/* ==========================================================================
   Bares Taekwondo Fitness — styles.css
   Plain CSS, no preprocessor. Mobile-first.
   ========================================================================== */

:root {
  /* BRAND: sampled from the live barestkd.fit site (Duda theme).
     Primary action red = live --btn-bg-color rgba(233,41,45); button text = white.
     Body text = live rgba(75,76,83). Backgrounds = white / #f2f2f2 light gray. */
  --ink: #1a1a1a;          /* near-black — headings / primary text */
  --paper: #ffffff;        /* white — main background (live content bg) */
  --belt-red: #e9292d;     /* live brand red — primary action color */
  --belt-red-dark: #c81f23;/* darker red for hover (live hover is black; kept on-theme) */
  --belt-gold: #c8992e;    /* minor accent: belt-stripe divider + focus ring */
  --mat-gray: #f2f2f2;     /* light gray section background (live) */

  --ink-soft: #4b4c53;     /* live muted body-text gray */
  --line: #dcdcdc;
  --white: #ffffff;

  --maxw: 1140px;
  --gutter: clamp(1rem, 4vw, 2rem);
  --radius: 10px;
  --shadow: 0 6px 24px rgba(0, 0, 0, 0.10);

  /* Display/headings: live site uses "Winner Sans" (proprietary — Latinotype, not on
     Google Fonts). Archivo Black is kept as the closest freely-available match. */
  --font-display: "Archivo Black", system-ui, -apple-system, "Segoe UI", sans-serif;
  /* Body + buttons: Montserrat — exact match to the live site (free Google Font). */
  --font-body: "Montserrat", system-ui, -apple-system, "Segoe UI", Roboto, Helvetica, Arial, sans-serif;

  --header-h: 68px;
}

/* --------------------------------------------------------------------------
   Reset / base
   -------------------------------------------------------------------------- */
*, *::before, *::after { box-sizing: border-box; }
/* overflow-x: clip is insurance only — the real overflow fixes live in the
   header grid and the form-control min-width rules. clip (not hidden) does
   NOT create a scroll container, so it never breaks the sticky header. */
html, body { overflow-x: clip; }
html { -webkit-text-size-adjust: 100%; scroll-behavior: smooth; }
@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }
}

body {
  margin: 0;
  font-family: var(--font-body);
  font-size: 1.0625rem;
  line-height: 1.65;
  color: var(--ink);
  background: var(--paper);
  -webkit-font-smoothing: antialiased;
}

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

a { color: var(--belt-red); text-decoration: underline; text-underline-offset: 2px; }
a:hover { color: var(--belt-red-dark); }

h1, h2, h3 {
  font-family: var(--font-display);
  font-weight: 400;
  line-height: 1.08;
  text-transform: uppercase;
  letter-spacing: 0.02em;
  margin: 0 0 0.5em;
}
h1 { font-size: clamp(1.9rem, 6vw, 3.25rem); }
h2 { font-size: clamp(1.5rem, 4.5vw, 2.25rem); }
h3 { font-size: clamp(1.15rem, 3vw, 1.4rem); letter-spacing: 0.01em; }
p { margin: 0 0 1rem; max-width: 66ch; }

/* --------------------------------------------------------------------------
   Accessibility helpers
   -------------------------------------------------------------------------- */
:focus-visible {
  outline: 3px solid var(--belt-gold);
  outline-offset: 2px;
  border-radius: 3px;
}

.visually-hidden {
  position: absolute !important;
  width: 1px; height: 1px;
  padding: 0; margin: -1px;
  overflow: hidden; clip: rect(0 0 0 0);
  white-space: nowrap; border: 0;
}

.skip-link {
  position: absolute; left: 0; top: -60px;
  background: var(--ink); color: var(--white);
  padding: 0.6rem 1rem; z-index: 200;
  transition: top 0.15s ease;
  text-decoration: none;
}
.skip-link:focus { top: 0; color: var(--white); }

/* --------------------------------------------------------------------------
   Layout
   -------------------------------------------------------------------------- */
.container {
  width: 100%;
  max-width: var(--maxw);
  margin-inline: auto;
  padding-inline: var(--gutter);
}

.section { padding-block: clamp(2.5rem, 7vw, 4.5rem); }
.section--mat { background: var(--mat-gray); }
.section--ink { background: var(--ink); color: var(--paper); }
.section--ink h1, .section--ink h2, .section--ink h3 { color: var(--white); }
.section__lead { max-width: 60ch; color: var(--ink-soft); }
.section--ink .section__lead { color: #d7cfc4; }

.eyebrow {
  font-family: var(--font-display);
  text-transform: uppercase;
  letter-spacing: 0.14em;
  font-size: 0.8rem;
  color: var(--belt-red);
  margin: 0 0 0.5rem;
}
.section--ink .eyebrow { color: var(--belt-gold); }

/* --------------------------------------------------------------------------
   Belt-stripe divider — the one signature decorative element
   -------------------------------------------------------------------------- */
.belt-divider {
  height: 14px;
  background: var(--ink);
  position: relative;
  width: 100%;
  border: none;
  margin: 0;
}
.belt-divider::after {
  /* three/four short rank stripes near one end */
  content: "";
  position: absolute;
  top: 0; bottom: 0;
  left: 24px;
  width: 132px;
  background-image: linear-gradient(
    to right,
    var(--belt-gold) 0 24px, transparent 24px 36px,
    var(--belt-gold) 36px 60px, transparent 60px 72px,
    var(--belt-gold) 72px 96px, transparent 96px 108px,
    var(--belt-gold) 108px 132px
  );
}

/* --------------------------------------------------------------------------
   Buttons
   -------------------------------------------------------------------------- */
.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 0.5rem;
  font-family: var(--font-body);   /* Montserrat 700 — matches live site buttons */
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.05em;
  font-size: 0.95rem;
  line-height: 1;
  padding: 0.95rem 1.5rem;
  min-height: 48px;
  border-radius: var(--radius);
  border: 3px solid var(--belt-red);
  text-decoration: none;
  cursor: pointer;
  transition: background-color 0.15s ease, color 0.15s ease, transform 0.05s ease;
}
.btn:active { transform: translateY(1px); }

