/* ──────────────────────────────────────────────────────────────────────────
   Bakken Motor — shared system styles
   Source of truth: product-single.html. Pair with bakken-tokens.css (design
   tokens) and bakken-header.js (the <bakken-header> custom element).

   This file carries everything shared across every page: the base/type layer,
   primitives (buttons, chips, cards, inputs, focus, skip-link), a few shared
   components (tabs, reveal load-in, related-card, demo tiles), and the full
   header system (topbar / mainbar / catbar / mega / drawer / popover / toast).
   Page-specific CSS stays inline in each page. Edit a shared rule here once and
   it propagates to every page.
   ────────────────────────────────────────────────────────────────────────── */

/* ─── Base & typografi ─── */
html {
  scroll-behavior: smooth;
}
html,
body {
  font-family: var(--font-display);
  color: var(--bm-ink);
  background: var(--bm-bg);
}
body {
  -webkit-font-smoothing: antialiased;
  text-rendering: optimizeLegibility;
  font-kerning: normal;
}

h1,
h2,
h3 {
  text-wrap: balance;
  letter-spacing: -0.025em;
}
p {
  text-wrap: pretty;
}

/* Content-link convention: graphite-navy at rest, marine accent recolour on
   interaction (no underline). Chrome links (header nav, footer, breadcrumb,
   topbar, drawer) set their own colour. */
a {
  color: var(--bm-navy-600);
  text-decoration: none;
  transition: color 0.15s var(--ease-out-quart);
}
/* Buttons (anchor-buttons .btn and .button) keep their own colour and never
   take the content-link accent recolour. Red CTAs deepen to --bm-cta-600 via
   their own :hover; the label must not turn marine. */
a:hover:not(.btn):not(.button),
a:active:not(.btn):not(.button) {
  color: var(--bm-accent-600);
}
/* Links on dark navy surfaces read as light, not the dark marine accent (which
   falls to ~2:1 on navy-900). Hover still resolves to #fff. */
.topbar a,
footer a {
  color: var(--bm-navy-50);
}
/* Navigation/chrome links and breadcrumbs manage their own affordance; this
   guard keeps them free of any text-decoration on interaction. */
.topbar a:hover,
.topbar a:active,
footer a:hover,
footer a:active,
.catbar a:hover,
.catbar a:active,
.mega a:hover,
.mega a:active,
.drawer a:hover,
.drawer a:active,
.acc-list a:hover,
.acc-list a:active,
.navbar__item:hover,
.navbar__item:active,
.nav-contact:hover,
.nav-contact:active,
.skip-link:hover,
.skip-link:active,
.breadcrumb__link:hover,
.breadcrumb__link:active {
  text-decoration: none;
}

/* Mono-tall: aksjekurs, spesifikasjoner, teller */
.num {
  font-family: var(--font-mono);
  font-variant-numeric: tabular-nums;
  font-feature-settings: 'tnum' 1;
  letter-spacing: -0.01em;
}
.mono-label {
  font-family: var(--font-mono);
  letter-spacing: 0.08em;
  text-transform: uppercase;
}

/* Fokusring (HeroUI-stil) — aksentfarge */
:where(button, a, input, select, textarea, summary, [tabindex]):focus-visible {
  outline: 2px solid var(--bm-accent-500);
  outline-offset: 2px;
  border-radius: 6px;
}

/* Skip link */
.skip-link {
  position: fixed;
  top: 8px;
  left: 8px;
  z-index: 60;
  background: var(--bm-navy-800);
  color: #fff;
  padding: 10px 16px;
  border-radius: 10px;
  font-weight: 600;
  transform: translateY(-150%);
  transition: transform 0.2s var(--ease-out-quart);
}
.skip-link:focus {
  transform: translateY(0);
}

/* ─── Primitiver ─── */

/* Chip (HeroUI <Chip variant="flat">) */
.chip {
  display: inline-flex;
  align-items: center;
  gap: 0.375rem;
  height: 27px;
  padding: 0 11px;
  border-radius: 999px;
  font-size: 12px;
  font-weight: 600;
  line-height: 1;
  letter-spacing: 0.01em;
}

/* Knapper (HeroUI <Button>) */
.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 0.5rem;
  height: 48px;
  padding: 0 20px;
  border-radius: 12px;
  font-weight: 600;
  font-size: 15px;
  line-height: 1;
  transition:
    transform 0.15s var(--ease-out-quart),
    background 0.15s,
    color 0.15s,
    border-color 0.15s,
    box-shadow 0.15s;
  user-select: none;
  cursor: pointer;
  border: 1px solid transparent;
}
.btn:active {
  transform: translateY(1px) scale(0.99);
}
.btn-sm {
  height: 38px;
  padding: 0 15px;
  font-size: 14px;
  border-radius: 10px;
}
.btn-primary {
  background: var(--bm-cta-500);
  color: #fff;
  box-shadow: 0 1px 2px oklch(24% 0.02 246 / 0.12);
}
.btn-primary:hover {
  background: var(--bm-cta-600);
}
.btn-solid-navy {
  background: var(--bm-navy-800);
  color: #fff;
}
.btn-solid-navy:hover {
  background: var(--bm-navy-900);
}
.btn-bordered {
  border-color: var(--bm-line);
  color: var(--bm-ink);
  background: #fff;
}
.btn-bordered:hover {
  background: var(--bm-navy-50);
  border-color: var(--bm-navy-200);
}
.btn-light {
  color: var(--bm-navy-700);
  background: transparent;
}
.btn-light:hover {
  background: var(--bm-navy-50);
}
.btn-on-dark {
  background: #fff;
  color: var(--bm-navy-900);
}
.btn-on-dark:hover {
  background: var(--bm-navy-50);
}
.btn:disabled {
  opacity: 0.55;
  cursor: not-allowed;
}

