/* FindMyofunctional
   Palette: breath mint, deep plum ink, tongue rose.
   Motif: the palate arch, used for the logo, the hero window and panel tops. */

@font-face {
  font-family: "Bricolage Grotesque";
  src: url("fonts/bricolage-grotesque-wdth.woff2") format("woff2-variations");
  font-weight: 200 800; font-stretch: 75% 100%; font-display: swap;
}
@font-face {
  font-family: "Atkinson Hyperlegible";
  src: url("fonts/atkinson-hyperlegible-latin-400-normal.woff2") format("woff2");
  font-weight: 400; font-display: swap;
}
@font-face {
  font-family: "Atkinson Hyperlegible";
  src: url("fonts/atkinson-hyperlegible-latin-700-normal.woff2") format("woff2");
  font-weight: 700; font-display: swap;
}

:root {
  --mint: #e5f1eb;       /* page */
  --mint-2: #cfe5da;     /* tinted panels, stage */
  --sea: #2f7a68;        /* secondary accent, focus */
  --plum: #2b1d3f;       /* ink, primary buttons */
  --plum-2: #5e5171;     /* secondary text */
  --rose: #e86a82;       /* tongue, logo dot */
  --white: #fbfdfc;
  --line: rgba(43, 29, 63, .14);

  --display: "Bricolage Grotesque", "Avenir Next", "Segoe UI", sans-serif;
  --text: "Atkinson Hyperlegible", "Segoe UI", system-ui, sans-serif;

  --arch: 999px 999px 28px 28px;
  --gutter: clamp(20px, 4vw, 56px);
}

* { box-sizing: border-box; }
html { background: var(--mint); color: var(--plum); }
body {
  margin: 0;
  min-width: 320px;
  font-family: var(--text);
  font-size: 18px;
  line-height: 1.55;
  -webkit-font-smoothing: antialiased;
}
a { color: inherit; text-underline-offset: .2em; text-decoration-thickness: 1px; }
a:hover { color: var(--sea); }
:focus-visible { outline: 3px solid var(--sea); outline-offset: 3px; border-radius: 6px; }

.skip-link {
  position: fixed; z-index: 80; top: 12px; left: 12px;
  padding: 10px 14px; border-radius: 10px;
  background: var(--plum); color: var(--mint);
  font-size: 14px; font-weight: 700;
  transform: translateY(-160%);
}
.skip-link:focus { transform: none; }

/* ---- header ------------------------------------------------------------ */
.site-header {
  position: sticky; top: 0; z-index: 40;
  display: flex; align-items: center; gap: 32px;
  padding: 16px var(--gutter);
  background: color-mix(in srgb, var(--mint) 92%, transparent);
  backdrop-filter: blur(10px);
}
.brand {
  display: inline-flex; align-items: center; gap: 10px;
  font-family: var(--display); font-size: 20px; font-weight: 700;
  letter-spacing: -0.02em; text-decoration: none;
}
.brand:hover { color: var(--plum); }
.mark { display: block; flex: none; }
.nav { display: flex; gap: 24px; margin-right: auto; font-size: 16px; }
.nav a { text-decoration: none; color: var(--plum-2); }
.nav a:hover { color: var(--plum); }
.nav a[aria-current="page"] { color: var(--plum); text-decoration: underline; text-decoration-color: var(--rose); text-decoration-thickness: 2px; text-underline-offset: 6px; }

