/* =========================================================
   HEXAGON ASSETS - TOPBAR FINAL UPDATED
   Clean dark premium style
   ========================================================= */

:root {
  --dc-topbar-bg-1: #15254b;
  --dc-topbar-bg-2: #1a2953;
  --dc-topbar-border: rgba(255, 255, 255, 0.08);
  --dc-topbar-text: #f8fbff;
  --dc-topbar-text-soft: #c7d5f1;
  --dc-topbar-muted: #93a6cc;
  --dc-topbar-btn-bg: rgba(255, 255, 255, 0.06);
  --dc-topbar-btn-border: rgba(255, 255, 255, 0.09);
  --dc-topbar-panel-bg-1: #0c1222;
  --dc-topbar-panel-bg-2: #0a1020;
  --dc-topbar-panel-bg-3: #111a30;
  --dc-topbar-panel-border: rgba(255, 255, 255, 0.08);
  --dc-topbar-panel-highlight: rgba(255, 255, 255, 0.05);
  --dc-topbar-blue: #3b82f6;
  --dc-topbar-blue-dark: #2563eb;
  --dc-topbar-danger: #ef4444;
  --dc-topbar-danger-soft: #fca5a5;
  --dc-topbar-shadow: 0 10px 24px rgba(0, 0, 0, 0.18);
  --dc-topbar-dropdown-shadow: 0 24px 50px rgba(0, 0, 0, 0.34);
}

/* =========================================================
   TOPBAR
   ========================================================= */

.app-header.dc-topbar {
  background: linear-gradient(
    90deg,
    var(--dc-topbar-bg-1) 0%,
    var(--dc-topbar-bg-2) 100%
  ) !important;
  border-bottom: 1px solid var(--dc-topbar-border);
  box-shadow: var(--dc-topbar-shadow);
  min-height: 58px;
  padding: 0 0.65rem;
  z-index: 1035;
}

.dc-topbar .container-fluid {
  min-height: 58px;
}

.dc-topbar .nav-link {
  color: var(--dc-topbar-text-soft) !important;
  transition: all 0.18s ease-in-out;
}

/* =========================================================
   TOPBAR BUTTONS
   ========================================================= */

.dc-topbar-btn {
  width: 40px;
  height: 40px;
  padding: 0 !important;
  border-radius: 14px;
  display: inline-flex !important;
  align-items: center;
  justify-content: center;
  background: linear-gradient(
    180deg,
    var(--dc-topbar-btn-bg),
    rgba(255, 255, 255, 0.03)
  );
  border: 1px solid var(--dc-topbar-btn-border);
  color: #e7efff !important;
  margin-left: 0.22rem;
  box-shadow: inset 0 1px 0 rgba(255, 255, 255, 0.04);
}

.dc-topbar-btn:hover,
.dc-topbar-btn:focus {
  background: linear-gradient(
    180deg,
    rgba(59, 130, 246, 0.2),
    rgba(37, 99, 235, 0.1)
  );
  border-color: rgba(96, 165, 250, 0.24);
  color: #ffffff !important;
  transform: translateY(-1px);
  box-shadow: 0 10px 20px rgba(37, 99, 235, 0.14);
}

.dc-topbar-btn i {
  font-size: 0.95rem;
  line-height: 1;
  display: inline-block;
}

.dc-sidebar-toggle {
  margin-right: 0.3rem;
}

/* =========================================================
   HOME LINK
   ========================================================= */

.dc-topbar-home {
  display: inline-flex !important;
  align-items: center;
  min-height: 40px;
  padding: 0.55rem 0.95rem !important;
  border-radius: 12px;
  font-family: "Inter", "Source Sans 3", sans-serif;
  font-size: 0.87rem;
  font-weight: 600;
  color: #eef4ff !important;
}

.dc-topbar-home:hover,
.dc-topbar-home:focus {
  background: rgba(255, 255, 255, 0.05);
  color: #ffffff !important;
}

/* =========================================================
   USER MENU TRIGGER
   ========================================================= */

.dc-user-menu-trigger {
  display: inline-flex !important;
  align-items: center;
  gap: 0.68rem;
  min-height: 42px;
  padding: 0.28rem 0.5rem 0.28rem 0.34rem !important;
  margin-left: 0.32rem;
  border-radius: 14px;
  color: #ffffff !important;
  background: linear-gradient(
    180deg,
    rgba(255, 255, 255, 0.06),
    rgba(255, 255, 255, 0.03)
  );
  border: 1px solid rgba(255, 255, 255, 0.07);
  box-shadow: inset 0 1px 0 rgba(255, 255, 255, 0.04);
}

