/* =========================================
   Variables Globales (Tema Oscuro/Verde)
   ========================================= */
:root {
    --bg-color: #0d1f18;
    /* Fondo principal oscuro */
    --text-color: #f0fdf4;
    /* Texto claro */
    --primary-color: #2d6a4f;
    /* Verde principal */
    --secondary-color: #52b788;
    /* Verde secundario */
    --accent-color: #95d5b2;
    /* Verde acento */
    --glass-bg: rgba(45, 106, 79, 0.1);
    /* Fondo para efecto vidrio */
    --glass-border: rgba(82, 183, 136, 0.2);
    /* Borde sutil para vidrio */
    --font-main: 'Outfit', sans-serif;
    /* TipografÃ­a principal */
}

/* =========================================
   Reset y Estilos Base
   ========================================= */
* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
    /* Manejo intuitivo del modelo de caja */
}

body {
    font-family: var(--font-main);
    background-color: var(--bg-color);
    color: var(--text-color);
    overflow-x: hidden;
    line-height: 1.6;
}

/* =========================================
   Fondo Animado Complejo
   ========================================= */
/* =========================================
   Fondo Animado Complejo
   ========================================= */
.background-gradient {
    position: fixed;
    top: 0;
    left: 0;
    width: 100vw;
    height: 100vh;
    /* Gradiente radial fondo base: crea la atmÃ³sfera oscura */
    background: radial-gradient(circle at 50% 50%, #1b4332 0%, #081c15 100%);
    z-index: -1;
    /* DetrÃ¡s de todo el contenido */
}

/* Orbes de luz decorativos (Pseudo-elementos) */
/* Orbe superior derecho */
.background-gradient::before {
    content: '';
    position: absolute;
    top: -20%;
    right: -10%;
    width: 600px;
    height: 600px;
    /* Gradiente azul con transparencia */
    background: radial-gradient(circle, rgba(59, 130, 246, 0.15) 0%, transparent 70%);
    border-radius: 50%;
    filter: blur(80px);
    /* Efecto difuso para suavizar bordes */
}

/* Orbe inferior izquierdo */
.background-gradient::after {
    content: '';
    position: absolute;
    bottom: -20%;
    left: -10%;
    width: 500px;
    height: 500px;
    /* Gradiente violeta con transparencia */
    background: radial-gradient(circle, rgba(139, 92, 246, 0.15) 0%, transparent 70%);
    border-radius: 50%;
    filter: blur(80px);
}

/* =========================================
   Header (NavegaciÃ³n) con Glassmorphism
   ========================================= */
/* Header */
.glass-header {
    background: rgba(15, 23, 42, 0.7);
    backdrop-filter: blur(12px);
    border-bottom: 1px solid var(--glass-border);
    position: fixed;
    width: 100%;
    top: 0;
    z-index: 1000;
    padding: 1.2rem 2rem;
}

nav {
    display: flex;
    justify-content: space-between;
    align-items: center;
    max-width: 1200px;
    margin: 0 auto;
}

.logo {
    font-size: 1.5rem;
    font-weight: 700;
    letter-spacing: 1px;
    background: linear-gradient(to right, var(--primary-color), var(--secondary-color));
    -webkit-background-clip: text;
    background-clip: text;
    color: transparent;
}

.nav-links {
    list-style: none;
    display: flex;
    gap: 2rem;
}

.nav-links a {
    color: var(--text-color);
    text-decoration: none;
    font-weight: 500;
    transition: color 0.3s ease;
}

.nav-links a:hover {
    color: var(--primary-color);
}

/* Hero Section */
/* Hero Section: Contenedor principal de la primera vista */
.hero-section {
    min-height: 100vh;
    /* Ocupa al menos toda la altura de la ventana */
    display: flex;
    align-items: center;
    /* Centrado vertical */
    justify-content: center;
    /* Centrado horizontal */
    padding: 2rem;
    max-width: 1200px;
    margin: 0 auto;
    /* Centrado del contenedor en la pÃ¡gina */
    position: relative;
}

.hero-content {
    flex: 1;
    /* Toma el espacio disponible equitativamente */
    z-index: 10;
    /* Asegura que el texto estÃ© sobre los elementos de fondo */
}

/* TÃ­tulo Principal */
h1 {
    font-size: 4rem;
    line-height: 1.1;
    margin-bottom: 1.5rem;
}

/* Texto con Gradiente: Efecto visual llamativo para destacar palabras clave */
.gradient-text {
    background: linear-gradient(135deg, var(--primary-color), var(--accent-color));
    -webkit-background-clip: text;
    /* Aplica el fondo solo al texto (Webkit) */
    background-clip: text;
    /* EstÃ¡ndar */
    color: transparent;
    /* Hace el texto transparente para mostrar el fondo */
}

.hero-content p {
    font-size: 1.25rem;
    color: #94a3b8;
    margin-bottom: 2.5rem;
    max-width: 500px;
}

.cta-group {
    display: flex;
    gap: 1rem;
}

.btn {
    padding: 1rem 2rem;
    border-radius: 30px;
    text-decoration: none;
    font-weight: 600;
    transition: all 0.3s ease;
    border: none;
    cursor: pointer;
}

.btn-primary {
    background: linear-gradient(135deg, var(--primary-color), var(--secondary-color));
    color: white;
    box-shadow: 0 4px 15px rgba(59, 130, 246, 0.4);
}

.btn-primary:hover {
    transform: translateY(-2px);
    box-shadow: 0 6px 20px rgba(59, 130, 246, 0.6);
}

.btn-secondary {
    background: transparent;
    border: 2px solid var(--glass-border);
    color: var(--text-color);
}

.btn-secondary:hover {
    background: var(--glass-bg);
    border-color: var(--primary-color);
}

/* Visuals */
.hero-visual {
    flex: 1;
    display: flex;
    justify-content: center;
    align-items: center;
}

.sphere {
    width: 300px;
    height: 300px;
    background: linear-gradient(135deg, rgba(59, 130, 246, 0.8), rgba(236, 72, 153, 0.8));
    border-radius: 50%;
    filter: blur(2px);
    box-shadow:
        inset 0 0 50px rgba(255, 255, 255, 0.2),
        0 0 50px rgba(59, 130, 246, 0.4);
    animation: pulse 4s infinite alternate;
}

@keyframes pulse {
    0% {
        transform: scale(1);
        box-shadow: 0 0 50px rgba(59, 130, 246, 0.4);
    }

    100% {
        transform: scale(1.05);
        box-shadow: 0 0 80px rgba(236, 72, 153, 0.5);
    }
}

/* Services */
.features-section {
    padding: 6rem 2rem;
    max-width: 1200px;
    margin: 0 auto;
}

.features-section h2 {
    text-align: center;
    font-size: 2.5rem;
    margin-bottom: 4rem;
}

/* Grid Layout para las tarjetas de servicios
   Responsive: crea columnas automÃ¡ticamente segÃºn el ancho disponible */
.grid-container {
    display: grid;
    /* minmax(300px, 1fr) asegura que las columnas tengan al menos 300px
       y se expandan para llenar el espacio restante */
    grid-template-columns: repeat(auto-fit, minmax(300px, 1fr));
    gap: 2rem;
    /* Espacio entre filas y columnas */
}

/* Efecto de tarjeta de vidrio (Glassmorphism) */
.glass-card {
    background: var(--glass-bg);
    border: 1px solid var(--glass-border);
    border-radius: 20px;
    padding: 2.5rem;
    transition: transform 0.3s ease, background 0.3s ease;
}

.glass-card:hover {
    transform: translateY(-10px);
    background: rgba(255, 255, 255, 0.08);
}

.icon {
    font-size: 3rem;
    margin-bottom: 1.5rem;
}

.glass-card h3 {
    font-size: 1.5rem;
    margin-bottom: 1rem;
    color: var(--text-color);
}

.glass-card p {
    color: #94a3b8;
}

/* Footer */
.glass-footer {
    text-align: center;
    padding: 2rem;
    border-top: 1px solid var(--glass-border);
    margin-top: 4rem;
    color: #64748b;
}

/* =========================================
   Animaciones Keyframes
   ========================================= */
/* Animations */
.animate-fade-in {
    animation: fadeIn 1s ease-out;
}

.animate-slide-up {
    animation: slideUp 1s ease-out;
}

.delay-200 {
    animation-delay: 0.2s;
    animation-fill-mode: backwards;
}

.animate-float {
    animation: float 6s ease-in-out infinite;
}

/* Animaciones Definidas:
   fadeIn: aparece suavemente desde transparencia total
   slideUp: aparece desde abajo hacia su posiciÃ³n original
   float: movimiento suave de levitaciÃ³n para elementos decorativos */
@keyframes fadeIn {
    from {
        opacity: 0;
    }

    to {
        opacity: 1;
    }
}

@keyframes slideUp {
    from {
        opacity: 0;
        transform: translateY(20px);
    }

    to {
        opacity: 1;
        transform: translateY(0);
    }
}

@keyframes float {
    0% {
        transform: translateY(0);
    }

    50% {
        transform: translateY(-20px);
    }

    100% {
        transform: translateY(0);
    }
}

/* Responsive */
@media (max-width: 768px) {
    .hero-section {
        flex-direction: column-reverse;
        text-align: center;
        padding-top: 6rem;
    }

    h1 {
        font-size: 2.5rem;
    }

    .cta-group {
        justify-content: center;
    }

    .nav-links {
        display: none;
    }
}

/* =========================================
   Galería de Imágenes
   ========================================= */
.gallery-section {
    padding: 6rem 2rem;
    max-width: 1200px;
    margin: 0 auto;
}

.gallery-section h2 {
    text-align: center;
    font-size: 2.5rem;
    margin-bottom: 1rem;
}

.gallery-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(300px, 1fr));
    gap: 1.5rem;
    padding: 1rem;
}

