/* IT-TI – Farben und Grundbausteine aus dem Designkonzept */
:root {
  --gruen: #17A88B; --gruen-dunkel: #0E6E5A; --gruen-hell: #DDF3EC;
  --blau: #2B7BD9; --blau-dunkel: #1A5AA6; --blau-hell: #E0ECFA;
  --tinte: #13293D; --grau: #4A5B6C; --nebel: #EEF4F7; --linie: #D5E1E8;
  --rot: #A12C2C; --rot-hell: #FBE4E4; --orange: #8A5300; --orange-hell: #FCEFD9;
  --glas: rgba(255,255,255,0.75);
  --verlauf: linear-gradient(135deg, #17A88B, #2B7BD9);
}
/* Dunkelmodus folgt der Systemeinstellung */
@media (prefers-color-scheme: dark) {
  :root { --tinte: #E6EEF3; --grau: #A9B8C4; --nebel: #0F1E2B; --linie: #2A3F52; --glas: rgba(23,42,58,0.8);
    --gruen-hell: #123E35; --blau-hell: #16304D; --rot-hell: #4A1F1F; --orange-hell: #43321A; --gruen-dunkel: #7CD9C2; --blau-dunkel: #9CC7F5; --rot: #FF9E9E; --orange: #F5C98A; }
}
* { box-sizing: border-box; }
body { margin: 0; font-family: Inter, system-ui, sans-serif; color: var(--tinte); background: var(--nebel); min-height: 100vh; }
body::before, body::after { content: ""; position: fixed; z-index: -1; width: 480px; height: 480px; border-radius: 50%; filter: blur(100px); pointer-events: none; }
body::before { background: var(--gruen); opacity: .15; top: -180px; right: 5%; }
body::after { background: var(--blau); opacity: .12; bottom: -200px; left: 0; }
h1, h2, h3 { font-family: Manrope, sans-serif; margin: 0; }
h1 { font-size: clamp(28px, 5vw, 40px); font-weight: 800; letter-spacing: -.5px; }
h2 { font-size: 22px; font-weight: 700; }
a { color: var(--blau-dunkel); }
p { margin: 0; line-height: 1.5; }
.leise { color: var(--grau); }
.klein { font-size: 13px; }

.seite { max-width: 1160px; margin: 0 auto; padding: 24px; display: flex; flex-direction: column; gap: 28px; }
.karte { background: var(--glas); backdrop-filter: blur(18px); border: 1px solid rgba(255,255,255,.6); border-radius: 24px; box-shadow: 0 10px 30px rgba(19,41,61,.07); padding: 24px; display: flex; flex-direction: column; gap: 12px; }
.raster { display: grid; grid-template-columns: repeat(auto-fit, minmax(240px, 1fr)); gap: 16px; }
.zeile { display: flex; flex-wrap: wrap; gap: 12px; align-items: center; justify-content: space-between; }

.nav { display: flex; flex-wrap: wrap; gap: 12px; align-items: center; justify-content: space-between; padding: 10px 14px; background: var(--glas); backdrop-filter: blur(18px); border: 1px solid rgba(255,255,255,.6); border-radius: 18px; }
.logo { display: flex; align-items: center; gap: 10px; font-family: Manrope, sans-serif; font-weight: 800; font-size: 18px; text-decoration: none; color: var(--tinte); }
.logo i { width: 32px; height: 32px; border-radius: 10px; background: var(--verlauf); display: inline-block; }
.nav-links { display: flex; flex-wrap: wrap; gap: 4px; }
.nav-links a { padding: 10px 14px; border-radius: 12px; color: var(--tinte); text-decoration: none; font-weight: 600; font-size: 15px; }
.nav-links a.aktiv { background: var(--tinte); color: var(--nebel); }

.btn { min-height: 48px; padding: 0 20px; border-radius: 14px; border: 1px solid #C9D7E0; background: rgba(255,255,255,.85); color: #13293D; font: 600 16px Inter, sans-serif; cursor: pointer; display: inline-flex; align-items: center; justify-content: center; text-decoration: none; }
.btn.haupt { border: 0; background: var(--verlauf); color: #fff; }
.btn.dunkel { border: 0; background: #13293D; color: #fff; }
.btn:disabled { opacity: .5; cursor: default; }
.btn:focus-visible, input:focus-visible, select:focus-visible, textarea:focus-visible, a:focus-visible { outline: 3px solid var(--blau); outline-offset: 2px; }

label { font-size: 14px; font-weight: 600; display: block; margin-bottom: 6px; }
input, select, textarea { width: 100%; min-height: 48px; padding: 10px 14px; border: 1px solid #C9D7E0; border-radius: 14px; background: rgba(255,255,255,.92); color: #13293D; font: 16px Inter, sans-serif; }
textarea { min-height: 110px; resize: vertical; }
.feld { display: flex; flex-direction: column; }
form { display: flex; flex-direction: column; gap: 16px; }

.badge { padding: 4px 10px; border-radius: 999px; font-size: 13px; font-weight: 600; white-space: nowrap; }
.s-offen { background: var(--rot-hell); color: var(--rot); }
.s-in_arbeit { background: var(--orange-hell); color: var(--orange); }
.s-warte { background: var(--blau-hell); color: var(--blau-dunkel); }
.s-erledigt { background: var(--gruen-hell); color: var(--gruen-dunkel); }

.fehler { padding: 12px 14px; border-radius: 12px; background: var(--rot-hell); color: var(--rot); font-size: 14px; }
.ok { padding: 12px 14px; border-radius: 12px; background: var(--gruen-hell); color: var(--gruen-dunkel); font-size: 14px; }

/* Login */
.login { min-height: 100vh; display: flex; align-items: center; justify-content: center; padding: 24px; }
.login .karte { width: 100%; max-width: 400px; padding: 36px; gap: 20px; }

/* Chat */
.chat { display: flex; flex-direction: column; gap: 12px; }
.blase { max-width: 78%; padding: 12px 16px; border-radius: 18px; display: flex; flex-direction: column; gap: 4px; line-height: 1.5; white-space: pre-wrap; }
.blase.fremd { align-self: flex-start; background: rgba(255,255,255,.9); border: 1px solid var(--linie); border-bottom-left-radius: 6px; color: #13293D; }
.blase.eigen { align-self: flex-end; background: var(--gruen-hell); border-bottom-right-radius: 6px; }
.blase.intern { align-self: stretch; max-width: none; background: var(--orange-hell); color: var(--orange); border-radius: 10px; }
.blase .wer { font-size: 12px; font-weight: 700; opacity: .8; }

/* Admin: klassisch */
.admin { display: flex; flex-wrap: wrap; min-height: 100vh; background: #F3F7F9; color: #13293D; }
.admin-menue { flex: 1 1 220px; max-width: 100%; background: #13293D; color: #fff; padding: 20px 14px; display: flex; flex-direction: column; gap: 4px; }
.admin-menue a { padding: 10px 12px; border-radius: 6px; color: #D3DEE6; text-decoration: none; font-size: 14px; display: flex; justify-content: space-between; }
.admin-menue a.aktiv { background: #24425C; color: #fff; font-weight: 600; }
.admin-inhalt { flex: 999 1 560px; min-width: 0; padding: 28px; display: flex; flex-direction: column; gap: 22px; }
.admin .kasten { background: #fff; border: 1px solid #D5E1E8; border-radius: 8px; }
.admin .kasten-kopf { padding: 14px 16px; border-bottom: 1px solid #D5E1E8; display: flex; justify-content: space-between; align-items: center; gap: 12px; }
.tabelle-box { overflow-x: auto; }
table { width: 100%; border-collapse: collapse; font-size: 14px; }
th { text-align: left; background: #F3F7F9; padding: 10px 16px; }
td { padding: 10px 16px; border-top: 1px solid #E6EDF1; }
tr.klickbar { cursor: pointer; }
tr.klickbar:hover td { background: #F7FAFB; }
.admin .btn { min-height: 38px; border-radius: 6px; font-size: 14px; padding: 0 14px; }
.admin input, .admin select, .admin textarea { border-radius: 6px; min-height: 40px; font-size: 15px; }
.zahl { font-family: Manrope, sans-serif; font-size: 30px; font-weight: 800; }
.admin .blase.fremd { background: #fff; }
@media (prefers-color-scheme: dark) { .admin { color-scheme: light; } }

/* ---------- Ergänzungen für alle Phasen ---------- */
.sr { position: absolute; width: 1px; height: 1px; overflow: hidden; clip: rect(0 0 0 0); }
.s-neutral { background: #E6EDF1; color: #4A5B6C; }
.zaehler { background: #D64545; color: #fff; border-radius: 4px; padding: 0 7px; font-size: 12px; font-weight: 600; }
.liste-zeile { display: flex; justify-content: space-between; align-items: center; gap: 12px; padding: 10px 0; border-top: 1px solid var(--linie); flex-wrap: wrap; }
.anhang { display: block; max-width: 240px; max-height: 180px; border-radius: 10px; margin-top: 6px; object-fit: cover; }

/* Startseite: News + Warnungen */
.start-zweispaltig { display: flex; flex-wrap: wrap; gap: 24px; align-items: flex-start; }
.start-zweispaltig > section { flex: 999 1 520px; min-width: 0; }
.start-zweispaltig > aside { flex: 1 1 300px; }
.news { display: flex; gap: 16px; background: var(--glas); backdrop-filter: blur(18px); border: 1px solid rgba(255,255,255,.6); border-radius: 22px; overflow: hidden; }
.news img, .news .news-farbe { width: 180px; min-height: 140px; object-fit: cover; flex-shrink: 0; }
.news .news-farbe { background: var(--verlauf); opacity: .85; }
.news .news-text { padding: 18px 18px 18px 0; display: flex; flex-direction: column; gap: 6px; }
.news h3 { font-size: 19px; }
.news.gross { flex-direction: column; }
.news.gross img, .news.gross .news-farbe { width: 100%; height: 220px; min-height: 0; }
.news.gross .news-text { padding: 4px 22px 22px; }
.news.gross h3 { font-size: 24px; }
@media (max-width: 560px) { .news { flex-direction: column; } .news img, .news .news-farbe { width: 100%; height: 160px; } .news .news-text { padding: 4px 18px 18px; } }
.warnungen { border-left: 0; }
.warn-ul { list-style: none; margin: 0; padding: 0; display: flex; flex-direction: column; }
.warn-ul li { padding: 10px 0; border-top: 1px solid var(--linie); display: flex; flex-direction: column; gap: 2px; }
.warn-ul a { color: var(--tinte); font-weight: 600; text-decoration: none; font-size: 14px; line-height: 1.4; }
.warn-ul a:hover { text-decoration: underline; }
.warn-ul span { font-size: 12px; color: var(--grau); }

/* Buchen */
.slots { display: grid; grid-template-columns: repeat(auto-fill, minmax(88px, 1fr)); gap: 8px; }
.slot { min-height: 44px; border-radius: 12px; border: 1px solid #C9D7E0; background: #fff; color: #13293D; font: 500 15px Inter, sans-serif; cursor: pointer; }
.slot[aria-pressed="true"] { border: 2px solid var(--gruen); background: #DDF3EC; color: #0E6E5A; font-weight: 700; }

/* Belege zum Drucken */
.druck-leiste { display: flex; justify-content: space-between; align-items: center; max-width: 794px; margin: 16px auto; padding: 0 12px; }
.a4 { width: 794px; min-height: 1123px; margin: 0 auto 40px; background: #fff; color: #13293D; padding: 64px 72px 56px; display: flex; flex-direction: column; gap: 32px; position: relative; box-shadow: 0 10px 40px rgba(0,0,0,.12); }
.a4 .leise, .a5 .leise { color: #4A5B6C; }
.a4 .logo span { display: flex; flex-direction: column; } .a4 .logo small { font: 400 12px Inter; color: #4A5B6C; }
.a4 h1 { font-size: 38px; }
.ueberzeile { font-size: 12px; font-weight: 600; letter-spacing: 1px; text-transform: uppercase; color: #0E6E5A; }
.infobox { padding: 18px 20px; border-radius: 14px; background: #EEF4F7; display: flex; flex-direction: column; gap: 4px; font-size: 14px; line-height: 1.5; }
.raster2 { display: grid; grid-template-columns: auto 1fr; column-gap: 16px; } .raster2 strong { text-align: right; }
.beleg-tabelle th { background: none; border-bottom: 1px solid #13293D; padding: 0 0 10px; color: #4A5B6C; }
.beleg-tabelle td { padding: 14px 0; border-top: 0; border-bottom: 1px solid #D5E1E8; }
.betrag-box { width: 320px; padding: 22px 24px; border-radius: 16px; border: 2px solid #17A88B; display: flex; flex-direction: column; gap: 8px; }
.gross-zahl { font-family: Manrope, sans-serif; font-size: 30px; font-weight: 800; }
.unterschrift { font-family: Manrope, sans-serif; font-size: 22px; font-weight: 700; font-style: italic; color: #1A5AA6; }
.fusszeile { padding-top: 14px; border-top: 1px solid #D5E1E8; font-size: 12px; color: #4A5B6C; }
.a4.xmas { border-top: 10px solid; border-image: repeating-linear-gradient(90deg, #C0392B 0 24px, #fff 24px 36px, #17A88B 36px 60px, #fff 60px 72px) 10; }
.xmas-gruss { color: #A93226; font-weight: 600; margin-top: 6px; }
.a5 { width: 794px; height: 559px; margin: 0 auto 40px; background: #fff; color: #13293D; display: flex; box-shadow: 0 10px 40px rgba(0,0,0,.12); }
.a5-links { width: 300px; padding: 48px 40px; background: #13293D; color: #fff; display: flex; flex-direction: column; justify-content: space-between; }
.a5-betrag { font-family: Manrope, sans-serif; font-size: 84px; font-weight: 800; line-height: 1; letter-spacing: -2px; }
.a5-rechts { flex: 1; padding: 48px 44px; display: flex; flex-direction: column; gap: 22px; }
.linie-feld { font-weight: 600; padding-bottom: 6px; border-bottom: 1px solid #C9D7E0; min-height: 24px; }
@media print {
  body { background: #fff !important; } body::before, body::after, .druck-leiste { display: none !important; }
  .a4, .a5 { box-shadow: none; margin: 0; }
  @page { margin: 0; }
}

/* Terminal (Tablet im TV-Hub) */
.terminal { min-height: 100vh; background: #EEF2F5; color: #13293D; display: flex; flex-direction: column; }
.t-kopf { height: 72px; padding: 0 32px; background: #13293D; color: #fff; display: flex; align-items: center; justify-content: space-between; }
.t-trenner { width: 1px; height: 24px; background: #3A5671; margin: 0 6px; }
.t-info { display: flex; gap: 18px; align-items: center; color: #D3DEE6; } .t-info span { display: flex; gap: 8px; align-items: center; }
.t-punkt { width: 10px; height: 10px; border-radius: 50%; background: #3DDC97; display: inline-block; }
.t-raster { flex: 1; padding: 28px 32px; display: grid; grid-template-columns: repeat(auto-fit, minmax(340px, 1fr)); gap: 28px; }
.t-spalte { display: flex; flex-direction: column; gap: 16px; }
.t-box { background: #fff; border: 1px solid #D5E1E8; border-radius: 12px; padding: 16px 20px; display: flex; flex-direction: column; gap: 8px; }
.t-gross { flex: 1; padding: 32px; justify-content: space-between; gap: 24px; }
.t-avatar { width: 56px; height: 56px; border-radius: 50%; background: #DDF3EC; color: #0E6E5A; display: flex; align-items: center; justify-content: center; font: 800 22px Manrope, sans-serif; }
.t-status { padding: 10px 18px; border-radius: 999px; font-size: 18px; font-weight: 700; }
.t-an { background: #DDF3EC; color: #0E6E5A; } .t-pause { background: #FCEFD9; color: #8A5300; } .t-aus { background: #E6EDF1; color: #4A5B6C; }
.t-uhr { font: 800 clamp(72px, 10vw, 112px) Manrope, sans-serif; letter-spacing: -3px; line-height: 1; font-variant-numeric: tabular-nums; }
.t-summen { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 12px; }
.t-summen div { padding: 14px 16px; border-radius: 10px; background: #F3F7F9; display: flex; flex-direction: column; gap: 4px; }
.t-summen strong { font: 800 26px Manrope, sans-serif; }
.t-knopf { flex: 1; min-height: 110px; border: 0; border-radius: 12px; padding: 0 32px; display: flex; flex-direction: column; justify-content: center; align-items: flex-start; gap: 2px; cursor: pointer; font-family: Inter, sans-serif; }
.t-knopf span { font-size: 34px; font-weight: 700; } .t-knopf small { font-size: 16px; opacity: .85; }
.t-knopf:disabled { opacity: .35; cursor: default; }
.tk-kommen { background: #0E7C66; color: #fff; } .tk-pause { background: #F2A541; color: #13293D; } .tk-gehen { background: #13293D; color: #fff; }

/* Weihnachtsdesign (in den Einstellungen freischaltbar) */
body.weihnachten::before { background: #C0392B; opacity: .12; }
body.weihnachten .nav { border-top: 4px solid #C0392B; }
body.weihnachten .logo i { background: linear-gradient(135deg, #C0392B, #17A88B); }
body.weihnachten .btn.haupt { background: linear-gradient(135deg, #C0392B, #17A88B); }
