/* Gulvvarmeguiden
   Layout: smal læsekolonne + et "risikobillede"-panel ved siden af på store skærme, under på mobil.
   Farver: vand (blå-grøn) som accent, varme (rød-orange) kun til fremløb/alvor. */
:root {
  --bg: #f3f6f7;
  --surface: #ffffff;
  --surface-2: #e8eff2;
  --ink: #13242e;
  --muted: #566a75;
  --line: #d3dee3;
  --water: #1c6a85;
  --water-ink: #ffffff;
  --heat: #c9482c;
  --ok: #2c7a4b;
  --warn: #a86a12;
  --stop: #b42318;
  --warn-bg: #fdf3e2;
  --stop-bg: #fdeceb;
  --font-display: "Bricolage Grotesque", "Segoe UI", system-ui, sans-serif;
  --font-body: "Figtree", "Segoe UI", system-ui, -apple-system, sans-serif;
  --radius: 10px;
  --maxw: 1120px;
}
@media (prefers-color-scheme: dark) {
  :root:not([data-theme="light"]) {
    --bg: #0e171c; --surface: #15222a; --surface-2: #1c2c35; --ink: #e5eef2; --muted: #9db0ba;
    --line: #2a3d48; --water: #5bb3cf; --water-ink: #0b1a20; --heat: #f07a5c; --ok: #6cc592;
    --warn: #e8b25a; --stop: #f2796d; --warn-bg: #2e2412; --stop-bg: #331a18; color-scheme: dark;
  }
}
:root[data-theme="dark"] {
  --bg: #0e171c; --surface: #15222a; --surface-2: #1c2c35; --ink: #e5eef2; --muted: #9db0ba;
  --line: #2a3d48; --water: #5bb3cf; --water-ink: #0b1a20; --heat: #f07a5c; --ok: #6cc592;
  --warn: #e8b25a; --stop: #f2796d; --warn-bg: #2e2412; --stop-bg: #331a18; color-scheme: dark;
}

* { box-sizing: border-box; }
html { -webkit-text-size-adjust: 100%; }
body {
  margin: 0; background: var(--bg); color: var(--ink);
  font-family: var(--font-body); font-size: 17px; line-height: 1.55;
}
a { color: var(--water); text-underline-offset: 2px; }
img { max-width: 100%; }
h1, h2, h3 { font-family: var(--font-display); line-height: 1.15; text-wrap: balance; margin: 0 0 .5em; }
h1 { font-size: clamp(1.7rem, 3.4vw, 2.4rem); font-weight: 700; letter-spacing: -.01em; }
h2 { font-size: 1.35rem; font-weight: 650; }
h3 { font-size: 1.05rem; }
p { margin: 0 0 1em; }
.small { font-size: .875rem; }
.muted { color: var(--muted); }
.caps { text-transform: uppercase; letter-spacing: .06em; font-family: var(--font-body); font-weight: 700; color: var(--muted); margin-top: 1.2em; }
.num { font-variant-numeric: tabular-nums; }
.eyebrow { text-transform: uppercase; letter-spacing: .08em; font-size: .78rem; font-weight: 700; color: var(--water); margin-bottom: .5em; }
.lead { font-size: 1.12rem; max-width: 62ch; }
:focus-visible { outline: 3px solid var(--water); outline-offset: 2px; border-radius: 4px; }
[hidden] { display: none !important; }

.wrap { max-width: var(--maxw); margin: 0 auto; padding-left: max(16px, env(safe-area-inset-left, 0px)); padding-right: max(16px, env(safe-area-inset-right, 0px)); }

/* Header */
.site-header { background: var(--surface); border-bottom: 1px solid var(--line); }
.site-header .wrap { display: flex; flex-wrap: wrap; align-items: center; gap: 8px 24px; padding-block: 12px; }
.logo { display: flex; align-items: center; gap: 10px; text-decoration: none; color: var(--ink); font-family: var(--font-display); font-weight: 700; font-size: 1.2rem; }
.logo svg { flex: none; }
.logo .tld { color: var(--muted); font-weight: 500; }
.nav { display: flex; flex-wrap: wrap; gap: 4px 18px; margin-left: auto; font-size: .95rem; }
.nav a { color: var(--ink); text-decoration: none; padding: 4px 0; border-bottom: 2px solid transparent; }
.nav a:hover, .nav a[aria-current="page"] { border-color: var(--heat); }

/* Main layout */
main { padding-block: 32px 56px; }
.layout { display: grid; grid-template-columns: minmax(0, 1fr) 320px; gap: 32px; align-items: start; }
body[data-view="start"] .layout { grid-template-columns: minmax(0, 1fr); }
@media (max-width: 860px) { .layout { grid-template-columns: minmax(0, 1fr); } }
.content { min-width: 0; max-width: 72ch; }

