/* Layout: Kopfleiste, darunter je Ansicht Inhalt + Seitenleiste; Startseite mit drei Kacheln */
/* Vereinsfarben MTV Immensen: Blau aus dem Wappen (#383880) und Weiß. Bewusst nur ein helles Erscheinungsbild. */
:root {
  --bg: #f3f4fa;          /* sehr helles Blaugrau */
  --surface: #ffffff;
  --fg: #1c1d3a;          /* fast schwarzes Blau für Text */
  --muted: #5d607d;
  --line: #d8daec;
  --court: #383880;       /* Vereinsblau */
  --court-dark: #2b2b66;
  --court-fg: #ffffff;
  --ball: #e3e4f5;        /* helle Blautönung für Auswahl und Hover */
  --ball-fg: #383880;
  --focus: #6d6dc8;
  --booked: #e9eaf4;
  --booked-fg: #3d3f63;
  --mine: #383880;
  --mine-fg: #ffffff;
  --past: #eff0f6;
  --danger: #b4321f;
  --danger-bg: #fbe9e5;
  --font-display: "Avenir Next Condensed", "Roboto Condensed", "Arial Narrow", "Helvetica Neue", system-ui, sans-serif;
  --font-body: system-ui, -apple-system, "Segoe UI", Roboto, "Helvetica Neue", Arial, sans-serif;
  color-scheme: light;
}
* { box-sizing: border-box; }
[hidden] { display: none !important; }
html { -webkit-text-size-adjust: 100%; }
body {
  margin: 0; background: var(--bg); color: var(--fg); font-family: var(--font-body); font-size: 15px; line-height: 1.45;
}
.wrap {
  max-width: 1100px; margin: 0 auto;
  padding-left: max(16px, env(safe-area-inset-left, 0px));
  padding-right: max(16px, env(safe-area-inset-right, 0px));
  padding-block: 24px 48px;
}
h1 { font-family: var(--font-display); font-stretch: condensed; font-weight: 700; font-size: 2.3rem; line-height: 1.05; margin: 0; text-wrap: balance; }
h1 span { color: var(--court); }
.sub { color: var(--muted); margin: 6px 0 0; max-width: 62ch; }
.empty { color: var(--muted); font-size: 14px; margin: 0; }
.mt { margin-top: 8px; }
.grow { flex: 1; min-width: 0; }

/* Kopfleiste */
.topbar { background: var(--surface); color: var(--court); border-bottom: 4px solid var(--court); padding-top: env(safe-area-inset-top, 0px); }
.topbar-in {
  max-width: 1100px; margin: 0 auto; display: flex; align-items: center; justify-content: space-between; gap: 12px; flex-wrap: wrap;
  padding-left: max(16px, env(safe-area-inset-left, 0px)); padding-right: max(16px, env(safe-area-inset-right, 0px)); padding-block: 10px;
}
.brand { color: inherit; text-decoration: none; display: flex; align-items: center; gap: 10px; min-width: 0; }
.brand img { width: 42px; height: 42px; flex: 0 0 auto; }
.brand-text { display: flex; flex-direction: column; line-height: 1; }
.brand-text b { font-family: var(--font-display); font-stretch: condensed; font-weight: 700; font-size: 1.35rem; letter-spacing: .03em; text-transform: uppercase; }
.brand-text small { font-size: 11px; letter-spacing: .16em; text-transform: uppercase; color: var(--muted); margin-top: 3px; }
.topnav { display: flex; align-items: center; gap: 8px; flex-wrap: wrap; }
.topnav .who { font-size: 14px; color: var(--muted); margin-right: 4px; }
.topbar .btn { background: transparent; color: var(--court); border-color: var(--line); }
.topbar .btn:hover { background: var(--ball); }

/* Ansichten */
.view { display: flex; flex-direction: column; gap: 20px; }
.vhead { display: flex; flex-wrap: wrap; align-items: end; justify-content: space-between; gap: 12px; }
.back { color: var(--muted); text-decoration: none; font-size: 14px; align-self: flex-start; }
.back:hover { color: var(--fg); }
.main { display: grid; grid-template-columns: minmax(0, 1fr) 320px; gap: 20px; align-items: start; }
@media (max-width: 860px) { .main { grid-template-columns: minmax(0, 1fr); } }
.side { display: flex; flex-direction: column; gap: 16px; min-width: 0; }
.panel, .plan { background: var(--surface); border: 1px solid var(--line); border-radius: 14px; padding: 16px; min-width: 0; }
.panel h2 { font-family: var(--font-display); font-stretch: condensed; font-size: 1.35rem; font-weight: 600; margin: 0 0 10px; }
.panel.narrow { max-width: 460px; display: flex; flex-direction: column; gap: 12px; }
.panel.narrow h2 { margin: 0; }
.panel-head { display: flex; justify-content: space-between; align-items: center; gap: 10px; margin-bottom: 10px; }
.panel-head h2 { margin: 0; }
.plan-head { display: flex; justify-content: space-between; align-items: baseline; gap: 10px; flex-wrap: wrap; margin-bottom: 10px; }
.plan-head h2 { font-family: var(--font-display); font-stretch: condensed; font-size: 1.5rem; font-weight: 600; margin: 0; }
.status { font-size: 13px; color: var(--muted); }

