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

:root {
  /* Flat "paper" background palette (ref: research.beingbeyond.com) */
  --bg: #f7f7f7;
  --bg-alt: #fbfbfb;
  --card: #fbfbfb;
  --card-hover: #ffffff;
  --foreground: #1b1b1b;
  --muted: rgba(27, 27, 27, 0.72);
  --dim: rgba(27, 27, 27, 0.46);
  --border: rgba(27, 27, 27, 0.22);
  --border-strong: rgba(27, 27, 27, 0.46);
  --accent: #1b1b1b;
  --accent-hover: #000000;
  --accent-soft: rgba(27, 27, 27, 0.06);
  --ink: #1b1b1b;
  --panel: #fbfbfb;
  --hard-shadow: 2px 2px 0 0 #000;

  /* Category tag colors */
  --slate-bg: #f1f5f9;   --slate-fg: #475569;
  --emerald-bg: #ecfdf5; --emerald-fg: #047857;
  --violet-bg: #f5f3ff;  --violet-fg: #6d28d9;
  --amber-bg: #fffbeb;   --amber-fg: #b45309;

  --radius-sm: 0.25rem;
  --radius: 0.35rem;
  --radius-lg: 0.45rem;
  --radius-xl: 0.6rem;

  --font: "Geist", system-ui, -apple-system, "Segoe UI", sans-serif;
  --serif: "EB Garamond", Georgia, "Times New Roman", serif;
  --mono: "JetBrains Mono", "Geist Mono", ui-monospace, "SF Mono", monospace;

  --max-width: 1080px;
  --section-pad: clamp(4rem, 8vw, 7rem);
  --nav-h: 64px;
}

html {
  scroll-behavior: smooth;
  scroll-padding-top: calc(var(--nav-h) + 1rem);
  overflow-x: hidden;
}

body {
  font-family: var(--font);
  background: var(--bg);
  color: var(--foreground);
  line-height: 1.625;
  -webkit-font-smoothing: antialiased;
  text-rendering: optimizeLegibility;
  overflow-x: hidden;
}

.container {
  width: min(calc(100% - 2.5rem), var(--max-width));
  margin-inline: auto;
}

code {
  font-family: var(--mono);
  font-size: 0.85em;
  background: var(--accent-soft);
  color: var(--foreground);
  padding: 0.15em 0.45em;
  border-radius: 6px;
}

a {
  color: var(--foreground);
  text-decoration: none;
  transition: color 0.15s ease, opacity 0.15s ease;
}

/* ── Navigation ───────────────────────────────────────────────── */
.nav {
  position: sticky;
  top: 0;
  z-index: 50;
  background: rgba(247, 247, 247, 0.8);
  backdrop-filter: saturate(180%) blur(12px);
  -webkit-backdrop-filter: saturate(180%) blur(12px);
  border-bottom: 1px solid transparent;
  transition: border-color 0.2s ease, background 0.2s ease;
}

.nav.scrolled {
  background: rgba(255, 255, 255, 0.9);
  border-bottom-color: var(--border);
}

.nav-inner {
  height: var(--nav-h);
  display: flex;
  align-items: center;
  gap: 1.5rem;
}

.nav-brand {
  display: inline-flex;
  align-items: center;
  gap: 0.6rem;
  font-weight: 600;
  letter-spacing: -0.01em;
}

.nav-logo {
  height: 30px;
  width: auto;
  border-radius: 6px;
}

.nav-brand-text {
  font-size: 1.0625rem;
}

.nav-links {
  display: flex;
  align-items: center;
  gap: 1.75rem;
  margin-left: auto;
}

.nav-links a {
  font-size: 0.9rem;
  font-weight: 500;
  color: var(--muted);
}

.nav-links a:hover {
  color: var(--foreground);
}

/* ── Buttons ──────────────────────────────────────────────────── */
.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  padding: 0.7rem 1.4rem;
  border-radius: 999px;
  font-size: 0.9375rem;
  font-weight: 500;
  font-family: var(--font);
  border: 1px solid transparent;
  cursor: pointer;
  transition: background 0.18s ease, border-color 0.18s ease, color 0.18s ease, transform 0.1s ease, box-shadow 0.18s ease;
}

.btn:active {
  transform: scale(0.98);
}

.btn-sm {
  padding: 0.5rem 1.05rem;
  font-size: 0.875rem;
}

.btn-primary {
  background: var(--accent);
  color: #fff;
  box-shadow: 0 1px 2px rgba(15, 23, 42, 0.18);
}

.btn-primary:hover {
  background: var(--accent-hover);
  color: #fff;
  box-shadow: 0 4px 14px rgba(15, 23, 42, 0.22);
}

.btn-secondary {
  background: var(--card);
  color: var(--foreground);
  border-color: var(--border-strong);
}

.btn-secondary:hover {
  background: var(--accent-soft);
  border-color: var(--dim);
}

