:root {
  /* Neonpunk Color Palette */
  --neon-pink: #ff007f;
  --neon-pink-dark: #b30059;
  --neon-pink-glow: rgba(255, 0, 127, 0.4);
  
  --neon-cyan: #00e5ff;
  --neon-cyan-dark: #0099ab;
  --neon-cyan-glow: rgba(0, 229, 255, 0.4);
  
  --neon-yellow: #ffcc00;
  --neon-yellow-dark: #b38f00;
  --neon-yellow-glow: rgba(255, 204, 0, 0.4);
  
  --dark-bg: #07060b;
  --panel-bg: rgba(15, 12, 25, 0.85);
  --panel-bg-solid: #0f0c19;
  --text-primary: #ffffff;
  --text-muted: #8b8a9f;
  
  --font-title: 'Outfit', sans-serif;
  --font-body: 'Inter', sans-serif;
  --font-mono: 'Fira Code', monospace;
  
  --border-radius-sm: 6px;
  --border-radius-md: 12px;
  --border-radius-lg: 20px;
}

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

html {
  scroll-behavior: smooth;
  background-color: var(--dark-bg);
  color: var(--text-primary);
  font-family: var(--font-body);
  overflow-x: hidden;
}

body {
  position: relative;
  min-height: 100vh;
  display: flex;
  flex-direction: column;
}

a {
  text-decoration: none;
  color: inherit;
}

/* Base Neon Utilities */
.text-pink { color: var(--neon-pink); text-shadow: 0 0 8px var(--neon-pink-glow); }
.text-cyan { color: var(--neon-cyan); text-shadow: 0 0 8px var(--neon-cyan-glow); }
.text-yellow { color: var(--neon-yellow); text-shadow: 0 0 8px var(--neon-yellow-glow); }
.cyan-accent { color: var(--neon-cyan); }

/* Background Sci-Fi Grid Overlay */
.cyber-grid {
  position: fixed;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  z-index: -2;
  background-image: 
    linear-gradient(rgba(255, 0, 127, 0.05) 1px, transparent 1px),
    linear-gradient(90deg, rgba(255, 0, 127, 0.05) 1px, transparent 1px);
  background-size: 40px 40px;
  background-position: center;
  pointer-events: none;
}

.cyber-grid::before {
  content: '';
  position: absolute;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  background: radial-gradient(circle, transparent 30%, var(--dark-bg) 85%);
  pointer-events: none;
}

/* CRT Scanlines Overlay */
.scanlines {
  position: fixed;
  top: 0;
  left: 0;
  width: 100vw;
  height: 100vh;
  background: linear-gradient(
    rgba(18, 16, 16, 0) 50%, 
    rgba(0, 0, 0, 0.15) 50%
  );
  background-size: 100% 4px;
  z-index: 1000;
  pointer-events: none;
}

/* Header */
.hero-header {
  text-align: center;
  padding: 60px 20px 40px 20px;
  position: relative;
  z-index: 10;
}

.logo-container {
  display: inline-block;
  position: relative;
  margin-bottom: 24px;
}

.logo-neon-ring {
  width: 160px;
  height: 160px;
  border-radius: 50%;
  padding: 6px;
  background: linear-gradient(45deg, var(--neon-pink), var(--neon-yellow), var(--neon-cyan));
  box-shadow: 
    0 0 20px var(--neon-pink-glow),
    0 0 35px var(--neon-cyan-glow);
  display: flex;
  justify-content: center;
  align-items: center;
  animation: rotateGlow 8s linear infinite;
}

#good-gary-logo-img {
  width: 100%;
  height: 100%;
  border-radius: 50%;
  object-fit: cover;
  border: 4px solid var(--dark-bg);
  animation: unrotate 8s linear infinite;
}

@keyframes rotateGlow {
  0% { transform: rotate(0deg); }
  100% { transform: rotate(360deg); }
}

@keyframes unrotate {
  0% { transform: rotate(0deg); }
  100% { transform: rotate(-360deg); }
}

