/* ============================= */
/*       NAVBAR PRINCIPAL        */
/* ============================= */

.navbar {
    background-color: #ffffff;
    border-top: 1px solid #eee;
    border-bottom: 2px solid #947e1e;
    color: #333;
    display: flex;
    justify-content: center;
    align-items: stretch;
    width: 100%;
    position: relative; 
    z-index: 100;       
    height: 40px;
    box-shadow: 0 2px 5px rgba(0,0,0,0.02);
}

.navbar > ul {
    list-style: none;
    margin: 0;
    padding: 0;
    display: flex;
    width: 100%;
    max-width: 1200px;
    justify-content: center;
    gap: 30px;
    align-items: stretch; 
}

.navbar > ul > li {
    margin: 0;
    padding: 0;
    position: relative;
    display: flex;
    align-items: center;
    transition: all 0.3s;
    border-bottom: 2px solid transparent;
}

/* Hover en items principales */
.navbar > ul > li:hover {
    background-color: rgba(148, 126, 30, 0.04);
    border-bottom: 2px solid #947e1e;
}

.navbar > ul > li.active,
.navbar > ul > li > a.active {
    border-bottom: 2px solid #947e1e;
    color: #947e1e;
}

.navbar > ul > li > a {
    color: #555;
    text-decoration: none;
    font-size: 0.80rem;
    font-weight: 400;
    text-transform: uppercase;
    letter-spacing: 0.5px;
    padding: 0 15px;
    display: flex;
    align-items: center;
    justify-content: center;
    height: 100%; 
    transition: color 0.3s; 
}

.navbar > ul > li:hover > a {
    color: #947e1e;
}

/* ============================= */
/*       FLECHA INDICADORA       */
/* ============================= */

.navbar .menu-item-has-children > a {
    padding-right: 5px;
}

.navbar .menu-item-has-children::after {
    content: "\f0d7";
    font-family: "Font Awesome 6 Free";
    font-weight: 900;
    font-size: 0.7rem;
    color: #999;
    margin-right: 15px; /* Espacio */
    transition: transform 0.3s ease;
}

.navbar .menu-item-has-children:hover::after {
    transform: rotate(180deg);
    color: #947e1e;
}

/* =============================== */
/*             SUBMENÚ             */
/* =============================== */

.navbar .sub-menu {
    display: none;
    position: absolute;
    top: 100%;
    left: 0;
    min-width: 220px; /* Ancho mínimo */
    background-color: white;
    box-shadow: 0 5px 15px rgba(0, 0, 0, 0.1);
    padding: 10px 0;
    z-index: 999;
    border-top: 3px solid #947e1e; /* Línea de acento */
    flex-direction: column;
}

.navbar > ul > li:hover > .sub-menu {
    display: flex;
    animation: fadeIn 0.3s ease;
}

.navbar .sub-menu li {
    display: block;
    width: 100%;
}

.navbar .sub-menu li a {
    padding: 10px 20px;
    display: block;
    text-align: left; 
    color: #666; 
    font-weight: 500;
    font-size: 0.9em;
    text-transform: none; /* Normal en submenu */
    border-radius: 0;
    white-space: nowrap;
    text-decoration: none;
}

.navbar .sub-menu li a:hover {
    background-color: #f9f9f9;
    color: #947e1e;
    transform: translateX(5px); /* Pequeño desplazamiento */
}

/* =============================== */
/*         NAVBAR WIDGET ITEM      */
/* =============================== */

/* El LI del widget */
.navbar > ul > li.navbar-widget-item {
    padding: 0 15px; /* Mismo padding lateral que los enlaces normales */
    display: flex;
    align-items: center;
    justify-content: center;
}

/* Evitar el borde/fondo hover en el widget si lo prefieres limpio */
/* (Opcional: si quieres que se ilumine como los otros, borra esto) */
.navbar > ul > li.navbar-widget-item:hover {
    background-color: transparent;
    border-bottom-color: transparent;
}

/* Ajustes genéricos para contenidos de widgets (como GTranslate) */
.navbar-widget-item select {
    padding: 5px 10px;
    border: 1px solid #ddd;
    border-radius: 4px;
    font-size: 0.85rem;
    color: #555;
    background: #fafafa;
    outline: none;
    cursor: pointer;
}

.navbar-widget-item select:focus {
    border-color: #947e1e;
}

/* Si el widget es una lista (algunos plugins de idiomas usan UL/LI) */
.navbar-widget-item ul {
    display: flex;
    list-style: none;
    padding: 0;
    margin: 0;
    gap: 5px;
}

.navbar-widget-item img {
    vertical-align: middle; /* Para banderitas */
}

@keyframes fadeIn {
    from { opacity: 0; transform: translateY(10px); }
    to { opacity: 1; transform: translateY(0); }
}

@media (max-width: 992px) {
    .navbar { display: none; }
}