/* ========================================
   SASANKAJYOTI SHARMA — AUTHOR WEBSITE
   Design System & Styles
   ======================================== */

/* ----------------------------------------
   CSS Custom Properties (Design Tokens)
   ---------------------------------------- */
:root {
  /* Colors — Refined Professional Palette */
  --color-primary: #0f1c2e;
  /* Deeper navy — stronger authority */
  --color-primary-light: #1a2d42;
  /* Lighter navy for hover states */
  --color-secondary: #faf8f5;
  /* Warm off-white — refined paper */
  --color-secondary-dark: #f0ebe3;
  /* Warm cream for surfaces */
  --color-accent: #c9a227;
  /* Rich gold — sophistication */
  --color-accent-light: #dbb84a;
  /* Lighter gold for hover */
  --color-accent-dark: #a88b1f;
  /* Darker gold for depth */
  --color-text: #1f2937;
  /* Dark slate — crisp readability */
  --color-text-light: #4b5563;
  /* Medium gray for subtitles */
  --color-text-muted: #9ca3af;
  /* Muted for timestamps */
  --color-white: #ffffff;
  --color-border: #e5e1d8;
  /* Warm subtle border */

  /* Premium Access Colors */
  --color-premium: #7c3aed;
  /* Purple — exclusive */
  --color-premium-light: #a78bfa;
  --color-free: #10b981;
  /* Green — accessible */
  --color-preview: #f59e0b;
  /* Amber — preview */

  /* Background */
  --color-bg: #fdfcfa;
  /* Warm background */

  /* Typography */
  --font-heading: 'Playfair Display', Georgia, 'Times New Roman', serif;
  --font-body: 'Inter', -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, sans-serif;

  /* Font Sizes — Fluid Scale */
  --text-xs: 0.75rem;
  /* 12px */
  --text-sm: 0.875rem;
  /* 14px */
  --text-base: 1rem;
  /* 16px */
  --text-lg: 1.125rem;
  /* 18px */
  --text-xl: 1.25rem;
  /* 20px */
  --text-2xl: 1.5rem;
  /* 24px */
  --text-3xl: 1.875rem;
  /* 30px */
  --text-4xl: 2.25rem;
  /* 36px */
  --text-5xl: 3rem;
  /* 48px */

  /* Line Heights */
  --leading-tight: 1.25;
  --leading-normal: 1.5;
  --leading-relaxed: 1.75;
  --leading-article: 1.8;
  /* Optimal for long-form reading */

  /* Spacing Scale */
  --space-1: 0.25rem;
  /* 4px */
  --space-2: 0.5rem;
  /* 8px */
  --space-3: 0.75rem;
  /* 12px */
  --space-4: 1rem;
  /* 16px */
  --space-5: 1.25rem;
  /* 20px */
  --space-6: 1.5rem;
  /* 24px */
  --space-8: 2rem;
  /* 32px */
  --space-10: 2.5rem;
  /* 40px */
  --space-12: 3rem;
  /* 48px */
  --space-16: 4rem;
  /* 64px */
  --space-20: 5rem;
  /* 80px */
  --space-24: 6rem;
  /* 96px */

  /* Layout */
  --max-width-content: 1200px;
  --max-width-article: 720px;
  /* Optimal reading width */
  --max-width-narrow: 540px;

  /* Borders */
  --radius-sm: 4px;
  --radius-md: 8px;
  --radius-lg: 12px;
  --radius-xl: 16px;

  /* Enhanced Shadows */
  --shadow-sm: 0 1px 2px rgba(15, 28, 46, 0.04);
  --shadow-md: 0 4px 8px rgba(15, 28, 46, 0.06);
  --shadow-lg: 0 12px 24px rgba(15, 28, 46, 0.1);
  --shadow-xl: 0 20px 40px rgba(15, 28, 46, 0.12);
  --shadow-card: 0 2px 8px rgba(15, 28, 46, 0.05);
  --shadow-card-hover: 0 8px 24px rgba(15, 28, 46, 0.12);
  --shadow-glow: 0 0 20px rgba(201, 162, 39, 0.15);

  /* Transitions */
  --transition-fast: 150ms ease;
  --transition-base: 200ms ease;
  --transition-slow: 300ms ease-out;
  --transition-smooth: 400ms cubic-bezier(0.4, 0, 0.2, 1);
}

.reading-progress {
  position: fixed;
  top: 0;
  left: 0;
  height: 3px;
  background-color: var(--color-accent);
  z-index: 1000;
  width: 0%;
  transition: width 100ms ease-out;
}

