/**
 * Panel shell top bar (guest, user, admin) — header + pill buttons.
 * Scoped to nav.panel-topbar.
 */

body.g-sidenav-show {
  --panel-topbar-h: 76px;
}

body.g-sidenav-show .iq-banner {
  padding-top: var(--panel-topbar-h, 68px) !important;
}

body.g-sidenav-show:has(.panel-topbar) .main-content .iq-banner {
  padding-top: 0 !important;
}

body.g-sidenav-show:has(.panel-topbar) #panel-ajax-content {
  padding-top: calc(
    var(--panel-shell-header-h, var(--panel-topbar-h, 72px)) + var(--panel-below-header-gap, 32px)
  ) !important;
  box-sizing: border-box;
}

body.g-sidenav-show .sidebar + .main-content .panel-topbar.iq-navbar,
body.g-sidenav-show .sidebar + .main-content .panel-topbar.iq-navbar.navs-sticky,
body.g-sidenav-show .sidebar + .main-content .panel-topbar.iq-navbar.navs-sticky.menu-sticky,
body.g-sidenav-show .main-content .panel-topbar.iq-navbar {
  position: fixed !important;
  top: 0 !important;
  bottom: auto !important;
  left: var(--sidebar-width, 18rem) !important;
  right: 0 !important;
  width: auto !important;
  max-width: none !important;
  margin: 0 !important;
  z-index: 1045 !important;
}

html[dir="rtl"] body.g-sidenav-show .sidebar + .main-content .panel-topbar.iq-navbar,
html[dir="rtl"] body.g-sidenav-show .main-content .panel-topbar.iq-navbar {
  left: 0 !important;
  right: var(--sidebar-width, 18rem) !important;
}

@media (max-width: 991.98px) {
  body.g-sidenav-show {
    --panel-topbar-h: 64px;
  }

  body.g-sidenav-show .sidebar + .main-content .panel-topbar.iq-navbar,
  body.g-sidenav-show .main-content .panel-topbar.iq-navbar,
  html[dir="rtl"] body.g-sidenav-show .main-content .panel-topbar.iq-navbar {
    left: 0 !important;
    right: 0 !important;
    width: 100% !important;
  }
}

.panel-topbar.iq-navbar,
.panel-topbar.navbar.iq-navbar,
.panel-topbar.navbar.navbar-light.iq-navbar {
  position: relative;
  background: linear-gradient(180deg, #ffffff 0%, #fcfdff 100%) !important;
  background-color: #ffffff !important;
  border: 0 !important;
  border-bottom: 1px solid rgba(226, 232, 240, 0.95) !important;
  box-shadow:
    0 1px 0 rgba(255, 255, 255, 0.98) inset,
    0 10px 32px rgba(15, 23, 42, 0.06),
    0 2px 8px rgba(49, 160, 255, 0.04) !important;
  backdrop-filter: saturate(1.2) blur(8px);
  -webkit-backdrop-filter: saturate(1.2) blur(8px);
  height: var(--panel-topbar-h, 72px);
  min-height: var(--panel-topbar-h, 72px);
  max-height: var(--panel-topbar-h, 72px);
  box-sizing: border-box;
  overflow: visible !important;
}

.panel-topbar.iq-navbar::before {
  content: "" !important;
  display: block !important;
  position: absolute;
  inset: 0 0 auto 0;
  height: 1px;
  background: linear-gradient(
    90deg,
    transparent 0%,
    rgba(255, 255, 255, 0.95) 12%,
    rgba(255, 255, 255, 0.95) 88%,
    transparent 100%
  );
  pointer-events: none;
  z-index: 1;
}

.panel-topbar.iq-navbar::after {
  content: "";
  position: absolute;
  left: 0;
  right: 0;
  bottom: 0;
  height: 2px;
  background: linear-gradient(
    90deg,
    rgba(49, 160, 255, 0) 0%,
    rgba(49, 160, 255, 0.45) 22%,
    rgba(99, 102, 241, 0.5) 50%,
    rgba(49, 160, 255, 0.45) 78%,
    rgba(49, 160, 255, 0) 100%
  );
  opacity: 0.85;
  pointer-events: none;
  z-index: 1;
}

.panel-topbar .navbar-inner {
  display: flex !important;
  align-items: center !important;
  justify-content: flex-start !important;
  gap: 12px !important;
  height: 100%;
  min-height: 0;
  padding: 5px 18px 3px !important;
  overflow: visible !important;
  box-sizing: border-box;
}

@media (min-width: 1200px) {
  body.g-sidenav-show .main-content .panel-topbar.iq-navbar .navbar-inner {
    padding-left: 36px !important;
    justify-content: space-between !important;
  }

  .panel-topbar .product-offcanvas {
    flex: 1 1 auto !important;
    max-width: none !important;
  }

  .panel-topbar .header-quick-actions {
    margin-left: auto !important;
    flex: 0 0 auto !important;
  }
}

.panel-topbar .product-offcanvas,
.panel-topbar .product-offcanvas.ph-head-left {
  flex: 1 1 auto !important;
  min-width: 0 !important;
  display: flex !important;
  align-items: center !important;
  justify-content: flex-start !important;
  gap: 10px !important;
}

.panel-topbar .ph-head-left .ph-title {
  flex: 0 1 auto !important;
  min-width: 0 !important;
  border: 0 !important;
  margin: 0 !important;
  padding: 2px 0 0 !important;
}

.panel-topbar .ph-head-left .ph-ai {
  flex: 0 0 auto !important;
  margin-left: 0 !important;
}

.panel-topbar .ph-head-left .panel-header-lang {
  flex: 0 0 auto !important;
  margin: 0 !important;
}

.panel-topbar .panel-brand-logo {
  display: none !important;
}

.panel-topbar .sidebar-toggle,
.panel-topbar .iq-navbar .sidebar-toggle,
.panel-topbar.nav .sidebar-toggle,
html.dark-mode .panel-topbar .sidebar-toggle {
  position: relative !important;
  left: auto !important;
  right: auto !important;
  top: auto !important;
  transform: none !important;
  width: 36px !important;
  height: 36px !important;
  min-width: 36px !important;
  padding: 0 !important;
  border: 0 !important;
  border-radius: 50% !important;
  background: linear-gradient(145deg, #3b82f6 0%, #2563eb 100%) !important;
  color: #fff !important;
  box-shadow: 0 8px 18px rgba(37, 99, 235, 0.32) !important;
  display: inline-flex !important;
  align-items: center;
  justify-content: center;
  flex-shrink: 0;
  z-index: 2;
}

.panel-topbar .sidebar-toggle svg,
.panel-topbar .sidebar-toggle .icon {
  width: 16px;
  height: 16px;
  color: #fff !important;
}

.panel-topbar .product-offcanvas,
.panel-topbar .breadcrumb-title {
  border: 0 !important;
  margin: 0 !important;
  padding: 0 !important;
  display: flex !important;
}

.panel-topbar .ph-title,
.panel-topbar .ph-title small,
.panel-topbar .ph-title h1,
.panel-topbar .ph-title h2,
.panel-topbar .ph-title h3 {
  margin: 0 !important;
  padding: 0 !important;
  color: #1e3a5f !important;
  font-size: 20px !important;
  font-weight: 700 !important;
  line-height: 1.35 !important;
  letter-spacing: -0.02em;
  text-transform: none !important;
  background: none !important;
  -webkit-text-fill-color: #1e3a5f !important;
}

.panel-topbar .ph-ai {
  margin-left: 0;
  display: inline-flex;
  align-items: center;
  gap: 8px;
  min-height: 44px;
  padding: 8px 14px 8px 12px;
  border-radius: 999px;
  text-decoration: none !important;
  color: #64748b !important;
  font-size: 14px;
  font-weight: 500;
  border: 1.5px solid transparent;
  background:
    linear-gradient(#fff, #fff) padding-box,
    linear-gradient(90deg, #60a5fa, #2563eb, #93c5fd) border-box;
  box-shadow:
    inset 0 1px 0 rgba(255, 255, 255, 0.95),
    0 4px 14px rgba(37, 99, 235, 0.11),
    0 12px 28px rgba(15, 23, 42, 0.08);
  white-space: nowrap;
  flex: 0 1 auto;
  min-width: 0;
  max-width: min(100%, 340px);
  transition: transform 0.18s ease, box-shadow 0.18s ease;
}

.panel-topbar .ph-ai:hover {
  color: #334155 !important;
  transform: translateY(-1px);
  box-shadow:
    inset 0 1px 0 rgba(255, 255, 255, 1),
    0 6px 18px rgba(37, 99, 235, 0.14),
    0 16px 34px rgba(37, 99, 235, 0.16);
}

.panel-topbar .ph-ai.is-active {
  box-shadow:
    inset 0 0 0 1px rgba(37, 99, 235, 0.1),
    0 6px 18px rgba(37, 99, 235, 0.16),
    0 14px 32px rgba(15, 23, 42, 0.08);
}

.panel-topbar .ph-ai__spark {
  width: 18px;
  height: 18px;
  color: #3b82f6;
  flex-shrink: 0;
}

.panel-topbar .ph-ai__text {
  flex: 1 1 auto;
  min-width: 0;
  overflow: hidden;
  text-overflow: ellipsis;
}

.panel-topbar .ph-ai__badge {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  height: 22px;
  padding: 0 8px;
  border-radius: 999px;
  background: #2563eb;
  color: #fff;
  font-size: 11px;
  font-weight: 800;
  letter-spacing: 0.04em;
  flex-shrink: 0;
}

.panel-topbar #currencyDropdown,
.panel-topbar .ph-wallet,
.panel-topbar #currencyDropdown.btn-success,
.panel-topbar #currencyDropdown.btn-successam,
.panel-topbar .ph-wallet.btn-success,
.panel-topbar .ph-wallet.btn-successam {
  display: inline-flex !important;
  align-items: center !important;
  justify-content: center;
  gap: 4px;
  min-height: 0 !important;
  height: auto !important;
  --bs-btn-padding-y: 8px;
  --bs-btn-padding-x: 16px;
  --bs-btn-line-height: 1;
  padding-block: 8px !important;
  padding-inline: 16px 14px !important;
  border: none !important;
  border-radius: 12px !important;
  line-height: 1 !important;
  background: linear-gradient(135deg, #10b981 0%, #059669 100%) !important;
  background-image: linear-gradient(135deg, #10b981 0%, #059669 100%) !important;
  --bs-btn-bg: #10b981;
  --bs-btn-border-color: transparent;
  --bs-btn-color: #fff;
  --bs-btn-hover-bg: #059669;
  --bs-btn-hover-border-color: transparent;
  --bs-btn-hover-color: #fff;
  --bs-btn-active-bg: #047857;
  --bs-btn-active-border-color: transparent;
  color: #fff !important;
  box-shadow: 0 4px 15px rgba(16, 185, 129, 0.3) !important;
  font-weight: 700;
  overflow: visible;
  transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1) !important;
}

.panel-topbar #currencyDropdown:hover,
.panel-topbar .ph-wallet:hover {
  transform: translateY(-1px);
  box-shadow: 0 6px 20px rgba(16, 185, 129, 0.38) !important;
}

.panel-topbar #currencyDropdown .ph-wallet-ico,
.panel-topbar .ph-wallet .ph-wallet-ico,
.panel-topbar #currencyDropdown .feather-dollar-sign {
  width: 18px;
  height: 18px;
  color: #fff !important;
  stroke: #fff;
  flex-shrink: 0;
}

.panel-topbar #currencyDropdown::after,
.panel-topbar .ph-wallet::after {
  margin-left: 3px !important;
  margin-inline-start: 3px !important;
  flex-shrink: 0;
  vertical-align: middle;
  border-top-color: rgba(255, 255, 255, 0.95) !important;
}

.panel-topbar #currencyDropdown > .d-flex.flex-column,
.panel-topbar .ph-wallet > .d-flex.flex-column {
  padding: 0 !important;
  margin: 0 !important;
  gap: 0 !important;
  min-width: 0;
  line-height: 1 !important;
}

@keyframes ph-user-dot-glow {
  0%,
  100% {
    box-shadow:
      0 0 0 2px #fff,
      0 0 0 3px rgba(34, 197, 94, 0.2),
      0 0 8px rgba(34, 197, 94, 0.45);
  }
  50% {
    box-shadow:
      0 0 0 2px #fff,
      0 0 0 4px rgba(34, 197, 94, 0.32),
      0 0 14px rgba(34, 197, 94, 0.62);
  }
}

.panel-topbar .ph-user,
.panel-topbar #itemdropdown1 a.nav-link.ph-user {
  display: inline-flex !important;
  align-items: center !important;
  gap: 8px !important;
  min-height: 42px !important;
  height: 42px !important;
  padding: 3px 12px 3px 3px !important;
  border-radius: 999px !important;
  background:
    linear-gradient(145deg, rgba(255, 255, 255, 0.97) 0%, rgba(248, 250, 252, 0.94) 52%, rgba(239, 246, 255, 0.92) 100%) !important;
  box-shadow:
    0 1px 0 rgba(255, 255, 255, 0.98) inset,
    0 0 0 1px rgba(148, 163, 184, 0.28),
    0 4px 14px rgba(37, 99, 235, 0.12),
    0 12px 32px rgba(15, 23, 42, 0.06) !important;
  border: 0 !important;
  text-decoration: none !important;
  line-height: 1 !important;
  overflow: visible !important;
  backdrop-filter: blur(10px);
  -webkit-backdrop-filter: blur(10px);
  transition: box-shadow 0.22s ease, transform 0.22s ease, background 0.22s ease;
}

.panel-topbar .ph-user:hover,
.panel-topbar #itemdropdown1.show .ph-user,
.panel-topbar #itemdropdown1.show a.nav-link.ph-user {
  background:
    linear-gradient(145deg, #ffffff 0%, #eff6ff 55%, #dbeafe 100%) !important;
  box-shadow:
    0 1px 0 rgba(255, 255, 255, 1) inset,
    0 0 0 1px rgba(37, 99, 235, 0.35),
    0 8px 22px rgba(37, 99, 235, 0.18),
    0 16px 36px rgba(15, 23, 42, 0.08) !important;
  transform: translateY(-1px);
}

.panel-topbar .ph-avatar-wrap,
.panel-topbar #itemdropdown1 .ph-avatar-wrap {
  position: relative;
  display: flex !important;
  align-items: center !important;
  justify-content: center !important;
  width: 34px !important;
  height: 34px !important;
  flex: 0 0 34px !important;
  border-radius: 50% !important;
  padding: 2px !important;
  overflow: visible !important;
  background: transparent !important;
  box-shadow: none !important;
  padding: 0 !important;
  transition: transform 0.22s ease;
}

.panel-topbar .ph-user:hover .ph-avatar-wrap,
.panel-topbar #itemdropdown1.show .ph-avatar-wrap {
  transform: scale(1.04);
}

.panel-topbar .ph-user img.ph-avatar,
.panel-topbar #itemdropdown1 a.nav-link.ph-user img.ph-avatar {
  width: 32px !important;
  height: 32px !important;
  max-width: 32px !important;
  margin: 0 !important;
  padding: 0 !important;
  border: 0 !important;
  border-radius: 50% !important;
  object-fit: cover !important;
  display: block !important;
  background: transparent;
}