.btn--primary { background: var(--belt-red); color: var(--white); }
.btn--primary:hover { background: var(--belt-red-dark); border-color: var(--belt-red-dark); color: var(--white); }

.btn--secondary { background: transparent; color: var(--ink); border-color: var(--ink); }
.btn--secondary:hover { background: var(--ink); color: var(--white); }

.section--ink .btn--secondary { color: var(--white); border-color: var(--white); }
.section--ink .btn--secondary:hover { background: var(--white); color: var(--ink); }

.btn--lg { font-size: 1.05rem; padding: 1.1rem 1.9rem; min-height: 54px; }

/* --------------------------------------------------------------------------
   Header / nav
   -------------------------------------------------------------------------- */
.site-header {
  position: sticky;
  top: 0;
  z-index: 100;
  background: var(--paper);
  border-bottom: 1px solid var(--line);
}
/* Contact links live in the main header row on wider desktops (mobile uses the
   header phone icon + the bottom action bar). */
.header-ask { display: none; }
@media (min-width: 1760px) {
  .call-link .call-link__num { display: inline; font-weight: 700; }
  .header-ask {
    display: inline-flex; align-items: center; flex-shrink: 0;
    color: var(--ink); font-family: var(--font-body); font-weight: 700;
    font-size: 0.9rem; text-decoration: none; white-space: nowrap;
    margin-inline-start: 0.35rem;
  }
  .header-ask:hover { color: var(--belt-red); }
}
/* Mobile: three-column grid centers the logo in the full header width with
   the hamburger pinned to the end column. This can't overflow — the balanced
   1fr spacers absorb the free space instead of pushing anything off-screen. */
.site-header__inner {
  display: grid;
  grid-template-columns: 1fr auto 1fr;
  align-items: center;
  gap: 1rem;
  min-height: var(--header-h);
  padding-block: 0.5rem;
}
.brand {
  display: inline-flex;
  align-items: center;
  text-decoration: none;
  color: var(--ink);
  grid-column: 2;                /* middle column => visually centered */
  grid-row: 1;
  justify-self: center;
  min-width: 0;
}
.brand img { height: 54px; width: auto; }  /* logo stands alone, slightly larger */

.nav-toggle {
  grid-column: 3;                /* end column, stays tappable at the edge */
  grid-row: 1;
  justify-self: end;
  display: inline-flex;
  flex-direction: column;
  justify-content: center;
  gap: 5px;
  width: 46px; height: 46px;
  background: transparent;
  border: 2px solid var(--line);
  border-radius: 8px;
  cursor: pointer;
}
.nav-toggle span { display: block; height: 3px; width: 22px; margin-inline: auto; background: var(--ink); border-radius: 2px; }

/* Secondary tap-to-call link. Mobile: a compact icon-only button in the left
   header column, mirroring the hamburger and keeping the logo centered.
   Desktop: icon + number, no border, sitting left of the red trial CTA. */
.call-link {
  grid-column: 1;
  grid-row: 1;
  justify-self: start;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 0.4rem;
  width: 46px; height: 46px;
  border: 2px solid var(--line);
  border-radius: 8px;
  color: var(--ink);
  text-decoration: none;
  font-weight: 700;
}
.call-link__icon { width: 22px; height: 22px; color: var(--belt-red); flex: 0 0 auto; }
.call-link__num { display: none; }

.primary-nav { display: none; }
.header-cta { display: none; }

/* Homepage only: the header CTA hides while the hero is on screen and fades
   in once the user scrolls past it (toggled by JS adding .hero-cta-hidden to
   the header). Interior pages have no .hero, so the button stays visible. */
.header-cta:not(.header-cta--mobile) { transition: opacity 0.3s ease, visibility 0.3s ease; }
.site-header.hero-cta-hidden .header-cta:not(.header-cta--mobile) {
  opacity: 0;
  visibility: hidden;
  pointer-events: none;
}
@media (prefers-reduced-motion: reduce) {
  .header-cta:not(.header-cta--mobile) { transition: none; }
}

