/* ==========================================================================
   lewestown.com/lewes_history/ -- archive section stylesheet
   Design intent: an archival finding aid, not a travel page. Related to the
   main site (Spectral / IBM Plex) but quieter: no lantern-gold, no cards,
   no CTAs. One signature element: the "archive record" provenance card.
   This file is served unhashed from /lewes_history/archive.css.
   ========================================================================== */

:root {
  --paper: #f7f4ee;      /* warm chalk paper */
  --ink: #26292d;        /* flint ink */
  --flint: #5b6570;      /* secondary text */
  --rule: #d9d3c7;       /* hairline rules */
  --harbor: #33586e;     /* links: muted bay slate, NOT lantern gold */
  --harbor-dark: #24404f;
  --record-bg: #efede6;  /* provenance record card */
  --record-edge: #c9c2b2;
}

* { box-sizing: border-box; }

html { background: var(--paper); }

body {
  margin: 0;
  font-family: "IBM Plex Sans", system-ui, sans-serif;
  font-size: 1.0625rem;
  line-height: 1.65;
  color: var(--ink);
  -webkit-font-smoothing: antialiased;
}

a { color: var(--harbor); text-decoration-thickness: 1px; text-underline-offset: 2px; }
a:hover { color: var(--harbor-dark); }
a:focus-visible { outline: 2px solid var(--harbor); outline-offset: 2px; }

/* --- masthead ----------------------------------------------------------- */
.masthead {
  border-bottom: 1px solid var(--rule);
  padding: 0.9rem 1.25rem;
}
.masthead-inner {
  max-width: 44rem; margin: 0 auto;
  display: flex; justify-content: space-between; align-items: baseline;
  gap: 1rem; flex-wrap: wrap;
}
.masthead a { text-decoration: none; }
.brand {
  font-family: "Spectral", Georgia, serif;
  font-weight: 600; font-size: 1.05rem; color: var(--ink); letter-spacing: 0.01em;
}
.section-label {
  font-family: "IBM Plex Mono", monospace;
  font-size: 0.72rem; letter-spacing: 0.14em; text-transform: uppercase;
  color: var(--flint);
}

/* --- layout ------------------------------------------------------------- */
main { max-width: 44rem; margin: 0 auto; padding: 2.25rem 1.25rem 3.5rem; }

/* --- signature element: the archive record card ------------------------- */
.record {
  background: var(--record-bg);
  border: 1px solid var(--record-edge);
  border-left: 3px solid var(--flint);
  padding: 1rem 1.15rem;
  margin: 0 0 2.25rem;
  font-size: 0.9rem;
}
.record-label {
  font-family: "IBM Plex Mono", monospace;
  font-size: 0.68rem; letter-spacing: 0.16em; text-transform: uppercase;
  color: var(--flint); margin: 0 0 0.6rem;
}
.record dl { margin: 0; display: grid; grid-template-columns: 7.5rem 1fr; row-gap: 0.3rem; column-gap: 0.75rem; }
.record dt { font-family: "IBM Plex Mono", monospace; font-size: 0.72rem; color: var(--flint); text-transform: uppercase; letter-spacing: 0.08em; padding-top: 0.15rem; }
.record dd { margin: 0; }
.record p { margin: 0.75rem 0 0; color: var(--ink); }
@media (max-width: 480px) { .record dl { grid-template-columns: 1fr; row-gap: 0.1rem; } .record dt { margin-top: 0.45rem; } }

/* --- typography ---------------------------------------------------------- */
h1 {
  font-family: "Spectral", Georgia, serif;
  font-weight: 600; font-size: 2rem; line-height: 1.2;
  margin: 0 0 0.4rem; letter-spacing: -0.01em;
}
.byline {
  font-family: "IBM Plex Mono", monospace;
  font-size: 0.78rem; color: var(--flint); margin: 0 0 2rem;
}
h2 {
  font-family: "Spectral", Georgia, serif;
  font-weight: 600; font-size: 1.35rem; line-height: 1.3;
  margin: 2.4rem 0 0.7rem;
}
p { margin: 0 0 1.1rem; }

.summary {
  border-top: 1px solid var(--rule); border-bottom: 1px solid var(--rule);
  padding: 1rem 0; margin: 0 0 1.75rem;
  font-size: 1.05rem;
}
.summary p { margin: 0; }

/* --- sources & notes ------------------------------------------------------ */
.sources { border-top: 1px solid var(--rule); margin-top: 2.75rem; padding-top: 1.25rem; font-size: 0.92rem; }
.sources h2 { margin-top: 0; font-size: 1.1rem; }
.sources ul { padding-left: 1.15rem; margin: 0.5rem 0 0; }
.sources li { margin-bottom: 0.45rem; }

.note {
  border: 1px solid var(--rule);
  padding: 0.9rem 1.1rem; margin: 1.75rem 0;
  font-size: 0.92rem; color: var(--flint);
}
.note p { margin: 0 0 0.6rem; } .note p:last-child { margin: 0; }

/* --- index table (hub page) ---------------------------------------------- */
.holdings { width: 100%; border-collapse: collapse; margin: 1.25rem 0 0; font-size: 0.95rem; }
.holdings th {
  text-align: left; font-family: "IBM Plex Mono", monospace;
  font-size: 0.7rem; letter-spacing: 0.12em; text-transform: uppercase;
  color: var(--flint); font-weight: 400;
  border-bottom: 1px solid var(--rule); padding: 0.4rem 0.75rem 0.4rem 0;
}
.holdings td { border-bottom: 1px solid var(--rule); padding: 0.65rem 0.75rem 0.65rem 0; vertical-align: top; }
.holdings td:first-child a { font-weight: 600; }
@media (max-width: 560px) {
  .holdings, .holdings tbody, .holdings tr, .holdings td { display: block; }
  .holdings thead { display: none; }
  .holdings tr { border-bottom: 1px solid var(--rule); padding: 0.6rem 0; }
  .holdings td { border: 0; padding: 0.1rem 0; }
}

/* --- footer --------------------------------------------------------------- */
.archive-footer {
  border-top: 1px solid var(--rule);
  margin-top: 3rem; padding: 1.5rem 1.25rem 2.5rem;
  font-size: 0.88rem; color: var(--flint);
}
.archive-footer-inner { max-width: 44rem; margin: 0 auto; }
.archive-footer p { margin: 0 0 0.8rem; }

@media (prefers-reduced-motion: reduce) { * { transition: none !important; } }
@media print { .masthead, .archive-footer { display: none; } }