/* Formulare & Buttons */
.btn {
  font: inherit; font-size: 14px; font-weight: 500; padding: 8px 14px; border-radius: 8px; cursor: pointer;
  border: 1px solid var(--line); background: var(--surface); color: var(--fg); text-decoration: none; display: inline-block;
}
.btn.primary { background: var(--court); border-color: var(--court); color: var(--court-fg); }
.btn.primary:hover:not(:disabled) { background: var(--court-dark); border-color: var(--court-dark); }
.btn.danger { background: var(--danger-bg); border-color: transparent; color: var(--danger); }
.btn.small { padding: 5px 10px; font-size: 13px; }
.btn:disabled { opacity: .5; cursor: default; }
button:focus-visible, a:focus-visible, input:focus-visible, select:focus-visible, textarea:focus-visible { outline: 2px solid var(--focus); outline-offset: 2px; }
.row { display: flex; gap: 8px; flex-wrap: wrap; align-items: center; }
.row.end { justify-content: flex-end; }
label.f { display: flex; flex-direction: column; gap: 6px; font-size: 13px; color: var(--muted); }
label.f input, label.f select, label.f textarea, .search {
  font: inherit; font-size: 15px; padding: 9px 11px; border-radius: 8px; border: 1px solid var(--line); background: var(--bg); color: var(--fg); width: 100%;
}
label.f textarea { resize: vertical; min-height: 84px; }
label.check { display: flex; gap: 8px; align-items: center; font-size: 14px; }
.flabel { font-size: 13px; color: var(--muted); margin-bottom: 6px; }
.msg { font-size: 13px; color: var(--danger); margin: 0; }
.msg.ok { color: var(--court); }
.toast { position: fixed; left: 50%; transform: translateX(-50%); bottom: calc(20px + env(safe-area-inset-bottom, 0px)); background: var(--fg); color: var(--bg);
  padding: 10px 16px; border-radius: 10px; font-size: 14px; z-index: 30; max-width: calc(100% - 32px); }

/* Login */
.login-view { align-items: center; padding-top: 6vh; }
.login-card { width: 100%; max-width: 400px; background: var(--surface); border: 1px solid var(--line); border-radius: 16px; padding: 24px; display: flex; flex-direction: column; gap: 14px; }
.login-card .sub { margin-top: -6px; }