.dc-user-menu-trigger:hover,
.dc-user-menu-trigger:focus {
  background: linear-gradient(
    180deg,
    rgba(59, 130, 246, 0.18),
    rgba(37, 99, 235, 0.1)
  );
  border-color: rgba(96, 165, 250, 0.22);
  box-shadow: 0 10px 22px rgba(37, 99, 235, 0.12);
  transform: translateY(-1px);
}

.dc-user-image {
  width: 34px !important;
  height: 34px !important;
  min-width: 34px;
  object-fit: cover;
  border-radius: 12px !important;
  border: 2px solid rgba(255, 255, 255, 0.12);
  background: #0f172a;
  box-shadow: 0 4px 14px rgba(0, 0, 0, 0.18);
}

.dc-user-text {
  display: flex;
  flex-direction: column;
  line-height: 1.08;
  min-width: 0;
}

.dc-user-name {
  font-family: "Inter", "Source Sans 3", sans-serif;
  font-size: 0.84rem;
  font-weight: 700;
  color: #ffffff;
  white-space: nowrap;
  max-width: 150px;
  overflow: hidden;
  text-overflow: ellipsis;
}

.dc-user-role {
  font-family: "Inter", "Source Sans 3", sans-serif;
  font-size: 0.71rem;
  font-weight: 500;
  color: var(--dc-topbar-text-soft);
  white-space: nowrap;
  max-width: 150px;
  overflow: hidden;
  text-overflow: ellipsis;
}

.dc-user-caret {
  font-size: 0.75rem;
  color: var(--dc-topbar-muted);
  line-height: 1;
}

/* =========================================================
   DROPDOWN
   ========================================================= */

.dc-topbar-dropdown {
  min-width: 290px;
  margin-top: 0.72rem !important;
  padding: 0;
  border-radius: 20px;
  border: 1px solid var(--dc-topbar-panel-border);
  background: linear-gradient(
    180deg,
    rgba(18, 27, 47, 0.98) 0%,
    rgba(9, 16, 31, 0.98) 100%
  );
  box-shadow: var(--dc-topbar-dropdown-shadow);
  overflow: hidden;
  backdrop-filter: blur(14px);
  -webkit-backdrop-filter: blur(14px);
}

.dc-user-dropdown {
  width: 310px;
}

/* =========================================================
   USER DROPDOWN HEADER
   ========================================================= */

.dc-user-dropdown-header {
  position: relative;
  padding: 0;
  overflow: hidden;
  background:
    radial-gradient(
      circle at top right,
      rgba(255, 255, 255, 0.08),
      transparent 26%
    ),
    linear-gradient(
      180deg,
      rgba(255, 255, 255, 0.05) 0%,
      rgba(255, 255, 255, 0.02) 100%
    );
  border-bottom: 1px solid rgba(255, 255, 255, 0.08);
}

.dc-user-dropdown-cover {
  height: 24px;
  background: transparent;
  border-bottom: 0;
}

.dc-user-dropdown-profile {
  position: relative;
  display: flex;
  gap: 0.9rem;
  align-items: center;
  padding: 0.95rem 1rem 0.95rem 1rem;
  margin-top: 0;
}

.dc-user-dropdown-avatar-wrap {
  position: relative;
  width: 58px;
  height: 58px;
  min-width: 58px;
  border-radius: 18px;
  padding: 3px;
  background: linear-gradient(
    135deg,
    rgba(255, 255, 255, 0.18),
    rgba(255, 255, 255, 0.06)
  );
  box-shadow: 0 10px 24px rgba(0, 0, 0, 0.22);
}

.dc-user-dropdown-image {
  width: 100%;
  height: 100%;
  object-fit: cover;
  border-radius: 15px;
  display: block;
  background: #0f172a;
}

.dc-user-dropdown-info {
  min-width: 0;
  padding-top: 0;
}

.dc-user-dropdown-name {
  color: #ffffff;
  font-size: 0.98rem;
  font-weight: 700;
  line-height: 1.2;
  margin-bottom: 0.18rem;
  word-break: break-word;
}

.dc-user-dropdown-role {
  color: #d5e0f6;
  font-size: 0.78rem;
  font-weight: 600;
  line-height: 1.2;
  margin-bottom: 0.28rem;
}

