/* Gravity Forms control skin. Scoped to the native careers theme. */
body.mari-native .gform_wrapper {
  --gf-color-primary: #246f64;
  --gf-color-primary-rgb: 36, 111, 100;
  --gf-color-primary-contrast: #fff;
  --gf-ctrl-accent-color: #246f64;
  --gf-ctrl-btn-bg-color-primary: #246f64;
  --gf-ctrl-btn-bg-color-hover-primary: #1b574e;
  --gf-ctrl-btn-color-primary: #fff;
  --gf-ctrl-btn-border-color-primary: #246f64;
  --gf-ctrl-btn-border-radius: 8px;
  --gf-ctrl-border-color: #bbcec6;
  --gf-ctrl-border-color-focus: #246f64;
  --gf-ctrl-outline-color-focus: #246f64;
  --gf-ctrl-outline-width-focus: 2px;
  --gf-ctrl-outline-offset-focus: 2px;
}

/* Both legacy input buttons and current button elements need explicit rules. */
body.mari-native .gform_wrapper :is(
  .gform_button,
  .gform_next_button,
  .gform_previous_button,
  .gform_button_select_files,
  .gform_save_link
) {
  appearance: none !important;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: auto !important;
  max-width: 100%;
  min-height: 48px !important;
  height: auto !important;
  margin: 0 !important;
  padding: 12px 22px !important;
  border: 1px solid #246f64 !important;
  border-radius: 8px !important;
  background-color: #246f64 !important;
  background-image: none !important;
  box-shadow: none !important;
  color: #fff !important;
  font-family: system-ui, -apple-system, "Segoe UI", sans-serif !important;
  font-size: 14px !important;
  font-weight: 600 !important;
  line-height: 1.5 !important;
  letter-spacing: normal !important;
  text-transform: none !important;
  text-decoration: none;
  white-space: normal;
  cursor: pointer;
  transition: background-color .15s, border-color .15s;
}

body.mari-native .gform_wrapper :is(.gform_button[type="submit"], .gform_next_button):hover:not(:disabled) {
  background-color: #1b574e !important;
  border-color: #1b574e !important;
}

body.mari-native .gform_wrapper :is(.gform_previous_button, .gform_button_select_files, .gform_save_link) {
  color: #245e52 !important;
  border-color: #bbcec6 !important;
  background-color: #fff !important;
}

body.mari-native .gform_wrapper :is(.gform_previous_button, .gform_button_select_files, .gform_save_link):hover:not(:disabled) {
  background-color: #edf5f0 !important;
  border-color: #7ea996 !important;
}

body.mari-native .gform_wrapper :is(.gform_button, .gform_next_button, .gform_previous_button, .gform_button_select_files):focus-visible {
  outline: 2px solid #246f64 !important;
  outline-offset: 3px !important;
}

body.mari-native .gform_wrapper :is(.gform_button, .gform_next_button, .gform_previous_button):disabled {
  opacity: .55;
  cursor: not-allowed;
}

body.mari-native .gform_wrapper :is(.gform_page_footer, .gform_footer) {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 12px;
  margin-top: 28px;
  padding-top: 22px;
  border-top: 1px solid #e1ebe5;
}

/* One clear caret and focus outline, while retaining the native mobile picker. */
body.mari-native .gform_wrapper select:not([multiple]):not([size]),
body.mari-native .gform_wrapper select[size="1"] {
  appearance: none !important;
  -webkit-appearance: none !important;
  min-height: 48px !important;
  height: auto !important;
  padding: 12px 44px 12px 14px !important;
  border: 1px solid #bbcec6 !important;
  border-radius: 8px !important;
  background-color: #fafcfb !important;
  background-image: url("chevron-down.svg") !important;
  background-repeat: no-repeat !important;
  background-position: right 14px center !important;
  background-size: 18px 18px !important;
  box-shadow: none !important;
  color: #243e36 !important;
  font: 400 15px/1.5 system-ui, -apple-system, "Segoe UI", sans-serif !important;
  width: 100%;
  max-width: 100%;
  cursor: pointer;
}

