/* The Review of One-Dimensional Maps — scholarly, editorial, generous with maps.
   Besley throughout; Greek and Cyrillic fall back to Source Serif 4 scaled to
   Besley's x-height ("Besley Fallback" in fonts.css). */
:root {
  --bg: #f7f1e5;
  --ink: #1d2433;
  --navy: #13294b;
  --muted: #4b4a48;
  --accent: #13294b;
  --gold: #a8742a;
  --rule: #c9b99a;
  --panel: #efe5cf;
  --body-font: "Besley", "Besley Fallback", Georgia, serif;
  --display-font: "Besley", "Besley Fallback", Georgia, serif;
  --mono-font: ui-monospace, "SF Mono", Menlo, monospace;
  --page: 76rem;
}
body { font-size: 1.1rem; }

.eyebrow, .kicker, .card-meta, .badge, .archive-list time, .archive-year h2 { font-family: var(--body-font); font-weight: 600; }
.badge { color: var(--gold); }

/* Header */
.site-header-inner { display: flex; justify-content: space-between; gap: 2rem; }
.is-home .site-header-inner { padding-block: 1.5rem 0; align-items: stretch; border-bottom: 1px solid var(--navy); }
.masthead { margin: 0; padding: .5rem 2rem 1.75rem 0; border-right: 1px solid var(--navy); color: var(--navy); line-height: 1; flex: 0 0 auto; }
.masthead-pre { display: block; font: italic 400 clamp(1.8rem, 3.6vw, 2.8rem)/1 var(--display-font); }
.masthead-main { display: block; font: 700 clamp(2.8rem, 6.2vw, 4.9rem)/.95 var(--display-font); letter-spacing: -0.02em; margin-top: .1em; }
.masthead-tagline { display: block; font: italic 400 clamp(1rem, 1.8vw, 1.3rem)/1.2 var(--display-font); margin-top: .7rem; color: var(--ink); }
.masthead-art { flex: 1 1 auto; position: relative; min-height: 12rem; display: flex; flex-direction: column; }
.masthead-art .site-nav { position: relative; z-index: 1; justify-content: flex-end; padding: .5rem 0 0; font-size: 1.1rem; }
.masthead-strip { position: absolute; inset: 0 calc(-1 * var(--gutter)) 0 0; mask-image: linear-gradient(to bottom, transparent 0, #000 35%, #000 85%, transparent), linear-gradient(to right, transparent, #000 8%); mask-composite: intersect; opacity: .9; }
.masthead-strip svg { width: 100%; height: 100%; }
.site-nav { color: var(--navy); }

.is-compact .site-header-inner { align-items: baseline; padding-block: 1.1rem; flex-wrap: wrap; }
.masthead-compact { font: 700 1.45rem/1.1 var(--display-font); color: var(--navy); text-decoration: none; }
.masthead-compact i { font-weight: 400; }
.header-band { height: 3.25rem; overflow: hidden; border-block: 1px solid var(--rule); }
.header-band svg { width: 100%; height: 100%; }

@media (max-width: 50rem) {
  .is-home .site-header-inner { flex-direction: column-reverse; }
  .masthead { border-right: 0; }
  .masthead-art { min-height: 7rem; }
}

/* Featured */
.featured { display: grid; grid-template-columns: minmax(16rem, 1fr) 2fr; gap: clamp(1.5rem, 4vw, 3rem); align-items: center; padding: 2.5rem 0; border-bottom: 1px solid var(--navy); }
.featured .eyebrow { color: var(--navy); }
.featured-title { font: 700 clamp(2.3rem, 4.8vw, 3.6rem)/1.02 var(--display-font); color: var(--navy); margin: 0 0 1rem; letter-spacing: -0.015em; }
.featured-title a { text-decoration: none; }
.featured-dek { font: italic 400 1.35rem/1.35 var(--display-font); margin: 0 0 1.5rem; }
.featured-art { display: block; aspect-ratio: 10 / 3; box-shadow: 0 1px 3px rgb(60 40 10 / .25); }
.featured-art svg { width: 100%; height: 100%; }
@media (max-width: 50rem) { .featured { grid-template-columns: 1fr; } }

/* Intro (from mockup 1) */
.intro { display: grid; grid-template-columns: 2fr 1fr; gap: 2.5rem; padding: 2.5rem 0; border-bottom: 1px solid var(--rule); }
.intro-title { font: 400 clamp(1.9rem, 3.6vw, 2.6rem)/1.1 var(--display-font); color: var(--navy); margin: 0 0 .75rem; text-wrap: balance; }
.intro p { margin: 0 0 1.5rem; max-width: 40rem; font-size: 1.2rem; line-height: 1.5; }
.button-gold { background: var(--gold); color: #fffaf0; }
.topics { list-style: none; margin: 0; padding: .25rem 0 .25rem 2rem; border-left: 1px solid var(--gold); font: italic 400 1.35rem/1.75 var(--display-font); color: var(--navy); }
@media (max-width: 50rem) { .intro { grid-template-columns: 1fr; } }

/* Recent: five columns divided by rules (mockup 1) */
.recent { padding: 2rem 0 3.5rem; }
.section-head h2 { color: var(--navy); font-weight: 500; }
.cards { grid-template-columns: repeat(auto-fit, minmax(11rem, 1fr)); gap: 0; }
.card { padding: 0 1.1rem; border-left: 1px solid var(--rule); }
.card:first-child { padding-left: 0; border-left: 0; }
.card:last-child { padding-right: 0; }
.card-art { border-radius: 0; box-shadow: 0 1px 2px rgb(60 40 10 / .2); }
.card-title { font-weight: 500; font-size: 1.3rem; color: var(--navy); margin-top: .8rem; }
.card-dek { color: var(--ink); font-size: 1rem; }
@media (max-width: 64rem) { .cards { grid-template-columns: repeat(3, 1fr); row-gap: 2rem; } .card:nth-child(3n + 1) { padding-left: 0; border-left: 0; } }
@media (max-width: 40rem) { .cards { grid-template-columns: 1fr; } .card { padding: 0; border: 0; } }

/* Footer */
.site-footer { border-top: 1px solid var(--navy); }
.site-footer-inner { padding-block: 1.5rem 2rem; }
.footer-rule { display: flex; align-items: center; gap: 1rem; margin: 0 0 1rem; font: italic 400 1.25rem/1 var(--display-font); color: var(--gold); }
.footer-rule a { color: inherit; text-decoration: none; }
.footer-rule a:hover { text-decoration: underline; text-underline-offset: .2em; text-decoration-thickness: 1px; }
.footer-rule::before, .footer-rule::after { content: ""; height: 1px; background: var(--gold); opacity: .6; }
.footer-rule::before { flex: 0 0 4rem; }
.footer-rule::after { flex: 1; }
.footer-row { display: flex; justify-content: space-between; align-items: center; gap: 1rem; flex-wrap: wrap; }
.footer-credit { margin: 0; font-style: italic; }
.footer-credit a { text-decoration: none; }
.footer-nav { display: flex; gap: 1.5rem; align-items: center; color: var(--navy); }
.footer-nav a { text-decoration: none; }
.footer-nav a:hover { text-decoration: underline; }

/* Article */
.article-title { color: var(--navy); font-weight: 700; }
.article-dek { font-style: italic; }
.prose h2, .prose h3 { color: var(--navy); font-weight: 600; }
.prose figure svg { box-shadow: 0 1px 3px rgb(60 40 10 / .25); }
