/* ==========================================================================
   Darrin Alves - HomeLab Manager Showcase Stylesheet
   Design System: Deep Midnight Dark + Cyan/Indigo Gradients + Glassmorphism
   ========================================================================== */

/* --- CSS Variables & Theme Tokens --- */
:root {
  --bg-dark: #0B0F19;
  --bg-dark-alt: #111726;
  --bg-card: rgba(17, 24, 39, 0.7);
  --bg-card-hover: rgba(31, 41, 55, 0.85);

  --primary-cyan: #06b6d4;
  --primary-indigo: #6366f1;
  --accent-emerald: #10b981;
  --accent-purple: #a855f7;
  --accent-yellow: #f59e0b;
  --accent-orange: #f97316;

  --text-main: #f3f4f6;
  --text-muted: #9ca3af;
  --text-dim: #6b7280;

  --border-glass: rgba(255, 255, 255, 0.1);
  --border-glow: rgba(6, 182, 212, 0.3);

  --font-heading: 'Outfit', -apple-system, BlinkMacSystemFont, sans-serif;
  --font-body: 'Plus Jakarta Sans', -apple-system, BlinkMacSystemFont, sans-serif;
  --font-mono: 'JetBrains Mono', monospace;

  --shadow-subtle: 0 10px 30px -10px rgba(0, 0, 0, 0.5);
  --shadow-glow: 0 0 25px rgba(6, 182, 212, 0.25);
  --radius-lg: 16px;
  --radius-md: 12px;
  --radius-sm: 8px;
  --transition-fast: all 0.2s cubic-bezier(0.4, 0, 0.2, 1);
  --transition-smooth: all 0.35s cubic-bezier(0.4, 0, 0.2, 1);
}

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

html {
  scroll-behavior: smooth;
  font-size: 16px;
}

body.dark-theme {
  background-color: var(--bg-dark);
  color: var(--text-main);
  font-family: var(--font-body);
  line-height: 1.6;
  overflow-x: hidden;
  position: relative;
}

/* Custom Scrollbar */
::-webkit-scrollbar {
  width: 10px;
}
::-webkit-scrollbar-track {
  background: var(--bg-dark);
}
::-webkit-scrollbar-thumb {
  background: #1f2937;
  border-radius: 5px;
}
::-webkit-scrollbar-thumb:hover {
  background: var(--primary-cyan);
}

/* --- Layout Containers --- */
.container {
  max-width: 1240px;
  margin: 0 auto;
  padding: 0 24px;
}

.section-padding {
  padding: 100px 0;
}

.alt-bg {
  background-color: var(--bg-dark-alt);
  position: relative;
}

/* --- Ambient Background Glows --- */
.ambient-glow {
  position: absolute;
  border-radius: 50%;
  filter: blur(120px);
  pointer-events: none;
  z-index: 0;
  opacity: 0.4;
}

.glow-1 {
  top: -100px;
  right: -100px;
  width: 500px;
  height: 500px;
  background: radial-gradient(circle, var(--primary-cyan) 0%, transparent 70%);
}

.glow-2 {
  top: 40%;
  left: -150px;
  width: 600px;
  height: 600px;
  background: radial-gradient(circle, var(--primary-indigo) 0%, transparent 70%);
}

.glow-3 {
  bottom: 10%;
  right: -100px;
  width: 550px;
  height: 550px;
  background: radial-gradient(circle, var(--accent-purple) 0%, transparent 70%);
}

/* --- Typography Utilities (Modern Web Guidance) --- */
h1, h2, h3, h4, h5, h6, .section-title, .hero-title {
  font-family: var(--font-heading);
  font-weight: 700;
  color: var(--text-main);
  line-height: 1.2;
  text-wrap: balance;
}

p, .section-description, .hero-description, .feature-card p {
  text-wrap: pretty;
}

