*, *::before, *::after { box-sizing: border-box; margin: 0; padding: 0; }

:root {
  --ink-midnight: #1c1c22;
  --thread-cream: #FAF7F2;
  --paper-white: #FFFFFF;
  --signal-teal: #3D7A78;
  --signal-teal-light: #E8F2F1;
  --copper-wire: #B87333;
  --copper-light: #F5E8DA;
  --muted-rose: #8B6F71;
  --warm-graphite: #6E6A65;
  --border-soft: rgba(184, 115, 51, 0.18);
  --shadow-soft: 0 4px 24px rgba(28, 28, 34, 0.06);
  --shadow-card: 0 8px 32px rgba(28, 28, 34, 0.08);
  --measure: 68ch;
  --pad: clamp(3rem, 6vw, 7.5rem);
  --font-serif: 'DM Serif Display', Georgia, serif;
  --font-body: 'Lora', Georgia, serif;
  --font-mono: 'IBM Plex Mono', monospace;
}

html { scroll-behavior: smooth; font-size: 100%; }
@media (prefers-reduced-motion: reduce) { html { scroll-behavior: auto; } }

body {
  font-family: var(--font-body);
  font-size: 1.125rem;
  font-weight: 400;
  line-height: 1.72;
  color: var(--ink-midnight);
  background: var(--thread-cream);
}

img { max-width: 100%; height: auto; display: block; }
a { color: var(--signal-teal); text-decoration-thickness: 1px; text-underline-offset: 3px; }
a:hover { color: var(--copper-wire); opacity: 1; }

.surface-cream { background: var(--thread-cream); color: var(--ink-midnight); }
.surface-white { background: var(--paper-white); color: var(--ink-midnight); }
.surface-midnight { background: var(--paper-white); color: var(--ink-midnight); }
.surface-teal { background: var(--signal-teal-light); color: var(--ink-midnight); }
.surface-copper { background: var(--copper-light); color: var(--ink-midnight); }

/* ── Header ── */
.site-header {
  position: sticky; top: 0; z-index: 100;
  background: rgba(255, 255, 255, 0.92);
  backdrop-filter: blur(12px);
  -webkit-backdrop-filter: blur(12px);
  color: var(--ink-midnight);
  border-bottom: 1px solid var(--border-soft);
  transition: box-shadow 0.3s;
}
.site-header.surface-midnight {
  background: rgba(255, 255, 255, 0.92);
  color: var(--ink-midnight);
}
.site-header.is-scrolled { box-shadow: var(--shadow-soft); }

.header-inner {
  max-width: 1200px; margin: 0 auto;
  padding: 1rem 1.5rem;
  display: flex; align-items: center; justify-content: space-between; gap: 1rem;
}

.logo {
  font-family: var(--font-serif);
  font-weight: 700; font-size: 1.5rem;
  text-decoration: none; letter-spacing: 0.02em;
  color: var(--ink-midnight);
}
.logo span { color: var(--copper-wire); }

.nav-list { display: flex; gap: 1.75rem; list-style: none; align-items: center; }
.nav-list a {
  text-decoration: none; font-size: 0.95rem; font-weight: 500;
  color: var(--warm-graphite);
}
.nav-list a:hover { color: var(--copper-wire); }
.nav-list a[aria-current="page"] { color: var(--ink-midnight); font-weight: 600; }

.nav-cta {
  padding: 0.5rem 1.15rem;
  border: 1.5px solid var(--copper-wire);
  border-radius: 4px;
  color: var(--copper-wire) !important;
  font-weight: 600 !important;
}
.nav-cta:hover {
  background: var(--copper-wire);
  color: var(--paper-white) !important;
}

.menu-toggle {
  display: none; background: var(--paper-white);
  border: 1.5px solid var(--copper-wire);
  color: var(--copper-wire); padding: 0.4rem 0.75rem;
  cursor: pointer; font-family: var(--font-mono);
  font-size: 0.75rem; letter-spacing: 0.08em; text-transform: uppercase;
  border-radius: 4px;
}