/* Dark Mode Theme */
[data-theme="dark"] {
  --color-primary: #cbd5e1;
  /* Light slate for primary text in dark mode */
  --color-primary-light: #94a3b8;

  --color-secondary: #0f1c2e;
  /* Deep navy background */
  --color-secondary-dark: #1a2d42;
  /* Lighter navy for surfaces */

  --color-text: #f1f5f9;
  /* Off-white for readability */
  --color-text-light: #cbd5e1;
  --color-text-muted: #94a3b8;

  --color-bg: #0b1421;
  /* Very dark navy for main background */
  --color-white: #1a2d42;
  /* Card background in dark mode */
  --color-border: #2d3f56;
  /* Dark mode border */

  --shadow-sm: 0 1px 2px rgba(0, 0, 0, 0.3);
  --shadow-md: 0 4px 8px rgba(0, 0, 0, 0.4);
  --shadow-lg: 0 12px 24px rgba(0, 0, 0, 0.5);
  --shadow-xl: 0 20px 40px rgba(0, 0, 0, 0.6);
  /* Dark Mode Specific Overrides for Premium Components */

  /* Keep Content Gate Dark & Gold even in Dark Mode */
  .content-gate-box {
    background: linear-gradient(135deg, #0f1c2e 0%, #1a2d42 100%);
    color: #ffffff;
    box-shadow: 0 20px 40px rgba(0, 0, 0, 0.6);
  }

  .content-gate-box h3,
  .content-gate-box p,
  .content-gate-benefits span {
    color: #ffffff;
    /* Force white text */
  }

  .content-gate-price {
    color: #c9a227;
    /* Force gold price */
  }

  .content-gate-price span {
    color: rgba(255, 255, 255, 0.7);
  }

  /* Purchase Modal - Keep it clean */
  .modal-content {
    background: #1a2d42;
    /* Dark card background */
    border: 1px solid #2d3f56;
  }

  .modal-header h2,
  .modal-body h4 {
    color: #f1f5f9;
  }

  .modal-body p,
  .modal-body label {
    color: #cbd5e1;
  }

  .payment-option {
    background: #0f1c2e;
    border-color: #2d3f56;
  }

  .payment-option:hover {
    border-color: #94a3b8;
  }

  .payment-option.selected {
    background: rgba(201, 162, 39, 0.15);
    border-color: #c9a227;
  }

  .payment-option-info h4 {
    color: #f1f5f9;
  }

  .payment-option-info p {
    color: #94a3b8;
  }

  input[type="email"],
  input[type="text"] {
    background: #0f1c2e;
    border-color: #2d3f56;
    color: #f1f5f9;
  }

  input:focus {
    border-color: #c9a227;
  }
}

/* ----------------------------------------
   CSS Reset & Base Styles
   ---------------------------------------- */
*,
*::before,
*::after {
  box-sizing: border-box;
  margin: 0;
  padding: 0;
}

html {
  font-size: 16px;
  scroll-behavior: smooth;
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
}

body {
  font-family: var(--font-body);
  font-size: var(--text-base);
  line-height: var(--leading-normal);
  color: var(--color-text);
  background-color: var(--color-secondary);
  min-height: 100vh;
}

img {
  max-width: 100%;
  height: auto;
  display: block;
}

a {
  color: inherit;
  text-decoration: none;
}

button {
  font-family: inherit;
  cursor: pointer;
  border: none;
  background: none;
}

ul,
ol {
  list-style: none;
}

/* ----------------------------------------
   Typography
   ---------------------------------------- */
h1,
h2,
h3,
h4,
h5,
h6 {
  font-family: var(--font-heading);
  font-weight: 600;
  line-height: var(--leading-tight);
  color: var(--color-primary);
}

h1 {
  font-size: var(--text-5xl);
  font-weight: 700;
}

h2 {
  font-size: var(--text-4xl);
}

h3 {
  font-size: var(--text-3xl);
}

h4 {
  font-size: var(--text-2xl);
}

h5 {
  font-size: var(--text-xl);
}

h6 {
  font-size: var(--text-lg);
}

p {
  margin-bottom: var(--space-4);
}

.lead {
  font-size: var(--text-xl);
  line-height: var(--leading-relaxed);
  color: var(--color-text-light);
}

.text-muted {
  color: var(--color-text-muted);
}

.text-accent {
  color: var(--color-accent);
}

/* ----------------------------------------
   Layout Utilities
   ---------------------------------------- */
.container {
  width: 100%;
  max-width: var(--max-width-content);
  margin: 0 auto;
  padding: 0 var(--space-6);
}

.container-narrow {
  max-width: var(--max-width-article);
}

.section {
  padding: var(--space-16) 0;
}

.section-sm {
  padding: var(--space-10) 0;
}

/* ----------------------------------------
   Header & Navigation
   ---------------------------------------- */
.header {
  background-color: var(--color-white);
  border-bottom: 1px solid var(--color-border);
  position: sticky;
  top: 0;
  z-index: 100;
}

.header-inner {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: var(--space-4) var(--space-6);
  max-width: var(--max-width-content);
  margin: 0 auto;
}

.logo {
  font-family: var(--font-heading);
  font-size: var(--text-xl);
  font-weight: 600;
  color: var(--color-primary);
  transition: color var(--transition-base);
}

.logo:hover {
  color: var(--color-accent);
}

.nav {
  display: flex;
  align-items: center;
  gap: var(--space-8);
}

.nav-link {
  font-size: var(--text-sm);
  font-weight: 500;
  color: var(--color-text-light);
  position: relative;
  padding: var(--space-2) 0;
  transition: color var(--transition-base);
}

.nav-link::after {
  content: '';
  position: absolute;
  bottom: 0;
  left: 0;
  width: 0;
  height: 2px;
  background-color: var(--color-accent);
  transition: width var(--transition-base);
}

.nav-link:hover,
.nav-link.active {
  color: var(--color-primary);
}

.nav-link:hover::after,
.nav-link.active::after {
  width: 100%;
}

/* Mobile Navigation Toggle */
.nav-toggle {
  display: none;
  flex-direction: column;
  gap: 5px;
  padding: var(--space-2);
}

.nav-toggle span {
  display: block;
  width: 24px;
  height: 2px;
  background-color: var(--color-primary);
  transition: all var(--transition-base);
}

/* ----------------------------------------
   Hero Section
   ---------------------------------------- */
.hero {
  padding: var(--space-24) 0;
  text-align: center;
  background: linear-gradient(180deg, var(--color-white) 0%, var(--color-secondary) 100%);
}

.hero-content {
  max-width: 800px;
  margin: 0 auto;
}

.hero-title {
  font-size: clamp(2.5rem, 5vw, 3.5rem);
  margin-bottom: var(--space-6);
  animation: fadeInUp 0.6s ease-out;
}

.hero-subtitle {
  font-size: var(--text-xl);
  color: var(--color-text-light);
  margin-bottom: var(--space-8);
  animation: fadeInUp 0.6s ease-out 0.1s both;
}

.hero-tagline {
  display: inline-block;
  font-size: var(--text-sm);
  font-weight: 500;
  color: var(--color-accent);
  text-transform: uppercase;
  letter-spacing: 2px;
  margin-bottom: var(--space-4);
  animation: fadeInUp 0.6s ease-out 0.05s both;
}

/* ----------------------------------------
   Buttons
   ---------------------------------------- */
.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  padding: var(--space-3) var(--space-6);
  font-size: var(--text-sm);
  font-weight: 500;
  border-radius: var(--radius-md);
  transition: all var(--transition-base);
}

.btn-primary {
  background-color: var(--color-primary);
  color: var(--color-white);
}

.btn-primary:hover {
  background-color: var(--color-primary-light);
  transform: translateY(-1px);
}

.btn-outline {
  border: 1px solid var(--color-border);
  color: var(--color-text);
  background-color: transparent;
}

.btn-outline:hover {
  border-color: var(--color-primary);
  color: var(--color-primary);
}

.btn-accent {
  background-color: var(--color-accent);
  color: var(--color-white);
}

.btn-accent:hover {
  background-color: var(--color-accent-light);
}

/* ----------------------------------------
   Article Cards
   ---------------------------------------- */
.articles-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(340px, 1fr));
  gap: var(--space-8);
}

/* Compact Grid for "More Articles" */
.articles-grid.compact {
  grid-template-columns: repeat(auto-fill, minmax(260px, 1fr));
  gap: var(--space-6);
}

.articles-grid.compact .article-card {
  padding: var(--space-5);
}

.articles-grid.compact .article-card-title {
  font-size: var(--text-lg);
}

.article-card {
  background-color: var(--color-white);
  border-radius: var(--radius-lg);
  padding: var(--space-8);
  box-shadow: var(--shadow-card);
  transition: all var(--transition-slow);
  border: 1px solid transparent;
}

.article-card:hover {
  box-shadow: var(--shadow-card-hover);
  transform: translateY(-2px);
  border-color: var(--color-border);
}

.article-card-category {
  font-size: var(--text-xs);
  font-weight: 600;
  text-transform: uppercase;
  letter-spacing: 1px;
  color: var(--color-accent);
  margin-bottom: var(--space-3);
}

.article-card-title {
  font-size: var(--text-xl);
  margin-bottom: var(--space-3);
  transition: color var(--transition-base);
}

.article-card:hover .article-card-title {
  color: var(--color-accent);
}

.article-card-excerpt {
  font-size: var(--text-sm);
  color: var(--color-text-light);
  line-height: var(--leading-relaxed);
  margin-bottom: var(--space-4);
}

.article-card-meta {
  display: flex;
  align-items: center;
  gap: var(--space-4);
  font-size: var(--text-xs);
  color: var(--color-text-muted);
}

.article-card-meta span {
  display: flex;
  align-items: center;
  gap: var(--space-1);
}

/* ----------------------------------------
   Article Content (Single Article Page)
   ---------------------------------------- */
.article-header {
  text-align: center;
  padding: var(--space-16) 0 var(--space-10);
  background: linear-gradient(180deg, var(--color-white) 0%, var(--color-secondary) 100%);
}

.article-category {
  font-size: var(--text-sm);
  font-weight: 600;
  text-transform: uppercase;
  letter-spacing: 2px;
  color: var(--color-accent);
  margin-bottom: var(--space-4);
}

.article-title {
  font-size: clamp(2rem, 4vw, 2.75rem);
  max-width: 900px;
  margin: 0 auto var(--space-6);
}

.article-meta {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: var(--space-6);
  color: var(--color-text-muted);
  font-size: var(--text-sm);
}

.article-meta-divider {
  width: 4px;
  height: 4px;
  border-radius: 50%;
  background-color: var(--color-text-muted);
}

.article-content {
  max-width: var(--max-width-article);
  margin: 0 auto;
  padding: var(--space-10) var(--space-6);
}

.article-content p {
  font-size: var(--text-lg);
  line-height: var(--leading-article);
  margin-bottom: var(--space-6);
}

.article-content h2 {
  font-size: var(--text-2xl);
  margin: var(--space-12) 0 var(--space-6);
}

.article-content h3 {
  font-size: var(--text-xl);
  margin: var(--space-10) 0 var(--space-4);
}

.article-content blockquote {
  border-left: 3px solid var(--color-accent);
  padding-left: var(--space-6);
  margin: var(--space-8) 0;
  font-style: italic;
  color: var(--color-text-light);
}

.article-content ul,
.article-content ol {
  margin: var(--space-6) 0;
  padding-left: var(--space-6);
}

.article-content li {
  margin-bottom: var(--space-2);
  line-height: var(--leading-relaxed);
}

.article-content ul li {
  list-style: disc;
}

.article-content ol li {
  list-style: decimal;
}

