
:root {
  --bg: #f6f8f7; --surface: #ffffff; --surface-2: #eef3f1; --ink: #0d1f24; --ink-2: #44585d; --ink-3: #6b7d81;
  --line: #dde6e3; --brand: #00693e; --brand-ink: #ffffff; --brand-soft: #dcefe4; --accent: #f2b705;
  --ok: #157f4a; --warn: #a45a00; --bad: #c2332a; --ok-soft: #e1f4e9; --warn-soft: #fdf0dc; --bad-soft: #fbe5e3;
  --ring: #00693e; --shadow: 0 1px 2px rgba(13,31,36,.05), 0 8px 24px -12px rgba(13,31,36,.12);
  --r: 14px; --r-sm: 10px; --max: 1120px;
  color-scheme: light;
}
@media (prefers-color-scheme: dark) {
  :root {
    --bg: #0a1416; --surface: #101e21; --surface-2: #15272b; --ink: #e8f0ee; --ink-2: #a9bbb8; --ink-3: #82938f;
    --line: #213538; --brand: #3fbf7f; --brand-ink: #03200f; --brand-soft: #0f3322; --accent: #f5c542;
    --ok: #4ccf8a; --warn: #f0a94a; --bad: #ff7b70; --ok-soft: #10301f; --warn-soft: #33250f; --bad-soft: #3a1714;
    --ring: #3fbf7f; --shadow: 0 1px 2px rgba(0,0,0,.3), 0 12px 32px -16px rgba(0,0,0,.6);
    color-scheme: dark;
  }
}
* { box-sizing: border-box; }
[hidden] { display: none !important; }
html { -webkit-text-size-adjust: 100%; }
body { margin: 0; background: var(--bg); color: var(--ink); font: 400 16px/1.55 'Schibsted Grotesk', system-ui, -apple-system, 'Segoe UI', sans-serif; }
a { color: var(--brand); text-decoration: none; }
a:hover { text-decoration: underline; }
h1, h2, h3, .logo, .price, .stat .v { font-family: 'Bricolage Grotesque', 'Schibsted Grotesk', system-ui, sans-serif; }
h1, h2, h3 { line-height: 1.15; letter-spacing: -0.02em; margin: 0 0 .5em; text-wrap: balance; }
p { margin: 0 0 1em; }
code, .mono { font-family: 'JetBrains Mono', ui-monospace, monospace; font-size: .9em; }
:focus-visible { outline: 2px solid var(--ring); outline-offset: 2px; border-radius: 6px; }
.wrap { max-width: var(--max); margin: 0 auto; padding: 0 20px; }
.muted { color: var(--ink-2); }
.small { font-size: .875rem; }
.sr { position: absolute; width: 1px; height: 1px; overflow: hidden; clip: rect(0 0 0 0); }
.icon { width: 20px; height: 20px; flex: none; stroke: currentColor; fill: none; stroke-width: 1.8; stroke-linecap: round; stroke-linejoin: round; }

/* nav */
.nav { position: sticky; top: 0; z-index: 20; background: color-mix(in srgb, var(--bg) 85%, transparent); backdrop-filter: blur(12px); border-bottom: 1px solid var(--line); }
.nav .wrap { display: flex; align-items: center; gap: 24px; height: 64px; }
.logo { display: flex; align-items: center; gap: 10px; font-weight: 800; font-size: 1.15rem; color: var(--ink); letter-spacing: -0.02em; }
.logo:hover { text-decoration: none; }
.logo-mark { width: 30px; height: 30px; border-radius: 9px; background: var(--brand); display: grid; place-items: center; color: var(--brand-ink); }
.nav-links { display: flex; gap: 22px; margin-left: auto; align-items: center; }
.nav-links a:not(.btn) { color: var(--ink-2); font-weight: 500; }
.nav-links a:not(.btn):hover { color: var(--ink); text-decoration: none; }
@media (max-width: 720px) { .nav-links .hide-sm { display: none; } .nav-links { gap: 14px; } }

/* buttons & inputs */
.btn { display: inline-flex; align-items: center; justify-content: center; gap: 8px; min-height: 44px; padding: 0 18px; border-radius: 999px; border: 1px solid transparent;
  font: 600 .95rem/1 inherit; cursor: pointer; transition: background .15s, border-color .15s, transform .15s; text-decoration: none !important; white-space: nowrap; }
