:root {
  --lilac: #D9D2F2;
  --ink: #1B1640;
  --paper: #FBFAF7;
  --cobalt: #2337C6;
  --marigold: #F2B019;
  --pine: #0F6B55;
  --blush: #F4A6B8;
  --error: #A3123A;
  --font: "Bricolage Grotesque", "Avenir Next", "Segoe UI", system-ui, sans-serif;
}

*, *::before, *::after { box-sizing: border-box; }

html { -webkit-text-size-adjust: 100%; }

body {
  margin: 0;
  background: var(--lilac);
  color: var(--ink);
  font-family: var(--font);
  font-size: 1.125rem;
  line-height: 1.55;
  font-variation-settings: "opsz" 14;
}

.page {
  max-width: 1180px;
  margin: 0 auto;
  padding: clamp(1.25rem, 4vw, 3.5rem);
  display: grid;
  grid-template-columns: minmax(0, 1.05fr) minmax(0, 0.95fr);
  gap: clamp(2rem, 6vw, 5rem);
  align-items: start;
}

/* Cover */
.cover-col {
  position: sticky;
  top: clamp(1.25rem, 4vw, 3.5rem);
}
.cover {
  margin: 0;
  box-shadow: 14px 14px 0 var(--ink);
  border: 3px solid var(--ink);
  background: var(--paper);
  line-height: 0;
}
.cover svg { width: 100%; height: auto; display: block; }
#shapes { transition: opacity 220ms ease; }
#shapes.is-swapping { opacity: 0; }

.cover-title {
  font-family: var(--font);
  font-size: 118px;
  font-weight: 800;
  font-stretch: 75%;
  font-variation-settings: "opsz" 96, "wdth" 75;
  letter-spacing: -2px;
}
.cover-blurb {
  font-family: var(--font);
  font-size: 19px;
  font-weight: 500;
  font-variation-settings: "opsz" 14;
}

.shuffle {
  margin-top: 1.75rem;
  font: inherit;
  font-weight: 650;
  font-size: 1rem;
  padding: 0.7rem 1.2rem;
  color: var(--ink);
  background: var(--paper);
  border: 2px solid var(--ink);
  border-radius: 999px;
  cursor: pointer;
}
.shuffle:hover { background: var(--marigold); }
.shuffle:active { transform: translate(1px, 1px); }

/* Text */
.text-col { max-width: 34rem; padding-top: 0.5rem; }
.lead {
  font-size: clamp(1.75rem, 3.2vw, 2.5rem);
  line-height: 1.12;
  font-weight: 700;
  font-variation-settings: "opsz" 60;
  letter-spacing: -0.01em;
  margin: 0 0 1.25rem;
}
.text-col > p { margin: 0 0 1rem; }

h2 {
  font-size: 1.5rem;
  font-weight: 750;
  font-variation-settings: "opsz" 40;
  margin: 3rem 0 1rem;
}

/* Form */
.contact { display: grid; gap: 1.1rem; }
.field { display: grid; gap: 0.35rem; }
label { font-weight: 600; font-size: 1rem; }
input, textarea {
  font: inherit;
  font-size: 1rem;
  color: var(--ink);
  background: var(--paper);
  border: 2px solid var(--ink);
  border-radius: 10px;
  padding: 0.7rem 0.85rem;
  width: 100%;
}
textarea { resize: vertical; min-height: 9rem; }
input[aria-invalid="true"], textarea[aria-invalid="true"] { border-color: var(--error); box-shadow: inset 0 0 0 1px var(--error); }

.trap { position: absolute; left: -9999px; width: 1px; height: 1px; overflow: hidden; }

.send {
  justify-self: start;
  font: inherit;
  font-weight: 700;
  font-size: 1.05rem;
  padding: 0.8rem 1.5rem;
  color: var(--paper);
  background: var(--cobalt);
  border: 2px solid var(--ink);
  border-radius: 999px;
  cursor: pointer;
}
.send:hover { background: var(--ink); }
.send[disabled] { opacity: 0.6; cursor: progress; }

.status { margin: 0; min-height: 1.5em; font-weight: 600; }
.status.is-error { color: var(--error); }
.status.is-ok { color: var(--pine); }

:focus-visible { outline: 3px solid var(--cobalt); outline-offset: 3px; }

.foot {
  max-width: 1180px;
  margin: 0 auto;
  padding: 0 clamp(1.25rem, 4vw, 3.5rem) 2.5rem;
  font-size: 0.9rem;
}

.visually-hidden {
  position: absolute !important;
  width: 1px; height: 1px;
  overflow: hidden; clip: rect(0 0 0 0); white-space: nowrap;
}

/* 404 */
.lost { max-width: 34rem; margin: 0 auto; padding: 18vh 1.5rem; }
.lost a { color: var(--cobalt); font-weight: 650; }

@media (max-width: 820px) {
  .page { grid-template-columns: 1fr; }
  .cover-col { position: static; max-width: 460px; }
  .cover { box-shadow: 9px 9px 0 var(--ink); margin-right: 9px; }
}

@media (prefers-reduced-motion: reduce) {
  #shapes { transition: none; }
}
