/* ── FONTS ───────────────────────────────────────────────────────────────────── */
@import url('https://fonts.googleapis.com/css2?family=Inter:wght@300;400;500;600&family=Roboto+Mono:wght@400;500;600&display=swap');

/* ── CUSTOM PROPERTIES ───────────────────────────────────────────────────────── */
:root {
  /* Backgrounds — inverted dark ground (#171413 = --tk-ink) */
  --bg-base:       #171413;
  --bg-surface:    #620d3c;    /* wine — the brand alternate ground */
  --bg-card:       rgba(255,255,255,0.05);
  --bg-card-solid: #1e1614;
  --bg-card-hover: rgba(255,255,255,0.09);
  --bg-popup:      #1e1614;

  /* Brand */
  --brand:         #620d3c;
  --brand-dark:    #4a0a2e;

  /* Accents */
  --accent-amber:  #f1a222;    /* Takshashila marigold gold */
  --accent-red:    #e63946;    /* data encoding — kept */
  --accent-green:  #3aab6e;    /* data encoding — kept */
  --accent-dim:    rgba(241,162,34,0.08);

  /* Text — inverted ground values */
  --text-primary:   rgba(255,255,255,0.92);
  --text-secondary: rgba(255,255,255,0.80);
  --text-muted:     rgba(255,255,255,0.50);

  /* Borders — inverted hairlines */
  --border:     rgba(255,255,255,0.12);
  --border-mid: rgba(255,255,255,0.28);

  /* Country colors — categorical data encoding; wine + gold as anchors */
  --country-usa:         #5585d8;
  --country-china:       #e05555;
  --country-switzerland: #8a9ab5;
  --country-germany:     #5aaa4a;
  --country-netherlands: #e07b39;
  --country-taiwan:      #9b7ad6;
  --country-japan:       #d45088;
  --country-ireland:     #3eb87a;
  --country-iran:        #f1a222;   /* anchored to Takshashila gold — Iran is the subject */
  --country-russia:      #cc5555;
  --country-uk:          #5a88bb;
  --country-czech:       #cc4444;
  --country-canada:      #cc5555;

  /* Typography */
  --font-heading: "Inter", -apple-system, system-ui, sans-serif;
  --font-serif:   "Inter", -apple-system, system-ui, sans-serif;
  --font-mono:    "Roboto Mono", ui-monospace, monospace;

  /* Layout */
  --nav-h:     clamp(60px, 10vw, 80px);
  --radius:    0;
  --radius-sm: 0;
  --tk-rule:   1px solid rgba(255,255,255,0.12);
}

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

html { scroll-behavior: smooth; scroll-padding-top: var(--nav-h); }

body {
  font-family: var(--font-heading);
  background: var(--bg-base);
  color: var(--text-primary);
  font-size: 18px;
  line-height: 1.7;
  -webkit-font-smoothing: antialiased;
}

h1, h2, h3, h4 {
  font-family: var(--font-heading);
  font-weight: 400;
  letter-spacing: -0.01em;
}

p { margin-bottom: 1em; }
p:last-child { margin-bottom: 0; }

a { color: var(--accent-amber); text-decoration: none; }
a:hover { text-decoration: underline; }

