/* Malli – mobile-first. Varm, rolig flate; produktbildene står i sentrum. */
@font-face { font-family: 'Fraunces'; src: url('/fonts/fraunces-latin.woff2') format('woff2'); font-weight: 300 600; font-display: swap; }
@font-face { font-family: 'Inter'; src: url('/fonts/inter-latin.woff2') format('woff2'); font-weight: 400 700; font-display: swap; }

:root {
  --bg: #f6f2ec; --surface: #fffdfa; --sunk: #efe9e1; --ink: #1d1915; --ink-2: #4a423b; --muted: #7a7067; --line: #e3dbd0; --line-2: #d4c9bb;
  --accent: #4b1d28; --accent-2: #6e2c3b; --on-accent: #fbf6f0;
  --ok: #2e6a46; --ok-bg: #e4efe6; --warn: #9a5b0b; --warn-bg: #f6ead3; --bad: #8f3a2f; --bad-bg: #f3e2de; --unk: #8a837c; --unk-bg: #ece8e3;
  --r: 14px; --r-sm: 10px; --r-lg: 22px;
  --serif: 'Fraunces', 'Iowan Old Style', Georgia, serif;
  --sans: 'Inter', system-ui, -apple-system, 'Segoe UI', Roboto, sans-serif;
  --safe-t: env(safe-area-inset-top, 0px); --safe-b: env(safe-area-inset-bottom, 0px);
  --tab-h: 62px; --shadow: 0 1px 2px rgba(40, 28, 18, .06), 0 8px 24px rgba(40, 28, 18, .06);
  color-scheme: light;
}
* { box-sizing: border-box; -webkit-tap-highlight-color: transparent; }
html { -webkit-text-size-adjust: 100%; }
body { margin: 0; background: var(--bg); color: var(--ink); font: 15px/1.45 var(--sans); -webkit-font-smoothing: antialiased; min-height: 100dvh; }
body.no-scroll { overflow: hidden; }
#view { outline: none; padding-bottom: calc(var(--tab-h) + var(--safe-b) + 24px); min-height: 100dvh; }
body[data-tab="none"] #view { padding-bottom: calc(96px + var(--safe-b)); }
a { color: inherit; }
img { display: block; max-width: 100%; }
button { font: inherit; color: inherit; background: none; border: 0; padding: 0; cursor: pointer; }
h1, h2, h3 { font-family: var(--serif); font-weight: 400; letter-spacing: -.01em; margin: 0; }
h1 { font-size: clamp(28px, 7vw, 40px); line-height: 1.08; }
h2 { font-size: 21px; line-height: 1.2; }
p { margin: 0; }
.small, small { font-size: 12.5px; color: var(--muted); }
.muted { color: var(--muted); }
.icon { display: inline-flex; width: 20px; height: 20px; flex: none; }
.icon svg { width: 100%; height: 100%; }
.label { font-size: 12px; font-weight: 600; letter-spacing: .08em; text-transform: uppercase; color: var(--muted); margin: 22px 0 10px; }
.eyebrow { font-size: 12px; font-weight: 600; letter-spacing: .1em; text-transform: uppercase; color: var(--muted); }
.wordmark { font-family: var(--serif); font-weight: 500; font-size: 22px; letter-spacing: .28em; text-decoration: none; text-transform: uppercase; }
.tagline { display: block; font-size: 12px; letter-spacing: .08em; color: var(--muted); margin-top: 2px; }

/* ---------- Knapper ---------- */
.btn { display: inline-flex; align-items: center; justify-content: center; gap: 8px; min-height: 48px; padding: 0 20px; border-radius: 999px;
  background: var(--ink); color: var(--surface); font-weight: 600; font-size: 15px; text-decoration: none; transition: transform .12s, opacity .2s; white-space: nowrap; }
.btn:active { transform: scale(.98); }
.btn:disabled, .btn[disabled] { opacity: .45; pointer-events: none; }
.btn-primary { background: var(--accent); color: var(--on-accent); }
.btn-ghost { background: transparent; color: var(--ink); box-shadow: inset 0 0 0 1px var(--line-2); }
.btn-block { width: 100%; }
.btn-small { min-height: 38px; padding: 0 14px; font-size: 13.5px; }
.btn .icon { width: 18px; height: 18px; }
.btn.danger { color: var(--bad); }
.icon-btn { width: 42px; height: 42px; border-radius: 50%; display: inline-grid; place-items: center; flex: none; }
.icon-btn .icon { width: 22px; height: 22px; }
.icon-btn.glass { background: rgba(255, 253, 250, .86); backdrop-filter: blur(10px); -webkit-backdrop-filter: blur(10px); box-shadow: var(--shadow); }
.link-btn { font-size: 14px; font-weight: 600; color: var(--accent); text-decoration: none; padding: 8px 4px; }

