/* Practice Handled. Tokens come from the design canvas. */
:root {
  --ground: #F6F8F3; --surface: #FFFFFF; --ink: #1C2419; --muted: #56614F;
  --line: #DCE3D6; --accent: #46663C; --accent-ink: #FFFFFF; --soft: #E8EFE3;
  --warn: #8A5A12; --warn-soft: #FBF1DD; --bad: #9B2C2C; --bad-soft: #FBE9E7;
  --radius: 14px; --shadow: 0 1px 2px rgba(22,33,31,.05), 0 8px 28px rgba(22,33,31,.06);
  --font: "Manrope", "Segoe UI Variable Text", "Segoe UI", system-ui, sans-serif;
  --mono: "Cascadia Mono", Consolas, monospace;
  /* Added for night mode (ph/daynight.py); each has a night value below. Text tokens are 4.5:1 or
     better on --surface and --ground in both looks. */
  --ok: #2B7A3F; --ok-soft: #E7F5EA;                         /* done */
  --info: #23498A; --info-soft: #EEF3FB; --info-line: #9DB3D6;
  --warn-line: #E8A15A; --bad-line: #E9B8B2;
  --danger: #B3261E;                                         /* text/borders only; red buttons keep their own fill */
  --pine: #1D5C55; --plum: #6B4E8A;                          /* the admin portal's teal, and a purple tag */
  --deep: #1C2419;                                           /* dark bands (light text on them in both looks) */
  --field: #FFFFFF; --field-line: #DCE3D6;                   /* text boxes and drop-downs */
  --paper: #FFFFFF; --paper-ink: #1C2419;                    /* always light: drawings, scans, signatures */
  --paper-panel: transparent;                                /* behind pictures and logos: nothing by day, light at night */
  color-scheme: light;
}
/* Night: the device's own setting (no choice saved), or Night chosen on this device. Screens
   only: printing always uses the day colors above. */
@media screen and (prefers-color-scheme: dark) {
  :root:not([data-theme="day"]) {
    --ground: #121712; --surface: #1A211A; --ink: #E6ECE2; --muted: #A3AE9C;
    --line: #2E392D; --accent: #8FBF7F; --accent-ink: #0F1A0C; --soft: #223021;
    --warn: #E3B46A; --warn-soft: #3A2E17; --bad: #F08B84; --bad-soft: #3D1E1C;
    --shadow: 0 1px 2px rgba(0,0,0,.35), 0 8px 28px rgba(0,0,0,.30);
    --ok: #8FD3A0; --ok-soft: #1D3324; --info: #A8C4F2; --info-soft: #1C2638; --info-line: #3E5478;
    --warn-line: #8A6328; --bad-line: #6E3530; --danger: #FF9A90; --pine: #86CDBF; --plum: #CBB2EA;
    --deep: #0B0F0B; --field: #121812; --field-line: #46524A; --paper-panel: #F4F6F1;
    color-scheme: dark;
  }
}
@media screen {
  :root[data-theme="night"] {
    --ground: #121712; --surface: #1A211A; --ink: #E6ECE2; --muted: #A3AE9C;
    --line: #2E392D; --accent: #8FBF7F; --accent-ink: #0F1A0C; --soft: #223021;
    --warn: #E3B46A; --warn-soft: #3A2E17; --bad: #F08B84; --bad-soft: #3D1E1C;
    --shadow: 0 1px 2px rgba(0,0,0,.35), 0 8px 28px rgba(0,0,0,.30);
    --ok: #8FD3A0; --ok-soft: #1D3324; --info: #A8C4F2; --info-soft: #1C2638; --info-line: #3E5478;
    --warn-line: #8A6328; --bad-line: #6E3530; --danger: #FF9A90; --pine: #86CDBF; --plum: #CBB2EA;
    --deep: #0B0F0B; --field: #121812; --field-line: #46524A; --paper-panel: #F4F6F1;
    color-scheme: dark;
  }
}
/* A practice's own colors (public page, booking, client portal: themes.style_vars sets --brand
   and the rest on <body>). At night its accent is lightened so it reads on the dark ground. */
