/* =================
   VARIABLES GLOBALES
   ================= */
:root {
    --color-yellow: #fbf9c4;
    --color-orange: #FF7F50;
    --color-purple: #D9C3FA;
    --color-green: #CAFA9D;
    --color-white: #FFFFFF;
    --color-blue-zone0: #0A1A2B;
    --color-blue-zone1: #0F1624;
    --color-blue-zone2: #1B2639;
    --color-blue-zone3: #283B5B;
    --color-blue-zone4: #384E7A;
    --color-accent: #88C4FF;
    --transition-speed: 0.3s;
    --border-radius: 10px;
}

/* =================
   RESET Y BASE
   ================= */
* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

html {
    overflow-x: hidden;
    width: 100%;
}

body {
    font-family: 'Montserrat', sans-serif;
    line-height: 1.6;
    color: var(--color-white);
    background-color: var(--color-blue-zone1);
    background-image: 
        radial-gradient(ellipse at 30% 30%, rgba(60, 1, 60, 0.07) 0%, rgba(128, 0, 128, 0.05) 40%, transparent 70%),
        radial-gradient(circle at 80% 15%, rgba(150, 20, 60, 0.04) 0%, rgba(150, 20, 60, 0.03) 30%, transparent 60%),
        radial-gradient(ellipse at 40% 80%, rgba(0, 28, 85, 0.08) 0%, rgba(0, 50, 150, 0.04) 50%, transparent 75%),
        radial-gradient(circle at 10% 60%, rgba(159, 27, 27, 0.07) 0%, transparent 60%),
        radial-gradient(ellipse at 85% 30%, rgba(0, 90, 90, 0.13) 0%, rgba(0, 128, 128, 0.05) 40%, transparent 70%),
        radial-gradient(ellipse at 85% 90%, rgba(86, 82, 12, 0.15) 0%, rgba(70, 78, 0, 0.05) 15%, transparent 90%),
        radial-gradient(circle at 5% 5%, rgba(5, 30, 52, 0.18) 0%, transparent 40%);
    position: relative;
    background-blend-mode: screen;
}

/* =================
   ELEMENTOS DECORATIVOS
   ================= */
.decoration {
    position: absolute;
    opacity: 0.1;
    pointer-events: none;
    z-index: -1;
}

.musical-note {
    top: 60%;
    right: 5%;
    width: 150px;
    height: 150px;
    background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='%23FFFFFF'%3E%3Cpath d='M12 3v10.55c-.59-.34-1.27-.55-2-.55-2.21 0-4 1.79-4 4s1.79 4 4 4 4-1.79 4-4V7h4V3h-6z'/%3E%3C/svg%3E");
    background-repeat: no-repeat;
    transform: rotate(15deg);
}

.book {
    top: 40%;
    left: 5%;
    width: 150px;
    height: 150px;
    background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='%23FFFFFF'%3E%3Cpath d='M22 16.653c0 .25-.05.5-.15.73a2 2 0 0 1-.41.62c-.181.171-.391.31-.62.41a1.9 1.9 0 0 1-.74.14a15.2 15.2 0 0 0-3.37.32a9.3 9.3 0 0 0-3.71 1.27V5.233c1.091-.52 2.26-.858 3.46-1a17.4 17.4 0 0 1 3.71-.33a1.92 1.92 0 0 1 1.3.61c.33.352.513.817.51 1.3zM11 5.233v14.91a9.25 9.25 0 0 0-3.65-1.27a16.2 16.2 0 0 0-3.43-.32a1.9 1.9 0 0 1-.74-.14a2.2 2.2 0 0 1-.62-.41a1.8 1.8 0 0 1-.41-.62a1.8 1.8 0 0 1-.15-.73v-10.9a1.9 1.9 0 0 1 1.78-1.89a17 17 0 0 1 3.79.33A10.7 10.7 0 0 1 11 5.233'/%3E%3C/svg%3E");
    background-repeat: no-repeat;
    transform: rotate(-15deg);
}

.controller {
    bottom: 20%;
    left: 5%;
    width: 150px;
    height: 150px;
    background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='%23FFFFFF'%3E%3Cpath d='M21 6H3c-1.1 0-2 .9-2 2v8c0 1.1.9 2 2 2h18c1.1 0 2-.9 2-2V8c0-1.1-.9-2-2-2zm-10 7H8v3H6v-3H3v-2h3V8h2v3h3v2zm4.5 2c-.83 0-1.5-.67-1.5-1.5s.67-1.5 1.5-1.5 1.5.67 1.5 1.5-.67 1.5-1.5 1.5zm4-3c-.83 0-1.5-.67-1.5-1.5S18.67 9 19.5 9s1.5.67 1.5 1.5-.67 1.5-1.5 1.5z'/%3E%3C/svg%3E");
    background-repeat: no-repeat;
    transform: rotate(5deg);
}

