/* ============================================================
   BUDDHIST DIPLOMACY — Components
   Nav, Hero, Cards, Ticker, Map, Newsletter, Footer
   ============================================================ */

/* ===================== TOP NAVIGATION ===================== */
.top-nav {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 12px var(--margin-desktop);
  position: fixed;
  top: 0;
  left: 0;
  right: 0;
  z-index: var(--z-header);
  transition: background var(--duration-base) var(--ease-out),
              padding var(--duration-base) var(--ease-out),
              border-color var(--duration-base) var(--ease-out),
              box-shadow var(--duration-base) var(--ease-out);
  /* Default: solid bar with crystal-clear contrast on light & dark backgrounds */
  background: rgba(245, 240, 230, 0.96);
  backdrop-filter: blur(16px);
  -webkit-backdrop-filter: blur(16px);
  border-bottom: 1px solid var(--border);
  box-shadow: 0 1px 3px rgba(23, 23, 23, 0.05);
}

[data-theme="dark"] .top-nav {
  background: rgba(19, 18, 17, 0.96);
  border-bottom: 1px solid rgba(255, 255, 255, 0.08);
  box-shadow: 0 1px 4px rgba(0, 0, 0, 0.25);
}

.top-nav.scrolled {
  padding: 10px var(--margin-desktop);
}

/* Brand */
.nav-brand {
  font-family: var(--font-display);
  font-size: 20px;
  font-weight: 700;
  color: var(--on-surface);
  text-decoration: none;
  white-space: nowrap;
  letter-spacing: -0.01em;
  transition: color var(--duration-fast) var(--ease-out);
}

.nav-brand:hover {
  color: var(--burgundy);
}

[data-theme="dark"] .nav-brand:hover {
  color: var(--gold);
}

/* Nav Links */
.nav-links {
  display: flex;
  align-items: center;
  gap: var(--space-1);
}

.nav-link {
  font-family: var(--font-body);
  font-size: var(--label-size);
  font-weight: var(--label-weight);
  letter-spacing: var(--label-spacing);
  text-transform: uppercase;
  color: var(--on-surface-secondary);
  text-decoration: none;
  padding: 6px 12px;
  position: relative;
  transition: color var(--duration-fast) var(--ease-out);
}

.nav-link:hover {
  color: var(--on-surface);
}

.nav-link.active {
  color: var(--burgundy);
  font-weight: 600;
}

[data-theme="dark"] .nav-link.active {
  color: var(--gold);
}

.nav-link::after {
  content: '';
  position: absolute;
  bottom: 0;
  left: 12px;
  right: 12px;
  height: 2px;
  background: var(--burgundy);
  transform: scaleX(0);
  transform-origin: left;
  transition: transform var(--duration-base) var(--ease-out);
}

[data-theme="dark"] .nav-link::after {
  background: var(--gold);
}

.nav-link:hover::after,
.nav-link.active::after {
  transform: scaleX(1);
}

/* Nav Actions */
.nav-actions {
  display: flex;
  align-items: center;
  gap: var(--space-2);
}

/* Nav Icon Buttons */
.nav-icon-btn {
  display: flex;
  align-items: center;
  justify-content: center;
  width: 36px;
  height: 36px;
  border-radius: var(--radius-md);
  color: var(--on-surface-secondary);
  transition: all var(--duration-fast) var(--ease-out);
}

.nav-icon-btn:hover {
  color: var(--on-surface);
  background: rgba(0, 0, 0, 0.05);
}

[data-theme="dark"] .nav-icon-btn:hover {
  color: var(--ivory);
  background: rgba(255, 255, 255, 0.08);
}

.nav-icon-btn svg {
  width: 18px;
  height: 18px;
}

/* Nav Latest Button */
.nav-latest-btn {
  font-family: var(--font-body);
  font-size: 10px;
  font-weight: 600;
  letter-spacing: var(--label-spacing);
  text-transform: uppercase;
  padding: 5px 14px;
  border: 1px solid var(--border-strong);
  border-radius: var(--radius-sm);
  color: var(--on-surface-secondary);
  text-decoration: none;
  transition: all var(--duration-fast) var(--ease-out);
}

.nav-latest-btn:hover {
  border-color: var(--burgundy);
  color: var(--burgundy);
}

[data-theme="dark"] .nav-latest-btn:hover {
  border-color: var(--gold);
  color: var(--gold);
}

/* Theme Toggle */
.theme-toggle {
  position: relative;
  width: 52px;
  height: 28px;
  background: var(--surface-panel);
  border: 1px solid var(--border-strong);
  border-radius: var(--radius-pill);
  cursor: pointer;
  padding: 0;
  display: inline-flex;
  align-items: center;
  overflow: hidden;
  transition: background var(--duration-base), border-color var(--duration-base), box-shadow var(--duration-base);
  box-shadow: inset 0 1px 2px rgba(0, 0, 0, 0.06);
}

.theme-toggle:hover {
  border-color: var(--gold);
}

.theme-toggle-track {
  width: 100%;
  height: 100%;
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 0 6px;
  pointer-events: none;
}

.theme-toggle-icon {
  display: flex;
  align-items: center;
  justify-content: center;
  width: 13px;
  height: 13px;
  transition: opacity var(--duration-base), transform var(--duration-base), color var(--duration-base);
}

.theme-toggle-icon svg {
  width: 12px;
  height: 12px;
}

.theme-toggle-sun {
  color: var(--gold);
  opacity: 1;
  transform: scale(1);
}

.theme-toggle-moon {
  color: var(--on-surface-tertiary);
  opacity: 0.35;
  transform: scale(0.8);
}

.theme-toggle-thumb {
  position: absolute;
  top: 2px;
  left: 2px;
  width: 22px;
  height: 22px;
  background: #FFFFFF;
  border-radius: 50%;
  box-shadow: 0 1px 4px rgba(0, 0, 0, 0.18), 0 0 1px rgba(0, 0, 0, 0.1);
  transition: transform 320ms cubic-bezier(0.34, 1.56, 0.64, 1), background var(--duration-base), border-color var(--duration-base), box-shadow var(--duration-base);
  pointer-events: none;
}

/* Dark Mode State for Toggle */
[data-theme="dark"] .theme-toggle {
  background: #1C1B19;
  border-color: rgba(198, 150, 59, 0.35);
  box-shadow: inset 0 1px 3px rgba(0, 0, 0, 0.4);
}

[data-theme="dark"] .theme-toggle-sun {
  color: var(--on-surface-tertiary);
  opacity: 0.35;
  transform: scale(0.8);
}

[data-theme="dark"] .theme-toggle-moon {
  color: var(--gold);
  opacity: 1;
  transform: scale(1);
}

[data-theme="dark"] .theme-toggle-thumb {
  transform: translateX(24px);
  background: #252320;
  border: 1px solid var(--gold);
  box-shadow: 0 0 8px rgba(198, 150, 59, 0.4);
}

/* Fallback for empty theme-toggle buttons */
.theme-toggle:empty::after {
  content: '';
  position: absolute;
  top: 2px;
  left: 2px;
  width: 22px;
  height: 22px;
  background: #FFFFFF;
  border-radius: 50%;
  box-shadow: 0 1px 4px rgba(0, 0, 0, 0.18);
  transition: transform 320ms cubic-bezier(0.34, 1.56, 0.64, 1), background var(--duration-base);
}

[data-theme="dark"] .theme-toggle:empty::after {
  transform: translateX(24px);
  background: #252320;
  border: 1px solid var(--gold);
  box-shadow: 0 0 8px rgba(198, 150, 59, 0.4);
}

/* Mobile Menu Button */
.mobile-menu-btn {
  display: none;
  align-items: center;
  justify-content: center;
  width: 44px;
  height: 44px;
  min-width: 44px;
  min-height: 44px;
  border-radius: var(--radius-md);
  color: var(--on-surface-secondary);
}

.mobile-menu-btn:hover {
  color: var(--on-surface);
}