/* Kort */
.card {
  background: #fff;
  border: 1px solid var(--bm-line);
  border-radius: var(--radius-card);
  box-shadow: var(--shadow-card);
}

/* Felt (HeroUI <Input variant="bordered">) */
.input,
.textarea,
.select {
  width: 100%;
  border: 1px solid var(--bm-line);
  border-radius: 10px;
  padding: 12px 13px;
  font-size: 15px;
  background: #fff;
  color: var(--bm-ink);
  font-family: var(--font-display);
  transition:
    border-color 0.15s,
    box-shadow 0.15s;
}
.input::placeholder,
.textarea::placeholder {
  color: oklch(53% 0.02 244);
} /* ≥4.5:1 på hvit */
.input:focus,
.textarea:focus,
.select:focus {
  border-color: var(--bm-accent-500);
  box-shadow: 0 0 0 3px oklch(52% 0.108 235 / 0.18);
  outline: none;
}
.input[aria-invalid='true'],
.textarea[aria-invalid='true'] {
  border-color: oklch(55% 0.17 25);
  box-shadow: 0 0 0 3px oklch(55% 0.17 25 / 0.15);
}
.label {
  font-size: 13px;
  font-weight: 600;
  color: var(--bm-ink);
  margin-bottom: 6px;
  display: block;
}
.field-error {
  color: oklch(52% 0.18 25);
  font-size: 12.5px;
  margin-top: 5px;
  display: none;
}
.field-error.show {
  display: block;
}
.req {
  color: var(--bm-accent-600);
}

/* ─── Delte komponenter ─── */

/* Faner (HeroUI <Tabs>) */
.tab-trigger {
  color: var(--bm-muted);
  transition:
    color 0.15s,
    background 0.15s;
}
.tab-trigger:hover {
  color: var(--bm-navy-700);
}
.tab-trigger[aria-selected='true'] {
  color: var(--bm-navy-800);
  background: #fff;
  box-shadow: 0 1px 2px oklch(24% 0.02 246 / 0.08);
}

/* Trekkspill / chevron */
details[open] > summary .chev {
  transform: rotate(180deg);
}
summary {
  list-style: none;
}
summary::-webkit-details-marker {
  display: none;
}
.chev {
  transition: transform 0.25s var(--ease-out-quart);
}

/* Relaterte kort */
.related-card {
  transition:
    transform 0.25s var(--ease-out-quart),
    box-shadow 0.25s var(--ease-out-quart);
}
.related-card:hover {
  transform: translateY(-3px);
  box-shadow: var(--shadow-float);
}
.related-card img {
  transition: transform 0.5s var(--ease-out-quart);
}
.related-card:hover img {
  transform: scale(1.05);
}

/* Demo-innhold (kontekst for sticky/scroll) */
.demo-body {
  padding: 40px 0 120px;
}
.tile {
  border: 1px solid var(--bm-line);
  border-radius: 14px;
  background: #fff;
  padding: 18px;
  display: flex;
  align-items: center;
  gap: 14px;
  transition:
    box-shadow 0.2s var(--ease-out-quart),
    transform 0.2s var(--ease-out-quart);
}
.tile:hover {
  box-shadow: var(--shadow-card);
  transform: translateY(-2px);
}
.tile .ic {
  width: 46px;
  height: 46px;
  border-radius: 11px;
  background: var(--bm-navy-50);
  color: var(--bm-navy-700);
  display: grid;
  place-items: center;
  flex: none;
}

/* NB: `.reveal` is intentionally NOT defined here. Pages implement it differently
   (product pages: load-in animation; frontpage: scroll-triggered .js-anim/.in
   transition), so each page keeps its own `.reveal` rules inline. */

/* ══════════════════════════════════════════════════════════════════════════
   Header system — rendered by the <bakken-header> custom element
   (bakken-header.js, light DOM). Topbar / mainbar / catbar / mega / drawer /
   popover / toast. Stilguide.html uses the same classes with inline markup.
   ══════════════════════════════════════════════════════════════════════════ */

/* Host element: display:contents so it generates NO box of its own. Otherwise the
   host would be a ~170px-tall wrapper, and position:sticky on the inner .site-header
   can only stick within its containing block — so it would un-stick (scroll away) the
   moment you scrolled past the header's own height. display:contents lets .site-header
   stick against the page/viewport for the full scroll, exactly as a direct body child. */
bakken-header {
  display: contents;
}

.wrap {
  max-width: var(--maxw);
  margin: 0 auto;
  padding: 0 16px;
}