@media screen and (prefers-color-scheme: dark) {
  :root:not([data-theme="day"]) body[style*="--brand"] {
    --accent: color-mix(in srgb, var(--brand) 42%, #E6ECE2) !important; --soft: color-mix(in srgb, var(--brand) 30%, #1A211A) !important;
    --ground: #121712 !important; --ink: #E6ECE2 !important;
  }
}
@media screen {
  :root[data-theme="night"] body[style*="--brand"] {
    --accent: color-mix(in srgb, var(--brand) 42%, #E6ECE2) !important; --soft: color-mix(in srgb, var(--brand) 30%, #1A211A) !important;
    --ground: #121712 !important; --ink: #E6ECE2 !important;
  }
}
/* Pictures, signatures, scanned faxes, uploaded photos and drawings sit on a light panel at
   night instead of being inverted. */
:is(.on-paper, .care-art, .plogo-img, img.ux-thumb, .art-piece img, .epic-logo) { background-color: var(--paper-panel); }
* { box-sizing: border-box; }
html { -webkit-text-size-adjust: 100%; }
body { margin: 0; background: var(--ground); color: var(--ink); font: 16px/1.55 var(--font); }
a { color: var(--accent); }
h1, h2, h3 { line-height: 1.15; letter-spacing: -.02em; margin: 0; }
p { margin: 0; }
.wrap { max-width: 1120px; margin: 0 auto; padding: 0 24px; }
.eyebrow { font: 700 12px/1 var(--font); letter-spacing: .14em; text-transform: uppercase; color: var(--accent); }
.muted { color: var(--muted); }
.small { font-size: 14px; }

.btn { display: inline-flex; align-items: center; justify-content: center; gap: 8px; min-height: 44px;
  padding: 0 20px; border-radius: 999px; border: 1px solid var(--accent); background: var(--accent);
  color: var(--accent-ink); font: 700 15px/1 var(--font); text-decoration: none; cursor: pointer; }
.btn:hover { filter: brightness(1.08); }
.btn.ghost { background: transparent; color: var(--accent); border-color: var(--line); }
.btn.ghost:hover { background: var(--soft); filter: none; }
.btn.danger { background: transparent; color: var(--bad); border-color: var(--line); }
.btn.sm { min-height: 36px; padding: 0 14px; font-size: 14px; }
:focus-visible { outline: 3px solid color-mix(in srgb, var(--accent) 45%, transparent); outline-offset: 2px; }

.card { background: var(--surface); border: 1px solid var(--line); border-radius: var(--radius); padding: 24px; }
.card + .card { margin-top: 20px; }
/* Stacked cards keep the same 20px gap when the markup puts something between them:
   an invisible element (hidden field, <link>, <datalist>, <script>, a closed <dialog>),
   or a wrapper (a <form>, or the .cols grid) that starts or ends with a card.
   :where() keeps these at the plain .card weight, so a screen that joins its cards on
   purpose (e.g. .twostep .card + .card) still wins. */
:where(.card) + :where(link, script, style, template, datalist, dialog, input[type=hidden]) + :where(.card),
:where(.card) + :where(link, script, style, template, datalist, dialog, input[type=hidden]) + :where(link, script, style, template, datalist, dialog, input[type=hidden]) + :where(.card),
:where(.card) + :where(.cols, form:not(.card)),
:where(.cols, form:not(.card)):has(> .card:last-child, > .cols:last-child) + :where(.card, .cols) { margin-top: 20px; }
.card h2 { font-size: 19px; margin-bottom: 4px; }
.pill { display: inline-block; padding: 4px 10px; border-radius: 999px; background: var(--soft);
  color: var(--accent); font: 600 13px/1.3 var(--font); }
.pill.warn { background: var(--warn-soft); color: var(--warn); }
.pill.plain { background: var(--ground); color: var(--muted); }
.pill.bad { background: var(--bad-soft); color: var(--bad); }
.notice { padding: 12px 16px; border-radius: 10px; background: var(--soft); color: var(--accent); font-weight: 600; margin-bottom: 20px; }
.notice.bad { background: var(--bad-soft); color: var(--bad); }
.notice ul { margin: 0; padding-left: 18px; }

label { display: block; font-weight: 700; font-size: 14px; margin-bottom: 6px; }
.hint { font-weight: 500; color: var(--muted); font-size: 13px; }
input[type=text], input[type=email], input[type=password], input[type=tel], input[type=time],
input[type=number], input:not([type]), select, textarea { width: 100%; min-height: 44px; padding: 10px 12px; border: 1px solid var(--line);
  border-radius: 10px; background: var(--field); border-color: var(--field-line); color: var(--ink); font: 500 15px/1.4 var(--font); }
textarea { min-height: 150px; resize: vertical; }
input:focus, select:focus, textarea:focus { outline: 3px solid color-mix(in srgb, var(--accent) 30%, transparent); border-color: var(--accent); }
.field { margin-bottom: 18px; }
.row { display: grid; gap: 16px; grid-template-columns: repeat(auto-fit, minmax(180px, 1fr)); }
.check { display: flex; gap: 10px; align-items: flex-start; font-weight: 600; font-size: 15px; }
.check input { width: 20px; height: 20px; margin-top: 2px; accent-color: var(--accent); flex: none; }
.hp { position: absolute; left: -9999px; }

/* ---------- Top bar shared by the site pages ---------- */
.topbar { position: sticky; top: var(--ea-stick, 0px); z-index: 10; background: color-mix(in srgb, var(--ground) 88%, transparent);
  backdrop-filter: blur(10px); border-bottom: 1px solid var(--line); }
.topbar .wrap { display: flex; align-items: center; justify-content: space-between; height: 68px; gap: 16px; }
.brand { display: inline-flex; align-items: center; gap: 10px; font-weight: 800; font-size: 18px; letter-spacing: -.02em;
  color: var(--ink); text-decoration: none; }
.brand-mark { width: 32px; height: 32px; border-radius: 50%; background: #46663C; display: grid; place-items: center; flex: none; }
.brand-mark svg { width: 32px; height: 32px; display: block; }
.nav { display: flex; align-items: center; gap: 26px; }
.nav a.link { color: var(--muted); text-decoration: none; font-weight: 600; font-size: 15px; }
.nav a.link:hover { color: var(--ink); }
@media (max-width: 720px) { .nav a.link { display: none; } }

/* ---------- Marketing home ---------- */
.hero { padding: 72px 0 56px; }
.hero-grid { display: grid; grid-template-columns: 1.05fr 1fr; gap: 56px; align-items: center; }
.hero h1 { font-size: clamp(38px, 5.4vw, 62px); font-weight: 800; margin: 18px 0 20px; }
.hero h1 em { font-style: normal; color: var(--accent); }
.hero p.lead { font-size: 19px; color: var(--muted); max-width: 520px; }
.hero p.lead + p.lead { margin-top: 12px; }
.hero .actions { display: flex; flex-wrap: wrap; gap: 12px; margin-top: 30px; }
.hero .assure { margin-top: 22px; display: flex; flex-wrap: wrap; gap: 8px 20px; color: var(--muted); font-size: 14px; font-weight: 600; }
.hero .assure span::before { content: "\2713"; color: var(--accent); margin-right: 6px; font-weight: 800; }
.mock { background: var(--surface); border: 1px solid var(--line); border-radius: 20px; box-shadow: var(--shadow); padding: 18px; }
.mock-bar { display: flex; gap: 6px; margin-bottom: 14px; }
.mock-bar i { width: 10px; height: 10px; border-radius: 50%; background: var(--line); }
.mock-head { display: flex; justify-content: space-between; align-items: baseline; margin-bottom: 12px; }
.mock-head b { font-size: 17px; }
.mock-head span { font: 500 12px var(--font); color: var(--muted); }
.mock-row { display: grid; grid-template-columns: 64px 1fr auto; gap: 12px; align-items: center; padding: 12px;
  border: 1px solid var(--line); border-radius: 12px; margin-bottom: 8px; }
.mock-row .t { font: 600 13px var(--font); color: var(--accent); }
.mock-row b { display: block; font-size: 15px; }
.mock-row small { color: var(--muted); }
.mock-stats { display: grid; grid-template-columns: repeat(3, 1fr); gap: 8px; margin-top: 12px; }
.mock-stats div { background: var(--ground); border-radius: 12px; padding: 12px; }
.mock-stats b { display: block; font-size: 20px; letter-spacing: -.02em; }
.mock-stats small { color: var(--muted); font-size: 12px; }
/* The Today mock on the marketing homes: the real Today page's order (dashboard.html), in miniature. */
.mock-today .mock-head { align-items: center; gap: 10px; }
.mock-today .mock-head small { display: block; font: 700 11px/1 var(--font); letter-spacing: .14em; color: var(--accent); margin-bottom: 6px; }
.mock-today .mock-head b { font-size: 20px; }
.mock-today .mock-head span { border: 1px solid var(--line); border-radius: 999px; padding: 5px 10px; white-space: nowrap; }
.mock-now { display: flex; align-items: center; justify-content: space-between; gap: 12px; padding: 12px 14px; margin-bottom: 14px;
  border: 1px solid var(--line); border-left: 4px solid var(--accent); border-radius: 12px; background: var(--soft); }
.mock-now small { display: block; font: 700 10.5px/1.2 var(--font); letter-spacing: .1em; color: var(--accent); }
.mock-now b { display: block; font-size: 16px; margin: 3px 0 2px; }
.mock-now div span { font-size: 13px; color: var(--muted); }
.mock-now em { font-style: normal; font-weight: 700; color: var(--accent); white-space: nowrap; }
.mock-btn { flex: none; background: var(--accent); color: var(--accent-ink); border-radius: 999px; padding: 8px 18px; font: 700 14px/1 var(--font); }
.mock-sec { display: flex; align-items: center; justify-content: space-between; margin: 12px 2px 8px; }
.mock-sec b { font-size: 15px; }
.mock-sec span:not(.pill) { font: 600 12px var(--font); color: var(--accent); border: 1px solid var(--line); border-radius: 999px; padding: 3px 10px; }
.mock-today .mock-row { padding: 10px 12px; grid-template-columns: 58px minmax(0, 1fr) auto; }
.mock-today .mock-row .t small { display: block; font-weight: 500; color: var(--muted); }
.mock-today .mock-row .pill.ghost { background: transparent; border: 1px solid var(--line); }
@media (max-width: 420px) { .mock { padding: 14px; } .mock-today .mock-row { grid-template-columns: 56px minmax(0, 1fr); gap: 4px 10px; }
  .mock-today .mock-row .pill { grid-column: 2; justify-self: start; } }
@media (max-width: 900px) { .hero-grid { grid-template-columns: 1fr; gap: 36px; } .hero { padding-top: 44px; } }

.band { padding: 72px 0; }
.band.white { background: var(--surface); border-top: 1px solid var(--line); border-bottom: 1px solid var(--line); }
.band-head { max-width: 640px; margin-bottom: 40px; }
.band-head h2 { font-size: clamp(28px, 3.6vw, 40px); font-weight: 800; margin: 14px 0 12px; }
.band-head p { color: var(--muted); font-size: 18px; }
.features { display: grid; grid-template-columns: repeat(3, 1fr); gap: 18px; }
.feature { background: var(--surface); border: 1px solid var(--line); border-radius: var(--radius); padding: 24px; }
.feature .ico { width: 42px; height: 42px; border-radius: 12px; background: var(--soft); color: var(--accent); display: grid; place-items: center; margin-bottom: 16px; }
.feature .ico svg { width: 22px; height: 22px; }
.feature h3 { font-size: 18px; margin-bottom: 8px; }
.feature p { color: var(--muted); font-size: 15px; }
@media (max-width: 900px) { .features { grid-template-columns: 1fr 1fr; } }
@media (max-width: 600px) { .features { grid-template-columns: 1fr; } }

.split { display: grid; grid-template-columns: 1fr 1fr; gap: 56px; align-items: center; }
.split h2 { font-size: clamp(26px, 3.2vw, 36px); font-weight: 800; margin: 14px 0 14px; }
.split p { color: var(--muted); font-size: 17px; }
.ticks { list-style: none; padding: 0; margin: 22px 0 28px; display: grid; gap: 12px; }
.ticks li { padding-left: 30px; position: relative; font-weight: 600; }
.ticks li::before { content: "\2713"; position: absolute; left: 0; top: 2px; width: 20px; height: 20px; border-radius: 50%;
  background: var(--soft); color: var(--accent); font-size: 12px; font-weight: 800; display: grid; place-items: center; }
.urlbar { font: 500 13px var(--font); background: var(--ground); border-radius: 999px; padding: 8px 14px; color: var(--muted); margin-bottom: 14px; }
.urlbar b { color: var(--ink); }
.mini-profile { display: flex; gap: 14px; align-items: center; margin-bottom: 14px; }
.avatar { width: 56px; height: 56px; border-radius: 50%; background: var(--soft); color: var(--accent); display: grid; place-items: center; font-weight: 800; font-size: 20px; flex: none; }
.avatar.lg { width: 96px; height: 96px; font-size: 34px; }
.chips { display: flex; flex-wrap: wrap; gap: 8px; }
.slot { display: inline-flex; align-items: center; justify-content: center; min-height: 44px; padding: 0 16px; border-radius: 10px;
  border: 1px solid var(--line); background: var(--surface); color: var(--accent); font-weight: 700; font-size: 15px; text-decoration: none; }
a.slot:hover { background: var(--accent); color: var(--accent-ink); border-color: var(--accent); }
@media (max-width: 900px) { .split { grid-template-columns: 1fr; gap: 32px; } }

.steps { display: grid; grid-template-columns: repeat(3, 1fr); gap: 18px; counter-reset: step; }
.step { padding: 24px; border-radius: var(--radius); border: 1px solid var(--line); background: var(--surface); }
.step::before { counter-increment: step; content: "0" counter(step); font: 600 13px var(--font); color: var(--accent); }
.step h3 { margin: 10px 0 8px; font-size: 18px; }
.step p { color: var(--muted); font-size: 15px; }
@media (max-width: 800px) { .steps { grid-template-columns: 1fr; } }
.cta { background: var(--accent); color: var(--accent-ink); border-radius: 24px; padding: 48px; display: flex; flex-wrap: wrap; gap: 24px; align-items: center; justify-content: space-between; }
.cta h2 { font-size: clamp(26px, 3.2vw, 36px); font-weight: 800; }
.cta p { opacity: .85; margin-top: 8px; }
.prose .cta p { color: inherit; }   /* not the prose's muted gray on the accent */
.cta .btn { background: var(--surface); color: var(--accent); border-color: var(--surface); }
.foot { padding: 32px 0 48px; color: var(--muted); font-size: 14px; }
.foot .wrap { display: flex; flex-wrap: wrap; gap: 12px; justify-content: space-between; }

/* ---------- Sign in ---------- */
.center { min-height: calc(100vh - 69px); display: grid; place-items: center; padding: 40px 24px; }
.auth { width: 100%; max-width: 420px; }
.auth h1 { font-size: 28px; font-weight: 800; margin-bottom: 6px; }

/* ---------- Portal ---------- */
.shell { display: grid; grid-template-columns: 240px 1fr; min-height: 100vh; }
.side { background: var(--surface); border-right: 1px solid var(--line); padding: 22px 16px; display: flex; flex-direction: column; gap: 4px; }
.side .brand { margin: 0 8px 22px; }
.side a.item, .side span.item { display: flex; align-items: center; justify-content: space-between; min-height: 44px; padding: 0 12px;
  border-radius: 10px; color: var(--ink); text-decoration: none; font-weight: 600; font-size: 15px; }
.side a.item:hover { background: var(--ground); }
.side a.item.on { background: var(--soft); color: var(--accent); }
.side span.item { color: var(--muted); }
.side span.item small { font: 500 11px var(--font); }
.side .who { margin-top: auto; padding: 14px 12px 0; border-top: 1px solid var(--line); font-size: 14px; }
.side .who b { display: block; }
.side .who form { margin-top: 10px; }
.main { padding: 36px 40px 64px; max-width: 980px; width: 100%; min-width: 0; }
.main > header { display: flex; flex-wrap: wrap; gap: 12px; align-items: flex-end; justify-content: space-between; margin-bottom: 26px; }
.main > header h1 { font-size: 30px; font-weight: 800; }
.cols { display: grid; grid-template-columns: 1.6fr 1fr; gap: 20px; align-items: start; }
.cols > * { min-width: 0; }
.req { display: grid; grid-template-columns: 110px 1fr auto; gap: 16px; padding: 16px 0; border-top: 1px solid var(--line); align-items: start; }
.req.first { border-top: 0; }
.req .when b { display: block; }
.req .when span { font: 500 13px var(--font); color: var(--accent); }
.req .who-name { font-weight: 700; }
.req .acts { display: flex; gap: 8px; flex-wrap: wrap; justify-content: flex-end; }
.req form { display: inline; }
.list { list-style: none; margin: 12px 0 0; padding: 0; display: grid; gap: 8px; }
.list li { padding-left: 22px; position: relative; font-size: 15px; }
.list li::before { content: ""; position: absolute; left: 2px; top: 8px; width: 8px; height: 8px; border-radius: 50%; border: 2px solid var(--accent); }
.hours { width: 100%; border-collapse: collapse; margin: 12px 0 18px; }
.hours td { padding: 10px 0; border-top: 1px solid var(--line); }
.hours td:last-child { text-align: right; }
.swatch input[type=color] { width: 56px; height: 44px; border: 1px solid var(--line); border-radius: 10px; padding: 3px; background: var(--surface); }
.empty { padding: 28px; text-align: center; color: var(--muted); border: 1px dashed var(--line); border-radius: 12px; }
@media (max-width: 900px) {
  .shell { grid-template-columns: 1fr; }
  .side { flex-direction: row; flex-wrap: wrap; align-items: center; border-right: 0; border-bottom: 1px solid var(--line); }
  .side .brand { margin: 0 12px 0 4px; }
  .side span.item { display: none; }
  .side .who { margin: 0 0 0 auto; border: 0; padding: 0; display: flex; gap: 10px; align-items: center; }
  .side .who form { margin: 0; }
  .main { padding: 24px 16px 48px; }
  .cols { grid-template-columns: 1fr; }
  .req { grid-template-columns: 1fr; gap: 8px; }
  .req .acts { justify-content: flex-start; }
}

/* ---------- A practice's public page ---------- */
.site-head { background: var(--surface); border-bottom: 1px solid var(--line); padding: 48px 0 40px; }
.site-id { display: flex; gap: 24px; align-items: center; flex-wrap: wrap; }
.site-id h1 { font-size: clamp(30px, 4.4vw, 44px); font-weight: 800; }
.site-id h1 small { font-size: .5em; font-weight: 700; color: var(--muted); letter-spacing: 0; margin-left: 6px; }
.site-id .headline { font-size: 19px; color: var(--muted); margin-top: 8px; max-width: 620px; }
.site-body { display: grid; grid-template-columns: 1.3fr 1fr; gap: 28px; padding-top: 36px; padding-bottom: 64px; align-items: start; }
.site-body .bio { white-space: pre-line; color: color-mix(in srgb, var(--ink) 91%, var(--surface)); font-size: 17px; margin-top: 10px; }
.facts { display: grid; gap: 14px; margin-top: 12px; }
.facts div { display: flex; justify-content: space-between; gap: 16px; padding-top: 14px; border-top: 1px solid var(--line); }
.facts div:first-child { border-top: 0; padding-top: 0; }
.day { margin-top: 18px; }
.day h3 { font: 600 13px var(--font); color: var(--muted); letter-spacing: .04em; text-transform: uppercase; margin-bottom: 10px; }
.powered { text-align: center; padding: 24px; color: var(--muted); font-size: 13px; }
.powered a { color: var(--muted); font-weight: 700; }
.form-page { max-width: 640px; margin: 0 auto; padding: 40px 24px 64px; }
.form-page h1 { font-size: 30px; font-weight: 800; margin-bottom: 8px; }
@media (max-width: 860px) { .site-body { grid-template-columns: 1fr; } }

/* ---------- Booking widget (shown inside a practice's own website) ---------- */
body.embed { background: var(--surface); }
.embed .form-page { padding: 20px 18px 24px; max-width: none; }
.embed .form-page h1 { font-size: 24px; }
.embed .form-page .card { border: 0; padding: 0; }
.widget { padding: 20px 18px 16px; }
.widget-head { display: flex; gap: 14px; align-items: center; margin-bottom: 6px; }
.widget-head img, .widget-head .avatar { width: 52px; height: 52px; border-radius: 50%; object-fit: cover; flex: none; }
.widget-head h1 { font-size: 20px; }
.widget .day { margin-top: 14px; }
.widget .powered { padding: 18px 0 0; text-align: left; }
.snippet { width: 100%; min-height: 96px; font: 500 13px/1.5 var(--font); background: var(--ground); }

/* ---------- Widget month calendar ---------- */
.wbar { display: flex; flex-wrap: wrap; gap: 8px 14px; align-items: center; justify-content: space-between; margin: 16px 0 14px; }
.tabs { display: inline-flex; gap: 4px; padding: 4px; border-radius: 999px; background: var(--ground); }
.tabs a { display: inline-flex; align-items: center; min-height: 36px; padding: 0 16px; border-radius: 999px;
  font-weight: 700; font-size: 14px; color: var(--muted); text-decoration: none; }
.tabs a.on { background: var(--surface); color: var(--ink); box-shadow: 0 1px 2px rgba(22,33,31,.1); }
.wcal { display: grid; grid-template-columns: 1fr; gap: 20px; }
@media (min-width: 600px) { .wcal { grid-template-columns: minmax(0, 1.2fr) minmax(0, 1fr); align-items: start; } }
.month-head { display: flex; align-items: center; justify-content: space-between; margin-bottom: 6px; }
.month-head b { font-size: 16px; letter-spacing: -.01em; }
.month-nav { width: 40px; height: 40px; display: grid; place-items: center; border-radius: 50%; border: 1px solid var(--line);
  color: var(--ink); text-decoration: none; font-size: 22px; line-height: 1; }
a.month-nav:hover { background: var(--ground); }
.month-nav.off { color: var(--muted); pointer-events: none; text-decoration: none; }
.cal { width: 100%; border-collapse: separate; border-spacing: 3px; table-layout: fixed; }
.cal th { padding: 4px 0; font: 600 11px var(--font); color: var(--muted); text-align: center; }
.cal th abbr { text-decoration: none; }
.cal td { padding: 0; text-align: center; }
.cal .d { display: grid; place-items: center; height: 40px; border-radius: 10px; font-size: 15px; font-weight: 600;
  color: var(--muted); text-decoration: none; }
.cal .d.out { visibility: hidden; }
.cal .d.today { box-shadow: inset 0 0 0 1.5px var(--line); }
.cal a.d.open { background: var(--soft); color: var(--accent); font-weight: 800; }
.cal a.d.open:hover { box-shadow: inset 0 0 0 2px var(--accent); }
.cal a.d.sel { background: var(--accent); color: var(--accent-ink); }
.legend { margin-top: 8px; display: flex; align-items: center; gap: 8px; }
.legend i { width: 14px; height: 14px; border-radius: 4px; background: var(--soft); box-shadow: inset 0 0 0 1px color-mix(in srgb, var(--accent) 25%, transparent); }
.times h3 { font: 600 13px var(--font); color: var(--muted); letter-spacing: .04em; text-transform: uppercase; margin: 6px 0 10px; }
.times-grid { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 8px; }
.times-grid .slot { width: 100%; }

/* ---------- Practice themes: headings use the practice's heading font ---------- */
h1, h2, h3 { font-family: var(--head-font, var(--font)); }
.eyebrow, .day h3, .times h3, .cal th { font-family: var(--font); }
.ptop { background: var(--surface); border-bottom: 1px solid var(--line); }
.ptop .wrap { display: flex; align-items: center; justify-content: space-between; gap: 12px; min-height: 64px; flex-wrap: wrap; padding-top: 10px; padding-bottom: 10px; }
.plogo { display: inline-flex; align-items: center; gap: 10px; color: var(--ink); text-decoration: none; }
.plogo-img { display: block; max-width: 220px; object-fit: contain; }
.plogo-mark { display: inline-grid; place-items: center; border-radius: 50%; background: var(--accent); color: var(--accent-ink);
  font-family: var(--head-font, var(--font)); font-weight: 700; letter-spacing: .02em; flex: none; }
.plogo-mark.sq { border-radius: 28%; }
.plogo-name { font-family: var(--head-font, var(--font)); font-weight: 700; font-size: 17px; }
.plogo-name small { font-family: var(--font); font-weight: 600; color: var(--muted); font-size: 13px; margin-left: 6px; }
.plogo-word { font-family: var(--head-font, var(--font)); font-weight: 700; font-size: 22px; letter-spacing: -.01em; }
.pnav { display: flex; gap: 8px; flex-wrap: wrap; }

/* Marketing screenshots */
.shot { margin: 8px 0 0; }
.shot img { display: block; width: 100%; height: auto; border-radius: 16px; border: 1px solid var(--line); box-shadow: 0 18px 50px rgba(28, 36, 25, .14); background: var(--surface); }
.shot figcaption { margin-top: 12px; text-align: center; }
.prose { max-width: 760px; }
.prose h2 { font-size: clamp(22px, 2.6vw, 28px); font-weight: 800; margin: 40px 0 12px; }
.prose h3 { font-size: 19px; font-weight: 800; margin: 28px 0 8px; }
.prose p, .prose li { color: var(--muted); font-size: 17px; line-height: 1.6; }
.prose ul { padding-left: 20px; }
.prose li + li { margin-top: 8px; }
.trust .btn.ghost { color: #EEF3EA; border-color: rgba(255, 255, 255, .45); background: transparent; }
.trust .btn.ghost:hover { background: rgba(255, 255, 255, .1); }
.prose p + p { margin-top: 14px; }

/* Therapist sites: existing clients sign in here. */
.pnav .client-link { font-size: 14px; font-weight: 600; color: var(--accent); text-decoration: none; padding: 6px 4px; margin-left: 4px; }
.pnav .client-link:hover { text-decoration: underline; }

/* A clinician who is also the group administrator: switch between their own view and the Front desk view */
.viewswitch { display: grid; grid-template-columns: 1fr 1fr; gap: 4px; background: color-mix(in srgb, var(--ink) 7%, var(--surface)); border-radius: 12px; padding: 4px; margin: 4px 0 10px; }
.viewswitch button { font: 600 13px var(--font, system-ui, sans-serif); border: 0; background: transparent; color: color-mix(in srgb, var(--ink) 78%, var(--surface)); border-radius: 9px;
  padding: 9px 6px; min-height: 40px; cursor: pointer; }
.viewswitch button.on { background: var(--surface); color: var(--ink); box-shadow: 0 1px 4px rgba(0,0,0,.12); }
.shell.compact .viewswitch { grid-template-columns: 1fr; }

/* The plain-language coding picker (Claude Design artboards 5 and 6) */
.cpick { display: grid; gap: 14px; margin: 6px 0 14px; }
.cp-q { border: 0; margin: 0; padding: 0; display: grid; gap: 8px; min-width: 0; }
.cp-svc[hidden], [data-services][hidden], [data-svc-more][hidden] { display: none; }
/* "How many" and "Which ear", only on the lines that take them (audiology "each" items and one-ear codes). */
.cp-qty[hidden], .cp-ear[hidden] { display: none; }
.cp-svc { margin: 0; }
.cp-q > legend, .cp-q > label { font-weight: 600; font-size: 15px; margin-bottom: 6px; padding: 0; }
.cp-tiles { display: grid; gap: 8px; }
.cp-tiles.two { grid-template-columns: repeat(2, minmax(0, 1fr)); }
.cp-tiles.three { grid-template-columns: repeat(auto-fill, minmax(150px, 1fr)); }
.cp-tiles.four { grid-template-columns: repeat(auto-fill, minmax(170px, 1fr)); }
.cp-tiles.inline { display: flex; flex-wrap: wrap; }
.cp-tile { position: relative; cursor: pointer; }
.cp-tile input { position: absolute; opacity: 0; inset: 0; margin: 0; cursor: pointer; }
.cp-tile > span { display: flex; flex-direction: column; gap: 3px; min-height: 52px; box-sizing: border-box; padding: 12px 14px; border-radius: 14px;
  border: 1px solid var(--line); background: var(--surface); font-weight: 600; font-size: 15px; }
.cp-tile.sm > span { min-height: 44px; padding: 10px 14px; justify-content: center; }
.cp-tile small { font-weight: 400; font-size: 13px; color: var(--muted); }
.cp-tile input:checked + span { border: 2px solid var(--accent); background: color-mix(in srgb, var(--accent) 10%, var(--surface)); padding: 11px 13px; }
.cp-tile input:focus-visible + span { outline: 3px solid color-mix(in srgb, var(--accent) 45%, transparent); outline-offset: 2px; }
.cp-tile.off { cursor: not-allowed; }
.cp-tile.off > span { border-style: dashed; background: color-mix(in srgb, var(--ink) 6%, var(--surface)); color: var(--muted); }
.cp-tile.off small.cp-why { color: color-mix(in srgb, var(--warn) 71%, var(--ink)); }
.cp-row { display: grid; grid-template-columns: minmax(150px, 220px) 1fr; gap: 16px; align-items: start; }
.cp-min { font: 600 20px var(--font); padding: 10px 12px; max-width: 130px; }
.cp-chip-check { display: flex; gap: 10px; align-items: center; font-size: 15px; padding: 10px 14px; border: 1px dashed var(--info-line);
  border-radius: 16px; background: color-mix(in srgb, var(--info-line) 10%, var(--surface)); color: var(--info); width: fit-content; max-width: 100%; box-sizing: border-box; cursor: pointer; }
.cp-chip-check:has(small) { align-items: flex-start; }
.cp-chip-check input { width: 18px; height: 18px; margin: 0; flex: none; }
.cp-chip-check:has(small) input { margin-top: 2px; }
.cp-chip-check span { display: grid; gap: 2px; }
.cp-chip-check small { font-size: 12.5px; color: color-mix(in srgb, var(--info) 55%, var(--muted)); }
.cp-chips { display: flex; flex-wrap: wrap; gap: 8px; margin-top: 6px; }
.cp-chip { font: 500 15px var(--font); padding: 9px 14px; border-radius: 16px; border: 1px solid var(--info-line); background: color-mix(in srgb, var(--info-line) 10%, var(--surface)); color: var(--info);
  cursor: pointer; text-align: left; display: flex; flex-direction: column; gap: 2px; max-width: 360px; }
.cp-chip small { font-size: 12.5px; color: color-mix(in srgb, var(--info) 55%, var(--muted)); font-weight: 400; }
.cp-extras { display: grid; gap: 8px; }
.cp-extra { display: flex; gap: 12px; align-items: center; border: 1px solid var(--line); border-radius: 12px; padding: 10px 14px; background: var(--surface); }
.cp-extra .grow { flex: 1; }
.cp-extra.bad { border: 2px solid var(--warn-line); background: color-mix(in srgb, var(--warn-line) 10%, var(--surface)); }
.cp-search summary { cursor: pointer; font-weight: 600; color: var(--accent); min-height: 32px; }
.cp-search input { margin-top: 8px; width: 100%; max-width: 420px; }
.cp-results { display: grid; gap: 6px; margin-top: 8px; max-width: 520px; }
.cp-result-item { text-align: left; font: 600 15px var(--font); padding: 10px 14px; border: 1px solid var(--line); border-radius: 12px; background: var(--surface);
  cursor: pointer; display: flex; flex-direction: column; gap: 2px; }
.cp-result-item small { font-weight: 400; color: var(--muted); font-size: 13px; }
.cp-problems p { margin: 0 0 6px; padding: 10px 14px; border-radius: 12px; font-size: 14.5px; line-height: 1.45; }
.cp-block { background: color-mix(in srgb, var(--bad-line) 38%, var(--surface)); color: color-mix(in srgb, var(--danger) 74%, var(--ink)); }
.cp-warn { background: color-mix(in srgb, var(--warn-line) 15%, var(--surface)); color: color-mix(in srgb, var(--warn) 69%, var(--ink)); }
.cp-result { border: 2px solid var(--line); border-radius: 16px; padding: 16px 18px; display: grid; gap: 4px; background: var(--surface); }
.cp-result.ok { border-color: var(--accent); }
.cp-result .cp-k { font-size: 12px; font-weight: 700; letter-spacing: .05em; text-transform: uppercase; color: var(--muted); }
.cp-result b { font-size: 20px; line-height: 1.3; }
.cp-codes { font-size: 12.5px; color: var(--muted); }
button[data-record]:disabled { background: var(--soft); color: var(--muted); border: 1px dashed var(--line); cursor: not-allowed; }
@media (max-width: 640px) {
  .cp-tiles.three, .cp-tiles.four { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .cp-row { grid-template-columns: 1fr; }
}

/* Chart lists (Claude Design artboard 8) */
.chart-grid { display: grid; grid-template-columns: repeat(auto-fit, minmax(220px, 1fr)); gap: 16px; margin-top: 10px; }
.chart-col { display: grid; gap: 8px; align-content: start; }
.chart-col h3 { margin: 0; font-size: 16px; }
.chart-head { display: flex; align-items: center; gap: 8px; justify-content: space-between; }
.chart-item { display: grid; gap: 2px; border-left: 4px solid var(--accent); padding: 4px 10px; }
.chart-item span { font-size: 13px; color: var(--muted); }
.chart-item form { display: flex; gap: 10px; }
.chart-item.muted { border-left-color: var(--line); }
.chart-add summary { cursor: pointer; font-weight: 600; }
.chart-add form { margin-top: 8px; display: grid; gap: 8px; }
.allergen { color: var(--bad); }
.allergy-flag { background: var(--bad-soft); color: var(--bad); border-radius: 999px; padding: 6px 14px; font-weight: 700; font-size: 14px; }

/* Add interpreter (Claude Design artboard 9) */
.ip-dialog { border: 0; border-radius: 22px; padding: 24px; width: min(620px, calc(100vw - 32px)); box-shadow: 0 20px 60px rgba(0,0,0,.35); }
.ip-dialog::backdrop { background: rgba(20,28,24,.55); }
.ip-dialog h2 { margin: 2px 0 12px; }
.ip-close { position: absolute; right: 18px; top: 14px; }
.ip-steps { margin: 0; padding-left: 22px; display: grid; gap: 16px; }
.ip-steps li > b { display: block; margin-bottom: 6px; }
.ip-row { display: flex; flex-wrap: wrap; gap: 8px; }
.ip-grid { display: grid; grid-template-columns: repeat(auto-fit, minmax(130px, 1fr)); gap: 10px; }
.ip-grid label { display: grid; gap: 4px; font-size: 13px; color: var(--muted); }
.ip-ah { background: var(--warn-soft); color: var(--warn); border-radius: 12px; padding: 10px 14px; font-size: 14px; }
.ip-msg { min-height: 20px; color: var(--accent); font-weight: 600; margin: 8px 0; }
.ip-actions { display: flex; flex-wrap: wrap; gap: 10px; }
.ip-recent { margin: 12px 0 0; padding-left: 18px; }

/* Getting in-network (Claude Design artboard 10) */
.cred { display: grid; gap: 22px; max-width: 980px; }
.cred h2 { font-size: 18px; margin: 0 0 10px; }
.cred-next { display: flex; flex-wrap: wrap; gap: 16px; align-items: center; background: var(--surface); border: 2px solid var(--accent); border-radius: 20px; padding: 20px 22px; }
.cred-next.bad { border-color: var(--bad); background: var(--bad-soft); }
.cred-next.calm { border-color: var(--line); }
.cred-next .grow { flex: 1 1 340px; }
.cred-next p { margin: 0; font-size: 16px; }
.cred-actions { display: flex; flex-wrap: wrap; gap: 10px; align-items: center; }
.cred-sec { display: grid; gap: 10px; }
.cred-app { background: var(--surface); border: 1px solid var(--line); border-radius: 16px; padding: 14px 18px; }
.cred-app.warn { border: 2px solid var(--warn-line); }
.cred-app.closed { opacity: .7; }
.cred-app-row { display: grid; grid-template-columns: minmax(150px, 220px) 1fr auto; gap: 16px; align-items: center; }
.cred-payer { font-size: 16px; }
.cred-bar { display: grid; grid-template-columns: repeat(5, minmax(0, 1fr)); gap: 6px; }
.cred-bar span { height: 10px; border-radius: 6px; background: color-mix(in srgb, var(--ink) 21%, var(--surface)); }
.cred-bar span.on { background: var(--accent); }
.cred-when { font-size: 14px; color: var(--muted); }
.cred-when b { color: color-mix(in srgb, var(--warn) 93%, var(--ink)); }
.cred-more { margin-top: 8px; }
.cred-more > summary { cursor: pointer; font-weight: 600; color: var(--accent); min-height: 28px; }
.cred-log, .cred-form { display: grid; grid-template-columns: repeat(auto-fit, minmax(200px, 1fr)); gap: 10px; margin-top: 10px; align-items: end; }
.cred-log label, .cred-form label { display: grid; gap: 4px; font-size: 13px; color: var(--muted); }
.cred-form label.check { display: flex; gap: 8px; align-items: center; font-size: 15px; color: var(--ink); }
.cred-contacts { margin: 8px 0 0; padding-left: 18px; }
.cred-cards { display: grid; grid-template-columns: repeat(auto-fill, minmax(190px, 1fr)); gap: 12px; }
.cred-card { background: var(--surface); border: 1px solid var(--line); border-radius: 14px; padding: 14px; display: grid; gap: 4px; }
.cred-card small { color: var(--muted); font-size: 13px; }
.cred-state { font-size: 13px; font-weight: 700; }
.cred-card.ok .cred-state { color: var(--accent); }
.cred-card.missing { border: 2px solid var(--warn-line); }
.cred-card.missing .cred-state, .cred-card.soon .cred-state { color: color-mix(in srgb, var(--warn) 93%, var(--ink)); }
.cred-card.bad { border: 2px solid var(--bad); }
.cred-card.bad .cred-state { color: var(--bad); }
.cred-card.na { opacity: .75; }
.cred-card.na .cred-state { color: var(--muted); }
/* A rule's or number's source: small and quiet, never a banner. */
.src-link { font-size: 12px; color: var(--muted); text-decoration: underline; text-decoration-color: color-mix(in srgb, var(--muted) 45%, transparent); }
.src-link:hover { color: var(--ink); }
/* On a tinted notice or a coding-picker reason, the link takes that text's color (muted gray on a tint can
   drop under 4.5:1 at night); it stays quiet by its size and light underline. */
.notice .src-link, .cp-block .src-link, .cp-warn .src-link, .bad .src-link { color: inherit; }
.cred-also { margin: 8px 0 0; padding-left: 18px; font-size: 14px; }
.cred-also li { margin: 2px 0; }
.cred-strip { background: var(--surface); border: 1px solid var(--line); border-radius: 16px; padding: 14px 18px; display: flex; flex-wrap: wrap; gap: 18px; align-items: center; font-size: 14px; }
.cred-strip b.ok { color: var(--accent); }
.cred-strip b.bad { color: var(--bad); }
.bfilter { display: flex; flex-wrap: wrap; gap: 8px; }
.bfilter a { padding: 8px 14px; border-radius: 999px; border: 1px solid var(--line); background: var(--surface); color: var(--ink); text-decoration: none; font-size: 14px; }
.bfilter a.on { background: var(--accent); color: var(--accent-ink); border-color: var(--accent); }
@media (max-width: 640px) { .cred-app-row { grid-template-columns: 1fr; gap: 8px; } }

.cred-med { display: grid; gap: 4px; border-radius: 14px; padding: 14px 16px; border: 1px solid var(--line); background: var(--surface); }
.cred-med.ok { border: 2px solid var(--accent); }
.cred-med.no { background: var(--warn-soft); }
.cred-med-steps { margin: 6px 0 0; padding-left: 20px; display: grid; gap: 10px; }
.cred-plans { list-style: none; padding: 0; margin: 8px 0 0; display: grid; gap: 8px; }
.cred-plans li { display: flex; flex-wrap: wrap; gap: 10px; align-items: center; background: var(--surface); border: 1px solid var(--line); border-radius: 12px; padding: 10px 14px; }
.cred-plans li > span:first-child { flex: 1 1 220px; }

/* Applying to one insurer (Claude Design artboard 11) */
.kit-steps { display: grid; grid-template-columns: repeat(auto-fit, minmax(180px, 1fr)); gap: 10px; }
.kit-steps .btn, .kit-steps form .btn { justify-content: center; text-align: center; }
.kit-card { background: var(--surface); border: 1px solid var(--line); border-radius: 18px; padding: 18px 20px; display: grid; gap: 6px; }
.kit-card h2 { margin: 0 0 6px; font-size: 17px; }
.kit-row { display: grid; grid-template-columns: minmax(140px, 220px) 1fr auto; gap: 10px; align-items: center; padding: 8px 0; border-bottom: 1px solid var(--line); }
.kit-row span { color: var(--muted); font-size: 14px; }
.kit-row b { white-space: pre-line; word-break: break-word; }
.kit-body { white-space: pre-wrap; background: var(--ground); border-radius: 12px; padding: 14px; font: 14px/1.55 var(--font); margin: 6px 0 10px; }
.kit-packet { display: flex; flex-wrap: wrap; gap: 14px; align-items: center; justify-content: space-between; }
.kit-link { margin-top: 10px; }
@media (max-width: 640px) { .kit-row { grid-template-columns: 1fr auto; } .kit-row span { grid-column: 1 / -1; } }

.kit-list { margin: 4px 0 0; padding-left: 22px; display: grid; gap: 6px; font-size: 15px; }

/* Guided credentialing setup (Claude Design artboard 13) */
.wiz { max-width: 640px; display: grid; gap: 18px; }
.wiz-top { display: grid; gap: 8px; }
.wiz-bar { display: grid; grid-template-columns: repeat(9, minmax(0, 1fr)); gap: 4px; }
.wiz-bar a { height: 8px; border-radius: 4px; background: color-mix(in srgb, var(--ink) 18%, var(--surface)); display: block; }
.wiz-bar a.on { background: var(--accent); }
.wiz-card { background: var(--surface); border: 1px solid var(--line); border-radius: 20px; padding: 24px; display: grid; gap: 14px; }
.wiz-card h1 { margin: 0; font-size: 26px; }
.wiz-card p { margin: 0; }
.wiz-field { display: grid; gap: 6px; font-weight: 600; }
.wiz-field input, .wiz-field select, .wiz-field textarea { font: 17px var(--font); padding: 11px 13px; border: 1px solid var(--line); border-radius: 12px; }
.wiz-found { border-radius: 12px; padding: 12px 14px; background: var(--soft); }
.wiz-found.bad { background: var(--warn-soft); color: var(--warn); }
.wiz-doc { border: 1px dashed var(--line); border-radius: 12px; padding: 10px 14px; }
.wiz-rows { display: grid; gap: 8px; }
.wiz-row { display: grid; grid-template-columns: 2fr 1.4fr 1.2fr 70px 1fr 1fr; gap: 6px; }
.wiz-row.refs { grid-template-columns: 1.4fr 1.4fr 1fr 1.4fr; }
.wiz-row input, .wiz-row select { font: 15px var(--font); padding: 8px 9px; border: 1px solid var(--line); border-radius: 10px; min-width: 0; }
.wiz-row.head span { padding-left: 2px; }
.wiz-row[hidden] { display: none; }
.wiz-gap { border: 1px solid color-mix(in srgb, var(--warn-line) 77%, var(--surface)); background: color-mix(in srgb, var(--warn-line) 14%, var(--surface)); border-radius: 12px; padding: 10px 14px; }
@media (max-width: 720px) { .wiz-row, .wiz-row.refs { grid-template-columns: 1fr 1fr; } .wiz-row.head { display: none; } }
.wiz-doc.ok { border-style: solid; border-color: var(--accent); }
.wiz-review { list-style: none; padding: 0; margin: 0; display: grid; gap: 8px; }
.wiz-review li { border-left: 4px solid var(--warn-line); padding: 4px 10px; }
.wiz-review li.ok { border-left-color: var(--accent); }
.wiz-nav { display: flex; justify-content: space-between; align-items: center; gap: 12px; margin-top: 6px; }
.cred-guide { display: flex; flex-wrap: wrap; gap: 10px; align-items: center; background: var(--soft); border-radius: 16px; padding: 14px 18px; text-decoration: none; color: var(--ink); }
.cred-guide span:nth-child(2) { flex: 1 1 260px; color: var(--muted); }
.cred-guide .bcta { font-weight: 700; color: var(--accent); }
.sr { position: absolute; width: 1px; height: 1px; overflow: hidden; clip: rect(0 0 0 0); }

.assoc-form { display: grid; gap: 8px; border-top: 1px solid var(--line); padding-top: 10px; }
.assoc-form label { display: grid; gap: 3px; }
.supv-bar { height: 10px; background: color-mix(in srgb, var(--ink) 12%, var(--surface)); border-radius: 6px; overflow: hidden; }
.supv-bar span { display: block; height: 100%; background: var(--accent); border-radius: 6px; }
.supv-bar.low span { background: var(--warn-line); }
.assoc-bill { border-radius: 14px; padding: 12px 14px; display: grid; gap: 6px; border: 2px solid var(--accent); background: var(--surface); }
.assoc-bill.warn { border-color: var(--warn-line); background: color-mix(in srgb, var(--warn-line) 10%, var(--surface)); }
.assoc-bill .seg { margin-top: 4px; }

.text-ok small { display: block; color: var(--muted); font-size: 13.5px; margin-top: 2px; }

.ins-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(230px, 1fr)); gap: 6px 14px; margin-top: 8px; max-height: 320px; overflow: auto; }

.wiz-choice { display: grid; gap: 10px; }
.wiz-choice .mode-card { display: grid; gap: 4px; border: 1px solid var(--line); border-radius: 14px; padding: 12px 14px 12px 40px; position: relative; cursor: pointer; background: var(--surface); }
.wiz-choice .mode-card input { position: absolute; left: 14px; top: 15px; width: 18px; height: 18px; accent-color: var(--accent); }
.wiz-choice .mode-card:has(input:checked) { border: 2px solid var(--accent); padding: 11px 13px 11px 39px; background: var(--soft, color-mix(in srgb, var(--ink) 6%, var(--surface))); }

/* Practice setup (artboards 22-25) */
.setup { display: grid; grid-template-columns: 270px minmax(0, 1fr); gap: 24px; align-items: start; }
.setup-side { background: var(--surface); border: 1px solid var(--line); border-radius: 18px; padding: 16px; display: flex; flex-direction: column; gap: 3px; position: sticky; top: 16px; }
.setup-group { font-size: 12px; font-weight: 600; color: var(--muted); letter-spacing: .04em; text-transform: uppercase; margin: 12px 0 2px; }
.setup-step { padding: 7px 10px; border-radius: 10px; color: var(--ink); text-decoration: none; }
.setup-step.done { color: var(--accent); }
.setup-step.on { background: var(--soft); font-weight: 600; }
.setup-meter { height: 8px; background: color-mix(in srgb, var(--ink) 12%, var(--surface)); border-radius: 99px; overflow: hidden; margin: 6px 0; }
.setup-meter span { display: block; height: 100%; background: var(--accent); }
.setup-main { display: grid; gap: 16px; min-width: 0; }
.setup-form { display: grid; gap: 16px; }
.setup-head { display: flex; justify-content: space-between; align-items: start; gap: 12px; }
.setup-head h1 { margin: 2px 0 0; font-size: 30px; }
.setup-head p { margin: 0; }
.setup-choices { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 12px; }
.setup-choices.two { grid-template-columns: repeat(2, minmax(0, 1fr)); }
.setup-choice { background: var(--surface); border: 1px solid var(--line); border-radius: 16px; padding: 16px; display: grid; gap: 4px; cursor: pointer; position: relative; }
.setup-choice input { position: absolute; opacity: 0; }
.setup-choice:has(input:checked) { border: 2px solid var(--accent); background: var(--soft); padding: 15px; }
.setup-choice:has(input:checked) b::before { content: "✓ "; }
.setup-choice:has(input:focus-visible) { outline: 3px solid var(--accent); outline-offset: 2px; }
.setup-office { border: 0; padding: 0; margin: 0; display: grid; gap: 10px; }
.setup-office[hidden], .wiz-card[hidden] { display: none; }
.setup-addr { display: grid; grid-template-columns: 2fr 1.2fr 80px 110px; gap: 10px; }
.setup-two { display: grid; grid-template-columns: 1fr 1fr; gap: 12px; }
.setup-fee { display: grid; grid-template-columns: minmax(0, 1fr) 80px 170px; gap: 12px; align-items: center; padding: 8px 0; border-top: 1px solid color-mix(in srgb, var(--ink) 7%, var(--surface)); }
.setup-fee.head { border-top: 0; padding-bottom: 0; }
.setup-money { display: flex; align-items: center; gap: 6px; }
.setup-money input { width: 90px; font: 16px var(--font); padding: 8px 10px; border: 1px solid var(--line); border-radius: 10px; }
.setup-money.example input { border-color: color-mix(in srgb, var(--warn-line) 77%, var(--surface)); background: color-mix(in srgb, var(--warn-line) 14%, var(--surface)); }
.setup-money em { font-style: normal; font-size: 12px; color: color-mix(in srgb, var(--warn) 94%, var(--surface)); }
.setup-payers { display: grid; grid-template-columns: repeat(auto-fill, minmax(220px, 1fr)); gap: 6px 14px; max-height: 320px; overflow: auto; }
.setup-days { border: 0; padding: 0; margin: 0; display: flex; flex-wrap: wrap; gap: 6px 14px; }
.setup-nav { display: flex; justify-content: space-between; align-items: center; gap: 12px; }
.setup-go { display: flex; gap: 12px; align-items: center; flex-wrap: wrap; justify-content: flex-end; }
.setup-card { border: 2px solid var(--accent); }
.setup-card-top { display: flex; justify-content: space-between; align-items: center; gap: 14px; }
.setup-chips { display: flex; flex-wrap: wrap; gap: 8px; }
.setup-chip { border: 1px solid var(--line); border-radius: 99px; padding: 5px 11px; font-size: 14px; color: var(--muted); text-decoration: none; }
@media (max-width: 860px) {
  .setup { grid-template-columns: 1fr; } .setup-side { position: static; }
  .setup-choices, .setup-choices.two, .setup-addr, .setup-two { grid-template-columns: 1fr; }
  .setup-fee { grid-template-columns: 1fr 120px; } .setup-fee > span:nth-child(2) { display: none; }
  .setup-card-top { flex-direction: column; align-items: stretch; }
}
.setup .wiz-field input, .setup .wiz-field select, .setup .wiz-field textarea { min-width: 0; width: 100%; box-sizing: border-box; }
.setup-addr > *, .setup-two > *, .setup-choices > * { min-width: 0; }
.setup-choice span { font-weight: 400; }
.setup-nav > a, .setup-go .btn { white-space: nowrap; }

/* One claim (practice side): what the checker found, and the claim form's boxes */
.claim-findings h2 { display: flex; align-items: center; gap: 8px; }
.claim-findings h2 + .claim-list { margin-bottom: 18px; }
.claim-list { list-style: none; margin: 10px 0 0; padding: 0; display: grid; gap: 12px; }
.claim-list > li { display: flex; gap: 14px; align-items: flex-start; justify-content: space-between;
  padding: 12px 0; border-top: 1px solid var(--line, color-mix(in srgb, var(--ink) 12%, var(--surface))); }
.claim-list .grow { flex: 1; min-width: 0; }
.claim-pair { display: flex; flex-wrap: wrap; gap: 6px 22px; margin: 6px 0; }
.claim-pair small { display: block; font-size: 12px; color: var(--muted, color-mix(in srgb, var(--ink) 68%, var(--surface))); }
.claim-boxes th { width: 38%; font-weight: 500; text-align: left; }
.claim-boxes .dx { white-space: nowrap; }
@media (max-width: 640px) { .claim-list > li { flex-direction: column; } }

/* Help pages, urgent messages and "worried about your provider" (ph/help_safety.py) */
.hs-crisis { border: 2px solid var(--bad); background: var(--bad-soft); }
.hs-crisis h2 { color: var(--bad); margin-top: 0; }
.hs-crisis .hs-calls { display: flex; flex-wrap: wrap; gap: 10px; margin: 12px 0 4px; }
.hs-list { margin: 8px 0 0; padding-left: 20px; }
.hs-list li { margin: 6px 0; }
.hs-providers { list-style: none; padding: 0; margin: 10px 0 0; }
.hs-providers li { padding: 10px 0; border-bottom: 1px solid var(--line, color-mix(in srgb, var(--ink) 12%, var(--surface))); }
.hs-mail { display: flex; flex-wrap: wrap; gap: 10px; margin: 12px 0; }
.urgent-ack { display: none; margin: 8px 0 0; padding: 12px 14px; border-radius: 10px; background: var(--warn-soft); color: var(--warn); }
#urgent:checked ~ .urgent-ack, .field:has(> .check #urgent:checked) > .urgent-ack { display: block; }
.js-urgent .urgent-ack { display: none !important; }
.urgent-dialog { border: 0; border-radius: 18px; padding: 22px; width: min(480px, calc(100vw - 32px)); max-height: calc(100dvh - 32px); overflow-y: auto; box-shadow: 0 20px 60px rgba(0,0,0,.35); }
.urgent-dialog::backdrop { background: rgba(20,28,24,.55); }
.urgent-dialog .row { display: flex; flex-wrap: wrap; gap: 10px; margin-top: 16px; }
.cp-msg.urgent, .msg-urgent { border-left: 4px solid var(--bad); }

.hs-checked { background: var(--soft, color-mix(in srgb, var(--ink) 7%, var(--surface))); border-radius: 10px; padding: 10px 12px; margin: 8px 0 12px; }

/* ===== Portal usability pass: My profile tabs, Calendar settings sections, My website (boards 1, 2, 6) ===== */
.ux-h1 { margin-top: 10px; }
.ux-lede { margin-top: 6px; }
.ux-sub { margin: 6px 0 14px; }
.ux-block { display: block; }
.ux-gap { margin-top: 12px; }
.ux-gap-sm { margin-top: 8px; }
.ux-grow { flex: 1; min-width: 0; margin-bottom: 0; }
.ux-narrow { max-width: 760px; }
.ux-narrow > .card + .card, .ux-narrow > .card + section.card { margin-top: 20px; }
.ux-actions { display: flex; flex-wrap: wrap; gap: 10px; margin-top: 16px; }
.ux-foot { margin-top: 16px; }
.ux-head-btns { display: flex; gap: 8px; flex-wrap: wrap; }
.ux-sec h3.sub { font-size: 15px; margin: 20px 0 10px; }
.ux-sec h2 + h3.sub { margin-top: 12px; }

/* Tabs: links, so each tab is its own page (works without JavaScript); one row that scrolls on a phone */
.ux-tabs { display: flex; gap: 4px; padding: 4px; margin-bottom: 20px; border-radius: 999px; background: color-mix(in srgb, var(--ink) 11%, var(--surface));
  width: fit-content; max-width: 100%; overflow-x: auto; scrollbar-width: none; }
.ux-tabs::-webkit-scrollbar { display: none; }
.ux-tabs a { flex: none; display: inline-flex; align-items: center; min-height: 40px; padding: 0 16px; border-radius: 999px;
  font-weight: 700; font-size: 14px; color: color-mix(in srgb, var(--ink) 80%, var(--surface)); text-decoration: none; white-space: nowrap; }
.ux-tabs a:hover { color: var(--ink); }
.ux-tabs a.on { background: var(--surface); color: var(--ink); box-shadow: 0 1px 2px rgba(22,33,31,.12); }

/* My profile */
.ux-narrow input:not([type]), .ux-narrow input[type=url], .ux-narrow input[type=search], .ux-sec input[type=url] {
  width: 100%; min-height: 44px; padding: 10px 12px; border: 1px solid var(--line); border-radius: 10px; background: var(--surface);
  color: var(--ink); font: 500 15px/1.4 var(--font); }
.ux-photo { margin: 14px 0 18px; align-items: flex-start; }
.ux-photo .link-btn { margin-top: 6px; }
.ux-switches { display: grid; gap: 14px; margin-top: 4px; }
.ux-states { margin-bottom: 10px; }
.ux-list { margin: 0 0 4px; padding-left: 18px; display: grid; gap: 4px; }
.ux-fieldset { border: 0; padding: 0; margin: 14px 0 0; min-width: 0; }
.ux-fieldset legend { padding: 0; }
.ux-picked { display: grid; grid-template-columns: repeat(auto-fill, minmax(230px, 1fr)); gap: 6px 14px; margin: 4px 0 10px; }
.ux-ins-all { margin-top: 12px; border: 1px solid var(--line); border-radius: 12px; padding: 0 14px; background: var(--ground); }
.ux-ins-all > summary { cursor: pointer; min-height: 48px; display: flex; align-items: center; gap: 6px; flex-wrap: wrap; }
.ux-ins-all[open] { padding-bottom: 14px; }
.ux-ins-all .ins-grid { background: var(--surface); border: 1px solid var(--line); border-radius: 10px; padding: 10px 12px; }
.ins-grid label[hidden] { display: none; }
.ux-ins-search { display: none; margin: 4px 0 10px; }
.ux-js .ux-ins-search { display: block; }
.ux-yearrow { grid-template-columns: minmax(0, 1fr) minmax(0, 1fr) 110px; }
.ux-year { max-width: 110px; }
.ux-fieldset > .ux-yearrow + .ux-yearrow, .ux-pub + .ux-pub { border-top: 1px dashed var(--line); padding-top: 14px; }

/* Calendar settings: jump links, sections, one sticky Save */
.ux-who { margin-bottom: 20px; display: flex; gap: 8px; flex-wrap: wrap; align-items: center; }
.ux-jump { position: sticky; top: var(--ea-stick, 0px); z-index: 6; display: flex; gap: 6px; flex-wrap: nowrap; overflow-x: auto; scrollbar-width: none;
  margin: 0 0 16px; padding: 8px 0; background: var(--ground); }
.ux-jump::-webkit-scrollbar { display: none; }
.ux-jump a { flex: none; display: inline-flex; align-items: center; min-height: 40px; padding: 0 16px; border-radius: 999px;
  border: 1px solid var(--line); background: var(--surface); font-weight: 700; font-size: 14px; color: var(--ink); text-decoration: none; }
.ux-jump a:hover { background: var(--soft); }
.ux-sec { scroll-margin-top: calc(72px + var(--ea-stick, 0px)); }
.ux-inline { display: grid; grid-template-columns: minmax(0, 1fr) auto; gap: 12px; align-items: end; }
.ux-inline .field { margin-bottom: 0; }
.ux-zone { margin: 8px 0 4px; }
.ux-presets { margin-top: 18px; }
.ux-presets h3.sub { margin: 0; }
.ux-subform { margin-top: 22px; padding-top: 6px; border-top: 1px solid var(--line); }
.ux-nojs-save { margin-top: 14px; }
.ux-js .ux-nojs-save { display: none; }
.ux-savebar[hidden] { display: none; }
.ux-savebar { flex-wrap: wrap; }
.ux-savebar [data-savebar-msg] { font-weight: 700; }
.ux-savebar-btns { display: flex; gap: 8px; margin-left: auto; }
.sched-toggle { margin-bottom: 4px; }

/* My website: a preview first, sections that open, Advanced last */
.ux-preview-head { display: flex; flex-wrap: wrap; gap: 8px 12px; align-items: center; justify-content: space-between; }
.ux-pills { display: flex; flex-wrap: wrap; gap: 6px; }
.ux-host { margin: 4px 0 14px; overflow-wrap: anywhere; }
.ux-mock { border: 1px solid var(--line); border-radius: 14px; background: var(--ground); padding: 18px; display: grid; gap: 14px; }
.ux-mock-who { display: flex; gap: 14px; align-items: center; min-width: 0; }
.ux-mock-who > div { min-width: 0; display: grid; gap: 2px; }
.ux-mock-who img.avatar { object-fit: cover; }
.ux-mock-name { font-size: 18px; }
.ux-mock-book { padding-top: 12px; border-top: 1px solid var(--line); }
.ux-preview-foot { display: flex; flex-wrap: wrap; gap: 10px 16px; align-items: center; justify-content: space-between; margin-top: 14px;
  padding: 12px 14px; border-radius: 12px; background: var(--warn-soft); color: var(--warn); }
.ux-preview-foot p { flex: 1 1 260px; }
details.openable.ux-sec > summary::after, details.openable.ux-sec[open] > summary::after { content: none; }
.ux-sec > summary > span:first-child { min-width: 0; grid-template-columns: minmax(0, 1fr); overflow-wrap: anywhere; }
.ux-act { flex: none; display: inline-flex; align-items: center; min-height: 36px; padding: 0 14px; border-radius: 999px;
  border: 1px solid var(--line); background: var(--surface); color: var(--accent); font-weight: 700; font-size: 14px; }
details.openable.ux-sec[open] > summary .ux-act { font-size: 0; }
details.openable.ux-sec[open] > summary .ux-act::after { content: "Close"; font-size: 14px; }
.ux-row { display: flex; flex-wrap: wrap; gap: 10px 16px; align-items: center; justify-content: space-between; }
.ux-row > span { flex: 1 1 260px; display: grid; gap: 4px; }
.ux-thumb { width: 72px; height: 72px; object-fit: cover; border-radius: 14px; border: 1px solid var(--line); }
.ux-thumb.round { border-radius: 50%; }
.ux-linkrow { grid-template-columns: minmax(0, 1fr) minmax(0, 2fr); }
.ux-adv-h { font-size: 15px; letter-spacing: .1em; text-transform: uppercase; color: var(--muted); margin: 32px 0 12px; }
.ux-adv-h + .card { margin-top: 0; }

@media (max-width: 640px) {
  .ux-tabs { border-radius: 14px; width: 100%; }
  .ux-yearrow { grid-template-columns: minmax(0, 1fr) 96px; }
  .ux-yearrow > .field:first-child { grid-column: 1 / -1; }
  .ux-linkrow { grid-template-columns: 1fr; }
  .ux-inline { grid-template-columns: 1fr; }
  .ux-savebar-btns { margin-left: 0; width: 100%; }
  .ux-savebar-btns .btn { flex: 1; }
  .ux-photo { flex-direction: column; }
  .ux-mock-who { align-items: flex-start; }
  .ux-mock-who .avatar.lg { width: 64px; height: 64px; font-size: 24px; }
}
@media (max-width: 900px) {   /* below the portal menu, which sticks to the top on phones */
  .ux-jump { top: 69px; }
  .ux-sec { scroll-margin-top: calc(136px + var(--ea-stick, 0px)); }
}
/* ===== end portal usability pass (boards 1, 2, 6) ===== */

/* ==========================================================================
   Portal usability pass: Messages, Billing, Billing settings + Team, coding picker
   (Claude Design artboards 7-10). Classes start with ub- or cp-.
   ========================================================================== */
/* Page head with a plain link on the right (Messages: Archived) */
.main > header.ub-head { align-items: center; }
.ub-headlink { font-weight: 700; padding: 10px 0; }
/* Tabs with counts */
.ub-tabs { display: flex; flex-wrap: wrap; width: fit-content; max-width: 100%; margin: 0 0 14px; }
.ub-tabs a { gap: 8px; min-height: 40px; font-weight: 700; font-size: 14px; }
.ub-tabs .n { display: inline-grid; place-items: center; min-width: 22px; height: 22px; padding: 0 6px; border-radius: 999px;
  background: color-mix(in srgb, var(--ink) 18%, var(--surface)); color: var(--ink); font-size: 12px; }
.ub-tabs a.on .n { background: var(--accent); color: var(--accent-ink); }
.ub-tabs a.ub-alert .n { background: var(--bad); color: var(--surface); }
* + .ub-tabs { margin-top: 20px; }
/* Rows: message threads and claims */
.ub-rows { list-style: none; margin: 0; padding: 0; }
.ub-rows > li { border-top: 1px solid color-mix(in srgb, var(--ink) 7%, var(--surface)); padding: 14px 0; }
.ub-rows > li:first-child { border-top: 0; padding-top: 0; }
.ub-rows > li:last-child { padding-bottom: 0; }
.ub-grow { flex: 1; min-width: 0; }
.ub-sub { display: block; margin-top: 2px; }
.ub-th { display: grid; grid-template-columns: 44px minmax(0, 1fr) auto auto; gap: 14px; align-items: center; }
.ub-th.msg-urgent { padding-left: 10px; }
.ub-av { width: 44px; height: 44px; border-radius: 50%; background: var(--soft); color: var(--accent); display: grid; place-items: center; font-weight: 800; }
.ub-name { font-weight: 700; color: var(--ink); text-decoration: none; }
.ub-name:hover { text-decoration: underline; }
.ub-dot { display: inline-block; width: 10px; height: 10px; border-radius: 50%; background: var(--accent); margin-right: 6px; }
.ub-foot { margin-top: 14px; }
.ub-alerts { margin-top: 10px; }
.ub-alerts > summary { cursor: pointer; list-style: none; min-height: 32px; padding: 4px 0; }
.ub-alerts > summary::-webkit-details-marker { display: none; }
.ub-change { color: var(--accent); font-weight: 700; font-size: 14px; text-decoration: underline; }
.ub-alerts[open] .ub-change { display: none; }
.ub-alerts-form { margin-top: 10px; max-width: 560px; }
/* Billing: claims */
.ub-claim { display: flex; gap: 14px; align-items: center; justify-content: space-between; }
.ub-claim .ub-grow > a[href^="/app/clients/"] { font-weight: 700; color: var(--ink); }
.ub-why { display: grid; gap: 4px; margin-top: 6px; }
.ub-why:empty { display: none; }
.ub-why > span { padding: 8px 12px; border-radius: 10px; background: var(--bad-soft); color: color-mix(in srgb, var(--danger) 65%, var(--ink)); font-size: 14px; }
.ub-claim .claim-form { display: flex; flex-wrap: wrap; gap: 8px; align-items: center; justify-content: flex-end; }
.ub-acts { display: flex; flex-wrap: wrap; gap: 8px; justify-content: flex-end; }
.ub-subhead { font-size: 15px; margin: 22px 0 10px; }
.ub-ready { display: flex; gap: 12px; align-items: center; justify-content: space-between; }
.ub-ready .ub-sub { font-weight: 500; }
.ub-ready-many { display: block; }
.ub-ready-many > summary { display: flex; gap: 12px; align-items: center; justify-content: space-between; cursor: pointer; list-style: none; }
.ub-ready-many > summary::-webkit-details-marker, .ub-fold > summary::-webkit-details-marker { display: none; }
.ub-ready-many[open] .ub-see, .ub-fold[open] .ub-see { display: none; }
.ub-ready-many .ub-rows { margin-top: 12px; background: var(--surface); border-radius: 10px; padding: 12px 14px; font-weight: 500; }
.ub-fold { padding: 16px 22px; }
.ub-fold > summary { display: flex; gap: 12px; align-items: center; justify-content: space-between; cursor: pointer; list-style: none; min-height: 36px; }
.ub-fold[open] > summary { margin-bottom: 12px; }
.ub-see { pointer-events: none; }
/* Folding sections + one sticky Save (Billing settings, Team) */
.ub-secs { display: grid; gap: 16px; }
.main > .ub-secs { margin-top: 20px; }
.ub-sec { background: var(--surface); border: 1px solid var(--line); border-radius: var(--radius); min-width: 0; }
.ub-sec-h { display: flex; align-items: center; justify-content: space-between; gap: 12px; padding: 16px 20px; min-height: 64px; cursor: pointer; list-style: none; }
.ub-sec-h::-webkit-details-marker { display: none; }
.ub-sec-h b { font-size: 17px; letter-spacing: -.01em; }
.ub-sec-h:focus-visible { border-radius: var(--radius); }
.ub-sec .ub-chev { width: 20px; height: 20px; color: var(--muted); flex: none; transition: transform .15s; }
.ub-sec[open] > .ub-sec-h .ub-chev { transform: rotate(180deg); }
.ub-sec-b { border-top: 1px solid color-mix(in srgb, var(--ink) 7%, var(--surface)); padding: 18px 20px 20px; display: grid; gap: 14px; min-width: 0; }
.ub-sec-b > .field, .ub-sec-b .row > .field { margin-bottom: 0; }
.ub-sec-b > .notice { margin-bottom: 0; }
.ub-sec-open .ub-sec-h { cursor: default; }
.ub-more > summary { cursor: pointer; font-weight: 600; color: var(--accent); min-height: 36px; display: flex; align-items: center; }
.ub-more[open] > summary { margin-bottom: 10px; }
.ub-more[hidden] { display: none; }
.ub-savebar { position: sticky; bottom: 0; z-index: 6; display: flex; flex-wrap: wrap; align-items: center; justify-content: space-between; gap: 10px 12px;
  margin: 24px 0 0; padding: 12px 20px; background: var(--surface); border: 1px solid var(--line); border-radius: 14px;
  box-shadow: 0 -6px 20px rgba(22,33,31,.06); }
.ub-savebar.dirty { border-color: var(--accent); }
.ub-savebar-acts { display: flex; gap: 10px; }
/* Coding picker: the live "Bills as" line beside the choices */
.cp-lgrid { display: grid; gap: 16px; min-width: 0; }
.cp-qs { display: grid; gap: 14px; min-width: 0; }
.cpick { container-type: inline-size; }
.cp-live { border: 2px solid var(--line); border-radius: 16px; padding: 14px 18px; display: grid; gap: 4px; background: var(--surface); }
.cp-live.ok { border-color: var(--accent); }
.cp-live[hidden] { display: none; }
.cp-live .cp-k { font-size: 12px; font-weight: 700; letter-spacing: .05em; text-transform: uppercase; color: var(--muted); }
.cp-live b { font-size: 24px; line-height: 1.2; letter-spacing: -.01em; }
.cp-chip-check.off { color: var(--muted); border-style: dashed; cursor: not-allowed; }
.cp-cx-note { margin: -6px 0 0; padding: 10px 14px; border-radius: 12px; font-size: 14px; }
.cp-cx-note[hidden] { display: none; }
@container (min-width: 680px) {
  .cp-lgrid.cp-has-live { grid-template-columns: minmax(0, 1fr) 260px; align-items: start; }
  .cp-has-live .cp-live { position: sticky; top: 16px; }
}
@container (max-width: 679px) {
  /* a thin bar that stays at the bottom of the screen while the picker is on it */
  .cp-has-live .cp-live { position: sticky; bottom: 8px; z-index: 5; order: 2; padding: 10px 14px;
    grid-template-columns: auto 1fr; align-items: baseline; gap: 2px 10px; box-shadow: 0 -4px 18px rgba(22,33,31,.12); }
  .cp-has-live .cp-live b { font-size: 18px; }
  .cp-has-live .cp-live .small { grid-column: 1 / -1; }
  .cp-has-live .cp-live [data-live-plain] { display: none; }
}
@media (max-width: 640px) {
  .ub-th { grid-template-columns: 44px minmax(0, 1fr) auto; }
  .ub-th .ub-when { display: none; }
  .ub-claim { flex-direction: column; align-items: stretch; }
  .ub-claim > .btn, .ub-claim > .ub-acts, .ub-claim .claim-form { justify-content: flex-start; align-self: flex-start; }
  .ub-ready { flex-direction: column; align-items: stretch; }
  .ub-ready > .btn { align-self: flex-start; }
  .ub-tabs a { padding: 0 12px; }
  .ub-sec-h { padding: 14px 16px; }
  .ub-sec-b { padding: 16px; }
  .ub-savebar { padding: 10px 14px; margin-left: -4px; margin-right: -4px; }
  .ub-savebar-acts { width: 100%; }
  .ub-savebar-acts .btn { flex: 1; min-height: 40px; }
  .ub-savebar:not(.dirty) [data-savebar-msg] { display: none; }
  .ub-tabs { gap: 2px; }
}
/* the Team table's hidden "Change" header stays inside its scrolling box */
.tbl:has(> .team-table) { position: relative; }
/* ---------- end of the usability pass block ---------- */

/* ---------- Client chart: the essentials up top, then sections that open (templates/client.html) ---------- */
.cx-top { display: grid; gap: 16px; }
.cx-facts { display: grid; gap: 10px; }
.cx-facts > div { display: flex; flex-wrap: wrap; gap: 2px 12px; align-items: baseline; }
.cx-facts > div > span:last-child { flex: 1 1 260px; min-width: 0; overflow-wrap: anywhere; }
.cx-k { flex: 0 0 132px; font-size: 13px; font-weight: 700; color: var(--muted); }
.cx-facts .pill { text-decoration: none; margin-left: 4px; }
.cx-alerts { list-style: none; margin: 0; padding: 0; display: flex; flex-wrap: wrap; gap: 8px; }
.cx-alerts a { display: inline-flex; align-items: center; min-height: 36px; padding: 6px 14px; border-radius: 999px;
  background: var(--warn-soft); color: var(--warn); font-weight: 700; font-size: 14px; line-height: 1.3; text-decoration: none; }
.cx-alerts .bad a { background: var(--bad-soft); color: var(--bad); }
.cx-alerts a:hover { filter: brightness(.97); }
.cx-actions { display: flex; flex-wrap: wrap; gap: 8px; }
.cx-tools { display: grid; gap: 4px; padding-top: 12px; border-top: 1px solid var(--line); color: var(--muted); }
.cx-tools a { font-weight: 700; }
.cx-top + .card, .cx-top + .card + #specialty, .cx-top + #specialty { margin-top: 20px; }
.cx-secs { margin-top: 20px; display: grid; gap: 10px; }
.cx-secs > .card + .card { margin-top: 0; }
/* A section that opens (<details>) carries its heading just before it, for screen readers' heading lists
   (a heading inside <summary> isn't announced as one everywhere); the visible title stays in the summary. */
.card + .sec-h + .card { margin-top: 20px; }
.cx-secs > .sec-h + .card { margin-top: 0; }
details.cx-sec { padding: 0; scroll-margin-top: 72px; }
details.cx-sec > summary { list-style: none; cursor: pointer; display: flex; align-items: center; gap: 12px; padding: 14px 24px; min-height: 64px; }
details.cx-sec > summary::-webkit-details-marker { display: none; }
details.cx-sec > summary > span:first-child { flex: 1 1 auto; min-width: 0; display: grid; gap: 2px; }
details.cx-sec > summary h2 { font-size: 17px; margin: 0; }
details.card.cx-sec > summary h2::after, details.card.cx-sec[open] > summary h2::after { content: none; }
details.cx-sec > summary::after { content: "+"; flex: none; width: 22px; text-align: center; font: 700 22px/1 var(--font); color: var(--accent); }
details.cx-sec[open] > summary::after { content: "\2212"; }
details.cx-sec > summary:hover h2 { color: var(--accent); }
.cx-one { font-size: 14px; color: var(--muted); overflow-wrap: anywhere; }
.cx-one .warn { color: var(--warn); }
.cx-one .bad { color: var(--bad); }
.cx-body { display: block; padding: 0 24px 24px; border-top: 1px solid var(--line); }
.cx-part { margin-top: 20px; padding-top: 16px; border-top: 1px solid var(--line); }
.cx-body h3.sub { margin-bottom: 6px; }
.cx-sub > summary { cursor: pointer; display: inline; }
.cx-sub { margin-top: 14px; }
/* a whole card dropped inside a section: no second box, no second title */
.cx-wrap > .card { border: 0; border-radius: 0; background: none; padding: 16px 0 0; margin-top: 0; }
.cx-wrap > .card > h2:first-child, .cx-wrap > .card > .sched-head:first-child > h2 { display: none; }
.cx-wrap > .card > .sched-head:first-child { justify-content: flex-end; }
@media (max-width: 640px) {
  details.cx-sec > summary { padding: 12px 16px; }
  .cx-body { padding: 0 16px 18px; }
  .cx-k { flex-basis: 100%; }
}

/* Credentialing term explainers (ph/cred_terms.py, static/cred-terms.js): a "?" button, the explanation on
   hover, keyboard focus or tap. Colors are theme tokens, so night mode follows. */
.term { position: relative; display: inline; }
.term-q { display: inline-grid; place-items: center; width: 18px; height: 18px; margin: 0 0 0 4px; padding: 0;
  border: 1px solid var(--line); border-radius: 50%; background: var(--soft); color: var(--muted);
  font: 700 11px/1 var(--font); cursor: help; vertical-align: 1px; position: relative; }
.term-q::after { content: ""; position: absolute; inset: -4px; }   /* a 24px+ target around the 18px circle */
.term-q:hover, .term-q:focus-visible { color: var(--ink); border-color: var(--accent); }
.term-q:focus-visible { outline: 2px solid var(--accent); outline-offset: 2px; }
.term-tip { position: absolute; left: 0; top: calc(100% + 6px); z-index: 40; width: max-content; max-width: min(320px, 80vw);
  padding: 10px 12px; border: 1px solid var(--line); border-radius: 10px; background: var(--surface); color: var(--ink);
  box-shadow: var(--shadow); font-size: 13px; font-weight: 400; line-height: 1.45; text-align: left; white-space: normal;
  visibility: hidden; opacity: 0; transition: opacity .12s; }
.term:hover .term-tip, .term-q:focus-visible + .term-tip, .term.open .term-tip, .term:focus-within .term-tip { visibility: visible; opacity: 1; }
.term.dismissed .term-tip { visibility: hidden; opacity: 0; }
/* An explainer next to a form field sits after the <label>, so it isn't part of the field's name. */
.term-line { display: block; margin: -4px 0 10px; color: var(--muted); }
.term-line .term-word { font-size: 12px; }
@media (max-width: 640px) { .term-tip { position: fixed; left: 16px; right: 16px; top: auto; bottom: 16px; max-width: none; width: auto; } }
@media print { .term-q, .term-tip { display: none; } }

/* Invite an interpreter ahead of time (templates/_interpreter_invite.html, 1059) */
.ip-card .ip-who { margin: 10px 0 4px; }
.ip-card .ip-newlink { margin: 10px 0; }
.ip-linkrow { display: flex; gap: 8px; align-items: center; margin-top: 4px; }
.ip-linkrow input { flex: 1; min-width: 0; }
.ip-card .ip-cancel { display: flex; gap: 10px; align-items: baseline; flex-wrap: wrap; margin-top: 8px; }
.ip-card .ip-form { margin-top: 12px; }
.ip-card .ip-form form { margin-top: 8px; }

/* Phone layout (docs/audits/antigravity-phone-layout-2026-12-01.md) */
.row-inline { grid-template-columns: 1fr auto; align-items: end; }
.row-inline3 { grid-template-columns: 1fr 1fr auto; align-items: end; }
.rec-extra-row { grid-template-columns: 2fr 1fr auto; align-items: end; gap: 8px; }
.wl-acts { display: flex; flex-wrap: wrap; gap: 8px; margin-top: 10px; }
.wl-days { display: flex; flex-wrap: wrap; gap: 8px 14px; }
.wl-days legend { width: 100%; }
.wl-days .check { min-height: 44px; align-items: center; }
.cp-main a[href^="mailto:"], .cp-main pre { overflow-wrap: anywhere; }
.cp-main pre { white-space: pre-wrap; }
@media (max-width: 720px) {
  .btn.sm { min-height: 44px; }
  .link-btn { min-height: 44px; padding: 8px 4px; }
  .cp-legal a { display: inline-block; padding: 10px 4px; }
}
@media (max-width: 640px) {
  .row-inline, .row-inline3, .rec-extra-row { grid-template-columns: 1fr; }
  .oon-claims thead { position: absolute; width: 1px; height: 1px; overflow: hidden; clip: rect(0 0 0 0); }
  .oon-claims table, .oon-claims tbody, .oon-claims tr, .oon-claims td { display: block; }
  .oon-claims tr { padding: 12px 0; border-top: 1px solid var(--line); }
  .oon-claims tr:first-child { border-top: 0; }
  .oon-claims td { padding: 2px 0; border: 0; white-space: normal; text-align: left; }
  .oon-claims td.num::before { content: "Fee: "; color: var(--muted); }
  .cp-receipts th, .cp-receipts td { padding: 10px 6px; }
}
@media (max-width: 480px) { .plogo-img { max-width: 170px; } }

/* Interpreter routes and warnings (templates/_interpreter_route.html, calendar.html, static/interpreter-alerts.js; 1063).
   Red plus the words and a warning sign: never colour alone. */
.iroute-warn { margin: 6px 0; padding: 8px 10px; border-radius: 8px; background: var(--bad-soft); color: var(--bad); font-size: 14px; }
.iroute-warn a { color: inherit; font-weight: 700; }
.appt.interp-needed, .mappt.interp-needed, .drow.interp-needed { background: var(--bad-soft); box-shadow: inset 0 0 0 2px var(--bad); }
.interp-flag { color: var(--bad); font-weight: 800; letter-spacing: .02em; }
.appt .interp-flag { display: block; }
.interp-alert { max-width: 560px; }
.interp-alert h2 { color: var(--bad); }
.interp-alert-list { list-style: none; margin: 12px 0; padding: 0; max-height: 50vh; overflow: auto; }
.interp-alert-list li { padding: 10px 0; border-top: 1px solid var(--line); }
.interp-alert-row { display: flex; gap: 10px; align-items: center; flex-wrap: wrap; margin-top: 6px; }
.interp-hint { margin: 10px 0; }
.interp-hint p { margin: 4px 0; }
