/* ─────────────────────────────────────────────────
   Sibplanner — Design tokens (mirrored from Flutter app)
   Petrol & Cream — roligt, varmt, tillidsfuldt
───────────────────────────────────────────────── */
:root {
  /* Brand */
  --primary: #1F5959;
  --primary-light: #2B7272;
  --primary-deep: #143F3F;
  --primary-surface: #E2EFEC;
  --secondary: #3D6680;

  /* Accent */
  --accent: #B89048;
  --accent-light: #CFA860;
  --accent-surface: #F4E9D2;

  /* Neutrals */
  --text-primary: #1B2A2E;
  --text-secondary: #5C6B6F;
  --text-tertiary: #8A9499;
  --background: #F6F1E8;
  --surface: #FFFFFF;
  --surface-alt: #FBF6EC;
  --border: #E8E0D2;
  --divider: #EDE6D8;

  /* Semantic */
  --success: #5B7A3A;

  /* Radii */
  --r-xs: 6px;
  --r-sm: 10px;
  --r-md: 14px;
  --r-lg: 18px;
  --r-xl: 24px;
  --r-pill: 999px;

  /* Spacing (8pt grid) */
  --s-xs: 4px;
  --s-sm: 8px;
  --s-md: 12px;
  --s-lg: 16px;
  --s-xl: 24px;
  --s-xxl: 32px;
  --s-xxxl: 48px;

  /* Shadows (petrol-tinted) */
  --shadow-xs: 0 1px 2px rgba(20,30,30,0.04);
  --shadow-card: 0 2px 6px rgba(20,30,30,0.06), 0 1px 2px rgba(20,30,30,0.04);
  --shadow-hover: 0 6px 16px rgba(20,30,30,0.08), 0 2px 4px rgba(20,30,30,0.04);
  --shadow-header: 0 6px 14px rgba(31,89,89,0.18);
  --shadow-lg: 0 16px 40px rgba(20,30,30,0.12), 0 4px 8px rgba(20,30,30,0.06);

  /* Layout */
  --container: 1180px;
  --header-h: 72px;
}

/* ───────── Reset ───────── */
*, *::before, *::after { box-sizing: border-box; }
html, body { margin: 0; padding: 0; }
body {
  font-family: "Plus Jakarta Sans", -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif;
  background: var(--background);
  color: var(--text-primary);
  font-size: 16px;
  line-height: 1.5;
  -webkit-font-smoothing: antialiased;
  text-rendering: optimizeLegibility;
}
img, svg { display: block; max-width: 100%; }
a { color: inherit; text-decoration: none; }
button { font-family: inherit; cursor: pointer; }
ul { padding: 0; margin: 0; list-style: none; }

/* ───────── Layout helpers ───────── */
.container {
  width: 100%;
  max-width: var(--container);
  margin: 0 auto;
  padding: 0 var(--s-xl);
}

.section {
  padding: 96px 0;
}
.section--tight { padding: 64px 0; }

/* ───────── Type ───────── */
.eyebrow {
  display: inline-flex;
  align-items: center;
  gap: var(--s-sm);
  font-size: 12px;
  font-weight: 600;
  text-transform: uppercase;
  letter-spacing: 0.12em;
  color: var(--primary);
  background: var(--primary-surface);
  padding: 6px 12px;
  border-radius: var(--r-pill);
}
.eyebrow--accent {
  color: #8A6A2E;
  background: var(--accent-surface);
}

h1, h2, h3, h4 {
  font-family: "Fraunces", "Plus Jakarta Sans", serif;
  margin: 0;
  color: var(--text-primary);
  letter-spacing: -0.02em;
  text-wrap: balance;
  font-weight: 600;
}
h1 { font-size: clamp(40px, 5.2vw, 64px); line-height: 1.05; }
h2 { font-size: clamp(32px, 3.6vw, 44px); line-height: 1.1; }
h3 { font-size: 22px; line-height: 1.3; font-weight: 700; }

p { margin: 0; color: var(--text-secondary); text-wrap: pretty; }
.lead { font-size: 19px; line-height: 1.55; color: var(--text-secondary); max-width: 56ch; }
.muted { color: var(--text-tertiary); }

