/* ============================================================
   THE TAILOR — Global Design System
   iamthetailor.com
   ============================================================ */

/* ============================================================
   FONTS
   ============================================================ */
@import url('https://fonts.googleapis.com/css2?family=Space+Grotesk:wght@400;500;600;700&family=Inter:wght@300;400;500&display=swap');

/* ============================================================
   CSS CUSTOM PROPERTIES
   ============================================================ */
:root {
  /* Brand Colors */
  --black:          #0A0A0A;
  --graphite:       #111111;
  --steel:          #151515;
  --panel:          #1E1E1E;
  --border:         #2A2A2A;
  --border-subtle:  rgba(255,255,255,0.06);

  --text-primary:   #F5F5F5;
  --text-secondary: #A1A1A1;
  --text-muted:     #555555;
  --text-ghost:     #2A2A2A;

  --gold:           #C6A96B;
  --gold-dim:       rgba(198,169,107,0.15);
  --gold-border:    rgba(198,169,107,0.2);
  --signal:         #32D583;
  --signal-dim:     rgba(50,213,131,0.12);

  /* Typography Scale */
  --font-display:   'Space Grotesk', 'Helvetica Neue', Arial, sans-serif;
  --font-body:      'Inter', 'Helvetica Neue', Arial, sans-serif;

  --text-xs:        0.6875rem;   /* 11px */
  --text-sm:        0.8125rem;   /* 13px */
  --text-base:      1rem;        /* 16px */
  --text-md:        1.125rem;    /* 18px */
  --text-lg:        1.375rem;    /* 22px */
  --text-xl:        1.75rem;     /* 28px */
  --text-2xl:       2.25rem;     /* 36px */
  --text-3xl:       3rem;        /* 48px */
  --text-4xl:       4rem;        /* 64px */
  --text-5xl:       5.5rem;      /* 88px */

  /* Spacing */
  --space-1:   0.25rem;
  --space-2:   0.5rem;
  --space-3:   0.75rem;
  --space-4:   1rem;
  --space-6:   1.5rem;
  --space-8:   2rem;
  --space-10:  2.5rem;
  --space-12:  3rem;
  --space-16:  4rem;
  --space-20:  5rem;
  --space-24:  6rem;
  --space-32:  8rem;

  /* Layout */
  --max-width:      1280px;
  --content-width:  900px;
  --nav-height:     72px;

  /* Borders */
  --radius-sm:   4px;
  --radius-md:   8px;
  --radius-lg:   12px;
  --radius-xl:   20px;

  /* Transitions */
  --ease:        cubic-bezier(0.4, 0, 0.15, 1);
  --ease-out:    cubic-bezier(0.0, 0, 0.2, 1);
  --duration-sm: 180ms;
  --duration-md: 300ms;
  --duration-lg: 500ms;
}

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

html {
  font-size: 16px;
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
  scroll-behavior: smooth;
}

body {
  background-color: var(--black);
  color: var(--text-primary);
  font-family: var(--font-body);
  font-size: var(--text-base);
  font-weight: 400;
  line-height: 1.65;
  overflow-x: hidden;
}

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

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

button {
  font-family: var(--font-display);
  cursor: pointer;
  border: none;
  background: none;
}

input, textarea, select {
  font-family: var(--font-body);
  font-size: var(--text-base);
}

ul, ol {
  list-style: none;
}

/* ============================================================
   GRID / BACKGROUND TEXTURE (CSS only, no images)
   ============================================================ */
.grid-texture {
  position: relative;
}
.grid-texture::before {
  content: '';
  position: absolute;
  inset: 0;
  background-image:
    linear-gradient(var(--gold-border) 1px, transparent 1px),
    linear-gradient(90deg, var(--gold-border) 1px, transparent 1px);
  background-size: 48px 48px;
  pointer-events: none;
  z-index: 0;
  opacity: 0.4;
}

.grid-texture > * {
  position: relative;
  z-index: 1;
}

