/* Mountain West Wiki — typography-first vanilla CSS */

:root {
  --bg: #fbf9f4;
  --surface: #ffffff;
  --ink: #1f2933;
  --ink-soft: #4a5562;
  --muted: #8a909a;
  --rule: #e3ddd0;
  --rule-soft: #efeadd;
  --accent: #2a4d3a;        /* deep evergreen — Mountain West */
  --accent-hover: #1a3525;
  --link: #2a4d3a;
  --link-visited: #5a4a2a;
  --highlight: #fff4d6;
  --max-width: 70ch;
}

* { box-sizing: border-box; }

html {
  font-size: 18px;
  -webkit-text-size-adjust: 100%;
  scroll-behavior: smooth;
}

body {
  margin: 0;
  background: var(--bg);
  color: var(--ink);
  font-family: "Source Serif Pro", "Source Serif 4", "Charter", "Iowan Old Style", "Georgia", serif;
  line-height: 1.65;
  font-feature-settings: "kern", "liga", "onum";
}

.site-header {
  border-bottom: 1px solid var(--rule);
  background: var(--surface);
}

.site-header .wrap {
  max-width: var(--max-width);
  margin: 0 auto;
  padding: 1.4rem 1.25rem 1.1rem;
  display: flex;
  align-items: baseline;
  justify-content: space-between;
  gap: 1rem;
  flex-wrap: wrap;
}

.site-title {
  margin: 0;
  font-size: 1.05rem;
  font-weight: 600;
  letter-spacing: 0.01em;
}

.site-title a {
  color: var(--ink);
  text-decoration: none;
  border-bottom: none;
}

.site-title a:hover {
  color: var(--accent);
}

.site-tagline {
  margin: 0;
  font-size: 0.85rem;
  color: var(--muted);
  font-style: italic;
}

main {
  max-width: var(--max-width);
  margin: 0 auto;
  padding: 2.25rem 1.25rem 4rem;
}

.breadcrumb {
  font-size: 0.88rem;
  color: var(--muted);
  margin-bottom: 1.5rem;
}

.breadcrumb a {
  color: var(--ink-soft);
}

h1, h2, h3, h4 {
  font-family: "Source Serif Pro", "Source Serif 4", "Charter", "Iowan Old Style", "Georgia", serif;
  color: var(--ink);
  line-height: 1.25;
  letter-spacing: -0.005em;
}

h1 {
  font-size: 2.05rem;
  font-weight: 700;
  margin: 0 0 1.25rem;
}

h2 {
  font-size: 1.4rem;
  font-weight: 600;
  margin: 2.4rem 0 0.75rem;
  padding-bottom: 0.35rem;
  border-bottom: 1px solid var(--rule-soft);
}

h3 {
  font-size: 1.12rem;
  font-weight: 600;
  margin: 1.85rem 0 0.4rem;
}

h4 {
  font-size: 1rem;
  font-weight: 600;
  margin: 1.5rem 0 0.35rem;
  color: var(--ink-soft);
}

p {
  margin: 0 0 1.05rem;
}

strong {
  font-weight: 600;
  color: var(--ink);
}

em {
  font-style: italic;
}

a {
  color: var(--link);
  text-decoration: none;
  border-bottom: 1px solid rgba(42, 77, 58, 0.25);
  transition: color 0.15s, border-color 0.15s;
}

a:hover {
  color: var(--accent-hover);
  border-bottom-color: var(--accent-hover);
}

a:visited {
  color: var(--link-visited);
}

ul, ol {
  margin: 0 0 1.1rem;
  padding-left: 1.5rem;
}

li {
  margin-bottom: 0.35rem;
}

li > ul, li > ol {
  margin-top: 0.35rem;
  margin-bottom: 0.35rem;
}

blockquote {
  margin: 1.4rem 0;
  padding: 0.4rem 1.15rem;
  border-left: 3px solid var(--accent);
  background: var(--rule-soft);
  color: var(--ink-soft);
  font-style: italic;
  border-radius: 0 4px 4px 0;
}

blockquote p:last-child { margin-bottom: 0; }

hr {
  border: none;
  border-top: 1px solid var(--rule);
  margin: 2rem 0;
}

/* Tables — for growth data and footprint */
.table-wrap {
  overflow-x: auto;
  margin: 1.4rem 0;
  border: 1px solid var(--rule);
  border-radius: 4px;
  background: var(--surface);
}

table {
  width: 100%;
  border-collapse: collapse;
  font-size: 0.92rem;
  font-family: "Source Sans Pro", "Inter", -apple-system, BlinkMacSystemFont, sans-serif;
}

thead {
  background: var(--rule-soft);
}

th, td {
  padding: 0.6rem 0.85rem;
  text-align: left;
  border-bottom: 1px solid var(--rule-soft);
  vertical-align: top;
}

th {
  font-weight: 600;
  color: var(--ink);
  white-space: nowrap;
}

tbody tr:last-child td { border-bottom: none; }

tbody tr:hover {
  background: rgba(42, 77, 58, 0.03);
}

td strong {
  color: var(--accent);
}

/* Footer */
.site-footer {
  max-width: var(--max-width);
  margin: 0 auto;
  padding: 1.5rem 1.25rem 2.5rem;
  font-size: 0.82rem;
  color: var(--muted);
  text-align: center;
  font-style: italic;
  border-top: 1px solid var(--rule-soft);
}

.site-footer a {
  color: var(--ink-soft);
}

/* See-also section */
.see-also {
  margin-top: 2.5rem;
  padding-top: 1.25rem;
  border-top: 1px solid var(--rule);
}

/* Mobile */
@media (max-width: 600px) {
  html { font-size: 17px; }
  main { padding: 1.5rem 1rem 3rem; }
  h1 { font-size: 1.7rem; }
  h2 { font-size: 1.25rem; }
  table { font-size: 0.85rem; }
  th, td { padding: 0.5rem 0.6rem; }
}

/* Print */
@media print {
  body { background: white; color: black; }
  .site-header, .site-footer { border: none; }
  a { color: black; border-bottom: none; }
}
