/* Investor Sign-up */

.investor-signup {
  /* Validation red: a functional state colour with no brand variable yet. */
  --investor-signup-error: #d13b3b;

  position: relative;
  padding: 0;
  background: var(--white);
  color: var(--black);
}

/* Blue quote band with a diagonal lower edge, lower on the left. */
.investor-signup__quote-band {
  position: relative;
  padding: 56px 0 120px;
  background: var(--blue);
  color: var(--white);
  clip-path: polygon(0 0, 100% 0, 100% 72%, 0 100%);
}

/*
 * Quote type follows the theme's large-copy sizes (20px, then 28px and 32px
 * as .investor-info-copy). The form heading reuses .larger-heading at 35px;
 * labels, errors and consent text use the theme's 14px small-text size.
 */
.investor-signup__quote {
  max-width: 30em;
  margin: 0 auto;
  text-align: center;
  font-weight: 300;
  font-size: 20px;
  line-height: 1.4;
}

.investor-signup__quote p {
  margin: 0;
}

.investor-signup__attribution {
  margin-top: 16px;
  font-size: 16px;
  opacity: 0.85;
}

/* Two-column body pulled up into the band so the image overlaps the blue. */
.investor-signup__body {
  position: relative;
  z-index: 1;
}

.investor-signup--has-quote .investor-signup__body {
  margin-top: -56px;
}

.investor-signup__media-cell {
  order: 2;
  margin-top: 40px;
}

.investor-signup__form-cell {
  order: 1;
}

.investor-signup__image {
  display: block;
  width: 100%;
  max-width: 520px;
  height: auto;
}

.investor-signup__heading {
  margin: 0 0 24px;
  @media (max-width: 50em) {
    margin-top: 90px;
  }
}

/* Form */
.investor-signup__field {
  margin-bottom: 20px;
}

.investor-signup__label {
  display: flex;
  flex-wrap: wrap;
  align-items: baseline;
  justify-content: space-between;
  gap: 4px 12px;
  margin-bottom: 8px;
  font-size: 14px;
  font-weight: 600;
  line-height: 1.3;
  text-transform: uppercase;
}

.investor-signup__optional {
  font-weight: 400;
  text-transform: none;
  opacity: 0.7;
}

.investor-signup__error {
  font-size: 14px;
  font-weight: 400;
  text-transform: none;
  color: var(--investor-signup-error);
}

.investor-signup__error:empty {
  display: none;
}

.investor-signup__input,
.investor-signup__select {
  display: block;
  width: 100%;
  padding: 12px 14px;
  border: 1px solid var(--grey);
  border-radius: 3px;
  background: var(--white);
  color: var(--black);
  font: inherit;
  font-size: 16px;
  line-height: 1.3;
  transition:
    border-color 200ms ease,
    box-shadow 200ms ease;
}

.investor-signup__input::placeholder {
  color: var(--grey);
  opacity: 1;
}

.investor-signup__input:focus-visible,
.investor-signup__select:focus-visible {
  outline: none;
  border-color: var(--blue);
  box-shadow: 0 0 0 2px var(--light-blue);
}

.investor-signup__field.is-invalid .investor-signup__input,
.investor-signup__field.is-invalid .investor-signup__select {
  border-color: var(--investor-signup-error);
}

/* Select with the theme's blue chevron drawn in CSS. */
.investor-signup__select-wrap {
  position: relative;
  display: block;
}

.investor-signup__select {
  appearance: none;
  padding-right: 44px;
  cursor: pointer;
}

.investor-signup__select-wrap::after {
  content: '';
  position: absolute;
  top: 50%;
  right: 18px;
  width: 9px;
  height: 9px;
  border-right: 2px solid var(--blue);
  border-bottom: 2px solid var(--blue);
  transform: translateY(-70%) rotate(45deg);
  pointer-events: none;
}

/* Consent */
.investor-signup__consent {
  display: flex;
  align-items: flex-start;
  gap: 12px;
  margin: 24px 0 28px;
}

.investor-signup__checkbox {
  flex: 0 0 20px;
  width: 20px;
  height: 20px;
  margin: 2px 0 0;
  accent-color: var(--blue);
  cursor: pointer;
}

.investor-signup__consent-label {
  font-size: 14px;
  line-height: 1.5;
}

.investor-signup__consent-label p {
  margin: 0;
}

.investor-signup__consent-label a {
  font-weight: 600;
  text-decoration: underline;
}

.investor-signup__consent .investor-signup__error {
  display: block;
  margin-top: 6px;
}

.investor-signup__consent .investor-signup__error:empty {
  display: none;
}

/* Honeypot: off screen for people, present for bots. */
.investor-signup__honeypot {
  position: absolute;
  left: -9999px;
  width: 1px;
  height: 1px;
  overflow: hidden;
  opacity: 0;
}

/* Filled variant of the theme's .button, full width of the form. */
.investor-signup__submit {
  display: block;
  width: 100%;
  text-align: center;
  cursor: pointer;
  transition:
    background-color 0.2s ease,
    color 0.2s ease,
    opacity 0.2s ease;
}

.investor-signup__submit:disabled {
  opacity: 0.6;
  cursor: progress;
}

.investor-signup__form.is-complete .investor-signup__fields {
  opacity: 0.5;
}

.investor-signup__form.is-complete :disabled {
  cursor: not-allowed;
}

.investor-signup__status {
  margin: 16px 0 0;
  font-size: 14px;
  line-height: 1.5;
}

.investor-signup__status:empty {
  display: none;
}

.investor-signup__status.is-success {
  font-weight: 600;
  color: var(--blue);
}

.investor-signup__status.is-error {
  color: var(--investor-signup-error);
}

/* Medium and up */
@media print, screen and (min-width: 50em) {
  .investor-signup {
    padding-bottom: 0;
  }

  .investor-signup__quote-band {
    padding: 90px 0 180px;
    clip-path: polygon(0 0, 100% 0, 100% 60%, 0 100%);
  }

  .investor-signup__quote {
    font-size: 28px;
  }

  .investor-signup--has-quote .investor-signup__body {
    margin-top: -150px;
  }

  .investor-signup__media-cell {
    order: 1;
    margin-top: 0;
    align-self: flex-end;
  }

  .investor-signup__form-cell {
    order: 2;
    padding-top: 120px;
    padding-bottom: 64px;
  }

  .investor-signup__image {
    max-width: none;
  }

  .investor-signup__heading {
    margin-bottom: 32px;
  }
}

/* Large and up */
@media print, screen and (min-width: 64em) {
  .investor-signup__quote-band {
    padding: 110px 0 230px;
  }

  .investor-signup__quote {
    font-size: 32px;
  }

  .investor-signup--has-quote .investor-signup__body {
    margin-top: -210px;
  }

  .investor-signup__form-cell {
    padding-top: 180px;
    padding-bottom: 80px;
  }

  .investor-signup__video {
    position: relative;
    z-index: 1;
    transform: scale(1.22);
    transform-origin: bottom center;
  }
}

@media (prefers-reduced-motion: reduce) {
  .investor-signup__input,
  .investor-signup__select,
  .investor-signup__submit {
    transition: none;
  }
}