/* Noise grain overlay */
.noise::after {
  content: '';
  position: absolute;
  inset: 0;
  background-image: url("data:image/svg+xml,%3Csvg viewBox='0 0 256 256' xmlns='http://www.w3.org/2000/svg'%3E%3Cfilter id='noise'%3E%3CfeTurbulence type='fractalNoise' baseFrequency='0.9' numOctaves='4' stitchTiles='stitch'/%3E%3C/filter%3E%3Crect width='100%25' height='100%25' filter='url(%23noise)' opacity='0.04'/%3E%3C/svg%3E");
  pointer-events: none;
  z-index: 0;
}

/* ============================================================
   LAYOUT
   ============================================================ */
.container {
  width: 100%;
  max-width: var(--max-width);
  margin: 0 auto;
  padding: 0 var(--space-8);
}

.container-narrow {
  width: 100%;
  max-width: var(--content-width);
  margin: 0 auto;
  padding: 0 var(--space-8);
}

.section {
  padding: var(--space-32) 0;
}

.section-tight {
  padding: var(--space-20) 0;
}

/* ============================================================
   NAVIGATION
   ============================================================ */
.nav {
  position: fixed;
  top: 0;
  left: 0;
  right: 0;
  height: var(--nav-height);
  z-index: 1000;
  transition: background var(--duration-md) var(--ease),
              border-color var(--duration-md) var(--ease);
  border-bottom: 1px solid transparent;
}

.nav.scrolled {
  background: rgba(10,10,10,0.92);
  backdrop-filter: blur(20px);
  -webkit-backdrop-filter: blur(20px);
  border-bottom-color: var(--border-subtle);
}

.nav-inner {
  display: flex;
  align-items: center;
  justify-content: space-between;
  height: 100%;
  max-width: var(--max-width);
  margin: 0 auto;
  padding: 0 var(--space-8);
}

.nav-logo {
  display: flex;
  align-items: center;
  gap: var(--space-3);
  text-decoration: none;
}

.nav-logo-the {
  font-family: var(--font-display);
  font-size: var(--text-xs);
  letter-spacing: 0.2em;
  text-transform: uppercase;
  color: var(--gold);
  font-weight: 500;
  line-height: 1;
  display: block;
  margin-bottom: 3px;
}

.nav-logo-tailor {
  font-family: var(--font-display);
  font-size: var(--text-md);
  font-weight: 600;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  color: var(--text-primary);
  line-height: 1;
  display: block;
}

.nav-links {
  display: flex;
  align-items: center;
  gap: var(--space-8);
}

.nav-link {
  font-family: var(--font-display);
  font-size: var(--text-sm);
  font-weight: 500;
  letter-spacing: 0.06em;
  text-transform: uppercase;
  color: var(--text-secondary);
  transition: color var(--duration-sm) var(--ease);
  text-decoration: none;
}

.nav-link:hover {
  color: var(--text-primary);
}

.nav-cta {
  font-family: var(--font-display);
  font-size: var(--text-sm);
  font-weight: 600;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  color: var(--black);
  background: var(--gold);
  padding: var(--space-2) var(--space-6);
  border-radius: var(--radius-sm);
  transition: opacity var(--duration-sm) var(--ease);
  text-decoration: none;
}

.nav-cta:hover {
  opacity: 0.88;
}

/* ============================================================
   TYPOGRAPHY
   ============================================================ */

/* Labels */
.label {
  font-family: var(--font-display);
  font-size: var(--text-xs);
  font-weight: 500;
  letter-spacing: 0.18em;
  text-transform: uppercase;
  color: var(--gold);
}

.label-muted {
  font-family: var(--font-display);
  font-size: var(--text-xs);
  font-weight: 500;
  letter-spacing: 0.18em;
  text-transform: uppercase;
  color: var(--text-muted);
}

