/* A-kasse Kompas. Bank-stil: hvid flade, navy top, én grøn accent, 4px radius. */
@font-face { font-family: "IBM Plex Sans"; src: url("/assets/fonts/ibm-plex-sans-latin-400-normal.woff2") format("woff2"); font-weight: 400; font-display: swap; }
@font-face { font-family: "IBM Plex Sans"; src: url("/assets/fonts/ibm-plex-sans-latin-500-normal.woff2") format("woff2"); font-weight: 500; font-display: swap; }
@font-face { font-family: "IBM Plex Sans"; src: url("/assets/fonts/ibm-plex-sans-latin-600-normal.woff2") format("woff2"); font-weight: 600; font-display: swap; }
@font-face { font-family: "IBM Plex Sans"; src: url("/assets/fonts/ibm-plex-sans-latin-700-normal.woff2") format("woff2"); font-weight: 700; font-display: swap; }

:root {
  --bg: #ffffff;
  --band: #f3f5f7;
  --surface: #ffffff;
  --ink: #0b1f33;
  --ink-2: #3d4a58;
  --muted: #6b7785;
  --line: #d5dbe2;
  --line-soft: #eef1f4;
  --navy: #0b1f33;
  --navy-ink: #ffffff;
  --navy-muted: #b7c2cf;
  --accent: #0b6b4f;
  --accent-ink: #084d39;
  --accent-tint: #e6f3ee;
  --on-accent: #ffffff;
  --info-tint: #e8eef6;
  --good: #0b6b4f;
  --bad: #b23a30;
  --warn: #c98a1b;
  --warn-tint: #fbf1dc;
  --r: 4px;
  --shadow: 0 8px 24px rgba(11, 31, 51, .06);
  --font: "IBM Plex Sans", ui-sans-serif, -apple-system, "Segoe UI", Roboto, Arial, sans-serif;
  --max: 1160px;
  color-scheme: light dark;
}
@media (prefers-color-scheme: dark) {
  :root {
    --bg: #0f1620; --band: #141d29; --surface: #182230; --ink: #e9edf2; --ink-2: #c3cbd5; --muted: #8f9aa8;
    --line: #2a3542; --line-soft: #202a36; --navy: #0a1420; --navy-ink: #e9edf2; --navy-muted: #8f9aa8;
    --accent: #3fbf93; --accent-ink: #6fd3b0; --accent-tint: #15302a; --on-accent: #06251c; --info-tint: #1a2535;
    --good: #3fbf93; --bad: #ee7d73; --warn: #e2a84a; --warn-tint: #2c2615; --shadow: none;
  }
}

*, *::before, *::after { box-sizing: border-box; }
html { -webkit-text-size-adjust: 100%; }
body { margin: 0; font-family: var(--font); color: var(--ink); background: var(--bg); line-height: 1.55; font-size: 17px; }
img, svg { max-width: 100%; display: block; }
a { color: var(--accent); text-underline-offset: 3px; text-decoration-thickness: 1px; }
a:hover { color: var(--accent-ink); }
h1, h2, h3 { line-height: 1.1; letter-spacing: -.02em; margin: 0 0 .45em; font-weight: 700; }
h1 { font-size: clamp(2rem, 4vw, 3.1rem); max-width: 20ch; }
h2 { font-size: clamp(1.4rem, 2.3vw, 1.8rem); margin-top: 1.8em; }
h3 { font-size: 1.12rem; letter-spacing: -.01em; }
p { margin: 0 0 1em; }
.wrap { max-width: var(--max); margin: 0 auto; padding: 0 16px; }
@media (min-width: 768px) { .wrap { padding: 0 32px; } }
.narrow { max-width: 760px; }
.muted { color: var(--muted); }
.small { font-size: .88rem; }
.sr { position: absolute; width: 1px; height: 1px; overflow: hidden; clip: rect(0 0 0 0); }

