/* ===== Basted Visuals — Arcade Cabinet (cutout-driven layout) ===== */
/*
  Hole map v3d9:
  Marquee:  L 20.8% T  2.6% W 58.5% H  6.3%
  Screen:   L  4.55% T 15.95% W 91.05% H 34.85%  (corners ~1.35%)
  Btn L/M/R: good
  Social:    L 38.22 / 50.25 / 62.15 % × 77.36/84.50 %
*/

/*
  THEME TOKENS — change fonts/colors here later without hunting the whole file.
  Swap --font-* or palette vars and most of the UI follows.
*/
:root {
  /*
    Crystal wordmark theme (from logo-basted-visuals.png):
    electric teal-cyan + deep violet, dark body, metallic outline energy
  */
  --bg: #04060c;
  --cyan: #2ee6ef;
  --teal: #1ad4c8;
  --pink: #c44bff; /* shifted toward logo purple for harmony */
  --purple: #7b3dff;
  --violet-deep: #4a1a8a;
  --text: #eef9ff;
  --muted: rgba(200, 240, 255, 0.72);

  /* Fonts */
  --font-ui: "Inter", system-ui, sans-serif;
  --font-game: "Orbitron", sans-serif;
  --font-marquee: "Orbitron", sans-serif;
  --font-button: "Black Ops One", "Orbitron", sans-serif;

  /* Motion */
  --pulse-fast: 1.8s;
  --pulse-slow: 2.6s;
}

*,
*::before,
*::after {
  box-sizing: border-box;
}

html {
  height: 100%;
  /* iOS Safari: fill real visible viewport */
  height: -webkit-fill-available;
}

html,
body {
  margin: 0;
  background: var(--bg);
  color: var(--text);
  font-family: var(--font-ui);
}

body {
  min-height: 100%;
  min-height: 100svh;
  min-height: 100dvh;
  min-height: -webkit-fill-available;
  height: 100%;
  height: 100svh;
  height: 100dvh;
  overflow: hidden;
}

.stage {
  position: relative;
  min-height: 100%;
  min-height: 100svh;
  min-height: 100dvh;
  min-height: -webkit-fill-available;
  height: 100%;
  height: 100svh;
  height: 100dvh;
  width: 100%;
  display: grid;
  place-items: center;
  padding: 0;
  box-sizing: border-box;
  overflow: hidden;
  background: #05031a;
}

/* ---------- Arena ambient (reference art + motion) ---------- */
.stage-ambient {
  position: absolute;
  inset: 0;
  z-index: 0;
  pointer-events: none;
  overflow: hidden;
}

/* Media plate: locked camera (no pull-in) — motion lives in the video lights only */
.amb-media {
  position: absolute;
  inset: 0;
  z-index: 0;
  transform: none;
}

.amb-video,
.amb-photo {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  object-fit: cover;
  /* Bias slightly low so lowered walls stay visible at bottom */
  object-position: center 58%;
}

.amb-video {
  z-index: 1;
  /* Slight boost so neon punches through */
  filter: saturate(1.1) contrast(1.05) brightness(1.03);
}

/* Still plate shows if video fails / reduced motion */
.amb-photo {
  z-index: 0;
  filter: saturate(1.08) contrast(1.04);
}

.amb-photo-desktop {
  background: center 58% / cover no-repeat url("../assets/stage-arena.jpg?v=5");
}

.amb-photo-mobile {
  display: none;
  background: center 55% / cover no-repeat url("../assets/stage-arena-mobile.jpg?v=2");
}

/* Desktop default: hide mobile plate */
.amb-video-mobile {
  display: none;
}

/* Extra color orbs on top of the arena for more “alive” bloom */
.amb-orb {
  position: absolute;
  z-index: 2;
  border-radius: 50%;
  filter: blur(56px);
  will-change: transform, opacity;
  mix-blend-mode: screen;
  pointer-events: none;
}

.amb-orb-cyan {
  width: min(70vw, 620px);
  height: min(70vw, 620px);
  left: -12%;
  top: 0%;
  background: radial-gradient(circle, rgba(46, 230, 239, 0.42) 0%, rgba(26, 212, 200, 0.1) 45%, transparent 70%);
  animation: ambDriftA 16s ease-in-out infinite alternate;
}

.amb-orb-purple {
  width: min(90vw, 820px);
  height: min(90vw, 820px);
  left: 18%;
  top: 10%;
  background: radial-gradient(circle, rgba(123, 61, 255, 0.48) 0%, rgba(74, 26, 138, 0.16) 48%, transparent 72%);
  animation: ambDriftB 20s ease-in-out infinite alternate;
}

.amb-orb-pink {
  width: min(75vw, 640px);
  height: min(75vw, 640px);
  right: -14%;
  bottom: -6%;
  left: auto;
  background: radial-gradient(circle, rgba(255, 78, 184, 0.36) 0%, rgba(196, 75, 255, 0.12) 42%, transparent 70%);
  animation: ambDriftC 18s ease-in-out infinite alternate;
}

/* Soft side wash only — no big center cone */
.amb-rays {
  position: absolute;
  inset: 0;
  z-index: 3;
  background:
    radial-gradient(ellipse 42% 55% at 12% 28%, rgba(46, 230, 239, 0.12), transparent 70%),
    radial-gradient(ellipse 42% 55% at 88% 28%, rgba(196, 75, 255, 0.12), transparent 70%),
    linear-gradient(
      118deg,
      transparent 18%,
      rgba(46, 230, 239, 0.05) 36%,
      transparent 48%,
      rgba(196, 75, 255, 0.06) 62%,
      transparent 80%
    );
  background-size: 100% 100%, 100% 100%, 240% 100%;
  animation: ambRays 12s ease-in-out infinite alternate;
  mix-blend-mode: screen;
  opacity: 0.85;
}

/* Falling dust only (downward forever — denser layer; never reverses with video) */
.amb-dust {
  position: absolute;
  inset: 0;
  z-index: 3;
  overflow: hidden;
  pointer-events: none;
  mix-blend-mode: screen;
}

.amb-dust span {
  position: absolute;
  top: -6%;
  border-radius: 50%;
  background: rgba(230, 245, 255, 0.72);
  box-shadow:
    0 0 3px rgba(200, 230, 255, 0.55),
    0 0 8px rgba(160, 200, 255, 0.25);
  animation-name: ambDustFall;
  animation-timing-function: linear;
  animation-iteration-count: infinite;
  opacity: 0;
  will-change: transform, opacity;
}

@keyframes ambDustFall {
  0% {
    transform: translate3d(0, 0, 0);
    opacity: 0;
  }
  6% {
    opacity: var(--dust-op, 0.7);
  }
  80% {
    opacity: calc(var(--dust-op, 0.7) * 0.55);
  }
  100% {
    transform: translate3d(var(--dust-drift, 8px), 118vh, 0);
    opacity: 0;
  }
}

