/* ===== THEME SYSTEM ===== */
:root {
  /* Dark theme (default) */
  --bg: #090e1a;
  --bg-alt: #0d1526;
  --bg-gradient: linear-gradient(180deg, #090e1a 0%, #0d1526 100%);
  --surface: rgba(255, 255, 255, 0.03);
  --panel: rgba(255, 255, 255, 0.03);
  --glass: rgba(13, 21, 38, 0.7);
  --glass-border: rgba(255, 255, 255, 0.08);
  --card: rgba(255, 255, 255, 0.04);
  --card-hover: rgba(255, 255, 255, 0.08);
  --stroke: rgba(255, 255, 255, 0.1);
  --border: rgba(255, 255, 255, 0.1);
  --accent: #00e5c0;
  --accent-hover: #00ffda;
  --accent-glow: rgba(0, 229, 192, 0.4);
  --accent-2: #ffb02e;
  --accent-2-glow: rgba(255, 176, 46, 0.4);
  --text: #eef2f6;
  --text-secondary: #cbd5e1;
  --text-muted: #94a3b8;
  --muted: #94a3b8;
  --error: #ff6b6b;
  --success: #00e5c0;
  --warning: #ffb02e;
  --shadow-sm: 0 4px 12px rgba(0, 0, 0, 0.3);
  --shadow-md: 0 8px 24px rgba(0, 0, 0, 0.4);
  --shadow-lg: 0 20px 60px rgba(0, 0, 0, 0.5);
  --shadow-glow: 0 0 40px var(--accent-glow);
  --radius: 16px;
  --radius-sm: 8px;
  --radius-lg: 24px;
  --radius-full: 9999px;
  --font-sans: 'Space Grotesk', system-ui, sans-serif;
  --font-serif: 'Source Serif 4', serif;
  --transition-fast: 0.15s ease;
  --transition-base: 0.3s ease;
  --transition-slow: 0.5s ease;
  --header-blur: blur(16px);
}

/* Light theme */
[data-theme="light"] {
  --bg: #f8fafc;
  --bg-alt: #f1f5f9;
  --bg-gradient: linear-gradient(180deg, #f8fafc 0%, #f1f5f9 100%);
  --surface: rgba(0, 0, 0, 0.02);
  --panel: rgba(0, 0, 0, 0.03);
  --glass: rgba(255, 255, 255, 0.8);
  --glass-border: rgba(0, 0, 0, 0.08);
  --card: rgba(0, 0, 0, 0.03);
  --card-hover: rgba(0, 0, 0, 0.06);
  --stroke: rgba(0, 0, 0, 0.1);
  --border: rgba(0, 0, 0, 0.1);
  --accent: #00b899;
  --accent-hover: #00d4b0;
  --accent-glow: rgba(0, 184, 153, 0.3);
  --text: #1e293b;
  --text-secondary: #475569;
  --text-muted: #64748b;
  --muted: #64748b;
  --shadow-sm: 0 4px 12px rgba(0, 0, 0, 0.08);
  --shadow-md: 0 8px 24px rgba(0, 0, 0, 0.1);
  --shadow-lg: 0 20px 60px rgba(0, 0, 0, 0.15);
}

/* Theme transition */
body,
body * {
  transition: background-color var(--transition-base),
    border-color var(--transition-base),
    color var(--transition-fast);
}

* {
  box-sizing: border-box;
}

body {
  margin: 0;
  background-color: var(--bg);
  background-image:
    radial-gradient(circle at 15% 15%, rgba(0, 229, 192, 0.08) 0%, transparent 40%),
    radial-gradient(circle at 85% 10%, rgba(255, 176, 46, 0.08) 0%, transparent 40%),
    radial-gradient(circle at 50% 50%, rgba(13, 21, 38, 0.5) 0%, transparent 100%);
  background-attachment: fixed;
  color: var(--text);
  font-family: var(--font-sans);
  line-height: 1.6;
  -webkit-font-smoothing: antialiased;
  overflow-x: hidden;
}

/* Animations */
@keyframes fadeInUp {
  from {
    opacity: 0;
    transform: translateY(20px);
  }

  to {
    opacity: 1;
    transform: translateY(0);
  }
}

@keyframes float {
  0% {
    transform: translateY(0px);
  }

  50% {
    transform: translateY(-10px);
  }

  100% {
    transform: translateY(0px);
  }
}

@keyframes pulse-glow {
  0% {
    box-shadow: 0 0 0 0 rgba(0, 229, 192, 0.4);
  }

  70% {
    box-shadow: 0 0 0 10px rgba(0, 229, 192, 0);
  }

  100% {
    box-shadow: 0 0 0 0 rgba(0, 229, 192, 0);
  }
}

@keyframes slideInRight {
  from {
    opacity: 0;
    transform: translateX(100%);
  }

  to {
    opacity: 1;
    transform: translateX(0);
  }
}

@keyframes slideOutRight {
  from {
    opacity: 1;
    transform: translateX(0);
  }

  to {
    opacity: 0;
    transform: translateX(100%);
  }
}

@keyframes shimmer {
  0% {
    background-position: -200% 0;
  }

  100% {
    background-position: 200% 0;
  }
}

@keyframes scaleIn {
  from {
    opacity: 0;
    transform: scale(0.9);
  }

  to {
    opacity: 1;
    transform: scale(1);
  }
}

@keyframes spin {
  from {
    transform: rotate(0deg);
  }

  to {
    transform: rotate(360deg);
  }
}

/* Reading Progress Bar */
.reading-progress {
  position: fixed;
  top: 0;
  left: 0;
  width: 0%;
  height: 3px;
  background: linear-gradient(90deg, var(--accent), var(--accent-2));
  z-index: 9999;
  transition: width 0.1s linear;
}

/* Theme Toggle Button */
.theme-toggle {
  display: flex;
  align-items: center;
  justify-content: center;
  width: 40px;
  height: 40px;
  padding: 0;
  background: var(--surface);
  border: 1px solid var(--stroke);
  border-radius: var(--radius-full);
  cursor: pointer;
  transition: all var(--transition-base);
  color: var(--text);
}

.theme-toggle:hover {
  background: var(--card-hover);
  transform: rotate(15deg);
}

.theme-toggle svg {
  width: 20px;
  height: 20px;
  transition: transform var(--transition-base);
}

.theme-toggle .sun-icon {
  display: none;
}

.theme-toggle .moon-icon {
  display: block;
}

[data-theme="light"] .theme-toggle .sun-icon {
  display: block;
}

[data-theme="light"] .theme-toggle .moon-icon {
  display: none;
}

/* Search Bar Styles */
.search-toggle {
  display: flex;
  align-items: center;
  justify-content: center;
  width: 40px;
  height: 40px;
  padding: 0;
  background: var(--surface);
  border: 1px solid var(--stroke);
  border-radius: var(--radius-full);
  cursor: pointer;
  transition: all var(--transition-base);
  color: var(--text);
}

.search-toggle:hover {
  background: var(--card-hover);
  border-color: var(--accent);
}

.search-toggle svg {
  width: 18px;
  height: 18px;
}

.search-overlay {
  position: fixed;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  background: rgba(0, 0, 0, 0.8);
  backdrop-filter: blur(8px);
  -webkit-backdrop-filter: blur(8px);
  z-index: 9998;
  opacity: 0;
  visibility: hidden;
  transition: all var(--transition-base);
}

.search-overlay.active {
  opacity: 1;
  visibility: visible;
}

.search-modal {
  position: fixed;
  top: 20%;
  left: 50%;
  transform: translateX(-50%) scale(0.95);
  width: min(600px, 90vw);
  background: var(--glass);
  border: 1px solid var(--glass-border);
  border-radius: var(--radius-lg);
  padding: 24px;
  z-index: 9999;
  opacity: 0;
  visibility: hidden;
  transition: all var(--transition-base);
  backdrop-filter: blur(20px);
  -webkit-backdrop-filter: blur(20px);
}

.search-modal.active {
  opacity: 1;
  visibility: visible;
  transform: translateX(-50%) scale(1);
}

.search-input-wrapper {
  position: relative;
  display: flex;
  align-items: center;
  gap: 12px;
}

.search-input-wrapper svg {
  position: absolute;
  left: 16px;
  width: 20px;
  height: 20px;
  color: var(--text-muted);
}

.search-input {
  width: 100%;
  padding: 16px 16px 16px 48px;
  background: var(--surface);
  border: 1px solid var(--stroke);
  border-radius: var(--radius);
  color: var(--text);
  font-size: 1.1rem;
  font-family: var(--font-sans);
  transition: all var(--transition-base);
}

.search-input:focus {
  outline: none;
  border-color: var(--accent);
  box-shadow: 0 0 0 3px var(--accent-glow);
}

.search-input::placeholder {
  color: var(--text-muted);
}

.search-results {
  margin-top: 16px;
  max-height: 400px;
  overflow-y: auto;
}

.search-result-item {
  display: block;
  padding: 16px;
  background: var(--surface);
  border: 1px solid var(--stroke);
  border-radius: var(--radius-sm);
  margin-bottom: 8px;
  text-decoration: none;
  transition: all var(--transition-base);
}

.search-result-item:hover {
  background: var(--card-hover);
  border-color: var(--accent);
  transform: translateX(4px);
}

.search-result-item h4 {
  margin: 0 0 4px;
  color: var(--text);
  font-size: 1rem;
}

.search-result-item p {
  margin: 0;
  color: var(--text-muted);
  font-size: 0.9rem;
}

.search-shortcut {
  display: flex;
  justify-content: center;
  gap: 4px;
  margin-top: 16px;
  color: var(--text-muted);
  font-size: 0.85rem;
}

.search-shortcut kbd {
  padding: 4px 8px;
  background: var(--surface);
  border: 1px solid var(--stroke);
  border-radius: 4px;
  font-family: var(--font-sans);
  font-size: 0.75rem;
}

a {
  color: var(--accent);
  text-decoration: none;
}

a:hover {
  color: #7df3de;
}

img {
  max-width: 100%;
  display: block;
}

.container {
  width: min(1400px, 96vw);
  margin: 0 auto;
}

/* Container large pour layout avec sidebar */
.container:has(.content-with-sidebar) {
  width: min(1400px, 96vw);
}

.narrow {
  width: min(800px, 92vw);
}

.site-header {
  position: sticky;
  top: 0;
  z-index: 1000;
  backdrop-filter: blur(16px);
  -webkit-backdrop-filter: blur(16px);
  background: rgba(9, 14, 26, 0.85);
  border-bottom: 1px solid var(--stroke);
  transition: all 0.3s ease;
}

.topbar {
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding: 8px 4vw;
  font-size: 0.9rem;
  color: var(--muted);
  background: rgba(255, 255, 255, 0.02);
  border-bottom: 1px solid var(--stroke);
}

.navbar {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 16px 4vw;
  position: relative;
}

.brand {
  color: #fff;
  font-weight: 700;
  letter-spacing: -0.01em;
  font-size: 1.1rem;
}

.nav-links {
  display: flex;
  gap: 18px;
  list-style: none;
  margin: 0;
  padding: 0;
}

.nav-links a {
  color: var(--text);
  padding: 8px 10px;
  border-radius: 8px;
  transition: background 0.2s ease;
}

.nav-links a[aria-current="page"] {
  background: var(--accent);
  color: #041019;
}

.nav-links a:hover {
  background: rgba(255, 255, 255, 0.05);
}

.nav-toggle {
  display: none;
  flex-direction: column;
  gap: 5px;
  background: none;
  border: 1px solid var(--stroke);
  padding: 8px;
  border-radius: 10px;
  cursor: pointer;
}

.nav-toggle span {
  width: 24px;
  height: 2px;
  background: var(--text);
  display: block;
}

.hero {
  padding: 80px 0 40px;
}

.hero .container {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(280px, 1fr));
  gap: 28px;
  align-items: center;
}

.hero-content h1 {
  font-size: clamp(2.5rem, 5vw, 4rem);
  margin: 20px 0;
  line-height: 1.1;
  background: linear-gradient(135deg, #ffffff 0%, #b3b3b3 100%);
  background-clip: text;
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
  animation: fadeInUp 0.8s ease-out forwards;
}

.hero-content .lead {
  color: var(--text-muted);
  font-size: 1.15rem;
  max-width: 600px;
  margin-bottom: 32px;
  animation: fadeInUp 0.8s ease-out 0.2s forwards;
  opacity: 0;
}

.eyebrow {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  padding: 8px 16px;
  background: rgba(0, 229, 192, 0.1);
  border: 1px solid rgba(0, 229, 192, 0.2);
  border-radius: 999px;
  color: var(--accent);
  text-transform: uppercase;
  letter-spacing: 0.08em;
  font-size: 0.75rem;
  font-weight: 700;
  animation: fadeInUp 0.8s ease-out forwards;
}

.hero-card {
  background: linear-gradient(145deg, rgba(255, 255, 255, 0.05) 0%, rgba(255, 255, 255, 0.01) 100%);
  border: 1px solid var(--glass-border);
  backdrop-filter: blur(20px);
  -webkit-backdrop-filter: blur(20px);
  border-radius: var(--radius);
  padding: 32px;
  box-shadow: var(--shadow-lg);
  animation: float 6s ease-in-out infinite;
}

.hero-card h2 {
  margin-top: 0;
}

.hero-card ul {
  padding-left: 18px;
  color: var(--muted);
}

.hero-actions {
  display: flex;
  gap: 16px;
  flex-wrap: wrap;
  margin-top: 24px;
  animation: fadeInUp 0.8s ease-out 0.4s forwards;
  opacity: 0;
}

.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 10px;
  padding: 14px 28px;
  border-radius: 12px;
  border: 1px solid transparent;
  font-weight: 600;
  font-size: 1rem;
  color: var(--text);
  cursor: pointer;
  transition: all 0.3s cubic-bezier(0.25, 0.8, 0.25, 1);
  position: relative;
  overflow: hidden;
}

.btn.primary {
  background: linear-gradient(135deg, var(--accent), #00c4b4);
  color: #041019;
  box-shadow: 0 4px 20px var(--accent-glow);
}

.btn.primary:hover {
  transform: translateY(-2px);
  box-shadow: 0 8px 30px var(--accent-glow);
}

.btn.ghost {
  background: transparent;
}

.btn:hover {
  transform: translateY(-1px);
}

.section {
  padding: 70px 0;
}

.section.alt {
  background: rgba(255, 255, 255, 0.02);
  border-top: 1px solid var(--stroke);
  border-bottom: 1px solid var(--stroke);
}

.section-head {
  margin-bottom: 28px;
}

.section-head p {
  color: var(--muted);
  margin: 6px 0 0;
}

.card-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(240px, 1fr));
  gap: 18px;
}