/* Header: navy bånd */
.top { background: var(--navy); color: var(--navy-ink); position: sticky; top: 0; z-index: 20; }
.top .wrap { display: flex; align-items: center; justify-content: space-between; height: 68px; gap: 16px; }
.logo { display: flex; align-items: center; gap: 10px; font-weight: 700; color: var(--navy-ink); text-decoration: none; letter-spacing: -.01em; font-size: 1.1rem; }
.logo svg { width: 26px; height: 26px; }
.logo:hover { color: var(--navy-ink); }
.nav { display: flex; gap: 26px; }
.nav a { color: var(--navy-muted); text-decoration: none; font-weight: 500; font-size: .95rem; padding: 6px 0; border-bottom: 2px solid transparent; }
.nav a:hover { color: var(--navy-ink); }
.nav a[aria-current] { color: var(--navy-ink); border-bottom-color: var(--accent); }
.menu-btn { display: none; background: none; border: 1px solid rgba(255,255,255,.3); border-radius: var(--r); padding: 7px 12px; font: inherit; font-weight: 600; color: var(--navy-ink); }
@media (max-width: 960px) {
  .menu-btn { display: block; }
  .nav { display: none; position: absolute; top: 68px; left: 0; right: 0; background: var(--navy); flex-direction: column; gap: 0; padding: 4px 16px 12px; }
  .nav.open { display: flex; }
  .nav a { padding: 12px 0; border-bottom: 1px solid rgba(255,255,255,.12); }
  .nav a[aria-current] { border-bottom-color: rgba(255,255,255,.12); color: var(--accent-ink); }
}
.foot .logo { color: var(--ink); }

.crumbs { font-size: .85rem; color: var(--muted); margin-top: 22px; }
.crumbs a { color: var(--muted); }

/* Page heads */
.page-head { padding: 26px 0 10px; max-width: 780px; }
.lead { font-size: 1.15rem; color: var(--ink-2); max-width: 60ch; }
.updated { font-size: .85rem; color: var(--muted); margin-top: -4px; }

/* Hero (forside): grå bånd, tekst + kontoudtog */
.hero { background: var(--band); padding: 52px 0 48px; }
.hero .wrap { display: grid; grid-template-columns: minmax(0, 1fr) minmax(0, 1fr); gap: 56px; align-items: center; }
.hero h1 { font-size: clamp(2.1rem, 4vw, 3.3rem); max-width: 15ch; }
.hero .lead { font-size: 1.15rem; }
@media (max-width: 900px) { .hero .wrap { grid-template-columns: 1fr; gap: 32px; } .hero { padding: 36px 0 40px; } }

.situations { display: flex; flex-wrap: wrap; gap: 8px; margin-top: 22px; }
.situations a { background: var(--surface); border: 1px solid var(--line); color: var(--ink); text-decoration: none; font-weight: 500; font-size: .9rem; padding: 8px 13px; border-radius: 999px; }
.situations a:hover { border-color: var(--accent); color: var(--accent-ink); }

/* Kontoudtog-kortet */
.statement { background: var(--surface); border: 1px solid var(--line); border-radius: var(--r); padding: 26px 30px; box-shadow: var(--shadow); }
.statement .head { display: flex; justify-content: space-between; align-items: center; gap: 12px; border-bottom: 1px solid var(--line); padding-bottom: 14px; margin-bottom: 4px; }
.statement .head label { font-size: 14px; font-weight: 600; color: var(--ink-2); display: flex; align-items: center; gap: 8px; }
.statement .head input { font: inherit; font-weight: 600; width: 120px; border: 1px solid var(--line); padding: 6px 8px; border-radius: var(--r); color: var(--ink); background: var(--surface); text-align: right; }
.statement input[type=range] { width: 100%; accent-color: var(--accent); margin: 10px 0 6px; }
.statement .rows { display: grid; grid-template-columns: 1fr auto; font-size: 16px; }
.statement .rows span { padding: 12px 0; border-bottom: 1px solid var(--line-soft); }
.statement .rows span:nth-child(even) { text-align: right; font-variant-numeric: tabular-nums; }
.statement .rows .k { color: var(--ink-2); }
.statement .rows .tot { border-bottom: 0; padding-top: 18px; font-weight: 700; font-size: 18px; }
.statement .rows .tot.v { font-size: 30px; color: var(--accent); letter-spacing: -.02em; line-height: 1.2; }
.statement .foot { margin: 10px 0 0; font-size: 13px; color: var(--muted); }
.statement .foot a { font-weight: 600; }

