/*
Theme Name: DevOpsInterview Theme
Theme URI: https://devopsinterview.com
Author: Anmol Gupta
Description: Premium SaaS-style DevOps interview preparation platform.
Version: 2506-10
*/

@import url('https://fonts.googleapis.com/css2?family=Inter:wght@400;500;600;700&family=Plus+Jakarta+Sans:wght@400;500;600;700;800&family=JetBrains+Mono:wght@400;500;600&display=swap');

:root {
  /* SaaS Brand Colors (Stripe/Linear/Vercel inspired) */
  --primary: #6366F1;       /* Indigo/Blurple */
  --primary-hover: #4F46E5;
  --secondary: #10B981;     /* Emerald / Success */
  --accent: #F43F5E;        /* Rose / Alert */
  --warning: #F59E0B;       /* Amber / Warning */
  --white: #FFFFFF;
  
  /* Fonts */
  --font-sans: 'Plus Jakarta Sans', 'Inter', -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, sans-serif;
  --font-mono: 'JetBrains Mono', 'Fira Code', 'Menlo', 'Monaco', monospace;
  
  /* Radius & Shadows */
  --radius-sm: 8px;
  --radius-md: 12px;
  --radius-lg: 20px;
  --radius-xl: 32px;
  
  /* Transitions */
  --transition: all 0.25s cubic-bezier(0.4, 0, 0.2, 1);

  /* Default Dark Theme variables */
  --bg-page: #060913;       /* Deep Space Navy */
  --bg-card: #0F1322;       /* Slate 900 variation */
  --bg-card-hover: #171C30; /* Highlighted card */
  --bg-sidebar: #090D1A;    /* Dark sidebar */
  --text-main: #F3F4F6;     /* Slate 100 - High contrast body */
  --text-muted: #9CA3AF;    /* Slate 400 - Muted metadata */
  --text-headings: #FFFFFF;
  --border: rgba(255, 255, 255, 0.08); /* Clean modern border */
  --border-hover: rgba(255, 255, 255, 0.16);

  --shadow-sm: 0 1px 2px rgba(0, 0, 0, 0.05);
  --shadow-md: 0 4px 6px -1px rgba(0, 0, 0, 0.2), 0 2px 4px -1px rgba(0, 0, 0, 0.1);
  --shadow-lg: 0 10px 25px -3px rgba(0, 0, 0, 0.3), 0 4px 12px -2px rgba(0, 0, 0, 0.2);
  --shadow-glow: 0 0 30px rgba(99, 102, 241, 0.12);

  /* Difficulty Colors */
  --easy-bg: rgba(16, 185, 129, 0.1);
  --easy-text: #34D399;
  --easy-border: rgba(16, 185, 129, 0.2);
  
  --medium-bg: rgba(245, 158, 11, 0.1);
  --medium-text: #FBBF24;
  --medium-border: rgba(245, 158, 11, 0.2);
  
  --hard-bg: rgba(244, 63, 94, 0.1);
  --hard-text: #FB7185;
  --hard-border: rgba(244, 63, 94, 0.2);

  /* Level Badges */
  --level-bg: rgba(99, 102, 241, 0.1);
  --level-text: #A5B4FC;
  --level-border: rgba(99, 102, 241, 0.2);

  /* Code Blocks variables */
  --bg-pre: #0A0D16;
  --text-pre: #F8FAFC;
  --border-pre: rgba(255, 255, 255, 0.08);
  --shadow-pre: 0 4px 12px rgba(0, 0, 0, 0.3);
  --bg-code: rgba(99, 102, 241, 0.1);
  --text-code: #A5B4FC;

  /* Custom inputs & UI */
  --bg-input: rgba(15, 19, 34, 0.6);
  --bg-answer-wrapper: rgba(0, 0, 0, 0.12);
  --bg-hover-subtle: rgba(255, 255, 255, 0.02);
  --medium-gray: var(--text-muted);
  --dot-pattern-opacity: 0.9;
  --dot-color: rgba(255, 255, 255, 0.05);
  --bg-header: rgba(6, 9, 19, 0.85);
  --bg-section-gray: #080B16;
  --hero-gradient: radial-gradient(120% 60% at 50% 0%, rgba(99, 102, 241, 0.12) 0%, rgba(6, 9, 19, 0) 100%);
  --hero-title-gradient: linear-gradient(135deg, var(--white) 30%, #94A3B8 100%);
  --stat-number-gradient: linear-gradient(135deg, var(--white) 30%, var(--primary) 100%);
  
  /* CTA Box Variables */
  --bg-cta: #0A0F1D;
  --bg-cta-gradient: radial-gradient(circle at 50% 0%, rgba(99, 102, 241, 0.15) 0%, rgba(15, 23, 42, 0) 100%);
  --text-cta: #FFFFFF;
}

html[data-theme="light"] {
  /* Light Theme Specific Overrides */
  --bg-page: #F3F4F7;       /* Soft warm white / light blue-gray */
  --bg-card: #FFFFFF;       /* Pure white card */
  --bg-card-hover: #F1F3F9; /* Subtle highlight hover */
  --bg-sidebar: #F1F3F9;    /* Light sidebar */
  --text-main: #334155;     /* Slate 700 - high contrast body */
  --text-muted: #64748B;    /* Slate 500 - muted metadata */
  --text-headings: #0F172A; /* Slate 900 for high-contrast headings */
  --border: rgba(15, 23, 42, 0.08); /* Soft slate border */
  --border-hover: rgba(15, 23, 42, 0.16);
  
  --shadow-sm: 0 1px 2px rgba(15, 23, 42, 0.05);
  --shadow-md: 0 4px 12px rgba(15, 23, 42, 0.06), 0 1px 3px rgba(15, 23, 42, 0.04);
  --shadow-lg: 0 16px 36px rgba(15, 23, 42, 0.08), 0 4px 12px rgba(15, 23, 42, 0.03);
  --shadow-glow: 0 0 30px rgba(99, 102, 241, 0.06);

  /* Difficulty colors in Light Mode (keep readable contrast) */
  --easy-bg: rgba(16, 185, 129, 0.08);
  --easy-text: #059669; /* Darker for readability */
  --easy-border: rgba(16, 185, 129, 0.15);
  
  --medium-bg: rgba(217, 119, 6, 0.08);
  --medium-text: #B45309; /* Darker amber */
  --medium-border: rgba(217, 119, 6, 0.15);
  
  --hard-bg: rgba(225, 29, 72, 0.08);
  --hard-text: #BE123C; /* Darker rose */
  --hard-border: rgba(225, 29, 72, 0.15);

  --level-bg: rgba(79, 70, 229, 0.08);
  --level-text: #4F46E5;
  --level-border: rgba(79, 70, 229, 0.15);

  /* Code Blocks */
  --bg-pre: #F8FAFC;
  --text-pre: #1E293B;
  --border-pre: rgba(15, 23, 42, 0.08);
  --shadow-pre: 0 4px 12px rgba(15, 23, 42, 0.03);
  --bg-code: rgba(99, 102, 241, 0.06);
  --text-code: #4F46E5;

  /* Custom inputs & UI */
  --bg-input: #FFFFFF;
  --bg-answer-wrapper: rgba(15, 23, 42, 0.02);
  --bg-hover-subtle: rgba(15, 23, 42, 0.03);
  --dot-pattern-opacity: 0.25;
  --dot-color: rgba(15, 23, 42, 0.05);
  --bg-header: rgba(248, 249, 252, 0.85);
  --bg-section-gray: #F1F3F9;
  --hero-gradient: radial-gradient(120% 60% at 50% 0%, rgba(99, 102, 241, 0.04) 0%, rgba(248, 249, 252, 0) 100%);
  --hero-title-gradient: linear-gradient(135deg, var(--text-headings) 30%, #475569 100%);
  --stat-number-gradient: linear-gradient(135deg, var(--text-headings) 30%, var(--primary) 100%);

  /* CTA Box Variables */
  --bg-cta: #FFFFFF;
  --bg-cta-gradient: radial-gradient(circle at 50% 0%, rgba(99, 102, 241, 0.08) 0%, rgba(255, 255, 255, 0) 100%);
  --text-cta: var(--text-headings);
}

/* Reset & Base */
* { 
  box-sizing: border-box; 
  margin: 0; 
  padding: 0; 
}
html {
  scroll-behavior: smooth;
  background-color: var(--bg-page);
}
body {
  font-family: var(--font-sans);
  color: var(--text-main);
  background-color: var(--bg-page);
  line-height: 1.65;
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
  overflow-x: hidden;
  position: relative;
}
/* Ambient glow & grid overlay pattern */
body::before {
  content: "";
  position: fixed;
  top: 0;
  left: 0;
  width: 100vw;
  height: 100vh;
  background-image: 
    radial-gradient(circle at 10% 20%, rgba(99, 102, 241, 0.04) 0%, transparent 45%),
    radial-gradient(circle at 90% 80%, rgba(16, 185, 129, 0.03) 0%, transparent 45%),
    linear-gradient(to right, var(--dot-color) 1px, transparent 1px),
    linear-gradient(to bottom, var(--dot-color) 1px, transparent 1px);
  background-size: 100vw 100vh, 100vw 100vh, 48px 48px, 48px 48px;
  pointer-events: none;
  z-index: -10;
  opacity: var(--dot-pattern-opacity, 1);
  transition: opacity 0.3s ease;
}

/* Typography Hierarchy */
h1, h2, h3, h4, h5, h6 {
  color: var(--text-headings);
  font-weight: 700;
  line-height: 1.2;
  letter-spacing: -0.02em;
  margin-bottom: 1rem;
}
h1 { font-size: clamp(32px, 5vw, 56px); font-weight: 800; letter-spacing: -0.04em; }
h2 { font-size: clamp(24px, 4vw, 36px); font-weight: 800; letter-spacing: -0.03em; }
h3 { font-size: clamp(18px, 3vw, 24px); font-weight: 700; letter-spacing: -0.02em; }
h4 { font-size: 18px; font-weight: 600; }
p { margin-bottom: 1rem; font-size: 16px; color: var(--text-muted); }

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

/* Layout Grid */
.container {
  max-width: 1280px;
  margin: 0 auto;
  padding: 0 24px;
}
.section { 
  padding: 80px 0; 
  position: relative;
}
.section-gray { 
  background-color: var(--bg-section-gray); 
  border-top: 1px solid var(--border);
  border-bottom: 1px solid var(--border);
}

/* Buttons */
.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  padding: 12px 24px;
  border-radius: var(--radius-sm);
  font-weight: 600;
  font-size: 15px;
  cursor: pointer;
  transition: var(--transition);
  text-decoration: none;
  gap: 8px;
  border: none;
}
.btn-primary { 
  background: linear-gradient(135deg, var(--primary) 0%, #8B5CF6 100%); 
  color: var(--white); 
  box-shadow: 0 4px 14px rgba(99, 102, 241, 0.35); 
}
.btn-primary:hover { 
  background: linear-gradient(135deg, var(--primary-hover) 0%, #7C3AED 100%); 
  transform: translateY(-2px); 
  box-shadow: 0 6px 20px rgba(99, 102, 241, 0.45); 
  color: var(--white);
}
/* Light theme overrides for primary CTA buttons */
html[data-theme="light"] .btn-primary {
  background: linear-gradient(135deg, #4F46E5 0%, #7C3AED 100%);
  color: var(--white);
  box-shadow: 0 4px 14px rgba(79, 70, 229, 0.35);
}

html[data-theme="light"] .btn-primary:hover {
  background: linear-gradient(135deg, #4338CA 0%, #6D28D9 100%);
  color: var(--text-headings);
  box-shadow: 0 6px 20px rgba(79, 70, 229, 0.45);
}

/* Existing outline button */
.btn-outline {
  background-color: rgba(255, 255, 255, 0.03);
  border: 1px solid var(--border);
  color: var(--text-main);
}

.btn-outline:hover {
  border-color: var(--border-hover);
  background-color: rgba(255, 255, 255, 0.08);
  transform: translateY(-2px);
} 
  background-color: rgba(255, 255, 255, 0.03); 
  border: 1px solid var(--border); 
  color: var(--text-main); 
}
.btn-outline:hover { 
  border-color: var(--border-hover); 
  background-color: rgba(255, 255, 255, 0.08); 
  transform: translateY(-2px); 
}
.btn-large { 
  padding: 16px 32px; 
  font-size: 16px; 
  border-radius: var(--radius-md); 
}

/* Glassmorphism Header */
.header {
  height: 76px;
  display: flex;
  align-items: center;
  background: var(--bg-header);
  backdrop-filter: blur(16px);
  -webkit-backdrop-filter: blur(16px);
  border-bottom: 1px solid var(--border);
  position: sticky;
  top: 0;
  z-index: 10000;
  transition: var(--transition);
}
.nav-wrap { 
  display: flex; 
  justify-content: space-between; 
  align-items: center; 
  width: 100%; 
  position: relative;
  z-index: 9999;
}
.logo { 
  font-weight: 800; 
  font-size: 20px; 
  color: var(--text-headings); 
  display: flex; 
  align-items: center; 
  gap: 10px; 
  letter-spacing: -0.02em; 
  text-decoration: none; 
}
.logo-badge {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 34px;
  height: 34px;
  background: linear-gradient(135deg, var(--primary), #8B5CF6);
  border-radius: 8px;
  box-shadow: 0 2px 10px rgba(99, 102, 241, 0.4);
  flex-shrink: 0;
}
.logo-text-wrap {
  display: flex;
  align-items: baseline;
  line-height: 1;
  gap: 4px;
}
.logo-devops {
  font-size: 19px;
  font-weight: 800;
  letter-spacing: -0.03em;
  background: linear-gradient(135deg, #A5B4FC 0%, var(--primary) 100%);
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
}
.logo-interview {
  font-size: 19px;
  font-weight: 800;
  letter-spacing: -0.03em;
  color: var(--text-headings);
}
.logo-dot {
  width: 5px;
  height: 5px;
  border-radius: 50%;
  background: #8B5CF6;
  margin: 0 2px 2px;
  display: inline-block;
}
.logo:hover .logo-badge {
  box-shadow: 0 4px 16px rgba(99, 102, 241, 0.6);
  transform: translateY(-1px) scale(1.03);
}

.nav-links { 
  display: flex; 
  gap: 24px; 
  align-items: center; 
}
.nav-links a { 
  color: var(--text-muted); 
  font-weight: 500; 
  font-size: 14px; 
  position: relative; 
  padding: 6px 0;
}
.nav-links a:hover { 
  color: var(--text-headings); 
}
.nav-links a.active { 
  color: var(--text-headings) !important; 
  font-weight: 600; 
}
.nav-links a::after {
  content: '';
  position: absolute;
  bottom: 0;
  left: 0;
  width: 0;
  height: 2px;
  background: linear-gradient(90deg, var(--primary), #8B5CF6);
  transition: width 0.25s ease;
}
.nav-links a:hover::after,
.nav-links a.active::after {
  width: 100%;
}
 
/* Mobile Toggle */
.mobile-toggle { 
  display: none; 
  background: none; 
  border: none; 
  color: var(--text-headings); 
  cursor: pointer; 
  padding: 8px; 
}
.mobile-drawer { 
  position: fixed; 
  top: 0; 
  right: 0; 
  transform: translateX(100%); 
  width: 320px; 
  height: 100vh; 
  background: var(--bg-sidebar); 
  border-left: 1px solid var(--border);
  z-index: 10500; 
  box-shadow: -10px 0 35px rgba(0,0,0,0.5); 
  transition: transform 0.3s cubic-bezier(0.4, 0, 0.2, 1); 
  padding: 32px; 
}
.mobile-drawer.open { 
  transform: translateX(0); 
}
.drawer-header { 
  display: flex; 
  justify-content: space-between; 
  align-items: center; 
  margin-bottom: 40px; 
}
#drawer-close { 
  font-size: 32px; 
  background: none; 
  border: none; 
  cursor: pointer; 
  color: var(--text-muted); 
}
#drawer-close:hover {
  color: var(--text-headings);
}
.drawer-links { 
  display: flex; 
  flex-direction: column; 
  gap: 20px; 
}
.drawer-links a { 
  font-size: 17px; 
  font-weight: 600; 
  color: var(--text-muted); 
  padding: 8px 0;
  border-bottom: 1px solid rgba(255,255,255,0.03);
}
.drawer-links a:hover,
.drawer-links a.active {
  color: var(--text-headings);
  border-left: 2px solid var(--primary);
  padding-left: 12px;
}
 
/* Dot grid canvas background */
.dot-pattern {
  position: absolute;
  width: 100%;
  height: 100%;
  top: 0;
  left: 0;
  background-image: radial-gradient(var(--dot-color) 1px, transparent 1px);
  background-size: 24px 24px;
  opacity: var(--dot-pattern-opacity);
  z-index: 0;
  pointer-events: none;
}
 
/* Premium Hero Section */
.hero-redesign {
  background: var(--hero-gradient);
  padding: 10px 0 10px;
  text-align: center;
  position: relative;
  overflow: hidden;
  border-bottom: 1px solid var(--border);
}
.hero-redesign h1 { 
  font-size: clamp(34px, 6vw, 64px); 
  line-height: 1.1; 
  margin-bottom: 24px; 
  background: var(--hero-title-gradient);
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
  letter-spacing: -0.04em;
}
.hero-redesign p {
  font-size: clamp(16px, 2.5vw, 20px);
  color: var(--text-muted);
  max-width: 680px;
  margin: 0 auto 20px;
  line-height: 1.6;
}
.hero-content-wrap { 
  max-width: 900px; 
  margin: 0 auto; 
  position: relative; 
  z-index: 1; 
}
.hero-search-container {
  max-width: 640px;
  margin: 0 auto 28px;
  position: relative;
}
.hero-search-input {
  width: 100%;
  padding: 20px 140px 20px 60px;
  border-radius: 16px;
  border: 1px solid var(--border);
  background: var(--bg-input);
  color: var(--text-headings);
  box-shadow: var(--shadow-md);
  font-size: 16px;
  outline: none;
  transition: var(--transition);
  font-family: inherit;
  backdrop-filter: blur(8px);
}
.hero-search-input:focus {
  border-color: var(--primary);
  background: var(--bg-card);
  box-shadow: 0 0 0 4px rgba(99, 102, 241, 0.25), var(--shadow-lg);
}
.hero-search-icon {
  position: absolute;
  left: 20px;
  top: 50%;
  transform: translateY(-50%);
  color: var(--text-muted);
}
.hero-search-btn {
  position: absolute;
  right: 10px;
  top: 50%;
  transform: translateY(-50%);
  background: linear-gradient(135deg, var(--primary) 0%, #8B5CF6 100%);
  color: #ffffff;
  padding: 10px 24px;
  border-radius: 10px;
  font-weight: 600;
  border: none;
  cursor: pointer;
  font-size: 14px;
  transition: var(--transition);
}
.hero-search-btn:hover {
  transform: translateY(-50%) scale(1.02);
  box-shadow: 0 2px 10px rgba(99,102,241,0.4);
}
.hero-buttons {
  display: flex;
  justify-content: center;
  gap: 16px;
  margin-bottom: 32px;
}
 
.trending-topics { 
  display: flex; 
  justify-content: center; 
  align-items: center; 
  gap: 12px; 
  color: var(--text-muted); 
  font-size: 14px; 
}
.trending-tag { 
  background: var(--bg-hover-subtle); 
  border: 1px solid var(--border);
  color: var(--text-main); 
  padding: 5px 12px; 
  border-radius: 12px; 
  font-weight: 500;
  font-size: 13px;
  transition: var(--transition);
}
.trending-tag:hover {
  border-color: var(--primary);
  background: rgba(99, 102, 241, 0.1);
  color: var(--primary);
}
 
/* Trust/Stats Section */
.trust-stats-section {
  padding: 40px 0;
  border-bottom: 1px solid var(--border);
}
.stats-grid {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 24px;
}
.stat-card {
  background: var(--bg-card);
  border: 1px solid var(--border);
  border-radius: var(--radius-md);
  padding: 24px;
  text-align: center;
  transition: var(--transition);
  backdrop-filter: blur(10px);
}
.stat-card:hover {
  border-color: rgba(99, 102, 241, 0.3);
  background: var(--bg-card-hover);
  transform: translateY(-2px);
  box-shadow: var(--shadow-glow);
}
.stat-number {
  font-size: 38px;
  font-weight: 800;
  line-height: 1.1;
  background: var(--stat-number-gradient);
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
  margin-bottom: 8px;
}
.stat-label {
  font-size: 14px;
  color: var(--text-muted);
  font-weight: 600;
  text-transform: uppercase;
  letter-spacing: 0.05em;
}

/* Featured Tracks Grid */
.tracks-header {
  display: flex;
  justify-content: space-between;
  align-items: flex-end;
  margin-bottom: 40px;
}
.tracks-grid {
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  gap: 24px;
}
.track-card {
  display: flex;
  background: var(--bg-card);
  border: 1px solid var(--border);
  border-radius: var(--radius-lg);
  padding: 24px;
  gap: 24px;
  transition: var(--transition);
  text-decoration: none;
  position: relative;
  overflow: hidden;
}
.track-card:hover {
  background: var(--bg-card-hover);
  border-color: var(--border-hover);
  transform: translateY(-4px);
  box-shadow: var(--shadow-lg);
}
.track-card::before {
  content: '';
  position: absolute;
  top: 0; left: 0; width: 4px; height: 100%;
  background: var(--primary);
  opacity: 0;
  transition: var(--transition);
}
.track-card:hover::before {
  opacity: 1;
}
 
/* Custom Gradients per Track */
.track-card.kubernetes::before { background: #326CE5; }
.track-card.aws::before { background: #FF9900; }
.track-card.docker::before { background: #2496ED; }
.track-card.terraform::before { background: #844FBA; }
.track-card.linux::before { background: #F8F9FA; }
.track-card.ci-cd::before { background: #2088FF; }
.track-card.observability::before { background: #E6522C; }
.track-card.system-design::before { background: #10B981; }
 
.track-icon-wrap {
  width: 56px;
  height: 56px;
  border-radius: 12px;
  background: var(--bg-hover-subtle);
  border: 1px solid var(--border);
  display: flex;
  align-items: center;
  justify-content: center;
  flex-shrink: 0;
  color: var(--text-headings);
  transition: var(--transition);
}
.track-card:hover .track-icon-wrap {
  background: rgba(99, 102, 241, 0.1);
  border-color: rgba(99, 102, 241, 0.3);
  color: var(--primary-hover);
}
.track-info {
  flex: 1;
  display: flex;
  flex-direction: column;
}
.track-info h3 {
  font-size: 20px;
  margin-bottom: 6px;
}
.track-info p {
  font-size: 14px;
  color: var(--text-muted);
  margin-bottom: 16px;
  flex: 1;
}
.track-meta {
  display: flex;
  gap: 16px;
  font-size: 13px;
  font-weight: 500;
  color: var(--text-muted);
}
.track-meta-item {
  display: flex;
  align-items: center;
  gap: 6px;
}
.track-meta-item svg {
  color: var(--primary);
}
 
/* Production Incidents Section */
.incident-board {
  background: var(--bg-card);
  border: 1px solid var(--border);
  border-radius: var(--radius-lg);
  overflow: hidden;
  box-shadow: var(--shadow-lg);
}
.incident-header {
  background: var(--bg-hover-subtle);
  padding: 16px 24px;
  border-bottom: 1px solid var(--border);
  display: flex;
  justify-content: space-between;
  align-items: center;
}
.incident-console-title {
  font-family: var(--font-mono);
  font-size: 14px;
  color: var(--primary);
  display: flex;
  align-items: center;
  gap: 12px;
}
.console-dots {
  display: flex;
  gap: 6px;
}
.console-dot {
  width: 10px;
  height: 10px;
  border-radius: 50%;
}
.console-dot.red { background: #EF4444; }
.console-dot.yellow { background: #F59E0B; }
.console-dot.green { background: #10B981; }
 
.incident-status-feed {
  padding: 8px 0;
}
.incident-row {
  display: flex;
  align-items: center;
  padding: 16px 24px;
  border-bottom: 1px solid var(--border);
  transition: var(--transition);
}
.incident-row:last-child {
  border-bottom: none;
}
.incident-row:hover {
  background: var(--bg-hover-subtle);
}
.incident-status-indicator {
  display: flex;
  align-items: center;
  gap: 8px;
  font-size: 13px;
  font-weight: 600;
  width: 140px;
  flex-shrink: 0;
}
.status-ping {
  width: 8px;
  height: 8px;
  border-radius: 50%;
  position: relative;
}
.status-ping.critical { background: #EF4444; box-shadow: 0 0 8px #EF4444; }
.status-ping.warning { background: #F59E0B; box-shadow: 0 0 8px #F59E0B; }
.status-ping.resolved { background: #10B981; box-shadow: 0 0 8px #10B981; }
 
@keyframes status-blink {
  0% { transform: scale(0.95); opacity: 0.5; }
  50% { transform: scale(1.6); opacity: 0; }
  100% { transform: scale(0.95); opacity: 0; }
}
.status-ping::after {
  content: '';
  position: absolute;
  top: -4px; left: -4px; right: -4px; bottom: -4px;
  border-radius: 50%;
  border: 2px solid currentColor;
  animation: status-blink 1.8s infinite ease-out;
  opacity: 0;
}
.status-ping.critical::after { border-color: #EF4444; }
.status-ping.warning::after { border-color: #F59E0B; }
.status-ping.resolved::after { display: none; }
 
.incident-details {
  flex: 1;
  padding-right: 16px;
}
.incident-title {
  font-weight: 700;
  font-size: 15px;
  color: var(--text-headings);
  margin-bottom: 2px;
}
.incident-meta {
  display: flex;
  gap: 12px;
  font-size: 13px;
  color: var(--text-muted);
}
.incident-action {
  flex-shrink: 0;
}

/* Roadmap timeline */
.roadmap-timeline {
  position: relative;
  max-width: 900px;
  margin: 0 auto;
  padding-left: 32px;
}
.roadmap-timeline::before {
  content: '';
  position: absolute;
  left: 11px;
  top: 0;
  bottom: 0;
  width: 2px;
  background: linear-gradient(to bottom, var(--primary), #8B5CF6, #EC4899, #10B981);
}
.roadmap-phase {
  position: relative;
  margin-bottom: 48px;
}
.roadmap-phase:last-child {
  margin-bottom: 0;
}
.roadmap-node {
  position: absolute;
  left: -32px;
  top: 4px;
  width: 24px;
  height: 24px;
  border-radius: 50%;
  background: var(--bg-page);
  border: 4px solid var(--primary);
  box-shadow: 0 0 10px rgba(99, 102, 241, 0.5);
  z-index: 1;
}
.roadmap-phase:nth-child(2) .roadmap-node { border-color: #8B5CF6; box-shadow: 0 0 10px rgba(139, 92, 246, 0.5); }
.roadmap-phase:nth-child(3) .roadmap-node { border-color: #EC4899; box-shadow: 0 0 10px rgba(236, 72, 153, 0.5); }
.roadmap-phase:nth-child(4) .roadmap-node { border-color: #10B981; box-shadow: 0 0 10px rgba(16, 185, 129, 0.5); }
.roadmap-phase:nth-child(5) .roadmap-node { border-color: #F59E0B; box-shadow: 0 0 10px rgba(245, 158, 11, 0.5); }

.roadmap-phase-card {
  background: var(--bg-card);
  border: 1px solid var(--border);
  border-radius: var(--radius-lg);
  padding: 32px;
  transition: var(--transition);
}
.roadmap-phase-card:hover {
  border-color: var(--border-hover);
  box-shadow: var(--shadow-lg);
  transform: translateX(4px);
}
.phase-number {
  font-family: var(--font-mono);
  font-size: 13px;
  color: var(--primary);
  font-weight: 700;
  text-transform: uppercase;
  margin-bottom: 8px;
  display: block;
}
.roadmap-phase-card h3 {
  font-size: 22px;
  margin-bottom: 8px;
}
.roadmap-phase-card p {
  margin-bottom: 20px;
}
.phase-skills-list {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  list-style: none;
}
.phase-skills-list li {
  font-size: 13px;
  background: var(--bg-hover-subtle);
  border: 1px solid var(--border);
  padding: 4px 12px;
  border-radius: 8px;
  color: var(--text-main);
  font-weight: 500;
}
 
/* Two-Column Sticky Navigation layout for Topic / Questions Listing */
.listing-layout {
  display: flex;
  gap: 40px;
  position: relative;
  align-items: flex-start;
}
.sticky-sidebar-wrapper {
  width: 260px;
  flex-shrink: 0;
  position: sticky;
  top: 116px;
  height: calc(100vh - 160px);
  overflow-y: auto;
  padding-right: 12px;
  scrollbar-width: thin;
}
.sticky-sidebar-wrapper::-webkit-scrollbar {
  width: 4px;
}
.sticky-sidebar-wrapper::-webkit-scrollbar-thumb {
  background: var(--border);
  border-radius: 2px;
}
.sidebar-title {
  font-size: 12px;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.05em;
  color: var(--text-muted);
  margin-bottom: 16px;
}
.sidebar-menu {
  list-style: none;
}
.sidebar-menu-item {
  margin-bottom: 4px;
}
.sidebar-link {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 8px 12px;
  border-left: 2px solid transparent;
  color: var(--text-muted);
  font-size: 14px;
  font-weight: 500;
  transition: var(--transition);
}
.sidebar-link:hover {
  color: var(--text-headings);
  background: var(--bg-hover-subtle);
}
.sidebar-link.active {
  color: var(--primary);
  border-left-color: var(--primary);
  background: rgba(99, 102, 241, 0.06);
  font-weight: 600;
}
.sidebar-sec-count {
  font-size: 11px;
  background: var(--bg-hover-subtle);
  padding: 2px 6px;
  border-radius: 6px;
  font-weight: 600;
}
.sidebar-link.active .sidebar-sec-count {
  background: rgba(99, 102, 241, 0.15);
  color: var(--primary);
}
 
.main-content-flow {
  flex: 1;
  min-width: 0; /* Prevents flex items from overflowing */
}
 
.grouped-section {
  margin-bottom: 60px;
  scroll-margin-top: 110px; /* Offset for sticky header */
}
.grouped-section h2 {
  font-size: 26px;
  margin-bottom: 24px;
  display: flex;
  align-items: center;
  gap: 12px;
  padding-bottom: 12px;
  border-bottom: 1px solid var(--border);
}
.section-desc {
  font-size: 15px;
  color: var(--text-muted);
  margin-top: -16px;
  margin-bottom: 24px;
}
 
/* Premium Expandable Question Card */
.premium-q-card {
  background: var(--bg-card);
  border: 1px solid var(--border);
  border-radius: var(--radius-lg);
  margin-bottom: 20px;
  transition: var(--transition);
  overflow: hidden;
  box-shadow: var(--shadow-sm);
  position: relative;
}
.premium-q-card:hover {
  border-color: var(--border-hover);
  box-shadow: var(--shadow-md);
}
.premium-q-card.mastered {
  border-color: rgba(16, 185, 129, 0.35);
  box-shadow: 0 4px 20px rgba(16, 185, 129, 0.05);
}
.q-card-header {
  padding: 24px 32px;
  cursor: pointer;
  user-select: none;
}
.q-meta-row {
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
  margin-bottom: 12px;
  align-items: center;
}
.q-title-wrap {
  display: flex;
  align-items: flex-start;
  gap: 16px;
}
.q-prefix {
  font-family: var(--font-sans);
  font-size: 20px;
  font-weight: 800;
  color: var(--primary);
  line-height: 1.3;
}
.q-title {
  font-size: 18px;
  font-weight: 700;
  color: var(--text-headings);
  line-height: 1.4;
}
 
/* Expandable Answer details */
.q-answer-wrapper {
  max-height: 0;
  overflow: hidden;
  transition: max-height 0.35s cubic-bezier(0.4, 0, 0.2, 1);
  border-top: 1px solid transparent;
  background: var(--bg-answer-wrapper);
}
.premium-q-card.expanded {
  border-color: rgba(99, 102, 241, 0.3);
}
.premium-q-card.expanded .q-answer-wrapper {
  border-top-color: var(--border);
  max-height: 2500px; /* Large fallback for dynamic content */
}
.q-answer-content {
  padding: 32px;
  font-size: 16px;
  line-height: 1.7;
  color: var(--text-main);
}
.q-answer-content h2, 
.q-answer-content h3 {
  margin-top: 24px;
  margin-bottom: 12px;
}
.q-answer-content h2 { font-size: 20px; }
.q-answer-content h3 { font-size: 18px; }
.q-answer-content p {
  margin-bottom: 16px;
}
.q-answer-content ul, 
.q-answer-content ol {
  margin-bottom: 16px;
  padding-left: 24px;
}
.q-answer-content li {
  margin-bottom: 6px;
}

/* Badges */
.badge {
  display: inline-flex;
  align-items: center;
  padding: 4px 10px;
  border-radius: 12px;
  font-size: 12px;
  font-weight: 600;
  border: 1px solid transparent;
  letter-spacing: 0.02em;
}
.badge-easy { background: var(--easy-bg); color: var(--easy-text); border-color: var(--easy-border); }
.badge-medium { background: var(--medium-bg); color: var(--medium-text); border-color: var(--medium-border); }
.badge-hard { background: var(--hard-bg); color: var(--hard-text); border-color: var(--hard-border); }
.badge-level { background: var(--level-bg); color: var(--level-text); border-color: var(--level-border); }
.badge-tag {
  background: var(--bg-hover-subtle);
  color: var(--text-muted);
  border-color: var(--border);
}
 
/* Action Bar inside question card */
.q-action-bar {
  display: flex;
  justify-content: space-between;
  align-items: center;
  margin-top: 16px;
}
.show-answer-btn {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  font-size: 14px;
  font-weight: 700;
  color: var(--primary);
  border: none;
  background: none;
  cursor: pointer;
  transition: var(--transition);
}
.show-answer-btn:hover {
  color: var(--primary-hover);
}
.show-answer-btn svg {
  transition: transform 0.25s ease;
}
.premium-q-card.expanded .show-answer-btn svg {
  transform: rotate(180deg);
}
 
.card-actions-right {
  display: flex;
  align-items: center;
  gap: 12px;
}
 
/* Mastery toggle buttons */
.q-mastery-btn {
  background: var(--bg-hover-subtle);
  border: 1px solid var(--border);
  color: var(--text-muted);
  display: inline-flex;
  align-items: center;
  gap: 6px;
  padding: 6px 14px;
  border-radius: 8px;
  font-size: 13px;
  font-weight: 600;
  cursor: pointer;
  transition: var(--transition);
}
.q-mastery-btn:hover {
  border-color: var(--border-hover);
  color: var(--text-headings);
}
.q-mastery-btn.active {
  background: rgba(16, 185, 129, 0.1);
  color: var(--secondary);
  border-color: rgba(16, 185, 129, 0.2);
}
.q-mastery-btn.active svg {
  fill: var(--secondary);
}
 
/* Code Blocks Styling */
pre {
  background: var(--bg-pre) !important;
  color: var(--text-pre) !important;
  padding: 20px 24px;
  border-radius: 12px;
  overflow-x: auto;
  font-family: var(--font-mono);
  font-size: 14px;
  line-height: 1.6;
  margin: 24px 0;
  border: 1px solid var(--border-pre);
  box-shadow: var(--shadow-pre);
  position: relative;
}
code {
  font-family: var(--font-mono);
  font-size: 0.9em;
  background: var(--bg-code);
  color: var(--text-code);
  padding: 2px 6px;
  border-radius: 4px;
}
pre code {
  background: transparent;
  color: inherit;
  padding: 0;
  font-size: inherit;
}
 
/* Copy to clipboard button style */
.code-copy-btn {
  position: absolute;
  top: 12px;
  right: 12px;
  background: var(--bg-hover-subtle);
  border: 1px solid var(--border);
  color: var(--text-muted);
  width: 32px;
  height: 32px;
  border-radius: 6px;
  display: flex;
  align-items: center;
  justify-content: center;
  cursor: pointer;
  opacity: 0;
  transition: var(--transition);
  z-index: 10;
}
pre:hover .code-copy-btn {
  opacity: 1;
}
.code-copy-btn:hover {
  background: var(--bg-card-hover);
  color: var(--text-headings);
  border-color: var(--border-hover);
}
.code-copy-btn.copied {
  background: rgba(16, 185, 129, 0.15);
  color: var(--secondary);
  border-color: rgba(16, 185, 129, 0.3);
}
 
/* CTA Linear-style Box */
.cta-box {
  text-align: center; 
  padding: 60px 40px; 
  background: var(--bg-cta-gradient), var(--bg-cta);
  color: var(--text-main); 
  border-radius: var(--radius-lg); 
  margin: 0 auto; 
  max-width: 1000px; 
  box-shadow: var(--shadow-lg);
  position: relative; 
  overflow: hidden;
  border: 1px solid var(--border);
}
.cta-box h2 { 
  color: var(--text-cta); 
  font-size: clamp(24px, 4vw, 38px); 
  margin-bottom: 16px; 
  position: relative; 
  z-index: 1; 
}
.cta-box p { 
  font-size: 17px; 
  color: var(--text-muted); 
  margin-bottom: 32px; 
  max-width: 600px; 
  margin-left: auto; 
  margin-right: auto; 
  position: relative; 
  z-index: 1; 
}
.cta-box .btn { 
  position: relative; 
  z-index: 1; 
}

/* Topic Grid and Topic Card (Topics Page Redesign) */
.topic-grid-new {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 24px;
  margin-top: 40px;
}

.topic-card-new {
  display: flex;
  flex-direction: column;
  background: var(--bg-card);
  border: 1px solid var(--border);
  border-radius: var(--radius-lg);
  padding: 32px;
  transition: var(--transition);
  text-decoration: none;
  position: relative;
  overflow: hidden;
  box-shadow: var(--shadow-sm);
}

.topic-card-new:hover {
  background: var(--bg-card-hover);
  border-color: rgba(255, 255, 255, 0.15);
  transform: translateY(-6px);
  box-shadow: var(--shadow-lg);
}

/* Card top gradient borders per topic */
.topic-card-new::before {
  content: '';
  position: absolute;
  top: 0; left: 0; width: 100%; height: 4px;
  background: var(--primary);
  opacity: 0.8;
  transition: var(--transition);
}

/* Specific gradients */
.topic-card-new.kubernetes::before { background: linear-gradient(90deg, #326CE5, #6366F1); }
.topic-card-new.aws::before { background: linear-gradient(90deg, #FF9900, #F59E0B); }
.topic-card-new.docker::before { background: linear-gradient(90deg, #2496ED, #0080FF); }
.topic-card-new.terraform::before { background: linear-gradient(90deg, #844FBA, #A78BFA); }
.topic-card-new.linux::before { background: linear-gradient(90deg, #7F7F7F, #F3F4F6); }
.topic-card-new.ci-cd::before { background: linear-gradient(90deg, #2088FF, #10B981); }
.topic-card-new.observability::before { background: linear-gradient(90deg, #E6522C, #F43F5E); }
.topic-card-new.system-design::before { background: linear-gradient(90deg, #10B981, #34D399); }
.topic-card-new.azure::before { background: linear-gradient(90deg, #0078D4, #38BDF8); }
.topic-card-new.gcp::before { background: linear-gradient(90deg, #4285F4, #34A853); }

/* Card Icon */
.card-icon-wrap-new {
  width: 48px;
  height: 48px;
  border-radius: 10px;
  background: var(--bg-hover-subtle);
  border: 1px solid var(--border);
  display: flex;
  align-items: center;
  justify-content: center;
  color: var(--text-headings);
  margin-bottom: 24px;
  transition: var(--transition);
}

.topic-card-new:hover .card-icon-wrap-new {
  background: rgba(99, 102, 241, 0.1);
  border-color: rgba(99, 102, 241, 0.3);
  color: var(--primary-hover);
}

.card-icon-new {
  width: 20px;
  height: 20px;
}

/* Topic Card Content */
.topic-card-new h3 {
  font-size: 20px;
  font-weight: 700;
  margin-bottom: 8px;
  color: var(--text-headings);
}

.topic-card-new p {
  font-size: 14px;
  color: var(--text-muted);
  line-height: 1.5;
  margin-bottom: 24px;
  flex: 1;
}

/* Card Stats and Mastery Tracker */
.card-stats-new {
  display: flex;
  flex-direction: column;
  gap: 12px;
  margin-top: auto;
}

.question-count-new {
  font-size: 13px;
  font-weight: 600;
  color: var(--text-muted);
}

.progress-bar-bg-new {
  width: 100%;
  height: 6px;
  background: rgba(255, 255, 255, 0.05);
  border-radius: 3px;
  overflow: hidden;
}

.progress-bar-fill-new {
  height: 100%;
  background: linear-gradient(90deg, var(--primary), var(--secondary));
  border-radius: 3px;
  transition: width 0.4s ease;
}

.practice-link-new {
  display: flex;
  align-items: center;
  gap: 6px;
  font-size: 14px;
  font-weight: 700;
  color: var(--primary);
  margin-top: 4px;
  transition: var(--transition);
}

.topic-card-new:hover .practice-link-new {
  color: var(--primary-hover);
  transform: translateX(4px);
}

.card-more-new {
  position: absolute;
  top: 24px;
  right: 24px;
  color: var(--text-muted);
  opacity: 0.5;
  transition: var(--transition);
}

.topic-card-new:hover .card-more-new {
  opacity: 1;
}

/* Minimalist Footer */
.footer { 
  padding: 80px 0 40px; 
  background: #04060C; 
  border-top: 1px solid var(--border); 
  color: var(--text-muted); 
  font-size: 14px; 
}

/* Footer CTA Section */
.footer-cta {
  text-align: center;
  padding-bottom: 60px;
  border-bottom: 1px solid var(--border);
  margin-bottom: 60px;
}
.footer-cta .cta-heading {
  font-size: clamp(28px, 4vw, 38px);
  font-weight: 800;
  letter-spacing: -0.02em;
  color: var(--text-headings);
  margin-bottom: 16px;
}
.footer-cta .cta-subheading {
  font-size: 16px;
  color: var(--text-muted);
  max-width: 600px;
  margin: 0 auto 32px;
  line-height: 1.6;
}
.footer-cta .cta-buttons {
  display: flex;
  justify-content: center;
  gap: 16px;
  flex-wrap: wrap;
  align-items: center;
}
.footer-cta .cta-buttons .btn {
  min-width: 160px;
}

/* Footer Grid */
.footer-grid { 
  display: grid; 
  grid-template-columns: 2fr repeat(4, 1fr); 
  gap: 40px; 
}
.footer-branding {
  max-width: 320px;
  margin-top: 16px;
  color: var(--text-muted);
  font-size: 14px;
  line-height: 1.6;
}
.social-icons { 
  display: flex; 
  gap: 16px; 
  margin-top: 24px; 
}
.social-icons a { 
  color: var(--text-muted); 
  transition: var(--transition); 
}
.social-icons a:hover { 
  color: var(--text-headings); 
  transform: translateY(-2px); 
}
.footer h4 {
  font-size: 14px;
  margin-bottom: 20px;
  color: var(--text-headings);
  font-weight: 600;
  letter-spacing: 0.05em;
  text-transform: uppercase;
}
.footer .footer-link { 
  color: var(--text-muted); 
  display: block; 
  margin-bottom: 12px; 
  transition: var(--transition); 
  text-decoration: none;
}
.footer .footer-link:hover {
  color: var(--text-headings);
  transform: translateX(2px);
}

/* Footer Bottom */
.footer-bottom {
  border-top: 1px solid var(--border);
  padding-top: 30px;
  margin-top: 60px;
}
.bottom-bar {
  display: flex;
  justify-content: center;
  align-items: center;
}
.bottom-bar .copy-text {
  color: var(--text-muted);
  font-size: 14px;
  text-align: center;
  line-height: 1.6;
}

/* Dark theme footer enhancements */
html[data-theme="dark"] .footer {
  background: #0B0F19; /* premium deep slate */
  border-top-color: rgba(255, 255, 255, 0.08);
}
html[data-theme="dark"] .footer h4 {
  color: #FFFFFF;
}
html[data-theme="dark"] .footer .footer-link {
  color: #94A3B8;
}
html[data-theme="dark"] .footer .footer-link:hover {
  color: #FFFFFF;
}
html[data-theme="dark"] .footer .cta-heading {
  color: #FFFFFF;
}
html[data-theme="dark"] .footer .cta-subheading {
  color: #94A3B8;
}

/* Light theme footer */
html[data-theme="light"] .footer {
  background: #F8FAFC;
  border-top-color: rgba(0, 0, 0, 0.06);
  color: var(--text-main);
}
html[data-theme="light"] .footer h4 {
  color: var(--text-headings);
}
html[data-theme="light"] .footer .footer-link {
  color: var(--text-muted);
}
html[data-theme="light"] .footer .footer-link:hover {
  color: var(--text-headings);
}
html[data-theme="light"] .footer .cta-heading,
html[data-theme="light"] .footer .cta-subheading {
  color: var(--text-headings);
}

/* Responsive Footer */
@media (max-width: 1024px) {
  .footer-grid {
    grid-template-columns: 1.5fr repeat(2, 1fr);
    gap: 32px;
  }
}
@media (max-width: 768px) {
  .footer {
    padding: 60px 0 30px;
  }
  .footer-grid {
    grid-template-columns: 1fr 1fr;
    gap: 32px;
  }
  .footer-col:first-child {
    grid-column: span 2;
    margin-bottom: 16px;
  }
  .footer-bottom {
    margin-top: 40px;
    padding-top: 24px;
  }
}
@media (max-width: 640px) {
  .footer-cta .cta-buttons {
    flex-direction: column;
    align-items: stretch;
    max-width: 320px;
    margin: 0 auto;
  }
  .footer-cta .cta-buttons .btn {
    width: 100%;
  }
}
@media (max-width: 480px) {
  .footer-grid {
    grid-template-columns: 1fr;
    gap: 24px;
  }
  .footer-col:first-child {
    grid-column: span 1;
  }
}

/* Premium Back to Top Button */
.back-to-top {
  position: fixed; 
  bottom: 84px; 
  right: 24px; 
  width: 48px; 
  height: 48px; 
  background: var(--bg-card); 
  color: var(--text-headings); 
  border: 1px solid var(--border); 
  border-radius: 50%; 
  display: flex; 
  align-items: center; 
  justify-content: center; 
  cursor: pointer; 
  opacity: 0; 
  visibility: hidden; 
  transform: translateY(20px); 
  transition: var(--transition); 
  z-index: 1000;
  backdrop-filter: blur(8px);
  box-shadow: var(--shadow-md);
}
.back-to-top.visible { 
  opacity: 1; 
  visibility: visible; 
  transform: translateY(0); 
}
.back-to-top:hover { 
  background: var(--primary); 
  border-color: var(--primary-hover);
  color: #ffffff;
  transform: translateY(-3px); 
  box-shadow: var(--shadow-glow);
}
html[data-theme="light"] .back-to-top {
  background: rgba(255, 255, 255, 0.85); 
  border: 1px solid rgba(0, 0, 0, 0.06); 
  box-shadow: 0 4px 20px rgba(0, 0, 0, 0.08);
}
html[data-theme="light"] .back-to-top:hover {
  background: #4F46E5;
  border-color: #4F46E5;
  color: #ffffff;
  box-shadow: 0 0 20px rgba(79, 70, 229, 0.4);
}
 
/* Reading Progress Bar */
.reading-progress {
  position: fixed; 
  top: 0; 
  left: 0; 
  height: 3px; 
  background: linear-gradient(to right, var(--primary), #8B5CF6); 
  width: 0%; 
  z-index: 12000; 
  transition: width 0.1s ease-out;
}
 
/* Back to Top Button styles merged above */
 
/* Mastery Counter style on cards */
.mastery-check { 
  position: absolute; 
  top: -8px; 
  right: -8px; 
  width: 26px; 
  height: 26px; 
  background: var(--secondary); 
  color: #ffffff; 
  border-radius: 50%; 
  display: flex; 
  align-items: center; 
  justify-content: center; 
  box-shadow: 0 4px 10px rgba(16, 185, 129, 0.4); 
  border: 2px solid var(--bg-card); 
  z-index: 10;
}

/* Single question container custom spacing */
.single-container {
  max-width: 800px;
  margin: 0 auto;
}
.single-header { 
  margin-bottom: 32px; 
  padding-bottom: 24px; 
  border-bottom: 1px solid var(--border); 
}
.single-title { 
  font-size: clamp(24px, 5vw, 36px); 
  line-height: 1.3; 
  margin-bottom: 16px; 
}
.single-meta { 
  display: flex; 
  gap: 16px; 
  align-items: center; 
  font-size: 14px; 
  color: var(--text-muted); 
}
.single-content {
  color: var(--text-main);
}

/* Blog layouts */
.blog-hero-card {
  display: grid;
  grid-template-columns: 1fr 1fr;
  border-radius: var(--radius-lg);
  overflow: hidden;
  background: var(--bg-card);
  border: 1px solid var(--border);
  text-decoration: none;
  color: inherit;
  transition: var(--transition);
  margin-bottom: 48px;
  min-height: 380px;
  box-shadow: var(--shadow-md);
}
.blog-hero-card:hover {
  box-shadow: var(--shadow-lg);
  border-color: rgba(255,255,255,0.15);
  transform: translateY(-4px);
}
.blog-hero-image {
  overflow: hidden;
  background: var(--bg-page);
  position: relative;
}
.blog-hero-image img {
  width: 100%; height: 100%; object-fit: cover;
  transition: var(--transition);
}
.blog-hero-card:hover .blog-hero-image img {
  transform: scale(1.03);
}
.blog-hero-content {
  padding: 40px;
  display: flex;
  flex-direction: column;
  justify-content: center;
}
.blog-hero-content h2 {
  font-size: 28px;
  margin: 16px 0;
}
.blog-tag {
  display: inline-block;
  background: rgba(99, 102, 241, 0.1);
  color: #A5B4FC;
  font-size: 11px;
  font-weight: 700;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  padding: 4px 12px;
  border-radius: 20px;
  width: fit-content;
  border: 1px solid rgba(99, 102, 241, 0.2);
}
.blog-meta {
  display: flex;
  align-items: center;
  justify-content: space-between;
  font-size: 14px;
  color: var(--text-muted);
}
.blog-read-more {
  color: var(--primary);
  font-weight: 700;
}

.blog-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 24px;
}
.blog-card {
  background: var(--bg-card);
  border-radius: var(--radius-lg);
  border: 1px solid var(--border);
  overflow: hidden;
  text-decoration: none;
  color: inherit;
  display: flex;
  flex-direction: column;
  transition: var(--transition);
  box-shadow: var(--shadow-sm);
}
.blog-card:hover {
  box-shadow: var(--shadow-lg);
  border-color: rgba(255,255,255,0.15);
  transform: translateY(-4px);
}
.blog-card-image {
  height: 200px;
  overflow: hidden;
}
.blog-card-image img {
  width: 100%; height: 100%; object-fit: cover;
  transition: var(--transition);
}
.blog-card:hover .blog-card-image img {
  transform: scale(1.03);
}
.blog-card-content {
  padding: 24px;
  display: flex;
  flex-direction: column;
  gap: 12px;
  flex: 1;
}
.blog-card-content h3 {
  font-size: 18px;
  line-height: 1.4;
}
.blog-card-content p {
  font-size: 14px;
  margin: 0;
  flex: 1;
}

/* Filter components */
.filter-bar {
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding: 16px 0;
  border-bottom: 1px solid var(--border);
  margin-bottom: 32px;
  flex-wrap: wrap;
  gap: 16px;
}
.filter-select {
  padding: 8px 16px;
  border-radius: 8px;
  border: 1px solid var(--border);
  background: var(--bg-card);
  color: var(--text-main);
  outline: none;
  cursor: pointer;
  font-family: inherit;
  transition: var(--transition);
}
.filter-select:hover {
  border-color: var(--border-hover);
}
.filter-select:focus {
  border-color: var(--primary);
}
.filter-select option {
  background: var(--bg-card);
  color: var(--text-main);
}
.filter-options {
  display: flex;
  gap: 8px;
}
.filter-btn {
  padding: 6px 14px;
  border-radius: 20px;
  font-size: 13px;
  font-weight: 600;
  color: var(--text-muted);
  background: transparent;
  transition: var(--transition);
  border: 1px solid transparent;
}
.filter-btn:hover {
  color: var(--text-headings);
  background: var(--bg-hover-subtle);
}
.filter-btn.active {
  color: var(--primary);
  background: rgba(99,102,241,0.12);
  border-color: rgba(99,102,241,0.3);
}

/* Page list items */
.question-list {
  background: var(--bg-card);
  border: 1px solid var(--border);
  border-radius: var(--radius-lg);
  overflow: hidden;
}
.question-list-item {
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding: 20px 32px;
  border-bottom: 1px solid var(--border);
  transition: var(--transition);
  text-decoration: none;
}
.question-list-item:last-child {
  border-bottom: none;
}
.question-list-item:hover {
  background: var(--bg-hover-subtle);
  transform: translateX(4px);
}
.ql-info {
  flex: 1;
  padding-right: 16px;
}
.ql-title {
  font-weight: 700;
  font-size: 16px;
  color: var(--text-headings);
  margin-bottom: 4px;
  display: block;
}
.ql-meta {
  display: flex;
  gap: 16px;
  align-items: center;
  font-size: 14px;
  color: var(--text-muted);
}
.ql-meta span {
  display: flex;
  align-items: center;
  gap: 4px;
}

/* Search results item highlights */
.search-result-item:hover {
  border-left: 3px solid var(--primary);
}

/* Animation utilities */
@keyframes fadeInUp {
  from { opacity: 0; transform: translateY(16px); }
  to { opacity: 1; transform: translateY(0); }
}
.fade-in-up {
  animation: fadeInUp 0.4s cubic-bezier(0.16, 1, 0.3, 1) forwards;
}

/* Mobile & Tablet Responsiveness */
@media (max-width: 1024px) {
  .listing-layout {
    flex-direction: column;
    gap: 24px;
    align-items: stretch;
  }
  .sticky-sidebar-wrapper {
    width: 100%;
    height: auto;
    position: sticky;
    top: 76px;
    background: var(--bg-page);
    z-index: 50;
    padding: 12px 0;
    border-bottom: 1px solid var(--border);
  }
  .sidebar-title {
    display: none;
  }
  .mega-menu {
  position: fixed;
  top: 0;
  left: 0;
  width: 100%;
  background: #07091A;
  border-top: 1px solid rgba(99, 102, 241, 0.3);
  border-bottom: 1px solid rgba(255, 255, 255, 0.06);
  box-shadow: 0 32px 80px -12px rgba(0, 0, 0, 0.9);
  opacity: 0;
  visibility: hidden;
  pointer-events: none;
  transform: translateY(-4px);
  transition:
    opacity 0.16s cubic-bezier(0.4, 0, 0.2, 1),
    transform 0.16s cubic-bezier(0.4, 0, 0.2, 1),
    visibility 0.16s;
}
  .sidebar-menu {
    display: flex;
    gap: 8px;
    overflow-x: auto;
    padding-bottom: 4px;
    scrollbar-width: none;
  }
  .sidebar-menu::-webkit-scrollbar {
    display: none;
  }
  .sidebar-link {
    white-space: nowrap;
    border-left: none;
    border-bottom: 2px solid transparent;
    padding: 6px 12px;
  }
  .sidebar-link.active {
    border-left-color: transparent;
    border-bottom-color: var(--primary);
  }
  .stats-grid {
    grid-template-columns: repeat(2, 1fr);
  }
  .tracks-grid {
    grid-template-columns: 1fr;
  }
  .nav-links {
    display: none;
  }
  .mobile-toggle {
    display: block;
  }
  .blog-grid {
    grid-template-columns: repeat(2, 1fr);
  }
  .topic-grid-new {
    grid-template-columns: repeat(2, 1fr);
  }
}

@media (max-width: 768px) {
  .hero-redesign {
    padding: 30px 0 20px;
  }
  .hero-redesign h1 {
    font-size: 36px;
  }
  .hero-search-input {
    padding: 16px 20px 16px 50px;
    font-size: 15px;
  }
  .hero-search-icon {
    left: 18px;
  }
  .hero-search-btn {
    display: none; /* Hide search submit button on mobile */
  }
  .trending-topics {
    flex-wrap: wrap;
  }
  .stats-grid {
    grid-template-columns: 1fr;
  }
  .track-card {
    flex-direction: column;
    gap: 16px;
  }
  .incident-row {
    flex-direction: column;
    align-items: flex-start;
    gap: 12px;
  }
  .incident-status-indicator {
    width: auto;
  }
  .incident-action {
    align-self: flex-end;
  }
  .roadmap-timeline {
    padding-left: 20px;
  }
  .roadmap-node {
    left: -20px;
  }
  .blog-hero-card {
    grid-template-columns: 1fr;
    min-height: auto;
  }
  .blog-hero-image {
    height: 220px;
  }
  .blog-grid {
    grid-template-columns: 1fr;
  }
  .q-card-header {
    padding: 20px 24px;
  }
  .q-answer-content {
    padding: 24px;
  }
  .topic-grid-new {
    grid-template-columns: 1fr;
  }
}

/* ==========================================
   Theme Switching System - Toggle & Transitions
   ========================================== */

/* Nav Actions Container */
.nav-actions {
  display: flex;
  align-items: center;
  gap: 16px;
  margin-left: 16px;
}

/* Premium Animated Theme Toggle */
.theme-toggle {
  background: transparent;
  border: 1px solid var(--border);
  color: var(--text-muted);
  width: 40px;
  height: 40px;
  border-radius: 10px;
  display: flex;
  align-items: center;
  justify-content: center;
  cursor: pointer;
  position: relative;
  overflow: hidden;
  transition: var(--transition);
}
.theme-toggle:hover {
  border-color: var(--border-hover);
  color: var(--text-headings);
  background: var(--bg-hover-subtle);
  box-shadow: var(--shadow-glow);
}
.theme-toggle:focus-visible {
  outline: 2px solid var(--primary);
  outline-offset: 2px;
}
.theme-icon {
  position: absolute;
  transition: transform 0.5s cubic-bezier(0.4, 0, 0.2, 1), opacity 0.5s ease;
}

/* Icons states */
/* In dark mode (default) */
html[data-theme="dark"] .sun-icon {
  transform: rotate(90deg) scale(0);
  opacity: 0;
}
html[data-theme="dark"] .moon-icon {
  transform: rotate(0deg) scale(1);
  opacity: 1;
}
/* In light mode */
html[data-theme="light"] .sun-icon {
  transform: rotate(0deg) scale(1);
  opacity: 1;
}
html[data-theme="light"] .moon-icon {
  transform: rotate(-90deg) scale(0);
  opacity: 0;
}

/* Smooth transitions for theme switching */
body, .header, .stat-card, .track-card, .premium-q-card, .sticky-sidebar-wrapper, .q-answer-wrapper, pre, code, .sidebar-link, a, h1, h2, h3, h4, h5, h6, input, button {
  transition: background-color 0.3s ease, border-color 0.3s ease, color 0.3s ease, box-shadow 0.3s ease;
}

/* ==========================================
   Syntax Highlighting Overrides for Light Mode
   ========================================== */
html[data-theme="light"] .hljs {
  background: var(--bg-pre);
  color: var(--text-pre);
}
html[data-theme="light"] .hljs-keyword,
html[data-theme="light"] .hljs-selector-tag,
html[data-theme="light"] .hljs-title,
html[data-theme="light"] .hljs-section,
html[data-theme="light"] .hljs-name {
  color: #D73A49; /* GitHub-style red keyword */
  font-weight: 600;
}
html[data-theme="light"] .hljs-string,
html[data-theme="light"] .hljs-meta .hljs-string {
  color: #032F62; /* GitHub-style deep blue string */
}
html[data-theme="light"] .hljs-comment,
html[data-theme="light"] .hljs-quote {
  color: #6A737D; /* Muted gray comment */
  font-style: italic;
}
html[data-theme="light"] .hljs-number,
html[data-theme="light"] .hljs-literal,
html[data-theme="light"] .hljs-symbol,
html[data-theme="light"] .hljs-bullet {
  color: #005CC5; /* Bright blue number */
}
html[data-theme="light"] .hljs-attr,
html[data-theme="light"] .hljs-variable,
html[data-theme="light"] .hljs-template-variable,
html[data-theme="light"] .hljs-tag .hljs-attr {
  color: #E36209; /* GitHub-style orange attributes */
}
html[data-theme="light"] .hljs-built_in,
html[data-theme="light"] .hljs-class .hljs-title {
  color: #6F42C1; /* Purple builtins */
}
html[data-theme="light"] .hljs-meta {
  color: #1B1F23; /* Meta text */
}

/* ===============================================================
   Interactive Developer Learning Platform Styles (v16.0)
   =============================================================== */

/* 1. Navbar Dropdowns & Mega Menu — Premium Viewport-Safe System */
.nav-item-dropdown {
  position: relative;
}
.nav-item-dropdown::after {
  content: '';
  position: absolute;
  top: 100%;
  left: 0;
  width: 100%;
  height: 30px;
  background: transparent;
  pointer-events: none;
  z-index: 99999;
}
.nav-item-dropdown:hover::after {
  pointer-events: auto;
}
.nav-dropbtn {
  background: transparent;
  border: none;
  color: var(--text-muted);
  font-family: inherit;
  font-size: 14px;
  font-weight: 500;
  cursor: pointer;
  display: flex;
  align-items: center;
  gap: 5px;
  padding: 6px 10px;
  border-radius: var(--radius-sm);
  transition: var(--transition);
  white-space: nowrap;
}
.nav-dropbtn:hover, .nav-dropbtn.active {
  color: var(--text-headings);
  background: var(--bg-hover-subtle);
}
.dropdown-chevron {
  transition: transform 0.2s ease;
  opacity: 0.6;
}
.nav-item-dropdown:hover .dropdown-chevron,
.nav-item-dropdown:focus-within .dropdown-chevron {
  transform: rotate(180deg);
}
/* ─── MEGA NAV BACKDROP ─────────────────────────────────────────── */
.mega-nav-backdrop {
  position: fixed;
  top: 76px;
  left: 0;
  width: 100vw;
  height: calc(100vh - 76px);
  background: rgba(0, 0, 0, 0.72);
  backdrop-filter: blur(3px);
  -webkit-backdrop-filter: blur(3px);
  opacity: 0;
  visibility: hidden;
  pointer-events: none;
  transition: opacity 0.22s ease, visibility 0.22s;
  z-index: 9998;
}
html[data-theme="light"] .mega-nav-backdrop {
  background: rgba(15, 23, 42, 0.35);
}
.mega-nav-backdrop.visible {
  opacity: 1;
  visibility: visible;
  pointer-events: auto;
}

/* ─── MEGA PANEL ────────────────────────────────────────────────── */
.mega-menu {
  position: fixed;
  top: var(--header-height, 76px);
  left: 0;
  right: 0;
  width: 100%;
  background: #07091A;
  border-top: 1px solid rgba(99, 102, 241, 0.3);
  border-bottom: 1px solid rgba(255, 255, 255, 0.06);
  box-shadow: 0 32px 80px -12px rgba(0, 0, 0, 0.9);
  opacity: 0;
  visibility: hidden;
  pointer-events: none;
  transform: translateY(-4px);
  transition:
    opacity 0.16s cubic-bezier(0.4, 0, 0.2, 1),
    transform 0.16s cubic-bezier(0.4, 0, 0.2, 1),
    visibility 0.16s;
  z-index: 9999;
  overflow: hidden;
}
html[data-theme="light"] .mega-menu {
  background: #F8F9FC;
  border-top-color: rgba(99, 102, 241, 0.25);
  border-bottom-color: rgba(15, 23, 42, 0.08);
  box-shadow: 0 32px 80px -12px rgba(15, 23, 42, 0.18);
}
.nav-item-dropdown:hover .mega-menu,
.nav-item-dropdown:focus-within .mega-menu {
  opacity: 1;
  visibility: visible;
  pointer-events: auto;
  transform: translateY(0);
}

/* ─── INNER LAYOUT ──────────────────────────────────────────────── */
.mega-menu-inner {
  max-width: 1200px;
  margin: 0 auto;
  padding: 28px 40px 24px;
}
.mega-menu-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  margin-bottom: 20px;
  padding-bottom: 14px;
  border-bottom: 1px solid rgba(255, 255, 255, 0.07);
}
html[data-theme="light"] .mega-menu-header {
  border-bottom-color: rgba(15, 23, 42, 0.08);
}
.mega-menu-label {
  font-size: 10px;
  font-weight: 800;
  text-transform: uppercase;
  letter-spacing: 0.12em;
  color: var(--primary);
  display: flex;
  align-items: center;
  gap: 8px;
}
.mega-menu-label::before {
  content: '';
  display: inline-block;
  width: 16px;
  height: 2px;
  background: var(--primary);
  border-radius: 2px;
}
.mega-view-all {
  font-size: 12px;
  font-weight: 600;
  color: var(--primary);
  text-decoration: none;
  display: flex;
  align-items: center;
  gap: 4px;
  opacity: 0.8;
  transition: opacity 0.15s ease, gap 0.15s ease;
}
.mega-view-all:hover {
  opacity: 1;
  gap: 8px;
  color: var(--primary);
}

/* ─── GRID LAYOUT ───────────────────────────────────────────────── */
.mega-menu-grid {
  display: grid;
  gap: 6px;
}
.grid-topics    { grid-template-columns: repeat(3, 1fr); }
.grid-prep      { grid-template-columns: repeat(3, 1fr); }
.grid-scenarios { grid-template-columns: repeat(3, 1fr); }

/* ─── MEGA ITEM CARD ────────────────────────────────────────────── */
.mega-item {
  display: flex;
  gap: 14px;
  padding: 13px 16px;
  border-radius: 12px;
  border: 1px solid rgba(255, 255, 255, 0.04);
  background: rgba(255, 255, 255, 0.02);
  transition: background 0.15s ease, border-color 0.15s ease, transform 0.15s ease, box-shadow 0.15s ease;
  align-items: center;
  text-decoration: none;
  cursor: pointer;
}
.mega-item:hover {
  background: rgba(99, 102, 241, 0.09);
  border-color: rgba(99, 102, 241, 0.2);
  box-shadow: 0 4px 16px rgba(99, 102, 241, 0.12);
  transform: translateY(-1px);
}
html[data-theme="light"] .mega-item {
  border-color: rgba(15, 23, 42, 0.06);
  background: rgba(255, 255, 255, 0.8);
}
html[data-theme="light"] .mega-item:hover {
  background: rgba(255, 255, 255, 1);
  border-color: rgba(99, 102, 241, 0.2);
  box-shadow: 0 4px 20px rgba(99, 102, 241, 0.1);
  transform: translateY(-1px);
}
.mega-item:hover .mega-title { color: var(--primary); }

/* ─── COLOR-CODED ICON BADGES ───────────────────────────────────── */
.mega-icon {
  width: 40px;
  height: 40px;
  min-width: 40px;
  border-radius: 10px;
  display: flex;
  align-items: center;
  justify-content: center;
  flex-shrink: 0;
  font-weight: 800;
  font-size: 10.5px;
  letter-spacing: 0.03em;
  font-family: var(--font-mono);
  transition: transform 0.15s ease;
  /* default: indigo */
  background: rgba(99, 102, 241, 0.15);
  border: 1px solid rgba(99, 102, 241, 0.25);
  color: #A5B4FC;
}
.mega-item:hover .mega-icon { transform: scale(1.08); }

/* Topic-specific icon colors */
.mega-icon.k8s  { background: rgba(50, 108, 229, 0.18); border-color: rgba(50,108,229,0.3);  color: #60A5FA; }
.mega-icon.aws  { background: rgba(255,153,0, 0.15);    border-color: rgba(255,153,0, 0.28); color: #FCD34D; }
.mega-icon.tf   { background: rgba(132,79,186,0.18);    border-color: rgba(132,79,186,0.3);  color: #C4B5FD; }
.mega-icon.dk   { background: rgba(36,150,237,0.18);    border-color: rgba(36,150,237,0.3);  color: #7DD3FC; }
.mega-icon.lx   { background: rgba(148,163,184,0.15);   border-color: rgba(148,163,184,0.25);color: #CBD5E1; }
.mega-icon.ci   { background: rgba(16,185,129,0.15);    border-color: rgba(16,185,129,0.28); color: #6EE7B7; }
.mega-icon.ob   { background: rgba(230, 82, 44, 0.15);  border-color: rgba(230,82,44,0.28);  color: #FCA5A5; }
.mega-icon.se   { background: rgba(244,63,94,0.15);     border-color: rgba(244,63,94,0.28);  color: #FDA4AF; }
.mega-icon.sd   { background: rgba(16,185,129,0.15);    border-color: rgba(16,185,129,0.28); color: #34D399; }

/* Light mode icon adjustments */
html[data-theme="light"] .mega-icon.k8s  { background: rgba(50,108,229,0.08);  border-color: rgba(50,108,229,0.18);  color: #2563EB; }
html[data-theme="light"] .mega-icon.aws  { background: rgba(255,153,0,0.08);   border-color: rgba(255,153,0,0.18);   color: #D97706; }
html[data-theme="light"] .mega-icon.tf   { background: rgba(132,79,186,0.08);  border-color: rgba(132,79,186,0.18);  color: #7C3AED; }
html[data-theme="light"] .mega-icon.dk   { background: rgba(36,150,237,0.08);  border-color: rgba(36,150,237,0.18);  color: #0284C7; }
html[data-theme="light"] .mega-icon.lx   { background: rgba(100,116,139,0.08); border-color: rgba(100,116,139,0.18); color: #475569; }
html[data-theme="light"] .mega-icon.ci   { background: rgba(16,185,129,0.08);  border-color: rgba(16,185,129,0.18);  color: #059669; }
html[data-theme="light"] .mega-icon.ob   { background: rgba(230,82,44,0.08);   border-color: rgba(230,82,44,0.18);   color: #DC2626; }
html[data-theme="light"] .mega-icon.se   { background: rgba(244,63,94,0.08);   border-color: rgba(244,63,94,0.18);   color: #BE123C; }
html[data-theme="light"] .mega-icon.sd   { background: rgba(16,185,129,0.08);  border-color: rgba(16,185,129,0.18);  color: #047857; }

/* Scenario emoji icons */
.mega-icon-scenario {
  width: 40px;
  height: 40px;
  min-width: 40px;
  border-radius: 10px;
  background: rgba(255, 255, 255, 0.04);
  border: 1px solid rgba(255, 255, 255, 0.08);
  display: flex;
  align-items: center;
  justify-content: center;
  flex-shrink: 0;
  font-size: 18px;
  transition: transform 0.15s ease, background 0.15s ease;
}
html[data-theme="light"] .mega-icon-scenario {
  background: rgba(15, 23, 42, 0.04);
  border-color: rgba(15, 23, 42, 0.1);
}
.mega-item:hover .mega-icon-scenario {
  transform: scale(1.08);
  background: rgba(99, 102, 241, 0.1);
  border-color: rgba(99, 102, 241, 0.2);
}

/* Prep level bullet dots */
.mega-bullet {
  width: 10px;
  height: 10px;
  min-width: 10px;
  border-radius: 50%;
  flex-shrink: 0;
  transition: transform 0.15s ease;
}
.mega-item:hover .mega-bullet { transform: scale(1.3); }
.mega-bullet.beginner     { background: #10B981; box-shadow: 0 0 10px rgba(16,185,129,0.6); }
.mega-bullet.intermediate { background: #F59E0B; box-shadow: 0 0 10px rgba(245,158,11,0.6); }
.mega-bullet.advanced     { background: #F43F5E; box-shadow: 0 0 10px rgba(244,63,94,0.6); }
.mega-bullet.sre          { background: #6366F1; box-shadow: 0 0 10px rgba(99,102,241,0.6); }
.mega-bullet.platform     { background: #8B5CF6; box-shadow: 0 0 10px rgba(139,92,246,0.6); }

/* ─── TEXT DETAILS ──────────────────────────────────────────────── */
.mega-details {
  display: flex;
  flex-direction: column;
  gap: 3px;
  min-width: 0;
}
.mega-title {
  font-size: 13.5px;
  font-weight: 600;
  color: var(--text-headings);
  line-height: 1.3;
  transition: color 0.15s ease;
  white-space: nowrap;
}
.mega-desc {
  font-size: 11.5px;
  color: var(--text-muted);
  line-height: 1.4;
}

/* ─── RESPONSIVE ─────────────────────────────────────────────────── */
@media (max-width: 1100px) {
  .grid-topics, .grid-prep, .grid-scenarios {
    grid-template-columns: repeat(2, 1fr);
  }
  .mega-menu-inner { padding: 24px 24px 20px; }
}
@media (max-width: 768px) {
  .nav-item-dropdown { display: none; }
}


/* 2. Global Sticky Command Palette Modal */
.search-modal-backdrop {
  position: fixed;
  top: 0;
  left: 0;
  width: 100vw;
  height: 100vh;
  background: rgba(6, 9, 19, 0.7);
  backdrop-filter: blur(8px);
  -webkit-backdrop-filter: blur(8px);
  z-index: 11000;
  display: flex;
  align-items: flex-start;
  justify-content: center;
  padding-top: 12vh;
  opacity: 0;
  visibility: hidden;
  transition: opacity 0.25s ease, visibility 0.25s ease;
}
.search-modal-backdrop.open {
  opacity: 1;
  visibility: visible;
}
.search-modal {
  width: 90%;
  max-width: 600px;
  background: var(--bg-card);
  border: 1px solid var(--border);
  border-radius: var(--radius-md);
  box-shadow: var(--shadow-lg), 0 0 40px rgba(99, 102, 241, 0.08);
  overflow: hidden;
  transform: scale(0.97);
  transition: transform 0.2s cubic-bezier(0.16, 1, 0.3, 1);
}
.search-modal-backdrop.open .search-modal {
  transform: scale(1);
}
.search-modal-header {
  display: flex;
  align-items: center;
  border-bottom: 1px solid var(--border);
  padding: 16px 20px;
  gap: 12px;
}
.search-modal-input {
  flex: 1;
  background: transparent;
  border: none;
  color: var(--text-main);
  font-size: 16px;
  font-family: inherit;
  outline: none;
}
.search-modal-input::placeholder {
  color: var(--text-muted);
}
.search-modal-close-btn {
  background: transparent;
  border: none;
  color: var(--text-muted);
  cursor: pointer;
  font-size: 24px;
  line-height: 1;
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 4px;
}
.search-modal-close-btn:hover {
  color: var(--text-main);
}
.search-modal-body {
  max-height: 380px;
  overflow-y: auto;
  padding: 16px 0;
}
.search-suggestions-title {
  font-size: 11px;
  text-transform: uppercase;
  font-weight: 700;
  letter-spacing: 0.05em;
  color: var(--text-muted);
  padding: 0 20px 8px;
}
.search-suggestions-list {
  list-style: none;
}
.search-suggestion-item a {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 12px 20px;
  color: var(--text-main);
  font-size: 14.5px;
  transition: var(--transition);
  text-decoration: none;
}
.search-suggestion-item:hover a,
.search-suggestion-item.active a {
  background: var(--bg-hover-subtle);
  color: var(--primary);
}
.search-suggestion-left {
  display: flex;
  align-items: center;
  gap: 12px;
}
.search-suggestion-badge {
  font-size: 11px;
  padding: 2px 6px;
  border-radius: 4px;
  background: var(--border);
  color: var(--text-muted);
}
.search-suggestion-item.active .search-suggestion-badge {
  background: rgba(99, 102, 241, 0.1);
  color: var(--primary);
}
.search-modal-footer {
  padding: 12px 20px;
  border-top: 1px solid var(--border);
  background: rgba(0, 0, 0, 0.1);
  display: flex;
  justify-content: space-between;
  align-items: center;
  font-size: 11.5px;
  color: var(--text-muted);
}
html[data-theme="light"] .search-modal-footer {
  background: rgba(15, 23, 42, 0.02);
}
.search-shortcuts {
  display: flex;
  gap: 12px;
}
.search-shortcut-item {
  display: flex;
  align-items: center;
  gap: 4px;
}
.search-kbd {
  background: var(--bg-page);
  border: 1px solid var(--border);
  border-radius: 4px;
  padding: 1px 5px;
  font-family: var(--font-mono);
  box-shadow: 0 1px 0 rgba(0,0,0,0.15);
  font-size: 10px;
}

/* Floating Search Button Trigger */
.floating-search-trigger {
  position: fixed;
  bottom: 24px;
  right: 24px;
  width: 48px;
  height: 48px;
  border-radius: 50%;
  background: var(--primary);
  color: var(--white);
  border: none;
  box-shadow: var(--shadow-lg), 0 0 20px rgba(99, 102, 241, 0.25);
  display: flex;
  align-items: center;
  justify-content: center;
  cursor: pointer;
  z-index: 99;
  transition: var(--transition);
}
.floating-search-trigger:hover {
  transform: translateY(-2px) scale(1.05);
  background: var(--primary-hover);
}

/* Navbar Search Input Icon Style */
.nav-search-btn-trigger {
  background: var(--bg-hover-subtle);
  border: 1px solid var(--border);
  border-radius: var(--radius-sm);
  padding: 6px 12px;
  display: flex;
  align-items: center;
  gap: 8px;
  cursor: pointer;
  color: var(--text-muted);
  font-size: 13px;
  transition: var(--transition);
}
.nav-search-btn-trigger:hover {
  border-color: var(--border-hover);
  color: var(--text-main);
}

/* 3. Trending Questions Section */
.trending-questions-section {
  padding: 80px 0 60px;
  position: relative;
}
.trending-grid {
  display: flex;
  flex-direction: column;
  gap: 20px;
  margin-top: 32px;
}
.trending-card {
  background: var(--bg-card);
  border: 1px solid var(--border);
  border-radius: var(--radius-md);
  box-shadow: var(--shadow-md);
  transition: var(--transition);
  overflow: hidden;
  position: relative;
}
.trending-card:hover {
  transform: translateY(-2px);
  border-color: var(--primary);
  box-shadow: var(--shadow-lg), var(--shadow-glow);
}
.trending-card-header {
  padding: 24px 30px;
  cursor: pointer;
}
.trending-meta-row {
  display: flex;
  gap: 8px;
  margin-bottom: 12px;
  align-items: center;
  flex-wrap: wrap;
}
.trending-title-wrap {
  display: flex;
  gap: 12px;
  align-items: flex-start;
}
.trending-q-prefix {
  font-family: var(--font-mono);
  color: var(--primary);
  font-weight: 700;
  font-size: 20px;
  margin-top: -1px;
}
.trending-title {
  font-size: 19px;
  font-weight: 700;
  margin: 0;
  color: var(--text-headings);
  flex: 1;
}
.trending-preview-text {
  font-size: 14.5px;
  color: var(--text-muted);
  margin-top: 8px;
  margin-left: 32px;
}
.trending-action-bar {
  display: flex;
  justify-content: space-between;
  align-items: center;
  margin-top: 20px;
  margin-left: 32px;
}
.reveal-btn {
  background: rgba(99, 102, 241, 0.08);
  border: 1px solid rgba(99, 102, 241, 0.15);
  color: var(--primary);
  padding: 6px 16px;
  border-radius: 6px;
  font-weight: 600;
  font-size: 13px;
  display: flex;
  align-items: center;
  gap: 8px;
  cursor: pointer;
  transition: var(--transition);
}
.reveal-btn:hover {
  background: var(--primary);
  color: var(--white);
}
.reveal-btn svg {
  transition: transform 0.25s ease;
}
.trending-card.expanded .reveal-btn svg {
  transform: rotate(180deg);
}

.trending-answer-wrapper {
  max-height: 0;
  overflow: hidden;
  transition: max-height 0.35s cubic-bezier(0.16, 1, 0.3, 1);
  background: rgba(0, 0, 0, 0.15);
  border-top: 1px solid var(--border);
}
html[data-theme="light"] .trending-answer-wrapper {
  background: rgba(15, 23, 42, 0.02);
}
.trending-answer-content {
  padding: 30px;
}

/* Tabbed Interface inside quick answers */
.tab-headers {
  display: flex;
  border-bottom: 1px solid var(--border);
  gap: 8px;
  margin-bottom: 24px;
  overflow-x: auto;
}
.tab-btn {
  background: transparent;
  border: none;
  border-bottom: 2px solid transparent;
  color: var(--text-muted);
  font-family: inherit;
  font-size: 13px;
  font-weight: 600;
  padding: 8px 16px 12px;
  cursor: pointer;
  transition: var(--transition);
  white-space: nowrap;
}
.tab-btn:hover {
  color: var(--text-main);
}
.tab-btn.active {
  color: var(--primary);
  border-bottom-color: var(--primary);
}
.tab-pane {
  display: none;
  animation: fadeIn 0.25s ease;
}
.tab-pane.active {
  display: block;
}

/* 4. Mock Terminal Window Styles */
.mock-terminal {
  background: #0B0E14;
  border: 1px solid rgba(255, 255, 255, 0.06);
  border-radius: 8px;
  overflow: hidden;
  box-shadow: 0 8px 24px rgba(0,0,0,0.3);
  margin: 16px 0;
  font-family: var(--font-mono);
}
.terminal-header {
  background: #121620;
  padding: 10px 16px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  border-bottom: 1px solid rgba(255, 255, 255, 0.04);
}
.terminal-dots {
  display: flex;
  gap: 6px;
}
.terminal-dot {
  width: 10px;
  height: 10px;
  border-radius: 50%;
}
.terminal-dot.red { background: #EF4444; }
.terminal-dot.yellow { background: #F59E0B; }
.terminal-dot.green { background: #10B981; }
.terminal-title {
  font-size: 11px;
  color: #64748B;
  font-weight: 500;
}
.terminal-body {
  padding: 16px 20px;
  margin: 0;
  overflow-x: auto;
}
.terminal-body pre {
  margin: 0;
  background: transparent !important;
  border: none !important;
  padding: 0 !important;
  box-shadow: none !important;
}
.terminal-body code {
  color: #E2E8F0 !important;
  font-size: 13px !important;
  background: transparent !important;
  padding: 0 !important;
}

/* Steps lists */
.troubleshooting-steps {
  list-style: none;
  display: flex;
  flex-direction: column;
  gap: 12px;
}
.troubleshooting-steps li {
  display: flex;
  gap: 12px;
  align-items: flex-start;
  font-size: 14.5px;
  line-height: 1.5;
}
.step-number {
  background: rgba(99, 102, 241, 0.1);
  color: var(--primary);
  width: 24px;
  height: 24px;
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  font-weight: 700;
  font-size: 11.5px;
  flex-shrink: 0;
}

/* Interactive flow diagrams */
.mini-diagram {
  background: var(--bg-page);
  border: 1px solid var(--border);
  border-radius: 6px;
  padding: 20px;
  display: flex;
  align-items: center;
  justify-content: center;
  flex-direction: column;
  gap: 12px;
  margin: 16px 0;
}
.diagram-flow {
  display: flex;
  align-items: center;
  gap: 10px;
  flex-wrap: wrap;
  justify-content: center;
}
.diagram-node {
  background: var(--bg-card);
  border: 1px solid var(--border);
  border-radius: 4px;
  padding: 6px 14px;
  font-size: 12.5px;
  font-family: var(--font-mono);
  font-weight: 600;
  color: var(--text-main);
  box-shadow: var(--shadow-sm);
}
.diagram-node.highlight {
  border-color: var(--primary);
  color: var(--primary);
  background: rgba(99, 102, 241, 0.04);
}
.diagram-arrow {
  color: var(--text-muted);
  font-weight: bold;
}

/* 5. "Why Us" Positioning Section */
.why-us-section {
  padding: 80px 0;
  background: var(--bg-section-gray);
  position: relative;
}
.why-us-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(280px, 1fr));
  gap: 24px;
  margin-top: 48px;
}
.why-card {
  background: var(--bg-card);
  border: 1px solid var(--border);
  border-radius: var(--radius-md);
  padding: 30px;
  box-shadow: var(--shadow-md);
  transition: var(--transition);
}
.why-card:hover {
  transform: translateY(-4px);
  border-color: var(--primary);
  box-shadow: var(--shadow-lg);
}
.why-icon {
  width: 48px;
  height: 48px;
  border-radius: 12px;
  background: rgba(99, 102, 241, 0.08);
  color: var(--primary);
  display: flex;
  align-items: center;
  justify-content: center;
  margin-bottom: 20px;
}
.why-card h3 {
  font-size: 18px;
  margin-bottom: 12px;
  color: var(--text-headings);
}
.why-card p {
  font-size: 14px;
  color: var(--text-muted);
  margin: 0;
  line-height: 1.5;
}

/* 6. Personalization Dashboard Widget */
.workspace-section {
  padding: 40px 0 20px;
  position: relative;
}
.workspace-card {
  background: var(--bg-card);
  border: 1px solid var(--border);
  border-radius: var(--radius-lg);
  padding: 30px;
  box-shadow: var(--shadow-md);
}
.workspace-header-row {
  display: flex;
  justify-content: space-between;
  align-items: center;
  border-bottom: 1px solid var(--border);
  padding-bottom: 18px;
  margin-bottom: 24px;
  flex-wrap: wrap;
  gap: 16px;
}
.workspace-title-area {
  display: flex;
  align-items: center;
  gap: 12px;
}
.workspace-title-area h2 {
  margin: 0;
  font-size: 22px;
  color: var(--text-headings);
}
.workspace-tabs {
  display: flex;
  gap: 8px;
  flex-wrap: wrap;
}
.workspace-tab-btn {
  background: transparent;
  border: 1px solid var(--border);
  padding: 8px 16px;
  border-radius: 6px;
  font-size: 13.5px;
  font-weight: 600;
  color: var(--text-muted);
  cursor: pointer;
  transition: var(--transition);
}
.workspace-tab-btn:hover {
  border-color: var(--border-hover);
  color: var(--text-main);
}
.workspace-tab-btn.active {
  background: var(--primary);
  color: var(--white);
  border-color: var(--primary);
}
.workspace-content {
  min-height: 100px;
}
.workspace-panel {
  display: none;
  animation: fadeIn 0.25s ease;
}
.workspace-panel.active {
  display: block;
}
.workspace-list {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(280px, 1fr));
  gap: 20px;
  list-style: none;
  padding: 0;
  margin: 0;
}
.workspace-item-link {
  display: flex;
  flex-direction: column;
  padding: 16px 20px;
  background: var(--bg-hover-subtle);
  border: 1px solid var(--border);
  border-radius: var(--radius-sm);
  transition: var(--transition);
  text-decoration: none;
  height: 100%;
  justify-content: space-between;
}
.workspace-item-link:hover {
  border-color: var(--primary);
  background: var(--bg-card);
  box-shadow: var(--shadow-sm);
}
.workspace-item-meta {
  display: flex;
  justify-content: space-between;
  align-items: center;
  font-size: 11px;
  color: var(--text-muted);
  margin-bottom: 6px;
}
.workspace-item-title {
  font-size: 14.5px;
  font-weight: 600;
  color: var(--text-headings);
  line-height: 1.4;
}

/* Bookmark Buttons */
.q-bookmark-btn {
  background: transparent;
  border: none;
  color: var(--text-muted);
  cursor: pointer;
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 6px;
  border-radius: 4px;
  transition: var(--transition);
}
.q-bookmark-btn:hover {
  background: var(--bg-hover-subtle);
  color: var(--primary);
}
.q-bookmark-btn.bookmarked {
  color: var(--warning);
}
.q-bookmark-btn.bookmarked svg {
  fill: currentColor;
}

/* Empty State Styling for Workspace */
.workspace-empty-state {
  text-align: center;
  padding: 40px 20px;
  color: var(--text-muted);
  font-size: 14.5px;
}
.workspace-empty-state svg {
  margin-bottom: 12px;
  color: var(--text-muted);
  opacity: 0.7;
}

@keyframes fadeIn {
  from { opacity: 0; transform: translateY(4px); }
  to { opacity: 1; transform: translateY(0); }
}

/* Mobile responsive fixes for menu */
@media (max-width: 1024px) {
  .nav-links {
    display: none;
  }
  .nav-search-btn-trigger {
    display: none;
  }
}
@media (max-width: 768px) {
  .trending-card-header {
    padding: 20px;
  }
  .trending-title {
    font-size: 16px;
  }
  .trending-preview-text {
    margin-left: 0;
    margin-top: 12px;
  }
  .trending-action-bar {
    margin-left: 0;
    margin-top: 16px;
  }
  .trending-answer-content {
    padding: 20px;
  }
}


