/* The one staff menu (workspace-menu.js renders it) on Clinic, Analytics and
   Content: the clinic's espresso sidebar, with Clinic and Analytics as groups
   that open and close. Pages lay themselves out beside --wm-width. */
@font-face{font-family:"Inter";src:url("/fonts/InterVariable.woff2") format("woff2");font-weight:100 900;font-display:swap}
:root{--wm-width:232px;--wm-dark:#2b201d;--wm-mid:#3c2923;--wm-light:#5a3a2f}
body.nav-collapsed{--wm-width:72px}

.wm-sidebar{position:fixed;left:8px;top:8px;bottom:8px;width:var(--wm-width);z-index:20;display:flex;flex-direction:column;box-sizing:border-box;padding:28px 12px 14px;border:0;border-radius:14px;
  background:linear-gradient(180deg,var(--wm-dark) 0%,var(--wm-mid) 45%,var(--wm-light) 100%);color:#fff;font:500 16px/1.35 "Inter","Avenir Next",Avenir,"Segoe UI",sans-serif;-webkit-font-smoothing:antialiased}
.wm-brand{display:flex;justify-content:center;align-items:center;padding:0 0 26px;text-decoration:none}
.wm-brand img{width:34px;height:34px;object-fit:contain;border-radius:2px;background:#fff}
.wm-collapse{position:absolute;top:22px;right:-22px;display:grid;place-items:center;width:24px;height:44px;padding:0;border:0;border-radius:0 12px 12px 0;background:var(--wm-dark);color:#fff;cursor:pointer}
.wm-collapse:hover{background:var(--wm-mid)}
.wm-collapse .wm-icon{width:18px;height:18px;transition:transform .15s ease}
body.nav-collapsed .wm-collapse .wm-icon{transform:rotate(180deg)}

.wm-nav{display:flex;flex-direction:column;gap:2px;flex:1;min-height:0;overflow-y:auto;margin:0 -6px;padding:0 6px;scrollbar-width:thin;scrollbar-color:rgba(255,255,255,.2) transparent}
.wm-sidebar .wm-link,.wm-sidebar .wm-group-toggle{display:flex;align-items:center;gap:14px;width:100%;min-height:42px;margin:0;padding:9px 14px;border:0;border-radius:8px;background:none;color:#fff;font:inherit;font-size:.9375rem;text-align:left;text-decoration:none;cursor:pointer;box-sizing:border-box}
.wm-sidebar .wm-link:hover,.wm-sidebar .wm-group-toggle:hover{background:rgba(255,255,255,.08)}
.wm-sidebar .wm-link[aria-current="page"]{background:rgba(255,255,255,.16);font-weight:600}
.wm-sidebar .wm-link:focus-visible,.wm-sidebar .wm-group-toggle:focus-visible,.wm-brand:focus-visible,.wm-collapse:focus-visible{outline:2px solid rgba(239,139,103,.8);outline-offset:1px}
.wm-icon{flex:none;width:22px;height:22px;fill:currentColor}
.wm-label{min-width:0;overflow:hidden;text-overflow:ellipsis;white-space:nowrap}
.wm-chevron{flex:none;width:20px;height:20px;margin-left:auto;fill:currentColor;opacity:.65;transition:transform .15s ease}
.wm-group-toggle[aria-expanded="true"] .wm-chevron{transform:rotate(180deg)}
.wm-sidebar .wm-group-toggle.wm-here{font-weight:650}
.wm-group+.wm-group,.wm-group+.wm-link{margin-top:4px}
.wm-children{display:flex;flex-direction:column;gap:1px;margin:2px 0 6px}
.wm-children[hidden]{display:none}
.wm-sidebar .wm-children .wm-link{min-height:36px;padding:7px 12px 7px 24px;gap:12px;font-size:.875rem;color:rgba(255,255,255,.84)}
.wm-sidebar .wm-children .wm-link[aria-current="page"]{color:#fff}
.wm-children .wm-icon{width:18px;height:18px}
.wm-footer{margin-top:10px;padding-top:10px;border-top:1px solid rgba(255,255,255,.14)}
.wm-sidebar .wm-footer .wm-link{min-height:38px;font-size:.875rem;color:rgba(255,255,255,.84)}

/* Collapsed rail: group icons only; a click on one opens the rail there. */
body.nav-collapsed .wm-sidebar{padding-inline:10px}
body.nav-collapsed .wm-sidebar .wm-link,body.nav-collapsed .wm-sidebar .wm-group-toggle{justify-content:center;padding-inline:0}
body.nav-collapsed .wm-label,body.nav-collapsed .wm-chevron{position:absolute;width:1px;height:1px;overflow:hidden;clip:rect(0,0,0,0)}
body.nav-collapsed .wm-children{display:none}
body.nav-collapsed .wm-sidebar .wm-group-toggle.wm-here{background:rgba(255,255,255,.16)}

/* Phones: the clinic keeps its bottom tab bar; Analytics and Content open the
   same menu as a drawer from the top bar's menu button. */
.wm-open-btn{display:none}
.wm-scrim{display:none}
@media(max-width:800px){
  .wm-sidebar{display:none}
  body[data-wm-mobile="drawer"]{--wm-width:min(280px,86vw)}
  body[data-wm-mobile="drawer"] .wm-sidebar{display:flex;left:0;top:0;bottom:0;border-radius:0 14px 14px 0;transform:translateX(-105%);transition:transform .18s ease;z-index:50}
  body[data-wm-mobile="drawer"].wm-drawer-open .wm-sidebar{transform:none}
  body[data-wm-mobile="drawer"] .wm-collapse{display:none}
  body[data-wm-mobile="drawer"].nav-collapsed .wm-label,body[data-wm-mobile="drawer"].nav-collapsed .wm-chevron{position:static;width:auto;height:auto;clip:auto}
  body[data-wm-mobile="drawer"].nav-collapsed .wm-children:not([hidden]){display:flex}
  body[data-wm-mobile="drawer"].nav-collapsed .wm-sidebar .wm-link,body[data-wm-mobile="drawer"].nav-collapsed .wm-sidebar .wm-group-toggle{justify-content:flex-start;padding-inline:14px}
  body[data-wm-mobile="drawer"].nav-collapsed .wm-sidebar .wm-children .wm-link{padding-left:24px}
  body[data-wm-mobile="drawer"] .wm-open-btn{display:inline-grid;place-items:center;width:40px;height:40px;margin:0 8px 0 -8px;padding:0;border:0;border-radius:8px;background:none;color:inherit;cursor:pointer}
  body[data-wm-mobile="drawer"] .wm-open-btn svg{width:24px;height:24px;fill:currentColor}
  body.wm-drawer-open .wm-scrim{display:block;position:fixed;inset:0;z-index:45;background:rgba(16,24,40,.35)}
}
@media(prefers-reduced-motion:reduce){.wm-sidebar,.wm-chevron,.wm-collapse .wm-icon{transition:none}}
