/* Technikplan ÖSGI – Entwurf, Version 2 (2. Oktober 2026)
   Kühle, helle Gestaltung nach ÖSGI-Markenfarben: Cyan (#00A2C3) und Gold (#E9B21A).
   Farbe unterstützt Zustände, Text erklärt sie. */

:root {
  --brand: #00a2c3;        /* ÖSGI-Cyan, Flächen und Kopf */
  --brand-deep: #004664;   /* dunkles Petrol für Überschriften und Kontraste */
  --brand-ink: #007a94;    /* Links und Schaltflächen-Text auf Weiß */
  --brand-soft: #e3f4f8;   /* zarte Flächen */
  --heading: #004664;      /* Überschriften und Titel (im Dunkelmodus hell) */
  --gold: #e9b21a;
  --gold-soft: #fff5d6;

  --bg: #f3f7f9;
  --surface: #ffffff;
  --surface-2: #f6f9fb;
  --text: #15232b;
  --muted: #5b6b74;
  --line: #dde6eb;
  --shadow: 0 1px 2px rgba(0, 70, 100, 0.06), 0 6px 20px rgba(0, 70, 100, 0.06);
  --focus: #004664;

  --red-bg: #fde8e6;   --red-ink: #8a1c1c;  --red-line: #f1a8a3;  --red-dot: #d32f2f;
  --amber-bg: #fff3cd; --amber-ink: #6b4a00; --amber-line: #efcf6a; --amber-dot: #e39a00;
  --green-bg: #e2f5e8; --green-ink: #14532d; --green-line: #8fd4a6; --green-dot: #2e9c5a;
  --off-bg: #eceff1;   --off-ink: #44525a;  --off-line: #c5ced4;
  --info-bg: #e3f4f8;  --info-ink: #004664; --info-line: #9fd9e7;

  --radius: 18px;
  --radius-s: 12px;
  --gap: 14px;
  --tap: 44px;
  --maxw: 640px;
  --maxw-wide: 1120px;
  --font-body: "Noto Sans", system-ui, -apple-system, "Segoe UI", Roboto, Arial, sans-serif;
  --font-head: "Raleway", "Noto Sans", system-ui, -apple-system, "Segoe UI", Roboto, Arial, sans-serif;
}

@media (prefers-color-scheme: dark) {
  :root:not([data-theme="light"]) {
    --brand: #22b8d6; --brand-deep: #0c2a38; --brand-ink: #5fd0e8; --brand-soft: #0f3340; --heading: #bfe9f3;
    --gold: #f0bd2f; --gold-soft: #3a2f10;
    --bg: #0f171c; --surface: #18232a; --surface-2: #1f2c34; --text: #eef3f5; --muted: #a7b6be; --line: #2b3a43;
    --shadow: 0 1px 2px rgba(0,0,0,.4), 0 8px 24px rgba(0,0,0,.35); --focus: #8fe0f2;
    --red-bg: #4a1d1a;   --red-ink: #fecaca;  --red-line: #b4423a;  --red-dot: #f87171;
    --amber-bg: #4a3608; --amber-ink: #fde68a; --amber-line: #a87a0a; --amber-dot: #fbbf24;
    --green-bg: #16311f; --green-ink: #bbf7d0; --green-line: #2f7a4a; --green-dot: #4ade80;
    --off-bg: #2a333a;   --off-ink: #d6dde2;  --off-line: #4b575f;
    --info-bg: #10303c;  --info-ink: #bfe9f3; --info-line: #2c7f97;
  }
}

* { box-sizing: border-box; }
html { -webkit-text-size-adjust: 100%; }
body {
  margin: 0; background: var(--bg); color: var(--text);
  font-family: var(--font-body); font-size: 16px; line-height: 1.5;
  padding-bottom: calc(76px + env(safe-area-inset-bottom));
}
h1, h2, h3 { font-family: var(--font-head); line-height: 1.2; margin: 0 0 8px; color: var(--heading); font-weight: 700; }
h1 { font-size: 1.35rem; } h2 { font-size: 1.2rem; } h3 { font-size: 1.04rem; }
p { margin: 0 0 10px; }
a { color: var(--brand-ink); }
small, .muted { color: var(--muted); } .muted { font-size: 0.95rem; }
ul { margin: 0; padding-left: 1.2em; } .plain { list-style: none; padding: 0; margin: 0; }
.sr-only { position: absolute; width: 1px; height: 1px; overflow: hidden; clip: rect(0 0 0 0); white-space: nowrap; }
.skip-link { position: absolute; left: -999px; top: 8px; background: var(--surface); padding: 8px 12px; border: 2px solid var(--focus); border-radius: 8px; z-index: 100; }
.skip-link:focus { left: 8px; }
:focus-visible { outline: 3px solid var(--focus); outline-offset: 2px; }