/* mobile nav open state */
.primary-nav.is-open {
  display: block;
  position: absolute;
  left: 0; right: 0;
  top: 100%;
  background: var(--paper);
  border-bottom: 1px solid var(--line);
  box-shadow: var(--shadow);
  padding: 0.5rem var(--gutter) 1.25rem;
  max-height: calc(100vh - var(--header-h));
  overflow-y: auto;
}
.primary-nav ul { list-style: none; margin: 0; padding: 0; }
.primary-nav > ul > li { border-bottom: 1px solid var(--line); }
.primary-nav a {
  display: block;
  padding: 0.85rem 0.25rem;
  color: var(--ink);
  text-decoration: none;
  font-weight: 600;
}
.primary-nav a:hover { color: var(--belt-red); }

.has-dropdown > .dropdown-toggle {
  display: flex;
  align-items: center;
  justify-content: space-between;
  width: 100%;
  background: none;
  border: none;
  font: inherit;
  font-weight: 600;
  color: var(--ink);
  padding: 0.85rem 0.25rem;
  cursor: pointer;
}
.dropdown-toggle .chev { transition: transform 0.15s ease; }
.has-dropdown.is-open .dropdown-toggle .chev { transform: rotate(180deg); }
.dropdown { display: none; padding-bottom: 0.5rem; }
.has-dropdown.is-open .dropdown { display: block; }
.dropdown a { padding: 0.6rem 0.25rem 0.6rem 1rem; font-weight: 500; color: var(--ink-soft); }

/* The header trial button is hidden on mobile — the sticky bottom action bar
   provides it there instead. It returns at the desktop breakpoint. */
.header-cta.header-cta--mobile { display: none; }

/* --------------------------------------------------------------------------
   Mobile sticky bottom action bar (phones/tablets below 900px only)
   -------------------------------------------------------------------------- */
.mobile-cta-bar {
  position: fixed;
  left: 0; right: 0; bottom: 0;
  z-index: 90;
  display: flex;
  gap: 0.6rem;
  padding: 0.55rem var(--gutter);
  padding-bottom: calc(0.55rem + env(safe-area-inset-bottom, 0px)); /* phone safe area */
  background: var(--paper);
  border-top: 1px solid var(--line);
  box-shadow: 0 -4px 16px rgba(23, 19, 15, 0.14);
  transition: transform 0.2s ease;
}
.mobile-cta-bar .btn { flex: 1 1 0; min-width: 0; padding-inline: 0.5rem; }
.mobile-cta-bar.is-hidden { transform: translateY(120%); pointer-events: none; }
@media (prefers-reduced-motion: reduce) {
  .mobile-cta-bar { transition: none; }
}

/* Reserve space so the fixed bar never covers page content (mobile only).
   Pages without the bar (e.g. /free-week) opt out via body.no-mobile-bar. */
@media (max-width: 899.98px) {
  body { padding-bottom: calc(66px + env(safe-area-inset-bottom, 0px)); }
  body.no-mobile-bar { padding-bottom: 0; }
}

/* --------------------------------------------------------------------------
   Hero
   -------------------------------------------------------------------------- */
/* Program-page hero: shorter than the homepage's. These are wide room photos, so
   a tall (portrait) mobile hero shows the full image height and only a narrow
   slice of its width. A shorter hero crops less width and eats less screen.
   min-height, so it still grows if the headline needs the room. */
