/* ─── GK & SZS Pitch Deck · FML × QIC ───────────────────────────────
   Cold-neon palette (cyan + neon green) · custom display + body type.
   Layout system mirrors the Ducati deck; only accents + fonts differ. */

@font-face {
  font-family: "Asgrike";
  src: url("assets/fonts/Asgrike.ttf") format("truetype");
  font-weight: 100 900;
  font-display: swap;
}
@font-face {
  font-family: "Rinter";
  src: url("assets/fonts/Rinter.ttf") format("truetype");
  font-weight: 100 900;
  font-display: swap;
}
@font-face {
  font-family: "Nivra";
  src: url("assets/fonts/Nivra-Black.ttf") format("truetype");
  font-weight: 100 900;
  font-display: swap;
}
@font-face {
  font-family: "Neofolia";
  src: url("assets/fonts/Neofolia.ttf") format("truetype");
  font-weight: 100 900;
  font-display: swap;
}
@font-face {
  font-family: "Baunk";
  src: url("assets/fonts/Baunk.ttf") format("truetype");
  font-weight: 100 900;
  font-display: swap;
}

:root {
  /* Palette — Electric cyan + neon green + deep cold ink */
  --red:       #18C2E0;       /* primary accent (cyan) — keeps token name for layout reuse */
  --red-deep:  #0E8FA8;       /* deep cyan */
  --red-hot:   #3DE8A0;       /* neon green pop */
  --accent:    #18C2E0;
  --accent-2:  #3DE8A0;
  --ink:       #0B0E10;       /* cold near-black */
  --ink-2:     #12171A;
  --ink-3:     #1B2227;
  --bone:      #EAF4F2;       /* cool off-white */
  --bone-2:    #D6E4E1;
  --paper:     #F2F8F6;
  --rule:      rgba(11,14,16,0.14);
  --rule-dark: rgba(234,244,242,0.16);
  --muted:     rgba(11,14,16,0.55);
  --muted-d:   rgba(234,244,242,0.6);

  /* Type — Nivra display + Rinter body & micro-labels */
  --f-display: "Nivra", "Syne", system-ui, sans-serif;    /* display */
  --f-motor:   "Bebas Neue", "Anton", Impact, sans-serif;             /* big numerals / labels */
  --f-body:    "Rinter", "Space Grotesk", system-ui, sans-serif;
  --f-mono:    "Rinter", "Space Mono", "JetBrains Mono", ui-monospace, monospace;

  /* Scale — 1920x1080 */
  --title: 64px;
  --subtitle: 44px;
  --body: 34px;
  --small: 28px;
  --micro: 22px;
}

* { box-sizing: border-box; }

html, body {
  margin: 0;
  padding: 0;
  background: var(--ink);
  font-family: var(--f-body);
  color: var(--ink);
  -webkit-font-smoothing: antialiased;
  text-rendering: geometricPrecision;
}

/* Slides — every <section> inside <deck-stage> */
deck-stage section {
  display: flex;
  flex-direction: column;
  background: var(--bone);
  color: var(--ink);
  overflow: hidden;
}

/* ─── Typography primitives ─────────────────────────────────────────── */

.eyebrow {
  font-family: var(--f-mono);
  font-size: var(--micro);
  letter-spacing: 0.2em;
  text-transform: uppercase;
  font-weight: 400;
  opacity: 0.72;
}

.display {
  font-family: var(--f-display);
  font-weight: 700;
  letter-spacing: -0.02em;
  line-height: 0.96;
  font-style: normal;
  text-wrap: balance;
}

.display em, .display .it {
  font-style: italic;
  font-weight: 800;
  color: var(--accent);
}

.motor {
  font-family: var(--f-motor);
  text-transform: uppercase;
  letter-spacing: 0.02em;
  line-height: 0.86;
  font-weight: 400;
}

.mono {
  font-family: var(--f-mono);
  letter-spacing: 0.02em;
}

/* ─── Frame: running header + footer on every slide ─────────────────── */

.frame-top, .frame-bottom {
  position: absolute;
  left: 0; right: 0;
  padding: 0 64px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  font-family: var(--f-mono);
  font-size: 16px;
  letter-spacing: 0.14em;
  text-transform: uppercase;
  opacity: 0.55;
  z-index: 5;
  pointer-events: none;
}
.frame-top { top: 40px; }
.frame-bottom { bottom: 40px; }
.frame-top .dot, .frame-bottom .dot {
  width: 8px; height: 8px; border-radius: 50%; background: var(--accent);
  display: inline-block; margin: 0 10px 1px;
}

/* ─── Image / asset placeholders ────────────────────────────────────── */

