/* Erste Hilfe for you – Stylesheet (seriös, Logo-Türkis auf Nachtblau) */

/* Schrift: Plus Jakarta Sans, lokal eingebunden (keine Verbindung zu Google) */
@font-face { font-family: "Jakarta"; font-weight: 400; font-display: swap; src: url("fonts/jakarta-400.woff2") format("woff2"); unicode-range: U+0000-00FF, U+0131, U+0152-0153, U+02BB-02BC, U+02C6, U+02DA, U+02DC, U+2000-206F, U+20AC, U+2122, U+2191, U+2193, U+2212, U+2215, U+FEFF, U+FFFD; }
@font-face { font-family: "Jakarta"; font-weight: 600; font-display: swap; src: url("fonts/jakarta-600.woff2") format("woff2"); unicode-range: U+0000-00FF, U+0131, U+0152-0153, U+02BB-02BC, U+02C6, U+02DA, U+02DC, U+2000-206F, U+20AC, U+2122, U+2191, U+2193, U+2212, U+2215, U+FEFF, U+FFFD; }
@font-face { font-family: "Jakarta"; font-weight: 800; font-display: swap; src: url("fonts/jakarta-800.woff2") format("woff2"); unicode-range: U+0000-00FF, U+0131, U+0152-0153, U+02BB-02BC, U+02C6, U+02DA, U+02DC, U+2000-206F, U+20AC, U+2122, U+2191, U+2193, U+2212, U+2215, U+FEFF, U+FFFD; }
@font-face { font-family: "Jakarta"; font-weight: 400; font-display: swap; src: url("fonts/jakarta-ext-400.woff2") format("woff2"); unicode-range: U+0100-02AF, U+0304, U+0308, U+0329, U+1E00-1EFF, U+20A0-20AB, U+20AD-20CF, U+2C60-2C7F, U+A720-A7FF; }
@font-face { font-family: "Jakarta"; font-weight: 600; font-display: swap; src: url("fonts/jakarta-ext-600.woff2") format("woff2"); unicode-range: U+0100-02AF, U+0304, U+0308, U+0329, U+1E00-1EFF, U+20A0-20AB, U+20AD-20CF, U+2C60-2C7F, U+A720-A7FF; }
@font-face { font-family: "Jakarta"; font-weight: 800; font-display: swap; src: url("fonts/jakarta-ext-800.woff2") format("woff2"); unicode-range: U+0100-02AF, U+0304, U+0308, U+0329, U+1E00-1EFF, U+20A0-20AB, U+20AD-20CF, U+2C60-2C7F, U+A720-A7FF; }

:root {
  --ink: #0a2a35;
  --ink-2: #125066;
  --muted: #4f6b76;
  --line: #d9ecec;
  --soft: #f1f7f8;
  --blue: #04679a;
  --aid: #29b4b6;          /* Türkis aus dem Logo – Schrift darauf immer dunkel (--ink) */
  --aid-dark: #0b7b7f;     /* Türkis für Text auf hellem Grund */
  --aid-light: #dcf5f4;
  --aid-bright: #7ce6e1;   /* auf dunklem Grund */
  --signal: #ff5a3c;
  --signal-light: #fff0eb;
  --danger: #c0392b;
  --danger-light: #fdecea;
  --ok: #17845a;
  --ok-light: #e6f5ee;
  --warn-light: #fff5dc;
  --radius: 14px;
  --font: "Jakarta", "Avenir Next", "Segoe UI", system-ui, -apple-system, Roboto, Arial, sans-serif;
}

* { box-sizing: border-box; -webkit-tap-highlight-color: transparent; }
html { scroll-behavior: smooth; }
body {
  margin: 0; font-family: var(--font); color: var(--ink); background: #fff;
  line-height: 1.55; font-size: 17px; display: flex; flex-direction: column; min-height: 100vh;
  -webkit-font-smoothing: antialiased; overflow-x: hidden;
}
main { flex: 1; }
img { max-width: 100%; height: auto; }
a { color: var(--blue); text-underline-offset: 3px; }
a:hover { color: var(--aid-dark); }
h1, h2, h3 { color: var(--ink); line-height: 1.05; margin: 0 0 .5em; font-weight: 800; letter-spacing: -.035em; }
h1 { font-size: clamp(2.2rem, 6vw, 3.4rem); }
h2 { font-size: clamp(1.8rem, 5vw, 2.8rem); }
h3 { font-size: 1.2rem; letter-spacing: -.02em; }
p { margin: 0 0 1em; }
strong { font-weight: 800; }
::selection { background: var(--aid); color: var(--ink); }