/* Vorschau-Leiste (nur im Entwurf) */
.preview {
  background: var(--gold-soft); color: #4a3a00; border-bottom: 2px dashed var(--gold);
  font-size: 0.86rem; padding: 6px 16px;
  display: flex; flex-wrap: wrap; gap: 6px 14px; align-items: center; justify-content: center;
}
@media (prefers-color-scheme: dark) { :root:not([data-theme="light"]) .preview { color: #fde9a8; } }
.preview label { display: inline-flex; align-items: center; gap: 6px; font-weight: 600; }
.preview select, .preview button {
  font: inherit; font-size: 0.86rem; min-height: 34px; border-radius: 8px; border: 1px solid var(--gold); padding: 4px 8px;
  background: var(--surface); color: var(--text); cursor: pointer;
}

/* Kopfzeile mit Logo */
.topbar { position: sticky; top: 0; z-index: 10; background: var(--brand); color: #fff; box-shadow: 0 2px 10px rgba(0, 70, 100, 0.18); }
.topbar-inner { max-width: var(--maxw); margin: 0 auto; padding: 6px 16px; display: flex; align-items: center; gap: 12px; min-height: 60px; }
.topbar-inner.wide { max-width: var(--maxw-wide); }
.topbar .logo { width: 48px; height: 48px; flex: 0 0 auto; }
.topbar h1 { font-size: 1.12rem; margin: 0; flex: 1; color: #fff; font-weight: 700; letter-spacing: 0.01em; }
.topbar .brandline { display: flex; flex-direction: column; flex: 1; min-width: 0; }
.topbar .brandline small { color: rgba(255,255,255,.85); font-size: 0.78rem; letter-spacing: 0.08em; text-transform: uppercase; }
.topbar .back { flex: 0 0 auto; color: #fff; border-color: rgba(255,255,255,.5); background: rgba(255,255,255,.12); }
.session-pill { font-size: 0.84rem; padding: 5px 11px; border-radius: 999px; background: rgba(255,255,255,.16); border: 1px solid rgba(255,255,255,.45); color: #fff; white-space: nowrap; text-decoration: none; }

main { max-width: var(--maxw); margin: 0 auto; padding: 18px 16px 24px; }
main.wide { max-width: var(--maxw-wide); }
section + section { margin-top: 22px; }

/* Karten */
.card { background: var(--surface); border-radius: var(--radius); padding: 16px; margin-bottom: var(--gap); box-shadow: var(--shadow); border: 1px solid transparent; }
.card--link { display: block; color: inherit; text-decoration: none; }
.card--link:hover, .card--link:focus-visible { border-color: var(--brand); }
.card--cancelled { opacity: .9; border: 1px dashed var(--off-line); box-shadow: none; }
.card--sub { background: var(--surface-2); box-shadow: none; border: 1px solid var(--line); }
.card--red { border-left: 6px solid var(--red-dot); }
.card--amber { border-left: 6px solid var(--amber-dot); }
.card--green { border-left: 6px solid var(--green-dot); }

/* Veranstaltungskarte mit Datumsblock */
.ev-head { display: grid; grid-template-columns: 64px 1fr; gap: 14px; align-items: start; }
.datebox { background: var(--brand-soft); color: var(--heading); border-radius: 14px; text-align: center; padding: 8px 4px; line-height: 1.1; }
.datebox .wd { font-size: 0.74rem; text-transform: uppercase; letter-spacing: 0.06em; font-weight: 700; }
.datebox .dd { font-family: var(--font-head); font-size: 1.6rem; font-weight: 800; }
.datebox .mo { font-size: 0.8rem; font-weight: 600; }
.datebox--off { background: var(--off-bg); color: var(--off-ink); }
.datebox--gold { background: var(--gold-soft); color: #5a4200; }
.title { font-family: var(--font-head); font-size: 1.18rem; font-weight: 700; margin: 0 0 2px; color: var(--heading); }
.title.strike { text-decoration: line-through; color: var(--muted); }
.ev-meta { color: var(--muted); font-size: 0.95rem; }
.time { font-variant-numeric: tabular-nums; }
.timegrid { display: grid; grid-template-columns: auto 1fr; gap: 4px 12px; margin: 6px 0; }
.timegrid dt { color: var(--muted); font-size: 0.95rem; } .timegrid dd { margin: 0; font-variant-numeric: tabular-nums; }
.strike { text-decoration: line-through; color: var(--muted); }

/* Chips und Status */
.chip { display: inline-flex; align-items: center; gap: 6px; font-size: 0.86rem; font-weight: 600; line-height: 1.25; padding: 4px 10px; border-radius: 999px; border: 1px solid; }
.chip svg { width: 14px; height: 14px; flex: 0 0 auto; }
.chip--red { background: var(--red-bg); color: var(--red-ink); border-color: var(--red-line); }
.chip--amber { background: var(--amber-bg); color: var(--amber-ink); border-color: var(--amber-line); }
.chip--green { background: var(--green-bg); color: var(--green-ink); border-color: var(--green-line); }
.chip--off { background: var(--off-bg); color: var(--off-ink); border-color: var(--off-line); }
.chip--info { background: var(--info-bg); color: var(--info-ink); border-color: var(--info-line); }
.chips { display: flex; flex-wrap: wrap; gap: 6px; margin-top: 8px; }
.tag { display: inline-block; font-size: 0.78rem; font-weight: 700; color: var(--brand-ink); background: var(--brand-soft); border-radius: 6px; padding: 1px 7px; margin-left: 6px; vertical-align: middle; }
.groups { display: flex; flex-wrap: wrap; gap: 6px 12px; }
.groups .check { min-height: 32px; }
.tag { display: inline-block; font-size: 0.78rem; font-weight: 700; color: var(--brand-ink); background: var(--brand-soft); border-radius: 6px; padding: 1px 7px; margin-left: 6px; vertical-align: middle; }
.groups { display: flex; flex-wrap: wrap; gap: 6px 12px; }
.groups .check { min-height: 32px; }
.banner { border: 1px solid; border-radius: var(--radius-s); padding: 10px 14px; margin-bottom: 12px; font-size: 0.97rem; }
.banner--red { background: var(--red-bg); color: var(--red-ink); border-color: var(--red-line); }
.banner--amber { background: var(--amber-bg); color: var(--amber-ink); border-color: var(--amber-line); }
.banner--green { background: var(--green-bg); color: var(--green-ink); border-color: var(--green-line); }
.banner--off { background: var(--off-bg); color: var(--off-ink); border-color: var(--off-line); }
.banner--info { background: var(--info-bg); color: var(--info-ink); border-color: var(--info-line); }
.banner strong { display: block; margin-bottom: 2px; }
.banner .btn-row { margin-top: 8px; }
.dot { display: inline-block; width: 12px; height: 12px; border-radius: 50%; vertical-align: -1px; margin-right: 6px; }
.dot--red { background: var(--red-dot); } .dot--amber { background: var(--amber-dot); } .dot--green { background: var(--green-dot); }

/* Dienste in der Übersicht: Tag, Zeit, Aufgabe, wer dabei ist */
.svc-list { margin: 12px 0 0; padding: 0; list-style: none; }
.svc-list li { display: grid; grid-template-columns: 1fr auto; gap: 2px 10px; align-items: start; padding: 10px 0; border-top: 1px solid var(--line); font-size: 0.97rem; }
.svc-list .svc-name { font-weight: 700; color: var(--text); }
.svc-list .svc-time { color: var(--muted); font-variant-numeric: tabular-nums; }
.svc-list .svc-day { display: inline-block; font-size: 0.8rem; font-weight: 700; color: var(--brand-ink); background: var(--brand-soft); border-radius: 6px; padding: 1px 7px; margin-right: 6px; }
.svc-list .who { grid-column: 1 / -1; color: var(--text); font-size: 0.93rem; }
.svc-list .who .t { color: var(--muted); }
.svc-list .chip { grid-column: 1 / -1; justify-self: start; }
.count { font-variant-numeric: tabular-nums; font-weight: 700; }
.svc-list .count { white-space: nowrap; text-align: right; }

/* Zeitachse im Detail: Tag → Dienste */
.day { margin-top: 18px; }
.day-head { display: flex; align-items: center; gap: 12px; margin: 0 0 10px; }
.day-head .datebox { width: 64px; flex: 0 0 auto; }
.day-head h2 { margin: 0; font-size: 1.1rem; }
.day-head .muted { display: block; font-size: 0.9rem; }
.slot { border-top: 1px solid var(--line); padding-top: 14px; margin-top: 14px; }
.slot:first-of-type { border-top: 0; padding-top: 0; margin-top: 0; }
.slot-head { display: flex; justify-content: space-between; gap: 10px; flex-wrap: wrap; align-items: baseline; }
.slot-task { font-family: var(--font-head); font-weight: 700; font-size: 1.05rem; color: var(--heading); }
.slot-time { font-size: 1.15rem; font-weight: 700; font-variant-numeric: tabular-nums; }
.people { display: flex; flex-wrap: wrap; gap: 8px; margin: 10px 0; }
.person { display: inline-flex; align-items: center; gap: 8px; background: var(--surface-2); border: 1px solid var(--line); border-radius: 999px; padding: 4px 12px 4px 4px; font-size: 0.96rem; font-weight: 600; }
.person .av { width: 30px; height: 30px; border-radius: 50%; background: var(--brand); color: #fff; display: inline-flex; align-items: center; justify-content: center; font-size: 0.8rem; font-weight: 800; font-family: var(--font-head); flex: 0 0 auto; }
.person--me { border-color: var(--brand); background: var(--brand-soft); }
.person--me .av { background: var(--brand-deep); }
.person--trainee { border-style: dashed; }
.person--guest .av { background: var(--muted); }
.person--reserve { border-style: dotted; } .person--reserve .av { background: var(--amber-dot); color: #3a2a00; }
.person--cancelled { opacity: .6; text-decoration: line-through; } .person--cancelled .av { background: var(--off-line); color: var(--off-ink); }
.lang { font: inherit; font-size: 0.82rem; min-height: 32px; border-radius: 8px; border: 1px solid rgba(255,255,255,.5); background: rgba(255,255,255,.16); color: #fff; padding: 2px 6px; }
.lang option { color: #15232b; } .person--trainee .av { background: var(--gold); color: #3a2a00; }
h2 .x { font-size: 1rem; vertical-align: middle; }
.person .x, h2 .x { font: inherit; border: 0; background: transparent; color: var(--brand-ink); cursor: pointer; padding: 0 2px; min-width: 28px; min-height: 28px; }
.empty { color: var(--muted); font-style: italic; }

/* Buttons */
.btn { font: inherit; font-size: 0.95rem; font-weight: 700; min-height: 40px; padding: 6px 16px; border-radius: 999px; border: 2px solid var(--brand-ink); background: var(--brand-ink); color: #fff; cursor: pointer; display: inline-flex; align-items: center; justify-content: center; gap: 8px; text-decoration: none; }
.btn:hover { filter: brightness(1.08); }
.btn--secondary { background: var(--surface); color: var(--brand-ink); }
.btn--ghost { background: transparent; border-color: var(--line); color: var(--text); }
.btn--danger { background: var(--surface); border-color: #b91c1c; color: #b91c1c; }
.btn--block { width: 100%; }
@media (min-width: 720px) { .btn--block { width: auto; min-width: 220px; } }
.btn--small { min-height: 34px; padding: 4px 12px; font-size: 0.88rem; }
.btn[disabled] { opacity: .55; cursor: not-allowed; }
.btn-row { display: flex; flex-wrap: wrap; gap: 8px; margin-top: 10px; }
@media (prefers-color-scheme: dark) { :root:not([data-theme="light"]) .btn { color: #06202a; } :root:not([data-theme="light"]) .btn--secondary { color: var(--brand-ink); } :root:not([data-theme="light"]) .btn--ghost { color: var(--text); } :root:not([data-theme="light"]) .btn--danger { color: #fca5a5; border-color: #fca5a5; } }

/* Filterleiste */
.filters { display: flex; gap: 8px; flex-wrap: wrap; margin-bottom: 12px; }
.filters .btn { min-height: 36px; padding: 4px 14px; font-size: 0.9rem; }
.filters .btn[aria-pressed="true"] { background: var(--brand-deep); border-color: var(--brand-deep); color: #fff; }
.legend { display: flex; flex-wrap: wrap; gap: 6px 16px; font-size: 0.88rem; color: var(--muted); margin: 0 0 14px; }

/* Formulare */
.field { display: block; margin-bottom: 12px; }
.field > span { display: block; font-weight: 600; font-size: 0.93rem; margin-bottom: 4px; color: var(--heading); }
.field input[type="text"], .field input[type="time"], .field input[type="date"], .field input[type="number"], .field input[type="password"], .field input[type="email"], .field select, .field textarea {
  font: inherit; width: 100%; min-height: var(--tap); padding: 8px 12px; border: 1px solid var(--line); border-radius: var(--radius-s); background: var(--surface); color: var(--text);
}
.field textarea { min-height: 80px; resize: vertical; }
.field-row { display: grid; grid-template-columns: 1fr 1fr; gap: 10px; align-items: end; }
.field-row-3 { display: grid; grid-template-columns: 1fr 1fr 1fr; gap: 10px; align-items: end; }
.check { display: flex; align-items: center; gap: 10px; min-height: 40px; cursor: pointer; }
.check input { width: 24px; height: 24px; margin: 0; accent-color: var(--brand-ink); flex: 0 0 auto; }
.hint { font-size: 0.9rem; color: var(--muted); margin-top: 4px; }
.error { color: var(--red-ink); background: var(--red-bg); border: 1px solid var(--red-line); border-radius: 8px; padding: 8px 10px; margin-bottom: 10px; }

/* Kalender-Auswahl */
.cal-table { width: 100%; border-collapse: collapse; background: var(--surface); border-radius: var(--radius); box-shadow: var(--shadow); overflow: hidden; }
.cal-table th { text-align: left; font-size: 0.86rem; color: var(--muted); padding: 10px 12px; border-bottom: 1px solid var(--line); text-transform: uppercase; letter-spacing: 0.04em; }
.cal-table td { padding: 12px; border-bottom: 1px solid var(--line); vertical-align: middle; }
.cal-table input[type="checkbox"] { width: 26px; height: 26px; accent-color: var(--brand-ink); display: block; }
.cal-table .t-time { font-variant-numeric: tabular-nums; white-space: nowrap; }
@media (max-width: 719px) {
  .cal-table { background: transparent; box-shadow: none; }
  .cal-table thead { display: none; }
  .cal-table, .cal-table tbody, .cal-table tr, .cal-table td { display: block; }
  .cal-table tr { background: var(--surface); border-radius: var(--radius); box-shadow: var(--shadow); padding: 12px 14px; margin-bottom: 10px; display: grid; grid-template-columns: auto 1fr; gap: 2px 12px; align-items: center; }
  .cal-table td { padding: 0; border: 0; }
  .cal-table td.t-check { grid-row: 1 / span 3; }
  .cal-table td.t-title { font-weight: 700; }
  .cal-table td.t-status { grid-column: 2; }
}
.admin-table { width: 100%; border-collapse: collapse; }
.admin-table th { text-align: left; font-size: 0.86rem; color: var(--muted); padding: 8px 10px; border-bottom: 1px solid var(--line); text-transform: uppercase; letter-spacing: 0.04em; }
.admin-table td { padding: 10px; border-bottom: 1px solid var(--line); vertical-align: middle; }
.role-select { font: inherit; font-size: 0.93rem; min-height: 36px; padding: 4px 8px; border: 1px solid var(--line); border-radius: 10px; background: var(--surface); color: var(--text); }
@media (max-width: 719px) {
  .admin-table thead { display: none; }
  .admin-table, .admin-table tbody, .admin-table tr, .admin-table td { display: block; }
  .admin-table tr { border: 1px solid var(--line); border-radius: var(--radius-s); padding: 10px 12px; margin-bottom: 10px; }
  .admin-table td { padding: 2px 0; border: 0; }
  .admin-table td[data-label]::before { content: attr(data-label) ": "; color: var(--muted); font-size: 0.9rem; }
}
/* Terminübersicht: am Handy untereinander, am Desktop als horizontal scrollbare Reihe */
.ev-grid { display: grid; gap: 0; }
@media (min-width: 900px) {
  .ev-grid { display: grid; grid-auto-flow: column; grid-auto-columns: 400px; gap: 16px; align-items: start; overflow-x: auto; overscroll-behavior-x: contain; scroll-snap-type: x proximity; padding: 4px 4px 14px; margin: 0 -4px; scrollbar-width: thin; }
  .ev-grid .card { margin-bottom: 0; scroll-snap-align: start; }
  .ev-grid::-webkit-scrollbar { height: 10px; } .ev-grid::-webkit-scrollbar-thumb { background: var(--line); border-radius: 999px; }
}
@media print { .ev-grid { display: block; overflow: visible; } }
.strip { position: relative; }
.strip-btn { display: none; }
.strip-dots { display: none; }
@media (min-width: 900px) {
  .strip--scrollable { padding: 0 64px; }
  .strip--scrollable .strip-btn { display: inline-flex; position: absolute; top: 50%; transform: translateY(-50%); z-index: 3; width: 48px; height: 48px; border-radius: 50%; border: 1px solid var(--line); background: var(--surface); color: var(--brand-ink); font-size: 2rem; line-height: 1; align-items: center; justify-content: center; cursor: pointer; box-shadow: var(--shadow); }
  .strip-btn--prev { left: 0; } .strip-btn--next { right: 0; }
  .strip--start .strip-btn--prev, .strip--end .strip-btn--next { opacity: .35; pointer-events: none; }
  .strip--scrollable .strip-dots { display: flex; justify-content: center; gap: 6px; margin-top: 2px; }
  .dot-btn { width: 10px; height: 10px; border-radius: 50%; border: 0; background: var(--line); padding: 0; cursor: pointer; }
  .dot-btn--on { background: var(--brand-ink); }
}
.svc-dayhead { display: flex !important; gap: 8px; align-items: baseline; padding: 10px 0 2px !important; border-top: 0 !important; font-size: 0.8rem !important; text-transform: uppercase; letter-spacing: 0.05em; color: var(--brand-ink); font-weight: 700; }
.svc-dayhead span:last-child { color: var(--muted); font-weight: 600; }
.svc-dayhead--pre { color: #8a5a00; }
.svc-dayhead + li { border-top: 0; }
/* Teamverwaltung: Suche, feste Kopfzeile, Symbol-Buttons */
.team-tools { display: flex; gap: 12px; align-items: center; justify-content: space-between; flex-wrap: wrap; margin-bottom: 8px; }
.team-tools h2 { margin: 0; }
.team-tools input[type="search"] { font: inherit; width: 100%; min-height: 40px; padding: 6px 12px; border: 1px solid var(--line); border-radius: 999px; background: var(--surface); color: var(--text); }
.admin-table--sticky thead th { position: sticky; top: 60px; background: var(--surface); z-index: 2; }
.admin-table--sticky td { padding: 6px 10px; }
.iconbar { display: flex; gap: 6px; flex-wrap: nowrap; }
.iconbtn { width: 36px; height: 36px; border-radius: 10px; border: 1px solid var(--line); background: var(--surface); color: var(--brand-ink); cursor: pointer; display: inline-flex; align-items: center; justify-content: center; padding: 0; }
.iconbtn svg { width: 18px; height: 18px; }
.iconbtn:hover { border-color: var(--brand-ink); }
.iconbtn--primary { background: var(--brand-ink); color: #fff; border-color: var(--brand-ink); }
.iconbtn--ok { color: var(--green-ink); }
.iconbtn--danger { color: #b91c1c; }
.iconbtn[disabled] { opacity: .4; cursor: not-allowed; }
@media (max-width: 719px) { .admin-table--sticky thead th { top: 0; } }

/* Programm / Ablauf */
.prog { width: 100%; border-collapse: collapse; }
.prog td { padding: 8px 8px 8px 0; border-top: 1px solid var(--line); vertical-align: top; }
.prog tr:first-child td { border-top: 0; }
.prog-time { width: 64px; font-variant-numeric: tabular-nums; font-weight: 700; white-space: nowrap; }
.prog-who { width: 34%; }
.prog--open td { background: var(--amber-bg); }
.prog .tech { color: var(--brand-ink); font-weight: 600; }
.prog--edit td:last-child { width: 1%; white-space: nowrap; }
.split { display: grid; gap: 16px; }
.team-grid { display: grid; gap: 16px; }
@media (min-width: 900px) { .team-grid > div { display: grid; grid-template-columns: 1fr 1fr; gap: 16px; align-items: start; } .admin-table td:last-child .btn-row { flex-wrap: wrap; margin-top: 0; } .admin-table .btn { white-space: nowrap; } }
@media (min-width: 900px) { .split { grid-template-columns: minmax(300px, 2fr) 3fr; align-items: start; } .split > * { min-width: 0; } }

/* Untere Navigation */
.nav { position: fixed; left: 0; right: 0; bottom: 0; z-index: 10; background: var(--surface); border-top: 1px solid var(--line); padding-bottom: env(safe-area-inset-bottom); box-shadow: 0 -4px 16px rgba(0,70,100,.06); }
.nav-inner { max-width: var(--maxw); margin: 0 auto; display: flex; }
.nav a { flex: 1; min-height: 56px; display: flex; flex-direction: column; align-items: center; justify-content: center; gap: 3px; text-decoration: none; color: var(--muted); font-size: 0.78rem; font-weight: 700; }
.nav a svg { width: 24px; height: 24px; }
.nav a[aria-current="page"] { color: var(--brand-ink); }

.toast { position: fixed; left: 50%; bottom: calc(84px + env(safe-area-inset-bottom)); transform: translateX(-50%); background: var(--brand-deep); color: #fff; padding: 10px 16px; border-radius: 999px; max-width: calc(100% - 32px); opacity: 0; pointer-events: none; transition: opacity .2s; z-index: 50; font-size: 0.95rem; }
.toast.show { opacity: 1; }
.copybox { font: inherit; width: 100%; min-height: 120px; border: 1px solid var(--line); border-radius: var(--radius-s); padding: 10px; background: var(--surface-2); color: var(--text); }
.demo-note { font-size: 0.85rem; color: var(--muted); text-align: center; margin-top: 24px; }
@media (prefers-reduced-motion: reduce) { .toast { transition: none; } }

/* Druckansicht / PDF */
.print-head { display: flex; align-items: center; gap: 12px; margin-bottom: 12px; }
.print-head img { width: 44px; height: 44px; background: var(--brand); border-radius: 10px; padding: 4px; }
.print-table { width: 100%; border-collapse: collapse; font-size: 0.92rem; background: var(--surface); border-radius: var(--radius); box-shadow: var(--shadow); overflow: hidden; }
.print-table th { text-align: left; font-size: 0.8rem; text-transform: uppercase; letter-spacing: 0.04em; color: var(--muted); padding: 8px 10px; border-bottom: 1px solid var(--line); }
.print-table td { padding: 8px 10px; border-bottom: 1px solid var(--line); vertical-align: top; }
.print-table tr.ev td { background: var(--brand-soft); font-weight: 700; color: var(--heading); }
.print-table .st { white-space: nowrap; }
.print-table .st::before { content: ''; display: inline-block; width: 10px; height: 10px; border-radius: 50%; margin-right: 6px; vertical-align: -1px; }
.print-table .st--red::before { background: var(--red-dot); } .print-table .st--amber::before { background: var(--amber-dot); } .print-table .st--green::before { background: var(--green-dot); } .print-table .st--off::before { background: var(--off-line); }
@page { size: A4 portrait; margin: 12mm 10mm; }
@media print {
  html, body { background: #fff; color: #000; padding: 0; margin: 0; font-size: 9.5pt; }
  .print-table { font-size: 9pt; }
  .print-table td, .print-table th { padding: 4px 6px; }
  .print-table thead { display: table-header-group; }
  .print-table tbody.evgroup { break-inside: avoid; page-break-inside: avoid; }
  .print-head h2 { font-size: 14pt; }
  .topbar, .nav, .preview, .toast, .no-print { display: none !important; }
  main { max-width: none; padding: 0; }
  .print-table { box-shadow: none; border-radius: 0; }
  .print-table tr.ev td { background: #e3f4f8 !important; -webkit-print-color-adjust: exact; print-color-adjust: exact; }
  .print-table .st::before { -webkit-print-color-adjust: exact; print-color-adjust: exact; }
  .print-head img { -webkit-print-color-adjust: exact; print-color-adjust: exact; }
  a { color: inherit; text-decoration: none; }
  tr { break-inside: avoid; }
}
