/* ------------------------------------------------------------------
   Design tokens
------------------------------------------------------------------ */
:root {
  --bg: #ffffff;
  --bg-alt: #f5f7fa;
  --surface: #ffffff;
  --border: #e3e8ef;
  --text: #0f172a;
  --muted: #4b5563;
  --accent: #e8590c;        /* commerce orange */
  --accent-strong: #c2410c;
  --accent-soft: #fff1e8;
  --navy: #0b1b33;
  --navy-soft: #13294b;
  --on-navy: #ffffff;
  --shadow: 0 1px 2px rgba(15, 23, 42, .06), 0 8px 24px rgba(15, 23, 42, .06);
  --radius: 14px;
  --radius-sm: 8px;
  --font: ui-sans-serif, system-ui, -apple-system, "Segoe UI", Roboto, "Helvetica Neue", Arial, sans-serif;
  --maxw: 1120px;
}

@media (prefers-color-scheme: dark) {
  :root:not([data-theme="light"]) {
    --bg: #0b1220;
    --bg-alt: #0f172a;
    --surface: #111b2e;
    --border: #233049;
    --text: #e5e7eb;
    --muted: #a3adbd;
    --accent: #ff7a2f;
    --accent-strong: #ff9456;
    --accent-soft: #2a1a10;
    --navy: #0a1426;
    --navy-soft: #122040;
    --shadow: 0 1px 2px rgba(0,0,0,.4), 0 8px 24px rgba(0,0,0,.35);
  }
}

/* ------------------------------------------------------------------
   Base
------------------------------------------------------------------ */
*, *::before, *::after { box-sizing: border-box; }
html { scroll-behavior: smooth; -webkit-text-size-adjust: 100%; }
body {
  margin: 0;
  font-family: var(--font);
  font-size: 17px;
  line-height: 1.6;
  color: var(--text);
  background: var(--bg);
}
img { max-width: 100%; display: block; }
a { color: var(--accent-strong); text-decoration: none; }
a:hover { text-decoration: underline; }
h1, h2, h3, h4 { line-height: 1.15; margin: 0 0 .5em; letter-spacing: -.01em; }
h1 { font-size: clamp(2rem, 5vw, 3.25rem); font-weight: 800; }
h2 { font-size: clamp(1.6rem, 3.2vw, 2.25rem); font-weight: 800; }
h3 { font-size: 1.2rem; font-weight: 700; }
.h4 { font-size: 1rem; text-transform: uppercase; letter-spacing: .08em; color: var(--muted); margin-top: 1.5rem; }
p { margin: 0 0 1em; }
ul, ol { margin: 0; padding: 0; }
small { font-weight: 400; }

.container { width: min(var(--maxw), 100% - 32px); margin-inline: auto; }
.container--narrow { max-width: 760px; }

.skip {
  position: absolute; left: -999px; top: 8px; background: var(--navy); color: #fff;
  padding: 8px 12px; border-radius: 6px; z-index: 100;
}
.skip:focus { left: 8px; }

.accent { color: var(--accent); }
.eyebrow {
  font-size: .85rem; font-weight: 600; letter-spacing: .04em; text-transform: uppercase;
  color: var(--muted); margin-bottom: 1rem;
}
.lead { font-size: 1.15rem; color: var(--muted); max-width: 58ch; }

