/* Contact section of the static site (exporter --contact-form). Fields, buttons, panels and errors come from
   site.css; this sheet only adds the layout, the e-mail card, the choice group and the result box, with the
   site's own tokens (black, white and grays). */
/* [hidden] must win over the display values below (the form only appears once its script runs). */
.contact-static [hidden] { display: none !important; }
.contact-layout { display: grid; grid-template-columns: minmax(0, 5fr) minmax(0, 7fr); gap: clamp(40px, 6vw, 88px); align-items: start; }
.contact-aside { position: sticky; top: 104px; }
.contact-aside h2 { font-size: clamp(1.75rem, 3vw, 2.4rem); margin-bottom: 16px; }
.contact-aside .lead { margin-bottom: 32px; }

/* The address is the first thing a visitor needs: a black card, large type, easy to tap or copy. */
.contact-email-card { margin: 0 0 40px; padding: clamp(24px, 3vw, 32px); border-radius: var(--radius-lg); background: var(--black); color: var(--on-dark-muted); }
.contact-email-line { margin: 0; display: flex; flex-direction: column; gap: 8px; }
.contact-email-label { font: 600 .78rem/1 var(--display); letter-spacing: .14em; text-transform: uppercase; color: var(--on-dark-muted); }
.contact-email-card .contact-email-link { font: 600 clamp(1.3rem, 2.4vw, 1.75rem)/1.2 var(--display); letter-spacing: -.015em; color: var(--white);
  text-decoration: underline; text-decoration-thickness: 1px; text-underline-offset: 5px; overflow-wrap: anywhere; }
.contact-email-card .contact-email-link:hover { color: var(--white); text-decoration-thickness: 2px; }
.contact-email-card :focus-visible { outline-color: var(--white); }
.contact-email-note { margin: 12px 0 0; font-size: .95rem; }
.contact-next-title { font-size: 1.1rem; margin-bottom: 16px; }

/* The form panel. */
.contact-form { display: grid; gap: 32px; }
.contact-form-title { font-size: clamp(1.4rem, 2.2vw, 1.75rem); margin: 0; }
.contact-form-intro { margin: -20px 0 0; color: var(--muted); }
.contact-form > fieldset { display: grid; gap: 20px; padding-top: 28px; border-top: 1px solid var(--line-light); }
.contact-form > fieldset > legend { float: left; width: 100%; margin-bottom: 4px; }
.contact-form legend h3 { margin: 0; font-size: 1.05rem; letter-spacing: .01em; }
.req { color: var(--ink); font-weight: 700; }
.optional { color: var(--muted); font-weight: 400; }
.contact-summary:focus { outline: 2px solid var(--ink); outline-offset: 2px; }
.contact-summary.is-error { background: var(--paper); color: var(--ink); border: 1px solid var(--ink); border-left-width: 4px; font-weight: 600; }

/* Preferred contact: four large, tappable options. */
.contact-choice-legend { display: block; font: 600 .9rem var(--display); margin-bottom: 8px; color: var(--ink); }
.contact-options { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 8px; }
.field-half { max-width: calc(50% - 10px); }
.contact-option { display: flex; align-items: center; gap: 10px; min-height: 50px; padding: 0 14px; border: 1px solid var(--line-strong);
  border-radius: var(--radius); background: var(--white); font: 400 .95rem/1.3 var(--font); color: var(--text); cursor: pointer; }
.field label.contact-option { display: flex; margin: 0; font: 400 .95rem/1.3 var(--font); }
.contact-option input { width: 18px; height: 18px; margin: 0; flex: none; accent-color: var(--black); }
.contact-option:has(input:checked) { border-color: var(--ink); box-shadow: inset 0 0 0 1px var(--ink); font-weight: 600; }
.contact-option:has(input:focus-visible) { outline: 2px solid var(--ink); outline-offset: 2px; }

.contact-submit { display: grid; gap: 12px; justify-items: start; padding-top: 8px; }
.contact-submit .btn { min-width: 260px; }
.contact-submit p { margin: 0; }

/* After validation: what happened and the complete summary to copy. */
.contact-result { display: grid; gap: 14px; padding: 24px; border: 1px solid var(--ink); border-radius: var(--radius-lg); background: var(--paper); }
.contact-result p { margin: 0; }
.contact-result-title { margin: 0; font-size: 1.2rem; }
.contact-result-title:focus { outline: none; }
.contact-result-label { font: 600 .9rem var(--display); color: var(--ink); }
.contact-preview { width: 100%; min-height: 220px; padding: 12px 14px; border: 1px solid var(--line-strong); border-radius: var(--radius);
  background: var(--white); color: var(--text); font: 400 .9rem/1.5 var(--mono); resize: vertical; }

@media (max-width: 960px) {
  .contact-layout { grid-template-columns: 1fr; }
  .contact-aside { position: static; }
}
@media (max-width: 640px) {
  .field-half { max-width: none; }
  .contact-submit .btn { width: 100%; min-width: 0; }
  .contact-result .btn-row .btn { width: 100%; }
}
