/**
 * @file
 * Webform SDC — Request a Rep field styling (Figma 29999:57037–57040).
 *
 * Layout (1440 / gutters / centering) is the container's job, same as
 * study-card, text-wysiwyg, etc. This file only caps the form column at
 * 802px — measured on node 29418:173440.
 */

.sdc-webform--request-a-rep {
  width: 100%;
  max-width: 802px;
  margin-inline: auto;
  --field-narrow: 240px;
  --color-required: #d00;
}

.sdc-webform--request-a-rep .webform-submission-request-a-rep-form {
  display: flex;
  flex-direction: column;
  gap: var(--space-lg);
}

.sdc-webform--request-a-rep .mt-0 {
  margin: 0;
  font-size: var(--fs-16);
  color: var(--color-charcoal);
}

.sdc-webform--request-a-rep .red-text,
.sdc-webform--request-a-rep label span {
  color: var(--color-required);
}

.sdc-webform--request-a-rep .webform-submission-request-a-rep-form > .form-wrapper,
.sdc-webform--request-a-rep .webform-submission-request-a-rep-form > .js-form-wrapper {
  display: flex;
  flex-direction: column;
  gap: var(--space-lg);
  margin: 0;
  width: 100%;
}

.sdc-webform--request-a-rep .form-item,
.sdc-webform--request-a-rep .js-form-item {
  display: flex;
  flex-direction: column;
  gap: var(--space-sm);
  margin: 0;
}

/* The 240px cap belongs to the input, not the field: Figma lets the label run
   past the input's right edge (node I29999:57039;29418:173459). */
.sdc-webform--request-a-rep .form-item-phone-number input,
.sdc-webform--request-a-rep .form-item-zip-code input,
.sdc-webform--request-a-rep .form-item-npi input {
  max-width: var(--field-narrow);
}

.sdc-webform--request-a-rep label,
.sdc-webform--request-a-rep legend {
  font-family: var(--font-agenda);
  font-size: var(--fs-20);
  font-weight: var(--font-weight-normal);
  line-height: var(--line-height-body);
  color: var(--color-steel);
  margin: 0;
}

.sdc-webform--request-a-rep input[type="text"],
.sdc-webform--request-a-rep input[type="email"],
.sdc-webform--request-a-rep input[type="tel"],
.sdc-webform--request-a-rep input[type="number"] {
  box-sizing: border-box;
  width: 100%;
  height: 44px;
  padding: 12px 16px;
  border: 1px solid var(--color-steel);
  border-radius: 8px;
  background: var(--color-white);
  font-family: var(--font-agenda);
  font-size: var(--fs-20);
  line-height: var(--line-height-body);
  color: var(--color-charcoal);
}

.sdc-webform--request-a-rep select {
  box-sizing: border-box;
  width: 100%;
  height: 44px;
  padding: 11px 40px 11px 16px;
  border: 1px solid var(--color-steel);
  border-radius: 8px;
  background-color: var(--color-white);
  background-image: url(../../images/icons/select-down.svg);
  background-repeat: no-repeat;
  background-position: right 12px center;
  background-size: 24px 24px;
  font-family: var(--font-agenda);
  font-size: var(--fs-20);
  line-height: normal;
  color: var(--color-charcoal);
  appearance: none;
  cursor: pointer;
}

.sdc-webform--request-a-rep input:focus,
.sdc-webform--request-a-rep select:focus {
  outline: none;
  border-color: var(--color-nav-active);
}

.sdc-webform--request-a-rep input:focus-visible,
.sdc-webform--request-a-rep select:focus-visible {
  outline: 3px solid var(--color-nav-active);
  outline-offset: 2px;
}

.sdc-webform--request-a-rep .form-item--error input,
.sdc-webform--request-a-rep .form-item--error select,
.sdc-webform--request-a-rep input.error,
.sdc-webform--request-a-rep select.error {
  border-color: var(--color-required);
}

.sdc-webform--request-a-rep .form-item--error-message,
.sdc-webform--request-a-rep .form-item--error-message strong,
.sdc-webform--request-a-rep strong.error {
  font-size: var(--fs-16);
  color: var(--color-required);
}

.sdc-webform--request-a-rep .form-item-receive-updates {
  flex-direction: row;
  align-items: center;
  gap: 10px;
  max-width: none;
  margin-top: var(--space-lg);
}

.sdc-webform--request-a-rep .form-item-receive-updates label {
  flex: 1;
  color: var(--color-charcoal);
}

.sdc-webform--request-a-rep .form-item-receive-updates input[type="checkbox"] {
  width: 24px;
  height: 24px;
  margin: 0;
  border: 1px solid var(--color-steel);
  border-radius: 4px;
  accent-color: var(--color-dark-coral);
}

.sdc-webform--request-a-rep .privacy-text,
.sdc-webform--request-a-rep .email-info {
  font-size: var(--fs-20);
  line-height: var(--line-height-body);
  color: var(--color-charcoal);
}

.sdc-webform--request-a-rep .privacy-text {
  margin-top: 8px;
}

.sdc-webform--request-a-rep .email-info {
  margin-top: 16px;
}

.sdc-webform--request-a-rep .privacy-link,
.sdc-webform--request-a-rep .email-bold {
  font-weight: var(--font-weight-bold);
  color: var(--color-dark-coral);
  text-decoration: underline;
}

.sdc-webform--request-a-rep .webform-actions {
  display: flex;
  flex-direction: row;
  justify-content: center;
  align-items: center;
  width: 100%;
  margin: var(--space-lg) 0 0;
}

.sdc-webform--request-a-rep .webform-button--submit {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  box-sizing: border-box;
  width: fit-content;
  flex: 0 0 auto;
  height: 48px;
  padding: 12px 40px 10px 24px;
  border: 2px solid var(--color-coral);
  border-radius: var(--radius-full);
  background-color: var(--color-coral);
  background-image: url(../../images/icons/chevron-right.svg);
  background-repeat: no-repeat;
  background-position: right 16px center;
  background-size: 24px 24px;
  font-family: var(--font-agenda);
  font-size: 19px;
  font-weight: var(--font-weight-bold);
  line-height: 1;
  color: var(--color-white);
  white-space: nowrap;
  cursor: pointer;
}

.sdc-webform--request-a-rep .webform-button--submit:hover,
.sdc-webform--request-a-rep .webform-button--submit:focus-visible {
  background-color: var(--color-coral);;
  color: var(--color-white);
}

@media (max-width: 767px) {
  .sdc-webform--request-a-rep .form-item-phone-number input,
  .sdc-webform--request-a-rep .form-item-zip-code input,
  .sdc-webform--request-a-rep .form-item-npi input {
    max-width: 100%;
  }

  .sdc-webform--request-a-rep .webform-button--submit {
    width: 100%;
  }
}
