/* 游戏门禁：进游戏前的小测验 + 休息提醒 */
#gateRoot {
  position: fixed;
  inset: 0;
  z-index: 9999;
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 16px;
  background: rgba(5, 8, 18, 0.88);
  backdrop-filter: blur(10px);
  font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", "Microsoft YaHei", "PingFang SC", sans-serif;
  color: #eef2ff;
}

#gateRoot.hidden { display: none !important; }

.gate-card {
  width: min(94vw, 520px);
  border-radius: 24px;
  padding: 28px 26px 24px;
  background: linear-gradient(180deg, rgba(32, 44, 86, 0.98), rgba(16, 22, 44, 0.98));
  border: 1px solid rgba(110, 231, 255, 0.28);
  box-shadow: 0 30px 90px rgba(0, 0, 0, 0.6), 0 0 80px rgba(110, 231, 255, 0.12);
  text-align: center;
  animation: gatePop 0.3s cubic-bezier(.18, 1.2, .4, 1);
}

@keyframes gatePop {
  from { transform: scale(0.9) translateY(10px); opacity: 0; }
  to   { transform: none; opacity: 1; }
}

.gate-emoji { font-size: 40px; line-height: 1; margin-bottom: 6px; }

.gate-title {
  margin: 0 0 6px;
  font-size: 21px;
  font-weight: 800;
  letter-spacing: 0.5px;
}

.gate-sub {
  margin: 0 0 18px;
  font-size: 13px;
  color: #93a0c4;
}

.gate-progress {
  display: flex;
  gap: 6px;
  justify-content: center;
  margin-bottom: 16px;
}

.gate-progress i {
  width: 26px;
  height: 5px;
  border-radius: 3px;
  background: rgba(255, 255, 255, 0.14);
}

.gate-progress i.on { background: #6ee7ff; }

.gate-question {
  font-size: 19px;
  font-weight: 700;
  margin: 0 0 16px;
  line-height: 1.5;
}

.gate-options {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 10px;
  margin-bottom: 10px;
}

.gate-option {
  padding: 14px 10px;
  border-radius: 14px;
  font-size: 15px;
  font-weight: 600;
  color: #eef2ff;
  background: rgba(255, 255, 255, 0.06);
  border: 1px solid rgba(255, 255, 255, 0.12);
  cursor: pointer;
  transition: background 0.15s, transform 0.12s, border-color 0.15s;
}

.gate-option:hover { background: rgba(255, 255, 255, 0.12); }
.gate-option:active { transform: scale(0.97); }
.gate-option.right { background: rgba(62, 224, 143, 0.25); border-color: #3ee08f; }
.gate-option.wrong { background: rgba(255, 107, 107, 0.22); border-color: #ff6b6b; }

.gate-feedback {
  min-height: 22px;
  font-size: 14px;
  margin-bottom: 6px;
  color: #93a0c4;
}

.gate-feedback.ok { color: #3ee08f; }
.gate-feedback.no { color: #ff8a8a; }

.gate-read {
  font-size: 20px;
  line-height: 1.7;
  font-weight: 700;
  margin: 4px 0 14px;
  padding: 16px;
  border-radius: 14px;
  background: rgba(255, 255, 255, 0.05);
  border: 1px solid rgba(255, 255, 255, 0.1);
}

.gate-btn {
  width: 100%;
  padding: 14px 20px;
  border-radius: 14px;
  border: none;
  font-size: 16px;
  font-weight: 800;
  color: #05101f;
  background: linear-gradient(135deg, #6ee7ff, #b8f3ff);
  cursor: pointer;
  transition: transform 0.12s, box-shadow 0.15s;
}

.gate-btn:hover { box-shadow: 0 12px 30px rgba(110, 231, 255, 0.3); }
.gate-btn:active { transform: scale(0.98); }
.gate-btn:disabled { opacity: 0.45; cursor: not-allowed; box-shadow: none; }

.gate-btn.ghost {
  margin-top: 10px;
  color: #eef2ff;
  background: rgba(255, 255, 255, 0.07);
  border: 1px solid rgba(255, 255, 255, 0.14);
}

.gate-timer {
  font-size: 34px;
  font-weight: 800;
  color: #6ee7ff;
  margin: 6px 0 14px;
  font-variant-numeric: tabular-nums;
}

.gate-note {
  font-size: 12px;
  color: #93a0c4;
  margin-top: 12px;
  line-height: 1.6;
}

@media (max-width: 420px) {
  .gate-options { grid-template-columns: 1fr; }
  .gate-card { padding: 22px 18px 18px; }
}
