/* [Name] [City] — botanical print / Enlightenment title-page feel.
   Light theme is the default; [data-theme="dark"] switches the palette. */

:root {
  --paper: #fbfbf7;
  --panel: #f3f4ec;
  --ink: #22271f;
  --ink-soft: #5a6153;
  --leaf: #2c5e3f;
  --leaf-strong: #234c33;
  --copper: #97551f;
  --rule: #d6d8ca;
  --shadow: rgba(34, 39, 31, 0.08);
}

html[data-theme="dark"] {
  --paper: #171b16;
  --panel: #1f251e;
  --ink: #e6e8de;
  --ink-soft: #a4ac9a;
  --leaf: #7fbf95;
  --leaf-strong: #9ed4b1;
  --copper: #d99a5b;
  --rule: #38402f;
  --shadow: rgba(0, 0, 0, 0.4);
}

* { box-sizing: border-box; }

html { scroll-behavior: smooth; }
@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }
  * { transition: none !important; }
}

body {
  margin: 0;
  background: var(--paper);
  color: var(--ink);
  font-family: "Spectral", Georgia, "Times New Roman", serif;
  font-size: 1.06rem;
  line-height: 1.65;
  transition: background 0.25s, color 0.25s;
}

main {
  max-width: 62rem;
  margin: 0 auto;
  padding: 0 1.25rem 4rem;
}

a { color: var(--leaf); text-underline-offset: 3px; }
a:hover { color: var(--leaf-strong); }
a:focus-visible, button:focus-visible {
  outline: 2px solid var(--copper);
  outline-offset: 3px;
}

h1, h2, h3, .wordmark-name {
  font-family: "Fraunces", Georgia, serif;
  font-weight: 600;
  line-height: 1.15;
  color: var(--ink);
}

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

/* ---------------- masthead: 18th-century title page ---------------- */

.site-header {
  border-bottom: 1px solid var(--rule);
  padding: 1.5rem 1.25rem 0;
  max-width: 66rem;
  margin: 0 auto;
}

.masthead {
  display: flex;
  align-items: flex-end;
  justify-content: space-between;
  gap: 1rem;
  padding-bottom: 1rem;
  border-bottom: 3px double var(--rule);
}

.wordmark { text-decoration: none; color: inherit; }

.wordmark-est {
  display: block;
  font-size: 0.72rem;
  letter-spacing: 0.22em;
  text-transform: uppercase;
  color: var(--copper);
  margin-bottom: 0.25rem;
}

.wordmark-name { font-size: clamp(1.4rem, 3.5vw, 2rem); }

#theme-toggle {
  font: 0.72rem/1 "Spectral", serif;
  letter-spacing: 0.14em;
  text-transform: uppercase;
  color: var(--ink-soft);
  background: none;
  border: 1px solid var(--rule);
  border-radius: 2rem;
  padding: 0.5rem 0.9rem;
  cursor: pointer;
}
#theme-toggle:hover { color: var(--ink); border-color: var(--ink-soft); }
html[data-theme="dark"] .toggle-light { display: none; }
html:not([data-theme="dark"]) .toggle-dark { display: none; }

.site-nav {
  display: flex;
  flex-wrap: wrap;
  gap: 0.25rem 1.75rem;
  padding: 0.7rem 0;
  font-size: 0.86rem;
  letter-spacing: 0.14em;
  text-transform: uppercase;
}
.site-nav a { color: var(--ink-soft); text-decoration: none; padding: 0.2rem 0; }
.site-nav a:hover { color: var(--leaf); }
.site-nav a[aria-current="page"] {
  color: var(--leaf);
  border-bottom: 2px solid var(--leaf);
}

/* ---------------- headings & structure ---------------- */

.eyebrow {
  font-size: 0.74rem;
  letter-spacing: 0.24em;
  text-transform: uppercase;
  color: var(--copper);
  margin: 0 0 0.6rem;
}

.hero { padding: 3.5rem 0 2rem; max-width: 46rem; }
.hero h1 { font-size: clamp(1.8rem, 4.5vw, 2.8rem); margin: 0 0 1rem; }
.hero-body { color: var(--ink-soft); font-size: 1.12rem; }

.page-head { padding: 3rem 0 1.5rem; }
.page-head h1 { font-size: clamp(1.8rem, 4vw, 2.6rem); margin: 0; }

.home-section { margin-top: 3rem; }

.rule-head {
  display: flex;
  align-items: baseline;
  justify-content: space-between;
  gap: 1rem;
  border-top: 3px double var(--rule);
  padding-top: 0.8rem;
  margin-bottom: 1.4rem;
}
.rule-head h2 { font-size: 1.35rem; margin: 0; }
.more { font-size: 0.85rem; text-decoration: none; letter-spacing: 0.06em; }

.section-label {
  font-size: 1.2rem;
  border-top: 3px double var(--rule);
  padding-top: 0.8rem;
  margin: 2.5rem 0 1.2rem;
}

/* ---------------- news cards: specimen labels ---------------- */

