/* Woodhead and Windyhills Community Trust
   Shared stylesheet. Edit colours in the :root block below. */

:root {
  --peat:   #1C2A1B;
  --moss:   #4C6B47;
  --gorse:  #C08A1E;
  --quartz: #EFF1EC;
  --stone:  #8A9187;
  --paper:  #F7F8F4;
  --ink:    #161D15;

  --measure: 36rem;
  --shell: 68rem;

  --display: "Fraunces", Georgia, serif;
  --body: "Karla", system-ui, sans-serif;
  --utility: "IBM Plex Mono", ui-monospace, monospace;
}

*, *::before, *::after { box-sizing: border-box; }

html { -webkit-text-size-adjust: 100%; }

body {
  margin: 0;
  background: var(--paper);
  color: var(--ink);
  font-family: var(--body);
  font-size: 1.0625rem;
  line-height: 1.65;
}

img { max-width: 100%; height: auto; display: block; }

a { color: var(--moss); text-underline-offset: 3px; }
a:hover { color: var(--peat); }

:focus-visible {
  outline: 3px solid var(--gorse);
  outline-offset: 3px;
}

.shell {
  width: min(100% - 2.5rem, var(--shell));
  margin-inline: auto;
}

/* ---------- Signature: quartzite gravel band ---------- */
/* The site sits on quartzite gravels from an ancient river-bed.
   This band is the visual thread that runs through the site. */
.strata {
  height: 18px;
  background:
    radial-gradient(circle at 6px 10px,  var(--stone) 0 3px,   transparent 3.5px),
    radial-gradient(circle at 21px 6px,  var(--moss)  0 2px,   transparent 2.5px),
    radial-gradient(circle at 34px 12px, var(--gorse) 0 2.5px, transparent 3px),
    radial-gradient(circle at 48px 7px,  var(--stone) 0 2px,   transparent 2.5px),
    radial-gradient(circle at 58px 13px, var(--moss)  0 1.5px, transparent 2px);
  background-size: 68px 18px;
  opacity: .6;
}