body.mari-native .gform_wrapper select:focus {
  border-color: #246f64 !important;
  box-shadow: none !important;
  outline: 2px solid #246f64 !important;
  outline-offset: 2px !important;
}

body.mari-native .gform_wrapper select:disabled {
  color: #6b7a73 !important;
  background-color: #f0f3f1 !important;
  cursor: not-allowed;
}

/* Enhanced selects, if enabled in the installed form. */
body.mari-native .gform_wrapper .chosen-container-single .chosen-single,
body.mari-native .gform_wrapper .select2-container--default .select2-selection--single {
  min-height: 48px;
  height: auto;
  padding: 10px 38px 10px 14px;
  border: 1px solid #bbcec6 !important;
  border-radius: 8px !important;
  background: #fafcfb url("chevron-down.svg") no-repeat right 14px center / 18px 18px !important;
  box-shadow: none !important;
  color: #243e36;
  font: 400 15px/26px system-ui, -apple-system, "Segoe UI", sans-serif;
}
body.mari-native .gform_wrapper .chosen-container-single .chosen-single div,
body.mari-native .gform_wrapper .select2-selection--single .select2-selection__arrow {
  display: none;
}
body.mari-native .gform_wrapper .select2-selection--single .select2-selection__rendered {
  padding: 0;
  color: inherit;
  line-height: 26px;
}
body.mari-native .gform_wrapper :is(.chosen-drop, .select2-dropdown) {
  border-color: #bbcec6;
  border-radius: 8px;
  box-shadow: 0 8px 24px #153c3020;
  font-family: system-ui, -apple-system, "Segoe UI", sans-serif;
}
body.mari-native .gform_wrapper .chosen-results li.highlighted,
body.mari-native .gform_wrapper .select2-results__option--highlighted[aria-selected] {
  background: #246f64 !important;
  color: #fff !important;
}