/* ─── Navbar / button / badge / dropdown anatomy ─── */
.navbar {
  --navbar-height: 4rem;
  --navbar-max-width: var(--maxw);
  --navbar-transition-duration: 300ms;
  background: var(--background);
  color: var(--foreground);
}
.navbar--sticky {
  position: sticky;
  top: 0;
}
.navbar__brand {
  display: inline-flex;
  align-items: center;
  gap: 0.5rem;
  flex-shrink: 0;
}
.navbar__content {
  display: flex;
  align-items: center;
  gap: 0.25rem;
}
.navbar__item {
  position: relative;
  display: inline-flex;
  align-items: center;
  gap: 0.5rem;
  border-radius: 8px;
  color: var(--muted);
  cursor: var(--cursor-interactive);
}
.navbar__item:hover,
.navbar__item[data-current='true'],
.navbar__item[aria-current='page'] {
  color: var(--foreground);
}
.navbar__separator {
  align-self: center;
  height: 24px;
  border-left: 1px solid var(--separator);
}
.navbar__menu-toggle {
  cursor: var(--cursor-interactive);
}
.btn-solid {
  background: var(--bm-navy-800);
  color: #fff;
}
.btn-solid:hover {
  background: var(--bm-navy-900);
}
.button {
  --button-bg: transparent;
  --button-bg-hover: var(--button-bg);
  --button-fg: currentColor;
  background: var(--button-bg);
  color: var(--button-fg);
  cursor: var(--cursor-interactive);
}
.button:hover {
  background: var(--button-bg-hover);
}
.button:active {
  transform: scale(0.98);
}
.button--primary {
  --button-bg: var(--accent);
  --button-bg-hover: var(--accent-hover);
  --button-fg: var(--accent-foreground);
}
.button--danger {
  --button-bg: var(--danger);
  --button-bg-hover: var(--danger-hover);
  --button-fg: var(--danger-foreground);
}
.button--outline {
  --button-bg: var(--surface);
  --button-bg-hover: var(--default);
  --button-fg: var(--foreground);
  border-color: var(--border);
}
.button--ghost {
  --button-bg: transparent;
  --button-bg-hover: var(--default);
  --button-fg: var(--foreground);
}
.button--sm {
  height: 38px;
  padding: 0 14px;
  font-size: 14px;
}
.button--icon-only {
  width: 40px;
  padding: 0;
}
.button--full-width,
.btn.w-full {
  width: 100%;
}
.badge {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-width: 18px;
  min-height: 18px;
  padding: 0 5px;
  border-radius: 999px;
  font-family: var(--font-mono);
  font-size: 10.5px;
  font-weight: 600;
  line-height: 1;
  border: 1px solid var(--background);
}
.badge--primary.badge--danger {
  background: var(--danger);
  color: var(--danger-foreground);
}
.badge-anchor {
  position: relative;
  display: inline-flex;
}
.dropdown {
  position: relative;
}
.dropdown__trigger {
  outline: none;
  transition:
    transform 0.2s var(--ease-out-quart),
    background 0.15s,
    box-shadow 0.15s;
}
.dropdown__trigger:active {
  transform: scale(0.98);
}
.dropdown__popover {
  background: var(--overlay);
  color: var(--overlay-foreground);
  box-shadow: var(--shadow-overlay);
}
.dropdown__menu {
  display: flex;
  flex-direction: column;
  gap: 2px;
}

/* ─── Header-skall ─── */
.site-header {
  position: sticky;
  top: 0;
  z-index: var(--z-header);
  background: var(--bm-bg);
  transition: box-shadow 0.28s var(--ease-out-quart);
}
.site-header.is-compact {
  box-shadow: var(--shadow-float);
}

/* Topplinje */
.topbar {
  background: var(--bm-navy-900);
  color: #fff;
  font-size: 12.5px;
}
.topbar .wrap {
  height: 38px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 16px;
}
.topbar a:hover {
  color: #fff;
}
.topbar .left {
  display: flex;
  align-items: center;
  gap: 18px;
  min-width: 0;
}
.topbar .left .promo {
  display: inline-flex;
  align-items: center;
  gap: 7px;
  color: var(--bm-navy-200);
}
.topbar .open {
  display: inline-flex;
  align-items: center;
  gap: 7px;
  color: var(--bm-navy-200);
}
.topbar .right {
  display: flex;
  align-items: center;
  gap: 16px;
  color: var(--bm-navy-200);
}
.stockdot {
  width: 7px;
  height: 7px;
  border-radius: 99px;
  background: var(--bm-ok-dot);
  box-shadow: 0 0 0 3px oklch(64% 0.15 162 / 0.25);
  flex: none;
}
.topbar .wrap {
  position: relative;
}
.topbar .tb-banner {
  position: absolute;
  left: 50%;
  transform: translateX(-50%);
  display: inline-flex;
  align-items: center;
  gap: 9px;
  text-decoration: none;
  max-width: min(60%, 720px);
}
.topbar .tb-chip {
  flex: none;
  display: inline-flex;
  align-items: center;
  height: 22px;
  padding: 0 9px;
  border-radius: 999px;
  background: var(--bm-cta-500);
  color: #fff;
  font-family: var(--font-mono);
  font-size: 11px;
  font-weight: 700;
  letter-spacing: 0.03em;
  text-transform: uppercase;
  white-space: nowrap;
}
.topbar .tb-title {
  color: #fff;
  font-weight: 600;
  font-size: 12.5px;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
  transition: color 0.18s var(--ease-out-quart);
}
.topbar .tb-banner:hover .tb-title {
  color: var(--bm-accent-300);
}

/* Hovedlinje */
.mainbar {
  background: #fff;
  border-bottom: 1px solid var(--bm-line);
}
.mainbar .wrap {
  height: 80px;
  display: grid;
  grid-template-columns: auto minmax(0, 1fr) auto;
  align-items: center;
  gap: 28px;
  transition: height 0.25s var(--ease-out-quart);
}
.brand {
  display: inline-flex;
  align-items: center;
  gap: 10px;
}
.brand-logo {
  display: block;
  width: clamp(160px, 17vw, 230px);
  height: auto;
  color: var(--bm-navy-800);
}
.brand .mark {
  width: 38px;
  height: 38px;
  border-radius: 10px;
  background: var(--bm-navy-800);
  color: #fff;
  display: grid;
  place-items: center;
  font-weight: 800;
}
.brand .name {
  font-weight: 800;
  color: var(--bm-navy-800);
  letter-spacing: 0;
  font-size: 18px;
}
.brand .sub {
  font-size: 10px;
  color: var(--bm-muted);
}

