/* ==========================================================================
   Block: Contact form
   --------------------------------------------------------------------------
   No comp exists for this page yet (see the brief this was built against) —
   every value here is an existing token, nothing new. Expect this to be
   restyled once a comp exists; kept deliberately plain so that is cheap.
   ========================================================================== */

.awx-cf__header {
  max-width: var(--awx-measure);
  margin-bottom: var(--awx-space-lg);
}

.awx-cf__grid {
  display: grid;
  grid-template-columns: 1fr;
  gap: var(--awx-space-md);
}

@media (min-width: 40rem) {
  .awx-cf__grid {
    grid-template-columns: repeat(2, 1fr);
  }

  .awx-cf__field--full {
    grid-column: 1 / -1;
  }
}

.awx-cf__field {
  display: flex;
  flex-direction: column;
  gap: var(--awx-space-2xs);
}

.awx-cf__field label {
  color: var(--surface-heading);
  font-size: var(--awx-step--1);
  font-weight: 600;
}

.awx-cf__field input,
.awx-cf__field select,
.awx-cf__field textarea {
  width: 100%;
  padding: 0.75rem 1rem;
  border: var(--awx-rule) solid var(--surface-rule);
  border-radius: var(--awx-radius);
  background: var(--surface-bg);
  color: var(--surface-text);
  font-family: var(--awx-font-body);
  font-size: var(--awx-step-0);
}

.awx-cf__field textarea {
  resize: vertical;
}

.awx-cf__field input:focus-visible,
.awx-cf__field select:focus-visible,
.awx-cf__field textarea:focus-visible {
  outline: 2px solid var(--surface-accent);
  outline-offset: 2px;
}

/* No error/danger token exists in tokens.css, and this page's own brief
   says not to introduce any new colour — so invalid fields borrow the
   site's existing accent colour (gold) rather than a made-up red. It is
   already the colour used elsewhere for anything that needs attention
   (focus rings, active states), so this is a reuse, not a new colour. */
.awx-cf__field input[aria-invalid="true"],
.awx-cf__field select[aria-invalid="true"],
.awx-cf__field textarea[aria-invalid="true"] {
  border-color: var(--surface-accent);
  border-width: 2px;
}

.awx-cf__error {
  color: var(--surface-heading);
  font-size: var(--awx-step--1);
  font-weight: 600;
}

.awx-cf__actions {
  margin-top: var(--awx-space-lg);
}

/* ---- Error summary ------------------------------------------------------- */

.awx-cf__summary {
  margin-bottom: var(--awx-space-lg);
  padding: var(--awx-space-sm) var(--awx-space-md);
  border: var(--awx-rule) solid var(--surface-accent); /* same reasoning as the invalid-field border above */
  border-radius: var(--awx-radius);
}

.awx-cf__summary:focus-visible {
  outline: 2px solid var(--surface-accent);
  outline-offset: 2px;
}

.awx-cf__summary-heading {
  margin: 0 0 var(--awx-space-2xs);
  color: var(--surface-heading);
  font-weight: 700;
}

.awx-cf__summary ul {
  margin: 0;
  padding-left: 1.25rem;
}

/* ---- Success state --------------------------------------------------------- */

.awx-cf__success {
  max-width: var(--awx-measure);
  padding: var(--awx-space-md);
  border: var(--awx-rule) solid var(--surface-rule);
  border-radius: var(--awx-radius);
}

.awx-cf__success-heading {
  margin: 0 0 var(--awx-space-2xs);
  color: var(--surface-heading);
  font-family: var(--awx-font-display);
  font-size: var(--awx-step-1);
  font-weight: 700;
}

/* ---- Honeypot -------------------------------------------------------------- */

/* Visually hidden, not display:none — a display:none field is exactly what
   some spam bots are coded to skip, since it is the one hiding technique
   they check for. This keeps the field present and "visible" to a naive
   bot's DOM scan while removing it from sighted view, and aria-hidden plus
   tabindex="-1" (in the markup) keep a real keyboard or screen-reader user
   from ever landing on it either. */
.awx-cf__honeypot {
  position: absolute;
  width: 1px;
  height: 1px;
  margin: -1px;
  padding: 0;
  overflow: hidden;
  clip: rect(0, 0, 0, 0);
  white-space: nowrap;
  border: 0;
}
