/* ============================================
   The Belonging Economy — Pixwell Tasty Magazine
   ============================================ */

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

/* --- Custom Properties — Light (default) --- */
:root {
  --font-heading: 'Inter', -apple-system, BlinkMacSystemFont, sans-serif;
  --font-body: 'Source Sans 3', -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, sans-serif;

  --primary: #1a2b3c;
  --primary-hover: #0f1d2b;
  --secondary: #e63926;
  --secondary-hover: #c7301f;
  --secondary-light: rgba(230, 57, 38, 0.10);

  --bg: #ffffff;
  --bg-alt: #f9f9f9;
  --surface: #ffffff;
  --surface-hover: #f5f5f5;
  --text: #282828;
  --text-secondary: #555555;
  --text-muted: #888888;
  --accent: #e63926;
  --accent-hover: #c7301f;
  --accent-light: rgba(230, 57, 38, 0.10);
  --border: #eeeeee;
  --border-light: #f0f0f0;
  --shadow: rgba(0, 0, 0, 0.06);
  --shadow-md: rgba(0, 0, 0, 0.12);
  --shadow-lg: rgba(0, 0, 0, 0.16);
  --overlay: rgba(0, 0, 0, 0.5);
  --progress-bg: rgba(0, 0, 0, 0.08);
  --card-shadow: 0 5px 30px rgba(0, 0, 0, 0.08);
  --card-shadow-hover: 0 12px 40px rgba(0, 0, 0, 0.15);

  --reading-width: 720px;
  --wide-width: 1240px;
  --nav-height: 64px;
}

/* --- Dark Mode --- */
[data-theme="dark"] {
  --bg: #191c20;
  --bg-alt: #1e2228;
  --surface: #22262c;
  --surface-hover: #2a2e36;
  --text: #e8e6e1;
  --text-secondary: #b0ada6;
  --text-muted: #777777;
  --primary: #c8d6e5;
  --primary-hover: #dfe6ed;
  --secondary: #ff6b5a;
  --secondary-hover: #ff8a7d;
  --secondary-light: rgba(255, 107, 90, 0.12);

  --accent: #ff6b5a;
  --accent-hover: #ff8a7d;
  --accent-light: rgba(255, 107, 90, 0.12);
  --border: #333333;
  --border-light: #2a2a2a;
  --shadow: rgba(0, 0, 0, 0.3);
  --shadow-md: rgba(0, 0, 0, 0.4);
  --shadow-lg: rgba(0, 0, 0, 0.5);
  --overlay: rgba(0, 0, 0, 0.7);
  --progress-bg: rgba(255, 255, 255, 0.08);
  --card-shadow: 0 5px 30px rgba(0, 0, 0, 0.3);
  --card-shadow-hover: 0 12px 40px rgba(0, 0, 0, 0.45);
}

/* --- Base --- */
html {
  scroll-behavior: smooth;
  scroll-padding-top: calc(var(--nav-height) + 24px);
}

body {
  font-family: var(--font-body);
  font-size: 16px;
  font-weight: 300;
  line-height: 1.7;
  color: var(--text);
  background: var(--bg);
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
  transition: background 0.3s ease, color 0.3s ease;
}

a {
  color: var(--accent);
  text-decoration: none;
  transition: color 0.2s ease;
}
a:hover { color: var(--accent-hover); }

/* Focus-visible states for accessibility */
a:focus-visible,
button:focus-visible,
input:focus-visible,
textarea:focus-visible,
select:focus-visible {
  outline: 2px solid var(--accent);
  outline-offset: 2px;
}

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

/* --- Typography --- */
h1, h2, h3, h4, h5, h6 {
  font-family: var(--font-heading);
  font-weight: 700;
  line-height: 1.2;
  color: var(--text);
}

h1 { font-size: clamp(32px, 5vw, 56px); letter-spacing: -0.01em; }
h2 { font-size: clamp(26px, 3.5vw, 40px); letter-spacing: -0.01em; }
h3 { font-size: clamp(20px, 2.5vw, 28px); }
h4 { font-size: 18px; }

p { margin-bottom: 16px; }

/* --- Utility --- */
.container {
  max-width: var(--wide-width);
  margin: 0 auto;
  padding: 0 24px;
}

.reading-column {
  max-width: var(--reading-width);
  margin: 0 auto;
  padding: 0 24px;
}

.sr-only {
  position: absolute;
  width: 1px; height: 1px;
  padding: 0; margin: -1px;
  overflow: hidden;
  clip: rect(0, 0, 0, 0);
  border: 0;
}

.badge {
  display: inline-block;
  font-family: var(--font-body);
  font-size: 11px;
  font-weight: 600;
  text-transform: uppercase;
  letter-spacing: 0.08em;
  padding: 5px 12px;
  border-radius: 4px;
  background: var(--accent);
  color: #fff;
}

/* ============================================
   NAVIGATION
   ============================================ */
.site-nav {
  position: sticky;
  top: 0;
  z-index: 1000;
  background: var(--bg);
  border-bottom: 1px solid var(--border);
  height: var(--nav-height);
  transition: background 0.3s ease, border-color 0.3s ease, box-shadow 0.3s ease;
}

.site-nav.scrolled {
  box-shadow: 0 2px 20px var(--shadow);
}

.nav-inner {
  max-width: var(--wide-width);
  margin: 0 auto;
  padding: 0 24px;
  height: 100%;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 24px;
}

.nav-logo {
  font-family: var(--font-heading);
  font-size: 18px;
  font-weight: 700;
  color: var(--text);
  text-decoration: none;
  white-space: nowrap;
}
.nav-logo:hover { color: var(--accent); }

.nav-links {
  display: flex;
  align-items: center;
  gap: 4px;
  list-style: none;
  overflow: visible;
}

.nav-links a {
  font-size: 13px;
  font-weight: 500;
  color: var(--text-secondary);
  white-space: nowrap;
  padding: 6px 12px;
  border-radius: 6px;
  transition: all 0.2s ease;
}
.nav-links a:hover {
  color: var(--text);
  background: var(--surface-hover);
}

.nav-right {
  display: flex;
  align-items: center;
  gap: 12px;
}

/* Nav dropdown */
.nav-dropdown { position: relative; }
.nav-dropdown > a { cursor: pointer; }

.dropdown-menu {
  display: none;
  position: absolute;
  top: 100%;
  left: 50%;
  transform: translateX(-50%);
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: 10px;
  padding: 8px 0;
  min-width: 200px;
  box-shadow: 0 8px 32px var(--shadow-md);
  z-index: 1001;
}

.nav-dropdown:hover .dropdown-menu,
.nav-dropdown.open .dropdown-menu { display: block; }

.dropdown-menu a {
  display: block;
  padding: 10px 20px;
  font-size: 13px;
  font-weight: 500;
  color: var(--text-secondary);
  white-space: nowrap;
  border-radius: 0;
}
.dropdown-menu a:hover {
  color: var(--text);
  background: var(--surface-hover);
}

/* ============================================
   MEGA MENU
   ============================================ */
.mega-menu {
  display: none;
  position: absolute;
  top: 100%;
  left: 50%;
  transform: translateX(-50%);
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: 12px;
  padding: 20px 24px;
  min-width: 580px;
  box-shadow: 0 12px 48px var(--shadow-md);
  z-index: 1001;
}
.nav-has-mega:hover .mega-menu,
.nav-has-mega.open .mega-menu { display: grid; grid-template-columns: repeat(3, 1fr); gap: 20px; }

.mega-label {
  display: block;
  font-family: var(--font-heading);
  font-size: 11px;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.1em;
  color: var(--accent);
  padding: 0 0 8px;
  margin-bottom: 4px;
  border-bottom: 1px solid var(--border-light);
}

.mega-col a {
  display: flex;
  align-items: center;
  gap: 8px;
  padding: 6px 8px;
  font-size: 13px;
  font-weight: 500;
  color: var(--text-secondary);
  border-radius: 6px;
  transition: all 0.15s ease;
  white-space: nowrap;
}
.mega-col a:hover {
  color: var(--text);
  background: var(--surface-hover);
}

.mega-step {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 22px;
  height: 22px;
  border-radius: 6px;
  background: var(--accent);
  color: #fff;
  font-family: var(--font-heading);
  font-size: 11px;
  font-weight: 800;
  flex-shrink: 0;
}

.mega-view-all {
  margin-top: 4px;
  color: var(--accent) !important;
  font-weight: 600 !important;
  font-size: 12px !important;
}
.mega-view-all:hover {
  color: var(--text) !important;
}

/* ============================================
   MOBILE NAV (accordion)
   ============================================ */
.mobile-nav-group {
  border-bottom: 1px solid var(--border-light);
}
.mobile-nav-toggle {
  display: flex;
  align-items: center;
  justify-content: space-between;
  width: 100%;
  background: none;
  border: none;
  cursor: pointer;
  font-family: var(--font-heading);
  font-size: 17px;
  font-weight: 700;
  color: var(--text);
  padding: 16px 0;
  text-align: left;
}
.mobile-nav-arrow {
  font-size: 12px;
  transition: transform 0.25s ease;
  color: var(--text-muted);
}
.mobile-nav-toggle[aria-expanded="true"] .mobile-nav-arrow {
  transform: rotate(180deg);
}

.mobile-nav-panel {
  display: none;
  padding: 0 0 12px 4px;
}
.mobile-nav-toggle[aria-expanded="true"] + .mobile-nav-panel {
  display: block;
}

.mobile-nav-sub-label {
  display: block;
  font-size: 11px;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.1em;
  color: var(--accent);
  padding: 12px 0 4px;
  margin-top: 4px;
}
.mobile-nav-sub-label:first-child {
  padding-top: 0;
  margin-top: 0;
}

.mobile-nav-panel a {
  font-size: 15px !important;
  padding: 8px 0 8px 12px !important;
  border-bottom: none !important;
  display: flex !important;
  align-items: center;
  gap: 8px;
}

.mobile-nav-highlight {
  display: flex !important;
  align-items: center;
  gap: 6px;
  font-size: 17px !important;
  font-weight: 700 !important;
  padding: 16px 0 !important;
  border-bottom: 1px solid var(--border-light) !important;
}

.mobile-nav-panel .mega-step {
  width: 20px;
  height: 20px;
  font-size: 10px;
}

/* Mega menu responsive — prevent overflow */
@media (max-width: 1100px) {
  .mega-menu {
    left: auto;
    right: 0;
    transform: none;
  }
  .nav-has-mega:first-child .mega-menu {
    left: 0;
    right: auto;
  }
}
@media (max-width: 900px) {
  .mega-menu {
    min-width: 480px;
  }
  .mega-col a {
    font-size: 12px;
    padding: 5px 6px;
  }
}

