/* Contact. The headline and the address are the stage; the form is the system's field component, enlarged.
   Loads after site.css. Colours, easing and spacing come from its tokens. */

.ct-top {
  --f: min(18.6vw, calc((100svh - 330px) / .8));
  display: flex; flex-direction: column; min-height: 100svh;
  padding: calc(var(--nav) + 10px) var(--m) 28px;
}
.ct-top .kicker { margin-bottom: var(--s2); }
.ct-top .hl { flex-direction: row; align-items: flex-start; gap: .2em; white-space: nowrap; }
.ct-top .ln { --wdth: var(--rest, 62); }
.ct-top .ln:last-child .w { --i: 2; }

.ct-direct { position: relative; margin-top: auto; padding-top: var(--s5); }
.ct-copy { position: absolute; right: 0; top: calc(var(--s5) - .3em); }
.ct-mail { line-height: .86; }
.mail {
  display: block; width: max-content; max-width: 100%; padding: .04em 0 .1em;
  font-size: calc((100vw - 2 * var(--m)) * .955 / 8.44);
  font-weight: 900; --wdth: 62; font-variation-settings: "wght" 900, "wdth" var(--wdth);
  line-height: .86; white-space: nowrap;
  transition: color .25s;
}
.mail:hover, .mail:focus-visible { color: var(--y); }
.mail wbr { display: none; }

.ct-foot { display: flex; flex-wrap: wrap; align-items: end; justify-content: space-between; gap: var(--s3) var(--s4); margin-top: var(--s5); }
.ct-lede { max-width: 21em; font-size: clamp(20px, 2.15vw, 34px); line-height: 1.16; font-weight: 650; font-stretch: 88%; text-wrap: balance; }
.ct-foot .go { align-items: center; gap: var(--s2) var(--s4); }
.ct-cv { font-size: clamp(20px, 2.15vw, 34px); font-weight: 650; font-stretch: 88%; }

/* ---------- form ---------- */
.ct-form { --s6: clamp(72px, 10vh, 120px); }
.ct-form__grid { display: grid; grid-template-columns: minmax(0, 5fr) minmax(0, 6fr); gap: var(--s5) calc(var(--m) * 3); align-items: start; }
.ct-form__intro { position: sticky; top: calc(var(--nav) + var(--s3)); }
.ct-form__intro .display i { font-style: normal; color: var(--y); }
.ct-facts { display: grid; gap: var(--s3); margin: var(--s5) 0 0; }
.ct-facts dt { font-size: 14px; line-height: 1.4; color: var(--dim); }
.ct-facts dd { margin: 0; font-size: clamp(20px, 2.15vw, 34px); line-height: 1.16; font-weight: 650; font-stretch: 88%; }
.ct-form__title { margin-bottom: var(--s4); color: var(--dim); font-size: 14px; line-height: 1.4; font-weight: 400; font-stretch: 100%; }

