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

:root {
  --navy: #0a0f1e;
  --navy-mid: #111827;
  --navy-light: #1a2540;
  --blue: #2d6eff;
  --blue-dim: #1a4db8;
  --amber: #ffa826;
  --white: #f0efeb;
  --muted: #8a9bc0;
  --border: rgba(255, 255, 255, 0.08);
  --mono: "JetBrains Mono", monospace;
  --sans: "Space Grotesk", sans-serif;
  --body: "Inter", sans-serif;
}

html {
  scroll-behavior: smooth;
}

body {
  background: var(--navy);
  color: var(--white);
  font-family: var(--body);
  font-size: 16px;
  line-height: 1.7;
  overflow-x: hidden;
}

/* ── NAV ── */
nav {
  position: fixed;
  top: 0;
  left: 0;
  right: 0;
  z-index: 100;
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 1.2rem 3rem;
  background: rgba(10, 15, 30, 0.85);
  backdrop-filter: blur(12px);
  border-bottom: 1px solid var(--border);
}
.nav-logo {
  font-family: var(--sans);
  font-weight: 700;
  font-size: 1.1rem;
  letter-spacing: -0.02em;
  color: var(--white);
  display: flex;
  align-items: center;
  gap: 10px;
}
.logo-dot {
  width: 8px;
  height: 8px;
  border-radius: 50%;
  background: var(--blue);
  display: inline-block;
}
.nav-links {
  display: flex;
  gap: 2rem;
}
.nav-links a {
  color: var(--muted);
  text-decoration: none;
  font-size: 0.9rem;
  font-family: var(--sans);
  transition: color 0.2s;
}
.nav-links a:hover {
  color: var(--white);
}
.nav-cta {
  background: var(--blue);
  color: #fff;
  border: none;
  padding: 0.55rem 1.4rem;
  border-radius: 6px;
  font-family: var(--sans);
  font-size: 0.9rem;
  font-weight: 500;
  cursor: pointer;
  text-decoration: none;
  transition: background 0.2s;
}
.nav-cta:hover {
  background: var(--blue-dim);
}

/* ── HERO ── */
.hero {
  min-height: 100vh;
  display: flex;
  align-items: center;
  justify-content: center;
  flex-direction: column;
  text-align: center;
  padding: 8rem 2rem 4rem;
  position: relative;
  overflow: hidden;
}
.hero-grid-bg {
  position: absolute;
  inset: 0;
  pointer-events: none;
  background-image:
    linear-gradient(rgba(45, 110, 255, 0.05) 1px, transparent 1px),
    linear-gradient(90deg, rgba(45, 110, 255, 0.05) 1px, transparent 1px);
  background-size: 60px 60px;
  mask-image: radial-gradient(
    ellipse 80% 70% at 50% 40%,
    black 20%,
    transparent 80%
  );
}
.hero-eyebrow {
  font-family: var(--mono);
  font-size: 0.78rem;
  color: var(--blue);
  letter-spacing: 0.12em;
  text-transform: uppercase;
  display: flex;
  align-items: center;
  gap: 8px;
  margin-bottom: 1.5rem;
}
.eyebrow-line {
  width: 24px;
  height: 1px;
  background: var(--blue);
}
h1 {
  font-family: var(--sans);
  font-size: clamp(2.6rem, 6vw, 4.8rem);
  font-weight: 700;
  letter-spacing: -0.04em;
  line-height: 1.05;
  max-width: 820px;
  margin-bottom: 1.5rem;
}
h1 em {
  font-style: normal;
  color: var(--blue);
}
.hero-sub {
  font-size: 1.15rem;
  color: var(--muted);
  max-width: 520px;
  font-weight: 300;
  line-height: 1.7;
  margin-bottom: 2.5rem;
  font-family: var(--body);
}
.hero-actions {
  display: flex;
  gap: 1rem;
  flex-wrap: wrap;
  justify-content: center;
}
.btn-primary {
  background: var(--blue);
  color: #fff;
  padding: 0.85rem 2rem;
  border-radius: 8px;
  border: none;
  font-family: var(--sans);
  font-size: 1rem;
  font-weight: 600;
  cursor: pointer;
  text-decoration: none;
  display: inline-flex;
  align-items: center;
  gap: 8px;
  transition:
    background 0.2s,
    transform 0.15s;
}
.btn-primary:hover {
  background: var(--blue-dim);
  transform: translateY(-1px);
}
.btn-secondary {
  background: transparent;
  color: var(--muted);
  padding: 0.85rem 2rem;
  border-radius: 8px;
  border: 1px solid var(--border);
  font-family: var(--sans);
  font-size: 1rem;
  cursor: pointer;
  text-decoration: none;
  display: inline-flex;
  align-items: center;
  gap: 8px;
  transition:
    color 0.2s,
    border-color 0.2s;
}
.btn-secondary:hover {
  color: var(--white);
  border-color: rgba(255, 255, 255, 0.2);
}

