/* ==========================================================================
   CuoreSafety WordPress theme — site styles
   Ported from inputs/ (tokens + ui_kits/website component & section styles).
   Class-based rewrite of the React inline-style source; layout/colour/type/
   spacing match the design 1:1. Heavy GSAP scroll-choreography is replaced by
   the source's own reduced-motion (stacked) layouts + lightweight CSS/IO motion.
   ========================================================================== */

/* ---- Base elements (tokens/base.css) ------------------------------------- */
*, *::before, *::after { box-sizing: border-box; }
html { scroll-behavior: smooth; }
body {
  margin: 0;
  overflow-x: hidden;
  background: var(--surface-page);
  color: var(--text-body);
  font-family: var(--font-body);
  font-size: var(--text-body-size);
  line-height: var(--leading-body);
  -webkit-font-smoothing: antialiased;
}
h1, h2, h3, h4 {
  font-family: var(--font-display);
  color: var(--text-heading);
  letter-spacing: var(--tracking-heading);
  line-height: var(--leading-heading);
  margin: 0;
}
a { color: var(--fg-1); text-decoration: none; transition: color var(--dur-fast) var(--ease-standard); }
a:hover { color: var(--accent-text); }
img { max-width: 100%; }
::selection { background: var(--accent); color: var(--fg-1); }
:focus-visible { outline: 2px solid var(--focus-ring); outline-offset: 3px; border-radius: 4px; }

/* ---- Layout helpers ------------------------------------------------------ */
.cs-container { max-width: var(--container); margin: 0 auto; width: 100%; }
.cs-section { padding: var(--section-pad) var(--gutter); }
.cs-section--raised { background: var(--carbon-2); border-top: 1px solid var(--line-1); }
.cs-stack { display: flex; flex-direction: column; }

/* ---- Grain overlay ------------------------------------------------------- */
.cs-grain {
  position: fixed; inset: 0; pointer-events: none; z-index: 999; opacity: 0.045;
  background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='140' height='140'%3E%3Cfilter id='n'%3E%3CfeTurbulence type='fractalNoise' baseFrequency='0.85' numOctaves='2'/%3E%3C/filter%3E%3Crect width='140' height='140' filter='url(%23n)'/%3E%3C/svg%3E");
}

/* ---- Reveal-on-scroll (IntersectionObserver) — only hides when JS motion on -- */
html.cs-js-anim [data-reveal] { opacity: 0; transition: opacity var(--dur-reveal) var(--ease-standard), transform var(--dur-reveal) var(--ease-reveal); }
html.cs-js-anim [data-reveal="up"] { transform: translateY(48px); }
html.cs-js-anim [data-reveal].cs-in { opacity: 1; transform: none; }

/* ---- Eyebrow (mono caps label) ------------------------------------------- */
.cs-eyebrow {
  font-family: var(--font-mono); font-size: var(--text-eyebrow);
  letter-spacing: var(--tracking-eyebrow); text-transform: uppercase; color: var(--fg-3);
  display: flex; align-items: center; gap: 10px;
}
.cs-eyebrow__dot { color: var(--accent-text); font-size: 8px; }
.cs-eyebrow--invert { color: var(--invert-muted); }

/* ---- Chip (telemetry pill) ----------------------------------------------- */
.cs-chip {
  font-family: var(--font-mono); font-size: 11px; letter-spacing: 0.1em; color: var(--fg-2);
  border: 1px solid var(--line-2); background: transparent; border-radius: var(--radius-pill);
  padding: 6px 12px; display: inline-flex; gap: 8px; align-items: center; white-space: nowrap; text-transform: uppercase;
}
.cs-chip--dashed { border-style: dashed; }
.cs-chip--accent { color: var(--accent-text); border-color: var(--accent-tint); background: var(--accent-tint); }
.cs-chip__live { width: 6px; height: 6px; border-radius: 50%; background: var(--live); font-style: normal; }

