*{box-sizing:border-box}
:root{font-family:Inter,system-ui,-apple-system,BlinkMacSystemFont,"Segoe UI",sans-serif;color:#172033;background:#f4f7fb}
body{margin:0;min-height:100vh;background:#f4f7fb}
button,input{font:inherit}
button{cursor:pointer}
.hidden{display:none!important}
.app-shell{max-width:1100px;margin:0 auto;padding:20px}
.topbar{display:flex;justify-content:space-between;align-items:center;padding:12px 4px 22px}.brand-row{display:flex;align-items:center;gap:11px}.brand-logo{width:42px;height:42px;border-radius:11px;display:block;box-shadow:0 3px 10px rgba(21,101,192,.18)}
.brand{font-size:30px;font-weight:900;letter-spacing:-1px;color:#1565c0}
.subbrand{font-size:13px;color:#687386;margin-top:2px}
.screen{min-height:70vh}
.auth-card{width:min(460px,100%);margin:40px auto;background:#fff;border:1px solid #e1e7ef;border-radius:20px;padding:28px;box-shadow:0 12px 40px rgba(30,60,100,.08)}
.auth-card h1{margin:8px 0 5px;font-size:26px}
.muted{color:#687386;margin:0 0 18px}
.logo-mark{width:92px;height:92px;border-radius:23px;display:grid;place-items:center;overflow:hidden;margin-bottom:8px;box-shadow:0 8px 24px rgba(21,101,192,.16)}.logo-mark img{width:100%;height:100%;display:block}
.icon{font-size:38px}
label{display:block;font-weight:750;font-size:13px;margin:14px 0;color:#303b4f}
input{display:block;width:100%;margin-top:7px;padding:13px 14px;border:1px solid #cfd7e3;border-radius:11px;outline:none;background:#fff;color:#172033}
input:focus{border-color:#1565c0;box-shadow:0 0 0 3px rgba(21,101,192,.1)}
button{border:0;border-radius:11px;padding:12px 16px;font-weight:800}
.primary{width:100%;background:#1565c0;color:#fff}
.secondary{background:#eaf2fb;color:#14599f}
.full-width{width:100%;margin-top:12px}
.link-button{background:none;color:#1565c0;padding:12px 0}
.divider{display:flex;align-items:center;gap:10px;color:#8b95a5;font-size:12px;margin:24px 0 6px}
.divider:before,.divider:after{content:"";height:1px;background:#e2e7ee;flex:1}
.message{min-height:22px;margin-top:14px;font-size:13px;font-weight:700}
.info-box,.notice{background:#f7faff;border:1px solid #dbe8f7;border-radius:13px;padding:13px;margin:14px 0;color:#334158}
.badge{display:inline-flex;align-items:center;padding:8px 11px;border-radius:999px;background:#e8f5e9;color:#246b2b;font-size:12px;font-weight:900}
.dashboard-head{display:flex;justify-content:space-between;align-items:center;gap:16px;margin:10px 0 18px}
.dashboard-head h1{margin:0 0 4px}
.dashboard-actions{display:flex;gap:8px;align-items:center}
.stats{display:grid;grid-template-columns:repeat(3,1fr);gap:12px;margin-bottom:14px}
.stats>div{background:#fff;border:1px solid #e1e7ef;border-radius:14px;padding:14px}
.stats strong{display:block;font-size:20px}
.stats span{font-size:12px;color:#687386}
.notice{display:flex;gap:8px;flex-wrap:wrap;margin-bottom:18px}
.bed-grid{display:grid;grid-template-columns:repeat(2,minmax(0,1fr));gap:14px}
.bed-card{background:#fff;border:1px solid #dce3ed;border-radius:16px;padding:16px;min-height:145px;display:flex;flex-direction:column;justify-content:space-between}
.bed-number{font-weight:900;color:#1565c0;font-size:18px}
.empty{color:#7a8494;font-weight:750}
@media(max-width:650px){.app-shell{padding:14px}.auth-card{margin:20px auto;padding:22px}.dashboard-head{align-items:flex-start;flex-direction:column}.stats{grid-template-columns:1fr}.bed-grid{grid-template-columns:1fr}.dashboard-actions{width:100%;justify-content:space-between}}


select{display:block;width:100%;margin-top:7px;padding:13px 14px;border:1px solid #cfd7e3;border-radius:11px;outline:none;background:#fff;color:#172033}
select:focus{border-color:#1565c0;box-shadow:0 0 0 3px rgba(21,101,192,.1)}
.coordinator-screen{}
.coord-grid{display:grid;grid-template-columns:repeat(2,minmax(0,1fr));gap:14px;margin-bottom:14px}
.panel-card{background:#fff;border:1px solid #dce3ed;border-radius:16px;padding:18px;margin-bottom:14px}
.panel-card h2{margin:0 0 8px;font-size:18px}
.panel-title-row{display:flex;justify-content:space-between;align-items:flex-start;gap:12px}
.table-wrap{overflow:auto}
.assignment-table{width:100%;border-collapse:collapse;min-width:680px}
.assignment-table th,.assignment-table td{text-align:left;padding:11px 10px;border-bottom:1px solid #e7ebf1;font-size:13px}
.assignment-table th{color:#687386;font-size:11px;text-transform:uppercase;letter-spacing:.04em}
.small-action{padding:8px 10px;font-size:12px;background:#eaf2fb;color:#14599f}
.code-box{margin-top:16px;padding:18px;border:1px dashed #1565c0;border-radius:14px;background:#f7faff}
.generated-code{font-size:30px;letter-spacing:6px;font-weight:950;color:#1565c0;margin:10px 0}
@media(max-width:700px){.coord-grid{grid-template-columns:1fr}.panel-title-row{flex-direction:column}}

.error-box{padding:14px;border:1px solid #efcaca;border-radius:12px;background:#fff7f7;color:#9b1c1c;line-height:1.5}

.clinical-actions{margin:12px 0;justify-content:flex-end}
.patient-form label{margin-bottom:12px}
.patient-form textarea{resize:vertical}
.form-grid{display:grid;grid-template-columns:repeat(2,minmax(0,1fr));gap:12px}
.patient-card{cursor:pointer}
.patient-card .patient-name{font-size:18px;font-weight:900;color:#1565c0}
.patient-card .diagnosis{color:#c62828;font-weight:800}
.patient-meta{display:flex;flex-wrap:wrap;gap:8px;margin:8px 0}
.patient-meta span{padding:4px 8px;background:#f0f3f7;border-radius:999px;font-size:12px}
.modal{position:fixed;inset:0;background:rgba(16,24,40,.48);display:flex;align-items:center;justify-content:center;padding:18px;z-index:100}
.modal-card{background:#fff;border-radius:18px;width:min(900px,100%);max-height:92vh;overflow:auto;padding:20px;box-shadow:0 20px 60px rgba(0,0,0,.2)}
@media(max-width:700px){.form-grid{grid-template-columns:1fr}}

/* v0.15 clinical UI */
.eyebrow{font-size:10px;letter-spacing:.14em;font-weight:900;color:#7b8798;margin-bottom:5px}
.bed-grid{grid-template-columns:repeat(3,minmax(0,1fr))}
.bed-card{min-height:178px;padding:18px;transition:transform .15s ease,box-shadow .15s ease,border-color .15s ease}
.bed-card:hover{transform:translateY(-2px);box-shadow:0 10px 28px rgba(30,60,100,.08);border-color:#c5d6e8}
.patient-card{position:relative;cursor:default}
.patient-card .bed-number{font-size:12px;text-transform:uppercase;letter-spacing:.08em;color:#718096}
.patient-head{display:flex;align-items:flex-start;justify-content:space-between;gap:12px}
.patient-name{font-size:19px;font-weight:900;color:#162235;margin-top:5px}
.patient-id{font-size:12px;color:#738095;margin-top:3px}
.patient-diagnosis{margin-top:12px;padding:10px 11px;border-radius:10px;background:#f7f9fc;color:#35445a;font-size:13px;line-height:1.35}
.patient-meta{display:flex;flex-wrap:wrap;gap:6px;margin-top:10px}
.patient-meta span{padding:5px 8px;background:#f2f5f8;border-radius:999px;font-size:11px;font-weight:800;color:#59677a}
.patient-actions{display:flex;gap:8px;margin-top:14px}
.patient-actions button{flex:1;padding:9px 10px;font-size:12px}
.chart-btn{background:#eaf2fb;color:#14599f}
.edit-btn{background:#1565c0;color:#fff}
.empty-bed{display:flex;flex-direction:column;gap:8px;height:100%;justify-content:center}
.empty-bed .empty-title{font-size:17px;font-weight:900}
.empty-bed .empty-sub{font-size:12px;color:#7a8494}
.full-access-note{background:#edf8f0;border-color:#d4ecd8;color:#245d2b}
.view-only-note{background:#f7f8fa;border-color:#e2e6eb;color:#566273}
.modal{background:rgba(17,27,43,.52);backdrop-filter:blur(3px);padding:24px}
.patient-editor{background:#fff;border-radius:22px;width:min(980px,100%);max-height:94vh;overflow:auto;box-shadow:0 28px 80px rgba(0,0,0,.22)}
.patient-editor-header{display:flex;justify-content:space-between;gap:18px;align-items:flex-start;padding:24px 26px 18px;border-bottom:1px solid #e9edf2;position:sticky;top:0;background:#fff;z-index:2}
.patient-editor-header h2{margin:0 0 4px;font-size:24px;letter-spacing:-.4px}
.icon-close{background:#f0f3f7;color:#4e5b6d;width:38px;height:38px;padding:0;border-radius:50%;font-size:24px;line-height:1}
.profile-section{padding:22px 26px;border-bottom:1px solid #edf0f4}
.section-heading{display:flex;align-items:center;gap:11px;margin-bottom:16px}
.section-heading>div:last-child{display:flex;flex-direction:column;gap:2px}
.section-heading strong{font-size:15px}
.section-heading span{font-size:11px;color:#7a8494}
.section-icon{width:34px;height:34px;border-radius:10px;background:#edf4fb;color:#1565c0;display:grid;place-items:center;font-size:10px;font-weight:950;letter-spacing:.04em}
.form-grid.two{grid-template-columns:1fr 1fr}
.form-grid.three{grid-template-columns:repeat(3,1fr)}
.span-2{grid-column:span 2}
.patient-form textarea{display:block;width:100%;margin-top:7px;padding:12px 13px;border:1px solid #cfd7e3;border-radius:11px;outline:none;background:#fff;color:#172033;font:inherit;resize:vertical}
.patient-form textarea:focus{border-color:#1565c0;box-shadow:0 0 0 3px rgba(21,101,192,.1)}
.editor-footer{display:flex;justify-content:flex-end;gap:9px;padding:18px 26px;position:sticky;bottom:0;background:#fff;border-top:1px solid #e9edf2}
.editor-footer .primary{width:auto;min-width:150px}
.editor-footer .secondary{min-width:100px}
.save-patient-btn{box-shadow:0 5px 14px rgba(21,101,192,.18)}
@media(max-width:900px){.bed-grid{grid-template-columns:repeat(2,minmax(0,1fr))}}
@media(max-width:650px){.bed-grid{grid-template-columns:1fr}.form-grid.two,.form-grid.three{grid-template-columns:1fr}.span-2{grid-column:auto}.patient-editor-header,.profile-section,.editor-footer{padding-left:18px;padding-right:18px}}

/* v0.15.1 — Open Chart */
.clinical-chart-shell{background:#f7f9fc;width:min(1180px,100%);max-height:94vh;overflow:auto;border-radius:22px;box-shadow:0 28px 80px rgba(0,0,0,.24)}
.clinical-chart-header{background:#fff;padding:24px 28px 18px;border-bottom:1px solid #e7ebf0;display:flex;justify-content:space-between;align-items:flex-start;position:sticky;top:0;z-index:3}
.clinical-chart-header h2{margin:0 0 4px;font-size:24px}
.clinical-chart-body{padding:20px 24px}
.chart-summary-grid{display:grid;grid-template-columns:repeat(4,1fr);gap:12px;margin-bottom:16px}
.chart-summary-card{background:#fff;border:1px solid #e3e8ef;border-radius:14px;padding:14px}
.chart-summary-card span,.latest-vitals-grid span{display:block;font-size:10px;font-weight:900;letter-spacing:.08em;color:#7a8494}
.chart-summary-card strong{display:block;margin-top:5px;font-size:16px;color:#182335;word-break:break-word}
.chart-section{background:#fff;border:1px solid #e3e8ef;border-radius:16px;padding:17px;margin-bottom:14px}
.chart-section-title{display:flex;justify-content:space-between;align-items:center;gap:12px;margin-bottom:14px}
.chart-section-title h3{margin:0 0 3px;font-size:16px}
.chart-section-title span{font-size:11px;color:#7a8494}
.chart-two-col{display:grid;grid-template-columns:1fr 1fr;gap:12px}
.chart-two-col label{font-size:10px;font-weight:900;letter-spacing:.08em;color:#7a8494;text-transform:uppercase}
.chart-text{margin-top:6px;background:#f7f9fc;border-radius:10px;padding:11px;min-height:46px;white-space:pre-wrap;line-height:1.4;font-size:13px;color:#344155}
.latest-vitals-grid{display:grid;grid-template-columns:repeat(6,1fr);gap:9px}
.latest-vitals-grid>div{background:#f7f9fc;border-radius:11px;padding:10px}
.latest-vitals-grid strong{display:block;margin-top:5px;font-size:15px}
.chart-timeline-item{border-left:3px solid #c7d3df;padding:9px 0 9px 13px;margin:8px 0}
.chart-inline-form{background:#fff;border:2px solid #dce8f4;border-radius:16px;padding:18px;margin-bottom:14px}
.chart-inline-form h3{margin-top:0}
@media(max-width:900px){.chart-summary-grid{grid-template-columns:repeat(2,1fr)}.latest-vitals-grid{grid-template-columns:repeat(3,1fr)}}
@media(max-width:650px){.clinical-chart-header{padding:18px}.clinical-chart-body{padding:14px}.chart-two-col{grid-template-columns:1fr}.latest-vitals-grid{grid-template-columns:repeat(2,1fr)}}

/* v0.16 approved 12-bed layout */
body{background:#f7f9fc}.app-shell{max-width:1180px;padding:0 18px 88px}
.icu-topbar{margin:0 -18px;padding:15px 22px;background:#083f70;color:#fff;display:flex;align-items:center;gap:24px;border-radius:0 0 18px 18px;box-shadow:0 6px 22px rgba(8,63,112,.14)}.icu-brand-row{display:flex;align-items:center;gap:10px;min-width:230px}.icu-logo-img{width:42px;height:42px;border-radius:11px;display:block;flex:0 0 42px;box-shadow:0 3px 12px rgba(0,0,0,.16)}.icu-logo{font-size:42px;color:#24c5e9}.icu-brand{font-size:25px;font-weight:900}.icu-tagline{font-size:12px;color:#bcd2e6}.icu-hospital{display:flex;align-items:center;gap:8px;flex:1}.hospital-icon{font-size:29px}.icu-hospital div:last-child{display:flex;flex-direction:column}.icu-hospital strong{font-size:14px}.icu-hospital span{font-size:11px;color:#c3d6e8}.icu-top-actions{display:flex;align-items:center;gap:8px}.icu-top-actions .badge{background:rgba(255,255,255,.15)!important;color:#fff!important}.top-icon-btn{background:transparent;color:#fff;font-size:21px}
.shift-summary{margin:15px 0 12px;background:#fff;border:1px solid #e2e8ef;border-radius:16px;padding:10px 13px;display:grid;grid-template-columns:2fr repeat(3,1fr);align-items:center;box-shadow:0 4px 18px rgba(35,63,90,.04)}.shift-day{display:flex;align-items:center;gap:9px}.sun-icon{font-size:27px}.shift-day strong{display:block;font-size:16px}.shift-day span:last-child{font-size:11px;color:#7a8799}.summary-stat{border-left:1px solid #e2e7ed;text-align:center;display:grid;grid-template-columns:auto auto;grid-template-rows:auto auto;justify-content:center;align-items:center;column-gap:5px}.summary-stat span{grid-row:1/3;font-size:19px}.summary-stat strong{font-size:17px}.summary-stat small{font-size:10px;color:#788599}.bed-icon{color:#1470cf}.person-icon{color:#22a981}.critical-icon{color:#ed2942;background:#fff0f2;border-radius:50%;width:22px;height:22px;display:grid;place-items:center}
.bed-toolbar{display:flex;gap:9px;margin:12px 0}.search-box{flex:1;background:#edf2f8;border-radius:13px;display:flex;align-items:center;padding:0 12px}.search-box span{font-size:25px;color:#71839b}.search-box input{border:0;background:transparent;margin:0;padding:11px 8px;box-shadow:none}.filter-btn{width:46px;background:#edf2f8;color:#345a7d;font-size:20px}.compact-notice{margin:7px 0 10px;padding:8px 10px;font-size:11px}
.icu-bed-grid{display:grid;grid-template-columns:repeat(2,minmax(0,1fr));gap:12px}.icu-bed-card{background:#fff;border:1px solid #dce4ed;border-radius:15px;overflow:hidden;box-shadow:0 3px 12px rgba(40,67,95,.035);min-height:180px}.icu-bed-card .bed-card-top{height:42px;padding:8px 11px;display:flex;align-items:center;gap:7px}.icu-bed-card .bed-card-top>strong{font-size:16px;flex:1}.more-dot{font-weight:950;letter-spacing:2px}.stable-card .bed-card-top{background:#d9f5e9}.unstable-card .bed-card-top{background:#fff0bf}.critical-card .bed-card-top{background:#ffd9dd}.empty-card .bed-card-top{background:#edf4fa}
.status-pill{padding:5px 8px;border-radius:999px;font-size:9px;font-weight:900}.status-pill.stable{background:#bcebdc;color:#17694f}.status-pill.unstable{background:#ffe59b;color:#6d5800}.status-pill.critical{background:#f52d43;color:#fff}.status-pill.available{background:#e5edf5;color:#56708b}
.patient-card-main{padding:9px 12px 2px;cursor:pointer}.patient-line{display:flex;justify-content:space-between;gap:7px}.patient-line strong{font-size:15px;color:#102d50}.patient-line span{font-size:11px;color:#193b61}.diagnosis-line{color:#1467b3;font-weight:800;font-size:11px;margin-top:3px;white-space:nowrap;overflow:hidden;text-overflow:ellipsis}.vitals-mini{display:grid;grid-template-columns:1fr 1fr;gap:5px 14px;margin-top:9px}.vitals-mini span{display:flex;align-items:center;gap:5px;font-size:12px}.vitals-mini i{font-style:normal;color:#4b6685;font-size:16px}.heart-mini{color:#e62d49!important}.lung-mini{color:#1aa2cf!important}.card-footer{display:flex;align-items:center;gap:6px;padding:5px 10px 10px}.task-chip{background:#edf4fc;color:#1265bd;border-radius:9px;padding:6px 8px;font-size:10px}.task-chip.danger{background:#fff0f2;color:#e52c46}.card-edit-btn{background:#eaf3fc;color:#155e9d;padding:5px 8px;font-size:9px}.empty-card-body{min-height:80px;display:flex;flex-direction:column;align-items:center;justify-content:center;color:#6f7d8e}.empty-card-body span{font-size:10px}.empty-plus{font-size:27px;color:#1672d1}.card-add-btn{margin:0 11px 10px;background:#edf5ff;color:#1265bf;padding:7px;width:calc(100% - 22px)}
.empty-page{padding:50px;text-align:center;background:#fff;border-radius:16px;color:#748196}.bed-pagination{display:flex;align-items:center;justify-content:space-between;padding:11px 2px 6px}.pager-center{text-align:center}.pager-center strong{display:block;font-size:11px;color:#4c617b;margin-top:4px}.pager-dots{display:flex;justify-content:center;gap:7px}.pager-dots span{width:8px;height:8px;border-radius:50%;background:#d9e1eb}.pager-dots span.active{background:#116ac6}.pager-arrow{background:transparent;color:#0870d4;font-size:34px;padding:0 9px}.pager-arrow:disabled{opacity:.25}.extra-bed-btn{width:100%;background:#eaf4ff;color:#0865c2;padding:12px;border-radius:13px;font-size:15px}.move-hint{text-align:center;color:#63758c;font-size:10px;padding:9px}.bottom-nav{position:fixed;bottom:0;left:50%;transform:translateX(-50%);width:min(1180px,100%);background:rgba(255,255,255,.97);backdrop-filter:blur(10px);border-top:1px solid #dfe5ec;display:grid;grid-template-columns:repeat(5,1fr);padding:7px 10px calc(7px + env(safe-area-inset-bottom));z-index:80}.bottom-nav button{position:relative;background:transparent;color:#50657e;padding:5px 3px;display:flex;flex-direction:column;align-items:center;gap:2px}.bottom-nav button span{font-size:21px}.bottom-nav button small{font-size:10px}.bottom-nav button.active{color:#0d6ed1}.bottom-nav button.active:after{content:"";height:3px;width:46px;background:#0d6ed1;border-radius:3px;position:absolute;bottom:-7px}.bottom-nav b{position:absolute;top:0;right:34%;background:#e72b43;color:#fff;border-radius:99px;font-size:9px;min-width:18px;padding:2px 5px}

/* Add clinical-action dialogs intentionally have no floating title/X header.
   The dialog is a single white surface with only Cancel + Save in the footer. */
#chartActionModal #chartActionForm > .action-head{display:none!important;}
#chartActionModal .icon-close{display:none!important;}

@media(max-width:760px){.app-shell{padding:0 10px 86px}.icu-topbar{margin:0 -10px;padding:13px;gap:7px}.icu-brand-row{min-width:0;flex:1}.icu-logo-img{width:34px;height:34px;flex-basis:34px;border-radius:9px}.icu-logo{font-size:36px}.icu-brand{font-size:21px}.icu-hospital{display:none}.icu-top-actions .badge,.icu-top-actions #coordinatorBtn{display:none}.shift-summary{grid-template-columns:1.65fr repeat(3,1fr);padding:9px 5px}.summary-stat{padding-left:5px}.icu-bed-grid{gap:8px}.icu-bed-card{min-height:178px}.icu-bed-card .bed-card-top{padding:8px}.icu-bed-card .bed-card-top>strong{font-size:13px}.status-pill{font-size:8px;padding:4px 6px}.patient-card-main{padding:8px}.patient-line strong{font-size:12px}.patient-line span{font-size:9px}.diagnosis-line{font-size:9px}.vitals-mini{gap:4px}.vitals-mini span{font-size:9px}.vitals-mini i{font-size:13px}.card-footer{padding:4px 7px 8px}.task-chip{font-size:8px;padding:5px 6px}.card-open-btn{font-size:24px}}

/* Persistent session + in-app back navigation */
.clinical-chart-header{position:relative}.back-button{background:transparent;color:#126ac5;border:0;font-weight:800;font-size:13px;padding:6px 4px;white-space:nowrap}.clinical-chart-header .back-button{margin-right:4px}.back-button:hover{background:#eef6ff;border-radius:8px}

/* Add clinical-action dialogs intentionally have no floating title/X header.
   The dialog is a single white surface with only Cancel + Save in the footer. */
#chartActionModal #chartActionForm > .action-head{display:none!important;}
#chartActionModal .icon-close{display:none!important;}

@media(max-width:760px){.clinical-chart-header{gap:6px}.clinical-chart-header .back-button{font-size:12px}}

/* v0.16.15 interaction + clinical modules */
.icu-bed-card{touch-action:pan-y;user-select:none}.icu-bed-card.drag-source{transform:scale(.98);box-shadow:0 0 0 3px #1672d1,0 12px 30px rgba(16,70,120,.18);opacity:.82}.icu-bed-card.drop-target{box-shadow:0 0 0 3px #22a981,0 12px 30px rgba(34,169,129,.18)}
.notification-action{position:relative}.notification-badge{position:absolute;top:-2px;right:-2px;background:#e72b43;color:#fff;border-radius:99px;font-size:8px;min-width:16px;padding:2px 4px}.alarm-center{background:#fff;width:min(680px,94vw);max-height:82vh;overflow:auto;border-radius:18px;padding:18px;box-shadow:0 20px 70px rgba(0,0,0,.22)}.alarm-list{display:flex;flex-direction:column;gap:9px}.alarm-row{display:flex;justify-content:space-between;gap:12px;padding:12px;border:1px solid #e2e8ef;border-radius:12px;background:#f9fbfd}.alarm-row.urgent{border-color:#ffb6bf;background:#fff4f5}.alarm-row strong{display:block;color:#12385e}.alarm-row span{font-size:10px;color:#73839a}.alarm-row p{margin:5px 0 0;font-size:12px;color:#506174}.clinical-chart-page{position:fixed;inset:0;background:#f7f9fc;z-index:150;overflow:auto;display:block}.clinical-chart-page.hidden{display:none!important;pointer-events:none!important;}.clinical-chart-shell{width:100%;min-height:100vh;overflow:visible;background:#f7f9fc}.clinical-chart-header{position:sticky;top:0;z-index:30;background:#083f70;color:#fff;padding:14px 18px;display:flex;align-items:center;gap:14px}.clinical-chart-header>div{flex:1}.clinical-chart-header h2{margin:2px 0;font-size:20px}.clinical-chart-header .muted{color:#c4d7e9}.back-button{background:transparent;color:#fff;font-size:14px;font-weight:700;padding:8px 10px;white-space:nowrap}.patient-editor{z-index:310}.clinical-chart-header{position:sticky;top:0;z-index:3;background:#083f70;color:#fff;padding:14px 18px;display:flex;align-items:center;gap:14px}.clinical-chart-header>div{flex:1}.clinical-chart-header h2{margin:2px 0;font-size:20px}.clinical-chart-header .muted{color:#c4d7e9}.back-button{background:transparent;color:#fff;font-size:20px;padding:6px 8px}.chart-patient-strip{display:grid;grid-template-columns:2fr repeat(3,1fr);gap:1px;background:#dfe6ef}.chart-patient-strip>div{background:#fff;padding:10px 14px}.chart-patient-strip span{display:block;font-size:9px;color:#7a899c}.chart-patient-strip strong{font-size:12px;color:#153c62}.chart-tabs{display:flex;overflow:auto;background:#fff;border-bottom:1px solid #dfe5ec;padding:0 12px;position:sticky;top:74px;z-index:2}.chart-tabs button{background:transparent;color:#50657e;padding:11px 14px;border-bottom:3px solid transparent;white-space:nowrap}.chart-tabs button.active{color:#0b6dcc;border-bottom-color:#0b6dcc;font-weight:800}.clinical-chart-body{padding:14px}.chart-tab-panel{display:none}.chart-tab-panel.active{display:block}.clinical-grid-cards{display:grid;grid-template-columns:repeat(2,minmax(0,1fr));gap:12px}.chart-section{background:#fff;border:1px solid #e0e6ed;border-radius:15px;padding:13px;margin-bottom:12px}.chart-section-title{display:flex;justify-content:space-between;align-items:center;gap:10px;margin-bottom:10px}.chart-section-title h3{margin:0;color:#143c62;font-size:15px}.chart-section-title span{font-size:10px;color:#7b8999}.chart-two-col{display:grid;grid-template-columns:1fr 1fr;gap:10px}.chart-two-col label{font-size:9px;color:#738299}.chart-text{font-size:11px;color:#40566f;white-space:pre-wrap;margin-top:3px}.clinical-list-row{display:grid;grid-template-columns:1.3fr 2fr auto;gap:9px;align-items:center;padding:9px 0;border-bottom:1px solid #edf1f5;font-size:11px}.clinical-list-row:last-child{border-bottom:0}.clinical-list-row strong{color:#173e62}.clinical-list-row span{color:#53667b}.clinical-list-row small{color:#8794a5}.clinical-note{padding:10px;border:1px solid #e4eaf0;border-radius:11px;margin-bottom:8px}.clinical-note strong{font-size:10px;color:#1c609c}.clinical-note small{float:right;color:#8997a7;font-size:9px}.clinical-note p{font-size:12px;white-space:pre-wrap;margin:7px 0 0;color:#40556b}.fluid-balance-card{display:grid;grid-template-columns:repeat(3,1fr);gap:8px}.fluid-balance-card div{background:#eef5fb;border-radius:10px;padding:10px;text-align:center}.fluid-balance-card span{display:block;font-size:9px;color:#6c7d91}.fluid-balance-card strong{font-size:14px;color:#174d79}.trend-wrap{min-height:130px}.trend-svg{width:100%;height:230px}.trend-svg line{stroke:#d7e0e9;stroke-width:1}.trend-svg text{fill:#718197;font-size:12px}.trend-line{fill:none;stroke-width:3}.trend-line.hr{stroke:#e62d49}.trend-line.spo{stroke:#1b8ec4}.trend-legend{display:flex;gap:20px;font-size:10px;color:#65758a}.chart-timeline-item{padding:8px 0;border-bottom:1px solid #edf1f5}.timeline-time{font-size:9px;color:#8290a0}.unified-timeline-item{display:grid;grid-template-columns:18px 1fr;gap:8px;padding:10px 0;border-bottom:1px solid #e9eef3}.timeline-dot{width:9px;height:9px;background:#1372ce;border-radius:50%;margin-top:4px}.unified-timeline-item small{display:block;font-size:9px;color:#7d8b9c}.unified-timeline-item strong{display:block;font-size:12px;color:#294c6d;margin-top:2px}.chart-action-modal{position:fixed;inset:0;background:rgba(5,25,45,.48);display:flex;align-items:center;justify-content:center;z-index:200;padding:15px}.chart-action-modal.hidden{display:none}.chart-action-modal>form,.chart-action-modal{ }.chart-action-modal #chartActionForm{background:#fff;width:min(720px,94vw);max-height:88vh;overflow:auto;border-radius:17px;padding:18px}.action-head{display:flex;justify-content:space-between;align-items:center;margin-bottom:12px;color:#153c62}.check-label{display:flex;align-items:center;gap:7px}.check-label input{width:auto}

/* Add clinical-action dialogs intentionally have no floating title/X header.
   The dialog is a single white surface with only Cancel + Save in the footer. */
#chartActionModal #chartActionForm > .action-head{display:none!important;}
#chartActionModal .icon-close{display:none!important;}

@media(max-width:760px){.clinical-grid-cards{grid-template-columns:1fr}.chart-patient-strip{grid-template-columns:1.5fr repeat(3,1fr)}.chart-patient-strip>div{padding:8px}.chart-patient-strip strong{font-size:10px}.chart-tabs{top:64px}.clinical-chart-header{padding:11px}.clinical-chart-body{padding:9px}.clinical-list-row{grid-template-columns:1fr;gap:2px}.chart-two-col{grid-template-columns:1fr}.trend-svg{height:180px}.icu-top-actions{gap:2px}.icu-top-actions .top-icon-btn{font-size:16px;padding:4px}}
/* Bnercrit master-baseline interaction hardening */
.clinical-data-warning{display:flex;gap:8px;align-items:flex-start;margin:10px 14px 0;padding:10px 12px;border:1px solid #f0d58a;background:#fff9e8;color:#6d5700;border-radius:11px;font-size:10px;line-height:1.45}.clinical-data-warning strong{white-space:nowrap}.clinical-data-warning span{color:#806f3c}.clinical-data-warning.hidden{display:none}
.icu-bed-grid{touch-action:pan-y}.icu-bed-card{cursor:grab;-webkit-user-select:none;user-select:none;-webkit-touch-callout:none}.icu-bed-card.drag-source{cursor:grabbing;position:relative;z-index:20;transform:scale(.985);box-shadow:0 0 0 3px #1672d1,0 18px 34px rgba(16,70,120,.2);opacity:.88}.icu-bed-card.drop-target{box-shadow:0 0 0 3px #22a981,0 12px 30px rgba(34,169,129,.18)}.icu-bed-card:active{cursor:grabbing}

.build-badge{font-size:9px;background:rgba(255,255,255,.16);color:#fff;border:1px solid rgba(255,255,255,.22);border-radius:999px;padding:4px 7px}.extra-bed-dialog{background:#fff;width:min(520px,94vw);border-radius:18px;padding:18px;box-shadow:0 25px 80px rgba(0,0,0,.24)}#extraBedModal{position:fixed;inset:0;background:rgba(5,25,45,.48);display:flex;align-items:center;justify-content:center;z-index:250;padding:15px}#extraBedModal.hidden{display:none}

/* Add clinical-action dialogs intentionally have no floating title/X header.
   The dialog is a single white surface with only Cancel + Save in the footer. */
#chartActionModal #chartActionForm > .action-head{display:none!important;}
#chartActionModal .icon-close{display:none!important;}

@media(max-width:760px){.build-badge{display:none}.extra-bed-dialog{width:100%;padding:16px}}

/* v0.17.3 — Modern clinical visual system: inspired by approved reference, refined for production */
:root{
  --bn-navy:#073b69;
  --bn-navy-2:#0a4b7f;
  --bn-blue:#0877dc;
  --bn-cyan:#22c7ec;
  --bn-ink:#102d4d;
  --bn-muted:#63758d;
  --bn-surface:#ffffff;
  --bn-page:#f5f8fc;
  --bn-line:#dce7f2;
  --bn-stable:#d9f4e9;
  --bn-stable-ink:#087a58;
  --bn-unstable:#fff1bf;
  --bn-unstable-ink:#8a6500;
  --bn-critical:#ffdce0;
  --bn-critical-ink:#e32342;
  --bn-shadow:0 8px 28px rgba(20,61,99,.07);
}
html{background:var(--bn-page)}
body{background:linear-gradient(180deg,#f7faff 0%,#f3f7fb 100%);color:var(--bn-ink)}
.app-shell{max-width:1180px;padding:0 18px 96px}
.icu-topbar{
  margin:0 -18px;
  padding:16px 22px 15px;
  min-height:82px;
  background:linear-gradient(110deg,var(--bn-navy) 0%,#084a7c 55%,#0b568c 100%);
  border-radius:0 0 22px 22px;
  box-shadow:0 8px 28px rgba(3,48,83,.18);
}
.icu-brand-row{gap:11px;min-width:255px}
.icu-logo{width:43px;height:43px;display:grid;place-items:center;font-size:39px;line-height:1;color:var(--bn-cyan);filter:drop-shadow(0 3px 5px rgba(0,0,0,.1))}
.icu-brand{font-size:26px;letter-spacing:-.6px;line-height:1.05;color:#fff}
.icu-tagline{font-size:11px;color:#b9d3e7;margin-top:4px;letter-spacing:.01em}
.icu-hospital{gap:9px}
.hospital-icon{font-size:27px}
.icu-hospital strong{font-size:14px;color:#fff}
.icu-hospital span{font-size:11px;color:#bfd7e9;margin-top:2px}
.icu-top-actions{gap:7px}
.top-icon-btn{width:38px;height:38px;display:grid;place-items:center;padding:0;border-radius:11px;background:rgba(255,255,255,.10);color:#fff;font-size:19px;border:1px solid rgba(255,255,255,.10)}
.top-icon-btn:hover{background:rgba(255,255,255,.17)}
.build-badge{display:none}
.shift-summary{
  margin:14px 0 12px;
  padding:11px 14px;
  border:1px solid var(--bn-line);
  border-radius:17px;
  box-shadow:var(--bn-shadow);
  background:rgba(255,255,255,.96);
}
.shift-day{gap:10px}
.sun-icon{font-size:28px;color:#f7b820}
.shift-day strong{font-size:15px;color:var(--bn-ink)}
.shift-day span:last-child{font-size:11px;color:var(--bn-muted);margin-top:2px}
.summary-stat{border-left:1px solid #e5ecf3}
.summary-stat span{font-size:19px}
.summary-stat strong{font-size:18px;color:var(--bn-ink)}
.summary-stat small{font-size:10px;color:var(--bn-muted)}
.bed-toolbar{margin:10px 0 13px;gap:9px}
.search-box{background:#eaf1f8;border:1px solid transparent;min-height:45px;border-radius:14px;transition:.15s ease}
.search-box:focus-within{background:#fff;border-color:#b9d4ec;box-shadow:0 0 0 3px rgba(8,119,220,.08)}
.search-box span{font-size:24px;color:#6b829a}
.search-box input{font-size:14px;color:var(--bn-ink)}
.search-box input::placeholder{color:#7a8da4}
.filter-btn{width:45px;min-height:45px;border-radius:14px;background:#eaf1f8;color:#315d82;border:1px solid transparent}
.compact-notice{border-radius:12px;font-size:11px}
.icu-bed-grid{gap:11px;grid-template-columns:repeat(2,minmax(0,1fr))}
.icu-bed-card{
  min-height:188px;
  border:1px solid var(--bn-line);
  border-radius:17px;
  box-shadow:0 4px 16px rgba(25,64,101,.045);
  transition:transform .16s ease,box-shadow .16s ease,border-color .16s ease;
  overflow:hidden;
}
.icu-bed-card:hover{transform:translateY(-1px);box-shadow:0 10px 24px rgba(25,64,101,.08);border-color:#c7d9e9}
.icu-bed-card .bed-card-top{height:43px;padding:8px 11px;gap:7px}
.stable-card .bed-card-top{background:linear-gradient(90deg,#d7f3e8,#e5f8f0)}
.unstable-card .bed-card-top{background:linear-gradient(90deg,#fff0bb,#fff5cf)}
.critical-card .bed-card-top{background:linear-gradient(90deg,#ffd9de,#ffe5e8)}
.empty-card .bed-card-top{background:#edf4fa}
.icu-bed-card .bed-card-top>strong{font-size:16px;color:#102d4d}
.status-pill{font-size:9px;padding:5px 8px;letter-spacing:.02em}
.status-pill.stable{background:#bfead9;color:#087556}
.status-pill.unstable{background:#ffe5a1;color:#785900}
.status-pill.critical{background:#ff304d;color:#fff}
.status-pill.available{background:#e2edf6;color:#42627d}
.patient-card-main{padding:9px 11px 6px}
.patient-line{align-items:baseline}
.patient-line strong{font-size:15px;color:#102d4d;letter-spacing:-.15px}
.patient-line span{font-size:11px;color:#506982;white-space:nowrap}
.diagnosis-line{font-size:11px;color:#1467b3;font-weight:800;margin-top:5px;min-height:15px}
.vitals-mini{gap:9px;margin-top:12px}
.vitals-mini span{font-size:11px;color:#274764;display:inline-flex;align-items:center;gap:4px}
.vitals-mini i{font-style:normal;font-size:15px}
.heart-mini{color:#ee2746}.lung-mini{color:#1597c6}
.card-footer{padding:5px 9px 9px;gap:6px}
.task-chip{font-size:9px;padding:6px 8px;background:#eaf3ff;color:#1769b4;border-radius:10px}
.task-chip.danger{background:#ffe4e8;color:#dc2440}

.card-edit-btn{font-size:9px;border-radius:9px;padding:6px 9px;background:#eef5fc;color:#25628f}
.empty-card-body{padding:15px 10px 8px;gap:5px}
.empty-plus{width:38px;height:38px;border-radius:50%;display:grid;place-items:center;background:#eaf3ff;color:#0877dc;font-size:25px}
.empty-card-body strong{font-size:13px;color:#294864}
.empty-card-body span{font-size:10px;color:#8091a3}
.card-add-btn{margin:0 9px 10px;width:calc(100% - 18px);background:#eaf4ff;color:#0870ce;font-size:11px;border-radius:10px}
.bed-pagination{padding:12px 2px 7px}
.pager-center strong{font-size:11px;color:#4c617b}
.pager-dots{gap:6px}
.pager-dots span{width:8px;height:8px}
.pager-dots span.active{background:#0877dc;box-shadow:0 0 0 3px rgba(8,119,220,.09)}
.pager-arrow{font-size:31px;color:#0877dc;width:38px;height:38px;border-radius:11px}
.pager-arrow:hover:not(:disabled){background:#eaf4ff}
.extra-bed-btn{margin-top:3px;min-height:45px;background:#e8f3ff;border:1px solid #d6e8f8;color:#086ac9;border-radius:14px;font-size:14px;box-shadow:none}
.extra-bed-btn:hover{background:#e1effd}
.move-hint{font-size:10px;color:#6b7e94;padding:8px}
.bottom-nav{width:min(1180px,100%);padding:8px 12px calc(8px + env(safe-area-inset-bottom));border-top:1px solid #dce6ef;box-shadow:0 -8px 24px rgba(25,64,101,.06)}
.bottom-nav button{color:#587089;border-radius:12px}
.bottom-nav button.active{color:#0870d1}
.bottom-nav button.active:after{background:#0877dc;height:3px;width:42px}
.bottom-nav button span{font-size:22px}
.bottom-nav button small{font-size:10px;font-weight:650}
.bottom-nav b{top:0;right:31%;background:#ed2946;box-shadow:0 0 0 2px #fff}

@media(min-width:761px){
  .icu-bed-grid{grid-template-columns:repeat(2,minmax(0,1fr))}
}

/* Add clinical-action dialogs intentionally have no floating title/X header.
   The dialog is a single white surface with only Cancel + Save in the footer. */
#chartActionModal #chartActionForm > .action-head{display:none!important;}
#chartActionModal .icon-close{display:none!important;}

@media(max-width:760px){
  .app-shell{padding:0 10px 88px}
  .icu-topbar{margin:0 -10px;padding:13px 13px 14px;min-height:76px;border-radius:0 0 18px 18px}
  .icu-logo{width:37px;height:37px;font-size:34px}
  .icu-brand{font-size:21px}
  .icu-tagline{font-size:10px;margin-top:3px}
  .icu-top-actions{gap:5px}
  .icu-top-actions .top-icon-btn{width:35px;height:35px;font-size:17px}
  .icu-hospital{display:flex;flex:0 0 auto}
  .icu-hospital .hospital-icon{display:none}
  .icu-hospital strong{font-size:10px;text-align:right;display:block}
  .icu-hospital span{font-size:8px;text-align:right;display:block}
  .shift-summary{grid-template-columns:1.55fr repeat(3,1fr);padding:9px 5px;border-radius:15px}
  .shift-day{gap:7px;padding-left:3px}
  .sun-icon{font-size:25px}
  .shift-day strong{font-size:13px}
  .shift-day span:last-child{font-size:9px}
  .summary-stat{padding-left:4px;column-gap:3px}
  .summary-stat span{font-size:16px}
  .summary-stat strong{font-size:15px}
  .summary-stat small{font-size:8px}
  .icu-bed-grid{grid-template-columns:repeat(2,minmax(0,1fr));gap:8px}
  .icu-bed-card{min-height:184px;border-radius:15px}
  .icu-bed-card .bed-card-top{height:40px;padding:7px 8px}
  .icu-bed-card .bed-card-top>strong{font-size:13px}
  .patient-card-main{padding:8px 8px 5px}
  .patient-line strong{font-size:12px}
  .patient-line span{font-size:9px}
  .diagnosis-line{font-size:9px;margin-top:4px;white-space:nowrap;overflow:hidden;text-overflow:ellipsis}
  .vitals-mini{gap:4px;margin-top:10px;justify-content:space-between}
  .vitals-mini span{font-size:9px;gap:2px}
  .vitals-mini i{font-size:13px}
  .card-footer{padding:4px 7px 8px}
  .task-chip{font-size:8px;padding:5px 6px}

  .status-pill{font-size:7px;padding:4px 6px}
  .more-dot{font-size:12px}
  .bottom-nav{padding-left:8px;padding-right:8px}
}

/* v0.17.4 Patient Profile — modular critical-care layout */
.patient-profile-sections{display:flex;flex-direction:column;gap:10px;max-width:980px;margin:0 auto}
.profile-section{background:#fff;border:1px solid #dfe7ef;border-radius:17px;overflow:hidden;box-shadow:0 5px 18px rgba(15,55,90,.055);transition:border-color .18s,box-shadow .18s}
.profile-section:hover{border-color:#c9d8e7;box-shadow:0 8px 24px rgba(15,55,90,.08)}
.profile-section-head{display:flex;align-items:center;justify-content:space-between;gap:10px;min-height:68px;padding:8px 12px;background:linear-gradient(180deg,#ffffff,#f8fbfe)}
.profile-section-main{display:flex;align-items:center;gap:12px;flex:1;text-align:left;background:transparent;padding:8px 4px;color:#143c62}
.profile-section-icon{width:40px;height:40px;border-radius:12px;display:grid;place-items:center;background:#edf6fc;font-size:21px;flex:none}
.profile-section-main strong{display:block;font-size:15px;line-height:1.15}
.profile-section-main small{display:block;margin-top:4px;font-size:10px;color:#8190a1;font-weight:700;text-transform:uppercase;letter-spacing:.05em}
.profile-section-actions{display:flex;align-items:center;gap:5px}
.profile-state-btn{border:1px solid #d9e4ed;background:#f7fafc;color:#5d7185;border-radius:10px;padding:7px 9px;font-size:10px;font-weight:800}
.profile-chevron{width:34px;height:34px;border-radius:10px;background:#edf5fb;color:#1767a7;font-size:20px;padding:0;display:grid;place-items:center}
.profile-section-body{padding:0 14px 15px}
.profile-section.is-collapsed .profile-section-body,.profile-section.is-na .profile-section-body{display:none}
.profile-section.is-collapsed .profile-section-head{border-bottom:0}
.profile-section.is-na{opacity:.78;background:#f8fafc}
.profile-section.is-na .profile-section-head{background:#f4f7fa}
.profile-hero{display:flex;align-items:center;gap:13px;padding:8px 0 15px;border-bottom:1px solid #edf2f6;margin-bottom:12px}
.profile-avatar{width:56px;height:56px;border-radius:17px;background:linear-gradient(135deg,#0b548b,#14a6c8);color:#fff;display:grid;place-items:center;font-size:24px;font-weight:900;box-shadow:0 8px 18px rgba(11,84,139,.18)}
.profile-hero-main{flex:1;min-width:0}.profile-name-row{display:flex;align-items:center;gap:8px;flex-wrap:wrap}.profile-name-row h3{margin:0;color:#123c63;font-size:18px}.profile-hero-main p{margin:4px 0 0;color:#65778a;font-size:11px}.profile-edit{white-space:nowrap}
.profile-status{display:inline-flex;align-items:center;border-radius:999px;padding:5px 9px;font-size:9px;font-weight:900;text-transform:uppercase;letter-spacing:.04em}.profile-status.stable{background:#d8f5e9;color:#087650}.profile-status.unstable{background:#fff0bd;color:#7c5b00}.profile-status.critical{background:#ffe0e4;color:#c51f37}
.profile-data-grid{display:grid;grid-template-columns:repeat(3,minmax(0,1fr));gap:8px}
.profile-data-item{padding:10px 11px;background:#f7fafc;border:1px solid #e7edf3;border-radius:12px;min-width:0}.profile-data-item span{display:block;font-size:9px;color:#7b8a9a;font-weight:700;text-transform:uppercase;letter-spacing:.035em;margin-bottom:4px}.profile-data-item strong{display:block;color:#183f62;font-size:12px;line-height:1.35;word-break:break-word}
.profile-highlight{padding:12px 13px;background:#fff5f6;border-left:4px solid #ed2945;border-radius:11px;color:#5e2630;font-size:12px;font-weight:700;margin-bottom:10px}
.profile-list-row{display:grid;grid-template-columns:1.2fr 2fr auto;gap:10px;align-items:center;padding:10px 0;border-bottom:1px solid #edf1f5;font-size:11px}.profile-list-row:last-child{border-bottom:0}.profile-list-row strong{color:#173f63}.profile-list-row span{color:#52677d}.profile-list-row small{color:#8a98a7;font-size:9px;text-align:right}.task-status{font-weight:800}.task-status.overdue{color:#c5223c}.task-status.due-soon{color:#9a6a00}.task-status.completed{color:#13805a}

/* Add clinical-action dialogs intentionally have no floating title/X header.
   The dialog is a single white surface with only Cancel + Save in the footer. */
#chartActionModal #chartActionForm > .action-head{display:none!important;}
#chartActionModal .icon-close{display:none!important;}

@media(max-width:760px){.patient-profile-sections{gap:8px}.profile-section-head{min-height:62px;padding:7px 9px}.profile-section-icon{width:36px;height:36px;font-size:19px;border-radius:11px}.profile-section-main{gap:9px}.profile-section-main strong{font-size:14px}.profile-state-btn{padding:6px 7px;font-size:9px}.profile-chevron{width:31px;height:31px}.profile-section-body{padding:0 10px 12px}.profile-hero{align-items:flex-start;flex-wrap:wrap}.profile-avatar{width:48px;height:48px;font-size:20px}.profile-name-row h3{font-size:16px}.profile-edit{margin-left:58px;margin-top:-4px}.profile-data-grid{grid-template-columns:repeat(2,minmax(0,1fr))}.profile-data-item{padding:9px}.profile-list-row{grid-template-columns:1fr;gap:3px}.profile-list-row small{text-align:left}}
/* v0.17.7 Patient Profile vertical clinical layout */
.clinical-profile-titlebar{display:flex;align-items:center;justify-content:space-between;gap:12px;padding:14px 2px 10px}.clinical-profile-titlebar h2{margin:2px 0 2px;font-size:22px;color:#123b60}.clinical-profile-titlebar .muted{font-size:11px}.profile-access-badge{font-size:10px;font-weight:900;padding:7px 10px;border-radius:999px;white-space:nowrap}.profile-access-badge.full{background:#d9f5e9;color:#17694f}.profile-access-badge.view{background:#e8eef5;color:#536b84}
.patient-profile-sections{display:flex;flex-direction:column;gap:10px;padding-bottom:24px}.patient-profile-sections .profile-section{margin:0!important;border:1px solid #dfe7ef;border-radius:15px;background:#fff;box-shadow:0 3px 12px rgba(25,55,85,.045);overflow:hidden}.patient-profile-sections .profile-section-head{display:flex;align-items:center;min-height:54px;padding:0 11px;background:#fbfdff}.patient-profile-sections .profile-section-main{flex:1;min-width:0;display:flex;align-items:center;gap:9px;background:transparent;border:0;text-align:left;padding:8px 0}.patient-profile-sections .profile-section-main strong{font-size:14px;color:#123b60}.patient-profile-sections .profile-section-main small{display:block;font-size:9px;color:#7b8da0;margin-top:2px}.patient-profile-sections .profile-section-actions{display:flex;align-items:center;gap:5px}.patient-profile-sections .profile-edit-section{background:#eaf4ff;color:#0b69c7;border:1px solid #cfe4f7;border-radius:9px;padding:6px 9px;font-size:10px;font-weight:800}.patient-profile-sections .profile-state-btn{background:transparent;color:#74869a;border:0;font-size:9px;padding:5px}.patient-profile-sections .profile-chevron{background:transparent;color:#1a6db3;border:0;font-size:23px;padding:4px 2px;min-width:25px}.patient-profile-sections .profile-section-body{padding:0 11px 11px}.patient-profile-sections .profile-data-grid{display:grid;grid-template-columns:repeat(2,minmax(0,1fr));gap:7px}.patient-profile-sections .profile-data-item{background:#f6f9fc;border-radius:9px;padding:7px 8px}.patient-profile-sections .profile-data-item span{display:block;font-size:9px;color:#718298}.patient-profile-sections .profile-data-item strong{display:block;font-size:11px;color:#183d60;margin-top:2px;overflow-wrap:anywhere}.patient-profile-sections .profile-list-row{display:grid;grid-template-columns:1.1fr 1.6fr auto;gap:8px;align-items:center;padding:8px 0;border-bottom:1px solid #edf1f5;font-size:10px}.patient-profile-sections .profile-list-row:last-child{border-bottom:0}.patient-profile-sections .profile-list-row strong{color:#244b6e}.patient-profile-sections .profile-list-row span{color:#5e7085}.patient-profile-sections .profile-list-row small{color:#8997a7;font-size:8px}.patient-profile-sections .profile-list-row.clinical-record > div{min-width:0;display:block}.patient-profile-sections .profile-list-row.clinical-record > div > strong{display:block;line-height:1.35;margin-bottom:6px}.patient-profile-sections .profile-list-row.clinical-record > div > span{display:block;line-height:1.55;margin-top:4px;white-space:normal;overflow-wrap:anywhere}.patient-profile-sections .profile-list-row.clinical-record > div > small{display:block;text-align:left;line-height:1.4;margin-top:7px}.clinical-list-row > div{min-width:0}.clinical-list-row > div > strong{display:block;line-height:1.35;margin-bottom:5px}.clinical-list-row > div > span{display:block;line-height:1.5;margin-top:3px;white-space:normal;overflow-wrap:anywhere}.clinical-list-row > div > small{display:block;line-height:1.4;margin-top:6px;text-align:left}.patient-profile-sections .profile-highlight{background:#fff8e8;border-left:3px solid #e6b52f;padding:9px;border-radius:8px;margin-bottom:8px;font-size:11px;color:#5d501d}.patient-profile-sections .profile-status{display:inline-block;border-radius:999px;padding:4px 7px;font-size:9px;font-weight:900}.patient-profile-sections .profile-status.stable{background:#c9efdf;color:#17694f}.patient-profile-sections .profile-status.unstable{background:#ffe8a7;color:#715900}.patient-profile-sections .profile-status.critical{background:#ffd8dd;color:#b71e35}.patient-profile-sections .profile-hero{display:flex;align-items:center;gap:10px;padding:5px 0 10px}.patient-profile-sections .profile-avatar{width:42px;height:42px;border-radius:12px;background:#e8f5ff;color:#0b6ec8;display:grid;place-items:center;font-size:17px;font-weight:900}.patient-profile-sections .profile-hero-main{flex:1;min-width:0}.patient-profile-sections .profile-name-row{display:flex;align-items:center;gap:6px}.patient-profile-sections .profile-name-row h3{font-size:15px;margin:0;color:#123b60;overflow:hidden;text-overflow:ellipsis;white-space:nowrap}.patient-profile-sections .profile-hero-main p{font-size:10px;color:#66788c;margin:3px 0 0;overflow:hidden;text-overflow:ellipsis;white-space:nowrap}.patient-profile-sections .profile-edit{font-size:10px;padding:7px 9px}.patient-profile-sections .profile-section.na .profile-section-body{display:none}.patient-profile-sections .profile-section.na .profile-section-head{opacity:.72}

/* Add clinical-action dialogs intentionally have no floating title/X header.
   The dialog is a single white surface with only Cancel + Save in the footer. */
#chartActionModal #chartActionForm > .action-head{display:none!important;}
#chartActionModal .icon-close{display:none!important;}

@media(max-width:760px){.clinical-profile-titlebar h2{font-size:19px}.clinical-profile-titlebar{padding:10px 0 8px}.patient-profile-sections{gap:8px}.patient-profile-sections .profile-list-row{grid-template-columns:1fr;gap:2px}.patient-profile-sections .profile-list-row small{justify-self:start}.patient-profile-sections .profile-data-grid{grid-template-columns:1fr 1fr}.patient-profile-sections .profile-section-main strong{font-size:12px}.patient-profile-sections .profile-edit-section{padding:5px 7px}}

/* v0.17.8 Patient Profile title + Add actions */
.clinical-profile-titlebar{width:100%;text-align:center;display:flex;justify-content:center;align-items:center;padding:14px 8px 12px;border-bottom:1px solid #e3eaf2;background:#fff;}
.clinical-profile-titlebar>div{display:flex;flex-direction:column;align-items:center;}
.clinical-profile-titlebar .eyebrow{letter-spacing:1.8px;font-size:10px;font-weight:900;color:#0b6b9f;}
.clinical-profile-titlebar h2{margin:4px 0 2px;color:#123b60;font-size:22px;font-weight:900;}
.clinical-profile-titlebar .muted{font-size:10px;color:#718399;margin:0;}
.patient-profile-sections .profile-edit-section{display:inline-flex!important;align-items:center;justify-content:center;visibility:visible!important;opacity:1!important;}

/* Add clinical-action dialogs intentionally have no floating title/X header.
   The dialog is a single white surface with only Cancel + Save in the footer. */
#chartActionModal #chartActionForm > .action-head{display:none!important;}
#chartActionModal .icon-close{display:none!important;}

@media(max-width:760px){.clinical-profile-titlebar{padding:12px 6px 10px}.clinical-profile-titlebar h2{font-size:20px}.clinical-profile-titlebar .eyebrow{font-size:9px}.clinical-profile-titlebar .muted{font-size:9px}}
.task-action-row{display:flex;align-items:center;justify-content:space-between;gap:12px}.task-inline-actions{display:flex;gap:6px;flex-wrap:wrap;justify-content:flex-end}.task-inline-actions button{white-space:nowrap}.alarm-row{display:flex;align-items:center;justify-content:space-between;gap:14px}.alarm-row>div:first-child{min-width:0}.alarm-row p{margin:.25rem 0}.alarm-row .task-inline-actions{flex:0 0 auto}

/* v0.17.19: End Patient Stay modal must be fully opaque */
.end-stay-card{background:#fff;border:1px solid #dbe5ee;border-radius:14px;padding:16px}
#actionModal .chart-action-modal, #endStayModal .chart-action-modal, .chart-action-modal:has(#endStayForm){background:rgba(5,25,45,.62)}
#endStayForm{background:#fff!important;opacity:1!important}
#endStayForm input,#endStayForm select,#endStayForm textarea{background:#fff!important;opacity:1!important}


/* v0.17.23 — Patient Profile standalone page */
.clinical-chart-page{position:fixed;inset:0;background:#f7f9fc;z-index:150;overflow:auto;display:block}
.clinical-chart-page.hidden{display:none!important;pointer-events:none!important;}
.clinical-chart-page .clinical-chart-shell{width:100%;min-height:100vh;max-height:none;overflow:visible;background:#f7f9fc;border-radius:0;box-shadow:none}
.clinical-chart-page .clinical-chart-header{position:sticky;top:0;z-index:30;background:#083f70;color:#fff;padding:14px 18px;display:flex;align-items:center;gap:14px}
.clinical-chart-page .clinical-chart-header>div{flex:1}
.clinical-chart-page .clinical-chart-header h2{margin:2px 0;font-size:20px}
.clinical-chart-page .clinical-chart-header .muted{color:#c4d7e9}
.clinical-chart-page .back-button{background:transparent;color:#fff;font-size:14px;font-weight:700;padding:8px 10px;white-space:nowrap}
#patientModal{z-index:300}


/* v0.17.24 — standalone patient route + mobile dashboard header hardening */
.icu-topbar{min-width:0;overflow:hidden}.icu-brand-row{min-width:0}.icu-top-actions{min-width:0;max-width:52%;flex-shrink:1;display:flex;align-items:center;justify-content:flex-end;overflow:hidden}.icu-top-actions .top-icon-btn{flex:0 0 auto}.icu-hospital{min-width:0;flex-shrink:1}.icu-hospital>div:last-child{min-width:0}.icu-hospital strong,.icu-hospital span{overflow:hidden;text-overflow:ellipsis;white-space:nowrap}.clinical-chart-page{position:fixed!important;inset:0!important;width:100vw;height:100dvh;overflow-y:auto;overflow-x:hidden}.clinical-chart-shell{width:100%;max-width:100%;min-height:100dvh}.clinical-chart-header{width:100%;box-sizing:border-box}.back-button{flex:0 0 auto}.clinical-chart-header h2,.clinical-chart-header .muted{overflow-wrap:anywhere}

/* Add clinical-action dialogs intentionally have no floating title/X header.
   The dialog is a single white surface with only Cancel + Save in the footer. */
#chartActionModal #chartActionForm > .action-head{display:none!important;}
#chartActionModal .icon-close{display:none!important;}

@media(max-width:760px){
  .icu-topbar{padding:10px 8px!important;gap:6px!important;min-height:66px!important}
  .icu-brand-row{flex:1 1 auto;min-width:0}.icu-logo{width:34px;height:34px;font-size:30px!important;flex:0 0 34px}.icu-brand{font-size:18px!important}.icu-tagline{font-size:8px!important}
  .icu-hospital{display:none!important}
  .icu-top-actions{max-width:none;width:auto;flex:0 0 auto;gap:3px!important;overflow:visible}
  .icu-top-actions .top-icon-btn{width:34px!important;height:34px!important;min-width:34px!important;padding:0!important;display:grid;place-items:center}
  .icu-top-actions .notification-action,.icu-top-actions .alarm-action{overflow:visible}
  .notification-badge{right:-3px;top:-4px}
  .shift-summary{width:100%;box-sizing:border-box;grid-template-columns:1.45fr repeat(3,minmax(0,1fr));overflow:hidden}
  .bed-toolbar{width:100%;box-sizing:border-box}.search-box{min-width:0}.filter-btn{flex:0 0 45px}
  .clinical-chart-header{padding:10px 9px!important;gap:8px!important}.clinical-chart-header .back-button{font-size:15px!important;padding:7px 5px!important}.clinical-chart-header h2{font-size:17px!important;line-height:1.2}.clinical-chart-header .muted{font-size:9px!important}
}
@media(max-width:360px){.icu-top-actions .top-icon-btn{width:31px!important;height:31px!important;min-width:31px!important;font-size:14px!important}.icu-brand{font-size:16px!important}.icu-tagline{display:none}.icu-logo-img{width:30px;height:30px;flex-basis:30px;border-radius:8px}.icu-logo{width:30px;height:30px;flex-basis:30px;font-size:26px!important}}

/* Patient status is reflected across the dashboard card and profile. */
.icu-bed-card.stable-card{border-color:#bfe8d7;background:#fbfffd}
.icu-bed-card.unstable-card{border-color:#f1d58a;background:#fffdf7}
.icu-bed-card.critical-card{border-color:#f0b7bf;background:#fffafb}
.icu-bed-card.stable-card .patient-card-main,.icu-bed-card.stable-card .card-footer{background:#fbfffd}
.icu-bed-card.unstable-card .patient-card-main,.icu-bed-card.unstable-card .card-footer{background:#fffdf7}
.icu-bed-card.critical-card .patient-card-main,.icu-bed-card.critical-card .card-footer{background:#fffafb}


/* v0.17.27 — robust mobile Add-action modal: viewport-sized, clipped inside white panel, touch-scrollable */
html,body{min-height:100%;overflow-y:auto!important;overflow-x:hidden!important;}
body.modal-open{overflow:auto!important;overscroll-behavior:auto;}
#chartActionModal.chart-action-modal{
  position:fixed!important;
  inset:0!important;
  width:100vw!important;
  height:100dvh!important;
  max-width:none!important;
  max-height:none!important;
  box-sizing:border-box!important;
  padding:clamp(10px,3vw,24px)!important;
  background:rgba(7,25,45,.58)!important;
  display:flex!important;
  align-items:center!important;
  justify-content:center!important;
  overflow-y:auto!important;
  overflow-x:hidden!important;
  -webkit-overflow-scrolling:touch!important;
  overscroll-behavior:contain;
  touch-action:pan-y;
  z-index:99999!important;
}
#chartActionModal.chart-action-modal.hidden{display:none!important;}
#chartActionModal #chartActionForm{
  position:relative!important;
  display:flex!important;
  flex-direction:column!important;
  box-sizing:border-box!important;
  width:min(760px,100%)!important;
  max-width:100%!important;
  height:auto!important;
  max-height:calc(100dvh - 20px)!important;
  margin:auto!important;
  padding:18px 0 0!important;
  background:#fff!important;
  border:1px solid #dce5ee!important;
  border-radius:20px!important;
  box-shadow:0 24px 80px rgba(0,0,0,.28)!important;
  overflow:hidden!important;
  min-height:0!important;
}
#chartActionModal .action-head{
  position:sticky!important;
  top:0!important;
  z-index:5!important;
  flex:0 0 auto!important;
  box-sizing:border-box!important;
  min-height:64px!important;
  margin:0!important;
  padding:14px 58px 14px 20px!important;
  background:#fff!important;
  border-bottom:1px solid #e8edf2!important;
  box-shadow:0 3px 10px rgba(20,50,80,.05)!important;
}
#chartActionModal .action-head strong{font-size:18px!important;color:#143c62!important;line-height:1.25!important;}
#chartActionModal .action-head .icon-close{
  position:absolute!important;
  right:14px!important;
  top:50%!important;
  transform:translateY(-50%)!important;
  z-index:10!important;
  width:40px!important;
  height:40px!important;
  min-width:40px!important;
  border:1px solid #d9e3ec!important;
  border-radius:12px!important;
  background:#f3f7fb!important;
  color:#40566e!important;
  font-size:25px!important;
  line-height:1!important;
  display:grid!important;
  place-items:center!important;
  cursor:pointer!important;
}
#chartActionModal .action-head .icon-close:hover{background:#e9f1f8!important;}
#chartActionModal #chartActionForm>*:not(.action-head):not(.editor-footer){flex:0 0 auto;}
#chartActionModal #chartActionForm{overflow-y:auto!important;overflow-x:hidden!important;touch-action:pan-y!important;-webkit-overflow-scrolling:touch!important;}
#chartActionModal #chartActionForm .action-head{margin-bottom:0!important;}
#chartActionModal #chartActionForm>label,
#chartActionModal #chartActionForm>.form-grid{margin-left:20px!important;margin-right:20px!important;}
#chartActionModal #chartActionForm>label{margin-top:14px!important;}
#chartActionModal #chartActionForm>label:last-of-type{margin-bottom:14px!important;}
#chartActionModal #chartActionForm input,
#chartActionModal #chartActionForm select,
#chartActionModal #chartActionForm textarea{
  box-sizing:border-box!important;
  width:100%!important;
  min-height:44px!important;
  margin-top:6px!important;
  padding:10px 12px!important;
  border:1px solid #d6e0e9!important;
  border-radius:11px!important;
  background:#fbfdff!important;
  color:#173c5e!important;
  font-size:14px!important;
  outline:none!important;
}
#chartActionModal #chartActionForm textarea{min-height:92px!important;resize:vertical!important;line-height:1.45!important;}
#chartActionModal #chartActionForm input:focus,
#chartActionModal #chartActionForm select:focus,
#chartActionModal #chartActionForm textarea:focus{border-color:#72acd7!important;box-shadow:0 0 0 3px rgba(30,119,190,.10)!important;background:#fff!important;}
#chartActionModal #chartActionForm label{display:block!important;color:#61758a!important;font-size:11px!important;font-weight:700!important;}
#chartActionModal #chartActionForm .form-grid{gap:12px!important;margin-top:14px!important;}
#chartActionModal #chartActionForm .check-label{display:flex!important;align-items:center!important;gap:9px!important;min-height:44px!important;padding:9px 12px!important;background:#f6f9fc!important;border:1px solid #e0e7ee!important;border-radius:11px!important;box-sizing:border-box!important;}
#chartActionModal #chartActionForm .check-label input{width:18px!important;min-height:18px!important;margin:0!important;flex:0 0 18px!important;}
#chartActionModal #chartActionForm .editor-footer{
  position:sticky!important;
  bottom:0!important;
  z-index:6!important;
  flex:0 0 auto!important;
  box-sizing:border-box!important;
  margin:14px 0 0!important;
  padding:12px 20px calc(12px + env(safe-area-inset-bottom))!important;
  background:rgba(255,255,255,.97)!important;
  border-top:1px solid #e7edf2!important;
  display:flex!important;
  gap:9px!important;
}
#chartActionModal #chartActionForm .editor-footer .secondary,
#chartActionModal #chartActionForm .editor-footer .primary{min-height:44px!important;border-radius:11px!important;font-weight:800!important;}
#chartActionModal #chartActionForm .editor-footer .secondary{min-width:95px!important;}
#chartActionModal #chartActionForm .editor-footer .primary{flex:1!important;min-width:130px!important;}

/* Add clinical-action dialogs intentionally have no floating title/X header.
   The dialog is a single white surface with only Cancel + Save in the footer. */
#chartActionModal #chartActionForm > .action-head{display:none!important;}
#chartActionModal .icon-close{display:none!important;}

@media(max-width:760px){
  #chartActionModal.chart-action-modal{padding:8px!important;align-items:flex-start!important;}
  #chartActionModal #chartActionForm{width:100%!important;max-width:none!important;max-height:calc(100dvh - 16px)!important;border-radius:16px!important;}
  #chartActionModal .action-head{min-height:58px!important;padding:12px 54px 12px 15px!important;}
  #chartActionModal .action-head strong{font-size:16px!important;}
  #chartActionModal .action-head .icon-close{right:10px!important;width:38px!important;height:38px!important;min-width:38px!important;}
  #chartActionModal #chartActionForm>label,
  #chartActionModal #chartActionForm>.form-grid{margin-left:14px!important;margin-right:14px!important;}
  #chartActionModal #chartActionForm .editor-footer{padding-left:14px!important;padding-right:14px!important;}
}
@media(max-width:380px){
  #chartActionModal #chartActionForm>label,
  #chartActionModal #chartActionForm>.form-grid{margin-left:11px!important;margin-right:11px!important;}
  #chartActionModal #chartActionForm input,
  #chartActionModal #chartActionForm select,
  #chartActionModal #chartActionForm textarea{font-size:13px!important;}
}

/* v0.17.29 — End Patient Stay uses the same clean, single-surface mobile modal as Add dialogs */
#chartActionModal #endStayForm.clean-end-stay-form{
  position:relative!important;
  display:flex!important;
  flex-direction:column!important;
  box-sizing:border-box!important;
  width:min(760px,100%)!important;
  max-width:100%!important;
  max-height:calc(100dvh - 20px)!important;
  margin:auto!important;
  padding:18px 0 0!important;
  background:#fff!important;
  border:1px solid #dce5ee!important;
  border-radius:20px!important;
  box-shadow:0 24px 80px rgba(0,0,0,.28)!important;
  overflow:hidden!important;
  min-height:0!important;
  overflow-y:auto!important;
  overflow-x:hidden!important;
  -webkit-overflow-scrolling:touch!important;
  touch-action:pan-y!important;
}
#chartActionModal #endStayForm .end-stay-title{
  flex:0 0 auto!important;
  padding:4px 20px 16px!important;
  border-bottom:1px solid #e8edf2!important;
}
#chartActionModal #endStayForm .end-stay-title strong{display:block!important;color:#143c62!important;font-size:19px!important;line-height:1.25!important}
#chartActionModal #endStayForm .end-stay-title span{display:block!important;margin-top:5px!important;color:#718399!important;font-size:11px!important;line-height:1.45!important}
#chartActionModal #endStayForm>label,
#chartActionModal #endStayForm>.form-grid,
#chartActionModal #endStayForm>#amaFields{margin-left:20px!important;margin-right:20px!important}
#chartActionModal #endStayForm>label{margin-top:14px!important}
#chartActionModal #endStayForm .form-grid{gap:12px!important;margin-top:14px!important}
#chartActionModal #endStayForm input,
#chartActionModal #endStayForm select,
#chartActionModal #endStayForm textarea{
  box-sizing:border-box!important;width:100%!important;min-height:44px!important;margin-top:6px!important;padding:10px 12px!important;border:1px solid #d6e0e9!important;border-radius:11px!important;background:#fbfdff!important;color:#173c5e!important;font-size:14px!important;outline:none!important;
}
#chartActionModal #endStayForm textarea{min-height:92px!important;resize:vertical!important;line-height:1.45!important}
#chartActionModal #endStayForm input:focus,
#chartActionModal #endStayForm select:focus,
#chartActionModal #endStayForm textarea:focus{border-color:#72acd7!important;box-shadow:0 0 0 3px rgba(30,119,190,.10)!important;background:#fff!important}
#chartActionModal #endStayForm label{display:block!important;color:#61758a!important;font-size:11px!important;font-weight:700!important}
#chartActionModal #endStayForm #amaFields{padding:14px 0 2px!important;margin-top:14px!important;border:1px solid #e0e7ee!important;border-radius:14px!important;background:#f8fafc!important}
#chartActionModal #endStayForm #amaFields h4{margin:0 14px 2px!important;color:#143c62!important;font-size:13px!important}
#chartActionModal #endStayForm #amaFields label{margin:12px 14px 0!important}
#chartActionModal #endStayForm .editor-footer{
  position:sticky!important;bottom:0!important;z-index:6!important;flex:0 0 auto!important;box-sizing:border-box!important;margin:14px 0 0!important;padding:12px 20px calc(12px + env(safe-area-inset-bottom))!important;background:rgba(255,255,255,.97)!important;border-top:1px solid #e7edf2!important;display:flex!important;gap:9px!important;
}
#chartActionModal #endStayForm .editor-footer .secondary,
#chartActionModal #endStayForm .editor-footer .primary{min-height:46px!important;border-radius:11px!important;font-weight:800!important}
#chartActionModal #endStayForm .editor-footer .secondary{min-width:100px!important}
#chartActionModal #endStayForm .editor-footer .primary{flex:1!important;min-width:150px!important}
@media(max-width:760px){
 #chartActionModal #endStayForm.clean-end-stay-form{width:100%!important;max-width:none!important;max-height:calc(100dvh - 16px)!important;border-radius:16px!important;padding-top:14px!important}
 #chartActionModal #endStayForm .end-stay-title{padding:2px 14px 13px!important}
 #chartActionModal #endStayForm .end-stay-title strong{font-size:17px!important}
 #chartActionModal #endStayForm>label,
 #chartActionModal #endStayForm>.form-grid,
 #chartActionModal #endStayForm>#amaFields{margin-left:14px!important;margin-right:14px!important}
 #chartActionModal #endStayForm .editor-footer{padding-left:14px!important;padding-right:14px!important}
}
@media(max-width:380px){
 #chartActionModal #endStayForm>label,
 #chartActionModal #endStayForm>.form-grid,
 #chartActionModal #endStayForm>#amaFields{margin-left:11px!important;margin-right:11px!important}
 #chartActionModal #endStayForm input,
 #chartActionModal #endStayForm select,
 #chartActionModal #endStayForm textarea{font-size:13px!important}
}

/* v0.17.30 — explicit patient move menu; long-press/drag removed */
.icu-bed-card{cursor:default!important;-webkit-user-select:auto!important;user-select:auto!important;-webkit-touch-callout:default!important}
.icu-bed-card:active{cursor:default!important}
.icu-bed-card.drag-source,.icu-bed-card.drop-target{transform:none!important;box-shadow:none!important;opacity:1!important}
.more-dot{appearance:none;border:0;background:transparent!important;color:#60758a!important;font-size:16px!important;font-weight:900!important;line-height:1!important;min-width:34px!important;min-height:34px!important;padding:5px!important;border-radius:9px!important;cursor:pointer!important;display:inline-flex!important;align-items:center!important;justify-content:center!important;letter-spacing:1px}
.more-dot:hover,.more-dot:focus-visible{background:#eef5fa!important;color:#153c62!important;outline:none!important}
.move-patient-dialog{background:#fff;width:min(620px,94vw);max-height:min(86vh,760px);border-radius:20px;box-shadow:0 24px 70px rgba(12,43,70,.24);overflow:hidden;display:flex;flex-direction:column}
.move-dialog-head{position:relative;padding:22px 58px 17px 22px;border-bottom:1px solid #e5ebf1;background:#fff}
.move-dialog-head .move-eyebrow{font-size:9px;font-weight:900;letter-spacing:1.4px;color:#6d8397}
.move-dialog-head h3{margin:4px 0 3px;color:#153c62;font-size:22px}
.move-dialog-head p{margin:0;color:#6d7e90;font-size:12px}
.move-dialog-close{position:absolute;right:15px;top:15px;width:40px;height:40px;border:1px solid #dce5ec;border-radius:12px;background:#f6f9fb;color:#49647b;font-size:27px;line-height:1;cursor:pointer}
.move-dialog-close:hover{background:#eaf2f8;color:#153c62}
.move-bed-list{padding:18px;display:grid;grid-template-columns:repeat(3,minmax(0,1fr));gap:11px;overflow:auto;overscroll-behavior:contain;-webkit-overflow-scrolling:touch;touch-action:pan-y;min-height:0}
.move-bed-option{min-height:76px;border:1px solid #dce6ed;border-radius:14px;background:#fff;padding:11px;text-align:left;display:flex;flex-direction:column;justify-content:center;gap:4px;cursor:pointer;transition:.15s}
.move-bed-option:hover{border-color:#79acd0;background:#f5faff;transform:translateY(-1px)}
.move-bed-option.current{background:#eef5fa;border-color:#aac4d8;cursor:default}
.move-bed-option.occupied{background:#fff9f7;border-color:#f0cfc5}
.move-bed-option:disabled{opacity:1}
.move-bed-number{font-size:15px;font-weight:850;color:#173f62}
.move-bed-state{font-size:10px;color:#77899a;white-space:nowrap;overflow:hidden;text-overflow:ellipsis}
.move-bed-option.occupied .move-bed-state{color:#b35a43;font-weight:700}
.move-dialog-footer{padding:13px 18px;border-top:1px solid #e5ebf1;background:#fbfcfd;display:flex;justify-content:flex-end}
.move-dialog-footer .secondary{min-width:110px;min-height:44px;border-radius:11px}
.move-bed-option.loading{opacity:.55;pointer-events:none}
@media(max-width:600px){
  .move-patient-dialog{width:calc(100vw - 16px);max-height:calc(100dvh - 16px);border-radius:17px}
  .move-dialog-head{padding:18px 55px 15px 16px}
  .move-dialog-head h3{font-size:19px}
  .move-bed-list{grid-template-columns:repeat(2,minmax(0,1fr));padding:13px;gap:9px}
  .move-bed-option{min-height:70px}
  .move-dialog-footer{padding:11px 13px}
}

/* v0.17.36 — empty bed cards use a bed icon instead of a plus icon */
.empty-card-body .bed-empty-icon{font-size:30px!important;line-height:1!important;width:42px;height:42px;display:grid;place-items:center;background:#eaf4ff;border-radius:50%;color:inherit;margin-bottom:3px;}
.empty-card-body .bed-empty-icon::first-letter{font-size:30px;}

.hospital-bed-icon{width:64px;height:64px;display:block;color:currentColor}
.bed-empty-icon{font-size:inherit}

/* v0.17.37 — ensure action buttons are always touch/click targets */
#bedGrid .bed-card-top{position:relative;z-index:2}
#bedGrid .more-dot{position:relative;z-index:20;pointer-events:auto!important;touch-action:manipulation!important;-webkit-tap-highlight-color:transparent}
#bedGrid .card-add-btn,#bedGrid .card-edit-btn{position:relative;z-index:5;pointer-events:auto!important;touch-action:manipulation!important}

/* v0.17.42 — professional hospital bed icon for empty beds */
.empty-card-body .bed-empty-icon{width:58px;height:58px;border-radius:50%;display:grid;place-items:center;background:#eef5fb;overflow:hidden;margin-bottom:3px;}
.hospital-bed-icon-img{width:54px;height:54px;display:block;object-fit:contain;}

/* v0.17.43 bottom navigation content */
.bottom-nav-content{padding:4px 0;max-height:min(62vh,620px);overflow:auto}
.bottom-nav-content .alarm-row{margin:8px 0}
.bottom-nav>button{cursor:pointer;touch-action:manipulation}

/* v0.17.44 — standalone bottom-navigation pages */
.standalone-app-page{min-height:100vh;background:#f5f8fc;padding-bottom:78px}
.standalone-page-inner{width:min(1180px,100%);margin:0 auto;padding:18px 16px 24px}
.standalone-page-header{display:flex;align-items:center;justify-content:space-between;gap:14px;background:#fff;border:1px solid #e0e8f1;border-radius:18px;padding:18px;margin-bottom:14px;box-shadow:0 8px 24px rgba(25,64,101,.05)}
.standalone-page-header h1{margin:3px 0 2px;font-size:24px;color:#17324f}
.standalone-page-header p{margin:0}
.standalone-page-content{display:grid;gap:10px}
.standalone-item{display:flex;align-items:center;justify-content:space-between;gap:14px;background:#fff;border:1px solid #e0e8f1;border-radius:15px;padding:15px;box-shadow:0 5px 18px rgba(25,64,101,.04)}
.standalone-item>div:first-child{display:grid;gap:4px;min-width:0}
.standalone-item strong{color:#17324f;font-size:15px}
.standalone-item span{color:#667b91;font-size:12px}
.standalone-item p{margin:0;color:#536b83;font-size:13px;white-space:pre-wrap}
.standalone-item .task-inline-actions{display:flex;gap:7px;flex-wrap:wrap;justify-content:flex-end}
.standalone-bottom-nav{position:fixed;z-index:120}
@media(max-width:640px){.standalone-page-inner{padding:10px 10px 18px}.standalone-page-header{padding:14px;border-radius:14px}.standalone-page-header h1{font-size:21px}.standalone-back{white-space:nowrap}.standalone-item{align-items:flex-start;flex-direction:column}.standalone-item button{width:100%}.standalone-item .task-inline-actions{width:100%;justify-content:stretch}.standalone-item .task-inline-actions button{flex:1}.standalone-bottom-nav{bottom:0}}

/* v0.17.47 — professional SVG bottom-navigation icons */
.bottom-nav .nav-icon{width:24px;height:24px;display:grid;place-items:center;line-height:0}
.bottom-nav .nav-icon svg{width:24px;height:24px;display:block}
.bottom-nav button.active .nav-icon{transform:translateY(-1px)}
.bottom-nav button{touch-action:manipulation;-webkit-tap-highlight-color:transparent}
/* v0.17.51 — high-yield ICU Bed Card */
.patient-id-line{display:flex;align-items:center;gap:4px;margin-top:3px;color:#6a7d91;font-size:9px;line-height:1.2}.patient-id-line b{color:#244766;font-weight:800}.card-los{margin-left:auto;color:#1d628e;white-space:nowrap;font-weight:850;font-size:9px;letter-spacing:.1px}.bed-clinical-grid{display:grid;grid-template-columns:repeat(2,minmax(0,1fr));gap:6px 10px;margin-top:10px;padding-top:8px;border-top:1px solid rgba(102,132,160,.16)}.clinical-mini{display:flex;align-items:center;min-width:0;gap:5px;color:#294a66;font-size:10px;line-height:1.2}.clinical-mini i{width:22px;height:22px;display:grid;place-items:center;flex:0 0 22px;border:1px solid rgba(61,111,151,.18);border-radius:7px;background:rgba(239,247,252,.9)}.clinical-mini i svg{width:18px;height:18px;fill:none;stroke:currentColor;stroke-width:1.7;stroke-linecap:round;stroke-linejoin:round}.clinical-mini b{font-weight:750;white-space:nowrap;overflow:hidden;text-overflow:ellipsis}.clinical-wide{grid-column:span 2}.clinical-wide b{font-size:9px}.card-footer{border-top:1px solid rgba(102,132,160,.10)}
@media(max-width:760px){.patient-id-line{font-size:8px}.bed-clinical-grid{gap:5px 7px;margin-top:8px;padding-top:7px}.clinical-mini{font-size:8.5px;gap:3px}.clinical-mini i{width:19px;height:19px;flex-basis:19px}.clinical-mini i svg{width:16px;height:16px}.clinical-wide b{font-size:8px}.card-los{display:inline-flex;align-items:center;justify-content:center;font-size:8px;font-weight:850;margin-left:auto;padding:2px 5px;border-radius:6px;background:#eef6fb;color:#17638f;white-space:nowrap}.icu-bed-card{min-height:190px}.diagnosis-line{margin-top:3px}}

.vitals-record{border:1px solid #e1e8ef;border-radius:12px;background:#fbfdff;padding:10px 11px;margin:8px 0}.vitals-record:first-child{margin-top:2px}.vitals-record:last-child{margin-bottom:0}.vitals-record-head{display:flex;justify-content:space-between;align-items:center;gap:8px;padding-bottom:8px;margin-bottom:8px;border-bottom:1px solid #e9eef3}.vitals-record-head strong{font-size:10px;color:#1d4d73}.vitals-record-head small{font-size:8px;color:#8997a7}.vitals-record-grid{display:grid;grid-template-columns:repeat(3,minmax(0,1fr));gap:7px}.vitals-record-grid span{display:flex;flex-direction:column;gap:2px;background:#f3f7fa;border-radius:8px;padding:7px}.vitals-record-grid i{font-style:normal;font-size:8px;color:#75869a}.vitals-record-grid b{font-size:11px;color:#173f63}.vitals-record-note{font-size:9px;color:#62758a;margin-top:7px;padding-top:6px;border-top:1px dashed #e0e7ee}
@media(max-width:760px){.vitals-record-grid{grid-template-columns:repeat(2,minmax(0,1fr))}.vitals-record-head{align-items:flex-start;flex-direction:column;gap:2px}}

.clinical-record{display:flex;align-items:center;justify-content:space-between;gap:12px}.clinical-record>div{min-width:0;flex:1}.icon-danger{border:1px solid #e3b8b8;background:#fff7f7;color:#b42318;border-radius:8px;padding:5px 8px;font-size:11px;cursor:pointer;white-space:nowrap}.icon-danger:hover{background:#fff0f0}.vitals-record-head .icon-danger{margin-left:auto}
/* v0.17.58 — task center details and status */
.task-page-row{display:flex;gap:14px;align-items:center}
.task-page-main{flex:1;min-width:0}
.task-page-title{display:flex;align-items:center;gap:9px;flex-wrap:wrap}
.task-page-title strong{font-size:15px;color:#17324d}
.task-page-meta{display:flex;flex-wrap:wrap;gap:7px 14px;margin-top:7px;color:#60748b;font-size:12px}
.task-page-meta span{white-space:nowrap}
.task-status-pill{display:inline-flex;align-items:center;border-radius:999px;padding:3px 8px;font-size:10px;font-weight:800;text-transform:uppercase;letter-spacing:.03em}
.task-status-pill.pending{background:#fff4df;color:#a46300}
.task-status-pill.done{background:#e7f7ee;color:#16824d}
.task-completed{opacity:.78}
.task-summary-bar{display:flex;justify-content:space-between;align-items:center;gap:10px;padding:12px 14px;margin-bottom:12px;border:1px solid #dce7f1;background:#f7fbff;border-radius:12px;color:#49647e}
.task-summary-bar strong{color:#17324d}
.task-summary-bar span{font-size:11px}
.task-page-section{margin-bottom:18px}
.task-page-section h3{font-size:13px;color:#31506c;margin:0 0 8px}
.completed-section{border-top:1px solid #e1e8ef;padding-top:15px}
@media(max-width:640px){.task-page-row{align-items:stretch;flex-direction:column}.task-page-row .task-inline-actions{width:100%}.task-page-row .task-inline-actions button{flex:1}.task-summary-bar{align-items:flex-start;flex-direction:column}}
/* Dynamic shift icon: sun for daytime shifts, moon for night shifts. */
.shift-day .sun-icon,.shift-day .moon-icon{width:32px;height:32px;display:grid;place-items:center;font-size:0;flex:0 0 32px}
.shift-day .sun-icon{color:#f7b820}
.shift-day .moon-icon{color:#526b9a}
.shift-day .sun-icon svg,.shift-day .moon-icon svg{width:28px;height:28px;fill:none;stroke:currentColor;stroke-width:1.8;stroke-linecap:round;stroke-linejoin:round}


/* v0.17.67 — approved Bnercrit logo on Login screen */
.login-auth-card{padding-top:28px}
.login-brand{text-align:center;margin:0 auto 18px;display:flex;flex-direction:column;align-items:center}
.login-brand-logo{width:118px;height:118px;border-radius:28px;display:block;box-shadow:0 10px 28px rgba(8,63,112,.18)}
.login-brand-name{margin-top:12px;font-size:30px;font-weight:900;letter-spacing:-1px;color:#1565c0;line-height:1}
.login-brand-subtitle{margin-top:5px;font-size:12px;font-weight:600;color:#687386;letter-spacing:.2px}
@media(max-width:480px){.login-auth-card{padding-top:22px}.login-brand-logo{width:104px;height:104px;border-radius:25px}.login-brand-name{font-size:28px}}

.task-inline-actions .danger{border-color:#e3b8b8;background:#fff7f7;color:#b42318}.task-inline-actions .danger:hover{background:#fff0f0}

/* v0.17.72 — explicit request delete action */
.request-delete-btn{min-height:34px;white-space:nowrap}.clinical-record .request-delete-btn{flex:0 0 auto}.clinical-list-row .request-delete-btn{flex:0 0 auto}

/* v0.17.73: unified red delete actions */
.icon-danger{border:1px solid #e3b8b8!important;background:#fff1f1!important;color:#b42318!important;border-radius:8px;padding:5px 8px;font-size:11px;cursor:pointer;white-space:nowrap}
.icon-danger:hover{background:#ffe1e1!important;color:#8f1d16!important}
.request-delete-btn{flex:0 0 auto;min-height:34px}


/* v0.17.74 — explicit red delete buttons for requests and notes */
.delete-danger{border:1px solid #e3b8b8!important;background:#fff1f1!important;color:#b42318!important;border-radius:8px;padding:6px 9px;font-size:11px;font-weight:700;cursor:pointer;white-space:nowrap;flex:0 0 auto}
.delete-danger:hover{background:#ffe1e1!important;color:#8f1d16!important;border-color:#d49a9a!important}
.clinical-note-row{display:flex;align-items:flex-start;justify-content:space-between;gap:12px}
.clinical-note-content{min-width:0;flex:1}
.clinical-note-row .delete-danger{margin-top:2px}

/* v0.17.78 Bed Card clinical icon refinement */
.clinical-mini .mini-pressor{font-size:10px}.clinical-mini b{line-height:1.15}
@media(max-width:760px){.clinical-mini .mini-pressor{font-size:8px}}

/* v0.17.83 — separate Notification Center and Alarm Center */
#notificationCenterModal,#alarmCenterModal{z-index:420}
.notification-center .alarm-row{border-left:3px solid #2b78b8}
.alarm-center .alarm-row.urgent{border-left:3px solid #d33}
.alarm-action{position:relative;overflow:visible}


/* v0.17.85 — Login credit */
.login-credit{
  text-align:center;
  margin:22px auto 4px;
  font-size:10.5px;
  font-weight:500;
  letter-spacing:.15px;
  color:#98a2b3;
  line-height:1.4;
}
@media(max-width:480px){
  .login-credit{font-size:10px;margin-top:18px}
}


/* v0.17.86 — remembrance prayer under login credit */
.login-credit-prayer{
  margin-top:5px;
  font-size:10.5px;
  font-weight:400;
  color:#a3aab6;
  letter-spacing:0;
}
@media(max-width:480px){
  .login-credit-prayer{font-size:10px;margin-top:4px}
}


/* Password visibility controls */
.password-field{position:relative;display:flex;align-items:center}
.password-field input{width:100%;padding-right:48px}
.password-toggle{position:absolute;right:7px;top:50%;transform:translateY(-50%);width:36px;height:36px;border:0;background:transparent;color:#60758a;border-radius:9px;display:flex;align-items:center;justify-content:center;cursor:pointer;padding:0}.password-eye-icon{width:19px;height:19px;display:block;fill:none;stroke:currentColor;stroke-width:1.8;stroke-linecap:round;stroke-linejoin:round}.password-toggle:hover .password-eye-icon{stroke:#0b6b9f}
.password-toggle:hover{background:rgba(11,107,159,.08);color:#0b6b9f}
.password-toggle:focus-visible{outline:2px solid #0b6b9f;outline-offset:1px}
.profile-info-box{padding:10px 12px;margin-bottom:12px;border:1px solid var(--border,#d9e2ec);border-radius:10px;background:rgba(37,99,235,.05);font-size:12px;line-height:1.5;color:var(--muted,#64748b)}

.pressor-list{display:flex;flex-direction:column;gap:6px;width:100%}.pressor-row{display:grid;grid-template-columns:minmax(0,1fr) auto;align-items:center;gap:10px;width:100%;box-sizing:border-box;padding:8px 9px;border:1px solid var(--border,#d9e2ec);border-radius:8px;background:rgba(15,23,42,.025)}.pressor-row span{font-weight:600;white-space:nowrap;overflow:hidden;text-overflow:ellipsis;min-width:0}.pressor-row small{color:var(--muted,#64748b);white-space:nowrap;font-size:9px}


/* v0.17.90 — organized Active Alarms center */
.alarm-center-organized{width:min(700px,94vw);max-height:84vh;padding:18px;overflow:auto}
.alarm-center-organized .action-head{position:sticky;top:-18px;z-index:2;background:#fff;padding:2px 0 12px;margin:0 0 8px}
.alarm-center-organized .action-head>div{min-width:0}
.alarm-center-organized .action-head strong{display:block;font-size:19px;color:#153c62}
.alarm-center-subtitle{display:block;margin-top:3px;font-size:10px;color:#8190a2}
.alarm-groups{gap:14px}
.alarm-group{margin:0}
.alarm-group-title{display:flex;align-items:center;justify-content:space-between;margin:2px 2px 7px;color:#52677e;font-size:11px;font-weight:800;text-transform:uppercase;letter-spacing:.35px}
.alarm-group-title b{min-width:22px;height:20px;padding:0 6px;border-radius:99px;background:#edf3f8;color:#315777;display:inline-flex;align-items:center;justify-content:center;font-size:10px}
.alarm-group.critical .alarm-group-title{color:#b42318}.alarm-group.critical .alarm-group-title b{background:#fff0f0;color:#b42318}
.alarm-group-list{display:flex;flex-direction:column;gap:8px}
.alarm-center-organized .alarm-row{display:block;padding:13px 13px 11px;border:1px solid #dfe7ef;border-radius:13px;background:#fbfcfe;box-sizing:border-box}
.alarm-center-organized .alarm-row.urgent{border-color:#efb4bc;background:#fff7f7}
.alarm-row-main{min-width:0}
.alarm-row-title{display:flex;align-items:flex-start;justify-content:space-between;gap:8px}
.alarm-row-title strong{font-size:14px;line-height:1.3;color:#173e62;overflow-wrap:anywhere}
.alarm-kind{flex:0 0 auto;padding:3px 7px;border-radius:99px;background:#eef4f9;color:#667b90;font-size:9px!important;font-weight:700}
.alarm-row-meta{display:flex;flex-wrap:wrap;gap:7px;margin-top:7px;font-size:10px;color:#718298}
.alarm-row-meta span{display:inline-flex;align-items:center}
.alarm-priority{font-weight:800;color:#2f638f}
.alarm-row.urgent .alarm-priority{color:#b42318}
.alarm-center-organized .alarm-row p{margin:7px 0 0;font-size:11px;line-height:1.45;color:#52677c;overflow-wrap:anywhere}
.alarm-row-actions{display:flex;flex-wrap:wrap;gap:7px;margin-top:11px;padding-top:10px;border-top:1px solid #e8edf2}
.alarm-row-actions button{flex:1 1 120px;min-width:0;white-space:nowrap}
.alarm-empty{text-align:center;padding:30px 10px}
@media(max-width:640px){
  .alarm-center-organized{width:calc(100vw - 28px);max-height:82vh;padding:15px;border-radius:18px}
  .alarm-center-organized .action-head{top:-15px;padding-bottom:11px}
  .alarm-center-organized .action-head strong{font-size:18px}
  .alarm-row-title{display:block}
  .alarm-kind{display:inline-flex;margin-top:6px}
  .alarm-row-actions{display:grid;grid-template-columns:1fr;gap:7px}
  .alarm-row-actions button{width:100%;flex:none;min-height:42px}
}


/* v0.17.91 — independently organized Notifications Center */
.notification-center-organized{
  width:min(700px,94vw);max-height:84vh;padding:18px;overflow:auto;
  background:#fff;border-radius:18px;box-shadow:0 20px 70px rgba(0,0,0,.22);box-sizing:border-box;
}
.notification-center-organized .action-head{
  position:sticky;top:-18px;z-index:2;background:#fff;padding:2px 0 12px;margin:0 0 8px;
}
.notification-center-organized .action-head>div{min-width:0}
.notification-center-organized .action-head strong{display:block;font-size:19px;color:#153c62}
.notification-center-subtitle{display:block;margin-top:3px;font-size:10px;color:#8190a2}
.notification-groups{display:flex;flex-direction:column;gap:14px}
.notification-group{margin:0}
.notification-group-title{display:flex;align-items:center;justify-content:space-between;margin:2px 2px 7px;color:#52677e;font-size:11px;font-weight:800;text-transform:uppercase;letter-spacing:.35px}
.notification-group-title b{min-width:22px;height:20px;padding:0 6px;border-radius:99px;background:#edf3f8;color:#315777;display:inline-flex;align-items:center;justify-content:center;font-size:10px}
.notification-group.critical .notification-group-title{color:#b42318}
.notification-group.critical .notification-group-title b{background:#fff0f0;color:#b42318}
.notification-group-list{display:flex;flex-direction:column;gap:8px}
.notification-card{display:block;padding:13px 13px 11px;border:1px solid #dfe7ef;border-radius:13px;background:#fbfcfe;box-sizing:border-box}
.notification-card.critical{border-color:#efb4bc;background:#fff7f7;border-left:3px solid #d33}
.notification-card-main{min-width:0}
.notification-card-title{display:flex;align-items:flex-start;justify-content:space-between;gap:8px}
.notification-card-title strong{font-size:14px;line-height:1.3;color:#173e62;overflow-wrap:anywhere}
.notification-kind{flex:0 0 auto;padding:3px 7px;border-radius:99px;background:#eef4f9;color:#667b90;font-size:9px!important;font-weight:700}
.notification-card-meta{display:flex;flex-wrap:wrap;gap:7px;margin-top:7px;font-size:10px;color:#718298}
.notification-card-meta span{display:inline-flex;align-items:center}
.notification-priority{font-weight:800;color:#2f638f}
.notification-card.critical .notification-priority{color:#b42318}
.notification-card p{margin:7px 0 0;font-size:11px;line-height:1.45;color:#52677c;overflow-wrap:anywhere}
.notification-card-actions{display:flex;margin-top:11px;padding-top:10px;border-top:1px solid #e8edf2}
.notification-card-actions button{width:100%;min-height:42px;white-space:nowrap}
.notification-empty{text-align:center;padding:30px 10px}
@media(max-width:640px){
  .notification-center-organized{width:calc(100vw - 28px);max-height:82vh;padding:15px;border-radius:18px}
  .notification-center-organized .action-head{top:-15px;padding-bottom:11px}
  .notification-center-organized .action-head strong{font-size:18px}
  .notification-card-title{display:block}
  .notification-kind{display:inline-flex;margin-top:6px}
}

/* v0.17.95 admission time + live LOS */
.admission-time{margin:4px 0 0;font-size:10px;font-weight:700;color:#bfe1f5}.clinical-chart-page .admission-time{color:#bfe1f5}.card-los{font-variant-numeric:tabular-nums;}

/* v0.17.96 — History search and outcome filters */
.history-tools{display:grid;gap:12px;margin-bottom:14px}
.history-search-wrap{position:relative}
.history-search-wrap input{width:100%;box-sizing:border-box;background:#fff;border:1px solid #d8e3ed;border-radius:14px;padding:13px 14px 13px 42px;font-size:14px;color:#17324f;outline:none;box-shadow:0 4px 14px rgba(25,64,101,.04)}
.history-search-wrap input:focus{border-color:#78a8d0;box-shadow:0 0 0 3px rgba(62,128,186,.10)}
.history-search-icon{position:absolute;left:15px;top:50%;transform:translateY(-50%);color:#6d8297;font-size:22px;line-height:1;pointer-events:none}
.history-filters{display:flex;gap:8px;flex-wrap:wrap}
.history-date-tools{display:grid;grid-template-columns:repeat(3,minmax(0,1fr)) auto;gap:8px;align-items:end}
.history-date-tools label{display:grid;gap:5px;min-width:0}
.history-date-tools label span{font-size:11px;font-weight:800;color:#6a8095}
.history-date-tools select{width:100%;box-sizing:border-box;border:1px solid #d7e2ec;background:#fff;color:#17324f;border-radius:12px;padding:10px 11px;font-size:13px;outline:none}
.history-date-tools select:focus{border-color:#78a8d0;box-shadow:0 0 0 3px rgba(62,128,186,.10)}
.history-date-clear{border:1px solid #d7e2ec;background:#f7fafc;color:#476178;border-radius:12px;padding:10px 13px;font-size:12px;font-weight:800;cursor:pointer;white-space:nowrap}
.history-filter{border:1px solid #d7e2ec;background:#fff;color:#476178;border-radius:999px;padding:9px 13px;font-size:12px;font-weight:700;cursor:pointer;white-space:nowrap}
.history-filter b{margin-left:4px;color:#17324f}
.history-filter.active{background:#17324f;color:#fff;border-color:#17324f}
.history-filter.active b{color:#fff}
.history-results{display:grid;gap:10px}
.history-record{background:#fff;border:1px solid #dfe8f0;border-radius:15px;padding:15px;box-shadow:0 5px 18px rgba(25,64,101,.04)}
.history-record-main{display:grid;gap:7px;min-width:0}
.history-record-top{display:flex;align-items:center;justify-content:space-between;gap:10px;flex-wrap:wrap}
.history-record-top strong{font-size:15px;color:#17324f}
.history-meta{font-size:12px;color:#6a8095}
.history-diagnosis,.history-detail{font-size:13px;color:#536b83;line-height:1.5;overflow-wrap:anywhere}
.history-dates{display:flex;gap:18px;flex-wrap:wrap;font-size:12px;color:#536b83;line-height:1.5}
.history-outcome-badge{display:inline-flex;align-items:center;border-radius:999px;padding:5px 9px;font-size:11px;font-weight:800;white-space:nowrap}
.history-outcome-discharged{background:#e9f7ee;color:#207a43}.history-outcome-transferred{background:#eaf3fb;color:#27658e}.history-outcome-deceased{background:#f0f1f3;color:#46515c}.history-outcome-ama{background:#fff2e4;color:#9a5b12}.history-outcome-other{background:#eef2f6;color:#5d6f80}
.history-no-match{margin-top:10px}
.hidden{display:none!important}
@media(max-width:640px){.history-date-tools{grid-template-columns:1fr 1fr}.history-date-tools label:last-of-type{grid-column:1}.history-date-clear{grid-column:2;align-self:end;width:100%}.history-filters{display:grid;grid-template-columns:1fr 1fr}.history-filter{width:100%}.history-record{padding:13px}.history-dates{display:grid;gap:3px}.history-record-top{align-items:flex-start}}

/* v0.17.109: harden Patient Profile against horizontal overflow / stray content */
.clinical-chart-page,
.clinical-chart-shell,
.clinical-chart-body,
.chart-tab-panel,
.patient-profile-sections{
  max-width:100%;
  min-width:0;
  box-sizing:border-box;
}
.patient-profile-sections{
  width:100%;
  overflow-x:hidden;
}
.patient-profile-sections .profile-section{
  width:100%;
  max-width:100%;
  min-width:0;
  box-sizing:border-box;
  overflow:hidden!important;
}
.patient-profile-sections .profile-section-head,
.patient-profile-sections .profile-section-body,
.patient-profile-sections .profile-section-main,
.patient-profile-sections .profile-section-actions{
  min-width:0;
  max-width:100%;
  box-sizing:border-box;
}
.patient-profile-sections .profile-section-actions{
  flex-shrink:1;
}
.patient-profile-sections .profile-section-body{
  overflow:hidden;
}
.patient-profile-sections .profile-section.is-collapsed > .profile-section-body,
.patient-profile-sections .profile-section.is-na > .profile-section-body{
  display:none!important;
}
.patient-profile-sections .profile-list-row,
.patient-profile-sections .profile-list-row > div,
.patient-profile-sections .profile-data-item,
.patient-profile-sections .profile-highlight,
.patient-profile-sections .muted{
  min-width:0;
  max-width:100%;
  box-sizing:border-box;
  overflow-wrap:anywhere;
  word-break:break-word;
}
.patient-profile-sections .profile-section-main strong,
.patient-profile-sections .profile-section-main small{
  min-width:0;
  overflow-wrap:anywhere;
  word-break:break-word;
}

/* v0.17.110 — dashboard refresh icon */
.top-icon-btn.refresh-dashboard-action svg{width:20px;height:20px;display:block;transition:transform .25s ease}
.top-icon-btn.refresh-dashboard-action.is-refreshing svg{animation:bnercrit-spin .8s linear infinite}
.top-icon-btn.refresh-dashboard-action:disabled{opacity:.72;cursor:wait}
@keyframes bnercrit-spin{to{transform:rotate(360deg)}}
@media(max-width:760px){.icu-top-actions .refresh-dashboard-action svg{width:17px;height:17px}}

/* v0.17.125 — Isolation badge styled like the red CRITICAL status pill */
.icu-bed-card .isolation-badge{
  display:inline-flex;
  align-items:center;
  justify-content:center;
  width:26px;
  height:22px;
  flex:0 0 26px;
  border-radius:999px;
  background:#fff0f2;
  color:#e72b43;
  border:0;
  box-shadow:none;
}
.icu-bed-card .isolation-badge-icon{
  display:inline-flex;
  width:14px;
  height:14px;
  align-items:center;
  justify-content:center;
}
.icu-bed-card .isolation-badge-icon svg{
  width:14px;
  height:14px;
  fill:none;
  stroke:currentColor;
  stroke-width:2;
  stroke-linecap:round;
  stroke-linejoin:round;
}
@media(max-width:760px){
  .icu-bed-card .isolation-badge{width:23px;height:20px;flex-basis:23px}
  .icu-bed-card .isolation-badge-icon,.icu-bed-card .isolation-badge-icon svg{width:13px;height:13px}
}

/* v0.17.128 — cross-browser Isolation badge */
.icu-bed-card .isolation-badge{display:inline-flex!important;align-items:center!important;justify-content:center!important;flex:0 0 26px!important;width:26px!important;height:22px!important;min-width:26px!important;min-height:22px!important;box-sizing:border-box!important;padding:0!important;margin:0!important;border:0!important;border-radius:999px!important;background:#fff1f3!important;color:#e72b43!important;box-shadow:none!important;line-height:1!important}
.icu-bed-card .isolation-badge-icon{display:inline-flex!important;align-items:center!important;justify-content:center!important;width:14px!important;height:14px!important;color:#e72b43!important}
.icu-bed-card .isolation-badge-icon svg{display:block!important;width:14px!important;height:14px!important;fill:none!important;stroke:#e72b43!important;color:#e72b43!important;stroke-width:2!important;stroke-linecap:round!important;stroke-linejoin:round!important}
@media(max-width:760px){.icu-bed-card .isolation-badge{width:23px!important;height:20px!important;min-width:23px!important;min-height:20px!important;flex-basis:23px!important}.icu-bed-card .isolation-badge-icon,.icu-bed-card .isolation-badge-icon svg{width:13px!important;height:13px!important}}

/* v0.17.128 — cross-browser Isolation badge */
.icu-bed-card .isolation-badge{display:inline-flex!important;align-items:center!important;justify-content:center!important;flex:0 0 26px!important;width:26px!important;height:22px!important;min-width:26px!important;min-height:22px!important;box-sizing:border-box!important;padding:0!important;margin:0!important;border:0!important;border-radius:999px!important;background:#fff1f3!important;color:#e72b43!important;box-shadow:none!important;line-height:1!important}
.icu-bed-card .isolation-badge-icon{display:inline-flex!important;align-items:center!important;justify-content:center!important;width:14px!important;height:14px!important;color:#e72b43!important}
.icu-bed-card .isolation-badge-icon svg{display:block!important;width:14px!important;height:14px!important;fill:none!important;stroke:#e72b43!important;color:#e72b43!important;stroke-width:2!important;stroke-linecap:round!important;stroke-linejoin:round!important}
@media(max-width:760px){.icu-bed-card .isolation-badge{width:23px!important;height:20px!important;min-width:23px!important;min-height:20px!important;flex-basis:23px!important}.icu-bed-card .isolation-badge-icon,.icu-bed-card .isolation-badge-icon svg{width:13px!important;height:13px!important}}

/* Prevent the login screen from flashing during a full-page reload while Supabase restores the saved session. */
body.auth-bootstrap .app-shell{visibility:hidden}
body.auth-bootstrap::before{content:"Loading Bnercrit…";position:fixed;inset:0;display:flex;align-items:center;justify-content:center;background:#f4f7fb;color:#0b2a4a;font-weight:800;font-size:16px;z-index:99999}


/* v0.17.133 — Refined professional logout confirmation */
.top-icon-btn.logout-icon-btn svg{width:20px;height:20px;display:block;fill:none;stroke:currentColor;stroke-width:2;stroke-linecap:round;stroke-linejoin:round}
.top-icon-btn.logout-icon-btn{color:#fff}
.logout-confirm-dialog{width:min(92vw,440px);background:#fff;border:1px solid rgba(15,42,67,.08);border-radius:22px;padding:28px 28px 24px;box-shadow:0 24px 70px rgba(11,42,74,.24);text-align:center}
.logout-confirm-icon{width:60px;height:60px;margin:0 auto 16px;border-radius:18px;display:grid;place-items:center;background:#fff3f3;color:#c62828;box-shadow:inset 0 0 0 1px rgba(198,40,40,.08)}
.logout-confirm-icon svg{width:29px;height:29px;fill:none;stroke:currentColor;stroke-width:2;stroke-linecap:round;stroke-linejoin:round}
.logout-confirm-eyebrow{display:block;margin-bottom:7px;color:#94a3b8;font-size:11px;font-weight:800;letter-spacing:.12em}
.logout-confirm-copy h3{margin:0 0 9px;font-size:22px;line-height:1.25;color:#18324a;font-weight:800}
.logout-confirm-copy p{margin:0 auto;color:#64748b;font-size:14px;line-height:1.55;max-width:330px}
.logout-confirm-actions{display:flex;justify-content:center;gap:10px;margin-top:24px}
.logout-confirm-actions button{min-width:132px;height:42px;border-radius:10px;font-weight:700}
.logout-confirm-btn{background:#c62828!important;color:#fff!important;border-color:#c62828!important;box-shadow:0 6px 14px rgba(198,40,40,.18)}
.logout-confirm-btn:hover{background:#b71c1c!important;border-color:#b71c1c!important}
@media(max-width:480px){.logout-confirm-dialog{padding:24px 20px 20px;border-radius:20px}.logout-confirm-actions{flex-direction:column-reverse}.logout-confirm-actions button{width:100%}}

/* v0.17.136 — Editable monthly coordinator schedule */
.monthly-schedule-card{overflow:hidden}
.monthly-schedule-head{align-items:center}
.monthly-schedule-actions{display:flex;gap:8px;flex-wrap:wrap}
.monthly-schedule-toolbar{display:flex;align-items:center;justify-content:space-between;gap:12px;margin:12px 0}
.monthly-schedule-title{font-size:20px;font-weight:900;color:#172033}
.monthly-schedule-wrap{overflow:auto;border:1px solid #dce3ed;border-radius:14px;max-height:65vh;background:#fff}
.monthly-schedule-table{border-collapse:separate;border-spacing:0;min-width:max-content;width:100%}
.monthly-schedule-table th,.monthly-schedule-table td{border-right:1px solid #e7ebf1;border-bottom:1px solid #e7ebf1;padding:7px;font-size:12px;white-space:nowrap}
.monthly-schedule-table thead th{position:sticky;top:0;z-index:4;background:#f7f9fc;color:#687386;font-size:11px;text-transform:uppercase;letter-spacing:.04em;text-align:center}
.monthly-schedule-table .doctor-header,.monthly-schedule-table .doctor-cell{position:sticky;left:0;z-index:5;background:#fff;min-width:190px;text-align:left}
.monthly-schedule-table .doctor-header{z-index:7;background:#f7f9fc}
.monthly-schedule-table .day-header{min-width:86px}
.monthly-schedule-cell{min-width:86px;height:64px;background:#fff;vertical-align:middle}
.monthly-schedule-cell:hover{background:#f8fbff}
.monthly-shift-button{width:100%;min-height:48px;border:1px solid #dce3ed;border-radius:10px;background:#fff;text-align:left;padding:7px 8px;cursor:pointer}
.monthly-shift-button:hover{border-color:#8db9e8;background:#f7fbff}
.monthly-shift-name{font-weight:900;color:#14599f;display:block}
.monthly-shift-time{display:block;color:#687386;font-size:10px;margin-top:3px}
.monthly-empty-cell{color:#a0a8b5;text-align:center;font-size:18px;font-weight:800}
.monthly-doctor-name{font-weight:900;color:#1565c0}
.monthly-doctor-email{display:block;color:#7b8798;font-size:10px;margin-top:3px;overflow:hidden;text-overflow:ellipsis;max-width:170px}
.monthly-remove-doctor{float:right;border:0;background:transparent;color:#9b1c1c;font-size:16px;cursor:pointer;padding:2px 4px}
.monthly-schedule-footer{display:flex;align-items:center;justify-content:space-between;gap:12px;margin-top:12px}
.monthly-schedule-footer-actions{display:flex;gap:8px;flex-wrap:wrap}
.monthly-doctor-picker{position:relative}
.monthly-doctor-picker input{width:100%;margin-bottom:8px}
.monthly-doctor-results{max-height:240px;overflow:auto;border:1px solid #dce3ed;border-radius:10px;background:#fff}
.monthly-doctor-result{display:block;width:100%;padding:10px;text-align:left;border:0;border-bottom:1px solid #edf0f4;background:#fff;cursor:pointer}
.monthly-doctor-result:hover{background:#f5f9fe}
.monthly-doctor-result strong{display:block;color:#172033}
.monthly-doctor-result span{font-size:11px;color:#687386}
.monthly-shift-picker{display:grid;grid-template-columns:1fr 1fr;gap:8px}
.monthly-shift-option{padding:11px;border:1px solid #dce3ed;border-radius:10px;background:#fff;text-align:left;cursor:pointer}
.monthly-shift-option:hover{border-color:#8db9e8;background:#f7fbff}
.monthly-shift-option strong{display:block}
.monthly-shift-option span{font-size:10px;color:#687386}
.emergency-code-table{width:100%;border-collapse:collapse;min-width:760px}
.emergency-code-table th,.emergency-code-table td{text-align:left;padding:11px 10px;border-bottom:1px solid #e7ebf1;font-size:13px;vertical-align:middle}
.emergency-code-table th{color:#687386;font-size:11px;text-transform:uppercase;letter-spacing:.04em}
.emergency-code-table input,.emergency-code-table select{width:100%;min-width:170px}
.emergency-code-action{display:flex;align-items:center;gap:12px;min-width:180px}
.emergency-generated-code{font-weight:950;font-size:20px;letter-spacing:3px;color:#1565c0}
@media(max-width:700px){.monthly-schedule-toolbar,.monthly-schedule-footer{align-items:stretch;flex-direction:column}.monthly-schedule-actions{width:100%}.monthly-schedule-actions button{flex:1}.monthly-shift-picker{grid-template-columns:1fr}.monthly-schedule-table .doctor-header,.monthly-schedule-table .doctor-cell{min-width:160px}}


/* v0.17.137 — Shift Swap UI */
.shift-swap-card{overflow:hidden}
.shift-swap-grid{display:grid;grid-template-columns:minmax(0,1fr) 44px minmax(0,1fr);gap:14px;align-items:center}
.shift-swap-assignment{border:1px solid #dce3ed;border-radius:14px;background:#fbfcfe;padding:14px}
.shift-swap-assignment-title{font-weight:900;color:#172033;margin-bottom:12px}
.shift-swap-assignment label{display:block;font-size:12px;font-weight:800;color:#687386;margin:9px 0}
.shift-swap-assignment select{width:100%;margin-top:5px}
.shift-swap-assignment-info{min-height:40px;border-top:1px solid #e7ebf1;margin-top:12px;padding-top:10px;font-size:12px}
.shift-swap-arrow{display:flex;align-items:center;justify-content:center;font-size:28px;font-weight:900;color:#1565c0}
.shift-swap-preview{margin-top:14px;border:1px solid #cfe0f2;border-radius:14px;background:#f7fbff;padding:14px}
.shift-swap-preview-title{font-weight:900;color:#172033;margin-bottom:10px}
.shift-swap-preview-row{display:grid;grid-template-columns:1fr 36px 1fr;gap:10px;align-items:center;padding:9px 0;border-bottom:1px solid #e3edf7}
.shift-swap-preview-row:last-child{border-bottom:0}
.shift-swap-preview-box{background:#fff;border:1px solid #dce3ed;border-radius:10px;padding:9px}
.shift-swap-preview-box strong{display:block;color:#1565c0}
.shift-swap-preview-box span{display:block;color:#687386;font-size:11px;margin-top:3px}
.shift-swap-footer{display:flex;align-items:center;justify-content:space-between;gap:12px;margin-top:12px}
@media(max-width:700px){.shift-swap-grid{grid-template-columns:1fr}.shift-swap-arrow{transform:rotate(90deg);height:24px}.shift-swap-footer{align-items:stretch;flex-direction:column}.shift-swap-footer button{width:100%}.shift-swap-preview-row{grid-template-columns:1fr}.shift-swap-preview-row>div:nth-child(2){text-align:center}}

.doctor-picker-cell input[type="search"]{width:100%;min-width:170px}

.shift-swap-date-select{height:150px;overflow-y:auto;max-height:150px}
.shift-swap-date-select option{padding:7px 10px}

/* v0.17.142 — Current Shift Assignments month filter + scroll */
.current-assignments-head{align-items:flex-end}
.current-assignments-controls{display:flex;align-items:flex-end;gap:10px}
.current-assignments-month-label{margin:0;font-size:11px;font-weight:900;color:#687386;text-transform:uppercase;letter-spacing:.04em}
.current-assignments-month-label input{width:170px;margin-top:6px;padding:10px 12px}
.assignments-scroll-wrap{max-height:390px;overflow:auto;border:1px solid #e7ebf1;border-radius:12px;margin-top:12px}
.assignments-scroll-wrap .assignment-table{margin:0}
.assignments-scroll-wrap .assignment-table thead th{position:sticky;top:0;background:#fff;z-index:2}
@media(max-width:700px){.current-assignments-head{align-items:stretch}.current-assignments-controls{width:100%;align-items:stretch;flex-direction:column}.current-assignments-month-label input{width:100%}.assignments-scroll-wrap{max-height:340px}}
