/* ------------------------------------------------------------------
   Contact Form 7 styling (08 §8 component 14, §16). Tokens only.
   Baseline treatment — field markup finalises against 09; extend then.
   ------------------------------------------------------------------ */

.wpcf7-form {
  --field-border: var(--border-light);
}

/* Labels — visible, block, associated in markup. Placeholder is NOT a label (08 §12). */
.wpcf7-form label {
  display: block;
  margin-bottom: 6px;
  font-weight: 500;
  color: var(--neutral-900);
}

/* Required marker — text/symbol, never colour alone. */
.wpcf7-form label .required,
.wpcf7-form .required-mark {
  color: var(--neutral-900);
}

/* Inputs. */
.wpcf7-form input[type="text"],
.wpcf7-form input[type="email"],
.wpcf7-form input[type="tel"],
.wpcf7-form input[type="url"],
.wpcf7-form input[type="number"],
.wpcf7-form select,
.wpcf7-form textarea {
  width: 100%;
  min-height: 44px;
  padding: 12px 14px;
  font-size: 16px; /* ≥16px prevents iOS zoom-on-focus */
  color: var(--neutral-900);
  background: var(--surface-light);
  border: 1px solid var(--field-border);
  border-radius: var(--radius);
  box-sizing: border-box;
}
.wpcf7-form textarea {
  min-height: 140px;
  resize: vertical;
}

/* Focus — visible, high contrast (defers to accessibility.css outline too). */
.wpcf7-form input:focus,
.wpcf7-form select:focus,
.wpcf7-form textarea:focus {
  border-color: var(--brand-black);
  outline: 2px solid var(--brand-black);
  outline-offset: 1px;
}

/* Submit — the correct CTA treatment: black text on accent bg (16:1, 08 §4.2). */
.wpcf7-form .wpcf7-submit {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  padding: 14px 28px;
  font-size: 16px;
  font-weight: 500;
  color: var(--brand-black);
  background: var(--brand-accent);
  border: 0;
  border-radius: var(--radius);
  cursor: pointer;
  transition: background-color 150ms ease;
}
.wpcf7-form .wpcf7-submit:hover,
.wpcf7-form .wpcf7-submit:focus {
  background: var(--accent-dark);
}
.wpcf7-form .wpcf7-submit:disabled {
  background: var(--neutral-500);
  cursor: not-allowed;
}

/* Errors — text, associated with the field, not colour alone (08 §12). */
.wpcf7-not-valid {
  border-color: var(--brand-black) !important;
  border-width: 2px !important;
}
.wpcf7-not-valid-tip {
  display: block;
  margin-top: 6px;
  font-size: 15px;
  font-weight: 500;
  color: var(--neutral-900);
}
.wpcf7-response-output {
  margin: 16px 0 0;
  padding: 12px 14px;
  border: 1px solid var(--field-border);
  border-radius: var(--radius);
  font-size: 15px;
  color: var(--neutral-900);
}

/* ==================================================================
   PRIMARY ENQUIRY FORM (F1) — full-bleed immersive section (design
   Option B). Scoped so it does NOT touch the light Contact-page form:
   field styling hangs off .hef-grid (always in the form DOM); section
   background/centering also target #heraform1's element-id class,
   because Elementor container css_classes can fail to reach the DOM
   in this build (documented quirk) — the id class always renders.
   Budget bands + consent wording are placeholders pending D-38 / legal.
   ================================================================== */
.heraedges-form,
.heraedges-form {
  position: relative;
  background-color: #000;
  background-image: radial-gradient(rgba(191, 247, 71, 0.10) 1.2px, transparent 1.6px);
  background-size: 40px 40px;
  overflow: hidden;
}
/* ambient glow — top behind the heading + a softer low glow behind the
   submit, so the lower half is not dead-flat black */
.heraedges-form::before,
.heraedges-form::before {
  content: ""; position: absolute; inset: 0; pointer-events: none;
  background:
    radial-gradient(circle at 50% -5%, rgba(191, 247, 71, 0.16), transparent 42%),
    radial-gradient(circle at 50% 108%, rgba(191, 247, 71, 0.08), transparent 45%);
}
.heraedges-form > * { position: relative; z-index: 1; }