strong { font-weight: 600; color: #fff; }
em { font-style: italic; }

/* ── LAYOUT ──────────────────────────────────────────────────────────────────── */
.container {
  max-width: 1180px;
  margin: 0 auto;
  padding: 0 40px;
}
@media (max-width: 960px) { .container { padding: 0 24px; } }
@media (max-width: 560px) { .container { padding: 0 18px; } }

/* ── NAV — wine background, Roboto Mono labels ───────────────────────────────── */
.site-nav {
  position: fixed;
  top: 0; left: 0; right: 0;
  height: var(--nav-h);
  background: var(--brand);
  border-bottom: 1px solid rgba(255,255,255,0.10);
  z-index: 1000;
}

.nav-inner {
  max-width: 1180px;
  margin: 0 auto;
  padding: 0 40px;
  height: 100%;
  display: flex;
  align-items: center;
  gap: 20px;
}
@media (max-width: 960px) { .nav-inner { padding: 0 24px; } }

.nav-wordmark {
  font-family: var(--font-mono);
  font-size: 11px;
  font-weight: 600;
  letter-spacing: 0.14em;
  color: var(--accent-amber);
  white-space: nowrap;
  flex-shrink: 0;
  text-transform: uppercase;
}

.nav-tabs {
  display: flex;
  list-style: none;
  gap: 0;
  flex: 1;
}

.nav-tab {
  font-family: var(--font-heading);   /* Inter — navigation is never mono */
  font-size: 14px;
  font-weight: 400;
  letter-spacing: 0.3px;             /* hair of positive tracking, nothing like mono */
  text-transform: none;              /* Title Case, not uppercase */
  color: rgba(255,255,255,0.70);
  padding: 8px 12px;
  transition: color 0.15s, background 0.15s;
  text-decoration: none;
  white-space: nowrap;
}
.nav-tab:hover { color: #fff; background: rgba(255,255,255,0.10); text-decoration: none; }
.nav-tab.active { color: var(--accent-amber); background: rgba(255,255,255,0.08); }

.nav-meta {
  font-family: var(--font-mono);
  font-size: 10px;
  font-weight: 400;
  letter-spacing: 0.06em;
  color: rgba(255,255,255,0.50);
  white-space: nowrap;
  margin-left: auto;
  flex-shrink: 0;
}

.nav-hamburger {
  display: none;
  background: none;
  border: none;
  color: rgba(255,255,255,0.75);
  font-size: 20px;
  cursor: pointer;
}

.nav-mobile-menu {
  display: none;
  flex-direction: column;
  list-style: none;
  background: var(--brand-dark);
  border-bottom: var(--tk-rule);
  padding: 12px 0;
}
.nav-mobile-menu.open { display: flex; }
.nav-tab-mobile {
  display: block;
  font-family: var(--font-heading);   /* Inter — nav links are destinations, not metadata */
  font-size: 16px;
  font-weight: 400;
  letter-spacing: 0.3px;
  text-transform: none;              /* Title Case */
  color: rgba(255,255,255,0.65);
  padding: 10px 24px;
  text-decoration: none;
  transition: color 0.15s;
}
.nav-tab-mobile:hover { color: var(--accent-amber); text-decoration: none; }

/* ── SECTION BASE ────────────────────────────────────────────────────────────── */
.section {
  padding: 64px 0;       /* style guide §4: 64px vertical padding */
  border-bottom: var(--tk-rule);
  opacity: 0;
  transform: translateY(20px);
  transition: opacity 0.55s ease, transform 0.55s ease;
}
.section.in-view {
  opacity: 1;
  transform: none;
}
.section-first { padding-top: calc(var(--nav-h) + 56px); }

/* Alternate sections — wine ground */
.section-alt { background: var(--bg-surface); }

/* Card and interactive element overrides on wine sections */
.section-alt .bg-card-override {
  background: rgba(0,0,0,0.18);
  border-color: rgba(255,255,255,0.16);
}

.section-heading {
  font-family: var(--font-heading);
  font-size: clamp(22px, 3vw, 36px);
  font-weight: 400;
  letter-spacing: -0.02em;
  color: var(--text-primary);
  margin-bottom: 12px;
  text-wrap: balance;
}

.section-intro {
  font-size: 16px;
  color: var(--text-secondary);
  max-width: 720px;
  margin-bottom: 44px;
  font-style: normal;
  line-height: 1.65;
  text-wrap: pretty;
}

/* ── INTRO CAROUSEL ──────────────────────────────────────────────────────────── */
.intro-carousel {
  position: relative;
  margin-bottom: 48px;
}

.carousel-viewport {
  overflow: hidden;
}

.carousel-track {
  display: flex;
  transition: transform 0.4s ease;
}

.carousel-card {
  min-width: 100%;
  background: var(--bg-card);
  border: var(--tk-rule);
  padding: 40px 48px;
  display: flex;
  gap: 36px;
  align-items: flex-start;
}
@media (max-width: 768px) {
  .carousel-card { flex-direction: column; gap: 16px; padding: 28px 22px; }
}

.card-num {
  font-family: var(--font-mono);
  font-size: 64px;
  font-weight: 400;
  color: var(--accent-amber);
  opacity: 0.15;
  line-height: 1;
  flex-shrink: 0;
  user-select: none;
  letter-spacing: -0.02em;
}
@media (max-width: 768px) { .card-num { font-size: 42px; } }

.card-content { flex: 1; }

.card-title {
  font-family: var(--font-heading);
  font-size: 20px;
  font-weight: 400;
  color: var(--text-primary);
  margin-bottom: 14px;
  letter-spacing: -0.01em;
  line-height: 1.3;
  text-wrap: balance;
}

.card-body {
  font-size: 16px;
  line-height: 1.75;
  color: var(--text-secondary);
}

.card-stats {
  display: flex;
  gap: 28px;
  margin-top: 22px;
  padding-top: 18px;
  border-top: var(--tk-rule);
  flex-wrap: wrap;
}

.card-stat { display: flex; flex-direction: column; gap: 4px; }
.card-stat-val {
  font-family: var(--font-mono);
  font-size: 22px;
  font-weight: 400;     /* style guide: stat figures weight 400 — authority from size */
  color: var(--accent-amber);
  line-height: 1;
  letter-spacing: -0.01em;
}
.card-stat-label {
  font-family: var(--font-mono);
  font-size: 10px;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  color: var(--text-muted);
}

.carousel-controls {
  display: flex;
  justify-content: center;
  gap: 8px;
  margin-top: 18px;
}

.carousel-dot {
  width: 8px; height: 8px;
  background: var(--border-mid);
  border: none;
  cursor: pointer;
  transition: background 0.2s, width 0.2s;
  padding: 0;
}
.carousel-dot.active {
  background: var(--accent-amber);
  width: 24px;
}

.carousel-nav-btns {
  position: absolute;
  top: 50%;
  left: 0; right: 0;
  transform: translateY(-50%);
  display: flex;
  justify-content: space-between;
  pointer-events: none;
  padding: 0 10px;
}

.carousel-nav-btn {
  pointer-events: all;
  background: var(--bg-base);
  border: var(--tk-rule);
  color: var(--text-secondary);
  width: 36px; height: 36px;
  cursor: pointer;
  font-size: 16px;
  display: flex;
  align-items: center;
  justify-content: center;
  transition: color 0.15s, border-color 0.15s;
}
.carousel-nav-btn:hover { color: var(--accent-amber); border-color: var(--accent-amber); }

/* Left-rule aside — the house pull-quote */
.intro-context {
  border-left: 2px solid var(--accent-amber);
  padding: 20px 24px;
  font-size: 16px;
  color: var(--text-secondary);
  line-height: 1.75;
  text-wrap: pretty;
}
.intro-context strong { color: var(--text-primary); }

/* ── VARIANTS CAROUSEL ───────────────────────────────────────────────────────── */
.variants-carousel-wrap {
  display: flex;
  align-items: center;
  gap: 16px;
  margin-bottom: 20px;
}

.variants-viewport {
  position: relative;
  flex: 1;
  overflow: hidden;
  height: 620px;
}

.variants-track {
  position: relative;
  width: 100%;
  height: 100%;
}

.variant-card {
  position: absolute;
  inset: 0;
  background: var(--bg-card);
  border: var(--tk-rule);
  overflow: hidden;
  display: flex;
  flex-direction: column;
  opacity: 0;
  pointer-events: none;
  transform: translateX(48px);
  transition: opacity 0.35s ease, transform 0.35s ease;
}
.variant-card.active { opacity: 1; pointer-events: auto; transform: translateX(0); }
.variant-card.entering-slide-left  { transform: translateX(48px);  opacity: 0; }
.variant-card.entering-slide-right { transform: translateX(-48px); opacity: 0; }
.variant-card.leaving-slide-left   { transform: translateX(-48px); opacity: 0; }
.variant-card.leaving-slide-right  { transform: translateX(48px);  opacity: 0; }

.variant-img-wrap {
  position: relative;
  height: 380px;
  overflow: hidden;
  background: #0a0807;
  flex-shrink: 0;
  display: flex;
  align-items: center;
  justify-content: center;
}
.variant-img {
  width: 100%;
  height: 100%;
  object-fit: contain;
  object-position: center;
  display: block;
  padding: 16px;
}
.variant-img-overlay {
  position: absolute;
  top: 0; left: 0; right: 0;
  padding: 14px 14px 0;
  display: flex;
  justify-content: space-between;
  align-items: flex-start;
}
.variant-img-credit {
  position: absolute;
  bottom: 0; left: 0; right: 0;
  font-family: var(--font-mono);
  font-size: 9px;
  color: rgba(255,255,255,0.40);
  background: rgba(0,0,0,0.70);
  padding: 6px 10px;
  letter-spacing: 0.05em;
}

.variant-badge {
  font-family: var(--font-mono);
  font-size: 10px;
  font-weight: 600;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  background: var(--accent-amber);
  color: var(--bg-base);
  padding: 4px 9px;
}

.variant-role-tag {
  font-family: var(--font-mono);
  font-size: 9px;
  letter-spacing: 0.06em;
  color: rgba(255,255,255,0.80);
  background: rgba(0,0,0,0.55);
  border: var(--tk-rule);
  padding: 3px 8px;
}

.variant-info {
  padding: 20px 24px;
  flex: 1;
  display: flex;
  flex-direction: column;
  gap: 14px;
}

.variant-specs {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 12px 16px;
}

.spec-key {
  font-family: var(--font-mono);
  font-size: 9px;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  color: var(--text-muted);
  display: block;
  margin-bottom: 3px;
}
.spec-val {
  font-family: var(--font-mono);
  font-size: 12px;
  font-weight: 500;
  color: var(--text-primary);
}
.variant-engine-val {
  font-size: 10px;
  font-weight: 400;
  display: block;
  margin-top: 3px;
  color: var(--text-secondary);
}

.variant-notes {
  font-family: var(--font-heading);
  font-size: 14px;
  color: var(--text-secondary);
  line-height: 1.65;
  border-top: var(--tk-rule);
  padding-top: 14px;
  margin-top: auto;
  text-wrap: pretty;
}

.var-arrow {
  background: var(--bg-card);
  border: var(--tk-rule);
  color: var(--text-secondary);
  width: 44px; height: 44px;
  cursor: pointer;
  font-size: 18px;
  flex-shrink: 0;
  display: flex;
  align-items: center;
  justify-content: center;
  transition: color 0.15s, border-color 0.15s, background 0.15s;
}
.var-arrow:hover {
  color: var(--accent-amber);
  border-color: var(--accent-amber);
  background: var(--accent-dim);
}
.var-arrow:disabled { opacity: 0.3; cursor: default; }

.variants-dots {
  display: flex;
  justify-content: center;
  gap: 8px;
  margin-bottom: 8px;
}
.variant-dot {
  width: 8px; height: 8px;
  background: var(--border-mid);
  border: none;
  cursor: pointer;
  transition: background 0.2s, width 0.2s;
  padding: 0;
}
.variant-dot.active {
  background: var(--accent-amber);
  width: 24px;
}

/* ── COMPONENT SECTION ───────────────────────────────────────────────────────── */
.component-toggle {
  display: flex;
  gap: 0;
  margin-bottom: 28px;
  border: var(--tk-rule);
  width: fit-content;
}

.toggle-btn {
  font-family: var(--font-mono);
  font-size: 11px;
  font-weight: 400;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  padding: 10px 20px;
  background: transparent;
  border: none;
  border-right: var(--tk-rule);
  color: var(--text-secondary);
  cursor: pointer;
  transition: background 0.15s, color 0.15s;
  display: flex;
  align-items: center;
  gap: 10px;
}
.toggle-btn:last-child { border-right: none; }
.toggle-btn:hover { background: var(--accent-dim); color: var(--text-primary); }
.toggle-btn.active { background: var(--accent-dim); color: var(--accent-amber); }

.toggle-count { font-size: 10px; opacity: 0.60; }

/* ── BLUEPRINT ───────────────────────────────────────────────────────────────── */
.blueprint-outer {
  width: 100%;
  overflow-x: auto;
  background: #0d0b0a;
  border-top: var(--tk-rule);
  border-bottom: var(--tk-rule);
  -webkit-overflow-scrolling: touch;
}
.blueprint-board {
  min-width: 900px;
}
.blueprint-board svg { display: block; width: 100%; height: auto; }

.bp-chip { cursor: pointer; }
.bp-chip rect { transition: filter 0.15s, stroke-width 0.15s; }
.bp-chip:hover rect {
  filter: brightness(1.5) drop-shadow(0 0 5px rgba(100,200,255,0.40));
  stroke-width: 1.8px;
}

.bp-overlay {
  position: fixed;
  inset: 0;
  background: rgba(0,0,0,0.70);
  z-index: 900;
}
.bp-overlay[hidden] { display: none; }

.bp-modal {
  position: fixed;
  top: 50%;
  left: 50%;
  transform: translate(-50%, -50%);
  width: min(480px, calc(100vw - 32px));
  background: var(--bg-card-solid);
  border: 1px solid var(--border-mid);
  z-index: 901;
  animation: bpModalIn 0.20s ease;
}
.bp-modal[hidden] { display: none; }
@keyframes bpModalIn {
  from { opacity: 0; transform: translate(-50%, -47%); }
  to   { opacity: 1; transform: translate(-50%, -50%); }
}
.bp-modal-close {
  position: absolute;
  top: 12px; right: 14px;
  background: none; border: none;
  font-size: 16px;
  color: var(--text-muted);
  cursor: pointer;
  padding: 4px;
  z-index: 1;
}
.bp-modal-close:hover { color: var(--text-primary); }
.bp-modal-body { padding: 28px 28px 24px; }

.bpm-badge {
  display: inline-block;
  font-family: var(--font-mono);
  font-size: 10px;
  font-weight: 600;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  color: #fff;
  padding: 3px 10px;
  margin-bottom: 14px;
}
.bpm-name {
  font-family: var(--font-heading);
  font-size: 19px;
  font-weight: 400;
  color: var(--text-primary);
  margin-bottom: 4px;
  line-height: 1.3;
  padding-right: 24px;
}
.bpm-model {
  font-family: var(--font-mono);
  font-size: 11px;
  color: var(--text-muted);
  margin-bottom: 18px;
  letter-spacing: 0.06em;
}
.bpm-specs { margin: 0; }
.bpm-specs dt {
  font-family: var(--font-mono);
  font-size: 9.5px;
  letter-spacing: 0.10em;
  text-transform: uppercase;
  color: rgba(241,162,34,0.55);
  margin-top: 12px;
}
.bpm-specs dd {
  font-family: var(--font-heading);
  font-size: 14px;
  color: var(--text-secondary);
  line-height: 1.6;
  margin: 0;
}

/* ── LIFECYCLE HINT ──────────────────────────────────────────────────────────── */
.lc-hint {
  font-family: var(--font-mono);
  font-size: 11px;
  letter-spacing: 0.10em;
  text-transform: uppercase;
  color: rgba(241,162,34,0.65);
  margin-bottom: 28px;
}

/* ── LIFECYCLE DIAGRAM ───────────────────────────────────────────────────────── */
.lc-wheel {
  display: grid;
  grid-template-columns: 1fr 180px 1fr;
  grid-template-rows: auto 180px auto;
  gap: 20px;
  align-items: center;
  margin-bottom: 48px;
  max-width: 900px;
  margin-left: auto;
  margin-right: auto;
}

.lc-center {
  grid-column: 2;
  grid-row: 2;
  display: flex;
  align-items: center;
  justify-content: center;
}

.lc-node {
  background: rgba(0,0,0,0.20);
  border: var(--tk-rule);
  padding: 18px 20px;
  cursor: pointer;
  transition: border-color 0.2s, opacity 0.2s;
  text-align: left;
}
.lc-node:hover { border-color: var(--border-mid); }
.lc-node.active { border-color: var(--accent-amber); }
.lc-node.dim { opacity: 0.4; }

.lc-node-top    { grid-column: 2; grid-row: 1; text-align: center; }
.lc-node-right  { grid-column: 3; grid-row: 2; }
.lc-node-bottom { grid-column: 2; grid-row: 3; text-align: center; }
.lc-node-left   { grid-column: 1; grid-row: 2; text-align: right; }

.lc-node-num {
  font-family: var(--font-mono);
  font-size: 10px;
  font-weight: 600;
  color: var(--accent-amber);
  letter-spacing: 0.14em;
  margin-bottom: 6px;
  display: block;
  text-transform: uppercase;
}
.lc-node-title {
  font-family: var(--font-heading);
  font-size: 14px;
  font-weight: 400;
  color: var(--text-primary);
  line-height: 1.3;
  margin-bottom: 4px;
}
.lc-node-role {
  font-family: var(--font-mono);
  font-size: 8.5px;
  letter-spacing: 0.10em;
  text-transform: uppercase;
  color: var(--text-muted);
  margin-bottom: 10px;
  display: block;
}
.lc-node-stats {
  display: flex;
  gap: 12px;
  flex-wrap: wrap;
}
.lc-node-top .lc-node-stats,
.lc-node-bottom .lc-node-stats { justify-content: center; }
.lc-node-left .lc-node-stats   { justify-content: flex-end; }

.lc-stat { display: flex; flex-direction: column; gap: 2px; }
.lc-stat-val {
  font-family: var(--font-mono);
  font-size: 13px;
  font-weight: 500;
  color: var(--accent-amber);
  line-height: 1.2;
}
.lc-stat-label {
  font-family: var(--font-mono);
  font-size: 8px;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  color: var(--text-muted);
}

.lc-detail {
  border-top: var(--tk-rule);
  padding-top: 36px;
  max-width: 900px;
  margin: 0 auto;
  display: none;
}
.lc-detail.visible { display: block; }

.lc-detail-inner {
  background: rgba(0,0,0,0.22);
  border: 1px solid var(--border-mid);
  padding: 32px 36px;
  animation: detailFadeIn 0.30s ease;
}
@keyframes detailFadeIn {
  from { opacity: 0; transform: translateY(8px); }
  to   { opacity: 1; transform: none; }
}

.lc-detail-header {
  display: flex;
  align-items: flex-start;
  gap: 20px;
  margin-bottom: 20px;
}
.lc-detail-num {
  font-family: var(--font-mono);
  font-size: 52px;
  font-weight: 400;
  color: var(--accent-amber);
  opacity: 0.15;
  line-height: 1;
  flex-shrink: 0;
  user-select: none;
  letter-spacing: -0.02em;
}
.lc-detail-title {
  font-family: var(--font-heading);
  font-size: 22px;
  font-weight: 400;
  color: var(--text-primary);
  margin-bottom: 4px;
  letter-spacing: -0.01em;
}
.lc-detail-role {
  font-family: var(--font-mono);
  font-size: 10px;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  color: var(--accent-amber);
  opacity: 0.70;
}
.lc-detail-stats {
  display: flex;
  gap: 40px;
  margin-bottom: 24px;
  padding-bottom: 24px;
  border-bottom: var(--tk-rule);
}
.lc-detail-stat { display: flex; flex-direction: column; gap: 4px; }
.lc-detail-stat-val {
  font-family: var(--font-mono);
  font-size: 30px;
  font-weight: 400;
  color: var(--accent-amber);
  line-height: 1;
  letter-spacing: -0.01em;
}
.lc-detail-stat-label {
  font-family: var(--font-mono);
  font-size: 10px;
  letter-spacing: 0.10em;
  text-transform: uppercase;
  color: var(--text-muted);
}
.lc-detail-body p {
  font-size: 16px;
  color: var(--text-secondary);
  line-height: 1.80;
  margin-bottom: 1em;
  text-wrap: pretty;
}
.lc-detail-body strong { color: var(--text-primary); }

/* ── LIFECYCLE MODAL ─────────────────────────────────────────────────────────── */
.lc-overlay {
  position: fixed;
  inset: 0;
  background: rgba(0,0,0,0.72);
  z-index: 900;
}
.lc-overlay[hidden] { display: none; }

.lc-modal {
  position: fixed;
  top: 50%;
  left: 50%;
  transform: translate(-50%, -50%);
  width: min(680px, calc(100vw - 32px));
  max-height: calc(100vh - 80px);
  overflow-y: auto;
  background: var(--bg-card-solid);
  border: 1px solid var(--border-mid);
  z-index: 901;
  animation: lcModalIn 0.22s ease;
}
.lc-modal[hidden] { display: none; }
@keyframes lcModalIn {
  from { opacity: 0; transform: translate(-50%, -47%); }
  to   { opacity: 1; transform: translate(-50%, -50%); }
}

.lc-modal-close {
  position: sticky;
  top: 14px;
  float: right;
  margin: 14px 14px 0 0;
  background: rgba(255,255,255,0.08);
  border: var(--tk-rule);
  color: var(--text-secondary);
  width: 32px; height: 32px;
  cursor: pointer;
  font-size: 14px;
  display: flex;
  align-items: center;
  justify-content: center;
  transition: background 0.15s, color 0.15s;
  z-index: 1;
}
.lc-modal-close:hover { background: rgba(255,255,255,0.16); color: var(--text-primary); }

.lc-modal-body {
  padding: 28px 36px 36px;
  clear: right;
}

/* ── EXPORT CARDS ────────────────────────────────────────────────────────────── */
.export-cards-grid {
  display: grid;
  grid-template-columns: repeat(5, 1fr);
  gap: 20px;
}

.export-card {
  background: var(--bg-card);
  border: var(--tk-rule);
  padding: 20px 18px;
  transition: background 0.15s ease, border-color 0.15s;
  display: flex;
  flex-direction: column;
  gap: 10px;
}
.export-card:hover {
  background: var(--bg-card-hover);
  border-color: var(--border-mid);
}

.export-card-header { display: flex; flex-direction: column; gap: 8px; }
.export-card-recipient {
  font-family: var(--font-mono);
  font-size: 13px;
  font-weight: 600;
  color: var(--text-primary);
  letter-spacing: 0.04em;
  text-transform: uppercase;
}
.export-card-models {
  font-family: var(--font-mono);
  font-size: 9.5px;
  color: var(--accent-amber);
  letter-spacing: 0.06em;
  line-height: 1.5;
}
.export-card-notes {
  font-family: var(--font-heading);
  font-size: 13px;
  color: var(--text-muted);
  line-height: 1.65;
  flex: 1;
  text-wrap: pretty;
}

.rel-badge {
  font-family: var(--font-mono);
  font-size: 9px;
  padding: 2px 7px;
  display: inline-block;
  letter-spacing: 0.06em;
  text-transform: uppercase;
}
.rel-state   { background: rgba(85,133,216,0.20); color: #88aaee; }
.rel-militia { background: rgba(230,57,70,0.18);  color: #ee9090; }
.rel-reverse { background: rgba(58,171,110,0.18); color: #7adba8; }

/* ── PATHWAYS / SUPPLY-LINES ─────────────────────────────────────────────────── */
.pathways-grid {
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  gap: 20px;
  margin-top: 8px;
}

.pathway-card {
  background: rgba(0,0,0,0.18);
  border: var(--tk-rule);
  border-top: 3px solid var(--accent-amber);   /* replaces gradient accent */
  padding: 28px 30px;
  transition: background 0.15s ease, border-color 0.15s;
  position: relative;
  overflow: hidden;
}
.pathway-card:hover {
  background: rgba(0,0,0,0.28);
  border-color: var(--border-mid);
  border-top-color: var(--accent-amber);
}

.pathway-card-header {
  display: flex;
  align-items: flex-start;
  gap: 16px;
  margin-bottom: 16px;
}
.pathway-num {
  font-family: var(--font-mono);
  font-size: 38px;
  font-weight: 400;
  opacity: 0.10;
  line-height: 1;
  flex-shrink: 0;
  color: var(--text-primary);
  user-select: none;
  letter-spacing: -0.02em;
}
.pathway-title {
  font-family: var(--font-heading);
  font-size: 18px;
  font-weight: 400;
  color: var(--text-primary);
  margin-bottom: 5px;
  line-height: 1.3;
  text-wrap: balance;
}
.pathway-subtitle {
  font-family: var(--font-mono);
  font-size: 9.5px;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  color: var(--text-muted);
}
.pathway-body {
  font-family: var(--font-heading);
  font-size: 15px;
  color: var(--text-secondary);
  line-height: 1.75;
  margin-bottom: 18px;
  text-wrap: pretty;
}
.pathway-examples {
  list-style: none;
  display: flex;
  flex-direction: column;
  gap: 7px;
}
.pathway-examples li {
  font-family: var(--font-mono);
  font-size: 11px;
  color: var(--text-muted);
  padding-left: 18px;
  position: relative;
  line-height: 1.5;
  letter-spacing: 0.02em;
}
.pathway-examples li::before {
  content: '→';
  position: absolute;
  left: 0;
  color: var(--accent-amber);
  opacity: 0.65;
}

/* ── FOOTER ──────────────────────────────────────────────────────────────────── */
.site-footer {
  background: var(--brand);
  border-top: none;
  padding: 48px 0;
  text-align: left;
}
.site-footer .container { display: flex; flex-direction: column; gap: 12px; }
.site-footer p {
  font-family: var(--font-mono);
  font-size: 11px;
  color: rgba(255,255,255,0.55);
  letter-spacing: 0.06em;
  margin-bottom: 0;
  text-transform: uppercase;
}
.footer-note {
  font-size: 11px !important;
  max-width: 560px;
  text-transform: none !important;
  letter-spacing: 0.02em !important;
  color: rgba(255,255,255,0.50) !important;
}

/* Gold CTA button on dark/wine ground */
.footer-cta {
  display: inline-block;
  font-family: var(--font-mono);
  font-size: 12px;
  font-weight: 600;
  letter-spacing: 0.10em;
  text-transform: uppercase;
  color: var(--bg-base);
  background: var(--accent-amber);
  padding: 14px 28px;
  text-decoration: none;
  transition: background 0.15s;
  margin-top: 4px;
  align-self: flex-start;
}
.footer-cta:hover { background: #d98d0f; text-decoration: none; }

/* ── RESPONSIVE ───────────────────────────────────────────────────────────────── */
@media (max-width: 1100px) {
  .export-cards-grid { grid-template-columns: repeat(3, 1fr); }
}

@media (max-width: 1024px) {
  .lc-wheel {
    grid-template-columns: 1fr 150px 1fr;
    grid-template-rows: auto 150px auto;
    gap: 14px;
  }
}

@media (max-width: 820px) {
  .lc-wheel {
    display: flex;
    flex-direction: column;
    gap: 10px;
    align-items: stretch;
    max-width: 100%;
    margin-bottom: 36px;
  }
  .lc-center { display: none; }
  .lc-node { text-align: left !important; }
  .lc-node-stats { justify-content: flex-start !important; }
  .export-cards-grid { grid-template-columns: repeat(2, 1fr); }
  .pathways-grid { grid-template-columns: 1fr; }
}

@media (max-width: 768px) {
  .nav-tabs  { display: none; }
  .nav-meta  { display: none; }
  .nav-hamburger { display: block; }

  .variants-viewport { min-height: 520px; height: 520px; }
  .variant-img-wrap  { height: 260px; }
  .variant-specs     { grid-template-columns: repeat(2, 1fr); }

  .component-toggle { flex-direction: column; border: none; width: 100%; }
  .toggle-btn { border: var(--tk-rule); border-bottom: none; width: 100%; }
  .toggle-btn:last-child { border-bottom: var(--tk-rule); }

  .section { padding: 60px 0; }
  .section-first { padding-top: calc(var(--nav-h) + 40px); }

  .lc-detail-inner { padding: 22px; }
  .lc-detail-stats { gap: 20px; }
}

@media (max-width: 600px) {
  .export-cards-grid { grid-template-columns: 1fr; }
}

@media (max-width: 480px) {
  .variants-viewport { min-height: 440px; height: 440px; }
  .variants-carousel-wrap { gap: 6px; }
  .var-arrow { width: 32px; height: 32px; font-size: 14px; }
  .card-stats { flex-wrap: wrap; gap: 16px; }
}