.mobile-menu-btn svg {
  width: 22px;
  height: 22px;
}

/* === Transparent Navbar ONLY over Hero on Home Page when unscrolled === */
body.has-hero .top-nav:not(.scrolled) {
  background: transparent;
  backdrop-filter: none;
  -webkit-backdrop-filter: none;
  border-bottom: 1px solid transparent;
  box-shadow: none;
  padding: var(--space-2) var(--margin-desktop);
}

body.has-hero .top-nav:not(.scrolled) .nav-brand {
  color: #F5F0E6;
}

body.has-hero .top-nav:not(.scrolled) .nav-brand:hover {
  color: var(--gold);
}

body.has-hero .top-nav:not(.scrolled) .nav-link {
  color: rgba(245, 240, 230, 0.75);
}

body.has-hero .top-nav:not(.scrolled) .nav-link:hover,
body.has-hero .top-nav:not(.scrolled) .nav-link.active {
  color: #F5F0E6;
}

body.has-hero .top-nav:not(.scrolled) .nav-link::after {
  background: var(--gold);
}

body.has-hero .top-nav:not(.scrolled) .nav-icon-btn {
  color: rgba(245, 240, 230, 0.75);
}

body.has-hero .top-nav:not(.scrolled) .nav-icon-btn:hover {
  color: var(--ivory);
  background: rgba(255, 255, 255, 0.1);
}

body.has-hero .top-nav:not(.scrolled) .nav-latest-btn {
  border-color: rgba(245, 240, 230, 0.25);
  color: rgba(245, 240, 230, 0.85);
}

body.has-hero .top-nav:not(.scrolled) .nav-latest-btn:hover {
  border-color: var(--gold);
  color: var(--gold);
}

body.has-hero .top-nav:not(.scrolled) .mobile-menu-btn {
  color: rgba(245, 240, 230, 0.85);
}

/* --- Mobile Fullscreen Menu --- */
.mobile-nav-overlay {
  position: fixed;
  inset: 0;
  background: var(--surface-dark);
  z-index: var(--z-mobile-menu);
  display: flex;
  flex-direction: column;
  padding: var(--space-8) var(--space-4);
  opacity: 0;
  visibility: hidden;
  transition: opacity var(--duration-base) var(--ease-out),
              visibility var(--duration-base) var(--ease-out);
}

.mobile-nav-overlay.active {
  opacity: 1;
  visibility: visible;
}

.mobile-nav-close {
  position: absolute;
  top: var(--space-2);
  right: var(--space-3);
  width: 44px;
  height: 44px;
  display: flex;
  align-items: center;
  justify-content: center;
  color: var(--on-surface-dark);
  border-radius: var(--radius-md);
}

.mobile-nav-close svg {
  width: 24px;
  height: 24px;
}

.mobile-nav-links {
  display: flex;
  flex-direction: column;
  gap: var(--space-1);
  margin-top: var(--space-6);
}

.mobile-nav-link {
  font-family: var(--font-display);
  font-size: 28px;
  font-weight: 500;
  color: var(--on-surface-dark);
  text-decoration: none;
  padding: var(--space-2) 0;
  border-bottom: 1px solid rgba(245, 240, 230, 0.08);
  transition: color var(--duration-fast) var(--ease-out);
}

.mobile-nav-link:hover {
  color: var(--gold);
}

.mobile-nav-secondary {
  margin-top: auto;
  display: flex;
  flex-direction: column;
  gap: var(--space-1);
}

.mobile-nav-secondary a {
  font-size: var(--body-sm-size);
  color: rgba(245, 240, 230, 0.5);
  text-decoration: none;
}

/* ===================== HERO ===================== */
.hero-section {
  position: relative;
  min-height: 85vh;
  display: flex;
  align-items: flex-end;
  overflow: hidden;
  background: var(--charcoal);
}

.hero-bg {
  position: absolute;
  inset: 0;
  background-image: var(--hero-image);
  background-size: cover;
  background-position: center 40%;
  background-repeat: no-repeat;
  transition: opacity 0.6s ease;
}

.hero-bg::after {
  content: '';
  position: absolute;
  inset: 0;
  background: var(--hero-overlay);
  transition: background 0.6s ease;
}

/* Subtle grain texture */
.hero-bg::before {
  content: '';
  position: absolute;
  inset: 0;
  z-index: 1;
  opacity: 0.06;
  background-image: url("data:image/svg+xml,%3Csvg viewBox='0 0 200 200' xmlns='http://www.w3.org/2000/svg'%3E%3Cfilter id='g'%3E%3CfeTurbulence type='fractalNoise' baseFrequency='0.65' numOctaves='3' stitchTiles='stitch'/%3E%3C/filter%3E%3Crect width='100%25' height='100%25' filter='url(%23g)'/%3E%3C/svg%3E");
}

.hero-content {
  position: relative;
  z-index: 2;
  max-width: var(--container-max);
  margin: 0 auto;
  padding: 0 var(--margin-desktop) var(--space-12);
  width: 100%;
}

.hero-eyebrow {
  font-family: var(--font-body);
  font-size: var(--label-size);
  font-weight: var(--label-weight);
  letter-spacing: 0.2em;
  text-transform: uppercase;
  color: var(--gold);
  margin-bottom: var(--space-3);
  display: flex;
  align-items: center;
  gap: var(--space-2);
}

.hero-eyebrow::before {
  content: '';
  width: 32px;
  height: 1px;
  background: var(--gold);
}

.hero-label {
  font-family: var(--font-display);
  font-size: var(--body-md-size);
  font-weight: 400;
  font-style: italic;
  color: rgba(245, 240, 230, 0.6);
  margin-bottom: var(--space-2);
  display: block;
}

.hero-title {
  font-family: var(--font-display);
  font-size: var(--display-xl-size);
  line-height: var(--display-xl-line);
  letter-spacing: var(--display-xl-spacing);
  font-weight: var(--display-xl-weight);
  color: var(--ivory);
  max-width: 800px;
  margin-bottom: var(--space-3);
}

.hero-description {
  font-size: var(--body-lg-size);
  line-height: var(--body-lg-line);
  color: rgba(245, 240, 230, 0.7);
  max-width: 560px;
  margin-bottom: var(--space-5);
}

.hero-actions {
  display: flex;
  align-items: center;
  gap: var(--space-3);
  flex-wrap: wrap;
}

.hero-cta {
  display: inline-flex;
  align-items: center;
  gap: var(--space-1);
  padding: 12px 28px;
  font-family: var(--font-body);
  font-size: var(--label-size);
  font-weight: var(--label-weight);
  letter-spacing: var(--label-spacing);
  text-transform: uppercase;
  background: var(--gold);
  color: var(--charcoal);
  border-radius: var(--radius-sm);
  text-decoration: none;
  transition: all var(--duration-fast) var(--ease-out);
}

.hero-cta:hover {
  background: var(--gold-light);
  color: var(--charcoal);
  transform: translateY(-1px);
}

.hero-link {
  font-family: var(--font-body);
  font-size: var(--body-sm-size);
  font-weight: 500;
  color: rgba(245, 240, 230, 0.7);
  text-decoration: none;
  display: inline-flex;
  align-items: center;
  gap: 6px;
  transition: color var(--duration-fast) var(--ease-out);
}

.hero-link:hover {
  color: var(--ivory);
}

.hero-link .arrow {
  transition: transform var(--duration-fast) var(--ease-out);
}

.hero-link:hover .arrow {
  transform: translateX(4px);
}

/* ===================== INTELLIGENCE STREAM ===================== */
.intel-stream {
  background: var(--surface-tint);
  color: var(--on-surface);
  padding: 12px 0;
  border-top: 1px solid var(--border);
  border-bottom: 1px solid var(--border-gold);
  overflow: hidden;
  position: relative;
  transition: background var(--duration-base), border-color var(--duration-base);
}

