/* Base — Aurora: reset, typografi, layout, komponenter (mobile-first). Egne værdier; intet fra forlægget. */
@font-face { font-family: "Plus Jakarta Sans"; src: url("../fonts/plus-jakarta-sans-latin.woff2") format("woff2"); font-weight: 200 800; font-style: normal; font-display: swap; unicode-range: U+0000-00FF, U+0131, U+0152-0153, U+02BB-02BC, U+02C6, U+02DA, U+02DC, U+2000-206F, U+20AC, U+2122, U+2191, U+2193, U+2212, U+2215, U+FEFF, U+FFFD; }
@font-face { font-family: "Plus Jakarta Sans"; src: url("../fonts/plus-jakarta-sans-latin-ext.woff2") format("woff2"); font-weight: 200 800; font-style: normal; font-display: swap; unicode-range: U+0100-02BA, U+02BD-02C5, U+02C7-02CC, U+02CE-02D7, U+02DD-02FF, U+1E00-1E9F, U+1EF2-1EFF, U+2020, U+20A0-20AB, U+20AD-20C0, U+2113, U+2C60-2C7F, U+A720-A7FF; }
@font-face { font-family: "Sacramento"; src: url("../fonts/sacramento-latin.woff2") format("woff2"); font-weight: 400; font-style: normal; font-display: swap; unicode-range: U+0000-00FF, U+0131, U+0152-0153, U+02BB-02BC, U+02C6, U+02DA, U+02DC, U+2000-206F, U+20AC, U+2122, U+2191, U+2193, U+2212, U+2215, U+FEFF, U+FFFD; }
@font-face { font-family: "Sacramento"; src: url("../fonts/sacramento-latin-ext.woff2") format("woff2"); font-weight: 400; font-style: normal; font-display: swap; unicode-range: U+0100-02BA, U+02BD-02C5, U+02C7-02CC, U+02CE-02D7, U+02DD-02FF, U+1E00-1E9F, U+1EF2-1EFF, U+2020, U+20A0-20AB, U+20AD-20C0, U+2113, U+2C60-2C7F, U+A720-A7FF; }

*, *::before, *::after { box-sizing: border-box; }
:root { -webkit-tap-highlight-color: transparent; }
a, button, summary, label, [role="button"], input, select, textarea { touch-action: manipulation; }
[id] { scroll-margin-top: 84px; }
html { font-size: 15px; -webkit-text-size-adjust: 100%; scroll-behavior: smooth; }
@media (prefers-reduced-motion: reduce) { html { scroll-behavior: auto; } *, *::before, *::after { animation: none !important; transition: none !important; } }
body { margin: 0; position: relative; background: var(--c-bg); color: var(--c-text); font-family: var(--f-body); font-size: var(--fs-1); line-height: var(--lh-body); -webkit-font-smoothing: antialiased; }
img, svg, video { max-width: 100%; height: auto; display: block; }
h1, h2, h3, h4 { font-family: var(--f-display); font-weight: 800; line-height: var(--lh-tight); margin: 0 0 var(--sp-3); letter-spacing: -0.02em; text-wrap: balance; }
h1 { font-size: var(--fs-5); } h2 { font-size: var(--fs-4); } h3 { font-size: var(--fs-2); } h4 { font-size: var(--fs-1); }
@media (min-width: 1024px) { h1 { font-size: var(--fs-6); } h2 { font-size: var(--fs-5); } }
p { margin: 0 0 var(--sp-4); }
a { color: var(--c-primary-2); text-decoration: none; }
a:hover { color: var(--c-primary); text-decoration: underline; text-decoration-thickness: 1px; text-underline-offset: 3px; }
:focus-visible { outline: none; box-shadow: var(--focus); border-radius: var(--radius-pill); }
::selection { background: rgba(242,66,122,.22); }
strong, b { font-weight: 700; }
.visually-hidden { position: absolute !important; width: 1px; height: 1px; overflow: hidden; clip: rect(0 0 0 0); white-space: nowrap; }
.skip-link { position: absolute; left: -999px; top: var(--sp-2); background: var(--c-surface); padding: var(--sp-2) var(--sp-4); border-radius: var(--radius-pill); z-index: 1000; }
.skip-link:focus { left: var(--sp-2); }

/* Typografiske hjælpere */
.script { font-family: var(--f-script); font-weight: 400; color: var(--c-primary); letter-spacing: 0; line-height: 1; }
.eyebrow { font-size: var(--fs-0); font-weight: 700; letter-spacing: .08em; text-transform: uppercase; color: var(--c-text-3); }
.muted { color: var(--c-text-2); }
.small { font-size: var(--fs-0); }
.num { font-variant-numeric: tabular-nums; }
.lead { font-size: var(--fs-2); color: var(--c-text-2); }

/* Layout */
main.container { padding-block: var(--sp-6) var(--sp-8); min-height: 50vh; }
.container { width: 100%; max-width: var(--container); margin-inline: auto; padding-inline: var(--sp-4); }
.grid { display: grid; gap: var(--sp-4); grid-template-columns: repeat(2, minmax(0, 1fr)); }
/* Kolonnespænd gælder kun i 12-kolonnegitteret (≥1024px); nedenunder fylder de bredden */
.span-3, .span-6 { grid-column: 1 / -1; }
@media (min-width: 640px) { .grid { grid-template-columns: repeat(3, minmax(0, 1fr)); } }
@media (min-width: 1024px) { .grid { grid-template-columns: repeat(12, minmax(0, 1fr)); gap: var(--sp-5); } .grid > * { grid-column: span 3; } .span-3 { grid-column: span 3; } .span-6 { grid-column: span 6; } .container { padding-inline: var(--sp-5); } }
/* En formularrække er ikke sidens 12-kolonne-layout: to felter side om side, ét på mobil.
   Reglen hører til her sammen med .grid, så den også gælder på sider uden konto.css. */
.form-grid { grid-template-columns: 1fr; gap: var(--sp-3) var(--sp-4); }
.form-grid > .form-field { min-width: 0; }
@media (min-width: 640px) { .form-grid { grid-template-columns: 1fr 1fr; } .form-grid > * { grid-column: auto; } }
@media (min-width: 1024px) { .form-grid { grid-template-columns: 1fr 1fr; } .form-grid > * { grid-column: auto; } }
.stack > * + * { margin-top: var(--sp-4); }
.cluster { display: flex; flex-wrap: wrap; gap: var(--sp-2); align-items: center; }

/* Aurora-blobs (ren CSS) */
.aurora { position: absolute; inset: 0; pointer-events: none; overflow: hidden; z-index: 0; opacity: var(--blob-opacity); }
.aurora i { position: absolute; display: block; border-radius: 50%; filter: blur(64px); }
.aurora .a { width: 38rem; height: 38rem; left: -10rem; top: -12rem; background: var(--c-coral); animation: aurora-drift 26s ease-in-out infinite alternate; }
.aurora .b { width: 32rem; height: 32rem; left: 40%; top: -16rem; background: var(--c-primary); animation: aurora-drift 30s ease-in-out infinite alternate-reverse; }
.aurora .c { width: 30rem; height: 30rem; right: -8rem; top: -6rem; background: var(--c-orchid); animation: aurora-drift 34s ease-in-out infinite alternate; }
.aurora .d { width: 18rem; height: 18rem; right: 26%; top: 8rem; background: var(--c-online); opacity: .6; animation: aurora-drift 22s ease-in-out infinite alternate-reverse; }
@keyframes aurora-drift { from { transform: translate(0, 0) scale(1); } to { transform: translate(2.5rem, 2rem) scale(1.12); } }
.has-aurora { position: relative; isolation: isolate; }
.has-aurora > :not(.aurora) { position: relative; z-index: 1; }

