/* ===========================================================
   MindPlay Page Theme — "Cyberium" Extension
   =========================================================== */
body.mindplay-page {
  --accent-color: #00ffcc; /* teal/cyber accent */
  --background-color: #060b10;
  --surface-color: #0b141f;
  --heading-color: #e8f6ff;
  --default-color: #c9d8e3;
  background: radial-gradient(circle at 20% 30%, rgba(0,255,204,0.06) 0%, transparent 60%),
              radial-gradient(circle at 80% 70%, rgba(0,140,255,0.05) 0%, transparent 60%),
              #060b10;
  overflow-x: hidden;
}

/* Glowing section title accent */
body.mindplay-page h1, 
body.mindplay-page h2, 
body.mindplay-page h3 {
  text-shadow: 0 0 8px rgba(0,255,204,0.25);
}

/* Cyber grid background for hero section */
#mindplay-hero {
  position: relative;
  background: linear-gradient(180deg, rgba(0,255,204,0.02) 0%, rgba(0,255,204,0.04) 100%);
  border-bottom: 1px solid rgba(0,255,204,0.15);
  overflow: hidden;
}
#mindplay-hero::before {
  content: "";
  position: absolute;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  background-image: 
    linear-gradient(rgba(0,255,204,0.05) 1px, transparent 1px),
    linear-gradient(90deg, rgba(0,255,204,0.05) 1px, transparent 1px);
  background-size: 40px 40px;
  opacity: 0.2;
  animation: grid-fade 10s linear infinite;
}
@keyframes grid-fade {
  0% { opacity: 0.2; transform: translateY(0px); }
  50% { opacity: 0.3; transform: translateY(10px); }
  100% { opacity: 0.2; transform: translateY(0px); }
}

/* Cards — soft neon hover glow */
body.mindplay-page .card {
  background: rgba(12,18,26,0.85);
  border: 1px solid rgba(0,255,204,0.1);
  box-shadow: 0 0 10px rgba(0,255,204,0.05);
  transition: all 0.3s ease;
}
body.mindplay-page .card:hover {
  border-color: rgba(0,255,204,0.4);
  box-shadow: 0 0 20px rgba(0,255,204,0.15);
  transform: translateY(-4px);
}

/* Accent glow buttons */
body.mindplay-page .btn-outline-light {
  border-color: rgba(0,255,204,0.6);
  color: var(--heading-color);
  transition: all 0.25s ease;
}
body.mindplay-page .btn-outline-light:hover {
  background: var(--accent-color);
  color: #000;
  box-shadow: 0 0 16px rgba(0,255,204,0.4);
}

/* Section separation */
#mindplay-info {
  background: linear-gradient(180deg, rgba(0,255,204,0.03) 0%, rgba(0,140,255,0.05) 100%);
  border-top: 1px solid rgba(0,255,204,0.1);
}

/* Footer accent pulse */
body.mindplay-page #footer {
  background: #070c11;
  border-top: 1px solid rgba(0,255,204,0.15);
}
body.mindplay-page #footer p {
  color: rgba(200,255,255,0.7);
  text-shadow: 0 0 5px rgba(0,255,204,0.2);
}
/* ============================
   MindPlay Font & Typography
   ============================ */
body.mindplay-page {
  --heading-font: "Orbitron", sans-serif;
  --default-font: "Exo 2", "Roboto", sans-serif;
}

body.mindplay-page h1,
body.mindplay-page h2,
body.mindplay-page h3 {
  font-family: var(--heading-font);
  letter-spacing: 1.5px;
  text-transform: uppercase;
}

body.mindplay-page p,
body.mindplay-page a,
body.mindplay-page button {
  font-family: var(--default-font);
}
.mindplay-terminal-text {
  font-family: "JetBrains Mono", monospace;
  letter-spacing: 0.5px;
  color: #00ffcc;
  text-shadow: 0 0 4px rgba(0,255,204,0.4);
}
/* Footer vertical alignment fix */
body.mindplay-page #footer {
  margin-top: 60px;   /* space above footer */
  padding-top: 25px;  /* consistent top padding inside footer */
  padding-bottom: 25px;
}


