/* Assuréo questionnaire and typeform layout. */

.assureo-form {
  width: 100%;
}

.assureo-form-layout {
  display: grid;
  grid-template-columns: minmax(0, 1fr) 315px;
  gap: 22px;
  align-items: start;
  min-width: 0;
}

.assureo-form-card,
.assureo-summary-card {
  min-width: 0;
  border: 1px solid rgba(255, 255, 255, .9);
  border-radius: 27px;
  background: rgba(255, 255, 255, .96);
  box-shadow: var(--assureo-shadow);
}

.assureo-form-card {
  min-height: 500px;
  padding: 37px 40px 40px;
}

.assureo-summary-card {
  position: sticky;
  top: 20px;
  min-height: 210px;
  padding: 30px 28px;
}

.assureo-progress-row {
  display: flex;
  align-items: center;
  gap: 18px;
  margin-bottom: 36px;
}

.assureo-progress {
  position: relative;
  flex: 1;
  height: 20px;
  overflow: hidden;
  border-radius: 99px;
  background: #f0f3f7;
}

.assureo-progress-fill {
  display: block;
  width: 8.3333%;
  height: 100%;
  border-radius: inherit;
  background: var(--assureo-navy);
  transition: width .3s ease;
}

.assureo-step-count {
  flex: 0 0 auto;
  font-size: 16px;
  font-weight: 700;
  white-space: nowrap;
}

.assureo-step {
  display: none;
  min-width: 0;
}

.assureo-step.is-active {
  display: block;
  animation: assureo-step-in .25s ease both;
}

@keyframes assureo-step-in {
  from { opacity: 0; transform: translateX(8px); }
  to { opacity: 1; transform: translateX(0); }
}

.assureo-step-heading {
  margin-bottom: 26px;
}

.assureo-step-heading--compact {
  margin: 24px 0 12px;
}

.assureo-step-heading h2,
.assureo-step-heading h3 {
  margin: 0;
  color: var(--assureo-navy);
  font-weight: 700;
  letter-spacing: -.025em;
}

.assureo-step-heading h2 {
  font-size: clamp(25px, 2vw, 31px);
}

.assureo-step-heading h3 {
  font-size: 21px;
}

.assureo-back {
  display: inline-block;
  margin: -8px 0 19px;
  padding: 0;
  border: 0;
  background: transparent;
  color: var(--assureo-muted);
  font-size: 14px;
  font-weight: 500;
}

.assureo-choice-list,
.assureo-choice-grid {
  display: grid;
  gap: 14px;
}

.assureo-choice-grid--two {
  grid-template-columns: repeat(2, minmax(0, 1fr));
}

.assureo-choice-card,
.assureo-chip,
.assureo-choice-dropdown-toggle {
  display: flex;
  align-items: center;
  min-height: 64px;
  border: 1px solid var(--assureo-border);
  border-radius: 15px;
  background: var(--assureo-white);
  color: var(--assureo-navy);
  font-size: 16px;
  font-weight: 500;
  text-align: left;
  cursor: pointer;
  transition: border-color .2s ease, background-color .2s ease, box-shadow .2s ease, transform .2s ease;
}

.assureo-choice-input {
  position: absolute;
  width: 1px;
  height: 1px;
  margin: -1px;
  padding: 0;
  overflow: hidden;
  border: 0;
  clip: rect(0 0 0 0);
  clip-path: inset(50%);
  white-space: nowrap;
}

.assureo-choice-card,
.assureo-choice-dropdown-toggle {
  gap: 13px;
  width: 100%;
  padding: 12px 17px;
}

.assureo-choice-card:hover,
.assureo-choice-card.is-selected,
.assureo-chip:hover,
.assureo-chip.is-selected,
.assureo-choice-dropdown-toggle:hover,
.assureo-choice-dropdown-toggle.is-selected,
.assureo-choice-dropdown-toggle[aria-expanded="true"] {
  border-color: var(--assureo-navy);
  background: #f5f8fc;
  box-shadow: inset 0 0 0 1px var(--assureo-navy);
}

.assureo-choice-input:focus-visible + .assureo-radio {
  outline: 3px solid rgba(226, 29, 42, .3);
  outline-offset: 3px;
}

.assureo-choice-arrow {
  margin-left: auto;
  color: #9ca5b2;
  font-size: 20px;
}

.assureo-radio {
  display: inline-block;
  flex: 0 0 24px;
  width: 24px;
  height: 24px;
  border: 2px solid #9299a1;
  border-radius: 50%;
  background: transparent;
}