.btn-copy {
  background: var(--card);
  color: var(--foreground);
  border: 1px solid var(--border-strong);
  padding: 0.55rem 1.1rem;
  border-radius: 999px;
  font-size: 0.875rem;
}

.btn-copy:hover {
  background: var(--accent-soft);
}

.btn-copy.copied {
  border-color: #34d399;
  color: #047857;
  background: var(--emerald-bg);
}

/* ── Hero ─────────────────────────────────────────────────────── */
.hero {
  position: relative;
  padding: clamp(4rem, 9vw, 7rem) 0 clamp(3rem, 6vw, 5rem);
  text-align: center;
  overflow: hidden;
}

.hero-bg {
  position: absolute;
  inset: 0;
  pointer-events: none;
  background: var(--bg);
}

.hero-inner {
  position: relative;
  display: flex;
  flex-direction: column;
  align-items: center;
}

.badge {
  display: inline-flex;
  align-items: center;
  gap: 0.5rem;
  font-size: 0.8125rem;
  font-weight: 500;
  color: var(--muted);
  background: var(--card);
  border: 1px solid var(--border);
  padding: 0.4rem 0.95rem;
  border-radius: 999px;
  margin-bottom: 1.75rem;
  box-shadow: 0 1px 2px rgba(15, 23, 42, 0.04);
}

.badge::before {
  content: "";
  width: 7px;
  height: 7px;
  border-radius: 50%;
  background: #10b981;
  box-shadow: 0 0 0 3px rgba(16, 185, 129, 0.18);
}

.hero-title {
  font-size: var(--text-display, clamp(2.75rem, 7vw, 4.5rem));
  font-weight: 700;
  letter-spacing: -0.04em;
  line-height: 1.05;
  margin-bottom: 1rem;
  background: linear-gradient(180deg, #1e293b 0%, #0f172a 60%, #334155 100%);
  -webkit-background-clip: text;
  background-clip: text;
  color: transparent;
}

.hero-subtitle {
  font-size: clamp(1.1rem, 2.4vw, 1.5rem);
  font-weight: 500;
  color: var(--foreground);
  letter-spacing: -0.015em;
  margin-bottom: 1.5rem;
  max-width: 30ch;
}

.hero-intro {
  font-size: clamp(1rem, 1.6vw, 1.125rem);
  color: var(--muted);
  max-width: 64ch;
  margin-bottom: 2.25rem;
}

.hero-actions {
  display: flex;
  flex-wrap: wrap;
  gap: 0.85rem;
  justify-content: center;
}

/* ── Stats band ───────────────────────────────────────────────── */
.stats {
  margin-top: clamp(3rem, 6vw, 4.5rem);
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 1px;
  background: var(--border);
  border: 1px solid var(--border);
  border-radius: var(--radius-lg);
  overflow: hidden;
  width: min(100%, 720px);
  box-shadow: 0 1px 3px rgba(15, 23, 42, 0.04);
}

.stat {
  background: var(--card);
  padding: 1.6rem 1rem;
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 0.3rem;
}

.stat-num {
  font-size: clamp(1.5rem, 3.5vw, 2.25rem);
  font-weight: 700;
  letter-spacing: -0.03em;
  color: var(--foreground);
}

.stat-label {
  font-size: 0.8125rem;
  color: var(--muted);
  text-transform: uppercase;
  letter-spacing: 0.06em;
}

/* ── Sections ─────────────────────────────────────────────────── */
.section {
  padding: var(--section-pad) 0;
}

.section-alt {
  background: var(--bg-alt);
  border-top: 1px solid var(--border);
  border-bottom: 1px solid var(--border);
}

.eyebrow {
  text-align: center;
  font-size: 0.75rem;
  font-weight: 600;
  text-transform: uppercase;
  letter-spacing: 0.12em;
  color: var(--dim);
  margin-bottom: 0.75rem;
}

.section-title {
  font-size: clamp(1.75rem, 3.5vw, 2.5rem);
  font-weight: 700;
  letter-spacing: -0.03em;
  text-align: center;
  margin-bottom: 0.85rem;
}

.section-lead {
  text-align: center;
  color: var(--muted);
  max-width: 60ch;
  margin-inline: auto;
  margin-bottom: 3rem;
  font-size: 1.0625rem;
}

.section-note {
  text-align: center;
  color: var(--dim);
  font-size: 0.875rem;
  margin-top: 2rem;
}

/* ── Tags ─────────────────────────────────────────────────────── */
.tag {
  display: inline-block;
  font-size: 0.6875rem;
  font-weight: 600;
  text-transform: uppercase;
  letter-spacing: 0.06em;
  padding: 0.28rem 0.65rem;
  border-radius: 999px;
  margin-bottom: 1rem;
}

.tag-slate   { color: var(--slate-fg);   background: var(--slate-bg); }
.tag-emerald { color: var(--emerald-fg); background: var(--emerald-bg); }
.tag-violet  { color: var(--violet-fg);  background: var(--violet-bg); }
.tag-amber   { color: var(--amber-fg);   background: var(--amber-bg); }

/* ── Policies ─────────────────────────────────────────────────── */
.policy-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(264px, 1fr));
  gap: 1.25rem;
}

