/* BetterLearn Documentation - Premium Design System
   Matching the main application design:
   - Primary: #2A66FF (Blue)
   - Text: #0F3547 (Dark Teal)
   - Background: #FCFBF8 (Warm off-white)
   - Border: #E7E7E7
   - Font: Manrope (primary), Inter (fallback)
*/

/* ===== CSS Variables ===== */
:root {
  /* Primary Colors - Matching App */
  --primary: #2A66FF;
  --primary-dark: #1e54e6;
  --primary-light: #5a8aff;
  --primary-bg: rgba(42, 102, 255, 0.08);
  --primary-border: rgba(42, 102, 255, 0.2);
  --primary-gradient: linear-gradient(135deg, #2A66FF 0%, #1e54e6 100%);

  /* Text Colors - Matching App */
  --text-primary: #0F3547;
  --text-secondary: rgba(15, 53, 71, 0.75);
  --text-muted: rgba(15, 53, 71, 0.5);
  --text-light: rgba(15, 53, 71, 0.4);
  --text-white: #FFFFFF;

  /* Background Colors - Matching App */
  --bg-white: #FFFFFF;
  --bg-cream: #FCFBF8;
  --bg-light: #F8F8F8;
  --bg-surface: #FAFAF9;
  --bg-dark: #0F3547;

  /* Border Colors */
  --border: #E7E7E7;
  --border-light: rgba(231, 231, 231, 0.6);
  --border-hover: #d4d4d4;

  /* Accent Colors */
  --success: #10b981;
  --success-bg: rgba(16, 185, 129, 0.1);
  --success-border: rgba(16, 185, 129, 0.2);
  
  --warning: #f59e0b;
  --warning-bg: rgba(245, 158, 11, 0.1);
  --warning-border: rgba(245, 158, 11, 0.2);
  
  --error: #ef4444;
  --error-bg: rgba(239, 68, 68, 0.1);
  --error-border: rgba(239, 68, 68, 0.2);
  
  --info: #06b6d4;
  --info-bg: rgba(6, 182, 212, 0.1);
  --info-border: rgba(6, 182, 212, 0.2);
  
  --purple: #8b5cf6;
  --purple-bg: rgba(139, 92, 246, 0.1);
  --purple-border: rgba(139, 92, 246, 0.2);
  
  --pink: #ec4899;
  --pink-bg: rgba(236, 72, 153, 0.1);
  --pink-border: rgba(236, 72, 153, 0.2);

  /* Shadows */
  --shadow-sm: 0 1px 3px rgba(0, 0, 0, 0.04), 0 1px 2px rgba(0, 0, 0, 0.02);
  --shadow-md: 0 4px 12px rgba(0, 0, 0, 0.05), 0 2px 4px rgba(0, 0, 0, 0.03);
  --shadow-lg: 0 10px 25px rgba(0, 0, 0, 0.08), 0 5px 10px rgba(0, 0, 0, 0.04);
  --shadow-xl: 0 20px 40px rgba(0, 0, 0, 0.1);
  --shadow-primary: 0 4px 16px rgba(42, 102, 255, 0.25);
  --shadow-glow: 0 0 40px rgba(42, 102, 255, 0.15);

  /* Border Radius */
  --radius-sm: 8px;
  --radius-md: 12px;
  --radius-lg: 16px;
  --radius-xl: 20px;
  --radius-2xl: 24px;
  --radius-full: 9999px;

  /* Typography - Matching App */
  --font-sans: 'Manrope', 'Inter', -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, sans-serif;
  --font-mono: 'JetBrains Mono', 'Fira Code', 'SF Mono', Consolas, monospace;

  /* Transitions */
  --transition-fast: 150ms cubic-bezier(0.4, 0, 0.2, 1);
  --transition-base: 200ms cubic-bezier(0.4, 0, 0.2, 1);
  --transition-slow: 300ms cubic-bezier(0.4, 0, 0.2, 1);
  --transition-spring: 400ms cubic-bezier(0.34, 1.56, 0.64, 1);
}

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

html {
  scroll-behavior: smooth;
  font-size: 16px;
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
}

body {
  font-family: var(--font-sans);
  background: var(--bg-cream);
  color: var(--text-primary);
  line-height: 1.65;
  min-height: 100vh;
  font-weight: 400;
}

/* ===== Layout ===== */
.docs-container {
  display: flex;
  min-height: 100vh;
}

/* ===== Sidebar ===== */
.sidebar {
  position: fixed;
  top: 0;
  left: 0;
  width: 280px;
  height: 100vh;
  background: var(--bg-white);
  border-right: 1px solid var(--border);
  display: flex;
  flex-direction: column;
  z-index: 100;
  transition: transform var(--transition-slow);
}

.sidebar-header {
  padding: 24px;
  border-bottom: 1px solid var(--border);
  background: var(--bg-white);
}

.sidebar-brand {
  display: flex;
  align-items: center;
  gap: 12px;
  text-decoration: none;
}

.sidebar-logo {
  width: 42px;
  height: 42px;
  object-fit: contain;
}

.sidebar-title {
  font-size: 19px;
  font-weight: 700;
  color: var(--text-primary);
  letter-spacing: -0.02em;
}

.sidebar-version {
  font-size: 11px;
  font-weight: 700;
  color: var(--primary);
  background: var(--primary-bg);
  padding: 3px 8px;
  border-radius: var(--radius-full);
  margin-left: 4px;
}

.sidebar-nav {
  flex: 1;
  overflow-y: auto;
  padding: 16px 12px;
}

.nav-section {
  margin-bottom: 24px;
}

.nav-section-title {
  font-size: 11px;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.1em;
  color: var(--text-muted);
  padding: 0 12px;
  margin-bottom: 8px;
}

.nav-link {
  display: flex;
  align-items: center;
  gap: 12px;
  padding: 11px 14px;
  border-radius: var(--radius-md);
  color: var(--text-secondary);
  text-decoration: none;
  font-size: 14px;
  font-weight: 500;
  transition: all var(--transition-fast);
}

.nav-link:hover {
  background: var(--bg-light);
  color: var(--text-primary);
  transform: translateX(2px);
}

.nav-link.active {
  background: var(--primary-bg);
  color: var(--primary);
  font-weight: 600;
}

.nav-link svg,
.nav-link .nav-icon {
  width: 18px;
  height: 18px;
  flex-shrink: 0;
  display: flex;
  align-items: center;
  justify-content: center;
}

/* ===== Main Content ===== */
.main-content {
  margin-left: 280px;
  flex: 1;
  min-height: 100vh;
  background: var(--bg-cream);
}

.content-wrapper {
  max-width: 960px;
  margin: 0 auto;
  padding: 48px 48px 100px;
}

/* ===== Typography ===== */
h1, h2, h3, h4, h5, h6 {
  font-weight: 700;
  color: var(--text-primary);
  line-height: 1.3;
  letter-spacing: -0.02em;
}

h1 {
  font-size: 2.75rem;
  margin-bottom: 20px;
  font-weight: 800;
}

h2 {
  font-size: 1.75rem;
  margin-top: 56px;
  margin-bottom: 20px;
  padding-bottom: 16px;
  border-bottom: 1px solid var(--border);
}

h3 {
  font-size: 1.25rem;
  margin-top: 32px;
  margin-bottom: 14px;
}

h4 {
  font-size: 1.1rem;
  margin-top: 24px;
  margin-bottom: 10px;
}

p {
  margin-bottom: 16px;
  color: var(--text-secondary);
  line-height: 1.7;
}

a {
  color: var(--primary);
  text-decoration: none;
  font-weight: 500;
  transition: color var(--transition-fast);
}

a:hover {
  color: var(--primary-dark);
  text-decoration: underline;
}

/* ===== Section Titles ===== */
.section-title {
  display: flex;
  align-items: center;
  gap: 14px;
  margin-top: 64px;
  margin-bottom: 20px;
  padding-bottom: 16px;
  border-bottom: 1px solid var(--border);
}

.section-icon {
  font-size: 1.5rem;
}

.section-badge {
  font-size: 0.75rem;
  font-weight: 700;
  color: var(--primary);
  background: var(--primary-bg);
  padding: 4px 10px;
  border-radius: var(--radius-full);
  margin-left: auto;
}

.section-description {
  font-size: 1.05rem;
  color: var(--text-secondary);
  margin-bottom: 28px;
  max-width: 700px;
}

/* ===== Hero Section ===== */
.hero {
  background: var(--bg-white);
  border: 1px solid var(--border);
  border-radius: var(--radius-2xl);
  padding: 56px 48px;
  margin-bottom: 40px;
  position: relative;
  overflow: hidden;
}

.hero::before {
  content: '';
  position: absolute;
  top: -100px;
  right: -100px;
  width: 400px;
  height: 400px;
  background: radial-gradient(circle, rgba(42, 102, 255, 0.08) 0%, transparent 70%);
  pointer-events: none;
}

.hero::after {
  content: '';
  position: absolute;
  bottom: -150px;
  left: -150px;
  width: 350px;
  height: 350px;
  background: radial-gradient(circle, rgba(139, 92, 246, 0.06) 0%, transparent 70%);
  pointer-events: none;
}

.hero-content {
  position: relative;
  z-index: 1;
}

.hero-badge {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  background: var(--primary-bg);
  color: var(--primary);
  padding: 8px 16px;
  border-radius: var(--radius-full);
  font-size: 13px;
  font-weight: 600;
  margin-bottom: 24px;
}

.hero-badge-icon {
  font-size: 16px;
}

.hero h1 {
  font-size: 3rem;
  margin-bottom: 20px;
  background: linear-gradient(135deg, var(--text-primary) 0%, var(--primary) 100%);
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
  background-clip: text;
}

.hero-subtitle {
  font-size: 1.2rem;
  color: var(--text-secondary);
  margin-bottom: 32px;
  max-width: 680px;
  line-height: 1.7;
}

.hero-actions {
  display: flex;
  gap: 14px;
  flex-wrap: wrap;
}

/* ===== Buttons ===== */
.btn {
  display: inline-flex;
  align-items: center;
  gap: 10px;
  padding: 14px 28px;
  font-size: 15px;
  font-weight: 600;
  border-radius: var(--radius-md);
  border: none;
  cursor: pointer;
  text-decoration: none;
  transition: all var(--transition-fast);
  font-family: var(--font-sans);
}

.btn-primary {
  background: var(--primary-gradient);
  color: var(--text-white);
  box-shadow: var(--shadow-primary);
}

.btn-primary:hover {
  transform: translateY(-2px);
  box-shadow: 0 8px 24px rgba(42, 102, 255, 0.35);
  text-decoration: none;
  color: var(--text-white);
}

.btn-secondary {
  background: var(--bg-white);
  color: var(--text-primary);
  border: 1px solid var(--border);
  box-shadow: var(--shadow-sm);
}

.btn-secondary:hover {
  background: var(--bg-light);
  border-color: var(--border-hover);
  color: var(--text-primary);
  text-decoration: none;
}

.btn-outline {
  background: transparent;
  color: var(--primary);
  border: 1px solid var(--primary-border);
}

.btn-outline:hover {
  background: var(--primary-bg);
  text-decoration: none;
}

/* ===== Version Banner ===== */
.version-banner {
  background: var(--primary-gradient);
  color: var(--text-white);
  border-radius: var(--radius-xl);
  padding: 24px 32px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  margin-bottom: 40px;
  box-shadow: var(--shadow-primary);
}

.version-banner-content {
  display: flex;
  align-items: center;
  gap: 20px;
}

.version-badge {
  background: rgba(255, 255, 255, 0.15);
  border-radius: var(--radius-md);
  padding: 12px 16px;
  text-align: center;
  backdrop-filter: blur(10px);
}

.version-number {
  font-size: 1.75rem;
  font-weight: 800;
  display: block;
  line-height: 1;
}

.version-label {
  font-size: 11px;
  font-weight: 600;
  text-transform: uppercase;
  letter-spacing: 0.1em;
  opacity: 0.9;
}

.version-info h3 {
  color: var(--text-white);
  margin: 0 0 4px;
  font-size: 1.15rem;
}

.version-info p {
  color: rgba(255, 255, 255, 0.85);
  margin: 0;
  font-size: 14px;
}

/* ===== Badges ===== */
.badge {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  padding: 6px 14px;
  font-size: 12px;
  font-weight: 700;
  border-radius: var(--radius-full);
}

.badge-new {
  background: rgba(255, 255, 255, 0.2);
  color: var(--text-white);
  backdrop-filter: blur(10px);
}

.badge-primary {
  background: var(--primary-bg);
  color: var(--primary);
}

.badge-success {
  background: var(--success-bg);
  color: var(--success);
}

/* ===== Stats Grid ===== */
.stats-grid {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 20px;
  margin: 40px 0;
}

.stat-card {
  background: var(--bg-white);
  border: 1px solid var(--border);
  border-radius: var(--radius-xl);
  padding: 28px;
  text-align: center;
  transition: all var(--transition-base);
  position: relative;
  overflow: hidden;
}

.stat-card::before {
  content: '';
  position: absolute;
  inset: 0;
  opacity: 0;
  transition: opacity var(--transition-base);
}

.stat-card-primary::before {
  background: linear-gradient(135deg, rgba(42, 102, 255, 0.05) 0%, transparent 100%);
}

.stat-card-success::before {
  background: linear-gradient(135deg, rgba(16, 185, 129, 0.05) 0%, transparent 100%);
}

.stat-card-purple::before {
  background: linear-gradient(135deg, rgba(139, 92, 246, 0.05) 0%, transparent 100%);
}

.stat-card-info::before {
  background: linear-gradient(135deg, rgba(6, 182, 212, 0.05) 0%, transparent 100%);
}

.stat-card:hover {
  transform: translateY(-4px);
  box-shadow: var(--shadow-lg);
  border-color: var(--border-hover);
}

.stat-card:hover::before {
  opacity: 1;
}

.stat-icon {
  font-size: 28px;
  margin-bottom: 12px;
}

.stat-value {
  font-size: 2.5rem;
  font-weight: 800;
  line-height: 1;
  margin-bottom: 8px;
  position: relative;
}

.stat-card-primary .stat-value { color: var(--primary); }
.stat-card-success .stat-value { color: var(--success); }
.stat-card-purple .stat-value { color: var(--purple); }
.stat-card-info .stat-value { color: var(--info); }

.stat-label {
  font-size: 14px;
  color: var(--text-secondary);
  font-weight: 500;
}

/* ===== Callouts ===== */
.callout {
  border-radius: var(--radius-lg);
  padding: 24px;
  margin: 28px 0;
  display: flex;
  gap: 18px;
  align-items: flex-start;
}

.callout-icon {
  width: 28px;
  height: 28px;
  flex-shrink: 0;
  display: flex;
  align-items: center;
  justify-content: center;
  border-radius: var(--radius-sm);
  font-size: 15px;
}

.callout-content {
  flex: 1;
}

.callout-title {
  font-weight: 700;
  margin-bottom: 6px;
  font-size: 15px;
}

.callout-text {
  font-size: 14px;
  margin: 0;
  line-height: 1.6;
}

/* Callout Variants */
.callout-info {
  background: var(--info-bg);
  border: 1px solid var(--info-border);
}

.callout-info .callout-icon {
  background: var(--info);
  color: var(--text-white);
}

.callout-info .callout-title {
  color: #0e7490;
}

.callout-success {
  background: var(--success-bg);
  border: 1px solid var(--success-border);
}

.callout-success .callout-icon {
  background: var(--success);
  color: var(--text-white);
}

.callout-success .callout-title {
  color: #047857;
}

.callout-warning {
  background: var(--warning-bg);
  border: 1px solid var(--warning-border);
}

.callout-warning .callout-icon {
  background: var(--warning);
  color: var(--text-white);
}

.callout-warning .callout-title {
  color: #b45309;
}

.callout-purple {
  background: var(--purple-bg);
  border: 1px solid var(--purple-border);
}

.callout-purple .callout-icon {
  background: var(--purple);
  color: var(--text-white);
}

.callout-purple .callout-title {
  color: #6d28d9;
}

/* Gradient Callout */
.callout-gradient {
  background: linear-gradient(135deg, var(--purple-bg) 0%, var(--primary-bg) 100%);
  border: 1px solid var(--purple-border);
  padding: 28px 32px;
}

.callout-gradient .callout-icon-wrapper {
  background: var(--primary-gradient);
  padding: 14px;
  border-radius: var(--radius-md);
  box-shadow: var(--shadow-primary);
}

.callout-gradient .callout-icon {
  background: none;
  font-size: 22px;
}

.callout-gradient .callout-title {
  color: var(--text-primary);
  font-size: 18px;
  margin-bottom: 12px;
}

.callout-features {
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
}

.callout-feature {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  font-size: 14px;
  color: var(--text-secondary);
  background: rgba(255, 255, 255, 0.6);
  padding: 6px 14px;
  border-radius: var(--radius-full);
  border: 1px solid var(--border);
}

.feature-dot {
  width: 6px;
  height: 6px;
  background: var(--primary);
  border-radius: 50%;
}

/* ===== Feature Showcase ===== */
.feature-showcase {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 20px;
  margin: 32px 0;
}

.feature-card {
  background: var(--bg-white);
  border: 1px solid var(--border);
  border-radius: var(--radius-xl);
  padding: 28px;
  display: flex;
  flex-direction: column;
  gap: 14px;
  transition: all var(--transition-base);
}

.feature-card:hover {
  border-color: var(--primary-border);
  transform: translateY(-4px);
  box-shadow: var(--shadow-lg);
}

.feature-card-large {
  grid-column: span 3;
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 28px;
  padding: 36px;
}

.feature-card-large .feature-card-header {
  display: flex;
  align-items: center;
  gap: 14px;
}

.feature-tag {
  font-size: 11px;
  font-weight: 700;
  color: var(--primary);
  background: var(--primary-bg);
  padding: 4px 10px;
  border-radius: var(--radius-full);
}

.feature-list {
  margin: 0;
  padding-left: 0;
  list-style: none;
}

.feature-list li {
  display: flex;
  align-items: center;
  gap: 10px;
  padding: 8px 0;
  font-size: 14px;
  color: var(--text-secondary);
}

.feature-list li::before {
  content: '✓';
  width: 20px;
  height: 20px;
  background: var(--success-bg);
  color: var(--success);
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 11px;
  font-weight: 700;
}

.card-icon {
  width: 52px;
  height: 52px;
  display: flex;
  align-items: center;
  justify-content: center;
  border-radius: var(--radius-lg);
  font-size: 26px;
  flex-shrink: 0;
}

.card-icon-primary {
  background: var(--primary-bg);
}

.card-icon-success {
  background: var(--success-bg);
}

.card-icon-warning {
  background: var(--warning-bg);
}

.card-icon-info {
  background: var(--info-bg);
}

.card-icon-purple {
  background: var(--purple-bg);
}

.card-icon-pink {
  background: var(--pink-bg);
}

.feature-card h3 {
  margin: 0;
  font-size: 1.1rem;
}

.feature-card p {
  margin: 0;
  font-size: 14px;
  color: var(--text-secondary);
}

/* ===== Tools Grid ===== */
.tools-grid {
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  gap: 20px;
  margin: 32px 0;
}

.tool-category {
  background: var(--bg-white);
  border: 1px solid var(--border);
  border-radius: var(--radius-xl);
  padding: 24px;
  transition: all var(--transition-base);
}

.tool-category:hover {
  border-color: var(--primary-border);
  box-shadow: var(--shadow-md);
}

.tool-category-header {
  display: flex;
  align-items: flex-start;
  gap: 16px;
  margin-bottom: 16px;
}

.tool-category-icon {
  font-size: 28px;
  background: var(--primary-bg);
  width: 48px;
  height: 48px;
  display: flex;
  align-items: center;
  justify-content: center;
  border-radius: var(--radius-md);
}

.tool-category-header h4 {
  margin: 0;
  font-size: 1rem;
}

.tool-category-header p {
  margin: 2px 0 0;
  font-size: 13px;
  color: var(--text-muted);
}

.tool-items {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
}

.tool-item {
  font-size: 12px;
  color: var(--text-secondary);
  background: var(--bg-light);
  padding: 6px 12px;
  border-radius: var(--radius-full);
  border: 1px solid var(--border);
}

/* ===== Student Tools Showcase ===== */
.student-tools-showcase {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 16px;
  margin: 32px 0;
}

.student-tool-card {
  background: var(--bg-white);
  border: 1px solid var(--border);
  border-radius: var(--radius-lg);
  padding: 24px;
  text-align: center;
  transition: all var(--transition-base);
}

.student-tool-card:hover {
  border-color: var(--primary-border);
  transform: translateY(-3px);
  box-shadow: var(--shadow-md);
}

.student-tool-icon {
  font-size: 36px;
  margin-bottom: 14px;
}

.student-tool-card h4 {
  margin: 0 0 8px;
  font-size: 1rem;
}

.student-tool-card p {
  margin: 0;
  font-size: 13px;
  color: var(--text-muted);
  line-height: 1.5;
}

/* ===== AI Assistant Showcase ===== */
.ai-assistant-showcase {
  margin: 32px 0;
}

.ai-models-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 20px;
  margin-bottom: 32px;
}

