header.header-main {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    padding: 20px 40px;
    display: flex;
    justify-content: space-between;
    align-items: center;
    z-index: 90000;
    color: white;
    background: linear-gradient(
        to bottom,
        rgba(0, 0, 0, 0.9) 0%,
        rgba(0, 0, 0, 0.6) 50%,
        rgba(0, 0, 0, 0) 100%
    ); /* Gradiente más suave y proporcional */
    box-sizing: border-box;
}

.logo-container {
    display: flex;
    align-items: center;
}

.logo {
    z-index: 90001;
}

.logo img {
    height: 3.5em;
    width: auto;
    transition: transform 0.3s ease;
}

.logo img:hover {
    transform: scale(1.1);
}

.dropdown {
    position: relative;
    margin-left: 15px;
}

.dropdown-toggle {
    background: none;
    border: none;
    color: white;
    font-family: 'Dancing Script', cursive;
    font-size: 20px;
    cursor: pointer;
    padding: 5px 10px;
    transition: color 0.3s ease;
}

.dropdown-toggle:hover {
    color: #ffc400;
}

.dropdown-menu {
    display: none;
    position: absolute;
    top: 100%;
    left: 0;
    background: rgba(0, 0, 0, 0.9);
    border-radius: 8px;
    padding: 10px 0;
    min-width: 150px;
    z-index: 90002;
    box-shadow: 0 4px 8px rgba(0, 0, 0, 0.3);
}

.dropdown-menu.active {
    display: block;
}

.dropdown-menu a {
    display: block;
    color: white;
    font-family: 'Dancing Script', cursive;
    font-size: 18px;
    padding: 8px 15px;
    text-decoration: none;
    transition: background 0.3s ease, transform 0.3s ease;
}

.dropdown-menu a:hover {
    background: rgba(255, 196, 0, 0.3);
    transform: translateX(5px);
}

nav {
    display: flex;
    align-items: center;
}

.nav-links {
    display: flex;
    align-items: center;
}

.nav-links a {
    margin: 0 10px;
    color: white;
    text-decoration: none;
    font-size: 16px;
    display: flex;
    align-items: center;
    height: 25px;
    transition: color 0.3s ease;
}

.nav-links a:hover {
    color: #ffc400;
}

.nav-links a span {
    color: #ffc400;
    text-decoration: underline;
}

.iconshome {
    filter: invert(100%);
    width: 25px;
    height: 25px;
    vertical-align: middle;
    margin-right: 5px;
}

.hamburger {
    color: white;
    display: none;
    background: none;
    border: none;
    cursor: pointer;
    padding: 5px 10px;
    position: relative;
    width: 30px;
    height: 30px;
    z-index: 90001;
}

.hamburger span {
    display: block;
    width: 25px;
    height: 3px;
    background: #ffffff;
    margin: 5px 0;
    transition: all 0.3s ease;
    border-radius: 2px;
}

.hamburger span:nth-child(2) {
    width: 20px;
}

.hamburger.active span:nth-child(1) {
    transform: rotate(45deg) translate(5px, 5px);
}

.hamburger.active span:nth-child(2) {
    opacity: 0;
}

.hamburger.active span:nth-child(3) {
    transform: rotate(-45deg) translate(7px, -7px);
}

.hamburger:hover span {
    background: #ffc400;
}

.nav-logo {
    display: none;
}

