/* =========================================================
   BARRA DE SECCIONES
   ========================================================= */

/* ---------- Barra de secciones ---------- */
.bar {
  display: flex;
  justify-content: space-between;   /* las secciones se reparten a lo ancho del contenido */
  gap: var(--space-1);
  margin-top: var(--gap-header);
  padding: 8px 6px 6px;
  overflow-x: auto;
  scrollbar-width: none;
}

.bar::-webkit-scrollbar { display: none; }

.cat {
  --mx: 0px;                            /* el ícono sigue un poco al cursor (js/motion.js) */
  --my: 0px;
  position: relative;
  flex: 0 0 auto;
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 10px;
  min-width: 112px;
  padding: 16px 12px 12px;
  background: none;
  border: 0;
  border-radius: 14px;
  color: var(--muted);
  font: inherit;
  cursor: pointer;
  transition: color var(--quick) var(--glide);
}

.cat svg {
  width: 38px;
  height: 38px;
  transform: translate(var(--mx), var(--my));
  transition: transform var(--move) var(--spring);
}

.cat .lbl {
  font-size: 15px;
  font-weight: 400;
}

.cat.on { color: var(--fg); }

.cat.on svg {
  transform: translate(var(--mx), var(--my)) scale(1.3) translateY(-3px);
  filter: drop-shadow(0 0 10px rgba(255, 255, 255, .45));
  animation: halo var(--breath) ease-in-out infinite;
}

.cat.on .lbl { font-weight: 600; }

/* Cursor quieto encima (js/app.js → arming): una línea se llena bajo el nombre
   y, al completarse, la sección se abre. Al salir, desaparece sin devolverse */
.cat::after {
  content: '';
  position: absolute;
  left: 50%;
  bottom: 2px;
  width: 28px;
  height: 2px;
  border-radius: 2px;
  background: var(--fg);
  opacity: 0;
  transform: translateX(-50%) scaleX(0);
  transition: opacity var(--quick) var(--glide);
  pointer-events: none;
}

.cat.arming::after {
  opacity: .8;
  transform: translateX(-50%) scaleX(1);
  transition: opacity var(--quick) var(--glide), transform var(--dwell) linear;
}

@keyframes halo {
  0%, 100% { filter: drop-shadow(0 0 7px rgba(255, 255, 255, .35)); }
  50% { filter: drop-shadow(0 0 16px rgba(255, 255, 255, .65)); }
}
