/* Conversations with Dean guest intake. Palette and type follow deanhobson.com (Crimson Pro headings, Inter body,
   forest and sage greens on cream, rust accent). */
:root {
  --forest: #1f4037;
  --sage: #3f5147;
  --ink: #202219;
  --olive: #716a56;
  --cream: #f6eddd;
  --mist: #efecec;
  --paper: #fbf8f1;
  --white: #ffffff;
  --rust: #b64926;
  --text: #252525;
  --muted: #5f6460;
  --line: rgba(32, 34, 25, 0.14);
  --focus: rgba(31, 64, 55, 0.28);
  --shadow: 0 10px 30px rgba(32, 34, 25, 0.08);
  --radius: 14px;
  --font-heading: "Crimson Pro", Georgia, "Times New Roman", serif;
  --font-body: Inter, system-ui, -apple-system, "Segoe UI", sans-serif;
  color-scheme: light;
}

*, *::before, *::after { box-sizing: border-box; }
html { scroll-behavior: smooth; -webkit-text-size-adjust: 100%; }
body {
  margin: 0;
  font-family: var(--font-body);
  font-size: 16px;
  line-height: 1.55;
  color: var(--text);
  background: var(--paper);
  background-image: radial-gradient(1200px 500px at 80% -10%, rgba(63, 81, 71, 0.12), transparent 70%);
}
a { color: var(--forest); }
h1, h2, h3 { font-family: var(--font-heading); font-weight: 600; line-height: 1.12; margin: 0; color: var(--ink); }
p { margin: 0 0 0.9em; }
code { font-family: ui-monospace, SFMono-Regular, Menlo, Consolas, monospace; font-size: 0.9em; }
.hidden { display: none !important; }
.skip { position: absolute; left: -999px; top: 8px; background: var(--forest); color: var(--white); padding: 8px 12px; border-radius: 8px; z-index: 50; }
.skip:focus { left: 16px; }

/* Header */
.site-header {
  display: flex; align-items: center; justify-content: space-between; gap: 16px;
  padding: 14px 16px; max-width: 1040px; margin: 0 auto;
}
.brand { display: inline-flex; align-items: center; gap: 12px; text-decoration: none; color: var(--ink); }
.brand-mark {
  width: 36px; height: 36px; border-radius: 50%; background: var(--forest);
  box-shadow: inset 0 0 0 5px var(--forest), inset 0 0 0 8px var(--cream), inset 0 0 0 13px var(--forest);
  position: relative;
}
.brand-mark::after { content: ""; position: absolute; inset: 13px; border-radius: 50%; background: var(--rust); }
.brand-text { display: flex; flex-direction: column; line-height: 1.1; }
.brand-text strong { font-family: var(--font-heading); font-size: 1.25rem; font-weight: 600; }
.brand-text small { font-size: 0.72rem; letter-spacing: 0.08em; text-transform: uppercase; color: var(--olive); }
.site-nav { display: flex; align-items: center; gap: 18px; font-size: 0.92rem; }
.site-nav a { text-decoration: none; color: var(--sage); font-weight: 500; }
.site-nav .nav-cta { border: 1px solid var(--forest); color: var(--forest); padding: 7px 12px; border-radius: 999px; }
.site-nav .nav-cta:hover { background: var(--forest); color: var(--white); }

main { max-width: 760px; margin: 0 auto; padding: 0 16px 56px; }