.card {
  background: var(--card);
  border: 1px solid var(--stroke);
  border-radius: var(--radius);
  padding: 18px;
  box-shadow: var(--shadow);
}

.card h3 {
  margin-top: 0;
}

.card p {
  color: var(--muted);
}

.table-wrapper {
  overflow-x: auto;
  border-radius: var(--radius);
  border: 1px solid var(--stroke);
}

.table-wrapper table {
  width: 100%;
  border-collapse: collapse;
  background: var(--panel);
}

.table-wrapper th,
.table-wrapper td {
  padding: 14px 12px;
  border-bottom: 1px solid var(--stroke);
  text-align: left;
}

.table-wrapper th {
  color: var(--muted);
  font-weight: 600;
}

.list-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(260px, 1fr));
  gap: 16px;
}

.list-item {
  background: var(--panel);
  border: 1px solid var(--stroke);
  border-radius: var(--radius);
  padding: 16px;
}

.text-link {
  color: var(--accent-2);
  font-weight: 600;
}

.ads {
  padding: 50px 0;
}

.ad-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(220px, 1fr));
  gap: 14px;
}

.ad-slot {
  border: 1px dashed var(--stroke);
  border-radius: var(--radius);
  padding: 32px;
  text-align: center;
  color: var(--muted);
  background: var(--panel);
}

