/**
 * November 2026 redesign: the inquiry forms on the Enterprise and Franchise
 * pages.
 *
 * Each page's HTML has a card (<div data-qd-form="webform:…">) with a
 * <drupal-webform> tag in it, which renders the "Let's get started" webform
 * in that page's variant (module qd_nov2026_redesign). These rules make the
 * webform look like the approved design's form: two-column rows, bold
 * labels with a red asterisk, "I'm with" as toggle buttons, and a red
 * "Send inquiry" button with the privacy note beside it.
 *
 * Scoped to the cards, so the same webform elsewhere (case studies, Mailing
 * Lists, /form/let-s-get-started) is unaffected. The doubled id outranks the
 * theme's Bootstrap form rules without !important.
 */

/* ── Layout: fields flow in rows; pairs share a row, as in the design.
   The per-field rules repeat the form selector so they outrank the
   catch-all "> *" rule. ── */
#main-container-wrapper#main-container-wrapper .qd-page [data-qd-form] form.webform-submission-form {
  display: flex;
  flex-wrap: wrap;
  gap: 18px 16px;
  margin: 0;
}
#main-container-wrapper#main-container-wrapper .qd-page [data-qd-form] form.webform-submission-form > * {
  flex: 1 1 100%;
  min-width: 0;
  margin: 0;
}
#main-container-wrapper#main-container-wrapper .qd-page [data-qd-form] form.webform-submission-form > :is(.form-item-name, .form-item-business-name, .form-item-email, .form-item-phone-number) {
  /* At most two per row (the design wraps each pair in its own row);
     below 456px of card width they stack. */
  flex: 1 1 calc(50% - 8px);
  min-width: 220px;
}
#main-container-wrapper#main-container-wrapper .qd-page [data-qd-form] form.webform-submission-form > :is(.form-item-locations, .form-item-what-is-the-approximate-amount-of-associates-) {
  flex: 0 1 calc(50% - 8px);
  min-width: 220px;
}

/* ── Labels ── */
#main-container-wrapper#main-container-wrapper .qd-page [data-qd-form] .form-item > label.control-label:not(.option) {
  display: block;
  margin: 0 0 6px;
  font-size: 14px;
  font-weight: 700;
  line-height: 1.6;
  color: inherit;
}
/* The webform's own CSS hides required markers everywhere it's used
   (".form-required:after { display: none !important }"); only an
   !important rule can show them, and this one applies to these cards only. */
#main-container-wrapper#main-container-wrapper .qd-page [data-qd-form] :is(label, .fieldset-legend).form-required::after {
  content: "\00a0*";
  color: #D92025;
  background: none;
  display: inline !important;
  width: auto;
  height: auto;
  margin: 0;
  vertical-align: baseline;
}

/* ── Text inputs and textarea ── */
#main-container-wrapper#main-container-wrapper .qd-page [data-qd-form] .form-control {
  display: block;
  width: 100%;
  height: auto;
  box-sizing: border-box;
  margin: 0;
  padding: 10px;
  font: inherit;
  font-size: 15px;
  font-weight: 400;
  line-height: 1.6;
  color: #212121;
  background: #FFFFFF;
  border: 1px solid #696969;
  border-radius: 2px;
  box-shadow: none;
}
#main-container-wrapper#main-container-wrapper .qd-page [data-qd-form] .form-control:focus {
  border-color: #696969;
  box-shadow: none;
  outline: revert;
}
/* Four rows, as in the design (15px × 1.6 × 4 + padding + border). */
#main-container-wrapper#main-container-wrapper .qd-page [data-qd-form] textarea.form-control {
  height: 118px;
  min-height: 118px;
  resize: vertical;
}

