/* =========================================================
   CENTS & SENSIBILITY — site styles
   v1.0
   ========================================================= */

:root {
  --navy: #1F3864;
  --navy-deep: #14254a;
  --ink: #1a1d24;
  --cream: #f5f1e8;
  --cream-soft: #faf6ec;
  --cream-card: #efe9da;
  --gold: #b08c44;
  --gold-bright: #e0b75c;
  --rule: #c8b896;
  --rule-soft: #e2d8c0;
  --muted: #6b6356;
  --muted-soft: #8a8174;

  --font-display: "Playfair Display", "Cormorant Garamond", Georgia, "Times New Roman", serif;
  --font-text: "Source Serif Pro", "Cormorant Garamond", Georgia, "Times New Roman", serif;
  --font-accent: "Cormorant Garamond", "EB Garamond", Georgia, serif;
  --font-ui: "Inter", -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif;
  --font-mono: "JetBrains Mono", ui-monospace, "SF Mono", Menlo, monospace;

  --content-max: 720px;
  --wide-max: 1200px;
}

* { box-sizing: border-box; }

html, body {
  margin: 0;
  padding: 0;
  background: var(--cream-soft);
  color: var(--ink);
  -webkit-font-smoothing: antialiased;
  text-rendering: optimizeLegibility;
}

body {
  font-family: var(--font-text);
  font-size: 18px;
  line-height: 1.7;
}

img { max-width: 100%; height: auto; display: block; }
a { color: var(--navy); text-decoration: none; }
a:hover { color: var(--gold); }

/* ============== HEADER ============== */
.site-header {
  background: var(--cream-soft);
  border-bottom: 1px solid var(--rule);
  position: sticky;
  top: 0;
  z-index: 50;
  backdrop-filter: saturate(140%) blur(8px);
  -webkit-backdrop-filter: saturate(140%) blur(8px);
  background: rgba(250, 246, 236, 0.92);
}
.site-header__inner {
  max-width: var(--wide-max);
  margin: 0 auto;
  padding: 22px 40px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 24px;
}
.site-header__logo img {
  height: 56px;
  width: auto;
}
.site-nav {
  display: flex;
  align-items: center;
  gap: 32px;
}
.site-nav a {
  font-family: var(--font-ui);
  font-size: 11px;
  letter-spacing: 0.28em;
  text-transform: uppercase;
  color: var(--ink);
  font-weight: 500;
  opacity: 0.72;
  transition: opacity 120ms ease, color 120ms ease;
}
.site-nav a:hover,
.site-nav a.is-active {
  opacity: 1;
  color: var(--navy);
}

/* mobile nav toggle */
.nav-toggle {
  display: none;
  background: none;
  border: none;
  padding: 8px;
  cursor: pointer;
  color: var(--navy);
}
.nav-toggle svg { width: 22px; height: 22px; }

/* ============== HERO ============== */
.hero {
  max-width: var(--wide-max);
  margin: 0 auto;
  padding: 88px 40px 64px;
  border-bottom: 1px solid var(--rule-soft);
}
.hero__kicker {
  font-family: var(--font-ui);
  font-size: 11px;
  letter-spacing: 0.32em;
  text-transform: uppercase;
  color: var(--gold);
  font-weight: 600;
  margin: 0 0 18px;
}
.hero h1 {
  font-family: var(--font-display);
  font-weight: 700;
  font-size: clamp(40px, 6vw, 72px);
  line-height: 1.1;
  letter-spacing: -0.015em;
  color: var(--navy);
  margin: 0 0 22px;
}
.hero--article h1 {
  max-width: 18ch;
}
.hero h1 em {
  font-style: italic;
  color: var(--gold);
  font-weight: 500;
  padding: 0 0.04em;
}
.hero__sub {
  font-family: var(--font-accent);
  font-style: italic;
  font-size: clamp(20px, 2.5vw, 28px);
  color: var(--muted);
  margin: 0 0 32px;
  max-width: 40ch;
}
.hero__meta {
  font-family: var(--font-ui);
  font-size: 12px;
  color: var(--muted);
  letter-spacing: 0.04em;
}
.hero__intro {
  max-width: 56ch;
  margin-top: 8px;
  font-family: var(--font-text);
  font-size: 18px;
  line-height: 1.65;
  color: var(--ink);
}
.hero__intro p { margin: 0; }
.hero__meta span + span::before {
  content: "·";
  margin: 0 12px;
  color: var(--muted-soft);
}

