/* ============================================================
   TOXUESURE — SHARED STYLESHEET
   Used across all pages: index, articles, books, about
   ============================================================ */

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

:root {
  --ink:       #0E0E0D;
  --base:      #F7F6F2;
  --mid:       #8A8880;
  --rule:      #DDDBD5;
  --accent:    #1B3A5C;
  --accent-lt: #2D5F8A;
  --warm:      #F0EDE6;
  --serif:     'DM Serif Display', 'Playfair Display', Georgia, serif;
  --sans:      'Inter', system-ui, sans-serif;
  --lead:      1.65;
}

html { scroll-behavior: smooth; }

body {
  background: var(--base);
  color: var(--ink);
  font-family: var(--sans);
  font-size: 16px;
  line-height: var(--lead);
  -webkit-font-smoothing: antialiased;
}

a { color: inherit; }
img { max-width: 100%; display: block; }

/* ── TICKER ─────────────────────────────────────────────── */
.ticker-wrap {
  background: var(--ink);
  color: var(--base);
  font-size: 10.5px;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  padding: 7px 0;
  overflow: hidden;
  white-space: nowrap;
}
.ticker-track {
  display: inline-flex;
  animation: ticker 40s linear infinite;
}
.ticker-item {
  display: inline-flex;
  align-items: center;
  gap: 12px;
  padding: 0 32px;
  opacity: 0.9;
}
.ticker-item span.dot {
  width: 3px; height: 3px;
  background: var(--accent-lt);
  border-radius: 50%;
  display: inline-block;
  flex-shrink: 0;
}
@keyframes ticker {
  0% { transform: translateX(0); }
  100% { transform: translateX(-50%); }
}

/* ── NAV ─────────────────────────────────────────────────── */
nav {
  border-bottom: 1px solid var(--rule);
  padding: 0 48px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  height: 64px;
  position: sticky;
  top: 0;
  background: rgba(247, 246, 242, 0.96);
  backdrop-filter: blur(10px);
  -webkit-backdrop-filter: blur(10px);
  z-index: 100;
}
.nav-wordmark {
  display: flex;
  align-items: center;
  text-decoration: none;
}
.nav-wordmark img {
  height: 32px;
  width: auto;
  display: block;
}
.nav-links {
  display: flex;
  align-items: center;
  gap: 36px;
  list-style: none;
}
.nav-links a {
  font-size: 12px;
  font-weight: 500;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  color: var(--mid);
  text-decoration: none;
  transition: color 0.2s;
}
.nav-links a:hover, .nav-links a.active { color: var(--ink); }
.nav-cta {
  font-size: 11.5px;
  font-weight: 500;
  letter-spacing: 0.1em;
  text-transform: uppercase;
  color: var(--base) !important;
  background: var(--ink);
  padding: 8px 20px;
  border-radius: 2px;
  transition: background 0.2s !important;
}
.nav-cta:hover { background: var(--accent) !important; color: var(--base) !important; }

@media (max-width: 900px) {
  nav { padding: 0 24px; }
  .nav-links { gap: 18px; }
  .nav-links li:not(:last-child) { display: none; }
}

/* ── SECTION LABEL ───────────────────────────────────────── */
.section-label {
  display: flex;
  align-items: center;
  gap: 16px;
  font-size: 10px;
  font-weight: 600;
  letter-spacing: 0.25em;
  text-transform: uppercase;
  color: var(--mid);
  margin-bottom: 32px;
}
.section-label::before {
  content: '';
  width: 24px;
  height: 1px;
  background: var(--rule);
}
.section-label::after {
  content: '';
  flex: 1;
  height: 1px;
  background: var(--rule);
}

/* ── MASTHEAD (page headers) ─────────────────────────────── */
.page-masthead {
  padding: 72px 48px 56px;
  border-bottom: 1px solid var(--rule);
}
.masthead-eyebrow {
  font-size: 10.5px;
  font-weight: 500;
  letter-spacing: 0.2em;
  text-transform: uppercase;
  color: var(--accent);
  margin-bottom: 20px;
  display: flex;
  align-items: center;
  gap: 10px;
}
.masthead-eyebrow::after {
  content: '';
  display: block;
  width: 32px;
  height: 1px;
  background: var(--accent);
}
.masthead-title {
  font-family: var(--serif);
  font-size: clamp(40px, 6vw, 80px);
  font-weight: 400;
  line-height: 1.0;
  letter-spacing: -0.02em;
  max-width: 800px;
}
.masthead-title em { font-style: italic; color: var(--accent); }
.masthead-sub {
  font-size: 16px;
  color: var(--mid);
  max-width: 560px;
  margin-top: 20px;
  line-height: 1.7;
}

@media (max-width: 900px) {
  .page-masthead { padding: 48px 24px; }
}

/* ── BREADCRUMB ──────────────────────────────────────────── */
.breadcrumb {
  padding: 24px 48px 0;
  font-size: 11px;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  color: var(--mid);
}
.breadcrumb a { color: var(--mid); text-decoration: none; }
.breadcrumb a:hover { color: var(--ink); }
@media (max-width: 900px) { .breadcrumb { padding: 20px 24px 0; } }