/* Søk med scope */
.search {
  position: relative;
  display: flex;
  align-items: center;
  gap: 8px;
  height: 48px;
  background: var(--bm-navy-50);
  border: 1px solid var(--bm-line);
  border-radius: 14px;
  padding: 0 7px 0 14px;
  transition:
    background 0.15s,
    border-color 0.15s,
    box-shadow 0.15s;
  max-width: 600px;
}
.search.search-field {
  flex-direction: row;
}
.search .ico {
  color: var(--bm-muted);
  flex: none;
}
.search:focus-within {
  background: #fff;
  border-color: var(--bm-accent-500);
  box-shadow: 0 0 0 4px oklch(25.5% 0.034 247 / 0.12);
}
.search .scope {
  appearance: none;
  -webkit-appearance: none;
  flex: none;
  height: 34px;
  border: 1px solid var(--bm-line);
  background: #fff
    url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='12' height='12' viewBox='0 0 24 24' fill='none' stroke='%23687683' stroke-width='2.5' stroke-linecap='round' stroke-linejoin='round'%3E%3Cpolyline points='6 9 12 15 18 9'/%3E%3C/svg%3E")
    no-repeat right 10px center;
  background-size: 12px;
  font: inherit;
  font-size: 13.5px;
  font-weight: 600;
  color: var(--bm-navy-700);
  padding: 0 30px 0 13px;
  border-radius: 9px;
  cursor: pointer;
}
.search .scope:hover {
  background-color: var(--bm-navy-50);
}
.search .scope:focus-visible {
  outline-offset: -2px;
}
.search input {
  flex: 1;
  min-width: 0;
  border: 0;
  outline: 0;
  background: transparent;
  font: inherit;
  font-size: 14.5px;
  color: var(--bm-ink);
  padding: 0 4px;
}
.search input::placeholder {
  color: oklch(53% 0.02 244);
}
.search .clear {
  flex: none;
  width: 30px;
  height: 30px;
  border-radius: 8px;
  display: grid;
  place-items: center;
  color: var(--bm-muted);
  background: transparent;
  border: 0;
  cursor: pointer;
  transition:
    background 0.15s,
    color 0.15s;
}
.search .clear:hover {
  background: var(--bm-navy-50);
  color: var(--bm-ink);
}
.search .clear[hidden] {
  display: none;
}
.search .go {
  width: 36px;
  height: 36px;
  border-radius: 9px;
  display: grid;
  place-items: center;
  color: #fff;
  background: var(--bm-navy-800);
  flex: none;
}
.search .go:hover {
  background: var(--bm-navy-900);
}
.kbd {
  font-family: var(--font-mono);
  font-size: 11px;
  color: var(--bm-muted);
  border: 1px solid var(--bm-line);
  border-radius: 6px;
  padding: 2px 6px;
  background: #fff;
}

/* ─── Søkeforslag (autocomplete-panel under søkefeltet) ───
   Forankret til søkefeltet (.search er position:relative), flyter ut over
   katlinjen via z-dropdown. Forslag øverst, produkttreff under, «se alle» i bunn. */
.search-suggest {
  position: absolute;
  top: calc(100% + 9px);
  left: 0;
  right: 0;
  z-index: var(--z-dropdown);
  background: #fff;
  border: 1px solid var(--bm-line);
  border-radius: var(--radius-card);
  box-shadow: var(--shadow-float);
  padding: 7px;
  overflow: hidden;
  transform-origin: top center;
  animation: ss-in 0.19s var(--ease-out-expo);
}
.search-suggest[hidden] {
  display: none;
}

.ss-group {
  display: flex;
  align-items: baseline;
  justify-content: space-between;
  padding: 8px 10px 4px;
}
.ss-group__label {
  font-family: var(--font-mono);
  font-size: 11px;
  font-weight: 500;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  color: var(--bm-muted);
}
.ss-group__count {
  font-family: var(--font-mono);
  font-size: 11px;
  color: var(--bm-muted);
}

.ss-opt {
  box-sizing: border-box;
  display: flex;
  align-items: center;
  gap: 11px;
  width: 100%;
  text-align: left;
  background: transparent;
  border: 0;
  border-radius: 10px;
  padding: 9px 10px;
  cursor: pointer;
  text-decoration: none;
  color: var(--bm-ink);
  font: inherit;
}
.ss-opt.is-active,
.ss-opt:hover {
  background: var(--bm-navy-50);
}

/* Forslag (søkeordfullføring) */
.ss-sugg__ico {
  flex: none;
  width: 30px;
  height: 30px;
  border-radius: 8px;
  display: grid;
  place-items: center;
  background: #fff;
  border: 1px solid var(--bm-line);
  color: var(--bm-muted);
  transition:
    color 0.12s,
    border-color 0.12s;
}
.ss-opt.is-active .ss-sugg__ico {
  color: var(--bm-accent-600);
  border-color: var(--bm-accent-300);
}
.ss-sugg__text {
  flex: 1;
  min-width: 0;
  font-size: 14px;
  line-height: 1.3;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
  color: var(--bm-navy-800);
}
.ss-sugg__arrow {
  flex: none;
  color: var(--bm-navy-300);
  opacity: 0;
  transform: translateX(-3px);
  transition:
    opacity 0.14s var(--ease-out-quart),
    transform 0.14s var(--ease-out-quart);
}
.ss-opt.is-active .ss-sugg__arrow,
.ss-opt:hover .ss-sugg__arrow {
  opacity: 1;
  transform: none;
}