/* form sits in a subtle glass panel to lift it off the immersive bg */
.heraedges-form .wpcf7 {
  max-width: 1000px; margin: 0 auto; width: 100%;
  background: rgba(255, 255, 255, 0.02);
  border: 1px solid rgba(255, 255, 255, 0.08);
  border-radius: 22px;
  padding: 44px 44px 40px;
}

/* header */
.hef-head { max-width: 720px; margin: 0 auto 40px; text-align: center; }
.hef-eyebrow { color: var(--brand-accent); font-family: var(--font-heading); letter-spacing: 3px; font-size: 14px; text-transform: uppercase; margin-bottom: 14px; }
.hef-title { font-family: var(--font-heading); font-weight: 400; font-size: clamp(34px, 6vw, 70px); line-height: 1.05; color: #fff; }
.hef-title span { color: var(--brand-accent); }
.hef-sub { font-family: var(--font-body); color: #b8b8b8; font-size: 18px; line-height: 1.6; margin-top: 14px; }

/* 2-column field grid */
.hef-grid { display: grid; grid-template-columns: 1fr 1fr; gap: 24px 22px; }
.hef-grid .hef-field { margin: 0; }
.hef-grid .hef-full { grid-column: 1 / -1; }

/* labels — BODY font (Manrope) for legibility; the display face was too
   condensed at this size. Consistent 14px, help 12px. */
.hef-grid label { display: block; color: #ededed; font-family: var(--font-body); font-weight: 600; font-size: 16px; letter-spacing: .1px; margin-bottom: 9px; }
.hef-grid .hef-legend { font-size: 16px; }
.hef-grid .req { color: var(--brand-accent); }
.hef-grid .field-help { display: block; margin-top: 7px; font-size: 14px; line-height: 1.45; color: var(--neutral-500); font-family: var(--font-body); font-weight: 400; }

/* inputs (dark) — override the light base by higher specificity */
.hef-grid input[type="text"],
.hef-grid input[type="email"],
.hef-grid input[type="tel"],
.hef-grid input[type="url"],
.hef-grid select,
.hef-grid textarea {
  background: #0d0d0d; border: 1px solid rgba(255, 255, 255, 0.14); color: #fff;
  border-radius: 12px; min-height: 54px; font-size: 16px; padding: 14px 16px;
  font-family: var(--font-body);
  transition: border-color .2s ease, box-shadow .2s ease, background-color .2s ease;
}
.hef-grid input::placeholder, .hef-grid textarea::placeholder { color: #6b6b6b; }
.hef-grid textarea { min-height: 120px; line-height: 1.5; }
.hef-grid input:focus,
.hef-grid select:focus,
.hef-grid textarea:focus {
  border-color: var(--brand-accent); background: #101010;
  outline: none; box-shadow: 0 0 0 3px rgba(191, 247, 71, 0.18);
}
.hef-grid select option { color: #000; } /* native dropdown list stays readable */

/* interest field → chips */
.hef-grid .wpcf7-checkbox { display: flex; flex-wrap: wrap; gap: 9px; margin-top: 2px; }
.hef-grid .wpcf7-checkbox .wpcf7-list-item { margin: 0; }
.hef-grid .wpcf7-checkbox .wpcf7-list-item label {
  display: inline-flex; align-items: center; margin: 0; cursor: pointer;
  border: 1px solid rgba(255, 255, 255, 0.16); border-radius: 30px; padding: 9px 16px;
  transition: background-color .2s ease, border-color .2s ease;
}
.hef-grid .wpcf7-checkbox .wpcf7-list-item label:hover { border-color: rgba(191, 247, 71, 0.5); }
.hef-grid .wpcf7-checkbox .wpcf7-list-item input { position: absolute; opacity: 0; width: 0; height: 0; }
.hef-grid .wpcf7-checkbox .wpcf7-list-item-label { font-family: var(--font-body); font-size: 15px; color: #dcdcdc; }
.hef-grid .wpcf7-checkbox .wpcf7-list-item label:has(input:checked) { background: var(--brand-accent); border-color: var(--brand-accent); }
.hef-grid .wpcf7-checkbox .wpcf7-list-item input:checked + .wpcf7-list-item-label { color: #000; font-weight: 600; }

/* consent (dark) */
.hef-consent { margin-top: 4px; }
.hef-consent .wpcf7-list-item { margin: 0; }
.hef-consent label { display: flex; align-items: flex-start; gap: 11px; margin: 0; color: #9a9a9a; font-family: var(--font-body); font-weight: 400; font-size: 15px; line-height: 1.5; }
.hef-consent input[type="checkbox"] { width: 19px; height: 19px; margin-top: 1px; accent-color: var(--brand-accent); flex: 0 0 auto; }

/* submit (rounded lime, matches site CTAs). !important overrides a theme
   input[type=submit] rule that otherwise greys the button. CF7 6.x disables
   the submit until required fields are valid — style that disabled state as
   dimmed lime so a fresh form reads "fill to enable", not "broken/dead". */
.hef-submit { display: flex; margin-top: 6px; }
.hef-grid .wpcf7-submit {
  background: var(--brand-accent) !important; color: #000 !important; border: 0; border-radius: 50px;
  font-family: var(--font-heading); font-size: 18px; padding: 16px 48px; cursor: pointer;
  transition: background-color .2s ease, opacity .2s ease, transform .2s ease;
}
.hef-grid .wpcf7-submit:hover, .hef-grid .wpcf7-submit:focus { background: var(--accent-dark) !important; transform: translateY(-1px); }
.hef-grid .wpcf7-submit:disabled {
  background: var(--brand-accent) !important; color: #000 !important;
  opacity: 0.4; cursor: not-allowed; transform: none;
}

/* validation / response (dark context) */
.heraedges-form .wpcf7-response-output { color: #fff; border-color: rgba(255, 255, 255, 0.22); background: rgba(255, 255, 255, 0.04); }
.hef-grid .wpcf7-not-valid-tip { color: var(--brand-accent); font-weight: 400; }
.hef-grid .wpcf7-not-valid { border-color: var(--brand-accent) !important; }

@media (max-width: 781px) {
  .hef-grid { grid-template-columns: 1fr; gap: 20px; }
  .heraedges-form .wpcf7 { padding: 28px 20px; }
}

/* Elementor container align-items:center shrinks child widgets to content
   width — force the header + form widgets to fill so the 2-col grid spans
   the boxed section, then center inner blocks via their own max-width. */
.heraedges-form .elementor-widget,
.heraedges-form .elementor-widget-container { width: 100%; }
.heraedges-form .hef-head,
.heraedges-form .wpcf7 { margin-left: auto; margin-right: auto; }

/* ---- Form enhancements: grouped sections, optional tags, char counter,
       submit reassurance. All still inside .hef-grid (scoped to F1). ---- */
.hef-sectionhead {
  display: flex; align-items: center; gap: 12px;
  font-family: var(--font-heading); color: #fff; font-size: 18px;
  margin: 4px 0 2px; padding-bottom: 14px; border-bottom: 1px solid rgba(255, 255, 255, 0.09);
}
.hef-sectionhead + * { margin-top: 2px; }
.hef-grid .hef-sectionhead ~ .hef-sectionhead,
.hef-sectionhead:nth-of-type(2) { margin-top: 22px; }
.hef-sectionhead span {
  flex: 0 0 auto; width: 30px; height: 30px; border-radius: 50%;
  background: var(--brand-accent); color: #000;
  display: flex; align-items: center; justify-content: center; font-size: 15px;
}
.hef-opt {
  font-family: var(--font-body); font-weight: 400; font-size: 12px;
  color: var(--neutral-500); margin-left: 6px; text-transform: none; letter-spacing: 0;
}
.hef-count { float: right; font-family: var(--font-body); font-weight: 400; font-size: 12px; color: var(--neutral-500); }
.hef-count.ok { color: var(--brand-accent); }
.hef-submitrow { display: flex; align-items: center; gap: 20px; flex-wrap: wrap; margin-top: 6px; }
.hef-reassure { color: var(--neutral-500); font-family: var(--font-body); font-size: 14px; }
