/* contact.css: the Contact page's own placing (plan.md, "Contact"), and the kit's full form as components.md describes
   it ("The full form"): an ivory card, the picker's tiles, step markers, fields. Tokens only (system.css). */

/* ---------- #top: the words on the left; the photo set like a print, the note's card overhanging its left edge ------ */
.ct-top { padding-block: clamp(2rem, 1rem + 3vw, 4rem) clamp(3.5rem, 2rem + 4vw, 6rem); }
.ct-top__grid { display: grid; grid-template-columns: minmax(0, 5fr) minmax(0, 7fr); gap: clamp(2.5rem, 1rem + 4vw, 5rem); align-items: center; }
.ct-top__copy { display: grid; gap: var(--space-4); justify-items: start; }
.ct-top h1 { font-size: var(--fs-h1); max-width: 14ch; }
.ct-top__line { font-size: var(--fs-lead); color: var(--c-ink-soft); max-width: 30rem; }
.ct-top__acts { display: flex; flex-wrap: wrap; align-items: center; gap: 0.75rem 1.5rem; }
.ct-top__note { font-size: 1.05rem; }
.ct-top__mail { color: var(--c-ink-soft); }
.ct-top__pic { position: relative; padding: 18px 0 18px 64px; }
/* the print: a white border, turned two degrees, a soft shadow */
.ct-print { margin: 0; padding: 14px 14px 18px; background: var(--c-card); border-radius: 6px; transform: rotate(2deg); box-shadow: 0 2px 4px rgb(13 27 51 / 0.08), 0 26px 50px -24px rgb(13 27 51 / 0.5); }
.ct-print img { display: block; width: 100%; height: auto; aspect-ratio: 3 / 2; object-fit: cover; border-radius: 2px; }
/* the note's card over the laptop's back, clear of Marco's face */
.ct-top__pic .ct-top__scene { position: absolute; left: 0; top: 13%; width: min(360px, 56%); height: 470px; }
.ct-top__stop { top: 34px; right: 14px; }

/* ---------- #form: the kit's form in a card, the side card beside it ---------- */
.cform__grid { display: grid; grid-template-columns: minmax(0, 1fr) minmax(0, 19rem); gap: clamp(1.5rem, 1rem + 2vw, 3rem); align-items: start; }
.cform__main .head { margin-bottom: var(--space-5); }
.cform__card { padding: clamp(1.25rem, 0.9rem + 1.3vw, 2rem); }
.steps-mark { list-style: none; display: flex; gap: 0.5rem; margin: 0 0 1.6rem; padding: 0; }
.steps-mark li { flex: 1; display: flex; align-items: center; gap: 0.55rem; padding-top: 0.75rem; border-top: 3px solid var(--c-line); font: 600 0.92rem/1.2 var(--font-ui); color: var(--c-ink-soft); transition: border-color var(--dur-med), color var(--dur-med); }
.steps-mark li span { flex: none; display: grid; place-items: center; width: 26px; height: 26px; border-radius: 50%; background: var(--c-paper-alt); font: 700 0.85rem/1 var(--font-ui); color: var(--c-ink); transition: background var(--dur-med), color var(--dur-med); }
.steps-mark li[aria-current="step"] { border-color: var(--c-brand); color: var(--c-ink); }
.steps-mark li[aria-current="step"] span { background: var(--c-brand); color: var(--c-on-brand); }
.steps-mark li[data-kit-past] { border-color: var(--c-accent); }
.steps-mark li[data-kit-past] span { background: var(--c-accent); color: var(--c-on-accent); }
.cform__step { min-width: 0; display: grid; gap: 1.1rem; margin: 0; padding: 0; border: 0; }
.cform__legend { margin-bottom: 0.3rem; padding: 0; font: 650 1.4rem/1.25 var(--font-display); color: var(--c-ink); }
.cform__choices { display: grid; grid-template-columns: 1fr 1fr; gap: 0.6rem; }
.cform__choices .choice:nth-of-type(5) { grid-column: 1 / -1; }
.cform__echo { margin: 0; padding: 0.65rem 0.9rem; border-radius: var(--radius-m); background: var(--c-brand-light); font: 500 1rem/1.4 var(--font-ui); color: var(--c-ink); }
.field { display: grid; gap: 0.4rem; }
.field label { font: 650 0.98rem/1.3 var(--font-ui); color: var(--c-ink); }
.field label span { font-weight: 500; color: var(--c-ink-soft); }
.field input, .field textarea { width: 100%; min-height: 50px; padding: 0.75rem 1rem; border: 1px solid var(--c-line); border-radius: var(--radius-m); background: var(--c-paper); font: 500 1rem/1.4 var(--font-ui); color: var(--c-ink); }
.field textarea { min-height: 104px; resize: vertical; }
.field input::placeholder { color: color-mix(in srgb, var(--c-ink-soft) 70%, transparent); }
.field input:focus-visible, .field textarea:focus-visible { outline: 2px solid var(--c-accent); outline-offset: 1px; border-color: var(--c-brand); }
.field [aria-invalid="true"] { border-color: var(--c-error); box-shadow: inset 0 0 0 1px var(--c-error); }
.field__err { margin: 0; font: 600 0.92rem/1.3 var(--font-ui); color: var(--c-error); }
.cform__nav { display: flex; justify-content: flex-end; gap: 0.6rem; margin-top: 0.3rem; }
.cform__card[data-kit-sending] button[type="submit"] { opacity: 0.7; }
.cform__side { position: sticky; top: calc(var(--header-h) + 1.5rem); display: grid; gap: 0.85rem; justify-items: start; margin-top: 28px; padding: 2.5rem 1.5rem 1.5rem; }
.cform__face { position: absolute; top: -28px; left: 1.5rem; width: 56px; height: 56px; border-radius: 50%; object-fit: cover; box-shadow: 0 0 0 3px var(--c-card), 0 0 0 4.5px var(--c-accent), var(--shadow-s); }
.cform__side h3 { font: 650 1.35rem/1.25 var(--font-display); }
.cform__book { width: 100%; }
.cform__side .micro { margin-top: -0.35rem; }
.cform__mail, .cform__reply { margin: 0; }
.cform__reply { font-size: var(--fs-small); color: var(--c-ink-soft); }

