/* ============================
   Careers Page — Interactive Quiz
   ============================ */

.cr-hero {
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  min-height: 80vh;
  padding: 140px 24px 80px;
  text-align: center;
}
.cr-label {
  font-size: 12px;
  text-transform: uppercase;
  letter-spacing: 0.1em;
  color: var(--text-muted);
  margin-bottom: 12px;
}
.cr-title {
  font-size: clamp(28px, 4vw, 44px);
  font-weight: 600;
  color: #f5f5f5;
  letter-spacing: -0.03em;
  margin-bottom: 64px;
}

/* ---- Quiz container ---- */
.cr-quiz {
  position: relative;
  width: 100%;
  max-width: 600px;
  min-height: 260px;
}

/* ---- Steps ---- */
.cr-step {
  position: absolute;
  top: 0;
  left: 0;
  width: 100%;
  opacity: 0;
  transform: translateY(20px);
  pointer-events: none;
  transition: opacity 0.4s ease, transform 0.4s ease;
}
.cr-step.active {
  position: relative;
  opacity: 1;
  transform: translateY(0);
  pointer-events: auto;
}
.cr-step.exit {
  opacity: 0;
  transform: translateY(-20px);
}
.cr-step.entering {
  opacity: 0;
  transform: translateY(20px);
}

/* ---- Questions ---- */
.cr-question {
  font-size: clamp(22px, 3vw, 28px);
  font-weight: 500;
  color: #f5f5f5;
  line-height: 1.3;
  margin-bottom: 36px;
}

/* ---- Answer buttons ---- */
.cr-answers {
  display: flex;
  gap: 12px;
  justify-content: center;
  flex-wrap: wrap;
}
.cr-answer {
  padding: 12px 32px;
  border-radius: 100px;
  border: 1px solid rgba(255,255,255,0.2);
  background: transparent;
  color: #f5f5f5;
  font-size: 15px;
  font-weight: 500;
  cursor: pointer;
  transition: background 0.2s, border-color 0.2s, transform 0.15s;
}
.cr-answer:hover {
  background: rgba(255,255,255,0.08);
  border-color: rgba(255,255,255,0.4);
  transform: scale(1.03);
}
.cr-answer:active {
  transform: scale(0.97);
}

/* ---- Endings ---- */
.cr-ending {
  text-align: center;
}
.cr-verdict {
  font-size: clamp(24px, 3.5vw, 32px);
  font-weight: 600;
  color: #f5f5f5;
  margin-bottom: 12px;
  letter-spacing: -0.02em;
}
.cr-ending.agent .cr-verdict {
  color: var(--green);
}
.cr-ending-sub {
  font-size: 16px;
  color: var(--text-secondary);
  line-height: 1.5;
  margin-bottom: 32px;
  max-width: 440px;
  margin-left: auto;
  margin-right: auto;
}

/* ---- Prompt challenge ---- */
.cr-prompt-challenge {
  margin-bottom: 24px;
}
.cr-challenge-label {
  font-size: 14px;
  color: var(--text-secondary);
  margin-bottom: 16px;
  font-weight: 500;
}
.cr-challenge-input {
  width: 100%;
  min-height: 100px;
  background: var(--bg-elevated);
  border: 1px solid var(--border-color);
  border-radius: 14px;
  padding: 16px;
  color: #f5f5f5;
  font-family: var(--font);
  font-size: 14px;
  line-height: 1.5;
  resize: vertical;
  margin-bottom: 12px;
  outline: none;
  transition: border-color 0.2s;
}
.cr-challenge-input:focus {
  border-color: rgba(255,255,255,0.3);
}
.cr-challenge-input:disabled {
  opacity: 0.5;
  cursor: not-allowed;
}
.cr-challenge-actions {
  display: flex;
  justify-content: center;
}
.cr-challenge-submit {
  padding: 10px 28px;
  border-radius: 100px;
  background: #f5f5f5;
  color: #0c130f;
  font-size: 14px;
  font-weight: 600;
  cursor: pointer;
  border: none;
  transition: background 0.2s, transform 0.15s;
}
.cr-challenge-submit:hover {
  background: #ddd;
  transform: scale(1.03);
}
.cr-challenge-submit:disabled {
  opacity: 0.6;
  cursor: not-allowed;
  transform: none;
}
/* ---- Submit transition ---- */
.cr-prompt-challenge {
  transition: opacity 0.4s ease, transform 0.4s ease;
}
.cr-prompt-challenge.submitting {
  opacity: 0.5;
  transform: scale(0.98);
}
.cr-prompt-challenge.submitting .cr-challenge-submit {
  background: transparent;
  border: 1px solid rgba(255,255,255,0.2);
  color: rgba(255,255,255,0.4);
}
.cr-prompt-challenge.submitted {
  animation: cr-success-in 0.6s cubic-bezier(0.16, 1, 0.3, 1) forwards;
}

/* ---- Success card ---- */
.cr-success {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 12px;
  padding: 8px 0;
}
.cr-success-check {
  width: 56px;
  height: 56px;
  border-radius: 50%;
  background: rgba(74, 222, 128, 0.1);
  display: flex;
  align-items: center;
  justify-content: center;
  color: var(--green);
  animation: cr-check-pop 0.5s cubic-bezier(0.34, 1.56, 0.64, 1) 0.1s both;
}
.cr-success-check svg {
  stroke-dasharray: 30;
  stroke-dashoffset: 30;
  animation: cr-check-draw 0.4s ease 0.35s forwards;
}
.cr-success-title {
  font-size: 18px;
  font-weight: 600;
  color: #f5f5f5;
  opacity: 0;
  transform: translateY(8px);
  animation: cr-text-in 0.4s ease 0.45s forwards;
}
.cr-success-sub {
  font-size: 14px;
  color: var(--text-secondary);
  opacity: 0;
  transform: translateY(8px);
  animation: cr-text-in 0.4s ease 0.6s forwards;
}

@keyframes cr-success-in {
  from { opacity: 0; transform: scale(0.95); }
  to { opacity: 1; transform: scale(1); }
}
@keyframes cr-check-pop {
  from { transform: scale(0); opacity: 0; }
  to { transform: scale(1); opacity: 1; }
}
@keyframes cr-check-draw {
  to { stroke-dashoffset: 0; }
}
@keyframes cr-text-in {
  to { opacity: 1; transform: translateY(0); }
}

/* ---- Restart ---- */
.cr-restart {
  margin-top: 24px;
  background: none;
  border: none;
  color: var(--text-muted);
  font-size: 13px;
  cursor: pointer;
  transition: color 0.2s;
  padding: 8px 16px;
}
.cr-restart:hover {
  color: var(--text-secondary);
}

/* ---- Agent ending CTA ---- */
.cr-ending.agent .btn {
  margin-bottom: 8px;
}

/* ============================
   Responsive
   ============================ */
@media (max-width: 768px) {
  .cr-hero {
    padding: 120px 16px 60px;
    min-height: 70vh;
  }
  .cr-title {
    margin-bottom: 48px;
  }
  .cr-question {
    font-size: 22px;
  }
  .cr-answer {
    padding: 10px 24px;
    font-size: 14px;
  }
}

@media (max-width: 480px) {
  .cr-hero {
    padding: 100px 14px 40px;
  }
  .cr-title {
    font-size: 28px;
    margin-bottom: 36px;
  }
  .cr-answers {
    flex-direction: column;
    gap: 8px;
  }
  .cr-answer {
    width: 100%;
  }
  .cr-verdict {
    font-size: 24px;
  }
}