main { min-height: 60vh; }

.eyebrow {
  font-family: var(--font-mono);
  font-size: 0.75rem; font-weight: 500;
  letter-spacing: 0.14em; text-transform: uppercase;
  color: var(--copper-wire);
}

.dateline {
  font-family: var(--font-mono);
  font-size: 0.8125rem; font-weight: 500;
  letter-spacing: 0.06em;
  color: var(--warm-graphite);
}

h1, h2, h3 {
  font-family: var(--font-serif);
  font-weight: 700; line-height: 1.15;
  color: var(--ink-midnight);
}
h1 { font-size: clamp(2.25rem, 5vw, 3.75rem); }
h2 { font-size: clamp(1.75rem, 3vw, 2.5rem); }
h3 { font-size: clamp(1.25rem, 2vw, 1.625rem); font-weight: 600; }

.prose { max-width: var(--measure); }
.prose p { margin-bottom: 1.25em; }
.prose p:last-child { margin-bottom: 0; }

.section { padding: var(--pad) 1.5rem; }
.section-inner { max-width: 1100px; margin: 0 auto; }
.section-narrow { max-width: 780px; margin: 0 auto; }

.pull-quote {
  margin: 2.5rem 0; padding: 1.75rem 2rem;
  border-left: 3px solid var(--copper-wire);
  background: var(--copper-light);
  border-radius: 0 4px 4px 0;
  font-family: var(--font-serif);
  font-size: clamp(1.35rem, 2.5vw, 1.75rem);
  font-style: italic; line-height: 1.4;
  color: var(--muted-rose);
}

.article-hero { padding-top: calc(var(--pad) * 0.75); }
.article-meta { margin: 1rem 0 2rem; display: flex; flex-wrap: wrap; gap: 1rem; align-items: center; }
.article-photo { margin: 2rem 0; border-radius: 6px; overflow: hidden; }
.article-photo img {
  width: 100%;
  box-shadow: var(--shadow-card);
  border: 1px solid var(--border-soft);
}
.article-photo figcaption {
  font-family: var(--font-mono);
  font-size: 0.75rem; padding: 0.75rem 0;
  color: var(--warm-graphite);
}

/* ── Hero ── */
.hero-open {
  position: relative; overflow: hidden;
  min-height: 72vh;
  display: flex; flex-direction: column; justify-content: flex-end;
  background: var(--thread-cream);
}
.hero-open.surface-midnight { background: var(--thread-cream); color: var(--ink-midnight); }
.hero-open-bg {
  position: absolute; inset: 0; bottom: auto;
  height: 58%; z-index: 0;
}
.hero-open-bg img {
  width: 100%; height: 100%; object-fit: cover;
}
.hero-open-bg::after {
  content: '';
  position: absolute; inset: 0;
  background: linear-gradient(
    to bottom,
    rgba(250, 247, 242, 0.05) 0%,
    rgba(250, 247, 242, 0.45) 65%,
    var(--thread-cream) 100%
  );
}
.hero-open-content {
  position: relative; z-index: 1;
  width: 100%; max-width: 1100px; margin: 0 auto;
  padding: 2rem 1.5rem var(--pad);
  background: var(--thread-cream);
  border-top: 1px solid var(--border-soft);
}
.hero-open .eyebrow {
  color: #8B5A2B;
  font-weight: 600;
}
.hero-open h1 {
  max-width: 14ch;
  color: var(--ink-midnight);
}
.hero-open h1 .accent { color: var(--copper-wire); }
.hero-tagline {
  max-width: 46ch;
  margin-top: 1.25rem;
  font-size: 1.125rem;
  line-height: 1.65;
  color: var(--ink-midnight);
}
.hero-open .btn-secondary {
  background: var(--paper-white);
  border: 2px solid var(--ink-midnight);
  color: var(--ink-midnight);
  font-weight: 600;
  box-shadow: var(--shadow-soft);
}
.hero-open .btn-secondary:hover {
  background: var(--ink-midnight);
  color: var(--paper-white);
  border-color: var(--ink-midnight);
}