/* ============== ARTICLE ============== */
.article {
  max-width: var(--content-max);
  margin: 0 auto;
  padding: 64px 32px 96px;
}

.article h2 {
  font-family: var(--font-display);
  font-weight: 600;
  font-size: 32px;
  line-height: 1.2;
  color: var(--navy);
  letter-spacing: -0.01em;
  margin: 64px 0 18px;
  position: relative;
}
.article h2:first-child { margin-top: 0; }
.article h2 .num {
  font-family: var(--font-ui);
  font-size: 11px;
  font-weight: 600;
  letter-spacing: 0.32em;
  text-transform: uppercase;
  color: var(--gold);
  display: block;
  margin-bottom: 10px;
}

.article h3 {
  font-family: var(--font-display);
  font-weight: 600;
  font-size: 22px;
  line-height: 1.25;
  color: var(--navy-deep);
  margin: 40px 0 12px;
  letter-spacing: -0.005em;
}

.article h4 {
  font-family: var(--font-display);
  font-style: italic;
  font-weight: 600;
  font-size: 19px;
  color: var(--navy-deep);
  margin: 32px 0 10px;
}

.article p {
  margin: 0 0 22px;
  color: var(--ink);
  text-wrap: pretty;
}
.article p:has(+ p),
.article p {
  hyphens: auto;
}

.article em { font-style: italic; }
.article strong { color: var(--navy-deep); font-weight: 600; }

.article a {
  color: var(--navy);
  border-bottom: 1px solid var(--rule);
  transition: color 120ms ease, border-color 120ms ease;
}
.article a:hover { color: var(--gold); border-bottom-color: var(--gold); }

.article blockquote {
  margin: 32px 0;
  padding: 6px 0 6px 28px;
  border-left: 2px solid var(--gold);
  font-family: var(--font-accent);
  font-style: italic;
  font-size: 22px;
  line-height: 1.45;
  color: var(--muted);
}
.article blockquote cite {
  display: block;
  margin-top: 12px;
  font-family: var(--font-ui);
  font-style: normal;
  font-size: 12px;
  letter-spacing: 0.16em;
  text-transform: uppercase;
  color: var(--muted-soft);
  font-weight: 500;
}

/* Drop cap on the first paragraph after the intro lead, optional */
.article .lede {
  font-family: var(--font-accent);
  font-style: italic;
  font-size: 24px;
  line-height: 1.5;
  color: var(--ink);
  margin: 0 0 36px;
  padding-bottom: 36px;
  border-bottom: 1px solid var(--rule-soft);
}

/* Pull quote */
.article .pullquote {
  margin: 48px -32px;
  padding: 36px 32px;
  text-align: center;
  font-family: var(--font-display);
  font-weight: 500;
  font-style: italic;
  font-size: 28px;
  line-height: 1.3;
  color: var(--navy);
  border-top: 1px solid var(--rule);
  border-bottom: 1px solid var(--rule);
}

/* Section rule */
.article hr {
  border: none;
  height: 1px;
  background: var(--rule);
  margin: 56px auto;
  width: 80px;
}

/* End mark + sources */
.article .sources {
  margin-top: 64px;
  padding-top: 32px;
  border-top: 1px solid var(--rule);
  font-family: var(--font-ui);
  font-size: 14px;
  color: var(--muted);
  line-height: 1.65;
}
.article .sources h4 {
  font-family: var(--font-ui);
  font-style: normal;
  font-size: 11px;
  letter-spacing: 0.32em;
  text-transform: uppercase;
  font-weight: 600;
  color: var(--muted);
  margin: 0 0 12px;
}

/* ============== HOMEPAGE POST LIST ============== */
.posts {
  max-width: var(--wide-max);
  margin: 0 auto;
  padding: 72px 40px 96px;
}
.posts__head {
  display: flex;
  align-items: baseline;
  justify-content: space-between;
  margin-bottom: 32px;
}
.posts__head h2 {
  font-family: var(--font-display);
  font-weight: 600;
  font-size: 28px;
  color: var(--navy);
  margin: 0;
  letter-spacing: -0.01em;
}
.posts__head .label {
  font-family: var(--font-ui);
  font-size: 11px;
  letter-spacing: 0.32em;
  text-transform: uppercase;
  color: var(--muted);
  font-weight: 600;
}

