/* ==========================================================================
   RESPAWN CAFE — UI POLISH LAYER
   Loaded AFTER style.css. Refines rhythm, depth, typography, motion & a11y
   without rewriting the base stylesheet.
   ========================================================================== */

:root {
  /* Fluid spacing scale */
  --sp-2xs: clamp(0.25rem, 0.2rem + 0.25vw, 0.375rem);
  --sp-xs: clamp(0.5rem, 0.4rem + 0.5vw, 0.75rem);
  --sp-sm: clamp(0.75rem, 0.6rem + 0.75vw, 1.125rem);
  --sp-md: clamp(1rem, 0.8rem + 1vw, 1.5rem);
  --sp-lg: clamp(1.5rem, 1.2rem + 1.5vw, 2.25rem);
  --sp-xl: clamp(2rem, 1.6rem + 2vw, 3rem);
  --sp-2xl: clamp(3rem, 2.4rem + 3vw, 4.5rem);

  /* Elevation scale — layered, not one giant blur */
  --e1: 0 1px 2px rgba(0, 0, 0, 0.5);
  --e2: 0 2px 4px rgba(0, 0, 0, 0.45), 0 6px 14px rgba(0, 0, 0, 0.4);
  --e3: 0 2px 6px rgba(0, 0, 0, 0.5), 0 12px 28px rgba(0, 0, 0, 0.5);
  --e4: 0 4px 10px rgba(0, 0, 0, 0.55), 0 24px 56px rgba(0, 0, 0, 0.6);

  /* Motion */
  --dur-fast: 140ms;
  --dur-mid: 260ms;
  --dur-slow: 520ms;
  --ease-out: cubic-bezier(0.22, 1, 0.36, 1);
  --ease-spring: cubic-bezier(0.34, 1.4, 0.64, 1);

  /* Surfaces — slightly cooler and more consistent than the mixed rgba values */
  --surface-1: rgba(14, 14, 19, 0.72);
  --surface-2: rgba(20, 20, 27, 0.86);
  --hairline: rgba(255, 255, 255, 0.08);
  --hairline-strong: rgba(255, 255, 255, 0.16);

  /* Focus ring */
  --ring: #FF5A52;
}

::selection {
  background: rgba(217, 38, 38, 0.5);
  color: #fff;
}

/* --------------------------------------------------------------------------
   1. LAYOUT RHYTHM — fluid section padding instead of a flat 90px
   -------------------------------------------------------------------------- */
.container {
  max-width: 1240px;
  padding-inline: clamp(20px, 4vw, 40px);
}

.section {
  padding-block: clamp(64px, 8vw, 128px);
}

/* The hero owns its own vertical space */
.hero-section {
  padding-top: clamp(104px, 14vh, 148px);
  padding-bottom: var(--sp-xl);
}

/* Section headings had no spacing rule at all — content sat right under them */
.section-heading {
  margin-bottom: clamp(36px, 5vw, 64px);
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: var(--sp-xs);
}

.section-heading.text-left {
  align-items: flex-start;
}

.section-heading .pill-badge-red {
  margin-bottom: var(--sp-2xs);
}

/* --------------------------------------------------------------------------
   2. TYPOGRAPHY — tighter scale, better measure, less muddy shadow
   -------------------------------------------------------------------------- */
.section-title {
  font-size: clamp(2rem, 1.35rem + 2.7vw, 3.5rem);
  line-height: 1.04;
  letter-spacing: -0.035em;
  text-wrap: balance;
  /* Was a 20px blur at 95% black — read as smudge over the animated canvas */
  text-shadow: 0 2px 14px rgba(0, 0, 0, 0.75);
}

.section-subtitle {
  max-width: 60ch;
  font-size: clamp(0.98rem, 0.94rem + 0.3vw, 1.12rem);
  line-height: 1.62;
  color: #A3AEBE;
  text-wrap: pretty;
  text-shadow: 0 1px 8px rgba(0, 0, 0, 0.7);
}

.pill-badge-red {
  font-size: 0.68rem;
  letter-spacing: 0.14em;
  padding: 5px 14px;
  background: linear-gradient(180deg, rgba(217, 38, 38, 0.16), rgba(217, 38, 38, 0.06));
  box-shadow: inset 0 1px 0 rgba(255, 255, 255, 0.06);
}