mark.ss-hl {
  background: transparent;
  color: var(--bm-accent-600);
  font-weight: 600;
}

/* Produkttreff (gjenbruker .li-tankegangen, egne klasser for kompakt rad) */
.ss-prod__thumb {
  width: 46px;
  height: 46px;
  border-radius: 9px;
  overflow: hidden;
  flex: none;
  background: var(--bm-navy-100);
}
.ss-prod__thumb img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  display: block;
}
.ss-prod__info {
  display: block;
  flex: 1;
  min-width: 0;
}
.ss-prod__nm {
  display: block;
  font-size: 13.5px;
  font-weight: 600;
  line-height: 1.25;
  color: var(--bm-ink);
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}
.ss-prod__meta {
  display: block;
  font-family: var(--font-mono);
  font-size: 11.5px;
  color: var(--bm-muted);
  margin-top: 3px;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}
.ss-prod__right {
  display: flex;
  flex-direction: column;
  align-items: flex-end;
  gap: 5px;
  flex: none;
  padding-left: 4px;
}
.ss-prod__price {
  font-family: var(--font-mono);
  font-size: 13px;
  font-weight: 600;
  letter-spacing: -0.01em;
  color: var(--bm-navy-800);
  white-space: nowrap;
}

/* Lagerstatus: alltid prikk + tekst, aldri farge alene */
.ss-stock {
  display: inline-flex;
  align-items: center;
  gap: 5px;
  font-size: 11px;
  font-weight: 600;
  padding: 2px 8px 2px 7px;
  border-radius: 999px;
  white-space: nowrap;
}
.ss-stock__dot {
  width: 6px;
  height: 6px;
  border-radius: 50%;
  flex: none;
}
.ss-stock--ok {
  background: var(--bm-ok-bg);
  color: var(--bm-ok-ink);
}
.ss-stock--ok .ss-stock__dot {
  background: var(--bm-ok-dot);
}
.ss-stock--warn {
  background: var(--bm-warn-bg);
  color: var(--bm-warn-ink);
}
.ss-stock--warn .ss-stock__dot {
  background: var(--bm-warn-dot);
}

.ss-divider {
  height: 1px;
  background: var(--bm-line);
  margin: 6px 9px;
}

/* «Se alle treff» i bunnen — marineaksent, aldri rød */
.ss-foot {
  box-sizing: border-box;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 10px;
  width: 100%;
  background: transparent;
  border: 0;
  border-top: 1px solid var(--bm-line);
  border-radius: 0 0 10px 10px;
  padding: 12px 10px 9px;
  margin-top: 5px;
  cursor: pointer;
  text-decoration: none;
  font: inherit;
  font-size: 13px;
  font-weight: 600;
  color: var(--bm-accent-600);
}
.ss-foot.is-active,
.ss-foot:hover {
  background: var(--bm-navy-50);
}
.ss-foot__q {
  color: var(--bm-ink);
}
.ss-foot__arrow {
  flex: none;
  transition: transform 0.14s var(--ease-out-quart);
}
.ss-foot.is-active .ss-foot__arrow,
.ss-foot:hover .ss-foot__arrow {
  transform: translateX(3px);
}

/* Tomt resultat */
.ss-empty {
  padding: 20px 14px 18px;
  text-align: center;
  color: var(--bm-muted);
  font-size: 13.5px;
  line-height: 1.5;
}
.ss-empty strong {
  color: var(--bm-ink);
}

@keyframes ss-in {
  from {
    opacity: 0;
    transform: translateY(-7px) scale(0.985);
  }
  to {
    opacity: 1;
    transform: none;
  }
}
@media (prefers-reduced-motion: reduce) {
  .search-suggest {
    animation: none;
  }
}

/* Handlinger (konto / ønskeliste / kurv) */
.actions {
  display: flex;
  align-items: center;
  gap: 4px;
}
.ibtn {
  position: relative;
  height: 46px;
  min-width: 46px;
  padding: 0 10px;
  border-radius: 12px;
  display: inline-flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: 2px;
  color: var(--bm-ink);
  background: transparent;
  border: 0;
  cursor: pointer;
  transition: background 0.15s;
  font-size: 10.5px;
  font-weight: 600;
}
.ibtn:hover {
  background: var(--bm-navy-50);
}
.ibtn .ico {
  position: relative;
}
.ibtn .lab {
  color: var(--bm-muted);
}
.nav-contact {
  display: flex;
  flex-direction: row;
  align-items: center;
  gap: 10px;
  justify-content: center;
  line-height: 1.25;
  padding: 0 12px 0 8px;
  white-space: nowrap;
  text-decoration: none;
}
.nav-contact__ico {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 32px;
  height: 32px;
  border-radius: 9px;
  background: var(--bm-navy-50);
  color: var(--bm-navy-700);
  flex: 0 0 auto;
  transition:
    background 0.18s var(--ease-out-quart),
    color 0.18s var(--ease-out-quart);
}
.nav-contact__ico svg {
  width: 17px;
  height: 17px;
  display: block;
}
.nav-contact__text {
  display: flex;
  flex-direction: column;
  align-items: flex-end;
  line-height: 1.25;
}
.nav-contact .lab {
  font-family: var(--font-mono);
  font-size: 10px;
  letter-spacing: 0;
  text-transform: uppercase;
  color: var(--bm-muted);
}
.nav-contact strong {
  font-family: var(--font-mono);
  font-size: 14px;
  font-weight: 600;
  color: var(--bm-navy-800);
  letter-spacing: 0;
}
.nav-contact:hover .nav-contact__ico {
  background: var(--bm-accent-600);
  color: #fff;
}
.nav-contact:hover strong {
  color: var(--bm-navy-900);
}
.count {
  position: absolute;
  top: -7px;
  right: -9px;
  min-width: 18px;
  height: 18px;
  padding: 0 5px;
  border-radius: 9px;
  background: var(--bm-cta-500);
  color: #fff;
  font-family: var(--font-mono);
  font-size: 10.5px;
  font-weight: 600;
  display: flex;
  align-items: center;
  justify-content: center;
  line-height: 1;
}
.count[data-count='0'] {
  display: none;
}