.policy-card {
  background: var(--card);
  border: 1px solid var(--border);
  border-radius: var(--radius-lg);
  padding: 1.6rem;
  box-shadow: 0 1px 2px rgba(15, 23, 42, 0.04);
  transition: border-color 0.18s ease, transform 0.18s ease, box-shadow 0.18s ease;
}

.policy-card:hover {
  border-color: var(--border-strong);
  box-shadow: 0 12px 30px rgba(15, 23, 42, 0.08);
  transform: translateY(-3px);
}

.policy-name {
  font-size: 1.2rem;
  font-weight: 600;
  margin-bottom: 0.55rem;
  font-family: var(--mono);
  letter-spacing: -0.01em;
}

.policy-desc {
  font-size: 0.9375rem;
  color: var(--muted);
  line-height: 1.6;
}

/* ── Authors ──────────────────────────────────────────────────── */
.author-grid {
  list-style: none;
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(210px, 1fr));
  gap: 1rem;
}

.author-card {
  background: var(--card);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  padding: 1.35rem 1.45rem;
  display: flex;
  flex-direction: column;
  gap: 0.3rem;
  box-shadow: 0 1px 2px rgba(15, 23, 42, 0.04);
  transition: border-color 0.18s ease, transform 0.18s ease, box-shadow 0.18s ease;
}

.author-card:hover {
  border-color: var(--border-strong);
  transform: translateY(-2px);
  box-shadow: 0 8px 22px rgba(15, 23, 42, 0.06);
}

.author-name {
  font-weight: 600;
  font-size: 1.0625rem;
}

.author-affiliation {
  font-size: 0.875rem;
  color: var(--muted);
}

/* ── Contributors ─────────────────────────────────────────────── */
.lang-toggle {
  display: flex;
  justify-content: center;
  gap: 0.35rem;
  margin-bottom: 2.5rem;
  padding: 0.25rem;
  background: var(--card);
  border: 1px solid var(--border);
  border-radius: 999px;
  width: fit-content;
  margin-inline: auto;
}

.lang-btn {
  padding: 0.45rem 1.15rem;
  border: none;
  border-radius: 999px;
  font-family: var(--font);
  font-size: 0.875rem;
  font-weight: 500;
  color: var(--muted);
  background: transparent;
  cursor: pointer;
  transition: background 0.15s ease, color 0.15s ease, box-shadow 0.15s ease;
}

.lang-btn:hover {
  color: var(--foreground);
}

.lang-btn.is-active {
  background: var(--accent);
  color: #fff;
  box-shadow: 0 1px 3px rgba(15, 23, 42, 0.15);
}

.contributor-content.is-hidden {
  display: none;
}

.lang-content.is-hidden {
  display: none;
}

.contributor-lead {
  margin-bottom: 2rem;
}

.contributor-callout {
  background: var(--card);
  border: 1px solid var(--border);
  border-left: 3px solid var(--accent);
  border-radius: var(--radius);
  padding: 1.25rem 1.5rem;
  max-width: 72ch;
  margin-inline: auto;
  margin-bottom: 2.5rem;
  box-shadow: 0 1px 2px rgba(15, 23, 42, 0.04);
}

.contributor-callout p {
  color: var(--foreground);
  font-size: 1rem;
  line-height: 1.65;
  margin: 0;
}

.benefit-list {
  list-style: none;
  display: flex;
  flex-direction: column;
  gap: 1rem;
  max-width: 760px;
  margin-inline: auto;
  margin-bottom: 2.5rem;
}

.benefit-item {
  display: flex;
  gap: 1.15rem;
  align-items: flex-start;
  background: var(--card);
  border: 1px solid var(--border);
  border-radius: var(--radius-lg);
  padding: 1.5rem 1.6rem;
  box-shadow: 0 1px 2px rgba(15, 23, 42, 0.04);
  transition: border-color 0.18s ease, box-shadow 0.18s ease;
}

.benefit-item:hover {
  border-color: var(--border-strong);
  box-shadow: 0 8px 22px rgba(15, 23, 42, 0.06);
}

.benefit-num {
  flex-shrink: 0;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 2rem;
  height: 2rem;
  border-radius: 50%;
  background: var(--accent-soft);
  color: var(--foreground);
  font-size: 0.875rem;
  font-weight: 600;
  font-family: var(--mono);
}

.benefit-title {
  font-size: 1.0625rem;
  font-weight: 600;
  margin-bottom: 0.4rem;
  letter-spacing: -0.01em;
}

.benefit-desc {
  font-size: 0.9375rem;
  color: var(--muted);
  line-height: 1.6;
  margin: 0;
}

.integration-band {
  background: var(--bg-alt);
  border: 1px solid var(--border);
  border-radius: var(--radius-lg);
  padding: 2rem;
  max-width: 760px;
  margin-inline: auto;
  margin-bottom: 2rem;
  text-align: center;
}

