/* Additions for the PHP contact form; layout comes from the theme's .contact_form rules. */
.contact_hp {
  position: absolute;
  left: -10000px;
  width: 1px;
  height: 1px;
  overflow: hidden;
}
.contact_alert {
  margin: 0 0 32px;
  padding: 12px 16px;
  border: 1px solid #dc3232;
  color: #dc3232;
}
.contact_notice {
  margin: 0 0 32px;
  padding: 12px 16px;
  border: 1px solid #8c80b8;
  color: #5d5290;
  text-align: center;
}
.contact_error {
  margin-top: 6px;
  color: #dc3232;
  font-size: 13px;
}
/* Underline-only fields (the theme's look) with a calmer, consistent box. */
body #wrapper main .contact_form dl .contact_row dt span {
  margin-left: 10px;
}
body #wrapper main .contact_form dl .contact_row dd input,
body #wrapper main .contact_form dl .contact_row dd textarea {
  /* Width stays with the theme: 550px beside the label on wide screens, 100% when stacked. */
  box-sizing: border-box;
  padding: 8px 2px;
  border: none;
  border-bottom: 1px solid #dcd8ea;
  border-radius: 0;
  background: transparent;
  font: inherit;
  color: #333;
  line-height: 1.6;
  transition: border-color .2s;
}
body #wrapper main .contact_form dl .contact_row dd textarea {
  min-height: 160px;
  resize: vertical;
}
body #wrapper main .contact_form dl .contact_row dd input:focus,
body #wrapper main .contact_form dl .contact_row dd textarea:focus {
  outline: none;
  border-bottom: 2px solid #8c80b8;
  padding-bottom: 7px;
}
/* Chrome/Safari autofill paints a blue box; keep the field white. */
body #wrapper main .contact_form dl .contact_row dd input:-webkit-autofill {
  -webkit-box-shadow: 0 0 0 1000px #fff inset;
  -webkit-text-fill-color: #333;
}
body #wrapper main .contact_form dl .contact_row dd [aria-invalid="true"] {
  border-bottom-color: #dc3232;
}
.contact_lead {
  margin-bottom: 40px;
  text-align: center;
}
.contact_value {
  white-space: pre-wrap;
  word-break: break-word;
}
.contact_turnstile {
  display: flex;
  justify-content: center;
  margin-top: 20px;
}
/* Done / error pages: short text, so centre it under the centred page title. */
.contact_message {
  text-align: center;
}
.contact_message p {
  margin-bottom: 1.5em;
}
/* The theme button reserves room for its arrow on the right; keep its label left-aligned. */
.contact_message .tataya-btn {
  text-align: left;
}
.contact_back {
  margin-top: 40px;
}
/* Phones: the theme stacks the buttons but leaves them at the left edge, with arrows placed by a
   fixed left offset that only fits one label. Give every button the same 250px box (like .tataya-btn),
   centre it, and pin the arrow to its right edge. */
@media screen and (max-width: 640px) {
  body #wrapper main .contact_form .contact_submit {
    align-items: center;
  }
  body #wrapper main .contact_form .contact_submit .tataya-submit p input[type="submit"],
  body #wrapper main .contact_form .contact_submit .tataya-submit.check p input[type="submit"],
  body #wrapper main .contact_form .contact_submit .tataya-submit.pre p input[type="button"] {
    box-sizing: border-box;
    width: 250px;
    padding: 7px 40px 7px 23px;
    text-align: left;
  }
  body #wrapper main .contact_form .contact_submit .tataya-submit::before,
  body #wrapper main .contact_form .contact_submit .tataya-submit.pre::before,
  body #wrapper main .contact_form .contact_submit .tataya-submit::after,
  body #wrapper main .contact_form .contact_submit .tataya-submit.pre::after {
    left: auto;
    right: 10px;
  }
}