/* Keep the cabinet readable — darken edges + soft center tunnel */
.amb-vignette {
  position: absolute;
  inset: 0;
  z-index: 4;
  background:
    radial-gradient(ellipse 48% 62% at 50% 46%, transparent 0%, transparent 42%, rgba(4, 2, 16, 0.35) 72%, rgba(2, 1, 10, 0.78) 100%),
    linear-gradient(180deg, rgba(5, 3, 18, 0.25) 0%, transparent 18%, transparent 72%, rgba(3, 2, 14, 0.55) 100%);
  pointer-events: none;
}

@keyframes ambDriftA {
  0% {
    transform: translate3d(0, 0, 0) scale(1);
    opacity: 0.45;
  }
  50% {
    transform: translate3d(14%, 12%, 0) scale(1.15);
    opacity: 0.85;
  }
  100% {
    transform: translate3d(5%, 16%, 0) scale(1);
    opacity: 0.55;
  }
}

@keyframes ambDriftB {
  0% {
    transform: translate3d(0, 0, 0) scale(1.05);
    opacity: 0.55;
  }
  50% {
    transform: translate3d(-12%, -8%, 0) scale(1.2);
    opacity: 0.95;
  }
  100% {
    transform: translate3d(8%, 5%, 0) scale(1);
    opacity: 0.5;
  }
}

@keyframes ambDriftC {
  0% {
    transform: translate3d(0, 0, 0) scale(1);
    opacity: 0.4;
  }
  50% {
    transform: translate3d(-16%, -10%, 0) scale(1.18);
    opacity: 0.8;
  }
  100% {
    transform: translate3d(-5%, -3%, 0) scale(1.05);
    opacity: 0.5;
  }
}

@keyframes ambRays {
  0% {
    background-position: 0 0, 0% 50%;
    opacity: 0.55;
  }
  100% {
    background-position: 0 0, 100% 50%;
    opacity: 1;
  }
}

.stage > .cabinet {
  position: relative;
  z-index: 1;
  /* Soft lift so cab reads against the arena */
  filter: drop-shadow(0 12px 40px rgba(0, 0, 0, 0.55));
}

@media (prefers-reduced-motion: reduce) {
  .amb-orb,
  .amb-rays,
  .amb-dust span {
    animation: none !important;
  }

  .amb-dust {
    display: none;
  }

  .amb-video-desktop,
  .amb-video-mobile {
    display: none !important;
  }

  .amb-orb-cyan {
    opacity: 0.55;
  }

  .amb-orb-purple {
    opacity: 0.65;
  }

  .amb-orb-pink {
    opacity: 0.5;
  }
}

/*
  Phone / tall screens: use portrait arena so honeycomb walls + beams
  stay in frame (landscape 16:9 was cropping to empty center).
*/
@media (max-width: 900px), (max-aspect-ratio: 10 / 16) {
  .amb-video-desktop,
  .amb-photo-desktop {
    display: none !important;
  }

  .amb-video-mobile {
    display: block;
    object-position: center 55%;
    filter: saturate(1.18) contrast(1.08) brightness(1.06);
  }

  .amb-photo-mobile {
    display: block;
    filter: saturate(1.14) contrast(1.06) brightness(1.04);
  }

  /* Pull side neon into the phone frame harder */
  .amb-orb {
    filter: blur(36px);
  }

  .amb-orb-cyan {
    width: min(95vw, 420px);
    height: min(95vw, 420px);
    left: -18%;
    top: 8%;
    opacity: 0.9;
    background: radial-gradient(circle, rgba(46, 230, 239, 0.55) 0%, rgba(26, 212, 200, 0.14) 45%, transparent 70%);
  }

  .amb-orb-purple {
    width: min(110vw, 520px);
    height: min(110vw, 520px);
    left: 15%;
    top: 18%;
    background: radial-gradient(circle, rgba(123, 61, 255, 0.55) 0%, rgba(74, 26, 138, 0.18) 48%, transparent 72%);
  }

  .amb-orb-pink {
    width: min(95vw, 420px);
    height: min(95vw, 420px);
    right: -16%;
    bottom: 4%;
    background: radial-gradient(circle, rgba(255, 78, 184, 0.48) 0%, rgba(196, 75, 255, 0.16) 42%, transparent 70%);
  }

  .amb-rays {
    opacity: 1;
    background:
      radial-gradient(ellipse 55% 50% at 8% 30%, rgba(46, 230, 239, 0.22), transparent 68%),
      radial-gradient(ellipse 55% 50% at 92% 30%, rgba(196, 75, 255, 0.22), transparent 68%),
      radial-gradient(ellipse 70% 40% at 50% 88%, rgba(100, 60, 180, 0.14), transparent 70%),
      linear-gradient(
        118deg,
        transparent 12%,
        rgba(46, 230, 239, 0.08) 32%,
        transparent 46%,
        rgba(196, 75, 255, 0.09) 68%,
        transparent 88%
      );
    background-size: 100% 100%, 100% 100%, 100% 100%, 240% 100%;
  }

  /* Lighter vignette so walls/dust read through on phone */
  .amb-vignette {
    background:
      radial-gradient(ellipse 62% 58% at 50% 48%, transparent 0%, transparent 48%, rgba(4, 2, 16, 0.28) 78%, rgba(2, 1, 10, 0.62) 100%),
      linear-gradient(180deg, rgba(5, 3, 18, 0.18) 0%, transparent 14%, transparent 68%, rgba(3, 2, 14, 0.42) 100%);
  }

  /* Dust more visible against phone glass */
  .amb-dust span {
    background: rgba(240, 248, 255, 0.88);
    box-shadow:
      0 0 4px rgba(210, 235, 255, 0.75),
      0 0 10px rgba(170, 210, 255, 0.4);
  }
}

.cabinet {
  position: relative;
  aspect-ratio: 832 / 1248;
  /* Desktop / landscape: fit entire cabinet, keep proportions */
  width: min(100vw, calc(100dvh * 832 / 1248));
  height: min(100dvh, calc(100vw * 1248 / 832));
  max-width: 100vw;
  max-height: 100dvh;
  user-select: none;
  -webkit-user-select: none;
}

/*
  Mobile: stretch the full cabinet to fill the screen.
  Proportions can change — no crop, no letterbox.
  Hotspots stay % of the box so they still line up.
*/
@media (max-width: 900px), (max-aspect-ratio: 10 / 16) {
  .cabinet {
    aspect-ratio: auto;
    width: 100vw;
    width: 100dvw;
    height: 100%;
    height: 100svh;
    height: 100dvh;
    max-width: none;
    max-height: none;
    transform: none;
  }

  .cabinet-art {
    /* Stretch art to the stretched box */
    object-fit: fill;
  }
}

/* Cutout frame sits on top; holes reveal layers below */
.cabinet-art {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  object-fit: fill;
  pointer-events: none;
  z-index: 20;
  display: block;
}