/* Headings */
h1, .h1 {
  font-family: var(--font-display);
  font-size: clamp(var(--text-3xl), 7vw, var(--text-5xl));
  font-weight: 700;
  line-height: 1.0;
  letter-spacing: -0.02em;
  color: var(--text-primary);
}

h2, .h2 {
  font-family: var(--font-display);
  font-size: clamp(var(--text-2xl), 4vw, var(--text-4xl));
  font-weight: 600;
  line-height: 1.1;
  letter-spacing: -0.02em;
  color: var(--text-primary);
}

h3, .h3 {
  font-family: var(--font-display);
  font-size: clamp(var(--text-xl), 2.5vw, var(--text-2xl));
  font-weight: 600;
  line-height: 1.2;
  letter-spacing: -0.01em;
  color: var(--text-primary);
}

h4, .h4 {
  font-family: var(--font-display);
  font-size: var(--text-lg);
  font-weight: 600;
  line-height: 1.3;
  color: var(--text-primary);
}

h5, .h5 {
  font-family: var(--font-display);
  font-size: var(--text-md);
  font-weight: 500;
  line-height: 1.4;
  color: var(--text-primary);
}

p {
  font-family: var(--font-body);
  font-size: var(--text-base);
  font-weight: 400;
  line-height: 1.75;
  color: var(--text-secondary);
}

.lead {
  font-size: var(--text-md);
  line-height: 1.7;
  color: var(--text-secondary);
}

.gold-text {
  color: var(--gold);
}

.signal-text {
  color: var(--signal);
}

/* ============================================================
   BUTTONS
   ============================================================ */
.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: var(--space-2);
  font-family: var(--font-display);
  font-size: var(--text-sm);
  font-weight: 600;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  text-decoration: none;
  border-radius: var(--radius-sm);
  padding: var(--space-3) var(--space-8);
  transition: all var(--duration-md) var(--ease);
  cursor: pointer;
  border: none;
  white-space: nowrap;
}

.btn-primary {
  background: var(--gold);
  color: var(--black);
}

.btn-primary:hover {
  opacity: 0.88;
  transform: translateY(-1px);
}

.btn-secondary {
  background: transparent;
  color: var(--text-primary);
  border: 1px solid var(--border);
}

.btn-secondary:hover {
  border-color: var(--gold-border);
  color: var(--gold);
}

.btn-ghost {
  background: transparent;
  color: var(--text-secondary);
  border: 1px solid transparent;
  padding: var(--space-3) 0;
}

.btn-ghost:hover {
  color: var(--text-primary);
}

.btn-ghost::after {
  content: ' →';
  transition: transform var(--duration-sm) var(--ease);
  display: inline-block;
}

.btn-ghost:hover::after {
  transform: translateX(4px);
}

.btn-signal {
  background: var(--signal-dim);
  color: var(--signal);
  border: 1px solid rgba(50,213,131,0.2);
}

.btn-signal:hover {
  background: rgba(50,213,131,0.18);
}

/* Button sizes */
.btn-lg {
  font-size: var(--text-base);
  padding: var(--space-4) var(--space-10);
}

.btn-sm {
  font-size: var(--text-xs);
  padding: var(--space-2) var(--space-6);
}

/* ============================================================
   CARDS
   ============================================================ */
.card {
  background: var(--panel);
  border: 1px solid var(--border-subtle);
  border-radius: var(--radius-lg);
  padding: var(--space-8);
  transition: border-color var(--duration-md) var(--ease),
              transform var(--duration-md) var(--ease);
}

.card:hover {
  border-color: var(--gold-border);
  transform: translateY(-2px);
}

.card-number {
  font-family: var(--font-display);
  font-size: var(--text-xs);
  font-weight: 500;
  letter-spacing: 0.14em;
  color: var(--text-ghost);
  margin-bottom: var(--space-6);
}

.card-icon {
  width: 32px;
  height: 32px;
  margin-bottom: var(--space-6);
}

