:root {
    /* Light theme colors */
    --bg-color: #f8f9fa;
    --text-color: #ffffff52;
    --header-bg: linear-gradient(85deg, #004716, #007123, #bb0000, #004716);
    --accent-color: #e53e3e;
    --hover-color: #c53030;
    --shadow-color: rgba(0, 0, 0, 0.1);
    --toggle-bg: rgb(15 93 1);
    --toggle-text: #ffffff;
    --menu-bg: rgb(59 59 0 / 57%);
    --menu-hover-bg: rgba(229, 62, 62, 0.1);
    --transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
}

[data-theme="dark"] {
    /* Dark theme colors */
    --bg-color: #1a202c;
    --text-color: rgb(128 159 255);
    --header-bg: linear-gradient(180deg, rgb(3, 12, 38, 1), rgb(3, 12, 38, 1), rgb(3, 12, 38, 1), rgb(0 0 0));
    --accent-color: #ffb214;
    --hover-color: #e53e3e;
    --shadow-color: rgba(0, 0, 0, 0.3);
    --toggle-bg: rgb(0 35 135);
    --toggle-text: #1a202c;
    --menu-bg: rgb(0 0 0 / 67%);
    --menu-hover-bg: rgb(135 160 255 / 11%);
}

* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

body {
    font-family: 'Poppins', sans-serif;
    line-height: 1.6;
    transition: var(--transition);
    overflow: hidden;
}

.header {
    background: var(--header-bg);
    backdrop-filter: blur(8px);
    padding: 1rem 2rem;
    display: flex;
    align-items: center;
    justify-content: space-between;
    box-shadow: 0 2px 10px var(--shadow-color);
    position: fixed;
    width: 100%;
    top: 0;
    z-index: 1000;
    animation: slideDown 0.5s ease-out;
}

#content-frame {
    position: fixed;
    top: 70px;
    left: 0;
    width: 100%;
    height: calc(100% - 70px);
    border: none;
    z-index: 1;
}

.logo {
    font-size: 1.8rem;
    font-weight: 700;
    color: #ffca00;
    letter-spacing: 0.5px;
    transition: var(--transition);
    min-width: 120px;
    text-shadow: 0 0 10px #ffb591, 0 0 20px #ffb395, 0 0 30px #f9c474;
}

.logo:hover {
    transform: scale(1.05);
}

.nav-links {
    position: relative;
    flex-grow: 1;
    max-width: 400px;
    margin: 0 20px;
}

.mods-toggle {
    background: var(--accent-color);
    color: var(--toggle-text);
    border: none;
    padding: 0.6rem 1.4rem;
    border-radius: 8px;
    cursor: pointer;
    font-size: 1rem;
    font-weight: 600;
    transition: var(--transition);
    display: none;
}

.mods-toggle:hover {
    background: var(--hover-color);
    transform: translateY(-2px);
    box-shadow: 0 4px 8px var(--shadow-color);
}

.mods-menu {
    display: flex;
    list-style: none;
    width: 100%;
    gap: 0;
}

.mods-menu li {
    flex: 1;
    text-align: center;
}

.mods-menu li a {
    display: block;
    text-decoration: none;
    color: var(--text-color);
    font-size: 1rem;
    font-weight: 600;
    padding: 0.5rem 0.2rem;
    margin: 0 2px;
    border-radius: 6px;
    transition: var(--transition);
    position: relative;
}

.mods-menu li a::after {
    content: '';
    position: absolute;
    width: 0;
    height: 2px;
    bottom: 0;
    left: 0;
    background: var(--accent-color);
    transition: var(--transition);
}

.mods-menu li a:hover {
    color: var(--accent-color);
    background: var(--menu-hover-bg);
}

.mods-menu li a:hover::after {
    width: 100%;
}

.theme-toggle {
    background: var(--toggle-bg);
    border: none;
    border-radius: 50%;
    width: 44px;
    height: 44px;
    display: flex;
    align-items: center;
    justify-content: center;
    cursor: pointer;
    transition: var(--transition);
    flex-shrink: 0;
}

.theme-toggle:hover {
    transform: scale(1.1);
    box-shadow: 0 0 15px var(--accent-color);
}

.theme-icon {
    width: 24px;
    height: 24px;
    transition: var(--transition);
}

.light-icon {
    display: block;
}

.dark-icon {
    display: none;
}

[data-theme="dark"] .light-icon {
    display: none;
}

[data-theme="dark"] .dark-icon {
    display: block;
}

/* MODAL DE BIENVENIDA */
.welcome-modal {
    position: fixed;
    top: 0;
    left: 0;
    width: 100vw;
    height: 100vh;
    background: rgba(0, 0, 0, 0.8);
    backdrop-filter: blur(4px);
    display: flex;
    align-items: center;
    justify-content: center;
    z-index: 10000;
    opacity: 0;
    visibility: hidden;
    transition: all 0.3s ease-in-out;
}