/* Buttons */
.btn { display: inline-flex; align-items: center; justify-content: center; gap: 8px; font: inherit; font-weight: 600; border-radius: var(--r); padding: 13px 22px; border: 1px solid transparent; cursor: pointer; text-decoration: none; white-space: nowrap; transition: background .15s ease, border-color .15s ease; }
.btn:active { transform: translateY(1px); }
.btn-primary { background: var(--accent); color: var(--on-accent); }
.btn-primary:hover { background: var(--accent-ink); color: var(--on-accent); }
.btn-ghost { background: transparent; color: var(--ink); border-color: var(--ink); }
.btn-ghost:hover { background: var(--ink); color: var(--bg); }
.btn-sm { padding: 8px 14px; font-size: .92rem; }
.btn-row { display: flex; flex-wrap: wrap; gap: 12px; margin-top: 24px; }
.ad-tag { font-size: .72rem; color: var(--muted); margin-top: 3px; }

/* Surfaces */
.card { background: var(--surface); border: 1px solid var(--line); border-radius: var(--r); padding: 24px; }
.grid { display: grid; gap: 16px; }
.grid-2 { grid-template-columns: repeat(2, minmax(0, 1fr)); }
.grid-3 { grid-template-columns: repeat(3, minmax(0, 1fr)); }
@media (max-width: 760px) { .grid-2, .grid-3 { grid-template-columns: 1fr; } }
.section { padding: 52px 0 0; }
.section > .wrap > h2:first-child { margin-top: 0; }

/* Værktøjer: tre kolonner med topstreg */
.tools { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 36px; }
.tools a { display: flex; flex-direction: column; gap: 8px; text-decoration: none; color: var(--ink); border-top: 3px solid var(--navy); padding-top: 16px; }
.tools a h3 { margin: 0; font-size: 1.25rem; }
.tools a p { color: var(--ink-2); margin: 0; font-size: .96rem; line-height: 1.5; }
.tools a .go { color: var(--accent); font-weight: 600; margin-top: 4px; }
.tools a:hover .go { text-decoration: underline; }
@media (max-width: 760px) { .tools { grid-template-columns: 1fr; gap: 20px; } }

/* Tal-række */
.facts { display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); gap: 24px; margin: 28px 0 8px; border-top: 1px solid var(--line); padding-top: 18px; }
.fact b { display: block; font-size: clamp(1.5rem, 2.6vw, 2rem); font-weight: 700; letter-spacing: -.02em; line-height: 1.1; font-variant-numeric: tabular-nums; }
.fact span { font-size: .88rem; color: var(--muted); }
.grid-3.stats { grid-template-columns: repeat(3, minmax(0, 1fr)); border-top: 1px solid var(--line); padding-top: 18px; gap: 24px; margin: 24px 0; }
@media (max-width: 760px) { .facts, .grid-3.stats { grid-template-columns: repeat(2, minmax(0, 1fr)); } }