.assureo-choice-card:not(.is-selected):hover .assureo-radio,
.assureo-chip:not(.is-selected):hover .assureo-radio,
.assureo-choice-dropdown-toggle:not(.is-selected):hover .assureo-radio {
  border-color: var(--assureo-navy);
}

.is-selected .assureo-radio {
  border-color: var(--assureo-navy);
  box-shadow: inset 0 0 0 5px var(--assureo-white);
  background: var(--assureo-navy);
}

.assureo-form-card > .assureo-button,
.assureo-step > .assureo-button {
  margin-top: 28px;
}

.assureo-range-value {
  margin: -2px 0 22px;
}

.assureo-range-value output {
  display: inline-block;
  border-bottom: 2px solid var(--assureo-red);
  color: var(--assureo-navy);
  font-size: clamp(40px, 5vw, 58px);
  font-weight: 700;
  letter-spacing: -.045em;
  line-height: 1.1;
}

.assureo-range {
  width: 100%;
  height: 8px;
  margin: 15px 0 10px;
  accent-color: var(--assureo-red);
  cursor: pointer;
  -webkit-appearance: none;
  appearance: none;
  background: transparent;
}

.assureo-range::-webkit-slider-runnable-track {
  height: 8px;
  border-radius: 99px;
  background: linear-gradient(90deg, var(--assureo-navy) 0%, var(--assureo-navy) var(--range-progress, 30%), #dedfe1 var(--range-progress, 30%), #dedfe1 100%);
}

.assureo-range::-webkit-slider-thumb {
  width: 30px;
  height: 30px;
  margin-top: -11px;
  border: 0;
  border-radius: 50%;
  background: var(--assureo-red);
  -webkit-appearance: none;
  appearance: none;
  box-sizing: border-box;
}

.assureo-range::-moz-range-track {
  height: 8px;
  border-radius: 99px;
  background: #dedfe1;
}

.assureo-range::-moz-range-progress {
  height: 8px;
  border-radius: 99px;
  background: var(--assureo-navy);
}

.assureo-range::-moz-range-thumb {
  width: 30px;
  height: 30px;
  border: 0;
  border-radius: 50%;
  background: var(--assureo-red);
  box-sizing: border-box;
}

.assureo-range-labels {
  display: flex;
  justify-content: space-between;
  margin-top: 12px;
  color: var(--assureo-navy);
  font-size: 16px;
}

.assureo-fieldset {
  min-width: 0;
  margin: 0;
  padding: 0;
  border: 0;
}

.assureo-field-label {
  display: block;
  margin-bottom: 7px;
  color: var(--assureo-navy);
  font-size: 14px;
  font-weight: 500;
}

.assureo-text-input {
  display: block;
  width: 100%;
  min-height: 45px;
  padding: 10px 13px;
  border: 1px solid #aeb8c8;
  border-radius: 9px;
  background: var(--assureo-white);
  color: var(--assureo-navy);
  outline: none;
  transition: border-color .2s ease, box-shadow .2s ease;
}

.assureo-text-input:focus {
  border-color: var(--assureo-navy);
  box-shadow: 0 0 0 3px rgba(6, 29, 80, .1);
}

.assureo-text-input::placeholder {
  color: #9ca2aa;
}

.assureo-chip-grid {
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
}

.assureo-chip {
  min-height: 48px;
  padding: 9px 14px;
  border-radius: 13px;
  gap: 9px;
}

.assureo-chip .assureo-radio {
  flex-basis: 20px;
  width: 20px;
  height: 20px;
}

.assureo-chip.is-selected .assureo-radio {
  box-shadow: inset 0 0 0 4px var(--assureo-white);
}

.assureo-contact-grid {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 16px;
  margin-top: 20px;
}

.assureo-field .assureo-field-label {
  margin-bottom: 6px;
}

.assureo-consent {
  position: relative;
  display: flex;
  align-items: flex-start;
  gap: 9px;
  margin: 20px 0 0;
  color: var(--assureo-muted);
  font-size: 12px;
  cursor: pointer;
}

.assureo-consent input {
  position: absolute;
  width: 1px;
  height: 1px;
  opacity: 0;
}

.assureo-checkbox {
  display: inline-flex;
  flex: 0 0 16px;
  align-items: center;
  justify-content: center;
  width: 16px;
  height: 16px;
  border: 1px solid var(--assureo-navy);
  border-radius: 4px;
}

.assureo-consent input:checked + .assureo-checkbox::after {
  color: var(--assureo-red);
  content: "✓";
  font-size: 13px;
  font-weight: 700;
}

.assureo-consent a {
  color: var(--assureo-navy);
  font-weight: 500;
}

.assureo-form-error {
    min-height: 18px;
    margin: 10px 0 0;
  color: var(--assureo-red);
  font-size: 13px;
    font-weight: 500;
}

.assureo-field-error {
  display: block;
  margin: 5px 0 0;
  color: var(--assureo-red);
  font-size: 12px;
  line-height: 1.25;
  font-weight: 500;
}

.assureo-step-field-grid--stable-errors {
  align-items: start;
}

.assureo-step-field-grid--stable-errors > .assureo-field {
  display: block;
}

.assureo-step-field-grid--stable-errors .assureo-field-label {
  min-height: 2.6em;
}

.assureo-field-error-slot {
  display: block;
  min-height: 15px;
  margin-top: 5px;
}

.assureo-field-error-slot .assureo-field-error {
  margin-top: 0;
}

.assureo-credit-fields {
  gap: 18px;
}

.assureo-credit-fields .assureo-field-label {
  min-height: 0;
}

.assureo-credit-fields .assureo-repayment-question {
  font-size: 18px;
  font-weight: 700;
  line-height: 1.35;
}

.assureo-repayment-hint {
  margin: 2px 0 18px;
  color: var(--assureo-muted);
  font-size: 14px;
}

.assureo-repayment-date-grid {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 16px;
}

.assureo-repayment-date-grid .assureo-field-label {
  font-weight: 700;
}

.assureo-step-select-wrap {
  max-width: 560px;
}

.assureo-choice-dropdown {
  position: relative;
  width: 100%;
}

.assureo-choice-dropdown-toggle {
  font-family: inherit;
}

.assureo-choice-dropdown-toggle::after {
  display: none;
}

.assureo-choice-dropdown-toggle[aria-invalid="true"] {
  border-color: var(--assureo-red);
  box-shadow: inset 0 0 0 1px var(--assureo-red);
}

.assureo-choice-dropdown-label {
  flex: 1 1 auto;
  min-width: 0;
}

.assureo-choice-dropdown-label.is-placeholder {
  color: var(--assureo-muted);
}

.assureo-choice-dropdown-indicator {
  flex: 0 0 10px;
  width: 10px;
  height: 10px;
  margin: 0 5px 5px auto;
  border-right: 2px solid currentColor;
  border-bottom: 2px solid currentColor;
  transform: rotate(45deg);
}

.assureo-choice-dropdown-toggle[aria-expanded="true"] .assureo-choice-dropdown-indicator {
  margin-top: 5px;
  margin-bottom: 0;
  transform: rotate(225deg);
}

.assureo-choice-dropdown-menu {
  width: 100%;
  min-width: 100%;
  max-height: min(220px, calc(100dvh - 120px));
  overflow-y: auto;
  padding: 5px 0;
  border: 1px solid var(--assureo-border);
  border-radius: 3px;
  background: var(--assureo-white);
  box-shadow: 0 10px 24px rgba(6, 29, 80, .15);
}

.assureo-choice-dropdown-option {
  width: 100%;
  padding: 10px 12px;
  color: var(--assureo-navy);
  font-size: 15px;
  text-align: left;
  white-space: normal;
}

.assureo-choice-dropdown-option:hover,
.assureo-choice-dropdown-option:focus,
.assureo-choice-dropdown-option[aria-checked="true"] {
  background: var(--assureo-navy);
  color: var(--assureo-white);
}

.assureo-choice-dropdown-option:focus-visible {
  outline: 2px solid var(--assureo-red);
  outline-offset: -2px;
}

.assureo-choice-dropdown-error {
  min-height: 18px;
  margin: 8px 0 0;
}

.assureo-date-dropdown .assureo-choice-dropdown-toggle {
  min-height: 52px;
  padding: 10px 13px;
  border-radius: 9px;
  background: var(--assureo-white);
  box-shadow: none;
  font-weight: 400;
}

.assureo-date-dropdown .assureo-choice-dropdown-toggle:hover,
.assureo-date-dropdown .assureo-choice-dropdown-toggle.is-selected,
.assureo-date-dropdown .assureo-choice-dropdown-toggle[aria-expanded="true"] {
  border-color: var(--assureo-navy);
  background: var(--assureo-white);
  box-shadow: none;
}

.assureo-date-dropdown .assureo-choice-dropdown-toggle[aria-invalid="true"] {
  border-color: var(--assureo-red);
  box-shadow: inset 0 0 0 1px var(--assureo-red);
}

.assureo-field-error--consent {
  margin-top: 6px;
}

.assureo-summary-heading {
  display: flex;
  align-items: flex-start;
  flex-direction: column;
  gap: 10px;
  margin-bottom: 16px;
}

.assureo-summary-heading h2 {
  margin: 0;
  font-size: 27px;
  font-weight: 700;
  letter-spacing: -.03em;
}

.assureo-summary-heading span {
  display: block;
  width: 78%;
  height: 4px;
  border-radius: 99px;
  background: var(--assureo-red);
}

.assureo-summary-empty {
  margin: 0;
  color: var(--assureo-muted);
  font-size: 14px;
}

.assureo-summary-row {
  display: flex;
  justify-content: space-between;
  gap: 15px;
  padding: 12px 0;
  border-bottom: 1px solid #eceef1;
  font-size: 13px;
}

.assureo-summary-row span:first-child {
  color: var(--assureo-muted);
}

.assureo-summary-row strong {
  max-width: 58%;
  min-width: 0;
  color: var(--assureo-navy);
  font-weight: 700;
  overflow-wrap: anywhere;
  text-align: right;
}

.assureo-typeform-page {
  min-height: calc(100vh - 85px);
  padding-top: 0;
  background: #F4F7FB;
}

.assureo-typeform-page .assureo-button {
  font-weight: 700;
}

.assureo-typeform-header {
  display: flex;
  align-items: center;
  justify-content: center;
  min-height: 70px;
  background: var(--assureo-white);
}

.assureo-typeform-header .assureo-brand img {
  display: block;
  width: 191px;
  padding: 10px;
  height: auto;
} 
.assureo-typeform-content {
  width: min(1270px, calc(100% - 64px));
  min-height: 780px;
  min-width: 0;
  margin: 0 auto;
  padding: 108px 0 130px;
}

.assureo-typeform-content .assureo-form-layout {
  grid-template-columns: minmax(0, 856px) minmax(330px, 1fr);
  gap: 24px;
}

.assureo-typeform-content .assureo-form-card {
  min-height: 500px;
  padding: 39px 40px 38px;
}

.assureo-typeform-content .assureo-summary-card {
  min-height: 180px;
}

@media (max-width: 1180px) {
  .assureo-form-card {
      padding-right: 28px;
      padding-left: 28px;
    }

  .assureo-typeform-content {
      width: min(calc(100% - 40px), 1000px);
    }

  .assureo-typeform-content .assureo-form-layout {
      grid-template-columns: minmax(0, 1fr) 315px;
    }
}

@media (max-width: 900px) {
  .assureo-form-shell {
      margin-top: 28px;
    }

  .assureo-form-layout {
      grid-template-columns: 1fr;
    }

  .assureo-summary-card {
      position: static;
    }

  .assureo-typeform-content {
      width: calc(100% - 32px);
      max-width: 720px;
      min-height: 0;
      padding: 54px 0 75px;
    }

  .assureo-typeform-content .assureo-form-layout {
      grid-template-columns: 1fr;
    }
}

@media (max-width: 600px) {
  .assureo-form-card,
    .assureo-summary-card {
      border-radius: 20px;
    }

  .assureo-form-card {
      padding: 24px 18px 25px;
    }

  .assureo-progress-row {
      gap: 10px;
      margin-bottom: 26px;
    }

  .assureo-progress {
      height: 13px;
    }

  .assureo-step-count {
      font-size: 13px;
    }

  .assureo-step-heading h2 {
      font-size: 24px;
      overflow-wrap: anywhere;
    }

  .assureo-choice-grid--two, .assureo-contact-grid {
      grid-template-columns: 1fr;
    }

  .assureo-choice-card,
  .assureo-choice-dropdown-toggle {
      min-height: 56px;
      padding: 10px 13px;
      font-size: 14px;
    }

  .assureo-range-value output {
      font-size: 42px;
    }

  .assureo-typeform-header {
      min-height: 84px;
    }

  .assureo-typeform-content {
      width: calc(100% - 24px);
      max-width: 520px;
      padding-top: 34px;
    }

  .assureo-typeform-content .assureo-form-card {
      padding: 24px 18px 25px;
    }
}


.assureo-choice-card:focus-visible,
.assureo-chip:focus-visible,
.assureo-choice-dropdown-toggle:focus-visible,
.assureo-back:focus-visible {
  outline: 3px solid rgba(226, 29, 42, .3);
  outline-offset: 3px;
}

.assureo-step-field-grid {
  display: grid;
  gap: 18px;
  min-width: 0;
  align-items: end;
}

.assureo-step-field-grid--single {
  grid-template-columns: minmax(0, 1fr);
}

.assureo-step-field-grid--three {
  grid-template-columns: repeat(3, minmax(0, 1fr));
}

.assureo-step-field-grid--two {
  grid-template-columns: repeat(2, minmax(0, 1fr));
}

.assureo-input-with-suffix {
  position: relative;
  display: block;
}

.assureo-input-with-suffix .assureo-text-input {
  padding-right: 42px;
}

.assureo-input-with-suffix > span {
  position: absolute;
  top: 50%;
  right: 14px;
  color: var(--assureo-navy);
  font-weight: 700;
  pointer-events: none;
  transform: translateY(-50%);
}

.assureo-address-grid {
  display: grid;
  grid-template-columns: minmax(0, 1fr);
  gap: 16px;
  margin-top: 20px;
  min-width: 0;
}

.assureo-address-grid__street {
  grid-column: 1 / -1;
}

.assureo-manual-address {
  display: grid;
  gap: 12px;
}

.assureo-address-note {
  margin: 0;
  color: var(--assureo-muted);
  font-size: 13px;
}

.input-container, .input-container div.autocomplete-icon { 
  color: var(--assureo-navy) !important; 
}

.assureo-places-host gmp-place-autocomplete {
  display: block;
  width: 100%;
  min-height: 45px;
  border: 1px solid #aeb8c8;
  border-radius: 9px;
  background: var(--assureo-white); 
  color: light-dark(var(--assureo-navy), #9ca2aa);
  font-family: inherit;
  font-size: 16px;
}

.assureo-places-host gmp-place-autocomplete:focus-within {
  border-color: var(--assureo-navy);
  box-shadow: 0 0 0 3px rgba(6, 29, 80, .1);
}

.assureo-consent-fieldset {
  margin-top: 20px;
}

.assureo-consent-fieldset .assureo-field-label {
  margin-bottom: 10px;
}

.assureo-consent-fieldset a {
  color: var(--assureo-navy);
  font-weight: 500;
}

.assureo-consent-fieldset .assureo-field-error {
  margin-top: 7px;
}

.assureo-required-consent {
  display: flex;
  align-items: flex-start;
  gap: 12px;
  padding: 16px;
  border: 1px solid #d6e4ff;
  border-radius: 12px;
  background: #f5f8ff;
  color: var(--assureo-navy);
  font-size: 15px;
  line-height: 1.5;
  cursor: pointer;
}

.assureo-required-consent input,
.assureo-optional-consent input {
  flex: 0 0 20px;
  width: 20px;
  height: 20px;
  margin: 2px 0 0;
  accent-color: var(--assureo-navy);
}

.assureo-required-consent a,
.assureo-optional-consent a {
  color: #2768e8;
  text-decoration: underline;
}

.assureo-optional-consents {
  margin-top: 10px;
  border-top: 1px solid var(--assureo-border);
}

.assureo-optional-consent {
  display: grid;
  grid-template-columns: 20px minmax(0, 1fr) auto;
  gap: 14px;
  align-items: start;
  padding: 16px 2px;
  border-bottom: 1px solid var(--assureo-border);
  color: var(--assureo-navy);
  cursor: pointer;
}

.assureo-optional-consent__copy {
  display: grid;
  gap: 5px;
  min-width: 0;
  font-size: 15px;
  line-height: 1.45;
}

.assureo-optional-consent__copy strong {
  font-weight: 500;
}

.assureo-optional-consent__copy small {
  color: var(--assureo-muted);
  font-size: 13px;
}

.assureo-optional-consent__badge {
  padding: 5px 10px;
  border-radius: 9px;
  background: #f0f3f7;
  color: var(--assureo-muted);
  font-size: 12px;
  white-space: nowrap;
}

@media (max-width: 600px) {
  .assureo-step-field-grid--three,
  .assureo-step-field-grid--two {
    grid-template-columns: 1fr;
  }

  .assureo-step-field-grid--stable-errors .assureo-field-label {
    min-height: 0;
  }

  .assureo-field-error-slot {
    min-height: 15px;
  }

  .assureo-optional-consent {
    grid-template-columns: 20px minmax(0, 1fr);
  }

  .assureo-optional-consent__badge {
    grid-column: 2;
    justify-self: start;
  }

  .assureo-address-grid {
    grid-template-columns: 1fr;
  }
}

@media (max-width: 900px) {
  .assureo-step-field-grid--three {
    grid-template-columns: 1fr;
  }
}