.page-hero {
  padding: 70px 0 40px;
}

.page {
  padding-bottom: 40px;
}

.pill-list {
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
  padding: 0;
  list-style: none;
}

.pill-list li {
  padding: 10px 14px;
  border-radius: 999px;
  border: 1px solid var(--stroke);
  background: rgba(255, 255, 255, 0.03);
}

.stack {
  margin-bottom: 18px;
  background: var(--panel);
  border: 1px solid var(--stroke);
  border-radius: var(--radius);
  padding: 16px;
}

.notice {
  color: var(--muted);
  font-size: 0.95rem;
}

.cta-note {
  margin-top: 14px;
  padding: 14px 16px;
  border-radius: var(--radius);
  border: 1px solid var(--stroke);
  background: rgba(245, 165, 36, 0.08);
}

.faq {
  display: flex;
  flex-direction: column;
  gap: 10px;
}

.faq-item {
  border: 1px solid var(--stroke);
  border-radius: var(--radius);
  background: var(--panel);
}

.faq-question {
  width: 100%;
  padding: 14px 16px;
  background: none;
  border: none;
  color: var(--text);
  font-weight: 600;
  text-align: left;
  cursor: pointer;
}

.faq-answer {
  display: none;
  padding: 0 16px 14px;
  color: var(--muted);
}

