/* ===========================================
   Build My Workflow — forms (onboarding + request)
   Matches the landing: pure black on white, Inter
   =========================================== */

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

:root {
  --black: #000;
  --white: #fff;
  --paper: #fafafa;
  --line: #e6e6e6;
  --muted: #606060;
  --green: #28e070;
  --max: 720px;
  --pad: clamp(20px, 4vw, 40px);
  --r: 16px;
  --r-sm: 10px;
}

html, body { margin: 0; padding: 0; }
html { -webkit-text-size-adjust: 100%; }
body {
  font-family: 'Inter', system-ui, -apple-system, Segoe UI, Roboto, sans-serif;
  font-size: 17px;
  line-height: 1.55;
  color: var(--black);
  background: var(--paper);
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
}

a { color: inherit; }
img, svg { display: block; max-width: 100%; }
button { font: inherit; cursor: pointer; }

/* ---- Header ---- */
.fhead {
  border-bottom: 1px solid var(--line);
  background: var(--white);
}
.fhead__inner {
  max-width: var(--max);
  margin: 0 auto;
  padding: 18px var(--pad);
  display: flex;
  align-items: center;
  gap: 10px;
}
.fhead__mark { width: 26px; height: 26px; }
.fhead__wordmark { font-weight: 800; letter-spacing: -0.02em; font-size: 17px; }
.fhead__io { color: var(--muted); }

/* ---- Shell ---- */
.wrap {
  max-width: var(--max);
  margin: 0 auto;
  padding: clamp(32px, 6vw, 64px) var(--pad) 80px;
}
.eyebrow {
  font-family: 'JetBrains Mono', ui-monospace, monospace;
  font-size: 12px;
  font-weight: 500;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  color: var(--muted);
  display: inline-flex;
  align-items: center;
  gap: 8px;
  margin: 0 0 14px;
}
.eyebrow .dot { width: 8px; height: 8px; border-radius: 50%; background: var(--green); }
.title {
  font-size: clamp(28px, 5vw, 40px);
  line-height: 1.05;
  letter-spacing: -0.03em;
  font-weight: 800;
  margin: 0 0 12px;
}
.lead { color: var(--muted); font-size: 18px; margin: 0 0 36px; max-width: 56ch; }

/* ---- Form ---- */
.form { display: flex; flex-direction: column; gap: 22px; }
.field { display: flex; flex-direction: column; gap: 7px; }
.field__label { font-weight: 600; font-size: 15px; }
.field__hint { color: var(--muted); font-size: 13.5px; margin: -2px 0 2px; }
.req { color: var(--green); font-weight: 700; }

.input, .textarea, .select {
  width: 100%;
  font: inherit;
  font-size: 16px;
  color: var(--black);
  background: var(--white);
  border: 1px solid var(--line);
  border-radius: var(--r-sm);
  padding: 13px 14px;
  transition: border-color .15s ease, box-shadow .15s ease;
}
.input:focus, .textarea:focus, .select:focus {
  outline: none;
  border-color: var(--black);
  box-shadow: 0 0 0 3px rgba(0,0,0,0.06);
}
.textarea { resize: vertical; min-height: 96px; }
.select { appearance: none; background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='12' height='8' viewBox='0 0 12 8'%3E%3Cpath d='M1 1l5 5 5-5' stroke='%23000' stroke-width='1.5' fill='none'/%3E%3C/svg%3E"); background-repeat: no-repeat; background-position: right 14px center; padding-right: 38px; }

/* radios + checkboxes */
.choices { display: grid; grid-template-columns: repeat(auto-fill, minmax(150px, 1fr)); gap: 8px; }
.choice {
  display: flex; align-items: center; gap: 9px;
  border: 1px solid var(--line);
  border-radius: var(--r-sm);
  padding: 11px 13px;
  font-size: 14.5px;
  cursor: pointer;
  background: var(--white);
  transition: border-color .12s ease, background .12s ease;
}
.choice:hover { border-color: #bbb; }
.choice input { accent-color: var(--black); width: 16px; height: 16px; margin: 0; }
.choice:has(input:checked) { border-color: var(--black); background: #fff; box-shadow: inset 0 0 0 1px var(--black); }

.radios { display: flex; gap: 8px; flex-wrap: wrap; }
.radios .choice { flex: 1; min-width: 120px; }

/* consent */
.consent {
  display: flex; gap: 11px; align-items: flex-start;
  background: var(--white); border: 1px solid var(--line);
  border-radius: var(--r-sm); padding: 14px;
  font-size: 14px; color: var(--muted);
}
.consent input { accent-color: var(--black); width: 17px; height: 17px; margin-top: 1px; flex-shrink: 0; }
.consent strong { color: var(--black); }

/* button */
.submit {
  appearance: none; border: none;
  background: var(--black); color: var(--white);
  font-weight: 600; font-size: 16px;
  padding: 16px 22px;
  border-radius: 999px;
  display: inline-flex; align-items: center; justify-content: center; gap: 8px;
  transition: transform .12s ease, opacity .12s ease;
}
.submit:hover { transform: translateY(-1px); }
.submit:disabled { opacity: .5; cursor: not-allowed; transform: none; }
.foot { color: var(--muted); font-size: 13px; text-align: center; margin: 4px 0 0; }

/* error */
.err { color: #c0392b; font-size: 13.5px; }
.input.is-invalid, .textarea.is-invalid, .select.is-invalid { border-color: #c0392b; }
.form-fail {
  margin-top: 16px;
  padding: 14px 16px;
  border: 1px solid #c0392b;
  border-radius: 10px;
  background: #fdf3f2;
  color: #7f2318;
  font-size: 15px;
}
.form-fail a { font-weight: 600; text-decoration: underline; }

/* success */
.done { text-align: center; padding: 48px 0; display: none; }
.done.is-on { display: block; }
.done__check { width: 56px; height: 56px; border-radius: 50%; background: var(--black); color: var(--white); display: grid; place-items: center; margin: 0 auto 20px; font-size: 26px; }
.done__title { font-size: 26px; font-weight: 800; letter-spacing: -0.02em; margin: 0 0 10px; }
.done__sub { color: var(--muted); max-width: 46ch; margin: 0 auto; }

.form.is-hidden { display: none; }

@media (max-width: 560px) {
  .choices { grid-template-columns: 1fr 1fr; }
}
