/* ============================================
   Creative Confidence Assessment — Styles
   Light theme: bg #f5f3eb, dark text #1a1a1a,
   accent buttons with dark legible text.
   Reduced font sizes. Clean and minimal.
   letter-spacing: normal throughout.
   ============================================ */

/* --- Wrapper --- */
.ca-wrapper {
  min-height: 100vh;
  width: 100%;
  position: relative;
}

/* --- Screens --- */
.ca-screen {
  display: none;
  min-height: 100vh;
  padding: 80px 0 120px;
  opacity: 0;
  transition: opacity 0.5s ease;
}

.ca-screen--active {
  display: block;
  opacity: 1;
  animation: ca-fade-in 0.5s ease forwards;
}

@keyframes ca-fade-in {
  from { opacity: 0; transform: translateY(12px); }
  to { opacity: 1; transform: translateY(0); }
}

/* --- Container --- */
.ca-container {
  max-width: 840px;
  margin: 0 auto;
  padding: 0 24px;
}

/* --- Typography --- */
.ca-label {
  font-family: var(--font2, 'Roboto', sans-serif);
  font-size: 0.625rem;
  text-transform: uppercase;
  letter-spacing: 0.12em;
  color: var(--ghost-accent-color, #E84E1B);
  font-weight: 600;
  margin-bottom: 12px;
}

.ca-title {
  font-family: var(--font1, 'Thunder', sans-serif);
  font-size: clamp(2.5rem, 7vw, 5rem);
  font-weight: 700;
  text-transform: uppercase;
  line-height: 0.92;
  letter-spacing: normal;
  color: #1a1a1a;
  margin-bottom: 32px;
}

.ca-heading {
  font-family: var(--font2, 'Roboto', sans-serif);
  font-size: clamp(1.125rem, 2.5vw, 1.5rem);
  font-weight: 500;
  line-height: 1.35;
  letter-spacing: normal;
  color: #1a1a1a;
  margin-bottom: 28px;
}

/* --- Welcome --- */
.ca-welcome {
  padding-top: 40px;
}

.ca-intro-text {
  margin-bottom: 32px;
}

.ca-intro-text p {
  font-family: var(--font2, 'Roboto', sans-serif);
  font-size: 0.875rem;
  line-height: 1.7;
  letter-spacing: normal;
  color: rgba(26, 26, 26, 0.6);
  margin-bottom: 12px;
}

/* --- Buttons --- */
.ca-btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  font-family: var(--font2, 'Roboto', sans-serif);
  font-size: 0.8125rem;
  font-weight: 600;
  letter-spacing: 0.02em;
  border: none;
  border-radius: 0;
  cursor: pointer;
  transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
  padding: 16px 36px;
  width: 100%;
  text-align: center;
}