/* ---------- Marquee — steak icons + crystal wordmark ---------- */
.marquee {
  position: absolute;
  /* Fill marquee hole edge-to-edge — neon frame is the PNG on top */
  left: 20.8%;
  top: 2.6%;
  width: 58.5%;
  height: 6.3%;
  z-index: 10;
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 1.2%;
  /* Soft blend into neon (not a hard black slab) */
  background:
    radial-gradient(ellipse 90% 120% at 50% 50%, #0a0e18 0%, #05070f 70%, #03050a 100%);
  box-shadow:
    inset 0 0 12px rgba(0, 200, 220, 0.12),
    inset 0 0 20px rgba(180, 60, 255, 0.08);
  overflow: hidden;
  border: none;
  padding: 0 1.2%;
  margin: 0;
  cursor: pointer;
  appearance: none;
  -webkit-tap-highlight-color: transparent;
}

/*
  Marquee pulse — ONE animation, same duration, no delays.
  Logo + both steaks breathe together.
*/
.marquee-logo,
.marquee-steak {
  pointer-events: none;
  user-select: none;
  animation: marqueePulseSynced var(--pulse-slow) ease-in-out infinite;
  animation-delay: 0s;
}

.marquee-logo {
  display: block;
  flex: 1 1 auto;
  width: auto;
  min-width: 0;
  height: 82%;
  max-height: 100%;
  object-fit: contain;
  object-position: center;
}

/* Neon steak flanks — same asset, mirrored on the right */
.marquee-steak {
  flex: 0 0 auto;
  display: block;
  height: 78%;
  width: auto;
  max-width: 12%;
  object-fit: contain;
}

.marquee-steak-left {
  transform: scaleX(1);
}

.marquee-steak-right {
  /* Mirror so both open toward the wordmark (no animation-delay) */
  transform: scaleX(-1);
}

.marquee:hover .marquee-logo,
.marquee:focus-visible .marquee-logo {
  animation: none;
  filter:
    drop-shadow(0 0 6px rgba(46, 230, 239, 0.95))
    drop-shadow(0 0 16px rgba(123, 61, 255, 0.75))
    drop-shadow(0 0 28px rgba(196, 75, 255, 0.45));
  opacity: 1;
  transform: scale(1.03);
}

.marquee:hover .marquee-steak-left,
.marquee:focus-visible .marquee-steak-left {
  animation: none;
  filter:
    drop-shadow(0 0 6px rgba(46, 230, 239, 1))
    drop-shadow(0 0 14px rgba(255, 46, 159, 0.75));
  opacity: 1;
  transform: scale(1.08);
}

.marquee:hover .marquee-steak-right,
.marquee:focus-visible .marquee-steak-right {
  animation: none;
  filter:
    drop-shadow(0 0 6px rgba(46, 230, 239, 1))
    drop-shadow(0 0 14px rgba(255, 46, 159, 0.75));
  opacity: 1;
  transform: scaleX(-1) scale(1.08);
}

.marquee:focus-visible {
  outline: none;
}

@keyframes marqueePulseSynced {
  0%,
  100% {
    filter:
      drop-shadow(0 0 3px rgba(46, 230, 239, 0.5))
      drop-shadow(0 0 8px rgba(123, 61, 255, 0.35))
      drop-shadow(0 0 4px rgba(255, 46, 159, 0.25));
    opacity: 0.9;
  }
  50% {
    filter:
      drop-shadow(0 0 7px rgba(46, 230, 239, 0.95))
      drop-shadow(0 0 16px rgba(123, 61, 255, 0.7))
      drop-shadow(0 0 20px rgba(26, 212, 200, 0.35))
      drop-shadow(0 0 12px rgba(255, 46, 159, 0.45));
    opacity: 1;
  }
}

/* ---------- Screen (main monitor cutout) ---------- */
.screen {
  position: absolute;
  /* Expanded cutout fills more space toward neon border (carbon header pass) */
  left: 1.92%;
  top: 14.74%;
  width: 96.27%;
  height: 38.54%;
  z-index: 5;
  overflow: hidden;
  background: #05060c;
  /* 25% less round than prior (was 1.35% / 8–14px) */
  border-radius: clamp(6px, 1.1%, 12px);
  box-shadow:
    inset 0 0 16px rgba(0, 0, 0, 0.3),
    inset 0 0 36px rgba(40, 200, 220, 0.04);
  container-type: size;
  container-name: arcade-screen;
}

.panel {
  position: absolute;
  inset: 0;
  display: none;
  flex-direction: column;
  color: var(--text);
  opacity: 0;
}

.panel.active {
  display: flex;
  animation: panelIn 0.85s ease forwards;
}

.panel[hidden] {
  display: none !important;
}

@keyframes panelIn {
  from {
    opacity: 0;
    filter: brightness(0.4);
  }
  to {
    opacity: 1;
    filter: brightness(1);
  }
}

/* Welcome — fill the glass (type scales with screen via cqi/cqb) */
.panel-welcome {
  align-items: center;
  justify-content: center;
  text-align: center;
  padding: 3% 4%;
  background:
    radial-gradient(ellipse 90% 70% at 50% 48%, rgba(74, 26, 138, 0.45), transparent 72%),
    radial-gradient(ellipse 55% 42% at 50% 22%, rgba(46, 230, 239, 0.12), transparent 60%),
    linear-gradient(180deg, #04060e 0%, #0a0618 100%);
  position: absolute;
}

/* ---------- Welcome logo APNG (hero → docked under titles) ---------- */
.welcome-logo-layer {
  position: absolute;
  inset: 0;
  z-index: 2;
  display: flex;
  align-items: center;
  justify-content: center;
  pointer-events: none;
  /* Fill most of the glass top-to-bottom */
  padding: 1% 2%;
  opacity: 1;
  transition: opacity 0.75s ease;
}

.welcome-logo-anim {
  display: block;
  width: min(96%, 98cqi);
  height: auto;
  max-height: 96%;
  object-fit: contain;
  opacity: 0;
  /* No extra website glow — logo already bright from the asset */
  filter: none;
  transition: opacity 1.5s ease;
}

/* Slow fade-in of full-size logo */
.panel-welcome.welcome-logo-ready .welcome-logo-layer .welcome-logo-anim {
  opacity: 1;
}

/* Soft crossfade out of hero before dock */
.panel-welcome.welcome-logo-leaving .welcome-logo-layer {
  opacity: 0;
}

/* Docked size in spinner slot */
.welcome-spinner .welcome-logo-anim,
#welcome-logo-slot .welcome-logo-anim {
  width: clamp(2.8rem, 18cqi, 6rem);
  max-height: none;
  height: auto;
  opacity: 0;
  transform: scale(0.88);
  filter: none;
  transition:
    opacity 0.7s ease 0.1s,
    transform 0.7s cubic-bezier(0.22, 1, 0.36, 1) 0.1s;
}

.panel-welcome.welcome-logo-docked .welcome-spinner .welcome-logo-anim,
.panel-welcome.welcome-logo-docked #welcome-logo-slot .welcome-logo-anim {
  opacity: 1;
  transform: scale(1);
}

.panel-welcome.welcome-logo-docked .welcome-logo-layer {
  display: none;
}

.welcome-inner {
  position: relative;
  z-index: 3;
  width: 100%;
  max-width: 94%;
}

/* Titles hidden until logo is in permanent slot */
.panel-welcome .game-title,
.panel-welcome .welcome-sub {
  opacity: 0;
  transform: translateY(10px);
  transition:
    opacity 0.8s ease,
    transform 0.8s cubic-bezier(0.22, 1, 0.36, 1);
  pointer-events: none;
}

