/* Graylands Campus Project — community site
   Design system: civic dossier / evidence-file aesthetic.
   Ink navy + stone paper, brick accent for calls to action,
   verified-green for sourced claims, mono face for citations. */

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

:root {
  --ink: #1b2a38;
  --slate: #57626c;
  --paper: #efede4;
  --panel: #ffffff;
  --brick: #9c4630;
  --brick-tint: #f3e6e1;
  --verified: #3e6650;
  --verified-tint: #e4ebe4;
  --hairline: #d9d4c6;
  --max: 780px;
  --wide: 1080px;
}

* { box-sizing: border-box; }

html { scroll-behavior: smooth; }

body {
  margin: 0;
  background: var(--paper);
  color: var(--ink);
  font-family: 'IBM Plex Sans', -apple-system, sans-serif;
  font-size: 17px;
  line-height: 1.65;
  -webkit-font-smoothing: antialiased;
}

h1, h2, h3, h4 {
  font-family: 'Source Serif 4', Georgia, serif;
  font-weight: 600;
  line-height: 1.2;
  color: var(--ink);
  margin: 0 0 0.5em;
}

h1 { font-size: clamp(2rem, 4vw, 2.9rem); font-weight: 700; }
h2 { font-size: clamp(1.5rem, 3vw, 1.9rem); margin-top: 2.4em; }
h3 { font-size: 1.25rem; margin-top: 1.8em; }

p { margin: 0 0 1.1em; color: var(--ink); }
p.lede { font-size: 1.15rem; color: var(--slate); }

a { color: var(--brick); text-decoration-thickness: 1px; text-underline-offset: 2px; }
a:hover { text-decoration-thickness: 2px; }

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

/* ---------- Nav ---------- */
header.site-nav {
  position: sticky; top: 0; z-index: 50;
  background: rgba(239,237,228,0.94);
  backdrop-filter: blur(6px);
  border-bottom: 1px solid var(--hairline);
}
.nav-inner {
  max-width: var(--wide); margin: 0 auto; padding: 14px 24px;
  display: flex; align-items: center; justify-content: space-between; gap: 16px;
}
.brand { display: flex; align-items: center; gap: 10px; text-decoration: none; }
.brand svg { flex-shrink: 0; }
.brand-text { font-family: 'Source Serif 4', serif; font-weight: 600; font-size: 1.05rem; color: var(--ink); line-height: 1.15; }
.brand-text span { display: block; font-family: 'IBM Plex Mono', monospace; font-size: 0.65rem; font-weight: 500; letter-spacing: 0.08em; color: var(--slate); text-transform: uppercase; }

nav.links { display: flex; gap: 4px; flex-wrap: wrap; }
nav.links a {
  font-size: 0.92rem; font-weight: 500; color: var(--ink); text-decoration: none;
  padding: 8px 12px; border-radius: 4px; border-bottom: 2px solid transparent;
}
nav.links a:hover { border-bottom-color: var(--hairline); }
nav.links a.active { border-bottom-color: var(--brick); color: var(--brick); }

.nav-toggle { display: none; background: none; border: 1px solid var(--hairline); border-radius: 4px; padding: 8px 10px; cursor: pointer; }
.nav-toggle span { display: block; width: 20px; height: 2px; background: var(--ink); margin: 4px 0; }