.dc-user-dropdown-time {
  color: #97abd4;
  font-size: 0.72rem;
  font-weight: 500;
  line-height: 1.2;
}

/* =========================================================
   USER DROPDOWN BODY
   ========================================================= */

.dc-user-dropdown-body {
  padding: 0.7rem;
  background: transparent;
}

.dc-topbar-dropdown .dropdown-item {
  display: flex;
  align-items: center;
  gap: 0.72rem;
  min-height: 44px;
  border-radius: 14px;
  color: #dce8ff;
  font-size: 0.85rem;
  font-weight: 600;
  padding: 0.72rem 0.82rem;
  transition: all 0.18s ease-in-out;
}

.dc-topbar-dropdown .dropdown-item i {
  width: 18px;
  min-width: 18px;
  text-align: center;
  font-size: 0.88rem;
  line-height: 1;
  color: #b9cdf6;
}

.dc-topbar-dropdown .dropdown-item:hover,
.dc-topbar-dropdown .dropdown-item:focus {
  background: linear-gradient(
    90deg,
    rgba(255, 255, 255, 0.08),
    rgba(59, 130, 246, 0.1)
  );
  color: #ffffff;
}

.dc-topbar-dropdown .dropdown-item:hover i,
.dc-topbar-dropdown .dropdown-item:focus i {
  color: #ffffff;
}

.dc-topbar-dropdown .dropdown-divider {
  margin: 0.45rem 0.15rem;
  border-color: rgba(255, 255, 255, 0.08);
}

.dc-topbar-dropdown .dropdown-item.text-danger {
  color: var(--dc-topbar-danger-soft) !important;
}

.dc-topbar-dropdown .dropdown-item.text-danger i {
  color: #f8a29a !important;
}

.dc-topbar-dropdown .dropdown-item.text-danger:hover,
.dc-topbar-dropdown .dropdown-item.text-danger:focus {
  color: #ffffff !important;
  background: linear-gradient(
    90deg,
    rgba(239, 68, 68, 0.22),
    rgba(239, 68, 68, 0.08)
  );
}

.dc-topbar-dropdown .dropdown-item.text-danger:hover i,
.dc-topbar-dropdown .dropdown-item.text-danger:focus i {
  color: #ffffff !important;
}

/* =========================================================
   CARET / DEFAULT DROPDOWN FIX
   ========================================================= */

.dc-topbar .dropdown-toggle::after {
  display: none !important;
}

.dc-topbar a:focus-visible {
  outline: 2px solid rgba(96, 165, 250, 0.45);
  outline-offset: 2px;
}

/* =========================================================
   RESPONSIVE
   ========================================================= */

@media (max-width: 991.98px) {
  .app-header.dc-topbar {
    padding: 0 0.35rem;
    min-height: 54px;
  }

  .dc-topbar .container-fluid {
    min-height: 54px;
  }

  .dc-topbar-btn {
    width: 38px;
    height: 38px;
    border-radius: 12px;
    margin-left: 0.16rem;
  }

  .dc-user-menu-trigger {
    min-height: 40px;
    padding: 0.26rem 0.34rem !important;
    margin-left: 0.18rem;
    border-radius: 12px;
  }

  .dc-user-image {
    width: 32px !important;
    height: 32px !important;
    min-width: 32px;
    border-radius: 11px !important;
  }

  .dc-topbar-dropdown {
    min-width: 250px;
  }

  .dc-user-dropdown {
    width: 280px;
  }

  .dc-user-dropdown-profile {
    gap: 0.78rem;
    padding: 0.85rem 0.85rem 0.85rem 0.85rem;
  }

  .dc-user-dropdown-avatar-wrap {
    width: 52px;
    height: 52px;
    min-width: 52px;
    border-radius: 16px;
  }

  .dc-user-dropdown-image {
    border-radius: 13px;
  }

  .dc-user-dropdown-name {
    font-size: 0.92rem;
  }

  .dc-user-dropdown-role {
    font-size: 0.75rem;
  }

  .dc-user-dropdown-time {
    font-size: 0.7rem;
  }
}

@media (max-width: 575.98px) {
  .dc-topbar-home {
    display: none !important;
  }

  .dc-topbar-btn {
    width: 36px;
    height: 36px;
  }

  .dc-user-menu-trigger {
    padding: 0.22rem 0.28rem !important;
  }

  .dc-user-dropdown {
    width: 260px;
    right: 0 !important;
    left: auto !important;
  }
}