/* ---- Button -------------------------------------------------------------- */
.cs-btn {
  display: inline-flex; align-items: center; gap: 10px;
  font-family: var(--font-body); font-weight: 500; font-size: 15px;
  padding: 15px 30px; border-radius: var(--radius-pill); cursor: pointer;
  text-decoration: none; white-space: nowrap; border: 1px solid transparent;
  transition: background var(--dur-fast) var(--ease-standard), color var(--dur-fast) var(--ease-standard),
              border-color var(--dur-fast) var(--ease-standard), transform var(--dur-fast) var(--ease-standard);
}
.cs-btn--sm { padding: 10px 20px; font-size: 14px; }
.cs-btn--lg { padding: 19px 40px; font-size: 17px; }
.cs-btn--primary { background: var(--accent); color: #fff; }
.cs-btn--primary:hover { background: var(--accent-hover); color: #fff; }
.cs-btn--primary:active { background: var(--accent-press); }
.cs-btn--ghost { background: transparent; color: var(--fg-1); border: 1px solid var(--line-2); }
.cs-btn--ghost:hover { border-color: var(--fg-2); color: var(--fg-1); }
.cs-btn--inverted { background: var(--invert-fg); color: var(--invert-bg); }
.cs-btn--inverted:hover { background: var(--accent); color: #fff; }
.cs-btn:hover { transform: translateY(-2px); }
.cs-btn:active { transform: scale(0.98); }

/* ---- Section heading ----------------------------------------------------- */
.cs-heading { display: flex; flex-direction: column; gap: 24px; align-items: flex-start; text-align: left; }
.cs-heading--center { align-items: center; text-align: center; }
.cs-heading__title {
  font-family: var(--font-display); font-weight: 700; color: var(--fg-1);
  font-size: var(--text-display); letter-spacing: var(--tracking-display);
  line-height: var(--leading-display); margin: 0; text-wrap: balance; max-width: 14ch;
}
.cs-heading__title--h2 { font-size: var(--text-h2); }
.cs-heading__lead { margin: 0; font-family: var(--font-body); font-size: var(--text-lead); line-height: 1.5; color: var(--fg-2); max-width: 46ch; }
.cs-heading--invert .cs-heading__title { color: var(--invert-fg); }
.cs-heading--invert .cs-heading__lead { color: var(--invert-muted); }

/* ---- Underline link ------------------------------------------------------ */
.cs-underline-link { position: relative; padding-bottom: 3px; color: var(--fg-2); font-size: 15px; }
.cs-underline-link::after {
  content: ''; position: absolute; left: 0; bottom: 0; width: 100%; height: 1px; background: var(--accent-hover);
  transform: scaleX(0); transform-origin: right; transition: transform 0.45s var(--ease-reveal);
}
.cs-underline-link:hover::after { transform: scaleX(1); transform-origin: left; }

/* ==========================================================================
   NAVBAR
   ========================================================================== */
.cs-nav {
  position: fixed; top: 0; left: 0; right: 0; z-index: 100;
  display: flex; align-items: center; justify-content: space-between;
  padding: 24px var(--gutter);
  background: transparent; border-bottom: 1px solid transparent;
  transition: padding 0.4s var(--ease-reveal), background 0.4s var(--ease-standard), border-color 0.4s var(--ease-standard);
}
.cs-nav.is-scrolled {
  padding: 12px var(--gutter);
  background: var(--surface-glass);
  -webkit-backdrop-filter: blur(var(--blur-glass)); backdrop-filter: blur(var(--blur-glass));
  border-bottom: 1px solid var(--line-1);
}
.cs-nav__logo { display: flex; }
.cs-nav__logo img { height: 28px; display: block; transition: height 0.4s var(--ease-reveal); }
.cs-nav.is-scrolled .cs-nav__logo img { height: 22px; }

/* ==========================================================================
   HERO
   ========================================================================== */
.cs-hero {
  min-height: 100vh; position: relative; overflow: hidden;
  display: flex; flex-direction: column; justify-content: center;
  padding: calc(var(--nav-height) + 24px) var(--gutter) 110px;
}
.cs-hero__content { max-width: var(--container); margin: 0 auto; width: 100%; position: relative; display: flex; flex-direction: column; gap: 34px; }
.cs-hero__title {
  margin: 0; font-family: var(--font-display); font-weight: 700;
  font-size: var(--text-hero); letter-spacing: var(--tracking-display);
  line-height: var(--leading-display); color: var(--fg-1); max-width: 11ch;
}
.cs-hero__lead { margin: 0; font-size: var(--text-lead); line-height: 1.5; color: var(--fg-2); max-width: 42ch; }
.cs-hero__actions { display: flex; gap: 20px; align-items: center; flex-wrap: wrap; }

/* word clip-mask reveal — only hidden when JS motion is active */
.cs-mask { display: inline-block; overflow: hidden; vertical-align: top; padding-bottom: 0.08em; margin: 0 0.22em -0.08em 0; }
.cs-word { display: inline-block; }
html.cs-js-anim .cs-word { transform: translateY(112%); transition: transform 1s var(--ease-reveal); }
html.cs-js-anim .cs-word.cs-in { transform: translateY(0); }

/* 3D perspective road */
.cs-road-wrap { position: absolute; inset: 0; pointer-events: none; perspective: 620px; perspective-origin: 50% 38%; }
.cs-road-plane { position: absolute; left: -30%; width: 160%; top: 38%; height: 130%; transform: rotateX(78deg); transform-origin: 50% 0; }
.cs-road-line { position: absolute; top: 0; bottom: 0; width: 3px; }
.cs-road-edge { background: linear-gradient(to bottom, rgba(242,240,233,0.14), rgba(242,240,233,0.02)); }
.cs-road-dash { background: repeating-linear-gradient(to bottom, rgba(242,240,233,0.35) 0 70px, transparent 70px 160px); }
.cs-road-scroll { position: absolute; left: 0; right: 0; top: -320px; bottom: 0; animation: csDrive 1.15s linear infinite; }
@keyframes csDrive { to { transform: translateY(320px); } }
.cs-road-grid { position: absolute; inset: 0; background: repeating-linear-gradient(to bottom, rgba(242,240,233,0.045) 0 1px, transparent 1px 110px); }
.cs-road-horizon { position: absolute; left: 0; right: 0; top: 34%; height: 22%; background: radial-gradient(60% 100% at 50% 38%, var(--accent-glow), transparent 70%); opacity: 0.5; }
.cs-road-fade {
  position: absolute; inset: 0;
  background: linear-gradient(to bottom, var(--carbon-1) 30%, transparent 55%, rgba(10,11,10,0.9) 96%),
              linear-gradient(to right, var(--carbon-1) 0%, transparent 22%, transparent 78%, var(--carbon-1) 100%);
}

/* floating hero chips */
.cs-hero-chips { position: absolute; inset: 0; pointer-events: none; }
.cs-hero-chips > div { position: absolute; }

/* scroll indicator */
.cs-scroll-indicator { position: absolute; bottom: 26px; left: 50%; transform: translateX(-50%); display: flex; flex-direction: column; align-items: center; gap: 10px; }
.cs-scroll-indicator span:first-child { font-family: var(--font-mono); font-size: 10px; letter-spacing: 0.2em; color: var(--fg-3); }
.cs-scroll-line { display: block; width: 1px; height: 44px; background: var(--line-2); position: relative; overflow: hidden; }
.cs-scroll-line::after { content: ''; position: absolute; left: 0; top: -100%; width: 100%; height: 100%; background: var(--accent); animation: csScroll 1.8s var(--ease-standard) infinite; }
@keyframes csScroll { to { top: 100%; } }

/* ==========================================================================
   MARQUEE
   ========================================================================== */
.cs-marquee { overflow: hidden; white-space: nowrap; border-top: 1px solid var(--line-1); border-bottom: 1px solid var(--line-1); padding: 22px 0; }
.cs-marquee__track { display: inline-flex; align-items: center; gap: 48px; animation: csMarquee 28s linear infinite; will-change: transform; }
@keyframes csMarquee { from { transform: translateX(0); } to { transform: translateX(-33.333%); } }
.cs-marquee__item { font-family: var(--font-display); font-weight: 500; font-size: 22px; letter-spacing: 0.06em; text-transform: uppercase; color: var(--fg-3); }
.cs-marquee__sep { color: var(--accent); font-size: 10px; }

/* ==========================================================================
   PRODUCTS
   ========================================================================== */
.cs-products__grid { display: flex; flex-direction: column; gap: 80px; }
.cs-product { display: grid; gap: 40px; }
.cs-prod-copy { display: flex; flex-direction: column; gap: 24px; }
.cs-prod-copy h3 { margin: 0; font-family: var(--font-display); font-weight: 700; font-size: var(--text-h2); letter-spacing: var(--tracking-display); line-height: 1; color: var(--fg-1); }
.cs-prod-copy p { margin: 0; font-size: 17px; line-height: 1.6; color: var(--fg-2); max-width: 42ch; }
.cs-prod-card { position: relative; }
.cs-prod-card__glow { position: absolute; inset: -16%; background: radial-gradient(closest-side, var(--accent-glow), transparent 72%); pointer-events: none; }
.cs-prod-card__frame { position: relative; border-radius: var(--radius-l); overflow: hidden; border: 1px solid var(--line-2); box-shadow: var(--shadow-card); }
.cs-prod-card__index { position: absolute; top: -20px; right: 0; font-family: var(--font-mono); font-size: 12px; letter-spacing: 0.22em; color: var(--fg-3); }
.cs-prod-visual { width: 100%; aspect-ratio: 16 / 10.5; position: relative; overflow: hidden; display: block; object-fit: cover; }

/* CS Monitor CSS render */
.cs-monitor { position: relative; width: 100%; aspect-ratio: 16 / 10.5; overflow: hidden;
  background: radial-gradient(90% 100% at 50% 36%, #171A18 0%, #0E100F 55%, #0A0B0A 100%);
  display: flex; align-items: center; justify-content: center; }
.cs-monitor svg { position: absolute; inset: 0; width: 100%; height: 100%; }
.cs-trace { stroke-dasharray: 5 9; animation: csTraceFlow 2.2s linear infinite; }
@keyframes csTraceFlow { to { stroke-dashoffset: -28; } }
.cs-device-float { position: relative; width: 42%; animation: csDeviceFloat 5.5s ease-in-out infinite; }
@keyframes csDeviceFloat { 0%, 100% { transform: translateY(0); } 50% { transform: translateY(-10px); } }
.cs-device { position: relative; aspect-ratio: 1.58; border-radius: 26px;
  background: linear-gradient(148deg, #2C302D 0%, #181B19 42%, #0E100F 100%);
  border: 1px solid rgba(255,255,255,0.10);
  box-shadow: 0 70px 90px -42px rgba(0,0,0,0.95), inset 0 1px 0 rgba(255,255,255,0.16), inset 0 -18px 30px rgba(0,0,0,0.55); }
.cs-device__inset { position: absolute; inset: 9%; border-radius: 18px; border: 1px solid rgba(255,255,255,0.06); background: linear-gradient(160deg, rgba(255,255,255,0.045), transparent 55%); }
.cs-device__logo { position: absolute; left: 50%; top: 50%; transform: translate(-50%, -50%); width: 30%; opacity: 0.92; }
.cs-device__led { position: absolute; right: 10%; top: 14%; width: 7px; height: 7px; border-radius: 50%; background: var(--green-bright); box-shadow: 0 0 12px 2px var(--accent-glow); animation: csLed 1.7s ease-in-out infinite; }
@keyframes csLed { 0%, 100% { opacity: 1; } 50% { opacity: 0.3; } }
.cs-device__code { position: absolute; left: 11%; bottom: 12%; font-family: var(--font-mono); font-size: 8px; letter-spacing: 0.22em; color: rgba(246,244,242,0.35); }
.cs-device__shadow { position: absolute; left: 8%; right: 8%; bottom: -14%; height: 10%; border-radius: 50%; background: radial-gradient(closest-side, rgba(0,0,0,0.8), transparent); }
.cs-monitor__label { position: absolute; bottom: 7.5%; left: 50%; transform: translateX(-50%); font-family: var(--font-mono); font-size: 10px; letter-spacing: 0.24em; color: var(--fg-3); white-space: nowrap; }
.cs-monitor__chip-l { position: absolute; top: 9%; left: 7%; }
.cs-monitor__chip-r { position: absolute; top: 9%; right: 7%; }

/* ==========================================================================
   DASHBOARD TOUR (stacked)
   ========================================================================== */
.cs-tour__list { display: flex; flex-direction: column; gap: 40px; }
.cs-tour__item { display: flex; flex-direction: column; gap: 10px; border-top: 1px solid var(--line-1); padding-top: 24px; }
.cs-tour__kicker { font-family: var(--font-mono); font-size: 12px; letter-spacing: 0.18em; text-transform: uppercase; color: var(--accent-text); }
.cs-tour__title { margin: 0; font-size: 28px; font-weight: 700; color: var(--fg-1); }
.cs-tour__copy { margin: 0; font-size: 16px; line-height: 1.6; color: var(--fg-2); max-width: 52ch; }
.cs-tour__media { border-radius: var(--radius-l); overflow: hidden; border: 1px solid var(--line-2); box-shadow: var(--shadow-card); position: relative; }
.cs-tour__media img { display: block; width: 100%; }
.cs-tour__hud { position: absolute; top: 12px; left: 50%; transform: translateX(-50%); display: flex; align-items: center; gap: 10px; z-index: 2;
  background: rgba(10,11,10,0.55); -webkit-backdrop-filter: blur(6px); backdrop-filter: blur(6px); border: 1px solid var(--line-1); border-radius: 999px; padding: 7px 16px; }
.cs-tour__hud i { width: 6px; height: 6px; border-radius: 50%; background: var(--accent-text); }
.cs-tour__hud span { font-family: var(--font-mono); font-size: 11px; letter-spacing: 0.2em; text-transform: uppercase; color: var(--fg-2); white-space: nowrap; }

/* ==========================================================================
   MODULES / INFO-GRID
   ========================================================================== */
.cs-modules-grid { display: grid; grid-template-columns: repeat(auto-fit, minmax(230px, 1fr)); gap: 1px; background: var(--line-1); border: 1px solid var(--line-1); }
.cs-module { background: var(--carbon-1); padding: 26px 24px; display: flex; flex-direction: column; gap: 12px; transition: background 0.35s var(--ease-standard); }
.cs-module:hover { background: var(--carbon-3); }
.cs-module__icon { width: 34px; height: 34px; border-radius: 8px; background: var(--green-tint); display: flex; align-items: center; justify-content: center; }
.cs-module__icon img { width: 16px; height: 16px; filter: brightness(1.9) saturate(0.7); }
.cs-module__title { font-size: 16px; font-weight: 600; color: var(--fg-1); }
.cs-module__desc { font-size: 13.5px; line-height: 1.5; color: var(--fg-3); }

/* ==========================================================================
   HOW IT WORKS (steps)
   ========================================================================== */
.cs-steps { display: flex; flex-direction: column; gap: 56px; padding-left: var(--gutter); padding-right: var(--gutter); }
.cs-step { display: flex; flex-direction: column; gap: 24px; border-left: 1px solid var(--line-1); padding: 8px 0 8px clamp(28px, 3.5vw, 64px); }
.cs-step__n { font-family: var(--font-mono); font-size: 13px; letter-spacing: 0.22em; color: var(--accent); }
.cs-step__t { margin: 0; font-family: var(--font-display); font-weight: 700; font-size: clamp(40px, 4.5vw, 72px); letter-spacing: var(--tracking-display); line-height: 1; color: var(--fg-1); }
.cs-step__c { margin: 0; font-size: 17px; line-height: 1.6; color: var(--fg-2); max-width: 38ch; }
.cs-step__extra { display: flex; align-items: center; gap: 24px; margin-top: 8px; flex-wrap: wrap; }

/* score gauge */
.cs-gauge { width: 150px; position: relative; }
.cs-gauge svg { width: 100%; display: block; transform: rotate(-90deg); }
.cs-gauge__val { position: absolute; inset: 0; display: flex; flex-direction: column; align-items: center; justify-content: center; gap: 2px; }
.cs-gauge__num { font-family: var(--font-display); font-weight: 700; font-size: 31px; letter-spacing: -0.03em; color: var(--fg-1); line-height: 1; }
.cs-gauge__label { font-family: var(--font-mono); font-size: 9px; letter-spacing: 0.16em; text-transform: uppercase; color: var(--fg-3); }

/* ==========================================================================
   WAITLIST / CONTACT FORM (cream inversion block)
   ========================================================================== */
.cs-waitlist { background: var(--invert-bg); color: var(--invert-fg); padding: var(--section-pad) var(--gutter); position: relative; overflow: hidden; }
.cs-waitlist__rule { position: absolute; top: 0; left: 18%; right: 18%; border-top: 2px dashed var(--invert-line); }
.cs-waitlist__grid { max-width: var(--container); margin: 0 auto; display: grid; grid-template-columns: minmax(0, 6fr) minmax(0, 5fr); gap: clamp(48px, 6vw, 120px); align-items: start; }
.cs-waitlist__intro { display: flex; flex-direction: column; gap: 28px; }
.cs-waitlist__title { margin: 0; font-family: var(--font-display); font-weight: 700; font-size: var(--text-display); letter-spacing: var(--tracking-display); line-height: 0.98; color: var(--invert-fg); }
.cs-waitlist__lead { margin: 0; font-size: var(--text-lead); line-height: 1.5; color: var(--invert-muted); max-width: 44ch; }

.cs-form { display: flex; flex-direction: column; gap: 20px; }
.cs-form__row { display: grid; grid-template-columns: repeat(auto-fit, minmax(200px, 1fr)); gap: 16px; }
.cs-field { display: flex; flex-direction: column; gap: 8px; font-family: var(--font-body); }
.cs-field__label { font-family: var(--font-mono); font-size: 11px; letter-spacing: 0.14em; text-transform: uppercase; color: var(--invert-muted); }
.cs-field__label .req { color: var(--accent); }
.cs-field input {
  font-family: var(--font-body); font-size: 16px; color: var(--invert-fg);
  background: rgba(10,10,11,0.04); border: 1px solid var(--invert-line); border-radius: var(--radius-s);
  padding: 15px 18px; width: 100%; box-sizing: border-box;
  transition: border-color var(--dur-fast) var(--ease-standard), background var(--dur-fast) var(--ease-standard), box-shadow var(--dur-fast) var(--ease-standard);
}
.cs-field input:hover { border-color: rgba(10,10,11,0.3); }
.cs-field input:focus { outline: none; border-color: var(--accent); box-shadow: 0 0 0 3px var(--accent-tint); }
.cs-field input::placeholder { color: var(--invert-muted); }

.cs-checkbox { display: flex; gap: 12px; align-items: flex-start; cursor: pointer; font-family: var(--font-body); font-size: 14px; line-height: 1.5; color: var(--invert-muted); }
.cs-checkbox__box { position: relative; flex-shrink: 0; width: 20px; height: 20px; margin-top: 1px; }
.cs-checkbox input { position: absolute; inset: 0; opacity: 0; cursor: pointer; margin: 0; }
.cs-checkbox__mark { position: absolute; inset: 0; border-radius: 5px; border: 1px solid var(--invert-line); background: transparent;
  transition: background var(--dur-fast) var(--ease-standard), border-color var(--dur-fast) var(--ease-standard);
  display: flex; align-items: center; justify-content: center; color: #fff; font-size: 13px; font-weight: 700; }
.cs-checkbox input:checked + .cs-checkbox__mark { background: var(--accent); border-color: var(--accent); }
.cs-checkbox input:checked + .cs-checkbox__mark::after { content: '✓'; }

.cs-form__success { display: flex; flex-direction: column; gap: 12px; align-items: flex-start; animation: csFadeUp 0.8s var(--ease-reveal); }
@keyframes csFadeUp { from { opacity: 0; transform: translateY(24px); } to { opacity: 1; transform: none; } }
.cs-form__success-tag { font-family: var(--font-mono); font-size: 12px; letter-spacing: 0.18em; color: var(--accent); }
.cs-form__success h3 { margin: 0; font-family: var(--font-display); font-weight: 700; font-size: 32px; letter-spacing: -0.02em; color: var(--invert-fg); }
.cs-form__success p { margin: 0; font-family: var(--font-body); font-size: 16px; color: var(--invert-muted); }
.cs-form__error { color: var(--alert); font-family: var(--font-mono); font-size: 12px; letter-spacing: 0.06em; }

/* Dark variant of the form (when not on the cream block) */
.cs-form--dark .cs-field__label { color: var(--fg-3); }
.cs-form--dark .cs-field input { color: var(--fg-1); background: rgba(244,243,240,0.04); border-color: var(--line-2); }
.cs-form--dark .cs-field input:hover { border-color: var(--fg-3); }
.cs-form--dark .cs-checkbox { color: var(--fg-2); }
.cs-form--dark .cs-checkbox__mark { border-color: var(--line-2); }
.cs-form--dark .cs-form__success h3 { color: var(--fg-1); }
.cs-form--dark .cs-form__success p { color: var(--fg-2); }

/* ==========================================================================
   CTA BLOCK (generic)
   ========================================================================== */
.cs-cta { position: relative; padding: var(--section-pad) var(--gutter); overflow: hidden; }
.cs-cta__inner { max-width: var(--container); margin: 0 auto; display: flex; flex-direction: column; gap: 28px; align-items: flex-start; position: relative; z-index: 1; }
.cs-cta--center .cs-cta__inner { align-items: center; text-align: center; }
.cs-cta__bg { position: absolute; inset: 0; object-fit: cover; width: 100%; height: 100%; z-index: 0; }
.cs-overlay { position: absolute; inset: 0; z-index: 0; pointer-events: none; }

/* ==========================================================================
   INTRO BLOCK (generic)
   ========================================================================== */
.cs-intro { padding: var(--section-pad) var(--gutter); }
.cs-intro__inner { max-width: var(--container); margin: 0 auto; display: grid; gap: clamp(32px, 5vw, 96px); align-items: center; }
.cs-intro__inner.has-image { grid-template-columns: minmax(0, 1fr) minmax(0, 1fr); }
.cs-intro__text { display: flex; flex-direction: column; gap: 24px; }
.cs-intro__text p { margin: 0; font-size: 17px; line-height: 1.7; color: var(--fg-2); }
.cs-intro__media { position: relative; border-radius: var(--radius-l); overflow: hidden; }
.cs-intro__media img { display: block; width: 100%; }

/* ==========================================================================
   FOOTER
   ========================================================================== */
.cs-footer { background: var(--carbon-0); border-top: 1px solid var(--line-1); overflow: hidden; }
.cs-footer__inner { max-width: var(--container); margin: 0 auto; padding: 72px var(--gutter) 40px; }
.cs-footer__top { display: flex; flex-wrap: wrap; gap: 32px; justify-content: space-between; align-items: flex-start; padding-bottom: 64px; }
.cs-footer__inq-label { font-family: var(--font-mono); font-size: 11px; letter-spacing: 0.16em; text-transform: uppercase; color: var(--fg-3); }
.cs-footer__email { color: var(--fg-1); font-size: 18px; }
.cs-footer__socials { display: flex; gap: 28px; }
.cs-footer a { font-family: var(--font-body); font-size: 15px; color: var(--fg-2); }
.cs-footer a:hover { color: var(--accent-hover); }
.cs-footer__mark { font-family: var(--font-display); font-weight: 700; letter-spacing: -0.04em; font-size: clamp(3rem, 11.5vw, 12rem); line-height: 0.9; color: var(--fg-1); white-space: nowrap; user-select: none; }
.cs-footer__mark span { color: var(--accent); }
.cs-footer__legal { display: flex; flex-wrap: wrap; gap: 16px; justify-content: space-between; border-top: 1px solid var(--line-1); margin-top: 48px; padding-top: 24px; font-family: var(--font-body); font-size: 13px; color: var(--fg-3); }
.cs-footer__legal a { font-size: 13px; color: var(--fg-3); }

/* ==========================================================================
   RESPONSIVE
   ========================================================================== */
@media (max-width: 900px) {
  .cs-waitlist__grid { grid-template-columns: 1fr; }
  .cs-hero-chips { display: none; }
  .cs-intro__inner.has-image { grid-template-columns: 1fr; }
}

@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }
  .cs-road-scroll, .cs-scroll-line::after, .cs-marquee__track, .cs-device-float, .cs-device__led, .cs-trace { animation: none !important; }
  .cs-word { transform: none !important; }
  [data-reveal] { opacity: 1 !important; transform: none !important; }
}

/* ==========================================================================
   PRELOADER
   ========================================================================== */
.cs-preloader {
  position: fixed; inset: 0; z-index: 1000; background: var(--carbon-0);
  display: flex; align-items: center; justify-content: center;
  transition: transform 0.78s var(--ease-swift);
}
.cs-preloader__logo-mask { overflow: hidden; padding: 4px 0; }
.cs-preloader__logo { height: 36px; display: block; transform: translateY(112%); transition: transform 0.9s var(--ease-reveal); }
.cs-preloader__loading { position: absolute; left: var(--gutter); bottom: 30px; font-family: var(--font-mono); font-size: 12px; letter-spacing: 0.2em; color: var(--fg-3); }
.cs-preloader__num { position: absolute; right: var(--gutter); bottom: 24px; font-family: var(--font-display); font-weight: 700; font-size: 56px; letter-spacing: -0.04em; color: var(--fg-1); line-height: 1; }
.cs-preloader__num span:last-child { color: var(--accent); }
.cs-preloader__bar { position: absolute; left: 0; bottom: 0; height: 2px; background: var(--accent); width: 0; transition: width 0.1s linear; }
@media (prefers-reduced-motion: reduce) { .cs-preloader { display: none; } }

/* ==========================================================================
   MARQUEE — velocity shift room (JS nudges .cs-marquee on scroll velocity)
   ========================================================================== */
html.cs-js-anim .cs-marquee { width: calc(100% + 320px); margin-left: -160px; will-change: transform; }
html.cs-js-anim .cs-marquee .cs-marquee__track { padding-left: 160px; }

/* ==========================================================================
   DUAL MARKUP — stacked (accessible) vs heavy (pinned choreography)
   ========================================================================== */
.cs-products__heavy, .cs-dashtour__heavy, .cs-how__heavy { display: none; }
@media (min-width: 900px) {
  html.cs-js-anim .cs-products__stacked,
  html.cs-js-anim .cs-dashtour__stacked,
  html.cs-js-anim .cs-how__stacked { display: none; }
  html.cs-js-anim .cs-products__heavy { display: flex; }
  html.cs-js-anim .cs-dashtour__heavy { display: grid; }
  html.cs-js-anim .cs-how__heavy { display: block; }
}

/* ---- Products: pinned 3D card swap (display set only by the cs-js-anim toggle) */
.cs-products__heavy {
  height: 100vh; overflow: hidden; flex-direction: column; justify-content: center;
  padding: 0 var(--gutter); box-sizing: border-box;
}
.cs-products__heavy-inner { max-width: var(--container); margin: 0 auto; width: 100%; display: flex; flex-direction: column; gap: 56px; }
.cs-products__stage { display: grid; grid-template-columns: minmax(0, 5fr) minmax(0, 6fr); gap: clamp(32px, 5vw, 96px); align-items: center; perspective: 1400px; }
.cs-products__copies { display: grid; }
.cs-products__copies > .cs-prod-copy { grid-area: 1 / 1; }
.cs-products__cards { display: grid; }
.cs-products__cards > .cs-prod-card { grid-area: 1 / 1; }
.cs-products__progress { height: 2px; background: var(--line-1); position: relative; width: 200px; }
.cs-prod-bar { position: absolute; inset: 0; background: var(--accent); transform: scaleX(0); transform-origin: left; }

/* ---- Dashboard tour: pinned camera stage ---------------------------------- */
.cs-dashtour__heavy {
  height: 100vh; overflow: hidden; background: var(--carbon-2);
  border-top: 1px solid var(--line-1); border-bottom: 1px solid var(--line-1);
  grid-template-columns: minmax(340px, 4fr) minmax(0, 8fr);
  gap: clamp(24px, 3vw, 64px); padding: 0 var(--gutter); box-sizing: border-box; align-items: center;
}
.cs-tour-rail { position: relative; height: 380px; display: flex; flex-direction: column; justify-content: center; }
.cs-tour-dots { position: absolute; top: 0; display: flex; gap: 6px; }
.cs-tour-dot { width: 24px; height: 2px; background: var(--line-2); transition: transform 0.4s var(--ease-reveal), background 0.3s; transform-origin: left; }
.cs-tour-caption { position: absolute; display: flex; flex-direction: column; gap: 16px; max-width: 420px; }
.cs-tour-caption__kicker { font-family: var(--font-mono); font-size: 12px; letter-spacing: 0.2em; text-transform: uppercase; color: var(--accent-text); }
.cs-tour-caption__title { margin: 0; font-family: var(--font-display); font-weight: 700; font-size: clamp(30px, 2.6vw, 44px); line-height: 1.08; letter-spacing: -0.02em; color: var(--fg-1); text-wrap: balance; }
.cs-tour-caption__copy { margin: 0; font-size: 16.5px; line-height: 1.65; color: var(--fg-2); }
.cs-tour-stage { position: relative; height: 78vh; display: flex; align-items: center; justify-content: center; perspective: 1600px; min-width: 0; }
.cs-tour-ui-wrap { position: absolute; }
.cs-tour-hud { position: absolute; top: 6px; left: 50%; transform: translateX(-50%); display: flex; align-items: center; gap: 10px; z-index: 2; background: rgba(10,11,10,0.55); -webkit-backdrop-filter: blur(6px); backdrop-filter: blur(6px); border: 1px solid var(--line-1); border-radius: 999px; padding: 7px 16px; }
.cs-tour-hud__dot { width: 6px; height: 6px; border-radius: 50%; background: var(--accent-text); }
.cs-hud-text { font-family: var(--font-mono); font-size: 11px; letter-spacing: 0.2em; text-transform: uppercase; color: var(--fg-2); white-space: nowrap; }

/* ---- How it works: horizontal pinned track -------------------------------- */
.cs-how { padding: var(--section-pad) 0; }
.cs-how__head { padding: 0 var(--gutter); margin-bottom: 56px; }
.cs-how__head .cs-container { max-width: var(--container); margin: 0 auto; }
.cs-how__stacked .cs-steps { padding: 0 var(--gutter); }
.cs-step--panel {
  flex: 0 0 auto; width: min(620px, 72vw); box-sizing: border-box;
  border-left: 1px solid var(--line-1); padding: 0 clamp(28px, 3.5vw, 64px);
  justify-content: center;
}
@media (min-width: 900px) {
  html.cs-js-anim .cs-how {
    height: 100vh; overflow: hidden; padding: 0;
    display: flex; flex-direction: column; justify-content: center; gap: 48px;
  }
  html.cs-js-anim .cs-how__head { margin-bottom: 0; }
  .cs-steps--track { display: flex; flex-direction: row; align-items: stretch; padding-left: var(--gutter); will-change: transform; }
}

/* ==========================================================================
   LIVE DASHBOARD MOCK (ported from dashboard-mock.jsx)
   ========================================================================== */
.cs-dash-ui {
  position: relative; width: 1180px; height: 680px; background: #F6F4F2; border-radius: 14px;
  overflow: hidden; display: flex; font-family: 'Poppins', sans-serif; color: #242424; text-align: left;
  box-shadow: 0 24px 60px -24px rgba(0,0,0,0.8), 0 0 0 1px rgba(255,255,255,0.07);
}
.cs-dash-side { width: 176px; flex-shrink: 0; background: #fff; border-right: 1px solid #ECEAE7; padding: 14px 10px; display: flex; flex-direction: column; gap: 2px; }
.cs-dash-logo { width: 128px; margin: 2px 8px 14px; }
.cs-dash-menu-label { font-size: 8.5px; letter-spacing: 0.1em; color: #B9B9B9; padding: 0 8px 6px; font-weight: 600; }
.cs-dash-nav { display: flex; align-items: center; gap: 8px; padding: 7px 9px; border-radius: 6px; color: #3A3A3A; font-size: 10.5px; font-weight: 500; white-space: nowrap; overflow: hidden; }
.cs-dash-nav img { width: 13px; height: 13px; flex-shrink: 0; filter: grayscale(1) brightness(0.35); }
.cs-dash-nav.is-active { background: #4B7F57; color: #fff; font-weight: 600; }
.cs-dash-nav.is-active img { filter: none; }
.cs-dash-nav--foot { margin-top: auto; }
.cs-dash-main { flex-grow: 1; display: flex; flex-direction: column; min-width: 0; }
.cs-dash-head { display: flex; align-items: center; justify-content: space-between; padding: 10px 18px; background: #fff; border-bottom: 1px solid #ECEAE7; }
.cs-dash-head > b { font-size: 13px; font-weight: 700; }
.cs-dash-search { background: #F6F4F2; border-radius: 6px; font-size: 9px; color: #8E8E8E; padding: 6px 12px; width: 200px; }
.cs-dash-user { display: flex; align-items: center; gap: 8px; font-size: 9.5px; }
.cs-dash-user > span:first-child { text-align: right; line-height: 1.25; }
.cs-dash-user b { font-weight: 600; }
.cs-dash-user i { font-style: normal; color: #8E8E8E; font-size: 8px; }
.cs-dash-avatar { width: 24px; height: 24px; border-radius: 50%; background: #E4E4E4; }
.cs-dash-grid { padding: 14px; display: flex; flex-wrap: wrap; gap: 12px; align-content: flex-start; flex-grow: 1; }
.cs-dash-card { background: #fff; border-radius: 8px; padding: 12px 14px; box-sizing: border-box; box-shadow: 0 2px 3px -1px rgba(0,0,0,0.08); display: flex; flex-direction: column; gap: 8px; min-width: 0; }
.cs-dash-card-top { display: flex; justify-content: space-between; align-items: center; }
.cs-dash-card-top h4 { margin: 0; font-size: 12px; font-weight: 700; color: #242424; letter-spacing: 0.2px; }
.cs-dash-dots { color: #B9B9B9; font-size: 12px; line-height: 1; }
.cs-dash-bars { display: flex; flex-direction: column; gap: 6px; flex-grow: 1; justify-content: flex-end; }
.cs-dash-bars-row { display: flex; align-items: flex-end; gap: 10px; height: 96px; border-bottom: 1px solid #ECEAE7; }
.cs-dash-bar-col { flex: 1; display: flex; align-items: flex-end; justify-content: center; gap: 3px; height: 100%; }
.cs-dash-bar { width: 7px; border-radius: 3px 3px 0 0; }
.cs-dash-bars-x { display: flex; gap: 10px; }
.cs-dash-bars-x span { flex: 1; text-align: center; font-size: 8px; color: #606060; }
.cs-dash-legend { display: flex; gap: 12px; font-size: 8px; color: #606060; }
.cs-dash-legend i { display: inline-block; width: 7px; height: 7px; border-radius: 2px; margin-right: 4px; }
.cs-dash-score { display: flex; flex-direction: column; align-items: center; gap: 6px; flex-grow: 1; justify-content: center; }
.cs-dash-score-ring { position: relative; width: 92px; height: 92px; }
.cs-dash-score-num { position: absolute; inset: 0; display: flex; align-items: center; justify-content: center; font-size: 22px; font-weight: 600; color: #242424; }
.cs-dash-score-cap { font-size: 9.5px; font-weight: 600; color: #242424; }
.cs-dash-score-grid { display: grid; grid-template-columns: 1fr 1fr; gap: 2px 14px; font-size: 8.5px; color: #606060; }
.cs-dash-alerts { display: flex; flex-direction: column; flex-grow: 1; }
.cs-dash-alert { display: flex; gap: 8px; align-items: center; padding: 6px 0; }
.cs-dash-alert-ic { width: 22px; height: 22px; border-radius: 5px; display: flex; align-items: center; justify-content: center; flex-shrink: 0; }
.cs-dash-alert-ic img { width: 11px; height: 11px; }
.cs-dash-alert-tx { display: flex; flex-direction: column; min-width: 0; }
.cs-dash-alert-tx b { font-size: 9.5px; font-weight: 600; color: #242424; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.cs-dash-alert-tx i { font-size: 8px; font-style: normal; color: #8E8E8E; }
.cs-dash-map { position: relative; flex-grow: 1; border-radius: 6px; overflow: hidden; background: #EDEBE6; min-height: 110px; }
.cs-dash-map svg { position: absolute; inset: 0; width: 100%; height: 100%; }
.cs-dash-pin { position: absolute; width: 20px; animation: csPinFloat 2.6s ease-in-out infinite; transform-origin: 50% 100%; }
.cs-dash-pin-2 { animation-delay: 0.9s; }
.cs-dash-pin-3 { animation-delay: 1.6s; }
@keyframes csPinFloat { 0%, 100% { transform: translateY(0); } 50% { transform: translateY(-4px); } }
.cs-dash-live { position: absolute; right: 6px; top: 6px; background: #fff; border-radius: 4px; font-size: 8px; padding: 3px 6px; color: #4B7F57; font-weight: 600; box-shadow: 0 1px 2px rgba(0,0,0,0.15); }
.cs-dash-stats { display: flex; gap: 12px; width: 58%; flex-grow: 1; align-items: stretch; }
.cs-dash-stats-col { display: flex; flex-direction: column; gap: 12px; flex: 1; }
.cs-dash-stat { background: #fff; border-radius: 8px; padding: 10px 12px; flex: 1; box-shadow: 0 2px 3px -1px rgba(0,0,0,0.08); }
.cs-dash-stat-v { font-size: 17px; font-weight: 700; color: #4B7F57; line-height: 1.1; }
.cs-dash-stat-v span { font-size: 9px; color: #8E8E8E; font-weight: 500; }
.cs-dash-stat-l { font-size: 8.5px; color: #606060; }
.cs-dash-risky { background: #fff; border-radius: 8px; padding: 10px 12px; flex: 1.4; box-shadow: 0 2px 3px -1px rgba(0,0,0,0.08); display: flex; flex-direction: column; gap: 6px; }
.cs-dash-risky > b { font-size: 10.5px; font-weight: 700; }
.cs-dash-risky > span { display: flex; justify-content: space-between; font-size: 9px; color: #3A3A3A; border-bottom: 1px solid #F0EEE9; padding-bottom: 4px; }
@media (prefers-reduced-motion: reduce) { .cs-dash-pin { animation: none; } }

/* ==========================================================================
   GUTENBERG EDITOR PARITY (so blocks look right inside the editor)
   ========================================================================== */
.editor-styles-wrapper { background: var(--surface-page); }
.wp-block { max-width: none; }
/* editor: always show the accessible stacked layout, never the pinned heavy DOM */
.editor-styles-wrapper .cs-products__heavy,
.editor-styles-wrapper .cs-dashtour__heavy,
.editor-styles-wrapper .cs-how__heavy { display: none !important; }
.editor-styles-wrapper .cs-products__stacked,
.editor-styles-wrapper .cs-dashtour__stacked,
.editor-styles-wrapper .cs-how__stacked { display: block !important; }