.integration-label {
  font-size: 0.75rem;
  font-weight: 600;
  text-transform: uppercase;
  letter-spacing: 0.1em;
  color: var(--dim);
  margin-bottom: 1.25rem;
}

.integration-stats {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 1px;
  background: var(--border);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  overflow: hidden;
  margin-bottom: 1.25rem;
}

.integration-stat {
  background: var(--card);
  padding: 1.25rem 0.75rem;
  display: flex;
  flex-direction: column;
  gap: 0.25rem;
}

.integration-stat dt {
  font-size: 0.8125rem;
  color: var(--muted);
  font-weight: 500;
}

.integration-stat dd {
  font-size: 1.25rem;
  font-weight: 700;
  letter-spacing: -0.02em;
  color: var(--foreground);
}

.integration-note {
  font-size: 0.9375rem;
  color: var(--muted);
  margin: 0;
}

.contributor-timeline {
  max-width: 72ch;
  margin-inline: auto;
  text-align: center;
  margin-bottom: 2.5rem;
}

.contributor-timeline p {
  font-size: 1rem;
  color: var(--muted);
  line-height: 1.65;
  margin: 0;
}

.contributor-cta {
  text-align: center;
  max-width: 520px;
  margin-inline: auto;
}

.contributor-cta-text {
  font-size: 1rem;
  color: var(--foreground);
  margin-bottom: 0.5rem;
}

.contributor-deadline {
  font-size: 0.9375rem;
  color: var(--muted);
  margin-bottom: 1.5rem;
}

.contributor-form-note {
  margin-top: 1rem;
}

/* ── Subpage (Contributors) ─────────────────────────────────────── */
.page-hero {
  position: relative;
  padding: clamp(3rem, 7vw, 5rem) 0 clamp(2rem, 4vw, 3rem);
  text-align: center;
  overflow: hidden;
  border-bottom: 1px solid var(--border);
  background: var(--bg-alt);
}

.page-hero::before {
  content: "";
  position: absolute;
  inset: 0;
  pointer-events: none;
  background: var(--bg-alt);
}

.page-hero-inner {
  position: relative;
  display: flex;
  flex-direction: column;
  align-items: center;
}

.page-back {
  align-self: flex-start;
  font-size: 0.875rem;
  font-weight: 500;
  color: var(--muted);
  margin-bottom: 1.5rem;
}

.page-back:hover {
  color: var(--foreground);
}

.page-title {
  font-size: clamp(2rem, 5vw, 3rem);
  font-weight: 700;
  letter-spacing: -0.03em;
  line-height: 1.1;
  margin-bottom: 0.75rem;
}

.page-subtitle {
  font-size: clamp(1rem, 2vw, 1.2rem);
  color: var(--muted);
  max-width: 52ch;
  margin-bottom: 2rem;
}

.page-hero .lang-toggle {
  margin-bottom: 0;
}

.page-body {
  padding-top: clamp(2.5rem, 5vw, 4rem);
}

.page-content {
  max-width: 760px;
  margin-inline: auto;
}

.page-intro {
  font-size: 1.0625rem;
  color: var(--muted);
  line-height: 1.7;
  margin-bottom: 2rem;
}

.content-heading {
  font-size: 1.25rem;
  font-weight: 600;
  letter-spacing: -0.02em;
  margin-bottom: 1.25rem;
  margin-top: 2.5rem;
}

.content-heading:first-of-type {
  margin-top: 0;
}

.timeline-list {
  list-style: none;
  display: flex;
  flex-direction: column;
  gap: 0.75rem;
  margin-bottom: 2.5rem;
}

.timeline-list li {
  display: flex;
  align-items: baseline;
  gap: 1rem;
  font-size: 0.9375rem;
  color: var(--muted);
  line-height: 1.55;
  padding: 0.85rem 1.1rem;
  background: var(--card);
  border: 1px solid var(--border);
  border-radius: var(--radius);
}

.timeline-tag {
  flex-shrink: 0;
  font-size: 0.6875rem;
  font-weight: 600;
  text-transform: uppercase;
  letter-spacing: 0.05em;
  padding: 0.25rem 0.6rem;
  border-radius: 999px;
  background: var(--slate-bg);
  color: var(--slate-fg);
}

.timeline-tag.deadline {
  background: var(--amber-bg);
  color: var(--amber-fg);
}

.nav-links a[aria-current="page"] {
  color: var(--foreground);
}

.contributor-cta .contributor-deadline {
  margin-top: 1rem;
  margin-bottom: 0;
}

/* ── Coming Soon (homepage placeholder) ─────────────────────────── */
.coming-soon-body {
  min-height: 100dvh;
}

.coming-soon {
  position: relative;
  min-height: 100dvh;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  text-align: center;
  padding: 2rem 1.25rem;
  overflow: hidden;
}

