/* ==========================================================================
   Bottom Navigation вЂ” Floating Pill (Glass + Centered)
   Relax-Store
   ========================================================================== */

.bottom-nav {
  position: fixed !important;
  bottom: 12px !important;
  left: 50% !important;
  transform: translateX(-50%) !important;
  width: calc(100% - 16px) !important;
  max-width: 420px !important;
  z-index: 1000;
  height: 58px;
  min-height: 58px;
  background: rgba(28, 28, 30, 0.88) !important;
  backdrop-filter: blur(20px) saturate(160%) !important;
  -webkit-backdrop-filter: blur(20px) saturate(160%) !important;
  border-radius: 20px !important;
  border: 1px solid rgba(255, 255, 255, 0.08);
  box-shadow: 0 4px 24px rgba(0, 0, 0, 0.3), 0 1px 4px rgba(0, 0, 0, 0.2) !important;
  display: flex !important;
  flex-direction: row !important;
  align-items: stretch;
  justify-content: space-around;
  padding: 8px 4px 0 4px !important;
  margin: 0 auto !important;
}

/* --- Nav Item --- */
.bottom-nav-item {
  flex: 0 0 auto;
  width: 41px;
  height: 41px;
  display: flex !important;
  align-items: center !important;
  justify-content: center !important;
  text-decoration: none !important;
  cursor: pointer;
  border: none !important;
  background: none !important;
  padding: 0 !important;
  margin: 0 !important;
  position: relative;
  color: rgba(255, 255, 255, 0.35) !important;
  transition: color 0.25s ease, transform 0.25s ease;
  -webkit-tap-highlight-color: transparent;
  outline: none !important;
  border-radius: 12px !important;
}

.bottom-nav-item:active { transform: scale(0.92); }

.bottom-nav-item.active {
  color: #FFFFFF !important;
  text-shadow: 0 0 12px rgba(255, 255, 255, 0.3);
}

.bottom-nav-item.active::after {
  content: '';
  position: absolute;
  inset: 2px;
  border-radius: 10px;
  background: rgba(255, 255, 255, 0.08);
  z-index: -1;
}

.bottom-nav-item svg {
  width: 24px !important;
  height: 24px !important;
  display: block !important;
  flex-shrink: 0;
  stroke: currentColor !important;
  fill: none !important;
  filter: drop-shadow(0 0 4px rgba(255, 255, 255, 0.15));
  transition: filter 0.25s ease;
}

.bottom-nav-item.active svg {
  filter: drop-shadow(0 0 8px rgba(255, 255, 255, 0.4));
}

/* --- Hidden elements --- */
.bottom-nav-item-label { display: none; }
.bottom-nav-indicator { display: none; }

/* --- Badge --- */
.bottom-nav-badge {
  position: absolute;
  top: -2px;
  right: -2px;
  min-width: 16px;
  height: 16px;
  border-radius: 10px;
  background: #FF3B30;
  color: #fff;
  font-family: -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, sans-serif;
  font-size: 10px;
  font-weight: 600;
  display: none;
  align-items: center;
  justify-content: center;
  padding: 0 4px;
  line-height: 1;
  box-shadow: 0 2px 6px rgba(255, 59, 48, 0.4);
}

.bottom-nav-badge.visible { display: flex; }
.bottom-nav-badge.pop { animation: badge-pop 0.3s ease; }

@keyframes badge-pop {
  0%   { transform: scale(1); }
  40%  { transform: scale(1.3); }
  70%  { transform: scale(0.95); }
  100% { transform: scale(1); }
}

body.has-bottom-nav {
  padding-bottom: calc(70px + env(safe-area-inset-bottom, 0px)) !important;
}

/* Dark spacer under footer вЂ” matches site-footer background #111 */
body.has-bottom-nav::after {
  content: '';
  display: block;
  position: fixed;
  bottom: 0;
  left: 0;
  right: 0;
  height: calc(70px + env(safe-area-inset-bottom, 0px));
  background: #111;
  z-index: -1;
}
