:root {
  --bg: #f6f1eb;
  --surface: #fffdf9;
  --surface-strong: #fff8f1;
  --surface-muted: #f2e5d7;
  --text: #231711;
  --muted: #6d5447;
  --brand: #9f1f17;
  --brand-dark: #7e1710;
  --brand-soft: #cfb299;
  --line: #dcc7b6;
  --shadow: 0 18px 36px rgba(79, 36, 23, 0.08);
  --radius: 22px;
}

* {
  box-sizing: border-box;
}

html {
  scroll-behavior: smooth;
}

body {
  margin: 0;
  background:
    radial-gradient(circle at top left, rgba(207, 178, 153, 0.3), transparent 30rem),
    linear-gradient(180deg, #f9f4ed 0%, var(--bg) 100%);
  color: var(--text);
  font-family: Helvetica, Arial, sans-serif;
  font-size: 17px;
  line-height: 1.65;
  -webkit-text-size-adjust: 100%;
}

a {
  color: var(--brand);
  text-decoration-thickness: 0.08em;
  text-underline-offset: 0.16em;
}

a:visited {
  color: var(--brand-dark);
}

a:hover,
a:focus-visible {
  color: #c5281b;
}

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

.hero-media img,
.hero-image {
  display: block;
}

p,
li,
address,
label,
input,
select,
button {
  overflow-wrap: anywhere;
}

h1,
h2,
h3 {
  margin: 0;
  line-height: 1.05;
  color: var(--brand);
}

h1 {
  font-family: Impact, Charcoal, sans-serif;
  font-size: clamp(2.5rem, 8vw, 4.8rem);
  letter-spacing: 0.02em;
}

h2 {
  font-family: Georgia, "Times New Roman", serif;
  font-size: clamp(1.55rem, 4vw, 2.4rem);
}

h3 {
  font-family: Georgia, "Times New Roman", serif;
  font-size: 1.2rem;
}

ul {
  margin: 0;
  padding-left: 1.2rem;
}

address {
  font-style: normal;
}

.site-shell {
  width: min(1100px, calc(100% - 28px));
  margin: 0 auto;
  padding: 18px 0 36px;
}

.site-shell-compact {
  width: min(900px, calc(100% - 28px));
}

.hero {
  display: grid;
  gap: 1rem;
  padding: 0.75rem;
  background: linear-gradient(180deg, rgba(255, 248, 241, 0.96), rgba(255, 253, 249, 0.96));
  border: 1px solid rgba(220, 199, 182, 0.9);
  border-radius: calc(var(--radius) + 6px);
  box-shadow: var(--shadow);
}

.hero-media {
  position: relative;
}

.hero-image {
  width: 100%;
  border-radius: calc(var(--radius) - 8px);
  aspect-ratio: 16 / 7;
  object-fit: cover;
  object-position: center center;
}

.hero-copy {
  padding: 0.35rem 0.35rem 0.15rem;
}

.hero-copy-overlay {
  position: absolute;
  inset: 0;
  display: flex;
  flex-direction: column;
  justify-content: flex-end;
  align-items: flex-start;
  padding: clamp(1rem, 4vw, 2rem);
  border-radius: calc(var(--radius) - 8px);
  background:
    linear-gradient(180deg, rgba(24, 13, 10, 0.12) 0%, rgba(24, 13, 10, 0.28) 52%, rgba(24, 13, 10, 0.72) 100%);
}

.hero-copy-overlay .eyebrow {
  color: rgba(255, 244, 236, 0.9);
  text-shadow: 0 2px 8px rgba(0, 0, 0, 0.35);
}

.hero-copy-overlay h1 {
  max-width: 11ch;
  color: #fff6ef;
  font-size: clamp(2.3rem, 8.6vw, 7rem);
  text-shadow:
    0 3px 10px rgba(0, 0, 0, 0.4),
    0 0 1px rgba(0, 0, 0, 0.6);
}

.hero-title-main {
  white-space: nowrap;
  font-size: clamp(1.9rem, 7.8vw, 6rem);
}

.hero-copy-support {
  padding-top: 0;
}

.hero-compact .hero-image {
  aspect-ratio: 16 / 6;
}

.eyebrow,
.section-kicker {
  margin: 0 0 0.5rem;
  color: var(--muted);
  text-transform: uppercase;
  letter-spacing: 0.12em;
  font-size: 0.76rem;
  font-weight: 700;
}

.lead {
  margin: 1rem 0 0;
  max-width: 42rem;
  font-size: clamp(1rem, 2.6vw, 1.2rem);
  color: #3d2b22;
}

.section-nav {
  display: flex;
  gap: 0.65rem;
  flex-wrap: wrap;
  margin: 1rem 0 1.4rem;
}

.section-nav a {
  display: inline-flex;
  align-items: center;
  min-height: 2.5rem;
  padding: 0.55rem 0.9rem;
  border: 1px solid var(--line);
  border-radius: 999px;
  background: rgba(255, 253, 249, 0.92);
  text-decoration: none;
  font-weight: 700;
  color: var(--brand-dark);
}

.section-nav [aria-current="page"] {
  display: inline-flex;
  align-items: center;
  min-height: 2.5rem;
  padding: 0.55rem 0.9rem;
  border: 1px solid var(--line);
  border-radius: 999px;
  background: rgba(237, 162, 112, 0.16);
  font-weight: 700;
  color: var(--brand-dark);
}

main {
  display: grid;
  gap: 1rem;
}

.section {
  min-width: 0;
  padding: 1.25rem;
  background: rgba(255, 253, 249, 0.92);
  border: 1px solid var(--line);
  border-radius: var(--radius);
  box-shadow: var(--shadow);
}

.section-highlight {
  background: linear-gradient(180deg, rgba(255, 248, 241, 0.98), rgba(255, 253, 249, 0.92));
}

.section-heading {
  margin-bottom: 1rem;
}

.section p + p {
  margin-top: 0.9rem;
}

.card-grid {
  display: grid;
  gap: 1rem;
}

.card-grid-compact .card {
  min-height: 100%;
}

.card {
  padding: 1rem;
  border: 1px solid var(--line);
  border-radius: calc(var(--radius) - 6px);
  background: var(--surface);
}

.card p {
  margin: 0.7rem 0 0;
}

.card-primary-action {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-height: 2.7rem;
  padding: 0.65rem 1rem;
  border: 1px solid var(--brand-dark);
  border-radius: 999px;
  background: var(--brand);
  color: #fff8f2;
  text-decoration: none;
  font-weight: 700;
}

.card-primary-action:visited {
  color: #fff8f2;
}

.card-primary-action:hover,
.card-primary-action:focus-visible {
  background: #b7241b;
  color: #fffdf9;
}

.archive-feature-card {
  max-width: 52rem;
}

.muted {
  color: var(--muted);
}

.search-panel {
  display: grid;
  gap: 0.9rem;
  margin-top: 1.2rem;
}

.search-panel label,
.search-query {
  display: grid;
  gap: 0.42rem;
}

.search-panel span {
  font-weight: 700;
  color: #4d392f;
}

.search-panel select,
.search-panel input[type="text"],
.search-panel input[type="submit"] {
  width: 100%;
  min-height: 2.9rem;
  padding: 0.68rem 0.78rem;
  border: 1px solid #cfb6a3;
  border-radius: 14px;
  background: #fff;
  font: inherit;
  color: var(--text);
}

.search-panel input[type="submit"] {
  border-color: var(--brand-dark);
  background: var(--brand);
  color: #fff8f2;
  font-weight: 700;
  cursor: pointer;
}

.wordcloud-panel {
  margin-top: 1.25rem;
  padding: 1rem;
  border-radius: calc(var(--radius) - 6px);
  background: var(--surface-strong);
  border: 1px solid var(--line);
}

.wordcloud-intro {
  margin: 0 0 0.7rem;
  font-weight: 700;
  color: #4d392f;
}

#wordcloud {
  width: 100%;
  overflow: hidden;
}

