/* ===== Whāingaroa BJJ stylesheet ===== */

:root {
  --bg: #0b0b0d;
  --bg-alt: #131316;
  --surface: #1b1b20;
  --surface-2: #202027;
  --border: #2b2b32;
  --text: #f5f4f0;
  --text-muted: #a9a8ae;

  --blue: #4361c9;
  --blue-dark: #2c4494;
  --purple: #8a3fae;
  --purple-dark: #632d80;
  --red: #c8202c;
  --brown: #7a4a2b;

  --belt-white: #f5f4f0;
  --belt-black: #1c1c21;

  --radius: 14px;
  --radius-sm: 8px;
  --font-head: "Anton", "Arial Narrow", sans-serif;
  --font-head-mc: "Oswald", "Anton", "Arial Narrow", sans-serif;
  --font-body: "Work Sans", -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif;
  --wrap: 1120px;
}

* { box-sizing: border-box; }
html { scroll-behavior: smooth; }
body {
  margin: 0;
  background: var(--bg);
  color: var(--text);
  font-family: var(--font-body);
  line-height: 1.55;
  -webkit-font-smoothing: antialiased;
}
img { max-width: 100%; display: block; }
a { color: inherit; }
h1, h2, h3 {
  font-family: var(--font-head);
  font-weight: 400;
  letter-spacing: 0.01em;
  line-height: 1.05;
  margin: 0 0 0.4em;
  text-transform: uppercase;
}
p { margin: 0 0 1em; color: var(--text-muted); }

/* Macron-safe font for "Whāingaroa" — Anton's condensed glyph set doesn't
   position the tohutō (ā) correctly, so this word borrows Oswald instead. */
.mc { font-family: var(--font-head-mc); font-weight: 700; }
.wrap {
  max-width: var(--wrap);
  margin: 0 auto;
  padding: 0 24px;
}
.wrap-narrow { max-width: 780px; }

section[id], .hero { scroll-margin-top: 84px; }

.skip-link {
  position: absolute;
  left: -999px;
  top: 0;
  background: var(--blue);
  color: #fff;
  padding: 10px 16px;
  z-index: 1000;
}
.skip-link:focus { left: 16px; top: 16px; }

/* ---- Buttons ---- */
.btn {
  display: inline-block;
  padding: 14px 28px;
  border-radius: 999px;
  font-weight: 600;
  text-decoration: none;
  border: 2px solid transparent;
  cursor: pointer;
  font-size: 1rem;
  transition: transform 0.15s ease, background 0.15s ease, border-color 0.15s ease;
}
.btn:hover { transform: translateY(-2px); }
.btn-primary {
  background: linear-gradient(120deg, var(--blue), var(--purple));
  color: #fff;
}
.btn-primary:hover { filter: brightness(1.1); }
.btn-ghost {
  background: transparent;
  border-color: rgba(245,244,240,0.35);
  color: var(--text);
}
.btn-ghost:hover { border-color: var(--text); }

