/* Computational Thinking Brain Gaming Platform - Electric Gen-Z GameZone Theme */
@import url('https://fonts.googleapis.com/css2?family=Fredoka:wght@500;600;700&family=Outfit:wght@400;500;600;700;800;900&family=Space+Grotesk:wght@500;700&display=swap');

:root {
  --font-heading: 'Outfit', -apple-system, sans-serif;
  --font-brand: 'Fredoka', cursive, sans-serif;
  --font-mono: 'Space Grotesk', monospace;

  /* Neon Gen-Z Electric Palette */
  --neon-cyan: #06B6D4;
  --neon-lime: #10B981;
  --neon-pink: #EC4899;
  --neon-purple: #8B5CF6;
  --neon-yellow: #F59E0B;
  --electric-blue: #3B82F6;

  /* Cyber Dark & Glass Foundations */
  --bg-dark: #0A0F1D;
  --bg-card: rgba(15, 23, 42, 0.75);
  --border-neon: rgba(99, 102, 241, 0.3);

  /* CT Pillars */
  --ct-decomp: #6366F1;
  --ct-pattern: #F59E0B;
  --ct-abstract: #A855F7;
  --ct-algo: #10B981;
}

* {
  box-sizing: border-box;
}

body {
  font-family: var(--font-heading);
  background-color: #090D1A;
  background-image: 
    radial-gradient(at 10% 15%, rgba(99, 102, 241, 0.22) 0px, transparent 50%),
    radial-gradient(at 90% 10%, rgba(236, 72, 153, 0.2) 0px, transparent 50%),
    radial-gradient(at 50% 50%, rgba(16, 185, 129, 0.12) 0px, transparent 50%),
    radial-gradient(at 80% 85%, rgba(139, 92, 246, 0.2) 0px, transparent 50%),
    radial-gradient(at 20% 90%, rgba(6, 182, 212, 0.18) 0px, transparent 50%);
  background-attachment: fixed;
  color: #F1F5F9;
  min-height: 100vh;
  margin: 0;
  padding: 0;
  -webkit-font-smoothing: antialiased;
}

h1, h2, h3, h4, h5, h6 {
  font-family: var(--font-heading);
  letter-spacing: -0.02em;
}

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

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

/* Fluidic Neon Ambient Lights */
.ambient-glow-cyan {
  filter: blur(80px);
  background: rgba(6, 182, 212, 0.25);
  border-radius: 9999px;
  pointer-events: none;
}
.ambient-glow-pink {
  filter: blur(80px);
  background: rgba(236, 72, 153, 0.25);
  border-radius: 9999px;
  pointer-events: none;
}

/* Fluid Glass Panels with Electric Border */
.glass-panel {
  background: rgba(15, 23, 42, 0.8);
  backdrop-filter: blur(16px);
  -webkit-backdrop-filter: blur(16px);
  border: 1px solid rgba(255, 255, 255, 0.12);
  box-shadow: 0 10px 30px -10px rgba(0, 0, 0, 0.5), inset 0 1px 0 rgba(255, 255, 255, 0.1);
}

.glass-card {
  background: rgba(17, 24, 39, 0.85);
  backdrop-filter: blur(12px);
  -webkit-backdrop-filter: blur(12px);
  border: 1px solid rgba(255, 255, 255, 0.08);
  border-radius: 1.5rem;
  transition: all 0.3s cubic-bezier(0.34, 1.56, 0.64, 1);
  box-shadow: 0 4px 20px -2px rgba(0, 0, 0, 0.4);
  position: relative;
  overflow: hidden;
}

.glass-card::before {
  content: '';
  position: absolute;
  top: 0;
  left: 0;
  right: 0;
  height: 2px;
  background: linear-gradient(90deg, transparent, rgba(99, 102, 241, 0.6), transparent);
  opacity: 0;
  transition: opacity 0.3s ease;
}

.glass-card:hover {
  transform: translateY(-8px) scale(1.02);
  border-color: rgba(99, 102, 241, 0.5);
  box-shadow: 0 20px 35px -5px rgba(99, 102, 241, 0.25), 0 0 15px rgba(99, 102, 241, 0.15);
}

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

