/* H.O.T-Jarvis landing page. Same instrument language as the app: near-black
   steel, hairlines, tiny uppercase mono labels, one glowing element (the core).
   Static site, no framework — fast load is the premium signal. */

:root {
  --font-ui: "Segoe UI Variable", "Segoe UI", system-ui, -apple-system, sans-serif;
  --font-mono: "Cascadia Code", "SF Mono", Consolas, monospace;
  --bg: #04070d;
  --bg-2: #060b15;
  --panel: rgba(129, 180, 219, 0.05);
  --line: rgba(129, 190, 232, 0.16);
  --line-strong: rgba(129, 190, 232, 0.34);
  --text: #d9e7f2;
  --text-dim: #64788f;
  --accent: #38c6f4;
  --accent-2: #56dfb4;
  --accent-ink: #02171f;
  --accent-glow: rgba(56, 198, 244, 0.4);
  --maxw: 1140px;
  --ease: cubic-bezier(0.16, 1, 0.3, 1);
}

* {
  box-sizing: border-box;
}

html {
  scroll-behavior: smooth;
}

body {
  margin: 0;
  font-family: var(--font-ui);
  color: var(--text);
  background:
    radial-gradient(1200px 700px at 50% -5%, rgba(38, 142, 191, 0.1), transparent 60%),
    var(--bg);
  overflow-x: hidden;
  line-height: 1.6;
}

a {
  color: inherit;
}

/* ---- reserved video slots: poster is real premium art until a clip lands ---- */
.video-slot {
  position: relative;
  overflow: hidden;
  border-radius: 14px;
  background: var(--bg-2);
}

.video-slot .poster,
.video-slot video {
  display: block;
  width: 100%;
  height: 100%;
  object-fit: cover;
}

.slot-note {
  position: absolute;
  bottom: 10px;
  left: 12px;
  font-family: var(--font-mono);
  font-size: 9px;
  letter-spacing: 0.16em;
  text-transform: uppercase;
  color: var(--text-dim);
  background: rgba(4, 7, 13, 0.6);
  padding: 3px 8px;
  border-radius: 999px;
  backdrop-filter: blur(4px);
}

/* ==================== HERO ==================== */
.hero {
  position: relative;
  min-height: 100svh;
  display: grid;
  place-items: center;
  text-align: center;
  padding: 6vh 24px;
  isolation: isolate;
}

.hero-bg {
  position: absolute;
  inset: 0;
  border-radius: 0;
  z-index: -2;
  opacity: 0.5;
}

.hero-bg .poster {
  height: 100%;
}

/* GPU core. Sits where the 2D core sits; only becomes visible once
   webgl-core.js confirms it rendered a frame (html.has-webgl). */
.hero-webgl {
  position: absolute;
  z-index: -1;
  width: min(760px, 96vw);
  height: min(760px, 96vw);
  top: 50%;
  left: 50%;
  transform: translate(-50%, -50%);
  opacity: 0;
  transition: opacity 900ms cubic-bezier(0.2, 0.8, 0.2, 1);
  pointer-events: none;
}

.has-webgl .hero-webgl {
  opacity: 1;
}

/* Only one core at a time: the 2D one is the fallback, so it steps aside. */
.has-webgl .hero-core {
  opacity: 0;
}

/* The GPU core is bright enough on its own; dim the video backdrop so the
   headline keeps its contrast. */
.has-webgl .hero-bg {
  opacity: 0.28;
}

.hero-core {
  position: absolute;
  z-index: -1;
  transition: opacity 700ms ease;
  width: min(560px, 82vw);
  height: min(560px, 82vw);
  top: 50%;
  left: 50%;
  transform: translate(-50%, -52%);
  opacity: 0.9;
  pointer-events: none;
}

.hero-copy {
  max-width: 720px;
}

.eyebrow {
  font-family: var(--font-mono);
  font-size: 11px;
  letter-spacing: 0.28em;
  text-transform: uppercase;
  color: var(--text-dim);
  margin: 0 0 20px;
}

.hero h1 {
  font-size: clamp(34px, 6vw, 66px);
  line-height: 1.04;
  font-weight: 600;
  letter-spacing: -0.02em;
  margin: 0 0 22px;
}

.grad {
  background: linear-gradient(120deg, var(--accent), var(--accent-2));
  -webkit-background-clip: text;
  background-clip: text;
  color: transparent;
}

.lede {
  font-size: clamp(15px, 2vw, 19px);
  color: #aebbcd;
  max-width: 620px;
  margin: 0 auto 32px;
}

