/* ==========================================================================
   Itch Quiz Component
   Three views: Start → Quiz → Results
   ========================================================================== */

.itch-quiz {
  max-width: 780px;
  margin: 0 auto;
  padding: var(--space-8) var(--space-4);
}

.itch-quiz:has(.itch-quiz__quiz:not([hidden])) {
  max-width: 740px;
}

@media (min-width: 768px) {
  .itch-quiz {
    padding: var(--space-12) var(--space-4);
  }
}

/* ==========================================================================
   Start View
   ========================================================================== */

.itch-quiz__start {
  display: flex;
  flex-direction: column;
  align-items: center;
  text-align: center;
  gap: var(--space-4);
}

.itch-quiz__start-graphic {
  margin-bottom: var(--space-2);
}

.itch-quiz__start-graphic-img {
  width: 120px;
  height: auto;
}

.itch-quiz__start-heading {
  color: var(--Branded-Blue-dark, #003A70);
  text-align: center;
  font-feature-settings: 'liga' off, 'clig' off;
  font-family: Outfit, sans-serif;
  font-size: 24px;
  font-style: normal;
  font-weight: 700;
  line-height: 120%;
  margin: 0;
}

.itch-quiz__start-description {
  color: var(--Neutral-Almost-black, #313131);
  text-align: center;
  font-feature-settings: 'liga' off, 'clig' off;
  font-family: Outfit, sans-serif;
  font-size: 18px;
  font-style: normal;
  font-weight: 400;
  line-height: 120%;
  margin: 0;
  max-width: 750px;
}

.itch-quiz__start-btn {
  min-width: 138px;
  margin-top: var(--space-2);
}

.itch-quiz__back-btn {
  padding-left: 0;
  padding-right: 0;
}

.itch-quiz__next-btn {
  min-width: 162px;
  gap: 20px;
  padding: 13px 12px 10px 40px;
}

.itch-quiz__quiz {
  min-height: 462px;
  display: grid;
  grid-auto-rows: max-content max-content max-content 1fr max-content;
}

.itch-quiz__nav:has(.itch-quiz__back-btn[hidden]) {
  margin-left: auto;
}

@media screen and (max-width: 767px) {
  .itch-quiz__quiz:has(.itch-quiz__back-btn:not([hidden])) {
    min-height: 512px;
  }
}

.itch-quiz__support-btn.lm-btn--lg {
  padding: 13px 24px 10px 24px;
}

@media screen and (min-width: 768px) {
  .itch-quiz__quiz {
    min-height: 410px;
  }
}

/* ==========================================================================
   Quiz View — Progress
   ========================================================================== */

.itch-quiz__progress {
  display: flex;
  justify-content: space-between;
  align-items: baseline;
  margin-bottom: var(--space-2);
}

.itch-quiz__progress-label {
  color: #717182;
  font-family: Outfit, sans-serif;
  font-size: 16px;
  font-style: normal;
  font-weight: 400;
  line-height: 24px;
  letter-spacing: -0.312px;
}

.itch-quiz__progress-pct {
  color: #717182;
  font-family: Outfit, sans-serif;
  font-size: 16px;
  font-style: normal;
  font-weight: 400;
  line-height: 24px;
  letter-spacing: -0.312px;
}

.itch-quiz__progress-bar {
  width: 100%;
  height: 6px;
  background: #E0E7EF;
  border-radius: 3px;
  overflow: hidden;
  margin-bottom: var(--space-6);
}

.itch-quiz__progress-fill {
  height: 100%;
  background: #003A70;
  border-radius: 3px;
  transition: width 300ms ease;
}

/* ==========================================================================
   Quiz View — Question & Choices
   ========================================================================== */

.itch-quiz__question {
  color: var(--Branded-Blue-dark, #003A70);
  text-align: left;
  font-feature-settings: 'liga' off, 'clig' off;
  font-family: Outfit, sans-serif;
  font-size: 18px;
  font-style: normal;
  font-weight: 600;
  line-height: 120%;
  margin: 0 0 var(--space-5);
}

.itch-quiz__choices {
  display: flex;
  flex-direction: column;
  gap: var(--space-3);
  margin-bottom: var(--space-6);
  text-align: left;
}

@media screen and (max-width: 599px) {
  .itch-quiz__choices {
     margin-bottom: 8px;
     gap: var(--space-2);
  }
}

.itch-quiz__choice {
  display: flex;
  padding: 0 15.998px;
  align-items: center;
  gap: 11.997px;
  min-height: 60px;
  background: #EBF9FE;
  border-radius: 10px;
  border: 0.556px solid #8C8C8C;
  cursor: pointer;
  transition: border-color 150ms ease, background-color 150ms ease;
  color: var(--Neutral-Almost-black, #313131);
  font-feature-settings: 'liga' off, 'clig' off;
  font-family: Outfit, sans-serif;
  font-size: 18px;
  font-style: normal;
  font-weight: 400;
  line-height: 120%;
  text-align: left;
}

.itch-quiz__choice:hover {
  border-color: #003A70;
}

.itch-quiz__choice.is-selected {
  border-color: #003A70;
  background: #D6E8F5;
}

@media screen and (min-width: 768px) {
  .itch-quiz__choice {
    min-height: 48px;
  }
}

.itch-quiz__choice-radio {
  flex-shrink: 0;
  width: 16px;
  height: 16px;
  border-radius: 18641400px;
  border: 0.556px solid #8C8C8C;
  background: #FFF;
  box-shadow: 0 1px 2px 0 rgba(0, 0, 0, 0.05);
  display: flex;
  align-items: center;
  justify-content: center;
  transition: border-color 150ms ease;
}

.itch-quiz__choice.is-selected .itch-quiz__choice-radio {
  border-color: #003A70;
  border-width: 1px;
}

.itch-quiz__choice.is-selected .itch-quiz__choice-radio::after {
  content: '';
  width: 8px;
  height: 8px;
  border-radius: 50%;
  background: #003A70;
}

.itch-quiz__choice-text {
  flex: 1;
}

/* .itch-quiz .lm-btn__label {
  margin-bottom: 0;
} */

/* ==========================================================================
   Quiz View — Navigation
   ========================================================================== */

.itch-quiz__nav {
  display: flex;
  justify-content: space-between;
  align-items: center;
}

.itch-quiz__back-btn {
  color: #003A70;
}

/* .itch-quiz__nav {
  margin-left: auto;
} */

.itch-quiz__next-btn:disabled {
  opacity: 0.4;
  cursor: not-allowed;
}

@media screen and (max-width: 599px) {
  .itch-quiz__nav {
    flex-direction: column-reverse;
    justify-items: center;
    margin-left: auto;
    margin-right: auto;
  }
}

/* ==========================================================================
   Results View
   ========================================================================== */

.itch-quiz__results-header {
  display: flex;
  gap: var(--space-5);
  align-items: flex-start;
  margin-bottom: var(--space-6);
}

@media screen and (max-width: 599px) {
  .itch-quiz__results-header {
    flex-direction: column;
  }
  .itch-quiz__results-subheading {
    text-align: left;
  }
}

.itch-quiz__results-graphic {
  flex-shrink: 0;
}

.itch-quiz__results-graphic-img {
  width: 126px;
  height: 126px;
  flex-shrink: 0;
}

.itch-quiz__results-heading {
  color: var(--Branded-Blue-dark, #003A70);
  font-feature-settings: 'liga' off, 'clig' off;
  font-family: Outfit, sans-serif;
  font-size: 20px;
  font-style: normal;
  font-weight: 600;
  line-height: 120%;
  margin: 0 0 var(--space-3);
}

.itch-quiz__results-body {
  color: var(--Neutral-Almost-black, #313131);
  font-family: Outfit, sans-serif;
  font-size: 18px;
  font-weight: 400;
  line-height: 140%;
  margin: 0;
}

.itch-quiz__results-body strong {
  font-weight: 700;
}

.itch-quiz__results-subheading {
  color: var(--Neutral-Almost-black, #313131);
  text-align: center;
  font-feature-settings: 'liga' off, 'clig' off;
  font-family: Outfit, sans-serif;
  font-size: 18px;
  font-style: normal;
  font-weight: 600;
  line-height: 120%;
  margin: 0 0 var(--space-4);
}

.itch-quiz__results-questions {
  display: grid;
  grid-template-columns: 1fr;
  gap: var(--space-2);
  margin-bottom: var(--space-8);
}

@media (min-width: 600px) {
  .itch-quiz__results-questions {
    grid-template-columns: 1fr 1fr;
  }
}

.itch-quiz__results-card {
  display: flex;
  padding: 8px 20px;
  justify-content: center;
  align-items: center;
  gap: 10px;
  flex: 1 0 0;
  align-self: stretch;
  background: #EBF9FE;
  /* border: 2px solid #D6E8F5; */
  border-radius: 12px;
  color: var(--Neutral-Almost-black, #313131);
  font-feature-settings: 'liga' off, 'clig' off;
  font-family: Outfit, sans-serif;
  font-size: 18px;
  font-style: normal;
  font-weight: 400;
  line-height: 120%;
}

.itch-quiz__results-actions {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: var(--space-6);
  flex-wrap: wrap;
}

@media (max-width: 599px) {
  .itch-quiz__results-actions {
    flex-direction: column-reverse;
    gap: 10px;
  }
}

.itch-quiz__retake-btn {
  color: #003A70;

  .lm-btn__icon {
    margin-bottom: var(--space-1);
  }
}