/* ------------------------------------------------------------------
   Buttons
------------------------------------------------------------------ */
.btn {
  display: inline-flex; align-items: center; justify-content: center; gap: .4em;
  padding: 14px 22px; border-radius: 999px; font-weight: 700; font-size: 1rem;
  border: 2px solid transparent; cursor: pointer; text-decoration: none !important;
  transition: transform .08s ease, background .15s ease, border-color .15s ease;
  font-family: inherit;
}
.btn:active { transform: translateY(1px); }
.btn--primary { background: var(--accent); color: #fff; }
.btn--primary:hover { background: var(--accent-strong); }
.btn--ghost { background: transparent; color: var(--text); border-color: var(--border); }
.btn--ghost:hover { border-color: var(--text); }
.btn--sm { padding: 9px 16px; font-size: .92rem; }
.btn--block { width: 100%; }
.link { font-weight: 600; }

/* ------------------------------------------------------------------
   Navigation
------------------------------------------------------------------ */
.nav {
  position: sticky; top: 0; z-index: 50;
  background: color-mix(in srgb, var(--bg) 85%, transparent);
  backdrop-filter: saturate(160%) blur(10px);
  border-bottom: 1px solid var(--border);
}
.nav__inner { display: flex; align-items: center; justify-content: space-between; min-height: 68px; gap: 16px; }
.brand { display: flex; align-items: center; gap: 12px; color: var(--text); font-weight: 800; }
.brand:hover { text-decoration: none; }
.brand__mark {
  width: 40px; height: 40px; border-radius: 10px; display: grid; place-items: center;
  background: var(--navy); color: #fff; font-size: .95rem; letter-spacing: .02em;
}
.brand__text { display: flex; flex-direction: column; line-height: 1.1; }
.brand__text small { font-size: .78rem; color: var(--muted); }
.nav__menu { display: flex; align-items: center; gap: 22px; }
.nav__menu a { color: var(--text); font-weight: 600; font-size: .95rem; }
.nav__menu a:hover { color: var(--accent-strong); text-decoration: none; }
.nav__toggle {
  display: none; width: 44px; height: 44px; border: 0; background: transparent; cursor: pointer;
  flex-direction: column; justify-content: center; gap: 5px; align-items: center;
}
.nav__toggle span { width: 22px; height: 2px; background: var(--text); display: block; transition: transform .2s; }

@media (max-width: 860px) {
  .brand__text small { display: none; }
  .nav__toggle { display: flex; }
  .nav__menu {
    display: none; position: absolute; left: 0; right: 0; top: 100%;
    flex-direction: column; align-items: stretch; gap: 0;
    background: var(--bg); border-bottom: 1px solid var(--border); padding: 8px 16px 16px;
  }
  .nav__menu.is-open { display: flex; }
  .nav__menu a { padding: 12px 4px; border-bottom: 1px solid var(--border); }
  .nav__menu a.btn { margin-top: 12px; border-bottom: 0; }
  .nav__toggle[aria-expanded="true"] span:nth-child(1) { transform: translateY(7px) rotate(45deg); }
  .nav__toggle[aria-expanded="true"] span:nth-child(2) { opacity: 0; }
  .nav__toggle[aria-expanded="true"] span:nth-child(3) { transform: translateY(-7px) rotate(-45deg); }
}

/* ------------------------------------------------------------------
   Hero
------------------------------------------------------------------ */
.hero {
  padding: clamp(48px, 8vw, 96px) 0 clamp(40px, 6vw, 72px);
  background:
    radial-gradient(900px 400px at 85% -10%, var(--accent-soft), transparent 70%),
    var(--bg);
}
.hero__grid { display: grid; grid-template-columns: 1.4fr 1fr; gap: 48px; align-items: center; }
.hero__cta { display: flex; flex-wrap: wrap; gap: 12px; margin: 1.5rem 0; }
.trust { display: flex; flex-wrap: wrap; gap: 8px 18px; list-style: none; color: var(--muted); font-size: .92rem; font-weight: 600; }
.trust li::before { content: "✓"; color: var(--accent); margin-right: 6px; font-weight: 800; }

.hero__card {
  background: var(--navy); color: var(--on-navy); border-radius: var(--radius);
  padding: 28px; box-shadow: var(--shadow);
}
.card__title { font-size: .85rem; text-transform: uppercase; letter-spacing: .08em; opacity: .75; margin-bottom: 1rem; }
.facts { margin: 0; display: grid; gap: 14px; }
.facts div { display: grid; gap: 2px; padding-bottom: 12px; border-bottom: 1px solid rgba(255,255,255,.12); }
.facts div:last-child { border-bottom: 0; padding-bottom: 0; }
.facts dt { font-size: .8rem; opacity: .7; text-transform: uppercase; letter-spacing: .06em; }
.facts dd { margin: 0; font-weight: 600; }

@media (max-width: 860px) {
  .hero__grid { grid-template-columns: 1fr; gap: 32px; }
}

/* ------------------------------------------------------------------
   Sections and grids
------------------------------------------------------------------ */
.section { padding: clamp(56px, 8vw, 96px) 0; }
[id] { scroll-margin-top: 84px; } /* keep anchored headings clear of the sticky nav */
.section--alt { background: var(--bg-alt); }
.section__title { margin-bottom: .4em; }
.section__intro { color: var(--muted); max-width: 64ch; margin-bottom: 2.2rem; font-size: 1.08rem; }

.grid { display: grid; gap: 20px; }
.grid--3 { grid-template-columns: repeat(3, 1fr); }
@media (max-width: 960px) { .grid--3 { grid-template-columns: repeat(2, 1fr); } }
@media (max-width: 620px) { .grid--3 { grid-template-columns: 1fr; } }

.feature, .service, .case {
  background: var(--surface); border: 1px solid var(--border); border-radius: var(--radius);
  padding: 26px; box-shadow: var(--shadow);
}
.feature p, .case p:last-child { margin-bottom: 0; color: var(--muted); }
.feature h3::before {
  content: ""; display: block; width: 36px; height: 4px; border-radius: 2px;
  background: var(--accent); margin-bottom: 14px;
}

/* comparison table */
.compare { margin-top: 2.5rem; overflow-x: auto; }
.compare table { width: 100%; border-collapse: collapse; background: var(--surface); border: 1px solid var(--border); border-radius: var(--radius); overflow: hidden; }
.compare th, .compare td { text-align: left; padding: 14px 16px; border-bottom: 1px solid var(--border); vertical-align: top; }
.compare thead th { background: var(--bg-alt); font-size: .85rem; text-transform: uppercase; letter-spacing: .06em; color: var(--muted); }
.compare tbody th { font-weight: 700; width: 24%; }
.compare tbody td:nth-child(2) { color: var(--muted); }
.compare tbody td:nth-child(3) { font-weight: 600; }
.compare tr:last-child th, .compare tr:last-child td { border-bottom: 0; }
@media (max-width: 620px) {
  .compare th, .compare td { padding: 10px 12px; font-size: .92rem; }
}

/* services */
.service { display: flex; flex-direction: column; }
.service__kicker { font-size: .75rem; text-transform: uppercase; letter-spacing: .08em; color: var(--accent-strong); font-weight: 700; margin-bottom: .4rem; }
.service p { color: var(--muted); }
.service .price { margin-top: auto; color: var(--text); font-size: .95rem; padding-top: .5rem; }
.service .price strong { font-size: 1.3rem; }
.service .link { margin-top: .4rem; }

/* steps */
.steps { list-style: none; counter-reset: step; display: grid; grid-template-columns: repeat(4, 1fr); gap: 20px; }
.steps li { counter-increment: step; position: relative; padding-top: 56px; }
.steps li::before {
  content: counter(step, decimal-leading-zero); position: absolute; top: 0; left: 0;
  width: 44px; height: 44px; border-radius: 12px; background: var(--navy); color: #fff;
  display: grid; place-items: center; font-weight: 800; font-size: .95rem;
}
.steps p { color: var(--muted); margin: 0; }
@media (max-width: 960px) { .steps { grid-template-columns: repeat(2, 1fr); } }
@media (max-width: 560px) { .steps { grid-template-columns: 1fr; } }

/* cases */
.tags { display: flex; flex-wrap: wrap; gap: 6px; margin-bottom: .8rem; }
.tags span {
  font-size: .72rem; font-weight: 700; text-transform: uppercase; letter-spacing: .06em;
  background: var(--accent-soft); color: var(--accent-strong); padding: 4px 9px; border-radius: 999px;
}

/* about */
.about { display: grid; grid-template-columns: 220px 1fr; gap: 40px; align-items: start; }
.about__photo {
  width: 220px; aspect-ratio: 1; border-radius: var(--radius); background: var(--navy-soft);
  color: #fff; display: grid; place-items: center; font-size: 3rem; font-weight: 800;
}
.about__photo img { width: 100%; height: 100%; object-fit: cover; border-radius: var(--radius); }
.about__copy p { color: var(--muted); max-width: 68ch; }
.chips { list-style: none; display: flex; flex-wrap: wrap; gap: 8px; }
.chips li { font-size: .88rem; font-weight: 600; border: 1px solid var(--border); background: var(--surface); padding: 6px 12px; border-radius: 999px; }
@media (max-width: 760px) {
  .about { grid-template-columns: 1fr; }
  .about__photo { width: 140px; font-size: 2rem; }
}

/* faq */
.faq { border-bottom: 1px solid var(--border); padding: 6px 0; }
.faq summary {
  cursor: pointer; font-weight: 700; padding: 14px 36px 14px 0; list-style: none; position: relative; font-size: 1.05rem;
}
.faq summary::-webkit-details-marker { display: none; }
.faq summary::after {
  content: "+"; position: absolute; right: 4px; top: 50%; transform: translateY(-50%);
  font-size: 1.4rem; color: var(--accent); font-weight: 400;
}
.faq[open] summary::after { content: "–"; }
.faq p { color: var(--muted); margin: 0 0 14px; max-width: 70ch; }

/* contact */
.contact { display: grid; grid-template-columns: 1fr 1.2fr; gap: 48px; align-items: start; }
.contact__copy p { color: var(--muted); max-width: 48ch; }
.contact__list { list-style: none; display: grid; gap: 8px; font-weight: 600; }
.contact__list a[hidden] { display: none; }
.form {
  background: var(--surface); border: 1px solid var(--border); border-radius: var(--radius);
  padding: 28px; box-shadow: var(--shadow); display: grid; gap: 16px;
}
.form__row { display: grid; gap: 6px; }
.form__row--2 { grid-template-columns: 1fr 1fr; gap: 16px; }
.form__row--2 > div { display: grid; gap: 6px; }
.form label { font-size: .9rem; font-weight: 700; }
.form input, .form select, .form textarea {
  font: inherit; color: var(--text); background: var(--bg); border: 1px solid var(--border);
  border-radius: var(--radius-sm); padding: 11px 12px; width: 100%;
}
.form input:focus, .form select:focus, .form textarea:focus { outline: 2px solid var(--accent); outline-offset: 1px; border-color: var(--accent); }
.form textarea { resize: vertical; min-height: 120px; }
.form__note { font-size: .82rem; color: var(--muted); margin: 0; }
.form__error { margin: 0; padding: 10px 12px; border-radius: var(--radius-sm); background: #fdecec; color: #991b1b; border: 1px solid #f5c2c2; font-size: .92rem; }
.form__error[hidden] { display: none; }
.hp { position: absolute; left: -9999px; width: 1px; height: 1px; overflow: hidden; }
@media (max-width: 860px) {
  .contact { grid-template-columns: 1fr; gap: 28px; }
}
@media (max-width: 480px) {
  .form__row--2 { grid-template-columns: 1fr; }
  .form { padding: 20px; }
}

/* footer */
.footer { border-top: 1px solid var(--border); padding: 28px 0; font-size: .9rem; color: var(--muted); }
.footer__inner { display: flex; flex-wrap: wrap; justify-content: space-between; gap: 8px 16px; }
.footer p { margin: 0; }

/* consent banner */
.consent { position: fixed; inset: auto 16px 16px 16px; z-index: 60; display: flex; justify-content: center; }
.consent[hidden] { display: none; }
.consent__box {
  background: var(--surface); border: 1px solid var(--border); border-radius: var(--radius);
  box-shadow: var(--shadow); padding: 18px 20px; max-width: 560px; width: 100%; font-size: .92rem;
}
.consent__box p { margin: 0 0 .5em; }
.consent__actions { display: flex; gap: 10px; justify-content: flex-end; margin-top: 8px; flex-wrap: wrap; }

/* simple pages (privacy, thank-you) */
.page { padding: clamp(40px, 6vw, 72px) 0; }
.page h1 { font-size: clamp(1.8rem, 4vw, 2.6rem); }
.page h2 { font-size: 1.35rem; margin-top: 2rem; }
.page p, .page li { color: var(--muted); }
.page ul { padding-left: 1.2em; margin-bottom: 1em; }
.page li { margin-bottom: .3em; }
.page--center { text-align: center; }
.page--center .btn { margin-top: 1rem; }

/* checklist (scope of work on the landing pages hyva.html / upgrade.html) */
.checklist { list-style: none; display: grid; gap: 16px 32px; }
.checklist li { position: relative; padding-left: 30px; color: var(--muted); }
.checklist li::before {
  content: "✓"; position: absolute; left: 0; top: 0; color: var(--accent); font-weight: 800;
}
.checklist strong { display: block; color: var(--text); margin-bottom: 2px; }
@media (min-width: 761px) { .checklist--2 { grid-template-columns: 1fr 1fr; } }

/* dark statement band (commitment section) */
.section--dark { background: var(--navy); color: var(--on-navy); }
.section--dark .section__intro { color: rgba(255,255,255,.78); }
.section--dark .feature { background: rgba(255,255,255,.06); border-color: rgba(255,255,255,.14); box-shadow: none; }
.section--dark .feature h3 { color: #fff; }
.section--dark .feature p { color: rgba(255,255,255,.8); }

/* certification badge */
.trust img { width: 22px; height: 22px; vertical-align: -5px; margin-right: 4px; }
.trust li.has-badge::before { content: none; }
.about__badge { margin-top: 16px; display: flex; align-items: center; gap: 12px; }
.about__badge img { width: 72px; height: 72px; flex: none; }
.about__badge span { font-size: .85rem; font-weight: 600; color: var(--muted); line-height: 1.35; }
.about__badge span strong { display: block; color: var(--text); font-size: .95rem; }
@media (max-width: 760px) { .about__badge { justify-content: flex-start; } }
a.about__badge { color: inherit; text-decoration: none; }
a.about__badge:hover span strong { color: var(--accent-strong); }
.trust li.has-badge a { color: inherit; }
.trust img { display: inline-block; }

/* full-width service card (7th card in the 3-column grid) */
.service--wide { grid-column: 1 / -1; flex-direction: row; align-items: center; gap: 32px; }
.service--wide .service__main { flex: 1 1 auto; }
.service--wide .service__main p:last-child { margin-bottom: 0; }
.service--wide .service__aside { flex: 0 0 auto; min-width: 180px; text-align: left; }
.service--wide .service__aside .price { margin-top: 0; padding-top: 0; }
@media (max-width: 760px) {
  .service--wide { flex-direction: column; align-items: stretch; gap: 8px; }
  .service--wide .service__aside { min-width: 0; }
}

/* readability: dark text on orange primary buttons, quieter CTA in the nav */
.btn--primary, .btn--primary:hover { color: var(--navy); }
@media (prefers-color-scheme: dark) {
  :root:not([data-theme="light"]) .btn--primary,
  :root:not([data-theme="light"]) .btn--primary:hover { color: #0b1b33; }
}
.nav__menu .btn--primary { background: transparent; color: var(--text); border-color: var(--accent); }
.nav__menu .btn--primary:hover { background: var(--accent-soft); color: var(--text); border-color: var(--accent-strong); }
@media (prefers-color-scheme: dark) {
  :root:not([data-theme="light"]) .nav__menu .btn--primary,
  :root:not([data-theme="light"]) .nav__menu .btn--primary:hover { color: var(--text); }
}
.trust img { margin-right: 9px; }
.nowrap { white-space: nowrap; }

/* casual photo under the contact details */
.contact__photo { display: block; width: 100%; max-width: 470px; height: auto; margin-top: 28px; border-radius: var(--radius); box-shadow: var(--shadow); }

/* mobile menu: keep the full pill border on the CTA (the divider rule removed its bottom edge) */
@media (max-width: 860px) {
  .nav__menu a.btn { border-bottom: 2px solid var(--accent); padding: 11px 18px; margin: 14px 0 4px; }
}

/* images keep their aspect ratio even when width/height attributes are set */
img { height: auto; }

/* always dark (decision 2026-10-15): dark tokens apply regardless of the OS setting */
:root {
  color-scheme: dark;
  --bg: #0b1220;
  --bg-alt: #0f172a;
  --surface: #111b2e;
  --border: #233049;
  --text: #e5e7eb;
  --muted: #a3adbd;
  --accent: #ff7a2f;
  --accent-strong: #ff9456;
  --accent-soft: #2a1a10;
  --navy: #0a1426;
  --navy-soft: #122040;
  --shadow: 0 1px 2px rgba(0,0,0,.4), 0 8px 24px rgba(0,0,0,.35);
}
.btn--primary, .btn--primary:hover { color: #0b1b33; }
.nav__menu .btn--primary, .nav__menu .btn--primary:hover { color: var(--text); }

/* palette: blue-grey slate background instead of deep navy (2026-10-15) */
:root:not([data-theme="light"]) {
  --bg: #26303f;
  --bg-alt: #2b3646;
  --surface: #303c4e;
  --border: #44526a;
  --text: #eaeef4;
  --muted: #b7c1cf;
  --navy: #151c28;
  --navy-soft: #1c2534;
  --accent-soft: #3a2a1f;
  --shadow: 0 1px 2px rgba(0,0,0,.3), 0 8px 24px rgba(0,0,0,.28);
}
.nav { background: color-mix(in srgb, var(--bg) 88%, transparent); }

/* palette: light pastel blue-grey, always on (decision 2026-10-15, replaces the dark variants above) */
:root:not([data-theme="light"]), :root {
  color-scheme: light;
  --bg: #e9eef4;
  --bg-alt: #dfe6ee;
  --surface: #ffffff;
  --border: #cfd8e3;
  --text: #182130;
  --muted: #4f5b6c;
  --accent: #e8590c;
  --accent-strong: #c2410c;
  --accent-soft: #fde9dc;
  --navy: #0b1b33;
  --navy-soft: #13294b;
  --on-navy: #ffffff;
  --shadow: 0 1px 2px rgba(24,33,48,.06), 0 8px 24px rgba(24,33,48,.08);
}
.nav { background: color-mix(in srgb, var(--bg) 90%, transparent); }
.hero { background: radial-gradient(900px 400px at 85% -10%, #fbe3d3, transparent 70%), var(--bg); }
.section--dark .feature { background: rgba(255,255,255,.07); border-color: rgba(255,255,255,.16); }

/* palette: light pastel sage (trial 2026-10-15) */
:root:not([data-theme="light"]), :root {
  --bg: #e8ede6;
  --bg-alt: #dfe6dc;
  --surface: #ffffff;
  --border: #cbd6c9;
  --text: #1b2420;
  --muted: #4f5f57;
  --accent-soft: #fbe7d8;
  --shadow: 0 1px 2px rgba(27,36,32,.06), 0 8px 24px rgba(27,36,32,.08);
}
.hero { background: radial-gradient(900px 400px at 85% -10%, #f6e2cf, transparent 70%), var(--bg); }