.article-content a {
  color: var(--color-accent);
  text-decoration: underline;
  text-decoration-thickness: 1px;
  text-underline-offset: 2px;
  transition: color var(--transition-base);
}

.article-content a:hover {
  color: var(--color-primary);
  text-decoration-thickness: 2px;
}

/* ----------------------------------------
   Author Card
   ---------------------------------------- */
.author-card {
  display: flex;
  align-items: flex-start;
  gap: var(--space-6);
  padding: var(--space-8);
  background-color: var(--color-white);
  border-radius: var(--radius-lg);
  border: 1px solid var(--color-border);
  margin: var(--space-12) 0;
}

.author-avatar {
  width: 80px;
  height: 80px;
  border-radius: 50%;
  background-color: var(--color-primary);
  display: flex;
  align-items: center;
  justify-content: center;
  color: var(--color-white);
  font-family: var(--font-heading);
  font-size: var(--text-2xl);
  font-weight: 600;
  flex-shrink: 0;
}

.author-info h4 {
  margin-bottom: var(--space-2);
}

.author-info p {
  font-size: var(--text-sm);
  color: var(--color-text-light);
  margin-bottom: 0;
}

/* ----------------------------------------
   About Page
/* ----------------------------------------
   About Page Hero (Landscape)
   ---------------------------------------- */
.about-hero {
  position: relative;
  height: 60vh;
  min-height: 600px;
  background-image: url('../assets/author-image-landscape.jpg');
  background-size: cover;
  background-position: center;
  background-repeat: no-repeat;
  display: flex;
  align-items: flex-end;
  justify-content: center;
  text-align: center;
  color: var(--color-white);
  margin-bottom: var(--space-12);
  border-bottom: 5px solid var(--color-accent);
}

/* Dark gradient overlay for text readability */
.about-hero::before {
  content: '';
  position: absolute;
  top: 0;
  left: 0;
  right: 0;
  bottom: 0;
  background: linear-gradient(to top, rgba(15, 28, 46, 0.95) 0%, rgba(15, 28, 46, 0.4) 50%, rgba(15, 28, 46, 0.2) 100%);
}

.about-hero-content {
  position: relative;
  z-index: 2;
  padding-bottom: var(--space-12);
  width: 100%;
  max-width: var(--max-width-content);
  margin: 0 auto;
  padding-left: var(--space-6);
  padding-right: var(--space-6);
}

.about-hero h1 {
  color: #F5F7FA;
  margin-bottom: var(--space-3);
  text-shadow: 0 4px 6px rgba(0, 0, 0, 0.3);
  font-size: clamp(2.5rem, 5vw, 4rem);
}

.about-hero .lead {
  color: rgba(255, 255, 255, 0.9);
  font-size: var(--text-xl);
  max-width: 700px;
  margin: 0 auto;
  text-shadow: 0 2px 4px rgba(0, 0, 0, 0.3);
  font-weight: 500;
  letter-spacing: 0.5px;
}

/* Legacy styles kept just in case, but unused in new design */
.about-avatar {
  width: 160px;
  height: 160px;
  border-radius: 50%;
  background-color: var(--color-primary);
  display: flex;
  align-items: center;
  justify-content: center;
  color: var(--color-white);
  font-family: var(--font-heading);
  font-size: var(--text-5xl);
  font-weight: 600;
  margin: 0 auto var(--space-8);
}

.about-content {
  max-width: var(--max-width-article);
  margin: 0 auto;
  padding: 0 var(--space-6) var(--space-10);
}

.about-content p {
  font-size: var(--text-lg);
  line-height: var(--leading-article);
  margin-bottom: var(--space-6);
}

.about-section {
  margin-bottom: var(--space-12);
}

.about-section h2 {
  font-size: var(--text-2xl);
  margin-bottom: var(--space-6);
  padding-bottom: var(--space-3);
  border-bottom: 2px solid var(--color-accent);
  display: inline-block;
}

/* ----------------------------------------
   Contact Page
   ---------------------------------------- */
.contact-container {
  max-width: 600px;
  margin: 0 auto;
  padding: var(--space-16) var(--space-6);
}

.contact-header {
  text-align: center;
  margin-bottom: var(--space-10);
}

.contact-header h1 {
  margin-bottom: var(--space-4);
}

.contact-header p {
  color: var(--color-text-light);
}

.contact-form {
  background-color: var(--color-white);
  padding: var(--space-10);
  border-radius: var(--radius-lg);
  box-shadow: var(--shadow-md);
}

.form-group {
  margin-bottom: var(--space-6);
}

.form-label {
  display: block;
  font-size: var(--text-sm);
  font-weight: 500;
  color: var(--color-text);
  margin-bottom: var(--space-2);
}

.form-input,
.form-textarea {
  width: 100%;
  padding: var(--space-3) var(--space-4);
  font-family: var(--font-body);
  font-size: var(--text-base);
  color: var(--color-text);
  background-color: var(--color-secondary);
  border: 1px solid var(--color-border);
  border-radius: var(--radius-md);
  transition: all var(--transition-base);
}

.form-input:focus,
.form-textarea:focus {
  outline: none;
  border-color: var(--color-primary);
  background-color: var(--color-white);
  box-shadow: 0 0 0 3px rgba(26, 38, 57, 0.1);
}

.form-textarea {
  min-height: 150px;
  resize: vertical;
}

.form-submit {
  width: 100%;
  padding: var(--space-4);
  font-size: var(--text-base);
}

/* ----------------------------------------
   Footer
   ---------------------------------------- */
.footer {
  background-color: var(--color-primary);
  color: var(--color-white);
  padding: var(--space-16) 0 var(--space-8);
}

.footer-inner {
  max-width: var(--max-width-content);
  margin: 0 auto;
  padding: 0 var(--space-6);
}

.footer-main {
  display: grid;
  grid-template-columns: 2fr 1fr 1fr;
  gap: var(--space-12);
  padding-bottom: var(--space-10);
  border-bottom: 1px solid rgba(255, 255, 255, 0.1);
}

.footer-brand h3 {
  font-family: var(--font-heading);
  font-size: var(--text-xl);
  color: var(--color-white);
  margin-bottom: var(--space-4);
}

.footer-brand p {
  font-size: var(--text-sm);
  color: rgba(255, 255, 255, 0.7);
  line-height: var(--leading-relaxed);
  max-width: 300px;
}

.footer-nav h4 {
  font-family: var(--font-body);
  font-size: var(--text-sm);
  font-weight: 600;
  text-transform: uppercase;
  letter-spacing: 1px;
  color: var(--color-white);
  margin-bottom: var(--space-4);
}

.footer-nav ul {
  display: flex;
  flex-direction: column;
  gap: var(--space-3);
}

.footer-nav a {
  font-size: var(--text-sm);
  color: rgba(255, 255, 255, 0.7);
  transition: color var(--transition-base);
}

.footer-nav a:hover {
  color: var(--color-white);
}

.footer-bottom {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding-top: var(--space-8);
}

.footer-copyright {
  font-size: var(--text-sm);
  color: rgba(255, 255, 255, 0.5);
}

/* ----------------------------------------
   Section Headers
   ---------------------------------------- */
.section-header {
  text-align: center;
  margin-bottom: var(--space-12);
}

.section-header h2 {
  margin-bottom: var(--space-4);
}

.section-header p {
  color: var(--color-text-light);
  max-width: 600px;
  margin: 0 auto;
}

/* ----------------------------------------
   Category Filter
   ---------------------------------------- */
.category-filter {
  display: flex;
  justify-content: center;
  gap: var(--space-2);
  margin-bottom: var(--space-10);
  flex-wrap: wrap;
}

.category-btn {
  padding: var(--space-2) var(--space-5);
  font-size: var(--text-sm);
  font-weight: 500;
  color: var(--color-text-light);
  background-color: transparent;
  border: 1px solid var(--color-border);
  border-radius: 50px;
  transition: all var(--transition-base);
}

.category-btn:hover,
.category-btn.active {
  background-color: var(--color-primary);
  border-color: var(--color-primary);
  color: var(--color-white);
}

/* ----------------------------------------
   Animations
   ---------------------------------------- */
@keyframes fadeIn {
  from {
    opacity: 0;
  }

  to {
    opacity: 1;
  }
}