.card-title {
  font-family: var(--font-display);
  font-size: var(--text-lg);
  font-weight: 600;
  color: var(--text-primary);
  margin-bottom: var(--space-3);
  letter-spacing: -0.01em;
}

.card-body {
  font-size: var(--text-sm);
  line-height: 1.75;
  color: var(--text-secondary);
}

/* ============================================================
   DIVIDERS
   ============================================================ */
.divider {
  height: 1px;
  background: var(--border-subtle);
}

.divider-gold {
  height: 1px;
  background: linear-gradient(
    90deg,
    transparent 0%,
    var(--gold-border) 30%,
    var(--gold-border) 70%,
    transparent 100%
  );
}

/* ============================================================
   PROOF / STAT BLOCKS
   ============================================================ */
.stat {
  display: flex;
  flex-direction: column;
  gap: var(--space-2);
}

.stat-value {
  font-family: var(--font-display);
  font-size: clamp(var(--text-2xl), 4vw, var(--text-4xl));
  font-weight: 700;
  color: var(--text-primary);
  letter-spacing: -0.02em;
  line-height: 1;
}

.stat-value span {
  color: var(--gold);
}

.stat-label {
  font-family: var(--font-display);
  font-size: var(--text-xs);
  font-weight: 500;
  letter-spacing: 0.14em;
  text-transform: uppercase;
  color: var(--text-muted);
}

/* ============================================================
   FORMS
   ============================================================ */
.form-group {
  display: flex;
  flex-direction: column;
  gap: var(--space-2);
}

.form-label {
  font-family: var(--font-display);
  font-size: var(--text-xs);
  font-weight: 500;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  color: var(--text-muted);
}

.form-input,
.form-select,
.form-textarea {
  background: var(--steel);
  border: 1px solid var(--border);
  border-radius: var(--radius-md);
  padding: var(--space-4) var(--space-6);
  color: var(--text-primary);
  font-family: var(--font-body);
  font-size: var(--text-base);
  transition: border-color var(--duration-sm) var(--ease);
  width: 100%;
  outline: none;
  appearance: none;
}

.form-input:focus,
.form-select:focus,
.form-textarea:focus {
  border-color: var(--gold-border);
}

.form-input::placeholder,
.form-textarea::placeholder {
  color: var(--text-ghost);
}

.form-textarea {
  resize: vertical;
  min-height: 120px;
  line-height: 1.65;
}

.form-error {
  font-size: var(--text-xs);
  color: #E2534A;
  margin-top: var(--space-1);
}

/* Multi-step progress indicator */
.form-progress {
  display: flex;
  align-items: center;
  gap: var(--space-2);
  margin-bottom: var(--space-8);
}

.form-progress-dot {
  width: 6px;
  height: 6px;
  border-radius: 50%;
  background: var(--border);
  transition: all var(--duration-md) var(--ease);
}

.form-progress-dot.active {
  background: var(--gold);
  width: 20px;
  border-radius: 3px;
}

.form-progress-dot.complete {
  background: var(--signal);
}

/* ============================================================
   BADGE / TAG
   ============================================================ */
.badge {
  display: inline-flex;
  align-items: center;
  font-family: var(--font-display);
  font-size: var(--text-xs);
  font-weight: 500;
  letter-spacing: 0.1em;
  text-transform: uppercase;
  padding: var(--space-1) var(--space-3);
  border-radius: var(--radius-sm);
}

.badge-gold {
  background: var(--gold-dim);
  color: var(--gold);
  border: 1px solid var(--gold-border);
}

.badge-signal {
  background: var(--signal-dim);
  color: var(--signal);
  border: 1px solid rgba(50,213,131,0.15);
}

.badge-muted {
  background: var(--steel);
  color: var(--text-muted);
  border: 1px solid var(--border-subtle);
}

/* ============================================================
   LOGO SVG — reusable inline component
   ============================================================ */
.logo-mark {
  display: flex;
  flex-direction: column;
  align-items: flex-start;
}

