:root {
  --paper: #EEF0E7;
  --paper-raised: #F7F8F3;
  --ink: #202B24;
  --ink-soft: #56635A;
  --pine: #35503F;
  --pine-dark: #263B2E;
  --clay: #B97C42;
  --clay-soft: #E7D4BB;
  --line: #D3D7C8;
  --on-pine: #F2F1E9;
  box-sizing: border-box;
  padding-top: env(safe-area-inset-top, 0px);
  padding-bottom: env(safe-area-inset-bottom, 0px);
}
@media (prefers-color-scheme: dark) {
  :root:not([data-theme="light"]) {
    --paper: #1B211C;
    --paper-raised: #232B24;
    --ink: #EBEDE5;
    --ink-soft: #ABB3A5;
    --pine: #7FA88C;
    --pine-dark: #5C8268;
    --clay: #D9A066;
    --clay-soft: #3B3226;
    --line: #333C33;
    --on-pine: #16201A;
  }
}
:root[data-theme="dark"] {
  --paper: #1B211C;
  --paper-raised: #232B24;
  --ink: #EBEDE5;
  --ink-soft: #ABB3A5;
  --pine: #7FA88C;
  --pine-dark: #5C8268;
  --clay: #D9A066;
  --clay-soft: #3B3226;
  --line: #333C33;
  --on-pine: #16201A;
}
* { box-sizing: border-box; }
html { scroll-behavior: smooth; scroll-padding-top: calc(72px + env(safe-area-inset-top, 0px)); }
body {
  margin: 0;
  background: var(--paper);
  color: var(--ink);
  font-family: 'Inter', -apple-system, sans-serif;
  font-size: 16px;
  line-height: 1.6;
  -webkit-font-smoothing: antialiased;
}
h1, h2, h3, .display {
  font-family: 'Fraunces', Georgia, serif;
  font-weight: 500;
  letter-spacing: -0.01em;
  margin: 0;
  color: var(--ink);
}
p { margin: 0 0 1em; max-width: 62ch; color: var(--ink-soft); }
a { color: inherit; }
img, svg { max-width: 100%; display: block; }
.wrap { max-width: 1120px; margin: 0 auto; padding: 0 28px; }
section { padding: 96px 0; }
@media (max-width: 720px) { section { padding: 64px 0; } .wrap { padding: 0 20px; } }

/* ---------- Nav ---------- */
header.site {
  position: sticky; top: 0; z-index: 40;
  padding-top: env(safe-area-inset-top, 0px);
  background: color-mix(in srgb, var(--paper) 88%, transparent);
  backdrop-filter: blur(10px);
  border-bottom: 1px solid var(--line);
}
.nav { display: flex; align-items: center; justify-content: space-between; padding: 18px 0; }
.wordmark { font-family: 'Fraunces', serif; font-size: 1.25rem; font-weight: 500; }
.wordmark span { color: var(--pine); font-style: italic; }
nav.links { display: flex; gap: 28px; font-size: 0.94rem; }
nav.links a { text-decoration: none; color: var(--ink-soft); transition: color .15s; }
nav.links a:hover, nav.links a:focus-visible { color: var(--pine); }
.nav-cta {
  background: var(--pine); color: var(--on-pine); border: none;
  padding: 10px 20px; border-radius: 3px; font-size: 0.92rem; font-family: inherit;
  cursor: pointer; text-decoration: none; display: inline-block;
}
.nav-cta:hover { background: var(--pine-dark); }
.menu-btn { display: none; background: none; border: none; color: var(--ink); font-size: 1.6rem; cursor: pointer; }
@media (max-width: 780px) {
  nav.links { position: fixed; top: calc(64px + env(safe-area-inset-top,0px)); left: 0; right: 0;
    background: var(--paper-raised); flex-direction: column; padding: 20px 28px; gap: 18px;
    border-bottom: 1px solid var(--line); transform: translateY(-130%); transition: transform .25s ease; }
  nav.links.open { transform: translateY(0); }
  .nav-cta.desktop-only { display: none; }
  .menu-btn { display: block; }
}

