:root{font:16px/1.5 "Inter",-apple-system,BlinkMacSystemFont,"Segoe UI",sans-serif;color:#27332e;background:#fff;--ink:#1b4038;--line:#dce2dc;--soft:#f2f5f1;--dim:#5c6c62;--rail:250px}
*{box-sizing:border-box}body{margin:0}button,input,textarea{font:inherit}button{cursor:pointer;border:0}button:disabled{opacity:.5;cursor:default}button,a{touch-action:manipulation}button:focus-visible,a:focus-visible,input:focus-visible,textarea:focus-visible,summary:focus-visible{outline:3px solid #a97828;outline-offset:3px}
[hidden]{display:none!important}.sr{position:absolute;width:1px;height:1px;overflow:hidden;clip-path:inset(100%)}header{background:#fff;border-bottom:1px solid var(--line);height:58px}.header{height:100%;padding:0 22px;display:flex;align-items:center;gap:14px}.brand{display:flex;align-items:center;gap:10px;font-weight:650;color:var(--ink);text-decoration:none;letter-spacing:-.03em}.brand img{border-radius:9px}.account{margin-left:auto;display:flex;align-items:center;gap:10px}.account span{font-size:.83rem;color:var(--dim)}.plain,.link,#menu{background:none;color:var(--ink);padding:7px;font-weight:600}.link{text-decoration:underline;text-underline-offset:3px}.primary,.secondary,.voice-action{border-radius:18px;padding:9px 16px;font-weight:600}.primary{background:var(--ink);color:#fff}.secondary,.voice-action{background:var(--soft);color:var(--ink)}h1,h2,p{overflow-wrap:anywhere}h1{font-size:clamp(1.65rem,4vw,2.2rem);line-height:1.2;letter-spacing:-.045em;margin:.6em 0}h2{font-size:1.08rem}.intro,.empty,small,.small{color:var(--dim)}small{display:block}.intro{max-width:60ch}#pairing{max-width:520px;margin:clamp(24px,9vh,90px) auto;padding:0 22px}.panel,.card{border:1px solid var(--line);border-radius:17px;padding:20px;background:#fff}.panel>p{color:var(--dim)}.consent{display:flex;align-items:flex-start;gap:10px;font-size:.89rem;line-height:1.5;color:var(--dim);margin:10px 0 18px}input[type=checkbox]{accent-color:var(--ink);width:17px;height:17px;flex:none}input[type=password]{width:100%;padding:11px;border:1px solid var(--line);border-radius:10px;margin:7px 0 12px}summary{cursor:pointer;color:var(--ink);font-weight:600;padding:10px 0}details{margin-top:10px}#google-sign{width:100%}#google-status{margin-top:7px}
#workspace{height:calc(100dvh - 58px);display:grid;grid-template-columns:var(--rail) 1fr}#sidebar{background:#f6f7f4;border-right:1px solid var(--line);display:flex;flex-direction:column;overflow:auto;padding:18px 12px;gap:12px}#sidebar button{text-align:left;color:#273b32;background:transparent;padding:9px 13px;border-radius:9px}#sidebar button:hover,#sidebar button[aria-current=page]{background:#e7eee6}#sidebar .side-new{background:#e5ece4;font-weight:650}nav{display:grid}.side-heading,.meta{font-size:.79rem;color:var(--dim)}.side-heading{padding:6px 13px 0;font-weight:650}#recent{display:grid;gap:2px}#recent button{overflow:hidden;text-overflow:ellipsis;white-space:nowrap}.emergency{margin-top:auto;padding:18px 13px 0;color:var(--dim);font-size:.85rem}#menu{display:none}#scrim{display:none}
.chat-page{min-width:0;min-height:0;display:flex;flex-direction:column}.sectionhead,.sendrow,.actions{display:flex;align-items:center;justify-content:space-between;gap:9px}.sectionhead h1{margin:16px 0}.sectionhead #fresh{font-size:.86rem}#thread,.reader{overflow:auto}#thread{flex:1;padding:18px max(22px,calc((100% - 790px)/2)) 12px;scroll-behavior:smooth}.reader{width:min(840px,100%);margin:0 auto;padding:24px}.bubble{margin:17px 0;overflow-wrap:anywhere}.bubble:not(.assistant){background:#eef2ed;border-radius:18px 18px 4px 18px;padding:12px 17px;margin-left:auto;width:fit-content;max-width:88%}.assistant{padding:4px 0 14px}.assistant .meta{font-weight:650}.bodytext{white-space:pre-wrap;line-height:1.6;margin:5px 0}.danger{display:block;color:#842c20;background:#ffede5;border-radius:8px;padding:8px;margin:6px 0}.bubble .link{font-size:.82rem;padding-left:0}
#composer{width:min(834px,100%);margin:0 auto;padding:4px 22px max(9px,env(safe-area-inset-bottom))}#askform{border:1px solid #b8c7bb;border-radius:22px;padding:9px 11px;box-shadow:0 3px 14px #25382b0a}textarea{border:none;background:transparent;width:100%;padding:4px 6px;min-height:45px;max-height:18vh;resize:vertical;color:var(--ink);line-height:1.45}.sendrow{justify-content:flex-start;flex-wrap:wrap}.sendrow #send{margin-left:auto}.sendrow button{font-size:.89rem}#voice-status,.meta{font-size:.82rem}#voice-panel{font-size:.79rem;color:var(--dim);padding:5px 4px}#voice-panel label{display:flex;align-items:center;gap:6px}#voice-panel small{font-size:.72rem}#voice-caption{max-height:3.8em;overflow:auto;color:var(--ink)}#context-note{background:#faf6e9;border:1px solid #e8dcc0;border-radius:10px;margin:5px 0;padding:7px 10px;font-size:.84rem}#context-note button{font-size:inherit;padding:2px 0}#reviewhint .link{font-size:.9rem}
.card,.listitem{margin:10px 0}.listitem{width:100%;text-align:left;background:#fff;border:1px solid var(--line);border-radius:12px;color:var(--ink);padding:13px 16px}.listitem strong{display:block;overflow-wrap:anywhere}.card blockquote{border-left:3px solid #a7c7a5;margin:13px 0;padding-left:12px;white-space:pre-wrap;overflow-wrap:anywhere}.actions{justify-content:flex-start;flex-wrap:wrap}.card .primary{font-size:.9rem}#notice{position:fixed;bottom:12px;left:50%;transform:translateX(-50%);border:1px solid #dfcea4;color:#573f1a;background:#fff9e8;border-radius:12px;padding:12px 16px;max-width:min(550px,92%);z-index:10}.health-row{display:flex;gap:9px;align-items:baseline;margin:.6em 0}.health-row span{overflow-wrap:anywhere}#import-launch a{color:var(--ink);font-weight:600;margin-right:12px}#device details{font-size:.9rem}
@media(max-width:740px){:root{--rail:min(80vw,290px)}.header{padding:0 12px;gap:8px}#workspace{display:block}.chat-page,.reader{height:100%}#menu{display:block}#sidebar{position:fixed;top:58px;bottom:0;left:0;width:var(--rail);transform:translateX(-102%);visibility:hidden;transition:transform .16s;z-index:6}body.drawer #sidebar{visibility:visible;transform:none}body.drawer #scrim{display:block;position:fixed;inset:58px 0 0;background:#15251b55;z-index:5}#thread{padding:10px 16px}.reader{padding:16px}#composer{padding-left:10px;padding-right:10px}.panel,.card{padding:14px}#context-note{max-height:17vh;overflow:auto}.account span{font-size:.77rem}h1{font-size:1.65rem}.brand{font-size:.96rem}input,textarea{font-size:16px}}

.brand{white-space:nowrap;flex-shrink:0}.account span{white-space:nowrap}@media(max-width:365px){.brand{font-size:.87rem}.header{gap:5px;padding:0 8px}.account{gap:4px}}
@media(max-width:740px){.header{min-width:0}.brand{min-width:0;white-space:normal;flex:1 1 auto}.brand img{flex:none}.account{flex:none}.account span{white-space:normal;max-width:6em}}

.bodytext a{overflow-wrap:anywhere;color:var(--ink)}
#connection-form{display:grid;gap:8px;margin-top:18px;max-width:480px}
#connection-form input,#connection-form select{font:inherit;width:100%;min-height:44px;padding:8px 10px;border:1px solid var(--line);border-radius:8px;background:#fff;color:var(--ink)}
#connection-form .actions,#connection-list .actions{justify-content:flex-start;margin-top:6px}

/* Conversations occupy the rail; the account tools stay below the scrollable list. */
:root{--ink:#262926;--line:#e2e3df;--soft:#f2f3f0;--dim:#666b65;--rail:266px}
header{height:56px}.header{padding:0 20px}.brand{font-size:1.05rem;font-weight:650}
#workspace{height:calc(100dvh - 56px);grid-template-columns:var(--rail) minmax(0,1fr)}
#sidebar{padding:14px 10px;gap:12px;background:#f8f8f6;overflow:hidden;min-height:0}
#sidebar .side-new{display:flex;align-items:center;gap:11px;color:#20231e;background:transparent;font-weight:650}
.side-new span{font-size:1.3rem;line-height:1}.chat-nav{display:flex;flex:1;flex-direction:column;min-height:0}
#sidebar .chat-nav>button{font-size:.84rem;font-weight:650;color:var(--dim)}
#recent{overflow:auto;display:flex;flex-direction:column;min-height:0}
#recent button{flex:none;min-height:38px;font-weight:450;font-size:.92rem}
#sidebar button:hover,#sidebar button[aria-current=page]{background:#e9eae6;color:#20231e}
.profile-nav{border-top:1px solid var(--line);padding-top:8px;font-size:.86rem}
#sidebar .profile-nav button{padding:6px 13px}.profile-nav .emergency{margin:0;padding:7px 13px;text-decoration:none;font-size:.79rem}
.menu-icon{display:block;width:18px;height:12px;border-block:2px solid currentColor}
.mobile-new{display:none}.chat-page{position:relative}
#thread{padding:18px max(24px,calc((100% - 742px)/2)) 12px}
#thread .sectionhead h1{font-size:1rem;font-weight:600;color:var(--dim);overflow:hidden;text-overflow:ellipsis;white-space:nowrap;line-height:1.5}
#composer{width:min(790px,100%);padding-bottom:max(15px,env(safe-area-inset-bottom))}
#askform{border:1px solid #cfd2cd;box-shadow:0 2px 8px #20231e09;border-radius:23px;padding:10px 12px}
#askform:focus-within{border-color:#848a81}
#question{display:block;min-height:38px;max-height:22dvh;padding:6px 4px;resize:none;color:var(--ink)}
#question:focus{outline:none}.sendrow{gap:7px}.sendrow{justify-content:flex-end}.sendrow #voice-status{margin-right:auto}
.sendrow .voice-action,.sendrow #send{display:inline-flex;align-items:center;justify-content:center;margin:0;padding:0;width:40px;height:40px;border-radius:50%}
.sendrow .voice-action{gap:2px;background:var(--soft);color:#343a33}.voice-action i{width:2px;height:8px;background:currentColor;border-radius:2px}
.voice-action i:nth-child(2),.voice-action i:nth-child(4){height:14px}.voice-action i:nth-child(3){height:20px}
.sendrow #send{background:#282b28;color:white;font-size:1.35rem}.sendrow #voice-status:empty{display:none}
#voice-panel:not([data-active]){display:none}#voice-panel[data-active]{padding-top:8px}
.bubble:not(.assistant){background:#f1f2ef;border-radius:19px}.assistant .bodytext{line-height:1.65}
.empty-chat #thread{display:flex;flex-direction:column;justify-content:flex-end;align-items:center;text-align:center;overflow:visible}
.empty-chat #thread .sectionhead h1{font-size:clamp(24px,3vw,34px);color:var(--ink);letter-spacing:-.04em;white-space:normal;margin:12px 0}
@media(min-width:741px){.empty-chat #composer{margin-bottom:clamp(48px,32vh,360px)}}
@media(max-width:740px){
  #workspace{display:block}.header{gap:6px;padding:0 10px}.brand{flex:1}
  #menu,.mobile-new{display:inline-flex;align-items:center;justify-content:center;width:40px;height:40px;flex:none}
  .mobile-new{font-size:1.55rem}.account{margin:0;font-size:.82rem}.account span{max-width:5em}
  #sidebar{top:56px;width:min(84vw,300px)}body.drawer #scrim{inset:56px 0 0}
  #thread{padding:12px 16px}.empty-chat #thread{justify-content:center}#composer{padding:4px 10px max(10px,env(safe-area-inset-bottom))}
  .sendrow .voice-action,.sendrow #send{width:44px;height:44px}
}
#chat-intro{display:none}.empty-chat #chat-intro{display:block;margin:0 0 12px;max-width:42ch;color:var(--dim);font-size:.94rem;line-height:1.5}

#health-welcome{box-sizing:border-box;max-width:min(29rem,calc(100% - 2rem));padding:1.5rem;border:1px solid #969e98;border-radius:1rem;color:inherit;background:Canvas}
#health-welcome::backdrop{background:rgba(0,0,0,.48)}
#health-welcome p{line-height:1.55}

.attach-picture{border:0;border-radius:50%;background:transparent;color:inherit;font-size:1.65rem;width:2.5rem;height:2.5rem;line-height:1;cursor:pointer}
.attach-picture:hover,.attach-picture:focus-visible{background:#e3eae5}
#picture-drafts{display:flex;flex-wrap:wrap;gap:.5rem}
.picture-draft{position:relative;margin:.45rem 0}
.picture-draft img{display:block;width:4rem;height:4rem;object-fit:cover;border-radius:.6rem}
.remove-picture{position:absolute;right:-.2rem;top:-.3rem;background:#21392b;color:white;border:0;border-radius:50%;width:1.45rem;height:1.45rem;line-height:1}
.chat-picture{margin:.65rem 0;display:grid;justify-items:start;gap:.35rem}
.chat-picture img{display:block;max-width:100%;width:auto;height:auto;max-height:32rem;object-fit:contain;border-radius:.65rem}

#funding-status{padding:1rem;border:1px solid var(--line);border-radius:1rem;background:var(--soft);margin-bottom:.75rem}
#funding-status p{margin:0 0 .7rem}
#funding-status .primary{width:100%;min-height:48px}
.ready-message{color:#23663f}