.ph-user-initial {
  display: inline-flex !important;
  align-items: center;
  justify-content: center;
  flex-shrink: 0;
  border-radius: 50%;
  font-weight: 800;
  line-height: 1;
  letter-spacing: -0.04em;
  text-transform: uppercase;
  color: #fff !important;
  background: linear-gradient(180deg, #3b82f6 0%, #2563eb 100%);
  box-shadow: inset 0 1px 0 rgba(255, 255, 255, 0.22), 0 6px 14px rgba(37, 99, 235, 0.28);
  user-select: none;
}

.ph-user-initial--sm {
  width: 32px;
  height: 32px;
  font-size: 14px;
}

.ph-user-initial--md {
  width: 36px;
  height: 36px;
  font-size: 15px;
}

.ph-user-initial--lg {
  width: 44px;
  height: 44px;
  font-size: 18px;
}

.panel-topbar .ph-avatar-wrap .ph-user-initial {
  display: inline-flex !important;
  align-items: center !important;
  justify-content: center !important;
  width: 34px !important;
  height: 34px !important;
  margin: 0 !important;
  padding: 0 !important;
  border: 0 !important;
  flex: 0 0 auto;
  font-size: 13px !important;
  font-weight: 800 !important;
  line-height: 1 !important;
  text-align: center;
  color: #fff !important;
  border-radius: 50% !important;
  background: linear-gradient(145deg, #38bdf8 0%, #2563eb 100%) !important;
  box-shadow:
    0 0 0 2px #fff,
    0 0 0 4px rgba(37, 99, 235, 0.32),
    inset 0 1px 0 rgba(255, 255, 255, 0.28),
    0 5px 14px rgba(37, 99, 235, 0.28) !important;
  transition: box-shadow 0.22s ease, transform 0.22s ease;
}

.panel-topbar .ph-user:hover .ph-avatar-wrap .ph-user-initial,
.panel-topbar #itemdropdown1.show .ph-avatar-wrap .ph-user-initial {
  box-shadow:
    0 0 0 2px #fff,
    0 0 0 4px rgba(37, 99, 235, 0.42),
    inset 0 1px 0 rgba(255, 255, 255, 0.32),
    0 8px 18px rgba(37, 99, 235, 0.35) !important;
}

.panel-topbar .panel-brand-logo .logo-mini .ph-user-initial.psb-topbar-avatar {
  width: 32px !important;
  height: 32px !important;
  font-size: 14px !important;
}

.panel-topbar .panel-brand-logo .logo-mini img.ph-user-photo.psb-topbar-avatar {
  width: 32px !important;
  height: 32px !important;
  border-radius: 50% !important;
  object-fit: cover !important;
  display: block !important;
}

.panel-topbar .ph-avatar-wrap .ph-user-photo.ph-user-photo--sm {
  width: 34px !important;
  height: 34px !important;
  border-radius: 50% !important;
  object-fit: cover !important;
  display: block !important;
  box-shadow:
    0 0 0 2px #fff,
    0 0 0 4px rgba(37, 99, 235, 0.32),
    0 5px 14px rgba(37, 99, 235, 0.22);
}

.panel-topbar .ph-avatar-wrap .ph-user-icon {
  display: flex !important;
  align-items: center;
  justify-content: center;
  width: 100%;
  height: 100%;
  margin: 0;
  padding: 0;
  font-size: 14px;
  line-height: 1;
  color: #fff !important;
}

.panel-topbar .ph-avatar-wrap .ph-user-icon--sm {
  font-size: 13px;
}

.panel-topbar .ph-user--icon-only {
  gap: 7px !important;
  padding: 3px 10px 3px 3px !important;
}

.panel-topbar .ph-user--icon-only .ph-user__name {
  display: none !important;
}

.panel-topbar .ph-user__dot {
  position: absolute;
  top: -1px;
  right: -1px;
  width: 10px;
  height: 10px;
  border-radius: 50%;
  background: linear-gradient(180deg, #4ade80 0%, #22c55e 100%);
  border: 2px solid #fff;
  animation: ph-user-dot-glow 2.6s ease-in-out infinite;
  z-index: 2;
}

.panel-topbar .ph-user__name {
  display: none !important;
  font-size: 14px !important;
  font-weight: 700;
  color: #0f172a;
  letter-spacing: -0.02em;
  line-height: 1.1;
  max-width: 120px;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.panel-topbar .ph-user .ph-caret {
  flex-shrink: 0;
  width: 20px;
  height: 20px;
  padding: 3px;
  box-sizing: border-box;
  border-radius: 999px;
  color: #2563eb;
  margin: 0;
  opacity: 1;
  background: linear-gradient(180deg, rgba(37, 99, 235, 0.14) 0%, rgba(37, 99, 235, 0.06) 100%);
  box-shadow: inset 0 1px 0 rgba(255, 255, 255, 0.75);
  transition: transform 0.2s ease, color 0.2s ease, background 0.2s ease;
}

.panel-topbar .ph-user:hover .ph-caret,
.panel-topbar #itemdropdown1.show .ph-caret {
  color: #1d4ed8;
  background: linear-gradient(180deg, rgba(37, 99, 235, 0.22) 0%, rgba(37, 99, 235, 0.1) 100%);
}

.panel-topbar #itemdropdown1.show .ph-caret {
  transform: rotate(180deg);
}

.panel-topbar #currencyDropdown .balance-amount,
.panel-topbar #currencyDropdown .feather-dollar-sign,
.panel-topbar #currencyDropdown b,
.panel-topbar .ph-wallet .balance-amount,
.panel-topbar .ph-wallet b.balance-amount {
  color: #fff !important;
  -webkit-text-fill-color: #fff !important;
  text-shadow: 0 1px 2px rgba(0, 0, 0, 0.12) !important;
  font-size: 14px;
  font-weight: 700;
  line-height: 1 !important;
  margin: 0 !important;
  padding: 0 !important;
}

.panel-topbar #currencyDropdown .converted-balance,
.panel-topbar .ph-wallet .converted-balance {
  color: rgba(255, 255, 255, 0.92) !important;
  -webkit-text-fill-color: rgba(255, 255, 255, 0.92) !important;
  text-shadow: 0 1px 2px rgba(0, 0, 0, 0.1) !important;
}

/* Two-line wallet when display currency ≠ USD (same behavior as legacy header) */
.panel-topbar .ph-wallet-dd.has-converted-balance #currencyDropdown,
.panel-topbar .ph-wallet-dd.has-converted-balance .ph-wallet {
  min-height: 0 !important;
  height: auto !important;
  max-width: min(68vw, 248px) !important;
  padding-block: 8px !important;
  padding-inline: 14px 12px !important;
  gap: 5px !important;
}

.panel-topbar .ph-wallet-dd.has-converted-balance #currencyDropdown .converted-balance {
  display: block !important;
  margin-top: 1px;
  font-size: 10px !important;
  font-weight: 600 !important;
  line-height: 1.2 !important;
  letter-spacing: 0.01em;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
  max-width: 100%;
}

.panel-topbar .ph-wallet-dd:not(.has-converted-balance) #currencyDropdown .converted-balance {
  display: none !important;
}

.panel-topbar #currencyDropdown .feather-dollar-sign,
.panel-topbar #currencyDropdown .ph-wallet-ico {
  display: block !important;
  flex-shrink: 0;
}

.panel-topbar #itemdropdown1 .btn-icon,
.panel-topbar #itemdropdown1 .btn.btn-primary {
  display: none !important;
}

.panel-topbar #fullscreen-item,
.panel-topbar .header-user-quick,
.panel-topbar .ph-lang {
  display: none !important;
}

.panel-topbar .header-inbox-activity,
.panel-topbar .header-inbox-messages,
.panel-topbar .lbrt2 {
  display: flex !important;
  align-items: center;
  list-style: none;
  margin: 0 !important;
  padding: 0 !important;
}

.panel-topbar #cartSidebarBtn,
.panel-topbar #ActivityToggleBtn,
.panel-topbar #MessagesToggleBtn,
.panel-topbar .ph-action-btn {
  display: inline-flex !important;
  align-items: center;
  justify-content: center;
  width: 44px;
  height: 44px;
  min-width: 44px;
  min-height: 44px;
  padding: 0 !important;
  margin: 0 !important;
  border-radius: 14px !important;
  border: 1px solid rgba(15, 23, 42, 0.08) !important;
  background: #fff !important;
  color: #475569 !important;
  box-shadow:
    inset 0 1px 0 rgba(255, 255, 255, 0.95),
    0 2px 6px rgba(15, 23, 42, 0.05),
    0 8px 22px rgba(37, 99, 235, 0.11),
    0 14px 32px rgba(15, 23, 42, 0.08);
  transition: transform 0.15s ease, box-shadow 0.15s ease, border-color 0.15s ease;
}

