/* ==========================================================================
   chosendistro.pro - Master Stylesheet
   Geek-chic retro terminal vibes x Cyberpunk / Modern responsive engineering
   Zero external frameworks - 100% Vanilla CSS
   ========================================================================== */

:root {
  /* Core Color Palette */
  --bg-dark: #0b0f14;
  --bg-card: #121820;
  --bg-card-hover: #182230;
  --bg-surface: #1e293b;
  --bg-terminal: #070a0e;
  
  --text-main: #e2e8f0;
  --text-muted: #94a3b8;
  --text-bright: #ffffff;
  
  /* Retro Phosphor Accents */
  --color-green: #00ff66;
  --color-green-glow: rgba(0, 255, 102, 0.25);
  --color-cyan: #00e5ff;
  --color-cyan-glow: rgba(0, 229, 255, 0.25);
  --color-amber: #ffb000;
  --color-amber-glow: rgba(255, 176, 0, 0.25);
  
  /* Active Dynamic Distro Accent (Default Phosphor Green) */
  --theme-accent: var(--color-green);
  --theme-glow: var(--color-green-glow);
  
  /* Distro-Specific Palette */
  --distro-ubuntu: #e95420;
  --distro-arch: #1793d1;
  --distro-fedora: #294172;
  --distro-mint: #87cf3e;
  --distro-debian: #a80030;
  --distro-popos: #48b9c7;
  --distro-manjaro: #35bf5c;
  --distro-opensuse: #73ba25;
  --distro-zorin: #17a8f5;
  --distro-bazzite: #e040fb;
  --distro-kali: #557c93;
  --distro-tails: #563d7c;
  --distro-nixos: #5277c3;
  --distro-alpine: #0d597f;
  
  /* Borders and UI */
  --border-subtle: #243042;
  --border-glow: rgba(0, 255, 102, 0.4);
  --radius-sm: 4px;
  --radius-md: 8px;
  --radius-lg: 12px;
  
  /* Typography */
  --font-mono: "Fira Code", "JetBrains Mono", Consolas, "Courier New", monospace;
  --font-sans: -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, Oxygen, Ubuntu, Cantarell, sans-serif;
  
  /* Transitions */
  --transition-fast: 0.15s ease;
  --transition-normal: 0.25s cubic-bezier(0.4, 0, 0.2, 1);
}

/* Theme Override Data Attributes */
body[data-theme="ubuntu"] { --theme-accent: var(--distro-ubuntu); --theme-glow: rgba(233, 84, 32, 0.3); }
body[data-theme="arch"] { --theme-accent: var(--distro-arch); --theme-glow: rgba(23, 147, 209, 0.3); }
body[data-theme="fedora"] { --theme-accent: var(--distro-fedora); --theme-glow: rgba(41, 65, 114, 0.3); }
body[data-theme="mint"] { --theme-accent: var(--distro-mint); --theme-glow: rgba(135, 207, 62, 0.3); }
body[data-theme="debian"] { --theme-accent: var(--distro-debian); --theme-glow: rgba(168, 0, 48, 0.3); }
body[data-theme="cyan"] { --theme-accent: var(--color-cyan); --theme-glow: var(--color-cyan-glow); }
body[data-theme="amber"] { --theme-accent: var(--color-amber); --theme-glow: var(--color-amber-glow); }

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

html {
  font-size: 16px;
  scroll-behavior: smooth;
  background-color: var(--bg-dark);
  color: var(--text-main);
  font-family: var(--font-sans);
}

body {
  min-height: 100vh;
  display: flex;
  flex-direction: column;
  overflow-x: hidden;
  line-height: 1.6;
  background-color: var(--bg-dark);
}

/* Subtle CRT Scanline Overlay */
body::after {
  content: " ";
  position: fixed;
  top: 0; left: 0; bottom: 0; right: 0;
  background: linear-gradient(rgba(18, 16, 16, 0) 50%, rgba(0, 0, 0, 0.18) 50%), linear-gradient(90deg, rgba(255, 0, 0, 0.02), rgba(0, 255, 0, 0.01), rgba(0, 0, 255, 0.02));
  z-index: 9999;
  background-size: 100% 3px, 6px 100%;
  pointer-events: none;
  opacity: 0.45;
}

body.scanlines-disabled::after {
  display: none;
}

/* Typography Defaults */
h1, h2, h3, h4, h5, h6 {
  font-family: var(--font-sans);
  color: var(--text-bright);
  font-weight: 700;
  line-height: 1.25;
}

code, pre, .mono {
  font-family: var(--font-mono);
}

a {
  color: var(--theme-accent);
  text-decoration: none;
  transition: color var(--transition-fast);
}

a:hover {
  text-decoration: underline;
  text-shadow: 0 0 8px var(--theme-glow);
}