/* ---------- #next, on the designed ground: the route from one note to a plan ---------- */
.page-contact .ground { overflow: clip; }
.ct-next__k { left: -14%; bottom: -26%; }
.ct-next__head { margin-bottom: var(--space-5); }
.ct-next__stage { position: relative; height: 460px; }
.ct-next__stage .ct-next__scene { position: absolute; inset: 0; }
.ct-next__stop { top: -48px; right: 0; }

@media (min-width: 1000px) and (max-width: 1199px) {
  /* a narrower print, so a taller photo: the note's card still stands on it, Marco's face clear on the right */
  .ct-print img { aspect-ratio: auto; height: 440px; object-position: 60% 40%; }
  .ct-top__pic .ct-top__scene { top: 40px; }
}
@media (max-width: 999px) {
  /* one column: the words and both ways to start first, then the photo and its story */
  .ct-top__grid { grid-template-columns: 1fr; }
  .ct-top__pic { max-width: 46rem; }
  .ct-top__copy { max-width: 40rem; }
}
@media (max-width: 900px) {
  .cform__grid { grid-template-columns: 1fr; }
  .cform__side { position: relative; top: auto; }
}
@media (max-width: 760px) {
  /* the photo straight and tall: the note's card (365px at its fullest) stands on its lower half, under Marco's smile */
  .ct-top__pic { padding: 0 0 156px; }
  .ct-print { padding: 0; background: none; border-radius: var(--radius-l); overflow: hidden; transform: none; box-shadow: var(--shadow-l); }
  .ct-print img { aspect-ratio: auto; height: 460px; object-position: 72% 40%; border-radius: 0; }
  .ct-top__pic .ct-top__scene { left: 12px; right: auto; top: 236px; width: min(420px, calc(100% - 24px)); height: 380px; }
  .ct-top__stop { top: 190px; right: 12px; }
  .steps-mark li { font-size: 0.8rem; }
}
/* the route turns upright on a stage under 700 px wide: its four stations need the taller stage */
.ct-next > .wrap { container-type: inline-size; }
@container (width < 700px) {
  .ct-next__stage { height: 620px; }
}
@media (max-width: 560px) {
  .cform__choices { grid-template-columns: 1fr; }
  .cform__choices .choice:nth-of-type(5) { grid-column: auto; }
}