/* ── INTERACTIVE REMOTE DEMO ── */
.demo-section {
  padding: 6rem 2rem;
  display: flex;
  justify-content: center;
  align-items: flex-start;
  gap: 5rem;
  flex-wrap: wrap;
  max-width: 1100px;
  margin: 0 auto;
}
.demo-remote {
  flex-shrink: 0;
  position: relative;
}
.remote-body {
  width: 140px;
  background: #141c2e;
  border-radius: 28px;
  border: 1px solid rgba(255, 255, 255, 0.1);
  padding: 20px 14px 28px;
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 6px;
  position: relative;
}
.remote-top-bar {
  width: 40px;
  height: 5px;
  border-radius: 3px;
  background: rgba(255, 255, 255, 0.08);
  margin-bottom: 6px;
}
.remote-ir-eye {
  width: 14px;
  height: 14px;
  border-radius: 50%;
  background: #1a0030;
  border: 1px solid #5a2080;
  margin-bottom: 10px;
}
.remote-ir-eye.firing {
  background: #9030d0;
  box-shadow: 0 0 12px 4px rgba(144, 48, 208, 0.6);
}
.r-btn {
  width: 44px;
  height: 32px;
  border-radius: 6px;
  border: 1px solid rgba(255, 255, 255, 0.1);
  background: #1e2a42;
  cursor: pointer;
  font-family: var(--mono);
  font-size: 0.58rem;
  color: var(--muted);
  display: flex;
  align-items: center;
  justify-content: center;
  transition:
    background 0.1s,
    color 0.1s,
    transform 0.1s;
  user-select: none;
  letter-spacing: 0.05em;
  white-space: nowrap;
  padding: 0 4px;
  text-align: center;
}
.r-btn:hover {
  background: #253350;
  color: var(--white);
}
.r-btn.active {
  background: var(--blue);
  color: #fff;
  transform: scale(0.95);
}
.r-btn.amber-btn.active {
  background: var(--amber);
  color: #1a1000;
}
.remote-row {
  display: flex;
  gap: 6px;
  justify-content: center;
}
.r-btn.wide {
  width: 94px;
}

/* ── SIGNAL RINGS (signature element) ── */
.signal-rings {
  position: absolute;
  top: 50%;
  left: 50%;
  transform: translate(-50%, -50%);
  pointer-events: none;
  z-index: 0;
  opacity: 0;
}
.signal-rings.burst {
  animation: burst-rings 0.6s ease-out forwards;
}
@keyframes burst-rings {
  0% {
    opacity: 0.9;
  }
  100% {
    opacity: 0;
  }
}
.ring {
  position: absolute;
  border-radius: 50%;
  border: 1.5px solid var(--blue);
  top: 50%;
  left: 50%;
  transform: translate(-50%, -50%);
}
.ring-1 {
  animation: ring-expand 0.6s ease-out forwards;
}
.ring-2 {
  animation: ring-expand 0.6s 0.1s ease-out forwards;
}
.ring-3 {
  animation: ring-expand 0.6s 0.2s ease-out forwards;
}
@keyframes ring-expand {
  from {
    width: 0;
    height: 0;
    opacity: 0.8;
  }
  to {
    width: 200px;
    height: 200px;
    opacity: 0;
  }
}