.ai-model-card {
  background: var(--bg-white);
  border: 1px solid var(--border);
  border-radius: var(--radius-xl);
  padding: 28px;
  text-align: center;
  transition: all var(--transition-base);
  position: relative;
}

.ai-model-card:hover {
  border-color: var(--primary-border);
  transform: translateY(-4px);
  box-shadow: var(--shadow-lg);
}

.ai-model-logo {
  margin-bottom: 18px;
}

.model-avatar {
  width: 56px;
  height: 56px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  border-radius: var(--radius-lg);
  font-size: 24px;
  font-weight: 800;
  color: var(--text-white);
}

.model-avatar.gemini {
  background: linear-gradient(135deg, #4285f4 0%, #34a853 50%, #fbbc05 100%);
}

.model-avatar.openai {
  background: #10a37f;
}

.model-avatar.claude {
  background: linear-gradient(135deg, #d97706 0%, #f59e0b 100%);
}

.ai-model-card h4 {
  margin: 0 0 6px;
  font-size: 1.1rem;
}

.model-provider {
  font-size: 12px;
  color: var(--text-muted);
  font-weight: 600;
  text-transform: uppercase;
  letter-spacing: 0.05em;
  margin-bottom: 12px;
}

.model-description {
  font-size: 14px;
  color: var(--text-secondary);
  margin: 0;
}

.model-tag {
  position: absolute;
  top: 16px;
  right: 16px;
  font-size: 11px;
  font-weight: 700;
  color: var(--success);
  background: var(--success-bg);
  padding: 4px 10px;
  border-radius: var(--radius-full);
}

.ai-features-list {
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  gap: 16px;
}

.ai-feature {
  display: flex;
  align-items: flex-start;
  gap: 14px;
  padding: 20px;
  background: var(--bg-white);
  border: 1px solid var(--border);
  border-radius: var(--radius-lg);
}

.ai-feature-icon {
  font-size: 24px;
  flex-shrink: 0;
}

.ai-feature strong {
  display: block;
  margin-bottom: 4px;
  font-size: 15px;
}

.ai-feature p {
  margin: 0;
  font-size: 13px;
  color: var(--text-muted);
}

/* ===== Tech Stack Grid ===== */
.tech-stack-grid {
  display: grid;
  grid-template-columns: repeat(5, 1fr);
  gap: 16px;
  margin: 32px 0;
}

.tech-item {
  background: var(--bg-white);
  border: 1px solid var(--border);
  border-radius: var(--radius-lg);
  padding: 20px;
  display: flex;
  flex-direction: column;
  align-items: center;
  text-align: center;
  gap: 12px;
  transition: all var(--transition-base);
}

.tech-item:hover {
  border-color: var(--primary-border);
  transform: translateY(-2px);
  box-shadow: var(--shadow-md);
}

.tech-icon {
  width: 40px;
  height: 40px;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 32px;
}

.tech-icon img {
  width: 100%;
  height: 100%;
  object-fit: contain;
}

.tech-info h4 {
  margin: 0;
  font-size: 14px;
}

.tech-info p {
  margin: 4px 0 0;
  font-size: 12px;
  color: var(--text-muted);
}

/* ===== Quick Start Steps ===== */
.quickstart-steps {
  position: relative;
  margin: 32px 0;
}

.quickstart-step {
  display: flex;
  gap: 20px;
  position: relative;
  padding-bottom: 28px;
}

.quickstart-step:last-child {
  padding-bottom: 0;
}

.step-connector {
  position: absolute;
  left: 18px;
  top: 44px;
  bottom: 0;
  width: 2px;
  background: var(--border);
}

.quickstart-step:last-child .step-connector {
  display: none;
}

.step-number {
  width: 40px;
  height: 40px;
  background: var(--primary-gradient);
  color: var(--text-white);
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  font-weight: 700;
  font-size: 15px;
  flex-shrink: 0;
  position: relative;
  z-index: 1;
  box-shadow: var(--shadow-primary);
}

.step-content {
  flex: 1;
  padding-top: 6px;
}

.step-content h4 {
  margin: 0 0 8px;
  font-size: 1.1rem;
}

.step-content p {
  margin: 0;
}

.code-inline {
  background: var(--bg-light);
  border: 1px solid var(--border);
  border-radius: var(--radius-sm);
  padding: 8px 14px;
  margin-top: 12px;
  display: inline-block;
}

.code-inline code {
  font-family: var(--font-mono);
  font-size: 13px;
  color: var(--primary-dark);
}

.step-link {
  display: inline-flex;
  align-items: center;
  gap: 4px;
  font-size: 14px;
  font-weight: 600;
  color: var(--primary);
  margin-top: 8px;
}

/* ===== API Keys Grid ===== */
.api-keys-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 16px;
  margin: 28px 0;
}

.api-key-card {
  background: var(--bg-white);
  border: 1px solid var(--border);
  border-radius: var(--radius-lg);
  padding: 24px;
  text-align: center;
  transition: all var(--transition-base);
}

.api-key-card:hover {
  border-color: var(--primary-border);
  box-shadow: var(--shadow-md);
}

.api-key-icon {
  font-size: 28px;
  margin-bottom: 12px;
}

.api-key-card h4 {
  margin: 0 0 4px;
  font-size: 1rem;
}

.api-key-card p {
  margin: 0 0 12px;
  font-size: 13px;
  color: var(--text-muted);
}

.api-key-card code {
  font-family: var(--font-mono);
  font-size: 11px;
  background: var(--bg-light);
  padding: 4px 10px;
  border-radius: var(--radius-sm);
  color: var(--text-secondary);
  border: 1px solid var(--border);
}

/* ===== Admin Features Grid ===== */
.admin-features-grid {
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  gap: 20px;
  margin: 32px 0;
}

.admin-feature-card {
  background: var(--bg-white);
  border: 1px solid var(--border);
  border-radius: var(--radius-xl);
  padding: 28px;
  transition: all var(--transition-base);
}

.admin-feature-card:hover {
  border-color: var(--primary-border);
  transform: translateY(-3px);
  box-shadow: var(--shadow-lg);
}

.admin-feature-icon {
  font-size: 32px;
  margin-bottom: 16px;
}

.admin-feature-card h3 {
  margin: 0 0 10px;
  font-size: 1.15rem;
}

.admin-feature-card > p {
  margin: 0 0 16px;
  font-size: 14px;
}

.admin-feature-list {
  list-style: none;
  padding: 0;
  margin: 0;
}

.admin-feature-list li {
  display: flex;
  align-items: center;
  gap: 10px;
  padding: 6px 0;
  font-size: 13px;
  color: var(--text-secondary);
}

.admin-feature-list li::before {
  content: '•';
  color: var(--primary);
  font-weight: 700;
}

/* ===== Docs Grid ===== */
.docs-grid {
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  gap: 20px;
  margin: 32px 0;
}

.doc-card {
  background: var(--bg-white);
  border: 1px solid var(--border);
  border-radius: var(--radius-xl);
  padding: 28px;
  text-decoration: none;
  display: flex;
  flex-direction: column;
  gap: 10px;
  transition: all var(--transition-base);
  position: relative;
}

.doc-card:hover {
  border-color: var(--primary-border);
  transform: translateY(-3px);
  box-shadow: var(--shadow-lg);
  text-decoration: none;
}

.doc-card-icon {
  font-size: 32px;
  margin-bottom: 4px;
}

.doc-card h3 {
  margin: 0;
  font-size: 1.1rem;
  color: var(--text-primary);
}

.doc-card p {
  margin: 0;
  font-size: 14px;
  color: var(--text-secondary);
}

.doc-card-arrow {
  position: absolute;
  top: 28px;
  right: 28px;
  font-size: 18px;
  color: var(--primary);
  opacity: 0;
  transform: translateX(-8px);
  transition: all var(--transition-base);
}

.doc-card:hover .doc-card-arrow {
  opacity: 1;
  transform: translateX(0);
}

/* ===== Credits Grid ===== */
.credits-grid {
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  gap: 16px;
  margin: 28px 0;
}

.credit-item {
  display: flex;
  align-items: center;
  gap: 14px;
  padding: 20px;
  background: var(--bg-white);
  border: 1px solid var(--border);
  border-radius: var(--radius-lg);
}

.credit-icon {
  font-size: 24px;
  flex-shrink: 0;
}

.credit-item strong {
  display: block;
  margin-bottom: 2px;
  font-size: 15px;
}

.credit-item p {
  margin: 0;
  font-size: 13px;
  color: var(--text-muted);
}

/* ===== Footer ===== */
.docs-footer {
  margin-top: 80px;
  padding-top: 40px;
  border-top: 1px solid var(--border);
  text-align: center;
}

.footer-content {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 12px;
}

.footer-brand {
  display: flex;
  align-items: center;
  gap: 10px;
  font-weight: 600;
  color: var(--text-primary);
}

.footer-logo {
  width: 28px;
  height: 28px;
}

.docs-footer p {
  font-size: 13px;
  color: var(--text-muted);
  margin: 0;
}

/* ===== Code Blocks ===== */
code {
  font-family: var(--font-mono);
  font-size: 0.875em;
  background: var(--bg-light);
  padding: 2px 8px;
  border-radius: 4px;
  color: var(--primary-dark);
  border: 1px solid var(--border);
}

pre {
  background: var(--bg-dark);
  color: #e2e8f0;
  border-radius: var(--radius-lg);
  padding: 24px;
  overflow-x: auto;
  margin: 24px 0;
  font-size: 14px;
  line-height: 1.7;
  border: 1px solid var(--border);
}

pre code {
  background: none;
  padding: 0;
  color: inherit;
  font-size: inherit;
  border: none;
}

/* ===== Tables ===== */
table {
  width: 100%;
  border-collapse: collapse;
  margin: 24px 0;
  font-size: 14px;
  border: 1px solid var(--border);
  border-radius: var(--radius-lg);
  overflow: hidden;
}

th, td {
  padding: 14px 18px;
  text-align: left;
  border-bottom: 1px solid var(--border);
}

th {
  background: var(--bg-light);
  font-weight: 600;
  color: var(--text-primary);
  font-size: 13px;
  text-transform: uppercase;
  letter-spacing: 0.05em;
}

tr:hover td {
  background: var(--bg-cream);
}

tr:last-child td {
  border-bottom: none;
}

/* ===== Lists ===== */
ul:not(.nav-link):not(.feature-list):not(.admin-feature-list), 
ol {
  margin: 16px 0;
  padding-left: 24px;
}

li {
  margin-bottom: 8px;
  color: var(--text-secondary);
}

li::marker {
  color: var(--primary);
}

/* ===== Steps ===== */
.steps {
  margin: 32px 0;
}

.step {
  display: flex;
  gap: 20px;
  padding: 24px 0;
  border-bottom: 1px solid var(--border-light);
}

.step:last-child {
  border-bottom: none;
}



.step-content h4 {
  margin: 0 0 8px;
  font-size: 1.1rem;
}

.step-content p {
  margin: 0;
}

/* ===== Feature Grid (legacy) ===== */
.feature-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 16px;
  margin: 32px 0;
}

