/* ============================================================
   TVR Portal – mein.tvr-basketball.de
   Mobile-First · große Touch-Targets · TVR-Farben
   ============================================================ */

/* ── Barlow (selbst gehostet, DSGVO) ─────────────────────────
   Lege die Schriftdateien unter /assets/fonts/ ab.
   Bis dahin greift der System-Fallback automatisch. */
@font-face {
  font-family: 'Barlow';
  src: url('fonts/Barlow-Regular.woff2') format('woff2');
  font-weight: 400; font-style: normal; font-display: swap;
}
@font-face {
  font-family: 'Barlow';
  src: url('fonts/Barlow-SemiBold.woff2') format('woff2');
  font-weight: 600; font-style: normal; font-display: swap;
}
@font-face {
  font-family: 'Barlow';
  src: url('fonts/Barlow-Bold.woff2') format('woff2');
  font-weight: 700; font-style: normal; font-display: swap;
}
@font-face {
  font-family: 'Barlow Condensed';
  src: url('fonts/BarlowCondensed-SemiBold.woff2') format('woff2');
  font-weight: 600; font-style: normal; font-display: swap;
}

:root {
  --red:        #C8221A;
  --red-dark:   #9e1914;
  --red-light:  #e8302a;
  --black:      #0d0d0d;
  --dark:       #161616;
  --card:       #1e1e1e;
  --border:     #2a2a2a;
  --white:      #f5f5f5;
  --muted:      #888888;
  --green:      #2e9e44;
  --green-dark: #237a35;

  --safe-bottom: env(safe-area-inset-bottom, 0px);
  --navh: 64px;
  --font: 'Barlow', system-ui, -apple-system, 'Segoe UI', Roboto, sans-serif;
  --cond: 'Barlow Condensed', 'Barlow', system-ui, sans-serif;
}

* { box-sizing: border-box; -webkit-tap-highlight-color: transparent; }

html, body {
  margin: 0; padding: 0;
  background: var(--black);
  color: var(--white);
  font-family: var(--font);
  font-size: 17px;
  line-height: 1.45;
  -webkit-font-smoothing: antialiased;
}

a { color: var(--red-light); text-decoration: none; }

/* ── Topbar ──────────────────────────────────────────────── */
.topbar {
  position: sticky; top: 0; z-index: 50;
  background: var(--dark);
  border-bottom: 1px solid var(--border);
  padding-top: env(safe-area-inset-top, 0px);
}
.topbar-inner {
  display: flex; align-items: center; justify-content: space-between;
  height: 56px; padding: 0 16px;
}
.brand { display: flex; flex-direction: column; line-height: 1; }
.brand-mark {
  font-family: var(--cond);
  font-weight: 700; font-size: 24px; letter-spacing: 1px;
  color: var(--red); text-transform: uppercase;
}
.brand-sub { font-size: 11px; color: var(--muted); margin-top: 2px; }

.profil-switch {
  display: flex; align-items: center; gap: 6px;
  background: var(--card); border: 1px solid var(--border);
  color: var(--white); font-weight: 600;
  padding: 10px 14px; border-radius: 999px;
  min-height: 44px;
}
.ps-caret { color: var(--muted); }

.topbar-title {
  font-family: var(--cond);
  font-weight: 600; font-size: 22px;
  padding: 10px 16px 14px;
  text-transform: uppercase; letter-spacing: .5px;
}

/* ── Content ─────────────────────────────────────────────── */
.content {
  padding: 16px 16px calc(var(--navh) + var(--safe-bottom) + 24px);
  max-width: 640px; margin: 0 auto;
}

/* ── Karten ──────────────────────────────────────────────── */
.card {
  background: var(--card);
  border: 1px solid var(--border);
  border-radius: 16px;
  padding: 18px;
  margin-bottom: 14px;
}
.card h2, .card h3 { margin: 0 0 8px; font-family: var(--cond); text-transform: uppercase; }
.muted { color: var(--muted); }

/* Anklickbare Karte (z.B. Kind auswählen) */
.card-btn {
  display: block; width: 100%; text-align: left;
  background: var(--card); border: 1px solid var(--border);
  border-radius: 16px; padding: 18px; margin-bottom: 14px;
  color: var(--white); font-family: var(--font); font-size: 17px;
  cursor: pointer;
}
.card-btn:active { transform: scale(.99); border-color: var(--red); }
.card-btn .chevron { color: var(--muted); font-size: 22px; }

