/* HedgeBot — main stylesheet. Plain static CSS, no framework. */

@font-face {
  font-family: "Audiowide";
  src: url("../fonts/Audiowide-Regular.ttf") format("truetype");
  font-weight: 400;
  font-style: normal;
  font-display: swap;
}

@font-face {
  font-family: "Inter";
  src: url("../fonts/Inter-Regular.woff2") format("woff2");
  font-weight: 400;
  font-style: normal;
  font-display: swap;
}

@font-face {
  font-family: "Inter";
  src: url("../fonts/Inter-Medium.woff2") format("woff2");
  font-weight: 500;
  font-style: normal;
  font-display: swap;
}

@font-face {
  font-family: "Inter";
  src: url("../fonts/Inter-SemiBold.woff2") format("woff2");
  font-weight: 600;
  font-style: normal;
  font-display: swap;
}

@font-face {
  font-family: "Inter";
  src: url("../fonts/Inter-Bold.woff2") format("woff2");
  font-weight: 700;
  font-style: normal;
  font-display: swap;
}

:root {
  --bg: #0b0b10;
  --panel: #121218;
  --panel-2: #16161f;
  --border: rgba(255, 255, 255, 0.08);
  --text: #f5f5f7;
  --muted: #a1a1aa;
  --muted-strong: #c4c4cc;
  --violet: #7c3aed;
  --violet-hover: #6d28d9;
  --purple: #8930fd;
  --green: #22c55e;
  --teal: #5eead4;
  --radius: 14px;
  --radius-sm: 10px;
  --max-width: 1120px;
  --section-pad: 64px;
  --font-body: "Inter", system-ui, -apple-system, "Segoe UI", sans-serif;
  --font-display: "Audiowide", "Inter", system-ui, sans-serif;
}

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

html {
  scroll-behavior: smooth;
  -webkit-text-size-adjust: 100%;
}

body {
  margin: 0;
  background: var(--bg);
  color: var(--text);
  font-family: var(--font-body);
  font-size: 1rem;
  line-height: 1.6;
  -webkit-font-smoothing: antialiased;
}

img {
  max-width: 100%;
  height: auto;
  display: block;
}

a {
  color: inherit;
}

h1,
h2,
h3 {
  line-height: 1.12;
  letter-spacing: -0.02em;
  margin: 0 0 0.5em;
  font-weight: 700;
}

h1 {
  font-size: 2.1rem;
}

h2 {
  font-size: 1.75rem;
}

h3 {
  font-size: 1.125rem;
  line-height: 1.3;
}

p {
  margin: 0 0 1em;
}

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

.container.narrow {
  max-width: 780px;
}

.skip-link {
  position: absolute;
  left: 16px;
  top: -60px;
  z-index: 200;
  background: var(--violet);
  color: #fff;
  padding: 12px 18px;
  border-radius: 8px;
  text-decoration: none;
  font-weight: 600;
  transition: top 0.2s ease;
}

.skip-link:focus {
  top: 12px;
}

:focus-visible {
  outline: 2px solid var(--purple);
  outline-offset: 3px;
  border-radius: 4px;
}

/* ---------- Buttons ---------- */

.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  min-height: 48px;
  padding: 12px 22px;
  border-radius: 999px;
  font-family: var(--font-body);
  font-size: 1rem;
  font-weight: 600;
  line-height: 1.2;
  text-decoration: none;
  border: 1px solid transparent;
  cursor: pointer;
  transition: background-color 0.2s ease, border-color 0.2s ease, transform 0.2s ease;
}

.btn-lg {
  min-height: 52px;
  padding: 14px 28px;
}

.btn-primary {
  background: var(--violet);
  color: #fff;
}

.btn-primary:hover {
  background: var(--violet-hover);
}

.btn-ghost {
  background: transparent;
  color: var(--text);
  border-color: var(--border);
}

