/* ============================================================
   Toms Arena v2 — felles lag for UNDERSIDENE (runde 2026-10)

   Lastes ETTER shared/v2.css på alle undersider (ikke index.html).
   v2.css eier tokens, headeren og grunnformene. Denne fila eier
   byggeklossene undersidene settes sammen av:

     .v2-hero / .v2-section / .v2-tint / .v2-dark   seksjoner
     .v2-head / .v2-h2 / .v2-eyebrow / .v2-lede      overskrifter
     .v2-grid-2/3/4 / .v2-card / .v2-ico / .v2-num   kort og ikoner
     .v2-panel / .v2-cta / .v2-actions               paneler og knapper
     .v2-facts                                        klinikkfakta

     .reveal                                          myk inntoning (v2-sider.js)

   Ingen innhold her. Alt som står på sidene kommer fra i18n.
   ============================================================ */

/* ---------- Grunnlinje ---------- */
body { font-feature-settings: "ss01" 0; }
.v2-main { display: block; }
::selection { background: var(--sage-2); color: var(--ink, #15191A); }

/* Knappene får v2-formen: pille, 48px høye, tydelig hovedhandling. */
.btn {
  min-height: 48px;
  padding: 0 24px;
  border-radius: var(--r-pill);
  justify-content: center;
  font-size: 15px;
  transition: background-color .25s var(--ease), color .25s var(--ease),
              border-color .25s var(--ease), transform .25s var(--ease);
}
.btn-primary { background: var(--forest-800); color: #fff; }
.btn-primary:hover { background: var(--forest-950); }
.btn-outline { border-color: rgba(21, 25, 26, .22); color: var(--ink); background: transparent; }
.btn-outline:hover { background: var(--ink); border-color: var(--ink); color: #fff; }
.btn:active { transform: translateY(1px); }
.btn:focus-visible { outline: 2px solid var(--green); outline-offset: 3px; }
/* Pila på hovedknappene utenfor headeren: en liten sirkel, samme grep
   som header-CTA-en. Sider som har pila som <span> i markupen bruker
   ikke klassen .v2-arrow og får ikke to piler. */
.v2-arrow::after {
  content: "→";
  display: inline-grid; place-items: center;
  width: 28px; height: 28px; margin-inline-end: -12px;
  border-radius: 50%;
  background: rgba(255, 255, 255, .16);
  font-size: 14px;
  transition: transform .3s var(--ease);
}
.v2-arrow:hover::after { transform: translateX(3px); }
html[dir="rtl"] .v2-arrow::after { content: "←"; }

/* ---------- Etikett, overskrifter ---------- */
.v2-eyebrow {
  display: inline-flex; align-items: center; gap: 10px;
  font-family: 'Poppins', 'JetBrains Mono', ui-monospace, monospace;
  font-size: 11.5px; font-weight: 500;
  letter-spacing: .16em; text-transform: uppercase;
  color: var(--green);
}
.v2-eyebrow::before {
  content: ""; width: 7px; height: 7px; border-radius: 50%;
  background: var(--green);
  box-shadow: 0 0 0 4px var(--sage-2);
  flex: none;
}
.v2-dark .v2-eyebrow { color: #EAF3E6; }
.v2-dark .v2-eyebrow::before { background: var(--sage); box-shadow: 0 0 0 4px rgba(183, 211, 174, .16); }

.v2-hero { padding: clamp(56px, 8vw, 112px) 0 clamp(40px, 5vw, 72px); }
.v2-hero h1 {
  font-family: 'TA Serif', 'Fraunces', Georgia, serif;
  font-weight: 400;
  font-size: clamp(40px, 6.4vw, 82px);
  line-height: 1.0;
  letter-spacing: -.032em;
  margin: 22px 0 26px;
  max-width: 15ch;
  text-wrap: balance;
}
.v2-hero h1 em, .v2-h2 em { font-style: italic; font-weight: 300; color: var(--green); }
.v2-dark .v2-h2 em, .v2-dark h1 em { color: var(--sage); }
.v2-lede {
  font-size: clamp(17px, 1.35vw, 19px);
  line-height: 1.6;
  color: var(--ink-2);
  max-width: 58ch;
  margin: 0;
}
.v2-hero-grid { display: grid; gap: 32px; align-items: end; }
@media (min-width: 960px) {
  .v2-hero-grid { grid-template-columns: minmax(0, 1.25fr) minmax(0, .75fr); gap: 72px; }
}

.v2-section { padding: clamp(64px, 8vw, 112px) 0; }
.v2-section--tight { padding: clamp(40px, 5vw, 72px) 0; }
.v2-tint { background: var(--paper-2); }
.v2-dark { background: var(--forest-950); color: #fff; }
.v2-dark .v2-lede, .v2-dark p { color: rgba(255, 255, 255, .92); }

.v2-head { display: grid; gap: 18px; margin-bottom: clamp(32px, 4vw, 56px); }
.v2-head > * { min-width: 0; }
@media (min-width: 960px) {
  .v2-head--split { grid-template-columns: minmax(0, 1.1fr) minmax(0, .9fr); align-items: end; gap: 72px; }
}
.v2-h2 {
  font-family: 'TA Serif', 'Fraunces', Georgia, serif;
  font-weight: 400;
  font-size: clamp(30px, 4.2vw, 52px);
  line-height: 1.04;
  letter-spacing: -.026em;
  margin: 14px 0 0;
  max-width: 19ch;
  text-wrap: balance;
}
.v2-head p { font-size: 17px; line-height: 1.62; color: var(--ink-2); max-width: 54ch; margin: 0; }
.v2-dark .v2-head p { color: rgba(255, 255, 255, .92); }
.v2-prose p { font-size: 17px; line-height: 1.65; color: var(--ink-2); margin: 0 0 16px; max-width: 64ch; }
.v2-prose p:last-child { margin-bottom: 0; }

/* ---------- Rutenett og kort ---------- */
.v2-grid { display: grid; gap: clamp(14px, 1.6vw, 22px); }
.v2-grid > * { min-width: 0; }
.v2-grid-2 { grid-template-columns: repeat(auto-fit, minmax(min(100%, 340px), 1fr)); }
.v2-grid-3 { grid-template-columns: repeat(auto-fit, minmax(min(100%, 280px), 1fr)); }
.v2-grid-4 { grid-template-columns: repeat(auto-fit, minmax(min(100%, 230px), 1fr)); }

.v2-card {
  position: relative;
  background: #fff;
  border: 1px solid rgba(15, 36, 24, .08);
  border-radius: var(--r-card);
  padding: clamp(24px, 2.6vw, 34px);
  box-shadow: var(--shadow-1);
  transition: transform .45s var(--ease), box-shadow .45s var(--ease), border-color .45s var(--ease);
}
a.v2-card { display: block; color: inherit; }
a.v2-card:hover, .v2-card--lift:hover { transform: translateY(-3px); box-shadow: var(--shadow-2); }
a.v2-card:focus-visible { outline: 2px solid var(--green); outline-offset: 3px; }
.v2-card h3 {
  font-family: 'TA Serif', 'Fraunces', Georgia, serif;
  font-weight: 400; font-size: clamp(20px, 1.8vw, 24px);
  line-height: 1.2; letter-spacing: -.012em;
  margin: 0 0 10px; color: var(--ink);
}
.v2-card p { font-size: 15.5px; line-height: 1.62; color: var(--ink-2); margin: 0; }
.v2-card p + p { margin-top: 10px; }
.v2-card--flat { box-shadow: none; }
.v2-card--sage { background: var(--sage-2); border-color: transparent; box-shadow: none; }
.v2-card--dark { background: var(--forest-950); border-color: transparent; color: #fff; }
.v2-card--dark h3 { color: #fff; }
.v2-card--dark p { color: rgba(255, 255, 255, .92); }
.v2-dark .v2-card { background: rgba(21, 25, 26, .08); border-color: rgba(255, 255, 255, .1); box-shadow: none; }
.v2-dark .v2-card h3 { color: #fff; }
.v2-dark .v2-card p { color: rgba(255, 255, 255, .97); }

/* Ikonflis: rund, salvie, linjeikon 1.6px. */
.v2-ico {
  width: 48px; height: 48px; border-radius: 50%;
  display: grid; place-items: center;
  background: var(--sage-2); color: var(--forest-800);
  margin-bottom: 22px; flex: none;
}
.v2-ico svg {
  width: 24px; height: 24px;
  fill: none; stroke: currentColor; stroke-width: 1.6;
  stroke-linecap: round; stroke-linejoin: round;
}
.v2-dark .v2-ico, .v2-card--dark .v2-ico { background: rgba(183, 211, 174, .14); color: var(--sage); }

/* Levende ikoner (v2-sider.js setter .ikon-liv og .is-live). Strekene tegnes
   inn, så puster flisen rolig med en myk ring, og nodene i nettverksikonet
   lyser opp etter tur. */
@media (prefers-reduced-motion: no-preference) {
  .v2-ico.ikon-liv { position: relative; }
  .v2-ico.ikon-liv.ico-pulse { animation: none; }
  .v2-ico.ikon-liv svg * { stroke-dasharray: 1 1; stroke-dashoffset: 1; }
  .v2-ico.ikon-liv.is-live svg * {
    animation: ikonTegn 1.1s cubic-bezier(.65, 0, .35, 1) forwards;
    animation-delay: calc(.1s + var(--k, 0) * 90ms);
  }
  @keyframes ikonTegn { to { stroke-dashoffset: 0; } }
  .v2-ico.ikon-liv::after {
    content: ""; position: absolute; inset: 0; border-radius: inherit; pointer-events: none;
    box-shadow: 0 0 0 0 rgba(74, 102, 80, .28); opacity: 0;
  }
  .v2-card--dark .v2-ico.ikon-liv::after, .v2-dark .v2-ico.ikon-liv::after { box-shadow: 0 0 0 0 rgba(183, 211, 174, .3); }
  .v2-ico.ikon-liv.is-live::after { animation: ikonRing 4.8s ease-out infinite; animation-delay: calc(1.6s + var(--n, 0) * .6s); }
  @keyframes ikonRing {
    0% { opacity: 1; box-shadow: 0 0 0 0 rgba(74, 102, 80, .28); }
    45%, 100% { opacity: 0; box-shadow: 0 0 0 12px rgba(74, 102, 80, 0); }
  }
  .v2-ico.ikon-liv.is-live svg { animation: ikonPust 4.8s ease-in-out infinite; animation-delay: calc(1.6s + var(--n, 0) * .6s); transform-origin: center; }
  @keyframes ikonPust { 0%, 100% { transform: scale(1); } 22% { transform: scale(1.1); } 50% { transform: scale(1); } }
  /* Nettverksikonet: sirklene fylles og slukkes etter tur, som signaler i et nett. */
  .v2-ico.ikon-liv.ico-pulse.is-live svg circle {
    animation: ikonTegn 1.1s cubic-bezier(.65, 0, .35, 1) forwards, ikonNode 3.6s ease-in-out infinite;
    animation-delay: calc(.1s + var(--k, 0) * 90ms), calc(1.4s + var(--k, 0) * .35s);
  }
  @keyframes ikonNode { 0%, 30%, 100% { fill: transparent; } 12% { fill: currentColor; } }
}

/* Nummerbrikke: mono i en salviepille. */
.v2-num {
  display: inline-flex; align-items: center; justify-content: center;
  min-width: 40px; height: 28px; padding: 0 12px;
  border-radius: var(--r-pill);
  background: var(--sage-2); color: var(--forest-800);
  font-family: 'Poppins', 'JetBrains Mono', ui-monospace, monospace;
  font-size: 12px; letter-spacing: .08em;
  margin-bottom: 18px;
}
.v2-dark .v2-num, .v2-card--dark .v2-num { background: rgba(21, 25, 26, .16); color: #EAF3E6; }

/* ---------- Paneler og CTA ---------- */
.v2-panel {
  border-radius: var(--r-panel);
  padding: clamp(28px, 5vw, 64px);
  overflow: hidden;
  position: relative;
  isolation: isolate;
}
.v2-panel.v2-dark { box-shadow: var(--shadow-2); }
.v2-cta { text-align: center; }
.v2-cta .v2-h2 { margin-inline: auto; max-width: 18ch; }
.v2-cta p { margin: 18px auto 0; max-width: 52ch; font-size: 17px; line-height: 1.6; }
.v2-actions { display: flex; flex-wrap: wrap; gap: 12px; margin-top: 30px; }
.v2-cta .v2-actions { justify-content: center; }
.v2-dark .btn-primary { background: #fff; color: var(--ink, #15191A); }
.v2-dark .btn-primary:hover { background: var(--sage-2); }
.v2-dark .btn-primary.v2-arrow::after { background: var(--forest-950); color: #fff; }
.v2-dark .btn-outline { color: #fff; border-color: rgba(255, 255, 255, .32); }
.v2-dark .btn-outline:hover { background: #fff; color: var(--ink, #15191A); border-color: #fff; }
/* Myk lysflekk bak mørke paneler. Bare dekor, aldri tekst oppå. */
.v2-glow::before {
  content: ""; position: absolute; z-index: -1;
  width: 520px; height: 520px; border-radius: 50%;
  right: -160px; top: -220px;
  background: radial-gradient(closest-side, rgba(183, 211, 174, .18), transparent);
  pointer-events: none;
}
@media (max-width: 640px) {
  .v2-actions { flex-direction: column; align-items: stretch; }
}

/* ---------- Sitat ---------- */
.v2-quote { margin: 0; }
.v2-quote svg { width: 34px; height: 26px; fill: var(--sage); margin-bottom: 18px; display: block; }
.v2-quote blockquote {
  margin: 0;
  font-family: 'TA Serif', 'Fraunces', Georgia, serif;
  font-style: italic; font-weight: 300;
  font-size: clamp(22px, 2.6vw, 32px);
  line-height: 1.3; letter-spacing: -.01em;
  max-width: 30ch;
}
.v2-quote figcaption, .v2-quote cite {
  display: block; margin-top: 18px;
  font-family: 'Poppins', 'JetBrains Mono', ui-monospace, monospace;
  font-style: normal; font-size: 11.5px; letter-spacing: .14em; text-transform: uppercase;
  color: var(--muted);
}
.v2-dark .v2-quote figcaption, .v2-dark .v2-quote cite { color: rgba(255, 255, 255, .97); }

/* ---------- Klinikkfakta ---------- */
.v2-facts { display: grid; gap: clamp(14px, 1.6vw, 22px); grid-template-columns: repeat(auto-fit, minmax(min(100%, 260px), 1fr)); margin: 0; }
.v2-fact { display: flex; gap: 16px; align-items: flex-start; }
.v2-fact .v2-ico { margin: 0; }
.v2-fact dt {
  font-family: 'Poppins', 'JetBrains Mono', ui-monospace, monospace;
  font-size: 11px; letter-spacing: .16em; text-transform: uppercase;
  color: var(--green); margin: 4px 0 8px;
}
.v2-fact dd { margin: 0; font-size: 15.5px; line-height: 1.55; color: var(--ink-2); white-space: pre-line; }
.v2-fact dd a { color: var(--ink); border-bottom: 1px solid rgba(21, 25, 26, .25); }
.v2-fact dd a:hover { color: var(--green); border-bottom-color: var(--green); }

/* ---------- Tilbakelenke (pille) ---------- */
.v2-back {
  display: inline-flex; align-items: center; gap: 10px;
  min-height: 44px; padding: 0 18px 0 8px;
  border-radius: var(--r-pill);
  background: var(--paper-2);
  font-family: 'Poppins', 'JetBrains Mono', ui-monospace, monospace;
  font-size: 11.5px; letter-spacing: .14em; text-transform: uppercase;
  color: var(--forest-800);
  transition: background-color .25s var(--ease);
}
.v2-back::before {
  content: "←"; display: inline-grid; place-items: center;
  width: 30px; height: 30px; border-radius: 50%;
  background: #fff; color: var(--ink, #15191A); font-size: 14px;
  letter-spacing: 0;
  transition: transform .3s var(--ease);
}
.v2-back:hover { background: var(--sage-2); }
.v2-back:hover::before { transform: translateX(-2px); }
html[dir="rtl"] .v2-back::before { content: "→"; }

/* ---------- Myk inntoning ----------
   Skjules bare når shared/v2-sider.js har kjørt og satt html.v2-rv,
   og aldri med redusert bevegelse. Uten JS er alt synlig. */
@media (prefers-reduced-motion: no-preference) {
  html.v2-rv .reveal {
    opacity: 0; transform: translateY(14px);
    transition: opacity .7s var(--ease), transform .7s var(--ease);
    transition-delay: var(--d, 0s);
  }
  html.v2-rv .reveal.is-in { opacity: 1; transform: none; }
}

/* ---------- Mobil ---------- */
@media (max-width: 640px) {
  .container { padding: 0 20px; }
  .v2-hero h1 { font-size: clamp(36px, 10.5vw, 48px); }
  .v2-card { border-radius: 20px; }
  .v2-panel { border-radius: 24px; }

}

/* ============================================================
   QA-runden 2026-10-11: småfeil som gikk igjen på tvers av sidene.
   ============================================================ */

/* Overskrifter brekker jevnt: ingen enslige ord på siste linje. */
h1, h2, h3 { text-wrap: balance; }

/* Pila i hvit knapp på mørkt panel: sirkelen var hvit på hvitt og
   forsvant. Samme løsning som .v2-dark har. */
.hist-cta .btn-primary.v2-arrow::after,
.beh-cta .btn-primary.v2-arrow::after { background: var(--forest-950); color: #fff; }

/* Ikonflisene løfter seg også når kortet de står i får hover. */
@media (prefers-reduced-motion: no-preference) {
  .v2-card:hover .ico-live, .v2-fact:hover .ico-live { transform: translateY(-2px) rotate(-4deg); }
}

/* Brødtekst minst 16px på mobil (var 15-15,5px i kort, fakta og CTA). */
@media (max-width: 640px) {
  .v2-card p, .v2-fact dd, .v2-cta p, .beh-cta-note,
  .tf-notice p, .tomf-aside p, .kt-form-head p:not(.kt-label),
  .ak-step-card p, .ak-pillar p, .ak-who-item p { font-size: 16px; }
  .tf-hint, .tf-consent { font-size: 14px; }

}

/* Sitatsignaturen i et mørkt kort (om-klinikken) fikk den mørke
   standardfargen fra .v2-quote figcaption: 2,6:1 mot forest-950.
   Nå samme lyse tone som i .v2-dark, rundt 7:1. */
.v2-card--dark.v2-quote figcaption, .v2-card--dark.v2-quote cite { color: rgba(255, 255, 255, .92); }

/* Rutenett på nettbrett: tre kort i to spalter ga et foreldreløst kort
   med tom flate ved siden av (butikk, om-klinikken, priser og
   om-toms-metode på 768). Mellom 600 og 959 står de i to spalter, og
   et siste kort uten partner tar hele raden. Fire kort i tre spalter
   (1024) ble på samme måte 3 + 1; de står nå 2 + 2 til det er plass
   til fire. */
@media (min-width: 600px) and (max-width: 959px) {
  .v2-grid-3, .v2-facts { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .v2-grid-3:not(.tm-journey) > :last-child:nth-child(odd),
  .v2-facts > :last-child:nth-child(odd),
  .pris-notes > :last-child:nth-child(odd) { grid-column: 1 / -1; }
}
@media (min-width: 600px) and (max-width: 1099px) {
  .v2-grid-4 { grid-template-columns: repeat(2, minmax(0, 1fr)); }
}

/* ---------- Runde 2026-10-17: en hovedknapp på hele nettsiden ----------
   Samme som forsidens: skoggrønn pille, 52 px høy, med hvit pilsirkel.
   Mørke seksjoner (.v2-dark) beholder sin hvite variant. */
.btn-primary { background: var(--forest-950); color: #fff; min-height: 52px; }
.btn-primary:hover { background: var(--forest-800); color: #fff; }
.v2-arrow::after { width: 36px; height: 36px; margin-inline-end: -14px; background: #fff; color: var(--ink, #15191A); }