/* ── Buttons (große Daumen-Targets) ──────────────────────── */
.btn {
  display: flex; align-items: center; justify-content: center;
  width: 100%; min-height: 56px;
  border: none; border-radius: 14px;
  font-family: var(--font); font-weight: 700; font-size: 18px;
  color: #fff; background: var(--red);
  cursor: pointer; user-select: none;
  padding: 0 18px; margin-bottom: 12px;
}
.btn:active { transform: scale(.98); }
.btn-dark   { background: var(--card); border: 1px solid var(--border); color: var(--white); }
.btn-ghost  { background: transparent; border: 1px solid var(--border); color: var(--white); }
.btn:disabled { opacity: .5; }

/* Zusage / Absage – das zentrale Aktionspaar */
.btn-row { display: flex; gap: 12px; }
.btn-row .btn { margin-bottom: 0; }
.btn-zu { background: var(--green); }
.btn-zu:active { background: var(--green-dark); }
.btn-ab { background: var(--red); }
.btn-ab:active { background: var(--red-dark); }
.btn-unsicher { background: var(--card); border: 1px solid var(--border); }

/* ── Status-Pills ────────────────────────────────────────── */
.pill {
  display: inline-flex; align-items: center;
  font-size: 13px; font-weight: 600;
  padding: 4px 12px; border-radius: 999px;
}
.pill-zu       { background: rgba(46,158,68,.18);  color: #5fd07a; }
.pill-ab       { background: rgba(200,34,26,.18);  color: var(--red-light); }
.pill-offen    { background: var(--card); color: var(--muted); border: 1px solid var(--border); }
.pill-unsicher { background: rgba(200,150,20,.18); color: #e0b341; }
.pill-pending  { background: rgba(200,150,20,.18); color: #e0b341; }

/* ── Formulare ───────────────────────────────────────────── */
label { display: block; font-weight: 600; margin: 14px 0 6px; }
input[type=text], input[type=email], input[type=password],
input[type=date], select, textarea {
  width: 100%; min-height: 52px;
  background: var(--black); color: var(--white);
  border: 1px solid var(--border); border-radius: 12px;
  padding: 0 14px; font-size: 17px; font-family: var(--font);
}
textarea { padding: 12px 14px; min-height: 90px; }
input:focus, select:focus, textarea:focus { outline: 2px solid var(--red); border-color: var(--red); }

.checkbox-row { display: flex; align-items: flex-start; gap: 12px; margin: 16px 0; }
.checkbox-row input[type=checkbox] { width: 26px; height: 26px; margin-top: 2px; flex: 0 0 auto; accent-color: var(--red); }

/* ── Meldungen ───────────────────────────────────────────── */
.msg { border-radius: 12px; padding: 14px 16px; margin-bottom: 14px; font-weight: 600; }
.msg-err { background: rgba(200,34,26,.15); border: 1px solid var(--red); color: #ffb3ae; }
.msg-ok  { background: rgba(46,158,68,.15); border: 1px solid var(--green); color: #9be4ac; }

/* ── Bottom-Navigation ───────────────────────────────────── */
.bottomnav {
  position: fixed; left: 0; right: 0; bottom: 0; z-index: 60;
  display: flex; background: var(--dark);
  border-top: 1px solid var(--border);
  padding-bottom: var(--safe-bottom);
  height: calc(var(--navh) + var(--safe-bottom));
}
.bn-item {
  flex: 1; display: flex; flex-direction: column;
  align-items: center; justify-content: center; gap: 3px;
  color: var(--muted); font-size: 11px; font-weight: 600;
  min-height: var(--navh);
}
.bn-ico { font-size: 22px; line-height: 1; }
.bn-item.is-active { color: var(--red-light); }

/* ── Diverses ────────────────────────────────────────────── */
.center { text-align: center; }
.stack > * + * { margin-top: 12px; }
.spacer { height: 8px; }
.hr { height: 1px; background: var(--border); border: 0; margin: 18px 0; }
