:root {
  font-family: "Helvetica Neue", Helvetica, Arial, sans-serif;
  color: #344155;
  background: #f4f6fa;
  font-synthesis: none;
  --blue: #1a4896;
  --dark: #07275d;
  --border: #dbe2ed;
}
* {
  box-sizing: border-box;
}
body {
  margin: 0;
}
.access-gate {
  min-height: 100vh;
  display: grid;
  place-items: center;
  padding: 24px;
  background: linear-gradient(135deg, #edf2fa, #f9fbfe);
}
.access-card {
  width: min(100%, 430px);
  padding: 36px;
  border: 1px solid var(--border);
  border-radius: 18px;
  background: rgba(255, 255, 255, .96);
  box-shadow: 0 16px 45px rgba(7, 39, 93, .12);
}
.access-card img {
  display: block;
  width: min(100%, 300px);
  height: auto;
  margin: 0 auto 26px;
}
.access-card h1 { text-align: center; margin: 0 0 10px; }
.access-card > p { text-align: center; margin: 0 0 24px; }
.access-field { margin: 16px 0; }
.access-field label { display: block; margin-bottom: 7px; color: var(--dark); font-weight: 700; }
.access-error { min-height: 26px; margin: 12px 0 !important; color: #a12525; font-weight: 700; }
.access-card button { width: 100%; }
@media (max-width: 450px) { .access-card { padding: 28px 20px; } }
a {
  color: var(--blue);
}
button,
input,
select,
textarea {
  font: inherit;
  font-size: 16px;
}
button,
a,
summary,
input,
select,
textarea {
  -webkit-tap-highlight-color: transparent;
}
button,
.button {
  min-height: 44px;
  min-width: 44px;
  border: 1px solid #b5c3d8;
  background: white;
  color: var(--blue);
  border-radius: 7px;
  padding: 10px 15px;
  cursor: pointer;
  text-decoration: none;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 7px;
}
button:hover,
.button:hover {
  background: #edf2fa;
}
button:disabled {
  opacity: 0.45;
  cursor: default;
}
.primary {
  background: var(--blue);
  color: white;
  border-color: var(--blue);
}
.primary:hover {
  background: var(--dark);
}
:focus-visible {
  outline: 3px solid #d07b00;
  outline-offset: 3px;
}
h1,
h2,
h3 {
  color: var(--dark);
  line-height: 1.2;
}
h1 {
  font-size: 30px;
  letter-spacing: -0.7px;
  margin: 12px 0;
}
h2 {
  font-size: 21px;
}
h3 {
  font-size: 17px;
}
p {
  line-height: 1.6;
}
input:not([type="checkbox"]),
textarea,
select {
  width: 100%;
  min-width: 0;
  min-height: 44px;
  border: 1px solid #9facc0;
  border-radius: 5px;
  padding: 10px;
  color: #24334b;
  background: white;
}
input[type="checkbox"] {
  width: 24px;
  height: 24px;
  accent-color: var(--blue);
}
.header {
  display: flex;
  align-items: center;
  gap: 25px;
  background: white;
  border-top: 5px solid var(--blue);
  border-bottom: 1px solid var(--border);
  padding: 23px 32px;
}
.brand {
  flex-shrink: 0;
}
.brand img {
  width: 300px;
  height: auto;
  display: block;
}
.heading {
  display: flex;
  flex-direction: column;
  gap: 7px;
  border-left: 1px solid var(--border);
  padding-left: 25px;
}
.heading span {
  font-size: 11px;
  color: #56647a;
}
.heading strong {
  font-size: 20px;
  color: var(--dark);
}
#logout {
  flex-shrink: 0;
}
.logout-button {
  border-color: var(--blue);
  color: var(--blue);
  background: white;
}
.logout-button:hover {
  background: #edf2fa;
}
#search-form {
  margin-left: auto;
  width: min(420px, 36%);
}
.searchbox {
  display: flex;
  background: #f4f6fa;
  border: 1px solid #c4cedd;
  border-radius: 7px;
}
.searchbox input {
  border: 0;
  background: transparent;
}
.searchbox button {
  border: 0;
  background: transparent;
  font-size: 26px;
}
.shell {
  display: grid;
  grid-template-columns: 265px minmax(0, 1fr);
  min-height: calc(100vh - 109px);
}
#sidebar {
  background: white;
  border-right: 1px solid var(--border);
  padding: 27px 18px;
  display: flex;
  flex-direction: column;
  gap: 30px;
}
nav a {
  display: block;
  padding: 13px 12px;
  min-height: 44px;
  text-decoration: none;
  font-size: 14px;
  border-radius: 6px;
  margin: 4px 0;
  line-height: 1.4;
}
nav a[aria-current="page"] {
  background: #eaf0fa;
  color: var(--dark);
  font-weight: 700;
  border-left: 3px solid var(--blue);
}
nav summary {
  padding: 18px 9px;
  min-height: 44px;
  cursor: pointer;
  color: #59677b;
  font-size: 13px;
  font-weight: bold;
}
nav details {
  border-top: 1px solid var(--border);
  margin-top: 15px;
}
.sidebar-note {
  margin-top: auto;
  padding: 18px 12px;
  border-top: 1px solid var(--border);
  font-size: 12px;
  color: #5c6c81;
}
.sidebar-note p {
  margin: 8px 0;
}
.dot {
  display: inline-block;
  width: 7px;
  height: 7px;
  background: #2b765e;
  border-radius: 50%;
  margin-right: 7px;
}
#main {
  padding: 35px 40px 60px;
  min-width: 0;
  width: 100%;
  max-width: 1500px;
  margin: auto;
  align-self: start;
  overflow-wrap: anywhere;
}
.eyebrow {
  font-size: 11px;
  font-weight: 700;
  letter-spacing: 1.6px;
  text-transform: uppercase;
  color: var(--blue);
}
.lead {
  max-width: 740px;
  color: #637087;
  margin: 12px 0 25px;
}
.badge {
  display: inline-flex;
  font-size: 11px;
  font-weight: bold;
  padding: 5px 8px;
  border-radius: 4px;
  background: #eaf0fa;
  color: var(--blue);
  letter-spacing: 0.3px;
}
.badge.example {
  background: #fff1d6;
  color: #79551c;
}
.notice {
  background: #fff9eb;
  border: 1px solid #ead6a9;
  border-left: 3px solid #c49332;
  padding: 14px 18px;
  font-size: 14px;
  line-height: 1.55;
  border-radius: 5px;
  margin: 22px 0;
}
.cards {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 18px;
  margin: 22px 0 32px;
}
.card {
  background: white;
  border: 1px solid var(--border);
  border-radius: 10px;
  padding: 23px;
  min-width: 0;
  display: flex;
  flex-direction: column;
  text-decoration: none;
  color: inherit;
}
.card:hover {
  border-color: #8ba5cb;
}
.card p {
  font-size: 14px;
  color: #617089;
  margin: 0 0 20px;
}
.card .arrow {
  margin-top: auto;
  color: var(--blue);
  font-weight: bold;
  font-size: 14px;
}
.card-icon {
  width: 43px;
  height: 43px;
  display: grid;
  place-items: center;
  background: #edf2fa;
  color: var(--blue);
  border-radius: 9px;
  font-size: 22px;
  margin-bottom: 20px;
}
.section-head {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 15px;
}
.section-head span {
  font-size: 13px;
  color: #64718a;
}
.help-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 20px;
}
.panel {
  padding: 22px;
  background: white;
  border: 1px solid var(--border);
  border-radius: 9px;
}
.panel p {
  font-size: 14px;
  color: #637087;
}
.import {
  display: flex;
  flex-wrap: wrap;
  gap: 12px;
  align-items: center;
}
.import input {
  max-width: 100%;
}
.toolbar,
.actions {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 9px;
  margin: 16px 0;
}
.toolbar label {
  font-size: 14px;
  display: flex;
  align-items: center;
  gap: 7px;
}
.toolbar select {
  width: auto;
}
.actions {
  padding-top: 15px;
  border-top: 1px solid var(--border);
}
.view-tabs {
  display: flex;
  gap: 5px;
}
.view-tabs button[aria-pressed="true"] {
  background: var(--blue);
  color: white;
}
.editor {
  background: white;
  border: 1px solid var(--border);
  border-radius: 9px;
  padding: 18px;
  min-width: 0;
}
.pdf-scroll {
  overflow: auto;
  max-height: 78vh;
  background: #dfe5ee;
  border: 1px solid #c6d0df;
  padding: 16px;
  overscroll-behavior: contain;
  min-width: 0;
}
.pdf-page {
  position: relative;
  margin: 0 auto;
  background: white;
  box-shadow: 0 3px 12px #17345c22;
  flex-shrink: 0;
}
.pdf-page canvas {
  display: block;
  width: 100%;
  height: 100%;
}
.overlay {
  position: absolute;
  inset: 0;
}
.pdf-field {
  position: absolute;
  background: rgba(224, 237, 255, 0.65) !important;
  border: 1px solid #4777ba !important;
  border-radius: 2px !important;
  min-height: 0 !important;
  padding: 3px !important;
  margin: 0 !important;
  resize: none;
  line-height: 1.25;
  font-size: 16px !important;
  color: #172c4b !important;
}
.pdf-field:focus {
  background: #fff !important;
  z-index: 2;
}
.pdf-field[type="checkbox"] {
  min-width: 0 !important;
  accent-color: var(--blue);
}
.pdf-field[aria-invalid="true"] {
  border: 2px solid #ba3030 !important;
}
.stacked {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 22px;
}
.field-wrap {
  min-width: 0;
}
.field-wrap.wide {
  grid-column: 1/-1;
}
.field-wrap label {
  display: block;
  font-size: 14px;
  font-weight: 700;
  margin-bottom: 9px;
}
.field-wrap textarea {
  min-height: 140px;
  resize: vertical;
}
.field-wrap.check label {
  display: flex;
  align-items: center;
  gap: 12px;
  min-height: 44px;
}
.hint {
  font-size: 13px;
  color: #617087;
  line-height: 1.5;
}
.field-error {
  color: #a12121;
  font-size: 13px;
  margin-top: 7px;
  line-height: 1.4;
}
.error-summary {
  border: 1px solid #d99898;
  background: #fff4f4;
  padding: 15px;
  color: #9b2323;
  border-radius: 5px;
}
.error-summary button {
  color: #9b2323;
  text-align: left;
  border: 0;
  background: transparent;
  display: block;
}
.hidden,
[hidden] {
  display: none !important;
}
.result {
  display: block;
  background: white;
  border: 1px solid var(--border);
  padding: 20px;
  margin: 12px 0;
  border-radius: 8px;
  text-decoration: none;
  color: inherit;
}
.result h2 {
  margin: 10px 0;
  font-size: 20px;
}
.result p {
  margin: 0;
  font-size: 14px;
  color: #62718a;
}
.diagram-scroll {
  overflow: auto;
  border: 1px solid var(--border);
  background: #fff;
  border-radius: 8px;
  max-height: 70vh;
  padding: 16px;
}
.diagram {
  display: block;
  max-width: none;
}
.process-grid {
  display: grid;
  grid-template-columns: 1.5fr 1fr;
  gap: 22px;
  margin-top: 24px;
}
.steps {
  padding-left: 24px;
}
.steps li {
  padding-left: 8px;
  margin-bottom: 23px;
}
.steps p {
  font-size: 14px;
  margin: 6px 0;
}
.status {
  position: fixed;
  bottom: 16px;
  left: 50%;
  transform: translateX(-50%);
  max-width: calc(100% - 32px);
  padding: 0;
  background: var(--dark);
  color: white;
  border-radius: 6px;
  z-index: 20;
}
.status:not(:empty) {
  padding: 12px 18px;
}
.sr {
  position: absolute;
  width: 1px;
  height: 1px;
  padding: 0;
  margin: -1px;
  overflow: hidden;
  clip: rect(0, 0, 0, 0);
  white-space: nowrap;
  border: 0;
}
.skip {
  position: fixed;
  top: -80px;
  left: 10px;
  background: white;
  padding: 15px;
  z-index: 99;
}
.skip:focus {
  top: 10px;
}
#menu {
  display: none;
}
dialog {
  width: min(1000px, 95vw);
  max-height: 95dvh;
  border: 1px solid var(--border);
  border-radius: 10px;
  padding: 22px;
}
dialog::backdrop {
  background: #07275d99;
}
.dialog-head {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 12px;
}
.dialog-head h2 {
  margin-right: auto;
}
#print-pages canvas {
  display: block;
  width: 100%;
  height: auto;
  margin: 16px 0;
  border: 1px solid #ddd;
}
#print-output {
  display: none;
}
.footnote {
  margin-top: 35px;
  padding-top: 20px;
  border-top: 1px solid var(--border);
  font-size: 12px;
  color: #62718a;
}
@media (min-width: 1600px) {
  .cards {
    gap: 25px;
  }
}
@media (max-width: 1100px) {
  .header {
    gap: 18px;
    padding: 20px;
  }
  .brand img {
    width: 240px;
  }
  .heading {
    padding-left: 18px;
  }
  .heading span {
    display: none;
  }
  .heading strong {
    font-size: 18px;
  }
  .shell {
    grid-template-columns: 225px minmax(0, 1fr);
  }
  #main {
    padding: 28px 24px;
  }
  .cards {
    grid-template-columns: 1fr;
  }
  .card {
    padding: 20px;
  }
  .card-icon {
    margin-bottom: 5px;
  }
  .card p {
    margin-bottom: 12px;
  }
  .help-grid,
  .process-grid {
    grid-template-columns: 1fr;
  }
}
@media (max-width: 800px) {
  .header {
    flex-wrap: wrap;
    gap: 12px;
    padding: 14px 16px;
  }
  .brand img {
    width: 210px;
  }
  .heading {
    border: 0;
    padding: 0;
    flex: 1;
  }
  .heading strong {
    font-size: 15px;
  }
  #search-form {
    order: 3;
    width: 100%;
    margin: 0;
  }
  #logout { order: 2; }
  #menu {
    display: flex;
    padding: 8px;
  }
  .header #menu span {
    display: none;
  }
  .shell {
    display: block;
    min-height: 0;
  }
  #sidebar {
    display: none;
    border-right: 0;
    border-bottom: 1px solid var(--border);
    padding: 12px 16px;
  }
  #sidebar.open {
    display: block;
  }
  .sidebar-note {
    display: none;
  }
  #main {
    padding: 25px 16px 50px;
  }
  .cards {
    grid-template-columns: 1fr 1fr;
  }
  .cards .card:first-child {
    grid-column: 1/-1;
  }
  .stacked {
    grid-template-columns: 1fr;
  }
  .field-wrap.wide {
    grid-column: auto;
  }
  h1 {
    font-size: 27px;
  }
  .editor {
    padding: 12px;
  }
  .pdf-scroll {
    padding: 8px;
  }
  .actions button {
    flex: 1 1 200px;
  }
  .toolbar {
    gap: 7px;
  }
  .toolbar button {
    padding: 8px 10px;
  }
  .view-tabs {
    flex-wrap: wrap;
  }
  .notice {
    padding: 12px;
  }
  .help-grid {
    gap: 14px;
  }
}
@media (max-width: 450px) {
  .brand img {
    width: 175px;
  }
  .heading strong {
    font-size: 13px;
  }
  .header {
    gap: 10px;
  }
  .cards {
    grid-template-columns: 1fr;
  }
  .help-grid {
    grid-template-columns: 1fr;
  }
  .section-head {
    align-items: start;
  }
  .section-head span {
    display: none;
  }
  .panel {
    padding: 17px;
  }
  .toolbar label {
    flex-wrap: wrap;
  }
  .toolbar select {
    max-width: 100%;
  }
}
@media print {
  @page {
    margin: 0;
  }
  body > * {
    display: none !important;
  }
  body > #print-output {
    display: block !important;
  }
  #print-output img {
    display: block;
    width: 100%;
    height: auto;
    break-after: page;
    page-break-after: always;
  }
  #print-output img:last-child {
    break-after: auto;
    page-break-after: auto;
  }
  dialog {
    display: none !important;
  }
}
input.sr {
  width: 1px !important;
  height: 1px !important;
  min-height: 0 !important;
  padding: 0 !important;
  position: absolute !important;
}
#main:focus-visible {
  outline: none;
}
input.sr:focus-visible + label,
.import:focus-within label {
  outline: 3px solid #d07b00;
  outline-offset: 3px;
}
.badge {
  align-self: flex-start;
}
.brand {
  display: flex;
  align-items: center;
  min-height: 44px;
}
.panel > a:not(.card),
.section-head > a,
.footnote a {
  display: inline-flex;
  align-items: center;
  min-height: 44px;
}
.field-wrap input,
.field-wrap textarea,
.field-wrap select {
  scroll-margin-block: 90px;
}
.pdf-field:focus-visible {
  outline-offset: 1px;
}