.panel-welcome.welcome-logo-docked .game-title,
.panel-welcome.welcome-logo-docked .welcome-sub {
  opacity: 1;
  transform: translateY(0);
  pointer-events: auto;
}

/* Slot under titles — permanent logo home */
.welcome-spinner {
  margin-top: 0.75em;
  display: flex;
  justify-content: center;
  align-items: center;
  min-height: clamp(2.8rem, 18cqi, 6rem);
}

.game-title {
  margin: 0;
  font-family: var(--font-game);
  font-weight: 900;
  line-height: 0.92;
  letter-spacing: 0.04em;
  /* Scale to monitor width (cqi), not full phone viewport — keeps PC big, mobile fitted */
  font-size: clamp(1.15rem, 15cqi, 4.6rem);
  transform: skewX(-4deg);
}

.game-title-line {
  display: block;
  white-space: nowrap;
  /* Echo crystal logo: teal → cyan → violet */
  background: linear-gradient(105deg, var(--teal) 0%, var(--cyan) 35%, var(--purple) 70%, var(--pink) 100%);
  -webkit-background-clip: text;
  background-clip: text;
  color: transparent;
  filter:
    drop-shadow(0 0 10px rgba(46, 230, 239, 0.45))
    drop-shadow(0 2px 0 rgba(30, 10, 60, 0.55));
  /* slight metal / slash energy without custom font file */
  font-style: italic;
  letter-spacing: 0.02em;
}

.welcome-sub {
  margin: 0.85em 0 0;
  font-size: clamp(0.55rem, 3.8cqi, 1.05rem);
  letter-spacing: 0.18em;
  text-transform: uppercase;
  color: var(--muted);
  font-weight: 500;
}

/* Narrow / short glass (phones in portrait, small cabinets) */
@container arcade-screen (max-width: 420px) {
  .panel-welcome {
    padding: 4% 5%;
  }

  .game-title {
    font-size: clamp(1.05rem, 13.5cqi, 1.85rem);
    letter-spacing: 0.02em;
    line-height: 0.94;
  }

  .game-title-line {
    filter: drop-shadow(0 0 8px rgba(0, 232, 255, 0.35));
  }

  .welcome-sub {
    margin-top: 0.65em;
    font-size: clamp(0.5rem, 3.4cqi, 0.72rem);
    letter-spacing: 0.14em;
  }

  .welcome-spinner {
    margin-top: 0.55em;
    min-height: clamp(2.4rem, 16cqi, 3.6rem);
  }

  .welcome-spinner .welcome-logo-anim,
  #welcome-logo-slot .welcome-logo-anim {
    width: clamp(2.4rem, 16cqi, 3.6rem);
  }

  .panel-welcome.welcome-logo-hero .welcome-logo-layer {
    padding: 1% 1.5%;
  }
}

@container arcade-screen (max-height: 220px) {
  .game-title {
    font-size: clamp(0.95rem, 12cqi, 1.55rem);
  }

  .welcome-sub {
    margin-top: 0.45em;
  }

  .welcome-spinner {
    margin-top: 0.4em;
    min-height: clamp(2rem, 13cqi, 2.8rem);
  }

  .welcome-spinner .welcome-logo-anim,
  #welcome-logo-slot .welcome-logo-anim {
    width: clamp(2rem, 13cqi, 2.8rem);
  }
}

/* Fallback when container queries unavailable — phone viewports */
@supports not (container-type: size) {
  @media (max-width: 560px) {
    .game-title {
      font-size: clamp(1.1rem, 7vw, 1.7rem);
      letter-spacing: 0.02em;
    }

    .welcome-sub {
      margin-top: 0.65em;
      font-size: clamp(0.52rem, 2.8vw, 0.7rem);
      letter-spacing: 0.14em;
    }

    .welcome-spinner {
      margin-top: 0.55em;
      min-height: 2.8rem;
    }

    .welcome-spinner .welcome-logo-anim,
    #welcome-logo-slot .welcome-logo-anim {
      width: 2.8rem;
    }
  }
}

/* Shared panel chrome */
.panel-heading {
  margin: 0;
  font-family: var(--font-game);
  font-weight: 700;
  letter-spacing: 0.08em;
  font-size: clamp(0.9rem, 3vw, 1.25rem);
  background: linear-gradient(90deg, var(--cyan), var(--pink));
  -webkit-background-clip: text;
  background-clip: text;
  color: transparent;
}

.panel-heading.sm {
  font-size: clamp(0.7rem, 2.2vw, 0.95rem);
}

/* Gallery / services / contact headers stay compact so content fills the glass */
.panel-gallery .panel-heading.sm,
.panel-services .panel-heading.sm,
.panel-contact .panel-heading.sm {
  font-size: clamp(0.62rem, 2vw, 0.85rem);
}

.panel-lead {
  margin: 0.35em 0 0.75em;
  font-size: clamp(0.58rem, 1.7vw, 0.78rem);
  color: var(--muted);
  line-height: 1.4;
}

.panel-scroll {
  height: 100%;
  overflow-y: auto;
  padding: 4% 5%;
  background: linear-gradient(180deg, #060612 0%, #0c0818 100%);
  scrollbar-width: thin;
  scrollbar-color: var(--purple) transparent;
}

/* Contact — same chrome as gallery/services */
.panel-contact {
  background: #05050c;
  /* Flex column so body can shrink to glass height without page scroll */
  min-height: 0;
}

.contact-chrome {
  flex: 0 0 auto;
  padding: 1.2% 2% 0.4%;
  text-align: center;
  z-index: 2;
}

.contact-body {
  flex: 1;
  min-height: 0;
  padding: 1.5% 4% 2.5%;
  display: flex;
  flex-direction: column;
  overflow: hidden; /* fill glass; no empty void under form */
}

/* Contact */
.contact-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 0.45rem;
  margin-bottom: 0.55rem;
  flex: 0 0 auto;
}

.contact-card {
  background: rgba(255, 255, 255, 0.04);
  border: 1px solid rgba(0, 232, 255, 0.18);
  border-radius: 6px;
  padding: 0.45rem 0.55rem;
  font-size: clamp(0.55rem, 1.55vw, 0.72rem);
  display: flex;
  flex-direction: column;
  gap: 0.15rem;
}

.contact-label {
  font-family: var(--font-game);
  font-size: 0.58em;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  color: var(--cyan);
  opacity: 0.9;
}

.contact-card a {
  color: var(--text);
  text-decoration: none;
}

.contact-card a:hover {
  color: var(--cyan);
}

.contact-form {
  display: grid;
  grid-template-columns: 1fr 1fr;
  /* name/email | message expands | submit */
  grid-template-rows: auto minmax(5em, 1fr) auto;
  gap: 0.45rem;
  flex: 1 1 auto;
  min-height: 0;
  height: 100%;
  align-content: stretch;
}

.contact-form label {
  display: flex;
  flex-direction: column;
  gap: 0.15rem;
  font-size: clamp(0.5rem, 1.4vw, 0.65rem);
  color: var(--muted);
}

.contact-form label.full {
  grid-column: 1 / -1;
  display: flex;
  flex-direction: column;
  min-height: 0;
  height: 100%;
}