/* ---- Tags ---- */
.tag {
  font-size: 0.72rem;
  font-weight: 700;
  letter-spacing: 0.06em;
  text-transform: uppercase;
  padding: 5px 12px;
  border-radius: 999px;
  white-space: nowrap;
}
.tag-blue { background: rgba(67,97,201,0.18); color: #8fa4ec; }
.tag-purple { background: rgba(138,63,174,0.18); color: #cf9de6; }

/* ---- Header ---- */
.site-header {
  position: sticky;
  top: 0;
  z-index: 500;
  border-bottom: 1px solid var(--border);
}
/* Frosted-glass background lives on a pseudo-element rather than the header
   itself: a `backdrop-filter` on .site-header would make it the containing
   block for the fixed-position mobile nav panel below, clipping the panel
   to the header's own (tiny) height instead of the full viewport. */
.site-header::before {
  content: "";
  position: absolute;
  inset: 0;
  z-index: -1;
  background: rgba(11,11,13,0.85);
  backdrop-filter: blur(10px);
}
.header-inner {
  display: flex;
  align-items: center;
  justify-content: space-between;
  height: 72px;
}
.brand {
  display: flex;
  align-items: center;
  gap: 12px;
  text-decoration: none;
}
.brand-logo {
  width: 42px;
  height: 42px;
  border-radius: 50%;
  object-fit: cover;
}
.brand-text { display: flex; flex-direction: column; line-height: 1.1; }
.brand-name { font-family: var(--font-head); font-size: 1rem; letter-spacing: 0.02em; text-transform: uppercase; }
.brand-sub { font-size: 0.72rem; color: var(--text-muted); letter-spacing: 0.08em; text-transform: uppercase; }

.site-nav {
  display: flex;
  align-items: center;
  gap: 28px;
}
.site-nav a {
  text-decoration: none;
  font-weight: 500;
  font-size: 0.95rem;
  color: var(--text);
  opacity: 0.85;
}
.site-nav a:hover { opacity: 1; }
.nav-cta {
  background: linear-gradient(120deg, var(--blue), var(--purple));
  padding: 9px 18px;
  border-radius: 999px;
  opacity: 1 !important;
  color: #fff !important;
}

.nav-toggle {
  display: none;
  flex-direction: column;
  justify-content: center;
  gap: 5px;
  width: 40px;
  height: 40px;
  background: none;
  border: none;
  cursor: pointer;
}
.nav-toggle span {
  display: block;
  width: 24px;
  height: 2px;
  background: var(--text);
  margin: 0 auto;
  transition: transform 0.2s ease, opacity 0.2s ease;
}

/* ---- Hero ---- */
.hero {
  position: relative;
  min-height: 92vh;
  display: flex;
  align-items: center;
  overflow: hidden;
}
.hero-bg {
  position: absolute;
  inset: 0;
  background-image: url('../images/hero-bg.jpg');
  background-size: cover;
  background-position: center 20%;
  filter: saturate(0.9);
}
/* wide/short viewports get a crop composed specifically around the patch
   (cover-cropping the tall mobile photo into an ultra-wide banner would
   otherwise hide it almost entirely) */
@media (min-width: 900px) {
  .hero-bg {
    background-image: url('../images/hero-bg-wide.jpg');
    background-position: center 70%;
  }
}
.hero-overlay {
  position: absolute;
  inset: 0;
  background:
    linear-gradient(180deg, rgba(11,11,13,0.42) 0%, rgba(11,11,13,0.6) 55%, rgba(11,11,13,0.95) 100%),
    linear-gradient(100deg, rgba(11,11,13,0.58) 10%, rgba(67,97,201,0.18) 55%, rgba(138,63,174,0.22) 100%);
}
.hero-inner {
  position: relative;
  z-index: 2;
  text-align: center;
  padding: 96px 24px 64px;
}
.hero-logo {
  width: 108px;
  height: 108px;
  border-radius: 50%;
  margin: 0 auto 24px;
  box-shadow: 0 0 0 3px rgba(245,244,240,0.15), 0 20px 40px rgba(0,0,0,0.5);
}
.hero h1 {
  font-size: clamp(2.3rem, 6vw, 4.2rem);
  margin-bottom: 0.15em;
}
.hero-nickname {
  font-family: var(--font-head);
  text-transform: uppercase;
  letter-spacing: 0.18em;
  font-size: 0.95rem;
  color: #cf9de6;
  margin-bottom: 1.2em;
}
.hero-tagline {
  max-width: 560px;
  margin: 0 auto 2.2em;
  font-size: 1.08rem;
  color: #dedcd8;
}
.hero-facts {
  display: flex;
  flex-wrap: wrap;
  justify-content: center;
  gap: 14px;
  margin-bottom: 2.4em;
}
.hero-fact {
  background: rgba(255,255,255,0.06);
  border: 1px solid rgba(255,255,255,0.12);
  border-radius: var(--radius-sm);
  padding: 12px 20px;
  min-width: 150px;
}
.hero-fact strong { display: block; font-size: 1rem; }
.hero-fact span { display: block; font-size: 0.8rem; color: var(--text-muted); margin-top: 2px; }
.hero-buttons {
  display: flex;
  flex-wrap: wrap;
  justify-content: center;
  gap: 16px;
}

/* ---- Belt stripe divider ---- */
.belt-stripe {
  display: flex;
  height: 7px;
  /* a hairline top/bottom the full width of the strip, so the black
     segment still reads as a distinct bar instead of vanishing into the
     near-black page background either side of it */
  box-shadow:
    inset 0 1px 0 rgba(245,244,240,0.25),
    inset 0 -1px 0 rgba(245,244,240,0.15);
}
.belt-stripe span { flex: 1; }
.s-white { background: var(--belt-white); }
.s-blue { background: var(--blue); }
.s-purple { background: var(--purple); }
.s-brown { background: var(--brown); }
.s-black { background: var(--belt-black); border-right: none; }

/* ---- Sections ---- */
.section { padding: 88px 0; }
.section-alt { background: var(--bg-alt); }
.eyebrow {
  color: #8fa4ec;
  font-weight: 700;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  font-size: 0.8rem;
  margin-bottom: 0.6em;
}
.section h2 { font-size: clamp(1.9rem, 4vw, 2.6rem); }
.section-lead {
  max-width: 640px;
  font-size: 1.05rem;
}

/* ---- Class cards ---- */
.class-cards {
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  gap: 24px;
  margin: 40px 0 32px;
}
.class-card {
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  padding: 32px;
}
.class-card-head {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  margin-bottom: 18px;
}
.class-card h3 { margin: 0; font-size: 1.5rem; }
.class-time { font-size: 1.6rem; font-weight: 700; color: var(--text); font-family: var(--font-head); text-transform: none; margin-bottom: 2px; }
.class-days { color: var(--text-muted); margin-bottom: 18px; }
.class-price { font-size: 1.9rem; font-weight: 700; color: #8fa4ec; font-family: var(--font-head); }
.class-price span { font-size: 0.95rem; color: var(--text-muted); font-family: var(--font-body); font-weight: 500; }
.class-desc { margin-top: 14px; margin-bottom: 0; }

.notice-box {
  background: rgba(67,97,201,0.08);
  border: 1px solid rgba(67,97,201,0.25);
  border-radius: var(--radius);
  padding: 22px 26px;
}
.notice-box p { margin-bottom: 8px; color: var(--text); font-size: 0.96rem; }
.notice-box p:last-child { margin-bottom: 0; }
.notice-box strong { color: #cf9de6; }

/* ---- What to expect ---- */
.expect-grid {
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  gap: 32px 40px;
  margin-top: 40px;
}
.expect-num {
  font-family: var(--font-head);
  font-size: 1.4rem;
  color: var(--purple);
  display: block;
  margin-bottom: 8px;
}
.expect-item h3 { font-size: 1.15rem; margin-bottom: 0.4em; }
.expect-item p { margin-bottom: 0; }

/* ---- Location ---- */
.location-wrap {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 48px;
  align-items: center;
}
.location-address {
  font-size: 1.15rem;
  color: var(--text);
  margin-bottom: 1.4em;
}
.location-map {
  border-radius: var(--radius);
  overflow: hidden;
  border: 1px solid var(--border);
  aspect-ratio: 4 / 3;
}
.location-map iframe {
  width: 100%;
  height: 100%;
  border: 0;
  filter: grayscale(0.3) invert(0.92) contrast(0.9);
}

/* ---- Coaches ---- */
.coach-cards {
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  gap: 24px;
  margin: 40px 0 48px;
}
.coach-card {
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  padding: 28px;
  position: relative;
  overflow: hidden;
}
/* the coach-belt bar is a literal (if compact) belt tip: black belt fabric,
   two degree stripes, then the red bar, left to right */
.coach-belt {
  position: absolute;
  top: 0; left: 0; right: 0;
  height: 8px;
  display: flex;
}
.coach-belt span { display: block; }
.coach-belt span:nth-child(1) { flex: 1 1 55%; background: var(--belt-black); }
.coach-belt span:nth-child(2) { flex: 0 0 3px; background: var(--belt-white); }
.coach-belt span:nth-child(3) { flex: 0 0 3px; background: var(--belt-black); }
.coach-belt span:nth-child(4) { flex: 0 0 3px; background: var(--belt-white); }
.coach-belt span:nth-child(5) { flex: 0 0 4px; background: var(--belt-black); }
.coach-belt span:nth-child(6) { flex: 1 1 auto; background: var(--red); }
.coach-photo {
  width: 96px;
  height: 96px;
  border-radius: 50%;
  margin: 6px 0 18px;
  overflow: hidden;
  position: relative;
  background: linear-gradient(135deg, var(--blue), var(--purple));
  display: flex;
  align-items: center;
  justify-content: center;
  border: 2px solid rgba(245,244,240,0.15);
}
.coach-photo img { width: 100%; height: 100%; object-fit: cover; }
.coach-initials {
  display: none;
  font-family: var(--font-head);
  font-size: 1.5rem;
  color: #fff;
  letter-spacing: 0.04em;
}
.coach-photo.no-photo .coach-initials { display: block; }
.coach-card h3 { font-size: 1.3rem; margin-top: 10px; margin-bottom: 4px; }
.coach-role { color: #8fa4ec; font-weight: 600; margin-bottom: 0; }

.affiliation {
  display: flex;
  align-items: center;
  gap: 24px;
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  padding: 26px 30px;
}
.affiliation-logo { width: 76px; height: 76px; border-radius: 50%; flex-shrink: 0; }
.affiliation p { margin: 0; color: var(--text); }

/* ---- Our Story ---- */
.story-quote {
  margin: 32px 0 0;
  padding: 22px 28px;
  border-left: 3px solid var(--purple);
  background: var(--surface);
  border-radius: 0 var(--radius-sm) var(--radius-sm) 0;
}
.story-quote p {
  font-size: 1.1rem;
  font-style: italic;
  color: var(--text);
  margin-bottom: 10px;
}
.story-quote cite {
  font-style: normal;
  font-size: 0.85rem;
  color: var(--text-muted);
  font-weight: 600;
}

/* ---- FAQ ---- */
.faq-list { margin-top: 32px; }
.faq-item {
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: var(--radius-sm);
  padding: 4px 22px;
  margin-bottom: 12px;
}
.faq-item summary {
  cursor: pointer;
  list-style: none;
  padding: 18px 0;
  font-weight: 600;
  font-size: 1.02rem;
  color: var(--text);
  display: flex;
  justify-content: space-between;
  align-items: center;
}
.faq-item summary::-webkit-details-marker { display: none; }
.faq-item summary::after {
  content: "+";
  font-family: var(--font-head);
  font-size: 1.4rem;
  color: var(--purple);
  margin-left: 16px;
  flex-shrink: 0;
}
.faq-item[open] summary::after { content: "\2212"; }
.faq-answer { padding-bottom: 18px; }
.faq-answer p { margin: 0; }

/* ---- Contact ---- */
.contact-wrap {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 56px;
  align-items: start;
}
.social-buttons { display: flex; gap: 14px; margin-top: 4px; }
.social-btn {
  display: flex;
  align-items: center;
  gap: 10px;
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: 999px;
  padding: 12px 20px;
  text-decoration: none;
  color: var(--text);
  font-weight: 600;
  font-size: 0.92rem;
}
.social-btn svg { width: 20px; height: 20px; fill: currentColor; }
.social-btn:hover { border-color: rgba(245,244,240,0.4); }

.contact-form {
  display: flex;
  flex-direction: column;
  gap: 6px;
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  padding: 32px;
}
.contact-form label {
  font-size: 0.85rem;
  font-weight: 600;
  color: var(--text-muted);
  margin-top: 14px;
}
.contact-form input[type="text"],
.contact-form input[type="email"],
.contact-form textarea {
  background: var(--bg);
  border: 1px solid var(--border);
  border-radius: var(--radius-sm);
  padding: 12px 14px;
  color: var(--text);
  font-family: var(--font-body);
  font-size: 1rem;
  resize: vertical;
}
.contact-form input:focus,
.contact-form textarea:focus {
  outline: none;
  border-color: var(--blue);
}
.contact-form button { margin-top: 20px; }
.hp-field { position: absolute; left: -9999px; }
.form-status { margin-top: 14px; font-size: 0.92rem; margin-bottom: 0; min-height: 1.2em; }
.form-status.ok { color: #7bd67b; }
.form-status.err { color: #e06767; }

/* ---- Footer ---- */
.site-footer {
  background: var(--bg-alt);
  border-top: 1px solid var(--border);
  padding: 44px 0 26px;
}
.footer-inner {
  display: flex;
  flex-wrap: wrap;
  justify-content: space-between;
  align-items: center;
  gap: 24px;
  margin-bottom: 28px;
}
.footer-brand { display: flex; align-items: center; gap: 14px; }
.footer-logo { width: 48px; height: 48px; border-radius: 50%; }
.footer-name { font-weight: 700; color: var(--text); margin: 0; }
.footer-sub { font-size: 0.85rem; margin: 2px 0 0; }
.footer-social { display: flex; gap: 22px; }
.footer-social a { text-decoration: none; font-weight: 600; font-size: 0.92rem; color: var(--text-muted); }
.footer-social a:hover { color: var(--text); }
.footer-copy { font-size: 0.8rem; color: var(--text-muted); border-top: 1px solid var(--border); padding-top: 20px; margin: 0; }

/* ---- Reveal animation ---- */
.reveal { opacity: 0; transform: translateY(24px); transition: opacity 0.6s ease, transform 0.6s ease; }
.reveal.in-view { opacity: 1; transform: translateY(0); }

/* ---- Responsive ---- */
@media (max-width: 880px) {
  .site-nav {
    position: fixed;
    top: 72px;
    left: 0;
    right: 0;
    bottom: 0;
    background: var(--bg);
    flex-direction: column;
    justify-content: flex-start;
    align-items: flex-start;
    padding: 32px 24px;
    gap: 22px;
    transform: translateX(100%);
    transition: transform 0.25s ease;
    overflow-y: auto;
  }
  .site-nav.open { transform: translateX(0); }
  .site-nav a { font-size: 1.1rem; width: 100%; }
  .nav-cta { text-align: center; }
  .nav-toggle { display: flex; }
  .nav-toggle.open span:nth-child(1) { transform: translateY(7px) rotate(45deg); }
  .nav-toggle.open span:nth-child(2) { opacity: 0; }
  .nav-toggle.open span:nth-child(3) { transform: translateY(-7px) rotate(-45deg); }

  .class-cards,
  .expect-grid,
  .coach-cards { grid-template-columns: 1fr; }
  .location-wrap,
  .contact-wrap { grid-template-columns: 1fr; }
  .location-map { order: -1; }
  .affiliation { flex-direction: column; text-align: center; }
}

@media (max-width: 480px) {
  .hero-inner { padding-top: 72px; }
  .section { padding: 64px 0; }
}
