/* ============================================================
   Berkeley County Historical Society — site stylesheet
   Colors from brand guide:
     Big Stone  #193942  (ink / primary dark)
     Wheat      #f2d6ad  (paper / warm cream)
     Casablanca #fbaf5c  (accent — amber)
     Keppel     #42b6a0  (accent — teal)
   Type: Source Serif 4 (display + body, stands in for Freight Text Pro),
         Public Sans (utility: nav, labels, buttons, captions)
   ============================================================ */

@import url('https://fonts.googleapis.com/css2?family=Source+Serif+4:ital,opsz,wght@0,8..60,400;0,8..60,600;0,8..60,700;1,8..60,400&family=Public+Sans:wght@400;500;600;700&display=swap');

:root{
  --ink: #193942;
  --ink-90: #1e424c;
  --paper: #fbf3e3;      /* lightened wheat, easier on long reading */
  --wheat: #f2d6ad;
  --amber: #fbaf5c;
  --teal: #42b6a0;
  --ink-soft: #3d5a63;
  --max: 1180px;
  --serif: 'Source Serif 4', Georgia, 'Times New Roman', serif;
  --sans: 'Public Sans', -apple-system, Segoe UI, sans-serif;
}

*{ box-sizing: border-box; }
html{ scroll-behavior: smooth; }
body{
  margin:0;
  font-family: var(--serif);
  color: var(--ink);
  background: var(--paper);
  line-height: 1.65;
  font-size: 18px;
}
img{ max-width:100%; display:block; }
a{ color: var(--ink); }
h1,h2,h3,h4{
  font-family: var(--serif);
  font-weight: 700;
  line-height: 1.15;
  margin: 0 0 .5em;
  letter-spacing: -0.01em;
}
h1{ font-size: clamp(2.2rem, 5vw, 3.6rem); }
h2{ font-size: clamp(1.6rem, 3.4vw, 2.4rem); }
h3{ font-size: 1.3rem; }
.eyebrow{
  font-family: var(--sans);
  font-weight: 600;
  letter-spacing: .14em;
  text-transform: uppercase;
  font-size: .78rem;
  color: var(--teal);
}
p{ margin: 0 0 1em; }
.container{ max-width: var(--max); margin: 0 auto; padding: 0 28px; }
.visually-hidden{
  position:absolute; width:1px;height:1px; overflow:hidden;
  clip:rect(0,0,0,0); white-space:nowrap;
}

/* focus visibility */
a:focus-visible, button:focus-visible{
  outline: 3px solid var(--amber);
  outline-offset: 2px;
}