.primary-cta {
  display: inline-flex; align-items: center; justify-content: center;
  min-height: 46px; padding: 0 20px;
  border: 0; border-radius: 14px;
  background: var(--plum); color: var(--mint);
  font: 700 16px/1 var(--text);
  white-space: nowrap;
  text-decoration: none;
  transition: background .15s ease;
}
.primary-cta:hover { background: #3d2b57; color: var(--mint); }
.primary-cta[aria-current="page"] { background: var(--sea); }

main { display: block; }

/* ---- type -------------------------------------------------------------- */
h1, h2, h3 {
  margin: 0;
  font-family: var(--display);
  font-weight: 700;
  letter-spacing: -0.035em;
  line-height: 1.0;
  text-wrap: balance;
}
h1 { font-size: clamp(52px, 7.4vw, 104px); font-variation-settings: "wdth" 85; }
h2 { font-size: clamp(34px, 4.2vw, 56px); }
h3 { font-size: clamp(24px, 2.4vw, 30px); letter-spacing: -0.02em; }
.kicker { margin: 0 0 14px; font-size: 17px; color: var(--plum-2); }
.lede, .prose p, .row p, .pair p, .close p {
  max-width: 34em; margin: 20px 0 0; color: var(--plum-2);
}
.lede { font-size: 20px; }

.tags { display: flex; flex-wrap: wrap; gap: 8px; margin: 26px 0 0; padding: 0; list-style: none; }
.tags li {
  padding: 5px 12px; border-radius: 10px;
  background: var(--white); color: var(--plum);
  font-size: 15px;
}

.more { display: inline-block; margin-top: 18px; font-weight: 700; }

/* ---- home: scroll world ------------------------------------------------ */
.world-canvas {
  position: fixed; inset: 0; z-index: 0;
  width: 100%; height: 100%;
  pointer-events: none;
  opacity: 0; transition: opacity .9s ease;
}
.world-canvas.is-ready { opacity: 1; }
.world main, .world footer { position: relative; z-index: 1; }
.world .site-header { z-index: 40; }

.scene {
  min-height: 100svh;
  display: flex; flex-direction: column; justify-content: center; align-items: flex-start;
  padding: 96px var(--gutter);
}
.scene > * { max-width: min(34rem, 42vw); }
.scene-hero { min-height: calc(100svh - 78px); padding-top: 40px; }
.scene-hero h1 { max-width: 9ch; }
.hero-actions { display: flex; flex-wrap: wrap; align-items: center; gap: 20px; margin-top: 32px; }
.scene p { margin: 20px 0 0; color: var(--plum-2); }
.scene .lede { font-size: 20px; }

.steps { margin: 24px 0 0; padding: 0; list-style: none; counter-reset: step; width: 100%; }
.steps li {
  counter-increment: step;
  display: grid; grid-template-columns: 44px 1fr; align-items: baseline;
  padding: 14px 0; border-top: 1.5px solid var(--line);
}
.steps li::before {
  content: counter(step);
  font-family: var(--display); font-weight: 700; font-size: 22px; color: var(--rose);
}

/* ---- inner pages ------------------------------------------------------- */
.page-hero { padding: clamp(40px, 7vw, 96px) var(--gutter); }
.prose { max-width: 760px; }
.prose ol { margin: 24px 0 0; padding-left: 1.3em; color: var(--plum-2); }
.prose li { margin: 0 0 10px; padding-left: 4px; }
.prose li::marker { color: var(--rose); font-weight: 700; font-family: var(--display); }
.empty {
  margin-top: 28px; padding: 28px;
  border-radius: 160px 160px 24px 24px;
  background: var(--mint-2); color: var(--plum-2); text-align: center;
  padding-top: 56px;
}

.panel {
  display: grid;
  grid-template-columns: minmax(0, .85fr) minmax(280px, 1fr);
  gap: clamp(28px, 4vw, 64px);
  width: min(1080px, calc(100% - 2 * var(--gutter)));
  margin: clamp(24px, 4vw, 48px) auto 72px;
  padding: clamp(28px, 5vw, 64px);
  border-radius: 36px;
  background: var(--plum); color: var(--mint);
}
.panel h1 { font-size: clamp(46px, 5.6vw, 76px); }
.panel p { color: rgba(229, 241, 235, .8); }
.panel .kicker { color: rgba(229, 241, 235, .7); }
form { display: grid; align-content: center; gap: 14px; }
.fields { display: grid; grid-template-columns: 1fr 1fr; gap: 12px; }
label { display: grid; gap: 8px; font-size: 15px; font-weight: 700; }
input, textarea {
  width: 100%;
  border: 1.5px solid rgba(229, 241, 235, .25); border-radius: 14px;
  background: rgba(229, 241, 235, .08); color: var(--mint);
  font: 400 17px/1.4 var(--text);
}
input { height: 52px; padding: 0 14px; }
textarea { min-height: 120px; padding: 14px; resize: vertical; }
.panel .primary-cta { background: var(--mint); color: var(--plum); width: fit-content; }
button.primary-cta:disabled { opacity: .6; cursor: not-allowed; }
.fine { margin: 4px 0 0; font-size: 15px; font-weight: 400; color: rgba(229, 241, 235, .72); }

footer {
  padding: 28px var(--gutter) 48px;
  color: var(--plum-2); font-size: 15px;
}

/* ---- small screens ----------------------------------------------------- */
@media (max-width: 860px) {
  .scene { justify-content: flex-end; padding-bottom: 40px;
    background: linear-gradient(to top, var(--mint) 40%, transparent 64%); }
  .scene > * { max-width: none; }
  .scene-hero { min-height: 100svh; padding-top: 44svh; }
  .scene-hero h1 { font-size: 46px; }
  .nav { display: none; }
  .site-header { gap: 16px; justify-content: space-between; }
  .panel, .fields { grid-template-columns: 1fr; }
}
@media (max-width: 420px) {
  .brand { font-size: 18px; }
  .primary-cta { padding: 0 14px; font-size: 15px; }
}
@media (prefers-reduced-motion: reduce) {
  * { transition: none !important; }
  .world-canvas { transition: none; }
}

/* ---- forms --------------------------------------------------------------- */
.hint { display: block; font-weight: 400; font-size: 14px; opacity: .8; }
.trap { position: absolute; left: -9999px; width: 1px; height: 1px; overflow: hidden; }
.check { grid-template-columns: 22px 1fr; align-items: start; gap: 10px; font-weight: 400; font-size: 16px; }
.check input { width: 20px; height: 20px; margin: 2px 0 0; accent-color: var(--sea); }
.field-error { font-size: 14px; font-weight: 700; color: var(--rose); }
[aria-invalid="true"] { border-color: var(--rose) !important; }
.form-status { min-height: 1.4em; margin: 0; font-size: 15px; }
.form-status[data-kind="error"] { color: var(--rose); font-weight: 700; }
.panel .form-status[data-kind="error"] { color: #ffb3c0; }
.form-done { padding: 8px 0; outline: none; }
.form-done h2, .form-done h3 { font-size: clamp(30px, 3.4vw, 44px); }
.panel .fine a { color: inherit; }
.turnstile:empty { display: none; }

/* Light variant for forms on the mint page */
.light-form { margin-top: 32px; max-width: 760px; }
.light-form input:not([type="checkbox"]), .light-form textarea {
  border-color: var(--line); background: var(--white); color: var(--plum);
}
.light-form .form-done p { color: var(--plum-2); }

/* ---- therapist list ------------------------------------------------------ */
.join { padding-top: 0; }
.therapist-list { margin: 28px 0 0; padding: 0; list-style: none; }
.therapist-list li { padding: 20px 0; border-top: 1.5px solid var(--line); }
.therapist-list h3 { font-size: 24px; }
.therapist-list p { margin: 6px 0 0; }
.therapist-list .tag {
  display: inline-block; margin: 10px 12px 0 0; padding: 3px 10px; border-radius: 10px;
  background: var(--white); font-size: 14px;
}
.therapist-list a { display: inline-block; margin-top: 10px; font-weight: 700; }
footer a { color: inherit; }
.prose h2.sub { margin-top: 44px; font-size: clamp(26px, 2.6vw, 34px); }
.prose a { font-weight: 700; }
[hidden] { display: none !important; }
.fields { align-items: end; }
form button.primary-cta { width: fit-content; justify-self: start; }
