/* discr337.com — Orange, Blue & Silver Physics & Aerospace Theme */
:root {
  --bg-deep: #040914;
  --bg-panel: #091325;
  --bg-elevated: #0e1c36;
  --silver-bright: #f1f5f9;
  --silver-mid: #cbd5e1;
  --silver-muted: #94a3b8;
  --silver-border: rgba(203, 213, 225, 0.17);
  --blue-core: #0ea5e9;
  --blue-bright: #38bdf8;
  --blue-glow: rgba(14, 165, 233, 0.30);
  --orange-core: #ff6b1a;
  --orange-bright: #ff8c42;
  --orange-glow: rgba(255, 107, 26, 0.30);
  --font-sans: 'Inter', -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, sans-serif;
  --font-mono: 'JetBrains Mono', ui-monospace, SFMono-Regular, Menlo, Monaco, Consolas, monospace;
}

* {
  box-sizing: border-box;
}

html {
  scroll-behavior: smooth;
}

body {
  margin: 0;
  font-family: var(--font-sans);
  background-color: var(--bg-deep);
  color: var(--silver-bright);
  line-height: 1.6;
  overflow-x: hidden;
  background-image:
    radial-gradient(circle at 12% 10%, rgba(14, 165, 233, 0.11), transparent 36%),
    radial-gradient(circle at 88% 18%, rgba(255, 107, 26, 0.10), transparent 36%),
    linear-gradient(rgba(203, 213, 225, 0.025) 1px, transparent 1px),
    linear-gradient(90deg, rgba(203, 213, 225, 0.025) 1px, transparent 1px);
  background-size: 100% 100%, 100% 100%, 44px 44px, 44px 44px;
}

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

/* Brushed Silver Panels */
.silver-card {
  background: linear-gradient(145deg, rgba(14, 28, 54, 0.92), rgba(7, 15, 30, 0.96));
  border: 1px solid var(--silver-border);
  box-shadow:
    inset 0 1px 0 rgba(241, 245, 249, 0.12),
    0 18px 44px rgba(2, 6, 15, 0.58);
  border-radius: 1rem;
  backdrop-filter: blur(10px);
}

.silver-badge {
  background: linear-gradient(135deg, #f1f5f9 0%, #94a3b8 50%, #e2e8f0 100%);
  color: #050b16;
  font-weight: 800;
  letter-spacing: 0.06em;
}

.blue-accent-border {
  border-color: rgba(56, 189, 248, 0.36);
  box-shadow: inset 0 1px 0 rgba(56, 189, 248, 0.2), 0 0 32px rgba(14, 165, 233, 0.13);
}

.orange-accent-border {
  border-color: rgba(255, 107, 26, 0.36);
  box-shadow: inset 0 1px 0 rgba(255, 140, 66, 0.2), 0 0 32px rgba(255, 107, 26, 0.13);
}

/* Countdown Digit Tiles */
.cd-tile {
  background: linear-gradient(180deg, rgba(15, 30, 58, 0.95) 0%, rgba(5, 11, 22, 0.98) 100%);
  border: 1px solid rgba(203, 213, 225, 0.24);
  box-shadow:
    inset 0 1px 0 rgba(241, 245, 249, 0.18),
    0 8px 24px rgba(0, 0, 0, 0.45);
  border-radius: 0.85rem;
  position: relative;
  overflow: hidden;
}

.cd-tile::after {
  content: '';
  position: absolute;
  left: 0;
  right: 0;
  top: 50%;
  height: 1px;
  background: rgba(203, 213, 225, 0.08);
  pointer-events: none;
}

/* Spawn Palette Buttons */
.spawn-btn {
  transition: all 0.16s ease;
  border: 1px solid rgba(203, 213, 225, 0.18);
  background: rgba(7, 15, 30, 0.85);
}

.spawn-btn:hover {
  border-color: rgba(56, 189, 248, 0.55);
  transform: translateY(-1px);
}

.spawn-btn.active {
  border-color: #ff6b1a;
  background: linear-gradient(135deg, rgba(14, 165, 233, 0.22), rgba(255, 107, 26, 0.22));
  box-shadow: 0 0 18px rgba(255, 107, 26, 0.25);
}

/* Custom Range Sliders */
input[type='range'] {
  -webkit-appearance: none;
  appearance: none;
  width: 100%;
  height: 6px;
  border-radius: 999px;
  background: rgba(148, 163, 184, 0.25);
  outline: none;
  cursor: pointer;
}

input[type='range'].slider-blue::-webkit-slider-thumb {
  -webkit-appearance: none;
  appearance: none;
  width: 17px;
  height: 17px;
  border-radius: 50%;
  background: var(--blue-bright);
  border: 2px solid var(--silver-bright);
  box-shadow: 0 0 10px var(--blue-glow);
  cursor: pointer;
}

input[type='range'].slider-orange::-webkit-slider-thumb {
  -webkit-appearance: none;
  appearance: none;
  width: 17px;
  height: 17px;
  border-radius: 50%;
  background: var(--orange-core);
  border: 2px solid var(--silver-bright);
  box-shadow: 0 0 10px var(--orange-glow);
  cursor: pointer;
}

input[type='range'].slider-silver::-webkit-slider-thumb {
  -webkit-appearance: none;
  appearance: none;
  width: 17px;
  height: 17px;
  border-radius: 50%;
  background: var(--silver-bright);
  border: 2px solid var(--bg-deep);
  box-shadow: 0 0 10px rgba(241, 245, 249, 0.5);
  cursor: pointer;
}

/* 3D Solar System Container */
.solar-3d-wrap {
  position: relative;
  width: 100%;
  height: 540px;
  border-radius: 0.9rem;
  overflow: hidden;
  background: radial-gradient(circle at center, #081326 0%, #02050c 100%);
  border: 1px solid rgba(56, 189, 248, 0.30);
  cursor: grab;
  touch-action: none;
}

.solar-3d-wrap:active {
  cursor: grabbing;
}

.sim-canvas {
  width: 100%;
  height: 310px;
  display: block;
  border-radius: 0.75rem;
  background: radial-gradient(circle at center, #091529 0%, #040913 100%);
  border: 1px solid rgba(203, 213, 225, 0.16);
}

.rocket-canvas {
  width: 100%;
  height: 360px;
  display: block;
  border-radius: 0.85rem;
  background: linear-gradient(180deg, #02060e 0%, #07142b 58%, #0c2649 85%, #163a5f 100%);
  border: 1px solid rgba(255, 107, 26, 0.32);
}

/* Toast */
#toast {
  position: fixed;
  bottom: 1.25rem;
  right: 1.25rem;
  z-index: 60;
  transform: translateY(120%);
  opacity: 0;
  transition: transform 0.25s ease, opacity 0.25s ease;
}

#toast.show {
  transform: translateY(0);
  opacity: 1;
}

@keyframes pulseDot {
  0%, 100% { opacity: 1; transform: scale(1); }
  50% { opacity: 0.45; transform: scale(1.25); }
}

.pulse-dot {
  animation: pulseDot 1.8s infinite ease-in-out;
}