/* ── ARTICLE CARD GRID ───────────────────────────────────── */
.research-section {
  padding: 64px 48px;
  border-bottom: 1px solid var(--rule);
}
.research-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 1px;
  background: var(--rule);
  border: 1px solid var(--rule);
}
.research-card {
  background: var(--base);
  padding: 36px 32px;
  display: flex;
  flex-direction: column;
  transition: background 0.2s;
  cursor: pointer;
  text-decoration: none;
  color: inherit;
}
.research-card:hover { background: var(--warm); }
.card-number {
  font-size: 10px;
  font-weight: 500;
  letter-spacing: 0.2em;
  color: var(--mid);
  margin-bottom: 24px;
}
.card-category {
  font-size: 9.5px;
  font-weight: 600;
  letter-spacing: 0.22em;
  text-transform: uppercase;
  color: var(--accent);
  margin-bottom: 14px;
}
.card-title {
  font-family: var(--serif);
  font-size: 22px;
  font-weight: 400;
  line-height: 1.2;
  color: var(--ink);
  margin-bottom: 16px;
  flex: 1;
}
.card-title em { font-style: italic; }
.card-excerpt {
  font-size: 13.5px;
  line-height: 1.6;
  color: #5A5957;
  margin-bottom: 24px;
}
.card-footer {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding-top: 20px;
  border-top: 1px solid var(--rule);
}
.card-meta {
  font-size: 10.5px;
  letter-spacing: 0.08em;
  color: var(--mid);
  text-transform: uppercase;
}
.card-arrow {
  width: 20px;
  height: 20px;
  border: 1px solid var(--rule);
  display: flex;
  align-items: center;
  justify-content: center;
  transition: background 0.2s, border-color 0.2s;
  flex-shrink: 0;
}
.research-card:hover .card-arrow {
  background: var(--ink);
  border-color: var(--ink);
}
.research-card:hover .card-arrow svg path { stroke: var(--base); }

@media (max-width: 900px) {
  .research-section { padding: 48px 24px; }
  .research-grid { grid-template-columns: 1fr; }
}

/* ── EMPTY STATE ─────────────────────────────────────────── */
.empty-state {
  padding: 96px 48px;
  text-align: left;
  border-bottom: 1px solid var(--rule);
}
.empty-state-inner {
  max-width: 520px;
}
.empty-state-eyebrow {
  font-size: 10px;
  font-weight: 600;
  letter-spacing: 0.22em;
  text-transform: uppercase;
  color: var(--accent);
  margin-bottom: 20px;
}
.empty-state-title {
  font-family: var(--serif);
  font-size: clamp(28px, 3.5vw, 40px);
  font-weight: 400;
  line-height: 1.2;
  margin-bottom: 16px;
}
.empty-state-title em { font-style: italic; color: var(--accent); }
.empty-state-desc {
  font-size: 15px;
  color: var(--mid);
  line-height: 1.7;
}
@media (max-width: 900px) { .empty-state { padding: 64px 24px; } }

/* ── ARTICLE PAGE ────────────────────────────────────────── */
.article-header {
  padding: 56px 48px 0;
  max-width: 760px;
  margin: 0 auto;
}
.article-category {
  font-size: 10px;
  font-weight: 600;
  letter-spacing: 0.22em;
  text-transform: uppercase;
  color: var(--accent);
  margin-bottom: 24px;
  display: flex;
  align-items: center;
  gap: 10px;
}
.article-category::before {
  content: '';
  width: 20px;
  height: 1px;
  background: var(--accent);
}
.article-title {
  font-family: var(--serif);
  font-size: clamp(32px, 5vw, 56px);
  font-weight: 400;
  line-height: 1.08;
  letter-spacing: -0.015em;
  margin-bottom: 24px;
}
.article-title em { font-style: italic; }
.article-deck {
  font-size: 18px;
  font-weight: 300;
  line-height: 1.7;
  color: #3D3C39;
  margin-bottom: 32px;
}
.article-byline {
  display: flex;
  align-items: center;
  gap: 16px;
  padding: 24px 0;
  border-top: 1px solid var(--rule);
  border-bottom: 1px solid var(--rule);
  margin-bottom: 48px;
}
.byline-avatar {
  width: 36px;
  height: 36px;
  border-radius: 50%;
  background: var(--ink);
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 13px;
  font-weight: 600;
  color: var(--base);
  flex-shrink: 0;
}
.byline-avatar img {
  width: 16px;
  height: 16px;
  filter: brightness(0) invert(1);
}
.byline-text p:first-child { font-size: 12.5px; font-weight: 500; }
.byline-text p:last-child { font-size: 11px; color: var(--mid); letter-spacing: 0.05em; margin-top: 2px; }

