/* ============================================================
   CREO — Nav Dropdown Styles
   BEM: .nav-item-dropdown, .nav-dropdown
   ============================================================ */

/* ─── NAVEGACIÓN — ITEM CON DROPDOWN ─────────────────────────── */
.nav-links {
  /* Ensure parent allows visible dropdowns on hover */
  overflow: visible !important;
}

.nav-item-dropdown {
  position: relative;
  display: inline-block;
}

.nav-link--has-dropdown {
  display: flex !important;
  align-items: center;
  gap: 8px;
  cursor: pointer;
}

.nav-link-arrow {
  width: 12px;
  height: 12px;
  stroke: currentColor;
  stroke-width: 2.5;
  fill: none;
  transition: transform 0.3s cubic-bezier(0.16, 1, 0.3, 1);
}

.nav-item-dropdown:hover .nav-link-arrow {
  transform: rotate(180deg);
}

/* ─── DROPDOWN CONTAINER ────────────────────────────────────── */
.nav-dropdown {
  position: absolute;
  top: 100%;
  left: 50%;
  transform: translateX(-50%) translateY(10px);
  width: 280px;
  padding-top: 16px; /* Space for the caret */
  opacity: 0;
  visibility: hidden;
  transition: all 0.4s cubic-bezier(0.16, 1, 0.3, 1);
  z-index: 1001;
}

.nav-item-dropdown:hover .nav-dropdown {
  opacity: 1;
  visibility: visible;
  transform: translateX(-50%) translateY(0);
}

/* Glassmorphism Box */
.nav-dropdown-inner {
  background: rgba(11, 23, 61, 0.85); /* Semi-transparent dark bg */
  backdrop-filter: blur(20px);
  -webkit-backdrop-filter: blur(20px);
  border: 1px solid rgba(255, 255, 255, 0.1);
  border-radius: var(--radius-lg);
  padding: 12px;
  box-shadow: 
    0 10px 40px rgba(0, 0, 0, 0.4),
    inset 0 0 0 1px rgba(255, 255, 255, 0.05);
  position: relative;
}

/* Caret (Pico) */
.nav-dropdown-caret {
  position: absolute;
  top: -6px;
  left: 50%;
  transform: translateX(-50%);
  width: 0;
  height: 0;
  border-left: 8px solid transparent;
  border-right: 8px solid transparent;
  border-bottom: 8px solid rgba(11, 23, 61, 0.85);
  pointer-events: none;
}

/* ─── DROPDOWN LINKS ─────────────────────────────────────────── */
.nav-dropdown-list {
  list-style: none;
  margin: 0;
  padding: 0;
  display: flex;
  flex-direction: column;
  gap: 4px;
}

.nav-dropdown-item {
  width: 100%;
}

.nav-dropdown-link {
  display: flex;
  align-items: center;
  padding: 12px 16px;
  text-decoration: none;
  font-family: var(--font-body);
  font-size: 0.875rem;
  font-weight: 600;
  color: rgba(255, 255, 255, 0.7);
  border-radius: var(--radius-md);
  transition: all 0.2s ease;
  white-space: nowrap;
}

.nav-dropdown-link span {
  display: inline-block;
  color: var(--creo-accent); /* Orange for numbers */
  margin-right: 12px;
  font-size: 0.75rem;
  font-weight: 800;
  opacity: 0.6;
}

.nav-dropdown-link:hover {
  background: rgba(255, 255, 255, 0.08);
  color: var(--creo-white);
  transform: translateX(4px);
}

.nav-dropdown-link:hover span {
  opacity: 1;
}

/* Border on the left indicating current/hover? (Optional, maybe too much) */
/* .nav-dropdown-link:hover::before {
  content: "";
  position: absolute;
  left: 4px;
  width: 2px;
  height: 16px;
  background: var(--creo-accent);
  border-radius: 4px;
} */

/* Responsive: In mobile menu, we'll need a different approach (accordion or simple list) */
@media (max-width: 1023px) {
  .nav-dropdown {
    position: static;
    transform: none;
    width: 100%;
    opacity: 1;
    visibility: visible;
    display: none; /* Controlled via JS or just expanded toggle */
    padding-top: 8px;
  }
  
  .nav-item-dropdown--active .nav-dropdown {
    display: block;
  }

  .nav-dropdown-inner {
    background: rgba(0, 0, 0, 0.2);
    border: none;
    box-shadow: none;
    padding: 0 0 0 24px;
  }
  
  .nav-dropdown-caret {
    display: none;
  }
  
  .nav-dropdown-link {
    padding: 8px 16px;
    font-size: 0.8125rem;
  }
}
