/* Fondo degradado del sidebar */
.sidebar-gradient {
    background: linear-gradient(
        135deg,
        #ffffff 0%,
        #cc9efd 25%,
        #a582ff 50%,
        #3b78d8 75%,
        #3b78d8 100%
    );
}

/* Letras blancas en el sidebar */
.sidebar-letter-white .nav-link {
    color: #ffffff !important;
}

/* TODOS los botones (no activos) con fondo lila clarito */
.nav-sidebar .nav-item > .nav-link {
    background-color: rgba(
        128,
        0,
        128,
        0.07
    ) !important; /* lila clarito muy sutil */
    color: #1b003a !important;
    border-radius: 8px;
    transition: all 0.3s ease;
    transform-origin: center;
}

/* HOVER sobre cualquier botón del menú */
.nav-sidebar .nav-item > .nav-link:hover {
    transform: scale(1.05);
    box-shadow: 0 0 10px rgba(128, 0, 128, 0.3);
    background-color: rgba(128, 0, 128, 0.15) !important;
}

/* BOTÓN PADRE ABIERTO (menu-open) — aunque NO esté activo */
.nav-sidebar .nav-item.menu-open > .nav-link {
    background-color: rgba(128, 0, 128, 0.15) !important;
    color: #1b003a !important;
    border-radius: 8px;
    box-shadow: inset 0 0 5px rgba(128, 0, 128, 0.3);
    transition: all 0.3s ease;
    /* eliminamos transform: scale */
}

/* BOTÓN PADRE ABIERTO Y ACTIVO */
.nav-sidebar .nav-item.menu-open > .nav-link.active {
    background-color: rgba(128, 0, 128, 0.2) !important;
    color: #1b003a !important;
    border-radius: 8px;
    font-size: 1.05em;
    box-shadow: inset 0 0 8px rgba(128, 0, 128, 0.4);
    transition: all 0.3s ease;
    /* eliminamos transform: scale */
}

/* BOTÓN HIJO ACTIVO */
.nav-sidebar .nav-treeview > .nav-item > .nav-link.active {
    background-color: rgba(128, 0, 128, 0.25) !important;
    border: 2px solid rgba(128, 0, 128, 0.5) !important;
    color: #1b003a !important;
    font-size: 1.05em;
    border-radius: 8px;
    box-shadow: 0 0 10px rgba(128, 0, 128, 0.4);
    transition: all 0.3s ease;
    /* eliminamos transform: scale */
}

/* HOVER en BOTÓN HIJO ACTIVO */
.nav-sidebar .nav-treeview > .nav-item > .nav-link.active:hover {
    background-color: rgba(128, 0, 128, 0.4) !important;
    border-color: rgba(128, 0, 128, 0.8) !important;
    transform: scale(1.08);
}

/* BOTÓN HIJO NO ACTIVO */
.nav-sidebar .nav-treeview > .nav-item > .nav-link {
    background-color: rgba(128, 0, 128, 0.07) !important;
    color: #1b003a !important;
    border-radius: 8px;
    transition: all 0.3s ease;
}

.nav-sidebar .nav-treeview > .nav-item > .nav-link:hover {
    background-color: rgba(128, 0, 128, 0.15) !important;
    transform: scale(1.05);
    box-shadow: 0 0 10px rgba(128, 0, 128, 0.3);
}

/* Animación del submenú al desplegarse */
.nav-treeview {
    max-height: 0;
    overflow: hidden;
    transition: max-height 0.4s ease;
}

.nav-item.menu-open > .nav-treeview {
    max-height: 1000px; /* suficientemente grande para mostrar submenus */
}
/* ////////////////77777777777777777777777777777777//////// */
/* INPUT DEL BUSCADOR */
.form-control-sidebar {
    background-color: rgba(
        128,
        0,
        128,
        0.3
    ); /* un lila más oscuro y traslúcido */
    border: 1px solid rgba(128, 0, 128, 0.4);
    color: #fff;
    border-radius: 8px;
    padding: 0.5rem 0.75rem;
    font-size: 0.95rem;
    transition: all 0.3s ease;
}

.form-control-sidebar::placeholder {
    color: #e0c6ff;
}

.form-control-sidebar:focus {
    background-color: rgba(128, 0, 128, 0.5);
    border-color: rgba(128, 0, 128, 0.8);
    box-shadow: 0 0 5px rgba(179, 107, 255, 0.6);
    color: #fff;
}

/* BOTÓN LUPA O X */
.btn-sidebar {
    background-color: rgba(128, 0, 128, 0.4);
    color: #fff;
    border: none;
}

.btn-sidebar:hover {
    background-color: rgba(128, 0, 128, 0.7);
    color: #fff;
    transform: scale(1.1);
    transition: all 0.3s ease;
}

/* CAJA DE RESULTADOS DEL BUSCADOR */
.nav-item .dropdown-menu {
    background-color: rgba(40, 0, 70, 0.85);
    border: 1px solid rgba(128, 0, 128, 0.6);
    border-radius: 8px;
    padding: 0.5rem 0;
    color: #fff;
    backdrop-filter: blur(4px);
}

.nav-item .dropdown-menu .dropdown-item {
    color: #e9d4ff;
    padding: 0.5rem 1rem;
    transition: all 0.3s ease;
}

.nav-item .dropdown-menu .dropdown-item:hover {
    background-color: rgba(179, 107, 255, 0.3);
    color: #fff;
    border-radius: 6px;
    transform: translateX(5px);
}

/* RESULTADOS DEL SEARCH (si aparecen dentro de listas) */
.nav-sidebar .nav-treeview > .nav-item > .nav-link {
    background-color: rgba(128, 0, 128, 0.15);
    color: #fff;
    border-radius: 6px;
}

.nav-sidebar .nav-treeview > .nav-item > .nav-link:hover {
    background-color: rgba(179, 107, 255, 0.25);
    color: #fff;
    transform: translateX(5px);
    transition: all 0.3s ease;
}

.logo-importadora {
    background: rgb(2, 0, 36);
    background: linear-gradient(
        90deg,
        rgba(2, 0, 36, 1) 0%,
        rgba(3, 12, 13, 1) 35%,
        rgba(0, 212, 255, 1) 100%
    );
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
}

.logo-miranda {
    background: rgb(2, 0, 36);
    background: linear-gradient(
        90deg,
        rgba(2, 0, 36, 1) 0%,
        rgba(3, 12, 13, 1) 35%,
        rgba(0, 212, 255, 1) 100%
    );
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
}