.glow-title-yellow {
  font-family: var(--font-title);
  font-weight: 900;
  font-size: 3.5rem;
  letter-spacing: 2px;
  color: var(--neon-yellow);
  text-shadow: 
    0 0 10px rgba(255, 204, 0, 0.4),
    0 0 25px rgba(255, 204, 0, 0.2);
  margin-bottom: 8px;
}

.hero-tagline {
  font-family: var(--font-mono);
  font-weight: 600;
  font-size: 1.1rem;
  letter-spacing: 4px;
  color: var(--neon-cyan);
  text-shadow: 0 0 10px var(--neon-cyan-glow);
}

/* Audio control toggle (Fixed Top Right) */
.audio-control-wrapper {
  position: fixed;
  top: 20px;
  right: 20px;
  z-index: 1001;
}

/* Tactile 3D Buttons */
.btn-3d {
  position: relative;
  border: none;
  background: transparent;
  padding: 0;
  cursor: pointer;
  outline-offset: 4px;
  transition: filter 250ms;
  user-select: none;
  font-family: var(--font-mono);
}

.btn-3d-top {
  display: block;
  padding: 12px 24px;
  border-radius: var(--border-radius-sm);
  font-weight: 700;
  font-size: 0.95rem;
  text-transform: uppercase;
  letter-spacing: 1px;
  transform: translateY(-6px);
  transition: transform 600ms cubic-bezier(.3, .7, .4, 1);
}

.btn-3d:hover {
  filter: brightness(1.15);
}

.btn-3d:hover .btn-3d-top {
  transform: translateY(-8px);
  transition: transform 250ms cubic-bezier(.3, .7, .4, 1);
}

.btn-3d:active .btn-3d-top {
  transform: translateY(-2px);
  transition: transform 34ms;
}

/* Button Colors */
.btn-pink {
  background: var(--neon-pink-dark);
  border-radius: var(--border-radius-sm);
}
.btn-pink .btn-3d-top {
  background: var(--neon-pink);
  color: #fff;
  box-shadow: 0 0 15px var(--neon-pink-glow);
}

.btn-cyan {
  background: var(--neon-cyan-dark);
  border-radius: var(--border-radius-sm);
}
.btn-cyan .btn-3d-top {
  background: var(--neon-cyan);
  color: #000;
  box-shadow: 0 0 15px var(--neon-cyan-glow);
}

.btn-yellow {
  background: var(--neon-yellow-dark);
  border-radius: var(--border-radius-sm);
}
.btn-yellow .btn-3d-top {
  background: var(--neon-yellow);
  color: #000;
  box-shadow: 0 0 15px var(--neon-yellow-glow);
}

/* Large and round button overrides */
.btn-large .btn-3d-top {
  padding: 18px 36px;
  font-size: 1.1rem;
  letter-spacing: 2px;
}

.btn-sm .btn-3d-top {
  padding: 8px 14px;
  font-size: 0.75rem;
}

.btn-round {
  border-radius: 50%;
  background: var(--neon-pink-dark);
}
.btn-round .btn-3d-top {
  border-radius: 50%;
  width: 70px;
  height: 70px;
  display: flex;
  justify-content: center;
  align-items: center;
  padding: 0;
  font-size: 0.8rem;
  transform: translateY(-5px);
}
.btn-round:hover .btn-3d-top {
  transform: translateY(-7px);
}
.btn-round:active .btn-3d-top {
  transform: translateY(-1px);
}

/* Button disabled state */
.btn-3d.disabled {
  pointer-events: none;
  filter: grayscale(1);
  opacity: 0.5;
}

/* Neon Boxes & Outlines */
.neon-box-pink, .neon-box-blue, .neon-box-yellow {
  background: var(--panel-bg);
  backdrop-filter: blur(8px);
  border-radius: var(--border-radius-md);
  padding: 30px;
  position: relative;
}

.neon-box-pink {
  border: 2px solid var(--neon-pink);
  box-shadow: 
    0 0 15px rgba(255, 0, 127, 0.25),
    inset 0 0 10px rgba(255, 0, 127, 0.1);
}

