/* ── Font self-hosted ── */
@font-face {
  font-family: 'Libre Baskerville';
  font-style: normal;
  font-weight: 400;
  font-display: swap;
  src: url('/fonts/libre-baskerville-v24-latin-regular.woff2') format('woff2');
}

@font-face {
  font-family: 'Libre Baskerville';
  font-style: italic;
  font-weight: 400;
  font-display: swap;
  src: url('/fonts/libre-baskerville-v24-latin-italic.woff2') format('woff2');
}

@font-face {
  font-family: 'Libre Baskerville';
  font-style: normal;
  font-weight: 700;
  font-display: swap;
  src: url('/fonts/libre-baskerville-v24-latin-700.woff2') format('woff2');
}

@font-face {
  font-family: 'DM Mono';
  font-style: normal;
  font-weight: 400;
  font-display: swap;
  src: url('/fonts/dm-mono-v16-latin-regular.woff2') format('woff2');
}

@font-face {
  font-family: 'DM Mono';
  font-style: normal;
  font-weight: 500;
  font-display: swap;
  src: url('/fonts/dm-mono-v16-latin-500.woff2') format('woff2');
}

/* ══════════════════════════════════════════════
   AnotherWorld.network — Article Template CSS
   Libre Baskerville + DM Mono
   ══════════════════════════════════════════════ */

/* ── reset ── */
*, *::before, *::after {
  box-sizing: border-box;
  margin: 0;
  padding: 0;
}

/* ── design tokens ── */
:root {
  --black:      #0a0a0a;
  --white:      #f7f5f0;
  --mid:        #4a4a4a;
  --light:      #c8c4bc;
  --serif:      'Libre Baskerville', Georgia, serif;
  --mono:       'DM Mono', 'Courier New', monospace;

  --body-size:  clamp(16px, 2.2vw, 19px);
  --small-size: clamp(13px, 1.8vw, 15px);
  --lead-size:  clamp(18px, 2.8vw, 23px);
  --h1-size:    clamp(26px, 5.5vw, 52px);
  --h2-size:    clamp(14px, 2vw, 17px);
}

/* ── base ── */
html {
  background-color: var(--white);
  color: var(--black);
  font-family: var(--serif);
  font-size: var(--body-size);
  line-height: 1.65;
  text-rendering: optimizeLegibility;
  -webkit-font-smoothing: antialiased;
  font-feature-settings: "kern" 1, "liga" 1, "onum" 1;
}

body {
  min-height: 100vh;
  padding: 0;
}

/* ── layout ── */
.page-wrap {
  max-width: 720px;
  margin: 0 auto;
  padding: 0 1.25rem;
}

/* ── site-nav ── */
.site-nav {
  border-bottom: 2px solid var(--black);
  background: var(--white);
  position: sticky;
  top: 0;
  z-index: 100;
}

.site-nav__inner {
  max-width: 720px;
  margin: 0 auto;
  padding: 0.9rem 1.25rem;
  display: flex;
  align-items: center;
  justify-content: space-between;
}

.site-nav__brand {
  display: flex;
  align-items: center;
  gap: 0.65rem;
  text-decoration: none;
}

.site-nav__logo {
  height: 36px;
  width: auto;
  display: block;
  flex-shrink: 0;
}

.site-nav__name {
  font-family: var(--serif);
  font-size: clamp(1.1rem, 3.5vw, 1.75rem);
  font-weight: 700;
  letter-spacing: -0.02em;
  line-height: 1;
  color: var(--black);
}

.site-nav__brand:hover .site-nav__name {
  text-decoration: underline;
  text-underline-offset: 3px;
}

.site-nav__share {
  display: flex;
  align-items: center;
  gap: 0.75rem;
}

.site-nav__share-btn {
  display: flex;
  align-items: center;
  justify-content: center;
  color: var(--mid);
  transition: color 0.2s;
  text-decoration: none;
}

.site-nav__share-btn:hover {
  color: var(--black);
}

.site-nav__share-btn svg {
  width: 18px;
  height: 18px;
}