.gradient-text {
  background: linear-gradient(135deg, var(--primary-cyan), var(--primary-indigo), #c084fc);
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
}

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

.highlight-text {
  color: var(--primary-cyan);
}

.code-font {
  font-family: var(--font-mono);
  font-size: 0.9em;
  background: rgba(255, 255, 255, 0.08);
  padding: 2px 6px;
  border-radius: 4px;
  color: var(--primary-cyan);
}

/* --- Section Headers --- */
.section-header {
  margin-bottom: 56px;
}
.section-header.center {
  text-align: center;
  max-width: 760px;
  margin-left: auto;
  margin-right: auto;
}

.section-tag {
  display: inline-block;
  font-size: 0.85rem;
  font-weight: 600;
  text-transform: uppercase;
  letter-spacing: 1.5px;
  color: var(--primary-cyan);
  background: rgba(6, 182, 212, 0.1);
  border: 1px solid rgba(6, 182, 212, 0.25);
  padding: 6px 14px;
  border-radius: 20px;
  margin-bottom: 16px;
}

.section-title {
  font-size: 2.5rem;
  margin-bottom: 16px;
}

.section-description {
  font-size: 1.125rem;
  color: var(--text-muted);
  line-height: 1.7;
}

/* --- Glassmorphic Card Base --- */
.glass-card {
  background: var(--bg-card);
  backdrop-filter: blur(16px);
  -webkit-backdrop-filter: blur(16px);
  border: 1px solid var(--border-glass);
  border-radius: var(--radius-lg);
  box-shadow: var(--shadow-subtle);
  transition: var(--transition-smooth);
}

.glass-card:hover {
  border-color: rgba(6, 182, 212, 0.4);
  box-shadow: 0 15px 35px -10px rgba(0, 0, 0, 0.6), 0 0 20px rgba(6, 182, 212, 0.15);
}

/* --- Buttons --- */
.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 10px;
  padding: 12px 24px;
  font-family: var(--font-heading);
  font-weight: 600;
  font-size: 1rem;
  border-radius: var(--radius-md);
  text-decoration: none;
  cursor: pointer;
  border: none;
  transition: var(--transition-fast);
}

.btn-primary {
  background: linear-gradient(135deg, var(--primary-cyan), var(--primary-indigo));
  color: #ffffff;
  box-shadow: 0 4px 15px rgba(6, 182, 212, 0.35);
}
.btn-primary:hover {
  transform: translateY(-2px);
  box-shadow: 0 6px 20px rgba(6, 182, 212, 0.5);
}

.btn-secondary {
  background: rgba(255, 255, 255, 0.08);
  color: var(--text-main);
  border: 1px solid var(--border-glass);
}
.btn-secondary:hover {
  background: rgba(255, 255, 255, 0.15);
  color: #ffffff;
  transform: translateY(-2px);
}

.btn-glass {
  background: rgba(17, 24, 39, 0.6);
  backdrop-filter: blur(10px);
  color: var(--text-main);
  border: 1px solid var(--border-glass);
}
.btn-glass:hover {
  border-color: var(--primary-cyan);
  color: var(--primary-cyan);
  transform: translateY(-2px);
}

.btn-lg {
  padding: 14px 28px;
  font-size: 1.05rem;
}
.btn-sm {
  padding: 8px 16px;
  font-size: 0.875rem;
}

/* --- Navigation Bar --- */
.navbar-wrapper {
  position: fixed;
  top: 0;
  left: 0;
  width: 100%;
  z-index: 100;
  padding: 16px 0;
  transition: var(--transition-fast);
}