.ph {
  position: relative;
  background:
    repeating-linear-gradient(135deg,
      rgba(11,14,16,0.04) 0 10px,
      rgba(11,14,16,0) 10px 22px),
    var(--bone-2);
  border: 1px solid var(--rule);
  color: var(--ink);
  display: flex;
  align-items: flex-end;
  overflow: hidden;
}
.ph.dark {
  background:
    repeating-linear-gradient(135deg,
      rgba(234,244,242,0.05) 0 10px,
      rgba(234,244,242,0) 10px 22px),
    var(--ink-2);
  border-color: var(--rule-dark);
  color: var(--bone);
}
.ph.red {
  background:
    repeating-linear-gradient(135deg,
      rgba(255,255,255,0.08) 0 10px,
      rgba(255,255,255,0) 10px 22px),
    var(--red-deep);
  border-color: rgba(255,255,255,0.12);
  color: var(--ink);
}
.ph > .ph-label {
  font-family: var(--f-mono);
  font-size: 14px;
  display: none;
  letter-spacing: 0.14em;
  text-transform: uppercase;
  padding: 14px 18px;
  opacity: 0.78;
}
.ph > .ph-corner { display: none; }

/* Logo tile placeholder */
.logo-tile {
  border: 1px solid var(--rule);
  background: var(--paper);
  aspect-ratio: 3 / 2;
  display: flex; align-items: center; justify-content: center;
  font-family: var(--f-mono); font-size: 14px;
  letter-spacing: 0.16em; text-transform: uppercase;
  color: var(--muted);
  position: relative;
}
.logo-tile::before {
  content: ""; position: absolute; inset: 0;
  background: repeating-linear-gradient(135deg,
    rgba(11,14,16,0.035) 0 6px,
    rgba(11,14,16,0) 6px 14px);
  pointer-events: none;
}
.logo-tile.dark {
  background: var(--ink-2);
  border-color: var(--rule-dark);
  color: var(--muted-d);
}
.logo-tile.dark::before {
  background: repeating-linear-gradient(135deg,
    rgba(234,244,242,0.05) 0 6px,
    rgba(234,244,242,0) 6px 14px);
}
.logo-tile .label { position: relative; z-index: 1; padding: 0 12px; text-align: center; text-wrap: balance;}

.logo-tile.filled {
  overflow: hidden;
  background: var(--ink);
  border: none;
}
.logo-tile.filled::before {
  content: ""; position: absolute; inset: 0;
  background: rgba(11,14,16,0.55);
  z-index: 1;
}
.logo-tile.filled > img {
  position: absolute; inset: 0;
  width: 100%; height: 100%;
  object-fit: cover;
  z-index: 0;
}
.logo-tile.filled .label {
  color: var(--bone);
  text-shadow: 0 2px 10px rgba(0,0,0,0.7);
  z-index: 2;
}

/* ─── Section dividers — full-bleed accent ──────────────────────────── */

.section-divider {
  background: var(--ink);
  color: var(--bone);
  position: relative;
}
.section-divider .frame-top,
.section-divider .frame-bottom {
  color: var(--bone);
  opacity: 0.7;
}
.section-divider .frame-top .dot,
.section-divider .frame-bottom .dot {
  background: var(--accent);
}

/* ─── Dark slide shell ──────────────────────────────────────────────── */
.dark-slide {
  background: var(--ink);
  color: var(--bone);
}
.dark-slide .frame-top, .dark-slide .frame-bottom {
  color: var(--bone);
  opacity: 0.5;
}

/* Bone slide */
.bone-slide { background: var(--bone); color: var(--ink); }
.paper-slide { background: var(--paper); color: var(--ink); }

/* ─── Small utilities ───────────────────────────────────────────────── */
.rule { height: 1px; background: currentColor; opacity: 0.18; }
.rule-v { width: 1px; background: currentColor; opacity: 0.18; }

.redline {
  width: 72px; height: 4px; background: var(--accent); border-radius: 2px;
  display: inline-block;
}

.chip {
  display: inline-flex; align-items: center; gap: 10px;
  padding: 10px 18px;
  border: 1px solid currentColor;
  border-radius: 999px;
  font-family: var(--f-mono);
  font-size: 18px;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  opacity: 0.9;
}

/* ─── Animation primitives ─────────────────────────────────────────── */
@keyframes slideInUp { from { transform: translateY(40px); opacity: 0; } to { transform: translateY(0); opacity: 1; } }
@keyframes slideInLeft { from { transform: translateX(-60px); opacity: 0; } to { transform: translateX(0); opacity: 1; } }
@keyframes slideInRight { from { transform: translateX(60px); opacity: 0; } to { transform: translateX(0); opacity: 1; } }
@keyframes fadeIn { from { opacity: 0; } to { opacity: 1; } }
@keyframes marquee { from { transform: translateX(0); } to { transform: translateX(-50%); } }
@keyframes pulseDot { 0%, 100% { transform: scale(1); opacity: 1; } 50% { transform: scale(1.35); opacity: 0.6; } }
@keyframes arcDraw { to { stroke-dashoffset: 0; } }
@keyframes growWidth { from { transform: scaleX(0); } to { transform: scaleX(1); } }