.post-list {
  list-style: none;
  margin: 0;
  padding: 0;
}
.post-card {
  display: grid;
  grid-template-columns: 120px 1fr auto;
  gap: 32px;
  align-items: baseline;
  padding: 32px 0;
  border-bottom: 1px solid var(--rule-soft);
  transition: opacity 120ms ease;
}
.post-card:hover { opacity: 0.78; }
.post-card .date {
  font-family: var(--font-ui);
  font-size: 12px;
  color: var(--muted);
  letter-spacing: 0.05em;
  padding-top: 8px;
}
.post-card .body h3 {
  font-family: var(--font-display);
  font-weight: 600;
  font-size: 28px;
  color: var(--navy);
  margin: 0 0 8px;
  line-height: 1.2;
  letter-spacing: -0.01em;
}
.post-card .body .sub {
  font-family: var(--font-accent);
  font-style: italic;
  font-size: 18px;
  color: var(--muted);
  margin: 0 0 12px;
}
.post-card .body .topic {
  font-family: var(--font-ui);
  font-size: 11px;
  letter-spacing: 0.28em;
  text-transform: uppercase;
  color: var(--gold);
  font-weight: 600;
}
.post-card .read {
  font-family: var(--font-ui);
  font-size: 12px;
  color: var(--muted);
  letter-spacing: 0.04em;
  white-space: nowrap;
  padding-top: 8px;
}

/* Featured (first card) gets the lede image treatment */
.post-card.featured {
  padding: 48px 0;
  border-top: 1px solid var(--rule);
}
.post-card.featured .body h3 {
  font-size: 44px;
  line-height: 1.1;
}
.post-card.featured .body h3 em {
  font-style: italic;
  color: var(--gold);
  font-weight: 500;
}

/* ============== ABOUT PAGE ============== */
.about {
  max-width: var(--content-max);
  margin: 0 auto;
  padding: 96px 32px 120px;
}
.about__mark { text-align: center; margin-bottom: 48px; }
.about__mark img { width: 120px; margin: 0 auto; }
.about h1 {
  font-family: var(--font-display);
  font-weight: 600;
  font-size: 48px;
  line-height: 1.1;
  color: var(--navy);
  text-align: center;
  letter-spacing: -0.015em;
  margin: 0 0 8px;
}
.about h1 em { font-style: italic; color: var(--gold); font-weight: 500; padding: 0 0.04em; }
.about__sub {
  font-family: var(--font-accent);
  font-style: italic;
  font-size: 22px;
  color: var(--muted);
  text-align: center;
  margin: 0 0 56px;
}
.about p { margin: 0 0 22px; }
.about .signature {
  margin-top: 48px;
  padding-top: 24px;
  border-top: 1px solid var(--rule);
  font-family: var(--font-accent);
  font-style: italic;
  font-size: 20px;
  color: var(--navy);
}

/* ============== POST HERO PANEL (editorial infographic) ============== */
.post-hero {
  max-width: 820px;
  margin: 0 auto 40px;
  padding: 0 32px;
}
.post-hero__panel {
  background: var(--navy);
  color: var(--cream);
  border-radius: 4px;
  padding: 40px 44px 36px;
  position: relative;
  overflow: hidden;
}
.post-hero__panel::before {
  /* faint constellation grid in the top half */
  content: "";
  position: absolute;
  inset: 0 0 50% 0;
  background:
    radial-gradient(circle at 20% 30%, rgba(224, 183, 92, 0.08) 1px, transparent 2px),
    radial-gradient(circle at 80% 50%, rgba(224, 183, 92, 0.06) 1px, transparent 2px),
    radial-gradient(circle at 45% 70%, rgba(224, 183, 92, 0.05) 1px, transparent 2px),
    radial-gradient(circle at 65% 20%, rgba(224, 183, 92, 0.06) 1px, transparent 2px),
    radial-gradient(circle at 10% 60%, rgba(224, 183, 92, 0.05) 1px, transparent 2px);
  background-size: 240px 200px, 320px 280px, 180px 160px, 280px 220px, 200px 180px;
  pointer-events: none;
}

.post-hero__coin {
  position: relative;
  z-index: 1;
  width: 64px;
  height: 64px;
  margin: 0 auto 20px;
  border: 1.5px solid var(--gold-bright);
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  flex-direction: column;
  background: var(--navy);
}
.post-hero__coin::before {
  content: "";
  position: absolute;
  inset: 4px;
  border: 1px solid rgba(224, 183, 92, 0.35);
  border-radius: 50%;
}
.post-hero__coin .glyph {
  font-family: var(--font-display);
  font-weight: 700;
  font-size: 24px;
  color: var(--gold-bright);
  line-height: 1;
  margin-top: 3px;
}
.post-hero__coin .label {
  font-family: var(--font-ui);
  font-size: 7px;
  letter-spacing: 0.32em;
  color: rgba(224, 183, 92, 0.7);
  margin-top: 2px;
}