/* --------------------------------------------------------------------------
   3. DEPTH — real card system: hairline top highlight + lift on hover
   -------------------------------------------------------------------------- */
.glass-hud {
  border-radius: 18px;
  background: var(--surface-1);
  border-color: var(--hairline);
  box-shadow: var(--e3), inset 0 1px 0 rgba(255, 255, 255, 0.055);
  transition:
    transform var(--dur-mid) var(--ease-out),
    border-color var(--dur-mid) var(--ease-out),
    box-shadow var(--dur-mid) var(--ease-out),
    background var(--dur-mid) var(--ease-out);
}

/* Base hover previously changed colour but never moved — felt inert */
.glass-hud:hover {
  background: var(--surface-2);
  border-color: var(--hairline-strong);
  box-shadow: var(--e4), inset 0 1px 0 rgba(255, 255, 255, 0.09);
}

/* Only lift the cards that are actual content tiles */
.venue-card:hover,
.pass-compact-card:hover,
.game-price-card:hover,
.hud-card:hover,
.astat-card:hover {
  transform: translateY(-5px);
}

/* Modals and panels shouldn't react to hover like content tiles */
.booking-modal-card:hover,
.wave-confirmation-card:hover,
.dropdown-menu-panel:hover,
.mobile-popover-menu:hover {
  transform: none;
  background: var(--surface-2);
  box-shadow: var(--e4), inset 0 1px 0 rgba(255, 255, 255, 0.06);
}

/* Featured pass / price card: one clear focal point per grid */
.pass-compact-card.featured,
.game-price-card.featured {
  border-color: rgba(217, 38, 38, 0.7);
  background:
    linear-gradient(180deg, rgba(217, 38, 38, 0.1), rgba(217, 38, 38, 0) 42%),
    var(--surface-2);
  box-shadow:
    var(--e4),
    0 0 0 1px rgba(217, 38, 38, 0.28),
    0 14px 44px rgba(217, 38, 38, 0.16),
    inset 0 1px 0 rgba(255, 255, 255, 0.09);
}

.pass-compact-card.featured:hover,
.game-price-card.featured:hover {
  border-color: var(--primary-red);
  box-shadow:
    var(--e4),
    0 0 0 1px rgba(217, 38, 38, 0.45),
    0 18px 56px rgba(217, 38, 38, 0.26),
    inset 0 1px 0 rgba(255, 255, 255, 0.12);
}

/* Venue image: gradient scrim so overlaid text/badges always read */
.venue-image-wrap::after {
  content: '';
  position: absolute;
  inset: 0;
  background: linear-gradient(180deg, rgba(0, 0, 0, 0.35) 0%, transparent 38%, rgba(6, 6, 8, 0.72) 100%);
  pointer-events: none;
}

.venue-img {
  transition: transform 0.7s var(--ease-out);
}

.venue-card:hover .venue-img {
  transform: scale(1.06);
}

.venue-info {
  padding: var(--sp-md);
  gap: 10px;
}

.venue-title {
  font-size: 1.2rem;
  letter-spacing: -0.015em;
}

.venue-desc {
  font-size: 0.87rem;
  line-height: 1.55;
  color: #98A3B4;
}

.venue-tags span {
  background: rgba(255, 255, 255, 0.045);
  border-color: var(--hairline);
  padding: 4px 11px;
  transition: color var(--dur-fast) var(--ease-out), border-color var(--dur-fast) var(--ease-out);
}

.venue-card:hover .venue-tags span {
  border-color: rgba(217, 38, 38, 0.35);
  color: #D6DEE9;
}

/* --------------------------------------------------------------------------
   4. HERO — clean subtitle, deeper scrim, real CTAs
   -------------------------------------------------------------------------- */

/* The base filter dimmed the photo to 80% brightness, then two stacked scrims
   sat on top of it — the gamers were barely visible. Let the photo through. */
.hero-gamers-image {
  filter: contrast(1.04) brightness(1.02) saturate(0.96);
}

/* Scrim is now localised: soft pool behind the headline, thin wash under the
   nav, and a fade into the page at the bottom. The middle stays clear. */