@keyframes fadeInUp {
  from {
    opacity: 0;
    transform: translateY(20px);
  }

  to {
    opacity: 1;
    transform: translateY(0);
  }
}

.fade-in {
  animation: fadeIn var(--transition-slow) ease-out;
}

.fade-in-up {
  animation: fadeInUp var(--transition-slow) ease-out;
}

/* Scroll-triggered animations */
.animate-on-scroll {
  opacity: 0;
  transform: translateY(20px);
  transition: all 0.5s ease-out;
}

.animate-on-scroll.visible {
  opacity: 1;
  transform: translateY(0);
}

/* ----------------------------------------
   Responsive Design
   ---------------------------------------- */

/* Tablets and below */
@media (max-width: 1024px) {
  .footer-main {
    grid-template-columns: 1fr 1fr;
    gap: var(--space-8);
  }

  .footer-brand {
    grid-column: 1 / -1;
  }
}

/* Mobile and small tablets */
@media (max-width: 768px) {
  :root {
    --text-5xl: 2.5rem;
    --text-4xl: 2rem;
    --text-3xl: 1.5rem;
  }

  /* Mobile Header Tweaks (User Request) */
  .logo img {
    height: 48px !important;
    /* Slightly larger logo/name (overrides inline 40px) */
    width: auto;
  }

  .auth-btn-container .btn {
    padding: 6px 12px !important;
    /* Smaller button */
    font-size: 13px !important;
    height: auto;
    min-height: 32px;
  }

  .nav {
    position: fixed;
    top: 60px;
    left: 0;
    right: 0;
    background-color: var(--color-white);
    flex-direction: column;
    padding: var(--space-6);
    gap: var(--space-4);
    border-bottom: 1px solid var(--color-border);
    transform: translateY(-100%);
    opacity: 0;
    visibility: hidden;
    transition: all var(--transition-slow);
  }

  .nav.active {
    transform: translateY(0);
    opacity: 1;
    visibility: visible;
  }

  .nav-toggle {
    display: flex;
  }

  .hero {
    padding: var(--space-16) 0;
  }

  .section {
    padding: var(--space-12) 0;
  }

  .articles-grid {
    grid-template-columns: 1fr;
  }

  .author-card {
    flex-direction: column;
    text-align: center;
    align-items: center;
  }

  .footer-main {
    grid-template-columns: 1fr;
    gap: var(--space-8);
    text-align: center;
  }

  .footer-brand p {
    max-width: none;
  }

  .footer-bottom {
    flex-direction: column;
    gap: var(--space-4);
    text-align: center;
  }

  /* Newsletter mobile */
  .newsletter-form {
    flex-direction: column;
    gap: var(--space-3);
  }

  .newsletter-form input[type="email"] {
    min-width: 100%;
  }

  .newsletter-form button {
    width: 100%;
  }

  /* Share buttons mobile */
  .share-buttons {
    flex-wrap: wrap;
    justify-content: center;
  }

  .share-buttons .btn {
    margin-left: 0 !important;
    margin-top: var(--space-3);
    width: 100%;
  }

  /* Credentials mobile */
  .credentials {
    justify-content: center;
  }

  .credential-badge {
    font-size: var(--text-xs);
    padding: var(--space-1) var(--space-3);
  }

  /* Social proof mobile */
  .social-proof-logos {
    flex-direction: column;
    gap: var(--space-4);
  }

  /* Author photo mobile */
  .author-photo-hero {
    width: 120px;
    height: 120px;
  }

  /* TOC mobile */
  .toc {
    padding: var(--space-4);
  }

  /* Legal content mobile */
  .legal-content {
    padding: var(--space-6) var(--space-4);
  }

  .legal-content h1 {
    font-size: var(--text-2xl);
  }

  .legal-content h2 {
    font-size: var(--text-lg);
  }
}

/* Small phones */
@media (max-width: 480px) {
  .container {
    padding: 0 var(--space-4);
  }

  .article-card {
    padding: var(--space-6);
  }

  .contact-form {
    padding: var(--space-6);
  }

  .about-avatar {
    width: 120px;
    height: 120px;
    font-size: var(--text-4xl);
  }

  /* Hero mobile */
  .hero-content {
    padding: 0 var(--space-2);
  }

  .hero-title {
    font-size: var(--text-3xl);
  }

  /* Newsletter section small */
  .newsletter-section {
    padding: var(--space-8) var(--space-4);
  }

  .newsletter-section h3 {
    font-size: var(--text-xl);
  }

  /* Share buttons small */
  .share-btn {
    width: 36px;
    height: 36px;
  }

  /* Inline newsletter small */
  .newsletter-inline {
    padding: var(--space-6);
  }

  .newsletter-inline .newsletter-form {
    flex-direction: column;
  }

  /* Author photo small */
  .author-photo-hero {
    width: 100px;
    height: 100px;
  }

  .author-photo-small {
    width: 60px;
    height: 60px;
  }

  /* Credential badges small */
  .credentials {
    gap: var(--space-2);
  }

  .credential-badge {
    font-size: 10px;
    padding: var(--space-1) var(--space-2);
  }
}

/* ----------------------------------------
   Utility Classes
   ---------------------------------------- */
.text-center {
  text-align: center;
}

.mt-4 {
  margin-top: var(--space-4);
}

.mt-6 {
  margin-top: var(--space-6);
}

.mt-8 {
  margin-top: var(--space-8);
}

.mb-4 {
  margin-bottom: var(--space-4);
}

.mb-6 {
  margin-bottom: var(--space-6);
}

.mb-8 {
  margin-bottom: var(--space-8);
}

.hidden {
  display: none !important;
}

.sr-only {
  position: absolute;
  width: 1px;
  height: 1px;
  padding: 0;
  margin: -1px;
  overflow: hidden;
  clip: rect(0, 0, 0, 0);
  white-space: nowrap;
  border: 0;
}

/* ----------------------------------------
   Newsletter Component
   ---------------------------------------- */
.newsletter-section {
  background: linear-gradient(135deg, var(--color-primary) 0%, var(--color-primary-light) 100%);
  padding: var(--space-12) 0;
  text-align: center;
}

.newsletter-section h3 {
  color: var(--color-white);
  font-size: var(--text-2xl);
  margin-bottom: var(--space-3);
}

.newsletter-section p {
  color: rgba(255, 255, 255, 0.8);
  margin-bottom: var(--space-6);
}

.newsletter-form {
  display: flex;
  gap: var(--space-3);
  max-width: 500px;
  margin: 0 auto;
  flex-wrap: wrap;
  justify-content: center;
}

.newsletter-form input[type="email"] {
  flex: 1;
  min-width: 250px;
  padding: var(--space-3) var(--space-4);
  border: none;
  border-radius: var(--radius-md);
  font-size: var(--text-base);
}

.newsletter-form button {
  padding: var(--space-3) var(--space-6);
  background-color: var(--color-accent);
  color: var(--color-white);
  border: none;
  border-radius: var(--radius-md);
  font-weight: 500;
  cursor: pointer;
  transition: background-color var(--transition-base);
}

.newsletter-form button:hover {
  background-color: var(--color-accent-light);
}

.newsletter-message {
  margin-top: var(--space-4);
  font-size: var(--text-sm);
  color: var(--color-white);
}

.newsletter-message.success {
  color: #4ade80;
}

/* Inline Newsletter (for article pages) */
.newsletter-inline {
  background-color: var(--color-white);
  border: 1px solid var(--color-border);
  border-radius: var(--radius-lg);
  padding: var(--space-8);
  text-align: center;
  margin: var(--space-10) 0;
}

.newsletter-inline h4 {
  margin-bottom: var(--space-2);
}

.newsletter-inline p {
  color: var(--color-text-light);
  font-size: var(--text-sm);
  margin-bottom: var(--space-4);
}

/* ----------------------------------------
   Social Share Buttons
   ---------------------------------------- */
.share-buttons {
  display: flex;
  align-items: center;
  gap: var(--space-3);
  margin: var(--space-8) 0;
  padding: var(--space-4) 0;
  border-top: 1px solid var(--color-border);
  border-bottom: 1px solid var(--color-border);
}