.ct-form .field { gap: 4px; margin-bottom: var(--s4); }
.ct-form .field label {
  font-size: clamp(20px, 2.15vw, 34px); line-height: 1.16; font-weight: 650; font-stretch: 88%; color: var(--ink);
}
.ct-form .field input, .ct-form .field textarea {
  padding: 10px 0 12px; font-size: clamp(18px, 1.6vw, 24px); line-height: 1.35;
  background: transparent; border-bottom: 2px solid var(--dim); box-shadow: inset 0 0 0 0 var(--y);
  transition: border-color .25s, box-shadow .35s var(--ease);
}
.ct-form .field textarea { min-height: 7.5em; }
.ct-form .field input::placeholder, .ct-form .field textarea::placeholder { color: var(--dim); opacity: 1; }
.ct-form .field input:focus, .ct-form .field textarea:focus { outline: 0; border-bottom-color: var(--y); box-shadow: 0 2px 0 0 var(--y); }
.ct-form .field:focus-within label { color: var(--y); }
.ct-form .field input:-webkit-autofill { -webkit-text-fill-color: var(--ink); box-shadow: 0 0 0 100px #000 inset; caret-color: var(--ink); }
.ct-form .field.is-bad input, .ct-form .field.is-bad textarea { border-bottom-color: var(--y); }
.ct-form .field__error { margin-top: 2px; }
.ct-form .field__error::before { content: ""; display: inline-block; width: .55em; height: .55em; margin-right: .6em; background: var(--y); vertical-align: baseline; }

.ct-form .btn--block { display: flex; justify-content: space-between; align-items: center; width: 100%; padding: 1.05em 1.25em; font-size: 17px; cursor: pointer; border: 0; font-family: inherit; }
.ct-form .btn--block:disabled { cursor: progress; background: var(--dim); }
.ct-form .btn--block:focus-visible { outline-offset: 5px; }

.form__result { display: none; margin-top: var(--s3); font-size: clamp(20px, 2.15vw, 34px); line-height: 1.16; font-weight: 650; font-stretch: 88%; text-wrap: balance; }
.form__result--ok { color: var(--ink); }
.form__result--error { color: var(--y); }

/* the honeypot stays out of sight and out of the tab order */
.botcheck-honeypot { position: absolute !important; left: -9999px !important; top: -9999px !important; width: 1px !important; height: 1px !important; opacity: 0 !important; pointer-events: none !important; }

/* ---------- Explore More ---------- */
.ct-more { padding-bottom: var(--s6); }
.ct-more .opener { margin-bottom: var(--s4); }
.ct-links { display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); gap: var(--s4) calc(var(--m) * 2); }
.ct-links__a { display: grid; grid-template-rows: auto 1fr auto; gap: var(--s2); height: 100%; transition: color .25s; }
.ct-links__a h3 {
  font-size: clamp(36px, 4.4vw, 72px); line-height: .88; font-weight: 900; font-stretch: 100%;
  font-variation-settings: "wght" 900, "wdth" 62; text-transform: uppercase;
}
.ct-links__a p { max-width: 17em; color: var(--dim); font-size: 15px; line-height: 1.4; transition: color .25s; }
.ct-links__arrow { font-size: clamp(28px, 3vw, 44px); line-height: 1; font-weight: 900; transition: transform .4s var(--ease), color .25s; }
.ct-links__a:hover h3, .ct-links__a:focus-visible h3, .ct-links__a:hover .ct-links__arrow, .ct-links__a:focus-visible .ct-links__arrow { color: var(--y); }
.ct-links__a:hover p { color: var(--ink); }
.ct-links__a:hover .ct-links__arrow { transform: translateX(.3em); }

/* ---------- tablet and phone ---------- */
@media (max-width: 1099.98px) {
  .ct-links { grid-template-columns: repeat(2, minmax(0, 1fr)); }
}
@media (max-width: 820px) {
  .ct-top { --f: 30vw; }
  .ct-top .hl { flex-direction: column; align-items: stretch; gap: .05em; white-space: normal; }
  .ct-direct { padding-top: var(--s4); }
  .mail { font-size: 14.2vw; }
  .mail wbr { display: inline; }
  .mail { white-space: normal; width: auto; overflow-wrap: anywhere; }
  .ct-copy { top: calc(var(--s4) - .3em); }
  .ct-foot { flex-direction: column; align-items: flex-start; margin-top: var(--s4); }
  .ct-form__grid { grid-template-columns: 1fr; gap: var(--s5); }
  .ct-form__intro { position: static; }
  .ct-facts { margin-top: var(--s4); }
  .ct-links { grid-template-columns: 1fr; }
  .ct-links__a { grid-template-columns: minmax(0, 1fr) auto; grid-template-rows: auto auto; align-items: end; }
  .ct-links__a p { grid-column: 1; }
  .ct-links__arrow { grid-column: 2; grid-row: 1 / 3; }
}

/* the headline enters by itself and the address rises after it, from CSS, so a short page is never caught half way */
@media (prefers-reduced-motion: no-preference) {
  .mail { animation: rise-in 1s var(--ease) .35s backwards; }
  .ct-direct .kicker, .ct-copy, .ct-foot { animation: fade .9s ease .6s backwards; }
}
@keyframes rise-in { from { opacity: 0; transform: translateY(30%); } }
