/* ============================================
   Maple Valley BMW Club — style.css
   Palette drawn from BMW M division livery:
   M light blue / M dark blue / M red on asphalt.
   ============================================ */

:root {
  --asphalt: #0b0d11;
  --carbon: #141821;
  --carbon-2: #1a1f2b;
  --line: rgba(244, 246, 249, 0.1);
  --white: #f4f6f9;
  --muted: #9aa3b2;
  --m-blue: #00a1e4;
  --m-navy: #2353a0;
  --m-red: #e7222e;
  --radius: 10px;
  --max: 1120px;
}

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

html { scroll-behavior: smooth; }

body {
  background: var(--asphalt);
  color: var(--white);
  font-family: "Barlow", system-ui, sans-serif;
  font-size: 17px;
  line-height: 1.6;
  -webkit-font-smoothing: antialiased;
}

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

a { color: var(--m-blue); text-decoration: none; }
a:hover { text-decoration: underline; }
a:focus-visible, button:focus-visible, input:focus-visible, textarea:focus-visible {
  outline: 2px solid var(--m-blue);
  outline-offset: 3px;
}

.wrap { max-width: var(--max); margin: 0 auto; padding: 0 24px; }

/* ---------- M stripe signature ---------- */
.m-stripe {
  display: inline-flex;
  gap: 4px;
  height: 1em;
  vertical-align: -0.1em;
}
.m-stripe i {
  width: 0.32em;
  transform: skewX(-18deg);
  border-radius: 1px;
}
.m-stripe i:nth-child(1) { background: var(--m-blue); }
.m-stripe i:nth-child(2) { background: var(--m-navy); }
.m-stripe i:nth-child(3) { background: var(--m-red); }

/* ---------- Header / nav ---------- */
.site-header {
  position: sticky;
  top: 0;
  z-index: 50;
  background: rgba(11, 13, 17, 0.88);
  backdrop-filter: blur(10px);
  border-bottom: 1px solid var(--line);
}
.site-header .wrap {
  display: flex;
  align-items: center;
  justify-content: space-between;
  height: 68px;
}
.brand {
  display: flex;
  align-items: center;
  gap: 12px;
  font-family: "Archivo", sans-serif;
  font-weight: 800;
  font-size: 17px;
  letter-spacing: 0.04em;
  text-transform: uppercase;
  color: var(--white);
}
.brand:hover { text-decoration: none; }
.brand .m-stripe { font-size: 22px; }
.brand small {
  display: block;
  font-family: "Chakra Petch", monospace;
  font-weight: 500;
  font-size: 10px;
  letter-spacing: 0.28em;
  color: var(--muted);
}

nav.main-nav { display: flex; gap: 6px; }
nav.main-nav a {
  position: relative;
  color: var(--muted);
  font-family: "Chakra Petch", monospace;
  font-size: 13px;
  font-weight: 500;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  padding: 10px 14px;
}
nav.main-nav a::after {
  content: "";
  position: absolute;
  left: 14px;
  right: 14px;
  bottom: 4px;
  height: 3px;
  background: linear-gradient(90deg, var(--m-blue) 0 33%, var(--m-navy) 33% 66%, var(--m-red) 66% 100%);
  transform: scaleX(0);
  transform-origin: left;
  transition: transform 0.25s ease;
}
nav.main-nav a:hover { color: var(--white); text-decoration: none; }
nav.main-nav a:hover::after,
nav.main-nav a.active::after { transform: scaleX(1); }
nav.main-nav a.active { color: var(--white); }

/* ---------- Hero ---------- */
.hero {
  position: relative;
  overflow: hidden;
  padding: 110px 0 90px;
  background:
    radial-gradient(900px 420px at 80% -10%, rgba(0, 161, 228, 0.16), transparent 65%),
    radial-gradient(700px 380px at 5% 110%, rgba(231, 34, 46, 0.1), transparent 60%),
    var(--asphalt);
}
.hero::before {
  content: "";
  position: absolute;
  inset: 0;
  background-image: linear-gradient(var(--line) 1px, transparent 1px),
    linear-gradient(90deg, var(--line) 1px, transparent 1px);
  background-size: 56px 56px;
  mask-image: radial-gradient(700px 500px at 70% 20%, rgba(0,0,0,0.5), transparent 75%);
  pointer-events: none;
}
.hero-sweep {
  position: absolute;
  top: 0;
  right: -8%;
  height: 100%;
  width: 38%;
  display: flex;
  gap: clamp(10px, 1.6vw, 22px);
  transform: skewX(-18deg);
  opacity: 0.9;
  pointer-events: none;
}
.hero-sweep span { flex: 1; }
.hero-sweep span:nth-child(1) { background: linear-gradient(180deg, var(--m-blue), transparent 92%); opacity: .22; }
.hero-sweep span:nth-child(2) { background: linear-gradient(180deg, var(--m-navy), transparent 92%); opacity: .26; }
.hero-sweep span:nth-child(3) { background: linear-gradient(180deg, var(--m-red), transparent 92%); opacity: .2; }