/* ---------- Segmentkontroll og chips ---------- */
.seg { display: flex; gap: 4px; padding: 4px; background: var(--sunk); border-radius: 999px; margin: 14px 0; }
.seg-btn { flex: 1; display: inline-flex; align-items: center; justify-content: center; gap: 6px; min-height: 40px; border-radius: 999px; font-weight: 600; font-size: 14px; color: var(--ink-2); text-decoration: none; transition: background .2s; }
.seg-btn .icon { width: 17px; height: 17px; }
.seg-btn.active { background: var(--surface); color: var(--ink); box-shadow: var(--shadow); }
.chips { display: flex; gap: 8px; }
.chips.wrap { flex-wrap: wrap; }
.chips.scroll { overflow-x: auto; scrollbar-width: none; padding: 2px 16px 10px; margin: 0 -16px; scroll-padding: 16px; }
.chips.scroll::-webkit-scrollbar { display: none; }
.chip { display: inline-flex; align-items: center; gap: 6px; min-height: 38px; padding: 0 15px; border-radius: 999px; background: var(--surface); box-shadow: inset 0 0 0 1px var(--line); font-size: 14px; font-weight: 500; white-space: nowrap; transition: background .15s, color .15s; }
.chip.active { background: var(--ink); color: var(--surface); box-shadow: none; }
.chip:disabled { opacity: .4; }
.chip.size { min-width: 54px; justify-content: center; font-weight: 600; }
.chip-in { display: inline-flex; align-items: center; gap: 6px; }
.chip-in .icon { width: 16px; height: 16px; }
.swatch { width: 14px; height: 14px; border-radius: 50%; box-shadow: inset 0 0 0 1px rgba(0, 0, 0, .15); display: inline-block; }
.pill { display: inline-block; font-size: 11.5px; font-weight: 600; padding: 3px 9px; border-radius: 999px; background: var(--ok-bg); color: var(--ok); white-space: nowrap; }
.pill.muted { background: var(--unk-bg); color: var(--muted); }

/* ---------- Søkefelt og input ---------- */
.search-box { display: flex; align-items: center; gap: 10px; background: var(--surface); border-radius: 999px; padding: 0 18px; min-height: 50px; box-shadow: inset 0 0 0 1px var(--line); margin: 12px 0; }
.search-box.big { min-height: 56px; box-shadow: var(--shadow), inset 0 0 0 1px var(--line); }
.search-box .icon { color: var(--muted); }
.search-input { flex: 1; border: 0; background: none; font: inherit; font-size: 16px; outline: none; min-width: 0; color: var(--ink); }
.input { font: inherit; font-size: 16px; border: 0; border-radius: var(--r-sm); background: var(--surface); box-shadow: inset 0 0 0 1px var(--line); padding: 12px 14px; width: 100%; color: var(--ink); }
.toggle { display: flex; gap: 12px; align-items: flex-start; margin: 18px 0; cursor: pointer; }
.toggle input { width: 22px; height: 22px; accent-color: var(--accent); margin: 1px 0 0; flex: none; }
.toggle span { display: grid; gap: 2px; font-weight: 500; }

/* ---------- Tabbar ---------- */
.tabbar { position: fixed; left: 0; right: 0; bottom: 0; z-index: 40; display: flex; justify-content: space-around; height: calc(var(--tab-h) + var(--safe-b)); padding-bottom: var(--safe-b);
  background: rgba(255, 253, 250, .92); backdrop-filter: saturate(1.4) blur(16px); -webkit-backdrop-filter: saturate(1.4) blur(16px); border-top: 1px solid var(--line); }
.tab { flex: 1; display: grid; place-items: center; align-content: center; gap: 3px; text-decoration: none; color: var(--muted); font-size: 11px; font-weight: 600; }
.tab .icon { width: 23px; height: 23px; }
.tab.active { color: var(--ink); }
body[data-tab="none"] .tabbar { display: none; }