.share-label {
  font-size: var(--text-sm);
  font-weight: 500;
  color: var(--color-text-muted);
}

.share-btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 40px;
  height: 40px;
  border-radius: 50%;
  background-color: var(--color-secondary);
  color: var(--color-text);
  font-size: var(--text-sm);
  transition: all var(--transition-base);
  text-decoration: none;
}

.share-btn:hover {
  background-color: var(--color-primary);
  color: var(--color-white);
  transform: translateY(-2px);
}

.share-btn.twitter:hover {
  background-color: #1da1f2;
}

.share-btn.linkedin:hover {
  background-color: #0077b5;
}

.share-btn.facebook:hover {
  background-color: #1877f2;
}

.share-btn.whatsapp:hover {
  background-color: #25d366;
}

.share-btn.copy:hover {
  background-color: var(--color-accent);
}

/* ----------------------------------------
   Table of Contents
   ---------------------------------------- */
.toc {
  background-color: var(--color-white);
  border: 1px solid var(--color-border);
  border-radius: var(--radius-lg);
  padding: var(--space-6);
  margin-bottom: var(--space-10);
}

.toc-title {
  font-size: var(--text-sm);
  font-weight: 600;
  text-transform: uppercase;
  letter-spacing: 1px;
  color: var(--color-text-muted);
  margin-bottom: var(--space-4);
}

.toc-list {
  list-style: none;
}

.toc-list li {
  padding: var(--space-2) 0;
  border-bottom: 1px solid var(--color-border);
}

.toc-list li:last-child {
  border-bottom: none;
}

.toc-list a {
  color: var(--color-text);
  font-size: var(--text-sm);
  transition: color var(--transition-base);
}

.toc-list a:hover {
  color: var(--color-accent);
}

/* ----------------------------------------
   Credentials & Social Proof
   ---------------------------------------- */
.credentials {
  display: flex;
  flex-wrap: wrap;
  gap: var(--space-3);
  margin-top: var(--space-4);
}

.credential-badge {
  display: inline-flex;
  align-items: center;
  gap: var(--space-2);
  padding: var(--space-2) var(--space-4);
  background-color: var(--color-secondary);
  border-radius: 50px;
  font-size: var(--text-xs);
  font-weight: 500;
  color: var(--color-text);
}

.credential-badge svg {
  width: 14px;
  height: 14px;
}

.social-proof {
  background-color: var(--color-white);
  padding: var(--space-10) 0;
  border-top: 1px solid var(--color-border);
  border-bottom: 1px solid var(--color-border);
}

.social-proof-title {
  text-align: center;
  font-size: var(--text-sm);
  text-transform: uppercase;
  letter-spacing: 2px;
  color: var(--color-text-muted);
  margin-bottom: var(--space-6);
}

.social-proof-logos {
  display: flex;
  justify-content: center;
  align-items: center;
  gap: var(--space-10);
  flex-wrap: wrap;
  opacity: 0.6;
}

.social-proof-logos span {
  font-family: var(--font-heading);
  font-size: var(--text-lg);
  color: var(--color-text-muted);
}

/* ----------------------------------------
   Author Photo
   ---------------------------------------- */
.author-photo {
  width: 180px;
  height: 180px;
  border-radius: 50%;
  object-fit: cover;
  border: 4px solid var(--color-white);
  box-shadow: var(--shadow-lg);
}

.author-photo-hero {
  width: 150px;
  height: 150px;
  margin: 0 auto var(--space-6);
}

.author-photo-small {
  width: 80px;
  height: 80px;
}

/* ----------------------------------------
   Enhanced Hero
   ---------------------------------------- */
.hero-enhanced {
  position: relative;
  overflow: hidden;
}

.hero-enhanced::before {
  content: '';
  position: absolute;
  top: -50%;
  right: -20%;
  width: 600px;
  height: 600px;
  background: radial-gradient(circle, rgba(184, 134, 11, 0.08) 0%, transparent 70%);
  pointer-events: none;
}

.hero-enhanced::after {
  content: '';
  position: absolute;
  bottom: -30%;
  left: -10%;
  width: 400px;
  height: 400px;
  background: radial-gradient(circle, rgba(26, 38, 57, 0.05) 0%, transparent 70%);
  pointer-events: none;
}

/* ----------------------------------------
   Legal Pages (Disclaimer, Privacy, Terms)
   ---------------------------------------- */
.legal-content {
  max-width: var(--max-width-article);
  margin: 0 auto;
  padding: var(--space-10) var(--space-6);
}

.legal-content h1 {
  margin-bottom: var(--space-8);
  text-align: center;
}

.legal-content h2 {
  font-size: var(--text-xl);
  margin: var(--space-8) 0 var(--space-4);
}

.legal-content p {
  font-size: var(--text-base);
  line-height: var(--leading-relaxed);
  margin-bottom: var(--space-4);
}

.legal-content ul {
  margin: var(--space-4) 0;
  padding-left: var(--space-6);
}

.legal-content li {
  list-style: disc;
  margin-bottom: var(--space-2);
  line-height: var(--leading-relaxed);
}

.legal-meta {
  font-size: var(--text-sm);
  color: var(--color-text-muted);
  text-align: center;
  margin-bottom: var(--space-8);
}

/* ----------------------------------------
   Print Styles
   ---------------------------------------- */
@media print {

  /* Hide non-essential elements */
  .header,
  .footer,
  .nav,
  .nav-toggle,
  .share-buttons,
  .newsletter-section,
  .newsletter-inline,
  .toc,
  .btn,
  .reading-progress {
    display: none !important;
  }

  /* Reset backgrounds */
  body {
    background: white;
    color: black;
  }

  /* Article content */
  .article-content {
    max-width: 100%;
    padding: 0;
  }

  .article-content p {
    font-size: 12pt;
    line-height: 1.6;
  }

  .article-header {
    background: none;
    padding: 20pt 0;
  }

  .article-title {
    font-size: 24pt;
  }

  /* Links */
  a {
    color: black;
    text-decoration: underline;
  }

  /* Add URL after links */
  .article-content a::after {
    content: " (" attr(href) ")";
    font-size: 10pt;
    color: #666;
  }

  /* Page breaks */
  h2,
  h3 {
    page-break-after: avoid;
  }

  p,
  blockquote {
    orphans: 3;
    widows: 3;
  }

  /* Print header */
  .print-header {
    display: block !important;
    text-align: center;
    padding-bottom: 20pt;
    border-bottom: 1pt solid #ccc;
    margin-bottom: 20pt;
  }
}

/* Print header (hidden on screen) */
.print-header {
  display: none;
}

/* ----------------------------------------
   Premium Content Badges
   ---------------------------------------- */
.access-badge {
  display: inline-flex;
  align-items: center;
  gap: var(--space-1);
  padding: var(--space-1) var(--space-2);
  border-radius: 50px;
  font-size: var(--text-xs);
  font-weight: 600;
  text-transform: uppercase;
  letter-spacing: 0.5px;
}

.access-badge-free {
  background-color: rgba(16, 185, 129, 0.1);
  color: var(--color-free);
}

.access-badge-preview {
  background-color: rgba(245, 158, 11, 0.1);
  color: var(--color-preview);
}

.access-badge-premium {
  background-color: rgba(124, 58, 237, 0.1);
  color: var(--color-premium);
}

.lock-icon {
  font-size: var(--text-sm);
}

/* Premium Article Card Overlay */
.article-card.premium-content {
  position: relative;
}

/* Removed redundant lock icon pseudo-element */
/*
.article-card.premium-content::before {
  content: '🔒';
  position: absolute;
  top: var(--space-4);
  right: var(--space-4);
  font-size: var(--text-lg);
  z-index: 2;
}
*/

/* ----------------------------------------
   Content Gate (for premium articles)
   ---------------------------------------- */
.content-gate {
  position: relative;
  margin-top: var(--space-8);
}

.content-gate-overlay {
  position: absolute;
  top: 0;
  left: -20%;
  right: -20%;
  height: 200px;
  background: linear-gradient(to bottom, transparent 0%, var(--color-bg) 80%);
  pointer-events: none;
}