.hero-bg-overlay {
  background:
    radial-gradient(ellipse 72% 52% at 50% 40%, rgba(6, 6, 8, 0.52) 0%, rgba(6, 6, 8, 0.2) 58%, transparent 80%),
    linear-gradient(180deg, rgba(6, 6, 8, 0.58) 0%, rgba(6, 6, 8, 0.06) 20%, rgba(6, 6, 8, 0.08) 58%, rgba(6, 6, 8, 0.82) 92%, #060608 100%);
}

.hero-gaming-title {
  letter-spacing: -0.045em;
  line-height: 0.9;
}

/* Bottom of the gradient was mid-grey (#64748B) — muddy now that the photo
   behind it is brighter. Keep the whole word in the bright range. */
.title-respawn {
  background: linear-gradient(180deg, #FFFFFF 18%, #E2E8F0 56%, #A3B0C2 100%);
  -webkit-background-clip: text;
  background-clip: text;
  -webkit-text-fill-color: transparent;
}

.title-cafe {
  background: linear-gradient(180deg, #FF4A44 0%, #E11D28 52%, #9F1239 100%);
  -webkit-background-clip: text;
  background-clip: text;
  -webkit-text-fill-color: transparent;
  filter: drop-shadow(0 0 22px rgba(220, 38, 38, 0.5));
}

/* The subtitle was boxed in a blurred pill — reads as a UI chip, not a tagline */
.hero-gaming-sub {
  background: none;
  border: none;
  box-shadow: none;
  backdrop-filter: none;
  -webkit-backdrop-filter: none;
  padding: 0;
  margin-top: var(--sp-sm);
  max-width: 34ch;
  font-weight: 500;
  color: #CFD7E2;
  letter-spacing: 0.005em;
  /* Brighter photo behind it now, so the text carries its own contrast */
  text-shadow: 0 1px 3px rgba(0, 0, 0, 0.95), 0 3px 18px rgba(0, 0, 0, 0.85);
}

/* Small proof row under the headline */
.hero-trust-row {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  justify-content: center;
  gap: var(--sp-xs) var(--sp-md);
  margin-top: var(--sp-lg);
  font-family: var(--font-tech);
  font-size: 0.74rem;
  font-weight: 700;
  letter-spacing: 0.1em;
  text-transform: uppercase;
  color: #9DAABB;
  text-shadow: 0 1px 3px rgba(0, 0, 0, 0.95), 0 2px 12px rgba(0, 0, 0, 0.8);
}

.hero-trust-row span {
  display: inline-flex;
  align-items: center;
  gap: 7px;
  white-space: nowrap;
}

.hero-trust-row i {
  color: var(--primary-red);
  font-size: 0.8rem;
}

.hero-trust-sep {
  width: 1px;
  height: 12px;
  background: var(--hairline-strong);
}

/* Posters: tighter footprint so the new CTAs fit the first viewport */
.floating-game-posters-wrap {
  height: clamp(190px, 25vh, 290px);
  margin: var(--sp-md) 0 var(--sp-xs);
}

.poster-card-inner {
  width: clamp(112px, 11vw, 152px);
  height: auto;
  aspect-ratio: 2 / 3;
  border-width: 1px;
  border-color: rgba(255, 255, 255, 0.14);
  border-radius: 16px;
  box-shadow: var(--e4), inset 0 1px 0 rgba(255, 255, 255, 0.12);
}

/* Was a hard 18% white wash across the whole poster */
.poster-shine {
  background: linear-gradient(140deg, rgba(255, 255, 255, 0.16) 0%, rgba(255, 255, 255, 0.03) 28%, transparent 55%);
}

.poster-label {
  font-size: 0.68rem;
  letter-spacing: 0.12em;
  background: rgba(10, 10, 14, 0.82);
  backdrop-filter: blur(10px);
  -webkit-backdrop-filter: blur(10px);
}

/* Gentle idle drift — subtle enough to read as depth, not decoration */
.poster-fc26,
.poster-apex {
  animation: posterDrift 7s var(--ease-out) infinite alternate;
}

.poster-gtav,
.poster-warzone {
  animation: posterDrift 8.5s var(--ease-out) infinite alternate-reverse;
}

.poster-spiderman,
.poster-valorant {
  animation: posterDrift 7.8s var(--ease-out) infinite alternate;
}

@keyframes posterDrift {
  from {
    translate: 0 0;
  }

  to {
    translate: 0 -10px;
  }
}

.game-poster-card:hover {
  animation-play-state: paused;
}

.scroll-prompt-text {
  font-family: var(--font-tech);
  font-size: 0.74rem;
  font-weight: 700;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  color: #93A0B4;
  text-shadow: 0 1px 3px rgba(0, 0, 0, 0.95), 0 2px 12px rgba(0, 0, 0, 0.8);
}

/* Posters used to snap upright on hover because the hover transform replaced
   the rotate(). Split rotation/scale/translate into independent properties. */
.poster-fc26,
.poster-apex {
  transform: none;
  rotate: -12deg;
}

.poster-gtav,
.poster-warzone {
  transform: none;
  rotate: -2deg;
}

.poster-spiderman,
.poster-valorant {
  transform: none;
  rotate: 10deg;
}

.game-poster-card {
  transition: scale var(--dur-mid) var(--ease-spring), rotate var(--dur-mid) var(--ease-out);
}

.game-poster-card:hover {
  transform: none !important;
  scale: 1.07;
  rotate: 0deg;
}

/* --------------------------------------------------------------------------
   5. NAVIGATION — calmer primary button, crisper glass
   -------------------------------------------------------------------------- */
.top-nav {
  transition: background var(--dur-mid) var(--ease-out), box-shadow var(--dur-mid) var(--ease-out),
    border-color var(--dur-mid) var(--ease-out);
}

/* The white button was blown out by a 24px pure-white glow */
.nav-primary-btn {
  min-height: 40px;
  letter-spacing: 0.045em;
  box-shadow: var(--e2), inset 0 1px 0 rgba(255, 255, 255, 0.9);
  transition:
    transform var(--dur-mid) var(--ease-spring),
    box-shadow var(--dur-mid) var(--ease-out),
    background var(--dur-mid) var(--ease-out);
}

.nav-primary-btn:hover {
  transform: translateY(-2px);
  box-shadow: var(--e3), 0 0 22px rgba(255, 255, 255, 0.3), 0 0 12px rgba(217, 38, 38, 0.28);
}

@media (min-width: 980px) {
  .top-nav.scrolled .nav-container {
    max-width: 1260px !important;
    width: max-content !important;
    min-width: min(100%, 960px) !important;
    padding: 0 20px !important;
    gap: 16px !important;
  }
}

@media (max-width: 979px) {
  .top-nav.scrolled .nav-container {
    width: 100% !important;
    min-width: 0 !important;
    padding: 0 14px !important;
    gap: 8px !important;
  }
}

.nav-menu-links {
  flex-shrink: 0 !important;
  white-space: nowrap !important;
  flex-wrap: nowrap !important;
}

.nav-link,
.nav-link span,
.dropdown-trigger,
.nav-actions,
.nav-support-pill,
.nav-brand,
.brand-logo-main {
  white-space: nowrap !important;
  text-wrap: nowrap !important;
  flex-shrink: 0 !important;
}

.nav-link {
  transition: color var(--dur-fast) var(--ease-out), background var(--dur-fast) var(--ease-out);
}

.dropdown-menu-panel,
.mobile-popover-menu {
  box-shadow: var(--e4), inset 0 1px 0 rgba(255, 255, 255, 0.06);
}

.dropdown-item {
  border-radius: 12px;
  transition: background var(--dur-fast) var(--ease-out), translate var(--dur-fast) var(--ease-out);
}

.dropdown-item:hover {
  translate: 3px 0;
}

/* --------------------------------------------------------------------------
   6. ACCESSIBILITY — focus ring, touch targets, skip link
   -------------------------------------------------------------------------- */
:focus-visible {
  outline: 2px solid var(--ring);
  outline-offset: 3px;
  border-radius: 6px;
}

:focus:not(:focus-visible) {
  outline: none;
}

.skip-link {
  position: absolute;
  top: 0;
  left: 50%;
  translate: -50% -140%;
  z-index: 10000;
  padding: 12px 22px;
  background: #fff;
  color: #080809;
  font-weight: 800;
  font-size: 0.85rem;
  border-radius: 0 0 12px 12px;
  text-decoration: none;
  transition: translate var(--dur-mid) var(--ease-out);
}

.skip-link:focus-visible {
  translate: -50% 0;
  outline-offset: -3px;
}

@media (max-width: 900px) {

  .mobile-nav-link,
  .nav-primary-btn,
  .mobile-hamburger-btn {
    min-height: 44px;
  }
}

/* --------------------------------------------------------------------------
   7. SCROLL REVEALS — set by ui-polish.js
   -------------------------------------------------------------------------- */
[data-reveal] {
  opacity: 0;
  translate: 0 22px;
  transition:
    opacity var(--dur-slow) var(--ease-out),
    translate var(--dur-slow) var(--ease-out);
  transition-delay: var(--reveal-delay, 0ms);
}

[data-reveal].is-revealed {
  opacity: 1;
  translate: 0 0;
}

/* Never leave content hidden if JS fails to run */
.no-js [data-reveal] {
  opacity: 1;
  translate: 0 0;
}

/* --------------------------------------------------------------------------
   8. READING PROGRESS BAR
   -------------------------------------------------------------------------- */
.scroll-progress {
  position: fixed;
  top: 0;
  left: 0;
  height: 2px;
  width: 100%;
  z-index: 9998;
  transform-origin: 0 50%;
  scale: var(--progress, 0) 1;
  background: linear-gradient(90deg, #D92626, #FF6B65 60%, #FFB4AE);
  box-shadow: 0 0 12px rgba(217, 38, 38, 0.6);
  pointer-events: none;
}

/* Custom scrollbar to match the dark HUD shell */
* {
  scrollbar-width: thin;
  scrollbar-color: rgba(217, 38, 38, 0.55) rgba(255, 255, 255, 0.04);
}

/* --------------------------------------------------------------------------
   9. REDUCED MOTION — honour the OS setting
   -------------------------------------------------------------------------- */
@media (prefers-reduced-motion: reduce) {
  html {
    scroll-behavior: auto;
  }

  *,
  *::before,
  *::after {
    animation-duration: 0.01ms !important;
    animation-iteration-count: 1 !important;
    transition-duration: 0.01ms !important;
  }

  [data-reveal] {
    opacity: 1 !important;
    translate: 0 0 !important;
  }

  .scroll-progress {
    display: none;
  }
}

/* --------------------------------------------------------------------------
   10. HERO FIT — keep the first viewport intact on small/short screens
   -------------------------------------------------------------------------- */
@media (max-width: 560px) {
  .hero-trust-row {
    font-size: 0.66rem;
    gap: 6px 12px;
  }

  .hero-trust-sep {
    display: none;
  }
}

/* Short viewports (laptops, landscape phones): drop the optional bits first */
@media (max-height: 760px) and (min-width: 561px) {
  .floating-game-posters-wrap {
    height: 170px;
    margin-top: var(--sp-sm);
  }

  .hero-scroll-prompt {
    display: none;
  }
}

/* --------------------------------------------------------------------------
   11. FOOTER FIT — eliminate trailing empty viewport space
   -------------------------------------------------------------------------- */
.page-content {
  min-height: 100vh !important;
  display: flex !important;
  flex-direction: column !important;
}

.cinematic-footer-wrapper {
  min-height: auto !important;
  padding-bottom: 0 !important;
  margin-top: auto !important;
  flex-shrink: 0 !important;
}

.footer-bottom-bar {
  margin-top: 16px !important;
  padding-bottom: 22px !important;
}

body {
  padding-bottom: 0;
  margin: 0 !important;
}

@media (max-width: 768px) {
  body {
    padding-bottom: calc(76px + env(safe-area-inset-bottom, 0px)) !important;
  }
}

#respawn-cart-wrapper,
.respawn-cart-drawer,
.respawn-floating-cart {
  position: fixed !important;
}

.respawn-cart-drawer.is-hidden,
.respawn-floating-cart.is-hidden {
  display: none !important;
}

@media (max-height: 620px) {

  .hero-scroll-prompt,
  .hero-trust-row {
    display: none;
  }
}


/* ── Booking wizard: no rigs open for the picked setup ───── */
.wave-empty-note {
  display: flex;
  gap: 9px;
  padding: 14px 15px;
  border-radius: 10px;
  border: 1px dashed rgba(255, 255, 255, 0.14);
  background: rgba(255, 255, 255, 0.02);
  color: rgba(255, 255, 255, 0.62);
  font-size: 0.78rem;
  line-height: 1.55;
}

.wave-empty-note i {
  margin-top: 3px;
}