/*
 * VeloValue — barra de categorías horizontal bajo el header
 */

/* ── Barra ──────────────────────────────────────────────────────────────── */

.vv-cat-bar {
  background: var(--vv-gray-900);
  border-bottom: 1px solid rgba(255, 255, 255, .08);
}

.vv-cat-bar__inner {
  max-width: var(--wp--style--global--content-size, 1200px);
  margin: 0 auto;
  padding: 0 1rem;
}

.vv-cat-bar__list {
  display: flex;
  flex-wrap: wrap;
  list-style: none !important;
  margin: 0 !important;
  padding: 0 !important;
}

/* ── Items de nivel 1 ────────────────────────────────────────────────────── */

.vv-cat-bar__item {
  position: relative;
}

/* tipografía compartida entre nivel 1 y dropdown */
.vv-cat-bar__link,
.vv-cat-bar__dropdown-link {
  display: block;
  font-family: var(--vv-font-heading);
  font-size: .72rem;
  text-transform: uppercase;
  color: var(--vv-gray-200) !important;
  text-decoration: none !important;
  white-space: nowrap;
}

.vv-cat-bar__link {
  padding: .6rem .9rem;
  font-weight: 700;
  letter-spacing: .06em;
  transition: color .15s, background .15s;
}

.vv-cat-bar__link:hover,
.vv-cat-bar__item--has-sub:hover > .vv-cat-bar__link {
  color: var(--vv-sky) !important;
  background: rgba(255, 255, 255, .05);
}

/* indicador de que tiene hijos */
.vv-cat-bar__item--has-sub > .vv-cat-bar__link::after {
  content: '';
  display: inline-block;
  width: 0;
  height: 0;
  margin-left: .35rem;
  vertical-align: middle;
  border-left: 3px solid transparent;
  border-right: 3px solid transparent;
  border-top: 4px solid currentColor;
  opacity: .6;
}

/* ── Dropdown (nivel 2) ──────────────────────────────────────────────────── */

.vv-cat-bar__dropdown {
  display: none;
  position: absolute;
  top: 100%;
  left: 0;
  min-width: 190px;
  list-style: none !important;
  margin: 0 !important;
  padding: .3rem 0 !important;
  background: var(--vv-gray-900);
  border-top: 2px solid var(--vv-sky);
  border-radius: 0 0 var(--vv-radius) var(--vv-radius);
  box-shadow: 0 8px 20px rgba(0, 0, 0, .45);
  z-index: 9000;
  animation: vv-drop-in .12s ease;
}

.vv-cat-bar__item--has-sub:hover > .vv-cat-bar__dropdown,
.vv-cat-bar__item--has-sub:focus-within > .vv-cat-bar__dropdown {
  display: block;
}

@keyframes vv-drop-in {
  from { opacity: 0; transform: translateY(-4px); }
  to   { opacity: 1; transform: translateY(0); }
}

.vv-cat-bar__dropdown-link {
  padding: .5rem 1.1rem;
  font-weight: 600;
  letter-spacing: .05em;
  transition: background .1s, color .1s;
}

.vv-cat-bar__dropdown-link:hover {
  background: rgba(255, 255, 255, .06);
  color: var(--vv-sky) !important;
}

.vv-cat-bar__dropdown-item + .vv-cat-bar__dropdown-item > .vv-cat-bar__dropdown-link {
  border-top: 1px solid rgba(255, 255, 255, .06);
}

/* ── Mobile ──────────────────────────────────────────────────────────────── */

@media (max-width: 767px) {
  .vv-cat-bar { display: none; }
}