.featured-card {
  display: grid; grid-template-columns: 1fr 1.15fr; gap: 2.5rem;
  padding: 2.5rem; border-radius: 8px; align-items: center;
  background: var(--paper-white);
  border: 1px solid var(--border-soft);
  box-shadow: var(--shadow-soft);
}
.featured-card.surface-midnight {
  background: var(--paper-white);
  color: var(--ink-midnight);
}
.featured-card img {
  border-radius: 6px;
  box-shadow: var(--shadow-card);
  border: 1px solid var(--border-soft);
}

.about-strip {
  display: grid; grid-template-columns: 160px 1fr; gap: 2rem;
  align-items: center; margin-top: 3rem; padding-top: 3rem;
  border-top: 1px solid var(--border-soft);
}
.about-strip img {
  width: 160px; height: 160px; object-fit: cover; border-radius: 50%;
  border: 3px solid var(--copper-wire);
  box-shadow: var(--shadow-soft);
}

.post-grid {
  display: grid; grid-template-columns: repeat(auto-fill, minmax(280px, 1fr));
  gap: 1.75rem; margin-top: 2rem;
}
.post-card {
  background: var(--paper-white);
  border: 1px solid var(--border-soft);
  border-radius: 8px; overflow: hidden;
  transition: transform 0.25s, box-shadow 0.25s;
}
.post-card:hover { transform: translateY(-3px); box-shadow: var(--shadow-card); }
.post-card img { aspect-ratio: 16/10; object-fit: cover; width: 100%; }
.post-card-body { padding: 1.5rem; }
.post-card h3 { margin-bottom: 0.5rem; font-size: 1.25rem; }
.post-card h3 a { text-decoration: none; color: var(--ink-midnight); }
.post-card h3 a:hover { color: var(--copper-wire); }
.post-card .dateline { margin-bottom: 0.75rem; display: block; }

.card-grid {
  display: grid; grid-template-columns: repeat(auto-fill, minmax(280px, 1fr));
  gap: 1.75rem; margin-top: 2rem;
}
.card {
  background: var(--paper-white);
  border: 1px solid var(--border-soft);
  border-radius: 8px; overflow: hidden;
  transition: transform 0.25s, box-shadow 0.25s;
}
.card:hover { transform: translateY(-3px); box-shadow: var(--shadow-card); }
.card img { aspect-ratio: 16/10; object-fit: cover; width: 100%; }
.card-body { padding: 1.5rem; }
.card h3 { margin-bottom: 0.5rem; font-size: 1.25rem; }
.card h3 a { text-decoration: none; color: var(--ink-midnight); }
.card h3 a:hover { color: var(--copper-wire); }
.card .dateline { margin-bottom: 0.75rem; display: block; }

.journal-list { list-style: none; margin-top: 2rem; }
.journal-item {
  display: grid; grid-template-columns: 140px 1fr; gap: 2rem;
  padding: 2rem 0; border-bottom: 1px solid var(--border-soft);
  align-items: start;
}
.journal-item:first-child { border-top: 1px solid var(--border-soft); }
.journal-item img {
  border-radius: 6px; aspect-ratio: 4/3; object-fit: cover;
  border: 1px solid var(--border-soft);
  box-shadow: var(--shadow-soft);
}
.journal-item h2 { font-size: 1.5rem; margin-bottom: 0.5rem; }
.journal-item h2 a { text-decoration: none; color: var(--ink-midnight); }
.journal-item h2 a:hover { color: var(--copper-wire); }