/* Kategorilinje */
.catbar {
  background: #fff;
  border-bottom: 1px solid var(--bm-line);
  position: relative;
}
.catbar .wrap {
  height: 52px;
  display: flex;
  align-items: center;
  gap: 2px;
}
.cat-trigger {
  position: relative;
  height: 36px;
  padding: 0 13px;
  border-radius: 9px;
  display: inline-flex;
  align-items: center;
  gap: 7px;
  font-size: 14px;
  font-weight: 600;
  color: var(--bm-ink);
  background: transparent;
  border: 0;
  cursor: pointer;
  white-space: nowrap;
  transition:
    background 0.15s,
    color 0.15s;
}
.cat-trigger:hover {
  background: var(--bm-navy-50);
}
.cat-trigger[data-current='true'] {
  background: var(--bm-navy-50);
  color: var(--bm-navy-900);
}
.cat-trigger .chev {
  transition: transform 0.2s var(--ease-out-quart);
  color: var(--bm-muted);
}
.cat-trigger[aria-expanded='true'] {
  color: var(--bm-navy-900);
}
.cat-trigger[aria-expanded='true'] .chev {
  transform: rotate(180deg);
}
.cat-underline {
  position: absolute;
  bottom: 0;
  height: 2px;
  background: var(--bm-navy-800);
  border-radius: 2px;
  opacity: 0;
  transition:
    opacity 0.2s,
    left 0.25s var(--ease-out-quart),
    width 0.25s var(--ease-out-quart);
}
.catbar .meta {
  margin-left: auto;
  display: flex;
  align-items: center;
  gap: 14px;
  font-size: 13px;
  color: var(--bm-muted);
}
.catbar .meta a {
  display: inline-flex;
  align-items: center;
  gap: 6px;
}
.catbar .meta a:hover {
  color: var(--bm-ink);
}
@media (max-width: 1180px) {
  .catbar .meta {
    display: none;
  }
}

/* Mega-panel */
.mega {
  position: absolute;
  left: 0;
  right: 0;
  top: 100%;
  background: #fff;
  border-top: 1px solid var(--bm-line);
  border-bottom: 1px solid var(--bm-line);
  box-shadow: var(--shadow-float);
}
.mega[hidden] {
  display: none;
}
.mega .wrap {
  display: flex;
  align-items: flex-start;
  gap: 40px;
  padding: 28px 24px 30px;
  height: auto;
}
.mega .wrap > div {
  flex: 1 1 0;
  min-width: 0;
}
.mega h3 {
  font-size: 10.5px;
  font-weight: 700;
  letter-spacing: 0;
  text-transform: uppercase;
  color: var(--bm-muted);
  margin-bottom: 12px;
}
.mega .mlink {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 10px;
  padding: 7px 0;
  font-size: 14px;
  color: var(--bm-ink);
  border-radius: 6px;
}
.mega .mlink:hover {
  color: var(--bm-navy-900);
}
.mega .mlink:hover .mc {
  color: var(--bm-navy-700);
}
.mega .mc {
  font-family: var(--font-mono);
  font-size: 11.5px;
  color: var(--bm-muted);
}
.mega .feat {
  position: relative;
  border-radius: 14px;
  overflow: hidden;
  min-height: 228px;
  flex: 0 0 360px;
  background: var(--bm-navy-900);
  color: #fff;
  display: flex;
  flex-direction: column;
  justify-content: flex-end;
  padding: 20px;
}
.mega .feat img {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  object-fit: cover;
  opacity: 0.62;
}
.mega .feat .scrim {
  position: absolute;
  inset: 0;
  background: linear-gradient(180deg, oklch(19% 0.028 248 / 0.15) 0%, oklch(16% 0.026 248 / 0.9) 100%);
}
.mega .feat > * {
  position: relative;
}
.mega .feat .tag {
  font-size: 11px;
  font-weight: 700;
  letter-spacing: 0;
  text-transform: uppercase;
  color: var(--bm-navy-200);
}
.mega .feat h4 {
  font-size: 22px;
  font-weight: 700;
  margin: 6px 0 2px;
  letter-spacing: 0;
}
.mega .feat p {
  font-size: 13px;
  color: var(--bm-navy-200);
  margin-bottom: 14px;
}