/* glow pulse for neon accents */
@keyframes neonPulse {
  0%, 100% { opacity: 1; filter: drop-shadow(0 0 6px rgba(24,194,224,0.5)); }
  50%      { opacity: 0.75; filter: drop-shadow(0 0 14px rgba(24,194,224,0.85)); }
}

deck-stage section[data-deck-active] .anim-up     { animation: slideInUp 0.9s cubic-bezier(.22,.8,.2,1) both; }
deck-stage section[data-deck-active] .anim-left   { animation: slideInLeft 0.9s cubic-bezier(.22,.8,.2,1) both; }
deck-stage section[data-deck-active] .anim-right  { animation: slideInRight 0.9s cubic-bezier(.22,.8,.2,1) both; }
deck-stage section[data-deck-active] .anim-fade   { animation: fadeIn 1.2s ease both; }

deck-stage section:not([data-deck-active]) .anim-up,
deck-stage section:not([data-deck-active]) .anim-left,
deck-stage section:not([data-deck-active]) .anim-right,
deck-stage section:not([data-deck-active]) .anim-fade { opacity: 0; }

@media print {
  deck-stage section .anim-up,
  deck-stage section .anim-left,
  deck-stage section .anim-right,
  deck-stage section .anim-fade,
  deck-stage section:not([data-deck-active]) .anim-up,
  deck-stage section:not([data-deck-active]) .anim-left,
  deck-stage section:not([data-deck-active]) .anim-right,
  deck-stage section:not([data-deck-active]) .anim-fade {
    animation: none !important; opacity: 1 !important; transform: none !important;
  }
  .redbar-grow, deck-stage section[data-deck-active] .redbar-grow {
    animation: none !important; transform: scaleX(1) !important;
  }
  .marquee { animation: none !important; }
  [stroke-dashoffset] { stroke-dashoffset: 0 !important; }
  *, *::before, *::after { animation-delay: 0s !important; animation-duration: 0s !important; transition: none !important; }
}

/* stagger helpers */
.d1 { animation-delay: 0.08s !important; }
.d2 { animation-delay: 0.18s !important; }
.d3 { animation-delay: 0.30s !important; }
.d4 { animation-delay: 0.44s !important; }
.d5 { animation-delay: 0.60s !important; }
.d6 { animation-delay: 0.78s !important; }
.d7 { animation-delay: 0.96s !important; }
.d8 { animation-delay: 1.14s !important; }
.d9 { animation-delay: 1.32s !important; }

.redbar {
  position: absolute; left: 0; right: 0; top: 0;
  height: 6px; background: var(--accent);
  transform-origin: left;
  animation: none;
}
deck-stage section[data-deck-active] .redbar-grow { animation: growWidth 1.1s cubic-bezier(.7,0,.2,1) both; }

.marquee {
  display: flex; gap: 80px;
  white-space: nowrap;
  animation: marquee 40s linear infinite;
  will-change: transform;
}

.mega-num {
  font-family: var(--f-motor);
  font-size: 780px;
  line-height: 0.8;
  letter-spacing: -0.04em;
  color: var(--bone);
  opacity: 0.12;
}

/* ─── Deck-wide tech trim · interrupted corner brackets ──────────────
   Two L-shaped brackets (top-left + bottom-right) instead of a closed
   square, so the frame is never solid around the content. currentColor
   keeps it theme-aware; sits behind content at low opacity. */
deck-stage section::before {
  content: ""; position: absolute; z-index: 0; pointer-events: none;
  left: 34px; top: 34px; width: 120px; height: 120px;
  border-left: 1px solid currentColor; border-top: 1px solid currentColor;
  opacity: 0.16;
}
deck-stage section::after {
  content: ""; position: absolute; z-index: 0; pointer-events: none;
  right: 34px; bottom: 34px; width: 120px; height: 120px;
  border-right: 1px solid currentColor; border-bottom: 1px solid currentColor;
  opacity: 0.16;
}
/* full-bleed hero slides: keep trims off the imagery */
deck-stage section.section-divider::before,
deck-stage section.section-divider::after { opacity: 0.28; }

/* faint engineering grid + accent glow on divider slides */
deck-stage section.section-divider {
  background-image:
    radial-gradient(ellipse at 78% 30%, color-mix(in srgb, var(--accent) 12%, transparent) 0%, rgba(0,0,0,0) 55%),
    repeating-linear-gradient(0deg, color-mix(in srgb, currentColor 6%, transparent) 0 1px, transparent 1px 88px),
    repeating-linear-gradient(90deg, color-mix(in srgb, currentColor 6%, transparent) 0 1px, transparent 1px 88px);
}

