/* Helen & Sons HRIS — Full labeled navigation + interactive overview.
   Overrides the video-inspired icon-only rail without removing its dashboard design.
   Corporate navy #000040, white #ffffff and gold accent is used throughout. */
:root{--hs-navy:#000040;--hs-white:#ffffff;--hs-highlight:#F4C542}
html .app-shell{max-width:1760px!important}
html .sidebar{
  position:sticky!important;top:0!important;left:auto!important;bottom:auto!important;
  flex:0 0 251px!important;width:251px!important;min-width:251px!important;
  height:calc(100vh - 64px)!important;min-height:620px!important;
  display:flex!important;flex-direction:column!important;align-items:stretch!important;
  margin:0!important;padding:26px 15px 18px!important;
  overflow-y:auto!important;overflow-x:hidden!important;background:#000040!important;
  z-index:40!important;box-shadow:none!important;border-radius:0!important;
}
html .brand-logo.side{
  display:flex!important;justify-content:flex-start!important;align-items:center!important;
  width:100%!important;min-height:56px!important;
  margin:2px 0 34px!important;padding:0 7px!important;gap:10px!important;
}
html .brand-logo.side .side-logo{width:51px!important;height:51px!important;flex:0 0 51px!important;object-fit:contain!important}
html .brand-logo.side .brand-wordmark{
  display:block!important;color:#fff!important;font-size:13px!important;font-weight:800!important;
  white-space:nowrap!important;letter-spacing:.005em!important;line-height:1.4!important;
}
html .brand-logo.side .brand-wordmark span{color:#fff!important}
html .brand-logo.side .brand-wordmark small{display:block!important;color:#cbd0e5!important;font-size:7.5px!important;letter-spacing:.09em!important;margin-top:4px!important}
html .sidebar .side-group-label{display:block!important;margin:0 12px 14px!important;color:#aeb7d3!important;font-size:9px!important;font-weight:800!important;letter-spacing:.16em!important}
html .side-nav{width:100%!important;display:flex!important;align-items:stretch!important;gap:5px!important;flex-direction:column!important}
html .sidebar .nav-item{
  display:flex!important;align-items:center!important;justify-content:flex-start!important;
  gap:13px!important;flex:0 0 auto!important;width:100%!important;height:auto!important;
  min-height:45px!important;padding:12px 12px!important;
  font-size:12.5px!important;line-height:1.3!important;font-weight:650!important;
  text-align:left!important;color:#d4d9ed!important;background:transparent!important;
  border:1px solid transparent!important;border-radius:12px!important;
  white-space:nowrap!important;transform:none!important;box-shadow:none!important;
  transition:background .16s ease,color .16s ease!important;
}
html .sidebar .nav-item:hover{background:#242463!important;color:#fff!important;transform:none!important}
html .sidebar .nav-item.active{background:#fff!important;border-color:#fff!important;color:#000040!important;box-shadow:none!important}
html .sidebar .nav-icon{width:21px!important;height:21px!important;flex:0 0 21px!important;display:grid!important;place-items:center!important;color:inherit!important;line-height:1!important}
html .sidebar .nav-icon svg{display:block!important;width:20px!important;height:20px!important;stroke:currentColor!important}
html[data-theme="light"] .sidebar .nav-item .nav-icon,
html[data-theme="dark"] .sidebar .nav-item .nav-icon{color:inherit!important}
html[data-theme="light"] .sidebar .nav-item:hover .nav-icon,
html[data-theme="dark"] .sidebar .nav-item:hover .nav-icon{color:#fff!important}
html[data-theme="light"] .sidebar .nav-item.active .nav-icon,
html[data-theme="dark"] .sidebar .nav-item.active .nav-icon{color:#000040!important}
html .sidebar .nav-count{
  position:static!important;right:auto!important;top:auto!important;margin-left:auto!important;
  flex:0 0 auto!important;min-width:20px!important;height:20px!important;padding:3px 6px!important;
  border:0!important;background:#F4C542!important;border-radius:100px!important;
  color:#000040!important;font-size:10px!important;font-weight:850!important;
}
html .sidebar .side-hint{display:flex!important;background:#131350!important;border:1px solid #343477!important;border-radius:13px!important;padding:11px 10px!important;gap:9px!important;margin:0 0 11px!important}
html .sidebar .side-hint :is(strong,small){color:#fff!important}
html .sidebar .side-hint small{color:#b5bdd7!important}
html .sidebar-bottom{width:100%!important;margin-top:auto!important;padding-top:18px!important;gap:5px!important;align-items:stretch!important;display:flex!important;flex-direction:column!important}
html .sidebar-bottom .logout-btn{
  display:flex!important;justify-content:flex-start!important;align-items:center!important;
  width:100%!important;height:auto!important;min-height:44px!important;padding:10px 13px!important;
  text-align:left!important;color:#fff!important;font-size:12.5px!important;font-weight:700!important;
  background:transparent!important;border-radius:12px!important;
}
html .sidebar-bottom .logout-btn:hover{background:#242463!important}
html .sidebar-bottom .logout-btn span{font-size:22px!important;margin-right:12px!important}
html .workspace{flex:1 1 auto!important;min-width:0!important;margin:0!important}
.sidebar-mobile-heading,html .mobile-menu-toggle,html .mobile-menu-close{display:none!important}
.mobile-nav-backdrop{display:none!important}
/* Card navigation: buttons, not decorative tiles. */
html .metric-grid .metric-card.metric-link{
  appearance:none;-webkit-appearance:none;cursor:pointer!important;font-family:inherit!important;
  text-align:left!important;width:100%!important;min-width:0!important;
  border:1px solid var(--studio-border)!important;
  transition:transform .16s ease,box-shadow .16s ease,border-color .16s ease!important;
}
html .metric-grid .metric-card.metric-link:hover{transform:translateY(-3px)!important;box-shadow:0 15px 28px rgba(0,0,64,.13)!important;border-color:#8e99b0!important}
html .metric-grid .metric-card.metric-link:active{transform:translateY(-1px)!important}
html .metric-grid .metric-card.metric-link:focus-visible{outline:3px solid #000040!important;outline-offset:4px!important}
html[data-theme="dark"] .metric-grid .metric-card.metric-link:focus-visible{outline-color:#F4C542!important}
html .metric-card .metric-title{display:block!important}
html .metric-card .studio-card-footer{display:flex!important}
.metric-open{
  position:absolute;top:19px;right:18px;width:27px;height:27px;border-radius:50%;
  display:grid;place-items:center;font-size:19px;font-weight:800;
  color:var(--studio-foreground);background:var(--studio-inner);border:1px solid var(--studio-border);
  transition:transform .15s ease;
}
html .metric-card:nth-child(2) .metric-open{background:#000040;color:#F4C542;border-color:#000040}
html .metric-card.metric-link:hover .metric-open{transform:translate(2px,-2px)}
html .metric-card.metric-link .card-symbol{flex-shrink:0}
html .metric-card.metric-link .metric-title{padding-right:8px!important}
/* Useful filtering for card drill-down pages. */
.attendance-view-filter,.alert-view-filter{display:flex;align-items:center;gap:8px;flex-wrap:wrap}
.attendance-view-filter label,.alert-view-filter label{font-size:11px;font-weight:800;color:var(--studio-softtext)}
html .attendance-view-filter select,html .alert-view-filter select{
  max-width:180px;min-width:135px;min-height:38px;padding:8px 12px;border-radius:12px;
  border:1px solid var(--studio-border);color:var(--studio-foreground);
  background:var(--studio-panel);font-size:12px;font-weight:650;
}
html .attendance-view-filter select:focus-visible,html .alert-view-filter select:focus-visible{outline:2px solid var(--studio-foreground);outline-offset:2px}
/* Keep a comfortable two-column layout when the restored sidebar reduces workspace width. */
@media(max-width:1380px){
  html .metric-grid{grid-template-columns:repeat(2,minmax(0,1fr))!important}
  html .metric-card.metric-link{min-height:205px!important}
  html .topbar{padding:8px 16px!important}
  html .topbar-actions{gap:6px!important}
}
/* On tablet/mobile use an off-canvas menu so the content gets full width. */
@media(max-width:900px){
  html .app-shell{width:100%!important;max-width:none!important;min-height:100vh!important;
    margin:0!important;padding:0!important;border:0!important;border-radius:0!important;box-shadow:none!important;overflow:visible!important}
  html .workspace{width:100%!important;min-width:0!important;margin:0!important}
  html .sidebar{
    position:fixed!important;left:0!important;top:0!important;bottom:0!important;
    width:min(290px,calc(100vw - 42px))!important;
    min-width:0!important;max-width:290px!important;
    height:100dvh!important;min-height:0!important;
    padding:15px 16px 21px!important;overflow-y:auto!important;
    transform:translateX(-105%)!important;visibility:hidden!important;
    transition:transform .2s ease,visibility .2s!important;z-index:600!important;
  }
  html .sidebar.mobile-open{transform:translateX(0)!important;visibility:visible!important}
  html .sidebar .brand-logo.side{margin-bottom:23px!important}
  html .sidebar-mobile-heading{display:flex!important;color:#cdd4e7;align-items:center;justify-content:space-between;
    font-size:10px;font-weight:900;letter-spacing:.15em;padding:0 8px 9px}
  html .mobile-menu-close{display:grid!important;place-items:center;width:39px;height:39px;color:#fff;
    background:#202060;border:1px solid #404078;border-radius:12px;font-size:17px}
  html .mobile-menu-toggle{display:grid!important;place-items:center;width:42px;height:42px;min-width:42px;
    background:var(--studio-panel)!important;border:1px solid var(--studio-border)!important;
    color:var(--studio-foreground)!important;border-radius:12px!important;font-size:22px;line-height:1;
    padding:0!important;margin:0 4px 0 0!important;cursor:pointer;flex:0 0 auto}
  .mobile-nav-backdrop:not(.hidden){display:block!important;position:fixed!important;inset:0!important;z-index:590!important;
    width:100vw!important;height:100dvh!important;border:0!important;border-radius:0!important;
    background:rgba(0,0,30,.60)!important;cursor:pointer}
  body.mobile-menu-active{overflow:hidden}
  html .topbar{display:flex!important;justify-content:flex-start!important;flex-wrap:nowrap;min-height:68px!important;
    height:auto!important;padding:9px 14px!important;gap:8px!important;position:relative!important}
  html .topbar .mobile-nav-label{display:block!important;font-weight:900!important;color:var(--studio-foreground)!important}
  html .topbar .breadcrumb{display:none!important}
  html .topbar-actions{margin-left:auto!important;min-width:0!important;gap:6px!important}
  html .topbar .top-user{display:none!important}
  html .mode-warning{margin:0 13px 8px!important}
  html .page-wrap{width:100%!important;padding:14px 15px 32px!important}
  html .studio-hero h2{font-size:clamp(35px,5.4vw,48px)}
  html .metric-grid{grid-template-columns:repeat(2,minmax(0,1fr))!important}
  html .studio-hero{padding-top:15px}
}
@media(max-width:580px){
  html .topbar{padding:8px 10px!important;gap:4px!important;min-height:62px!important}
  html .mobile-menu-toggle{width:38px;height:38px;min-width:38px;font-size:20px;margin-right:0!important}
  html .topbar .mobile-nav-label{font-size:10px!important;letter-spacing:.035em!important;white-space:nowrap}
  html .topbar-actions{gap:4px!important}
  html .topbar .demo-switch-wrap select{max-width:116px!important;min-width:0!important;min-height:34px!important;font-size:10px!important}
  html .topbar .notification-bell{height:31px!important;width:31px!important}
  html .topbar .theme-switch{padding:2px!important}
  html .topbar .theme-option{padding:5px!important}
  html .topbar .theme-option .theme-icon{font-size:14px!important}
  html .topbar .account-circle{width:31px;height:31px;min-width:31px;max-width:31px;flex:0 0 31px}
  html .page-wrap{padding:9px 11px 28px!important}
  html .metric-grid{gap:10px!important}
  html .metric-card.metric-link{min-height:190px!important;padding:15px!important}
  html .metric-card.metric-link .card-symbol{margin-bottom:13px!important}
  .metric-open{width:22px;height:22px;top:15px;right:12px;font-size:17px}
  html .metric-card.metric-link .metric-title{font-size:12px!important;line-height:1.4!important}
  html .metric-card.metric-link>strong{font-size:44px!important;letter-spacing:-.06em!important;margin-top:7px!important}
  html .metric-card.metric-link>small{font-size:10px!important}
  .studio-card-footer span{height:17px!important}
  html #page-attendance .data-panel>.panel-title-row{align-items:stretch!important}
  .attendance-view-filter,.alert-view-filter{justify-content:flex-start}
  html .attendance-view-filter select,html .alert-view-filter select{min-width:120px;max-width:165px}
}
@media(max-width:375px){
  html .topbar .mobile-nav-label{display:none!important}
  html .metric-card.metric-link{min-height:188px!important;padding:12px!important}
  html .metric-card.metric-link .metric-title{font-size:11px!important}
  html .metric-card.metric-link>strong{font-size:39px!important}
  html .metric-card.metric-link>small{font-size:9px!important}
  .studio-card-footer{gap:2px!important}
  .studio-card-footer span{min-width:0!important}
}
@media(prefers-reduced-motion:reduce){html .sidebar,html .metric-card.metric-link,html .metric-open{transition:none!important}}
/* Role-visibility must take precedence over the restored full-width nav styling. */
html .sidebar .nav-item.hidden,html .sidebar .nav-count.hidden{display:none!important}

/* Demo role selection is moved into the mobile drawer to keep a narrow phone header usable. */
.mobile-demo-switch{display:none!important}
@media(max-width:900px){
 html .sidebar .mobile-demo-switch:not(.hidden){display:flex!important;flex-direction:column;gap:8px!important;
   border:1px solid #41417a;background:#151550;border-radius:13px;padding:13px 12px;margin-bottom:10px}
 html .mobile-demo-switch label{color:#c7cde4;font-size:10px;font-weight:800;letter-spacing:.08em}
 html .mobile-demo-switch select{width:100%;min-height:40px;border:1px solid #79799e;border-radius:10px;
   background:#fff;color:#000040;font-size:12px;font-weight:700;padding:8px}
 html .sidebar .mobile-demo-switch.hidden{display:none!important}
}