.faq-item.open .faq-answer {
  display: block;
}

.faq-item.open .faq-question {
  color: var(--accent);
}

.forum-list {
  display: grid;
  gap: 12px;
}

.forum-topic {
  padding: 16px;
  border: 1px solid var(--stroke);
  border-radius: var(--radius);
  background: var(--panel);
}

.forum-topic .meta {
  color: var(--muted);
  font-size: 0.9rem;
}

.contact-form {
  background: var(--panel);
  border: 1px solid var(--stroke);
  border-radius: var(--radius);
  padding: 24px;
  box-shadow: var(--shadow);
}

.field {
  display: flex;
  flex-direction: column;
  gap: 6px;
  margin-bottom: 14px;
}

label {
  font-weight: 600;
}

input,
textarea {
  width: 100%;
  padding: 12px;
  border-radius: 10px;
  border: 1px solid var(--stroke);
  background: rgba(255, 255, 255, 0.03);
  color: var(--text);
  font-family: var(--font-sans);
}

.error {
  color: #ff8a8a;
  min-height: 18px;
}

.form-status {
  margin-top: 10px;
  color: var(--accent);
}

.site-footer {
  border-top: 1px solid var(--stroke);
  background: rgba(5, 9, 17, 0.9);
  padding: 40px 0 20px;
}

.footer-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(220px, 1fr));
  gap: 16px;
}

.site-footer ul {
  list-style: none;
  padding: 0;
  margin: 0;
  display: grid;
  gap: 8px;
}

.site-footer h3,
.site-footer h4 {
  margin: 0 0 10px;
}

.site-footer p {
  color: var(--muted);
}

.footer-bottom {
  border-top: 1px solid var(--stroke);
  margin-top: 20px;
  padding-top: 14px;
  text-align: center;
  color: var(--muted);
}

@media (max-width: 960px) {
  .nav-toggle {
    display: flex;
  }

  .nav-links {
    position: absolute;
    top: 100%;
    right: 4vw;
    background: rgba(13, 21, 38, 0.97);
    border: 1px solid var(--stroke);
    border-radius: var(--radius);
    padding: 12px;
    flex-direction: column;
    gap: 10px;
    min-width: 200px;
    display: none;
  }

  .nav-links.open {
    display: flex;
  }

  .hero {
    padding: 60px 0 30px;
  }
}

@media (max-width: 640px) {
  .topbar {
    display: none;
  }

  .hero-actions {
    width: 100%;
  }

  .btn {
    width: 100%;
    text-align: center;
  }
}

/* Articles Grid */
.articles-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(320px, 1fr));
  gap: 24px;
  margin-bottom: 40px;
}