.logo-the {
  font-family: var(--font-display);
  font-size: var(--text-xs);
  font-weight: 500;
  letter-spacing: 0.22em;
  text-transform: uppercase;
  color: var(--gold);
  line-height: 1;
  display: block;
  margin-bottom: 4px;
}

.logo-tailor {
  font-family: var(--font-display);
  font-size: var(--text-2xl);
  font-weight: 600;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  color: var(--text-primary);
  line-height: 1;
  display: block;
}

/* ============================================================
   SECTION HEADERS
   ============================================================ */
.section-header {
  margin-bottom: var(--space-16);
}

.section-header-centered {
  text-align: center;
  max-width: 680px;
  margin: 0 auto var(--space-16);
}

.section-header .label {
  margin-bottom: var(--space-4);
  display: block;
}

/* ============================================================
   HORIZONTAL RULE WITH LABEL
   ============================================================ */
.rule-label {
  display: flex;
  align-items: center;
  gap: var(--space-4);
  color: var(--text-ghost);
  font-family: var(--font-display);
  font-size: var(--text-xs);
  letter-spacing: 0.14em;
  text-transform: uppercase;
}

.rule-label::before,
.rule-label::after {
  content: '';
  flex: 1;
  height: 1px;
  background: var(--border-subtle);
}

/* ============================================================
   SIGNAL LINE — decorative animated CSS element
   ============================================================ */
.signal-line {
  position: relative;
  height: 1px;
  background: var(--border-subtle);
  overflow: hidden;
}

.signal-line::after {
  content: '';
  position: absolute;
  top: 0;
  left: -100%;
  width: 60%;
  height: 100%;
  background: linear-gradient(
    90deg,
    transparent,
    var(--gold-border),
    var(--gold),
    var(--gold-border),
    transparent
  );
  animation: signal-travel 3s ease-in-out infinite;
}

@keyframes signal-travel {
  0%   { left: -60%; }
  100% { left: 110%; }
}

/* ============================================================
   SCROLL ANIMATIONS — base states
   (JS adds .visible class via IntersectionObserver)
   ============================================================ */
.fade-up {
  opacity: 0;
  transform: translateY(28px);
  transition: opacity var(--duration-lg) var(--ease),
              transform var(--duration-lg) var(--ease);
}

.fade-up.visible {
  opacity: 1;
  transform: translateY(0);
}

.fade-in {
  opacity: 0;
  transition: opacity var(--duration-lg) var(--ease);
}

.fade-in.visible {
  opacity: 1;
}

/* Stagger delays for child elements */
.stagger > *:nth-child(1) { transition-delay: 0ms; }
.stagger > *:nth-child(2) { transition-delay: 80ms; }
.stagger > *:nth-child(3) { transition-delay: 160ms; }
.stagger > *:nth-child(4) { transition-delay: 240ms; }

/* ============================================================
   ADMIN PORTAL — base overrides
   (admin.css extends this file)
   ============================================================ */
.admin-body {
  background: var(--graphite);
}

/* ============================================================
   RESPONSIVE
   ============================================================ */
@media (max-width: 1024px) {
  .container,
  .container-narrow {
    padding: 0 var(--space-6);
  }
}

@media (max-width: 768px) {
  :root {
    --nav-height: 60px;
  }

  .container,
  .container-narrow {
    padding: 0 var(--space-4);
  }

  .section {
    padding: var(--space-20) 0;
  }

  .nav-links {
    display: none;
  }

  .btn-lg {
    font-size: var(--text-sm);
    padding: var(--space-4) var(--space-8);
  }
}

@media (max-width: 480px) {
  .section {
    padding: var(--space-16) 0;
  }
}

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

.text-center { text-align: center; }
.text-right  { text-align: right; }

