/* ==========================================================================
   Evmarcom Modern — design system
   ========================================================================== */

/* ---------- Tokens ---------- */
:root {
  /* Brand */
  --brand-blue: #17479e;
  --brand-green: #a6ce39;

  --blue-950: #050c1c;
  --blue-900: #081533;
  --blue-800: #0b2050;
  --blue-700: #102f72;
  --blue-600: #17479e;
  --blue-500: #2560c4;
  --blue-400: #4a86e8;
  --blue-300: #8db4f2;

  --green-700: #5d7d1e;
  --green-600: #7ba428;
  --green-500: #8fbb2f;
  --green-400: #a6ce39;
  --green-300: #c2df76;

  /* Semantic — light (default) */
  --bg: #ffffff;
  --bg-alt: #f4f7fb;
  --bg-sunken: #eaeff7;
  --surface: #ffffff;
  --surface-2: #f8fafd;
  --border: #dfe6f0;
  --border-strong: #c6d2e3;
  --text: #0b1424;
  --text-2: #3d4a60;
  --text-3: #5b6a80;
  --accent: var(--blue-600);
  --accent-contrast: #ffffff;
  --accent-soft: rgba(23, 71, 158, 0.08);
  --lime: #55731c;
  --lime-soft: rgba(166, 206, 57, 0.16);
  --ring: rgba(23, 71, 158, 0.45);

  --shadow-sm: 0 1px 2px rgba(11, 20, 36, 0.06), 0 1px 3px rgba(11, 20, 36, 0.05);
  --shadow-md: 0 4px 12px rgba(11, 20, 36, 0.07), 0 2px 4px rgba(11, 20, 36, 0.04);
  --shadow-lg: 0 18px 40px -12px rgba(11, 20, 36, 0.22), 0 4px 12px rgba(11, 20, 36, 0.06);
  --shadow-glow: 0 0 0 1px rgba(23, 71, 158, 0.12), 0 20px 50px -20px rgba(23, 71, 158, 0.4);

  /* Type */
  --font-sans: "Inter", -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, Helvetica, Arial, sans-serif;
  --font-display: "Manrope", "Inter", -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif;
  --font-mono: ui-monospace, SFMono-Regular, "SF Mono", Menlo, Consolas, monospace;

  --step--1: clamp(0.82rem, 0.79rem + 0.13vw, 0.89rem);
  --step-0: clamp(0.97rem, 0.94rem + 0.16vw, 1.06rem);
  --step-1: clamp(1.13rem, 1.06rem + 0.32vw, 1.31rem);
  --step-2: clamp(1.32rem, 1.19rem + 0.62vw, 1.66rem);
  --step-3: clamp(1.55rem, 1.32rem + 1.05vw, 2.13rem);
  --step-4: clamp(1.81rem, 1.44rem + 1.66vw, 2.73rem);
  --step-5: clamp(2.11rem, 1.53rem + 2.55vw, 3.5rem);
  --step-6: clamp(2.46rem, 1.57rem + 3.86vw, 4.5rem);

  /* Space */
  --sp-1: 0.25rem;
  --sp-2: 0.5rem;
  --sp-3: 0.75rem;
  --sp-4: 1rem;
  --sp-5: 1.5rem;
  --sp-6: 2rem;
  --sp-7: 3rem;
  --sp-8: 4rem;
  --sp-9: 6rem;
  --section-y: clamp(3.5rem, 2rem + 6vw, 6.5rem);

  --container: 1200px;
  --container-wide: 1360px;
  --container-narrow: 760px;
  --gutter: clamp(1rem, 0.4rem + 2.4vw, 2.5rem);

  --radius-sm: 6px;
  --radius: 12px;
  --radius-lg: 18px;
  --radius-xl: 26px;

  --header-h: 76px;
  --ease: cubic-bezier(0.22, 0.61, 0.36, 1);
  --ease-out-expo: cubic-bezier(0.16, 1, 0.3, 1);
}

/* Dark theme — auto, unless the visitor forced light */
@media (prefers-color-scheme: dark) {
  :root:not([data-theme="light"]) {
    --bg: #070c17;
    --bg-alt: #0b1220;
    --bg-sunken: #050a13;
    --surface: #101a2c;
    --surface-2: #142137;
    --border: #1f2e47;
    --border-strong: #2c3e5c;
    --text: #e9eef7;
    --text-2: #b3bfd2;
    --text-3: #8695ad;
    --accent: var(--blue-400);
    --accent-contrast: #05101f;
    --accent-soft: rgba(74, 134, 232, 0.14);
    --lime: var(--green-400);
    --lime-soft: rgba(166, 206, 57, 0.14);
    --ring: rgba(141, 180, 242, 0.5);
    --shadow-sm: 0 1px 2px rgba(0, 0, 0, 0.4);
    --shadow-md: 0 4px 14px rgba(0, 0, 0, 0.45);
    --shadow-lg: 0 20px 44px -14px rgba(0, 0, 0, 0.7);
    --shadow-glow: 0 0 0 1px rgba(74, 134, 232, 0.2), 0 20px 50px -20px rgba(23, 71, 158, 0.75);
  }
}

/* Dark theme — forced */
:root[data-theme="dark"] {
  --bg: #070c17;
  --bg-alt: #0b1220;
  --bg-sunken: #050a13;
  --surface: #101a2c;
  --surface-2: #142137;
  --border: #1f2e47;
  --border-strong: #2c3e5c;
  --text: #e9eef7;
  --text-2: #b3bfd2;
  --text-3: #8695ad;
  --accent: var(--blue-400);
  --accent-contrast: #05101f;
  --accent-soft: rgba(74, 134, 232, 0.14);
  --lime: var(--green-400);
  --lime-soft: rgba(166, 206, 57, 0.14);
  --ring: rgba(141, 180, 242, 0.5);
  --shadow-sm: 0 1px 2px rgba(0, 0, 0, 0.4);
  --shadow-md: 0 4px 14px rgba(0, 0, 0, 0.45);
  --shadow-lg: 0 20px 44px -14px rgba(0, 0, 0, 0.7);
  --shadow-glow: 0 0 0 1px rgba(74, 134, 232, 0.2), 0 20px 50px -20px rgba(23, 71, 158, 0.75);
}

/* ---------- Reset ---------- */
*,
*::before,
*::after { box-sizing: border-box; }

* { margin: 0; }

html {
  -webkit-text-size-adjust: 100%;
  scroll-behavior: smooth;
  scroll-padding-top: calc(var(--header-h) + 1.5rem);
}

body {
  background: var(--bg);
  color: var(--text);
  font-family: var(--font-sans);
  font-size: var(--step-0);
  line-height: 1.65;
  -webkit-font-smoothing: antialiased;
  text-rendering: optimizeLegibility;
  font-feature-settings: "cv05" 1, "ss01" 1;
  overflow-x: hidden;
}

img, svg, video, canvas { display: block; max-width: 100%; height: auto; }

h1, h2, h3, h4, h5 {
  font-family: var(--font-display);
  font-weight: 750;
  line-height: 1.12;
  letter-spacing: -0.022em;
  color: var(--text);
  text-wrap: balance;
}

h1 { font-size: var(--step-5); }
h2 { font-size: var(--step-4); }
h3 { font-size: var(--step-2); }
h4 { font-size: var(--step-1); }

p { text-wrap: pretty; }

a { color: var(--accent); text-decoration-thickness: 1px; text-underline-offset: 3px; }
a:hover { color: var(--blue-500); }

ul, ol { padding-inline-start: 1.15em; }

button, input, select, textarea { font: inherit; color: inherit; }