/* Buttons */
.btn { display: inline-flex; align-items: center; justify-content: center; gap: 6px; min-height: 44px; padding: 10px 18px; border-radius: 8px; border: 2px solid var(--water); background: var(--water); color: var(--water-ink); font: 600 1rem var(--font-body); text-decoration: none; cursor: pointer; }
.btn:hover { filter: brightness(1.08); }
.btn:disabled { opacity: .45; cursor: not-allowed; }
.btn.ghost { background: transparent; color: var(--water); }
.btn[aria-pressed="true"] { background: var(--water); color: var(--water-ink); }
.link { background: none; border: 0; padding: 0; color: var(--water); font: inherit; cursor: pointer; text-decoration: underline; text-underline-offset: 2px; }
.question > p.small { margin-top: 18px; }
.actions { display: flex; flex-wrap: wrap; gap: 10px; margin-top: 16px; }

/* Start */
.start h1 { font-size: clamp(2rem, 4.6vw, 3.1rem); max-width: 18ch; }
.flow-cards { display: grid; grid-template-columns: repeat(auto-fit, minmax(260px, 1fr)); gap: 20px; margin: 28px 0; }
.flow-card { display: flex; flex-direction: column; gap: 8px; padding: 24px; background: var(--surface); border: 1px solid var(--line); border-radius: var(--radius); color: var(--ink); text-decoration: none; transition: border-color .15s, transform .15s; }
.flow-card:hover { border-color: var(--water); transform: translateY(-2px); }
.flow-card p { color: var(--muted); flex: 1; }
.flow-card .btn { align-self: flex-start; }
.flow-icon { color: var(--heat); }
@media (prefers-reduced-motion: reduce) { .flow-card { transition: none; } .flow-card:hover { transform: none; } }

/* Question */
.q-top { display: flex; justify-content: space-between; align-items: center; gap: 12px; margin-bottom: 14px; }
.progress { height: 6px; background: var(--surface-2); border-radius: 3px; overflow: hidden; margin-bottom: 22px; }
.progress span { display: block; height: 100%; background: linear-gradient(90deg, var(--water), var(--heat)); transition: width .3s; }
.help { color: var(--muted); max-width: 62ch; }
.options { display: grid; gap: 10px; margin-top: 18px; }
.option { display: flex; align-items: center; gap: 14px; width: 100%; text-align: left; padding: 14px 16px; min-height: 56px; background: var(--surface); color: var(--ink); border: 1.5px solid var(--line); border-radius: var(--radius); font: inherit; cursor: pointer; }
.option:hover { border-color: var(--water); }
.option img { flex: none; width: 72px; height: 48px; object-fit: cover; border-radius: 6px; background: var(--surface-2); }
.option input { flex: none; width: 20px; height: 20px; accent-color: var(--water); }
.option:has(input:checked) { border-color: var(--water); background: var(--surface-2); }
.opt-text { display: flex; flex-direction: column; min-width: 0; }
.opt-label { font-weight: 600; }
.opt-hint { font-size: .9rem; color: var(--muted); }
a.term { color: inherit; text-decoration: underline dotted var(--water); text-underline-offset: 3px; }

/* Panel */
.panel { position: sticky; top: calc(env(safe-area-inset-top, 0px) + 16px); background: var(--surface); border: 1px solid var(--line); border-radius: var(--radius); padding: 20px; min-width: 0; }
@media (max-width: 860px) { .panel { position: static; } }
.panel-title { font-size: 1.1rem; }
.severity { padding: 12px; border-radius: 8px; background: var(--surface-2); margin-bottom: 8px; }
.sev-head { display: flex; justify-content: space-between; gap: 8px; font-size: .9rem; }
.sev-scale { display: grid; grid-template-columns: repeat(3, 1fr); gap: 4px; margin: 8px 0; }
.sev-scale span { height: 8px; border-radius: 4px; background: var(--line); }
.sev-0 .sev-scale .on { background: var(--ok); }
.sev-1 .sev-scale .on { background: var(--warn); }
.sev-2 .sev-scale .on { background: var(--stop); }
.sev-2 .sev-head strong { color: var(--stop); }
.severity p { margin: 0; }
.alerts { list-style: none; padding: 0; margin: 8px 0; display: grid; gap: 6px; font-size: .88rem; font-weight: 600; }
.alerts li { padding: 6px 10px; border-radius: 6px; border-left: 4px solid var(--warn); background: var(--warn-bg); }
.alerts .alert-stop { border-color: var(--stop); background: var(--stop-bg); }
.bars { list-style: none; padding: 0; margin: 6px 0 12px; display: grid; gap: 10px; }
.bar-label { display: flex; justify-content: space-between; gap: 8px; font-size: .9rem; }
.bar { height: 8px; background: var(--surface-2); border-radius: 4px; overflow: hidden; }
.bar span { display: block; height: 100%; background: var(--water); border-radius: 4px; transition: width .4s; }
.bars li:first-child .bar span { background: var(--heat); }
@media (prefers-reduced-motion: reduce) { .bar span, .progress span { transition: none; } }

/* Stop */
.stop { background: var(--stop-bg); border: 2px solid var(--stop); border-radius: var(--radius); padding: 28px; }
.stop .eyebrow { color: var(--stop); }