/* Popover (konto / ønskeliste / kurv) */
.pop-wrap {
  position: relative;
}
.pop {
  position: absolute;
  top: calc(100% + 10px);
  right: 0;
  z-index: var(--z-dropdown);
  width: 360px;
  background: #fff;
  border: 1px solid var(--bm-line);
  border-radius: var(--radius-card);
  box-shadow: var(--shadow-float);
  padding: 16px;
}
.pop[hidden] {
  display: none;
}
.pop::before {
  content: '';
  position: absolute;
  top: -7px;
  right: 22px;
  width: 12px;
  height: 12px;
  background: #fff;
  border-left: 1px solid var(--bm-line);
  border-top: 1px solid var(--bm-line);
  transform: rotate(45deg);
}
.pop-head {
  display: flex;
  align-items: center;
  justify-content: space-between;
  margin-bottom: 10px;
}
.pop-head h3 {
  font-size: 14px;
  font-weight: 700;
  color: var(--bm-navy-800);
}
.pop-head .cnt {
  font-family: var(--font-mono);
  font-size: 12px;
  color: var(--bm-muted);
}
.li {
  display: flex;
  gap: 12px;
  padding: 11px 0;
  border-top: 1px solid var(--bm-line);
}
.li .thumb {
  width: 52px;
  height: 52px;
  border-radius: 9px;
  overflow: hidden;
  flex: none;
  background: var(--bm-navy-100);
}
.li .thumb img {
  width: 100%;
  height: 100%;
  object-fit: cover;
}
.li .info {
  flex: 1;
  min-width: 0;
}
.li .nm {
  font-size: 13.5px;
  font-weight: 600;
  color: var(--bm-ink);
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}
.li .meta2 {
  font-size: 12px;
  color: var(--bm-muted);
  margin-top: 2px;
}
.li .pr {
  font-size: 13.5px;
  font-weight: 600;
  color: var(--bm-navy-800);
}
.li .rm {
  width: 28px;
  height: 28px;
  border-radius: 7px;
  display: grid;
  place-items: center;
  color: var(--bm-muted);
  background: transparent;
  border: 0;
  cursor: pointer;
  flex: none;
}
.li .rm:hover {
  background: var(--bm-navy-50);
  color: var(--bm-ink);
}
.pop-foot {
  margin-top: 12px;
  padding-top: 12px;
  border-top: 1px solid var(--bm-line);
}
.pop-empty {
  text-align: center;
  padding: 22px 8px 14px;
}
.pop-empty .ec {
  width: 48px;
  height: 48px;
  border-radius: 50%;
  background: var(--bm-navy-50);
  color: var(--bm-navy-700);
  display: grid;
  place-items: center;
  margin: 0 auto 12px;
}
.pop-empty p {
  color: var(--bm-muted);
  font-size: 14px;
}
.subtot {
  display: flex;
  align-items: center;
  justify-content: space-between;
  margin: 6px 0 12px;
  font-size: 14px;
}
.subtot .v {
  font-weight: 700;
  color: var(--bm-navy-800);
}
.acc-list a {
  display: flex;
  align-items: center;
  gap: 10px;
  padding: 9px 8px;
  border-radius: 9px;
  font-size: 14px;
}
.acc-list a:hover {
  background: var(--bm-navy-50);
}

/* Mobil */
.hamb {
  display: none;
}
.drawer-root[hidden] {
  display: none;
}
.drawer-backdrop {
  position: fixed;
  inset: 0;
  background: oklch(16% 0.026 248 / 0.5);
  z-index: var(--z-drawer-backdrop);
}
.drawer {
  position: fixed;
  top: 0;
  right: 0;
  height: 100%;
  width: min(380px, 88vw);
  background: #fff;
  z-index: var(--z-drawer);
  box-shadow: var(--shadow-float);
  display: flex;
  flex-direction: column;
  overflow: hidden;
}
.drawer-head {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 16px 18px;
  border-bottom: 1px solid var(--bm-line);
}
.drawer-body {
  overflow-y: auto;
  padding: 14px 14px 28px;
  flex: 1;
}
.drawer details {
  border-bottom: 1px solid var(--bm-line);
}
.drawer details > summary {
  list-style: none;
  cursor: pointer;
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 13px 8px;
  font-size: 15px;
  font-weight: 600;
  color: var(--bm-navy-800);
}
.drawer details > summary::-webkit-details-marker {
  display: none;
}
.drawer details[open] > summary .chev {
  transform: rotate(180deg);
}
.drawer .sub a {
  display: block;
  padding: 9px 8px 9px 20px;
  font-size: 14px;
  color: var(--bm-ink);
  border-radius: 8px;
}
.drawer .sub a:hover {
  background: var(--bm-navy-50);
}
.drawer .util {
  display: flex;
  align-items: center;
  gap: 10px;
  padding: 11px 8px;
  font-size: 14px;
  color: var(--bm-ink);
}

/* Sticky-compact ved scroll */
/* Crossfade the separator: hairline border at rest → soft shadow when stuck,
   so the bottom edge is never both a hard line AND a shadow (the "doubled border"). */