.neon-box-blue {
  border: 2px solid var(--neon-cyan);
  box-shadow: 
    0 0 15px rgba(0, 229, 255, 0.25),
    inset 0 0 10px rgba(0, 229, 255, 0.1);
}

.neon-box-yellow {
  border: 2px solid var(--neon-yellow);
  box-shadow: 
    0 0 15px rgba(255, 204, 0, 0.25),
    inset 0 0 10px rgba(255, 204, 0, 0.1);
}

.neon-tag {
  position: absolute;
  top: -12px;
  left: 24px;
  background: var(--dark-bg);
  padding: 2px 10px;
  font-family: var(--font-mono);
  font-size: 0.8rem;
  font-weight: 600;
  border-left: 2px solid currentColor;
  border-right: 2px solid currentColor;
}

/* Main Layout Grid */
.main-content {
  max-width: 1000px;
  margin: 0 auto;
  padding: 0 20px 80px 20px;
  display: flex;
  flex-direction: column;
  gap: 60px;
  width: 100%;
}

.section-title {
  font-family: var(--font-title);
  font-weight: 900;
  font-size: 2.2rem;
  letter-spacing: 2px;
  margin-bottom: 24px;
  text-transform: uppercase;
}

/* Brand Story */
.story-content {
  line-height: 1.7;
  font-size: 1.05rem;
  display: flex;
  flex-direction: column;
  gap: 16px;
  font-weight: 300;
}

.story-content strong {
  font-weight: 600;
}

.highlight-text {
  font-family: var(--font-title);
  font-size: 1.25rem;
  font-weight: 700;
  font-style: italic;
  margin-top: 10px;
  border-left: 3px solid var(--neon-yellow);
  padding-left: 16px;
}

/* Arcade Cabinet Component */
.arcade-cabinet {
  border: 8px solid #1a1a2e;
  border-radius: var(--border-radius-lg);
  background: #09080e;
  overflow: hidden;
  box-shadow: 
    0 20px 50px rgba(0, 0, 0, 0.6),
    0 0 20px rgba(0, 229, 255, 0.2),
    0 0 40px rgba(255, 0, 127, 0.2);
  transition: all 0.5s cubic-bezier(0.175, 0.885, 0.32, 1.275);
  position: relative;
  display: flex;
  flex-direction: column;
}

.arcade-cabinet.collapsed {
  height: 320px;
  border-color: #221a36;
}

.arcade-cabinet.expanded {
  height: auto;
  min-height: 600px;
  border-color: #00e5ff;
  box-shadow: 
    0 25px 60px rgba(0, 0, 0, 0.8),
    0 0 35px var(--neon-cyan-glow),
    0 0 50px var(--neon-pink-glow);
}

/* CRT Screen Effect */
.crt-screen {
  background: #030206;
  position: relative;
  overflow: hidden;
  display: flex;
  flex-direction: column;
  justify-content: center;
  align-items: center;
  box-shadow: inset 0 0 60px rgba(0, 0, 0, 1);
  height: 100%;
}

.crt-screen::before {
  content: " ";
  display: block;
  position: absolute;
  top: 0; left: 0; bottom: 0; right: 0;
  background: radial-gradient(circle, rgba(18, 16, 16, 0) 60%, rgba(0, 0, 0, 0.6) 100%);
  z-index: 5;
  pointer-events: none;
}

/* Cover screen (when game is closed) */
.arcade-cover {
  width: 100%;
  height: 100%;
  flex: 1;
}

.cover-screen {
  padding: 40px 20px;
  gap: 20px;
  text-align: center;
}

.retro-glitch-text {
  font-family: var(--font-title);
  font-size: 2.8rem;
  font-weight: 900;
  letter-spacing: 4px;
  position: relative;
  text-shadow: 
    0 0 10px var(--neon-pink-glow),
    2px 2px 0px var(--neon-cyan),
    -2px -2px 0px var(--neon-yellow);
}