.scroll-progress-bar {
  position: absolute;
  top: 0;
  left: 0;
  height: 3px;
  background: linear-gradient(90deg, var(--primary-cyan), var(--primary-indigo), #c084fc);
  width: 0%;
  transition: width 0.1s linear;
  box-shadow: 0 0 10px rgba(6, 182, 212, 0.8);
  z-index: 101;
}

.navbar-wrapper.scrolled {
  background: rgba(11, 15, 25, 0.85);
  backdrop-filter: blur(16px);
  -webkit-backdrop-filter: blur(16px);
  border-bottom: 1px solid var(--border-glass);
  padding: 10px 0;
}

.navbar {
  max-width: 1240px;
  margin: 0 auto;
  padding: 0 24px;
  display: flex;
  align-items: center;
  justify-content: space-between;
}

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

.brand-logo {
  width: 40px;
  height: 40px;
  background: linear-gradient(135deg, var(--primary-cyan), var(--primary-indigo));
  border-radius: var(--radius-md);
  display: flex;
  align-items: center;
  justify-content: center;
  color: #fff;
  box-shadow: 0 0 15px rgba(6, 182, 212, 0.4);
}

.brand-text {
  display: flex;
  flex-direction: column;
}

.author-name {
  font-family: var(--font-heading);
  font-weight: 700;
  font-size: 1.1rem;
  color: var(--text-main);
}

.app-subtitle {
  font-size: 0.75rem;
  color: var(--primary-cyan);
  font-weight: 500;
}

.nav-links {
  position: relative;
  display: flex;
  align-items: center;
  gap: 4px;
  background: rgba(255, 255, 255, 0.03);
  padding: 4px;
  border-radius: var(--radius-full);
  border: 1px solid var(--border-glass);
}

.nav-indicator-pill {
  position: absolute;
  top: 4px;
  bottom: 4px;
  left: 0;
  width: 0;
  background: rgba(6, 182, 212, 0.15);
  border: 1px solid rgba(6, 182, 212, 0.4);
  border-radius: var(--radius-full);
  transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
  pointer-events: none;
  box-shadow: 0 0 12px rgba(6, 182, 212, 0.2);
}

.nav-link {
  position: relative;
  z-index: 1;
  color: var(--text-muted);
  text-decoration: none;
  font-weight: 500;
  font-size: 0.9rem;
  padding: 6px 16px;
  border-radius: var(--radius-full);
  transition: var(--transition-fast);
}

.nav-link:hover {
  color: var(--text-main);
}

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

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

/* Command Palette Trigger Button */
.cmd-k-trigger {
  display: flex;
  align-items: center;
  gap: 8px;
  padding: 8px 14px;
  background: rgba(255, 255, 255, 0.05);
  border: 1px solid var(--border-glass);
  border-radius: var(--radius-md);
  color: var(--text-muted);
  font-family: var(--font-body);
  font-size: 0.85rem;
  cursor: pointer;
  transition: var(--transition-fast);
}

.cmd-k-trigger:hover {
  background: rgba(255, 255, 255, 0.1);
  border-color: rgba(6, 182, 212, 0.4);
  color: var(--text-main);
  box-shadow: 0 0 10px rgba(6, 182, 212, 0.2);
}

.cmd-k-badge {
  background: rgba(0, 0, 0, 0.4);
  border: 1px solid rgba(255, 255, 255, 0.15);
  border-radius: 4px;
  padding: 2px 6px;
  font-family: var(--font-mono);
  font-size: 0.7rem;
  color: var(--primary-cyan);
}

.mobile-toggle {
  display: none;
  background: none;
  border: none;
  flex-direction: column;
  gap: 5px;
  cursor: pointer;
}
.mobile-toggle span {
  width: 24px;
  height: 2px;
  background: var(--text-main);
  border-radius: 2px;
}

/* --- Hero Section --- */
.hero-section {
  padding-top: 160px;
  padding-bottom: 100px;
  position: relative;
  z-index: 1;
}

.hero-container {
  display: grid;
  grid-template-columns: 1.1fr 0.9fr;
  gap: 48px;
  align-items: center;
}

.hero-badge {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  padding: 6px 14px;
  background: rgba(16, 185, 129, 0.1);
  border: 1px solid rgba(16, 185, 129, 0.3);
  border-radius: 20px;
  margin-bottom: 24px;
}

.pulse-dot {
  width: 8px;
  height: 8px;
  background-color: var(--accent-emerald);
  border-radius: 50%;
  box-shadow: 0 0 10px var(--accent-emerald);
  animation: pulse 2s infinite;
}

@keyframes pulse {
  0% { transform: scale(0.95); box-shadow: 0 0 0 0 rgba(16, 185, 129, 0.7); }
  70% { transform: scale(1); box-shadow: 0 0 0 8px rgba(16, 185, 129, 0); }
  100% { transform: scale(0.95); box-shadow: 0 0 0 0 rgba(16, 185, 129, 0); }
}

.badge-text {
  font-size: 0.85rem;
  font-weight: 600;
  color: var(--accent-emerald);

}

.hero-title {
  font-size: 3.2rem;
  line-height: 1.15;
  margin-bottom: 20px;
  letter-spacing: -0.5px;
}

.hero-description {
  font-size: 1.15rem;
  color: var(--text-muted);
  margin-bottom: 32px;
  line-height: 1.7;
}

.hero-actions {
  display: flex;
  flex-wrap: wrap;
  gap: 16px;
  margin-bottom: 48px;
}

.hero-stats {
  display: flex;
  align-items: center;
  gap: 24px;
  padding-top: 24px;
  border-top: 1px solid var(--border-glass);
}

.stat-item {
  display: flex;
  flex-direction: column;
}

.stat-value {
  font-family: var(--font-heading);
  font-weight: 800;
  font-size: 1.4rem;
  color: var(--text-main);
}

.stat-label {
  font-size: 0.8rem;
  color: var(--text-dim);

}

.stat-divider {
  width: 1px;
  height: 32px;
  background: var(--border-glass);
}

/* --- Hero Terminal Window --- */
.hero-graphic {
  position: relative;
}

.terminal-window {
  overflow: hidden;
}

.terminal-header {
  background: rgba(15, 23, 42, 0.9);
  padding: 12px 16px;
  display: flex;
  align-items: center;
  border-bottom: 1px solid var(--border-glass);
}

.terminal-dots {
  display: flex;
  gap: 8px;
}
.dot {
  width: 12px;
  height: 12px;
  border-radius: 50%;
}
.dot.red { background: #ef4444; }
.dot.yellow { background: #f59e0b; }
.dot.green { background: #10b981; }

.terminal-title {
  font-size: 0.85rem;
  color: var(--text-muted);
  margin: 0 auto;
  font-family: var(--font-mono);
}

.terminal-body {
  padding: 20px;
  background: #090d16;
  font-size: 0.875rem;
  line-height: 1.8;
  color: #e5e7eb;
}

.cmd-line {
  color: var(--primary-cyan);
}
.prompt {
  color: var(--accent-emerald);
  margin-right: 8px;
}
.cmd-output.dim {
  color: var(--text-dim);
}
.cmd-output.success {
  color: var(--accent-emerald);
}
.cmd-output.info {
  color: #60a5fa;
}

/* --- Section 2: Overview Grid --- */
.overview-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(260px, 1fr));
  gap: 24px;
}

.overview-card {
  padding: 32px;
}

.icon-box {
  width: 56px;
  height: 56px;
  border-radius: var(--radius-md);
  display: flex;
  align-items: center;
  justify-content: center;
  margin-bottom: 20px;
}
.icon-box.cyan { background: rgba(6, 182, 212, 0.15); color: var(--primary-cyan); }
.icon-box.indigo { background: rgba(99, 102, 241, 0.15); color: var(--primary-indigo); }
.icon-box.emerald { background: rgba(16, 185, 129, 0.15); color: var(--accent-emerald); }
.icon-box.purple { background: rgba(168, 85, 247, 0.15); color: var(--accent-purple); }

.overview-card h3 {
  font-size: 1.25rem;
  margin-bottom: 12px;
}
.overview-card p {
  color: var(--text-muted);
  font-size: 0.95rem;
  line-height: 1.6;
}

/* --- Section 3: Interactive Showcase Tabs & Gallery --- */
.showcase-tabs-container {
  padding: 24px;
}

.showcase-tabs {
  display: flex;
  gap: 10px;
  overflow-x: auto;
  padding-bottom: 16px;
  border-bottom: 1px solid var(--border-glass);
  margin-bottom: 24px;
}

.tab-btn {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  padding: 10px 18px;
  background: rgba(255, 255, 255, 0.04);
  border: 1px solid var(--border-glass);
  border-radius: var(--radius-md);
  color: var(--text-muted);
  font-family: var(--font-heading);
  font-size: 0.9rem;
  font-weight: 500;
  cursor: pointer;
  white-space: nowrap;
  transition: var(--transition-fast);
}

.tab-btn:hover {
  background: rgba(255, 255, 255, 0.08);
  color: var(--text-main);
}

.tab-btn.active {
  background: linear-gradient(135deg, rgba(6, 182, 212, 0.2), rgba(99, 102, 241, 0.2));
  border-color: var(--primary-cyan);
  color: #ffffff;
  box-shadow: 0 0 15px rgba(6, 182, 212, 0.2);
}

.tab-panel {
  display: none;
  grid-template-columns: 1.2fr 0.8fr;
  gap: 32px;
  align-items: center;
}

.tab-panel.active {
  display: grid;
  animation: fadeIn 0.4s ease-in-out;
}

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

.panel-preview .image-wrapper {
  position: relative;
  border-radius: var(--radius-md);
  overflow: hidden;
  border: 1px solid var(--border-glass);
  cursor: pointer;
}

.screenshot-img {
  width: 100%;
  height: auto;
  display: block;
  transition: transform 0.4s ease;
}

.image-wrapper:hover .screenshot-img {
  transform: scale(1.03);
}

.image-overlay {
  position: absolute;
  inset: 0;
  background: rgba(11, 15, 25, 0.4);
  display: flex;
  align-items: center;
  justify-content: center;
  opacity: 0;
  transition: opacity 0.3s ease;
}
.image-wrapper:hover .image-overlay {
  opacity: 1;
}

.zoom-badge {
  background: rgba(6, 182, 212, 0.9);
  color: #fff;
  padding: 8px 16px;
  border-radius: 20px;
  font-size: 0.85rem;
  font-weight: 600;
}

.panel-details h3 {
  font-size: 1.6rem;
  margin-bottom: 12px;
}
.panel-details p {
  color: var(--text-muted);
  font-size: 1.05rem;
  margin-bottom: 24px;
}

.feature-bullets {
  list-style: none;
  display: flex;
  flex-direction: column;
  gap: 12px;
}
.feature-bullets li {
  display: flex;
  align-items: center;
  gap: 10px;
  color: var(--text-main);
  font-size: 0.95rem;
}
.check-icon {
  color: var(--accent-emerald);
  font-weight: bold;
}

/* --- Section 4: Features Grid --- */
.features-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(320px, 1fr));
  gap: 24px;
}