/* =========================================================
   THEMED CYBER STYLES — SPLIT VARIANTS
   ========================================================= */

/* === Typing Simulator (Green Cyber Theme) === */
.typing-simulator .cyber-card {
  background: radial-gradient(circle at 30% 30%, rgba(99,255,93,0.05), transparent 80%), #0b0f0c;
  border: 1px solid rgba(99,255,93,0.2);
  box-shadow: 0 0 15px rgba(99,255,93,0.15), inset 0 0 20px rgba(0,255,200,0.05);
}

.typing-simulator .text-cyber {
  color: rgba(190, 255, 190, 0.9);
  text-shadow: 0 0 4px rgba(99,255,93,0.2);
}

.typing-simulator .cyber-input {
  background-color: rgba(15, 25, 20, 0.95);
  color: #caffc7;
  border: 1px solid rgba(99,255,93,0.25);
  transition: border-color 0.2s ease, box-shadow 0.2s ease;
}

.typing-simulator .cyber-input::placeholder {
  color: rgba(180, 255, 180, 0.55);
}

.typing-simulator .cyber-input:focus {
  background-color: rgba(25, 35, 25, 1);
  color: #e7ffe5;
  border-color: #63ff5d;
  box-shadow: 0 0 10px rgba(99,255,93,0.3);
}

.typing-simulator .cyber-terminal {
  font-family: "JetBrains Mono", monospace;
  color: #a3ffb0;
  text-shadow: 0 0 4px rgba(99,255,93,0.6);
  min-height: 120px;
  white-space: normal;
  width: 100%;
  overflow-x: hidden;
  text-align: left;
  padding: 12px 16px;
  line-height: 1.45;
}

.typing-simulator #cursor {
  color: #63ff5d;
  animation: blink 1s infinite;
}

.typing-simulator .neon-green {
  color: #63ff5d;
  text-shadow: 0 0 6px rgba(99,255,93,0.4);
}

.typing-simulator .meter-box {
  background: rgba(10, 15, 10, 0.8);
  border: 1px solid rgba(99,255,93,0.25);
  box-shadow: inset 0 0 10px rgba(99,255,93,0.15), 0 0 8px rgba(99,255,93,0.2);
  display: inline-block;
}

.typing-simulator .glow-btn {
  box-shadow: 0 0 10px rgba(99,255,93,0.3);
  transition: all 0.3s ease;
}

.typing-simulator .glow-btn:hover {
  box-shadow: 0 0 20px rgba(99,255,93,0.5);
  transform: translateY(-1px);
}

/* === Typing Test (MindPlay Blue Theme) === */
.typing-test .cyber-card {
  background: radial-gradient(circle at 30% 30%, rgba(93,200,255,0.06), transparent 80%), #0b0f14;
  border: 1px solid rgba(93,200,255,0.25);
  box-shadow: 0 0 15px rgba(93,200,255,0.15), inset 0 0 20px rgba(80,180,255,0.05);
}

.typing-test .text-cyber {
  color: rgba(200, 235, 255, 0.95);
  text-shadow: 0 0 4px rgba(93,200,255,0.3);
}

.typing-test .cyber-input {
  background-color: rgba(10, 20, 30, 0.95);
  color: #cdeeff;
  border: 1px solid rgba(93,200,255,0.25);
  transition: border-color 0.2s ease, box-shadow 0.2s ease;
}

.typing-test .cyber-input::placeholder {
  color: rgba(190, 230, 255, 0.6);
}

.typing-test .cyber-input:focus {
  background-color: rgba(20, 35, 50, 1);
  color: #e6f7ff;
  border-color: #5dc8ff;
  box-shadow: 0 0 10px rgba(93,200,255,0.3);
}

