:root {
  --pc-navy: #14213d;
  --pc-navy-deep: #0b1428;
  --pc-ink: #172033;
  --pc-paper: #ffffff;
  --pc-card: #ffffff;
  --pc-red: #c63d3d;
  --pc-teal: #16877b;
  --pc-gold: #f4b942;
  --pc-rule: #d8d0c1;
  --pc-hero-image: url("./assets/hero-citation-network-v1.png");
}

html { scroll-behavior: smooth; }

body {
  background:
    linear-gradient(rgba(20, 33, 61, .035) 1px, transparent 1px),
    linear-gradient(90deg, rgba(20, 33, 61, .035) 1px, transparent 1px),
    var(--pc-paper) !important;
  background-size: 32px 32px;
}

.editorial-standard {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 1rem;
  min-height: 34px;
  padding: .4rem 1rem;
  background: var(--pc-card);
  border-bottom: 1px solid var(--pc-rule);
  color: #4b5568;
  font: 600 .68rem/1.3 "IBM Plex Mono", monospace;
  letter-spacing: .055em;
  text-transform: uppercase;
}

.editorial-standard strong { color: var(--pc-teal); }
.editorial-standard span::before { content: "•"; margin-right: 1rem; color: var(--pc-gold); }
.dark .editorial-standard { background: #111d34; border-color: #30405b; color: #ced7e5; }

.dataset-audit {
  padding: .58rem 1rem;
  background: #fff5d8;
  border-bottom: 1px solid #e8cd7b;
  color: #634b0a;
  font: 500 .78rem/1.45 Inter, sans-serif;
  text-align: center;
}

.dataset-audit strong { font-weight: 700; }
.dark .dataset-audit { background: #322a14; border-color: #65541f; color: #f1dc9b; }

.dark body {
  background:
    radial-gradient(circle at 15% 0%, rgba(22, 135, 123, .13), transparent 28rem),
    radial-gradient(circle at 90% 18%, rgba(198, 61, 61, .10), transparent 28rem),
    var(--pc-navy-deep) !important;
}

header.sticky {
  background: rgba(20, 33, 61, .97) !important;
  color: white !important;
  border-bottom: 3px solid var(--pc-gold) !important;
  box-shadow: 0 5px 18px rgba(11, 20, 40, .18);
}

header.sticky [class*="text-muted"] { color: #c7d0df !important; }
header.sticky [class*="text-primary"] { color: var(--pc-gold) !important; }
header.sticky [class*="bg-secondary"] { background: rgba(255,255,255,.12) !important; }
header.sticky a, header.sticky button { color: inherit; }

main > div:first-child > section:first-child {
  position: relative;
  overflow: hidden;
}

main > div:first-child > section:first-child::before {
  content: "DAILY MEDIA-ACCOUNTABILITY BRIEF";
  display: inline-block;
  margin: 1.75rem 0 0 2rem;
  padding: .42rem .68rem;
  background: var(--pc-gold);
  color: var(--pc-navy);
  font: 700 .68rem/1 Inter, sans-serif;
  letter-spacing: .14em;
}

main h1, main h2 {
  font-family: "Source Serif 4", Georgia, serif !important;
}

main h1 {
  font-weight: 700 !important;
  letter-spacing: -.035em !important;
}

main h1 [class*="text-primary"] {
  color: var(--pc-red) !important;
}

main a button:not([class*="ghost"]):not([class*="outline"]) {
  background: var(--pc-red) !important;
  color: white !important;
  border: 1px solid #a92d2d !important;
  box-shadow: 0 4px 0 #8d2828;
}

main a button:not([class*="ghost"]):not([class*="outline"]):hover {
  transform: translateY(1px);
  box-shadow: 0 3px 0 #8d2828;
}

main article,
main [class*="bg-card"] {
  background-color: var(--pc-card) !important;
  border-color: var(--pc-rule) !important;
  box-shadow: 0 8px 24px rgba(20, 33, 61, .07);
}

.dark main article,
.dark main [class*="bg-card"] {
  background-color: #111d34 !important;
  border-color: #30405b !important;
}

main article {
  position: relative;
  border-top: 4px solid var(--pc-teal) !important;
  transition: transform .2s ease, box-shadow .2s ease;
}

main article:nth-of-type(3n+2) { border-top-color: var(--pc-red) !important; }
main article:nth-of-type(3n+3) { border-top-color: var(--pc-gold) !important; }
main article:hover {
  transform: translateY(-2px);
  box-shadow: 0 12px 28px rgba(20, 33, 61, .12);
}

main article a { text-decoration-color: var(--pc-teal) !important; }

main article footer {
  margin: .55rem -.5rem -.5rem;
  padding: .9rem 1rem 1rem !important;
  border: 1px solid #d9cdb7 !important;
  border-radius: .65rem;
  background: #f5eddd !important;
  color: var(--pc-navy) !important;
  box-shadow: inset 4px 0 0 var(--pc-gold);
}

main article footer [class*="text-muted"]:not(a),
main article footer [class*="text-foreground"]:not(a) {
  color: var(--pc-navy) !important;
}

main article footer [class*="uppercase"][class*="tracking"] {
  color: var(--pc-navy) !important;
}

main article footer a,
main article footer a:visited {
  color: #075f59 !important;
  font-weight: 650;
  text-decoration: underline !important;
  text-decoration-thickness: .09em !important;
  text-underline-offset: .18em;
  text-decoration-color: #16877b !important;
}

main article footer a:hover {
  color: #8e2d2d !important;
  text-decoration-color: #c63d3d !important;
}

main article footer a:focus-visible {
  outline: 3px solid rgba(22, 135, 123, .38);
  outline-offset: 3px;
  border-radius: .2rem;
}

.dark main article footer {
  background: #f1e7d5 !important;
  border-color: #cbbb9d !important;
  color: var(--pc-navy) !important;
}

.dark main article footer [class*="text-muted"]:not(a),
.dark main article footer [class*="text-foreground"]:not(a) {
  color: var(--pc-navy) !important;
}

.dark main article footer a,
.dark main article footer a:visited {
  color: #075f59 !important;
}

main [class*="uppercase"][class*="tracking"] {
  font-family: "IBM Plex Mono", monospace !important;
}

main [class*="rounded-full"][class*="bg-primary"],
header [class*="rounded-full"][class*="bg-primary"] {
  background: var(--pc-gold) !important;
}

main select:focus, main input:focus {
  outline: 3px solid rgba(22, 135, 123, .24) !important;
  border-color: var(--pc-teal) !important;
}

footer {
  background: var(--pc-navy) !important;
  color: #dce3ed !important;
  border-top: 5px solid var(--pc-gold) !important;
}

footer [class*="text-muted"] { color: #dce3ed !important; }

@media (max-width: 767px) {
  .editorial-standard { justify-content: flex-start; overflow-x: auto; white-space: nowrap; }
  .dataset-audit { text-align: left; }
  main > div:first-child > section:first-child::before {
    margin: 1.1rem 0 0 1rem;
    font-size: .59rem;
  }
  header.sticky nav[aria-label="Primary mobile"] {
    background: var(--pc-navy-deep);
  }
}

@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }
  *, *::before, *::after { transition: none !important; }
}

/* 2026 visual refresh: light-first editorial system */
body, main { color: var(--pc-ink); }
body { overflow-x: hidden; }
.dark body, .dark main { color: #edf1f6; }

header.sticky {
  background: rgba(255,255,255,.97) !important;
  color: var(--pc-navy) !important;
  border-bottom: 2px solid #d3c49f !important;
  box-shadow: 0 5px 18px rgba(11,20,40,.10);
}
header.sticky [class*="text-muted"] { color: #5d6677 !important; }
header.sticky [class*="text-primary"] { color: #9b6b05 !important; }
header.sticky [class*="bg-secondary"] { background: #f0eadf !important; }
.dark header.sticky { background: rgba(17,29,52,.97) !important; color: white !important; border-color: var(--pc-gold) !important; }
.dark header.sticky [class*="text-muted"] { color: #c7d0df !important; }
.dark header.sticky [class*="bg-secondary"] { background: rgba(255,255,255,.12) !important; }

.pc-original-theme-toggle { display: none !important; }
.pc-theme-toggle {
  display: inline-flex;
  align-items: center;
  gap: .42rem;
  padding: .5rem .72rem;
  border: 1px solid var(--pc-rule);
  border-radius: 999px;
  background: var(--pc-card);
  color: var(--pc-navy);
  font: 700 .68rem/1 Inter, sans-serif;
  letter-spacing: .02em;
}
.dark .pc-theme-toggle { background: #172642; border-color: #40506d; color: #f8f3e8; }

main a[href="#/cases"] button {
  background: var(--pc-red) !important;
  color: white !important;
  border-color: #a92d2d !important;
  box-shadow: 0 4px 0 #8d2828 !important;
}

main > div:first-child > section:first-child {
  background:
    linear-gradient(90deg, #fff 0%, #fff 56%, rgba(255,255,255,.96) 66%, rgba(255,255,255,.22) 82%, rgba(255,255,255,0) 100%),
    var(--pc-hero-image) right center / cover no-repeat !important;
  border-bottom: 1px solid var(--pc-rule);
}
.dark main > div:first-child > section:first-child {
  background:
    linear-gradient(90deg, rgba(11,20,40,.99) 0%, rgba(11,20,40,.96) 48%, rgba(11,20,40,.52) 76%, rgba(11,20,40,.28) 100%),
    var(--pc-hero-image) right center / cover no-repeat !important;
}
main h1 {
  max-width: 15ch;
  color: var(--pc-navy) !important;
  font-size: clamp(2.7rem, 6vw, 5.8rem) !important;
  line-height: .96 !important;
}
.dark main h1 { color: #fffdf8 !important; }

main article h3 {
  color: var(--pc-navy) !important;
  font: 700 clamp(1.28rem,2vw,1.72rem)/1.14 "Source Serif 4", Georgia, serif !important;
  letter-spacing: -.018em;
}
.dark main article h3 { color: #fffdf8 !important; }
main article [class*="uppercase"][class*="tracking"] { color: #5b6473 !important; font-weight: 700 !important; }
.dark main article [class*="uppercase"][class*="tracking"] { color: #b9c4d5 !important; }

.pc-trust-strip {
  display: grid;
  grid-template-columns: repeat(5,minmax(0,1fr));
  max-width: 80rem;
  margin: 1.35rem auto 0;
  border: 1px solid var(--pc-rule);
  border-radius: .9rem;
  background: #fff;
  box-shadow: 0 8px 22px rgba(20,33,61,.06);
  overflow: hidden;
}
.pc-trust-strip > * { display: flex; flex-direction: column; gap: .2rem; padding: 1rem 1.1rem; border-right: 1px solid var(--pc-rule); color: inherit; text-decoration: none; }
.pc-trust-strip > *:last-child { border-right: 0; background: #fff; box-shadow: inset 0 3px 0 var(--pc-gold); }
.pc-trust-strip strong { color: var(--pc-navy); font: 700 .78rem/1.2 "IBM Plex Mono", monospace; text-transform: uppercase; letter-spacing: .06em; }
.pc-trust-strip span { color: #5f6673; font: 500 .78rem/1.35 Inter, sans-serif; }
.dark .pc-trust-strip { background: #111d34; border-color: #30405b; }
.dark .pc-trust-strip > * { border-color: #30405b; }
.dark .pc-trust-strip > *:last-child { background: #322a14; }
.dark .pc-trust-strip strong { color: #fff; }
.dark .pc-trust-strip span { color: #cbd4e0; }

.pc-latest-brief {
  max-width: 80rem;
  margin: 4.5rem auto 2.4rem;
  padding: 1.5rem 1.65rem 1.65rem;
  border-left: 5px solid var(--pc-gold);
  background: var(--pc-navy);
  color: white;
  box-shadow: 0 18px 42px rgba(20,33,61,.16);
}
.pc-brief-kicker { margin-bottom: .8rem; color: #f4cc73; font: 700 .69rem/1 "IBM Plex Mono", monospace; letter-spacing: .12em; text-transform: uppercase; }
.pc-brief-grid { display: grid; grid-template-columns: 1.6fr 1fr; gap: 2rem; align-items: end; }
.pc-latest-brief h2 { margin: 0; color: white !important; font-size: clamp(1.8rem,3vw,2.7rem) !important; line-height: 1.05 !important; }
.pc-latest-brief p { max-width: 65rem; margin: .65rem 0 0; color: #d9e1ed; line-height: 1.6; }
.pc-brief-facts { display: grid; grid-template-columns: repeat(3,1fr); gap: .6rem; }
.pc-brief-facts span { padding: .7rem; border: 1px solid rgba(255,255,255,.16); color: #d9e1ed; font: 600 .74rem/1.3 Inter,sans-serif; }
.pc-brief-facts b { display: block; color: white; font: 700 1.3rem/1 "Source Serif 4",serif; }

@media (max-width: 767px) {
  .pc-theme-toggle { margin-right: .7rem; padding: .48rem; }
  .pc-theme-toggle span:last-child { display: none; }
  main > div:first-child > section:first-child { background-position: 72% center !important; background-size: cover !important; }
  .pc-trust-strip { grid-template-columns: 1fr 1fr; margin: .8rem 1rem 0; }
  .pc-trust-strip > * { border-bottom: 1px solid var(--pc-rule); }
  .pc-trust-strip > *:last-child { grid-column: 1 / -1; }
  .pc-latest-brief { margin: 3rem 1rem 1.5rem; }
  .pc-brief-grid { grid-template-columns: 1fr; }
  .pc-brief-facts { grid-template-columns: 1fr; }
}

html:not(.dark) body {
  background: #fff !important;
  background-image: none !important;
}

html:not(.dark) .min-h-screen.bg-background,
html:not(.dark) header.sticky,
html:not(.dark) main,
html:not(.dark) main article,
html:not(.dark) main [class*="bg-card"] {
  background-color: #fff !important;
}

html:not(.dark) header.sticky {
  backdrop-filter: none !important;
}

html:not(.dark) .dataset-audit {
  background: #fff !important;
  border-color: #d7b34f;
  color: var(--pc-navy);
}

html:not(.dark) .pc-trust-strip,
html:not(.dark) .pc-trust-strip > * {
  background-color: #fff !important;
}
