/* ==========================================================================
   Mark Nagales for Supervisor — District 5 — One-page, photo-forward
   Design tokens: Bay Fog / Harbor Ink / Transit Blue / Sunrise Gold / Line Coral
   ========================================================================== */

:root {
  --bay-fog: #eef0ec;
  --bay-fog-dim: #e4e7e0;
  --harbor-ink: #16283d;
  --transit-blue: #2e5c8a;
  --transit-blue-deep: #234a70;
  --sunrise-gold: #e3a73c;
  --sunrise-gold-soft: #f0c986;
  --slate: #4b5560;
  --slate-light: #7c8792;
  --line-coral: #d65f45;
  --paper: #fbfaf6;
  --white: #ffffff;
  --border-hairline: rgba(22, 40, 61, 0.12);

  --font-display: "Fraunces", "Iowan Old Style", serif;
  --font-body: "Public Sans", -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif;
  --font-mono: "IBM Plex Mono", ui-monospace, monospace;

  --max-width: 1200px;
  --radius-sm: 4px;
  --radius-md: 12px;
}

* { box-sizing: border-box; }
html { scroll-behavior: smooth; }

@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }
  * { animation-duration: 0.001ms !important; animation-iteration-count: 1 !important; transition-duration: 0.001ms !important; }
}

body {
  margin: 0;
  font-family: var(--font-body);
  color: var(--harbor-ink);
  background: var(--bay-fog);
  -webkit-font-smoothing: antialiased;
  line-height: 1.55;
}

img { max-width: 100%; display: block; }
a { color: inherit; text-decoration: none; }
ul { margin: 0; padding: 0; list-style: none; }

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

.eyebrow {
  font-family: var(--font-mono);
  font-size: 0.72rem;
  letter-spacing: 0.16em;
  text-transform: uppercase;
  color: var(--transit-blue);
  display: inline-flex;
  align-items: center;
  gap: 10px;
  margin-bottom: 14px;
}
.eyebrow::before {
  content: "";
  width: 7px; height: 7px;
  border-radius: 50%;
  background: var(--sunrise-gold);
  display: inline-block;
}

h1, h2, h3, h4 {
  font-family: var(--font-display);
  font-weight: 600;
  line-height: 1.1;
  margin: 0 0 0.5em;
  color: var(--harbor-ink);
}
h2 { font-size: clamp(1.9rem, 3.4vw, 2.6rem); }
h3 { font-size: 1.25rem; }
p { margin: 0 0 1em; }
.lead { font-size: 1.1rem; color: var(--slate); }