.article-body {
  max-width: 720px;
  margin: 0 auto;
  padding: 0 48px 96px;
  font-size: 17px;
  line-height: 1.85;
  color: #2A2A28;
}
.article-body p { margin-bottom: 28px; }
.article-body h2 {
  font-family: var(--serif);
  font-size: 32px;
  font-weight: 400;
  margin: 56px 0 24px;
  line-height: 1.25;
}
.article-body h3 {
  font-family: var(--serif);
  font-size: 24px;
  font-weight: 400;
  margin: 40px 0 18px;
}
.article-body blockquote {
  font-family: var(--serif);
  font-size: 26px;
  font-style: italic;
  line-height: 1.4;
  color: var(--accent);
  border-left: 2px solid var(--accent);
  padding-left: 28px;
  margin: 48px 0;
}
.article-body figure { margin: 48px 0; }
.article-body figcaption {
  font-size: 12.5px;
  color: var(--mid);
  margin-top: 12px;
  line-height: 1.5;
}
.article-body .pull-stats {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 1px;
  background: var(--rule);
  border: 1px solid var(--rule);
  margin: 48px 0;
}
.article-body .pull-stat {
  background: var(--warm);
  padding: 24px 20px;
}
.article-body .pull-stat-val {
  font-family: var(--serif);
  font-size: 30px;
  color: var(--ink);
  margin-bottom: 6px;
}
.article-body .pull-stat-label {
  font-size: 10.5px;
  letter-spacing: 0.1em;
  text-transform: uppercase;
  color: var(--mid);
}
.article-divider {
  width: 100%;
  height: 1px;
  background: var(--rule);
  margin: 0;
}

@media (max-width: 900px) {
  .article-header, .article-body { padding-left: 24px; padding-right: 24px; }
  .article-body .pull-stats { grid-template-columns: 1fr; }
}

/* ── NEWSLETTER STRIP ────────────────────────────────────── */
.newsletter-section {
  padding: 80px 48px;
  border-bottom: 1px solid var(--rule);
  display: grid;
  grid-template-columns: 1fr 480px;
  gap: 64px;
  align-items: center;
}
.newsletter-heading {
  font-family: var(--serif);
  font-size: clamp(28px, 4vw, 44px);
  font-weight: 400;
  line-height: 1.12;
  letter-spacing: -0.015em;
}
.newsletter-heading em { font-style: italic; color: var(--accent); }
.newsletter-sub { font-size: 14px; color: var(--mid); margin-top: 16px; line-height: 1.6; }
.newsletter-form { display: flex; flex-direction: column; gap: 12px; }
.newsletter-input-wrap { display: flex; border: 1px solid var(--rule); background: var(--base); }
.newsletter-input-wrap input {
  flex: 1; padding: 14px 18px; border: none; background: transparent;
  font-size: 13.5px; font-family: var(--sans); color: var(--ink); outline: none;
}
.newsletter-input-wrap input::placeholder { color: var(--mid); }
.newsletter-btn {
  padding: 14px 24px; background: var(--ink); color: var(--base); border: none;
  font-size: 11px; font-weight: 600; letter-spacing: 0.15em; text-transform: uppercase;
  font-family: var(--sans); cursor: pointer; transition: background 0.2s;
}
.newsletter-btn:hover { background: var(--accent); }
.newsletter-note { font-size: 11px; color: var(--mid); letter-spacing: 0.05em; }

@media (max-width: 900px) {
  .newsletter-section { padding: 56px 24px; grid-template-columns: 1fr; }
}

/* ── FOOTER ──────────────────────────────────────────────── */
footer { padding: 56px 48px 40px; border-top: 1px solid var(--rule); }
.footer-top {
  display: grid;
  grid-template-columns: 1.4fr 1fr 1fr 1fr;
  gap: 48px;
  margin-bottom: 56px;
  padding-bottom: 40px;
  border-bottom: 1px solid var(--rule);
}
.footer-wordmark {
  margin-bottom: 16px;
}
.footer-wordmark img {
  height: 26px;
  width: auto;
  display: block;
}
.footer-tagline { font-size: 12.5px; line-height: 1.65; color: var(--mid); max-width: 280px; }
.footer-col-heading {
  font-size: 10px; font-weight: 600; letter-spacing: 0.2em;
  text-transform: uppercase; margin-bottom: 20px;
}
.footer-links { list-style: none; display: flex; flex-direction: column; gap: 10px; }
.footer-links a { font-size: 13px; color: var(--mid); text-decoration: none; transition: color 0.15s; }
.footer-links a:hover { color: var(--ink); }
.footer-bottom { display: flex; align-items: center; justify-content: space-between; flex-wrap: wrap; gap: 16px; }
.footer-copy { font-size: 11.5px; color: var(--mid); letter-spacing: 0.05em; }
.footer-legal { display: flex; gap: 28px; }
.footer-legal a { font-size: 11px; color: var(--mid); text-decoration: none; letter-spacing: 0.05em; transition: color 0.15s; }
.footer-legal a:hover { color: var(--ink); }

@media (max-width: 900px) {
  footer { padding: 48px 24px 32px; }
  .footer-top { grid-template-columns: 1fr 1fr; }
}

/* ── SHARED FADE-IN ──────────────────────────────────────── */
.fade-in { opacity: 0; transform: translateY(16px); transition: opacity 0.6s ease, transform 0.6s ease; }
.fade-in.visible { opacity: 1; transform: translateY(0); }