@media (max-width: 768px) {
    header.header-main {
        padding: 10px 20px;
        flex-direction: row !important;
        justify-content: space-between;
        align-items: center;
        background: linear-gradient(
            to bottom,
            rgba(0, 0, 0, 0.9) 0%,
            rgba(0, 0, 0, 0.7) 70%,
            rgba(0, 0, 0, 0) 100%
        ); /* Gradiente ajustado para pantallas más pequeñas */
    }

    .logo img {
        height: 2.8em;
    }

    .dropdown-toggle {
        font-size: 18px;
    }

    .dropdown-menu {
        min-width: 120px;
    }

    .dropdown-menu a {
        font-size: 16px;
        padding: 6px 12px;
    }

    .hamburger {
        display: block;
    }

    nav {
        position: fixed;
        top: 0;
        left: 0;
        width: 100%;
        height: 100vh;
        background: linear-gradient(
            to bottom,
            rgba(0, 0, 0, 0.9) 0%,
            rgba(29, 29, 29, 0.95) 50%,
            rgba(45, 45, 45, 0.9) 100%
        ); /* Gradiente ajustado para coherencia con el header */
        flex-direction: column;
        align-items: center;
        padding: 100px 20px;
        transform: translateX(-100%);
        transition: transform 0.5s ease-in-out;
        z-index: 90000;
        overflow-y: auto;
        -webkit-overflow-scrolling: touch;
    }

    nav::before {
        content: '';
        position: absolute;
        top: 0;
        left: 0;
        width: 100%;
        height: 100%;
        background: linear-gradient(
            45deg,
            rgba(255, 196, 0, 0.1) 0%,
            rgba(255, 255, 255, 0.05) 50%,
            rgba(255, 69, 0, 0.1) 100%
        );
        opacity: 0.3;
        z-index: 0;
    }

    nav.active {
        transform: translateX(0);
    }

    nav.active .nav-logo {
        display: block;
        position: absolute;
        top: 40px;
        left: 50%;
        transform: translateX(-50%);
        z-index: 1;
    }

    .nav-logo img {
        height: 7em;
        width: auto;
        transition: transform 0.3s ease;
    }

    .nav-logo img:hover {
        transform: scale(1.1);
    }

    .nav-links {
        flex-direction: column;
        width: 100%;
        max-width: 300px;
        margin-top: 60px;
        position: relative;
        z-index: 1;
    }

    .nav-links a {
        margin: 15px 0;
        font-size: 18px;
        height: auto;
        width: 100%;
        justify-content: center;
        padding: 12px 20px;
        background: rgba(255, 255, 255, 0.1);
        border-radius: 8px;
        box-shadow: 0 2px 5px rgba(0, 0, 0, 0.3);
        transition: all 0.3s ease;
        opacity: 0;
        transform: translateY(20px);
        animation: slideIn 0.5s forwards;
    }

    .nav-links a:nth-child(1) { animation-delay: 0.1s; }
    .nav-links a:nth-child(2) { animation-delay: 0.2s; }
    .nav-links a:nth-child(3) { animation-delay: 0.3s; }
    .nav-links a:nth-child(4) { animation-delay: 0.4s; }
    .nav-links a:nth-child(5) { animation-delay: 0.5s; }
    .nav-links a:nth-child(6) { animation-delay: 0.6s; }
    .nav-links a:nth-child(7) { animation-delay: 0.7s; }
    .nav-links a:nth-child(8) { animation-delay: 0.8s; }

    @keyframes slideIn {
        to {
            opacity: 1;
            transform: translateY(0);
        }
    }

    .nav-links a:hover {
        background: rgba(255, 196, 0, 0.3);
        transform: translateY(-3px);
        box-shadow: 0 4px 8px rgba(0, 0, 0, 0.4);
    }

    .iconshome {
        width: 25px;
        height: 25px;
        margin-right: 10px;
    }
}

@media (max-width: 480px) {
    header.header-main {
        padding: 10px 15px;
        background: linear-gradient(
            to bottom,
            rgba(0, 0, 0, 0.9) 0%,
            rgba(0, 0, 0, 0.8) 60%,
            rgba(0, 0, 0, 0) 100%
        ); /* Gradiente aún más ajustado para pantallas muy pequeñas */
    }

    .logo img {
        height: 2.5em;
    }

    .dropdown-toggle {
        font-size: 16px;
    }

    .dropdown-menu {
        min-width: 100px;
    }

    .dropdown-menu a {
        font-size: 14px;
        padding: 5px 10px;
    }

    .nav-logo img {
        height: 3.5em;
    }

    .nav-links a {
        font-size: 16px;
        padding: 10px 15px;
    }

    .iconshome {
        width: 22px;
        height: 22px;
    }

    .hamburger {
        width: 25px;
        height: 25px;
    }

    .hamburger span {
        width: 20px;
        height: 2px;
        margin: 4px 0;
    }

    .hamburger span:nth-child(2) {
        width: 15px;
    }
}