/* Petition CTA pinned in the nav — deliberately distinct from the plain text links */
nav.links a.nav-petition {
  background: var(--brick); color: #fff; padding: 8px 16px; margin-left: 4px;
  border-radius: 5px; border-bottom: none; font-weight: 600;
}
nav.links a.nav-petition:hover { background: #833a28; border-bottom-color: transparent; }

.nav-cta-group { display: flex; align-items: center; gap: 6px; }
nav.links a.nav-register {
  font-family: 'IBM Plex Mono', monospace; font-size: 0.78rem; font-weight: 600;
  color: var(--brick); border: 1px solid var(--brick); border-bottom: 1px solid var(--brick);
  padding: 7px 10px; border-radius: 5px; white-space: nowrap;
}
nav.links a.nav-register:hover { background: var(--brick-tint); border-bottom-color: var(--brick); }

@media (max-width: 820px) {
  .nav-toggle { display: block; }
  nav.links {
    display: none; flex-direction: column; width: 100%;
    position: absolute; top: 100%; left: 0; background: var(--paper);
    border-bottom: 1px solid var(--hairline); padding: 8px 24px 16px;
  }
  nav.links.open { display: flex; }
  nav.links a { padding: 12px 4px; border-bottom: 1px solid var(--hairline); border-radius: 0; }
  nav.links a.nav-petition { margin: 8px 0 0; text-align: center; }
  .nav-cta-group { flex-direction: column; align-items: stretch; gap: 8px; }
  nav.links a.nav-register { text-align: center; margin: 0; border-bottom: 1px solid var(--brick); }
}

/* ---------- Hero ---------- */
.hero { padding: 56px 0 40px; }
.hero .eyebrow { font-family: 'IBM Plex Mono', monospace; font-size: 0.8rem; letter-spacing: 0.08em; text-transform: uppercase; color: var(--brick); margin-bottom: 14px; display: block; }
.hero .eyebrow.strapline {
  font-family: 'Source Serif 4', Georgia, serif; font-size: clamp(1.15rem, 2.6vw, 1.55rem);
  font-weight: 700; letter-spacing: 0; text-transform: none; color: var(--brick);
  margin-bottom: 18px; line-height: 1.3;
}
.hero h1 { max-width: 15ch; }
.hero .sub { font-size: 1.2rem; color: var(--slate); max-width: 52ch; margin-top: 0.6em; }

.hero-photo { margin: 0 0 28px; }
.hero-photo img { width: 100%; height: auto; border-radius: 10px; border: 1px solid var(--hairline); display: block; }
.hero-photo figcaption { font-size: 0.82rem; color: var(--slate); margin-top: 8px; font-style: italic; }

.hero-diagram { margin: 32px 0; }
.diagram text { font-family: 'IBM Plex Sans', sans-serif; fill: var(--ink); }
.diagram .mono { font-family: 'IBM Plex Mono', monospace; }
.diagram .accent { fill: var(--brick); }
.diagram .muted { fill: var(--slate); font-size: 12px; }
.diagram .box { fill: var(--panel); stroke: var(--ink); stroke-width: 1.4; }
.diagram .stage1 { fill: none; stroke: var(--brick); stroke-width: 1.4; stroke-dasharray: 4 3; }
.diagram .measure { stroke: var(--slate); stroke-width: 1; stroke-dasharray: 3 3; fill: none; }
.diagram .tick { stroke: var(--slate); stroke-width: 1; }

.cta-row { display: flex; gap: 12px; flex-wrap: wrap; margin-top: 16px; }
.cta-lead { font-size: 1.05rem; font-weight: 600; margin: 22px 0 0; color: var(--ink); }
.privacy-note ul { margin: 10px 0 0; padding-left: 20px; }
.privacy-note li { margin-bottom: 8px; font-size: 0.94rem; }
.privacy-note li:last-child { margin-bottom: 0; }
.btn {
  display: inline-flex; align-items: center; gap: 8px;
  font-family: 'IBM Plex Sans', sans-serif; font-weight: 600; font-size: 0.95rem;
  padding: 12px 20px; border-radius: 6px; text-decoration: none; border: 1px solid transparent;
  cursor: pointer;
}
.btn-primary { background: var(--brick); color: #fff; }
.btn-primary:hover { background: #833a28; }
.btn-secondary { background: transparent; color: var(--ink); border-color: var(--ink); }
.btn-secondary:hover { background: var(--ink); color: var(--paper); }
.btn-register { background: transparent; color: var(--brick); border-color: var(--brick); }
.btn-register:hover { background: var(--brick); color: #fff; }
.btn-shout {
  font-size: 1.05rem; padding: 15px 28px; box-shadow: 0 3px 0 #6f331f;
}
.btn-shout:hover { box-shadow: 0 2px 0 #6f331f; transform: translateY(1px); }
.cta-row-tertiary { margin-top: 10px; }
.snapshot-cta { display: flex; gap: 12px; flex-wrap: wrap; }
.petition-strip-actions { display: flex; gap: 10px; flex-wrap: wrap; flex-shrink: 0; }

/* ---------- Non-partisan banner ---------- */
.banner {
  background: var(--verified-tint); border: 1px solid var(--verified);
  border-radius: 8px; padding: 20px 24px; margin: 28px 0;
}
.banner p { margin: 0; color: #274435; font-weight: 500; }
.banner .label { font-family: 'IBM Plex Mono', monospace; font-size: 0.72rem; letter-spacing: 0.08em; text-transform: uppercase; color: var(--verified); display: block; margin-bottom: 8px; }

/* ---------- 60-second snapshot ---------- */
.snapshot { padding: 4px 0 8px; }
.snapshot-box {
  background: var(--panel); border: 1.5px solid var(--ink); border-radius: 12px;
  padding: 28px 30px; position: relative;
}
.snapshot-tag {
  display: inline-block; font-family: 'IBM Plex Mono', monospace; font-size: 0.78rem;
  font-weight: 600; letter-spacing: 0.06em; text-transform: uppercase; color: #fff;
  background: var(--ink); padding: 5px 10px; border-radius: 4px; margin-bottom: 16px;
}
.snapshot-box ul { margin: 0 0 22px; padding-left: 22px; }
.snapshot-box li { margin-bottom: 10px; font-size: 1.02rem; }
.snapshot-box li:last-child { margin-bottom: 0; }

/* ---------- Stat cards ---------- */
.stat-row { display: grid; grid-template-columns: repeat(3, 1fr); gap: 14px; margin: 32px 0; }
.stat-card { background: var(--panel); border: 1px solid var(--hairline); border-radius: 8px; padding: 20px; }
.stat-card .num { font-family: 'IBM Plex Mono', monospace; font-size: 1.6rem; font-weight: 500; color: var(--brick); display: block; }
.stat-card .label { font-size: 0.88rem; color: var(--slate); margin-top: 4px; display: block; }
@media (max-width: 700px) { .stat-row { grid-template-columns: 1fr; } }

/* ---------- Sections / cards ---------- */
section { padding: 8px 0 32px; }
.hairline { border: none; border-top: 1px solid var(--hairline); margin: 40px 0; }

.card { background: var(--panel); border: 1px solid var(--hairline); border-radius: 10px; padding: 24px; margin-bottom: 16px; }

.action-pair { display: grid; grid-template-columns: 1fr 1fr; gap: 16px; margin: 8px 0 16px; }
@media (max-width: 700px) { .action-pair { grid-template-columns: 1fr; } }
.action-card { margin-bottom: 0; display: flex; flex-direction: column; }
.action-card h3 { margin: 8px 0 8px; }
.action-card p { flex-grow: 1; }
.action-card .btn { align-self: flex-start; margin-top: 4px; }
.action-card-register { border-color: var(--brick); }
.verified-tag-register { color: var(--brick); background: var(--brick-tint); }

.cc-more {
  display: inline-flex; align-items: center; gap: 4px;
  font-family: 'IBM Plex Mono', monospace; font-size: 0.82rem; font-weight: 600;
  color: var(--brick); text-decoration: none;
}
.cc-more:hover { text-decoration: underline; }

.concern-full { padding: 28px 0 36px; border-top: 1px solid var(--hairline); }
.concern-full:first-of-type { border-top: none; }
.concern-full .eyebrow { font-family: 'IBM Plex Mono', monospace; font-size: 0.78rem; letter-spacing: 0.06em; text-transform: uppercase; color: var(--brick); }

/* ---------- Expandable concern cards (skim layer, full detail on open) ---------- */
.concern-expand-grid { display: grid; grid-template-columns: repeat(2, 1fr); gap: 14px; margin: 28px 0; }
@media (max-width: 700px) { .concern-expand-grid { grid-template-columns: 1fr; } }

details.concern-card-expand {
  background: var(--panel); border: 1px solid var(--hairline); border-radius: 10px;
  padding: 4px 22px; align-self: start;
}
details.concern-card-expand[open] { grid-column: 1 / -1; border-color: var(--brick); }

details.concern-card-expand summary {
  cursor: pointer; list-style: none; padding: 18px 34px 18px 0; position: relative;
}
details.concern-card-expand summary::-webkit-details-marker { display: none; }
details.concern-card-expand summary::after {
  content: '+'; position: absolute; right: 0; top: 14px; font-size: 1.5rem; line-height: 1;
  color: var(--brick); font-weight: 400;
}
details.concern-card-expand[open] summary::after { content: '\2212'; }

.cc-num {
  font-family: 'IBM Plex Mono', monospace; font-size: 0.76rem; color: var(--brick);
  font-weight: 600; display: block; margin-bottom: 4px;
}
.cc-tag {
  display: inline-block; font-family: 'IBM Plex Mono', monospace; font-size: 0.7rem; font-weight: 600;
  letter-spacing: 0.04em; text-transform: uppercase; color: #7a3625; background: var(--brick-tint);
  border-radius: 4px; padding: 2px 8px; margin-bottom: 6px;
}
.cc-title { display: block; font-family: 'Source Serif 4', serif; font-weight: 600; font-size: 1.08rem; color: var(--ink); line-height: 1.3; }

/* Minimal header variant used on the homepage — just a number and a short tag when collapsed */
.cc-row { display: flex; align-items: center; gap: 12px; }
.cc-num-mini {
  flex-shrink: 0; width: 26px; height: 26px; margin-top: 1px; border-radius: 50%;
  background: var(--brick-tint); color: var(--brick); font-family: 'IBM Plex Mono', monospace;
  font-weight: 600; font-size: 0.85rem; display: flex; align-items: center; justify-content: center;
}
.cc-tag-mini { font-family: 'Source Serif 4', serif; font-weight: 600; font-size: 1.02rem; color: var(--ink); }
.cc-full-title {
  font-family: 'Source Serif 4', serif; font-weight: 600; font-size: 1.1rem; color: var(--ink);
  margin: 0 0 10px !important; line-height: 1.3;
}
.concern-card-expand .cc-body { padding-bottom: 22px; }
.concern-card-expand .cc-body p:last-child { margin-bottom: 0; }

/* ---------- Mobile-only persistent petition bar (injected by script.js) ---------- */
.mobile-petition-bar {
  display: none; position: fixed; left: 0; right: 0; bottom: 0; z-index: 60;
  background: var(--ink); padding: 10px 12px; box-shadow: 0 -2px 10px rgba(0,0,0,0.15);
  gap: 8px; align-items: stretch;
}
.mobile-petition-bar .mpb-primary {
  flex: 1; text-align: center; background: var(--brick); color: #fff;
  font-family: 'IBM Plex Sans', sans-serif; font-weight: 600; font-size: 0.98rem;
  padding: 13px; border-radius: 7px; text-decoration: none;
}
.mobile-petition-bar .mpb-register {
  flex-shrink: 0; display: flex; align-items: center; justify-content: center;
  text-align: center; background: transparent; color: #f2c4b3; border: 1px solid #e8a893;
  font-family: 'IBM Plex Mono', monospace; font-weight: 600; font-size: 0.76rem;
  padding: 6px 10px; border-radius: 7px; text-decoration: none; white-space: nowrap;
}
@media (max-width: 820px) {
  .mobile-petition-bar { display: flex; }
  body { padding-bottom: 68px; }
}

/* ---------- Citation chip: the site's signature device ---------- */
.cite {
  display: inline-flex; align-items: baseline; gap: 4px;
  font-family: 'IBM Plex Mono', monospace; font-size: 0.76rem; font-weight: 500;
  background: var(--brick-tint); color: #7a3625; border-radius: 4px;
  padding: 2px 7px; text-decoration: none; margin: 0 2px;
  border: 1px solid #e5cdc4; cursor: pointer;
}
a.cite:hover { background: #ecd7cf; text-decoration: none; }
.cite::before { content: '↗'; opacity: 0.55; font-size: 0.68rem; }
/* research-record citations: our own review is the primary record, no external link */
.cite.record { background: var(--verified-tint); color: #2f5140; border-color: #bcd0c2; }
.cite.record::before { content: '§'; opacity: 0.6; }

.verified-tag {
  display: inline-flex; align-items: center; gap: 5px;
  font-family: 'IBM Plex Mono', monospace; font-size: 0.72rem; font-weight: 500;
  color: var(--verified); background: var(--verified-tint); border-radius: 4px;
  padding: 3px 8px; margin-bottom: 10px;
}

/* ---------- Timeline ---------- */
.timeline { border-left: 2px solid var(--hairline); margin: 24px 0 24px 4px; padding-left: 24px; }
.timeline .item { position: relative; padding-bottom: 22px; }
.timeline .item::before {
  content: ''; position: absolute; left: -30px; top: 4px;
  width: 10px; height: 10px; border-radius: 50%; background: var(--brick); border: 2px solid var(--paper);
}
.timeline .date { font-family: 'IBM Plex Mono', monospace; font-size: 0.82rem; color: var(--brick); font-weight: 500; }
.timeline .desc { margin-top: 3px; color: var(--ink); }
.timeline .sig { font-size: 0.88rem; color: var(--slate); margin-top: 2px; }

/* ---------- FAQ accordion ---------- */
details.faq { background: var(--panel); border: 1px solid var(--hairline); border-radius: 8px; padding: 4px 20px; margin-bottom: 10px; }
details.faq summary {
  cursor: pointer; font-weight: 600; padding: 14px 0; list-style: none; position: relative; padding-right: 28px;
}
details.faq summary::-webkit-details-marker { display: none; }
details.faq summary::after {
  content: '+'; position: absolute; right: 0; top: 12px; font-size: 1.3rem; color: var(--brick); font-weight: 400;
}
details.faq[open] summary::after { content: '–'; }
details.faq .a { padding-bottom: 18px; color: var(--slate); }
.faq-category { font-family: 'IBM Plex Mono', monospace; font-size: 0.75rem; letter-spacing: 0.07em; text-transform: uppercase; color: var(--brick); margin: 32px 0 12px; }
.faq-category:first-child { margin-top: 8px; }

/* ---------- Sources list ---------- */
.source-group h3 { margin-top: 2em; }
.source-row {
  display: flex; justify-content: space-between; gap: 16px; align-items: baseline;
  padding: 12px 0; border-bottom: 1px solid var(--hairline); font-size: 0.95rem;
}
.source-row a { color: var(--ink); text-decoration: none; }
.source-row a:hover { color: var(--brick); }
.source-row .go { font-family: 'IBM Plex Mono', monospace; font-size: 0.78rem; color: var(--slate); flex-shrink: 0; }

/* ---------- Download cards ---------- */
.doc-card {
  display: flex; gap: 18px; align-items: flex-start;
  background: var(--panel); border: 1px solid var(--hairline); border-radius: 10px; padding: 24px; margin-bottom: 18px;
}
.doc-icon {
  width: 46px; height: 58px; flex-shrink: 0; background: var(--paper); border: 1px solid var(--hairline);
  border-radius: 4px; display: flex; align-items: center; justify-content: center;
  font-family: 'IBM Plex Mono', monospace; font-size: 0.65rem; font-weight: 600; color: var(--brick);
}
.doc-meta { font-size: 0.85rem; color: var(--slate); margin: 4px 0 14px; }

/* ---------- Form placeholder ---------- */
.form-placeholder {
  background: var(--panel); border: 1.5px dashed var(--hairline); border-radius: 10px;
  padding: 36px 24px; text-align: center; color: var(--slate);
}
.form-placeholder .icon { font-size: 1.8rem; margin-bottom: 10px; }
.form-embed {
  background: var(--panel); border: 1px solid var(--hairline); border-radius: 10px;
  overflow: hidden; margin-bottom: 12px;
}
.form-embed iframe { display: block; width: 100%; }
.form-fallback { font-size: 0.88rem; color: var(--slate); }

/* ---------- Footer ---------- */
footer { border-top: 1px solid var(--hairline); margin-top: 60px; padding: 32px 0 48px; }
footer .banner-line { font-size: 0.92rem; color: var(--slate); max-width: 60ch; }
footer .meta { font-family: 'IBM Plex Mono', monospace; font-size: 0.78rem; color: var(--slate); margin-top: 16px; display: flex; gap: 18px; flex-wrap: wrap; }
footer a { color: var(--slate); }

table { width: 100%; border-collapse: collapse; margin: 20px 0; font-size: 0.94rem; }
th, td { text-align: left; padding: 10px 12px; border-bottom: 1px solid var(--hairline); vertical-align: top; }
th { font-family: 'IBM Plex Mono', monospace; font-size: 0.74rem; text-transform: uppercase; letter-spacing: 0.05em; color: var(--slate); font-weight: 500; }

.callout { background: var(--brick-tint); border-left: 3px solid var(--brick); border-radius: 0 8px 8px 0; padding: 16px 20px; margin: 20px 0; font-size: 0.95rem; }
.callout p:last-child { margin-bottom: 0; }

/* ---------- Exhibit: side-by-side quote comparison ---------- */
.exhibit { background: var(--panel); border: 1px solid var(--hairline); border-radius: 10px; padding: 26px 28px; margin: 22px 0; }
.exhibit-label { font-family: 'IBM Plex Mono', monospace; font-size: 0.74rem; text-transform: uppercase; letter-spacing: 0.05em; color: var(--slate); margin-bottom: 8px; }
.exhibit-quote { margin: 0 0 4px; padding-left: 16px; border-left: 3px solid var(--hairline); font-size: 1.05rem; line-height: 1.55; color: var(--ink); }
.exhibit-quote-full { color: var(--slate); font-size: 0.98rem; }
.exhibit-quote-full q, .exhibit-quote-full { font-style: normal; }
.exhibit-however { color: var(--brick); font-weight: 700; font-style: normal; }
.exhibit-source { font-size: 0.85rem; color: var(--slate); margin-top: 6px; }
.exhibit-source a { color: var(--slate); }
.exhibit-divider { font-size: 0.88rem; color: var(--ink); background: var(--paper); border-radius: 6px; padding: 10px 14px; margin: 18px 0; }

/* ---------- Petition strip: reusable cross-referral banner ---------- */
.petition-strip {
  display: flex; align-items: center; justify-content: space-between; gap: 20px; flex-wrap: wrap;
  background: var(--ink); color: var(--paper); border-radius: 10px; padding: 22px 26px; margin: 28px 0;
}
.petition-strip p { color: var(--paper); margin: 0; font-size: 1rem; max-width: 46ch; }
.petition-strip .btn-primary { background: var(--brick); flex-shrink: 0; }
.petition-strip .btn-primary:hover { background: #c25a3e; }
.petition-strip .btn-register { border-color: #e8a893; color: #f2c4b3; }
.petition-strip .btn-register:hover { background: var(--brick); color: #fff; border-color: var(--brick); }

/* ---------- Updates feed ---------- */
.update-feed { margin: 28px 0; }
.update-entry {
  background: var(--panel); border: 1px solid var(--hairline); border-radius: 10px;
  padding: 20px 24px; margin-bottom: 14px;
}
.update-entry .update-head { display: flex; align-items: baseline; gap: 12px; flex-wrap: wrap; margin-bottom: 6px; }
.update-entry .update-date { font-family: 'IBM Plex Mono', monospace; font-size: 0.8rem; color: var(--slate); }
.update-tag {
  display: inline-block; font-family: 'IBM Plex Mono', monospace; font-size: 0.68rem; font-weight: 600;
  letter-spacing: 0.05em; text-transform: uppercase; padding: 3px 8px; border-radius: 4px;
}
.update-tag.tag-sent { background: var(--brick-tint); color: #7a3625; }
.update-tag.tag-reply { background: var(--verified-tint); color: #2f5140; }
.update-tag.tag-milestone { background: #e6eaf0; color: #2c3e50; }
.update-tag.tag-media { background: #f0e9d8; color: #7a5c1e; }
.update-entry h4 { margin: 4px 0 6px; font-size: 1.05rem; }
.update-entry p { margin: 0; color: var(--slate); font-size: 0.95rem; }
.update-entry p.body-text { color: var(--ink); }
.update-loading, .update-empty { color: var(--slate); font-size: 0.95rem; padding: 12px 0; }
.update-preview { margin: 24px 0; }
.update-preview .update-entry { margin-bottom: 10px; }
.update-preview-more { font-size: 0.92rem; margin-top: 4px; }