.flex         { display: flex; }
.flex-col     { flex-direction: column; }
.items-center { align-items: center; }
.justify-between { justify-content: space-between; }
.gap-4  { gap: var(--space-4); }
.gap-6  { gap: var(--space-6); }
.gap-8  { gap: var(--space-8); }
.gap-12 { gap: var(--space-12); }

.mt-4  { margin-top: var(--space-4); }
.mt-6  { margin-top: var(--space-6); }
.mt-8  { margin-top: var(--space-8); }
.mt-12 { margin-top: var(--space-12); }
.mt-16 { margin-top: var(--space-16); }

.w-full  { width: 100%; }
.hidden  { display: none; }
.relative { position: relative; }
.overflow-hidden { overflow: hidden; }

/* ============================================================
   HORIZONTAL TIMELINE — global reusable styles
   Chapter panels use these classes across the site.
   Background images are set inline per-chapter in index.html.
============================================================ */

/* Outer wrapper */
.timeline-outer {
  background: var(--black);
  overflow: hidden;
}

/* Header above the pinned region */
.timeline-header {
  padding: var(--space-20) 0 var(--space-12);
  text-align: center;
}

/* GSAP pin target */
.timeline-pin {
  overflow: hidden;
  position: relative;
}

/* Horizontal track — GSAP translates this */
.timeline-track {
  display: flex;
  will-change: transform;
}

/* Individual chapter panel */
.chapter {
  width: 100vw;
  min-height: 82vh;
  flex-shrink: 0;
  display: flex;
  align-items: center;
  padding: var(--space-20) var(--space-12);
  position: relative;
  overflow: hidden;
  border-right: 1px solid rgba(255,255,255,0.04);
  /* Background image set per-chapter inline — no default bg */
  background-size: cover;
  background-position: center right;
  background-repeat: no-repeat;
}

.chapter:last-child {
  border-right: none;
}

/* Dark gradient overlay — keeps text readable over images */
.chapter-overlay {
  position: absolute;
  inset: 0;
  z-index: 1;
  pointer-events: none;
  background: linear-gradient(
    90deg,
    rgba(10,10,10,0.96) 0%,
    rgba(10,10,10,0.88) 36%,
    rgba(10,10,10,0.60) 58%,
    rgba(10,10,10,0.20) 80%,
    rgba(10,10,10,0.05) 100%
  );
}

/* Bottom fade for depth */
.chapter-overlay::after {
  content: '';
  position: absolute;
  inset: 0;
  background: linear-gradient(
    180deg,
    rgba(10,10,10,0.35) 0%,
    transparent 20%,
    transparent 75%,
    rgba(10,10,10,0.50) 100%
  );
}

/* Text container — sits above overlay */
.chapter-inner {
  max-width: 600px;
  position: relative;
  z-index: 2;
}

/* Ghost chapter number */
.chapter-number {
  font-family: var(--font-display);
  font-size: clamp(5rem, 12vw, 10rem);
  font-weight: 700;
  letter-spacing: -0.06em;
  color: rgba(255,255,255,0.04);
  line-height: 1;
  position: absolute;
  top: -10px;
  right: -16px;
  z-index: 1;
  user-select: none;
  pointer-events: none;
}

/* Chapter label */
.chapter-label {
  font-family: var(--font-display);
  font-size: var(--text-xs);
  font-weight: 500;
  letter-spacing: 0.2em;
  text-transform: uppercase;
  color: var(--gold);
  margin-bottom: var(--space-6);
  display: block;
}

/* Chapter title */
.chapter-title {
  font-family: var(--font-display);
  font-size: clamp(var(--text-2xl), 3.5vw, var(--text-3xl));
  font-weight: 700;
  line-height: 1.05;
  letter-spacing: -0.02em;
  color: var(--text-primary);
  margin-bottom: var(--space-8);
}

/* Chapter body */
.chapter-body {
  font-size: var(--text-base);
  line-height: 1.85;
  color: var(--text-secondary);
}

.chapter-body p {
  margin-bottom: var(--space-4);
}