.eyebrow {
  font-family: "Chakra Petch", monospace;
  font-size: 13px;
  font-weight: 500;
  letter-spacing: 0.3em;
  text-transform: uppercase;
  color: var(--m-blue);
  margin-bottom: 18px;
}
.hero h1 {
  position: relative;
  font-family: "Archivo", sans-serif;
  font-weight: 800;
  font-size: clamp(42px, 7vw, 84px);
  line-height: 0.98;
  letter-spacing: -0.01em;
  text-transform: uppercase;
  max-width: 12ch;
}
.hero h1 .accent { color: var(--m-red); }
.hero p.lede {
  position: relative;
  margin-top: 22px;
  max-width: 54ch;
  font-size: 19px;
  color: var(--muted);
}
.hero-actions { position: relative; margin-top: 34px; display: flex; gap: 14px; flex-wrap: wrap; }

/* ---------- Buttons ---------- */
.btn {
  display: inline-block;
  font-family: "Chakra Petch", monospace;
  font-size: 14px;
  font-weight: 500;
  letter-spacing: 0.1em;
  text-transform: uppercase;
  padding: 14px 26px;
  border-radius: 6px;
  border: 1px solid transparent;
  transition: transform 0.15s ease, background 0.2s ease, border-color 0.2s ease;
}
.btn:hover { text-decoration: none; transform: translateY(-2px); }
.btn-primary { background: var(--m-red); color: #fff; }
.btn-primary:hover { background: #f23440; }
.btn-ghost { border-color: var(--line); color: var(--white); }
.btn-ghost:hover { border-color: var(--m-blue); color: var(--m-blue); }

/* ---------- Next meet card ---------- */
.meet-card {
  position: relative;
  margin-top: 56px;
  background: var(--carbon);
  border: 1px solid var(--line);
  border-radius: var(--radius);
  padding: 26px 28px;
  display: grid;
  grid-template-columns: auto 1fr auto;
  gap: 26px;
  align-items: center;
  overflow: hidden;
}
.meet-card::before {
  content: "";
  position: absolute;
  left: 0;
  top: 0;
  bottom: 0;
  width: 6px;
  background: linear-gradient(180deg, var(--m-blue) 0 33%, var(--m-navy) 33% 66%, var(--m-red) 66% 100%);
}
.meet-date {
  font-family: "Archivo", sans-serif;
  font-weight: 800;
  text-align: center;
  line-height: 1;
  padding-left: 8px;
}
.meet-date .day { font-size: 46px; }
.meet-date .month {
  display: block;
  font-family: "Chakra Petch", monospace;
  font-weight: 500;
  font-size: 13px;
  letter-spacing: 0.3em;
  color: var(--m-blue);
  margin-top: 6px;
}
.meet-card h3 { font-family: "Archivo", sans-serif; font-size: 21px; font-weight: 700; }
.meet-card p { color: var(--muted); font-size: 15px; margin-top: 4px; }

/* ---------- Sections ---------- */
.section { padding: 84px 0; }
.section.alt { background: var(--carbon); border-top: 1px solid var(--line); border-bottom: 1px solid var(--line); }
.section-head { margin-bottom: 44px; max-width: 60ch; }
.section-head h2 {
  font-family: "Archivo", sans-serif;
  font-weight: 800;
  font-size: clamp(28px, 4vw, 42px);
  text-transform: uppercase;
  line-height: 1.05;
}
.section-head p { margin-top: 12px; color: var(--muted); }

/* ---------- Cards grid ---------- */
.grid-3 { display: grid; grid-template-columns: repeat(3, 1fr); gap: 22px; }
.grid-2 { display: grid; grid-template-columns: repeat(2, 1fr); gap: 22px; }
.card {
  background: var(--carbon-2);
  border: 1px solid var(--line);
  border-radius: var(--radius);
  padding: 26px;
  transition: transform 0.2s ease, border-color 0.2s ease;
}
.section.alt .card { background: var(--asphalt); }
.card:hover { transform: translateY(-4px); border-color: rgba(0, 161, 228, 0.45); }
.card .tag {
  font-family: "Chakra Petch", monospace;
  font-size: 12px;
  font-weight: 500;
  letter-spacing: 0.22em;
  text-transform: uppercase;
  margin-bottom: 14px;
}
.tag.blue { color: var(--m-blue); }
.tag.navy { color: #6e9fe0; }
.tag.red { color: var(--m-red); }
.card h3 { font-family: "Archivo", sans-serif; font-size: 19px; font-weight: 700; margin-bottom: 8px; }
.card p { color: var(--muted); font-size: 15.5px; }
.card ul { color: var(--muted); font-size: 15.5px; padding-left: 18px; margin-top: 6px; }
.card li { margin-bottom: 6px; }

/* ---------- Detail rows (meet info) ---------- */
.detail-row {
  display: grid;
  grid-template-columns: 200px 1fr;
  gap: 24px;
  padding: 22px 0;
  border-bottom: 1px solid var(--line);
}
.detail-row:first-of-type { border-top: 1px solid var(--line); }
.detail-row dt {
  font-family: "Chakra Petch", monospace;
  font-size: 13px;
  font-weight: 500;
  letter-spacing: 0.2em;
  text-transform: uppercase;
  color: var(--m-blue);
  padding-top: 3px;
}
.detail-row dd p + p { margin-top: 8px; }
.detail-row dd { color: var(--white); }
.detail-row dd .sub { color: var(--muted); font-size: 15px; }

/* ---------- Rules list ---------- */
.rules { counter-reset: rule; list-style: none; }
.rules li {
  counter-increment: rule;
  display: grid;
  grid-template-columns: 56px 1fr;
  gap: 18px;
  padding: 18px 0;
  border-bottom: 1px solid var(--line);
  color: var(--muted);
}
.rules li strong { color: var(--white); display: block; font-family: "Archivo", sans-serif; }
.rules li::before {
  content: counter(rule, decimal-leading-zero);
  font-family: "Chakra Petch", monospace;
  font-size: 22px;
  color: var(--m-red);
  line-height: 1.3;
}

/* ---------- Contact ---------- */
.contact-grid { display: grid; grid-template-columns: 1.1fr 0.9fr; gap: 40px; align-items: start; }
.contact-list { list-style: none; }
.contact-list li {
  display: flex;
  justify-content: space-between;
  gap: 16px;
  padding: 18px 0;
  border-bottom: 1px solid var(--line);
}
.contact-list .label {
  font-family: "Chakra Petch", monospace;
  font-size: 13px;
  letter-spacing: 0.2em;
  text-transform: uppercase;
  color: var(--muted);
}

form .field { margin-bottom: 18px; }
form label {
  display: block;
  font-family: "Chakra Petch", monospace;
  font-size: 12px;
  letter-spacing: 0.2em;
  text-transform: uppercase;
  color: var(--muted);
  margin-bottom: 8px;
}
form input, form textarea {
  width: 100%;
  background: var(--carbon-2);
  border: 1px solid var(--line);
  border-radius: 6px;
  color: var(--white);
  font-family: "Barlow", sans-serif;
  font-size: 16px;
  padding: 13px 14px;
}
form input:focus, form textarea:focus { border-color: var(--m-blue); outline: none; }
form button { cursor: pointer; }

/* ---------- Footer ---------- */
.site-footer { border-top: 1px solid var(--line); padding: 36px 0 44px; }
.site-footer .stripe-bar {
  height: 4px;
  background: linear-gradient(90deg, var(--m-blue) 0 33%, var(--m-navy) 33% 66%, var(--m-red) 66% 100%);
  border-radius: 2px;
  margin-bottom: 28px;
}
.site-footer .wrap-inner {
  display: flex;
  justify-content: space-between;
  gap: 20px;
  flex-wrap: wrap;
  color: var(--muted);
  font-size: 14px;
}
.site-footer nav { display: flex; gap: 18px; }
.site-footer a { color: var(--muted); }
.site-footer a:hover { color: var(--white); }

/* ---------- Page hero (interior pages) ---------- */
.page-hero {
  padding: 76px 0 56px;
  border-bottom: 1px solid var(--line);
  background:
    radial-gradient(700px 300px at 85% 0%, rgba(0, 161, 228, 0.12), transparent 65%),
    var(--asphalt);
}
.page-hero h1 {
  font-family: "Archivo", sans-serif;
  font-weight: 800;
  font-size: clamp(34px, 5vw, 58px);
  text-transform: uppercase;
  line-height: 1.02;
}
.page-hero p { margin-top: 14px; color: var(--muted); max-width: 58ch; font-size: 18px; }

/* ---------- Responsive ---------- */
@media (max-width: 860px) {
  .grid-3, .grid-2, .contact-grid { grid-template-columns: 1fr; }
  .meet-card { grid-template-columns: auto 1fr; }
  .meet-card .btn { grid-column: 1 / -1; text-align: center; }
  .detail-row { grid-template-columns: 1fr; gap: 8px; }
  .hero { padding: 80px 0 64px; }
  .hero-sweep { width: 55%; right: -25%; }
}
@media (max-width: 640px) {
  .site-header .wrap { flex-direction: column; height: auto; padding-top: 14px; padding-bottom: 10px; gap: 4px; }
  nav.main-nav { flex-wrap: wrap; justify-content: center; }
  .brand small { display: none; }
}

@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after { transition: none !important; animation: none !important; }
  html { scroll-behavior: auto; }
}
