/* 
   === Robot Visualizer Soft Aurora Stylesheet ===
   Awwwards-level Glassmorphic Dark-Mode Design System
*/

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

:root {
  --bg-color: #080710;       /* Dark space violet base */
  --panel-bg: rgba(15, 11, 28, 0.7); /* Glassmorphic dark sheet */
  --text-primary: #FAF6F0;   /* Creamy warm white (easy reading) */
  --text-muted: #9CA3AF;     /* Soft slate gray */
  --border-color: rgba(255, 255, 255, 0.16); /* Delicate transparent border */
  
  /* Glowing accent colors matching the robot and desk themes */
  --retro-orange: #EC4899;   /* Glowing Magenta/Pink */
  --retro-green: #10B981;    /* Glowing Emerald Green */
  --retro-amber: #F59E0B;    /* Glowing Amber/Yellow */
  --retro-blue: #3B82F6;     /* Glowing Cyber Blue */
  --retro-purple: #A855F7;   /* Glowing Violet */
}

* {
  box-sizing: border-box;
  margin: 0;
  padding: 0;
}

body {
  background-color: var(--bg-color);
  color: var(--text-primary);
  font-family: 'Inter', sans-serif;
  overflow-x: hidden;
  position: relative;
  line-height: 1.5;
}

/* Soft Aurora background container */
.aurora-bg {
  position: fixed;
  top: 0;
  left: 0;
  width: 100vw;
  height: 100vh;
  background-color: var(--bg-color);
  overflow: hidden;
  z-index: -10;
  pointer-events: none;
}

.aurora-blob {
  position: absolute;
  border-radius: 50%;
  filter: blur(120px);
  opacity: 0.18;
  mix-blend-mode: screen;
}

.aurora-blob-1 {
  width: 65vw;
  height: 65vw;
  background: radial-gradient(circle, var(--retro-blue) 0%, transparent 70%);
  top: -15%;
  left: -15%;
  animation: drift 25s infinite alternate ease-in-out;
}

.aurora-blob-2 {
  width: 65vw;
  height: 65vw;
  background: radial-gradient(circle, var(--retro-orange) 0%, transparent 70%);
  bottom: -15%;
  right: -15%;
  animation: drift-reverse 30s infinite alternate ease-in-out;
}

.aurora-blob-3 {
  width: 50vw;
  height: 50vw;
  background: radial-gradient(circle, var(--retro-purple) 0%, transparent 70%);
  top: 25%;
  left: 25%;
  animation: drift 35s infinite alternate ease-in-out;
}

@keyframes drift {
  0% { transform: translate(0px, 0px) scale(1); }
  50% { transform: translate(60px, 40px) scale(1.1); }
  100% { transform: translate(-40px, 80px) scale(0.9); }
}

@keyframes drift-reverse {
  0% { transform: translate(0px, 0px) scale(1); }
  50% { transform: translate(-50px, 60px) scale(0.95); }
  100% { transform: translate(70px, -40px) scale(1.15); }
}

/* Retro space grid back drop */
.retro-grid {
  background-size: 30px 30px;
  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);
}

/* Custom Typography */
h1, h2, h3, .brand-font {
  font-family: 'Syne', sans-serif;
  font-weight: 800;
  text-transform: uppercase;
  letter-spacing: -0.03em;
  color: #FFFFFF;
}

.mono-title {
  font-family: 'Space Grotesk', sans-serif;
  font-weight: 700;
}

code, pre, .code-font {
  font-family: 'JetBrains Mono', monospace;
}

/* Custom Minimal Trailing Cursor */
.custom-cursor {
  position: fixed;
  top: 0;
  left: 0;
  width: 22px;
  height: 22px;
  border: 1.5px solid var(--retro-purple);
  background-color: rgba(168, 85, 247, 0.08);
  border-radius: 50%;
  pointer-events: none;
  z-index: 99990;
  transform: translate(-50%, -50%);
  transition: width 0.15s ease, height 0.15s ease, background-color 0.15s ease, border-color 0.15s ease;
  box-shadow: 0 0 10px rgba(168, 85, 247, 0.2);
}

.custom-cursor-dot {
  display: none;
}

/* Hover States for Trailing Cursor */
.hovering .custom-cursor {
  width: 36px;
  height: 36px;
  border-color: var(--retro-orange);
  background-color: rgba(236, 72, 153, 0.1);
  box-shadow: 0 0 15px rgba(236, 72, 153, 0.3);
}

