/* ═══════════════════════════════════════════
   SCREENS — mode, levelup, about, planets
═══════════════════════════════════════════ */

/* ─── MODE SELECT ─────────────────────────── */
#screen-mode {
  background: linear-gradient(180deg, #0D2B0D 0%, #152515 100%);
}

.mode-grid {
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  gap: 0.8rem;
}

.mode-card {
  background: var(--mc-panel);
  border: 3px solid var(--mc-border);
  box-shadow: inset -3px -3px 0 #1A1A1A, inset 3px 3px 0 #5A5A5A;
  padding: 1rem 0.8rem;
  cursor: pointer;
  transition: filter 0.15s, transform 0.1s;
  text-align: center;
}
.mode-card:hover:not(.mode-locked) { filter: brightness(1.2); transform: translateY(-2px); }
.mode-card:focus-visible { outline: 3px solid var(--mc-gold); outline-offset: 2px; }
.mode-card.mode-locked {
  opacity: 0.35;
  cursor: not-allowed;
  filter: grayscale(0.6);
}
.mode-filter-banner {
  background: rgba(255, 213, 79, 0.12);
  border: 1px solid #ffd54f66;
  border-radius: 6px;
  padding: 0.5rem 0.75rem;
  margin-bottom: 0.75rem;
  font-family: 'VT323', monospace;
  font-size: 0.85rem;
  color: #ffd54f;
  line-height: 1.4;
}
.mode-card.selected {
  border-color: var(--mc-emerald);
  box-shadow: inset -3px -3px 0 #1A1A1A, inset 3px 3px 0 var(--mc-emerald), 0 0 12px var(--mc-emerald);
}

.mode-icon { font-size: 2rem; margin-bottom: 0.4rem; }
.mode-name { font-size: 0.55rem; color: var(--mc-gold); margin-bottom: 0.3rem; }
.mode-desc { font-family: var(--font-vt); font-size: 1rem; color: var(--mc-text-dim); line-height: 1.3; }

/* ─── LEVEL UP ────────────────────────────── */
#screen-levelup {
  background: radial-gradient(circle, #1E5A1E 0%, #0B1E0B 100%);
  align-items: center;
  justify-content: center;
}

.levelup-content {
  text-align: center;
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 1rem;
  padding: 2rem;
  position: relative;
}

.levelup-sparkles {
  position: absolute;
  inset: 0;
  pointer-events: none;
}

.levelup-title {
  font-size: 1rem;
  color: var(--mc-gold);
  text-shadow: 0 0 20px var(--mc-gold), 3px 3px 0 #000;
  animation: pulse 1s ease-in-out infinite;
}

@keyframes pulse { 0%,100%{opacity:1} 50%{opacity:0.7} }

.levelup-level { font-size: 3rem; color: var(--mc-gold); text-shadow: 0 0 30px var(--mc-gold); }
.levelup-title-text { font-size: 0.7rem; color: var(--mc-diamond); }
.levelup-item { font-size: 1.2rem; font-family: var(--font-vt); color: var(--mc-text-dim); }

.sparkle {
  position: absolute;
  font-size: 1.5rem;
  animation: sparkle-fly 2s ease-out forwards;
}
@keyframes sparkle-fly {
  0% { transform: translate(0,0) scale(0); opacity: 1; }
  100% { transform: translate(var(--tx), var(--ty)) scale(1.5); opacity: 0; }
}

/* ─── PLANET DECORATIONS (Science) ───────── */
.planet-deco {
  display: none;
  position: absolute;
  inset: 0;
  pointer-events: none;
  z-index: 0;
  overflow: hidden;
}
body.theme-space .planet-deco { display: block; }

.planet {
  position: absolute;
  line-height: 1;
  user-select: none;
}

