:root {
  color-scheme: light;
  --ink: #18323a;
  --navy: #123149;
  --muted: #607077;
  --line: #d8e4e1;
  --soft: #eef6f2;
  --paper: #ffffff;
  --warm: #fff8ed;
  --teal: #0f766e;
  --teal-dark: #0b4f4a;
  --eucalyptus: #5d8f7d;
  --gold: #c58a2b;
  --red: #b42318;
  --shadow: 0 18px 50px rgba(18, 49, 73, 0.12);
  font-family: Inter, ui-sans-serif, system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif;
}

* { box-sizing: border-box; }

html { scroll-behavior: smooth; }

body {
  margin: 0;
  background: #f6faf8;
  color: var(--ink);
}

h1, h2, h3, p { margin: 0; }

h1 {
  font-size: clamp(2.1rem, 5vw, 4.6rem);
  line-height: 1;
  color: var(--navy);
}

h2 {
  font-size: clamp(1.25rem, 2vw, 1.75rem);
  color: var(--navy);
  line-height: 1.15;
}

h3 {
  font-size: 1.05rem;
  color: var(--navy);
  margin-bottom: 10px;
}

p { line-height: 1.55; }

button, select, input { font: inherit; }

button {
  border: 0;
  cursor: pointer;
  border-radius: 8px;
  font-weight: 800;
}

a { color: var(--teal-dark); }

.site-header {
  position: sticky;
  top: 0;
  z-index: 50;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 22px;
  min-height: 92px;
  padding: 14px clamp(16px, 4vw, 56px);
  background: rgba(255, 255, 255, 0.96);
  border-bottom: 1px solid var(--line);
  box-shadow: 0 8px 24px rgba(18, 49, 73, 0.06);
  backdrop-filter: blur(12px);
}

.brand {
  display: flex;
  align-items: center;
  gap: 13px;
  min-width: 250px;
}

.brand-logo {
  width: 178px;
  height: 58px;
  object-fit: contain;
  object-position: left center;
  border-radius: 6px;
  background: white;
}

.brand-text {
  display: grid;
  gap: 2px;
}

.brand-text strong {
  color: var(--navy);
  font-size: 1.02rem;
  line-height: 1.1;
}

.brand-text span {
  color: var(--muted);
  font-size: .85rem;
  font-weight: 750;
}

.primary-nav {
  display: flex;
  align-items: center;
  justify-content: flex-end;
  gap: 6px;
  flex-wrap: wrap;
}

.nav-item {
  position: relative;
}

.nav-tab,
.dropdown-menu button {
  background: transparent;
  color: var(--navy);
  min-height: 42px;
}

.nav-tab {
  padding: 0 12px;
  white-space: nowrap;
}

.nav-tab:hover,
.nav-tab.active,
.nav-item:focus-within > .nav-tab {
  background: var(--soft);
  color: var(--teal-dark);
}

.dropdown-menu {
  position: absolute;
  top: calc(100% + 8px);
  left: 0;
  display: none;
  min-width: 220px;
  padding: 8px;
  background: var(--paper);
  border: 1px solid var(--line);
  border-radius: 8px;
  box-shadow: var(--shadow);
}

.has-menu:hover .dropdown-menu,
.has-menu:focus-within .dropdown-menu {
  display: grid;
  gap: 4px;
}

.dropdown-menu button {
  width: 100%;
  padding: 9px 10px;
  text-align: left;
  font-weight: 760;
}

.dropdown-menu button:hover,
.dropdown-menu button:focus {
  background: var(--soft);
  color: var(--teal-dark);
}

.site-main {
  width: min(1220px, calc(100% - 32px));
  margin: 24px auto 42px;
}

.page-section {
  display: none;
}

.page-section.active {
  display: block;
}

.eyebrow {
  color: var(--teal-dark);
  font-size: .78rem;
  font-weight: 900;
  letter-spacing: 0;
  text-transform: uppercase;
  margin-bottom: 8px;
}