/* ───────── Header ───────── */
.header {
  position: sticky;
  top: 0;
  z-index: 50;
  background: rgba(246, 241, 232, 0.85);
  backdrop-filter: saturate(180%) blur(12px);
  -webkit-backdrop-filter: saturate(180%) blur(12px);
  border-bottom: 1px solid transparent;
  transition: border-color .2s, background .2s;
}
.header.scrolled { border-bottom-color: var(--border); }
.header__inner {
  height: var(--header-h);
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: var(--s-xl);
}
.brand {
  display: inline-flex;
  align-items: center;
  gap: 10px;
  font-weight: 700;
  color: var(--text-primary);
  font-size: 18px;
  letter-spacing: -0.01em;
}
.brand__mark {
  width: 32px;
  height: 32px;
  border-radius: 9px;
  background: linear-gradient(135deg, var(--primary-deep), var(--primary));
  display: grid;
  place-items: center;
  color: white;
  box-shadow: var(--shadow-header);
}

.nav {
  display: flex;
  align-items: center;
  gap: var(--s-xl);
}
.nav a {
  font-size: 14px;
  font-weight: 600;
  color: var(--text-secondary);
  padding: 8px 4px;
  position: relative;
  transition: color .15s;
}
.nav a:hover { color: var(--primary); }
.nav a.active { color: var(--text-primary); }
.nav a.active::after {
  content: "";
  position: absolute;
  left: 4px; right: 4px; bottom: 0;
  height: 2px;
  background: var(--accent);
  border-radius: 2px;
}

.header__right {
  display: flex;
  align-items: center;
  gap: var(--s-md);
}

/* Lang switch */
.lang {
  display: inline-flex;
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: var(--r-pill);
  padding: 3px;
  font-size: 12px;
  font-weight: 700;
}
.lang button {
  border: 0;
  background: transparent;
  padding: 6px 12px;
  border-radius: var(--r-pill);
  color: var(--text-secondary);
  letter-spacing: 0.04em;
}
.lang button.active {
  background: var(--primary);
  color: white;
}

/* Buttons */
.btn {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  padding: 12px 20px;
  font-size: 15px;
  font-weight: 600;
  border-radius: var(--r-md);
  border: 1.5px solid transparent;
  background: var(--primary);
  color: white;
  transition: transform .15s ease, box-shadow .2s, background .15s;
  box-shadow: var(--shadow-header);
}
.btn:hover { background: var(--primary-light); transform: translateY(-1px); }
.btn:active { transform: translateY(0); }
.btn--ghost {
  background: transparent;
  color: var(--text-primary);
  border-color: var(--border);
  box-shadow: none;
}
.btn--ghost:hover { background: var(--surface); border-color: var(--primary); color: var(--primary); }
.btn--lg { padding: 16px 26px; font-size: 16px; border-radius: var(--r-lg); }
.btn--sm { padding: 8px 14px; font-size: 13px; border-radius: var(--r-sm); }
.btn--accent {
  background: var(--accent);
  color: #1F1305;
  box-shadow: 0 6px 14px rgba(184,144,72,0.28);
}
.btn--accent:hover { background: var(--accent-light); }

/* Store badges */
.stores {
  display: flex;
  flex-wrap: wrap;
  gap: var(--s-md);
}
.store {
  display: inline-flex;
  align-items: center;
  gap: 10px;
  background: var(--text-primary);
  color: white;
  padding: 10px 16px;
  border-radius: var(--r-md);
  transition: transform .15s, box-shadow .2s;
  box-shadow: var(--shadow-card);
}
.store:hover { transform: translateY(-2px); box-shadow: var(--shadow-hover); }
.store__small { font-size: 10px; opacity: .75; line-height: 1; letter-spacing: 0.04em; text-transform: uppercase; }
.store__big { font-size: 15px; font-weight: 700; line-height: 1.2; margin-top: 2px; }

/* ───────── Pattern (subtle geometric) ───────── */
.pattern-bg {
  position: absolute;
  inset: 0;
  z-index: 0;
  pointer-events: none;
  opacity: var(--pattern-opacity, 1);
  background-image: url("pattern.svg");
  background-size: 280px 280px;
  -webkit-mask-image: radial-gradient(ellipse at 30% 20%, rgba(0,0,0,.6), rgba(0,0,0,0) 70%);
  mask-image: radial-gradient(ellipse at 30% 20%, rgba(0,0,0,.6), rgba(0,0,0,0) 70%);
}

/* ───────── Hero ───────── */
.hero {
  position: relative;
  overflow: hidden;
  padding: 72px 0 88px;
}
.hero__grid {
  position: relative;
  z-index: 1;
  display: grid;
  grid-template-columns: 1.05fr 1fr;
  gap: 56px;
  align-items: center;
}
.hero__copy h1 .alt {
  color: var(--primary);
  font-style: italic;
  font-weight: 500;
}
.hero__copy .lead { margin-top: var(--s-lg); }
.hero__cta {
  display: flex;
  gap: var(--s-md);
  margin-top: var(--s-xl);
  flex-wrap: wrap;
}
.hero__meta {
  display: flex;
  gap: 28px;
  margin-top: var(--s-xxl);
  padding-top: var(--s-lg);
  border-top: 1px dashed var(--border);
  flex-wrap: wrap;
}
.hero__meta-item {
  display: flex;
  flex-direction: column;
  gap: 2px;
}
.hero__meta-item strong {
  font-size: 22px;
  color: var(--primary);
  font-weight: 800;
  letter-spacing: -0.02em;
}
.hero__meta-item span { font-size: 13px; color: var(--text-tertiary); }

