/* ============================================================
   Mit Fertilitetsforløb — App-tokens
   Bygger på LøvenIT-tokens, men med Rigshospital-blå/hvid
   som primær flade og tre visuelle varianter (warm / clinical / soft).
   ============================================================ */

@import url("./lovenit-tokens.css");
@import url("https://fonts.googleapis.com/css2?family=Inter:wght@400;500;600;700&family=Fraunces:opsz,wght@9..144,500;9..144,600&display=swap");

:root {
  /* ── Rigshospital-inspirerede tokens ── */
  --rh-blue-900: #0B2240;     /* dyb marine — header, ink */
  --rh-blue-800: #133B6B;     /* primary mørk */
  --rh-blue-700: #1B5AA0;     /* primary */
  --rh-blue-600: #2A77C9;     /* primary aktiv */
  --rh-blue-500: #4A92DB;     /* link / accent */
  --rh-blue-400: #7DB2E5;
  --rh-blue-300: #B6D2EC;
  --rh-blue-200: #D6E5F2;
  --rh-blue-100: #E8F0F7;
  --rh-blue-50:  #F4F8FB;

  --rh-cream:    #F8F5EF;     /* varm baggrund hvor blå er hovedflade */
  --rh-paper:    #FFFFFF;
  --rh-bone:     #F1ECE3;
  --rh-ink:      #0E1A2B;
  --rh-ink-2:    #2A3548;
  --rh-mute:     #5C6A80;
  --rh-mute-2:   #8794A8;
  --rh-line:     rgba(15, 28, 50, 0.08);
  --rh-line-2:   rgba(15, 28, 50, 0.14);

  /* støttende */
  --rh-coral:    #E0644E;     /* varm accent (ikke orange skrigende) */
  --rh-rose:     #E5A39A;
  --rh-sage:     #6F9A7A;     /* "taget" / okay */
  --rh-sage-bg:  #E5EFE3;
  --rh-amber:    #C7902A;
  --rh-amber-bg: #F8EFD7;

  /* App-flader (overskrives per tema nedenfor) */
  --bg-app:        var(--rh-cream);
  --bg-card:       var(--rh-paper);
  --bg-elev:       #FBF9F4;
  --bg-inverse:    var(--rh-blue-900);
  --bg-tint:       var(--rh-blue-50);
  --bg-tint-2:     var(--rh-blue-100);

  --fg-1:          var(--rh-ink);
  --fg-2:          var(--rh-ink-2);
  --fg-3:          var(--rh-mute);
  --fg-4:          var(--rh-mute-2);
  --fg-on-blue:    #FFFFFF;
  --fg-on-cream:   var(--rh-ink);

  --line:          var(--rh-line);
  --line-2:        var(--rh-line-2);

  --accent:        var(--rh-blue-700);
  --accent-strong: var(--rh-blue-800);
  --accent-soft:   var(--rh-blue-100);
  --accent-ink:    var(--rh-blue-900);

  --warm:          var(--rh-coral);

  /* Typografi */
  --font-display: "Fraunces", "Bricolage Grotesque", Georgia, serif;
  --font-sans:    "Inter", -apple-system, system-ui, sans-serif;

  /* Radii — appen er roligere end LøvenIT */
  --r-1: 6px;
  --r-2: 10px;
  --r-3: 14px;
  --r-4: 20px;
  --r-pill: 999px;

  /* Skygger — kølige denne gang */
  --sh-xs: 0 1px 2px rgba(15, 28, 50, 0.05);
  --sh-sm: 0 2px 6px rgba(15, 28, 50, 0.06), 0 1px 2px rgba(15, 28, 50, 0.04);
  --sh-md: 0 6px 18px rgba(15, 28, 50, 0.08), 0 2px 6px rgba(15, 28, 50, 0.05);
  --sh-lg: 0 16px 40px rgba(15, 28, 50, 0.12), 0 4px 12px rgba(15, 28, 50, 0.06);

  /* Motion */
  --ease: cubic-bezier(0.22, 0.61, 0.36, 1);
  --dur:  220ms;
}