/* Draw exactly one check mark instead of mixing browser and framework glyphs. */
body.mari-native .gform_wrapper input:is([type="checkbox"], [type="radio"]) {
  appearance: none !important;
  -webkit-appearance: none !important;
  display: inline-block !important;
  width: 20px !important;
  height: 20px !important;
  min-height: 20px !important;
  padding: 0 !important;
  border: 1.5px solid #8fa89a !important;
  border-radius: 4px !important;
  background-color: #fff !important;
  background-image: none !important;
  box-shadow: none !important;
  flex: 0 0 20px;
  cursor: pointer;
}
body.mari-native .gform_wrapper input:is([type="checkbox"], [type="radio"])::before,
body.mari-native .gform_wrapper input:is([type="checkbox"], [type="radio"])::after {
  content: none !important;
  display: none !important;
}
body.mari-native .gform_wrapper input[type="checkbox"]:checked {
  border-color: #246f64 !important;
  background: #246f64 url("check-white.svg") no-repeat center / 16px 16px !important;
}
body.mari-native .gform_wrapper input[type="checkbox"]:indeterminate {
  border-color: #246f64 !important;
  background: linear-gradient(#fff, #fff) center / 10px 2px no-repeat #246f64 !important;
}
body.mari-native .gform_wrapper input[type="radio"] {
  border-radius: 50% !important;
}
body.mari-native .gform_wrapper input[type="radio"]:checked {
  border-color: #246f64 !important;
  background-color: #246f64 !important;
  box-shadow: inset 0 0 0 4px #fff !important;
}
body.mari-native .gform_wrapper input:is([type="checkbox"], [type="radio"]):focus-visible {
  outline: 2px solid #246f64 !important;
  outline-offset: 3px !important;
}
body.mari-native .gform_wrapper input:is([type="checkbox"], [type="radio"]):disabled {
  opacity: .5;
  cursor: not-allowed;
}

/* Progress keeps the existing step labels and accessible percentage text. */
body.mari-native .gform_wrapper :is(.gf_progressbar, .gf_progressbar_wrapper .gf_progressbar) {
  height: 8px;
  padding: 0 !important;
  border: 0;
  border-radius: 20px;
  background: #e3eee7 !important;
  overflow: hidden;
}
body.mari-native .gform_wrapper .gf_progressbar_percentage {
  height: 8px;
  min-height: 8px;
  border-radius: 20px;
  background-color: #246f64 !important;
  background-image: none !important;
}
body.mari-native .gform_wrapper .gf_progressbar_percentage span {
  position: absolute;
  width: 1px;
  height: 1px;
  padding: 0;
  overflow: hidden;
  clip-path: inset(50%);
}
body.mari-native .gform_wrapper .gf_step_active .gf_step_number {
  background-color: #246f64 !important;
  border-color: #246f64 !important;
  color: #fff !important;
}

/* MediaElement is a player, so form button sizes and colours must not reach it. */
body.mari-native .gform_wrapper :is(.mejs-container, .mejs__container, .wp-video) {
  max-width: 100%;
  border-radius: 10px;
  overflow: hidden;
}
body.mari-native .gform_wrapper :is(.mejs-button, .mejs__button) > button {
  appearance: none !important;
  width: 20px !important;
  height: 20px !important;
  min-width: 20px !important;
  min-height: 20px !important;
  margin: 10px 6px !important;
  padding: 0 !important;
  border: 0 !important;
  border-radius: 0 !important;
  background-color: transparent !important;
  box-shadow: none !important;
  color: #fff !important;
  font-size: 0 !important;
  line-height: 0 !important;
  overflow: hidden;
}
body.mari-native .gform_wrapper :is(.mejs-button, .mejs__button) > button:focus-visible {
  outline: 2px solid #fff !important;
  outline-offset: 2px !important;
}
body.mari-native .gform_wrapper :is(.mejs-time-current, .mejs__time-current, .mejs-horizontal-volume-current, .mejs__horizontal-volume-current) {
  background-color: #7ccab9 !important;
}

@media (max-width: 600px) {
  body.mari-native .gform_wrapper :is(.gform_page_footer, .gform_footer) {
    display: grid;
    grid-template-columns: minmax(0, 1fr);
    gap: 12px;
  }
  body.mari-native .gform_wrapper :is(.gform_page_footer, .gform_footer) > :is(.gform_button, .gform_next_button, .gform_previous_button, .gform_save_link) {
    width: 100% !important;
    min-width: 0 !important;
    text-align: center;
  }
}

@media (forced-colors: active) {
  body.mari-native .gform_wrapper input:is([type="checkbox"], [type="radio"]) {
    appearance: auto !important;
    -webkit-appearance: auto !important;
    forced-color-adjust: auto;
  }
}
@media (prefers-reduced-motion: reduce) {
  body.mari-native .gform_wrapper :is(.gform_button, .gform_next_button, .gform_previous_button) { transition: none; }
}

/* Form rhythm: a single field gap, separate label/help gaps, and one card inset. */
body.mari-native .mari-nda-instructions {
  padding-inline-start: 24px;
  margin: 0 0 20px;
  line-height: 1.75;
}
body.mari-native .mari-nda-instructions li { padding-inline-start: 4px; margin-bottom: 12px; }
body.mari-native .mari-nda-frame {
  display: block;
  width: 100%;
  height: 1100px;
  border: 1px solid #dce7e0;
  border-radius: 8px;
  background: #fff;
}
body.mari-native .gform_wrapper {
  --mari-field-gap: 28px;
  --mari-label-gap: 10px;
  --mari-help-gap: 8px;
  --mari-subfield-gap: 16px;
  line-height: 1.65;
}
body.mari-native .mari-content .gform_wrapper {
  padding: 32px;
  border: 1px solid #dce7e0;
  border-radius: 12px;
  box-shadow: none;
}
body.mari-native .mari-onboarding > .mari-card {
  padding: 28px;
  margin-bottom: 28px;
}
body.mari-native .mari-onboarding .mari-card > .gform_wrapper {
  padding: 0 !important;
  border: 0;
  border-radius: 0;
  margin: 0;
  box-shadow: none;
}
body.mari-native .mari-onboarding > h1 { margin-bottom: 16px; }
body.mari-native .mari-onboarding > p {
  margin: 0 0 16px;
  max-width: 76ch;
  line-height: 1.75;
}
body.mari-native .mari-onboarding > p:last-of-type { margin-bottom: 28px; }
body.mari-native .mari-onboarding > .mari-card > h2 {
  margin: 0 0 20px;
  line-height: 1.35;
}
body.mari-native .gform_wrapper .gform_heading { margin: 0 0 28px; }
body.mari-native .gform_wrapper .gform_title {
  margin: 0 0 12px;
  line-height: 1.35;
}
body.mari-native .gform_wrapper .gform_description {
  display: block;
  margin: 0;
  padding: 0;
  max-width: 80ch;
  font-size: 14px;
  line-height: 1.75;
}
body.mari-native .gform_wrapper .gform_heading:empty { display: none; }
body.mari-native .gform_wrapper .gform_fields {
  row-gap: var(--mari-field-gap) !important;
  column-gap: 20px !important;
}
body.mari-native .gform_wrapper .gform_fields > .gfield {
  margin-block: 0 !important;
  min-width: 0;
}
body.mari-native .gform_wrapper:not(.gravity-theme):not(.gform-theme--framework) .gform_fields > .gfield {
  margin-bottom: var(--mari-field-gap) !important;
}
body.mari-native .gform_wrapper .gfield > :is(.gfield_label, .gform-field-label) {
  display: block;
  margin: 0 0 var(--mari-label-gap) !important;
  padding: 0;
  font-size: 15px;
  font-weight: 600;
  line-height: 1.5 !important;
}
body.mari-native .gform_wrapper .gfield_required {
  margin-inline-start: 5px;
  font-size: 12px;
  font-weight: 400;
  line-height: inherit;
}
body.mari-native .gform_wrapper .ginput_container { margin-block: 0; }
body.mari-native .gform_wrapper .ginput_complex { row-gap: var(--mari-subfield-gap); }
/* Let the framework's negative row gutters offset its padded columns. */
body.mari-native .gform_wrapper .ginput_complex.gform-grid-row { width: auto; }
body.mari-native .gform_wrapper .ginput_complex .gform-field-label--type-sub,
body.mari-native .gform_wrapper .ginput_complex > span > label {
  display: block;
  padding: 0;
  margin: 6px 0 0 !important;
  color: #526a61;
  font-size: 13px;
  font-weight: 400;
  line-height: 1.5 !important;
}
body.mari-native .gform_wrapper .field_sublabel_above .ginput_complex > span > label,
body.mari-native .gform_wrapper .field_sublabel_above .gform-field-label--type-sub {
  margin: 0 0 6px !important;
}
body.mari-native .gform_wrapper .ginput_container_address.has_country:not(.has_street):not(.has_city):not(.has_state):not(.has_zip) .address_country {
  flex: 0 0 100%;
  width: 100% !important;
}
body.mari-native .gform_wrapper .ginput_container input:not([type="checkbox"]):not([type="radio"]):not([type="file"]):not([type="hidden"]):not([type="button"]):not([type="submit"]):not([type="image"]):not([type="range"]) {
  box-sizing: border-box;
  height: 48px;
  min-height: 48px;
  padding: 11px 14px;
  font-size: 15px;
  line-height: 24px !important;
}
body.mari-native .gform_wrapper textarea {
  display: block;
  padding: 12px 14px;
  min-height: 132px;
  font-size: 15px;
  line-height: 1.65;
  resize: vertical;
}
body.mari-native .gform_wrapper :is(.gfield_description, .ginput_description, .gform_fileupload_rules) {
  padding: 0 !important;
  margin: var(--mari-help-gap) 0 0 !important;
  font-size: 13px;
  line-height: 1.7 !important;
  overflow-wrap: anywhere;
}
body.mari-native .gform_wrapper .field_description_above > .gfield_description,
body.mari-native .gform_wrapper .gfield > .gfield_label + .gfield_description {
  margin: 0 0 12px !important;
}
body.mari-native .gform_wrapper :is(.gfield_description, .ginput_description):empty { display: none; }
body.mari-native .gform_wrapper :is(.gfield_checkbox, .gfield_radio) {
  margin: 0;
  padding: 0;
  gap: 10px;
}
body.mari-native .gform_wrapper :is(.gchoice, .ginput_container_consent) {
  margin: 0;
  gap: 10px;
  min-height: 28px;
}
body.mari-native .gform_wrapper :is(.gchoice, .ginput_container_consent) > label {
  margin: 0 !important;
  padding: 0 !important;
  line-height: 1.7;
}
body.mari-native .gform_wrapper .gform_drop_area {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  justify-content: center;
  gap: 12px;
  margin: 0;
  padding: 22px 18px;
}
body.mari-native .gform_wrapper .ginput_preview {
  margin: 12px 0 0;
  padding: 12px;
  line-height: 1.65;
}
body.mari-native .gform_wrapper :is(.mari-upload-status, .mari-file-state) {
  margin: 12px 0 0 !important;
  line-height: 1.7;
}
body.mari-native .gform_wrapper .mari-upload-status { padding: 14px 16px; }
body.mari-native .gform_wrapper .gform_validation_errors {
  margin: 0 0 24px;
  padding: 18px 20px;
  border-radius: 8px;
  line-height: 1.7;
}
body.mari-native .gform_wrapper .gform_validation_errors > h2 {
  margin: 0;
  font: 600 16px/1.5 system-ui, -apple-system, "Segoe UI", sans-serif;
}
body.mari-native .gform_wrapper .gform_validation_errors .validation_list {
  margin: 12px 0 0;
  padding-inline-start: 20px;
}
body.mari-native .gform_wrapper .validation_list li { margin: 0 0 8px; }
body.mari-native .gform_wrapper :is(.gfield_validation_message, .validation_message) {
  margin: 10px 0 0 !important;
  padding: 10px 12px !important;
  line-height: 1.7 !important;
}
body.mari-native .gform_wrapper .gf_progressbar_wrapper { margin: 0 0 28px; }
body.mari-native .gform_wrapper .gf_progressbar_title {
  margin: 0 0 12px;
  font-size: 14px;
  line-height: 1.5;
}
body.mari-native .gform_wrapper :is(.gform_page_footer, .gform_footer) {
  margin: 28px 0 0 !important;
  padding: 22px 0 0 !important;
}
body.mari-native .mari-onboarding .gfield_html:has(.wp-video),
body.mari-native .mari-onboarding .gfield_html:has(.wp-video) + .gfield--type-fileupload {
  grid-column: span 6;
}
body.mari-native .gform_wrapper .gfield_html > .wp-video { margin: 0; max-width: 100%; }

@media (max-width: 780px) {
  body.mari-native .mari-onboarding .gfield_html:has(.wp-video),
  body.mari-native .mari-onboarding .gfield_html:has(.wp-video) + .gfield--type-fileupload { grid-column: span 12; }
}
@media (max-width: 600px) {
  body.mari-native .gform_wrapper { --mari-field-gap: 24px; }
  body.mari-native .mari-content .gform_wrapper { padding: 20px; }
  body.mari-native .mari-onboarding > .mari-card { padding: 20px; margin-bottom: 24px; }
  body.mari-native .mari-onboarding .mari-card > .gform_wrapper { padding: 0 !important; }
  body.mari-native .gform_wrapper .gform_fields { column-gap: 16px !important; }
  body.mari-native .gform_wrapper .gform_drop_area { padding: 20px 14px; }
  body.mari-native .gform_wrapper .gform_heading { margin-bottom: 24px; }
  body.mari-native .gform_wrapper .ginput_container input:not([type="checkbox"]):not([type="radio"]):not([type="file"]):not([type="hidden"]):not([type="button"]):not([type="submit"]):not([type="image"]):not([type="range"]),
  body.mari-native .gform_wrapper select,
  body.mari-native .gform_wrapper textarea { font-size: 16px !important; }
  body.mari-native .gform_wrapper .gform_validation_errors { padding: 16px; }
}