.panel-topbar #cartSidebarBtn:hover,
.panel-topbar #ActivityToggleBtn:hover,
.panel-topbar #MessagesToggleBtn:hover,
.panel-topbar .ph-action-btn:hover {
  transform: translateY(-1px);
  border-color: rgba(37, 99, 235, 0.35) !important;
  box-shadow:
    inset 0 1px 0 rgba(255, 255, 255, 1),
    0 4px 12px rgba(37, 99, 235, 0.12),
    0 12px 28px rgba(37, 99, 235, 0.18),
    0 20px 40px rgba(15, 23, 42, 0.1);
  color: #1e40af !important;
}

.panel-topbar .lbrt-theme .theme-toggle-btn.theme-toggle-btn--compact {
  box-shadow:
    0 4px 12px rgba(15, 23, 42, 0.28),
    0 10px 26px rgba(37, 99, 235, 0.2) !important;
}

.panel-topbar .lbrt-theme .theme-toggle-btn.theme-toggle-btn--compact:hover {
  box-shadow:
    0 6px 16px rgba(15, 23, 42, 0.34),
    0 14px 32px rgba(37, 99, 235, 0.26) !important;
}

.panel-topbar #cartSidebarBtn i,
.panel-topbar #MessagesToggleBtn i,
.panel-topbar #ActivityToggleBtn i {
  font-size: 18px !important;
  line-height: 1;
}

.panel-topbar #cartSidebarBtn #cart-item-count,
.panel-topbar #MessagesToggleBtn .header-icon-badge,
.panel-topbar #ActivityToggleBtn .header-icon-badge,
.panel-topbar #MessagesToggleBtn #message-count {
  top: 4px !important;
  right: 4px !important;
  min-width: 16px;
  height: 16px;
  font-size: 9px !important;
  border: 2px solid #fff;
}

html.dark-mode .panel-topbar #cartSidebarBtn,
html.dark-mode .panel-topbar #ActivityToggleBtn,
html.dark-mode .panel-topbar #MessagesToggleBtn {
  background: #1e293b !important;
  border-color: rgba(255, 255, 255, 0.1) !important;
  color: #e2e8f0 !important;
  box-shadow:
    inset 0 1px 0 rgba(255, 255, 255, 0.05),
    0 4px 14px rgba(0, 0, 0, 0.45),
    0 12px 32px rgba(0, 0, 0, 0.35) !important;
}

html.dark-mode .panel-topbar #cartSidebarBtn:hover,
html.dark-mode .panel-topbar #ActivityToggleBtn:hover,
html.dark-mode .panel-topbar #MessagesToggleBtn:hover {
  box-shadow:
    inset 0 1px 0 rgba(255, 255, 255, 0.08),
    0 6px 18px rgba(96, 165, 250, 0.18),
    0 14px 36px rgba(0, 0, 0, 0.48) !important;
}

html.dark-mode .panel-topbar .lbrt-theme .theme-toggle-btn.theme-toggle-btn--compact {
  box-shadow:
    0 4px 14px rgba(0, 0, 0, 0.55),
    0 12px 28px rgba(96, 165, 250, 0.16) !important;
}

html.dark-mode .panel-topbar .lbrt-theme .theme-toggle-btn.theme-toggle-btn--compact:hover {
  box-shadow:
    0 6px 18px rgba(0, 0, 0, 0.6),
    0 16px 36px rgba(96, 165, 250, 0.22) !important;
}

.panel-topbar .lbrt-theme {
  display: flex !important;
  align-items: center !important;
  list-style: none;
  margin: 0 !important;
  padding: 0 !important;
}

.panel-topbar .ph-sd-theme {
  display: grid !important;
  place-items: center;
  width: 32px;
  height: 32px;
  min-width: 32px;
  min-height: 32px;
  padding: 0;
  margin: 0;
  border-radius: 10px;
  border: 1px solid rgba(15, 23, 42, 0.1);
  background: rgba(15, 23, 42, 0.03);
  color: #163a6b;
  cursor: pointer;
  font-size: 13px;
  line-height: 1;
}

html.dark-mode .panel-topbar .ph-sd-theme {
  border-color: rgba(255, 255, 255, 0.1);
  background: rgba(255, 255, 255, 0.03);
  color: #f1f3f8;
}

.panel-topbar .ph-sd-theme:hover {
  border-color: rgba(74, 222, 128, 0.45);
  color: #16a34a;
}

html.dark-mode .panel-topbar .ph-sd-theme:hover {
  color: #4ade80;
}

.panel-topbar .ph-sd-theme [data-ph-sun] { display: none; }
html:not(.dark-mode):not(.deep-blue) .panel-topbar .ph-sd-theme [data-ph-sun] { display: inline-block; }
html:not(.dark-mode):not(.deep-blue) .panel-topbar .ph-sd-theme [data-ph-moon] { display: none; }

.panel-topbar .header-menu-toggle-wrap {
  display: none !important;
}

@media (min-width: 1200px) {
  .panel-topbar .header-quick-actions,
  .panel-topbar #navbarSupportedContent.navbar-collapse,
  .panel-topbar #navbarSupportedContent .navbar-list {
    display: flex !important;
    align-items: center !important;
    gap: 10px !important;
    flex: 0 0 auto !important;
  }

  .panel-topbar .ph-ai {
    margin-left: 0 !important;
  }

  .panel-topbar #itemdropdown1 {
    display: flex !important;
  }
}

@media (max-width: 1199.98px) {
  .panel-topbar .navbar-inner {
    flex-wrap: nowrap !important;
    gap: 8px !important;
    padding: 8px 10px !important;
    min-height: 58px;
  }

  .panel-topbar .header-quick-actions {
    display: flex !important;
    align-items: center;
    gap: 6px;
    margin-left: auto !important;
    flex: 0 0 auto;
    overflow: visible !important;
  }

  .panel-topbar #navbarSupportedContent.navbar-collapse {
    display: flex !important;
    flex: 0 0 auto;
    width: auto !important;
    padding: 0 !important;
    background: transparent !important;
    border: 0 !important;
  }

  .panel-topbar #navbarSupportedContent .navbar-list {
    display: flex !important;
    align-items: center;
    gap: 6px;
    margin: 0 !important;
  }

  .panel-topbar .ph-ai,
  .panel-topbar a.ph-ai {
    display: none !important;
  }

  .panel-topbar .ph-title {
    min-width: 0 !important;
    max-width: 100%;
    overflow: hidden;
  }

  .panel-topbar .ph-title small,
  .panel-topbar .ph-title h1,
  .panel-topbar .ph-title h2,
  .panel-topbar .ph-title h3 {
    font-size: 16px !important;
    white-space: nowrap !important;
    overflow: hidden;
    text-overflow: ellipsis;
  }

  .panel-topbar #itemdropdown1 {
    display: flex !important;
  }

  .panel-topbar .ph-user__name {
    max-width: 88px;
    overflow: hidden;
    text-overflow: ellipsis;
    white-space: nowrap;
  }

  .panel-topbar .header-quick-actions #currencyDropdown,
  .panel-topbar .ph-wallet {
    max-width: min(52vw, 188px) !important;
    height: auto !important;
    min-height: 0 !important;
    padding-block: 7px !important;
    padding-inline: 10px 8px !important;
    gap: 3px !important;
  }

  .panel-topbar #currencyDropdown .ph-wallet-ico,
  .panel-topbar .ph-wallet .ph-wallet-ico {
    width: 18px !important;
    height: 18px !important;
  }

  .panel-topbar #currencyDropdown .balance-amount,
  .panel-topbar .ph-wallet b.balance-amount {
    font-size: 14px !important;
  }

  .panel-topbar #cartSidebarBtn,
  .panel-topbar #ActivityToggleBtn,
  .panel-topbar #MessagesToggleBtn {
    width: 38px !important;
    height: 38px !important;
    min-width: 38px !important;
    min-height: 38px !important;
    border-radius: 12px !important;
  }

  .panel-topbar #cartSidebarBtn i,
  .panel-topbar #MessagesToggleBtn i,
  .panel-topbar #ActivityToggleBtn i {
    font-size: 16px !important;
  }

  .panel-topbar .ph-user.ph-user--icon-only,
  .panel-topbar #itemdropdown1 a.nav-link.ph-user.ph-user--icon-only {
    width: auto !important;
    min-width: 0 !important;
    max-width: none !important;
    height: auto !important;
    min-height: 0 !important;
    padding: 0 !important;
    background: transparent !important;
    box-shadow: none !important;
  }

  .panel-topbar .ph-user:not(.ph-user--icon-only),
  .panel-topbar #itemdropdown1 a.nav-link.ph-user:not(.ph-user--icon-only) {
    width: auto !important;
    min-width: 0 !important;
    max-width: none !important;
    height: auto !important;
    min-height: 0 !important;
    padding: 0 !important;
    background: transparent !important;
    box-shadow: none !important;
  }

  .panel-topbar .ph-avatar-wrap,
  .panel-topbar #itemdropdown1 .ph-avatar-wrap {
    width: 32px !important;
    height: 32px !important;
    flex: 0 0 32px !important;
  }

  .panel-topbar .ph-user img.ph-avatar,
  .panel-topbar #itemdropdown1 a.nav-link.ph-user img.ph-avatar {
    width: 30px !important;
    height: 30px !important;
    max-width: 30px !important;
  }

  .panel-topbar .sidebar-toggle {
    width: 34px !important;
    height: 34px !important;
    min-width: 34px !important;
    min-height: 34px !important;
  }

  .panel-topbar .ph-wallet-dd.has-converted-balance #currencyDropdown,
  .panel-topbar .ph-wallet-dd.has-converted-balance .ph-wallet {
    max-width: min(68vw, 248px) !important;
    min-height: 0 !important;
    height: auto !important;
    padding-block: 7px !important;
    padding-inline: 10px 8px !important;
  }

  .panel-topbar .ph-wallet-dd.has-converted-balance #currencyDropdown .converted-balance {
    display: block !important;
    font-size: 9px !important;
  }

  .panel-topbar .ph-wallet-dd:not(.has-converted-balance) #currencyDropdown .converted-balance {
    display: none !important;
  }
}

html.dark-mode .panel-topbar.iq-navbar,
html.dark-mode .panel-topbar.navbar.iq-navbar {
  background: #13151c !important;
  background-color: #13151c !important;
  border-bottom-color: rgba(255, 255, 255, 0.08) !important;
}

html.dark-mode .panel-topbar .ph-title,
html.dark-mode .panel-topbar .ph-title small,
html.dark-mode .panel-topbar .ph-title h1,
html.dark-mode .panel-topbar .ph-title h2,
html.dark-mode .panel-topbar .ph-title h3 {
  color: #f1f3f8 !important;
  -webkit-text-fill-color: #f1f3f8 !important;
}

html.dark-mode .panel-topbar .sidebar-toggle,
html.dark-mode .panel-topbar .iq-navbar .sidebar-toggle {
  background: #1d4ed8 !important;
  color: #fff !important;
  box-shadow: 0 8px 18px rgba(0, 0, 0, 0.35) !important;
}

html.dark-mode .panel-topbar .sidebar-toggle svg,
html.dark-mode .panel-topbar .sidebar-toggle .icon {
  color: #fff !important;
}