.hovering-blue .custom-cursor {
  width: 36px;
  height: 36px;
  border-color: var(--retro-blue);
  background-color: rgba(59, 130, 246, 0.1);
  box-shadow: 0 0 15px rgba(59, 130, 246, 0.3);
}

/* Glassmorphic Cards */
.brutalist-card {
  position: relative;
  background: var(--panel-bg);
  backdrop-filter: blur(14px);
  -webkit-backdrop-filter: blur(14px);
  border: 2px solid var(--border-color);
  border-radius: 0px;
  padding: 24px;
  box-shadow: 6px 6px 0px 0px rgba(168, 85, 247, 0.25);
  transition: transform 0.1s ease, box-shadow 0.1s ease, border-color 0.1s ease;
  transform: translate3d(0, 0, 0);
  backface-visibility: hidden;
  -webkit-backface-visibility: hidden;
}

.brutalist-card:hover {
  transform: translate(-3px, -3px);
  box-shadow: 9px 9px 0px 0px rgba(168, 85, 247, 0.35);
  border-color: rgba(255, 255, 255, 0.3);
}

.brutalist-card.blue-card {
  box-shadow: 6px 6px 0px 0px rgba(59, 130, 246, 0.25);
}
.brutalist-card.blue-card:hover {
  box-shadow: 9px 9px 0px 0px rgba(59, 130, 246, 0.35);
}

.brutalist-card.green-card {
  box-shadow: 6px 6px 0px 0px rgba(16, 185, 129, 0.25);
}
.brutalist-card.green-card:hover {
  box-shadow: 9px 9px 0px 0px rgba(16, 185, 129, 0.35);
}

.brutalist-card.amber-card {
  box-shadow: 6px 6px 0px 0px rgba(245, 158, 11, 0.25);
}
.brutalist-card.amber-card:hover {
  box-shadow: 9px 9px 0px 0px rgba(245, 158, 11, 0.35);
}

.brutalist-card.orange-card {
  box-shadow: 6px 6px 0px 0px rgba(236, 72, 153, 0.25);
}
.brutalist-card.orange-card:hover {
  box-shadow: 9px 9px 0px 0px rgba(236, 72, 153, 0.35);
}

/* Glassmorphic Glowing Buttons */
.brutalist-btn {
  background: rgba(255, 255, 255, 0.04);
  backdrop-filter: blur(8px);
  color: #FFFFFF;
  border: 2px solid rgba(255, 255, 255, 0.2);
  padding: 12px 20px;
  border-radius: 0px;
  font-family: 'Space Grotesk', sans-serif;
  font-weight: 700;
  font-size: 0.75rem;
  letter-spacing: 0.05em;
  box-shadow: 4px 4px 0px 0px rgba(255, 255, 255, 0.1);
  transition: all 0.1s ease;
  text-transform: uppercase;
}

.brutalist-btn:hover {
  transform: translate(-2px, -2px);
  box-shadow: 6px 6px 0px 0px rgba(168, 85, 247, 0.4);
  background: var(--retro-purple);
  border-color: var(--retro-purple);
  color: #FFFFFF;
}

.brutalist-btn:active {
  transform: translate(2px, 2px);
  box-shadow: 2px 2px 0px 0px rgba(255, 255, 255, 0.1);
}

.brutalist-btn.blue-btn:hover {
  background: var(--retro-blue);
  border-color: var(--retro-blue);
  box-shadow: 6px 6px 0px 0px rgba(59, 130, 246, 0.4);
}

.brutalist-btn.green-btn:hover {
  background: var(--retro-green);
  border-color: var(--retro-green);
  box-shadow: 6px 6px 0px 0px rgba(16, 185, 129, 0.4);
}

.brutalist-btn.amber-btn:hover {
  background: var(--retro-amber);
  border-color: var(--retro-amber);
  box-shadow: 6px 6px 0px 0px rgba(245, 158, 11, 0.4);
}

.brutalist-btn.orange-btn:hover {
  background: var(--retro-orange);
  border-color: var(--retro-orange);
  box-shadow: 6px 6px 0px 0px rgba(236, 72, 153, 0.4);
}

