/* Wokingham Energy Collective
   Colours are taken from the logo. Fonts are stored on our own site (no Google Fonts),
   so visitors are not tracked by third parties. */

@font-face {
  font-family: "Figtree";
  src: url("/assets/fonts/figtree.woff2") format("woff2-variations");
  font-weight: 300 900;
  font-display: swap;
}
@font-face {
  font-family: "Montserrat";
  src: url("/assets/fonts/montserrat.woff2") format("woff2-variations");
  font-weight: 100 900;
  font-display: swap;
}

:root {
  --green: #064b2f;
  --green-deep: #04361f;
  --leaf: #5a9832;
  --leaf-dark: #3d7420;
  --sun: #f6ad09;
  --sun-soft: #fff4d6;
  --mint: #ebf2e0;
  --mint-soft: #f5f8ef;
  --ink: #15241b;
  --muted: #45564b;
  --line: #d9e3cf;
  --input-border: #7d8f74;
  --white: #ffffff;

  --font-body: "Figtree", system-ui, -apple-system, "Segoe UI", Roboto, Arial, sans-serif;
  --font-head: "Montserrat", "Figtree", system-ui, sans-serif;

  --radius: 20px;
  --radius-small: 12px;
  --shadow: 0 1px 2px rgb(6 75 47 / 0.06), 0 8px 24px rgb(6 75 47 / 0.08);
  --container: 1180px;
  --gutter: 1rem;
}

*, *::before, *::after { box-sizing: border-box; }
[hidden] { display: none !important; }

html { -webkit-text-size-adjust: 100%; scroll-padding-top: 6rem; }
body {
  margin: 0;
  font-family: var(--font-body);
  font-size: 1.125rem;
  line-height: 1.65;
  color: var(--ink);
  background: var(--white);
  overflow-x: hidden;
}
img, svg, picture { max-width: 100%; height: auto; display: block; }
picture { display: contents; }

h1, h2, h3 {
  font-family: var(--font-head);
  color: var(--green);
  line-height: 1.2;
  letter-spacing: -0.01em;
  margin: 0 0 0.6em;
  text-wrap: balance;
}
h1 { font-size: clamp(2.1rem, 1.4rem + 3vw, 3.5rem); font-weight: 800; }
h2 { font-size: clamp(1.55rem, 1.2rem + 1.4vw, 2.15rem); font-weight: 700; }
h3 { font-size: 1.25rem; font-weight: 700; }
p { margin: 0 0 1em; }

a { color: var(--green); text-decoration-thickness: 2px; text-underline-offset: 3px; }
a:hover { color: var(--leaf-dark); }
:focus-visible { outline: 3px solid var(--sun); outline-offset: 3px; border-radius: 4px; }
main:focus { outline: none; }

.container { width: 100%; max-width: var(--container); margin-inline: auto; padding-inline: var(--gutter); }
.narrow > * { max-width: 780px; }
.narrow .grid, .narrow .gallery-grid { max-width: none; }
.small { font-size: 0.95rem; }
.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: 1rem; top: -4rem; z-index: 100;
  background: var(--green); color: var(--white); padding: 0.75rem 1.25rem; border-radius: var(--radius-small);
  font-weight: 700;
}
.skip-link:focus { top: 1rem; color: var(--white); }

/* ---------- Preview and draft labels ---------- */
.preview-bar {
  background: var(--sun-soft); color: #4a3200; text-align: center; font-size: 0.95rem;
  padding: 0.5rem var(--gutter); border-bottom: 1px solid #f0d58f;
}
.draft-badge {
  display: inline-block; vertical-align: middle; font-family: var(--font-body);
  font-size: 0.72rem; font-weight: 800; letter-spacing: 0.04em; text-transform: uppercase;
  color: #5c3d00; background: #fde7b0; border: 1px dashed #b07d00; border-radius: 6px; padding: 0.1rem 0.5rem;
}

.upcoming-badge {
  display: inline-block; vertical-align: middle; font-family: var(--font-body);
  font-size: 0.72rem; font-weight: 800; letter-spacing: 0.04em; text-transform: uppercase;
  color: var(--green-deep); background: var(--sun-soft); border: 1px solid var(--sun); border-radius: 6px; padding: 0.1rem 0.5rem;
}