html.dark-mode .panel-topbar .ph-ai {
  background:
    linear-gradient(#1a1d27, #1a1d27) padding-box,
    linear-gradient(90deg, #4ade80, #16a34a, #86efac) border-box;
  color: #8b93a7 !important;
  box-shadow: 0 8px 20px rgba(0, 0, 0, 0.28);
}

html.dark-mode .panel-topbar .ph-ai__badge {
  background: rgba(22, 163, 74, 0.22);
  color: #86efac;
}

html.dark-mode .panel-topbar #currencyDropdown,
html.dark-mode .panel-topbar .ph-wallet {
  background: linear-gradient(135deg, #10b981 0%, #059669 100%) !important;
  background-image: linear-gradient(135deg, #10b981 0%, #059669 100%) !important;
  color: #fff !important;
  box-shadow: 0 4px 15px rgba(16, 185, 129, 0.35) !important;
}

html.dark-mode .panel-topbar #currencyDropdown:hover,
html.dark-mode .panel-topbar .ph-wallet:hover {
  box-shadow: 0 6px 20px rgba(16, 185, 129, 0.42) !important;
}

html.dark-mode .panel-topbar #currencyDropdown .balance-amount,
html.dark-mode .panel-topbar #currencyDropdown b {
  color: #fff !important;
  -webkit-text-fill-color: #fff !important;
}

html.dark-mode .panel-topbar #currencyDropdown .ph-wallet-ico,
html.dark-mode .panel-topbar .ph-wallet .ph-wallet-ico,
html.dark-mode .panel-topbar #currencyDropdown .feather-dollar-sign {
  color: #fff !important;
  stroke: #fff;
}

html.dark-mode .panel-topbar .ph-wallet-dd.has-converted-balance #currencyDropdown .converted-balance {
  color: rgba(255, 255, 255, 0.9) !important;
  -webkit-text-fill-color: rgba(255, 255, 255, 0.9) !important;
}

html.dark-mode .panel-topbar .ph-user,
html.dark-mode .panel-topbar #itemdropdown1 a.nav-link.ph-user,
html.dark-mode:not(.deep-blue) .panel-topbar .ph-user {
  background: linear-gradient(180deg, #1e293b 0%, #172033 100%) !important;
  box-shadow:
    0 1px 0 rgba(255, 255, 255, 0.06) inset,
    0 0 0 1px rgba(255, 255, 255, 0.08),
    0 8px 20px rgba(0, 0, 0, 0.35) !important;
}

html.dark-mode .panel-topbar .ph-user:hover,
html.dark-mode .panel-topbar #itemdropdown1.show .ph-user,
html.dark-mode .panel-topbar #itemdropdown1.show a.nav-link.ph-user {
  background: linear-gradient(180deg, #243044 0%, #1a2332 100%) !important;
  box-shadow:
    0 0 0 1px rgba(96, 165, 250, 0.35),
    0 10px 24px rgba(0, 0, 0, 0.4) !important;
}

html.dark-mode .panel-topbar .ph-user__name {
  color: #f1f5f9;
}

html.dark-mode .panel-topbar .ph-user__dot {
  border-color: #1e293b;
}

html.dark-mode .panel-topbar .ph-user .ph-caret {
  color: #93c5fd;
  background: linear-gradient(180deg, rgba(96, 165, 250, 0.2) 0%, rgba(96, 165, 250, 0.08) 100%);
  box-shadow: inset 0 1px 0 rgba(255, 255, 255, 0.08);
}

html.dark-mode .panel-topbar .ph-user:hover .ph-caret,
html.dark-mode .panel-topbar #itemdropdown1.show .ph-caret {
  color: #bfdbfe;
  background: linear-gradient(180deg, rgba(96, 165, 250, 0.32) 0%, rgba(96, 165, 250, 0.14) 100%);
}

.panel-topbar .dropdown,
.panel-topbar .nav-item.dropdown,
.panel-topbar #itemdropdown1,
.panel-topbar [data-ot="balance"] {
  position: relative;
  overflow: visible !important;
}

.panel-topbar .ph-pop.dropdown-menu,
.panel-topbar .dropdown-menu.ph-pop {
  --ph-pop-bg: #fff;
  --ph-pop-text: #0f172a;
  --ph-pop-muted: #64748b;
  --ph-pop-line: #eef2f7;
  --ph-pop-hover: #f4f7fc;
  display: none;
  position: absolute !important;
  min-width: 240px;
  margin-top: 8px !important;
  padding: 14px 12px !important;
  border: 0 !important;
  border-radius: 22px !important;
  background: var(--ph-pop-bg) !important;
  background-image: none !important;
  box-shadow:
    0 0 0 1px rgba(15, 23, 42, 0.04),
    0 24px 60px rgba(15, 23, 42, 0.16) !important;
  overflow: visible;
  z-index: 1080 !important;
}

.panel-topbar .ph-pop.dropdown-menu.show,
.panel-topbar .dropdown-menu.ph-pop.show {
  display: block !important;
  animation: phPopIn 0.22s cubic-bezier(0.16, 1, 0.3, 1);
}

@keyframes phPopIn {
  from {
    opacity: 0;
    transform: translateY(10px) scale(0.96);
  }
  to {
    opacity: 1;
    transform: translateY(0) scale(1);
  }
}

.panel-topbar .ph-pop--user {
  top: calc(100% + 10px) !important;
  right: 0 !important;
  left: auto !important;
  width: 292px;
  min-width: 292px;
  max-width: min(292px, calc(100vw - 20px));
  padding: 8px !important;
  border-radius: 20px !important;
  --ph-pop-bg: #ffffff;
  --ph-pop-text: #0f172a;
  --ph-pop-muted: #64748b;
  --ph-pop-hover: #eff6ff;
  background: #ffffff !important;
  background-color: #ffffff !important;
  color: #0f172a !important;
  opacity: 1 !important;
  isolation: isolate;
  backdrop-filter: none !important;
  -webkit-backdrop-filter: none !important;
  overflow: hidden !important;
  transform: none !important;
  border: 1px solid rgba(37, 99, 235, 0.14) !important;
  box-shadow:
    0 0 0 1px rgba(255, 255, 255, 0.8) inset,
    0 20px 50px rgba(15, 23, 42, 0.14),
    0 8px 24px rgba(37, 99, 235, 0.1) !important;
}

.panel-topbar .ph-pop--user.show {
  display: block !important;
  opacity: 1 !important;
}

.panel-topbar .ph-pop--user::before,
.panel-topbar .ph-pop--user::after {
  display: none !important;
}

html.dark-mode .panel-topbar .ph-pop--user {
  --ph-pop-bg: #1a1f2e;
  --ph-pop-text: #f1f5f9;
  --ph-pop-muted: #94a3b8;
  --ph-pop-hover: rgba(37, 99, 235, 0.14);
  background: linear-gradient(165deg, #1e2433 0%, #151922 100%) !important;
  background-color: #151922 !important;
  color: #f1f5f9 !important;
  opacity: 1 !important;
  border-color: rgba(96, 165, 250, 0.18) !important;
  box-shadow:
    0 0 0 1px rgba(255, 255, 255, 0.05) inset,
    0 24px 56px rgba(0, 0, 0, 0.55),
    0 8px 20px rgba(37, 99, 235, 0.12) !important;
}

.panel-topbar .ph-wallet-dd,
.panel-topbar [data-ot="balance"] {
  position: relative !important;
  display: flex !important;
  align-items: center;
  overflow: visible !important;
  flex: 0 0 auto !important;
}

.header-currency-menu.ph-pop--wallet {
  max-height: min(72vh, 440px);
  overflow-x: hidden !important;
  overflow-y: auto !important;
  padding: 10px !important;
  border-radius: 22px !important;
  --ph-pop-bg: #ffffff;
  --ph-pop-text: #0f172a;
  --ph-pop-muted: #64748b;
  --ph-pop-hover: #f0fdf4;
  --ph-wallet-accent: #16a34a;
  background: linear-gradient(180deg, #ffffff 0%, #f8fafc 100%) !important;
  background-color: #fff !important;
  border: 1px solid rgba(22, 163, 74, 0.14) !important;
  box-shadow:
    0 0 0 1px rgba(255, 255, 255, 0.85) inset,
    0 4px 6px rgba(15, 23, 42, 0.04),
    0 22px 56px rgba(15, 23, 42, 0.14),
    0 8px 24px rgba(22, 163, 74, 0.1) !important;
  transform: none !important;
  box-sizing: border-box !important;
}

.panel-topbar .ph-pop--wallet {
  position: absolute !important;
  top: calc(100% + 10px) !important;
  right: 0 !important;
  left: auto !important;
  bottom: auto !important;
  width: min(320px, calc(100vw - 24px)) !important;
  min-width: 280px !important;
  max-width: min(320px, calc(100vw - 24px)) !important;
}

.header-currency-menu.ph-pop--wallet.show,
.panel-topbar .ph-pop--wallet.show {
  display: block !important;
}

.header-currency-menu.ph-pop--wallet::before,
.header-currency-menu.ph-pop--wallet::after,
.panel-topbar .ph-pop--wallet::before,
.panel-topbar .ph-pop--wallet::after {
  display: none !important;
}

html.dark-mode .header-currency-menu.ph-pop--wallet,
html.dark-mode .panel-topbar .ph-pop--wallet {
  --ph-pop-bg: #ffffff;
  --ph-pop-text: #111827;
  --ph-pop-muted: #8b95a5;
  --ph-pop-hover: #f3f6fb;
  box-shadow:
    0 0 0 1px rgba(15, 23, 42, 0.04),
    0 24px 60px rgba(15, 23, 42, 0.18) !important;
}

.header-currency-menu.ph-pop--wallet::-webkit-scrollbar,
.panel-topbar .ph-pop--wallet::-webkit-scrollbar {
  width: 8px;
}

.header-currency-menu.ph-pop--wallet::-webkit-scrollbar-track,
.panel-topbar .ph-pop--wallet::-webkit-scrollbar-track {
  background: transparent;
  margin: 12px 0;
}

.header-currency-menu.ph-pop--wallet::-webkit-scrollbar-thumb,
.panel-topbar .ph-pop--wallet::-webkit-scrollbar-thumb {
  background: linear-gradient(180deg, #4ade80 0%, #16a34a 100%);
  border-radius: 999px;
}

.header-currency-menu.ph-pop--wallet .ph-pop__label,
.panel-topbar .ph-pop--wallet .ph-pop__label {
  display: flex;
  align-items: center;
  gap: 8px;
  padding: 4px 10px 8px;
  margin: 0 0 4px;
  font-size: 10px;
  font-weight: 800;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  color: #64748b;
}

.header-currency-menu.ph-pop--wallet .ph-pop__label::before,
.header-currency-menu.ph-pop--wallet .ph-pop__label::after,
.panel-topbar .ph-pop--wallet .ph-pop__label::before,
.panel-topbar .ph-pop--wallet .ph-pop__label::after {
  content: "";
  flex: 1 1 auto;
  height: 1px;
  background: linear-gradient(90deg, transparent, rgba(22, 163, 74, 0.22), transparent);
}

.header-currency-menu.ph-pop--wallet .ph-pop__ccy-item,
.panel-topbar .ph-pop--wallet .ph-pop__ccy-item {
  list-style: none;
  margin: 0 0 4px;
  padding: 0;
}

.panel-topbar .ph-pop li {
  list-style: none;
  margin: 0;
  padding: 0;
}

.panel-topbar .ph-pop--user .ph-pop__identity {
  padding: 12px 12px 14px;
  margin: 0 0 6px;
  border: none;
  background: linear-gradient(135deg, rgba(37, 99, 235, 0.1) 0%, rgba(99, 102, 241, 0.06) 52%, rgba(248, 250, 252, 0.4) 100%);
  border-radius: 14px;
  position: relative;
  overflow: hidden;
}

.panel-topbar .ph-pop--user .ph-pop__identity::after {
  content: "";
  position: absolute;
  top: -20px;
  right: -20px;
  width: 100px;
  height: 100px;
  background: radial-gradient(circle, rgba(59, 130, 246, 0.22) 0%, transparent 68%);
  pointer-events: none;
}

html.dark-mode .panel-topbar .ph-pop--user .ph-pop__identity {
  background: linear-gradient(135deg, rgba(37, 99, 235, 0.2) 0%, rgba(30, 41, 59, 0.85) 100%);
}

.panel-topbar .ph-pop__identity-row {
  display: flex;
  align-items: center;
  gap: 12px;
  min-width: 0;
  position: relative;
  z-index: 1;
}

.panel-topbar .ph-pop__avatar {
  position: relative;
  flex: 0 0 auto;
  width: 44px;
  height: 44px;
  line-height: 0;
}

.panel-topbar .ph-pop__avatar-img {
  width: 44px !important;
  height: 44px !important;
  border-radius: 50%;
  object-fit: cover;
  display: block;
  box-shadow:
    0 0 0 3px #fff,
    0 0 0 5px rgba(37, 99, 235, 0.35);
}

.panel-topbar .ph-pop__avatar-initial.ph-user-initial--md {
  width: 44px !important;
  height: 44px !important;
  font-size: 16px !important;
  box-shadow:
    0 0 0 3px #fff,
    0 0 0 5px rgba(37, 99, 235, 0.32),
    inset 0 1px 0 rgba(255, 255, 255, 0.25);
}

.panel-topbar .ph-pop__avatar-dot {
  position: absolute;
  bottom: 1px;
  right: 1px;
  width: 10px;
  height: 10px;
  border-radius: 50%;
  background: #22c55e;
  border: 2px solid #fff;
  box-shadow: 0 0 0 1px rgba(15, 23, 42, 0.08);
}

.panel-topbar .ph-pop__identity-text {
  flex: 1 1 auto;
  min-width: 0;
}

.panel-topbar .ph-pop__name {
  display: inline-flex;
  align-items: center;
  gap: 4px;
  max-width: 100%;
  font-size: 14px;
  font-weight: 700;
  color: #0f172a !important;
  letter-spacing: -0.02em;
  line-height: 1.25;
}

.panel-topbar .ph-pop__name-text {
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
  min-width: 0;
}

.panel-blue-verified-tick {
  flex-shrink: 0;
  font-size: 12px;
  color: rgb(79, 151, 245);
  line-height: 1;
  vertical-align: middle;
}

.panel-2fa-lock {
  flex-shrink: 0;
  font-size: 11px;
  color: #16a34a;
  line-height: 1;
  vertical-align: middle;
}

html.dark-mode .panel-topbar .ph-pop--user .ph-pop__name,
html.dark-mode .panel-topbar .ph-pop--user .ph-pop__theme-label {
  color: #f1f5f9 !important;
}

.panel-topbar .ph-pop__email {
  margin-top: 3px;
  margin-bottom: 0;
  font-size: 11px;
  font-weight: 500;
  color: var(--ph-pop-muted);
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
  line-height: 1.35;
}

.panel-topbar .ph-pop--user .ph-pop__nav {
  margin: 0;
  padding: 0;
}

.panel-topbar .ph-pop--user .ph-pop__sep {
  height: 1px;
  margin: 6px 8px;
  background: linear-gradient(90deg, transparent, rgba(30, 64, 175, 0.14), transparent);
  list-style: none;
}

html.dark-mode .panel-topbar .ph-pop--user .ph-pop__sep {
  background: linear-gradient(90deg, transparent, rgba(148, 163, 184, 0.28), transparent);
}

.panel-topbar .ph-pop--user .ph-pop__logout-form {
  margin: 0;
  padding: 0;
}

html body .panel-topbar .ph-pop--user .ph-pop__account,
html.dark-mode body .panel-topbar .ph-pop--user .ph-pop__account {
  display: none !important;
}

html body .panel-topbar .ph-pop--user .ph-pop__account:hover {
  color: #fff !important;
}

.panel-topbar .ph-pop__theme {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 10px;
  min-height: 34px;
  padding: 4px 8px;
}

.panel-topbar .ph-pop__theme-label {
  font-size: 13px;
  font-weight: 600;
  color: #111827 !important;
}

.panel-topbar .ph-theme-switch {
  width: 36px;
  height: 20px;
  padding: 0;
  border: 0;
  border-radius: 999px;
  background: #e2e8f0;
  position: relative;
  cursor: pointer;
  flex-shrink: 0;
}

.panel-topbar .ph-theme-switch__knob {
  position: absolute;
  top: 2px;
  left: 2px;
  width: 16px;
  height: 16px;
  border-radius: 50%;
  background: #cbd5e1;
  color: #64748b;
  display: flex;
  align-items: center;
  justify-content: center;
  transition: transform 0.22s cubic-bezier(0.16, 1, 0.3, 1), background 0.22s ease, color 0.22s ease;
  box-shadow: 0 1px 3px rgba(15, 23, 42, 0.16);
}

.panel-topbar .ph-theme-switch__knob svg {
  width: 10px;
  height: 10px;
}

html.dark-mode .panel-topbar .ph-theme-switch {
  background: #334155;
}

html.dark-mode .panel-topbar .ph-theme-switch__knob {
  transform: translateX(16px);
  background: #16a34a;
  color: #dcfce7;
}

.panel-topbar .ph-pop__link {
  display: flex !important;
  align-items: center;
  gap: 10px;
  width: 100%;
  min-height: 42px;
  padding: 8px 10px;
  border: 0;
  border-radius: 12px;
  background: transparent;
  color: var(--ph-pop-text) !important;
  font-size: 13px;
  font-weight: 600;
  text-align: start;
  text-decoration: none !important;
  transition: background 0.16s ease, color 0.16s ease, transform 0.16s ease;
  cursor: pointer;
}

.panel-topbar .ph-pop--user .ph-pop__label-text {
  flex: 1 1 auto;
  min-width: 0;
  letter-spacing: -0.01em;
}

.panel-topbar .ph-pop--user .ph-pop__chev {
  width: 14px;
  height: 14px;
  flex-shrink: 0;
  color: #cbd5e1;
  opacity: 0;
  transform: translateX(-4px);
  transition: opacity 0.16s ease, transform 0.16s ease, color 0.16s ease;
}

.panel-topbar .ph-pop--user .ph-pop__ico {
  width: 34px;
  height: 34px;
  flex-shrink: 0;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  border-radius: 10px;
  background: rgba(37, 99, 235, 0.08);
  color: #2563eb;
  transition: background 0.16s ease, color 0.16s ease, box-shadow 0.16s ease;
}

.panel-topbar .ph-pop--user .ph-pop__ico svg {
  width: 17px;
  height: 17px;
}

.panel-topbar .ph-pop--user .ph-pop__ico--affiliate {
  background: rgba(99, 102, 241, 0.1);
  color: #4f46e5;
}

.panel-topbar .ph-pop__link svg {
  width: 15px;
  height: 15px;
  color: inherit;
  flex-shrink: 0;
}

.panel-topbar .ph-pop--user .ph-pop__link:hover {
  background: var(--ph-pop-hover) !important;
  color: #1d4ed8 !important;
}

.panel-topbar .ph-pop--user .ph-pop__link:hover .ph-pop__ico {
  background: linear-gradient(145deg, #3b82f6 0%, #2563eb 100%);
  color: #fff !important;
  box-shadow: 0 4px 12px rgba(37, 99, 235, 0.28);
}

.panel-topbar .ph-pop--user .ph-pop__link:hover .ph-pop__chev {
  opacity: 1;
  transform: translateX(0);
  color: #60a5fa;
}

.panel-topbar .ph-pop__link--logout {
  color: #dc2626 !important;
}

.panel-topbar .ph-pop--user .ph-pop__ico--logout {
  background: rgba(239, 68, 68, 0.1);
  color: #dc2626;
}

.panel-topbar .ph-pop__link--logout:hover {
  background: rgba(254, 226, 226, 0.85) !important;
  color: #b91c1c !important;
}

.panel-topbar .ph-pop--user .ph-pop__link--logout:hover .ph-pop__ico--logout {
  background: linear-gradient(145deg, #ef4444 0%, #dc2626 100%);
  color: #fff !important;
  box-shadow: 0 4px 12px rgba(220, 38, 38, 0.25);
}

html.dark-mode .panel-topbar .ph-pop--user .ph-pop__link:hover {
  color: #93c5fd !important;
}

html.dark-mode .panel-topbar .ph-pop__avatar-img,
html.dark-mode .panel-topbar .ph-pop__avatar-initial.ph-user-initial--md {
  box-shadow:
    0 0 0 3px #151922,
    0 0 0 5px rgba(96, 165, 250, 0.45);
}

html.dark-mode .panel-topbar .ph-pop__avatar-dot {
  border-color: #151922;
}

html.dark-mode .panel-topbar .ph-pop--user .ph-pop__ico {
  background: rgba(59, 130, 246, 0.15);
  color: #93c5fd;
}

html.dark-mode .panel-topbar .ph-pop--user .ph-pop__ico--affiliate {
  background: rgba(129, 140, 248, 0.16);
  color: #a5b4fc;
}

html.dark-mode .panel-topbar .ph-pop__link--logout:hover {
  background: rgba(127, 29, 29, 0.35) !important;
  color: #fca5a5 !important;
}

.header-currency-menu.ph-pop--wallet .ph-pop__add,
.panel-topbar .ph-pop--wallet .ph-pop__add {
  display: flex !important;
  align-items: center;
  justify-content: center;
  gap: 10px;
  width: calc(100% - 4px);
  margin: 2px 2px 10px;
  min-height: 44px;
  padding: 10px 14px !important;
  border-radius: 14px !important;
  color: #fff !important;
  font-size: 14px;
  font-weight: 800;
  letter-spacing: 0.01em;
  text-decoration: none !important;
  background: linear-gradient(135deg, #22c55e 0%, #16a34a 52%, #059669 100%) !important;
  box-shadow:
    inset 0 1px 0 rgba(255, 255, 255, 0.22),
    0 6px 18px rgba(22, 163, 74, 0.32) !important;
  transition: transform 0.18s ease, box-shadow 0.18s ease, filter 0.18s ease;
}

.header-currency-menu.ph-pop--wallet .ph-pop__add:hover,
.panel-topbar .ph-pop--wallet .ph-pop__add:hover {
  transform: translateY(-1px);
  filter: brightness(1.05);
  color: #fff !important;
  box-shadow:
    inset 0 1px 0 rgba(255, 255, 255, 0.28),
    0 10px 24px rgba(22, 163, 74, 0.38) !important;
}

.header-currency-menu.ph-pop--wallet .ph-pop__plus,
.panel-topbar .ph-pop--wallet .ph-pop__plus {
  width: 24px;
  height: 24px;
  border-radius: 8px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  background: rgba(255, 255, 255, 0.22);
  color: #fff;
  font-size: 17px;
  font-weight: 800;
  line-height: 1;
  border: 1px solid rgba(255, 255, 255, 0.28);
}

.header-currency-menu.ph-pop--wallet .ph-pop__ccy,
.header-currency-menu.ph-pop--wallet .dropdown-item,
.panel-topbar .ph-pop--wallet .ph-pop__ccy,
.panel-topbar .ph-pop--wallet .dropdown-item {
  display: grid !important;
  grid-template-columns: 42px 54px minmax(0, 1fr) 22px;
  column-gap: 8px;
  align-items: center;
  width: 100%;
  min-height: 46px;
  padding: 6px 8px 6px 6px !important;
  border: 1px solid transparent !important;
  border-radius: 14px !important;
  background: rgba(255, 255, 255, 0.72) !important;
  color: #0f172a !important;
  font-size: 14px;
  font-weight: 700;
  text-decoration: none !important;
  visibility: visible !important;
  opacity: 1 !important;
  transition: transform 0.16s ease, box-shadow 0.16s ease, border-color 0.16s ease, background 0.16s ease;
}

.header-currency-menu.ph-pop--wallet .ph-pop__ccy:hover,
.header-currency-menu.ph-pop--wallet .dropdown-item:hover,
.panel-topbar .ph-pop--wallet .ph-pop__ccy:hover,
.panel-topbar .ph-pop--wallet .dropdown-item:hover {
  background: #f0fdf4 !important;
  border-color: rgba(22, 163, 74, 0.16) !important;
  color: #0f172a !important;
  transform: translateX(2px);
  box-shadow: 0 4px 14px rgba(15, 23, 42, 0.06);
}

.header-currency-menu.ph-pop--wallet .ph-pop__ccy.active,
.header-currency-menu.ph-pop--wallet .dropdown-item.active,
.panel-topbar .ph-pop--wallet .ph-pop__ccy.active,
.panel-topbar .ph-pop--wallet .dropdown-item.active {
  background: linear-gradient(90deg, rgba(22, 163, 74, 0.14) 0%, rgba(220, 252, 231, 0.95) 100%) !important;
  border-color: rgba(22, 163, 74, 0.28) !important;
  color: #14532d !important;
  box-shadow:
    inset 3px 0 0 #16a34a,
    0 4px 16px rgba(22, 163, 74, 0.12) !important;
}

.header-currency-menu.ph-pop--wallet .ph-pop__sym,
.panel-topbar .ph-pop--wallet .ph-pop__sym {
  display: inline-flex !important;
  align-items: center;
  justify-content: center;
  min-width: 38px !important;
  height: 38px !important;
  padding: 0 4px;
  border-radius: 11px;
  background: linear-gradient(180deg, #f0fdf4 0%, #ecfdf5 100%) !important;
  border: 1px solid rgba(22, 163, 74, 0.14);
  color: #15803d !important;
  font-weight: 800;
  font-size: 13px;
  line-height: 1;
  text-align: center;
}

.header-currency-menu.ph-pop--wallet .ph-pop__ccy.active .ph-pop__sym,
.panel-topbar .ph-pop--wallet .ph-pop__ccy.active .ph-pop__sym {
  background: linear-gradient(180deg, #22c55e 0%, #16a34a 100%) !important;
  border-color: rgba(255, 255, 255, 0.35);
  color: #fff !important;
  box-shadow: 0 4px 12px rgba(22, 163, 74, 0.28);
}

.header-currency-menu.ph-pop--wallet .ph-pop__code,
.panel-topbar .ph-pop--wallet .ph-pop__code {
  font-weight: 800;
  letter-spacing: 0.04em;
  font-size: 12px;
  color: #0f172a !important;
}

.header-currency-menu.ph-pop--wallet .ph-pop__ccy.active .ph-pop__code,
.panel-topbar .ph-pop--wallet .ph-pop__ccy.active .ph-pop__code {
  color: #14532d !important;
}

.header-currency-menu.ph-pop--wallet .ph-pop__cname,
.panel-topbar .ph-pop--wallet .ph-pop__cname {
  margin-left: 0;
  font-size: 11px;
  font-weight: 600;
  color: #64748b !important;
  max-width: 100%;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
  line-height: 1.25;
}

.header-currency-menu.ph-pop--wallet .ph-pop__ccy.active .ph-pop__cname,
.panel-topbar .ph-pop--wallet .ph-pop__ccy.active .ph-pop__cname {
  color: #166534 !important;
}

.header-currency-menu.ph-pop--wallet .ph-pop__ccy-mark,
.panel-topbar .ph-pop--wallet .ph-pop__ccy-mark {
  width: 20px;
  height: 20px;
  border-radius: 50%;
  border: 2px solid #cbd5e1;
  justify-self: end;
  transition: background 0.16s ease, border-color 0.16s ease, box-shadow 0.16s ease;
}

.header-currency-menu.ph-pop--wallet .ph-pop__ccy.active .ph-pop__ccy-mark,
.panel-topbar .ph-pop--wallet .ph-pop__ccy.active .ph-pop__ccy-mark {
  border-color: #16a34a;
  background-color: #16a34a;
  box-shadow: 0 0 0 3px rgba(34, 197, 94, 0.22);
  background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 16 16' fill='none'%3E%3Cpath d='M3.5 8.2L6.4 11.1L12.5 4.9' stroke='white' stroke-width='2.2' stroke-linecap='round' stroke-linejoin='round'/%3E%3C/svg%3E");
  background-repeat: no-repeat;
  background-position: center;
  background-size: 11px 11px;
}

/* Beat HopeUI / Bootstrap blue .dropdown-item.active inside wallet menu */
.header-currency-menu.ph-pop--wallet a.dropdown-item.active,
.header-currency-menu.ph-pop--wallet a.dropdown-item.active:hover,
.header-currency-menu.ph-pop--wallet a.dropdown-item.active:focus,
.panel-topbar .ph-pop--wallet a.dropdown-item.active,
.panel-topbar .ph-pop--wallet a.dropdown-item.active:hover,
.panel-topbar .ph-pop--wallet a.dropdown-item.active:focus {
  background: linear-gradient(90deg, rgba(22, 163, 74, 0.14) 0%, rgba(220, 252, 231, 0.95) 100%) !important;
  color: #14532d !important;
}

.panel-topbar .ph-pop__sym {
  min-width: 28px;
  color: #334155;
  font-weight: 800;
}

.panel-topbar .ph-pop__code {
  font-weight: 800;
  letter-spacing: 0.02em;
}

.panel-topbar .ph-pop__cname {
  margin-left: auto;
  font-size: 12px;
  font-weight: 600;
  color: #8b95a5;
  max-width: 46%;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.panel-topbar .ph-pop__dash {
  color: #94a3b8;
  font-weight: 600;
}

html.dark-mode .panel-topbar .ph-pop.dropdown-menu:not(.ph-pop--wallet):not(.ph-pop--user),
html.dark-mode .panel-topbar .dropdown-menu.ph-pop:not(.ph-pop--wallet):not(.ph-pop--user) {
  --ph-pop-bg: #171b24;
  --ph-pop-text: #f1f5f9;
  --ph-pop-muted: #94a3b8;
  --ph-pop-line: rgba(255, 255, 255, 0.08);
  --ph-pop-hover: rgba(255, 255, 255, 0.06);
  box-shadow:
    0 0 0 1px rgba(255, 255, 255, 0.06),
    0 28px 64px rgba(0, 0, 0, 0.45) !important;
}

html.dark-mode .panel-topbar .ph-pop:not(.ph-pop--wallet) .ph-pop__add,
html.dark-mode .panel-topbar .ph-pop:not(.ph-pop--wallet) .ph-pop__ccy {
  color: #f1f5f9 !important;
}

html.dark-mode .header-currency-menu.ph-pop--wallet .ph-pop__add,
html.dark-mode .header-currency-menu.ph-pop--wallet .ph-pop__ccy,
html.dark-mode .header-currency-menu.ph-pop--wallet .dropdown-item,
html.dark-mode .panel-topbar .ph-pop--wallet .ph-pop__add,
html.dark-mode .panel-topbar .ph-pop--wallet .ph-pop__ccy,
html.dark-mode .panel-topbar .ph-pop--wallet .dropdown-item {
  color: #111827 !important;
}

html.dark-mode .panel-topbar .ph-pop__plus,
html.dark-mode .header-currency-menu.ph-pop--wallet .ph-pop__plus {
  background: rgba(255, 255, 255, 0.22);
  color: #fff;
}

html.dark-mode .header-currency-menu.ph-pop--wallet .ph-pop__ccy:hover,
html.dark-mode .header-currency-menu.ph-pop--wallet .dropdown-item:hover,
html.dark-mode .panel-topbar .ph-pop--wallet .ph-pop__ccy:hover,
html.dark-mode .panel-topbar .ph-pop--wallet .dropdown-item:hover {
  background: #f0fdf4 !important;
  color: #111827 !important;
}

html.dark-mode .header-currency-menu.ph-pop--wallet .ph-pop__ccy.active,
html.dark-mode .header-currency-menu.ph-pop--wallet .dropdown-item.active,
html.dark-mode .panel-topbar .ph-pop--wallet .ph-pop__ccy.active,
html.dark-mode .panel-topbar .ph-pop--wallet .dropdown-item.active {
  background: linear-gradient(90deg, rgba(22, 163, 74, 0.2) 0%, rgba(220, 252, 231, 0.92) 100%) !important;
  color: #14532d !important;
}

html.dark-mode .panel-topbar .ph-pop__link--logout:hover {
  background: rgba(239, 68, 68, 0.12) !important;
}

/* Phone / tablet: keep toggle + title + wallet + avatar on ONE header row.
   Bootstrap navbar-expand-xl otherwise wraps #navbarSupportedContent (7 Panel) onto the search. */
@media (max-width: 1199.98px) {
  html body.g-sidenav-show .main-content .panel-topbar.iq-navbar,
  html body.g-sidenav-show .panel-topbar.iq-navbar {
    overflow: visible !important;
  }

  html body.g-sidenav-show .panel-topbar .navbar-inner,
  .panel-topbar .navbar-inner {
    flex-wrap: nowrap !important;
    flex-direction: row !important;
    align-items: center !important;
    gap: 6px !important;
  }

  .panel-topbar .product-offcanvas,
  .panel-topbar .ph-title {
    flex: 1 1 auto !important;
    min-width: 0 !important;
    max-width: none !important;
  }

  .panel-topbar .header-quick-actions {
    margin-left: 0 !important;
    flex: 0 0 auto !important;
  }

  .panel-topbar #navbarSupportedContent.navbar-collapse,
  .panel-topbar #navbarSupportedContent.collapse.navbar-collapse,
  .panel-topbar.navbar-expand-xl .navbar-collapse {
    display: flex !important;
    flex: 0 0 auto !important;
    flex-grow: 0 !important;
    flex-shrink: 0 !important;
    flex-basis: auto !important;
    width: auto !important;
    max-width: none !important;
    height: auto !important;
    margin: 0 !important;
    padding: 0 !important;
    overflow: visible !important;
    background: transparent !important;
    border: 0 !important;
  }

  .panel-topbar #navbarSupportedContent .navbar-list,
  .panel-topbar #navbarSupportedContent .navbar-nav.navbar-list {
    display: flex !important;
    flex-direction: row !important;
    flex-wrap: nowrap !important;
    align-items: center !important;
    gap: 6px !important;
    width: auto !important;
    margin: 0 !important;
    padding: 0 !important;
  }

  .panel-topbar #navbarSupportedContent .navbar-list > .nav-item {
    width: auto !important;
    margin: 0 !important;
  }

  .panel-topbar .ph-user__name,
  .panel-topbar #itemdropdown1 .ph-user__name,
  .panel-topbar .ph-user .ph-caret {
    display: none !important;
  }

  .panel-topbar .ph-user,
  .panel-topbar #itemdropdown1 a.nav-link.ph-user,
  .panel-topbar .ph-user.ph-user--icon-only,
  .panel-topbar #itemdropdown1 a.nav-link.ph-user.ph-user--icon-only {
    width: auto !important;
    min-width: 0 !important;
    max-width: none !important;
    height: auto !important;
    min-height: 0 !important;
    padding: 0 !important;
    gap: 0 !important;
    justify-content: center !important;
    background: transparent !important;
    box-shadow: none !important;
    backdrop-filter: none !important;
    -webkit-backdrop-filter: none !important;
    border: 0 !important;
  }

  .panel-topbar .ph-user:hover,
  .panel-topbar #itemdropdown1.show .ph-user,
  .panel-topbar #itemdropdown1.show a.nav-link.ph-user {
    background: transparent !important;
    box-shadow: none !important;
    transform: none !important;
  }

  .panel-topbar .ph-user:hover .ph-avatar-wrap,
  .panel-topbar #itemdropdown1.show .ph-avatar-wrap {
    transform: scale(1.04);
  }

  html body.g-sidenav-show .panel-topbar #navbarSupportedContent,
  html body.g-sidenav-show .panel-topbar #navbarSupportedContent.navbar-collapse,
  html body.g-sidenav-show .panel-topbar.navbar-expand-xl .navbar-collapse {
    display: none !important;
  }

  html body.g-sidenav-show .panel-topbar .header-quick-actions {
    display: flex !important;
    flex-wrap: nowrap !important;
    align-items: center !important;
    justify-content: flex-end !important;
    flex: 0 1 auto !important;
    flex-grow: 0 !important;
    margin-left: auto !important;
    gap: 6px !important;
  }

  html body.g-sidenav-show .panel-topbar .header-quick-actions > .lbrt-theme,
  html body.g-sidenav-show .panel-topbar .header-quick-actions > #itemdropdown1 {
    display: flex !important;
    align-items: center !important;
    flex: 0 0 auto !important;
    margin: 0 !important;
  }
}

@media (max-width: 767.98px) {
  body.g-sidenav-show {
    --panel-topbar-h: 66px;
    --panel-shell-toggle-size: 32px;
  }

  .panel-topbar.iq-navbar,
  .panel-topbar.navbar.iq-navbar {
    height: var(--panel-topbar-h, 66px) !important;
    min-height: var(--panel-topbar-h, 66px) !important;
    max-height: var(--panel-topbar-h, 66px) !important;
  }

  .panel-topbar .navbar-inner {
    padding: 8px 8px !important;
    gap: 5px !important;
    min-height: var(--panel-topbar-h, 66px);
    height: 100%;
    align-items: center !important;
  }

  .panel-topbar .ph-title small,
  .panel-topbar .ph-title h1,
  .panel-topbar .ph-title h2,
  .panel-topbar .ph-title h3 {
    font-size: 14px !important;
    max-width: 22vw;
  }

  .panel-topbar .header-quick-actions,
  .panel-topbar #navbarSupportedContent .navbar-list,
  html body.g-sidenav-show .panel-topbar .header-quick-actions {
    gap: 5px !important;
  }

  .panel-topbar .sidebar-toggle {
    width: 32px !important;
    height: 32px !important;
    min-width: 32px !important;
    min-height: 32px !important;
  }

  .panel-topbar .sidebar-toggle svg,
  .panel-topbar .sidebar-toggle .icon {
    width: 15px !important;
    height: 15px !important;
  }

  .panel-topbar .header-quick-actions #currencyDropdown,
  .panel-topbar .ph-wallet {
    max-width: min(52vw, 188px) !important;
    height: auto !important;
    min-height: 0 !important;
    padding-block: 6px !important;
    padding-inline: 8px 6px !important;
    gap: 2px !important;
    box-shadow: 0 4px 15px rgba(16, 185, 129, 0.3) !important;
  }

  .panel-topbar .ph-wallet-dd.has-converted-balance #currencyDropdown,
  .panel-topbar .ph-wallet-dd.has-converted-balance .ph-wallet {
    padding-block: 6px !important;
    padding-inline: 8px 6px !important;
  }

  .panel-topbar #currencyDropdown .ph-wallet-ico,
  .panel-topbar .ph-wallet .ph-wallet-ico {
    width: 16px !important;
    height: 16px !important;
  }

  .panel-topbar .ph-wallet b.balance-amount,
  .panel-topbar #currencyDropdown .balance-amount {
    font-size: 13px !important;
  }

  .panel-topbar #currencyDropdown::after,
  .panel-topbar .ph-wallet::after {
    margin-left: 2px !important;
    margin-inline-start: 2px !important;
  }

  .panel-topbar #cartSidebarBtn,
  .panel-topbar #ActivityToggleBtn,
  .panel-topbar #MessagesToggleBtn {
    width: 34px !important;
    height: 34px !important;
    min-width: 34px !important;
    min-height: 34px !important;
    border-radius: 11px !important;
    box-shadow:
      inset 0 1px 0 rgba(255, 255, 255, 0.95),
      0 2px 6px rgba(15, 23, 42, 0.05),
      0 10px 24px rgba(37, 99, 235, 0.1) !important;
  }

  .panel-topbar #cartSidebarBtn i,
  .panel-topbar #MessagesToggleBtn i,
  .panel-topbar #ActivityToggleBtn i {
    font-size: 15px !important;
  }

  .panel-topbar #cartSidebarBtn #cart-item-count,
  .panel-topbar #MessagesToggleBtn .header-icon-badge,
  .panel-topbar #ActivityToggleBtn .header-icon-badge,
  .panel-topbar #MessagesToggleBtn #message-count {
    top: 2px !important;
    right: 2px !important;
    min-width: 15px !important;
    height: 15px !important;
    font-size: 9px !important;
    padding: 0 3px !important;
  }

  .panel-topbar .ph-user,
  .panel-topbar #itemdropdown1 a.nav-link.ph-user {
    width: auto !important;
    min-width: 0 !important;
    max-width: none !important;
    height: auto !important;
    min-height: 0 !important;
    padding: 0 !important;
    background: transparent !important;
    box-shadow: none !important;
  }

  .panel-topbar .ph-avatar-wrap,
  .panel-topbar #itemdropdown1 .ph-avatar-wrap {
    width: 32px !important;
    height: 32px !important;
    flex: 0 0 32px !important;
    padding: 0 !important;
  }

  .panel-topbar .ph-user img.ph-avatar,
  .panel-topbar #itemdropdown1 a.nav-link.ph-user img.ph-avatar {
    width: 32px !important;
    height: 32px !important;
    max-width: 32px !important;
  }

  .panel-topbar .ph-avatar-wrap .ph-user-initial {
    width: 32px !important;
    height: 32px !important;
    font-size: 12px !important;
  }

  .panel-topbar .ph-user__dot {
    width: 9px;
    height: 9px;
    border-width: 2px;
  }

  .panel-topbar .lbrt-theme .ph-sd-theme {
    width: 34px !important;
    height: 34px !important;
    min-width: 34px !important;
    min-height: 34px !important;
    border-radius: 11px !important;
    font-size: 12px !important;
  }

  .panel-topbar .lbrt-theme .theme-toggle-btn.theme-toggle-btn--compact,
  html body.g-sidenav-show .panel-topbar .header-quick-actions .theme-toggle-btn.theme-toggle-btn--compact {
    width: 32px !important;
    height: 32px !important;
    min-width: 32px !important;
    min-height: 32px !important;
    max-width: 32px !important;
    max-height: 32px !important;
    box-shadow:
      0 3px 8px rgba(15, 23, 42, 0.14),
      0 8px 18px rgba(15, 23, 42, 0.2) !important;
  }

  .panel-topbar .lbrt-theme .theme-toggle-btn.theme-toggle-btn--compact:hover,
  html body.g-sidenav-show .panel-topbar .header-quick-actions .theme-toggle-btn.theme-toggle-btn--compact:hover {
    box-shadow:
      0 4px 10px rgba(15, 23, 42, 0.18),
      0 10px 22px rgba(15, 23, 42, 0.24) !important;
  }

  .panel-topbar .lbrt-theme .theme-toggle-btn .theme-icon,
  html body.g-sidenav-show .panel-topbar .header-quick-actions .theme-toggle-btn .theme-icon {
    font-size: 13px !important;
  }
}

