/* Hjelpeverktøy – sidelag oppå designpakka. Bare tokens fra palett.css, ingen egne farger. */

*, *::before, *::after { box-sizing: border-box; }
html { scroll-behavior: smooth; }
body {
  margin: 0;
  background: var(--surface-base);
  color: var(--ink);
  font-family: var(--font-sans);
  font-size: 17px;
  line-height: 1.6;
}
h1, h2, h3 { font-family: var(--font-display); color: var(--ink); line-height: 1.2; margin: 0 0 var(--space-3); }
h1 { font-size: 32px; font-weight: 800; letter-spacing: -0.02em; }
h2 { font-size: 24px; font-weight: 700; }
h3 { font-size: 19px; font-weight: 700; }
p { margin: 0 0 var(--space-3); max-width: 65ch; }
a { color: var(--brand-accent); text-decoration: underline; text-underline-offset: 3px; }
a:hover { color: var(--brand-hover); }
a:focus-visible, button:focus-visible {
  outline: none;
  box-shadow: 0 0 0 2px var(--surface-base), 0 0 0 4px var(--focus);
  border-radius: var(--radius-sm);
}
strong { color: var(--ink); }

/* Hopp-lenke for tastatur og skjermleser */
.hopp {
  position: absolute; left: var(--space-3); top: -60px;
  padding: var(--space-2) var(--space-3);
  background: var(--brand); color: var(--on-brand);
  border-radius: var(--radius-md); z-index: 10;
}
.hopp:focus { top: var(--space-3); }

/* Toppmeny */
.topp { position: sticky; top: 0; z-index: 5; }
.topp .tw-nav__brand { text-decoration: none; }
.meny { display: flex; flex-wrap: wrap; gap: var(--space-1); }
.meny .tw-nav__link { text-decoration: none; min-height: 44px; display: inline-flex; align-items: center; }
.tema-knapp { min-height: 44px; }

/* Innhold */
main { padding: 0 16px; max-width: 1040px; margin: 0 auto; }
.del { padding: var(--space-8) 0; border-top: 1px solid var(--border); }
.del--ramme {
  background: var(--surface-raised);
  border: 1px solid var(--border);
  border-radius: var(--radius-lg);
  padding: var(--space-6) var(--space-5);
  margin: var(--space-6) 0;
}
.hero { padding: var(--space-10) 0 var(--space-8); }
.ingress { font-size: 19px; color: var(--ink-muted); }
.ingress strong { color: var(--ink); }

/* Knapper: store trykkflater (≥ 48 px) */
.knapperad { display: flex; flex-wrap: wrap; gap: var(--space-3); margin-top: var(--space-5); }
.tw-btn--lg { min-height: 48px; text-decoration: none; }
.tw-btn.is-disabled { pointer-events: none; }
@media (max-width: 480px) {
  .knapperad .tw-btn, .kort-knapper .tw-btn { width: 100%; }
}

/* Verktøykort */
.kort-rad { display: grid; gap: var(--space-4); grid-template-columns: 1fr; }
@media (min-width: 720px) { .kort-rad { grid-template-columns: repeat(3, 1fr); } .kort-rad--to { grid-template-columns: repeat(2, 1fr); } }
.verktoykort { display: flex; flex-direction: column; }
.verktoykort .tw-card__body { font-size: 16px; line-height: 24px; margin-bottom: var(--space-3); }
.kort-topp { display: flex; align-items: center; justify-content: space-between; gap: var(--space-3); margin-bottom: var(--space-3); }
.kort-topp img, .ikon-plass { width: 48px; height: 48px; border-radius: var(--radius-md); flex: none; }
.ikon-plass { background: var(--surface-sunken); border: 1px dashed var(--border-strong); }
.kort-knapper { margin-top: auto; padding-top: var(--space-2); }
.tw-badge--soft { background: var(--surface-sunken); color: var(--ink-muted); }

/* Lister */
.punkter, .liste { padding-left: 1.2em; margin: 0 0 var(--space-4); }
.punkter li, .liste li { margin-bottom: var(--space-2); max-width: 65ch; }
.liste { font-size: 16px; line-height: 24px; }
.hjelpeliste { list-style: none; padding: 0; margin: 0; }
.hjelpeliste li {
  padding: var(--space-3) 0;
  border-bottom: 1px solid var(--border);
  display: flex; flex-direction: column; gap: var(--space-1);
  max-width: 65ch;
}
.hjelpeliste li > a { font-weight: 700; font-size: 18px; min-height: 44px; display: inline-flex; align-items: center; }
.hjelpeliste span { color: var(--ink-muted); }
.akutt { margin-top: var(--space-5); font-weight: 600; }

/* Bunn */
.bunn { padding: var(--space-8) 16px; border-top: 1px solid var(--border); color: var(--ink-muted); max-width: 1040px; margin: 0 auto; }
.bunn p { margin-bottom: var(--space-2); }
.bunn-logo { vertical-align: -2px; margin-right: 4px; }
.liten { font-size: 14px; }

@media (prefers-reduced-motion: reduce) { html { scroll-behavior: auto; } }
