/* steveogilvie.com — contact form.
   Uses the design's own tokens (--primary lime, --background, Geist) so the
   form reads as part of the page rather than a bolted-on widget. */

.contact-form-wrap {
  margin-top: 55px;
  border-top: 1px solid #ffffff25;
  padding-top: 45px;
  display: grid;
  grid-template-columns: minmax(0, 1fr) minmax(0, 1.15fr);
  gap: 60px;
  align-items: start;
}

.contact-aside p {
  color: #aab5ac;
  font-size: 1rem;
  line-height: 1.8;
  margin: 0 0 22px;
  max-width: 420px;
}

.contact-aside .eyebrow {
  color: #a5b29f;
  margin: 0 0 22px;
  display: block;
}

.contact-aside-links {
  display: flex;
  flex-direction: column;
  align-items: start;
  gap: 18px;
  margin-top: 30px;
}

.contact-form {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 22px;
}

.field {
  display: flex;
  flex-direction: column;
  gap: 9px;
  min-width: 0;
}

.field-wide {
  grid-column: 1 / -1;
}

.field label {
  font: 500 0.75rem/1.6 var(--font-geist-mono), monospace;
  letter-spacing: 0.1em;
  color: #a5b29f;
  text-transform: uppercase;
}

.field label .optional {
  color: #7f8c81;
  letter-spacing: 0.04em;
}

.field input,
.field textarea {
  font: inherit;
  font-size: 0.9375rem;
  color: var(--foreground);
  background: #141916;
  border: 1px solid #303830;
  border-radius: 3px;
  padding: 14px 15px;
  width: 100%;
  transition: border-color 0.2s, background 0.2s;
}

.field textarea {
  resize: vertical;
  min-height: 132px;
  line-height: 1.65;
}

.field input:hover,
.field textarea:hover {
  border-color: #46523f;
}

.field input:focus,
.field textarea:focus {
  outline: 2px solid var(--primary);
  outline-offset: 2px;
  border-color: transparent;
  background: #171d19;
}

.field.is-invalid input,
.field.is-invalid textarea {
  border-color: #ff7a7a;
}

.field-error {
  font-size: 0.8125rem;
  color: #ff9c9c;
  min-height: 0;
}

/* Honeypot. Hidden from sighted users AND from screen readers, because a
   screen reader user filling it in would be silently discarded. */
.hp-field {
  position: absolute;
  left: -9999px;
  width: 1px;
  height: 1px;
  overflow: hidden;
}

.form-foot {
  grid-column: 1 / -1;
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  justify-content: space-between;
  gap: 20px;
  margin-top: 4px;
}

.cf-turnstile {
  min-height: 65px;
}

.contact-form button[type='submit'] {
  border: 1px solid transparent;
}

.contact-form button[type='submit']:disabled {
  opacity: 0.55;
  cursor: not-allowed;
  transform: none;
}

.form-error {
  grid-column: 1 / -1;
  border: 1px solid #6d3b3b;
  background: #241717;
  color: #ffb4b4;
  border-radius: 3px;
  padding: 14px 16px;
  font-size: 0.875rem;
  line-height: 1.6;
}

.form-confirmation {
  border: 1px solid #59694c;
  background: #161d13;
  border-radius: 3px;
  padding: 30px 28px;
}

.form-confirmation h3 {
  margin: 0 0 12px;
  font-size: 1.5rem;
  font-weight: 550;
  letter-spacing: -0.03em;
  color: var(--primary);
}

.form-confirmation p {
  margin: 0;
  color: #aab5ac;
  font-size: 1rem;
  line-height: 1.75;
}

.form-confirmation:focus {
  outline: 2px solid var(--primary);
  outline-offset: 6px;
}

@media (max-width: 1100px) {
  .contact-form-wrap {
    grid-template-columns: 1fr;
    gap: 40px;
  }
}

@media (max-width: 700px) {
  .contact-form-wrap {
    margin-top: 35px;
    padding-top: 32px;
  }
  .contact-form {
    grid-template-columns: 1fr;
    gap: 18px;
  }
  .form-foot {
    align-items: stretch;
    flex-direction: column;
  }
  .form-foot .button {
    width: 100%;
  }
}