.coming-soon-inner {
  position: relative;
  display: flex;
  flex-direction: column;
  align-items: center;
  max-width: 36rem;
}

.coming-soon-logo {
  width: 64px;
  height: auto;
  border-radius: 12px;
  margin-bottom: 1.75rem;
  box-shadow: 0 4px 20px rgba(15, 23, 42, 0.08);
}

.coming-soon .hero-title {
  margin-bottom: 0.5rem;
}

.coming-soon-label {
  font-size: 0.8125rem;
  font-weight: 600;
  text-transform: uppercase;
  letter-spacing: 0.14em;
  color: var(--dim);
  margin-bottom: 1.25rem;
}

.coming-soon-text {
  font-size: 1.0625rem;
  color: var(--muted);
  line-height: 1.65;
  margin-bottom: 2rem;
  max-width: 32ch;
}

.coming-soon-footer {
  position: relative;
  margin-top: auto;
  padding-top: 3rem;
}

.coming-soon-footer p {
  font-size: 0.8125rem;
  color: var(--dim);
}

/* ── Partners ─────────────────────────────────────────────────── */
.partner-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(190px, 1fr));
  gap: 1rem;
}

.partner-card {
  display: flex;
  align-items: center;
  justify-content: center;
  background: var(--card);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  padding: 1.85rem 1.25rem;
  min-height: 104px;
  box-shadow: 0 1px 2px rgba(15, 23, 42, 0.04);
  transition: border-color 0.18s ease, background 0.18s ease, box-shadow 0.18s ease, transform 0.18s ease;
}

.partner-card:hover {
  border-color: var(--border-strong);
  transform: translateY(-2px);
  box-shadow: 0 8px 22px rgba(15, 23, 42, 0.06);
}

.partner-logo {
  max-width: 150px;
  max-height: 50px;
  width: auto;
  height: auto;
  object-fit: contain;
  opacity: 0.7;
  filter: grayscale(40%);
  transition: opacity 0.18s ease, filter 0.18s ease;
}

.partner-card:hover .partner-logo {
  opacity: 1;
  filter: grayscale(0%);
}

/* ── Citation ─────────────────────────────────────────────────── */
.citation-block {
  position: relative;
  background: #0f172a;
  border: 1px solid #1e293b;
  border-radius: var(--radius-lg);
  padding: 1.75rem;
  max-width: 760px;
  margin-inline: auto;
  box-shadow: 0 12px 40px rgba(15, 23, 42, 0.18);
}

.citation-text {
  font-family: var(--mono);
  font-size: 0.8125rem;
  line-height: 1.75;
  color: #cbd5e1;
  white-space: pre-wrap;
  word-break: break-word;
  overflow-x: auto;
  margin-bottom: 1.35rem;
}

.citation-block .btn-copy {
  background: rgba(255, 255, 255, 0.06);
  color: #e2e8f0;
  border-color: rgba(255, 255, 255, 0.16);
}

.citation-block .btn-copy:hover {
  background: rgba(255, 255, 255, 0.12);
}

.citation-block .btn-copy.copied {
  border-color: #34d399;
  color: #6ee7b7;
  background: rgba(16, 185, 129, 0.12);
}

/* ── Footer ───────────────────────────────────────────────────── */
.site-footer {
  background: var(--bg-alt);
  border-top: 1px solid var(--border);
  padding-top: 3rem;
}

.footer-inner {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  justify-content: space-between;
  gap: 1.5rem;
  padding-bottom: 2.25rem;
  border-bottom: 1px solid var(--border);
}

.footer-brand {
  display: flex;
  align-items: center;
  gap: 0.85rem;
  max-width: 460px;
}

.footer-logo {
  height: 32px;
  width: auto;
  border-radius: 6px;
  opacity: 0.9;
}

.footer-text {
  font-size: 0.9375rem;
  color: var(--muted);
}

.footer-links {
  display: flex;
  flex-wrap: wrap;
  gap: 1.5rem;
}

.footer-links a {
  font-size: 0.9rem;
  font-weight: 500;
  color: var(--muted);
}

.footer-links a:hover {
  color: var(--foreground);
}

.footer-bottom {
  padding: 1.5rem 0 2rem;
}

.footer-copy {
  font-size: 0.8125rem;
  color: var(--dim);
  text-align: center;
}

/* ── Utility ──────────────────────────────────────────────────── */
.is-hidden {
  display: none !important;
}

/* ── Pipeline ─────────────────────────────────────────────────── */
.pipeline {
  list-style: none;
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(230px, 1fr));
  gap: 1.25rem;
  counter-reset: step;
  margin-bottom: 2.5rem;
}

.pipeline-step {
  position: relative;
  background: var(--card);
  border: 1px solid var(--border);
  border-radius: var(--radius-lg);
  padding: 1.75rem 1.6rem 1.6rem;
  box-shadow: 0 1px 2px rgba(15, 23, 42, 0.04);
  transition: border-color 0.18s ease, transform 0.18s ease, box-shadow 0.18s ease;
  overflow: hidden;
}