.content-gate-box {
  background: linear-gradient(135deg, var(--color-primary) 0%, var(--color-primary-light) 100%);
  color: var(--color-white);
  padding: var(--space-10);
  border-radius: var(--radius-xl);
  text-align: center;
  position: relative;
  z-index: 1;
  box-shadow: var(--shadow-xl);
}

.content-gate-box h3 {
  font-size: var(--text-2xl);
  margin-bottom: var(--space-4);
  color: var(--color-white);
}

.content-gate-box p {
  color: rgba(255, 255, 255, 0.8);
  margin-bottom: var(--space-6);
  max-width: 500px;
  margin-left: auto;
  margin-right: auto;
}

.content-gate-price {
  font-size: var(--text-4xl);
  font-weight: 700;
  color: var(--color-accent);
  margin-bottom: var(--space-2);
}

.content-gate-price span {
  font-size: var(--text-lg);
  font-weight: 400;
  color: rgba(255, 255, 255, 0.6);
}

.content-gate-benefits {
  display: flex;
  justify-content: center;
  gap: var(--space-6);
  margin: var(--space-6) 0;
  flex-wrap: wrap;
}

.content-gate-benefits span {
  display: flex;
  align-items: center;
  gap: var(--space-2);
  font-size: var(--text-sm);
  color: rgba(255, 255, 255, 0.9);
}

/* ----------------------------------------
   Purchase Modal
   ---------------------------------------- */
.modal-overlay {
  position: fixed;
  top: 0;
  left: 0;
  right: 0;
  bottom: 0;
  background-color: rgba(15, 28, 46, 0.8);
  backdrop-filter: blur(4px);
  display: flex;
  align-items: center;
  justify-content: center;
  z-index: 9999;
  opacity: 0;
  visibility: hidden;
  transition: var(--transition-slow);
  padding: var(--space-4);
}

.modal-overlay.active {
  opacity: 1;
  visibility: visible;
}

.modal-content {
  background: var(--color-white);
  border-radius: var(--radius-xl);
  max-width: 500px;
  width: 100%;
  max-height: 90vh;
  overflow-y: auto;
  transform: translateY(20px) scale(0.95);
  transition: var(--transition-smooth);
}

.modal-overlay.active .modal-content {
  transform: translateY(0) scale(1);
}

.modal-header {
  padding: var(--space-6);
  border-bottom: 1px solid var(--color-border);
  display: flex;
  align-items: center;
  justify-content: space-between;
}

.modal-header h2 {
  font-size: var(--text-xl);
  margin: 0;
}

.modal-close {
  background: none;
  border: none;
  font-size: var(--text-2xl);
  cursor: pointer;
  color: var(--color-text-muted);
  width: 40px;
  height: 40px;
  display: flex;
  align-items: center;
  justify-content: center;
  border-radius: 50%;
  transition: var(--transition-base);
}

.modal-close:hover {
  background-color: var(--color-secondary);
  color: var(--color-text);
}

.modal-body {
  padding: var(--space-6);
}

.modal-footer {
  padding: var(--space-6);
  border-top: 1px solid var(--color-border);
  text-align: center;
}

/* Payment Options */
.payment-options {
  display: grid;
  gap: var(--space-4);
  margin-bottom: var(--space-6);
}

.payment-option {
  border: 2px solid var(--color-border);
  border-radius: var(--radius-lg);
  padding: var(--space-4);
  cursor: pointer;
  transition: var(--transition-base);
  display: flex;
  align-items: center;
  gap: var(--space-4);
}

.payment-option:hover {
  border-color: var(--color-primary);
}

.payment-option.selected {
  border-color: var(--color-accent);
  background-color: rgba(201, 162, 39, 0.05);
}

.payment-option-icon {
  font-size: var(--text-2xl);
}

.payment-option-info h4 {
  margin-bottom: var(--space-1);
}

.payment-option-info p {
  font-size: var(--text-sm);
  color: var(--color-text-muted);
  margin: 0;
}

/* Demo Notice */
.demo-notice {
  background-color: rgba(245, 158, 11, 0.1);
  border-left: 3px solid var(--color-preview);
  padding: var(--space-4);
  border-radius: var(--radius-md);
  margin-top: var(--space-4);
}

.demo-notice p {
  margin: 0;
  font-size: var(--text-sm);
  color: var(--color-text);
}

/* ----------------------------------------
   Parallax Hero
   ---------------------------------------- */
.hero-parallax {
  position: relative;
  min-height: 80vh;
  display: flex;
  align-items: center;
  overflow: hidden;
}

.h

/* Hero Background Handling */
.hero-background {
  position: absolute;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  z-index: -1;
  overflow: hidden;
}

/* The Image Layer */
.hero-background::before {
  content: "";
  position: absolute;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  background-size: cover;
  background-position: center 35%;
  /* Pulled down slightly (showing more top) */
  transition: all 0.5s ease;
  transform: scale(1.05);
  /* Constant scale as requested */

  /* Light Mode Defaults */
  background-image: url('../assets/hero-section-background-image-light.png');
  filter: blur(3px);
}

/* The Overlay Layer */
.hero-background::after {
  content: "";
  position: absolute;
  top: -10%;
  left: -10%;
  width: 120%;
  height: 120%;
  transition: background-color 0.5s ease;

  /* Light Mode Defaults */
  background-color: rgba(255, 255, 255, 0.88);
}

/* Dark Mode Overrides */
[data-theme="dark"] .hero-background::before {
  background-image: url('../assets/hero-section-background-image-dark.png');
  filter: blur(1.5px) brightness(0.75) contrast(1.1);
}

[data-theme="dark"] .hero-background::after {
  background-color: rgba(8, 15, 28, 0.82);
  /* Deep Navy */
}

/* Ensure content stays above */
.hero-section .container {
  position: relative;
  z-index: 2;
}

.hero-content {
  position: relative;
  z-index: 1;
}

/* Social Proof (Featured In Bar) */
.social-proof {
  padding: var(--space-8) 0;
  background-color: #f8f9fa;
  /* Distinct Light Grey Background */
  border-top: 1px solid var(--color-border);
  border-bottom: 1px solid var(--color-border);
  text-align: center;
  position: relative;
  z-index: 2;
  /* Check Z-index context */
}

.social-proof-title {
  font-size: var(--text-xs);
  text-transform: uppercase;
  letter-spacing: 1.5px;
  color: var(--color-text-muted);
  margin-bottom: var(--space-4);
  font-weight: 600;
}

.social-proof-logos {
  display: flex;
  justify-content: center;
  align-items: center;
  flex-wrap: wrap;
  gap: var(--space-6);
  opacity: 0.8;
}

.social-proof-logos span {
  font-family: var(--font-serif);
  font-size: var(--text-lg);
  font-style: italic;
  color: var(--color-text);
  opacity: 0.7;
  transition: opacity 0.3s ease;
}

.social-proof-logos span:hover {
  opacity: 1;
}

/* Social Proof Dark Mode */
[data-theme="dark"] .social-proof {
  background-color: rgba(255, 255, 255, 0.03);
  /* Subtle dark container */
  border-top: 1px solid rgba(255, 255, 255, 0.1);
  border-bottom: 1px solid rgba(255, 255, 255, 0.1);
}

[data-theme="dark"] .social-proof-logos span {
  color: var(--color-text-muted);
  /* Ensure visible light text */
}

/* ----------------------------------------
   Enhanced Animations
   ---------------------------------------- */
@keyframes fadeInUp {
  from {
    opacity: 0;
    transform: translateY(30px);
  }

  to {
    opacity: 1;
    transform: translateY(0);
  }
}

@keyframes fadeIn {
  from {
    opacity: 0;
  }

  to {
    opacity: 1;
  }
}

@keyframes slideInLeft {
  from {
    opacity: 0;
    transform: translateX(-30px);
  }

  to {
    opacity: 1;
    transform: translateX(0);
  }
}

@keyframes slideInRight {
  from {
    opacity: 0;
    transform: translateX(30px);
  }

  to {
    opacity: 1;
    transform: translateX(0);
  }
}

@keyframes scaleIn {
  from {
    opacity: 0;
    transform: scale(0.9);
  }

  to {
    opacity: 1;
    transform: scale(1);
  }
}