.feature-card {
  padding: 32px;
  position: relative;
}

.feature-icon {
  font-size: 2rem;
  margin-bottom: 16px;
}
.feature-card h3 {
  font-size: 1.3rem;
  margin-bottom: 10px;
}
.feature-card p {
  color: var(--text-muted);
  font-size: 0.95rem;
  line-height: 1.6;
}



/* --- Section 6: Architecture Box --- */
.arch-box {
  padding: 40px;
  display: grid;
  grid-template-columns: 1fr auto 1fr;
  gap: 40px;
}

.arch-divider {
  width: 1px;
  background: var(--border-glass);
}

.arch-col h3 {
  font-size: 1.3rem;
  margin-bottom: 20px;
  color: var(--primary-cyan);
}

.arch-list {
  list-style: none;
  display: flex;
  flex-direction: column;
  gap: 12px;
}
.arch-list li {
  font-size: 0.95rem;
  color: var(--text-muted);
}
.arch-list strong {
  color: var(--text-main);
}

/* --- Section 7: Quick Deploy --- */
.deploy-card {
  max-width: 800px;
  margin: 0 auto;
  overflow: hidden;
}

.deploy-tabs {
  display: flex;
  background: rgba(15, 23, 42, 0.8);
  border-bottom: 1px solid var(--border-glass);
}

