/* Price Skin Care Clinic: plugin layer (MIG-WO-14, from the FEIC MIG-WO-10 layer). Our CSS only, around the public
   output of Gravity Forms. No vendor file, template or script is touched. Loaded at wp_footer after the plugins' own CSS.
   Gravity Forms "Output default CSS" is off on the local copy (its own documented setting, seed site.php), so the
   shared control tokens in os-refresh.css style the controls (FORM CONTROLS MATCH, ALWAYS). */

/* ---- Gravity Forms: the form sits on the content line; title and description as live; base rules that hold plugin
   markup (FACELIFT-GUIDE 7.2): unknown children full width, empty rows hidden, fixed-width widgets fit at 320 px. */
.gform_wrapper { max-width: 46rem; }
.gform_wrapper .gform_heading { margin-bottom: var(--space-md); }
.gform_wrapper .gform_title { margin: 0 0 0.5rem; font-size: var(--fs-h3); }
.gform_wrapper .gform_description { display: block; color: var(--color-text-2); }
.gform_wrapper .gform_fields > * { grid-column: 1 / -1; min-width: 0; }
.gform_wrapper .gform_fields > :empty,
.gform_wrapper .gfield:empty { display: none; }
.gform_wrapper :is(iframe, .ginput_recaptcha, .cf-turnstile, .g-recaptcha) { max-width: 100%; }
.gform_wrapper .gfield--width-half { min-width: 0; }
@media (min-width: 640px) {
  .gform_wrapper .gform_fields { grid-template-columns: repeat(12, minmax(0, 1fr)); column-gap: var(--space-md); }
  .gform_wrapper .gform_fields > .gfield--width-half { grid-column: span 6; }
  .gform_wrapper .gform_fields > .gfield--width-third { grid-column: span 4; }
  .gform_wrapper .gform_fields > .gfield--width-quarter { grid-column: span 3; }
}
.gform_wrapper ul.gform_fields { margin: 0; padding: 0; list-style: none; }
.gform_wrapper li.gfield + li.gfield { margin-top: 0; }
.gform_wrapper .gfield_list_group_item input,
.gform_wrapper .ginput_container_date input { width: 100%; }
.gform_wrapper .gsection { padding-bottom: 0.5rem; border-bottom: 1px solid var(--color-rule); }
.gform_wrapper .gsection_title { margin: 0; font-size: var(--fs-h4); }
.gform_wrapper .gfield_consent_label,
.gform_wrapper .gchoice label { display: inline; }
.gform_wrapper .gform_footer { display: flex; flex-wrap: wrap; gap: var(--space-sm); }

/* Base form CSS holds plugin markup (FACELIFT-GUIDE 7.2, MIG-WO-14): any child the theme does not know, and fixed-width
   widgets (a 304 px CAPTCHA box, a security plugin's check), stay inside the form at 320 px. Empty rows are hidden. */
.gform_wrapper form > *,
.gform_wrapper .gform_body > *,
.gform_wrapper .gfield > *,
.gform_wrapper :is(iframe, .g-recaptcha, .cf-turnstile, .ginput_recaptcha),
.gform_wrapper form [style*="width"] { max-width: 100%; }
.gform_wrapper .gfield:empty,
.gform_wrapper form > p:empty { display: none; }

/* Batch rule (MIG-WO-14): no left-accent borders. The shared os-refresh.css gives the form confirmation a 4 px left
   edge; here it is one even 1 px border with the pale tint. */
.gform_confirmation_message { border-left-width: 1px; background: var(--color-surface-2); }

/* Gravity Forms date field (Payment form): its calendar button (public markup: button.gform-datepicker-toggle, with
   aria-controls and a label; it opens the date picker) gets a 44 x 44 px tap area inside the right end of the field and
   a line calendar icon. The field keeps room for it. Our CSS only (PM review, MIG-WO-14). */
.gform_wrapper .ginput_container_date { position: relative; }
.gform_wrapper .ginput_container_date input.datepicker_with_icon { padding-right: 3.25rem; }
.gform_wrapper .ginput_container_date button.gform-datepicker-toggle {
  position: absolute;
  top: calc((var(--porch-control-height) - 2.75rem) / 2);
  right: 0.125rem;
  display: inline-grid;
  place-items: center;
  width: 2.75rem;
  min-width: 2.75rem;
  height: 2.75rem;
  min-height: 2.75rem;
  margin: 0;
  padding: 0;
  border: 0;
  border-radius: var(--radius-sm);
  background: none;
  box-shadow: none;
  color: var(--color-text-2);
  font-size: 0;
  line-height: 0;
  cursor: pointer;
  transition: color var(--pm-dur-micro) var(--pm-ease-micro);
}
.gform_wrapper .ginput_container_date button.gform-datepicker-toggle::before {
  content: "";
  width: 1.25rem;
  height: 1.25rem;
  background: currentColor;
  -webkit-mask: var(--psc-calendar-mask) center / contain no-repeat;
  mask: var(--psc-calendar-mask) center / contain no-repeat;
}
.gform_wrapper .ginput_container_date button.gform-datepicker-toggle:hover { color: var(--color-accent); }
.gform_wrapper .ginput_container_date button.gform-datepicker-toggle:focus-visible { outline: var(--pm-focus-ring); outline-offset: -2px; }
