/* ==========================================================================
   🔢 猜数字游戏模块 专属 CSS (css/number-guess.css)
   ========================================================================== */

.number-guess-stage-vault {
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  width: 100%;
  max-width: 960px;
  margin: 0 auto;
  min-height: 72vh;
}

.number-guess-card {
  width: 100%;
  background: #ffffff;
  border-radius: 36px;
  padding: 48px;
  border: 1px solid var(--border-light);
  box-shadow: 0 24px 60px rgba(0, 0, 0, 0.1);
  display: flex;
  flex-direction: column;
  align-items: center;
  text-align: center;
  box-sizing: border-box;
}

.number-guess-card.setup {
  max-width: 600px;
}

.mode-selector-grid {
  display: flex;
  gap: 12px;
  width: 100%;
  margin-bottom: 24px;
}

.mode-option-btn {
  flex: 1;
  padding: 16px 12px;
  border-radius: 20px;
  border: 2px solid #e2e8f0;
  background: #f8fafc;
  cursor: pointer;
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 6px;
  transition: all 0.2s ease;
}

.mode-option-btn.active {
  border-color: var(--accent-primary);
  background: #fef2f2;
  box-shadow: 0 4px 14px rgba(239, 68, 68, 0.15);
}

.mode-option-btn .mode-title {
  font-size: 16px;
  font-weight: 800;
  color: var(--text-primary);
}

.mode-option-btn .mode-desc {
  font-size: 12px;
  color: var(--text-muted);
}

/* 范围输入框水平完美对齐 */
.range-inputs-inline {
  display: flex;
  align-items: center;
  gap: 12px;
  width: 100%;
}

.input-range-num {
  flex: 1;
  width: 0;
  padding: 14px 18px;
  border-radius: 16px;
  border: 1px solid #cbd5e1;
  font-size: 15px;
  outline: none;
  background: #f8fafc;
  font-family: inherit;
  box-sizing: border-box;
  text-align: center;
  font-weight: 700;
  color: var(--text-primary);
  transition: all 0.2s ease;
}

.input-range-num:focus {
  border-color: var(--accent-primary);
  background: #ffffff;
  box-shadow: 0 0 0 3px rgba(239, 68, 68, 0.12);
}

.range-tilde {
  font-size: 18px;
  font-weight: 800;
  color: #94a3b8;
  flex-shrink: 0;
}