/* ── ACTION DISPLAY ── */
.demo-action-panel {
  flex: 1;
  min-width: 280px;
  padding-top: 20px;
}
.demo-label {
  font-family: var(--mono);
  font-size: 0.72rem;
  color: var(--muted);
  letter-spacing: 0.1em;
  text-transform: uppercase;
  margin-bottom: 1rem;
}
.action-display {
  background: var(--navy-mid);
  border: 1px solid var(--border);
  border-radius: 12px;
  padding: 1.5rem;
  min-height: 180px;
  display: flex;
  flex-direction: column;
  justify-content: center;
  position: relative;
  overflow: hidden;
}
.action-display::before {
  content: "";
  position: absolute;
  top: 0;
  left: 0;
  width: 3px;
  height: 100%;
  background: var(--blue);
  border-radius: 3px 0 0 3px;
  transition: background 0.3s;
}
.action-display.amber-mode::before {
  background: var(--amber);
}
.action-cmd {
  font-family: var(--mono);
  font-size: 0.85rem;
  color: var(--blue);
  margin-bottom: 0.4rem;
}
.action-cmd.amber {
  color: var(--amber);
}
.action-title {
  font-family: var(--sans);
  font-size: 1.6rem;
  font-weight: 700;
  color: var(--white);
  letter-spacing: -0.02em;
  line-height: 1.2;
  margin-bottom: 0.5rem;
}
.action-desc {
  font-size: 0.9rem;
  color: var(--muted);
  font-family: var(--body);
}
.action-key {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  background: var(--navy-light);
  border: 1px solid var(--border);
  border-radius: 5px;
  padding: 2px 10px;
  font-family: var(--mono);
  font-size: 0.8rem;
  color: var(--white);
  margin-top: 0.8rem;
}
.demo-hint {
  font-size: 0.82rem;
  color: var(--muted);
  margin-top: 1rem;
  font-family: var(--body);
  display: flex;
  align-items: center;
  gap: 6px;
}
.hint-arrow {
  color: var(--blue);
}

/* ── SECTIONS ── */
section {
  padding: 5rem 2rem;
}
.container {
  max-width: 1000px;
  margin: 0 auto;
}
.section-label {
  font-family: var(--mono);
  font-size: 0.75rem;
  color: var(--blue);
  letter-spacing: 0.1em;
  text-transform: uppercase;
  margin-bottom: 0.8rem;
}
h2 {
  font-family: var(--sans);
  font-size: clamp(1.8rem, 4vw, 2.8rem);
  font-weight: 700;
  letter-spacing: -0.03em;
  line-height: 1.1;
  margin-bottom: 1rem;
}
h2 em {
  font-style: normal;
  color: var(--blue);
}
.section-sub {
  font-size: 1rem;
  color: var(--muted);
  max-width: 480px;
  font-weight: 300;
}

/* ── HOW IT WORKS ── */
.steps {
  display: flex;
  gap: 0;
  margin-top: 3.5rem;
  flex-wrap: wrap;
}
.step {
  flex: 1;
  min-width: 220px;
  padding: 2rem 2rem 2rem 0;
  border-top: 1px solid var(--border);
  position: relative;
}
.step::after {
  content: "";
  position: absolute;
  top: -1px;
  left: 0;
  width: 40px;
  height: 2px;
  background: var(--blue);
}
.step-num {
  font-family: var(--mono);
  font-size: 0.72rem;
  color: var(--blue);
  letter-spacing: 0.08em;
  margin-bottom: 0.8rem;
}
.step h3 {
  font-family: var(--sans);
  font-size: 1.05rem;
  font-weight: 600;
  color: var(--white);
  margin-bottom: 0.5rem;
  letter-spacing: -0.01em;
}
.step p {
  font-size: 0.9rem;
  color: var(--muted);
  line-height: 1.65;
}
.step code {
  font-family: var(--mono);
  font-size: 0.82rem;
  color: var(--amber);
  background: rgba(255, 168, 38, 0.1);
  padding: 1px 6px;
  border-radius: 4px;
}

/* ── COMMAND TABLE ── */
.cmd-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(220px, 1fr));
  gap: 1px;
  background: var(--border);
  border: 1px solid var(--border);
  border-radius: 12px;
  overflow: hidden;
  margin-top: 2.5rem;
}
.cmd-cell {
  background: var(--navy-mid);
  padding: 1rem 1.2rem;
  display: flex;
  align-items: center;
  gap: 12px;
}
.cmd-key {
  font-family: var(--mono);
  font-size: 0.75rem;
  color: var(--blue);
  background: rgba(45, 110, 255, 0.12);
  padding: 3px 8px;
  border-radius: 4px;
  flex-shrink: 0;
  min-width: 80px;
  text-align: center;
}
.cmd-desc {
  font-size: 0.88rem;
  color: var(--muted);
  font-family: var(--body);
}