/* Theme toggle */
.theme-toggle {
  background: none;
  border: 1px solid var(--border);
  border-radius: 8px;
  cursor: pointer;
  padding: 8px;
  color: var(--text-secondary);
  display: flex;
  align-items: center;
  justify-content: center;
  transition: all 0.2s ease;
  width: 36px;
  height: 36px;
}
.theme-toggle:hover {
  color: var(--text);
  border-color: var(--text-muted);
  background: var(--surface-hover);
}
.theme-toggle svg { width: 18px; height: 18px; }

/* Hamburger */
.nav-hamburger {
  display: none;
  background: none;
  border: none;
  cursor: pointer;
  padding: 8px;
  color: var(--text);
}
.nav-hamburger svg { width: 24px; height: 24px; }

/* Mobile nav */
.mobile-nav {
  display: none;
  position: fixed;
  top: var(--nav-height);
  left: 0; right: 0; bottom: 0;
  background: var(--bg);
  z-index: 999;
  padding: 24px;
  overflow-y: auto;
}
.mobile-nav.open { display: block; }

.mobile-nav a {
  display: block;
  font-size: 18px;
  font-weight: 500;
  color: var(--text);
  padding: 14px 0;
  border-bottom: 1px solid var(--border-light);
}

/* ============================================
   HERO SECTION
   ============================================ */
.hero {
  min-height: calc(100vh - var(--nav-height));
  display: flex;
  flex-direction: column;
  justify-content: flex-start;
  align-items: center;
  text-align: center;
  padding: 50px 24px 80px;
  background: transparent;
  color: #fff;
  position: relative;
  overflow: hidden;
}

.hero-video {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  object-fit: cover;
  z-index: 0;
}

.hero-bg-iframe {
  position: absolute;
  inset: 0;
  width: 100vw;
  height: 100vh;
  border: none;
  z-index: 0;
  pointer-events: none;
}

.hero > *:not(.hero-video):not(.hero-bg-iframe) {
  position: relative;
  z-index: 2;
}

.hero::before {
  display: none;
}

.hero-overline {
  font-family: var(--font-body);
  font-size: 13px;
  font-weight: 600;
  text-transform: uppercase;
  letter-spacing: 0.15em;
  color: var(--accent);
  margin-bottom: 24px;
  position: relative;
}

.hero h1 {
  font-size: clamp(36px, 6vw, 72px);
  font-weight: 700;
  line-height: 1.05;
  max-width: 900px;
  margin-bottom: 24px;
  letter-spacing: -0.02em;
  color: #fff;
  position: relative;
}

.hero-subtitle {
  font-size: clamp(14px, 2vw, 24px);
  color: rgba(255, 255, 255, 0.9);
  max-width: 720px;
  line-height: 1.5;
  margin-bottom: 40px;
  font-weight: 600;
  position: relative;
}

.hero-cta {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  background: var(--accent);
  color: #fff;
  font-family: var(--font-body);
  font-size: 15px;
  font-weight: 600;
  padding: 14px 32px;
  border-radius: 50px;
  border: none;
  cursor: pointer;
  text-decoration: none;
  transition: all 0.25s ease;
}
.hero-cta:hover {
  background: var(--accent-hover);
  color: #fff;
  transform: translateY(-2px);
  box-shadow: 0 8px 24px rgba(255, 135, 99, 0.35);
}

.hero-cta-row {
  display: flex;
  gap: 16px;
  justify-content: center;
  flex-wrap: wrap;
  position: relative;
}

.hero-cta-secondary {
  background: transparent;
  border: 2px solid rgba(255, 255, 255, 0.3);
  color: #fff;
}
.hero-cta-secondary:hover {
  background: rgba(255, 255, 255, 0.1);
  border-color: rgba(255, 255, 255, 0.5);
  color: #fff;
  box-shadow: none;
}

.hero-meta {
  margin-top: 48px;
  display: flex;
  gap: 32px;
  color: rgba(255, 255, 255, 0.5);
  font-size: 14px;
  font-weight: 400;
  position: relative;
}

.hero-meta span {
  display: flex;
  align-items: center;
  gap: 6px;
}

/* ============================================
   INTRO SECTION
   ============================================ */
.intro-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 64px;
  align-items: start;
}
.intro-h1 {
  font-family: var(--font-heading);
  font-size: clamp(32px, 4vw, 48px);
  font-weight: 800;
  color: var(--text);
  line-height: 1.1;
  margin-bottom: 16px;
}
.intro-h2 {
  font-family: var(--font-heading);
  font-size: clamp(18px, 2vw, 24px);
  font-weight: 500;
  color: var(--text-secondary);
  line-height: 1.4;
}
.intro-h3 {
  font-family: var(--font-heading);
  font-size: clamp(14px, 1.5vw, 18px);
  font-weight: 800;
  color: var(--secondary);
  line-height: 1.2;
  margin-top: 16px;
  letter-spacing: 0.08em;
  text-transform: uppercase;
}
.intro-right p {
  font-family: var(--font-body);
  font-size: 16px;
  color: var(--text-secondary);
  line-height: 1.8;
  font-weight: 450;
  margin-bottom: 16px;
}
.intro-right p:last-child {
  margin-bottom: 0;
}

/* ============================================
   QUOTE BANNER
   ============================================ */
.quote-banner {
  background: var(--bg-alt);
  padding: 64px 24px;
  text-align: center;
  border-top: 1px solid var(--border);
  border-bottom: 1px solid var(--border);
}
.pull-quote {
  font-family: var(--font-heading);
  font-size: clamp(20px, 3vw, 32px);
  font-weight: 600;
  font-style: italic;
  color: var(--text);
  line-height: 1.5;
  max-width: 800px;
  margin: 0 auto 20px;
}
.quote-cite {
  font-family: var(--font-body);
  font-size: 14px;
  color: var(--text-muted);
  font-style: normal;
}
.quote-cite a {
  color: var(--secondary);
  text-decoration: underline;
}

/* ============================================
   PREPARE BANNER
   ============================================ */
.prepare-banner {
  background: #4ade80;
  padding: 64px 24px;
  text-align: center;
}
.prepare-banner h2 {
  font-family: var(--font-heading);
  font-size: clamp(28px, 4vw, 44px);
  font-weight: 800;
  color: #000;
  margin-bottom: 24px;
  line-height: 1.15;
}
.prepare-banner p {
  font-family: var(--font-body);
  font-size: 17px;
  color: #111;
  line-height: 1.8;
  max-width: 760px;
  margin: 0 auto 16px;
  font-weight: 450;
}
.prepare-banner p:last-child {
  margin-bottom: 0;
}
.prepare-banner strong {
  color: #000;
  font-weight: 700;
}

/* ============================================
   IMAGE PLACEHOLDERS
   ============================================ */
.img-placeholder {
  width: 100%;
  height: 100%;
  min-height: 200px;
  background-size: cover;
  background-position: center;
}