/* Forms */
.tool { display: grid; grid-template-columns: minmax(0, 1fr) minmax(0, .9fr); gap: 24px; align-items: start; margin-top: 18px; }
@media (max-width: 900px) { .tool { grid-template-columns: 1fr; } }
.field { margin-bottom: 20px; }
.field > label, .field > .label { display: block; font-weight: 600; font-size: .95rem; margin-bottom: 8px; }
.field .hint { font-size: .85rem; color: var(--muted); margin-top: 6px; }
input[type=number], input[type=email], input[type=text], select { width: 100%; font: inherit; padding: 11px 13px; border: 1px solid var(--line); border-radius: var(--r); background: var(--surface); color: var(--ink); }
input::placeholder { color: var(--muted); }
input:focus-visible, select:focus-visible, button:focus-visible, a:focus-visible, .seg input:focus-visible + span { outline: 2px solid var(--accent); outline-offset: 2px; }
input[type=range] { width: 100%; accent-color: var(--accent); }
.seg { display: inline-flex; flex-wrap: wrap; border: 1px solid var(--line); border-radius: var(--r); overflow: hidden; }
.seg label { position: relative; }
.seg label + label span { border-left: 1px solid var(--line); }
.seg input { position: absolute; opacity: 0; }
.seg span { display: block; padding: 9px 16px; font-size: .93rem; font-weight: 500; cursor: pointer; background: var(--surface); color: var(--ink-2); }
.seg input:checked + span { background: var(--navy); color: var(--navy-ink); }
.check { display: flex; gap: 10px; align-items: flex-start; font-size: .95rem; margin-bottom: 6px; }
.check input { margin-top: 4px; accent-color: var(--accent); width: 17px; height: 17px; flex: none; }
.money { position: relative; }
.money input { padding-right: 50px; font-size: 1.2rem; font-weight: 600; }
.money::after { content: "kr."; position: absolute; right: 14px; top: 50%; transform: translateY(-50%); color: var(--muted); }

/* Resultatpanel: navy */
.result { position: sticky; top: 88px; background: var(--navy); color: var(--navy-ink); border: 0; }
.result .lbl { font-size: .9rem; color: var(--navy-muted); font-weight: 500; }
.result .big { font-size: clamp(2.4rem, 5.5vw, 3.4rem); font-weight: 700; letter-spacing: -.03em; line-height: 1; margin: 6px 0 4px; font-variant-numeric: tabular-nums; }
.result .split { display: grid; grid-template-columns: 1fr 1fr; gap: 20px; margin: 22px 0 18px; padding: 16px 0; border-top: 1px solid rgba(255,255,255,.15); border-bottom: 1px solid rgba(255,255,255,.15); }
.result .pill b { display: block; font-size: 1.3rem; letter-spacing: -.01em; }
.result .pill small { color: var(--navy-muted); font-size: .82rem; }
.result .row { display: flex; justify-content: space-between; gap: 12px; padding: 6px 0; font-size: .95rem; font-variant-numeric: tabular-nums; }
.result .row span:first-child { color: var(--navy-muted); }
.result a { color: var(--navy-ink); }
.result .btn-primary { width: 100%; margin-top: 18px; }
.bar { display: none; }