.chapter-body p:last-child {
  margin-bottom: 0;
}

.chapter-body strong {
  color: var(--text-primary);
  font-weight: 500;
}

/* Gold accent line under chapter content */
.chapter-accent {
  display: block;
  width: 32px;
  height: 1px;
  background: var(--gold);
  margin-top: var(--space-8);
  opacity: 0.6;
}

/* Progress pips — fixed bottom center during scroll */
.timeline-progress {
  position: fixed;
  bottom: var(--space-8);
  left: 50%;
  transform: translateX(-50%);
  display: flex;
  gap: var(--space-2);
  z-index: 100;
  opacity: 0;
  transition: opacity 0.4s ease;
  pointer-events: none;
}

.timeline-progress.visible {
  opacity: 1;
}

.progress-pip {
  width: 6px;
  height: 6px;
  border-radius: 50%;
  background: rgba(255,255,255,0.2);
  transition: all 0.35s ease;
}

.progress-pip.active {
  width: 20px;
  border-radius: 3px;
  background: var(--gold);
}

.progress-pip.past {
  background: rgba(198,169,107,0.35);
}

/* Mobile — stack vertically, simplify */
@media (max-width: 768px) {
  .chapter {
    padding: var(--space-12) var(--space-6);
    /* On mobile the horizontal scroll becomes vertical stacked */
    width: 100vw;
    min-height: 70vh;
    background-position: center center;
  }
  .chapter-overlay {
    background: linear-gradient(
      180deg,
      rgba(10,10,10,0.92) 0%,
      rgba(10,10,10,0.80) 50%,
      rgba(10,10,10,0.70) 100%
    );
  }
  .chapter-overlay::after {
    display: none;
  }
  .chapter-number {
    display: none;
  }
  .chapter-inner {
    max-width: 100%;
  }
}

/* ============================================================
   FOOTER — full component styles
   Ensures consistent footer across all pages
============================================================ */
.footer {
  background: var(--black);
  border-top: 1px solid var(--border-subtle);
  padding: var(--space-16) 0 var(--space-8);
}

.footer-top {
  display: grid;
  grid-template-columns: 1.5fr 1fr 1fr 1fr;
  gap: var(--space-8);
  margin-bottom: var(--space-16);
  min-width: 0;
}

.footer-top > * {
  min-width: 0;
  overflow-wrap: break-word;
}

.footer-brand p {
  font-size: var(--text-sm);
  line-height: 1.75;
  color: var(--text-muted);
  margin-top: var(--space-6);
  max-width: 280px;
}

.footer-col-label {
  font-family: var(--font-display);
  font-size: var(--text-xs);
  font-weight: 500;
  letter-spacing: 0.18em;
  text-transform: uppercase;
  color: var(--text-ghost);
  margin-bottom: var(--space-6);
}

.footer-links {
  display: flex;
  flex-direction: column;
  gap: var(--space-3);
}

.footer-link {
  font-size: var(--text-sm);
  color: var(--text-muted);
  text-decoration: none;
  transition: color 0.2s ease;
}

.footer-link:hover { color: var(--text-primary); }

.footer-bottom {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding-top: var(--space-8);
  border-top: 1px solid var(--border-subtle);
  flex-wrap: wrap;
  gap: var(--space-4);
}

.footer-legal {
  font-size: var(--text-xs);
  color: var(--text-ghost);
  letter-spacing: 0.06em;
}

.footer-company {
  font-family: var(--font-display);
  font-size: var(--text-xs);
  letter-spacing: 0.1em;
  text-transform: uppercase;
  color: var(--text-ghost);
}

.footer-company span { color: var(--gold); }

@media (max-width: 1024px) {
  .footer-top { grid-template-columns: 1fr 1fr; gap: var(--space-6); }
}

@media (max-width: 640px) {
  .footer-top { grid-template-columns: 1fr; }
  .footer-bottom { flex-direction: column; text-align: center; }
}
