/* The package is built in a shared 3D context. Each suspended plate has its own position, face, and walls. */
.processor {
  --scene-x: 0;
  --scene-y: 0;
  --processor-size: min(64%, 17.5rem);
  position: relative;
  display: grid;
  place-items: center;
  min-width: 0;
  pointer-events: none;
  perspective: 820px;
  perspective-origin: 50% 47%;
}

.processor--hero {
  /* The chip holds one pose (Dylan 2026-11-24); every other cursor effect on the page is unchanged. */
  --scene-x: 0;
  --scene-y: 0;
  min-height: 21rem;
  grid-row: 2;
}

.processor--service {
  /* The chip holds one pose (Dylan 2026-11-24); every other cursor effect on the page is unchanged. */
  --scene-x: 0;
  --scene-y: 0;
  --processor-size: min(57%, 13.5rem);
  height: 17rem;
  margin: -1rem -1rem 0;
}

.processor__assembly,
.processor__layer {
  transform-style: preserve-3d;
}

.processor__assembly {
  position: relative;
  width: var(--processor-size);
  aspect-ratio: 1;
  transform: scale(var(--processor-scale, 1)) rotateX(calc(54deg - var(--scene-y) * 19deg))
    rotateY(calc(var(--scene-x) * 17deg))
    rotateZ(calc(-39deg + var(--scene-x) * 20deg));
}

.processor__layer {
  position: absolute;
  inset: var(--layer-inset);
  transform: translate3d(var(--layer-x), var(--layer-y), var(--layer-z));
}