.feature-item {
  background: var(--bg-white);
  border: 1px solid var(--border);
  border-radius: var(--radius-lg);
  padding: 20px;
  text-align: center;
  transition: all var(--transition-base);
}

.feature-item:hover {
  border-color: var(--primary-border);
  transform: translateY(-2px);
  box-shadow: var(--shadow-md);
}

.feature-item .icon {
  font-size: 32px;
  margin-bottom: 12px;
}

.feature-item h4 {
  margin: 0 0 8px;
  font-size: 15px;
}

.feature-item p {
  margin: 0;
  font-size: 13px;
  color: var(--text-muted);
}

/* ===== Card Grid (legacy) ===== */
.card-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(280px, 1fr));
  gap: 20px;
  margin: 24px 0;
}

/* ===== Checklist ===== */
.checklist {
  list-style: none;
  padding-left: 0;
}

.checklist li {
  display: flex;
  align-items: flex-start;
  gap: 12px;
  padding: 12px 0;
  border-bottom: 1px solid var(--border-light);
}

.checklist li::before {
  content: '✓';
  width: 22px;
  height: 22px;
  background: var(--success-bg);
  color: var(--success);
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 12px;
  font-weight: 700;
  flex-shrink: 0;
}

/* ===== Page Header ===== */
.page-header {
  margin-bottom: 40px;
}

