/* ==========================================================================
   GLOBAL.CSS — Design tokens, reset, typography, utilities
   Battlezone Laser Tag — Website Redesign 2026
   ========================================================================== */

/* --------------------------------------------------------------------------
   Design Tokens
   -------------------------------------------------------------------------- */
:root {
  /* Brand colours */
  --red:          #CC2027;
  --red-dim:      rgba(204, 32, 39, 0.12);
  --red-hover:    #B01B21;
  --ochre:        #B8965A;
  --ochre-dim:    rgba(184, 150, 90, 0.12);
  --ochre-hover:  #A07D44;

  /* Backgrounds — dark */
  --black:        #0F0F0F;
  --grey-900:     #1A1A1A;
  --grey-800:     #252525;
  --grey-700:     #2E2E2E;
  --grey-600:     #3D3D3D;

  /* Backgrounds — light */
  --white:        #F5F3EE;
  --white-mid:    #EDEAE3;

  /* Text */
  --grey-400:     #6B6B6B;
  --grey-200:     #C4C2BC;
  --text-dark:    #1A1A1A;
  --text-light:   #F5F3EE;

  /* Typography */
  --font-d: 'Bebas Neue', 'Impact', sans-serif;
  --font-s: 'Barlow Condensed', 'Arial Narrow', sans-serif;
  --font-b: 'DM Sans', 'Helvetica Neue', sans-serif;

  /* Spacing scale */
  --sp-1:  4px;
  --sp-2:  8px;
  --sp-3:  12px;
  --sp-4:  16px;
  --sp-5:  24px;
  --sp-6:  32px;
  --sp-7:  48px;
  --sp-8:  64px;
  --sp-9:  96px;
  --sp-10: 128px;

  /* Layout */
  --max-w: 1280px;
  --nav-h: 72px;

  /* Borders */
  --radius-sm: 2px;
  --radius-md: 4px;
  --radius-lg: 8px;

  /* Transitions */
  --ease:   cubic-bezier(0.4, 0, 0.2, 1);
  --ease-out: cubic-bezier(0, 0, 0.2, 1);
  --t-fast: 150ms;
  --t-base: 250ms;
  --t-slow: 400ms;

  /* Shadows */
  --shadow-sm:     0 1px 3px rgba(0,0,0,0.3);
  --shadow-md:     0 4px 12px rgba(0,0,0,0.35);
  --shadow-lg:     0 8px 32px rgba(0,0,0,0.45);
  --shadow-red:    0 4px 24px rgba(204, 32, 39, 0.4);
  --shadow-red-lg: 0 6px 24px rgba(204, 32, 39, 0.14);
  --shadow-red-xl: 0 12px 40px rgba(204, 32, 39, 0.15);

  /* Missing palette tokens (referenced in components.css) */
  --black-soft: #181824;
  --grey-500:   #4A4A4A;
  --grey-300:   #A8A5A0;

  /* Z-index scale */
  --z-base:    1;
  --z-raised:  10;
  --z-sticky:  980;
  --z-overlay: 990;
  --z-nav:     1000;
  --z-popover: 1010;
  --z-modal:   9000;
}

/* --------------------------------------------------------------------------
   Reset
   -------------------------------------------------------------------------- */
*, *::before, *::after {
  box-sizing: border-box;
  margin: 0;
  padding: 0;
}

html {
  scroll-behavior: smooth;
  -webkit-text-size-adjust: 100%;
  font-size: 16px;
}

body {
  font-family: var(--font-b);
  font-size: 16px;
  line-height: 1.6;
  color: var(--text-dark);
  background: var(--black);
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
  overflow-x: hidden;
}

img, video, svg {
  display: block;
  max-width: 100%;
}

a {
  color: inherit;
  text-decoration: none;
}

ul, ol {
  list-style: none;
}

button {
  cursor: pointer;
  border: none;
  background: none;
  font: inherit;
}

input, textarea, select {
  font: inherit;
  border: none;
  outline: none;
}

/* --------------------------------------------------------------------------
   Typography
   -------------------------------------------------------------------------- */

/* Display — Bebas Neue */
.t-display {
  font-family: var(--font-d);
  line-height: 0.95;
  letter-spacing: 0.01em;
}

/* Subheading — Barlow Condensed */
.t-sub {
  font-family: var(--font-s);
  font-weight: 600;
  letter-spacing: 0.04em;
}

/* Body — DM Sans */
.t-body {
  font-family: var(--font-b);
  font-weight: 400;
}

