/* OpenSCI V16.46.21 hotfix */
.clinical-record-card{padding:18px 18px 16px;overflow:hidden}.clinical-record-card>header{display:flex;align-items:flex-start;justify-content:space-between;gap:12px;margin-bottom:12px}.clinical-record-kind{font-size:13px;line-height:1.2;font-weight:800;letter-spacing:.06em;text-transform:uppercase;color:#17798b}.clinical-record-card>header small{font-size:12px;color:#6f8392;text-align:right}.clinical-record-body{font-size:15.5px;line-height:1.58;font-weight:400;color:#17324a}.clinical-record-body p{margin:0 0 12px}.clinical-record-body p:last-child{margin-bottom:0}.clinical-record-body strong{font-weight:760;color:#102a43}.clinical-record-body em{font-style:italic;color:#425c70}.clinical-record-body blockquote{margin:10px 0;padding:10px 12px;border-left:3px solid #33b9b3;background:rgba(51,185,179,.08);border-radius:8px}.clinical-empty{color:#6f8392}

.week-v24-wrap{position:relative;overflow-y:auto;overflow-x:hidden;max-height:min(72vh,860px);border:1px solid #d8e5ea;border-radius:22px;background:#f8fbfc;overscroll-behavior:contain}.week-v24-grid{display:grid;grid-template-columns:48px repeat(7,minmax(0,1fr));grid-template-rows:44px repeat(52,18px);position:relative;min-width:100%;isolation:isolate}.week-v24-corner,.week-v24-day{position:sticky;top:0;z-index:8;background:#f4f8f9;border-bottom:1px solid #d8e5ea}.week-v24-corner{border-right:1px solid #d8e5ea}.week-v24-day{border:0;border-right:1px solid #e0eaee;padding:4px 1px;color:#536d7d;display:flex;flex-direction:column;align-items:center;justify-content:center;gap:1px}.week-v24-day span{font-size:10px;text-transform:uppercase;letter-spacing:.05em}.week-v24-day strong{font-size:16px;line-height:1}.week-v24-day.today{background:#e4f6f3;color:#0b8e88}.week-v24-time{z-index:2;align-self:start;justify-self:stretch;padding:0 5px 0 3px;transform:translateY(-6px);font-size:10px;line-height:1;color:#708696;background:#f8fbfc;text-align:right}.week-v24-cell{border:0;border-right:1px solid #e3ecef;background:transparent;min-width:0;padding:0;z-index:1}.week-v24-cell.major{border-top:1px solid #d7e3e8}.week-v24-cell.minor{border-top:1px solid rgba(215,227,232,.28)}.week-v24-cell:active{background:rgba(21,166,159,.06)}.week-v24-event{z-index:5;margin:1px 2px;border:0;border-left:3px solid #11aaa4;border-radius:8px;background:#d7f0ec;color:#163c43;padding:4px 4px 3px;text-align:left;display:flex;flex-direction:column;align-items:flex-start;justify-content:flex-start;gap:2px;min-width:0;overflow:hidden;box-shadow:0 2px 8px rgba(12,64,74,.08)}.week-v24-event time{font-size:9.5px;line-height:1;font-weight:800;color:#078e88;white-space:nowrap}.week-v24-event strong{font-size:10.5px;line-height:1.08;font-weight:760;white-space:normal;overflow-wrap:anywhere;word-break:normal}.week-v24-event small{font-size:9px;line-height:1;color:#55747c;white-space:nowrap}.week-v24-event.type-break,.week-v24-event.type-dayoff{background:#eef1f3;border-left-color:#8796a1;color:#415563}.week-v24-event.type-personal{background:#e4eefb;border-left-color:#6089c7}.week-v24-event.type-slot{background:#f4f7f8;border-left-color:#8da0aa}@media(max-width:430px){.week-v24-grid{grid-template-columns:45px repeat(7,minmax(0,1fr));grid-template-rows:42px repeat(52,17px)}.week-v24-event{margin:1px;padding:3px 3px 2px}.week-v24-event strong{font-size:10px}.week-v24-event time{font-size:9px}.week-v24-event small{font-size:8.5px}}

.ai-compose{display:grid;grid-template-columns:minmax(0,1fr) 46px auto;align-items:end;gap:8px}.ai-compose-field{min-width:0}.ai-inline-voice{width:46px;height:46px;border:1px solid #c8e1e4;border-radius:15px;background:#e9f6f5;color:#137c88;font-size:21px;display:grid;place-items:center}.ai-inline-voice.listening{background:#d1f1ed;border-color:#1fb8ae;box-shadow:0 0 0 4px rgba(31,184,174,.12)}.ai-inline-voice.processing{opacity:.65}.ai-inline-voice:disabled{opacity:.45}.v24-send-failed .chat-assistant{border-color:#e3b4a7;background:#fff7f4}.v24-send-failed .chat-assistant p{color:#8a3c2c}@media(max-width:390px){.ai-compose{grid-template-columns:minmax(0,1fr) 44px}.ai-compose .ai-send{grid-column:1/-1;width:100%}.ai-inline-voice{width:44px;height:44px}}

body.theme-dark .clinical-record-body{color:#d8e4e7}body.theme-dark .clinical-record-body strong{color:#f2f7f8}body.theme-dark .clinical-record-card>header small{color:#8ca0aa}body.theme-dark .week-v24-wrap,body.theme-dark .week-v24-time{background:#10232d;border-color:#294452}body.theme-dark .week-v24-corner,body.theme-dark .week-v24-day{background:#122936;border-color:#2b4654;color:#aebdc5}body.theme-dark .week-v24-day.today{background:#173b3d;color:#58d5ce}body.theme-dark .week-v24-cell{border-right-color:#294452}body.theme-dark .week-v24-cell.major{border-top-color:#365563}body.theme-dark .week-v24-cell.minor{border-top-color:rgba(54,85,99,.3)}body.theme-dark .week-v24-event{background:#d7f0ec;color:#163c43}

.voice-field-wrap{position:relative;display:block;width:100%;min-width:0}.voice-field-wrap>textarea,.voice-field-wrap>input{width:100%;padding-right:54px}.field-inline-voice{position:absolute;right:8px;bottom:8px;width:40px;height:40px;border:1px solid #c8e1e4;border-radius:13px;background:#e9f6f5;color:#137c88;font-size:19px;display:grid;place-items:center;z-index:2}.input-voice-field .field-inline-voice{top:50%;bottom:auto;transform:translateY(-50%)}.field-inline-voice.listening{background:#d1f1ed;border-color:#1fb8ae;box-shadow:0 0 0 4px rgba(31,184,174,.12)}.field-inline-voice.processing{opacity:.65;pointer-events:none}.field-inline-voice:disabled{opacity:.45}body.theme-dark .field-inline-voice{background:#183944;border-color:#35606b;color:#65d4cf}body.theme-dark .field-inline-voice.listening{background:#1b4b4b;border-color:#58d5ce}

.document-proposal-head{display:flex;align-items:flex-start;justify-content:space-between;gap:10px;flex-wrap:wrap}.document-proposal-head small{color:var(--muted,#60758a)}.document-decision-final{color:var(--muted,#60758a);font-size:.84rem}.document-review-notice{border-left:4px solid #1aa59e}.document-summary-card p{margin:.35rem 0}
/* Keyboard layout is owned by the single in-flow chat rules at the end of
   live.css. Keep this late stylesheet free of fixed visualViewport overlays:
   on iOS Telegram they can detach the dialog from the scroller and leave a
   blank white panel above the keyboard. */
body.ai-keyboard-open .ai-chat-window .chat-list{padding-bottom:12px}
body.ai-keyboard-open .ai-compose{padding-bottom:max(10px,env(safe-area-inset-bottom))}
@media(max-height:520px){body.ai-keyboard-open .ai-dialog-toolbar{min-height:40px}body.ai-keyboard-open .ai-dialog-toolbar button{display:none}body.ai-keyboard-open .ai-compose-label{display:none}body.ai-keyboard-open .ai-compose{padding-top:8px}}
