/* Contact Form 7 on the prototype's form (Let's talk). The fields keep the
   base styles of .form, label, input/select/textarea (site/01-base.css): this
   file covers the markup CF7 adds and the states the prototype doesn't have.
   It replaces the plugin's stylesheet, which inc/contact-form.php turns off. */

/* ---------- Plugin markup ---------- */

.wpcf7 .screen-reader-response {
  position: absolute;
  width: 1px;
  height: 1px;
  margin: -1px;
  padding: 0;
  overflow: hidden;
  clip-path: inset(50%);
  border: 0;
  white-space: nowrap;
}
.wpcf7 .hidden-fields-container { display: none; }

/* ---------- Invalid fields ---------- */

.wpcf7 .wpcf7-not-valid { border-color: var(--color-error); }
.wpcf7 .wpcf7-not-valid:focus { box-shadow: 0 0 0 3px rgb(from var(--color-error) r g b / 0.14); }
.wpcf7-not-valid-tip {
  display: block;
  margin-top: 7px;
  color: var(--color-error);
  font-size: var(--fs-small);
  font-weight: 600;
}

/* ---------- Response box (after the button) ---------- */

.wpcf7-response-output {
  padding: 12px 14px;
  border: 1px solid var(--line);
  border-radius: 13px;
  font-size: var(--fs-small);
  line-height: 1.5;
}
.wpcf7 form.init .wpcf7-response-output,
.wpcf7 form.resetting .wpcf7-response-output,
.wpcf7 form.submitting .wpcf7-response-output { display: none; }
.wpcf7 form.sent .wpcf7-response-output {
  border-color: rgb(from var(--color-success) r g b / 0.55);
  background: rgb(from var(--color-success) r g b / 0.08);
  color: var(--color-text-on-dark);
}
.wpcf7 form:is(.invalid, .unaccepted, .failed, .aborted, .spam) .wpcf7-response-output {
  border-color: rgb(from var(--color-error) r g b / 0.55);
  background: rgb(from var(--color-error) r g b / 0.08);
  color: var(--color-text-on-dark);
}

/* ---------- Sending ---------- */

/* No spinner next to the button: it would take a row of the .form grid. */
.wpcf7 form.submitting .btn {
  opacity: 0.6;
  cursor: progress;
  pointer-events: none;
}

/* ---------- Privacy note ---------- */

.wpcf7 .notice a {
  text-decoration: underline;
  text-underline-offset: 2px;
}
.wpcf7 .notice a:hover { color: var(--color-text-on-dark); }
