
#referenceHero {
  --dark: #0A1018;
  --navy: #0D1B2E;
  --gold: #FFB627;
  --cyan: #35D0EE;
  --green: #3EE08F;
  --magenta: #F45FC0;
  --indigo: #4B3FD6;
  --petrol: #0E6E8C;
  --moss: #3F7C33;
  --plum: #7D2E7A;
  --blue: #4B3FD6;
  --teal: #35D0EE;
  --white: #FFFFFF;
  --grey: #C8D2DD;
  --active-base: #FFB627;
  --active-ink: #0A1018;
  --active-accent: #4B3FD6;
  --active-logo: #FFB627;
  --nav-h: 76px;
  min-width: 320px;
  color: var(--white);
  font-family: Inter, ui-sans-serif, -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif;
}
#referenceHero *, #referenceHero *::before, #referenceHero *::after { box-sizing: border-box; }
#referenceHero button, #referenceHero a { font-family: inherit; }
#referenceHero button { color: inherit; }

/* Keep production header/logo, using the exact active slide color system. */
header { min-height: 76px; padding: 1rem 3rem; background: rgba(10,16,24,.88); border-bottom: 1px solid rgba(255,255,255,.12); backdrop-filter: blur(18px) saturate(130%); }
header .logo { position: relative; color: var(--active-logo, #FFB627); }
header .logo-img { width: auto; height: 32px; max-width: min(46vw, 220px); opacity: 0; filter: none; }
header .logo::before { content: ""; position: absolute; inset: 0; width: 100%; height: 100%; background: currentColor; -webkit-mask: url("/assets/brand/TapSocial_Wordmark@0.5x.png") left center / contain no-repeat; mask: url("/assets/brand/TapSocial_Wordmark@0.5x.png") left center / contain no-repeat; filter: drop-shadow(0 0 8px color-mix(in srgb, currentColor 28%, transparent)); }
.header-actions { display: flex; align-items: center; gap: 10px; }
header .pause { min-width: 64px; border: 1px solid rgba(255,255,255,.18); border-radius: 14px; padding: 10px 14px; color: #fff; background: rgba(255,255,255,.06); font-size: 11px; font-weight: 700; letter-spacing: .08em; text-transform: uppercase; cursor: pointer; }
header .pause:hover { border-color: rgba(255,255,255,.48); background: rgba(255,255,255,.10); }

/* The first-run consent banner owns the bottom layer. Keep carousel navigation in
   its normal position so the fixed banner paints over it instead of lifting it
   into the hero artwork. */
@media (max-width: 720px) {
  header { min-height: 60px; padding: 10px 14px; }
  header .logo-img { height: 26px; max-width: 47vw; }
  header .header-cta { display: none; }
  header .pause { min-width: 0; padding: 8px 10px; }
}
@media (max-height: 720px) and (min-width: 721px) {
  .cookie-visible #referenceHero .hero-copy { transform: translateY(-64%); }
}

.hero { position: relative; width: 100%; height: 100svh; overflow: hidden; background: var(--dark); }
.slides { width: 100%; height: 100%; }
.hero-slide {
  position: absolute;
  inset: 0;
  isolation: isolate;
  overflow: hidden;
  opacity: 0;
  visibility: hidden;
  transform: scale(1.02);
  transition: opacity .9s cubic-bezier(.22,.61,.36,1), transform 1.15s cubic-bezier(.22,.61,.36,1), visibility 0s linear .9s;
  background: var(--slide-bg);
  color: var(--slide-ink);
}
.hero-slide.active {
  opacity: 1;
  visibility: visible;
  transform: scale(1);
  transition-delay: 0s;
}
.hero-slide::before {
  content: "";
  position: absolute;
  inset: 0;
  z-index: -2;
  background: var(--slide-field);
}
.hero-slide::after {
  content: "";
  position: absolute;
  inset: 0;
  z-index: -1;
  pointer-events: none;
  background:
    linear-gradient(90deg, var(--copy-shade) 0%, color-mix(in srgb, var(--copy-shade) 82%, transparent) 34%, transparent 64%),
    linear-gradient(180deg, transparent 54%, color-mix(in srgb, var(--slide-bg) 44%, transparent) 100%);
}

.hero-background-film {
  position: absolute;
  inset: 0;
  z-index: -1;
  width: 100%;
  height: 100%;
  object-fit: cover;
  object-position: center center;
  background: #0A1018;
  pointer-events: none;
}
.has-background-film::after {
  z-index: 1;
  background:
    linear-gradient(90deg, #0A1018 0%, rgba(10,16,24,.92) 30%, rgba(10,16,24,.42) 55%, rgba(10,16,24,.08) 76%),
    linear-gradient(180deg, rgba(10,16,24,.18) 0%, transparent 48%, rgba(10,16,24,.48) 100%);
}
.has-background-film .motion-canvas { display: none; }

.slide-lead {
  --slide-bg: #0D1B2E;
  --slide-ink: #FFFFFF;
  --slide-muted: rgba(255,255,255,.69);
  --copy-shade: #0D1B2E;
  --accent: #4B3FD6;
  --button-bg: #FFFFFF;
  --button-ink: #0A1018;
  --slide-field: linear-gradient(135deg, #0D1B2E 0%, #16224E 55%, #4B3FD6 125%);
}
.slide-value {
  --slide-bg: #35D0EE;
  --slide-ink: #0A1018;
  --slide-muted: rgba(10,16,24,.68);
  --copy-shade: #35D0EE;
  --accent: #0A1018;
  --button-bg: #0A1018;
  --button-ink: #FFFFFF;
  --slide-field:
    radial-gradient(circle at 77% 28%, rgba(255,255,255,.88), transparent 22%),
    linear-gradient(128deg, #35D0EE 2%, #35D0EE 42%, #4B3FD6 100%);
}
.slide-platforms {
  --slide-bg: #F5F6F8;
  --slide-ink: #0A1018;
  --slide-muted: rgba(10,16,24,.64);
  --copy-shade: #F5F6F8;
  --accent: #4B3FD6;
  --button-bg: #0A1018;
  --button-ink: #FFFFFF;
  --slide-field:
    radial-gradient(circle at 72% 38%, rgba(144,255,233,.84), transparent 17%),
    radial-gradient(circle at 89% 30%, rgba(79,143,255,.88), transparent 29%),
    linear-gradient(112deg, #FFFFFF 0%, #F5F6F8 50%, #dfeaff 100%);
}
.slide-precision {
  --slide-bg: #0D1B2E;
  --slide-ink: #FFFFFF;
  --slide-muted: rgba(255,255,255,.70);
  --copy-shade: #0D1B2E;
  --accent: #35D0EE;
  --button-bg: #35D0EE;
  --button-ink: #0A1018;
  --slide-field:
    radial-gradient(circle at 79% 48%, rgba(144,255,233,.32), transparent 8%),
    radial-gradient(circle at 79% 48%, rgba(79,143,255,.26), transparent 30%),
    linear-gradient(105deg, #0D1B2E 25%, #0E6E8C 65%, #4B3FD6 140%);
}
.slide-agentic {
  --slide-bg: #0A1018;
  --slide-ink: #FFFFFF;
  --slide-muted: rgba(255,255,255,.69);
  --copy-shade: #0A1018;
  --accent: #4B3FD6;
  --button-bg: #FFFFFF;
  --button-ink: #0A1018;
  --slide-field:
    radial-gradient(circle at 78% 48%, rgba(144,255,233,.28), transparent 17%),
    radial-gradient(circle at 88% 20%, rgba(79,143,255,.44), transparent 35%),
    linear-gradient(118deg, #050a11 15%, #0A1018 48%, #0D1B2E 72%, #4B3FD6 140%);
}

.motion-canvas { position: absolute; inset: 0; width: 100%; height: 100%; z-index: 1; pointer-events:none; filter: var(--canvas-filter,none); transition: filter .3s; }
.slide-precision.active a,
.slide-precision.active button { cursor: pointer; }
.game-status {
  position: absolute;
  width: 1px;
  height: 1px;
  padding: 0;
  margin: -1px;
  overflow: hidden;
  clip: rect(0, 0, 0, 0);
  white-space: nowrap;
  border: 0;
}
.hero-copy {
  position: absolute;
  z-index: 2;
  left: clamp(22px, 7vw, 112px);
  top: 50%;
  width: min(760px, 58vw);
  transform: translateY(-47%);
}
.kicker {
  display: flex;
  align-items: center;
  gap: 10px;
  margin: 0 0 22px;
  color: var(--accent);
  text-transform: uppercase;
  font-size: 11px;
  font-weight: 800;
  letter-spacing: .24em;
}
.kicker-spark {
  flex: none;
  width: 12px;
  height: 12px;
  background: var(--accent);
  clip-path: polygon(50% 0, 61% 36%, 100% 50%, 61% 64%, 50% 100%, 39% 64%, 0 50%, 39% 36%);
}
.hero-copy h2 {
  max-width: 760px;
  margin: 0;
  text-wrap: balance;
  font-family: 'Bakbak One', Inter, sans-serif;
  font-size: clamp(56px, 7.4vw, 126px);
  line-height: .86;
  letter-spacing: -.052em;
  text-transform: uppercase;
  font-weight: 400;
}
.hero-copy h2 span { display: block; }
.hero-title-mobile { display: none; }
.slide-lead .hero-copy { width: min(920px, 56vw); }
.slide-lead .hero-copy h2 { max-width: 920px; font-size: clamp(52px, 5.2vw, 88px); }
.hero-copy p {
  max-width: 600px;
  margin: 28px 0 0;
  color: var(--slide-muted);
  font-size: clamp(15px, 1.35vw, 19px);
  line-height: 1.62;
}
.hero-progress {
  position: absolute;
  z-index: 10;
  left: 0;
  right: 0;
  bottom: 86px;
  height: 2px;
  background: rgba(255,255,255,.12);
}
.hero-progress span { display: block; width: 0; height: 100%; background: linear-gradient(90deg, var(--active-base), var(--active-accent)); }
.hero-controls {
  position: absolute;
  z-index: 12;
  inset: auto 0 0;
  height: 86px;
  display: grid;
  grid-template-columns: minmax(0, 1fr);
  align-items: stretch;
  gap: 0;
  padding: 0 0 0 clamp(20px, 4vw, 64px);
  border-top: 0;
  background: rgba(5,10,17,.94);
  backdrop-filter: blur(18px) saturate(132%);
  color: #FFFFFF;
}
.message-nav {
  display: grid;
  grid-template-columns: repeat(5, minmax(0, 1fr));
  align-items: stretch;
  min-width: 0;
}
#referenceHero .message-nav button {
  position: relative;
  display: flex;
  flex-direction: column;
  align-items: flex-start;
  justify-content: center;
  border: 0;
  padding: 0 clamp(10px, 1.3vw, 22px);
  color: rgba(255,255,255,.46);
  background: transparent;
  text-align: left;
  cursor: pointer;
  text-transform: uppercase;
  font-size: clamp(14px, 1.17vw, 18px);
  font-weight: 650;
  line-height: 1.08;
  letter-spacing: .035em;
  min-width: 0;
}
.message-nav button + button {
  border-left: 1px solid rgba(255,255,255,.08);
}
.message-nav button span {
  display: block;
  overflow: hidden;
  white-space: nowrap;
  text-overflow: ellipsis;
}
#referenceHero .message-nav button.active {
  color: #FFFFFF;
  font-weight: 800;
}
@media (max-width: 1180px) {
  .message-nav button { padding-inline: 4px; font-size: 12px; }
}

@media (max-width: 980px) {
  .hero-copy { width: min(720px, 72vw); }
  .message-nav { display: flex; gap: 5px; align-items: center; justify-content: center; }
  .message-nav button,
  .message-nav button.active { width: 22px; height: 22px; padding: 0; overflow: hidden; color: transparent; text-indent: -999px; }
  .message-nav button span { display: none; }
  .message-nav button::before { content: ""; position: absolute; display: block; left: 8px; top: 8px; width: 6px; height: 6px; border-radius: 50%; background: rgba(255,255,255,.22); }
  .message-nav button.active::before { background: var(--active-base); }
}

@media (max-width: 720px) {
  #referenceHero { --nav-h: 60px; }
  .hero-slide::after {
    background:
      linear-gradient(180deg, var(--copy-shade) 0%, color-mix(in srgb, var(--copy-shade) 94%, transparent) 42%, color-mix(in srgb, var(--copy-shade) 40%, transparent) 64%, transparent 78%),
      linear-gradient(90deg, color-mix(in srgb, var(--copy-shade) 42%, transparent) 0%, transparent 76%);
  }
  .hero-background-film { object-position: 72% center; }
  .has-background-film::after {
    background:
      linear-gradient(180deg, #0A1018 0%, rgba(10,16,24,.94) 39%, rgba(10,16,24,.44) 65%, rgba(10,16,24,.12) 78%),
      linear-gradient(90deg, rgba(10,16,24,.60) 0%, transparent 78%);
  }
  .hero-copy {
    top: calc(var(--nav-h) + 34px);
    left: 18px;
    right: 18px;
    bottom: auto;
    width: auto;
    transform: none;
  }
  .hero-copy .kicker { margin-bottom: 12px; gap: 9px; font-size: 11px; line-height: normal; letter-spacing: .2em; }
  .hero-copy .kicker-spark { width: 13px; height: 13px; }
  .hero-title-desktop { display: none; }
  .hero-title-mobile { display: block; }
  .hero-title-mobile span {
    /* Scale with the viewport (not capped at the 390px design) so the type fills the card. */
    /* Scale proportionally with the viewport: exact 390px design sizes at 390px,
       and they grow to fill wider phones (same fit ratio, so no overflow). */
    font-size: calc(var(--mobile-title-size) * (100vw / 390));
    line-height: .92;
    letter-spacing: -.045em;
    white-space: nowrap;
  }
  .slide-lead .hero-copy { width: auto; }
  .hero-copy p { margin-top: 14px; max-width: 100%; font-size: 16px; line-height: 1.5; }
  .hero-progress { bottom: 64px; }
  .hero-controls { height: 64px; grid-template-columns: minmax(0, 1fr); gap: 0; padding-left: 14px; }
}

@media (max-width: 720px) and (max-height: 740px) {
  .hero-copy { top: calc(var(--nav-h) + 22px); }
  .kicker { margin-bottom: 12px; }
  .hero-title-mobile span { font-size: calc(var(--mobile-title-size) * min(.94px, 100vw / 390)); }
  .hero-copy p { margin-top: 12px; font-size: 14px; line-height: 1.45; }
}

@media (max-width: 720px) and (max-height: 500px) and (orientation: landscape) {
  .slide-precision .hero-copy {
    top: 82px;
    right: auto;
    width: 47%;
  }
  .slide-precision .kicker { margin-bottom: 7px; font-size: 8px; }
  .slide-precision .hero-copy h2 { font-size: clamp(27px, 6.2vw, 35px); line-height: .88; }
  .slide-precision .hero-copy p { display: none; }
  .cookie-visible #referenceHero .hero-controls,
  .cookie-visible #referenceHero .hero-progress { opacity: 0; pointer-events: none; }
}

@media (max-height: 720px) and (min-width: 721px) {
  .hero-copy { transform: translateY(-52%); }
  .hero-copy h2 { font-size: clamp(54px, 6.7vw, 88px); }
  .hero-copy p { margin-top: 18px; font-size: 15px; line-height: 1.5; }
}

@media (prefers-reduced-motion: reduce) and (min-width:100000px) {
  .hero-slide { transition: none; transform: none; }
}