/* Size scale */
.t-hero   { font-size: clamp(64px, 10vw, 160px); }
.t-h1     { font-size: clamp(48px, 6vw, 96px); }
.t-h2     { font-size: clamp(40px, 5vw, 72px); }
.t-h3     { font-size: clamp(28px, 3.5vw, 48px); }
.t-h4     { font-size: clamp(22px, 2.5vw, 32px); }
.t-xl     { font-size: clamp(18px, 2vw, 22px); }
.t-lg     { font-size: clamp(17px, 1.5vw, 20px); }
.t-md     { font-size: 16px; }
.t-sm     { font-size: 15px; }
.t-xs     { font-size: 14px; }

/* Eyebrow label */
.t-eyebrow {
  font-family: var(--font-s);
  font-size: 13px;
  font-weight: 700;
  letter-spacing: 0.25em;
  text-transform: uppercase;
}

/* Stat number */
.t-stat {
  font-family: var(--font-d);
  font-size: clamp(48px, 6vw, 80px);
  line-height: 1;
}

/* --------------------------------------------------------------------------
   Colour utilities
   -------------------------------------------------------------------------- */
.c-red     { color: var(--red); }
.c-ochre   { color: var(--ochre); }
.c-light   { color: var(--text-light); }
.c-dark    { color: var(--text-dark); }
.c-muted   { color: var(--grey-400); }
.c-muted-l { color: var(--grey-200); }

.bg-black  { background: var(--black); }
.bg-900    { background: var(--grey-900); }
.bg-800    { background: var(--grey-800); }
.bg-white  { background: var(--white); }
.bg-red    { background: var(--red); }
.bg-ochre  { background: var(--ochre); }

/* --------------------------------------------------------------------------
   Layout utilities
   -------------------------------------------------------------------------- */
.container {
  width: 100%;
  max-width: var(--max-w);
  margin: 0 auto;
  padding: 0 var(--sp-6);
}

@media (max-width: 768px) {
  .container {
    padding: 0 var(--sp-5);
  }
}

.section {
  padding: var(--sp-10) 0;
}

@media (max-width: 768px) {
  .section {
    padding: var(--sp-8) 0;
  }
}

@media (max-width: 480px) {
  .section {
    padding: var(--sp-7) 0;   /* 48px — compact on small phones */
  }
  .container {
    padding: 0 var(--sp-4);   /* 16px — tighter horizontal gutters */
  }
}

/* Flex helpers */
.flex        { display: flex; }
.flex-col    { flex-direction: column; }
.flex-center { align-items: center; justify-content: center; }
.flex-between { align-items: center; justify-content: space-between; }
.flex-wrap   { flex-wrap: wrap; }
.gap-1  { gap: var(--sp-1); }
.gap-2  { gap: var(--sp-2); }
.gap-3  { gap: var(--sp-3); }
.gap-4  { gap: var(--sp-4); }
.gap-5  { gap: var(--sp-5); }
.gap-6  { gap: var(--sp-6); }

/* Grid helpers */
.grid     { display: grid; }
.grid-2   { grid-template-columns: repeat(2, 1fr); }
.grid-3   { grid-template-columns: repeat(3, 1fr); }
.grid-4   { grid-template-columns: repeat(4, 1fr); }

@media (max-width: 1024px) {
  .grid-4 { grid-template-columns: repeat(2, 1fr); }
  .grid-3 { grid-template-columns: repeat(2, 1fr); }
}

@media (max-width: 640px) {
  .grid-4, .grid-3, .grid-2 { grid-template-columns: 1fr; }
}

/* Text alignment */
.ta-c { text-align: center; }
.ta-l { text-align: left; }
.ta-r { text-align: right; }

/* Spacing utilities */
.mt-1 { margin-top: var(--sp-1); }
.mt-2 { margin-top: var(--sp-2); }
.mt-3 { margin-top: var(--sp-3); }
.mt-4 { margin-top: var(--sp-4); }
.mt-5 { margin-top: var(--sp-5); }
.mt-6 { margin-top: var(--sp-6); }
.mt-7 { margin-top: var(--sp-7); }
.mt-8 { margin-top: var(--sp-8); }
.mb-1 { margin-bottom: var(--sp-1); }
.mb-2 { margin-bottom: var(--sp-2); }
.mb-3 { margin-bottom: var(--sp-3); }
.mb-4 { margin-bottom: var(--sp-4); }
.mb-5 { margin-bottom: var(--sp-5); }
.mb-6 { margin-bottom: var(--sp-6); }
.mb-7 { margin-bottom: var(--sp-7); }
.mb-8 { margin-bottom: var(--sp-8); }

/* --------------------------------------------------------------------------
   Section themes
   -------------------------------------------------------------------------- */
.sect-dark {
  background: var(--black);
  color: var(--text-light);
}

.sect-dark-mid {
  background: var(--grey-900);
  color: var(--text-light);
}