.cta-row {
  display: flex;
  gap: 14px;
  justify-content: center;
  flex-wrap: wrap;
}

.cta-row.center {
  margin-top: 28px;
}

.btn {
  display: inline-block;
  padding: 13px 26px;
  border-radius: 10px;
  font-family: var(--font-mono);
  font-size: 12px;
  letter-spacing: 0.14em;
  text-transform: uppercase;
  text-decoration: none;
  transition: transform 0.15s var(--ease), box-shadow 0.15s var(--ease), background 0.15s var(--ease);
}

.btn.primary {
  background: var(--accent);
  color: var(--accent-ink);
  font-weight: 650;
}

.btn.primary:hover {
  box-shadow: 0 0 26px var(--accent-glow);
  transform: translateY(-1px);
}

.btn.ghost {
  border: 1px solid var(--line-strong);
  color: var(--text);
}

.btn.ghost:hover {
  border-color: var(--accent);
  color: var(--accent);
}

.trust-line {
  margin-top: 22px;
  font-family: var(--font-mono);
  font-size: 11px;
  letter-spacing: 0.1em;
  color: var(--text-dim);
}

.scroll-hint {
  position: absolute;
  bottom: 26px;
  left: 50%;
  transform: translateX(-50%);
  font-family: var(--font-mono);
  font-size: 9px;
  letter-spacing: 0.3em;
  text-transform: uppercase;
  color: var(--text-dim);
  animation: bob 2.4s ease-in-out infinite;
}

@keyframes bob {
  0%, 100% { transform: translateX(-50%) translateY(0); opacity: 0.5; }
  50% { transform: translateX(-50%) translateY(6px); opacity: 1; }
}

/* ==================== SHOWCASE SECTIONS ==================== */
.showcase {
  max-width: var(--maxw);
  margin: 0 auto;
  padding: clamp(70px, 12vh, 150px) 24px;
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: clamp(28px, 5vw, 72px);
  align-items: center;
}

.showcase.flagship {
  border-top: 1px solid var(--line);
}

.showcase-text h2 {
  font-size: clamp(26px, 3.4vw, 40px);
  line-height: 1.1;
  letter-spacing: -0.015em;
  margin: 14px 0 18px;
}

.showcase-text p {
  color: #a4b2c4;
  font-size: 16px;
  max-width: 42ch;
}

.showcase-text em {
  color: var(--text);
  font-style: normal;
  font-weight: 600;
}

.section-index {
  font-family: var(--font-mono);
  font-size: 12px;
  letter-spacing: 0.2em;
  color: var(--accent);
}

/* aspect ratios per slot type */
.video-slot.cinema {
  aspect-ratio: 16 / 9;
  border: 1px solid var(--line);
  box-shadow: 0 30px 80px rgba(0, 2, 8, 0.6);
}

.video-slot.loop {
  aspect-ratio: 4 / 3;
  border: 1px solid var(--line);
}

/* ==================== CLOSE ==================== */
.close {
  max-width: 720px;
  margin: 0 auto;
  padding: clamp(80px, 14vh, 170px) 24px;
  text-align: center;
}

.close h2 {
  font-size: clamp(28px, 4vw, 48px);
  letter-spacing: -0.02em;
  margin: 0 0 18px;
}

.close p {
  color: #a4b2c4;
  font-size: 17px;
  max-width: 56ch;
  margin: 0 auto;
}

.foot {
  max-width: var(--maxw);
  margin: 0 auto;
  padding: 30px 24px 50px;
  border-top: 1px solid var(--line);
  display: flex;
  justify-content: space-between;
  font-family: var(--font-mono);
  font-size: 11px;
  letter-spacing: 0.14em;
  text-transform: uppercase;
}

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

/* ==================== SCROLL REVEAL ==================== */
.reveal {
  opacity: 0;
  transform: translateY(26px);
  transition: opacity 0.7s var(--ease), transform 0.7s var(--ease);
  will-change: opacity, transform;
}

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

/* ==================== RESPONSIVE ==================== */
@media (max-width: 820px) {
  .showcase {
    grid-template-columns: 1fr;
  }
  /* keep image above text on alternating rows for a natural read order */
  .showcase.alt .video-slot {
    order: -1;
  }
}

/* ==================== ACCESSIBILITY: reduced motion ==================== */
@media (prefers-reduced-motion: reduce) {
  html {
    scroll-behavior: auto;
  }
  .reveal {
    opacity: 1;
    transform: none;
    transition: none;
  }
  .scroll-hint {
    animation: none;
  }
  /* video is never loaded under reduced motion — reveal.js honors this too */
}