/* ---------- Generelle sider ---------- */
.page, .home, .flow, .results { max-width: 1180px; margin: 0 auto; padding: calc(var(--safe-t) + 12px) 16px 0; }
.page-head { padding: 12px 0 6px; display: grid; gap: 6px; }
.page-head > .icon-btn { margin-left: -10px; }
.page-head p { color: var(--muted); }
.page-loading, .loading { display: grid; place-items: center; min-height: 40vh; color: var(--muted); }
.loading { min-height: 100px; }
.spinner { width: 28px; height: 28px; border-radius: 50%; border: 2.5px solid var(--line-2); border-top-color: var(--accent); animation: spin .8s linear infinite; }
@keyframes spin { to { transform: rotate(360deg); } }
.error-page, .empty { text-align: center; padding: 48px 16px; display: grid; gap: 12px; justify-items: center; }
.empty p { color: var(--muted); max-width: 36ch; }
.empty-actions { display: grid; gap: 10px; width: 100%; max-width: 380px; margin-top: 8px; }
.empty-note, .step-note { color: var(--muted); font-size: 13.5px; margin: 10px 0; }
.notice { display: flex; gap: 10px; align-items: flex-start; padding: 14px; border-radius: var(--r); background: var(--sunk); color: var(--ink-2); font-size: 14px; margin: 12px 0; }
.notice.warn { background: var(--warn-bg); color: var(--warn); }
.disclaimer { display: flex; gap: 8px; align-items: flex-start; font-size: 12.5px; color: var(--muted); margin: 14px 0; }
.disclaimer .icon { width: 16px; height: 16px; margin-top: 1px; }
.demo-flag { display: inline-block; font-size: 11.5px; font-weight: 700; letter-spacing: .06em; text-transform: uppercase; color: var(--warn); background: var(--warn-bg); padding: 4px 10px; border-radius: 999px; margin-bottom: 10px; }
.demo-banner { display: flex; gap: 10px; align-items: flex-start; margin: 4px 0 6px; padding: 12px 14px; border-radius: var(--r); background: var(--warn-bg); color: #6b4108; font-size: 13px; text-decoration: none; }
.prose { display: grid; gap: 12px; color: var(--ink-2); }
.list { display: grid; gap: 2px; }
.list-row { display: flex; align-items: center; gap: 12px; width: 100%; min-height: 52px; padding: 10px 4px; text-align: left; text-decoration: none; border-bottom: 1px solid var(--line); }
.list-row > span:not(.icon) { flex: 1; display: grid; }
.list-row.active { font-weight: 600; }
.list-row .icon:last-child { color: var(--muted); }
.list-row.tall { min-height: 72px; }
.list-link { display: flex; gap: 12px; align-items: center; flex: 1; text-decoration: none; }
.list-link span { display: grid; }
.thumb, .thumbs img { width: 48px; height: 60px; object-fit: cover; border-radius: 8px; background: var(--sunk); }
.thumbs { display: flex; }
.thumbs img + img { margin-left: -18px; box-shadow: -2px 0 0 var(--bg); }
.list-text { display: grid; }
.new-list { display: flex; gap: 8px; margin-top: 14px; }

/* ---------- Forside ---------- */
.home-head { display: flex; align-items: center; justify-content: space-between; padding: 6px 0; }
.hero { padding: 26px 0 8px; }
.hero h1 { font-size: clamp(34px, 9vw, 56px); }
.hero h1 em { font-style: italic; color: var(--accent); font-weight: 300; }
.hero .seg { margin-top: 24px; }
.hero-note { color: var(--muted); font-size: 13.5px; margin: -4px 4px 6px; min-height: 2.9em; }
.resume { display: grid; grid-template-columns: 1fr auto; gap: 2px 12px; align-items: center; width: 100%; text-align: left; padding: 16px 18px; border-radius: var(--r-lg); background: var(--ink); color: var(--surface); margin: 8px 0; }
.resume .icon { grid-row: 1 / 4; grid-column: 2; }
.resume-label { font-size: 11.5px; letter-spacing: .1em; text-transform: uppercase; opacity: .7; font-weight: 600; }
.resume strong { font-family: var(--serif); font-weight: 400; font-size: 19px; }
.resume small { color: inherit; opacity: .75; }
.home-section { margin-top: 30px; }
.home-section h2, .section-head h2 { margin-bottom: 14px; }
.section-head { display: flex; align-items: baseline; justify-content: space-between; margin-top: 30px; }
.mall-scroll { display: flex; gap: 10px; overflow-x: auto; scrollbar-width: none; margin: 0 -16px; padding: 0 16px 6px; scroll-snap-type: x mandatory; }
.mall-card { flex: 0 0 64%; max-width: 260px; scroll-snap-align: start; display: grid; gap: 4px; padding: 16px; border-radius: var(--r); background: var(--surface); box-shadow: inset 0 0 0 1px var(--line); text-decoration: none; }
.mall-card .icon { color: var(--accent); margin-bottom: 6px; }
.mall-card .pill { justify-self: start; margin-top: 6px; }
.home-how { display: grid; gap: 18px; margin: 40px 0 10px; padding: 24px 20px; border-radius: var(--r-lg); background: var(--surface); box-shadow: inset 0 0 0 1px var(--line); }
.home-how div { display: grid; grid-template-columns: 34px 1fr; gap: 0 10px; }
.home-how .num { grid-row: 1 / 3; width: 28px; height: 28px; border-radius: 50%; display: grid; place-items: center; font-family: var(--serif); background: var(--sunk); }
.home-how p { color: var(--muted); font-size: 14px; }
.home-foot { padding: 24px 0; text-align: center; display: grid; gap: 6px; font-size: 13px; color: var(--muted); }
.home-foot a { color: var(--ink-2); }

/* ---------- Flyt / steg ---------- */
.flow { display: flex; flex-direction: column; min-height: calc(100dvh - var(--tab-h)); }
.flow-head { display: flex; align-items: center; gap: 8px; padding: 4px 0 8px; position: sticky; top: 0; z-index: 5; background: var(--bg); margin-left: -10px; }
.progress { flex: 1; display: flex; gap: 5px; padding: 0 6px; }
.progress span { flex: 1; height: 3px; border-radius: 3px; background: var(--line); transition: background .3s; }
.progress span.on { background: var(--accent); }
.flow-body { flex: 1; }
.flow-foot { position: sticky; bottom: calc(var(--tab-h) + var(--safe-b)); padding: 14px 0; background: linear-gradient(to top, var(--bg) 70%, transparent); display: grid; gap: 4px; justify-items: center; }
.step { padding: 8px 0 20px; }
.step-title { margin: 10px 0 6px; }
.step-sub { color: var(--muted); margin-bottom: 8px; }
.aud-grid { display: grid; grid-template-columns: 1fr 1fr; gap: 10px; margin-top: 18px; }
.aud-tile { display: grid; align-content: end; gap: 4px; min-height: 132px; padding: 18px; border-radius: var(--r-lg); background: var(--surface); text-align: left; box-shadow: inset 0 0 0 1px var(--line); transition: transform .12s, background .2s; }
.aud-tile:active { transform: scale(.98); }
.aud-tile.active { background: var(--ink); color: var(--surface); }
.aud-label { font-family: var(--serif); font-size: 26px; }
.aud-sub { font-size: 13px; color: var(--muted); }
.aud-tile.active .aud-sub { color: inherit; opacity: .7; }
.aud-grid.compact .aud-tile { min-height: 84px; }
.aud-grid.compact .aud-label { font-size: 21px; }
.cat-grid { display: grid; grid-template-columns: 1fr 1fr; gap: 10px; }
.cat-tile { position: relative; aspect-ratio: 4 / 5; border-radius: var(--r); overflow: hidden; background: linear-gradient(160deg, #eee6dc, #e2d6c7); text-align: left; display: flex; align-items: flex-end; }
.cat-tile img { position: absolute; inset: 0; width: 100%; height: 100%; object-fit: cover; }
.cat-tile::after { content: ''; position: absolute; inset: 40% 0 0; background: linear-gradient(to top, rgba(20, 14, 10, .55), transparent); }
.cat-tile:not(:has(img))::after { display: none; }
.cat-name { position: relative; z-index: 1; padding: 14px; font-family: var(--serif); font-size: 19px; line-height: 1.15; }
.cat-tile:has(img) .cat-name { color: #fff; }
.cat-tile.all { background: var(--ink); color: var(--surface); }
.cat-tile.active { box-shadow: 0 0 0 2.5px var(--accent); }
.size-group { margin-top: 6px; }
.place-current { margin: 14px 0; }
.place-pill { display: flex; gap: 12px; align-items: center; padding: 14px 16px; border-radius: var(--r); background: var(--surface); box-shadow: inset 0 0 0 1.5px var(--ink); }
.place-pill div { display: grid; }
.place-results { display: grid; }
.place-row { display: flex; gap: 12px; align-items: center; text-align: left; padding: 12px 4px; border-bottom: 1px solid var(--line); }
.place-row span { display: grid; }
.mall-row { display: flex; gap: 8px; overflow-x: auto; scrollbar-width: none; margin: 0 -16px; padding: 0 16px 4px; }
.mall-chip { flex: none; display: grid; text-align: left; gap: 2px; padding: 12px 14px; border-radius: var(--r); background: var(--surface); box-shadow: inset 0 0 0 1px var(--line); max-width: 220px; }
.mall-chip strong { white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.store-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(150px, 1fr)); gap: 10px; }
.store-tile { position: relative; display: grid; justify-items: start; gap: 4px; padding: 14px; border-radius: var(--r); background: var(--surface); box-shadow: inset 0 0 0 1px var(--line); text-align: left; transition: box-shadow .15s, opacity .15s; }
.store-tile.active { box-shadow: inset 0 0 0 2px var(--ink); }
.store-grid:not(.static) .store-tile:not(.active) { opacity: .55; }
.store-tile .brand-tile { margin-bottom: 6px; }
.store-name { font-weight: 600; line-height: 1.25; }
.store-meta { font-size: 12.5px; color: var(--muted); }
.store-data { font-size: 11.5px; font-weight: 600; color: var(--ok); }
.store-tile.no-data .store-data { color: var(--muted); }
.tick { position: absolute; top: 10px; right: 10px; width: 24px; height: 24px; border-radius: 50%; background: var(--ink); color: var(--surface); display: none; place-items: center; }
.tick .icon { width: 15px; height: 15px; }
.store-tile.active .tick { display: grid; }
.more-stores { margin: 18px 0; }
.more-stores summary { cursor: pointer; font-weight: 600; padding: 10px 0; color: var(--ink-2); }
.brand-tile { --c: #3b332c; display: inline-grid; place-items: center; width: 44px; height: 44px; border-radius: 12px; background: var(--c); color: #fff; font-weight: 700; font-size: 14px; letter-spacing: .04em; overflow: hidden; flex: none; }
.brand-tile img { width: 100%; height: 100%; object-fit: contain; background: #fff; }
.brand-tile.sm { width: 26px; height: 26px; border-radius: 7px; font-size: 10px; }

/* ---------- Resultater ---------- */
.results-head { position: sticky; top: 0; z-index: 10; background: rgba(246, 242, 236, .94); backdrop-filter: blur(14px); -webkit-backdrop-filter: blur(14px); margin: 0 -16px; padding: calc(var(--safe-t) + 4px) 16px 0; }
.results { padding-top: 0; }
.results-top { display: flex; align-items: center; gap: 4px; margin-left: -10px; }
.results-title { flex: 1; font-size: 24px; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.seg-mode { margin: 6px 0 10px; }
.scope { padding: 10px 0 14px; display: grid; gap: 4px; }
.scope-main { font-size: 15px; }
.scope-sub { display: flex; gap: 6px; align-items: flex-start; font-size: 12.5px; color: var(--muted); }
.scope-sub .icon { width: 15px; height: 15px; margin-top: 1px; }
.scope-warn { display: flex; gap: 8px; align-items: center; text-align: left; font-size: 13px; color: var(--warn); background: var(--warn-bg); padding: 8px 12px; border-radius: var(--r-sm); margin-top: 6px; justify-self: start; }
.scope-warn .icon { width: 17px; height: 17px; }
.grid { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 18px 12px; }
.card { display: grid; align-content: start; gap: 10px; text-decoration: none; min-width: 0; }
.card-media { position: relative; aspect-ratio: 4 / 5; border-radius: var(--r); overflow: hidden; background: var(--sunk); }
.card-media img { width: 100%; height: 100%; object-fit: cover; transition: transform .5s; }
.card-media img.broken { opacity: 0; }
.card:hover .card-media img { transform: scale(1.03); }
.badge { position: absolute; left: 8px; top: 8px; font-size: 11.5px; font-weight: 700; padding: 4px 8px; border-radius: 999px; background: var(--surface); }
.badge.sale { background: var(--accent); color: var(--on-accent); }
.badge.demo { left: auto; right: 50px; background: var(--warn-bg); color: var(--warn); }
.badge.ok { background: var(--ok); color: #fff; }
.badge.muted { background: var(--unk-bg); color: var(--muted); }
.card-notes { position: absolute; left: 8px; top: 8px; right: 50px; display: grid; gap: 4px; justify-items: start; }
.card-notes .badge { position: static; }
.heart { position: absolute; right: 8px; top: 8px; width: 36px; height: 36px; border-radius: 50%; display: grid; place-items: center; background: rgba(255, 253, 250, .9); }
.heart .icon { width: 19px; height: 19px; }
.heart[aria-pressed="true"] { color: var(--accent); }
.card-body { display: grid; gap: 3px; min-width: 0; }
.card-retailer { font-size: 11px; font-weight: 700; letter-spacing: .09em; text-transform: uppercase; color: var(--muted); }
.card-title { font-size: 14px; line-height: 1.3; display: -webkit-box; -webkit-line-clamp: 2; -webkit-box-orient: vertical; overflow: hidden; }
.prices { display: flex; gap: 6px; align-items: baseline; flex-wrap: wrap; }
.price { font-weight: 600; }
.price.sale { color: var(--accent); }
.price-was { color: var(--muted); font-size: 13px; }
.avail { display: grid; grid-template-columns: auto 1fr; gap: 0 6px; align-items: center; font-size: 12.5px; font-weight: 600; margin-top: 2px; }
.avail small { grid-column: 2; font-weight: 400; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.avail.online { color: var(--muted); font-weight: 500; }
.avail.online .icon { width: 14px; height: 14px; }
.dot { width: 8px; height: 8px; border-radius: 50%; background: var(--unk); }
.s-in.dot, .dot.s-in { background: var(--ok); }
.dot.s-few { background: var(--warn); }
.card .pill { justify-self: start; background: var(--sunk); color: var(--ink-2); }
.card.skeleton .card-media, .sk-line { background: linear-gradient(90deg, var(--sunk), #f5f0ea, var(--sunk)); background-size: 200% 100%; animation: sk 1.2s infinite; }
.sk-line { height: 12px; border-radius: 6px; display: block; }
.sk-line.short { width: 60%; }
@keyframes sk { to { background-position: -200% 0; } }
.load-more { display: grid; place-items: center; padding: 28px 0; }
.end-note { color: var(--muted); font-size: 13px; }

/* ---------- Lagerstatus ---------- */
.state { display: inline-flex; align-items: center; gap: 6px; font-size: 12.5px; font-weight: 600; padding: 3px 9px 3px 7px; border-radius: 999px; background: var(--unk-bg); color: var(--unk); }
.state i { width: 7px; height: 7px; border-radius: 50%; background: currentColor; }
.state.s-in { background: var(--ok-bg); color: var(--ok); }
.state.s-few { background: var(--warn-bg); color: var(--warn); }
.state.s-out { background: var(--bad-bg); color: var(--bad); }
.state.s-display { background: var(--unk-bg); color: var(--ink-2); }

/* ---------- Produktside ---------- */
.product { max-width: 1180px; margin: 0 auto; }
.product-media { position: relative; }
.gallery { display: flex; overflow-x: auto; scroll-snap-type: x mandatory; scrollbar-width: none; aspect-ratio: 4 / 5; max-height: 78vh; background: var(--sunk); }
.gallery::-webkit-scrollbar { display: none; }
.gallery img { flex: 0 0 100%; width: 100%; height: 100%; object-fit: cover; scroll-snap-align: center; }
.gallery-empty { display: grid; place-items: center; width: 100%; color: var(--muted); }
.gallery-dots { position: absolute; bottom: 14px; left: 0; right: 0; display: flex; justify-content: center; gap: 6px; pointer-events: none; }
.gallery-dots span { width: 6px; height: 6px; border-radius: 50%; background: rgba(255, 255, 255, .6); box-shadow: 0 0 2px rgba(0, 0, 0, .3); }
.gallery-dots span.on { background: #fff; width: 18px; border-radius: 3px; }
.media-bar { position: absolute; top: calc(var(--safe-t) + 10px); left: 12px; right: 12px; display: flex; gap: 8px; }
.media-bar .spacer { flex: 1; }
.media-bar .heart { position: static; width: 42px; height: 42px; box-shadow: var(--shadow); }
.product-info { padding: 20px 16px 0; }
.product-retailer { display: flex; align-items: center; gap: 8px; font-size: 13px; font-weight: 600; }
.product-title { font-size: clamp(26px, 6.5vw, 36px); margin: 10px 0 8px; }
.product-price .price { font-size: 19px; }
.colors .chips { margin-bottom: 4px; }
.sibling-row { display: flex; gap: 8px; }
.sibling img { width: 54px; height: 68px; object-fit: cover; border-radius: 8px; background: var(--sunk); }
.size-chips { display: grid; grid-template-columns: repeat(auto-fill, minmax(64px, 1fr)); gap: 8px; }
.size-chip { display: grid; place-items: center; gap: 1px; min-height: 56px; border-radius: var(--r-sm); background: var(--surface); box-shadow: inset 0 0 0 1px var(--line); font-weight: 600; }
.size-chip small { font-size: 10.5px; font-weight: 600; color: var(--muted); }
.size-chip.s-in small { color: var(--ok); }
.size-chip.s-few small { color: var(--warn); }
.size-chip.s-out, .size-chip.s-unknown { color: var(--muted); }
.size-chip.s-out span { text-decoration: line-through; }
.size-chip.wanted:not(.active) { box-shadow: inset 0 0 0 1px var(--ink-2); }
.size-chip.active { background: var(--ink); color: var(--surface); box-shadow: none; }
.size-chip.active small { color: inherit; opacity: .8; }
.stock { margin-top: 30px; }
.stock h2 { margin-bottom: 4px; }
.stock-summary { color: var(--ink-2); margin-bottom: 12px; }
.stock-list { display: grid; gap: 10px; }
.stock-row { padding: 16px; border-radius: var(--r); background: var(--surface); box-shadow: inset 0 0 0 1px var(--line); display: grid; gap: 12px; }
.stock-row.s-out, .stock-row.s-unknown { background: transparent; }
.stock-row.s-out .stock-main, .stock-row.s-unknown .stock-main { opacity: .72; }
.stock-title { display: flex; justify-content: space-between; gap: 10px; }
.dist { color: var(--muted); font-size: 13.5px; white-space: nowrap; }
.stock-addr { font-size: 13px; color: var(--muted); margin-top: 2px; }
.stock-meta { display: flex; gap: 10px; flex-wrap: wrap; align-items: center; font-size: 12.5px; margin-top: 8px; }
.stock-meta .open { color: var(--ok); font-weight: 600; }
.stock-meta .closed { color: var(--muted); }
.stock-time { font-size: 11.5px; color: var(--muted); margin-top: 6px; }
.stock-actions { display: flex; gap: 8px; flex-wrap: wrap; }
.product-more { margin: 28px 0 20px; display: grid; gap: 16px; }
.desc summary { font-weight: 600; cursor: pointer; padding: 6px 0; }
.desc p { color: var(--ink-2); margin-top: 6px; white-space: pre-line; }
.disclosure { font-size: 12px; color: var(--muted); }
.action-bar { position: fixed; z-index: 30; left: 0; right: 0; bottom: 0; display: flex; align-items: center; gap: 12px; justify-content: space-between;
  padding: 12px 16px calc(12px + var(--safe-b)); background: rgba(255, 253, 250, .95); backdrop-filter: blur(16px); -webkit-backdrop-filter: blur(16px); border-top: 1px solid var(--line); }
.action-price { display: grid; }
.action-bar .btn { flex: 0 1 auto; padding: 0 22px; }

/* ---------- Kjøpesenter, lagret ---------- */
.mall-list { display: grid; }
.mall-item { display: flex; align-items: center; gap: 12px; padding: 14px 2px; border-bottom: 1px solid var(--line); text-decoration: none; }
.mall-icon { width: 42px; height: 42px; border-radius: 12px; background: var(--surface); box-shadow: inset 0 0 0 1px var(--line); display: grid; place-items: center; color: var(--accent); flex: none; }
.mall-text { flex: 1; display: grid; min-width: 0; }
.mall-text strong { white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.mall-item > .icon:last-child { color: var(--muted); }
.mall-stats { display: flex; gap: 10px; margin: 14px 0; }
.mall-stats div { flex: 1; padding: 14px; border-radius: var(--r); background: var(--surface); box-shadow: inset 0 0 0 1px var(--line); display: grid; }
.mall-stats strong { font-family: var(--serif); font-size: 28px; font-weight: 400; }
.mall-actions { display: grid; gap: 10px; margin-bottom: 26px; }
.mall-page section { margin-top: 24px; }
.mall-page section h2 { margin-bottom: 12px; }
.trip { list-style: none; padding: 0; margin: 12px 0; display: grid; gap: 12px; counter-reset: stop; }
.trip-stop { padding: 16px; border-radius: var(--r); background: var(--surface); box-shadow: inset 0 0 0 1px var(--line); display: grid; gap: 12px; }
.trip-head { display: flex; justify-content: space-between; align-items: center; gap: 10px; }
.trip-head div { display: grid; }
.trip-items { display: flex; gap: 10px; overflow-x: auto; scrollbar-width: none; }
.trip-item { flex: 0 0 96px; display: grid; gap: 4px; text-decoration: none; font-size: 12.5px; }
.trip-item img { width: 96px; height: 120px; object-fit: cover; border-radius: 10px; background: var(--sunk); }
.trip-item span { display: -webkit-box; -webkit-line-clamp: 2; -webkit-box-orient: vertical; overflow: hidden; }
.pref { margin-bottom: 6px; }
.about .list { margin-bottom: 12px; }
.filters .price-row { display: flex; gap: 10px; align-items: center; }

/* ---------- Bunnark og toast ---------- */
.sheet-backdrop { position: fixed; inset: 0; z-index: 100; background: rgba(25, 18, 12, 0); display: flex; align-items: flex-end; justify-content: center; transition: background .25s; }
.sheet-backdrop.open { background: rgba(25, 18, 12, .38); }
.sheet { width: 100%; max-width: 640px; max-height: 92dvh; display: flex; flex-direction: column; background: var(--bg); border-radius: var(--r-lg) var(--r-lg) 0 0; transform: translateY(100%); transition: transform .28s cubic-bezier(.2, .8, .2, 1); }
.sheet-backdrop.open .sheet { transform: none; }
.sheet-grip { width: 38px; height: 4px; border-radius: 4px; background: var(--line-2); margin: 8px auto 0; }
.sheet-head { display: flex; align-items: center; justify-content: space-between; padding: 6px 10px 0 18px; }
.sheet-head h2 { font-size: 20px; }
.sheet-body { overflow-y: auto; padding: 0 18px 18px; overscroll-behavior: contain; }
.sheet-body .step { padding-top: 0; }
.sheet-body .step-title { display: none; }
.sheet-foot { display: flex; gap: 10px; padding: 12px 18px calc(12px + var(--safe-b)); border-top: 1px solid var(--line); }
.sheet-foot .btn { flex: 1; }
.toast { position: fixed; left: 50%; bottom: calc(var(--tab-h) + var(--safe-b) + 18px); z-index: 200; transform: translate(-50%, 20px); opacity: 0; pointer-events: none;
  background: var(--ink); color: var(--surface); padding: 12px 18px; border-radius: 999px; font-size: 14px; font-weight: 500; transition: all .25s; white-space: nowrap; }
.toast.show { opacity: 1; transform: translate(-50%, 0); }

/* ---------- Større skjermer (web) ---------- */
@media (min-width: 720px) {
  .grid { grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 28px 18px; }
  .cat-grid { grid-template-columns: repeat(4, 1fr); }
  .aud-grid { grid-template-columns: repeat(4, 1fr); }
  .page, .home, .flow, .results { padding-left: 28px; padding-right: 28px; }
  .results-head { margin: 0 -28px; padding-left: 28px; padding-right: 28px; }
  .chips.scroll { margin: 0 -28px; padding-left: 28px; padding-right: 28px; }
  .home-how { grid-template-columns: repeat(3, 1fr); }
  .sheet-backdrop { align-items: center; }
  .sheet { border-radius: var(--r-lg); }
  .product { display: grid; grid-template-columns: minmax(0, 1.1fr) minmax(0, 1fr); gap: 36px; padding: 24px 28px 0; }
  .product-media { position: sticky; top: 24px; align-self: start; }
  .gallery { border-radius: var(--r-lg); }
  .product-info { padding-top: 0; }
  .action-bar { left: auto; right: max(28px, calc((100vw - 1180px) / 2 + 28px)); bottom: 24px; width: min(420px, calc(50vw - 40px)); border-radius: var(--r-lg); border: 1px solid var(--line); box-shadow: var(--shadow); padding-bottom: 12px; }
}
@media (min-width: 1100px) {
  .grid { grid-template-columns: repeat(4, minmax(0, 1fr)); }
  .tabbar { top: 0; bottom: auto; height: 60px; padding: 0 max(28px, calc((100vw - 1180px) / 2 + 28px)); justify-content: flex-end; gap: 8px; border-top: 0; border-bottom: 1px solid var(--line); }
  .tab { flex: none; grid-auto-flow: column; gap: 8px; padding: 0 14px; font-size: 14px; }
  .tab .icon { width: 19px; height: 19px; }
  #view { padding-top: 60px; padding-bottom: 40px; }
  .results-head { top: 60px; }
  .flow-head { top: 60px; }
  .flow-foot { bottom: 0; }
  .toast { bottom: 30px; }
  body[data-tab="none"] .tabbar { display: flex; }
}
@media (prefers-reduced-motion: reduce) { * { transition: none !important; animation: none !important; } }

/* ---------- Statiske sider (SEO, om, personvern) ---------- */
.page-doc { background: var(--bg); }
.doc-head { max-width: 1080px; margin: 0 auto; display: flex; justify-content: space-between; align-items: center; padding: 16px 20px; }
.doc { max-width: 1080px; margin: 0 auto; padding: 12px 20px 40px; display: grid; gap: 14px; }
.doc h1 { margin-top: 6px; }
.doc h2 { margin-top: 18px; }
.doc .lead { font-size: 17px; color: var(--ink-2); max-width: 60ch; }
.doc p, .doc li { max-width: 70ch; }
.doc .btn { justify-self: start; }
.doc code { background: var(--sunk); padding: 1px 6px; border-radius: 6px; font-size: 13px; }
.doc pre { background: var(--ink); color: #f3ece3; padding: 16px; border-radius: var(--r); overflow-x: auto; font-size: 12.5px; }
.doc table { border-collapse: collapse; width: 100%; font-size: 14px; }
.doc th, .doc td { text-align: left; padding: 8px 10px; border-bottom: 1px solid var(--line); vertical-align: top; }
.doc-foot { max-width: 1080px; margin: 0 auto; padding: 20px; border-top: 1px solid var(--line); color: var(--muted); font-size: 13px; display: grid; gap: 6px; }
.seo-product { display: grid; gap: 24px; }
.seo-gallery { display: flex; gap: 10px; overflow-x: auto; }
.seo-gallery img { width: min(78vw, 420px); aspect-ratio: 4 / 5; object-fit: cover; border-radius: var(--r); background: var(--sunk); flex: none; }
.seo-info { display: grid; gap: 10px; align-content: start; }
.seo-list { padding-left: 18px; margin: 0; display: grid; gap: 4px; }
.seo-list.cols { columns: 2; display: block; }
.seo-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(160px, 1fr)); gap: 16px; }
.seo-card { display: grid; gap: 4px; text-decoration: none; font-size: 14px; }
.seo-card img { aspect-ratio: 4 / 5; object-fit: cover; border-radius: var(--r); background: var(--sunk); width: 100%; }
.demo-cart { padding: 16px; border-radius: var(--r); background: var(--surface); box-shadow: inset 0 0 0 1px var(--line); }
@media (min-width: 820px) { .seo-product { grid-template-columns: 1.1fr 1fr; } .seo-gallery { flex-direction: column; } .seo-gallery img { width: 100%; } }
.nav-mark { display: none; }
@media (min-width: 1100px) { .nav-mark { display: block; margin-right: auto; align-self: center; font-size: 19px; } .home-head .wordmark { visibility: hidden; } }
.onb-form { display: grid; gap: 14px; max-width: 560px; }
.onb-form label:not(.toggle) { display: grid; gap: 6px; font-size: 13px; font-weight: 600; color: var(--ink-2); }
.onb-form .toggle small { display: block; font-weight: 400; }
