﻿:root {
  --ink: #0f1f24;
  --muted: #5b6d73;
  --line: #e2ecee;
  --paper: #f4f8f9;
  --card: #ffffff;
  --accent: #0d7c86;
  --accent-dark: #0a5f67;
  --hero: #062f36;
  --s: #1b7f4e;
  --i: #c9a227;
  --r: #b42318;
  --radius: 14px;
  --shadow: 0 12px 32px rgba(6, 47, 54, 0.08);
  --help-fg: var(--ink);
  --help-bg: #fff;
}

* { box-sizing: border-box; }
html, body { margin: 0; }
body {
  min-height: 100vh;
  display: flex;
  flex-direction: column;
  font-family: "Segoe UI", system-ui, sans-serif;
  color: var(--ink);
  background: var(--paper);
  line-height: 1.5;
}
a { color: var(--accent); }
.topbar {
  background: #fff;
  border-bottom: 2px solid var(--accent);
  box-shadow: 0 2px 10px rgba(6, 47, 54, 0.08);
}
.topbar-inner {
  width: min(1120px, calc(100% - 2rem));
  margin: 0 auto;
  display: flex;
  align-items: center;
  gap: 1rem;
  padding: 0.65rem 0;
}
.logo {
  font-weight: 800;
  text-decoration: none;
  color: var(--hero);
  letter-spacing: -0.03em;
  font-size: 1.12rem;
  margin-right: 0.35rem;
}
.nav { display: flex; flex-wrap: wrap; align-items: center; gap: 0.3rem; }
.nav > a, .nav summary, .nav > button.nav-help-toggle {
  color: var(--ink);
  text-decoration: none;
  cursor: pointer;
  list-style: none;
  font-weight: 700;
  font-size: 0.98rem;
  line-height: 1.2;
  padding: 0.45rem 0.8rem;
  border-radius: 8px;
  border: 1px solid transparent;
}
.nav > button.nav-help-toggle {
  appearance: none;
  background: transparent;
  font: inherit;
}
.nav summary {
  display: inline-flex;
  align-items: center;
  gap: 0.3rem;
}
.nav summary::-webkit-details-marker { display: none; }
.nav summary::after {
  content: "\25BE";
  font-size: 0.75em;
  opacity: 0.7;
}
.nav > a:hover, .nav summary:hover, .nav > button.nav-help-toggle:hover {
  background: #e4f3f4;
  color: var(--accent-dark);
  border-color: #c5e3e6;
}
.nav > a.is-active,
.nav > button.nav-help-toggle.is-active,
.nav-more.is-active > summary {
  background: var(--accent);
  color: #fff;
  border-color: var(--accent);
}
.nav-more { position: relative; }
.nav-more div {
  position: absolute;
  background: #fff;
  border: 1px solid var(--line);
  border-radius: 10px;
  padding: 0.4rem;
  display: grid;
  gap: 0.15rem;
  min-width: 14rem;
  z-index: 5;
  box-shadow: var(--shadow);
}
.nav-more div a {
  color: var(--ink);
  text-decoration: none;
  font-weight: 600;
  padding: 0.4rem 0.55rem;
  border-radius: 6px;
  white-space: nowrap;
}
.nav-more div a:hover {
  background: #e4f3f4;
  color: var(--accent-dark);
}
.nav-more-label {
  margin: 0.35rem 0 0.05rem;
  padding: 0.15rem 0.55rem 0;
  font-size: 0.72rem;
  font-weight: 700;
  letter-spacing: 0.03em;
  text-transform: uppercase;
  color: var(--muted);
}
.nav-more-label:first-child { margin-top: 0; }
.nav-more div a.is-active {
  background: var(--accent);
  color: #fff;
}
.topbar-actions {
  margin-left: auto;
  display: flex;
  align-items: center;
  gap: 0.75rem;
}
.logout { margin-left: 0; }
.logout button {
  background: #fff;
  border: 1px solid var(--line);
  color: var(--ink);
  cursor: pointer;
  font: inherit;
  font-weight: 600;
  padding: 0.4rem 0.75rem;
  border-radius: 8px;
}
.logout button:hover {
  border-color: var(--accent);
  color: var(--accent-dark);
  background: #e4f3f4;
}
.linkish {
  background: none;
  border: 0;
  color: var(--accent-dark);
  cursor: pointer;
  font: inherit;
  font-weight: 600;
  text-decoration: underline;
}
.license-line {
  width: min(1120px, calc(100% - 2rem));
  margin: 0 auto;
  padding: 0 0 0.6rem;
  color: var(--muted);
  font-size: 0.85rem;
}
.demo-banner {
  background: #fff4d6;
  color: #5a3d00;
  border-bottom: 1px solid #ead7a0;
  text-align: center;
  padding: 0.55rem 1rem;
  font-size: 0.9rem;
}
.demo-banner a {
  color: inherit;
  font-weight: 600;
  white-space: nowrap;
}
.webmaster-bar {
  background: #eef3f4;
  color: var(--muted);
  border-bottom: 1px solid var(--line);
}
.webmaster-inner {
  width: 100%;
  margin: 0;
  display: flex;
  flex-wrap: wrap;
  align-items: flex-start;
  justify-content: flex-start;
  gap: 0.35rem 0.75rem;
  padding: 0.28rem 1rem;
  text-align: left;
}
.webmaster-title {
  font-size: 0.78rem;
  font-weight: 600;
  letter-spacing: 0;
  white-space: nowrap;
  color: var(--muted);
}
.webmaster-nav {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 0.3rem 0.7rem;
}
.webmaster-nav a {
  color: var(--accent-dark);
  text-decoration: none;
  font-size: 0.8rem;
  font-weight: 600;
}
.webmaster-nav a.is-active,
.webmaster-nav a:hover {
  color: var(--hero);
  text-decoration: underline;
}
.webmaster-nav a.button {
  text-decoration: none;
}
.webmaster-nav a.button:hover,
.webmaster-nav a.button.is-active {
  background: #e4f3f4;
  border-color: var(--accent);
  color: var(--accent-dark);
  text-decoration: none;
}
.webmaster-nav .webmaster-menu-panel a {
  display: block;
  width: 100%;
  box-sizing: border-box;
  color: var(--ink);
  text-decoration: none;
  font-size: 0.88rem;
  font-weight: 600;
  padding: 0.35rem 0.45rem;
  border-radius: 6px;
}
.webmaster-nav .webmaster-menu-panel a:hover,
.webmaster-nav .webmaster-menu-panel a.is-active {
  background: #e4f3f4;
  color: var(--accent-dark);
  text-decoration: none;
}
.webmaster-actions {
  margin-left: 0;
  display: flex;
  flex-wrap: wrap;
  align-items: flex-start;
  gap: 0.3rem 0.5rem;
}
.webmaster-menu {
  position: relative;
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 0.12rem;
}
.webmaster-caption {
  font-size: 0.72rem;
  line-height: 1.15;
  color: var(--muted);
  text-align: center;
  white-space: nowrap;
  max-width: 12rem;
  overflow: hidden;
  text-overflow: ellipsis;
}
.webmaster-menu-panel {
  position: absolute;
  left: 0;
  right: auto;
  top: calc(100% + 0.3rem);
  min-width: 14rem;
  max-height: 18rem;
  overflow: auto;
  background: #fff;
  border: 1px solid var(--line);
  border-radius: 10px;
  padding: 0.4rem;
  z-index: 20;
  box-shadow: var(--shadow);
}
.webmaster-menu-current {
  margin: 0 0.35rem 0.35rem;
  font-size: 0.75rem;
  color: var(--muted);
}
.webmaster-menu-panel form {
  margin: 0;
}
.webmaster-menu-panel button {
  display: block;
  width: 100%;
  text-align: left;
  background: none;
  border: 0;
  color: var(--ink);
  font: inherit;
  font-size: 0.88rem;
  padding: 0.35rem 0.45rem;
  border-radius: 6px;
  cursor: pointer;
}
.webmaster-menu-panel button:hover {
  background: #e4f3f4;
}
.webmaster-bar .button {
  background: transparent;
  color: var(--ink);
  border-color: #c9d6d9;
  font-size: 0.78rem;
  font-weight: 600;
  padding: 0.18rem 0.5rem;
}
.webmaster-bar .button:hover,
.webmaster-bar .button.is-active {
  background: #e4f3f4;
  border-color: var(--accent);
  color: var(--accent-dark);
}
.page {
  width: min(1120px, calc(100% - 2rem));
  margin: 1.25rem auto 2rem;
  flex: 1;
}
.page-head, .hero-panel, .filter-bar, .inline-form, .capture-meta, .actions, .cards {
  display: flex;
  flex-wrap: wrap;
  gap: 0.75rem 1rem;
  align-items: center;
}
.page-head { justify-content: space-between; }
.keim-hint { margin: -0.25rem 0 1rem; max-width: 72rem; }
.page-head-title {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 0.5rem 0.75rem;
}
.page-head-title h1 { margin: 0; }
.capture-head { justify-content: flex-start; align-items: flex-start; gap: 1rem 1.5rem; }
.capture-head h1 { margin: 0; }
.capture-head-text { display: grid; gap: 0.35rem; }
.capture-tab-hint { margin: 0; font-size: 0.95rem; }
.capture-title {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 0.35rem 0.5rem;
  font-family: inherit;
  font-size: 1.75rem;
  font-weight: 700;
  line-height: 1.2;
  letter-spacing: -0.03em;
  color: inherit;
}
.capture-title-date {
  font: inherit;
  font-family: inherit;
  font-size: 1em;
  font-weight: inherit;
  line-height: inherit;
  letter-spacing: inherit;
  color: inherit;
  height: auto;
  padding: 0 0.2em;
  margin: 0;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: #fff;
}
.capture-title-date::-webkit-datetime-edit,
.capture-title-date::-webkit-datetime-edit-fields-wrapper,
.capture-title-date::-webkit-datetime-edit-text,
.capture-title-date::-webkit-datetime-edit-year-field,
.capture-title-date::-webkit-datetime-edit-month-field,
.capture-title-date::-webkit-datetime-edit-day-field {
  font: inherit;
  font-family: inherit;
  font-size: inherit;
  font-weight: inherit;
  line-height: inherit;
  letter-spacing: inherit;
  padding: 0;
}
.capture-title-date::-webkit-calendar-picker-indicator {
  width: 1em;
  height: 1em;
  cursor: pointer;
}
.hero-panel {
  background: var(--hero);
  color: #e8f4f5;
  border-radius: var(--radius);
  padding: 1.4rem 1.5rem;
  justify-content: space-between;
  margin-bottom: 1.25rem;
}
.hero-panel .lead { color: #c5dfe2; max-width: 36rem; }
.hero-panel .lead-single { max-width: none; white-space: nowrap; }
.kicker { text-transform: uppercase; letter-spacing: 0.08em; font-size: 0.75rem; margin: 0; color: #9ad4db; }
h1 { margin: 0.2rem 0 0.5rem; letter-spacing: -0.03em; }
h2 { margin: 1.4rem 0 0.6rem; font-size: 1.1rem; }
.stat-card, .mini-card, .card, .copy-box {
  background: #fff;
  border: 1px solid var(--line);
  border-radius: var(--radius);
  padding: 1rem 1.1rem;
  box-shadow: var(--shadow);
  color: var(--ink);
}
.hero-panel .stat-card span,
.hero-panel .mini-card span {
  color: var(--muted);
}
.stat-card strong, .mini-card strong { font-size: 2rem; display: block; }
.button {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  border-radius: 999px;
  padding: 0.45rem 0.95rem;
  text-decoration: none;
  border: 1px solid var(--line);
  background: #fff;
  color: var(--ink);
  cursor: pointer;
  font: inherit;
}
.button[hidden] { display: none !important; }
p[hidden] { display: none !important; }
.button-primary { background: var(--accent); border-color: var(--accent); color: #fff; }
.capture-save {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 0.65rem;
  margin: 1.2rem 0 0.4rem;
  text-align: center;
}
.capture-save[hidden] { display: none !important; }
.capture-save p { margin: 0; font-weight: 600; }
.button-ghost { background: transparent; color: inherit; border-color: rgba(255,255,255,0.35); }
.hero-panel .button-ghost { color: #fff; }
.table { width: 100%; border-collapse: collapse; background: #fff; border-radius: var(--radius); overflow: hidden; }
.table th, .table td { text-align: left; padding: 0.55rem 0.7rem; border-bottom: 1px solid var(--line); vertical-align: middle; }
.table th { font-size: 0.8rem; color: var(--muted); font-weight: 600; }
.table th a.sort-link { color: var(--accent-dark); text-decoration: underline; cursor: pointer; }
.table th a.sort-link.is-active { font-weight: 700; }
.table th a.sort-link:hover { color: var(--accent); }
.table td form { display: inline; margin-left: 0.55rem; }
.table td form.gram-form { display: block; margin: 0; }
.gram-form select { min-width: 11rem; }
.source-link { display: grid; gap: 0.35rem; min-width: 14rem; }
.table td .source-link form { display: flex; flex-wrap: wrap; align-items: center; gap: 0.35rem; margin: 0; }
.source-link select { min-width: 12rem; }
.source-link .button { padding: 0.2rem 0.55rem; font-size: 0.85rem; }
.source-link .button-ghost { border-color: var(--line); color: var(--ink); background: #fff; }
.source-link summary { cursor: pointer; }
.organism-source { display: block; margin-top: 0.15rem; color: var(--muted); font-size: 0.85rem; }
.result-row-actions {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 0.45rem 0.65rem;
}
.result-row-actions form { margin: 0; }
.result-row-actions .button {
  padding: 0.25rem 0.7rem;
  font-size: 0.85rem;
}
.staff-table td { white-space: nowrap; }
.staff-table td form.staff-line,
.staff-table td form {
  display: inline-flex;
  flex-wrap: nowrap;
  align-items: center;
  gap: 0.65rem;
  margin: 0;
}
.staff-table input[name="name"] {
  width: 14rem;
}
.staff-create {
  flex-wrap: nowrap;
  white-space: nowrap;
  align-items: center;
  gap: 0.75rem;
  margin: 0 0 1.5rem;
}
.staff-create label {
  display: inline-flex;
  align-items: center;
  gap: 0.75rem;
  margin: 0;
  font-weight: 600;
}
.staff-create input[name="name"],
.staff-create select,
.staff-create .button {
  height: 2.5rem;
  box-sizing: border-box;
  margin: 0;
}
.staff-create input[name="name"] {
  width: 18rem;
  border-radius: 999px;
  padding: 0 1rem;
}
.staff-create .button {
  padding: 0 1.2rem;
}
.eucast-decisive { color: var(--r); margin-top: 0; }
.eucast-decisive a { color: inherit; }
.eucast-details-open {
  color: inherit;
  font: inherit;
  background: none;
  border: 0;
  padding: 0;
  text-decoration: underline;
  cursor: pointer;
}
.eucast-actions-mark {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 1.85rem;
  height: 1.85rem;
  margin-left: 0.4rem;
  border: 0;
  border-radius: 999px;
  background: var(--r);
  color: #fff;
  font-weight: 700;
  font-size: 1.2rem;
  line-height: 1;
  vertical-align: middle;
  cursor: pointer;
}
.eucast-details {
  width: min(42rem, calc(100vw - 2rem));
  max-height: calc(100vh - 2rem);
  overflow: auto;
  border: 0;
  border-radius: var(--radius);
  padding: 1.25rem 1.4rem 1.4rem;
  color: var(--ink);
  background: var(--card);
  box-shadow: var(--shadow);
}
.eucast-details::backdrop { background: rgba(6, 47, 54, 0.45); }
.eucast-details-head {
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: 1rem;
  margin-bottom: 0.75rem;
}
.eucast-details-head h2 { margin: 0; font-size: 1.15rem; }
.eucast-details-body p { margin: 0 0 0.85rem; }
.eucast-details-body p:last-child { margin-bottom: 0; }
.eucast-logic { white-space: nowrap; min-width: 11rem; }
.eucast-zone { white-space: nowrap; min-width: 8rem; }
tr.eucast-diff td.eucast-changed { background: #fff3d6; }
.eucast-column-filters {
  margin: 0;
  height: 0;
  overflow: hidden;
}
.eucast-compare th.eucast-organism,
.eucast-compare th.eucast-antibiotic,
.eucast-compare th.eucast-version {
  white-space: normal;
}
.eucast-column-filter {
  display: flex;
  flex-direction: column;
  align-items: stretch;
  gap: 0.2rem;
}
.eucast-column-filter > span { white-space: nowrap; }
.eucast-column-filter-control {
  display: grid;
  grid-template-columns: minmax(0, 1fr);
  min-width: 0;
}
.eucast-column-filter select {
  width: 100%;
  min-width: 0;
  max-width: 100%;
  margin: 0;
  padding: 0.1rem 0.15rem;
  font-size: 0.72rem;
  font-weight: 600;
  line-height: 1.2;
}
.eucast-compare-filters {
  display: flex;
  flex-wrap: wrap;
  gap: 0.5rem 0.75rem;
  align-items: center;
  margin-top: 0.5rem;
}
a.eucast-compare-toggle,
a.eucast-compare-toggle.is-active {
  background: var(--s);
  border-color: var(--s);
  color: #fff;
}
a.eucast-compare-toggle.is-active { background: #145c38; border-color: #145c38; }
.eucast-comments { white-space: pre-wrap; max-width: 26rem; font-size: 0.85rem; }
body:has(.eucast-compare) {
  height: 100vh;
  overflow: hidden;
}
.page:has(.eucast-compare) {
  width: calc(100% - 2rem);
  max-width: none;
  min-height: 0;
  margin-top: 0.25rem;
  margin-bottom: 0;
  display: flex;
  flex-direction: column;
  overflow: hidden;
}
.page:has(.eucast-compare) .page-head h1 {
  margin-top: 0;
  margin-bottom: 0.15rem;
}
.page:has(.eucast-compare) .page-head + .muted {
  margin-top: 0.35rem;
}
.eucast-logic-legend {
  display: flex;
  flex-wrap: wrap;
  gap: 0.5rem 0.75rem;
  margin: 0;
}
.eucast-logic-legend span {
  display: inline-block;
  padding: 0.4rem 0.7rem;
  border-radius: 8px;
  font-size: 0.85rem;
  line-height: 1.35;
}
.eucast-logic-0 { background: #fde8e6; color: #8a2b22; }
.eucast-logic-1 { background: #e7f1fb; color: #1d4f86; }
.eucast-logic-2 { background: #e5f6ec; color: #1d6b45; }
.eucast-logic-3 { background: #fff3d6; color: #8a5a00; }
.eucast-compare-scroll {
  flex: 1;
  min-height: 0;
  overflow: auto;
}
.table.eucast-compare {
  width: 100%;
  overflow: visible;
  border-collapse: separate;
  border-spacing: 0;
}
.eucast-compare thead {
  position: sticky;
  top: 0;
  z-index: 2;
}
.eucast-compare thead th {
  background: #fff;
  box-shadow: inset 0 -2px 0 #5c757b;
}
.eucast-compare tbody td {
  border-bottom: 2px solid #5c757b;
}
.eucast-compare tr.eucast-compare-sizer {
  height: 0;
}
.eucast-compare tr.eucast-compare-sizer td {
  height: 0;
  padding-top: 0;
  padding-bottom: 0;
  border-bottom: 0;
  line-height: 0;
  overflow: hidden;
  color: transparent;
}
.eucast-compare tr.eucast-compare-sizer .eucast-adopt {
  height: 0;
  padding-top: 0;
  padding-bottom: 0;
  border-top-width: 0;
  border-bottom-width: 0;
  overflow: hidden;
  visibility: hidden;
}
.eucast-compare thead .eucast-side {
  background: #fff;
  border-bottom: 0;
  box-shadow: none;
}
.eucast-adopt-actions {
  display: flex;
  flex-wrap: nowrap;
  gap: 0.45rem;
  align-items: flex-start;
}
.table.eucast-compare .eucast-adopt-actions form { display: block; margin: 0; }
.eucast-compare .eucast-adopt {
  display: inline-block;
  padding: 0.35rem 0.7rem;
  font-size: 0.8rem;
  line-height: 1.25;
  text-align: center;
  white-space: nowrap;
}
.eucast-compare .eucast-adopt-keep {
  max-width: none;
  white-space: nowrap;
  text-align: center;
}
tr.eucast-adopted td,
tr.eucast-adopted td.eucast-changed,
tr.eucast-adopted .eucast-comment-edit textarea { background: #e5f6ec; }
.eucast-adopted-note {
  display: block;
  margin-top: 0.3rem;
  font-size: 0.75rem;
  font-weight: 700;
  color: #1d6b45;
}
.eucast-compare th,
.eucast-compare td { vertical-align: top; }
.eucast-compare td {
  padding-top: 0.08rem;
  padding-bottom: 0.08rem;
  line-height: 1.2;
}
.eucast-compare .eucast-organism,
.eucast-compare .eucast-antibiotic {
  width: 1%;
  white-space: nowrap;
}
.eucast-compare .eucast-version,
.eucast-compare .eucast-logic,
.eucast-compare .eucast-zone {
  font-size: 0.72rem;
  line-height: 1.2;
  white-space: nowrap;
  width: 1%;
  min-width: 0;
  padding-left: 0.3rem;
  padding-right: 0.3rem;
}
.eucast-compare thead tr:nth-child(2) th {
  font-size: 0.8rem;
  font-weight: 600;
  line-height: 1.2;
  vertical-align: middle;
  padding: 0.4rem 0.45rem;
}
.eucast-compare .eucast-side { text-align: center; background: #fff; }
.eucast-compare .eucast-side-new { border-left: 2px solid var(--line); }
.eucast-compare .eucast-comments {
  max-width: 18rem;
  font-size: 0.75rem;
  line-height: 1.35;
  color: var(--muted);
}
.eucast-compare td.eucast-comments:has(.eucast-comment-edit) {
  white-space: normal;
  line-height: 0;
}
.table.eucast-compare .eucast-comment-edit {
  display: flex;
  flex-direction: row;
  align-items: flex-start;
  gap: 0.3rem;
  margin: 0;
  min-width: 0;
}
.eucast-compare .eucast-comment-edit textarea {
  flex: 1;
  width: 100%;
  min-width: 0;
  min-height: 0;
  margin: 0;
  padding: 0.05rem 0.35rem;
  border: 1px solid var(--line);
  border-radius: 6px;
  background: #fff;
  color: var(--ink);
  font: inherit;
  font-size: 0.75rem;
  line-height: 1.25;
  field-sizing: content;
  resize: vertical;
}
.eucast-compare .eucast-comment-save {
  flex: 0 0 auto;
  width: 1.2rem;
  height: 1.2rem;
  padding: 0;
  border-radius: 6px;
}
.eucast-compare .eucast-comment-save svg {
  width: 0.85rem;
  height: 0.85rem;
  display: block;
}
.table td.files { vertical-align: top; min-width: 14rem; }
.file-list { list-style: none; margin: 0 0 0.5rem; padding: 0; display: grid; gap: 0.45rem; }
.file-list li { font-size: 0.85rem; display: flex; flex-wrap: wrap; align-items: center; gap: 0.35rem 0.6rem; }
.file-mail { display: inline; margin: 0; }
.file-mail .button { padding: 0.2rem 0.65rem; font-size: 0.8rem; }
.file-upload { display: flex; flex-wrap: wrap; gap: 0.4rem; align-items: center; }
.file-upload input[type="file"] { max-width: 14rem; }
.flash { padding: 0.7rem 0.9rem; border-radius: 10px; margin-bottom: 1rem; }
.flash-success { background: #e7f6ee; }
.flash-error { background: #fde8e6; }
.flash-warn { background: #fff6e0; border: 1px solid #e6d39a; }
.flash-warn p { margin: 0 0 0.45rem; }
.flash-warn p:last-child { margin-bottom: 0; }
.flash-warn ul { margin: 0.35rem 0 0; padding-left: 1.15rem; }
.button-row { display: flex; flex-wrap: wrap; gap: 0.5rem; align-items: center; margin: 0; }
.stack { display: grid; gap: 0.75rem; max-width: 32rem; }
.stack-wide { max-width: 48rem; }
.var-list { font-size: 0.85rem; }
.var-list ul { margin: 0.2rem 0 0; padding-left: 1.1rem; }
.var-list li { margin: 0.15rem 0; }
.var-list code { font-size: 0.8rem; }
.form-grid { max-width: 48rem; grid-template-columns: 1fr 1fr; }
.form-grid .full { grid-column: 1 / -1; }
.card .page-head h2, .card > h2 { margin-top: 0; }
label { display: grid; gap: 0.25rem; font-size: 0.9rem; }
.filter-field { display: grid; gap: 0.25rem; font-size: 0.9rem; }
.filter-field > label { display: block; }
.eucast-without-rules { margin: 0.75rem 0; }
.eucast-actions { white-space: nowrap; width: 1%; }
.eucast-actions-links {
  display: flex;
  flex-direction: column;
  align-items: flex-start;
  gap: 0.15rem;
}
.table td.eucast-actions form { display: block; margin: 0; }
.eucast-actions-links .linkish {
  appearance: none;
  margin: 0;
  padding: 0;
  border: 0;
  line-height: inherit;
  text-align: left;
  font-weight: 400;
  color: var(--accent);
}
#capture-step-start label strong,
.capture-summary label strong { font-weight: 700; }
input, select, textarea {
  font: inherit;
  padding: 0.45rem 0.55rem;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: #fff;
}
.check { display: flex; align-items: flex-start; gap: 0.4rem; }
.keimzahl-options {
  margin: 0;
  padding: 0.75rem 0 0;
  border: 0;
  display: grid;
  gap: 0.4rem;
}
.keimzahl-options legend { font-weight: 600; padding: 0; }
.keimzahl-hint {
  margin: 0.25rem 0 0;
  font-size: 0.72rem;
  font-weight: 400;
  line-height: 1.35;
  max-width: 36rem;
}
.muted { color: var(--muted); }
.capture-staff-block { display: grid; gap: 0.25rem; margin-top: 1.25em; }
.capture-staff-block .muted { margin: 0; font-size: 0.82rem; }
#panel-empty { margin: 0.35rem 0 0.2rem; }
#panel-empty[hidden] { display: none; }
.capture-ids {
  display: flex;
  flex-direction: column;
  align-items: flex-start;
  gap: 1.25em;
  margin: 1.25em 0 0.6rem;
}
.capture-ids #patient-id { width: 14rem; }
.capture-ids label:has(#organism-search) { width: min(36rem, 100%); }
.capture-ids #organism-search { width: 100%; }
#keimzahl {
  width: 5.4rem;
  min-width: 5.4rem;
  max-width: 5.4rem;
  padding-left: 0.3rem;
  padding-right: 0.2rem;
}
.capture-title .capture-control { display: contents; }
.capture-control { display: grid; }
#capture-start-head[hidden],
#capture-step-start[hidden],
#capture-step-resist[hidden] { display: none !important; }
.capture-summary-wrap { margin: 0 0 1.1rem; }
.capture-summary {
  display: flex;
  flex-wrap: wrap;
  align-items: flex-end;
  gap: 0.85rem 1.15rem;
  margin: 0;
  padding: 0.9rem 1rem;
  background: #fff;
  border: 1px solid var(--line);
  border-radius: var(--radius);
  box-shadow: var(--shadow);
}
.capture-summary-edit-hint {
  margin: 0.4rem 0 0;
  padding: 0 0.15rem;
  font-size: 0.78rem;
}
.capture-summary-edit-hint + .capture-summary-edit-hint { margin-top: 0.35rem; }
.capture-summary label {
  display: grid;
  gap: 0.25rem;
  font-size: 0.9rem;
  font-weight: 600;
}
.capture-summary [data-capture-slot] { display: grid; }
.capture-summary .capture-title-date {
  font-size: 1rem;
  font-weight: 400;
  letter-spacing: 0;
  line-height: 1.5;
  padding: 0.45rem 0.55rem;
  height: auto;
}
.capture-summary #staff-search,
.capture-summary #organism-search { width: min(18rem, 100%); }
.capture-summary #patient-id { width: 14rem; }
.capture-keim-pair {
  display: flex;
  flex-wrap: nowrap;
  align-items: flex-end;
  gap: 0.85rem 1.15rem;
  min-width: 0;
}
.capture-summary-keimzahl {
  width: auto;
  flex: 0 0 auto;
}
.capture-summary .keimzahl-hint { display: none; }
.capture-suggest {
  position: fixed;
  z-index: 80;
  max-height: 14rem;
  overflow: auto;
  margin: 0;
  padding: 0.25rem 0;
  list-style: none;
  background: #fff;
  border: 1px solid var(--line);
  border-radius: 8px;
  box-shadow: var(--shadow);
}
.capture-suggest[hidden] { display: none; }
.capture-suggest button {
  display: block;
  width: 100%;
  margin: 0;
  padding: 0.35rem 0.65rem;
  border: 0;
  border-radius: 0;
  background: transparent;
  color: var(--ink);
  text-align: left;
  cursor: pointer;
}
.capture-suggest button:hover,
.capture-suggest button.is-active {
  background: #e4f3f4;
}
.tag { display: inline-block; background: #e7f1f2; border-radius: 999px; padding: 0.05rem 0.45rem; font-size: 0.75rem; }
.facts { display: grid; grid-template-columns: repeat(auto-fit, minmax(12rem, 1fr)); gap: 0.6rem; }
.facts dt { color: var(--muted); font-size: 0.8rem; }
.facts dd { margin: 0; font-weight: 600; }
.facts dd input,
.facts dd select { width: 100%; max-width: 16rem; font-weight: 600; }
.result-sir { display: inline-flex; vertical-align: middle; margin-right: 0.45rem; }
.result-word { font-weight: 600; }
.result-save { margin: 1rem 0 0; }
.site-footer {
  border-top: 1px solid var(--line);
  padding: 0.8rem 1rem;
  display: flex;
  justify-content: space-between;
  gap: 1rem;
  color: var(--muted);
  font-size: 0.85rem;
  width: min(1120px, calc(100% - 2rem));
  margin: 0 auto;
}
.auth-body {
  display: grid;
  place-items: center;
  background: var(--hero);
}
.auth-card {
  width: min(28rem, calc(100% - 2rem));
  background: #fff;
  padding: 1.5rem;
  border-radius: 18px;
}
.auth-card input { font-size: 1rem; }
.password-field {
  display: grid;
  grid-template-columns: 1fr auto;
  gap: 0.25rem 0.4rem;
  align-items: stretch;
}
.password-field > label {
  grid-column: 1 / -1;
  display: block;
}
.password-field input { min-width: 0; width: 100%; }
.password-toggle {
  padding: 0.45rem 0.75rem;
  white-space: nowrap;
}
.ab-toolbar {
  display: flex;
  flex-wrap: wrap;
  gap: 0.6rem 1rem;
  align-items: center;
  justify-content: space-between;
  margin: 0.4rem 0 0.6rem;
}
.ab-toolbar .muted { margin: 0; max-width: 38rem; }
.ab-toolbar-actions {
  display: flex;
  flex-wrap: wrap;
  gap: 0.5rem 0.75rem;
  align-items: center;
}
.ab-table-row {
  display: flex;
  align-items: flex-start;
  gap: 1.25rem 1.5rem;
  width: 100%;
}
.ab-table-side {
  display: flex;
  flex-direction: column;
  align-items: flex-start;
  gap: 0.75rem;
  flex: 1 1 auto;
  min-width: 12rem;
  padding-top: 0.35rem;
}
.ab-table-hint {
  margin: 0;
  font-size: 0.9rem;
}
.ab-table-hint[hidden] { display: none !important; }
.ab-progress {
  margin: 0;
  font-size: 0.9rem;
}
.ab-progress:empty,
.ab-progress[hidden] { display: none !important; }
.ab-sort-toggle {
  flex-direction: column;
  align-items: center;
  gap: 0.15rem;
  line-height: 1.25;
  text-align: center;
  padding: 0.45rem 0.95rem 0.4rem;
  margin-top: 1rem;
  background: #e7f4f5;
  border-color: #c5dfe2;
}
.ab-sort-toggle:hover {
  background: #d9eef0;
  border-color: var(--accent);
}
.ab-sort-click-hint {
  margin: 0;
  font-size: 0.75rem;
  font-weight: 400;
  color: var(--muted);
  line-height: 1.3;
}
.ab-sort-click-hint[hidden] { display: none !important; }
.ab-sort-mode-hint {
  margin: 1rem 0 0.45rem;
  font-size: 0.82rem;
}
.ab-sort-mode-hint[hidden] { display: none !important; }
.ab-sort-mode-hint:not([hidden]) + .ab-sort-toggle { margin-top: 0; }
.ab-list.is-sorting .sir-btns button {
  pointer-events: none;
  cursor: default;
}
.ab-list {
  flex: 0 0 auto;
  width: max-content;
  max-width: 100%;
  max-height: min(70vh, 44rem);
  overflow: auto;
  background: #fff;
  border: 1px solid var(--line);
  border-radius: var(--radius);
  padding: 0 0.7rem;
}
.ab-head,
.ab-row {
  position: relative;
  display: grid;
  grid-template-columns: max-content auto;
  gap: 0.5rem 1rem;
  align-items: center;
  padding: 0.28rem 0.1rem;
  border-bottom: 1px solid var(--line);
  background: #fff;
}
.ab-list.is-sorting .ab-head,
.ab-list.is-sorting .ab-row {
  grid-template-columns: auto max-content auto;
}
.ab-head {
  position: sticky;
  top: 0;
  z-index: 8;
  background: #eef5f6;
  font-size: 0.72rem;
  font-weight: 700;
  color: var(--muted);
  text-transform: uppercase;
  letter-spacing: 0.05em;
}
.ab-head-sir span {
  width: 2.2rem;
  height: 2.2rem;
  display: inline-flex;
  align-items: center;
  justify-content: center;
}
.ab-row.is-current {
  background: #e8f4f5;
  box-shadow: inset 3px 0 0 var(--accent);
}
.ab-row.is-done:not(.is-current) .ab-name {
  color: var(--muted);
}
.ab-row--hint:has(.ab-info-wrap:hover),
.ab-row--hint:has(.ab-info-wrap:focus-within) {
  z-index: 5;
}
.ab-label {
  display: flex;
  align-items: center;
  flex-wrap: wrap;
  gap: 0.3rem 0.4rem;
  min-width: 0;
}
.ab-exclude {
  margin: 0;
  padding: 0;
  border: 0;
  background: transparent;
  color: var(--muted);
  text-decoration: underline;
  cursor: pointer;
  font: inherit;
  font-size: 0.78rem;
}
.ab-list.is-sorting .ab-exclude { display: none; }
.ab-info-wrap {
  position: relative;
  display: inline-flex;
  align-items: center;
}
.ab-info {
  width: 1.15rem;
  height: 1.15rem;
  padding: 0;
  border-radius: 50%;
  border: 1px solid var(--accent);
  background: #fff;
  color: var(--accent);
  font-size: 0.72rem;
  font-weight: 700;
  font-style: italic;
  line-height: 1;
  cursor: help;
}
.ab-info:hover,
.ab-info:focus {
  background: var(--accent);
  color: #fff;
  outline: none;
}
.ab-tip {
  display: none;
  position: absolute;
  left: 0;
  top: calc(100% + 0.35rem);
  z-index: 40;
  width: max-content;
  max-width: min(32rem, 70vw);
  padding: 0.65rem 0.8rem;
  background: #12353a;
  color: #f4fbfb;
  border-radius: 10px;
  font-size: 0.82rem;
  font-style: normal;
  font-weight: 400;
  line-height: 1.45;
  text-align: left;
  box-shadow: 0 12px 28px rgba(6, 47, 54, 0.18);
  pointer-events: none;
}
.ab-tip p {
  margin: 0 0 0.45rem;
}
.ab-tip p:last-child {
  margin-bottom: 0;
}
.ab-info-wrap:hover .ab-tip,
.ab-info-wrap:focus-within .ab-tip {
  display: block;
}
.ab-row.is-dragging { opacity: 0.55; }
.ab-sort {
  display: none;
  align-items: center;
  gap: 0.15rem;
}
.ab-list.is-sorting .ab-sort { display: flex; }
.ab-handle {
  width: 1.6rem;
  height: 2.2rem;
  border: 0;
  background: transparent;
  color: var(--muted);
  cursor: grab;
  font-size: 1.1rem;
  line-height: 1;
}
.ab-handle:active { cursor: grabbing; }
.ab-move { display: flex; flex-direction: column; gap: 0.15rem; }
.ab-move button {
  width: 1.7rem;
  height: 1.1rem;
  padding: 0;
  border-radius: 5px;
  border: 1px solid var(--line);
  background: #fff;
  color: var(--ink);
  cursor: pointer;
  font-size: 0.65rem;
  line-height: 1;
}
.ab-zone {
  font-size: 0.78rem;
  color: var(--muted);
  line-height: 1.35;
  white-space: nowrap;
  min-width: 0;
  text-align: right;
}
.ab-actions {
  display: flex;
  align-items: center;
  justify-content: flex-end;
  gap: 0.75rem;
}
.sir-btns { display: flex; gap: 0.35rem; }
.sir-btns button:focus-visible {
  outline: 2px solid var(--accent);
  outline-offset: 1px;
}
.sir-btns button:disabled {
  opacity: 0.35;
  cursor: default;
}
.sir-btns button {
  width: 2.2rem;
  height: 2.2rem;
  border-radius: 8px;
  border: 1px solid var(--line);
  background: #fff;
  cursor: pointer;
  font-weight: 700;
}
.sir-btns button.is-s, .sir.sir-S { background: var(--s); color: #fff; border-color: var(--s); }
.sir-btns button.is-i, .sir.sir-I { background: var(--i); color: #fff; border-color: var(--i); }
.sir-btns button.is-r, .sir.sir-R { background: var(--r); color: #fff; border-color: var(--r); }
.sir { display: inline-block; min-width: 1.4rem; text-align: center; border-radius: 4px; font-weight: 700; }
.bar { display: flex; height: 10px; background: #edf3f4; border-radius: 99px; overflow: hidden; min-width: 8rem; }
.bar-s { background: var(--s); display: block; }
.bar-i { background: var(--i); display: block; }
.bar-r { background: var(--r); display: block; }
.chip-list { display: flex; flex-wrap: wrap; gap: 0.35rem 0.8rem; }
.copy-box {
  display: grid;
  justify-items: start;
  gap: 0.75rem;
  margin-bottom: 1rem;
}
.copy-box p { margin: 0; }
.copy-box textarea {
  width: 100%;
  min-width: 0;
  box-sizing: border-box;
  resize: vertical;
}
.copy-preview {
  width: 100%;
  min-width: 0;
  box-sizing: border-box;
  padding: 0.65rem 0.75rem;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: #fff;
  font: inherit;
  line-height: 1.45;
}
.page:has(#copy-template-form) {
  width: calc(100% - 2rem);
}
.copy-template-form.stack {
  max-width: none;
  width: 100%;
}
.copy-template-lead {
  max-width: none;
  white-space: nowrap;
}
.copy-template-split {
  display: grid;
  grid-template-columns: minmax(0, 1fr) minmax(0, 1fr);
  gap: 1.25rem;
  align-items: stretch;
  width: 100%;
}
.copy-template-pane {
  display: grid;
  gap: 0.35rem;
  min-width: 0;
}
.copy-template-pane .muted { margin: 0; }
.copy-template-editor-wrap,
.copy-template-preview {
  min-height: min(28rem, calc(100vh - 16rem));
  height: 100%;
}
.copy-template-editor-wrap {
  display: grid;
  grid-template-columns: auto minmax(0, 1fr);
  align-items: stretch;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: #fff;
  overflow: auto;
}
.copy-template-editor-wrap:focus-within {
  border-color: var(--accent);
}
.copy-template-lines {
  display: flex;
  flex-direction: column;
  margin: 0;
  padding: 0.65rem 0.55rem 0.65rem 0.65rem;
  border-right: 1px solid var(--line);
  background: var(--paper);
  color: var(--muted);
  line-height: 1.5;
  user-select: none;
  pointer-events: none;
  white-space: nowrap;
  font-variant-numeric: tabular-nums;
}
.copy-template-lines span {
  display: flex;
  align-items: flex-start;
  justify-content: flex-end;
  min-height: 1.5em;
}
.copy-template-toolbar {
  display: flex;
  flex-wrap: wrap;
  gap: 0.4rem 0.75rem;
  align-items: center;
}
.copy-template-group {
  display: flex;
  flex-wrap: wrap;
  gap: 0.4rem;
  align-items: center;
}
.copy-template-label {
  color: var(--muted);
  font-weight: 600;
  white-space: nowrap;
}
.copy-template-editor {
  min-height: min(28rem, calc(100vh - 16rem));
  padding: 0.65rem 0.75rem;
  border: 0;
  border-radius: 0;
  background: #fff;
  line-height: 1.5;
  white-space: pre-wrap;
  outline: none;
  user-select: text;
  -webkit-user-select: text;
}
.copy-token {
  display: inline-block;
  padding: 0.05rem 0.35rem;
  border-radius: 999px;
  background: #e4f3f4;
  font-family: ui-monospace, Consolas, monospace;
  font-size: 0.88em;
  font-weight: 600;
  user-select: all;
  -webkit-user-select: all;
  cursor: pointer;
}
.copy-template-preview { background: #f7fbfb; }
.copy-box-actions {
  display: flex;
  flex-wrap: wrap;
  gap: 0.5rem 0.75rem;
}
.copy-done {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  max-width: 100%;
  box-sizing: border-box;
  border-radius: 999px;
  padding: 0.45rem 0.95rem;
  margin: -0.25rem 0 1rem;
  background: var(--s);
  color: #fff;
  font-weight: 600;
  line-height: 1.4;
  text-align: left;
}
.copy-done[hidden] { display: none !important; }
.page-head-title .copy-done { margin: 0; }
.section { margin-top: 1rem; }
details.card summary { cursor: pointer; font-weight: 600; }
@media (max-width: 800px) {
  .password-field { grid-template-columns: 1fr; }
  .password-toggle { justify-self: start; }
  .form-grid { grid-template-columns: 1fr; }
  .topbar-inner, .webmaster-inner { flex-wrap: wrap; }
  .webmaster-title { white-space: normal; }
  .ab-table-row { flex-wrap: wrap; }
  .ab-table-side { flex-basis: 100%; }
  .ab-head, .ab-row,
  .ab-list.is-sorting .ab-head,
  .ab-list.is-sorting .ab-row { grid-template-columns: auto minmax(0, 1fr); }
  .ab-head .ab-actions, .ab-row .ab-actions { grid-column: 1 / -1; }
  .ab-tip { max-width: min(32rem, calc(100vw - 3rem)); }
  .copy-template-split { grid-template-columns: 1fr; }
}
.visually-hidden {
  position: absolute;
  width: 1px;
  height: 1px;
  padding: 0;
  margin: -1px;
  overflow: hidden;
  clip: rect(0, 0, 0, 0);
  white-space: nowrap;
  border: 0;
}
