:root {
  --ink: #0B2540;
  --text: #334155;
  --muted: #5B6B7B;
  --accent: #0870B0;
  --accent-ink: #065A8E;
  --mint: #3ED3E0;
  --bg: #F7F9FA;
  --card: #FFFFFF;
  --line: #DCE3E8;
  --chip: #E7F4FA;
  --r: 14px;
  --serif: ui-serif, Georgia, "Times New Roman", serif;
  --sans: system-ui, -apple-system, "Segoe UI", Roboto, "Helvetica Neue", Arial, sans-serif;
}

*, *::before, *::after { box-sizing: border-box; }
html { -webkit-text-size-adjust: 100%; scroll-behavior: smooth; }
body {
  margin: 0;
  background: var(--bg);
  color: var(--text);
  font: 17px/1.65 var(--sans);
  overflow-x: clip;
}
img, svg { max-width: 100%; height: auto; display: block; }
h1, h2, h3, .hero .lead, .card p, .prose p, .prose li {
  overflow-wrap: anywhere;
  word-break: break-word;
}
.grid > *,
.feature > *,
.steps > *,
.anno,
.card {
  min-width: 0;
}
a { color: var(--accent-ink); }
a:hover { color: var(--accent); }
a:focus-visible,
summary:focus-visible,
button:focus-visible {
  outline: 3px solid var(--accent);
  outline-offset: 3px;
  border-radius: 6px;
}

.wrap { max-width: 1080px; margin: 0 auto; padding: 0 20px; }
.skip {
  position: absolute;
  left: -999px;
  top: 8px;
  background: #fff;
  padding: 8px 12px;
  border-radius: 8px;
  z-index: 100;
}
.skip:focus { left: 12px; }

/* Header */
.top {
  background: #fff;
  border-bottom: 1px solid var(--line);
  position: sticky;
  top: 0;
  z-index: 50;
}
.top .wrap {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 16px;
  min-height: 68px;
}
.brand {
  display: flex;
  align-items: center;
  gap: 12px;
  color: var(--ink);
  text-decoration: none;
  font-weight: 600;
  letter-spacing: .2px;
  flex-shrink: 0;
}
.brand img { flex: none; width: 56px; height: 48px; }
.brand small {
  display: block;
  font-weight: 400;
  font-size: 12px;
  color: var(--muted);
  letter-spacing: 0;
}
.nav {
  display: none;
  align-items: center;
  gap: 4px 14px;
  flex-wrap: wrap;
  justify-content: flex-end;
}
.nav a {
  color: var(--ink);
  text-decoration: none;
  font-size: 14px;
  font-weight: 500;
  padding: 6px 0;
}
.nav a:hover { color: var(--accent); }
.nav a[aria-current="page"] { color: var(--accent-ink); border-bottom: 2px solid var(--mint); }
.lang {
  display: inline-flex;
  gap: 6px;
  align-items: center;
  font-size: 13px;
  margin-left: 8px;
  padding-left: 12px;
  border-left: 1px solid var(--line);
}
.lang a { color: var(--muted); text-decoration: none; font-weight: 600; }
.lang a[aria-current="true"] { color: var(--ink); }
.top-cta { display: none; }
@media (min-width: 900px) {
  .nav { display: flex; }
  .top-cta { display: inline-flex; }
}