.welcome-modal.show {
    opacity: 1;
    visibility: visible;
}

.welcome-modal-content {
    background: var(--menu-bg);
    border-radius: 20px;
    padding: 2.5rem;
    max-width: 600px;
    width: 90%;
    text-align: center;
    box-shadow: 0 20px 60px rgba(0, 0, 0, 0.3);
    border: 2px solid var(--accent-color);
    position: relative;
    transform: scale(0.8);
    transition: all 0.3s cubic-bezier(0.34, 1.56, 0.64, 1);
}

.welcome-modal.show .welcome-modal-content {
    transform: scale(1);
}

.welcome-modal h2 {
    color: var(--accent-color);
    font-size: 2.2rem;
    margin-bottom: 1.5rem;
    font-weight: 700;
    text-shadow: 0 2px 10px rgba(229, 62, 62, 0.3);
}

.welcome-modal p {
    color: var(--text-color);
    font-size: 1.1rem;
    line-height: 1.8;
    margin-bottom: 1rem;
    font-weight: 500;
}

.welcome-close-btn {
    background: linear-gradient(135deg, var(--accent-color), var(--hover-color));
    color: white;
    border: none;
    padding: 12px 30px;
    border-radius: 25px;
    font-size: 1.1rem;
    font-weight: 600;
    cursor: pointer;
    margin-top: 1.5rem;
    transition: all 0.3s ease;
    box-shadow: 0 4px 15px rgba(229, 62, 62, 0.3);
}

.welcome-close-btn:hover {
    transform: translateY(-2px);
    box-shadow: 0 8px 25px rgba(229, 62, 62, 0.4);
}

.welcome-close-btn:active {
    transform: translateY(0);
}

/* Dark theme adaptations for modal */
[data-theme="dark"] .welcome-modal-content {
    border-color: var(--accent-color);
}

[data-theme="dark"] .welcome-modal h2 {
    text-shadow: 0 2px 10px rgba(255, 178, 20, 0.3);
}

[data-theme="dark"] .welcome-close-btn {
    background: linear-gradient(135deg, var(--accent-color), #e08e00);
    box-shadow: 0 4px 15px rgba(255, 178, 20, 0.3);
}

[data-theme="dark"] .welcome-close-btn:hover {
    box-shadow: 0 8px 25px rgba(255, 178, 20, 0.4);
}

/* Blur effect for background content */
.content-blurred {
    filter: blur(5px);
    transition: filter 0.3s ease;
}

@keyframes slideDown {
    from {
        transform: translateY(-100%);
        opacity: 0;
    }
    to {
        transform: translateY(0);
        opacity: 1;
    }
}

@media (max-width: 768px) {
    .header {
        padding: 1rem;
    }
    
    .logo {
        font-size: 1.5rem;
    }
    
    .mods-toggle {
        display: block;
    }
    
    .mods-menu {
        display: none;
        position: absolute;
        top: 100%;
        left: 50%;
        transform: translateX(-50%);
        background: var(--menu-bg);
        backdrop-filter: blur(10px);
        flex-direction: column;
        width: 200px;
        padding: 1rem;
        border-radius: 12px;
        box-shadow: 0 10px 25px var(--shadow-color);
        gap: 0.5rem;
        animation: fadeInUp 0.3s ease-out;
    }
    
    .mods-menu.active {
        display: flex;
    }
    
    .mods-menu li {
        flex: none;
        text-align: left;
    }
    
    .mods-menu li a {
        padding: 0.75rem;
        margin: 0;
    }
    
    .theme-toggle {
        width: 38px;
        height: 38px;
    }
    
    .theme-icon {
        width: 20px;
        height: 20px;
    }

    .welcome-modal-content {
        padding: 2rem;
        max-width: 90%;
    }

    .welcome-modal h2 {
        font-size: 1.8rem;
    }

    .welcome-modal p {
        font-size: 1rem;
    }
}

@media (max-width: 480px) {
    .logo {
        font-size: 1.3rem;
        min-width: 100px;
    }
    
    .theme-toggle {
        width: 36px;
        height: 36px;
    }
    
    .theme-icon {
        width: 18px;
        height: 18px;
    }

    .welcome-modal-content {
        padding: 1.5rem;
        margin: 1rem;
    }

    .welcome-modal h2 {
        font-size: 1.6rem;
        margin-bottom: 1rem;
    }

    .welcome-modal p {
        font-size: 0.95rem;
        margin-bottom: 0.8rem;
    }
}

@keyframes fadeInUp {
    from {
        opacity: 0;
        transform: translateX(-50%) translateY(10px);
    }
    to {
        opacity: 1;
        transform: translateX(-50%) translateY(0);
    }
}

/* Clases para animaciones */
.theme-change {
    animation: fadeIn 0.3s ease-out;
}

@keyframes fadeIn {
    from {
        opacity: 0.8;
    }
    to {
        opacity: 1;
    }
}