.article-card {
  background: var(--card);
  border: 1px solid var(--stroke);
  border-radius: var(--radius);
  padding: 24px;
  transition: all 0.4s cubic-bezier(0.25, 0.8, 0.25, 1);
  display: flex;
  flex-direction: column;
  position: relative;
  overflow: hidden;
  height: 100%;
}

.article-card::before {
  content: '';
  position: absolute;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  background: radial-gradient(800px circle at var(--mouse-x) var(--mouse-y), rgba(255, 255, 255, 0.06), transparent 40%);
  opacity: 0;
  transition: opacity 0.5s;
  pointer-events: none;
}

.article-card:hover::before {
  opacity: 1;
}

.article-card:hover {
  background: rgba(255, 255, 255, 0.07);
  border-color: rgba(255, 255, 255, 0.2);
  transform: translateY(-6px);
  box-shadow: 0 12px 40px rgba(0, 0, 0, 0.4);
}

.article-card h3 {
  font-size: 1.4rem;
  font-weight: 700;
  color: #fff;
  margin: 0 0 12px 0;
  line-height: 1.3;
}

.article-card p {
  color: var(--text-muted);
  margin: 0 0 24px 0;
  flex-grow: 1;
  font-size: 1rem;
  line-height: 1.6;
}

.card-link {
  color: var(--accent);
  font-weight: 600;
  display: inline-flex;
  align-items: center;
  gap: 8px;
  transition: all 0.2s ease;
  margin-top: auto;
}

.card-link i {
  transition: transform 0.2s;
}

.card-link:hover i {
  transform: translateX(4px);
}

.card-image {
  width: 100%;
  height: 220px;
  border-radius: 12px;
  margin-bottom: 20px;
  object-fit: cover;
  transition: transform 0.5s ease;
}

.article-card:hover .card-image {
  transform: scale(1.03);
}

.article-image {
  width: 100%;
  height: auto;
  border-radius: var(--radius);
  border: 1px solid var(--stroke);
  margin-bottom: 2rem;
  box-shadow: var(--shadow-sm);
}

.card-link:hover {
  color: #7df3de;
}

@media (max-width: 960px) {
  .articles-grid {
    grid-template-columns: repeat(auto-fit, minmax(280px, 1fr));
    gap: 20px;
  }

  .article-card {
    padding: 24px;
  }
}

@media (max-width: 640px) {
  .articles-grid {
    grid-template-columns: 1fr;
    gap: 16px;
  }

  .article-card {
    padding: 20px;
  }

  .article-card h3 {
    font-size: 1.1rem;
  }
}

/* Comparison Tables */
.comparison-table {
  width: 100%;
  border-collapse: collapse;
  background: var(--panel);
  border-radius: var(--radius);
  overflow: hidden;
  margin: 1.5rem 0;
}

.comparison-table th,
.comparison-table td {
  padding: 14px 16px;
  border-bottom: 1px solid var(--stroke);
  text-align: left;
}

.comparison-table th {
  background: rgba(0, 198, 167, 0.1);
  color: var(--accent);
  font-weight: 600;
}

.comparison-table tr:last-child td {
  border-bottom: none;
}

.comparison-table tr:hover {
  background: rgba(255, 255, 255, 0.03);
}

@media (max-width: 640px) {
  .comparison-table {
    font-size: 0.9rem;
  }

  .comparison-table th,
  .comparison-table td {
    padding: 10px 12px;
  }
}

/* Smooth scroll behavior */
html {
  scroll-behavior: smooth;
}

/* Focus states for accessibility */
a:focus,
button:focus {
  outline: 2px solid var(--accent);
  outline-offset: 2px;
}

/* Print styles */
@media print {

  .site-header,
  .site-footer,
  .hero-actions,
  .nav-toggle {
    display: none !important;
  }

  body {
    background: white;
    color: black;
  }
}

/* ===== LIGHT MODE HEADER ===== */
[data-theme="light"] .site-header {
  background: rgba(248, 250, 252, 0.9);
}

[data-theme="light"] .topbar {
  background: rgba(0, 0, 0, 0.02);
}

[data-theme="light"] .brand {
  color: var(--text);
}

[data-theme="light"] .nav-links a {
  color: var(--text);
}

[data-theme="light"] .nav-links a[aria-current="page"] {
  background: var(--accent);
  color: #fff;
}

[data-theme="light"] body {
  background-image:
    radial-gradient(circle at 15% 15%, rgba(0, 184, 153, 0.08) 0%, transparent 40%),
    radial-gradient(circle at 85% 10%, rgba(255, 176, 46, 0.08) 0%, transparent 40%),
    radial-gradient(circle at 50% 50%, rgba(241, 245, 249, 0.5) 0%, transparent 100%);
}

/* ===== MODERN FOOTER ===== */
.site-footer {
  border-top: 1px solid var(--stroke);
  background: linear-gradient(180deg, var(--bg-alt) 0%, var(--bg) 100%);
  padding: 60px 0 30px;
  position: relative;
  overflow: hidden;
}