.page-header h1 {
  display: flex;
  align-items: center;
  gap: 16px;
}

.page-header .header-icon {
  width: 52px;
  height: 52px;
  display: flex;
  align-items: center;
  justify-content: center;
  background: var(--primary-gradient);
  border-radius: var(--radius-lg);
  color: var(--text-white);
  font-size: 26px;
  box-shadow: var(--shadow-primary);
}

.page-description {
  font-size: 1.15rem;
  color: var(--text-secondary);
  max-width: 680px;
}

/* ===== Mobile Navigation ===== */
.mobile-nav-toggle {
  display: none;
  position: fixed;
  top: 16px;
  left: 16px;
  z-index: 200;
  width: 48px;
  height: 48px;
  background: var(--bg-white);
  border: 1px solid var(--border);
  border-radius: var(--radius-md);
  cursor: pointer;
  align-items: center;
  justify-content: center;
  box-shadow: var(--shadow-md);
}

.mobile-nav-toggle span {
  display: block;
  width: 22px;
  height: 2px;
  background: var(--text-primary);
  margin: 5px auto;
  transition: all var(--transition-fast);
  border-radius: 1px;
}

/* ===== Responsive ===== */
@media (max-width: 1280px) {
  .tech-stack-grid {
    grid-template-columns: repeat(5, 1fr);
  }
}