/* Hero */
.hero { padding: 40px 0 28px; }
.eyebrow { font-size: 0.76rem; letter-spacing: 0.14em; text-transform: uppercase; color: var(--rust); font-weight: 600; margin-bottom: 12px; }
.hero h1 { font-size: clamp(2.4rem, 6.5vw, 3.8rem); letter-spacing: -0.01em; }
.tagline { font-family: var(--font-heading); font-style: italic; font-size: clamp(1.3rem, 3.4vw, 1.7rem); color: var(--sage); margin: 6px 0 18px; }
.intro { font-size: 1.08rem; max-width: 60ch; color: #333; }
.hero-actions { display: flex; flex-wrap: wrap; gap: 12px; margin: 22px 0 8px; }
.hero-facts { list-style: none; margin: 22px 0 0; padding: 0; display: grid; gap: 10px; grid-template-columns: repeat(auto-fit, minmax(210px, 1fr)); }
.hero-facts li { background: var(--cream); border-radius: 12px; padding: 12px 14px; font-size: 0.92rem; color: #3b3b3b; }
.hero-facts strong { display: block; color: var(--forest); font-weight: 600; margin-bottom: 2px; }

/* Buttons */
.button {
  display: inline-flex; align-items: center; justify-content: center; gap: 8px;
  font: inherit; font-weight: 600; font-size: 0.97rem; text-decoration: none; cursor: pointer;
  padding: 12px 20px; border-radius: 999px; border: 1px solid transparent; transition: background 0.15s, color 0.15s, transform 0.05s;
}
.button:active { transform: translateY(1px); }
.button-primary { background: var(--forest); color: var(--white); }
.button-primary:hover { background: var(--sage); }
.button-primary:disabled { opacity: 0.6; cursor: progress; }
.button-secondary { background: transparent; color: var(--forest); border-color: var(--forest); }
.button-secondary:hover { background: rgba(31, 64, 55, 0.08); }
.button-ghost { background: transparent; color: var(--muted); border-color: var(--line); }
.button-ghost:hover { color: var(--rust); border-color: var(--rust); }

/* Progress */
.progress-shell { position: sticky; top: 0; z-index: 20; background: rgba(251, 248, 241, 0.92); backdrop-filter: blur(8px); padding: 10px 0 8px; margin: 0 -16px; padding-left: 16px; padding-right: 16px; border-bottom: 1px solid var(--line); }
.section-nav { display: flex; gap: 6px; overflow-x: auto; scrollbar-width: none; padding-bottom: 6px; }
.section-nav::-webkit-scrollbar { display: none; }
.section-nav a { flex: 0 0 auto; font-size: 0.78rem; font-weight: 500; text-decoration: none; color: var(--sage); background: var(--mist); border-radius: 999px; padding: 5px 11px; white-space: nowrap; }
.section-nav a.is-done { background: var(--forest); color: var(--white); }
.section-nav a.is-active { outline: 2px solid var(--forest); outline-offset: 1px; }
.progress { display: flex; align-items: center; gap: 12px; }
.progress-bar { flex: 1; height: 6px; border-radius: 999px; background: var(--mist); overflow: hidden; }
.progress-bar span { display: block; height: 100%; width: 0; background: linear-gradient(90deg, var(--sage), var(--forest)); transition: width 0.25s; }
.progress-text { font-size: 0.78rem; color: var(--muted); white-space: nowrap; }

/* Panels and sections */
.panel { background: var(--white); border: 1px solid var(--line); border-radius: var(--radius); padding: 22px 20px; box-shadow: var(--shadow); margin-top: 22px; }
.section-header { display: flex; gap: 14px; align-items: flex-start; margin-bottom: 14px; }
.section-header h2 { font-size: 1.65rem; }
.step { flex: 0 0 34px; height: 34px; border-radius: 50%; background: var(--cream); color: var(--forest); font-family: var(--font-heading); font-weight: 700; font-size: 1.05rem; display: inline-flex; align-items: center; justify-content: center; margin-top: 2px; }
.lead { color: var(--muted); font-size: 0.97rem; margin-bottom: 0.4em; }
.form-section.is-done .step { background: var(--forest); color: var(--white); }

/* Fields */
.field { margin-top: 18px; }
.field label, .field legend { display: block; font-weight: 600; font-size: 0.95rem; color: var(--ink); margin-bottom: 6px; padding: 0; }
.req { font-weight: 500; font-size: 0.72rem; letter-spacing: 0.06em; text-transform: uppercase; color: var(--rust); margin-left: 6px; }
.hint { display: block; color: var(--muted); font-size: 0.84rem; margin-top: 5px; }
input[type="text"], input[type="email"], input[type="tel"], input[type="url"], input[type="date"], textarea, select {
  width: 100%; font: inherit; color: var(--text); background: var(--paper);
  border: 1px solid var(--line); border-radius: 10px; padding: 11px 13px; outline: none;
  transition: border-color 0.15s, box-shadow 0.15s, background 0.15s;
}
textarea { min-height: 86px; resize: vertical; line-height: 1.5; }
input:focus, textarea:focus, select:focus { border-color: var(--forest); box-shadow: 0 0 0 4px var(--focus); background: var(--white); }
input:not(:placeholder-shown):valid, textarea:not(:placeholder-shown):valid { background: var(--white); }
.field.is-invalid input, .field.is-invalid textarea, .field.is-invalid .choices { border-color: var(--rust); box-shadow: 0 0 0 3px rgba(182, 73, 38, 0.18); }
.field .error { display: none; color: var(--rust); font-size: 0.84rem; margin-top: 5px; }
.field.is-invalid .error { display: block; }
.prefix-field { display: flex; flex-direction: column; gap: 6px; }
.prefix { font-family: var(--font-heading); font-style: italic; font-size: 1.15rem; color: var(--sage); }

fieldset { border: 0; margin: 0; padding: 0; min-width: 0; }
.choices { display: flex; flex-wrap: wrap; gap: 8px; border-radius: 10px; }
.choice { position: relative; }
.choice input { position: absolute; opacity: 0; width: 1px; height: 1px; }
.choice span {
  display: inline-block; padding: 9px 14px; border-radius: 999px; border: 1px solid var(--line);
  background: var(--paper); font-size: 0.92rem; cursor: pointer; user-select: none; color: var(--text);
}
.choice input:checked + span { background: var(--forest); color: var(--white); border-color: var(--forest); }
.choice input:focus-visible + span { box-shadow: 0 0 0 4px var(--focus); }

.consent-item { display: flex; gap: 12px; align-items: flex-start; padding: 12px 0; border-top: 1px solid var(--line); }
.consent-item:first-of-type { border-top: 0; }
.consent-item input { width: 20px; height: 20px; margin: 2px 0 0; accent-color: var(--forest); flex: 0 0 20px; }
.consent-item label { font-weight: 500; font-size: 0.95rem; margin: 0; }
.consent-item label .req { display: inline; }
.consent-grid { display: grid; gap: 14px; grid-template-columns: 1fr 1fr; }
@media (max-width: 560px) { .consent-grid { grid-template-columns: 1fr; } }

/* Submit and done */
.submit-panel h2 { font-size: 1.6rem; margin-bottom: 6px; }
.submit-row { display: flex; flex-wrap: wrap; gap: 12px; margin-top: 14px; }
.form-status { margin: 12px 0 0; font-size: 0.92rem; color: var(--muted); min-height: 1.4em; }
.form-status.is-error { color: var(--rust); }
.form-status.is-ok { color: var(--forest); }
.done { padding: 30px 24px; }
.done h2 { font-size: 2.1rem; margin-bottom: 8px; }
.next-steps { padding-left: 20px; margin: 10px 0 18px; }
.next-steps li { margin-bottom: 8px; }
.done-ref { font-size: 0.82rem; color: var(--muted); }

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

/* Footer */
.site-footer { max-width: 760px; margin: 0 auto; padding: 24px 16px 40px; border-top: 1px solid var(--line); font-size: 0.9rem; color: var(--muted); }
.site-footer .fine { font-size: 0.8rem; }
.noscript { max-width: 760px; margin: 20px auto; padding: 14px 16px; background: var(--cream); border-radius: 12px; }

@media (max-width: 640px) {
  .site-header { padding: 12px 16px; }
  .site-nav a:not(.nav-cta) { display: none; }
  .hero { padding-top: 26px; }
  .panel { padding: 18px 16px; }
  .section-header { gap: 10px; }
  .section-header h2 { font-size: 1.45rem; }
  .button { width: 100%; }
  .hero-actions .button, .submit-row .button { width: 100%; }
}

@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }
  .progress-bar span, .button { transition: none; }
}

@media print {
  .progress-shell, .site-nav, .hero-actions, .submit-row, .trap { display: none !important; }
  .panel { box-shadow: none; break-inside: avoid; }
}