/* Container */
.container {
  width: 100%;
  max-width: 1240px;
  margin: 0 auto;
  padding: 0 1.25rem;
}

/* ==========================================================================
   NAVIGATION BAR
   ========================================================================== */
.site-nav {
  background-color: rgba(11, 15, 20, 0.94);
  backdrop-filter: blur(12px);
  border-bottom: 1px solid var(--border-subtle);
  position: sticky;
  top: 0;
  z-index: 1000;
}

.nav-inner {
  display: flex;
  align-items: center;
  justify-content: space-between;
  height: 68px;
}

.brand-logo {
  display: flex;
  align-items: center;
  gap: 0.75rem;
  font-family: var(--font-mono);
  font-size: 1.25rem;
  font-weight: 800;
  color: var(--text-bright);
}

.brand-icon {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 36px;
  height: 36px;
  background: var(--bg-card);
  border: 1px solid var(--theme-accent);
  border-radius: var(--radius-sm);
  color: var(--theme-accent);
  box-shadow: 0 0 10px var(--theme-glow);
  font-size: 1.05rem;
}

.brand-logo .dot-pro {
  color: var(--theme-accent);
  text-shadow: 0 0 8px var(--theme-glow);
}

.nav-links {
  display: flex;
  align-items: center;
  gap: 1.5rem;
  list-style: none;
}

.nav-link {
  font-family: var(--font-mono);
  font-size: 0.9rem;
  color: var(--text-muted);
  text-transform: uppercase;
  letter-spacing: 0.05em;
  padding: 0.35rem 0.6rem;
  border-radius: var(--radius-sm);
  transition: all var(--transition-fast);
}

.nav-link:hover, .nav-link.active {
  color: var(--theme-accent);
  text-decoration: none;
  background-color: rgba(255, 255, 255, 0.04);
}

.nav-tools {
  display: flex;
  align-items: center;
  gap: 0.75rem;
}

/* Theme Switcher Dots */
.theme-selector {
  display: flex;
  align-items: center;
  gap: 0.4rem;
  background: var(--bg-card);
  padding: 0.3rem 0.5rem;
  border-radius: 20px;
  border: 1px solid var(--border-subtle);
}

.theme-dot {
  width: 14px;
  height: 14px;
  border-radius: 50%;
  cursor: pointer;
  border: 2px solid transparent;
  transition: transform var(--transition-fast), border-color var(--transition-fast);
}

.theme-dot:hover {
  transform: scale(1.2);
}

.theme-dot.active {
  border-color: #fff;
}

