/* Tripnora – public site (tripnora.se). Static, no build step.
   Brand tokens are copied from frontend/src/index.css (app identity), not imported:
   the marketing site and the app stay fully decoupled. */

/* Self-hosted fonts: upstream WOFF2, unmodified, SIL OFL 1.1 (assets/fonts/OFL-*.txt).
   Only the weights the site uses. No third-party font requests. */
@font-face {
  font-family: "Sora"; font-style: normal; font-weight: 600; font-display: swap;
  src: url("assets/fonts/Sora-SemiBold.woff2") format("woff2");
}
@font-face {
  font-family: "Public Sans"; font-style: normal; font-weight: 400; font-display: swap;
  src: url("assets/fonts/PublicSans-Regular.woff2") format("woff2");
}
@font-face {
  font-family: "Public Sans"; font-style: normal; font-weight: 500; font-display: swap;
  src: url("assets/fonts/PublicSans-Medium.woff2") format("woff2");
}
@font-face {
  font-family: "Public Sans"; font-style: normal; font-weight: 600; font-display: swap;
  src: url("assets/fonts/PublicSans-SemiBold.woff2") format("woff2");
}

:root {
  --bg: hsl(40 30% 97%);
  --bg-warm: hsl(40 26% 93.5%);
  --surface: #fff;
  --ink: hsl(215 28% 13%);
  --ink-2: hsl(215 14% 32%);
  --ink-3: hsl(215 12% 40%);
  --line: hsl(200 16% 87%);
  --line-soft: hsl(200 16% 91%);

  --teal: hsl(187 58% 22%);
  --teal-600: hsl(187 52% 28%);
  --teal-tint: hsl(187 32% 93%);
  --deep: hsl(189 52% 11%);
  --deep-2: hsl(189 40% 15.5%);
  --deep-line: hsl(189 26% 24%);
  --on-deep: hsl(40 30% 96%);
  --on-deep-2: hsl(190 14% 74%);

  --orange: hsl(28 90% 52%);
  --orange-ink: hsl(24 86% 35%);
  --orange-tint: hsl(32 90% 94%);
  --ok: hsl(152 52% 30%);

  --font-display: "Sora", system-ui, sans-serif;
  --font-body: "Public Sans", system-ui, -apple-system, "Segoe UI", sans-serif;

  --radius-sm: 10px;
  --radius: 16px;
  --radius-lg: 24px;
  --radius-xl: 32px;
  --shadow-sm: 0 1px 2px hsl(215 30% 15% / 0.06);
  --shadow: 0 1px 2px hsl(215 30% 15% / 0.05), 0 12px 32px -12px hsl(215 30% 15% / 0.14);
  --shadow-lg: 0 2px 4px hsl(215 30% 15% / 0.04), 0 32px 64px -24px hsl(195 40% 15% / 0.28);

  --gutter: clamp(20px, 5vw, 40px);
  --section-y: clamp(80px, 11vw, 144px);
  --header-h: 64px;
  --ease: cubic-bezier(.2, .7, .2, 1);
}

/* ---------- base ---------- */
*, *::before, *::after { box-sizing: border-box; }
html { -webkit-text-size-adjust: 100%; scroll-padding-top: calc(var(--header-h) + 8px); }
@media (prefers-reduced-motion: no-preference) { html { scroll-behavior: smooth; } }
body {
  margin: 0;
  background: var(--bg);
  color: var(--ink);
  font-family: var(--font-body);
  font-size: 1.0625rem;
  line-height: 1.65;
  -webkit-font-smoothing: antialiased;
  text-rendering: optimizeLegibility;
  overflow-x: clip;
}
img, svg { display: block; max-width: 100%; }
h1, h2, h3, p, ul, ol, figure { margin: 0; }
ul, ol { padding: 0; list-style: none; }
a { color: inherit; }
button { font: inherit; }
h1, h2, h3, .h3-like { font-family: var(--font-display); font-weight: 600; color: var(--ink); text-wrap: balance; }
p { text-wrap: pretty; }

:focus-visible { outline: 2px solid var(--teal); outline-offset: 3px; border-radius: 6px; }
.ops :focus-visible, .final :focus-visible { outline-color: var(--orange); }

.visually-hidden {
  position: absolute !important; width: 1px; height: 1px; padding: 0; margin: -1px;
  overflow: hidden; clip: rect(0 0 0 0); white-space: nowrap; border: 0;
}
.skip-link {
  position: absolute; left: 12px; top: -48px; z-index: 100;
  background: var(--ink); color: #fff; padding: 10px 14px; border-radius: 8px;
  text-decoration: none; font-weight: 600;
}
.skip-link:focus { top: 12px; }

.container { width: 100%; max-width: 1240px; margin-inline: auto; padding-inline: var(--gutter); }
.section { padding-block: var(--section-y); }

/* ---------- type ---------- */
.eyebrow {
  font-family: var(--font-body);
  font-size: .8125rem; font-weight: 600; letter-spacing: .12em; text-transform: uppercase;
  color: var(--teal-600); margin-bottom: 18px;
}
.eyebrow-on-dark { color: hsl(28 92% 66%); }
h1 {
  font-size: clamp(2.6rem, 1.55rem + 4.6vw, 5.1rem);
  line-height: 1.02; letter-spacing: -0.04em;
}
.h1-quiet { color: var(--teal); }
h2 {
  font-size: clamp(2rem, 1.35rem + 2.7vw, 3.4rem);
  line-height: 1.08; letter-spacing: -0.03em;
}
h3 { font-size: 1.1875rem; line-height: 1.3; letter-spacing: -0.01em; }
.h3-like { font-size: clamp(1.375rem, 1.1rem + 1vw, 1.75rem); line-height: 1.25; letter-spacing: -0.02em; }
.lead { font-size: clamp(1.0625rem, 1rem + .35vw, 1.25rem); line-height: 1.6; color: var(--ink-2); }
.section-head { max-width: 760px; margin-bottom: clamp(40px, 6vw, 72px); }

