/* Navbar icon buttons — notification, messages, profile */
.nav-icon-btn {
  position: relative;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 2.35rem;
  height: 2.35rem;
  border-radius: 0.5rem;
  color: #697a8d !important;
  transition: background-color 0.15s ease, color 0.15s ease;
}

.nav-icon-btn:hover {
  background-color: rgba(67, 89, 113, 0.08);
  color: #2f3b4c !important;
}

.nav-icon-btn .nav-icon {
  font-size: 1.15rem;
  line-height: 1;
}

.nav-icon-btn .nav-badge {
  position: absolute;
  top: 0.1rem;
  right: 0.05rem;
  min-width: 1.05rem;
  height: 1.05rem;
  padding: 0 0.25rem;
  font-size: 0.6rem;
  font-weight: 700;
  line-height: 1.05rem;
  border: 2px solid #fff;
}

.nav-icon-btn .nav-badge:empty,
.nav-icon-btn .nav-badge label:empty {
  display: none;
}

/* ========== Notification dropdown ========== */
.hms-notify-menu {
  width: 22rem;
  max-width: calc(100vw - 2rem);
  max-height: min(70vh, 28rem);
  padding: 0 !important;
  overflow-y: auto;
  border-radius: 0.65rem !important;
  border: 1px solid #e7ecf1;
  box-shadow: 0 0.5rem 1.25rem rgba(67, 89, 113, 0.12) !important;
}

.hms-notify-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 0.75rem 1rem;
  background: #f8fafc;
  border-bottom: 1px solid #e7ecf1;
  list-style: none;
  position: sticky;
  top: 0;
  z-index: 2;
}

.hms-notify-title {
  font-size: 0.8125rem;
  font-weight: 700;
  color: #2f3b4c;
  letter-spacing: 0.02em;
  text-transform: uppercase;
}

.hms-notify-menu .dropdown-item {
  padding: 0.55rem 1rem;
  font-size: 0.8125rem;
  color: #566a7f !important;
  white-space: normal;
  border-radius: 0;
}

.hms-notify-menu .dropdown-item:hover,
.hms-notify-menu .dropdown-item:focus {
  background-color: rgba(var(--app-primary-rgb, 105, 108, 255), 0.06) !important;
  color: #2f3b4c !important;
}

.hms-notify-menu .dropdown-item i {
  color: var(--app-primary, #696cff);
  font-size: 1rem;
  opacity: 0.9;
}

.hms-notify-menu .dropdown-item .badge {
  font-size: 0.65rem;
  min-width: 1.25rem;
  height: 1.25rem;
}

.hms-notify-footer {
  list-style: none;
  background: #f8fafc;
  border-top: 1px solid #e7ecf1;
  position: sticky;
  bottom: 0;
  z-index: 2;
}

.hms-notify-footer .dropdown-item {
  text-align: center !important;
  font-weight: 600;
  color: var(--app-primary, #696cff) !important;
  padding: 0.6rem 1rem;
}

.hms-notify-footer .dropdown-item:hover {
  background: rgba(var(--app-primary-rgb, 105, 108, 255), 0.08) !important;
}

.hms-notify-footer .dropdown-divider {
  margin: 0;
  border-color: #e7ecf1;
}

/* ========== Profile dropdown ========== */
.hms-profile-menu {
  min-width: 15rem;
  padding: 0 !important;
  overflow: hidden;
  border-radius: 0.65rem !important;
  border: 1px solid #e7ecf1;
  box-shadow: 0 0.5rem 1.25rem rgba(67, 89, 113, 0.12) !important;
}

.hms-profile-menu > li:first-child .dropdown-item {
  padding: 0.85rem 1rem;
  pointer-events: none;
  background: #f8fafc;
  border-bottom: 1px solid #e7ecf1;
}

.hms-profile-menu .dropdown-item {
  padding: 0.55rem 1.15rem;
  font-size: 0.8125rem;
  color: #566a7f !important;
}

.hms-profile-menu .dropdown-item:hover,
.hms-profile-menu .dropdown-item:focus {
  background-color: rgba(67, 89, 113, 0.06) !important;
  color: #2f3b4c !important;
}

.hms-profile-menu .dropdown-item i {
  color: #8a97a8;
  font-size: 1.05rem;
}

.hms-profile-menu .dropdown-item:hover i {
  color: var(--app-primary, #696cff);
}

.hms-profile-menu .dropdown-divider {
  margin: 0.25rem 0;
  border-color: #eceef1;
}

.hms-profile-menu .fw-medium {
  color: #2f3b4c !important;
  font-size: 0.875rem;
}

/* ========== Chat nav dropdown ========== */
.hms-chat-menu {
  min-width: 12rem;
  padding: 0.35rem !important;
  border-radius: 0.65rem !important;
  border: 1px solid #e7ecf1;
  box-shadow: 0 0.5rem 1.25rem rgba(67, 89, 113, 0.12) !important;
}

.hms-chat-menu .dropdown-item {
  border-radius: 0.45rem;
  padding: 0.55rem 0.85rem;
  font-size: 0.8125rem;
  color: #566a7f !important;
}

.hms-chat-menu .dropdown-item:hover {
  background: rgba(var(--app-primary-rgb, 105, 108, 255), 0.06) !important;
  color: #2f3b4c !important;
}

.hms-chat-menu .dropdown-item i {
  color: var(--app-primary, #696cff);
}

.hms-chat-menu .dropdown-divider {
  margin: 0.25rem 0;
}

.hms-profile-menu li:last-child .dropdown-item:hover {
  background-color: rgba(255, 62, 29, 0.08) !important;
  color: #ff3e1d !important;
}

.hms-profile-menu li:last-child .dropdown-item:hover i {
  color: #ff3e1d;
}

/* Appearance panel inside profile menu */
.hms-profile-menu .appearance-panel {
  padding: 0.65rem 1rem 0.75rem;
}

/* Dark mode */
html.dark-style .hms-notify-menu,
html.dark-style .hms-profile-menu,
html.dark-style .hms-chat-menu {
  background: var(--app-surface-elevated, #2d2d30);
  border: 1px solid var(--app-border, #555555);
}

html.dark-style .hms-notify-header,
html.dark-style .hms-notify-footer,
html.dark-style .hms-profile-menu > li:first-child .dropdown-item {
  background: var(--app-surface, #252526);
  border-color: var(--app-border, #555555);
}

html.dark-style .hms-notify-title,
html.dark-style .hms-profile-menu .fw-medium {
  color: var(--app-heading, #f3f3f3) !important;
}

html.dark-style .hms-notify-menu .dropdown-item,
html.dark-style .hms-profile-menu .dropdown-item,
html.dark-style .hms-chat-menu .dropdown-item {
  color: var(--app-text, #cccccc) !important;
}

html.dark-style .nav-icon-btn {
  color: var(--app-text, #cccccc) !important;
}

html.dark-style .nav-icon-btn .nav-badge {
  border-color: var(--app-surface, #252526);
}