/* Tactile Gen-Z Cyber Gaming Buttons */
.btn-kid {
  font-family: var(--font-heading);
  font-size: 0.95rem;
  font-weight: 700;
  letter-spacing: 0.02em;
  padding: 0.7rem 1.4rem;
  border-radius: 9999px;
  border: none;
  cursor: pointer;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 0.5rem;
  transition: all 0.18s cubic-bezier(0.34, 1.56, 0.64, 1);
  text-decoration: none;
  position: relative;
  user-select: none;
}

.btn-kid:active {
  transform: translateY(3px) scale(0.98);
}

.btn-primary-kid {
  background: linear-gradient(135deg, #6366F1 0%, #4F46E5 100%);
  color: white;
  box-shadow: 0 4px 0 #3730A3, 0 0 15px rgba(99, 102, 241, 0.4);
}
.btn-primary-kid:hover {
  filter: brightness(1.12);
  box-shadow: 0 4px 0 #3730A3, 0 0 22px rgba(99, 102, 241, 0.6);
}

.btn-success-kid {
  background: linear-gradient(135deg, #10B981 0%, #059669 100%);
  color: white;
  box-shadow: 0 4px 0 #047857, 0 0 15px rgba(16, 185, 129, 0.4);
}
.btn-success-kid:hover {
  filter: brightness(1.12);
  box-shadow: 0 4px 0 #047857, 0 0 22px rgba(16, 185, 129, 0.6);
}

.btn-amber-kid {
  background: linear-gradient(135deg, #F59E0B 0%, #D97706 100%);
  color: #1E1B4B;
  box-shadow: 0 4px 0 #B45309, 0 0 15px rgba(245, 158, 11, 0.4);
}
.btn-amber-kid:hover {
  filter: brightness(1.12);
  box-shadow: 0 4px 0 #B45309, 0 0 22px rgba(245, 158, 11, 0.6);
}

.btn-secondary-kid {
  background: linear-gradient(135deg, #EC4899 0%, #DB2777 100%);
  color: white;
  box-shadow: 0 4px 0 #BE185D, 0 0 15px rgba(236, 72, 153, 0.4);
}
.btn-secondary-kid:hover {
  filter: brightness(1.12);
  box-shadow: 0 4px 0 #BE185D, 0 0 22px rgba(236, 72, 153, 0.6);
}

.btn-cyan-kid {
  background: linear-gradient(135deg, #06B6D4 0%, #0891B2 100%);
  color: #0F172A;
  box-shadow: 0 4px 0 #0E7490, 0 0 15px rgba(6, 182, 212, 0.4);
}
.btn-cyan-kid:hover {
  filter: brightness(1.12);
  box-shadow: 0 4px 0 #0E7490, 0 0 22px rgba(6, 182, 212, 0.6);
}

/* Glowing CT Concept Badges */
.badge-decomp {
  background: rgba(99, 102, 241, 0.2);
  color: #818CF8;
  border: 1px solid rgba(99, 102, 241, 0.4);
  box-shadow: 0 0 10px rgba(99, 102, 241, 0.2);
}
.badge-pattern {
  background: rgba(245, 158, 11, 0.2);
  color: #FBBF24;
  border: 1px solid rgba(245, 158, 11, 0.4);
  box-shadow: 0 0 10px rgba(245, 158, 11, 0.2);
}
.badge-abstract {
  background: rgba(168, 85, 247, 0.2);
  color: #C084FC;
  border: 1px solid rgba(168, 85, 247, 0.4);
  box-shadow: 0 0 10px rgba(168, 85, 247, 0.2);
}
.badge-algo {
  background: rgba(16, 185, 129, 0.2);
  color: #34D399;
  border: 1px solid rgba(16, 185, 129, 0.4);
  box-shadow: 0 0 10px rgba(16, 185, 129, 0.2);
}

/* Cyber Modal */
.modal-overlay {
  position: fixed;
  inset: 0;
  background: rgba(5, 8, 18, 0.85);
  backdrop-filter: blur(12px);
  -webkit-backdrop-filter: blur(12px);
  display: flex;
  align-items: center;
  justify-content: center;
  z-index: 9999;
  padding: 1rem;
  opacity: 0;
  pointer-events: none;
  transition: opacity 0.25s ease-out;
}

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

.modal-box {
  background: #0F172A;
  border-radius: 2rem;
  max-width: 520px;
  width: 100%;
  padding: 2.2rem;
  box-shadow: 0 25px 60px -15px rgba(0, 0, 0, 0.8), 0 0 30px rgba(99, 102, 241, 0.25);
  transform: scale(0.9) translateY(20px);
  transition: transform 0.3s cubic-bezier(0.34, 1.56, 0.64, 1);
  border: 2px solid rgba(99, 102, 241, 0.4);
  color: #F8FAFC;
}

.modal-overlay.active .modal-box {
  transform: scale(1) translateY(0);
}

/* Animations */
@keyframes bouncePop {
  0% { transform: scale(0.85); opacity: 0; }
  60% { transform: scale(1.04); }
  100% { transform: scale(1); opacity: 1; }
}

@keyframes pulseGlow {
  0%, 100% { transform: scale(1); box-shadow: 0 0 0 0 rgba(99, 102, 241, 0.5); }
  50% { transform: scale(1.03); box-shadow: 0 0 25px 8px rgba(99, 102, 241, 0.35); }
}

@keyframes laserShine {
  0% { background-position: -200% 0; }
  100% { background-position: 200% 0; }
}

.animate-pop {
  animation: bouncePop 0.4s cubic-bezier(0.34, 1.56, 0.64, 1) forwards;
}

.pulse-glow {
  animation: pulseGlow 2.5s infinite;
}

/* Custom Neon Laser Scrollbars */
::-webkit-scrollbar {
  width: 10px;
  height: 10px;
}
::-webkit-scrollbar-track {
  background: rgba(15, 23, 42, 0.8);
  border-radius: 9999px;
  border: 1px solid rgba(255, 255, 255, 0.05);
}
::-webkit-scrollbar-thumb {
  background: linear-gradient(180deg, #6366F1 0%, #EC4899 100%);
  border-radius: 9999px;
  border: 2px solid #0F172A;
  box-shadow: 0 0 8px rgba(99, 102, 241, 0.5);
}
::-webkit-scrollbar-thumb:hover {
  background: linear-gradient(180deg, #818CF8 0%, #F472B6 100%);
  box-shadow: 0 0 14px rgba(236, 72, 153, 0.8);
}

/* High-visibility code queue scrollbar */
.program-scroll-box {
  scrollbar-width: thin;
  scrollbar-color: #6366F1 #1E293B;
  overflow-y: scroll !important;
}

/* Section 1 Kids Practice Cards & Thumbnails */
.gz-game-thumb {
  position: relative;
  width: 100%;
  aspect-ratio: 16 / 9;
  border-radius: 1.25rem;
  overflow: hidden;
  background-color: #0b0f19;
  border: 1px solid rgba(255, 255, 255, 0.08);
}
.gz-thumb-img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  transition: transform 0.4s cubic-bezier(0.165, 0.84, 0.44, 1);
}
.glass-card:hover .gz-thumb-img {
  transform: scale(1.08);
}
.gz-thumb-overlay {
  position: absolute;
  inset: 0;
  background: linear-gradient(to top, rgba(10, 15, 29, 0.9) 0%, rgba(10, 15, 29, 0.3) 50%, transparent 100%);
  display: flex;
  align-items: center;
  justify-content: center;
  opacity: 0;
  transition: opacity 0.3s ease;
}
.glass-card:hover .gz-thumb-overlay {
  opacity: 1;
}
.gz-play-btn {
  width: 50px;
  height: 50px;
  border-radius: 9999px;
  background: linear-gradient(135deg, #06B6D4, #6366F1);
  color: #ffffff;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 1.5rem;
  box-shadow: 0 0 20px rgba(6, 182, 212, 0.6);
  transform: scale(0.8);
  transition: transform 0.3s cubic-bezier(0.175, 0.885, 0.32, 1.275);
}
.glass-card:hover .gz-play-btn {
  transform: scale(1);
}