@media (max-width: 399.98px) {
  .panel-topbar .ph-title small,
  .panel-topbar .ph-title h1,
  .panel-topbar .ph-title h2,
  .panel-topbar .ph-title h3 {
    display: none !important;
  }

  .panel-topbar .product-offcanvas.ph-head-left {
    flex: 0 0 auto !important;
    min-width: 0 !important;
  }

  .panel-topbar .header-quick-actions #currencyDropdown,
  .panel-topbar .ph-wallet {
    max-width: min(52vw, 188px) !important;
  }
}

/* ── Shell: one sidebar toggle + sidebar header aligned with topbar ── */
/* Hope UI sidebar is z-index ~910; iq-banner/topbar ~1040+ — seam toggle must sit above topbar */
@media (min-width: 992px) {
  body.g-sidenav-show .sidebar.sidebar-base[data-sidebar="responsive"] {
    z-index: 1062 !important;
  }

  /* Bootstrap backdrop is 1050; sidebar at 1062 stayed bright when modals opened */
  body.modal-open.g-sidenav-show .sidebar.sidebar-base[data-sidebar="responsive"] {
    z-index: 1035 !important;
  }
}

@media (max-width: 991.98px) {
  body.modal-open.g-sidenav-show .sidebar.sidebar-base {
    z-index: 1035 !important;
  }
}