.img-crisis { background-color: #4a1a0a; }
.img-thesis { background-color: #0a4040; }
.img-verticals { background-color: #2a2a2a; }
.img-vision { background-color: #2a0a4a; }
.img-global { background-color: #0a2040; }
.img-opinion { background-color: #4a0a3a; }
.img-playbook { background-color: #6b3210; }
.img-government { background-color: #1a3a2a; }
.img-business { background-color: #2a1a3a; }
.img-featured { background-color: #0a1428; }

/* Pulsing NEW badge */
.pulse-badge {
  display: inline-block;
  background: #e63926;
  color: #fff;
  font-size: 9px;
  font-weight: 700;
  letter-spacing: 0.08em;
  padding: 2px 6px;
  border-radius: 4px;
  text-transform: uppercase;
  animation: pulse-glow 2s ease-in-out infinite;
  line-height: 1.2;
}

@keyframes pulse-glow {
  0%, 100% { box-shadow: 0 0 4px rgba(230, 57, 38, 0.4); opacity: 1; }
  50% { box-shadow: 0 0 16px rgba(230, 57, 38, 0.8); opacity: 0.85; }
}

/* ============================================
   SECTIONS
   ============================================ */
.section {
  padding: 80px 0;
}

.section-alt {
  background: var(--bg-alt);
}

.section-header {
  margin-bottom: 48px;
}

.section-header-row {
  display: flex;
  justify-content: space-between;
  align-items: flex-end;
  gap: 16px;
  flex-wrap: wrap;
}

.section-overline {
  font-family: var(--font-body);
  font-size: 12px;
  font-weight: 600;
  text-transform: uppercase;
  letter-spacing: 0.15em;
  color: var(--accent);
  margin-bottom: 12px;
}

.section-title {
  font-size: clamp(28px, 4vw, 40px);
  margin-bottom: 12px;
  letter-spacing: -0.01em;
}

.section-subtitle {
  font-size: 16px;
  color: var(--text-secondary);
  max-width: 600px;
  line-height: 1.7;
  font-weight: 300;
}

.section-view-all {
  font-size: 14px;
  font-weight: 600;
  color: var(--accent);
  white-space: nowrap;
  transition: all 0.2s ease;
}
.section-view-all:hover {
  color: var(--accent-hover);
}

/* ============================================
   MAGAZINE CARD SYSTEM
   ============================================ */

/* --- Large Overlay Card --- */
.mag-card-lg {
  position: relative;
  display: block;
  border-radius: 16px;
  overflow: hidden;
  text-decoration: none;
  color: #fff;
  aspect-ratio: 16 / 9;
  transition: transform 0.3s ease, box-shadow 0.3s ease;
}

.mag-card-lg:hover {
  transform: translateY(-4px);
  box-shadow: var(--card-shadow-hover);
  color: #fff;
}

.mag-card-lg .mag-card-img {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  object-fit: cover;
}

.mag-card-lg .img-placeholder {
  position: absolute;
  inset: 0;
}

.mag-card-lg .mag-card-overlay {
  position: absolute;
  inset: 0;
  background: linear-gradient(to top, rgba(0,0,0,0.75) 0%, rgba(0,0,0,0.1) 60%, transparent 100%);
  display: flex;
  flex-direction: column;
  justify-content: flex-end;
  padding: 28px;
}

.mag-card-badge {
  display: inline-block;
  font-family: var(--font-body);
  font-size: 11px;
  font-weight: 600;
  text-transform: uppercase;
  letter-spacing: 0.08em;
  padding: 5px 12px;
  border-radius: 4px;
  background: var(--accent);
  color: #fff;
  margin-bottom: 12px;
  width: fit-content;
}

.mag-card-lg .mag-card-title {
  font-family: var(--font-heading);
  font-size: clamp(20px, 2.5vw, 28px);
  font-weight: 700;
  line-height: 1.2;
  margin-bottom: 6px;
  color: #fff;
}

.mag-card-lg .mag-card-excerpt {
  font-size: 14px;
  font-weight: 300;
  color: rgba(255, 255, 255, 0.8);
  line-height: 1.5;
  display: -webkit-box;
  -webkit-line-clamp: 2;
  -webkit-box-orient: vertical;
  overflow: hidden;
}

.mag-card-lg .mag-card-meta {
  font-size: 12px;
  color: rgba(255, 255, 255, 0.5);
  margin-top: 8px;
  font-weight: 400;
}

/* --- Small Vertical Card --- */
.mag-card-sm {
  display: flex;
  flex-direction: column;
  background: var(--surface);
  border-radius: 14px;
  overflow: hidden;
  text-decoration: none;
  color: var(--text);
  box-shadow: var(--card-shadow);
  transition: transform 0.3s ease, box-shadow 0.3s ease;
}

.mag-card-sm:hover {
  transform: translateY(-4px);
  box-shadow: var(--card-shadow-hover);
  color: var(--text);
}

.mag-card-sm .mag-card-thumb {
  aspect-ratio: 16 / 10;
  overflow: hidden;
  position: relative;
}

.mag-card-sm .mag-card-thumb img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  transition: transform 0.4s ease;
}

.mag-card-sm:hover .mag-card-thumb img {
  transform: scale(1.05);
}

.mag-card-sm .mag-card-thumb .img-placeholder {
  width: 100%;
  height: 100%;
  position: absolute;
  inset: 0;
}

.mag-card-sm .mag-card-thumb .mag-card-badge {
  position: absolute;
  top: 14px;
  left: 14px;
  margin-bottom: 0;
}

.mag-card-sm .mag-card-body {
  padding: 20px;
  flex: 1;
  display: flex;
  flex-direction: column;
}

.mag-card-sm .mag-card-title {
  font-family: var(--font-heading);
  font-size: 18px;
  font-weight: 700;
  line-height: 1.3;
  margin-bottom: 6px;
  color: var(--text);
}

.mag-card-sm .mag-card-excerpt {
  font-size: 14px;
  font-weight: 300;
  color: var(--text-secondary);
  line-height: 1.6;
  flex: 1;
  display: -webkit-box;
  -webkit-line-clamp: 3;
  -webkit-box-orient: vertical;
  overflow: hidden;
}

.mag-card-sm .mag-card-meta {
  font-size: 12px;
  color: var(--text-muted);
  margin-top: 12px;
  padding-top: 12px;
  border-top: 1px solid var(--border-light);
  display: flex;
  justify-content: space-between;
  align-items: center;
  font-weight: 400;
}

.mag-card-arrow {
  color: var(--accent);
  font-size: 16px;
  transition: transform 0.2s ease;
}
.mag-card-sm:hover .mag-card-arrow { transform: translateX(4px); }

/* ============================================
   MAGAZINE GRIDS
   ============================================ */

/* --- Mosaic Grid --- */
.mosaic-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  grid-template-rows: 280px 280px;
  gap: 16px;
}
.mosaic-tile {
  position: relative;
  overflow: hidden;
  border-radius: 12px;
  text-decoration: none;
  color: #fff;
}
.mosaic-tile .img-placeholder {
  position: absolute;
  inset: 0;
  transition: transform 0.4s ease;
}
.mosaic-tile:hover .img-placeholder {
  transform: scale(1.05);
}
.mosaic-overlay {
  position: absolute;
  inset: 0;
  background: linear-gradient(to top, rgba(0,0,0,0.85) 0%, rgba(0,0,0,0.2) 50%, transparent 100%);
  display: flex;
  flex-direction: column;
  justify-content: flex-end;
  padding: 24px;
  z-index: 1;
}
.mosaic-overlay .mag-card-title {
  color: #fff;
  font-size: 20px;
  margin: 6px 0 4px;
}
.mosaic-overlay .mag-card-excerpt {
  color: rgba(255,255,255,0.8);
  font-size: 14px;
  margin: 0;
}
.mosaic-overlay .mag-card-meta {
  color: rgba(255,255,255,0.6);
  font-size: 13px;
  margin-top: 8px;
}
.mosaic-tall {
  grid-row: span 2;
}
.mosaic-wide {
  grid-column: span 2;
}

.mag-grid-featured {
  display: grid;
  grid-template-columns: 1.2fr 1fr;
  grid-template-rows: auto auto;
  gap: 24px;
}
.mag-grid-featured > :first-child {
  grid-row: 1 / 3;
}

.mag-grid-2 {
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  gap: 24px;
}

.mag-grid-3 {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 24px;
}

.mag-grid-2x2 {
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  gap: 24px;
}

.mag-grid-5 {
  display: grid;
  grid-template-columns: repeat(5, 1fr);
  gap: 24px;
}

/* ============================================
   FEATURED ARTICLE SECTION
   ============================================ */
.featured-card {
  background: var(--surface);
  border-radius: 16px;
  overflow: hidden;
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 0;
  text-decoration: none;
  color: var(--text);
  box-shadow: var(--card-shadow);
  transition: transform 0.3s ease, box-shadow 0.3s ease;
}
.featured-card:hover {
  color: var(--text);
  transform: translateY(-4px);
  box-shadow: var(--card-shadow-hover);
}

.featured-card-img {
  position: relative;
  min-height: 320px;
}
.featured-card-img .img-placeholder {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
}

.featured-content {
  padding: 40px;
  display: flex;
  flex-direction: column;
  justify-content: center;
}

.featured-content .phase-badge {
  display: inline-block;
  margin-bottom: 16px;
  width: fit-content;
}

.featured-content .card-title {
  font-family: var(--font-heading);
  font-size: 28px;
  font-weight: 700;
  line-height: 1.2;
  margin-bottom: 8px;
}

.featured-content .card-subtitle {
  font-size: 15px;
  color: var(--text-secondary);
  font-weight: 300;
  line-height: 1.6;
  margin-bottom: 16px;
}

.featured-content .card-preview {
  font-size: 14px;
  color: var(--text-muted);
  line-height: 1.7;
  font-weight: 300;
}

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

.featured-pullquote {
  padding: 40px;
  display: flex;
  align-items: center;
  background: var(--bg-alt);
  font-family: var(--font-heading);
  font-size: 18px;
  font-style: italic;
  line-height: 1.6;
  color: var(--text-secondary);
  border-left: 3px solid var(--accent);
}

.phase-badge {
  font-family: var(--font-body);
  font-size: 11px;
  font-weight: 600;
  text-transform: uppercase;
  letter-spacing: 0.08em;
  padding: 5px 12px;
  border-radius: 4px;
  background: var(--accent-light);
  color: var(--accent);
}

.card-number {
  font-size: 12px;
  font-weight: 600;
  color: var(--text-muted);
}

.card-type {
  font-size: 11px;
  font-weight: 500;
  color: var(--text-muted);
  margin-left: auto;
}

.card-meta {
  display: flex;
  align-items: center;
  gap: 10px;
  margin-bottom: 14px;
  flex-wrap: wrap;
}

.card-readtime {
  font-size: 13px;
  color: var(--text-muted);
  font-weight: 500;
}

.card-arrow {
  color: var(--accent);
  font-size: 18px;
  transition: transform 0.2s ease;
}

/* ============================================
   TOPIC LANDING PAGE
   ============================================ */
.topic-hero {
  padding: 100px 24px 60px;
  min-height: 100vh;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  text-align: center;
  position: relative;
  overflow: hidden;
}

.topic-hero .img-placeholder {
  position: absolute;
  inset: 0;
  z-index: 0;
}

.topic-hero::after {
  content: '';
  position: absolute;
  inset: 0;
  background: linear-gradient(to bottom, rgba(0,0,0,0.1) 0%, rgba(0,0,0,0.75) 100%);
  z-index: 1;
}

.topic-hero > * {
  position: relative;
  z-index: 2;
}

.topic-hero .section-overline {
  color: var(--accent);
  margin-bottom: 16px;
}

.topic-hero h1 {
  color: #fff;
  margin-bottom: 16px;
}

.topic-hero .topic-subtitle {
  font-size: 17px;
  color: rgba(255, 255, 255, 0.9);
  max-width: 640px;
  margin: 0 auto 32px;
  line-height: 1.7;
  font-weight: 500;
}

.topic-hero .topic-stats {
  display: flex;
  gap: 32px;
  justify-content: center;
  color: rgba(255, 255, 255, 0.5);
  font-size: 14px;
}

.topic-grid {
  padding: 64px 0;
}

.continue-reading {
  padding: 64px 0;
  background: var(--bg-alt);
}

.continue-reading .section-header {
  margin-bottom: 32px;
}

/* ============================================
   ARTICLE READER
   ============================================ */

/* Reading progress bar */
.progress-bar {
  position: fixed;
  top: 0;
  left: 0;
  height: 3px;
  background: var(--accent);
  z-index: 1001;
  transition: width 0.1s linear;
}

/* Article hero */
.article-hero {
  position: relative;
  min-height: 100vh;
  display: flex;
  align-items: flex-end;
  overflow: hidden;
}

.article-hero .img-placeholder {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
}

.article-hero::after {
  content: '';
  position: absolute;
  inset: 0;
  background: linear-gradient(to top, rgba(0,0,0,0.8) 0%, rgba(0,0,0,0.2) 60%, transparent 100%);
}

.article-hero-content {
  position: relative;
  z-index: 1;
  padding: 48px;
  max-width: var(--wide-width);
  margin: 0 auto;
  width: 100%;
  color: #fff;
}

.article-hero-content .phase-badge {
  background: var(--accent);
  color: #fff;
  margin-bottom: 16px;
}

.article-hero-content h1 {
  font-size: clamp(28px, 5vw, 48px);
  color: #fff;
  margin-bottom: 8px;
  max-width: 800px;
}

.article-hero-content .subtitle {
  font-size: 18px;
  color: rgba(255, 255, 255, 0.9);
  font-weight: 500;
  max-width: 640px;
  margin-bottom: 16px;
}

.article-hero-content .article-meta {
  display: flex;
  gap: 20px;
  color: rgba(255, 255, 255, 0.5);
  font-size: 14px;
}

/* Fallback article header (no hero) */
.article-header {
  padding: 80px 24px 48px;
  text-align: center;
  max-width: 800px;
  margin: 0 auto;
}

.article-header .phase-badge {
  display: inline-block;
  margin-bottom: 16px;
}

.article-header .card-number {
  display: block;
  margin-bottom: 8px;
  font-size: 14px;
}

.article-header h1 {
  font-size: clamp(32px, 5vw, 52px);
  margin-bottom: 16px;
  letter-spacing: -0.02em;
}

.article-header .subtitle {
  font-size: 20px;
  color: var(--text-secondary);
  line-height: 1.5;
  margin-bottom: 24px;
  font-weight: 300;
}

.article-meta {
  display: flex;
  justify-content: center;
  gap: 24px;
  color: var(--text-muted);
  font-size: 14px;
}

/* The Argument block */
.argument-block {
  background: var(--accent-light);
  border-left: 4px solid var(--accent);
  border-radius: 0 12px 12px 0;
  padding: 24px 28px;
  margin: 40px auto;
  max-width: var(--reading-width);
}

.argument-block h3 {
  font-family: var(--font-body);
  font-size: 12px;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.1em;
  color: var(--accent);
  margin-bottom: 10px;
}

.argument-block p {
  font-size: 16px;
  line-height: 1.7;
  color: var(--text-secondary);
  margin-bottom: 0;
}

/* Article body */
.article-body {
  max-width: var(--reading-width);
  margin: 0 auto;
  padding: 0 24px 80px;
  font-size: 18px;
  line-height: 1.8;
  color: var(--text);
  font-weight: 300;
}

.article-body h2 {
  font-size: 28px;
  margin: 48px 0 20px;
  padding-top: 24px;
}

.article-body h3 {
  font-size: 22px;
  margin: 36px 0 16px;
}

.article-body h4 {
  font-family: var(--font-body);
  font-size: 16px;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.05em;
  margin: 32px 0 12px;
  color: var(--text-secondary);
}

.article-body p {
  margin-bottom: 20px;
}

.article-body blockquote {
  font-family: var(--font-heading);
  font-size: 20px;
  font-style: italic;
  line-height: 1.6;
  color: var(--text-secondary);
  border-left: 3px solid var(--accent);
  padding: 4px 0 4px 24px;
  margin: 32px 0;
}

.article-body ul, .article-body ol {
  margin: 16px 0 20px;
  padding-left: 28px;
}

.article-body li { margin-bottom: 8px; }

.article-body strong {
  font-weight: 600;
  color: var(--text);
}

.article-body em { font-style: italic; }

.article-body hr {
  border: none;
  border-top: 1px solid var(--border);
  margin: 48px 0;
}

.article-body a {
  color: var(--accent);
  text-decoration: underline;
  text-underline-offset: 3px;
}

.article-body .section-break {
  text-align: center;
  margin: 48px 0;
  color: var(--text-muted);
  font-size: 24px;
  letter-spacing: 0.5em;
}

/* Related articles */
.related-articles {
  padding: 64px 0;
  background: var(--bg-alt);
}

.related-articles .section-header {
  margin-bottom: 32px;
}

/* Article navigation */
.article-nav {
  max-width: var(--reading-width);
  margin: 0 auto;
  padding: 0 24px 80px;
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 24px;
}

.article-nav a {
  display: block;
  padding: 20px;
  border: 1px solid var(--border);
  border-radius: 12px;
  text-decoration: none;
  color: var(--text);
  transition: all 0.25s ease;
}
.article-nav a:hover {
  border-color: var(--accent);
  color: var(--text);
  box-shadow: var(--card-shadow);
}

.article-nav .nav-label {
  font-size: 12px;
  font-weight: 600;
  text-transform: uppercase;
  letter-spacing: 0.08em;
  color: var(--text-muted);
  margin-bottom: 6px;
}

.article-nav .nav-title {
  font-family: var(--font-heading);
  font-size: 16px;
  font-weight: 600;
}

.article-nav .next { text-align: right; }

.back-link {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  font-size: 14px;
  font-weight: 500;
  color: var(--text-secondary);
  margin-bottom: 40px;
  text-decoration: none;
}
.back-link:hover { color: var(--accent); }

/* --- Chart Previews (in-article) --- */
.chart-preview {
  display: block;
  position: relative;
  margin: 48px auto;
  max-width: var(--reading-width);
  height: 476px;
  border-radius: 14px;
  overflow: hidden;
  background: #ffffff;
  border: 1px solid var(--border);
  box-shadow: var(--card-shadow);
  cursor: pointer;
  transition: box-shadow 0.3s, transform 0.25s;
  text-decoration: none;
}
.chart-preview:hover {
  box-shadow: var(--card-shadow-hover);
  transform: translateY(-2px);
}
.chart-preview iframe {
  display: block;
  width: 1000px;
  height: 700px;
  border: none;
  transform: scale(0.68);
  transform-origin: top left;
  pointer-events: none;
}
.chart-preview-overlay {
  position: absolute;
  inset: 0;
  display: flex;
  align-items: flex-end;
  justify-content: center;
  padding-bottom: 20px;
  background: linear-gradient(to top, rgba(0,0,0,0.4) 0%, transparent 40%);
  opacity: 0;
  transition: opacity 0.3s;
}
.chart-preview:hover .chart-preview-overlay { opacity: 1; }
.chart-preview-label {
  font-family: var(--font-body);
  font-size: 14px;
  font-weight: 600;
  color: #fff;
  background: rgba(0,0,0,0.6);
  padding: 8px 16px;
  border-radius: 8px;
}

/* ============================================
   KEYNOTE PAGE
   ============================================ */
.keynote-hero {
  padding: 0;
  margin: 0;
  min-height: 100vh;
  min-height: 100dvh;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  text-align: center;
  position: relative;
  overflow: hidden;
  background: linear-gradient(135deg, #1a1a2e 0%, #16213e 40%, #0f3460 100%);
  color: #fff;
}

.keynote-hero .img-placeholder {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  min-height: 0;
  z-index: 0;
}

.keynote-hero::after {
  content: '';
  position: absolute;
  inset: 0;
  background: linear-gradient(to bottom, rgba(0,0,0,0.1) 0%, rgba(0,0,0,0.75) 100%);
  z-index: 1;
}

.keynote-hero > * {
  position: relative;
  z-index: 2;
}

.keynote-hero .section-overline {
  color: var(--accent);
  margin-bottom: 16px;
}

.keynote-hero h1 {
  color: #fff;
  margin-bottom: 16px;
}

.keynote-hero .subtitle {
  font-size: 20px;
  color: rgba(255, 255, 255, 0.75);
  font-weight: 300;
}

.keynote-hero .article-meta {
  margin-top: 20px;
  color: rgba(255, 255, 255, 0.5);
}

/* Fallback keynote header */
.keynote-header {
  text-align: center;
  padding: 80px 24px 48px;
}

.keynote-header h1 {
  font-size: clamp(32px, 5vw, 52px);
  margin-bottom: 16px;
}

.keynote-header .subtitle {
  font-size: 20px;
  color: var(--text-secondary);
  font-weight: 300;
}

/* Keynote Synopsis / Pitch Block */
.keynote-synopsis {
  background: var(--primary);
  color: #fff;
  padding: 72px 24px;
  border-top: 4px solid var(--secondary);
}
.synopsis-inner {
  max-width: 740px;
  margin: 0 auto;
}
.synopsis-label {
  text-transform: uppercase;
  letter-spacing: 4px;
  font-size: 0.7rem;
  font-weight: 700;
  font-family: var(--font-heading);
  color: var(--secondary);
  margin-bottom: 24px;
}
.synopsis-headline {
  font-family: var(--font-heading);
  font-size: clamp(1.75rem, 4vw, 2.5rem);
  font-weight: 800;
  line-height: 1.15;
  margin-bottom: 36px;
  color: #fff;
  letter-spacing: -0.5px;
}
.synopsis-body p {
  font-family: var(--font-body);
  font-size: 1.08rem;
  line-height: 1.8;
  color: rgba(255, 255, 255, 0.92);
  font-weight: 400;
  margin-bottom: 20px;
}
.synopsis-body p:last-child {
  margin-bottom: 0;
  font-size: 1.12rem;
  color: #fff;
}
.synopsis-body strong {
  color: #fff;
  font-weight: 700;
}

.keynote-layout {
  max-width: 1100px;
  margin: 0 auto;
  padding: 48px 24px 80px;
  display: grid;
  grid-template-columns: 200px 1fr;
  gap: 48px;
}

/* TOC */
.keynote-toc {
  position: sticky;
  top: calc(var(--nav-height) + 32px);
  align-self: start;
}

.keynote-toc h3 {
  font-family: var(--font-body);
  font-size: 11px;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.12em;
  color: var(--text-muted);
  margin-bottom: 16px;
}

.keynote-toc ul { list-style: none; }
.keynote-toc li { margin-bottom: 4px; }

.keynote-toc a {
  display: block;
  font-size: 13px;
  font-weight: 500;
  color: var(--text-secondary);
  padding: 6px 12px;
  border-radius: 6px;
  border-left: 2px solid transparent;
  transition: all 0.2s ease;
}
.keynote-toc a:hover {
  color: var(--text);
  background: var(--surface-hover);
}
.keynote-toc a.active {
  color: var(--accent);
  border-left-color: var(--accent);
  background: var(--accent-light);
}

/* Keynote body */
.keynote-body {
  font-size: 18px;
  line-height: 1.8;
  font-weight: 300;
}

.keynote-body h2 {
  font-size: 32px;
  margin: 56px 0 24px;
  padding-top: 24px;
  border-top: 1px solid var(--border);
}

.keynote-body h2:first-child {
  margin-top: 0;
  border-top: none;
  padding-top: 0;
}

.keynote-body h3 {
  font-size: 22px;
  margin: 36px 0 16px;
}

.keynote-body p { margin-bottom: 20px; }

.keynote-body blockquote {
  font-family: var(--font-heading);
  font-size: 20px;
  font-style: italic;
  line-height: 1.6;
  color: var(--text-secondary);
  border-left: 3px solid var(--accent);
  padding: 4px 0 4px 24px;
  margin: 32px 0;
}

/* Stage directions */
.stage-direction {
  font-family: var(--font-body);
  font-style: italic;
  color: var(--text-muted);
  font-size: 15px;
  font-weight: 300;
  background: var(--bg-alt);
  border-radius: 8px;
  padding: 8px 14px;
  margin: 16px 0;
  display: block;
  border-left: 3px solid var(--border);
}

.keynote-body hr {
  border: none;
  border-top: 1px solid var(--border);
  margin: 48px 0;
}

/* ============================================
   VISUALS GALLERY
   ============================================ */
.visuals-hero {
  text-align: center;
  padding: 100px 24px 60px;
  position: relative;
  overflow: hidden;
  background: linear-gradient(135deg, #1a1a2e 0%, #16213e 40%, #0f3460 100%);
  color: #fff;
}

.visuals-hero::before {
  content: '';
  position: absolute;
  inset: 0;
  background: radial-gradient(ellipse at 50% 50%, rgba(255, 135, 99, 0.1) 0%, transparent 60%);
  pointer-events: none;
}

.visuals-hero > * { position: relative; z-index: 1; }

.visuals-hero h1 {
  color: #fff;
  margin-bottom: 12px;
}

.visuals-hero .subtitle {
  font-size: 18px;
  color: rgba(255, 255, 255, 0.75);
  line-height: 1.6;
  font-weight: 300;
  max-width: 640px;
  margin: 0 auto;
}

/* Fallback visuals header */
.visuals-header {
  text-align: center;
  padding: 80px 24px 48px;
  max-width: 800px;
  margin: 0 auto;
}
.visuals-header h1 {
  font-size: clamp(32px, 5vw, 52px);
  margin-bottom: 12px;
  letter-spacing: -0.02em;
}
.visuals-header .subtitle {
  font-size: 18px;
  color: var(--text-secondary);
  line-height: 1.6;
  font-weight: 300;
}

.visuals-gallery {
  max-width: 100%;
  margin: 0 auto;
  padding: 0 24px 80px;
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 24px;
}

.visual-card {
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: 16px;
  overflow: hidden;
  scroll-margin-top: calc(var(--nav-height) + 24px);
  box-shadow: var(--card-shadow);
  display: flex;
  flex-direction: column;
}

.visual-card-full {
  grid-column: 1 / -1;
  max-width: 1200px;
  margin: 0 auto;
}

.visual-iframe-wrap {
  width: 100%;
  background: #ffffff;
}

.visual-iframe-wrap iframe,
.visual-iframe-wrap belonging-chart {
  display: block;
  width: 100%;
  min-height: 360px;
  border: none;
}

.visual-info {
  padding: 16px 20px;
  border-top: 1px solid var(--border-light);
  margin-top: auto;
}

.visual-title {
  font-family: var(--font-heading);
  font-size: 24px;
  font-weight: 700;
  margin-bottom: 4px;
}

.visual-subtitle {
  font-size: 15px;
  color: var(--text-secondary);
  margin-bottom: 8px;
  font-weight: 300;
}

.visual-source {
  font-size: 13px;
  color: var(--text-muted);
  font-style: italic;
  margin-bottom: 16px;
}
.visual-source a {
  color: var(--accent);
  text-decoration: underline;
  text-underline-offset: 2px;
}

.visual-actions {
  display: flex;
  align-items: center;
  gap: 12px;
  flex-wrap: wrap;
}

.visual-btn {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  font-family: var(--font-body);
  font-size: 13px;
  font-weight: 600;
  padding: 8px 16px;
  border-radius: 8px;
  border: 1px solid var(--border);
  background: var(--surface);
  color: var(--text-secondary);
  cursor: pointer;
  transition: all 0.2s;
  text-decoration: none;
}
.visual-btn:hover {
  color: var(--text);
  border-color: var(--text-muted);
  background: var(--surface-hover);
}
.visual-btn svg { width: 16px; height: 16px; }

.visual-toast {
  position: fixed;
  bottom: 32px;
  left: 50%;
  transform: translateX(-50%) translateY(100px);
  background: var(--text);
  color: var(--bg);
  font-family: var(--font-body);
  font-size: 14px;
  font-weight: 600;
  padding: 12px 24px;
  border-radius: 10px;
  box-shadow: 0 8px 32px var(--shadow-md);
  z-index: 9999;
  opacity: 0;
  transition: transform 0.3s ease, opacity 0.3s ease;
  pointer-events: none;
}
.visual-toast.show {
  transform: translateX(-50%) translateY(0);
  opacity: 1;
}

/* ============================================
   OPINION / LINKEDIN CARDS
   ============================================ */
.opinion-card {
  background: var(--surface);
  border-radius: 14px;
  padding: 28px;
  text-decoration: none;
  color: var(--text);
  box-shadow: var(--card-shadow);
  transition: all 0.25s ease;
  display: flex;
  flex-direction: column;
}
.opinion-card:hover {
  color: var(--text);
  transform: translateY(-4px);
  box-shadow: var(--card-shadow-hover);
}

.opinion-label {
  font-size: 11px;
  font-weight: 600;
  text-transform: uppercase;
  letter-spacing: 0.08em;
  color: var(--accent);
  margin-bottom: 12px;
}

.opinion-card .card-title {
  font-family: var(--font-heading);
  font-size: 20px;
  font-weight: 700;
  margin-bottom: 10px;
  line-height: 1.3;
}

.opinion-card .card-preview {
  font-size: 14px;
  color: var(--text-secondary);
  line-height: 1.7;
  flex-grow: 1;
  font-weight: 300;
}

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

/* ============================================
   KEYNOTE BANNER CTA
   ============================================ */
.keynote-banner {
  background: linear-gradient(135deg, #1a1a2e 0%, #16213e 50%, #0f3460 100%);
  padding: 80px 24px;
  text-align: center;
  position: relative;
  overflow: hidden;
}

.keynote-banner::before {
  content: '';
  position: absolute;
  inset: 0;
  background: radial-gradient(ellipse at 50% 50%, rgba(255, 135, 99, 0.1) 0%, transparent 60%);
  pointer-events: none;
}

.keynote-banner > * { position: relative; z-index: 1; }

.keynote-banner h2 {
  font-size: clamp(28px, 4vw, 40px);
  margin-bottom: 12px;
  color: #fff;
}

.keynote-banner p {
  color: rgba(255, 255, 255, 0.7);
  font-size: 16px;
  font-weight: 300;
  margin-bottom: 32px;
  max-width: 600px;
  margin-left: auto;
  margin-right: auto;
  line-height: 1.7;
}

.keynote-cta {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  background: var(--accent);
  color: #fff;
  font-family: var(--font-body);
  font-size: 15px;
  font-weight: 600;
  padding: 14px 32px;
  border-radius: 50px;
  text-decoration: none;
  transition: all 0.25s ease;
}
.keynote-cta:hover {
  background: var(--accent-hover);
  color: #fff;
  transform: translateY(-2px);
  box-shadow: 0 8px 24px rgba(255, 135, 99, 0.35);
}

/* ============================================
   ABOUT SECTION
   ============================================ */
.about-section {
  text-align: center;
  padding: 80px 24px;
}

.about-section h2 {
  font-size: clamp(28px, 4vw, 36px);
  margin-bottom: 16px;
}

.about-section p {
  color: var(--text-secondary);
  font-size: 16px;
  line-height: 1.7;
  max-width: 640px;
  margin: 0 auto 24px;
  font-weight: 300;
}

/* ============================================
   HOMEPAGE CHART GRID
   ============================================ */
.chart-grid {
  display: grid;
  grid-template-columns: 1fr;
  gap: 0;
  max-width: 100%;
  margin: 0;
  padding: 0;
}

.chart-grid.single-col {
  grid-template-columns: 1fr;
  max-width: 100%;
  gap: 48px;
}

.chart-grid.three-col {
  grid-template-columns: repeat(3, 1fr);
  max-width: 100%;
  gap: 24px;
}

@media (max-width: 900px) {
  .chart-grid.three-col {
    grid-template-columns: 1fr;
    gap: 32px;
  }
}

.chart-card {
  border-radius: 0;
  overflow: hidden;
  background: #ffffff;
  display: flex;
  flex-direction: column;
}

.chart-card iframe,
.chart-card belonging-chart {
  display: block;
  width: 100%;
  border: none;
  pointer-events: none;
  overflow: hidden;
}
.chart-card iframe {
  height: 100vh;
}

.chart-card-footer {
  margin-top: auto;
  padding: 16px 20px;
  background: var(--surface);
  border-top: 1px solid var(--border-light);
  display: flex;
  justify-content: space-between;
  align-items: center;
}

.chart-card-title {
  font-family: var(--font-body);
  font-size: 14px;
  font-weight: 600;
  color: var(--text);
}

.chart-card-link {
  font-family: var(--font-body);
  font-size: 13px;
  color: var(--accent);
  text-decoration: none;
}
.chart-card-link:hover { text-decoration: underline; }

/* ============================================
   DISRUPTION CHART (inline)
   ============================================ */
.disruption-section {
  padding: 0;
}

/* ============================================
   SHARE / EMBED MODAL
   ============================================ */
.modal-backdrop {
  display: none;
  position: fixed;
  inset: 0;
  background: var(--overlay);
  z-index: 10000;
  align-items: center;
  justify-content: center;
  padding: 24px;
}
.modal-backdrop.open { display: flex; }

.modal {
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: 16px;
  max-width: 600px;
  width: 100%;
  max-height: 90vh;
  overflow-y: auto;
  box-shadow: 0 24px 80px var(--shadow-lg);
  animation: modalIn 0.2s ease;
}

@keyframes modalIn {
  from { opacity: 0; transform: scale(0.95) translateY(8px); }
  to { opacity: 1; transform: scale(1) translateY(0); }
}

.modal-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 24px 28px 0;
}

.modal-header h2 {
  font-family: var(--font-heading);
  font-size: 22px;
  font-weight: 700;
}

.modal-close {
  background: none;
  border: none;
  cursor: pointer;
  color: var(--text-muted);
  padding: 4px;
  border-radius: 6px;
  transition: color 0.2s, background 0.2s;
  display: flex;
  align-items: center;
  justify-content: center;
}
.modal-close:hover {
  color: var(--text);
  background: var(--surface-hover);
}
.modal-close svg { width: 20px; height: 20px; }

.modal-body { padding: 20px 28px 28px; }

.modal-section { margin-bottom: 24px; }
.modal-section:last-child { margin-bottom: 0; }

.modal-label {
  font-family: var(--font-body);
  font-size: 11px;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.1em;
  color: var(--text-muted);
  margin-bottom: 8px;
  display: block;
}

.modal-input-row { display: flex; gap: 8px; }

.modal-input {
  flex: 1;
  font-family: var(--font-body);
  font-size: 13px;
  padding: 10px 14px;
  border: 1px solid var(--border);
  border-radius: 8px;
  background: var(--bg);
  color: var(--text);
  min-width: 0;
}
.modal-input:focus { outline: none; border-color: var(--accent); }

textarea.modal-input {
  width: 100%;
  resize: vertical;
  min-height: 80px;
  line-height: 1.5;
}

.modal-copy-btn {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  font-family: var(--font-body);
  font-size: 13px;
  font-weight: 600;
  padding: 10px 18px;
  border-radius: 8px;
  border: none;
  background: var(--accent);
  color: #fff;
  cursor: pointer;
  white-space: nowrap;
  transition: background 0.2s;
}
.modal-copy-btn:hover { background: var(--accent-hover); }

.modal-hint {
  font-size: 13px;
  color: var(--text-secondary);
  line-height: 1.6;
  margin-top: 10px;
}

.modal-terms {
  font-size: 12px;
  color: var(--text-muted);
  line-height: 1.7;
  background: var(--bg-alt);
  border-radius: 8px;
  padding: 16px 18px;
}
.modal-terms strong { color: var(--text-secondary); font-weight: 600; }
.modal-terms ul { margin: 8px 0 0; padding-left: 20px; }
.modal-terms li { margin-bottom: 4px; }

/* ============================================
   MESSAGE MODAL
   ============================================ */
.message-modal { max-width: 720px; }

.message-lede {
  font-family: var(--font-heading);
  font-style: italic;
  font-size: 16px;
  color: var(--text-secondary);
  margin-bottom: 24px;
  line-height: 1.7;
}

.message-manifesto {
  font-family: var(--font-body);
  font-size: 15px;
  line-height: 1.8;
  color: var(--text);
  margin-bottom: 24px;
  font-weight: 300;
}
.message-manifesto p { margin-bottom: 16px; }

.message-highlight {
  border-left: 4px solid var(--accent);
  padding: 16px 20px;
  margin: 24px 0;
  background: var(--accent-light);
  border-radius: 0 10px 10px 0;
  font-family: var(--font-heading);
  font-size: 17px;
  font-weight: 600;
  line-height: 1.6;
  color: var(--text);
}

.teaser-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 16px;
  margin: 20px 0 28px;
}

.teaser-card {
  background: var(--bg-alt);
  border: 1px solid var(--border);
  border-radius: 12px;
  padding: 18px;
}

.teaser-badge {
  font-size: 10px;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.1em;
  color: var(--accent);
  margin-bottom: 8px;
}

.teaser-title {
  font-family: var(--font-heading);
  font-size: 15px;
  font-weight: 700;
  margin-bottom: 6px;
}

.teaser-desc {
  font-size: 13px;
  color: var(--text-secondary);
  line-height: 1.5;
  font-weight: 300;
}

.email-capture { margin-top: 24px; text-align: center; }
.email-capture p {
  font-size: 14px;
  color: var(--text-secondary);
  margin-bottom: 12px;
}

.email-capture-row {
  display: flex;
  gap: 8px;
  max-width: 440px;
  margin: 0 auto;
}
.email-capture-row input {
  flex: 1;
  padding: 10px 14px;
  border: 1px solid var(--border);
  border-radius: 8px;
  font-size: 14px;
  background: var(--bg);
  color: var(--text);
  font-family: var(--font-body);
}
.email-capture-row input:focus {
  outline: none;
  border-color: var(--accent);
}
.email-capture-row button {
  padding: 10px 20px;
  background: var(--accent);
  color: #fff;
  border: none;
  border-radius: 8px;
  font-weight: 600;
  font-family: var(--font-body);
  cursor: pointer;
  white-space: nowrap;
  transition: background 0.2s;
}
.email-capture-row button:hover { background: var(--accent-hover); }

.email-capture-success {
  font-size: 14px;
  color: var(--accent);
  font-weight: 600;
}

/* ============================================
   FOOTER — Magazine 3-Column
   ============================================ */
.site-footer {
  border-top: 1px solid var(--border);
  padding: 64px 24px 32px;
  background: var(--bg-alt);
}

.footer-grid {
  max-width: var(--wide-width);
  margin: 0 auto;
  display: grid;
  grid-template-columns: 1.5fr 1fr 1fr;
  gap: 48px;
  margin-bottom: 48px;
}

.footer-brand .nav-logo {
  display: block;
  margin-bottom: 12px;
  font-size: 20px;
}

.footer-brand p {
  color: var(--text-muted);
  font-size: 14px;
  line-height: 1.7;
  font-weight: 300;
  max-width: 320px;
}

.footer-col h4 {
  font-family: var(--font-body);
  font-size: 12px;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.1em;
  color: var(--text-muted);
  margin-bottom: 16px;
}

.footer-col ul {
  list-style: none;
}

.footer-col li {
  margin-bottom: 8px;
}

.footer-col a {
  color: var(--text-secondary);
  font-size: 14px;
  font-weight: 400;
  transition: color 0.2s;
}
.footer-col a:hover { color: var(--accent); }

.footer-bottom {
  max-width: var(--wide-width);
  margin: 0 auto;
  text-align: center;
  padding-top: 24px;
  border-top: 1px solid var(--border);
  color: var(--text-muted);
  font-size: 13px;
}

/* Legacy footer (simple) */
.footer-links {
  display: flex;
  justify-content: center;
  gap: 24px;
  list-style: none;
  margin-bottom: 24px;
  flex-wrap: wrap;
}

.footer-links a {
  color: var(--text-secondary);
  font-size: 13px;
  font-weight: 500;
}
.footer-links a:hover { color: var(--accent); }

/* ============================================
   RESPONSIVE
   ============================================ */

@media (max-width: 1280px) {
  .container { padding: 0 32px; }
  .mag-grid-5 { grid-template-columns: repeat(3, 1fr); }
}

@media (max-width: 1024px) {
  .featured-card { grid-template-columns: 1fr; }
  .featured-card-img { min-height: 240px; }

  .mosaic-grid {
    grid-template-columns: 1fr 1fr;
    grid-template-rows: 220px 220px 220px;
  }
  .mosaic-tall { grid-row: span 2; }
  .mosaic-wide { grid-column: span 1; }

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

  .mag-grid-featured {
    grid-template-columns: 1fr;
    grid-template-rows: auto;
  }
  .mag-grid-featured > :first-child { grid-row: auto; }

  .keynote-layout { grid-template-columns: 1fr; }

  .keynote-toc {
    position: static;
    display: flex;
    gap: 8px;
    overflow-x: auto;
    padding-bottom: 16px;
    border-bottom: 1px solid var(--border);
    margin-bottom: 32px;
  }
  .keynote-toc h3 { display: none; }
  .keynote-toc ul { display: flex; gap: 4px; }
  .keynote-toc a {
    border-left: none;
    border-bottom: 2px solid transparent;
    border-radius: 6px;
    white-space: nowrap;
    padding: 8px 14px;
  }
  .keynote-toc a.active {
    border-left-color: transparent;
    border-bottom-color: var(--accent);
  }

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

@media (max-width: 768px) {
  .hero,
  .topic-hero,
  .keynote-hero {
    min-height: 100vh !important;
    min-height: 100dvh !important;
    justify-content: flex-start;
    padding-top: 80px;
  }

  .chart-preview { height: 340px; }
  .chart-preview iframe { width: 750px; height: 500px; transform: scale(0.45); }
  .chart-card iframe { height: 100vh; }
  .visual-info { padding: 20px 24px; }
  .visual-title { font-size: 20px; }

  .mag-grid-2 { grid-template-columns: 1fr; }
  .mag-grid-5 { grid-template-columns: 1fr 1fr; }

  .topic-hero .topic-stats { flex-wrap: wrap; gap: 16px; }
}

@media (max-width: 640px) {
  :root { --nav-height: 56px; }

  body { font-size: 15px; }

  .nav-links { display: none; }
  .nav-hamburger { display: block; }

  .hero {
    padding: 20px 20px 60px;
  }
  .hero h1 { font-size: 32px; }
  .desktop-break { display: none; }
  .intro-grid { grid-template-columns: 1fr; gap: 32px; }
  .hero-meta { flex-direction: column; gap: 8px; }

  .section { padding: 48px 0; }

  .mag-grid-2, .mag-grid-3, .mag-grid-2x2, .mag-grid-5 {
    grid-template-columns: 1fr;
  }

  .mosaic-grid {
    grid-template-columns: 1fr;
    grid-template-rows: auto;
  }
  .mosaic-tile { min-height: 200px; }
  .mosaic-tall { grid-row: span 1; }
  .mosaic-wide { grid-column: span 1; }

  .mag-grid-featured { grid-template-columns: 1fr; }

  .mag-card-lg { aspect-ratio: 4/3; }

  .featured-card { padding: 0; }
  .featured-content { padding: 24px; }
  .featured-content .card-title { font-size: 22px; }
  .featured-pullquote { font-size: 16px; padding: 24px; }

  .article-hero { min-height: 100vh; min-height: 100dvh; }
  .article-hero-content { padding: 24px; }
  .article-hero-content h1 { font-size: 26px; }

  .article-header { padding: 48px 20px 32px; }
  .article-header h1 { font-size: 28px; }

  .article-body {
    font-size: 16px;
    padding: 0 20px 48px;
  }
  .article-body h2 { font-size: 24px; }
  .article-body blockquote { font-size: 17px; }

  .chart-preview { height: 280px; }
  .chart-preview iframe { width: 640px; height: 440px; transform: scale(0.44); }
  .visuals-gallery { grid-template-columns: repeat(auto-fit, minmax(300px, 1fr)); gap: 20px; padding: 0 16px 48px; }
  .visual-card { border-radius: 12px; }

  .article-nav {
    grid-template-columns: 1fr;
    padding: 0 20px 48px;
  }

  .keynote-body { font-size: 16px; }
  .keynote-body h2 { font-size: 26px; }

  .topic-hero {
    min-height: 100vh;
    min-height: 100svh;
    min-height: -webkit-fill-available;
    padding: 80px 20px 40px;
  }

  .modal { max-height: 85vh; border-radius: 12px; }
  .modal-header { padding: 20px 20px 0; }
  .modal-body { padding: 16px 20px 24px; }
  .modal-input-row { flex-direction: column; }
  .teaser-grid { grid-template-columns: 1fr; }
  .email-capture-row { flex-direction: column; }

  .footer-grid {
    grid-template-columns: 1fr;
    gap: 32px;
  }
}

@media (min-width: 1280px) {
  .container { padding: 0 40px; }
}

/* ============================================
   SHARE BAR — appears on cards, charts, quotes
   ============================================ */
.share-bar {
  position: absolute;
  bottom: 10px;
  right: 10px;
  display: flex;
  gap: 4px;
  opacity: 0;
  transform: translateY(4px);
  transition: opacity 0.25s ease, transform 0.25s ease;
  z-index: 10;
  pointer-events: none;
}

/* Show on hover (desktop) */
.mag-card-sm:hover > .share-bar,
.mag-card-lg:hover > .share-bar,
.opinion-card:hover > .share-bar,
.chart-card:hover > .share-bar,
.featured-card:hover > .share-bar,
.quote-banner:hover > .share-bar,
.share-bar.share-active {
  opacity: 1;
  transform: translateY(0);
  pointer-events: auto;
}

/* Always visible on touch devices */
@media (hover: none) {
  .share-bar {
    opacity: 1;
    transform: translateY(0);
    pointer-events: auto;
  }
}

.share-btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 30px;
  height: 30px;
  border-radius: 50%;
  border: none;
  background: none;
  color: var(--text-muted);
  cursor: pointer;
  transition: all 0.2s ease;
  padding: 0;
}

.share-btn:hover {
  color: var(--text);
}

.share-btn--primary {
  color: var(--text-muted);
}

.share-btn--primary:hover {
  color: var(--text);
}

.share-btn-icon {
  display: flex;
  align-items: center;
  justify-content: center;
  width: 14px;
  height: 14px;
}

.share-btn-icon svg {
  width: 14px;
  height: 14px;
}

/* Quote banner: centre the share bar */
.quote-banner .share-bar {
  bottom: 16px;
  right: 50%;
  transform: translateX(50%) translateY(4px);
}

.quote-banner:hover .share-bar {
  transform: translateX(50%) translateY(0);
}

@media (hover: none) {
  .quote-banner .share-bar {
    transform: translateX(50%) translateY(0);
  }
}

/* Large card overlay: position above overlay text */
.mag-card-lg .share-bar {
  bottom: auto;
  top: 12px;
  right: 12px;
}

/* Sections: inline share row, always visible */
.share-bar-inline {
  position: static !important;
  opacity: 1 !important;
  transform: none !important;
  pointer-events: auto !important;
  margin-top: 12px;
  margin-bottom: 4px;
}

/* ============================================
   SHARE TOAST
   ============================================ */
.share-toast {
  position: fixed;
  bottom: 32px;
  left: 50%;
  transform: translateX(-50%) translateY(20px);
  background: var(--primary);
  color: #fff;
  padding: 10px 24px;
  border-radius: 8px;
  font-family: var(--font-body);
  font-size: 14px;
  font-weight: 500;
  opacity: 0;
  pointer-events: none;
  transition: all 0.3s ease;
  z-index: 9999;
}

.share-toast.show {
  opacity: 1;
  transform: translateX(-50%) translateY(0);
}

/* ============================================
   USAGE MODAL
   ============================================ */
.usage-overlay {
  position: fixed;
  inset: 0;
  background: rgba(0, 0, 0, 0.5);
  display: flex;
  align-items: center;
  justify-content: center;
  z-index: 10000;
  opacity: 0;
  pointer-events: none;
  transition: opacity 0.3s ease;
  padding: 20px;
}

.usage-overlay.visible {
  opacity: 1;
  pointer-events: auto;
}

.usage-modal {
  background: var(--surface);
  border-radius: 16px;
  max-width: 540px;
  width: 100%;
  padding: 36px 32px;
  box-shadow: 0 20px 60px rgba(0, 0, 0, 0.2);
  transform: translateY(20px);
  transition: transform 0.3s ease;
  max-height: 90vh;
  overflow-y: auto;
}

.usage-overlay.visible .usage-modal {
  transform: translateY(0);
}

.usage-modal h2 {
  font-family: var(--font-heading);
  font-size: 24px;
  font-weight: 700;
  color: var(--text);
  margin-bottom: 12px;
}

.usage-modal p {
  font-family: var(--font-body);
  font-size: 15px;
  line-height: 1.7;
  color: var(--text-secondary);
  margin-bottom: 16px;
}

.usage-rules {
  display: flex;
  flex-direction: column;
  gap: 12px;
  margin: 20px 0;
  padding: 20px;
  background: var(--bg-alt);
  border-radius: 10px;
  border: 1px solid var(--border);
}

.usage-rule {
  display: flex;
  flex-direction: column;
  gap: 2px;
}

.usage-rule strong {
  font-family: var(--font-heading);
  font-size: 14px;
  font-weight: 600;
  color: var(--text);
}

.usage-rule span {
  font-family: var(--font-body);
  font-size: 13px;
  color: var(--text-muted);
  line-height: 1.5;
}

.usage-fine {
  font-size: 13px !important;
  color: var(--text-muted) !important;
  font-style: italic;
}

.usage-fine a {
  color: var(--accent);
  text-decoration: underline;
}

.usage-close {
  display: block;
  margin: 20px auto 0;
  padding: 10px 32px;
  border-radius: 24px;
  background: var(--accent);
  color: #fff;
  border: none;
  font-family: var(--font-heading);
  font-size: 14px;
  font-weight: 600;
  cursor: pointer;
  transition: background 0.2s;
}

.usage-close:hover {
  background: var(--accent-hover);
}

/* ============================================
   Subscribe Page
   ============================================ */
.sub-hero {
  padding: 120px 24px 60px;
  text-align: center;
  background: var(--primary);
  color: #fff;
}

[data-theme="dark"] .sub-hero {
  background: #0f1520;
}

.sub-hero-inner {
  max-width: var(--reading-width);
  margin: 0 auto;
}

.sub-hero h1 {
  font-family: var(--font-heading);
  font-size: clamp(2rem, 5vw, 3.2rem);
  font-weight: 800;
  margin-bottom: 16px;
  letter-spacing: -0.02em;
}

.sub-hero-lead {
  font-size: 1.2rem;
  opacity: 0.85;
  line-height: 1.6;
  max-width: 540px;
  margin: 0 auto;
}

.sub-page {
  padding: 48px 24px 80px;
  background: var(--bg);
}

.sub-container {
  max-width: 720px;
  margin: 0 auto;
}

.sub-card {
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: 16px;
  padding: 40px;
  margin-bottom: 48px;
}

.sub-card-primary {
  border-top: 4px solid var(--accent);
}

.sub-card-icon {
  color: var(--accent);
  margin-bottom: 16px;
}

.sub-card h2 {
  font-family: var(--font-heading);
  font-size: 1.6rem;
  font-weight: 700;
  margin-bottom: 12px;
  color: var(--text);
}

.sub-card > p {
  color: var(--text-secondary);
  line-height: 1.6;
  margin-bottom: 28px;
}

.sub-form {
  display: flex;
  flex-direction: column;
  gap: 20px;
}

.sub-form-row {
  display: flex;
  gap: 12px;
}

.sub-form-row input {
  flex: 1;
  padding: 12px 16px;
  border: 1px solid var(--border);
  border-radius: 8px;
  font-family: var(--font-body);
  font-size: 15px;
  background: var(--bg);
  color: var(--text);
  transition: border-color 0.2s;
}

.sub-form-row input:focus {
  outline: none;
  border-color: var(--accent);
}

.sub-topics-label {
  font-family: var(--font-heading);
  font-size: 14px;
  font-weight: 600;
  color: var(--text-secondary);
  margin-bottom: 10px;
}

.sub-topics-grid {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
}

.sub-topic-chip {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  padding: 6px 14px;
  border: 1px solid var(--border);
  border-radius: 20px;
  font-size: 13px;
  color: var(--text-secondary);
  cursor: pointer;
  transition: all 0.2s;
  user-select: none;
}

.sub-topic-chip:hover {
  border-color: var(--accent);
  color: var(--accent);
}

.sub-topic-chip input[type="checkbox"] {
  width: 14px;
  height: 14px;
  accent-color: var(--accent);
}

.sub-topic-chip:has(input:checked) {
  background: var(--accent-light);
  border-color: var(--accent);
  color: var(--accent);
}

.sub-role select {
  width: 100%;
  padding: 12px 16px;
  border: 1px solid var(--border);
  border-radius: 8px;
  font-family: var(--font-body);
  font-size: 15px;
  background: var(--bg);
  color: var(--text);
  cursor: pointer;
}

.sub-role select:focus {
  outline: none;
  border-color: var(--accent);
}

.sub-consent {
  font-size: 13px;
  color: var(--text-muted);
  line-height: 1.5;
}

.sub-consent label {
  display: flex;
  gap: 10px;
  align-items: flex-start;
  cursor: pointer;
}

.sub-consent input[type="checkbox"] {
  margin-top: 3px;
  accent-color: var(--accent);
  flex-shrink: 0;
}

.sub-consent a {
  color: var(--accent);
  text-decoration: underline;
}

.sub-submit-btn {
  width: 100%;
  padding: 14px;
  border: none;
  border-radius: 8px;
  background: var(--accent);
  color: #fff;
  font-family: var(--font-heading);
  font-size: 16px;
  font-weight: 600;
  cursor: pointer;
  transition: background 0.2s;
}

.sub-submit-btn:hover {
  background: var(--accent-hover);
}

.sub-success {
  text-align: center;
  padding: 32px 0;
}

.sub-success-icon {
  color: #22c55e;
  margin-bottom: 16px;
}

.sub-success h3 {
  font-family: var(--font-heading);
  font-size: 1.4rem;
  font-weight: 700;
  color: var(--text);
  margin-bottom: 8px;
}

.sub-success p {
  color: var(--text-secondary);
  margin-bottom: 24px;
}

.sub-back-btn {
  display: inline-block;
  padding: 10px 24px;
  border-radius: 8px;
  background: var(--surface-hover);
  color: var(--text);
  text-decoration: none;
  font-family: var(--font-heading);
  font-size: 14px;
  font-weight: 600;
  transition: background 0.2s;
}

.sub-back-btn:hover {
  background: var(--border);
}

/* Benefits section */
.sub-benefits {
  margin-bottom: 48px;
}

.sub-benefits h2 {
  font-family: var(--font-heading);
  font-size: 1.4rem;
  font-weight: 700;
  color: var(--text);
  margin-bottom: 24px;
  text-align: center;
}

.sub-benefits-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 20px;
}

.sub-benefit {
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: 12px;
  padding: 24px;
  text-align: center;
}

.sub-benefit-icon {
  color: var(--accent);
  margin-bottom: 12px;
}

.sub-benefit h3 {
  font-family: var(--font-heading);
  font-size: 0.95rem;
  font-weight: 600;
  color: var(--text);
  margin-bottom: 8px;
}

.sub-benefit p {
  font-size: 13px;
  color: var(--text-muted);
  line-height: 1.5;
}

.sub-privacy {
  background: var(--bg-alt);
  border: 1px solid var(--border);
  border-radius: 12px;
  padding: 28px;
  text-align: center;
}

.sub-privacy h3 {
  font-family: var(--font-heading);
  font-size: 1rem;
  font-weight: 600;
  color: var(--text);
  margin-bottom: 8px;
}

.sub-privacy p {
  font-size: 14px;
  color: var(--text-secondary);
  line-height: 1.6;
  max-width: 560px;
  margin: 0 auto;
}

/* Hero stats */
.sub-hero-stats {
  display: flex;
  justify-content: center;
  gap: 32px;
  margin-top: 28px;
}

.sub-hero-stat {
  font-size: 14px;
  opacity: 0.7;
}

.sub-hero-stat strong {
  display: block;
  font-size: 1.5rem;
  font-weight: 800;
  opacity: 1;
}

/* Custom dropdowns */
.sub-dropdown {
  position: relative;
}

.sub-dropdown-btn {
  display: flex;
  align-items: center;
  justify-content: space-between;
  width: 100%;
  padding: 12px 16px;
  border: 1px solid var(--border);
  border-radius: 8px;
  background: var(--surface);
  color: var(--text-muted);
  font-family: var(--font-body);
  font-size: 14px;
  cursor: pointer;
  transition: border-color 0.2s, box-shadow 0.2s;
}

.sub-dropdown-btn:hover {
  border-color: var(--text-muted);
}

.sub-dropdown.open .sub-dropdown-btn {
  border-color: var(--accent);
  box-shadow: 0 0 0 3px var(--accent-light);
}

.sub-dd-text.sub-dd-selected {
  color: var(--text);
}

.sub-dd-arrow {
  flex-shrink: 0;
  transition: transform 0.2s;
}

.sub-dropdown.open .sub-dd-arrow {
  transform: rotate(180deg);
}

.sub-dropdown-list {
  display: none;
  position: absolute;
  top: calc(100% + 4px);
  left: 0;
  right: 0;
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: 8px;
  box-shadow: 0 8px 24px var(--shadow-md);
  max-height: 260px;
  overflow-y: auto;
  z-index: 100;
}

.sub-dropdown.open .sub-dropdown-list {
  display: block;
}

.sub-dd-item {
  padding: 10px 16px;
  font-size: 14px;
  color: var(--text-secondary);
  cursor: pointer;
  transition: background 0.15s, color 0.15s;
}

.sub-dd-item:hover {
  background: var(--surface-hover);
  color: var(--text);
}

.sub-dd-item.active {
  background: var(--accent-light);
  color: var(--accent);
  font-weight: 600;
}

/* Section labels */
.sub-section-label {
  font-family: var(--font-heading);
  font-size: 13px;
  font-weight: 600;
  color: var(--text-secondary);
  margin-bottom: 10px;
}

/* Chip checkmark */
.sub-chip-check {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 18px;
  height: 18px;
  border: 2px solid var(--border);
  border-radius: 4px;
  flex-shrink: 0;
  transition: all 0.2s;
}

.sub-topic-chip input:checked ~ .sub-chip-check {
  background: var(--accent);
  border-color: var(--accent);
}

.sub-topic-chip input:checked ~ .sub-chip-check::after {
  content: '';
  width: 5px;
  height: 9px;
  border: solid #fff;
  border-width: 0 2px 2px 0;
  transform: rotate(45deg);
  margin-top: -2px;
}

/* Field labels */
.sub-field {
  display: flex;
  flex-direction: column;
  gap: 6px;
  flex: 1;
}

.sub-field-label {
  font-family: var(--font-heading);
  font-size: 13px;
  font-weight: 600;
  color: var(--text-secondary);
}

/* Enhanced topic chips */
.sub-topic-chip {
  display: flex;
  align-items: center;
  gap: 10px;
  padding: 12px 16px;
  border: 1px solid var(--border);
  border-radius: 12px;
  font-size: 13px;
  color: var(--text-secondary);
  cursor: pointer;
  transition: all 0.2s;
  user-select: none;
}

.sub-topic-chip:hover {
  border-color: var(--accent);
  background: var(--accent-light);
}

.sub-topic-chip input[type="checkbox"] {
  display: none;
}

.sub-chip-icon {
  flex-shrink: 0;
  color: var(--text-muted);
  transition: color 0.2s;
}

.sub-chip-text strong {
  display: block;
  font-size: 14px;
  color: var(--text);
}

.sub-chip-text small {
  color: var(--text-muted);
  font-size: 12px;
}

.sub-topic-chip:has(input:checked) {
  border-color: var(--accent);
  background: var(--accent-light);
}

.sub-topic-chip:has(input:checked) .sub-chip-icon {
  color: var(--accent);
}

.sub-topics-grid {
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  gap: 10px;
}

/* Frequency cards */
.sub-frequency {
  margin-bottom: 4px;
}

.sub-freq-options {
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  gap: 10px;
  margin-top: 10px;
}

.sub-freq-card {
  cursor: pointer;
}

.sub-freq-card input[type="radio"] {
  display: none;
}

.sub-freq-inner {
  display: flex;
  flex-direction: column;
  align-items: center;
  text-align: center;
  gap: 6px;
  padding: 20px 12px;
  border: 2px solid var(--border);
  border-radius: 12px;
  transition: all 0.2s;
}

.sub-freq-inner:hover {
  border-color: var(--accent);
}

.sub-freq-card input:checked + .sub-freq-inner {
  border-color: var(--accent);
  background: var(--accent-light);
}

.sub-freq-icon {
  color: var(--text-muted);
  transition: color 0.2s;
}

.sub-freq-card input:checked + .sub-freq-inner .sub-freq-icon {
  color: var(--accent);
}

.sub-freq-inner strong {
  font-family: var(--font-heading);
  font-size: 14px;
  color: var(--text);
}

.sub-freq-inner small {
  font-size: 12px;
  color: var(--text-muted);
}

/* Extras checkboxes */
.sub-extras {
  margin-bottom: 4px;
}

.sub-extra-check {
  display: flex;
  align-items: center;
  gap: 10px;
  padding: 10px 0;
  font-size: 14px;
  color: var(--text-secondary);
  cursor: pointer;
  border-bottom: 1px solid var(--border-light);
}

.sub-extra-check:last-child {
  border-bottom: none;
}

.sub-extra-check input[type="checkbox"] {
  accent-color: var(--accent);
  width: 16px;
  height: 16px;
}

/* Success summary */
.sub-summary-grid {
  display: flex;
  justify-content: center;
  gap: 24px;
  margin: 20px 0;
  padding: 16px;
  background: var(--bg-alt);
  border-radius: 10px;
}

.sub-summary-item {
  text-align: center;
}

.sub-summary-label {
  display: block;
  font-size: 11px;
  text-transform: uppercase;
  letter-spacing: 0.05em;
  color: var(--text-muted);
  margin-bottom: 4px;
}

.sub-summary-value {
  font-family: var(--font-heading);
  font-size: 14px;
  font-weight: 600;
  color: var(--text);
}

/* Success actions */
.sub-success-actions {
  display: flex;
  gap: 12px;
  justify-content: center;
  margin-top: 20px;
}

.sub-action-btn {
  display: inline-block;
  padding: 10px 24px;
  border-radius: 8px;
  background: var(--surface-hover);
  color: var(--text);
  text-decoration: none;
  font-family: var(--font-heading);
  font-size: 14px;
  font-weight: 600;
  border: 1px solid var(--border);
  cursor: pointer;
  transition: all 0.2s;
}

.sub-action-btn:hover {
  background: var(--border);
}

.sub-action-primary {
  background: var(--accent);
  color: #fff;
  border-color: var(--accent);
}

.sub-action-primary:hover {
  background: var(--accent-hover);
}

.sub-success-change {
  margin-top: 20px;
  font-size: 13px;
  color: var(--text-muted);
}

.sub-success-change a {
  color: var(--accent);
  text-decoration: underline;
}

/* Returning subscriber */
.sub-returning {
  text-align: center;
  padding: 40px 20px;
}

/* Shake animation for validation */
@keyframes sub-shake {
  0%, 100% { transform: translateX(0); }
  20% { transform: translateX(-6px); }
  40% { transform: translateX(6px); }
  60% { transform: translateX(-4px); }
  80% { transform: translateX(4px); }
}

.sub-shake {
  animation: sub-shake 0.4s ease-in-out;
}

/* Nav subscribe button */
.nav-subscribe-btn {
  background: var(--accent) !important;
  color: #fff !important;
  padding: 6px 16px !important;
  border-radius: 6px !important;
  font-size: 13px !important;
  font-weight: 600 !important;
  transition: background 0.2s !important;
}

.nav-subscribe-btn:hover {
  background: var(--accent-hover) !important;
}

/* ============================================
   Site Footer
   ============================================ */
.site-footer {
  margin-top: 64px;
}

.footer-inner {
  max-width: var(--wide-width);
  margin: 0 auto;
  padding: 0 24px;
}

/* Newsletter band */
.footer-newsletter {
  background: var(--primary);
  padding: 40px 24px;
  color: #fff;
}

[data-theme="dark"] .footer-newsletter {
  background: #0f1520;
  border-top: 1px solid rgba(255,255,255,0.08);
}

.footer-newsletter .footer-inner {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 32px;
}

.footer-nl-content h3 {
  font-family: var(--font-heading);
  font-size: 1.3rem;
  font-weight: 700;
  margin-bottom: 6px;
}

.footer-nl-content p {
  font-size: 14px;
  opacity: 0.8;
}

.footer-nl-form {
  display: flex;
  gap: 8px;
  align-items: center;
  flex-shrink: 0;
}

.footer-nl-form input {
  padding: 10px 16px;
  border: 1px solid rgba(255,255,255,0.2);
  border-radius: 6px;
  background: rgba(255,255,255,0.1);
  color: #fff;
  font-family: var(--font-body);
  font-size: 14px;
  width: 260px;
  transition: border-color 0.2s;
}

.footer-nl-form input::placeholder {
  color: rgba(255,255,255,0.5);
}

.footer-nl-form input:focus {
  outline: none;
  border-color: rgba(255,255,255,0.5);
}

.footer-nl-form button {
  padding: 10px 20px;
  border: none;
  border-radius: 6px;
  background: var(--accent);
  color: #fff;
  font-family: var(--font-heading);
  font-size: 14px;
  font-weight: 600;
  cursor: pointer;
  transition: background 0.2s;
  white-space: nowrap;
}

.footer-nl-form button:hover {
  background: var(--accent-hover);
}

.footer-nl-success {
  color: #4ade80;
  font-weight: 600;
  font-size: 14px;
}

/* Main footer */
.footer-main {
  background: var(--bg-alt);
  padding: 48px 24px;
  border-top: 1px solid var(--border);
}

.footer-grid {
  display: grid;
  grid-template-columns: 2fr 1fr 1fr 1fr;
  gap: 40px;
}

.footer-brand .footer-logo {
  font-family: var(--font-heading);
  font-size: 1.1rem;
  font-weight: 700;
  color: var(--text);
  text-decoration: none;
  display: block;
  margin-bottom: 12px;
}

.footer-brand p {
  font-size: 14px;
  color: var(--text-muted);
  line-height: 1.6;
}

.footer-col h4 {
  font-family: var(--font-heading);
  font-size: 13px;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.05em;
  color: var(--text-secondary);
  margin-bottom: 16px;
}

.footer-col a {
  display: block;
  font-size: 14px;
  color: var(--text-muted);
  text-decoration: none;
  padding: 4px 0;
  transition: color 0.2s;
}

.footer-col a:hover {
  color: var(--accent);
}

/* Bottom bar */
.footer-bottom {
  background: var(--bg-alt);
  border-top: 1px solid var(--border);
  padding: 16px 24px;
}

.footer-bottom .footer-inner {
  display: flex;
  justify-content: space-between;
  align-items: center;
  font-size: 13px;
  color: var(--text-muted);
}

.footer-bottom-links {
  display: flex;
  gap: 20px;
}

.footer-bottom-links a {
  color: var(--text-muted);
  text-decoration: none;
  transition: color 0.2s;
}

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

/* Footer responsive */
@media (max-width: 768px) {
  .sub-form-row { flex-direction: column; }
  .sub-benefits-grid { grid-template-columns: 1fr 1fr; }
  .sub-card { padding: 28px 20px; }
  .sub-topics-grid { grid-template-columns: 1fr; }
  .sub-freq-options { grid-template-columns: 1fr 1fr; }
  .sub-hero-stats { gap: 20px; }
  .sub-hero-stat strong { font-size: 1.2rem; }
  .sub-summary-grid { flex-direction: column; gap: 12px; }
  .sub-success-actions { flex-direction: column; }

  .footer-newsletter .footer-inner {
    flex-direction: column;
    text-align: center;
  }
  .footer-nl-form {
    flex-direction: column;
    width: 100%;
  }
  .footer-nl-form input {
    width: 100%;
  }
  .footer-grid {
    grid-template-columns: 1fr 1fr;
    gap: 32px;
  }
  .footer-brand {
    grid-column: 1 / -1;
  }
  .footer-bottom .footer-inner {
    flex-direction: column;
    gap: 8px;
    text-align: center;
  }
}

@media (max-width: 480px) {
  .footer-grid {
    grid-template-columns: 1fr;
  }
  .sub-benefits-grid {
    grid-template-columns: 1fr;
  }
  .sub-freq-options {
    grid-template-columns: 1fr;
  }
  .sub-hero-stats {
    flex-direction: column;
    gap: 12px;
  }
}