.typing-test .cyber-terminal {
  font-family: "JetBrains Mono", monospace;
  color: #bfe9ff;
  text-shadow: 0 0 4px rgba(93,200,255,0.5);
  min-height: 120px;
  white-space: normal;
  width: 100%;
  overflow-x: hidden;
  text-align: left;
  padding: 12px 16px;
  line-height: 1.45;
}

.typing-test #cursor {
  color: #5dc8ff;
  animation: blink 1s infinite;
}

.typing-test .neon-blue {
  color: #5dc8ff;
  text-shadow: 0 0 6px rgba(93,200,255,0.4);
}

.typing-test .meter-box {
  background: rgba(10, 15, 20, 0.8);
  border: 1px solid rgba(93,200,255,0.25);
  box-shadow: inset 0 0 10px rgba(93,200,255,0.15), 0 0 8px rgba(93,200,255,0.2);
  display: inline-block;
}

.typing-test .glow-btn {
  box-shadow: 0 0 10px rgba(93,200,255,0.3);
  transition: all 0.3s ease;
}

.typing-test .glow-btn:hover {
  box-shadow: 0 0 20px rgba(93,200,255,0.5);
  transform: translateY(-1px);
}

.typing-test #testText {
  color: #e3f5ff;
  background-color: rgba(8, 12, 20, 0.95);
  border: 1px solid rgba(93,200,255,0.25);
  box-shadow: inset 0 0 8px rgba(93,200,255,0.2);
}

/* === Shared: No number arrows + cyber scrollbars === */
.cyber-input[type="number"] {
  appearance: textfield;
  -moz-appearance: textfield;
  -webkit-appearance: textfield;
}


.cyber-input[type="number"]::-webkit-outer-spin-button,
.cyber-input[type="number"]::-webkit-inner-spin-button {
  -webkit-appearance: none;
  margin: 0;
}

textarea.cyber-input {
  resize: vertical;
  overflow-y: auto;
  scrollbar-width: thin;
  scrollbar-color: currentColor rgba(10, 20, 15, 0.5);
}

textarea.cyber-input::-webkit-scrollbar {
  width: 10px;
}

textarea.cyber-input::-webkit-scrollbar-track {
  background: rgba(10, 20, 15, 0.5);
  border-radius: 8px;
}

textarea.cyber-input::-webkit-scrollbar-thumb {
  background: linear-gradient(180deg, currentColor 0%, #2ea043 100%);
  border-radius: 8px;
  box-shadow: 0 0 8px rgba(99,255,93,0.4);
}

textarea.cyber-input::-webkit-scrollbar-thumb:hover {
  filter: brightness(1.2);
}

/* === Typing Test — Completion + Results Styling === */
.typing-test #testCompleteMsg {
  text-align: center;
  font-weight: 700;
  color: #5dc8ff;
  text-shadow: 0 0 8px rgba(93,200,255,0.4);
  background: rgba(10,15,25,0.9);
  border: 1px solid rgba(93,200,255,0.25);
  border-radius: 8px;
  padding: 4px 8px;
  margin-top: 4px;
  box-shadow: inset 0 0 10px rgba(93,200,255,0.15), 0 0 8px rgba(93,200,255,0.25);
  display: inline-block;
  width: 100%;
}

/* Animated check icon (instead of plain ✅) */
.typing-test #testCompleteMsg {
  content: ""; /* bootstrap icons: check-circle-fill (requires bi font) */
  font-size: 1.4em;
  color: #5dc8ff;
  margin-right: 8px;
  vertical-align: middle;
}