:where(a, button, input, select, textarea, summary, [tabindex]):focus-visible {
  outline: 2px solid var(--ring);
  outline-offset: 3px;
  border-radius: 4px;
}

::selection { background: var(--lime-soft); color: var(--text); }

hr { border: 0; border-top: 1px solid var(--border); margin: var(--sp-6) 0; }

/* ---------- Utilities ---------- */
.container {
  width: min(100% - (var(--gutter) * 2), var(--container));
  margin-inline: auto;
}
.container--wide { width: min(100% - (var(--gutter) * 2), var(--container-wide)); }
.container--narrow { width: min(100% - (var(--gutter) * 2), var(--container-narrow)); }

.section { padding-block: var(--section-y); }
.section--tight { padding-block: clamp(2.5rem, 1.5rem + 4vw, 4.5rem); }
.section--alt { background: var(--bg-alt); }

.screen-reader-text {
  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: var(--sp-4);
  top: -100px;
  z-index: 200;
  background: var(--accent);
  color: var(--accent-contrast);
  padding: 0.7rem 1.2rem;
  border-radius: var(--radius-sm);
  font-weight: 600;
  transition: top 0.2s var(--ease);
}
.skip-link:focus { top: var(--sp-4); }

/* ---------- Section heading ---------- */
.eyebrow {
  display: inline-flex;
  align-items: center;
  gap: 0.55rem;
  font-size: var(--step--1);
  font-weight: 650;
  letter-spacing: 0.13em;
  text-transform: uppercase;
  color: var(--lime);
  margin-bottom: var(--sp-4);
}
.eyebrow::before {
  content: "";
  width: 26px;
  height: 2px;
  background: currentColor;
  border-radius: 2px;
}

.section-head { max-width: 62ch; margin-bottom: clamp(2rem, 1rem + 3vw, 3.25rem); }
.section-head--center { margin-inline: auto; text-align: center; }
.section-head--center .eyebrow::before { display: none; }
.section-head p {
  color: var(--text-2);
  font-size: var(--step-1);
  margin-top: var(--sp-4);
  line-height: 1.6;
}

/* ---------- Buttons ---------- */
.btn {
  --btn-bg: var(--accent);
  --btn-fg: var(--accent-contrast);
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 0.6rem;
  padding: 0.85rem 1.5rem;
  border-radius: 999px;
  border: 1px solid transparent;
  background: var(--btn-bg);
  color: var(--btn-fg);
  font-weight: 650;
  font-size: var(--step-0);
  line-height: 1.2;
  text-decoration: none;
  cursor: pointer;
  transition: transform 0.18s var(--ease), box-shadow 0.22s var(--ease), background-color 0.2s var(--ease), border-color 0.2s var(--ease), color 0.2s var(--ease);
  white-space: nowrap;
}
.btn:hover {
  transform: translateY(-2px);
  box-shadow: var(--shadow-lg);
  color: var(--btn-fg);
}
.btn:active { transform: translateY(0); }
.btn svg { width: 1.05em; height: 1.05em; flex: none; transition: transform 0.22s var(--ease); }
.btn:hover svg.icon-arrow { transform: translateX(3px); }

