/* ==========================================================================
   OnThisDay – Stylesheet
   Designsystem an ck1969.de angelehnt, ergänzt um einen warmen Archiv-Akzent.
   ========================================================================== */

:root {
  --bg: #f7f8fa;
  --surface: rgba(255, 255, 255, 0.82);
  --surface-strong: #ffffff;
  --surface-soft: #eef2f4;
  --text: #16202a;
  --muted: #5f6d7a;
  --faint: #8a97a4;
  --line: rgba(22, 32, 42, 0.12);

  --blue: #007AFF;
  --green: #2EBF78;
  --teal: #1B8E85;
  --purple: #5E5CE6;
  --amber: #C77C21;
  --red: #E5484D;

  --shadow-sm: 0 10px 30px rgba(17, 24, 39, 0.08);
  --shadow-md: 0 16px 48px rgba(17, 24, 39, 0.10);
  --shadow-lg: 0 24px 80px rgba(17, 24, 39, 0.14);
  --radius-lg: 28px;
  --radius-md: 20px;
  --radius-sm: 14px;
}

@media (prefers-color-scheme: dark) {
  :root {
    --bg: #0f1419;
    --surface: rgba(25, 31, 38, 0.82);
    --surface-strong: #171d24;
    --surface-soft: #222a33;
    --text: #edf3f8;
    --muted: #aab8c5;
    --faint: #7d8b99;
    --line: rgba(237, 243, 248, 0.12);
    --amber: #E8A33D;
    --shadow-sm: 0 10px 30px rgba(0, 0, 0, 0.22);
    --shadow-md: 0 16px 48px rgba(0, 0, 0, 0.28);
    --shadow-lg: 0 24px 80px rgba(0, 0, 0, 0.34);
  }
}

* { box-sizing: border-box; }

html { scroll-behavior: smooth; background: var(--surface-soft); }
@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }
  *, *::before, *::after { animation-duration: 0.001ms !important; transition-duration: 0.001ms !important; }
}

body {
  margin: 0;
  font-family: Inter, system-ui, -apple-system, BlinkMacSystemFont, 'Segoe UI', sans-serif;
  color: var(--text);
  background:
    radial-gradient(circle at top left, rgba(0, 122, 255, 0.10), transparent 28%),
    radial-gradient(circle at top right, rgba(46, 191, 120, 0.10), transparent 30%),
    radial-gradient(circle at 50% 120%, rgba(94, 92, 230, 0.10), transparent 40%),
    linear-gradient(180deg, var(--bg), var(--surface-soft));
  background-repeat: no-repeat;
  min-height: 100vh;
  line-height: 1.6;
  -webkit-font-smoothing: antialiased;
}

img, svg { display: block; max-width: 100%; }
a { color: inherit; }

::selection { background: rgba(0, 122, 255, 0.22); }

:focus-visible {
  outline: 3px solid color-mix(in srgb, var(--blue) 65%, transparent);
  outline-offset: 3px;
  border-radius: 6px;
}

.wrap { max-width: 1120px; margin: 0 auto; padding: 0 20px 80px; }
.skip-link {
  position: absolute; left: -9999px; top: 0; z-index: 100;
  background: var(--surface-strong); padding: 12px 18px; border-radius: 0 0 12px 0;
}
.skip-link:focus { left: 0; }

/* --------------------------------------------------------------------------
   Kopfleiste
   -------------------------------------------------------------------------- */

.topbar {
  position: sticky; top: 0; z-index: 50;
  backdrop-filter: blur(18px);
  -webkit-backdrop-filter: blur(18px);
  background: color-mix(in srgb, var(--bg) 74%, transparent);
  border-bottom: 1px solid var(--line);
}
.topbar-inner {
  max-width: 1120px; margin: 0 auto; padding: 14px 20px;
  display: flex; align-items: center; justify-content: space-between; gap: 18px;
}
.brand { display: flex; align-items: center; gap: 12px; text-decoration: none; min-height: 44px; }
/* Trägt jetzt das Kalenderblatt-SVG; Verlauf und Rundung bringt es selbst mit */
.brand-mark {
  width: 42px; height: 42px; flex: 0 0 42px;
  display: grid; place-items: center;
  filter: drop-shadow(0 6px 16px rgba(17, 24, 39, 0.16));
}
.brand-mark svg { width: 42px; height: 42px; display: block; }
.brand-text strong { display: block; font-size: .98rem; letter-spacing: -0.01em; }
.brand-text span { display: block; color: var(--muted); font-size: .84rem; }