.site-footer::before {
  content: '';
  position: absolute;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  background:
    radial-gradient(ellipse at 20% 50%, rgba(0, 229, 192, 0.05) 0%, transparent 50%),
    radial-gradient(ellipse at 80% 50%, rgba(255, 176, 46, 0.05) 0%, transparent 50%);
  pointer-events: none;
}

.footer-grid {
  display: grid;
  grid-template-columns: 2fr 1fr 1fr 1fr;
  gap: 40px;
  position: relative;
  z-index: 1;
}

.footer-brand {
  max-width: 280px;
}

.footer-brand h3 {
  font-size: 1.5rem;
  margin: 0 0 16px;
  background: linear-gradient(135deg, var(--accent) 0%, var(--accent-2) 100%);
  background-clip: text;
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
}

.footer-brand p {
  color: var(--text-muted);
  font-size: 0.95rem;
  line-height: 1.6;
  margin: 0 0 20px;
}

.footer-social {
  display: flex;
  gap: 12px;
}

.footer-social a {
  display: flex;
  align-items: center;
  justify-content: center;
  width: 40px;
  height: 40px;
  background: var(--surface);
  border: 1px solid var(--stroke);
  border-radius: var(--radius-full);
  color: var(--text-muted);
  transition: all var(--transition-base);
}

.footer-social a:hover {
  background: var(--accent);
  border-color: var(--accent);
  color: #000;
  transform: translateY(-3px);
}

.footer-social svg {
  width: 18px;
  height: 18px;
}

.site-footer h4 {
  font-size: 1rem;
  margin: 0 0 20px;
  color: var(--text);
  position: relative;
  padding-bottom: 12px;
}

.site-footer h4::after {
  content: '';
  position: absolute;
  bottom: 0;
  left: 0;
  width: 30px;
  height: 2px;
  background: linear-gradient(90deg, var(--accent), transparent);
}

.site-footer ul {
  list-style: none;
  padding: 0;
  margin: 0;
  display: grid;
  gap: 12px;
}

.site-footer ul a {
  color: var(--text-muted);
  font-size: 0.95rem;
  transition: all var(--transition-fast);
  display: inline-flex;
  align-items: center;
  gap: 8px;
}

.site-footer ul a:hover {
  color: var(--accent);
  transform: translateX(4px);
}

.footer-newsletter {
  background: var(--surface);
  border: 1px solid var(--stroke);
  border-radius: var(--radius);
  padding: 20px;
  margin-top: 10px;
}

.footer-newsletter p {
  font-size: 0.9rem;
  margin: 0 0 12px;
  color: var(--text-muted);
}

.footer-newsletter-form {
  display: flex;
  gap: 8px;
}

.footer-newsletter-form input {
  flex: 1;
  padding: 10px 14px;
  background: var(--bg);
  border: 1px solid var(--stroke);
  border-radius: var(--radius-sm);
  color: var(--text);
  font-size: 0.9rem;
}

.footer-newsletter-form button {
  padding: 10px 16px;
  background: var(--accent);
  border: none;
  border-radius: var(--radius-sm);
  color: #000;
  font-weight: 600;
  cursor: pointer;
  transition: all var(--transition-base);
}

.footer-newsletter-form button:hover {
  background: var(--accent-hover);
  transform: translateY(-2px);
}

.footer-bottom {
  border-top: 1px solid var(--stroke);
  margin-top: 40px;
  padding-top: 24px;
  display: flex;
  justify-content: space-between;
  align-items: center;
  flex-wrap: wrap;
  gap: 16px;
  position: relative;
  z-index: 1;
}

.footer-bottom p {
  margin: 0;
  color: var(--text-muted);
  font-size: 0.9rem;
}

.footer-links {
  display: flex;
  gap: 24px;
}

.footer-links a {
  color: var(--text-muted);
  font-size: 0.9rem;
  transition: color var(--transition-fast);
}

.footer-links a:hover {
  color: var(--accent);
}

@media (max-width: 960px) {
  .footer-grid {
    grid-template-columns: 1fr 1fr;
    gap: 32px;
  }

  .footer-brand {
    grid-column: 1 / -1;
    max-width: 100%;
    text-align: center;
  }

  .footer-social {
    justify-content: center;
  }
}

@media (max-width: 640px) {
  .footer-grid {
    grid-template-columns: 1fr;
    text-align: center;
  }

  .site-footer h4::after {
    left: 50%;
    transform: translateX(-50%);
  }

  .footer-bottom {
    flex-direction: column;
    text-align: center;
  }

  .footer-links {
    justify-content: center;
  }
}