/* Buttons */
.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-height: 46px;
  padding: 0 20px;
  border-radius: 999px;
  background: var(--accent);
  color: #fff;
  text-decoration: none;
  font-weight: 600;
  border: none;
  cursor: pointer;
}
.btn:hover { background: var(--accent-ink); color: #fff; }
.btn.ghost {
  background: transparent;
  border: 1.5px solid rgba(255,255,255,.55);
  color: #fff;
}
.btn.ghost:hover { background: rgba(255,255,255,.08); color: #fff; }
.btn.outline {
  background: transparent;
  border: 1.5px solid var(--accent);
  color: var(--accent-ink);
}
.btn.outline:hover { background: var(--chip); color: var(--accent-ink); }

/* Hero — mobile-first: no viewport-height; desktop min-height only ≥900px */
.hero {
  background:
    radial-gradient(ellipse 80% 60% at 90% 10%, rgba(62,211,224,.12), transparent 50%),
    linear-gradient(165deg, var(--ink) 0%, #0F3A66 55%, #0A2D4F 100%);
  color: #fff;
  padding: 28px 0 32px;
  position: relative;
  overflow: hidden;
}
.hero-home {
  display: block;
  padding: 28px 0 32px;
}
.hero .wrap { position: relative; z-index: 1; width: 100%; }
.hero::after { content: none; }
.eyebrow {
  color: var(--mint);
  font-weight: 600;
  font-size: 13px;
  letter-spacing: 1.2px;
  text-transform: uppercase;
  margin: 0 0 12px;
}
.hero h1 {
  font-family: var(--serif);
  font-weight: 600;
  font-size: clamp(26px, 6.5vw, 48px);
  line-height: 1.15;
  margin: 0 0 12px;
  max-width: 20ch;
  color: #fff;
}
.hero .lead {
  font-size: clamp(16px, 3.8vw, 20px);
  color: #D5E1EA;
  max-width: 58ch;
  margin: 0 0 16px;
}
.cta {
  display: flex;
  flex-wrap: wrap;
  gap: 12px;
  margin-bottom: 16px;
}
.cta.center { justify-content: center; }
.cta.spaced { margin: 24px 0; }
.stack-gap { margin-top: 24px; }
.standards {
  display: flex;
  flex-wrap: wrap;
  gap: 8px 18px;
  padding: 0;
  margin: 0;
  list-style: none;
  color: #A9C3D3;
  font-size: 14px;
}
.standards li::before {
  content: "✓";
  color: var(--mint);
  margin-right: 6px;
}

/* Breadcrumb */
.crumb {
  font-size: 13px;
  color: var(--muted);
  padding: 14px 0 0;
  margin: 0;
  list-style: none;
  display: flex;
  flex-wrap: wrap;
  gap: 4px 0;
}
.crumb li:not(:last-child)::after {
  content: "/";
  margin: 0 8px;
  color: var(--line);
}
.crumb a { color: var(--muted); text-decoration: none; }
.crumb a:hover { color: var(--accent); }
.crumb [aria-current="page"] { color: var(--ink); }

/* Sections — mobile ≤32px; grow with clamp on larger screens */
section { padding: clamp(24px, 4vw, 56px) 0; }
.page-hero + section { padding-top: clamp(20px, 3vw, 40px); }
h1, h2, h3 { font-family: var(--serif); color: var(--ink); }
h2 {
  font-size: clamp(22px, 3.5vw, 32px);
  line-height: 1.25;
  margin: 0 0 10px;
  font-weight: 600;
}
h3 {
  font-size: 19px;
  line-height: 1.3;
  margin: 0 0 8px;
  font-weight: 600;
}
.intro {
  max-width: 65ch;
  margin: 0 0 20px;
  color: var(--muted);
}
.prose { max-width: 70ch; }
.prose p { margin: 0 0 1.1em; }
.prose ul, .prose ol { margin: 0 0 1.1em; padding-left: 1.3em; }
.prose li { margin-bottom: .4em; }
.alt { background: #EEF3F5; }
.tight { padding: clamp(24px, 3vw, 40px) 0; }

/* Cards / grids */
.grid { display: grid; gap: 12px; grid-template-columns: 1fr; }
@media (min-width: 720px) {
  .grid { gap: 18px; }
  .grid.two { grid-template-columns: 1fr 1fr; }
  .grid.three { grid-template-columns: 1fr 1fr 1fr; }
}
@media (min-width: 1000px) {
  .grid.three { grid-template-columns: 1fr 1fr 1fr; }
}
.card {
  background: var(--card);
  border: 1px solid var(--line);
  border-radius: var(--r);
  padding: 16px;
  position: relative;
}
.card.flagship {
  border-color: #0870B0;
  box-shadow: 0 0 0 1px rgba(8,112,176,.12);
}
.card-flag {
  position: absolute;
  top: 14px;
  right: 14px;
  margin: 0;
  font-size: 12px;
  font-weight: 700;
  letter-spacing: .04em;
  text-transform: uppercase;
  color: #065A8E;
  background: var(--chip);
  border: 1px solid #C6E3F2;
  border-radius: 6px;
  padding: 4px 8px;
}
.card p { margin: 0 0 14px; }
.card .more {
  font-weight: 600;
  text-decoration: none;
  font-size: 15px;
}
.card .more::after { content: " →"; }
.icon {
  width: 40px;
  height: 40px;
  border-radius: 10px;
  background: var(--chip);
  display: grid;
  place-items: center;
  margin-bottom: 14px;
}
.tags {
  display: flex;
  flex-wrap: wrap;
  gap: 6px;
  list-style: none;
  padding: 0;
  margin: 0;
}
.tags li {
  font-size: 13px;
  line-height: 1;
  padding: 7px 10px;
  border-radius: 999px;
  background: var(--chip);
  color: var(--accent-ink);
  border: 1px solid #C6E3F2;
}

/* AI highlight flagship */
.ai-flag {
  background:
    linear-gradient(135deg, #0B2540 0%, #0F3A66 60%, #065A8E 100%);
  color: #D5E1EA;
  border-radius: var(--r);
  padding: 16px;
  position: relative;
  overflow: hidden;
  border: 1px solid rgba(62,211,224,.25);
}
.ai-flag::before { content: none; }
.ai-flag h2 { color: #fff; margin-bottom: 8px; }
.ai-flag .eyebrow { margin-bottom: 8px; }
.ai-flag p { max-width: 62ch; margin: 0 0 16px; }
.ai-flag .btn { margin-right: 10px; margin-bottom: 8px; }
.ai-points {
  display: grid;
  gap: 12px;
  list-style: none;
  padding: 0;
  margin: 0 0 16px;
}
@media (min-width: 720px) {
  .ai-points { grid-template-columns: 1fr 1fr; }
  .ai-flag { padding: clamp(24px, 4vw, 40px); }
}
.ai-points li {
  background: rgba(255,255,255,.06);
  border: 1px solid rgba(255,255,255,.1);
  border-radius: 10px;
  padding: 12px 14px;
  font-size: 15px;
}
.ai-points strong { display: block; color: var(--mint); margin-bottom: 4px; font-size: 14px; }

/* Feature deep-dive with annotation */
.feature {
  display: grid;
  gap: 16px;
  align-items: start;
  margin: 20px 0;
}
@media (min-width: 800px) {
  .feature { grid-template-columns: 1.2fr .8fr; gap: 40px; margin: 36px 0; }
}
.feature.reverse { direction: rtl; }
.feature.reverse > * { direction: ltr; }
.anno {
  background: var(--card);
  border: 1px solid var(--line);
  border-radius: var(--r);
  padding: 16px;
}
.anno h3 { font-size: 15px; text-transform: uppercase; letter-spacing: .6px; color: var(--muted); font-family: var(--sans); font-weight: 700; }
.anno svg {
  display: block;
  width: 100%;
  max-width: 100%;
  height: auto;
  margin-top: 12px;
}
.anno-figures {
  list-style: none;
  padding: 0;
  margin: 12px 0 0;
  display: grid;
  gap: 10px;
}
.anno-figures li {
  display: flex;
  gap: 12px;
  align-items: baseline;
  border-top: 1px solid var(--line);
  padding-top: 10px;
}
.anno-figures strong {
  font-family: var(--serif);
  font-size: 22px;
  color: var(--accent-ink);
  min-width: 4.5ch;
}

/* Comparison table */
.table-wrap { overflow-x: auto; margin: 24px 0; -webkit-overflow-scrolling: touch; }
table.compare {
  width: 100%;
  border-collapse: collapse;
  background: var(--card);
  border: 1px solid var(--line);
  border-radius: var(--r);
  font-size: 15px;
  min-width: 560px;
}
table.compare th,
table.compare td {
  padding: 14px 16px;
  text-align: left;
  border-bottom: 1px solid var(--line);
  vertical-align: top;
}
table.compare th {
  background: var(--ink);
  color: #fff;
  font-weight: 600;
  font-family: var(--sans);
}
table.compare th:first-child { border-radius: calc(var(--r) - 1px) 0 0 0; }
table.compare th:last-child { border-radius: 0 calc(var(--r) - 1px) 0 0; }
table.compare tbody tr:last-child td { border-bottom: none; }
table.compare td:first-child { font-weight: 600; color: var(--ink); width: 22%; }
table.compare tbody tr:nth-child(even) { background: #F3F7F9; }

/* Credibility / standards */
.cred-grid {
  display: grid;
  gap: 12px;
  grid-template-columns: 1fr;
  list-style: none;
  padding: 0;
  margin: 0;
}
@media (min-width: 600px) {
  .cred-grid { grid-template-columns: 1fr 1fr; }
}
@media (min-width: 900px) {
  .cred-grid { grid-template-columns: 1fr 1fr 1fr; }
}
.cred-grid li {
  background: var(--card);
  border: 1px solid var(--line);
  border-radius: 10px;
  padding: 16px 18px;
}
.cred-grid strong { display: block; color: var(--ink); margin-bottom: 4px; }

/* Sectors / topics / steps */
.sectors {
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
  list-style: none;
  padding: 0;
  margin: 0;
}
.sectors li {
  background: var(--card);
  border: 1px solid var(--line);
  border-radius: 10px;
  padding: 10px 14px;
  font-weight: 500;
  color: var(--ink);
}
.topics {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  list-style: none;
  padding: 0;
  margin: 0;
}
.topics li {
  background: var(--card);
  border: 1px solid var(--line);
  border-radius: 999px;
  padding: 8px 14px;
  font-size: 15px;
  color: var(--ink);
}
.steps {
  counter-reset: s;
  list-style: none;
  padding: 0;
  margin: 0;
  display: grid;
  gap: 12px;
}
@media (min-width: 720px) {
  .steps { gap: 18px; grid-template-columns: repeat(2, 1fr); }
  .steps.steps-4 { grid-template-columns: repeat(2, 1fr); }
  .steps.steps-5 { grid-template-columns: repeat(3, 1fr); }
}
@media (min-width: 1100px) {
  .steps.steps-4 { grid-template-columns: repeat(4, 1fr); }
  .steps.steps-5 { grid-template-columns: repeat(5, 1fr); }
}
.steps li {
  counter-increment: s;
  background: var(--card);
  border: 1px solid var(--line);
  border-radius: var(--r);
  padding: 16px;
}
.steps li::before {
  content: counter(s);
  display: grid;
  place-items: center;
  width: 34px;
  height: 34px;
  border-radius: 50%;
  background: var(--ink);
  color: #fff;
  font-weight: 700;
  margin-bottom: 10px;
}
.steps strong {
  display: block;
  color: var(--ink);
  font-size: 18px;
  margin-bottom: 4px;
}

/* FAQ */
details {
  background: var(--card);
  border: 1px solid var(--line);
  border-radius: 12px;
  padding: 0 20px;
  margin-bottom: 10px;
}
summary {
  cursor: pointer;
  font-weight: 600;
  color: var(--ink);
  padding: 16px 0;
  min-height: 44px;
  list-style: none;
}
summary::-webkit-details-marker { display: none; }
summary::after {
  content: "+";
  float: right;
  color: var(--accent);
  font-size: 22px;
  line-height: 1;
}
details[open] summary::after { content: "–"; }
details p { margin: 0 0 18px; }

/* Cross-links */
.related {
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
  list-style: none;
  padding: 0;
  margin: 16px 0 0;
}
.related a {
  display: inline-block;
  padding: 10px 14px;
  background: var(--card);
  border: 1px solid var(--line);
  border-radius: 10px;
  text-decoration: none;
  color: var(--ink);
  font-weight: 500;
  font-size: 15px;
}
.related a:hover { border-color: var(--accent); color: var(--accent-ink); }

/* Contact CTA */
.contact {
  background: var(--ink);
  color: #D5E1EA;
  text-align: center;
}
.contact h2 { color: #fff; }
.contact p { max-width: 56ch; margin: 0 auto 22px; }
.contact .cta { justify-content: center; }

/* Footer */
footer {
  background: #0A1F2E;
  color: #93A8B8;
  font-size: 14px;
  padding: 32px 0 24px;
}
footer a { color: #B8CBD8; text-decoration: none; }
footer a:hover { color: #fff; }
.foot-grid {
  display: grid;
  gap: 24px;
  margin-bottom: 24px;
}
@media (min-width: 700px) {
  .foot-grid { grid-template-columns: 1.4fr 1fr 1fr; }
}
.foot-grid h2 {
  font-family: var(--sans);
  font-size: 13px;
  text-transform: uppercase;
  letter-spacing: .8px;
  color: #D5E1EA;
  margin: 0 0 10px;
}
.foot-grid ul { list-style: none; padding: 0; margin: 0; }
.foot-grid li { margin-bottom: 6px; }
.foot-bottom {
  display: flex;
  flex-wrap: wrap;
  justify-content: space-between;
  gap: 10px;
  padding-top: 18px;
  border-top: 1px solid #1A3344;
}

/* 404 */
.err {
  text-align: center;
  padding: clamp(32px, 6vw, 80px) 0 clamp(40px, 8vw, 100px);
}
.err h1 { font-size: clamp(40px, 8vw, 72px); margin: 0 0 8px; }
.err p { color: var(--muted); max-width: 40ch; margin: 0 auto 24px; }

/* Page-specific compact hero (inner pages) */
.page-hero h1 { max-width: 22ch; }

/* Mobile / tablet <900px: kill leftover hero height + shrink diagrams */
@media (max-width: 899px) {
  .hero,
  .hero-home,
  .page-hero {
    min-height: 0;
    height: auto;
    display: block;
    justify-content: flex-start;
    align-items: stretch;
  }
  .anno svg {
    max-width: min(100%, 280px);
    max-height: 200px;
    width: 100%;
    height: auto;
    margin-inline: auto;
  }
  .feature {
    grid-template-columns: 1fr;
  }
}

/* Mobile tightening (<600px): hard caps on section/hero/card spacing */
@media (max-width: 599px) {
  section { padding: 24px 0; }
  .page-hero + section { padding-top: 20px; }
  .hero,
  .hero-home { padding: 24px 0 28px; }
  .card { padding: 16px; }
  .steps li { padding: 16px; }
  .anno { padding: 16px; }
  .grid,
  .steps { gap: 12px; }
  .sectors { gap: 8px; }
  .cta.spaced { margin: 16px 0; }
  .stack-gap { margin-top: 16px; }
  .contact p { margin: 0 auto 16px; }
  footer { padding: 24px 0 20px; }
  .foot-grid { gap: 16px; margin-bottom: 16px; }
  .wrap { padding: 0 16px; }
}

/* Desktop: taller hero + optional decorative ring (≥900px only) */
@media (min-width: 900px) {
  .hero {
    padding: clamp(40px, 5vw, 56px) 0 clamp(48px, 6vw, 64px);
  }
  .hero-home {
    min-height: calc(100vh - 69px);
    min-height: calc(100svh - 69px);
    display: flex;
    align-items: center;
    padding: clamp(32px, 4vw, 48px) 0;
  }
  .hero::after {
    content: "";
    position: absolute;
    right: -100px;
    top: -60px;
    width: 380px;
    height: 380px;
    border-radius: 50%;
    border: 1px solid rgba(62,211,224,.18);
    box-shadow: 0 0 0 50px rgba(62,211,224,.04), 0 0 0 100px rgba(62,211,224,.03);
    pointer-events: none;
  }
  .ai-flag::before {
    content: "";
    position: absolute;
    right: -40px;
    bottom: -40px;
    width: 180px;
    height: 180px;
    border-radius: 50%;
    background: rgba(62,211,224,.08);
    pointer-events: none;
  }
  .card { padding: 24px; }
  .steps li { padding: 22px; }
  .anno { padding: 20px; }
}

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