.hero {
  min-height: clamp(480px, 72vh, 700px);
  display: flex;
  align-items: center;
  padding: clamp(30px, 7vw, 76px);
  border: 1px solid var(--line);
  border-radius: 8px;
  background-color: #fbfdfb;
  background-image:
    linear-gradient(90deg, rgba(251, 253, 251, 1) 0%, rgba(251, 253, 251, .98) 42%, rgba(251, 253, 251, .72) 63%, rgba(251, 253, 251, .22) 100%),
    url("assets/care-of-mind-logo.png");
  background-repeat: no-repeat;
  background-position: center, right clamp(10px, 4vw, 48px) center;
  background-size: auto, min(760px, 58vw) auto;
  box-shadow: var(--shadow);
}

.hero-copy {
  max-width: 640px;
}

.tagline {
  margin-top: 18px;
  color: var(--teal-dark);
  font-size: clamp(1.25rem, 2.6vw, 2rem);
  font-weight: 850;
}

.hero-intro {
  max-width: 520px;
  margin-top: 14px;
  color: #34464d;
  font-size: 1.12rem;
}

.hero-actions,
.actions {
  display: flex;
  align-items: center;
  gap: 10px;
  flex-wrap: wrap;
}

.hero-actions { margin-top: 28px; }

.primary,
.secondary,
.ghost {
  min-height: 44px;
  padding: 0 16px;
  border: 1px solid transparent;
}

.primary {
  background: var(--teal-dark);
  color: white;
}