/* Modal open: dim full shell (topbar + sidebar + seam toggle); avoid body padding shift */
body.modal-open {
  padding-right: 0 !important;
}

body.modal-open.g-sidenav-show .sidebar + .main-content .panel-topbar.iq-navbar,
body.modal-open.g-sidenav-show .main-content .panel-topbar.iq-navbar {
  z-index: 1035 !important;
  padding-right: 0 !important;
}

body.modal-open.g-sidenav-show .sidebar.sidebar-base .sidebar-header {
  z-index: 1 !important;
}

body.modal-open.g-sidenav-show .sidebar.sidebar-base .sidebar-header .panel-shell-sidebar-toggle,
body.modal-open.g-sidenav-show .sidebar.sidebar-base .sidebar-header .sidebar-toggle {
  z-index: 1 !important;
  pointer-events: none !important;
}

body.modal-open.g-sidenav-show .panel-topbar .sidebar-toggle {
  pointer-events: none !important;
}

body.g-sidenav-show {
  --panel-shell-toggle-size: 36px;
}

@media (max-width: 991.98px) {
  body.g-sidenav-show {
    --panel-shell-toggle-size: 34px;
  }
}

body.g-sidenav-show .sidebar.sidebar-base .sidebar-header {
  height: var(--panel-topbar-h, 72px) !important;
  min-height: var(--panel-topbar-h, 72px) !important;
  max-height: var(--panel-topbar-h, 72px) !important;
  background: linear-gradient(180deg, #ffffff 0%, #fcfdff 100%) !important;
  border-bottom: 1px solid rgba(226, 232, 240, 0.95) !important;
  box-shadow: 0 6px 20px rgba(15, 23, 42, 0.04);
  align-items: center !important;
  padding-top: 0 !important;
  padding-bottom: 0 !important;
  box-sizing: border-box !important;
  flex-shrink: 0;
}

body.g-sidenav-show .sidebar.sidebar-base.left-bordered {
  border-right-color: rgba(30, 64, 175, 0.14) !important;
}

body.g-sidenav-show .sidebar.sidebar-base .sidebar-header .panel-shell-sidebar-toggle,
body.g-sidenav-show .sidebar.sidebar-base .sidebar-header .sidebar-toggle {
  background: #2563eb !important;
  color: #fff !important;
  box-shadow: 0 8px 18px rgba(37, 99, 235, 0.32) !important;
  width: var(--panel-shell-toggle-size, 36px) !important;
  height: var(--panel-shell-toggle-size, 36px) !important;
  min-width: var(--panel-shell-toggle-size, 36px) !important;
  min-height: var(--panel-shell-toggle-size, 36px) !important;
  border-radius: 50% !important;
  position: absolute !important;
  z-index: 1070 !important;
  pointer-events: auto !important;
}

body.g-sidenav-show .sidebar.sidebar-base .sidebar-header .sidebar-toggle svg,
body.g-sidenav-show .sidebar.sidebar-base .sidebar-header .sidebar-toggle .icon {
  color: #fff !important;
}

@media (max-width: 1199.98px) {
  /* Drawer closed: open control lives in the top bar */
  body.g-sidenav-show .sidebar.sidebar-base.sidebar-mini .sidebar-header .sidebar-toggle,
  body.g-sidenav-show .sidebar.sidebar-base.sidebar-mini .sidebar-header .panel-shell-sidebar-toggle {
    display: none !important;
  }

  /* Drawer open: close control must stay on the sidebar (top bar is covered) */
  body.g-sidenav-show .sidebar.sidebar-base:not(.sidebar-mini) .sidebar-header .sidebar-toggle,
  body.g-sidenav-show .sidebar.sidebar-base:not(.sidebar-mini) .sidebar-header .panel-shell-sidebar-toggle {
    display: inline-flex !important;
    align-items: center !important;
    justify-content: center !important;
    position: absolute !important;
    top: 50% !important;
    right: max(12px, env(safe-area-inset-right, 0px)) !important;
    left: auto !important;
    transform: translateY(-50%) !important;
    margin: 0 !important;
    z-index: 1080 !important;
    pointer-events: auto !important;
  }

  body.g-sidenav-show .sidebar.sidebar-base:not(.sidebar-mini) .sidebar-header {
    padding-right: calc(var(--panel-shell-toggle-size, 34px) + 22px) !important;
  }

  body.g-sidenav-show .panel-topbar .sidebar-toggle {
    background: #2563eb !important;
    color: #fff !important;
    width: var(--panel-shell-toggle-size, 34px) !important;
    height: var(--panel-shell-toggle-size, 34px) !important;
    min-width: var(--panel-shell-toggle-size, 34px) !important;
    min-height: var(--panel-shell-toggle-size, 34px) !important;
    box-shadow: 0 8px 18px rgba(37, 99, 235, 0.32) !important;
  }

  body.g-sidenav-show .panel-topbar .sidebar-toggle svg,
  body.g-sidenav-show .panel-topbar .sidebar-toggle .icon {
    color: #fff !important;
  }
}

@media (min-width: 1200px) {
  body.g-sidenav-show .panel-topbar .sidebar-toggle,
  body.g-sidenav-show .panel-topbar.iq-navbar .sidebar-toggle {
    display: none !important;
  }
}

html.dark-mode body.g-sidenav-show .sidebar.sidebar-base .sidebar-header {
  background: #13151c !important;
  border-bottom-color: rgba(255, 255, 255, 0.08) !important;
}

html.dark-mode body.g-sidenav-show .sidebar.sidebar-base .sidebar-header .sidebar-toggle {
  background: #1d4ed8 !important;
  box-shadow: 0 8px 18px rgba(0, 0, 0, 0.4) !important;
}

/* Mobile: compact wallet currency menu (JS sets top + left under balance pill) */
@media (max-width: 991.98px) {
  .panel-topbar .ph-wallet-dd .dropdown-menu.header-currency-menu.ph-pop--wallet,
  .panel-topbar .header-quick-actions .header-currency-menu.ph-pop--wallet,
  body > .header-currency-menu.ph-pop--wallet {
    position: fixed !important;
    left: auto !important;
    right: max(12px, env(safe-area-inset-right, 0px)) !important;
    width: min(268px, calc(100vw - 24px)) !important;
    min-width: 0 !important;
    max-width: min(268px, calc(100vw - 24px)) !important;
    transform: none !important;
    margin: 0 !important;
    padding: 6px !important;
    border-radius: 16px !important;
    box-sizing: border-box !important;
    z-index: 1092 !important;
    -webkit-overflow-scrolling: touch;
    overscroll-behavior: contain;
  }

  .header-currency-menu.ph-pop--wallet::-webkit-scrollbar,
  .panel-topbar .ph-pop--wallet::-webkit-scrollbar {
    width: 5px;
  }

  .header-currency-menu.ph-pop--wallet .ph-pop__add,
  .panel-topbar .ph-pop--wallet .ph-pop__add {
    gap: 7px;
    min-height: 36px;
    margin: 0 0 6px;
    padding: 7px 10px !important;
    border-radius: 11px !important;
    font-size: 12.5px;
  }

  .header-currency-menu.ph-pop--wallet .ph-pop__plus,
  .panel-topbar .ph-pop--wallet .ph-pop__plus {
    width: 20px;
    height: 20px;
    font-size: 14px;
    border-radius: 6px;
  }

  .header-currency-menu.ph-pop--wallet .ph-pop__label,
  .panel-topbar .ph-pop--wallet .ph-pop__label {
    gap: 6px;
    padding: 2px 4px 4px;
    margin: 0 0 2px;
    font-size: 9px;
  }

  .header-currency-menu.ph-pop--wallet .ph-pop__ccy-item,
  .panel-topbar .ph-pop--wallet .ph-pop__ccy-item {
    margin: 0 0 2px;
  }

  .header-currency-menu.ph-pop--wallet .ph-pop__ccy,
  .header-currency-menu.ph-pop--wallet .dropdown-item,
  .panel-topbar .ph-pop--wallet .ph-pop__ccy,
  .panel-topbar .ph-pop--wallet .dropdown-item {
    grid-template-columns: 32px 42px minmax(0, 1fr) 16px;
    column-gap: 5px;
    min-height: 36px;
    padding: 3px 5px 3px 3px !important;
    border-radius: 10px !important;
    font-size: 12px;
  }

  .header-currency-menu.ph-pop--wallet .ph-pop__sym,
  .panel-topbar .ph-pop--wallet .ph-pop__sym {
    min-width: 28px !important;
    height: 28px !important;
    padding: 0 2px;
    border-radius: 8px;
    font-size: 10px;
  }

  .header-currency-menu.ph-pop--wallet .ph-pop__code,
  .panel-topbar .ph-pop--wallet .ph-pop__code {
    font-size: 10.5px;
  }

  .header-currency-menu.ph-pop--wallet .ph-pop__cname,
  .panel-topbar .ph-pop--wallet .ph-pop__cname {
    font-size: 9.5px;
  }

  .header-currency-menu.ph-pop--wallet .ph-pop__ccy-mark,
  .panel-topbar .ph-pop--wallet .ph-pop__ccy-mark {
    width: 16px;
    height: 16px;
    border-width: 1.5px;
  }

  .header-currency-menu.ph-pop--wallet .ph-pop__ccy.active .ph-pop__ccy-mark,
  .panel-topbar .ph-pop--wallet .ph-pop__ccy.active .ph-pop__ccy-mark {
    box-shadow: 0 0 0 2px rgba(34, 197, 94, 0.2);
    background-size: 9px 9px;
  }

  .header-currency-menu.ph-pop--wallet .dropdown-item,
  .header-currency-menu.ph-pop--wallet .ph-pop__ccy {
    -webkit-tap-highlight-color: transparent;
  }

  .panel-topbar #itemdropdown1 .dropdown-menu.ph-pop--user {
    position: fixed !important;
    right: max(12px, env(safe-area-inset-right, 0px)) !important;
    left: auto !important;
    width: min(252px, calc(100vw - 24px - env(safe-area-inset-left, 0px) - env(safe-area-inset-right, 0px))) !important;
    min-width: 0 !important;
    max-width: min(252px, calc(100vw - 24px - env(safe-area-inset-left, 0px) - env(safe-area-inset-right, 0px))) !important;
    padding: 6px !important;
    border-radius: 16px !important;
    transform: none !important;
    box-sizing: border-box !important;
  }

  .panel-topbar .ph-pop--user .ph-pop__identity {
    padding: 8px 10px 10px !important;
    margin-bottom: 4px !important;
    border-radius: 12px !important;
  }

  .panel-topbar .ph-pop__identity-row {
    gap: 8px !important;
  }

  .panel-topbar .ph-pop__avatar {
    width: 36px !important;
    height: 36px !important;
  }

  .panel-topbar .ph-pop__avatar-img,
  .panel-topbar .ph-pop__avatar-initial.ph-user-initial--md {
    width: 36px !important;
    height: 36px !important;
    font-size: 14px !important;
  }

  .panel-topbar .ph-pop__avatar-dot {
    width: 8px;
    height: 8px;
    border-width: 1.5px;
  }

  .panel-topbar .ph-pop__name {
    font-size: 13px !important;
  }

  .panel-topbar .ph-pop__email {
    font-size: 10px !important;
    margin-top: 2px !important;
  }

  .panel-topbar .ph-pop--user .ph-pop__link {
    min-height: 36px !important;
    padding: 6px 8px !important;
    gap: 8px !important;
    border-radius: 10px !important;
    font-size: 12px !important;
  }

  .panel-topbar .ph-pop--user .ph-pop__ico {
    width: 30px !important;
    height: 30px !important;
    border-radius: 9px !important;
  }

  .panel-topbar .ph-pop--user .ph-pop__ico svg {
    width: 15px !important;
    height: 15px !important;
  }

  .panel-topbar .ph-pop--user .ph-pop__chev {
    width: 14px !important;
    height: 14px !important;
  }

  .panel-topbar .ph-pop--user .ph-pop__sep {
    margin: 4px 6px !important;
  }
}