.btn-ghost:hover {
  border-color: rgba(255, 255, 255, 0.28);
  background: rgba(255, 255, 255, 0.04);
}

.btn-light {
  background: #fff;
  color: #17101f;
}

.btn-light:hover {
  background: #e9e4f5;
}

/* ---------- Header / nav ---------- */

.site-header {
  position: sticky;
  top: 0;
  z-index: 100;
  background: rgba(11, 11, 16, 0.88);
  backdrop-filter: blur(12px);
  -webkit-backdrop-filter: blur(12px);
  border-bottom: 1px solid var(--border);
}

.header-inner {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 16px;
  min-height: 80px;
}

.brand {
  display: flex;
  align-items: center;
  gap: 12px;
  flex-shrink: 0;
  text-decoration: none;
  min-height: 44px;
}

.brand-icon {
  height: 46px;
  width: auto;
  flex-shrink: 0;
}

.brand-wordmark {
  font-family: var(--font-display);
  font-size: 1.5rem;
  line-height: 1;
  color: #fff;
  letter-spacing: 0.01em;
  white-space: nowrap;
}

.brand-wordmark-accent {
  color: var(--purple);
}

.site-nav {
  display: flex;
  align-items: center;
  gap: 8px;
}

.nav-list {
  display: flex;
  align-items: center;
  gap: 4px;
  list-style: none;
  margin: 0;
  padding: 0;
}

.nav-link {
  display: inline-flex;
  align-items: center;
  min-height: 44px;
  padding: 10px 14px;
  border-radius: 8px;
  color: var(--muted-strong);
  text-decoration: none;
  font-size: 0.95rem;
  font-weight: 500;
  transition: color 0.2s ease, background-color 0.2s ease;
}

.nav-link:hover {
  color: var(--text);
  background: rgba(255, 255, 255, 0.05);
}

.nav-cta {
  margin-left: 12px;
  min-height: 44px;
  padding: 10px 20px;
  font-size: 0.95rem;
}

.menu-toggle {
  display: none;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: 5px;
  width: 48px;
  height: 48px;
  padding: 0;
  background: transparent;
  border: 1px solid var(--border);
  border-radius: 10px;
  cursor: pointer;
}

.menu-toggle-bar {
  display: block;
  width: 20px;
  height: 2px;
  background: var(--text);
  border-radius: 2px;
  transition: transform 0.25s ease, opacity 0.25s ease;
}

.menu-toggle[aria-expanded="true"] .menu-toggle-bar:nth-child(1) {
  transform: translateY(7px) rotate(45deg);
}

.menu-toggle[aria-expanded="true"] .menu-toggle-bar:nth-child(2) {
  opacity: 0;
}

.menu-toggle[aria-expanded="true"] .menu-toggle-bar:nth-child(3) {
  transform: translateY(-7px) rotate(-45deg);
}

/* ---------- Hero ---------- */

.hero {
  padding: 72px 0 56px;
  background:
    radial-gradient(720px 420px at 85% -10%, rgba(137, 48, 253, 0.22), transparent 65%),
    radial-gradient(560px 360px at -10% 30%, rgba(124, 58, 237, 0.14), transparent 60%),
    var(--bg);
}

.hero-grid {
  display: grid;
  gap: 40px;
}

.eyebrow {
  margin: 0 0 16px;
  font-family: var(--font-display);
  font-size: 0.72rem;
  letter-spacing: 0.18em;
  text-transform: uppercase;
  color: #c4b5fd;
}

.hero-sub {
  margin: 0 0 28px;
  font-size: 1.125rem;
  line-height: 1.65;
  color: var(--muted);
  max-width: 34rem;
}

.hero-ctas {
  display: flex;
  flex-wrap: wrap;
  gap: 12px;
  margin-bottom: 24px;
}

.trust-line {
  margin: 0;
  font-size: 0.9rem;
  color: var(--muted);
}