.processor__layer--socket {
  --layer-inset: 0%;
  --layer-x: calc(var(--scene-x) * -14px);
  --layer-y: calc(var(--scene-y) * -12px);
  --layer-z: -57px;
  --wall-thickness: 20px;
  --face-base: #242425;
  --face-line: #6d6255;
  --wall-fill: linear-gradient(#3d3631, #161616);
}

.processor__layer--board {
  --layer-inset: 10%;
  --layer-x: calc(var(--scene-x) * 11px);
  --layer-y: calc(var(--scene-y) * 8px);
  --layer-z: calc(-4px + var(--scene-y) * -9px);
  --wall-thickness: 13px;
  --face-base: #312823;
  --face-line: #99734b;
  --wall-fill: linear-gradient(#74502b, #32241e);
}

.processor__layer--die {
  --layer-inset: 23%;
  --layer-x: calc(var(--scene-x) * 31px);
  --layer-y: calc(var(--scene-y) * 23px);
  --layer-z: calc(55px + var(--scene-y) * -18px);
  --wall-thickness: 16px;
  --face-base: #797068;
  --face-line: #c0ad8d;
  --wall-fill: linear-gradient(#777068, #34302c);
}

.processor__face {
  position: absolute;
  inset: 0;
  display: grid;
  place-items: center;
  background:
    radial-gradient(ellipse at calc(33% + var(--scene-x) * 31%) calc(22% + var(--scene-y) * 32%), rgba(255, 244, 223, .32), transparent 60%),
    linear-gradient(145deg, transparent 18%, rgba(0, 0, 0, .48)),
    var(--face-base);
  border: 1px solid var(--face-line);
  box-shadow: inset 0 0 0 3px rgba(0, 0, 0, .22), inset 0 1px rgba(255, 244, 223, .35);
  backface-visibility: hidden;
}

.processor__layer--socket .processor__face::before {
  content: "";
  position: absolute;
  inset: 5%;
  border: 1px solid #887157;
  background: radial-gradient(circle, #a58d69 0 14%, transparent 24%) center / 7% 7%, #1c1a18;
  box-shadow: inset 0 0 1rem #111;
}

.processor__layer--board .processor__face {
  background-color: #312823;
  box-shadow: inset 0 0 0 3px #211d1a, inset 0 0 1.25rem #221610;
}

.processor__traces {
  display: block;
  width: 94%;
  fill: none;
  stroke: #d3a364;
  stroke-width: 1.3;
  opacity: .82;
}

.processor__wall {
  position: absolute;
  background: var(--wall-fill);
  border-bottom: 1px solid #130f0e;
  box-shadow: inset 0 1px rgba(255, 244, 223, .34);
}

.processor__wall--front {
  inset: auto 0 0;
  height: var(--wall-thickness);
  transform-origin: center bottom;
  transform: rotateX(90deg);
}

.processor__wall--right {
  inset: 0 0 0 auto;
  width: var(--wall-thickness);
  transform-origin: center right;
  transform: rotateY(-90deg);
  background: linear-gradient(90deg, #181614, #625447);
}

.processor__layer--socket .processor__wall--front {
  background: repeating-linear-gradient(90deg, transparent 0 6px, #8b6b42 6px 8px, #302722 8px 10px), var(--wall-fill);
  border-top: 2px solid #574737;
}

.processor__layer--socket .processor__wall--right {
  background: repeating-linear-gradient(0deg, transparent 0 6px, #655034 6px 8px, #302722 8px 10px), linear-gradient(90deg, #1c1715, #46382a);
}

.processor__silicon {
  width: 63%;
  aspect-ratio: 1;
  border: 1px solid #f2bf65;
  background:
    repeating-linear-gradient(0deg, transparent 0 4px, rgba(60, 35, 17, .22) 4px 5px),
    repeating-linear-gradient(90deg, transparent 0 4px, rgba(60, 35, 17, .22) 4px 5px),
    linear-gradient(calc(132deg + var(--scene-x) * 45deg), #fff4df, #f2bf65 34%, #98703d 79%, #653825);
  box-shadow: 0 0 0 4px #292421, 0 0 0 5px #a2865d, 0 1.2rem 1.3rem -1rem #1b1009;
}

.processor__shadow {
  position: absolute;
  width: min(86%, 29rem);
  height: 24%;
  top: 69%;
  pointer-events: none;
  border-radius: 50%;
  background: radial-gradient(ellipse, #050403 0%, rgba(6, 5, 4, .73) 30%, transparent 72%);
  transform: translate(calc(var(--scene-x) * -34px), calc(var(--scene-y) * 8px))
    skewX(calc(-21deg - var(--scene-x) * 22deg));
}

.hero .hero__stage {
  display: grid;
  align-content: start;
  min-height: min(calc(100svh - var(--cts-layout-header)), 51rem);
  padding-top: clamp(5.5rem, 4rem + 3vw, 8rem);
}

.hero__stage > .hero__copy,
[data-intro] .hero__stage > .hero__copy {
  grid-row: 1;
  width: min(var(--cts-layout-wrap), 100% - 2 * var(--cts-layout-gutter));
  justify-items: center;
  align-content: center;
  padding: 0;
  text-align: center;
}

.hero__stage > .hero__copy > *,
[data-intro] .hero__stage > .hero__copy > * { max-width: 100%; }

.hero__stage > .hero__copy .cts-display,
[data-intro] .hero__stage > .hero__copy .cts-display {
  max-width: 100%;
  font-size: clamp(2.65rem, 5.9vw, 6rem);
  line-height: 1;
}

.hero__stage > .hero__copy .cts-lead { max-width: 41rem; }
.hero__stage > .hero__copy .hero__actions { justify-content: center; }
.hero__stage > .hero__copy .hero__cue { display: none; }
.hero .intro { opacity: .38; }
.hero .intro--circuit { bottom: 1rem; }
.service--lead .service__copy { margin-top: 0; }

@media (max-width: 899px) {
  .processor--hero {
    --processor-size: min(47%, 13.5rem);
    margin-top: 1rem;
  }

  .processor--service + .service__num { position: absolute; top: 1.5rem; }
  .hero__stage > .hero__copy .cts-display { text-wrap: balance; }
}

@media (max-width: 420px) {
  .hero .hero__stage { padding-top: 5rem; }
  .processor--hero { min-height: 17rem; }
  .processor--service { --processor-scale: .84; height: 14rem; }
}

@media (min-width: 900px) {
  .hero .hero__stage { align-content: center; }
  .hero__stage > .hero__copy,
  [data-intro] .hero__stage > .hero__copy {
    justify-items: start;
    text-align: start;
    padding-bottom: 3.5rem;
  }

  .hero__stage > .hero__copy > *,
  [data-intro] .hero__stage > .hero__copy > *,
  .hero__stage > .hero__copy .cts-display,
  [data-intro] .hero__stage > .hero__copy .cts-display {
    max-width: 53%;
  }

  .hero__stage > .hero__copy .hero__actions { justify-content: start; }
  .processor--hero {
    position: absolute;
    grid-row: auto;
    inset: 4rem max(2vw, calc((100% - 86rem) / 2)) 0 auto;
    width: min(48%, 44rem);
  }

  .processor--service {
    position: absolute;
    inset: 0 1% 0 auto;
    width: 48%;
    height: auto;
    margin: 0;
  }

  .service--lead .service__copy { max-width: 50%; }
}

@media (prefers-reduced-motion: no-preference) {
  .processor__assembly, .processor__layer, .processor__shadow {
    transition: transform 170ms ease-out;
  }
}

.processor--service { overflow: clip; }

.service__art-window {
  position: absolute;
  inset: 0 0 auto auto;
  width: 8.5rem;
  height: 5.25rem;
  overflow: clip;
  perspective: 22rem;
  pointer-events: none;
  z-index: -1;
}

.service__art-window > .cts-tile__art {
  width: 100%;
  height: auto;
  max-height: 100%;
}

@media (min-width: 720px) {
  .service:not(.service--home) .service__art-window { width: 13rem; height: 8rem; }
}

.service--home .service__art-window {
  width: 5.5rem;
  height: 4rem;
}

/* ============ The board (2026-11-24) ============
   The hero backdrop is the board the processor sits on. It lives inside .processor__assembly, so it shares the chip's
   exact 3D pose and its traces leave the socket's real edges. 3.4x the socket, faded to nothing at the edges. */
.processor__layer--field {
  --layer-inset: -120%;
  --layer-x: 0px;
  --layer-y: 0px;
  --layer-z: -62px;
  -webkit-mask-image: radial-gradient(closest-side, #000 34%, rgba(0, 0, 0, 0.5) 62%, transparent 100%);
  mask-image: radial-gradient(closest-side, #000 34%, rgba(0, 0, 0, 0.5) 62%, transparent 100%);
}
.board__svg { display: block; width: 100%; height: 100%; overflow: visible; }
.board__svg pattern circle { fill: rgba(255, 244, 223, 0.16); }
.board__keepout { fill: none; stroke: rgba(242, 191, 101, 0.28); stroke-width: 1.5; stroke-dasharray: 3 7; }
.board__bus path { fill: none; stroke: rgba(255, 244, 223, 0.1); stroke-width: 2; }
.board__traces path { fill: none; stroke: rgba(211, 163, 100, 0.42); stroke-width: 2.2; stroke-linecap: round; stroke-linejoin: round; }
.board__traces--gold path { stroke: #f2bf65; stroke-width: 2.6; }
.board__vias circle { fill: #1a1714; stroke: rgba(211, 163, 100, 0.6); stroke-width: 2; }
.board__vias--gold circle { fill: #f2bf65; stroke: none; }
@media (prefers-reduced-motion: no-preference) {
  .board__draw { stroke-dasharray: 1; stroke-dashoffset: 1; animation: board-draw 1.5s var(--cts-motion-ease-out, ease-out) 0.15s forwards; }
  .board__draw.d2 { animation-delay: 0.3s; } .board__draw.d3 { animation-delay: 0.45s; } .board__draw.d4 { animation-delay: 0.6s; }
  .board__draw.d5 { animation-delay: 0.75s; } .board__draw.d6 { animation-delay: 0.9s; } .board__draw.d7 { animation-delay: 1.05s; }
  html[data-opening-motion="paused"] .board__draw { animation: none; stroke-dashoffset: 0; }
}
@keyframes board-draw { to { stroke-dashoffset: 0; } }

/* ==========================================================================
   CLICK-TO-ENTER MACHINED CHIP COVER (Round 5 — ported to live site)
   Scoped strictly to .cover, .cover__lift-shadow, and the lifting transition.
   Once html[data-cover="open"], the live home page styles apply untouched.
   ========================================================================== */
.cover,
.cover__lift-shadow {
  display: none;
}

.cover::after {
  content: none;
  display: none;
}

html[data-cover="on"] {
  overflow: hidden;
}

.cover:focus {
  outline: none;
}

html[data-cover="on"] .cover,
html[data-cover="lifting"] .cover,
html[data-cover="on"][data-opening-motion] .cover,
html[data-cover="lifting"][data-opening-motion] .cover {
  --lift-p: 0;
  position: fixed;
  inset: 0;
  z-index: 80;
  display: block;
  padding: 0;
  background: #060607;
  overflow: hidden;
  cursor: pointer;
  touch-action: none;
  touch-action: pinch-zoom;
  -webkit-user-select: none;
  user-select: none;
  box-shadow:
    0 24px 70px rgba(0, 0, 0, 0.94),
    0 8px 22px rgba(0, 0, 0, 0.82);
  transition:
    transform 1020ms cubic-bezier(0.42, 0.04, 0.16, 1),
    border-radius 360ms cubic-bezier(0.2, 0.7, 0.2, 1),
    box-shadow 1020ms cubic-bezier(0.42, 0.04, 0.16, 1);
  will-change: transform;
}

html[data-cover="on"] .cover:active {
  cursor: grabbing;
  border-radius: 0;
}

/* Soft physical grounding shadow apron cast onto the emerging site below the cover */
html[data-cover="on"] .cover__lift-shadow,
html[data-cover="lifting"] .cover__lift-shadow {
  position: fixed;
  left: -4vw;
  right: -4vw;
  top: 0;
  height: 100vh;
  z-index: 75;
  display: block;
  pointer-events: none;
  background: linear-gradient(
    180deg,
    rgba(0, 0, 0, 0) 0%,
    rgba(0, 0, 0, 0) 76%,
    rgba(3, 3, 4, 0.74) 94%,
    rgba(0, 0, 0, 0.92) 100%
  );
  filter: blur(26px);
  opacity: 0;
  transform: translate3d(0, 0, 0);
  transition:
    transform 1040ms cubic-bezier(0.42, 0.04, 0.16, 1),
    opacity 420ms ease-out;
}

html[data-cover="lifting"] .cover,
html[data-cover="lifting"][data-opening-motion] .cover {
  transform: translate3d(0, -106%, 0);
  border-radius: 0 0 32px 32px;
  box-shadow:
    0 46px 110px rgba(0, 0, 0, 0.96),
    0 18px 38px rgba(0, 0, 0, 0.85),
    0 2px 18px rgba(242, 191, 101, 0.14);
}

html[data-cover="lifting"] .cover__lift-shadow {
  opacity: 0.95;
  transform: translate3d(0, -104%, 0);
}

/* Deterministic mid-lift state for QA & studio review (?state=mid-lift) */
html[data-cover="lifting"][data-state="mid-lift"] .cover {
  transition: none !important;
  transform: translate3d(0, -47%, 0);
  border-radius: 0 0 30px 30px;
}

html[data-cover="lifting"][data-state="mid-lift"] .cover__lift-shadow {
  transition: none !important;
  opacity: 0.92;
  transform: translate3d(0, -42%, 0);
}

/* Skip link rises above the lifting sheet on Tab */
html[data-cover="lifting"] .cts-skip {
  z-index: 95;
}

/* Full-bleed WebGL2 studio hardware stage */
.cover__stage {
  position: absolute;
  inset: 0;
  z-index: 0;
  pointer-events: none;
  overflow: hidden;
  background: #060607;
}

.cover__fallback {
  position: absolute;
  inset: 0;
  background:
    radial-gradient(ellipse 48% 36% at 50% 60%, rgba(242, 191, 101, 0.11) 0%, rgba(184, 55, 35, 0.045) 42%, rgba(6, 6, 7, 0.96) 78%),
    linear-gradient(180deg, #09090b 0%, #070708 56%, #050506 100%);
  transition: opacity 280ms ease-out;
}

.cover__canvas {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  display: block;
  opacity: 0;
  transition: opacity 280ms ease-out;
}

html[data-chip-webgl="ready"] .cover__canvas {
  opacity: 1;
}

html[data-chip-webgl="ready"] .cover__fallback {
  opacity: 0;
}

/* Deep obsidian upper studio veil and bottom foot vignette — preserves Round 5's crisp darkness */
.cover__vignette {
  position: absolute;
  inset: 0;
  pointer-events: none;
  background:
    radial-gradient(ellipse 62% 24% at 50% 11%, rgba(5, 5, 6, 0.78) 0%, rgba(5, 5, 6, 0.22) 66%, rgba(5, 5, 6, 0) 100%),
    linear-gradient(180deg, rgba(5, 5, 6, 0.68) 0%, rgba(5, 5, 6, 0.14) 22%, rgba(5, 5, 6, 0) 36%, rgba(5, 5, 6, 0) 82%, rgba(4, 4, 5, 0.86) 95%, rgba(2, 2, 3, 0.96) 100%);
}

/* Understated brand mark floating cleanly above the chip centerpiece (no home copy on hero) */
.cover__sanctuary {
  position: absolute;
  top: clamp(1.35rem, 3.8vh, 2.8rem);
  left: 0;
  right: 0;
  z-index: 2;
  display: grid;
  justify-items: center;
  padding: 0 var(--cts-layout-gutter);
  pointer-events: none;
}

.cover__mark {
  position: relative;
  width: min(21rem, 55vw);
}

.cover__mark::before {
  content: "";
  position: absolute;
  inset: -28% -14%;
  z-index: -1;
  background: radial-gradient(
    ellipse 54% 48% at 50% 50%,
    rgba(242, 191, 101, 0.11) 0%,
    rgba(184, 55, 35, 0.045) 48%,
    rgba(0, 0, 0, 0) 74%
  );
  opacity: var(--forge-op, 1);
  pointer-events: none;
}

.cover__forge-flare {
  position: absolute;
  inset: -95% -55%;
  z-index: 3;
  pointer-events: none;
  background:
    radial-gradient(
      ellipse 38% 28% at 50% 50%,
      rgba(255, 244, 223, 0.86) 0%,
      rgba(242, 191, 101, 0.52) 22%,
      rgba(184, 55, 35, 0.22) 40%,
      rgba(0, 0, 0, 0) 58%
    );
  mix-blend-mode: screen;
  opacity: 0;
  transform: translateZ(0) scaleX(0.04);
  transform-origin: 50% 50%;
  will-change: transform, opacity;
}

.cover__forge-flare::after {
  content: "";
  position: absolute;
  left: 16%;
  right: 16%;
  top: 50%;
  height: 3px;
  transform: translateY(-50%);
  border-radius: 999px;
  background: linear-gradient(
    90deg,
    rgba(255, 244, 223, 0) 0%,
    rgba(184, 55, 35, 0.78) 14%,
    rgba(242, 191, 101, 0.96) 36%,
    #fff4df 50%,
    rgba(242, 191, 101, 0.96) 64%,
    rgba(184, 55, 35, 0.78) 86%,
    rgba(255, 244, 223, 0) 100%
  );
}

.cover__mark-reveal {
  position: relative;
  width: 100%;
  overflow: hidden;
  will-change: transform, opacity;
}

.cover__mark picture {
  display: contents;
}

.cover__mark img {
  width: 100%;
  height: auto;
  display: block;
  filter: drop-shadow(0 16px 30px rgba(0, 0, 0, 0.85)) drop-shadow(0 2px 8px rgba(0, 0, 0, 0.68));
  -webkit-user-drag: none;
}

.cover__forge-molten {
  position: absolute;
  inset: 0;
  background: radial-gradient(
    ellipse 72% 78% at 50% 50%,
    #fff4df 0%,
    #f2bf65 44%,
    #b83723 84%,
    rgba(184, 55, 35, 0.4) 100%
  );
  -webkit-mask: url(cts-logo-header.webp) center / 100% 100% no-repeat;
  mask: url(cts-logo-header.webp) center / 100% 100% no-repeat;
  mix-blend-mode: screen;
  opacity: 0;
  will-change: opacity;
  pointer-events: none;
}

/* Pure GPU-composited feathered obsidian curtains (zero CPU mask re-rasterization!) */
.cover__forge-veil {
  position: absolute;
  top: -12%;
  bottom: -12%;
  width: 68%;
  pointer-events: none;
  z-index: 2;
  will-change: transform;
}

.cover__forge-veil--l {
  left: -18%;
  background: linear-gradient(90deg, #050506 0%, #050506 72%, rgba(5, 5, 6, 0) 100%);
  transform: translate3d(0%, 0, 0);
}

.cover__forge-veil--r {
  right: -18%;
  background: linear-gradient(270deg, #050506 0%, #050506 72%, rgba(5, 5, 6, 0) 100%);
  transform: translate3d(0%, 0, 0);
}

.cover__sheen {
  position: absolute;
  inset: 0;
  overflow: hidden;
  -webkit-mask: url(cts-logo-header.webp) center / 100% 100% no-repeat;
  mask: url(cts-logo-header.webp) center / 100% 100% no-repeat;
  mix-blend-mode: soft-light;
  opacity: 0;
  pointer-events: none;
}

.cover__sheen::after {
  content: "";
  position: absolute;
  inset: -20% 0;
  width: 44%;
  background: linear-gradient(90deg, rgba(255, 244, 223, 0) 0%, rgba(255, 244, 223, 0.82) 50%, rgba(255, 244, 223, 0) 100%);
  transform: translate3d(-140%, 0, 0) skewX(-20deg);
}

html[data-opening-motion="playing"][data-intro-phase="forge"] .cover__sheen {
  opacity: 1;
}

html[data-opening-motion="playing"][data-intro-phase="forge"] .cover__sheen::after {
  animation: cover-sheen-gpu 740ms cubic-bezier(0.25, 0.6, 0.3, 1) 460ms 1 both;
}

@keyframes cover-sheen-gpu {
  from { transform: translate3d(-140%, 0, 0) skewX(-20deg); }
  to   { transform: translate3d(340%, 0, 0) skewX(-20deg); }
}

/* Once settled into ready/idle, drop all forge helper layers so idle has zero extra GPU compositing */
html[data-intro-phase="ready"] .cover__forge-flare,
html[data-intro-phase="ready"] .cover__forge-molten,
html[data-intro-phase="ready"] .cover__forge-veil {
  display: none;
}

html[data-intro-phase="ready"] .cover__mark-reveal {
  overflow: visible;
}

/* Pre-forge initial hidden state before first paint (animated directly on child GPU layers in JS) */
html[data-intro-phase]:not([data-intro-phase="ready"]) .cover__mark::before {
  opacity: 0;
}

html[data-intro-phase]:not([data-intro-phase="ready"]) .cover__mark-reveal {
  opacity: 0;
  transform: scale(0.93);
}

html[data-intro-phase]:not([data-intro-phase="ready"]) .cover__open {
  opacity: 0;
  transform: translate3d(-50%, 12px, 0);
  transition: none;
}

html[data-intro-phase]:not([data-intro-phase="ready"]) .cover__lip {
  opacity: 0;
  transform: scaleX(0.06);
  transform-origin: 50% 50%;
  transition: none;
}

/* Precision-machined Enter site / Swipe up handle */
.cover__open {
  position: absolute;
  z-index: 4;
  left: 50%;
  bottom: max(1.65rem, env(safe-area-inset-bottom));
  display: grid;
  justify-items: center;
  gap: 0.65rem;
  min-width: 14rem;
  min-height: 5.5rem;
  padding: 0.75rem 1.5rem;
  border: 0;
  border-radius: var(--cts-radius-lg);
  background: none;
  color: var(--cts-color-text);
  font: inherit;
  font-size: var(--cts-font-size-caption);
  font-weight: var(--cts-font-weight-semibold);
  letter-spacing: 0.16em;
  text-transform: uppercase;
  cursor: pointer;
  transform: translateX(-50%);
  -webkit-tap-highlight-color: transparent;
  transition:
    opacity 260ms ease-out,
    transform 260ms var(--cts-motion-ease-out),
    border-color 220ms ease-out,
    box-shadow 220ms ease-out,
    background-color 220ms ease-out;
}

html[data-cover="lifting"] .cover__open {
  opacity: 0.25;
  transform: translateX(-50%) translateY(-4px);
}

.cover__open:focus-visible {
  outline: var(--cts-focus-width) solid var(--cts-color-focus);
  outline-offset: var(--cts-focus-offset);
}

.cover__chevron {
  width: 0.65rem;
  height: 0.65rem;
  border-top: 2px solid var(--cts-color-gold);
  border-left: 2px solid var(--cts-color-gold);
  transform: rotate(45deg) translateY(2px);
  flex: none;
}

.cover__hint {
  color: var(--cts-color-text);
  background: linear-gradient(100deg, #b5b0a6 36%, #fff4df 50%, #b5b0a6 64%) 0 0 / 260% 100%;
  -webkit-background-clip: text;
  background-clip: text;
  -webkit-text-fill-color: transparent;
}

.cover__hint--pointer {
  display: none;
}

.cover__bar {
  width: 8.5rem;
  height: 5px;
  border-radius: var(--cts-radius-pill);
  background: linear-gradient(90deg, rgba(242, 191, 101, 0.35), rgba(255, 244, 223, 0.78), rgba(242, 191, 101, 0.35));
  box-shadow: 0 1px 10px rgba(242, 191, 101, 0.28);
}

@media (hover: hover) and (pointer: fine) {
  .cover__hint--touch,
  .cover__bar {
    display: none;
  }
  .cover__hint--pointer {
    display: inline;
  }
  .cover__open {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 0.72rem;
    bottom: max(1.85rem, 4.6vh);
    min-height: 3.125rem;
    min-width: 11.75rem;
    padding: 0 1.8rem;
    border: 1px solid rgba(242, 191, 101, 0.56);
    border-radius: var(--cts-radius-pill);
    background: linear-gradient(180deg, rgba(36, 34, 34, 0.88) 0%, rgba(12, 12, 14, 0.94) 100%);
    -webkit-backdrop-filter: blur(12px) saturate(140%);
    backdrop-filter: blur(12px) saturate(140%);
    box-shadow:
      inset 0 1px 0 rgba(255, 244, 223, 0.28),
      inset 0 -1px 0 rgba(0, 0, 0, 0.78),
      0 14px 36px rgba(0, 0, 0, 0.86),
      0 0 28px rgba(242, 191, 101, 0.14);
  }
  .cover__open:focus-visible {
    border-radius: var(--cts-radius-pill);
  }
  .cover__open:hover {
    border-color: #ffd98a;
    background: linear-gradient(180deg, rgba(52, 46, 40, 0.94) 0%, rgba(20, 18, 16, 0.96) 100%);
    box-shadow:
      inset 0 1px 0 rgba(255, 248, 226, 0.48),
      0 16px 42px rgba(0, 0, 0, 0.88),
      0 0 38px rgba(242, 191, 101, 0.34),
      0 0 64px rgba(184, 55, 35, 0.16);
    transform: translateX(-50%) translateY(-2px);
  }
  .cover__chevron {
    width: 0.5rem;
    height: 0.5rem;
    transform: rotate(45deg) translateY(1px);
  }
}

/* Physical chamfered red-into-gold sealing flange along the bottom lifting edge */
.cover__lip {
  position: absolute;
  z-index: 6;
  inset: auto 0 0 0;
  height: 3px;
  pointer-events: none;
  overflow: hidden;
  background: linear-gradient(
    90deg,
    rgba(184, 55, 35, 0.08) 0%,
    rgba(184, 55, 35, 0.92) 18%,
    #f2bf65 44%,
    #ffebb8 50%,
    #f2bf65 56%,
    rgba(184, 55, 35, 0.92) 82%,
    rgba(184, 55, 35, 0.08) 100%
  );
  box-shadow:
    0 -1px 0 rgba(255, 244, 223, 0.16),
    0 0 18px rgba(242, 191, 101, 0.36),
    0 0 32px rgba(184, 55, 35, 0.24);
  transition: box-shadow 260ms ease-out, height 220ms ease-out;
}

.cover__lip::after {
  content: "";
  position: absolute;
  inset: 0;
  background: linear-gradient(90deg, rgba(255, 244, 223, 0) 0%, #fff4df 45%, #f2bf65 55%, rgba(255, 244, 223, 0) 100%);
  transform: scaleX(0.08);
  opacity: 0;
  transition: transform 520ms cubic-bezier(0.16, 1, 0.3, 1), opacity 220ms ease-out;
}

html[data-cover="lifting"] .cover__lip {
  height: 4px;
  box-shadow:
    0 -1px 0 rgba(255, 248, 226, 0.62),
    0 0 32px rgba(242, 191, 101, 0.85),
    0 0 64px rgba(184, 55, 35, 0.52);
}

html[data-cover="lifting"] .cover__lip::after {
  transform: scaleX(1.35);
  opacity: 0.95;
}

/* Opening shimmer & nudge once the cover settles into ready state */
:root[data-opening-motion="playing"][data-intro-phase="ready"] .cover__hint {
  animation: cover-shimmer 2.5s linear 400ms 3 both;
}

:root[data-opening-motion="playing"][data-intro-phase="ready"] .cover__chevron {
  animation: cover-nudge 2.5s var(--cts-motion-ease-in-out) 400ms 3 both;
}

@keyframes cover-sheen {
  from { opacity: 1; background-position: 140% 0; }
  to { opacity: 1; background-position: -40% 0; }
}

@keyframes cover-shimmer {
  from { background-position: 130% 0; }
  to { background-position: -30% 0; }
}

@keyframes cover-nudge {
  0%, 100% { transform: rotate(45deg) translateY(1px); }
  40% { transform: translateY(-0.36rem) rotate(45deg); }
}

@media (hover: hover) and (pointer: fine) {
  :root[data-opening-motion="playing"] .cover__chevron {
    animation: none;
  }
}

@media (max-width: 900px) {
  .cover__sanctuary {
    top: clamp(2.2rem, 6.4vh, 4.2rem);
  }
  .cover__mark {
    width: min(20rem, 64vw);
  }
}

@media (max-width: 600px) {
  .cover__sanctuary {
    top: clamp(2.1rem, 6.8vh, 3.8rem);
  }
  .cover__mark {
    width: min(17rem, 68vw);
  }
}

/* Site rising in transition behind the lifting cover */
html[data-cover="on"] .hero .board__draw {
  animation-play-state: paused;
}

html[data-cover="on"] .cts-header,
html[data-cover="on"] .sale-bar,
html[data-cover="on"] #main {
  opacity: 0.18;
  transform: translate3d(0, 34px, 0) scale(0.976);
  transform-origin: 50% 16%;
}

html[data-cover="lifting"] .cts-header,
html[data-cover="lifting"] .sale-bar {
  animation: cts-header-enter 760ms cubic-bezier(0.16, 1, 0.3, 1) 200ms both;
}

html[data-cover="lifting"] #main {
  animation: cts-site-enter 900ms cubic-bezier(0.16, 1, 0.3, 1) 170ms both;
}

html[data-cover="lifting"][data-state="mid-lift"] .cts-header,
html[data-cover="lifting"][data-state="mid-lift"] .sale-bar,
html[data-cover="lifting"][data-state="mid-lift"] #main {
  animation: none !important;
  opacity: 0.96;
  transform: translate3d(0, 10px, 0) scale(0.994);
}

@keyframes cts-header-enter {
  from { opacity: 0; transform: translate3d(0, -12px, 0); }
  to { opacity: 1; transform: none; }
}

@keyframes cts-site-enter {
  from { opacity: 0.14; transform: translate3d(0, 36px, 0) scale(0.976); }
  to { opacity: 1; transform: none; }
}

/* Reduced motion, forced colors & print */
@media (prefers-reduced-motion: reduce) {
  html[data-cover="on"] .cover,
  html[data-cover="lifting"] .cover,
  html[data-cover="on"][data-opening-motion] .cover,
  html[data-cover="lifting"][data-opening-motion] .cover {
    transition: opacity 240ms ease-out;
    will-change: auto;
  }

  html[data-cover="lifting"] .cover,
  html[data-cover="lifting"][data-opening-motion] .cover {
    transform: none;
    border-radius: 0;
    opacity: 0;
  }

  html[data-cover="lifting"][data-state="mid-lift"] .cover {
    transform: none !important;
    border-radius: 0 !important;
    opacity: 0.48 !important;
  }

  html[data-cover="on"] .cover__lift-shadow,
  html[data-cover="lifting"] .cover__lift-shadow {
    display: none;
  }

  html[data-cover="on"] .cts-header,
  html[data-cover="on"] .sale-bar,
  html[data-cover="on"] #main,
  html[data-cover="lifting"] .cts-header,
  html[data-cover="lifting"] .sale-bar,
  html[data-cover="lifting"] #main {
    animation: none !important;
    opacity: 1 !important;
    transform: none !important;
  }

  .cover__sheen,
  .cover__hint,
  .cover__chevron {
    animation: none !important;
  }

  .cover__forge-flare,
  .cover__forge-molten,
  .cover__forge-veil {
    display: none !important;
  }

  .cover__mark-reveal {
    overflow: visible !important;
    opacity: 1 !important;
    transform: none !important;
  }

  .cover__open,
  .cover__lip {
    opacity: 1 !important;
  }
}

@media (forced-colors: active) {
  .cover__hint {
    -webkit-text-fill-color: currentColor;
    background: none;
  }
}

@media print {
  .cover,
  .cover__lift-shadow {
    display: none !important;
  }
}

/* ==========================================================================
   Cinematic enter (2026-11-25). One 1.7 s shot:
   0.00-0.28 s  unlatch: the cover dips, the chip flares, the seam ignites
   0.28-1.70 s  lift: the cover rises on a heavy ease, the logo pulls away on
                its own layer, the gold seam trails the bottom edge
   0.40-1.80 s  the site comes up out of depth (scale, blur, light), header last
   Reduced motion keeps the short fade defined above.
   ========================================================================== */
@media (prefers-reduced-motion: no-preference) {
  html[data-cover="lifting"] .cover,
  html[data-cover="lifting"][data-opening-motion] .cover {
    transition: none;
    animation: cts-cine-cover 1700ms both;
  }
  html[data-cover="lifting"] .cover__stage {
    transform-origin: 50% 48%;
    animation: cts-cine-stage 1700ms cubic-bezier(0.3, 0, 0.2, 1) both;
  }
  html[data-cover="lifting"] .cover__sanctuary {
    animation: cts-cine-mark 1300ms cubic-bezier(0.55, 0, 0.2, 1) 180ms both;
  }
  html[data-cover="lifting"] .cover__lip {
    animation: cts-cine-seam 1700ms ease-out both;
  }
  html[data-cover="lifting"] .cover__lip::after {
    transition: transform 700ms cubic-bezier(0.16, 1, 0.3, 1) 60ms, opacity 200ms ease-out;
    transform: scaleX(1.6);
  }
  html[data-cover="lifting"] .cover__lift-shadow {
    transition: transform 1420ms cubic-bezier(0.62, 0, 0.18, 1) 280ms, opacity 500ms ease-out;
  }
  html[data-cover="lifting"] #main {
    transform-origin: 50% 0;
    animation: cts-cine-site 1400ms cubic-bezier(0.16, 1, 0.3, 1) 400ms both;
  }
  html[data-cover="lifting"] .cts-header,
  html[data-cover="lifting"] .sale-bar {
    animation: cts-cine-header 800ms cubic-bezier(0.16, 1, 0.3, 1) 1000ms both;
  }
}

@keyframes cts-cine-cover {
  0%   { transform: translate3d(0, 0, 0); border-radius: 0; animation-timing-function: cubic-bezier(0.3, 0, 0.6, 1); }
  10%  { transform: translate3d(0, 1.4%, 0); border-radius: 0 0 8px 8px; animation-timing-function: cubic-bezier(0.4, 0, 0.6, 1); }
  16%  { transform: translate3d(0, 0.9%, 0); border-radius: 0 0 14px 14px; animation-timing-function: cubic-bezier(0.62, 0, 0.18, 1); }
  100% { transform: translate3d(0, -108%, 0); border-radius: 0 0 44px 44px;
         box-shadow: 0 60px 140px rgba(0, 0, 0, 0.96), 0 20px 44px rgba(0, 0, 0, 0.85), 0 18px 90px rgba(242, 191, 101, 0.30); }
}

@keyframes cts-cine-stage {
  0%   { transform: scale(1); filter: brightness(1); }
  14%  { transform: scale(1.025); filter: brightness(1.45) saturate(1.15); }
  40%  { transform: scale(1.055); filter: brightness(1.1); }
  100% { transform: scale(1.09); filter: brightness(0.55); }
}

@keyframes cts-cine-mark {
  from { transform: translate3d(0, 0, 0) scale(1); opacity: 1; filter: blur(0); }
  to   { transform: translate3d(0, -22vh, 0) scale(1.08); opacity: 0; filter: blur(6px); }
}

@keyframes cts-cine-seam {
  0%   { height: 3px; box-shadow: none; }
  12%  { height: 6px; box-shadow: 0 0 22px rgba(255, 248, 226, 0.95), 0 0 70px rgba(242, 191, 101, 0.95), 0 0 140px rgba(184, 55, 35, 0.7); }
  100% { height: 4px; box-shadow: 0 -1px 0 rgba(255, 248, 226, 0.62), 0 0 40px rgba(242, 191, 101, 0.9), 0 0 110px rgba(184, 55, 35, 0.55); }
}

@keyframes cts-cine-site {
  from { opacity: 0; transform: translate3d(0, 4.5rem, 0) scale(0.93); filter: blur(8px) brightness(0.45); }
  55%  { filter: blur(0) brightness(1.08); }
  to   { opacity: 1; transform: none; filter: none; }
}

@keyframes cts-cine-header {
  from { opacity: 0; transform: translate3d(0, -18px, 0); }
  to   { opacity: 1; transform: none; }
}