.dot-green { background-color: #00ff66; }
.dot-arch { background-color: #1793d1; }
.dot-ubuntu { background-color: #e95420; }
.dot-fedora { background-color: #294172; }
.dot-debian { background-color: #a80030; }

.scanline-btn {
  background: var(--bg-card);
  border: 1px solid var(--border-subtle);
  color: var(--text-muted);
  font-family: var(--font-mono);
  font-size: 0.75rem;
  padding: 0.35rem 0.6rem;
  border-radius: var(--radius-sm);
  cursor: pointer;
  transition: all var(--transition-fast);
}

.scanline-btn:hover {
  border-color: var(--theme-accent);
  color: var(--theme-accent);
}

/* ==========================================================================
   BUTTONS & TERMINAL CONTROLS
   ========================================================================== */
.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 0.5rem;
  font-family: var(--font-mono);
  font-size: 0.95rem;
  padding: 0.75rem 1.4rem;
  border-radius: var(--radius-sm);
  font-weight: 600;
  cursor: pointer;
  border: 1px solid transparent;
  transition: all var(--transition-fast);
  text-decoration: none !important;
}

.btn-primary {
  background-color: var(--theme-accent);
  color: #05080c;
  box-shadow: 0 0 14px var(--theme-glow);
}

.btn-primary:hover {
  background-color: #fff;
  color: #000;
  box-shadow: 0 0 20px rgba(255, 255, 255, 0.4);
}

.btn-outline {
  background-color: transparent;
  border-color: var(--border-subtle);
  color: var(--text-bright);
}

.btn-outline:hover {
  border-color: var(--theme-accent);
  color: var(--theme-accent);
  box-shadow: 0 0 10px var(--theme-glow);
}

.btn-terminal {
  background-color: var(--bg-card);
  border: 1px solid var(--theme-accent);
  color: var(--theme-accent);
}

.btn-terminal:hover {
  background-color: var(--theme-accent);
  color: #000;
}

/* Terminal Window Frame Component */
.terminal-window {
  background-color: var(--bg-terminal);
  border: 1px solid var(--border-subtle);
  border-radius: var(--radius-md);
  box-shadow: 0 12px 35px rgba(0, 0, 0, 0.5);
  overflow: hidden;
  margin: 1.5rem 0;
}

.terminal-titlebar {
  background-color: var(--bg-surface);
  padding: 0.5rem 0.9rem;
  display: flex;
  align-items: center;
  justify-content: space-between;
  border-bottom: 1px solid var(--border-subtle);
  font-family: var(--font-mono);
  font-size: 0.8rem;
  color: var(--text-muted);
}

.terminal-dots {
  display: flex;
  gap: 6px;
}

.term-dot {
  width: 11px;
  height: 11px;
  border-radius: 50%;
  display: inline-block;
}

.dot-red { background-color: #ff5f56; }
.dot-yellow { background-color: #ffbd2e; }
.dot-btn-green { background-color: #27c93f; }

.terminal-title {
  color: var(--text-bright);
  letter-spacing: 0.05em;
}

.terminal-body {
  padding: 1.5rem;
  font-family: var(--font-mono);
  font-size: 0.9rem;
  color: var(--text-main);
}

/* ==========================================================================
   HERO BANNER & CAROUSEL VIEWPORT
   ========================================================================== */
.hero-section {
  padding: 3.5rem 0 3rem;
  border-bottom: 1px solid var(--border-subtle);
  background: radial-gradient(circle at 50% 20%, rgba(0, 255, 102, 0.05) 0%, transparent 65%);
  position: relative;
}

.hero-grid {
  display: grid;
  grid-template-columns: 1.05fr 0.95fr;
  gap: 2.5rem;
  align-items: center;
}

.terminal-pill {
  display: inline-flex;
  align-items: center;
  gap: 0.5rem;
  background-color: var(--bg-card);
  border: 1px solid var(--theme-accent);
  padding: 0.35rem 0.8rem;
  border-radius: 20px;
  font-family: var(--font-mono);
  font-size: 0.8rem;
  color: var(--theme-accent);
  margin-bottom: 1.25rem;
  box-shadow: 0 0 10px var(--theme-glow);
}

.pulse-led {
  width: 8px;
  height: 8px;
  background-color: var(--theme-accent);
  border-radius: 50%;
  box-shadow: 0 0 8px var(--theme-accent);
  animation: ledPulse 1.8s infinite;
}

@keyframes ledPulse {
  0%, 100% { opacity: 1; transform: scale(1); }
  50% { opacity: 0.4; transform: scale(0.85); }
}

.hero-title {
  font-size: 3.25rem;
  font-weight: 800;
  letter-spacing: -0.02em;
  margin-bottom: 1.25rem;
  line-height: 1.1;
}

.hero-highlight {
  color: var(--theme-accent);
  text-shadow: 0 0 18px var(--theme-glow);
}

.hero-description {
  font-size: 1.12rem;
  color: var(--text-muted);
  margin-bottom: 2rem;
  max-width: 580px;
}

.hero-cta-group {
  display: flex;
  gap: 1rem;
  flex-wrap: wrap;
}

/* ==========================================================================
   INTERACTIVE HERO CAROUSEL COMPONENT
   ========================================================================== */
.hero-carousel {
  position: relative;
  background: var(--bg-terminal);
  border: 1px solid var(--theme-accent);
  border-radius: var(--radius-md);
  box-shadow: 0 12px 35px rgba(0, 0, 0, 0.7), 0 0 20px var(--theme-glow);
  overflow: hidden;
  user-select: none;
}

.carousel-titlebar {
  background-color: var(--bg-surface);
  padding: 0.5rem 0.9rem;
  display: flex;
  align-items: center;
  justify-content: space-between;
  border-bottom: 1px solid var(--border-subtle);
  font-family: var(--font-mono);
  font-size: 0.78rem;
}

.carousel-viewport {
  position: relative;
  overflow: hidden;
  width: 100%;
  height: 320px;
  background: #000;
}

.carousel-track {
  display: flex;
  height: 100%;
  transition: transform 0.45s cubic-bezier(0.2, 0.8, 0.2, 1);
  will-change: transform;
}

.carousel-slide {
  flex: 0 0 100%;
  position: relative;
  height: 100%;
  background: #05080c;
  overflow: hidden;
}

.carousel-slide-img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  opacity: 0.88;
  transition: opacity 0.3s ease, transform 0.5s ease;
  display: block;
}

.hero-carousel:hover .carousel-slide-img {
  transform: scale(1.02);
  opacity: 0.95;
}

/* Metadata Holographic Overlay */
.carousel-overlay {
  position: absolute;
  bottom: 0;
  left: 0;
  right: 0;
  background: linear-gradient(180deg, transparent 0%, rgba(7, 10, 14, 0.85) 40%, rgba(7, 10, 14, 0.98) 100%);
  padding: 1.5rem 1.25rem 1rem;
  display: flex;
  justify-content: space-between;
  align-items: flex-end;
  pointer-events: auto;
}

.slide-meta-info {
  max-width: 70%;
}

.slide-category-pill {
  display: inline-block;
  font-family: var(--font-mono);
  font-size: 0.7rem;
  font-weight: 700;
  text-transform: uppercase;
  padding: 0.2rem 0.5rem;
  border-radius: var(--radius-sm);
  background: rgba(0, 0, 0, 0.75);
  border: 1px solid var(--slide-accent, var(--theme-accent));
  color: var(--slide-accent, var(--theme-accent));
  margin-bottom: 0.35rem;
}

.slide-distro-title {
  font-size: 1.35rem;
  font-weight: 800;
  color: #fff;
  margin-bottom: 0.2rem;
  text-shadow: 0 2px 8px rgba(0, 0, 0, 0.8);
}

.slide-desktop-env {
  font-family: var(--font-mono);
  font-size: 0.8rem;
  color: var(--text-muted);
}

.slide-action-link {
  font-family: var(--font-mono);
  font-size: 0.8rem;
  font-weight: 700;
  padding: 0.45rem 0.85rem;
  border-radius: var(--radius-sm);
  background: var(--slide-accent, var(--theme-accent));
  color: #000 !important;
  text-decoration: none !important;
  box-shadow: 0 0 10px rgba(0, 0, 0, 0.5);
  white-space: nowrap;
  transition: transform var(--transition-fast), filter var(--transition-fast);
}

.slide-action-link:hover {
  transform: translateY(-2px);
  filter: brightness(1.15);
}

/* Micro-switch Arcade Controls */
.carousel-footer-bar {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 0.65rem 1rem;
  background: var(--bg-surface);
  border-top: 1px solid var(--border-subtle);
  font-family: var(--font-mono);
  font-size: 0.78rem;
}

.carousel-control-btn {
  background: var(--bg-card);
  border: 1px solid var(--border-subtle);
  color: var(--text-main);
  font-family: var(--font-mono);
  font-size: 0.75rem;
  font-weight: bold;
  padding: 0.35rem 0.75rem;
  border-radius: var(--radius-sm);
  cursor: pointer;
  transition: all var(--transition-fast);
}

.carousel-control-btn:hover {
  border-color: var(--theme-accent);
  color: var(--theme-accent);
  box-shadow: 0 0 8px var(--theme-glow);
  transform: translateY(-1px);
}

.carousel-indicators {
  display: flex;
  gap: 8px;
}

.carousel-pip {
  width: 22px;
  height: 6px;
  background: var(--bg-card);
  border: 1px solid var(--border-subtle);
  border-radius: 3px;
  cursor: pointer;
  transition: all var(--transition-fast);
}

.carousel-pip.active {
  background: var(--theme-accent);
  border-color: var(--theme-accent);
  box-shadow: 0 0 8px var(--theme-glow);
}

/* ==========================================================================
   RECOMMENDATION QUIZ LAYOUT
   ========================================================================== */
.quiz-section {
  padding: 4rem 0;
  background-color: var(--bg-dark);
}

.quiz-wrapper {
  max-width: 900px;
  margin: 0 auto;
}

.quiz-frame {
  background-color: var(--bg-card);
  border: 1px solid var(--border-subtle);
  border-radius: var(--radius-lg);
  box-shadow: 0 10px 30px rgba(0, 0, 0, 0.4);
  padding: 2.5rem;
  position: relative;
}

.quiz-progress-bar-container {
  width: 100%;
  height: 6px;
  background-color: var(--bg-terminal);
  border-radius: 3px;
  overflow: hidden;
  margin-bottom: 1.5rem;
  border: 1px solid var(--border-subtle);
}

.quiz-progress-fill {
  height: 100%;
  width: 5%;
  background: linear-gradient(90deg, var(--theme-accent), var(--color-cyan));
  box-shadow: 0 0 12px var(--theme-glow);
  transition: width 0.3s ease;
}

.quiz-meta-row {
  display: flex;
  align-items: center;
  justify-content: space-between;
  margin-bottom: 1.5rem;
  font-family: var(--font-mono);
  font-size: 0.85rem;
  color: var(--text-muted);
}

.quiz-step-tag {
  color: var(--theme-accent);
  font-weight: 700;
  letter-spacing: 0.05em;
}

.quiz-header {
  margin-bottom: 2rem;
}

.quiz-question-title {
  font-size: 1.85rem;
  margin-top: 0.5rem;
  margin-bottom: 0.5rem;
}

.quiz-question-sub {
  font-size: 1rem;
  color: var(--text-muted);
}

.quiz-options-grid {
  display: grid;
  grid-template-columns: 1fr;
  gap: 1rem;
  margin-bottom: 2rem;
}

.quiz-option-card {
  display: flex;
  align-items: center;
  gap: 1.25rem;
  background: var(--bg-terminal);
  border: 1px solid var(--border-subtle);
  border-radius: var(--radius-md);
  padding: 1.15rem 1.4rem;
  text-align: left;
  cursor: pointer;
  transition: all var(--transition-fast);
  color: var(--text-main);
  width: 100%;
}

.quiz-option-card:hover {
  background-color: var(--bg-card-hover);
  border-color: var(--theme-accent);
  transform: translateY(-2px);
  box-shadow: 0 6px 16px rgba(0, 0, 0, 0.4);
}

.quiz-option-card.selected {
  border-color: var(--theme-accent);
  background-color: rgba(0, 255, 102, 0.06);
  box-shadow: 0 0 12px var(--theme-glow);
}

.option-marker {
  font-family: var(--font-mono);
  font-weight: bold;
  font-size: 1.1rem;
  color: var(--theme-accent);
  min-width: 32px;
}

.option-body {
  flex: 1;
}

.option-title {
  font-size: 1.05rem;
  font-weight: 600;
  color: var(--text-bright);
  margin-bottom: 0.2rem;
}

.option-desc {
  font-size: 0.85rem;
  color: var(--text-muted);
  line-height: 1.4;
}

.option-check {
  font-family: var(--font-mono);
  font-weight: bold;
  color: var(--theme-accent);
  font-size: 1.25rem;
  min-width: 24px;
}

.quiz-nav-row {
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding-top: 1.5rem;
  border-top: 1px solid var(--border-subtle);
}

/* ==========================================================================
   QUIZ RESULTS DISPLAY
   ========================================================================== */
.results-section {
  display: none;
  padding: 4rem 0;
  background-color: var(--bg-dark);
}

.results-header-banner {
  text-align: center;
  margin-bottom: 3rem;
}

.terminal-tag {
  font-family: var(--font-mono);
  font-size: 0.85rem;
  font-weight: bold;
  letter-spacing: 0.1em;
  margin-bottom: 0.75rem;
}

.glow-green {
  color: var(--color-green);
  text-shadow: 0 0 10px var(--color-green-glow);
}

.results-title {
  font-size: 2.5rem;
  margin-bottom: 0.75rem;
}

.results-sub {
  font-size: 1.1rem;
  color: var(--text-muted);
  max-width: 650px;
  margin: 0 auto;
}

.results-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(320px, 1fr));
  gap: 2rem;
  margin-bottom: 3rem;
}

.result-card {
  background-color: var(--bg-card);
  border: 1px solid var(--distro-accent, var(--border-subtle));
  border-radius: var(--radius-lg);
  padding: 2rem;
  display: flex;
  flex-direction: column;
  position: relative;
  transition: transform var(--transition-fast), box-shadow var(--transition-fast);
}

.result-card:hover {
  transform: translateY(-4px);
  box-shadow: 0 12px 30px rgba(0, 0, 0, 0.5);
}

.result-card.top-match {
  border-width: 2px;
  box-shadow: 0 0 25px rgba(0, 255, 102, 0.15);
  background: linear-gradient(180deg, rgba(255, 255, 255, 0.02) 0%, var(--bg-card) 100%);
}

.result-badge-row {
  display: flex;
  align-items: center;
  justify-content: space-between;
  margin-bottom: 1.25rem;
}

.result-rank-badge {
  font-family: var(--font-mono);
  font-size: 0.75rem;
  font-weight: 700;
  color: #fff;
  background: var(--bg-surface);
  padding: 0.3rem 0.6rem;
  border-radius: var(--radius-sm);
  border: 1px solid var(--border-subtle);
}

.result-percentage-pill {
  font-family: var(--font-mono);
  font-size: 0.85rem;
  font-weight: 800;
  padding: 0.3rem 0.65rem;
  border: 1px solid;
  border-radius: 20px;
}

.result-distro-name {
  font-size: 1.9rem;
  margin-bottom: 0.4rem;
}

.result-tagline {
  font-size: 0.95rem;
  color: var(--text-muted);
  margin-bottom: 1.25rem;
  min-height: 44px;
}

.result-reason-box {
  background: var(--bg-terminal);
  border-left: 3px solid var(--distro-accent, var(--theme-accent));
  padding: 1rem;
  border-radius: 0 var(--radius-sm) var(--radius-sm) 0;
  margin-bottom: 1.5rem;
  font-size: 0.9rem;
}

.result-reason-box strong {
  display: block;
  font-size: 0.8rem;
  color: var(--text-bright);
  text-transform: uppercase;
  font-family: var(--font-mono);
  margin-bottom: 0.3rem;
}

.result-spec-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 0.75rem;
  margin-bottom: 1.5rem;
  font-size: 0.8rem;
}

.spec-cell {
  background: var(--bg-surface);
  padding: 0.5rem 0.75rem;
  border-radius: var(--radius-sm);
}

.spec-label {
  display: block;
  color: var(--text-muted);
  font-size: 0.75rem;
  text-transform: uppercase;
  font-family: var(--font-mono);
}

.spec-val {
  color: var(--text-bright);
  font-weight: 600;
}

.result-tags {
  display: flex;
  flex-wrap: wrap;
  gap: 0.4rem;
  margin-bottom: 1.75rem;
}

.tag-pill {
  font-family: var(--font-mono);
  font-size: 0.75rem;
  padding: 0.2rem 0.5rem;
  background: var(--bg-terminal);
  border: 1px solid var(--border-subtle);
  border-radius: var(--radius-sm);
  color: var(--text-muted);
}

.result-actions {
  margin-top: auto;
  display: flex;
  flex-direction: column;
  gap: 0.75rem;
}

.retake-quiz-bar {
  display: flex;
  justify-content: center;
  gap: 1.5rem;
  flex-wrap: wrap;
  padding: 2rem 0;
}

/* ==========================================================================
   FEATURED DISTROS & CATALOG
   ========================================================================== */
.section-header {
  margin-bottom: 2.5rem;
}

.section-tag {
  font-family: var(--font-mono);
  color: var(--theme-accent);
  font-size: 0.85rem;
  font-weight: 700;
  letter-spacing: 0.08em;
  margin-bottom: 0.4rem;
  display: block;
}

.section-title {
  font-size: 2.25rem;
}

.catalog-filters {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  justify-content: space-between;
  gap: 1rem;
  margin-bottom: 2rem;
  background: var(--bg-card);
  padding: 1.25rem;
  border-radius: var(--radius-md);
  border: 1px solid var(--border-subtle);
}

.tag-filter-buttons {
  display: flex;
  flex-wrap: wrap;
  gap: 0.5rem;
}

.filter-btn {
  background: var(--bg-terminal);
  border: 1px solid var(--border-subtle);
  color: var(--text-muted);
  font-family: var(--font-mono);
  font-size: 0.8rem;
  padding: 0.4rem 0.8rem;
  border-radius: var(--radius-sm);
  cursor: pointer;
  transition: all var(--transition-fast);
}

.filter-btn:hover, .filter-btn.active {
  background: var(--theme-accent);
  color: #000;
  border-color: var(--theme-accent);
  font-weight: 700;
}

.search-input-wrapper {
  position: relative;
  min-width: 260px;
}

.search-input {
  width: 100%;
  background: var(--bg-terminal);
  border: 1px solid var(--border-subtle);
  border-radius: var(--radius-sm);
  padding: 0.5rem 1rem 0.5rem 2.25rem;
  color: var(--text-bright);
  font-family: var(--font-mono);
  font-size: 0.85rem;
  outline: none;
  transition: border-color var(--transition-fast);
}

.search-input:focus {
  border-color: var(--theme-accent);
  box-shadow: 0 0 10px var(--theme-glow);
}

.search-icon-symbol {
  position: absolute;
  left: 0.75rem;
  top: 50%;
  transform: translateY(-50%);
  color: var(--text-muted);
  font-size: 0.9rem;
}

.distros-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(340px, 1fr));
  gap: 1.5rem;
  margin-bottom: 3.5rem;
}

.distro-card {
  background: var(--bg-card);
  border: 1px solid var(--border-subtle);
  border-radius: var(--radius-md);
  padding: 1.5rem;
  display: flex;
  flex-direction: column;
  transition: all var(--transition-fast);
  position: relative;
}

.distro-card:hover {
  border-color: var(--card-accent, var(--theme-accent));
  transform: translateY(-3px);
  box-shadow: 0 8px 24px rgba(0, 0, 0, 0.4);
}

.card-top-row {
  display: flex;
  align-items: center;
  justify-content: space-between;
  margin-bottom: 0.75rem;
}

.category-tag {
  font-family: var(--font-mono);
  font-size: 0.75rem;
  color: var(--card-accent, var(--theme-accent));
  border: 1px solid var(--card-accent, var(--theme-accent));
  padding: 0.2rem 0.5rem;
  border-radius: var(--radius-sm);
}

.card-distro-name {
  font-size: 1.4rem;
  margin-bottom: 0.35rem;
}

.card-tagline {
  font-size: 0.85rem;
  color: var(--text-muted);
  margin-bottom: 1.25rem;
  flex: 1;
}

.spec-mini-list {
  font-family: var(--font-mono);
  font-size: 0.78rem;
  color: var(--text-muted);
  margin-bottom: 1.25rem;
  line-height: 1.6;
}

.spec-mini-list strong {
  color: var(--text-bright);
}

.card-footer {
  display: flex;
  gap: 0.75rem;
  margin-top: auto;
}

/* ==========================================================================
   DEEP-DIVE ARTICLE TEMPLATE (`distro.html`)
   ========================================================================== */
.article-header {
  padding: 3.5rem 0 2.5rem;
  border-bottom: 1px solid var(--border-subtle);
  background: linear-gradient(180deg, rgba(255, 255, 255, 0.01) 0%, transparent 100%);
}

.distro-hero-meta {
  display: flex;
  align-items: center;
  gap: 1rem;
  margin-bottom: 1rem;
}

.article-title {
  font-size: 3rem;
  margin-bottom: 0.75rem;
}

.article-lead {
  font-size: 1.2rem;
  color: var(--text-muted);
  max-width: 800px;
  margin-bottom: 2rem;
}

.article-layout {
  display: grid;
  grid-template-columns: 1fr 340px;
  gap: 2.5rem;
  padding: 3rem 0;
}

.article-content section {
  margin-bottom: 3.5rem;
}

.article-content h2 {
  font-size: 1.75rem;
  margin-bottom: 1.25rem;
  padding-bottom: 0.5rem;
  border-bottom: 1px solid var(--border-subtle);
  display: flex;
  align-items: center;
  gap: 0.75rem;
}

.article-content p {
  margin-bottom: 1.25rem;
  color: #cbd5e1;
  font-size: 1.05rem;
  line-height: 1.7;
}

/* ==========================================================================
   DESKTOP SCREENSHOT SHOWCASE FRAME
   ========================================================================== */
.distro-screenshot-frame {
  background: var(--bg-terminal);
  border: 1px solid var(--distro-accent, var(--theme-accent));
  border-radius: var(--radius-md);
  box-shadow: 0 10px 30px rgba(0, 0, 0, 0.6), 0 0 16px rgba(0, 255, 102, 0.15);
  overflow: hidden;
  margin: 2rem 0;
  position: relative;
  transition: transform var(--transition-fast), box-shadow var(--transition-fast);
}

.distro-screenshot-frame:hover {
  box-shadow: 0 15px 40px rgba(0, 0, 0, 0.75), 0 0 25px rgba(0, 255, 102, 0.25);
}

.screenshot-container {
  position: relative;
  width: 100%;
  max-height: 520px;
  background: #000;
  overflow: hidden;
  display: flex;
  align-items: center;
  justify-content: center;
}

.distro-screenshot-img {
  width: 100%;
  height: auto;
  max-height: 520px;
  object-fit: cover;
  display: block;
  cursor: zoom-in;
  transition: opacity 0.3s ease;
}

.screenshot-zoom-overlay {
  position: absolute;
  top: 1rem;
  right: 1rem;
  z-index: 10;
}

.screenshot-zoom-btn {
  background: rgba(11, 15, 20, 0.85);
  backdrop-filter: blur(8px);
  border: 1px solid var(--distro-accent, var(--theme-accent));
  color: var(--text-bright);
  font-family: var(--font-mono);
  font-size: 0.78rem;
  padding: 0.4rem 0.8rem;
  border-radius: var(--radius-sm);
  cursor: pointer;
  display: inline-flex;
  align-items: center;
  gap: 0.4rem;
  transition: all var(--transition-fast);
}

.screenshot-zoom-btn:hover {
  background: var(--distro-accent, var(--theme-accent));
  color: #000;
  box-shadow: 0 0 10px var(--theme-glow);
}

.distro-screenshot-caption {
  padding: 0.9rem 1.25rem;
  background: var(--bg-surface);
  border-top: 1px solid var(--border-subtle);
  font-family: var(--font-mono);
  font-size: 0.85rem;
  color: var(--text-muted);
  line-height: 1.5;
}

/* Lightbox Modal for Screenshots */
.screenshot-modal {
  position: fixed;
  top: 0; left: 0; right: 0; bottom: 0;
  background: rgba(0, 0, 0, 0.92);
  backdrop-filter: blur(12px);
  z-index: 20000;
  display: none;
  align-items: center;
  justify-content: center;
  padding: 2rem;
  cursor: zoom-out;
}

.screenshot-modal.open {
  display: flex;
}

.screenshot-modal-content {
  max-width: 95vw;
  max-height: 90vh;
  object-fit: contain;
  border: 2px solid var(--theme-accent);
  border-radius: var(--radius-md);
  box-shadow: 0 0 35px var(--theme-glow);
}

/* Specs Matrix Table */
.specs-table {
  width: 100%;
  border-collapse: collapse;
  margin: 1.5rem 0;
  font-size: 0.95rem;
}

.specs-table th, .specs-table td {
  padding: 0.85rem 1rem;
  border: 1px solid var(--border-subtle);
  text-align: left;
}

.specs-table th {
  background-color: var(--bg-surface);
  color: var(--text-bright);
  font-family: var(--font-mono);
  font-size: 0.85rem;
}

.specs-table tr:nth-child(even) {
  background-color: var(--bg-card);
}

/* Step-by-Step Tutorial Cards */
.tutorial-step-card {
  background: var(--bg-card);
  border: 1px solid var(--border-subtle);
  border-radius: var(--radius-md);
  margin-bottom: 1.5rem;
  overflow: hidden;
}

.step-card-header {
  background: var(--bg-surface);
  padding: 0.85rem 1.25rem;
  display: flex;
  align-items: center;
  gap: 0.75rem;
  border-bottom: 1px solid var(--border-subtle);
}

.step-number {
  background: var(--theme-accent);
  color: #000;
  font-family: var(--font-mono);
  font-size: 0.85rem;
  font-weight: 800;
  padding: 0.2rem 0.6rem;
  border-radius: var(--radius-sm);
}

.step-card-title {
  font-size: 1.1rem;
  font-weight: 600;
}

.step-card-body {
  padding: 1.25rem;
}

.code-block {
  background: var(--bg-terminal);
  border: 1px solid var(--border-subtle);
  border-radius: var(--radius-sm);
  padding: 1rem;
  font-family: var(--font-mono);
  font-size: 0.85rem;
  color: #a5f3fc;
  overflow-x: auto;
  margin: 0.75rem 0;
  position: relative;
}

/* Sidebar Info Box */
.article-sidebar {
  display: flex;
  flex-direction: column;
  gap: 2rem;
}

.sticky-sidebar-block {
  position: sticky;
  top: 90px;
}

.distro-quick-facts {
  background: var(--bg-card);
  border: 1px solid var(--border-subtle);
  border-radius: var(--radius-md);
  padding: 1.5rem;
}

.fact-row {
  display: flex;
  justify-content: space-between;
  padding: 0.65rem 0;
  border-bottom: 1px solid rgba(255, 255, 255, 0.05);
  font-size: 0.85rem;
}

.fact-row:last-child {
  border-bottom: none;
}

.fact-title {
  color: var(--text-muted);
  font-family: var(--font-mono);
}

.fact-data {
  color: var(--text-bright);
  font-weight: 600;
}

/* ==========================================================================
   FOOTER
   ========================================================================== */
.site-footer {
  margin-top: auto;
  background-color: var(--bg-terminal);
  border-top: 1px solid var(--border-subtle);
  padding: 3rem 0 1.5rem;
}

.footer-grid {
  display: grid;
  grid-template-columns: 1.5fr 1fr 1fr 1fr;
  gap: 2.5rem;
  margin-bottom: 2.5rem;
}

.footer-brand-desc {
  font-size: 0.85rem;
  color: var(--text-muted);
  margin-top: 0.75rem;
  line-height: 1.5;
}

.footer-col-title {
  font-family: var(--font-mono);
  font-size: 0.85rem;
  color: var(--text-bright);
  text-transform: uppercase;
  letter-spacing: 0.05em;
  margin-bottom: 1rem;
}

.footer-link-list {
  list-style: none;
  font-size: 0.85rem;
}

.footer-link-list li {
  margin-bottom: 0.5rem;
}

.footer-link-list a {
  color: var(--text-muted);
}

.footer-link-list a:hover {
  color: var(--theme-accent);
}

.footer-bottom-row {
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding-top: 1.5rem;
  border-top: 1px solid var(--border-subtle);
  font-family: var(--font-mono);
  font-size: 0.75rem;
  color: #64748b;
  flex-wrap: wrap;
  gap: 1rem;
}

/* ==========================================================================
   RESPONSIVE MEDIA QUERIES
   ========================================================================== */
@media (max-width: 992px) {
  .hero-grid {
    grid-template-columns: 1fr;
    gap: 2rem;
  }
  
  .hero-title {
    font-size: 2.5rem;
  }

  .carousel-viewport {
    height: 280px;
  }
  
  .article-layout {
    grid-template-columns: 1fr;
  }
  
  .footer-grid {
    grid-template-columns: 1fr 1fr;
  }
}

@media (max-width: 640px) {
  .hero-title {
    font-size: 2rem;
  }
  
  .quiz-frame {
    padding: 1.25rem;
  }

  .quiz-question-title {
    font-size: 1.4rem;
  }

  .carousel-viewport {
    height: 220px;
  }

  .carousel-overlay {
    padding: 1rem 0.75rem 0.75rem;
  }

  .slide-distro-title {
    font-size: 1.1rem;
  }

  .slide-meta-info {
    max-width: 65%;
  }

  .nav-links {
    display: none;
  }

  .footer-grid {
    grid-template-columns: 1fr;
  }
}
