/* One section per block type. Class names match templates/blocks/. */

/* hero: yellow field, photo cut in the shape of the cottage */
.hero {
  background: var(--roof);
  display: grid;
  grid-template-columns: minmax(0, 1.05fr) minmax(0, 0.95fr);
  align-items: end;
  gap: clamp(1.5rem, 4vw, 4rem);
  padding: clamp(2rem, 6vw, 5rem) var(--inset) 0;
}
.hero-text { padding-bottom: clamp(2rem, 6vw, 5rem); }
.lede { font-size: clamp(1.2rem, 2vw, 1.45rem); line-height: 1.45; max-width: 34ch; }
.actions { display: flex; flex-wrap: wrap; gap: 0.75rem; margin: 1.75rem 0 0; }
.cottage { margin: 0; align-self: end; justify-self: end; max-width: 40rem; width: 100%; }
.cottage img {
  width: 100%;
  aspect-ratio: 1 / 1.02;
  object-fit: cover;
  object-position: 62% 30%;
  clip-path: polygon(50% 0, 100% 27%, 100% 100%, 0 100%, 0 27%);
}

/* prose */
.prose-text { max-width: 46rem; }
.prose-text p { font-size: 1.15rem; }
.prose.split { display: grid; grid-template-columns: minmax(0, 1fr) minmax(0, 1fr); gap: clamp(1.5rem, 5vw, 4rem); align-items: center; }
.prose .when { font-weight: 700; font-size: 1.125rem; margin-bottom: 0.4rem; }
.prose .aside { border-left: 6px solid var(--roof); padding-left: 1rem; font-size: 1rem; }
.prose-media { margin: 0; }
.prose-media img { width: 100%; border-radius: var(--radius); }
.prose-media.video { aspect-ratio: 16 / 9; }
.prose-media.video iframe { width: 100%; height: 100%; border: 0; border-radius: var(--radius); }

/* gallery */
.gallery-grid { display: grid; gap: 1rem; align-items: start; }
.gallery-three .gallery-grid { grid-template-columns: repeat(3, minmax(0, 1fr)); }
.gallery-two .gallery-grid { grid-template-columns: repeat(2, minmax(0, 1fr)); }
.gallery-feature .gallery-grid { grid-template-columns: 1.25fr 0.8fr 1.25fr; }
.gallery figure { margin: 0; }
.gallery img { width: 100%; aspect-ratio: 3 / 2; object-fit: cover; border-radius: var(--radius); }
.gallery-feature img { aspect-ratio: 4 / 3; }
.gallery-feature figure:nth-child(2) img { aspect-ratio: 3 / 3.55; }
.gallery figcaption, .gallery .note { font-size: 0.95rem; padding-top: 0.5rem; }
.gallery .note { margin: 0.4rem 0 0; opacity: 0.85; }

/* stats-3 */
.stats-3 dl { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 1.5rem 2.5rem; margin: 0; }
.stats-3 dl > div { border-top: 6px solid var(--roof); padding-top: 1rem; }
.stats-3 dt { font: 700 1.3rem/1.15 var(--display); margin-bottom: 0.4rem; }
.stats-3 dd { margin: 0; }

/* donate-band */
.donate-band { background: var(--butter); text-align: center; }
.donate-band > * { margin-inline: auto; }
.donate-band h2 { max-width: 18ch; }
.donate-band p { font-size: 1.2rem; }
.meter { max-width: 40rem; height: 1.6rem; background: #fff; border: 2px solid var(--ink); border-radius: 999px; overflow: hidden; margin-block: 1.5rem 0.6rem; }
.meter-fill { height: 100%; background: var(--roof); border-right: 2px solid var(--ink); }
.donate-band .meter-label { font-size: 1.05rem; }

/* other-ways */
.ways { list-style: none; margin: 2rem 0 0; padding: 0; border-top: 2px solid var(--ink); }
.ways li {
  display: grid;
  grid-template-columns: minmax(0, 0.8fr) minmax(0, 1.4fr) auto;
  gap: 0.5rem 2rem;
  align-items: baseline;
  padding: 1.4rem 0;
  border-bottom: 2px solid var(--ink);
}
.ways h3, .ways p { margin: 0; }
.go { font-weight: 700; white-space: nowrap; }

/* supporters */
.supporters h3 { margin-top: 2rem; font-size: 1.05rem; font-family: var(--body); }
.names { max-width: 70ch; }
.names-big { font: 700 clamp(1.3rem, 2.4vw, 1.75rem)/1.3 var(--display); }

@media (max-width: 52rem) {
  .hero { grid-template-columns: 1fr; }
  .hero-text { padding-bottom: 0; }
  .cottage { justify-self: center; }
  .prose.split, .stats-3 dl,
  .gallery-three .gallery-grid, .gallery-two .gallery-grid { grid-template-columns: 1fr; }
  .gallery-feature .gallery-grid { grid-template-columns: 1fr 1fr; }
  .gallery-feature figure:nth-child(2) { order: 3; grid-column: 1 / -1; }
  .gallery-feature figure:nth-child(2) img { aspect-ratio: 16 / 9; }
  .ways li { grid-template-columns: 1fr; }
}

/* policy: terms, privacy, accessibility */
.policy > * { max-width: 46rem; }
.policy .when { font-weight: 700; }
.policy-intro { font-size: 1.2rem; }
.policy-sections { list-style: none; margin: 2.5rem 0 0; padding: 0; counter-reset: policy; }
.policy-sections > li { counter-increment: policy; border-top: 2px solid var(--ink); padding: 1.4rem 0 0.6rem; }
.policy-sections h2 { font-size: 1.45rem; letter-spacing: -0.01em; }
.policy-sections h2::before { content: counter(policy) ". "; }
.policy-sections ul { margin: 0 0 1em; padding-left: 1.2rem; }
.policy-sections ul li { margin-bottom: 0.3rem; }