/* prevent textarea from turning bright white after completion */
.typing-test #typingInput.bg-light {
  background-color: rgba(15,25,35,0.85) !important;
  color: #e6f7ff !important;
  border-color: rgba(93,200,255,0.3) !important;
}
/* === FIX: Gauge alignment on medium screens === */
@media (max-width: 991.98px) and (min-width: 768px) {
  .typing-test .row.gy-3.align-items-start {
    align-items: center !important;
  }
  .typing-test .meter-box {
    margin-top: 20px;
    margin-left: auto;
    margin-right: auto;
    display: block;
    max-width: 280px;
  }
  #testGauge {
    width: 100% !important;
    height: auto !important;
  }
}

.theme-select {
  width: auto;
  display: inline-block;
  text-align: left;
}

.table-dark th {
  background-color: #0b0f14;
  color: #cdeeff;
}

/* === FINAL STABLE CYBER GLOW — Full Row, Perfect Alignment === */
.table-dark tr.best-score td {
  background-color: rgba(0, 60, 40, 0.35) !important;
  color: #00ff9c !important;
  font-weight: 700;
  text-shadow: 0 0 12px rgba(0,255,160,0.6);
  animation: pulseGlow 2s ease-in-out infinite;
  position: relative;
  z-index: 0;
  box-shadow: inset 0 0 6px rgba(0,255,160,0.25);
}

.table-dark tr.best-score td:first-child::before {
  content: "";
  position: absolute;
  top: 0;
  left: -9999px;
  width: 99999px;
  height: 100%;
  background: radial-gradient(circle, rgba(0,255,160,0.22) 0%, transparent 70%);
  filter: blur(4px);
  z-index: -1;
  pointer-events: none;
}

@keyframes pulseGlow {
  0%, 100% {
    filter: brightness(1);
    box-shadow: inset 0 0 6px rgba(0,255,160,0.25);
  }
  50% {
    filter: brightness(1.3);
    box-shadow: inset 0 0 10px rgba(0,255,160,0.35);
  }
}
.btn-outline-success.glow-btn {
  color: #00ff9c;
  border-color: #00ff9c;
  text-shadow: 0 0 6px rgba(0, 255, 160, 0.4);
}

.challenge-instructions ul {
  list-style: "⚡ ";
  line-height: 1.5;
  color: #9ae9ff;
}
.challenge-instructions li strong {
  color: #00ff9c;
  text-shadow: 0 0 4px rgba(0, 255, 160, 0.4);
}

@keyframes softPulse {
  0%, 100% {
    box-shadow: 0 0 6px rgba(0, 255, 255, 0.3), 0 0 12px rgba(0, 255, 255, 0.1);
  }
  50% {
    box-shadow: 0 0 12px rgba(0, 255, 255, 0.6), 0 0 20px rgba(0, 255, 255, 0.3);
  }
}

.glow-pulse {
  animation: softPulse 2s ease-in-out infinite;
  border-color: rgba(0, 255, 255, 0.6);
}

/* After selection, remove glow */
.glow-pulse.selected {
  animation: none;
  box-shadow: none;
}

#themeSelect.glow-pulse {
  box-shadow: 0 0 12px rgba(0, 255, 255, 0.5),
              0 0 24px rgba(0, 255, 255, 0.3);
  animation: themeGlow 1.6s ease-in-out infinite;
  border-color: #00eaff;
}
@keyframes themeGlow {
  0%, 100% { box-shadow: 0 0 8px rgba(0, 255, 255, 0.4); }
  50% { box-shadow: 0 0 20px rgba(0, 255, 255, 0.8); }
}

#instructionsBox {
  overflow: hidden;
  height: auto;
  transition: all 0.35s ease;
}

#instructionsBox.collapsed {
  height: 0;
  padding-top: 0 !important;
  padding-bottom: 0 !important;
  border-width: 0;
  opacity: 0;
}

#instructionsBox.collapse {
  transition: height 0.35s ease;
}

#navmenu a {
  transition: none !important;
  transform: none !important;
  animation: none !important;
}
#navmenu a:focus,
#navmenu a:active {
  outline: none !important;
  transform: none !important;
}