.deploy-tab-btn {
  flex: 1;
  padding: 14px;
  background: none;
  border: none;
  color: var(--text-muted);
  font-family: var(--font-heading);
  font-size: 0.95rem;
  font-weight: 600;
  cursor: pointer;
  transition: var(--transition-fast);
}
.deploy-tab-btn.active {
  color: var(--primary-cyan);
  background: rgba(6, 182, 212, 0.1);
  border-bottom: 2px solid var(--primary-cyan);
}

.deploy-code-wrapper {
  background: #060913;
  padding: 24px;
  position: relative;
}

.deploy-panel {
  display: none;
}
.deploy-panel.active {
  display: block;
}

.float-copy {
  position: absolute;
  top: 16px;
  right: 16px;
}

.deploy-code-wrapper pre {
  color: var(--accent-emerald);
  font-size: 0.9rem;
  line-height: 1.6;
  overflow-x: auto;
}

/* --- Modal Viewer --- */
.modal {
  position: fixed;
  inset: 0;
  z-index: 200;
  display: flex;
  align-items: center;
  justify-content: center;
  opacity: 0;
  pointer-events: none;
  transition: opacity 0.3s ease;
}
.modal.open {
  opacity: 1;
  pointer-events: auto;
}

.modal-overlay {
  position: absolute;
  inset: 0;
  background: rgba(0, 0, 0, 0.85);
  backdrop-filter: blur(10px);
}