/* Start */
.start-hero { padding-block: 8px 0; }
.start-hero h1 { font-size: clamp(2.2rem, 6vw, 3.2rem); }
.start-hero p { color: var(--muted); margin: 10px 0 0; max-width: 56ch; }
.choices { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 16px; }
@media (max-width: 900px) { .choices { grid-template-columns: minmax(0, 1fr); } }
.choice { display: flex; flex-direction: column; gap: 10px; padding: 24px; border-radius: 16px; text-decoration: none; min-height: 200px; justify-content: flex-end; position: relative; overflow: hidden; }
@media (max-width: 900px) { .choice { min-height: 150px; } }
.choice.court { background: var(--court); color: var(--court-fg); }
.choice.drinks { background: var(--ball); color: var(--court); border: 1px solid #cfd1ec; }
.choice.drinks p { color: var(--fg); }
.choice.work { background: var(--surface); color: var(--fg); border: 1px solid var(--line); }
.choice.work svg { color: var(--court); }
.choice h2 { font-family: var(--font-display); font-stretch: condensed; font-size: 2rem; font-weight: 700; margin: 0; line-height: 1; }
.choice p { margin: 0; opacity: .85; max-width: 36ch; }
.choice .go { font-weight: 600; font-size: 14px; }
.choice svg { position: absolute; top: 18px; right: 18px; width: 84px; height: 84px; opacity: .9; }
@media (prefers-reduced-motion: no-preference) { .choice { transition: transform .15s; } .choice:hover { transform: translateY(-3px); } }
.start-status { display: flex; gap: 24px; flex-wrap: wrap; align-items: center; }
.start-status .k { font-size: 11px; text-transform: uppercase; letter-spacing: .08em; color: var(--muted); display: block; }
.start-status b { font-family: var(--font-display); font-stretch: condensed; font-size: 1.5rem; font-variant-numeric: tabular-nums; }
.admin-link { align-self: flex-start; }

/* Platzbuchung */
.legend { display: flex; flex-wrap: wrap; gap: 14px; font-size: 13px; color: var(--muted); }
.legend i { display: inline-block; width: 14px; height: 14px; border-radius: 3px; vertical-align: -2px; margin-right: 6px; border: 1px solid var(--line); }
.legend .lg-free { border-style: dashed; }
.legend .lg-booked { background: var(--booked); }
.legend .lg-mine { background: var(--mine); border-color: var(--mine); }
.dates { display: flex; gap: 8px; overflow-x: auto; padding-bottom: 4px; scrollbar-width: thin; }
.date-btn { flex: 0 0 auto; min-width: 62px; padding: 8px 10px; border-radius: 10px; border: 1px solid var(--line); background: var(--surface); color: var(--fg); cursor: pointer; text-align: center; font: inherit; }
.date-btn .dow { display: block; font-size: 11px; text-transform: uppercase; letter-spacing: .08em; color: var(--muted); }
.date-btn .day { display: block; font-family: var(--font-display); font-stretch: condensed; font-size: 1.5rem; font-weight: 600; line-height: 1.1; font-variant-numeric: tabular-nums; }
.date-btn .mon { display: block; font-size: 11px; color: var(--muted); }
.date-btn[aria-pressed="true"] { background: var(--court); border-color: var(--court); color: var(--court-fg); }
.date-btn[aria-pressed="true"] .dow, .date-btn[aria-pressed="true"] .mon { color: var(--court-fg); opacity: .8; }
.grid { display: grid; grid-template-columns: 54px repeat(3, minmax(0, 1fr)); grid-auto-rows: 34px; column-gap: 8px; row-gap: 4px; }
.court-h { grid-row: 1; background: var(--court); color: var(--court-fg); border-radius: 8px; display: flex; flex-direction: column; align-items: center; justify-content: center; line-height: 1.1; min-width: 0; }
.court-h b { font-family: var(--font-display); font-stretch: condensed; font-size: 1.1rem; font-weight: 600; }
.court-h small { font-size: 10px; text-transform: uppercase; letter-spacing: .1em; opacity: .8; }
.time { grid-column: 1; font-size: 12px; color: var(--muted); font-variant-numeric: tabular-nums; display: flex; align-items: center; }
.time.half { opacity: .55; }
.slot { border-radius: 7px; border: 1px dashed var(--line); background: transparent; color: var(--muted); font: inherit; font-size: 12px; cursor: pointer; min-width: 0; }
.slot:hover:not(:disabled) { background: var(--ball); color: var(--ball-fg); border-color: var(--ball); border-style: solid; }
.slot:disabled { background: var(--past); border-style: solid; border-color: transparent; cursor: default; }
.slot .lbl { opacity: 0; }
.slot:hover:not(:disabled) .lbl, .slot:focus-visible .lbl { opacity: 1; }
.booking { border-radius: 7px; background: var(--booked); color: var(--booked-fg); padding: 4px 8px; min-width: 0; display: flex; flex-direction: column; justify-content: center; overflow: hidden; font-size: 12px; line-height: 1.25; border: 0; font-family: inherit; text-align: left; }
.booking.mine { background: var(--mine); color: var(--mine-fg); }
.booking.can { cursor: pointer; }
.booking b { font-weight: 600; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.booking span { white-space: nowrap; overflow: hidden; text-overflow: ellipsis; opacity: .85; font-variant-numeric: tabular-nums; }
.booking.past { opacity: .55; }
.mylist { list-style: none; margin: 0; padding: 0; display: flex; flex-direction: column; gap: 10px; }
.mylist li { border: 1px solid var(--line); border-radius: 10px; padding: 10px 12px; display: flex; flex-direction: column; gap: 6px; }
.mylist .when { font-weight: 600; font-variant-numeric: tabular-nums; display: flex; justify-content: space-between; gap: 8px; }
.mylist .where { font-size: 13px; color: var(--muted); }
.mylist .txt { font-size: 14px; white-space: pre-wrap; overflow-wrap: anywhere; }
.mylist .q { font-size: 13px; }
.rules { margin: 0; padding-left: 18px; color: var(--muted); font-size: 13px; display: flex; flex-direction: column; gap: 4px; }

/* Dialoge */
.sheet-bg { position: fixed; inset: 0; background: rgb(0 0 0 / .45); display: flex; align-items: center; justify-content: center; z-index: 20;
  padding: max(16px, env(safe-area-inset-top, 0px)) max(16px, env(safe-area-inset-right, 0px)) max(16px, env(safe-area-inset-bottom, 0px)) max(16px, env(safe-area-inset-left, 0px)); }
.sheet { background: var(--surface); color: var(--fg); border-radius: 16px; padding: 20px; width: 100%; max-width: 420px; display: flex; flex-direction: column; gap: 14px; max-height: 100%; overflow-y: auto; }
.sheet h3 { font-family: var(--font-display); font-stretch: condensed; font-size: 1.6rem; font-weight: 600; margin: 0; }
.sheet .meta { color: var(--muted); margin: -8px 0 0; }
.durations { display: grid; grid-template-columns: repeat(4, 1fr); gap: 8px; }
.dur { font: inherit; padding: 10px 0; border-radius: 8px; border: 1px solid var(--line); background: var(--surface); color: var(--fg); cursor: pointer; font-variant-numeric: tabular-nums; }
.dur[aria-pressed="true"] { background: var(--ball); color: var(--ball-fg); border-color: var(--ball); font-weight: 600; }
.dur:disabled { opacity: .35; cursor: default; }

/* Getränke */
.drinklist { list-style: none; margin: 0; padding: 0; display: flex; flex-direction: column; }
.drinklist li { display: flex; align-items: center; gap: 12px; padding: 10px 0; border-bottom: 1px solid var(--line); }
.drinklist li:last-child { border-bottom: 0; }
.drinklist .dn { flex: 1; min-width: 0; }
.drinklist .dn b { display: block; font-weight: 600; }
.drinklist .dn small { color: var(--muted); font-size: 12px; }
.drinklist li.has b { color: var(--court); }
.stepper { display: flex; align-items: center; gap: 6px; }
.stepper button { width: 36px; height: 36px; border-radius: 50%; border: 1px solid var(--line); background: var(--surface); color: var(--fg); font-size: 20px; line-height: 1; cursor: pointer; font-family: var(--font-body); }
.stepper button.plus { background: var(--court); color: var(--court-fg); border-color: var(--court); }
.stepper button:disabled { opacity: .35; cursor: default; }
.stepper input { width: 46px; text-align: center; font: inherit; font-size: 16px; font-weight: 600; font-variant-numeric: tabular-nums; border: 1px solid var(--line); border-radius: 8px; padding: 6px 2px; background: var(--bg); color: var(--fg); }
.submit-bar { display: flex; justify-content: space-between; align-items: center; gap: 12px; flex-wrap: wrap; margin-top: 14px; padding-top: 14px; border-top: 1px solid var(--line); }
.submit-bar .sum { color: var(--muted); font-size: 14px; min-width: 0; }
.totals { width: 100%; border-collapse: collapse; font-size: 14px; }
.totals td { padding: 6px 0; border-bottom: 1px solid var(--line); }
.totals td:last-child { text-align: right; font-variant-numeric: tabular-nums; font-weight: 600; }
.totals tr:last-child td { border-bottom: 0; }

/* Arbeitsstunden */
.cal-head { display: flex; align-items: center; justify-content: space-between; gap: 8px; margin-bottom: 10px; }
.cal-head h2 { font-family: var(--font-display); font-stretch: condensed; font-size: 1.5rem; font-weight: 600; margin: 0; }
.cal-nav { width: 36px; height: 36px; border-radius: 50%; border: 1px solid var(--line); background: var(--surface); color: var(--fg); font-size: 18px; cursor: pointer; }
.cal-nav:disabled { opacity: .35; cursor: default; }
.cal { display: grid; grid-template-columns: repeat(7, minmax(0, 1fr)); gap: 4px; }
.cal .wd { font-size: 11px; text-transform: uppercase; letter-spacing: .06em; color: var(--muted); text-align: center; padding-bottom: 4px; }
.cal .d { aspect-ratio: 1 / 1; max-width: 100%; border-radius: 8px; border: 1px solid transparent; background: var(--bg); color: var(--fg); font: inherit; font-variant-numeric: tabular-nums; cursor: pointer; position: relative; display: flex; align-items: center; justify-content: center; }
.cal .d:hover:not(:disabled) { border-color: var(--court); }
.cal .d.today { border-color: var(--court); font-weight: 600; }
.cal .d.sel { background: var(--court); color: var(--court-fg); border-color: var(--court); }
.cal .d:disabled { opacity: .35; cursor: default; }
.cal .d.has::after { content: ""; position: absolute; bottom: 5px; left: 50%; width: 5px; height: 5px; margin-left: -2.5px; border-radius: 50%; background: var(--court); }
.cal .d.sel.has::after { background: var(--court-fg); }
.work-form { display: flex; flex-direction: column; gap: 14px; margin-top: 16px; padding-top: 16px; border-top: 1px solid var(--line); }
.work-form .seldate { font-family: var(--font-display); font-stretch: condensed; font-size: 1.3rem; font-weight: 600; }
.hours-val { min-width: 76px; text-align: center; font-family: var(--font-display); font-stretch: condensed; font-size: 1.4rem; font-weight: 600; font-variant-numeric: tabular-nums; }
.big-num { font-family: var(--font-display); font-stretch: condensed; font-size: 2.6rem; font-weight: 700; line-height: 1; font-variant-numeric: tabular-nums; color: var(--court); margin-bottom: 10px; }
.meter { height: 8px; border-radius: 4px; background: var(--booked); overflow: hidden; }
.meter i { display: block; height: 100%; width: 0; background: var(--court); border-radius: 4px; }

/* Admin */
.yearbar { display: flex; align-items: center; gap: 10px; }
.yearbar b { font-family: var(--font-display); font-stretch: condensed; font-size: 1.4rem; font-weight: 600; font-variant-numeric: tabular-nums; }
.admin-main { display: grid; grid-template-columns: 320px minmax(0, 1fr); gap: 20px; align-items: start; }
@media (max-width: 860px) { .admin-main { grid-template-columns: minmax(0, 1fr); } }
.search { margin-bottom: 10px; }
.users { list-style: none; margin: 0; padding: 0; display: flex; flex-direction: column; gap: 4px; }
.users button { width: 100%; text-align: left; font: inherit; color: var(--fg); background: transparent; border: 1px solid transparent; border-radius: 10px; padding: 9px 10px; cursor: pointer; display: flex; align-items: center; gap: 10px; }
.users button:hover { background: var(--bg); }
.users button[aria-pressed="true"] { background: var(--bg); border-color: var(--court); }
.users .un { flex: 1; min-width: 0; }
.users .un b { display: block; font-weight: 600; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.users .un small { color: var(--muted); font-size: 12px; font-variant-numeric: tabular-nums; }
.users .inactive .un b { color: var(--muted); text-decoration: line-through; }
.avatar { width: 32px; height: 32px; border-radius: 50%; flex: 0 0 auto; background: var(--booked); color: var(--booked-fg); display: inline-flex; align-items: center; justify-content: center; font-size: 12px; font-weight: 700; }
.avatar.admin { background: var(--court); color: var(--court-fg); }
.avatar.big { width: 52px; height: 52px; font-size: 18px; }
.pill { font-size: 11px; font-weight: 600; padding: 3px 8px; border-radius: 999px; white-space: nowrap; font-variant-numeric: tabular-nums; }
.pill.ok { background: var(--court); color: var(--court-fg); }
.pill.open { background: var(--danger-bg); color: var(--danger); }
.pill.off { background: var(--booked); color: var(--booked-fg); }
.detail-head { display: flex; align-items: center; gap: 14px; margin-bottom: 16px; }
.detail-head h2 { font-family: var(--font-display); font-stretch: condensed; font-size: 1.8rem; font-weight: 700; margin: 0; line-height: 1.1; overflow-wrap: anywhere; }
.stats { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 12px; }
@media (max-width: 560px) { .stats { grid-template-columns: minmax(0, 1fr); } }
.stat { border: 1px solid var(--line); border-radius: 12px; padding: 14px; display: flex; flex-direction: column; gap: 6px; min-width: 0; }
.stat .k { font-size: 11px; text-transform: uppercase; letter-spacing: .08em; color: var(--muted); }
.stat .v { font-family: var(--font-display); font-stretch: condensed; font-size: 2rem; font-weight: 700; line-height: 1; font-variant-numeric: tabular-nums; }
.stat .s { font-size: 13px; color: var(--muted); }
.dsec { margin-top: 22px; }
.dsec h3 { font-family: var(--font-display); font-stretch: condensed; font-size: 1.3rem; font-weight: 600; margin: 0 0 8px; }
.table-wrap { overflow-x: auto; }
.all { border-collapse: collapse; font-size: 14px; min-width: 100%; }
.all th, .all td { padding: 8px 10px; border-bottom: 1px solid var(--line); text-align: left; font-variant-numeric: tabular-nums; vertical-align: top; }
.all th { font-size: 11px; text-transform: uppercase; letter-spacing: .06em; color: var(--muted); font-weight: 600; white-space: nowrap; }
.all td.nw { white-space: nowrap; }
.all td.zero { color: var(--muted); }
.all tr.sumrow td { font-weight: 600; border-bottom: 0; }
.manage { border-top: 1px solid var(--line); padding-top: 18px; display: flex; flex-direction: column; gap: 12px; }
.manage h3 { margin: 0; }
.manage-grid { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 12px; }
@media (max-width: 560px) { .manage-grid { grid-template-columns: minmax(0, 1fr); } }
.pwbox { background: var(--bg); border: 1px dashed var(--court); border-radius: 10px; padding: 12px; font-size: 14px; display: flex; flex-direction: column; gap: 8px; }
.pwbox code { font-size: 16px; font-weight: 700; user-select: all; overflow-wrap: anywhere; }
.confirm { background: var(--danger-bg); color: var(--fg); border-radius: 10px; padding: 12px; font-size: 14px; display: flex; flex-direction: column; gap: 10px; }
.confirm p { margin: 0; }
@media (prefers-reduced-motion: no-preference) { .slot, .date-btn, .btn { transition: background .12s, color .12s; } }

/* Getränkekarte (Mitglieder) */
.cat-title { font-family: var(--font-display); font-stretch: condensed; font-size: 1.05rem; font-weight: 700; text-transform: uppercase; letter-spacing: .08em; color: var(--muted); margin: 18px 0 2px; }
.cat-title:first-child { margin-top: 0; }
.drinklist .price { font-variant-numeric: tabular-nums; font-weight: 600; color: var(--fg); white-space: nowrap; }
.drinklist .dn small { display: block; }
.sticky-bar { position: sticky; bottom: env(safe-area-inset-bottom, 0px); background: var(--surface); margin-inline: -16px; padding-inline: 16px; padding-bottom: 4px; z-index: 2; }
.sum b { color: var(--fg); font-variant-numeric: tabular-nums; }
.big-num.credit { color: var(--court); }
.big-num.debt { color: var(--danger); }
.amount { font-variant-numeric: tabular-nums; white-space: nowrap; }

/* Zahlungen (Admin) */
.payform { display: grid; grid-template-columns: 130px 160px minmax(0, 1fr) auto; gap: 10px; align-items: end; margin-bottom: 10px; }
@media (max-width: 700px) { .payform { grid-template-columns: minmax(0, 1fr) minmax(0, 1fr); } .payform .grow2, .payform button { grid-column: 1 / -1; } }
.all td.num, .all th.num { text-align: right; white-space: nowrap; }

/* Getränkekarte bearbeiten (Admin) */
.menu-editor { display: flex; flex-direction: column; gap: 16px; }
.cat-card { background: var(--surface); border: 1px solid var(--line); border-radius: 14px; padding: 14px 16px; display: flex; flex-direction: column; gap: 8px; min-width: 0; }
.cat-card.off { opacity: .7; }
.cat-head { display: flex; gap: 8px; align-items: center; flex-wrap: wrap; }
.cat-head .cat-name { flex: 1 1 200px; min-width: 0; font-family: var(--font-display); font-stretch: condensed; font-size: 1.3rem; font-weight: 700; }
.ed-input { font: inherit; font-size: 14px; padding: 7px 9px; border-radius: 8px; border: 1px solid var(--line); background: var(--bg); color: var(--fg); min-width: 0; }
.ed-input:focus { border-color: var(--court); }
.ed-input.price-in { text-align: right; font-variant-numeric: tabular-nums; }
.iconbtn { width: 32px; height: 32px; border-radius: 8px; border: 1px solid var(--line); background: var(--surface); color: var(--fg); cursor: pointer; font-size: 14px; flex: 0 0 auto; }
.iconbtn:disabled { opacity: .3; cursor: default; }
.prod-row { display: grid; grid-template-columns: 32px 32px minmax(0, 1fr) 80px 92px 140px auto auto; gap: 6px; align-items: center; padding: 6px 0; border-top: 1px solid var(--line); }
.prod-row.off .ed-input { color: var(--muted); text-decoration: line-through; }
.prod-row.head { border-top: 0; font-size: 11px; text-transform: uppercase; letter-spacing: .06em; color: var(--muted); padding-bottom: 0; }
.prod-row.add { grid-template-columns: minmax(0, 1fr) 80px 92px auto; border-top: 1px dashed var(--line); padding-top: 10px; }
.vis { display: flex; align-items: center; gap: 4px; font-size: 12px; color: var(--muted); white-space: nowrap; }
@media (max-width: 760px) {
  .prod-row { grid-template-columns: 32px 32px minmax(0, 1fr) 92px; grid-auto-flow: row dense; }
  .prod-row .unit-in, .prod-row.head { display: none; }
  .prod-row .cat-sel { grid-column: 3 / 4; }
  .prod-row .vis { grid-column: 4 / 5; }
  .prod-row .del { grid-column: 1 / 2; }
  .prod-row span.del { grid-column: 1 / -1; justify-self: end; }
  .prod-row.add { grid-template-columns: minmax(0, 1fr) 92px; }
  .prod-row.add .unit-in { display: none; }
  .prod-row.add button { grid-column: 1 / -1; }
}
.newcat .row { flex-wrap: nowrap; }
.newcat .search { margin: 0; }
.row.nowrap { flex-wrap: nowrap; }
.start-status b.debt, .stat .v.debt { color: var(--danger); }
.statlink { color: inherit; text-decoration: none; }
.statlink:hover b { text-decoration: underline; }
.mylist .when .txt { font-weight: 500; }

/* Logos */
.login-logo { width: 120px; height: auto; align-self: center; margin-bottom: 4px; }
.start-hero { display: flex; align-items: center; justify-content: space-between; gap: 20px; }
.start-hero .hero-logo { width: 110px; height: auto; flex: 0 0 auto; }
@media (max-width: 560px) { .start-hero .hero-logo { width: 72px; } }
.choice svg { color: currentColor; }
/* Kacheltext immer unterhalb des Symbols, damit lange Titel nicht überlappen */
.choice { padding-top: 112px; min-height: 0; justify-content: flex-start; }
.choice svg { width: 72px; height: 72px; top: 22px; left: 24px; right: auto; }
.choice h2 { overflow-wrap: anywhere; }
.users .un small { display: block; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.warn { color: var(--danger) !important; }
#aMeta a { color: var(--court); }
.view .panel.narrow + .panel.narrow { margin-top: 0; }
.pill.admin { background: var(--ball); color: var(--court); }
.start-status .statlink b { color: var(--fg); }
.start-status .statlink b.debt { color: var(--danger); }
.is-admin .member-data { display: none; }
.is-admin .stats { grid-template-columns: minmax(0, 1fr); max-width: 320px; }

/* Bezahlen */
.payinfo { display: flex; flex-direction: column; gap: 10px; }
.payinfo h2 { margin: 0; }
.payinfo p { margin: 0; }
.payinfo .small { font-size: 12px; }
.payinfo .paypal { align-self: flex-start; }
.bank { display: grid; grid-template-columns: auto minmax(0, 1fr); gap: 6px 14px; margin: 4px 0 0; font-size: 14px; align-items: center; }
.bank dt { color: var(--muted); font-size: 12px; text-transform: uppercase; letter-spacing: .06em; }
.bank dd { margin: 0; display: flex; align-items: center; gap: 8px; flex-wrap: wrap; min-width: 0; }
.bank code { font-family: ui-monospace, Menlo, Consolas, monospace; font-size: 14px; font-weight: 600; overflow-wrap: anywhere; user-select: all; }
@media (max-width: 480px) { .bank { grid-template-columns: minmax(0, 1fr); } .bank dt { margin-top: 6px; } }

/* Getränke-Station (Tablet) */
.tablet-view .sub { margin-top: 4px; }
.tsearch { font-size: 18px; padding: 12px 14px; max-width: 480px; }
.tnames { list-style: none; margin: 0; padding: 0; display: grid; grid-template-columns: repeat(auto-fill, minmax(200px, 1fr)); gap: 12px; }
.tname {
  width: 100%; min-height: 72px; display: flex; align-items: center; gap: 12px; padding: 12px 16px; text-align: left;
  font: inherit; font-size: 18px; font-weight: 600; color: var(--fg); background: var(--surface); border: 1px solid var(--line); border-radius: 14px; cursor: pointer;
}
.tname:hover, .tname:active { border-color: var(--court); background: var(--ball); }
.tname .avatar { width: 44px; height: 44px; font-size: 15px; background: var(--court); color: var(--court-fg); }
.thead { display: flex; align-items: center; gap: 16px; flex-wrap: wrap; }
.tablet-view .stepper button { width: 48px; height: 48px; font-size: 24px; }
.tcount { min-width: 40px; text-align: center; font-size: 20px; font-weight: 700; font-variant-numeric: tabular-nums; }
.tablet-view .drinklist li { padding: 12px 0; }
.tablet-view .drinklist .dn b { font-size: 17px; }
.tbig { font-size: 17px; padding: 12px 20px; }
.tdone { max-width: 560px; margin: 4vh auto 0; text-align: center; align-items: center; display: flex; flex-direction: column; gap: 12px; padding: 32px 24px; }
.tdone h1 { font-size: 2rem; }
.tcheck { width: 72px; height: 72px; border-radius: 50%; background: var(--court); color: var(--court-fg); font-size: 40px; line-height: 72px; font-weight: 700; }
.tdone-items { font-size: 18px; margin: 0; }
.row.center { justify-content: center; }
.tstep { display: flex; flex-direction: column; gap: 16px; }

/* Impressum & Fußzeile */
.legal { max-width: 760px; display: flex; flex-direction: column; gap: 4px; padding: 24px; }
.legal h1 { margin-bottom: 8px; }
.legal h2 { font-family: var(--font-display); font-stretch: condensed; font-size: 1.2rem; font-weight: 700; margin: 18px 0 4px; }
.legal p { margin: 0; max-width: 65ch; line-height: 1.55; }
.legal a { color: var(--court); }
.legal .missing { color: var(--danger); font-weight: 600; }
.notice-warn { background: var(--danger-bg); color: var(--danger); border-radius: 10px; padding: 12px 14px; font-size: 14px; }
.sitefoot { border-top: 1px solid var(--line); background: var(--surface); padding-bottom: env(safe-area-inset-bottom, 0px); }
.sitefoot-in { max-width: 1100px; margin: 0 auto; display: flex; justify-content: space-between; gap: 12px; flex-wrap: wrap; font-size: 13px; color: var(--muted);
  padding-left: max(16px, env(safe-area-inset-left, 0px)); padding-right: max(16px, env(safe-area-inset-right, 0px)); padding-block: 14px; }
.sitefoot a { color: var(--court); font-weight: 600; }

/* Buchung: Art des Spiels, Spielform, Spieler */
.game-wrap { display: flex; flex-direction: column; gap: 12px; }
.chips { display: flex; flex-wrap: wrap; gap: 6px; }
.chip { font: inherit; font-size: 14px; padding: 7px 12px; border-radius: 999px; border: 1px solid var(--line); background: var(--surface); color: var(--fg); cursor: pointer; }
.chip[aria-pressed="true"] { background: var(--court); border-color: var(--court); color: var(--court-fg); font-weight: 600; }
.player-fields { display: grid; grid-template-columns: minmax(0, 1fr); gap: 10px; }
.player-fields label.f { gap: 4px; }
.player-fields select, .player-fields input { width: 100%; font-size: 15px; padding: 8px 10px; }
.kind-tag { font-style: normal; font-size: 10px; font-weight: 700; text-transform: uppercase; letter-spacing: .04em; padding: 1px 5px; border-radius: 4px; margin-right: 5px;
  background: var(--court); color: var(--court-fg); vertical-align: 1px; }
.booking.mine .kind-tag { background: var(--court-fg); color: var(--court); }
.booking.k-meisterschaft { box-shadow: inset 4px 0 0 var(--focus); }
.booking.k-punktspiel { box-shadow: inset 4px 0 0 var(--court-dark); }
.booking.mine.k-meisterschaft, .booking.mine.k-punktspiel { box-shadow: inset 4px 0 0 var(--court-fg); }
/* Paarung darf auf zwei Zeilen umbrechen, Art des Spiels steht klein vor der Uhrzeit */
.booking b { white-space: normal; display: -webkit-box; -webkit-line-clamp: 2; -webkit-box-orient: vertical; overflow: hidden; overflow-wrap: anywhere; }
.booking span .kind-tag { font-size: 9px; padding: 0 4px; margin-right: 4px; }
.booking { cursor: pointer; }
.sheet .meta { white-space: pre-line; line-height: 1.6; }
@media (max-width: 560px) { .booking .btime { display: none; } .booking span .kind-tag { margin-right: 0; } }

/* Nachrichten */
.choices { grid-template-columns: repeat(auto-fit, minmax(230px, 1fr)); }
.badge { display: inline-block; min-width: 18px; padding: 0 5px; margin-left: 6px; border-radius: 999px; background: var(--danger); color: #fff; font-size: 11px; font-weight: 700; line-height: 18px; text-align: center; }
.newmsg { display: block; background: var(--court); color: var(--court-fg); border-radius: 12px; padding: 14px 16px; font-weight: 600; text-decoration: none; }
.newmsg:hover { background: var(--court-dark); }
.msglist { list-style: none; margin: 0; padding: 0; display: flex; flex-direction: column; gap: 8px; max-width: 760px; }
.inmsg { background: var(--surface); border: 1px solid var(--line); border-radius: 12px; overflow: hidden; }
.inmsg.unread { border-color: var(--court); }
.msg-head { width: 100%; display: flex; align-items: center; gap: 10px; padding: 14px 16px; background: transparent; border: 0; font: inherit; color: var(--fg); text-align: left; cursor: pointer; }
.msg-dot { width: 9px; height: 9px; border-radius: 50%; background: var(--court); flex: 0 0 auto; }
.msg-subj { flex: 1; min-width: 0; font-weight: 600; overflow-wrap: anywhere; }
.inmsg.unread .msg-subj { color: var(--court); }
.msg-date { font-size: 12px; color: var(--muted); white-space: nowrap; font-variant-numeric: tabular-nums; }
.msg-body { padding: 0 16px 16px; white-space: pre-wrap; overflow-wrap: anywhere; line-height: 1.55; border-top: 1px solid var(--line); padding-top: 12px; }
.msg-main { grid-template-columns: 320px minmax(0, 1fr); }
@media (max-width: 860px) { .msg-main { grid-template-columns: minmax(0, 1fr); } }
.rcpts { list-style: none; margin: 10px 0 0; padding: 0; display: flex; flex-direction: column; gap: 2px; max-height: 420px; overflow-y: auto; }
.rcpt { display: flex; align-items: center; gap: 10px; padding: 7px 6px; border-radius: 8px; cursor: pointer; }
.rcpt:hover { background: var(--bg); }
.rcpt input { width: 18px; height: 18px; flex: 0 0 auto; }
.rcpt b { display: block; font-weight: 600; }
.rcpt small { font-size: 12px; color: var(--muted); }
.empty.small { font-size: 12px; margin-top: 8px; }
.composer { display: flex; flex-direction: column; gap: 12px; }
.composer textarea { min-height: 180px; }
.chip.small { font-size: 12px; padding: 4px 9px; font-family: ui-monospace, Menlo, Consolas, monospace; }
.preview { border: 1px dashed var(--court); border-radius: 10px; padding: 12px 14px; background: var(--bg); display: flex; flex-direction: column; gap: 6px; margin-top: 10px; }
.pv-meta { font-size: 12px; color: var(--muted); }
.pv-subj { font-weight: 700; }
.pv-body { white-space: pre-wrap; overflow-wrap: anywhere; font-size: 14px; line-height: 1.5; }
.panel.narrow.wide { max-width: none; }
.all td.warn, .warn { color: var(--danger); }
#mailForm2 code { font-size: 13px; }
details summary { cursor: pointer; color: var(--court); font-size: 13px; }
