/* ==========================================================================
   Pickleball Brantford — Design System
   Modernized club brand: vivid green + charcoal, sleek & contemporary
   ========================================================================== */

/* ---------- Design tokens ---------- */
:root {
  /* Brand */
  --green: #8bc53f;
  --green-600: #6fa42b;
  --green-700: #527a1c;
  --green-300: #b9df84;
  --green-tint: #f1f8e6;
  --green-tint-2: #e7f2d3;

  /* Neutrals */
  --ink: #14181b;
  --charcoal: #20262b;
  --charcoal-2: #2b3238;
  --slate: #54616b;
  --muted: #7c8893;
  --line: #e7ebe2;
  --line-2: #eef1ea;
  --paper: #ffffff;
  --paper-2: #f7f9f4;

  /* Effects */
  --radius-sm: 10px;
  --radius: 16px;
  --radius-lg: 24px;
  --radius-xl: 32px;
  --shadow-sm: 0 1px 2px rgba(20, 24, 27, .06), 0 2px 8px rgba(20, 24, 27, .05);
  --shadow: 0 10px 30px -12px rgba(20, 24, 27, .18);
  --shadow-lg: 0 30px 60px -24px rgba(20, 24, 27, .28);
  --shadow-green: 0 16px 36px -14px rgba(111, 164, 43, .55);

  --maxw: 1200px;
  --gutter: clamp(20px, 5vw, 56px);

  --font-head: "Outfit", "Segoe UI", system-ui, -apple-system, sans-serif;
  --font-body: "Inter", "Segoe UI", system-ui, -apple-system, sans-serif;

  --ease: cubic-bezier(.22, .61, .36, 1);
}

/* ---------- Reset ---------- */
*, *::before, *::after { box-sizing: border-box; }
* { margin: 0; }
html { scroll-behavior: smooth; -webkit-text-size-adjust: 100%; overflow-x: clip; }
body {
  font-family: var(--font-body);
  color: var(--charcoal);
  background: var(--paper);
  line-height: 1.65;
  font-size: 17px;
  -webkit-font-smoothing: antialiased;
  text-rendering: optimizeLegibility;
  overflow-x: hidden;
}
img, svg { display: block; max-width: 100%; }
a { color: inherit; text-decoration: none; }
button { font: inherit; cursor: pointer; border: 0; background: none; color: inherit; }
ul { list-style: none; padding: 0; }
:focus-visible { outline: 2.5px solid var(--green-600); outline-offset: 3px; border-radius: 8px; }
h1, h2, h3, h4 { font-family: var(--font-head); line-height: 1.08; color: var(--ink); font-weight: 700; letter-spacing: -.02em; }