.modal-content {
  position: relative;
  max-width: 90vw;
  max-height: 90vh;
  padding: 20px;
  z-index: 10;
  display: flex;
  flex-direction: column;
  align-items: center;
}

.modal-content img {
  max-width: 100%;
  max-height: 80vh;
  border-radius: var(--radius-sm);
}

.modal-caption {
  margin-top: 12px;
  color: var(--text-muted);
  font-size: 0.95rem;
}

.modal-close {
  position: absolute;
  top: -15px;
  right: -15px;
  width: 36px;
  height: 36px;
  background: var(--primary-cyan);
  color: #000;
  border: none;
  border-radius: 50%;
  font-size: 1.5rem;
  cursor: pointer;
  display: flex;
  align-items: center;
  justify-content: center;
  box-shadow: 0 0 15px rgba(6, 182, 212, 0.5);
}

/* --- Footer --- */
.footer {
  background: #060913;
  border-top: 1px solid var(--border-glass);
  padding: 60px 0 30px;
}

.footer-container {
  display: flex;
  justify-content: space-between;
  gap: 40px;
  margin-bottom: 40px;
}

.footer-brand .author-name {
  font-size: 1.3rem;
}
.footer-tagline {
  color: var(--text-muted);
  font-size: 0.9rem;
  margin-top: 8px;
  max-width: 320px;
}

.footer-links {
  display: flex;
  gap: 48px;
}

.footer-col h4 {
  font-size: 0.95rem;
  color: var(--text-main);
  margin-bottom: 14px;
}

.footer-col a {
  display: block;
  color: var(--text-muted);
  text-decoration: none;
  font-size: 0.9rem;
  margin-bottom: 8px;
  transition: var(--transition-fast);
}
.footer-col a:hover {
  color: var(--primary-cyan);
}

.footer-bottom {
  border-top: 1px solid rgba(255, 255, 255, 0.05);
  padding-top: 24px;
  text-align: center;
  color: var(--text-dim);
  font-size: 0.85rem;
}

/* --- Responsive Media Queries --- */
@media (max-width: 992px) {
  .hero-container {
    grid-template-columns: 1fr;
    gap: 32px;
  }
  .hero-title {
    font-size: 2.5rem;
  }
  .tab-panel {
    grid-template-columns: 1fr;
  }
  .arch-box {
    grid-template-columns: 1fr;
  }
  .arch-divider {
    display: none;
  }
}

@media (max-width: 768px) {
  .nav-links {
    display: none;
  }
  .cmd-k-text, .cmd-k-badge {
    display: none;
  }
  .cmd-k-trigger {
    padding: 8px;
  }
  .mobile-toggle {
    display: flex;
  }
  .hero-stats {
    flex-wrap: wrap;
  }
  .stat-divider {
    display: none;
  }
  .footer-container {
    flex-direction: column;
  }
}

/* --- Mobile Sliding Drawer --- */
.mobile-drawer-overlay {
  position: fixed;
  inset: 0;
  background: rgba(0, 0, 0, 0.6);
  backdrop-filter: blur(8px);
  -webkit-backdrop-filter: blur(8px);
  z-index: 1000;
  opacity: 0;
  pointer-events: none;
  transition: opacity 0.3s ease;
}