.arcade-subtitle {
  font-family: var(--font-mono);
  font-size: 0.9rem;
  letter-spacing: 2px;
}

.arcade-status {
  font-family: var(--font-mono);
  font-weight: 600;
  font-size: 0.95rem;
}

.animate-blink {
  animation: flash 1.2s infinite;
}

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

/* Main Playing Frame */
.arcade-main-play {
  display: none; /* Shown dynamically when active */
  flex-direction: column;
  width: 100%;
}

.arcade-marquee {
  background: #12101f;
  border-bottom: 4px solid #1a172e;
  padding: 12px 20px;
  display: flex;
  justify-content: space-between;
  align-items: center;
  text-align: center;
}

.arcade-marquee h3 {
  font-family: var(--font-title);
  font-weight: 800;
  font-size: 1.2rem;
  color: #fff;
  letter-spacing: 3px;
  text-shadow: 0 0 10px var(--neon-pink);
}

.marquee-lights {
  width: 10px;
  height: 10px;
  border-radius: 50%;
  display: inline-block;
}

.pink-lights {
  background: var(--neon-pink);
  box-shadow: 0 0 8px var(--neon-pink);
  animation: flash 0.6s infinite alternate;
}

.cyan-lights {
  background: var(--neon-cyan);
  box-shadow: 0 0 8px var(--neon-cyan);
  animation: flash 0.6s infinite alternate-reverse;
}

/* Screen Area */
.arcade-screen-area {
  padding: 15px;
  background: #161426;
  border-bottom: 6px solid #0f0d19;
}

.game-screen {
  border: 4px solid #231f3c;
  border-radius: var(--border-radius-sm);
  aspect-ratio: 2/1;
  width: 100%;
  max-width: 100%;
}

#game-canvas {
  width: 100%;
  height: 100%;
  display: block;
}

/* HUD Overlay on Screen */
#game-overlay-screens {
  position: absolute;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  z-index: 10;
  display: flex;
  justify-content: center;
  align-items: center;
}

.game-hud-panel {
  background: rgba(8, 7, 15, 0.9);
  border: 2px solid var(--neon-cyan);
  box-shadow: 0 0 20px rgba(0, 229, 255, 0.3);
  padding: 24px;
  border-radius: var(--border-radius-md);
  text-align: center;
  max-width: 85%;
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 16px;
}

.game-hud-panel h4 {
  font-family: var(--font-title);
  font-size: 1.6rem;
  font-weight: 800;
  letter-spacing: 2px;
}

.game-hud-panel p {
  font-size: 0.9rem;
}

.mission-selectors {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 12px;
  width: 100%;
  max-width: 440px;
}

.control-tip {
  font-family: var(--font-mono);
  font-size: 0.75rem !important;
}

.score-display {
  font-family: var(--font-mono);
  font-weight: 700;
  font-size: 1.2rem;
}

.hidden {
  display: none !important;
}

/* Arcade Console Dashboard */
.arcade-dashboard {
  background: #1b182d;
  padding: 16px 24px;
  display: grid;
  grid-template-columns: auto 1fr auto;
  align-items: center;
  gap: 20px;
  border-top: 4px solid #282442;
}

.dashboard-joystick-group {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 6px;
}

.joystick-base {
  width: 60px;
  height: 60px;
  background: #110e1e;
  border: 4px solid #2d2847;
  border-radius: 50%;
  position: relative;
}

.joystick-stick {
  width: 24px;
  height: 24px;
  background: var(--neon-cyan);
  border-radius: 50%;
  box-shadow: 0 0 10px var(--neon-cyan);
  position: absolute;
  top: 50%;
  left: 50%;
  transform: translate(-50%, -50%);
  transition: transform 0.1s ease;
}

.dashboard-keytips {
  font-family: var(--font-mono);
  font-size: 0.8rem;
  color: var(--text-muted);
  line-height: 1.6;
  text-align: center;
}

.dashboard-button-group {
  display: flex;
  align-items: center;
  gap: 16px;
}