/* ── OPEN SOURCE BAND ── */
.oss-band {
  background: var(--navy-mid);
  border-top: 1px solid var(--border);
  border-bottom: 1px solid var(--border);
  padding: 4rem 2rem;
  text-align: center;
}
.oss-badge {
  display: inline-flex;
  align-items: center;
  gap: 10px;
  background: rgba(45, 110, 255, 0.1);
  border: 1px solid rgba(45, 110, 255, 0.25);
  border-radius: 100px;
  padding: 6px 18px;
  font-family: var(--mono);
  font-size: 0.78rem;
  color: var(--blue);
  margin-bottom: 1.5rem;
  letter-spacing: 0.05em;
}
.oss-title {
  font-family: var(--sans);
  font-size: 1.8rem;
  font-weight: 700;
  letter-spacing: -0.03em;
  margin-bottom: 0.8rem;
}
.oss-sub {
  color: var(--muted);
  font-size: 0.95rem;
  max-width: 480px;
  margin: 0 auto 2rem;
}
.oss-links {
  display: flex;
  gap: 1rem;
  justify-content: center;
  flex-wrap: wrap;
}

/* ── HARDWARE SPEC ── */
.spec-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(200px, 1fr));
  gap: 1rem;
  margin-top: 2.5rem;
}
.spec-card {
  background: var(--navy-mid);
  border: 1px solid var(--border);
  border-radius: 10px;
  padding: 1.2rem 1.4rem;
}
.spec-icon {
  font-size: 1.4rem;
  margin-bottom: 0.6rem;
}
.spec-label {
  font-family: var(--mono);
  font-size: 0.72rem;
  color: var(--muted);
  letter-spacing: 0.08em;
}
.spec-val {
  font-family: var(--sans);
  font-size: 0.95rem;
  color: var(--white);
  font-weight: 500;
  margin-top: 2px;
}
.spec-card a {
  color: var(--blue);
  text-decoration: none;
  font-size: 0.8rem;
}
.spec-card a:hover {
  text-decoration: underline;
}

/* ── CTA FOOTER ── */
.cta-footer {
  text-align: center;
  padding: 7rem 2rem;
  position: relative;
  overflow: hidden;
}
.cta-glow {
  position: absolute;
  width: 600px;
  height: 600px;
  background: radial-gradient(
    ellipse,
    rgba(45, 110, 255, 0.12) 0%,
    transparent 70%
  );
  top: 50%;
  left: 50%;
  transform: translate(-50%, -50%);
  pointer-events: none;
}
.cta-footer h2 {
  font-size: clamp(2rem, 5vw, 3.5rem);
  margin-bottom: 1rem;
  position: relative;
}
.cta-footer p {
  color: var(--muted);
  margin-bottom: 2.5rem;
  position: relative;
  font-size: 1rem;
}

/* ── FOOTER BAR ── */
footer {
  border-top: 1px solid var(--border);
  padding: 1.5rem 3rem;
  display: flex;
  justify-content: space-between;
  align-items: center;
  font-size: 0.82rem;
  color: var(--muted);
  flex-wrap: wrap;
  gap: 1rem;
}
footer a {
  color: var(--muted);
  text-decoration: none;
}
footer a:hover {
  color: var(--white);
}

/* ── DIVIDER ── */
.divider {
  border: none;
  border-top: 1px solid var(--border);
}