.mobile-drawer-overlay.active {
  opacity: 1;
  pointer-events: auto;
}

.mobile-drawer {
  position: fixed;
  top: 0;
  right: -320px;
  width: 300px;
  height: 100vh;
  background: #0b0f19;
  border-left: 1px solid var(--border-glass);
  z-index: 1001;
  display: flex;
  flex-direction: column;
  padding: 24px;
  transition: right 0.3s cubic-bezier(0.4, 0, 0.2, 1);
  box-shadow: -10px 0 30px rgba(0, 0, 0, 0.8);
}

.mobile-drawer.active {
  right: 0;
}

.drawer-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding-bottom: 20px;
  border-bottom: 1px solid var(--border-glass);
  margin-bottom: 24px;
}

.drawer-close-btn {
  background: rgba(255, 255, 255, 0.05);
  border: 1px solid var(--border-glass);
  color: var(--text-main);
  width: 36px;
  height: 36px;
  border-radius: var(--radius-md);
  display: flex;
  align-items: center;
  justify-content: center;
  cursor: pointer;
  transition: var(--transition-fast);
}

.drawer-close-btn:hover {
  background: rgba(255, 255, 255, 0.1);
  border-color: var(--primary-cyan);
}

.drawer-nav {
  display: flex;
  flex-direction: column;
  gap: 12px;
  flex: 1;
}

.drawer-link {
  display: flex;
  align-items: center;
  gap: 12px;
  padding: 12px 16px;
  background: rgba(255, 255, 255, 0.03);
  border: 1px solid var(--border-glass);
  border-radius: var(--radius-md);
  color: var(--text-main);
  text-decoration: none;
  font-weight: 500;
  font-size: 1rem;
  transition: var(--transition-fast);
}

.drawer-link:hover, .drawer-link.active {
  background: rgba(6, 182, 212, 0.15);
  border-color: var(--primary-cyan);
  color: var(--primary-cyan);
}

.drawer-footer {
  padding-top: 20px;
  border-top: 1px solid var(--border-glass);
}

.w-full {
  width: 100%;
}

/* --- Command Palette Dialog --- */
.cmd-palette-dialog {
  padding: 0;
  border: none;
  background: transparent;
  width: 100%;
  max-width: 600px;
  margin: auto;
  inset: 0;
  position: fixed;
  z-index: 1050;
  overflow: visible;
}

.cmd-palette-dialog::backdrop {
  background: rgba(0, 0, 0, 0.75);
  backdrop-filter: blur(12px);
  -webkit-backdrop-filter: blur(12px);
}

.cmd-palette-backdrop {
  display: none;
}

.cmd-palette-container {
  background: #090d16;
  border: 1px solid rgba(6, 182, 212, 0.4);
  border-radius: var(--radius-lg);
  box-shadow: 0 25px 50px -12px rgba(0, 0, 0, 0.9), 0 0 30px rgba(6, 182, 212, 0.2);
  overflow: hidden;
  display: flex;
  flex-direction: column;
  animation: cmdScaleIn 0.2s cubic-bezier(0.16, 1, 0.3, 1);
}

@keyframes cmdScaleIn {
  from { opacity: 0; transform: scale(0.95); }
  to { opacity: 1; transform: scale(1); }
}

.cmd-palette-search {
  display: flex;
  align-items: center;
  gap: 12px;
  padding: 18px 24px;
  border-bottom: 1px solid var(--border-glass);
  background: rgba(255, 255, 255, 0.02);
  color: var(--primary-cyan);
}

.cmd-palette-search input {
  flex: 1;
  background: transparent;
  border: none;
  outline: none;
  font-family: var(--font-body);
  font-size: 1.1rem;
  color: var(--text-main);
}

.cmd-palette-search input::placeholder {
  color: var(--text-dim);
}

.cmd-esc-badge {
  background: rgba(255, 255, 255, 0.1);
  border: 1px solid rgba(255, 255, 255, 0.15);
  border-radius: 4px;
  padding: 2px 8px;
  font-family: var(--font-mono);
  font-size: 0.75rem;
  color: var(--text-muted);
}

