/* ===== Design tokens ===== */
:root {
  /* Helix Systems brand palette */
  --navy: #0a0d31;
  --navy-2: #0c1340;
  --surface: #ffffff;
  --surface-2: #f5f7fa;
  --ink: #0a0d31;
  --ink-soft: #444c6b;
  --ink-faint: #818aa6;
  --line: #e4e8ef;
  --line-strong: #d3d9e4;
  --brand: #08679a;       /* logo blue */
  --electric: #0e26d6;    /* electric blue accent */
  --electric-ink: #0a1ca8;
  --accent: #d33a2c;      /* warning red */
  --warn-bg: #fdf3f1;
  --info-bg: #eef3f8;
  --ok: #0f8a8f;

  /* sharp, intentional radii */
  --r: 3px;
  --r-md: 4px;
  --r-lg: 6px;

  --shadow-card: 0 1px 1px rgba(10, 13, 49, 0.04), 0 8px 24px rgba(10, 13, 49, 0.05);
  --shadow-pop: 0 18px 50px rgba(10, 13, 49, 0.18);
  --container: 1140px;
  --ease: cubic-bezier(0.4, 0, 0.2, 1);
}

* { box-sizing: border-box; }

html { scroll-behavior: smooth; scroll-padding-top: 80px; }

body {
  margin: 0;
  font-family: "Inter", -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif;
  color: var(--ink);
  background: var(--surface);
  -webkit-font-smoothing: antialiased;
  text-rendering: optimizeLegibility;
  line-height: 1.6;
}

img { max-width: 100%; display: block; }
a { color: inherit; text-decoration: none; }

.container {
  width: 100%;
  max-width: var(--container);
  margin: 0 auto;
  padding: 0 28px;
}

/* ===== Shared: eyebrow ===== */
.eyebrow {
  display: inline-flex;
  align-items: center;
  gap: 12px;
  font-size: 0.72rem;
  letter-spacing: 0.18em;
  text-transform: uppercase;
  font-weight: 600;
  color: #9aa6c9;
  margin: 0 0 22px;
}
.eyebrow-rule {
  display: inline-block;
  width: 28px;
  height: 1px;
  background: var(--electric);
}
.eyebrow-light { color: var(--brand); }
.eyebrow-light .eyebrow-rule { background: var(--electric); }

/* ===== Scroll progress ===== */
.scroll-progress {
  position: fixed;
  top: 0; left: 0;
  height: 2px;
  width: 0%;
  background: var(--electric);
  z-index: 200;
  transition: width 0.1s linear;
}

/* ===== Header ===== */
.site-header {
  position: sticky;
  top: 0;
  z-index: 100;
  background: var(--surface);
  border-bottom: 1px solid transparent;
  transition: border-color 0.25s var(--ease), box-shadow 0.25s var(--ease);
}
.site-header.scrolled {
  border-bottom-color: var(--line);
  box-shadow: 0 1px 0 rgba(10, 13, 49, 0.04);
}
.header-inner {
  display: flex;
  align-items: center;
  justify-content: space-between;
  height: 70px;
}
.brand { display: inline-flex; align-items: center; }
.brand-logo { height: 34px; width: auto; display: block; }
.brand-logo-light { height: 32px; filter: brightness(0) invert(1); opacity: 0.9; }

.header-nav {
  display: flex;
  align-items: center;
  gap: 30px;
  font-size: 0.9rem;
  font-weight: 500;
}
.header-nav a { color: var(--ink-soft); transition: color 0.2s; position: relative; }
.header-nav a:not(.header-cta)::after {
  content: "";
  position: absolute;
  left: 0; bottom: -6px;
  width: 0; height: 2px;
  background: var(--electric);
  transition: width 0.25s var(--ease);
}
.header-nav a:not(.header-cta):hover { color: var(--ink); }
.header-nav a:not(.header-cta):hover::after { width: 100%; }
.header-cta {
  background: var(--electric);
  color: #fff !important;
  padding: 10px 18px;
  border-radius: var(--r);
  font-weight: 600;
  transition: background 0.2s;
}
.header-cta:hover { background: var(--electric-ink); }