.card-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(15rem, 1fr));
  gap: 1.4rem;
}

.card {
  background: var(--panel);
  border: 1px solid var(--rule);
  border-radius: 3px;
  padding: 1.1rem 1.2rem 1.3rem;
  box-shadow: 0 1px 3px var(--shadow);
}
.card img {
  width: calc(100% + 2.4rem);
  margin: -1.1rem -1.2rem 1rem;
  border-radius: 3px 3px 0 0;
  aspect-ratio: 3 / 2;
  object-fit: cover;
}
.card h3 { font-size: 1.15rem; margin: 0.2rem 0 0.4rem; }
.card h3 a { color: inherit; text-decoration: none; }
.card h3 a:hover { color: var(--leaf); }
.card p { margin: 0.3rem 0 0; color: var(--ink-soft); font-size: 0.95rem; }

.card-meta {
  font-size: 0.78rem;
  letter-spacing: 0.16em;
  text-transform: uppercase;
  color: var(--ink-soft);
  margin: 0;
}

/* ---------------- events: accession-tag dates ---------------- */

.event-list { list-style: none; margin: 0; padding: 0; }

.event {
  display: flex;
  gap: 1.4rem;
  padding: 1.2rem 0;
  border-bottom: 1px solid var(--rule);
}

.event-when {
  flex: 0 0 4.4rem;
  text-align: center;
  border: 1px solid var(--rule);
  border-radius: 3px;
  background: var(--panel);
  padding: 0.5rem 0.3rem;
  height: fit-content;
}
.event-day {
  display: block;
  font-family: "Fraunces", Georgia, serif;
  font-size: 1.6rem;
  font-weight: 700;
  color: var(--copper);
  line-height: 1.1;
}
.event-month {
  display: block;
  font-size: 0.68rem;
  letter-spacing: 0.14em;
  text-transform: uppercase;
  color: var(--ink-soft);
}

.event-what h3 { margin: 0 0 0.3rem; font-size: 1.2rem; }
.event-list.past .event-what h3 { font-size: 1.05rem; }
.event-list.past .event-when { opacity: 0.65; }

/* ---------------- gallery ---------------- */

.gallery-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(14rem, 1fr));
  gap: 1.4rem;
}

.gallery-item { margin: 0; }
.gallery-item img {
  width: 100%;
  aspect-ratio: 4 / 3;
  object-fit: cover;
  border: 1px solid var(--rule);
  border-radius: 3px;
  box-shadow: 0 1px 3px var(--shadow);
}
.gallery-item figcaption {
  font-size: 0.9rem;
  color: var(--ink-soft);
  padding: 0.5rem 0.2rem 0;
  font-style: italic;
}

/* ---------------- members ---------------- */

.member-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(15rem, 1fr));
  gap: 1.6rem;
}

.member {
  background: var(--panel);
  border: 1px solid var(--rule);
  border-radius: 3px;
  padding: 1.2rem 1.3rem 1.4rem;
}
.member img {
  width: 6.5rem;
  height: 6.5rem;
  object-fit: cover;
  border-radius: 50%;
  border: 1px solid var(--rule);
  margin-bottom: 0.8rem;
}
.member h3 { margin: 0; font-size: 1.15rem; }
.member-role {
  font-size: 0.78rem;
  letter-spacing: 0.16em;
  text-transform: uppercase;
  color: var(--copper);
  margin: 0.25rem 0 0.6rem;
}

/* ---------------- article & prose ---------------- */

.post { max-width: 44rem; margin: 0 auto; padding-top: 3rem; }
.post h1 { font-size: clamp(1.7rem, 4vw, 2.4rem); margin: 0 0 1.2rem; }
.post-image { border-radius: 3px; border: 1px solid var(--rule); margin-bottom: 1.5rem; }

.prose p { margin: 0.7rem 0; }
.prose.small { font-size: 0.95rem; color: var(--ink-soft); }
.prose img { border-radius: 3px; border: 1px solid var(--rule); }

.backlink { margin-top: 2.5rem; }
.empty { color: var(--ink-soft); font-style: italic; }

/* ---------------- footer ---------------- */

.site-footer {
  border-top: 3px double var(--rule);
  max-width: 66rem;
  margin: 0 auto;
  padding: 2rem 1.25rem 3rem;
  text-align: center;
  color: var(--ink-soft);
  font-size: 0.95rem;
}
.footer-name {
  font-family: "Fraunces", Georgia, serif;
  font-size: 1.1rem;
  color: var(--ink);
  margin: 0 0 0.4rem;
}
.site-footer p { margin: 0.25rem 0; }
.footer-small { font-size: 0.8rem; letter-spacing: 0.1em; margin-top: 1rem; }

/* ---------------- small screens ---------------- */

@media (max-width: 34rem) {
  .masthead { flex-direction: column; align-items: flex-start; }
  #theme-toggle { align-self: flex-end; margin-top: -2.2rem; }
  .event { gap: 1rem; }
}