.cmd-palette-list {
  max-height: 380px;
  overflow-y: auto;
  padding: 12px;
  -webkit-mask-image: linear-gradient(to bottom, black 90%, transparent 100%);
  mask-image: linear-gradient(to bottom, black 90%, transparent 100%);
}

.cmd-group-title {
  font-size: 0.75rem;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 1px;
  color: var(--text-dim);
  padding: 8px 12px 4px;
}

.cmd-item {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 12px 16px;
  border-radius: var(--radius-md);
  color: var(--text-muted);
  cursor: pointer;
  transition: var(--transition-fast);
}

.cmd-item:hover, .cmd-item.selected {
  background: rgba(6, 182, 212, 0.15);
  color: var(--text-main);
}

.cmd-item-main {
  display: flex;
  align-items: center;
  gap: 12px;
  font-weight: 500;
}

.cmd-item-icon {
  font-size: 1.1rem;
}

.cmd-item-shortcut {
  font-family: var(--font-mono);
  font-size: 0.75rem;
  color: var(--primary-cyan);
  background: rgba(6, 182, 212, 0.1);
  padding: 2px 8px;
  border-radius: 4px;
}

.cmd-palette-footer {
  display: flex;
  align-items: center;
  gap: 20px;
  padding: 12px 24px;
  background: rgba(255, 255, 255, 0.02);
  border-top: 1px solid var(--border-glass);
  font-size: 0.8rem;
  color: var(--text-dim);
}

.cmd-palette-footer kbd {
  background: rgba(255, 255, 255, 0.1);
  padding: 1px 5px;
  border-radius: 3px;
  color: var(--text-muted);
}

/* --- Floating Action Hub & Progress Ring --- */
.floating-nav-hub {
  position: fixed;
  bottom: 28px;
  right: 28px;
  z-index: 90;
}

.btn-floating-top {
  position: relative;
  width: 44px;
  height: 44px;
  border-radius: 50%;
  background: rgba(11, 15, 25, 0.85);
  backdrop-filter: blur(12px);
  -webkit-backdrop-filter: blur(12px);
  border: 1px solid var(--border-glass);
  color: var(--primary-cyan);
  display: flex;
  align-items: center;
  justify-content: center;
  cursor: pointer;
  opacity: 0;
  visibility: hidden;
  transform: translateY(10px);
  transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
  box-shadow: 0 10px 25px rgba(0, 0, 0, 0.5), 0 0 15px rgba(6, 182, 212, 0.3);
}

.btn-floating-top.visible {
  opacity: 1;
  visibility: visible;
  transform: translateY(0);
}

.btn-floating-top:hover {
  transform: translateY(-4px) scale(1.05);
  box-shadow: 0 15px 30px rgba(0, 0, 0, 0.6), 0 0 25px rgba(6, 182, 212, 0.5);
  color: #fff;
}

.progress-ring {
  position: absolute;
  top: 0;
  left: 0;
  transform: rotate(-90deg);
  pointer-events: none;
}

.progress-ring-circle {
  stroke: var(--primary-cyan);
  stroke-dasharray: 113;
  stroke-dashoffset: 113;
  transition: stroke-dashoffset 0.1s linear;
}

/* View Transitions for SPA Navigation */
::view-transition-old(root) {
  animation: fadeOut 0.2s ease-out forwards;
}

::view-transition-new(root) {
  animation: fadeIn 0.25s ease-in forwards;
}

@keyframes fadeOut {
  from { opacity: 1; transform: scale(1); }
  to { opacity: 0; transform: scale(0.99); }
}

/* Scroll Reveal Animations (Modern Web Guidance) */
.scroll-reveal {
  opacity: 0;
  transform: translateY(28px);
  transition: opacity 0.6s cubic-bezier(0.16, 1, 0.3, 1), transform 0.6s cubic-bezier(0.16, 1, 0.3, 1);
  will-change: opacity, transform;
}

.scroll-reveal.revealed {
  opacity: 1;
  transform: translateY(0);
}
