@font-face { font-family: Bricolage; src: url(/fonts/bricolage.woff2) format('woff2'); font-weight: 200 800; font-display: swap; }
@font-face { font-family: SourceSerif; src: url(/fonts/serif.woff2) format('woff2'); font-weight: 200 900; font-display: swap; }
@font-face { font-family: SourceSerif; src: url(/fonts/serif-italic.woff2) format('woff2'); font-weight: 200 900; font-style: italic; font-display: swap; }

:root {
  --ground: #e8eeeb;
  --sheet: #fff;
  --ink: #10282a;
  --muted: #4b6163;
  --petrol: #145c55;
  --marker: #f6d65b;
  --line: #bccac6;
  --sans: Bricolage, system-ui, sans-serif;
  --serif: SourceSerif, Georgia, serif;
  color-scheme: light;
}

* { box-sizing: border-box; }
[hidden] { display: none !important; }
body {
  margin: 0;
  min-height: 100vh;
  min-height: 100dvh;
  display: flex;
  flex-direction: column;
  background: var(--ground);
  color: var(--ink);
  font: 1.0625rem/1.5 var(--sans);
}
.top, .desk, footer { width: min(100% - 2.5rem, 72rem); margin-inline: auto; }
.top { display: flex; flex-wrap: wrap; justify-content: space-between; align-items: baseline; gap: .25rem 2rem; padding-block: 1.5rem; }
.top p { margin: 0; }
.name { font-weight: 700; font-size: 1.2rem; }
.trade { font-family: var(--serif); font-style: italic; color: var(--muted); }

.desk { flex: 1; display: grid; grid-template-columns: minmax(0, 7fr) minmax(0, 5fr); gap: clamp(2rem, 6vw, 6rem); align-items: start; padding-block: clamp(1.5rem, 6vh, 4.5rem) 3rem; }

h1, h2 { margin: 0; text-wrap: balance; letter-spacing: -.025em; }
h1 { font-size: clamp(2.6rem, 6vw, 4.75rem); line-height: .98; font-weight: 750; font-stretch: 90%; }
h2 { font-size: clamp(1.75rem, 3.4vw, 2.6rem); line-height: 1.08; font-weight: 650; }
h2:focus { outline: none; }
.lead { font: 1.25rem/1.55 var(--serif); max-width: 34em; margin: 1.75rem 0 2rem; }
.why { font: italic 1.125rem/1.55 var(--serif); color: var(--muted); max-width: 34em; margin: .9rem 0 1.75rem; }
.small { font-size: .9rem; color: var(--muted); max-width: 34em; }

button { font: inherit; color: inherit; cursor: pointer; }
button:focus-visible, input:focus-visible, textarea:focus-visible { outline: 3px solid var(--petrol); outline-offset: 3px; }
.primary { background: var(--petrol); color: #fff; border: 0; border-radius: 999px; padding: .95rem 1.9rem; font-weight: 600; }
.primary:hover { background: var(--ink); }
.primary:disabled { opacity: .65; cursor: progress; }
.link { background: none; border: 0; padding: .25rem 0; text-decoration: underline; text-underline-offset: .2em; }

.progress { display: flex; align-items: center; gap: 1rem; margin-bottom: 2.25rem; font-size: .9rem; color: var(--muted); }
progress { flex: 1; height: 4px; appearance: none; border: 0; background: var(--line); }
progress::-webkit-progress-bar { background: var(--line); }
progress::-webkit-progress-value { background: var(--petrol); }
progress::-moz-progress-bar { background: var(--petrol); }

.options { display: grid; gap: .6rem; max-width: 34rem; }
.options button { text-align: left; background: var(--sheet); border: 1.5px solid var(--line); border-radius: 10px; padding: .95rem 1.2rem; font-weight: 500; }
.options button:hover { border-color: var(--petrol); }
.options button[aria-pressed='true'] { background: var(--marker); border-color: var(--ink); }

#contact { display: grid; gap: 1.1rem; max-width: 34rem; justify-items: start; }
#contact label { display: grid; gap: .35rem; width: 100%; font-weight: 600; }
#contact .field span { font-weight: 400; color: var(--muted); }
#sheet-hint { margin: -.5rem 0 0; }
input:not([type='checkbox']), textarea { width: 100%; font: 1.0625rem var(--serif); color: var(--ink); background: var(--sheet); border: 1.5px solid #7d9490; border-radius: 6px; padding: .75rem .85rem; }
textarea { resize: vertical; }
#contact .check { font-weight: 400; grid-template-columns: auto 1fr; gap: .75rem; align-items: start; }
#contact .check span { font-size: .95rem; }
.check input { width: 1.15rem; height: 1.15rem; margin: .15rem 0 0; accent-color: var(--petrol); }
#contact .trap { position: absolute; left: -9999px; width: 1px; }
.error { margin: 0; color: #9b1c1c; font-weight: 600; }

/* The intake sheet fills in as questions are answered. */
.sheet { position: relative; background: var(--sheet); padding: 2rem 1.75rem 2.25rem 2rem; border-radius: 3px; box-shadow: 0 1px 2px #10282a1f, 0 24px 48px -28px #10282a66; }
.sheet::before { content: ''; position: absolute; top: -11px; left: 50%; width: 7rem; height: 24px; translate: -50% 0; rotate: -2deg; background: #f6d65bb3; }
.sheet h2 { font-size: 1.15rem; letter-spacing: -.01em; margin-bottom: 1rem; }
#notes { list-style: none; margin: 0; padding: 0; font: 1.0625rem/1.6 var(--serif); }
#notes li { min-height: 2.9rem; padding-block: .55rem; border-bottom: 1px solid #dbe4e1; }
#notes li.current { border-bottom: 2px solid var(--petrol); }
mark { color: inherit; background: linear-gradient(transparent 52%, var(--marker) 52% 92%, transparent 92%); box-decoration-break: clone; -webkit-box-decoration-break: clone; }
#notes li.new mark { animation: written .6s ease-out; }
@keyframes written { from { opacity: .4; } }

footer { padding-block: 1rem 1.5rem; font-size: .9rem; color: var(--muted); }
dialog { width: min(100% - 2rem, 34rem); border: 0; border-radius: 8px; padding: 2rem; color: var(--ink); font-family: var(--serif); }
dialog h2 { font-family: var(--sans); font-size: 1.5rem; }
dialog::backdrop { background: #10282aa6; }

@media (max-width: 52rem) {
  .desk { grid-template-columns: minmax(0, 1fr); padding-top: 1rem; }
  /* On small screens the sheet would distract, so it returns for review at the last step. */
  body:not([data-stage='end']) .sheet { display: none; }
  .trade { font-size: .95rem; }
}
@media (prefers-reduced-motion: reduce) { * { animation: none !important; } }