.btn {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  font-family: var(--font-mono);
  font-size: 0.78rem;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  padding: 14px 26px;
  border-radius: var(--radius-sm);
  border: 1px solid transparent;
  cursor: pointer;
  transition: transform 0.15s ease, background 0.2s ease;
}
.btn:hover { transform: translateY(-1px); }
.btn:focus-visible { outline: 3px solid var(--sunrise-gold); outline-offset: 2px; }
.btn-primary { background: var(--line-coral); color: var(--white); box-shadow: 0 6px 18px rgba(214,95,69,0.28); }
.btn-primary:hover { background: #c14f37; }
.btn-ghost { background: transparent; border-color: rgba(22,40,61,0.25); color: var(--harbor-ink); }
.btn-ghost:hover { border-color: var(--harbor-ink); }
.btn-gold { background: var(--sunrise-gold); color: var(--harbor-ink); }
.btn-gold:hover { background: #d69827; }

.skip-link {
  position: absolute; left: -999px; top: auto;
  background: var(--harbor-ink); color: var(--white);
  padding: 12px 18px; z-index: 999;
  font-family: var(--font-mono); font-size: 0.85rem;
}
.skip-link:focus { left: 12px; top: 12px; }

/* ---------- Header ---------- */
.site-header {
  position: sticky; top: 0; z-index: 500;
  background: rgba(238,240,236,0.92);
  backdrop-filter: blur(10px);
  border-bottom: 1px solid var(--border-hairline);
}
.site-header .container {
  display: flex; align-items: center; justify-content: space-between;
  gap: 24px; padding-top: 14px; padding-bottom: 14px;
}
.logo { display: flex; flex-direction: column; line-height: 1; }
.logo .logo-name { font-family: var(--font-display); font-weight: 700; font-size: 1.3rem; color: var(--harbor-ink); }
.logo .logo-tag { font-family: var(--font-mono); font-size: 0.6rem; letter-spacing: 0.14em; text-transform: uppercase; color: var(--transit-blue); margin-top: 4px; }

.nav-primary { display: flex; align-items: center; gap: 32px; }
.nav-primary ul { display: flex; gap: 26px; }
.nav-primary a { font-size: 0.92rem; font-weight: 600; color: var(--harbor-ink); position: relative; padding: 4px 0; }
.nav-primary a::after { content: ""; position: absolute; left: 0; bottom: -2px; width: 0; height: 2px; background: var(--line-coral); transition: width 0.2s ease; }
.nav-primary a:hover::after { width: 100%; }

.header-actions { display: flex; align-items: center; gap: 16px; }
.nav-toggle { display: none; background: none; border: none; cursor: pointer; padding: 6px; }
.nav-toggle span { display: block; width: 24px; height: 2px; background: var(--harbor-ink); margin: 5px 0; }

/* ---------- Hero: photo-forward ---------- */
.hero {
  position: relative;
  padding: 56px 0 0;
  background: var(--paper);
}
.hero .container {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 40px;
  align-items: center;
}
.hero-copy h1 { font-size: clamp(2.2rem, 4.4vw, 3.4rem); margin-bottom: 0.3em; }
.hero-copy .lead { max-width: 42ch; margin-bottom: 1.6em; }
.hero-cta { display: flex; flex-wrap: wrap; gap: 14px; }

.photo-card {
  position: relative;
  border-radius: var(--radius-md);
  overflow: hidden;
  background: linear-gradient(155deg, var(--transit-blue) 0%, var(--harbor-ink) 100%);
  display: flex;
  align-items: flex-end;
  isolation: isolate;
}
.photo-card::after {
  content: "";
  position: absolute; inset: 0;
  background: radial-gradient(circle at 25% 15%, rgba(227,167,60,0.32), transparent 45%);
  z-index: -1;
}
.photo-card .cap {
  font-family: var(--font-mono);
  font-size: 0.68rem;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  color: rgba(255,255,255,0.9);
  background: rgba(22,40,61,0.55);
  padding: 9px 13px;
  border-radius: var(--radius-sm);
  margin: 18px;
}

.hero-photo { aspect-ratio: 4/5; }

/* Full-bleed photo strip / gallery */
.photo-strip {
  padding: 40px 0;
}
.photo-strip .container {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 16px;
}
.photo-strip .photo-card { aspect-ratio: 1/1; }
.photo-strip .photo-card:nth-child(1) { background: linear-gradient(155deg,#2e5c8a,#16283d); }
.photo-strip .photo-card:nth-child(2) { background: linear-gradient(155deg,#e3a73c,#c17f22); }
.photo-strip .photo-card:nth-child(3) { background: linear-gradient(155deg,#d65f45,#8f3b28); }
.photo-strip .photo-card:nth-child(4) { background: linear-gradient(155deg,#4b5560,#16283d); }

/* ---------- Section shell ---------- */
.section { padding: 72px 0; }
.section-tight { padding: 48px 0; }
.section-header { max-width: 620px; margin: 0 auto 40px; text-align: center; }
.section-header.align-left { margin-left: 0; text-align: left; }
.bg-paper { background: var(--paper); }
.bg-fog { background: var(--bay-fog); }
.bg-ink { background: var(--harbor-ink); color: var(--bay-fog); }
.bg-ink h2, .bg-ink h3 { color: var(--white); }
.bg-ink .eyebrow { color: var(--sunrise-gold-soft); }
.bg-ink .eyebrow::before { background: var(--sunrise-gold); }

/* ---------- Meet Mark: big photo + short copy ---------- */
.meet-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 48px;
  align-items: center;
}
.meet-photo { aspect-ratio: 4/5; }
.meet-copy h3 { font-size: 1.5rem; }
.stat-strip {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 16px;
  margin-top: 24px;
  padding-top: 24px;
  border-top: 1px solid var(--border-hairline);
}
.stat-strip .num { font-family: var(--font-display); font-size: 1.6rem; color: var(--transit-blue-deep); display: block; }
.stat-strip .label { font-size: 0.78rem; color: var(--slate); }

/* ---------- Priorities: icon tiles, minimal text ---------- */
.tile-grid {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 20px;
}
.tile {
  background: var(--white);
  border: 1px solid var(--border-hairline);
  border-radius: var(--radius-md);
  padding: 26px 20px;
  text-align: center;
}
.tile .icon-wrap {
  width: 52px; height: 52px;
  border-radius: 50%;
  background: var(--bay-fog-dim);
  display: flex; align-items: center; justify-content: center;
  margin: 0 auto 14px;
}
.tile .icon-wrap svg { width: 24px; height: 24px; fill: var(--transit-blue-deep); }
.tile h3 { font-size: 1rem; margin-bottom: 4px; }
.tile p { font-size: 0.85rem; color: var(--slate); margin: 0; }

/* ---------- Record: photo + stat cards mixed ---------- */
.record-grid {
  display: grid;
  grid-template-columns: 1.1fr 0.9fr;
  gap: 20px;
}
.record-photo { border-radius: var(--radius-md); overflow: hidden; }
.record-stats {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 16px;
}
.record-stats .stat-card {
  background: var(--white);
  border: 1px solid var(--border-hairline);
  border-radius: var(--radius-md);
  padding: 22px;
  display: flex;
  flex-direction: column;
  justify-content: center;
}
.record-stats .stat-card .num { font-family: var(--font-display); font-size: 2rem; color: var(--transit-blue-deep); }
.record-stats .stat-card .label { font-size: 0.82rem; color: var(--slate); }

/* ---------- Testimonials: photo avatars ---------- */
.testimonial-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 24px;
}
.testimonial-card {
  background: var(--paper);
  border: 1px solid var(--border-hairline);
  border-radius: var(--radius-md);
  padding: 24px;
  display: flex;
  flex-direction: column;
  gap: 14px;
}
.testimonial-quote { font-family: var(--font-display); font-size: 1rem; line-height: 1.5; color: var(--harbor-ink); flex-grow: 1; }
.testimonial-person { display: flex; align-items: center; gap: 12px; }
.avatar {
  width: 44px; height: 44px; border-radius: 50%;
  background: var(--transit-blue); color: var(--white);
  display: flex; align-items: center; justify-content: center;
  font-family: var(--font-mono); font-weight: 700; font-size: 0.8rem;
  flex-shrink: 0;
}
.testimonial-person .name { font-weight: 700; font-size: 0.9rem; }
.testimonial-person .role { font-size: 0.78rem; color: var(--slate-light); }

/* ---------- Gallery band ---------- */
.gallery-band .container {
  display: grid;
  grid-template-columns: repeat(6, 1fr);
  grid-template-rows: 140px 140px;
  gap: 12px;
}
.gallery-band .photo-card:nth-child(1) { grid-column: span 2; grid-row: span 2; }
.gallery-band .photo-card:nth-child(2) { grid-column: span 2; }
.gallery-band .photo-card:nth-child(3) { grid-column: span 2; }
.gallery-band .photo-card:nth-child(4) { grid-column: span 2; }
.gallery-band .photo-card:nth-child(5) { grid-column: span 2; grid-row: span 1; }

.gallery-band .photo-card:nth-child(1) { background: linear-gradient(155deg,#2e5c8a,#16283d); }
.gallery-band .photo-card:nth-child(2) { background: linear-gradient(155deg,#e3a73c,#c17f22); }
.gallery-band .photo-card:nth-child(3) { background: linear-gradient(155deg,#d65f45,#8f3b28); }
.gallery-band .photo-card:nth-child(4) { background: linear-gradient(155deg,#4b5560,#16283d); }
.gallery-band .photo-card:nth-child(5) { background: linear-gradient(155deg,#2e5c8a,#8f3b28); }

/* ---------- Join + Contact combined ---------- */
.join-section {
  background: var(--transit-blue);
  color: var(--white);
  position: relative;
  overflow: hidden;
}
.join-section::before {
  content: "";
  position: absolute; inset: 0;
  background: radial-gradient(circle at 85% 20%, rgba(227,167,60,0.22), transparent 55%);
  pointer-events: none;
}
.join-grid { display: grid; grid-template-columns: 1fr 1fr; gap: 48px; align-items: center; position: relative; }
.join-copy h2 { color: var(--white); }
.join-copy p { color: rgba(255,255,255,0.82); max-width: 42ch; }

.social-inline { display: flex; gap: 12px; margin-top: 18px; }
.social-inline a {
  width: 40px; height: 40px; border-radius: 50%;
  border: 1px solid rgba(255,255,255,0.35);
  display: flex; align-items: center; justify-content: center;
  transition: background 0.2s ease, border-color 0.2s ease;
}
.social-inline a:hover { background: rgba(255,255,255,0.12); border-color: var(--white); }
.social-inline svg { width: 17px; height: 17px; fill: var(--white); }

.signup-form {
  background: var(--white);
  color: var(--harbor-ink);
  border-radius: var(--radius-md);
  padding: 30px;
  box-shadow: 0 24px 60px rgba(10,20,32,0.28);
}
.signup-form .form-row { display: grid; grid-template-columns: 1fr 1fr; gap: 14px; }
.signup-form label {
  font-family: var(--font-mono); font-size: 0.66rem; letter-spacing: 0.08em;
  text-transform: uppercase; color: var(--slate); display: block; margin-bottom: 6px;
}
.signup-form .field { margin-bottom: 14px; }
.signup-form input {
  width: 100%; padding: 12px 14px; border: 1px solid var(--border-hairline);
  border-radius: var(--radius-sm); font-family: var(--font-body); font-size: 0.94rem;
  background: var(--bay-fog-dim);
}
.signup-form input:focus-visible { outline: 2px solid var(--transit-blue); outline-offset: 1px; }
.signup-form .btn { width: 100%; justify-content: center; margin-top: 4px; }
.form-fineprint { font-size: 0.72rem; color: var(--slate-light); margin-top: 10px; margin-bottom: 0; }
.form-success {
  display: none; background: #eef7ee; border: 1px solid #b9dcb9; color: #2c5c2c;
  padding: 12px 14px; border-radius: var(--radius-sm); font-size: 0.9rem;
}
.form-success.is-visible { display: block; }

/* ---------- Contribute band ---------- */
.contribute-band {
  background: var(--harbor-ink);
  color: var(--white);
  text-align: center;
  padding: 68px 0;
  position: relative;
  overflow: hidden;
}
.contribute-band::before {
  content: "";
  position: absolute; inset: 0;
  background: radial-gradient(circle at 20% 30%, rgba(46,92,138,0.5), transparent 55%),
              radial-gradient(circle at 80% 75%, rgba(227,167,60,0.18), transparent 50%);
}
.contribute-band .container { position: relative; }
.contribute-band h2 { color: var(--white); max-width: 20ch; margin-left: auto; margin-right: auto; }
.contribute-band p { color: rgba(255,255,255,0.78); max-width: 50ch; margin-left: auto; margin-right: auto; }

/* ---------- Footer ---------- */
.site-footer { background: var(--paper); border-top: 1px solid var(--border-hairline); padding: 48px 0 24px; }
.footer-top { display: grid; grid-template-columns: 1.2fr 1fr 1fr; gap: 40px; padding-bottom: 32px; border-bottom: 1px solid var(--border-hairline); }
.footer-brand .logo-name { font-size: 1.2rem; }
.footer-brand p { color: var(--slate); max-width: 34ch; margin-top: 12px; font-size: 0.88rem; }
.footer-col h4 { font-family: var(--font-mono); font-size: 0.7rem; letter-spacing: 0.1em; text-transform: uppercase; color: var(--slate); margin-bottom: 14px; }
.footer-col ul li { margin-bottom: 8px; }
.footer-col a { font-size: 0.9rem; color: var(--harbor-ink); }
.footer-col a:hover { color: var(--transit-blue); }
.footer-bottom { display: flex; justify-content: space-between; align-items: center; flex-wrap: wrap; gap: 12px; padding-top: 20px; }
.footer-legal { font-size: 0.74rem; color: var(--slate-light); max-width: 62ch; }
.footer-legal a { color: var(--slate); text-decoration: underline; }

/* ---------- Utility ---------- */
.text-center { text-align: center; }

/* ---------- Responsive ---------- */
@media (max-width: 980px) {
  .hero .container { grid-template-columns: 1fr; }
  .meet-grid { grid-template-columns: 1fr; }
  .meet-photo { max-width: 420px; }
  .join-grid { grid-template-columns: 1fr; }
  .tile-grid { grid-template-columns: repeat(2, 1fr); }
  .photo-strip .container { grid-template-columns: repeat(2, 1fr); }
  .testimonial-grid { grid-template-columns: 1fr; }
  .record-grid { grid-template-columns: 1fr; }
  .footer-top { grid-template-columns: 1fr 1fr; }
  .gallery-band .container { grid-template-columns: repeat(2, 1fr); grid-template-rows: auto; }
  .gallery-band .photo-card:nth-child(1) { grid-column: span 2; }
  .gallery-band .photo-card { grid-row: auto !important; aspect-ratio: 4/3; }
}

@media (max-width: 760px) {
  .nav-primary {
    position: fixed; inset: 68px 0 0 0;
    background: var(--bay-fog);
    flex-direction: column; align-items: flex-start;
    padding: 32px 28px;
    transform: translateX(100%);
    transition: transform 0.25s ease;
    overflow-y: auto;
  }
  .nav-primary.is-open { transform: translateX(0); }
  .nav-primary ul { flex-direction: column; gap: 4px; width: 100%; }
  .nav-primary ul li a { display: block; padding: 14px 4px; font-size: 1.1rem; border-bottom: 1px solid var(--border-hairline); }
  .nav-primary .header-donate { margin-top: 20px; }
  .nav-toggle { display: block; }
  .header-actions .btn-primary.header-donate-desktop { display: none; }
  .signup-form .form-row { grid-template-columns: 1fr; }
  .footer-top { grid-template-columns: 1fr; }
  .footer-bottom { flex-direction: column; align-items: flex-start; }
  .tile-grid { grid-template-columns: 1fr 1fr; }
}
