/* v196 patient layout only on phone-sized screens; desktop retains v195. */
@media screen and (max-width:767px){
/* One responsive patient experience at every width. Normal document scrolling. */
body[data-portal-area=patient]>main{width:100%;max-width:860px;margin:20px auto;padding:0 16px;box-sizing:border-box}
body[data-portal-area=patient] #app{min-width:0;max-width:100%}
body[data-portal-area=patient] #app :is(button,a.button){min-height:46px;white-space:normal;touch-action:manipulation;line-height:1.4}
body[data-portal-area=patient] #app :is(input:not([type=checkbox]):not([type=radio]),select,textarea){font-size:16px;max-width:100%;min-width:0;box-sizing:border-box}
#patient-dashboard{max-width:780px;margin-inline:auto}
#patient-dashboard .patient-dashboard-greeting{gap:10px;margin-bottom:18px;align-items:center}
#patient-dashboard .patient-dashboard-greeting h1{font-size:clamp(22px,4vw,28px);line-height:1.3}
#patient-dashboard .patient-dashboard-header-actions{width:auto;max-width:none;flex:0 0 auto}
#patient-dashboard .patient-dashboard-header-actions>.patient-dashboard-shortcuts{width:auto;max-width:none}
#patient-dashboard .patient-dashboard-greeting p{font-size:15px;line-height:1.5}
#patient-dashboard .patient-home-actions{display:grid;gap:12px;margin-bottom:24px}
#patient-dashboard .patient-main-request{padding:20px;margin:0;border:1px solid #bed8c9;border-radius:14px;background:#f0f7f3}
#patient-dashboard .patient-main-request h2{margin:0 0 8px;font-size:20px}
#patient-dashboard .patient-main-request>p{font-size:15px;line-height:1.5;margin:0 0 16px}
#patient-dashboard [data-dashboard-appointment-primary]{display:flex;align-items:center;justify-content:center;gap:10px;width:100%;min-height:54px;font-size:18px;font-weight:700;margin:0}
#patient-dashboard .patient-home-actions>.patient-appointments-shortcut{width:100%;max-width:none;min-height:54px;margin:0;padding:12px 16px;font-size:17px;background:#fff;border:1px solid #b9d1c3}
#patient-dashboard .patient-dashboard-appointment-routes{grid-template-columns:minmax(0,1fr)}
#patient-dashboard .patient-dashboard-appointment-routes>button{min-height:68px;padding:14px;font-size:16px}
#patient-dashboard .patient-dashboard-appointment-routes>button>span{font-size:16px}
#patient-dashboard .patient-dashboard-appointment-routes>button>small{font-size:14px}
#patient-dashboard [data-patient-next-steps]{display:grid;gap:12px}
#patient-dashboard [data-patient-next-steps]>h2{font-size:20px;margin:0 0 2px}
#patient-dashboard .patient-next-card{padding:16px;border:1px solid #ceddd3;border-radius:12px;background:#fff;min-width:0}
#patient-dashboard .patient-next-card:nth-of-type(even){background:#f6f8f7}
#patient-dashboard .patient-next-card h3{font-size:17px;margin:10px 0 6px;line-height:1.4}
#patient-dashboard .patient-next-card p{font-size:15px;line-height:1.6;margin:0 0 12px;overflow-wrap:anywhere}
#patient-dashboard .patient-next-card .patient-next-status{display:inline-block;font-size:14px;font-weight:650;padding:4px 8px;border-radius:6px;margin:0;background:#eaf2ed;color:#31533f}
#patient-dashboard .patient-next-card .needs-reply{background:#fff0d8;color:#805019}
#patient-dashboard .patient-next-card button{width:100%;font-size:16px;margin:0}
body[data-portal-area=patient] #patient-calendar.pc-appointments-mode{display:block;height:auto;min-height:0;max-width:none;overflow:visible}
body[data-portal-area=patient] #patient-calendar.pc-appointments-mode>.pc-content{display:block;overflow:visible;height:auto;min-height:0}
#patient-calendar.pc-sidebar-layout.pc-appointments-mode .pc-split-workspace{display:grid;grid-template-columns:minmax(0,1fr);grid-template-rows:auto;grid-template-areas:"menu" "controls" "actions" "appointments" "details";gap:12px;overflow:visible}
#patient-calendar.pc-sidebar-layout.pc-appointments-mode .pc-split-workspace:has(.pc-sidepanel[data-pane-mode=empty]){grid-template-rows:auto}
#patient-calendar.pc-sidebar-layout.pc-appointments-mode .pc-appointments-menu{max-height:none;overflow:visible;border:0;background:transparent}
#patient-calendar.pc-sidebar-layout.pc-appointments-mode .pc-appointments-menu-heading{display:none}
#patient-calendar.pc-sidebar-layout.pc-appointments-mode .pc-appointments-menu-body{display:grid;grid-template-columns:minmax(0,1fr);padding:0;border:0;overflow:visible;max-height:none;gap:10px}
#patient-calendar.pc-sidebar-layout.pc-appointments-mode .pc-page-toolbar{display:grid;grid-template-columns:repeat(2,minmax(0,1fr));gap:8px;margin:0}
#patient-calendar.pc-sidebar-layout.pc-appointments-mode .pc-page-toolbar>button{font-size:15px;min-height:46px;height:auto;padding:10px}
#patient-calendar.pc-sidebar-layout.pc-appointments-mode .pc-view-options{margin:0;padding:10px 12px;border:1px solid #d0ddd4;border-radius:8px;background:#f8faf9}
#patient-calendar.pc-sidebar-layout.pc-appointments-mode summary{cursor:pointer;font-size:15px;line-height:1.5;padding:3px 0}
#patient-calendar.pc-sidebar-layout.pc-appointments-mode .pc-menu-section{padding-top:12px}
#patient-calendar.pc-sidebar-layout.pc-appointments-mode .pc-list-filters{grid-template-columns:repeat(2,minmax(0,1fr));gap:8px}
#patient-calendar.pc-sidebar-layout.pc-appointments-mode .pc-list-filters>button{min-height:44px;font-size:14px;padding:8px}
#patient-calendar.pc-sidebar-layout.pc-appointments-mode .pc-list-headerbar{display:block;min-height:0;margin:0;padding:10px 12px}
#patient-calendar.pc-sidebar-layout.pc-appointments-mode .pc-list-headerbar .pc-list-controls{display:grid;grid-template-columns:repeat(2,minmax(0,1fr));gap:10px;margin-top:12px}
#patient-calendar.pc-sidebar-layout.pc-appointments-mode .pc-list-headerbar:not([open]) .pc-list-controls{display:none}
#patient-calendar.pc-sidebar-layout.pc-appointments-mode .pc-list-search,#patient-calendar.pc-sidebar-layout.pc-appointments-mode .pc-bulk-controls{grid-column:1/-1}
#patient-calendar.pc-sidebar-layout.pc-appointments-mode .pc-list-controls>label{font-size:14px;gap:5px}
#patient-calendar.pc-sidebar-layout.pc-appointments-mode .pc-bulk-controls{flex-wrap:wrap;justify-content:space-between}
#patient-calendar.pc-sidebar-layout.pc-appointments-mode .pc-bulk-controls :is(button,label){font-size:14px;min-height:44px}
#patient-calendar.pc-sidebar-layout.pc-appointments-mode .pc-appointments-main,#patient-calendar.pc-sidebar-layout.pc-appointments-mode .pc-appointments-main>.pc-appointment-list{display:block;overflow:visible;height:auto;max-height:none}
#patient-calendar.pc-sidebar-layout.pc-appointments-mode .pc-appointment-list .pc-card-main{grid-template-columns:20px minmax(0,1fr)}
#patient-calendar.pc-sidebar-layout.pc-appointments-mode .pc-appointment-list .pc-card-date{grid-column:2;grid-row:2}
#patient-calendar.pc-sidebar-layout.pc-appointments-mode .pc-appointment-list .pc-card-doctor{grid-column:2;grid-row:3}
#patient-calendar.pc-sidebar-layout.pc-appointments-mode .pc-appointment-list .pc-card-main .pc-status[data-pc-tone]{grid-column:2;grid-row:4;width:auto;max-width:100%;justify-self:start}
#patient-calendar.pc-sidebar-layout.pc-appointments-mode .pc-selection-actions{display:block;padding:12px;margin:0}
#patient-calendar.pc-sidebar-layout.pc-appointments-mode .pc-selection-copy{margin-bottom:8px}
#patient-calendar.pc-sidebar-layout.pc-appointments-mode .pc-selection-copy strong{font-size:15px}
#patient-calendar.pc-sidebar-layout.pc-appointments-mode .pc-selection-copy>span{font-size:14px;white-space:normal}
#patient-calendar.pc-sidebar-layout.pc-appointments-mode .pc-selection-buttons{display:grid;grid-template-columns:repeat(2,minmax(0,1fr));gap:8px;overflow:visible;min-width:0}
#patient-calendar.pc-sidebar-layout.pc-appointments-mode .pc-selection-buttons .pc-disabled-action{display:none}
#patient-calendar.pc-sidebar-layout.pc-appointments-mode .pc-selection-buttons>button{min-height:46px;width:100%;min-width:0;padding:9px;font-size:14px}
#patient-calendar.pc-sidebar-layout.pc-appointments-mode .pc-selection-buttons>.pc-primary-next{display:block;grid-column:1/-1;background:#1d6c50;color:#fff;border-color:#1d6c50}
#patient-calendar.pc-sidebar-layout.pc-appointments-mode .pc-action-long{display:inline}
#patient-calendar.pc-sidebar-layout.pc-appointments-mode .pc-action-short{display:none}
#patient-calendar.pc-sidebar-layout.pc-appointments-mode .pc-selection-actions:not(.has-selection) .pc-selection-buttons{display:none}
#patient-calendar.pc-sidebar-layout.pc-appointments-mode .pc-sidepanel[data-pane-mode=empty]{display:none}
#patient-calendar.pc-sidebar-layout.pc-appointments-mode .pc-split-workspace:has(.pc-sidepanel:not([data-pane-mode=empty])){grid-template-areas:"actions" "details";grid-template-rows:auto;overflow:visible}
#patient-calendar.pc-sidebar-layout.pc-appointments-mode .pc-split-workspace:has(.pc-sidepanel:not([data-pane-mode=empty])) :is(.pc-appointments-menu,.pc-list-headerbar,.pc-appointments-main){display:none}
#patient-calendar.pc-sidebar-layout.pc-appointments-mode .pc-sidepanel{width:100%;min-height:0;overflow:visible;margin:0;container-type:normal}
#patient-calendar.pc-sidebar-layout.pc-appointments-mode [data-pc-pane-body]{overflow:visible;max-height:none;padding:16px}
#patient-calendar.pc-sidebar-layout.pc-appointments-mode .pc-sidepanel-heading{align-items:center;padding:10px 14px}
#patient-calendar.pc-sidebar-layout.pc-appointments-mode .pc-sidepanel-heading h2{font-size:18px}
#patient-calendar.pc-sidebar-layout.pc-appointments-mode .pc-sidepanel-heading button{min-height:44px;font-size:15px}
#patient-calendar .pc-booking-grid{display:block}
#patient-calendar .pc-booking-grid>.pc-review{display:none}
#patient-calendar.pc-mobile-review-ready .pc-booking-grid>.pc-picker{display:none}
#patient-calendar.pc-mobile-review-ready .pc-booking-grid>.pc-review{display:block}
#patient-calendar .pc-mobile-step{display:block;min-height:48px;width:100%;margin:14px 0;font-size:16px}
#patient-calendar .pc-mobile-progress{display:flex;list-style:none;gap:6px;padding:0;margin:12px 0;color:#496353;font-size:14px}
#patient-calendar .pc-mobile-progress>li{flex:1;text-align:center;background:#edf3ef;border-radius:6px;padding:8px 5px}
#patient-calendar .pc-mobile-progress>[aria-current=step]{background:#dbede2;color:#205b3e;font-weight:700}
#patient-calendar .pc-times{display:grid;grid-template-columns:repeat(3,minmax(0,1fr));gap:8px}
#patient-calendar .pc-times button{margin:0;min-height:46px;font-size:16px}
#patient-calendar [data-pc-action=book]{width:100%;min-height:50px;font-size:16px}
@media(max-width:480px){body[data-portal-area=patient]>main{padding-inline:12px}#patient-dashboard .patient-main-request{padding:16px}#patient-calendar.pc-sidebar-layout.pc-appointments-mode .pc-sidepanel .pc-detail-data{grid-template-columns:minmax(0,1fr);gap:4px}#patient-calendar.pc-sidebar-layout.pc-appointments-mode .pc-sidepanel .pc-detail-data dd{margin:0 0 8px}}
@media print{#patient-calendar .pc-mobile-step,#patient-calendar .pc-mobile-progress{display:none!important}}

}

.pc-mobile-close-label{display:none}
@media screen and (max-width:767px){.pc-mobile-close-label{display:inline}.pc-desktop-close-label{display:none}}

/* v198: phone-only compact header, task menu and message tools. */
@media screen and (max-width:767px){
#patient-dashboard .patient-dashboard-greeting{display:block;margin-bottom:12px}
#patient-dashboard .patient-dashboard-header-actions{display:flex;flex-direction:row;width:100%;max-width:none;align-items:center;justify-content:flex-end;gap:8px;position:relative}
#patient-dashboard .patient-dashboard-header-actions>.patient-appointments-shortcut{width:auto;max-width:none;margin:0;flex:1;min-height:46px}
#patient-dashboard .patient-dashboard-header-actions>.patient-dashboard-shortcuts{width:auto;flex:none;position:static}
#patient-dashboard .patient-task-menu{position:static}
#patient-dashboard .patient-dashboard-task-popup{left:0;right:0;top:calc(100% + 6px);width:100%;max-width:100%;z-index:40}
#patient-calendar.pc-sidebar-layout.pc-appointments-mode .pc-selection-actions{display:none}
#patient-calendar.pc-sidebar-layout.pc-appointments-mode .pc-split-workspace:has(.pc-sidepanel:not([data-pane-mode=empty])){grid-template-areas:"details";gap:0}
#patient-calendar .pc-appointment-actions [data-pc-action=detail]{display:none}
#patient-calendar .pn-center-heading{display:none}
#patient-calendar .pn-mobile-tools{position:relative;margin:0 0 12px auto;width:100%;text-align:right}
#patient-calendar .pn-mobile-tools>summary{display:inline-block;list-style:none;border:1px solid #b9d1c3;border-radius:8px;background:#fff;padding:10px 16px;min-height:44px;box-sizing:border-box;cursor:pointer}
#patient-calendar .pn-mobile-tools-body{text-align:left;padding:12px;margin-top:8px;background:#f5f8f6;border:1px solid #cfddd4;border-radius:10px}
#patient-calendar .pn-mobile-tools .pn-toolbar,#patient-calendar .pn-mobile-tools .pn-bulk{display:grid;grid-template-columns:minmax(0,1fr);gap:8px;margin:0 0 8px;padding:0;border:0}
#patient-calendar .pn-mobile-tools button{width:100%;margin:0}
}

@media screen and (max-width:767px){
#patient-calendar .pc-view-options,#patient-calendar .pc-list-headerbar,#patient-calendar .pn-mobile-tools,#patient-calendar .pc-detail-extra{display:none!important}
#patient-account-menu{max-width:calc(100vw - 24px);max-height:80dvh;overflow-y:auto;box-sizing:border-box}
#patient-account-menu [data-mobile-appointment-tools]{padding:8px;border-top:1px solid #ccdcd2;min-width:0}
#patient-account-menu [data-mobile-appointment-tools] details{margin:8px 0;border:1px solid #cfddd4;border-radius:8px;padding:8px;min-width:0}
#patient-account-menu [data-mobile-appointment-tools] summary{font-size:14px;padding:8px;cursor:pointer}
#patient-account-menu [data-mobile-appointment-tools] :is(.pc-list-controls,.pc-list-filters,.pn-toolbar,.pn-bulk){display:grid;grid-template-columns:minmax(0,1fr);gap:8px;padding:8px 0}
#patient-account-menu [data-mobile-appointment-tools] :is(input,select,button){box-sizing:border-box;max-width:100%;font-size:16px;min-height:44px}
#patient-account-menu [data-mobile-appointment-tools] label{white-space:normal;display:block}
#patient-account-menu [data-mobile-appointment-tools] button{width:100%;white-space:normal}
#patient-calendar .pc-swipe-actions{display:none;gap:8px;justify-content:flex-end;padding:10px 0 0}
#patient-calendar .pc-swipe-open .pc-swipe-actions{display:flex}
#patient-calendar .pc-swipe-open{border-color:#638f7b;background:#eaf3ee}
#patient-calendar [data-pc-entry]{touch-action:pan-y}
}
@media(min-width:768px){.pc-swipe-actions,[data-mobile-appointment-tools]{display:none!important}}

@media screen and (max-width:767px){#patient-dashboard .patient-home-card-actions{display:grid;grid-template-columns:1fr 1fr;gap:8px;margin-top:8px}#patient-dashboard .patient-home-card-actions button{font-size:14px;min-height:44px}}

@media screen and (max-width:767px){#patient-dashboard [data-dashboard-appointment-primary] > span[aria-hidden=true]{display:none}}

#patient-dashboard [data-overview-tools]{display:none}

@media screen and (max-width:767px){#patient-dashboard .patient-home-list-title>.patient-appointments-shortcut{display:flex;align-items:center;justify-content:space-between;width:100%;max-width:none;min-height:48px;margin:0;font-size:18px;font-weight:700}#patient-dashboard .patient-home-list-title{margin:0 0 4px}}