/* ---------- Hero ---------- */
.hero { padding: 76px 0 40px; overflow: hidden; }
.hero .wrap { display: grid; grid-template-columns: 1.1fr 0.9fr; gap: 56px; align-items: center; }
@media (max-width: 900px) { .hero .wrap { grid-template-columns: 1fr; } .hero-art { order: -1; max-width: 340px; margin: 0 auto 8px; } }
.hero h1 { font-size: clamp(2.1rem, 4.4vw, 3.4rem); line-height: 1.12; }
.hero .lede { font-size: 1.1rem; margin-top: 22px; max-width: 44ch; }
.hero-actions { display: flex; gap: 16px; margin-top: 30px; flex-wrap: wrap; }
.btn-primary {
  background: var(--pine); color: var(--on-pine); border: none; padding: 14px 26px;
  border-radius: 3px; font-family: inherit; font-size: 1rem; cursor: pointer; text-decoration: none;
  display: inline-block;
}
.btn-primary:hover { background: var(--pine-dark); }
.btn-ghost {
  background: none; border: 1px solid var(--line); color: var(--ink); padding: 13px 24px;
  border-radius: 3px; font-family: inherit; font-size: 1rem; cursor: pointer; text-decoration: none;
  display: inline-block;
}
.btn-ghost:hover { border-color: var(--pine); color: var(--pine); }

/* ---------- General info ---------- */
.info .wrap { display: grid; grid-template-columns: 1fr 1fr; gap: 64px; }
@media (max-width: 860px) { .info .wrap { grid-template-columns: 1fr; gap: 36px; } }
.info h2 { font-size: 2rem; margin-bottom: 20px; }
.kicker { color: var(--clay); font-style: italic; font-family: 'Fraunces', serif; font-size: 1.05rem; margin-bottom: 6px; }
.info-list { list-style: none; padding: 0; margin: 0; border-top: 1px solid var(--line); }
.info-list li { padding: 20px 0; border-bottom: 1px solid var(--line); }
.info-list h3 { font-size: 1.08rem; font-weight: 500; margin-bottom: 6px; }
.info-list p { margin: 0; font-size: 0.96rem; }

/* ---------- Therapist ---------- */
.therapist { background: var(--paper-raised); border-top: 1px solid var(--line); border-bottom: 1px solid var(--line); }
.therapist .wrap { display: grid; grid-template-columns: 220px 1fr; gap: 48px; align-items: start; }
@media (max-width: 720px) { .therapist .wrap { grid-template-columns: 1fr; } .therapist-photo { width: 140px; margin: 0 auto; } }
.therapist-photo { width: 200px; aspect-ratio: 1; border-radius: 50%; }
.therapist h2 { font-size: 1.9rem; }
.credentials { color: var(--pine); font-size: 0.98rem; margin-top: 6px; margin-bottom: 18px; }
.placeholder-note { margin-top: 18px; padding: 12px 16px; border-left: 2px solid var(--clay); font-size: 0.86rem; color: var(--ink-soft); background: var(--clay-soft); border-radius: 0 3px 3px 0; }

/* ---------- Process ---------- */
.process ol { list-style: none; margin: 40px 0 0; padding: 0; display: grid; grid-template-columns: repeat(3,1fr); gap: 0; border-top: 1px solid var(--line); }
@media (max-width: 780px) { .process ol { grid-template-columns: 1fr; } }
.process li { padding: 28px 32px 28px 0; border-right: 1px solid var(--line); }
.process li:last-child { border-right: none; }
@media (max-width: 780px) { .process li { border-right: none; border-bottom: 1px solid var(--line); padding: 24px 0; } .process li:last-child { border-bottom: none; } }
.step-num { font-family: 'Fraunces', serif; font-style: italic; font-size: 1.6rem; color: var(--clay); display: block; margin-bottom: 10px; }
.process h3 { font-size: 1.1rem; margin-bottom: 8px; font-weight: 500; }
.process p { font-size: 0.95rem; margin: 0; }