/* Result */
.callout { padding: 14px 16px; border-radius: 8px; margin: 14px 0; border-left: 5px solid var(--warn); background: var(--warn-bg); }
.callout p { margin: 4px 0 0; }
.callout-stop { border-color: var(--stop); background: var(--stop-bg); }
.result-card { background: var(--surface); border: 1px solid var(--line); border-radius: var(--radius); padding: 22px; margin: 18px 0; }
.result-card.first { border: 2px solid var(--heat); }
.rc-head { display: flex; justify-content: space-between; align-items: baseline; gap: 12px; }
.pill { flex: none; padding: 2px 10px; border-radius: 999px; background: var(--surface-2); font-weight: 700; font-size: .9rem; }
.first .pill { background: var(--heat); color: var(--surface); }
.steps, .tips { padding-left: 1.3em; display: grid; gap: 6px; }
.pro { background: var(--surface-2); padding: 10px 14px; border-radius: 8px; }
.procon { display: grid; grid-template-columns: repeat(auto-fit, minmax(200px, 1fr)); gap: 0 20px; }
.procon ul { padding-left: 1.2em; margin: 0; }
.rest { padding-left: 1.2em; }
.feedback, .share, .installer-cta { margin-top: 32px; padding-top: 24px; border-top: 1px solid var(--line); }
.feedback label { display: block; font-weight: 600; margin: 12px 0 6px; }
.feedback select { min-height: 44px; padding: 8px; border-radius: 8px; border: 1.5px solid var(--line); background: var(--surface); color: var(--ink); font: inherit; max-width: 100%; margin-right: 8px; }
.thanks { font-weight: 600; color: var(--ok); }
.share-row { display: flex; flex-wrap: wrap; gap: 8px; margin-bottom: 10px; }
.share-row input { flex: 1 1 240px; min-width: 0; min-height: 44px; padding: 8px 12px; border-radius: 8px; border: 1.5px solid var(--line); background: var(--surface); color: var(--ink); font: .9rem var(--font-body); }
.installer-cta { background: var(--surface); border: 1px solid var(--line); border-radius: var(--radius); padding: 22px; }
.your-answers { margin-top: 24px; }
.your-answers summary { cursor: pointer; font-weight: 600; }
.your-answers dl { display: grid; grid-template-columns: minmax(0, 1fr); gap: 2px; }
.your-answers dt { color: var(--muted); font-size: .9rem; margin-top: 8px; }
.your-answers dd { margin: 0; font-weight: 600; }

/* Article pages (fejl, løsninger, faq, ordbog, udstyr) */
.article { max-width: 72ch; }
.article ul, .article ol { padding-left: 1.3em; }
.article li + li { margin-top: 4px; }
.breadcrumb { font-size: .875rem; color: var(--muted); margin-bottom: 12px; }
.breadcrumb a { color: var(--muted); }
.cta-box { background: var(--surface); border: 1px solid var(--line); border-radius: var(--radius); padding: 20px; margin: 28px 0; }
.card-list { list-style: none; padding: 0; display: grid; grid-template-columns: repeat(auto-fill, minmax(240px, 1fr)); gap: 14px; }
.card-list li { background: var(--surface); border: 1px solid var(--line); border-radius: var(--radius); padding: 16px; }
.card-list a { font-weight: 600; }
.card-list p { margin: 4px 0 0; color: var(--muted); font-size: .92rem; }
.search { width: 100%; min-height: 48px; padding: 10px 14px; border: 1.5px solid var(--line); border-radius: 8px; background: var(--surface); color: var(--ink); font: inherit; margin: 12px 0 20px; }
.faq-item { border-bottom: 1px solid var(--line); padding: 14px 0; }
.faq-item summary { cursor: pointer; font-weight: 600; font-size: 1.05rem; }
.faq-item .tag { font-size: .75rem; text-transform: uppercase; letter-spacing: .06em; color: var(--muted); margin-left: 8px; font-weight: 600; }
.gloss dt { font-family: var(--font-display); font-weight: 650; font-size: 1.15rem; margin-top: 22px; scroll-margin-top: 16px; }
.gloss dt:target { color: var(--heat); }
.gloss dd { margin: 4px 0 0; }
.gloss .alias { color: var(--muted); font-size: .85rem; }
.equip { display: grid; grid-template-columns: repeat(auto-fill, minmax(260px, 1fr)); gap: 18px; list-style: none; padding: 0; }
.equip li { background: var(--surface); border: 1px solid var(--line); border-radius: var(--radius); overflow: hidden; scroll-margin-top: 16px; }
.equip img { display: block; width: 100%; aspect-ratio: 3 / 2; object-fit: cover; background: var(--surface-2); }
.equip .body { padding: 16px; }
.equip ul { padding-left: 1.2em; font-size: .92rem; }
.placeholder-note { font-size: .78rem; color: var(--muted); font-style: italic; }

/* Footer */
.site-footer { border-top: 1px solid var(--line); background: var(--surface); font-size: .9rem; color: var(--muted); }
.site-footer .wrap { display: flex; flex-wrap: wrap; gap: 12px 28px; padding-block: 24px; justify-content: space-between; }
.site-footer nav { display: flex; flex-wrap: wrap; gap: 6px 18px; }
.site-footer a { color: var(--muted); }
