/* ============================================================
   Contact Form
   ============================================================ */

.ucf {
  max-width: 600px;
  margin: 0;
  padding: 0;
  box-sizing: border-box;
  line-height: 1.5;
  color: #1a1a1a;
  background-color: #ffffff; /* explicit — stops scanner walking up into page DOM */
}

.ucf *,
.ucf *::before,
.ucf *::after {
  box-sizing: border-box;
}

/* ── Container ─────────────────────────────────────────────── */
.ucf__container {
  background: #ffffff;
  padding: 32px;
  border-radius: 8px;
  border: 1px solid #c8cdd3;
}

/* ── Heading & description ─────────────────────────────────── */
.ucf__title {
  margin: 0 0 8px;
  font-size: 1.5rem;
  font-weight: 700;
  color: #1a1a1a;
  text-align: center;
}

.ucf__description {
  margin: 0 0 28px;
  font-size: 0.9375rem;
  color: #3d4550;
  text-align: center;
}

/* ── Required note ─────────────────────────────────────────── */
.ucf__required-note {
  font-size: 0.875rem;
  color: #3d4550;
  margin-bottom: 24px;
  display: block;
}

/* ── Form groups ───────────────────────────────────────────── */
.ucf__group {
  margin-bottom: 22px;
}

/* ── Labels ────────────────────────────────────────────────── */
.ucf__label {
  display: block;
  margin-bottom: 6px;
  font-size: 0.9375rem;
  font-weight: 600;
  color: #1a1a1a;
}

.ucf__required {
  color: #b91c1c;
  margin-left: 3px;
  font-weight: 700;
}

/* ── Inputs & Textarea ─────────────────────────────────────── */
.ucf__input {
  display: block;
  width: 100%;
  padding: 11px 14px;
  border: 2px solid #6b7280;
  border-radius: 5px;
  font-size: 1rem;
  font-family: inherit; /* inherit from page */
  color: #1a1a1a;
  background-color: #ffffff;
  transition: border-color 0.2s ease, box-shadow 0.2s ease;
  appearance: none;
  -webkit-appearance: none;
}

.ucf__input:hover {
  border-color: #374151;
}

.ucf__input:focus {
  outline: 3px solid #2563eb;
  outline-offset: 2px;
  border-color: #2563eb;
  box-shadow: none;
}

.ucf__input:invalid {
  border-color: #6b7280;
  box-shadow: none;
}

.ucf__textarea {
  min-height: 120px;
  resize: vertical;
  background-color: #ffffff; /* explicit — required for accessibility scanners */
  color: #1a1a1a;            /* explicit — ensures contrast is unambiguous */
  display: block;            /* ensures no inherited inline display issues */
}

/* ── Inline error messages ─────────────────────────────────── */
.ucf__error {
  display: none;
  margin-top: 6px;
  font-size: 0.875rem;
  color: #b91c1c;
  font-weight: 600;
}

.ucf__error::before {
  content: "⚠ ";
}

.ucf__input--error {
  border-color: #b91c1c;
}

.ucf__input--error:focus {
  outline-color: #b91c1c;
  border-color: #b91c1c;
}

/* ── Submit button ─────────────────────────────────────────── */
.ucf__submit {
  display: block;
  width: 100%;
  padding: 14px 20px;
  background-color: #021D4A;
  color: #ffffff;
  border: 2px solid transparent;
  border-radius: 5px;
  font-size: 1rem;
  font-weight: 700;
  font-family: inherit;
  cursor: pointer;
  transition: background-color 0.2s ease, box-shadow 0.2s ease;
  margin-top: 10px;
  text-align: center;
}

.ucf__submit:hover {
  background-color: #0a4299;
}

.ucf__submit:focus {
  outline: 3px solid #0a4299;
  outline-offset: 3px;
  background-color: #0a4299;
}

.ucf__submit:active {
  background-color: #0a4299;
}

.ucf__submit:disabled,
.ucf__submit[aria-disabled="true"] {
  background-color: #6b7280;
  cursor: not-allowed;
  pointer-events: none;
}

/* ── Status / alert region ─────────────────────────────────── */
.ucf__status {
  margin-top: 20px;
  padding: 14px 18px;
  border-radius: 5px;
  font-size: 0.9375rem;
  font-weight: 600;
  border: 2px solid transparent;
  display: none;
}

.ucf__status--success {
  background-color: #f0fdf4;
  border-color: #16a34a;
  color: #14532d;
}

.ucf__status--error {
  background-color: #fef2f2;
  border-color: #b91c1c;
  color: #7f1d1d;
}

/* ── Honeypot — visually hidden but present in DOM ──────────
   Do NOT use display:none or visibility:hidden — bots ignore
   those and skip the field. Position off-screen instead so
   it exists in the DOM but is invisible to real users.
   aria-hidden on the parent keeps it out of the a11y tree.   */
.ucf__honeypot {
  position: absolute;
  left: -9999px;
  top: -9999px;
  width: 1px;
  height: 1px;
  overflow: hidden;
  opacity: 0;
  pointer-events: none;
}

/* ── Screen-reader only utility ────────────────────────────── */
.ucf-sr-only {
  position: absolute;
  width: 1px;
  height: 1px;
  padding: 0;
  margin: -1px;
  overflow: hidden;
  clip: rect(0, 0, 0, 0);
  white-space: nowrap;
  border: 0;
}

/* ── Responsive ────────────────────────────────────────────── */
@media (max-width: 600px) {
  .ucf__container {
    padding: 20px 16px;
  }

  .ucf__title {
    font-size: 1.25rem;
  }
}

/* ── Placeholder text ───────────────────────────────────────
   #767676 on #ffffff = 4.54:1 — just meets WCAG AA 4.5:1.
   Do not lighten this further or it will fail contrast.       */
.ucf__input::placeholder {
  color: #767676;
  opacity: 1; /* Firefox reduces opacity by default */
}
   Some scanners cannot resolve background-color through the DOM
   hierarchy and require it set directly on the element by ID.   */
#ucf-comments {
  background-color: #ffffff;
  color: #1a1a1a;
}

/* ── Reduced motion ─────────────────────────────────────────── */
@media (prefers-reduced-motion: reduce) {
  .ucf__input,
  .ucf__submit {
    transition: none;
  }
}