.pipeline-step::before {
  content: "";
  position: absolute;
  inset: 0 auto 0 0;
  width: 3px;
  background: linear-gradient(180deg, #6d28d9, #047857);
  opacity: 0;
  transition: opacity 0.18s ease;
}

.pipeline-step:hover {
  border-color: var(--border-strong);
  transform: translateY(-3px);
  box-shadow: 0 12px 30px rgba(15, 23, 42, 0.08);
}

.pipeline-step:hover::before {
  opacity: 1;
}

.pipeline-index {
  font-family: var(--mono);
  font-size: 0.8125rem;
  font-weight: 500;
  color: var(--dim);
  letter-spacing: 0.05em;
}

.pipeline-title {
  font-size: 1.15rem;
  font-weight: 600;
  letter-spacing: -0.01em;
  margin: 0.6rem 0 0.55rem;
}

.pipeline-desc {
  font-size: 0.9375rem;
  color: var(--muted);
  line-height: 1.6;
  margin: 0;
}

/* ── Highlight band ───────────────────────────────────────────── */
.highlight-band {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(220px, 1fr));
  gap: 1px;
  background: var(--border);
  border: 1px solid var(--border);
  border-radius: var(--radius-lg);
  overflow: hidden;
  box-shadow: 0 1px 3px rgba(15, 23, 42, 0.04);
}

.highlight {
  background: var(--card);
  padding: 1.5rem 1.6rem;
}

.highlight-title {
  font-size: 1rem;
  font-weight: 600;
  letter-spacing: -0.01em;
  margin: 0 0 0.4rem;
}

.highlight-desc {
  font-size: 0.9rem;
  color: var(--muted);
  line-height: 1.55;
  margin: 0;
}

/* ── Benchmark tabs ───────────────────────────────────────────── */
.bench-tabs {
  display: flex;
  flex-wrap: wrap;
  justify-content: center;
  gap: 0.4rem;
  padding: 0.3rem;
  background: var(--card);
  border: 1px solid var(--border);
  border-radius: 999px;
  width: fit-content;
  max-width: 100%;
  margin-inline: auto;
  margin-bottom: 2.5rem;
  box-shadow: 0 1px 2px rgba(15, 23, 42, 0.04);
}

.bench-tab {
  display: inline-flex;
  align-items: center;
  gap: 0.5rem;
  padding: 0.55rem 1.1rem;
  border: none;
  border-radius: 999px;
  font-family: var(--font);
  font-size: 0.875rem;
  font-weight: 500;
  color: var(--muted);
  background: transparent;
  cursor: pointer;
  white-space: nowrap;
  transition: background 0.15s ease, color 0.15s ease, box-shadow 0.15s ease;
}

.bench-tab:hover {
  color: var(--foreground);
}

.bench-tab.is-active {
  background: var(--accent);
  color: #fff;
  box-shadow: 0 1px 3px rgba(15, 23, 42, 0.15);
}

.bench-tab-count {
  font-family: var(--mono);
  font-size: 0.75rem;
  font-weight: 500;
  padding: 0.05rem 0.4rem;
  border-radius: 999px;
  background: var(--accent-soft);
  color: var(--muted);
}

.bench-tab.is-active .bench-tab-count {
  background: rgba(255, 255, 255, 0.18);
  color: #fff;
}

/* ── Task grid ────────────────────────────────────────────────── */
.task-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(148px, 1fr));
  gap: 0.85rem;
}

.task-tile {
  position: relative;
  display: flex;
  flex-direction: column;
  border: 1px solid var(--border);
  border-radius: var(--radius);
  overflow: hidden;
  background: var(--card);
  box-shadow: 0 1px 2px rgba(15, 23, 42, 0.04);
  transition: border-color 0.18s ease, transform 0.18s ease, box-shadow 0.18s ease;
}

.task-tile:hover {
  border-color: var(--border-strong);
  transform: translateY(-3px);
  box-shadow: 0 12px 28px rgba(15, 23, 42, 0.09);
}

.task-thumb {
  position: relative;
  aspect-ratio: 4 / 3;
  display: grid;
  place-items: center;
  overflow: hidden;
}

.task-thumb::after {
  content: "";
  position: absolute;
  inset: 0;
  background-image:
    linear-gradient(to right, rgba(255, 255, 255, 0.35) 1px, transparent 1px),
    linear-gradient(to bottom, rgba(255, 255, 255, 0.35) 1px, transparent 1px);
  background-size: 22px 22px;
  opacity: 0.5;
  pointer-events: none;
}

.task-glyph {
  position: relative;
  z-index: 1;
  font-size: 1.9rem;
  filter: drop-shadow(0 2px 6px rgba(15, 23, 42, 0.18));
}

.task-caption {
  padding: 0.6rem 0.7rem 0.7rem;
  border-top: 1px solid var(--border);
}

.task-id {
  font-family: var(--mono);
  font-size: 0.6875rem;
  color: var(--dim);
  letter-spacing: 0.03em;
}