/* 巨幅震撼范围展示卡片 */
.range-display-box {
  width: 100%;
  padding: 44px 36px;
  background: linear-gradient(135deg, #0f172a 0%, #1e293b 100%);
  border-radius: 32px;
  color: #ffffff;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  margin-bottom: 36px;
  box-shadow: 0 20px 50px rgba(15, 23, 42, 0.35);
  position: relative;
  overflow: hidden;
}

.range-label {
  font-size: 15px;
  color: #94a3b8;
  letter-spacing: 0.15em;
  font-weight: 700;
  margin-bottom: 16px;
}

.range-values-row {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 28px;
  font-family: 'Outfit', sans-serif;
}

.range-bound {
  font-size: 88px;
  font-weight: 900;
  color: #38bdf8;
  text-shadow: 0 0 35px rgba(56, 189, 248, 0.6);
  line-height: 1;
}

.range-separator {
  font-size: 48px;
  color: #475569;
  font-weight: 300;
}

.range-target-placeholder {
  font-size: 88px;
  font-weight: 900;
  color: #fbbf24;
  text-shadow: 0 0 40px rgba(251, 191, 36, 0.8);
  animation: pulseScale 1.5s infinite alternate;
  line-height: 1;
}

/* 数字输入提交区 */
.number-input-form {
  display: flex;
  gap: 20px;
  width: 100%;
  max-width: 640px;
  margin-bottom: 32px;
}

.input-guess-number {
  flex: 1;
  padding: 20px 28px;
  border-radius: 24px;
  border: 2px solid #cbd5e1;
  font-size: 36px;
  font-weight: 900;
  text-align: center;
  font-family: 'Outfit', sans-serif;
  outline: none;
  background: #f8fafc;
  transition: all 0.2s ease;
}

.input-guess-number:focus {
  border-color: var(--accent-primary);
  background: #ffffff;
  box-shadow: 0 0 0 4px rgba(239, 68, 68, 0.15);
}

.btn-guess-submit {
  padding: 0 32px;
  border-radius: 20px;
  border: none;
  background: var(--accent-primary);
  color: #ffffff;
  font-size: 18px;
  font-weight: 800;
  font-family: inherit;
  cursor: pointer;
  transition: all 0.2s ease;
  box-shadow: 0 8px 20px rgba(239, 68, 68, 0.35);
  white-space: nowrap;
}

.btn-guess-submit:hover {
  background: var(--accent-primary-hover);
  transform: translateY(-2px);
  box-shadow: 0 12px 24px rgba(239, 68, 68, 0.45);
}

/* 猜测历史轨迹 */
.guess-history-feed {
  width: 100%;
  max-height: 180px;
  overflow-y: auto;
  display: flex;
  flex-direction: column;
  gap: 8px;
  padding: 8px;
  background: #f8fafc;
  border-radius: 20px;
  border: 1px solid #e2e8f0;
}

.history-item-row {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 10px 16px;
  background: #ffffff;
  border-radius: 12px;
  border: 1px solid #cbd5e1;
  font-size: 14px;
}

.history-item-row .val {
  font-weight: 800;
  font-size: 16px;
  color: var(--text-primary);
}

.history-item-row .hint-badge {
  font-size: 13px;
  font-weight: 700;
  padding: 4px 10px;
  border-radius: 8px;
}

.history-item-row .hint-badge.too-high {
  background: #fee2e2;
  color: #ef4444;
}

.history-item-row .hint-badge.too-low {
  background: #e0f2fe;
  color: #0284c7;
}

.history-item-row .hint-badge.ab-result {
  background: #fef3c7;
  color: #d97706;
  font-weight: 900;
}

/* 4位解密专有显示 */
.ab-feedback-box {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 24px;
  margin-bottom: 24px;
}

.ab-pill {
  padding: 12px 24px;
  border-radius: 16px;
  font-size: 24px;
  font-weight: 900;
  display: flex;
  align-items: center;
  gap: 8px;
}

.ab-pill.a {
  background: #dcfce7;
  color: #166534;
  border: 2px solid #86efac;
}

.ab-pill.b {
  background: #fef3c7;
  color: #92400e;
  border: 2px solid #fde68a;
}

/* 全屏炸弹爆炸 Overlay */
.bomb-explosion-overlay {
  position: fixed;
  inset: 0;
  z-index: 3000;
  background: rgba(15, 23, 42, 0.95);
  backdrop-filter: blur(28px);
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  text-align: center;
  animation: shake 0.5s ease;
}

.bomb-explosion-overlay.hidden { display: none; }

.bomb-icon-huge {
  font-size: 120px;
  animation: popScale 0.6s cubic-bezier(0.175, 0.885, 0.32, 1.275);
}

.bomb-title-text {
  font-size: 64px;
  font-weight: 900;
  color: #ef4444;
  text-shadow: 0 0 40px rgba(239, 68, 68, 0.8);
  margin-top: 16px;
}

.bomb-sub-text {
  font-size: 24px;
  color: #f87171;
  margin-top: 12px;
  margin-bottom: 32px;
}

.btn-bomb-close {
  flex: initial;
  width: 100%;
  max-width: 340px;
  padding: 18px 36px;
  border-radius: 32px;
  border: none;
  background: linear-gradient(135deg, #fbbf24 0%, #f59e0b 100%);
  color: #78350f;
  font-size: 18px;
  font-weight: 900;
  font-family: inherit;
  cursor: pointer;
  box-shadow: 0 10px 25px rgba(245, 158, 11, 0.45);
  transition: all 0.25s cubic-bezier(0.34, 1.56, 0.64, 1);
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  white-space: nowrap;
}

.btn-bomb-close:hover {
  transform: translateY(-3px) scale(1.04);
  box-shadow: 0 14px 32px rgba(245, 158, 11, 0.6);
}
