/* styles/checkpoint.css
   Mid-run formative checkpoint (C6). Inline check between biome
   transitions — one micro-question, two options, brief feedback.
   No penalty for wrong; gated to fire once per player per checkpoint
   id.

   Visual register matches the share-card resting beat but smaller
   and tighter — this is a teaching pause, not an end-of-run beat. */

.checkpoint-overlay {
  position: fixed;
  inset: 0;
  z-index: var(--z-modal, 60);
  background: rgba(6, 7, 12, 0.86);
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 24px;
  opacity: 0;
  transition: opacity 700ms ease;
  backdrop-filter: blur(8px) saturate(0.85);
  -webkit-backdrop-filter: blur(8px) saturate(0.85);
}
.checkpoint-overlay.revealed { opacity: 1; }

.checkpoint-card {
  position: relative;
  width: min(480px, 92vw);
  max-height: 88vh;
  overflow-y: auto;
  background: linear-gradient(180deg,
    #0c1220 0%,
    #10162a 55%,
    #080a14 100%);
  border: 1px solid rgba(184, 224, 255, 0.30);
  border-radius: 4px;
  padding: 28px 32px 24px 32px;
  color: rgba(248, 240, 224, 0.94);
  font-family: var(--serif);
  box-shadow:
    0 0 40px rgba(184, 224, 255, 0.10),
    0 28px 56px rgba(0, 0, 0, 0.72);
  transform: translateY(8px);
  transition: transform 700ms ease;
}
.checkpoint-overlay.revealed .checkpoint-card {
  transform: translateY(0);
}

/* ---------- EYEBROW (Schema voice register) ---------- */

.cp-eyebrow {
  display: block;
  text-align: center;
  font-family: var(--mono);
  font-size: 0.55rem;
  letter-spacing: 0.42em;
  text-transform: uppercase;
  color: rgba(184, 224, 255, 0.65);
  margin-bottom: 18px;
}

/* ---------- QUESTION ---------- */

.cp-question {
  margin: 0 0 22px 0;
  text-align: center;
  font-family: var(--serif);
  font-style: italic;
  font-weight: normal;
  font-size: 1.25rem;
  line-height: 1.35;
  letter-spacing: 0.01em;
  color: rgba(232, 240, 252, 0.96);
}

/* ---------- OPTIONS ---------- */

.cp-options {
  display: flex;
  flex-direction: column;
  gap: 10px;
  margin-bottom: 18px;
}
.cp-option {
  width: 100%;
  text-align: left;
  padding: 14px 18px;
  background: rgba(184, 224, 255, 0.03);
  border: 1px solid rgba(184, 224, 255, 0.22);
  border-radius: 3px;
  color: rgba(232, 240, 252, 0.94);
  font-family: var(--serif);
  font-size: 0.96rem;
  line-height: 1.4;
  cursor: pointer;
  transition: all 200ms ease;
}
.cp-option:hover:not(:disabled) {
  border-color: rgba(184, 224, 255, 0.65);
  background: rgba(184, 224, 255, 0.08);
  transform: translateX(2px);
}
.cp-option:active:not(:disabled) {
  transform: translateX(2px) scale(0.99);
}
.cp-option:disabled {
  cursor: default;
  opacity: 0.55;
}
.cp-option.is-correct {
  border-color: rgba(10, 191, 83, 0.75);
  background: rgba(10, 191, 83, 0.10);
  color: rgba(180, 248, 200, 0.96);
  opacity: 1;
}
.cp-option.is-wrong {
  border-color: rgba(255, 168, 100, 0.65);
  background: rgba(255, 168, 100, 0.08);
  color: rgba(255, 220, 180, 0.92);
  opacity: 1;
}
.cp-option.is-actually-correct {
  /* The option the player DIDN'T pick but which was correct — show it
     with a soft green outline so they see the right answer. */
  border-color: rgba(10, 191, 83, 0.45);
  border-style: dashed;
  color: rgba(180, 248, 200, 0.85);
  opacity: 0.92;
}

/* ---------- FEEDBACK ---------- */

.cp-feedback {
  margin-top: 8px;
  padding-top: 16px;
  border-top: 1px solid rgba(184, 224, 255, 0.12);
  animation: cp-feedback-in 500ms ease both;
}
@keyframes cp-feedback-in {
  from { opacity: 0; transform: translateY(4px); }
  to   { opacity: 1; transform: translateY(0); }
}
.cp-feedback-verdict {
  font-family: var(--mono);
  font-size: 0.7rem;
  letter-spacing: 0.32em;
  text-transform: uppercase;
  margin-bottom: 8px;
}
.cp-feedback-verdict.is-correct {
  color: rgba(10, 191, 83, 0.95);
}
.cp-feedback-verdict.is-wrong {
  color: rgba(255, 168, 100, 0.92);
}
.cp-feedback-explanation {
  font-family: var(--serif);
  font-size: 0.92rem;
  line-height: 1.5;
  color: rgba(232, 240, 252, 0.88);
  margin-bottom: 18px;
}
.cp-feedback-explanation em {
  font-style: italic;
  color: rgba(255, 232, 168, 0.95);
}

.cp-continue {
  display: block;
  margin: 0 auto;
  padding: 12px 26px;
  background: rgba(184, 224, 255, 0.06);
  border: 1px solid rgba(184, 224, 255, 0.55);
  border-radius: 3px;
  color: rgba(184, 224, 255, 0.95);
  font-family: var(--mono);
  cursor: pointer;
  transition: all 200ms ease;
}
.cp-continue:hover {
  border-color: rgba(184, 224, 255, 0.95);
  background: rgba(184, 224, 255, 0.12);
  transform: translateY(-1px);
  box-shadow: 0 6px 18px rgba(0, 0, 0, 0.4);
}
.cp-continue-label {
  font-size: 0.85rem;
  letter-spacing: 0.28em;
  text-transform: uppercase;
  font-weight: bold;
}

/* ---------- REDUCED MOTION ---------- */

@media (prefers-reduced-motion: reduce) {
  .checkpoint-overlay { transition-duration: 200ms; }
  .checkpoint-card { transition-duration: 100ms; transform: none !important; }
  .cp-option,
  .cp-continue { transition-duration: 100ms; transform: none !important; }
  .cp-feedback { animation-duration: 200ms; }
}

/* ---------- MOBILE BREAKPOINT ---------- */

@media (max-width: 480px) {
  .checkpoint-overlay { padding: 12px; }
  .checkpoint-card {
    width: 96vw;
    padding: 22px 20px 18px 20px;
  }
  .cp-question { font-size: 1.1rem; }
  .cp-option { font-size: 0.9rem; padding: 12px 14px; }
  .cp-feedback-explanation { font-size: 0.85rem; }
}
