/* ==========================================================================
   Arch Metrics — contact page
   Loads after homepage.css and reuses its tokens, nav, footer and buttons.
   Adds only what the contact page needs. No framework, no CDN.
   ========================================================================== */

.contact { padding: 88px 0 104px; }

/* Narrative 42% / form 58%, with a substantial gutter between them. */
.contact__grid {
  display: grid;
  grid-template-columns: minmax(0, 42fr) minmax(0, 58fr);
  gap: 80px;
  align-items: start;
}

/* --- Intro column ------------------------------------------------------- */
.contact__intro h1 {
  font-family: var(--serif);
  font-size: clamp(34px, 3.9vw, 50px);
  line-height: 1.07;
  letter-spacing: -0.03em;
  text-wrap: balance;
}

.contact__lede {
  margin-top: 26px;
  padding-top: 26px;
  border-top: 1px solid var(--line);
  font-size: 18.5px;
  line-height: 1.62;
  color: var(--ink-2);
}

/* --- Form panel --------------------------------------------------------- */
.contact__panel {
  position: relative;
  width: 100%;
  background: var(--bg-alt);
  border: 1px solid var(--line);
  border-radius: 6px;
  padding: 42px 42px 38px;
  box-shadow: 0 1px 2px rgba(15, 28, 46, .03);
}

/* --- Field grid: Name + Company share row 1; Email and textarea full ---- */
.cform__grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 26px 22px;
  width: 100%;
}
.cform__field { min-width: 0; }
.cform__field--full { grid-column: 1 / -1; }

.cform__label {
  display: block;
  font-size: 12.5px;
  font-weight: 600;
  letter-spacing: 0.11em;
  text-transform: uppercase;
  color: var(--ink);
  margin-bottom: 9px;
}

.cform__opt {
  font-weight: 500;
  letter-spacing: 0.04em;
  text-transform: none;
  color: var(--muted-2);
  margin-left: 6px;
}

.cform__input {
  display: block;
  width: 100%;
  max-width: 100%;
  box-sizing: border-box;
  height: 52px;
  font-family: var(--sans);
  font-size: 16.5px;
  line-height: 1.5;
  color: var(--ink);
  background: #fff;
  border: 1px solid #d3dde8;
  border-radius: 3px;
  padding: 0 15px;
  appearance: none;
  -webkit-appearance: none;
  transition: border-color .16s ease, box-shadow .16s ease;
}

.cform__input::placeholder { color: var(--muted-2); }
.cform__input:hover { border-color: #bccbdb; }

/* Strong, high-contrast focus ring. */
.cform__input:focus,
.cform__input:focus-visible {
  outline: none;
  border-color: var(--brand);
  box-shadow: 0 0 0 3px rgba(7, 75, 131, .18);
}

.cform__textarea {
  height: 190px;
  min-height: 190px;
  padding: 14px 15px;
  resize: vertical;
}

/* --- Verification slot -------------------------------------------------- */
.cform__verify { margin-top: 30px; min-height: 65px; }

/* --- Submit ------------------------------------------------------------- */
.cform__submit {
  margin-top: 28px;
  width: 100%;
  justify-content: center;
  height: 54px;
  padding: 0 26px;
  font-size: 15.5px;
  border-radius: 3px;
}

.cform__hint {
  margin-top: 16px;
  font-size: 13.5px;
  line-height: 1.55;
  color: var(--muted);
}

/* --- Inline error ------------------------------------------------------- */
.cform__alert {
  margin-bottom: 26px;
  padding: 15px 18px;
  background: #fff;
  border: 1px solid var(--line);
  border-left: 3px solid #b0413e;
  border-radius: 3px;
  font-size: 15px;
  line-height: 1.5;
  color: var(--ink-2);
}

/* --- Honeypot: never visible to a human, in any state ------------------- */
.cform__hp {
  display: none !important;
}

/* --- Panel states (success / unavailable) ------------------------------- */
.panelstate { padding: 8px 0 6px; }
.panelstate h2 {
  font-family: var(--serif);
  font-size: 30px;
  line-height: 1.15;
  letter-spacing: -0.024em;
  color: var(--ink);
  margin-bottom: 14px;
}
.panelstate p { font-size: 17px; line-height: 1.6; color: var(--ink-2); }
.panelstate p + p { margin-top: 14px; }
.panelstate__back { font-size: 15px; }

/* --- Local development preview only --------------------------------------
   Neither of these can render in production: the page only emits them when
   the config is absent AND the request is loopback on a local dev server. */

/* Placeholder holding the real Turnstile footprint (~300x65). */
.cform__verify-ph {
  display: flex;
  align-items: center;
  gap: 10px;
  width: 300px;
  max-width: 100%;
  height: 65px;
  padding: 0 18px;
  border: 1px solid var(--line);
  border-radius: 3px;
  background: #fff;
  font-size: 13.5px;
  color: var(--muted-2);
}
.cform__verify-ph-dot {
  width: 15px;
  height: 15px;
  border: 1.5px solid #cfdae6;
  border-radius: 50%;
  flex: none;
}

/* Tiny corner badge — out of flow, so it cannot distort the layout. */
.cform__devbadge {
  position: absolute;
  top: 10px;
  right: 12px;
  font-size: 9.5px;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  color: #b6c3d1;
  pointer-events: none;
}

/* --- Responsive --------------------------------------------------------- */
@media (max-width: 820px) {
  .contact { padding: 56px 0 72px; }
  .contact__grid { grid-template-columns: 1fr; gap: 40px; }
  .contact__panel { padding: 36px 30px 32px; }
}

@media (max-width: 620px) {
  .contact { padding: 44px 0 60px; }
  .contact__panel { padding: 26px 20px 24px; }
  .contact__lede { font-size: 17.5px; }

  /* Every field full width on mobile. */
  .cform__grid { grid-template-columns: 1fr; gap: 22px; }
  .cform__textarea { height: 180px; min-height: 180px; }

  .panelstate h2 { font-size: 26px; }

  /* iOS zooms any field under 16px on focus. */
  .cform__input { font-size: 16px; }
}