/* ── TEMA: warm — varm cream + sundhedsblå accent (default) ── */
.theme-warm {
  --bg-app:    #F6F1E7;
  --bg-card:   #FFFFFF;
  --bg-elev:   #FBF7EE;
  --bg-tint:   #E8F0F7;
  --bg-tint-2: #DDE8F2;
  --accent:        #1B5AA0;
  --accent-strong: #133B6B;
  --accent-soft:   #E8F0F7;
  --accent-ink:    #0B2240;
  --warm:          #E0644E;
  --font-display:  "Fraunces", Georgia, serif;
}

/* ── TEMA: clinical — Rigshospital-stram, hvid + dyb marine ── */
.theme-clinical {
  --bg-app:    #F4F6F9;
  --bg-card:   #FFFFFF;
  --bg-elev:   #FFFFFF;
  --bg-tint:   #EAF1F8;
  --bg-tint-2: #DCE7F2;
  --accent:        #133B6B;
  --accent-strong: #0B2240;
  --accent-soft:   #EAF1F8;
  --accent-ink:    #0B2240;
  --warm:          #C8533F;
  --font-display:  "Inter", system-ui, sans-serif;
  --font-sans:     "Inter", system-ui, sans-serif;
}
.theme-clinical .display { letter-spacing: -0.025em; font-weight: 600; }

/* ── TEMA: soft — beroligende salviegrøn + støvet rosa ── */
.theme-soft {
  --bg-app:    #EEF2EC;
  --bg-card:   #FBFAF6;
  --bg-elev:   #F5F2EB;
  --bg-tint:   #E3EBDF;
  --bg-tint-2: #D4DECF;
  --accent:        #4F7763;
  --accent-strong: #324F41;
  --accent-soft:   #E3EBDF;
  --accent-ink:    #1F3329;
  --warm:          #D08A7C;
  --font-display:  "Fraunces", Georgia, serif;
}

/* ── Generic app body ── */
.app-body {
  font-family: var(--font-sans);
  color: var(--fg-1);
  background: var(--bg-app);
  font-size: 15px;
  line-height: 1.45;
  -webkit-font-smoothing: antialiased;
  text-rendering: optimizeLegibility;
}

/* ── Typografiske helpers brugt i app ── */
.t-display {
  font-family: var(--font-display);
  font-weight: 600;
  letter-spacing: -0.02em;
  line-height: 1.05;
  color: var(--fg-1);
}
.t-h1 { font-family: var(--font-display); font-weight: 600; font-size: 28px; line-height: 1.1; letter-spacing: -0.02em; }
.t-h2 { font-family: var(--font-display); font-weight: 600; font-size: 22px; line-height: 1.15; letter-spacing: -0.015em; }
.t-h3 { font-weight: 600; font-size: 17px; line-height: 1.25; letter-spacing: -0.005em; }
.t-eyebrow {
  font-size: 11px; font-weight: 600; letter-spacing: 0.08em;
  text-transform: uppercase; color: var(--accent);
}
.t-body { font-size: 15px; line-height: 1.5; color: var(--fg-1); }
.t-meta { font-size: 13px; color: var(--fg-3); }
.t-mono-num { font-variant-numeric: tabular-nums; }

