/* ═══════════════════════════════════════════════════════════════════════
   New Mexico Track Club — site styles.
   Shared across index.html, workouts.html, and membership.html.
   ═══════════════════════════════════════════════════════════════════════ */

  html { scroll-behavior: smooth; }

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

  :root {
    /* Brand palette pulled from the NMTC banner: Zia red, sun yellow, turquoise. */
    --red: #D5181E;
    --red-dark: #A8121A;
    --yellow: #F5C518;          /* tempered for dark backgrounds */
    --yellow-bright: #FBE802;   /* matches banner exactly — use on red */
    --turquoise: #1FB0C0;
    --turquoise-dark: #167F8A;
    --gold: var(--yellow);      /* legacy alias — anything still referencing --gold */

    --dark: #0E0E0E;
    --mid: #1C1C1C;
    --surface: #242424;
    --muted: #9A9A9A;
    --light: #F5F3EE;
    --white: #FFFFFF;
    --ff-head: 'Barlow Condensed', sans-serif;
    --ff-body: 'Barlow', sans-serif;
  }

  body { background: var(--dark); color: var(--light); font-family: var(--ff-body); }

  /* NAV */
  nav {
    position: sticky; top: 0; z-index: 100;
    display: flex; align-items: center; justify-content: space-between;
    padding: 0 2.5rem; height: 60px;
    background: rgba(14,14,14,0.97); backdrop-filter: blur(8px);
    border-bottom: 1px solid rgba(192,57,43,0.3);
  }
  .nav-logo {
    display: flex; align-items: center; gap: 0.5rem;
    text-decoration: none; color: var(--white);
    font-family: var(--ff-head); font-size: 1.05rem; font-weight: 900;
    letter-spacing: 0.12em; text-transform: uppercase;
  }
  .nav-logo img {
    /* Pin both dimensions explicitly. iOS Safari mis-computes width
       when only height is set on an SVG that lacks intrinsic sizing. */
    height: 40px; width: 60px; display: block;
  }
  .nav-logo span { color: var(--turquoise); }
  .nav-links { display: flex; gap: 2rem; list-style: none; }
  .nav-links a {
    font-family: var(--ff-head); font-size: 0.95rem; font-weight: 600;
    letter-spacing: 0.1em; text-transform: uppercase;
    color: var(--muted); text-decoration: none; transition: color 0.2s;
  }
  .nav-links a:hover, .nav-links a.active { color: var(--white); }
  .nav-cta {
    font-family: var(--ff-head); font-size: 0.85rem; font-weight: 700;
    letter-spacing: 0.12em; text-transform: uppercase;
    background: var(--red); color: var(--white);
    border: none; padding: 0.45rem 1.2rem; cursor: pointer;
    transition: background 0.2s;
  }
  .nav-cta:hover { background: var(--red-dark); }
  .mobile-cta-item { display: none; }

  /* PAGE SWITCHER */
  /* .page/.page.active were the JS page-switcher classes when the site
     was a single-file, three-in-one page. Now each page is its own HTML
     file, so those rules are gone. */

  /* HERO */
  .hero {
    position: relative; min-height: 88vh;
    display: flex; flex-direction: column;
    justify-content: center; align-items: center;
    text-align: center;
    padding: 5rem 2.5rem 4rem;
    overflow: hidden;
  }
  .hero-bg {
    position: absolute; inset: 0;
    background: linear-gradient(135deg, #0E0E0E 0%, #1a0a08 60%, #0E0E0E 100%);
  }
  .hero-stripe {
    position: absolute; top: 0; right: 0; width: 42%; height: 100%;
    background: var(--turquoise); opacity: 0.05;
    clip-path: polygon(20% 0, 100% 0, 100% 100%, 0% 100%);
  }
  .hero-track-lines {
    position: absolute; bottom: 0; left: 0; right: 0; height: 6px;
    background: repeating-linear-gradient(
      90deg,
      var(--red) 0, var(--red) 60px,
      transparent 60px, transparent 80px,
      var(--yellow) 80px, var(--yellow) 100px,
      transparent 100px, transparent 120px,
      var(--turquoise) 120px, var(--turquoise) 140px,
      transparent 140px, transparent 160px
    );
    opacity: 0.55;
  }
  /* Hero banner image — replaces big text headline */
  .hero-banner-wrap {
    margin: 0 auto 1.5rem;
    max-width: 540px;
    box-shadow: 0 20px 60px rgba(0,0,0,0.5), 0 0 0 1px rgba(245,197,24,0.15);
  }
  .hero-banner-wrap img {
    display: block; width: 100%; height: auto;
  }

  /* Screen-reader-only utility */
  .visually-hidden {
    position: absolute !important;
    width: 1px; height: 1px; overflow: hidden;
    clip: rect(0 0 0 0); clip-path: inset(50%);
    white-space: nowrap; border: 0; padding: 0; margin: -1px;
  }
  .hero-content {
    position: relative; max-width: 700px;
    margin: 0 auto;
  }
  .hero-eyebrow {
    font-family: var(--ff-head); font-size: 0.85rem; font-weight: 600;
    letter-spacing: 0.25em; text-transform: uppercase; color: var(--yellow);
    margin-bottom: 1rem;
  }
  .hero-title {
    font-family: var(--ff-head); font-weight: 900; line-height: 0.92;
    text-transform: uppercase; color: var(--white);
    font-size: clamp(3.5rem, 9vw, 7rem);
    margin-bottom: 1.5rem;
  }
  .hero-title em { color: var(--red); font-style: normal; display: block; }
  .hero-sub {
    font-family: var(--ff-body); font-weight: 300; font-size: 1.05rem;
    color: rgba(245,243,238,0.7); line-height: 1.7; max-width: 500px;
    margin: 0 auto 2.5rem;
  }
  .hero-actions { display: flex; gap: 1rem; align-items: center; justify-content: center; }
  .btn-primary {
    font-family: var(--ff-head); font-size: 1rem; font-weight: 700;
    letter-spacing: 0.12em; text-transform: uppercase;
    background: var(--red); color: var(--white);
    border: none; padding: 0.8rem 2rem; cursor: pointer; transition: background 0.2s;
  }
  .btn-primary:hover { background: var(--red-dark); }
  .btn-secondary {
    font-family: var(--ff-head); font-size: 1rem; font-weight: 600;
    letter-spacing: 0.1em; text-transform: uppercase;
    background: transparent; color: var(--light);
    border: 1px solid rgba(245,243,238,0.3); padding: 0.8rem 2rem;
    cursor: pointer; transition: border-color 0.2s, color 0.2s;
  }
  .btn-secondary:hover { border-color: var(--light); }
  .hero-stats {
    position: relative;
    display: flex; flex-direction: row;
    justify-content: center; align-items: flex-end;
    gap: 3.5rem;
    margin-top: 3rem;
  }
  .stat { text-align: center; }
  .stat-num {
    font-family: var(--ff-head); font-size: 2.8rem; font-weight: 900;
    line-height: 1; color: var(--yellow);
  }
  .stat-per {
    font-family: var(--ff-head); font-size: 1.1rem; font-weight: 700;
    color: rgba(245,197,24,0.7); letter-spacing: 0.02em;
    margin-left: 0.15rem;
  }
  .stat-label {
    font-family: var(--ff-body); font-size: 0.75rem; font-weight: 400;
    letter-spacing: 0.15em; text-transform: uppercase; color: var(--muted);
  }

  /* SECTIONS */
  section { padding: 5rem 2.5rem; }
  .section-label {
    font-family: var(--ff-head); font-size: 0.75rem; font-weight: 700;
    letter-spacing: 0.3em; text-transform: uppercase; color: var(--turquoise);
    margin-bottom: 0.6rem;
  }
  .section-title {
    font-family: var(--ff-head); font-size: clamp(2rem, 4vw, 3rem);
    font-weight: 900; text-transform: uppercase; color: var(--white);
    line-height: 1; margin-bottom: 2.5rem;
    position: relative; padding-bottom: 0.8rem;
  }
  .section-title::after {
    content: ""; position: absolute; bottom: 0; left: 0;
    width: 64px; height: 4px;
    background: linear-gradient(90deg, var(--red) 0 33%, var(--yellow) 33% 66%, var(--turquoise) 66% 100%);
  }

  /* ABOUT */
  .about-strip {
    background: var(--mid);
    border-top: 1px solid rgba(255,255,255,0.06);
    border-bottom: 1px solid rgba(255,255,255,0.06);
  }
  .about-inner { max-width: 860px; }
  .about-body {
    font-size: 1.05rem; font-weight: 300; color: rgba(245,243,238,0.75);
    line-height: 1.8; margin-bottom: 1.5rem;
  }
  .about-body strong { color: var(--white); font-weight: 500; }
  .director-sig {
    font-family: var(--ff-head); font-size: 0.85rem; font-weight: 600;
    letter-spacing: 0.15em; text-transform: uppercase; color: var(--turquoise);
  }

  /* PHOTO BAND (Option A) */
  .photo-band {
    display: grid; grid-template-columns: 1fr 1fr;
    gap: 4px;                          /* slim gap acts as a divider */
    padding: 0;
    background: var(--yellow);          /* shows through the gap */
  }
  .band-photo {
    margin: 0; position: relative;
    aspect-ratio: 16 / 10;              /* uniform height for both photos */
    overflow: hidden;
  }
  .band-photo img {
    width: 100%; height: 100%;
    object-fit: cover; display: block;
  }

  .action-grid-inner {
    display: grid;
    grid-template-columns: 1fr 1fr 1fr;
    grid-template-rows: 1fr 1fr;
    width: 100%; height: 100%;
    gap: 3px;
    background: var(--yellow);
  }
  .action-cell {
    overflow: hidden;
    position: relative;
  }
  .action-cell img {
    width: 100%; height: 100%;
    object-fit: cover; object-position: center center;
    display: block;
  }
  .band-caption {
    position: absolute; left: 0; right: 0; bottom: 0;
    background: linear-gradient(to top, rgba(14,14,14,0.85), transparent);
    color: var(--white); padding: 1.5rem 1.25rem 1rem;
    font-family: var(--ff-head); font-size: 0.8rem; font-weight: 600;
    letter-spacing: 0.2em; text-transform: uppercase;
  }
  @media (max-width: 700px) {
    .photo-band { grid-template-columns: 1fr; }
  }

  /* PILLARS */
  .pillars { background: var(--dark); }
  .pillars-grid { display: grid; grid-template-columns: repeat(3, 1fr); gap: 1px; background: rgba(255,255,255,0.08); }
  .pillar {
    background: var(--dark); padding: 2.5rem 2rem;
    border-top: 3px solid var(--yellow);
    transition: background 0.25s;
  }
  .pillar:nth-child(2) { border-top-color: var(--turquoise); }
  .pillar:nth-child(3) { border-top-color: var(--red); }
  .pillar:hover { background: var(--mid); }
  .pillar-icon { font-size: 2rem; margin-bottom: 1rem; display: block; }
  .pillar-title {
    font-family: var(--ff-head); font-size: 1.3rem; font-weight: 700;
    text-transform: uppercase; letter-spacing: 0.08em; color: var(--white);
    margin-bottom: 0.6rem;
  }
  .pillar-text { font-size: 0.9rem; font-weight: 300; color: var(--muted); line-height: 1.7; }

  /* CTA BAND */
  .cta-band {
    background: var(--red); padding: 4rem 2.5rem;
    display: flex; align-items: center; justify-content: space-between; gap: 2rem;
  }
  .cta-band h2 {
    font-family: var(--ff-head); font-size: clamp(1.8rem, 3.5vw, 2.8rem);
    font-weight: 900; text-transform: uppercase; color: var(--white); line-height: 1;
  }
  .cta-band p { font-size: 0.95rem; font-weight: 300; color: rgba(255,255,255,0.75); margin-top: 0.4rem; }
  .btn-white {
    font-family: var(--ff-head); font-size: 1rem; font-weight: 700;
    letter-spacing: 0.12em; text-transform: uppercase;
    background: var(--white); color: var(--red);
    border: none; padding: 0.9rem 2.2rem; cursor: pointer;
    transition: opacity 0.2s; white-space: nowrap; flex-shrink: 0;
  }
  .btn-white:hover { opacity: 0.9; }

  /* WORKOUTS */
  .workouts-hero {
    background: var(--mid); padding: 4rem 2.5rem 3rem;
    border-bottom: 1px solid rgba(255,255,255,0.06);
  }
  .schedule-grid { display: grid; grid-template-columns: repeat(2, 1fr); gap: 1.5rem; }
  .schedule-card {
    background: var(--surface); padding: 2rem;
    border-left: 3px solid var(--turquoise);
  }
  .schedule-day {
    font-family: var(--ff-head); font-size: 1.1rem; font-weight: 700;
    letter-spacing: 0.15em; text-transform: uppercase; color: var(--turquoise);
    margin-bottom: 0.4rem;
  }
  .schedule-time {
    font-family: var(--ff-head); font-size: 2rem; font-weight: 900;
    color: var(--white); margin-bottom: 0.8rem;
  }
  .schedule-desc { font-size: 0.9rem; font-weight: 300; color: var(--muted); line-height: 1.7; }
  .schedule-meta { margin-top: 0.8rem; font-size: 0.9rem; font-weight: 300; color: var(--muted); line-height: 1.7; }
  .schedule-meta div { margin-top: 0.2rem; }
  .schedule-meta strong { color: var(--white); font-weight: 500; }
  .member-note {
    background: rgba(192,57,43,0.1); border: 1px solid rgba(192,57,43,0.3);
    padding: 1.5rem 2rem; margin-top: 2.5rem;
    display: flex; gap: 1rem; align-items: flex-start;
  }
  .member-note p { font-size: 0.9rem; font-weight: 300; color: rgba(245,243,238,0.75); line-height: 1.7; }
  .member-note strong { color: var(--white); font-weight: 500; }

  /* MEMBERSHIP */
  .membership-hero {
    background: var(--mid); padding: 4rem 2.5rem 3rem;
    border-bottom: 1px solid rgba(255,255,255,0.06);
  }
  .membership-grid { display: grid; grid-template-columns: repeat(2, 1fr); gap: 2rem; }
  .plan-card {
    background: var(--surface); padding: 2.5rem;
    border: 1px solid rgba(255,255,255,0.07);
  }
  .plan-card.featured { border-color: var(--red); }
  .plan-badge {
    display: inline-block; font-family: var(--ff-head); font-size: 0.7rem;
    font-weight: 700; letter-spacing: 0.2em; text-transform: uppercase;
    background: var(--red); color: var(--white);
    padding: 0.2rem 0.7rem; margin-bottom: 1.2rem;
  }
  .plan-name {
    font-family: var(--ff-head); font-size: 1.5rem; font-weight: 900;
    text-transform: uppercase; color: var(--white); margin-bottom: 0.3rem;
  }
  .plan-price {
    font-family: var(--ff-head); font-size: 3.5rem; font-weight: 900;
    color: var(--white); line-height: 1; margin-bottom: 1.5rem;
  }
  .plan-price sup { font-size: 1.5rem; vertical-align: top; margin-top: 0.5rem; }
  .plan-period {
    font-family: var(--ff-head); font-size: 1.15rem; font-weight: 600;
    color: var(--muted); letter-spacing: 0.05em;
    margin-left: 0.35rem;
    vertical-align: middle;
  }
  .plan-features { list-style: none; margin-bottom: 2rem; }
  .plan-features li {
    font-size: 0.9rem; font-weight: 300; color: rgba(245,243,238,0.75);
    padding: 0.55rem 0; border-bottom: 1px solid rgba(255,255,255,0.06);
    display: flex; align-items: flex-start; gap: 0.6rem; line-height: 1.5;
  }
  .plan-features li::before { content: "—"; color: var(--red); flex-shrink: 0; }

  /* COACHES */
  .coaches-section { background: var(--mid); }
  .coaches-grid { display: grid; grid-template-columns: repeat(2, 1fr); gap: 1.5rem; }
  .coach-card {
    background: var(--dark); padding: 2rem;
    border: 1px solid rgba(255,255,255,0.06);
  }
  .coach-name {
    font-family: var(--ff-head); font-size: 1.3rem; font-weight: 900;
    text-transform: uppercase; color: var(--white); margin-bottom: 0.2rem;
  }
  .coach-title {
    font-family: var(--ff-head); font-size: 0.8rem; font-weight: 600;
    letter-spacing: 0.15em; text-transform: uppercase; color: var(--turquoise);
    margin-bottom: 0.8rem;
  }
  .coach-bio { font-size: 0.88rem; font-weight: 300; color: rgba(245,243,238,0.8); line-height: 1.7; }
  .coach-bio-list {
    font-family: var(--ff-body);
    font-size: 0.88rem;
    font-weight: 300;
    color: rgba(245,243,238,0.8);
    line-height: 1.7;
    list-style-type: disc;
    list-style-position: outside;
    /* padding-left gives the markers room after the global padding reset;
       margin-left indents the whole list past the surrounding bio text. */
    padding-left: 1.5em;
    margin: 0.45rem 0 0.85rem 1.25em;
  }
  .coach-bio-list li {
    display: list-item;
    font-family: var(--ff-body);
    font-size: 0.88rem;
    font-weight: 300;
    color: rgba(245,243,238,0.8);
    line-height: 1.7;
    margin: 0.15rem 0;
  }
  .coach-bio-list li::marker { color: inherit; }

  /* CONTACT */
  .contact-section { background: var(--dark); }
  .contact-grid { display: grid; grid-template-columns: 1fr 1fr; gap: 4rem; }
  .contact-item { margin-bottom: 2rem; }
  .contact-item-label {
    font-family: var(--ff-head); font-size: 0.75rem; font-weight: 700;
    letter-spacing: 0.25em; text-transform: uppercase; color: var(--muted);
    margin-bottom: 0.3rem;
  }
  .contact-item-value { font-size: 1.05rem; font-weight: 300; color: var(--white); }
  .form-field { margin-bottom: 1.2rem; }
  .form-field label {
    display: block; font-family: var(--ff-head); font-size: 0.75rem;
    font-weight: 700; letter-spacing: 0.2em; text-transform: uppercase;
    color: var(--muted); margin-bottom: 0.4rem;
  }
  .form-field input, .form-field textarea, .form-field select {
    width: 100%; background: var(--surface);
    border: 1px solid rgba(255,255,255,0.1); border-radius: 0;
    color: var(--white); font-family: var(--ff-body); font-size: 0.95rem;
    padding: 0.7rem 0.9rem; outline: none; transition: border-color 0.2s;
    font-weight: 300;
  }
  .form-field input:focus, .form-field textarea:focus, .form-field select:focus {
    border-color: var(--red);
  }
  .form-field textarea { resize: vertical; min-height: 120px; }
  .form-field select option { background: var(--surface); }

  /* FOUNDING */
  .founding { background: var(--surface); padding: 3rem 2.5rem; }
  .founding-title {
    font-family: var(--ff-head); font-size: 0.75rem; font-weight: 700;
    letter-spacing: 0.3em; text-transform: uppercase; color: var(--muted);
    margin-bottom: 1rem;
  }
  .founding-names {
    display: flex; flex-wrap: wrap; gap: 0.5rem 1.5rem;
    font-family: var(--ff-head); font-size: 1rem; font-weight: 600;
    text-transform: uppercase; letter-spacing: 0.05em; color: rgba(245,243,238,0.5);
  }
  .in-memory {
    font-family: var(--ff-body); font-size: 0.82rem; font-weight: 300;
    color: var(--muted); margin-top: 0.8rem; font-style: italic;
  }

  /* FOOTER */
  footer {
    background: #080808; padding: 3rem 2.5rem;
    border-top: 1px solid rgba(255,255,255,0.06);
    display: flex; align-items: center; justify-content: space-between;
    flex-wrap: wrap; gap: 1rem;
  }
  .footer-logo {
    font-family: var(--ff-head); font-size: 1.1rem; font-weight: 900;
    letter-spacing: 0.12em; text-transform: uppercase; color: var(--white);
  }
  .footer-logo span { color: var(--turquoise); }
  .footer-copy { font-size: 0.8rem; font-weight: 300; color: var(--muted); }
  .footer-phone { font-size: 0.9rem; font-weight: 400; color: rgba(245,243,238,0.6); }
  .footer-phone a { color: var(--red); text-decoration: none; }
  .footer-email { font-size: 0.9rem; font-weight: 400; color: rgba(245,243,238,0.6); }
  .footer-email a { color: var(--turquoise); text-decoration: none; transition: color 0.2s; }
  .footer-email a:hover { color: var(--white); }
  /* Group phone + social vertically so the outer footer stays 3 slots. */
  .footer-contact {
    display: flex; flex-direction: column; align-items: flex-end;
    gap: 0.4rem;
  }
  .footer-social {
    display: inline-flex; align-items: center; gap: 0.45rem;
    font-family: var(--ff-body); font-size: 0.9rem; font-weight: 400;
    color: rgba(245,243,238,0.6);
    text-decoration: none;
    transition: color 0.2s;
  }
  .footer-social:hover { color: var(--turquoise); }
  .footer-social svg { flex-shrink: 0; }

  /* Instagram link within the Contact Information column. */
  .contact-social {
    display: inline-flex; align-items: center; gap: 0.5rem;
    color: var(--white); text-decoration: none;
    border-bottom: 1px dotted rgba(245,243,238,0.3);
    padding-bottom: 2px;
    transition: color 0.2s, border-color 0.2s;
  }
  .contact-social:hover { color: var(--turquoise); border-bottom-color: var(--turquoise); }

  /* Plain text links inside a contact-item-value (e.g. the flyer PDF). */
  .contact-link {
    color: rgba(245,243,238,0.85); text-decoration: none;
    border-bottom: 1px dotted rgba(245,243,238,0.4);
    padding-bottom: 1px;
    transition: color 0.2s, border-color 0.2s;
  }
  .contact-link:hover { color: var(--turquoise); border-bottom-color: var(--turquoise); }

  /* ─── ACCESSIBILITY ─── */
  .skip-link {
    position: absolute; top: -40px; left: 0; z-index: 200;
    background: var(--red); color: var(--white);
    padding: 0.6rem 1rem; text-decoration: none;
    font-family: var(--ff-head); font-size: 0.85rem;
    font-weight: 700; letter-spacing: 0.1em; text-transform: uppercase;
    transition: top 0.2s;
  }
  .skip-link:focus { top: 0; }

  /* Visible focus for keyboard users */
  a:focus-visible, button:focus-visible,
  input:focus-visible, textarea:focus-visible, select:focus-visible {
    outline: 2px solid var(--gold);
    outline-offset: 2px;
  }
  /* Form controls already have a red border on :focus — keep that, layer outline for keyboard nav */

  /* ─── HAMBURGER (hidden on desktop) ─── */
  .nav-toggle {
    display: none;
    background: transparent; border: none; cursor: pointer;
    padding: 0.4rem; margin-left: auto;
  }
  .nav-toggle span {
    display: block; width: 26px; height: 2px;
    background: var(--white); margin: 5px 0;
    transition: transform 0.25s, opacity 0.25s;
  }
  .nav-open .nav-toggle span:nth-child(1) { transform: translateY(7px) rotate(45deg); }
  .nav-open .nav-toggle span:nth-child(2) { opacity: 0; }
  .nav-open .nav-toggle span:nth-child(3) { transform: translateY(-7px) rotate(-45deg); }

  /* ─── RESPONSIVE ─── */
  @media (max-width: 900px) {
    nav { padding: 0 1.25rem; }
    .nav-logo img { height: 36px; width: 54px; }
    .nav-toggle { display: block; order: 3; }
    .nav-cta { display: none; }
    .nav-links {
      position: fixed; top: 60px; left: 0; right: 0;
      flex-direction: column; gap: 0;
      background: rgba(14,14,14,0.98); backdrop-filter: blur(10px);
      border-bottom: 1px solid rgba(192,57,43,0.3);
      padding: 1rem 1.5rem 1.5rem;
      /* Push fully off-screen: own height + the 60px top offset + 20px buffer.
         translateY(-110%) wasn't enough when the menu was short — its bottom
         edge stayed inside the nav area and the red Join Now button leaked. */
      transform: translateY(calc(-100% - 80px));
      transition: transform 0.25s ease;
      /* Layer above the nav while open so menu sits cleanly on top */
      z-index: 99;
    }
    .nav-open .nav-links { transform: translateY(0); }
    .nav-links li { width: 100%; border-bottom: 1px solid rgba(255,255,255,0.06); }
    .nav-links li:last-child { border-bottom: none; }
    .nav-links a {
      display: block; padding: 1rem 0; font-size: 1rem;
    }
    .mobile-cta-item { display: list-item; }
    .nav-links .mobile-cta {
      display: inline-block; margin-top: 0.5rem;
      background: var(--red); color: var(--white);
      padding: 0.6rem 1.2rem;
    }

    section { padding: 3.5rem 1.5rem; }
    .hero { padding: 4rem 1.5rem 3rem; min-height: auto; }
    .hero-stats {
      gap: 2rem; margin-top: 2.5rem;
      flex-wrap: wrap;          /* allow wrapping on very narrow screens */
    }
    .stat-num { font-size: 2.2rem; }

    .pillars-grid { grid-template-columns: 1fr; }
    .schedule-grid { grid-template-columns: 1fr; gap: 1rem; }
    .membership-grid { grid-template-columns: 1fr; gap: 1.5rem; }
    .coaches-grid { grid-template-columns: 1fr; }
    .contact-grid { grid-template-columns: 1fr; gap: 2rem; }

    .workouts-hero, .membership-hero { padding: 3rem 1.5rem 2rem; }
    .cta-band {
      padding: 2.5rem 1.5rem;
      flex-direction: column; align-items: flex-start; gap: 1.25rem;
    }
    .btn-white { width: 100%; }

    footer {
      padding: 2rem 1.5rem;
      flex-direction: column; align-items: flex-start; gap: 0.75rem;
    }
    .footer-contact { align-items: flex-start; }
    .founding { padding: 2.5rem 1.5rem; }
  }

  @media (max-width: 600px) {
    .hero-eyebrow { font-size: 0.75rem; }
    .hero-actions { flex-direction: column; align-items: stretch; }
    .hero-actions .btn-primary, .hero-actions .btn-secondary { width: 100%; text-align: center; }
    .plan-card { padding: 1.75rem 1.25rem; }
    .plan-price { font-size: 2.8rem; }
    .form-status { font-size: 0.85rem; }
  }

  /* ─── FORM STATUS ─── */
  .form-status {
    margin-top: 1rem; padding: 0.75rem 1rem;
    font-family: var(--ff-body); font-size: 0.9rem; font-weight: 300;
    border-left: 3px solid var(--gold);
    background: rgba(212,160,23,0.08); color: var(--light);
    display: none;
  }
  .form-status.visible { display: block; }
  .form-status.error { border-color: var(--red); background: rgba(192,57,43,0.1); }
  .form-status.success { border-color: var(--turquoise); background: rgba(31,176,192,0.1); color: var(--white); }

  /* Required-field indicator */
  .form-field label .req { color: var(--red); margin-left: 0.2rem; }

  /* ─── UPCOMING EVENTS ─── */
  .events-section { background: var(--dark); }
  .events-grid {
    display: grid; grid-template-columns: 1fr; gap: 1rem;
  }
  .event-card {
    background: var(--surface);
    border-left: 3px solid var(--red);
    padding: 1.5rem 1.75rem;
    display: grid;
    grid-template-columns: 84px 1fr auto;
    gap: 1.5rem;
    align-items: center;
  }
  .event-date {
    display: flex; flex-direction: column; align-items: center;
    padding: 0.6rem 0.5rem;
    background: var(--dark);
    border: 1px solid rgba(255,255,255,0.06);
    min-width: 0;
  }
  .event-date-month {
    font-family: var(--ff-head); font-size: 0.75rem; font-weight: 700;
    letter-spacing: 0.2em; text-transform: uppercase; color: var(--turquoise);
    line-height: 1;
  }
  .event-date-day {
    font-family: var(--ff-head); font-size: 1.9rem; font-weight: 900;
    line-height: 1.1; color: var(--white);
  }
  .event-body { min-width: 0; }
  .event-name {
    font-family: var(--ff-head); font-size: 1.15rem; font-weight: 700;
    text-transform: uppercase; letter-spacing: 0.05em; color: var(--white);
    margin-bottom: 0.2rem; line-height: 1.2;
  }
  .event-meta {
    font-size: 0.82rem; font-weight: 400; color: var(--turquoise);
    letter-spacing: 0.03em; margin-bottom: 0.4rem;
  }
  .event-desc {
    font-size: 0.9rem; font-weight: 300; color: var(--muted);
    line-height: 1.55;
  }
  .event-link {
    font-family: var(--ff-head); font-size: 0.8rem; font-weight: 700;
    letter-spacing: 0.15em; text-transform: uppercase;
    color: var(--yellow); text-decoration: none;
    white-space: nowrap;
  }
  .event-link:hover { color: var(--white); }
  .events-empty {
    color: var(--muted); font-size: 0.95rem; font-weight: 300;
    line-height: 1.6; padding: 1.5rem 0;
  }

  /* Home-page teaser variant — more compact */
  .events-teaser-header {
    display: flex; justify-content: space-between; align-items: flex-end;
    gap: 1rem; flex-wrap: wrap;
    max-width: 860px; margin-bottom: 2rem;
  }
  .events-teaser-header .section-title { margin-bottom: 0; }
  .teaser-cta {
    font-family: var(--ff-head); font-size: 0.85rem; font-weight: 700;
    letter-spacing: 0.15em; text-transform: uppercase;
    color: var(--turquoise); text-decoration: none;
    padding-bottom: 4px; border-bottom: 1px solid var(--turquoise);
  }
  .teaser-cta:hover { color: var(--white); border-color: var(--white); }
  .events-teaser .event-card {
    padding: 1.2rem 1.4rem;
    grid-template-columns: 72px 1fr;
  }
  .events-teaser .event-link { display: none; }   /* teaser cards go to Workouts page for link */
  .events-teaser .event-desc { display: none; }   /* keep teaser tidy */

  @media (max-width: 700px) {
    .event-card {
      grid-template-columns: 72px 1fr;
      grid-template-rows: auto auto;
      row-gap: 0.75rem; column-gap: 1rem;
      padding: 1.25rem 1.25rem;
    }
    .event-link {
      grid-column: 1 / -1;
      justify-self: start;
      margin-top: 0.25rem;
    }
    .event-date-day { font-size: 1.6rem; }
  }

  /* ─── RECENT RESULTS (event-grouped, auto-layout) ─── */
  .results-section { background: var(--dark); }
  .results-grid {
    display: flex; flex-direction: column; gap: 1rem;
  }

  /* Previous-year archives sit after the current-year cards. Native
     <details> keeps them collapsed until tapped; event cards inside
     reuse the same card styles as the current year. */
  .results-year-archive { margin-top: 1.5rem; }
  .results-year-details {
    background: var(--surface);
    border-left: 3px solid var(--turquoise);
  }
  .results-year-details > summary {
    list-style: none;
    cursor: pointer;
    user-select: none;
  }
  .results-year-details > summary::-webkit-details-marker { display: none; }
  .results-year-details > summary::marker { display: none; }
  .results-year-header {
    display: flex; align-items: center; gap: 1rem;
    padding: 1.25rem 1.75rem;
  }
  .results-year-title {
    flex: 1; min-width: 0;
    font-family: var(--ff-head); font-size: 1.2rem; font-weight: 800;
    text-transform: uppercase; letter-spacing: 0.05em;
    color: var(--white); line-height: 1.2;
  }
  .results-year-details[open] > summary.results-year-header {
    border-bottom: 1px solid rgba(255,255,255,0.08);
  }
  .results-year-details[open] > summary .event-result-toggle {
    transform: rotate(-135deg);
    margin-top: 0.35rem;
  }
  .results-year-details > summary:hover .event-result-toggle,
  .results-year-details > summary:focus-visible .event-result-toggle {
    border-color: var(--white);
  }
  .results-year-events {
    display: flex; flex-direction: column; gap: 1rem;
    padding: 1rem 1.75rem 1.5rem;
  }

  .event-result-card {
    background: var(--surface);
    border-left: 3px solid var(--yellow);
    padding: 1.5rem 1.75rem;
  }

  /* Native <details>/<summary> handles the collapse/expand.
     Marker is hidden and replaced with a chevron on the right. */
  .event-result-details > summary {
    list-style: none;   /* Firefox */
    cursor: pointer;
    user-select: none;
  }
  .event-result-details > summary::-webkit-details-marker { display: none; }
  .event-result-details > summary::marker { display: none; }

  .event-result-header {
    display: flex; align-items: center; gap: 1rem;
  }
  .event-result-header-text {
    flex: 1; min-width: 0;
    display: flex; justify-content: space-between; align-items: baseline;
    gap: 1rem; flex-wrap: wrap;
  }
  /* Divider between header and body — only visible when the card is open. */
  .event-result-details[open] > summary .event-result-header {
    padding-bottom: 0.85rem;
    margin-bottom: 1rem;
    border-bottom: 1px solid rgba(255,255,255,0.08);
  }

  /* Chevron: pointing down when collapsed, up when open. */
  .event-result-toggle {
    flex-shrink: 0;
    width: 10px; height: 10px;
    border-right: 2px solid var(--turquoise);
    border-bottom: 2px solid var(--turquoise);
    transform: rotate(45deg);
    transition: transform 0.2s ease;
    margin-right: 0.35rem;   /* visually center the diamond in its box */
  }
  .event-result-details[open] > summary .event-result-toggle {
    transform: rotate(-135deg);
    margin-top: 0.35rem;     /* compensate rotation so the arrow visually centers */
  }
  .event-result-details > summary:hover .event-result-toggle,
  .event-result-details > summary:focus-visible .event-result-toggle {
    border-color: var(--white);
  }

  .event-result-title {
    font-family: var(--ff-head); font-size: 1.2rem; font-weight: 800;
    text-transform: uppercase; letter-spacing: 0.05em;
    color: var(--white); line-height: 1.2;
  }
  .event-result-meta-block {
    display: flex; flex-direction: column;
    align-items: flex-end;
    gap: 0.2rem;
  }
  .event-result-meta {
    font-family: var(--ff-body); font-size: 0.85rem; font-weight: 400;
    color: var(--turquoise); letter-spacing: 0.02em;
  }
  .event-result-meta a {
    color: inherit; text-decoration: none;
    border-bottom: 1px dotted rgba(31,176,192,0.5);
  }
  .event-result-meta a:hover { color: var(--white); border-bottom-color: var(--white); }
  .event-result-counts {
    font-family: var(--ff-head);
    font-size: 0.7rem; font-weight: 700;
    letter-spacing: 0.15em; text-transform: uppercase;
    color: var(--muted);
  }

  .result-subgroup { margin-top: 1rem; }
  .result-subgroup:first-child { margin-top: 0; }
  .result-subgroup-name {
    font-family: var(--ff-head); font-size: 0.8rem; font-weight: 700;
    text-transform: uppercase; letter-spacing: 0.2em;
    color: var(--yellow);
    margin-bottom: 0.4rem;
  }

  /* Day block wraps day header + its discipline sub-groups (multi-day events only). */
  .result-day-block { margin-top: 1.4rem; }
  .result-day-block:first-child { margin-top: 0; }
  .result-day-header {
    display: flex; align-items: baseline; gap: 0.75rem;
    font-family: var(--ff-head); font-size: 0.95rem; font-weight: 800;
    letter-spacing: 0.2em; text-transform: uppercase;
    color: var(--turquoise);
    margin-bottom: 0.75rem;
  }
  /* Dashed rule extending from the label across the card width. */
  .result-day-header::after {
    content: ""; flex: 1;
    border-top: 1px dashed rgba(31,176,192,0.35);
    transform: translateY(-0.15em);
  }
  .result-row {
    display: grid;
    grid-template-columns: 1fr 130px 90px;
    align-items: baseline;
    gap: 0.25rem 1rem;
    padding: 0.4rem 0;
    border-top: 1px solid rgba(255,255,255,0.04);
  }
  .result-row:first-child { border-top: none; }
  .result-primary {
    font-family: var(--ff-body); font-size: 0.95rem; font-weight: 500;
    color: var(--white);
  }
  .result-place {
    font-family: var(--ff-head); font-size: 0.85rem; font-weight: 700;
    letter-spacing: 0.05em; text-transform: uppercase;
    color: var(--turquoise); text-align: right;
    white-space: nowrap;
  }
  .result-time {
    font-family: var(--ff-head); font-size: 1rem; font-weight: 900;
    color: var(--white); text-align: right;
    white-space: nowrap; letter-spacing: 0.01em;
  }
  .result-note {
    grid-column: 1 / -1;
    font-family: var(--ff-body); font-size: 0.8rem; font-weight: 300;
    font-style: italic; color: var(--muted);
    line-height: 1.4; padding-top: 0.15rem;
  }

  .results-empty {
    color: var(--muted); font-size: 0.95rem; font-weight: 300;
    line-height: 1.6; padding: 1.5rem 0;
  }

  @media (max-width: 700px) {
    .results-year-header { padding: 1.1rem 1.25rem; }
    .results-year-events { padding: 1rem 1.25rem 1.25rem; }
    .event-result-card { padding: 1.25rem 1.25rem; }
    .event-result-header-text { flex-direction: column; align-items: flex-start; gap: 0.35rem; }
    .event-result-meta-block { align-items: flex-start; }
    .result-row {
      grid-template-columns: 1fr auto auto;
      column-gap: 0.75rem;
    }
    .result-time { font-size: 0.95rem; }
  }

  /* ─── PHOTO GALLERY (event cards, collapsible, small thumbnails) ─── */
  .gallery-section { background: var(--dark); }
  .gallery-events {
    display: flex; flex-direction: column; gap: 1rem;
  }
  .gallery-event-card {
    background: var(--surface);
    border-left: 3px solid var(--turquoise);
    padding: 1.5rem 1.75rem;
  }

  /* Native <details>/<summary> — same collapsible pattern used by results. */
  .gallery-event-details > summary {
    list-style: none;
    cursor: pointer;
    user-select: none;
  }
  .gallery-event-details > summary::-webkit-details-marker { display: none; }
  .gallery-event-details > summary::marker { display: none; }

  .gallery-event-header {
    display: flex; align-items: center; gap: 1rem;
  }
  .gallery-event-header-text {
    flex: 1; min-width: 0;
    display: flex; justify-content: space-between; align-items: baseline;
    gap: 1rem; flex-wrap: wrap;
  }
  /* Divider between header and photo grid — only visible when open. */
  .gallery-event-details[open] > summary .gallery-event-header {
    padding-bottom: 0.85rem;
    margin-bottom: 1.25rem;
    border-bottom: 1px solid rgba(255,255,255,0.08);
  }
  .gallery-event-title {
    font-family: var(--ff-head); font-size: 1.2rem; font-weight: 800;
    text-transform: uppercase; letter-spacing: 0.05em;
    color: var(--white); line-height: 1.2;
  }
  .gallery-event-meta-block {
    display: flex; flex-direction: column;
    align-items: flex-end;
    gap: 0.2rem;
  }
  .gallery-event-meta {
    font-family: var(--ff-body); font-size: 0.85rem; font-weight: 400;
    color: var(--turquoise); letter-spacing: 0.02em;
  }
  .gallery-event-counts {
    font-family: var(--ff-head);
    font-size: 0.7rem; font-weight: 700;
    letter-spacing: 0.15em; text-transform: uppercase;
    color: var(--muted);
  }

  /* Chevron matches results toggle style. */
  .gallery-event-toggle {
    flex-shrink: 0;
    width: 10px; height: 10px;
    border-right: 2px solid var(--turquoise);
    border-bottom: 2px solid var(--turquoise);
    transform: rotate(45deg);
    transition: transform 0.2s ease;
    margin-right: 0.35rem;
  }
  .gallery-event-details[open] > summary .gallery-event-toggle {
    transform: rotate(-135deg);
    margin-top: 0.35rem;
  }
  .gallery-event-details > summary:hover .gallery-event-toggle,
  .gallery-event-details > summary:focus-visible .gallery-event-toggle {
    border-color: var(--white);
  }

  /* Smaller thumbnails — auto-fill grid means more per row on wider viewports,
     naturally reflowing to fewer on narrow. */
  .gallery-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(170px, 1fr));
    gap: 0.6rem;
  }
  .gallery-item {
    display: flex; flex-direction: column;
    background: var(--dark);
  }
  .gallery-thumb {
    display: block;
    aspect-ratio: 4 / 3;
    overflow: hidden;
    background: var(--dark);
  }
  .gallery-thumb img {
    width: 100%; height: 100%;
    object-fit: cover; display: block;
    transition: transform 0.35s ease, opacity 0.2s;
  }
  .gallery-thumb:hover img,
  .gallery-thumb:focus-visible img { transform: scale(1.04); }
  .gallery-caption {
    font-family: var(--ff-body); font-size: 0.72rem; font-weight: 300;
    color: var(--muted); font-style: italic;
    padding: 0.4rem 0.15rem 0;
    line-height: 1.35;
  }
  .gallery-empty {
    color: var(--muted); font-size: 0.95rem; font-weight: 300;
    line-height: 1.6; padding: 1.5rem 0;
  }
  @media (max-width: 700px) {
    .gallery-event-card { padding: 1.25rem 1.25rem; }
    .gallery-event-header-text { flex-direction: column; align-items: flex-start; gap: 0.35rem; }
    .gallery-event-meta-block { align-items: flex-start; }
    .gallery-grid { grid-template-columns: repeat(auto-fill, minmax(140px, 1fr)); }
  }

  /* ─── GALLERY LIGHTBOX ─── */
  /* Fullscreen overlay that shows a single gallery photo. Created and
     managed by main.js. On mobile it solves the "new tab" problem: the
     visitor never leaves the gallery page. */
  .lightbox {
    position: fixed; inset: 0; z-index: 1000;
    display: flex; align-items: center; justify-content: center;
    background: rgba(0,0,0,0.92);
    padding: 2rem;
  }
  .lightbox[hidden] { display: none; }
  .lightbox-stage {
    max-width: 100%; max-height: 100%;
    display: flex; flex-direction: column; align-items: center;
    gap: 0.6rem;
  }
  .lightbox-img {
    max-width: 100%; max-height: 78vh;
    object-fit: contain;
    display: block;
    background: #000;
    box-shadow: 0 20px 60px rgba(0,0,0,0.6);
  }
  .lightbox-caption {
    color: var(--light); font-size: 0.9rem;
    text-align: center; max-width: 80vw;
    font-style: italic; line-height: 1.4;
  }
  .lightbox-counter {
    color: var(--muted); font-size: 0.7rem;
    letter-spacing: 0.2em; text-transform: uppercase;
    font-family: var(--ff-head); font-weight: 700;
  }
  .lightbox-close,
  .lightbox-prev,
  .lightbox-next {
    position: absolute;
    background: rgba(0,0,0,0.55);
    border: 1px solid rgba(255,255,255,0.2);
    color: var(--white);
    cursor: pointer;
    width: 44px; height: 44px;
    border-radius: 50%;
    display: flex; align-items: center; justify-content: center;
    font-size: 1.6rem; line-height: 1;
    transition: background 0.2s, border-color 0.2s, transform 0.15s;
    touch-action: manipulation;
    -webkit-tap-highlight-color: transparent;
  }
  .lightbox-close:hover, .lightbox-close:focus-visible,
  .lightbox-prev:hover,  .lightbox-prev:focus-visible,
  .lightbox-next:hover,  .lightbox-next:focus-visible {
    background: rgba(31,176,192,0.55);
    border-color: var(--turquoise);
    outline: none;
  }
  .lightbox-close { top: 1rem; right: 1rem; }
  .lightbox-prev  { left: 1rem;  top: 50%; transform: translateY(-50%); }
  .lightbox-next  { right: 1rem; top: 50%; transform: translateY(-50%); }
  .lightbox-prev:hover, .lightbox-prev:focus-visible { transform: translateY(-50%) scale(1.06); }
  .lightbox-next:hover, .lightbox-next:focus-visible { transform: translateY(-50%) scale(1.06); }
  .lightbox-prev[hidden], .lightbox-next[hidden] { display: none; }
  @media (max-width: 600px) {
    .lightbox { padding: 1rem; }
    .lightbox-prev, .lightbox-next {
      width: 40px; height: 40px; font-size: 1.35rem;
    }
    .lightbox-prev { left: 0.5rem; }
    .lightbox-next { right: 0.5rem; }
    .lightbox-close {
      top: 0.5rem; right: 0.5rem;
      width: 40px; height: 40px; font-size: 1.35rem;
    }
    .lightbox-img { max-height: 72vh; }
  }