.task-name {
  font-size: 0.8125rem;
  font-weight: 500;
  color: var(--foreground);
  line-height: 1.35;
  margin-top: 0.15rem;
  display: block;
}

/* ── Leaderboard ──────────────────────────────────────────────── */
.lb-controls {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  justify-content: space-between;
  gap: 1rem;
  margin-bottom: 1.75rem;
}

.lb-tabs {
  margin: 0;
}

.lb-wrap {
  border: 1px solid var(--border);
  border-radius: var(--radius-lg);
  overflow: hidden;
  box-shadow: 0 1px 3px rgba(15, 23, 42, 0.04);
  background: var(--card);
}

.leaderboard {
  width: 100%;
  border-collapse: collapse;
  font-size: 0.9375rem;
}

.leaderboard thead th {
  text-align: left;
  font-size: 0.75rem;
  font-weight: 600;
  text-transform: uppercase;
  letter-spacing: 0.06em;
  color: var(--dim);
  padding: 0.9rem 1.15rem;
  background: var(--bg-alt);
  border-bottom: 1px solid var(--border);
}

.leaderboard td {
  padding: 0.9rem 1.15rem;
  border-bottom: 1px solid var(--border);
  color: var(--muted);
}

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

.leaderboard tbody tr {
  transition: background 0.15s ease;
}

.leaderboard tbody tr:hover {
  background: var(--accent-soft);
}

.lb-rank {
  width: 3.5rem;
}

.lb-num {
  text-align: right;
}

.lb-rank-badge {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 1.75rem;
  height: 1.75rem;
  border-radius: 50%;
  font-family: var(--mono);
  font-size: 0.8125rem;
  font-weight: 600;
  color: var(--muted);
  background: var(--accent-soft);
}