@media (min-width: 600px) {
  .site-nav__inner {
    padding: 0.9rem 2rem;
  }
  .site-nav__logo { height: 40px; }
}

@media (min-width: 900px) {
  .site-nav__inner {
    padding: 0.9rem 2.5rem;
  }
  .site-nav__logo { height: 44px; }
}

/* ── skip link (a11y) ── */
.skip-link {
  position: absolute;
  top: -40px;
  left: 0;
  background: var(--black);
  color: var(--white);
  padding: 0.4rem 0.8rem;
  font-family: var(--mono);
  font-size: 0.8rem;
  z-index: 100;
  text-decoration: none;
}

.skip-link:focus {
  top: 0;
}

/* ── header image ── */
.header-image-wrap {
  margin: 0;
  overflow: hidden;
  max-height: 420px;
}

.header-image-wrap img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  object-position: center top;
  display: block;
}

/* ── image caption ── */
.img-caption {
  font-family: var(--mono);
  font-size: 0.7rem;
  color: var(--mid);
  line-height: 1.5;
  padding: 0.6rem 0;
  border-bottom: 1px solid var(--light);
  margin-bottom: 0;
}

/* ── site header ── */
.site-header {
  border-bottom: 2px solid var(--black);
  padding: 1.4rem 0 1rem;
  margin-bottom: 0;
}

/* kicker — category label above title */
.kicker {
  font-family: var(--mono);
  font-size: var(--small-size);
  font-weight: 500;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  color: var(--mid);
  display: block;
  margin-bottom: 0.9rem;
}

/* ── typography ── */
h1 {
  font-family: var(--serif);
  font-size: var(--h1-size);
  font-weight: 700;
  line-height: 1.08;
  letter-spacing: -0.02em;
  hyphens: none;
  margin-bottom: 1.1rem;
}

/* deck — italic lead under title */
.deck {
  font-size: var(--lead-size);
  font-style: italic;
  line-height: 1.45;
  color: var(--mid);
  max-width: 62ch;
  margin-bottom: 1.4rem;
}

/* byline bar */
.byline-bar {
  display: flex;
  align-items: center;
  gap: 1.4rem;
  padding: 0.85rem 0;
  border-top: 1px solid var(--light);
  border-bottom: 1px solid var(--light);
  font-family: var(--mono);
  font-size: 0.75rem;
  letter-spacing: 0.06em;
  color: var(--mid);
  flex-wrap: wrap;
}

/* ── article body ── */
article {
  padding-top: 2.2rem;
}

p {
  margin-bottom: 1.35em;
  max-width: 65ch;
  hyphens: auto;
}

/* drop-cap — apply to first <p> in article */
.first-para::first-letter {
  font-size: 3.8em;
  font-weight: 700;
  line-height: 0.82;
  float: left;
  margin-right: 0.06em;
  margin-top: 0.04em;
}

/* section headings — mono uppercase with top rule */
.section-label {
  font-family: var(--mono);
  font-size: var(--h2-size);
  font-weight: 500;
  letter-spacing: 0.1em;
  text-transform: uppercase;
  color: var(--black);
  display: block;
  margin-top: 2.8rem;
  margin-bottom: 0.6rem;
  padding-top: 1.8rem;
  border-top: 1px solid var(--black);
}

/* pull quote — left border, italic */
.pull-quote {
  border-left: 3px solid var(--black);
  margin: 2.2rem 0;
  padding: 0.6rem 0 0.6rem 1.4rem;
}

.pull-quote p {
  font-size: clamp(18px, 2.6vw, 22px);
  font-style: italic;
  line-height: 1.4;
  color: var(--black);
  margin-bottom: 0;
  max-width: 52ch;
}

/* ── sources block ── */
.sources-block {
  margin-top: 3rem;
  padding-top: 1.4rem;
  border-top: 2px solid var(--black);
}

.sources-block h2 {
  font-family: var(--mono);
  font-size: 0.72rem;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  color: var(--mid);
  margin-bottom: 0.9rem;
  font-weight: 500;
}