.btn--lime { --btn-bg: var(--green-400); --btn-fg: #0b1424; }
.btn--ghost {
  --btn-bg: transparent;
  --btn-fg: var(--text);
  border-color: var(--border-strong);
}
.btn--ghost:hover { border-color: var(--accent); color: var(--accent); }
.btn--on-dark {
  --btn-bg: rgba(255, 255, 255, 0.08);
  --btn-fg: #fff;
  border-color: rgba(255, 255, 255, 0.28);
  backdrop-filter: blur(6px);
}
.btn--on-dark:hover { --btn-bg: rgba(255, 255, 255, 0.16); border-color: rgba(255, 255, 255, 0.5); }
.btn--sm { padding: 0.55rem 1.05rem; font-size: var(--step--1); }

.link-arrow {
  display: inline-flex;
  align-items: center;
  gap: 0.45rem;
  font-weight: 650;
  color: var(--accent);
  text-decoration: none;
}
.link-arrow svg { width: 1em; height: 1em; transition: transform 0.22s var(--ease); }
.link-arrow:hover svg { transform: translateX(4px); }

/* ---------- Header ---------- */
.site-header {
  position: sticky;
  top: 0;
  z-index: 100;
  background: color-mix(in srgb, var(--bg) 82%, transparent);
  backdrop-filter: saturate(180%) blur(14px);
  -webkit-backdrop-filter: saturate(180%) blur(14px);
  border-bottom: 1px solid transparent;
  transition: border-color 0.25s var(--ease), background-color 0.25s var(--ease), box-shadow 0.25s var(--ease);
}
.site-header.is-stuck {
  border-bottom-color: var(--border);
  box-shadow: var(--shadow-sm);
  background: color-mix(in srgb, var(--bg) 92%, transparent);
}

.header-inner {
  display: flex;
  align-items: center;
  gap: var(--sp-5);
  min-height: var(--header-h);
}

.brand { display: inline-flex; align-items: center; flex: none; }
.brand img { height: 40px; width: auto; }
@media (max-width: 480px) { .brand img { height: 32px; } }
:root[data-theme="dark"] .brand img,
.brand img.brand-logo--dark { }

/* Primary nav */
.primary-nav { margin-inline-start: auto; }
.primary-nav > ul {
  display: flex;
  align-items: center;
  gap: 0.15rem;
  list-style: none;
  margin: 0;
  padding: 0;
}
.primary-nav a {
  display: inline-flex;
  align-items: center;
  gap: 0.35rem;
  padding: 0.55rem 0.85rem;
  border-radius: 999px;
  font-size: var(--step--1);
  font-weight: 600;
  letter-spacing: -0.005em;
  color: var(--text-2);
  text-decoration: none;
  transition: color 0.18s var(--ease), background-color 0.18s var(--ease);
  white-space: nowrap;
}
.primary-nav a:hover,
.primary-nav li:hover > a,
.primary-nav li:focus-within > a { color: var(--text); background: var(--accent-soft); }
.primary-nav .current-menu-item > a,
.primary-nav .current-menu-ancestor > a,
.primary-nav .current-page-ancestor > a { color: var(--accent); }

.primary-nav > ul > li.menu-item-has-children > a::after {
  content: "";
  width: 0.5em; height: 0.5em;
  border-right: 2px solid currentColor;
  border-bottom: 2px solid currentColor;
  transform: rotate(45deg) translate(-2px, -2px);
  opacity: 0.6;
  transition: transform 0.2s var(--ease);
}
.primary-nav > ul > li:hover > a::after { transform: rotate(45deg) translate(0, 0); }

/* Plain dropdowns — only for top-level items that are NOT mega panels */
.primary-nav > ul > li:not(.has-mega) ul {
  position: absolute;
  min-width: 280px;
  list-style: none;
  margin: 0;
  padding: 0.5rem;
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  box-shadow: var(--shadow-lg);
  opacity: 0;
  visibility: hidden;
  transform: translateY(8px);
  transition: opacity 0.2s var(--ease), transform 0.2s var(--ease), visibility 0.2s;
  z-index: 20;
}
.primary-nav > ul > li { position: relative; }
.primary-nav > ul > li:not(.has-mega) > ul { top: calc(100% + 6px); left: 0; }
.primary-nav > ul > li:not(.has-mega) ul li { position: relative; }
.primary-nav > ul > li:not(.has-mega) ul ul { top: -0.5rem; left: calc(100% + 4px); }
.primary-nav > ul > li:not(.has-mega) li:hover > ul,
.primary-nav > ul > li:not(.has-mega) li:focus-within > ul { opacity: 1; visibility: visible; transform: translateY(0); }
.primary-nav > ul > li:not(.has-mega) ul a {
  display: flex;
  width: 100%;
  padding: 0.6rem 0.8rem;
  border-radius: var(--radius-sm);
  font-size: var(--step--1);
  color: var(--text-2);
  white-space: normal;
  line-height: 1.4;
}
.primary-nav > ul > li:not(.has-mega) ul a:hover { background: var(--accent-soft); color: var(--accent); }
.primary-nav > ul > li:not(.has-mega) ul .menu-item-has-children > a::after { transform: rotate(-45deg); margin-inline-start: auto; }
.primary-nav > ul > li:not(.has-mega) ul li:hover > a::after { transform: rotate(-45deg) translate(2px, 2px); }

/* Right-side actions */
.header-actions { display: flex; align-items: center; gap: 0.5rem; flex: none; }

.icon-btn {
  display: inline-grid;
  place-items: center;
  width: 40px; height: 40px;
  border-radius: 50%;
  border: 1px solid var(--border);
  background: var(--surface);
  color: var(--text-2);
  cursor: pointer;
  transition: color 0.18s var(--ease), border-color 0.18s var(--ease), transform 0.18s var(--ease);
}
.icon-btn:hover { color: var(--accent); border-color: var(--accent); transform: translateY(-1px); }
.icon-btn svg { width: 19px; height: 19px; }
.theme-toggle .icon-moon { display: none; }
:root[data-theme="dark"] .theme-toggle .icon-moon { display: block; }
:root[data-theme="dark"] .theme-toggle .icon-sun { display: none; }
@media (prefers-color-scheme: dark) {
  :root:not([data-theme="light"]) .theme-toggle .icon-moon { display: block; }
  :root:not([data-theme="light"]) .theme-toggle .icon-sun { display: none; }
}

.nav-toggle { display: none; }

@media (max-width: 1100px) {
  .primary-nav { display: none; }
  .nav-toggle { display: inline-grid; margin-inline-start: auto; }
  .header-actions .btn { display: none; }
}

/* ---------- Mobile drawer ---------- */
.mobile-drawer {
  position: fixed;
  inset: 0;
  z-index: 150;
  display: grid;
  grid-template-columns: 1fr min(88vw, 420px);
  visibility: hidden;
  pointer-events: none;
}
.mobile-drawer.is-open { visibility: visible; pointer-events: auto; }
.mobile-drawer__scrim {
  background: rgba(5, 10, 20, 0.55);
  backdrop-filter: blur(3px);
  opacity: 0;
  transition: opacity 0.3s var(--ease);
  border: 0;
  cursor: pointer;
}
.mobile-drawer.is-open .mobile-drawer__scrim { opacity: 1; }
.mobile-drawer__panel {
  background: var(--bg);
  border-inline-start: 1px solid var(--border);
  overflow-y: auto;
  overscroll-behavior: contain;
  padding: var(--sp-5) var(--sp-5) var(--sp-8);
  transform: translateX(100%);
  transition: transform 0.36s var(--ease-out-expo);
  display: flex;
  flex-direction: column;
  gap: var(--sp-5);
}
.mobile-drawer.is-open .mobile-drawer__panel { transform: translateX(0); }
.mobile-drawer__head { display: flex; align-items: center; justify-content: space-between; gap: var(--sp-4); }
.mobile-drawer__head img { height: 34px; width: auto; }

.mobile-nav ul { list-style: none; margin: 0; padding: 0; }
.mobile-nav > ul > li { border-bottom: 1px solid var(--border); }
.mobile-nav a {
  display: block;
  padding: 0.85rem 0;
  font-weight: 600;
  font-size: var(--step-1);
  color: var(--text);
  text-decoration: none;
}
.mobile-nav .sub-menu { display: none; padding-inline-start: 0.9rem; border-inline-start: 2px solid var(--border); margin-bottom: 0.6rem; }
.mobile-nav .sub-menu.is-open { display: block; }
.mobile-nav .sub-menu a { font-size: var(--step-0); font-weight: 500; color: var(--text-2); padding: 0.55rem 0; }
.mobile-nav .sub-menu .sub-menu a { font-size: var(--step--1); }
.mobile-nav li { position: relative; }
.submenu-toggle {
  position: absolute;
  top: 0.35rem; right: 0;
  width: 34px; height: 34px;
  display: grid; place-items: center;
  border: 1px solid var(--border);
  border-radius: 50%;
  background: transparent;
  color: var(--text-2);
  cursor: pointer;
  transition: transform 0.2s var(--ease), color 0.2s var(--ease);
}
.submenu-toggle[aria-expanded="true"] { transform: rotate(180deg); color: var(--accent); }
.submenu-toggle svg { width: 14px; height: 14px; }
.mobile-nav .sub-menu .submenu-toggle { top: 0.1rem; width: 28px; height: 28px; }

/* ---------- Hero (home) ---------- */
.hero {
  position: relative;
  isolation: isolate;
  background: var(--blue-950);
  color: #fff;
  overflow: hidden;
  padding-block: clamp(4rem, 2rem + 10vw, 8.5rem);
}
.hero__media {
  position: absolute;
  inset: 0;
  z-index: -2;
}
.hero__media img {
  width: 100%; height: 100%;
  object-fit: cover;
  object-position: 60% center;
  opacity: 0.5;
  filter: saturate(0.85) contrast(1.05);
}
.hero__overlay {
  position: absolute;
  inset: 0;
  z-index: -1;
  background:
    radial-gradient(90% 70% at 12% 20%, rgba(5, 12, 28, 0.94) 0%, rgba(5, 12, 28, 0.72) 45%, rgba(5, 12, 28, 0.3) 100%),
    linear-gradient(180deg, rgba(5, 12, 28, 0.85) 0%, rgba(5, 12, 28, 0.35) 45%, rgba(5, 12, 28, 0.9) 100%);
}
.hero__grid {
  position: absolute;
  inset: 0;
  z-index: -1;
  background-image:
    linear-gradient(rgba(255, 255, 255, 0.05) 1px, transparent 1px),
    linear-gradient(90deg, rgba(255, 255, 255, 0.05) 1px, transparent 1px);
  background-size: 64px 64px;
  mask-image: radial-gradient(70% 60% at 30% 40%, #000 0%, transparent 75%);
  -webkit-mask-image: radial-gradient(70% 60% at 30% 40%, #000 0%, transparent 75%);
}
.hero__inner { position: relative; display: grid; gap: var(--sp-7); }
@media (min-width: 900px) {
  .hero__inner { grid-template-columns: minmax(0, 1.05fr) minmax(0, 0.95fr); align-items: center; }
}
.hero h1 { font-size: var(--step-6); color: #fff; letter-spacing: -0.032em; }
.hero h1 .accent {
  background: linear-gradient(100deg, var(--green-400) 0%, var(--green-300) 40%, #ffffff 95%);
  -webkit-background-clip: text;
  background-clip: text;
  color: transparent;
}
.hero__lede {
  margin-top: var(--sp-5);
  font-size: var(--step-1);
  color: rgba(233, 238, 247, 0.82);
  max-width: 58ch;
}
.hero .eyebrow { color: var(--green-400); }
.hero__actions { display: flex; flex-wrap: wrap; gap: var(--sp-4); margin-top: var(--sp-6); }

.hero__stats {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(140px, 1fr));
  gap: var(--sp-4);
  margin-top: var(--sp-8);
  padding-top: var(--sp-6);
  border-top: 1px solid rgba(255, 255, 255, 0.14);
}
.hero__stat dt { font-size: var(--step--1); color: rgba(233, 238, 247, 0.6); letter-spacing: 0.04em; }
.hero__stat dd {
  margin: 0.2rem 0 0;
  font-family: var(--font-display);
  font-size: var(--step-2);
  font-weight: 750;
  color: #fff;
}

/* Radar visual */
.hero__visual { display: none; }
@media (min-width: 900px) { .hero__visual { display: block; } }
.radar { width: 100%; max-width: 460px; margin-inline: auto; aspect-ratio: 1; position: relative; }
.radar svg { width: 100%; height: 100%; overflow: visible; }
.radar__ring { fill: none; stroke: rgba(166, 206, 57, 0.35); stroke-width: 1; }
.radar__pulse { fill: none; stroke: var(--green-400); stroke-width: 1.5; transform-origin: center; animation: radar-pulse 4s var(--ease-out-expo) infinite; }
.radar__pulse:nth-of-type(2) { animation-delay: 1.33s; }
.radar__pulse:nth-of-type(3) { animation-delay: 2.66s; }
.radar__sweep { transform-origin: center; animation: radar-sweep 8s linear infinite; }
.radar__dot { fill: var(--green-400); }
.radar__dot--b { fill: var(--blue-300); }
@keyframes radar-pulse {
  0% { r: 40; opacity: 0.9; }
  100% { r: 230; opacity: 0; }
}
@keyframes radar-sweep { to { transform: rotate(360deg); } }

/* ---------- Page hero (inner pages) ---------- */
.page-hero {
  position: relative;
  isolation: isolate;
  background: var(--blue-950);
  color: #fff;
  overflow: hidden;
  padding-block: clamp(3rem, 2rem + 5vw, 5.5rem);
}
.page-hero__media { position: absolute; inset: 0; z-index: -2; }
.page-hero__media img { width: 100%; height: 100%; object-fit: cover; opacity: 0.32; }
.page-hero::after {
  content: "";
  position: absolute;
  inset: 0;
  z-index: -1;
  background:
    radial-gradient(80% 90% at 10% 0%, rgba(23, 71, 158, 0.55) 0%, transparent 60%),
    linear-gradient(180deg, rgba(5, 12, 28, 0.9) 0%, rgba(5, 12, 28, 0.78) 100%);
}
.page-hero::before {
  content: "";
  position: absolute;
  left: 0; right: 0; bottom: 0;
  height: 3px;
  background: linear-gradient(90deg, var(--green-400), var(--blue-500) 55%, transparent);
  z-index: 1;
}
.page-hero h1 { color: #fff; max-width: 20ch; }
.page-hero__lede { margin-top: var(--sp-4); color: rgba(233, 238, 247, 0.78); font-size: var(--step-1); max-width: 62ch; }

/* Breadcrumbs */
.breadcrumbs {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 0.4rem;
  font-size: var(--step--1);
  margin-bottom: var(--sp-5);
  color: rgba(233, 238, 247, 0.62);
}
.breadcrumbs a { color: inherit; text-decoration: none; }
.breadcrumbs a:hover { color: var(--green-400); }
.breadcrumbs span[aria-current] { color: #fff; font-weight: 600; }
.breadcrumbs .sep { opacity: 0.45; }

/* ---------- Cards ---------- */
.card-grid {
  display: grid;
  gap: clamp(1rem, 0.6rem + 1.4vw, 1.75rem);
  grid-template-columns: repeat(auto-fill, minmax(min(100%, 320px), 1fr));
}
.card-grid--2 { grid-template-columns: repeat(auto-fill, minmax(min(100%, 420px), 1fr)); }

.card {
  position: relative;
  display: flex;
  flex-direction: column;
  gap: var(--sp-4);
  padding: clamp(1.4rem, 1rem + 1vw, 2rem);
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: var(--radius-lg);
  overflow: hidden;
  isolation: isolate;
  transition: transform 0.28s var(--ease), box-shadow 0.28s var(--ease), border-color 0.28s var(--ease);
}
.card::before {
  content: "";
  position: absolute;
  inset: 0;
  z-index: -1;
  background: radial-gradient(120% 90% at 100% 0%, var(--accent-soft) 0%, transparent 60%);
  opacity: 0;
  transition: opacity 0.3s var(--ease);
}
.card::after {
  content: "";
  position: absolute;
  left: 0; top: 0; bottom: 0;
  width: 3px;
  background: linear-gradient(180deg, var(--green-400), var(--blue-500));
  transform: scaleY(0);
  transform-origin: top;
  transition: transform 0.32s var(--ease-out-expo);
}
.card:hover,
.card:focus-within {
  transform: translateY(-4px);
  border-color: var(--border-strong);
  box-shadow: var(--shadow-lg);
}
.card:hover::before, .card:focus-within::before { opacity: 1; }
.card:hover::after, .card:focus-within::after { transform: scaleY(1); }

.card__icon {
  display: grid;
  place-items: center;
  width: 52px; height: 52px;
  border-radius: 14px;
  background: var(--accent-soft);
  color: var(--accent);
  flex: none;
}
.card__icon svg { width: 26px; height: 26px; }
.card h3 { font-size: var(--step-1); letter-spacing: -0.015em; }
.card h3 a { color: inherit; text-decoration: none; }
.card h3 a::after { content: ""; position: absolute; inset: 0; }
.card p { color: var(--text-2); font-size: var(--step-0); margin: 0; }
.card__cta { margin-top: auto; padding-top: var(--sp-2); }

.card--muted { opacity: 0.86; }
.badge {
  display: inline-flex;
  align-items: center;
  gap: 0.35rem;
  padding: 0.25rem 0.65rem;
  border-radius: 999px;
  background: var(--lime-soft);
  color: var(--lime);
  font-size: 0.72rem;
  font-weight: 700;
  letter-spacing: 0.06em;
  text-transform: uppercase;
  width: fit-content;
}
:root[data-theme="dark"] .badge { color: var(--green-300); }
@media (prefers-color-scheme: dark) { :root:not([data-theme="light"]) .badge { color: var(--green-300); } }

/* ---------- Feature / highlight lists ---------- */
.feature-list {
  list-style: none;
  padding: 0;
  margin: 0;
  display: grid;
  gap: var(--sp-4);
}
@media (min-width: 760px) { .feature-list--2col { grid-template-columns: 1fr 1fr; column-gap: var(--sp-6); } }
.feature-list li {
  position: relative;
  padding-inline-start: 2.1rem;
  color: var(--text-2);
  line-height: 1.6;
}
.feature-list li::before {
  content: "";
  position: absolute;
  left: 0; top: 0.35em;
  width: 1.35rem; height: 1.35rem;
  border-radius: 50%;
  background: var(--lime-soft) url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='%237ba428' stroke-width='3.4' stroke-linecap='round' stroke-linejoin='round'%3E%3Cpolyline points='20 6 9 17 4 12'/%3E%3C/svg%3E") center / 0.78rem no-repeat;
}
.feature-list li strong, .feature-list li b { color: var(--text); font-weight: 650; }

/* ---------- Prose ---------- */
.prose { color: var(--text-2); font-size: var(--step-0); line-height: 1.72; }
.prose > * + * { margin-top: var(--sp-5); }
.prose h2 { font-size: var(--step-3); color: var(--text); margin-top: var(--sp-8); }
.prose h3 { font-size: var(--step-2); color: var(--text); margin-top: var(--sp-7); }
.prose h4 { font-size: var(--step-1); color: var(--text); margin-top: var(--sp-6); }
.prose > :first-child { margin-top: 0; }
.prose strong, .prose b { color: var(--text); font-weight: 650; }
.prose ul, .prose ol { display: grid; gap: var(--sp-3); padding-inline-start: 1.25em; }
.prose li::marker { color: var(--lime); }
.prose img { border-radius: var(--radius); box-shadow: var(--shadow-md); }
.prose figure { margin: var(--sp-6) 0; }
.prose figcaption { font-size: var(--step--1); color: var(--text-3); margin-top: var(--sp-3); text-align: center; }
.prose blockquote {
  border-inline-start: 3px solid var(--lime);
  padding-inline-start: var(--sp-5);
  font-size: var(--step-1);
  color: var(--text);
}
.prose .lead { font-size: var(--step-1); color: var(--text); line-height: 1.6; }

/* ---------- Spec tables ---------- */
.table-wrap {
  overflow-x: auto;
  border: 1px solid var(--border);
  border-radius: var(--radius);
  background: var(--surface);
  -webkit-overflow-scrolling: touch;
}
.prose table, .spec-table {
  width: 100%;
  border-collapse: collapse;
  font-size: var(--step--1);
  text-align: left;
}
.prose table th, .spec-table th {
  background: var(--surface-2);
  font-family: var(--font-display);
  font-weight: 700;
  color: var(--text);
  font-size: var(--step--1);
  letter-spacing: 0.02em;
}
.prose table th, .prose table td,
.spec-table th, .spec-table td {
  padding: 0.85rem 1.1rem;
  border-bottom: 1px solid var(--border);
  vertical-align: top;
}
.prose table tr:last-child td, .spec-table tr:last-child td { border-bottom: 0; }
.prose table tbody tr:hover, .spec-table tbody tr:hover { background: var(--accent-soft); }
.spec-table td:first-child, .prose table td:first-child { color: var(--text); font-weight: 600; width: 45%; min-width: 220px; }
.spec-table td p, .prose table td p { margin: 0; }
.spec-table td + td, .prose table td + td { color: var(--text-2); font-variant-numeric: tabular-nums; }

/* ---------- Media / gallery ---------- */
.media-grid {
  display: grid;
  gap: var(--sp-5);
  grid-template-columns: repeat(auto-fit, minmax(min(100%, 300px), 1fr));
}
.media-frame {
  position: relative;
  border: 1px solid var(--border);
  border-radius: var(--radius-lg);
  background: var(--surface-2);
  padding: var(--sp-4);
  overflow: hidden;
}
.media-frame img { border-radius: var(--radius-sm); width: 100%; }
.media-frame figcaption { margin-top: var(--sp-3); font-size: var(--step--1); color: var(--text-3); text-align: center; }

/* Split layout */
.split {
  display: grid;
  gap: clamp(2rem, 1rem + 4vw, 4rem);
  align-items: center;
}
@media (min-width: 900px) {
  .split { grid-template-columns: 1fr 1fr; }
  .split--wide-left { grid-template-columns: 1.15fr 0.85fr; }
  .split--reverse > :first-child { order: 2; }
}

.showcase {
  position: relative;
  border-radius: var(--radius-xl);
  overflow: hidden;
  box-shadow: var(--shadow-glow);
  border: 1px solid var(--border);
  background: var(--surface);
}
.showcase img { width: 100%; }

/* ---------- Data sheet rows ---------- */
.spec-rows { display: grid; gap: 0.6rem; list-style: none; padding: 0; margin: 0; }
.spec-row {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  justify-content: space-between;
  gap: var(--sp-4);
  padding: 0.95rem 1.2rem;
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  transition: border-color 0.22s var(--ease), transform 0.22s var(--ease);
}
.spec-row:hover { border-color: var(--accent); transform: translateX(3px); }
.spec-row__name { font-weight: 650; color: var(--text); }
.spec-row__action { font-size: var(--step--1); }

/* ---------- CTA band ---------- */
.cta-band {
  position: relative;
  isolation: isolate;
  overflow: hidden;
  background: linear-gradient(120deg, var(--blue-900) 0%, var(--blue-700) 55%, var(--blue-600) 100%);
  color: #fff;
  border-radius: var(--radius-xl);
  padding: clamp(2.25rem, 1.5rem + 4vw, 4rem);
}
.cta-band::before {
  content: "";
  position: absolute;
  inset: -40% -10% auto auto;
  width: 480px; height: 480px;
  border-radius: 50%;
  background: radial-gradient(circle, rgba(166, 206, 57, 0.4) 0%, transparent 65%);
  z-index: -1;
}
.cta-band h2 { color: #fff; font-size: var(--step-4); max-width: 18ch; }
.cta-band p { color: rgba(255, 255, 255, 0.82); margin-top: var(--sp-4); max-width: 52ch; font-size: var(--step-1); }
.cta-band__inner { display: grid; gap: var(--sp-6); align-items: center; }
@media (min-width: 860px) { .cta-band__inner { grid-template-columns: 1.3fr auto; } }
.cta-band .btn--lime:hover { box-shadow: 0 18px 40px -12px rgba(166, 206, 57, 0.5); }

/* ---------- Contact ---------- */
.contact-layout { display: grid; gap: clamp(2rem, 1rem + 4vw, 3.5rem); align-items: start; }
@media (min-width: 940px) { .contact-layout { grid-template-columns: minmax(0, 1.25fr) minmax(0, 0.75fr); } }

.form-card {
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: var(--radius-lg);
  padding: clamp(1.5rem, 1rem + 2vw, 2.5rem);
  box-shadow: var(--shadow-md);
}

/* Formidable form restyle — scoped to the contact card and given enough
   specificity to win against the plugin's own style pack. */
.form-card .frm_forms fieldset { border: 0; padding: 0; margin: 0; min-width: 0; }
.form-card .frm_forms legend { font-family: var(--font-display); font-size: var(--step-2); font-weight: 750; color: var(--text); padding: 0; margin-bottom: var(--sp-5); }
.form-card .frm_forms .frm_form_field { margin-bottom: var(--sp-5); }
.form-card .frm_forms .frm_primary_label,
.form-card .frm_forms label.frm_primary_label {
  display: block;
  font-size: var(--step--1);
  font-weight: 650;
  color: var(--text);
  margin-bottom: 0.4rem;
  letter-spacing: 0.01em;
  padding: 0;
}
.form-card .frm_forms .frm_required { color: var(--green-600); margin-inline-start: 0.15rem; }
.form-card .frm_forms.with_frm_style input[type="text"],
.form-card .frm_forms.with_frm_style input[type="email"],
.form-card .frm_forms.with_frm_style input[type="tel"],
.form-card .frm_forms.with_frm_style input[type="url"],
.form-card .frm_forms.with_frm_style input[type="number"],
.form-card .frm_forms.with_frm_style select,
.form-card .frm_forms.with_frm_style textarea {
  width: 100%;
  max-width: 100%;
  height: auto;
  padding: 0.75rem 0.95rem;
  background: var(--bg);
  border: 1px solid var(--border-strong);
  border-radius: var(--radius-sm);
  color: var(--text);
  font-family: var(--font-sans);
  font-size: var(--step-0);
  line-height: 1.5;
  box-shadow: none;
  transition: border-color 0.18s var(--ease), box-shadow 0.18s var(--ease);
}
.form-card .frm_forms.with_frm_style input:focus,
.form-card .frm_forms.with_frm_style select:focus,
.form-card .frm_forms.with_frm_style textarea:focus {
  outline: none;
  border-color: var(--accent);
  box-shadow: 0 0 0 3px var(--accent-soft);
  background: var(--bg);
}
.form-card .frm_forms.with_frm_style textarea { min-height: 150px; resize: vertical; }
.form-card .frm_forms .frm_description { font-size: 0.76rem; color: var(--text-3); margin-top: 0.3rem; }
.form-card .frm_forms .frm_submit { margin-top: var(--sp-5); }
.form-card .frm_forms.with_frm_style button[type="submit"],
.form-card .frm_forms.with_frm_style .frm_button_submit,
.form-card .frm_forms.with_frm_style input[type="submit"] {
  display: inline-flex;
  align-items: center;
  gap: 0.6rem;
  width: auto;
  padding: 0.85rem 1.8rem;
  border-radius: 999px;
  border: 0;
  background: var(--accent);
  color: var(--accent-contrast);
  font-family: var(--font-sans);
  font-weight: 650;
  font-size: var(--step-0);
  line-height: 1.2;
  cursor: pointer;
  text-shadow: none;
  box-shadow: none;
  transition: transform 0.18s var(--ease), box-shadow 0.22s var(--ease);
}
.form-card .frm_forms.with_frm_style button[type="submit"]:hover,
.form-card .frm_forms.with_frm_style .frm_button_submit:hover,
.form-card .frm_forms.with_frm_style input[type="submit"]:hover {
  transform: translateY(-2px);
  box-shadow: var(--shadow-lg);
  background: var(--accent);
}
.form-card .frm_forms .frm_error { color: #d33; font-size: var(--step--1); margin-top: 0.35rem; }
.form-card .frm_forms .frm_error_style,
.form-card .frm_forms .frm_message {
  background: var(--lime-soft);
  border: 1px solid var(--green-400);
  border-radius: var(--radius);
  padding: var(--sp-5);
  color: var(--text);
}
.form-card .frm_forms .frm_verify { position: absolute !important; left: -9999px !important; }
.form-card .frm_forms .frm_half { width: 100%; }
@media (min-width: 620px) {
  .form-card .frm_fields_container { display: grid; grid-template-columns: 1fr 1fr; column-gap: var(--sp-5); }
  .form-card .frm_fields_container > .frm_full,
  .form-card .frm_fields_container > .frm_submit,
  .form-card .frm_fields_container > input[type="hidden"] { grid-column: 1 / -1; }
  .form-card .frm_forms .frm_half { width: 100%; margin: 0; padding: 0; float: none; }
}

.info-card {
  display: grid;
  gap: var(--sp-5);
  padding: clamp(1.5rem, 1rem + 2vw, 2rem);
  background: linear-gradient(150deg, var(--blue-900), var(--blue-700));
  color: #fff;
  border-radius: var(--radius-lg);
}
.info-card h3 { color: #fff; font-size: var(--step-2); }
.info-card p { color: rgba(255, 255, 255, 0.82); }
.info-item { display: flex; gap: var(--sp-4); align-items: flex-start; }
.info-item svg { width: 22px; height: 22px; flex: none; color: var(--green-400); margin-top: 0.2rem; }
.info-item strong { display: block; font-weight: 650; }
.info-item a { color: #fff; }

/* ---------- Footer ---------- */
.site-footer {
  background: var(--blue-950);
  color: rgba(233, 238, 247, 0.72);
  padding-block: var(--sp-8) var(--sp-6);
  position: relative;
}
.site-footer::before {
  content: "";
  position: absolute;
  top: 0; left: 0; right: 0;
  height: 2px;
  background: linear-gradient(90deg, var(--green-400), var(--blue-500) 50%, transparent);
}
.footer-grid {
  display: grid;
  gap: var(--sp-7);
  grid-template-columns: repeat(auto-fit, minmax(min(100%, 200px), 1fr));
}
@media (min-width: 900px) { .footer-grid { grid-template-columns: 1.4fr 1fr 1fr 1fr; } }
.footer-brand img { height: 44px; width: auto; margin-bottom: var(--sp-4); }
.footer-brand p { max-width: 38ch; font-size: var(--step--1); line-height: 1.7; }
.site-footer h2, .site-footer h3 {
  color: #fff;
  font-size: var(--step--1);
  letter-spacing: 0.12em;
  text-transform: uppercase;
  margin-bottom: var(--sp-4);
  font-weight: 700;
}
.site-footer ul { list-style: none; padding: 0; margin: 0; display: grid; gap: 0.6rem; }
.site-footer a { color: rgba(233, 238, 247, 0.72); text-decoration: none; font-size: var(--step--1); transition: color 0.18s var(--ease); }
.site-footer a:hover { color: var(--green-400); }
.site-footer .sub-menu { display: none; }
.footer-bottom {
  margin-top: var(--sp-7);
  padding-top: var(--sp-5);
  border-top: 1px solid rgba(255, 255, 255, 0.1);
  display: flex;
  flex-wrap: wrap;
  gap: var(--sp-4);
  align-items: center;
  justify-content: space-between;
  font-size: var(--step--1);
}

/* ---------- Back to top ---------- */
.to-top {
  position: fixed;
  right: clamp(1rem, 2vw, 2rem);
  bottom: clamp(1rem, 2vw, 2rem);
  z-index: 90;
  width: 46px; height: 46px;
  border-radius: 50%;
  border: 1px solid var(--border);
  background: var(--surface);
  color: var(--accent);
  display: grid;
  place-items: center;
  cursor: pointer;
  box-shadow: var(--shadow-md);
  opacity: 0;
  transform: translateY(14px) scale(0.9);
  pointer-events: none;
  transition: opacity 0.25s var(--ease), transform 0.25s var(--ease);
}
.to-top.is-visible { opacity: 1; transform: none; pointer-events: auto; }
.to-top svg { width: 18px; height: 18px; }

/* ---------- Reveal on scroll ---------- */
.reveal { opacity: 0; transform: translateY(22px); }
.reveal.is-in { opacity: 1; transform: none; transition: opacity 0.7s var(--ease-out-expo), transform 0.7s var(--ease-out-expo); }
.reveal-stagger > * { opacity: 0; transform: translateY(22px); }
.reveal-stagger.is-in > * { opacity: 1; transform: none; transition: opacity 0.65s var(--ease-out-expo), transform 0.65s var(--ease-out-expo); }
.reveal-stagger.is-in > *:nth-child(1) { transition-delay: 0.04s; }
.reveal-stagger.is-in > *:nth-child(2) { transition-delay: 0.1s; }
.reveal-stagger.is-in > *:nth-child(3) { transition-delay: 0.16s; }
.reveal-stagger.is-in > *:nth-child(4) { transition-delay: 0.22s; }
.reveal-stagger.is-in > *:nth-child(5) { transition-delay: 0.28s; }
.reveal-stagger.is-in > *:nth-child(6) { transition-delay: 0.34s; }
.reveal-stagger.is-in > *:nth-child(7) { transition-delay: 0.4s; }
.reveal-stagger.is-in > *:nth-child(8) { transition-delay: 0.46s; }

@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }
  *, *::before, *::after {
    animation-duration: 0.001ms !important;
    animation-iteration-count: 1 !important;
    transition-duration: 0.001ms !important;
  }
  .reveal, .reveal-stagger > * { opacity: 1 !important; transform: none !important; }
}

/* ---------- Language switcher (TranslatePress) ---------- */
.trp-language-switcher { font-size: var(--step--1); }
.header-actions .trp-language-switcher > div { background: transparent; border: 1px solid var(--border); border-radius: 999px; }

/* ---------- 404 / search ---------- */
.centered-panel { text-align: center; max-width: 60ch; margin-inline: auto; }
.centered-panel .display-code {
  font-family: var(--font-display);
  font-size: clamp(4rem, 2rem + 12vw, 9rem);
  font-weight: 800;
  line-height: 1;
  background: linear-gradient(120deg, var(--blue-600), var(--green-400));
  -webkit-background-clip: text;
  background-clip: text;
  color: transparent;
}
.search-form { display: flex; gap: var(--sp-3); margin-top: var(--sp-5); }
.search-form input[type="search"] {
  flex: 1;
  padding: 0.8rem 1rem;
  border: 1px solid var(--border-strong);
  border-radius: 999px;
  background: var(--surface);
  color: var(--text);
}
.search-form input[type="search"]:focus { outline: none; border-color: var(--accent); box-shadow: 0 0 0 3px var(--accent-soft); }

.result-list { display: grid; gap: var(--sp-5); list-style: none; padding: 0; margin: 0; }
.result-item { padding-bottom: var(--sp-5); border-bottom: 1px solid var(--border); }
.result-item h2 { font-size: var(--step-2); }
.result-item h2 a { color: inherit; text-decoration: none; }
.result-item h2 a:hover { color: var(--accent); }
.result-item p { color: var(--text-2); margin-top: var(--sp-3); }

/* ---------- Sub-page rail (sibling navigation) ---------- */
.sub-rail {
  display: flex;
  flex-wrap: wrap;
  gap: 0.5rem;
  padding: 0;
  margin: 0;
  list-style: none;
}
.sub-rail a {
  display: inline-block;
  padding: 0.5rem 1rem;
  border-radius: 999px;
  border: 1px solid var(--border);
  background: var(--surface);
  font-size: var(--step--1);
  font-weight: 600;
  color: var(--text-2);
  text-decoration: none;
  transition: all 0.2s var(--ease);
}
.sub-rail a:hover { border-color: var(--accent); color: var(--accent); }
.sub-rail .is-current a { background: var(--accent); border-color: var(--accent); color: var(--accent-contrast); }

/* ---------- Pagination ---------- */
.pagination { display: flex; gap: 0.4rem; justify-content: center; margin-top: var(--sp-7); }
.pagination .page-numbers {
  display: grid; place-items: center;
  min-width: 42px; height: 42px;
  padding: 0 0.7rem;
  border-radius: var(--radius-sm);
  border: 1px solid var(--border);
  text-decoration: none;
  color: var(--text-2);
  font-weight: 600;
}
.pagination .page-numbers.current { background: var(--accent); border-color: var(--accent); color: var(--accent-contrast); }

/* ---------- Print ---------- */
@media print {
  .site-header, .site-footer, .to-top, .cta-band, .mobile-drawer { display: none !important; }
  body { color: #000; background: #fff; }
}

/* ---------- In-content component overrides ---------- */
.prose .feature-list { padding-inline-start: 0; list-style: none; gap: var(--sp-4); }
.prose .feature-list li::marker { content: none; }
.prose .spec-rows { padding-inline-start: 0; list-style: none; gap: 0.6rem; }
.prose .spec-rows li::marker { content: none; }
.prose .card-grid { gap: clamp(1rem, 0.6rem + 1.4vw, 1.75rem); }
.prose .media-grid, .prose .card-grid { margin-top: var(--sp-6); }
.prose .btn { text-decoration: none; }
.prose .table-wrap + .table-wrap { margin-top: var(--sp-4); }

/* ---------- Panel / notice ---------- */
.panel {
  display: grid;
  gap: var(--sp-4);
  padding: clamp(1.4rem, 1rem + 1.4vw, 2rem);
  border: 1px solid var(--border);
  border-radius: var(--radius-lg);
  background: var(--surface-2);
  position: relative;
  overflow: hidden;
}
.panel::before {
  content: "";
  position: absolute;
  inset: 0 auto 0 0;
  width: 4px;
  background: linear-gradient(180deg, var(--green-400), var(--blue-500));
}
.panel h3 { font-size: var(--step-1); margin: 0; }
.panel p { margin: 0; color: var(--text-2); }
.panel__actions { display: flex; flex-wrap: wrap; gap: var(--sp-3); }

/* ---------- Simple 2-column comparison ---------- */
.compare { display: grid; gap: var(--sp-5); }
@media (min-width: 880px) { .compare { grid-template-columns: 1fr 1fr; } }
.compare__col {
  padding: clamp(1.3rem, 1rem + 1vw, 1.9rem);
  border: 1px solid var(--border);
  border-radius: var(--radius-lg);
  background: var(--surface);
}
.compare__col h3 { font-size: var(--step-1); margin: 0 0 var(--sp-4); }
.compare__col--ours { border-color: var(--green-400); background: var(--surface); box-shadow: var(--shadow-md); }
.compare__col--ours h3 { color: var(--lime); }
:root[data-theme="dark"] .compare__col--ours h3 { color: var(--green-300); }
@media (prefers-color-scheme: dark) { :root:not([data-theme="light"]) .compare__col--ours h3 { color: var(--green-300); } }
.compare__col ul { margin: 0; }

/* ---------- Download / action row ---------- */
.actions-row { display: flex; flex-wrap: wrap; gap: var(--sp-3); align-items: center; }

/* ---------- Sub-rail spacing ---------- */
.sub-rail-wrap { padding-block: var(--sp-2); }

/* ---------- Logo ---------- */
:root { --logo-blue: #17479e; --logo-green: #a6ce39; }
:root[data-theme="dark"] { --logo-blue: #6d9cf0; }
@media (prefers-color-scheme: dark) {
  :root:not([data-theme="light"]) { --logo-blue: #6d9cf0; }
}
.brand { color: var(--text); }
.brand__logo {
  height: var(--brand-h, 40px);
  width: calc(var(--brand-h, 40px) * 4.571);
  display: block;
}
.brand--dark-bg { color: #fff; --logo-blue: #6d9cf0; }
@media (max-width: 480px) { .brand__logo { height: calc(var(--brand-h, 40px) * 0.82); width: calc(var(--brand-h, 40px) * 3.749); } }
/* The drawer panel always uses the page background, so it follows the theme. */
.mobile-drawer__head .brand img { height: 34px; }

/* ---------- Language switcher ---------- */
.lang-switch {
  display: inline-flex;
  align-items: center;
  padding: 3px;
  gap: 2px;
  border: 1px solid var(--border);
  border-radius: 999px;
  background: var(--surface);
}
.lang-switch__item {
  display: inline-grid;
  place-items: center;
  min-width: 34px;
  height: 32px;
  padding: 0 0.45rem;
  border-radius: 999px;
  font-size: 0.74rem;
  font-weight: 700;
  letter-spacing: 0.06em;
  color: var(--text-3);
  text-decoration: none;
  transition: background-color 0.18s var(--ease), color 0.18s var(--ease);
}
.lang-switch__item:hover { color: var(--text); background: var(--accent-soft); }
.lang-switch__item.is-current { background: var(--accent); color: var(--accent-contrast); }
.lang-switch--drawer { width: fit-content; }
@media (max-width: 620px) { .header-actions .lang-switch { display: none; } }

/* ---------- Mega menu ---------- */
.primary-nav > ul > li.has-mega { position: static; }

.mega {
  position: absolute;
  left: 0;
  right: 0;
  top: 100%;
  z-index: 30;
  background: var(--bg);
  border-top: 1px solid var(--border);
  border-bottom: 1px solid var(--border);
  box-shadow: 0 30px 60px -24px rgba(11, 20, 36, 0.28);
  opacity: 0;
  visibility: hidden;
  transform: translateY(-10px);
  transition: opacity 0.22s var(--ease), transform 0.28s var(--ease-out-expo), visibility 0.28s;
}
:root[data-theme="dark"] .mega { box-shadow: 0 30px 60px -24px rgba(0, 0, 0, 0.8); }
@media (prefers-color-scheme: dark) {
  :root:not([data-theme="light"]) .mega { box-shadow: 0 30px 60px -24px rgba(0, 0, 0, 0.8); }
}
.has-mega:hover > .mega,
.has-mega:focus-within > .mega { opacity: 1; visibility: visible; transform: translateY(0); }

.mega__inner { padding-block: clamp(1.5rem, 1rem + 2vw, 2.5rem); }

.mega__grid {
  display: grid;
  gap: clamp(1rem, 0.5rem + 1.4vw, 1.75rem) clamp(1rem, 0.5rem + 2vw, 2.5rem);
  grid-template-columns: repeat(4, minmax(0, 1fr));
}
@media (max-width: 1320px) { .mega__grid { grid-template-columns: repeat(3, minmax(0, 1fr)); } }

.mega__col { min-width: 0; }

.primary-nav .mega__head {
  display: flex;
  white-space: normal;
  align-items: flex-start;
  gap: 0.75rem;
  padding: 0.6rem;
  margin: -0.6rem -0.6rem 0.35rem;
  border-radius: var(--radius);
  text-decoration: none;
  transition: background-color 0.18s var(--ease);
}
.primary-nav .mega__head:hover { background: var(--accent-soft); }

.mega__icon {
  display: grid;
  place-items: center;
  flex: none;
  width: 40px;
  height: 40px;
  border-radius: 11px;
  background: var(--accent-soft);
  color: var(--accent);
  transition: background-color 0.2s var(--ease), color 0.2s var(--ease);
}
.mega__icon svg { width: 21px; height: 21px; }
.primary-nav .mega__head:hover .mega__icon { background: var(--accent); color: var(--accent-contrast); }

.mega__text { display: grid; gap: 0.15rem; min-width: 0; }
.mega__title {
  white-space: normal;
  font-family: var(--font-display);
  font-weight: 700;
  font-size: var(--step-0);
  line-height: 1.25;
  letter-spacing: -0.012em;
  color: var(--text);
}
.mega__desc {
  white-space: normal;
  font-size: 0.78rem;
  line-height: 1.45;
  color: var(--text-3);
  display: -webkit-box;
  -webkit-line-clamp: 2;
  -webkit-box-orient: vertical;
  overflow: hidden;
}

.mega__sub {
  list-style: none;
  margin: 0;
  padding: 0 0 0 3.1rem;
  display: grid;
  gap: 1px;
  border-inline-start: 0;
}
.mega__sub li { position: relative; }
.primary-nav .mega__sub a {
  display: block;
  padding: 0.34rem 0.5rem;
  border-radius: var(--radius-sm);
  font-size: 0.82rem;
  line-height: 1.4;
  font-weight: 500;
  color: var(--text-2);
  text-decoration: none;
  white-space: normal;
  transition: color 0.16s var(--ease), background-color 0.16s var(--ease);
}
.primary-nav .mega__sub a:hover { color: var(--accent); background: var(--accent-soft); }
.primary-nav .mega__sub .current-menu-item > a { color: var(--accent); font-weight: 650; }

.mega__foot {
  margin-top: clamp(1.25rem, 0.8rem + 1.4vw, 2rem);
  padding-top: var(--sp-4);
  border-top: 1px solid var(--border);
  display: flex;
  justify-content: flex-end;
}
.primary-nav .mega__foot .link-arrow { font-size: var(--step--1); }

/* Mobile: icons beside product entries in the drawer */
.mobile-nav .menu-icon {
  display: inline-grid;
  place-items: center;
  width: 26px;
  height: 26px;
  border-radius: 8px;
  background: var(--accent-soft);
  color: var(--accent);
  margin-inline-end: 0.55rem;
  vertical-align: -0.45rem;
  flex: none;
}
.mobile-nav .menu-icon svg { width: 15px; height: 15px; }
.mobile-nav .sub-menu > li > a { display: flex; align-items: center; }

/* ---------- Interface mockups & illustrations ---------- */
:root {
  --mk-panel: #ffffff;
  --mk-chrome: #f1f5fb;
  --mk-side: #f7f9fd;
  --mk-line: #dfe6f0;
  --mk-field: #ffffff;
  --mk-locked: #f4f7fb;
  --mk-text: #0b1424;
  --mk-muted: #67748c;
  --mk-accent: #17479e;
  --mk-accent-soft: #e8eefb;
  --mk-ok: #4f9d2b;
  --mk-warn: #b87400;
  --mk-crit: #cf3b2f;
  --mk-lime: #a6ce39;
  --mk-hint: #fdf6e3;

  --il-bg: #eef3fb;
  --il-panel: #ffffff;
  --il-line: #c9d6ea;
  --il-ink: #0b1424;
  --il-muted: #8395b0;
  --il-blue: #17479e;
  --il-blue-soft: #d7e2f7;
  --il-lime: #a6ce39;
}

:root[data-theme="dark"] {
  --mk-panel: #0e1626;
  --mk-chrome: #141f33;
  --mk-side: #0b1320;
  --mk-line: #25334c;
  --mk-field: #131d30;
  --mk-locked: #0f1828;
  --mk-text: #e9eef7;
  --mk-muted: #93a2ba;
  --mk-accent: #4a86e8;
  --mk-accent-soft: #17243d;
  --mk-ok: #6cc23f;
  --mk-warn: #e0a02a;
  --mk-crit: #e5594b;
  --mk-hint: #2a2314;

  --il-bg: #0b1320;
  --il-panel: #131d30;
  --il-line: #2a3a55;
  --il-ink: #e9eef7;
  --il-muted: #8395b0;
  --il-blue: #6d9cf0;
  --il-blue-soft: #1b2b48;
}

@media (prefers-color-scheme: dark) {
  :root:not([data-theme="light"]) {
    --mk-panel: #0e1626;
    --mk-chrome: #141f33;
    --mk-side: #0b1320;
    --mk-line: #25334c;
    --mk-field: #131d30;
    --mk-locked: #0f1828;
    --mk-text: #e9eef7;
    --mk-muted: #93a2ba;
    --mk-accent: #4a86e8;
    --mk-accent-soft: #17243d;
    --mk-ok: #6cc23f;
    --mk-warn: #e0a02a;
    --mk-crit: #e5594b;
    --mk-hint: #2a2314;

    --il-bg: #0b1320;
    --il-panel: #131d30;
    --il-line: #2a3a55;
    --il-ink: #e9eef7;
    --il-muted: #8395b0;
    --il-blue: #6d9cf0;
    --il-blue-soft: #1b2b48;
  }
}

.figure-svg { margin: var(--sp-6) 0; }
.figure-svg__frame {
  border: 1px solid var(--border);
  border-radius: var(--radius-lg);
  overflow: hidden;
  background: var(--mk-panel);
  box-shadow: var(--shadow-lg);
  line-height: 0;
}
.figure-svg__frame svg { width: 100%; height: auto; display: block; }
.figure-svg figcaption {
  margin-top: var(--sp-3);
  font-size: var(--step--1);
  color: var(--text-3);
  text-align: center;
  line-height: 1.5;
}
.figure-svg--plain .figure-svg__frame { border: 0; box-shadow: none; background: transparent; }
.figure-svg--tight { margin-top: 0; }
.prose .figure-svg { margin-block: var(--sp-6); }

/* Showcase variant used in the home split */
.showcase .figure-svg,
.showcase > svg { margin: 0; }

/* Portrait figures (the device tree) must not dominate the column */
.figure-svg--tree { max-width: 330px; margin-inline: auto; }
@media (min-width: 900px) {
  .figure-svg--tree { float: right; max-width: 300px; margin: 0 0 var(--sp-5) var(--sp-6); }
}