.intel-stream-label {
  position: absolute;
  left: 0;
  top: 0;
  bottom: 0;
  display: flex;
  align-items: center;
  padding: 0 var(--space-3);
  font-family: var(--font-body);
  font-size: 9px;
  font-weight: 700;
  letter-spacing: 0.15em;
  text-transform: uppercase;
  color: var(--gold);
  background: var(--surface-tint);
  z-index: 2;
  border-right: 1px solid var(--border-gold);
  transition: background var(--duration-base);
}

.intel-stream-track {
  display: flex;
  animation: ticker-scroll 80s linear infinite;
  padding-left: 140px;
}

.intel-stream-track:hover {
  animation-play-state: paused;
}

.intel-item {
  display: inline-flex;
  align-items: center;
  gap: var(--space-2);
  padding: 0 var(--space-4);
  white-space: nowrap;
  font-size: var(--body-sm-size);
  color: var(--on-surface-secondary);
  text-decoration: none;
  transition: color var(--duration-fast);
  border-right: 1px solid var(--border);
}

.intel-item:hover {
  color: var(--link-hover);
}

.intel-item-region {
  font-size: 10px;
  font-weight: 700;
  letter-spacing: 0.1em;
  text-transform: uppercase;
  padding: 2px 8px;
  border-radius: var(--radius-sm);
  flex-shrink: 0;
}