/* Apps Grid */
.section-subtitle {
  font-family: var(--font-mono);
  font-size: 0.95rem;
  letter-spacing: 2px;
  text-align: center;
  margin-top: -12px;
  margin-bottom: 40px;
}

.apps-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 30px;
}

.app-card {
  display: flex;
  flex-direction: column;
  height: 100%;
}

.app-card-header {
  display: flex;
  align-items: center;
  gap: 16px;
  margin-bottom: 12px;
}

.app-icon {
  font-size: 2rem;
  filter: drop-shadow(0 0 5px rgba(255,255,255,0.2));
}

.app-card h3 {
  font-family: var(--font-title);
  font-weight: 800;
  font-size: 1.4rem;
  letter-spacing: 1px;
}

.app-summary {
  font-weight: 300;
  line-height: 1.6;
  margin-bottom: 20px;
  flex: 1;
}

.app-actions {
  display: flex;
  margin-top: auto;
}

/* Expanding App Details Drawer */
.app-details-drawer {
  display: grid;
  grid-template-rows: 0fr;
  transition: grid-template-rows 400ms cubic-bezier(0.19, 1, 0.22, 1);
  overflow: hidden;
}

.app-details-drawer.expanded {
  grid-template-rows: 1fr;
}

.drawer-inner {
  min-height: 0;
  padding-bottom: 10px;
}

.neon-divider {
  border: 0;
  height: 1px;
  margin: 20px 0;
}

.pink-divider {
  background: linear-gradient(90deg, var(--neon-pink) 30%, transparent 100%);
}

.cyan-divider {
  background: linear-gradient(90deg, var(--neon-cyan) 30%, transparent 100%);
}

.yellow-divider {
  background: linear-gradient(90deg, var(--neon-yellow) 30%, transparent 100%);
}

.app-badge {
  display: inline-block;
  font-family: var(--font-mono);
  font-size: 0.75rem;
  padding: 4px 8px;
  border-radius: var(--border-radius-sm);
  margin-bottom: 16px;
  font-weight: 600;
}

.live-badge {
  background: rgba(0, 229, 255, 0.15);
  border: 1px solid var(--neon-cyan);
  color: var(--neon-cyan);
}

.dev-badge {
  background: rgba(255, 204, 0, 0.15);
  border: 1px solid var(--neon-yellow);
  color: var(--neon-yellow);
}

.drawer-inner ul {
  list-style: none;
  margin-top: 10px;
  margin-bottom: 20px;
}

.drawer-inner li {
  margin-bottom: 8px;
  position: relative;
  padding-left: 20px;
}

.drawer-inner li::before {
  content: "✔";
  position: absolute;
  left: 0;
  top: 1px;
  color: var(--neon-yellow);
}

.mock-device-preview {
  background: #040306;
  border: 1px solid #1f1a30;
  border-radius: var(--border-radius-sm);
  padding: 12px 16px;
  margin-bottom: 20px;
}

.terminal-mock {
  font-family: var(--font-mono);
  font-size: 0.8rem;
  line-height: 1.6;
}

/* Nixie Tube Timer — glowing digit display */
.nixie-digits {
  font-family: var(--font-mono);
  font-size: 1.1rem;
  font-weight: 700;
  color: #ff8c00;
  text-shadow:
    0 0 6px #ff8c00,
    0 0 14px rgba(255, 140, 0, 0.7),
    0 0 30px rgba(255, 80, 0, 0.3);
  animation: nixiePulse 2s ease-in-out infinite;
  letter-spacing: 3px;
}

