/* ============================================================
   DocSahab · Apple-style design layer (loaded after styles.css)
   Apple HIG cues: system font (SF on Apple devices), frosted translucent bars, large titles,
   grouped rounded cards with hairline borders, segmented controls, iOS switches and filled fields.
   Plus the dashboard components used by admin.html, support-desk.html and dashboard.html,
   drawn from the reference boards (MediCore / CareNest / Mediora / Orbix style).
   ============================================================ */
:root {
  --font-ui: -apple-system, BlinkMacSystemFont, "SF Pro Text", "SF Pro Display", "Plus Jakarta Sans", "Segoe UI", system-ui, sans-serif;
  --ap-bg: #f2f5f4;          /* systemGroupedBackground, mint-tinted */
  --ap-card: #ffffff;
  --ap-fill: rgba(118,128,124,.12);  /* iOS tertiary fill */
  --ap-hair: rgba(16,40,32,.08);
  --ap-label2: #5f6b67;
  --ap-blue: #0a84ff;
  --ap-red: #ff3b30; --ap-orange: #ff9500; --ap-green: #34c759; --ap-purple: #af52de;
  --ap-r: 22px; --ap-r-sm: 14px;
  --ap-shadow: 0 1px 1px rgba(0,0,0,.02), 0 8px 24px rgba(16,40,32,.06);
  --ap-glass: rgba(255,255,255,.72);
}
body, button, input, select, textarea { font-family: var(--font-ui); }
body { -webkit-font-smoothing: antialiased; -moz-osx-font-smoothing: grayscale; text-rendering: optimizeLegibility; }
h1, h2, h3 { letter-spacing: -.025em; }
.site-header { background: var(--ap-glass); backdrop-filter: saturate(180%) blur(20px); -webkit-backdrop-filter: saturate(180%) blur(20px); border-bottom: .5px solid var(--ap-hair); }
.card { border-radius: var(--ap-r); border-color: var(--ap-hair); box-shadow: var(--ap-shadow); }
.input, .select { border-radius: 12px; background: #f4f6f5; border-color: transparent; }
.input:focus, .select:focus { background: #fff; }
.btn { letter-spacing: -.01em; }
.btn:active { transform: scale(.97); }
:focus-visible { outline: 3px solid rgba(10,132,255,.45); outline-offset: 2px; }

/* ---------- shared controls ---------- */
.seg { display: inline-flex; gap: 4px; padding: 4px; border-radius: 999px; background: var(--ap-fill); }
.seg a, .seg button { border: 0; background: transparent; padding: 8px 16px; border-radius: 999px; font: 600 .9rem var(--font-ui); color: #33403c; cursor: pointer; white-space: nowrap; text-decoration: none; }
.seg .is-on, .seg [aria-selected="true"], .seg [aria-current="page"] { background: #fff; color: var(--dark); box-shadow: 0 1px 3px rgba(0,0,0,.12), 0 1px 1px rgba(0,0,0,.04); }
.ios-switch { position: relative; width: 51px; height: 31px; flex: none; }
.ios-switch input { position: absolute; opacity: 0; inset: 0; cursor: pointer; margin: 0; }
.ios-switch span { position: absolute; inset: 0; border-radius: 999px; background: #e3e6e5; transition: background .2s; pointer-events: none; }
.ios-switch span::after { content: ""; position: absolute; top: 2px; left: 2px; width: 27px; height: 27px; border-radius: 50%; background: #fff; box-shadow: 0 3px 8px rgba(0,0,0,.15), 0 1px 1px rgba(0,0,0,.16); transition: transform .25s cubic-bezier(.3,.7,.4,1); }
.ios-switch input:checked + span { background: var(--ap-green); }
.ios-switch input:checked + span::after { transform: translateX(20px); }
.pill { display: inline-flex; align-items: center; gap: 6px; padding: 4px 10px; border-radius: 999px; font-size: .76rem; font-weight: 700; white-space: nowrap; }
.pill::before { content: ""; width: 6px; height: 6px; border-radius: 50%; background: currentColor; }
.pill--green { background: #e6f8ec; color: #1f9d4c; } .pill--blue { background: #e6f1ff; color: #0a6fdc; } .pill--orange { background: #fff2e0; color: #c26a00; }
.pill--red { background: #ffeceb; color: #d92d20; } .pill--grey { background: #f0f2f1; color: #6b7672; } .pill--purple { background: #f5e9fb; color: #8e3cb8; }
.av { width: 36px; height: 36px; border-radius: 50%; object-fit: cover; flex: none; background: var(--mint); }
.av-txt { width: 36px; height: 36px; border-radius: 50%; display: grid; place-items: center; font-weight: 800; font-size: .8rem; color: #fff; flex: none; }
.ico-btn { width: 40px; height: 40px; border-radius: 50%; display: grid; place-items: center; border: 0; background: #fff; box-shadow: 0 1px 3px rgba(0,0,0,.08); color: #2b3633; cursor: pointer; position: relative; }
.ico-btn .dot { position: absolute; top: 9px; right: 10px; width: 8px; height: 8px; border-radius: 50%; background: var(--ap-red); border: 2px solid #fff; }
.ico-btn svg, .ap-svg { width: 18px; height: 18px; }

/* ---------- glass AI orb (reference: medical AI app) ---------- */
.orb { position: relative; width: 120px; aspect-ratio: 1; border-radius: 50%; isolation: isolate;
  background: radial-gradient(circle at 30% 28%, rgba(255,255,255,.95) 0 6%, rgba(255,255,255,0) 22%),
              conic-gradient(from 210deg, #064e3b, #10b981, #a7f3d0, #047857, #022c22, #34d399, #064e3b);
  box-shadow: inset -12px -16px 30px rgba(0,30,20,.55), inset 10px 12px 26px rgba(255,255,255,.35), 0 18px 40px rgba(4,120,87,.35), 0 0 0 10px rgba(255,255,255,.55);
  animation: orbSpin 9s linear infinite; }
.orb::before { content: ""; position: absolute; inset: 14%; border-radius: 50%; background: conic-gradient(from 40deg, rgba(255,255,255,0), rgba(255,255,255,.5), rgba(255,255,255,0) 30%, rgba(167,243,208,.6) 55%, rgba(255,255,255,0) 70%); filter: blur(6px); mix-blend-mode: screen; animation: orbSpin 5s linear infinite reverse; }
.orb::after { content: ""; position: absolute; left: 18%; top: 12%; width: 34%; height: 22%; border-radius: 50%; background: linear-gradient(180deg, rgba(255,255,255,.9), rgba(255,255,255,0)); transform: rotate(-28deg); }
.orb--sm { width: 40px; box-shadow: inset -4px -6px 10px rgba(0,30,20,.5), inset 3px 4px 8px rgba(255,255,255,.35), 0 4px 10px rgba(4,120,87,.3); }
.orb.is-live { animation: orbSpin 3s linear infinite, orbPulse 1.1s ease-in-out infinite; }
@keyframes orbSpin { to { filter: hue-rotate(0deg); transform: rotate(360deg); } }
@keyframes orbPulse { 50% { box-shadow: inset -12px -16px 30px rgba(0,30,20,.55), inset 10px 12px 26px rgba(255,255,255,.35), 0 18px 60px rgba(16,185,129,.6), 0 0 0 18px rgba(167,243,208,.35); } }
@media (prefers-reduced-motion: reduce) { .orb, .orb::before, .orb.is-live { animation: none; } }

/* ============================================================
   Operations / admin dashboard (light, reference: MediCore / CareNest)
   ============================================================ */
.ops { background: radial-gradient(1200px 600px at 85% -10%, #d8f5ea 0%, rgba(216,245,234,0) 60%), var(--ap-bg); min-height: 100vh; }
.ops-bar { position: sticky; top: 0; z-index: 40; background: rgba(242,245,244,.78); backdrop-filter: saturate(180%) blur(20px); -webkit-backdrop-filter: saturate(180%) blur(20px); border-bottom: .5px solid var(--ap-hair); }
.ops-bar .in { max-width: 1360px; margin: 0 auto; padding: 12px 24px; display: flex; align-items: center; gap: 16px; }
.ops-brand { display: flex; align-items: center; gap: 10px; font-weight: 800; font-size: 1.1rem; color: var(--dark); text-decoration: none; }
.ops-brand svg { width: 34px; height: 34px; }
.ops-bar .seg { margin: 0 auto; overflow-x: auto; max-width: 100%; scrollbar-width: none; }
.ops-search { display: flex; align-items: center; gap: 8px; padding: 9px 14px; border-radius: 999px; background: #fff; box-shadow: 0 1px 3px rgba(0,0,0,.06); color: var(--ap-label2); font-size: .88rem; min-width: 200px; }
.ops-me { display: flex; align-items: center; gap: 10px; font-size: .86rem; line-height: 1.2; }
.ops-me small { display: block; color: var(--ap-label2); }
.ops-wrap { max-width: 1360px; margin: 0 auto; padding: 24px; display: grid; gap: 20px; }
.ops-grid { display: grid; gap: 20px; }
.g-hero { grid-template-columns: 1.15fr 1fr; }
.g-4 { grid-template-columns: repeat(4, minmax(0, 1fr)); }
.g-main { grid-template-columns: 1.55fr 1fr; }
.g-3 { grid-template-columns: 1.3fr 1fr 1fr; }
.panel { background: var(--ap-card); border-radius: var(--ap-r); border: .5px solid var(--ap-hair); box-shadow: var(--ap-shadow); padding: 20px; min-width: 0; }
.panel-h { display: flex; align-items: center; justify-content: space-between; gap: 10px; margin-bottom: 14px; }
.panel-h h2, .panel-h h3 { font-size: 1.05rem; margin: 0; font-weight: 700; }
.panel-h .more { border: 0; background: var(--ap-fill); border-radius: 999px; padding: 6px 12px; font: 600 .8rem var(--font-ui); color: #33403c; cursor: pointer; text-decoration: none; }
.ops-hello { padding: 28px; display: flex; flex-direction: column; justify-content: center; gap: 12px; background: linear-gradient(135deg, rgba(255,255,255,.95), rgba(255,255,255,.75)); }
.ops-hello .eyebrow { font-size: .74rem; letter-spacing: .14em; text-transform: uppercase; color: var(--ap-label2); font-weight: 700; }
.ops-hello h1 { font-size: clamp(1.9rem, 3.4vw, 2.8rem); margin: 0; font-weight: 700; letter-spacing: -.035em; }
.ops-hello p { margin: 0; color: var(--ap-label2); }
.ops-hello .row { display: flex; gap: 10px; flex-wrap: wrap; margin-top: 6px; }
.btn--dark { background: #111816; color: #fff; } .btn--dark:hover { background: #000; color: #fff; }
.btn--soft { background: #fff; color: var(--dark); box-shadow: 0 1px 3px rgba(0,0,0,.08); } .btn--soft:hover { color: var(--dark); }
.ops-visual { position: relative; min-height: 280px; overflow: hidden; padding: 0; background: radial-gradient(circle at 60% 40%, #c8f3e2 0%, #eaf8f2 55%, #f6fbf9 100%); }
.ops-visual img { position: absolute; right: 8%; bottom: 0; height: 108%; object-fit: contain; filter: drop-shadow(0 20px 30px rgba(11,56,46,.2)); }
.ops-visual .orb { position: absolute; left: 10%; top: 16%; width: 110px; }
.chip-glass { position: absolute; display: flex; align-items: center; gap: 10px; padding: 10px 14px; border-radius: 16px; background: rgba(255,255,255,.75); backdrop-filter: blur(14px); -webkit-backdrop-filter: blur(14px); border: 1px solid rgba(255,255,255,.9); box-shadow: 0 10px 30px rgba(11,56,46,.12); font-size: .78rem; color: var(--ap-label2); line-height: 1.15; }
.chip-glass b { display: block; font-size: 1.15rem; color: var(--dark); letter-spacing: -.02em; }
.chip-glass i { width: 30px; height: 30px; border-radius: 10px; display: grid; place-items: center; background: var(--mint); color: var(--primary); font-style: normal; }
.stat { display: grid; gap: 6px; }
.stat .top { display: flex; justify-content: space-between; align-items: center; font-weight: 600; color: #33403c; font-size: .92rem; }
.stat .top a { width: 30px; height: 30px; border-radius: 50%; display: grid; place-items: center; background: var(--ap-fill); color: #33403c; }
.stat .delta { font-size: .76rem; font-weight: 700; color: #1f9d4c; } .stat .delta.down { color: #d92d20; }
.stat .row { display: flex; align-items: flex-end; justify-content: space-between; gap: 10px; }
.stat b { font-size: 2.4rem; font-weight: 700; letter-spacing: -.04em; line-height: 1; color: #111816; }
.stat svg { width: 55%; height: 48px; }
.tbl { width: 100%; border-collapse: collapse; font-size: .88rem; }
.tbl th { text-align: left; font-weight: 600; color: var(--ap-label2); font-size: .78rem; padding: 0 10px 10px; white-space: nowrap; }
.tbl td { padding: 12px 10px; border-top: .5px solid var(--ap-hair); vertical-align: middle; white-space: nowrap; }
.tbl .who { display: flex; align-items: center; gap: 10px; } .tbl .who b { display: block; font-weight: 600; color: #111816; } .tbl .who small { color: var(--ap-label2); }
.sched { display: grid; gap: 10px; }
.sched-row { display: grid; grid-template-columns: 58px 1fr auto; align-items: center; gap: 12px; padding: 10px 12px; border-radius: 16px; background: #f7f9f8; }
.sched-row time { font-size: .78rem; color: var(--ap-label2); line-height: 1.3; font-weight: 600; }
.sched-row .who { display: flex; align-items: center; gap: 10px; min-width: 0; } .sched-row .who b { display: block; font-size: .9rem; } .sched-row .who small { color: var(--ap-label2); font-size: .76rem; }
.prog { height: 8px; border-radius: 8px; background: #eef1f0; overflow: hidden; } .prog i { display: block; height: 100%; border-radius: inherit; background: linear-gradient(90deg, var(--secondary), #34d399); }
.prog--purple i { background: linear-gradient(90deg, #c084fc, #af52de); } .prog--orange i { background: linear-gradient(90deg, #fdba74, #ff9500); } .prog--blue i { background: linear-gradient(90deg, #7cc0ff, #0a84ff); }
.res { display: grid; gap: 10px; }
.res-row { display: flex; align-items: center; gap: 12px; padding: 12px; border-radius: 16px; background: #f7f9f8; }
.res-row i { width: 38px; height: 38px; border-radius: 12px; display: grid; place-items: center; font-style: normal; flex: none; }
.res-row b { display: block; font-size: .92rem; } .res-row small { color: var(--ap-label2); font-size: .76rem; } .res-row span.n { margin-left: auto; font-weight: 700; font-size: 1.05rem; }
.donut-wrap { display: grid; justify-items: center; gap: 14px; }
.legend { display: flex; flex-wrap: wrap; gap: 8px 16px; justify-content: center; font-size: .8rem; color: var(--ap-label2); }
.legend span { display: inline-flex; align-items: center; gap: 6px; } .legend span::before { content: ""; width: 9px; height: 9px; border-radius: 50%; background: var(--c); }
.alerts { display: grid; gap: 10px; }
.alert-row { display: flex; gap: 12px; align-items: flex-start; padding: 12px; border-radius: 16px; border: .5px solid var(--ap-hair); }
.alert-row i { width: 32px; height: 32px; border-radius: 10px; display: grid; place-items: center; font-style: normal; flex: none; background: #f2f4f3; }
.alert-row b { display: block; font-size: .9rem; } .alert-row small { color: var(--ap-label2); font-size: .78rem; }
.ai-card { position: relative; overflow: hidden; color: #e8fff6; background: radial-gradient(400px 220px at 90% 0%, rgba(52,211,153,.45), transparent 60%), radial-gradient(300px 200px at 0% 100%, rgba(16,185,129,.35), transparent 60%), linear-gradient(160deg, #0b2f27, #071b16); border: 1px solid rgba(255,255,255,.08); }
.ai-card .panel-h h3 { color: #fff; display: flex; align-items: center; gap: 10px; }
.ai-msg { padding: 10px 14px; border-radius: 16px; font-size: .86rem; margin-bottom: 10px; max-width: 88%; line-height: 1.45; }
.ai-msg.me { margin-left: auto; background: rgba(255,255,255,.1); border: 1px solid rgba(255,255,255,.12); }
.ai-msg.bot { background: rgba(255,255,255,.16); border: 1px solid rgba(255,255,255,.18); }
.ai-input { display: flex; align-items: center; gap: 8px; margin-top: 10px; padding: 8px 8px 8px 14px; border-radius: 16px; background: rgba(255,255,255,.08); border: 1px solid rgba(255,255,255,.14); }
.ai-input input { flex: 1; background: transparent; border: 0; color: #fff; font-size: .88rem; outline: none; } .ai-input input::placeholder { color: rgba(232,255,246,.6); }
.ai-input button { width: 34px; height: 34px; border-radius: 10px; border: 0; background: #fff; color: var(--dark); display: grid; place-items: center; cursor: pointer; }
.concern { display: grid; gap: 12px; }
.concern-row { display: grid; grid-template-columns: 1fr 44px; gap: 6px 10px; align-items: center; font-size: .86rem; }
.concern-row .prog { grid-column: 1 / -1; }
.sample-note { font-size: .78rem; color: var(--ap-label2); text-align: center; }
@media (max-width: 1100px) { .g-4 { grid-template-columns: repeat(2, minmax(0, 1fr)); } .g-main, .g-3, .g-hero { grid-template-columns: 1fr; } .ops-search { display: none; } }
@media (max-width: 640px) { .ops-wrap { padding: 14px; gap: 14px; } .ops-bar .in { padding: 10px 14px; flex-wrap: wrap; } .ops-bar .seg { order: 3; width: 100%; } .ops-me small, .ops-me span.t { display: none; } .g-4 { gap: 12px; } .stat b { font-size: 1.9rem; } .ops-visual { min-height: 230px; } .panel { padding: 16px; } }

/* ============================================================
   Customer support desk (dark, reference: Orbix support dashboard)
   ============================================================ */
.sd { --sd-bg: #0b0f17; --sd-panel: #121826; --sd-line: rgba(255,255,255,.07); --sd-txt: #e7ecf3; --sd-mute: #8a94a6;
  background: radial-gradient(800px 500px at 100% 0%, rgba(16,185,129,.12), transparent 60%), var(--sd-bg); color: var(--sd-txt); min-height: 100vh; }
.sd a { color: inherit; }
.sd-shell { display: grid; grid-template-columns: 76px 260px 340px 1fr 300px; height: 100vh; }
.sd-rail { display: flex; flex-direction: column; align-items: center; gap: 14px; padding: 18px 0; border-right: 1px solid var(--sd-line); }
.sd-rail .logo { width: 46px; height: 46px; border-radius: 50%; background: #fff; display: grid; place-items: center; margin-bottom: 8px; }
.sd-rail .logo svg { width: 30px; height: 30px; }
.sd-rail button, .sd-rail a.rb { width: 46px; height: 46px; border-radius: 50%; border: 1px solid var(--sd-line); background: #161d2c; color: #cfd7e3; display: grid; place-items: center; cursor: pointer; }
.sd-rail .is-on { background: linear-gradient(135deg, #10b981, #0d6e53); color: #fff; border-color: transparent; }
.sd-col { border-right: 1px solid var(--sd-line); overflow-y: auto; min-width: 0; }
.sd-folders { padding: 22px 14px; background: var(--sd-panel); }
.sd-folders h4 { margin: 16px 10px 8px; font-size: .74rem; color: var(--sd-mute); text-transform: uppercase; letter-spacing: .08em; font-weight: 600; }
.sd-folders h4:first-child { margin-top: 0; }
.sd-f { display: flex; align-items: center; gap: 10px; width: 100%; padding: 10px 12px; border: 0; border-radius: 12px; background: transparent; color: var(--sd-txt); font: 500 .9rem var(--font-ui); cursor: pointer; text-align: left; }
.sd-f:hover { background: rgba(255,255,255,.05); }
.sd-f.is-on { background: linear-gradient(90deg, #f59e0b, #ef4444 45%, #a855f7); color: #fff; font-weight: 700; }
.sd-f .c { margin-left: auto; font-size: .76rem; color: var(--sd-mute); } .sd-f.is-on .c { color: #fff; background: rgba(255,255,255,.25); border-radius: 999px; padding: 1px 8px; }
.sd-f .ag { width: 20px; height: 20px; border-radius: 6px; display: grid; place-items: center; font-size: .7rem; font-weight: 800; }
.sd-list-h { display: flex; justify-content: space-between; align-items: center; padding: 22px 18px 10px; }
.sd-list-h h2 { margin: 0; font-size: 1.35rem; color: #fff; }
.sd-list-h small { color: var(--sd-mute); }
.sd-conv { display: flex; gap: 12px; width: calc(100% - 20px); margin: 0 10px 4px; padding: 12px; border-radius: 14px; border: 0; background: transparent; color: inherit; cursor: pointer; text-align: left; font-family: var(--font-ui); }
.sd-conv:hover { background: rgba(255,255,255,.04); } .sd-conv.is-on { background: #1b2335; }
.sd-conv .t { flex: 1; min-width: 0; } .sd-conv b { display: block; font-size: .92rem; color: #fff; } .sd-conv small { display: block; color: var(--sd-mute); font-size: .8rem; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.sd-conv .meta { display: grid; justify-items: end; gap: 6px; font-size: .72rem; color: var(--sd-mute); }
.sd-conv .badge { min-width: 20px; height: 20px; border-radius: 999px; background: #10b981; color: #06281e; font-weight: 800; display: grid; place-items: center; font-size: .72rem; padding: 0 6px; }
.sd-conv .badge.red { background: #ef4444; color: #fff; }
.sd-thread { display: flex; flex-direction: column; min-width: 0; }
.sd-thread-h { display: flex; align-items: center; gap: 12px; padding: 16px 22px; border-bottom: 1px solid var(--sd-line); }
.sd-thread-h b { display: block; color: #fff; } .sd-thread-h small { color: var(--sd-mute); }
.sd-thread-h .act { margin-left: auto; display: flex; gap: 8px; }
.sd-btn { border: 1px solid var(--sd-line); background: #161d2c; color: var(--sd-txt); border-radius: 999px; padding: 7px 14px; font: 600 .8rem var(--font-ui); cursor: pointer; }
.sd-btn--go { background: #10b981; color: #052e22; border-color: transparent; }
.sd-msgs { flex: 1; overflow-y: auto; padding: 22px; display: flex; flex-direction: column; gap: 14px;
  background-image: radial-gradient(rgba(255,255,255,.035) 1px, transparent 1px); background-size: 18px 18px; }
.sd-m { display: flex; gap: 10px; max-width: 78%; }
.sd-m .bub { padding: 11px 14px; border-radius: 14px; background: #1b2335; border: 1px solid var(--sd-line); font-size: .9rem; line-height: 1.45; }
.sd-m .who { font-size: .76rem; color: var(--sd-mute); margin-bottom: 4px; }
.sd-m.agent { margin-left: auto; flex-direction: row-reverse; } .sd-m.agent .bub { background: #0f3b30; border-color: rgba(16,185,129,.3); }
.sd-m.ai .bub { background: linear-gradient(135deg, rgba(168,85,247,.18), rgba(16,185,129,.16)); border-color: rgba(168,85,247,.35); }
.sd-m time { font-size: .7rem; color: var(--sd-mute); display: block; margin-top: 4px; }
.sd-ai-bar { margin: 0 22px; padding: 12px 16px; border-radius: 16px; background: linear-gradient(90deg, #f59e0b, #ef4444 40%, #a855f7); color: #fff; display: flex; align-items: center; gap: 12px; font-size: .86rem; }
.sd-ai-bar b { font-weight: 800; } .sd-ai-bar .sd-btn { margin-left: auto; background: rgba(0,0,0,.25); border-color: rgba(255,255,255,.3); color: #fff; }
.sd-compose { display: flex; gap: 10px; padding: 14px 22px 20px; align-items: center; }
.sd-compose input { flex: 1; background: #161d2c; border: 1px solid var(--sd-line); border-radius: 14px; padding: 12px 14px; color: #fff; font: .92rem var(--font-ui); outline: none; }
.sd-compose input:focus { border-color: rgba(16,185,129,.5); }
.sd-side { padding: 22px 18px; background: var(--sd-panel); overflow-y: auto; }
.sd-side h3 { font-size: .8rem; color: var(--sd-mute); text-transform: uppercase; letter-spacing: .08em; margin: 18px 0 10px; font-weight: 600; }
.sd-side .card-d { background: #161d2c; border: 1px solid var(--sd-line); border-radius: 16px; padding: 14px; font-size: .86rem; display: grid; gap: 8px; }
.sd-side .kv { display: flex; justify-content: space-between; gap: 10px; } .sd-side .kv span { color: var(--sd-mute); }
.sd-kpis { display: grid; grid-template-columns: 1fr 1fr; gap: 10px; }
.sd-kpis div { background: #161d2c; border: 1px solid var(--sd-line); border-radius: 14px; padding: 12px; } .sd-kpis b { display: block; font-size: 1.4rem; color: #fff; } .sd-kpis small { color: var(--sd-mute); font-size: .74rem; }
.sd-note { font-size: .74rem; color: var(--sd-mute); margin-top: 14px; }
.sd-back { display: none; }
@media (max-width: 1280px) { .sd-shell { grid-template-columns: 70px 220px 300px 1fr; } .sd-side { display: none; } }
@media (max-width: 900px) {
  .sd-shell { grid-template-columns: 1fr; height: auto; min-height: 100vh; }
  .sd-rail { flex-direction: row; justify-content: flex-start; padding: 10px 14px; border-right: 0; border-bottom: 1px solid var(--sd-line); overflow-x: auto; }
  .sd-rail .logo { margin: 0; }
  .sd-folders { display: flex; gap: 6px; overflow-x: auto; padding: 10px 12px; } .sd-folders h4, .sd-folders .sd-ag { display: none; } .sd-f { width: auto; white-space: nowrap; }
  .sd-col { border-right: 0; }
  .sd.show-thread .sd-listcol { display: none; } .sd:not(.show-thread) .sd-thread { display: none; }
  .sd-thread { min-height: calc(100vh - 140px); } .sd-back { display: inline-flex; } .sd-m { max-width: 92%; } .sd-ai-bar { margin: 0 12px; flex-wrap: wrap; } .sd-msgs { padding: 14px; } .sd-compose { padding: 12px; }
}

/* ============================================================
   Patient dashboard & profile (reference: Mediora / CareNest)
   ============================================================ */
.pd { background: radial-gradient(1000px 500px at 100% 0%, #d6f5e8, rgba(214,245,232,0) 60%), var(--ap-bg); }
.pd-wrap { max-width: 1240px; margin: 0 auto; padding: 24px; display: grid; grid-template-columns: minmax(0, 1fr); gap: 20px; }
.pd-top > * { min-width: 0; }
.pd-top { display: flex; align-items: flex-end; justify-content: space-between; gap: 16px; flex-wrap: wrap; }
.pd-top h1 { font-size: clamp(1.9rem, 3.4vw, 2.6rem); margin: 0; font-weight: 700; letter-spacing: -.035em; }
.pd-top p { margin: 4px 0 0; color: var(--ap-label2); }
.pd-tabs { overflow-x: auto; max-width: 100%; scrollbar-width: none; }
.pd-view[hidden] { display: none; }
.g-pd { grid-template-columns: 1.1fr 1fr 1fr; }
.g-pd2 { grid-template-columns: 1.4fr 1fr; }
.score { position: relative; overflow: hidden; color: #eafff6; background: radial-gradient(360px 260px at 20% 0%, rgba(52,211,153,.55), transparent 60%), radial-gradient(300px 260px at 100% 100%, rgba(16,185,129,.4), transparent 60%), linear-gradient(160deg, #0d3b30, #06201a); border: 0; }
.score h3 { color: #fff; margin: 0; font-size: 1.05rem; display: flex; align-items: center; gap: 10px; }
.score small { color: rgba(234,255,246,.7); }
.gauge { position: relative; width: 100%; max-width: 280px; margin: 10px auto 0; }
.gauge svg { width: 100%; display: block; }
.gauge .v { position: absolute; left: 0; right: 0; bottom: 6%; text-align: center; }
.gauge .v b { font-size: 2.6rem; font-weight: 700; color: #fff; letter-spacing: -.04em; } .gauge .v span { display: inline-block; margin-bottom: 6px; padding: 3px 10px; border-radius: 999px; background: rgba(255,255,255,.14); font-size: .74rem; }
.vitals { display: grid; grid-template-columns: 1fr 1fr; gap: 14px; }
.vital { background: var(--ap-card); border-radius: var(--ap-r); border: .5px solid var(--ap-hair); box-shadow: var(--ap-shadow); padding: 16px; display: grid; gap: 6px; min-width: 0; }
.vital small { color: var(--ap-label2); font-weight: 600; font-size: .78rem; }
.vital b { font-size: 1.7rem; font-weight: 700; letter-spacing: -.03em; color: #111816; } .vital b em { font-style: normal; font-size: .8rem; color: var(--ap-label2); font-weight: 600; margin-left: 4px; }
.vital svg { width: 100%; height: 34px; }
.pd-appt { display: grid; gap: 12px; }
.pd-appt .doc { display: flex; align-items: center; gap: 12px; } .pd-appt .doc img { width: 54px; height: 54px; border-radius: 16px; object-fit: cover; background: var(--mint); }
.pd-appt .doc b { display: block; font-size: 1.02rem; } .pd-appt .doc small { color: var(--ap-label2); }
.pd-appt .when { display: flex; gap: 10px; flex-wrap: wrap; } .pd-appt .when span { display: inline-flex; align-items: center; gap: 6px; padding: 8px 12px; border-radius: 12px; background: #f4f6f5; font-weight: 600; font-size: .86rem; }
.prog-item { display: grid; gap: 8px; padding: 14px; border-radius: 16px; background: #f7f9f8; }
.prog-item .h { display: flex; align-items: center; gap: 10px; } .prog-item .h i { width: 34px; height: 34px; border-radius: 10px; display: grid; place-items: center; font-style: normal; background: #fff; }
.prog-item b { display: block; font-size: .92rem; } .prog-item small { color: var(--ap-label2); font-size: .76rem; }
.prog-item .f { display: flex; justify-content: space-between; font-size: .76rem; color: var(--ap-label2); font-weight: 600; }
.ask-ai .orb { width: 64px; margin: 4px auto 12px; display: block; }
.ask-ai p { color: rgba(234,255,246,.8); font-size: .86rem; margin: 0 0 6px; }
.ask-ai .sugg { display: flex; flex-wrap: wrap; gap: 8px; margin: 8px 0 4px; }
.ask-ai .sugg a { padding: 7px 12px; border-radius: 999px; background: rgba(255,255,255,.1); border: 1px solid rgba(255,255,255,.18); color: #fff; font-size: .78rem; text-decoration: none; }
/* profile (iOS settings style grouped list) */
.prof-card { display: flex; align-items: center; gap: 18px; flex-wrap: wrap; }
.prof-card img { width: 88px; height: 88px; border-radius: 28px; object-fit: cover; background: var(--mint); }
.prof-card h2 { margin: 0; font-size: 1.5rem; } .prof-card .tags { display: flex; gap: 8px; flex-wrap: wrap; margin-top: 8px; }
.prof-card .tags span { padding: 5px 10px; border-radius: 999px; background: #f4f6f5; font-size: .8rem; font-weight: 600; color: #33403c; }
.glist { background: var(--ap-card); border-radius: var(--ap-r); border: .5px solid var(--ap-hair); box-shadow: var(--ap-shadow); overflow: hidden; }
.glist-h { padding: 18px 18px 6px; font-size: .78rem; text-transform: uppercase; letter-spacing: .06em; color: var(--ap-label2); font-weight: 600; }
.grow { display: flex; align-items: center; gap: 14px; padding: 13px 18px; min-height: 52px; position: relative; }
.grow + .grow::before { content: ""; position: absolute; top: 0; left: 64px; right: 0; border-top: .5px solid var(--ap-hair); }
.grow i { width: 32px; height: 32px; border-radius: 9px; display: grid; place-items: center; color: #fff; font-style: normal; flex: none; }
.grow i svg { width: 18px; height: 18px; }
.grow .t { flex: 1; min-width: 0; } .grow .t b { display: block; font-weight: 500; color: #111816; font-size: .95rem; } .grow .t small { color: var(--ap-label2); }
.grow .v { color: var(--ap-label2); font-size: .9rem; } .grow .chev { color: #c4cac8; }
.g-prof { grid-template-columns: 1fr 1fr; align-items: start; }
@media (max-width: 1000px) { .g-pd, .g-pd2, .g-prof { grid-template-columns: 1fr; } }
@media (max-width: 640px) { .pd-wrap { padding: 14px; gap: 14px; } .vitals { gap: 10px; } .vital b { font-size: 1.4rem; } }

/* ============================================================
   Care Assistant: orb hero + voice mode (reference: medical AI app)
   ============================================================ */
.tri-hero { display: grid; justify-items: center; gap: 10px; padding: 18px 8px 6px; text-align: center; }
.tri-hero .orb { width: 92px; }
.tri-hero h3 { margin: 6px 0 0; font-size: 1.3rem; font-weight: 600; letter-spacing: -.02em; }
.tri-hero h3 span { color: var(--secondary); }
.tri-hero p { margin: 0; color: var(--ap-label2); font-size: .88rem; max-width: 460px; }
.tri-tiles { display: grid; grid-template-columns: 1fr 1fr; gap: 10px; width: 100%; max-width: 520px; margin-top: 6px; }
.tri-tile { display: grid; gap: 8px; padding: 14px; border-radius: 18px; border: .5px solid var(--ap-hair); background: #fff; text-align: left; cursor: pointer; font-family: var(--font-ui); box-shadow: 0 1px 2px rgba(0,0,0,.04); transition: transform .15s, box-shadow .2s; }
.tri-tile:hover { box-shadow: 0 8px 24px rgba(16,40,32,.08); } .tri-tile:active { transform: scale(.98); }
.tri-tile b { font-size: .92rem; color: #111816; } .tri-tile small { color: var(--ap-label2); font-size: .74rem; }
.tri-tile .picto { width: 34px; height: 34px; }
.tri-tile--sos b { color: #d92d20; }
.tri-av.orb-host { background: transparent; } .tri-av .orb--sm { width: 40px; }
.tri { position: relative; }
.tri-vm { position: absolute; inset: 0; z-index: 5; display: flex; flex-direction: column; align-items: center; justify-content: space-between; padding: 26px 20px 22px; text-align: center;
  background: linear-gradient(180deg, #ffffff 0%, #eefaf4 55%, #d9f4e8 100%); opacity: 0; visibility: hidden; transition: opacity .3s, visibility .3s; }
.tri-vm.is-on { opacity: 1; visibility: visible; }
.tri-vm-top { display: flex; justify-content: space-between; width: 100%; }
.tri-vm-top button { width: 42px; height: 42px; border-radius: 50%; border: 0; background: #fff; box-shadow: 0 2px 8px rgba(0,0,0,.08); display: grid; place-items: center; cursor: pointer; color: #2b3633; }
.tri-vm .orb { width: min(170px, 42vw); }
.tri-vm-lines { display: grid; gap: 6px; max-width: 520px; min-height: 120px; align-content: center; }
.tri-vm-lines .prev { color: #a3acaa; font-size: .95rem; line-height: 1.35; }
.tri-vm-lines .now { color: #111816; font-size: 1.25rem; font-weight: 500; line-height: 1.35; letter-spacing: -.01em; }
.tri-vm-lines .state { font-size: .78rem; text-transform: uppercase; letter-spacing: .12em; color: var(--secondary); font-weight: 700; }
.tri-wave { display: flex; align-items: center; justify-content: center; gap: 3px; height: 46px; width: 100%; max-width: 420px; }
.tri-wave i { width: 3px; border-radius: 3px; background: #c6d9d2; height: 4px; transition: height .12s ease; }
.tri-wave.is-live i { background: linear-gradient(180deg, #34d399, #0d6e53); }
.tri-vm-ctrls { display: flex; gap: 14px; align-items: center; }
.tri-vm-ctrls button { width: 56px; height: 56px; border-radius: 50%; border: 0; display: grid; place-items: center; cursor: pointer; }
.tri-vm-ctrls .kb { background: #fff; color: #2b3633; box-shadow: 0 2px 8px rgba(0,0,0,.08); }
.tri-vm-ctrls .main { width: 68px; height: 68px; background: linear-gradient(135deg, #10b981, #0d6e53); color: #fff; box-shadow: 0 10px 24px rgba(13,110,83,.35); }

/* fixes after visual review */
.sd-btn { white-space: nowrap; }
@media (max-width: 900px) { .sd-folders { align-items: center; } .sd-f { flex: none; } .sd-thread-h { flex-wrap: wrap; } }

/* ============================================================
   Theme switch button (header) + DARK THEME
   Brand greens, gradients and buttons stay exactly the same; only surfaces and text adapt.
   ============================================================ */
.theme-toggle { width: 40px; height: 40px; flex: none; border-radius: 50%; border: 1px solid var(--line); background: var(--surface); color: var(--ink); display: grid; place-items: center; cursor: pointer; transition: transform .2s, background .2s; }
.theme-toggle:hover { transform: rotate(-12deg); } .theme-toggle:active { transform: scale(.92); }
.theme-toggle .tt-sun { display: none; }
[data-theme="dark"] .theme-toggle .tt-sun { display: block; color: #ffd66b; } [data-theme="dark"] .theme-toggle .tt-moon { display: none; }
@media (max-width: 760px) { .header-actions .theme-toggle { width: 38px; height: 38px; } }

[data-theme="dark"] {
  color-scheme: dark;
  --mint: #12342b; --mint-2: #174236; --dark: #e9f7f1; --ink: #d9e7e2; --muted: #9db3ac; --line: #22392f;
  --surface: #0f1b17; --bg: #08120f; --warn-bg: #2a2210; --warn-ink: #f2c46a; --danger: #ff8a65;
  --shadow-sm: 0 1px 2px rgba(0,0,0,.4), 0 2px 8px rgba(0,0,0,.3); --shadow: 0 6px 24px rgba(0,0,0,.45); --shadow-lg: 0 24px 60px rgba(0,0,0,.55);
  --ap-bg: #08120f; --ap-card: #0f1b17; --ap-fill: rgba(255,255,255,.08); --ap-hair: rgba(255,255,255,.08); --ap-label2: #9db3ac;
  --ap-glass: rgba(10,20,17,.72); --ap-shadow: 0 1px 1px rgba(0,0,0,.3), 0 10px 30px rgba(0,0,0,.35);
}
/* elements whose background is the brand deep green stay deep green */
[data-theme="dark"] :is(.skip-link, .demo-banner, .site-footer, .toast, .admin-side, .tri-head, .tri-chip--done) { background-color: #0b382e; }
[data-theme="dark"] .site-footer { background: linear-gradient(180deg, #0b2a22, #061813); }
[data-theme="dark"] .final-cta { background: radial-gradient(800px 400px at 90% 10%, rgba(52,211,153,.35), transparent 60%), linear-gradient(135deg, #0d6e53 0%, #0b382e 100%); }
[data-theme="dark"] .demo-banner, [data-theme="dark"] .site-footer, [data-theme="dark"] .toast { color: #e9f7f1; }
/* cards & controls: white → dark green glass */
[data-theme="dark"] :is(.card, .panel, .btn--ghost, .book-bar, .hero .book-bar .loc, .quick-services, .svc-tile, .why-tiles div, .doc-card, .story-card,
  .service-card, .why-item, .empty-note, .stories-empty, .step .ic, .input, .select, textarea.input, .stepper, .option, .icon-btn, .review-item, .side-nav,
  .track-doc, .dash-hello, .followup, .svc-card, .faq details, .mobile-nav.is-open, .adm-doc-table select, .doc-card--poster, .doc-card--poster .doc-body,
  .sc, .tri, .tri-msg--bot, .tri-chip, .tri-input, .tri-foot, .tri-note, .glist, .vital, .ico-btn, .btn--soft, .ops-search, .tri-tile, .tri-text, .bill) {
  background: #0f1b17; border-color: rgba(255,255,255,.08); color: var(--ink); }
[data-theme="dark"] :is(.sched-row, .res-row, .prog-item, .tri-strip, .prog-item .h i, .pd-appt .when span, .prof-card .tags span) { background: #15241f; }
[data-theme="dark"] .alert-row { border-color: rgba(255,255,255,.08); } [data-theme="dark"] .alert-row i, [data-theme="dark"] .res-row i { filter: saturate(.9); }
[data-theme="dark"] .seg .is-on, [data-theme="dark"] .seg [aria-selected="true"], [data-theme="dark"] .seg [aria-current="page"] { background: #22352f; color: #fff; box-shadow: 0 1px 3px rgba(0,0,0,.4); }
[data-theme="dark"] .seg a, [data-theme="dark"] .seg button, [data-theme="dark"] .panel-h .more { color: #cfe0da; }
[data-theme="dark"] .option:has(input:checked) { background: #12342b; border-color: var(--secondary); }
[data-theme="dark"] .input:focus, [data-theme="dark"] .select:focus, [data-theme="dark"] .tri-text:focus { background: #13221d; }
[data-theme="dark"] .btn--ghost { color: #8ff0cb; }
[data-theme="dark"] .notice { background: #1d1a10; border-color: #4a3d16; color: #f2dca6; }
[data-theme="dark"] .demo-tag { background: #3a2f12; color: #ffd98a; border-color: #5c4a1c; }
/* light mint sections → deep green gradient */
[data-theme="dark"] .section--mint { background: linear-gradient(180deg, #0c1f1a 0%, #0a1714 100%); }
[data-theme="dark"] .hero { background: radial-gradient(1200px 600px at 85% 20%, rgba(0,169,130,.22) 0%, rgba(0,169,130,0) 60%), linear-gradient(180deg, #0b1a16 0%, #08120f 100%); }
[data-theme="dark"] .page-hero { background: radial-gradient(900px 400px at 85% 0%, rgba(0,169,130,.2), transparent 60%), #0a1612; }
[data-theme="dark"] .poster { background: radial-gradient(900px 500px at 50% 30%, rgba(0,169,130,.25), transparent 65%), linear-gradient(180deg, #0b1a16, #08120f); }
[data-theme="dark"] .poster::after { background: linear-gradient(180deg, rgba(8,18,15,0), #08120f); }
[data-theme="dark"] .poster-stage::before { background: radial-gradient(closest-side, rgba(52,211,153,.18), rgba(52,211,153,0)); }
[data-theme="dark"] .story { background: linear-gradient(120deg, #0f2721 0%, #0b1a16 100%); border-color: rgba(255,255,255,.08); }
[data-theme="dark"] .dc-stage { background: radial-gradient(circle at 50% 78%, rgba(52,211,153,.28) 0 26%, rgba(52,211,153,0) 60%), linear-gradient(180deg, #11312a 0%, #0c1f1a 100%); }
[data-theme="dark"] .hero-halo { background: radial-gradient(circle, rgba(0,169,130,.3) 0%, rgba(0,169,130,0) 70%); }
[data-theme="dark"] :is(.ops, .pd) { background: radial-gradient(1200px 600px at 85% -10%, rgba(0,169,130,.18) 0%, rgba(0,169,130,0) 60%), #08120f; }
[data-theme="dark"] .ops-bar { background: rgba(8,18,15,.78); }
[data-theme="dark"] .ops-hello { background: linear-gradient(135deg, #10201b, #0c1915); }
[data-theme="dark"] .ops-visual { background: radial-gradient(circle at 60% 40%, rgba(52,211,153,.3) 0%, #0f2620 55%, #0b1a16 100%); }
[data-theme="dark"] .chip-glass { background: rgba(15,27,23,.75); border-color: rgba(255,255,255,.12); color: var(--ap-label2); }
[data-theme="dark"] .glass { background: rgba(15,27,23,.7); border-color: rgba(255,255,255,.14); color: var(--ink); }
[data-theme="dark"] .hero-band { background: linear-gradient(120deg, rgba(15,27,23,.95), rgba(15,27,23,.75)), radial-gradient(600px 300px at 90% 50%, rgba(255,105,140,.2), transparent 60%); border-color: rgba(255,255,255,.08); }
[data-theme="dark"] .tri-log { background: linear-gradient(180deg, #0c1915, #0f1b17); }
[data-theme="dark"] .tri-vm { background: linear-gradient(180deg, #0f1b17 0%, #0c211b 55%, #0a2a21 100%); }
[data-theme="dark"] .tri-vm-top button, [data-theme="dark"] .tri-vm-ctrls .kb { background: #1a2b26; color: #e9f7f1; }
[data-theme="dark"] .tri-vm-lines .prev { color: #6f857e; }
[data-theme="dark"] .tri-tests { background: linear-gradient(180deg, #0f2520, #0f1b17); border-color: rgba(52,211,153,.25); }
[data-theme="dark"] .tri-warn { background: #2a2210; border-color: #5c4a1c; color: #f2dca6; }
[data-theme="dark"] .tri-msg:has(.tri-sos) { background: #2a1210; border-color: #6b2a24; }
[data-theme="dark"] .sc-art { background: linear-gradient(180deg, #11312a, #0c1f1a); }
[data-theme="dark"] .tbl td { border-color: rgba(255,255,255,.07); }
[data-theme="dark"] .prog { background: rgba(255,255,255,.08); }
[data-theme="dark"] .grow + .grow::before { border-color: rgba(255,255,255,.08); }
/* hard-coded near-black text in dashboards → light */
[data-theme="dark"] :is(.stat b, .stat .top, .tbl .who b, .vital b, .rgauge .v b, .grow .t b, .tri-tile b, .tri-vm-lines .now, .ops-hello h1, .ops-me, .sched-row .who b,
  .res-row b, .res-row span.n, .alert-row b, .prog-item b, .tl b, .pd-top h1, .prof-card h2, .panel-h h2, .panel-h h3, .concern-row, .doc-card--poster .doc-body h3, .dc-go) { color: #eef8f4; }
[data-theme="dark"] #ops-line, [data-theme="dark"] #ops-donut { color: #eef8f4; }
[data-theme="dark"] .pill--grey { background: rgba(255,255,255,.08); color: #b9c8c3; }
[data-theme="dark"] .pill--green { background: rgba(52,199,89,.16); color: #6ee7a0; } [data-theme="dark"] .pill--blue { background: rgba(10,132,255,.18); color: #7cc0ff; }
[data-theme="dark"] .pill--orange { background: rgba(255,149,0,.16); color: #ffbe5c; } [data-theme="dark"] .pill--red { background: rgba(255,59,48,.18); color: #ff8a80; }
[data-theme="dark"] .pill--purple { background: rgba(175,82,222,.2); color: #e0a8ff; }
[data-theme="dark"] .status--prog, [data-theme="dark"] .status--done { filter: brightness(.9); }
[data-theme="dark"] .why-photo--soft img, [data-theme="dark"] .story-photo img { filter: brightness(.92); }
[data-theme="dark"] img.av, [data-theme="dark"] .dc-figure { filter: none; }

/* ===== Medication chart (patient dashboard; reference: MediFlex "Medications") ===== */
.med-grid { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 10px; }
.med-row { display: flex; align-items: center; gap: 12px; padding: 12px; border-radius: 16px; background: #f7f9f8; min-width: 0; }
.med-ic { --c: #00a982; width: 40px; height: 40px; flex: none; border-radius: 12px; display: grid; place-items: center; font-size: 1.1rem; background: color-mix(in srgb, var(--c) 14%, #fff); box-shadow: inset 0 0 0 1px color-mix(in srgb, var(--c) 25%, transparent); }
.med-ic.sm { width: 34px; height: 34px; border-radius: 10px; font-size: .95rem; }
.med-t { flex: 1; min-width: 0; } .med-t b { display: block; font-size: .92rem; } .med-t small { display: block; color: var(--ap-label2); font-size: .76rem; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.med-d { text-align: right; flex: none; } .med-d b { display: block; font-size: .78rem; padding: 3px 8px; border-radius: 8px; background: #fff; box-shadow: 0 1px 2px rgba(0,0,0,.06); } .med-d small { color: var(--ap-label2); font-size: .7rem; }
.med-sched { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 12px; }
.med-slot { padding: 14px; border-radius: 18px; background: #f7f9f8; display: grid; gap: 8px; align-content: start; }
.med-slot-h { display: flex; justify-content: space-between; align-items: baseline; } .med-slot-h small { color: var(--ap-label2); font-weight: 600; }
.med-dose { display: flex; align-items: center; gap: 10px; padding: 10px; border-radius: 14px; background: #fff; cursor: pointer; box-shadow: 0 1px 2px rgba(0,0,0,.05); }
.med-dose input { width: 20px; height: 20px; accent-color: var(--ap-green); flex: none; }
.med-dose b { display: block; font-size: .86rem; } .med-dose small { color: var(--ap-label2); font-size: .74rem; }
.med-dose:has(input:checked) { opacity: .6; } .med-dose:has(input:checked) b { text-decoration: line-through; }
.med-chip { display: inline-block; margin: 0 4px 4px 0; padding: 3px 8px; border-radius: 8px; background: var(--mint); color: var(--primary); font-size: .74rem; font-weight: 700; }
.med-date { display: block; font-weight: 600; font-size: .84rem; } .med-date.old { font-weight: 500; color: var(--ap-label2); font-size: .78rem; }
.med-count { display: inline-grid; place-items: center; min-width: 34px; height: 28px; padding: 0 8px; border-radius: 999px; background: #eef7ff; color: #0a6fdc; font-weight: 800; font-size: .84rem; }
.med-tbl td { white-space: normal; vertical-align: top; } .med-tbl td:first-child { white-space: nowrap; }
@media (max-width: 1000px) { .med-grid { grid-template-columns: 1fr 1fr; } .med-sched { grid-template-columns: 1fr; } }
@media (max-width: 640px) { .med-grid { grid-template-columns: 1fr; } }
[data-theme="dark"] :is(.med-row, .med-slot) { background: #15241f; }
[data-theme="dark"] :is(.med-dose, .med-d b) { background: #0f1b17; box-shadow: none; color: #eef8f4; }
[data-theme="dark"] .med-ic { background: color-mix(in srgb, var(--c) 22%, #0f1b17); }
[data-theme="dark"] .med-count { background: rgba(10,132,255,.18); color: #7cc0ff; }
[data-theme="dark"] :is(.med-t b, .med-dose b, .med-slot-h b, .med-date) { color: #eef8f4; }

/* ===== Care calendar (patient dashboard; reference: MediCore day/time timeline) ===== */
.cal-legend { display: flex; flex-wrap: wrap; gap: 6px 14px; font-size: .76rem; color: var(--ap-label2); }
.cal-legend span { display: inline-flex; align-items: center; gap: 6px; } .cal-legend span::before { content: ""; width: 9px; height: 9px; border-radius: 3px; background: var(--c); }
.cal-scroll { overflow-x: auto; margin: 0 -4px; padding: 0 4px 4px; }
.cal { min-width: 820px; }
.cal-head { display: grid; grid-template-columns: 56px repeat(7, minmax(0, 1fr)); gap: 0; margin-bottom: 8px; }
.cal-head span { text-align: center; font-size: .8rem; font-weight: 600; color: var(--ap-label2); padding: 8px 4px; }
.cal-head .is-today { background: var(--ap-fill); border-radius: 10px; color: #111816; }
.cal-body { position: relative; }
.cal-hr { position: absolute; left: 0; width: 100%; transform: translateY(-50%); font-size: .72rem; color: var(--ap-label2); font-weight: 600; pointer-events: none; }
.cal-hr::after { content: ""; position: absolute; left: 56px; right: 0; top: 50%; border-top: 1px dashed rgba(16,40,32,.08); }
.cal-col { position: absolute; top: 0; bottom: 0; width: 0; border-left: 1px solid rgba(16,40,32,.06); }
.cal-now { position: absolute; left: 0; right: 0; height: 0; border-top: 1.5px solid #ff3b30; z-index: 3; }
.cal-now b { position: absolute; left: 0; top: -10px; padding: 1px 7px; border-radius: 999px; background: #ff3b30; color: #fff; font-size: .68rem; }
.cal-ev { position: absolute; z-index: 2; width: calc((100% - 56px) / 7 * 1.6 - 8px); display: flex; align-items: center; gap: 8px; padding: 6px 10px 6px 6px; border-radius: 14px;
  background: #fff; box-shadow: 0 6px 18px rgba(16,40,32,.08), inset 0 0 0 1px color-mix(in srgb, var(--c) 22%, transparent); border-left: 3px solid var(--c); transition: transform .15s; }
.cal-ev:hover { transform: translateY(-2px); z-index: 4; }
.cal-ev b { display: block; font-size: .8rem; line-height: 1.2; color: #111816; } .cal-ev small { display: block; font-size: .68rem; color: var(--ap-label2); line-height: 1.25; }
.cal-ic { width: 28px; height: 28px; border-radius: 9px; flex: none; display: grid; place-items: center; font-size: .85rem; background: color-mix(in srgb, var(--c) 14%, #fff); }
.cal-up { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 10px; margin-top: 16px; }
.cal-up-h { grid-column: 1 / -1; font-size: .86rem; }
.cal-up-row { display: flex; align-items: center; gap: 10px; padding: 10px; border-radius: 14px; background: #f7f9f8; }
.cal-up-row b { display: block; font-size: .86rem; } .cal-up-row small { color: var(--ap-label2); font-size: .74rem; }
@media (max-width: 900px) { .cal-up { grid-template-columns: 1fr; } }
[data-theme="dark"] .cal-ev { background: #13221d; box-shadow: 0 6px 18px rgba(0,0,0,.35), inset 0 0 0 1px color-mix(in srgb, var(--c) 35%, transparent); }
[data-theme="dark"] :is(.cal-ev b, .cal-up-row b, .cal-head .is-today) { color: #eef8f4; }
[data-theme="dark"] .cal-ic { background: color-mix(in srgb, var(--c) 22%, #0f1b17); }
[data-theme="dark"] .cal-up-row { background: #15241f; }
[data-theme="dark"] .cal-hr::after, [data-theme="dark"] .cal-col { border-color: rgba(255,255,255,.07); }
[data-theme="dark"] .med-chip { color: #8ff0cb; background: rgba(52,211,153,.14); }
[data-theme="dark"] :is(.crumbs a, .nav a[aria-current="page"], .link-arrow, .linklike, .dc-go, .poster-crumbs a, .tri-foot a, .sample-note a, .tbl a, .mobile-nav a) { color: #6ee7b7; }
[data-theme="dark"] .nav a[aria-current="page"] { background: rgba(52,211,153,.12); }
[data-theme="dark"] .btn--dark { background: linear-gradient(135deg, #00a982, #0d6e53); color: #fff; }

/* header fit with theme toggle + "Book your doctor" CTA; hero lettering never clipped */
.nav a { white-space: nowrap; }
@media (max-width: 1180px) { .site-header .container { gap: 12px; } .nav { gap: 0; } .nav a { padding-left: 9px; padding-right: 9px; font-size: .9rem; } .header-actions { gap: 8px; } .header-actions .btn--sm { padding: 10px 14px; } }
.hero-word { font-size: min(8.4rem, calc(96cqw / (8 * .72))); }

/* ===== Medicine reminders: header bell, dose panel, reminder card ===== */
.rem-bell { position: relative; width: 40px; height: 40px; flex: none; border-radius: 50%; border: 1px solid var(--line); background: var(--surface); color: var(--ink); display: grid; place-items: center; cursor: pointer; }
.rem-bell.has-due svg { animation: remRing 1.2s ease-in-out infinite; transform-origin: 50% 10%; }
@keyframes remRing { 0%, 60%, 100% { transform: rotate(0); } 10%, 30% { transform: rotate(14deg); } 20%, 40% { transform: rotate(-14deg); } }
.rem-badge { position: absolute; top: -3px; right: -3px; min-width: 18px; height: 18px; padding: 0 5px; border-radius: 999px; background: #ff3b30; color: #fff; font-size: .68rem; font-weight: 800; display: grid; place-items: center; border: 2px solid var(--surface); }
.rem-panel { position: fixed; z-index: 120; width: min(380px, calc(100vw - 20px)); max-height: min(560px, calc(100vh - 100px)); overflow-y: auto; padding: 14px; border-radius: 22px;
  background: rgba(255,255,255,.92); backdrop-filter: saturate(180%) blur(24px); -webkit-backdrop-filter: saturate(180%) blur(24px); border: 1px solid var(--ap-hair); box-shadow: 0 24px 60px rgba(16,40,32,.2); }
.rem-h { display: flex; justify-content: space-between; align-items: center; margin-bottom: 10px; } .rem-h a { font-size: .82rem; font-weight: 600; }
.rem-set { display: grid; gap: 2px; padding: 4px; border-radius: 16px; background: var(--ap-fill); margin-bottom: 12px; }
.rem-sw { display: flex; align-items: center; justify-content: space-between; gap: 10px; padding: 8px 10px; cursor: pointer; }
.rem-sw b { display: block; font-size: .88rem; } .rem-sw small { color: var(--ap-label2); font-size: .72rem; }
.rem-list-h { font-size: .74rem; text-transform: uppercase; letter-spacing: .06em; color: var(--ap-label2); font-weight: 700; margin: 4px 4px 8px; }
.rem-list { display: grid; grid-template-columns: minmax(0, 1fr); gap: 8px; }
.rem-badge[hidden] { display: none; } .rem-row .pill { flex: none; }
.rem-row { display: flex; align-items: center; gap: 10px; padding: 10px; border-radius: 14px; background: #f7f9f8; }
.rem-row.is-due { background: #fff1f0; box-shadow: inset 0 0 0 1px #ffc9c4; } .rem-row.is-taken { opacity: .6; } .rem-row.is-taken b { text-decoration: line-through; }
.rem-t { flex: 1; min-width: 0; } .rem-t b { display: block; font-size: .86rem; } .rem-t small { display: block; color: var(--ap-label2); font-size: .72rem; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.rem-mini { border: 0; border-radius: 999px; padding: 6px 12px; font: 700 .76rem var(--font-ui); background: var(--secondary); color: #fff; cursor: pointer; flex: none; }
.rem-mini.ghost { background: var(--ap-fill); color: var(--ink); }
.rem-empty { color: var(--ap-label2); font-size: .86rem; text-align: center; margin: 12px 0; }
.rem-foot { display: grid; gap: 6px; margin-top: 12px; } .rem-foot small { color: var(--ap-label2); font-size: .72rem; text-align: center; }
.rem-test { border: 1px dashed var(--secondary); background: transparent; color: var(--primary); border-radius: 12px; padding: 9px; font: 700 .84rem var(--font-ui); cursor: pointer; }
.rem-card { position: fixed; z-index: 130; right: 20px; bottom: 20px; width: min(380px, calc(100vw - 24px)); padding: 16px; border-radius: 24px;
  background: rgba(255,255,255,.94); backdrop-filter: saturate(180%) blur(24px); -webkit-backdrop-filter: saturate(180%) blur(24px); border: 1px solid rgba(0,169,130,.25);
  box-shadow: 0 30px 70px rgba(16,40,32,.28), 0 0 0 6px rgba(52,211,153,.12); transform: translateY(140%); opacity: 0; transition: transform .45s cubic-bezier(.2,.9,.3,1.2), opacity .3s; }
.rem-card.is-on { transform: none; opacity: 1; animation: remPulse 2s ease-in-out infinite; }
@keyframes remPulse { 50% { box-shadow: 0 30px 70px rgba(16,40,32,.28), 0 0 0 12px rgba(52,211,153,.18); } }
.rem-card-h { display: flex; align-items: center; gap: 10px; margin-bottom: 10px; } .rem-card-h b { display: block; font-size: 1.02rem; } .rem-card-h small { color: var(--ap-label2); font-size: .76rem; }
.rem-x { margin-left: auto; width: 30px; height: 30px; border-radius: 50%; border: 0; background: var(--ap-fill); color: var(--ink); cursor: pointer; }
.rem-card-row { display: flex; align-items: center; gap: 10px; padding: 10px; border-radius: 14px; background: #f4fbf8; margin-bottom: 8px; }
.rem-card-row b { display: block; font-size: .92rem; } .rem-card-row small { color: var(--ap-label2); font-size: .76rem; }
.rem-card-a { display: flex; gap: 8px; margin-top: 4px; } .rem-card-a .btn { flex: 1; }
.rem-card-note { display: block; margin-top: 8px; color: var(--ap-label2); font-size: .7rem; text-align: center; }
@media (max-width: 640px) { .rem-card { right: 12px; left: 12px; bottom: 12px; width: auto; } .header-actions .rem-bell { width: 38px; height: 38px; } }
@media (prefers-reduced-motion: reduce) { .rem-bell.has-due svg, .rem-card.is-on { animation: none; } }
[data-theme="dark"] :is(.rem-panel, .rem-card) { background: rgba(15,27,23,.95); border-color: rgba(255,255,255,.1); box-shadow: 0 24px 60px rgba(0,0,0,.55); }
[data-theme="dark"] :is(.rem-row, .rem-card-row) { background: #15241f; }
[data-theme="dark"] .rem-row.is-due { background: #2a1513; box-shadow: inset 0 0 0 1px #6b2a24; }
[data-theme="dark"] :is(.rem-t b, .rem-sw b, .rem-card-h b, .rem-card-row b, .rem-h b) { color: #eef8f4; }
[data-theme="dark"] .rem-test { color: #6ee7b7; } [data-theme="dark"] .rem-h a { color: #6ee7b7; }
.med-dose.is-due { box-shadow: inset 0 0 0 1.5px #ff3b30; } .med-dose.is-due small { color: #d92d20; } [data-theme="dark"] .med-dose.is-due small { color: #ff8a80; }

/* ---------- Home: patient dashboard phone preview (follows light / dark theme) ---------- */
.phone-screen.ps { --ps-bg: linear-gradient(180deg, #eefaf5 0%, #f7f9f8 60%); --ps-card: #fff; --ps-ink: #111816; --ps-sub: #6b7773; --ps-hair: rgba(0,0,0,.06); --ps-fill: rgba(118,128,124,.12);
  background: var(--ps-bg); padding: 14px 14px 12px; gap: 9px; min-height: 580px; position: relative; overflow: hidden; color: var(--ps-ink); font-family: var(--font-ui, inherit); }
.ps .p-card { background: var(--ps-card); border: .5px solid var(--ps-hair); border-radius: 18px; padding: 11px; box-shadow: 0 6px 18px rgba(11,56,46,.07); }
.ps small { color: var(--ps-sub); font-size: .66rem; font-weight: 600; display: block; }
.ps-status { display: flex; justify-content: space-between; align-items: center; padding: 0 10px; font-size: .72rem; height: 18px; }
.ps-status span { display: flex; gap: 2px; align-items: flex-end; } .ps-status i { width: 3px; background: currentColor; border-radius: 1px; }
.ps-status i:nth-child(1) { height: 5px; } .ps-status i:nth-child(2) { height: 7px; } .ps-status i:nth-child(3) { height: 9px; }
.ps-status em { width: 18px; height: 9px; border: 1.5px solid currentColor; border-radius: 3px; margin-left: 4px; background: linear-gradient(90deg, currentColor 70%, transparent 0) content-box; padding: 1px; }
.ps-top { display: flex; align-items: center; gap: 8px; margin-top: 8px; }
.ps-top > div { flex: 1; } .ps-top b { font-size: 1.3rem; letter-spacing: -.03em; display: block; line-height: 1.1; }
.ps-bell, .ps-av { width: 32px; height: 32px; border-radius: 50%; display: grid; place-items: center; background: var(--ps-card); border: .5px solid var(--ps-hair); font-size: .85rem; position: relative; flex: none; }
.ps-bell i { position: absolute; top: -3px; right: -3px; min-width: 15px; height: 15px; border-radius: 999px; background: #ff3b30; color: #fff; font: 800 .58rem/15px var(--font-ui, inherit); font-style: normal; text-align: center; }
.ps-av { background: linear-gradient(135deg, #00a982, #0d6e53); color: #fff; font-weight: 800; font-size: .8rem; border: 0; }
.ps .ps-hero { display: flex; align-items: center; gap: 12px; color: #fff; border: 0; padding: 14px; background: radial-gradient(160px 120px at 100% 0%, rgba(255,255,255,.22), transparent 60%), linear-gradient(135deg, #00a982 0%, #0d6e53 100%); box-shadow: 0 12px 26px rgba(13,110,83,.32); }
.ps-hero small { color: rgba(255,255,255,.8); } .ps-hero b { display: block; font-size: 1rem; } .ps-hero span { display: block; font-size: .66rem; opacity: .9; margin-top: 2px; }
.ps-ring { --p: 70; width: 58px; height: 58px; border-radius: 50%; flex: none; display: grid; place-items: center; background: conic-gradient(#fff calc(var(--p) * 1%), rgba(255,255,255,.22) 0); position: relative; }
.ps-ring::before { content: ""; position: absolute; inset: 6px; border-radius: 50%; background: #0b8a68; }
.ps-ring b { position: relative; font-size: .82rem; }
.ps .ps-rem { display: flex; align-items: center; gap: 10px; background: #fff7ed; box-shadow: inset 0 0 0 1px #ffd9a8, 0 6px 18px rgba(255,149,0,.12); border: 0; }
.ps-rem > div { flex: 1; min-width: 0; } .ps-rem small { color: #c56a00; } .ps-rem b { font-size: .8rem; display: block; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.ps-ic { width: 32px; height: 32px; border-radius: 10px; display: grid; place-items: center; background: rgba(255,149,0,.16); flex: none; }
.ps-take { background: #00a982; color: #fff; font-size: .66rem; font-weight: 800; padding: 6px 10px; border-radius: 999px; flex: none; }
.ps-week-h { display: flex; justify-content: space-between; align-items: baseline; margin-bottom: 8px; } .ps-week-h b { font-size: .8rem; }
.ps-days { display: grid; grid-template-columns: repeat(7, 1fr); gap: 3px; text-align: center; }
.ps-days span { font-size: .58rem; color: var(--ps-sub); font-weight: 700; padding: 5px 0 6px; border-radius: 10px; position: relative; display: grid; gap: 2px; justify-items: center; }
.ps-days b { font-size: .78rem; color: var(--ps-ink); }
.ps-days .on { background: linear-gradient(180deg, #00a982, #0d6e53); color: rgba(255,255,255,.85); } .ps-days .on b { color: #fff; }
.ps-days i { width: 5px; height: 5px; border-radius: 50%; } .ps-days i.g { background: #00a982; } .ps-days i.b { background: #fff; } .ps-days i.o { background: #ff9500; }
.ps-vitals { display: grid; grid-template-columns: 1fr 1fr; gap: 9px; }
.ps-vitals b { font-size: 1.15rem; letter-spacing: -.03em; display: block; } .ps-vitals em { font-style: normal; font-size: .62rem; color: var(--ps-sub); margin-left: 2px; }
.ps-vitals svg { width: 100%; height: 20px; display: block; margin-top: 2px; }
.ps-tabs { position: absolute; left: 10px; right: 10px; bottom: 10px; display: grid; grid-template-columns: repeat(5, 1fr); padding: 7px 4px; border-radius: 22px; background: color-mix(in srgb, var(--ps-card) 82%, transparent); backdrop-filter: blur(14px); -webkit-backdrop-filter: blur(14px); border: .5px solid var(--ps-hair); box-shadow: 0 8px 22px rgba(0,0,0,.1); }
.ps-tabs span { display: grid; justify-items: center; font-size: .82rem; filter: grayscale(1); opacity: .6; }
.ps-tabs span.on { filter: none; opacity: 1; } .ps-tabs span.on small { color: #00a982; }
.ps-tabs small { font-size: .52rem; }
.ps-tag { justify-self: center; margin-top: 2px; margin-bottom: 52px; }
[data-theme="dark"] .phone-screen.ps { --ps-bg: linear-gradient(180deg, #0c1f1a 0%, #08120f 60%); --ps-card: #13221d; --ps-ink: #eef8f4; --ps-sub: #9db3ac; --ps-hair: rgba(255,255,255,.08); }
[data-theme="dark"] .ps .p-card { box-shadow: 0 6px 18px rgba(0,0,0,.35); }
[data-theme="dark"] .ps .ps-hero { box-shadow: 0 12px 26px rgba(0,169,130,.22); }
[data-theme="dark"] .ps .ps-rem { background: #2a1d0c; box-shadow: inset 0 0 0 1px #5c3b10; } [data-theme="dark"] .ps-rem small { color: #ffb44d; }
[data-theme="dark"] .phone { background: #050b09; box-shadow: 0 0 0 1px rgba(255,255,255,.08), 0 30px 60px rgba(0,0,0,.55); } [data-theme="dark"] .phone::before { background: #050b09; }
[data-theme="dark"] .phone-stage::before { background: radial-gradient(circle, rgba(0,169,130,.22), rgba(0,169,130,0) 70%); }
.ps .ps-week, .ps .ps-vitals .p-card { display: block; } .ps .ps-vitals .p-card { padding: 10px 11px 8px; min-width: 0; }

/* ---------- DocSahab AI: floating button + chat drawer ---------- */
.ai-fab { position: fixed; z-index: 110; right: 20px; bottom: 20px; display: flex; align-items: center; gap: 10px; padding: 8px 18px 8px 8px; border: 0; border-radius: 999px; cursor: pointer;
  background: linear-gradient(135deg, #00a982, #0d6e53); color: #fff; font: 700 .9rem var(--font-ui, inherit); box-shadow: 0 14px 34px rgba(13,110,83,.38), inset 0 1px 0 rgba(255,255,255,.25); transition: transform .2s, box-shadow .2s; }
.ai-fab:hover { transform: translateY(-2px); box-shadow: 0 18px 40px rgba(13,110,83,.45); }
.ai-fab .orb { width: 34px; height: 34px; flex: none; }
.ai-open .ai-fab { opacity: 0; pointer-events: none; }
.ai-drawer { position: fixed; inset: 0; z-index: 140; display: flex; justify-content: flex-end; align-items: flex-end; padding: 16px; background: rgba(6,20,16,0); pointer-events: none; transition: background .25s; }
.ai-drawer.is-on { background: rgba(6,20,16,.35); pointer-events: auto; }
.ai-drawer-card { position: relative; width: min(460px, 100%); max-height: calc(100vh - 32px); border-radius: 28px; overflow: hidden; transform: translateY(24px) scale(.98); opacity: 0; transition: transform .3s cubic-bezier(.2,.8,.2,1), opacity .25s; box-shadow: 0 30px 80px rgba(0,0,0,.3); }
.ai-drawer.is-on .ai-drawer-card { transform: none; opacity: 1; }
.ai-drawer .tri { border-radius: 28px; border: 0; }
.ai-drawer .tri-head { padding-right: 58px; }
.ai-drawer .tri-log { height: min(58vh, 520px); }
.ai-drawer .tri-tiles { grid-template-columns: 1fr 1fr; }
.ai-drawer .tri-alt { display: none; }
.ai-x { position: absolute; top: 14px; right: 14px; z-index: 6; width: 34px; height: 34px; border-radius: 50%; border: 1px solid rgba(255,255,255,.35); background: rgba(255,255,255,.18); color: #fff; font-size: .9rem; cursor: pointer; backdrop-filter: blur(8px); }
.tri-links { display: flex; flex-wrap: wrap; gap: 8px; margin-top: 10px; }
.tri-link { display: inline-flex; align-items: center; padding: 7px 12px; border-radius: 999px; border: 0; background: #e6faf3; color: #0d6e53; font: 700 .8rem var(--font-ui, inherit); text-decoration: none; cursor: pointer; }
.tri-link:hover { background: #cff3e5; color: #0b382e; }
@media (max-width: 640px) {
  .ai-fab { right: 12px; bottom: 12px; padding: 6px; } .ai-fab-t { display: none; } .ai-fab .orb { width: 42px; height: 42px; }
  .ai-drawer { padding: 0; } .ai-drawer-card { width: 100%; border-radius: 26px 26px 0 0; max-height: 92vh; } .ai-drawer .tri { border-radius: 26px 26px 0 0; }
  .ai-drawer .tri-log { height: 60vh; }
}
/* a due-medicine reminder card sits above the AI button */
.rem-card.is-on ~ .ai-fab, body:has(.rem-card.is-on) .ai-fab { opacity: 0; pointer-events: none; }

/* ---------- Sign-in sheet (demo session) ---------- */
.login-sheet { position: fixed; inset: 0; z-index: 160; display: grid; place-items: center; padding: 16px; background: rgba(6,20,16,.45); opacity: 0; pointer-events: none; transition: opacity .2s; }
.login-sheet.is-on { opacity: 1; pointer-events: auto; }
.login-card { position: relative; width: min(400px, 100%); padding: 28px 24px 22px; border-radius: 26px; background: var(--surface, #fff); box-shadow: 0 30px 80px rgba(0,0,0,.3); display: grid; gap: 12px; justify-items: center; text-align: center; transform: translateY(12px); transition: transform .25s; }
.login-sheet.is-on .login-card { transform: none; }
.login-card svg { width: 46px; height: 46px; } .login-card h2 { margin: 0; font-size: 1.4rem; } .login-card p { margin: 0; }
.login-note { color: var(--ap-label2); font-size: .76rem; line-height: 1.5; }
.login-x { position: absolute; top: 12px; right: 12px; width: 32px; height: 32px; border-radius: 50%; border: 0; background: var(--ap-fill); color: var(--ink); cursor: pointer; }
.login-av { width: 22px; height: 22px; border-radius: 50%; display: inline-grid; place-items: center; margin-right: 6px; background: linear-gradient(135deg, #00a982, #0d6e53); color: #fff; font-size: .7rem; font-weight: 800; }
.mobile-nav .login-av { display: none; }

/* ---------- Booking: who is the visit for (signed in) ---------- */
.who-pick { border: 0; padding: 0; margin: 0 0 18px; } .who-pick legend { font-weight: 700; margin-bottom: 10px; color: var(--dark); }
.who-opts { display: grid; grid-template-columns: repeat(auto-fill, minmax(180px, 1fr)); gap: 10px; }
.who-opt { display: flex !important; align-items: center; gap: 10px; text-align: left; padding: 12px !important; }
.who-opt input { position: absolute; opacity: 0; }
.who-av { width: 36px; height: 36px; border-radius: 50%; display: grid; place-items: center; flex: none; background: #e6faf3; color: #0d6e53; font-weight: 800; }
.who-opt b { display: block; font-size: .9rem; } .who-opt small { color: var(--ap-label2); font-size: .76rem; }
.who-opt:has(input:checked) { box-shadow: inset 0 0 0 2px #00a982; background: #f0fbf7; }
.who-opt:has(input:checked) .who-av { background: linear-gradient(135deg, #00a982, #0d6e53); color: #fff; }

[data-theme="dark"] .tri-link { background: #12342b; color: #7ee0bf; } [data-theme="dark"] .tri-link:hover { background: #174236; color: #b7f5df; }
[data-theme="dark"] .ai-drawer.is-on, [data-theme="dark"] .login-sheet { background: rgba(0,0,0,.55); }
[data-theme="dark"] .who-av { background: #12342b; color: #7ee0bf; } [data-theme="dark"] .who-opt:has(input:checked) { background: #10261f; }

/* DocSahab AI replies */
.tri-msg--note { align-self: center; max-width: 92%; text-align: center; font-size: .74rem; color: var(--ap-label2); background: transparent; padding: 2px 8px; }
.tri-sugg { display: flex; gap: 12px; align-items: flex-start; margin-top: 10px; padding: 12px; border-radius: 16px; background: #e6faf3; box-shadow: inset 0 0 0 1px #bfeedd; }
.tri-sugg .picto { width: 34px; height: 34px; flex: none; } .tri-sugg b { display: block; color: #0b382e; } .tri-sugg small { display: block; color: #3f5a52; font-size: .8rem; margin-top: 2px; }
[data-theme="dark"] .tri-sugg { background: #10261f; box-shadow: inset 0 0 0 1px #1d4a3c; } [data-theme="dark"] .tri-sugg b { color: #eef8f4; } [data-theme="dark"] .tri-sugg small { color: #9db3ac; }

/* ---------- Phone hero: doctor first (lettering + doctor + ring), headline over his legs ---------- */
@media (max-width: 760px) {
  .hero .container { display: flex; flex-direction: column; gap: 0; padding-top: 8px; }
  .hero-visual { order: -1; width: 100%; min-height: 0; padding-top: 22px; place-items: end center; }
  .hero-word { top: 0; }
  .hero-doc { width: min(86vw, 350px); margin-top: 0; }
  .hero-doc img { -webkit-mask-image: linear-gradient(to bottom, #000 56%, transparent 94%); mask-image: linear-gradient(to bottom, #000 56%, transparent 94%); }
  .hero-ring { width: min(80vw, 320px); height: min(80vw, 320px); }
  .hero-halo { width: min(92vw, 360px); height: min(92vw, 360px); }
  .hero-copy { margin-top: 18px; text-align: center; }
  .hero-copy .chip { display: none; }
  #hero-title { margin-top: 0 !important; font-size: clamp(2.15rem, 10.4vw, 2.7rem); text-shadow: 0 2px 18px rgba(242,252,248,.85); }
  [data-theme="dark"] #hero-title { text-shadow: 0 2px 22px rgba(8,18,15,.9); }
  .hero-lead { margin-left: auto; margin-right: auto; }
}

/* ---------- Intro film on phones: show the whole (16:9) scene, blurred copy fills the screen ---------- */
.mv-shot .mv-bg { display: none; }
@media (max-width: 760px) {
  .mv-shot .mv-bg { display: block; position: absolute; inset: -6%; width: 112%; height: 112%; object-fit: cover; object-position: 50% 50%; filter: blur(22px) brightness(.5) saturate(1.15); transform: none; z-index: 0; }
  .mv-shot img:not(.mv-bg) { inset: auto; left: 0; right: 0; top: 27vh; width: 100%; height: auto; aspect-ratio: 16 / 9; object-fit: cover; object-position: 50% 50%; z-index: 1;
    -webkit-mask-image: linear-gradient(to bottom, transparent 0, #000 9%, #000 91%, transparent 100%); mask-image: linear-gradient(to bottom, transparent 0, #000 9%, #000 91%, transparent 100%);
    box-shadow: 0 30px 60px rgba(0,0,0,.45); }
  .mv-caption { bottom: 19vh; }
}
@media (max-width: 760px) and (max-height: 700px) { .mv-shot img:not(.mv-bg) { top: 22vh; } }

/* ---------- Glow behind doctor characters (cards + profile poster), both themes ---------- */
.dc-stage::before { content: ""; position: absolute; left: 50%; bottom: 6%; width: min(92%, 340px); aspect-ratio: 1; transform: translateX(-50%); border-radius: 50%; z-index: 0; pointer-events: none;
  background: radial-gradient(closest-side, rgba(255,255,255,.95) 0%, rgba(186,244,222,.75) 42%, rgba(120,226,188,.28) 66%, rgba(120,226,188,0) 100%); filter: blur(2px); }
.dc-word { z-index: 0; }
.dc-figure { filter: drop-shadow(0 0 22px rgba(255,255,255,.7)) drop-shadow(0 18px 22px rgba(11,56,46,.16)); }
.poster-stage::before { width: 92%; bottom: 2%; background: radial-gradient(closest-side, rgba(255,255,255,.95) 0%, rgba(186,244,222,.7) 45%, rgba(120,226,188,.25) 70%, rgba(120,226,188,0) 100%); }
.poster-subject { filter: drop-shadow(0 0 30px rgba(255,255,255,.65)); }
[data-theme="dark"] .dc-stage::before { background: radial-gradient(closest-side, rgba(110,240,195,.55) 0%, rgba(52,211,153,.32) 40%, rgba(0,169,130,.14) 66%, rgba(0,169,130,0) 100%); }
[data-theme="dark"] .dc-figure { filter: drop-shadow(0 0 24px rgba(52,211,153,.38)); }
[data-theme="dark"] .poster-stage::before { background: radial-gradient(closest-side, rgba(110,240,195,.5) 0%, rgba(52,211,153,.28) 42%, rgba(0,169,130,.12) 68%, rgba(0,169,130,0) 100%); }
[data-theme="dark"] .poster-subject { filter: drop-shadow(0 0 34px rgba(52,211,153,.35)); }

/* "DR." and the first name sit either side of the doctor's head */
.dc-word.is-split { display: flex; justify-content: center; gap: 24cqw; font-size: min(5.2rem, calc(66cqw / (var(--len, 5) * .74))); }
.dc-word.is-split span, .poster-word.is-split span { background: inherit; -webkit-background-clip: text; background-clip: text; }
.poster-word.is-split { display: flex; justify-content: center; gap: 15vw; font-size: min(15rem, calc(80vw / (var(--len, 5) * .66))); }
@media (max-width: 760px) {
  /* Phone: the head is too wide to split around, so the full name sits above the doctor */
  .poster-word.is-split { gap: .28em; font-size: min(24vw, calc(88vw / (var(--len, 5) * .72))); }
  .poster-stage { margin-top: calc(min(13vw, 64px) - 14px); }
}
/* Gap pinned to the centre (where the head is): "DR." right-aligned on the left, first name left-aligned on the right */
.dc-word.is-split { display: grid; grid-template-columns: 1fr 25cqw 1fr; gap: 0; align-items: end; font-size: min(3.6rem, calc(32cqw / (var(--nl, 5) * .74))); }
.dc-word.is-split > span:first-child { justify-self: end; }
.dc-word.is-split > span:last-child { grid-column: 3; justify-self: start; }
.dc-stage .demo-tag { top: auto; right: auto; bottom: 12px; left: 12px; }
@media (min-width: 761px) {
  .poster-word.is-split { display: grid; grid-template-columns: 1fr 16vw 1fr; gap: 0; align-items: end; font-size: min(14rem, calc(38vw / (var(--nl, 5) * .66))); }
  .poster-word.is-split > span:first-child { justify-self: end; }
  .poster-word.is-split > span:last-child { grid-column: 3; justify-self: start; }
}

/* The site manages its own light/dark themes — stop phone browsers from force-darkening the light theme */
:root { color-scheme: light; }
[data-theme="dark"] { color-scheme: dark; }
/* Review card text follows the theme explicitly */
.story-card { color: #0b382e; }
.story-card blockquote, .story-card figcaption b { color: #0b382e; }
.story-card figcaption small { color: #0d6e53; }
[data-theme="dark"] .story-card { color: #e9f7f1; }
[data-theme="dark"] .story-card blockquote, [data-theme="dark"] .story-card figcaption b { color: #eef8f4; }
[data-theme="dark"] .story-card figcaption small { color: #6ee0bc; }

/* Patient profile photo + upload button */
.pf-photo { position: relative; flex: none; }
.pf-photo img { display: block; width: 88px; height: 88px; border-radius: 28px; object-fit: cover; background: var(--mint); box-shadow: 0 10px 24px rgba(11,56,46,.18), 0 0 0 3px #fff; }
.pf-cam { position: absolute; right: -6px; bottom: -6px; width: 32px; height: 32px; border-radius: 50%; display: grid; place-items: center; cursor: pointer; color: #fff;
  background: linear-gradient(135deg, #00a982, #0d6e53); box-shadow: 0 6px 14px rgba(13,110,83,.35), 0 0 0 3px #fff; transition: transform .2s; }
.pf-cam:hover { transform: scale(1.08); } .pf-cam:focus-within { outline: 3px solid #7ee0bf; outline-offset: 2px; }
#hb-img { object-fit: cover; }
img.login-av { object-fit: cover; padding: 0; }
[data-theme="dark"] .pf-photo img { box-shadow: 0 10px 24px rgba(0,0,0,.4), 0 0 0 3px #0f1b17; }
[data-theme="dark"] .pf-cam { box-shadow: 0 6px 14px rgba(0,0,0,.4), 0 0 0 3px #0f1b17; }
[data-theme="dark"] .prof-card .tags span { color: #cfe7df; background: rgba(255,255,255,.08); }

/* ---------- Phase-wise services and scope of care (services.html, service.html, scope.html) ---------- */
.phase-block { display: grid; gap: 18px; margin-bottom: 44px; }
.phase-head { display: grid; gap: 4px; }
.phase-head h2 { margin: 6px 0 0; font-size: clamp(1.35rem, 2.6vw, 1.75rem); }
.phase-head p { margin: 0; }
.phase-chip { justify-self: start; display: inline-flex; padding: 4px 12px; border-radius: 999px; font-size: .74rem; font-weight: 800; letter-spacing: .06em; text-transform: uppercase; background: var(--mint); color: var(--primary); }
.phase-chip--2 { background: #e8eefc; color: #3554a5; }
.phase-chip--3 { background: #f4ecfb; color: #6b3fa0; }
[data-theme="dark"] .phase-chip--2 { background: #1a2640; color: #a9c0f2; }
[data-theme="dark"] .phase-chip--3 { background: #2a1f3a; color: #d4b8f2; }
.soon-tag { display: inline-flex; padding: 3px 10px; border-radius: 999px; font-size: .72rem; font-weight: 700; background: var(--mint); color: var(--primary); border: 1px dashed currentColor; }
.svc-card--soon { background: var(--bg); box-shadow: none; }
.svc-card--soon .picto { opacity: .8; }
.svc-offer { color: var(--primary); font-weight: 700; font-size: .9rem; }
.perk-row { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 14px; margin: 4px 0 18px; }
@media (max-width: 760px) { .perk-row { grid-template-columns: minmax(0, 1fr); } }
.perk { display: grid; gap: 4px; padding: 16px 18px; border-radius: 18px; background: var(--mint); }
.perk b { color: var(--dark); }
.perk span { color: var(--muted); font-size: .9rem; }
.scope-callout { display: flex; gap: 12px; align-items: flex-start; padding: 14px 16px; border-radius: 14px; background: var(--warn-bg); color: var(--warn-ink); font-size: .92rem; }
.scope-callout a { color: inherit; font-weight: 700; }
.scope-grid { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 18px; }
@media (max-width: 900px) { .scope-grid { grid-template-columns: minmax(0, 1fr); } }
.scope-col { display: grid; align-content: start; gap: 12px; padding: 22px; border-radius: 22px; background: var(--surface); border: 1px solid var(--line); }
.scope-col h2 { margin: 0; font-size: 1.2rem; display: flex; align-items: center; gap: 10px; }
.scope-col ul { margin: 0; padding-left: 1.1em; display: grid; gap: 8px; color: var(--ink); }
.scope-col--treat { border-top: 5px solid var(--primary); }
.scope-col--refer { border-top: 5px solid #d99a1e; }
.scope-col--never { border-top: 5px solid var(--danger, #d64545); }
.scope-col .lede { margin: 0; color: var(--muted); font-size: .92rem; }
.emergency-band { display: flex; gap: 14px; align-items: center; flex-wrap: wrap; padding: 18px 20px; border-radius: 18px; background: #b3261e; color: #fff; margin-bottom: 26px; }
.emergency-band b { font-size: 1.1rem; }
.emergency-band .num { font-size: 1.6rem; font-weight: 800; letter-spacing: .02em; }
.svc-limits { margin-top: 28px; padding: 18px 20px; border-radius: 18px; background: var(--warn-bg); color: var(--warn-ink); }
.svc-limits h2 { font-size: 1.1rem !important; margin: 0 0 8px; color: inherit; }
.svc-limits ul { margin: 0; padding-left: 1.1em; display: grid; gap: 6px; }

/* ---------- Where home care stops (scope.html#where-we-stop) ---------- */
.stop-block { display: grid; gap: 18px; margin-top: 48px; scroll-margin-top: 96px; }
.stop-jump { margin-left: auto; color: #fff; font-weight: 700; text-decoration: underline; text-underline-offset: 3px; }
.stop-jump:hover { color: #ffe1dc; }
.stop-bar { display: grid; grid-template-columns: 2fr 1fr 1fr; gap: 14px; font-size: .74rem; font-weight: 800; letter-spacing: .06em; text-transform: uppercase; }
.stop-bar span { padding: 8px 12px; border-radius: 999px; text-align: center; }
.sb-us { background: var(--mint); color: var(--primary); } .sb-hand { background: #fdf1dc; color: #8a5a00; } .sb-er { background: #fde4e1; color: #b3261e; }
.stop-ladder { list-style: none; margin: 0; padding: 0; display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); gap: 14px; }
.stop-step { position: relative; display: grid; gap: 12px; align-content: start; padding: 20px; border-radius: 20px; background: var(--surface); border: 1px solid var(--line); }
.stop-step h3 { margin: 0 0 6px; font-size: 1.05rem; }
.stop-step p { margin: 0; font-size: .92rem; color: var(--ink); }
.stop-step small { display: block; margin-top: 10px; font-size: .82rem; font-weight: 700; color: var(--muted); }
.stop-n { width: 34px; height: 34px; border-radius: 50%; display: grid; place-items: center; font-weight: 800; color: #fff; background: var(--primary); }
.stop-step--2 .stop-n { background: #d99a1e; } .stop-step--3 .stop-n { background: #c2410c; } .stop-step--4 .stop-n { background: #b3261e; }
.stop-step--4 { background: #fff5f4; border-color: #f3c4bf; }
.stop-step:not(:last-child)::after { content: ""; position: absolute; top: 34px; right: -11px; width: 9px; height: 9px; border-top: 2px solid #9cc9b8; border-right: 2px solid #9cc9b8; transform: rotate(45deg); }
.stop-grid { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 18px; }
.stop-grid h3 { margin: 0; font-size: 1.05rem; display: flex; align-items: center; gap: 8px; }
.stop-grid h3 svg { color: var(--secondary); width: 20px; height: 20px; flex: none; }
@media (max-width: 900px) { .stop-ladder, .stop-grid { grid-template-columns: minmax(0, 1fr); } .stop-step::after, .stop-bar { display: none; } .stop-jump { margin-left: 0; } }
[data-theme="dark"] .stop-step--4 { background: #2a1210; border-color: #6b2a24; }
[data-theme="dark"] .sb-hand { background: #2a2210; color: #f2c46a; } [data-theme="dark"] .sb-er { background: #2a1210; color: #ff8a80; }

/* ---------- Post-visit feedback sheet (feedback.js) ---------- */
html.fb-lock { overflow: hidden; }
.fb-sheet { position: fixed; inset: 0; z-index: 170; display: grid; place-items: center; padding: 16px; background: rgba(6,20,16,.5); opacity: 0; pointer-events: none; transition: opacity .2s; }
.fb-sheet.is-on { opacity: 1; pointer-events: auto; }
.fb-card { position: relative; width: min(560px, 100%); max-height: calc(100vh - 32px); max-height: calc(100dvh - 32px); overflow-y: auto; padding: 24px 24px 20px; border-radius: 26px; background: var(--surface); color: var(--ink); box-shadow: 0 30px 80px rgba(0,0,0,.3); display: grid; gap: 16px; transform: translateY(14px); transition: transform .25s; }
.fb-sheet.is-on .fb-card { transform: none; }
.fb-head { display: flex; gap: 14px; align-items: center; padding-right: 36px; }
.fb-head h2 { margin: 0; font-size: 1.35rem; }
.fb-head p { margin: 2px 0 0; font-weight: 700; line-height: 1.35; }
.fb-head small { font-weight: 500; color: var(--muted); }
.fb-av { width: 52px; height: 52px; border-radius: 50%; object-fit: cover; background: var(--mint); flex: none; }
.fb-av--txt { display: grid; place-items: center; font-weight: 800; color: var(--primary); }
.fb-sec { display: grid; gap: 12px; border: 0; margin: 0; padding: 14px 0 0; border-top: 1px solid var(--line); min-width: 0; }
.fb-sec > h3 { margin: 0; font-size: .74rem; font-weight: 800; letter-spacing: .07em; text-transform: uppercase; color: var(--muted); }
.fb-row { display: flex; align-items: center; justify-content: space-between; gap: 6px 12px; flex-wrap: wrap; }
.fb-row .fb-row-t { flex: 1 1 160px; min-width: 0; }
.fb-row:not(.fb-row--big) .fb-stars { flex: none; }
.fb-row--big .fb-row-t { flex: none; }
.fb-row-t b { display: block; font-size: .95rem; }
.fb-row-t small { color: var(--muted); font-size: .8rem; }
.fb-row--big { flex-direction: column; text-align: center; gap: 4px; }
.fb-row--big .fb-stars { justify-content: center; }
.fb-stars { display: flex; align-items: center; gap: 2px; flex-wrap: wrap; }
.fb-star, .fb-na, .fb-chip, .fb-n { position: relative; }
.fb-star input, .fb-na input, .fb-chip input, .fb-n input { position: absolute; opacity: 0; width: 1px; height: 1px; }
.fb-star { cursor: pointer; line-height: 1; }
.fb-star span[aria-hidden] { display: block; font-size: 1.7rem; color: #d5dcd9; padding: 2px; transition: transform .12s, color .12s; }
.fb-row--big .fb-star span[aria-hidden] { font-size: 2.5rem; }
.fb-star:hover span[aria-hidden] { transform: scale(1.12); }
.fb-stars[data-v="1"] .fb-star:nth-child(-n+1) span[aria-hidden], .fb-stars[data-v="2"] .fb-star:nth-child(-n+2) span[aria-hidden],
.fb-stars[data-v="3"] .fb-star:nth-child(-n+3) span[aria-hidden], .fb-stars[data-v="4"] .fb-star:nth-child(-n+4) span[aria-hidden],
.fb-stars[data-v="5"] .fb-star:nth-child(-n+5) span[aria-hidden] { color: #f5a623; }
.fb-word { width: 100%; text-align: center; font-size: .85rem; font-weight: 700; color: var(--muted); min-height: 1.3em; }
.fb-na { margin-left: 8px; }
.fb-na span, .fb-chip span { display: inline-block; padding: 6px 12px; border-radius: 999px; border: 1px solid var(--line); font-size: .8rem; font-weight: 700; color: var(--muted); cursor: pointer; background: var(--surface); }
.fb-na:has(input:checked) span, .fb-chip:has(input:checked) span { background: var(--primary); border-color: var(--primary); color: #fff; }
.fb-star input:focus-visible + span, .fb-na input:focus-visible + span, .fb-chip input:focus-visible + span, .fb-n input:focus-visible + span { outline: 2px solid var(--secondary); outline-offset: 2px; border-radius: 8px; }
.fb-check { border: 0; margin: 0; padding: 0; min-width: 0; }
.fb-check legend, .fb-nps-wrap legend { float: left; width: 100%; padding: 0; margin: 0 0 8px; font-weight: 700; font-size: .95rem; color: var(--ink); }
.fb-chips { clear: both; display: flex; gap: 6px; flex-wrap: wrap; }
.fb-nps { clear: both; display: grid; grid-template-columns: repeat(11, minmax(0, 1fr)); gap: 4px; }
.fb-n span { display: grid; place-items: center; height: 38px; border-radius: 10px; font-weight: 800; font-size: .9rem; cursor: pointer; background: var(--ap-fill); color: var(--ink); transition: background .12s; }
.fb-n--d:has(input:checked) span { background: #d92d20; color: #fff; } .fb-n--m:has(input:checked) span { background: #e08a00; color: #fff; } .fb-n--p:has(input:checked) span { background: #1f9d4c; color: #fff; }
.fb-nps-l { display: flex; justify-content: space-between; font-size: .76rem; color: var(--muted); font-weight: 600; }
.fb-cb { display: flex; gap: 8px; align-items: center; font-size: .9rem; font-weight: 600; }
.fb-submit { width: 100%; justify-content: center; }
.fb-note { color: var(--muted); font-size: .76rem; text-align: center; }
.fb-thanks { display: grid; justify-items: center; text-align: center; gap: 10px; padding: 18px 6px 4px; }
.fb-thanks h2 { margin: 0; font-size: 1.4rem; } .fb-thanks p { margin: 0; }
.fb-thanks-ic { font-size: 2.6rem; line-height: 1; }
.fb-thanks-stars { font-size: 1.6rem; color: #f5a623; letter-spacing: 2px; }
.fb-thanks-stars .off, .cx-fb-stars .off { color: #d5dcd9; }
@media (max-width: 480px) { .fb-card { padding: 20px 16px 16px; } .fb-n span { height: 32px; font-size: .8rem; border-radius: 8px; } .fb-nps { gap: 3px; } .fb-star span[aria-hidden] { font-size: 1.5rem; } }
/* patient dashboard + tracking */
.fb-prompt { display: flex; align-items: center; gap: 12px 16px; flex-wrap: wrap; margin-bottom: 20px; border: 1px solid rgba(0,169,130,.25); background: linear-gradient(120deg, #f0fbf7, var(--ap-card)); }
.fb-prompt-t { display: flex; align-items: center; gap: 12px; flex: 1 1 260px; }
.fb-prompt-t b { display: block; } .fb-prompt-t small { color: var(--ap-label2); }
.fb-prompt .av { width: 40px; height: 40px; border-radius: 50%; object-fit: cover; background: var(--mint); }
.fb-quick { display: flex; }
.fb-quick button { border: 0; background: none; font-size: 1.9rem; line-height: 1; color: #d5dcd9; cursor: pointer; padding: 2px 3px; transition: color .1s, transform .1s; }
.fb-quick:hover button { color: #f5a623; } .fb-quick button:hover ~ button { color: #d5dcd9; } .fb-quick button:hover { transform: scale(1.12); }
.fb-quick button:focus-visible { outline: 2px solid var(--secondary); border-radius: 6px; }
.fb-given { display: inline-flex; align-items: center; gap: 4px; font-weight: 800; color: #b97800; }
.fb-done { display: flex; align-items: center; gap: 12px; margin-top: 14px; padding: 14px; border-radius: 16px; background: var(--mint); }
.fb-done > div { flex: 1; min-width: 0; } .fb-done b { display: block; font-size: .92rem; } .fb-done small { color: var(--muted); font-size: .8rem; }
.fb-done-ic { font-weight: 800; color: #b97800; font-size: 1.05rem; white-space: nowrap; }
[data-theme="dark"] .fb-prompt { background: linear-gradient(120deg, #0f2721, var(--ap-card)); }
[data-theme="dark"] .fb-star span[aria-hidden], [data-theme="dark"] .fb-quick button, [data-theme="dark"] .fb-thanks-stars .off, [data-theme="dark"] .cx-fb-stars .off { color: #2c3d37; }
[data-theme="dark"] .fb-quick:hover button { color: #f5a623; } [data-theme="dark"] .fb-quick button:hover ~ button { color: #2c3d37; }
[data-theme="dark"] .fb-given, [data-theme="dark"] .fb-done-ic { color: #ffcf6b; }

/* ---------- Operations: customers and experience (admin-customers.js) ---------- */
.cx { display: grid; gap: 18px; scroll-margin-top: 90px; }
.cx-head { align-items: flex-start; flex-wrap: wrap; margin: 0; }
.cx-head p { margin: 2px 0 0; font-size: .88rem; }
.cx-kpis { display: grid; grid-template-columns: repeat(auto-fit, minmax(150px, 1fr)); gap: 12px; }
.cx-kpi { display: grid; gap: 2px; align-content: start; padding: 14px 16px; border-radius: 16px; background: var(--ap-fill); }
.cx-kpi small { font-size: .76rem; font-weight: 700; color: var(--ap-label2); }
.cx-kpi b { font-size: 1.7rem; font-weight: 800; letter-spacing: -.03em; line-height: 1.15; color: #111816; }
.cx-kpi b em { font-style: normal; font-size: .9rem; color: var(--ap-label2); font-weight: 700; }
.cx-kpi span { font-size: .74rem; color: var(--ap-label2); line-height: 1.35; }
.cx-kpi--red { background: #ffeceb; } .cx-kpi--red b { color: #d92d20; }
.cx-split { display: grid; grid-template-columns: minmax(0, 1fr) minmax(0, 1.2fr); gap: 18px; }
.cx-box { padding: 16px; border-radius: 18px; border: .5px solid var(--ap-hair); display: grid; gap: 10px; align-content: start; min-width: 0; }
.cx-box h3 { margin: 0; font-size: .95rem; } .cx-box .cx-box-h2 { margin-top: 8px; }
.cx-bar { display: grid; grid-template-columns: 150px minmax(0, 1fr) 34px; align-items: center; gap: 10px; font-size: .84rem; }
.cx-bar b { text-align: right; }
.cx-track { height: 8px; border-radius: 99px; background: var(--ap-fill); overflow: hidden; }
.cx-track i { display: block; height: 100%; border-radius: 99px; background: linear-gradient(90deg, #00a982, #0d6e53); }
.cx-mini { margin: 4px 0 0; font-size: .72rem; font-weight: 800; letter-spacing: .06em; text-transform: uppercase; color: var(--ap-label2); }
.cx-doc { display: flex; justify-content: space-between; align-items: center; gap: 10px; font-size: .86rem; }
.cx-doc > span:first-child > b { display: block; font-weight: 700; } .cx-doc small { color: var(--ap-label2); font-size: .76rem; }
.cx-star { white-space: nowrap; font-weight: 800; } .cx-star b { color: #f5a623; }
.cx-feed-row { display: flex; gap: 10px; align-items: flex-start; width: 100%; text-align: left; padding: 10px; border: 0; border-radius: 14px; background: none; cursor: pointer; font: inherit; color: inherit; }
.cx-feed-row:hover { background: var(--ap-fill); }
.cx-feed-row.is-flag { box-shadow: inset 3px 0 0 #d92d20; }
.cx-feed-t { display: grid; gap: 2px; min-width: 0; }
.cx-feed-t > b { font-size: .9rem; } .cx-feed-t small { color: var(--ap-label2); font-size: .76rem; }
.cx-feed-t q { font-size: .82rem; display: -webkit-box; -webkit-line-clamp: 2; -webkit-box-orient: vertical; overflow: hidden; }
.cx-tools { display: flex; gap: 12px; align-items: center; flex-wrap: wrap; }
.cx-tools .input { flex: 1 1 240px; max-width: 360px; }
.cx > *, .cx-split > * { min-width: 0; }
.cx-tools .seg { max-width: 100%; overflow-x: auto; scrollbar-width: none; }
.cx-tools .seg::-webkit-scrollbar { display: none; }
.cx-tbl td small { font-size: .76rem; }
#ops-rows tr { cursor: pointer; } #ops-rows tr:hover td { background: var(--ap-fill); }
@media (max-width: 900px) { .cx-split { grid-template-columns: minmax(0, 1fr); } .cx-bar { grid-template-columns: 120px minmax(0, 1fr) 30px; } }
/* journey drawer */
.cx-drawer { position: fixed; inset: 0; z-index: 150; background: rgba(6,20,16,.42); opacity: 0; transition: opacity .22s; }
.cx-drawer.is-on { opacity: 1; }
.cx-panel { position: absolute; top: 0; right: 0; bottom: 0; width: min(720px, 100%); overflow-y: auto; background: var(--ap-bg); box-shadow: -20px 0 60px rgba(0,0,0,.2); transform: translateX(30px); transition: transform .24s; outline: none; }
.cx-drawer.is-on .cx-panel { transform: none; }
.cx-d-head { position: sticky; top: 0; z-index: 2; display: flex; gap: 14px; align-items: center; padding: 18px 60px 16px 22px; background: var(--ap-card); border-bottom: .5px solid var(--ap-hair); }
.cx-d-head h2 { margin: 0; font-size: 1.3rem; } .cx-d-head small { color: var(--ap-label2); font-size: .82rem; }
.cx-d-body { display: grid; gap: 14px; padding: 18px 22px 40px; }
.cx-fam { margin: 0; font-size: .86rem; }
.cx-d-kpis { display: grid; grid-template-columns: repeat(5, minmax(0, 1fr)); gap: 10px; }
.cx-d-kpis div { padding: 12px; border-radius: 14px; background: var(--ap-card); border: .5px solid var(--ap-hair); display: grid; gap: 2px; min-width: 0; }
.cx-d-kpis small { font-size: .72rem; color: var(--ap-label2); font-weight: 700; } .cx-d-kpis b { font-size: 1.02rem; }
.cx-d-asp { display: grid; gap: 8px; padding: 14px; border-radius: 16px; background: var(--ap-card); border: .5px solid var(--ap-hair); }
.cx-d-actions { display: flex; gap: 8px; flex-wrap: wrap; }
.cx-d-h { margin: 6px 0 0; font-size: 1rem; }
.cx-visit { display: grid; gap: 12px; padding: 16px; border-radius: 18px; background: var(--ap-card); border: .5px solid var(--ap-hair); border-left: 4px solid #00a982; outline: none; }
.cx-visit--cancelled { border-left-color: #c7cfcc; } .cx-visit--urgent { border-left-color: #d92d20; } .cx-visit--in-visit { border-left-color: #ff9500; }
.cx-visit--upcoming, .cx-visit--assigned, .cx-visit--on-the-way { border-left-color: #0a84ff; }
.cx-visit:focus-visible { box-shadow: 0 0 0 3px rgba(0,169,130,.35); }
.cx-visit-h { display: flex; justify-content: space-between; align-items: flex-start; gap: 10px; }
.cx-visit-h b { display: block; } .cx-visit-h small { color: var(--ap-label2); font-size: .8rem; }
.cx-facts { margin: 0; display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 8px 16px; }
.cx-facts div { min-width: 0; }
.cx-facts dt { font-size: .7rem; font-weight: 700; color: var(--ap-label2); text-transform: uppercase; letter-spacing: .05em; }
.cx-facts dd { margin: 0; font-size: .86rem; }
.cx-steps { list-style: none; margin: 0 0 0 5px; padding: 0 0 0 16px; border-left: 2px solid var(--ap-hair); display: grid; gap: 6px; }
.cx-steps li { position: relative; display: flex; justify-content: space-between; gap: 10px; font-size: .82rem; }
.cx-steps li::before { content: ""; position: absolute; left: -23px; top: 5px; width: 8px; height: 8px; border-radius: 50%; background: var(--ap-card); border: 2px solid #00a982; }
.cx-steps time { color: var(--ap-label2); white-space: nowrap; }
.cx-fb { display: grid; gap: 10px; padding: 14px; border-radius: 14px; background: #f7faf9; border: .5px solid var(--ap-hair); }
.cx-fb.is-flag { background: #fff5f4; border-color: #f3c4bf; }
.cx-fb--none { display: flex; align-items: center; justify-content: space-between; gap: 10px; flex-wrap: wrap; color: var(--ap-label2); font-size: .86rem; }
.cx-fb-top { display: flex; align-items: center; gap: 8px 10px; flex-wrap: wrap; }
.cx-fb-top small { color: var(--ap-label2); margin-left: auto; font-size: .78rem; }
.cx-fb-stars { color: #f5a623; letter-spacing: 1px; font-size: 1.1rem; }
.cx-asp { display: grid; grid-template-columns: repeat(auto-fit, minmax(130px, 1fr)); gap: 8px; }
.cx-asp div { display: grid; gap: 2px; padding: 8px 10px; border-radius: 10px; background: var(--ap-card); }
.cx-asp small { font-size: .72rem; color: var(--ap-label2); font-weight: 700; }
.cx-chks { display: flex; gap: 6px; flex-wrap: wrap; }
.cx-chk { font-size: .76rem; font-weight: 700; padding: 4px 10px; border-radius: 999px; }
.cx-chk--ok { background: #e6f8ec; color: #1f9d4c; } .cx-chk--bad { background: #ffeceb; color: #d92d20; } .cx-chk--na { background: #f0f2f1; color: #6b7672; }
.cx-fb blockquote { margin: 0; padding: 8px 12px; border-left: 3px solid #00a982; font-size: .88rem; background: var(--ap-card); border-radius: 0 10px 10px 0; }
.cx-cb { margin: 0; font-size: .84rem; font-weight: 700; color: #c26a00; }
.cx-fb-act { display: flex; align-items: center; gap: 10px; }
@media (max-width: 640px) { .cx-d-kpis { grid-template-columns: repeat(2, minmax(0, 1fr)); } .cx-facts { grid-template-columns: minmax(0, 1fr); } .cx-d-body { padding: 14px 14px 32px; } .cx-d-head { padding: 14px 54px 14px 14px; } }
[data-theme="dark"] .cx-kpi--red, [data-theme="dark"] .cx-fb.is-flag { background: #2a1210; border-color: #6b2a24; }
[data-theme="dark"] .cx-fb { background: #13221d; }
[data-theme="dark"] .cx-chk--ok { background: rgba(52,199,89,.16); color: #6ee7a0; } [data-theme="dark"] .cx-chk--bad { background: rgba(255,59,48,.18); color: #ff8a80; } [data-theme="dark"] .cx-chk--na { background: rgba(255,255,255,.08); color: #b9c8c3; }
[data-theme="dark"] :is(.cx-kpi b, .cx-d-head h2, .cx-visit-h b, .cx-feed-t > b, .cx-doc b, .cx-box h3, .cx-d-h) { color: #eef8f4; }
[data-theme="dark"] .cx-kpi--red b { color: #ff8a80; }