.btn:active { transform: translateY(1px); }
.btn-primary { background: var(--brand); color: var(--brand-ink); }
.btn-primary:hover { background: color-mix(in srgb, var(--brand) 88%, var(--ink)); }
.btn-ghost { background: transparent; color: var(--ink); border-color: var(--line); }
.btn-ghost:hover { background: var(--surface-2); }
.btn-danger { background: transparent; color: var(--bad); border-color: color-mix(in srgb, var(--bad) 40%, transparent); }
.btn-sm { min-height: 36px; padding: 0 14px; font-size: .875rem; }
.btn[disabled] { opacity: .55; cursor: progress; }
label { display: block; font-weight: 600; font-size: .9rem; margin: 0 0 6px; }
.field { margin-bottom: 16px; }
.input, select, textarea { width: 100%; min-height: 44px; padding: 10px 14px; border-radius: var(--r-sm); border: 1px solid var(--line); background: var(--surface); color: var(--ink); font: inherit; }
.input:focus, select:focus, textarea:focus { outline: 2px solid var(--ring); outline-offset: 0; border-color: transparent; }
.hint { font-size: .825rem; color: var(--ink-3); margin-top: 6px; }
.err { color: var(--bad); font-size: .875rem; min-height: 1.2em; margin: 4px 0 0; }

/* cards */
.card { background: var(--surface); border: 1px solid var(--line); border-radius: var(--r); padding: 24px; box-shadow: var(--shadow); }
.grid { display: grid; gap: 20px; }
.badge { display: inline-flex; align-items: center; gap: 6px; padding: 3px 10px; border-radius: 999px; font-size: .78rem; font-weight: 600; background: var(--surface-2); color: var(--ink-2); }
.badge.ok { background: var(--ok-soft); color: var(--ok); } .badge.warn { background: var(--warn-soft); color: var(--warn); } .badge.bad { background: var(--bad-soft); color: var(--bad); }
.badge.brand { background: var(--brand-soft); color: var(--brand); }

/* hero */
.hero { padding: 88px 0 64px; position: relative; overflow: hidden; }
.hero::before { content: ''; position: absolute; inset: -40% -10% auto auto; width: 720px; height: 720px; border-radius: 50%;
  background: radial-gradient(closest-side, color-mix(in srgb, var(--brand) 22%, transparent), transparent); pointer-events: none; }
.hero .wrap { position: relative; display: grid; grid-template-columns: 1.15fr .85fr; gap: 48px; align-items: center; }
.hero h1 { font-size: clamp(2.3rem, 5vw, 3.6rem); font-weight: 800; }
.hero h1 em { font-style: normal; color: var(--brand); }
.hero .lead { font-size: 1.15rem; color: var(--ink-2); max-width: 34em; }
.hero-cta { display: flex; gap: 12px; flex-wrap: wrap; margin: 28px 0 20px; }
.ticks { display: flex; gap: 18px; flex-wrap: wrap; color: var(--ink-2); font-size: .9rem; padding: 0; margin: 0; list-style: none; }
.ticks li { display: flex; gap: 6px; align-items: center; }
.ticks .icon { color: var(--brand); width: 18px; height: 18px; }
@media (max-width: 860px) { .hero .wrap { grid-template-columns: 1fr; } .hero { padding: 56px 0 40px; } }