/* Sidens aurora-bånd (alle sider, fuld bredde, fader ud) */
.page-glow { position: absolute; top: 0; left: 0; right: 0; height: 520px; z-index: 0; pointer-events: none; overflow: hidden; -webkit-mask-image: linear-gradient(#000 30%, transparent); mask-image: linear-gradient(#000 30%, transparent); }
.page-glow .aurora { opacity: var(--blob-opacity); }
.page-glow .aurora .a { left: -8vw; top: -14rem; width: 46vw; height: 46vw; max-width: 44rem; max-height: 44rem; }
.page-glow .aurora .b { left: 32vw; top: -18rem; width: 40vw; height: 40vw; max-width: 38rem; max-height: 38rem; }
.page-glow .aurora .c { right: -10vw; top: -10rem; width: 44vw; height: 44vw; max-width: 42rem; max-height: 42rem; }
.page-glow .aurora .d { right: 22vw; top: 6rem; width: 22vw; height: 22vw; max-width: 20rem; max-height: 20rem; }
body.home .page-glow { height: 760px; -webkit-mask-image: linear-gradient(#000 45%, transparent); mask-image: linear-gradient(#000 45%, transparent); }
body.swipe-page .page-glow, body.admin .page-glow { display: none; }
body.konto .page-glow { height: 320px; opacity: .7; }
main.container, .site-footer { position: relative; } /* ingen z-index: modaler/skuffer inde i main skal kunne ligge over headeren */
main.container { padding-top: var(--sp-7); }

/* Header */
.site-header { background: color-mix(in srgb, var(--c-bg) 62%, transparent); backdrop-filter: blur(12px); -webkit-backdrop-filter: blur(12px); border-bottom: 1px solid var(--c-border); position: sticky; top: 0; z-index: 50; }
.site-header-inner { display: flex; align-items: center; gap: var(--sp-4); min-height: 64px; }
.site-logo { display: inline-flex; align-items: center; gap: var(--sp-2); text-decoration: none; color: var(--c-text); flex: 0 0 auto; }
.site-logo:hover { text-decoration: none; color: var(--c-text); }
.site-mark { width: 32px; height: 32px; border-radius: 10px; background: var(--g-signature); box-shadow: var(--shadow-lift); display: grid; place-items: center; color: #fff; }
.site-mark svg { width: 20px; height: 20px; }
/* Logoet er en udfyldt figur, ikke et stregikon. Uden det her rammer .icon-reglen (fill: none,
   stroke-width: 1.75) den med en streg på to tredjedele af ikonets bredde, og mærket står tomt.
   Stregtykkelsen er figurens egen — den gør stregerne tykke nok til at kunne kendes ved 20 px. */
.icon-figure { fill: currentColor; stroke: currentColor; stroke-width: 0.14; stroke-linejoin: round; stroke-linecap: round; }
.wordmark { font-weight: 800; font-size: 1.3rem; letter-spacing: -.03em; display: inline-flex; align-items: baseline; }
.wordmark i { width: 7px; height: 7px; border-radius: 50%; background: var(--g-signature); display: inline-block; margin-left: 3px; }
.site-search { flex: 1 1 auto; display: none; align-items: center; gap: var(--sp-2); background: var(--c-surface); border: 1px solid var(--c-border); border-radius: var(--radius-pill); padding: 0 var(--sp-3) 0 var(--sp-4); min-width: 0; max-width: 520px; height: 42px; transition: box-shadow var(--dur) var(--ease), border-color var(--dur) var(--ease); }
.site-search:focus-within { border-color: var(--c-primary); box-shadow: var(--focus); }
.site-search .icon { color: var(--c-text-3); flex: 0 0 auto; }
.site-search input { flex: 1; min-width: 0; border: 0; background: transparent; font: inherit; color: var(--c-text); outline: none; height: 100%; }
.site-search input::placeholder { color: var(--c-text-3); }
@media (min-width: 760px) { .site-search { display: flex; } .site-search-link { display: none; } }
.site-nav { margin-left: auto; display: flex; gap: var(--sp-2); align-items: center; min-width: 0; }
.site-nav > a:not(.btn):not(.icon-btn) { text-decoration: none; font-weight: 700; font-size: var(--fs-0); color: var(--c-text-2); padding: var(--sp-2) var(--sp-3); border-radius: var(--radius-pill); }
.site-nav > a:not(.btn):not(.icon-btn):hover { color: var(--c-text); background: var(--c-surface-2); }
.site-nav form.inline { display: inline; margin: 0; }
.site-nav .nav-guides { display: none; } @media (min-width: 1024px) { .site-nav .nav-guides { display: inline-flex; } }
.icon-btn { width: 40px; height: 40px; border-radius: 50%; display: inline-grid; place-items: center; background: var(--c-surface); border: 1px solid var(--c-border); color: var(--c-text); cursor: pointer; position: relative; padding: 0; font: inherit; transition: background var(--dur) var(--ease), transform var(--dur) var(--ease); }
.icon-btn:hover { background: var(--c-surface-2); text-decoration: none; color: var(--c-text); }
.icon-btn .icon { width: 20px; height: 20px; }
.header-cta { display: flex; gap: var(--sp-2); }
.header-cta .btn { min-height: 40px; padding: 0 var(--sp-4); font-size: var(--fs-0); }
@media (max-width: 600px) { .header-cta .btn-ghost { display: none; } }

/* Footer — fuldbredde aurora forneden, CTA-bånd, fem kolonner, trust-liste */
.site-footer { position: relative; margin-top: var(--sp-9); padding: var(--sp-8) 0 var(--sp-6); background: var(--c-surface); border-top: 1px solid var(--c-border); color: var(--c-text-2); font-size: var(--fs-0); overflow: hidden; isolation: isolate; }
.footer-glow { position: absolute; inset: 0; z-index: 0; pointer-events: none; -webkit-mask-image: linear-gradient(transparent, #000 60%); mask-image: linear-gradient(transparent, #000 60%); }
.footer-glow .aurora { opacity: calc(var(--blob-opacity) * .7); }
.footer-glow .aurora .a { left: -10vw; top: auto; bottom: -22rem; width: 44vw; height: 44vw; max-width: 44rem; max-height: 44rem; }
.footer-glow .aurora .c { right: -12vw; top: auto; bottom: -20rem; width: 46vw; height: 46vw; max-width: 46rem; max-height: 46rem; }
.footer-glow .aurora .d { right: 34vw; top: auto; bottom: -8rem; width: 22vw; height: 22vw; max-width: 20rem; max-height: 20rem; }
.site-footer .container { position: relative; z-index: 1; }
.site-footer a { color: inherit; }
.site-footer a:hover { color: var(--c-text); }
.footer-cta { display: flex; flex-wrap: wrap; align-items: center; justify-content: space-between; gap: var(--sp-4); padding: var(--sp-6); border-radius: var(--radius-xl); background: var(--c-bg); border: 1px solid var(--c-border); box-shadow: var(--shadow-2); margin-bottom: var(--sp-8); }
.footer-cta .script { font-size: 2.2rem; display: block; margin-bottom: -2px; }
.footer-cta h2 { font-size: var(--fs-5); margin-bottom: var(--sp-1); color: var(--c-text); }
.footer-cta p { margin: 0; max-width: 52ch; font-size: var(--fs-1); }
.footer-grid { display: grid; gap: var(--sp-6) var(--sp-5); grid-template-columns: 1fr 1fr; }
@media (min-width: 760px) { .footer-grid { grid-template-columns: repeat(3, 1fr); } }
@media (min-width: 1100px) { .footer-grid { grid-template-columns: 1.6fr repeat(4, 1fr); } }
.footer-brand { grid-column: 1 / -1; }
@media (min-width: 1100px) { .footer-brand { grid-column: auto; } }
.footer-brand .site-logo { margin-bottom: var(--sp-3); }
.footer-brand .script { font-size: 1.9rem; display: block; margin-bottom: var(--sp-2); }
.footer-brand p { max-width: 36ch; font-size: var(--fs-1); }
.footer-trust { list-style: none; padding: 0; margin: var(--sp-3) 0 0; display: grid; gap: 8px; }
.footer-trust li { display: flex; align-items: center; gap: 8px; font-weight: 600; color: var(--c-text); }
.footer-trust .icon { color: var(--c-primary); flex: 0 0 auto; }
.site-footer nav ul { list-style: none; padding: 0; margin: 0; display: grid; gap: 8px; }
.site-footer nav .eyebrow { margin-bottom: var(--sp-3); display: block; color: var(--c-text); }
.site-footer nav a { display: inline-block; padding: 2px 0; }
.footer-bottom { margin-top: var(--sp-7); padding-top: var(--sp-4); border-top: 1px solid var(--c-border); display: flex; flex-wrap: wrap; gap: var(--sp-2) var(--sp-5); justify-content: space-between; align-items: center; color: var(--c-text-3); }
.footer-top { font-weight: 700; }

/* Knapper */
.btn { display: inline-flex; align-items: center; justify-content: center; gap: var(--sp-2); padding: 0 1.25rem; border-radius: var(--radius-pill); border: 1px solid transparent; font: inherit; font-weight: 700; cursor: pointer; text-decoration: none; line-height: 1.2; min-height: 46px; white-space: nowrap; transition: transform var(--dur) var(--ease), box-shadow var(--dur) var(--ease), background var(--dur) var(--ease), color var(--dur) var(--ease); }
.btn:hover { text-decoration: none; }
.btn-primary, .btn-accent { background: var(--g-signature); color: var(--c-primary-contrast); box-shadow: var(--shadow-lift); }
.btn-primary:hover, .btn-accent:hover { color: #fff; transform: translateY(-2px); box-shadow: 0 18px 38px -14px rgba(242,66,122,.5); }
.btn-primary:active, .btn-accent:active { transform: translateY(0); }
.btn-ghost { background: var(--c-surface); border-color: var(--c-border); color: var(--c-text); }
.btn-ghost:hover { background: var(--c-surface-2); color: var(--c-text); }
.btn:active { transform: scale(.985); }
.btn-ghost.is-active, .btn-ghost[aria-current="true"], .btn-ghost[aria-pressed="true"] { background: var(--c-text); color: var(--c-bg); border-color: var(--c-text); }
.btn-danger { background: var(--c-danger); color: #fff; }
.btn-danger:hover { color: #fff; background: #B8324B; }
.btn-sm { min-height: 36px; padding: 0 .9rem; font-size: var(--fs-0); }
.btn-lg { min-height: 54px; padding: 0 1.75rem; font-size: var(--fs-2); }
.btn[disabled] { opacity: .55; cursor: not-allowed; transform: none; }
.btn .icon { width: 1.15em; height: 1.15em; }

/* Formularer */
.form-field { display: block; margin-bottom: var(--sp-4); }
/* Et skjult felt skal blive skjult: .form-field sætter display og slår ellers [hidden] ud */
.form-field[hidden] { display: none; }

/* Import af en annonce fra en anden platform — står både i oprettelsen og på oversigten */
.import-choice { border: 0; padding: 0; margin: 0 0 var(--sp-4); }
.import-choice legend { font-weight: 700; font-size: var(--fs-0); padding: 0; margin-bottom: var(--sp-2); }
.choose-inline { display: flex; gap: var(--sp-2); align-items: flex-start; padding: var(--sp-2) 0; cursor: pointer; }
.choose-inline input { margin-top: .3rem; flex: none; width: auto; min-height: 0; }
.import-verdict { margin: var(--sp-2) 0 0; font-weight: 600; }
.import-verdict.is-ok { color: var(--c-ok, #4ade80); }
.import-verdict.is-bad { color: var(--c-danger, #fb7185); }
.import-code strong { font-size: 1.6rem; letter-spacing: .18em; font-variant-numeric: tabular-nums; }
.form-field > label, .form-field > .label { display: block; font-weight: 700; font-size: var(--fs-0); margin-bottom: var(--sp-1); }
.input, select, textarea { width: 100%; font: inherit; padding: 0.6rem 0.9rem; border: 1px solid var(--c-border); border-radius: var(--radius); background: var(--c-surface); color: var(--c-text); min-height: 48px; transition: border-color var(--dur) var(--ease), box-shadow var(--dur) var(--ease); }
select { appearance: none; -webkit-appearance: none; background-image: linear-gradient(45deg, transparent 50%, var(--c-text-3) 50%), linear-gradient(135deg, var(--c-text-3) 50%, transparent 50%); background-position: calc(100% - 18px) 55%, calc(100% - 13px) 55%; background-size: 5px 5px; background-repeat: no-repeat; padding-right: 2.2rem; }
textarea { min-height: 120px; resize: vertical; }
.input:focus, select:focus, textarea:focus { outline: none; box-shadow: var(--focus); border-color: var(--c-primary); border-radius: var(--radius); }
.input::placeholder, textarea::placeholder { color: var(--c-text-3); }
.input-sm { min-height: 36px; padding: 0.3rem 0.7rem; width: auto; border-radius: var(--radius-pill); font-size: var(--fs-0); }
select.input-sm { padding-right: 2rem; }
.field-error { color: var(--c-danger); font-size: var(--fs-0); margin-top: var(--sp-1); font-weight: 600; }
.is-invalid { border-color: var(--c-danger); }
.help { color: var(--c-text-3); font-size: var(--fs-0); margin-top: var(--sp-1); }
.checkbox { display: flex; gap: var(--sp-2); align-items: flex-start; font-weight: 400; cursor: pointer; }
.checkbox input { width: 20px; height: 20px; margin-top: 3px; accent-color: var(--c-primary); flex: 0 0 auto; }
.phone-input { display: flex; gap: var(--sp-2); }
.phone-input select { max-width: 9rem; border-radius: var(--radius-pill); }

/* Fieldsets (stjerner, grupper) */
fieldset { border: 1px solid var(--c-border); border-radius: var(--radius-lg); padding: var(--sp-3) var(--sp-4) var(--sp-4); margin: 0 0 var(--sp-4); min-width: 0; background: var(--c-surface); }
legend { font-weight: 700; font-size: var(--fs-0); padding: 0 6px; color: var(--c-text-2); }
.rating-input { display: inline-flex; gap: 2px; direction: rtl; position: relative; } .rating-input label { cursor: pointer; font-size: 1.8rem; line-height: 1; color: var(--c-border); transition: color var(--dur) var(--ease), transform var(--dur) var(--ease); } .rating-input label:hover { transform: scale(1.15); } .rating-input input { position: absolute; opacity: 0; width: 0; height: 0; } .rating-input label:has(input:checked), .rating-input label:has(input:checked) ~ label, .rating-input label:hover, .rating-input label:hover ~ label { color: var(--c-primary); }
.rating-input label:has(input:focus-visible) { outline: 2px solid var(--c-primary); outline-offset: 2px; border-radius: 4px; }

/* Overflader */
.card { background: var(--c-surface); border: 1px solid var(--c-border); border-radius: var(--radius-lg); box-shadow: var(--shadow-1); }
.card-body { padding: var(--sp-5); }
@media (max-width: 640px) { .card-body { padding: var(--sp-4); } }
.tone-1 { background: var(--t-1); } .tone-2 { background: var(--t-2); } .tone-3 { background: var(--t-3); } .tone-4 { background: var(--t-4); } .tone-5 { background: var(--t-5); }
.tone-block { position: relative; overflow: hidden; border-radius: var(--radius-lg); }
.tone-block::before { content: ""; position: absolute; width: 60%; padding-top: 60%; border-radius: 50%; left: -20%; top: -30%; background: radial-gradient(circle, rgba(255,122,89,.45), transparent 62%); pointer-events: none; }
.tone-block::after { content: ""; position: absolute; width: 55%; padding-top: 55%; border-radius: 50%; right: -18%; bottom: -30%; background: radial-gradient(circle, rgba(178,59,190,.32), transparent 62%); pointer-events: none; }
.tone-2.tone-block::before { background: radial-gradient(circle, rgba(242,66,122,.36), transparent 62%); }
.tone-3.tone-block::after { background: radial-gradient(circle, rgba(255,122,89,.36), transparent 62%); }
.tone-4.tone-block::before { background: radial-gradient(circle, rgba(178,59,190,.36), transparent 62%); }
.tone-5.tone-block::before { background: radial-gradient(circle, rgba(31,191,143,.38), transparent 62%); }
.tone-block > * { position: relative; z-index: 1; }

/* Badges, chips, segment-tabs */
.badge { display: inline-flex; align-items: center; gap: 5px; padding: 3px 10px; border-radius: var(--radius-pill); font-size: var(--fs-0); font-weight: 700; line-height: 1.4; background: var(--c-surface-2); color: var(--c-text-2); text-decoration: none; }
a.badge:hover { background: var(--c-border); color: var(--c-text); text-decoration: none; }
.badge .icon { width: 1em; height: 1em; }
.badge-real { background: var(--g-signature); color: #fff; }
.badge-online { background: var(--t-5); color: var(--c-ink-mint); }
.badge-online::before { content: ""; width: 8px; height: 8px; border-radius: 50%; background: var(--c-online); position: relative; }
.badge-new { background: var(--t-3); color: var(--c-primary-2); }
.badge-tour, .badge-warn { background: var(--t-2); color: var(--c-ink-amber); }
.badge-spons { background: transparent; border: 1px solid var(--c-border); color: var(--c-text-3); font-size: 11px; letter-spacing: .06em; text-transform: uppercase; font-weight: 600; }
.pulse { position: relative; }
.pulse::after { content: ""; position: absolute; inset: -4px; border-radius: 50%; border: 2px solid var(--c-online); animation: pulse 1.6s ease-out infinite; }
@keyframes pulse { from { transform: scale(.6); opacity: .9; } to { transform: scale(1.9); opacity: 0; } }
.live-dot { width: 9px; height: 9px; border-radius: 50%; background: var(--c-online); display: inline-block; position: relative; }
.chip { display: inline-flex; align-items: center; gap: 6px; padding: 6px 14px; border-radius: var(--radius-pill); border: 1px solid var(--c-border); font-size: var(--fs-0); font-weight: 600; background: var(--c-surface); color: var(--c-text); cursor: pointer; white-space: nowrap; text-decoration: none; position: relative; }
.chip:hover { background: var(--c-surface-2); text-decoration: none; color: var(--c-text); }
.chip .icon { width: 16px; height: 16px; color: var(--c-primary); }
.chip:has(input:checked), .chip.is-on { background: linear-gradient(var(--c-surface), var(--c-surface)) padding-box, var(--g-signature) border-box; border: 1.5px solid transparent; }
.chip input { position: absolute; opacity: 0; width: 0; height: 0; }
.chips { display: flex; gap: var(--sp-2); overflow-x: auto; padding: 4px 2px 10px; scrollbar-width: none; -webkit-mask-image: linear-gradient(90deg, #000 90%, transparent); mask-image: linear-gradient(90deg, #000 90%, transparent); }
.chips::-webkit-scrollbar { display: none; }
.chips > * { flex: 0 0 auto; }
.tabs { display: inline-flex; gap: 4px; background: var(--c-surface-2); border-radius: var(--radius-pill); padding: 4px; margin-bottom: var(--sp-4); max-width: 100%; overflow-x: auto; scrollbar-width: none; }
.tabs::-webkit-scrollbar { display: none; }
.tab { text-decoration: none; padding: var(--sp-2) var(--sp-4); border-radius: var(--radius-pill); color: var(--c-text-2); font-weight: 700; font-size: var(--fs-0); white-space: nowrap; border: 0; background: transparent; cursor: pointer; }
.tab:hover { color: var(--c-text); text-decoration: none; }
.tab.is-active { background: var(--g-signature); color: #fff; }
.tab-panel { display: none; } .tab-panel.is-active { display: block; }
html:not(.js) .tab-panel { display: block; }

/* Gnist — partikelburst ved følg/favorit/gave */
.spark { position: relative; }
.spark::before, .spark::after { content: ""; position: absolute; inset: 0; pointer-events: none; border-radius: inherit; opacity: 0; }
.spark.is-sparking::before { background-image: radial-gradient(circle, var(--c-coral) 20%, transparent 22%), radial-gradient(circle, var(--c-primary) 20%, transparent 22%), radial-gradient(circle, var(--c-orchid) 20%, transparent 22%), radial-gradient(circle, var(--c-coral) 20%, transparent 22%), radial-gradient(circle, var(--c-primary) 20%, transparent 22%), radial-gradient(circle, var(--c-orchid) 20%, transparent 22%); background-size: 10% 10%, 12% 12%, 8% 8%, 10% 10%, 12% 12%, 8% 8%; background-repeat: no-repeat; animation: spark-up .7s ease-out forwards; }
.spark.is-sparking::after { background-image: radial-gradient(circle, var(--c-primary) 20%, transparent 22%), radial-gradient(circle, var(--c-orchid) 20%, transparent 22%), radial-gradient(circle, var(--c-coral) 20%, transparent 22%), radial-gradient(circle, var(--c-primary) 20%, transparent 22%); background-size: 10% 10%, 12% 12%, 8% 8%, 10% 10%; background-repeat: no-repeat; animation: spark-down .7s ease-out forwards; }
@keyframes spark-up { 0% { opacity: 1; background-position: 5% 90%, 25% 90%, 45% 90%, 60% 90%, 78% 90%, 95% 90%; } 60% { opacity: 1; } 100% { opacity: 0; background-position: 0% -40%, 22% -60%, 42% -50%, 62% -70%, 80% -45%, 100% -60%; } }
@keyframes spark-down { 0% { opacity: 1; background-position: 10% 10%, 35% 10%, 65% 10%, 90% 10%; } 60% { opacity: 1; } 100% { opacity: 0; background-position: 0% 150%, 30% 170%, 70% 160%, 100% 150%; } }
.spark.is-sparking { animation: spark-pop .35s var(--ease); }
@keyframes spark-pop { 50% { transform: scale(1.08); } }

/* Flash / toast */
.flash { padding: var(--sp-3) var(--sp-4); border-radius: var(--radius); margin-bottom: var(--sp-4); border: 1px solid var(--c-border); background: var(--c-surface); font-weight: 600; display: flex; gap: var(--sp-3); align-items: center; flex-wrap: wrap; }
.flash-success { border-color: transparent; background: var(--t-5); color: var(--c-ink-mint); }
.flash-error { border-color: transparent; background: var(--t-3); color: var(--c-danger); }
.flash-info { border-color: transparent; background: var(--t-2); color: var(--c-ink-amber); }
.flash .btn { min-height: 36px; }

/* Modal (SSR, uden JS-krav) */
.modal { position: fixed; inset: 0; z-index: 900; display: grid; grid-template-columns: minmax(0, 100%); place-items: center; padding: var(--sp-4); background: var(--c-overlay); overscroll-behavior: contain; overflow-y: auto; }
.modal[hidden] { display: none; }
.modal .card { width: 100%; min-width: 0; max-width: 440px; border-radius: var(--radius-xl); position: relative; overflow: hidden; box-shadow: var(--shadow-lift); }
.modal .card-body { padding: var(--sp-6); }
.modal .card .aurora { opacity: .35; }
.modal .close { position: absolute; top: var(--sp-3); right: var(--sp-3); z-index: 2; }
.modal .script { font-size: 2rem; display: block; margin-bottom: var(--sp-1); }
body.modal-open { overflow: hidden; }

/* Age-gate (SSR; indholdet står bagved i DOM'en) */
.age-gate { position: fixed; inset: 0; background: #17111A; z-index: 1000; display: grid; grid-template-columns: minmax(0, 100%); place-items: center; padding: var(--sp-4); isolation: isolate; overflow-y: auto; }
.age-gate .aurora { opacity: .5; }
.age-gate .card { max-width: 480px; width: 100%; min-width: 0; border-radius: var(--radius-xl); position: relative; z-index: 1; box-shadow: var(--shadow-lift); }
.age-gate .card-body { padding: var(--sp-6); }
.age-gate .script { font-size: 2.2rem; display: block; margin-bottom: var(--sp-1); }
.age-gate h2 { font-size: var(--fs-4); }
body.has-age-gate { overflow: hidden; }

/* Fejlsider, auth */
.error-page { text-align: center; padding: var(--sp-8) 0; }
.error-page h1 { font-size: var(--fs-6); }
.error-page .script { font-size: 2.4rem; display: block; }
.auth-card { max-width: 460px; margin: var(--sp-6) auto; border-radius: var(--radius-xl); position: relative; overflow: hidden; }
.auth-card .card-body { padding: var(--sp-6); position: relative; }
.auth-card .aurora { opacity: .4; }
/* Forskriften har lange opstreger. line-height: 1 fra .script klipper dem mod kortets overkant
   — det gælder login, oprettelse, klinik og kontakt, så det rettes ét sted. */
.auth-card .script { font-size: 2rem; display: block; margin-bottom: 2px; line-height: 1.35; }
.auth-card h1 { font-size: var(--fs-4); }
.auth-card .btn-primary { width: 100%; }
.auth-choose { display: grid; gap: var(--sp-4); grid-template-columns: 1fr; max-width: 860px; margin: var(--sp-6) auto; }
@media (min-width: 640px) { .auth-choose { grid-template-columns: 1fr 1fr; } }
.choose-card { display: block; text-decoration: none; color: inherit; border-radius: var(--radius-xl); padding: var(--sp-6); position: relative; overflow: hidden; border: 1px solid var(--c-border); transition: transform var(--dur) var(--ease), box-shadow var(--dur) var(--ease); }
.choose-card:hover { transform: translateY(-3px); box-shadow: var(--shadow-lift); text-decoration: none; color: inherit; }
.choose-card .script { font-size: 2rem; display: block; }
.choose-card h2 { margin-bottom: var(--sp-2); }
.choose-card ul { margin: 0 0 var(--sp-4); padding-left: 1.1rem; color: var(--c-text-2); }
.coupon-toggle { font-size: var(--fs-0); }
.coupon-found { border-radius: var(--radius); padding: var(--sp-3) var(--sp-4); background: var(--t-5); color: var(--c-ink-mint); font-weight: 700; font-size: var(--fs-0); margin-bottom: var(--sp-4); }
.legal-line { font-size: var(--fs-0); color: var(--c-text-3); text-align: center; margin-top: var(--sp-4); }

/* Medie-pladsholder (tonet flade + blob + forbogstav i skriftfont) */
.media-placeholder { display: grid; place-items: center; width: 100%; height: 100%; color: var(--c-text); text-align: center; padding: var(--sp-3); position: relative; overflow: hidden; }
.media-placeholder .initial { font-family: var(--f-script); font-size: clamp(3.5rem, 10vw, 6rem); line-height: 1; opacity: .55; color: var(--c-text); }
.media-placeholder .small { position: absolute; bottom: var(--sp-2); left: 0; right: 0; color: var(--c-text-2); opacity: .7; }

/* FAQ (landing + guides) */
.faq-item { border-top: 1px solid var(--c-border); padding: var(--sp-3) 0; }
.faq-item summary { cursor: pointer; font-weight: 700; list-style: none; display: flex; justify-content: space-between; gap: var(--sp-3); }
.faq-item summary::-webkit-details-marker { display: none; }
.faq-item summary::after { content: "+"; color: var(--c-primary); font-weight: 800; }
.faq-item[open] summary::after { content: "−"; }
.faq-item p { margin: var(--sp-2) 0 0; color: var(--c-text-2); }

/* Ikoner */
.icon { width: 1.25em; height: 1.25em; fill: none; stroke: currentColor; stroke-width: 1.75; stroke-linecap: round; stroke-linejoin: round; vertical-align: -0.25em; }

/* Sektioner */
.section-head { display: flex; justify-content: space-between; align-items: baseline; gap: var(--sp-3); margin-bottom: var(--sp-3); }
.section-head .script { font-size: 1.6rem; margin-right: var(--sp-2); }
.empty-state { text-align: center; padding: var(--sp-7) var(--sp-4); }
.empty-state .script { font-size: 2.2rem; display: block; margin-bottom: var(--sp-2); }
.prose { max-width: 68ch; }
.prose h2, .prose h3 { margin-top: var(--sp-5); }
.prose p, .prose li { color: var(--c-text-2); }
.breadcrumb { margin-bottom: var(--sp-3); }
.breadcrumb a { color: var(--c-text-2); }
.inline { display: inline; }
.modal .card-body, .auth-card .card-body, .age-gate .card-body { position: relative; z-index: 1; }
.chips.is-end { -webkit-mask-image: none; mask-image: none; }
/* Auth: valgkort, kodefelt, intro */
.auth-intro { text-align: center; max-width: 60ch; margin: var(--sp-5) auto 0; }
.auth-intro .script { font-size: 2.4rem; display: block; }
button.choose-card { font: inherit; text-align: left; cursor: pointer; background: var(--c-surface); color: inherit; }
.choose-card .btn { pointer-events: none; }
.code-input { font-size: var(--fs-4); letter-spacing: .35em; text-align: center; font-variant-numeric: tabular-nums; font-weight: 700; }
.coupon-toggle summary { list-style: none; cursor: pointer; font-size: var(--fs-0); }
.coupon-toggle summary::-webkit-details-marker { display: none; }
.coupon-toggle summary a { pointer-events: none; }
/* "Din profil"-modal */
.profile-panel .card { max-width: 520px; }
.panel-top { display: flex; gap: var(--sp-4); align-items: center; margin-bottom: var(--sp-4); }
.panel-top .script { font-size: 1.8rem; display: block; margin-bottom: -4px; }
.panel-top h2 { margin-bottom: var(--sp-1); font-size: var(--fs-3); }
.panel-top p { margin: 0; }
.ring { --pct: 0; width: 92px; height: 92px; flex: 0 0 auto; border-radius: 50%; background: conic-gradient(var(--c-primary) calc(var(--pct) * 1%), var(--c-surface-2) 0); display: grid; place-items: center; position: relative; }
.ring::after { content: ""; position: absolute; inset: 8px; border-radius: 50%; background: var(--c-surface); }
.ring b { position: relative; z-index: 1; font-size: var(--fs-2); font-weight: 800; }
.panel-shortcuts { display: grid; grid-template-columns: 1fr 1fr; gap: var(--sp-2); margin-bottom: var(--sp-4); }
.panel-shortcuts a { display: flex; align-items: center; gap: var(--sp-2); border: 1px solid var(--c-border); border-radius: var(--radius); padding: var(--sp-3); font-weight: 700; font-size: var(--fs-0); color: var(--c-text); text-decoration: none; }
.panel-shortcuts a:hover { background: var(--c-surface-2); text-decoration: none; }
.panel-shortcuts a i { width: 8px; height: 8px; border-radius: 50%; background: var(--g-signature); flex: 0 0 auto; }
.panel-foot { justify-content: space-between; }
.panel-foot .toggle { margin: 0; }
/* Finjusteringer */
.phone-input { flex-wrap: nowrap; }
.phone-input .input[data-contact], .phone-input input { width: auto; flex: 1 1 140px; min-width: 0; }
.auth-card .aurora, .modal .card .aurora { opacity: .28; }
.auth-card .aurora i, .modal .card .aurora i { filter: blur(48px); }
.auth-card .aurora .a, .modal .card .aurora .a { width: 18rem; height: 18rem; left: -7rem; top: -9rem; }
.auth-card .aurora .b, .modal .card .aurora .b { width: 16rem; height: 16rem; left: 40%; top: -10rem; }
.auth-card .aurora .c, .modal .card .aurora .c { width: 16rem; height: 16rem; right: -7rem; top: auto; bottom: -9rem; }
.auth-card .aurora .d, .modal .card .aurora .d { width: 10rem; height: 10rem; right: 20%; top: auto; bottom: -4rem; }
/* Brede tabeller scroller i egen container; hovedkolonner må aldrig tvinge sidebredden op */
.konto-main, .medlem-main, .medlem-right, .admin-shell > section, .search-main { min-width: 0; }
.konto-main table, .medlem-main table, .admin-shell table { display: block; overflow-x: auto; max-width: 100%; }

/* ===== UX-lag: reveal, billed-fade, header-tilstand, til-toppen, toasts, knap-loading ===== */
html.js .reveal { opacity: 0; transform: translateY(10px); transition: opacity .4s var(--ease), transform .4s var(--ease); transition-delay: var(--reveal-delay, 0ms); }
html.js .reveal.is-in { opacity: 1; transform: none; }
@media (prefers-reduced-motion: reduce) { html.js .reveal { opacity: 1; transform: none; transition: none; } }
html.js .ad-card-media img, html.js .profile-hero img, html.js .profile-thumb img, html.js .clinic-cover, html.js .clinic-thumb img, html.js .post-image { opacity: 0; transition: opacity .45s var(--ease); }
html.js .ad-card-media img.is-loaded, html.js .profile-hero img.is-loaded, html.js .profile-thumb img.is-loaded, html.js .clinic-cover.is-loaded, html.js .clinic-thumb img.is-loaded, html.js .post-image.is-loaded { opacity: 1; }
.site-header { transition: box-shadow var(--dur) var(--ease), background var(--dur) var(--ease); }
.site-header.is-scrolled { background: color-mix(in srgb, var(--c-bg) 88%, transparent); box-shadow: 0 8px 24px -18px rgba(35,22,31,.35); }
.to-top { position: fixed; right: var(--sp-4); bottom: calc(var(--sp-4) + env(safe-area-inset-bottom)); z-index: 70; width: 46px; height: 46px; border-radius: 50%; border: 1px solid var(--c-border); background: var(--c-surface); color: var(--c-text); box-shadow: var(--shadow-2); cursor: pointer; opacity: 0; transform: translateY(12px); pointer-events: none; transition: opacity var(--dur) var(--ease), transform var(--dur) var(--ease); display: grid; place-items: center; }
.to-top .icon { transform: rotate(-90deg); width: 20px; height: 20px; }
.to-top.is-visible { opacity: 1; transform: none; pointer-events: auto; }
.to-top:hover { background: var(--c-surface-2); }
.profile-page .to-top { bottom: calc(84px + env(safe-area-inset-bottom)); }
@media (min-width: 1024px) { .profile-page .to-top { bottom: calc(var(--sp-4) + env(safe-area-inset-bottom)); } }
.flash { position: relative; padding-right: 44px; animation: flash-in .3s var(--ease); }
.flash-close { position: absolute; right: 8px; top: 50%; transform: translateY(-50%); width: 30px; height: 30px; border-radius: 50%; border: 0; background: transparent; color: inherit; font-size: 1.3rem; cursor: pointer; opacity: .7; }
.flash-close:hover { opacity: 1; background: rgba(0,0,0,.06); }
.flash.is-leaving { opacity: 0; transform: translateY(-6px); transition: opacity .25s var(--ease), transform .25s var(--ease); }
@keyframes flash-in { from { opacity: 0; transform: translateY(-6px); } }
main.container > .flash { max-width: 760px; margin-inline: auto; }
.btn.is-loading { position: relative; color: transparent !important; pointer-events: none; }
.btn.is-loading::after { content: ""; position: absolute; width: 18px; height: 18px; border-radius: 50%; border: 2px solid currentColor; border-right-color: transparent; color: #fff; animation: spin .7s linear infinite; }
.btn-ghost.is-loading::after, .btn-outline.is-loading::after { color: var(--c-text); }
@keyframes spin { to { transform: rotate(360deg); } }
html:not(.kbd) :focus:not(:focus-visible) { box-shadow: none; }
/* Avatar (konto + medlem + chat) */
.konto-avatar { width: 72px; height: 72px; border-radius: 50%; background: var(--g-signature); color: #fff; display: grid; place-items: center; font-family: var(--f-script); font-size: 2.4rem; margin: 0 auto var(--sp-2); box-shadow: var(--shadow-lift); }
.avatar-sm { width: 40px; height: 40px; font-size: 1.4rem; margin: 0; box-shadow: none; flex: 0 0 auto; }

/* ===== Lightbox ===== */
.lightbox { position: fixed; inset: 0; z-index: 950; background: rgba(23,17,26,.94); display: grid; place-items: center; padding: var(--sp-4); animation: lb-in .2s var(--ease); }
.lightbox[hidden] { display: none; }
@keyframes lb-in { from { opacity: 0; } }
.lb-figure { margin: 0; max-width: min(100%, 1200px); max-height: 100%; display: grid; gap: var(--sp-3); justify-items: center; }
.lb-img { max-width: 100%; max-height: min(84vh, 1400px); width: auto; height: auto; border-radius: var(--radius-lg); box-shadow: 0 30px 80px -20px rgba(0,0,0,.7); opacity: 0; transform: scale(.98); transition: opacity .25s var(--ease), transform .25s var(--ease); object-fit: contain; }
.lb-img.is-ready { opacity: 1; transform: none; }
.lb-cap { color: rgba(255,255,255,.8); font-size: var(--fs-0); display: flex; gap: var(--sp-3); align-items: center; }
.lb-counter { font-weight: 800; color: #fff; }
.lightbox .icon-btn { position: absolute; background: rgba(255,255,255,.12); border-color: rgba(255,255,255,.25); color: #fff; width: 48px; height: 48px; }
.lightbox .icon-btn:hover { background: rgba(255,255,255,.22); }
.lb-close { top: var(--sp-4); right: var(--sp-4); }
.lb-nav { top: 50%; transform: translateY(-50%); font-size: 2rem; line-height: 1; }
.lb-prev { left: var(--sp-4); } .lb-next { right: var(--sp-4); }
@media (max-width: 640px) { .lb-nav { top: auto; bottom: var(--sp-5); transform: none; } .lb-prev { left: 28%; } .lb-next { right: 28%; } }
.profile-hero a, .profile-thumb, .clinic-thumb { cursor: zoom-in; }
.profile-thumb { position: relative; }
.profile-thumb .more { position: absolute; inset: 0; display: grid; place-items: center; background: rgba(23,17,26,.55); color: #fff; font-weight: 800; font-size: var(--fs-2); }
/* Header på små skærme (logget ind): kun ikoner + primær knap; log ud ligger i footerens Konto-kolonne */
@media (max-width: 600px) { .site-nav form.inline:not(.theme-form) { display: none; } .site-nav .btn-sm { padding: 0 var(--sp-3); } .site-header-inner { gap: var(--sp-2); } }
/* Navnet skal stå der: mærket alene fortæller ikke, hvor man er. Søgefeltet er på mobil
   erstattet af et ikon, så der er plads — teksten trækkes bare lidt sammen. */
@media (max-width: 400px) { .wordmark { font-size: 1.1rem; } .site-mark { width: 28px; height: 28px; border-radius: 9px; } .site-mark svg { width: 17px; height: 17px; } }
@media (max-width: 330px) { .wordmark { display: none; } }
.link-btn { background: none; border: 0; padding: 2px 0; font: inherit; color: inherit; cursor: pointer; }
.link-btn:hover { color: var(--c-text); text-decoration: underline; }

/* ── Sprog & tema (feature 003) ─────────────────────────────────────────── */
.header-tools { display: inline-flex; align-items: center; gap: 4px; }
.lang-switch { display: inline-flex; align-items: center; justify-content: center; min-width: 38px; height: 38px; padding: 0 8px; border-radius: var(--radius-pill); font-size: .78rem; font-weight: 800; letter-spacing: .06em; color: var(--c-text-2); text-decoration: none; border: 1px solid transparent; transition: background var(--dur) var(--ease), color var(--dur) var(--ease); }
.lang-switch:hover, .lang-switch:focus-visible { background: var(--c-surface-2); color: var(--c-text); }
.theme-toggle .icon { transition: transform .35s var(--ease); }
.theme-toggle:hover .icon { transform: rotate(20deg); }
.lang-banner { background: var(--t-4); border-bottom: 1px solid var(--c-border); }
.lang-banner-inner { display: flex; flex-wrap: wrap; align-items: center; gap: var(--sp-3); padding-top: var(--sp-2); padding-bottom: var(--sp-2); font-size: .9rem; }
.lang-banner-inner > span { display: inline-flex; align-items: center; gap: 8px; flex: 1 1 auto; }
.lang-banner .icon { width: 18px; height: 18px; color: var(--c-orchid); }
@media (max-width: 720px) { .header-tools { gap: 0; } .lang-switch { min-width: 34px; padding: 0 4px; } }
/* Under 600px er headeren for smal til begge: sproget flyttes til footeren, tema bliver i headeren */
@media (max-width: 600px) { .header-tools .lang-switch { display: none; } }
.footer-langs { display: inline-flex; align-items: center; gap: var(--sp-2); }
.footer-langs a, .footer-langs span { font-weight: 700; }
.footer-langs a { color: var(--c-text-2); text-decoration: none; border-bottom: 1px solid transparent; }
.footer-langs a:hover, .footer-langs a:focus-visible { color: var(--c-text); border-bottom-color: currentColor; }
.footer-langs .is-current { color: var(--c-primary); }

/* Mørkt tema: kort-/kortfarver der ellers er hvide */
:root[data-theme="dark"] .leaflet-tile, :root[data-theme="dark"] .leaflet-container { filter: brightness(.72) contrast(1.05) saturate(.7); }
:root[data-theme="dark"] .leaflet-popup-content-wrapper, :root[data-theme="dark"] .leaflet-popup-tip { background: var(--c-surface); color: var(--c-text); }
:root[data-theme="dark"] img.avatar, :root[data-theme="dark"] .logo-img { filter: brightness(.94); }
@media (prefers-color-scheme: dark) {
  :root:not([data-theme="light"]) .leaflet-tile, :root:not([data-theme="light"]) .leaflet-container { filter: brightness(.72) contrast(1.05) saturate(.7); }
  :root:not([data-theme="light"]) .leaflet-popup-content-wrapper, :root:not([data-theme="light"]) .leaflet-popup-tip { background: var(--c-surface); color: var(--c-text); }
}

/* ── Præferencepanel (tema, sprog, diskret tilstand) ─────────────────────── */
.prefs { position: relative; }
.prefs > summary { list-style: none; cursor: pointer; }
.prefs > summary::-webkit-details-marker { display: none; }
.prefs[open] > summary { background: var(--c-surface-2); color: var(--c-text); }
.prefs .panel { position: absolute; right: 0; top: calc(100% + var(--sp-2)); width: min(300px, calc(100vw - var(--sp-5))); z-index: 60; box-shadow: var(--shadow-2); }
/* På mobil sidder knapperne inde midt i headeren, så et panel hængt op på deres højrekant
   løber ud over skærmen til venstre. Der lægger panelerne sig i stedet under headeren i
   fuld bredde — og kan rulles, hvis indholdet er højere end skærmen. */
@media (max-width: 640px) {
  .prefs .panel {
    position: fixed; left: var(--sp-3); right: var(--sp-3); top: 72px; width: auto;
    max-height: calc(100dvh - 88px); overflow-y: auto; overscroll-behavior: contain;
  }
}
.prefs-group { display: grid; gap: 6px; }
.prefs-label { font-size: var(--fs-0); font-weight: 800; letter-spacing: .06em; text-transform: uppercase; color: var(--c-text-3); }
/* Guides, Log ind og Log ud kan ikke være i headeren på en telefon — uden dem her i panelet
   kunne man slet ikke komme til dem. Hvert punkt dukker op præcis dér, hvor headeren slipper det. */
.prefs-group.prefs-nav { display: none; }
.prefs-nav a, .prefs-nav button { display: block; width: 100%; padding: 6px 0; border: 0; background: none; font: inherit; font-weight: 700; color: var(--c-text); text-align: left; text-decoration: none; cursor: pointer; }
.prefs-nav a:hover, .prefs-nav button:hover { color: var(--c-brand); }
@media (max-width: 1023px) { .prefs-group.prefs-nav { display: grid; } .prefs-nav .prefs-account { display: none; } }
@media (max-width: 600px) { .prefs-nav .prefs-account { display: block; } }
.segmented { display: grid; grid-auto-flow: column; grid-auto-columns: 1fr; gap: 4px; padding: 4px; background: var(--c-surface-2); border-radius: var(--radius-pill); }
.segmented button, .segmented a { display: flex; flex-direction: column; align-items: center; justify-content: center; gap: 2px; padding: var(--sp-2) 4px; border: 0; background: transparent; border-radius: var(--radius-pill); font: inherit; font-size: var(--fs-0); font-weight: 700; color: var(--c-text-2); text-decoration: none; cursor: pointer; transition: background var(--dur) var(--ease), color var(--dur) var(--ease); }
.segmented button .icon, .segmented a .icon { width: 17px; height: 17px; }
.segmented button:hover, .segmented a:hover { color: var(--c-text); }
.segmented .is-active { background: var(--c-surface); color: var(--c-text); box-shadow: var(--shadow-1); }
.prefs-switch { margin: 0; }
.prefs-switch .switch { display: flex; align-items: center; gap: var(--sp-3); width: 100%; padding: var(--sp-3); border: 1px solid var(--c-border); border-radius: var(--radius); background: transparent; color: var(--c-text); font: inherit; text-align: left; cursor: pointer; }
.prefs-switch .switch:hover { border-color: var(--c-primary); }
.prefs-switch .switch .icon { width: 20px; height: 20px; color: var(--c-text-2); flex: none; }
.prefs-switch-text { display: grid; gap: 1px; flex: 1 1 auto; min-width: 0; }
.prefs-switch-text small { color: var(--c-text-3); font-size: var(--fs-0); line-height: 1.35; }
.switch-track { flex: none; width: 38px; height: 22px; border-radius: var(--radius-pill); background: var(--c-border); position: relative; transition: background var(--dur) var(--ease); }
.switch-track::after { content: ""; position: absolute; top: 3px; left: 3px; width: 16px; height: 16px; border-radius: 50%; background: var(--c-surface); box-shadow: var(--shadow-1); transition: transform var(--dur) var(--ease); }
.switch.is-on .switch-track { background: var(--c-primary); }
.switch.is-on .switch-track::after { transform: translateX(16px); }
.switch.is-on .icon { color: var(--c-primary); }

/* Diskret tilstand: billeder sløres, indtil man peger på dem */
html.is-discreet .ad-card-media img, html.is-discreet .ad-card-media video,
html.is-discreet .profile-photo, html.is-discreet .profile-thumb img, html.is-discreet .profile-media video,
html.is-discreet .post-image, html.is-discreet .post-avatar,
html.is-discreet .clinic-cover, html.is-discreet .clinic-thumb,
html.is-discreet .story-media img, html.is-discreet .story-media video,
html.is-discreet .media-tile img { filter: blur(18px); transition: filter .2s var(--ease); }
html.is-discreet .ad-card:hover .ad-card-media img, html.is-discreet .ad-card:focus-within .ad-card-media img,
html.is-discreet .profile-media:hover .profile-photo, html.is-discreet .profile-media:hover .profile-thumb img,
html.is-discreet .feed-post:hover .post-image, html.is-discreet .media-tile:hover img,
html.is-discreet .clinic-hero:hover .clinic-cover { filter: none; }
@media (prefers-reduced-motion: reduce) { html.is-discreet [class] { transition: none; } }

/* ── Prisindeks (D4) ─────────────────────────────────────────────────────── */
.price-index { margin-top: var(--sp-5); }
.price-index-title { margin: 0 0 var(--sp-1); font-size: var(--fs-3); }
.price-index-range { margin: 0; font-size: var(--fs-4); font-weight: 800; font-variant-numeric: tabular-nums; background: var(--g-signature); -webkit-background-clip: text; background-clip: text; color: transparent; }
.price-histogram { display: grid; grid-auto-flow: column; grid-auto-columns: 1fr; gap: 6px; margin: var(--sp-4) 0 var(--sp-3); padding: 0; list-style: none; }
/* Søjlehøjden sættes i px af skabelonen: procenthøjder i et gitterområde er upålidelige, når elementet ikke strækkes */
.price-histogram li { display: grid; grid-template-rows: 84px auto; align-items: end; justify-items: center; gap: 4px; min-width: 0; }
.price-histogram span { display: block; width: 100%; align-self: end; border-radius: var(--radius-sm) var(--radius-sm) 2px 2px; background: var(--c-surface-2); border: 1px solid var(--c-border); border-bottom: 0; }
.price-histogram li.is-median span { background: var(--g-signature); border-color: transparent; }
.price-histogram li.is-median small { color: var(--c-text); font-weight: 700; }
.price-histogram small { font-size: 11px; color: var(--c-text-3); font-variant-numeric: tabular-nums; white-space: nowrap; }
.ad-card-price { margin: 4px 0 0; font-weight: 700; color: var(--c-text-2); font-variant-numeric: tabular-nums; }
.badge-confirmed { background: var(--t-5); color: var(--c-ink-mint); }
.badge-confirmed .icon { width: 14px; height: 14px; }
.visit-code-field .input { max-width: 180px; font-family: ui-monospace, SFMono-Regular, Menlo, monospace; letter-spacing: .18em; }
.push-card { margin: var(--sp-4) 0; }
.push-card[hidden] { display: none; }

/* ── Panikskærm (T3) ─────────────────────────────────────────────────────── */
html.is-panic { overflow: hidden; }
/* Ingen rest af siden må kunne skimtes — heller ikke baggrunden bag den faste skærm */
html.is-panic, html.is-panic body { background: #f4f6f9; }
html.is-panic body > *:not(.panic) { visibility: hidden; }
.panic { position: fixed; inset: 0; z-index: 9999; display: grid; place-items: center; background: #f4f6f9; color: #1d2430; font-family: system-ui, -apple-system, "Segoe UI", sans-serif; }
.panic[hidden] { display: none; }
.panic-inner { width: min(420px, 88vw); background: #fff; border: 1px solid #e2e6ee; border-radius: 14px; padding: 28px; box-shadow: 0 10px 30px -18px rgba(29,36,48,.45); text-align: center; }
.panic-city { margin: 0; font-size: 15px; color: #5c6675; letter-spacing: .02em; }
.panic-temp { margin: 4px 0 0; font-size: 64px; font-weight: 300; line-height: 1; font-variant-numeric: tabular-nums; }
.panic-desc { margin: 6px 0 20px; font-size: 14px; color: #5c6675; }
.panic-days { display: flex; justify-content: space-between; gap: 8px; margin: 0 0 22px; padding: 16px 0 0; list-style: none; border-top: 1px solid #eef1f6; }
.panic-days li { display: grid; gap: 4px; font-size: 13px; color: #5c6675; }
.panic-days strong { color: #1d2430; font-weight: 600; font-variant-numeric: tabular-nums; }
.panic .btn { color: #5c6675; border-color: #e2e6ee; background: #fff; }

/* ── Bookingforespørgsler (D2) ───────────────────────────────────────────── */
.booking-card { margin-top: var(--sp-4); }
.radio-chip { display: inline-flex; align-items: center; gap: 8px; padding: 8px 14px; border: 1px solid var(--c-border); border-radius: var(--radius-pill); cursor: pointer; }
.radio-chip:has(input:checked) { border-color: var(--c-primary); background: var(--t-3); }
.booking-list { list-style: none; margin: var(--sp-4) 0 0; padding: 0; display: grid; gap: var(--sp-3); }
.booking-head { display: flex; align-items: center; justify-content: space-between; gap: var(--sp-3); flex-wrap: wrap; }
.booking-message { margin: var(--sp-2) 0 0; padding-left: var(--sp-3); border-left: 3px solid var(--c-border); color: var(--c-text-2); }
.booking-actions { display: grid; gap: var(--sp-2); margin-top: var(--sp-3); }
.badge-warn { background: var(--t-2); color: var(--c-ink-amber); }
.badge-muted { background: var(--c-surface-2); color: var(--c-text-3); }
.booking-accepted { border-color: var(--c-online); }

/* ── Søgeforslag (D3) ────────────────────────────────────────────────────── */
.site-search { position: relative; }
.suggest-list { position: absolute; left: 0; right: 0; top: calc(100% + 6px); z-index: 70; margin: 0; padding: 6px; list-style: none; background: var(--c-surface); border: 1px solid var(--c-border); border-radius: var(--radius); box-shadow: var(--shadow-2); max-height: 60vh; overflow-y: auto; }
.suggest-list[hidden] { display: none; }
.suggest-list a { display: flex; align-items: baseline; gap: var(--sp-2); padding: 8px 10px; border-radius: var(--radius-sm); text-decoration: none; color: var(--c-text); }
.suggest-list small { color: var(--c-text-3); font-size: var(--fs-0); }
.suggest-list li.is-active a, .suggest-list a:hover { background: var(--c-surface-2); }
.notes-card { margin-top: var(--sp-4); }
.visit-log { list-style: none; margin: 0; padding: 0; display: grid; gap: 6px; }
.visit-log li { display: flex; align-items: center; gap: var(--sp-3); color: var(--c-text-2); }
.follow-place { margin: var(--sp-3) 0; }
.follow-place .icon { width: 16px; height: 16px; }

/* ── Point ───────────────────────────────────────────────────────────────── */
.points-balance { margin: 0; display: flex; align-items: baseline; gap: 8px; color: var(--c-text-2); }
.points-figure { font-size: var(--fs-6); font-weight: 800; line-height: 1; background: var(--g-signature); -webkit-background-clip: text; background-clip: text; color: transparent; font-variant-numeric: tabular-nums; }
.gift-price-list { list-style: none; margin: 0; padding: 0; display: grid; gap: var(--sp-2); }
.gift-price-list li { display: flex; align-items: center; gap: var(--sp-3); padding: var(--sp-2) var(--sp-3); border: 1px solid var(--c-border); border-radius: var(--radius); }
.gift-price-list strong { margin-left: auto; font-variant-numeric: tabular-nums; }
.points-log { list-style: none; margin: 0; padding: 0; display: grid; gap: 6px; }
.points-log li { display: flex; align-items: center; gap: var(--sp-3); flex-wrap: wrap; }
.points-delta { min-width: 48px; font-weight: 800; font-variant-numeric: tabular-nums; }
.points-delta.is-plus { color: var(--c-ink-mint); }
.points-delta.is-minus { color: var(--c-text-3); }

/* Klinikhenvendelsens profilvælger: forslag under feltet, valgte som chips under igen */
.ad-picker-results { list-style: none; margin: var(--sp-2) 0 0; padding: 0; display: grid; gap: 2px; }
/* display: grid slår [hidden] — uden det her bliver forslagene stående, når man har valgt */
.ad-picker-results[hidden] { display: none; }
.ad-picker-chosen { list-style: none; margin: var(--sp-2) 0 0; padding: 0; }
.ad-picker-chosen .chip { display: inline-flex; align-items: center; gap: var(--sp-2); padding: 4px var(--sp-3); border-radius: var(--radius-pill); background: var(--c-surface-2); font-size: var(--fs-0); }
.ad-picker-chosen .chip button { border: 0; background: none; color: var(--c-text-3); cursor: pointer; font-size: 15px; line-height: 1; padding: 0; }
.ad-picker-chosen .chip button:hover { color: var(--c-text); }
.auth-card-wide { max-width: 720px; }