.sources-block p {
  font-family: var(--mono);
  font-size: 0.72rem;
  line-height: 1.6;
  color: var(--mid);
  max-width: none;
}

.sources-block a {
  color: var(--mid);
  text-decoration: none;
  word-break: break-all;
}

.sources-block a:hover {
  color: var(--black);
}

/* ── footer ── */
footer {
  margin-top: 3.5rem;
  border-top: 3px solid var(--black);
}

.footer-cta {
  padding: 2.2rem 0 1.6rem;
  border-bottom: 1px solid var(--light);
  display: flex;
  align-items: baseline;
  justify-content: space-between;
  gap: 2rem;
  flex-wrap: wrap;
}

.footer-cta__frase {
  font-family: var(--serif);
  font-style: italic;
  font-size: clamp(18px, 2.6vw, 24px);
  line-height: 1.35;
  color: var(--black);
  max-width: 38ch;
  margin: 0;
}

.footer-cta__link {
  font-family: var(--mono);
  font-size: 0.72rem;
  font-weight: 500;
  letter-spacing: 0.16em;
  text-transform: uppercase;
  color: var(--black);
  text-decoration: none;
  white-space: nowrap;
  border-bottom: 2px solid var(--black);
  padding-bottom: 2px;
  transition: color 0.15s, border-color 0.15s;
  flex-shrink: 0;
}

.footer-cta__link:hover {
  color: var(--mid);
  border-color: var(--mid);
}

.footer-base {
  padding: 1.2rem 0 2rem;
  font-family: var(--mono);
  font-size: 0.68rem;
  letter-spacing: 0.06em;
  color: var(--light);
  text-align: center;
}

/* ── responsive ── */
@media (min-width: 600px) {
  .page-wrap {
    padding: 0 2rem;
  }
}

@media (min-width: 900px) {
  .page-wrap {
    padding: 0 2.5rem;
  }

  .header-image-wrap {
    max-height: 500px;
  }

  .site-header {
    padding-top: 2rem;
  }
}

/* ── print ── */
@media print {
  html {
    background: white;
    color: black;
    font-size: 11pt;
  }

  .page-wrap {
    max-width: 100%;
    padding: 0;
  }

  .skip-link {
    display: none;
  }

  .header-image-wrap {
    max-height: 300px;
  }
}


/* ── data table ── */
.table-container {
  overflow-x: auto;
  margin: 2rem 0;
  -webkit-overflow-scrolling: touch;
}

.data-table {
  width: 100%;
  border-collapse: collapse;
  font-family: var(--mono);
  font-size: var(--small-size);
  font-variant-numeric: tabular-nums lining-nums;
}

.data-table caption {
  font-family: var(--serif);
  font-size: var(--small-size);
  font-style: italic;
  color: var(--mid);
  text-align: left;
  padding-bottom: 0.7rem;
}

.data-table thead tr {
  border-bottom: 2px solid var(--black);
}

.data-table th {
  text-align: left;
  padding: 0.5rem 1rem 0.5rem 0;
  font-weight: 500;
  letter-spacing: 0.06em;
  text-transform: uppercase;
  font-size: 0.7rem;
  color: var(--mid);
  white-space: nowrap;
}

.data-table th:last-child,
.data-table td:last-child {
  text-align: right;
}

.data-table td {
  padding: 0.7rem 1rem 0.7rem 0;
  border-bottom: 1px solid var(--light);
  vertical-align: top;
  line-height: 1.4;
}

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

.data-table .highlight-row td {
  font-weight: 500;
  color: var(--black);
}

/* ── stat callout ── */
.stat-callout {
  display: block;
  font-family: var(--mono);
  font-size: clamp(48px, 11vw, 96px);
  font-weight: 500;
  line-height: 1;
  letter-spacing: -0.03em;
  color: var(--black);
  margin: 2rem 0 0.3rem;
  font-variant-numeric: lining-nums;
}

.stat-label {
  font-family: var(--serif);
  font-style: italic;
  font-size: var(--small-size);
  color: var(--mid);
  display: block;
  margin-bottom: 2rem;
}
