/* The Meridian Index. Light canvas, Inter, ring cards; saffron lives only in the meridian. */

:root {
  --ink: #121a2c;
  --ink-body: #454a56;
  --ink-muted: #6e717b;
  --canvas: #fbfaf8;
  --surface: #ffffff;
  --sunk: #f2f0ec;
  --ring: #e6e2dc;
  --ring-strong: #cfcac2;
  --saffron: #e8912a;
  --saffron-text: #9a560b;
  --tint-saffron: #fcf1e2;

  --font: "Inter", ui-sans-serif, system-ui, -apple-system, sans-serif;
  --radius-card: 14px;
  --radius-well: 10px;
  --radius-button: 32px;
  --ease: cubic-bezier(0.22, 1, 0.36, 1);
  --page: 1360px;
  --gutter: clamp(16px, 4vw, 48px);
}

*, *::before, *::after { box-sizing: border-box; }
html { -webkit-text-size-adjust: 100%; scroll-behavior: smooth; scroll-padding-top: 88px; }
body {
  margin: 0;
  background: var(--canvas);
  color: var(--ink);
  font: 400 16px/1.55 var(--font);
  font-feature-settings: "cv11", "ss01";
  -webkit-font-smoothing: antialiased;
}
img { display: block; max-width: 100%; height: auto; }
a { color: inherit; }
h1, h2, h3 { font-weight: 400; margin: 0; }
p { margin: 0; }
:focus-visible { outline: 2px solid var(--ink); outline-offset: 3px; border-radius: 6px; }

.page { width: 100%; max-width: calc(var(--page) + 2 * var(--gutter)); margin: 0 auto; padding: 0 var(--gutter); }

