/* Caliber — shared design system */

:root {
  --paper-50:#FFFFFF; --paper-100:#FAF8F3; --paper-150:#F4F1EA; --paper-200:#ECE8DE;
  --ink-950:#0F1419; --ink-900:#1F2937; --ink-700:#374151; --ink-500:#6B7280; --ink-300:#9CA3AF;
  --line:rgba(15,20,25,0.08); --line-strong:rgba(15,20,25,0.16);
  --yellow:#FFD83D; --yellow-warm:#F5A623; --yellow-soft:#FFF1A8; --yellow-deep:#E8A40A;
  --cloud-pink:#F5A8D8; --cloud-violet:#B4A3F2; --cloud-cyan:#8AD7E8; --cloud-peach:#FFB89A;
  --green:#10B981; --green-soft:#D1FAE5;
  --amber:#F59E0B; --amber-soft:#FEF3C7;
  --rose:#F43F5E; --rose-soft:#FFE4E6;
  --blue:#3B82F6; --blue-soft:#DBEAFE;
  --radius-sm:8px; --radius-md:14px; --radius-lg:22px; --radius-xl:32px;
  --pad-x:clamp(20px,5vw,64px); --maxw:1320px;
  --t-fast:240ms cubic-bezier(.4,0,.2,1); --t-med:420ms cubic-bezier(.4,0,.2,1); --t-slow:720ms cubic-bezier(.4,0,.2,1);
}

*, *::before, *::after { box-sizing: border-box; margin: 0; padding: 0; }
html { scroll-behavior: smooth; }
body {
  font-family: 'Inter', -apple-system, BlinkMacSystemFont, 'Segoe UI', sans-serif;
  color: var(--ink-900);
  background: var(--paper-100);
  font-size: 16px;
  line-height: 1.55;
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
}
h1, h2, h3, h4 { font-weight: 600; letter-spacing: -0.01em; text-wrap: balance; color: var(--ink-950); }
em, .serif-italic {
  font-family: 'Instrument Serif', Georgia, serif;
  font-style: italic; font-weight: 400; letter-spacing: -0.02em;
}
a { color: inherit; text-decoration: none; }
button { font: inherit; cursor: pointer; border: none; background: none; color: inherit; }
input, select, textarea { font: inherit; }
.container { width: 100%; max-width: var(--maxw); margin: 0 auto; padding-left: var(--pad-x); padding-right: var(--pad-x); }