.post-hero__title {
  position: relative;
  z-index: 1;
  font-family: var(--font-display);
  font-weight: 700;
  font-size: 30px;
  line-height: 1.05;
  letter-spacing: 0.01em;
  color: var(--cream);
  text-align: center;
  text-transform: uppercase;
  margin: 0 0 8px;
}
.post-hero__title-rule {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 10px;
  margin-bottom: 14px;
}
.post-hero__title-rule .line {
  height: 1px;
  width: 56px;
  background: var(--gold);
  opacity: 0.6;
}
.post-hero__title-rule .dot {
  width: 5px;
  height: 5px;
  border-radius: 50%;
  background: var(--gold-bright);
}
.post-hero__sub {
  position: relative;
  z-index: 1;
  font-family: var(--font-ui);
  font-size: 10px;
  font-weight: 500;
  letter-spacing: 0.28em;
  text-transform: uppercase;
  color: rgba(245, 241, 232, 0.7);
  text-align: center;
  margin: 0 0 32px;
}

.post-hero__stats {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 12px;
  margin-bottom: 28px;
  position: relative;
  z-index: 1;
}
.stat-card {
  background: rgba(20, 37, 74, 0.55);
  border: 1px solid rgba(224, 183, 92, 0.18);
  border-radius: 3px;
  padding: 14px 14px 16px;
  display: flex;
  flex-direction: column;
  align-items: center;
  text-align: center;
}
.stat-card__label {
  font-family: var(--font-ui);
  font-size: 9px;
  font-weight: 600;
  letter-spacing: 0.24em;
  text-transform: uppercase;
  color: rgba(245, 241, 232, 0.65);
  margin-bottom: 10px;
}
.stat-card__icon {
  width: 100%;
  height: 40px;
  margin-bottom: 10px;
}
.stat-card__value {
  font-family: var(--font-display);
  font-weight: 700;
  font-size: 20px;
  color: var(--gold-bright);
  letter-spacing: -0.005em;
  white-space: nowrap;
}
.stat-card__value .arrow {
  color: #d97757;
  margin-right: 4px;
}
.stat-card--alt .stat-card__value {
  color: #d97757;
}

.post-hero__divider {
  border: none;
  border-top: 1px dashed rgba(245, 241, 232, 0.2);
  margin: 0 0 18px;
  position: relative;
  z-index: 1;
}
.post-hero__chart-label {
  font-family: var(--font-ui);
  font-size: 10px;
  font-weight: 500;
  letter-spacing: 0.28em;
  text-transform: uppercase;
  color: rgba(245, 241, 232, 0.7);
  text-align: center;
  margin: 0 0 12px;
  position: relative;
  z-index: 1;
}
.post-hero__chart {
  width: 100%;
  height: auto;
  display: block;
  position: relative;
  z-index: 1;
}