/* ---------- buttons ---------- */
.btn {
  display: inline-flex; align-items: center; justify-content: center; gap: 8px;
  min-height: 48px; padding: 12px 22px; border-radius: 999px;
  font-family: var(--font-body); font-weight: 600; font-size: 1rem; line-height: 1.2;
  text-decoration: none; border: 1px solid transparent; cursor: pointer;
  transition: background-color .2s var(--ease), color .2s var(--ease), border-color .2s var(--ease), transform .2s var(--ease);
}
.btn:active { transform: translateY(1px); }
.btn-sm { min-height: 40px; padding: 8px 18px; font-size: .9375rem; }
.btn-primary { background: var(--teal); color: #fff; }
.btn-primary:hover { background: hsl(187 60% 17%); }
.btn-ghost { color: var(--teal); padding-inline: 14px; }
.btn-ghost:hover { background: var(--teal-tint); }
.btn-ghost .arrow { transition: transform .2s var(--ease); }
.btn-ghost:hover .arrow { transform: translateX(3px); }
.btn-secondary { background: transparent; color: var(--teal); border-color: hsl(187 30% 72%); }
.btn-secondary:hover { border-color: var(--teal); background: var(--teal-tint); }
.btn-light { background: var(--on-deep); color: var(--deep); }
.btn-light:hover { background: #fff; }
.btn-outline-light { color: var(--on-deep); border-color: hsl(190 20% 40%); }
.btn-outline-light:hover { border-color: var(--on-deep); }
.cta-row { display: flex; flex-wrap: wrap; gap: 12px; align-items: center; }

/* ---------- header ---------- */
.site-header {
  position: sticky; top: 0; z-index: 50;
  background: hsl(40 30% 97% / .86);
  -webkit-backdrop-filter: saturate(160%) blur(14px);
  backdrop-filter: saturate(160%) blur(14px);
  border-bottom: 1px solid transparent;
  transition: border-color .25s var(--ease);
}
.site-header.is-scrolled, .site-header.is-open { border-bottom-color: var(--line-soft); }
.header-inner { display: flex; align-items: center; height: var(--header-h); gap: 24px; }
.brand {
  display: inline-flex; align-items: center; gap: 10px; text-decoration: none;
  font-family: var(--font-display); font-weight: 600; font-size: 1.1875rem; letter-spacing: -0.02em;
  color: var(--ink);
}
.brand img { border-radius: 8px; }

.header-mobile { margin-left: auto; display: flex; align-items: center; gap: 4px; }
.nav-login-compact {
  font-weight: 600; font-size: .9375rem; color: var(--teal); text-decoration: none;
  padding: 10px 12px; border-radius: 999px;
}
.menu-button {
  width: 44px; height: 44px; display: grid; place-items: center;
  border: 0; border-radius: 999px; background: transparent; color: var(--ink); cursor: pointer;
}
.menu-button:hover { background: var(--teal-tint); }
.menu-icon { width: 20px; height: 12px; position: relative; display: block; }
.menu-icon span {
  position: absolute; left: 0; right: 0; height: 2px; border-radius: 2px; background: currentColor;
  transition: transform .25s var(--ease), top .25s var(--ease);
}
.menu-icon span:first-child { top: 0; }
.menu-icon span:last-child { top: 10px; }
.is-open .menu-icon span:first-child { top: 5px; transform: rotate(45deg); }
.is-open .menu-icon span:last-child { top: 5px; transform: rotate(-45deg); }

/* Mobile nav: panel under the header */
.nav { display: none; }
.is-open .nav {
  display: block;
  position: absolute; left: 0; right: 0; top: 100%;
  background: var(--bg);
  border-bottom: 1px solid var(--line-soft);
  padding: 8px var(--gutter) 28px;
  max-height: calc(100dvh - var(--header-h)); overflow-y: auto;
  box-shadow: 0 24px 40px -24px hsl(215 30% 15% / .25);
}
.nav-links a {
  display: block; padding: 16px 4px; text-decoration: none;
  font-family: var(--font-display); font-size: 1.375rem; font-weight: 600; letter-spacing: -0.02em;
  border-bottom: 1px solid var(--line-soft);
}
.nav-actions { display: flex; flex-direction: column; gap: 12px; margin-top: 24px; }
.nav-actions .btn { width: 100%; min-height: 52px; font-size: 1rem; }
.nav-login {
  display: inline-flex; align-items: center; justify-content: center; min-height: 52px;
  border: 1px solid var(--line); border-radius: 999px; text-decoration: none; font-weight: 600; color: var(--teal);
}

@media (min-width: 960px) {
  :root { --header-h: 76px; }
  .header-mobile { display: none; }
  .nav, .is-open .nav {
    display: flex; align-items: center; flex: 1;
    position: static; padding: 0; background: none; border: 0; box-shadow: none; max-height: none; overflow: visible;
  }
  .nav-links { display: flex; gap: 4px; margin-inline: auto; }
  .nav-links a {
    padding: 8px 14px; border: 0; border-radius: 999px;
    font-family: var(--font-body); font-size: .9375rem; font-weight: 500; letter-spacing: 0; color: var(--ink-2);
    transition: color .2s var(--ease), background-color .2s var(--ease);
  }
  .nav-links a:hover { color: var(--ink); background: hsl(40 20% 91%); }
  .nav-actions { flex-direction: row; align-items: center; gap: 8px; margin: 0; }
  .nav-actions .btn { width: auto; min-height: 40px; font-size: .9375rem; }
  .nav-login { min-height: 40px; padding: 8px 16px; border: 0; font-size: .9375rem; }
  .nav-login:hover { background: var(--teal-tint); }
}

/* ---------- hero ---------- */
.hero { padding-block: clamp(32px, 3vw, 40px) clamp(64px, 9vw, 120px); overflow-x: clip; }
.hero-grid { display: grid; gap: 48px; }
.hero-copy .lead { margin-top: 24px; max-width: 34em; }
.hero-copy .cta-row { margin-top: 32px; }
.phase-line {
  display: flex; flex-wrap: wrap; align-items: center; gap: 8px 0;
  margin-top: 36px; font-size: .875rem; font-weight: 500; color: var(--ink-3);
}
.phase-line li { display: inline-flex; align-items: center; }
.phase-line li + li::before {
  content: ""; width: 4px; height: 4px; border-radius: 50%; background: hsl(200 12% 70%); margin-inline: 12px;
}
.phase-line .is-change { color: var(--orange-ink); }
@media (max-width: 479px) {
  .phase-line { font-size: .8125rem; flex-wrap: nowrap; white-space: nowrap; }
  .phase-line li + li::before { margin-inline: 8px; }
  .hero .btn-ghost { padding-inline: 4px; }
}

.hero-visual { position: relative; }
.mock-note { margin-top: 14px; font-size: .75rem; color: var(--ink-3); }
.hero-visual .mock-note { text-align: center; }

/* shared mock pieces */
.tile {
  background: var(--surface); border: 1px solid var(--line-soft); border-radius: 14px; padding: 14px 16px;
}
.tile-label { font-size: .6875rem; font-weight: 600; letter-spacing: .08em; text-transform: uppercase; color: var(--ink-3); }
.tile-time { font-family: var(--font-display); font-size: 1.75rem; font-weight: 600; letter-spacing: -0.03em; line-height: 1.1; margin-top: 6px; }
.tile-num { font-family: var(--font-display); font-size: 1.75rem; font-weight: 600; letter-spacing: -0.03em; line-height: 1.1; margin-top: 6px; }
.tile-num span { font-size: 1rem; color: var(--ink-3); font-weight: 500; letter-spacing: 0; }
.tile-strong { font-weight: 600; font-size: .9375rem; margin-top: 4px; }
.tile-sub { font-size: .8125rem; color: var(--ink-3); margin-top: 2px; }
.tone-warn { color: var(--orange-ink); font-weight: 600; }
.tile-next { background: var(--teal); border-color: var(--teal); color: #fff; }
.tile-next .tile-label { color: hsl(185 30% 78%); }
.tile-next .tile-sub { color: hsl(185 25% 84%); }
.tile-important { background: var(--orange-tint); border-color: hsl(32 70% 85%); }
.tile-important .tile-label, .tile-important .tile-sub { color: var(--orange-ink); }
.bar { height: 6px; border-radius: 6px; background: hsl(200 16% 90%); overflow: hidden; margin-top: 10px; }
.bar span {
  display: block; height: 100%; width: var(--v); border-radius: inherit; background: var(--ok);
  transform-origin: left; transition: transform 1.2s var(--ease) .3s;
}
.js .reveal:not(.is-visible) .bar span { transform: scaleX(0); }
.mock-pill {
  display: inline-flex; align-items: center; gap: 6px; padding: 4px 10px; border-radius: 999px;
  background: hsl(152 45% 92%); color: var(--ok); font-size: .75rem; font-weight: 600;
}
.mock-pill i { width: 6px; height: 6px; border-radius: 50%; background: currentColor; }
.mock-kicker { font-size: .75rem; color: var(--ink-3); font-weight: 500; }
.mock-title { font-family: var(--font-display); font-weight: 600; font-size: 1.25rem; letter-spacing: -0.02em; }

/* mobile phone composition (default) */
.mock-dash { display: none; }
.mock-phone {
  max-width: 340px; margin-inline: auto;
  background: hsl(200 18% 95%);
  border: 1px solid var(--line); border-radius: var(--radius-xl);
  padding: 10px; box-shadow: var(--shadow-lg);
}
.phone-inner { background: var(--bg); border-radius: 24px; padding: 18px 14px 16px; display: grid; gap: 10px; }
.phone-top { display: flex; align-items: center; justify-content: space-between; padding: 0 2px 4px; }
.phone-next { display: flex; align-items: center; gap: 14px; margin-top: 4px; }
.phone-next .tile-time { font-size: 2.25rem; margin: 0; }
.phone-row { display: grid; grid-template-columns: 1fr 1fr; gap: 10px; }

@media (min-width: 640px) {
  .mock-phone { display: none; }
  .mock-dash {
    display: grid; grid-template-columns: 1fr;
    background: var(--surface); border: 1px solid var(--line); border-radius: var(--radius-lg);
    box-shadow: var(--shadow-lg); overflow: hidden;
  }
  .mock-side { display: none; }
  .mock-main { padding: 22px; background: hsl(40 25% 98%); display: grid; gap: 14px; }
  .mock-top { display: flex; justify-content: space-between; align-items: flex-start; }
  .mock-tiles { display: grid; grid-template-columns: 1.3fr 1fr 1fr; grid-template-rows: auto auto; gap: 12px; }
  .mock-tiles .tile-next { grid-row: span 2; display: flex; flex-direction: column; }
  .mock-tiles .tile-next .tile-time { font-size: 2.75rem; margin-top: auto; }
  .mock-tiles .tile-important { grid-column: span 2; }
  .mock-program { background: var(--surface); border: 1px solid var(--line-soft); border-radius: 14px; padding: 14px 16px 6px; }
  .mock-program ul { margin-top: 8px; }
  .mock-program li {
    display: grid; grid-template-columns: 56px 1fr auto; align-items: center;
    padding: 10px 0; border-top: 1px solid var(--line-soft); font-size: .875rem;
  }
  .mock-program li:first-child { border-top: 0; }
  .mock-program li span { font-variant-numeric: tabular-nums; color: var(--ink-3); font-weight: 500; }
  .mock-program li em { font-style: normal; font-size: .75rem; font-weight: 600; color: var(--ink-3); }
  .mock-program .is-done { color: var(--ink-3); }
  .mock-program .is-next { font-weight: 600; }
  .mock-program .is-next em { color: var(--teal); }
}

@media (min-width: 1024px) {
  .hero-grid { grid-template-columns: minmax(0, 1fr) minmax(0, 1fr); align-items: center; gap: 56px; }
  .hero h1 { font-size: clamp(2.9rem, 4.6vw, 3.9rem); }
  .hero-visual { margin-right: calc(var(--gutter) * -1 - 80px); } /* bleed to the right; hero clips */
  .hero-visual .mock-note { text-align: left; padding-left: 8px; }
  .mock-dash { grid-template-columns: 172px 1fr; }
  .mock-side { display: block; padding: 20px 14px; border-right: 1px solid var(--line-soft); }
  .mock-side img { border-radius: 7px; margin: 0 0 22px 8px; }
  .mock-side li {
    display: flex; align-items: center; gap: 10px; padding: 8px 10px; border-radius: 10px;
    font-size: .8125rem; color: var(--ink-3); font-weight: 500;
  }
  .mock-side li i { width: 14px; height: 14px; border-radius: 4px; background: currentColor; opacity: .22; }
  .mock-side .is-active { background: var(--teal-tint); color: var(--teal); font-weight: 600; }
  .mock-main { padding: 26px; }
}
@media (min-width: 1440px) {
  .hero-visual { margin-right: -140px; }
}

@media (prefers-reduced-motion: no-preference) {
  .mock-dash, .mock-phone { animation: float 9s ease-in-out infinite; }
}
@keyframes float { 0%, 100% { transform: translateY(0); } 50% { transform: translateY(-6px); } }

/* ---------- problem / converge ---------- */
.problem { background: var(--bg-warm); }
.converge {
  display: grid; justify-items: center; gap: 0;
  margin-bottom: clamp(40px, 6vw, 72px);
}
.scatter { display: flex; flex-wrap: wrap; justify-content: center; gap: 10px; max-width: 420px; }
.scatter li {
  padding: 10px 16px; background: var(--surface); border: 1px solid var(--line);
  border-radius: 12px; font-size: .9375rem; font-weight: 500; color: var(--ink-2);
  box-shadow: var(--shadow-sm);
  transform: rotate(var(--r));
  transition: transform .9s var(--ease);
}
.js .converge.is-visible .scatter li { transform: rotate(calc(var(--r) * .35)); }
.converge-lines { display: none; }
.converge-target {
  position: relative; margin-top: 56px;
  display: grid; justify-items: center; text-align: center; gap: 10px;
  width: 100%; max-width: 360px; padding: 32px 24px;
  background: var(--teal); color: #fff; border-radius: var(--radius-lg); box-shadow: var(--shadow-lg);
}
.converge-target::before { /* vertical connector on mobile */
  content: ""; position: absolute; left: 50%; top: -48px; height: 40px; width: 1.5px;
  background: linear-gradient(hsl(187 30% 60% / 0), hsl(187 40% 40%));
}
.converge-target img { border-radius: 12px; box-shadow: 0 0 0 1px hsl(0 0% 100% / .2); }
.converge-brand { font-family: var(--font-display); font-size: 1.5rem; font-weight: 600; letter-spacing: -0.02em; }
.converge-claim { font-size: .9375rem; color: hsl(185 25% 85%); line-height: 1.5; }
.problem-copy { max-width: 680px; }
.problem-copy p + p { margin-top: 14px; color: var(--ink-2); }

@media (min-width: 768px) {
  .converge {
    grid-template-columns: minmax(0, 1fr) minmax(80px, 200px) minmax(0, 1fr);
    align-items: center; justify-items: stretch;
  }
  .scatter { flex-direction: column; flex-wrap: nowrap; align-items: flex-end; justify-content: space-between; height: 300px; gap: 0; max-width: none; }
  .scatter li { transform: translateX(var(--x)) rotate(var(--r)); }
  .js .converge.is-visible .scatter li { transform: translateX(calc(var(--x) * .3)) rotate(calc(var(--r) * .35)); }
  .converge-lines { display: block; width: 100%; height: 300px; overflow: visible; }
  .converge-lines path {
    fill: none; stroke: hsl(187 28% 62%); stroke-width: 1.5; vector-effect: non-scaling-stroke;
    stroke-dasharray: 4 5;
  }
  .converge-target { margin-top: 0; justify-self: start; }
  .converge-target::before { display: none; }
}
@media (min-width: 1024px) {
  .problem .container { display: grid; grid-template-columns: minmax(0, 7fr) minmax(0, 5fr); column-gap: 64px; align-items: end; }
  .problem .section-head { grid-column: 1 / -1; }
  .problem .converge { margin-bottom: 0; }
  .problem-copy { padding-bottom: 12px; }
}

/* ---------- lifecycle ---------- */
.journey { position: relative; display: grid; gap: 20px; }
.journey::before { /* the path the trip travels along */
  content: ""; position: absolute; left: 21px; top: 24px; bottom: 24px; width: 2px;
  background: linear-gradient(var(--teal) 0 60%, var(--orange));
  opacity: .35;
}
.stage { position: relative; display: grid; grid-template-columns: 44px 1fr; gap: 16px; }
.stage-marker span {
  position: relative; z-index: 1;
  display: grid; place-items: center; width: 44px; height: 44px; border-radius: 50%;
  font-family: var(--font-display); font-weight: 600; font-size: 1rem;
  background: var(--bg); border: 1.5px solid var(--line); color: var(--ink-2);
}
.stage-body { border-radius: var(--radius-lg); padding: 24px 22px 26px; }
.stage-body h3 { font-size: clamp(1.25rem, 1.1rem + .6vw, 1.5rem); letter-spacing: -0.02em; }
.stage-kicker {
  display: flex; align-items: center; gap: 8px; margin-bottom: 8px;
  font-family: var(--font-body); font-size: .75rem; font-weight: 600; letter-spacing: .12em; text-transform: uppercase;
}
.stage-body ul { margin-top: 20px; display: grid; gap: 0; }
.stage-body li { padding: 11px 0; border-top: 1px solid; font-size: .9875rem; }

.stage-before .stage-body { background: transparent; border: 1px solid var(--line); }
.stage-before .stage-kicker { color: var(--ink-3); }
.stage-before li { border-color: var(--line-soft); color: var(--ink-2); }

.stage-during .stage-marker span { background: var(--teal); border-color: var(--teal); color: #fff; }
.stage-during .stage-body { background: var(--teal); color: #fff; box-shadow: var(--shadow-lg); }
.stage-during h3 { color: #fff; }
.stage-during .stage-kicker { color: hsl(185 35% 80%); }
.stage-during li { border-color: hsl(187 40% 32%); color: hsl(185 25% 92%); }
.live-dot { width: 8px; height: 8px; border-radius: 50%; background: hsl(152 60% 55%); box-shadow: 0 0 0 4px hsl(152 60% 55% / .25); }

.stage-change .stage-marker span { border-color: var(--orange); color: var(--orange-ink); background: var(--orange-tint); }
.stage-change .stage-body { background: var(--surface); border: 1px solid var(--line-soft); box-shadow: inset 4px 0 0 var(--orange), var(--shadow); }
.stage-change .stage-kicker { color: var(--orange-ink); }
.stage-change li { border-color: var(--line-soft); color: var(--ink-2); }

@media (prefers-reduced-motion: no-preference) {
  .live-dot { animation: pulse 2.4s ease-in-out infinite; }
}
@keyframes pulse { 0%, 100% { box-shadow: 0 0 0 3px hsl(152 60% 55% / .3); } 50% { box-shadow: 0 0 0 7px hsl(152 60% 55% / 0); } }

@media (min-width: 1024px) {
  .journey { grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 24px; align-items: start; }
  .journey::before {
    left: 22px; right: 22px; top: 21px; bottom: auto; width: auto; height: 2px;
    background: linear-gradient(90deg, var(--teal) 0 55%, var(--orange));
  }
  .stage { grid-template-columns: 1fr; gap: 24px; }
  .stage-during { margin-top: 0; }
  .stage-during .stage-body { transform: translateY(-12px); padding-block: 32px 34px; }
  .stage-body { padding: 28px 28px 30px; }
}

/* ---------- operational value (dark) ---------- */
.ops { background: var(--deep); color: var(--on-deep); }
.ops h2 { color: var(--on-deep); }
.ops .lead { color: var(--on-deep-2); margin-top: 24px; max-width: 30em; }
.ops-grid { display: grid; gap: 48px; }
.ops-feed ol { position: relative; display: grid; gap: 14px; }
.ops-feed ol::before {
  content: ""; position: absolute; left: 52px; top: 20px; bottom: 20px; width: 1px; background: var(--deep-line);
}
.event { display: grid; grid-template-columns: 44px 1fr; gap: 20px; align-items: start; }
.event time {
  font-family: var(--font-display); font-size: .9375rem; font-weight: 600; color: var(--on-deep-2);
  font-variant-numeric: tabular-nums; padding-top: 18px; position: relative;
}
.event time::after { /* dot on the timeline */
  content: ""; position: absolute; right: -14px; top: 25px; width: 9px; height: 9px; border-radius: 50%;
  background: var(--deep); border: 2px solid hsl(190 20% 55%);
}
.event-card {
  background: var(--deep-2); border: 1px solid var(--deep-line); border-radius: var(--radius);
  padding: 16px 18px 18px;
}
.event-type { font-size: .6875rem; font-weight: 600; letter-spacing: .12em; text-transform: uppercase; color: var(--on-deep-2); }
.event-main { font-family: var(--font-display); font-size: clamp(1.125rem, 1rem + .6vw, 1.375rem); font-weight: 600; letter-spacing: -0.02em; margin-top: 4px; color: var(--on-deep); }
.event-sub { font-size: .875rem; color: var(--on-deep-2); margin-top: 4px; }
.event-sub s { opacity: .7; }
.event-flag { font-size: .875rem; font-weight: 600; margin-top: 8px; }
.tone-warn-dark { color: hsl(30 95% 66%); }
.bar-dark { background: hsl(189 30% 22%); }
.bar-dark span { background: hsl(152 50% 52%); }
.event-incident .event-card { border-color: hsl(28 60% 40%); box-shadow: inset 3px 0 0 var(--orange); }
.event-incident time::after { border-color: var(--orange); background: var(--orange); }
.check { color: hsl(152 50% 60%); margin-right: 4px; }
.mock-note-dark { color: hsl(190 12% 62%); padding-left: 64px; }

@media (min-width: 1024px) {
  .ops-grid { grid-template-columns: minmax(0, 5fr) minmax(0, 6fr); gap: 80px; align-items: center; }
  .ops-copy { position: sticky; top: calc(var(--header-h) + 48px); align-self: start; padding-top: 24px; }
  .event { grid-template-columns: 56px 1fr; gap: 28px; }
  .ops-feed ol::before { left: 70px; }
  .event time::after { right: -19px; }
  .event-card { padding: 20px 24px 22px; }
  .mock-note-dark { padding-left: 84px; }
}

/* ---------- capabilities ---------- */
.feature-grid { display: grid; gap: 16px; }
.feature {
  display: grid; gap: 24px; align-content: space-between;
  background: var(--surface); border: 1px solid var(--line-soft); border-radius: var(--radius-lg);
  padding: 28px 24px; box-shadow: var(--shadow-sm);
  transition: box-shadow .3s var(--ease), transform .3s var(--ease);
}
.feature:hover { box-shadow: var(--shadow); transform: translateY(-2px); }
.feature h3 { font-size: clamp(1.375rem, 1.15rem + .8vw, 1.75rem); letter-spacing: -0.025em; }
.feature-text p { margin-top: 8px; color: var(--ink-2); max-width: 30em; }
.feature-visual { background: var(--bg); border-radius: var(--radius); padding: 18px 20px; }

.fv-num { font-family: var(--font-display); font-size: 2.5rem; font-weight: 600; letter-spacing: -0.04em; line-height: 1; }
.fv-num span { font-size: 1.25rem; color: var(--ink-3); font-weight: 500; letter-spacing: -0.01em; }
.fv-missing { margin-top: 16px; display: grid; gap: 8px; }
.fv-missing li { display: flex; align-items: center; gap: 10px; font-size: .875rem; color: var(--orange-ink); font-weight: 500; }
.fv-missing b {
  display: grid; place-items: center; width: 30px; height: 30px; border-radius: 50%;
  background: var(--orange-tint); font-size: .6875rem; font-weight: 600; color: var(--orange-ink);
}
.fv-msg { background: var(--surface); border: 1px solid var(--line-soft); border-radius: 14px; padding: 14px 16px; font-size: .9375rem; }
.fv-msg-tag { font-size: .6875rem; font-weight: 600; letter-spacing: .1em; text-transform: uppercase; color: var(--orange-ink); margin-bottom: 4px; }
.fv-ack { margin-top: 12px; font-size: .875rem; color: var(--ink-3); }
.fv-ack span { font-weight: 600; color: var(--ok); }
.fv-steps { display: grid; gap: 10px; }
.fv-steps li { display: flex; align-items: center; gap: 10px; font-size: .9375rem; color: var(--ink-3); }
.fv-steps li::before { content: ""; width: 18px; height: 18px; border-radius: 50%; border: 1.5px dashed hsl(200 12% 66%); flex: none; }
.fv-steps .done { color: var(--ink); font-weight: 500; }
.fv-steps .done::before { border: 0; background: var(--teal) url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='white' stroke-width='3' stroke-linecap='round' stroke-linejoin='round'%3E%3Cpath d='M6 12l4 4 8-8'/%3E%3C/svg%3E") center / 12px no-repeat; }
.fv-offline { display: inline-flex; align-items: center; gap: 8px; padding: 6px 12px; border-radius: 999px; background: hsl(200 14% 90%); font-size: .8125rem; font-weight: 600; color: var(--ink-2); }
.fv-offline i { width: 8px; height: 8px; border-radius: 50%; background: hsl(200 10% 55%); }
.fv-sync { margin-top: 12px; font-size: .875rem; color: var(--ink-3); }

/* Offline tile goes dark: a visual anchor in the grid */
.feature-offline { background: var(--deep); border-color: var(--deep); }
.feature-offline h3 { color: var(--on-deep); }
.feature-offline .feature-text p { color: var(--on-deep-2); }
.feature-offline .feature-visual { background: var(--deep-2); }
.feature-offline .fv-offline { background: hsl(189 30% 22%); color: var(--on-deep); }
.feature-offline .fv-sync { color: var(--on-deep-2); }

.cap-list { display: grid; margin-top: clamp(40px, 6vw, 64px); }
.cap-list li { padding: 22px 0; border-top: 1px solid var(--line); }
.cap-list h3 { font-size: 1.125rem; }
.cap-list p { margin-top: 4px; font-size: .9875rem; color: var(--ink-3); }

@media (min-width: 640px) {
  .cap-list { grid-template-columns: repeat(2, minmax(0, 1fr)); column-gap: 40px; }
}
@media (min-width: 768px) {
  .feature-grid { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .feature-headcount, .feature-offline { grid-column: span 2; grid-template-columns: minmax(0, 1fr) minmax(0, 1fr); align-items: center; }
}
@media (min-width: 1024px) {
  .feature-grid { grid-template-columns: repeat(12, minmax(0, 1fr)); gap: 20px; }
  .feature { padding: 36px; }
  /* asymmetric checkerboard: wide | narrow, narrow | wide */
  .feature-headcount { grid-column: span 7; grid-template-columns: minmax(0, 1fr) minmax(0, 1.1fr); align-items: center; }
  .feature-headcount .feature-visual { padding: 24px; }
  .feature-headcount .fv-num { font-size: 3.5rem; }
  .feature-comms, .feature-incidents { grid-column: span 5; }
  .feature-offline { grid-column: span 7; grid-template-columns: minmax(0, 1fr) minmax(0, 1fr); align-items: end; }
  .cap-list { grid-template-columns: repeat(3, minmax(0, 1fr)); column-gap: 48px; }
}

/* ---------- integrations ---------- */
.integrations { background: var(--bg-warm); }
.int-grid { display: grid; gap: 56px; }
.int-grid > * { min-width: 0; }
.int-copy .lead { margin-top: 20px; color: var(--ink); font-weight: 500; }
.int-copy .lead + p { margin-top: 14px; color: var(--ink-2); max-width: 34em; }
.int-points { margin: 28px 0 32px; display: grid; gap: 12px; }
.int-points li { display: flex; align-items: center; gap: 12px; font-weight: 500; }
.int-points li::before { content: ""; width: 18px; height: 2px; border-radius: 2px; background: var(--orange); flex: none; }

.int-diagram figcaption { margin-top: 18px; font-size: .8125rem; color: var(--ink-3); text-align: center; }
.int-map {
  position: relative;
  display: grid; grid-template-columns: 1fr 1fr; gap: 12px;
  padding: 28px 18px; border-radius: var(--radius-lg);
  background: var(--surface); border: 1px solid var(--line-soft); box-shadow: var(--shadow-sm);
}
.int-hub {
  grid-column: 1 / -1; grid-row: 1; justify-self: center;
  display: inline-flex; align-items: center; gap: 12px; margin-bottom: 20px;
  padding: 14px 22px 14px 14px; border-radius: 20px; background: var(--teal); color: #fff;
  font-family: var(--font-display); font-weight: 600; font-size: 1.25rem; letter-spacing: -0.02em;
  box-shadow: var(--shadow);
}
.int-hub img { border-radius: 10px; box-shadow: 0 0 0 1px hsl(0 0% 100% / .2); }
/* "Andra verksamhetssystem" has a long unbreakable word: one column on the narrowest phones */
@media (max-width: 419px) {
  .int-map { grid-template-columns: minmax(0, 1fr); }
  .int-node { min-height: 48px; }
}
.int-node {
  display: grid; place-items: center; text-align: center; min-height: 56px; padding: 10px 12px;
  border: 1.5px dashed hsl(187 20% 72%); border-radius: 14px; background: var(--bg);
  font-size: .9375rem; font-weight: 500; color: var(--ink-2);
}

@media (min-width: 640px) {
  .int-map {
    grid-template-columns: 1fr auto 1fr; grid-template-rows: auto auto auto;
    gap: 40px 28px; padding: 40px 28px; align-items: center;
  }
  .int-hub { grid-column: 2; grid-row: 2; margin: 0; padding: 18px 26px 18px 18px; font-size: 1.375rem; }
  .n-top { grid-column: 2; grid-row: 1; }
  .n-left { grid-column: 1; grid-row: 2; }
  .n-right { grid-column: 3; grid-row: 2; }
  .n-bottom { grid-column: 2; grid-row: 3; }
  .int-node { position: relative; }
  .int-node::after { content: ""; position: absolute; border: 0 dashed hsl(187 25% 66%); }
  .n-top::after { left: 50%; top: 100%; height: 40px; border-left-width: 1.5px; }
  .n-bottom::after { left: 50%; bottom: 100%; height: 40px; border-left-width: 1.5px; }
  .n-left::after { top: 50%; left: 100%; width: 28px; border-top-width: 1.5px; }
  .n-right::after { top: 50%; right: 100%; width: 28px; border-top-width: 1.5px; }
}
@media (min-width: 1024px) {
  .int-grid { grid-template-columns: minmax(0, 5fr) minmax(0, 6fr); gap: 80px; align-items: center; }
  .int-map { padding: 56px 40px; gap: 48px 32px; }
  .n-top::after, .n-bottom::after { height: 48px; }
  .n-left::after, .n-right::after { width: 32px; }
}

/* ---------- audience ---------- */
.audience { padding-block: clamp(48px, 5vw, 72px); }
.audience-inner { display: grid; gap: 28px; }
.audience h2 { font-size: clamp(1.625rem, 1.2rem + 1.8vw, 2.5rem); max-width: 20em; }
.audience-list { display: flex; flex-wrap: wrap; gap: 10px; }
.audience-list li {
  padding: 10px 18px; border-radius: 999px; border: 1px solid var(--line);
  font-weight: 500; color: var(--ink-2); background: var(--surface);
}
@media (min-width: 1024px) {
  .audience-inner { grid-template-columns: minmax(0, 5fr) minmax(0, 6fr); gap: 80px; align-items: center; }
}

/* ---------- security ---------- */
.security { border-top: 1px solid var(--line-soft); padding-block: clamp(64px, 8vw, 112px) clamp(64px, 7vw, 104px); }
.sec-grid { display: grid; gap: 40px; }
.sec-copy .lead { margin-top: 20px; max-width: 28em; }
.sec-list { display: grid; }
.sec-list li { display: grid; grid-template-columns: 40px 1fr; gap: 16px; padding: 22px 0; border-top: 1px solid var(--line); }
.sec-list li:last-child { border-bottom: 1px solid var(--line); }
.sec-list svg {
  width: 40px; height: 40px; padding: 9px; border-radius: 12px; background: var(--teal-tint);
  fill: none; stroke: var(--teal); stroke-width: 1.75; stroke-linecap: round; stroke-linejoin: round;
}
.sec-list h3 { font-size: 1.125rem; }
.sec-list p { margin-top: 2px; color: var(--ink-3); font-size: .9875rem; }
@media (min-width: 1024px) {
  .sec-grid { grid-template-columns: minmax(0, 5fr) minmax(0, 6fr); gap: 80px; align-items: start; }
  .sec-copy { position: sticky; top: calc(var(--header-h) + 48px); }
}

/* ---------- final CTA ---------- */
.final { padding-top: 0; }
.final-card {
  position: relative; overflow: hidden; text-align: center;
  background: var(--deep); color: var(--on-deep);
  border-radius: var(--radius-xl); padding: clamp(56px, 9vw, 112px) clamp(24px, 6vw, 80px);
}
.final-card::before { /* the logo's compass ring, very faint */
  content: ""; position: absolute; width: 640px; height: 640px; left: 50%; top: 50%;
  transform: translate(-50%, -50%); border-radius: 50%; border: 1px solid hsl(189 30% 22%);
  box-shadow: 0 0 0 120px hsl(189 50% 13% / .5);
  pointer-events: none;
}
.final-card > * { position: relative; }
.final h2 { color: var(--on-deep); font-size: clamp(1.75rem, 1.1rem + 3vw, 3.75rem); }
.final .lead { color: var(--on-deep-2); margin-top: 20px; }
.cta-center { justify-content: center; margin-top: 36px; }

/* ---------- footer ---------- */
.site-footer { padding-block: 56px 40px; border-top: 1px solid var(--line-soft); font-size: .9375rem; }
.footer-grid { display: grid; gap: 32px; }
.footer-brand p { margin-top: 10px; color: var(--ink-3); }
.footer-links, .footer-legal { display: flex; flex-wrap: wrap; gap: 8px 24px; }
.footer-links a { text-decoration: none; color: var(--ink-2); }
.footer-legal a { text-decoration: none; color: var(--ink-3); }
.footer-links a:hover, .footer-legal a:hover { color: var(--teal); text-decoration: underline; text-underline-offset: 4px; }
.copyright { color: var(--ink-3); }
@media (min-width: 768px) {
  .footer-grid { grid-template-columns: 1fr auto; align-items: start; }
  .footer-grid nav, .footer-legal { justify-self: end; }
  .footer-legal { grid-column: 2; }
  .copyright { grid-column: 1; grid-row: 2; align-self: end; }
}

/* ---------- language switcher (SV / EN) ---------- */
.lang-switch { display: flex; align-items: center; gap: 2px; font-size: .8125rem; font-weight: 600; letter-spacing: .06em; }
.lang-switch > * {
  display: inline-flex; align-items: center; justify-content: center; min-width: 36px; min-height: 32px;
  padding: 4px 8px; border-radius: 999px;
}
.lang-switch [aria-current] { color: var(--ink); background: hsl(40 20% 91%); }
.lang-switch a { color: var(--teal); text-decoration: none; }
.lang-switch a:hover { background: var(--teal-tint); }
.nav .lang-switch { justify-content: center; }
@media (min-width: 960px) { .nav .lang-switch { margin-right: 8px; } }
/* Narrow headers show only the link to the other language; the full switcher is in the menu and footer. */
.header-mobile .lang-switch [aria-current], .page-header .lang-switch [aria-current] { display: none; }
@media (min-width: 640px) { .page-header .lang-switch [aria-current] { display: inline-flex; } }
@media (max-width: 359px) { .header-mobile .lang-switch, .page-header .lang-switch { display: none; } }
.footer-legal .lang-switch { margin-block: -6px; }

/* ---------- simple content page (integritet/, en/privacy/) ---------- */
.page-header { border-bottom-color: var(--line-soft); }
.page-home {
  margin-left: auto; font-weight: 600; font-size: .9375rem; color: var(--teal); text-decoration: none;
  padding: 10px 12px; border-radius: 999px;
}
.page-home:hover { background: var(--teal-tint); }
.page-legal { max-width: 760px; padding-block: clamp(48px, 8vw, 96px); }
.page-legal h1 { font-size: clamp(2.1rem, 1.5rem + 2.6vw, 3.25rem); line-height: 1.08; letter-spacing: -0.03em; }
.page-legal .lead { margin-top: 20px; }
.page-legal h2 { font-size: 1.375rem; line-height: 1.3; letter-spacing: -0.02em; margin-top: 44px; }
.page-legal h2 + p { margin-top: 10px; }
.page-legal p { color: var(--ink-2); }
.page-legal p a { color: var(--teal); text-underline-offset: 3px; }
.page-back { margin-top: 56px; font-weight: 600; }
.page-back a { color: var(--teal); text-decoration: none; }
.page-back a:hover { text-decoration: underline; text-underline-offset: 4px; }

/* ---------- reveal on scroll (only when JS runs and motion is welcome) ---------- */
@media (prefers-reduced-motion: no-preference) {
  .js .reveal { opacity: 0; transform: translateY(16px); transition: opacity .7s var(--ease), transform .7s var(--ease); }
  .js .reveal.is-visible { opacity: 1; transform: none; }
  .js .ops-feed .event.reveal { transition-delay: calc(var(--i, 0) * 120ms); }
  /* the during-stage keeps its lift after revealing */
  .js .stage-during.reveal.is-visible .stage-body { transition: transform .7s var(--ease); }
}
@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after { animation: none !important; transition: none !important; }
  .bar span { transform: none !important; }
  .scatter li { transform: none !important; }
}