/* Tabeller */
.table-wrap { overflow-x: auto; border: 1px solid var(--line); border-radius: var(--r); background: var(--surface); }
table { width: 100%; border-collapse: collapse; font-size: .95rem; }
th, td { padding: 13px 14px; text-align: left; vertical-align: middle; border-bottom: 1px solid var(--line-soft); }
th { font-size: .8rem; color: var(--muted); font-weight: 600; white-space: nowrap; background: var(--band); border-bottom: 1px solid var(--line); }
tr:last-child td { border-bottom: 0; }
th button { all: unset; cursor: pointer; }
th button:hover { color: var(--ink); }
td.num, th.num { text-align: right; white-space: nowrap; font-variant-numeric: tabular-nums; }
tr.is-cheapest td:first-child { box-shadow: inset 3px 0 0 var(--accent); }
.name-cell a { font-weight: 600; color: var(--ink); text-decoration: none; }
.name-cell a:hover { color: var(--accent); text-decoration: underline; }
.name-cell small { display: block; color: var(--muted); font-size: .82rem; max-width: 380px; }
.save { color: var(--good); font-weight: 600; }
.cost { color: var(--bad); }
.badge { display: inline-block; font-size: .74rem; font-weight: 600; padding: 2px 7px; border-radius: 3px; background: var(--band); color: var(--ink-2); white-space: nowrap; margin-left: 6px; vertical-align: 2px; }
.badge-good { background: var(--accent-tint); color: var(--accent-ink); }
.badge-warn { background: var(--warn-tint); color: var(--ink); }
.badge-gul { background: #fff4d6; color: #7a5a0b; }
.badge-roed { background: #fbe3e1; color: #8a2b22; }
@media (prefers-color-scheme: dark) { .badge-gul { background: #3a2f10; color: #f1c766; } .badge-roed { background: #3a1c19; color: #f4a39b; } }
.table-note { font-size: .85rem; color: var(--muted); margin-top: 10px; }

.filters { display: grid; grid-template-columns: repeat(auto-fit, minmax(220px, 1fr)); gap: 16px 24px; align-items: end; margin: 0 0 22px; }
.filters .field { margin: 0; }
#cmp { padding: 0; border: 0; background: none; }

/* Matcher */
.quiz { max-width: 760px; }
.progress { height: 4px; background: var(--line-soft); margin-bottom: 26px; border-radius: 2px; }
.progress i { display: block; height: 100%; background: var(--accent); transition: width .3s ease; border-radius: 2px; }
.q-step { display: none; }
.q-step.active { display: block; }
.q-step h2 { margin-top: 0; }
.options { display: grid; gap: 8px; margin: 18px 0; }
.options button { text-align: left; font: inherit; font-weight: 500; color: var(--ink); padding: 15px 18px; border: 1px solid var(--line); border-radius: var(--r); background: var(--surface); cursor: pointer; display: flex; justify-content: space-between; align-items: center; gap: 12px; }
.options button:hover { border-color: var(--accent); }
.options button small { color: var(--muted); font-weight: 400; }
.match { display: grid; grid-template-columns: 36px minmax(0, 1fr) auto; gap: 18px; align-items: start; padding: 22px 0; border-top: 1px solid var(--line); }
.match.first { border-top: 3px solid var(--navy); }
.match .rank { font-size: 1.5rem; font-weight: 700; color: var(--muted); line-height: 1.2; }
.match.first .rank { color: var(--accent); }
.match h3 { margin: 0; }
.match ul { margin: 8px 0 0; padding-left: 18px; color: var(--ink-2); font-size: .93rem; }
.match .price { text-align: right; font-weight: 700; font-size: 1.3rem; font-variant-numeric: tabular-nums; }
.match .price small { display: block; font-weight: 400; font-size: .8rem; color: var(--muted); }
@media (max-width: 620px) { .match { grid-template-columns: 28px minmax(0, 1fr); } .match .cta { grid-column: 2; } .match .price { text-align: left; } }

/* Ret-tjekker */
.verdict { padding: 0 0 6px; margin-bottom: 18px; border-top: 3px solid var(--line); }
.verdict.ja { border-top-color: var(--good); }
.verdict.snart { border-top-color: var(--warn); }
.verdict.nej { border-top-color: var(--bad); }
.verdict h3 { font-size: 1.45rem; margin: 18px 0 6px; }
.checklist { list-style: none; padding: 0; margin: 10px 0 0; }
.checklist li { display: grid; grid-template-columns: 26px 1fr; gap: 10px; padding: 8px 0; font-size: .96rem; }
.checklist li::before { font-weight: 700; font-size: .78rem; padding-top: 3px; }
.checklist li.ok::before { content: "Ja"; color: var(--good); }
.checklist li.no::before { content: "Nej"; color: var(--bad); }
.checklist li.info::before { content: "OBS"; color: var(--muted); font-size: .7rem; padding-top: 4px; }
#ret-next { background: var(--band); border: 0; }

/* Tekst */
.prose { max-width: 720px; }
.prose ul, .prose ol { padding-left: 1.2em; }
.prose li { margin-bottom: .4em; }
.prose h2 { font-size: 1.4rem; }
.faq { border-top: 1px solid var(--line); }
.faq details { border-bottom: 1px solid var(--line); }
.faq summary { cursor: pointer; font-weight: 600; padding: 16px 0; list-style: none; display: flex; justify-content: space-between; gap: 16px; }
.faq summary::-webkit-details-marker { display: none; }
.faq summary::after { content: "+"; color: var(--muted); font-weight: 400; font-size: 1.3rem; line-height: 1; }
.faq details[open] summary::after { content: "-"; }
.faq details p { color: var(--ink-2); max-width: 65ch; }
.callout { background: var(--info-tint); border-radius: var(--r); padding: 16px 20px; font-size: .95rem; margin: 24px 0; color: var(--ink-2); }
.callout.warn { background: var(--warn-tint); }
.sources { font-size: .85rem; color: var(--muted); margin-top: 28px; }
.sources a { color: var(--muted); }

.chips { display: flex; flex-wrap: wrap; gap: 8px; }
.chips a { display: inline-block; padding: 7px 12px; border-radius: 999px; border: 1px solid var(--line); color: var(--ink-2); text-decoration: none; font-size: .92rem; background: var(--surface); }
.chips a:hover { border-color: var(--accent); color: var(--accent-ink); }

.groups { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 28px 32px; margin-top: 18px; }
.groups h3 { font-size: .95rem; color: var(--muted); font-weight: 600; margin-bottom: 8px; }
.groups ul { list-style: none; padding: 0; margin: 0; }
.groups li a { display: block; padding: 5px 0; color: var(--ink); text-decoration: none; }
.groups li a:hover { color: var(--accent); }
@media (max-width: 760px) { .groups { grid-template-columns: 1fr 1fr; } }

/* To-kolonne tekst uden kort */
.cols2 { display: grid; grid-template-columns: 1fr 1fr; gap: 40px; margin-top: 24px; }
.cols2 > div { border-top: 3px solid var(--navy); padding-top: 16px; }
@media (max-width: 760px) { .cols2 { grid-template-columns: 1fr; } }

/* Prisalarm */
.alert-box { margin: 64px 0 0; padding: 32px; background: var(--band); border-radius: var(--r); display: grid; grid-template-columns: 1fr 1fr; gap: 32px; align-items: start; }
.alert-box h2 { margin-top: 0; font-size: 1.5rem; }
.alert-box p { color: var(--ink-2); max-width: 46ch; }
.alert-box form { display: grid; grid-template-columns: 1fr 1fr; gap: 10px; }
.alert-box form .check, .alert-box form button { grid-column: 1 / -1; }
.alert-box .check { font-size: .85rem; color: var(--muted); }
.alert-box button { justify-self: start; }
@media (max-width: 760px) { .alert-box, .alert-box form { grid-template-columns: 1fr; } }

/* Footer */
.foot { margin-top: 64px; border-top: 1px solid var(--line); padding: 40px 0 28px; font-size: .9rem; color: var(--muted); }
.foot .cols { display: grid; grid-template-columns: 1.5fr 1fr 1fr 1fr; gap: 28px; }
.foot h4 { color: var(--ink); margin: 0 0 10px; font-size: .9rem; font-weight: 600; }
.foot ul { list-style: none; padding: 0; margin: 0; }
.foot li { margin-bottom: 6px; }
.foot a { color: var(--muted); text-decoration: none; }
.foot a:hover { color: var(--ink); }
.foot .legal { border-top: 1px solid var(--line); margin-top: 32px; padding-top: 18px; font-size: .82rem; max-width: 90ch; }
@media (max-width: 760px) { .foot .cols { grid-template-columns: 1fr 1fr; } }

@media (prefers-reduced-motion: reduce) { * { transition: none !important; } }