.field-section {
  grid-column: 1/-1;
  margin: 22px 0 0;
  padding-top: 18px;
  border-top: 1px solid var(--border);
}
.field-wrap input:disabled {
  background: #f0f2f6;
  color: #657185;
}
.pdf-field:disabled {
  opacity: 0.45;
}
.field-wrap .hint {
  margin: 6px 0;
}

/* Category navigation and the two homepage entry tiles. */
.cards.entry-tiles {
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 24px;
}
.cards.entry-tiles .card:first-child {
  grid-column: auto;
}
.navigation-tile {
  position: relative;
  min-height: 235px;
  padding: 28px;
}
.navigation-tile h2 {
  font-size: 25px;
  margin: 12px 0;
}
.tile-count {
  font-size: 13px;
  color: #596b82;
  margin-top: 4px;
}
.cards.category-tiles {
  grid-template-columns: repeat(2, minmax(0, 1fr));
}
.cards.category-tiles .card:first-child {
  grid-column: auto;
}
.category-tiles .navigation-tile {
  min-height: 210px;
}
.category-tiles h2 {
  font-size: 21px;
}
.category-list-tile h2 a { color: inherit; text-decoration: none; }
.category-list-tile h2 a:hover, .category-list-tile h2 a:focus-visible { color: var(--blue); text-decoration: underline; }
.tile-attachments { margin: 2px 0 18px; padding: 12px; border: 1px solid rgba(110, 138, 180, .24); border-radius: 10px; background: rgba(255, 255, 255, .58); }
.tile-attachments h3 { margin: 0 0 7px; font-size: 13px; color: #435a79; }
.tile-attachments ul { margin: 0; padding-left: 18px; }
.tile-attachments li { margin: 6px 0; font-size: 14px; line-height: 1.35; }
.tile-attachments a { color: #285b9e; font-weight: 650; text-decoration: none; }
.tile-attachments a:hover, .tile-attachments a:focus-visible { text-decoration: underline; }
.tile-attachments .tile-empty { margin: 0; font-size: 13px; }
.category-list-tile .category-open { margin-top: auto; align-self: flex-start; }
.nav-category > a {
  margin: 2px 0;
}
.nav-category > a[data-active-category="true"] {
  background: #edf2fa;
  font-weight: 700;
}
.nav-subitems {
  border-left: 2px solid #dbe2ed;
  margin-left: 14px;
  padding-left: 8px;
}
.nav-subitems a {
  font-size: 13px;
}
.back-link {
  display: flex;
  align-items: center;
  min-height: 44px;
  width: fit-content;
  margin-bottom: 12px;
  text-decoration: none;
}
.local-import {
  margin-top: 28px;
  border-top: 1px solid var(--border);
  padding: 14px 0;
  color: #53657d;
}
.local-import summary {
  min-height: 44px;
  cursor: pointer;
  line-height: 1.5;
  padding: 10px 0;
  color: var(--blue);
  font-weight: 600;
}
.local-import p {
  font-size: 14px;
  max-width: 720px;
}
.keyword-index {
  margin-top: 32px;
  padding: 24px;
  border: 1px solid var(--border);
  border-radius: 18px;
  background: linear-gradient(145deg, #ffffff 10%, #f3f7fd 100%);
  box-shadow: var(--soft-shadow);
}
.mini-calendar {
  max-width: 430px;
  margin-top: 28px;
  padding: 20px 22px;
  border: 1px solid var(--border);
  border-radius: 16px;
  background: #fbfcff;
  box-shadow: 0 4px 18px rgba(26, 72, 150, 0.035);
}
.recent-changes {
  max-width: 760px;
  margin-top: 28px;
  padding: 22px 24px;
  border: 1px solid #d6e0f0;
  border-radius: 18px;
  background: linear-gradient(135deg, #f8fbff 0%, #f4f1fc 100%);
  box-shadow: var(--soft-shadow);
}
.recent-changes-head {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  gap: 16px;
}
.recent-changes-head .eyebrow { margin-bottom: 4px; }
.recent-changes-head h2 { margin: 0; color: var(--dark); font-size: 22px; }
.recent-changes-count {
  flex: 0 0 auto;
  padding: 5px 10px;
  border-radius: 999px;
  color: #514178;
  background: #e9e1fa;
  font-size: 13px;
  font-weight: 700;
}
.recent-changes-list {
  display: grid;
  gap: 10px;
  margin: 18px 0 0;
  padding: 0;
  list-style: none;
}
.recent-changes-list li {
  display: grid;
  grid-template-columns: 40px minmax(0, 1fr);
  gap: 12px;
  align-items: center;
  padding: 12px;
  border: 1px solid rgba(198, 210, 231, .8);
  border-radius: 12px;
  background: rgba(255, 255, 255, .72);
}
.recent-change-icon {
  display: grid;
  width: 40px;
  height: 40px;
  place-items: center;
  border-radius: 11px;
  color: var(--blue);
  background: #e6effc;
  font-size: 19px;
}
.recent-changes-list a { color: var(--blue); font-weight: 750; text-decoration: none; }
.recent-changes-list a:hover, .recent-changes-list a:focus-visible { text-decoration: underline; }
.recent-changes-list p { margin: 3px 0 0; color: #65738a; font-size: 13px; }
.recent-change-type {
  color: #514178;
  font-weight: 700;
}
.mini-calendar-head {
  display: flex;
  flex-wrap: wrap;
  align-items: end;
  gap: 12px;
  justify-content: space-between;
}
.mini-calendar-head h2 {
  margin: 2px 0 0;
  font-size: 21px;
  color: var(--dark);
}
.calendar-controls {
  display: flex;
  align-items: center;
  gap: 8px;
  color: #4d607d;
  font-size: 14px;
  text-transform: capitalize;
}
.calendar-controls button {
  min-width: 44px;
  min-height: 44px;
  padding: 8px;
  color: var(--blue);
  background: #eef4fd;
  border: 1px solid #d5e1f2;
}
.calendar-controls button:hover,
.calendar-controls button:focus-visible {
  background: #e3edfb;
}
.calendar-grid {
  display: grid;
  grid-template-columns: repeat(7, minmax(0, 1fr));
  gap: 4px;
  text-align: center;
}
.calendar-grid.with-weeks {
  grid-template-columns: 34px repeat(7, minmax(0, 1fr));
}
.calendar-weekdays {
  margin-top: 18px;
  color: #7a889d;
  font-size: 12px;
  font-weight: 700;
}
.calendar-days {
  margin-top: 6px;
}
.calendar-day {
  display: grid;
  min-height: 32px;
  place-items: center;
  color: #44546c;
  border-radius: 8px;
  font-size: 14px;
}
.calendar-day.today {
  color: #ffffff;
  background: var(--blue);
  font-weight: 800;
  box-shadow: 0 2px 7px rgba(26, 72, 150, 0.18);
}
.calendar-day.empty {
  visibility: hidden;
}
.calendar-week-label,
.calendar-week-number {
  display: grid;
  min-height: 32px;
  place-items: center;
  color: #8a98aa;
  font-size: 11px;
  font-weight: 700;
}
.calendar-week-number {
  border-right: 1px solid #e0e7f1;
  color: #73839a;
}
.calendar-note {
  margin: 14px 0 0;
  color: #7c8b9f;
  font-size: 12px;
}
.keyword-index-head h2 {
  margin: 4px 0 8px;
  color: var(--dark);
}
.keyword-index-head .lead {
  margin-bottom: 18px;
  font-size: 15px;
}
.keyword-letters {
  display: flex;
  flex-wrap: wrap;
  gap: 6px;
  padding: 12px 0 20px;
  border-bottom: 1px solid var(--border);
}
.keyword-letter {
  min-width: 44px;
  min-height: 44px;
  padding: 8px 10px;
  color: var(--blue);
  background: #eef4fd;
  border: 1px solid #cfddf1;
  border-radius: 9px;
  font-weight: 700;
}
.keyword-letter:hover:not(:disabled),
.keyword-letter:focus-visible {
  background: #dfeafb;
  border-color: #9eb7df;
}
.keyword-letter:disabled {
  color: #9aa8bc;
  background: #f5f7fb;
  border-color: #e4e9f1;
  cursor: not-allowed;
}
.keyword-groups {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 20px 28px;
  padding-top: 20px;
}
.keyword-group {
  scroll-margin-top: 20px;
}
.keyword-group h3 {
  margin: 0 0 8px;
  padding-bottom: 5px;
  border-bottom: 2px solid #d9e4f4;
  color: var(--blue);
  font-size: 20px;
}
.keyword-group ul {
  display: grid;
  gap: 7px;
  margin: 0;
  padding: 0;
  list-style: none;
}
.keyword-group li {
  display: grid;
  grid-template-columns: minmax(110px, 0.7fr) minmax(0, 1.3fr);
  gap: 10px;
  align-items: baseline;
  padding: 7px 0;
  border-bottom: 1px solid #e8edf5;
  font-size: 14px;
}
.keyword-term {
  color: #43536c;
  font-weight: 700;
}
.keyword-targets {
  min-width: 0;
}
.keyword-targets a {
  color: var(--blue);
  text-decoration: none;
}
.keyword-targets a:hover,
.keyword-targets a:focus-visible {
  text-decoration: underline;
}
.keyword-empty {
  margin: 0;
  color: #8795aa;
  font-size: 14px;
}
@media (max-width: 600px) {
  .cards.entry-tiles,
  .cards.category-tiles {
    grid-template-columns: 1fr;
    gap: 16px;
  }
  .navigation-tile,
  .category-tiles .navigation-tile {
    min-height: 195px;
    padding: 22px;
  }
  .keyword-index {
    padding: 18px;
  }
  .mini-calendar {
    max-width: none;
    padding: 18px;
  }
  .recent-changes { padding: 18px; }
  .keyword-groups {
    grid-template-columns: 1fr;
    gap: 18px;
  }
}

#main { margin: 0 auto; }

/* Softer screen surfaces, keeping the school's existing blue palette.
   PDF canvases, field geometry and printed original pages remain unchanged. */
@media screen {
  :root {
    background: #f5f7fc;
    --border: #dce5f2;
    --soft-shadow: 0 6px 24px rgba(26, 72, 150, 0.045);
  }
  .header {
    background: #ffffff;
    border-bottom-color: #e3eaf5;
    box-shadow: 0 3px 18px rgba(26, 72, 150, 0.035);
  }
  #sidebar { background: #f9fbff; }
  nav a { border-radius: 10px; }
  nav a:hover { background: #edf3fd; }
  nav a[aria-current="page"],
  .nav-category > a[data-active-category="true"] { background: #e5edfb; }
  #sidebar #navigation > details {
    margin: 13px 0 0;
    padding: 0;
    border: 0;
  }
  #sidebar #navigation > details > summary {
    margin: 0 0 9px;
    padding: 14px 13px;
    border-radius: 13px;
    color: #123b7d;
    background: #dceaff;
    font-size: 16px;
    font-weight: 800;
    letter-spacing: .1px;
  }
  #sidebar #navigation > details:nth-of-type(2) > summary { background: #eadfff; color: #5d3b87; }
  #sidebar #navigation > details:nth-of-type(3) > summary { background: #fff0d9; color: #865018; }
  #sidebar #navigation > details:nth-of-type(4) > summary { background: #def2eb; color: #1e6953; }
  #sidebar #navigation > details > a,
  #sidebar .nav-category > a,
  #sidebar .nav-subitems a {
    margin: 6px 0;
    border: 1px solid #d9e3f1;
    background: #f7faff;
    box-shadow: 0 2px 7px rgba(26, 72, 150, .035);
  }
  #sidebar #navigation > details:nth-of-type(2) > a { background: #fbf9ff; border-color: #e4dbf3; }
  #sidebar #navigation > details:nth-of-type(3) > a { background: #fffaf2; border-color: #f0dfbe; }
  #sidebar #navigation > details:nth-of-type(4) > a { background: #f7fcfa; border-color: #d5e9e1; }
  #sidebar .nav-subitems {
    margin: 7px 0 9px 10px;
    padding: 3px 0 3px 10px;
    border-left: 2px solid #b9cae2;
  }
  #sidebar .nav-subitems a { background: #fffdf9; border-color: #eee1c8; font-size: 13px; }
  #sidebar .home-link { background: linear-gradient(135deg, #fff4df, #fffaf0); border: 1px solid #f0dfbe; font-weight: 700; }
  .searchbox { background: #f0f4fc; border-color: #d3deef; border-radius: 12px; }
  .card {
    background: linear-gradient(145deg, #ffffff 20%, #f0f5fd 100%);
    border-color: #dce5f3;
    border-radius: 20px;
    box-shadow: var(--soft-shadow);
    transition: background-color 160ms ease, box-shadow 160ms ease, border-color 160ms ease;
  }
  .entry-tiles .card:first-child { background: linear-gradient(135deg, #edf3fd, #f9fbff); }
  .entry-tiles .card:last-child { background: linear-gradient(135deg, #f6f9ff, #eaf1fc); }
  .entry-tiles .navigation-tile,
  .category-tiles .navigation-tile {
    overflow: hidden;
    isolation: isolate;
  }
  .entry-tiles .navigation-tile::after,
  .category-tiles .navigation-tile::after {
    content: "";
    position: absolute;
    z-index: -1;
    width: 170px;
    height: 170px;
    right: -62px;
    bottom: -72px;
    border-radius: 48% 52% 57% 43% / 48% 44% 56% 52%;
    background: rgba(109, 151, 215, .15);
    transform: rotate(18deg);
  }
  .entry-tiles .navigation-tile:first-child {
    background: linear-gradient(135deg, #e6f0ff 0%, #f7fbff 70%);
  }
  .entry-tiles .tile-prozesse {
    background: linear-gradient(135deg, #f0ecff 0%, #fbfaff 70%);
  }
  .entry-tiles .tile-protokolle { background: linear-gradient(135deg, #fff1dd 0%, #fffdfa 70%); }
  .entry-tiles .tile-administration { background: linear-gradient(135deg, #eaf7f3 0%, #fbfefd 70%); }
  .entry-tiles .tile-prozesse::after { background: rgba(163, 133, 214, .17); }
  .entry-tiles .tile-protokolle::after { background: rgba(229, 164, 84, .18); }
  .entry-tiles .tile-administration::after { background: rgba(85, 166, 137, .14); }
  .entry-tiles .navigation-tile .card-icon {
    width: 58px;
    height: 58px;
    border-radius: 20px 20px 20px 8px;
    background: #d8e8ff;
    box-shadow: 0 6px 14px rgba(38, 92, 169, .12);
    font-size: 28px;
  }
  .entry-tiles .tile-prozesse .card-icon { background: #e8ddff; color: #624292; }
  .entry-tiles .tile-protokolle .card-icon { background: #ffe6c4; color: #925814; }
  .entry-tiles .tile-administration .card-icon { background: #dff2eb; color: #236a55; }
  .administration-tiles .panel { padding: 24px; }
  .administration-tiles .panel:nth-child(2) .card-icon { background: #e9ddff; color: #624292; }
  .administration-tiles .panel:nth-child(3) .card-icon { background: #dff2eb; color: #236a55; }
  .administration-tiles .admin-tile {
    display: flex;
    flex-direction: column;
    text-decoration: none;
    color: inherit;
    background: linear-gradient(135deg, #fff3e5, #fffdf9);
  }
  .administration-tiles .admin-tile .card-icon { background: #ffead2; color: #9a5a11; }
  .administration-tiles .process-admin-tile { background: linear-gradient(135deg, #f0ecff, #fbfaff); }
  .administration-tiles .process-admin-tile .card-icon { background: #e8ddff; color: #624292; }
  .administration-tiles .admin-tile .arrow { margin-top: auto; color: var(--blue); font-weight: 700; }
  .administration-tiles .admin-tile:hover,
  .administration-tiles .admin-tile:focus-visible { border-color: #aabfe0; box-shadow: 0 9px 28px rgba(26, 72, 150, .085); }
  .member-panel { margin-bottom: 18px; }
  .member-form-grid { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 16px; margin-bottom: 18px; }
  .member-form-grid label { display: grid; gap: 7px; color: var(--dark); font-weight: 700; }
  .member-list { list-style: none; margin: 0; padding: 0; }
  .member-list li { display: flex; justify-content: space-between; align-items: center; gap: 16px; padding: 14px 0; border-bottom: 1px solid var(--border); }
  .member-list li:last-child { border-bottom: 0; }
  .member-list span { display: block; margin-top: 4px; font-size: 14px; color: #617089; }
  .member-actions, .member-form-actions { display: flex; flex-wrap: wrap; gap: 8px; }
  .member-remove { color: #9b3030; }
  .admin-form-actions { display: grid; grid-template-columns: minmax(112px, 1fr); grid-auto-rows: 44px; gap: 7px; width: 124px; flex: 0 0 124px; }
  .admin-form-actions .button, .admin-form-actions .member-remove { min-width: 0; min-height: 44px; height: 44px; padding: 7px 10px; font-size: 14px; line-height: 1.2; }
  .admin-form-actions .member-remove { border-color: #e2b9b9; background: #fffafa; }
  .admin-form-actions .member-remove:hover { background: #fff0f0; }
  @media (max-width: 720px) { .builder-steps { grid-template-columns: 1fr; } .builder-field-row { grid-template-columns: repeat(2, minmax(0, 1fr)); } .builder-field-row label:first-of-type { grid-column: 1 / -1; } .builder-field-row .builder-required { min-height: 44px; } }
  @media (max-width: 520px) { .member-list li { align-items: flex-start; flex-direction: column; } .admin-form-actions { width: 100%; grid-template-columns: minmax(0, 1fr); } .builder-field-row { grid-template-columns: 1fr; } .builder-field-row label:first-of-type { grid-column: auto; } .builder-actions { display: grid; grid-template-columns: 1fr; } }
  .admin-access { max-width: 480px; margin: 36px auto; padding: 30px; }
  .admin-access label { display: block; margin: 16px 0 7px; color: var(--dark); font-weight: 700; }
  .admin-access button { margin-top: 4px; width: 100%; }
  .admin-import-panel { margin-bottom: 18px; }
  .admin-import-grid { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 16px; margin: 18px 0; }
  .admin-import-grid label { display: grid; gap: 7px; color: var(--dark); font-weight: 700; }
  .builder-intro { margin-bottom: 18px; }
  .builder-steps { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 14px; list-style: none; padding: 0; margin: 0; counter-reset: none; }
  .builder-steps li { padding: 15px; border-radius: 12px; background: #f6f9fe; border: 1px solid #dce5f3; }
  .builder-steps strong, .builder-steps span { display: block; }
  .builder-steps span { margin-top: 4px; color: #617089; font-size: 14px; line-height: 1.4; }
  .builder-step { display: grid; grid-template-columns: 38px 1fr; gap: 12px; align-items: start; margin: 22px 0 12px; }
  .builder-step h2 { margin: 0 0 4px; font-size: 19px; }
  .builder-step p { margin: 0; color: #617089; }
  .step-number { display: grid; place-items: center; width: 32px; height: 32px; border-radius: 50%; background: #dce9fb; color: #1a4896; font-weight: 800; }
  .builder-analysis { margin: 18px 0; padding: 16px 18px; border: 1px solid #b9d9cd; border-radius: 12px; background: #f1faf5; }
  .builder-analysis h2 { margin: 0 0 8px; font-size: 17px; color: #285f4e; }
  .builder-analysis p { margin: 0; color: #315d50; }
  .builder-analysis details { margin-top: 10px; color: #315d50; }
  .builder-analysis ul { margin: 8px 0 0; padding-left: 20px; }
  .builder-fields { margin: 24px 0; padding: 18px; border: 1px solid var(--border); border-radius: 12px; }
  .builder-fields legend { padding: 0 6px; color: var(--dark); font-weight: 700; }
  .builder-field-row { display: grid; grid-template-columns: minmax(170px, 2fr) repeat(7, minmax(72px, 1fr)) auto auto; gap: 10px; align-items: end; margin: 14px 0; padding: 14px; border: 1px solid #dce5f3; border-radius: 10px; background: #fbfdff; }
  .builder-field-heading { grid-column: 1 / -1; display: flex; align-items: center; gap: 8px; color: #435a79; font-size: 13px; }
  .builder-auto-badge { padding: 3px 7px; border-radius: 999px; background: #e3f3eb; color: #206347; font-weight: 700; }
  .builder-field-row label { display: grid; gap: 6px; color: #435a79; font-size: 13px; font-weight: 700; }
  .builder-field-row .builder-required { display: flex; align-items: center; min-height: 44px; white-space: nowrap; }
  .builder-field-row .builder-required input { width: 20px; height: 20px; }
  .builder-remove-field { min-height: 38px; padding: 7px 10px; font-size: 14px; color: #9b3030; }
  .builder-actions { display: flex; flex-wrap: wrap; gap: 10px; margin-top: 18px; }
  .builder-ai-note { margin-top: 22px; padding: 4px 0; color: #52647d; }
  .builder-ai-note summary { cursor: pointer; color: var(--blue); font-weight: 700; }
  .builder-ai-note p { line-height: 1.5; }
  .builder-preview-toolbar { display: flex; align-items: center; gap: 10px; margin: 14px 0; }
  .builder-preview-toolbar span { min-width: 118px; text-align: center; color: #435a79; font-weight: 700; }
  .builder-preview-host { overflow: auto; max-height: 62vh; padding: 14px; border: 1px solid #c6d0df; border-radius: 12px; background: #e8eef8; }
  .builder-preview-page { position: relative; margin: 0 auto; background: white; box-shadow: 0 3px 12px #17345c22; }
  .builder-preview-page canvas { display: block; width: 100%; height: 100%; }
  .builder-preview-overlay { position: absolute; inset: 0; pointer-events: none; }
  .builder-preview-field { position: absolute; display: flex; align-items: center; padding: 1px 3px; overflow: hidden; border: 1px solid #286bb7; border-radius: 2px; background: rgba(218, 234, 255, .46); color: #184c8a; line-height: 1.15; white-space: nowrap; }
  .builder-preview-field.checkbox { justify-content: center; padding: 0; background: rgba(218, 234, 255, .25); }
  .admin-import-concept { margin-top: 24px; padding: 18px; border-radius: 12px; background: #f5f8fe; }
  .admin-import-concept h3 { margin-top: 0; }
  .admin-import-concept li { margin: 8px 0; line-height: 1.45; }
  .process-required-forms { margin: 22px 0; padding: 16px; border: 1px solid var(--border); border-radius: 12px; }
  .process-required-forms legend { color: var(--dark); font-weight: 700; padding: 0 6px; }
  .process-required-forms > label { display: block; margin-bottom: 7px; font-weight: 700; }
  #process-form-results { max-height: 260px; overflow: auto; margin-top: 12px; border-top: 1px solid var(--border); }
  .process-form-choice { display: grid; grid-template-columns: 28px 1fr auto; gap: 8px; align-items: center; padding: 11px 4px; border-bottom: 1px solid var(--border); }
  .process-form-choice small { display: block; margin-top: 3px; color: #617089; font-size: 13px; }
  #process-steps { min-height: 300px; }
  .process-preview-dialog { width: min(100% - 28px, 940px); max-height: calc(100vh - 28px); padding: 22px; }
  .process-preview-dialog #process-preview-content { display: grid; gap: 18px; }
  .process-preview-dialog .diagram-scroll { max-height: 420px; }
  .form-preview-frame { display: block; width: 100%; height: min(68vh, 760px); border: 1px solid var(--border); border-radius: 10px; }
  @media (max-width: 700px) { .admin-import-grid { grid-template-columns: 1fr; } }
  @media (max-width: 700px) { .member-form-grid { grid-template-columns: 1fr; } }
  .category-tiles .navigation-tile:nth-child(4n + 1) { background: linear-gradient(135deg, #e7f2ff, #fbfdff); }
  .category-tiles .navigation-tile:nth-child(4n + 2) { background: linear-gradient(135deg, #f6edff, #fdfaff); }
  .category-tiles .navigation-tile:nth-child(4n + 3) { background: linear-gradient(135deg, #eaf7f3, #fbfefd); }
  .category-tiles .navigation-tile:nth-child(4n) { background: linear-gradient(135deg, #fff3e5, #fffdf9); }
  .category-tiles .navigation-tile:nth-child(4n + 2)::after { background: rgba(163, 133, 214, .15); }
  .category-tiles .navigation-tile:nth-child(4n + 3)::after { background: rgba(85, 166, 137, .14); }
  .category-tiles .navigation-tile:nth-child(4n)::after { background: rgba(222, 160, 87, .14); }
  .category-tiles .navigation-tile:nth-child(4n + 2) .card-icon { background: #e9ddff; color: #624292; }
  .category-tiles .navigation-tile:nth-child(4n + 3) .card-icon { background: #dff2eb; color: #236a55; }
  .category-tiles .navigation-tile:nth-child(4n) .card-icon { background: #ffead2; color: #9a5a11; }
  .card:hover, .card:focus-visible {
    border-color: #aabfe0;
    box-shadow: 0 9px 28px rgba(26, 72, 150, 0.085);
  }
  .card-icon { background: #e1ebfb; border-radius: 14px; }
  .badge { border-radius: 7px; background: #e6eefb; }
  .badge.example { background: #fff2dc; }
  .panel, .editor, .result {
    background: #ffffff;
    border-color: #dce5f3;
    border-radius: 16px;
    box-shadow: var(--soft-shadow);
  }
  .notice { background: #fffbf2; border-radius: 12px; }
  button, .button { border-radius: 10px; }
  .field-wrap input:not([type="checkbox"]), .field-wrap textarea, .field-wrap select {
    border-radius: 9px;
    background: #fcfdff;
  }
  .field-wrap input:disabled { background: #f0f3f9; }
  .pdf-scroll { background: #e8eef8; border-radius: 12px; border-color: #d4deed; }
  .diagram-scroll { border-radius: 14px; background: #fdfefe; }
  dialog { border-radius: 18px; box-shadow: 0 20px 70px rgba(7, 39, 93, 0.16); }
  .status { border-radius: 12px; }
  .error-summary { border-radius: 12px; }
}
@media (prefers-reduced-motion: reduce) {
  .card { transition: none; }
}

.diagram-form-link { cursor: pointer; }
.diagram-form-link text { fill: #17458a; text-decoration: underline; }
.diagram-form-link:hover rect, .diagram-form-link:focus rect { fill: #dce7f7; stroke: #17458a; stroke-width: 3; }