/* Hero headline entrance — one continuous rise-and-fade on load.
   The whole headline moves as a single unit with a smooth ease-out, so
   the entrance reads as one fluid motion with no visible pause between
   parts (the previous word-by-word stagger read as discrete chunks).
   Text ends fully solid opaque white; no background-clip: text /
   transparent fill anywhere, so the headline can never be hidden by
   the animation, even if it fails, is paused, or the browser ignores it. */
#hero-heading {
  color: var(--text);
  animation: hero-in 1s cubic-bezier(0.22, 1, 0.36, 1) backwards;
}

.hero-word {
  display: inline-block;
}

@keyframes hero-in {
  from {
    opacity: 0;
    transform: translateY(16px);
  }
  to {
    opacity: 1;
    transform: translateY(0);
  }
}

/* Hero chart card */

.chart-card {
  margin: 0;
  background: var(--panel);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  padding: 20px;
  box-shadow: 0 24px 60px rgba(0, 0, 0, 0.45);
}

.chart-head {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  flex-wrap: wrap;
  margin-bottom: 8px;
}

.chart-title {
  font-size: 0.9rem;
  font-weight: 600;
  color: var(--muted-strong);
}

.chart-live {
  display: inline-flex;
  align-items: center;
  gap: 7px;
  font-size: 0.8rem;
  font-weight: 600;
  color: var(--muted);
}

.chart-dot {
  width: 8px;
  height: 8px;
  border-radius: 50%;
  background: var(--green);
  animation: pulse-dot 2.4s ease-in-out infinite;
}

@keyframes pulse-dot {
  0%,
  100% {
    opacity: 1;
    transform: scale(1);
  }

  50% {
    opacity: 0.55;
    transform: scale(0.8);
  }
}

.gap-chart {
  width: 100%;
  height: auto;
}

.chart-line {
  stroke-dasharray: 100;
  stroke-dashoffset: 100;
  animation: draw-line 1.8s ease-out 0.2s forwards;
}

.chart-line.line-b {
  animation-delay: 0.45s;
}

@keyframes draw-line {
  to {
    stroke-dashoffset: 0;
  }
}

.gap-band {
  opacity: 0;
  animation: fade-band 1s ease-out 1.4s forwards, breathe-band 4s ease-in-out 2.6s infinite;
}

@keyframes fade-band {
  to {
    opacity: 1;
  }
}

@keyframes breathe-band {
  0%,
  100% {
    opacity: 1;
  }

  50% {
    opacity: 0.45;
  }
}

.capture-point {
  opacity: 0;
  animation: fade-band 0.8s ease-out 1.9s forwards;
}

.capture-ring {
  transform-box: fill-box;
  transform-origin: center;
  animation: ring-expand 2.2s ease-out 2.4s infinite;
}

@keyframes ring-expand {
  0% {
    opacity: 0.9;
    transform: scale(1);
  }

  100% {
    opacity: 0;
    transform: scale(3.2);
  }
}

.chart-foot {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  flex-wrap: wrap;
  padding-top: 12px;
  border-top: 1px solid var(--border);
  font-size: 0.9rem;
  color: var(--muted);
}

.chart-foot strong {
  color: var(--text);
}

.chart-status {
  color: var(--green);
  font-weight: 600;
}

.chart-caption {
  margin-top: 12px;
  font-size: 0.8rem;
  color: var(--muted);
  text-align: center;
}

/* ---------- Ticker ---------- */

.ticker-section {
  border-top: 1px solid var(--border);
  border-bottom: 1px solid var(--border);
  background: var(--panel);
  padding: 18px 0 20px;
  overflow: hidden;
}

.ticker-label {
  margin: 0 0 12px;
  text-align: center;
  font-size: 0.8rem;
  color: var(--muted);
  padding: 0 20px;
}

