/* 
 * Montage AI - Voxel Dark Mode Theme (SOTA Refactor)
 * Focus: Technical Readability, Fluid Typography, Mobile-First Responsiveness
 */

/* Fonts loaded from main style.css - using unified 3-font stack */

:root {
  /* --- COLOR SYSTEM (Neon Voxel) --- */
  --bg: #050505;
  --fg: #e0e0e0;
  --card-bg: #0d0d0d;
  
  --primary: #0055ff;      /* Electric Blue */
  --primary-glow: rgba(0, 85, 255, 0.3);
  --secondary: #ff5500;    /* Neon Orange */
  --secondary-glow: rgba(255, 85, 0, 0.3);
  
  --muted: #1a1a1a;
  --muted-fg: #888888;
  --border: #222222;
  --border-bright: #444444;
  --input-bg: #0a0a0a;
  
  --success: #00ff88;
  --warning: #ffcc00;
  --danger: #ff3333;  /* Consistent with docs */

  /* --- TYPOGRAPHY (Fluid & Technical - 2026 Stack) --- */
  --font-display: 'Space Grotesk', sans-serif;  /* Headlines */
  --font-body: 'Inter', sans-serif;              /* Body text */
  --font-mono: 'JetBrains Mono', monospace;      /* Code/Technical */
  
  /* SOTA: Fluid typography using clamp() */
  --fs-xs: clamp(0.7rem, 0.6rem + 0.5vw, 0.8rem);
  --fs-sm: clamp(0.8rem, 0.7rem + 0.5vw, 0.9rem);
  --fs-base: clamp(0.9rem, 0.8rem + 0.5vw, 1rem);
  --fs-lg: clamp(1.1rem, 1rem + 1vw, 1.3rem);
  --fs-xl: clamp(1.4rem, 1.2rem + 2vw, 1.8rem);
  --fs-2xl: clamp(1.8rem, 1.5rem + 3vw, 2.5rem);

  /* Technical details for mono fonts */
  --lh-tight: 1.1;
  --lh-base: 1.5;
  --ls-wide: 0.05em;
  --ls-tight: -0.02em;

  /* Technical Labels */
  --tech-label: {
    font-size: var(--fs-xs);
    text-transform: uppercase;
    letter-spacing: 0.1em;
    color: var(--muted-fg);
    font-weight: 700;
  };

  /* --- SHADOWS (Voxel Style - Subtle) --- */
  --shd-sm: 1px 1px 0px 0px var(--border);
  --shd-md: 2px 2px 0px 0px var(--border);
  --shd-primary: 2px 2px 0px 0px var(--primary);
  --shd-secondary: 2px 2px 0px 0px var(--secondary);

  /* --- GLOW EFFECTS (Selective - nur wo wichtig) --- */
  --glow-primary: 0 0 12px var(--primary-glow);
  --glow-secondary: 0 0 12px var(--secondary-glow);
  --glow-success: 0 0 10px rgba(0, 255, 136, 0.3);

  /* --- GRADIENTS (Artsy) --- */
  --gradient-primary: linear-gradient(135deg, var(--primary) 0%, #0088ff 100%);
  --gradient-secondary: linear-gradient(135deg, var(--secondary) 0%, #ff8800 100%);
  --gradient-cyber: linear-gradient(135deg, var(--primary) 0%, #ff00ff 50%, var(--secondary) 100%);
}

/* --- ANIMATIONS (Selective & Clean) --- */
@keyframes pulse-glow {
  0%, 100% { opacity: 1; }
  50% { opacity: 0.7; }
}

@keyframes float {
  0%, 100% { transform: translateY(0); }
  50% { transform: translateY(-3px); }
}

@keyframes subtle-border {
  0%, 100% { border-color: var(--border); }
  50% { border-color: var(--border-bright); }
}

/* --- RESET & BASE --- */
* {
  box-sizing: border-box;
  margin: 0;
  padding: 0;
}

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

body {
  background-color: var(--bg);
  color: var(--fg);
  font-family: var(--font-body);  /* Inter for readability */
  line-height: var(--lh-base);
  overflow-x: hidden;
  min-height: 100vh;
  
  /* Dark Grid Pattern */
  background-image: 
    linear-gradient(to right, rgba(255, 255, 255, 0.02) 1px, transparent 1px),
    linear-gradient(to bottom, rgba(255, 255, 255, 0.02) 1px, transparent 1px);
  background-size: 40px 40px;
}

/* --- LAYOUT --- */
.container {
  width: 100%;
  max-width: 1200px;
  margin: 0 auto;
  padding: 1rem;
}

@media (min-width: 768px) {
  .container { 
    padding: 2rem;
    max-width: 1280px;
  }
}

@media (min-width: 1024px) {
  .container { 
    padding: 2.5rem;
    max-width: 1400px;
  }
}

@media (min-width: 1280px) {
  .container { 
    padding: 3rem;
    max-width: 1600px;
  }
}

.grid {
  display: grid;
  gap: 1rem;
}

/* Responsive Grid System */
.grid-cols-auto { 
  grid-template-columns: repeat(auto-fit, minmax(300px, 1fr)); 
}

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

@media (min-width: 640px) {
  .sm\:grid-cols-2 { grid-template-columns: repeat(2, 1fr); }
}

@media (min-width: 768px) {
  .grid { gap: 1.5rem; }
  .md\:grid-cols-2 { grid-template-columns: repeat(2, 1fr); }
  .md\:grid-cols-3 { grid-template-columns: repeat(3, 1fr); }
  .md\:gap-6 { gap: 1.5rem; }
}

/* Large screens (1024px+) */
@media (min-width: 1024px) {
  .grid { gap: 1.5rem; }
  .lg\:grid-cols-2 { grid-template-columns: repeat(2, 1fr); }
  .lg\:grid-cols-3 { grid-template-columns: repeat(3, 1fr); }
  .lg\:grid-cols-4 { grid-template-columns: repeat(4, 1fr); }
  .lg\:gap-8 { gap: 2rem; }
}

/* X-Large screens (1280px+) */
@media (min-width: 1280px) {
  .xl\:grid-cols-3 { grid-template-columns: repeat(3, 1fr); }
  .xl\:grid-cols-4 { grid-template-columns: repeat(4, 1fr); }
  .xl\:gap-8 { gap: 2rem; }
}

.flex { display: flex; }
.flex-col { flex-direction: column; }
.flex-wrap { flex-wrap: wrap; }
.items-center { align-items: center; }
.items-start { align-items: flex-start; }
.items-end { align-items: flex-end; }
.justify-between { justify-content: space-between; }
.justify-center { justify-content: center; }
.justify-start { justify-content: flex-start; }
.justify-end { justify-content: flex-end; }
.gap-1 { gap: 0.25rem; }
.gap-2 { gap: 0.5rem; }
.gap-3 { gap: 0.75rem; }
.gap-4 { gap: 1rem; }
.gap-6 { gap: 1.5rem; }
.gap-8 { gap: 2rem; }

/* Utility helpers */
.mt-1 { margin-top: 1rem; }
.mt-05 { margin-top: 0.5rem; }
.mt-075 { margin-top: 0.75rem; }
.mb-05 { margin-bottom: 0.5rem; }
.full-width { width: 100%; }
.hidden-input { display: none; }
.stacked-option { display: flex; flex-direction: column; align-items: flex-start; }
.hidden { display: none !important; }
.progress-fill-zero { width: 0%; }

/* Responsive flex direction */
@media (min-width: 768px) {
  .md\:flex-row { flex-direction: row; }
  .md\:flex-col { flex-direction: column; }
  .md\:justify-end { justify-content: flex-end; }
  .md\:items-center { align-items: center; }
  .md\:items-end { align-items: flex-end; }
}

@media (min-width: 1024px) {
  .lg\:flex-row { flex-direction: row; }
}

/* --- TYPOGRAPHY --- */
h1, h2, h3, h4, h5, h6 {
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: var(--ls-wide);
  line-height: var(--lh-tight);
  margin-bottom: 0.5rem;
}

h1 { font-size: var(--fs-xl); }
h2 { font-size: var(--fs-lg); }
h3 { font-size: var(--fs-base); }

/* --- PAGE WRAPPER (SPA Consistency) --- */
.page-wrapper {
  display: flex;
  flex-direction: column;
  min-height: 100vh;
  background-color: var(--bg);
}

.container-app {
  flex: 1;
}

/* --- FOOTER (Consistent Across All Pages) --- */
.app-footer {
  background-color: var(--card-bg);
  border-top: 2px solid var(--border);
  padding: 2rem 1.5rem;
  margin-top: 3rem;
  color: var(--muted-fg);
  font-size: var(--fs-xs);
}

@media (min-width: 768px) {
  .app-footer { padding: 2.5rem 2rem; }
}

.footer-content {
  max-width: 1400px;
  margin: 0 auto;
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: 2rem;
  flex-wrap: wrap;
}

.footer-section {
  flex: 1;
}

.footer-tagline {
  margin: 0;
  color: var(--muted-fg);
  font-weight: 700;
  letter-spacing: 0.05em;
}

.footer-links {
  display: flex;
  gap: 2rem;
  justify-content: flex-end;
}

.footer-links a {
  color: var(--primary);
  text-decoration: none;
  font-weight: 700;
  text-transform: uppercase;
  transition: color 0.1s ease;
  font-size: var(--fs-xs);
}

.footer-links a:hover {
  color: var(--secondary);
}

@media (max-width: 640px) {
  .footer-content {
    flex-direction: column;
    gap: 1rem;
  }
  
  .footer-section {
    width: 100%;
  }
  
  .footer-links {
    justify-content: flex-start;
    gap: 1rem;
  }
}

.voxel-title {
  font-size: var(--fs-2xl);
  color: var(--primary);
  letter-spacing: var(--ls-tight);
  margin-bottom: 1rem;
  font-weight: 900;
}

.text-primary { color: var(--primary); }
.text-secondary { color: var(--secondary); }
.text-muted { color: var(--muted-fg); }
.text-xs { font-size: var(--fs-xs); }
.text-sm { font-size: var(--fs-sm); }
.text-center { text-align: center; }

/* --- COMPONENTS --- */

/* Navbar - Voxel Design System (2-Line Grid Layout) */
.navbar-voxel {
  background-color: var(--card-bg);
  border-bottom: 2px solid var(--primary);
  padding: 0;
  display: grid;
  grid-template-columns: 1fr;
  position: sticky;
  top: 0;
  z-index: 1000;
}

/* Line 1: Brand + Primary Navigation */
.navbar-top {
  display: flex;
  align-items: center;
  gap: 2rem;
  padding: 1rem 1.5rem;
  border-bottom: 1px solid var(--border);
}

/* Line 2: Secondary Navigation (Dropdowns) */
.navbar-bottom {
  padding: 0.75rem 1.5rem;
  background-color: rgba(0, 85, 255, 0.05);
}

@media (min-width: 768px) {
  .navbar-top { padding: 1rem 2rem; }
  .navbar-bottom { padding: 0.75rem 2rem; }
}

/* Brand Styling - Minimal & Iconic */
.nav-brand {
  font-weight: 900;
  font-size: var(--fs-xl);
  color: var(--fg);
  text-decoration: none;
  text-transform: uppercase;
  letter-spacing: -0.02em;
  display: flex;
  align-items: center;
  gap: 0.5rem;
  transition: all 0.2s ease;
  white-space: nowrap;
}

.nav-brand span {
  color: var(--primary);
  font-size: 1.2em;
  animation: pulse-glow 2s ease-in-out infinite;
}

.nav-brand:hover {
  transform: scale(1.02);
}

/* Primary Navigation (Line 1) */
.nav-primary {
  display: flex;
  gap: 1.5rem;
  margin-left: auto;
}

@media (max-width: 640px) {
  .nav-primary { display: none; }
  .navbar.nav-open .nav-primary {
    display: flex;
    flex-direction: column;
    position: absolute;
    top: 100%;
    left: 0;
    right: 0;
    background: var(--bg);
    border-bottom: 2px solid var(--primary);
    padding: 1rem;
    gap: 0.5rem;
    z-index: 1000;
  }
  .navbar.nav-open .nav-primary .nav-link {
    padding: 0.75rem 1rem;
    border: 1px solid var(--border);
  }
}

/* Hamburger Button (Mobile) */
.nav-hamburger {
  display: none;
  background: transparent;
  border: 2px solid var(--border);
  padding: 0.5rem;
  cursor: pointer;
  flex-direction: column;
  gap: 4px;
  margin-left: auto;
}
.nav-hamburger span {
  display: block;
  width: 20px;
  height: 2px;
  background: var(--fg);
  transition: all 0.2s ease;
}
@media (max-width: 640px) {
  .nav-hamburger { display: flex; }
}
/* Hamburger Animation */
.navbar.nav-open .nav-hamburger span:nth-child(1) {
  transform: rotate(45deg) translate(4px, 4px);
}
.navbar.nav-open .nav-hamburger span:nth-child(2) {
  opacity: 0;
}
.navbar.nav-open .nav-hamburger span:nth-child(3) {
  transform: rotate(-45deg) translate(4px, -4px);
}

/* Secondary Navigation (Line 2) - Dropdowns */
.nav-secondary {
  display: flex;
  gap: 2rem;
}

@media (max-width: 640px) {
  .nav-secondary { gap: 1rem; }
}

/* All Navigation Links */
.nav-link {
  color: var(--muted-fg);
  text-decoration: none;
  font-weight: 700;
  font-size: var(--fs-sm);
  text-transform: uppercase;
  white-space: nowrap;
  letter-spacing: 0.05em;
  transition: color 0.1s ease;
  position: relative;
  padding-bottom: 2px;
}

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

.nav-link.active {
  color: var(--primary);
  border-bottom: 2px solid var(--primary);
  padding-bottom: 0;
}

.nav-link.dropdown-toggle::after {
  content: '';
  display: inline-block;
  width: 0;
  height: 0;
  margin-left: 0.4rem;
  border-left: 3px solid transparent;
  border-right: 3px solid transparent;
  border-top: 3px solid currentColor;
  vertical-align: 0.15em;
}

/* Dropdown Menu - Elegant 2-Item Layout */
.nav-group {
  position: relative;
  display: inline-block;
}

.nav-dropdown {
  display: none;
  position: absolute;
  background-color: var(--card-bg);
  min-width: 200px;
  max-width: 220px;
  border: 2px solid var(--border);
  border-top: 2px solid var(--primary);
  box-shadow: var(--shd-md);
  z-index: 1001;
  top: 100%;
  padding: 0.75rem 0;
  margin-top: 0.5rem;
}

/* First dropdown (TOOLS) - opens to the right */
.nav-group:first-child .nav-dropdown {
  left: 0;
  right: auto;
}

/* Last dropdown (RESOURCES) - opens to the left */
.nav-group:last-child .nav-dropdown {
  right: 0;
  left: auto;
}

.nav-group:hover .nav-dropdown {
  display: block;
  animation: slideDown 0.15s ease-out;
}

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

.nav-dropdown .nav-link {
  display: block;
  padding: 0.6rem 1rem;
  font-size: var(--fs-xs);
  border: none;
  transition: all 0.1s ease;
}

.nav-dropdown .nav-link:hover {
  background-color: rgba(0, 85, 255, 0.1);
  padding-left: 1.2rem;
}

.nav-link:hover, .nav-link.active {
  color: var(--primary);
}

/* Voxel Card */
.voxel-card {
  background-color: var(--card-bg);
  border: 2px solid var(--border);
  box-shadow: var(--shd-md);
  padding: 1.25rem;
  transition: transform 0.1s steps(2), box-shadow 0.1s steps(2);
  height: 100%; /* Ensure cards in grid fill height */
  display: flex;
  flex-direction: column;
}

@media (min-width: 768px) {
  .voxel-card { padding: 1.5rem; }
}

.voxel-card:hover {
  transform: translate(-2px, -2px);
  box-shadow: var(--shd-primary);
  border-color: var(--primary);
}

/* Voxel Button */
.voxel-btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  padding: 0.6rem 1.2rem;
  font-family: var(--font-mono);
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: var(--ls-wide);
  background-color: var(--muted);
  color: var(--fg);
  border: 2px solid var(--border);
  box-shadow: var(--shd-sm);
  cursor: pointer;
  text-decoration: none;
  transition: all 0.1s steps(2);
  font-size: var(--fs-sm);
  white-space: nowrap;
}

.voxel-btn:hover {
  transform: translate(-2px, -2px);
  box-shadow: var(--shd-md);
  background-color: var(--border-bright);
}

.voxel-btn:active {
  transform: translate(1px, 1px);
  box-shadow: 1px 1px 0px 0px var(--border);
}

.voxel-btn-primary {
  background-color: var(--primary);
  color: white;
  border-color: var(--primary);
}

.voxel-btn-primary:hover {
  box-shadow: var(--shd-primary);
  filter: brightness(1.1);
}

.voxel-btn-secondary {
  background-color: var(--secondary);
  color: white;
  border-color: var(--secondary);
}

.voxel-btn-secondary:hover {
  box-shadow: var(--shd-secondary);
  filter: brightness(1.1);
}

.voxel-btn-sm {
  padding: 0.4rem 0.8rem;
  font-size: var(--fs-xs);
}

.voxel-btn:disabled {
  opacity: 0.5;
  cursor: not-allowed;
}

.voxel-btn:disabled:hover {
  transform: none;
  box-shadow: var(--shd-sm);
  background-color: var(--muted);
}

/* Voxel Input & Textarea */
.voxel-input {
  width: 100%;
  background-color: var(--input-bg);
  color: var(--fg);
  border: 2px solid var(--border);
  padding: 0.75rem;
  font-family: var(--font-mono);
  font-size: var(--fs-sm);
  outline: none;
  box-shadow: var(--shd-sm);
  transition: border-color 0.1s steps(2);
}

.voxel-input:focus {
  border-color: var(--primary);
}

textarea.voxel-input {
  resize: vertical;
  min-height: 120px;
}

/* Voxel Checkbox */
.voxel-checkbox {
  appearance: none;
  width: 1.25rem;
  height: 1.25rem;
  border: 2px solid var(--border);
  background-color: var(--input-bg);
  cursor: pointer;
  position: relative;
  box-shadow: 2px 2px 0px 0px var(--border);
  flex-shrink: 0;
}

.voxel-checkbox:checked {
  background-color: var(--primary);
  border-color: var(--primary);
}

.voxel-checkbox:checked::after {
  content: 'X';
  position: absolute;
  top: 50%;
  left: 50%;
  transform: translate(-50%, -50%);
  color: white;
  font-size: 0.75rem;
  font-weight: 900;
}

/* Badge */
.voxel-badge {
  display: inline-block;
  padding: 0.2rem 0.6rem;
  font-size: var(--fs-xs);
  font-weight: 800;
  text-transform: uppercase;
  border: 2px solid currentColor;
  box-shadow: 2px 2px 0px 0px currentColor;
  background: var(--bg);
  letter-spacing: var(--ls-wide);
}

.voxel-badge-primary { color: var(--primary); }
.voxel-badge-secondary { color: var(--secondary); }

/* Progress Bar */
.progress-container {
  width: 100%;
  height: 12px;
  background-color: var(--muted);
  border: 2px solid var(--border);
  box-shadow: 2px 2px 0px 0px var(--border);
  overflow: hidden;
}

.progress-bar {
  height: 100%;
  background-color: var(--primary);
  width: 0%;
  transition: width 0.3s steps(10);
}

/* --- UTILITIES --- */
.w-full { width: 100%; }
.flex-1 { flex: 1; }
.flex-shrink-0 { flex-shrink: 0; }
.min-w-0 { min-width: 0; }
.truncate { white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }

/* Spacing utilities */
.mb-1 { margin-bottom: 0.25rem; }
.mb-2 { margin-bottom: 0.5rem; }
.mb-3 { margin-bottom: 0.75rem; }
.mb-4 { margin-bottom: 1rem; }
.mb-6 { margin-bottom: 1.5rem; }
.mb-8 { margin-bottom: 2rem; }
.mb-12 { margin-bottom: 3rem; }
.mt-4 { margin-top: 1rem; }
.mt-8 { margin-top: 2rem; }
.pt-4 { padding-top: 1rem; }
.pt-8 { padding-top: 2rem; }
.py-12 { padding-top: 3rem; padding-bottom: 3rem; }

/* Space between items in flex columns */
.space-y-1 > * + * { margin-top: 0.25rem; }
.space-y-2 > * + * { margin-top: 0.5rem; }
.space-y-3 > * + * { margin-top: 0.75rem; }
.space-y-4 > * + * { margin-top: 1rem; }

/* Border utilities */
.border-t { border-top: 2px solid var(--border); }
.border-b { border-bottom: 2px solid var(--border); }
.border-l { border-left: 2px solid var(--border); }
.border-r { border-right: 2px solid var(--border); }
.border-border { border-color: var(--border); }

/* Badge styles */
.badge {
  display: inline-block;
  padding: 0.2rem 0.6rem;
  font-size: var(--fs-xs);
  font-weight: 800;
  text-transform: uppercase;
  border: 2px solid var(--border);
  background: var(--muted);
  color: var(--fg);
  letter-spacing: var(--ls-wide);
}

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

.badge-secondary {
  background: var(--secondary);
  color: white;
  border-color: var(--secondary);
}

/* Blocky Scrollbar */
::-webkit-scrollbar {
  width: 10px;
  height: 10px;
}

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

::-webkit-scrollbar-thumb {
  background: var(--border-bright);
  border: 2px solid var(--bg);
}

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

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

/* --- LAYOUT COMPONENTS --- */

/* Workflow card - for homepage feature cards */
.workflow-card {
  position: relative;
  overflow: hidden;
}

.workflow-card::before {
  content: '';
  position: absolute;
  top: 0;
  left: 0;
  right: 0;
  height: 2px;
  background: linear-gradient(90deg, var(--primary), var(--secondary), transparent);
}

.workflow-icon {
  font-size: 2.5rem;
  text-align: center;
  line-height: 1;
  opacity: 0.8;
}

/* --- RESPONSIVE FIXES --- */
img, video, canvas {
  max-width: 100%;
  height: auto;
}

.panel-stack {
  display: flex;
  flex-direction: column;
  gap: 1rem;
}

/* Fix for overflowing text in cards */
.voxel-card p {
  word-wrap: break-word;
  overflow-wrap: break-word;
}

/* Technical Typography Details */
.tech-label {
  font-size: var(--fs-xs);
  text-transform: uppercase;
  letter-spacing: 0.1em;
  color: var(--muted-fg);
  font-weight: 700;
  display: block;
  margin-bottom: 0.25rem;
}

.tech-value {
  font-family: var(--font-mono);
  font-weight: 900;
  color: var(--primary);
}

/* Scanline Effect (Subtle) */
body::after {
  content: " ";
  display: block;
  position: fixed;
  top: 0;
  left: 0;
  bottom: 0;
  right: 0;
  background: linear-gradient(rgba(18, 16, 16, 0) 50%, rgba(0, 0, 0, 0.1) 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% 4px, 3px 100%;
  pointer-events: none;
  opacity: 0.3;
}

/* ==========================================================================
   ARTSY VOXEL ENHANCEMENTS
   ========================================================================== */

/* Glitch Text Effect */
@keyframes glitch {
  0% {
    text-shadow: 3px 3px 0px var(--secondary), -1px -1px 0px var(--primary);
  }
  25% {
    text-shadow: -3px 3px 0px var(--secondary), 1px -1px 0px var(--primary);
  }
  50% {
    text-shadow: 3px -3px 0px var(--primary), -1px 1px 0px var(--secondary);
  }
  75% {
    text-shadow: -3px -3px 0px var(--primary), 1px 1px 0px var(--secondary);
  }
  100% {
    text-shadow: 3px 3px 0px var(--secondary), -1px -1px 0px var(--primary);
  }
}

.voxel-title:hover {
  animation: glitch 0.3s ease-in-out infinite;
}

/* Neon Glow Animation */
@keyframes neonPulse {
  0%, 100% {
    box-shadow: var(--shd-md), 0 0 10px var(--primary-glow);
  }
  50% {
    box-shadow: var(--shd-md), 0 0 25px var(--primary-glow), 0 0 50px var(--primary-glow);
  }
}

.voxel-card.glow-effect {
  animation: neonPulse 3s ease-in-out infinite;
}

/* Cyberpunk Corner Accents */
.voxel-card::before {
  content: '';
  position: absolute;
  top: -2px;
  left: -2px;
  width: 20px;
  height: 20px;
  border-top: 3px solid var(--primary);
  border-left: 3px solid var(--primary);
  pointer-events: none;
  opacity: 0;
  transition: opacity 0.2s;
}

.voxel-card::after {
  content: '';
  position: absolute;
  bottom: -2px;
  right: -2px;
  width: 20px;
  height: 20px;
  border-bottom: 3px solid var(--secondary);
  border-right: 3px solid var(--secondary);
  pointer-events: none;
  opacity: 0;
  transition: opacity 0.2s;
}

.voxel-card {
  position: relative;
}

.voxel-card:hover::before,
.voxel-card:hover::after {
  opacity: 1;
}

/* Matrix Rain Effect for Background (Optional Class) */
@keyframes matrixRain {
  0% {
    background-position: 0% 0%;
  }
  100% {
    background-position: 0% 100%;
  }
}

.matrix-bg {
  background-image:
    url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='40' height='40'%3E%3Ctext x='0' y='30' fill='%230055ff' opacity='0.03' font-family='monospace' font-size='10'%3E01%3C/text%3E%3C/svg%3E");
  animation: matrixRain 20s linear infinite;
}

/* Pixel Art Border Animation */
@keyframes pixelBorder {
  0%, 100% {
    border-image: linear-gradient(90deg, var(--primary), var(--secondary), var(--primary)) 1;
  }
  50% {
    border-image: linear-gradient(90deg, var(--secondary), var(--primary), var(--secondary)) 1;
  }
}

.voxel-btn-primary:hover,
.voxel-btn-secondary:hover {
  animation: pixelBorder 1s steps(5) infinite;
}

/* Holographic Gradient */
@keyframes holoShift {
  0% {
    background-position: 0% 50%;
  }
  50% {
    background-position: 100% 50%;
  }
  100% {
    background-position: 0% 50%;
  }
}

.holo-gradient {
  background: linear-gradient(
    135deg,
    var(--primary) 0%,
    var(--secondary) 25%,
    #9b59b6 50%,
    var(--primary) 75%,
    var(--secondary) 100%
  );
  background-size: 400% 400%;
  animation: holoShift 8s ease infinite;
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
  background-clip: text;
}

/* VHS Tracking Lines */
@keyframes vhsTracking {
  0%, 90%, 100% {
    opacity: 0;
  }
  92%, 98% {
    opacity: 0.3;
  }
  95% {
    transform: translateX(-5px);
  }
}

.vhs-effect::before {
  content: '';
  position: absolute;
  top: 0;
  left: 0;
  right: 0;
  height: 100%;
  background: repeating-linear-gradient(
    0deg,
    transparent,
    transparent 2px,
    rgba(255, 255, 255, 0.03) 2px,
    rgba(255, 255, 255, 0.03) 4px
  );
  pointer-events: none;
  animation: vhsTracking 8s ease-in-out infinite;
}

/* Retro CRT Corner Vignette */
.crt-vignette {
  box-shadow:
    inset 0 0 100px rgba(0, 0, 0, 0.5),
    inset 0 0 50px rgba(0, 0, 0, 0.3);
}

/* Data Stream Animation */
@keyframes dataStream {
  0% {
    transform: translateY(-100%);
    opacity: 0;
  }
  10% {
    opacity: 0.5;
  }
  90% {
    opacity: 0.5;
  }
  100% {
    transform: translateY(100%);
    opacity: 0;
  }
}

/* Typing Cursor Animation */
@keyframes blink {
  0%, 100% { opacity: 1; }
  50% { opacity: 0; }
}

.typing-cursor::after {
  content: '█';
  animation: blink 1s step-end infinite;
  color: var(--primary);
}

/* Tech Label with Line */
.tech-label-line {
  display: flex;
  align-items: center;
  gap: 0.5rem;
  font-size: var(--fs-xs);
  text-transform: uppercase;
  letter-spacing: 0.1em;
  color: var(--muted-fg);
  font-weight: 700;
  margin-bottom: 0.5rem;
}

.tech-label-line::after {
  content: '';
  flex: 1;
  height: 1px;
  background: linear-gradient(90deg, var(--border) 0%, transparent 100%);
}

/* Hexagon Badge */
.hex-badge {
  position: relative;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  padding: 0.5rem 1rem;
  background: var(--primary);
  color: white;
  font-size: var(--fs-xs);
  font-weight: 900;
  text-transform: uppercase;
  clip-path: polygon(10% 0%, 90% 0%, 100% 50%, 90% 100%, 10% 100%, 0% 50%);
}

/* Animated Progress Bar */
@keyframes progressGlow {
  0%, 100% {
    box-shadow: 0 0 5px var(--primary);
  }
  50% {
    box-shadow: 0 0 20px var(--primary), 0 0 30px var(--primary-glow);
  }
}

.progress-bar.animated {
  animation: progressGlow 2s ease-in-out infinite;
}

/* Stacked Paper Effect */
.stacked-card {
  position: relative;
}

.stacked-card::before {
  content: '';
  position: absolute;
  top: 8px;
  left: 8px;
  right: -8px;
  bottom: -8px;
  background: var(--border);
  z-index: -1;
}

/* Pixel Perfect Divider */
.pixel-divider {
  height: 4px;
  background: repeating-linear-gradient(
    90deg,
    var(--primary) 0px,
    var(--primary) 8px,
    transparent 8px,
    transparent 16px,
    var(--secondary) 16px,
    var(--secondary) 24px,
    transparent 24px,
    transparent 32px
  );
  margin: 2rem 0;
}

/* Floating Action Button */
.fab {
  position: fixed;
  bottom: 2rem;
  right: 2rem;
  width: 60px;
  height: 60px;
  display: flex;
  align-items: center;
  justify-content: center;
  background: var(--primary);
  border: 3px solid var(--primary);
  box-shadow: var(--shd-primary), 0 0 20px var(--primary-glow);
  cursor: pointer;
  font-size: 1.5rem;
  color: white;
  transition: all 0.2s;
  z-index: 1000;
}

.fab:hover {
  transform: translate(-4px, -4px);
  box-shadow: 8px 8px 0px 0px var(--secondary), 0 0 40px var(--primary-glow);
}

/* Status Indicator Dots */
.status-dot {
  width: 12px;
  height: 12px;
  border: 2px solid currentColor;
  position: relative;
}

.status-dot.online {
  background: var(--success);
  border-color: var(--success);
  animation: neonPulse 2s ease-in-out infinite;
}

.status-dot.processing {
  background: var(--secondary);
  border-color: var(--secondary);
  animation: neonPulse 1s ease-in-out infinite;
}

.status-dot.offline {
  background: var(--danger);
  border-color: var(--danger);
}

/* Ribbon Label */
.ribbon {
  position: absolute;
  top: 10px;
  right: -30px;
  background: var(--secondary);
  color: white;
  padding: 0.25rem 2rem;
  font-size: var(--fs-xs);
  font-weight: 900;
  text-transform: uppercase;
  transform: rotate(45deg);
  box-shadow: 0 2px 10px rgba(255, 85, 0, 0.3);
}

/* Input Focus Glow */
.voxel-input:focus {
  border-color: var(--primary);
  box-shadow: var(--shd-sm), 0 0 10px var(--primary-glow);
}

/* Checkbox Glow on Check */
.voxel-checkbox:checked {
  box-shadow: 2px 2px 0px 0px var(--border), 0 0 10px var(--primary-glow);
}

/* Card Category Colors */
.option-group {
  position: relative;
  overflow: hidden;
}

.option-group::before {
  content: '';
  position: absolute;
  top: 0;
  left: 0;
  width: 4px;
  height: 100%;
  background: var(--primary);
}

/* Animated Underline Links */
.animated-link {
  position: relative;
  color: var(--primary);
  text-decoration: none;
}

.animated-link::after {
  content: '';
  position: absolute;
  bottom: -2px;
  left: 0;
  width: 0;
  height: 2px;
  background: var(--secondary);
  transition: width 0.3s;
}

.animated-link:hover::after {
  width: 100%;
}

/* Feature Grid Hover */
.feature-highlight {
  transition: all 0.2s;
}

.feature-highlight:hover {
  background: linear-gradient(135deg, rgba(0, 85, 255, 0.1), rgba(255, 85, 0, 0.1));
  border-color: var(--primary);
}

/* =============================================================================
   FUNKY & ARTSY ENHANCEMENTS (2026)
   ============================================================================= */

/* Cyber Section Headers */
.cyber-header {
  position: relative;
  padding: 1rem 0;
  margin-bottom: 1.5rem;
  text-transform: uppercase;
  letter-spacing: 0.2em;
  font-weight: 900;
}

.cyber-header::before {
  content: '//';
  color: var(--secondary);
  margin-right: 0.5rem;
}

.cyber-header::after {
  content: '';
  position: absolute;
  bottom: 0;
  left: 0;
  width: 100%;
  height: 2px;
  background: var(--gradient-cyber);
}

/* Glowing Card Variant */
.voxel-card.glow {
  border-color: var(--primary);
  box-shadow: var(--shd-primary), var(--glow-primary);
}

.voxel-card.glow:hover {
  animation: pulse-glow 2s ease-in-out infinite;
}

/* Gradient Border Card */
.voxel-card.gradient-border {
  border: 2px solid transparent;
  background: linear-gradient(var(--card-bg), var(--card-bg)) padding-box,
              var(--gradient-cyber) border-box;
}

/* Floating Animation */
.float-anim {
  animation: float 3s ease-in-out infinite;
}

/* Glitch Text Effect */
.glitch-text {
  position: relative;
}

.glitch-text:hover {
  animation: glitch 0.3s ease-in-out;
}

/* Neon Badge */
.neon-badge {
  display: inline-block;
  padding: 0.25rem 0.75rem;
  font-size: var(--fs-xs);
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.1em;
  border: 1px solid currentColor;
  box-shadow: 0 0 10px currentColor;
}

.neon-badge.primary {
  color: var(--primary);
  box-shadow: 0 0 10px var(--primary-glow);
}

.neon-badge.secondary {
  color: var(--secondary);
  box-shadow: 0 0 10px var(--secondary-glow);
}

.neon-badge.success {
  color: var(--success);
  box-shadow: 0 0 10px rgba(0, 255, 136, 0.3);
}

/* Icon Glow */
.icon-glow {
  filter: drop-shadow(0 0 5px currentColor);
}

/* Step Counter (Funky numbered steps) */
.step-number {
  display: flex;
  align-items: center;
  justify-content: center;
  width: 2.5rem;
  height: 2.5rem;
  background: var(--gradient-primary);
  color: white;
  font-weight: 900;
  font-size: var(--fs-lg);
  box-shadow: var(--shd-sm), var(--glow-primary);
  flex-shrink: 0;
}

/* Decorative Corner */
.corner-deco {
  position: relative;
}

.corner-deco::before,
.corner-deco::after {
  content: '';
  position: absolute;
  width: 20px;
  height: 20px;
  border: 2px solid var(--primary);
}

.corner-deco::before {
  top: -5px;
  left: -5px;
  border-right: none;
  border-bottom: none;
}

.corner-deco::after {
  bottom: -5px;
  right: -5px;
  border-left: none;
  border-top: none;
}

/* Scanline Overlay */
.scanlines::after {
  content: '';
  position: absolute;
  top: 0;
  left: 0;
  right: 0;
  bottom: 0;
  background: repeating-linear-gradient(
    0deg,
    rgba(0, 0, 0, 0.1) 0px,
    rgba(0, 0, 0, 0.1) 1px,
    transparent 1px,
    transparent 2px
  );
  pointer-events: none;
  opacity: 0.3;
}

/* Feature Card with Icon */
.feature-card {
  display: flex;
  flex-direction: column;
  align-items: center;
  text-align: center;
  padding: 1.5rem;
  background: var(--card-bg);
  border: 2px solid var(--border);
  transition: all 0.2s;
}

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

.feature-card .icon {
  font-size: 2rem;
  margin-bottom: 0.75rem;
  filter: drop-shadow(0 0 10px var(--primary-glow));
}

.feature-card h4 {
  color: var(--primary);
  margin-bottom: 0.5rem;
}

.feature-card p {
  font-size: var(--fs-xs);
  color: var(--muted-fg);
}

/* Category Pill */
.category-pill {
  display: inline-flex;
  align-items: center;
  gap: 0.5rem;
  padding: 0.5rem 1rem;
  background: var(--muted);
  border-left: 3px solid var(--primary);
  font-size: var(--fs-xs);
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.05em;
}

.category-pill.video { border-color: var(--primary); }
.category-pill.audio { border-color: var(--success); }
.category-pill.color { border-color: var(--secondary); }
.category-pill.story { border-color: #9b59b6; }
.category-pill.output { border-color: var(--warning); }

/* Animated Progress Bar */
.cyber-progress {
  height: 4px;
  background: var(--muted);
  overflow: hidden;
  position: relative;
}

.cyber-progress::after {
  content: '';
  position: absolute;
  top: 0;
  left: 0;
  height: 100%;
  background: var(--gradient-cyber);
  animation: progress-shimmer 2s ease-in-out infinite;
}

@keyframes progress-shimmer {
  0% { width: 0%; opacity: 1; }
  50% { width: 100%; opacity: 0.5; }
  100% { width: 0%; opacity: 1; }
}

/* Radio/Checkbox as Styled Cards */
.choice-card {
  cursor: pointer;
  padding: 1rem;
  border: 2px solid var(--border);
  background: var(--card-bg);
  transition: all 0.15s;
}

.choice-card:hover {
  border-color: var(--primary);
  background: rgba(0, 85, 255, 0.05);
}

.choice-card.selected,
.choice-card:has(input:checked) {
  border-color: var(--secondary);
  background: rgba(255, 85, 0, 0.1);
  box-shadow: var(--shd-secondary);
}

.choice-card input {
  display: none;
}

/* --- ANIMATED ICONS & HEADER STATUS (Re-applying) --- */

.anim-icon {
  width: 42px;
  height: 42px;
  fill: none;
  stroke: currentColor;
  stroke-width: 2;
  stroke-linecap: round;
  stroke-linejoin: round;
  transition: all 0.4s cubic-bezier(0.175, 0.885, 0.32, 1.275);
}

.workflow-card:hover .anim-icon {
  transform: translateY(-5px) scale(1.1);
  stroke-width: 2.5;
  filter: drop-shadow(0 0 10px currentColor);
}

/* Specific Animations based on context */
.workflow-card:hover .icon-camera {
  transform: rotate(-10deg) scale(1.1);
}
.workflow-card:hover .icon-mobile {
  transform: rotate(10deg) scale(1.1);
}

.system-status-compact {
  display: flex;
  flex-direction: column;
  gap: 0.5rem;
  padding: 0.75rem 1rem;
  background: var(--card-bg);
  border: 1px solid var(--border);
}

.status-grid {
  display: grid;
  grid-template-columns: auto auto;
  gap: 0.5rem 1.5rem;
  align-items: center;
}

.status-item {
  display: flex;
  align-items: center;
  gap: 0.5rem;
  font-size: var(--fs-xs);
  color: var(--muted-fg);
}

.status-val {
  font-weight: bold;
  color: var(--fg);
}

.status-mini-bar {
  width: 60px;
  height: 4px;
  background: var(--muted);
  border-radius: 2px;
  overflow: hidden;
}

.status-mini-fill {
  height: 100%;
  background: var(--primary);
}

/* --- RECENT JOBS THUMBNAIL & PREVIEW --- */
.job-preview-container {
    width: 120px;
    height: 68px; /* 16:9 approx */
    background: #000;
    position: relative;
    overflow: hidden;
    border-radius: 4px;
    border: 1px solid var(--border);
    flex-shrink: 0;
}

.job-thumbnail {
    width: 100%;
    height: 100%;
    object-fit: cover;
    transition: opacity 0.3s;
}

.job-video-preview {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    object-fit: cover;
    opacity: 0;
    transition: opacity 0.3s;
}

.job-preview-container:hover .job-thumbnail {
    opacity: 0;
}

.job-preview-container:hover .job-video-preview {
    opacity: 1;
}

/* --- AUDIO SCRUBBER --- */
.audio-scrubber-container {
    background: var(--muted);
    border: 1px solid var(--border);
    padding: 1rem;
    position: relative;
}

.waveform-visual {
    height: 40px;
    display: flex;
    align-items: center;
    gap: 2px;
    margin-bottom: 0.5rem;
    opacity: 0.7;
}

.wave-bar {
    flex: 1;
    background: var(--primary);
    border-radius: 1px;
    transition: height 0.2s;
}

input[type=range].scrubber {
  width: 100%;
  -webkit-appearance: none;
  appearance: none;
    background: transparent;
    position: absolute;
    top: 1rem;
    left: 1rem;
    right: 1rem;
    width: calc(100% - 2rem);
    height: 40px;
    cursor: pointer;
}

input[type=range].scrubber::-webkit-slider-thumb {
    -webkit-appearance: none;
    height: 40px;
    width: 4px;
    background: #fff;
    border: none;
    cursor: pointer;
    box-shadow: 0 0 10px rgba(255,255,255,0.5);
}

/* --- FOOTER SLOGAN --- */
.footer-slogan {
    font-family: var(--font-mono);
    font-weight: 700;
    font-size: var(--fs-lg);
    color: var(--muted-fg);
    letter-spacing: -0.05em;
    opacity: 0.5;
}