nav ul { display: flex; gap: 6px; list-style: none; margin: 0; padding: 0; flex-wrap: wrap; }
nav a {
  text-decoration: none; min-height: 44px; display: inline-flex; align-items: center;
  padding: 10px 14px; border-radius: 999px; border: 1px solid transparent;
  color: var(--muted); font-size: .93rem; transition: background .18s, color .18s, border-color .18s;
}
nav a:hover, nav a:focus-visible { border-color: var(--line); color: var(--text); background: var(--surface); }
nav a.is-cta { color: #fff; background: linear-gradient(135deg, var(--blue), var(--teal)); font-weight: 650; }
nav a.is-cta:hover { color: #fff; filter: brightness(1.06); }

/* --------------------------------------------------------------------------
   Hero
   -------------------------------------------------------------------------- */

.hero { padding: 56px 0 12px; display: grid; grid-template-columns: 1.05fr 0.95fr; gap: 44px; align-items: center; }

.pill {
  display: inline-flex; align-items: center; gap: 8px;
  padding: 7px 14px 7px 10px; border-radius: 999px;
  border: 1px solid var(--line); background: var(--surface);
  font-size: .82rem; font-weight: 600; color: var(--muted);
  box-shadow: var(--shadow-sm);
}
.pill .dot {
  width: 8px; height: 8px; border-radius: 50%;
  background: var(--green); box-shadow: 0 0 0 4px color-mix(in srgb, var(--green) 22%, transparent);
}

.hero h1 {
  margin: 20px 0 0;
  font-size: clamp(2.3rem, 5.2vw, 3.5rem);
  line-height: 1.06; letter-spacing: -0.035em; font-weight: 800;
}
.hero h1 .grad {
  background: linear-gradient(115deg, var(--blue), var(--teal) 45%, var(--purple));
  -webkit-background-clip: text; background-clip: text; color: transparent;
}
.hero .lead { margin: 20px 0 0; font-size: 1.11rem; color: var(--muted); max-width: 56ch; }

.hero-actions { margin-top: 28px; display: flex; gap: 12px; flex-wrap: wrap; align-items: center; }

.hero-meta { margin-top: 26px; display: flex; gap: 26px; flex-wrap: wrap; }
.hero-meta div strong { display: block; font-size: 1.35rem; letter-spacing: -0.02em; }
.hero-meta div span { font-size: .84rem; color: var(--muted); }

/* --------------------------------------------------------------------------
   Buttons
   -------------------------------------------------------------------------- */

.btn {
  text-decoration: none; min-height: 48px; cursor: pointer;
  display: inline-flex; align-items: center; justify-content: center; gap: 10px;
  padding: 13px 22px; border-radius: 16px; font-weight: 700; font-size: .97rem;
  border: 1px solid var(--line); font-family: inherit;
  transition: transform .16s ease, filter .16s ease, background .16s ease;
}
.btn:hover { transform: translateY(-1px); }
.btn:active { transform: translateY(0); }
.btn-primary {
  background: linear-gradient(135deg, var(--blue), var(--teal));
  color: #fff; border-color: transparent; box-shadow: 0 12px 30px rgba(0, 122, 255, 0.28);
}
.btn-primary:hover { filter: brightness(1.06); }
.btn-secondary { background: var(--surface-strong); color: var(--text); }
.btn-secondary:hover { background: var(--surface-soft); }
.btn-ghost { background: transparent; color: var(--muted); }
.btn-ghost:hover { background: var(--surface); color: var(--text); }
.btn-danger { background: var(--surface-strong); color: var(--red); border-color: color-mix(in srgb, var(--red) 35%, transparent); }
.btn-danger:hover { background: color-mix(in srgb, var(--red) 10%, var(--surface-strong)); }
.btn-sm { min-height: 38px; padding: 8px 14px; font-size: .86rem; border-radius: 11px; }
.btn[disabled] { opacity: .55; cursor: not-allowed; transform: none; }

/* --------------------------------------------------------------------------
   Karten
   -------------------------------------------------------------------------- */

.card {
  border: 1px solid var(--line); border-radius: var(--radius-lg);
  background: var(--surface); backdrop-filter: blur(18px); -webkit-backdrop-filter: blur(18px);
  box-shadow: var(--shadow-lg);
}
.card-pad { padding: 30px; }

.section { padding-top: 64px; }
.section-head { max-width: 62ch; }
.kicker {
  font-size: .78rem; text-transform: uppercase; letter-spacing: .1em;
  color: var(--muted); font-weight: 800;
}
.section h2 { margin: 8px 0 0; font-size: clamp(1.6rem, 3vw, 2.1rem); letter-spacing: -0.028em; }
.section > .section-head > p { color: var(--muted); margin: 12px 0 0; }

/* --------------------------------------------------------------------------
   Kalenderblatt (abgerissene Seite)
   -------------------------------------------------------------------------- */

.sheet {
  position: relative;
  border: 1px solid var(--line); border-radius: var(--radius-lg);
  background: var(--surface-strong);
  box-shadow: var(--shadow-lg);
  overflow: hidden;
}
.sheet::before {
  content: ''; position: absolute; inset: 0 0 auto; height: 6px;
  background: linear-gradient(90deg, var(--amber), var(--blue) 55%, var(--purple));
}
.sheet-holes {
  display: flex; gap: 26px; justify-content: center;
  padding: 18px 0 0;
}
.sheet-holes i {
  width: 11px; height: 11px; border-radius: 50%;
  background: var(--surface-soft);
  box-shadow: inset 0 1px 2px rgba(0, 0, 0, .22);
}
.sheet-body { padding: 10px 32px 30px; text-align: center; }
.sheet-weekday {
  font-size: .82rem; font-weight: 800; letter-spacing: .16em;
  text-transform: uppercase; color: var(--amber);
}
.sheet-day {
  font-size: clamp(5rem, 15vw, 7.4rem); line-height: .95; font-weight: 800;
  letter-spacing: -0.06em; margin: 6px 0 2px;
  background: linear-gradient(160deg, var(--text), color-mix(in srgb, var(--text) 55%, var(--blue)));
  -webkit-background-clip: text; background-clip: text; color: transparent;
}
.sheet-month { font-size: 1.35rem; font-weight: 750; letter-spacing: -0.02em; }
.sheet-facts {
  margin: 22px 0 0; padding: 16px 0 0; border-top: 1px dashed var(--line);
  display: grid; grid-template-columns: repeat(3, 1fr); gap: 10px;
}
.sheet-facts div strong { display: block; font-size: 1.05rem; letter-spacing: -0.02em; }
.sheet-facts div span { font-size: .74rem; color: var(--muted); text-transform: uppercase; letter-spacing: .06em; }
.sheet-teaser {
  margin: 20px 0 0; padding: 16px 18px; border-radius: var(--radius-sm);
  background: var(--surface-soft); text-align: left; font-size: .93rem; color: var(--muted);
}
.sheet-teaser strong { color: var(--text); display: block; font-size: .74rem; text-transform: uppercase; letter-spacing: .09em; margin-bottom: 5px; }

/* --------------------------------------------------------------------------
   Ablauf in drei Schritten
   -------------------------------------------------------------------------- */

.steps { margin-top: 28px; display: grid; grid-template-columns: repeat(3, 1fr); gap: 20px; }
.step {
  padding: 26px; border: 1px solid var(--line); border-radius: var(--radius-lg);
  background: var(--surface); backdrop-filter: blur(18px); box-shadow: var(--shadow-sm);
}
.step-no {
  width: 42px; height: 42px; border-radius: 13px; display: grid; place-items: center;
  font-weight: 800; font-size: 1.05rem; color: #fff; margin-bottom: 14px;
}
.step:nth-child(1) .step-no { background: linear-gradient(135deg, var(--blue), var(--teal)); }
.step:nth-child(2) .step-no { background: linear-gradient(135deg, var(--green), var(--teal)); }
.step:nth-child(3) .step-no { background: linear-gradient(135deg, var(--purple), var(--blue)); }
.step h3 { margin: 0 0 6px; font-size: 1.1rem; letter-spacing: -0.02em; }
.step p { margin: 0; color: var(--muted); font-size: .95rem; }

/* --------------------------------------------------------------------------
   Anmeldeformular
   -------------------------------------------------------------------------- */

.signup { margin-top: 28px; overflow: hidden; }
.signup-grid { display: grid; grid-template-columns: 1.15fr 0.85fr; }
.signup-form { padding: 34px; }
.signup-side {
  padding: 34px; border-left: 1px solid var(--line);
  background:
    radial-gradient(circle at 80% 0%, color-mix(in srgb, var(--blue) 14%, transparent), transparent 55%),
    var(--surface-soft);
}
.signup-side h3 { margin: 0 0 14px; font-size: 1.05rem; letter-spacing: -0.02em; }
.check-list { list-style: none; margin: 0; padding: 0; display: grid; gap: 13px; }
.check-list li { display: flex; gap: 11px; font-size: .93rem; color: var(--muted); line-height: 1.55; }
.check-list svg { flex: 0 0 20px; margin-top: 2px; color: var(--green); }

.field { margin-bottom: 20px; }
.field > label {
  display: block; font-size: .84rem; font-weight: 700; letter-spacing: .02em;
  margin-bottom: 8px; color: var(--text);
}
.field .hint { display: block; font-weight: 500; color: var(--muted); font-size: .82rem; margin-top: 6px; }

.input, select.input {
  width: 100%; font: inherit; font-size: 1rem; color: var(--text);
  padding: 14px 16px; min-height: 52px;
  border-radius: var(--radius-sm); border: 1px solid var(--line);
  background: var(--surface-strong);
  transition: border-color .16s, box-shadow .16s;
  -webkit-appearance: none; appearance: none;
}
.input::placeholder { color: var(--faint); }
.input:focus {
  outline: none; border-color: color-mix(in srgb, var(--blue) 60%, transparent);
  box-shadow: 0 0 0 4px color-mix(in srgb, var(--blue) 16%, transparent);
}
.input[aria-invalid="true"] { border-color: color-mix(in srgb, var(--red) 60%, transparent); }

.time-row { display: flex; gap: 12px; align-items: center; flex-wrap: wrap; }
.time-row .input { max-width: 150px; }
.chips { display: flex; gap: 8px; flex-wrap: wrap; }
.chip {
  border: 1px solid var(--line); background: var(--surface-strong); color: var(--muted);
  border-radius: 999px; padding: 8px 14px; font: inherit; font-size: .86rem; font-weight: 650;
  cursor: pointer; min-height: 38px; transition: all .16s;
}
.chip:hover { color: var(--text); border-color: color-mix(in srgb, var(--blue) 40%, var(--line)); }
.chip.is-active {
  background: color-mix(in srgb, var(--blue) 12%, var(--surface-strong));
  border-color: color-mix(in srgb, var(--blue) 45%, transparent); color: var(--blue);
}

.consent { display: flex; gap: 12px; align-items: flex-start; font-size: .89rem; color: var(--muted); }
.consent input[type="checkbox"] {
  width: 21px; height: 21px; margin: 2px 0 0; flex: 0 0 21px; accent-color: var(--blue); cursor: pointer;
}
.hp { position: absolute; left: -9999px; width: 1px; height: 1px; overflow: hidden; }

/* --------------------------------------------------------------------------
   Meldungen
   -------------------------------------------------------------------------- */

.alert {
  display: flex; gap: 14px; align-items: flex-start;
  padding: 16px 18px; border-radius: var(--radius-md);
  border: 1px solid var(--line); background: var(--surface-strong);
  margin-bottom: 22px; font-size: .95rem; box-shadow: var(--shadow-sm);
}
.alert strong { display: block; margin-bottom: 3px; }
.alert p { margin: 0; color: var(--muted); }
.alert-icon { flex: 0 0 24px; margin-top: 1px; }
.alert-success { border-color: color-mix(in srgb, var(--green) 45%, transparent); background: color-mix(in srgb, var(--green) 8%, var(--surface-strong)); }
.alert-success .alert-icon { color: var(--green); }
.alert-error { border-color: color-mix(in srgb, var(--red) 45%, transparent); background: color-mix(in srgb, var(--red) 8%, var(--surface-strong)); }
.alert-error .alert-icon { color: var(--red); }
.alert-info { border-color: color-mix(in srgb, var(--blue) 40%, transparent); background: color-mix(in srgb, var(--blue) 8%, var(--surface-strong)); }
.alert-info .alert-icon { color: var(--blue); }

/* --------------------------------------------------------------------------
   Vorschau: Zeitstrahl
   -------------------------------------------------------------------------- */

.preview-card { margin-top: 28px; padding: 32px; }
.preview-head { display: flex; align-items: baseline; justify-content: space-between; gap: 16px; flex-wrap: wrap; margin-bottom: 6px; }
.preview-head h3 { margin: 0; font-size: 1.5rem; letter-spacing: -0.028em; }
.preview-head .date { color: var(--muted); font-size: .93rem; }

.rubric { margin-top: 30px; }
.rubric-title {
  font-size: .76rem; font-weight: 800; letter-spacing: .12em; text-transform: uppercase;
  display: flex; align-items: center; gap: 10px; margin-bottom: 16px;
}
.rubric-title::after { content: ''; flex: 1; height: 1px; background: var(--line); }
.rubric-events .rubric-title { color: var(--blue); }
.rubric-births .rubric-title { color: var(--green); }
.rubric-deaths .rubric-title { color: var(--purple); }
.rubric-holidays .rubric-title { color: var(--amber); }

.timeline { list-style: none; margin: 0; padding: 0 0 0 4px; position: relative; }
.timeline::before {
  content: ''; position: absolute; left: 43px; top: 10px; bottom: 10px; width: 2px;
  background: linear-gradient(180deg, transparent, var(--line) 12%, var(--line) 88%, transparent);
}
.timeline li { position: relative; display: flex; gap: 18px; padding: 11px 0; }
.year {
  flex: 0 0 78px; text-align: center; align-self: flex-start;
  font-size: .84rem; font-weight: 800; letter-spacing: -0.01em;
  padding: 6px 6px; border-radius: 999px; border: 1px solid var(--line);
  background: var(--surface-strong); position: relative; z-index: 1;
}
.rubric-events .year { color: var(--blue); border-color: color-mix(in srgb, var(--blue) 30%, transparent); background: color-mix(in srgb, var(--blue) 8%, var(--surface-strong)); }
.rubric-births .year { color: var(--green); border-color: color-mix(in srgb, var(--green) 30%, transparent); background: color-mix(in srgb, var(--green) 8%, var(--surface-strong)); }
.rubric-deaths .year { color: var(--purple); border-color: color-mix(in srgb, var(--purple) 30%, transparent); background: color-mix(in srgb, var(--purple) 8%, var(--surface-strong)); }

.entry { flex: 1; min-width: 0; }
.entry-text { margin: 3px 0 0; line-height: 1.6; }
.entry-text a { text-decoration: none; border-bottom: 1px solid color-mix(in srgb, var(--blue) 35%, transparent); }
.entry-text a:hover { border-bottom-color: var(--blue); }
.entry-desc { margin: 4px 0 0; font-size: .89rem; color: var(--muted); }
.entry-thumb {
  flex: 0 0 62px; width: 62px; height: 62px; border-radius: 16px; object-fit: cover;
  border: 1px solid var(--line); background: var(--surface-soft);
}

.holiday-grid { display: grid; grid-template-columns: repeat(2, 1fr); gap: 14px; }
.holiday {
  padding: 16px 18px; border-radius: var(--radius-md);
  border: 1px solid var(--line); background: var(--surface-strong);
}
.holiday span { display: block; font-size: .7rem; font-weight: 800; letter-spacing: .09em; text-transform: uppercase; color: var(--amber); }
.holiday p { margin: 4px 0 0; font-size: .95rem; }

/* --------------------------------------------------------------------------
   „Heute"-Block: Aktionstag, Namenstage, Witz
   -------------------------------------------------------------------------- */

.today { margin: 24px 0 6px; display: grid; gap: 14px; }

.today-day {
  display: flex; gap: 22px; align-items: center; padding: 20px;
  border: 1px solid color-mix(in srgb, var(--amber) 35%, var(--line));
  border-radius: var(--radius-md);
  background:
    radial-gradient(circle at 0% 0%, color-mix(in srgb, var(--amber) 16%, transparent), transparent 62%),
    var(--surface-strong);
}
.today-img {
  flex: 0 0 148px; width: 148px; height: 148px; object-fit: cover;
  border-radius: var(--radius-sm); border: 1px solid var(--line); background: var(--surface-soft);
}
.today-body { min-width: 0; }
.today-kicker {
  display: block; font-size: .72rem; font-weight: 800; letter-spacing: .12em;
  text-transform: uppercase; color: var(--amber);
}
.today-day h4 {
  margin: 6px 0 0; font-size: clamp(1.25rem, 2.6vw, 1.6rem);
  letter-spacing: -0.03em; line-height: 1.2;
}
.today-day h4 a { text-decoration: none; border-bottom: 2px solid color-mix(in srgb, var(--amber) 45%, transparent); }
.today-day h4 a:hover { border-bottom-color: var(--amber); }
.today-text { margin: 9px 0 0; color: var(--muted); font-size: .95rem; line-height: 1.6; }
.today-note { margin: 7px 0 0; color: var(--faint); font-size: .84rem; }

.today-more {
  padding: 16px 20px; border-radius: var(--radius-md);
  border: 1px solid var(--line); background: var(--surface-strong);
}
.today-more .today-kicker { color: var(--blue); }
.today-more ul { display: flex; gap: 8px; flex-wrap: wrap; list-style: none; margin: 7px 0 0; padding: 0; }
.today-more li {
  padding: 5px 13px; border-radius: 999px; font-size: .95rem; font-weight: 650;
  color: var(--blue);
  background: color-mix(in srgb, var(--blue) 9%, var(--surface-strong));
  border: 1px solid color-mix(in srgb, var(--blue) 28%, transparent);
}

.today-names {
  padding: 16px 20px; border-radius: var(--radius-md);
  border: 1px solid var(--line); background: var(--surface-strong);
}
.today-names p { margin: 7px 0 0; display: flex; gap: 8px; flex-wrap: wrap; }
.today-names em {
  font-style: normal; font-weight: 650; font-size: .95rem;
  padding: 5px 13px; border-radius: 999px;
  color: var(--teal);
  background: color-mix(in srgb, var(--teal) 10%, var(--surface-strong));
  border: 1px solid color-mix(in srgb, var(--teal) 30%, transparent);
}

.today-joke {
  padding: 18px 20px; border-radius: var(--radius-md);
  border: 1px solid color-mix(in srgb, var(--purple) 28%, var(--line));
  background:
    radial-gradient(circle at 100% 0%, color-mix(in srgb, var(--purple) 12%, transparent), transparent 60%),
    var(--surface-strong);
}
.today-joke .today-kicker { color: var(--purple); }
.joke-q { margin: 8px 0 0; font-size: 1.02rem; font-weight: 650; line-height: 1.5; }
.joke-a { margin: 6px 0 0; font-size: 1.02rem; color: var(--muted); line-height: 1.5; }

@media (max-width: 720px) {
  .today-day { flex-direction: column; align-items: flex-start; gap: 16px; }
  .today-img { flex: 0 0 auto; width: 100%; max-width: 220px; height: auto; aspect-ratio: 1; }
}

.lead-card {
  margin: 24px 0 4px; padding: 16px; display: flex; gap: 20px; align-items: center;
  border: 1px solid var(--line); border-radius: var(--radius-md);
  background:
    radial-gradient(circle at 0% 0%, color-mix(in srgb, var(--amber) 12%, transparent), transparent 60%),
    var(--surface-soft);
}
.lead-card img {
  flex: 0 0 132px; width: 132px; height: 132px; object-fit: cover;
  border-radius: var(--radius-sm); border: 1px solid var(--line); background: var(--surface-strong);
}
.lead-card figcaption { min-width: 0; }
.lead-kicker {
  display: block; font-size: .7rem; font-weight: 800; letter-spacing: .11em;
  text-transform: uppercase; color: var(--amber); margin-bottom: 5px;
}
.lead-card strong { font-size: 1.12rem; letter-spacing: -0.02em; }
.lead-card strong a { text-decoration: none; border-bottom: 1px solid color-mix(in srgb, var(--amber) 45%, transparent); }
.lead-card figcaption > p { margin: 5px 0 0; color: var(--muted); font-size: .92rem; }
.lead-caption { font-size: .76rem; color: var(--faint); margin: 8px 0 0 !important; }

.source-note { margin-top: 26px; padding-top: 18px; border-top: 1px solid var(--line); font-size: .82rem; color: var(--faint); }

/* --------------------------------------------------------------------------
   FAQ
   -------------------------------------------------------------------------- */

.faq { margin-top: 26px; display: grid; gap: 12px; }
.faq details {
  border: 1px solid var(--line); border-radius: var(--radius-md);
  background: var(--surface); overflow: hidden;
}
.faq summary {
  cursor: pointer; list-style: none; padding: 18px 22px; font-weight: 700; font-size: 1rem;
  display: flex; align-items: center; justify-content: space-between; gap: 14px;
}
.faq summary::-webkit-details-marker { display: none; }
.faq summary::after {
  content: '+'; font-size: 1.4rem; font-weight: 400; color: var(--muted); line-height: 1; transition: transform .2s;
}
.faq details[open] summary::after { transform: rotate(45deg); }
.faq details > p { margin: 0; padding: 0 22px 20px; color: var(--muted); font-size: .95rem; }

/* --------------------------------------------------------------------------
   Zustandsseiten (Bestätigung / Abmeldung)
   -------------------------------------------------------------------------- */

.state { max-width: 660px; margin: 60px auto 0; text-align: center; padding: 46px 34px; }
.state-icon {
  width: 76px; height: 76px; border-radius: 24px; margin: 0 auto 22px;
  display: grid; place-items: center; color: #fff;
}
.state-icon.ok { background: linear-gradient(135deg, var(--green), var(--teal)); box-shadow: 0 16px 40px rgba(46, 191, 120, .30); }
.state-icon.info { background: linear-gradient(135deg, var(--blue), var(--purple)); box-shadow: 0 16px 40px rgba(0, 122, 255, .28); }
.state-icon.warn { background: linear-gradient(135deg, #E8A33D, var(--amber)); box-shadow: 0 16px 40px rgba(199, 124, 33, .28); }
.state-icon.err { background: linear-gradient(135deg, #f0666a, var(--red)); box-shadow: 0 16px 40px rgba(229, 72, 77, .26); }
.state h1 { margin: 0; font-size: clamp(1.7rem, 4vw, 2.2rem); letter-spacing: -0.03em; }
.state p { color: var(--muted); margin: 14px 0 0; }
.state .actions { margin-top: 28px; display: flex; gap: 12px; justify-content: center; flex-wrap: wrap; }

/* --------------------------------------------------------------------------
   Fußbereich
   -------------------------------------------------------------------------- */

footer.site {
  margin-top: 70px; padding-top: 26px; border-top: 1px solid var(--line);
  color: var(--muted); font-size: .84rem;
  display: flex; justify-content: space-between; gap: 18px; flex-wrap: wrap;
}
footer.site a { color: var(--muted); text-decoration: none; }
footer.site a:hover { color: var(--text); text-decoration: underline; }
footer.site nav ul { gap: 16px; }

/* --------------------------------------------------------------------------
   Admin
   -------------------------------------------------------------------------- */

.admin-head { display: flex; align-items: flex-end; justify-content: space-between; gap: 20px; flex-wrap: wrap; padding: 44px 0 0; }
.admin-head h1 { margin: 6px 0 0; font-size: clamp(1.7rem, 3.5vw, 2.3rem); letter-spacing: -0.03em; }

.stats { margin-top: 26px; display: grid; grid-template-columns: repeat(4, 1fr); gap: 16px; }
.stat {
  padding: 22px; border-radius: var(--radius-md); border: 1px solid var(--line);
  background: var(--surface); box-shadow: var(--shadow-sm);
}
.stat b { display: block; font-size: 2rem; letter-spacing: -0.035em; line-height: 1.1; }
.stat span { font-size: .8rem; color: var(--muted); text-transform: uppercase; letter-spacing: .07em; font-weight: 700; }
.stat.accent-blue b { color: var(--blue); }
.stat.accent-green b { color: var(--green); }
.stat.accent-amber b { color: var(--amber); }
.stat.accent-purple b { color: var(--purple); }

.toolbar { margin-top: 26px; display: flex; gap: 12px; flex-wrap: wrap; align-items: center; justify-content: space-between; }
.toolbar form { display: flex; gap: 10px; flex-wrap: wrap; align-items: center; }
.toolbar .input { min-height: 44px; padding: 10px 14px; width: auto; min-width: 240px; }
.toolbar select.input { min-width: 160px; }

.table-card { margin-top: 18px; overflow: hidden; }
.table-scroll { overflow-x: auto; }
table.data { width: 100%; border-collapse: collapse; font-size: .92rem; min-width: 780px; }
table.data th {
  text-align: left; font-size: .72rem; text-transform: uppercase; letter-spacing: .09em;
  color: var(--muted); font-weight: 800; padding: 16px 18px; border-bottom: 1px solid var(--line);
  white-space: nowrap; background: color-mix(in srgb, var(--surface-soft) 60%, transparent);
}
table.data td { padding: 14px 18px; border-bottom: 1px solid var(--line); vertical-align: middle; }
table.data tbody tr:last-child td { border-bottom: 0; }
table.data tbody tr:hover { background: color-mix(in srgb, var(--blue) 4%, transparent); }
table.data .mail { font-weight: 650; overflow-wrap: anywhere; min-width: 230px; }
table.data .num { font-variant-numeric: tabular-nums; color: var(--muted); white-space: nowrap; }
table.data .actions { text-align: right; white-space: nowrap; }

.badge {
  display: inline-flex; align-items: center; gap: 6px; padding: 4px 11px; border-radius: 999px;
  font-size: .76rem; font-weight: 750; border: 1px solid var(--line); white-space: nowrap;
}
.badge::before { content: ''; width: 6px; height: 6px; border-radius: 50%; background: currentColor; }
.badge-active { color: var(--green); background: color-mix(in srgb, var(--green) 10%, transparent); border-color: color-mix(in srgb, var(--green) 30%, transparent); }
.badge-pending { color: var(--amber); background: color-mix(in srgb, var(--amber) 10%, transparent); border-color: color-mix(in srgb, var(--amber) 30%, transparent); }

.empty { padding: 56px 24px; text-align: center; color: var(--muted); }
.empty strong { display: block; font-size: 1.1rem; color: var(--text); margin-bottom: 6px; }

.login { max-width: 460px; margin: 8vh auto 0; padding: 38px; }
.login h1 { margin: 0 0 6px; font-size: 1.6rem; letter-spacing: -0.03em; }
.login p.sub { margin: 0 0 26px; color: var(--muted); font-size: .95rem; }

.log-list { list-style: none; margin: 0; padding: 0; font-size: .88rem; }
.log-list li { display: flex; gap: 14px; padding: 11px 0; border-bottom: 1px solid var(--line); }
.log-list li:last-child { border-bottom: 0; }
.log-list time { flex: 0 0 148px; color: var(--faint); font-variant-numeric: tabular-nums; font-size: .82rem; }
.log-list .ev { flex: 0 0 130px; font-weight: 700; font-size: .8rem; color: var(--muted); }
.log-list .msg { flex: 1; color: var(--muted); min-width: 0; word-break: break-word; }

code.snippet {
  display: block; padding: 14px 16px; border-radius: var(--radius-sm);
  background: var(--surface-soft); border: 1px solid var(--line);
  font-family: ui-monospace, SFMono-Regular, Menlo, Consolas, monospace;
  font-size: .84rem; word-break: break-all; margin-top: 10px;
}

/* --------------------------------------------------------------------------
   Responsive
   -------------------------------------------------------------------------- */

@media (max-width: 980px) {
  .hero { grid-template-columns: 1fr; gap: 36px; padding-top: 40px; }
  .signup-grid { grid-template-columns: 1fr; }
  .signup-side { border-left: 0; border-top: 1px solid var(--line); }
  .steps { grid-template-columns: 1fr; }
  .stats { grid-template-columns: repeat(2, 1fr); }
}

@media (max-width: 720px) {
  .topbar-inner { flex-direction: column; align-items: flex-start; gap: 10px; }
  .holiday-grid { grid-template-columns: 1fr; }
  .timeline::before { display: none; }
  .timeline li { flex-wrap: wrap; gap: 10px; }
  .year { flex: 0 0 auto; }
  .entry { flex: 1 1 100%; }
  .log-list li { flex-wrap: wrap; gap: 4px 12px; }
  .log-list time, .log-list .ev { flex: 0 0 auto; }
  .lead-card { flex-direction: column; align-items: flex-start; text-align: left; }
  .lead-card img { flex: 0 0 auto; width: 100%; max-width: 260px; height: auto; aspect-ratio: 1; }
}

@media (max-width: 640px) {
  .wrap { padding-inline: 16px; }
  .topbar-inner { padding-inline: 16px; }
  .card, .sheet, .step { border-radius: 22px; }
  .card-pad, .signup-form, .signup-side, .preview-card { padding: 22px; }
  .state { padding: 34px 22px; }
  .stats { grid-template-columns: 1fr; }
  .sheet-facts { grid-template-columns: 1fr; gap: 12px; text-align: left; }
}

/* Comic des Tages – islieb.de, CC BY-NC-ND 4.0.
   Bewusst ohne object-fit und ohne festes Seitenverhältnis: Das Bild darf
   nur skaliert, niemals beschnitten werden. */
.today-comic {
  margin: 0; padding: 18px 20px; border-radius: var(--radius-md);
  border: 1px solid color-mix(in srgb, var(--teal) 28%, var(--line));
  background:
    radial-gradient(circle at 0% 100%, color-mix(in srgb, var(--teal) 10%, transparent), transparent 60%),
    var(--surface-strong);
}
.today-comic .today-kicker { color: var(--teal); }
/* Nur der Bildlink ist ein Block – die Links im Nachweis bleiben im Fließtext */
.today-comic > a { display: block; margin-top: 10px; width: fit-content; }
.today-comic figcaption a { display: inline; }
.today-comic img {
  width: 100%; height: auto; max-width: 420px;
  border-radius: var(--radius-sm); border: 1px solid var(--line); background: #fff;
}
.today-comic figcaption {
  margin-top: 10px; font-size: .8rem; line-height: 1.6; color: var(--faint);
}
.today-comic figcaption strong { color: var(--text); }
.today-comic figcaption a { color: var(--muted); }

/* Zitat des Tages – gemeinfreie Autoren, Herkunft steht immer darunter */
.today-quote {
  margin: 0; padding: 18px 22px; border-radius: var(--radius-md);
  border: 1px solid color-mix(in srgb, var(--purple) 28%, var(--line));
  border-left: 4px solid var(--purple);
  background:
    radial-gradient(circle at 100% 0%, color-mix(in srgb, var(--purple) 11%, transparent), transparent 60%),
    var(--surface-strong);
}
.today-quote .today-kicker { color: var(--purple); }
.today-quote blockquote {
  margin: 9px 0 0; font-size: 1.08rem; line-height: 1.6; color: var(--text);
}
.today-quote blockquote::before { content: '„'; }
.today-quote blockquote::after  { content: '“'; }
.today-quote figcaption { margin-top: 10px; font-size: .88rem; color: var(--muted); }