.contact-form input,
.contact-form textarea {
  background: rgba(0, 0, 0, 0.45);
  border: 1px solid rgba(255, 255, 255, 0.12);
  border-radius: 5px;
  color: var(--text);
  padding: 0.4rem 0.5rem;
  font: inherit;
  font-size: clamp(0.55rem, 1.5vw, 0.72rem);
}

.contact-form input {
  resize: none;
}

.contact-form textarea {
  min-height: 0;
  flex: 1 1 auto;
  height: 100%;
  resize: none; /* keeps layout stable while filling glass */
  box-sizing: border-box;
}

.contact-form input:focus,
.contact-form textarea:focus {
  outline: none;
  border-color: var(--cyan);
  box-shadow: 0 0 0 1px rgba(0, 232, 255, 0.35);
}

.contact-submit {
  grid-column: 1 / -1;
  margin-top: 0.15rem;
  font-family: var(--font-game);
  font-size: clamp(0.58rem, 1.55vw, 0.75rem);
  letter-spacing: 0.1em;
  text-transform: uppercase;
  padding: 0.5rem 0.65rem;
  border: none;
  border-radius: 6px;
  cursor: pointer;
  color: #05050a;
  background: linear-gradient(90deg, var(--cyan), var(--pink));
  transition: transform 0.15s ease, filter 0.15s ease;
}

.contact-submit:hover {
  filter: brightness(1.1);
  transform: translateY(-1px);
}

.form-honey {
  position: absolute;
  width: 1px;
  height: 1px;
  padding: 0;
  margin: -1px;
  overflow: hidden;
  clip: rect(0, 0, 0, 0);
  white-space: nowrap;
  border: 0;
}

.contact-form {
  position: relative;
}

.form-note {
  margin: 0.5rem 0 0;
  font-size: clamp(0.52rem, 1.4vw, 0.68rem);
  color: var(--cyan);
}

.form-note.is-success {
  color: var(--cyan);
}

.form-note.is-error {
  color: #ff8ec8;
}

.form-note a {
  color: inherit;
  text-decoration: underline;
}

.contact-submit:disabled {
  opacity: 0.65;
  cursor: wait;
  transform: none;
}

/* Gallery — large frames, scroll left → right */
.panel-gallery {
  background: #05050c;
}

.gallery-chrome,
.services-chrome {
  flex: 0 0 auto;
  padding: 1.2% 2% 0.4%;
  text-align: center;
  z-index: 2;
}

.gallery-hint {
  margin: 0.15em 0 0;
  font-size: clamp(0.45rem, 1.2vw, 0.58rem);
  letter-spacing: 0.08em;
  text-transform: uppercase;
  color: var(--muted);
}