.lb-rank-badge.gold   { background: #fef3c7; color: #b45309; }
.lb-rank-badge.silver { background: #f1f5f9; color: #475569; }
.lb-rank-badge.bronze { background: #fef2e2; color: #b45309; }

.lb-policy {
  font-family: var(--mono);
  font-weight: 600;
  color: var(--foreground);
  letter-spacing: -0.01em;
}

.lb-type {
  font-size: 0.6875rem;
  font-weight: 600;
  text-transform: uppercase;
  letter-spacing: 0.05em;
  padding: 0.2rem 0.6rem;
  border-radius: 999px;
  background: var(--slate-bg);
  color: var(--slate-fg);
}

.lb-score {
  display: inline-flex;
  align-items: center;
  gap: 0.65rem;
  justify-content: flex-end;
  width: 100%;
}

.lb-score-val {
  font-family: var(--mono);
  font-weight: 600;
  color: var(--foreground);
  min-width: 3.4rem;
  text-align: right;
}

.lb-bar {
  width: 96px;
  height: 6px;
  border-radius: 999px;
  background: var(--accent-soft);
  overflow: hidden;
}

.lb-bar span {
  display: block;
  height: 100%;
  border-radius: 999px;
  background: linear-gradient(90deg, #6d28d9, #0f172a);
}

/* ── BeingBeyond-inspired editorial skin ──────────────────────── */
.nav {
  border-bottom-color: rgba(27, 27, 27, 0.14);
  backdrop-filter: none;
  -webkit-backdrop-filter: none;
}

.nav.scrolled {
  background: rgba(247, 247, 247, 0.96);
  border-bottom-color: rgba(27, 27, 27, 0.22);
}

.nav-links a,
.eyebrow,
.stat-label,
.integration-label,
.timeline-tag,
.tag,
.task-id,
.leaderboard thead th,
.bench-tab,
.lang-btn,
.coming-soon-label,
.page-back {
  font-family: var(--mono);
  text-transform: uppercase;
  letter-spacing: 0.14em;
}

.nav-links a {
  font-size: 0.72rem;
}

.hero-title,
.section-title,
.page-title {
  font-family: var(--serif);
  color: var(--foreground);
  background: none;
  -webkit-background-clip: initial;
  background-clip: initial;
  letter-spacing: -0.045em;
}

.hero-title {
  font-size: clamp(4rem, 9vw, 7.4rem);
  font-weight: 700;
  line-height: 0.9;
}

.section-title,
.page-title {
  font-weight: 700;
  line-height: 0.98;
}

.hero-subtitle,
.section-lead,
.hero-intro,
.page-subtitle {
  color: rgba(27, 27, 27, 0.72);
}

.btn,
.btn-copy,
.badge,
.bench-tabs,
.lang-toggle,
.stats,
.pipeline-step,
.highlight-band,
.task-tile,
.lb-wrap,
.policy-card,
.author-card,
.benefit-item,
.integration-band,
.timeline-list li,
.partner-card,
.citation-block,
.contributor-callout {
  border-color: rgba(27, 27, 27, 0.34);
  box-shadow: var(--hard-shadow);
}

.btn,
.btn-copy {
  border-color: rgba(27, 27, 27, 0.52);
  border-radius: var(--radius);
  font-family: var(--mono);
  font-size: 0.76rem;
  font-weight: 600;
  letter-spacing: 0.08em;
  text-transform: uppercase;
}

.btn-primary {
  background: var(--ink);
  color: #fff;
}

.btn-primary:hover,
.btn-secondary:hover,
.btn-copy:hover {
  transform: translate(-1px, -1px);
  box-shadow: 3px 3px 0 0 #000;
}

.btn-secondary,
.btn-copy,
.badge,
.bench-tabs,
.lang-toggle {
  background: var(--panel);
}

.badge {
  border-radius: var(--radius);
  font-family: var(--mono);
  font-size: 0.68rem;
  font-weight: 600;
  letter-spacing: 0.12em;
  text-transform: uppercase;
}

.stats,
.highlight-band,
.lb-wrap {
  background: rgba(27, 27, 27, 0.28);
  border-color: rgba(27, 27, 27, 0.5);
}

.stat,
.highlight,
.leaderboard thead th,
.leaderboard td {
  border-color: rgba(27, 27, 27, 0.18);
}

.stat-num,
.policy-name,
.benefit-title,
.content-heading,
.highlight-title,
.pipeline-title,
.lb-policy {
  color: var(--foreground);
}

.stat-num {
  font-family: var(--serif);
  font-size: clamp(2rem, 4vw, 3rem);
  line-height: 0.9;
}

.pipeline-step,
.policy-card,
.benefit-item,
.integration-band,
.partner-card,
.task-tile,
.contributor-callout {
  background: var(--panel);
}

.pipeline-step:hover,
.policy-card:hover,
.benefit-item:hover,
.partner-card:hover,
.task-tile:hover,
.author-card:hover {
  border-color: rgba(27, 27, 27, 0.62);
  transform: translate(-1px, -1px);
  box-shadow: 3px 3px 0 0 #000;
}

.pipeline-step::before {
  background: var(--ink);
}

.pipeline-index {
  color: rgba(27, 27, 27, 0.45);
  letter-spacing: 0.16em;
}

.bench-tabs {
  border-radius: var(--radius);
}

.bench-tab,
.lang-btn {
  border-radius: calc(var(--radius) - 1px);
  font-size: 0.68rem;
}

.bench-tab.is-active,
.lang-btn.is-active {
  background: var(--ink);
}

.task-tile {
  border-radius: var(--radius);
}

.task-caption,
.leaderboard thead th,
.leaderboard td {
  border-color: rgba(27, 27, 27, 0.18);
}

.task-thumb::after {
  background-image:
    linear-gradient(to right, rgba(27, 27, 27, 0.08) 1px, transparent 1px),
    linear-gradient(to bottom, rgba(27, 27, 27, 0.08) 1px, transparent 1px);
  opacity: 0.55;
}

.task-glyph {
  filter: none;
}

.leaderboard thead th {
  background: var(--panel);
}

.leaderboard tbody tr:hover {
  background: rgba(27, 27, 27, 0.04);
}

.lb-rank-badge,
.lb-type {
  border: 1px solid rgba(27, 27, 27, 0.28);
}

.lb-bar {
  border: 1px solid rgba(27, 27, 27, 0.24);
  background: transparent;
}

.lb-bar span {
  background: var(--ink);
}

.citation-block {
  border-color: var(--ink);
  box-shadow: 3px 3px 0 0 #000;
}

/* ── Responsive ───────────────────────────────────────────────── */
@media (max-width: 640px) {
  .nav-links {
    display: none;
  }

  .hero-title {
    font-size: clamp(3rem, 16vw, 3.7rem);
    letter-spacing: -0.055em;
  }

  .section-title,
  .page-title {
    font-size: clamp(1.7rem, 7.5vw, 2rem);
    letter-spacing: -0.04em;
    margin-inline: auto;
    max-width: 13ch;
    overflow-wrap: break-word;
  }

  .hero-subtitle,
  .hero-intro,
  .section-lead,
  .page-subtitle {
    width: min(100%, 64ch);
    overflow-wrap: break-word;
  }

  .badge {
    max-width: calc(100vw - 2.5rem);
    overflow: hidden;
    text-align: center;
    text-overflow: ellipsis;
    white-space: nowrap;
  }

  .hero-actions {
    align-items: center;
    flex-direction: column;
    max-width: 100%;
  }

  .stats {
    grid-template-columns: 1fr;
  }

  .integration-stats {
    grid-template-columns: 1fr;
  }

  .footer-inner {
    flex-direction: column;
    align-items: flex-start;
  }

  .task-grid {
    grid-template-columns: repeat(auto-fill, minmax(120px, 1fr));
  }

  .lb-controls {
    flex-direction: column;
    align-items: stretch;
  }

  .lb-bar {
    display: none;
  }

  .leaderboard th:nth-child(3),
  .leaderboard td:nth-child(3) {
    display: none;
  }
}