/* signal panel (hero illustration made of real UI) */
.signal { padding: 20px; }
.signal-row { display: flex; align-items: center; gap: 12px; padding: 12px 4px; border-bottom: 1px dashed var(--line); }
.signal-row:last-child { border-bottom: 0; }
.flag { width: 36px; height: 36px; border-radius: 10px; background: var(--surface-2); display: grid; place-items: center; font-weight: 700; font-size: .8rem; color: var(--ink-2); }
.signal-row .badge { margin-left: auto; }
.dot { width: 10px; height: 10px; border-radius: 50%; flex: none; margin: 0 13px; }
.dot.up { background: var(--ok, #16a34a); box-shadow: 0 0 0 4px color-mix(in srgb, var(--ok, #16a34a) 18%, transparent); }
.dot.down { background: var(--bad, #dc2626); }

/* sections */
section.block { padding: 72px 0; }
.section-head { max-width: 640px; margin-bottom: 40px; }
.section-head h2 { font-size: clamp(1.7rem, 3vw, 2.3rem); }
.eyebrow { text-transform: uppercase; letter-spacing: .12em; font-size: .75rem; font-weight: 700; color: var(--brand); margin-bottom: 10px; }
.features { grid-template-columns: repeat(4, 1fr); }
@media (max-width: 1000px) { .features { grid-template-columns: repeat(2, 1fr); } }
@media (max-width: 560px) { .features { grid-template-columns: 1fr; } }
.feature .icon-wrap { width: 44px; height: 44px; border-radius: 12px; background: var(--brand-soft); color: var(--brand); display: grid; place-items: center; margin-bottom: 16px; }
.feature h3 { font-size: 1.1rem; }
.feature p { color: var(--ink-2); margin: 0; }

/* pricing */
.toggle { display: inline-flex; padding: 4px; background: var(--surface-2); border-radius: 999px; gap: 4px; margin-bottom: 32px; flex-wrap: wrap; }
.toggle button { border: 0; background: transparent; color: var(--ink-2); font: 600 .9rem inherit; padding: 0 16px; min-height: 40px; border-radius: 999px; cursor: pointer; }
.toggle button[aria-pressed="true"] { background: var(--surface); color: var(--ink); box-shadow: var(--shadow); }
.toggle .save { color: var(--ok); font-weight: 700; margin-left: 4px; }
.plans { grid-template-columns: repeat(auto-fit, minmax(260px, 1fr)); align-items: stretch; }
.plan { display: flex; flex-direction: column; position: relative; }
.plan.featured { border: 2px solid var(--brand); }
.plan .ribbon { position: absolute; top: -12px; left: 24px; background: var(--brand); color: var(--brand-ink); font-size: .75rem; font-weight: 700; padding: 4px 12px; border-radius: 999px; }
.plan h3 { font-size: 1.2rem; margin-bottom: 4px; }
.price { font-size: 2.4rem; font-weight: 800; letter-spacing: -0.03em; margin: 16px 0 0; }
.price small { font-size: .95rem; font-weight: 500; color: var(--ink-2); letter-spacing: 0; }
.per { color: var(--ink-3); font-size: .85rem; min-height: 1.3em; }
.plan ul { list-style: none; padding: 0; margin: 20px 0 24px; display: grid; gap: 10px; flex: 1; }
.plan li { display: flex; gap: 10px; align-items: flex-start; color: var(--ink-2); }
.plan li .icon { color: var(--brand); width: 18px; height: 18px; margin-top: 3px; }
.plan li b { color: var(--ink); font-weight: 600; }
.plan.unavailable { opacity: .5; }

/* steps, apps, faq */
.steps { grid-template-columns: repeat(auto-fit, minmax(220px, 1fr)); counter-reset: s; }
.step::before { counter-increment: s; content: counter(s); display: grid; place-items: center; width: 32px; height: 32px; border-radius: 50%; background: var(--ink); color: var(--bg); font-weight: 700; margin-bottom: 14px; }
.apps { display: flex; flex-wrap: wrap; gap: 10px; }
.app-chip { display: inline-flex; gap: 8px; align-items: center; padding: 10px 14px; border: 1px solid var(--line); border-radius: 12px; background: var(--surface); font-weight: 600; font-size: .9rem; }
.app-chip span { color: var(--ink-3); font-weight: 500; }
details { border-bottom: 1px solid var(--line); padding: 18px 0; }
details summary { cursor: pointer; font-weight: 600; list-style: none; display: flex; justify-content: space-between; gap: 16px; }
details summary::after { content: '+'; color: var(--ink-3); font-size: 1.3rem; line-height: 1; }
details[open] summary::after { content: '–'; }
details p { color: var(--ink-2); margin: 12px 0 0; }
.cta-band { background: var(--ink); color: var(--bg); border-radius: 24px; padding: 48px; display: flex; gap: 24px; align-items: center; justify-content: space-between; flex-wrap: wrap; }
.cta-band h2 { margin: 0; }
.cta-band .btn-primary { background: var(--accent); color: #2a0d04; }
footer { padding: 40px 0 56px; color: var(--ink-3); font-size: .875rem; }
footer .wrap { display: flex; gap: 20px; justify-content: space-between; flex-wrap: wrap; }

/* app shell (account/admin) */
.shell { display: grid; grid-template-columns: 232px 1fr; min-height: calc(100vh - 64px); }
.side { border-right: 1px solid var(--line); padding: 24px 14px; display: flex; flex-direction: column; gap: 4px; position: sticky; top: 64px; height: calc(100vh - 64px); }
.side a { display: flex; gap: 12px; align-items: center; padding: 0 14px; min-height: 44px; border-radius: 10px; color: var(--ink-2); font-weight: 600; }
.side a:hover { background: var(--surface-2); text-decoration: none; color: var(--ink); }
.side a[aria-current="page"] { background: var(--brand-soft); color: var(--brand); }
.side .spacer { flex: 1; }
.main { padding: 32px clamp(16px, 4vw, 48px) 64px; max-width: 1080px; width: 100%; min-width: 0; }
.main h1 { font-size: 1.7rem; }
.page-head { display: flex; justify-content: space-between; gap: 16px; align-items: flex-end; flex-wrap: wrap; margin-bottom: 24px; }
@media (max-width: 820px) {
  .shell { grid-template-columns: 1fr; }
  .side { position: fixed; bottom: 0; top: auto; left: 0; right: 0; height: auto; flex-direction: row; justify-content: space-around; padding: 6px 6px calc(6px + env(safe-area-inset-bottom)); background: var(--surface); border-right: 0; border-top: 1px solid var(--line); z-index: 30; }
  .side a { flex-direction: column; gap: 2px; font-size: .7rem; padding: 8px 10px; min-height: 52px; justify-content: center; flex: 1; }
  .side .spacer, .side .desk { display: none; }
  .main { padding-bottom: 110px; }
}

.stats { grid-template-columns: repeat(auto-fit, minmax(200px, 1fr)); margin-bottom: 20px; }
.stats.four { grid-template-columns: repeat(4, 1fr); }
@media (max-width: 1240px) { .stats.four { grid-template-columns: repeat(2, 1fr); } }
.stat .k { color: var(--ink-2); font-size: .85rem; font-weight: 600; }
.stat .v { font-size: 1.8rem; font-weight: 800; letter-spacing: -0.02em; margin-top: 6px; font-variant-numeric: tabular-nums; }
.stat .s { color: var(--ink-3); font-size: .82rem; }
.meter { height: 10px; border-radius: 999px; background: var(--surface-2); overflow: hidden; margin: 10px 0 6px; }
.meter > i { display: block; height: 100%; background: var(--brand); border-radius: inherit; transition: width .6s ease; }
.meter.warn > i { background: var(--warn); } .meter.bad > i { background: var(--bad); }

.sub-box { display: flex; gap: 8px; align-items: stretch; flex-wrap: wrap; }
.sub-box .input { flex: 1 1 260px; font-family: 'JetBrains Mono', monospace; font-size: .85rem; }
.qr { width: 184px; height: 184px; padding: 10px; background: #fff; border-radius: 12px; border: 1px solid var(--line); }
.qr svg, .qr img { width: 100%; height: 100%; display: block; }
.two { grid-template-columns: 1.4fr 1fr; } @media (max-width: 900px) { .two { grid-template-columns: 1fr; } }

/* tables */
.table-wrap { overflow-x: auto; border: 1px solid var(--line); border-radius: var(--r); background: var(--surface); }
table { width: 100%; border-collapse: collapse; font-size: .9rem; }
th, td { text-align: left; padding: 12px 16px; border-bottom: 1px solid var(--line); white-space: nowrap; }
th { font-size: .78rem; text-transform: uppercase; letter-spacing: .06em; color: var(--ink-3); background: var(--surface-2); font-weight: 700; }
tr:last-child td { border-bottom: 0; }
td.num, th.num { text-align: right; font-variant-numeric: tabular-nums; }
.empty { padding: 40px; text-align: center; color: var(--ink-3); }

/* checkout picker */
.choice { display: grid; gap: 10px; grid-template-columns: repeat(auto-fit, minmax(150px, 1fr)); }
.choice label { margin: 0; display: flex; flex-direction: column; gap: 2px; padding: 14px 16px; border: 1.5px solid var(--line); border-radius: 12px; cursor: pointer; font-weight: 600; background: var(--surface); transition: border-color .15s; }
.choice label span { font-weight: 500; color: var(--ink-2); font-size: .85rem; }
.choice input { position: absolute; opacity: 0; }
.choice label:has(input:checked) { border-color: var(--brand); background: var(--brand-soft); }
.choice label:has(input:focus-visible) { outline: 2px solid var(--ring); outline-offset: 2px; }
.summary { display: flex; justify-content: space-between; align-items: center; gap: 16px; flex-wrap: wrap; padding-top: 20px; margin-top: 8px; border-top: 1px solid var(--line); }
.summary .total { font-size: 1.6rem; font-weight: 800; }

/* auth */
.auth { min-height: calc(100vh - 64px); display: grid; place-items: center; padding: 32px 16px; }
.auth .card { width: 100%; max-width: 420px; padding: 32px; }
.tabs { display: flex; gap: 4px; background: var(--surface-2); padding: 4px; border-radius: 999px; margin-bottom: 24px; }
.tabs button { flex: 1; border: 0; background: transparent; min-height: 40px; border-radius: 999px; font: 600 .9rem inherit; color: var(--ink-2); cursor: pointer; }
.tabs button[aria-selected="true"] { background: var(--surface); color: var(--ink); box-shadow: var(--shadow); }

/* toast & dialog */
#toast { position: fixed; left: 50%; bottom: 24px; transform: translate(-50%, 20px); opacity: 0; background: var(--ink); color: var(--bg); padding: 12px 18px; border-radius: 12px; font-weight: 600; font-size: .9rem; transition: .2s; z-index: 100; pointer-events: none; max-width: calc(100vw - 32px); }
#toast.show { opacity: 1; transform: translate(-50%, 0); }
@media (max-width: 820px) { #toast { bottom: 96px; } }
dialog { border: 1px solid var(--line); border-radius: var(--r); padding: 0; background: var(--surface); color: var(--ink); width: min(640px, calc(100vw - 32px)); box-shadow: var(--shadow); }
dialog::backdrop { background: rgba(5, 15, 17, .5); }
dialog form { padding: 24px; }
.row { display: grid; gap: 12px; grid-template-columns: repeat(auto-fit, minmax(130px, 1fr)); }
.checks { display: grid; gap: 8px; grid-template-columns: repeat(auto-fit, minmax(200px, 1fr)); }
.checks label { display: flex; gap: 8px; align-items: center; font-weight: 500; margin: 0; padding: 8px 10px; border: 1px solid var(--line); border-radius: 10px; cursor: pointer; }
.chart { display: flex; align-items: flex-end; gap: 4px; height: 140px; padding-top: 10px; }
.chart i { flex: 1; background: var(--brand); border-radius: 4px 4px 0 0; min-height: 2px; opacity: .85; }
.chart i:hover { opacity: 1; }

@media (prefers-reduced-motion: reduce) { *, *::before, *::after { transition: none !important; animation: none !important; } }

/* setup guide */
.os-tabs { display: flex; gap: 6px; flex-wrap: wrap; margin-bottom: 20px; }
.os-tabs button { border: 1px solid var(--line); background: var(--surface); color: var(--ink-2); font: 600 .9rem inherit; padding: 0 16px; min-height: 40px; border-radius: 999px; cursor: pointer; }
.os-tabs button[aria-pressed="true"] { background: var(--ink); color: var(--bg); border-color: var(--ink); }
.guide ol { counter-reset: g; list-style: none; padding: 0; margin: 0; display: grid; gap: 16px; }
.guide ol > li { counter-increment: g; display: grid; grid-template-columns: 32px 1fr; gap: 14px; }
.guide ol > li::before { content: counter(g); display: grid; place-items: center; width: 32px; height: 32px; border-radius: 50%; background: var(--brand-soft); color: var(--brand); font-weight: 700; }
.guide ol > li > div { padding-top: 4px; }
.guide kbd { font: inherit; font-weight: 600; background: var(--surface-2); border: 1px solid var(--line); border-radius: 6px; padding: 1px 6px; }
.choice textarea { min-height: 110px; }
.nodes { display: flex; gap: 8px; flex-wrap: wrap; }
.kv { display: grid; grid-template-columns: max-content 1fr; gap: 6px 20px; margin: 0; }
.kv dt { color: var(--ink-2); } .kv dd { margin: 0; font-weight: 600; }