.butterfly {
    top: 10%;
    right: 5%;
    width: 150px;
    height: 150px;
    background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 48 48'%3E%3Cg fill='none' stroke='%23FFFFFF' stroke-linecap='round' stroke-linejoin='round' stroke-width='4'%3E%3Cpath fill='%23FFFFFF' d='M5 12c3.664-4.294 14.081 6.82 19 13c4.92-6.18 15.337-17.294 19-13c.679.65 1.443 2.877-1 6c-.678.976-1.814 3.706-1 8c0 1.139-1.115 2.952-6 1c2.375 1.627 6.85 6.096 4 10c-2.714 3.416-9.035 7.457-13-2l-2-4l-2 4c-3.964 9.457-10.286 5.416-13 2c-2.85-3.904 1.626-8.373 4-10c-4.885 1.952-6 .139-6-1c.814-4.294-.321-7.024-1-8c-2.442-3.123-1.678-5.35-1-6'/%3E%3Cpath d='M24.032 23C23.534 17.864 28.913 7 33 7'/%3E%3Cpath d='M23.968 23C24.466 17.864 19.087 7 15 7'/%3E%3C/g%3E%3C/svg%3E");
    background-repeat: no-repeat;
    transform: rotate(25deg);
}

/* =================
   ESTRELLAS
   ================= */
.stars-container {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    pointer-events: none;
    z-index: -2;
}

.star {
    position: absolute;
    background-color: #ffffff;
    border-radius: 50%;
    opacity: 0;
    animation: twinkle var(--twinkle-duration) ease-in-out infinite;
}

@keyframes twinkle {
    0% { opacity: 0; }
    50% { opacity: var(--star-opacity); }
    100% { opacity: 0; }
}

.star.with-glow {
    box-shadow: 0 0 10px 2px rgba(255, 255, 255, 0.3);
}

/* =================
   HEADER Y NAVEGACIÓN
   ================= */

header {
    background-color: var(--color-blue-zone0);
    padding: 1rem 0;
    position: relative;
    z-index: 103;
    box-shadow: 0 2px 10px rgba(0, 0, 0, 0.3);
    backdrop-filter: blur(5px);
    border-bottom: 2px solid rgba(255, 127, 80, 0.3);
    width: 100%;
}

nav {
    max-width: 1200px;
    margin: 0 auto;
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 0 2rem;
    position: relative;
    overflow: visible;
    width: 100%;
    box-sizing: border-box;
}

.nav-logo {
    height: 40px;
    z-index: 102;
}

.nav-right {
    display: flex;
    align-items: center;
    gap: 3rem;
    position: relative;
    overflow: visible;
}

.nav-links {
    display: flex;
    gap: 2rem;
}

.nav-links a {
    color: var(--color-white);
    text-decoration: none;
    font-family: 'Raleway', sans-serif;
    font-weight: 600;
    font-size: 1rem;
    transition: all var(--transition-speed);
    position: relative;
    padding: 0.5rem 0;
}

.nav-links a::after {
    content: '';
    position: absolute;
    width: 0;
    height: 2px;
    bottom: 0;
    left: 0;
    background-color: var(--color-orange);
    transition: width var(--transition-speed);
}

.nav-links a:hover {
    color: var(--color-orange);
}

.nav-links a:hover::after {
    width: 100%;
}

/* Menú Hamburguesa */
.hamburger {
    display: none;
    flex-direction: column;
    cursor: pointer;
    padding: 0.5rem;
    z-index: 102;
    position: relative;
}

.hamburger span {
    width: 25px;
    height: 3px;
    background-color: var(--color-white);
    margin: 3px 0;
    transition: all 0.3s ease;
    border-radius: 2px;
}

.hamburger.active span:nth-child(1) {
    transform: rotate(-45deg) translate(-5px, 6px);
}

.hamburger.active span:nth-child(2) {
    opacity: 0;
}

.hamburger.active span:nth-child(3) {
    transform: rotate(45deg) translate(-5px, -6px);
}

/* Menú móvil */
.mobile-menu {
    position: fixed;
    top: 0;
    right: -100%;
    width: 300px;
    height: 100vh;
    background: var(--color-blue-zone1);
    transition: right 0.3s ease;
    z-index: 101;
    padding: 80px 2rem 2rem 2rem;
    box-shadow: -5px 0 15px rgba(0, 0, 0, 0.3);
}

.mobile-menu.show {
    right: 0;
}

.mobile-menu-overlay {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100vh;
    background: rgba(0, 0, 0, 0.5);
    opacity: 0;
    visibility: hidden;
    transition: all 0.3s ease;
    z-index: 100;
}

