:root { --practice-home-max: 880px; }

html { min-height: 100%; scroll-behavior: smooth; scrollbar-width: none; }
html::-webkit-scrollbar { display: none; }
body { min-height: 100vh; min-height: 100svh; padding-bottom: 78px; overflow-x: hidden; }
button { color: inherit; }

.home-hero { min-height: 176px; padding: calc(12px + env(safe-area-inset-top)) 20px 24px; }
.home-hero::before { bottom: -29px; height: 33px; }
.home-hero .dusk-disc {
  right: max(26px, calc((100vw - var(--practice-home-max)) / 2 + 26px));
  top: 66px;
  width: 34px;
  height: 34px;
  box-shadow: 0 0 28px rgba(242,181,126,.72);
}
.home-hero-inner { position: relative; z-index: 4; width: 100%; max-width: var(--practice-home-max); margin: 0 auto; }
.home-topline { display: flex; align-items: flex-start; justify-content: space-between; gap: 16px; }
.home-wordmark { color: var(--sky-ink); font: 600 16px/1 'Source Serif 4',serif; letter-spacing: .115em; text-transform: uppercase; white-space: nowrap; }
.home-practice-name { max-width: 270px; margin-top: 8px; color: rgba(248,238,231,.9); font-size: 11px; }
.home-actions { display: flex; align-items: center; gap: 8px; }
.home-icon-button,
.home-avatar { width: 34px; height: 34px; display: grid; place-items: center; flex: 0 0 auto; padding: 0; border: 1px solid rgba(255,255,255,.3); border-radius: 50%; color: var(--sky-ink); background: rgba(255,255,255,.08); }
.home-icon-button .material-symbols-rounded { font-size: 18px; font-variation-settings: 'FILL' 0, 'wght' 350; }
.home-avatar { overflow: hidden; padding: 2px; border-color: rgba(255,255,255,.62); background: #fff8f0; box-shadow: 0 0 0 2px rgba(231,161,120,.34); }
.home-avatar img { width: 100%; height: 100%; display: block; object-fit: contain; transform: scale(.88); }
.home-hero-copy { margin-top: 10px; padding-right: 45px; }
.home-admin-badge { display: inline-flex; align-items: center; gap: 6px; padding: 5px 10px; border: 1px solid rgba(255,255,255,.13); border-radius: 999px; color: rgba(255,241,231,.92); background: rgba(255,255,255,.11); font-size: 9px; font-weight: 600; }
.home-admin-badge .material-symbols-rounded { font-size: 12px; }
.home-admin-badge .filled { font-variation-settings: 'FILL' 1, 'wght' 400; }
.home-hero h1 { margin-top: 11px; color: var(--sky-ink); font: 600 28px/1.02 'Source Serif 4',serif; letter-spacing: -.025em; }
.home-description,
.home-trust { color: rgba(248,238,231,.9); font-size: 10px; line-height: 1.35; }
.home-description { margin-top: 7px; }
.home-trust { display: flex; align-items: center; gap: 7px; margin-top: 8px; }
.home-trust .material-symbols-rounded { font-size: 14px; }

.practice-home-main { width: 100%; max-width: var(--practice-home-max); margin: 0 auto; padding: 12px 16px 36px; }
.practice-home-status { margin: 0 2px 9px; color: var(--dusk-copy); font-size: 8px; line-height: 1.35; }
.practice-home-status.error { color: #ad4e42; }
.home-card { border: 1px solid var(--dusk-line); border-radius: 14px; background: var(--dusk-card-2); box-shadow: 0 12px 30px -28px rgba(58,45,39,.45); }
.home-card > h2 { color: var(--dusk-ink); font: 600 13px/1.1 'Source Serif 4',serif; }

.weekly-briefing { position: relative; display: grid; grid-template-columns: minmax(0,1fr) 96px; gap: 5px 16px; padding: 12px 15px 9px; overflow: hidden; }
.briefing-copy { min-width: 0; }
.briefing-copy .eyebrow { color: var(--dusk-ink); font: 600 12px/1 'Source Serif 4',serif; }
.briefing-copy h2 { margin-top: 10px; color: #655291; font: 600 24px/1 'Source Serif 4',serif; }
.briefing-copy > p:last-child { max-width: 310px; margin-top: 9px; color: var(--dusk-copy); font-size: 9px; line-height: 1.42; }
.briefing-visual { position: relative; width: 94px; height: 94px; overflow: hidden; align-self: center; border-radius: 50%; background: radial-gradient(circle at 55% 42%,rgba(245,205,160,.35),rgba(247,238,228,.88) 52%,rgba(236,226,241,.85)); }
.briefing-sun { position: absolute; z-index: 2; left: 35px; top: 26px; width: 28px; height: 28px; border-radius: 50%; background: radial-gradient(circle at 38% 35%,#fff1d7,#f2b96f 76%); box-shadow: 0 0 18px rgba(235,177,107,.35); }
.hill { position: absolute; left: -10px; bottom: -25px; width: 120px; height: 66px; display: block; border-radius: 50% 50% 0 0; transform: rotate(-7deg); }
.hill.one { z-index: 2; background: rgba(150,122,176,.28); }
.hill.two { z-index: 3; left: 18px; bottom: -34px; background: rgba(121,94,159,.22); transform: rotate(8deg); }
.spark { position: absolute; z-index: 4; color: #f1bc78; font-size: 10px; font-style: normal; }
.spark.one { left: 11px; top: 35px; }
.spark.two { right: 13px; top: 23px; }
.briefing-metrics { grid-column: 1 / -1; display: grid; grid-template-columns: repeat(3,minmax(0,1fr)); gap: 10px; margin-top: 4px; }
.briefing-metric { min-width: 0; min-height: 43px; display: grid; grid-template-columns: 31px minmax(0,1fr); grid-template-rows: auto auto; align-content: center; gap: 0 7px; padding: 5px 10px; border: 1px solid var(--dusk-line); border-radius: 10px; }
.metric-icon { grid-row: 1 / 3; width: 29px; height: 29px; display: grid; place-items: center; align-self: center; border-radius: 50%; }
.metric-icon .material-symbols-rounded { font-size: 18px; }
.metric-icon .filled { font-variation-settings: 'FILL' 1, 'wght' 400; }
.briefing-metric.purple { border-color: rgba(123,104,170,.24); }
.briefing-metric.amber { border-color: rgba(231,132,45,.24); }
.briefing-metric.green { border-color: rgba(102,139,94,.24); }
.briefing-metric.purple .metric-icon { color: #6652a4; background: rgba(123,104,170,.12); }
.briefing-metric.amber .metric-icon { color: #e8640d; background: rgba(232,108,22,.11); }
.briefing-metric.green .metric-icon { color: #57875a; background: rgba(102,139,94,.12); }
.briefing-metric strong { font: 600 14px/1 'Source Serif 4',serif; }
.briefing-metric.purple strong { color: #6652a4; }
.briefing-metric.amber strong { color: #e8640d; }
.briefing-metric.green strong { color: #57875a; }
.briefing-metric small { color: var(--dusk-copy); font-size: 7px; }
.briefing-link { grid-column: 1 / -1; min-height: 27px; display: flex; align-items: flex-end; justify-content: space-between; margin-top: 3px; padding: 8px 4px 0; border-top: 1px solid var(--dusk-line); color: #5d4aa0; font-size: 8.5px; font-weight: 600; text-decoration: none; }
.briefing-link .material-symbols-rounded { color: #92786c; font-size: 14px; }

.priorities-card { margin-top: 9px; padding: 9px 14px 8px; }
.priorities-card > h2 { margin: 0 0 7px 1px; }
.practice-priority-count { display: inline-grid; min-width: 18px; height: 18px; place-items: center; margin-left: 5px; border-radius: 999px; color: #6552a1; background: rgba(123,104,170,.12); font: 700 9px/1 'Albert Sans',sans-serif; }
.priority-list,
.activity-list { overflow: hidden; border: 1px solid var(--dusk-line); border-radius: 9px; }
.priority-row { min-height: 38px; display: grid; grid-template-columns: 30px minmax(0,1fr) 27px 12px; align-items: center; gap: 9px; padding: 5px 8px; border-top: 1px solid var(--dusk-line); color: inherit; text-decoration: none; }
.priority-row:first-child,.activity-row:first-child { border-top: 0; }
.priority-icon { width: 28px; height: 28px; display: grid; place-items: center; border-radius: 50%; }
.priority-icon .material-symbols-rounded { font-size: 17px; }
.priority-icon .filled { font-variation-settings: 'FILL' 1, 'wght' 400; }
.priority-icon.amber { color: #ed680e; background: rgba(236,109,24,.12); }
.priority-icon.purple { color: #6552a1; background: rgba(123,104,170,.12); }
.priority-icon.green { color: #4f8753; background: rgba(91,141,84,.12); }
.priority-row > span:nth-child(2) { min-width: 0; display: flex; flex-direction: column; }
.priority-row strong { color: var(--dusk-ink); font-size: 8px; }
.priority-row small { margin-top: 2px; color: var(--dusk-copy); font-size: 7.2px; }
.priority-row b { font: 600 20px/1 'Source Serif 4',serif; text-align: right; }
.priority-row b.amber { color: #e75d05; }
.priority-row b.purple { color: #6250a0; }
.priority-row b.green { color: #47814d; }
.priority-row > .material-symbols-rounded { color: #92786c; font-size: 14px; }
.practice-home-clear { margin: 0; padding: 18px 12px; color: var(--dusk-copy); font-size: 8px; line-height: 1.4; text-align: center; }
.practice-home-clear.error { color: #ad4e42; }

.home-paired-grid { display: grid; grid-template-columns: .92fr 1.08fr; gap: 8px; margin-top: 9px; }
.snapshot-card,
.activity-card { min-width: 0; padding: 9px 10px 8px; }
.snapshot-card h2 { display: flex; align-items: center; gap: 5px; }
.snapshot-card h2 .material-symbols-rounded { font-size: 11px; }
.snapshot-grid { display: grid; grid-template-columns: repeat(2,minmax(0,1fr)); gap: 6px; margin-top: 8px; }
.snapshot-stat { min-width: 0; min-height: 62px; display: grid; grid-template-columns: 26px minmax(0,1fr); align-items: start; gap: 5px; padding: 7px 6px; border: 1px solid var(--dusk-line); border-radius: 10px; }
.snapshot-icon { width: 24px; height: 24px; display: grid; place-items: center; border-radius: 50%; }
.snapshot-icon .material-symbols-rounded { font-size: 15px; }
.snapshot-icon .filled { font-variation-settings: 'FILL' 1, 'wght' 400; }
.snapshot-stat > span:last-child { min-width: 0; display: flex; flex-direction: column; }
.snapshot-stat small { min-height: 20px; color: var(--dusk-ink); font-size: 6.7px; line-height: 1.15; }
.snapshot-stat strong { margin-top: 5px; font: 500 17px/1 'Source Serif 4',serif; }
.snapshot-stat em { margin-top: 6px; color: var(--dusk-copy); font-size: 6px; font-style: normal; white-space: nowrap; }
.snapshot-stat.purple .snapshot-icon,.snapshot-stat.purple strong { color: #6652a4; background-color: rgba(123,104,170,.12); }
.snapshot-stat.green .snapshot-icon,.snapshot-stat.green strong { color: #4e8552; background-color: rgba(91,141,84,.12); }
.snapshot-stat.blue .snapshot-icon,.snapshot-stat.blue strong { color: #327ab5; background-color: rgba(74,128,179,.12); }
.snapshot-stat.amber .snapshot-icon,.snapshot-stat.amber strong { color: #e8650c; background-color: rgba(232,108,22,.11); }
.snapshot-stat strong { background: transparent !important; }
.activity-card > h2 { margin-bottom: 8px; }
.activity-row { min-height: 46px; display: grid; grid-template-columns: 29px minmax(0,1fr) auto 12px; align-items: center; gap: 7px; padding: 5px 7px; border-top: 1px solid var(--dusk-line); color: inherit; text-decoration: none; }
.activity-initial { width: 28px; height: 28px; display: grid; place-items: center; border-radius: 7px; font-size: 10px; }
.activity-initial.purple { color: #6652a4; background: rgba(123,104,170,.12); }
.activity-initial.green { color: #4e8552; background: rgba(91,141,84,.12); }
.activity-initial.amber { color: #e8650c; background: rgba(232,108,22,.11); }
.activity-row > span:nth-child(2) { min-width: 0; display: flex; flex-direction: column; }
.activity-row strong { color: var(--dusk-ink); font-size: 6.7px; }
.activity-row small { margin-top: 2px; color: var(--dusk-copy); font-size: 6.4px; }
.activity-row em { display: flex; align-items: center; gap: 4px; color: var(--dusk-copy); font-size: 6.2px; font-style: normal; white-space: nowrap; }
.activity-row em i { width: 5px; height: 5px; border-radius: 50%; }
.activity-row em.high i { background: #559356; }
.activity-row em.steady i { background: #3d82ba; }
.activity-row em.follow i { background: #f07a10; }
.activity-row > .material-symbols-rounded { color: #92786c; font-size: 13px; }

.quick-actions-card { margin-top: 9px; padding: 9px 14px 9px; }
.quick-actions-card > h2 { margin-bottom: 8px; }
.quick-actions-grid { display: grid; grid-template-columns: repeat(3,minmax(0,1fr)); gap: 8px; }
.quick-actions-grid a { min-width: 0; min-height: 42px; display: grid; grid-template-columns: 28px minmax(0,1fr) 12px; align-items: center; gap: 8px; padding: 6px 8px; border: 1px solid var(--dusk-line); border-radius: 10px; color: inherit; text-decoration: none; }
.quick-icon { width: 28px; height: 28px; display: grid; place-items: center; border-radius: 7px; color: #fff; background: linear-gradient(145deg,#755fad,#4c347e); }
.quick-icon .material-symbols-rounded { font-size: 17px; }
.quick-icon .filled { font-variation-settings: 'FILL' 1, 'wght' 400; }
.quick-actions-grid strong { color: var(--dusk-ink); font-size: 7px; line-height: 1.15; }
.quick-actions-grid a > .material-symbols-rounded { color: #92786c; font-size: 13px; }

.practice-home-boundary { display: flex; align-items: flex-start; gap: 10px; margin-top: 9px; padding: 12px 14px; border: 1px solid rgba(112,86,163,.2); border-radius: 12px; background: rgba(112,86,163,.07); }
.practice-home-boundary > .material-symbols-rounded { color: #6752a3; font-size: 17px; }
.practice-home-boundary p { margin: 0; color: var(--dusk-copy); font-size: 7.5px; line-height: 1.45; }
.practice-home-boundary strong,.practice-home-boundary span { display: block; }
.practice-home-boundary strong { margin-bottom: 2px; color: var(--dusk-ink); font-size: 8px; }

.practice-home-dock { position: fixed; z-index: 70; left: 50%; bottom: calc(9px + env(safe-area-inset-bottom)); width: calc(100% - 22px); max-width: 618px; min-height: 47px; display: grid; grid-template-columns: repeat(3,1fr); gap: 4px; padding: 5px; border: 1px solid var(--dusk-line); border-radius: 999px; background: rgba(255,252,248,.96); box-shadow: 0 13px 34px -18px rgba(58,45,39,.45); transform: translateX(-50%); backdrop-filter: blur(12px); }
.practice-home-dock a,
.practice-home-dock > span { min-width: 0; display: flex; align-items: center; justify-content: center; gap: 7px; padding: 8px 10px; border-radius: 999px; color: #9a7f70; font-size: 10.5px; font-weight: 700; text-decoration: none; }
.practice-home-dock .practice-dock-disabled { opacity: .46; cursor: not-allowed; }
.practice-home-dock .material-symbols-rounded { font-size: 17px; }
.practice-home-dock .active { color: var(--dusk-pill-text); background: var(--dusk-pill); }
.practice-home-dock .active .material-symbols-rounded { color: var(--dusk-pill-icon); font-variation-settings: 'FILL' 1, 'wght' 450; }

.home-reveal { animation: homeReveal .52s cubic-bezier(.22,1,.36,1) var(--home-delay,0ms) both; }
@keyframes homeReveal { from { opacity: 0; transform: translateY(7px); } to { opacity: 1; transform: translateY(0); } }

html.dark .home-card,
html.dark .practice-home-dock { background: rgba(33,30,44,.95); }

@media (min-width: 701px) {
  .home-hero { min-height: 245px; padding: calc(18px + env(safe-area-inset-top)) 22px 42px; }
  .home-hero .dusk-disc { top: 72px; width: 52px; height: 52px; box-shadow: 0 0 34px rgba(242,181,126,.72); }
  .home-wordmark { font-size: 18px; }
  .home-actions { gap: 9px; }
  .home-icon-button,.home-avatar { width: 39px; height: 39px; }
  .home-icon-button .material-symbols-rounded { font-size: 19px; }
  .home-hero-copy { margin-top: 25px; padding-right: 70px; }
  .home-admin-badge { font-size: 9.5px; letter-spacing: .06em; text-transform: uppercase; }
  .home-hero h1 { margin-top: 13px; font-size: 38px; }
  .home-description { margin-top: 8px; font-size: 12px; }
  .home-trust { margin-top: 10px; font-size: 9.5px; }

  .practice-home-main { padding: 0 18px 42px; }
  .practice-home-status { margin: 10px 2px; font-size: 9px; }
  .home-card { border-radius: 19px; box-shadow: 0 14px 34px -28px rgba(58,45,39,.5); }
  .home-card > h2 { font-size: 18px; }

  .weekly-briefing { grid-template-columns: minmax(0,1fr) 128px; gap: 12px 24px; padding: 20px 22px 17px; }
  .briefing-copy .eyebrow { font: 750 8.5px/1 'Albert Sans',sans-serif; letter-spacing: .13em; text-transform: uppercase; }
  .briefing-copy h2 { margin-top: 7px; font-size: 28px; }
  .briefing-copy > p:last-child { max-width: 540px; margin-top: 8px; font-size: 10.5px; line-height: 1.45; }
  .briefing-visual { width: 118px; height: 118px; }
  .briefing-sun { left: 45px; top: 29px; width: 35px; height: 35px; }
  .hill { width: 145px; height: 76px; bottom: -27px; }
  .hill.two { left: 25px; bottom: -39px; }
  .briefing-metrics { gap: 9px; margin-top: 2px; padding-top: 14px; border-top: 1px solid var(--dusk-line); }
  .briefing-metric { min-height: 58px; grid-template-columns: 36px minmax(0,1fr); gap: 0 9px; padding: 8px 11px; border-radius: 12px; }
  .metric-icon { width: 34px; height: 34px; }
  .metric-icon .material-symbols-rounded { font-size: 19px; }
  .briefing-metric strong { font-size: 19px; }
  .briefing-metric small { margin-top: 2px; font-size: 8px; }
  .briefing-link { min-height: 34px; margin-top: 0; padding: 11px 4px 0; font-size: 9px; }

  .priorities-card { margin-top: 11px; padding: 16px; }
  .priorities-card > h2 { margin-bottom: 12px; }
  .practice-priority-count { min-width: 27px; height: 27px; font-size: 10px; }
  .priority-list,.activity-list { border-radius: 12px; }
  .priority-row { min-height: 54px; grid-template-columns: 36px minmax(0,1fr) 34px 15px; gap: 10px; padding: 8px 10px; }
  .priority-icon { width: 34px; height: 34px; }
  .priority-icon .material-symbols-rounded { font-size: 19px; }
  .priority-row strong { font-size: 9.5px; }
  .priority-row small { margin-top: 3px; font-size: 8px; line-height: 1.3; }
  .priority-row b { font-size: 22px; }

  .home-paired-grid { grid-template-columns: 1fr 1fr; gap: 11px; margin-top: 11px; }
  .snapshot-card,.activity-card { padding: 16px; }
  .snapshot-card h2,.activity-card > h2 { margin-bottom: 12px; }
  .snapshot-grid { gap: 8px; margin-top: 0; }
  .snapshot-stat { min-height: 78px; grid-template-columns: 36px minmax(0,1fr); gap: 9px; padding: 10px; border-radius: 12px; }
  .snapshot-icon { width: 34px; height: 34px; }
  .snapshot-icon .material-symbols-rounded { font-size: 19px; }
  .snapshot-stat small { min-height: 24px; font-size: 8px; }
  .snapshot-stat strong { margin-top: 4px; font-size: 22px; }
  .snapshot-stat em { margin-top: 5px; font-size: 7.5px; }
  .activity-row { min-height: 59px; grid-template-columns: 36px minmax(0,1fr) auto 15px; gap: 9px; padding: 8px 10px; }
  .activity-initial { width: 34px; height: 34px; border-radius: 10px; font-size: 10px; }
  .activity-row strong { font-size: 9px; }
  .activity-row small { margin-top: 3px; font-size: 7.7px; }
  .activity-row em { font-size: 7.5px; }

  .quick-actions-card { margin-top: 11px; padding: 16px; }
  .quick-actions-card > h2 { margin-bottom: 11px; }
  .quick-actions-grid { gap: 9px; }
  .quick-actions-grid a { min-height: 60px; grid-template-columns: 36px minmax(0,1fr) 15px; gap: 10px; padding: 10px; border-radius: 12px; }
  .quick-icon { width: 35px; height: 35px; border-radius: 11px; }
  .quick-icon .material-symbols-rounded { font-size: 19px; }
  .quick-actions-grid strong { font-size: 9px; }
  .practice-home-boundary { margin-top: 11px; padding: 14px 16px; border-radius: 15px; }
  .practice-home-boundary > .material-symbols-rounded { font-size: 20px; }
  .practice-home-boundary p { font-size: 8.2px; }
  .practice-home-boundary strong { font-size: 9px; }
}

@media (max-width: 700px) {
  :root { --practice-home-max: 640px; }
}

@media (max-width: 419px) {
  .home-hero { min-height: 190px; padding-inline: 16px; }
  .home-wordmark { font-size: 14px; }
  .home-practice-name { max-width: 200px; font-size: 9.5px; }
  .home-icon-button,.home-avatar { width: 32px; height: 32px; }
  .home-hero-copy { padding-right: 28px; }
  .home-hero h1 { font-size: 26px; }
  .home-description,.home-trust { font-size: 9px; }
  .practice-home-main { padding-inline: 11px; }
  .weekly-briefing { grid-template-columns: 1fr 74px; padding-inline: 11px; }
  .briefing-visual { width: 72px; height: 72px; }
  .briefing-sun { left: 27px; top: 20px; width: 23px; height: 23px; }
  .briefing-metrics { grid-template-columns: 1fr; gap: 5px; }
  .briefing-metric { min-height: 39px; }
  .home-paired-grid { grid-template-columns: 1fr; }
  .activity-row strong { font-size: 7.5px; }
  .quick-actions-grid { grid-template-columns: 1fr; }
  .practice-home-dock a { gap: 4px; padding-inline: 5px; font-size: 9px; }
}

@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }
  .home-reveal { animation: none !important; }
}

/* ── Wide desktop ───────────────────────────────────────────────
   Matches the clinician workspace's 1160px shell. The briefing,
   quick actions and the boundary note stay full width; operational
   priorities and the snapshot pair share a row, so a laptop shows
   the whole account without scrolling past three stacked cards.
   ─────────────────────────────────────────────────────────────── */
@media (min-width: 1000px) {
  :root { --practice-home-max: 1160px; }

  /* Three columns, so operational priorities, the snapshot and care-team
     coverage share one row instead of stacking into a 494px column. That
     block alone was a third of the page. */
  .practice-home-main {
    display: grid;
    grid-template-columns: repeat(3, minmax(0, 1fr));
    gap: 12px 16px;
    align-items: start;
    padding: 0 26px 52px;
  }
  .practice-home-status,
  .practice-home-boundary { grid-column: 1 / -1; }
  /* Briefing and quick actions share a row; quick actions is a short
     three-link card and a full-width row of its own was wasted height. */
  .weekly-briefing { grid-column: span 2; }
  .quick-actions-card { grid-column: span 1; }

  .home-paired-grid { grid-column: span 2; grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .priorities-card { margin-top: 0; }

  /* The dock is a phone pattern: pinned to the bottom of the viewport, it
     floats over the content and is the first thing anything else on screen
     covers. On a desktop it belongs in the page, under the UI it navigates, which is what the clinician workspace does when it swaps its hotbar
     for inline tabs above 820px. */
  /* Back on the viewport, because each admin page is its own document:
     in flow the dock landed at a different height on every tab, so the
     nav you just clicked jumped hundreds of pixels. Lifted clear of the
     preview banner rather than hidden behind it. */
  .practice-home-dock {
    position: fixed;
    bottom: calc(16px + var(--ed-preview-banner-h, 0px));
    left: 50%;
    transform: translateX(-50%);
    width: min(618px, 100%);
    box-shadow: 0 10px 28px -20px rgba(58,45,39,.45);
  }

  /* One hero height across the four admin pages. They are separate
     documents, so an uneven hero moves the whole page down as you
     switch tabs and the change reads as a glitch. */
  /* One hero across the four admin pages: same height and the same
     type. Home was running a 38px h1 and an 18px wordmark against
     29px and 16px everywhere else, so the banner visibly changed
     weight as you moved between tabs. */
  .home-hero { min-height: 172px; padding-bottom: 26px; }
  .home-hero h1 { font-size: 29px; line-height: 1.08; }
  .home-wordmark { font-size: 16px; }
  .home-description { font-size: 11px; }
  .home-admin-badge { font-size: 9px; font-weight: 600; }

  /* The dock floats over the page, so the last card needs room to
     scroll out from under it, banner included. */
  .practice-home-main { padding-bottom: calc(104px + var(--ed-preview-banner-h, 0px)); }

  /* Density pass so the page fits a laptop screen. */
  .practice-home-main { padding-bottom: calc(72px + var(--ed-preview-banner-h, 0px)); gap: 10px 14px; }
  .home-hero-copy { margin-top: 16px; }
  .home-hero h1 { margin-top: 9px; }
  .home-description { margin-top: 6px; }
  .home-trust { margin-top: 7px; }
  .weekly-briefing { padding: 16px 18px 14px; }
  .briefing-copy h2 { font-size: 23px; }
  .briefing-metrics { padding-top: 11px; }
  .priorities-card, .quick-actions-card { padding: 14px; }
}

/* Like the clinician workspace, let the dashboard breathe and keep labels
   legible on ordinary laptop windows as well as large monitors. */
@media (min-width: 701px) {
  :root { --practice-home-max: min(1540px, calc(100vw - 48px)); }
  .practice-home-main { gap: 16px 20px; padding-inline: 20px; }
  .home-hero-inner { padding-inline: 20px; }
  .home-practice-name, .home-description { font-size: 14px; }
  .home-trust { font-size: 12px; }
  .practice-home-status { font-size: 12px; }
  .home-card > h2 { font-size: 21px; }
  .briefing-copy .eyebrow { font-size: 11px; }
  .briefing-copy > p:last-child { font-size: 14px; max-width: 680px; }
  .briefing-metric strong { font-size: 22px; }
  .briefing-metric small, .briefing-link { font-size: 12px; }
  .priority-row strong, .snapshot-stat small, .activity-row strong,
  .quick-actions-grid strong { font-size: 13px; }
  .priority-row small, .snapshot-stat em, .activity-row small,
  .activity-row em { font-size: 11px; }
  .practice-home-clear, .practice-home-boundary p { font-size: 12px; }
  .practice-home-boundary strong { font-size: 13px; }
}

@media (min-width: 1000px) and (max-width: 1279px) {
  .practice-home-main { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .weekly-briefing, .priorities-card { grid-column: span 1; }
  .home-paired-grid, .quick-actions-card { grid-column: 1 / -1; }
}

/* Desktop reading scale: the original card type was sized for the compact
   mockup, leaving the live clinic dashboard unusually small on wide screens. */
@media (min-width: 1000px) {
  .practice-home-main { gap: 20px; padding-top: 20px; }
  .home-hero { min-height: 205px; }
  .home-hero h1 { font-size: 36px; }
  .home-description, .home-practice-name { font-size: 15px; }
  .home-trust, .practice-home-status { font-size: 13px; }
  .home-card { border-radius: 18px; }
  .weekly-briefing, .priorities-card, .quick-actions-card { padding: 21px; }
  .snapshot-card, .activity-card { padding: 21px; }
  .home-card > h2 { font-size: 24px; }
  .briefing-copy h2 { font-size: 30px; }
  .briefing-copy > p:last-child { font-size: 15px; }
  .briefing-metric { min-height: 68px; grid-template-columns: 38px minmax(0, 1fr); padding: 10px 12px; }
  .metric-icon { width: 36px; height: 36px; }
  .briefing-metric strong { font-size: 26px; }
  .briefing-metric small { font-size: 12px; }
  .briefing-link { min-height: 40px; font-size: 13px; }
  .priority-list, .activity-list { border-radius: 13px; }
  .priority-row { min-height: 58px; grid-template-columns: 38px minmax(0, 1fr) 32px 16px; gap: 11px; padding: 9px 12px; }
  .priority-icon { width: 36px; height: 36px; }
  .priority-row strong, .practice-home-clear { font-size: 14px; }
  .priority-row small { font-size: 12px; }
  .activity-row { min-height: 60px; grid-template-columns: 38px minmax(0, 1fr) auto 16px; gap: 10px; padding: 9px 12px; }
  .activity-initial { width: 36px; height: 36px; font-size: 12px; }
  .activity-row strong { font-size: 14px; }
  .activity-row small, .activity-row em { font-size: 12px; }
  .snapshot-grid { gap: 10px; margin-top: 14px; }
  .snapshot-stat { min-height: 104px; grid-template-columns: 38px minmax(0, 1fr); gap: 10px; padding: 14px; }
  .snapshot-icon { width: 36px; height: 36px; }
  .snapshot-stat small { min-height: 0; font-size: 13px; }
  .snapshot-stat strong { font-size: 27px; }
  .snapshot-stat em { font-size: 12px; white-space: normal; }
  .quick-actions-grid a { min-height: 72px; grid-template-columns: 36px minmax(0, 1fr) 16px; gap: 9px; padding: 10px; }
  .quick-icon { width: 36px; height: 36px; }
  .quick-actions-grid strong { font-size: 13px; }
  .practice-home-dock a { font-size: 13px; }
}