/* ---------- Header ---------- */
.masthead {
  background: var(--peat);
  color: var(--quartz);
  padding: 1.1rem 0;
}
.masthead-inner {
  display: flex;
  flex-wrap: wrap;
  gap: 1rem 2rem;
  align-items: baseline;
  justify-content: space-between;
}
.wordmark {
  font-family: var(--display);
  font-weight: 600;
  font-size: 1.0625rem;
  line-height: 1.25;
  letter-spacing: .01em;
  color: var(--quartz);
  text-decoration: none;
  max-width: 15rem;
}
.wordmark:hover { color: #fff; }

nav ul {
  list-style: none;
  display: flex;
  flex-wrap: wrap;
  gap: .35rem 1.25rem;
  margin: 0;
  padding: 0;
}
nav a {
  font-family: var(--utility);
  font-size: .7rem;
  letter-spacing: .09em;
  text-transform: uppercase;
  color: var(--quartz);
  text-decoration: none;
  padding-bottom: 2px;
  border-bottom: 2px solid transparent;
}
nav a:hover { color: #fff; border-bottom-color: var(--gorse); }
nav a[aria-current="page"] { color: var(--gorse); border-bottom-color: var(--gorse); }

/* ---------- Hero ---------- */
.hero {
  position: relative;
  background: var(--peat);
  color: var(--quartz);
  overflow: hidden;
}
.hero-img {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  object-fit: cover;
  opacity: .42;
}
.hero-inner {
  position: relative;
  padding: 5.5rem 0 4.5rem;
}
.eyebrow {
  font-family: var(--utility);
  font-size: .7rem;
  letter-spacing: .16em;
  text-transform: uppercase;
  color: var(--gorse);
  margin: 0 0 1.1rem;
}
.hero h1 {
  font-family: var(--display);
  font-weight: 600;
  font-size: clamp(2.3rem, 6.5vw, 4.1rem);
  line-height: 1.02;
  letter-spacing: -.02em;
  margin: 0 0 .8rem;
  max-width: 16ch;
  text-wrap: balance;
}
.hero p.lede {
  max-width: var(--measure);
  font-size: 1.15rem;
  margin: 0 0 2rem;
  color: #DCE2D6;
}

/* ---------- Buttons ---------- */
.btn {
  display: inline-block;
  font-family: var(--utility);
  font-size: .72rem;
  letter-spacing: .12em;
  text-transform: uppercase;
  text-decoration: none;
  padding: .85rem 1.5rem;
  background: var(--gorse);
  color: var(--peat);
  border: 2px solid var(--gorse);
}
.btn:hover { background: transparent; color: var(--gorse); }
.btn-quiet { background: transparent; color: var(--quartz); border-color: var(--stone); }
.btn-quiet:hover { background: var(--quartz); color: var(--peat); border-color: var(--quartz); }
.btn-row { display: flex; flex-wrap: wrap; gap: .75rem; }

/* ---------- Page title (non-home pages) ---------- */
.page-head {
  background: var(--peat);
  color: var(--quartz);
  padding: 3.25rem 0 2.75rem;
}
.page-head h1 {
  font-family: var(--display);
  font-weight: 600;
  font-size: clamp(2rem, 5vw, 3.1rem);
  line-height: 1.05;
  letter-spacing: -.02em;
  margin: 0;
  text-wrap: balance;
}
.page-head p {
  max-width: var(--measure);
  margin: 1rem 0 0;
  color: #DCE2D6;
}

/* ---------- Sections ---------- */
.band { padding: 4rem 0; }
.band-quartz { background: var(--quartz); }

.band h2 {
  font-family: var(--display);
  font-weight: 600;
  font-size: clamp(1.5rem, 3.2vw, 2.1rem);
  line-height: 1.15;
  letter-spacing: -.015em;
  margin: 0 0 1rem;
  text-wrap: balance;
}
.band h3 {
  font-family: var(--display);
  font-weight: 600;
  font-size: 1.3rem;
  line-height: 1.2;
  margin: 0 0 .5rem;
}
.prose { max-width: var(--measure); }
.prose p { margin: 0 0 1.15rem; }
.prose p:last-child { margin-bottom: 0; }

/* ---------- Cards ---------- */
.cards {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(17rem, 1fr));
  gap: 2rem;
  margin: 0;
  padding: 0;
  list-style: none;
}
.card { background: var(--paper); border: 1px solid #D8DDD3; }
.band-quartz .card { background: var(--paper); }
.card img { aspect-ratio: 4 / 3; object-fit: cover; width: 100%; }
.card-body { padding: 1.35rem 1.4rem 1.5rem; }
.card-body p { margin: 0; }
.card-body p + p { margin-top: .9rem; }

/* ---------- Record cards (Resources index) ---------- */
.records {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(13rem, 1fr));
  gap: 1.25rem;
  list-style: none;
  margin: 2.5rem 0 0;
  padding: 0;
}
.record {
  border: 1px solid #D8DDD3;
  background: var(--paper);
}
.record a {
  display: block;
  text-decoration: none;
  color: inherit;
  height: 100%;
}
.record a:hover { background: var(--quartz); }
.record a:hover .record-name { color: var(--moss); }
.record img { aspect-ratio: 3 / 2; object-fit: cover; width: 100%; }
.record-meta { padding: .9rem 1rem 1.1rem; }
.record-index {
  font-family: var(--utility);
  font-size: .65rem;
  letter-spacing: .14em;
  text-transform: uppercase;
  color: var(--stone);
  display: block;
  margin-bottom: .3rem;
}
.record-name {
  font-family: var(--display);
  font-weight: 600;
  font-size: 1.15rem;
  line-height: 1.15;
}

/* ---------- Gallery ---------- */
/* Photographs run down the page at full size, uncropped. */
.gallery {
  columns: 3;
  column-gap: 1.5rem;
  list-style: none;
  margin: 0;
  padding: 0;
}
.gallery li {
  break-inside: avoid;
  margin: 0 0 1.5rem;
}
.gallery figure {
  margin: 0;
  border: 1px solid #D8DDD3;
  background: var(--paper);
}
.gallery img {
  width: 100%;
  height: auto;
  display: block;
}
.gallery figcaption {
  font-family: var(--utility);
  font-size: .72rem;
  letter-spacing: .03em;
  padding: .65rem .8rem .75rem;
  color: var(--peat);
}
@media (max-width: 60rem) { .gallery { columns: 2; } }
@media (max-width: 38rem) { .gallery { columns: 1; } }

.empty {
  border: 1px dashed var(--stone);
  padding: 2rem 1.75rem;
  max-width: var(--measure);
  font-family: var(--utility);
  font-size: .85rem;
  line-height: 1.6;
  color: var(--peat);
  background: var(--quartz);
}

/* ---------- News ---------- */
.news-list { list-style: none; margin: 0; padding: 0; display: grid; gap: 3rem; }
.news-item {
  display: grid;
  grid-template-columns: minmax(0, 20rem) minmax(0, 1fr);
  gap: 2rem;
  align-items: start;
}
@media (max-width: 42rem) {
  .news-item { grid-template-columns: 1fr; gap: 1.25rem; }
}
.news-item img { aspect-ratio: 1 / 1; object-fit: cover; }

/* ---------- Contact ---------- */
.contact-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(15rem, 1fr));
  gap: 2.5rem;
}
.contact-grid h3 { margin-bottom: .4rem; }
address { font-style: normal; }