/* ── "I'm with": radios shown as two toggle buttons ── */
#main-container-wrapper#main-container-wrapper .qd-page [data-qd-form] fieldset.form-composite {
  border: 0;
  margin: 0;
  padding: 0;
  min-width: 0;
}
#main-container-wrapper#main-container-wrapper .qd-page [data-qd-form] fieldset.form-composite > legend {
  width: 100%;
  margin: 0 0 4px;
  padding: 0 0 4px;
  border: 0;
  border-bottom: 1px solid #EBEBEB;
  font-size: 14px;
  font-weight: 700;
  line-height: 1.6;
  color: inherit;
}
#main-container-wrapper#main-container-wrapper .qd-page [data-qd-form] .js-webform-radios {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
}
#main-container-wrapper#main-container-wrapper .qd-page [data-qd-form] .js-webform-radios .form-item.radio {
  margin: 0;
  padding: 0;
}
#main-container-wrapper#main-container-wrapper .qd-page [data-qd-form] .js-webform-radios label.option {
  position: relative;
  display: inline-flex;
  align-items: center;
  box-sizing: border-box;
  min-height: 44px;
  margin: 0;
  padding: 9px 14px;
  font-size: 14px;
  font-weight: 600;
  line-height: 1.6;
  color: #156570;
  background: #FFFFFF;
  border: 1px solid #C0D8D8;
  border-radius: 2px;
  cursor: pointer;
}
/* The radio stays in the page for keyboard and screen readers, unseen. */
#main-container-wrapper#main-container-wrapper .qd-page [data-qd-form] .js-webform-radios input[type="radio"] {
  position: absolute;
  opacity: 0;
  width: 1px;
  height: 1px;
  margin: 0;
}
/* Selected: dark teal (the design shows only the unselected state). */
#main-container-wrapper#main-container-wrapper .qd-page [data-qd-form] .js-webform-radios label.option:has(input:checked) {
  color: #FFFFFF;
  background: #156570;
  border-color: #156570;
}
#main-container-wrapper#main-container-wrapper .qd-page [data-qd-form] .js-webform-radios label.option:has(input:focus-visible) {
  outline: 2px solid #156570;
  outline-offset: 2px;
}

/* ── Submit button and the note beside it ── */
#main-container-wrapper#main-container-wrapper .qd-page [data-qd-form] form.webform-submission-form > .form-actions {
  flex: 0 0 auto;
  display: flex;
  align-items: center;
}
#main-container-wrapper#main-container-wrapper .qd-page [data-qd-form] .webform-button--submit {
  height: auto;
  margin: 0;
  padding: 14px 26px;
  font: inherit;
  font-size: 16px;
  font-weight: 600;
  line-height: 1.6;
  color: #FFFFFF;
  background: #D92025;
  border: 0;
  border-radius: 2px;
  box-shadow: none;
  text-shadow: none;
  cursor: pointer;
}
#main-container-wrapper#main-container-wrapper .qd-page [data-qd-form] .webform-button--submit:is(:hover, :focus, :active) {
  color: #FFFFFF;
  background: #D92025;
  box-shadow: 0 1px 2px rgba(0, 0, 0, 0.6);
}
#main-container-wrapper#main-container-wrapper .qd-page [data-qd-form] form.webform-submission-form > .qd-form-note {
  flex: 1 1 200px;
  align-self: center;
  margin-left: -2px; /* the design's 14px gap, against the form's 16px */
  font-size: 13px;
  color: #444E46;
}

/* ── Narrow cards: pairs stack. The design wraps each pair inside its own
   row (16px apart), and rows are 18px apart, so the second of a pair
   moves up 2px. The card is the container; pairs stack below 456px. ── */
#main-container-wrapper#main-container-wrapper .qd-page [data-qd-form] {
  container-type: inline-size;
}
@container (max-width: 455.98px) {
  #main-container-wrapper#main-container-wrapper .qd-page [data-qd-form] form.webform-submission-form > :is(.form-item-business-name, .form-item-phone-number) {
    margin-top: -2px;
  }
}

/* ── Validation errors (client-side messages are label.error; webform's
   are .form-item--error-message). The design shows no error state, so
   these use the design system's error red (#D7263D). ── */
#main-container-wrapper#main-container-wrapper .qd-page [data-qd-form] :is(label.error, strong.error, .form-item--error-message) {
  display: block;
  margin: 6px 0 0;
  padding: 0;
  font-size: 13px;
  font-weight: 600;
  line-height: 1.4;
  color: #D7263D;
}
#main-container-wrapper#main-container-wrapper .qd-page [data-qd-form] .form-control.error {
  border-color: #D7263D;
}
#main-container-wrapper#main-container-wrapper .qd-page [data-qd-form] .js-webform-radios label.option:has(input.error) {
  border-color: #D7263D;
}