/* ---------- Layout helpers ---------- */
.container { width: 100%; max-width: var(--maxw); margin-inline: auto; padding-inline: var(--gutter); }
.section { padding-block: clamp(44px, 5.5vw, 82px); }
.section--tint { background: var(--paper-2); }
.section--ink { background: var(--ink); color: #d7dde2; }
.narrow { max-width: 820px; }
.center { text-align: center; }
.stack > * + * { margin-top: 1rem; }

.eyebrow {
  display: inline-flex; align-items: center; gap: 9px;
  font-family: var(--font-head); font-weight: 600;
  font-size: .8rem; letter-spacing: .16em; text-transform: uppercase;
  color: var(--green-700);
  background: var(--green-tint); border: 1px solid var(--green-tint-2);
  padding: 7px 14px; border-radius: 100px;
}
.section--ink .eyebrow { color: var(--green-300); background: rgba(139,197,63,.1); border-color: rgba(139,197,63,.2); }
.eyebrow svg { width: 15px; height: 15px; }

.section-title { font-size: clamp(2rem, 4.4vw, 3.1rem); margin-top: 18px; }
.section--ink .section-title { color: #fff; }
.section-lead { font-size: 1.12rem; color: var(--slate); margin-top: 16px; max-width: 60ch; }
.section--ink .section-lead { color: #aeb8bf; }
.center .section-lead, .center .eyebrow + .section-title + .section-lead { margin-inline: auto; }

/* ---------- Buttons ---------- */
.btn {
  --bg: var(--green); --fg: #18260a;
  display: inline-flex; align-items: center; justify-content: center; gap: 10px;
  font-family: var(--font-head); font-weight: 600; font-size: 1rem;
  padding: 14px 26px; border-radius: 100px;
  background: var(--bg); color: var(--fg);
  transition: transform .25s var(--ease), box-shadow .25s var(--ease), background .25s var(--ease);
  white-space: nowrap; box-shadow: var(--shadow-sm); position: relative;
}
.btn svg { width: 18px; height: 18px; transition: transform .25s var(--ease); }
.btn:hover { transform: translateY(-2px); box-shadow: var(--shadow-green); }
.btn:hover svg.arrow { transform: translateX(4px); }
.btn:active { transform: translateY(0); }
.btn--primary { background: linear-gradient(135deg, var(--green) 0%, var(--green-600) 100%); color: #fff; }
.btn--dark { background: var(--ink); color: #fff; }
.btn--dark:hover { box-shadow: var(--shadow-lg); }
.btn--ghost { background: transparent; color: var(--ink); box-shadow: inset 0 0 0 1.5px var(--line); }
.btn--ghost:hover { box-shadow: inset 0 0 0 1.5px var(--green); color: var(--green-700); }
.section--ink .btn--ghost { color: #fff; box-shadow: inset 0 0 0 1.5px rgba(255,255,255,.25); }
.section--ink .btn--ghost:hover { box-shadow: inset 0 0 0 1.5px var(--green); color: var(--green-300); }
.btn--lg { padding: 17px 32px; font-size: 1.06rem; }
.btn--sm { padding: 10px 18px; font-size: .9rem; }
.btn--block { display: flex; width: 100%; }

.textlink { color: var(--green-700); font-weight: 600; display: inline-flex; align-items: center; gap: 6px; }
.textlink svg { width: 16px; height: 16px; transition: transform .2s var(--ease); }
.textlink:hover { color: var(--green-600); }
.textlink:hover svg { transform: translateX(3px); }

/* ==========================================================================
   Header / Navigation
   ========================================================================== */
.site-header {
  position: sticky; top: 0; z-index: 100;
  background: rgba(255,255,255,.82);
  backdrop-filter: saturate(160%) blur(14px);
  -webkit-backdrop-filter: saturate(160%) blur(14px);
  border-bottom: 1px solid transparent;
  transition: border-color .3s var(--ease), box-shadow .3s var(--ease), background .3s var(--ease);
}
.site-header.scrolled { border-color: var(--line); box-shadow: 0 6px 24px -18px rgba(20,24,27,.4); }
.nav { display: flex; align-items: center; justify-content: space-between; height: 78px; gap: 24px; }

/* Logo */
.brand { display: inline-flex; align-items: center; }
.brand-badge { width: 56px; height: 56px; flex: none; object-fit: contain; transition: transform .3s var(--ease); }
.brand:hover .brand-badge { transform: scale(1.05) rotate(-1deg); }

/* Desktop nav */
.nav-menu { display: flex; align-items: center; gap: 4px; }
.nav-item { position: relative; }
.nav-link {
  display: inline-flex; align-items: center; gap: 6px;
  font-family: var(--font-head); font-weight: 500; font-size: .96rem; color: var(--charcoal);
  padding: 10px 14px; border-radius: 100px; transition: color .2s, background .2s;
}
.nav-link:hover { color: var(--green-700); background: var(--green-tint); }
.nav-link.active { color: var(--green-700); }
.nav-link .chev { width: 15px; height: 15px; transition: transform .25s var(--ease); }
.nav-item:hover .nav-link .chev { transform: rotate(180deg); }

/* Dropdown */
.dropdown {
  position: absolute; top: calc(100% + 10px); left: 50%; transform: translateX(-50%) translateY(8px);
  min-width: 270px; background: #fff; border: 1px solid var(--line);
  border-radius: var(--radius); box-shadow: var(--shadow-lg); padding: 8px;
  opacity: 0; visibility: hidden; transition: opacity .22s var(--ease), transform .22s var(--ease);
}
.nav-item:hover .dropdown, .nav-item:focus-within .dropdown { opacity: 1; visibility: visible; transform: translateX(-50%) translateY(0); }
.dropdown::before { content: ""; position: absolute; top: -10px; left: 0; right: 0; height: 10px; }
.dropdown-link { display: flex; align-items: center; gap: 12px; padding: 11px 12px; border-radius: 11px; transition: background .18s; }
.dropdown-link:hover { background: var(--green-tint); }
.dropdown-link .ico { width: 38px; height: 38px; flex: none; border-radius: 10px; background: var(--green-tint); color: var(--green-700); display: grid; place-items: center; transition: background .18s, color .18s; }
.dropdown-link:hover .ico { background: var(--green); color: #fff; }
.dropdown-link .ico svg { width: 20px; height: 20px; }
.dropdown-link .txt { display: flex; flex-direction: column; gap: 3px; min-width: 0; }
.dropdown-link .t { display: block; font-family: var(--font-head); font-weight: 600; font-size: .96rem; color: var(--ink); line-height: 1.25; }
.dropdown-link .d { display: block; font-size: .8rem; color: var(--muted); line-height: 1.35; }

.nav-cta { display: flex; align-items: center; gap: 10px; }

/* Hamburger */
.nav-toggle { display: none; width: 46px; height: 46px; border-radius: 12px; border: 1px solid var(--line); align-items: center; justify-content: center; }
.nav-toggle svg { width: 24px; height: 24px; }

/* Mobile panel */
.mobile-panel {
  position: fixed; inset: 0 0 0 auto; width: min(420px, 88vw); background: #fff; z-index: 200;
  transform: translateX(100%); transition: transform .38s var(--ease);
  display: flex; flex-direction: column; padding: 22px; overflow-y: auto; box-shadow: var(--shadow-lg);
}
.mobile-panel.open { transform: translateX(0); }
.mobile-overlay { position: fixed; inset: 0; background: rgba(15,20,18,.45); backdrop-filter: blur(2px); z-index: 199; opacity: 0; visibility: hidden; transition: opacity .3s; }
.mobile-overlay.open { opacity: 1; visibility: visible; }
.mobile-head { display: flex; align-items: center; justify-content: space-between; margin-bottom: 18px; }
.mobile-close { width: 44px; height: 44px; border-radius: 12px; border: 1px solid var(--line); display: grid; place-items: center; }
.mobile-close svg { width: 22px; height: 22px; }
.mobile-nav a { display: block; padding: 14px 12px; font-family: var(--font-head); font-weight: 600; font-size: 1.08rem; color: var(--ink); border-radius: 12px; }
.mobile-nav a:hover, .mobile-nav a.active { background: var(--green-tint); color: var(--green-700); }
.mobile-group-label { font-size: .72rem; letter-spacing: .16em; text-transform: uppercase; color: var(--muted); padding: 18px 12px 6px; font-family: var(--font-head); font-weight: 600; }
.mobile-sub a { font-size: .98rem; font-weight: 500; padding-left: 22px; color: var(--slate); }
.mobile-panel .btn { margin-top: 22px; }

/* ==========================================================================
   Hero
   ========================================================================== */
.hero { position: relative; overflow: hidden; background: var(--ink); color: #fff; }
.hero-bg { position: absolute; inset: 0; z-index: 0; }
.hero-bg .court { position: absolute; inset: 0; width: 100%; height: 100%; opacity: .9; }
.hero-glow { position: absolute; width: 60vw; height: 60vw; max-width: 720px; max-height: 720px; right: -10%; top: -20%; background: radial-gradient(circle, rgba(139,197,63,.5), transparent 65%); filter: blur(20px); }
.hero-inner { position: relative; z-index: 2; display: grid; grid-template-columns: 1.05fr .95fr; gap: 48px; align-items: center; padding-block: clamp(48px, 6vw, 88px); }
.hero h1 { font-size: clamp(2.5rem, 5.6vw, 4.4rem); color: #fff; line-height: 1.12; margin-top: 20px; }
.hero h1 .hl { color: var(--green-300); }
.hero-lead { font-size: clamp(1.05rem, 2vw, 1.3rem); color: #c2cbd2; margin-top: 24px; max-width: 52ch; }
.hero-cta { display: flex; flex-wrap: wrap; gap: 14px; margin-top: 28px; }
.hero-stats { display: flex; gap: 30px; margin-top: 32px; flex-wrap: wrap; }
.hero-stat .n { font-family: var(--font-head); font-weight: 800; font-size: 2rem; color: #fff; line-height: 1; }
.hero-stat .l { font-size: .82rem; color: #9aa6ad; margin-top: 6px; letter-spacing: .02em; }
.hero-art { position: relative; }
.hero-pill { position: absolute; background: #fff; color: var(--ink); border-radius: 16px; padding: 12px 16px; box-shadow: var(--shadow-lg); display: flex; align-items: center; gap: 11px; font-family: var(--font-head); }
.hero-pill .ico { width: 38px; height: 38px; border-radius: 11px; display: grid; place-items: center; background: var(--green-tint); color: var(--green-700); flex: none; }
.hero-pill .ico svg { width: 21px; height: 21px; }
.hero-pill b { display: block; font-size: .95rem; }
.hero-pill span { font-size: .76rem; color: var(--muted); font-family: var(--font-body); }
.hero-pill--1 { top: 8%; left: -6%; animation: float 6s ease-in-out infinite; }
.hero-pill--2 { bottom: 10%; right: 14px; animation: float 6s ease-in-out infinite .8s; }
@keyframes float { 0%,100% { transform: translateY(0); } 50% { transform: translateY(-12px); } }

/* compact page hero */
.page-hero { position: relative; background: var(--ink); color: #fff; overflow: hidden; }
.page-hero .hero-glow { right: 6%; top: -30%; opacity: .8; }
.page-hero-inner { position: relative; z-index: 2; padding-block: clamp(36px, 4.5vw, 62px); max-width: 760px; }
.page-hero h1 { color: #fff; font-size: clamp(2.2rem, 5vw, 3.6rem); margin-top: 16px; }
.page-hero p { color: #b9c2c9; font-size: 1.12rem; margin-top: 16px; max-width: 56ch; }
.breadcrumb { display: flex; align-items: center; gap: 8px; margin-bottom: 20px; font-size: .85rem; color: #8b97a0; font-family: var(--font-head); }
.breadcrumb a:hover { color: var(--green-300); }
.breadcrumb svg { width: 14px; height: 14px; }

/* ==========================================================================
   Cards & grids
   ========================================================================== */
.grid { display: grid; gap: 24px; }
/* tighten the gap between a section heading and its card grid */
.grid[style*="margin-top"] { margin-top: 34px !important; }
.grid-3 { grid-template-columns: repeat(3, 1fr); }
.grid-2 { grid-template-columns: repeat(2, 1fr); }
.grid-4 { grid-template-columns: repeat(4, 1fr); }

.card {
  background: #fff; border: 1px solid var(--line); border-radius: var(--radius-lg);
  padding: 32px; transition: transform .3s var(--ease), box-shadow .3s var(--ease), border-color .3s var(--ease);
  position: relative; overflow: hidden;
}
.card:hover { transform: translateY(-6px); box-shadow: var(--shadow); border-color: var(--green-300); }
.card-ico { width: 58px; height: 58px; border-radius: 16px; display: grid; place-items: center; background: var(--green-tint); color: var(--green-700); margin-bottom: 20px; transition: background .3s, color .3s; }
.card:hover .card-ico { background: var(--green); color: #fff; }
.card-ico svg { width: 30px; height: 30px; }
.card h3 { font-size: 1.32rem; margin-bottom: 10px; }
.card p { color: var(--slate); font-size: .98rem; }
.card .textlink { margin-top: 18px; }
.card-tag { position: absolute; top: 20px; right: 20px; font-family: var(--font-head); font-weight: 600; font-size: .72rem; letter-spacing: .08em; text-transform: uppercase; color: var(--green-700); background: var(--green-tint); padding: 5px 11px; border-radius: 100px; }

/* Feature card with number */
.step { background: #fff; border: 1px solid var(--line); border-radius: var(--radius-lg); padding: 34px 30px; position: relative; transition: transform .3s var(--ease), box-shadow .3s var(--ease); }
.step:hover { transform: translateY(-6px); box-shadow: var(--shadow); }
.step-num { font-family: var(--font-head); font-weight: 800; font-size: 1.05rem; width: 44px; height: 44px; border-radius: 50%; display: grid; place-items: center; color: #fff; background: linear-gradient(135deg, var(--green), var(--green-600)); margin-bottom: 22px; box-shadow: var(--shadow-green); }
.step h3 { font-size: 1.25rem; margin-bottom: 9px; }
.step p { color: var(--slate); font-size: .97rem; }
.step-line { position: absolute; top: 56px; left: 100%; width: 26px; height: 2px; background: var(--green-300); }

/* Benefit list */
.benefits-grid { display: grid; grid-template-columns: repeat(2, 1fr); gap: 16px; }
.benefit { display: flex; gap: 15px; align-items: flex-start; min-width: 0; background: #fff; border: 1px solid var(--line); border-radius: var(--radius); padding: 20px 22px; transition: border-color .25s, transform .25s; }
.benefit span { min-width: 0; overflow-wrap: anywhere; }
.benefit:hover { border-color: var(--green-300); transform: translateY(-3px); }
.benefit .check { flex: none; width: 30px; height: 30px; border-radius: 9px; background: var(--green-tint); color: var(--green-700); display: grid; place-items: center; margin-top: 2px; }
.benefit .check svg { width: 17px; height: 17px; }
.benefit b { font-family: var(--font-head); display: block; font-size: 1.02rem; color: var(--ink); }
.benefit span { color: var(--slate); font-size: .92rem; }

/* Split media block */
.split { display: grid; grid-template-columns: 1fr 1fr; gap: clamp(32px, 5vw, 72px); align-items: center; }
.split--rev .split-media { order: 2; }
.split-media { border-radius: var(--radius-xl); overflow: hidden; box-shadow: var(--shadow); position: relative; aspect-ratio: 4/3.2; background: radial-gradient(rgba(255,255,255,.14) 1.7px, transparent 2px) 0 0 / 20px 20px, linear-gradient(135deg, var(--green) 0%, var(--green-700) 100%); }
.split-media svg { width: 100%; height: 100%; }
.media-photo { width: 100%; height: 100%; object-fit: cover; display: block; }

/* Hero photo frame */
.hero-frame { position: relative; isolation: isolate; border-radius: var(--radius-xl); overflow: hidden; box-shadow: var(--shadow-lg); aspect-ratio: 4 / 3.35; background: radial-gradient(rgba(255,255,255,.1) 1.7px, transparent 2px) 0 0 / 20px 20px, linear-gradient(135deg, #2f93b8 0%, #14181b 100%); }
.hero-frame > img { width: 100%; height: 100%; object-fit: cover; display: block; }
.hero-frame::after { content: ""; position: absolute; inset: 0; z-index: 1; background: linear-gradient(180deg, rgba(20,24,27,0) 45%, rgba(20,24,27,.4) 100%); pointer-events: none; }

/* Live Instagram widget embed (optional) fills the hero frame */
.hero-frame iframe, .hero-frame .ig-widget { position: absolute; inset: 0; width: 100%; height: 100%; border: 0; display: block; z-index: 0; }

/* Rotating Instagram carousel */
.ig-carousel { position: relative; }
.ig-slide { position: absolute; inset: 0; width: 100%; height: 100%; object-fit: cover; opacity: 0; transform: scale(1.04); transition: opacity 1s var(--ease), transform 6s ease-out; z-index: 0; }
.ig-slide.is-active { opacity: 1; transform: scale(1); z-index: 0; }
.ig-badge { position: absolute; top: 14px; right: 14px; z-index: 4; display: inline-flex; align-items: center; gap: 8px; background: rgba(255,255,255,.92); color: var(--ink); font-family: var(--font-head); font-weight: 600; font-size: .82rem; padding: 8px 13px; border-radius: 100px; box-shadow: var(--shadow-sm); backdrop-filter: blur(6px); transition: transform .25s var(--ease); }
.ig-badge:hover { transform: translateY(-2px); }
.ig-badge svg { width: 17px; height: 17px; }
.ig-nav { position: absolute; top: 50%; transform: translateY(-50%); z-index: 3; width: 42px; height: 42px; border-radius: 50%; background: rgba(255,255,255,.9); color: var(--ink); display: grid; place-items: center; box-shadow: var(--shadow); opacity: 0; transition: opacity .25s var(--ease), background .2s; }
.ig-carousel:hover .ig-nav { opacity: 1; }
.ig-nav:hover { background: #fff; }
.ig-nav svg { width: 22px; height: 22px; }
.ig-nav.ig-prev { left: 14px; }
.ig-nav.ig-next { right: 14px; }
.ig-dots { position: absolute; bottom: 16px; left: 50%; transform: translateX(-50%); z-index: 3; display: flex; gap: 8px; }
.ig-dots button { width: 8px; height: 8px; border-radius: 100px; background: rgba(255,255,255,.55); transition: width .3s var(--ease), background .3s; }
.ig-dots button.is-active { width: 26px; background: #fff; }
@media (max-width: 560px) { .ig-nav { display: none; } .ig-badge { display: none; } }
@media (prefers-reduced-motion: reduce) { .ig-slide { transition: opacity .4s ease; transform: none; } .ig-slide.is-active { transform: none; } }
.split-body h2 { font-size: clamp(1.8rem, 3.6vw, 2.6rem); }

/* Info list (mission, etc.) */
.tile { background: #fff; border: 1px solid var(--line); border-radius: var(--radius-lg); padding: 30px; }
.tile h3 { display: flex; align-items: center; gap: 12px; font-size: 1.2rem; margin-bottom: 12px; }
.tile h3 .ico { width: 40px; height: 40px; border-radius: 11px; background: var(--green-tint); color: var(--green-700); display: grid; place-items: center; }
.tile h3 .ico svg { width: 22px; height: 22px; }
.tile .benefits-grid { grid-template-columns: repeat(2, minmax(0, 1fr)); }

/* ==========================================================================
   Community page specifics
   ========================================================================== */
.event-card { display: grid; grid-template-columns: 150px 1fr; background: #fff; border: 1px solid var(--line); border-radius: var(--radius-lg); overflow: hidden; transition: transform .3s var(--ease), box-shadow .3s var(--ease); }
.event-card:hover { transform: translateY(-5px); box-shadow: var(--shadow); }
.event-date { background: linear-gradient(160deg, var(--green) 0%, var(--green-600) 100%); color: #fff; display: flex; flex-direction: column; align-items: center; justify-content: center; padding: 26px 14px; text-align: center; }
.event-date .m { font-family: var(--font-head); font-weight: 600; letter-spacing: .14em; text-transform: uppercase; font-size: .82rem; opacity: .9; }
.event-date .d { font-family: var(--font-head); font-weight: 800; font-size: 2.7rem; line-height: 1; margin: 4px 0; }
.event-date .y { font-size: .85rem; opacity: .9; }
.event-body { padding: 28px 30px; }
.event-body .badge { display: inline-flex; align-items: center; gap: 7px; font-family: var(--font-head); font-weight: 600; font-size: .74rem; letter-spacing: .08em; text-transform: uppercase; color: var(--green-700); background: var(--green-tint); padding: 5px 12px; border-radius: 100px; margin-bottom: 12px; }
.event-body .badge svg { width: 14px; height: 14px; }
.event-body h3 { font-size: 1.4rem; margin-bottom: 9px; }
.event-body p { color: var(--slate); font-size: .98rem; }
.event-meta { display: flex; flex-wrap: wrap; gap: 18px; margin-top: 16px; }
.event-meta span { display: inline-flex; align-items: center; gap: 7px; font-size: .88rem; color: var(--muted); font-family: var(--font-head); font-weight: 500; }
.event-meta svg { width: 16px; height: 16px; color: var(--green-600); }

.impact-band { display: grid; grid-template-columns: repeat(4, 1fr); gap: 24px; text-align: center; }
.impact .n { font-family: var(--font-head); font-weight: 800; font-size: clamp(2.2rem, 4vw, 3rem); color: var(--green-300); line-height: 1; }
.impact .l { color: #aeb8bf; margin-top: 10px; font-size: .95rem; }
.vbadge { width: 66px; height: 66px; border-radius: 19px; display: grid; place-items: center; margin-inline: auto; background: rgba(139,197,63,.14); color: var(--green-300); }
.vbadge svg { width: 30px; height: 30px; }

/* ==========================================================================
   CTA band
   ========================================================================== */
.cta-band { position: relative; overflow: hidden; background: linear-gradient(135deg, var(--green-600) 0%, var(--green-700) 100%); color: #fff; border-radius: var(--radius-xl); padding: clamp(40px, 6vw, 72px); text-align: center; }
.cta-band h2 { color: #fff; font-size: clamp(1.9rem, 4vw, 3rem); }
.cta-band p { color: rgba(255,255,255,.9); font-size: 1.12rem; margin: 16px auto 30px; max-width: 50ch; }
.cta-band .btn--primary { background: #fff; color: var(--green-700); }
.cta-band .btn--primary:hover { box-shadow: 0 18px 40px -16px rgba(0,0,0,.5); }
.cta-band .btn--ghost { color: #fff; box-shadow: inset 0 0 0 1.5px rgba(255,255,255,.5); }
.cta-band .dots { position: absolute; inset: 0; opacity: .12; }

/* ==========================================================================
   Forms
   ========================================================================== */
.form { display: grid; gap: 18px; }
.field { display: grid; gap: 7px; }
.field label { font-family: var(--font-head); font-weight: 600; font-size: .9rem; color: var(--ink); }
.field input, .field textarea {
  font: inherit; font-size: 1rem; padding: 14px 16px; border-radius: 12px; border: 1.5px solid var(--line);
  background: #fff; color: var(--ink); transition: border-color .2s, box-shadow .2s; width: 100%;
}
.field input:focus, .field textarea:focus { outline: none; border-color: var(--green); box-shadow: 0 0 0 4px rgba(139,197,63,.16); }
.field textarea { resize: vertical; min-height: 140px; }
.form-row { display: grid; grid-template-columns: 1fr 1fr; gap: 18px; }
.form-note { font-size: .9rem; color: var(--muted); }
.form-success { display: none; align-items: center; gap: 12px; background: var(--green-tint); border: 1px solid var(--green-300); color: var(--green-700); padding: 16px 18px; border-radius: 12px; font-family: var(--font-head); font-weight: 600; }
.form-success.show { display: flex; }
.form-success svg { width: 22px; height: 22px; flex: none; }

.contact-card { background: var(--ink); color: #fff; border-radius: var(--radius-lg); padding: 34px; }
.contact-card h3 { color: #fff; }
.contact-method { display: flex; align-items: center; gap: 15px; padding: 16px 0; border-bottom: 1px solid rgba(255,255,255,.1); }
.contact-method:last-child { border-bottom: 0; }
.contact-method .ico { width: 46px; height: 46px; border-radius: 13px; background: rgba(139,197,63,.15); color: var(--green-300); display: grid; place-items: center; flex: none; }
.contact-method .ico svg { width: 22px; height: 22px; }
.contact-method .l { display: block; font-size: .8rem; color: #9aa6ad; margin-bottom: 1px; }
.contact-method .v { display: block; font-family: var(--font-head); font-weight: 600; color: #fff; word-break: break-word; }
.contact-method a.v:hover { color: var(--green-300); }

/* ==========================================================================
   Prose (code of conduct, etiquette)
   ========================================================================== */
.prose { max-width: 800px; }
.prose h2 { font-size: 1.6rem; margin-top: 44px; margin-bottom: 14px; scroll-margin-top: 100px; }
.prose h2:first-child { margin-top: 0; }
.prose h3 { font-size: 1.18rem; margin-top: 26px; margin-bottom: 8px; color: var(--green-700); }
.prose p { color: var(--slate); margin-bottom: 14px; }
.prose ul { display: grid; gap: 12px; margin: 16px 0; }
.prose ul li { display: flex; gap: 13px; align-items: flex-start; color: var(--slate); }
.prose ul li::before { content: ""; flex: none; width: 22px; height: 22px; margin-top: 2px; border-radius: 7px; background: var(--green-tint) url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='%23527a1c' stroke-width='3' stroke-linecap='round' stroke-linejoin='round'%3E%3Cpolyline points='20 6 9 17 4 12'/%3E%3C/svg%3E") center / 14px no-repeat; }
.prose ol { counter-reset: step; display: grid; gap: 14px; margin: 18px 0; padding: 0; }
.prose ol li { counter-increment: step; list-style: none; display: flex; gap: 16px; align-items: flex-start; background: #fff; border: 1px solid var(--line); border-radius: var(--radius); padding: 18px 20px; color: var(--slate); }
.prose ol li::before { content: counter(step); flex: none; width: 34px; height: 34px; border-radius: 50%; background: var(--ink); color: #fff; font-family: var(--font-head); font-weight: 700; display: grid; place-items: center; font-size: .95rem; }
.prose ol li b { color: var(--ink); font-family: var(--font-head); }

.toc { position: sticky; top: 100px; background: #fff; border: 1px solid var(--line); border-radius: var(--radius); padding: 22px; }
.toc h4 { font-size: .78rem; letter-spacing: .14em; text-transform: uppercase; color: var(--muted); margin-bottom: 14px; }
.toc a { display: block; padding: 8px 12px; border-radius: 9px; font-size: .92rem; color: var(--slate); font-family: var(--font-head); font-weight: 500; transition: background .18s, color .18s; }
.toc a:hover { background: var(--green-tint); color: var(--green-700); }
.with-toc { display: grid; grid-template-columns: 250px 1fr; gap: 56px; align-items: start; }

.callout { display: flex; gap: 16px; align-items: flex-start; background: var(--green-tint); border: 1px solid var(--green-tint-2); border-radius: var(--radius); padding: 22px 24px; margin: 8px 0 24px; }
.callout .ico { flex: none; width: 42px; height: 42px; border-radius: 12px; background: var(--green); color: #fff; display: grid; place-items: center; }
.callout .ico svg { width: 22px; height: 22px; }
.callout p { margin: 0; color: var(--green-700); }
.callout b { color: var(--ink); font-family: var(--font-head); }

/* ==========================================================================
   Footer
   ========================================================================== */
.site-footer { background: var(--ink); color: #aab4bb; padding-block: 64px 30px; }
.footer-top { display: grid; grid-template-columns: 1.4fr 1fr 1fr 1.2fr; gap: 40px; }
.footer-brand .brand-badge { width: 72px; height: 72px; }
.footer-about { margin-top: 18px; font-size: .95rem; color: #97a2a9; max-width: 34ch; }
.footer-social { display: flex; gap: 11px; margin-top: 22px; }
.footer-social a { width: 42px; height: 42px; border-radius: 12px; background: rgba(255,255,255,.07); display: grid; place-items: center; color: #cfd6db; transition: background .25s, color .25s, transform .25s; }
.footer-social a:hover { background: var(--green); color: #fff; transform: translateY(-3px); }
.footer-social svg { width: 20px; height: 20px; }
.footer-col h4 { color: #fff; font-size: .82rem; letter-spacing: .14em; text-transform: uppercase; margin-bottom: 18px; }
.footer-col a { display: block; padding: 6px 0; font-size: .95rem; color: #a3aeb5; transition: color .2s, padding .2s; }
.footer-col a:hover { color: var(--green-300); padding-left: 5px; }
.footer-col a.footer-cta { display: inline-flex; align-items: center; gap: 7px; width: auto; margin-top: 12px; padding: 9px 16px; border-radius: 100px; color: #fff; font-family: var(--font-head); font-weight: 600; font-size: .88rem; white-space: nowrap; box-shadow: inset 0 0 0 1.5px rgba(255,255,255,.22); transition: background .2s, box-shadow .2s; }
.footer-col a.footer-cta:hover { background: var(--green); color: #fff; padding-left: 16px; box-shadow: inset 0 0 0 1.5px var(--green); }
.footer-col a.footer-cta svg { width: 16px; height: 16px; }
.footer-contact-item { display: flex; gap: 11px; align-items: flex-start; margin-bottom: 14px; font-size: .94rem; }
.footer-contact-item svg { width: 18px; height: 18px; color: var(--green-300); flex: none; margin-top: 3px; }
.footer-sponsors { margin-top: 40px; padding-top: 28px; border-top: 1px solid rgba(255,255,255,.1); display: flex; flex-direction: column; align-items: center; gap: 12px; text-align: center; }
.footer-sponsors-label { font-family: var(--font-head); font-weight: 600; font-size: .74rem; letter-spacing: .16em; text-transform: uppercase; color: #8b97a0; }
.sponsor-logo { display: inline-flex; align-items: center; justify-content: center; background: #fff; padding: 12px 22px; border-radius: 14px; box-shadow: var(--shadow-sm); transition: transform .25s var(--ease), box-shadow .25s var(--ease); }
.sponsor-logo:hover { transform: translateY(-2px); box-shadow: var(--shadow-lg); }
.sponsor-logo img { height: 38px; width: auto; display: block; }
.footer-bottom { margin-top: 30px; padding-top: 24px; border-top: 1px solid rgba(255,255,255,.1); display: flex; justify-content: space-between; align-items: center; gap: 16px; flex-wrap: wrap; font-size: .86rem; color: #7e8a91; }
.footer-bottom a:hover { color: var(--green-300); }

/* ==========================================================================
   Scroll reveal
   ========================================================================== */
.reveal { opacity: 0; transform: translateY(26px); transition: opacity .7s var(--ease), transform .7s var(--ease); }
.reveal.in { opacity: 1; transform: none; }
.reveal[data-d="1"] { transition-delay: .08s; }
.reveal[data-d="2"] { transition-delay: .16s; }
.reveal[data-d="3"] { transition-delay: .24s; }
@media (prefers-reduced-motion: reduce) {
  .reveal { opacity: 1; transform: none; transition: none; }
  .hero-pill { animation: none; }
  html { scroll-behavior: auto; }
}

/* ==========================================================================
   Responsive
   ========================================================================== */
/* iPad landscape / small laptop: keep the full nav but tighten it so it fits */
@media (max-width: 1100px) {
  .nav { gap: 14px; }
  .nav-menu { gap: 0; }
  .nav-link { padding: 10px 11px; font-size: .92rem; }
  .nav-cta .btn--primary { padding: 12px 18px; }
}
/* iPad portrait and below: stack hero/split, two-column grids */
@media (max-width: 980px) {
  .hero-inner { grid-template-columns: 1fr; gap: 40px; }
  .hero-art { width: 100%; max-width: 460px; margin-inline: auto; }
  .split { grid-template-columns: 1fr; }
  .split--rev .split-media { order: 0; }
  .with-toc { grid-template-columns: 1fr; }
  .toc { position: static; }
  .grid-4 { grid-template-columns: repeat(2, 1fr); }
  .grid-3 { grid-template-columns: repeat(2, 1fr); }
  .tiles-grid { grid-template-columns: 1fr; }
  .impact-band { grid-template-columns: repeat(2, 1fr); }
  .step-line { display: none; }
  .section { padding-block: clamp(40px, 5vw, 66px); }
}
/* Collapse nav to the slide-out menu */
@media (max-width: 860px) {
  .nav-menu, .nav-cta .btn { display: none; }
  .nav-toggle { display: inline-flex; }
  .footer-top { grid-template-columns: 1fr 1fr; gap: 32px; }
  .footer-brand { grid-column: 1 / -1; }
}
/* Phones: turn card grids into swipeable horizontal carousels to shorten the page */
@media (max-width: 640px) {
  .grid-3, .grid-2:not(.tiles-grid) {
    grid-template-columns: none;
    grid-auto-flow: column;
    grid-auto-columns: 80%;
    gap: 14px;
    overflow-x: auto;
    overscroll-behavior-x: contain;
    scroll-snap-type: x mandatory;
    scroll-padding-left: var(--gutter);
    margin-inline: calc(var(--gutter) * -1);
    padding: 4px var(--gutter) 16px;
    -webkit-overflow-scrolling: touch;
    scrollbar-width: none;
  }
  .grid-3::-webkit-scrollbar, .grid-2:not(.tiles-grid)::-webkit-scrollbar { display: none; }
  .grid-3 > *, .grid-2:not(.tiles-grid) > * { scroll-snap-align: start; }
  .card { margin: 0; }
  .tiles-grid { grid-template-columns: 1fr; }
  .benefits-grid { grid-template-columns: 1fr; }
  /* keep the scroller from clipping card shadows/hover lift */
  .grid-3 .card:hover, .grid-2 .card:hover, .grid-3 .step:hover { transform: none; }
}
/* Phones */
@media (max-width: 560px) {
  body { font-size: 16px; }
  .nav { height: 66px; }
  .brand-badge { width: 48px; height: 48px; }
  /* tighter vertical rhythm */
  .section { padding-block: 46px; }
  .hero .hero-inner { padding-block: 40px 48px; }
  .page-hero-inner { padding-block: clamp(38px, 9vw, 60px); }
  .card { padding: 24px; }
  .tile { padding: 24px; }
  [style*="margin-top:52px"], [style*="margin-top:48px"] { margin-top: 28px !important; }
  .hero-stats { gap: 16px 26px; margin-top: 30px; }
  .hero-pill { padding: 10px 13px; }
  .hero-pill--1 { left: 0; top: 12px; } .hero-pill--2 { right: 0; bottom: 12px; }
  .hero-pill .ico { width: 34px; height: 34px; }
  .event-card { grid-template-columns: 1fr; }
  .event-date { flex-direction: row; gap: 10px; padding: 16px; }
  .event-date .d { font-size: 1.8rem; }
  .form-row { grid-template-columns: 1fr; }
  .impact-band { grid-template-columns: 1fr 1fr; }
  .footer-top { grid-template-columns: 1fr 1fr; gap: 24px 18px; }
  .footer-col--wide { grid-column: 1 / -1; }
  .footer-bottom { justify-content: flex-start; }
  .btn--lg { padding: 15px 26px; font-size: 1rem; }
  .cta-band { padding: 36px 22px; }
}
/* Narrow phones: stack the in-tile benefit chips for readability */
@media (max-width: 480px) {
  .tile .benefits-grid, .tile .benefits-grid[style] { grid-template-columns: 1fr !important; }
}
/* Small phones */
@media (max-width: 380px) {
  .hero-cta .btn { width: 100%; }
}