/* Tweaks: dark mode override */
body[data-theme="dark"] deck-stage section.bone-slide { background: var(--ink); color: var(--bone); }
body[data-theme="dark"] deck-stage section.paper-slide { background: var(--ink-2); color: var(--bone); }
body[data-theme="dark"] deck-stage section.bone-slide .ph:not(.dark):not(.red) {
  background:
    repeating-linear-gradient(135deg, rgba(234,244,242,0.05) 0 10px, rgba(234,244,242,0) 10px 22px),
    var(--ink-2);
  border-color: var(--rule-dark);
  color: var(--bone);
}

/* ─── Filled placeholders with imagery ───────────────────────────── */
.ph.filled { background: var(--ink); border-color: transparent; border: none; }
.ph.filled > img, .ph.filled > video { position: absolute; inset: 0; width: 100%; height: 100%; object-fit: cover; z-index: 0; }
.ph.filled > .ph-corner, .ph.filled > .ph-label { display: none; }
.ph.filled::after {
  content: ""; position: absolute; inset: 0; z-index: 1; pointer-events: none;
  background: linear-gradient(180deg, rgba(0,0,0,0) 40%, rgba(0,0,0,0.55) 100%);
}

/* Background hero image on dark slides */
.bg-hero { position: absolute; inset: 0; z-index: 0; overflow: hidden; pointer-events: none; }
.bg-hero img, .bg-hero video { width: 100%; height: 100%; object-fit: cover; opacity: 0.55; filter: saturate(0.9); }
.bg-hero.dim img, .bg-hero.dim video { opacity: 0.28; }
.bg-hero.edge::after {
  content: ""; position: absolute; inset: 0;
  background: linear-gradient(90deg, rgba(11,14,16,0.95) 0%, rgba(11,14,16,0.5) 50%, rgba(11,14,16,0.2) 100%);
}
.bg-hero.full::after {
  content: ""; position: absolute; inset: 0;
  background: radial-gradient(ellipse at 50% 50%, rgba(11,14,16,0.1) 0%, rgba(11,14,16,0.85) 100%);
}
.bg-hero.bottom::after {
  content: ""; position: absolute; inset: 0;
  background: linear-gradient(180deg, rgba(11,14,16,0.2) 0%, rgba(11,14,16,0.85) 70%, rgba(11,14,16,0.98) 100%);
}

/* Partner logo lockups */
.p-logo { display: inline-block; height: 44px; width: auto; object-fit: contain; vertical-align: middle; }
.p-logo.sm { height: 28px; }
.p-logo.lg { height: 64px; }
.p-logo.xl { height: 96px; }

/* ─── Scope→pillar matrix (slide 12B) ───────────────────────────────── */
.scope-matrix { width: 100%; border-collapse: collapse; }

/* ─── Neon-world accent helpers ─────────────────────────────────────── */
.neon-cyan { color: var(--accent); }
.neon-green { color: var(--accent-2); }
.glow { text-shadow: 0 0 18px color-mix(in srgb, var(--accent) 60%, transparent); }
.glow-green { text-shadow: 0 0 18px color-mix(in srgb, var(--accent-2) 55%, transparent); }

/* ─── Logo on every slide ───────────────────────────────────────────
   Default = full-bleed flame watermark sitting behind content.
   Sections flagged .logo-mark instead show a small white logo, bottom-center
   (used on animated-text pages where a watermark would clutter the reveal). */
.deck-logo {
  position: absolute;
  inset: 0;
  width: 100%; height: 100%;
  object-fit: cover; object-position: center;
  z-index: 0;
  pointer-events: none;
  filter: brightness(0);          /* black flame */
  opacity: 0.5;                   /* subtle on dark bg */
}
/* On light (bone/paper) slides the black flame must be far fainter */
.bone-slide .deck-logo,
.paper-slide .deck-logo { opacity: 0.06; }
/* Dark theme flips bone/paper slides dark → restore the darker watermark opacity */
body[data-theme="dark"] .bone-slide .deck-logo,
body[data-theme="dark"] .paper-slide .deck-logo { opacity: 0.5; }

/* Animated-text pages: small white logo, bottom-center, above content */
.logo-mark .deck-logo {
  inset: auto;
  left: 50%; bottom: 40px;
  transform: translateX(-50%);
  width: 64px; height: auto;
  object-fit: contain;
  z-index: 50;
  filter: brightness(0) invert(1) !important;   /* always white */
  opacity: 0.75 !important;
}

/* Per-slide page number · bottom-right corner, theme-aware */
.deck-pagenum {
  position: absolute;
  bottom: 40px; right: 44px;
  z-index: 45;
  font-family: var(--f-mono);
  font-size: 13px;
  letter-spacing: 0.16em;
  color: currentColor;
  opacity: 0.5;
  pointer-events: none;
}