#wordcloud svg {
  display: block;
  margin: 0 auto;
}

.link-list li + li {
  margin-top: 0.55rem;
}

.table-wrap {
  margin-top: 1rem;
  max-width: 100%;
  overflow-x: auto;
  -webkit-overflow-scrolling: touch;
}

.archive-table {
  width: 100%;
  min-width: 640px;
  background: var(--surface);
}

.archive-table th,
.archive-table td {
  padding: 0.75rem 0.85rem;
  text-align: left;
  vertical-align: top;
}

.archive-table td:nth-child(2) {
  font-family: "SFMono-Regular", Consolas, "Liberation Mono", Menlo, monospace;
  font-size: 0.92em;
}

.map-image,
.center {
  width: 100%;
  border-radius: calc(var(--radius) - 6px);
}

.site-footer {
  display: grid;
  gap: 1rem;
  margin-top: 1rem;
  padding: 1.2rem;
  background: rgba(35, 23, 17, 0.94);
  color: #f7eadc;
  border-radius: var(--radius);
}

.site-footer h2 {
  color: #ffddd0;
  font-size: 1.25rem;
  margin-bottom: 0.6rem;
}

.site-footer a,
.site-footer a:visited {
  color: #ffcab5;
}

.footer-block p,
.footer-block address {
  margin: 0.35rem 0 0;
}