.mobile-menu-overlay.show {
    opacity: 1;
    visibility: visible;
}

.mobile-nav-links {
    display: flex;
    flex-direction: column;
    gap: 1.5rem;
    margin-bottom: 2rem;
}

.mobile-nav-links a {
    color: var(--color-white);
    text-decoration: none;
    font-family: 'Raleway', sans-serif;
    font-weight: 600;
    font-size: 1.1rem;
    padding: 1rem 0;
    border-bottom: 1px solid rgba(255, 255, 255, 0.1);
    transition: all var(--transition-speed);
    position: relative;
}

.mobile-nav-links a:hover {
    color: var(--color-orange);
    padding-left: 1rem;
}

.mobile-nav-links a::before {
    content: '→';
    position: absolute;
    left: -20px;
    opacity: 0;
    transition: all var(--transition-speed);
    color: var(--color-orange);
}

.mobile-nav-links a:hover::before {
    left: 0;
    opacity: 1;
}

/* Selector de idiomas en móvil */
.mobile-language-section {
    border-top: 2px solid var(--color-accent);
    padding-top: 1.5rem;
}

.mobile-language-title {
    color: var(--color-accent);
    font-family: 'Raleway', sans-serif;
    font-weight: 600;
    font-size: 1rem;
    margin-bottom: 1rem;
}

.mobile-language-options {
    display: flex;
    flex-direction: column;
    gap: 0.8rem;
}

.mobile-language-option {
    display: flex;
    align-items: center;
    gap: 0.8rem;
    padding: 0.8rem;
    color: var(--color-white);
    text-decoration: none;
    font-family: 'Raleway', sans-serif;
    font-weight: 500;
    font-size: 1rem;
    transition: all var(--transition-speed);
    border-radius: 8px;
    border: 2px solid transparent;
}

.mobile-language-option:hover {
    background: var(--color-blue-zone3);
    border-color: var(--color-accent);
}

.mobile-language-option.current {
    background: var(--color-accent);
    color: var(--color-blue-zone1);
    font-weight: 600;
}

/* Selector de idiomas */
.language-selector {
    position: relative;
    overflow: visible;
    z-index: 104;
}

.language-selector.active {
    z-index: 10000;
}

.language-button {
    background: var(--color-blue-zone3);
    border: 2px solid var(--color-accent);
    color: var(--color-white);
    padding: 0.5rem 1rem;
    border-radius: 8px;
    cursor: pointer;
    font-family: 'Raleway', sans-serif;
    font-weight: 600;
    font-size: 0.9rem;
    transition: all var(--transition-speed);
    display: flex;
    align-items: center;
    gap: 0.5rem;
    min-width: 80px;
    justify-content: center;
    position: relative;
    z-index: 105;
}

.language-button:hover {
    background: var(--color-accent);
    color: var(--color-blue-zone1);
    transform: translateY(-2px);
}

.language-button::after {
    content: '▼';
    font-size: 0.7rem;
    transition: transform var(--transition-speed);
}

.language-button.active::after {
    transform: rotate(180deg);
}

.language-dropdown {
    position: absolute;
    top: 100%;
    right: 0;
    background: var(--color-blue-zone2);
    border: 2px solid var(--color-accent);
    border-radius: 8px;
    margin-top: 0.5rem;
    opacity: 0;
    visibility: hidden;
    transform: translateY(-10px);
    transition: all var(--transition-speed);
    z-index: 9999;
    min-width: 120px;
    box-shadow: 0 5px 15px rgba(0, 0, 0, 0.3);
}

.language-dropdown.show {
    opacity: 1;
    visibility: visible;
    transform: translateY(0);
}

.language-option {
    display: flex;
    align-items: center;
    gap: 0.5rem;
    padding: 0.7rem 1rem;
    color: var(--color-white);
    text-decoration: none;
    font-family: 'Raleway', sans-serif;
    font-weight: 500;
    font-size: 0.9rem;
    transition: all var(--transition-speed);
    border-bottom: 1px solid rgba(255, 255, 255, 0.1);
}

.language-option:last-child {
    border-bottom: none;
}

.language-option:hover {
    background: var(--color-blue-zone3);
    color: var(--color-accent);
}

.language-option.current {
    background: var(--color-accent);
    color: var(--color-blue-zone1);
    font-weight: 600;
}

/* =================
   CONTENIDO PRINCIPAL
   ================= */
main {
    max-width: 1000px;
    margin: 0 auto;
    padding: 2rem 1rem;
}

/* =================
   TIPOGRAFÍA COMÚN
   ================= */
h1, h2, h3, h4, h5 {
    font-family: 'Raleway', sans-serif;
    margin-bottom: 1rem;
}

p {
    text-align: center;
    line-height: 1.6;
    margin-bottom: 1rem;
}