/* Logged-in panel: language switcher in top bar — desktop only (mobile uses sidebar hub) */
.panel-topbar .panel-header-lang {
  display: none !important;
  align-items: center;
  list-style: none;
  margin: 0 !important;
  padding: 0 !important;
}

@media (min-width: 992px) {
  body.g-sidenav-show:not(.panel-guest) .panel-topbar .panel-header-lang {
    display: flex !important;
  }
}

.panel-topbar .panel-header-lang__btn {
  display: inline-flex !important;
  align-items: center !important;
  justify-content: center !important;
  min-width: 110px !important;
  height: 42px !important;
  padding: 0 16px !important;
  margin: 0 !important;
  border: 0 !important;
  border-radius: 12px !important;
  background: #3a57e8 !important;
  box-shadow: 0 6px 16px rgba(58, 87, 232, 0.28) !important;
  color: #fff !important;
  font-size: 14px !important;
  font-weight: 700 !important;
  line-height: 1 !important;
}

.panel-topbar .panel-header-lang__btn:hover,
.panel-topbar .panel-header-lang__btn:focus,
.panel-topbar .panel-header-lang__btn.show {
  background: #334fd4 !important;
  color: #fff !important;
  box-shadow: 0 8px 18px rgba(58, 87, 232, 0.32) !important;
}