pre {
  white-space: pre-wrap;
}

#responsive-img {
  width: 100%;
  height: auto;
}

th {
  color: var(--brand);
  font-family: Georgia, "Times New Roman", serif;
  font-size: 1rem;
  background-color: #ead8c7;
}

table.striped tr:nth-child(odd) {
  background-color: #f5ebdf;
}

table,
th,
td {
  border: 1px solid #b69b88;
  border-collapse: collapse;
}

tr:nth-child(odd) {
  background-color: #f5ebdf;
}

@media (min-width: 700px) {
  .hero {
    padding: 1rem;
  }

  .hero-copy-overlay h1 {
    max-width: none;
  }

  .hero-copy-support {
    max-width: 46rem;
  }

  .card-grid {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }

  .search-panel {
    grid-template-columns: repeat(2, minmax(0, 1fr));
    align-items: end;
  }

  .search-query {
    grid-column: 1 / -1;
  }

  .search-panel input[type="submit"] {
    width: fit-content;
    min-width: 12rem;
  }

  .site-footer {
    grid-template-columns: repeat(2, minmax(0, 1fr));
    align-items: start;
  }
}

@media (min-width: 980px) {
  .section {
    padding: 1.55rem;
  }

  .card-grid-compact {
    grid-template-columns: repeat(3, minmax(0, 1fr));
  }
}

@media (max-width: 699px) {
  body {
    font-size: 16px;
  }

  .site-shell,
  .site-shell-compact {
    width: min(calc(100% - 18px), 1100px);
    padding-top: 10px;
    padding-bottom: 24px;
  }

  .hero,
  .section,
  .site-footer {
    border-radius: 18px;
  }

  .hero-image {
    aspect-ratio: 16 / 8;
  }

  .hero-copy-overlay {
    padding: 0.9rem;
  }

  .hero-copy-overlay .eyebrow {
    margin-bottom: 0.25rem;
    font-size: 0.62rem;
    letter-spacing: 0.08em;
  }

  .hero-copy-overlay h1 {
    max-width: 7ch;
    font-size: clamp(1.9rem, 7vw, 3.1rem);
    line-height: 0.98;
  }

  .hero-title-main {
    max-width: none;
    font-size: clamp(1.45rem, 7vw, 2.35rem);
  }

  .archive-table {
    min-width: 560px;
  }

  .section-nav {
    margin-top: 0.9rem;
  }

  .section-nav a {
    flex: 1 1 auto;
    justify-content: center;
  }

  .section-nav [aria-current="page"] {
    flex: 1 1 auto;
    justify-content: center;
  }

  .section {
    padding: 1rem;
  }

  table {
    display: block;
    width: 100%;
    overflow-x: auto;
  }
}
