/* V31.0.25: actual left navigation and right-side workspaces, no API changes */
:root{--hc-side-width:252px;--hc-side-border:#e3e9f1;--hc-side-ink:#273751}
.hc-dash-sidebar{position:fixed;inset:0 auto 0 0;width:var(--hc-side-width);background:#fff;border-right:1px solid var(--hc-side-border);z-index:80;display:flex;flex-direction:column;box-shadow:2px 0 18px rgba(27,44,71,.025);color:var(--hc-side-ink);font-family:Inter,Arial,"Microsoft YaHei",sans-serif}
.hc-dash-brand{display:flex;align-items:center;gap:11px;padding:21px 20px 17px;border-bottom:1px solid #edf1f6;min-height:82px}
.hc-dash-brandmark{width:40px;height:40px;flex:0 0 40px;border-radius:11px;background:#263757;color:white;display:grid;place-items:center;font:800 24px Georgia,serif}
.hc-dash-brand b{display:block;font-size:16px;line-height:1.2;color:#14243a!important}.hc-dash-brand small{display:block;color:#64758a!important;font-size:11px;margin-top:4px}
.hc-dash-group{padding:18px 20px 8px;text-transform:uppercase;font-size:11px;letter-spacing:.08em;color:#718199;font-weight:700}
.hc-dash-sidebar nav{flex:1;padding:4px 11px 15px;overflow-y:auto;display:flex;flex-direction:column;gap:3px}
.hc-dash-sidebar nav a{display:flex;align-items:center;gap:11px;padding:10px 12px;min-height:42px;border-radius:10px;text-decoration:none!important;color:#33445d!important;font-size:13px;font-weight:600;border:1px solid transparent}
.hc-dash-sidebar nav a:hover{background:#f1f5ff!important;color:#3b47b8!important}.hc-dash-sidebar nav a.hc-active{background:#ecebff!important;color:#4b42c8!important;border-color:#dbd8ff!important}
.hc-nav-glyph{width:18px;text-align:center;color:#697a92;font-size:18px;font-family:Arial,sans-serif;flex-shrink:0}
.hc-dash-sidebar nav a.hc-active .hc-nav-glyph{color:#635bff}
.hc-dash-sidebar-bottom{padding:13px 20px;border-top:1px solid #edf1f6;color:#768398;font-size:11px}
body:has(#hcAdminSidebar),body:has(#hcPartnerSidebar){background:#f6f8fb!important}
body:has(#hcAdminSidebar) .wrap,body:has(#hcPartnerSidebar) .wrap{margin:0 0 0 var(--hc-side-width)!important;max-width:none!important;width:calc(100% - var(--hc-side-width))!important;padding:25px 30px 35px!important}
body:has(#hcAdminSidebar) .wrap>.top:first-child,body:has(#hcPartnerSidebar) .wrap>.row:first-child{background:#fff;border:1px solid #e2e9f1;border-radius:16px;padding:15px 20px;margin-bottom:22px;box-shadow:0 4px 16px rgba(19,42,82,.035)}
.hc-dash-toggle{display:none;position:fixed;left:13px;top:14px;z-index:110;width:42px;height:42px;border:1px solid #d9e2f0!important;border-radius:11px!important;background:#fff!important;color:#223954!important;font-size:22px!important;box-shadow:0 4px 16px #182b4320!important;padding:0!important}
/* Client modal now a two-column workspace */
#clientPortalModal .client-portal-shell{position:relative!important;padding:24px 26px 28px 254px!important;min-height:min(720px,90vh);width:min(1420px,97vw)!important;overflow:auto!important}
#clientPortalModal .client-portal-shell #hcClientSidebar{position:absolute;left:0;top:0;bottom:0;width:230px;border-right:1px solid #e3e9f1;background:#fff;border-radius:22px 0 0 22px;z-index:1;display:flex;flex-direction:column;min-height:100%;padding:0!important}
.hc-client-sidebar nav{padding:16px 10px;display:flex;flex-direction:column;gap:5px}
.hc-client-sidebar nav button{display:block;width:100%;border:1px solid transparent!important;border-radius:10px!important;padding:13px 12px!important;text-align:left!important;background:transparent!important;color:#35455e!important;box-shadow:none!important;font-weight:650!important;font-size:13px!important;cursor:pointer}
.hc-client-sidebar nav button:hover,.hc-client-sidebar nav button.active{background:#ecebff!important;border-color:#d9d6ff!important;color:#4b42c8!important}
.hc-client-sidebar .hc-dash-sidebar-bottom{margin-top:auto}
#clientPortalModal .client-portal-shell .vip-close-btn{position:sticky;top:0;float:right;z-index:5}
@media(max-width:1020px){:root{--hc-side-width:216px}body:has(#hcAdminSidebar) .wrap,body:has(#hcPartnerSidebar) .wrap{padding:18px!important}}
@media(max-width:760px){
.hc-dash-sidebar{transform:translateX(-105%);transition:transform .22s ease;width:258px!important;z-index:109}
body.hc-nav-open .hc-dash-sidebar{transform:translateX(0)}
.hc-dash-toggle{display:grid!important;place-items:center}
body:has(#hcAdminSidebar) .wrap,body:has(#hcPartnerSidebar) .wrap{margin:0!important;width:100%!important;max-width:none!important;padding:74px 12px 22px!important}
#clientPortalModal .client-portal-shell{padding:18px 14px 24px!important;width:98vw!important;max-height:94vh!important}
#clientPortalModal .client-portal-shell #hcClientSidebar{position:relative;left:auto;top:auto;bottom:auto;width:100%;min-height:0;border-right:0;border-radius:12px;border:1px solid #e4eafa;margin-bottom:15px}
#clientPortalModal .hc-client-sidebar .hc-dash-brand,#clientPortalModal .hc-client-sidebar .hc-dash-sidebar-bottom{display:none}
#clientPortalModal .hc-client-sidebar nav{display:flex;flex-direction:row;overflow-x:auto;gap:5px;padding:7px}
#clientPortalModal .hc-client-sidebar nav button{white-space:nowrap;width:auto;padding:9px 10px!important;flex:0 0 auto}
}
/* Don't present a logged-in dashboard to a guest on the login screen. */
body:has(#hcAdminSidebar):has(#app.hidden) #hcAdminSidebar,
body:has(#hcAdminSidebar):has(#app.hidden) #hcAdminNavToggle,
body:has(#hcPartnerSidebar):has(#portal.hidden) #hcPartnerSidebar,
body:has(#hcPartnerSidebar):has(#portal.hidden) #hcPartnerNavToggle{display:none!important}
body:has(#hcAdminSidebar):has(#app.hidden) .wrap,
body:has(#hcPartnerSidebar):has(#portal.hidden) .wrap{margin:0 auto!important;width:100%!important;max-width:1100px!important;padding:26px!important}

/* V31.0.26: Correct client workspace width, prevent sidebar overlap.  */
:root{--hc-lux-bg:#f7f5f0;--hc-lux-paper:#fffefa;--hc-lux-accent:#a77b31;--hc-lux-accent-dark:#77541d;--hc-lux-ink:#243044;--hc-lux-border:#e4dccc;--hc-side-width:242px}
body:has(#hcPartnerSidebar){background:var(--hc-lux-bg)!important}
.hc-dash-sidebar{background:var(--hc-lux-paper)!important;border-right:1px solid var(--hc-lux-border)!important;box-shadow:3px 0 17px rgba(73,55,24,.035)!important}
.hc-dash-brandmark{background:#96702f!important;color:#fff!important}
.hc-dash-sidebar nav a.hc-active,.hc-dash-sidebar nav a:hover{background:#f4ecdc!important;color:#76531b!important;border-color:#e3d2b1!important}
.hc-dash-sidebar nav a.hc-active .hc-nav-glyph{color:#946820!important}
.hc-dash-sidebar nav a{color:#38485c!important}
.hc-dash-sidebar-bottom{border-color:var(--hc-lux-border)!important}
body:has(#hcPartnerSidebar) .wrap{min-width:0!important;overflow-x:clip!important;background:var(--hc-lux-bg)!important}
/* Absolute side navigation is contained INSIDE the portal shell; force room for it on full-page portal and modal. */
#clientPortalModal .client-portal-shell,
body.portal-page #clientPortalModal .client-portal-shell{
  box-sizing:border-box!important;
  position:relative!important;
  padding:26px 30px 38px 274px!important;
  width:min(1500px,calc(100vw - 24px))!important;
  max-width:none!important;
  min-width:0!important;
  margin:0 auto!important;
  overflow-x:clip!important;
  background:var(--hc-lux-bg)!important;
  color:var(--hc-lux-ink)!important;
}
body.portal-page #clientPortalModal{background:var(--hc-lux-bg)!important;overflow-x:clip!important}
#clientPortalModal .client-portal-shell #hcClientSidebar,
body.portal-page #clientPortalModal .client-portal-shell #hcClientSidebar{
  position:absolute!important;
  top:0!important;
  left:0!important;
  bottom:0!important;
  width:244px!important;
  min-width:244px!important;
  max-width:244px!important;
  box-sizing:border-box!important;
  padding:0!important;
  background:var(--hc-lux-paper)!important;
  border-right:1px solid var(--hc-lux-border)!important;
  border-radius:0!important;
  z-index:2!important;
  overflow-x:hidden!important;
}
#clientPortalModal .client-portal-shell > :not(#hcClientSidebar){min-width:0!important;max-width:100%;box-sizing:border-box}
#clientPortalModal .client-portal-shell .portal-kpi-grid,
#clientPortalModal .client-portal-shell .portal-project-columns,
#clientPortalModal .client-portal-shell .portal-ops-grid{min-width:0!important;max-width:100%!important}
#clientPortalModal .client-portal-shell .portal-project-columns > *,
#clientPortalModal .client-portal-shell .portal-ops-grid > *{min-width:0!important}
#clientPortalModal .client-portal-shell img,#clientPortalModal .client-portal-shell table{max-width:100%}
#clientPortalModal .client-portal-shell :is(.portal-files-card,.portal-chat-card,.portal-message-list,.portal-project-card){overflow-wrap:anywhere}
/* Unified luxurious, low-saturation client and partner nav */
.hc-client-sidebar .hc-dash-brand{background:#fffdf8!important}
#clientPortalModal .hc-client-sidebar nav button,
#clientPortalModal .client-portal-shell .hc-client-sidebar nav button,
body.portal-page #clientPortalModal .hc-client-sidebar nav button{
  width:100%!important;
  min-height:44px!important;
  margin:0!important;
  background:transparent!important;
  border:1px solid transparent!important;
  border-radius:11px!important;
  color:#354358!important;
  font-weight:650!important;
  text-align:left!important;
  padding:11px 13px!important;
  box-shadow:none!important;
  transform:none!important;
}
#clientPortalModal .hc-client-sidebar nav button.active,
#clientPortalModal .hc-client-sidebar nav button:hover,
body.portal-page #clientPortalModal .hc-client-sidebar nav button.active{
  background:#f1e7d3!important;
  border:1px solid #ddc79c!important;
  color:#78551c!important;
}
#clientPortalModal .hc-client-sidebar .hc-dash-brandmark{background:#977332!important}
#clientPortalModal .client-portal-shell .portal-kpi,
#clientPortalModal .client-portal-shell .portal-project-card,
#clientPortalModal .client-portal-shell .portal-files-card,
#clientPortalModal .client-portal-shell .portal-chat-card{background:#fff!important;border-color:var(--hc-lux-border)!important;box-shadow:0 7px 22px rgba(67,52,26,.045)!important}
@media(max-width:1100px){
  body.portal-page #clientPortalModal .client-portal-shell,
  #clientPortalModal .client-portal-shell{padding:20px 16px 28px 226px!important}
  #clientPortalModal .client-portal-shell #hcClientSidebar,
  body.portal-page #clientPortalModal .client-portal-shell #hcClientSidebar{width:208px!important;min-width:208px!important;max-width:208px!important}
}
@media(max-width:760px){
  body.portal-page #clientPortalModal .client-portal-shell,
  #clientPortalModal .client-portal-shell{padding:16px 12px 24px!important;width:100%!important;max-width:100vw!important;overflow-x:hidden!important}
  #clientPortalModal .client-portal-shell #hcClientSidebar,
  body.portal-page #clientPortalModal .client-portal-shell #hcClientSidebar{
    position:relative!important;width:100%!important;min-width:0!important;max-width:none!important;min-height:0!important;
    top:auto!important;left:auto!important;bottom:auto!important;border:1px solid var(--hc-lux-border)!important;border-radius:14px!important;
    margin:0 0 14px!important;
  }
  #clientPortalModal .hc-client-sidebar nav button,
  body.portal-page #clientPortalModal .hc-client-sidebar nav button{width:auto!important;min-width:max-content!important;white-space:nowrap!important;padding:10px!important}
  #clientPortalModal .client-portal-shell .portal-kpi-grid{grid-template-columns:repeat(2,minmax(0,1fr))!important}
}
@media(max-width:460px){#clientPortalModal .client-portal-shell .portal-kpi-grid{grid-template-columns:1fr!important}}

/* V31.0.27: client buttons final champagne-gold override (after old purple portal rules) */
#clientPortalModal .client-portal-shell{--gold-primary:#a97c32!important;--gold-light:#d6b677!important;--hc-client-button:#b58b44;--hc-client-button-hover:#956b2e;--hc-client-ink:#243044}
#clientPortalModal .client-portal-shell button:not(.decline):not(.vip-close-btn):not(.portal-download-btn):not(.hc-client-sidebar button),
#clientPortalModal .client-portal-shell .btn-gold,
#clientPortalModal .client-portal-shell .portal-hero-actions button,
#clientPortalModal .client-portal-shell .portal-primary-action button{
  background:var(--hc-client-button)!important;color:#fffefa!important;border:1px solid #97702e!important;
  box-shadow:0 5px 15px rgba(107,75,26,.14)!important;text-shadow:none!important
}
#clientPortalModal .client-portal-shell button:not(.decline):not(.vip-close-btn):not(.portal-download-btn):not(.hc-client-sidebar button):hover,
#clientPortalModal .client-portal-shell .btn-gold:hover{background:var(--hc-client-button-hover)!important;border-color:#805922!important}
#clientPortalModal .client-portal-shell .portal-hero-card,
#clientPortalModal .client-portal-shell .portal-primary-action,
#clientPortalModal .client-portal-shell .portal-action-state{background:linear-gradient(135deg,#fffefb,#f8f3e9)!important;border-color:#e6d9c3!important}
#clientPortalModal .client-portal-shell .section-eyebrow,
#clientPortalModal .client-portal-shell .portal-eyebrow{color:#866025!important}
#clientPortalModal .client-portal-shell .portal-message.client{background:#f7eedc!important;border-color:#e1ccaa!important}
#clientPortalModal .client-portal-shell :is(button,a,input,textarea,select):focus-visible{outline:3px solid rgba(169,124,50,.30)!important;outline-offset:2px!important}

/* V31.0.28: final client navigation and warm action palette */
:root{--hc-bronze:#a67a36;--hc-bronze-dark:#795521;--hc-bronze-paper:#f1e6d2;--hc-bronze-border:#dcc49a}
/* Full-page portal has a fixed navigation that stays visible while the workspace scrolls. */
@media(min-width:761px){
 body.portal-page #clientPortalModal .client-portal-shell #hcClientSidebar{
   position:fixed!important;top:0!important;bottom:0!important;
   left:max(0px,calc((100vw - 1500px)/2))!important;
   height:100dvh!important;min-height:0!important;overflow-y:auto!important;
   overscroll-behavior:contain!important;
   z-index:100!important;
 }
}
@media(min-width:761px) and (max-width:1100px){body.portal-page #clientPortalModal .client-portal-shell #hcClientSidebar{left:0!important}}
/* Force client sidebar buttons to be neutral instead of legacy violet .button rules. */
html body #clientPortalModal .client-portal-shell aside#hcClientSidebar nav button,
html body.portal-page #clientPortalModal .client-portal-shell aside#hcClientSidebar nav button{
 appearance:none!important;background:#fffdf8!important;background-image:none!important;
 color:#384253!important;border:1px solid transparent!important;
 box-shadow:none!important;text-shadow:none!important;
}
html body #clientPortalModal .client-portal-shell aside#hcClientSidebar nav button.active,
html body #clientPortalModal .client-portal-shell aside#hcClientSidebar nav button:hover,
html body.portal-page #clientPortalModal .client-portal-shell aside#hcClientSidebar nav button.active{
 background:var(--hc-bronze-paper)!important;background-image:none!important;
 color:var(--hc-bronze-dark)!important;border-color:var(--hc-bronze-border)!important;
 box-shadow:none!important;
}
/* Client primary actions, except safe neutral actions and destructive alerts. */
html body #clientPortalModal .client-portal-shell button:not(.decline):not(.danger):not(.vip-close-btn):not(.portal-download-btn):not(.hc-client-sidebar button),
html body #clientPortalModal .client-portal-shell .btn-gold{
 background:var(--hc-bronze)!important;background-image:none!important;
 color:#fff!important;border-color:#8d6529!important;
 box-shadow:0 5px 15px rgba(116,81,31,.14)!important;
}
html body #clientPortalModal .client-portal-shell button:not(.decline):not(.danger):not(.vip-close-btn):not(.portal-download-btn):not(.hc-client-sidebar button):hover{
 background:#8d642a!important;
}
html body #clientPortalModal .client-portal-shell a,
html body #clientPortalModal .client-portal-shell .portal-file-name{color:#826020!important}
html body #clientPortalModal .client-portal-shell .portal-message{background:#f6f1e7!important;border-color:#e4d9c5!important}
html body #clientPortalModal .client-portal-shell .portal-message.client{background:#f2e8d7!important;border-color:#dcc7a3!important}
html body #clientPortalModal .client-portal-shell :is(button,a,input,textarea,select):focus-visible{outline:3px solid #dfc18c!important;outline-offset:2px!important}
@media(max-width:760px){
 html body.portal-page #clientPortalModal .client-portal-shell aside#hcClientSidebar{position:relative!important;left:auto!important;top:auto!important;bottom:auto!important;height:auto!important;}
}
/* Partner navigation: warm neutral links with a bronze active state. */
body:has(#hcPartnerSidebar) .hc-dash-sidebar nav a.hc-active,
body:has(#hcPartnerSidebar) .hc-dash-sidebar nav a:hover{background:#f1e6d2!important;color:#795521!important;border-color:#dcc49a!important}