.mainbar {
  transition: border-color 0.25s var(--ease-out-quart);
}
.site-header.is-compact .mainbar {
  border-bottom-color: transparent;
}
.site-header.is-compact .topbar .wrap {
  height: 0;
}
.site-header.is-compact .mainbar .wrap {
  height: 62px;
}
.site-header.is-compact .catbar {
  opacity: 0;
  pointer-events: none;
  border-bottom-color: transparent;
}
.site-header.is-compact .catbar .wrap {
  height: 0;
  overflow: hidden;
}
.topbar {
  transition: height 0.25s var(--ease-out-quart);
  overflow: hidden;
}
.topbar .wrap {
  transition: height 0.25s var(--ease-out-quart);
}
.catbar {
  transition:
    opacity 0.22s var(--ease-out-quart),
    border-color 0.22s var(--ease-out-quart);
}
.catbar .wrap {
  transition: height 0.26s var(--ease-out-quart);
}
@media (prefers-reduced-motion: reduce) {
  .site-header,
  .topbar,
  .topbar .wrap,
  .mainbar .wrap,
  .catbar,
  .catbar .wrap {
    transition: none;
  }
}

/* Toast (brukes ved fjerning fra ønskeliste / kurv) */
.toast {
  position: fixed;
  bottom: 20px;
  left: 50%;
  transform: translateX(-50%) translateY(20px);
  z-index: var(--z-toast);
  background: var(--bm-navy-900);
  color: #fff;
  padding: 10px 16px;
  border-radius: 10px;
  font-size: 13px;
  opacity: 0;
  pointer-events: none;
  transition:
    opacity 0.2s,
    transform 0.2s var(--ease-out-quart);
}
.toast.show {
  opacity: 1;
  transform: translateX(-50%) translateY(0);
}

@media (max-width: 1024px) {
  .catbar,
  .search .scope,
  .ibtn .lab,
  .nav-contact {
    display: none;
  }
  .topbar .left,
  .topbar .right {
    display: none;
  }
  .topbar .tb-banner {
    position: static;
    transform: none;
    margin: 0 auto;
    max-width: 100%;
  }
  .mainbar .wrap {
    grid-template-columns: auto 1fr auto;
    gap: 16px;
    height: 68px;
  }
  .hamb {
    display: inline-flex;
  }
  .brand .sub {
    display: none;
  }
}
@media (max-width: 680px) {
  .search {
    display: none;
  }
  .topbar .left .promo {
    display: none;
  }
  .nav-contact {
    display: none;
  }
  .account-action {
    display: none;
  }
  /* Søkefeltet er skjult: fall til to kolonner så handlingene skyves helt til
     høyre i stedet for å klistre seg inntil logoen i midtkolonnen. */
  .mainbar .wrap {
    grid-template-columns: auto 1fr;
    padding: 0 16px;
    gap: 10px;
  }
  .actions {
    gap: 0;
    justify-content: flex-end;
  }
  .brand-logo {
    width: 164px;
  }
}
@media (max-width: 520px) {
  /* Ønskeliste/kurv som bunnark på telefon: en 360px-boks forankret til en
     liten ikonknapp nær høyre kant flyter utenfor skjermen og blir avkuttet.
     Full bredde fra bunnen gir trygg plass, store trykkflater og rullbar liste. */
  .pop {
    position: fixed;
    inset: auto 0 0 0;
    width: auto;
    max-height: 82dvh;
    overflow-y: auto;
    border-radius: 18px 18px 0 0;
    border-width: 1px 0 0;
    padding: 22px 16px calc(16px + env(safe-area-inset-bottom, 0px));
    box-shadow: 0 -14px 44px oklch(24% 0.02 246 / 0.22);
    z-index: var(--z-drawer);
    animation: pop-sheet-up 0.28s var(--ease-out-expo);
  }
  /* pilen blir et drahåndtak øverst på arket */
  .pop::before {
    top: 9px;
    left: 50%;
    right: auto;
    transform: translateX(-50%);
    width: 40px;
    height: 4px;
    border-radius: 999px;
    background: var(--bm-navy-200);
    border: 0;
  }
  .li {
    padding: 13px 0;
  }
  .li .thumb {
    width: 56px;
    height: 56px;
  }
  @keyframes pop-sheet-up {
    from {
      transform: translateY(100%);
    }
    to {
      transform: translateY(0);
    }
  }
}
@media (max-width: 520px) and (prefers-reduced-motion: reduce) {
  .pop {
    animation: none;
  }
}
@media (max-width: 360px) {
  .brand-logo {
    width: 142px;
  }
  .ibtn {
    min-width: 42px;
    padding: 0 8px;
  }
}

/* ─── Brødsmuler (breadcrumb) ─── */
.breadcrumb {
  max-width: 1320px;
  margin: 0 auto;
  padding: 12px 16px;
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 7px;
  list-style: none;
  font-size: 14px;
}
.breadcrumb li {
  display: inline-flex;
  align-items: center;
}
.breadcrumb__link {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  color: var(--bm-muted);
  text-decoration: none;
  border-radius: 6px;
  transition: color 0.15s var(--ease-out-quart);
}
.breadcrumb__link svg {
  width: 15px;
  height: 15px;
  flex: none;
}
.breadcrumb__link:hover {
  color: var(--bm-accent-600);
}
.breadcrumb__link:focus-visible {
  outline: 2px solid var(--bm-accent-600);
  outline-offset: 2px;
}
.breadcrumb__sep {
  color: var(--bm-navy-200);
}
.breadcrumb__sep svg {
  width: 15px;
  height: 15px;
  display: block;
}
.breadcrumb__current {
  color: var(--bm-navy-900);
  font-weight: 600;
}

/* ─── Redusert bevegelse (global) ─── */
@media (prefers-reduced-motion: reduce) {
  html {
    scroll-behavior: auto;
  }
  *,
  *::before,
  *::after {
    animation-duration: 0.001ms !important;
    animation-iteration-count: 1 !important;
    transition-duration: 0.001ms !important;
  }
}