/* ===== IMPROVED MOBILE MENU ===== */
@media (max-width: 960px) {
  .nav-links {
    position: fixed;
    top: 0;
    right: -100%;
    width: min(320px, 80vw);
    height: 100vh;
    background: var(--glass);
    backdrop-filter: blur(20px);
    -webkit-backdrop-filter: blur(20px);
    border-left: 1px solid var(--glass-border);
    padding: 80px 24px 24px;
    flex-direction: column;
    gap: 0;
    z-index: 999;
    transition: right 0.4s cubic-bezier(0.16, 1, 0.3, 1);
    box-shadow: -10px 0 40px rgba(0, 0, 0, 0.3);
  }

  .nav-links.open {
    right: 0;
    display: flex;
  }

  .nav-links li {
    opacity: 0;
    transform: translateX(20px);
    transition: all 0.3s ease;
  }

  .nav-links.open li {
    opacity: 1;
    transform: translateX(0);
  }

  .nav-links.open li:nth-child(1) {
    transition-delay: 0.1s;
  }

  .nav-links.open li:nth-child(2) {
    transition-delay: 0.15s;
  }

  .nav-links.open li:nth-child(3) {
    transition-delay: 0.2s;
  }

  .nav-links.open li:nth-child(4) {
    transition-delay: 0.25s;
  }

  .nav-links.open li:nth-child(5) {
    transition-delay: 0.3s;
  }

  .nav-links.open li:nth-child(6) {
    transition-delay: 0.35s;
  }

  .nav-links.open li:nth-child(7) {
    transition-delay: 0.4s;
  }

  .nav-links.open li:nth-child(8) {
    transition-delay: 0.45s;
  }

  .nav-links a {
    display: block;
    padding: 16px 0;
    font-size: 1.1rem;
    border-bottom: 1px solid var(--stroke);
  }

  .nav-links li:last-child a {
    border-bottom: none;
  }

  /* Mobile menu backdrop */
  .nav-backdrop {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: rgba(0, 0, 0, 0.6);
    backdrop-filter: blur(4px);
    -webkit-backdrop-filter: blur(4px);
    z-index: 998;
    opacity: 0;
    visibility: hidden;
    transition: all var(--transition-base);
  }

  .nav-backdrop.active {
    opacity: 1;
    visibility: visible;
  }

  /* Hamburger animation */
  .nav-toggle {
    z-index: 1000;
  }

  .nav-toggle.active span:nth-child(1) {
    transform: rotate(45deg) translate(5px, 5px);
  }

  .nav-toggle.active span:nth-child(2) {
    opacity: 0;
  }

  .nav-toggle.active span:nth-child(3) {
    transform: rotate(-45deg) translate(5px, -5px);
  }

  .nav-toggle span {
    transition: all 0.3s ease;
  }
}

/* ===== ARTICLE PAGE ENHANCEMENTS ===== */
.article-hero {
  position: relative;
  padding: 100px 0 60px;
  background: linear-gradient(135deg, var(--bg) 0%, var(--bg-alt) 100%);
  overflow: hidden;
}

.article-hero::before {
  content: '';
  position: absolute;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  background:
    radial-gradient(ellipse at 30% 30%, rgba(0, 229, 192, 0.1) 0%, transparent 50%),
    radial-gradient(ellipse at 70% 70%, rgba(255, 176, 46, 0.1) 0%, transparent 50%);
  pointer-events: none;
}

.article-hero .container {
  position: relative;
  z-index: 1;
}

.article-meta {
  display: flex;
  align-items: center;
  gap: 16px;
  margin-bottom: 20px;
  flex-wrap: wrap;
}

.article-meta-item {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  padding: 8px 14px;
  background: var(--surface);
  border: 1px solid var(--stroke);
  border-radius: var(--radius-full);
  font-size: 0.85rem;
  color: var(--text-muted);
}

.article-meta-item svg {
  width: 14px;
  height: 14px;
}

.article-content {
  padding: 60px 0;
}

.article-content h2 {
  font-size: 1.8rem;
  margin: 48px 0 20px;
  padding-bottom: 12px;
  border-bottom: 1px solid var(--stroke);
  background: linear-gradient(135deg, var(--text) 0%, var(--text-secondary) 100%);
  background-clip: text;
  -webkit-background-clip: text;
}

.article-content h3 {
  font-size: 1.4rem;
  margin: 36px 0 16px;
  color: var(--text);
}

.article-content p {
  font-size: 1.05rem;
  line-height: 1.8;
  margin-bottom: 20px;
  color: var(--text-secondary);
}

.article-content ul,
.article-content ol {
  margin: 20px 0;
  padding-left: 24px;
}

.article-content li {
  margin-bottom: 10px;
  line-height: 1.7;
  color: var(--text-secondary);
}

.article-content blockquote {
  margin: 32px 0;
  padding: 24px 28px;
  background: var(--surface);
  border-left: 4px solid var(--accent);
  border-radius: 0 var(--radius) var(--radius) 0;
  font-style: italic;
  color: var(--text-muted);
}

/* Form modern styles */
.form-modern {
  background: linear-gradient(135deg, var(--surface) 0%, var(--panel) 100%);
  border: 1px solid var(--stroke);
  border-radius: var(--radius-lg);
  padding: 32px;
  box-shadow: var(--shadow-md);
}

.form-group-modern {
  position: relative;
  margin-bottom: 24px;
}

.form-group-modern input,
.form-group-modern textarea,
.form-group-modern select {
  width: 100%;
  padding: 16px 20px;
  background: var(--bg);
  border: 2px solid var(--stroke);
  border-radius: var(--radius);
  color: var(--text);
  font-size: 1rem;
  font-family: var(--font-sans);
  transition: all var(--transition-base);
}