.gallery-item {
    border-radius: 15px;
    overflow: hidden;
    box-shadow: 0 4px 15px rgba(0, 0, 0, 0.3);
    border: 1px solid var(--glass-border);
    transition: transform 0.3s ease, box-shadow 0.3s ease;
    background: var(--glass-bg);
}

.gallery-item:hover {
    transform: translateY(-5px);
    box-shadow: 0 8px 25px rgba(45, 106, 79, 0.4);
}

.gallery-image-wrapper {
    position: relative;
    width: 100%;
    height: 250px;
    overflow: hidden;
}

.gallery-image-wrapper img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    transition: transform 0.5s ease;
}

.gallery-item:hover .gallery-image-wrapper img {
    transform: scale(1.1);
}

.gallery-overlay {
    position: absolute;
    bottom: 0;
    left: 0;
    width: 100%;
    background: linear-gradient(to top, rgba(13, 31, 24, 0.95), transparent);
    padding: 1.5rem;
    color: white;
    transform: translateY(100%);
    transition: transform 0.3s ease-in-out;
    display: flex;
    flex-direction: column;
    justify-content: flex-end;
}

.gallery-item:hover .gallery-overlay {
    transform: translateY(0);
}

.gallery-overlay h3 {
    font-size: 1.25rem;
    margin-bottom: 0.25rem;
    color: var(--secondary-color);
}

.gallery-overlay p {
    font-size: 0.9rem;
    color: #e2e8f0;
}
