/* CSS Document */



/* Variables CSS para colores y tamaños */
:root {
    --color-dark-blue: #0A192F;
    --color-medium-blue: #007bff; /* Un azul más vibrante para reflejos y highlights */
    --color-light-blue: #61DAFB;
    --color-accent-blue: #2196F3; /* Azul para el borde y el hover */
    --color-text-light: #E6E6E6;
    --color-text-dark: #333;
    --gradient-start: #0f2027; /* Azul oscuro casi negro */
    --gradient-mid: #203A43; /* Azul petróleo */
    --gradient-end: #2c5364; /* Azul más claro */
    --box-bg: rgba(255, 255, 255, 0.08); /* Fondo de caja semitransparente */
    --box-border: rgba(33, 150, 243, 0.5); /* Borde azul semitransparente */
    --button-bg-start: #1A708D;
    --button-bg-end: #0D47A1;
}

/* Estilos Generales y Reseteo */
* {
    box-sizing: border-box;
    margin: 0;
    padding: 0;
}

body {
    font-family: 'Poppins', sans-serif;
    color: var(--color-text-light);
    line-height: 1.6;
    min-height: 100vh;
    display: flex;
    flex-direction: column;
    overflow-x: hidden; /* Evita barras de desplazamiento horizontales por las olas */
    background: linear-gradient(135deg, var(--gradient-start) 0%, var(--gradient-mid) 50%, var(--gradient-end) 100%);
}

/* Fondo de Océano y Animación de Olas */
.ocean-background {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    overflow: hidden;
    z-index: -1; /* Asegura que esté detrás de todo el contenido */
    background: linear-gradient(180deg, #001f3f 0%, #003366 50%, #004d99 100%); /* Degradado más oscuro para el fondo marino */
}

.wave {
    position: absolute;
    bottom: 0;
    width: 200%; /* El doble de ancho para el efecto de onda */
    height: 100px;
    background: url('data:image/svg+xml;utf8,<svg viewBox="0 0 100 10" preserveAspectRatio="none" xmlns="http://www.w3.org/2000/svg"><path d="M0 5 Q 12.5 10 25 5 T 50 5 T 75 5 T 100 5 V 10 H 0 Z" fill="rgba(255,255,255,0.1)"></path></svg>') repeat-x; /* Onda SVG semitransparente */
    background-size: 50% 100%;
    animation: waveAnimation 30s cubic-bezier(0.5, 0.2, 0.5, 0.8) infinite;
    opacity: 0.7;
}

.wave#wave1 {
    opacity: 0.15;
    height: 150px;
    animation-duration: 25s;
    bottom: 0px;
    background-image: url('data:image/svg+xml;utf8,<svg viewBox="0 0 100 10" preserveAspectRatio="none" xmlns="http://www.w3.org/2000/svg"><path d="M0 5 Q 12.5 0 25 5 T 50 5 T 75 5 T 100 5 V 10 H 0 Z" fill="rgba(255,255,255,0.15)"></path></svg>');
}

.wave#wave2 {
    opacity: 0.25;
    height: 120px;
    animation-duration: 20s;
    animation-delay: -5s;
    bottom: 10px;
    background-image: url('data:image/svg+xml;utf8,<svg viewBox="0 0 100 10" preserveAspectRatio="none" xmlns="http://www.w3.org/2000/svg"><path d="M0 5 Q 12.5 10 25 5 T 50 5 T 75 5 T 100 5 V 10 H 0 Z" fill="rgba(255,255,255,0.25)"></path></svg>');
}

.wave#wave3 {
    opacity: 0.1;
    height: 180px;
    animation-duration: 35s;
    animation-delay: -10s;
    bottom: 0px;
    background-image: url('data:image/svg+xml;utf8,<svg viewBox="0 0 100 10" preserveAspectRatio="none" xmlns="http://www.w3.org/2000/svg"><path d="M0 5 Q 12.5 0 25 5 T 50 5 T 75 5 T 100 5 V 10 H 0 Z" fill="rgba(255,255,255,0.1)"></path></svg>');
}

.wave#wave4 {
    opacity: 0.3;
    height: 100px;
    animation-duration: 15s;
    animation-delay: -15s;
    bottom: 20px;
    background-image: url('data:image/svg+xml;utf8,<svg viewBox="0 0 100 10" preserveAspectRatio="none" xmlns="http://www.w3.org/2000/svg"><path d="M0 5 Q 12.5 10 25 5 T 50 5 T 75 5 T 100 5 V 10 H 0 Z" fill="rgba(255,255,255,0.3)"></path></svg>');
}

@keyframes waveAnimation {
    0% { transform: translateX(0); }
    100% { transform: translateX(-50%); } /* Mueve la onda la mitad de su ancho */
}

/* Encabezado */
.header-container {
    text-align: center;
    padding: 4rem 1rem 2rem;
    background: rgba(0, 0, 0, 0.3); /* Fondo semitransparente para el texto */
    backdrop-filter: blur(5px); /* Efecto de desenfoque detrás del texto */
    margin-bottom: 2rem;
    position: relative;
    z-index: 10;
    box-shadow: 0 4px 20px rgba(0, 0, 0, 0.3);
    border-bottom: 2px solid var(--color-accent-blue);
}

.header-container h1 {
    font-family: 'Montserrat', sans-serif;
    font-size: 3rem;
    margin-bottom: 0.5rem;
    color: var(--color-light-blue);
    text-shadow: 0 0 10px rgba(97, 218, 251, 0.7); /* Brillo azul */
}

.header-container p {
    font-size: 1.2rem;
    color: var(--color-text-light);
    max-width: 800px;
    margin: 0 auto;
}