@keyframes nixiePulse {
  0%, 100% { opacity: 1; text-shadow: 0 0 6px #ff8c00, 0 0 14px rgba(255,140,0,0.7); }
  50%       { opacity: 0.85; text-shadow: 0 0 10px #ff8c00, 0 0 24px rgba(255,140,0,0.9), 0 0 40px rgba(255,60,0,0.4); }
}

.store-button {
  width: 100%;
  text-align: center;
}

/* Contact Terminal Form */
.terminal-container {
  background: rgba(4, 3, 7, 0.9);
  border: 1px solid #231e36;
  border-radius: var(--border-radius-md);
  padding: 24px;
  margin-bottom: 30px;
  box-shadow: inset 0 0 20px rgba(0, 0, 0, 0.8);
}

.terminal-form {
  display: flex;
  flex-direction: column;
  gap: 20px;
}

.terminal-row {
  display: flex;
  flex-direction: column;
  gap: 8px;
}

.term-prompt {
  font-family: var(--font-mono);
  font-size: 0.85rem;
  color: var(--neon-yellow);
  font-weight: 600;
}

.terminal-input {
  background: #0c0a12;
  border: 1px solid #2e284a;
  border-radius: var(--border-radius-sm);
  color: #fff;
  padding: 12px 16px;
  font-family: var(--font-mono);
  font-size: 0.9rem;
  width: 100%;
  outline: none;
  transition: all 0.3s ease;
}

.terminal-input:focus {
  border-color: var(--neon-yellow);
  box-shadow: 0 0 10px var(--neon-yellow-glow);
}

.terminal-input::placeholder {
  color: #55536b;
}

.terminal-submit-wrapper {
  margin-top: 10px;
  display: flex;
}

.terminal-submit-wrapper button {
  width: 100%;
}

/* Socials Dashboard */
.socials-dashboard {
  text-align: center;
  margin-bottom: 40px;
}

.socials-dashboard h3 {
  font-family: var(--font-mono);
  font-size: 1rem;
  letter-spacing: 3px;
  margin-bottom: 20px;
  text-transform: uppercase;
}

.social-icons {
  display: flex;
  justify-content: center;
  gap: 20px;
  flex-wrap: wrap;
}

.social-circle {
  width: 54px;
  height: 54px;
  border-radius: 50% !important;
}

.social-circle .btn-3d-top {
  border-radius: 50% !important;
  width: 100%;
  height: 100%;
  display: flex;
  justify-content: center;
  align-items: center;
  padding: 0;
  font-weight: 900;
  font-size: 1rem;
  font-family: var(--font-title);
  transform: translateY(-4px);
}
.social-circle:hover .btn-3d-top {
  transform: translateY(-6px);
}
.social-circle:active .btn-3d-top {
  transform: translateY(-1px);
}

/* Foods Banner */
.foods-banner-wrapper {
  margin-top: 30px;
  display: flex;
  justify-content: center;
}

.foods-badge {
  width: 100%;
  text-align: center;
}

.foods-badge .btn-3d-top {
  color: #000;
  font-family: var(--font-title);
  font-size: 1rem;
  font-weight: 800;
  letter-spacing: 1px;
}

/* Cyber Footer */
.cyber-footer {
  text-align: center;
  padding: 40px 20px;
  margin-top: auto;
  border-top: 1px solid rgba(255, 0, 127, 0.15);
  background: #06050a;
  position: relative;
  z-index: 10;
}

.cyber-footer p {
  font-family: var(--font-mono);
  font-size: 0.8rem;
  color: var(--text-muted);
  margin-bottom: 8px;
}

.footer-fineprint {
  font-size: 0.75rem !important;
  color: #4a475d !important;
}

/* Responsive Breakpoints */
@media (max-width: 768px) {
  .glow-title-yellow {
    font-size: 2.5rem;
  }
  .hero-tagline {
    font-size: 0.95rem;
    letter-spacing: 2px;
  }
  
  .apps-grid {
    grid-template-columns: 1fr;
    gap: 20px;
  }
  
  .arcade-dashboard {
    grid-template-columns: 1fr;
    justify-items: center;
    gap: 15px;
  }
  
  .dashboard-button-group {
    order: -1;
  }
  
  .dashboard-keytips {
    display: none; /* Hide keyboard tips on mobile layout */
  }
  
  .mission-selectors {
    grid-template-columns: 1fr;
  }
  
  .logo-neon-ring {
    width: 120px;
    height: 120px;
  }
}