/* ---------- Header / Nav ---------- */
.site-header{
  background: var(--ink);
  color: var(--wheat);
  position: sticky; top:0; z-index: 50;
  border-bottom: 4px solid var(--teal);
}
.site-header .container{
  display:flex; align-items:center; justify-content: space-between;
  padding-top: 12px; padding-bottom: 12px;
  gap: 20px;
}
.brand{ display:flex; align-items:center; gap:12px; text-decoration:none; color: var(--wheat); }
.brand img{ height: 52px; width:auto; }
.brand-word{
  font-family: var(--serif);
  font-weight:700;
  font-size: 1.15rem;
  line-height:1.15;
  color: var(--wheat);
}
.brand-word small{
  display:block;
  font-family: var(--sans);
  font-weight:500;
  font-size:.62rem;
  letter-spacing:.16em;
  text-transform:uppercase;
  color: var(--teal);
  margin-top:2px;
}
nav.primary-nav{ display:flex; align-items:center; gap: 4px; }
nav.primary-nav a{
  font-family: var(--sans);
  font-weight:600;
  font-size:.92rem;
  color: var(--wheat);
  text-decoration:none;
  padding: 10px 14px;
  border-radius: 3px;
  transition: background .15s ease, color .15s ease;
}
nav.primary-nav a:hover{ background: rgba(66,182,160,.18); color:#fff; }
nav.primary-nav a.current{ color: var(--amber); }
.nav-toggle{ display:none; }

@media (max-width: 860px){
  .site-header .container{ flex-wrap:wrap; }
  nav.primary-nav{
    width:100%; flex-wrap:wrap; justify-content:flex-start;
    padding-top: 6px; display:none;
  }
  nav.primary-nav.open{ display:flex; }
  .nav-toggle{
    display:inline-flex; align-items:center; gap:6px;
    background:none; border:1px solid var(--teal); color:var(--wheat);
    font-family:var(--sans); font-weight:600; font-size:.85rem;
    padding:8px 12px; border-radius:3px; cursor:pointer;
  }
}

/* ---------- Buttons ---------- */
.btn{
  display:inline-block;
  font-family: var(--sans);
  font-weight:700;
  font-size:.92rem;
  letter-spacing:.02em;
  text-decoration:none;
  padding: 13px 26px;
  border-radius: 3px;
  border: 2px solid transparent;
  cursor:pointer;
  transition: transform .12s ease, box-shadow .12s ease;
}
.btn:hover{ transform: translateY(-1px); }
.btn-primary{ background: var(--amber); color: var(--ink); }
.btn-primary:hover{ box-shadow: 0 4px 0 0 var(--ink); }
.btn-outline{ background:transparent; border-color: currentColor; color:inherit; }
.btn-teal{ background: var(--teal); color:#fff; }
.btn-teal:hover{ box-shadow: 0 4px 0 0 var(--ink); }

/* ---------- Tulip border divider ---------- */
.tulip-divider{
  height: 26px;
  background-image: url('patterns/tulip-bigstone.png');
  background-repeat: repeat-x;
  background-size: auto 26px;
}
.tulip-divider.teal{ background-image: url('patterns/tulip-keppel.png'); }

/* ---------- Hero (home) ---------- */
.hero{
  position:relative;
  color: var(--wheat);
  background: linear-gradient(180deg, rgba(25,57,66,.55), rgba(25,57,66,.86)),
              url('photos/founding-members-1973.jpg') center 30%/cover no-repeat;
  padding: 96px 0 84px;
}
.hero .eyebrow{ color: var(--amber); }
.hero h1{ color:#fff; max-width: 16ch; }
.hero p.lede{ font-size:1.2rem; max-width: 46ch; color: var(--wheat); }
.hero-actions{ display:flex; gap:14px; flex-wrap:wrap; margin-top: 1.6em; }
.hero-caption{
  font-family: var(--sans); font-size:.78rem; color: var(--wheat);
  opacity:.75; margin-top: 2.2em; max-width: 46ch;
}

/* ---------- Page hero (interior pages) ---------- */
.page-hero{
  background: var(--ink);
  color: var(--wheat);
  padding: 56px 0 40px;
}
.page-hero h1{ color:#fff; }
.page-hero p{ max-width: 60ch; color: var(--wheat); opacity:.9; }

/* ---------- Sections ---------- */
section{ padding: 72px 0; }
section.tight{ padding: 48px 0; }
.section-alt{ background: var(--wheat); }
.section-ink{ background: var(--ink); color: var(--wheat); }
.section-ink h2{ color:#fff; }
.section-ink a{ color: var(--amber); }

.grid-2{ display:grid; grid-template-columns: 1.1fr .9fr; gap: 56px; align-items:center; }
.grid-3{ display:grid; grid-template-columns: repeat(3,1fr); gap: 32px; }
.grid-4{ display:grid; grid-template-columns: repeat(4,1fr); gap: 24px; }
@media (max-width: 860px){
  .grid-2, .grid-3, .grid-4{ grid-template-columns: 1fr; }
}

.card{
  background:#fff;
  border: 1px solid rgba(25,57,66,.12);
  border-radius: 4px;
  padding: 28px;
}
.card-photo{
  aspect-ratio: 4/3; object-fit:cover; border-radius:4px 4px 0 0;
}
.card-photo-wrap{ overflow:hidden; border-radius:4px 4px 0 0; }
.stat{
  font-family:var(--serif); font-weight:700; font-size:2.6rem; color: var(--ink);
  line-height:1;
}
.stat-label{ font-family:var(--sans); font-size:.82rem; color:var(--ink-soft); text-transform:uppercase; letter-spacing:.08em; }

.icon-badge{ width:54px; height:54px; margin-bottom: 14px; }

/* ---------- Founders strip ---------- */
.founders-strip{
  display:flex; align-items:center; gap:28px; flex-wrap:wrap;
  font-family: var(--sans);
}
.founders-strip img{ width:70px; height:70px; object-fit:cover; border-radius:50%; border:3px solid var(--amber); }

/* ---------- Timeline (about) ---------- */
.timeline{ border-left: 3px solid var(--teal); margin-left: 8px; }
.timeline .tl-item{ position:relative; padding: 0 0 40px 32px; }
.timeline .tl-item::before{
  content:''; position:absolute; left:-9px; top:4px;
  width:15px; height:15px; border-radius:50%;
  background: var(--amber); border:3px solid var(--ink);
}
.timeline .tl-year{ font-family:var(--sans); font-weight:700; color:var(--teal); letter-spacing:.05em; }

/* ---------- Event card ---------- */
.event-card{
  display:grid; grid-template-columns: 140px 1fr; gap: 24px;
  background:#fff; border:1px solid rgba(25,57,66,.12); border-radius:4px;
  padding: 24px; align-items:start;
}
.event-date{
  background: var(--ink); color:#fff; text-align:center; border-radius:4px; padding: 14px 6px;
  font-family: var(--sans);
}
.event-date .d{ font-size:2rem; font-weight:700; line-height:1; }
.event-date .m{ text-transform:uppercase; letter-spacing:.1em; font-size:.75rem; color: var(--amber); }
.event-date .y{ font-size:.8rem; opacity:.8; }
@media (max-width:600px){ .event-card{ grid-template-columns: 1fr; } }

.embed-frame{
  border: 1px solid rgba(25,57,66,.15);
  border-radius: 6px;
  overflow:hidden;
  background:#fff;
}

/* ---------- Map texture panel ---------- */
.map-panel{
  background: url('patterns/muted-map.png') center/cover no-repeat;
  position:relative;
}
.map-panel::before{
  content:''; position:absolute; inset:0; background: rgba(242,214,173,.72);
}
.map-panel .container{ position:relative; }

/* ---------- Footer ---------- */
footer.site-footer{
  background: var(--ink); color: var(--wheat); padding: 52px 0 28px;
}
footer.site-footer a{ color: var(--wheat); text-decoration:none; }
footer.site-footer a:hover{ color: var(--amber); }
.footer-grid{ display:grid; grid-template-columns: 1.3fr 1fr 1fr; gap: 40px; }
.footer-grid h4{ color: var(--amber); font-family:var(--sans); font-size:.85rem; letter-spacing:.08em; text-transform:uppercase; }
.footer-grid ul{ list-style:none; padding:0; margin:0; font-family:var(--sans); font-size:.92rem; }
.footer-grid li{ margin-bottom:8px; }
.footer-bottom{
  margin-top:40px; padding-top:20px; border-top:1px solid rgba(242,214,173,.2);
  font-family: var(--sans); font-size:.8rem; opacity:.75;
  display:flex; justify-content:space-between; flex-wrap:wrap; gap:10px;
}
@media (max-width:860px){ .footer-grid{ grid-template-columns: 1fr; } }

/* ---------- Utility ---------- */
.mt-0{margin-top:0} .mb-0{margin-bottom:0}
.center{ text-align:center; }
.small{ font-family: var(--sans); font-size:.85rem; color: var(--ink-soft); }
.callout{
  border-left: 4px solid var(--amber);
  background: #fff;
  padding: 20px 24px;
  border-radius: 0 4px 4px 0;
}