@keyframes float {

  0%,
  100% {
    transform: translateY(0);
  }

  50% {
    transform: translateY(-10px);
  }
}

/* Scroll Animations */
.animate-on-scroll {
  opacity: 0;
  transform: translateY(30px);
  transition: opacity 0.6s ease-out, transform 0.6s ease-out;
}

.animate-on-scroll.visible {
  opacity: 1;
  transform: translateY(0);
}

.animate-delay-1 {
  transition-delay: 0.1s;
}

.animate-delay-2 {
  transition-delay: 0.2s;
}

.animate-delay-3 {
  transition-delay: 0.3s;
}

.animate-delay-4 {
  transition-delay: 0.4s;
}

/* Enhanced Card Hover */
.article-card {
  transition: transform var(--transition-smooth), box-shadow var(--transition-smooth);
}

.article-card:hover {
  transform: translateY(-8px);
  box-shadow: var(--shadow-card-hover);
}

/* Button Micro-interactions */
.btn {
  position: relative;
  overflow: hidden;
}

.btn::after {
  content: '';
  position: absolute;
  top: 50%;
  left: 50%;
  width: 0;
  height: 0;
  background: rgba(255, 255, 255, 0.2);
  border-radius: 50%;
  transform: translate(-50%, -50%);
  transition: width 0.4s ease-out, height 0.4s ease-out;
}

.btn:active::after {
  width: 300px;
  height: 300px;
}

/* Reading Progress Enhancement */
.reading-progress {
  background: linear-gradient(90deg, var(--color-accent) 0%, var(--color-accent-light) 100%);
  box-shadow: var(--shadow-glow);
}

/* ----------------------------------------
   Background Texture
   ---------------------------------------- */
body {
  background-color: var(--color-bg);
  background-image:
    url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='100' height='100' viewBox='0 0 100 100'%3E%3Cg fill-rule='evenodd'%3E%3Cg fill='%23e5e1d8' fill-opacity='0.15'%3E%3Cpath opacity='.5' d='M96 95h4v1h-4v4h-1v-4h-9v4h-1v-4h-9v4h-1v-4h-9v4h-1v-4h-9v4h-1v-4h-9v4h-1v-4h-9v4h-1v-4h-9v4h-1v-4h-9v4h-1v-4H0v-1h15v-9H0v-1h15v-9H0v-1h15v-9H0v-1h15v-9H0v-1h15v-9H0v-1h15v-9H0v-1h15v-9H0v-1h15v-9H0v-1h15V0h1v15h9V0h1v15h9V0h1v15h9V0h1v15h9V0h1v15h9V0h1v15h9V0h1v15h9V0h1v15h9V0h1v15h4v1h-4v9h4v1h-4v9h4v1h-4v9h4v1h-4v9h4v1h-4v9h4v1h-4v9h4v1h-4v9h4v1h-4v9zm-1 0v-9h-9v9h9zm-10 0v-9h-9v9h9zm-10 0v-9h-9v9h9zm-10 0v-9h-9v9h9zm-10 0v-9h-9v9h9zm-10 0v-9h-9v9h9zm-10 0v-9h-9v9h9zm-10 0v-9h-9v9h9zm-9-10h9v-9h-9v9zm10 0h9v-9h-9v9zm10 0h9v-9h-9v9zm10 0h9v-9h-9v9zm10 0h9v-9h-9v9zm10 0h9v-9h-9v9zm10 0h9v-9h-9v9zm10 0h9v-9h-9v9zm9-10v-9h-9v9h9zm-10 0v-9h-9v9h9zm-10 0v-9h-9v9h9zm-10 0v-9h-9v9h9zm-10 0v-9h-9v9h9zm-10 0v-9h-9v9h9zm-10 0v-9h-9v9h9zm-10 0v-9h-9v9h9zm-9-10h9v-9h-9v9zm10 0h9v-9h-9v9zm10 0h9v-9h-9v9zm10 0h9v-9h-9v9zm10 0h9v-9h-9v9zm10 0h9v-9h-9v9zm10 0h9v-9h-9v9zm10 0h9v-9h-9v9zm9-10v-9h-9v9h9zm-10 0v-9h-9v9h9zm-10 0v-9h-9v9h9zm-10 0v-9h-9v9h9zm-10 0v-9h-9v9h9zm-10 0v-9h-9v9h9zm-10 0v-9h-9v9h9zm-10 0v-9h-9v9h9zm-9-10h9v-9h-9v9zm10 0h9v-9h-9v9zm10 0h9v-9h-9v9zm10 0h9v-9h-9v9zm10 0h9v-9h-9v9zm10 0h9v-9h-9v9zm10 0h9v-9h-9v9zm10 0h9v-9h-9v9zm9-10v-9h-9v9h9zm-10 0v-9h-9v9h9zm-10 0v-9h-9v9h9zm-10 0v-9h-9v9h9zm-10 0v-9h-9v9h9zm-10 0v-9h-9v9h9zm-10 0v-9h-9v9h9zm-10 0v-9h-9v9h9zm-9-10h9v-9h-9v9zm10 0h9v-9h-9v9zm10 0h9v-9h-9v9zm10 0h9v-9h-9v9zm10 0h9v-9h-9v9zm10 0h9v-9h-9v9zm10 0h9v-9h-9v9zm10 0h9v-9h-9v9z'/%3E%3Cpath d='M6 5V0H5v5H0v1h5v94h1V6h94V5H6z'/%3E%3C/g%3E%3C/g%3E%3C/svg%3E");
}

/* ----------------------------------------
   Subscription Plans (for premium page)
   ---------------------------------------- */
.pricing-cards {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(280px, 1fr));
  gap: var(--space-6);
  max-width: 900px;
  margin: 0 auto;
}

.pricing-card {
  background: var(--color-white);
  border-radius: var(--radius-xl);
  padding: var(--space-8);
  text-align: center;
  border: 2px solid var(--color-border);
  transition: var(--transition-smooth);
  position: relative;
}

.pricing-card:hover {
  border-color: var(--color-accent);
  transform: translateY(-4px);
  box-shadow: var(--shadow-lg);
}

.pricing-card.featured {
  border-color: var(--color-accent);
  box-shadow: var(--shadow-lg), var(--shadow-glow);
}

.pricing-card.featured::before {
  content: 'Most Popular';
  position: absolute;
  top: -12px;
  left: 50%;
  transform: translateX(-50%);
  background: linear-gradient(135deg, var(--color-accent) 0%, var(--color-accent-light) 100%);
  color: var(--color-white);
  padding: var(--space-1) var(--space-4);
  border-radius: 50px;
  font-size: var(--text-xs);
  font-weight: 600;
  text-transform: uppercase;
  letter-spacing: 0.5px;
}

.pricing-card-name {
  font-size: var(--text-lg);
  font-weight: 600;
  color: var(--color-primary);
  margin-bottom: var(--space-4);
}

.pricing-card-price {
  font-size: var(--text-4xl);
  font-weight: 700;
  color: var(--color-primary);
  margin-bottom: var(--space-2);
}

.pricing-card-price span {
  font-size: var(--text-base);
  font-weight: 400;
  color: var(--color-text-muted);
}

.pricing-card-features {
  list-style: none;
  padding: 0;
  margin: var(--space-6) 0;
  text-align: left;
}

.pricing-card-features li {
  padding: var(--space-2) 0;
  display: flex;
  align-items: center;
  gap: var(--space-2);
  font-size: var(--text-sm);
  color: var(--color-text-light);
}

.pricing-card-features li::before {
  content: '✓';
  color: var(--color-free);
  font-weight: bold;
}

/* Mobile Adjustments for Premium Content */
@media (max-width: 768px) {
  .content-gate-box {
    padding: var(--space-6);
    margin: 0 calc(-1 * var(--space-4));
    border-radius: var(--radius-md);
  }

  .content-gate-price {
    font-size: var(--text-3xl);
  }

  .content-gate-benefits {
    flex-direction: column;
    gap: var(--space-3);
  }

  .modal-content {
    margin: var(--space-4);
    max-height: calc(100vh - var(--space-8));
  }

  .payment-option {
    padding: var(--space-3);
  }

  .pricing-cards {
    grid-template-columns: 1fr;
  }
}