.btn-row { display: flex; flex-wrap: wrap; gap: 1rem; margin-top: 2rem; }
.btn {
  display: inline-block; padding: 0.85rem 1.75rem;
  font-weight: 500; font-size: 0.95rem;
  text-decoration: none; border-radius: 4px;
  transition: background 0.2s, color 0.2s, box-shadow 0.2s;
  cursor: pointer;
}
.btn:hover { opacity: 1; }
.btn-primary {
  background: var(--copper-wire); color: var(--paper-white); border: none;
  box-shadow: 0 2px 8px rgba(184, 115, 51, 0.25);
}
.btn-primary:hover { background: #a3662d; color: var(--paper-white); }
.btn-secondary {
  background: var(--paper-white); color: var(--ink-midnight);
  border: 1.5px solid var(--border-soft);
}
.btn-secondary:hover { border-color: var(--copper-wire); color: var(--copper-wire); }

/* ── Contact ── */
.contact-hero-img {
  width: 100%; max-height: 280px; object-fit: cover;
  border-radius: 8px; margin: 2rem 0;
  border: 1px solid var(--border-soft);
  box-shadow: var(--shadow-soft);
}

.contact-grid {
  display: grid; grid-template-columns: 1fr 1.2fr; gap: 3rem;
  margin-top: 2rem;
}
.contact-details {
  font-style: normal;
  background: var(--paper-white);
  padding: 2rem;
  border-radius: 8px;
  border: 1px solid var(--border-soft);
  box-shadow: var(--shadow-soft);
}
.contact-details p { margin-bottom: 0.75em; }

.contact-form-wrap {
  background: var(--paper-white);
  padding: 2rem;
  border-radius: 8px;
  border: 1px solid var(--border-soft);
  box-shadow: var(--shadow-soft);
}

.form-group { margin-bottom: 1.25rem; }
.form-group > label {
  display: block; margin-bottom: 0.4rem;
  font-family: var(--font-mono); font-size: 0.75rem;
  letter-spacing: 0.06em; text-transform: uppercase;
  color: var(--warm-graphite);
}
.form-group input,
.form-group select,
.form-group textarea {
  width: 100%; padding: 0.75rem 1rem;
  font-family: var(--font-body); font-size: 1rem;
  border: 1px solid var(--border-soft);
  border-radius: 4px; background: var(--thread-cream);
  color: var(--ink-midnight);
  transition: border-color 0.2s, box-shadow 0.2s;
}
.form-group input:focus,
.form-group select:focus,
.form-group textarea:focus {
  outline: none;
  border-color: var(--copper-wire);
  box-shadow: 0 0 0 3px rgba(184, 115, 51, 0.12);
}
.form-group textarea { min-height: 160px; resize: vertical; }

.form-check {
  display: flex;
  flex-direction: row;
  align-items: flex-start;
  gap: 0.85rem;
  padding: 1rem;
  background: var(--signal-teal-light);
  border-radius: 6px;
  border: 1px solid rgba(61, 122, 120, 0.2);
}
.form-check input[type="checkbox"] {
  width: 1.15rem;
  height: 1.15rem;
  min-width: 1.15rem;
  margin-top: 0.2rem;
  flex-shrink: 0;
  accent-color: var(--signal-teal);
  cursor: pointer;
}
.form-check label {
  display: block;
  flex: 1;
  font-family: var(--font-body);
  font-size: 0.9375rem;
  letter-spacing: normal;
  text-transform: none;
  line-height: 1.55;
  color: var(--ink-midnight);
  cursor: pointer;
  margin-bottom: 0;
}

.form-note { font-size: 0.875rem; color: var(--warm-graphite); margin-top: 1rem; }
.form-alert {
  padding: 1rem 1.25rem; border-radius: 6px; margin-bottom: 1.5rem;
  border: 1px solid var(--signal-teal); background: var(--signal-teal-light);
}
.form-alert.is-error { border-color: var(--muted-rose); background: rgba(139, 111, 113, 0.08); }
.hp-field { position: absolute; left: -9999px; opacity: 0; height: 0; overflow: hidden; }

.error-page { text-align: center; padding: calc(var(--pad) * 1.5) 1.5rem; }
.error-page h1 { margin-bottom: 1rem; }
.error-code {
  font-family: var(--font-mono); font-size: 0.875rem;
  letter-spacing: 0.12em; color: var(--copper-wire);
  margin-bottom: 1.5rem;
}

/* ── Footer ── */
.site-footer {
  padding: 0;
  border-top: 3px solid var(--copper-wire);
  background: var(--paper-white);
  color: var(--ink-midnight);
}
.site-footer.surface-midnight {
  background: var(--paper-white);
  color: var(--ink-midnight);
}

.footer-top {
  max-width: 1100px; margin: 0 auto;
  padding: 3.5rem 1.5rem 2.5rem;
  display: grid;
  grid-template-columns: 1.4fr 1fr 1fr;
  gap: 2.5rem;
}

.footer-brand {
  font-family: var(--font-serif);
  font-size: 1.5rem; font-weight: 700;
  color: var(--ink-midnight);
  margin-bottom: 0.75rem;
}
.footer-brand span { color: var(--copper-wire); }

.footer-tagline {
  font-size: 0.9375rem;
  color: var(--warm-graphite);
  line-height: 1.6;
  max-width: 32ch;
}

.footer-heading {
  font-family: var(--font-mono);
  font-size: 0.7rem;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  color: var(--copper-wire);
  margin-bottom: 1rem;
}

.footer-links { list-style: none; }
.footer-links li { margin-bottom: 0.5rem; }
.footer-links a {
  text-decoration: none;
  font-size: 0.9375rem;
  color: var(--warm-graphite);
  transition: color 0.2s;
}
.footer-links a:hover { color: var(--copper-wire); }

.footer-contact p {
  font-size: 0.9375rem;
  color: var(--warm-graphite);
  margin-bottom: 0.4rem;
  line-height: 1.6;
}
.footer-contact a { color: var(--signal-teal); text-decoration: none; }
.footer-contact a:hover { color: var(--copper-wire); }

.footer-bottom {
  border-top: 1px solid var(--border-soft);
  background: var(--thread-cream);
}
.footer-bottom-inner {
  max-width: 1100px; margin: 0 auto;
  padding: 1.25rem 1.5rem;
  display: flex; flex-wrap: wrap;
  justify-content: space-between; align-items: center; gap: 0.75rem;
  font-size: 0.8125rem;
  color: var(--warm-graphite);
  font-family: var(--font-mono);
  letter-spacing: 0.04em;
}

/* Legacy footer support */
.footer-inner {
  max-width: 1100px; margin: 0 auto;
  padding: 3rem 1.5rem 2rem;
  display: grid; grid-template-columns: 1fr auto; gap: 2rem;
  align-items: end;
}
.footer-meta { font-size: 0.875rem; color: var(--warm-graphite); margin-top: 0.5rem; line-height: 1.7; }

/* ── Reveal (no content hiding) ── */
.reveal {
  opacity: 1;
  transform: none;
}
@media (prefers-reduced-motion: no-preference) {
  .js .reveal {
    opacity: 1;
    transform: none;
    transition: opacity 0.5s ease, transform 0.5s ease;
  }
  .js .reveal.reveal-pending {
    opacity: 0;
    transform: translateY(14px);
  }
  .js .reveal.reveal-pending.is-visible {
    opacity: 1;
    transform: none;
  }
}
@media (prefers-reduced-motion: reduce) {
  .reveal { opacity: 1; transform: none; transition: none; }
}

/* ── Cookie banner ── */
#cookie-banner {
  position: fixed; bottom: 0; left: 0; right: 0; z-index: 200;
  background: var(--paper-white);
  color: var(--ink-midnight);
  padding: 1.25rem 1.5rem;
  border-top: 1px solid var(--border-soft);
  box-shadow: 0 -4px 24px rgba(28, 28, 34, 0.08);
  transform: translateY(110%); transition: transform 0.35s ease;
}
#cookie-banner.is-visible { transform: translateY(0); }
.cookie-inner {
  max-width: 1100px; margin: 0 auto;
  display: flex; flex-wrap: wrap; gap: 1rem; align-items: center; justify-content: space-between;
}
.cookie-text { flex: 1; min-width: 240px; font-size: 0.9rem; color: var(--warm-graphite); }
.cookie-actions { display: flex; flex-wrap: wrap; gap: 0.5rem; }
.cookie-actions button {
  padding: 0.55rem 1.15rem; font-family: var(--font-mono);
  font-size: 0.75rem; letter-spacing: 0.06em; text-transform: uppercase;
  cursor: pointer; border-radius: 4px;
  transition: background 0.2s, color 0.2s;
}
#cookie-accept { background: var(--copper-wire); color: var(--paper-white); border: none; }
#cookie-accept:hover { background: #a3662d; }
#cookie-reject { background: transparent; color: var(--warm-graphite); border: 1px solid var(--border-soft); }
#cookie-customise { background: transparent; color: var(--copper-wire); border: 1.5px solid var(--copper-wire); }
#cookie-panel {
  display: none; width: 100%; margin-top: 1rem;
  padding-top: 1rem; border-top: 1px solid var(--border-soft);
}
#cookie-panel.is-open { display: block; }
#cookie-panel label {
  display: flex; gap: 0.5rem; align-items: center;
  margin-bottom: 0.5rem; font-size: 0.875rem;
}
#cookie-save {
  margin-top: 0.75rem; background: var(--signal-teal);
  color: var(--paper-white); border: none;
  padding: 0.55rem 1.15rem; cursor: pointer;
  font-family: var(--font-mono); font-size: 0.75rem;
  border-radius: 4px;
}

