/* ---------- Truevine page design: living circuit ---------- */
:root {
  --ink: #0c1a12;
  --text: #0c1a12;
  --muted: #4f5f56;
  --dim: #8a9a90;
  --border: #dfe7e1;
  --border-hi: #c5d2c9;
  --mist: #f3f7f4;
  --leaf: #16a34a;
  --glow: #4ade80;
  --display: 'Bricolage Grotesque', 'Space Grotesk', system-ui, sans-serif;
  --mono: 'JetBrains Mono', ui-monospace, monospace;
}

body { background: #fff; line-height: 1.5; }
.page { position: relative; overflow-x: clip; }

:is(a, button, input, textarea):focus-visible {
  outline: 2px solid var(--leaf);
  outline-offset: 3px;
}

/* ---------- Nav + buttons (quieter than the old terminal styling) ---------- */
.nav-links a {
  font-family: 'Inter', system-ui, sans-serif;
  font-size: 14px;
  text-transform: none;
  letter-spacing: 0;
}
.nav-links a::before { content: none; }

.cta-btn {
  font-family: 'Inter', system-ui, sans-serif;
  font-size: 14.5px;
  font-weight: 600;
  text-transform: none;
  letter-spacing: 0;
  padding: 13px 20px;
  border-radius: 8px;
  box-shadow: none;
}
.cta-btn:hover { box-shadow: 0 8px 22px -10px rgba(20, 83, 45, 0.55); }
.cta-btn.ghost { box-shadow: inset 0 0 0 1px var(--border-hi); }
.cta-btn.ghost:hover { box-shadow: inset 0 0 0 1px var(--violet); }

/* ---------- The vine ---------- */
.vine-layer {
  position: absolute; top: 0; left: 0;
  z-index: 3;
  pointer-events: none;
  overflow: visible;
}
.vine-ghost {
  fill: none;
  stroke: var(--border-hi);
  stroke-width: 1.5;
  stroke-dasharray: 1 8;
  stroke-linecap: round;
}
.vine-trunk {
  fill: none;
  stroke: var(--violet);
  stroke-width: 2.5;
  stroke-linecap: round;
  stroke-linejoin: round;
}
.vine-branch {
  fill: none;
  stroke: var(--violet);
  stroke-width: 1.75;
  stroke-linecap: round;
  stroke-linejoin: round;
  transition: stroke-dashoffset 0.7s cubic-bezier(.16, 1, .3, 1), stroke 0.2s, stroke-width 0.2s;
}
.vine-branch.active { stroke: var(--leaf); stroke-width: 2.75; }
.vine-node {
  fill: #fff;
  stroke: var(--violet);
  stroke-width: 1.75;
  opacity: 0;
  transition: opacity 0.3s 0.45s, fill 0.3s 0.45s;
}
.vine-node.lit { opacity: 1; fill: var(--leaf); }
.vine-node.active { fill: var(--glow); filter: drop-shadow(0 0 6px var(--glow)); transition-delay: 0s; }
.vine-leaf {
  fill: rgba(22, 163, 74, 0.14);
  stroke: var(--violet);
  stroke-width: 1.25;
  stroke-linejoin: round;
  transform: scale(0);
  transform-origin: 0 0;
  transition: transform 0.6s cubic-bezier(.34, 1.56, .64, 1);
}
.vine-leaf.lit { transform: scale(1); }
.vine-tip {
  fill: var(--glow);
  stroke: var(--violet);
  stroke-width: 1.5;
  filter: drop-shadow(0 0 8px rgba(74, 222, 128, 0.9));
  transition: opacity 0.4s;
}
.vine-instant, .vine-instant * { transition: none !important; }

.vine-rail { width: 0; align-self: stretch; justify-self: center; }

/* Items wait for their branch. Opacity only: a transform here would shift where the branch lands. */
.vine-ready [data-vine-node] { opacity: 0; transition: opacity 0.6s ease 0.2s; }
.vine-ready [data-vine-node][data-lit] { opacity: 1; }

/* ---------- Hero ---------- */
.hero {
  position: relative;
  min-height: 100vh; min-height: 100svh;
  display: flex;
  padding-top: 84px;
}
.hero-inner {
  display: grid;
  grid-template-columns: minmax(0, 1fr) minmax(0, 1.15fr);
  gap: 40px;
  align-items: center;
}
.hero-left { padding: 40px 0 64px; }
.hero h1 {
  font-family: var(--display);
  font-weight: 700;
  font-size: clamp(42px, 5.2vw, 82px);
  line-height: 0.98;
  letter-spacing: -0.035em;
  color: var(--ink);
  margin-bottom: 28px;
}
.hero h1 .line { display: block; }
.hero-sub {
  font-size: 19px;
  line-height: 1.55;
  color: var(--muted);
  max-width: 520px;
  margin-bottom: 32px;
}
.hero-cta-row { display: flex; gap: 12px; flex-wrap: wrap; margin-bottom: 44px; }
.hero-stats { display: flex; max-width: 560px; border-top: 1px solid var(--border); }
.hero-stat { flex: 1; padding: 18px 16px 0 0; }
.hero-stat + .hero-stat { padding-left: 20px; border-left: 1px solid var(--border); }
.hero-stat strong {
  display: block;
  font-family: var(--display);
  font-size: 30px;
  font-weight: 700;
  letter-spacing: -0.02em;
  line-height: 1.1;
}
.hero-stat span { font-size: 13px; color: var(--muted); }
.hero-note { margin-top: 20px; font-size: 13px; color: var(--dim); }

.hero-viz { position: relative; align-self: stretch; display: flex; align-items: center; }
.hero-seed { width: 116%; margin: 0 -8%; aspect-ratio: 16 / 9; flex-shrink: 0; }
.hero-seed img, .final-tree {
  width: 100%; height: 100%;
  object-fit: contain;
  /* The renders sit on off-white; multiply + a feathered mask melts the box into the page. */
  mix-blend-mode: multiply;
  -webkit-mask-image: radial-gradient(ellipse at center, #000 52%, transparent 76%);
  mask-image: radial-gradient(ellipse at center, #000 52%, transparent 76%);
  user-select: none;
}
.hero-rail { position: absolute; left: 50%; top: 50%; bottom: 0; }

/* ---------- Sections that hang off the vine ---------- */
.grow-section { position: relative; padding: 120px 0; }
.grow {
  display: grid;
  grid-template-columns: minmax(0, 0.8fr) minmax(0, 1.5fr);
  gap: 0 24px;
  align-items: start;
}
.grow.flip { grid-template-columns: minmax(0, 1.5fr) minmax(0, 0.8fr); }
.grow.flip .grow-head { order: 2; }
.grow-head { position: sticky; top: 110px; padding-bottom: 24px; }
.grow-head h2 {
  font-family: var(--display);
  font-weight: 700;
  font-size: clamp(30px, 3.3vw, 48px);
  line-height: 1.04;
  letter-spacing: -0.03em;
  color: var(--ink);
  margin-bottom: 18px;
}
.grow-head p { font-size: 17px; line-height: 1.6; color: var(--muted); max-width: 38ch; }

.grow-body { display: grid; grid-template-columns: 110px minmax(0, 1fr); }
.grow.flip .grow-body { grid-template-columns: minmax(0, 1fr) 110px; }
.grow.flip .grow-body .vine-rail { order: 2; }
.grow-items { display: flex; flex-direction: column; min-width: 0; }

.item { padding: 28px 0 30px; border-top: 1px solid var(--border); }
.item:last-child { border-bottom: 1px solid var(--border); }
.item-top { display: flex; align-items: center; gap: 14px; margin-bottom: 10px; }
.item-icon { width: 26px; height: 26px; color: var(--violet); flex-shrink: 0; }
.item-icon svg { width: 100%; height: 100%; display: block; }
.item h3 {
  font-family: var(--display);
  font-size: 24px;
  font-weight: 600;
  line-height: 1.2;
  letter-spacing: -0.015em;
  color: var(--ink);
}
.item > h3 { margin-bottom: 10px; }
.item p { font-size: 16px; line-height: 1.6; color: var(--muted); max-width: 60ch; }

.tags { display: flex; gap: 8px; flex-wrap: wrap; margin-top: 14px; }
.tag {
  font-family: var(--mono);
  font-size: 11.5px;
  color: var(--violet);
  padding: 4px 9px;
  border: 1px solid var(--border-hi);
  border-radius: 5px;
  background: var(--mist);
}

/* ---------- Case studies ---------- */
.case-meta {
  display: flex; justify-content: space-between; gap: 16px; flex-wrap: wrap;
  font-family: var(--mono);
  font-size: 12px;
  margin-bottom: 12px;
}
.case-meta .who { color: var(--violet); }
.case-meta .src { color: var(--dim); }
.case-quote {
  margin: 16px 0 0;
  padding-left: 16px;
  border-left: 2px solid var(--leaf);
  font-size: 15px;
  line-height: 1.55;
  font-style: italic;
  color: var(--ink);
  max-width: 60ch;
}
.case-stats { display: flex; gap: 36px; flex-wrap: wrap; margin-top: 22px; }
.case-stat b {
  display: block;
  font-family: var(--display);
  font-size: 28px;
  font-weight: 700;
  letter-spacing: -0.02em;
  color: var(--violet);
  line-height: 1.15;
}
.case-stat span { font-family: var(--mono); font-size: 11.5px; color: var(--muted); }
.case-footnote { margin-top: 24px; font-size: 12.5px; line-height: 1.6; color: var(--dim); max-width: 70ch; }

/* ---------- FAQ ---------- */
.faq-item { border-top: 1px solid var(--border); }
.faq-item:last-child { border-bottom: 1px solid var(--border); }
.faq-q {
  width: 100%;
  display: flex; align-items: center; justify-content: space-between; gap: 24px;
  padding: 22px 0;
  text-align: left;
  font-family: var(--display);
  font-size: 20px;
  font-weight: 600;
  letter-spacing: -0.01em;
  color: var(--ink);
}
.faq-q:hover { color: var(--violet); }
.faq-q .plus { position: relative; width: 16px; height: 16px; flex-shrink: 0; }
.faq-q .plus::before, .faq-q .plus::after {
  content: ''; position: absolute; left: 0; top: 7px;
  width: 16px; height: 2px;
  background: var(--violet);
  transition: transform 0.3s ease;
}
.faq-q .plus::after { transform: rotate(90deg); }
.faq-item.open .plus::after { transform: rotate(0deg); }
.faq-a { display: grid; grid-template-rows: 0fr; transition: grid-template-rows 0.35s ease; }
.faq-item.open .faq-a { grid-template-rows: 1fr; }
.faq-a-inner { overflow: hidden; }
.faq-a-inner p { padding-bottom: 22px; font-size: 16px; line-height: 1.65; color: var(--muted); max-width: 62ch; }

/* ---------- Final: the vine reaches the form ---------- */
.final { background: var(--mist); padding-bottom: 130px; }
.final .grow-head { position: static; }
.final-tree { display: block; margin-top: 12px; height: auto; aspect-ratio: 16 / 9; }

.field { padding-bottom: 22px; }
.field label { display: block; font-size: 14px; font-weight: 600; color: var(--ink); margin-bottom: 8px; }
.field input, .field textarea {
  display: block;
  width: 100%;
  font: inherit;
  font-size: 16px;
  color: var(--ink);
  padding: 14px 16px;
  background: #fff;
  border: 1px solid var(--border-hi);
  border-radius: 8px;
  resize: vertical;
  transition: border-color 0.2s, box-shadow 0.2s;
}
.field input::placeholder, .field textarea::placeholder { color: var(--dim); }
.field input:focus, .field textarea:focus {
  outline: none;
  border-color: var(--leaf);
  box-shadow: 0 0 0 4px rgba(22, 163, 74, 0.16);
}
.form-submit { display: flex; align-items: center; gap: 18px; flex-wrap: wrap; padding-top: 4px; }
.form-submit span { font-size: 13px; color: var(--muted); }

/* ---------- Footer ---------- */
.footer { padding: 56px 0 40px; border-top: 1px solid var(--border); background: #fff; }
.footer-top { display: flex; justify-content: space-between; align-items: flex-start; gap: 40px; flex-wrap: wrap; }
.footer-brand { max-width: 340px; }
.footer-brand img { height: 40px; width: auto; margin-bottom: 14px; }
.footer-brand p { font-size: 14px; line-height: 1.6; color: var(--muted); }
.footer-links { display: flex; gap: 28px; flex-wrap: wrap; font-size: 14px; color: var(--muted); }
.footer-links a:hover { color: var(--violet); }
.footer-bottom { margin-top: 36px; font-size: 13px; color: var(--dim); }

/* ---------- Narrow screens: the vine becomes a left rail ---------- */
@media (max-width: 900px) {
  .container { padding: 0 20px; }
  .hero { min-height: 0; padding-top: 88px; }
  .hero-inner { grid-template-columns: minmax(0, 1fr); gap: 0; }
  .hero-left { padding: 24px 0 8px; }
  .hero-viz { padding: 8px 0 48px; }
  .hero-seed { width: 100%; margin: 0; }

  .grow-section { padding: 72px 0; }
  .grow, .grow.flip { grid-template-columns: minmax(0, 1fr); }
  .grow.flip .grow-head { order: 0; }
  .grow-head { position: static; margin-bottom: 20px; }
  .grow-body, .grow.flip .grow-body { grid-template-columns: 34px minmax(0, 1fr); }
  .grow.flip .grow-body .vine-rail { order: 0; }
  .vine-rail { justify-self: start; margin-left: 6px; }
  .hero-rail { margin-left: 0; }
  .item h3 { font-size: 21px; }
  .faq-q { font-size: 18px; }
  .case-stats { gap: 24px; }
}

/* ---------- Booking modal ---------- */
.modal-backdrop {
  position: fixed; inset: 0;
  z-index: 200;
  display: none;
  align-items: center; justify-content: center;
  padding: 24px;
  background: rgba(12, 26, 18, 0.45);
  backdrop-filter: blur(6px);
  -webkit-backdrop-filter: blur(6px);
}
.modal-backdrop.open { display: flex; animation: modalFade 0.2s ease; }
@keyframes modalFade { from { opacity: 0; } to { opacity: 1; } }
.modal {
  width: 100%;
  max-width: 880px;
  max-height: 90vh;
  display: flex; flex-direction: column;
  overflow: hidden;
  background: #fff;
  border-radius: 16px;
  box-shadow: 0 2px 6px rgba(12, 26, 18, 0.08), 0 32px 80px -24px rgba(12, 26, 18, 0.45);
  animation: modalRise 0.3s cubic-bezier(.16, 1, .3, 1);
}
@keyframes modalRise { from { transform: translateY(20px); opacity: 0; } to { transform: none; opacity: 1; } }

.modal-chrome {
  display: flex; align-items: center; gap: 20px;
  padding: 16px 20px 16px 28px;
  border-bottom: 1px solid var(--border);
}
.modal-title { font-family: var(--display); font-size: 17px; font-weight: 600; color: var(--ink); }
.modal-steps { display: flex; align-items: center; margin-left: auto; }
.step-node {
  width: 10px; height: 10px; border-radius: 50%;
  background: #fff;
  border: 1.75px solid var(--border-hi);
  transition: background 0.3s, border-color 0.3s;
}
.step-node.on { background: var(--leaf); border-color: var(--violet); }
.step-stem { width: 28px; height: 2px; background: var(--border-hi); transition: background 0.3s; }
.step-stem.on { background: var(--violet); }
.modal-chrome .close {
  width: 36px; height: 36px;
  border-radius: 8px;
  font-size: 22px; line-height: 1;
  color: var(--muted);
  transition: background 0.15s, color 0.15s;
}
.modal-chrome .close:hover { background: var(--mist); color: var(--ink); }

.modal-body { display: grid; grid-template-columns: 290px minmax(0, 1fr); flex: 1; min-height: 0; overflow: hidden; }
.modal-side { padding: 28px; background: var(--mist); border-right: 1px solid var(--border); overflow-y: auto; }
.modal-side h3 {
  font-family: var(--display);
  font-size: 24px; font-weight: 700;
  letter-spacing: -0.02em;
  color: var(--ink);
  margin-bottom: 10px;
}
.modal-side .duration { display: flex; align-items: center; gap: 8px; font-size: 14px; font-weight: 500; color: var(--violet); margin-bottom: 16px; }
.modal-side p { font-size: 14px; line-height: 1.6; color: var(--muted); margin-bottom: 20px; }
.modal-side .agenda { list-style: none; border-left: 2px solid var(--violet); }
.modal-side .agenda li { position: relative; padding: 6px 0 6px 20px; font-size: 14px; color: var(--ink); }
.modal-side .agenda li::before {
  content: ''; position: absolute; left: -6px; top: 12px;
  width: 10px; height: 10px; border-radius: 50%;
  background: var(--leaf); border: 1.75px solid var(--violet);
  box-sizing: border-box;
}

.modal-main { padding: 28px; overflow-y: auto; display: flex; flex-direction: column; }
.modal-step { font-size: 13px; color: var(--muted); margin-bottom: 6px; }
.modal h4 {
  font-family: var(--display);
  font-size: 22px; font-weight: 700;
  letter-spacing: -0.015em;
  color: var(--ink);
  margin-bottom: 20px;
}

.cal-month-head { display: flex; justify-content: space-between; align-items: center; margin-bottom: 12px; }
.cal-month-head .month { font-size: 16px; font-weight: 600; color: var(--ink); }
.cal-nav { display: flex; gap: 6px; }
.cal-nav button {
  width: 34px; height: 34px;
  border-radius: 8px;
  border: 1px solid var(--border-hi);
  color: var(--ink);
  font-size: 16px;
  transition: border-color 0.15s, background 0.15s;
}
.cal-nav button:hover:not(:disabled) { border-color: var(--violet); background: var(--mist); }
.cal-nav button:disabled { opacity: 0.35; cursor: not-allowed; }
.cal-grid { display: grid; grid-template-columns: repeat(7, 1fr); gap: 4px; }
.cal-grid .dow { font-size: 12px; font-weight: 500; color: var(--dim); text-align: center; padding: 6px 0; }
.cal-day {
  aspect-ratio: 1;
  max-height: 46px;
  display: flex; align-items: center; justify-content: center;
  border-radius: 8px;
  font-size: 14px; font-weight: 500;
  font-variant-numeric: tabular-nums;
  color: var(--ink);
  transition: background 0.15s, color 0.15s;
}
.cal-day.available { background: var(--mist); }
.cal-day.available:hover { background: rgba(22, 163, 74, 0.2); }
.cal-day:disabled { color: var(--dim); opacity: 0.55; cursor: not-allowed; }
.cal-day.today { box-shadow: inset 0 0 0 1.5px var(--violet); }
.cal-day.selected, .cal-day.selected:hover { background: var(--violet); color: #fff; }
.cal-day.empty { visibility: hidden; }

.slots-label { margin-top: 24px; font-size: 14px; font-weight: 600; color: var(--ink); }
.slots { display: grid; grid-template-columns: repeat(4, 1fr); gap: 8px; margin-top: 12px; }
.slot {
  padding: 11px 8px;
  border: 1px solid var(--border-hi);
  border-radius: 8px;
  font-family: var(--mono);
  font-size: 13px;
  color: var(--ink);
  text-align: center;
  transition: border-color 0.15s, background 0.15s, color 0.15s;
}
.slot:hover { border-color: var(--violet); background: var(--mist); }
.slot.selected, .slot.selected:hover { background: var(--violet); border-color: var(--violet); color: #fff; }

.form-row { display: flex; flex-direction: column; gap: 8px; margin-bottom: 16px; }
.form-row label { font-size: 14px; font-weight: 600; color: var(--ink); }
.form-row input, .form-row textarea {
  font: inherit; font-size: 15px;
  color: var(--ink);
  padding: 12px 14px;
  background: #fff;
  border: 1px solid var(--border-hi);
  border-radius: 8px;
  resize: vertical;
  transition: border-color 0.2s, box-shadow 0.2s;
}
.form-row input::placeholder, .form-row textarea::placeholder { color: var(--dim); }
.form-row input:focus, .form-row textarea:focus {
  outline: none;
  border-color: var(--leaf);
  box-shadow: 0 0 0 4px rgba(22, 163, 74, 0.16);
}

.send-error {
  padding: 12px 14px;
  border-radius: 8px;
  background: #fef2f2;
  border: 1px solid #fecaca;
  color: #991b1b;
  font-size: 14px;
  line-height: 1.5;
}

.modal-footer {
  display: flex; justify-content: space-between; align-items: center; gap: 16px;
  padding: 16px 28px;
  border-top: 1px solid var(--border);
}
.modal-footer .summary { font-size: 14px; color: var(--muted); }
.modal-footer .summary strong { color: var(--ink); font-weight: 600; }
.modal-footer .actions { display: flex; gap: 10px; }
.modal-btn {
  padding: 12px 20px;
  border-radius: 8px;
  font-size: 14.5px; font-weight: 600;
  color: var(--ink);
  box-shadow: inset 0 0 0 1px var(--border-hi);
  transition: background 0.15s, box-shadow 0.15s;
}
.modal-btn:hover:not(:disabled) { box-shadow: inset 0 0 0 1px var(--violet); }
.modal-btn.primary { background: var(--violet); color: #fff; box-shadow: none; }
.modal-btn.primary:hover:not(:disabled) { background: var(--violet-hi); box-shadow: none; }
.modal-btn:disabled { opacity: 0.4; cursor: not-allowed; }

.success-screen { padding: 56px 32px; display: flex; flex-direction: column; align-items: center; text-align: center; overflow-y: auto; }
.success-icon {
  width: 72px; height: 72px; border-radius: 50%; flex-shrink: 0;
  display: flex; align-items: center; justify-content: center;
  background: var(--mist);
  border: 2px solid var(--violet);
  color: var(--violet);
  margin-bottom: 22px;
}
.success-screen h3 { font-family: var(--display); font-size: 32px; font-weight: 700; letter-spacing: -0.02em; color: var(--ink); margin-bottom: 10px; }
.success-screen p { font-size: 15px; line-height: 1.6; color: var(--muted); max-width: 420px; margin-bottom: 24px; }
.success-screen p strong { color: var(--violet); }
.success-details { width: 100%; max-width: 380px; padding: 8px 20px; background: var(--mist); border-radius: 12px; font-size: 14px; }
.success-details .row { display: flex; justify-content: space-between; gap: 16px; padding: 10px 0; color: var(--ink); }
.success-details .row + .row { border-top: 1px solid var(--border); }
.success-details .row span:first-child { color: var(--muted); }

@media (max-width: 760px) {
  .modal-backdrop { padding: 12px; }
  .modal { max-height: 94vh; }
  .modal-chrome { padding-left: 20px; gap: 12px; }
  .modal-body { grid-template-columns: minmax(0, 1fr); overflow-y: auto; }
  .modal-side { padding: 20px; border-right: 0; border-bottom: 1px solid var(--border); overflow: visible; }
  .modal-side p, .modal-side .agenda { display: none; }
  .modal-side .duration { margin-bottom: 0; }
  .modal-main { padding: 20px; overflow: visible; }
  .slots { grid-template-columns: repeat(3, 1fr); }
  .modal-footer { padding: 14px 20px; flex-wrap: wrap; }
}

@media (prefers-reduced-motion: reduce) {
  .modal, .modal-backdrop.open { animation: none; }
  .vine-layer *, .vine-ready [data-vine-node], .faq-a, .faq-q .plus::after { transition: none !important; }
}