.sect-dark-warm {
  background: #1A1917;
  color: var(--text-light);
}

.sect-light {
  background: var(--white);
  color: var(--text-dark);
}

.sect-light-mid {
  background: var(--white-mid);
  color: var(--text-dark);
}

.sect-red {
  background: var(--red);
  color: var(--text-light);
}

/* --------------------------------------------------------------------------
   Section header pattern
   -------------------------------------------------------------------------- */
.sect-header {
  margin-bottom: var(--sp-8);
}

.sect-header.ta-c {
  max-width: 720px;
  margin-left: auto;
  margin-right: auto;
}

.sect-header .t-eyebrow {
  margin-bottom: var(--sp-3);
}

.sect-header .heading-underline {
  display: inline-block;
  position: relative;
}

.sect-header .heading-underline::after {
  content: '';
  position: absolute;
  bottom: -6px;
  left: 0;
  width: 0;
  height: 3px;
  background: var(--red);
  transition: width 0.8s var(--ease-out);
}

.sect-header .heading-underline.ochre::after {
  background: var(--ochre);
}

.sect-header .heading-underline.animate::after {
  width: 100%;
}

.sect-header p {
  margin-top: var(--sp-5);
  max-width: 580px;
}

.sect-header.ta-c p {
  margin-left: auto;
  margin-right: auto;
}

/* --------------------------------------------------------------------------
   Placeholder image areas
   -------------------------------------------------------------------------- */
.img-placeholder {
  background: var(--grey-800);
  position: relative;
  overflow: hidden;
}

.img-placeholder::after {
  content: '';
  position: absolute;
  inset: 0;
  background: linear-gradient(
    90deg,
    transparent 0%,
    rgba(255,255,255,0.04) 50%,
    transparent 100%
  );
  background-size: 200% 100%;
  animation: shimmer 2s infinite;
}

@keyframes shimmer {
  0%   { background-position: -200% 0; }
  100% { background-position:  200% 0; }
}

/* --------------------------------------------------------------------------
   Divider
   -------------------------------------------------------------------------- */
.divider {
  width: 100%;
  height: 1px;
  background: var(--grey-800);
}

.divider-light {
  background: var(--grey-200);
}

.divider-red {
  background: var(--red);
  height: 2px;
}

.divider-ochre {
  background: var(--ochre);
  height: 2px;
}

/* --------------------------------------------------------------------------
   Visibility helpers
   -------------------------------------------------------------------------- */
.sr-only {
  position: absolute;
  width: 1px;
  height: 1px;
  padding: 0;
  margin: -1px;
  overflow: hidden;
  clip: rect(0,0,0,0);
  white-space: nowrap;
  border: 0;
}

@media (max-width: 768px) {
  .hide-mobile { display: none !important; }
}

@media (min-width: 769px) {
  .hide-desktop { display: none !important; }
}

/* --------------------------------------------------------------------------
   Ochre accent badge
   -------------------------------------------------------------------------- */
.badge {
  display: inline-flex;
  align-items: center;
  gap: var(--sp-2);
  padding: var(--sp-2) var(--sp-4);
  border-radius: var(--radius-sm);
  font-family: var(--font-s);
  font-size: 13px;
  font-weight: 700;
  letter-spacing: 0.15em;
  text-transform: uppercase;
}

.badge-red {
  background: var(--red-dim);
  color: var(--red);
  border: 1px solid rgba(204,32,39,0.3);
}

.badge-ochre {
  background: var(--ochre-dim);
  color: var(--ochre);
  border: 1px solid rgba(184,150,90,0.3);
}

.badge-dark {
  background: var(--grey-800);
  color: var(--grey-200);
  border: 1px solid var(--grey-600);
}

/* --------------------------------------------------------------------------
   Difficulty badges (for game modes)
   -------------------------------------------------------------------------- */
.diff-beginner     { background: rgba(0, 200, 100, 0.15); color: #00C864; border: 1px solid rgba(0,200,100,0.3); }
.diff-intermediate { background: rgba(184, 150, 90, 0.15); color: var(--ochre); border: 1px solid rgba(184,150,90,0.3); }
.diff-advanced     { background: var(--red-dim); color: var(--red); border: 1px solid rgba(204,32,39,0.3); }

/* --------------------------------------------------------------------------
   Highlight box (ochre callout)
   -------------------------------------------------------------------------- */
.callout-box {
  border-left: 4px solid var(--ochre);
  background: var(--ochre-dim);
  padding: var(--sp-5) var(--sp-6);
  border-radius: 0 var(--radius-md) var(--radius-md) 0;
}

.callout-box.red {
  border-left-color: var(--red);
  background: var(--red-dim);
}