.post-hero__phases {
  margin-top: 8px;
  position: relative;
  z-index: 1;
}
.post-hero__phases-bar {
  display: flex;
  height: 6px;
  border-radius: 1px;
  overflow: hidden;
  margin-bottom: 12px;
}
.post-hero__phases-bar span { display: block; height: 100%; }
.post-hero__phases-bar .p1 { background: #b8a23a; flex: 1.4; }
.post-hero__phases-bar .p2 { background: #c44b3a; flex: 2; }
.post-hero__phases-bar .p3 { background: #5780b8; flex: 2.4; }

.post-hero__phases-legend {
  display: flex;
  gap: 22px;
  font-family: var(--font-ui);
  font-size: 10px;
  letter-spacing: 0.06em;
  color: rgba(245, 241, 232, 0.7);
  font-style: italic;
}
.post-hero__phases-legend .swatch {
  display: inline-block;
  width: 9px;
  height: 9px;
  margin-right: 7px;
  vertical-align: -1px;
}

/* ============== ARTICLE FIGURES (inline diagrams) ============== */
.article figure.diagram {
  margin: 48px auto;
  text-align: center;
}
.article figure.diagram img {
  width: 100%;
  max-width: 600px;
  height: auto;
  display: block;
  margin: 0 auto;
  border-radius: 2px;
}
.article figure.diagram figcaption {
  margin-top: 14px;
  font-family: var(--font-ui);
  font-size: 12px;
  color: var(--muted);
  text-align: center;
  letter-spacing: 0.04em;
  line-height: 1.5;
}
.article figure.diagram figcaption em {
  font-family: var(--font-accent);
  font-style: italic;
  font-size: 14px;
  color: var(--navy-deep);
  display: block;
  margin-bottom: 4px;
}

/* Responsive */
@media (max-width: 760px) {
  .post-hero { padding: 0 16px; margin-bottom: 24px; }
  .post-hero__panel { padding: 36px 22px 32px; }
  .post-hero__title { font-size: 26px; }
  .post-hero__sub { font-size: 10px; margin-bottom: 28px; }
  .post-hero__stats { grid-template-columns: 1fr; gap: 12px; margin-bottom: 28px; }
  .stat-card__value { font-size: 22px; }
  .post-hero__phases-legend { flex-wrap: wrap; gap: 12px 20px; }
  .article figure.diagram { margin: 32px -8px; }
}

.site-footer {
  background: var(--navy);
  color: var(--cream);
  padding: 64px 40px 40px;
}
.site-footer__inner {
  max-width: var(--wide-max);
  margin: 0 auto;
  display: grid;
  grid-template-columns: 1fr auto;
  gap: 48px;
  align-items: start;
}
.site-footer__brand {
  display: flex;
  align-items: center;
  gap: 16px;
}
.site-footer__brand img {
  height: 48px;
  width: auto;
}
.site-footer__brand .name {
  font-family: var(--font-display);
  font-weight: 600;
  font-size: 22px;
  color: var(--cream);
}
.site-footer__brand .name em { color: var(--gold-bright); font-style: italic; font-weight: 500; padding: 0 0.05em; }
.site-footer__brand .tag {
  font-family: var(--font-ui);
  font-size: 11px;
  letter-spacing: 0.28em;
  text-transform: uppercase;
  color: rgba(245, 241, 232, 0.6);
  margin-top: 4px;
}
.site-footer__nav {
  display: flex;
  gap: 28px;
  font-family: var(--font-ui);
  font-size: 11px;
  letter-spacing: 0.28em;
  text-transform: uppercase;
  font-weight: 500;
}
.site-footer__nav a { color: rgba(245, 241, 232, 0.75); }
.site-footer__nav a:hover { color: var(--gold-bright); }
.site-footer__legal {
  grid-column: 1 / -1;
  margin-top: 48px;
  padding-top: 24px;
  border-top: 1px solid rgba(245, 241, 232, 0.15);
  font-family: var(--font-ui);
  font-size: 11px;
  color: rgba(245, 241, 232, 0.55);
  letter-spacing: 0.05em;
  display: flex;
  justify-content: space-between;
}

/* ============== RESPONSIVE ============== */
@media (max-width: 760px) {
  .site-header__inner { padding: 18px 22px; }
  .site-header__logo img { height: 44px; }
  .nav-toggle { display: inline-flex; }
  .site-nav {
    display: none;
    position: absolute;
    top: 100%;
    right: 0;
    left: 0;
    background: var(--cream-soft);
    border-bottom: 1px solid var(--rule);
    flex-direction: column;
    align-items: flex-start;
    gap: 0;
    padding: 12px 22px 22px;
  }
  .site-nav.is-open { display: flex; }
  .site-nav a { padding: 12px 0; width: 100%; }

  .hero { padding: 56px 22px 48px; }
  .article { padding: 48px 22px 72px; }
  .article .pullquote { margin: 36px -22px; padding: 28px 22px; font-size: 22px; }

  .posts { padding: 48px 22px 72px; }
  .post-card { grid-template-columns: 1fr; gap: 8px; padding: 24px 0; }
  .post-card .date, .post-card .read { padding-top: 0; }
  .post-card.featured .body h3 { font-size: 32px; }

  .about { padding: 64px 22px 80px; }
  .about h1 { font-size: 36px; }

  .site-footer { padding: 48px 22px 28px; }
  .site-footer__inner { grid-template-columns: 1fr; gap: 28px; }
  .site-footer__legal { flex-direction: column; gap: 6px; }
}

@media print {
  .site-header, .site-footer, .nav-toggle { display: none; }
  body { background: white; }
  .article { padding: 0; }
}