/* ---------- Booking ---------- */
.booking { background: var(--paper-raised); border-top: 1px solid var(--line); }
.booking-head { max-width: 60ch; margin-bottom: 48px; }
.booking-head h2 { font-size: 2rem; margin-bottom: 14px; }
.booking-grid { display: grid; grid-template-columns: 1fr 1fr; gap: 40px; align-items: start; }
@media (max-width: 900px) { .booking-grid { grid-template-columns: 1fr; } }
.cal-card { background: var(--paper); border: 1px solid var(--line); border-radius: 4px; padding: 26px; }
.cal-nav { display: flex; align-items: center; justify-content: space-between; margin-bottom: 18px; }
.cal-nav button { background: none; border: 1px solid var(--line); width: 34px; height: 34px; border-radius: 3px; cursor: pointer; color: var(--ink); font-size: 1rem; }
.cal-nav button:hover:not(:disabled) { border-color: var(--pine); color: var(--pine); }
.cal-nav button:disabled { opacity: 0.35; cursor: default; }
.cal-month { font-family: 'Fraunces', serif; font-size: 1.15rem; text-transform: capitalize; }
.cal-weekdays, .cal-days { display: grid; grid-template-columns: repeat(7, 1fr); gap: 6px; }
.cal-weekdays { margin-bottom: 8px; }
.cal-weekdays span { text-align: center; font-size: 0.72rem; color: var(--ink-soft); }
.cal-days button {
  aspect-ratio: 1; border-radius: 50%; border: none; background: none; color: var(--ink-soft);
  font-family: inherit; font-size: 0.88rem; cursor: default;
}
.cal-days button.avail { color: var(--ink); cursor: pointer; background: color-mix(in srgb, var(--pine) 12%, transparent); }
.cal-days button.avail:hover { background: color-mix(in srgb, var(--pine) 24%, transparent); }
.cal-days button.selected { background: var(--pine); color: var(--on-pine); }
.cal-days button.empty { visibility: hidden; }
.cal-legend { display: flex; gap: 16px; margin-top: 18px; font-size: 0.8rem; color: var(--ink-soft); }
.cal-legend .dot { display: inline-block; width: 9px; height: 9px; border-radius: 50%; margin-right: 6px; background: color-mix(in srgb, var(--pine) 30%, transparent); vertical-align: middle; }

.slots-card { background: var(--paper); border: 1px solid var(--line); border-radius: 4px; padding: 26px; min-height: 220px; }
.slots-card h3 { font-size: 1.02rem; font-weight: 500; margin-bottom: 16px; }
.slot-list { display: flex; flex-wrap: wrap; gap: 10px; }
.slot-btn { border: 1px solid var(--line); background: var(--paper-raised); padding: 10px 16px; border-radius: 3px; font-family: inherit; font-size: 0.9rem; cursor: pointer; color: var(--ink); }
.slot-btn:hover { border-color: var(--pine); color: var(--pine); }
.empty-hint { color: var(--ink-soft); font-size: 0.92rem; }