/* =================================================================
   DARK MODE VISIBILITY FIXES
   ================================================================= */
[data-theme="dark"] .newsletter-section {
  /* Override the Light Slate gradient with a Dark Navy gradient */
  background: linear-gradient(135deg, #1e293b 0%, #0f1c2e 100%);
  border-top: 1px solid #1e293b;
  border-bottom: 1px solid #1e293b;
}

[data-theme="dark"] .newsletter-section h3,
[data-theme="dark"] .newsletter-section p {
  color: #ffffff;
  /* Force White */
}

[data-theme="dark"] .footer {
  background-color: #0b1421;
  /* Very dark navy for footer */
  border-top: 1px solid #1e293b;
}

[data-theme="dark"] .footer-brand h3,
[data-theme="dark"] .footer-nav h4 {
  color: #f1f5f9;
  /* Bright white-ish text */
}

[data-theme="dark"] .footer-brand p,
[data-theme="dark"] .footer-nav ul li a,
[data-theme="dark"] .footer-copyright {
  color: #94a3b8;
  /* Readable grey-blue */
}

[data-theme="dark"] .footer-nav ul li a:hover {
  color: var(--color-accent);
}

[data-theme="dark"] .nav {
  /* Ensure mobile nav menu is dark */
  background-color: #1a2d42;
  border-bottom: 1px solid #2d3f56;
}

[data-theme="dark"] .pricing-card {
  /* Ensure pricing cards pop */
  background-color: #1a2d42;
  border-color: #2d3f56;
}

[data-theme="dark"] .pricing-card-name,
[data-theme="dark"] .pricing-card-price {
  color: #f1f5f9;
}

[data-theme="dark"] .logo img {
  /* Use the dark mode specific logo with Gold Icon & White Text */
  content: url('../assets/logo-dark.svg');
  filter: none;
  opacity: 1;
}

/* =================================================================
   USER REQUESTED REFINEMENTS (FINAL POLISH)
   ================================================================= */

/* Desktop Dark Mode: Reduce Grid Visibility (0.05 Opacity) */
[data-theme="dark"] body {
  background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='100' height='100' viewBox='0 0 100 100'%3E%3Cg fill-rule='evenodd'%3E%3Cg fill='%23e5e1d8' fill-opacity='0.05'%3E%3Cpath opacity='.5' d='M96 95h4v1h-4v4h-1v-4h-9v4h-1v-4h-9v4h-1v-4h-9v4h-1v-4h-9v4h-1v-4h-9v4h-1v-4h-9v4h-1v-4h-9v4h-1v-4h-9v4h-1v-4h-9v4h-1v-4H0v-1h15v-9H0v-1h15v-9H0v-1h15v-9H0v-1h15v-9H0v-1h15v-9H0v-1h15v-9H0v-1h15v-9H0v-1h15v-9H0v-1h15V0h1v15h9V0h1v15h9V0h1v15h9V0h1v15h9V0h1v15h9V0h1v15h9V0h1v15h9V0h1v15h9V0h1v15h4v1h-4v9h4v1h-4v9h4v1h-4v9h4v1h-4v9h4v1h-4v9h4v1h-4v9h4v1h-4v9h4v1h-4v9zm-1 0v-9h-9v9h9zm-10 0v-9h-9v9h9zm-10 0v-9h-9v9h9zm-10 0v-9h-9v9h9zm-10 0v-9h-9v9h9zm-10 0v-9h-9v9h9zm-10 0v-9h-9v9h9zm-10 0v-9h-9v9h9zm-9-10h9v-9h-9v9zm10 0h9v-9h-9v9zm10 0h9v-9h-9v9zm10 0h9v-9h-9v9zm10 0h9v-9h-9v9zm10 0h9v-9h-9v9zm10 0h9v-9h-9v9zm10 0h9v-9h-9v9zm9-10v-9h-9v9h9zm-10 0v-9h-9v9h9zm-10 0v-9h-9v9h9zm-10 0v-9h-9v9h9zm-10 0v-9h-9v9h9zm-10 0v-9h-9v9h9zm-10 0v-9h-9v9h9zm-10 0v-9h-9v9h9zm-10 0v-9h-9v9h9zm-9-10h9v-9h-9v9zm10 0h9v-9h-9v9zm10 0h9v-9h-9v9zm10 0h9v-9h-9v9zm10 0h9v-9h-9v9zm10 0h9v-9h-9v9zm10 0h9v-9h-9v9zm10 0h9v-9h-9v9zm10 0h9v-9h-9v9zm9-10v-9h-9v9h9zm-10 0v-9h-9v9h9zm-10 0v-9h-9v9h9zm-10 0v-9h-9v9h9zm-10 0v-9h-9v9h9zm-10 0v-9h-9v9h9zm-10 0v-9h-9v9h9zm-10 0v-9h-9v9h9zm-10 0v-9h-9v9h9zm-9-10h9v-9h-9v9zm10 0h9v-9h-9v9zm10 0h9v-9h-9v9zm10 0h9v-9h-9v9zm10 0h9v-9h-9v9zm10 0h9v-9h-9v9zm10 0h9v-9h-9v9zm10 0h9v-9h-9v9zm10 0h9v-9h-9v9z'/%3E%3Cpath d='M6 5V0H5v5H0v1h5v94h1V6h94V5H6z'/%3E%3C/g%3E%3C/g%3E%3C/svg%3E");
}

/* Desktop Dark Mode: Header Divider */
[data-theme="dark"] .header {
  border-bottom: 1px solid rgba(255, 255, 255, 0.08);
  /* Subtle definition */
}

/* Mobile Dark Mode Refinements */
@media (max-width: 768px) {

  /* Increase text brightness for long-form reading */
  [data-theme="dark"] .article-content p,
  [data-theme="dark"] .article-content li {
    color: #e2e8f0;
    /* Lighter than default Slate-400 */
  }

  /* Remove grid completely on mobile for zero distraction */
  [data-theme="dark"] body {
    background-image: none;
  }
}

/* =================================================================
   FOOTER POLISH (USER REQUESTED)
   ================================================================= */

/* 1. Spacing & Structure */
.footer {
  padding-bottom: var(--space-8);
  /* Reduced from likely space-12/16 */
}

/* 2. Visual Hierarchy */
.footer-brand h3 {
  font-size: 1.7rem;
  /* Increased size (was likely 1.5rem) */
  margin-bottom: var(--space-2);
}

/* 3. Divider Line */
.footer-bottom {
  border-top: 1px solid rgba(229, 225, 216, 0.15);
  /* Softer line */
  margin-top: var(--space-8);
  padding-top: var(--space-6);
}

/* Dark Mode Divider Override */
[data-theme="dark"] .footer-bottom {
  border-top: 1px solid rgba(255, 255, 255, 0.08);
}

/* 4. Alignment & Balance */
.footer-contact {
  text-align: left !important;
  /* Force Left Align */
}

.footer-contact p {
  margin-bottom: var(--space-2);
  color: var(--color-text-light);
}

[data-theme="dark"] .footer-contact p {
  color: #94a3b8;
}

/* Ensure Footer Contact Header matches Nav Headers */
.footer-contact h4 {
  font-size: var(--text-base);
  font-weight: 600;
  text-transform: uppercase;
  letter-spacing: 0.5px;
  color: #ffffff;
  /* White for Light Mode (assuming Dark Footer) */
  margin-bottom: var(--space-4);
}

[data-theme="dark"] .footer-contact h4 {
  color: #f1f5f9;
  /* White for Dark Mode */
}

/* Ensure Footer Columns Grid is Balanced */
/* Assuming .footer-main is grid, if not, this might need check. 
   But overriding text-align is key. */

@media (max-width: 768px) {
  .footer-contact {
    text-align: center !important;
  }

  .footer-credit {
    text-align: center !important;
  }
}

/* Developer Credit */
.footer-credit {
  font-size: 11px;
  color: var(--color-text-muted);
  opacity: 0.6;
  margin-top: var(--space-2);
  text-align: right;
  font-weight: 400;
  letter-spacing: 0.3px;
}

[data-theme="dark"] .footer-credit {
  color: #64748b;
  /* Slate-500 */
}