/* ===== RESET & ROOT ===== */
:root {
  --bg: #0a0a0a;
  --bg2: #111;
  --bg3: #161616;
  --surface: #141414;
  --border: #222;
  --text: #e8dcc8;
  --text-muted: #8a8070;
  --text-dim: #555;
  --gold: #c9a84c;
  --gold-light: #e2c67a;
  --gold-dark: #9a7a2e;
  --red: #9b2020;
  --red-light: #c94040;
  --red-dark: #6b1010;
  --blue-soviet: #1a3a5c;
  --green-hope: #1a3a28;
  --radius: 18px;
  --radius-sm: 10px;
  color-scheme: dark;
}

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

html { scroll-behavior: smooth; }

body {
  background: var(--bg);
  color: var(--text);
  font-family: "Georgia", "Times New Roman", serif;
  line-height: 1.75;
  min-height: 100vh;
}

/* ===== HERO ===== */
.hero {
  position: relative;
  min-height: 100vh;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  overflow: hidden;
  background:
    radial-gradient(ellipse at 20% 50%, rgba(120, 40, 10, 0.25) 0%, transparent 60%),
    radial-gradient(ellipse at 80% 20%, rgba(100, 70, 0, 0.2) 0%, transparent 50%),
    linear-gradient(160deg, #0d0508 0%, #0a0a0f 40%, #08080a 100%);
}

.hero::before {
  content: "";
  position: absolute;
  inset: 0;
  background-image:
    repeating-linear-gradient(0deg, transparent, transparent 49px, rgba(255,255,255,0.02) 49px, rgba(255,255,255,0.02) 50px),
    repeating-linear-gradient(90deg, transparent, transparent 49px, rgba(255,255,255,0.02) 49px, rgba(255,255,255,0.02) 50px);
  pointer-events: none;
}

.hero__overlay {
  position: absolute;
  inset: 0;
  background: radial-gradient(ellipse at center, transparent 30%, rgba(0,0,0,0.6) 100%);
  pointer-events: none;
}

.hero__content {
  position: relative;
  z-index: 1;
  text-align: center;
  padding: 2rem 1.5rem;
  max-width: 900px;
}

.hero__badge {
  display: inline-block;
  padding: 0.4rem 1.2rem;
  border: 1px solid var(--gold-dark);
  border-radius: 999px;
  color: var(--gold);
  font-size: 0.85rem;
  letter-spacing: 0.2em;
  text-transform: uppercase;
  margin-bottom: 1.5rem;
  background: rgba(150, 100, 0, 0.1);
}

.hero h1 {
  font-size: clamp(2rem, 5vw, 4rem);
  font-weight: 700;
  line-height: 1.18;
  color: #fff;
  text-shadow: 0 2px 30px rgba(0,0,0,0.8);
  margin-bottom: 1.5rem;
}

.hero__sub {
  font-size: clamp(1rem, 2vw, 1.25rem);
  color: #b0a090;
  max-width: 650px;
  margin: 0 auto 2rem;
  font-style: italic;
}

.hero__stars {
  font-size: 2.5rem;
  color: var(--gold);
  opacity: 0.4;
  margin-top: 1rem;
  filter: drop-shadow(0 0 12px var(--gold));
}

.star-of-david {
  font-style: normal;
}

.hero__scroll {
  position: absolute;
  bottom: 2rem;
  left: 50%;
  transform: translateX(-50%);
  color: var(--gold-dark);
  text-decoration: none;
  font-size: 1.5rem;
  animation: bounce 2s infinite;
  z-index: 1;
}

@keyframes bounce {
  0%, 100% { transform: translateX(-50%) translateY(0); }
  50% { transform: translateX(-50%) translateY(8px); }
}

/* ===== STICKY NAV ===== */
.toc {
  position: sticky;
  top: 0;
  z-index: 100;
  background: rgba(10, 10, 10, 0.95);
  backdrop-filter: blur(10px);
  border-bottom: 1px solid #1e1e1e;
  padding: 0.6rem 1rem;
  overflow-x: auto;
  scrollbar-width: none;
}

.toc::-webkit-scrollbar { display: none; }

.toc__inner {
  display: flex;
  gap: 0.4rem;
  min-width: max-content;
  margin: 0 auto;
  justify-content: center;
}

.toc a {
  color: #aaa;
  text-decoration: none;
  padding: 0.35rem 0.85rem;
  border: 1px solid #2a2a2a;
  border-radius: 999px;
  font-size: 0.8rem;
  font-weight: 700;
  letter-spacing: 0.03em;
  white-space: nowrap;
  font-family: "Segoe UI", sans-serif;
  transition: color 0.2s, border-color 0.2s, background 0.2s;
}

.toc a:hover {
  color: var(--gold);
  border-color: var(--gold-dark);
  background: rgba(150, 100, 0, 0.1);
}

/* ===== MAIN CONTENT ===== */
.content {
  max-width: 1000px;
  margin: 0 auto;
  padding: 3rem 1.5rem 4rem;
}

/* ===== ERA LABEL ===== */
.era-label {
  text-align: center;
  font-family: "Segoe UI", sans-serif;
  font-size: 0.75rem;
  letter-spacing: 0.35em;
  text-transform: uppercase;
  color: var(--text-dim);
  padding: 2rem 0 0.5rem;
  position: relative;
}

.era-label::before,
.era-label::after {
  content: "";
  position: absolute;
  top: 50%;
  height: 1px;
  width: 30%;
  background: linear-gradient(to right, transparent, #2a2a2a);
}

.era-label::before { left: 0; background: linear-gradient(to right, transparent, #2a2a2a); }
.era-label::after { right: 0; background: linear-gradient(to left, transparent, #2a2a2a); }

/* ===== CARDS ===== */
.card {
  position: relative;
  margin: 1.5rem 0;
  border-radius: var(--radius);
  overflow: hidden;
  border: 1px solid var(--border);
}

.card__date {
  position: absolute;
  top: 1.25rem;
  right: 1.25rem;
  font-family: "Segoe UI", sans-serif;
  font-size: 0.78rem;
  font-weight: 700;
  letter-spacing: 0.12em;
  padding: 0.3rem 0.8rem;
  border-radius: 999px;
  background: rgba(0,0,0,0.5);
  border: 1px solid rgba(255,255,255,0.08);
  color: #777;
  z-index: 1;
}

.card__body {
  padding: 2rem 2rem 2.5rem;
}

.card h2 {
  font-size: clamp(1.5rem, 3vw, 2.1rem);
  margin-bottom: 1.25rem;
  line-height: 1.25;
  padding-right: 100px;
}

.card h3 {
  font-size: 1.15rem;
  margin: 1.75rem 0 0.75rem;
  color: #ccc;
}

.card h4 {
  font-size: 1rem;
  margin: 1.25rem 0 0.5rem;
  color: #bbb;
}

.card p {
  margin: 0.85rem 0;
  color: #c8bdb0;
}

.card ul {
  padding-left: 1.5rem;
  margin: 0.75rem 0;
  color: #c0b8a8;
}

.card ul li {
  margin-bottom: 0.4rem;
}

/* Card colour variants */
.card--gold {
  background: linear-gradient(160deg, #131008 0%, #0f0e08 100%);
  border-color: #2a2000;
}
.card--gold .card__date { border-color: var(--gold-dark); color: var(--gold); }
.card--gold h2 { color: var(--gold-light); }

.card--red {
  background: linear-gradient(160deg, #130808 0%, #0f0808 100%);
  border-color: #2a0808;
}
.card--red .card__date { border-color: var(--red); color: var(--red-light); }
.card--red h2 { color: #e07070; }

.card--dark {
  background: linear-gradient(160deg, #0e0e0e 0%, #0b0b0b 100%);
  border-color: #1c1c1c;
}
.card--dark h2 { color: #d0c8b8; }

.card--sepia {
  background: linear-gradient(160deg, #100f0c 0%, #0d0c09 100%);
  border-color: #201c14;
}
.card--sepia h2 { color: #d4c090; }

.card--blood {
  background: linear-gradient(160deg, #160808 0%, #110606 100%);
  border-color: #3a0808;
  box-shadow: inset 0 0 60px rgba(120,0,0,0.08);
}
.card--blood h2 { color: #e06060; }

.card--soviet {
  background: linear-gradient(160deg, #0a0f1a 0%, #08080f 100%);
  border-color: #151e30;
}
.card--soviet h2 { color: #8090b0; }

.card--memorial {
  background: linear-gradient(160deg, #0d0d10 0%, #090910 100%);
  border-color: #1a1a28;
}
.card--memorial h2 { color: #a0a0c8; }

.card--hope {
  background: linear-gradient(160deg, #080f0a 0%, #060c08 100%);
  border-color: #102018;
}
.card--hope h2 { color: #80c890; }

/* ===== HISTORICAL IMAGE ===== */
.historical-img {
  margin: 1.25rem 0;
  border-radius: var(--radius-sm);
  overflow: hidden;
  border: 1px solid #222;
}

.img-art {
  height: 280px;
  display: flex;
  align-items: center;
  justify-content: center;
  position: relative;
  overflow: hidden;
}

/* Art backgrounds per section */
.img-art {
  background: linear-gradient(135deg, #1a1208 0%, #0f0c06 100%);
}

.img-art--fortress {
  background:
    radial-gradient(ellipse at 30% 60%, rgba(80,60,20,0.4), transparent 60%),
    linear-gradient(160deg, #1a1510 0%, #0d0b08 100%);
}

.img-art--napoleon {
  background:
    radial-gradient(ellipse at 70% 40%, rgba(120,40,10,0.3), transparent 60%),
    radial-gradient(ellipse at 20% 70%, rgba(60,40,0,0.3), transparent 50%),
    linear-gradient(160deg, #150f08 0%, #0d0905 100%);
}

.img-art--pale {
  background:
    radial-gradient(ellipse at 50% 50%, rgba(60,50,20,0.3), transparent 70%),
    linear-gradient(160deg, #10100c 0%, #0a0a07 100%);
}

.img-art--pogrom {
  background:
    radial-gradient(ellipse at 50% 80%, rgba(160,20,20,0.3), transparent 60%),
    radial-gradient(ellipse at 30% 30%, rgba(120,60,0,0.2), transparent 50%),
    linear-gradient(160deg, #160808 0%, #0d0505 100%);
}

.img-art--soviet {
  background:
    radial-gradient(ellipse at 30% 50%, rgba(10,30,80,0.4), transparent 60%),
    linear-gradient(160deg, #080a12 0%, #060708 100%);
}

.img-art--yevsek {
  background:
    radial-gradient(ellipse at 60% 40%, rgba(10,20,60,0.4), transparent 60%),
    linear-gradient(160deg, #080a14 0%, #060708 100%);
}

.img-art--prison {
  background:
    linear-gradient(160deg, #100808 0%, #0a0606 100%);
}

.img-art--gulag {
  background:
    radial-gradient(ellipse at 30% 60%, rgba(20,30,50,0.4), transparent 60%),
    radial-gradient(ellipse at 70% 30%, rgba(50,50,60,0.2), transparent 50%),
    linear-gradient(160deg, #0a0c10 0%, #07080a 100%);
}

.img-art--memorial {
  background:
    radial-gradient(ellipse at 50% 50%, rgba(20,20,60,0.4), transparent 70%),
    linear-gradient(160deg, #08080d 0%, #060608 100%);
}

.img-art--stalinist {
  background:
    radial-gradient(ellipse at 40% 40%, rgba(80,20,20,0.3), transparent 60%),
    linear-gradient(160deg, #120808 0%, #0a0606 100%);
}

.img-art--futerfas {
  background:
    radial-gradient(ellipse at 50% 50%, rgba(80,60,0,0.3), transparent 70%),
    linear-gradient(160deg, #120f06 0%, #0a0c06 100%);
}

.img-art--refusenik {
  background:
    radial-gradient(ellipse at 50% 40%, rgba(20,40,80,0.3), transparent 60%),
    linear-gradient(160deg, #080c14 0%, #060810 100%);
}

.img-art--liberation {
  background:
    radial-gradient(ellipse at 50% 40%, rgba(0,60,30,0.3), transparent 60%),
    linear-gradient(160deg, #060e0a 0%, #060a07 100%);
}

.img-art--chabad-founding {
  background:
    radial-gradient(ellipse at 50% 50%, rgba(80,60,10,0.3), transparent 70%),
    linear-gradient(160deg, #100e06 0%, #0c0a05 100%);
}

.img-art__inner {
  text-align: center;
  z-index: 1;
  position: relative;
}

.img-art__icon {
  display: block;
  font-size: 3.5rem;
  margin-bottom: 0.75rem;
  filter: drop-shadow(0 4px 20px rgba(0,0,0,0.8));
  opacity: 0.7;
}

.img-art__text {
  display: block;
  font-family: "Segoe UI", sans-serif;
  font-size: 0.75rem;
  letter-spacing: 0.1em;
  color: #504838;
  text-transform: uppercase;
}

/* Decorative frame lines */
.img-art::before,
.img-art::after {
  content: "";
  position: absolute;
  border: 1px solid rgba(255,255,255,0.04);
  border-radius: 6px;
}
.img-art::before { inset: 8px; }
.img-art::after { inset: 16px; opacity: 0.5; }

.historical-img figcaption {
  padding: 0.65rem 1rem;
  font-size: 0.82rem;
  color: var(--text-muted);
  font-style: italic;
  border-top: 1px solid var(--border);
  background: rgba(0,0,0,0.3);
  line-height: 1.5;
}

/* ===== QUOTE BLOCK ===== */
.quote-block {
  margin: 1.5rem 0;
  padding: 1.25rem 1.5rem;
  border-left: 3px solid #333;
  background: rgba(255,255,255,0.02);
  border-radius: 0 var(--radius-sm) var(--radius-sm) 0;
}

.quote-block--gold { border-left-color: var(--gold-dark); background: rgba(150,100,0,0.05); }
.quote-block--red { border-left-color: var(--red); background: rgba(120,0,0,0.05); }
.quote-block--memorial { border-left-color: #3a3a6a; background: rgba(20,20,80,0.05); }

.quote-block blockquote {
  font-style: italic;
  font-size: 1.05rem;
  color: #d0c8b8;
  margin-bottom: 0.5rem;
  line-height: 1.65;
}

.quote-block cite {
  font-size: 0.82rem;
  color: var(--text-muted);
  font-style: normal;
}

/* ===== FACT BOX ===== */
.fact-box {
  margin: 1.5rem 0;
  padding: 1.25rem 1.5rem;
  border: 1px solid #2a2218;
  border-radius: var(--radius-sm);
  background: rgba(150,100,0,0.04);
}

.fact-box--dark {
  border-color: #1e1e1e;
  background: rgba(255,255,255,0.02);
}

.fact-box__title {
  font-family: "Segoe UI", sans-serif;
  font-size: 0.8rem;
  letter-spacing: 0.1em;
  text-transform: uppercase;
  color: var(--gold);
  margin-bottom: 0.75rem;
  font-weight: 700;
}

.fact-box--dark .fact-box__title { color: #888; }

.fact-box ul {
  padding-left: 1.25rem;
  color: #b8b0a0;
}

.fact-box p {
  color: #b8b0a0 !important;
  margin: 0.5rem 0 !important;
}

/* ===== EMPHASIS TEXT ===== */
.emphasis-text {
  font-style: italic;
  color: #b0a888 !important;
  border-top: 1px solid #222;
  padding-top: 1rem;
  margin-top: 1.25rem !important;
}

/* ===== MINI TIMELINE ===== */
.timeline-mini {
  margin: 1.5rem 0;
  border-left: 2px solid #2a2a2a;
  padding-left: 1.25rem;
}

.tm-item {
  display: flex;
  gap: 1rem;
  margin-bottom: 0.85rem;
  align-items: flex-start;
}

.tm-year {
  font-family: "Segoe UI", sans-serif;
  font-size: 0.78rem;
  font-weight: 700;
  color: var(--text-dim);
  white-space: nowrap;
  min-width: 90px;
  padding-top: 0.15rem;
}

.tm-event {
  font-size: 0.9rem;
  color: #a8a098;
}

.tm-item--critical .tm-year { color: var(--red-light); }
.tm-item--critical .tm-event { color: #c0a8a0; }

/* ===== CONTRIBUTIONS GRID ===== */
.contributions-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(220px, 1fr));
  gap: 1rem;
  margin: 1.25rem 0;
}

.contrib-item {
  display: flex;
  gap: 0.85rem;
  padding: 1rem;
  border: 1px solid #1e1e1e;
  border-radius: var(--radius-sm);
  background: rgba(255,255,255,0.02);
}

.contrib-icon {
  font-size: 1.5rem;
  flex-shrink: 0;
}

.contrib-item strong {
  display: block;
  font-size: 0.9rem;
  color: #d0c8b8;
  margin-bottom: 0.3rem;
}

.contrib-item p {
  font-size: 0.85rem;
  color: #908880 !important;
  margin: 0 !important;
}

/* ===== DEATH NOTICE ===== */
.death-notice {
  margin: 1.5rem 0;
  padding: 1.25rem 1.5rem;
  border: 1px solid #2a1818;
  border-radius: var(--radius-sm);
  background: rgba(80,0,0,0.08);
}

.death-notice h3 {
  margin-top: 0 !important;
  font-size: 0.95rem;
  color: #c06060;
}

.death-notice p { color: #b8a8a0 !important; margin: 0.5rem 0 !important; }

/* ===== INGRATITUDE BOX ===== */
.ingratitude-box {
  margin: 1.5rem 0;
  padding: 1.5rem;
  border: 1px solid #2a1000;
  border-radius: var(--radius-sm);
  background: rgba(80,20,0,0.1);
}

.ingratitude-box h3 { margin-top: 0 !important; color: #c07840; }
.ingratitude-box p { color: #b8a898 !important; }
.ingratitude-box ul { color: #b0a898; }

/* ===== RESTRICTIONS GRID ===== */
.restrictions-list { margin: 1.25rem 0; }
.restrictions-list h3 { margin-bottom: 0.75rem; }

.rest-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(250px, 1fr));
  gap: 0.5rem;
}

.rest-item {
  padding: 0.6rem 0.9rem;
  border-radius: var(--radius-sm);
  font-size: 0.88rem;
}

.rest-item--bad {
  background: rgba(100,0,0,0.12);
  border: 1px solid #2a1010;
  color: #c09090;
}

/* ===== LEADERS TIMELINE ===== */
.leaders-timeline { margin: 1rem 0; }

.leader-item {
  padding: 0.85rem 1rem;
  margin-bottom: 0.65rem;
  border-left: 3px solid #2a2a2a;
  background: rgba(255,255,255,0.02);
  border-radius: 0 var(--radius-sm) var(--radius-sm) 0;
}

.leader-name { font-size: 0.95rem; color: #d4c898; font-weight: bold; }
.leader-dates { font-size: 0.78rem; color: var(--text-dim); margin: 0.15rem 0; font-family: "Segoe UI", sans-serif; }
.leader-event { font-size: 0.87rem; color: #a89888; margin-top: 0.35rem; }

/* ===== POGROM TIMELINE ===== */
.pogrom-timeline { margin: 1.25rem 0; }

.pt-era {
  margin-bottom: 1.25rem;
  border: 1px solid #2a1010;
  border-radius: var(--radius-sm);
  overflow: hidden;
}

.pt-era__header {
  padding: 0.7rem 1rem;
  background: rgba(80,10,10,0.3);
  font-size: 0.9rem;
  font-weight: bold;
  color: #d07070;
  border-bottom: 1px solid #2a1010;
}

.pt-era__content {
  padding: 1rem;
}

.pt-era__content p { color: #b8a8a0; margin: 0.5rem 0; font-size: 0.9rem; }
.pt-era__content ul { padding-left: 1.25rem; color: #b0a8a0; font-size: 0.9rem; }
.pt-era__content li { margin-bottom: 0.3rem; }

.victims-count {
  margin-top: 0.75rem;
  padding: 0.5rem 0.85rem;
  background: rgba(120,0,0,0.15);
  border-radius: 6px;
  font-size: 0.85rem;
  color: #c08080;
  font-style: italic;
}

/* ===== CAMPAIGN / POSTWAR GRID ===== */
.campaign-grid {
  display: grid;
  gap: 1rem;
  margin: 1.25rem 0;
}

.camp-item {
  padding: 1.1rem 1.25rem;
  border: 1px solid #1e1e28;
  border-radius: var(--radius-sm);
  background: rgba(20,20,40,0.3);
}

.camp-item--critical {
  border-color: #3a1818;
  background: rgba(60,10,10,0.2);
}

.camp-year {
  font-family: "Segoe UI", sans-serif;
  font-size: 0.75rem;
  letter-spacing: 0.1em;
  color: var(--text-dim);
  text-transform: uppercase;
  margin-bottom: 0.35rem;
}

.camp-title {
  font-size: 0.95rem;
  font-weight: bold;
  color: #a0a8c0;
  margin-bottom: 0.5rem;
}

.camp-item p { font-size: 0.88rem; color: #909098; }

/* ===== YEVSEK ACTIONS ===== */
.yevsek-actions { margin: 1.25rem 0; }

.action-item {
  margin-bottom: 0.85rem;
  padding: 1rem 1.25rem;
  border-radius: var(--radius-sm);
}

.action-item--evil {
  background: rgba(60,0,0,0.1);
  border: 1px solid #1e1010;
}

.action-item strong {
  display: block;
  font-size: 0.9rem;
  color: #c07060;
  margin-bottom: 0.35rem;
}

.action-item p {
  font-size: 0.87rem;
  color: #908880 !important;
  margin: 0 !important;
}

/* ===== BIO CARD ===== */
.bio-card {
  margin: 1.25rem 0;
  border: 1px solid var(--gold-dark);
  border-radius: var(--radius-sm);
  overflow: hidden;
  max-width: 480px;
}

.bio-card__header {
  padding: 0.6rem 1rem;
  background: rgba(150,100,0,0.15);
  font-family: "Segoe UI", sans-serif;
  font-size: 0.75rem;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  color: var(--gold);
}

.bio-card__row {
  display: flex;
  padding: 0.5rem 1rem;
  border-bottom: 1px solid #1e1808;
  font-size: 0.88rem;
  color: #b0a890;
}

.bio-card__row:last-child { border-bottom: none; }

.bio-card__row span {
  min-width: 130px;
  color: var(--text-dim);
}

/* ===== GULAG STORY ===== */
.gulag-story {
  margin: 1.25rem 0;
  padding: 1.25rem;
  border: 1px solid #181808;
  border-radius: var(--radius-sm);
  background: rgba(80,60,0,0.06);
}

.gulag-story h4 { color: var(--gold); margin-top: 0 !important; }

/* ===== REPRESSION STATS ===== */
.repression-stats {
  display: flex;
  gap: 1rem;
  margin: 1.5rem 0;
  flex-wrap: wrap;
}

.stat-item {
  flex: 1;
  min-width: 140px;
  text-align: center;
  padding: 1rem;
  border: 1px solid #2a1818;
  border-radius: var(--radius-sm);
  background: rgba(60,10,10,0.12);
}

.stat-number {
  font-size: 1.6rem;
  font-weight: 700;
  color: #c07070;
  line-height: 1;
  margin-bottom: 0.35rem;
}

.stat-label {
  font-size: 0.78rem;
  color: #806868;
  line-height: 1.4;
}

/* ===== HOLOCAUST LOCATIONS ===== */
.holocaust-locations {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(200px, 1fr));
  gap: 1rem;
  margin: 1.25rem 0;
}

.hl-item {
  padding: 1rem;
  border: 1px solid #1a1a2a;
  border-radius: var(--radius-sm);
  background: rgba(10,10,30,0.3);
}

.hl-item strong {
  display: block;
  font-size: 0.9rem;
  color: #a0a0c0;
  margin-bottom: 0.4rem;
}

.hl-item p {
  font-size: 0.87rem;
  color: #808090 !important;
  margin: 0 !important;
}

/* ===== LATE SOVIET ===== */
.latesoviet-facts { margin: 1.25rem 0; }

.lsf-item {
  margin-bottom: 1rem;
  padding: 0.9rem 1.1rem;
  border-left: 2px solid #2a2a3a;
  background: rgba(255,255,255,0.02);
  border-radius: 0 var(--radius-sm) var(--radius-sm) 0;
}

.lsf-item strong {
  display: block;
  font-size: 0.9rem;
  color: #9090b0;
  margin-bottom: 0.35rem;
}

.lsf-item p { font-size: 0.87rem; color: #808090 !important; margin: 0 !important; }

/* ===== LIBERATION EVENTS ===== */
.liberation-events {
  margin: 1.25rem 0;
  border-left: 2px solid #184028;
}

.le-item {
  display: flex;
  gap: 1rem;
  padding: 0.65rem 1.25rem;
  border-bottom: 1px solid #102018;
  font-size: 0.9rem;
  color: #90b898;
  align-items: baseline;
}

.le-item:last-child { border-bottom: none; }

.le-year {
  font-family: "Segoe UI", sans-serif;
  font-size: 0.78rem;
  font-weight: 700;
  color: #40806a;
  white-space: nowrap;
  min-width: 50px;
}

.conclusion-text {
  margin: 1.5rem 0 0;
  padding: 1.25rem;
  border-top: 1px solid #102018;
}

.conclusion-text p { color: #90b090 !important; margin: 0.65rem 0 !important; }

/* ===== MEMORIAL WALL ===== */
.memorial {
  margin: 3rem 0 1rem;
  padding: 2.5rem 2rem;
  border: 1px solid #1a1a2a;
  border-radius: var(--radius);
  background: linear-gradient(160deg, #08080e 0%, #050508 100%);
  text-align: center;
}

.memorial__title {
  font-size: 1.8rem;
  color: #a0a0c8;
  margin-bottom: 0.5rem;
}

.memorial__sub {
  font-size: 0.9rem;
  color: var(--text-dim);
  font-style: italic;
  margin-bottom: 2rem;
}

.memorial__grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(260px, 1fr));
  gap: 1rem;
  text-align: left;
}

.mem-card {
  padding: 1.1rem 1.25rem;
  border: 1px solid #1e1e2e;
  border-radius: var(--radius-sm);
  background: rgba(255,255,255,0.02);
}

.mem-card__name {
  font-size: 0.92rem;
  color: #c0b8d8;
  font-weight: bold;
  margin-bottom: 0.2rem;
}

.mem-card__dates {
  font-family: "Segoe UI", sans-serif;
  font-size: 0.75rem;
  color: #505060;
  margin-bottom: 0.5rem;
}

.mem-card__desc {
  font-size: 0.85rem;
  color: #807898;
  line-height: 1.55;
}

/* ===== FOOTER ===== */
.footer {
  background: #060606;
  border-top: 1px solid #1a1a1a;
  padding: 2.5rem 1.5rem;
  text-align: center;
}

.footer__inner {
  max-width: 700px;
  margin: 0 auto;
}

.footer__star {
  font-size: 2rem;
  color: var(--gold-dark);
  display: block;
  margin-bottom: 1rem;
  opacity: 0.5;
}

.footer__quote {
  font-style: italic;
  font-size: 1.05rem;
  color: #a0987a;
  margin-bottom: 0.25rem;
}

.footer__attr {
  font-size: 0.82rem;
  color: var(--text-dim);
  margin-bottom: 1.25rem;
}

.footer__line {
  border: none;
  border-top: 1px solid #1e1e1e;
  margin: 1.25rem 0;
}

.footer__note {
  font-size: 0.8rem;
  color: #484440;
  line-height: 1.6;
}

/* ===== PORTRAIT IMAGES ===== */
.portrait-img {
  display: block;
  width: 100%;
  border-radius: var(--radius-sm);
}

.historical-photo {
  display: block;
  width: 100%;
  max-height: 380px;
  object-fit: cover;
  object-position: center;
  border-radius: var(--radius-sm);
}

.historical-photo--map {
  max-height: none;
  object-fit: contain;
  background: #f0f0e8;
}

.portrait-img--solo {
  max-width: 320px;
  margin: 0 auto;
  max-height: 420px;
  object-fit: cover;
  object-position: top;
}

/* ===== PORTRAIT PAIR ===== */
.portrait-pair {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 0;
  background: #0a0a0a;
}

.portrait-pair__item {
  text-align: center;
  padding: 1rem 0.75rem 0.75rem;
  border-right: 1px solid #1a1a1a;
}

.portrait-pair__item:last-child { border-right: none; }

.portrait-pair__item img {
  width: 100%;
  max-height: 320px;
  object-fit: cover;
  object-position: top;
  border-radius: 8px;
  display: block;
}

.portrait-pair__item--tsar img {
  filter: sepia(0.15) contrast(0.95);
}

.portrait-pair__name {
  font-size: 0.9rem;
  font-weight: bold;
  color: #d0c8b8;
  margin-top: 0.5rem;
}

.portrait-pair__role {
  font-size: 0.75rem;
  color: #666;
  line-height: 1.5;
  margin-top: 0.2rem;
}

.portrait-pair__item--tsar .portrait-pair__name { color: #8090a0; }

/* ===== TSAR INLINE PORTRAIT ===== */
.tsar-portrait-inline {
  display: flex;
  gap: 1.25rem;
  align-items: flex-start;
  margin: 1.25rem 0;
  padding: 1rem 1.25rem;
  border: 1px solid #1a1e28;
  border-radius: var(--radius-sm);
  background: rgba(10, 20, 50, 0.15);
}

.tsar-portrait-inline img {
  width: 110px;
  flex-shrink: 0;
  border-radius: 6px;
  object-fit: cover;
  object-position: top;
  filter: sepia(0.2) contrast(0.9);
}

.tsar-portrait-inline__caption {
  font-size: 0.87rem;
  color: #8090a0;
  line-height: 1.6;
  padding-top: 0.25rem;
}

.tsar-portrait-inline__caption strong {
  display: block;
  color: #a0b0c0;
  font-size: 0.95rem;
  margin-bottom: 0.25rem;
}

/* ===== FOREWORD ===== */
.foreword {
  margin: 2rem 0 1rem;
  padding: 0 1rem;
  text-align: center;
}

.foreword__line {
  width: 60px;
  height: 1px;
  background: linear-gradient(to right, transparent, var(--gold-dark), transparent);
  margin: 1.25rem auto;
}

.foreword__text {
  font-size: clamp(1.05rem, 2.2vw, 1.3rem);
  line-height: 1.85;
  color: #b0a888;
  font-style: italic;
  max-width: 820px;
  margin: 0 auto;
}

.foreword__text strong {
  color: var(--gold-light);
  font-style: normal;
}

/* ===== REBBES / TSARS GALLERY ===== */
.rebbes-gallery {
  margin: 1.5rem 0 2.5rem;
  padding: 2rem 1.5rem;
  border: 1px solid #1e1a10;
  border-radius: var(--radius);
  background: linear-gradient(160deg, #0d0c08 0%, #090908 100%);
  text-align: center;
}

.rebbes-gallery__title {
  font-size: 1.1rem;
  color: var(--gold);
  font-weight: bold;
  margin-bottom: 0.35rem;
}

.rebbes-gallery__subtitle {
  font-size: 0.82rem;
  color: var(--text-dim);
  font-style: italic;
  margin-bottom: 1.5rem;
}

.rebbes-gallery__grid,
.tsars-gallery__grid {
  display: flex;
  gap: 0.75rem;
  justify-content: center;
  flex-wrap: wrap;
}

.rebbes-gallery__divider {
  text-align: center;
  font-family: "Segoe UI", sans-serif;
  font-size: 0.7rem;
  letter-spacing: 0.2em;
  text-transform: uppercase;
  color: var(--red);
  margin: 1.25rem 0;
  position: relative;
}

.rebbes-gallery__divider::before,
.rebbes-gallery__divider::after {
  content: "";
  position: absolute;
  top: 50%;
  width: 35%;
  height: 1px;
  background: linear-gradient(to right, transparent, var(--red-dark));
}

.rebbes-gallery__divider::before { left: 0; background: linear-gradient(to right, transparent, var(--red-dark)); }
.rebbes-gallery__divider::after { right: 0; background: linear-gradient(to left, transparent, var(--red-dark)); }

/* ===== GALLERY CARD ===== */
.gallery-card {
  width: 120px;
  text-align: center;
  text-decoration: none;
  display: block;
  border-radius: var(--radius-sm);
  overflow: hidden;
  border: 1px solid transparent;
  transition: border-color 0.2s, transform 0.2s;
  background: #0d0c08;
}

.gallery-card:hover {
  transform: translateY(-3px);
}

.gallery-card--rebbe { border-color: #2a2010; }
.gallery-card--rebbe:hover { border-color: var(--gold-dark); }
.gallery-card--tsar { border-color: #151e2a; width: 100px; }
.gallery-card--tsar:hover { border-color: #2a3a50; }
.gallery-card--tsar-evil { border-color: #2a1010 !important; text-decoration: none; }
.gallery-card--tsar-evil:hover { border-color: var(--red) !important; }
.gallery-card--tsar-evil .gallery-card__name { color: #c07070; }

.gallery-card img {
  width: 100%;
  height: 140px;
  object-fit: cover;
  object-position: top;
  display: block;
}

.gallery-card--tsar img {
  height: 120px;
  filter: sepia(0.2) contrast(0.9);
}

.gallery-card--no-photo {
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: flex-start;
  padding-top: 0;
}

.gallery-card__placeholder {
  width: 100%;
  height: 140px;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 2.5rem;
  background: #100e08;
  color: var(--gold-dark);
  opacity: 0.4;
}

.gallery-card__name {
  font-size: 0.78rem;
  font-weight: bold;
  color: #c0b8a0;
  padding: 0.4rem 0.5rem 0.1rem;
  line-height: 1.3;
}

.gallery-card--tsar .gallery-card__name { color: #8090a8; }

.gallery-card__dates {
  font-size: 0.68rem;
  color: #555;
  padding-bottom: 0.5rem;
  font-family: "Segoe UI", sans-serif;
}

/* ===== REBBE BADGE ===== */
.rebbe-badge {
  display: inline-block;
  padding: 0.35rem 1rem;
  border: 1px solid #2a2010;
  border-radius: 999px;
  background: rgba(150, 100, 0, 0.08);
  color: #a08848;
  font-family: "Segoe UI", sans-serif;
  font-size: 0.78rem;
  letter-spacing: 0.04em;
  margin-bottom: 1.25rem;
}

.card--red .rebbe-badge {
  border-color: #2a1010;
  background: rgba(100, 20, 20, 0.1);
  color: #a07070;
}

.card--dark .rebbe-badge {
  border-color: #222;
  background: rgba(255,255,255,0.03);
  color: #888;
}

.card--blood .rebbe-badge {
  border-color: #3a1010;
  background: rgba(120, 20, 20, 0.1);
  color: #b07070;
}

/* ===== ARREST BLOCK ===== */
.arrest-block {
  margin: 1.25rem 0;
  padding: 1.25rem 1.5rem;
  border: 1px solid #2a1818;
  border-radius: var(--radius-sm);
  background: rgba(80, 10, 10, 0.12);
}

.arrest-block--blue {
  border-color: #1a1e30;
  background: rgba(10, 20, 60, 0.15);
}

.arrest-block--red {
  border-color: #3a1010;
  background: rgba(100, 10, 10, 0.15);
}

.arrest-block__label {
  font-family: "Segoe UI", sans-serif;
  font-size: 0.72rem;
  letter-spacing: 0.14em;
  text-transform: uppercase;
  color: var(--red-light);
  margin-bottom: 0.65rem;
  font-weight: 700;
}

.arrest-block--blue .arrest-block__label {
  color: #7090c0;
}

.arrest-block p {
  font-size: 0.92rem;
  color: #b0a8a0 !important;
  margin: 0.5rem 0 !important;
}

/* ===== UVAROV BOX ===== */
.uvarov-box {
  margin: 1.25rem 0;
  padding: 1rem 1.25rem;
  border: 1px solid #202838;
  border-left: 3px solid #3a4a6a;
  border-radius: 0 var(--radius-sm) var(--radius-sm) 0;
  background: rgba(20, 30, 60, 0.15);
}

.uvarov-box__label {
  font-family: "Segoe UI", sans-serif;
  font-size: 0.72rem;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  color: #7080a0;
  margin-bottom: 0.5rem;
  font-weight: 700;
}

.uvarov-box p {
  font-size: 0.88rem;
  color: #808898 !important;
  margin: 0 !important;
  line-height: 1.6;
}

/* ===== CHANA STORY ===== */
.chana-story {
  margin: 1.25rem 0;
  padding: 1.25rem 1.5rem;
  border: 1px solid #2a2010;
  border-radius: var(--radius-sm);
  background: rgba(100, 70, 0, 0.06);
}

.chana-story p {
  font-size: 0.92rem;
  color: #b8b098 !important;
  margin: 0.6rem 0 !important;
}

/* ===== MEM CARD HIGHLIGHTED ===== */
.mem-card--highlighted {
  border-color: #2a2010;
  background: rgba(150, 100, 0, 0.06);
}

.mem-card--highlighted .mem-card__name { color: var(--gold-light); }

/* ===== STRONG MORE VISIBLE ===== */
.card__body strong { color: #d4a820; font-weight: 800; }
.card__body h3 { font-weight: 800; letter-spacing: 0.01em; }
.fact-box__title { font-weight: 800; font-size: 1rem; letter-spacing: 0.02em; }
.tm-year { font-weight: 900 !important; color: #c49820 !important; }
.arrest-block__label { font-weight: 800; font-size: 0.88rem; }

/* ===== INFOGRAPHIC STATS ===== */
.infographic-stats {
  background: linear-gradient(135deg, #0d0900 0%, #1a1000 100%);
  border: 1px solid #2a1e00;
  border-radius: 12px;
  padding: 2.5rem 1.5rem 2rem;
  margin: 2rem 0;
}
.infographic-stats__title {
  text-align: center;
  font-size: 0.78rem;
  letter-spacing: 0.18em;
  text-transform: uppercase;
  color: #6a5020;
  margin-bottom: 1.8rem;
  font-weight: 700;
}
.infostats-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(140px, 1fr));
  gap: 1rem;
}
.infostat {
  text-align: center;
  padding: 1.1rem 0.5rem;
  border: 1px solid #1e1500;
  border-radius: 8px;
  background: rgba(150, 100, 0, 0.04);
}
.infostat__num {
  font-size: 2.4rem;
  font-weight: 900;
  color: var(--gold);
  line-height: 1;
  margin-bottom: 0.45rem;
  font-family: Georgia, serif;
}
.infostat__num--red { color: #c03030; }
.infostat__label {
  font-size: 0.7rem;
  color: #6a5820;
  letter-spacing: 0.02em;
  line-height: 1.45;
  font-weight: 600;
}

/* ===== MEGA TIMELINE ===== */
.mega-timeline {
  margin: 2.5rem 0;
  overflow-x: auto;
  -webkit-overflow-scrolling: touch;
  padding-bottom: 1rem;
}
.mega-timeline__title {
  text-align: center;
  font-size: 0.78rem;
  letter-spacing: 0.18em;
  text-transform: uppercase;
  color: #6a5020;
  margin-bottom: 1.5rem;
  font-weight: 700;
}
.mega-timeline__wrap {
  min-width: 860px;
  position: relative;
  height: 240px;
}
.mega-timeline__axis {
  position: absolute;
  top: 110px;
  left: 0;
  right: 0;
  height: 3px;
  background: linear-gradient(to right, #1a1000, #6a0000 45%, #2a2a2a);
  border-radius: 2px;
}
.mega-timeline__era-band {
  position: absolute;
  top: 103px;
  height: 17px;
  border-radius: 2px;
  opacity: 0.4;
}
.mega-timeline__era-band--tsarist { background: #b88010; }
.mega-timeline__era-band--soviet  { background: #8B0000; }
.mega-timeline__era-band--late    { background: #444; }
.mega-timeline__era-label {
  position: absolute;
  top: 122px;
  font-size: 0.54rem;
  letter-spacing: 0.07em;
  text-transform: uppercase;
  color: #5a4820;
  white-space: nowrap;
}
.mega-timeline__event {
  position: absolute;
  top: 0;
  transform: translateX(-50%);
  display: flex;
  flex-direction: column;
  align-items: center;
}
.mega-timeline__dot {
  width: 9px;
  height: 9px;
  border-radius: 50%;
  background: var(--gold);
  border: 2px solid #0d0900;
  flex-shrink: 0;
  margin: 0 auto;
}
.mega-timeline__dot--critical {
  background: #c03030;
  width: 12px;
  height: 12px;
}
.mega-timeline__connector {
  width: 2px;
  background: #2a2200;
  flex: 1;
}
.mega-timeline__label {
  font-size: 0.6rem;
  color: #8a7050;
  text-align: center;
  line-height: 1.3;
  white-space: nowrap;
  max-width: 90px;
}
.mega-timeline__year {
  font-size: 0.65rem;
  font-weight: 900;
  color: #a08030;
  display: block;
  margin-bottom: 1px;
}
/* Above-axis events: label on top, dot at bottom of element, connector fills middle */
.mega-timeline__event--above {
  top: 0;
  height: 108px;
  flex-direction: column;
}
.mega-timeline__event--above .mega-timeline__label { order: 1; }
.mega-timeline__event--above .mega-timeline__connector { order: 2; }
.mega-timeline__event--above .mega-timeline__dot { order: 3; }
/* Below-axis events: dot at top, connector, label at bottom */
.mega-timeline__event--below {
  top: 113px;
  height: 120px;
  flex-direction: column;
}
.mega-timeline__event--below .mega-timeline__dot { order: 1; }
.mega-timeline__event--below .mega-timeline__connector { order: 2; }
.mega-timeline__event--below .mega-timeline__label { order: 3; }
.mega-timeline__year-markers {
  position: absolute;
  top: 108px;
  left: 0;
  right: 0;
  pointer-events: none;
}
.mega-timeline__year-start {
  position: absolute;
  left: 0;
  top: -22px;
  font-size: 0.65rem;
  font-weight: 800;
  color: #6a5020;
}
.mega-timeline__year-end {
  position: absolute;
  right: 0;
  top: -22px;
  font-size: 0.65rem;
  font-weight: 800;
  color: #6a5020;
}

/* ===== ERA NAVIGATION CARDS ===== */
.era-nav { margin: 3rem 0 2rem; }
.era-nav__title {
  text-align: center;
  font-size: 0.78rem;
  letter-spacing: 0.18em;
  text-transform: uppercase;
  color: #6a5020;
  margin-bottom: 1.5rem;
  font-weight: 700;
}
.era-nav__grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(210px, 1fr));
  gap: 1rem;
}
.era-card {
  display: block;
  text-decoration: none;
  padding: 1.5rem 1.25rem;
  border-radius: 10px;
  border: 1px solid #1e1e1e;
  background: #0d0d0d;
  transition: border-color 0.2s, background 0.2s, transform 0.15s;
  position: relative;
  overflow: hidden;
}
.era-card::before {
  content: '';
  position: absolute;
  left: 0; top: 0; bottom: 0;
  width: 3px;
}
.era-card--gold::before { background: var(--gold-dark); }
.era-card--blood::before { background: #6a0000; }
.era-card--soviet::before { background: #8B0000; }
.era-card--dark::before { background: #333; }
.era-card:hover { transform: translateY(-3px); }
.era-card--gold:hover  { border-color: var(--gold-dark); background: rgba(150,100,0,0.07); }
.era-card--blood:hover { border-color: #4a0000; background: rgba(139,0,0,0.07); }
.era-card--soviet:hover{ border-color: #6a0000; background: rgba(139,0,0,0.05); }
.era-card--dark:hover  { border-color: #444; background: rgba(60,60,60,0.05); }
.era-card__years {
  font-size: 0.68rem;
  letter-spacing: 0.1em;
  color: #5a4820;
  margin-bottom: 0.4rem;
  text-transform: uppercase;
  font-weight: 700;
}
.era-card__title {
  font-size: 1.05rem;
  font-weight: 800;
  color: var(--gold-light);
  margin-bottom: 0.5rem;
  line-height: 1.25;
}
.era-card__desc {
  font-size: 0.76rem;
  color: #6a5820;
  line-height: 1.55;
}
.era-card__arrow {
  display: block;
  margin-top: 0.8rem;
  color: #4a3810;
  font-size: 1rem;
  font-weight: 700;
}

/* ===== PAGE NAV (era pages) ===== */
.page-nav {
  background: rgba(10,10,10,0.97);
  border-bottom: 1px solid #1e1e1e;
  padding: 0.7rem 1.2rem;
  display: flex;
  align-items: center;
  gap: 0.8rem;
  position: sticky;
  top: 0;
  z-index: 100;
  backdrop-filter: blur(10px);
  overflow-x: auto;
  scrollbar-width: none;
}
.page-nav::-webkit-scrollbar { display: none; }
.page-nav__home {
  color: var(--gold);
  text-decoration: none;
  font-size: 0.78rem;
  font-weight: 800;
  letter-spacing: 0.04em;
  white-space: nowrap;
  padding: 0.3rem 0.8rem;
  border: 1px solid var(--gold-dark);
  border-radius: 999px;
  flex-shrink: 0;
  transition: background 0.15s;
}
.page-nav__home:hover { background: rgba(150,100,0,0.12); }
.page-nav__sep { color: #333; flex-shrink: 0; }
.page-nav__links {
  display: flex;
  gap: 0.3rem;
  flex-wrap: nowrap;
  min-width: 0;
}
.page-nav__link {
  color: #888;
  text-decoration: none;
  font-size: 0.73rem;
  font-weight: 700;
  padding: 0.3rem 0.7rem;
  border: 1px solid #2a2a2a;
  border-radius: 999px;
  white-space: nowrap;
  transition: color 0.15s, border-color 0.15s;
}
.page-nav__link:hover { color: var(--gold); border-color: var(--gold-dark); }
.page-nav__era {
  margin-left: auto;
  font-size: 0.65rem;
  letter-spacing: 0.1em;
  text-transform: uppercase;
  color: #3a2e10;
  white-space: nowrap;
  flex-shrink: 0;
  font-weight: 700;
}

/* ===== MAP INFOGRAPHIC ===== */
.map-infographic {
  border: 1px solid #1e1a0a;
  border-radius: 10px;
  overflow: hidden;
  margin: 2rem 0;
}
.map-infographic__header {
  background: #0d0900;
  padding: 0.7rem 1.2rem;
  font-size: 0.75rem;
  letter-spacing: 0.1em;
  text-transform: uppercase;
  color: #7a6020;
  border-bottom: 1px solid #1e1a0a;
  font-weight: 700;
}
.map-infographic__img {
  width: 100%;
  max-height: 340px;
  object-fit: contain;
  background: #f0f0e8;
  display: block;
}
.map-infographic__caption {
  background: #0a0800;
  padding: 0.55rem 1rem;
  font-size: 0.73rem;
  color: #6a5820;
  font-style: italic;
}

/* ===== RESPONSIVE ===== */
@media (max-width: 720px) {
  .card__body { padding: 1.5rem 1.25rem 2rem; }
  .card h2 { padding-right: 0; }
  .card__date { position: static; display: inline-block; margin: 1.25rem 1.25rem 0; }
  .toc__inner { justify-content: flex-start; }
  .contributions-grid { grid-template-columns: 1fr; }
  .repression-stats { flex-direction: column; }
  .holocaust-locations { grid-template-columns: 1fr; }
  .memorial__grid { grid-template-columns: 1fr; }
  .rest-grid { grid-template-columns: 1fr; }
  .era-nav__grid { grid-template-columns: 1fr 1fr; }
  .infostats-grid { grid-template-columns: repeat(3, 1fr); }
}

@media (max-width: 480px) {
  .hero h1 { font-size: 2rem; }
  .img-art { height: 200px; }
  .era-nav__grid { grid-template-columns: 1fr; }
  .infostats-grid { grid-template-columns: repeat(2, 1fr); }
  .page-nav__era { display: none; }
}