.primary:hover { background: #083f3b; }

.secondary {
  background: #e5f1ed;
  color: var(--teal-dark);
  border-color: #c7ddd6;
}

.secondary:hover { background: #d7e9e3; }

.ghost {
  background: white;
  color: var(--teal-dark);
  border-color: var(--line);
}

.ghost:hover { background: var(--soft); }

.text-link {
  display: inline-flex;
  align-items: center;
  min-height: 38px;
  margin-top: 14px;
  padding: 0;
  color: var(--teal-dark);
  background: transparent;
  text-align: left;
}

.text-link:hover { text-decoration: underline; }

.intro-grid,
.info-grid {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 16px;
  margin-top: 18px;
}

.info-grid { grid-template-columns: repeat(2, minmax(0, 1fr)); }

.intro-grid article,
.info-grid article,
.profile-copy {
  padding: 22px;
  background: var(--paper);
  border: 1px solid var(--line);
  border-radius: 8px;
  box-shadow: 0 8px 26px rgba(18, 49, 73, 0.07);
}

.intro-grid p,
.info-grid p,
.info-grid li,
.profile-copy p,
.section-head p {
  color: var(--muted);
}

.wide-card {
  grid-column: 1 / -1;
}

.prep-list,
.support-list {
  margin: 10px 0 0;
  padding-left: 20px;
}

.prep-list li,
.support-list li {
  margin: 7px 0;
  line-height: 1.45;
}

.urgent-card h3 {
  margin-top: 18px;
  margin-bottom: 4px;
}

.support-list {
  padding-left: 0;
  list-style: none;
}

.support-list li {
  display: grid;
  grid-template-columns: minmax(180px, .7fr) minmax(130px, .35fr) minmax(0, 1.6fr);
  gap: 10px;
  padding: 9px 0;
  border-top: 1px solid var(--line);
}

.support-list span {
  color: var(--teal-dark);
  font-weight: 900;
}

.support-list em {
  color: var(--muted);
  font-style: normal;
}

.section-head {
  display: grid;
  gap: 10px;
  max-width: 850px;
  margin-bottom: 18px;
  padding: 6px 0;
}

.section-head.with-action {
  max-width: none;
  grid-template-columns: minmax(0, 1fr) auto;
  align-items: start;
  gap: 18px;
}

.clinic-contact {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 10px;
  margin-top: 8px;
}

.clinic-contact div {
  display: grid;
  gap: 3px;
  padding: 10px 12px;
  background: var(--paper);
  border: 1px solid var(--line);
  border-radius: 8px;
}

.clinic-contact strong {
  color: var(--teal-dark);
  font-size: .74rem;
  text-transform: uppercase;
}

.clinic-contact a,
.clinic-contact span {
  color: var(--navy);
  font-weight: 760;
  line-height: 1.35;
  overflow-wrap: anywhere;
  word-break: break-word;
}

.profile-layout {
  display: grid;
  grid-template-columns: minmax(280px, .9fr) minmax(0, 1.1fr);
  gap: 18px;
  align-items: stretch;
}

.profile-logo {
  width: 100%;
  min-height: 320px;
  object-fit: contain;
  padding: 32px;
  background: var(--warm);
  border: 1px solid #f2dfbf;
  border-radius: 8px;
  box-shadow: var(--shadow);
}

.profile-photo-placeholder {
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: 14px;
  width: 100%;
  min-height: 320px;
  padding: 32px 24px;
  background: var(--warm);
  border: 1px dashed #d8c193;
  border-radius: 8px;
  box-shadow: var(--shadow);
}

.profile-photo-placeholder img {
  width: 65%;
  max-width: 220px;
  height: auto;
  object-fit: contain;
  opacity: 0.85;
}

.profile-photo-placeholder .placeholder-caption {
  font-size: .85rem;
  font-weight: 700;
  letter-spacing: .04em;
  text-transform: uppercase;
  color: var(--gold);
  background: #fff;
  border: 1px solid #f0d9a8;
  padding: 4px 12px;
  border-radius: 999px;
}

.profile-copy {
  display: grid;
  align-content: center;
  gap: 12px;
}

.notice {
  background: #fff7ed;
  border: 1px solid #fed7aa;
  border-left: 5px solid var(--gold);
  padding: 16px 18px;
  border-radius: 8px;
  color: #4a3415;
  line-height: 1.45;
}

.chooser {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 14px;
  margin: 18px 0;
}

.chooser-group {
  padding: 14px;
  border: 1px solid var(--line);
  border-radius: 8px;
  box-shadow: 0 4px 20px rgba(25, 42, 48, 0.06);
}

.chooser-group h2 {
  margin-bottom: 10px;
  font-size: 1rem;
}

.chooser-items {
  display: grid;
  gap: 10px;
}

.adhd-group {
  background: #eef7f4;
  border-color: #bcded5;
}

.adhd-group h2 { color: var(--teal-dark); }

.asd-group {
  background: #f7f2ea;
  border-color: #ead8ba;
}

.asd-group h2 { color: #7a4c10; }

.path {
  min-height: 96px;
  text-align: left;
  padding: 18px;
  color: var(--ink);
  background: var(--paper);
  border: 1px solid var(--line);
  box-shadow: 0 4px 20px rgba(25, 42, 48, 0.06);
}

.path span {
  display: block;
  font-size: clamp(1.08rem, 2vw, 1.35rem);
  line-height: 1.15;
}

.path small {
  color: var(--muted);
  display: block;
  margin-top: 4px;
}

.path.active {
  color: white;
  background: var(--teal-dark);
  border-color: var(--teal-dark);
}

.path.active small { color: #d3f5ef; }

.asd-group .path.active {
  background: #7a4c10;
  border-color: #7a4c10;
}

.asd-group .path.active small { color: #f8e7c8; }

.workspace {
  display: grid;
  grid-template-columns: 310px minmax(0, 1fr);
  gap: 18px;
  align-items: start;
}

.panel,
.form-card,
.report {
  background: var(--paper);
  border: 1px solid var(--line);
  border-radius: 8px;
  box-shadow: var(--shadow);
}

.panel {
  position: sticky;
  top: 112px;
  padding: 18px;
}

label {
  display: block;
  font-weight: 800;
  margin: 14px 0 7px;
}

select,
input {
  width: 100%;
  border: 1px solid var(--line);
  border-radius: 8px;
  padding: 11px 12px;
  background: white;
  color: var(--ink);
}

.meta {
  margin-top: 15px;
  color: var(--muted);
  line-height: 1.45;
  font-size: .95rem;
}

.meta a {
  color: var(--teal-dark);
  font-weight: 800;
}

.rights-note {
  margin-top: 10px;
  padding: 6px 8px;
  border-radius: 8px;
  background: #fff7ed;
  border: 1px solid #fed7aa;
  color: #5c3b12;
  font-size: .62rem;
  line-height: 1.25;
}

.source-note {
  margin-top: 6px;
  font-size: .62rem;
  line-height: 1.25;
}

.client-box {
  margin-top: 18px;
  padding-top: 4px;
  border-top: 1px solid var(--line);
}

.form-card {
  min-height: 540px;
  overflow: hidden;
}

.form-head {
  display: flex;
  justify-content: space-between;
  gap: 16px;
  padding: 22px;
  background: var(--soft);
  border-bottom: 1px solid var(--line);
}

.pill {
  align-self: start;
  background: #dff4ef;
  color: var(--teal-dark);
  border: 1px solid #bfe6dd;
  border-radius: 999px;
  padding: 8px 12px;
  font-weight: 800;
  white-space: nowrap;
}

#questionArea { padding: 10px 22px 22px; }

.question {
  display: grid;
  grid-template-columns: 1fr;
  gap: 12px;
  padding: 18px 0;
  border: 0;
  border-bottom: 1px solid var(--line);
  margin: 0;
}

.question-title {
  line-height: 1.4;
  font-weight: 750;
  padding: 0;
}

.options {
  display: grid;
  grid-template-columns: repeat(5, minmax(0, 1fr));
  gap: 8px;
}

.options.six { grid-template-columns: repeat(3, minmax(0, 1fr)); }
.options.four { grid-template-columns: repeat(4, minmax(0, 1fr)); }
.options.three { grid-template-columns: repeat(3, minmax(0, 1fr)); }

.option {
  position: relative;
  min-height: 48px;
  border: 1px solid var(--line);
  border-radius: 8px;
  display: flex;
  align-items: center;
  justify-content: center;
  text-align: center;
  padding: 8px;
  font-size: .9rem;
  color: var(--muted);
  background: white;
}

.option input {
  position: absolute;
  opacity: 0;
  pointer-events: none;
}

.option:has(input:checked) {
  background: var(--teal);
  color: white;
  border-color: var(--teal);
  box-shadow: 0 6px 16px rgba(15, 118, 110, .22);
}

.actions {
  justify-content: flex-end;
  padding: 18px 22px 22px;
}

.report {
  margin-top: 18px;
  padding: 22px;
}

.empty-report {
  min-height: 110px;
  display: grid;
  place-items: center;
  color: var(--muted);
  text-align: center;
}

.report-grid {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 12px;
  margin: 16px 0;
}

.metric {
  border: 1px solid var(--line);
  border-radius: 8px;
  padding: 14px;
  background: #fbfdfc;
}

.metric strong {
  display: block;
  font-size: 1.65rem;
}

.flag {
  display: inline-flex;
  align-items: center;
  border-radius: 999px;
  padding: 7px 10px;
  font-weight: 900;
  margin-top: 8px;
}

.flag.high { background: #fee4e2; color: var(--red); }
.flag.mid { background: #fef3c7; color: #8a4d0a; }
.flag.low { background: #dcfce7; color: #166534; }

.report p,
.report li {
  color: #334044;
  line-height: 1.55;
}

.answer-summary {
  overflow-x: auto;
  margin: 8px 0 18px;
  border: 1px solid var(--line);
  border-radius: 8px;
}

.answer-summary table {
  width: 100%;
  border-collapse: collapse;
  min-width: 760px;
  font-size: .9rem;
}

.answer-summary th,
.answer-summary td {
  padding: 10px;
  border-bottom: 1px solid var(--line);
  text-align: left;
  vertical-align: top;
}

.answer-summary th {
  background: var(--soft);
  color: var(--teal-dark);
  font-size: .78rem;
  text-transform: uppercase;
  letter-spacing: 0;
}

.answer-summary td:first-child {
  width: 54px;
  font-weight: 850;
  color: var(--teal-dark);
}

.answer-summary td:nth-child(2),
.answer-summary td:nth-child(3) {
  width: 170px;
}

.answer-summary tr:last-child td { border-bottom: 0; }

.report ul { padding-left: 20px; }

.report-disclaimer {
  margin-top: 14px;
  font-size: .7rem;
  line-height: 1.3;
  color: var(--muted);
}

.source-list {
  margin-top: 16px;
  font-size: .62rem;
  line-height: 1.25;
  color: var(--muted);
}

.report-actions {
  display: flex;
  justify-content: flex-end;
  margin-top: 14px;
}

footer {
  width: min(1220px, calc(100% - 32px));
  margin: 0 auto 26px;
  color: var(--muted);
  line-height: 1.45;
  font-size: .9rem;
  display: grid;
  gap: 6px;
}

@media (max-width: 980px) {
  .site-header {
    align-items: flex-start;
    flex-direction: column;
  }

  .primary-nav {
    width: 100%;
    justify-content: flex-start;
  }

  .dropdown-menu {
    right: auto;
    left: 0;
  }

  .hero {
    min-height: 560px;
    align-items: flex-start;
    background-image:
      linear-gradient(180deg, rgba(251, 253, 251, 1) 0%, rgba(251, 253, 251, .96) 55%, rgba(251, 253, 251, .42) 100%),
      url("assets/care-of-mind-logo.png");
    background-position: center, center bottom 22px;
    background-size: auto, min(600px, 92vw) auto;
  }

  .intro-grid,
  .info-grid,
  .clinic-contact,
  .profile-layout,
  .workspace,
  .report-grid {
    grid-template-columns: 1fr;
  }

  .support-list li {
    grid-template-columns: 1fr;
    gap: 3px;
  }

  .panel { position: static; }
}

@media (max-width: 700px) {
  .site-main {
    width: min(100% - 22px, 1220px);
    margin-top: 12px;
  }

  .brand {
    width: 100%;
    align-items: flex-start;
  }

  .brand-logo {
    width: 138px;
    height: 48px;
  }

  .primary-nav {
    display: grid;
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 8px;
  }

  .nav-tab {
    width: 100%;
    background: var(--soft);
  }

  .dropdown-menu {
    position: absolute;
    min-width: min(250px, calc(100vw - 32px));
  }

  .hero {
    padding: 24px;
    min-height: 620px;
  }

  .section-head.with-action,
  .form-head,
  .actions {
    grid-template-columns: 1fr;
    flex-direction: column;
    align-items: stretch;
  }

  .chooser,
  .options,
  .options.six,
  .options.four,
  .options.three {
    grid-template-columns: 1fr;
  }
}

/* Tap-to-call phone links */
.tel-link {
  color: inherit;
  font: inherit;
  text-decoration: underline;
  text-decoration-color: rgba(15, 118, 110, 0.45);
  text-decoration-thickness: 1.5px;
  text-underline-offset: 2px;
  white-space: nowrap;
}

.tel-link:hover,
.tel-link:focus {
  color: var(--teal-dark);
  text-decoration-color: var(--teal);
  outline: none;
}

.support-list .tel-link {
  color: var(--teal-dark);
  font-weight: 900;
}

.urgent-card strong .tel-link {
  color: var(--red);
  text-decoration-color: rgba(180, 35, 24, 0.55);
}

/* Patient resources by condition */
.resources-block {
  margin-top: 28px;
  padding: 26px;
  background: var(--paper);
  border: 1px solid var(--line);
  border-radius: 12px;
  box-shadow: 0 8px 26px rgba(18, 49, 73, 0.07);
}

.resources-head {
  display: grid;
  gap: 8px;
  max-width: 850px;
  margin-bottom: 18px;
}

.resources-head p { color: var(--muted); }

.resources-hint {
  font-size: .85rem;
  color: var(--teal-dark) !important;
  font-weight: 700;
}

.resources-list {
  display: grid;
  gap: 10px;
}

.resource-group {
  border: 1px solid var(--line);
  border-radius: 10px;
  background: #fbfdfc;
  overflow: hidden;
  transition: box-shadow .15s ease, border-color .15s ease;
}

.resource-group[open] {
  border-color: var(--teal);
  box-shadow: 0 6px 20px rgba(15, 118, 110, 0.10);
  background: var(--paper);
}

.resource-group > summary {
  list-style: none;
  cursor: pointer;
  padding: 14px 18px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 14px;
  font-weight: 800;
  color: var(--navy);
  background: var(--soft);
}

.resource-group[open] > summary {
  background: linear-gradient(180deg, var(--soft), #ffffff);
  border-bottom: 1px solid var(--line);
}

.resource-group > summary::-webkit-details-marker { display: none; }
.resource-group > summary::marker { content: ""; }

.resource-title {
  font-size: 1.05rem;
  letter-spacing: .01em;
}

.resource-caret {
  flex: 0 0 auto;
  width: 28px;
  height: 28px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  border-radius: 50%;
  background: var(--paper);
  border: 1px solid var(--line);
  color: var(--teal-dark);
  font-weight: 900;
  font-size: 1.05rem;
  transition: transform .2s ease, background .2s ease;
}

.resource-group[open] > summary .resource-caret {
  transform: rotate(45deg);
  background: var(--teal);
  color: #fff;
  border-color: var(--teal);
}

.resource-body {
  padding: 16px 22px 22px;
  display: grid;
  gap: 14px;
}

.resource-body h4 {
  margin: 8px 0 0;
  font-size: .82rem;
  text-transform: uppercase;
  letter-spacing: .07em;
  color: var(--teal-dark);
  font-weight: 800;
}

.resource-links {
  margin: 0;
  padding-left: 20px;
  display: grid;
  gap: 7px;
}

.resource-links li {
  line-height: 1.5;
  color: var(--ink);
}

.resource-links li a {
  color: var(--teal-dark);
  font-weight: 700;
  text-decoration: underline;
  text-decoration-color: rgba(15, 118, 110, 0.35);
  text-underline-offset: 2px;
  word-break: break-word;
}

.resource-links li a:hover {
  text-decoration-color: var(--teal);
}

.resource-links li em {
  font-style: normal;
  color: var(--muted);
}

.resource-links li strong {
  color: var(--navy);
}

.resources-disclaimer {
  margin-top: 18px;
  padding: 12px 14px;
  border-left: 3px solid var(--gold);
  background: var(--warm);
  border-radius: 6px;
  font-size: .9rem;
  color: var(--ink);
}

@media (max-width: 760px) {
  .resources-block { padding: 18px; }
  .resource-group > summary { padding: 12px 14px; }
  .resource-body { padding: 14px 14px 18px; }
  .resource-title { font-size: 1rem; }
}

@media print {
  body { background: white; }
  .site-header,
  .section-head,
  .notice,
  .chooser,
  .workspace,
  .report-actions,
  footer {
    display: none !important;
  }

  .site-main {
    width: 100%;
    margin: 0;
  }

  .page-section { display: none !important; }
  #screeners { display: block !important; }
  .report {
    box-shadow: none;
    border: 0;
    margin: 0;
    padding: 0;
  }

  .answer-summary { overflow: visible; }
  .answer-summary table {
    min-width: 0;
    font-size: 8.5pt;
  }
  .answer-summary th,
  .answer-summary td {
    padding: 5pt;
  }
}