.ca-btn--primary {
  background: var(--ghost-accent-color, #E84E1B);
  color: #1a1a1a;
}

.ca-btn--primary:hover {
  opacity: 0.88;
  transform: translateY(-1px);
}

.ca-btn--primary:disabled {
  opacity: 0.5;
  cursor: not-allowed;
  transform: none;
}

/* --- Back button --- */
.ca-back {
  font-family: var(--font2, 'Roboto', sans-serif);
  font-size: 0.75rem;
  font-weight: 400;
  letter-spacing: normal;
  color: rgba(26, 26, 26, 0.35);
  background: none;
  border: none;
  cursor: pointer;
  padding: 0;
  margin-bottom: 36px;
  transition: color 0.2s ease;
}

.ca-back:hover {
  color: rgba(26, 26, 26, 0.6);
}

/* --- Form --- */
.ca-form-group {
  margin-bottom: 20px;
}

.ca-form-label {
  display: block;
  font-family: var(--font2, 'Roboto', sans-serif);
  font-size: 0.75rem;
  font-weight: 500;
  letter-spacing: 0.02em;
  text-transform: uppercase;
  color: rgba(26, 26, 26, 0.5);
  margin-bottom: 8px;
}

.ca-required {
  color: var(--ghost-accent-color, #E84E1B);
}

.ca-input {
  width: 100%;
  padding: 14px 16px;
  font-family: var(--font2, 'Roboto', sans-serif);
  font-size: 0.875rem;
  letter-spacing: normal;
  border: 1px solid rgba(26, 26, 26, 0.15);
  border-radius: 4px;
  background: rgba(26, 26, 26, 0.04);
  color: #1a1a1a;
  transition: border-color 0.2s ease;
  outline: none;
}

.ca-input:focus {
  border-color: var(--ghost-accent-color, #E84E1B);
  background: rgba(26, 26, 26, 0.06);
}

.ca-input::placeholder {
  color: rgba(26, 26, 26, 0.3);
}

/* --- Progress --- */
.ca-progress {
  height: 2px;
  background: rgba(26, 26, 26, 0.1);
  border-radius: 2px;
  margin-bottom: 8px;
  overflow: hidden;
}

.ca-progress-bar {
  height: 100%;
  background: var(--ghost-accent-color, #E84E1B);
  border-radius: 2px;
  transition: width 0.5s cubic-bezier(0.4, 0, 0.2, 1);
  width: 0%;
}

.ca-progress-label {
  font-family: var(--font2, 'Roboto', sans-serif);
  font-size: 0.625rem;
  letter-spacing: 0.06em;
  text-transform: uppercase;
  color: rgba(26, 26, 26, 0.3);
  font-weight: 500;
  margin-bottom: 28px;
}

/* --- Quiz Intro --- */
.ca-quiz-intro {
  margin-bottom: 32px;
  padding: 20px;
  background: rgba(26, 26, 26, 0.03);
  border-radius: 6px;
  border: 1px solid rgba(26, 26, 26, 0.08);
}

.ca-quiz-intro p {
  font-family: var(--font2, 'Roboto', sans-serif);
  font-size: 0.8125rem;
  line-height: 1.65;
  letter-spacing: normal;
  color: rgba(26, 26, 26, 0.55);
}

/* --- Question --- */
.ca-question {
  transition: opacity 0.3s ease, transform 0.3s ease;
}

.ca-question--enter {
  animation: ca-slide-up 0.4s cubic-bezier(0.4, 0, 0.2, 1) forwards;
}

@keyframes ca-slide-up {
  from { opacity: 0; transform: translateY(20px); }
  to { opacity: 1; transform: translateY(0); }
}

.ca-question-number {
  font-family: var(--font2, 'Roboto', sans-serif);
  font-size: 0.6875rem;
  font-weight: 600;
  letter-spacing: 0.02em;
  color: var(--ghost-accent-color, #E84E1B);
  margin-bottom: 6px;
}

.ca-question-title {
  font-family: var(--font2, 'Roboto', sans-serif);
  font-size: clamp(1rem, 2.5vw, 1.375rem);
  font-weight: 500;
  line-height: 1.35;
  letter-spacing: normal;
  color: #1a1a1a;
  margin-bottom: 12px;
}

.ca-question-context {
  font-family: var(--font2, 'Roboto', sans-serif);
  font-size: 0.8125rem;
  line-height: 1.7;
  letter-spacing: normal;
  color: rgba(26, 26, 26, 0.4);
  margin-bottom: 28px;
}

/* --- Options --- */
.ca-options {
  display: flex;
  flex-direction: column;
  gap: 10px;
}

.ca-option {
  display: flex;
  align-items: flex-start;
  gap: 14px;
  width: 100%;
  padding: 16px 18px;
  background: rgba(26, 26, 26, 0.03);
  border: 1px solid rgba(26, 26, 26, 0.1);
  border-radius: 6px;
  cursor: pointer;
  transition: all 0.25s cubic-bezier(0.4, 0, 0.2, 1);
  text-align: left;
  font-family: var(--font2, 'Roboto', sans-serif);
}

.ca-option:hover {
  border-color: rgba(26, 26, 26, 0.25);
  background: rgba(26, 26, 26, 0.06);
  transform: translateY(-1px);
}

.ca-option--selected {
  border-color: var(--ghost-accent-color, #E84E1B);
  background: rgba(232, 78, 27, 0.08);
  transform: scale(0.99);
}

.ca-option-letter {
  display: flex;
  align-items: center;
  justify-content: center;
  width: 26px;
  height: 26px;
  min-width: 26px;
  border-radius: 50%;
  background: rgba(26, 26, 26, 0.08);
  font-family: var(--font2, 'Roboto', sans-serif);
  font-size: 0.6875rem;
  font-weight: 700;
  letter-spacing: normal;
  color: rgba(26, 26, 26, 0.4);
  transition: all 0.25s ease;
}

.ca-option--selected .ca-option-letter {
  background: var(--ghost-accent-color, #E84E1B);
  color: #1a1a1a;
}

.ca-option-text {
  font-family: var(--font2, 'Roboto', sans-serif);
  font-size: 0.8125rem;
  line-height: 1.5;
  letter-spacing: normal;
  color: rgba(26, 26, 26, 0.65);
  padding-top: 3px;
}

.ca-option--selected .ca-option-text {
  color: rgba(26, 26, 26, 0.95);
}

/* --- Reflection --- */
.ca-reflection {
  padding-top: 60px;
  max-width: 720px;
  margin: 0 auto;
  text-align: center;
}

.ca-reflection-text {
  font-family: var(--font2, 'Roboto', sans-serif);
  font-size: 0.9375rem;
  line-height: 1.75;
  letter-spacing: normal;
  color: rgba(26, 26, 26, 0.55);
  margin-bottom: 16px;
}

.ca-reflection .ca-btn {
  margin-top: 24px;
}

/* --- Results --- */
.ca-results {
  padding-top: 40px;
}

.ca-results-title {
  font-family: var(--font1, 'Thunder', sans-serif);
  font-size: clamp(2rem, 6vw, 3.5rem);
  font-weight: 700;
  text-transform: uppercase;
  line-height: 0.95;
  letter-spacing: normal;
  color: #1a1a1a;
  margin-bottom: 32px;
}

/* Score visual */
.ca-score-visual {
  margin-bottom: 32px;
}

.ca-score-bar-track {
  position: relative;
  height: 4px;
  background: rgba(26, 26, 26, 0.1);
  border-radius: 4px;
  margin-bottom: 10px;
  overflow: visible;
}

.ca-score-bar-fill {
  height: 100%;
  background: var(--ghost-accent-color, #E84E1B);
  border-radius: 4px;
  width: 0%;
  transition: width 1.2s cubic-bezier(0.4, 0, 0.2, 1);
}

.ca-score-marker {
  position: absolute;
  top: 50%;
  left: 0%;
  transform: translate(-50%, -50%);
  width: 14px;
  height: 14px;
  background: var(--ghost-accent-color, #E84E1B);
  border: 3px solid #f5f3eb;
  border-radius: 50%;
  box-shadow: 0 2px 8px rgba(0, 0, 0, 0.3);
  transition: left 1.2s cubic-bezier(0.4, 0, 0.2, 1);
}

.ca-score-labels {
  display: flex;
  justify-content: space-between;
}

.ca-score-labels span {
  font-family: var(--font2, 'Roboto', sans-serif);
  font-size: 0.5625rem;
  text-transform: uppercase;
  letter-spacing: 0.06em;
  color: rgba(26, 26, 26, 0.3);
  font-weight: 500;
}

/* Result sections */
.ca-result-section {
  margin-bottom: 24px;
}

.ca-result-section p,
.ca-result-summary {
  font-family: var(--font2, 'Roboto', sans-serif);
  font-size: 0.875rem;
  line-height: 1.7;
  letter-spacing: normal;
  color: rgba(26, 26, 26, 0.55);
}

.ca-result-summary {
  font-size: 0.9375rem;
  color: rgba(26, 26, 26, 0.65);
}

.ca-result-heading {
  font-family: var(--font2, 'Roboto', sans-serif);
  font-size: 0.6875rem;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.06em;
  color: rgba(26, 26, 26, 0.4);
  margin-bottom: 6px;
}

.ca-results .ca-btn {
  margin-top: 20px;
}

/* --- Thank You --- */
.ca-thankyou {
  padding-top: 40px;
}

.ca-thankyou-text {
  margin-bottom: 32px;
}

.ca-thankyou-text p {
  font-family: var(--font2, 'Roboto', sans-serif);
  font-size: 0.875rem;
  line-height: 1.7;
  letter-spacing: normal;
  color: rgba(26, 26, 26, 0.55);
  margin-bottom: 12px;
}

.ca-sign-off {
  font-weight: 600;
  color: rgba(26, 26, 26, 0.75) !important;
  margin-top: 20px !important;
}

/* --- Email Box --- */
.ca-email-box {
  padding: 24px;
  background: rgba(26, 26, 26, 0.04);
  border: 1px solid rgba(26, 26, 26, 0.08);
  border-radius: 6px;
  margin-bottom: 40px;
}

.ca-email-box-title {
  font-family: var(--font2, 'Roboto', sans-serif);
  font-size: 0.875rem;
  font-weight: 600;
  letter-spacing: normal;
  color: #1a1a1a;
  margin-bottom: 4px;
}

.ca-email-box-desc {
  font-family: var(--font2, 'Roboto', sans-serif);
  font-size: 0.75rem;
  letter-spacing: normal;
  color: rgba(26, 26, 26, 0.35);
  margin-bottom: 14px;
  line-height: 1.5;
}

.ca-email-row {
  display: flex;
  gap: 10px;
}

.ca-email-input {
  flex: 1;
}

.ca-btn--send {
  width: auto;
  padding: 14px 24px;
  flex-shrink: 0;
}

.ca-email-status {
  font-family: var(--font2, 'Roboto', sans-serif);
  font-size: 0.6875rem;
  letter-spacing: normal;
  margin-top: 8px;
  line-height: 1.4;
}

.ca-email-status--success {
  color: #4ade80;
}

.ca-email-status--error {
  color: var(--ghost-accent-color, #E84E1B);
}

/* --- Links --- */
.ca-links {
  margin-top: 40px;
}

.ca-links-title {
  font-family: var(--font2, 'Roboto', sans-serif);
  font-size: 0.6875rem;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.06em;
  color: rgba(26, 26, 26, 0.4);
  margin-bottom: 14px;
}

.ca-links-subtitle {
  font-family: var(--font2, 'Roboto', sans-serif);
  font-size: 0.6875rem;
  font-weight: 500;
  letter-spacing: normal;
  color: rgba(26, 26, 26, 0.3);
  margin-top: 24px;
  margin-bottom: 10px;
}

.ca-link-card {
  display: block;
  padding: 16px 24px;
  background: var(--ghost-accent-color, #E84E1B);
  color: #1a1a1a;
  font-family: var(--font2, 'Roboto', sans-serif);
  font-size: 0.8125rem;
  font-weight: 600;
  letter-spacing: 0.02em;
  text-decoration: none;
  text-align: center;
  transition: opacity 0.2s ease;
}

.ca-link-card:hover {
  opacity: 0.88;
}

.ca-links-grid {
  display: flex;
  flex-direction: column;
  gap: 0;
}

.ca-link-item {
  display: flex;
  align-items: baseline;
  gap: 12px;
  padding: 12px 0;
  border-bottom: 1px solid rgba(26, 26, 26, 0.08);
  text-decoration: none;
  font-family: var(--font2, 'Roboto', sans-serif);
  font-size: 0.8125rem;
  font-weight: 500;
  letter-spacing: normal;
  color: rgba(26, 26, 26, 0.7);
  transition: color 0.2s ease;
}

.ca-link-item:hover {
  color: var(--ghost-accent-color, #E84E1B);
}

.ca-link-item span {
  font-weight: 400;
  font-size: 0.6875rem;
  color: rgba(26, 26, 26, 0.3);
}

/* --- Start Again --- */
.ca-start-again {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  font-family: var(--font2, 'Roboto', sans-serif);
  font-size: 0.75rem;
  font-weight: 400;
  letter-spacing: normal;
  color: rgba(26, 26, 26, 0.3);
  background: none;
  border: none;
  cursor: pointer;
  padding: 12px 0;
  margin-top: 12px;
  transition: color 0.2s ease;
}

.ca-start-again:hover {
  color: rgba(26, 26, 26, 0.55);
}

/* --- Responsive --- */
@media screen and (max-width: 640px) {
  .ca-screen {
    padding: 60px 0 80px;
  }

  .ca-container {
    padding: 0 20px;
  }

  .ca-option {
    padding: 14px 14px;
    gap: 12px;
  }

  .ca-option-letter {
    width: 22px;
    height: 22px;
    min-width: 22px;
    font-size: 0.625rem;
  }

  .ca-option-text {
    font-size: 0.75rem;
  }

  .ca-email-row {
    flex-direction: column;
  }

  .ca-btn--send {
    width: 100%;
  }

  .ca-reflection {
    padding-top: 40px;
    text-align: left;
  }
}