/* Hero visual */
.hero__visual {
  position: relative;
  display: grid;
  place-items: center;
  min-height: 560px;
}
.hero__visual-disc {
  position: absolute;
  inset: auto;
  width: 520px;
  height: 520px;
  border-radius: 50%;
  background: radial-gradient(circle at 30% 30%, var(--primary-surface), var(--background) 70%);
  z-index: 0;
}
.hero__visual-pattern {
  position: absolute;
  width: 460px;
  height: 460px;
  z-index: 0;
  opacity: .5;
}

/* Phone mockup */
.phone {
  position: relative;
  width: 304px;
  height: 624px;
  background: #0f1a1c;
  border-radius: 44px;
  padding: 12px;
  box-shadow: 0 30px 60px -20px rgba(20,30,30,.35), 0 8px 22px -8px rgba(20,30,30,.25);
  z-index: 2;
}
.phone__screen {
  width: 100%;
  height: 100%;
  background: var(--background);
  border-radius: 32px;
  overflow: hidden;
  position: relative;
}
.phone__notch {
  position: absolute;
  top: 10px;
  left: 50%;
  transform: translateX(-50%);
  width: 110px;
  height: 26px;
  background: #0f1a1c;
  border-radius: var(--r-pill);
  z-index: 5;
}
.phone--floating-tag {
  position: absolute;
  z-index: 3;
  background: var(--surface);
  border-radius: var(--r-md);
  box-shadow: var(--shadow-hover);
  padding: 10px 14px;
  display: flex;
  align-items: center;
  gap: 10px;
  font-size: 13px;
  font-weight: 600;
  color: var(--text-primary);
}
.phone--floating-tag .dot {
  width: 8px; height: 8px; border-radius: 50%; background: var(--success);
}
.tag-top-left { top: 70px; left: -20px; }
.tag-bottom-right { bottom: 60px; right: -28px; background: var(--primary); color: white; }
.tag-mid-right { top: 220px; right: -52px; }

