/* FiNaSchla – Website. Farben wie in der App (mobile/src/ui/theme.ts): warm-neutraler Rahmen mit
   Korall, Nahrung grün, Schlaf nachtblau, Fitness hellblau. Keine Abhängigkeiten, keine Schrift
   von außen. */

@font-face {
  font-family: "Figtree";
  font-style: normal;
  font-weight: 300 900;
  font-display: swap;
  src: url("/fonts/figtree-latin-wght.woff2") format("woff2");
}

:root {
  color-scheme: light;
  --ground: #f1ece6;
  --surface: #ffffff;
  --tile: #f6f2ed;
  --ink: #221c18;
  --muted: #6b6159;
  --line: #e4dbd1;
  --accent: #b8471b;
  --accent-ink: #a3401a;
  --focus: #b8471b;
  /* warmes Licht oben rechts, wie in der Übersicht der App */
  --glow: rgba(255, 196, 160, 0.95);
  --glow-soft: rgba(253, 224, 205, 0.66);

  --food-ground: #eceeeb;
  --food-surface: #ffffff;
  --food-accent: #177a43;
  --food-soft: #dcf0e3;
  --food-ink: #19211c;

  --fit-surface: #ffffff;
  --fit-ink: #14212c;
  --fit-muted: #56687a;
  --fit-accent: #1f78bf;
  --fit-soft: #dcecfa;
  --fit-line: #b9d6ee;

  --night-ground: #0e1630;
  --night-surface: #172242;
  --night-tile: #1f2c52;
  --night-ink: #e9edfa;
  --night-muted: #a3add0;
  --night-accent: #93a8ff;
  --night-band: #34488a;
  --night-gold: #f3c56b;

  --mark-bg: #fff1bf;
  --mark-ink: #5e4500;

  --radius: 26px;
  --shadow: 0 1px 2px rgba(34, 28, 24, 0.06), 0 12px 32px -18px rgba(34, 28, 24, 0.28);
  --font: "Figtree", system-ui, -apple-system, "Segoe UI", Roboto, sans-serif;
}

@media (prefers-color-scheme: dark) {
  :root {
    color-scheme: dark;
    --ground: #14110f;
    --surface: #1f1b18;
    --tile: #292420;
    --ink: #f1ebe5;
    --muted: #b0a59b;
    --line: #3a332e;
    --accent: #ff9466;
    --accent-ink: #ffc2a6;
    --focus: #ff9466;
    --glow: rgba(94, 42, 28, 0.8);
    --glow-soft: rgba(46, 26, 20, 0.56);

    --food-ground: #101412;
    --food-surface: #1a1f1c;
    --food-accent: #4cc27f;
    --food-soft: #1b3a28;
    --food-ink: #e9efeb;

    --fit-surface: #16212b;
    --fit-ink: #e8f1f8;
    --fit-muted: #9db0c2;
    --fit-accent: #7cc4ff;
    --fit-soft: #1a3550;
    --fit-line: #2c4a66;

    --night-ground: #080e22;
    --night-surface: #111a36;
    --night-tile: #19244a;

    --mark-bg: #4a3b10;
    --mark-ink: #ffe9a8;
    --shadow: 0 1px 2px rgba(0, 0, 0, 0.4), 0 12px 32px -18px rgba(0, 0, 0, 0.8);
  }
}

*, *::before, *::after { box-sizing: border-box; }

html { -webkit-text-size-adjust: 100%; text-size-adjust: 100%; }

body {
  margin: 0;
  background: var(--ground);
  color: var(--ink);
  font-family: var(--font);
  font-size: 1.0625rem;
  line-height: 1.6;
  -webkit-font-smoothing: antialiased;
}

a { color: inherit; text-decoration-thickness: 1.5px; text-underline-offset: 3px; }
a:hover { text-decoration-thickness: 2.5px; }
:focus-visible { outline: 3px solid var(--focus); outline-offset: 3px; border-radius: 6px; }

h1, h2, h3 { line-height: 1.15; letter-spacing: -0.02em; margin: 0; }
p { margin: 0; }