.container { width: 100%; max-width: 1120px; margin: 0 auto; padding: 0 18px; }
.section { padding: 80px 0; }
@media (max-width: 640px) { .section { padding: 56px 0; } }
.section-soft { background: var(--soft); }
.lead { font-size: 1.12rem; color: var(--muted); max-width: 620px; }
.center { text-align: center; }
.center .lead { margin-left: auto; margin-right: auto; }
.muted { color: var(--muted); }
.small { font-size: .9rem; }
.accent { color: var(--aid); }
.kicker { display: inline-flex; align-items: center; gap: 10px; font-size: .78rem; font-weight: 800; color: var(--aid-dark); background: var(--aid-light); padding: 6px 14px 6px 8px; border-radius: 99px; margin-bottom: 16px; }
.kicker::before { content: ""; width: 18px; height: 18px; border-radius: 4px; background: var(--aid) url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 10 10'%3E%3Cpath d='M4 1.5h2v2.5h2.5v2H6v2.5H4V6H1.5V4H4z' fill='white'/%3E%3C/svg%3E") center/14px no-repeat; }

/* Erste-Hilfe-Zeichen: weißes Kreuz auf grünem Feld (kein rotes Kreuz – das ist geschützt) */
.sign { display: inline-grid; place-items: center; width: 1em; height: 1em; background: var(--aid); border-radius: .18em; flex-shrink: 0; }
.sign::before { content: ""; width: .62em; height: .62em; background: #fff;
  clip-path: polygon(35% 0, 65% 0, 65% 35%, 100% 35%, 100% 65%, 65% 65%, 65% 100%, 35% 100%, 35% 65%, 0 65%, 0 35%, 35% 35%); }

/* Rettungsstreifen wie am Rettungswagen */
.stripes { height: 6px; background: linear-gradient(90deg, var(--aid), var(--aid-bright), var(--blue)); }

/* Kopf */
.site-header { position: sticky; top: 0; z-index: 50; background: rgba(255,255,255,.94); backdrop-filter: saturate(1.4) blur(10px); }
.site-header .container { display: flex; align-items: center; justify-content: space-between; gap: 16px; min-height: 68px; }
.site-header .stripes { height: 4px; }
.brand { display: block; width: 140px; }
.brand span { display: block; }
.nav { display: flex; gap: 2px; align-items: center; flex-wrap: wrap; }
.nav a { text-decoration: none; color: var(--ink); font-weight: 600; font-size: .93rem; padding: 8px 12px; border-radius: 999px; }
.nav a:hover { color: var(--aid-dark); background: var(--soft); }
.nav a.active { color: var(--ink); background: var(--aid-light); }
.nav a.nav-cta { background: var(--aid); color: var(--ink); font-weight: 800; margin-left: 8px; padding: 10px 18px; border-radius: 999px; }
.nav a.nav-cta:hover { background: var(--ink); color: #fff; }
.nav-toggle { display: none; background: var(--soft); border: 2px solid var(--line); border-radius: 12px; padding: 9px 15px; font: inherit; font-weight: 800; color: var(--ink); cursor: pointer; }
@media (max-width: 980px) {
  .nav-toggle { display: block; }
  .nav { display: none; position: absolute; left: 0; right: 0; top: 100%; background: #fff; border-bottom: 1px solid var(--line); flex-direction: column; align-items: stretch; padding: 8px 18px 18px; box-shadow: 0 20px 40px rgba(10,37,64,.08); }
  .nav.open { display: flex; }
  .nav a { padding: 13px 12px; font-size: 1.05rem; }
  .nav a.nav-cta { margin: 8px 0 0; text-align: center; }
  .brand { width: 120px; }
}

/* Unterseiten-Kopf */
.page-head { background: linear-gradient(135deg, var(--aid), var(--aid-bright)); padding: 52px 0 56px; border-radius: 0 0 36px 36px; }
.page-head h1 { font-size: clamp(2.3rem, 7vw, 3.8rem); letter-spacing: -.05em; margin-bottom: 12px; }
.page-head .lead { margin-bottom: 0; color: var(--ink); }
@media (max-width: 640px) { .page-head { padding: 36px 0 34px; } }
.prose { max-width: 760px; }
.prose h2 { margin-top: 1.6em; font-size: 1.6rem; }

/* Knöpfe */
.btn {
  display: inline-flex; align-items: center; justify-content: center; gap: 8px;
  padding: 14px 26px; border-radius: 999px; border: 2px solid var(--aid); background: var(--aid); color: var(--ink);
  font: inherit; font-weight: 800; font-size: 1rem; text-decoration: none; cursor: pointer;
  transition: transform .15s, background .15s, border-color .15s, color .15s;
}
.btn:hover { background: var(--ink); border-color: var(--ink); color: #fff; transform: translateY(-2px); }
.btn:active { transform: scale(.97); }
.btn-outline, .btn-ghost { background: transparent; border-color: var(--line); color: var(--ink); }
.btn-outline:hover, .btn-ghost:hover { background: var(--soft); border-color: var(--line); color: var(--ink); }
.btn-danger { background: var(--danger); border-color: var(--danger); color: #fff; }
.btn-danger:hover { background: #9c2e22; border-color: #9c2e22; }
.btn-sm { padding: 8px 14px; font-size: .86rem; }
.btn[disabled] { opacity: .5; cursor: not-allowed; transform: none; }
.btn-row { display: flex; gap: 12px; flex-wrap: wrap; align-items: center; }
.arrow::after { content: "→"; transition: transform .15s; }
.btn:hover.arrow::after { transform: translateX(3px); }

/* Hauptaktion – .btn-teal bleibt als Name erhalten */
.plaster, .btn-teal {
  display: inline-flex; align-items: center; justify-content: center; gap: 10px;
  text-decoration: none; color: #fff; background: var(--ink); padding: 15px 32px; border-radius: 999px; border: 2px solid var(--ink);
  font: inherit; font-weight: 800; cursor: pointer; transition: transform .2s, background .2s;
}
.plaster:hover, .btn-teal:hover { transform: rotate(-2deg) scale(1.04); color: #fff; background: var(--ink-2); border-color: var(--ink-2); }
.btn-teal.btn-sm { padding: 9px 20px; }

/* Karten */
.grid { display: grid; gap: 20px; }
.grid-3 { grid-template-columns: repeat(3, 1fr); }
.grid-2 { grid-template-columns: repeat(2, 1fr); }
@media (max-width: 820px) { .grid-3, .grid-2 { grid-template-columns: 1fr; } }
.card { background: #fff; border: 2px solid var(--line); border-radius: var(--radius); padding: 26px; transition: transform .2s, border-color .2s; }
.card h3 { margin-top: 0; }
.card-hover:hover { transform: translateY(-4px); border-color: var(--aid); box-shadow: 0 16px 34px rgba(41,180,182,.18); }
.icon { width: 48px; height: 48px; border-radius: 14px; display: grid; place-items: center; background: var(--aid-light); color: var(--aid-dark); margin-bottom: 16px; }
.icon svg { width: 26px; height: 26px; }

/* Preise */
.price-card { display: flex; flex-direction: column; }
.price-card.featured { background: var(--ink); border-color: var(--ink); color: #c9d8e4; position: relative; overflow: hidden; }
.price-card.featured h3, .price-card.featured .price { color: #fff; }
.price-card .h-sym { margin-bottom: 14px; }
.price-card.featured .checklist li { border-color: rgba(255,255,255,.12); }
.price-card .badge-top { position: absolute; top: 20px; right: -44px; transform: rotate(35deg); width: 180px; text-align: center; font-size: .7rem; font-weight: 800; letter-spacing: .1em; text-transform: uppercase; color: var(--ink); background: var(--aid-bright); padding: 6px 0; }
.price { font-size: 3.6rem; font-weight: 800; color: var(--ink); line-height: 1; margin: 6px 0 22px; letter-spacing: -.06em; }
.price small { font-size: 1.4rem; letter-spacing: 0; }
.price-row { display: flex; justify-content: space-between; align-items: center; gap: 16px; }
.price-row .price { margin: 0; font-size: 2.4rem; }
.checklist { list-style: none; padding: 0; margin: 0 0 26px; flex: 1; }
.checklist li { padding: 9px 0 9px 32px; position: relative; border-bottom: 1px solid var(--line); }
.checklist li:last-child { border-bottom: none; }
.checklist li::before { content: ""; position: absolute; left: 0; top: 13px; width: 20px; height: 20px; border-radius: 5px; background: var(--aid) url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 10 10'%3E%3Cpath d='M4 1.5h2v2.5h2.5v2H6v2.5H4V6H1.5V4H4z' fill='white'/%3E%3C/svg%3E") center/15px no-repeat; }

/* Hinweise */
.notice { border-radius: 16px; padding: 18px 22px; margin: 0 0 22px; border-left: 5px solid var(--aid); background: var(--aid-light); }
.notice-warn { border-left-color: #e0a100; background: var(--warn-light); }
.notice-danger { border-left-color: var(--danger); background: var(--danger-light); }
.notice-ok { border-left-color: var(--ok); background: var(--ok-light); }
.notice p:last-child { margin-bottom: 0; }

/* Terminliste */
.course-list { display: grid; gap: 10px; margin-bottom: 36px; }
.course-option { position: relative; }
.course-option input { position: absolute; opacity: 0; pointer-events: none; width: 1px; height: 1px; }
.course-option label { display: flex; align-items: center; justify-content: space-between; gap: 16px; flex-wrap: wrap; border: 2px solid var(--line); border-radius: 18px; padding: 15px 18px; cursor: pointer; background: #fff; transition: border-color .15s, background .15s; }
.course-option label:hover { border-color: var(--aid); }
.course-option input:checked + label { border-color: var(--aid); background: var(--aid-light); }
.course-option input:focus-visible + label { outline: 3px solid var(--aid); outline-offset: 2px; }
.course-option input:disabled + label { cursor: not-allowed; opacity: .55; background: var(--soft); }
.course-date { font-weight: 800; color: var(--ink); font-size: 1.06rem; }
.course-meta { color: var(--muted); font-size: .92rem; }
.pill { display: inline-block; padding: 5px 12px; border-radius: 99px; font-size: .78rem; font-weight: 800; white-space: nowrap; background: var(--aid-light); color: var(--aid-dark); }
.pill-warn, .pill-full { background: var(--signal-light); color: #c23a1f; }
.pill-muted { background: var(--soft); color: var(--muted); }
@media (max-width: 860px) { #courses .course-option:not(:has(input:checked)) { display: none; } }

/* Formulare */
form h2 { font-size: 1.35rem; display: flex; align-items: center; gap: 12px; }
.num { display: inline-grid; place-items: center; width: 34px; height: 34px; border-radius: 50%; background: var(--aid); color: var(--ink); font-size: 1rem; flex-shrink: 0; }
.form-grid { display: grid; grid-template-columns: 1fr 1fr; gap: 18px 20px; }
.form-grid .full { grid-column: 1 / -1; }
@media (max-width: 640px) { .form-grid { grid-template-columns: 1fr; } }
.field label { display: block; font-weight: 600; margin-bottom: 6px; font-size: .93rem; }
.field input, .field select, .field textarea { width: 100%; font: inherit; padding: 13px 15px; border: 2px solid var(--line); border-radius: 14px; background: #fff; color: var(--ink); transition: border-color .15s; }
.field input:focus, .field select:focus, .field textarea:focus { outline: none; border-color: var(--aid); }
.field textarea { min-height: 96px; resize: vertical; }
.check { display: flex; gap: 12px; align-items: flex-start; font-size: .95rem; }
.check input { margin-top: 4px; width: 20px; height: 20px; flex-shrink: 0; accent-color: var(--aid); }
.hp { position: absolute !important; left: -9999px !important; }
.form-error { color: var(--danger); font-weight: 600; min-height: 1.4em; }
.code-box { display: flex; gap: 8px; align-items: center; background: var(--soft); border: 2px dashed var(--aid); border-radius: 14px; padding: 12px 14px; word-break: break-all; font-family: ui-monospace, Menlo, monospace; font-size: .85rem; }

.pkg-toggle { display: grid; gap: 8px; }
.pkg-list { grid-template-columns: repeat(2, 1fr); }
.pkg-toggle label { border: 2px solid var(--line); border-radius: 16px; padding: 12px; cursor: pointer; text-align: center; font-weight: 600; font-size: .92rem; line-height: 1.3; }
.pkg-toggle input { position: absolute; opacity: 0; pointer-events: none; width: 1px; height: 1px; }
.pkg-toggle label:has(input:checked) { border-color: var(--aid); background: var(--aid-light); }
.pkg-toggle label:has(input:focus-visible) { outline: 3px solid var(--aid); outline-offset: 2px; }
.pkg-toggle b { display: block; font-size: 1.15rem; }
.pkg-toggle small { display: block; font-size: .78rem; font-weight: 400; opacity: .75; margin-top: 4px; }
@media (max-width: 640px) {
  .pkg-list { grid-template-columns: 1fr; }
  .pkg-list label { display: grid; grid-template-columns: 64px 1fr; text-align: left; align-items: center; column-gap: 8px; }
  .pkg-list label b { grid-row: span 2; }
  .pkg-list label small { margin-top: 0; }
}
/* Anmeldung: Auswahl „mit / ohne Sehtest“ gut sichtbar */
.pkg-field { margin-bottom: 18px; background: var(--warn-light); border: 2px solid #f0a020; border-radius: 18px; padding: 16px; }
.pkg-field .pkg-question { font-size: 1.15rem; font-weight: 800; color: var(--ink); margin-bottom: 2px; }
.pkg-field .pkg-hint { margin: 0 0 12px; font-size: .92rem; color: #5c3b00; }
.pkg-field.pkg-missing { border-color: var(--danger); background: var(--danger-light); animation: pkg-shake .35s; }
@keyframes pkg-shake { 25% { transform: translateX(-5px); } 75% { transform: translateX(5px); } }
.pkg-field .pkg-toggle label { position: relative; background: #fff; padding: 16px 12px 14px; }
.pkg-field .pkg-toggle label:has(input:checked) { border-color: var(--aid-dark); background: var(--aid-light); box-shadow: 0 0 0 2px var(--aid-dark); }
.pkg-tag { display: inline-block; font-size: .8rem; font-weight: 800; letter-spacing: .04em; text-transform: uppercase; padding: 4px 10px; border-radius: 99px; margin-bottom: 6px; background: var(--soft); color: var(--ink-2); }
.pkg-komplett .pkg-tag { background: var(--ink); color: #fff; }
.pkg-dot { position: absolute; top: 12px; right: 12px; width: 22px; height: 22px; border: 2px solid var(--muted); border-radius: 50%; background: #fff; }
.pkg-toggle label:has(input:checked) .pkg-dot { border-color: var(--aid-dark); background: var(--aid-dark) url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 16 16'%3E%3Cpath d='M3.5 8.5l3 3 6-7' fill='none' stroke='white' stroke-width='2.2' stroke-linecap='round' stroke-linejoin='round'/%3E%3C/svg%3E") center/14px no-repeat; }
@media (max-width: 640px) {
  .pkg-field .pkg-list label { grid-template-columns: 64px 1fr; padding-right: 44px; }
  .pkg-field .pkg-list label .pkg-tag { grid-column: 2; justify-self: start; margin-bottom: 2px; }
  .pkg-field .pkg-list label b { grid-row: 1 / span 3; }
  .pkg-dot { top: 50%; margin-top: -11px; }
}

.id-notice { display: flex; gap: 14px; align-items: flex-start; background: #fff4e5; border: 2px solid #f0a020; border-radius: 16px; padding: 16px 18px; margin-bottom: 18px; }
.id-notice svg { flex-shrink: 0; width: 34px; height: 34px; }
.id-notice strong { display: block; font-size: 1.05rem; color: #5c3b00; margin-bottom: 2px; }
.id-notice p { margin: 0; color: #5c3b00; font-size: .95rem; }
.picked { display: flex; align-items: center; justify-content: space-between; gap: 12px; background: var(--ink); color: #fff; border-radius: 16px; padding: 14px 18px; margin-bottom: 18px; }
.picked small { color: #b7cad8; display: block; }
.picked button { font: inherit; font-weight: 700; background: transparent; color: var(--aid-bright); border: none; cursor: pointer; padding: 6px; }
@media (max-width: 640px) {
  .sticky-submit { position: sticky; bottom: 0; background: linear-gradient(transparent, #fff 30%); padding: 16px 16px 12px; margin: 0 -16px; z-index: 5; }
  .sticky-submit .btn { width: 100%; }
}

/* Kalender */
.cal { background: #fff; border: 2px solid var(--line); border-radius: var(--radius); padding: 16px; user-select: none; }
.cal-head { display: flex; align-items: center; justify-content: space-between; margin-bottom: 10px; }
.cal-head strong { font-size: 1.1rem; }
.cal-nav { width: 42px; height: 42px; border-radius: 12px; border: 2px solid var(--line); background: #fff; font: inherit; font-size: 1.4rem; line-height: 1; color: var(--ink); cursor: pointer; }
.cal-nav:hover { border-color: var(--aid); }
.cal-grid { display: grid; grid-template-columns: repeat(7, minmax(0, 1fr)); gap: 4px; }
.cal-wd span { text-align: center; font-size: .74rem; font-weight: 800; color: var(--muted); padding: 4px 0; text-transform: uppercase; letter-spacing: .06em; }
.cal-wd span.we { color: var(--aid-dark); }
.cal-day { position: relative; aspect-ratio: 1; min-height: 40px; border: none; border-radius: 12px; background: transparent; font: inherit; font-weight: 600; color: var(--ink); cursor: pointer; display: flex; flex-direction: column; align-items: center; justify-content: center; gap: 1px; padding: 0; transition: background .15s, color .15s, transform .1s; }
.cal-day:disabled { cursor: default; color: #b4c0c8; }
.cal-day.is-hl:disabled { color: #8797a3; }
.cal-day.is-past { opacity: .45; }
.cal-day.is-today .cal-num { text-decoration: underline; text-decoration-thickness: 2px; text-underline-offset: 3px; }
.cal-day:not(:disabled):hover { background: var(--aid-light); }
.cal-day:not(:disabled):active { transform: scale(.94); }
.cal-day.has-free { background: var(--aid-light); color: var(--aid-dark); font-weight: 800; }
.cal-day.has-few { background: var(--signal-light); color: #c23a1f; font-weight: 800; }
.cal-day.has-full { background: var(--soft); color: #9aa8b2; text-decoration: line-through; }
.cal-day.has-course { background: var(--soft); color: var(--ink); font-weight: 800; }
.cal-day.is-hl:not(.has-course):not(:disabled) { box-shadow: inset 0 0 0 1.5px var(--line); }
.cal-day.is-selected, .cal-day.is-selected:hover { background: var(--ink); color: #fff; }
.cal-dot { font-size: .62rem; font-weight: 800; line-height: 1; letter-spacing: .02em; opacity: .85; }
.cal-legend { display: flex; gap: 14px; flex-wrap: wrap; font-size: .82rem; color: var(--muted); margin-top: 10px; }
.cal-legend i { display: inline-block; width: 12px; height: 12px; border-radius: 4px; vertical-align: -1px; margin-right: 5px; }
.chips { display: flex; gap: 8px; flex-wrap: wrap; margin-bottom: 14px; }
.chip-btn { font: inherit; font-weight: 700; font-size: .92rem; border: 2px solid var(--line); background: #fff; color: var(--ink); padding: 8px 16px; border-radius: 999px; cursor: pointer; }
.chip-btn:hover { border-color: var(--aid); }
.chip-btn.active { background: var(--aid); border-color: var(--aid); color: var(--ink); }
.booking-grid { display: grid; grid-template-columns: 360px 1fr; gap: 24px; align-items: start; }
@media (max-width: 860px) { .booking-grid { grid-template-columns: 1fr; } }

/* Fragen */
details { border: 2px solid var(--line); border-radius: 16px; padding: 18px 22px; margin-bottom: 10px; background: #fff; }
summary { cursor: pointer; font-weight: 800; color: var(--ink); list-style: none; display: flex; justify-content: space-between; gap: 16px; }
summary::-webkit-details-marker { display: none; }
summary::after { content: "+"; font-size: 1.4rem; line-height: 1; color: var(--aid); transition: transform .2s; }
details[open] summary::after { transform: rotate(45deg); }
details[open] summary { margin-bottom: 10px; }
details p { color: var(--muted); }

/* Kontakt */
.contact-strip { display: grid; grid-template-columns: repeat(3, 1fr); gap: 12px; }
@media (max-width: 820px) { .contact-strip { grid-template-columns: 1fr; } }
.contact-item { display: flex; gap: 16px; align-items: center; background: #fff; border-radius: var(--radius); padding: 18px; border: 2px solid var(--line); text-decoration: none; color: var(--ink); transition: border-color .15s; }
.contact-item:hover { border-color: var(--aid); color: var(--ink); }
.contact-item strong { display: block; }
.contact-item .icon { margin: 0; }

/* ---------- Startseite ---------- */
.home-hero { position: relative; overflow: hidden; padding: 44px 0 110px; background: linear-gradient(150deg, var(--aid), var(--aid-bright)); }
.home-hero .container { position: relative; z-index: 1; display: grid; gap: 36px; align-items: center; }
.home-hero::before { content: ""; position: absolute; width: 520px; height: 520px; right: -160px; top: -200px; border-radius: 50%; background: rgba(255,255,255,.18); }
.home-hero .lead { color: var(--ink); }
.home-hero .kicker { background: #fff; color: var(--ink); }
.home-hero .btn-ghost { background: #fff; border-color: #fff; }
.home-hero .btn-ghost:hover { background: var(--ink); border-color: var(--ink); color: #fff; }
@media (min-width: 900px) { .home-hero { padding: 76px 0 130px; } .home-hero .container { grid-template-columns: 1.1fr 1fr; gap: 56px; } }
.home-hero h1 { font-size: clamp(2.6rem, 9.5vw, 4.4rem); margin: 18px 0 18px; letter-spacing: -.05em; line-height: .98; }
.home-hero h1 .hl { display: inline-block; color: var(--ink); background: #fff; padding: 0 .22em .04em; margin-top: .08em; border-radius: .22em; transform: rotate(-1.5deg); white-space: nowrap; }


.cpr { background: var(--soft); border-radius: 32px; padding: 28px 22px; display: grid; gap: 26px; align-items: center; }
@media (min-width: 900px) { .cpr { grid-template-columns: 1fr 1fr; padding: 48px; } }
.pad { position: relative; width: min(260px, 70vw); aspect-ratio: 1; margin: 0 auto; border-radius: 50%; border: none; cursor: pointer; font: inherit; background: radial-gradient(circle at 50% 40%, #fff, #e9f2f4); box-shadow: inset 0 -10px 30px rgba(10,37,64,.08), 0 20px 50px rgba(10,37,64,.12); display: grid; place-items: center; touch-action: manipulation; }
.pad svg { width: 46%; height: 46%; transition: transform .08s; }
.pad.press svg { transform: scale(.86); }
.pad::after { content: ""; position: absolute; inset: -10px; border-radius: 50%; border: 3px solid var(--aid); opacity: 0; }
.pad.beat::after { animation: ring .5s ease-out; }
@keyframes ring { from { opacity: .8; transform: scale(.92); } to { opacity: 0; transform: scale(1.12); } }
.pad .hint { position: absolute; bottom: 18%; font-size: .78rem; font-weight: 800; letter-spacing: .12em; text-transform: uppercase; color: var(--muted); }
.meter { text-align: center; }
.bpm { font-size: clamp(3.4rem, 12vw, 5.6rem); font-weight: 800; letter-spacing: -.06em; line-height: 1; }
.bpm small { font-size: 1rem; letter-spacing: 0; color: var(--muted); }
.gauge { position: relative; height: 14px; border-radius: 9px; margin: 16px auto 8px; max-width: 360px; background: linear-gradient(90deg, #ffd9cf 0 40%, var(--aid-light) 40% 60%, #ffd9cf 60%); }
.gauge::before { content: ""; position: absolute; left: 40%; width: 20%; top: 0; bottom: 0; border: 2px solid var(--aid); border-radius: 9px; }
.gauge i { position: absolute; top: -6px; width: 4px; height: 26px; border-radius: 3px; background: var(--ink); left: 0; transition: left .25s; }
.scale { position: relative; height: 1.2em; max-width: 360px; margin: 0 auto; font-size: .74rem; color: var(--muted); font-weight: 600; }
.scale span { position: absolute; transform: translateX(-50%); }
.verdict { font-weight: 800; font-size: 1.15rem; min-height: 1.6em; margin-top: 14px; }
.verdict.ok { color: var(--aid-dark); } .verdict.bad { color: var(--signal); }
.cpr .btn-row { justify-content: center; margin-top: 14px; }

.kit { display: grid; grid-template-columns: repeat(2, 1fr); gap: 12px; }
@media (min-width: 900px) { .kit { grid-template-columns: repeat(3, 1fr); gap: 16px; } }
.kit .item { background: #fff; border: 2px solid var(--line); border-radius: 22px; padding: 20px; transition: border-color .2s, transform .2s; }
.kit .item:hover { border-color: var(--aid); transform: translateY(-4px); }
.kit .item .icon { width: 44px; height: 44px; border-radius: 12px; margin-bottom: 14px; }
.kit .item .icon svg { width: 24px; height: 24px; }
.kit .item h3 { font-size: 1.08rem; margin-bottom: 4px; }
.kit .item p { margin: 0; color: var(--muted); font-size: .9rem; }

.dates { display: grid; gap: 10px; }
@media (min-width: 900px) { .dates { grid-template-columns: 1fr 1fr; } }
.date-card { display: grid; grid-template-columns: 74px 1fr auto; gap: 14px; align-items: center; text-decoration: none; color: var(--ink); background: #fff; border: 2px solid var(--line); border-radius: 20px; padding: 12px; transition: border-color .2s; }
.date-card:hover { border-color: var(--aid); color: var(--ink); }
.date-card .day { text-align: center; background: var(--soft); border-radius: 14px; padding: 8px 0; }
.date-card .day small { display: block; font-size: .68rem; font-weight: 800; letter-spacing: .12em; color: var(--muted); }
.date-card .day b { font-size: 1.7rem; letter-spacing: -.04em; line-height: 1.1; }
.date-card .where { font-weight: 800; }
.date-card .when { color: var(--muted); font-size: .88rem; }

.notice112 { display: flex; gap: 16px; align-items: center; background: var(--signal-light); border-radius: 22px; padding: 18px 20px; }
.notice112 b { font-size: 2.6rem; font-weight: 800; letter-spacing: -.05em; color: var(--signal); line-height: 1; }
.notice112 p { margin: 0; font-size: .95rem; }

/* Leiste unten auf dem Handy */
.dock { position: fixed; left: 12px; right: 12px; bottom: max(12px, env(safe-area-inset-bottom)); z-index: 40; display: flex; align-items: center; gap: 12px; background: #fff; border: 2px solid var(--line); border-radius: 20px; padding: 10px 10px 10px 14px; box-shadow: 0 14px 40px rgba(10,37,64,.18); transform: translateY(150%); transition: transform .4s cubic-bezier(.2,.8,.2,1); }
.dock.show { transform: none; }
.dock .sign { font-size: 30px; }
.dock div { flex: 1; line-height: 1.2; }
.dock small { color: var(--muted); font-size: .76rem; }
@media (min-width: 900px) { .dock { display: none; } }

.rv { opacity: 0; transform: translateY(24px); transition: opacity .7s, transform .7s cubic-bezier(.2,.8,.2,1); }
.rv.in { opacity: 1; transform: none; }

/* Fußbereich */
.site-footer { background: var(--ink); color: #b7cad8; margin-top: auto; }
.site-footer .container { padding-top: 48px; padding-bottom: 28px; }
.site-footer a { color: #fff; text-decoration: none; }
.site-footer a:hover { color: var(--aid-bright); }
.footer-grid { display: grid; grid-template-columns: 1.4fr 1fr 1fr; gap: 32px; }
@media (max-width: 820px) { .footer-grid { grid-template-columns: 1fr; } }
.site-footer h4 { color: #fff; margin: 0 0 12px; font-size: .78rem; letter-spacing: .14em; text-transform: uppercase; }
.site-footer ul { list-style: none; padding: 0; margin: 0; }
.site-footer li { margin-bottom: 8px; }
.footer-logo { width: 240px; max-width: 100%; margin-bottom: 16px; }
.footer-bottom { border-top: 1px solid rgba(255,255,255,.12); margin-top: 36px; padding-top: 18px; font-size: .85rem; display: flex; justify-content: space-between; flex-wrap: wrap; gap: 8px; }
.home .site-footer .container { padding-bottom: 110px; }
@media (min-width: 900px) { .home .site-footer .container { padding-bottom: 28px; } }

.demo-banner { background: #fff3cd; color: #6b5200; text-align: center; font-size: .85rem; padding: 6px 16px; }

/* Verwaltung */
.admin-bar { display: flex; justify-content: space-between; align-items: center; gap: 12px; flex-wrap: wrap; margin-bottom: 24px; }
.tabs { display: flex; gap: 8px; margin-bottom: 20px; flex-wrap: wrap; }
.tabs button { font: inherit; font-weight: 800; border: none; background: var(--soft); color: var(--muted); padding: 10px 18px; border-radius: 12px; cursor: pointer; }
.tabs button.active { background: var(--aid); color: var(--ink); }
.table-wrap { overflow-x: auto; border: 2px solid var(--line); border-radius: var(--radius); background: #fff; }
table { width: 100%; border-collapse: collapse; font-size: .93rem; }
th, td { text-align: left; padding: 12px 14px; border-bottom: 1px solid var(--line); vertical-align: middle; }
th { background: var(--soft); color: var(--muted); font-size: .76rem; text-transform: uppercase; letter-spacing: .08em; white-space: nowrap; }
tr:last-child td { border-bottom: none; }
tr.is-past td { color: var(--muted); }
td .btn-row { gap: 6px; flex-wrap: nowrap; }
td select { font: inherit; padding: 6px 8px; border-radius: 8px; border: 1px solid var(--line); }
.stat-row { display: grid; grid-template-columns: repeat(4, 1fr); gap: 14px; margin-bottom: 24px; }
@media (max-width: 820px) { .stat-row { grid-template-columns: repeat(2, 1fr); } }
.stat { background: #fff; border: 2px solid var(--line); border-radius: var(--radius); padding: 18px; }
.stat b { display: block; font-size: 1.8rem; color: var(--ink); line-height: 1.1; letter-spacing: -.02em; }
.stat span { color: var(--muted); font-size: .88rem; }
.quick-grid { display: grid; grid-template-columns: minmax(0, 1fr) minmax(0, 1fr); gap: 20px; }
@media (max-width: 720px) {
  .quick-grid { grid-template-columns: minmax(0, 1fr); }
  .q-card { padding: 14px; }
  .q-card .cal { padding: 10px; }
  .q-card .cal-day { min-height: 0; }
}
.sel-list { font-size: .9rem; color: var(--muted); min-height: 1.4em; }
dialog { border: none; border-radius: 22px; padding: 0; width: min(640px, calc(100vw - 32px)); box-shadow: 0 30px 80px rgba(0,0,0,.3); }
dialog.wide { width: min(880px, calc(100vw - 24px)); }
dialog::backdrop { background: rgba(10, 37, 64, .55); }
.dialog-body { padding: 28px; }
.hidden { display: none !important; }

/* Abgleich-Leiste der Verwaltung */
.sync-bar { display: flex; align-items: center; gap: 10px; flex-wrap: wrap; background: var(--soft); border: 2px solid var(--line); border-radius: 12px; padding: 10px 14px; margin-bottom: 20px; font-size: .9rem; }
.sync-bar #sync-text { flex: 1; min-width: 180px; }
.sync-dot { width: 10px; height: 10px; border-radius: 50%; flex-shrink: 0; }
.sync-dot.on { background: var(--ok); }
.sync-dot.off { background: var(--signal); }

.cap { display: inline-flex; align-items: center; gap: 6px; white-space: nowrap; }
.cap-btn { width: 28px; height: 28px; border-radius: 8px; border: 2px solid var(--line); background: #fff; color: var(--ink); font: inherit; font-weight: 800; line-height: 1; cursor: pointer; }
.cap-btn:hover { border-color: var(--aid); }

/* ---------- Seriös und kühl: dunkler Monitor-Look, klare Erste-Hilfe-Symbole ---------- */
:root { --nacht: #062029; --nacht-2: #0b303c; --nacht-line: rgba(255,255,255,.13); --hell: #c5dde2; }
.sym { width: 1em; height: 1em; display: block; }
.tile { display: grid; place-items: center; width: 52px; height: 52px; border-radius: 10px; background: var(--aid); color: var(--nacht); font-size: 30px; flex-shrink: 0; }

.btn, .plaster, .btn-teal { border-radius: 10px; }
.plaster, .btn-teal { background: var(--nacht); border-color: var(--nacht); color: #fff; }
.plaster:hover, .btn-teal:hover { transform: translateY(-2px); background: var(--nacht-2); border-color: var(--nacht-2); color: #fff; }
.nav a, .nav a.nav-cta { border-radius: 10px; }
.section-soft { background: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='64' height='64' viewBox='0 0 64 64'%3E%3Cpath fill='%2329b4b6' fill-opacity='.09' d='M29 25h6v4h4v6h-4v4h-6v-4h-4v-6h4z'/%3E%3C/svg%3E"), var(--soft); }

/* Dunkle Flächen */
.section-dark { background: var(--nacht); color: #fff; }
.section-dark h2 { color: #fff; }
.section-dark .lead { color: var(--hell); }
.section-dark .btn-ghost { color: #fff; border-color: var(--nacht-line); }
.section-dark .btn-ghost:hover { background: var(--nacht-2); color: #fff; border-color: var(--aid); }
.section-dark .btn:hover { background: var(--aid-bright); border-color: var(--aid-bright); color: var(--nacht); }

.page-head { position: relative; overflow: hidden; background: var(--nacht); border-radius: 0; color: #fff; }
.page-head h1 { color: #fff; }
.page-head .lead { color: var(--hell); }
.page-head::after { content: ""; position: absolute; right: -30px; top: 50%; width: 220px; height: 220px; transform: translateY(-50%); background: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24'%3E%3Cpath fill='%2329b4b6' d='M9 3h6v6h6v6h-6v6H9v-6H3V9h6z'/%3E%3C/svg%3E") center/contain no-repeat; opacity: .16; }

/* Startseite */
.home-hero { position: relative; overflow: hidden; padding: 48px 0 104px; background: radial-gradient(900px 500px at 85% 0, rgba(41,180,182,.24), transparent 65%), var(--nacht); color: #fff; }
.home-hero::before { display: none; }
@media (min-width: 900px) { .home-hero { padding: 80px 0 130px; } }
.home-hero h1 { color: #fff; }
.home-hero h1 .hl { display: inline; color: var(--aid-bright); background: none; padding: 0; margin: 0; border-radius: 0; transform: none; }
.home-hero .lead { color: var(--hell); }
.home-hero .kicker { background: rgba(255,255,255,.08); color: #fff; }
.home-hero .plaster { background: var(--aid); border-color: var(--aid); color: var(--nacht); }
.home-hero .plaster:hover { background: var(--aid-bright); border-color: var(--aid-bright); color: var(--nacht); }
.home-hero .btn-ghost { background: transparent; color: #fff; border-color: var(--nacht-line); }
.home-hero .btn-ghost:hover { background: var(--nacht-2); color: #fff; border-color: var(--aid); }

.monitor { background: var(--nacht-2); border: 1px solid var(--nacht-line); border-radius: 16px; padding: 24px; }
.monitor-head { display: flex; align-items: center; gap: 10px; font-size: .78rem; font-weight: 800; letter-spacing: .14em; text-transform: uppercase; color: var(--aid-bright); }
.monitor-head .sym { font-size: 22px; }
.monitor-date { font-size: 1.55rem; font-weight: 800; letter-spacing: -.02em; margin-top: 12px; line-height: 1.2; }
.monitor-meta { color: var(--hell); margin-top: 4px; }
.monitor-seats { display: flex; align-items: baseline; gap: 8px; margin-top: 18px; color: var(--hell); }
.monitor-seats b { font-size: 2.4rem; line-height: 1; color: var(--aid-bright); font-variant-numeric: tabular-nums; }
.seat-bar { height: 6px; border-radius: 3px; background: var(--nacht-line); margin: 10px 0 18px; overflow: hidden; }
.seat-bar i { display: block; height: 100%; background: var(--aid); }
.monitor .btn { width: 100%; }
.monitor .btn:hover { background: var(--aid-bright); border-color: var(--aid-bright); color: var(--nacht); }

.ecg-line { position: absolute; left: 0; right: 0; bottom: 10px; width: 100%; height: 76px; }
.ecg-line path { fill: none; stroke-linecap: round; stroke-linejoin: round; vector-effect: non-scaling-stroke; }
.ecg-line .base { stroke: var(--aid); stroke-width: 1.5; opacity: .28; }
.ecg-line .pulse { stroke: var(--aid-bright); stroke-width: 2.5; stroke-dasharray: 130 870; animation: ecg-run 5s linear infinite; }
@keyframes ecg-run { from { stroke-dashoffset: 1000; } to { stroke-dashoffset: 0; } }

.facts { background: var(--nacht-2); color: #fff; }
.facts .container { display: grid; grid-template-columns: 1fr 1fr; gap: 18px; padding-top: 22px; padding-bottom: 22px; }
@media (min-width: 900px) { .facts .container { grid-template-columns: repeat(4, 1fr); } }
.fact { display: flex; align-items: center; gap: 12px; min-width: 0; }
.fact .tile { width: 42px; height: 42px; font-size: 24px; }
.fact b { display: block; font-size: 1.15rem; line-height: 1.2; }
.fact span:not(.tile) { font-size: .8rem; color: var(--hell); line-height: 1.25; display: block; }

.price-card.featured { background: var(--nacht); border-color: var(--nacht); }
.price-card.featured .btn-teal, .price-card.featured .plaster { background: var(--aid); border-color: var(--aid); color: var(--nacht); }
.price-card.featured .btn-teal:hover, .price-card.featured .plaster:hover { background: var(--aid-bright); border-color: var(--aid-bright); color: var(--nacht); }
.h-sym { display: flex; align-items: center; gap: 14px; }
.step-card { position: relative; }
.step-no { position: absolute; top: 22px; right: 24px; font-size: 2.2rem; font-weight: 800; line-height: 1; color: var(--line); font-variant-numeric: tabular-nums; }
.step-card h3 { margin-top: 16px; font-size: 1.35rem; }
.step-card p { margin: 0; }
.step-alarm .tile { background: var(--signal); color: #fff; }

.kit { grid-template-columns: repeat(2, 1fr); }
@media (min-width: 900px) { .kit { grid-template-columns: repeat(3, 1fr); } }
.kit .item .tile { margin-bottom: 14px; }

/* Drück-Takt wie ein Messgerät */
.cpr { background: var(--nacht-2); border: 1px solid var(--nacht-line); border-radius: 16px; }
.pad { background: radial-gradient(circle at 50% 40%, #124656, #082a35); box-shadow: 0 0 0 1px var(--nacht-line), 0 0 44px rgba(41,180,182,.22); }
.pad .hint { color: var(--hell); }
.bpm { color: var(--aid-bright); font-variant-numeric: tabular-nums; }
.bpm small, .scale { color: var(--hell); }
.gauge { background: linear-gradient(90deg, rgba(255,90,60,.4) 0 40%, rgba(41,180,182,.3) 40% 60%, rgba(255,90,60,.4) 60%); }
.gauge i { background: #fff; }
.verdict.ok { color: var(--aid-bright); }

.symbol-row { display: flex; flex-wrap: wrap; gap: 18px; color: var(--aid); font-size: 28px; padding-bottom: 28px; margin-bottom: 28px; border-bottom: 1px solid rgba(255,255,255,.12); }

@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after { animation: none !important; transition: none !important; }
  .rv { opacity: 1; transform: none; }
  .ecg-line .pulse { animation: none; stroke-dasharray: none; opacity: .7; }
}
@media print {
  .site-header, .site-footer, .no-print, .demo-banner, .dock { display: none !important; }
  body { font-size: 12px; }
  .table-wrap { border: none; }
}

/* Erinnerung ans Synchronisieren */
.sync-reminder { position: fixed; left: 12px; right: 12px; bottom: calc(12px + env(safe-area-inset-bottom)); z-index: 50; display: flex; align-items: center; justify-content: space-between; gap: 12px; flex-wrap: wrap; max-width: 720px; margin: 0 auto; padding: 12px 16px; background: var(--nacht, #0a2540); color: #fff; font-weight: 700; border-radius: 14px; box-shadow: 0 10px 30px rgba(10, 37, 64, .35); }
.sync-reminder.pulse { animation: sr-pulse .7s ease-out; }
@keyframes sr-pulse { 0% { transform: scale(1); } 40% { transform: scale(1.03); } 100% { transform: scale(1); } }
@media (prefers-reduced-motion: reduce) { .sync-reminder.pulse { animation: none; } }
body.has-reminder { padding-bottom: 90px; }

/* Schülerdatenbank */
.sc-list { display: grid; gap: 14px; }
.sc-person { background: #fff; border: 2px solid var(--line); border-radius: var(--radius); padding: 16px; }
.sc-person h3 { margin: 0; font-size: 1.1rem; }
.sc-entry { border-top: 1px solid var(--line); margin-top: 12px; padding-top: 12px; display: grid; gap: 10px; }
.sc-entry .sc-facts { display: grid; grid-template-columns: repeat(auto-fit, minmax(190px, 1fr)); gap: 10px; }
.sc-entry label { display: block; font-size: .8rem; color: var(--muted, #5a6b78); margin-bottom: 4px; }
.sc-entry input[type=date] { width: 100%; max-width: 220px; }

/* Anwesenheit */
.att-list { display: grid; gap: 14px; }
.att-card { background: #fff; border: 2px solid var(--line); border-radius: var(--radius); padding: 16px; }
.att-card h3 { margin: 0 0 4px; font-size: 1.05rem; }
.att-row { display: flex; flex-wrap: wrap; align-items: center; gap: 8px 12px; padding: 10px 0; border-top: 1px solid var(--line); }
.att-name { flex: 1 1 170px; font-weight: 700; }
.att-btns, .att-fee { display: flex; flex-wrap: wrap; align-items: center; gap: 6px; }
.att-fee { flex-basis: 100%; }
.att-btn.on-yes { background: var(--ok); border-color: var(--ok); color: #fff; }
.att-btn.on-no { background: var(--danger); border-color: var(--danger); color: #fff; }

/* Sehtest abhaken */
.st-row { flex-basis: 100%; display: flex; flex-wrap: wrap; align-items: center; gap: 6px 10px; font-size: .86rem; }
.st-group { display: flex; flex-wrap: wrap; align-items: center; gap: 4px; }
.st-label { color: var(--muted, #5a6b78); }
.sc-done { font-weight: 800; }

/* Anwesenheit als Ordner */
.att-folder { background: #fff; border: 2px solid var(--line); border-radius: var(--radius); padding: 0; margin: 0; }
.att-folder[open] { border-color: var(--aid); }
.att-folder > summary { display: flex; flex-wrap: wrap; align-items: baseline; gap: 2px 10px; padding: 12px 16px; cursor: pointer; font-weight: 700; list-style: none; }
.att-folder > summary::-webkit-details-marker { display: none; }
.att-folder > summary { justify-content: flex-start; }
.att-folder > summary::after { margin-left: auto; }
.att-folder > summary small { font-weight: 500; color: var(--muted, #5a6b78); }
.att-body { padding: 0 16px 12px; }

/* Zurück-Knopf im Kopfbereich */
.header-left { display: flex; align-items: center; gap: 10px; min-width: 0; }
.back-btn { font: inherit; font-weight: 700; font-size: .86rem; white-space: nowrap; padding: 8px 12px; color: var(--ink); background: var(--soft); border: 2px solid var(--line); border-radius: 10px; cursor: pointer; }
.back-btn:hover { border-color: var(--aid); }
.back-btn[hidden] { display: none; }

/* Einnahmen & Ausgaben */
.fin-card { margin-bottom: 18px; }
.fin-card h3 { margin-top: 0; }
.fin-table .fin-num { text-align: right; white-space: nowrap; }
.fin-month td { font-weight: 800; background: var(--soft); }
.fin-sub td { font-weight: 700; }
.fin-total td { font-weight: 800; border-top: 2px solid var(--ink); }
.fin-form { display: flex; flex-wrap: wrap; align-items: flex-end; gap: 10px; margin-bottom: 12px; }
.fin-form label { display: flex; flex-direction: column; gap: 4px; font-size: .82rem; font-weight: 600; flex: 0 1 150px; min-width: 120px; }
.fin-form label.grow { flex: 1 1 220px; }
.fin-input, .fin-input-sm { padding: 6px 8px; text-align: right; }
.fin-input { width: 96px; }
.fin-input-sm { width: 64px; }
.fin-scroll { max-height: 420px; overflow: auto; }
.fin-routes { display: flex; flex-wrap: wrap; gap: 8px; margin-bottom: 12px; }
.fin-route { display: inline-flex; align-items: center; gap: 2px; }
.fin-route-del { font: inherit; border: none; background: none; color: var(--danger); cursor: pointer; padding: 6px; }
.fin-sumline { display: flex; justify-content: space-between; gap: 12px; padding: 6px 0; }
.fin-profit { border-top: 2px solid var(--ink); font-weight: 800; font-size: 1.15rem; margin-top: 4px; padding-top: 10px; }
.fin-bar { height: 10px; border-radius: 5px; background: var(--soft); overflow: hidden; }
.fin-bar i { display: block; height: 100%; background: var(--aid); }
.fin-bar.near i { background: #e0a100; }
.fin-bar.over i { background: var(--danger); }
.disc-note { flex: 1 1 160px; min-width: 130px; padding: 6px 8px; }

/* Schnelle Anwesenheit, auch auf dem Handy */
#att-section .att-btn { min-height: 44px; min-width: 96px; font-size: .95rem; }
.att-more { flex-basis: 100%; border: none; padding: 0; margin: 0; background: none; }
.att-more > summary { padding: 6px 0; font-size: .82rem; font-weight: 600; color: var(--muted, #5a6b78); }
@media (max-width: 720px) {
  #att-section .att-row { align-items: stretch; }
  #att-section .att-name { flex-basis: 100%; font-size: 1.05rem; }
  #att-section .att-btns { flex: 1 1 100%; }
  #att-section .att-btn { flex: 1 1 0; }
}

/* ---------- Sehtest am Computer ---------- */
.st-dlg { padding: 20px; }
.st-head { display: flex; flex-wrap: wrap; justify-content: space-between; gap: 10px 20px; align-items: flex-end; }
.st-head h3 { margin: 0; }
.st-head p { margin: 2px 0 0; }
.st-nr { margin: 0; min-width: 0; }
.st-nr input { width: 160px; font-weight: 700; }
.st-tabs { display: grid; grid-template-columns: repeat(6, minmax(0, 1fr)); gap: 6px; margin-top: 14px; }
.st-tab { display: flex; flex-direction: column; align-items: flex-start; gap: 1px; padding: 7px 8px; border: 1.5px solid var(--line, #e3eaee); border-radius: 12px; background: #fff; font: inherit; font-size: .78rem; text-align: left; cursor: pointer; color: inherit; min-width: 0; }
.st-tab span { color: var(--muted, #5f7180); white-space: nowrap; overflow: hidden; text-overflow: ellipsis; max-width: 100%; }
.st-tab em { font-style: normal; font-weight: 700; }
.st-tab.active { border-color: var(--ink, #0a2540); box-shadow: inset 0 0 0 1px var(--ink, #0a2540); }
.st-tab.is-bestanden em { color: var(--ok); }
.st-tab.is-nicht em { color: var(--danger); }
.st-grid { display: grid; gap: 6px; }
.st-line { display: flex; align-items: center; gap: 6px; padding: 4px 6px; border-radius: 10px; }
.st-line.counted { background: #eef4f6; }
.st-visus { width: 34px; flex: none; font-weight: 700; font-size: .85rem; }
.st-ring { position: relative; flex: 1 1 0; max-width: 72px; height: 52px; border: 1.5px solid var(--line, #e3eaee); border-radius: 12px; background: #fff; cursor: pointer; padding: 0; display: flex; align-items: center; justify-content: center; }
.st-ring svg { width: 30px; height: 30px; fill: #0a2540; }
.st-ring span { position: absolute; right: 4px; top: 2px; font-weight: 800; font-size: .85rem; }
.st-ring.m-r { border-color: var(--ok); background: #e9f7ef; }
.st-ring.m-r span { color: var(--ok); }
.st-ring.m-f { border-color: var(--danger); background: #fdecea; }
.st-ring.m-f span { color: var(--danger); }
.st-result { margin: 6px 0 0; font-weight: 800; font-size: 1.1rem; }
.st-result.is-bestanden { color: var(--ok); }
.st-result.is-nicht, .st-result.is-nicht-wiederholung { color: var(--danger); }
@media (max-width: 640px) {
  .st-dlg { padding: 14px; }
  .st-tabs { grid-template-columns: repeat(3, minmax(0, 1fr)); }
  .st-ring { height: 46px; }
  .st-ring svg { width: 26px; height: 26px; }
}
.st-line.ignored { opacity: .55; }
.st-extra { display: grid; gap: 8px; margin-top: 10px; }
.st-extra input[type="date"] { padding: 8px 10px; border: 1.5px solid var(--line); border-radius: 10px; font: inherit; }
.st-quick { margin-top: 6px; }
.se-list { display: grid; gap: 10px; }
.se-row { display: grid; grid-template-columns: 90px 1fr 100px 150px; gap: 6px 14px; align-items: center; padding: 12px 14px; border: 1px solid var(--line); border-radius: 14px; background: #fff; }
.se-nr { font-weight: 800; }
.se-res.ok { color: var(--ok); font-weight: 700; }
.se-res.no { color: var(--danger); font-weight: 700; }
.se-act { grid-column: 1 / -1; display: flex; flex-wrap: wrap; gap: 6px; }
@media (max-width: 640px) {
  .se-row { grid-template-columns: 1fr 1fr; }
  .se-who { grid-column: 1 / -1; order: -1; }
}
.st-sets { display: grid; grid-template-columns: 1fr 1fr; gap: 8px; margin-top: 14px; }
.st-set { display: flex; justify-content: space-between; align-items: center; gap: 8px; padding: 12px 14px; border: 1.5px solid var(--line); border-radius: 14px; background: #fff; font: inherit; cursor: pointer; color: inherit; }
.st-set strong { font-size: 1.05rem; }
.st-set em { font-style: normal; font-weight: 700; font-size: .85rem; }
.st-set.active { border-color: var(--ink, #0a2540); box-shadow: inset 0 0 0 1px var(--ink, #0a2540); }
.st-set.is-bestanden em, .st-block.is-bestanden .st-badge { color: var(--ok); }
.st-set.is-nicht em, .st-block.is-nicht .st-badge { color: var(--danger); }
.st-block { border: 1px solid var(--line); border-radius: 16px; padding: 12px; margin-bottom: 12px; }
.st-block.is-bestanden { border-color: var(--ok); }
.st-block.is-nicht { border-color: var(--danger); }
.st-block-head { display: flex; justify-content: space-between; align-items: baseline; gap: 8px; }
.st-block-head h4 { margin: 0 0 2px; font-size: 1rem; }
.st-badge { font-weight: 800; font-size: .85rem; white-space: nowrap; }
.st-line.practice { background: repeating-linear-gradient(135deg, #f6f8f9 0 8px, #fff 8px 16px); }
.st-visus small { display: block; font-weight: 600; font-size: .62rem; color: var(--muted); }
.st-warn { color: #a5560b; margin: 6px 0 0; font-weight: 600; }
#sd-idno { padding: 8px 10px; border: 1.5px solid var(--line); border-radius: 10px; font: inherit; min-width: 0; width: 220px; max-width: 100%; }
.st-set { flex-wrap: wrap; } .st-set strong { white-space: nowrap; }

/* ---------- Hauptnavigation: große Hauptbereiche, kleine Nebenbereiche ---------- */
.main-nav { margin-bottom: 26px; }
.nav-main { display: grid; grid-template-columns: repeat(7, minmax(0, 1fr)); gap: 8px; }
.nav-main button { display: flex; flex-direction: column; align-items: center; justify-content: center; gap: 4px; min-height: 68px; padding: 8px 4px; font: inherit; font-weight: 800; font-size: .95rem; border: 2px solid var(--line); border-radius: 16px; background: #fff; color: var(--ink); cursor: pointer; }
.nav-main button .sym { width: 24px; height: 24px; color: var(--teal, #29b4b6); }
.nav-main .dots { font-size: 1.1rem; line-height: 24px; letter-spacing: 2px; color: var(--teal, #29b4b6); }
.nav-main button.active { background: var(--ink); border-color: var(--ink); color: #fff; }
.nav-main button.active .sym { color: #7fdadb; }
.nav-more { display: flex; flex-wrap: wrap; gap: 4px 14px; margin-top: 10px; padding-top: 8px; border-top: 1px solid var(--line); }
.nav-more button { font: inherit; font-size: .88rem; font-weight: 700; border: none; background: none; color: var(--muted); padding: 6px 2px; cursor: pointer; }
.nav-more button.active { color: var(--ink); text-decoration: underline; text-underline-offset: 4px; }
.nav-badge { display: inline-block; min-width: 20px; padding: 1px 6px; border-radius: 999px; background: var(--danger); color: #fff; font-size: .75rem; text-align: center; }
.row-link { cursor: pointer; }
.row-link:hover td { background: #f4f9f9; }
.p-att { display: grid; gap: 6px; min-width: 210px; }
@media (max-width: 640px) {
  .nav-main { grid-template-columns: repeat(7, minmax(0, 1fr)); gap: 4px; }
  .nav-main button { min-height: 54px; padding: 6px 1px; font-size: .7rem; border-radius: 12px; gap: 2px; }
  .nav-main button .sym { width: 20px; height: 20px; }
  .nav-main .dots { line-height: 20px; font-size: .9rem; }
  .nav-main .nav-badge { position: absolute; margin: -34px 0 0 34px; font-size: .65rem; min-width: 16px; padding: 0 4px; }
  .nav-main button { position: relative; }
}

/* Sehtests in Ordnern je Kurstag */
.se-head { font-size: 1rem; margin: 18px 0 8px; color: var(--muted, #5a6b78); }
.se-folder { margin-bottom: 10px; }
.se-folder .att-body { padding: 0 12px 12px; }
.se-more { margin-top: 10px; }
.se-more > summary { cursor: pointer; padding: 6px 0; }
.check-line { display: flex; gap: 8px; align-items: center; margin: 10px 0 0; font-weight: 600; }
.se-more > summary { display: flex; align-items: center; list-style: none; }
.se-more > summary::-webkit-details-marker { display: none; }
.se-more > summary::after { margin-left: auto; }
.se-more:not([open]) > summary::after { transform: none; }

/* Verwaltung, Version 44: ruhiger Kopf, Startseite, feste Navigation */
body[data-page="admin"] #site-footer { display: none; }
.admin-top { display: flex; align-items: center; justify-content: space-between; gap: 8px 16px; flex-wrap: wrap; margin-bottom: 14px; }
.admin-top h1 { margin: 0; font-size: 1.5rem; }
.sync-mini { display: flex; align-items: center; gap: 8px; flex-wrap: wrap; }
.sync-mini #sync-text { max-width: 420px; color: var(--muted); }
.main-nav { position: sticky; top: 0; z-index: 30; background: var(--bg, #fff); padding: 8px 0 10px; margin-bottom: 18px; border-bottom: 1px solid var(--line); }
.nav-more-btn.active { background: var(--ink) !important; border-color: var(--ink) !important; color: #fff !important; }
.nav-more { border-top: 0; margin-top: 8px; padding: 6px 10px; background: var(--soft, #f4f9f9); border-radius: 12px; }
.start-date { font-size: 1.15rem; font-weight: 700; margin: 0 0 12px; }
.start-grid { display: grid; grid-template-columns: 1fr 1fr; gap: 14px; }
.start-card h2 { font-size: 1.1rem; margin: 0 0 8px; color: var(--muted); text-transform: uppercase; letter-spacing: .04em; }
.start-big { font-size: 1.25rem; font-weight: 800; margin: 0 0 4px; }
.todo-item { display: flex; align-items: center; gap: 12px; width: 100%; padding: 12px 14px; margin-bottom: 8px; font: inherit; font-weight: 700; text-align: left; border: 2px solid var(--line); border-radius: 14px; background: #fff; color: var(--ink); cursor: pointer; }
.todo-item b { min-width: 34px; height: 34px; display: grid; place-items: center; border-radius: 999px; background: var(--danger); color: #fff; }
.todo-item span:nth-of-type(1) { flex: 1; }
.todo-item:hover, .next-row:hover { border-color: var(--teal, #29b4b6); }
.start-h { font-size: 1.15rem; margin: 18px 0 10px; }
.start-next { display: grid; gap: 8px; }
.next-row { display: grid; grid-template-columns: 170px 1fr auto; gap: 4px 14px; align-items: center; width: 100%; padding: 12px 14px; font: inherit; text-align: left; border: 2px solid var(--line); border-radius: 14px; background: #fff; color: var(--ink); cursor: pointer; }
.next-cap { font-weight: 800; }
#att-unchecked { margin-top: 18px; }
.q-sum { font-weight: 800; font-size: 1.1rem; cursor: pointer; }
.q-sum::after, .row-more > summary::after { content: none !important; }
.row-more { position: relative; display: inline-block; }
.row-more > summary { list-style: none; }
.row-more > summary::-webkit-details-marker { display: none; }
.row-more-box { position: absolute; right: 0; top: calc(100% + 4px); z-index: 20; display: grid; gap: 6px; padding: 10px; background: #fff; border: 2px solid var(--line); border-radius: 12px; box-shadow: 0 8px 24px rgba(10,37,64,.15); white-space: nowrap; }
@media (max-width: 640px) {
  .start-grid { grid-template-columns: 1fr; }
  .next-row { grid-template-columns: 1fr auto; }
  .next-row span:nth-of-type(1) { grid-column: 1; }
  .next-row .next-cap { grid-column: 2; grid-row: 1 / span 2; }
  .admin-top h1 { font-size: 1.25rem; }
  .sync-mini #sync-text { display: none; }
}
body[data-page="admin"] .site-header { position: static; }
body[data-page="admin"] .section { padding-top: 22px; }

/* iPhone/Android: Eingabefelder mit mindestens 16 px, sonst zoomt der Browser beim Tippen hinein und bleibt groß */
@media (pointer: coarse) {
  input, select, textarea { font-size: 16px !important; }
}
/* Sehtest-Bescheinigung ausgestellt / neu ausstellen */
.st-fix { color: var(--ok); font-weight: 700; font-size: .85rem; white-space: nowrap; }
.st-reissue { display: inline-block; color: #fff; background: var(--danger); border-radius: 8px; padding: 1px 8px; font-weight: 700; font-size: .85rem; }
.st-extra.st-top { margin: 4px 0 12px; padding-bottom: 12px; border-bottom: 1px solid var(--line); }
/* Schüler vor Ort erfassen */
.start-capture { margin: 0 0 16px; }
.start-capture-btn { width: 100%; padding: 18px 16px; font-size: 1.1rem; }
.start-capture p { margin: 6px 2px 0; }
.cap-dlg { width: min(640px, 100vw - 16px); padding: 18px 16px 22px; box-sizing: border-box; }
.cap-head { display: flex; justify-content: space-between; align-items: center; gap: 10px; margin-bottom: 10px; }
.cap-head h3 { margin: 0; }
.cap-grid { display: grid; grid-template-columns: 1fr 1fr; gap: 10px 12px; margin-bottom: 10px; align-items: end; }
.cap-read { width: 100%; padding: 18px 12px; border-radius: 14px; font-size: 1.1rem; margin-top: 6px; }
.cap-more { margin: 0 0 10px; }
.cap-more summary { cursor: pointer; font-weight: 700; padding: 6px 0; }
.cap-save { width: 100%; padding: 16px; }
#cap-done h4 { margin: 18px 0 6px; }
.cap-row { display: flex; justify-content: space-between; align-items: center; gap: 8px; padding: 6px 0; border-bottom: 1px solid var(--line); }
@media (max-width: 480px) { .cap-grid { grid-template-columns: 1fr; } }
.del-mini { margin-top: 6px; font: inherit; font-size: .8rem; font-weight: 700; color: var(--danger); background: var(--danger-light); border: 1px solid transparent; border-radius: 999px; padding: 3px 10px; cursor: pointer; white-space: nowrap; }
/* QR-Code zur Selbsteintragung */
.qr-dlg { width: min(520px, 100vw - 16px); padding: 18px 16px 20px; box-sizing: border-box; }
.qr-img { background: #fff; border-radius: 14px; padding: 10px; margin: 0 auto 10px; max-width: 360px; }
.qr-img svg { display: block; width: 100%; height: auto; }
.st-void { display: inline-block; color: var(--muted); background: var(--soft); border: 1px dashed var(--line); border-radius: 8px; padding: 1px 8px; font-weight: 700; font-size: .85rem; }
.cert-row { display: flex; justify-content: space-between; align-items: center; gap: 10px; padding: 8px 0; border-bottom: 1px solid var(--line); }
/* Herunterziehen zum Aktualisieren */
.ptr { position: fixed; top: -46px; left: 50%; transform: translate(-50%, 0); z-index: 60; display: flex; align-items: center; gap: 8px;
  background: #fff; color: var(--ink); border: 1px solid var(--line); border-radius: 999px; padding: 8px 14px; font-weight: 700; font-size: .85rem;
  box-shadow: 0 6px 18px rgba(10, 42, 53, .15); transition: transform .15s; pointer-events: none; }
.ptr-icon { display: inline-block; font-size: 1.1rem; color: var(--aid-dark); transition: transform .2s; }
.ptr.ready .ptr-icon { transform: rotate(180deg); }
.ptr.busy .ptr-icon { animation: ptr-spin .8s linear infinite; }
@keyframes ptr-spin { to { transform: rotate(360deg); } }

/* ---------- Unterschrift vor Ort (Verwaltung) ---------- */
.sign-field { display: flex; align-items: center; justify-content: center; width: 100%; height: 110px; border: 2px dashed #9fd9da; border-radius: 12px; background: #fff; color: #4f6b76; font: inherit; font-weight: 600; cursor: pointer; padding: 6px; }
.sign-field img { max-width: 100%; max-height: 96px; }
dialog.sign-big { position: fixed; inset: 0; width: 100vw; height: 100vh; height: 100dvh; max-width: none; max-height: none; margin: 0; padding: 0; border: 0; border-radius: 0; background: #fff; color: #0a2a35; overflow: hidden; }
dialog.sign-big::backdrop { background: #fff; }
.sign-big .sb-wrap { position: absolute; top: 0; left: 0; width: 100vw; height: 100vh; height: 100dvh; display: flex; flex-direction: column; background: #fff; }
/* Handy hochkant: Feld um 90° drehen, damit es im Querformat die ganze Seite füllt */
.sign-big.sb-turn .sb-wrap { width: 100vh; width: 100dvh; height: 100vw; left: 100vw; transform-origin: top left; transform: rotate(90deg); }
.sign-big .sb-bar { display: flex; align-items: center; justify-content: space-between; gap: 8px; padding: max(8px, env(safe-area-inset-top)) max(12px, env(safe-area-inset-right)) 8px max(12px, env(safe-area-inset-left)); border-bottom: 1px solid #d9ecec; }
.sign-big .sb-bar strong { font-size: 15px; text-align: center; }
.sign-big .sb-area { position: relative; flex: 1; min-height: 0; margin: 8px 12px; border: 2px dashed #9fd9da; border-radius: 14px; background: #fff; overflow: hidden; }
.sign-big canvas { position: absolute; top: 0; left: 0; touch-action: none; display: block; }
.sign-big .sb-line { position: absolute; left: 6%; right: 6%; bottom: 26%; border-bottom: 2px solid #d9ecec; pointer-events: none; }
.sign-big .sb-hint { position: absolute; left: 0; right: 0; bottom: calc(26% - 26px); text-align: center; color: #8aa1a9; font-size: 14px; pointer-events: none; }
.sign-big .sb-foot { display: flex; gap: 10px; padding: 0 12px max(10px, env(safe-area-inset-bottom)); }
.sign-big .sb-foot .btn { flex: 1; min-height: 48px; font-size: 16px; }
.sign-preview { display: flex; align-items: center; justify-content: center; width: 100%; height: 110px; border: 2px dashed #9fd9da; border-radius: 14px; background: #fff; color: #4f6b76; font: inherit; font-weight: 600; cursor: pointer; padding: 6px; }
.sign-preview img { max-width: 100%; max-height: 96px; }

/* ---------- Schülersuche: Spalte Sehtest-Protokolle; Bezahlt-Zeile ---------- */
.sc-cols { display: grid; grid-template-columns: minmax(0, 1fr); gap: 18px; }
@media (min-width: 900px) { .sc-cols { grid-template-columns: minmax(0, 2fr) minmax(260px, 1fr); align-items: start; } }
.sc-protos { border: 1px solid var(--line); border-radius: 14px; padding: 12px; background: #fff; }
.sc-proto { display: flex; align-items: center; justify-content: space-between; gap: 8px; padding: 8px 0; border-top: 1px solid var(--line); }
.pay-row { align-items: center; flex-wrap: wrap; }
.pay-row .onlist { display: inline-flex; align-items: center; gap: 6px; margin-left: 6px; font-weight: 600; }
.pay-row .onlist input { width: 20px; height: 20px; }

/* Sehtest-Dialog: Schritte ① Ausweis ② Bezahlt ③ Sehtest */
.st-step { margin: 10px 0 4px; font-size: 1rem; }
.st-step:first-child { margin-top: 0; }
.st-step.done { color: var(--ok); }
.st-step.done::after { content: " ✓"; }
.st-more { margin-top: 6px; }
.st-more summary { cursor: pointer; }

/* Bezahlt-Vermerk: bezahlt in der Farbe von „Sehtest durchführen“, nicht bezahlt rot */
.att-btn.on-paid { background: var(--aid); border-color: var(--aid); color: var(--ink); }
.pay-tag { display: inline-block; padding: 6px 12px; border-radius: 999px; font-size: .86rem; font-weight: 800; }
.pay-tag.paid { background: var(--aid); color: var(--ink); }
.pay-tag.unpaid { background: var(--danger); color: #fff; }

/* Kurs-Abrechnung unten */
.course-sum { margin: 16px 0 4px; padding: 14px; border: 2px solid var(--line); border-radius: 16px; background: var(--soft); }
.sum-grid { display: grid; grid-template-columns: repeat(auto-fit, minmax(120px, 1fr)); gap: 8px; margin-bottom: 8px; }
.sum-cell { background: #fff; border-radius: 12px; padding: 8px 12px; display: flex; flex-direction: column; }
.sum-cell span { font-size: .8rem; color: var(--muted); }
.sum-cell b { font-size: 1.15rem; }
.sum-cell.strong { background: var(--aid); }
.sum-cell.strong span { color: var(--ink); }

/* Kurstag kompakt: Stand auf einen Blick */
.att-chips { display: flex; flex-wrap: wrap; gap: 6px; align-items: center; margin: 6px 0 2px; }
.chip { display: inline-block; padding: 5px 11px; border-radius: 999px; font-size: .84rem; font-weight: 700; background: var(--soft); color: var(--ink); }
.chip.ok { background: var(--aid); color: var(--ink); }
.chip.no { background: var(--danger); color: #fff; }
.chip-btn { border: 2px dashed var(--danger); background: #fff; color: var(--danger); border-radius: 999px; padding: 6px 13px; font: inherit; font-size: .88rem; font-weight: 800; cursor: pointer; min-height: 38px; }
.chip-btn.on { border: 2px solid var(--ok); background: var(--ok); color: #fff; }
.att-more > summary { cursor: pointer; font-weight: 700; padding: 6px 0; }

/* Zahlungen */
.pay-table { width: 100%; border-collapse: collapse; font-size: .92rem; }
.pay-table th, .pay-table td { padding: 8px 6px; border-bottom: 1px solid var(--line); text-align: left; vertical-align: top; }
.pay-table th { font-size: .78rem; color: var(--muted); text-transform: uppercase; letter-spacing: .03em; }
.pay-table td.num, .pay-table th.num { text-align: right; white-space: nowrap; }

/* Kurstag: drei Seiten */
.att-tabs { display: grid; grid-template-columns: repeat(4, 1fr); gap: 6px; margin: 0 0 14px; background: var(--soft); padding: 5px; border-radius: 16px; position: sticky; top: 0; z-index: 5; }
.att-tabs button { border: 0; background: transparent; padding: 12px 6px; border-radius: 12px; font: inherit; font-weight: 800; color: var(--ink); cursor: pointer; }
.att-tabs button.active { background: var(--aid); }
.st-pick { display: flex; align-items: center; gap: 10px; width: 100%; text-align: left; background: #fff; border: 2px solid var(--line); border-radius: 14px; padding: 10px 12px; font: inherit; color: inherit; cursor: pointer; }
.st-pick:hover { border-color: var(--aid); }
.st-pick .att-name { flex: 1 1 auto; }
.st-pick-go { font-weight: 800; color: var(--aid); white-space: nowrap; }

/* Zahlungen: Karten statt Tabelle */
.pay-tiles { display: grid; grid-template-columns: repeat(auto-fit, minmax(140px, 1fr)); gap: 10px; margin-bottom: 16px; }
.pay-tile { background: #fff; border: 2px solid var(--line); border-radius: 16px; padding: 12px 14px; display: flex; flex-direction: column; gap: 2px; }
.pay-tile span { font-size: .82rem; color: var(--muted); font-weight: 700; }
.pay-tile b { font-size: 1.35rem; }
.pay-tile.ok { border-color: var(--ok); }
.pay-tile.ok b { color: var(--ok); }
.pay-tile.no { border-color: var(--danger); }
.pay-tile.no b { color: var(--danger); }
.pay-h { font-size: 1rem; margin: 18px 0 8px; }
.pay-card { display: flex; align-items: center; justify-content: space-between; gap: 12px; background: #fff; border: 2px solid var(--line); border-left-width: 6px; border-radius: 14px; padding: 10px 14px; margin-bottom: 8px; }
.pay-card.is-paid { border-left-color: var(--ok); }
.pay-card.is-open { border-left-color: var(--danger); }
.pay-who { display: flex; flex-direction: column; gap: 2px; min-width: 0; }
.pay-info { font-size: .85rem; color: var(--muted); }
.pay-docs { font-size: .8rem; color: var(--muted); }
.pay-amount { display: flex; flex-direction: column; align-items: flex-end; gap: 4px; flex: 0 0 auto; text-align: right; }
.pay-amount b { font-size: 1.15rem; white-space: nowrap; }

/* PDF-Vorschau */
.pv-dlg { width: min(1000px, 96vw); height: 94vh; max-height: 94vh; padding: 0; border: 0; border-radius: 16px; overflow: hidden; }
.pv-dlg[open] { display: flex; flex-direction: column; }
.pv-dlg::backdrop { background: rgba(10, 37, 64, .55); }
.pv-bar { display: flex; flex-wrap: wrap; align-items: center; justify-content: space-between; gap: 8px; padding: 10px 14px; background: var(--soft); border-bottom: 1px solid var(--line); }
.pv-bar strong { font-size: .9rem; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; max-width: 50%; }
.pv-dlg iframe { flex: 1 1 auto; width: 100%; border: 0; background: #525659; }

.att-print { margin: 4px 0 6px; padding: 8px 12px; background: var(--soft); border-radius: 12px; }
.att-print > summary { cursor: pointer; font-weight: 800; }

/* Gesendete Schreiben */
.mail-card { background: #fff; border: 2px solid var(--line); border-radius: 14px; padding: 10px 14px; margin-bottom: 8px; }
.mail-card > summary { cursor: pointer; line-height: 1.5; }
.mail-when { display: inline-block; min-width: 128px; color: var(--muted); font-size: .85rem; }
.mail-body { white-space: pre-wrap; font: inherit; font-size: .92rem; background: var(--soft); border-radius: 10px; padding: 10px 12px; margin: 6px 0; }

.print-course { background: var(--soft); border-radius: 12px; padding: 10px 12px; }

/* ---------- Schülersuche: Auskunft auf einen Blick ---------- */
.quick-info { display: grid; grid-template-columns: minmax(0, 1fr); gap: 8px; margin: 10px 0; padding: 12px; border: 2px solid var(--aid-light, #dcf5f4); border-radius: 12px; background: #f6fbfb; }
@media (min-width: 700px) { .quick-info { grid-template-columns: minmax(150px, 1fr) minmax(0, 2.5fr); } }
.quick-info label { display: block; font-size: .78rem; font-weight: 700; text-transform: uppercase; letter-spacing: .03em; color: var(--aid-dark, #0b7b7f); }
.quick-info .qi-row { display: flex; flex-wrap: wrap; align-items: center; gap: 4px 12px; }
.quick-info .qi-ok { color: var(--ok); font-weight: 700; }
.quick-info .qi-no { color: var(--danger); font-weight: 700; }
.sc-entry .sc-head { margin: 4px 0 6px; }
.sc-entry .sc-more { margin-top: 8px; }
.sc-entry .sc-more > summary { cursor: pointer; color: var(--muted); padding: 4px 0; }
.pd-who { display: grid; gap: 6px; margin: 0 0 10px; padding: 10px; border: 1px solid var(--line); border-radius: 12px; }
.pd-who label { display: flex; align-items: center; gap: 8px; font-weight: 600; }
.pd-co { margin: 0 0 12px; }
.pd-co > summary { cursor: pointer; color: var(--muted); }
.cs-nr { display: flex; flex-direction: column; align-items: center; gap: 2px; margin: 8px 0 10px; padding: 12px; border: 3px solid var(--aid); border-radius: 14px; background: var(--aid-light, #dcf5f4); text-align: center; }
.cs-nr span { font-weight: 600; }
.cs-nr b { font-size: 3rem; line-height: 1.1; letter-spacing: .04em; color: var(--ink, #0a2a35); }
.cs-nr-miss { border-color: var(--danger); background: #fdecea; }
/* Startseite am Kurstag: große antippbare Zahlen */
.day-tiles { display: grid; grid-template-columns: repeat(auto-fit, minmax(140px, 1fr)); gap: 8px; margin-top: 8px; }
.day-tile { display: flex; flex-direction: column; align-items: flex-start; gap: 2px; padding: 12px; border: 2px solid var(--line); border-radius: 14px; background: #fff; cursor: pointer; text-align: left; font: inherit; color: inherit; }
.day-tile b { font-size: 2rem; line-height: 1; }
.day-tile span { font-size: .85rem; font-weight: 600; color: var(--muted); }
.day-tile.bad { border-color: var(--danger); }
.day-tile.bad b { color: var(--danger); }
.day-tile.ok b { color: var(--ok); }
/* Rechnung per E-Mail gesendet – deutlich sichtbar */
.mail-badge { display: inline-block; padding: 2px 9px; border-radius: 999px; background: #e3f0ff; color: #0b4f9c; font-size: .78rem; font-weight: 700; white-space: nowrap; vertical-align: middle; }
.quick-info .qi-mail { color: #0b4f9c; font-weight: 700; }
/* Anmeldung: dezenter Ausweis-Hinweis, erscheint beim Antippen der Namensfelder */
.id-hint { font-size: .8rem; line-height: 1.45; color: #7a5200; background: #fff8e6; border: 1px solid #f5dfae; border-radius: 10px; padding: 7px 12px; margin: -4px 0 4px; }
.id-hint strong { font-weight: 700; }
#id-hint-more:not([hidden]) { animation: idHintIn .25s ease-out; }
@keyframes idHintIn { from { opacity: 0; } to { opacity: 1; } }

/* ---------- Sehtest: Lesen je Test (flüssig / zögerlich / nichts erkannt) + Notiz – nur intern ---------- */
.st-read { margin-top: 10px; padding: 10px; border-radius: 12px; background: var(--soft); display: grid; gap: 8px; }
.st-read.is-todo { background: var(--warn-light); }
.st-read-head .st-label small { font-size: .78rem; }
.st-read-opts { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 6px; }
.st-read-opt { display: flex; align-items: center; gap: 8px; min-height: 54px; padding: 8px 10px; border: 2px solid var(--line); border-radius: 12px; background: #fff; color: var(--ink); font: inherit; font-weight: 700; font-size: .95rem; line-height: 1.2; text-align: left; cursor: pointer; -webkit-tap-highlight-color: transparent; touch-action: manipulation; }
.st-box { flex: none; width: 26px; height: 26px; border: 2px solid var(--muted); border-radius: 7px; background: #fff; display: inline-flex; align-items: center; justify-content: center; font-weight: 800; font-size: 1rem; }
.st-read-opt.on { border-color: var(--ink); background: var(--aid-light); }
.st-read-opt.on .st-box { background: var(--ink); border-color: var(--ink); color: #fff; }
.st-read-opt.opt-nichts.on { border-color: var(--danger); background: var(--danger-light); }
.st-read-opt.opt-nichts.on .st-box { background: var(--danger); border-color: var(--danger); }
.st-read-opt:focus-visible { outline: 3px solid var(--aid); outline-offset: 2px; }
.st-note { width: 100%; box-sizing: border-box; min-height: 52px; padding: 8px 10px; border: 1.5px solid var(--line); border-radius: 10px; font: inherit; font-size: 16px; resize: vertical; background: #fff; color: var(--ink); }
.st-read-tag { display: inline-block; margin-left: 6px; padding: 2px 8px; border-radius: 999px; font-size: .75rem; font-weight: 800; vertical-align: middle; white-space: nowrap; }
.st-read-tag.todo { background: var(--warn-light); color: #8a4b00; border: 1px dashed #d08a1e; }
.st-read-tag.done { background: var(--aid-light); color: var(--aid-dark); }
@media (max-width: 640px) {
  .st-read-opt { flex-direction: column; justify-content: center; text-align: center; gap: 4px; min-height: 72px; padding: 8px 4px; font-size: .85rem; }
}

/* ---------- Drucken in echtem A4: PDF-Seiten als Bilder, nur während des Druckens sichtbar ---------- */
#print-a4 { display: none; }
@media print {
  body.printing-a4 > *:not(#print-a4) { display: none !important; }
  body.printing-a4 { margin: 0 !important; padding: 0 !important; background: #fff !important; }
  body.printing-a4 #print-a4 { display: block !important; }
  .a4-page { overflow: hidden; break-after: page; page-break-after: always; }
  .a4-page:last-child { break-after: auto; page-break-after: auto; }
  .a4-page img { display: block; }
}
/* Vorschau aus Seitenbildern (A4-PDFs) – ohne die PDF-Leiste des Browsers */
.pv-pages { flex: 1 1 auto; overflow: auto; background: #525659; padding: 16px; }
.pv-pages img { display: block; width: 100%; max-width: 820px; margin: 0 auto 16px; background: #fff; box-shadow: 0 2px 12px rgba(0, 0, 0, .45); }
.pv-wait { color: #fff; text-align: center; margin-top: 40px; font-weight: 700; }
.pv-hint { flex-basis: 100%; }
.pv-hint:empty { display: none; }