/* ===== Hero ===== */
.hero {
  position: relative;
  overflow: hidden;
  background: var(--navy);
  color: #fff;
  padding: 100px 0 132px;
  border-bottom: 1px solid rgba(255, 255, 255, 0.06);
}
/* subtle blueprint grid */
.hero-grid {
  position: absolute;
  inset: 0;
  background-image:
    linear-gradient(rgba(255, 255, 255, 0.04) 1px, transparent 1px),
    linear-gradient(90deg, rgba(255, 255, 255, 0.04) 1px, transparent 1px);
  background-size: 64px 64px;
  mask-image: radial-gradient(1000px 600px at 75% 0%, #000 30%, transparent 80%);
  -webkit-mask-image: radial-gradient(1000px 600px at 75% 0%, #000 30%, transparent 80%);
  pointer-events: none;
}
.hero-inner { position: relative; max-width: 760px; }
.hero h1 {
  font-size: clamp(2.3rem, 5.4vw, 3.7rem);
  line-height: 1.06;
  letter-spacing: -0.025em;
  font-weight: 700;
  margin: 0 0 22px;
}
.hero-sub {
  max-width: 540px;
  margin: 0 0 36px;
  font-size: 1.1rem;
  color: #b7c0dc;
}
.hero-actions {
  display: flex;
  gap: 12px;
  flex-wrap: wrap;
  margin-bottom: 64px;
}

/* Buttons */
.btn {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  font-weight: 600;
  font-size: 0.97rem;
  padding: 13px 24px;
  border-radius: var(--r);
  transition: background 0.2s var(--ease), border-color 0.2s, color 0.2s, transform 0.15s var(--ease);
  cursor: pointer;
  border: 1px solid transparent;
}
.btn-primary { background: var(--electric); color: #fff; }
.btn-primary:hover { background: var(--electric-ink); }
.btn-ghost { background: transparent; border-color: rgba(255, 255, 255, 0.22); color: #fff; }
.btn-ghost:hover { background: rgba(255, 255, 255, 0.07); border-color: rgba(255, 255, 255, 0.4); }

/* Hero step list */
.hero-steps {
  list-style: none;
  margin: 0;
  padding: 0;
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  border-top: 1px solid rgba(255, 255, 255, 0.12);
}
.hero-steps li { border-right: 1px solid rgba(255, 255, 255, 0.12); }
.hero-steps li:last-child { border-right: none; }
.hero-step {
  display: flex;
  flex-direction: column;
  gap: 8px;
  padding: 22px 24px 22px 0;
  transition: opacity 0.2s;
}
.hero-steps li:not(:first-child) .hero-step { padding-left: 24px; }
.hero-step-num {
  font-size: 0.85rem;
  font-weight: 700;
  letter-spacing: 0.05em;
  color: var(--electric);
  font-variant-numeric: tabular-nums;
}
.hero-step-label { font-weight: 600; color: #e7ebf6; font-size: 1.02rem; }
.hero-step:hover .hero-step-label { color: #fff; }
.hero-step:hover .hero-step-num { color: #6f86ff; }

/* ===== Product switcher ===== */
.switch-bar {
  position: sticky;
  top: 70px;
  z-index: 90;
  background: rgba(255, 255, 255, 0.92);
  backdrop-filter: saturate(160%) blur(8px);
  -webkit-backdrop-filter: saturate(160%) blur(8px);
  border-bottom: 1px solid var(--line);
}
.switch-inner {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 16px;
  height: 64px;
}
.switch-label {
  font-size: 0.8rem;
  letter-spacing: 0.1em;
  text-transform: uppercase;
  font-weight: 600;
  color: var(--ink-faint);
}
.switch {
  position: relative;
  display: inline-flex;
  padding: 4px;
  background: var(--surface-2);
  border: 1px solid var(--line);
  border-radius: var(--r-md);
}
.switch-btn {
  position: relative;
  z-index: 1;
  appearance: none;
  border: none;
  background: transparent;
  font: inherit;
  font-weight: 600;
  font-size: 0.92rem;
  color: var(--ink-soft);
  padding: 9px 22px;
  border-radius: var(--r);
  cursor: pointer;
  transition: color 0.2s var(--ease);
  white-space: nowrap;
}
.switch-btn.is-active { color: #fff; }
.switch-thumb {
  position: absolute;
  top: 4px;
  bottom: 4px;
  left: 4px;
  width: 0;
  background: var(--navy);
  border-radius: var(--r);
  transition: transform 0.28s var(--ease), width 0.28s var(--ease);
  z-index: 0;
}

/* ===== Product panels ===== */
.product-panel[hidden] { display: none; }
.product-panel {
  display: flex;
  flex-direction: column;
  gap: 24px;
}

/* ===== Steps ===== */
.steps {
  margin-top: 36px;
  position: relative;
  z-index: 2;
  display: flex;
  flex-direction: column;
  gap: 24px;
  padding-bottom: 56px;
}
.step {
  background: var(--surface);
  border: 1px solid var(--line);
  border-radius: var(--r-lg);
  padding: 44px;
  box-shadow: var(--shadow-card);
  scroll-margin-top: 88px;
}
.step-head {
  display: flex;
  align-items: flex-start;
  gap: 22px;
  margin-bottom: 30px;
  padding-bottom: 26px;
  border-bottom: 1px solid var(--line);
}
.step-num {
  flex: none;
  font-size: 1.4rem;
  font-weight: 700;
  letter-spacing: -0.02em;
  color: #fff;
  background: var(--navy);
  width: 52px; height: 52px;
  display: grid; place-items: center;
  border-radius: var(--r-md);
  font-variant-numeric: tabular-nums;
}
.step-num-done { background: var(--ok); }
.step-titles { padding-top: 2px; }
.step-kicker {
  display: block;
  font-size: 0.72rem;
  letter-spacing: 0.16em;
  text-transform: uppercase;
  font-weight: 600;
  color: var(--brand);
  margin-bottom: 6px;
}
.step-head h2 {
  font-size: clamp(1.4rem, 2.6vw, 1.9rem);
  letter-spacing: -0.02em;
  font-weight: 700;
  margin: 0;
  line-height: 1.2;
}
.step-lead {
  font-size: 1.08rem;
  color: var(--ink-soft);
  margin: 0 0 30px;
  max-width: 68ch;
}

.step-grid {
  display: grid;
  grid-template-columns: 1fr 1.05fr;
  gap: 44px;
  align-items: start;
}
.step-copy { min-width: 0; padding-top: 4px; }

/* Checklist */
.checklist { list-style: none; margin: 0 0 24px; padding: 0; }
.checklist li {
  position: relative;
  padding-left: 32px;
  margin-bottom: 14px;
  font-size: 1.04rem;
  color: var(--ink-soft);
}
.checklist li strong { color: var(--ink); font-weight: 600; }
.checklist li::before {
  content: "";
  position: absolute;
  left: 0; top: 7px;
  width: 14px; height: 8px;
  border-left: 2px solid var(--electric);
  border-bottom: 2px solid var(--electric);
  transform: rotate(-45deg);
}

/* Notes / callouts — left accent bar, minimal radius */
.note {
  display: flex;
  gap: 14px;
  align-items: flex-start;
  padding: 16px 18px;
  border-radius: var(--r);
  border-left: 3px solid var(--brand);
  background: var(--info-bg);
  font-size: 0.97rem;
}
.note p { margin: 0; color: var(--ink-soft); }
.note p strong { color: var(--ink); }
.note-icon {
  flex: none;
  width: 22px; height: 22px;
  border-radius: 2px;
  display: grid; place-items: center;
  font-weight: 700;
  font-size: 0.82rem;
  font-style: normal;
  color: #fff;
  background: var(--brand);
}
.note-info { border-left-color: var(--brand); background: var(--info-bg); }
.note-info .note-icon { background: var(--brand); }
.note-warn { border-left-color: var(--accent); background: var(--warn-bg); }
.note-warn .note-icon { background: var(--accent); }
.note-wide { margin-top: 30px; }

/* Screenshots */
.shot {
  margin: 0;
  border-radius: var(--r-md);
  overflow: hidden;
  border: 1px solid var(--line);
  background: var(--surface-2);
  transition: box-shadow 0.25s var(--ease), border-color 0.25s var(--ease);
  cursor: zoom-in;
}
.shot:hover { border-color: var(--line-strong); box-shadow: var(--shadow-card); }
.shot img { width: 100%; }
.shot figcaption {
  padding: 12px 16px;
  font-size: 0.86rem;
  color: var(--ink-faint);
  border-top: 1px solid var(--line);
  background: #fff;
}
.shot figcaption strong { color: var(--ink-soft); font-weight: 600; }
.shot-sm { max-width: 420px; }

/* Substeps */
.substeps {
  margin-top: 30px;
  display: grid;
  gap: 1px;
  background: var(--line);
  border: 1px solid var(--line);
  border-radius: var(--r-md);
  overflow: hidden;
}
.substep {
  display: grid;
  grid-template-columns: 1fr 420px;
  gap: 32px;
  align-items: center;
  padding: 26px;
  background: var(--surface-2);
}
.substep-rev { grid-template-columns: 420px 1fr; }
.substep-rev .substep-text { order: 2; }
.substep h3 { margin: 0 0 8px; font-size: 1.12rem; letter-spacing: -0.01em; font-weight: 600; }
.substep p { margin: 0; color: var(--ink-soft); }
.substep .shot { background: #fff; }

/* Cards grid */
.cards {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 16px;
}
.cards-2 { grid-template-columns: repeat(2, 1fr); }
.card {
  background: var(--surface);
  border: 1px solid var(--line);
  border-radius: var(--r-md);
  padding: 16px;
  transition: border-color 0.2s var(--ease), box-shadow 0.2s var(--ease);
  display: flex;
  flex-direction: column;
}
.card:hover { border-color: var(--line-strong); box-shadow: var(--shadow-card); }
.card-shot {
  margin: 0 0 14px;
  height: 132px;
  border-radius: var(--r);
  overflow: hidden;
  background: var(--navy);
  border: 1px solid var(--line);
  display: grid;
  place-items: center;
  cursor: zoom-in;
}
.card-shot img { width: 100%; height: 100%; object-fit: cover; object-position: center; }
.card h3 { margin: 0 0 6px; font-size: 1.02rem; letter-spacing: -0.01em; font-weight: 600; }
.card p { margin: 0; font-size: 0.9rem; color: var(--ink-soft); }
.card p strong { color: var(--ink); font-weight: 600; }

/* ===== Help / contact ===== */
.help {
  background: var(--navy);
  color: #fff;
  padding: 80px 0;
  border-top: 3px solid var(--electric);
}
.help-inner {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 48px;
  align-items: center;
}
.help-copy h2 { font-size: clamp(1.7rem, 3.6vw, 2.4rem); margin: 0 0 12px; letter-spacing: -0.02em; font-weight: 700; }
.help-copy p { color: #b7c0dc; font-size: 1.08rem; margin: 0; max-width: 38ch; }
.help-cards { display: grid; gap: 14px; }
.help-card {
  display: flex;
  flex-direction: column;
  gap: 4px;
  padding: 22px 24px;
  border-radius: var(--r-md);
  background: rgba(255, 255, 255, 0.04);
  border: 1px solid rgba(255, 255, 255, 0.12);
  border-left: 3px solid var(--electric);
  transition: background 0.2s var(--ease), border-color 0.2s;
}
.help-card:hover { background: rgba(255, 255, 255, 0.08); }
.help-card-label { font-size: 0.74rem; letter-spacing: 0.14em; text-transform: uppercase; color: #8c98c0; font-weight: 600; }
.help-card-value { font-size: 1.35rem; font-weight: 700; letter-spacing: -0.01em; }
.help-card-meta { font-size: 0.88rem; color: #8c98c0; }

/* ===== Footer ===== */
.site-footer {
  background: #07091f;
  color: #9aa3c4;
  padding: 36px 0;
}
.footer-inner {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 16px;
  flex-wrap: wrap;
}
.footer-note { margin: 0; font-size: 0.88rem; }
.footer-copy { margin: 0; font-size: 0.82rem; color: #626a8c; }

/* ===== Lightbox ===== */
.lightbox {
  position: fixed;
  inset: 0;
  background: rgba(7, 9, 31, 0.9);
  display: none;
  align-items: center;
  justify-content: center;
  padding: 5vw;
  z-index: 300;
  cursor: zoom-out;
}
.lightbox.open { display: flex; animation: fade 0.18s var(--ease); }
.lightbox img {
  max-width: 100%;
  max-height: 90vh;
  border-radius: var(--r-md);
  box-shadow: var(--shadow-pop);
}
.lightbox-close {
  position: absolute;
  top: 22px; right: 26px;
  width: 42px; height: 42px;
  border-radius: var(--r);
  border: 1px solid rgba(255, 255, 255, 0.2);
  background: rgba(255, 255, 255, 0.08);
  color: #fff;
  font-size: 1.6rem;
  line-height: 1;
  cursor: pointer;
  transition: background 0.2s;
}
.lightbox-close:hover { background: rgba(255, 255, 255, 0.18); }

@keyframes fade { from { opacity: 0; } to { opacity: 1; } }

/* ===== Reveal on scroll ===== */
.reveal { opacity: 0; transform: translateY(16px); }
.reveal.in { opacity: 1; transform: none; transition: opacity 0.5s var(--ease), transform 0.5s var(--ease); }

/* ===== Responsive ===== */
@media (max-width: 980px) {
  .cards { grid-template-columns: repeat(2, 1fr); }
}
@media (max-width: 860px) {
  .header-nav a:not(.header-cta) { display: none; }
  .step { padding: 30px 24px; }
  .step-grid { grid-template-columns: 1fr; gap: 26px; }
  .substep, .substep-rev { grid-template-columns: 1fr; }
  .substep-rev .substep-text { order: 0; }
  .shot-sm { max-width: 100%; }
  .help-inner { grid-template-columns: 1fr; }
}
@media (max-width: 560px) {
  .switch-inner { flex-direction: column; justify-content: center; gap: 10px; height: auto; padding-top: 14px; padding-bottom: 14px; }
  .switch { width: 100%; }
  .switch-btn { flex: 1; padding: 10px 12px; text-align: center; }
  .hero { padding: 72px 0 104px; }
  .hero-steps { grid-template-columns: 1fr; }
  .hero-steps li { border-right: none; border-bottom: 1px solid rgba(255, 255, 255, 0.12); }
  .hero-steps li:last-child { border-bottom: none; }
  .hero-steps li:not(:first-child) .hero-step { padding-left: 0; }
  .hero-step { padding: 16px 0; }
  .cards { grid-template-columns: 1fr; }
  .step-head { gap: 16px; }
  .step-num { width: 44px; height: 44px; font-size: 1.2rem; }
}

@media (prefers-reduced-motion: reduce) {
  * { scroll-behavior: auto !important; }
  .reveal { opacity: 1; transform: none; }
}