.visually-hidden {
  position: absolute; width: 1px; height: 1px; padding: 0; margin: -1px; overflow: hidden;
  clip: rect(0 0 0 0); white-space: nowrap; border: 0;
}

.skip {
  position: absolute; left: 16px; top: -60px; z-index: 10; padding: 10px 16px;
  background: var(--ink); color: var(--ground); border-radius: 12px; font-weight: 600;
}
.skip:focus { top: 12px; }

/* Startseite: warmes Licht oben rechts, läuft in die Grundfarbe aus */
body.home {
  background-image: radial-gradient(circle 560px at 85% 0, var(--glow), var(--glow-soft) 50%, transparent 100%);
  background-repeat: no-repeat;
}

/* ------------------------------------------------------------------ Rahmen */

.site-header, main, .site-footer {
  width: 100%;
  max-width: 1080px;
  margin: 0 auto;
  padding-left: max(20px, env(safe-area-inset-left));
  padding-right: max(20px, env(safe-area-inset-right));
}

.site-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  padding-top: 22px;
  padding-bottom: 8px;
}

.brand { display: inline-flex; align-items: center; gap: 10px; text-decoration: none; }
.brand__mark { width: 36px; height: 36px; display: block; }
.brand__name { font-size: 1.3rem; font-weight: 750; letter-spacing: -0.02em; }

.chip {
  font-size: 0.875rem; font-weight: 600; color: var(--muted);
  border: 1.5px solid var(--line); border-radius: 999px; padding: 4px 12px; white-space: nowrap;
}

.site-footer {
  padding-top: 40px;
  padding-bottom: max(40px, env(safe-area-inset-bottom));
  color: var(--muted);
  font-size: 0.9rem;
  display: grid;
  gap: 10px;
}
.site-footer nav { display: flex; flex-wrap: wrap; gap: 6px 22px; font-weight: 600; color: var(--ink); }
.site-footer nav a { text-decoration: none; padding: 6px 0; }
.site-footer nav a:hover { text-decoration: underline; }

/* ------------------------------------------------------------------ Startseite */

.hero {
  display: grid;
  gap: 40px;
  align-items: center;
  padding: 36px 0 56px;
}

.eyebrow { font-weight: 700; font-size: 0.95rem; color: var(--accent-ink); letter-spacing: 0.02em; margin-bottom: 14px; }

.hero h1 { font-size: clamp(2.3rem, 7vw, 3.7rem); font-weight: 760; max-width: 13em; }

.lead { margin-top: 20px; font-size: 1.2rem; color: var(--muted); max-width: 32em; }

.hero__actions { margin-top: 30px; display: flex; flex-wrap: wrap; align-items: center; gap: 12px 18px; }

.store-badge {
  display: inline-flex; align-items: center; gap: 10px;
  background: var(--ink); color: var(--ground);
  border-radius: 14px; padding: 9px 18px 9px 14px; line-height: 1.1;
}
.store-badge svg { width: 24px; height: 24px; fill: none; stroke: currentColor; stroke-width: 1.8; stroke-linecap: round; }
.store-badge span { display: grid; font-weight: 700; font-size: 1.1rem; }
.store-badge small { font-weight: 500; font-size: 0.72rem; opacity: 0.8; }
.hero__note { color: var(--muted); font-size: 0.95rem; }

/* Telefon (nur Bild, aria-hidden) */
.hero__visual { display: flex; justify-content: center; }

.phone {
  width: min(320px, 88vw);
  border-radius: 48px;
  padding: 12px;
  background: #121614;
  box-shadow: 0 30px 60px -30px rgba(14, 22, 48, 0.55), 0 0 0 1.5px rgba(255, 255, 255, 0.08) inset;
}

.phone__screen {
  border-radius: 37px;
  background: radial-gradient(circle 190px at 88% 0, rgba(255, 196, 160, 0.95), rgba(253, 224, 205, 0.66) 50%, transparent 100%),
    #f1ece6;
  color: #221c18;
  padding: 18px 16px 22px;
  display: grid;
  gap: 12px;
  font-size: 0.85rem;
}