/* App screen (preview) */
.app {
  display: flex;
  flex-direction: column;
  height: 100%;
  font-size: 11px;
}
.app__header {
  background: linear-gradient(135deg, var(--primary-deep), var(--primary));
  color: white;
  padding: 36px 16px 18px;
  position: relative;
  border-bottom-left-radius: var(--r-xl);
  border-bottom-right-radius: var(--r-xl);
}
.app__greet { font-size: 11px; opacity: .8; }
.app__title { font-size: 17px; font-weight: 700; margin-top: 2px; letter-spacing: -0.01em; }
.app__chip {
  display: inline-flex;
  align-items: center;
  gap: 5px;
  background: rgba(255,255,255,0.12);
  border: 1px solid rgba(255,255,255,0.18);
  padding: 4px 9px;
  border-radius: var(--r-pill);
  font-size: 10px;
  font-weight: 600;
  margin-top: 10px;
}
.app__body { padding: 14px; display: flex; flex-direction: column; gap: 10px; flex: 1; overflow: hidden; }
.app__section-label {
  font-size: 10px;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.08em;
  color: var(--text-tertiary);
  margin-top: 4px;
}
.app__card {
  background: var(--surface);
  border-radius: var(--r-md);
  padding: 10px 11px;
  box-shadow: var(--shadow-xs);
  border: 1px solid var(--border);
  display: flex;
  align-items: center;
  gap: 10px;
}
.app__card-icon {
  width: 30px; height: 30px;
  border-radius: 8px;
  background: var(--primary-surface);
  display: grid;
  place-items: center;
  color: var(--primary);
  flex-shrink: 0;
  font-weight: 700;
}
.app__card-icon.amber { background: var(--accent-surface); color: #8A6A2E; }
.app__card-icon.olive { background: #E6EDD8; color: var(--success); }
.app__card-text { display: flex; flex-direction: column; min-width: 0; }
.app__card-title { font-size: 12px; font-weight: 700; color: var(--text-primary); }
.app__card-sub { font-size: 10px; color: var(--text-secondary); }
.app__card-meta { margin-left: auto; font-size: 10px; font-weight: 700; color: var(--primary); white-space: nowrap; }

.app__tabbar {
  background: var(--surface);
  border-top: 1px solid var(--border);
  padding: 8px 16px 14px;
  display: flex;
  justify-content: space-between;
}
.app__tab { display: flex; flex-direction: column; align-items: center; gap: 2px; font-size: 9px; color: var(--text-tertiary); font-weight: 600; }
.app__tab.active { color: var(--primary); }
.app__tab svg { width: 18px; height: 18px; }

/* ───────── Cards / Features ───────── */
.section__head {
  text-align: center;
  margin-bottom: var(--s-xxxl);
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: var(--s-lg);
}
.section__head .lead { text-align: center; }

.grid {
  display: grid;
  gap: var(--s-xl);
}
.grid--3 { grid-template-columns: repeat(3, 1fr); }
.grid--2 { grid-template-columns: repeat(2, 1fr); }

.card {
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: var(--r-lg);
  padding: var(--s-xl);
  transition: transform .2s, box-shadow .2s, border-color .2s;
}
.card:hover {
  transform: translateY(-3px);
  box-shadow: var(--shadow-hover);
  border-color: rgba(31,89,89,0.18);
}
.card__icon {
  width: 48px;
  height: 48px;
  border-radius: var(--r-md);
  background: var(--primary-surface);
  display: grid;
  place-items: center;
  color: var(--primary);
  margin-bottom: var(--s-lg);
}
.card__icon.accent { background: var(--accent-surface); color: #8A6A2E; }
.card h3 { margin-bottom: 6px; font-family: "Plus Jakarta Sans", sans-serif; font-size: 18px; font-weight: 700; letter-spacing: -0.01em;}
.card p { font-size: 14.5px; line-height: 1.55; }

/* Section "For foreninger" */
.split {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 64px;
  align-items: center;
}
.split--reverse > :first-child { order: 2; }

.checklist { display: flex; flex-direction: column; gap: 12px; margin-top: var(--s-lg); }
.checklist li {
  display: flex; gap: 12px; align-items: flex-start;
  font-size: 15px; color: var(--text-primary);
}
.checklist svg {
  width: 22px; height: 22px;
  background: var(--primary-surface);
  color: var(--primary);
  border-radius: 50%;
  padding: 3px;
  flex-shrink: 0;
}

/* Visual cluster card */
.cluster {
  position: relative;
  background: var(--surface-alt);
  border: 1px solid var(--border);
  border-radius: var(--r-xl);
  padding: 36px;
  min-height: 440px;
  overflow: hidden;
}
.cluster__title { font-size: 13px; font-weight: 700; color: var(--text-tertiary); text-transform: uppercase; letter-spacing: 0.1em; }
.cluster__row {
  display: flex;
  align-items: center;
  gap: 14px;
  background: var(--surface);
  border-radius: var(--r-md);
  border: 1px solid var(--border);
  padding: 14px;
  margin-top: 12px;
  box-shadow: var(--shadow-xs);
}
.cluster__avatar {
  width: 40px; height: 40px;
  border-radius: 50%;
  background: var(--primary-surface);
  color: var(--primary);
  display: grid; place-items: center;
  font-weight: 700;
  font-size: 14px;
  flex-shrink: 0;
}
.cluster__avatar.amber { background: var(--accent-surface); color: #8A6A2E; }
.cluster__avatar.olive { background: #E6EDD8; color: var(--success); }
.cluster__row strong { display: block; font-size: 14px; color: var(--text-primary); }
.cluster__row span { font-size: 12px; color: var(--text-secondary); }
.cluster__pill {
  margin-left: auto;
  font-size: 11px;
  font-weight: 700;
  color: var(--primary);
  background: var(--primary-surface);
  padding: 4px 10px;
  border-radius: var(--r-pill);
}
.cluster__pill.amber { color: #8A6A2E; background: var(--accent-surface); }

/* CTA banner */
.cta-banner {
  background: linear-gradient(135deg, var(--primary-deep), var(--primary));
  color: white;
  border-radius: var(--r-xl);
  padding: 64px;
  position: relative;
  overflow: hidden;
  text-align: center;
}
.cta-banner::before {
  content: "";
  position: absolute;
  inset: 0;
  background-image: url("pattern.svg");
  background-size: 220px 220px;
  opacity: .08;
  pointer-events: none;
}
.cta-banner h2 { color: white; }
.cta-banner p { color: rgba(255,255,255,0.78); max-width: 50ch; margin: 16px auto 0; font-size: 17px; }
.cta-banner .stores { justify-content: center; margin-top: 28px; }
.cta-banner .store { background: white; color: var(--text-primary); }

/* Footer */
.footer {
  border-top: 1px solid var(--border);
  padding: 56px 0 32px;
  background: var(--surface-alt);
}
.footer__grid {
  display: grid;
  grid-template-columns: 1.4fr repeat(3, 1fr);
  gap: 48px;
}
.footer__col h4 { font-family: "Plus Jakarta Sans", sans-serif; font-size: 13px; font-weight: 700; text-transform: uppercase; letter-spacing: 0.08em; color: var(--text-tertiary); margin-bottom: 14px; }
.footer__col ul { display: flex; flex-direction: column; gap: 10px; }
.footer__col a { font-size: 14px; color: var(--text-secondary); }
.footer__col a:hover { color: var(--primary); }
.footer__brand p { font-size: 14px; max-width: 32ch; margin-top: 12px; }
.footer__bottom {
  margin-top: 48px;
  padding-top: 20px;
  border-top: 1px solid var(--border);
  display: flex;
  justify-content: space-between;
  font-size: 13px;
  color: var(--text-tertiary);
}

/* Small bits */
.kicker-row {
  display: flex;
  gap: var(--s-md);
  align-items: center;
  margin-bottom: var(--s-md);
  flex-wrap: wrap;
}

/* Page hero (subpages) */
.page-hero {
  position: relative;
  overflow: hidden;
  padding: 80px 0 64px;
  text-align: center;
}
.page-hero h1 { max-width: 22ch; margin: 0 auto; }
.page-hero .lead { margin: var(--s-lg) auto 0; }

/* Quote / pull */
.pull {
  border-left: 3px solid var(--accent);
  padding: 6px 0 6px 20px;
  font-size: 18px;
  color: var(--text-primary);
  font-style: italic;
}

/* Tweaks-aware adjustments */
.no-pattern .pattern-bg,
.no-pattern .cta-banner::before,
.no-pattern .hero__visual-pattern { display: none !important; }

/* Hero layout variants */
body[data-hero="center"] .hero__grid {
  grid-template-columns: 1fr;
  text-align: center;
  justify-items: center;
}
body[data-hero="center"] .hero__copy { max-width: 720px; }
body[data-hero="center"] .hero__cta,
body[data-hero="center"] .hero__meta { justify-content: center; }
body[data-hero="center"] .hero__visual { margin-top: 32px; min-height: 580px; }
body[data-hero="center"] .lead { margin-left: auto; margin-right: auto; }

body[data-hero="tilt"] .phone {
  transform: rotate(-6deg) translateY(-10px);
}
body[data-hero="tilt"] .hero__visual-disc {
  transform: rotate(8deg);
}
body[data-hero="tilt"] .tag-top-left { transform: rotate(-6deg); }
body[data-hero="tilt"] .tag-bottom-right { transform: rotate(-6deg); }
body[data-hero="tilt"] .tag-mid-right { transform: rotate(-6deg); }

/* Hidden by language */
[data-lang-en], [data-lang-da] { display: none; }
html[lang="da"] [data-lang-da] { display: inline; }
html[lang="en"] [data-lang-en] { display: inline; }
html[lang="da"] .block[data-lang-da],
html[lang="da"] li[data-lang-da],
html[lang="da"] p[data-lang-da],
html[lang="da"] h1[data-lang-da],
html[lang="da"] h2[data-lang-da],
html[lang="da"] h3[data-lang-da] { display: block; }
html[lang="en"] .block[data-lang-en],
html[lang="en"] li[data-lang-en],
html[lang="en"] p[data-lang-en],
html[lang="en"] h1[data-lang-en],
html[lang="en"] h2[data-lang-en],
html[lang="en"] h3[data-lang-en] { display: block; }

/* Responsive */
@media (max-width: 960px) {
  .hero__grid, .split { grid-template-columns: 1fr; gap: 40px; }
  .split--reverse > :first-child { order: 0; }
  .grid--3 { grid-template-columns: repeat(2, 1fr); }
  .footer__grid { grid-template-columns: 1fr 1fr; }
  .nav { display: none; }
  .section { padding: 72px 0; }
  .cta-banner { padding: 44px 28px; }
  .hero__visual { min-height: 520px; }
}
@media (max-width: 600px) {
  .grid--3, .grid--2 { grid-template-columns: 1fr; }
  .footer__grid { grid-template-columns: 1fr; }
  .footer__bottom { flex-direction: column; gap: 8px; }
  .hero__meta { gap: 16px; }
  .container { padding: 0 var(--s-lg); }
  .hero__visual-disc { width: 360px; height: 360px; }
  .phone--floating-tag { display: none; }
}