/* ---------- Footer ---------- */
.footer {
  background: var(--peat);
  color: #C7CFC1;
  padding: 3rem 0 2.5rem;
  font-size: .9rem;
}
.footer a { color: var(--quartz); }
.footer-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(13rem, 1fr));
  gap: 2rem;
  margin-bottom: 2.5rem;
}
.footer h2 {
  font-family: var(--utility);
  font-size: .68rem;
  letter-spacing: .14em;
  text-transform: uppercase;
  color: var(--gorse);
  margin: 0 0 .75rem;
  font-weight: 400;
}
.footer ul { list-style: none; margin: 0; padding: 0; display: grid; gap: .4rem; }
.colophon {
  border-top: 1px solid #33422F;
  padding-top: 1.5rem;
  font-family: var(--utility);
  font-size: .7rem;
  letter-spacing: .05em;
  color: var(--stone);
}

@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after {
    animation-duration: .01ms !important;
    transition-duration: .01ms !important;
  }
}

/* Galleries with no photographs yet: a gravel block in place of a thumbnail */
.record-blank {
  aspect-ratio: 3 / 2;
  background:
    radial-gradient(circle at 14px 22px, var(--stone) 0 5px, transparent 5.5px),
    radial-gradient(circle at 44px 14px, var(--moss) 0 3.5px, transparent 4px),
    radial-gradient(circle at 72px 30px, var(--gorse) 0 4px, transparent 4.5px),
    radial-gradient(circle at 100px 18px, var(--stone) 0 3px, transparent 3.5px);
  background-size: 124px 44px;
  background-color: var(--quartz);
  opacity: .8;
}

/* News items with no photograph */
.news-item-text { grid-template-columns: 1fr; }
.news-item-text .prose { max-width: var(--measure); }

/* Image beside text (home feature, donate) */
.split {
  display: grid;
  grid-template-columns: minmax(0, 1fr) minmax(0, 1fr);
  gap: 3rem;
  align-items: center;
}
.split img { width: 100%; aspect-ratio: 4 / 3; object-fit: cover; }
@media (max-width: 46rem) {
  .split { grid-template-columns: 1fr; gap: 1.75rem; }
}

/* Homepage hero: photograph one half, words the other */
.hero-split {
  display: grid;
  grid-template-columns: 1fr 1fr;
  background: var(--peat);
  color: var(--quartz);
  min-height: min(70vh, 600px);
}
.hero-split-img img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  display: block;
}
.hero-split-text {
  display: flex;
  flex-direction: column;
  justify-content: center;
  padding: 3.5rem clamp(1.5rem, 4vw, 4.5rem);
  max-width: 36rem;
}
.hero-split h1 {
  font-family: var(--display);
  font-weight: 600;
  font-size: clamp(2rem, 3.4vw, 3rem);
  line-height: 1.05;
  letter-spacing: -.02em;
  margin: 0 0 .8rem;
  text-wrap: balance;
}
.hero-split .lede {
  font-size: 1.1rem;
  color: #DCE2D6;
  margin: 0 0 1.9rem;
}
@media (max-width: 52rem) {
  .hero-split { grid-template-columns: 1fr; min-height: 0; }
  .hero-split-img img { height: clamp(240px, 44vh, 360px); }
  .hero-split-text { padding: 2.75rem 1.25rem 3rem; max-width: none; }
}

/* Upright photograph beside a column of text */
.split-tall { align-items: start; }
.split-tall img { aspect-ratio: 3 / 4; }
@media (max-width: 46rem) {
  .split-tall img { aspect-ratio: 4 / 3; }
}