.hero {
  position: relative;
  min-height: min(78vh, 640px);
  display: flex;
  align-items: flex-end;
  color: var(--white);
  overflow: hidden;
  background: var(--ink);
}
.hero--page { min-height: min(56vh, 440px); } /* must follow .hero to win */
.hero__media {
  position: absolute; inset: 0;
  width: 100%; height: 100%;
  object-fit: cover;
  object-position: 50% 50%; /* center: keeps the face up in frame from 360px to desktop */
  z-index: 0;
}
.hero__scrim {
  position: absolute; inset: 0;
  z-index: 2;
  /* Stronger scrim, weighted to the bottom-left where the headline + buttons sit. */
  background:
    linear-gradient(to top, rgba(23,19,15,0.92) 0%, rgba(23,19,15,0.60) 42%, rgba(23,19,15,0.30) 72%, rgba(23,19,15,0.22) 100%),
    linear-gradient(to right, rgba(23,19,15,0.55) 0%, rgba(23,19,15,0.18) 55%, rgba(23,19,15,0) 100%);
}
.hero__inner { position: relative; z-index: 3; padding-block: clamp(2rem, 6vw, 3.5rem) clamp(1.1rem, 3vw, 1.75rem); }
.hero h1 { color: var(--white); font-family: "Teko", var(--font-body); font-weight: 600; font-size: clamp(2.6rem, 9vw, 4.5rem); letter-spacing: 0.01em; line-height: 1.02; max-width: 22ch; text-wrap: balance; }
.hero__sub { font-size: 1.15rem; max-width: 54ch; color: #ece7df; }
.hero__actions { display: flex; flex-wrap: wrap; gap: 0.85rem; margin-top: 1.5rem; }
.hero .btn--secondary { color: var(--white); border-color: var(--white); }
.hero .btn--secondary:hover { background: var(--white); color: var(--ink); }
/* --------------------------------------------------------------------------
   Grids / cards
   -------------------------------------------------------------------------- */
.grid { display: grid; gap: 1.25rem; }
.grid--3 { grid-template-columns: 1fr; }
.grid--auto { grid-template-columns: repeat(auto-fill, minmax(240px, 1fr)); }

.benefit {
  display: flex;
  gap: 0.9rem;
  align-items: flex-start;
}
.benefit__icon {
  flex: 0 0 auto;
  width: 44px; height: 44px;
  color: var(--belt-red);
}
.benefit__icon svg { width: 100%; height: 100%; }
.benefit h3 { margin-bottom: 0.25rem; }
.benefit p { margin: 0; color: var(--ink-soft); }

.card {
  background: var(--white);
  border: 1px solid var(--line);
  border-radius: var(--radius);
  overflow: hidden;
  display: flex;
  flex-direction: column;
  box-shadow: var(--shadow);
}
.card__media {
  aspect-ratio: 4 / 3;
  background: var(--mat-gray);
  position: relative;
}
.card__media img { width: 100%; height: 100%; object-fit: cover; }
.card__media--soon { display: flex; align-items: center; justify-content: center; background: var(--ink); }
.card__media--soon span { font-family: var(--font-display); color: var(--belt-gold); font-size: clamp(1.1rem, 3.5vw, 1.5rem); text-transform: uppercase; letter-spacing: 0.04em; text-align: center; }
.card__media--label { display: flex; align-items: center; justify-content: center; background: var(--ink); padding: 0.6rem; }
.card__media--label span { font-family: var(--font-display); color: var(--white); font-size: clamp(1rem, 3vw, 1.4rem); text-transform: uppercase; letter-spacing: 0.03em; text-align: center; line-height: 1.1; }

/* Instructors grid (About page) */
.instructor-grid { display: grid; grid-template-columns: repeat(auto-fit, minmax(200px, 1fr)); gap: 1.25rem; margin-top: 1.25rem; }
.instructor { margin: 0; text-align: center; }
.instructor img { width: 100%; aspect-ratio: 3 / 5; object-fit: cover; border-radius: var(--radius); border: 1px solid var(--line); background: var(--white); }
.instructor figcaption { margin-top: 0.6rem; font-family: var(--font-display); font-size: 1.1rem; }
.card__body { padding: 1.1rem 1.15rem 1.35rem; display: flex; flex-direction: column; gap: 0.5rem; flex: 1; }
.card__body h3 { margin: 0; }
.card__teaser { margin: 0; color: var(--ink-soft); font-size: 0.98rem; flex: 1; }
.card .btn { margin-top: 0.5rem; align-self: flex-start; }
/* "Core Program" badge on a program card */
.card__badge {
  align-self: flex-start;
  margin: 0;
  background: var(--belt-gold);
  color: var(--ink);
  font-family: var(--font-display);
  text-transform: uppercase;
  letter-spacing: 0.08em;
  font-size: 0.62rem;
  line-height: 1;
  padding: 0.35rem 0.55rem;
  border-radius: 999px;
}

/* Program link tiles (compact) */
.prog-grid { display: grid; grid-template-columns: 1fr; gap: 0.85rem; }
.prog-tile {
  display: flex;
  align-items: center;
  justify-content: center;
  text-align: center;
  gap: 0.85rem;
  padding: 0.85rem 1.1rem;
  background: var(--white);
  border: 1px solid var(--line);
  border-radius: var(--radius);
  text-decoration: none;
  color: var(--ink);
  font-weight: 700;
  transition: border-color 0.15s ease, transform 0.05s ease;
}
.prog-tile:hover { border-color: var(--belt-red); color: var(--ink); }
/* Photo placeholders are off for now: the tiles read as plain link buttons. */
.prog-tile__media { display: none; }
.prog-tile__media--off { flex: 0 0 auto; width: 56px; height: 56px; border-radius: 8px; background: var(--mat-gray); overflow: hidden; }
.prog-tile__media img { width: 100%; height: 100%; object-fit: cover; }
.prog-tile__soon { display: block; margin-top: 2px; font-size: 0.68rem; font-weight: 800; letter-spacing: 0.06em; text-transform: uppercase; color: var(--belt-gold); }

/* Weekly schedule — populated by schedule.js from the live schedule_template. */
.schedule { display: grid; grid-template-columns: repeat(auto-fit, minmax(200px, 1fr)); gap: 1rem; }
.schedule-day { border: 1px solid var(--line); border-radius: var(--radius); overflow: hidden; background: var(--white); }
.schedule-day__name { margin: 0; padding: 0.6rem 0.9rem; background: var(--ink); color: var(--white); font-family: var(--font-display); font-size: 1rem; }
.schedule-day__list { list-style: none; margin: 0; padding: 0.6rem; display: flex; flex-direction: column; gap: 0.5rem; }
.schedule-class { display: flex; flex-direction: column; gap: 1px; padding: 0.55rem 0.7rem; border-radius: 8px; background: var(--mat-gray); }
.schedule-class__time { font-weight: 800; font-size: 0.9rem; color: var(--ink); }
.schedule-class__name { font-weight: 700; }
.schedule-class[data-p="Taekwondo"] .schedule-class__name { color: #e9292d; }
.schedule-class[data-p="Cubs"] .schedule-class__name { color: #d9660a; }
.schedule-class[data-p="Kickboxing"] .schedule-class__name { color: #1565c0; }
.schedule-class[data-p="Jiu Jitsu"] .schedule-class__name { color: #6d4c41; }
.schedule-class[data-p="AMP'D"] .schedule-class__name { color: #2e7d32; }
.schedule-class__rank { font-size: 0.73rem; font-weight: 700; color: var(--ink); }
.schedule-class__detail { font-size: 0.72rem; font-weight: 600; color: var(--ink-soft); }
.schedule-fallback[hidden] { display: none; }
/* Per-program class-times list (program pages). */
.schedule-classes { display: grid; grid-template-columns: repeat(auto-fit, minmax(230px, 1fr)); gap: 1rem; }
.schedule-class-row { border: 1px solid var(--line); border-radius: var(--radius); padding: 0.85rem 1rem; background: var(--white); }
.schedule-class-row__name { margin: 0 0 0.15rem; font-size: 1.05rem; }
.schedule-class-row__age { margin: 0 0 0.6rem; font-size: 0.8rem; font-weight: 600; color: var(--ink-soft); }
.schedule-class-row__times { list-style: none; margin: 0; padding: 0; display: flex; flex-wrap: wrap; gap: 0.4rem; }
.schedule-class-row__times li { padding: 0.3rem 0.6rem; border-radius: 6px; background: var(--mat-gray); font-weight: 700; font-size: 0.85rem; }

/* --------------------------------------------------------------------------
   Free-week CTA band
   -------------------------------------------------------------------------- */
.cta-band {
  background: var(--belt-red);
  color: var(--white);
  text-align: center;
}
.cta-band h2 { color: var(--white); }
.cta-band p { margin-inline: auto; color: #ffe9e9; }
.cta-band .btn--primary { background: var(--white); color: var(--belt-red); border-color: var(--white); }
.cta-band .btn--primary:hover { background: var(--ink); color: var(--white); border-color: var(--ink); }
/* Secondary "Ask About This Program" action on the red band: white-outline box
   so it reads as clearly secondary to the solid-white free-week button. */
.cta-band__actions { display: flex; flex-wrap: wrap; gap: 0.75rem 1rem; justify-content: center; align-items: center; margin-inline: auto; }
.cta-band .btn--ask { background: transparent; color: var(--white); border-color: var(--white); }
.cta-band .btn--ask:hover { background: var(--white); color: var(--belt-red); border-color: var(--white); }
/* "Prefer to talk?" line on the red band: keep the phone link legible, not red-on-red. */
.cta-band__call { margin-top: 0.9rem; color: #ffe9e9; font-weight: 600; }
.cta-band__call a { color: var(--white); text-decoration: underline; }
.cta-band__call a:hover { color: var(--white); }

/* --------------------------------------------------------------------------
   Reviews
   -------------------------------------------------------------------------- */
.review {
  background: var(--white);
  border: 1px solid var(--line);
  border-left: 5px solid var(--belt-gold);
  border-radius: var(--radius);
  padding: 1.25rem 1.35rem;
}
.review p { font-style: italic; }
.review cite { font-style: normal; font-weight: 700; color: var(--ink); }
.review .review__stars { font-style: normal; color: var(--belt-gold); font-size: 1.05rem; letter-spacing: 0.15em; line-height: 1; margin: 0 0 0.5rem; }
.reviews-more { text-align: center; margin-top: 1.5rem; }

/* --------------------------------------------------------------------------
   FAQ accordion
   -------------------------------------------------------------------------- */
.faq { max-width: 760px; }
.faq__item { border-bottom: 1px solid var(--line); }
.faq__q {
  width: 100%;
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: 1rem;
  text-align: left;
  background: none;
  border: none;
  font-family: var(--font-body);
  font-size: 1.05rem;
  font-weight: 700;
  color: var(--ink);
  padding: 1.1rem 0.25rem;
  cursor: pointer;
}
.faq__q .chev { flex: 0 0 auto; transition: transform 0.15s ease; }
.faq__q[aria-expanded="true"] .chev { transform: rotate(180deg); }
.faq__a { padding: 0 0.25rem 1.1rem; color: var(--ink-soft); }
.faq__a[hidden] { display: none; }

/* --------------------------------------------------------------------------
   Contact / form
   -------------------------------------------------------------------------- */
.contact-grid { display: grid; gap: 2rem; grid-template-columns: 1fr; }
/* min-width:0 lets grid/flex children shrink below their content's intrinsic
   width — without it a <select> with long option text forces horizontal
   overflow on narrow phones. */
.contact-grid > *,
form[data-contact-form],
.form-field { min-width: 0; }
.form-field { display: flex; flex-direction: column; gap: 0.35rem; margin-bottom: 1rem; }
.form-field label { font-weight: 700; font-size: 0.95rem; }
.form-field input,
.form-field select,
.form-field textarea {
  font: inherit;
  width: 100%;
  max-width: 100%;
  min-width: 0;
  padding: 0.75rem 0.85rem;
  border: 2px solid var(--line);
  border-radius: 8px;
  background: var(--white);
  color: var(--ink);
}
.form-field input:focus,
.form-field select:focus,
.form-field textarea:focus { border-color: var(--belt-red); outline-offset: 1px; }
.form-consent { font-size: 0.82rem; color: var(--ink-soft); margin-top: 0.75rem; }
.form-status { margin-top: 1rem; font-weight: 600; }
.form-status[data-state="success"] { color: #1c6b2e; }
.form-status[data-state="error"] { color: var(--belt-red); }

/* honeypot */
.hp-field {
  position: absolute !important;
  left: -9999px !important;
  top: auto;
  width: 1px; height: 1px;
  overflow: hidden;
}

.nap { line-height: 1.7; }
.nap a { font-weight: 600; }
.hours { line-height: 1.55; }
.hours strong { font-weight: 700; }
.map-embed {
  aspect-ratio: 16 / 10;
  background: var(--mat-gray);
  border: 1px solid var(--line);
  border-radius: var(--radius);
  overflow: hidden;
  display: flex; align-items: center; justify-content: center;
  color: var(--ink-soft);
  text-align: center;
  padding: 1rem;
}
.map-embed img { width: 100%; height: 100%; object-fit: cover; }

/* --------------------------------------------------------------------------
   Footer
   -------------------------------------------------------------------------- */
.site-footer { background: var(--ink); color: #d7cfc4; padding-block: clamp(2.5rem, 6vw, 3.5rem); }
.site-footer a { color: #efe9e0; }
.site-footer a:hover { color: var(--white); }
.footer-grid { display: grid; gap: 2rem; grid-template-columns: 1fr; }
.footer-brand img { height: 52px; }
.footer-col h3 { color: var(--white); font-size: 1rem; letter-spacing: 0.06em; }
.footer-col ul { list-style: none; margin: 0; padding: 0; }
.footer-col li { margin-bottom: 0.5rem; }
.footer-col a { text-decoration: none; }
.footer-col a:hover { text-decoration: underline; }
.social { display: flex; gap: 0.75rem; margin-top: 0.75rem; }
.social a {
  display: inline-flex; align-items: center; justify-content: center;
  width: 42px; height: 42px;
  border: 1px solid rgba(255,255,255,0.25);
  border-radius: 8px;
  color: #efe9e0;
}
.social a:hover { border-color: var(--belt-gold); color: var(--belt-gold); }
.social svg { width: 22px; height: 22px; }
.footer-bottom {
  margin-top: 2rem; padding-top: 1.25rem;
  border-top: 1px solid rgba(255,255,255,0.15);
  display: flex; flex-wrap: wrap; gap: 1rem 1.5rem; align-items: center; justify-content: space-between;
  font-size: 0.9rem;
}

/* --------------------------------------------------------------------------
   Related programs row / misc
   -------------------------------------------------------------------------- */
.stack > * + * { margin-top: 1rem; }
.lede { font-size: 1.15rem; color: var(--ink-soft); max-width: 60ch; }
/* /free-week conversion landing page: one narrow, centred column. */
.free-week { max-width: 640px; text-align: center; }
.free-week .lede { margin-inline: auto; }
/* The panel centres, but its own fields/options stay left-aligned. */
.free-week__form { margin: 1.6rem auto 0; text-align: left; }
.free-week__note { margin-top: 1rem; font-size: 0.95rem; color: var(--ink-soft); }
/* Parenthetical detail dropped onto its own line under a program label
   (dropdown links and program cards). Only breaks the line — weight, size,
   case, and color are inherited so every parenthetical looks identical to
   its inline siblings. */
.label-sub { display: block; }
.placeholder-note {
  font-size: 0.85rem;
  color: var(--ink-soft);
  border: 1px dashed var(--line);
  border-radius: 8px;
  padding: 0.5rem 0.75rem;
  background: rgba(0,0,0,0.02);
}

/* --------------------------------------------------------------------------
   Fade-up on section entry (JS-toggled). Disabled under reduced motion.
   -------------------------------------------------------------------------- */
.fade-up { opacity: 1; }
@media (prefers-reduced-motion: no-preference) {
  .js .fade-up { opacity: 0; transform: translateY(18px); transition: opacity 0.5s ease, transform 0.5s ease; }
  .js .fade-up.is-visible { opacity: 1; transform: none; }
}

/* --------------------------------------------------------------------------
   Larger screens
   -------------------------------------------------------------------------- */
@media (min-width: 640px) {
  .grid--3 { grid-template-columns: repeat(2, 1fr); }
  .prog-grid { grid-template-columns: repeat(2, 1fr); }
  .footer-grid { grid-template-columns: repeat(2, 1fr); }
  .contact-grid { grid-template-columns: 1.1fr 0.9fr; }
}

@media (min-width: 900px) {
  .grid--3 { grid-template-columns: repeat(3, 1fr); }
  .prog-grid { grid-template-columns: repeat(3, 1fr); }
  .footer-grid { grid-template-columns: 1.6fr 1fr 1fr; }

  /* Desktop header unchanged: flex row, logo back at the left (not centered). */
  .site-header__inner { display: flex; }
  .brand {
    grid-column: auto;
    justify-self: auto;
    padding-inline-start: 0.5rem;
    margin-inline-end: 1.5rem;
    flex-shrink: 0;   /* never let the logo collapse under the nav */
  }

  /* Desktop call link: compact icon-only, secondary to the red trial button.
     (The full number won't fit inline next to the dense nav + trial button
     without forcing the header to wrap, so the header shows just the icon.) */
  .call-link {
    flex-shrink: 0;
    width: auto; height: auto;
    border: none;
    padding: 0.4rem;
  }
  .call-link:hover { color: var(--belt-red); }

  .nav-toggle { display: none; }
  .primary-nav { display: block; margin-left: auto; }
  .primary-nav > ul { display: flex; gap: 0.25rem; align-items: center; }
  .primary-nav > ul > li { border-bottom: none; position: relative; }
  .primary-nav a { padding: 0.6rem 0.55rem; }

  .has-dropdown > .dropdown-toggle { padding: 0.6rem 0.7rem; width: auto; gap: 0.35rem; }
  .dropdown {
    position: absolute;
    top: 100%; left: 0;
    min-width: 260px;
    background: var(--paper);
    border: 1px solid var(--line);
    border-radius: var(--radius);
    box-shadow: var(--shadow);
    padding: 0.35rem;
    display: none;
    z-index: 120;
  }
  .has-dropdown.is-open .dropdown,
  .has-dropdown:hover .dropdown,
  .has-dropdown:focus-within .dropdown { display: block; }
  .dropdown a { padding: 0.5rem 0.7rem; border-radius: 6px; }
  .dropdown a:hover { background: var(--mat-gray); }

  .header-cta { display: inline-flex; margin-left: 0.75rem; flex-shrink: 0; white-space: nowrap; }
  .header-cta--mobile { display: none; }

  .mobile-cta-bar { display: none; }  /* desktop unchanged: no bottom bar */
}

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

/* --------------------------------------------------------------------------
   Try-1-Week-Free popup modal (built by trial.js)
   -------------------------------------------------------------------------- */
.trial-open { overflow: hidden; }
.trial-modal { position: fixed; inset: 0; z-index: 200; display: flex; align-items: flex-end; justify-content: center; }
.trial-modal[hidden] { display: none; }
.trial-backdrop { position: absolute; inset: 0; background: rgba(23, 19, 15, 0.6); }
.trial-dialog {
  position: relative;
  z-index: 1;
  width: 100%;
  max-width: 520px;
  max-height: 92vh;
  overflow-y: auto;
  background: var(--paper);
  color: var(--ink);
  border-radius: 16px 16px 0 0;
  box-shadow: var(--shadow);
  padding: clamp(1.25rem, 5vw, 2rem);
  padding-bottom: calc(clamp(1.25rem, 5vw, 2rem) + env(safe-area-inset-bottom, 0px));
}
.trial-close {
  position: absolute; top: 0.4rem; right: 0.5rem;
  width: 40px; height: 40px;
  border: none; background: none;
  font-size: 1.9rem; line-height: 1;
  color: var(--ink-soft); cursor: pointer; border-radius: 8px;
}
.trial-close:hover { color: var(--belt-red); }
/* Inline trial form (/free-week): same flow, rendered into the page instead of
   a modal. The page scrolls, so no inner scroller and nothing to close. */
[data-trial-inline] {
  max-width: 520px;
  background: var(--paper);
  border: 1px solid var(--line);
  border-radius: var(--radius);
  padding: clamp(1.1rem, 4vw, 1.75rem);
}
[data-trial-inline] [data-trial-close] { display: none; }
[data-trial-inline] .trial-slots { max-height: none; overflow-y: visible; }
.trial-eyebrow { font-family: var(--font-display); text-transform: uppercase; letter-spacing: 0.12em; font-size: 0.72rem; color: var(--belt-red); margin: 0 0 0.4rem; }
.trial-h { margin: 0 0 0.75rem; }
.trial-sub { color: var(--ink-soft); margin: 0 0 1rem; font-weight: 600; }
.trial-note { color: var(--ink-soft); }
.trial-options { display: flex; flex-direction: column; gap: 0.6rem; }
.trial-slots { max-height: 46vh; overflow-y: auto; }
.trial-option {
  display: flex; flex-direction: column; gap: 0.15rem;
  text-align: left;
  padding: 0.9rem 1rem;
  background: var(--white);
  border: 2px solid var(--line);
  border-radius: var(--radius);
  cursor: pointer; font: inherit; color: var(--ink);
  transition: border-color 0.15s ease;
}
.trial-option:hover { border-color: var(--belt-red); }
.trial-option__name { font-family: var(--font-display); text-transform: uppercase; font-size: 0.95rem; letter-spacing: 0.02em; }
.trial-option__sub { color: var(--ink-soft); font-size: 0.9rem; }
.trial-actions { display: flex; gap: 0.6rem; margin-top: 1.1rem; flex-wrap: wrap; }
.trial-actions .btn { flex: 1 1 auto; }
.trial-success { text-align: center; padding-top: 0.5rem; }
.trial-check { width: 56px; height: 56px; margin: 0 auto 0.75rem; border-radius: 50%; background: var(--belt-red); color: #fff; font-size: 1.9rem; line-height: 56px; }
.trial-confirm { font-family: var(--font-display); text-transform: uppercase; font-size: 1.15rem; line-height: 1.3; margin: 0 0 0.75rem; }

@media (min-width: 640px) {
  .trial-modal { align-items: center; }
  .trial-dialog { border-radius: 16px; }
}
@media (prefers-reduced-motion: no-preference) {
  .trial-dialog { animation: trial-in 0.2s ease; }
  @keyframes trial-in { from { transform: translateY(12px); opacity: 0; } to { transform: none; opacity: 1; } }
}

/* trial popup v2: multi-select, address grid, waiver, recap */
.trial-toggle { flex-direction: row; align-items: center; gap: 0.8rem; }
.trial-toggle__box {
  flex: 0 0 auto; width: 22px; height: 22px; border-radius: 6px;
  border: 2px solid var(--line); position: relative; transition: border-color 0.15s ease, background 0.15s ease;
}
.trial-toggle[aria-checked="true"] { border-color: var(--belt-red); }
.trial-toggle[aria-checked="true"] .trial-toggle__box { border-color: var(--belt-red); background: var(--belt-red); }
.trial-toggle[aria-checked="true"] .trial-toggle__box::after {
  content: ""; position: absolute; left: 6px; top: 2px; width: 6px; height: 11px;
  border: solid #fff; border-width: 0 2px 2px 0; transform: rotate(45deg);
}
.trial-toggle__text { display: flex; flex-direction: column; gap: 0.15rem; min-width: 0; }

.trial-grid { display: grid; gap: 0 0.6rem; }
.trial-grid--2 { grid-template-columns: 1fr 1fr; }
.trial-grid--3 { grid-template-columns: 1fr 0.7fr 0.9fr; }
@media (max-width: 460px) {
  .trial-grid--2, .trial-grid--3 { grid-template-columns: 1fr; }
}
.trial-legend { font-family: var(--font-display); text-transform: uppercase; letter-spacing: 0.06em; font-size: 0.8rem; color: var(--ink-soft); margin: 0.4rem 0 0.6rem; }
.trial-fieldnote { font-size: 0.82rem; color: var(--ink-soft); margin: -0.35rem 0 0.7rem; }
.trial-fielderr { font-size: 0.85rem; font-weight: 700; color: var(--belt-red); margin: -0.4rem 0 0.4rem; }
.trial-fielderr:empty { display: none; }
.form-field .req { color: var(--belt-red); }

.trial-waiver {
  max-height: 34vh; overflow-y: auto;
  border: 2px solid var(--line); border-radius: var(--radius);
  padding: 0.9rem 1rem; margin-bottom: 1rem;
  background: var(--white); font-size: 0.9rem; color: var(--ink-soft);
}
.trial-waiver p { margin: 0 0 0.7rem; }
.trial-waiver__title { font-weight: 700; color: var(--ink); margin: 0 0 0.6rem; }
.trial-agree { display: flex; align-items: flex-start; gap: 0.6rem; margin: 0.2rem 0 0.4rem; cursor: pointer; }
.trial-agree input { flex: 0 0 auto; width: 20px; height: 20px; margin-top: 2px; }

.trial-recap { list-style: none; padding: 0; margin: 0 0 0.9rem; display: flex; flex-direction: column; gap: 0.4rem; }
.trial-recap li {
  padding: 0.6rem 0.8rem; border: 1px solid var(--line); border-radius: var(--radius);
  background: var(--white); font-weight: 600; font-size: 0.92rem;
}

/* trial popup v3: calendar week strip */
.trial-weeklabel { text-align: center; font-family: var(--font-display); text-transform: uppercase; letter-spacing: 0.04em; font-size: 0.85rem; color: var(--ink-soft); margin: 0 0 0.75rem; }
.trial-cal { display: flex; flex-direction: column; gap: 0.4rem; max-height: 46vh; overflow-y: auto; }
.trial-day { display: grid; grid-template-columns: 5.2rem 1fr; gap: 0.6rem; align-items: start; padding: 0.5rem 0; border-top: 1px solid var(--line); }
.trial-day:first-child { border-top: none; }
.trial-day__label { font-weight: 700; font-size: 0.85rem; padding-top: 0.35rem; }
.trial-day__slots { display: flex; flex-wrap: wrap; gap: 0.4rem; }
.trial-slot {
  padding: 0.45rem 0.7rem; border: 2px solid var(--line); border-radius: var(--radius);
  background: var(--white); cursor: pointer; font: inherit; color: var(--ink);
  font-size: 0.85rem; font-weight: 600; transition: border-color 0.15s ease;
}
.trial-slot:hover { border-color: var(--belt-red); }
.trial-day__empty { color: var(--ink-soft); font-size: 0.85rem; padding-top: 0.35rem; }

/* trial popup: first-class note + signature pad */
.trial-firstnote { font-size: 0.9rem; margin: 0 0 0.9rem; }
.trial-sigwrap { position: relative; }
.trial-sigpad { display: block; width: 100%; height: 150px; border: 2px solid var(--line); border-radius: var(--radius); background: var(--white); touch-action: none; cursor: crosshair; }
.trial-sigclear { position: absolute; top: 0.45rem; right: 0.5rem; font: inherit; font-size: 0.8rem; font-weight: 600; padding: 0.2rem 0.6rem; border: 1px solid var(--line); border-radius: 6px; background: var(--paper); color: var(--ink-soft); cursor: pointer; }
.trial-sigclear:hover { color: var(--belt-red); border-color: var(--belt-red); }