.ticker {
  overflow: hidden;
  mask-image: linear-gradient(90deg, transparent, #000 6%, #000 94%, transparent);
  -webkit-mask-image: linear-gradient(90deg, transparent, #000 6%, #000 94%, transparent);
}

.ticker-track {
  display: flex;
  gap: 0;
  width: max-content;
  animation: ticker-scroll 46s linear infinite;
  will-change: transform;
}

/* Two identical sets, each its own composited layer. A single 6000px-wide
   layer exceeds the ~4096px texture limit on mobile GPUs and tears into
   overlapping text while scrolling; one set (~3000px) stays under it, so
   each set rasterises independently and the loop stays clean. */
.ticker-set {
  display: flex;
  flex-shrink: 0;
  will-change: transform;
  transform: translateZ(0);
  -webkit-backface-visibility: hidden;
  backface-visibility: hidden;
}

.ticker:hover .ticker-track {
  animation-play-state: paused;
}

@keyframes ticker-scroll {
  to {
    transform: translateX(-50%);
  }
}

.ticker-item {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  white-space: nowrap;
  padding: 6px 22px;
  border-right: 1px solid var(--border);
  font-size: 0.92rem;
  color: var(--muted);
}

.ticker-item strong {
  color: var(--text);
  font-weight: 600;
  font-variant-numeric: tabular-nums;
}

.ticker-item em {
  font-style: normal;
  color: var(--green);
  font-weight: 600;
  font-variant-numeric: tabular-nums;
}

/* ---------- Sections ---------- */

.section {
  padding: var(--section-pad) 0;
}

.section-alt {
  background: var(--panel);
  border-top: 1px solid var(--border);
  border-bottom: 1px solid var(--border);
}

.section-head {
  max-width: 640px;
  margin-bottom: 40px;
}

.section-intro {
  margin: 0;
  font-size: 1.1rem;
  line-height: 1.65;
  color: var(--muted);
}

/* ---------- Stepper ---------- */

.stepper {
  background: var(--panel);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  overflow: hidden;
}

.stepper-tabs {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  border-bottom: 1px solid var(--border);
}

.step-tab {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 8px;
  min-height: 64px;
  padding: 16px 8px 14px;
  background: transparent;
  border: 0;
  border-bottom: 2px solid transparent;
  color: var(--muted);
  font-family: var(--font-body);
  font-size: 0.9rem;
  font-weight: 600;
  cursor: pointer;
  transition: color 0.2s ease, background-color 0.2s ease, border-color 0.2s ease;
}

.step-tab:hover {
  color: var(--text);
  background: rgba(255, 255, 255, 0.03);
}

.step-tab.is-active {
  color: var(--text);
  border-bottom-color: var(--purple);
  background: rgba(137, 48, 253, 0.08);
}

.step-num {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 30px;
  height: 30px;
  border-radius: 50%;
  border: 1px solid var(--border);
  background: var(--panel-2);
  font-size: 0.85rem;
  font-weight: 700;
  color: var(--muted);
  transition: background-color 0.2s ease, border-color 0.2s ease, color 0.2s ease;
}

.step-tab.is-active .step-num {
  background: var(--violet);
  border-color: var(--violet);
  color: #fff;
}

.step-panel {
  display: grid;
  gap: 28px;
  padding: 32px 24px;
}

.step-copy h3 {
  font-size: 1.4rem;
  margin-bottom: 10px;
}

.step-copy p {
  margin: 0;
  font-size: 1.05rem;
  line-height: 1.65;
  color: var(--muted);
  max-width: 34rem;
}

/* Step diagrams (small, decorative) */

.step-diagram {
  display: flex;
  align-items: center;
  justify-content: center;
  min-height: 150px;
  background: var(--panel-2);
  border: 1px solid var(--border);
  border-radius: var(--radius-sm);
  padding: 20px;
}

.diagram {
  display: none;
  flex-direction: column;
  align-items: center;
  gap: 16px;
}

.diagram.is-active {
  display: flex;
}

.diagram-label {
  font-size: 0.85rem;
  font-weight: 600;
  color: var(--muted);
  letter-spacing: 0.02em;
}

.diagram-radar {
  width: 64px;
  height: 64px;
  border-radius: 50%;
  border: 1px solid rgba(137, 48, 253, 0.5);
  background: radial-gradient(circle, rgba(137, 48, 253, 0.35) 0 8%, transparent 70%);
  position: relative;
  animation: radar-spin 3s linear infinite;
}

.diagram-radar::after {
  content: "";
  position: absolute;
  inset: 0;
  border-radius: 50%;
  background: conic-gradient(from 0deg, rgba(137, 48, 253, 0.55), transparent 90deg);
}

@keyframes radar-spin {
  to {
    transform: rotate(360deg);
  }
}

.diagram-scale {
  display: flex;
  align-items: center;
  gap: 14px;
  font-weight: 700;
  color: var(--text);
}

.diagram-scale-left,
.diagram-scale-right {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 44px;
  height: 44px;
  border-radius: 10px;
  background: var(--panel);
  border: 1px solid var(--border);
}

/* Balance scale: the two sides bob in opposition while the beam tips,
   same 2.8s rhythm as the step 4 track fill. */
.diagram-scale-left {
  animation: scale-bob 2.8s ease-in-out infinite alternate;
}

.diagram-scale-right {
  animation: scale-bob 2.8s ease-in-out infinite alternate-reverse;
}

@keyframes scale-bob {
  from {
    transform: translateY(-3px);
  }

  to {
    transform: translateY(3px);
  }
}

.diagram-scale-beam {
  width: 56px;
  height: 3px;
  border-radius: 2px;
  background: linear-gradient(90deg, var(--violet), var(--purple));
  transform-origin: center;
  animation: scale-tilt 2.8s ease-in-out infinite alternate;
}

@keyframes scale-tilt {
  from {
    transform: rotate(-5deg);
  }

  to {
    transform: rotate(5deg);
  }
}

.diagram-legs {
  display: flex;
  gap: 12px;
}

.diagram-leg {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-width: 84px;
  min-height: 44px;
  padding: 10px 16px;
  border-radius: 10px;
  font-size: 0.9rem;
  font-weight: 600;
  border: 1px solid var(--border);
  background: var(--panel);
}

.diagram-leg.leg-a {
  border-color: rgba(137, 48, 253, 0.6);
  color: #d6bcff;
  animation: leg-place 2.8s ease-in-out infinite;
}

.diagram-leg.leg-b {
  border-color: rgba(94, 234, 212, 0.5);
  color: #a7f3ea;
  animation: leg-place 2.8s ease-in-out 1.4s infinite;
}

/* Legs are placed in sequence: the two chips light up in turn, same
   2.8s rhythm as the step 4 track fill, offset by half a cycle. */
@keyframes leg-place {
  0%,
  100% {
    opacity: 0.55;
    transform: scale(1);
  }

  50% {
    opacity: 1;
    transform: scale(1.06);
  }
}

.diagram-track {
  width: min(100%, 260px);
  height: 8px;
  border-radius: 99px;
  background: rgba(255, 255, 255, 0.1);
  overflow: hidden;
}

.diagram-track-fill {
  display: block;
  height: 100%;
  width: 72%;
  border-radius: 99px;
  background: linear-gradient(90deg, var(--violet), var(--purple));
  animation: track-fill 2.8s ease-in-out infinite alternate;
}

@keyframes track-fill {
  from {
    width: 30%;
  }

  to {
    width: 96%;
  }
}

/* ---------- Features ---------- */

.feature-grid {
  display: grid;
  gap: 16px;
}

.feature-card {
  background: var(--bg);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  padding: 28px 24px;
  transition: border-color 0.2s ease, transform 0.2s ease;
}

.feature-card:hover {
  border-color: rgba(137, 48, 253, 0.45);
  transform: translateY(-2px);
}

.feature-card h3 {
  margin-bottom: 10px;
  font-size: 1.15rem;
}

.feature-card p {
  margin: 0;
  color: var(--muted);
  line-height: 1.65;
}

/* ---------- Security ---------- */

.security-list {
  list-style: none;
  margin: 0;
  padding: 0;
  display: grid;
  gap: 14px;
}

.security-list li {
  display: flex;
  gap: 14px;
  align-items: flex-start;
  background: var(--panel);
  border: 1px solid var(--border);
  border-radius: var(--radius-sm);
  padding: 18px 20px;
  line-height: 1.6;
  color: var(--muted-strong);
}

.security-list a {
  color: var(--text);
  font-weight: 600;
  text-decoration-color: var(--purple);
  text-underline-offset: 3px;
}

.check {
  flex-shrink: 0;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 26px;
  height: 26px;
  border-radius: 50%;
  background: rgba(34, 197, 94, 0.14);
  color: var(--green);
  font-size: 0.85rem;
  font-weight: 700;
  line-height: 1;
}

/* ---------- FAQ ---------- */

.faq-list {
  display: grid;
  gap: 12px;
}

.faq-item {
  background: var(--bg);
  border: 1px solid var(--border);
  border-radius: var(--radius-sm);
  overflow: hidden;
}

.faq-item h3 {
  margin: 0;
}

.faq-button {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 16px;
  width: 100%;
  min-height: 56px;
  padding: 18px 20px;
  background: transparent;
  border: 0;
  color: var(--text);
  font-family: var(--font-body);
  font-size: 1.02rem;
  font-weight: 600;
  line-height: 1.4;
  text-align: left;
  cursor: pointer;
}

.faq-button:hover {
  background: rgba(255, 255, 255, 0.03);
}

.faq-icon {
  flex-shrink: 0;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 30px;
  height: 30px;
  border-radius: 50%;
  border: 1px solid var(--border);
  color: var(--muted);
  font-size: 1.15rem;
  font-weight: 400;
  line-height: 1;
  transition: transform 0.25s ease, color 0.25s ease, border-color 0.25s ease;
}

.faq-button[aria-expanded="true"] .faq-icon {
  transform: rotate(45deg);
  color: #fff;
  border-color: var(--violet);
  background: var(--violet);
}

.faq-answer {
  max-height: 0;
  overflow: hidden;
  transition: max-height 0.3s ease;
}

.faq-answer p {
  margin: 0;
  padding: 0 20px 20px;
  color: var(--muted);
  line-height: 1.65;
}

.faq-answer a {
  color: var(--text);
  font-weight: 600;
  text-decoration-color: var(--purple);
  text-underline-offset: 3px;
}

/* ---------- CTA band ---------- */

.cta-band {
  background: linear-gradient(120deg, var(--violet) 0%, var(--purple) 55%, #5b21b6 100%);
  padding: 72px 0;
}

.cta-inner {
  text-align: center;
}

.cta-inner h2 {
  font-size: 2rem;
  margin-bottom: 10px;
  color: #fff;
}

.cta-inner p {
  margin: 0 0 28px;
  font-size: 1.1rem;
  color: rgba(255, 255, 255, 0.85);
}

/* ---------- Footer ---------- */

.site-footer {
  background: #08080c;
  border-top: 1px solid var(--border);
  padding: 56px 0 32px;
}

/* Single centered nav row — the brand note and contact column were
   removed, so the footer is one row of links plus the legal row. */
.footer-inner {
  display: flex;
  justify-content: center;
  margin-bottom: 40px;
}

.footer-nav ul {
  list-style: none;
  margin: 0;
  padding: 0;
  display: flex;
  flex-wrap: wrap;
  justify-content: center;
  gap: 8px 32px;
}

.footer-nav a {
  display: inline-flex;
  align-items: center;
  min-height: 44px;
  color: var(--muted-strong);
  text-decoration: none;
  font-size: 0.95rem;
  font-weight: 500;
}

.footer-nav a:hover {
  color: var(--text);
}

.footer-legal {
  border-top: 1px solid var(--border);
  padding-top: 24px;
}

.footer-legal p {
  margin: 0;
  color: var(--muted);
  font-size: 0.85rem;
  line-height: 1.6;
}

/* ---------- Icon-only brand marks ---------- */

.section-mark {
  height: 36px;
  width: auto;
  margin-bottom: 18px;
}

.cta-mark {
  width: 84px;
  height: 84px;
  padding: 14px;
  background: #0b0b10;
  border: 1px solid rgba(255, 255, 255, 0.18);
  border-radius: 50%;
  box-shadow: 0 8px 24px rgba(0, 0, 0, 0.35);
  margin: 0 auto 22px;
}

.footer-mark {
  height: 40px;
  width: auto;
  margin: 0 auto 18px;
  opacity: 0.9;
}

/* ---------- Request access modal ---------- */

.modal[hidden] {
  display: none;
}

.modal {
  position: fixed;
  inset: 0;
  z-index: 300;
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 20px;
}

.modal-backdrop {
  position: absolute;
  inset: 0;
  background: rgba(5, 5, 8, 0.72);
  backdrop-filter: blur(4px);
  -webkit-backdrop-filter: blur(4px);
}

.modal-card {
  position: relative;
  width: 100%;
  max-width: 480px;
  max-height: calc(100vh - 40px);
  overflow-y: auto;
  background: var(--panel);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  padding: 32px 28px;
  box-shadow: 0 32px 80px rgba(0, 0, 0, 0.6);
}

.modal-close {
  position: absolute;
  top: 12px;
  right: 12px;
  width: 44px;
  height: 44px;
  padding: 0;
  border-radius: 50%;
  border: 1px solid var(--border);
  background: transparent;
  color: var(--muted);
  font-size: 1.5rem;
  font-family: var(--font-body);
  line-height: 1;
  cursor: pointer;
  transition: color 0.2s ease, border-color 0.2s ease;
}

.modal-close:hover {
  color: var(--text);
  border-color: rgba(255, 255, 255, 0.28);
}

.modal-card h2 {
  font-size: 1.6rem;
  margin-bottom: 8px;
  padding-right: 44px;
}

.modal-intro {
  color: var(--muted);
  margin-bottom: 24px;
}

.field {
  margin-bottom: 18px;
}

.field label {
  display: block;
  margin-bottom: 8px;
  font-size: 0.95rem;
  font-weight: 600;
}

.field label .optional {
  color: var(--muted);
  font-weight: 400;
}

.field input,
.field textarea {
  width: 100%;
  padding: 12px 14px;
  border-radius: var(--radius-sm);
  border: 1px solid var(--border);
  background: var(--panel-2);
  color: var(--text);
  font-family: var(--font-body);
  font-size: 1rem;
  line-height: 1.5;
  resize: vertical;
}

.field input:focus,
.field textarea:focus {
  outline: none;
  border-color: var(--purple);
  box-shadow: 0 0 0 3px rgba(137, 48, 253, 0.25);
}

.field input[aria-invalid="true"],
.field textarea[aria-invalid="true"] {
  border-color: #ef4444;
}

.field-error {
  margin: 6px 0 0;
  color: #f87171;
  font-size: 0.85rem;
}

.form-error {
  margin: 0 0 16px;
  color: #f87171;
  font-size: 0.9rem;
}

.modal-submit {
  width: 100%;
}

.modal-submit[disabled] {
  opacity: 0.6;
  cursor: wait;
}

.modal-success-view {
  text-align: center;
  padding: 12px 0 4px;
}

.modal-success-check {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 56px;
  height: 56px;
  margin: 0 auto 18px;
  border-radius: 50%;
  background: rgba(34, 197, 94, 0.14);
  color: var(--green);
  font-size: 1.6rem;
  font-weight: 700;
}

.modal-success-view h2 {
  padding-right: 0;
}

.modal-success-view p {
  color: var(--muted);
  margin-bottom: 24px;
}

/* ---------- Scroll reveals ---------- */

.js .reveal {
  opacity: 0;
  transform: translateY(16px);
  transition: opacity 0.6s ease, transform 0.6s ease;
}

.reveal.visible {
  opacity: 1;
  transform: translateY(0);
}

/* ---------- Breakpoints ---------- */

@media (max-width: 639px) {
  .header-inner {
    min-height: 72px;
  }

  .brand {
    gap: 10px;
  }

  .brand-icon {
    height: 38px;
  }

  .brand-wordmark {
    font-size: 1.25rem;
  }

  .hero-ctas .btn {
    flex: 1 1 auto;
  }

  .step-tab {
    font-size: 0.82rem;
    padding: 14px 4px 12px;
  }

  .step-panel {
    padding: 28px 20px;
  }
}

/* Tablet widths: the larger horizontal brand + full nav no longer fit side by
   side, so the hamburger menu takes over here instead of at 639px. */
@media (max-width: 860px) {
  .site-nav {
    position: absolute;
    top: 100%;
    left: 0;
    right: 0;
    display: none;
    flex-direction: column;
    align-items: stretch;
    gap: 4px;
    padding: 12px 20px 20px;
    background: var(--bg);
    border-bottom: 1px solid var(--border);
  }

  .site-nav.is-open {
    display: flex;
  }

  .nav-list {
    flex-direction: column;
    align-items: stretch;
  }

  .nav-link {
    width: 100%;
    padding: 12px 10px;
  }

  .nav-cta {
    margin: 8px 0 0;
    width: 100%;
  }

  .menu-toggle {
    display: flex;
  }
}

@media (min-width: 640px) {
  :root {
    --section-pad: 80px;
  }

  h1 {
    font-size: 2.6rem;
  }

  h2 {
    font-size: 2rem;
  }

  .feature-grid {
    grid-template-columns: repeat(2, 1fr);
  }

  .feature-card:last-child {
    grid-column: 1 / -1;
  }

  .step-panel {
    grid-template-columns: 1fr 1.2fr;
    align-items: center;
    padding: 36px 32px;
  }

}

@media (min-width: 1024px) {
  :root {
    --section-pad: 96px;
  }

  h1 {
    font-size: 3.5rem;
  }

  h2 {
    font-size: 2.25rem;
  }

  .hero {
    padding: 104px 0 88px;
  }

  .hero-grid {
    grid-template-columns: 1.05fr 1fr;
    align-items: center;
    gap: 56px;
  }

  .hero-sub {
    font-size: 1.2rem;
  }

  .feature-grid {
    grid-template-columns: repeat(3, 1fr);
  }

  .feature-card:last-child {
    grid-column: auto;
  }

  .feature-card:nth-child(4),
  .feature-card:nth-child(5) {
    grid-column: span 1;
  }

}

@media (min-width: 1280px) {
  h1 {
    font-size: 3.9rem;
  }
}

/* ---------- Reduced motion ---------- */

@media (prefers-reduced-motion: reduce) {
  html {
    scroll-behavior: auto;
  }

  *,
  *::before,
  *::after {
    animation-duration: 0.01ms !important;
    animation-iteration-count: 1 !important;
    transition-duration: 0.01ms !important;
  }

  .chart-line {
    stroke-dashoffset: 0;
  }

  .gap-band,
  .capture-point {
    opacity: 1;
  }

  #hero-heading {
    animation: none;
  }

  .ticker-track {
    animation: none;
    flex-wrap: wrap;
    width: auto;
  }

  .ticker-set {
    flex-wrap: wrap;
  }

  .ticker-set + .ticker-set {
    display: none;
  }

  .reveal {
    opacity: 1;
    transform: none;
  }
}
