:root {
  --bg: #ffffff;
  --bg-secondary: #f8fafc;
  --bg-card: #ffffff;
  --text: #0f172a;
  --text-secondary: #64748b;
  --text-muted: #94a3b8;
  --border: #e2e8f0;
  --border-light: #f1f5f9;
  --primary: #6366f1;
  --primary-hover: #4f46e5;
  --primary-light: #eef2ff;
  --gradient-1: linear-gradient(135deg, #6366f1, #8b5cf6);
  --gradient-2: linear-gradient(135deg, #06b6d4, #0891b2);
  --gradient-3: linear-gradient(135deg, #f59e0b, #f97316);
  --gradient-hero: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
  --shadow-sm: 0 1px 2px rgba(0,0,0,0.05);
  --shadow: 0 4px 6px -1px rgba(0,0,0,0.1), 0 2px 4px -2px rgba(0,0,0,0.1);
  --shadow-lg: 0 10px 15px -3px rgba(0,0,0,0.1), 0 4px 6px -4px rgba(0,0,0,0.1);
  --shadow-xl: 0 20px 25px -5px rgba(0,0,0,0.1), 0 8px 10px -6px rgba(0,0,0,0.1);
  --radius: 12px;
  --radius-lg: 16px;
  --radius-xl: 24px;
  --transition: 0.3s cubic-bezier(0.4, 0, 0.2, 1);
  --font: 'Inter', -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, sans-serif;
  --font-mono: 'JetBrains Mono', 'Fira Code', monospace;
  --header-height: 72px;
  --max-width: 1280px;
  --orb1: rgba(99, 102, 241, 0.15);
  --orb2: rgba(139, 92, 246, 0.1);
  --orb3: rgba(6, 182, 212, 0.1);
  --card-glow: rgba(99, 102, 241, 0.05);
}

[data-theme="dark"] {
  --bg: #0f172a;
  --bg-secondary: #1e293b;
  --bg-card: #1e293b;
  --text: #f1f5f9;
  --text-secondary: #94a3b8;
  --text-muted: #64748b;
  --border: #334155;
  --border-light: #1e293b;
  --primary: #818cf8;
  --primary-hover: #6366f1;
  --primary-light: #1e1b4b;
  --gradient-hero: linear-gradient(135deg, #312e81 0%, #4c1d95 100%);
  --shadow-sm: 0 1px 2px rgba(0,0,0,0.3);
  --shadow: 0 4px 6px -1px rgba(0,0,0,0.4);
  --shadow-lg: 0 10px 15px -3px rgba(0,0,0,0.5);
  --shadow-xl: 0 20px 25px -5px rgba(0,0,0,0.6);
  --orb1: rgba(99, 102, 241, 0.08);
  --orb2: rgba(139, 92, 246, 0.06);
  --orb3: rgba(6, 182, 212, 0.06);
  --card-glow: rgba(99, 102, 241, 0.08);
}

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

html { scroll-behavior: smooth; }

body {
  font-family: var(--font);
  background: var(--bg);
  color: var(--text);
  line-height: 1.6;
  transition: background var(--transition), color var(--transition);
  overflow-x: hidden;
}

a { color: var(--primary); text-decoration: none; transition: color var(--transition); }
a:hover { color: var(--primary-hover); }

img { max-width: 100%; height: auto; }

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

/* Animated Background Orbs */
.bg-orbs {
  position: fixed;
  top: 0; left: 0;
  width: 100%; height: 100%;
  pointer-events: none;
  z-index: 0;
  overflow: hidden;
}
.bg-orbs .orb {
  position: absolute;
  border-radius: 50%;
  filter: blur(80px);
  animation: float 20s ease-in-out infinite;
}
.bg-orbs .orb:nth-child(1) {
  width: 600px; height: 600px;
  background: var(--orb1);
  top: -10%; left: -5%;
  animation-delay: 0s;
}
.bg-orbs .orb:nth-child(2) {
  width: 500px; height: 500px;
  background: var(--orb2);
  top: 50%; right: -10%;
  animation-delay: -7s;
  animation-duration: 25s;
}
.bg-orbs .orb:nth-child(3) {
  width: 400px; height: 400px;
  background: var(--orb3);
  bottom: -10%; left: 30%;
  animation-delay: -14s;
  animation-duration: 22s;
}
@keyframes float {
  0%, 100% { transform: translate(0, 0) scale(1); }
  25% { transform: translate(30px, -50px) scale(1.05); }
  50% { transform: translate(-20px, 20px) scale(0.95); }
  75% { transform: translate(40px, 30px) scale(1.02); }
}

/* Header */
.header {
  position: sticky;
  top: 0;
  z-index: 100;
  background: rgba(255,255,255,0.8);
  backdrop-filter: blur(20px);
  border-bottom: 1px solid var(--border);
  height: var(--header-height);
  transition: background var(--transition);
}
[data-theme="dark"] .header { background: rgba(15,23,42,0.85); }
.header-inner {
  max-width: var(--max-width);
  margin: 0 auto;
  padding: 0 24px;
  height: 100%;
  display: flex;
  align-items: center;
  justify-content: space-between;
}
.logo {
  font-size: 24px;
  font-weight: 800;
  background: var(--gradient-1);
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
  background-clip: text;
  letter-spacing: -0.5px;
}
.logo span { font-weight: 400; }

.nav { display: flex; align-items: center; gap: 32px; }
.nav a {
  color: var(--text-secondary);
  font-weight: 500;
  font-size: 15px;
  transition: color var(--transition);
}
.nav a:hover, .nav a.active { color: var(--primary); }

.header-search {
  position: relative;
  display: flex;
  align-items: center;
}
.header-search input {
  width: 260px;
  padding: 8px 16px 8px 38px;
  border: 2px solid var(--border);
  border-radius: 10px;
  font-size: 14px;
  background: var(--bg-secondary);
  color: var(--text);
  transition: all var(--transition);
}
.header-search input:focus {
  outline: none;
  border-color: var(--primary);
  width: 320px;
  box-shadow: 0 0 0 3px var(--primary-light);
}
.header-search svg {
  position: absolute;
  left: 12px;
  width: 16px;
  height: 16px;
  color: var(--text-muted);
}

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

/* Theme Toggle */
.theme-toggle {
  width: 40px;
  height: 40px;
  border: 2px solid var(--border);
  border-radius: 10px;
  background: var(--bg-secondary);
  cursor: pointer;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 18px;
  transition: all var(--transition);
}
.theme-toggle:hover { border-color: var(--primary); background: var(--primary-light); }

/* Auth buttons */
.btn {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  padding: 10px 20px;
  border: none;
  border-radius: var(--radius);
  font-size: 14px;
  font-weight: 600;
  cursor: pointer;
  transition: all var(--transition);
  font-family: var(--font);
}
.btn-primary {
  background: var(--gradient-1);
  color: #fff;
  box-shadow: 0 4px 15px rgba(99, 102, 241, 0.3);
}
.btn-primary:hover { transform: translateY(-2px); box-shadow: 0 6px 20px rgba(99, 102, 241, 0.4); }
.btn-secondary {
  background: var(--bg-secondary);
  color: var(--text);
  border: 2px solid var(--border);
}
.btn-secondary:hover { border-color: var(--primary); color: var(--primary); }
.btn-ghost {
  background: transparent;
  color: var(--text-secondary);
  padding: 8px 12px;
}
.btn-ghost:hover { color: var(--primary); background: var(--primary-light); }
.btn-sm { padding: 6px 14px; font-size: 13px; }
.btn-danger { background: linear-gradient(135deg, #ef4444, #dc2626); color: #fff; }
.btn-success { background: linear-gradient(135deg, #22c55e, #16a34a); color: #fff; }

/* Mobile nav */
.mobile-toggle {
  display: none;
  background: none;
  border: none;
  font-size: 24px;
  color: var(--text);
  cursor: pointer;
}

/* Hero */
.hero {
  position: relative;
  padding: 100px 0 80px;
  text-align: center;
  overflow: hidden;
  min-height: 520px;
  display: flex;
  align-items: center;
}
.hero-content {
  position: relative;
  z-index: 2;
  max-width: 700px;
  margin: 0 auto;
}
.hero h1 {
  font-size: 56px;
  font-weight: 800;
  line-height: 1.1;
  margin-bottom: 20px;
  letter-spacing: -1px;
}
.hero h1 .gradient-text {
  background: var(--gradient-1);
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
  background-clip: text;
}
.hero p {
  font-size: 20px;
  color: var(--text-secondary);
  margin-bottom: 40px;
  max-width: 550px;
  margin-left: auto;
  margin-right: auto;
}
.hero-search {
  display: flex;
  max-width: 560px;
  margin: 0 auto;
  background: var(--bg-card);
  border: 2px solid var(--border);
  border-radius: 16px;
  overflow: hidden;
  box-shadow: var(--shadow-lg);
  transition: border-color var(--transition);
}
.hero-search:focus-within { border-color: var(--primary); box-shadow: 0 0 0 4px var(--primary-light), var(--shadow-lg); }
.hero-search input {
  flex: 1;
  padding: 18px 24px;
  border: none;
  font-size: 17px;
  background: transparent;
  color: var(--text);
}
.hero-search input:focus { outline: none; }
.hero-search button {
  padding: 18px 32px;
  background: var(--gradient-1);
  color: #fff;
  border: none;
  font-size: 16px;
  font-weight: 700;
  cursor: pointer;
  transition: opacity var(--transition);
}
.hero-search button:hover { opacity: 0.9; }

#hero-canvas {
  position: absolute;
  top: 0; left: 0;
  width: 100%; height: 100%;
  z-index: 1;
  opacity: 0.6;
}

/* Usage indicator */
.usage-bar {
  margin-top: 20px;
  font-size: 13px;
  color: var(--text-muted);
}
.usage-bar .bar {
  width: 200px;
  height: 4px;
  background: var(--border);
  border-radius: 2px;
  margin: 6px auto 0;
  overflow: hidden;
}
.usage-bar .bar-fill {
  height: 100%;
  background: var(--gradient-1);
  border-radius: 2px;
  transition: width 0.5s ease;
}

/* Section */
.section {
  padding: 80px 0;
  position: relative;
  z-index: 1;
}
.section-header {
  display: flex;
  justify-content: space-between;
  align-items: center;
  margin-bottom: 40px;
}
.section-title {
  font-size: 32px;
  font-weight: 800;
  letter-spacing: -0.5px;
}
.section-subtitle {
  color: var(--text-secondary);
  font-size: 16px;
  margin-top: 4px;
}

/* Cards Grid */
.cards-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(280px, 1fr));
  gap: 24px;
}

/* Tool Card */
.tool-card {
  background: var(--bg-card);
  border: 1px solid var(--border);
  border-radius: var(--radius-lg);
  padding: 24px;
  transition: all var(--transition);
  cursor: pointer;
  position: relative;
  overflow: hidden;
}
.tool-card::before {
  content: '';
  position: absolute;
  top: 0; left: 0;
  width: 100%; height: 3px;
  background: var(--gradient-1);
  opacity: 0;
  transition: opacity var(--transition);
}
.tool-card:hover {
  transform: translateY(-4px) perspective(1000px) rotateX(2deg);
  box-shadow: var(--shadow-xl), 0 0 40px var(--card-glow);
  border-color: var(--primary);
}
.tool-card:hover::before { opacity: 1; }

.tool-card-icon {
  width: 52px;
  height: 52px;
  border-radius: 14px;
  background: var(--primary-light);
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 26px;
  margin-bottom: 16px;
}
.tool-card h3 {
  font-size: 18px;
  font-weight: 700;
  margin-bottom: 8px;
}
.tool-card p {
  font-size: 14px;
  color: var(--text-secondary);
  line-height: 1.5;
  margin-bottom: 16px;
}
.tool-card-meta {
  display: flex;
  align-items: center;
  justify-content: space-between;
}
.tool-card-category {
  font-size: 12px;
  font-weight: 600;
  padding: 4px 10px;
  background: var(--primary-light);
  color: var(--primary);
  border-radius: 20px;
}
.tool-card-views {
  font-size: 12px;
  color: var(--text-muted);
}

/* Article Card — used by the blog listing and the "more from the blog" block.
   Reuses the .tool-card hover language (gradient top bar, lift, glow) so both
   card types feel like one system. Every colour comes from a CSS variable so
   the component follows the dark theme automatically. */
.article-card {
  display: flex;
  flex-direction: column;
  background: var(--bg-card);
  border: 1px solid var(--border);
  border-radius: var(--radius-lg);
  overflow: hidden;
  color: var(--text);
  position: relative;
  transition: all var(--transition);
}
.article-card::before {
  content: '';
  position: absolute;
  top: 0; left: 0;
  width: 100%; height: 3px;
  background: var(--gradient-1);
  opacity: 0;
  transition: opacity var(--transition);
  z-index: 2;
}
.article-card:hover {
  transform: translateY(-4px);
  box-shadow: var(--shadow-xl), 0 0 40px var(--card-glow);
  border-color: var(--primary);
  color: var(--text);
}
.article-card:hover::before { opacity: 1; }

.article-card-media {
  position: relative;
  aspect-ratio: 16 / 9;
  background: linear-gradient(135deg, var(--primary-light), var(--bg-secondary));
  overflow: hidden;
}
.article-card-media img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  transition: transform var(--transition);
}
.article-card:hover .article-card-media img { transform: scale(1.05); }

/* Shown in place of a featured image when the article has none. */
.article-card-fallback {
  width: 100%;
  height: 100%;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 34px;
  color: var(--primary);
  opacity: 0.45;
}

.article-card-badges {
  position: absolute;
  top: 12px; left: 12px;
  display: flex;
  gap: 6px;
  flex-wrap: wrap;
  z-index: 1;
}
.article-card-badge {
  font-size: 11px;
  font-weight: 700;
  letter-spacing: 0.4px;
  text-transform: uppercase;
  padding: 4px 10px;
  border-radius: 999px;
  background: rgba(15, 23, 42, 0.78);
  color: #fff;
}
.article-card-badge.category { background: rgba(99, 102, 241, 0.94); }
.article-card-badge.featured { background: rgba(245, 158, 11, 0.95); color: #1c1917; }

.article-card-body {
  display: flex;
  flex-direction: column;
  flex: 1;
  padding: 20px 22px;
}
.article-card-title {
  font-size: 18px;
  font-weight: 700;
  line-height: 1.4;
  margin-bottom: 10px;
  display: -webkit-box;
  -webkit-line-clamp: 2;
  -webkit-box-orient: vertical;
  overflow: hidden;
}
.article-card:hover .article-card-title { color: var(--primary); }
.article-card-excerpt {
  font-size: 14px;
  color: var(--text-secondary);
  line-height: 1.6;
  margin-bottom: 16px;
  flex: 1;
  display: -webkit-box;
  -webkit-line-clamp: 3;
  -webkit-box-orient: vertical;
  overflow: hidden;
}
.article-card-meta {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 10px;
  padding-top: 14px;
  border-top: 1px solid var(--border-light);
  font-size: 12px;
  color: var(--text-muted);
}
.article-card-read {
  color: var(--primary);
  font-weight: 600;
  white-space: nowrap;
}

/* "More from the blog" block on the article page. Sits outside the narrow
   .article-content measure so the cards can use the full container width. */
.related-articles {
  margin-top: 48px;
  padding-top: 32px;
  border-top: 1px solid var(--border);
}

@media (max-width: 480px) {
  .article-card-meta { flex-direction: column; align-items: flex-start; gap: 6px; }
}

/* Category Card */
.category-card {
  background: var(--bg-card);
  border: 1px solid var(--border);
  border-radius: var(--radius-lg);
  padding: 32px 24px;
  text-align: center;
  transition: all var(--transition);
  cursor: pointer;
}
.category-card:hover {
  transform: translateY(-4px);
  box-shadow: var(--shadow-lg);
  border-color: var(--primary);
}
.category-card-icon {
  font-size: 40px;
  margin-bottom: 16px;
  display: block;
}
.category-card h3 { font-size: 18px; font-weight: 700; margin-bottom: 8px; }
.category-card p { font-size: 14px; color: var(--text-secondary); }
.category-card-count {
  display: inline-block;
  margin-top: 12px;
  font-size: 12px;
  font-weight: 600;
  color: var(--primary);
}

/* Tool Page */
.tool-page { padding-top: 40px; padding-bottom: 80px; }
.breadcrumb {
  display: flex;
  align-items: center;
  gap: 8px;
  font-size: 14px;
  color: var(--text-muted);
  margin-bottom: 32px;
  flex-wrap: wrap;
}
.breadcrumb a { color: var(--text-secondary); }
.breadcrumb a:hover { color: var(--primary); }
.breadcrumb .sep { color: var(--text-muted); }

.tool-header {
  display: flex;
  align-items: flex-start;
  gap: 20px;
  margin-bottom: 32px;
}
.tool-header-icon {
  width: 72px;
  height: 72px;
  border-radius: 18px;
  background: var(--primary-light);
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 36px;
  flex-shrink: 0;
}
.tool-header-info h1 {
  font-size: 32px;
  font-weight: 800;
  margin-bottom: 8px;
}
.tool-header-info p {
  font-size: 16px;
  color: var(--text-secondary);
}
.tool-header-actions { display: flex; gap: 12px; margin-top: 16px; }

.paid-badge {
  display: inline-block;
  font-size: 12px;
  font-weight: 700;
  vertical-align: middle;
  margin-left: 8px;
  padding: 4px 12px;
  background: linear-gradient(135deg, #7c3aed, #c026d3);
  color: #fff;
  border-radius: 20px;
}

/* Paid tool paywall */
.paywall {
  text-align: center;
  padding: 56px 32px;
  max-width: 560px;
  margin: 0 auto;
  background: linear-gradient(135deg, rgba(124, 58, 237, 0.07), rgba(192, 38, 211, 0.05));
  border: 2px dashed #c4b5fd;
  border-radius: var(--radius-xl);
}
.paywall-icon {
  width: 96px;
  height: 96px;
  margin: 0 auto 24px;
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 42px;
  background: linear-gradient(135deg, #7c3aed, #c026d3);
  box-shadow: 0 12px 28px -8px rgba(124, 58, 237, 0.5);
}
.paywall h2 { font-size: 26px; font-weight: 800; margin-bottom: 12px; }
.paywall p { font-size: 16px; color: var(--text-secondary); line-height: 1.7; margin-bottom: 20px; }
.paywall-price {
  display: inline-flex;
  align-items: baseline;
  gap: 8px;
  font-size: 42px;
  font-weight: 800;
  margin: 8px 0 28px;
  color: var(--text);
}
.paywall-price span {
  font-size: 14px;
  font-weight: 600;
  color: var(--text-secondary);
}
.paywall .btn-primary {
  font-size: 17px;
  padding: 15px 42px;
  border-radius: 999px;
}
.paywall-note { font-size: 13px !important; margin-top: 20px !important; }
.paywall-note a { color: var(--primary); font-weight: 600; }

.tool-embed {
  background: #ffffff;
  border: 1px solid #e5e7eb;
  border-radius: var(--radius-lg);
  padding: 32px;
  margin-bottom: 40px;
  min-height: 640px;
}
.tool-embed iframe {
  width: 100%;
  height: 640px;
  min-height: 640px;
  border: none;
  border-radius: 8px;
}
/* Tool area is always white so embedded tools look the same in both themes */
.tool-embed { color: #111827; }
.tool-embed h2,
.tool-embed p,
.tool-embed .paywall-price,
.tool-embed .paywall-price span,
.tool-embed .paywall-note { color: #111827; }
.tool-embed .paywall {
  background: linear-gradient(135deg, rgba(124, 58, 237, 0.08), rgba(192, 38, 211, 0.06));
  border-color: #ddd6fe;
}
.tool-embed .paywall-note a { color: #7c3aed; }
.tool-embed textarea,
.tool-embed input,
.tool-embed select {
  background: #f8fafc;
  color: #111827;
  border-color: #e2e8f0;
}
.tool-embed textarea {
  width: 100%;
  min-height: 200px;
}

.tool-content { max-width: 800px; margin-bottom: 60px; }
.tool-content h2 { font-size: 24px; font-weight: 700; margin-bottom: 16px; margin-top: 32px; }
.tool-content p { font-size: 16px; color: var(--text-secondary); line-height: 1.8; margin-bottom: 16px; }

.related-tools { margin-top: 60px; }
.share-buttons { display: flex; flex-wrap: wrap; gap: 10px; margin-top: 20px; }
.share-btn {
  padding: 8px 16px;
  border-radius: 8px;
  font-size: 13px;
  font-weight: 600;
  color: #fff;
  border: none;
  cursor: pointer;
  text-decoration: none;
  transition: opacity .2s;
}
.share-btn:hover { opacity: .85; color: #fff; }
.share-btn.facebook { background: #1877f2; }
.share-btn.instagram { background: linear-gradient(45deg, #f09433, #e6683c 25%, #dc2743 50%, #cc2366 75%, #bc1888); }
.share-btn.x { background: #000; }
.share-btn.pinterest { background: #e60023; }
.share-btn.linkedin { background: #0a66c2; }
.share-btn.tiktok { background: linear-gradient(45deg, #00f2ea, #ff0050); }
.share-btn.youtube { background: #ff0000; }
.share-btn.threads { background: #000; }
.share-btn.whatsapp { background: #25d366; }
.share-btn.copy { background: var(--gradient-2); }

/* Search Results */
.search-page { padding: 40px 0 80px; }
.search-page h1 { font-size: 32px; font-weight: 800; margin-bottom: 8px; }
.search-page .query { color: var(--primary); }
.search-results-info { color: var(--text-secondary); margin-bottom: 32px; }
.no-results { text-align: center; padding: 80px 0; }
.no-results h2 { font-size: 24px; margin-bottom: 12px; }
.no-results p { color: var(--text-secondary); }

/* Category Page */
.category-page { padding: 40px 0 80px; }
.category-page-header { margin-bottom: 40px; }
.category-page-header h1 {
  font-size: 36px;
  font-weight: 800;
  display: flex;
  align-items: center;
  gap: 12px;
}
.category-page-header p { font-size: 16px; color: var(--text-secondary); margin-top: 8px; }
.sort-bar {
  display: flex;
  gap: 12px;
  margin-bottom: 32px;
  flex-wrap: wrap;
}
.sort-btn {
  padding: 8px 16px;
  border: 2px solid var(--border);
  border-radius: 8px;
  background: transparent;
  color: var(--text-secondary);
  font-size: 14px;
  font-weight: 500;
  cursor: pointer;
  transition: all var(--transition);
}
.sort-btn.active, .sort-btn:hover {
  border-color: var(--primary);
  color: var(--primary);
  background: var(--primary-light);
}

/* Footer */
.footer {
  background: var(--bg-secondary);
  border-top: 1px solid var(--border);
  padding: 60px 0 30px;
  position: relative;
  z-index: 1;
}
.footer-grid {
  display: grid;
  grid-template-columns: 2fr 1fr 1fr 1fr;
  gap: 40px;
  margin-bottom: 40px;
}
.footer-brand .logo { font-size: 28px; margin-bottom: 12px; display: block; }
.footer-brand p { color: var(--text-secondary); font-size: 14px; line-height: 1.7; }
.footer-col h4 { font-size: 14px; font-weight: 700; text-transform: uppercase; letter-spacing: 1px; margin-bottom: 16px; color: var(--text-muted); }
.footer-col a {
  display: block;
  color: var(--text-secondary);
  font-size: 14px;
  padding: 4px 0;
  transition: color var(--transition);
}
.footer-col a:hover { color: var(--primary); }
.footer-bottom {
  border-top: 1px solid var(--border);
  padding-top: 24px;
  display: flex;
  justify-content: space-between;
  align-items: center;
  font-size: 13px;
  color: var(--text-muted);
}
.footer-socials { display: flex; gap: 12px; }
.footer-socials a {
  width: 36px;
  height: 36px;
  border-radius: 10px;
  background: var(--bg-card);
  border: 1px solid var(--border);
  display: flex;
  align-items: center;
  justify-content: center;
  color: var(--text-secondary);
  font-size: 16px;
  transition: all var(--transition);
}
.footer-socials a:hover { border-color: var(--primary); color: var(--primary); }

/* Auth Modal */
.modal-overlay {
  position: fixed;
  top: 0; left: 0;
  width: 100%; height: 100%;
  background: rgba(0,0,0,0.5);
  backdrop-filter: blur(8px);
  z-index: 200;
  display: none;
  align-items: center;
  justify-content: center;
}
.modal-overlay.active { display: flex; }
.modal {
  background: var(--bg-card);
  border: 1px solid var(--border);
  border-radius: var(--radius-xl);
  padding: 40px;
  width: 100%;
  max-width: 420px;
  box-shadow: var(--shadow-xl);
  position: relative;
}
.modal-close {
  position: absolute;
  top: 16px; right: 16px;
  background: none;
  border: none;
  font-size: 20px;
  color: var(--text-muted);
  cursor: pointer;
}
.modal h2 { font-size: 24px; font-weight: 800; margin-bottom: 8px; }
.modal p { color: var(--text-secondary); margin-bottom: 24px; }
.form-group { margin-bottom: 16px; }
.form-group label { display: block; font-size: 14px; font-weight: 600; margin-bottom: 6px; color: var(--text-secondary); }
.form-group input {
  width: 100%;
  padding: 12px 16px;
  border: 2px solid var(--border);
  border-radius: 10px;
  font-size: 15px;
  background: var(--bg);
  color: var(--text);
  transition: border-color var(--transition);
}
.form-group input:focus { outline: none; border-color: var(--primary); }
.form-error { color: #ef4444; font-size: 13px; margin-top: 4px; }
.modal-switch { text-align: center; margin-top: 20px; font-size: 14px; color: var(--text-secondary); }
.modal-switch a { color: var(--primary); font-weight: 600; cursor: pointer; }

/* Password visibility toggle + auth helpers */
.pw-wrap { position: relative; }
.pw-wrap input { padding-right: 44px; }
.pw-toggle {
  position: absolute;
  right: 4px;
  top: 50%;
  transform: translateY(-50%);
  background: none;
  border: none;
  color: var(--text-muted);
  font-size: 16px;
  cursor: pointer;
  padding: 8px;
  z-index: 2;
}
.pw-toggle:hover { color: var(--primary); }
.auth-row { display: flex; align-items: center; justify-content: space-between; margin: 2px 0 14px; font-size: 13px; }
.auth-link { color: var(--primary); font-weight: 600; cursor: pointer; background: none; border: none; padding: 0; font-size: 13px; }
.auth-link:hover { text-decoration: underline; }
.resend-row { text-align: center; margin-top: 12px; font-size: 13px; }

/* Toast */
.toast {
  position: fixed;
  bottom: 24px;
  right: 24px;
  background: var(--bg-card);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  padding: 16px 24px;
  box-shadow: var(--shadow-lg);
  z-index: 300;
  display: flex;
  align-items: center;
  gap: 12px;
  transform: translateY(120%);
  transition: transform 0.4s cubic-bezier(0.34, 1.56, 0.64, 1);
  font-size: 14px;
}
.toast.show { transform: translateY(0); }
.toast-icon { font-size: 20px; }
.toast.warning { border-left: 4px solid #f59e0b; }
.toast.success { border-left: 4px solid #22c55e; }
.toast.error { border-left: 4px solid #ef4444; }

/* Static Pages */
.static-page { padding: 60px 0 80px; max-width: 800px; margin: 0 auto; }
.static-page h1 { font-size: 36px; font-weight: 800; margin-bottom: 32px; }
.static-page h2 { font-size: 24px; font-weight: 700; margin-top: 32px; margin-bottom: 12px; }
.static-page p { font-size: 16px; color: var(--text-secondary); line-height: 1.8; margin-bottom: 16px; }

/* Contact Form */
.contact-form { max-width: 600px; margin-top: 24px; }
.contact-form textarea {
  width: 100%;
  padding: 12px 16px;
  border: 2px solid var(--border);
  border-radius: 10px;
  font-size: 15px;
  min-height: 150px;
  resize: vertical;
  background: var(--bg);
  color: var(--text);
  font-family: var(--font);
  margin-bottom: 16px;
}
.contact-form textarea:focus { outline: none; border-color: var(--primary); }

/* Pagination */
.pagination {
  display: flex;
  gap: 8px;
  justify-content: center;
  margin-top: 48px;
}
.pagination a, .pagination span {
  width: 40px; height: 40px;
  display: flex;
  align-items: center;
  justify-content: center;
  border-radius: 10px;
  font-size: 14px;
  font-weight: 600;
  border: 2px solid var(--border);
  color: var(--text-secondary);
  transition: all var(--transition);
}
.pagination a:hover { border-color: var(--primary); color: var(--primary); }
.pagination .active { background: var(--gradient-1); color: #fff; border-color: transparent; }

/* Loading */
.loading {
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 60px 0;
}
.spinner {
  width: 40px; height: 40px;
  border: 3px solid var(--border);
  border-top-color: var(--primary);
  border-radius: 50%;
  animation: spin 0.8s linear infinite;
}
@keyframes spin { to { transform: rotate(360deg); } }

/* Animations */
.fade-in { opacity: 0; transform: translateY(20px); transition: all 0.6s cubic-bezier(0.4, 0, 0.2, 1); }
.fade-in.visible { opacity: 1; transform: translateY(0); }

/* Reduced motion */
@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after {
    animation-duration: 0.01ms !important;
    transition-duration: 0.01ms !important;
  }
  .bg-orbs { display: none; }
  #hero-canvas { display: none; }
  .tool-card:hover { transform: none; }
}

/* Responsive */
@media (max-width: 1024px) {
  .footer-grid { grid-template-columns: 1fr 1fr; }
}

@media (max-width: 768px) {
  .nav { display: none; }
  .nav.open {
    display: flex;
    flex-direction: column;
    position: absolute;
    top: var(--header-height);
    left: 0; right: 0;
    background: var(--bg-card);
    border-bottom: 1px solid var(--border);
    padding: 20px;
    gap: 16px;
    box-shadow: var(--shadow-lg);
  }
  .mobile-toggle { display: block; }
  .header-search { display: none; }
  .hero h1 { font-size: 36px; }
  .hero p { font-size: 16px; }
  .hero { padding: 60px 0 40px; min-height: auto; }
  .hero-search { flex-direction: column; border-radius: 12px; }
  .hero-search input { padding: 14px 16px; }
  .hero-search button { padding: 14px; }
  .section { padding: 48px 0; }
  .section-title { font-size: 24px; }
  .cards-grid { grid-template-columns: 1fr; }
  .footer-grid { grid-template-columns: 1fr; gap: 24px; }
  .footer-bottom { flex-direction: column; gap: 12px; text-align: center; }
  .tool-header { flex-direction: column; }
  .tool-header-info h1 { font-size: 24px; }
  .tool-embed { padding: 16px; }
  .tool-page { padding-top: 24px; }
}

/* Scrollbar */
::-webkit-scrollbar { width: 8px; }
::-webkit-scrollbar-track { background: var(--bg-secondary); }
::-webkit-scrollbar-thumb { background: var(--border); border-radius: 4px; }
::-webkit-scrollbar-thumb:hover { background: var(--text-muted); }

/* ============================================================
   Site-wide saas-style Footer
   ============================================================ */
.app-footer {
  background: #0f172a;
  color: #94a3b8;
  border-top: 1px solid #1e293b;
}
.app-footer .container { padding-top: 60px; padding-bottom: 40px; }
.app-footer .footer-grid {
  display: grid;
  grid-template-columns: 2fr 1fr 1fr 1fr;
  gap: 40px;
  margin-bottom: 40px;
}
.app-footer .footer-col h4 {
  color: #fff;
  font-size: 15px;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 1px;
  margin-bottom: 18px;
}
.app-footer .footer-col ul { list-style: none; display: flex; flex-direction: column; gap: 12px; padding: 0; margin: 0; }
.app-footer .footer-col ul li a { color: #94a3b8; text-decoration: none; font-size: 14px; transition: color var(--transition); }
.app-footer .footer-col ul li a:hover { color: var(--primary); }
.app-footer .footer-brand p { color: #94a3b8; font-size: 14px; line-height: 1.7; margin-bottom: 20px; }
.app-footer .footer-logo { margin-bottom: 16px; display: block; }
.app-footer .footer-logo .logo { font-size: 28px; }
.app-footer .social-links { display: flex; gap: 12px; }
.app-footer .social-links a {
  width: 38px; height: 38px;
  border-radius: 10px;
  background: #1e293b;
  color: #f8fafc;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  text-decoration: none;
  font-size: 15px;
  transition: all var(--transition);
}
.app-footer .social-links a:hover { background: var(--primary); color: #fff; }
.app-footer .footer-bottom {
  border-top: 1px solid #1e293b;
  padding-top: 24px;
  display: flex;
  justify-content: space-between;
  align-items: center;
  font-size: 13px;
  color: #64748b;
}
.app-footer .footer-bottom .back-home { color: var(--primary); text-decoration: none; font-weight: 600; }
.app-footer .footer-bottom .back-home:hover { text-decoration: underline; }

/* SEO / long-form content blocks */
.seo-copy { max-width: 900px; margin: 0 auto; }.seo-copy p { color: var(--text-secondary); line-height: 1.8; margin-bottom: 16px; font-size: 15px; }
.seo-copy h2 { font-size: 24px; font-weight: 700; margin: 40px 0 16px; }
.seo-copy h3 { font-size: 20px; font-weight: 700; margin: 28px 0 12px; }
.seo-copy ul, .seo-copy ol { margin: 0 0 16px 22px; color: var(--text-secondary); line-height: 1.8; }
.seo-faq dt { font-weight: 700; margin-top: 18px; color: var(--text); }
.seo-faq dd { margin: 6px 0 0 0; color: var(--text-secondary); line-height: 1.7; }
.hero-stats { margin-top: 18px; font-size: 14px; color: var(--text-muted); letter-spacing: 0.3px; }

@media (max-width: 1024px) {
  .app-footer .footer-grid { grid-template-columns: 1fr 1fr; }
}
@media (max-width: 768px) {
  .app-footer .footer-grid { grid-template-columns: 1fr; gap: 28px; }
  .app-footer .footer-bottom { flex-direction: column; gap: 12px; text-align: center; }
}

/* ============ Newsletter ============ */
/* Lives inside the footer on every page. Uses --gradient-1 for the panel and
   --bg-card for the form so it follows the dark theme automatically. */
.newsletter {
  margin-top: 40px;
  padding: 28px 32px;
  border-radius: var(--radius-lg);
  background: linear-gradient(135deg, var(--primary-hover), #312e81);
  color: #fff;
  position: relative;
  overflow: hidden;
}
.newsletter::after {
  content: '';
  position: absolute;
  top: -40%; right: -10%;
  width: 320px; height: 320px;
  border-radius: 50%;
  background: rgba(255, 255, 255, 0.06);
  pointer-events: none;
}
.newsletter-inner {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 32px;
  position: relative;
  z-index: 1;
}
.newsletter-copy { max-width: 480px; }
.newsletter-copy h2 {
  font-size: 22px;
  font-weight: 800;
  letter-spacing: -0.3px;
  margin-bottom: 8px;
  color: #fff;
}
.newsletter-copy p {
  font-size: 14px;
  line-height: 1.6;
  color: rgba(255, 255, 255, 0.82);
  margin-bottom: 10px;
}
.newsletter-proof {
  display: inline-block;
  font-size: 13px;
  font-weight: 600;
  color: #fff;
  background: rgba(255, 255, 255, 0.14);
  border: 1px solid rgba(255, 255, 255, 0.2);
  border-radius: 999px;
  padding: 4px 12px;
}
.newsletter-form { flex: 1; max-width: 460px; }
.newsletter-row { display: flex; gap: 10px; }
.newsletter-row input {
  flex: 1;
  min-width: 0;
  padding: 12px 16px;
  border-radius: var(--radius);
  border: 1px solid rgba(255, 255, 255, 0.25);
  background: rgba(255, 255, 255, 0.12);
  color: #fff;
  font-size: 15px;
  font-family: var(--font);
}
.newsletter-row input::placeholder { color: rgba(255, 255, 255, 0.65); }
.newsletter-row input:focus {
  outline: none;
  border-color: #fff;
  background: rgba(255, 255, 255, 0.2);
}
.newsletter-row .btn { white-space: nowrap; }
.newsletter-msg {
  font-size: 13px;
  margin-top: 10px;
  min-height: 18px;
  color: rgba(255, 255, 255, 0.9);
}
.newsletter-msg.error { color: #fecaca; }
.newsletter-msg.success { color: #d1fae5; }

/* Visible focus label for the newsletter input, which has no visible label. */
.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;
}

@media (max-width: 900px) {
  .newsletter-inner { flex-direction: column; align-items: stretch; gap: 20px; }
  .newsletter-form { max-width: none; }
}
@media (max-width: 480px) {
  .newsletter { padding: 24px 20px; }
  .newsletter-row { flex-direction: column; }
}

/* Confirm / unsubscribe result page */
.nl-result {
  background: var(--bg-card);
  border: 1px solid var(--border);
  border-radius: var(--radius-lg);
  padding: 48px 32px;
  text-align: center;
}
.nl-result-icon { font-size: 56px; line-height: 1; margin-bottom: 18px; }
.nl-result-email {
  font-weight: 700;
  color: var(--primary);
  margin-bottom: 10px;
}

/* ============ About page ============ */
.about-hero {
  position: relative;
  background: linear-gradient(135deg, var(--primary-hover), #312e81);
  color: #fff;
  padding: 64px 32px;
  border-radius: var(--radius-xl);
  margin: 32px 0 48px;
  overflow: hidden;
  text-align: center;
  box-shadow: var(--shadow-xl);
  border: 1px solid #4338ca;
}
.about-hero h1 { font-size: clamp(28px, 4vw, 48px); font-weight: 800; margin-bottom: 16px; letter-spacing: -0.02em; }
.about-hero p { font-size: 17px; color: #c7d2fe; line-height: 1.7; max-width: 760px; margin: 0 auto; }
.about-stats { display: flex; gap: 32px; justify-content: center; margin-top: 28px; flex-wrap: wrap; }
.about-stat { text-align: center; }
.about-stat strong { display: block; font-size: 30px; font-weight: 800; }
.about-stat span { font-size: 13px; color: #c7d2fe; }

.mission-section { padding: 8px 0 48px; }
.mission-grid { display: grid; grid-template-columns: repeat(auto-fit, minmax(260px, 1fr)); gap: 24px; }
.mission-card {
  background: var(--bg-card); border: 1px solid var(--border);
  padding: 32px 24px; border-radius: var(--radius-lg); text-align: center;
  transition: transform var(--transition), border-color var(--transition), box-shadow var(--transition);
}
.mission-card:hover { transform: translateY(-5px); border-color: var(--primary); box-shadow: var(--shadow-xl); }
.mission-card .card-icon {
  width: 64px; height: 64px; border-radius: 50%;
  background: var(--primary-light); color: var(--primary);
  display: flex; align-items: center; justify-content: center;
  font-size: 26px; margin: 0 auto 16px;
}
.mission-card h3 { font-size: 18px; font-weight: 700; margin-bottom: 10px; }
.mission-card p { font-size: 14px; color: var(--text-secondary); line-height: 1.7; }

.timeline-section { padding: 0 0 48px; }
.timeline-grid { display: grid; grid-template-columns: repeat(auto-fit, minmax(240px, 1fr)); gap: 24px; }
.timeline-item {
  position: relative; background: var(--bg-card); border: 1px solid var(--border);
  border-radius: var(--radius-lg); padding: 32px 24px 24px;
}
.timeline-year {
  position: absolute; top: -14px; left: 20px;
  background: var(--primary); color: #fff;
  padding: 4px 16px; border-radius: 50px; font-size: 13px; font-weight: 700;
  box-shadow: 0 4px 10px rgba(99,102,241,0.3);
}
.timeline-title { font-size: 17px; font-weight: 700; margin: 8px 0 8px; }
.timeline-desc { font-size: 14px; color: var(--text-secondary); line-height: 1.7; }

.team-section { padding: 0 0 48px; }
.team-grid { display: flex; justify-content: center; gap: 32px; flex-wrap: wrap; }
.team-card {
  background: var(--bg-card); border: 1px solid var(--border);
  border-radius: var(--radius-lg); padding: 40px 32px; width: 320px; text-align: center;
  transition: transform var(--transition), border-color var(--transition);
}
.team-card:hover { transform: translateY(-5px); border-color: var(--primary); }
.team-avatar {
  width: 120px; height: 120px; border-radius: 50%;
  background: var(--primary-light); color: var(--primary);
  margin: 0 auto 16px; border: 3px solid var(--primary);
  display: flex; align-items: center; justify-content: center;
  font-size: 40px; overflow: hidden;
}
.team-avatar img { width: 100%; height: 100%; object-fit: cover; }
.team-card h3 { font-size: 20px; font-weight: 700; margin-bottom: 4px; }
.team-role { font-size: 12px; font-weight: 700; text-transform: uppercase; color: var(--primary); letter-spacing: 0.5px; margin-bottom: 12px; }
.team-bio { font-size: 14px; color: var(--text-secondary); line-height: 1.7; }

/* ============ Contact page ============ */
.contact-grid { display: grid; grid-template-columns: 1.1fr 1.5fr; gap: 32px; margin: 40px 0 56px; }
.contact-info-panel {
  background: linear-gradient(135deg, #0f172a, #1e293b); color: #fff;
  padding: 40px; border-radius: var(--radius-xl); border: 1px solid #334155;
  min-height: 480px; display: flex; flex-direction: column; justify-content: space-between;
}
.info-tagline {
  width: fit-content; font-size: 12px; font-weight: 700; text-transform: uppercase; letter-spacing: 1px;
  color: #a5b4fc; background: rgba(255,255,255,0.06); border: 1px solid rgba(255,255,255,0.1);
  padding: 6px 16px; border-radius: 50px; margin-bottom: 20px; display: inline-flex; align-items: center; gap: 8px;
}
.contact-info-panel h1 { font-size: 36px; font-weight: 800; margin-bottom: 12px; letter-spacing: -0.01em; }
.contact-info-panel > p { color: #94a3b8; line-height: 1.7; margin-bottom: 32px; }
.info-items-list { display: flex; flex-direction: column; gap: 16px; margin-bottom: 32px; }
.info-item-card {
  display: flex; align-items: center; gap: 14px;
  background: rgba(255,255,255,0.03); border: 1px solid rgba(255,255,255,0.05);
  padding: 16px; border-radius: var(--radius-lg);
}
.info-item-card .item-icon {
  width: 44px; height: 44px; border-radius: 50%;
  background: rgba(99,102,241,0.15); color: #818cf8;
  display: flex; align-items: center; justify-content: center; font-size: 18px; flex-shrink: 0;
}
.item-details h4 { font-size: 14px; font-weight: 700; }
.item-details p { color: #cbd5e1; font-size: 14px; margin: 2px 0 0; }
.social-panel h4 { font-size: 12px; text-transform: uppercase; letter-spacing: 0.5px; color: #64748b; margin-bottom: 10px; }
.social-links-row { display: flex; gap: 12px; }
.social-links-row a {
  width: 40px; height: 40px; border-radius: 50%;
  background: rgba(255,255,255,0.05); color: #fff;
  display: inline-flex; align-items: center; justify-content: center; text-decoration: none;
  transition: all var(--transition);
}
.social-links-row a:hover { background: var(--primary); }

.contact-form-panel {
  background: var(--bg-card); border: 1px solid var(--border);
  padding: 40px; border-radius: var(--radius-xl);
  box-shadow: var(--shadow-lg);
}
.contact-form-panel .form-group { display: flex; flex-direction: column; gap: 8px; margin-bottom: 20px; }
.contact-form-panel .form-group label { font-size: 14px; font-weight: 600; color: var(--text); }
.contact-form-panel .form-control {
  width: 100%; padding: 12px 16px;
  border: 1px solid var(--border); border-radius: var(--radius);
  outline: none; font-size: 15px; background: var(--bg); color: var(--text);
  transition: border-color var(--transition), box-shadow var(--transition);
}
.contact-form-panel .form-control:focus { border-color: var(--primary); box-shadow: 0 0 0 3px var(--card-glow); }
.contact-form-panel textarea.form-control { resize: vertical; min-height: 140px; }
.btn-submit {
  width: 100%; border: none; cursor: pointer;
  background: linear-gradient(135deg, var(--primary), var(--primary-hover));
  color: #fff; padding: 14px; border-radius: var(--radius);
  font-size: 16px; font-weight: 700; font-family: inherit;
  box-shadow: 0 10px 20px -10px rgba(99,102,241,0.5);
  transition: transform var(--transition), box-shadow var(--transition);
  display: flex; justify-content: center; align-items: center; gap: 8px;
}
.btn-submit:hover { transform: translateY(-2px); box-shadow: 0 15px 25px -10px rgba(99,102,241,0.6); }
.btn-submit:disabled { opacity: 0.7; cursor: not-allowed; }
.form-status { margin-top: 12px; font-size: 14px; font-weight: 600; display: none; }
.form-status.success { display: block; color: #10b981; }
.form-status.error { display: block; color: #ef4444; }

@media (max-width: 900px) {
  .contact-grid { grid-template-columns: 1fr; }
  .about-hero { padding: 48px 20px; }
  .contact-info-panel, .contact-form-panel { padding: 28px 20px; }
}

/* ============ Static text pages (privacy / terms) ============ */
.static-page { max-width: 820px; margin: 48px auto 64px; }
.static-page h1 { font-size: 36px; font-weight: 800; margin-bottom: 12px; }
.static-page h2 { font-size: 24px; font-weight: 700; margin: 40px 0 14px; }
.static-page p, .static-page li { color: var(--text-secondary); line-height: 1.8; font-size: 15px; }
.static-page ul { margin: 0 0 16px 22px; }
.static-page em { color: var(--text-muted); }
.static-page a { color: var(--primary); }

/* ============ Preloader (site loading screen) ============ */
#preloader {
  position: fixed;
  inset: 0;
  z-index: 9999;
  display: flex;
  align-items: center;
  justify-content: center;
  background: var(--bg);
  transition: opacity 0.5s ease, visibility 0.5s ease;
}
#preloader.hidden {
  opacity: 0;
  visibility: hidden;
  pointer-events: none;
}
.preloader-inner {
  position: relative;
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 18px;
  animation: preloaderPop 0.8s cubic-bezier(0.34, 1.56, 0.64, 1);
}
.preloader-inner img {
  width: 96px;
  height: 96px;
  border-radius: 50%;
  box-shadow: 0 0 60px rgba(99, 102, 241, 0.5);
  animation: preloaderPulse 1.6s ease-in-out infinite;
}
.preloader-name {
  font-size: 26px;
  font-weight: 800;
  background: var(--gradient-1);
  -webkit-background-clip: text;
  background-clip: text;
  -webkit-text-fill-color: transparent;
  letter-spacing: -0.5px;
}
.preloader-name span { font-weight: 400; }
.preloader-ring {
  position: absolute;
  top: -18px; left: 50%;
  width: 132px; height: 132px;
  margin-left: -66px;
  border-radius: 50%;
  background: conic-gradient(from 0deg, transparent 0%, var(--primary) 35%, #8b5cf6 60%, transparent 100%);
  -webkit-mask: radial-gradient(farthest-side, transparent calc(100% - 4px), #000 calc(100% - 3px));
  mask: radial-gradient(farthest-side, transparent calc(100% - 4px), #000 calc(100% - 3px));
  animation: spin 1s linear infinite;
}
@keyframes preloaderPop {
  0% { opacity: 0; transform: scale(0.8); }
  100% { opacity: 1; transform: scale(1); }
}
@keyframes preloaderPulse {
  0%, 100% { transform: scale(1); box-shadow: 0 0 50px rgba(99, 102, 241, 0.45); }
  50% { transform: scale(1.06); box-shadow: 0 0 80px rgba(139, 92, 246, 0.6); }
}

/* ============ 3D animated background decorations ============ */
.bg-decor {
  position: fixed;
  inset: 0;
  z-index: 0;
  overflow: hidden;
  pointer-events: none;
  perspective: 1200px;
}
.bg-decor::before {
  content: '';
  position: absolute;
  inset: 0;
  background:
    radial-gradient(1200px 700px at 12% -5%, rgba(99, 102, 241, 0.10), transparent 60%),
    radial-gradient(1000px 600px at 100% 8%, rgba(6, 182, 212, 0.08), transparent 55%),
    radial-gradient(900px 700px at 50% 110%, rgba(139, 92, 246, 0.10), transparent 60%),
    radial-gradient(600px 400px at 85% 75%, rgba(245, 158, 11, 0.06), transparent 55%);
}

/* Gradient blobs (animated gradient mesh) */
.deco-blob {
  position: absolute;
  border-radius: 50%;
  filter: blur(70px);
  animation: blobDrift 26s ease-in-out infinite;
  opacity: 0.5;
}
.deco-blob-1 { width: 420px; height: 420px; top: 22%; left: -6%; background: conic-gradient(from 120deg, rgba(99, 102, 241, 0.35), rgba(6, 182, 212, 0.25), rgba(139, 92, 246, 0.35), rgba(99, 102, 241, 0.35)); }
.deco-blob-2 { width: 380px; height: 380px; top: 48%; right: -8%; background: conic-gradient(from 240deg, rgba(245, 158, 11, 0.22), rgba(236, 72, 153, 0.28), rgba(99, 102, 241, 0.3), rgba(245, 158, 11, 0.22)); animation-duration: 32s; animation-delay: -8s; }
.deco-blob-3 { width: 320px; height: 320px; bottom: 4%; left: 40%; background: conic-gradient(from 0deg, rgba(139, 92, 246, 0.28), rgba(6, 182, 212, 0.2), rgba(99, 102, 241, 0.3), rgba(139, 92, 246, 0.28)); animation-duration: 38s; animation-delay: -16s; }
@keyframes blobDrift {
  0%, 100% { transform: translate(0, 0) scale(1); }
  25% { transform: translate(50px, -40px) scale(1.06); }
  50% { transform: translate(-30px, 30px) scale(0.94); }
  75% { transform: translate(70px, 20px) scale(1.03); }
}

/* 3D tumbling cubes */
.deco-cube {
  position: absolute;
  width: 64px;
  height: 64px;
  transform-style: preserve-3d;
  opacity: 0.55;
  animation: cubeFloat 26s linear infinite;
  top: 16%;
  left: 7%;
}
.deco-cube-2 {
  width: 36px;
  height: 36px;
  background: transparent;
  opacity: 0.6;
  top: 64%;
  right: 9%;
  left: auto;
  animation-duration: 20s;
  animation-delay: -6s;
}
.deco-cube-2 .face {
  background: linear-gradient(135deg, rgba(6, 182, 212, 0.6), rgba(99, 102, 241, 0.4));
  border-radius: 4px;
}
.deco-cube .face {
  position: absolute;
  inset: 0;
  border-radius: 8px;
  background: linear-gradient(135deg, rgba(99, 102, 241, 0.55), rgba(139, 92, 246, 0.35));
  border: 1.5px solid rgba(255, 255, 255, 0.6);
  box-shadow: inset 0 0 18px rgba(99, 102, 241, 0.45);
  backface-visibility: visible;
}
.deco-cube .face:nth-child(1) { transform: translateZ(32px); }
.deco-cube .face:nth-child(2) { transform: rotateY(180deg) translateZ(32px); }
.deco-cube .face:nth-child(3) { transform: rotateY(90deg) translateZ(32px); }
.deco-cube .face:nth-child(4) { transform: rotateY(-90deg) translateZ(32px); }
.deco-cube .face:nth-child(5) { transform: rotateX(90deg) translateZ(32px); }
.deco-cube .face:nth-child(6) { transform: rotateX(-90deg) translateZ(32px); }
.deco-cube-2 .face:nth-child(1) { transform: translateZ(18px); }
.deco-cube-2 .face:nth-child(2) { transform: rotateY(180deg) translateZ(18px); }
.deco-cube-2 .face:nth-child(3) { transform: rotateY(90deg) translateZ(18px); }
.deco-cube-2 .face:nth-child(4) { transform: rotateY(-90deg) translateZ(18px); }
.deco-cube-2 .face:nth-child(5) { transform: rotateX(90deg) translateZ(18px); }
.deco-cube-2 .face:nth-child(6) { transform: rotateX(-90deg) translateZ(18px); }
@keyframes cubeFloat {
  0%   { transform: rotateX(0deg) rotateY(0deg) rotateZ(0deg) translateY(0px); }
  25%  { transform: rotateX(360deg) rotateY(180deg) rotateZ(90deg) translateY(-24px); }
  50%  { transform: rotateX(720deg) rotateY(360deg) rotateZ(180deg) translateY(12px); }
  75%  { transform: rotateX(1080deg) rotateY(540deg) rotateZ(270deg) translateY(-18px); }
  100% { transform: rotateX(1440deg) rotateY(720deg) rotateZ(360deg) translateY(0px); }
}

/* Rotating diamond */
.deco-diamond {
  position: absolute;
  width: 80px;
  height: 80px;
  top: 58%;
  right: 6%;
  transform: rotate(45deg);
  border-radius: 18px;
  background: linear-gradient(135deg, rgba(6, 182, 212, 0.45), rgba(99, 102, 241, 0.3));
  border: 1.5px solid rgba(255, 255, 255, 0.5);
  box-shadow: inset 0 0 22px rgba(6, 182, 212, 0.4);
  opacity: 0.5;
  animation: diamondFloat 18s ease-in-out infinite;
}
@keyframes diamondFloat {
  0%, 100% { transform: rotate(45deg) translateY(0) scale(1); }
  33% { transform: rotate(58deg) translateY(-30px) scale(1.05); }
  66% { transform: rotate(36deg) translateY(18px) scale(0.95); }
}

/* Gradient halo rings */
.deco-ring {
  position: absolute;
  width: 150px;
  height: 150px;
  top: 12%;
  right: 16%;
  border-radius: 50%;
  background: radial-gradient(circle, transparent 56%, rgba(99, 102, 241, 0.6) 58%, rgba(139, 92, 246, 0.5) 74%, rgba(6, 182, 212, 0.4) 88%, transparent 90%);
  filter: blur(1px);
  animation: ringPulse 12s ease-in-out infinite;
}
.deco-ring-2 {
  width: 90px;
  height: 90px;
  top: auto;
  right: auto;
  bottom: 14%;
  left: 12%;
  background: radial-gradient(circle, transparent 54%, rgba(245, 158, 11, 0.55) 56%, rgba(249, 115, 22, 0.45) 72%, transparent 88%);
  animation-duration: 15s;
  animation-delay: -5s;
}
@keyframes ringPulse {
  0%, 100% { transform: scale(1) rotate(0deg); }
  50% { transform: scale(1.18) rotate(12deg); }
}

[data-theme="dark"] .deco-blob { opacity: 0.35; }
[data-theme="dark"] .deco-cube,
[data-theme="dark"] .deco-diamond,
[data-theme="dark"] .deco-ring { filter: brightness(0.85); }

@media (prefers-reduced-motion: reduce) {
  .bg-decor { display: none; }
}

/* ============ Expandable Text (Read More) ============ */
.expandable-text {
  position: relative;
  overflow: hidden;
  transition: max-height 0.4s ease;
  cursor: pointer;
}
.expandable-text.collapsed {
  max-height: 120px;
}
.expandable-text.expanded {
  max-height: none;
}
.expandable-text::after {
  content: '';
  position: absolute;
  bottom: 0;
  left: 0;
  right: 0;
  height: 50px;
  background: linear-gradient(transparent, var(--bg));
  pointer-events: none;
  transition: opacity 0.3s ease;
}
.expandable-text.expanded::after {
  opacity: 0;
}
.expandable-text-trigger {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  padding: 8px 16px;
  margin-top: 12px;
  background: var(--primary-light);
  color: var(--primary);
  border: none;
  border-radius: 8px;
  font-size: 13px;
  font-weight: 600;
  cursor: pointer;
  transition: all var(--transition);
  font-family: var(--font);
}
.expandable-text-trigger:hover {
  background: var(--primary);
  color: #fff;
}
.expandable-text-trigger .arrow {
  transition: transform 0.3s ease;
  font-size: 12px;
}
.expandable-text.expanded .expandable-text-trigger .arrow {
  transform: rotate(180deg);
}

/* ============ Freshness Signals ============ */
.freshness-badge {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  padding: 6px 14px;
  background: linear-gradient(135deg, #dcfce7, #bbf7d0);
  color: #166534;
  border-radius: 50px;
  font-size: 12px;
  font-weight: 600;
  margin-bottom: 16px;
  border: 1px solid #86efac;
}
.freshness-badge .pulse-dot {
  width: 8px;
  height: 8px;
  background: #22c55e;
  border-radius: 50%;
  animation: pulse 2s infinite;
}
@keyframes pulse {
  0%, 100% { opacity: 1; transform: scale(1); }
  50% { opacity: 0.6; transform: scale(1.2); }
}
.freshness-date {
  display: flex;
  align-items: center;
  gap: 8px;
  font-size: 13px;
  color: var(--text-muted);
  margin-bottom: 8px;
}
.freshness-date svg {
  width: 14px;
  height: 14px;
  color: #22c55e;
}
.freshness-section {
  background: linear-gradient(135deg, rgba(34, 197, 94, 0.05), rgba(34, 197, 94, 0.02));
  border: 1px solid rgba(34, 197, 94, 0.2);
  border-radius: var(--radius);
  padding: 16px 20px;
  margin: 20px 0;
}
.freshness-section h4 {
  font-size: 14px;
  font-weight: 700;
  color: #166534;
  margin-bottom: 8px;
  display: flex;
  align-items: center;
  gap: 8px;
}
.freshness-section ul {
  list-style: none;
  margin: 0;
  padding: 0;
}
.freshness-section li {
  font-size: 13px;
  color: var(--text-secondary);
  padding: 4px 0;
  display: flex;
  align-items: center;
  gap: 8px;
}
.freshness-section li::before {
  content: '✓';
  color: #22c55e;
  font-weight: 700;
}
[data-theme="dark"] .freshness-badge {
  background: linear-gradient(135deg, rgba(34, 197, 94, 0.15), rgba(34, 197, 94, 0.1));
  color: #86efac;
  border-color: rgba(34, 197, 94, 0.3);
}
[data-theme="dark"] .freshness-section {
  background: rgba(34, 197, 94, 0.08);
  border-color: rgba(34, 197, 94, 0.2);
}
[data-theme="dark"] .freshness-section h4 {
  color: #86efac;
}

/* ============ 3D Mouse Cursor Effect ============ */
.cursor3d {
  position: fixed;
  top: 0;
  left: 0;
  width: 44px;
  height: 44px;
  pointer-events: none;
  z-index: 99999;
  opacity: 0;
  will-change: transform;
}
.cursor3d.cursor3d-show { opacity: 1; }
.cursor3d-glow {
  position: absolute;
  inset: -26px;
  border-radius: 50%;
  background: radial-gradient(circle, rgba(99,102,241,.28), rgba(139,92,246,0) 65%);
  transform: scale(.6);
  transition: transform .3s ease;
  will-change: opacity;
}
.cursor3d:hover .cursor3d-glow,
.cursor3d.cursor3d-hover .cursor3d-glow { transform: scale(1.15); }
.cursor3d.cursor3d-down .cursor3d-glow { transform: scale(.45); }
.cursor3d-ring {
  position: absolute;
  inset: 0;
  transform-style: preserve-3d;
  animation: cursorSpin 14s linear infinite;
  transition: transform .15s ease-out;
}
.cursor3d-ring .cursor3d-face {
  position: absolute;
  inset: 4px;
  border: 2px solid rgba(139, 92, 246, .85);
  border-radius: 12px;
  box-shadow: 0 0 14px rgba(99, 102, 241, .6), inset 0 0 10px rgba(99, 102, 241, .35);
}
.cursor3d-ring .cursor3d-face:nth-child(1) { transform: rotateY(0deg) translateZ(12px); }
.cursor3d-ring .cursor3d-face:nth-child(2) { transform: rotateY(60deg) translateZ(12px); opacity:.25; }
.cursor3d-ring .cursor3d-face:nth-child(3) { transform: rotateY(120deg) translateZ(12px); opacity:.10; }
.cursor3d-ring .cursor3d-face:nth-child(4) { transform: rotateY(180deg) translateZ(12px); opacity:.10; }
.cursor3d-ring .cursor3d-face:nth-child(5) { transform: rotateY(240deg) translateZ(12px); opacity:.10; }
.cursor3d-ring .cursor3d-face:nth-child(6) { transform: rotateY(300deg) translateZ(12px); opacity:.25; }
@keyframes cursorSpin {
  from { transform: rotateX(45deg) rotateY(0deg); }
  to   { transform: rotateX(45deg) rotateY(360deg); }
}
.cursor3d-core {
  position: absolute;
  left: 50%;
  top: 50%;
  width: 6px;
  height: 6px;
  margin: -3px 0 0 -3px;
  border-radius: 50%;
  background: linear-gradient(135deg, #6366f1, #8b5cf6);
  box-shadow: 0 0 12px rgba(139, 92, 246, .9);
}
.cursor3d.cursor3d-hover .cursor3d-core { width: 10px; height: 10px; margin: -5px 0 0 -5px; }
.cursor3d.cursor3d-down .cursor3d-core { width: 4px; height: 4px; margin: -2px 0 0 -2px; }
.cursor3d.cursor3d-hover .cursor3d-ring { animation-duration: 7s; }

@media (prefers-reduced-motion: reduce) {
  .cursor3d { display: none; }
}
.site-stats {
  background: var(--bg-secondary);
  border-top: 1px solid var(--border);
  border-bottom: 1px solid var(--border);
  padding: 28px 0;
  position: relative;
  z-index: 1;
}
.site-stats-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(140px, 1fr));
  gap: 20px;
  text-align: center;
}
.site-stat {
  padding: 8px 12px;
}
.site-stat-icon { font-size: 26px; margin-bottom: 6px; }
.site-stat-num {
  font-size: 30px;
  font-weight: 800;
  letter-spacing: -0.5px;
  background: var(--gradient-1);
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
  background-clip: text;
}
.site-stat-label {
  font-size: 13px;
  color: var(--text-secondary);
  margin-top: 2px;
  font-weight: 600;
  text-transform: uppercase;
  letter-spacing: 0.5px;
}
@media (max-width: 600px) {
  .site-stats-grid { grid-template-columns: 1fr 1fr; }
}
