.bottom-nav {
  position: fixed;
  z-index: 15;
  left: 50%;
  bottom: max(10px, env(safe-area-inset-bottom));
  width: min(680px, calc(100% - 28px));
  min-height: 76px;
  transform: translateX(-50%);
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  align-items: center;
  padding: 8px;
  border: 1px solid rgba(48,25,85,.08);
  border-radius: 25px;
  background: rgba(255,255,255,.97);
  box-shadow: 0 12px 36px rgba(12,4,28,.28);
  backdrop-filter: blur(14px);
}

.bottom-nav-item {
  position: relative;
  min-width: 0;
  min-height: 58px;
  display: grid;
  align-content: center;
  justify-items: center;
  gap: 3px;
  border-radius: 15px;
  color: #756d83;
  font-size: .75rem;
  font-weight: 700;
  text-decoration: none;
}

.bottom-nav .bottom-nav-item.active {
  color: #4c19a5;
  background: transparent;
}

.bottom-nav-icon {
  position: relative;
  width: 30px;
  min-height: 30px;
  display: grid;
  place-items: center;
  font-size: 1.25rem;
  line-height: 1;
}

.bottom-nav-icon svg {
  width: 24px;
  height: 24px;
  fill: none;
  stroke: currentColor;
  stroke-width: 1.8;
  stroke-linecap: round;
  stroke-linejoin: round;
}

.bottom-nav-item[data-nav-item="home"].active .bottom-nav-icon { color: #a978ff; }
.bottom-nav-item[data-nav-item="home"].active .bottom-nav-icon svg { fill: currentColor; stroke-width: 1.4; }
.bottom-nav-item[data-nav-item="inbox"].active .bottom-nav-icon { color: #ff8b3d; }
.bottom-nav-item[data-nav-item="inbox"].active .bottom-nav-icon svg { fill: currentColor; stroke-width: 1.2; }
.bottom-nav-item[data-nav-item="golden"].active .bottom-nav-icon {
  color: #ffd86a;
  filter: drop-shadow(0 0 6px rgba(255, 216, 106, .7));
}
.bottom-nav-item[data-nav-item="profile"] .nav-avatar-ring {
  width: 28px;
  height: 28px;
  display: grid;
  place-items: center;
  border: 1.5px solid #92859f;
  border-radius: 50%;
  background: linear-gradient(145deg, #34204d, #624391);
  font-size: 1rem;
}
.bottom-nav-item[data-nav-item="profile"].active .nav-avatar-ring {
  border: 2px solid #a978ff;
  box-shadow: 0 0 0 2px rgba(169, 120, 255, .15);
}
.bottom-nav-badge {
  position: absolute;
  top: -3px;
  right: -6px;
  min-width: 17px;
  height: 17px;
  padding: 0 4px;
  display: grid;
  place-items: center;
  border: 1.5px solid #fff;
  border-radius: 999px;
  background: #ef4444;
  color: #fff;
  font-size: .59rem;
  font-weight: 950;
  line-height: 1;
}
.bottom-nav-badge[hidden] { display: none !important; }
.bottom-profile-settings-badge { min-width: 15px; width: 15px; height: 15px; padding: 0; top: -2px; right: -5px; font-size: .62rem; }
.bottom-golden-badge { transform-origin: center; }

.bottom-nav-item:focus-visible { outline: 3px solid #c7a5ff; outline-offset: 3px; }

@media (prefers-reduced-motion: no-preference) {
  .bottom-nav-item[data-nav-item="golden"].active .bottom-nav-icon { animation: nav-golden-glow 2.4s ease-in-out infinite; }
  .bottom-golden-badge:not([hidden]) { animation: nav-golden-heartbeat 1.25s ease-in-out infinite; }
  @keyframes nav-golden-heartbeat {
    0%, 35%, 70%, 100% { transform: scale(1); }
    15%, 50% { transform: scale(1.28); }
  }
  @keyframes nav-golden-glow {
    0%, 100% { filter: drop-shadow(0 0 3px rgba(255, 216, 106, .42)); }
    50% { filter: drop-shadow(0 0 8px rgba(255, 216, 106, .86)); }
  }
}