.mock-time { font-weight: 700; font-size: 0.8rem; text-align: center; margin-bottom: 4px; }
.mock-date { color: #a3401a; font-weight: 650; font-size: 0.78rem; }
.mock-hello { font-weight: 750; font-size: 1.45rem; letter-spacing: -0.02em; line-height: 1.1; margin-top: -10px; }

.mock-card { border-radius: 22px; padding: 14px 16px 16px; display: grid; gap: 4px; }
.mock-label { display: flex; align-items: center; gap: 6px; font-weight: 650; font-size: 0.78rem; }
.mock-label svg { width: 15px; height: 15px; fill: none; stroke: currentColor; stroke-width: 2; stroke-linecap: round; stroke-linejoin: round; }
.mock-big { font-weight: 760; font-size: 1.55rem; letter-spacing: -0.02em; line-height: 1.15; }
.mock-big small { font-size: 0.9rem; font-weight: 600; letter-spacing: 0; }
.mock-note { font-size: 0.78rem; font-weight: 600; }

.mock-card--sleep { background: #0e1630; color: #e9edfa; }
.mock-card--sleep .mock-label { color: #a3add0; }
.mock-card--sleep .mock-note { color: #93a8ff; }

.mock-bars {
  margin-top: 10px; height: 54px; display: grid; grid-template-columns: repeat(7, 1fr); gap: 7px; align-items: end;
  background: linear-gradient(to top, transparent 42%, rgba(52, 72, 138, 0.75) 42%, rgba(52, 72, 138, 0.75) 70%, transparent 70%);
  border-radius: 6px;
}
.mock-bars span { display: block; border-radius: 5px; background: #93a8ff; }
.mock-bars span:nth-child(1) { height: 58%; }
.mock-bars span:nth-child(2) { height: 46%; }
.mock-bars span:nth-child(3) { height: 37%; background: #f3c56b; }
.mock-bars span:nth-child(4) { height: 62%; }
.mock-bars span:nth-child(5) { height: 55%; }
.mock-bars span:nth-child(6) { height: 74%; background: #f3c56b; }
.mock-bars span:nth-child(7) { height: 60%; }

.mock-card--food { background: #ffffff; color: #19211c; box-shadow: 0 1px 2px rgba(34, 28, 24, 0.06); }
.mock-card--food .mock-label { color: #177a43; }
.mock-progress { height: 8px; border-radius: 4px; background: #e8ebe7; overflow: hidden; margin-top: 6px; }
.mock-progress span { display: block; height: 100%; width: 58%; border-radius: 4px; background: #5dbb85; }
.mock-macros { display: grid; grid-template-columns: repeat(3, 1fr); gap: 6px; margin-top: 8px; }
.mock-macros span { background: #f4f6f3; border-radius: 10px; padding: 6px 7px; font-size: 0.68rem; color: #5c675f; display: grid; }
.mock-macros b { color: #19211c; font-size: 0.82rem; }

.mock-card--fitness { background: #ffffff; color: #14212c; box-shadow: 0 1px 2px rgba(34, 28, 24, 0.06); }
.mock-card--fitness .mock-label { color: #1f78bf; }
.mock-card--fitness .mock-note { color: #b45a14; }
.mock-dots { display: flex; gap: 6px; margin-top: 8px; }
.mock-dots span { width: 14px; height: 14px; border-radius: 50%; border: 2px solid #b9d6ee; }
.mock-dots span.on { background: #1f78bf; border-color: #1f78bf; }

/* Bereiche */
.modules { display: grid; gap: 16px; }

.module { border-radius: var(--radius); padding: 26px 24px 28px; box-shadow: var(--shadow); }
.module__kicker { font-weight: 700; font-size: 0.95rem; margin-bottom: 8px; }
.module h3 { font-size: 1.55rem; font-weight: 740; margin-bottom: 12px; }
.module p { color: inherit; }
.module ul { margin: 16px 0 0; padding: 0; list-style: none; display: grid; gap: 8px; }
.module li { padding-left: 26px; position: relative; font-weight: 550; }
.module li::before {
  content: ""; position: absolute; left: 2px; top: 0.5em; width: 12px; height: 7px;
  border-left: 2.5px solid currentColor; border-bottom: 2.5px solid currentColor;
  transform: rotate(-45deg); opacity: 0.9;
}

.module--nahrung { background: var(--food-surface); color: var(--food-ink); }
.module--nahrung .module__kicker, .module--nahrung li::before { color: var(--food-accent); }

.module--schlaf { background: var(--night-ground); color: var(--night-ink); }
.module--schlaf .module__kicker, .module--schlaf li::before { color: var(--night-accent); }
.module--schlaf p:not(.module__kicker) { color: var(--night-muted); }
.module--schlaf li { color: var(--night-ink); }

.module--fitness { background: var(--fit-surface); color: var(--fit-ink); }
.module--fitness .module__kicker, .module--fitness li::before { color: var(--fit-accent); }
.module--fitness p:not(.module__kicker) { color: var(--fit-muted); }

/* Daten */
.privacy { margin-top: 64px; padding: 34px 26px 30px; border-radius: var(--radius); background: var(--surface); box-shadow: var(--shadow); }
.privacy h2 { font-size: clamp(1.7rem, 4vw, 2.2rem); font-weight: 750; }
.facts { display: grid; gap: 22px; margin-top: 24px; }
.facts h3 { font-size: 1.1rem; font-weight: 700; margin-bottom: 4px; letter-spacing: -0.01em; }
.facts p { color: var(--muted); }
.privacy__link { margin-top: 24px; font-weight: 650; }

.medical { margin: 32px 0 0; color: var(--muted); font-size: 0.95rem; }

@media (min-width: 860px) {
  .hero { grid-template-columns: 1.15fr 0.85fr; padding: 64px 0 88px; }
  .modules { grid-template-columns: repeat(3, 1fr); }
  .facts { grid-template-columns: repeat(3, 1fr); gap: 32px; }
  .privacy { padding: 44px 40px 40px; }
}

/* ------------------------------------------------------------------ Rechtstexte */

.legal {
  max-width: 720px;
  margin: 12px auto 0;
  background: var(--surface);
  border-radius: var(--radius);
  padding: 28px 22px 36px;
  box-shadow: var(--shadow);
  overflow-wrap: break-word;
}

.legal__back { font-weight: 600; font-size: 0.95rem; margin-bottom: 18px; }
.legal__back a { text-decoration: none; color: var(--muted); }
.legal__back a:hover { color: var(--ink); text-decoration: underline; }
.legal h1 { font-size: clamp(1.9rem, 6vw, 2.5rem); font-weight: 760; }
.legal__updated { color: var(--muted); margin-top: 6px; font-size: 0.95rem; }
.legal h2 { font-size: 1.3rem; font-weight: 720; margin-top: 2em; }
.legal h3 { font-size: 1.08rem; font-weight: 700; margin-top: 1.6em; letter-spacing: -0.01em; }
.legal p { margin-top: 0.8em; }
.legal ul { margin: 0.8em 0 0; padding-left: 1.3em; display: grid; gap: 0.35em; }
.legal li::marker { color: var(--muted); }
.legal strong { font-weight: 700; }

mark.placeholder {
  background: var(--mark-bg);
  color: var(--mark-ink);
  border-radius: 5px;
  padding: 0 4px;
  font-weight: 600;
}

@media (min-width: 860px) {
  .legal { padding: 44px 56px 52px; margin-top: 24px; }
}

/* ------------------------------------------------------------------ 404 */

.notfound__box { padding: 80px 0 40px; display: grid; gap: 14px; }
.notfound__box h1 { font-size: clamp(2rem, 6vw, 3rem); font-weight: 760; }
.notfound__box p { color: var(--muted); font-size: 1.15rem; }