.booking-form { margin-top: 20px; border-top: 1px solid var(--line); padding-top: 20px; display: none; }
.booking-form.open { display: block; }
.booking-form .field { margin-bottom: 14px; }
.booking-form label { display: block; font-size: 0.85rem; color: var(--ink-soft); margin-bottom: 6px; }
.booking-form input, .booking-form textarea {
  width: 100%; padding: 10px 12px; border: 1px solid var(--line); border-radius: 3px;
  background: var(--paper-raised); color: var(--ink); font-family: inherit; font-size: 0.95rem;
}
.booking-form textarea { resize: vertical; min-height: 64px; }
.selected-slot-tag { display: inline-block; background: color-mix(in srgb, var(--pine) 14%, transparent); color: var(--pine); padding: 6px 12px; border-radius: 3px; font-size: 0.88rem; margin-bottom: 16px; }
.form-actions { display: flex; gap: 12px; margin-top: 8px; }
.confirm-msg { display: none; padding: 14px 16px; background: color-mix(in srgb, var(--pine) 14%, transparent); color: var(--pine-dark); border-radius: 3px; font-size: 0.92rem; margin-top: 16px; }
.confirm-msg.show { display: block; }
.form-error { display: none; padding: 12px 14px; background: color-mix(in srgb, #B5493F 14%, transparent); color: #B5493F; border-radius: 3px; font-size: 0.88rem; margin-top: 12px; }
.form-error.show { display: block; }

/* My appointments */
.my-appts { margin-top: 56px; border-top: 1px solid var(--line); padding-top: 40px; }
.my-appts h3 { font-size: 1.2rem; margin-bottom: 6px; }
.lookup-row { display: flex; gap: 10px; margin: 18px 0 20px; max-width: 440px; flex-wrap: wrap; }
.lookup-row input { flex: 1; min-width: 180px; padding: 10px 12px; border: 1px solid var(--line); border-radius: 3px; background: var(--paper); color: var(--ink); font-family: inherit; }
.lookup-row button { padding: 10px 18px; }
.appt-item { display: flex; align-items: center; justify-content: space-between; gap: 16px; padding: 16px 0; border-bottom: 1px solid var(--line); flex-wrap: wrap; }
.appt-info strong { display: block; font-family: 'Fraunces', serif; font-size: 1.02rem; font-weight: 500; }
.appt-info span { font-size: 0.85rem; color: var(--ink-soft); }
.appt-actions { display: flex; gap: 8px; }
.appt-actions button { background: none; border: 1px solid var(--line); padding: 7px 14px; border-radius: 3px; font-family: inherit; font-size: 0.84rem; cursor: pointer; color: var(--ink); }
.appt-actions button:hover { border-color: var(--pine); color: var(--pine); }
.appt-actions button.danger:hover { border-color: #B5493F; color: #B5493F; }

/* ---------- Footer ---------- */
footer.site { background: var(--pine-dark); color: var(--on-pine); padding: 56px 0 calc(32px + env(safe-area-inset-bottom, 0px)); }
footer.site .wrap { display: grid; grid-template-columns: 1.3fr 1fr 1fr; gap: 40px; }
@media (max-width: 700px) { footer.site .wrap { grid-template-columns: 1fr; gap: 28px; } }
footer.site h4 { font-family: 'Fraunces', serif; font-weight: 500; font-size: 1.15rem; margin-bottom: 12px; color: var(--on-pine); }
footer.site p, footer.site a { color: color-mix(in srgb, var(--on-pine) 78%, transparent); font-size: 0.92rem; text-decoration: none; }
footer.site a:hover { color: var(--on-pine); }
footer.site .cols div p { margin-bottom: 6px; max-width: none; }
.foot-bottom { margin-top: 44px; padding-top: 20px; border-top: 1px solid color-mix(in srgb, var(--on-pine) 20%, transparent); font-size: 0.8rem; color: color-mix(in srgb, var(--on-pine) 55%, transparent); }

@media (prefers-reduced-motion: reduce) { html { scroll-behavior: auto; } * { transition: none !important; } }

/* ---------- Psychometric tests ---------- */
.tests-head { max-width: 60ch; margin-bottom: 40px; }
.tests-head h2 { font-size: 2rem; margin-bottom: 14px; }
.tests-disclaimer { font-size: 0.85rem; padding: 12px 16px; border-left: 2px solid var(--clay); background: var(--clay-soft); color: var(--ink-soft); border-radius: 0 3px 3px 0; margin-top: 4px; }
.test-grid { display: grid; grid-template-columns: repeat(2, 1fr); gap: 20px; margin-top: 36px; }
@media (max-width: 780px) { .test-grid { grid-template-columns: 1fr; } }
.test-card { background: var(--paper-raised); border: 1px solid var(--line); border-radius: 4px; padding: 24px; }
.test-card h3 { font-size: 1.08rem; font-weight: 500; margin-bottom: 8px; }
.test-card p.desc { font-size: 0.9rem; margin-bottom: 18px; }
.test-meta { font-size: 0.78rem; color: var(--ink-soft); margin-bottom: 16px; }
.test-start { background: none; border: 1px solid var(--line); color: var(--pine); padding: 10px 18px; border-radius: 3px; font-family: inherit; font-size: 0.9rem; cursor: pointer; }
.test-start:hover { border-color: var(--pine); background: color-mix(in srgb, var(--pine) 8%, transparent); }
.test-body { display: none; margin-top: 18px; border-top: 1px solid var(--line); padding-top: 18px; }
.test-body.open { display: block; }
.test-q { margin-bottom: 16px; }
.test-q .qtext { font-size: 0.92rem; margin-bottom: 8px; color: var(--ink); }
.test-q .opts { display: flex; flex-direction: column; gap: 6px; }
.test-q label { display: flex; align-items: center; gap: 8px; font-size: 0.86rem; color: var(--ink-soft); cursor: pointer; }
.test-submit { margin-top: 6px; }
.test-result { display: none; margin-top: 18px; padding: 16px; border-radius: 3px; background: color-mix(in srgb, var(--pine) 12%, transparent); }
.test-result.show { display: block; }
.test-result h4 { font-family: 'Fraunces', serif; font-weight: 500; font-size: 1rem; margin-bottom: 8px; color: var(--pine-dark); }
.test-result p { font-size: 0.88rem; margin-bottom: 8px; }
.test-result .note { font-size: 0.78rem; font-style: italic; }

/* ---------- Blog ---------- */
.blog-head { display: flex; align-items: flex-end; justify-content: space-between; gap: 20px; margin-bottom: 40px; flex-wrap: wrap; }
.blog-head h2 { font-size: 2rem; }
.blog-grid { display: grid; grid-template-columns: repeat(2, 1fr); gap: 28px 32px; }
@media (max-width: 780px) { .blog-grid { grid-template-columns: 1fr; } }
.post-card { border-top: 1px solid var(--line); padding-top: 18px; display: block; text-decoration: none; }
.post-date { font-size: 0.78rem; color: var(--clay); margin-bottom: 8px; }
.post-card h3 { font-family: 'Fraunces', serif; font-size: 1.25rem; font-weight: 500; margin-bottom: 10px; line-height: 1.3; }
.post-card p.excerpt { font-size: 0.92rem; margin-bottom: 12px; }
.post-read { font-size: 0.86rem; color: var(--pine); }
.post-card:hover .post-read { text-decoration: underline; }

/* ---------- Single article page ---------- */
.article-page { padding: 64px 0 96px; }
.article-page .article-date { font-size: 0.85rem; color: var(--clay); margin-bottom: 10px; }
.article-page h1 { font-size: clamp(1.8rem, 4vw, 2.6rem); line-height: 1.2; margin-bottom: 32px; max-width: 22ch; }
.article-body { max-width: 66ch; }
.article-body p { color: var(--ink); font-size: 1.02rem; margin-bottom: 1.1em; }
.article-body h4 { font-family: 'Fraunces', serif; font-size: 1.15rem; font-weight: 500; margin: 28px 0 12px; }
.article-back { display: inline-block; margin-top: 40px; }

/* ---------- Modals (privacy / terms) ---------- */
.modal-overlay { position: fixed; inset: 0; background: color-mix(in srgb, var(--ink) 45%, transparent); z-index: 100; display: none; align-items: flex-start; justify-content: center; padding: 40px 20px; overflow-y: auto; }
.modal-overlay.open { display: flex; }
.modal-card { background: var(--paper); border-radius: 6px; max-width: 640px; width: 100%; padding: 40px; position: relative; margin: auto; }
@media (max-width: 700px) { .modal-card { padding: 28px 22px; } }
.modal-close { position: absolute; top: 18px; right: 18px; background: var(--paper-raised); border: 1px solid var(--line); width: 32px; height: 32px; border-radius: 50%; cursor: pointer; color: var(--ink); font-size: 1rem; }
.modal-close:hover { border-color: var(--pine); color: var(--pine); }
.modal-card h2 { font-size: 1.55rem; margin-bottom: 20px; line-height: 1.25; padding-right: 30px; }
.modal-card .article-body p { color: var(--ink); font-size: 0.98rem; margin-bottom: 1em; max-width: none; }
.modal-card .article-body h4 { font-family: 'Fraunces', serif; font-size: 1.05rem; font-weight: 500; margin: 24px 0 10px; }