@media (max-width: 1024px) {
  .feature-grid,
  .student-tools-showcase,
  .feature-showcase {
    grid-template-columns: repeat(2, 1fr);
  }

  .feature-card-large {
    grid-column: span 2;
    grid-template-columns: 1fr;
  }

  .stats-grid,
  .ai-models-grid {
    grid-template-columns: repeat(2, 1fr);
  }

  .tech-stack-grid {
    grid-template-columns: repeat(3, 1fr);
  }
  
  .tools-grid {
    grid-template-columns: 1fr;
  }
}

@media (max-width: 768px) {
  .mobile-nav-toggle {
    display: flex;
  }

  .sidebar {
    transform: translateX(-100%);
  }

  .sidebar.open {
    transform: translateX(0);
    box-shadow: var(--shadow-xl);
  }

  .main-content {
    margin-left: 0;
  }

  .content-wrapper {
    padding: 24px 20px 80px;
  }

  h1 {
    font-size: 2rem;
  }

  h2, .section-title {
    font-size: 1.5rem;
    margin-top: 48px;
  }

  .hero {
    padding: 36px 28px;
  }

  .hero h1 {
    font-size: 2.25rem;
  }

  .hero-subtitle {
    font-size: 1.1rem;
  }

  .hero-actions {
    flex-direction: column;
  }

  .btn {
    width: 100%;
    justify-content: center;
  }

  .feature-showcase,
  .feature-grid,
  .student-tools-showcase,
  .ai-models-grid,
  .admin-features-grid,
  .docs-grid,
  .api-keys-grid,
  .ai-features-list {
    grid-template-columns: 1fr;
  }

  .feature-card-large {
    grid-column: span 1;
  }

  .stats-grid,
  .tools-grid,
  .credits-grid {
    grid-template-columns: 1fr;
  }

  .tech-stack-grid {
    grid-template-columns: repeat(2, 1fr);
  }

  .version-banner {
    flex-direction: column;
    gap: 20px;
    text-align: center;
  }

  .version-banner-content {
    flex-direction: column;
  }

  .callout-features {
    flex-direction: column;
    gap: 8px;
  }

  table {
    display: block;
    overflow-x: auto;
    white-space: nowrap;
  }
}

