/* Gravity Forms bridge.
   Gravity Forms' own stylesheets are switched off (see gform_disable_css in
   functions.php) so its markup inherits the site's existing form styles —
   .form-shell / .form-grid / .field — rather than fighting two grid systems.
   The per-page overrides for .talk-note and .careers-apply therefore keep
   working unchanged. */

.form-shell .gform_wrapper form,
.form-shell .gform_wrapper .gform_body {
  margin: 0;
}

.form-shell .gform_wrapper .gform_fields {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 22px 26px;
  margin: 0;
  padding: 0;
  list-style: none;
}

@media (max-width: 860px) {
  .form-shell .gform_wrapper .gform_fields {
    grid-template-columns: 1fr;
  }
}

.form-shell .gform_wrapper .gfield {
  display: flex;
  flex-direction: column;
  gap: 9px;
  min-width: 0;
  margin: 0;
}

.form-shell .gform_wrapper .gfield.field--wide,
.form-shell .gform_wrapper .gfield--width-full {
  grid-column: 1 / -1;
}

.form-shell .gform_wrapper .gfield_label {
  font-size: 11px;
  font-weight: 700;
  letter-spacing: 0.14em;
  text-transform: uppercase;
  color: var(--lmg-muted);
  margin: 0;
}

.form-shell .gform_wrapper .gfield_required {
  color: var(--lmg-accent);
  margin-left: 4px;
  text-decoration: none;
}

.form-shell .gform_wrapper .ginput_container input,
.form-shell .gform_wrapper .ginput_container textarea,
.form-shell .gform_wrapper .ginput_container select {
  width: 100%;
  max-width: 100%;
  background: transparent;
  border: 0;
  border-bottom: 1px solid var(--lmg-rule);
  border-radius: 0;
  color: var(--lmg-ink);
  font-family: var(--lmg-body);
  font-size: 16px;
  padding: 12px 2px;
  transition: border-color 0.3s;
}

.form-shell .gform_wrapper .ginput_container input:focus,
.form-shell .gform_wrapper .ginput_container textarea:focus,
.form-shell .gform_wrapper .ginput_container select:focus {
  outline: none;
  border-bottom-color: var(--lmg-accent);
}

.form-shell .gform_wrapper .ginput_container textarea {
  resize: vertical;
  min-height: 130px;
}

/* Submit button. It carries the site's own .contact-invitation class (see
   lmg_gform_submit_button in functions.php), so only the footer spacing and a
   cursor reset are needed here. */
.form-shell .gform_wrapper .gform_footer,
.form-shell .gform_wrapper .gform-footer {
  margin: 30px 0 0;
  padding: 0;
}

.form-shell .gform_wrapper button.contact-invitation {
  cursor: pointer;
}

/* Validation and confirmation states. */
.form-shell .gform_wrapper .gform_validation_errors,
.form-shell .gform_wrapper .validation_message {
  font-size: 13px;
  line-height: 1.7;
  color: #b3261e;
  border-left: 2px solid #b3261e;
  padding-left: 16px;
  margin: 0 0 20px;
  background: none;
  box-shadow: none;
  border-radius: 0;
}

.form-shell .gform_wrapper .validation_message {
  margin: 6px 0 0;
}

.form-shell .gform_wrapper .gfield_error .ginput_container input,
.form-shell .gform_wrapper .gfield_error .ginput_container textarea {
  border-bottom-color: #b3261e;
}

.form-shell .gform_confirmation_message {
  font-size: 15px;
  line-height: 1.7;
  color: var(--lmg-accent);
  border-left: 2px solid var(--lmg-accent);
  padding-left: 16px;
  max-width: 62ch;
}

.form-shell .gform_wrapper .gform_hidden,
.form-shell .gform_wrapper .gfield_visibility_hidden {
  display: none;
}

/* Honeypot and screen-reader-only text stay reachable but invisible. */
.form-shell .gform_wrapper .gform_validation_container {
  position: absolute !important;
  left: -9999px;
}

/* The static design showed no required markers. Name and Email are required on
   the live forms, so the marker is hidden from sight but left for screen
   readers (the inputs also carry aria-required="true"). */
.form-shell .gform_wrapper .gfield_required_text {
  position: absolute !important;
  width: 1px;
  height: 1px;
  padding: 0;
  margin: -1px;
  overflow: hidden;
  clip: rect(0, 0, 0, 0);
  white-space: nowrap;
  border: 0;
}

/* Bio intake has long questions and section introductions. */
.bio-intake-form .form-shell .gfield_label {
  font-size: 15px;
  line-height: 1.6;
  font-weight: 600;
  letter-spacing: normal;
  text-transform: none;
}

.bio-intake-form .gfield_html h2 {
  margin: 24px 0 12px;
  padding-bottom: 16px;
  border-bottom: 1px solid var(--lmg-rule);
  font-family: var(--lmg-display);
  font-size: clamp(28px, 3vw, 42px);
  font-weight: 400;
  line-height: 1.15;
}

.bio-intake-form .gfield_html p,
.bio-intake-form .gfield_description {
  font-size: 15px;
  line-height: 1.8;
}

.bio-intake-form fieldset.gfield {
  border: 0;
  padding: 0;
}

.bio-intake-form .gfield--type-date > .ginput_complex {
  display: flex;
  gap: 16px;
}

.bio-intake-form .ginput_container_date {
  flex: 1;
  min-width: 0;
  max-width: 120px;
}

.bio-intake-form .ginput_container_date label {
  display: block;
  font-size: 12px;
  margin-top: 6px;
}
