/* =====================================================================
   GROWTH V132 — NEXUS-INSPIRED TOP NAVIGATION (60FPS GPU OPTIMIZED)
   ===================================================================== */

/* 1. Sembunyikan total sidebar kiri & perluas area konten utama 100% */
#sb,
#sbBackdrop,
#top .mob {
  display: none !important;
}

#app {
  display: block !important;
}

#main {
  margin-left: 0 !important;
  width: 100% !important;
  max-width: 100% !important;
}

/* 2. Optimasi Performa Scroll Global pada Kartu Claymorphism */
.card,
.kpi,
.box,
.hero,
.tb {
  contain: layout style;
}

/* 3. Top Navigation Bar (Solid High-Opacity + GPU Compositing, Tanpa Backdrop-Blur Berat) */
#gNexusNav {
  position: sticky;
  top: 10px;
  z-index: 95;
  margin: 10px 20px 0;
  padding: 10px 18px;
  border-radius: 26px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 14px;
  background: rgba(255, 255, 255, 0.96);
  border: 1px solid var(--line, rgba(203, 213, 232, 0.9));
  box-shadow: 0 10px 24px -8px rgba(28, 45, 90, 0.14);
  transform: translateZ(0);
  will-change: transform;
  contain: layout style;
}

[data-theme=dark] #gNexusNav {
  background: rgba(20, 26, 46, 0.97);
  border-color: rgba(255, 255, 255, 0.09);
  box-shadow: 0 12px 26px -8px rgba(3, 6, 16, 0.65);
}

/* Kiri: Brand Logo */
.gnx-brand {
  display: flex;
  align-items: center;
  gap: 10px;
  cursor: pointer;
  flex-shrink: 0;
  text-decoration: none;
  color: var(--tx);
}

.gnx-brand img {
  width: 38px;
  height: 38px;
  border-radius: 12px;
  object-fit: contain;
  background: #ffffff;
  padding: 3px;
  border: 1px solid var(--line);
}

.gnx-brand-text {
  display: flex;
  flex-direction: column;
  line-height: 1.1;
}

.gnx-brand-text b {
  font-family: var(--fd, 'Sora', sans-serif);
  font-size: 16.5px;
  font-weight: 800;
  letter-spacing: 0.02em;
}

.gnx-brand-text small {
  font-size: 11px;
  color: var(--mu);
  font-weight: 600;
}

/* Tengah: Kapsul Pill */
.gnx-pill {
  display: flex;
  align-items: center;
  gap: 4px;
  padding: 5px 7px;
  border-radius: 999px;
  background: var(--panel2, #f3f6fc);
  border: 1px solid var(--line);
  box-shadow: inset 0 1px 3px rgba(25, 42, 86, 0.06);
  max-width: 100%;
}

[data-theme=dark] .gnx-pill {
  background: #0f1424;
  border-color: rgba(255, 255, 255, 0.08);
  box-shadow: inset 0 2px 4px rgba(0, 0, 0, 0.45);
}

.gnx-item {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  height: 34px;
  padding: 0 14px;
  border-radius: 999px;
  border: 0;
  background: transparent;
  color: var(--mu);
  font-family: var(--font);
  font-size: 12.5px;
  font-weight: 600;
  white-space: nowrap;
  cursor: pointer;
  transition: background-color 0.15s ease, color 0.15s ease;
}

.gnx-item:hover {
  color: var(--tx);
  background: var(--hov);
}

.gnx-item.on {
  background: var(--panel, #ffffff);
  color: var(--tx);
  font-weight: 700;
  box-shadow: 0 3px 10px -2px rgba(31, 49, 98, 0.16);
}

[data-theme=dark] .gnx-item.on {
  background: linear-gradient(135deg, #4f46e5, #6366f1);
  color: #ffffff;
  box-shadow: 0 4px 12px -2px rgba(79, 70, 229, 0.45);
}

.gnx-item svg {
  width: 15px;
  height: 15px;
  flex-shrink: 0;
}

/* Dropdown "Semua Modul" */
.gnx-more-wrap {
  position: relative;
}

.gnx-dropdown {
  position: absolute;
  top: calc(100% + 10px);
  right: 0;
  width: 280px;
  max-height: 72vh;
  overflow-y: auto;
  padding: 10px;
  border-radius: 20px;
  background: var(--panel, #ffffff);
  border: 1px solid var(--line);
  box-shadow: 0 16px 36px -8px rgba(20, 35, 75, 0.28);
  display: none;
  flex-direction: column;
  gap: 3px;
  z-index: 200;
}

.gnx-dropdown.open {
  display: flex;
}

.gnx-drop-title {
  font-size: 10.5px;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.05em;
  color: var(--mu);
  padding: 6px 10px 4px;
}

.gnx-drop-btn {
  display: flex;
  align-items: center;
  gap: 10px;
  width: 100%;
  padding: 9px 12px;
  border-radius: 12px;
  border: 0;
  background: transparent;
  color: var(--tx);
  font-size: 13px;
  font-weight: 600;
  text-align: left;
  cursor: pointer;
}

.gnx-drop-btn:hover {
  background: var(--hov);
}

.gnx-drop-btn.on {
  background: linear-gradient(135deg, #4f46e5 0%, #6366f1 100%);
  color: #ffffff;
}

.gnx-drop-btn svg {
  width: 16px;
  height: 16px;
  flex-shrink: 0;
}

/* Kanan: Kontrol & Tombol CTA */
.gnx-right {
  display: flex;
  align-items: center;
  gap: 8px;
  flex-shrink: 0;
}

.gnx-icon-btn {
  width: 36px;
  height: 36px;
  border-radius: 50%;
  border: 1px solid var(--line);
  background: var(--panel2);
  color: var(--tx);
  display: inline-flex;
  align-items: center;
  justify-content: center;
  cursor: pointer;
}

.gnx-icon-btn:hover {
  background: var(--hov);
}

.gnx-icon-btn svg {
  width: 16px;
  height: 16px;
}

.gnx-cta {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  height: 38px;
  padding: 0 18px;
  border-radius: 999px;
  border: 0;
  background: linear-gradient(135deg, #5b21b6 0%, #6d28d9 45%, #4f46e5 100%);
  color: #ffffff;
  font-family: var(--font);
  font-size: 13px;
  font-weight: 700;
  cursor: pointer;
  white-space: nowrap;
  box-shadow: 0 6px 16px -4px rgba(109, 40, 217, 0.45);
}

.gnx-cta:hover {
  filter: brightness(1.08);
}

.gnx-cta svg {
  width: 15px;
  height: 15px;
}

/* Responsif Mobile */
@media (max-width: 820px) {
  #gNexusNav {
    margin: 8px 8px 0;
    padding: 8px 12px;
    border-radius: 20px;
    top: 8px;
    gap: 8px;
  }
  .gnx-brand-text small,
  .gnx-icon-btn.hide-sm {
    display: none;
  }
  .gnx-pill {
    padding: 4px;
    gap: 2px;
    overflow-x: auto;
    scrollbar-width: none;
  }
  .gnx-pill::-webkit-scrollbar {
    display: none;
  }
  .gnx-item {
    height: 32px;
    padding: 0 10px;
    font-size: 12px;
  }
  .gnx-item.primary-tab span {
    display: none;
  }
  .gnx-dropdown {
    position: fixed;
    top: 62px;
    left: 10px;
    right: 10px;
    width: auto;
  }
  .gnx-cta {
    height: 34px;
    padding: 0 13px;
    font-size: 12px;
  }
}