.panel-topbar .panel-header-lang.dropdown .dropdown-toggle::after,
.panel-topbar .panel-header-lang__btn::after {
  content: "" !important;
  display: inline-block !important;
  width: 0 !important;
  height: 0 !important;
  margin: 0 0 0 8px !important;
  border: 0 !important;
  border-style: solid !important;
  border-width: 5px 4px 0 4px !important;
  border-color: #fff transparent transparent transparent !important;
  vertical-align: middle;
}

html[dir="rtl"] .panel-topbar .panel-header-lang__btn::after {
  margin: 0 8px 0 0 !important;
}

.panel-topbar .panel-header-lang__menu {
  min-width: 168px;
  max-height: min(320px, 70vh);
  overflow-y: auto;
  border-radius: 12px !important;
  padding: 6px !important;
  border: 1px solid rgba(226, 232, 240, 0.95) !important;
  box-shadow: 0 12px 32px rgba(15, 23, 42, 0.12) !important;
}

.panel-topbar .panel-header-lang__item {
  border-radius: 8px;
  font-size: 13px;
  font-weight: 600;
  padding: 8px 12px;
}

.panel-topbar .panel-header-lang__item.is-active,
.panel-topbar .panel-header-lang__item.active {
  background: #3a57e8 !important;
  color: #fff !important;
}

html.dark-mode .panel-topbar .panel-header-lang__menu {
  background: #1e293b !important;
  border-color: rgba(148, 163, 184, 0.2) !important;
}

html.dark-mode .panel-topbar .panel-header-lang__item {
  color: #e2e8f0;
}

html.dark-mode .panel-topbar .panel-header-lang__item:hover {
  background: rgba(58, 87, 232, 0.2);
  color: #fff;
}