.form-group-modern input:focus,
.form-group-modern textarea:focus,
.form-group-modern select:focus {
  outline: none;
  border-color: var(--accent);
  box-shadow: 0 0 0 4px var(--accent-glow);
}

.form-group-modern label {
  display: block;
  margin-bottom: 8px;
  font-weight: 600;
  color: var(--text);
}

.form-error-message {
  margin-top: 8px;
  font-size: 0.9rem;
  color: var(--error);
}

.form-success-message {
  padding: 16px;
  background: rgba(0, 229, 192, 0.1);
  border: 1px solid var(--accent);
  border-radius: var(--radius);
  color: var(--accent);
  text-align: center;
}

/* Contact page grid responsive */
@media (max-width: 768px) {
  .contact-grid {
    grid-template-columns: 1fr !important;
    gap: 2rem !important;
  }
}

/* ===== SIDEBAR LAYOUT ===== */
.content-with-sidebar {
  display: grid !important;
  grid-template-columns: minmax(0, 1fr) 320px !important;
  gap: 2.5rem;
  align-items: start;
  width: 100%;
}

.main-content {
  min-width: 0;
  width: 100%;
}

.main-content .articles-grid {
  grid-template-columns: repeat(auto-fill, minmax(260px, 1fr)) !important;
}

.sidebar {
  position: sticky;
  top: 100px;
  display: flex;
  flex-direction: column;
  gap: 1.5rem;
  width: 320px;
  min-width: 320px;
  max-width: 320px;
}

.sidebar-widget {
  background: var(--card);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  padding: 1.5rem;
}

.sidebar-widget h4 {
  margin: 0 0 1rem 0;
  font-size: 1rem;
  color: var(--text);
}

.sidebar-links {
  list-style: none;
  padding: 0;
  margin: 0;
}

.sidebar-links li {
  margin-bottom: 0.75rem;
}

.sidebar-links li:last-child {
  margin-bottom: 0;
}

.sidebar-links a {
  color: var(--text-muted);
  text-decoration: none;
  font-size: 0.9rem;
  transition: color var(--transition-fast);
}

.sidebar-links a:hover {
  color: var(--accent);
}

/* ===== NORDVPN BANNER ===== */
.nordvpn-banner {
  background: linear-gradient(145deg, rgba(70, 135, 255, 0.15) 0%, rgba(0, 229, 192, 0.1) 100%);
  border: 2px solid rgba(70, 135, 255, 0.3);
  text-align: center;
}

.nordvpn-banner .vpn-badge {
  display: inline-block;
  background: linear-gradient(135deg, #4687ff, #00e5c0);
  color: #fff;
  font-size: 0.75rem;
  font-weight: 700;
  padding: 4px 12px;
  border-radius: 20px;
  margin-bottom: 1rem;
  text-transform: uppercase;
  letter-spacing: 0.5px;
}

.nordvpn-banner .vpn-logo {
  margin-bottom: 1rem;
}

.nordvpn-banner .vpn-logo svg {
  width: 120px;
  height: 40px;
}

.nordvpn-banner h3 {
  margin: 0 0 0.75rem 0;
  font-size: 1.2rem;
  color: var(--text);
}

.nordvpn-banner p {
  font-size: 0.9rem;
  color: var(--text-muted);
  margin: 0 0 1rem 0;
  line-height: 1.5;
}

.vpn-features {
  list-style: none;
  padding: 0;
  margin: 0 0 1rem 0;
  text-align: left;
}

.vpn-features li {
  font-size: 0.85rem;
  color: var(--text-secondary);
  margin-bottom: 0.5rem;
  padding-left: 0;
}

.vpn-offer {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 0.75rem;
  margin-bottom: 1rem;
}

.vpn-offer .discount {
  background: #e11d48;
  color: #fff;
  font-size: 0.85rem;
  font-weight: 700;
  padding: 4px 10px;
  border-radius: 6px;
}

.vpn-offer .price {
  font-size: 1.5rem;
  font-weight: 700;
  color: var(--accent);
}

.vpn-cta {
  width: 100%;
  justify-content: center;
  font-size: 1rem;
  padding: 14px 20px;
  margin-bottom: 0.75rem;
  background: linear-gradient(135deg, #4687ff, #00b8d9);
  border: none;
}

.vpn-cta:hover {
  background: linear-gradient(135deg, #5a9aff, #00d4f5);
  transform: translateY(-2px);
  box-shadow: 0 8px 25px rgba(70, 135, 255, 0.4);
}

.nordvpn-banner small {
  display: block;
  font-size: 0.7rem;
  color: var(--text-muted);
  opacity: 0.7;
}

/* Sidebar responsive */
@media (max-width: 1024px) {
  .content-with-sidebar {
    grid-template-columns: 1fr;
  }
  
  .sidebar {
    position: static;
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(280px, 1fr));
    gap: 1rem;
  }
}

@media (max-width: 640px) {
  .sidebar {
    grid-template-columns: 1fr;
  }
}