/* ==========================================================================
   Contact page: two-column layout (form left ~45%, portrait photo right
   ~55%), stacking to a single column (form on top, photo below -- just
   from DOM order once the grid collapses to 1fr, no extra CSS needed) on
   narrower screens.
   ========================================================================== */

.contact-section {
  padding: calc(var(--nav-height) + 64px) 0 120px;
}

.contact-grid {
  display: grid;
  grid-template-columns: 0.9fr 1.1fr; /* ~45/55 split */
  gap: 64px;
  align-items: start;
}

/* ---- Left column: copy + form ---- */

.contact-heading {
  margin-top: 4px;
  font-family: var(--font-serif);
  font-size: clamp(2rem, 4vw, 3.25rem);
  font-weight: 400;
  letter-spacing: 0.04em;
  text-transform: uppercase;
}

.contact-form {
  margin-top: 40px;
  display: flex;
  flex-direction: column;
  gap: 22px;
  max-width: 480px;
}

.form-row {
  display: flex;
  flex-direction: column;
  gap: 8px;
}

.form-row label {
  font-size: 0.75rem;
  letter-spacing: 0.15em;
  text-transform: uppercase;
  color: var(--text-dim);
}

/* Light fields on the dark page background -- reads as more inviting/
   legible than dark-on-dark inputs would. */
.form-row input,
.form-row select,
.form-row textarea {
  background: var(--text); /* #f2f2f0 -- off-white, same token as body text color elsewhere */
  color: #111;
  border: none;
  border-radius: 2px;
  padding: 14px 16px;
  font-family: var(--font);
  font-size: 16px; /* iOS Safari auto-zooms the viewport on focus for any field under 16px -- must stay at/above this */
  width: 100%;
}

.form-row textarea {
  resize: vertical;
  min-height: 140px;
  line-height: 1.5;
}

.form-row select {
  cursor: pointer;
}

.form-row input:focus,
.form-row select:focus,
.form-row textarea:focus {
  outline: 2px solid var(--accent-blue);
  outline-offset: 1px;
}

.form-row input::placeholder,
.form-row textarea::placeholder {
  color: #767672;
}

/* Honeypot -- present in the DOM for bots to find, invisible and
   unreachable (no tab stop, hidden from AT) for real visitors. */
.contact-honeypot {
  position: absolute;
  left: -9999px;
  width: 1px;
  height: 1px;
  overflow: hidden;
}

.form-status {
  font-size: 0.85rem;
}

.form-status.is-error {
  color: #ff8a8a;
}

.form-status.is-success {
  color: #8fe0a8;
}

.contact-submit {
  align-self: flex-start;
  margin-top: 8px;
  padding: 16px 40px;
  border: 1px solid var(--text);
  background: transparent;
  color: var(--text);
  font-size: 0.78rem;
  letter-spacing: 0.2em;
  text-transform: uppercase;
  transition: background 0.3s var(--ease), color 0.3s var(--ease);
}

.contact-submit:hover {
  background: var(--text);
  color: #000;
}

/* ---- Right column: portrait photo ---- */

.contact-col-photo {
  position: relative;
}

.contact-photo-frame {
  position: relative;
}

/* The accent rectangle sits behind the photo, flush on top/right, and
   extends 20px past the photo's left and bottom edges -- that's the only
   part of it left visible, reading as an offset shadow/frame on those two
   sides. */
.contact-photo-frame::before {
  content: "";
  position: absolute;
  inset: 0 0 -20px -20px;
  background: var(--accent-blue);
  z-index: 0;
}

.contact-photo {
  position: relative;
  z-index: 1;
  display: block;
  width: 100%;
  height: 100%;
  object-fit: cover;
}

/* ---- Responsive ---- */

@media (max-width: 860px) {
  .contact-grid {
    grid-template-columns: 1fr;
    gap: 48px;
  }

  .contact-form {
    max-width: none;
  }
}

@media (max-width: 640px) {
  .contact-section {
    padding-bottom: 80px;
  }

  .contact-photo-frame::before {
    inset: 0 0 -12px -12px;
  }
}