.gallery-viewport {
  flex: 1;
  min-height: 0;
  position: relative;
  overflow: hidden;
  mask-image: linear-gradient(90deg, transparent, #000 5%, #000 95%, transparent);
  -webkit-mask-image: linear-gradient(90deg, transparent, #000 5%, #000 95%, transparent);
}

.gallery-track {
  display: flex;
  gap: 0.85rem;
  height: 100%;
  align-items: center;
  padding: 0 0.4rem 1.5%;
  width: max-content;
  /* Duration set in JS: ~8s for each image to cross the screen (scales with count) */
  --gallery-duration: 64s;
  animation: galleryScroll var(--gallery-duration) linear infinite;
  will-change: transform;
}

.gallery-viewport.is-paused .gallery-track {
  animation-play-state: paused;
}

@keyframes galleryScroll {
  from {
    transform: translateX(-50%);
  }
  to {
    transform: translateX(0);
  }
}

.gallery-item {
  flex: 0 0 auto;
  /* Fill most of the screen height */
  height: 86%;
  width: auto;
  aspect-ratio: 16 / 10;
  border-radius: 6px;
  overflow: hidden;
  border: 1px solid rgba(0, 232, 255, 0.28);
  cursor: pointer;
  position: relative;
  background: #111;
  opacity: 1;
  transition: transform 0.2s ease, box-shadow 0.2s ease;
}

.gallery-item:hover {
  transform: scale(1.03);
  box-shadow: 0 0 20px rgba(0, 232, 255, 0.5);
  z-index: 1;
}

.gallery-item img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  display: block;
  pointer-events: none;
}

.gallery-lightbox {
  position: absolute;
  inset: 0;
  z-index: 5;
  background: #000;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  padding: 1.5% 1.5% 2%;
  animation: panelIn 0.35s ease both;
}

.gallery-lightbox[hidden] {
  display: none !important;
}

.gallery-lightbox img {
  max-width: 100%;
  max-height: 92%;
  width: auto;
  height: auto;
  object-fit: contain;
  border-radius: 2px;
  box-shadow: 0 0 30px rgba(177, 76, 255, 0.35);
}

.lightbox-caption {
  margin: 0.35rem 0 0;
  font-size: clamp(0.5rem, 1.4vw, 0.68rem);
  color: var(--muted);
  letter-spacing: 0.06em;
}

.lightbox-close {
  position: absolute;
  top: 2%;
  right: 2%;
  width: 1.75rem;
  height: 1.75rem;
  border: 1px solid rgba(255, 255, 255, 0.25);
  border-radius: 50%;
  background: rgba(0, 0, 0, 0.55);
  color: var(--text);
  cursor: pointer;
  font-size: 0.8rem;
  line-height: 1;
  transition: border-color 0.15s, box-shadow 0.15s;
  z-index: 6;
}

.lightbox-close:hover {
  border-color: var(--pink);
  box-shadow: 0 0 12px rgba(255, 46, 159, 0.5);
}

/* Services — content centered in the remaining glass under the header */
.panel-services {
  background: #05050c;
}

.services-body {
  flex: 1 1 auto;
  min-height: 0;
  padding: 0.5% 4% 2%;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  text-align: center;
  overflow-y: auto;
}

.services-lead {
  margin: 0 0 0.55em;
  max-width: 36em;
  text-align: center;
  font-size: clamp(0.52rem, 1.6vw, 0.72rem);
  line-height: 1.4;
  color: var(--muted);
}

.services-list {
  list-style: none;
  margin: 0;
  padding: 0;
  width: min(100%, 28rem);
  display: grid;
  gap: 0.4rem;
}

.service-card {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 0.15rem;
  text-align: center;
  background: rgba(255, 255, 255, 0.05);
  border: 1px solid rgba(177, 76, 255, 0.4);
  border-radius: 10px;
  padding: 0.5rem 0.65rem;
  box-shadow: 0 0 14px rgba(177, 76, 255, 0.1);
}

.service-title {
  font-family: var(--font-game);
  font-size: clamp(0.58rem, 1.7vw, 0.78rem);
  letter-spacing: 0.06em;
  text-transform: uppercase;
  color: var(--cyan);
}

.service-desc {
  font-size: clamp(0.5rem, 1.45vw, 0.68rem);
  line-height: 1.35;
  color: var(--text);
}

.services-foot {
  margin: 0.55em 0 0;
  text-align: center;
  font-size: clamp(0.45rem, 1.2vw, 0.58rem);
  letter-spacing: 0.08em;
  text-transform: uppercase;
  color: var(--muted);
}

/* Social preview — full glass, no scroll: static profile snapshot + open/back bar */
.panel-social {
  padding: 0;
  overflow: hidden;
  background: #060610;
}

.social-preview-frame {
  position: absolute;
  inset: 0;
  display: flex;
  flex-direction: column;
  overflow: hidden;
}

.social-preview-img {
  flex: 1 1 auto;
  min-height: 0;
  width: 100%;
  height: 100%;
  object-fit: cover;
  object-position: top center;
  display: block;
  background: #0a0a12;
  pointer-events: none;
  user-select: none;
}

.social-preview-img.is-missing {
  display: none;
}

.social-preview-fallback {
  flex: 1 1 auto;
  min-height: 0;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  text-align: center;
  padding: 4%;
  background:
    radial-gradient(ellipse 70% 55% at 50% 40%, rgba(0, 100, 140, 0.3), transparent 70%),
    #060610;
}

.social-preview-fallback[hidden] {
  display: none !important;
}

.social-icon-lg {
  font-size: clamp(1.8rem, 5.5vw, 2.6rem);
  margin-bottom: 0.4rem;
  filter: drop-shadow(0 0 12px rgba(0, 232, 255, 0.45));
}

.social-handle {
  margin: 0.25rem 0 0.5rem;
  font-family: var(--font-game);
  letter-spacing: 0.12em;
  color: var(--cyan);
  font-size: clamp(0.7rem, 2.2vw, 0.95rem);
}

.social-blurb {
  margin: 0;
  font-size: clamp(0.58rem, 1.6vw, 0.78rem);
  color: var(--muted);
  line-height: 1.4;
  max-width: 28em;
}

.social-preview-bar {
  flex: 0 0 auto;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 0.5rem;
  padding: 2.5% 3%;
  background: linear-gradient(180deg, rgba(6, 6, 16, 0.2), rgba(6, 6, 16, 0.95) 30%, #060610);
  border-top: 1px solid rgba(0, 232, 255, 0.18);
  z-index: 2;
}

.social-preview-label {
  font-family: var(--font-game);
  font-size: clamp(0.5rem, 1.6vw, 0.72rem);
  letter-spacing: 0.08em;
  color: var(--cyan);
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
  min-width: 0;
}

.social-actions {
  display: flex;
  flex-wrap: nowrap;
  gap: 0.4rem;
  justify-content: flex-end;
  flex: 0 0 auto;
}

.social-open,
.social-back {
  font-family: var(--font-game);
  font-size: clamp(0.48rem, 1.35vw, 0.65rem);
  letter-spacing: 0.08em;
  text-transform: uppercase;
  padding: 0.4rem 0.7rem;
  border-radius: 999px;
  cursor: pointer;
  text-decoration: none;
  border: 1px solid transparent;
  transition: transform 0.15s ease, box-shadow 0.15s ease;
  white-space: nowrap;
}

.social-open {
  color: #05050a;
  background: linear-gradient(90deg, var(--cyan), var(--purple));
}

.social-open:hover {
  transform: translateY(-2px) scale(1.03);
  box-shadow: 0 0 18px rgba(0, 232, 255, 0.5);
}

.social-back {
  color: var(--text);
  background: transparent;
  border-color: rgba(255, 255, 255, 0.25);
}

.social-back:hover {
  border-color: var(--pink);
  box-shadow: 0 0 12px rgba(255, 46, 159, 0.35);
  transform: translateY(-1px);
}

/* ---------- Main buttons — real arcade ovals (lineart wells) ----------
   Wide ellipse matches lineart holes. ONE inner neon ring only (no double-ring
   with cutout art). Big readable labels. Glow lives inside the hole.
*/
.cab-btn {
  --btn-neon: var(--cyan);
  --btn-neon-soft: rgba(46, 230, 239, 0.55);
  --btn-face: #12141c;
  position: absolute;
  z-index: 10;
  width: 15.2%;
  height: 7.15%;
  /* Scale label text to the hole size (works on phone + desktop) */
  container-type: size;
  container-name: cab-btn;
  /* Thick even rim — same on all 3 buttons */
  border: 4px solid var(--btn-neon);
  border-radius: 50%;
  cursor: pointer;
  padding: 0 0.08em;
  display: flex;
  align-items: center;
  justify-content: center;
  transform: translate(-50%, -50%);
  text-align: center;
  line-height: 1.05;
  transition:
    transform 0.18s cubic-bezier(0.22, 1, 0.36, 1),
    filter 0.18s ease,
    box-shadow 0.18s ease,
    border-color 0.18s ease;
  -webkit-tap-highlight-color: transparent;
  appearance: none;
  background:
    radial-gradient(ellipse 65% 55% at 50% 38%, rgba(255, 255, 255, 0.16), transparent 55%),
    radial-gradient(ellipse 90% 85% at 50% 55%, #1c1e28 0%, var(--btn-face) 55%, #07080c 100%);
  /* Even glow all around (no top/bottom bias — was making tops look odd) */
  box-shadow:
    inset 0 0 12px rgba(0, 0, 0, 0.45),
    inset 0 0 8px var(--btn-neon-soft),
    0 0 0 1px color-mix(in srgb, var(--btn-neon) 50%, transparent),
    0 0 12px var(--btn-neon-soft),
    0 0 24px color-mix(in srgb, var(--btn-neon) 40%, transparent);
  animation: btnFacePulse var(--pulse-fast) ease-in-out infinite;
}

/* Even inner ring — same treatment all 3 colors */
.cab-btn::before {
  content: "";
  position: absolute;
  inset: 6%;
  border-radius: 50%;
  pointer-events: none;
  border: 2px solid color-mix(in srgb, var(--btn-neon) 75%, #fff);
  box-shadow:
    0 0 8px var(--btn-neon-soft),
    inset 0 0 8px var(--btn-neon-soft);
  opacity: 0.9;
  transition: inset 0.18s ease, box-shadow 0.18s ease, opacity 0.18s ease;
}

.cab-btn-label {
  position: relative;
  z-index: 1;
  font-family: var(--font-button);
  /* ~18% of button’s shorter side → fits 2 lines inside the oval on any screen */
  font-size: clamp(0.4rem, 18cqmin, 0.92rem);
  font-weight: 400;
  letter-spacing: 0.04em;
  line-height: 1.02;
  max-width: 92%;
  pointer-events: none;
  text-transform: uppercase;
  font-style: normal;
  transition: transform 0.18s ease, text-shadow 0.18s ease;
}

/* Gallery | Get Basted | Services — lowered + widened */
.cab-btn-gallery {
  left: 30.83%;
  top: 62.5%;
  --btn-neon: #2ee6ef;
  --btn-neon-soft: rgba(46, 230, 239, 0.55);
  animation-delay: 0s;
}

.cab-btn-gallery .cab-btn-label {
  color: #b8fbff;
  text-shadow:
    0 0 5px rgba(46, 230, 239, 1),
    0 0 12px rgba(46, 230, 239, 0.7),
    0 1px 2px rgba(0, 0, 0, 0.9);
}

/* L→R matches neon zones: cyan | purple | pink */
.cab-btn-contact {
  left: 50%;
  top: 62.7%;
  --btn-neon: #b14cff;
  --btn-neon-soft: rgba(177, 76, 255, 0.55);
  animation-delay: 0.15s;
}

.cab-btn-contact .cab-btn-label {
  color: #e8d0ff;
  text-shadow:
    0 0 5px rgba(177, 76, 255, 1),
    0 0 12px rgba(177, 76, 255, 0.7),
    0 1px 2px rgba(0, 0, 0, 0.9);
}

.cab-btn-services {
  left: 69.17%;
  top: 62.5%;
  --btn-neon: #ff4eb8;
  --btn-neon-soft: rgba(255, 78, 184, 0.55);
  animation-delay: 0.3s;
}

.cab-btn-services .cab-btn-label {
  color: #ffd0ec;
  text-shadow:
    0 0 5px rgba(255, 78, 184, 1),
    0 0 12px rgba(255, 78, 184, 0.7),
    0 1px 2px rgba(0, 0, 0, 0.9);
}

@keyframes btnFacePulse {
  0%,
  100% {
    border-color: color-mix(in srgb, var(--btn-neon) 90%, #fff);
    box-shadow:
      inset 0 0 12px rgba(0, 0, 0, 0.45),
      inset 0 0 8px var(--btn-neon-soft),
      0 0 0 1px color-mix(in srgb, var(--btn-neon) 45%, transparent),
      0 0 12px var(--btn-neon-soft),
      0 0 22px color-mix(in srgb, var(--btn-neon) 35%, transparent);
  }
  50% {
    border-color: var(--btn-neon);
    box-shadow:
      inset 0 0 12px rgba(0, 0, 0, 0.4),
      inset 0 0 12px var(--btn-neon-soft),
      0 0 0 1.5px color-mix(in srgb, var(--btn-neon) 70%, transparent),
      0 0 16px var(--btn-neon-soft),
      0 0 30px color-mix(in srgb, var(--btn-neon) 50%, transparent);
  }
}

.cab-btn:hover,
.cab-btn:focus-visible {
  transform: translate(-50%, -50%) scale(1.04);
  filter: brightness(1.15) saturate(1.1);
  outline: none;
  z-index: 12;
  animation: none;
  border-width: 4.5px;
  box-shadow:
    inset 0 0 12px rgba(0, 0, 0, 0.35),
    inset 0 0 14px var(--btn-neon-soft),
    0 0 0 1.5px var(--btn-neon),
    0 0 18px var(--btn-neon-soft),
    0 0 32px color-mix(in srgb, var(--btn-neon) 50%, transparent);
}

.cab-btn:hover::before,
.cab-btn:focus-visible::before {
  inset: 5%;
  opacity: 1;
  border-width: 2.5px;
  box-shadow:
    0 0 10px var(--btn-neon-soft),
    inset 0 0 12px var(--btn-neon-soft);
}

.cab-btn:hover .cab-btn-label,
.cab-btn:focus-visible .cab-btn-label {
  transform: scale(1.05);
}

.cab-btn:active {
  transform: translate(-50%, -50%) scale(0.96);
  filter: brightness(0.95);
}

.cab-btn.is-active {
  filter: brightness(1.12);
  border-width: 4.5px;
  box-shadow:
    inset 0 0 12px rgba(0, 0, 0, 0.4),
    inset 0 0 14px var(--btn-neon-soft),
    0 0 0 1.5px var(--btn-neon),
    0 0 16px var(--btn-neon-soft),
    0 0 28px color-mix(in srgb, var(--btn-neon) 45%, transparent);
}

.cab-btn.is-active::before {
  opacity: 1;
}

/* ---------- Social buttons (rounded-square cutouts) ---------- */
.social-btn {
  position: absolute;
  z-index: 10;
  /* Fill measured social wells */
  width: 7.57%;
  height: 5.13%;
  transform: translate(-50%, -50%);
  border: none;
  border-radius: 18%;
  cursor: pointer;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: clamp(0.8rem, 2.6vw, 1.25rem);
  color: #fff;
  background: radial-gradient(circle at 35% 30%, rgba(255, 255, 255, 0.12), transparent 50%), #0c0c14;
  box-shadow:
    inset 0 0 0 1px rgba(255, 255, 255, 0.14),
    0 0 8px rgba(0, 232, 255, 0.35),
    0 0 16px rgba(177, 76, 255, 0.2),
    0 2px 6px rgba(0, 0, 0, 0.4);
  animation: socialPulse var(--pulse-slow) ease-in-out infinite;
  transition:
    transform 0.2s cubic-bezier(0.22, 1, 0.36, 1),
    box-shadow 0.2s ease,
    filter 0.2s ease,
    color 0.2s ease;
  -webkit-tap-highlight-color: transparent;
  appearance: none;
  padding: 0;
}

@keyframes socialPulse {
  0%,
  100% {
    box-shadow:
      inset 0 0 0 1px rgba(255, 255, 255, 0.12),
      0 0 6px rgba(0, 232, 255, 0.28),
      0 0 12px rgba(177, 76, 255, 0.15),
      0 2px 6px rgba(0, 0, 0, 0.4);
    filter: brightness(0.95);
  }
  50% {
    box-shadow:
      inset 0 0 0 1px rgba(255, 255, 255, 0.22),
      0 0 12px rgba(0, 232, 255, 0.55),
      0 0 22px rgba(177, 76, 255, 0.35),
      0 2px 8px rgba(0, 0, 0, 0.4);
    filter: brightness(1.08);
  }
}

/* Positions — left col good; mid slight left; right col more left (glow balance) */
.social-instagram {
  left: 38.22%;
  top: 77.36%;
  animation-delay: 0s;
}
.social-x {
  left: 49.95%;
  top: 77.36%;
  animation-delay: 0.25s;
}
.social-tiktok {
  left: 61.72%;
  top: 77.36%;
  animation-delay: 0.5s;
}
.social-youtube {
  left: 38.22%;
  top: 84.5%;
  animation-delay: 0.75s;
}
.social-facebook {
  left: 49.95%;
  top: 84.5%;
  animation-delay: 1s;
}
.social-pinterest {
  left: 61.72%;
  top: 84.5%;
  animation-delay: 1.25s;
}

.social-btn:hover,
.social-btn:focus-visible {
  transform: translate(-50%, calc(-50% - 3px)) scale(1.14);
  outline: none;
  z-index: 12;
  filter: brightness(1.15);
  animation: none; /* solid glow on hover, no pulse fight */
}

.social-instagram:hover,
.social-instagram:focus-visible {
  color: #e1306c;
  box-shadow:
    0 0 0 2px rgba(225, 48, 108, 0.7),
    0 0 22px rgba(225, 48, 108, 0.65),
    0 8px 16px rgba(0, 0, 0, 0.45);
}

.social-x:hover,
.social-x:focus-visible {
  color: #fff;
  box-shadow:
    0 0 0 2px rgba(255, 255, 255, 0.55),
    0 0 22px rgba(0, 232, 255, 0.45),
    0 8px 16px rgba(0, 0, 0, 0.45);
}

.social-tiktok:hover,
.social-tiktok:focus-visible {
  color: #69c9d0;
  box-shadow:
    0 0 0 2px rgba(105, 201, 208, 0.7),
    0 0 22px rgba(238, 29, 82, 0.45),
    0 8px 16px rgba(0, 0, 0, 0.45);
}

.social-youtube:hover,
.social-youtube:focus-visible {
  color: #ff0000;
  box-shadow:
    0 0 0 2px rgba(255, 0, 0, 0.7),
    0 0 22px rgba(255, 0, 0, 0.55),
    0 8px 16px rgba(0, 0, 0, 0.45);
}

.social-facebook:hover,
.social-facebook:focus-visible {
  color: #1877f2;
  box-shadow:
    0 0 0 2px rgba(24, 119, 242, 0.75),
    0 0 22px rgba(24, 119, 242, 0.55),
    0 8px 16px rgba(0, 0, 0, 0.45);
}

.social-pinterest:hover,
.social-pinterest:focus-visible {
  color: #e60023;
  box-shadow:
    0 0 0 2px rgba(230, 0, 35, 0.75),
    0 0 22px rgba(230, 0, 35, 0.55),
    0 8px 16px rgba(0, 0, 0, 0.45);
}

.social-btn:active {
  transform: translate(-50%, -50%) scale(1.02);
}

/*
  Mobile + short glass: zero-scroll contact.
  Everything must fit inside the monitor cutout — no overflow scroll.
*/
@media (max-width: 560px) {
  .panel-contact {
    overflow: hidden;
  }

  .contact-chrome {
    padding: 0.6% 2% 0;
  }

  .contact-chrome .gallery-hint {
    font-size: clamp(0.38rem, 2.2vw, 0.48rem);
    letter-spacing: 0.06em;
    margin-top: 0.1em;
    line-height: 1.2;
  }

  .panel-contact .panel-heading.sm {
    font-size: clamp(0.55rem, 3.2vw, 0.72rem);
  }

  .contact-body.panel-scroll,
  .contact-body {
    padding: 0.6% 2.5% 1.2%;
    overflow: hidden !important; /* no scroll — fit to glass */
    height: auto;
  }

  .contact-grid {
    grid-template-columns: 1fr 1fr;
    gap: 0.22rem;
    margin-bottom: 0.28rem;
    flex: 0 0 auto;
  }

  .contact-card {
    padding: 0.18rem 0.28rem;
    border-radius: 4px;
    font-size: clamp(0.36rem, 2.2vw, 0.48rem);
    gap: 0.04rem;
    min-width: 0;
  }

  .contact-label {
    font-size: 0.5em;
    letter-spacing: 0.06em;
  }

  .contact-card a,
  .contact-card span:not(.contact-label) {
    overflow: hidden;
    text-overflow: ellipsis;
    white-space: nowrap;
  }

  .contact-form {
    gap: 0.22rem;
    flex: 1 1 auto;
    min-height: 0;
    /* name/email | message (fills) | submit — all visible, no scroll */
    grid-template-rows: auto minmax(1.8em, 1fr) auto;
  }

  .contact-form label {
    font-size: clamp(0.36rem, 2.1vw, 0.48rem);
    gap: 0.06rem;
  }

  /* Hide field labels on tiny glass — placeholders carry the meaning */
  .contact-form label > span {
    display: none;
  }

  .contact-form input,
  .contact-form textarea {
    padding: 0.28rem 0.35rem;
    font-size: clamp(0.4rem, 2.3vw, 0.52rem);
    border-radius: 4px;
    resize: none; /* prevent drag-resize causing overflow */
  }

  .contact-form textarea {
    min-height: 0;
    height: 100%;
    box-sizing: border-box;
  }

  .contact-form label.full {
    min-height: 0;
    height: 100%;
  }

  .contact-submit {
    margin-top: 0;
    padding: 0.32rem 0.4rem;
    font-size: clamp(0.42rem, 2.4vw, 0.55rem);
    letter-spacing: 0.08em;
    border-radius: 4px;
  }

  .form-note {
    margin: 0.2rem 0 0;
    font-size: clamp(0.36rem, 2vw, 0.48rem);
  }

  /* Phone: slightly tighter than desktop cqmin so ovals don’t overflow */
  .cab-btn-label {
    font-size: clamp(0.32rem, 15cqmin, 0.58rem);
    letter-spacing: 0.02em;
    line-height: 1.0;
    max-width: 90%;
  }

  .cab-btn {
    padding: 0 0.04em;
    border-width: 3px;
  }
}

/* Extra-tight when the monitor glass itself is short */
@container arcade-screen (max-height: 280px) {
  .panel-contact {
    overflow: hidden;
  }

  .contact-chrome {
    padding: 0.4% 1.5% 0;
  }

  .contact-chrome .gallery-hint {
    display: none; /* reclaim a full line of height */
  }

  .panel-contact .panel-heading.sm {
    font-size: clamp(0.5rem, 4cqi, 0.7rem);
  }

  .contact-body {
    padding: 0.5% 2% 1%;
    overflow: hidden;
  }

  .contact-grid {
    gap: 0.18rem;
    margin-bottom: 0.2rem;
  }

  .contact-card {
    padding: 0.12rem 0.22rem;
    font-size: clamp(0.32rem, 2.8cqi, 0.45rem);
  }

  .contact-form {
    gap: 0.16rem;
    grid-template-rows: auto minmax(1.4em, 1fr) auto;
  }

  .contact-form label > span {
    display: none;
  }

  .contact-form input,
  .contact-form textarea {
    padding: 0.2rem 0.28rem;
    font-size: clamp(0.36rem, 3cqi, 0.5rem);
    resize: none;
  }

  .contact-form textarea {
    min-height: 0;
    height: 100%;
  }

  .contact-form label.full {
    min-height: 0;
    height: 100%;
  }

  .contact-submit {
    padding: 0.26rem 0.35rem;
    font-size: clamp(0.38rem, 3.2cqi, 0.52rem);
  }
}

/* Reduce motion */
@media (prefers-reduced-motion: reduce) {
  .gallery-track,
  .gallery-item,
  .marquee-logo,
  .social-btn,
  .cab-btn {
    animation: none !important;
  }

  .panel.active,
  .welcome-inner {
    animation: none;
    opacity: 1;
  }

  .panel-welcome .game-title,
  .panel-welcome .welcome-sub,
  .welcome-logo-anim,
  .welcome-logo-layer {
    transition: none !important;
  }

  .panel-welcome.welcome-logo-ready .welcome-logo-layer .welcome-logo-anim {
    opacity: 1 !important;
  }

  .panel-welcome.welcome-logo-docked .game-title,
  .panel-welcome.welcome-logo-docked .welcome-sub,
  .panel-welcome.welcome-logo-docked .welcome-logo-anim {
    opacity: 1 !important;
    transform: none !important;
  }

  .marquee-logo,
  .marquee-steak {
    animation: none !important;
    opacity: 1;
    filter:
      drop-shadow(0 0 5px rgba(46, 230, 239, 0.7))
      drop-shadow(0 0 12px rgba(123, 61, 255, 0.45));
  }

  .cab-btn::before {
    animation: none !important;
    opacity: 1;
  }
}
