/* Variables convertidas a CSS */
:root {
    --negro: #000;
    --blanco: #fff;
    --verde-claro: #4CAF50;
}

/* Estilos del header */
.header {
    background-color: var(--negro);
    padding: 2rem;
}

.contenido-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
}

.contenido-header img {
    align-items: center;
    width: 15rem;
    transition: transform 0.3s ease;
}

.contenido-header img:hover {
    transform: scale(0.9);
}

/* Navegación principal */
/* 🔹 MENÚ OCULTO POR DEFECTO */
.navegacion-principal {
    display: none;
    flex-direction: column;
    position: absolute;
    top: 190px; /* Se coloca debajo del header */
    left: 0;
    width: 100%;
    background-color: var(--negro);
    padding: 1rem;
    box-shadow: 0 4px 8px rgba(0, 0, 0, 0.2);
    z-index: 1000;
}

/* ✅ Fuerza que al activarse se muestre */
.navegacion-principal.mostrar {
    display: flex !important; /* 🔥 Sobrescribe display: none */
}

/* 🔹 ESTILO DE LOS LINKS */
.navegacion-principal a {
    color: var(--blanco);
    text-decoration: none;
    font-size: 1.6rem;
    padding: 1rem;
    display: block;
}

/* 🔹 MENÚ EN PANTALLAS GRANDES (SE RESTABLECE) */
@media (min-width: 768px) {
    .navegacion-principal {
        display: flex !important;
        flex-direction: row;
        position: static;
        background: none;
        box-shadow: none;
    }
}

.navegacion-principal a:hover {
    color: var(--verde-claro);
    transform: translateY(-2px);
}

/* Efecto de subrayado animado */
.navegacion-principal a::before {
    content: '';
    position: absolute;
    width: 0%;
    height: 3px;
    bottom: 0;
    left: 0;
    background-color: var(--verde-claro);
    transition: width 0.3s ease;
}

.navegacion-principal a:hover::before {
    width: 100%;
}

/* Mostrar navegación en pantallas grandes */
@media (min-width: 768px) {
    .navegacion-principal {
        display: flex;
        flex-direction: row;
        gap: 1rem;
        overflow: visible;
    }

    .navegacion-principal.active {
        display: flex;
        text-align: start;
    }
}

/* Menú Hamburguesa */
.mobile-menu {
    display: flex;
    flex-direction: column;
    align-items: flex-start;
    cursor: pointer;
}

.mobile-menu img {
    width: 3rem;
}

.mobile-menu img:hover {
    cursor: pointer;
}

/* Ocultar menú hamburguesa en pantallas grandes */
@media (min-width: 768px) {
    .mobile-menu {
        display: none;
    }
}

/* Estilos de dark mode */
.derecha {
    display: flex;
    flex-direction: column;
    align-items: center;
}

.derecha .dark-mode-boton {
    width: 2rem;
    margin-top: 3rem;
    margin-bottom: 3rem;
    filter: invert(100%);
    cursor: pointer;
}

@media (min-width: 768px) {
    .derecha {
        align-items: flex-end;
    }

    .derecha .dark-mode-boton {
        margin-top: 0;
        width: 2rem;
        height: 2rem;
    }
}