/* ===== Print Styles ===== */
@media print {
  .sidebar,
  .mobile-nav-toggle {
    display: none;
  }

  .main-content {
    margin-left: 0;
  }

  .content-wrapper {
    max-width: 100%;
    padding: 0;
  }

  .hero,
  .callout,
  .feature-card,
  .stat-card {
    box-shadow: none;
    border: 1px solid #ddd;
  }
}

/* ===== Scrollbar ===== */
::-webkit-scrollbar {
  width: 8px;
  height: 8px;
}

::-webkit-scrollbar-track {
  background: var(--bg-light);
}

::-webkit-scrollbar-thumb {
  background: var(--border);
  border-radius: 4px;
}

::-webkit-scrollbar-thumb:hover {
  background: var(--text-muted);
}

/* ===== Selection ===== */
::selection {
  background: var(--primary-bg);
  color: var(--primary);
}

/* ===== Focus States ===== */
:focus-visible {
  outline: 2px solid var(--primary);
  outline-offset: 2px;
}

/* ===== Animations ===== */
@keyframes fadeIn {
  from { 
    opacity: 0; 
    transform: translateY(12px); 
  }
  to { 
    opacity: 1; 
    transform: translateY(0); 
  }
}

@keyframes slideIn {
  from {
    opacity: 0;
    transform: translateX(-20px);
  }
  to {
    opacity: 1;
    transform: translateX(0);
  }
}

.animate-fade-in {
  animation: fadeIn 0.5s ease forwards;
}

.animate-slide-in {
  animation: slideIn 0.4s ease forwards;
}

/* Staggered animation delays */
.animate-delay-100 { animation-delay: 100ms; }
.animate-delay-200 { animation-delay: 200ms; }
.animate-delay-300 { animation-delay: 300ms; }
.animate-delay-400 { animation-delay: 400ms; }
.animate-delay-500 { animation-delay: 500ms; }

/* ===== Utility Classes ===== */
.text-center { text-align: center; }
.text-left { text-align: left; }
.text-right { text-align: right; }

.mt-0 { margin-top: 0; }
.mt-4 { margin-top: 16px; }
.mt-8 { margin-top: 32px; }
.mb-0 { margin-bottom: 0; }
.mb-4 { margin-bottom: 16px; }
.mb-8 { margin-bottom: 32px; }

.flex { display: flex; }
.flex-col { flex-direction: column; }
.items-center { align-items: center; }
.justify-between { justify-content: space-between; }
.gap-2 { gap: 8px; }
.gap-4 { gap: 16px; }

.hidden { display: none; }
.block { display: block; }