/* ── DOWNLOAD MODAL ── */
.modal-overlay {
  position: fixed;
  inset: 0;
  z-index: 200;
  background: rgba(6, 9, 18, 0.75);
  backdrop-filter: blur(6px);
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 1.5rem;
  opacity: 0;
  visibility: hidden;
  transition:
    opacity 0.2s ease,
    visibility 0.2s ease;
}
.modal-overlay.open {
  opacity: 1;
  visibility: visible;
}
.modal-card {
  background: var(--navy-mid);
  border: 1px solid var(--border);
  border-radius: 16px;
  max-width: 460px;
  width: 100%;
  padding: 2rem;
  position: relative;
  transform: translateY(10px) scale(0.98);
  transition: transform 0.2s ease;
  box-shadow: 0 30px 60px -20px rgba(0, 0, 0, 0.6);
}
.modal-overlay.open .modal-card {
  transform: translateY(0) scale(1);
}
.modal-close {
  position: absolute;
  top: 1.2rem;
  right: 1.2rem;
  background: transparent;
  border: none;
  color: var(--muted);
  font-size: 1.3rem;
  line-height: 1;
  cursor: pointer;
  width: 32px;
  height: 32px;
  display: flex;
  align-items: center;
  justify-content: center;
  border-radius: 8px;
  transition:
    color 0.2s,
    background 0.2s;
}
.modal-close:hover {
  color: var(--white);
  background: rgba(255, 255, 255, 0.06);
}
.modal-eyebrow {
  font-family: var(--mono);
  font-size: 0.72rem;
  color: var(--blue);
  letter-spacing: 0.1em;
  text-transform: uppercase;
  margin-bottom: 0.6rem;
}
.modal-title {
  font-family: var(--sans);
  font-size: 1.5rem;
  font-weight: 700;
  letter-spacing: -0.02em;
  margin-bottom: 0.4rem;
}
.modal-sub {
  font-size: 0.92rem;
  color: var(--muted);
  margin-bottom: 1.8rem;
  line-height: 1.6;
}
.modal-options {
  display: flex;
  flex-direction: column;
  gap: 0.9rem;
}
.modal-option {
  display: flex;
  align-items: flex-start;
  gap: 0.9rem;
  background: var(--navy-light);
  border: 1px solid var(--border);
  border-radius: 10px;
  padding: 1rem 1.1rem;
  text-decoration: none;
  transition:
    border-color 0.2s,
    background 0.2s,
    transform 0.15s;
}
.modal-option:hover {
  border-color: rgba(45, 110, 255, 0.4);
  background: #1f2c4a;
  transform: translateY(-1px);
}
.modal-option-icon {
  flex-shrink: 0;
  width: 38px;
  height: 38px;
  border-radius: 8px;
  background: rgba(45, 110, 255, 0.12);
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 1.1rem;
}
.modal-option-text {
  flex: 1;
  min-width: 0;
}
.modal-option-title {
  font-family: var(--sans);
  font-size: 0.98rem;
  font-weight: 600;
  color: var(--white);
  margin-bottom: 0.15rem;
}
.modal-option-desc {
  font-size: 0.82rem;
  color: var(--muted);
  line-height: 1.5;
}
.modal-option-caption {
  display: flex;
  align-items: center;
  gap: 6px;
  font-family: var(--mono);
  font-size: 0.72rem;
  color: var(--amber);
  margin-top: 0.5rem;
  background: rgba(255, 168, 38, 0.08);
  border: 1px solid rgba(255, 168, 38, 0.2);
  border-radius: 6px;
  padding: 5px 9px;
  width: fit-content;
}
.modal-option-arrow {
  flex-shrink: 0;
  color: var(--muted);
  font-size: 1rem;
  align-self: center;
}
.modal-option:hover .modal-option-arrow {
  color: var(--blue);
}

/* ── INLINE APP-DOWNLOAD LINK (step 03) ── */
.step-download-link {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  margin-top: 0.9rem;
  font-family: var(--sans);
  font-size: 0.85rem;
  font-weight: 500;
  color: var(--blue);
  text-decoration: none;
  border: 1px solid rgba(45, 110, 255, 0.25);
  background: rgba(45, 110, 255, 0.08);
  border-radius: 6px;
  padding: 5px 11px;
  transition:
    background 0.2s,
    border-color 0.2s;
}
.step-download-link:hover {
  background: rgba(45, 110, 255, 0.16);
  border-color: rgba(45, 110, 255, 0.45);
}

@media (max-width: 700px) {
  nav {
    padding: 1rem 1.5rem;
  }
  .nav-links {
    display: none;
  }
  .demo-section {
    flex-direction: column;
    align-items: center;
    gap: 3rem;
  }
  .modal-card {
    padding: 1.6rem;
  }
}