/* Contenedor Principal (Cajas de Enlaces) */
.container {
    flex-grow: 1;
    width: 90%;
    max-width: 1200px;
    margin: 2rem auto;
    padding: 1rem;
    display: flex;
    flex-direction: column;
    gap: 2.5rem; /* Espacio entre categorías */
    position: relative;
    z-index: 5;
}

/* Cajas de Categorías */
.category-section {
    background: var(--box-bg); /* Fondo semitransparente para las cajas */
    backdrop-filter: blur(8px); /* Desenfoque del fondo */
    border-radius: 15px;
    padding: 2.5rem;
    border: 1px solid var(--box-border);
    box-shadow: 0 0 30px rgba(33, 150, 243, 0.3), /* Sombra azul que simula el reflejo */
                0 0 60px rgba(33, 150, 243, 0.2) inset; /* Reflejo interno */
    position: relative;
    overflow: hidden;
}

/* Efecto de 'agua' en las cajas */
.category-section::before {
    content: '';
    position: absolute;
    top: -50%;
    left: -50%;
    width: 200%;
    height: 200%;
    background: radial-gradient(circle at 50% 50%, rgba(97, 218, 251, 0.1) 0%, transparent 70%);
    animation: waterEffect 15s linear infinite;
    pointer-events: none;
    z-index: -1;
}

@keyframes waterEffect {
    0% { transform: translate(0, 0); opacity: 0.7; }
    50% { transform: translate(10%, 10%); opacity: 0.5; }
    100% { transform: translate(0, 0); opacity: 0.7; }
}


.category-section h2 {
    font-family: 'Montserrat', sans-serif;
    font-size: 2.2rem;
    color: var(--color-light-blue);
    text-align: center;
    margin-bottom: 2rem;
    text-shadow: 0 0 8px rgba(97, 218, 251, 0.6);
    position: relative;
}

.category-section h2::after {
    content: '';
    display: block;
    width: 60px;
    height: 3px;
    background: var(--color-accent-blue);
    margin: 1rem auto 0;
    border-radius: 2px;
}

.links-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(250px, 1fr));
    gap: 1.5rem;
    justify-content: center;
}

/* Botones de Enlace */
.link-button {
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    text-decoration: none;
    color: var(--color-text-light);
    background: linear-gradient(145deg, var(--button-bg-start), var(--button-bg-end));
    border: 2px solid var(--color-accent-blue);
    border-radius: 12px;
    padding: 1.5rem 1rem;
    font-size: 1.1rem;
    font-weight: 600;
    text-align: center;
    transition: all 0.3s ease;
    box-shadow: 0 5px 20px rgba(0, 0, 0, 0.4),
                0 0 15px rgba(33, 150, 243, 0.3) inset; /* Reflejo interno azul */
    position: relative;
    overflow: hidden;
}

.link-button:hover {
    transform: translateY(-5px) scale(1.02);
    box-shadow: 0 10px 30px rgba(0, 0, 0, 0.6),
                0 0 25px var(--color-light-blue) inset;
    border-color: var(--color-light-blue);
    background: linear-gradient(145deg, var(--button-bg-end), var(--button-bg-start)); /* Invertir el gradiente al pasar el ratón */
}

.link-button::before {
    content: '';
    position: absolute;
    top: 0;
    left: -100%;
    width: 100%;
    height: 100%;
    background: rgba(255, 255, 255, 0.1);
    transform: skewX(-30deg);
    transition: all 0.5s ease;
}

.link-button:hover::before {
    left: 100%;
}

.link-button strong {
    margin-bottom: 0.5rem;
    display: block;
    color: var(--color-light-blue);
}

.link-button span {
    font-size: 0.9rem;
    color: rgba(255, 255, 255, 0.8);
}


/* Pie de Página */
.footer-container {
    text-align: center;
    padding: 2rem 1rem;
    margin-top: 3rem;
    background: rgba(0, 0, 0, 0.3);
    backdrop-filter: blur(5px);
    border-top: 1px solid var(--box-border);
    position: relative;
    z-index: 10;
}

.footer-container p {
    font-size: 0.9rem;
    color: rgba(255, 255, 255, 0.7);
}

/* Media Queries para Responsividad */
@media (max-width: 768px) {
    .header-container h1 {
        font-size: 2.2rem;
    }

    .header-container p {
        font-size: 1rem;
    }

    .category-section {
        padding: 2rem 1.5rem;
    }

    .category-section h2 {
        font-size: 1.8rem;
    }

    .links-grid {
        grid-template-columns: 1fr; /* Una columna en pantallas pequeñas */
        gap: 1rem;
    }

    .link-button {
        padding: 1.2rem 1rem;
        font-size: 1rem;
    }
}

@media (max-width: 480px) {
    .header-container {
        padding: 3rem 1rem 1.5rem;
    }
    .header-container h1 {
        font-size: 1.8rem;
    }
    .container {
        width: 95%;
        margin-top: 1.5rem;
        gap: 2rem;
    }
    .category-section {
        padding: 1.5rem 1rem;
    }
    .category-section h2 {
        font-size: 1.5rem;
    }
}

/* Efecto Hover en Botones (Para dispositivos táctiles) */
@media (hover: none) {
    .link-button:hover {
        transform: none;
        box-shadow: 0 5px 20px rgba(0, 0, 0, 0.4),
                    0 0 15px rgba(33, 150, 243, 0.3) inset;
        border-color: var(--color-accent-blue);
        background: linear-gradient(145deg, var(--button-bg-start), var(--button-bg-end));
    }
    .link-button::before {
        display: none;
    }
}