/* ============ Header ============ */
.nav {
  position: fixed; top: 0; left: 0; right: 0; z-index: 100;
  background: rgba(255, 255, 255, 0.88);
  backdrop-filter: blur(14px) saturate(140%);
  -webkit-backdrop-filter: blur(14px) saturate(140%);
  border-bottom: 1px solid var(--line);
}
.nav-inner {
  display: flex; align-items: center; justify-content: space-between;
  height: 64px; max-width: var(--maxw); margin: 0 auto;
  padding: 0 var(--pad-x);
}
.brand { display: flex; align-items: center; gap: 10px; font-weight: 600; font-size: 16px; letter-spacing: -0.01em; }
.brand-mark {
  width: 28px; height: 28px; border-radius: 7px;
  background: var(--ink-950); color: var(--yellow);
  display: grid; place-items: center;
  font-weight: 700; font-size: 14px;
}
.brand-sub {
  color: var(--ink-500); font-weight: 400; font-size: 12px;
  margin-left: 6px; padding-left: 10px; border-left: 1px solid var(--line);
}
.nav-links { display: flex; align-items: center; gap: 8px; }
.nav-link, .nav-btn {
  display: inline-flex; align-items: center; gap: 6px;
  font-size: 13px; color: var(--ink-700);
  padding: 8px 14px; border-radius: 999px;
  border: 1px solid transparent;
  transition: background var(--t-fast), color var(--t-fast);
}
.nav-link:hover { color: var(--ink-950); }
.nav-btn { border-color: var(--line); }
.nav-btn:hover { background: var(--paper-150); }
.nav-btn svg { width: 12px; height: 12px; stroke: currentColor; stroke-width: 2; fill: none; }
.nav-cta {
  background: #FFFFFF; color: var(--ink-950);
  padding: 8px 18px; font-size: 13px; font-weight: 500;
  border-radius: 999px; border: 1px solid var(--line-strong);
  white-space: nowrap; width: fit-content;
  transition: transform var(--t-fast), box-shadow var(--t-fast);
}
.nav-cta:hover { transform: translateY(-1px); box-shadow: 0 4px 14px rgba(0, 0, 0, 0.06); }
.nav-cta.solid { background: var(--ink-950); color: var(--yellow); border-color: var(--ink-950); }
.nav-cta.solid:hover { background: #000; }

main { padding-top: 64px; }

/* ============ Buttons ============ */
.btn {
  display: inline-flex; align-items: center; gap: 8px;
  padding: 12px 22px; font-size: 14px; font-weight: 600;
  border-radius: 999px; white-space: nowrap; width: fit-content;
  transition: transform var(--t-fast), box-shadow var(--t-fast), background var(--t-fast);
}
.btn svg { width: 14px; height: 14px; stroke: currentColor; stroke-width: 2; fill: none; }
.btn-primary { background: var(--ink-950); color: var(--yellow); }
.btn-primary:hover { transform: translateY(-1px); box-shadow: 0 8px 24px rgba(0, 0, 0, 0.18); }
.btn-yellow { background: var(--yellow); color: var(--ink-950); }
.btn-yellow:hover { transform: translateY(-1px); box-shadow: 0 8px 24px rgba(255, 216, 61, 0.35); }
.btn-ghost { color: var(--ink-700); padding: 10px 18px; border: 1px solid var(--line); border-radius: 999px; }
.btn-ghost:hover { background: var(--paper-150); }
.btn-sm { font-size: 12px; padding: 8px 14px; border-radius: 999px; border: 1px solid var(--line); background: var(--paper-50); color: var(--ink-700); transition: background var(--t-fast); }
.btn-sm:hover { background: var(--paper-150); }
.btn-sm.solid { background: var(--ink-950); color: var(--yellow); border-color: var(--ink-950); }
.btn-sm.solid:hover { background: var(--ink-900); }
.btn-link { font-size: 13px; color: var(--ink-700); padding: 8px 0; }
.btn-link:hover { color: var(--ink-950); text-decoration: underline; }
button:disabled, .btn:disabled { opacity: 0.4; cursor: not-allowed; transform: none; box-shadow: none; }

/* ============ Cards ============ */
.card {
  background: var(--paper-50);
  border: 1px solid var(--line);
  border-radius: var(--radius-lg);
  padding: clamp(22px, 3vw, 32px);
  transition: transform var(--t-med), border-color var(--t-med);
}
.card.dark { background: var(--ink-950); color: var(--paper-100); border-color: var(--ink-950); }
.card.dark h3, .card.dark h2 { color: var(--paper-100); }

/* ============ Eyebrow + section title ============ */
.eyebrow {
  display: inline-flex; align-items: center; gap: 8px;
  font-size: 12px; color: var(--ink-500); font-weight: 500;
  margin-bottom: 14px;
}
.eyebrow::before { content: ""; width: 16px; height: 1px; background: var(--ink-500); }
.section-title { font-size: clamp(30px, 4vw, 52px); line-height: 1.08; max-width: 22ch; margin-bottom: 16px; }
.section-lede { font-size: clamp(15px, 1.3vw, 18px); color: var(--ink-700); max-width: 56ch; margin-bottom: 48px; }

/* ============ Stepper ============ */
.stepper { display: flex; align-items: center; margin-bottom: 48px; max-width: 880px; margin-left: auto; margin-right: auto; }
.step-dot { display: flex; align-items: center; gap: 10px; font-size: 12px; color: var(--ink-500); font-weight: 500; }
.step-dot .circle {
  width: 24px; height: 24px; border-radius: 50%;
  border: 1.5px solid var(--ink-300); background: var(--paper-50);
  display: grid; place-items: center;
  font-size: 11px; color: var(--ink-500); font-weight: 600;
}
.step-dot.active .circle { border-color: var(--ink-950); background: var(--ink-950); color: var(--yellow); }
.step-dot.done .circle { border-color: var(--ink-950); background: var(--yellow); color: var(--ink-950); }
.step-dot.active, .step-dot.done { color: var(--ink-950); }
.step-line { flex: 1; height: 1px; background: repeating-linear-gradient(to right, var(--line-strong) 0 6px, transparent 6px 12px); margin: 0 14px; }
.step-line.done { background: var(--ink-950); }

/* ============ Forms ============ */
.field { margin-bottom: 22px; }
.field:last-of-type { margin-bottom: 0; }
.field-label { display: flex; justify-content: space-between; align-items: baseline; margin-bottom: 8px; }
.field-label label { font-size: 13px; font-weight: 600; color: var(--ink-950); }
.field-label .hint { font-size: 12px; color: var(--ink-500); font-weight: 400; }
.input, .textarea, .select {
  width: 100%; font-size: 15px; color: var(--ink-950);
  padding: 12px 16px; background: var(--paper-100);
  border: 1px solid var(--line); border-radius: var(--radius-md);
  transition: border-color var(--t-fast), background var(--t-fast);
}
.input:focus, .textarea:focus, .select:focus { outline: none; border-color: var(--ink-950); background: var(--paper-50); }
.textarea { min-height: 100px; resize: vertical; font-family: inherit; line-height: 1.55; }
.select {
  appearance: none; -webkit-appearance: none;
  background-image: url("data:image/svg+xml;utf8,<svg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 16 16' fill='none' stroke='%231F2937' stroke-width='2'><path d='M4 6l4 4 4-4'/></svg>");
  background-repeat: no-repeat; background-position: right 16px center; padding-right: 40px;
}

/* Chips */
.chips { display: flex; flex-wrap: wrap; gap: 8px; }
.chip {
  padding: 10px 16px; border: 1px solid var(--line-strong);
  border-radius: 999px; font-size: 13px; color: var(--ink-700); background: var(--paper-50);
  cursor: pointer; transition: all var(--t-fast); user-select: none;
}
.chip:hover { border-color: var(--ink-950); color: var(--ink-950); }
.chip.selected { background: var(--ink-950); color: var(--yellow); border-color: var(--ink-950); }

/* ============ Modal ============ */
.modal-backdrop {
  position: fixed; inset: 0; z-index: 200;
  background: rgba(15, 20, 25, 0.5); backdrop-filter: blur(6px);
  display: none; align-items: flex-start; justify-content: center;
  padding: clamp(24px, 5vh, 80px) 20px;
  overflow-y: auto;
}
.modal-backdrop.open { display: flex; }
.modal {
  background: var(--paper-50);
  border-radius: var(--radius-xl);
  border: 1px solid var(--line);
  max-width: 560px; width: 100%;
  padding: clamp(28px, 4vw, 40px);
  position: relative;
  animation: modalIn 320ms cubic-bezier(.4, 0, .2, 1);
  box-shadow: 0 20px 60px rgba(15, 20, 25, 0.18);
}
@keyframes modalIn { from { opacity: 0; transform: translateY(12px) scale(0.98); } to { opacity: 1; transform: translateY(0) scale(1); } }
.modal-close {
  position: absolute; top: 16px; right: 16px;
  width: 32px; height: 32px; border-radius: 50%;
  display: grid; place-items: center;
  color: var(--ink-700);
  transition: background var(--t-fast);
}
.modal-close:hover { background: var(--paper-150); }
.modal-close svg { width: 14px; height: 14px; stroke: currentColor; stroke-width: 2; fill: none; }
.modal-title { font-size: 24px; font-weight: 600; margin-bottom: 8px; }
.modal-sub { font-size: 14px; color: var(--ink-700); margin-bottom: 28px; }
.modal-actions { display: flex; justify-content: space-between; align-items: center; margin-top: 28px; padding-top: 24px; border-top: 1px solid var(--line); }

/* ============ Progress bar ============ */
.progress-track { width: 100%; height: 8px; background: var(--paper-150); border-radius: 999px; overflow: hidden; }
.progress-fill { height: 100%; background: linear-gradient(90deg, var(--yellow), var(--yellow-warm)); border-radius: 999px; transition: width 600ms cubic-bezier(.4, 0, .2, 1); }

/* ============ Page header ============ */
.page-head { margin-bottom: 40px; }
.page-title { font-size: clamp(32px, 4.6vw, 52px); line-height: 1.06; margin-bottom: 12px; max-width: 22ch; }
.page-sub { font-size: 16px; color: var(--ink-700); max-width: 56ch; }

/* ============ Notes ============ */
.note-row {
  margin-top: 24px; padding: 14px 18px;
  background: var(--paper-150); border-radius: var(--radius-md);
  border: 1px solid var(--line);
  font-size: 12px; color: var(--ink-500);
  display: flex; gap: 10px; align-items: flex-start;
}
.note-row svg { width: 14px; height: 14px; stroke: var(--ink-500); stroke-width: 2; fill: none; flex-shrink: 0; margin-top: 2px; }

/* ============ Reveal ============ */
.reveal { opacity: 0; transform: translateY(12px); transition: opacity var(--t-slow), transform var(--t-slow); }
.reveal.in { opacity: 1; transform: translateY(0); }

/* ============ Toast ============ */
.toast {
  position: fixed; bottom: 24px; left: 50%; transform: translateX(-50%) translateY(20px);
  background: var(--ink-950); color: var(--paper-100);
  padding: 12px 22px; border-radius: 999px; font-size: 13px;
  opacity: 0; pointer-events: none; transition: all 280ms cubic-bezier(.4, 0, .2, 1);
  z-index: 300;
  box-shadow: 0 12px 30px rgba(0, 0, 0, 0.18);
}
.toast.show { opacity: 1; transform: translateX(-50%) translateY(0); }

/* ============ Footer ============ */
footer { padding: 32px 0; border-top: 1px solid var(--line); background: var(--paper-100); margin-top: 64px; }
.foot-inner { display: flex; align-items: center; justify-content: space-between; flex-wrap: wrap; gap: 16px; font-size: 13px; color: var(--ink-500); }
.foot-inner .brand { font-size: 14px; color: var(--ink-700); }
.foot-inner a:hover { color: var(--ink-950); }

/* ============ Print ============ */
@media print {
  .nav, footer, .no-print { display: none !important; }
  main { padding-top: 0; }
  body { background: white; }
  .card { break-inside: avoid; box-shadow: none; }
}
