/* 0.9.36: patient controls remain aligned; scroll only inside inset content. */
.pen-slip-fields{padding:16px;border:1px solid #dce6f2;border-radius:17px;background:#fff}.pen-slip-fields h3{margin:0 0 7px;font-size:14px}.pen-slip-fields>p{margin:0 0 14px;font-size:11px;line-height:1.5;color:#647b91}.pen-slip-grid{display:grid;grid-template-columns:repeat(2,minmax(0,1fr));gap:12px}.pen-slip-grid .field{font-size:11px}.pen-slip-grid input,.pen-slip-grid textarea{width:100%;min-width:0;min-height:42px;padding:10px;border-radius:11px;font-size:12px;border:1px solid #dce6f2;background:#f9fbff}.pen-slip-address{grid-column:1/-1}
.patient-workspace{grid-template-columns:minmax(195px,235px) minmax(0,1fr);gap:20px;align-items:start}
.profile-sidebar{--profile-widget-height:clamp(110px,calc((100dvh - 240px)/3),220px);display:grid;grid-template-columns:minmax(0,1fr);grid-auto-rows:var(--profile-widget-height);gap:14px;min-width:0}
.profile-sidebar>.quick-prescription-widgets{display:contents}
.profile-sidebar .profile-card,.profile-sidebar .quick-prescription-widget{width:100%;height:100%;min-height:0;margin:0;box-sizing:border-box;border-radius:22px;overflow:hidden}
.profile-sidebar .profile-card{display:block;padding:12px 8px 12px 14px}
.profile-summary-scroll{height:100%;min-height:0;overflow:auto;padding:3px 7px 3px 1px;overscroll-behavior:contain;scrollbar-gutter:stable}
.healthera-profile-details{margin-top:12px;border:1px solid var(--border);border-radius:14px;background:var(--bg,#f4f7fa);padding:9px 11px;font-size:11px}
.healthera-profile-details summary{cursor:pointer;font-weight:650;line-height:1.5;color:var(--ink,#243347)}
.healthera-profile-details dl{margin:10px 0 0}.healthera-profile-details dl>div{padding:6px 0;border-top:1px solid var(--border)}
.healthera-profile-details dt{color:var(--muted);font-size:10px}.healthera-profile-details dd{margin:3px 0 0;line-height:1.5;overflow-wrap:anywhere;white-space:pre-wrap}
.profile-sidebar .profile-avatar{width:43px;height:43px;font-size:17px;margin:0 0 9px;grid-row:auto}
.profile-sidebar .profile-card h2{font-size:17px;margin:0 0 7px;line-height:1.25}
.profile-sidebar .profile-card p{font-size:11px;line-height:1.5;margin:5px 0;overflow-wrap:anywhere}
.profile-sidebar .quick-prescription-widget{position:static;align-items:flex-start;gap:6px;padding:18px;justify-content:center}
.profile-sidebar .quick-prescription-widget strong{font-size:18px}.profile-sidebar .quick-prescription-widget small{font-size:11px}
.profile-sidebar .quick-pen-icon{position:static;width:38px;height:38px}.profile-sidebar .quick-widget-action{margin-top:4px}
.patient-workspace .profile-main>.tabbar{margin:0 0 16px;overflow:visible;min-width:0}
.patient-workspace .tabbar button{min-width:0;padding:10px 6px;font-size:12px;overflow-wrap:anywhere}
.patient-history-grid{gap:16px;margin-bottom:16px}
.patient-history-grid>.card{height:clamp(300px,calc(100dvh - 250px),530px);min-height:0;max-height:none;display:flex;flex-direction:column;overflow:hidden;scrollbar-gutter:auto;background:#fff}
.patient-history-grid>.card>.card-head{position:static;flex:0 0 auto;min-height:64px;background:#fff;padding:18px 16px;border-bottom:1px solid #e5edf5}
.patient-history-grid>.card>.card-head h2{font-size:15px}
.patient-history-grid>.card>.card-body{flex:1;min-height:0;overflow:auto;overscroll-behavior:contain;margin:4px 7px 10px 0;padding:0 2px 0 0;scrollbar-gutter:stable}
.patient-ai-history .record-item{background:#edf4ff;border-color:#dce8f9;box-shadow:none}
.patient-history-grid .record-item,.patient-history-grid .kiosk-intake{margin:10px;padding:14px;border-radius:15px}
.patient-history-grid .record-heading .button{font-size:11px;padding:8px 10px}
.patient-history-grid .record-heading h3{font-size:13px}.patient-history-grid .record-item p{font-size:12px;line-height:1.65}
.patient-history-grid .empty-state{padding:28px 16px}.patient-history-grid .empty-state h3{font-size:15px}
.patient-workspace .profile-content>.card{overflow:hidden}
.patient-workspace .profile-content>.card>.table-wrap,.patient-workspace .profile-content>.card>[data-paged-list]{margin:0 8px 10px;max-height:500px;overflow:auto;overscroll-behavior:contain}
.profile-content .table-wrap{scroll-padding:10px}
.studio-notifications{overflow:hidden;display:grid;grid-template-rows:auto auto auto minmax(0,1fr) auto;scrollbar-gutter:auto}
.studio-notifications:not([open]){display:none}
.studio-notifications>header{position:static}
#notification-requests{min-height:0;overflow:auto;margin:0 8px 0 0;padding:0 16px 12px 22px;overscroll-behavior:contain;scrollbar-gutter:stable}
.studio-notifications>footer{border-top:1px solid #e5edf5;background:#fff;padding:14px 22px}
.profile-summary-scroll,.patient-history-grid>.card>.card-body,#notification-requests{scrollbar-width:thin;scrollbar-color:#a9bbce transparent}
.profile-summary-scroll::-webkit-scrollbar,.patient-history-grid>.card>.card-body::-webkit-scrollbar,#notification-requests::-webkit-scrollbar{width:6px;height:6px}
@media(min-width:701px) and (max-width:1100px){.patient-workspace{grid-template-columns:190px minmax(0,1fr);gap:14px}.patient-history-grid{gap:12px}.patient-history-grid>.card>.card-head{padding:16px 12px;flex-wrap:wrap;gap:6px}.patient-history-grid>.card>.card-head h2{font-size:14px}.patient-history-grid .record-heading{display:block}.patient-history-grid .record-heading>a{margin-top:8px}.patient-history-grid .record-item,.patient-history-grid .kiosk-intake{padding:12px;margin:8px}.patient-history-grid .kiosk-intake h3{font-size:14px}}
@media(orientation:portrait){.profile-sidebar{--profile-widget-height:clamp(135px,calc((100dvh - 300px)/3),220px)}}
@media(max-width:700px){.patient-workspace{grid-template-columns:1fr;gap:18px}.profile-sidebar{--profile-widget-height:clamp(110px,calc((100dvh - 370px)/3),145px);gap:10px}.profile-sidebar .profile-card{padding:10px 9px 10px 14px}.profile-sidebar .profile-avatar{float:left;margin:0 12px 6px 0}.profile-sidebar .profile-card h2{padding-top:4px}.profile-sidebar .profile-card p{margin:4px 0}.profile-sidebar .quick-prescription-widget{padding:14px 18px;display:grid;grid-template-columns:42px 1fr;column-gap:14px;row-gap:3px;align-content:center;justify-content:normal}.profile-sidebar .quick-pen-icon{grid-row:1/4}.profile-sidebar .quick-widget-action{margin:2px 0 0;grid-column:2}.patient-history-grid{grid-template-columns:1fr}.patient-history-grid>.card{height:360px}.patient-workspace .profile-main>.tabbar{margin-bottom:14px}}
@media(prefers-contrast:more){.patient-ai-history .record-item{border-color:#647b91}.profile-summary-scroll,.patient-history-grid>.card>.card-body,#notification-requests{scrollbar-color:#647b91 transparent}}