.intel-item-region.nepal { background: rgba(84, 28, 38, 0.12); color: var(--burgundy); }
.intel-item-region.india { background: rgba(184, 134, 11, 0.15); color: #B8860B; }
.intel-item-region.china { background: rgba(38, 59, 85, 0.15); color: var(--slate); }
.intel-item-region.tibet { background: rgba(139, 58, 58, 0.15); color: #8B3A3A; }
.intel-item-region.global { background: rgba(111, 120, 103, 0.15); color: var(--sage); }
.intel-item-region.analysis { background: rgba(198, 150, 59, 0.15); color: var(--gold); }

[data-theme="dark"] .intel-item-region.nepal { background: rgba(84, 28, 38, 0.6); color: #f0c4cc; }
[data-theme="dark"] .intel-item-region.india { background: rgba(184, 134, 11, 0.3); color: #e8c865; }
[data-theme="dark"] .intel-item-region.china { background: rgba(38, 59, 85, 0.5); color: #8ab4e0; }
[data-theme="dark"] .intel-item-region.tibet { background: rgba(139, 58, 58, 0.4); color: #e0a0a0; }
[data-theme="dark"] .intel-item-region.global { background: rgba(111, 120, 103, 0.35); color: #b8c4ad; }
[data-theme="dark"] .intel-item-region.analysis { background: rgba(198, 150, 59, 0.25); color: #e8c865; }

.intel-item-arrow {
  color: var(--gold);
  font-size: 12px;
  margin-left: 4px;
}

.intel-item-date {
  font-size: 10px;
  color: var(--on-surface-tertiary);
  margin-left: var(--space-1);
}

/* ===================== SECTION HEADERS ===================== */
.section-heading {
  margin-bottom: var(--space-6);
}

.section-heading .eyebrow {
  font-family: var(--font-body);
  font-size: var(--label-size);
  font-weight: var(--label-weight);
  letter-spacing: var(--label-spacing);
  text-transform: uppercase;
  color: var(--gold);
  margin-bottom: var(--space-2);
  display: flex;
  align-items: center;
  gap: var(--space-2);
}

.section-heading .eyebrow::before {
  content: '';
  width: 24px;
  height: 1px;
  background: var(--gold);
}

.section-heading h2 {
  font-family: var(--font-display);
  font-size: var(--headline-lg-size);
  line-height: var(--headline-lg-line);
  letter-spacing: var(--headline-lg-spacing);
  color: var(--on-surface);
  margin-bottom: var(--space-1);
}

.section-heading p {
  font-size: var(--body-sm-size);
  color: var(--on-surface-secondary);
  max-width: 560px;
}

/* Legacy section header compat */
.section-header {
  display: flex;
  align-items: flex-end;
  justify-content: space-between;
  margin-bottom: var(--space-4);
  gap: var(--space-2);
}

.section-header h2 {
  font-size: var(--headline-lg-size);
  line-height: var(--headline-lg-line);
}

.section-header p {
  margin-top: 4px;
}

/* ===================== BUTTONS ===================== */
.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: var(--space-1);
  padding: 10px 22px;
  font-family: var(--font-body);
  font-size: var(--label-size);
  font-weight: var(--label-weight);
  letter-spacing: var(--label-spacing);
  text-transform: uppercase;
  border-radius: var(--radius-sm);
  cursor: pointer;
  transition: all var(--duration-fast) var(--ease-out);
  white-space: nowrap;
  text-decoration: none;
  line-height: 1;
  border: 1px solid transparent;
}

.btn-primary {
  background: var(--burgundy);
  color: var(--ivory);
  border-color: var(--burgundy);
}

.btn-primary:hover {
  background: var(--burgundy-light);
  color: var(--ivory);
  transform: translateY(-1px);
}

.btn-secondary {
  background: transparent;
  color: var(--on-surface);
  border-color: var(--border-strong);
}

.btn-secondary:hover {
  border-color: var(--on-surface);
  background: rgba(0, 0, 0, 0.03);
}

.btn-gold {
  background: var(--gold);
  color: var(--charcoal);
  border-color: var(--gold);
}

.btn-gold:hover {
  background: var(--gold-light);
  transform: translateY(-1px);
}

.btn-ghost {
  background: transparent;
  color: var(--on-surface-secondary);
  border-color: transparent;
}

.btn-ghost:hover {
  background: rgba(0, 0, 0, 0.04);
  color: var(--on-surface);
}

/* Keep compat for admin */
.btn-saffron { background: var(--gold); color: var(--charcoal); border-color: var(--gold); }
.btn-saffron:hover { background: var(--gold-light); }
.btn-danger { background: #ba1a1a; color: #fff; border-color: #ba1a1a; }
.btn-danger:hover { background: #d32f2f; }

.btn-sm {
  padding: 6px 14px;
  font-size: 10px;
}

/* --- Text Link with Arrow --- */
.text-link {
  font-family: var(--font-body);
  font-size: var(--body-sm-size);
  font-weight: 500;
  color: var(--burgundy);
  text-decoration: none;
  display: inline-flex;
  align-items: center;
  gap: 6px;
  transition: all var(--duration-fast) var(--ease-out);
}

.text-link:hover {
  color: var(--gold);
  gap: 10px;
}

.text-link .arrow {
  transition: transform var(--duration-fast) var(--ease-out);
  font-size: 14px;
}

.text-link:hover .arrow {
  transform: translateX(3px);
}

/* ===================== ARTICLE CARDS ===================== */
.card {
  background: var(--surface-alt);
  border: 1px solid var(--border);
  border-radius: var(--radius-lg);
  padding: var(--space-3);
  transition: all var(--duration-base) var(--ease-out);
  position: relative;
  overflow: hidden;
}

.card:hover {
  border-color: var(--border-strong);
  box-shadow: var(--shadow-sm);
}

.card-image-wrap {
  overflow: hidden;
  border-radius: var(--radius-md);
  margin-bottom: var(--space-2);
}

.card-image {
  width: 100%;
  height: 200px;
  object-fit: cover;
  background: var(--neutral-light);
  transition: transform var(--duration-slow) var(--ease-out);
}

.card:hover .card-image {
  transform: scale(1.03);
}

.card-meta {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: var(--space-1);
  margin-bottom: var(--space-2);
}

.card-title {
  font-family: var(--font-display);
  font-size: var(--headline-sm-size);
  line-height: var(--headline-sm-line);
  font-weight: 600;
  color: var(--on-surface);
  margin-bottom: var(--space-1);
}

.card-title a {
  color: inherit;
  text-decoration: none;
  transition: color var(--duration-fast) var(--ease-out);
}

.card-title a:hover {
  color: var(--burgundy);
}

.card-excerpt {
  font-size: var(--body-sm-size);
  line-height: 1.5;
  color: var(--on-surface-secondary);
  display: -webkit-box;
  -webkit-line-clamp: 3;
  -webkit-box-orient: vertical;
  overflow: hidden;
}

.card-date {
  font-size: 11px;
  font-weight: 500;
  letter-spacing: 0.04em;
  text-transform: uppercase;
  color: var(--on-surface-tertiary);
  white-space: nowrap;
}

.card-footer {
  display: flex;
  align-items: center;
  justify-content: space-between;
  margin-top: var(--space-2);
  padding-top: var(--space-2);
  border-top: 1px solid var(--border);
}

/* Featured card (large — for magazine layout) */
.card-featured {
  padding: 0;
  background: transparent;
  border: none;
  border-radius: 0;
}

.card-featured .card-image-wrap {
  border-radius: var(--radius-lg);
  margin-bottom: var(--space-3);
}

.card-featured .card-image {
  height: 400px;
}

.card-featured .card-title {
  font-size: var(--headline-md-size);
  line-height: var(--headline-md-line);
}

.card-featured .card-excerpt {
  font-size: var(--body-md-size);
  -webkit-line-clamp: 4;
}

/* Compact card */
.card-compact {
  display: flex;
  gap: var(--space-3);
  padding: var(--space-2);
  background: transparent;
  border: none;
  border-bottom: 1px solid var(--border);
  border-radius: 0;
}

.card-compact:last-child {
  border-bottom: none;
}

.card-compact .card-image-wrap {
  margin-bottom: 0;
  flex-shrink: 0;
}

.card-compact .card-image {
  width: 120px;
  min-width: 120px;
  height: 80px;
  border-radius: var(--radius-md);
}

.card-compact .card-title {
  font-size: var(--body-md-size);
  line-height: 1.4;
  font-weight: 600;
}

.card-compact .card-body {
  flex: 1;
  min-width: 0;
}

.card-compact:hover {
  background: var(--surface-dim);
}

/* Analysis card — larger with summary */
.analysis-card {
  border: 1px solid var(--border);
  border-radius: var(--radius-lg);
  overflow: hidden;
  transition: all var(--duration-base) var(--ease-out);
}

.analysis-card:hover {
  border-color: var(--border-strong);
  box-shadow: var(--shadow-md);
}

.analysis-card .card-image-wrap {
  border-radius: 0;
  margin-bottom: 0;
}

.analysis-card .card-image {
  height: 220px;
}

.analysis-card-body {
  padding: var(--space-3);
}

.analysis-card .card-title {
  font-size: var(--headline-sm-size);
  margin-bottom: var(--space-1);
}

.analysis-card .card-excerpt {
  font-size: var(--body-sm-size);
  -webkit-line-clamp: 3;
  margin-bottom: var(--space-2);
}

.analysis-card .card-author {
  font-size: 12px;
  color: var(--on-surface-tertiary);
  display: flex;
  align-items: center;
  gap: var(--space-1);
}

/* Hover arrow on analysis cards */
.analysis-card .hover-arrow {
  opacity: 0;
  transform: translateX(-4px);
  transition: all var(--duration-fast) var(--ease-out);
  color: var(--gold);
}

.analysis-card:hover .hover-arrow {
  opacity: 1;
  transform: translateX(0);
}

/* ===================== CHIPS & TAGS ===================== */
.chip {
  display: inline-flex;
  align-items: center;
  gap: 4px;
  padding: 3px 10px;
  font-family: var(--font-body);
  font-size: 10px;
  font-weight: 600;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  border-radius: var(--radius-sm);
  white-space: nowrap;
  transition: all var(--duration-fast);
}

.chip-nepal, .chip-nepali { background: rgba(84, 28, 38, 0.10); color: var(--burgundy); }
.chip-nepalese { background: rgba(84, 28, 38, 0.10); color: var(--burgundy); }
.chip-india { background: rgba(184, 134, 11, 0.10); color: #8B6914; }
.chip-indian { background: rgba(184, 134, 11, 0.10); color: #8B6914; }
.chip-china { background: rgba(38, 59, 85, 0.10); color: var(--slate); }
.chip-chinese { background: rgba(38, 59, 85, 0.10); color: var(--slate); }
.chip-tibet { background: rgba(139, 58, 58, 0.10); color: #8B3A3A; }
.chip-tibetan { background: rgba(139, 58, 58, 0.10); color: #8B3A3A; }
.chip-global { background: rgba(111, 120, 103, 0.10); color: var(--sage); }
.chip-asia { background: rgba(111, 120, 103, 0.10); color: var(--sage); }
.chip-analysis { background: rgba(198, 150, 59, 0.12); color: #9A7B30; }

[data-theme="dark"] .chip-nepal,
[data-theme="dark"] .chip-nepali,
[data-theme="dark"] .chip-nepalese { background: rgba(84, 28, 38, 0.25); color: #f0c4cc; }
[data-theme="dark"] .chip-india,
[data-theme="dark"] .chip-indian { background: rgba(184, 134, 11, 0.2); color: #e8c865; }
[data-theme="dark"] .chip-china,
[data-theme="dark"] .chip-chinese { background: rgba(38, 59, 85, 0.3); color: #8ab4e0; }
[data-theme="dark"] .chip-tibet,
[data-theme="dark"] .chip-tibetan { background: rgba(139, 58, 58, 0.25); color: #e0a0a0; }
[data-theme="dark"] .chip-global { background: rgba(111, 120, 103, 0.2); color: #b8c4ad; }
[data-theme="dark"] .chip-analysis { background: rgba(198, 150, 59, 0.2); color: #e8c865; }

/* Status chips (admin compat) */
.chip-status { padding: 2px 8px; font-size: 9px; }
.chip-published { background: rgba(42, 100, 60, 0.12); color: #2a643c; }
[data-theme="dark"] .chip-published { color: #78c68c; }
.chip-draft { background: rgba(198, 150, 59, 0.12); color: #9A7B30; }
.chip-critical { background: var(--gold); color: var(--charcoal); font-weight: 600; }

/* ===================== REGION TILES ===================== */
.region-tile {
  display: flex;
  flex-direction: column;
  gap: var(--space-1);
  padding: var(--space-3);
  border: 1px solid var(--border);
  border-radius: var(--radius-md);
  text-decoration: none;
  color: var(--on-surface);
  transition: all var(--duration-base) var(--ease-out);
  position: relative;
  overflow: hidden;
}

.region-tile::before {
  content: '';
  position: absolute;
  top: 0;
  left: 0;
  width: 3px;
  height: 100%;
  transition: width var(--duration-base) var(--ease-out);
}

.region-tile:hover {
  border-color: var(--border-strong);
  box-shadow: var(--shadow-sm);
  color: var(--on-surface);
}

.region-tile:hover::before {
  width: 4px;
}

.region-tile.nepal::before { background: var(--region-nepal); }
.region-tile.india::before { background: var(--region-india); }
.region-tile.china::before { background: var(--region-china); }
.region-tile.tibet::before { background: var(--region-tibet); }
.region-tile.asia::before { background: var(--region-asia); }
.region-tile.global::before { background: var(--region-global); }
.region-tile.analysis::before { background: var(--region-analysis); }

.region-tile-name {
  font-family: var(--font-display);
  font-size: var(--body-md-size);
  font-weight: 600;
}

.region-tile-count {
  font-size: 12px;
  color: var(--on-surface-tertiary);
}

/* ===================== OBSERVATORY / STATS ===================== */
.observatory-grid {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: var(--space-4);
}

.observatory-stat {
  text-align: center;
  padding: var(--space-4) var(--space-2);
}

.observatory-stat-number {
  font-family: var(--font-display);
  font-size: clamp(36px, 4vw, 56px);
  font-weight: 600;
  color: var(--gold);
  line-height: 1;
  margin-bottom: var(--space-1);
}

.observatory-stat-label {
  font-size: 12px;
  font-weight: 600;
  letter-spacing: 0.1em;
  text-transform: uppercase;
  color: var(--on-surface-secondary);
}

/* ===================== WHAT IS BD SECTION ===================== */
.explainer-pillars {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: var(--space-4);
  margin-top: var(--space-5);
}

.explainer-pillar {
  text-align: center;
  padding: var(--space-4) var(--space-3);
  border: 1px solid var(--border);
  border-radius: var(--radius-md);
}

.explainer-pillar-icon {
  font-size: 28px;
  margin-bottom: var(--space-2);
  display: block;
}

.explainer-pillar h4 {
  font-family: var(--font-display);
  font-size: var(--body-md-size);
  font-weight: 600;
  margin-bottom: var(--space-1);
}

.explainer-pillar p {
  font-size: var(--body-sm-size);
  color: var(--on-surface-secondary);
}

/* ===================== NEWSLETTER ===================== */
.newsletter-section {
  background: var(--burgundy);
  padding: var(--section-gap) 0;
}

.newsletter-content {
  max-width: 600px;
  margin: 0 auto;
  text-align: center;
}

.newsletter-content h2 {
  font-family: var(--font-display);
  font-size: var(--headline-lg-size);
  color: #F5F0E6;
  margin-bottom: var(--space-2);
}

.newsletter-content p {
  color: rgba(245, 240, 230, 0.7);
  margin-bottom: var(--space-4);
  font-size: var(--body-md-size);
}

.newsletter-form {
  display: flex;
  gap: var(--space-2);
  max-width: 460px;
  margin: 0 auto var(--space-2);
}

.newsletter-input {
  flex: 1;
  padding: 12px 18px;
  background: rgba(245, 240, 230, 0.1);
  border: 1px solid rgba(245, 240, 230, 0.2);
  border-radius: var(--radius-sm);
  color: #F5F0E6;
  font-size: var(--body-sm-size);
}

.newsletter-input::placeholder {
  color: rgba(245, 240, 230, 0.4);
}

.newsletter-input:focus {
  border-color: var(--gold);
  outline: none;
}

.newsletter-submit {
  padding: 12px 24px;
  background: var(--gold);
  color: #171717;
  border: none;
  border-radius: var(--radius-sm);
  font-family: var(--font-body);
  font-size: var(--label-size);
  font-weight: var(--label-weight);
  letter-spacing: var(--label-spacing);
  text-transform: uppercase;
  cursor: pointer;
  transition: background var(--duration-fast) var(--ease-out);
}

.newsletter-submit:hover {
  background: var(--gold-light);
}

.newsletter-disclaimer {
  font-size: 12px;
  color: rgba(245, 240, 230, 0.4);
}

/* ===================== FOOTER ===================== */
.site-footer {
  background: #171717;
  color: #F5F0E6;
  padding: var(--space-10) 0 var(--space-4);
}

.footer-grid {
  display: grid;
  grid-template-columns: 1.5fr repeat(4, 1fr);
  gap: var(--space-6);
  max-width: var(--container-max);
  margin: 0 auto;
  padding: 0 var(--margin-desktop);
}

.footer-brand h3 {
  font-family: var(--font-display);
  font-size: 18px;
  font-weight: 700;
  color: #F5F0E6;
  margin-bottom: var(--space-2);
}

.footer-brand p {
  font-size: var(--body-sm-size);
  line-height: 1.6;
  color: rgba(245, 240, 230, 0.5);
  max-width: 300px;
}

.footer-col h4 {
  font-family: var(--font-body);
  font-size: 10px;
  font-weight: 700;
  letter-spacing: 0.15em;
  text-transform: uppercase;
  color: var(--gold);
  margin-bottom: var(--space-3);
}

.footer-col a {
  display: block;
  font-size: var(--body-sm-size);
  color: rgba(245, 240, 230, 0.55);
  text-decoration: none;
  padding: 4px 0;
  transition: color var(--duration-fast);
}

.footer-col a:hover {
  color: #F5F0E6;
}

.footer-bottom {
  max-width: var(--container-max);
  margin: 0 auto;
  padding: var(--space-4) var(--margin-desktop) 0;
  margin-top: var(--space-6);
  border-top: 1px solid rgba(245, 240, 230, 0.08);
  display: flex;
  align-items: center;
  justify-content: space-between;
}

.footer-copy {
  font-size: 12px;
  color: rgba(245, 240, 230, 0.35);
}

.footer-links {
  display: flex;
  gap: var(--space-3);
}

.footer-links a {
  font-size: 12px;
  color: rgba(245, 240, 230, 0.35);
  text-decoration: none;
  transition: color var(--duration-fast);
}

.footer-links a:hover {
  color: rgba(245, 240, 230, 0.7);
}

/* ===================== SEARCH MODAL ===================== */
.search-overlay {
  position: fixed;
  inset: 0;
  background: rgba(23, 23, 23, 0.6);
  backdrop-filter: blur(8px);
  z-index: var(--z-search);
  display: flex;
  align-items: flex-start;
  justify-content: center;
  padding-top: 12vh;
  opacity: 0;
  visibility: hidden;
  transition: all var(--duration-base) var(--ease-out);
}

.search-overlay.active {
  opacity: 1;
  visibility: visible;
}

.search-modal {
  background: var(--surface);
  border-radius: var(--radius-lg);
  width: 90%;
  max-width: 640px;
  box-shadow: var(--shadow-lg);
  transform: translateY(-16px);
  transition: transform var(--duration-base) var(--ease-out);
  overflow: hidden;
}

.search-overlay.active .search-modal {
  transform: translateY(0);
}

.search-modal-header {
  padding: var(--space-3) var(--space-4);
  border-bottom: 1px solid var(--border);
  display: flex;
  align-items: center;
  gap: var(--space-2);
}

.search-modal-header svg {
  width: 20px;
  height: 20px;
  color: var(--on-surface-tertiary);
  flex-shrink: 0;
}

.search-modal-header input {
  flex: 1;
  font-size: var(--body-lg-size);
  font-family: var(--font-body);
  color: var(--on-surface);
  background: transparent;
}

.search-modal-header input::placeholder {
  color: var(--on-surface-tertiary);
}

.search-modal-results {
  max-height: 400px;
  overflow-y: auto;
}

.search-result {
  display: flex;
  gap: var(--space-2);
  padding: var(--space-2) var(--space-4);
  text-decoration: none;
  border-bottom: 1px solid var(--border);
  transition: background var(--duration-fast);
}

.search-result:hover {
  background: var(--surface-dim);
}

.search-result-title {
  font-size: var(--body-md-size);
  font-weight: 500;
  color: var(--on-surface);
  margin-bottom: 2px;
}

.search-result-meta {
  font-size: 11px;
  color: var(--on-surface-tertiary);
  text-transform: uppercase;
  letter-spacing: 0.04em;
}

/* Keep legacy search bar compat for admin */
.search-bar {
  display: flex;
  align-items: center;
  gap: var(--space-1);
  padding: 6px 14px;
  background: rgba(0, 0, 0, 0.04);
  border: 1px solid var(--border);
  border-radius: var(--radius-md);
  min-width: 200px;
  transition: all var(--duration-fast);
}

.search-bar:focus-within {
  border-color: var(--gold);
}

.search-bar svg { width: 16px; height: 16px; color: var(--on-surface-tertiary); flex-shrink: 0; }
.search-bar input { width: 100%; font-size: var(--caption-size); color: var(--on-surface); background: transparent; }
.search-bar input::placeholder { color: var(--on-surface-tertiary); }

/* ===================== READING PROGRESS ===================== */
.reading-progress {
  position: fixed;
  top: 0;
  left: 0;
  width: 0;
  height: 2px;
  background: var(--gold);
  z-index: calc(var(--z-header) + 1);
  transition: width 100ms linear;
}

/* ===================== BREADCRUMB ===================== */
.breadcrumb {
  display: flex;
  align-items: center;
  gap: var(--space-1);
  margin-bottom: var(--space-3);
}

.breadcrumb a,
.breadcrumb span {
  font-size: 11px;
  font-weight: 500;
  letter-spacing: 0.06em;
  text-transform: uppercase;
  color: var(--on-surface-tertiary);
  text-decoration: none;
}

.breadcrumb a:hover {
  color: var(--burgundy);
}

.breadcrumb .separator {
  color: var(--neutral);
}

.breadcrumb .current {
  color: var(--on-surface);
}

/* ===================== MAP & INTELLIGENCE CARTOGRAPHY ===================== */
.diplomacy-map-section {
  background: var(--surface-panel);
  padding: var(--section-gap) 0;
  border-top: 1px solid var(--border);
  border-bottom: 1px solid var(--border);
  transition: background var(--duration-base);
}

.diplomacy-map-section .section-heading .eyebrow {
  color: var(--gold);
}

.diplomacy-map-section .section-heading .eyebrow::before {
  background: var(--gold);
}

.diplomacy-map-section .section-heading h2 {
  color: var(--on-surface);
}

.diplomacy-map-section .section-heading p {
  color: var(--on-surface-secondary);
}

/* Map Region Filter Pills */
.map-filters {
  display: flex;
  flex-wrap: wrap;
  gap: var(--space-2);
  margin-bottom: var(--space-5);
  align-items: center;
}

.map-filter-btn {
  padding: 8px 16px;
  font-family: var(--font-body);
  font-size: 11px;
  font-weight: 600;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  background: var(--surface-card);
  color: var(--on-surface-secondary);
  border: 1px solid var(--border-strong);
  border-radius: var(--radius-pill);
  cursor: pointer;
  transition: all var(--duration-fast);
}

.map-filter-btn:hover {
  border-color: var(--gold);
  color: var(--on-surface);
}

.map-filter-btn.active {
  background: var(--burgundy);
  color: #FAF8F3;
  border-color: var(--burgundy);
  box-shadow: 0 2px 8px rgba(84, 28, 38, 0.22);
}

[data-theme="dark"] .map-filter-btn.active {
  background: var(--gold);
  color: #121110;
  border-color: var(--gold);
  box-shadow: 0 2px 8px rgba(198, 150, 59, 0.35);
}

/* Map Workspace: Left Map + Right Intelligence Dossier */
.map-workspace {
  display: grid;
  grid-template-columns: 1.8fr 1fr;
  gap: var(--space-5);
  align-items: stretch;
}

@media (max-width: 1024px) {
  .map-workspace {
    grid-template-columns: 1fr;
  }
}

.map-canvas-wrap {
  position: relative;
  background: var(--surface-card);
  border: 1px solid var(--border-strong);
  border-radius: var(--radius-lg);
  overflow: hidden;
  box-shadow: var(--shadow-md);
  display: flex;
  align-items: center;
  justify-content: center;
  min-height: 480px;
}

.map-svg {
  width: 100%;
  height: 100%;
  min-height: 480px;
  display: block;
}

/* Map Cartographic Elements */
.map-ocean {
  fill: var(--surface-dim);
  transition: fill var(--duration-base);
}

.map-landmass {
  fill: #E7E0D3;
  stroke: rgba(84, 28, 38, 0.16);
  stroke-width: 0.75;
  transition: fill var(--duration-base), stroke var(--duration-base);
}

[data-theme="dark"] .map-landmass {
  fill: #1C1B19;
  stroke: rgba(198, 150, 59, 0.22);
}

.map-himalayan-arc {
  fill: none;
  stroke: rgba(198, 150, 59, 0.35);
  stroke-width: 1.5;
  stroke-dasharray: 4, 3;
}

.map-route-line {
  stroke: var(--gold);
  stroke-width: 1.2;
  stroke-dasharray: 4, 4;
  opacity: 0.45;
  transition: opacity var(--duration-fast);
}

.map-route-line.highlighted {
  opacity: 0.9;
  stroke-width: 1.8;
}

.map-graticule {
  stroke: var(--border);
  stroke-width: 0.5;
  stroke-dasharray: 2, 6;
}

.map-coord-label {
  font-family: var(--font-body);
  font-size: 8px;
  fill: var(--on-surface-tertiary);
  opacity: 0.45;
  letter-spacing: 0.05em;
}

/* Markers */
.map-hub-glow {
  fill: var(--gold);
  opacity: 0.15;
  transition: all 0.3s ease;
  animation: hubPulse 3.5s ease-in-out infinite;
}

.map-hub-marker {
  fill: var(--gold);
  stroke: var(--burgundy);
  stroke-width: 1.5;
  cursor: pointer;
  transition: transform 0.2s ease, r 0.2s ease, fill 0.2s ease;
}

[data-theme="dark"] .map-hub-marker {
  stroke: #121110;
}

.map-hub-marker:hover,
.map-hub-marker.active {
  r: 7;
  fill: var(--burgundy);
  stroke: var(--gold);
  stroke-width: 2;
}

[data-theme="dark"] .map-hub-marker:hover,
[data-theme="dark"] .map-hub-marker.active {
  fill: #FFFFFF;
  stroke: var(--gold);
}

.map-hub-label {
  font-family: var(--font-body);
  font-size: 9px;
  font-weight: 700;
  letter-spacing: 0.06em;
  text-transform: uppercase;
  fill: var(--on-surface-secondary);
  pointer-events: none;
  transition: fill var(--duration-fast);
}

.map-hub-marker:hover + .map-hub-label,
.map-hub-marker.active + .map-hub-label {
  fill: var(--burgundy);
}

[data-theme="dark"] .map-hub-marker:hover + .map-hub-label,
[data-theme="dark"] .map-hub-marker.active + .map-hub-label {
  fill: var(--gold);
}

@keyframes hubPulse {
  0%, 100% { opacity: 0.15; transform: scale(1); }
  50% { opacity: 0.35; transform: scale(1.3); }
}

/* Tooltip floating over map */
.map-tooltip {
  position: absolute;
  background: var(--surface-card);
  color: var(--on-surface);
  padding: 10px 14px;
  border-radius: var(--radius-md);
  border: 1px solid var(--border-gold);
  box-shadow: var(--shadow-lg);
  pointer-events: none;
  opacity: 0;
  visibility: hidden;
  transition: opacity var(--duration-fast), transform var(--duration-fast);
  z-index: 20;
  max-width: 240px;
}

.map-tooltip.visible {
  opacity: 1;
  visibility: visible;
}

.map-tooltip-title {
  font-family: var(--font-display);
  font-size: 13px;
  font-weight: 600;
  color: var(--on-surface);
  margin-bottom: 2px;
}

.map-tooltip-tradition {
  font-size: 10px;
  font-weight: 700;
  letter-spacing: 0.1em;
  text-transform: uppercase;
  color: var(--gold);
  margin-bottom: 4px;
}

.map-tooltip-desc {
  font-size: 11px;
  line-height: 1.4;
  color: var(--on-surface-secondary);
}

/* Intelligence Dossier Panel */
.map-dossier {
  background: var(--surface-card);
  border: 1px solid var(--border-strong);
  border-radius: var(--radius-lg);
  padding: var(--space-6);
  display: flex;
  flex-direction: column;
  box-shadow: var(--shadow-md);
  position: relative;
  min-height: 480px;
  transition: all var(--duration-base);
}

.map-dossier::before {
  content: '';
  position: absolute;
  top: 0;
  left: 0;
  right: 0;
  height: 3px;
  background: linear-gradient(90deg, var(--burgundy), var(--gold));
  border-top-left-radius: var(--radius-lg);
  border-top-right-radius: var(--radius-lg);
}

[data-theme="dark"] .map-dossier::before {
  background: linear-gradient(90deg, var(--gold), #E8C865);
}

.dossier-badge {
  font-size: 10px;
  font-weight: 700;
  letter-spacing: 0.15em;
  text-transform: uppercase;
  color: var(--gold);
  margin-bottom: var(--space-2);
  display: inline-flex;
  align-items: center;
  gap: 6px;
}

.dossier-title {
  font-family: var(--font-display);
  font-size: clamp(22px, 2vw, 26px);
  font-weight: 600;
  color: var(--on-surface);
  line-height: 1.2;
  margin-bottom: var(--space-1);
}

.dossier-country {
  font-size: 13px;
  color: var(--on-surface-tertiary);
  margin-bottom: var(--space-3);
  display: flex;
  align-items: center;
  gap: 8px;
}

.dossier-tradition-tag {
  font-size: 10px;
  font-weight: 700;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  padding: 2px 8px;
  background: rgba(198, 150, 59, 0.12);
  color: var(--gold);
  border-radius: var(--radius-sm);
}

.dossier-role {
  font-size: var(--body-sm-size);
  line-height: 1.6;
  color: var(--on-surface-secondary);
  margin-bottom: var(--space-4);
}

.dossier-meta-list {
  display: flex;
  flex-direction: column;
  gap: var(--space-3);
  margin-bottom: var(--space-5);
  padding: var(--space-3) var(--space-4);
  background: var(--surface-panel);
  border-radius: var(--radius-md);
  border: 1px solid var(--border);
}

.dossier-meta-item {
  display: flex;
  flex-direction: column;
  gap: 2px;
}

.dossier-meta-label {
  font-weight: 700;
  color: var(--on-surface-tertiary);
  text-transform: uppercase;
  font-size: 9px;
  letter-spacing: 0.1em;
}

.dossier-meta-val {
  font-size: 12px;
  color: var(--on-surface);
  line-height: 1.4;
}

.dossier-action-btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: var(--space-2);
  padding: 12px 20px;
  background: var(--burgundy);
  color: #FAF8F3;
  border-radius: var(--radius-sm);
  text-decoration: none;
  font-weight: 600;
  font-size: 13px;
  transition: background var(--duration-fast), transform var(--duration-fast);
  margin-top: auto;
}

.dossier-action-btn:hover {
  background: var(--burgundy-light);
  transform: translateY(-1px);
}

[data-theme="dark"] .dossier-action-btn {
  background: var(--gold);
  color: #121110;
}

[data-theme="dark"] .dossier-action-btn:hover {
  background: var(--gold-light);
}

/* Mobile map fallback */
.map-mobile-regions {
  display: none;
  overflow-x: auto;
  gap: var(--space-2);
  padding: var(--space-2) 0;
  -webkit-overflow-scrolling: touch;
}

.map-mobile-region {
  flex: 0 0 200px;
  padding: var(--space-3);
  background: rgba(245, 240, 230, 0.06);
  border: 1px solid rgba(245, 240, 230, 0.08);
  border-radius: var(--radius-md);
  text-decoration: none;
  color: var(--ivory);
}

.map-mobile-region h4 {
  font-size: var(--body-md-size);
  color: var(--ivory);
  margin-bottom: 4px;
}

.map-mobile-region p {
  font-size: 12px;
  color: rgba(245, 240, 230, 0.5);
}

/* ===================== AUTHORS / VOICES ===================== */
.author-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(220px, 1fr));
  gap: var(--space-4);
}

.author-card {
  text-align: center;
  padding: var(--space-4) var(--space-2);
}

.author-avatar {
  width: 64px;
  height: 64px;
  border-radius: 50%;
  background: var(--burgundy);
  color: var(--ivory);
  display: flex;
  align-items: center;
  justify-content: center;
  font-family: var(--font-display);
  font-size: 20px;
  font-weight: 600;
  margin: 0 auto var(--space-2);
}

.author-name {
  font-family: var(--font-display);
  font-size: var(--body-md-size);
  font-weight: 600;
  color: var(--on-surface);
  margin-bottom: 2px;
}

.author-role {
  font-size: 12px;
  color: var(--on-surface-tertiary);
  text-transform: uppercase;
  letter-spacing: 0.06em;
}

/* ===================== FEATURED LONG READ ===================== */
.long-read {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: var(--space-6);
  align-items: center;
}

.long-read-reversed {
  direction: rtl;
}

.long-read-reversed > * {
  direction: ltr;
}

.long-read-image {
  width: 100%;
  height: 400px;
  object-fit: cover;
  border-radius: var(--radius-lg);
}

.long-read-content .chip {
  margin-bottom: var(--space-2);
}

.long-read-content h3 {
  font-family: var(--font-display);
  font-size: var(--headline-md-size);
  line-height: var(--headline-md-line);
  color: var(--on-surface);
  margin-bottom: var(--space-2);
}

.long-read-content p {
  font-size: var(--body-md-size);
  color: var(--on-surface-secondary);
  margin-bottom: var(--space-3);
}

.long-read-meta {
  font-size: 12px;
  color: var(--on-surface-tertiary);
  margin-bottom: var(--space-3);
}

/* ===================== INPUTS (admin compat) ===================== */
.input-group { display: flex; flex-direction: column; gap: 6px; }
.input-label { font-size: var(--label-size); font-weight: var(--label-weight); letter-spacing: var(--label-spacing); text-transform: uppercase; color: var(--on-surface-secondary); }
.input-field { padding: 10px 0; font-size: var(--body-md-size); color: var(--on-surface); border-bottom: 1px solid var(--border); background: transparent; transition: border-color var(--duration-fast); }
.input-field:focus { border-bottom-color: var(--gold); outline: none; }
.input-field-boxed { padding: 10px 14px; border: 1px solid var(--border); border-radius: var(--radius-md); background: var(--surface-alt); }
.input-field-boxed:focus { border-color: var(--gold); }
textarea.input-field, textarea.input-field-boxed { resize: vertical; min-height: 80px; font-family: var(--font-body); }

/* ===================== MODAL (admin compat) ===================== */
.modal-overlay { position: fixed; inset: 0; background: rgba(0,0,0,0.4); backdrop-filter: blur(4px); z-index: var(--z-modal); display: flex; align-items: center; justify-content: center; opacity: 0; visibility: hidden; transition: all var(--duration-base); }
.modal-overlay.active { opacity: 1; visibility: visible; }
.modal { background: var(--surface); border: 1px solid var(--border); border-radius: var(--radius-lg); padding: var(--space-4); max-width: 440px; width: 90%; box-shadow: var(--shadow-lg); transform: translateY(16px); transition: transform var(--duration-base); }
.modal-overlay.active .modal { transform: translateY(0); }
.modal-title { font-family: var(--font-display); font-size: var(--headline-md-size); margin-bottom: var(--space-2); }
.modal-body { margin-bottom: var(--space-3); color: var(--on-surface-secondary); }
.modal-actions { display: flex; gap: var(--space-2); justify-content: flex-end; }

/* ===================== TOAST ===================== */
.toast-container { position: fixed; bottom: var(--space-3); right: var(--space-3); z-index: var(--z-toast); display: flex; flex-direction: column; gap: var(--space-1); }
.toast { background: var(--charcoal); color: var(--ivory); padding: 12px 20px; border-radius: var(--radius-md); font-size: var(--caption-size); box-shadow: var(--shadow-md); animation: toastIn 300ms ease forwards; max-width: 360px; }
.toast.toast-out { animation: toastOut 250ms ease forwards; }
@keyframes toastIn { from { opacity: 0; transform: translateY(12px); } to { opacity: 1; transform: translateY(0); } }
@keyframes toastOut { from { opacity: 1; } to { opacity: 0; transform: translateY(-8px); } }

/* ===================== EMPTY STATE ===================== */
.empty-state { text-align: center; padding: var(--space-10) var(--space-4); color: var(--on-surface-tertiary); }
.empty-state-icon { font-size: 48px; margin-bottom: var(--space-2); opacity: 0.5; }
.empty-state h3 { color: var(--on-surface-secondary); margin-bottom: var(--space-1); }
.empty-state p { color: var(--on-surface-tertiary); max-width: 400px; margin: 0 auto; }

/* ===================== SCROLL BUTTONS (admin compat) ===================== */
.scroll-btn { width: 36px; height: 36px; border-radius: var(--radius-md); border: 1px solid var(--border); display: flex; align-items: center; justify-content: center; color: var(--on-surface-secondary); background: var(--surface-alt); transition: all var(--duration-fast); cursor: pointer; }
.scroll-btn:hover { border-color: var(--border-strong); color: var(--on-surface); }
.scroll-btn svg { width: 16px; height: 16px; }

/* Stream nav compat */
.stream-nav { display: flex; gap: var(--space-1); }

/* ===================== SIDEBAR (admin compat) ===================== */
.sidebar-header { display: flex; align-items: center; gap: var(--space-1); margin-bottom: var(--space-3); }
.sidebar-header-icon { width: 32px; height: 32px; border-radius: var(--radius-md); background: var(--gold-muted); display: flex; align-items: center; justify-content: center; font-size: 16px; }
.sidebar-header-text { flex: 1; }
.sidebar-header-text .label-caps { color: var(--on-surface); font-size: 11px; }
.sidebar-header-text .caption { color: var(--gold); font-size: 10px; text-transform: uppercase; letter-spacing: 0.08em; }
.sidebar-nav { display: flex; flex-direction: column; gap: 2px; }
.sidebar-link { display: flex; align-items: center; gap: var(--space-1); padding: 10px 12px; border-radius: var(--radius-md); color: var(--on-surface-secondary); text-decoration: none; font-size: 14px; transition: all var(--duration-fast); border: 1px solid transparent; }
.sidebar-link:hover { background: var(--surface-dim); color: var(--on-surface); }
.sidebar-link.active { background: var(--gold-muted); color: var(--on-surface); font-weight: 500; border-color: var(--border-gold); }
.sidebar-link svg, .sidebar-link .sidebar-icon { width: 18px; height: 18px; flex-shrink: 0; opacity: 0.7; }
.sidebar-link.active svg, .sidebar-link.active .sidebar-icon { opacity: 1; }
.sidebar-close { display: none; position: absolute; top: var(--space-2); right: var(--space-2); width: 32px; height: 32px; align-items: center; justify-content: center; border-radius: var(--radius-md); color: var(--on-surface-secondary); }

/* ===================== LIVE INDICATOR ===================== */
.live-dot { width: 6px; height: 6px; border-radius: 50%; background: #22c55e; display: inline-block; animation: livePulse 2s ease-in-out infinite; }
@keyframes livePulse { 0%, 100% { opacity: 1; } 50% { opacity: 0.4; } }

/* ===================== RESPONSIVE ===================== */
@media (max-width: 992px) {
  .long-read {
    grid-template-columns: 1fr;
  }

  .long-read-reversed {
    direction: ltr;
  }

  .long-read-image {
    height: 280px;
  }

  .observatory-grid {
    grid-template-columns: repeat(2, 1fr);
  }

  .explainer-pillars {
    grid-template-columns: 1fr;
    gap: var(--space-2);
  }
}

@media (max-width: 768px) {
  .top-nav,
  body.has-hero .top-nav:not(.scrolled) {
    padding: var(--space-2) var(--margin-mobile);
  }

  .top-nav.scrolled {
    padding: 10px var(--margin-mobile);
  }

  .nav-links {
    display: none;
  }

  .mobile-menu-btn {
    display: flex;
  }

  .nav-latest-btn {
    display: none;
  }

  .hero-section {
    min-height: 80vh;
  }

  .hero-content {
    padding: 0 var(--margin-mobile) var(--space-8);
  }

  .hero-title {
    font-size: clamp(32px, 8vw, 48px);
  }

  .hero-actions {
    flex-direction: column;
    align-items: flex-start;
  }

  .intel-stream-label {
    display: none;
  }

  .intel-stream-track {
    padding-left: var(--space-3);
  }

  .footer-grid {
    grid-template-columns: 1fr 1fr;
    gap: var(--space-4);
    padding: 0 var(--margin-mobile);
  }

  .footer-brand {
    grid-column: 1 / -1;
  }

  .footer-bottom {
    flex-direction: column;
    gap: var(--space-2);
    text-align: center;
    padding: var(--space-3) var(--margin-mobile) 0;
  }

  .newsletter-form {
    flex-direction: column;
  }

  .sidebar-close {
    display: flex;
  }

  .section-header {
    flex-direction: column;
    align-items: flex-start;
  }

  .site-footer {
    padding: var(--space-8) 0 var(--space-3);
  }

  .search-overlay {
    padding-top: var(--space-4);
  }

  .search-modal {
    width: 95%;
  }

  /* Map mobile: responsive canvas height, compact dossier, and hide legacy card scroller */
  .map-canvas-wrap {
    min-height: 260px;
  }

  .map-dossier {
    min-height: auto;
    padding: var(--space-4);
  }

  .map-mobile-regions {
    display: none !important;
  }

  .author-grid {
    grid-template-columns: repeat(2, 1fr);
    gap: var(--space-2);
  }

  .observatory-grid {
    grid-template-columns: repeat(2, 1fr);
    gap: var(--space-2);
  }
}

@media (max-width: 480px) {
  .author-grid {
    grid-template-columns: 1fr;
  }

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

/* ===================== DARK MODE OVERRIDES ===================== */
/* Cards */
[data-theme="dark"] .card {
  background: var(--surface-alt);
  border-color: var(--border);
}

[data-theme="dark"] .card:hover {
  border-color: var(--border-strong);
}

[data-theme="dark"] .card-title a:hover {
  color: var(--gold);
}

/* Analysis cards */
[data-theme="dark"] .analysis-card {
  background: var(--surface-alt);
}

/* Region tiles */
[data-theme="dark"] .region-tile {
  background: var(--surface-alt);
}

[data-theme="dark"] .region-tile:hover {
  background: var(--surface-dim);
}

/* Explainer */
[data-theme="dark"] .explainer-section {
  background: var(--surface-alt);
}

[data-theme="dark"] .explainer-pillar {
  background: var(--surface-dim);
  border-color: var(--border);
}

/* Observatory */
[data-theme="dark"] .observatory-stat {
  border-color: var(--border);
}

/* Section headings */
[data-theme="dark"] .section-heading h2 {
  color: var(--on-surface);
}

/* Selection */
[data-theme="dark"] ::selection {
  background-color: rgba(198, 150, 59, 0.35);
  color: #F5F0E6;
}

/* Scrollbar */
[data-theme="dark"] ::-webkit-scrollbar-track {
  background: var(--surface);
}

[data-theme="dark"] ::-webkit-scrollbar-thumb {
  background: var(--neutral);
}

/* Intelligence ticker */
[data-theme="dark"] .ticker {
  background: var(--surface-alt);
  border-color: var(--border);
}

/* Search modal */
[data-theme="dark"] .search-modal {
  background: var(--surface);
  border-color: var(--border);
}

[data-theme="dark"] .search-input {
  background: var(--surface-alt);
  color: var(--on-surface);
  border-color: var(--border);
}

/* Map tooltip in dark mode */
[data-theme="dark"] .map-tooltip {
  background: var(--surface-dim);
  color: var(--on-surface);
  border: 1px solid var(--border);
}

/* Long read feature card */
[data-theme="dark"] .longread-card {
  background: var(--surface-alt);
  border-color: var(--border);
}

/* Footer dark override — ensure footer stays dark in both themes */
[data-theme="dark"] .site-footer {
  background: #0A0A09;
  border-top: 1px solid rgba(232, 227, 217, 0.06);
}

/* Newsletter in dark mode — slightly darker burgundy */
[data-theme="dark"] .newsletter-section {
  background: #3D1019;
}

/* Breadcrumb */
[data-theme="dark"] .breadcrumb a {
  color: var(--on-surface-tertiary);
}

[data-theme="dark"] .breadcrumb a:hover {
  color: var(--gold);
}

/* Mobile nav overlay */
[data-theme="dark"] .mobile-menu-overlay {
  background: rgba(10, 10, 9, 0.97);
}

/* Empty state */
[data-theme="dark"] .empty-state {
  color: var(--on-surface-tertiary);
}
