/* Full-size professional medical layout */

:root{
  --ahms-primary:#0ea5a2;
  --ahms-primary-soft:rgba(14,165,162,0.12);
  --ahms-text:#0f172a;
  --ahms-text-muted:#4b5563;
  --ahms-surface:#f9fbfb;
  --ahms-surface-alt:#ffffff;
  --ahms-sidebar-bg:#0b1f24;
  --ahms-sidebar-card:#102932;
  --ahms-sidebar-border:rgba(255,255,255,0.05);
  --ahms-border:#e2e8f0;
  --ahms-shadow:0 12px 34px rgba(15, 23, 42, 0.14);
}

*,*::before,*::after{
  box-sizing:border-box;
}

html,body{
  height:100%;
  margin:0;
  padding:0;
}

body.app-body{
  min-height:100vh;
  font-family:"Inter",system-ui,-apple-system,"Segoe UI",sans-serif;
  background:linear-gradient(160deg,#ecfdfd 0%,#f4fbfb 50%,#ffffff 100%);
  color:var(--ahms-text);
}

/* APP SHELL */
.app-shell{
  width:100%;
}

.app-sidebar{
  width:280px;
  background:var(--ahms-sidebar-bg);
  color:#ffffff;
  padding:1.5rem 1.25rem;
  border-right:1px solid rgba(255,255,255,0.08);
  overflow-y:auto;
  position:relative;
}

.app-sidebar::-webkit-scrollbar{
  width:6px;
}
.app-sidebar::-webkit-scrollbar-thumb{
  background:rgba(255,255,255,0.12);
  border-radius:999px;
}

.sidebar-shell{
  min-height:100%;
}

.app-sidebar small,
.app-sidebar span,
.app-sidebar p{
  color:rgba(255,255,255,0.8);
}

.app-sidebar .nav{
  gap:.25rem;
  padding-top:1rem;
}

.app-sidebar .nav-item{
  list-style:none;
}

.app-sidebar .nav-link{
  color:rgba(255,255,255,0.88);
  padding:.65rem .85rem;
  border-radius:.75rem;
  transition:background .2s ease, color .2s ease, transform .2s ease;
}

.app-sidebar .nav-link:hover{
  background:rgba(255,255,255,0.08);
  color:#fff;
  transform:translateX(2px);
}

.app-sidebar .nav-link.active{
  background:rgba(14,165,162,0.25);
  color:#ffffff;
}

.sidebar-footer{
  background:transparent;
}
.sidebar-footer small,
.sidebar-footer span{
  color:rgba(255,255,255,0.7);
}
.sidebar-footer .dropdown-menu{
  border-radius:1rem;
}
.sidebar-footer .dropdown-menu-dark{
  background:rgba(15,30,38,0.96);
  border:1px solid rgba(255,255,255,0.05);
}
.sidebar-footer .dropdown-item{
  border-radius:.75rem;
}
.sidebar-footer .dropdown-item:hover{
  background:rgba(255,255,255,0.08);
}
.sidebar-footer .dropdown-divider{
  border-color:rgba(255,255,255,0.1);
}
.app-sidebar .card{
  background:rgba(255,255,255,0.08);
  color:#ffffff;
  border-radius:1rem;
  box-shadow:none;
}
.app-sidebar .card p,
.app-sidebar .card h6{
  color:#ffffff;
}
.app-sidebar .card .btn{
  border-radius:.75rem;
}

/* MAIN */
.app-main{
  background:var(--ahms-surface);
  padding:2rem clamp(1.5rem,3vw,3rem);
  box-shadow:inset 0 1px 0 rgba(255,255,255,0.6);
}

.app-main__header{
  padding-bottom:1.5rem;
  gap:1rem;
}
.app-main__header{
  padding-bottom:1.5rem;
  gap:1rem;
}
.nav-menu-toggle{
  display:inline-flex;
  align-items:center;
  justify-content:center;
  width:42px;
  height:42px;
  border-radius:999px;
  background:transparent;
  color:var(--ahms-text);
  border:none;
  text-decoration:none;
  transition:background .2s ease, transform .2s ease;
}
.nav-menu-toggle:hover,
.nav-menu-toggle:focus{
  background:rgba(14,165,162,0.12);
  transform:translateY(-1px);
  color:var(--ahms-text);
}
.nav-menu-toggle i{
  font-size:1.25rem;
}
@media (min-width:768px){
  .nav-menu-toggle{display:none!important;}
}

.app-main__title h1{
  font-weight:600;
  color:var(--ahms-text);
}

.app-main__content{
  background:var(--ahms-surface-alt);
  padding:2rem;
  border-radius:1.25rem;
  box-shadow:var(--ahms-shadow);
  overflow:auto;
}

.app-main__content > .alert:first-child{
  margin-top:0;
}

.app-footer{
  color:var(--ahms-text-muted);
}

/* BREADCRUMB */
.breadcrumb{
  --bs-breadcrumb-divider:'›';
  font-size:.85rem;
}
.breadcrumb-item + .breadcrumb-item::before{
  color:var(--ahms-text-muted);
}

/* ALERTS */
.alert{
  border-radius:.75rem;
  border:none;
  box-shadow:0 12px 30px rgba(15,23,42,0.12);
}

/* KPI CARDS */
.card.kpi{
  border:none;
  border-radius:1rem;
  background:#fff;
  box-shadow:var(--ahms-shadow);
}
.card.kpi .card-body{
  padding:1.25rem 1.5rem;
}
.card.kpi i{
  color:var(--ahms-primary);
}

/* OFFCANVAS */
.offcanvas{
  width:280px;
  background:var(--ahms-sidebar-bg);
  color:#fff;
}
.offcanvas .offcanvas-header{
  background:rgba(255,255,255,0.04);
}
.offcanvas .btn-close{
  filter:invert(1) grayscale(1);
}
.offcanvas .nav-link{
  color:rgba(255,255,255,0.88);
}
.offcanvas .nav-link.active{
  background:rgba(14,165,162,0.25);
  color:#fff;
}

/* RESPONSIVE */
@media (max-width:991.98px){
  .app-main{
    padding:1.5rem 1.25rem;
  }
  .app-main__content{
    padding:1.5rem;
  }
}

@media (max-width:767.98px){
  .app-shell{
    flex-direction:column;
  }
  .app-main{
    padding:1.25rem 1rem 2rem;
  }
  .app-main__content{
    padding:1.25rem;
  }
}