.skip { position: absolute; left: 12px; top: -60px; z-index: 50; background: var(--ink); color: #fff; padding: 10px 16px; border-radius: var(--radius-button); text-decoration: none; }
.skip:focus { top: 12px; }

/* Buttons */
.btn {
  display: inline-flex; align-items: center; justify-content: center; gap: 8px;
  height: 44px; padding: 0 22px; border-radius: var(--radius-button);
  font: 500 15px/1 var(--font); letter-spacing: -0.01em; text-decoration: none; white-space: nowrap;
  transition: transform 0.25s var(--ease), background 0.2s, box-shadow 0.2s;
}
.btn:active { transform: scale(0.97); }
.btn-dark { background: var(--ink); color: #fff; }
.btn-dark:hover { background: #253048; }
.btn-ring { color: var(--ink); box-shadow: inset 0 0 0 1px var(--ring-strong); background: var(--surface); }
.btn-ring:hover { box-shadow: inset 0 0 0 1px var(--ink-muted); }
.btn-sm { height: 36px; padding: 0 16px; font-size: 14px; }

/* Nav */
.nav { position: sticky; top: 0; z-index: 20; background: rgba(251, 250, 248, 0.96); box-shadow: 0 1px 0 rgba(230, 226, 220, 0.6); }
.nav-inner { display: flex; align-items: center; justify-content: space-between; height: 68px; }
.brand { display: inline-flex; align-items: center; gap: 10px; text-decoration: none; font-weight: 500; font-size: 16px; letter-spacing: -0.02em; }
.mark { width: 26px; height: 26px; color: var(--ink); flex: none; }
.nav-links { display: flex; align-items: center; gap: 28px; font-size: 15px; }
.nav-links a:not(.btn) { text-decoration: none; color: var(--ink-body); }
.nav-links a:not(.btn):hover { color: var(--ink); }

/* Hero */
.hero { text-align: center; padding-top: clamp(56px, 10vw, 128px); padding-bottom: clamp(48px, 7vw, 88px); }
.hero h1 { font-size: clamp(44px, 7.6vw, 104px); line-height: 0.98; letter-spacing: -0.045em; }
.hero-sub { max-width: 560px; margin: 28px auto 0; font-size: clamp(17px, 1.5vw, 19px); color: var(--ink-body); letter-spacing: -0.01em; }
.hero-actions { display: flex; gap: 12px; justify-content: center; flex-wrap: wrap; margin-top: 36px; }

/* Desk: sticky globe beside the story list */
.desk { display: grid; grid-template-columns: minmax(0, 5fr) minmax(0, 7fr); gap: clamp(32px, 4vw, 72px); align-items: start; padding-bottom: clamp(64px, 8vw, 120px); }
.desk-globe { position: sticky; top: 96px; }
.globe-frame { margin: 0; }
.globe { display: block; width: 100%; aspect-ratio: 1; opacity: 0; transition: opacity 0.8s var(--ease); }
.globe.is-ready { opacity: 1; }
.globe-frame figcaption { margin-top: 20px; font-size: 14px; color: var(--ink-muted); text-align: center; max-width: 380px; margin-inline: auto; }
.globe-place { display: block; color: var(--ink); margin-top: 4px; }
.meridian-key { display: inline-block; width: 14px; height: 3px; border-radius: 2px; background: var(--saffron); box-shadow: 0 0 8px rgba(232, 145, 42, 0.6); vertical-align: middle; margin: -2px 8px 0 0; }
.desk-list { display: grid; gap: 20px; }

/* Cards */
.card {
  position: relative; background: var(--surface); border-radius: var(--radius-card);
  box-shadow: inset 0 0 0 1px var(--ring); padding: 12px;
  transition: box-shadow 0.25s var(--ease), transform 0.35s var(--ease);
}
.card-link { position: absolute; inset: 0; z-index: 2; border-radius: inherit; }
.card:hover, .card.is-active { box-shadow: inset 0 0 0 1px var(--ring-strong); }
.card:hover { transform: translateY(-2px); }
.well { background: var(--sunk); border-radius: var(--radius-well); overflow: hidden; }
.well img { width: 100%; height: 100%; object-fit: cover; transition: transform 0.9s var(--ease); }
.card:hover .well img { transform: scale(1.03); }

.desk-list .card:not(.card-lead) { display: grid; grid-template-columns: minmax(0, 2fr) minmax(0, 3fr); gap: 20px; }
.desk-list .card:not(.card-lead) .well { aspect-ratio: 4 / 5; }
.desk-list .card:not(.card-lead) .well img { object-position: 50% 15%; }
.card-lead .well { aspect-ratio: 4 / 3; }
.card-lead .well img { object-position: 50% 0%; }
.card-text { padding: 8px 8px 8px 4px; display: flex; flex-direction: column; gap: 14px; min-width: 0; }
.card-lead .card-text { padding: 20px 12px 12px; }
.card h2 { font-size: clamp(20px, 1.7vw, 24px); line-height: 1.22; letter-spacing: -0.025em; }
.card-lead h2 { font-size: clamp(26px, 2.6vw, 38px); line-height: 1.12; letter-spacing: -0.035em; }
.credit-line { font-size: 13px; color: var(--ink-muted); margin-top: auto; }

.meta { display: flex; flex-wrap: wrap; gap: 4px 14px; font-size: 13px; color: var(--ink-muted); letter-spacing: 0; }
.meta span + span::before { content: ""; display: inline-block; width: 3px; height: 3px; border-radius: 50%; background: var(--ring-strong); vertical-align: middle; margin: -2px 14px 0 0; }
.meta .breaking + span::before { display: none; }
.breaking { color: var(--saffron-text); font-weight: 500; display: inline-flex; align-items: center; gap: 7px; }
.breaking::before { content: ""; width: 7px; height: 7px; border-radius: 50%; background: var(--saffron); box-shadow: 0 0 0 3px rgba(232, 145, 42, 0.2); }

.lens { background: var(--tint-saffron); border-radius: var(--radius-well); padding: 12px 14px; font-size: 15px; color: var(--ink-body); line-height: 1.5; }
.lens-label { display: block; font-size: 12px; font-weight: 500; color: var(--saffron-text); margin-bottom: 2px; }

/* Closing band and footer */
.closing { padding: 0 var(--gutter); }
.closing-inner { background: var(--tint-saffron); border-radius: 24px; text-align: center; padding: clamp(56px, 8vw, 104px) 24px; max-width: var(--page); }
.closing h2 { font-size: clamp(30px, 4.2vw, 56px); letter-spacing: -0.04em; line-height: 1.05; }
.closing p { color: var(--ink-body); max-width: 460px; margin: 18px auto 30px; }

.foot { padding: clamp(56px, 7vw, 88px) 0 48px; }
.foot-inner { display: grid; grid-template-columns: 2fr 1fr 1fr 1.4fr; gap: 32px; font-size: 14px; }
.foot-brand p { color: var(--ink-muted); margin-top: 14px; max-width: 300px; }
.foot-col { display: flex; flex-direction: column; gap: 10px; }
.foot-col h3 { font-size: 13px; font-weight: 500; color: var(--ink); margin-bottom: 4px; }
.foot-col a { color: var(--ink-body); text-decoration: none; }
.foot-col a:hover { color: var(--ink); }
.foot-col p { color: var(--ink-muted); }

/* Story page */
.col { width: 100%; max-width: calc(720px + 2 * var(--gutter)); margin: 0 auto; padding: 0 var(--gutter); }
.story-head { padding-top: clamp(32px, 5vw, 64px); display: flex; flex-direction: column; gap: 20px; }
.back { font-size: 14px; color: var(--ink-muted); text-decoration: none; display: inline-flex; gap: 8px; align-self: flex-start; }
.back::before { content: "←"; }
.back:hover { color: var(--ink); }
.story-head h1 { font-size: clamp(32px, 4.4vw, 54px); line-height: 1.06; letter-spacing: -0.04em; }
.dateline { display: flex; align-items: center; gap: 16px; padding: 4px 0; }
.globe-mini { width: 64px; flex: none; }
.dateline p { font-size: 14px; color: var(--ink-muted); line-height: 1.5; }
.dateline strong { color: var(--ink); font-weight: 500; }
.story-head .lens { font-size: 17px; padding: 16px 18px; }

.fig-hero { max-width: calc(1000px + 2 * var(--gutter)); margin: clamp(32px, 5vw, 56px) auto; padding: 0 var(--gutter); }
.fig-hero .well { padding: clamp(12px, 3vw, 32px); background: var(--sunk); border-radius: var(--radius-card); }
.fig-hero img { max-height: 72vh; width: auto; margin: 0 auto; object-fit: contain; border-radius: var(--radius-well); }
figure { margin: 0; }
figcaption { font-size: 13px; color: var(--ink-muted); margin-top: 12px; line-height: 1.5; }
figcaption a { color: var(--ink-muted); text-decoration-color: var(--ring-strong); text-underline-offset: 2px; }
figcaption a:hover { color: var(--ink); }
.fig-hero figcaption { max-width: 720px; margin-inline: auto; }

.story-body { display: flex; flex-direction: column; gap: 1.1em; font-size: clamp(18px, 1.4vw, 20px); line-height: 1.62; color: var(--ink-body); letter-spacing: -0.012em; }
.fig-inline { margin: 40px 0 0; }
.fig-inline .well { aspect-ratio: 3 / 2; }

.sources { margin-top: 56px; }
.sources h2 { font-size: 13px; font-weight: 500; margin-bottom: 12px; }
.sources ul { list-style: none; margin: 0; padding: 0; display: grid; gap: 2px; }
.sources a { display: flex; justify-content: space-between; gap: 16px; padding: 10px 0; text-decoration: none; color: var(--ink-body); border-bottom: 1px solid var(--ring); }
.sources a:hover { color: var(--ink); }
.sources a span { color: var(--ink-muted); }

.story-nav { display: grid; grid-template-columns: 1fr 1fr; gap: 16px; max-width: calc(720px + 2 * var(--gutter)); margin-top: clamp(56px, 7vw, 96px); margin-bottom: clamp(56px, 7vw, 96px); }
.nav-card { display: grid; grid-template-columns: 88px minmax(0, 1fr); gap: 16px; align-items: center; text-decoration: none; }
.nav-card .well { aspect-ratio: 1; }
.nav-dir { display: block; font-size: 13px; color: var(--ink-muted); margin-bottom: 4px; }
.nav-head { display: -webkit-box; -webkit-line-clamp: 3; -webkit-box-orient: vertical; overflow: hidden; font-size: 15px; line-height: 1.35; letter-spacing: -0.015em; }

/* About */
.hero-about h1 { font-size: clamp(44px, 6.8vw, 92px); }
.principles { padding-bottom: clamp(64px, 8vw, 120px); }
.section-title { font-size: clamp(26px, 2.6vw, 36px); letter-spacing: -0.035em; margin-bottom: 28px; }
.principle-grid { display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); gap: 16px; }
.principle { padding: 24px; display: flex; flex-direction: column; gap: 10px; min-height: 220px; }
.principle .num { font-size: 13px; color: var(--ink-muted); font-variant-numeric: tabular-nums; margin-bottom: auto; padding-bottom: 28px; }
.principle h3 { font-size: 19px; letter-spacing: -0.02em; line-height: 1.25; }
.principle p { font-size: 15px; color: var(--ink-body); }
.principle:last-child { background: var(--tint-saffron); box-shadow: none; }

/* Responsive */
@media (max-width: 1100px) {
  .principle-grid { grid-template-columns: repeat(2, minmax(0, 1fr)); }
}
@media (max-width: 999px) {
  .desk { grid-template-columns: 1fr; }
  .desk-globe { position: static; max-width: 440px; width: 100%; margin: 0 auto; }
}
@media (max-width: 720px) {
  .nav-links a:not(.btn) { display: none; }
  .desk-list .card:not(.card-lead) { grid-template-columns: 1fr; }
  .desk-list .card:not(.card-lead) .well { aspect-ratio: 16 / 10; }
  .card-text { padding: 12px 8px 8px; }
  .foot-inner { grid-template-columns: 1fr 1fr; }
  .foot-brand { grid-column: 1 / -1; }
  .story-nav { grid-template-columns: 1fr; }
  .principle-grid { grid-template-columns: 1fr; }
  .principle { min-height: 0; }
}
@media (max-width: 420px) {
  .brand span { font-size: 15px; }
}
@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }
  *, *::before, *::after { transition: none !important; }
}