/* ── Knapper ── */
.btn {
  display: inline-flex; align-items: center; justify-content: center; gap: 8px;
  font: inherit; font-weight: 600; font-size: 14px;
  padding: 11px 16px; border-radius: var(--r-2);
  border: 1px solid transparent; cursor: pointer;
  transition: background var(--dur) var(--ease), color var(--dur) var(--ease), transform var(--dur) var(--ease);
  white-space: nowrap;
}
.btn-primary { background: var(--accent); color: #fff; }
.btn-primary:hover { background: var(--accent-strong); }
.btn-ghost { background: transparent; color: var(--fg-1); border-color: var(--line-2); }
.btn-ghost:hover { background: var(--bg-tint); border-color: var(--accent); color: var(--accent); }
.btn-soft { background: var(--accent-soft); color: var(--accent-strong); }
.btn-soft:hover { background: var(--bg-tint-2); }
.btn-block { width: 100%; }
.btn-lg { padding: 14px 18px; font-size: 15px; }
.btn-sm { padding: 8px 12px; font-size: 13px; border-radius: var(--r-1); }

/* ── Card ── */
.card {
  background: var(--bg-card);
  border-radius: var(--r-3);
  border: 1px solid var(--line);
  box-shadow: var(--sh-xs);
}
.card-pad { padding: 18px; }

/* ── Chip ── */
.chip {
  display: inline-flex; align-items: center; gap: 6px;
  padding: 5px 10px; border-radius: var(--r-pill);
  background: var(--bg-tint); color: var(--accent-strong);
  font-size: 12px; font-weight: 500;
  border: 1px solid transparent;
}
.chip.warm { background: rgba(224, 100, 78, 0.1); color: var(--warm); }
.chip.sage { background: var(--rh-sage-bg); color: var(--rh-sage); }
.chip.amber{ background: var(--rh-amber-bg); color: var(--rh-amber); }
.chip.line { background: transparent; border-color: var(--line-2); color: var(--fg-2); }

/* ── Divider ── */
.hr { height: 1px; background: var(--line); border: 0; }

/* ── Skjul scrollbar i screens ── */
.no-scrollbar::-webkit-scrollbar { display: none; }
.no-scrollbar { scrollbar-width: none; }

/* ── App-screen ── */
.app-screen {
  width: 100%; height: 100%;
  background: var(--bg-app);
  overflow-y: auto; overflow-x: hidden;
  position: relative;
}

/* ── Bottom-nav ── */
.tab-bar {
  position: absolute; left: 0; right: 0; bottom: 0;
  padding: 8px 12px calc(8px + env(safe-area-inset-bottom));
  background: rgba(255, 255, 255, 0.92);
  backdrop-filter: blur(20px) saturate(180%);
  -webkit-backdrop-filter: blur(20px) saturate(180%);
  border-top: 1px solid var(--line);
  display: flex; justify-content: space-around; align-items: center;
  z-index: 30;
}
.theme-clinical .tab-bar { background: rgba(255,255,255,0.96); }
.theme-soft .tab-bar { background: rgba(251,250,246,0.92); }

.tab {
  flex: 1;
  display: flex; flex-direction: column; align-items: center; gap: 3px;
  padding: 6px 4px; border-radius: var(--r-2);
  border: 0; background: transparent;
  font: inherit; font-size: 10px; font-weight: 500;
  color: var(--fg-3);
  cursor: pointer;
}
.tab.active { color: var(--accent); }
.tab svg { width: 22px; height: 22px; }

/* progress */
.bar {
  position: relative; height: 6px;
  border-radius: var(--r-pill); background: var(--bg-tint);
  overflow: hidden;
}
.bar > i {
  display: block; height: 100%;
  border-radius: var(--r-pill);
  background: var(--accent);
  transition: width var(--dur) var(--ease);
}

/* dot */
.dot { width: 8px; height: 8px; border-radius: 999px; background: var(--accent); }

/* selectable card (onboarding) */
.choice {
  display: block; width: 100%; text-align: left;
  background: var(--bg-card);
  border: 1.5px solid var(--line);
  border-radius: var(--r-3);
  padding: 16px;
  cursor: pointer;
  transition: border-color var(--dur) var(--ease), background var(--dur) var(--ease), box-shadow var(--dur) var(--ease);
  font: inherit;
  color: inherit;
}
.choice:hover { border-color: var(--accent); }
.choice[data-selected="true"] {
  border-color: var(--accent);
  background: var(--accent-soft);
  box-shadow: var(--sh-sm);
}

/* badge */
.badge {
  display: inline-flex; align-items: center; gap: 4px;
  padding: 2px 8px; border-radius: var(--r-pill);
  font-size: 11px; font-weight: 600;
  background: var(--accent); color: #fff;
}