/* ---------- Buttons ---------- */
.button {
  display: inline-flex; align-items: center; justify-content: center; gap: 0.5rem;
  min-height: 48px; padding: 0.7rem 1.4rem;
  font: 700 1.05rem/1.2 var(--font-body);
  color: var(--white); background: var(--green);
  border: 2px solid var(--green); border-radius: 999px;
  text-decoration: none; cursor: pointer;
  transition: background-color 0.15s, color 0.15s, border-color 0.15s, transform 0.15s;
}
.button:hover { background: var(--green-deep); border-color: var(--green-deep); color: var(--white); }
.button:active { transform: translateY(1px); }
.button:disabled { opacity: 0.7; cursor: progress; }
.button-large { min-height: 56px; padding: 0.9rem 1.7rem; font-size: 1.12rem; }
.button-outline { background: transparent; color: var(--green); }
.button-outline:hover { background: var(--green); color: var(--white); }
.button-sun { background: var(--sun); border-color: var(--sun); color: var(--green-deep); }
.button-sun:hover { background: #ffc23d; border-color: #ffc23d; color: var(--green-deep); }
.button-row { display: flex; flex-wrap: wrap; gap: 0.75rem; margin-top: 1.75rem; }

.link-arrow { font-weight: 700; text-decoration: none; white-space: nowrap; }
.link-arrow::after { content: " \2192"; }
.link-arrow:hover { text-decoration: underline; }
.link-back::after { content: none; }
.link-back::before { content: "\2190 "; }

/* ---------- Header and navigation ---------- */
.site-header {
  position: sticky; top: 0; z-index: 50;
  background: rgb(255 255 255 / 0.97);
  border-bottom: 1px solid var(--line);
  backdrop-filter: saturate(1.4) blur(6px);
}
.header-inner { display: flex; align-items: center; justify-content: space-between; gap: 1rem; min-height: 80px; }
.brand { display: flex; align-items: center; gap: 0.7rem; text-decoration: none; }
.brand img { width: 66px; height: auto; }
.brand-name { font: 800 1.02rem/1.15 var(--font-head); color: var(--green); letter-spacing: -0.01em; }
.brand-energy { color: var(--leaf); }

.site-nav ul { display: flex; align-items: center; gap: 0.15rem; list-style: none; margin: 0; padding: 0; }
.site-nav a:not(.button) {
  display: block; padding: 0.55rem 0.8rem; border-radius: 10px;
  font-weight: 600; color: var(--ink); text-decoration: none;
}
.site-nav a:not(.button):hover { background: var(--mint); color: var(--green); }
.site-nav a[aria-current="page"]:not(.button) { color: var(--green); box-shadow: inset 0 -3px 0 var(--leaf); border-radius: 10px 10px 0 0; }
.nav-cta { margin-left: 0.6rem; }

.menu-toggle {
  display: none; align-items: center; gap: 0.6rem; min-height: 48px; padding: 0.5rem 1rem;
  font: 700 1rem var(--font-body); color: var(--green);
  background: var(--mint); border: 0; border-radius: 999px; cursor: pointer;
}
.menu-toggle-bars, .menu-toggle-bars::before, .menu-toggle-bars::after {
  display: block; width: 20px; height: 2.5px; background: currentColor; border-radius: 2px; position: relative;
  transition: transform 0.2s;
}
.menu-toggle-bars::before, .menu-toggle-bars::after { content: ""; position: absolute; left: 0; }
.menu-toggle-bars::before { top: -6px; }
.menu-toggle-bars::after { top: 6px; }
.menu-toggle[aria-expanded="true"] .menu-toggle-bars { background: transparent; }
.menu-toggle[aria-expanded="true"] .menu-toggle-bars::before { transform: translateY(6px) rotate(45deg); }
.menu-toggle[aria-expanded="true"] .menu-toggle-bars::after { transform: translateY(-6px) rotate(-45deg); }

@media (max-width: 1099px) {
  .menu-toggle { display: inline-flex; }
  .site-nav {
    display: none; position: absolute; left: 0; right: 0; top: 100%;
    background: var(--white); border-bottom: 1px solid var(--line); box-shadow: var(--shadow);
    padding: 0.5rem var(--gutter) 1.25rem;
  }
  .site-nav.is-open { display: block; }
  .site-nav ul { flex-direction: column; align-items: stretch; gap: 0.15rem; }
  .site-nav a:not(.button) { padding: 0.85rem 0.75rem; font-size: 1.1rem; }
  .site-nav a[aria-current="page"]:not(.button) { box-shadow: inset 4px 0 0 var(--leaf); border-radius: 0 10px 10px 0; background: var(--mint-soft); }
  .nav-cta { margin: 0.75rem 0 0; }
  .nav-cta .button { width: 100%; }
}
@media (max-width: 420px) {
  .brand img { width: 52px; }
  .brand-name { font-size: 0.92rem; }
  .menu-toggle { padding: 0.5rem 0.9rem; }
  .menu-toggle-label { position: absolute; width: 1px; height: 1px; overflow: hidden; clip: rect(0 0 0 0); white-space: nowrap; }
}

/* ---------- Sections ---------- */
.section { padding-block: clamp(3rem, 2rem + 4vw, 5rem); }
.section-tight { padding-block: 0; margin-top: -2.5rem; position: relative; z-index: 3; }
.section-soft { background: var(--mint-soft); }
.section-dark { background: var(--green); color: #e9f1e4; }
.section-dark h2 { color: var(--white); }
.section-dark a:not(.button) { color: var(--sun); }
.section-title { margin-bottom: 1.25rem; }
.section-title-spaced { margin-top: 3rem; }
.section-head { display: flex; flex-wrap: wrap; align-items: baseline; justify-content: space-between; gap: 0.5rem 1.5rem; margin-bottom: 1.25rem; }
.section-head .section-title { margin: 0; }
.section-foot { margin-top: 2rem; }
.empty-note { color: var(--muted); }

.grid { display: grid; gap: 1.5rem; }
.grid-2 { grid-template-columns: repeat(2, minmax(0, 1fr)); }
.grid-3 { grid-template-columns: repeat(3, minmax(0, 1fr)); }
.grid-4 { grid-template-columns: repeat(4, minmax(0, 1fr)); }
.split { display: grid; grid-template-columns: minmax(0, 1.25fr) minmax(0, 1fr); gap: clamp(2rem, 4vw, 4rem); align-items: start; }

@media (max-width: 959px) {
  .grid-3, .grid-4 { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .split { grid-template-columns: 1fr; }
}
@media (max-width: 639px) {
  .grid-2, .grid-3, .grid-4 { grid-template-columns: 1fr; }
}

/* ---------- Home: hero ---------- */
.hero {
  background:
    radial-gradient(1200px 500px at 85% -10%, var(--sun-soft), transparent 60%),
    linear-gradient(180deg, var(--mint-soft), var(--white));
  padding-block: clamp(2.5rem, 2rem + 4vw, 5rem) clamp(4rem, 3rem + 4vw, 6.5rem);
}
.hero-grid { display: grid; grid-template-columns: minmax(0, 1.05fr) minmax(0, 1fr); gap: clamp(2rem, 5vw, 4.5rem); align-items: center; }
.eyebrow {
  display: inline-flex; align-items: flex-start; gap: 0.55rem;
  font-weight: 800; font-size: 0.9rem; letter-spacing: 0.08em; text-transform: uppercase; color: var(--leaf-dark);
  margin-bottom: 1rem;
}
.eyebrow::before { content: ""; flex: none; margin-top: 0.2em; width: 14px; height: 14px; border-radius: 50%; background: var(--sun); box-shadow: 0 0 0 4px rgb(246 173 9 / 0.25); }
.lead { font-size: clamp(1.15rem, 1.05rem + 0.5vw, 1.35rem); color: var(--muted); max-width: 38em; }
.hero .lead { color: var(--ink); }

.hero-visual { position: relative; padding: 1.5rem 1.5rem 0 0; }
.sun {
  position: absolute; top: -0.5rem; right: -0.5rem; width: clamp(110px, 16vw, 170px); aspect-ratio: 1; border-radius: 50%;
  background: radial-gradient(circle, var(--sun) 0 46%, transparent 47%),
    repeating-conic-gradient(from 0deg, rgb(246 173 9 / 0.9) 0deg 6deg, transparent 6deg 30deg);
  -webkit-mask: radial-gradient(circle, #000 0 46%, transparent 47% 56%, #000 57% 72%, transparent 73%);
          mask: radial-gradient(circle, #000 0 46%, transparent 47% 56%, #000 57% 72%, transparent 73%);
}
.hero-frame { position: relative; z-index: 1; border-radius: 28px; overflow: hidden; box-shadow: 0 20px 50px rgb(6 75 47 / 0.18); background: var(--mint); }
.hero-photo { width: 100%; aspect-ratio: 4 / 3; object-fit: cover; }
.hills { position: absolute; left: 0; right: 0; bottom: -1px; width: 100%; height: 18%; }

@media (max-width: 959px) {
  .hero-grid { grid-template-columns: 1fr; }
  .hero-visual { max-width: 640px; }
}

/* ---------- Events ---------- */
.next-event {
  display: grid; grid-template-columns: auto 1fr auto; align-items: center; gap: 1.25rem 1.75rem;
  background: var(--white); border: 1px solid var(--line); border-left: 8px solid var(--sun);
  border-radius: var(--radius); padding: 1.25rem 1.5rem; box-shadow: var(--shadow);
}
.next-event-label { font: 800 0.85rem var(--font-body); letter-spacing: 0.08em; text-transform: uppercase; color: var(--leaf-dark); margin: 0 0 0.15rem; }
.next-event-title { font: 700 1.35rem/1.3 var(--font-head); margin: 0 0 0.2rem; }
.next-event-title a { text-decoration: none; }
.next-event-title a:hover { text-decoration: underline; }
.event-when { margin: 0; color: var(--muted); }
@media (max-width: 719px) {
  .next-event { grid-template-columns: auto 1fr; }
  .next-event .button { grid-column: 1 / -1; }
}

.event-date {
  display: grid; place-items: center; width: 4.6rem; height: 4.6rem; margin: 0;
  background: var(--green); color: var(--white); border-radius: 16px; line-height: 1; text-align: center;
}
.event-day { display: block; font: 800 1.85rem var(--font-head); }
.event-month { display: block; font-weight: 800; font-size: 0.85rem; letter-spacing: 0.08em; text-transform: uppercase; color: var(--sun); margin-top: 0.2rem; }

.event-list { display: grid; gap: 1rem; }
.event-card {
  display: grid; grid-template-columns: auto 1fr; gap: 1.25rem; align-items: start;
  background: var(--white); border: 1px solid var(--line); border-radius: var(--radius); padding: 1.25rem;
}
.event-title { font-size: 1.3rem; margin: 0 0 0.25rem; }
.event-title a { text-decoration: none; }
.event-title a:hover { text-decoration: underline; }
.event-body p:last-child { margin-bottom: 0; }
.event-body .event-when { margin-bottom: 0.5rem; }
.event-list-past .event-date { background: var(--mint); color: var(--green); }
.event-list-past .event-month { color: var(--leaf-dark); }

.event-facts { display: grid; gap: 0; margin: 0 0 2rem; border-top: 1px solid var(--line); }
.event-facts div { display: grid; grid-template-columns: 7rem 1fr; gap: 1rem; padding: 0.85rem 0; border-bottom: 1px solid var(--line); }
.event-facts dt { font-weight: 800; color: var(--green); }
.event-facts dd { margin: 0; }

/* ---------- Features ---------- */
.feature { background: var(--white); border: 1px solid var(--line); border-radius: var(--radius); padding: 1.75rem; }
.feature h3 { margin-top: 1rem; }
.feature p { margin: 0; color: var(--muted); }
.feature-icon {
  display: block; width: 64px; height: 64px; border-radius: 18px; background-color: var(--mint);
  background-repeat: no-repeat; background-position: center; background-size: 34px;
}
.feature-icon-solar { background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='%23064B2F' stroke-width='1.7' stroke-linecap='round' stroke-linejoin='round'%3E%3Cpath d='M6 12h12l2.5 8h-17z'/%3E%3Cpath d='M10 12l-1 8M14 12l1 8M4.7 16h14.6'/%3E%3Ccircle cx='12' cy='5.5' r='2.2' fill='%23F6AD09' stroke='%23F6AD09'/%3E%3Cpath d='M12 1.2v.8M16.3 5.5h.9M6.8 5.5h.9M15 2.5l-.6.6M9 2.5l.6.6' stroke='%23F6AD09'/%3E%3C/svg%3E"); }
.feature-icon-community { background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='%23064B2F' stroke-width='1.7' stroke-linecap='round' stroke-linejoin='round'%3E%3Cpath d='M3 11l9-7 9 7'/%3E%3Cpath d='M5 9.5V20h14V9.5'/%3E%3Cpath d='M12 17.5c-2.6-1.6-3.6-3.1-3.6-4.4a1.8 1.8 0 0 1 3.6-.6 1.8 1.8 0 0 1 3.6.6c0 1.3-1 2.8-3.6 4.4z' fill='%235A9832' stroke='%235A9832'/%3E%3C/svg%3E"); }
.feature-icon-people { background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='%23064B2F' stroke-width='1.7' stroke-linecap='round' stroke-linejoin='round'%3E%3Ccircle cx='9' cy='8' r='3'/%3E%3Cpath d='M3 20c0-3.3 2.7-6 6-6s6 2.7 6 6'/%3E%3Ccircle cx='17' cy='9' r='2.4'/%3E%3Cpath d='M15.6 14.3A5 5 0 0 1 21 19.5'/%3E%3C/svg%3E"); }

/* ---------- Cards ---------- */
.card {
  position: relative; display: flex; flex-direction: column;
  background: var(--white); border: 1px solid var(--line); border-radius: var(--radius); overflow: hidden;
  transition: box-shadow 0.2s, transform 0.2s;
}
.card:hover { box-shadow: var(--shadow); transform: translateY(-2px); }
.card-media { display: block; position: relative; overflow: hidden; aspect-ratio: 16 / 10; background: var(--mint); }
.card-media img { position: absolute; inset: 0; width: 100%; height: 100%; object-fit: cover; }
.card-media-logo { background: var(--white); border-bottom: 1px solid var(--line); }
.card-media .card-logo { object-fit: contain; padding: 0.75rem; }
.card-placeholder {
  display: block; width: 100%; height: 100%;
  background:
    radial-gradient(circle at 72% 42%, var(--sun) 0 13%, transparent 13.5%),
    radial-gradient(140% 70% at 20% 115%, var(--green) 0 50%, transparent 50.5%),
    radial-gradient(120% 60% at 90% 120%, var(--leaf) 0 55%, transparent 55.5%),
    linear-gradient(180deg, var(--mint-soft), var(--mint));
}
.card-body { padding: 1.25rem 1.4rem 1.5rem; }
.card-body p:last-child { margin-bottom: 0; }
.card-meta { font-size: 0.95rem; color: var(--muted); margin-bottom: 0.4rem; }
.card-title { font-size: 1.25rem; margin-bottom: 0.5rem; }
.card-title a { text-decoration: none; }
.card-title a::after { content: ""; position: absolute; inset: 0; }
.card-title a:hover { text-decoration: underline; }
.card-title a:focus-visible { outline: none; }
.card:has(.card-title a:focus-visible) { outline: 3px solid var(--sun); outline-offset: 3px; }

.stat-card { background: var(--white); border: 1px solid var(--line); border-radius: var(--radius); padding: 1.6rem; }
.stat-card p:last-child { margin-bottom: 0; }
.stat-figure {
  font: 800 clamp(1.9rem, 1.5rem + 1.5vw, 2.5rem)/1.1 var(--font-head); color: var(--green); margin: 0 0 0.5rem;
  background: linear-gradient(transparent 70%, rgb(246 173 9 / 0.45) 70%); display: inline;
}
.stat-card .stat-figure { display: inline-block; }

/* ---------- Join band ---------- */
.join-grid { display: grid; grid-template-columns: minmax(0, 1fr) minmax(0, 1fr); gap: clamp(2rem, 5vw, 4.5rem); align-items: start; }
.join-grid > div:first-child { padding-top: 1rem; }
.join-grid p { font-size: 1.15rem; }
.join-grid .small { font-size: 0.95rem; color: #c8dcc0; }
.join-form { background: var(--white); color: var(--ink); border-radius: 24px; padding: clamp(1.5rem, 3vw, 2.25rem); }
.section-dark .join-form h2 { color: var(--green); }
.section-dark .join-form a:not(.button) { color: var(--green); }
.join-form p { font-size: 1.05rem; }
@media (max-width: 859px) { .join-grid { grid-template-columns: 1fr; } }

/* ---------- Forms ---------- */
.form { display: grid; gap: 1.1rem; margin-top: 1rem; }
.field label { display: block; font-weight: 700; margin-bottom: 0.35rem; }
.field input[type="text"], .field input[type="email"], .field textarea {
  width: 100%; padding: 0.8rem 1rem; font: inherit; color: var(--ink);
  background: var(--white); border: 2px solid var(--input-border); border-radius: var(--radius-small);
}
.field input:focus, .field textarea:focus { border-color: var(--green); outline: 3px solid var(--sun); outline-offset: 1px; }
.field textarea { resize: vertical; min-height: 9rem; }
.field-check { display: grid; grid-template-columns: auto 1fr; gap: 0.75rem; align-items: start; }
.field-check input { width: 1.5rem; height: 1.5rem; margin: 0.15rem 0 0; accent-color: var(--green); }
.field-check label { font-weight: 500; margin: 0; }
.form-note { font-size: 0.95rem; color: var(--muted); margin: 0; }
.form .button { justify-self: start; }
.form-status { margin: 0; font-weight: 600; }
.form-status:empty { display: none; }
.form-status.is-success { color: var(--green); background: var(--mint); padding: 0.85rem 1rem; border-radius: var(--radius-small); }
.form-status.is-error { color: #8a1c1c; background: #fdecec; padding: 0.85rem 1rem; border-radius: var(--radius-small); }
.botcheck { display: none; }

/* ---------- Inner pages ---------- */
.page-hero {
  background: linear-gradient(180deg, var(--mint-soft), var(--mint));
  padding-block: clamp(2.5rem, 2rem + 3vw, 4rem) clamp(2rem, 1.5rem + 2vw, 3rem);
  border-bottom: 4px solid var(--leaf);
}
.page-hero h1 { margin-bottom: 0.4rem; }
.page-hero .lead { margin-bottom: 0; }
.page-hero .card-meta a { font-weight: 700; }

.prose { max-width: 68ch; }
.prose h2 { font-size: 1.6rem; margin-top: 2.2rem; }
.prose h3 { font-size: 1.25rem; margin-top: 1.6rem; margin-bottom: 0.4rem; }
.prose ul, .prose ol { padding-left: 1.3rem; margin: 0 0 1.2em; }
.prose li { margin-bottom: 0.35rem; }
.prose li::marker { color: var(--leaf); }
.prose img { border-radius: var(--radius-small); margin-block: 1.5rem; }
.prose blockquote { margin: 1.5rem 0; padding: 0.25rem 0 0.25rem 1.25rem; border-left: 4px solid var(--sun); color: var(--muted); font-style: italic; }
.prose > :first-child { margin-top: 0; }

.photo-frame { margin: 0; }
.photo-frame img { width: 100%; border-radius: var(--radius); }
.photo-frame figcaption { font-size: 0.95rem; color: var(--muted); padding-top: 0.6rem; }
.article-image { margin-bottom: 2rem; }

.panel { background: var(--white); border: 1px solid var(--line); border-radius: 24px; padding: clamp(1.5rem, 3vw, 2.25rem); }
.panel-highlight { background: var(--mint-soft); border-color: var(--leaf); }
.panel h2 { font-size: 1.6rem; }
.involve-grid { align-items: start; }
.contact-list { list-style: none; padding: 0; margin: 1.5rem 0 0; display: grid; gap: 0.75rem; }
.contact-list li { display: grid; grid-template-columns: 6.5rem 1fr; gap: 0.75rem; overflow-wrap: anywhere; }
.contact-list span { font-weight: 800; color: var(--green); }

.person { text-align: center; }
.person-photo { width: 140px; height: 140px; border-radius: 50%; object-fit: cover; margin: 0 auto 1rem; }
.person-initial { display: grid; place-items: center; background: var(--mint); color: var(--green); font: 800 3rem var(--font-head); }
.person h3 { margin-bottom: 0.2rem; }
.person-role { color: var(--leaf-dark); font-weight: 700; margin-bottom: 0.5rem; }
.person p:last-child { color: var(--muted); }

.timeline { list-style: none; margin: 0; padding: 0; border-left: 3px solid var(--mint); }
.timeline-item { position: relative; padding: 0 0 2.5rem 2rem; }
.timeline-item::before {
  content: ""; position: absolute; left: -11px; top: 0.35rem; width: 19px; height: 19px; border-radius: 50%;
  background: var(--sun); box-shadow: 0 0 0 4px var(--white);
}
.timeline-item h2 { font-size: 1.5rem; margin-bottom: 0.5rem; }
.timeline-item .stat-figure { display: inline-block; margin-bottom: 1rem; }
.timeline-image { width: 100%; border-radius: var(--radius); margin-bottom: 1rem; }

.press-list { list-style: none; margin: 0; padding: 0; }
.press-item { padding: 1.5rem 0; border-bottom: 1px solid var(--line); }
.press-item:first-child { padding-top: 0; }
.press-title { font-size: 1.35rem; margin-bottom: 0.4rem; }
.press-item p:last-child { margin-bottom: 0; }

/* ---------- Gallery ---------- */
.gallery-grid { list-style: none; margin: 0 0 2rem; padding: 0; display: grid; grid-template-columns: repeat(auto-fill, minmax(260px, 1fr)); gap: 1.25rem; }
.gallery-grid figure { margin: 0; }
.gallery-open { display: block; width: 100%; padding: 0; border: 0; background: var(--mint); border-radius: var(--radius-small); overflow: hidden; cursor: zoom-in; }
.gallery-open img { width: 100%; aspect-ratio: 4 / 3; object-fit: cover; transition: transform 0.3s; }
.gallery-open:hover img { transform: scale(1.03); }
.gallery-grid figcaption { font-size: 0.95rem; color: var(--muted); padding-top: 0.5rem; }

.lightbox { width: min(1100px, 94vw); max-height: 94vh; padding: 0; border: 0; border-radius: var(--radius); background: #0c1a12; color: var(--white); }
.lightbox::backdrop { background: rgb(4 20 12 / 0.85); }
.lightbox-inner { padding: 1rem; }
.lightbox-image img { width: 100%; max-height: 72vh; object-fit: contain; border-radius: var(--radius-small); }
.lightbox-caption { margin: 0.75rem 0; min-height: 1.5em; }
.lightbox-controls { display: flex; flex-wrap: wrap; align-items: center; gap: 0.6rem; }
.lightbox-controls .button-outline { color: var(--white); border-color: rgb(255 255 255 / 0.6); }
.lightbox-controls .button-outline:hover { background: var(--white); color: var(--green); }
.lightbox-controls [data-lightbox="close"] { margin-left: auto; background: var(--sun); border-color: var(--sun); color: var(--green-deep); }
.lightbox-count { color: #c8dcc0; font-size: 0.95rem; }

/* ---------- Footer ---------- */
.site-footer { background: var(--mint); padding-top: clamp(2.5rem, 2rem + 3vw, 4rem); font-size: 1.02rem; }
.footer-grid { display: grid; grid-template-columns: minmax(0, 1.6fr) minmax(0, 1fr) minmax(0, 1fr); gap: 2.5rem; }
.footer-logo { width: 150px; height: auto; margin-bottom: 1rem; padding: 0.6rem; background: var(--white); border-radius: var(--radius); box-sizing: content-box; }
.footer-about p { max-width: 36ch; color: var(--muted); }
.footer-heading { font-size: 1.05rem; margin-bottom: 0.75rem; }
.footer-list { list-style: none; margin: 0; padding: 0; display: grid; gap: 0.45rem; }
.footer-list a { color: var(--ink); text-decoration: none; overflow-wrap: anywhere; }
.footer-list a:hover { color: var(--green); text-decoration: underline; }
.footer-bottom {
  display: flex; flex-wrap: wrap; justify-content: space-between; gap: 0.5rem 2rem;
  margin-top: 2.5rem; padding-block: 1.25rem; border-top: 1px solid #c9d8bb; font-size: 0.95rem; color: var(--muted);
}
.footer-bottom p { margin: 0; }
.footer-bottom a { color: var(--muted); }
@media (max-width: 799px) { .footer-grid { grid-template-columns: 1fr 1fr; } .footer-about { grid-column: 1 / -1; } }
@media (max-width: 479px) { .footer-grid { grid-template-columns: 1fr; } }

/* ---------- Accessibility preferences and printing ---------- */
@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after { transition: none !important; animation: none !important; scroll-behavior: auto !important; }
}
@media print {
  .site-header, .site-footer, .join-form, .form, .skip-link, .preview-bar { display: none !important; }
  .section-dark { background: none; color: var(--ink); }
}
