/* ============================================================
   ICOSA LTD  ·  Gravity Forms in the Icosa style.
   Gravity Forms' own stylesheets are dequeued, so this file is the
   only thing styling the form: Merriweather throughout, underlined
   fields, a burnt orange rule on focus.
   ============================================================ */

.gform_wrapper{ --err:#B3261E; }

.gform_wrapper{ margin:0; }
.gform_wrapper form{ margin:0; }
.gform_wrapper .gform_heading{ display:none; }

/* Anti-spam honeypot and anything Gravity Forms hides structurally. */
.gform_wrapper .gform_validation_container,
.gform_wrapper .gfield--type-honeypot,
.gform_wrapper .gform_hidden,
.gform_wrapper input[type="hidden"]{
  display:none !important;
}
.gform_wrapper .gfield_visibility_hidden{
  position:absolute !important; left:-9999px; width:1px; height:1px; overflow:hidden;
}
.gform_wrapper .screen-reader-text{
  position:absolute !important; width:1px; height:1px;
  padding:0; margin:0; border:0; overflow:hidden; clip-path:inset(50%); white-space:nowrap;
}

/* ---------- Field grid: the design's .field-row, two up ---------- */
.gform_wrapper .gform_fields{
  display:grid; grid-template-columns:repeat(2, minmax(0,1fr));
  column-gap:clamp(20px, 2.4vw, 40px); row-gap:0;
  list-style:none; margin:0; padding:0;
}
.gform_wrapper .gfield{
  grid-column:1 / -1;
  margin:0 0 clamp(22px, 2.4vw, 34px);
  min-width:0;
}
.gform_wrapper .gfield--width-half{ grid-column:span 1; }

/* ---------- Labels ---------- */
.gform_wrapper .gfield_label{
  display:block; margin:0 0 4px;
  font-family:var(--ff); font-size:.68rem; font-weight:700; letter-spacing:.18em;
  text-transform:uppercase; color:var(--ink);
}
/* The design marks optional fields rather than required ones.
   #8C8C8C was 3.36:1 on white at 10.6px; #757575 is 4.61:1 and keeps this a
   step lighter than the privacy note, as the design has it. */
.gform_wrapper .gfield_required{ display:none; }
.gform_wrapper .gfield:not(.gfield_contains_required) > .gfield_label::after{
  content:" (optional)";
  text-transform:none; letter-spacing:.02em; font-weight:400; color:#6B6566;
}

/* ---------- Controls ---------- */
.gform_wrapper .ginput_container{ margin:0; }
.gform_wrapper input[type="text"],
.gform_wrapper input[type="email"],
.gform_wrapper input[type="tel"],
.gform_wrapper input[type="url"],
.gform_wrapper input[type="number"],
.gform_wrapper select,
.gform_wrapper textarea{
  width:100%; font-family:var(--ff); font-size:1.08rem; font-weight:300; line-height:1.5;
  color:var(--ink); background:transparent;
  border:0; border-bottom:1px solid var(--line-strong);
  padding-block:12px; padding-inline:0; border-radius:0;
  transition:border-color .25s var(--ease);
  -webkit-appearance:none; appearance:none;
}
/* Gravity Forms hardcodes rows="10" on every textarea and relies on its own
   stylesheet for the height. The design asks for four rows, so the height is
   set here: four line boxes plus the vertical padding and the underline.
   Deliberately left inline, as the design has it, so the line box below keeps
   its descender and the field measures the same 148px on both sides. */
.gform_wrapper textarea{
  resize:none;
  height:calc(4 * 1.5em + 24px + 1px);
}

/* The design's last field and the button row are adjacent siblings, so their
   margins collapse to the larger of the two. Grid items do not collapse, so
   the trailing margin is dropped here to leave the same 32px gap. */
.gform_wrapper .gform_fields > .gfield:last-child{ margin-bottom:0; }
/* The message placeholder carries a real instruction, not a restatement of the
   label, so it has to be readable. #9A9A9A was 2.81:1; #767676 is 4.54:1, the
   lightest grey on white that meets AA. */
.gform_wrapper input::placeholder,
.gform_wrapper textarea::placeholder{ color:#767676; opacity:1; }

.gform_wrapper select{
  cursor:pointer;
  background-image:linear-gradient(45deg, transparent 50%, var(--burnt) 50%),
                   linear-gradient(135deg, var(--burnt) 50%, transparent 50%);
  background-position:calc(100% - 7px) calc(50% + 1px), calc(100% - 2px) calc(50% + 1px);
  background-size:5px 5px, 5px 5px; background-repeat:no-repeat;
  padding-right:26px;
}
.gform_wrapper select option{ background:var(--white); color:var(--ink); }

.gform_wrapper input:focus,
.gform_wrapper select:focus,
.gform_wrapper textarea:focus{
  outline:none; border-bottom-color:var(--burnt); border-bottom-width:2px; padding-bottom:11px;
}
/* The accent underline already signals focus unambiguously here, so the global
   focus ring is suppressed on these controls only. */
.gform_wrapper input:focus-visible,
.gform_wrapper select:focus-visible,
.gform_wrapper textarea:focus-visible{ outline:none; }

/* ---------- Errors ---------- */
.gform_wrapper .gfield_error input,
.gform_wrapper .gfield_error select,
.gform_wrapper .gfield_error textarea{ border-bottom-color:var(--err); }
.gform_wrapper .gfield_validation_message,
.gform_wrapper .validation_message{
  margin-top:6px; padding:0; border:0; background:none;
  font-family:var(--ff); font-size:.8rem; font-weight:400; letter-spacing:0;
  color:var(--err);
}
.gform_wrapper .gfield_description{
  margin-top:6px; padding:0;
  font-family:var(--ff); font-size:.8rem; color:var(--mut);
}

/* Form-level error summary, styled as the design's status block. */
.gform_wrapper .gform_validation_errors{
  margin:0 0 clamp(18px, 2vw, 26px); padding:14px 18px;
  border:0; border-left:2px solid var(--err); background:var(--stone); box-shadow:none;
}
.gform_wrapper .gform_validation_errors h2{
  margin:0; font-family:var(--ff); font-weight:700; font-size:.92rem; color:var(--ink);
}
.gform_wrapper .gform_validation_errors h2 .gform-icon{ display:none; }
.gform_wrapper .gform_validation_errors ol{ display:none; }

/* ---------- Footer: the design's .form-foot ---------- */
.gform_wrapper .gform_footer{
  display:flex; flex-wrap:wrap; align-items:center; gap:14px 22px;
  margin:clamp(28px, 3vw, 40px) 0 0; padding:0;
}
/* #7C7C7C was 4.17:1 on white at 12.8px, just under AA. #6F6F6F is 5.03:1 and
   is still the muted tone the design asks for. */
.gform_wrapper .form-privacy{
  margin:0; font-size:.8rem; color:var(--mut); max-width:36ch;
}
.gform_wrapper .form-privacy a{
  color:var(--ink); border-bottom:1px solid rgba(199,73,6,.5);
  padding-bottom:1px; transition:border-color .3s var(--ease);
}
.gform_wrapper .form-privacy a:hover{ border-bottom-color:var(--burnt); }
.gform_wrapper .gform_ajax_spinner{
  width:18px; height:18px; margin:0;
}

/* ---------- Confirmation: the design's .form-status ---------- */
.gform_confirmation_wrapper,
.gform_wrapper .gform_confirmation_message,
.gform_confirmation_message{
  margin-top:0; padding:22px 24px;
  border-left:2px solid var(--burnt); background:var(--stone);
}
.gform_confirmation_message b{
  display:block; margin-bottom:6px; font-weight:400; font-size:1.3rem; color:var(--ink);
}
.gform_confirmation_message p{ margin:0; color:var(--mut); font-size:.95rem; }

/* ---------- Responsive: the design collapses field rows at 640 ---------- */
@media (max-width: 640px){
  .gform_wrapper .gform_fields{ grid-template-columns:minmax(0,1fr); }
  .gform_wrapper .gfield--width-half{ grid-column:1 / -1; }
}

/* Cloudflare Turnstile sits above the button row. */
.gform_wrapper .gfield--type-turnstile{ margin-bottom:0; }