.p-saturn     { top: 4%;  right: 4%;  font-size: 3.2rem; opacity: 0.75; animation: pfloat-a 9s ease-in-out infinite; }
.p-earth      { bottom: 22%; left: 2%; font-size: 2.6rem; opacity: 0.70; animation: pfloat-b 11s ease-in-out infinite 1s; }
.p-mars       { top: 38%; right: 2%;  font-size: 1.6rem; opacity: 0.65; animation: pfloat-c 7s ease-in-out infinite 0.5s; }
.p-moon       { bottom: 6%; right: 7%; font-size: 2.2rem; opacity: 0.70; animation: pfloat-a 13s ease-in-out infinite 3s; }
.p-comet      { top: 55%; right: 3%;  font-size: 2rem;   opacity: 0.60; animation: comet-drift 18s linear infinite; }
.p-star1      { top: 18%; left: 4%;   font-size: 1.6rem; opacity: 0.80; animation: star-twinkle 3.5s ease-in-out infinite; }
.p-star2      { top: 65%; left: 6%;   font-size: 1.3rem; opacity: 0.75; animation: star-twinkle 2.5s ease-in-out infinite 1.2s; }
.p-star3      { bottom: 14%; left: 5%;font-size: 1.1rem; opacity: 0.70; animation: star-twinkle 4s ease-in-out infinite 2s; }

@keyframes pfloat-a {
  0%,100% { transform: translateY(0) rotate(0deg); }
  50%     { transform: translateY(-16px) rotate(10deg); }
}
@keyframes pfloat-b {
  0%,100% { transform: translateY(0) rotate(0deg); }
  35%     { transform: translateY(-22px) rotate(-12deg); }
  70%     { transform: translateY(-8px) rotate(6deg); }
}
@keyframes pfloat-c {
  0%,100% { transform: translateY(0) scale(1); }
  50%     { transform: translateY(-14px) scale(1.12); }
}
@keyframes star-twinkle {
  0%,100% { opacity: 0.85; transform: scale(1); }
  50%     { opacity: 0.15; transform: scale(0.6); }
}
@keyframes comet-drift {
  0%   { transform: translate(0,    0   ) rotate(-25deg); }
  50%  { transform: translate(-30px, 18px) rotate(-25deg); }
  100% { transform: translate(0,    0   ) rotate(-25deg); }
}

body.theme-space .hud,
body.theme-space .question-area { position: relative; z-index: 1; }

/* ─── ABOUT SCREEN ────────────────────────── */
.about-body {
  padding: 0 1rem 2rem;
  overflow-y: auto;
}
.about-hero {
  text-align: center;
  padding: 1rem 0 0.5rem;
}
.about-logo { font-size: 2.5rem; }
.about-title {
  font-family: 'VT323', monospace;
  font-size: 2rem;
  color: var(--mc-gold);
  margin: 0.2rem 0 0;
}
.about-tagline {
  font-family: 'VT323', monospace;
  font-size: 0.9rem;
  color: var(--mc-text-dim);
  margin: 0 0 1rem;
}
.about-section {
  margin-bottom: 0.9rem;
  padding: 0.8rem 1rem;
}
.about-section-title {
  font-family: 'VT323', monospace;
  font-size: 1.3rem;
  color: var(--mc-gold);
  margin-bottom: 0.5rem;
}
.about-text {
  font-family: 'VT323', monospace;
  font-size: 1.05rem;
  color: #e0e0e0;
  line-height: 1.5;
  margin: 0;
}
.about-subject-row {
  display: flex;
  align-items: flex-start;
  gap: 0.6rem;
  margin-bottom: 0.4rem;
  font-family: 'VT323', monospace;
  font-size: 1.05rem;
  color: #e0e0e0;
}
.about-subj-icon { font-size: 1.3rem; flex-shrink: 0; }
.about-mode-row {
  display: flex;
  justify-content: space-between;
  font-family: 'VT323', monospace;
  font-size: 1.05rem;
  color: #e0e0e0;
  padding: 0.3rem 0;
  border-bottom: 1px solid rgba(255,255,255,0.06);
}
.about-mode-row:last-child { border-bottom: none; }
.about-streak-table { margin-top: 0.4rem; }
.about-streak-row {
  display: flex;
  justify-content: space-between;
  font-family: 'VT323', monospace;
  font-size: 1.05rem;
  color: #e0e0e0;
  padding: 0.3rem 0;
  border-bottom: 1px solid rgba(255,255,255,0.06);
}
.about-streak-row:last-child { border-bottom: none; }
.streak-reward { color: #69f0ae; }
.about-version {
  text-align: center;
  font-family: 'VT323', monospace;
  font-size: 0.9rem;
  color: #555;
  margin-top: 1rem;
}