.thanks-page {
  text-align: center; padding: calc(var(--pad) * 1.5) 1.5rem;
  min-height: 70vh; display: flex; align-items: center; justify-content: center;
}
.thanks-page .section-inner { max-width: 520px; }

.two-up { display: grid; grid-template-columns: 1fr 1fr; gap: 2rem; margin: 2rem 0; }
.two-up img { border-radius: 6px; border: 1px solid var(--border-soft); box-shadow: var(--shadow-soft); }

.neighbourhood-grid {
  display: grid; grid-template-columns: 1fr 1fr; gap: 2rem; align-items: center;
}
.neighbourhood-grid img {
  border-radius: 8px;
  border: 1px solid var(--border-soft);
  box-shadow: var(--shadow-card);
}

.about-grid {
  display: grid; grid-template-columns: 200px 1fr; gap: 3rem; align-items: start;
}
.about-grid img {
  width: 200px; height: 200px; object-fit: cover;
  border-radius: 50%; border: 3px solid var(--copper-wire);
  box-shadow: var(--shadow-soft);
}

.surface-teal .eyebrow { color: var(--signal-teal); }
.surface-teal .btn-primary { background: var(--signal-teal); box-shadow: 0 2px 8px rgba(61, 122, 120, 0.25); }
.surface-teal .btn-primary:hover { background: #346866; }

@media (max-width: 900px) {
  .hero-open { min-height: 62vh; }
  .hero-open-bg { height: 50%; }
  .featured-card { grid-template-columns: 1fr; }
  .about-strip { grid-template-columns: 1fr; text-align: center; }
  .about-strip img { margin: 0 auto; }
  .contact-grid { grid-template-columns: 1fr; }
  .journal-item { grid-template-columns: 1fr; }
  .two-up { grid-template-columns: 1fr; }
  .neighbourhood-grid { grid-template-columns: 1fr; }
  .about-grid { grid-template-columns: 1fr; text-align: center; }
  .about-grid img { margin: 0 auto; }
  .footer-top { grid-template-columns: 1fr; gap: 2rem; }
  .footer-inner { grid-template-columns: 1fr; }
  .footer-links { text-align: left; }
}

@media (max-width: 768px) {
  .menu-toggle { display: block; }
  .nav-list {
    display: none; position: absolute; top: 100%; left: 0; right: 0;
    flex-direction: column; padding: 1rem 1.5rem 1.5rem;
    background: var(--paper-white);
    border-bottom: 1px solid var(--border-soft);
    box-shadow: var(--shadow-soft);
  }
  .nav-list.is-open { display: flex; }
  .header-inner { position: relative; flex-wrap: wrap; }
  .footer-bottom-inner { flex-direction: column; text-align: center; }
}
