/* ============================================================
   nav_rail.css — Mobility Showroom v3
   ============================================================ */

#nav-rail {
  position: fixed;
  z-index: 9998;
  display: flex;
  flex-direction: column;
  gap: 5px;
  padding: 7px 5px;
  border-radius: 14px;
  background: rgba(255, 255, 255, 0.96);
  backdrop-filter: blur(14px);
  -webkit-backdrop-filter: blur(14px);
  box-shadow: 0 4px 24px rgba(15, 23, 42, 0.12), 0 1px 4px rgba(15,23,42,0.06);
  border: 1px solid rgba(15, 23, 42, 0.08);
  transition: box-shadow .2s ease;
}

#nav-rail:hover {
  box-shadow: 0 8px 32px rgba(15, 23, 42, 0.18), 0 2px 6px rgba(15,23,42,0.07);
}

.nav-rail__btn {
  width: 36px;
  height: 36px;
  border-radius: 10px;
  border: none;
  cursor: pointer;
  display: flex;
  align-items: center;
  justify-content: center;
  background: var(--btn-color, #374151);
  color: #ffffff;
  font-size: 14px;
  transition: transform .15s ease, box-shadow .15s ease, filter .15s ease, opacity .15s;
  box-shadow: 0 2px 6px rgba(15, 23, 42, 0.15);
  flex-shrink: 0;
  position: relative;
  overflow: hidden;
}

/* Shimmer on hover */
.nav-rail__btn::after {
  content: '';
  position: absolute;
  inset: 0;
  background: linear-gradient(135deg, rgba(255,255,255,0) 0%, rgba(255,255,255,0.22) 50%, rgba(255,255,255,0) 100%);
  opacity: 0;
  transition: opacity .15s;
}

.nav-rail__btn:hover {
  transform: scale(1.1) translateX(2px);
  box-shadow: 0 6px 18px rgba(15, 23, 42, 0.25);
  filter: brightness(1.07);
}

.nav-rail__btn:hover::after {
  opacity: 1;
}

.nav-rail__btn:active {
  transform: scale(0.96);
  box-shadow: 0 1px 4px rgba(15, 23, 42, 0.15);
}

.nav-rail__btn--active {
  box-shadow: 0 0 0 2.5px rgba(255,255,255,0.9), 0 4px 14px rgba(15,23,42,0.25);
  transform: translateX(2px);
}

/* Fly-out label panel */
#nav-rail-panel {
  position: fixed;
  z-index: 9999;
  background: rgba(255, 255, 255, 0.97);
  border: 1px solid rgba(15, 23, 42, 0.1);
  border-radius: 12px;
  padding: 9px 13px;
  box-shadow: 0 8px 28px rgba(15, 23, 42, 0.14);
  backdrop-filter: blur(10px);
  -webkit-backdrop-filter: blur(10px);
  pointer-events: auto;
  transition: opacity .15s ease, transform .15s ease, max-width .25s ease;
  transform-origin: left center;
  max-width: 240px;
}

#nav-rail-panel.nav-rail-panel--hidden {
  opacity: 0;
  pointer-events: none;
  transform: translateX(-6px) scale(0.97);
}

.nav-rail-panel__inner {
  display: flex;
  align-items: center;
  gap: 9px;
  font-size: 12.5px;
  font-weight: 600;
  color: #0f172a;
  font-family: -apple-system, 'Inter', 'Segoe UI', Arial, sans-serif;
  white-space: nowrap;
}

.nav-rail-panel__dot {
  width: 9px;
  height: 9px;
  border-radius: 50%;
  flex-shrink: 0;
}

.nav-rail-panel__label {
  white-space: nowrap;
}

/* Description — visible after 1.8s */
.nav-rail-panel__desc {
  margin-top: 7px;
  padding-top: 7px;
  border-top: 1px solid rgba(15, 23, 42, 0.08);
  font-size: 11px;
  line-height: 1.5;
  color: #475569;
  font-family: -apple-system, 'Inter', 'Segoe UI', Arial, sans-serif;
  white-space: normal;
  max-width: 220px;
  animation: descFadeIn .2s ease both;
}

@keyframes descFadeIn {
  from { opacity: 0; transform: translateY(-3px); }
  to   { opacity: 1; transform: translateY(0); }
}