/* Custom Scrollbar */
::-webkit-scrollbar {
  width: 10px;
}
::-webkit-scrollbar-track {
  background: var(--bg-color);
}
::-webkit-scrollbar-thumb {
  background: rgba(255, 255, 255, 0.2);
  border: 3px solid var(--bg-color);
}
::-webkit-scrollbar-thumb:hover {
  background: var(--retro-purple);
}

/* Telemetry Terminal Output Block */
.code-container {
  background-color: rgba(6, 4, 15, 0.6);
  backdrop-filter: blur(10px);
  border: 2px solid var(--border-color);
  border-radius: 0px;
  padding: 20px;
  overflow-x: auto;
  color: #E2E8F0;
  box-shadow: 4px 4px 0px 0px rgba(168, 85, 247, 0.25);
  position: relative;
}

.code-container::before {
  content: "FIRMWARE SOURCE";
  position: absolute;
  top: -10px;
  left: 10px;
  background: var(--bg-color);
  padding: 0 6px;
  font-family: 'Space Grotesk', sans-serif;
  font-size: 0.6rem;
  font-weight: 700;
  color: var(--retro-purple);
  border: 1.5px solid var(--border-color);
}

/* Click Spark Canvas */
#spark-canvas {
  position: fixed;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  pointer-events: none;
  z-index: 9998;
}

/* Main 3D Canvas container */
#canvas-container {
  width: 100%;
  height: 60vh;
  position: relative;
}

.canvas-loading {
  position: absolute;
  top: 50%;
  left: 50%;
  transform: translate(-50%, -50%);
  font-family: 'Space Grotesk', sans-serif;
  font-weight: 700;
  font-size: 0.75rem;
  letter-spacing: 0.1em;
  color: var(--text-muted);
}

/* Interactive elements */
.interactive-slider {
  -webkit-appearance: none;
  width: 100%;
  height: 8px;
  background: rgba(255, 255, 255, 0.05);
  outline: none;
  border: 1.5px solid rgba(255, 255, 255, 0.2);
}

.interactive-slider::-webkit-slider-thumb {
  -webkit-appearance: none;
  appearance: none;
  width: 18px;
  height: 18px;
  background: var(--retro-purple);
  border: 1.5px solid rgba(255, 255, 255, 0.5);
  cursor: none !important;
}

.interactive-slider.blue-slider::-webkit-slider-thumb {
  background: var(--retro-blue);
}

.interactive-slider.amber-slider::-webkit-slider-thumb {
  background: var(--retro-amber);
}

/* Highlight / Alert Banner boxes */
.alert-banner {
  padding: 16px;
  border: 2px solid var(--border-color);
  background-color: var(--panel-bg);
  box-shadow: 4px 4px 0px 0px rgba(168, 85, 247, 0.25);
  font-family: 'Space Grotesk', sans-serif;
}

/* Preloader / Bootloader Overlay */
#preloader {
  position: fixed;
  inset: 0;
  background-color: #080710;
  z-index: 99999;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  font-family: 'JetBrains Mono', monospace;
  color: #10B981; /* neon green */
  padding: 20px;
}

.terminal-box {
  width: 100%;
  max-width: 620px;
  background-color: rgba(12, 10, 24, 0.95);
  border: 2px solid rgba(16, 185, 129, 0.3);
  padding: 24px;
  box-shadow: 0 0 20px rgba(16, 185, 129, 0.15);
  display: flex;
  flex-direction: column;
  gap: 12px;
}

.terminal-line {
  font-size: 11px;
  line-height: 1.6;
  white-space: pre-wrap;
  color: #34D399;
}

.terminal-cursor {
  display: inline-block;
  width: 8px;
  height: 14px;
  background-color: #10B981;
  animation: blink 0.8s infinite;
  vertical-align: middle;
  margin-left: 4px;
}

@keyframes blink {
  0%, 100% { opacity: 0; }
  50% { opacity: 1; }
}

.progress-bar-container {
  width: 100%;
  height: 6px;
  background-color: rgba(255, 255, 255, 0.05);
  border: 1px solid rgba(16, 185, 129, 0.2);
  margin-top: 12px;
  overflow: hidden;
  position: relative;
}

.progress-bar-fill {
  height: 100%;
  width: 0%;
  background-color: #10B981;
  box-shadow: 0 0 8px #10B981;
}