/* Título de sección común */
.section-title {
    text-align: center;
    color: var(--color-yellow);
    font-size: 2rem;
    margin-bottom: 2rem;
    position: relative;
    display: inline-block;
    left: 50%;
    transform: translateX(-50%);
}

/* Sección base común */
.base-section {
    max-width: 1000px;
    margin: 0 auto 3rem auto;
    padding: 2rem;
    background-color: var(--color-blue-zone2);
    border-radius: var(--border-radius);
    box-shadow: 0 5px 15px rgba(0, 0, 0, 0.2);
    position: relative;
    overflow: hidden;
}

.base-section::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 4px;
    background: linear-gradient(to right, var(--color-yellow), var(--color-accent));
}

/* Botones comunes */
.btn {
    background-color: var(--color-orange);
    color: var(--color-white);
    border: none;
    padding: 0.6rem 1.2rem;
    font-family: 'Raleway', sans-serif;
    font-weight: 600;
    font-size: 0.9rem;
    cursor: pointer;
    transition: all var(--transition-speed);
    border-radius: 5px;
    box-shadow: 0 3px 6px rgba(0, 0, 0, 0.1);
    text-decoration: none;
    display: inline-block;
    text-align: center;
}

.btn:hover {
    background-color: #FF9770;
    transform: translateY(-2px);
    box-shadow: 0 5px 10px rgba(0, 0, 0, 0.2);
}

.btn:active {
    transform: translateY(0);
}

/* Hero Section */
.hero-section {
    text-align: center;
    margin: 3rem 0 4rem 0;
}

.hero-content {
    max-width: 1000px;
    margin: 0 auto;
}

.hero-title {
    font-family: 'Raleway', sans-serif;
    font-size: 3rem;
    font-weight: 700;
    color: var(--color-yellow);
    margin-bottom: 1.5rem;
    text-shadow: 0 0 20px rgba(251, 249, 196, 0.3);
    position: relative;
    display: inline-block;
    width: 100%;
}

.hero-title::after {
    content: '';
    position: absolute;
    width: 120px;
    height: 4px;
    background: linear-gradient(to right, var(--color-yellow), var(--color-accent));
    bottom: -15px;
    left: 50%;
    transform: translateX(-50%);
}

.hero-subtitle {
    font-size: 1.1rem;
    color: var(--color-accent);
    line-height: 1.6;
    opacity: 0.9;
    margin-top: 2rem;
}

/* =================
   FOOTER
   ================= */
footer {
    background-color: var(--color-blue-zone1);
    border-top: 1px solid rgba(255, 255, 255, 0.1);
    padding: 2rem 0;
    margin-top: 3rem;
}

.footer-content {
    max-width: 1200px;
    margin: 0 auto;
    display: flex;
    flex-direction: column;
    align-items: center;
    padding: 0 1rem;
}

.social-links {
    display: flex;
    gap: 1rem;
    margin-bottom: 1.5rem;
}

.social-icon {
    display: flex;
    align-items: center;
    justify-content: center;
    width: 40px;
    height: 40px;
    border-radius: 50%;
    background-color: var(--color-blue-zone3);
    transition: all var(--transition-speed);
}

.social-icon:hover {
    transform: translateY(-3px);
}

.social-icon:nth-child(1):hover {
    background-color: #DC297A;
}

.social-icon:nth-child(2):hover {
    background-color: #14171a;
}

.social-icon:nth-child(3):hover {
    background-color: #1ed760;
}

.social-icon:nth-child(4):hover {
    background-color: #0a66c2;
}

.social-icon:nth-child(5):hover {
    background-color: #2A3036;
}

.social-icon svg {
    width: 20px;
    height: 20px;
    fill: var(--color-white);
}

.footer-contact {
    color: var(--color-white);
    margin-bottom: 0.5rem;
    font-size: 0.9rem;
}

.footer-contact a {
    color: var(--color-accent);
    text-decoration: none;
    transition: color var(--transition-speed);
}

.footer-contact a:hover {
    color: var(--color-orange);
}

.copyright {
    text-align: center;
    color: var(--color-white);
    opacity: 0.7;
    font-size: 0.85rem;
}

/* =================
   RESPONSIVE BASE
   ================= */
@media (max-width: 768px) {    
    body{
        overflow-x: hidden;
    }
    
    .nav-right {
        display: none;
    }
    
    .hamburger {
        display: flex;
    }

    main {
        padding: 1.5rem 1rem;
    }

    .base-section {
        padding: 1.5rem;
    }
}

@media (max-width: 480px) {
    nav {
        padding: 0 1rem;
    }

    main {
        padding: 1rem;
    }

    .base-section {
        padding: 1rem;
    }

    .section-title {
        font-size: 1.6rem;
    }
}