.features-section {
    background-color: #062831;
    background: radial-gradient(circle at 50% 20%, #083744 0%, #062831 60%, #03151a 100%);
    color: #ffffff;
    padding: 20px 24px;
    font-family: 'Inter', system-ui, -apple-system, sans-serif;
    position: relative;
    overflow: hidden;
}

/* Malla 3D con animación */
.features-section .grid-perspective {
    position: absolute;
    width: 200%;
    height: 120%;
    top: -10%;
    left: -50%;
    background-image:
        linear-gradient(rgba(56, 189, 248, 0.08) 1px, transparent 1px),
        linear-gradient(90deg, rgba(56, 189, 248, 0.08) 1px, transparent 1px);
    background-size: 60px 60px;
    transform: perspective(600px) rotateX(60deg);
    transform-origin: top;
    animation: gridMove 25s linear infinite;
    z-index: 1;
    pointer-events: none;
    /* Máscara para suavizar los bordes superior e inferior de la malla */
    mask-image: linear-gradient(180deg, transparent 0%, rgba(0, 0, 0, 0.8) 30%, rgba(0, 0, 0, 0.8) 70%, transparent 100%);
    -webkit-mask-image: linear-gradient(180deg, transparent 0%, rgba(0, 0, 0, 0.8) 30%, rgba(0, 0, 0, 0.8) 70%, transparent 100%);
}

/* Orbe ambiental para mayor profundidad */
.features-section .glow-orb {
    position: absolute;
    top: 20%;
    left: 50%;
    transform: translate(-50%, -50%);
    width: 600px;
    height: 600px;
    background: radial-gradient(circle, rgba(56, 189, 248, 0.12) 0%, transparent 70%);
    z-index: 1;
    pointer-events: none;
    filter: blur(50px);
}

/* Animación del movimiento continuo de la red */
@keyframes gridMove {
    0% {
        background-position: 0 0;
    }

    100% {
        background-position: 0 60px;
    }
}

/* Garantiza que todo el contenido quede sobre la malla */
.features-container {
    max-width: 1280px;
    margin: 0 auto;
    position: relative;
    z-index: 2;
}

.features-header {
    text-align: center;
    margin-bottom: 64px;
}

.features-header .badge {
    display: inline-block;
    background: rgba(124, 224, 242, 0.1);
    color: #7ce0f2;
    border: 1px solid rgba(124, 224, 242, 0.2);
    padding: 6px 16px;
    border-radius: 20px;
    font-size: 0.8rem;
    font-weight: 500;
    margin-bottom: 16px;
    letter-spacing: 0.5px;
}

.features-header h2 {
    font-size: 2.5rem;
    font-weight: 700;
    letter-spacing: -1px;
    max-width: 700px;
    margin: 0 auto;
    line-height: 1.2;
}

/* Grid Layout */
.features-grid {
    display: grid;
    grid-template-columns: repeat(4, 1fr);
    gap: 24px;
}

/* Base Card Style */
.feature-card {
    position: relative;
    height: 480px;
    border-radius: 28px;
    overflow: hidden;
    display: flex;
    align-items: flex-end;
    padding: 32px 24px;
    box-sizing: border-box;
    cursor: pointer;
    border: 1px solid rgba(255, 255, 255, 0.08);
    transition: transform 0.4s cubic-bezier(0.16, 1, 0.3, 1), border-color 0.4s ease, box-shadow 0.4s ease;
}

/* Imagen de fondo */
.card-bg {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background-size: cover;
    background-position: center;
    filter: grayscale(30%);
    transition: transform 0.6s cubic-bezier(0.16, 1, 0.3, 1), filter 0.6s ease;
    z-index: 1;
}

/* Gradiente para asegurar legibilidad */
.card-overlay {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: linear-gradient(180deg,
            rgba(9, 17, 20, 0.1) 0%,
            rgba(9, 17, 20, 0.6) 50%,
            rgba(9, 17, 20, 0.95) 100%);
    z-index: 2;
    transition: opacity 0.4s ease;
}

/* Contenido */
.card-content {
    position: relative;
    z-index: 3;
    transform: translateY(0);
    transition: transform 0.4s ease;
}

.card-content h3 {
    font-size: 1.35rem;
    font-weight: 600;
    margin: 0 0 12px 0;
    line-height: 1.3;
    color: #ffffff;
    letter-spacing: -0.3px;
}

.card-content p {
    font-size: 0.9rem;
    color: rgba(255, 255, 255, 0.75);
    line-height: 1.55;
    margin: 0;
    font-weight: 300;
}

/* Hover Effects */
.feature-card:hover {
    transform: translateY(-8px);
    border-color: rgba(124, 224, 242, 0.4);
    box-shadow: 0 20px 40px rgba(0, 0, 0, 0.6), 0 0 20px rgba(124, 224, 242, 0.15);
}

.feature-card:hover .card-bg {
    transform: scale(1.08);
    filter: grayscale(0%);
}

.feature-card:hover .card-content h3 {
    color: #7ce0f2;
}

/* Responsivo */
@media (max-width: 1024px) {
    .features-grid {
        grid-template-columns: repeat(2, 1fr);
    }
}

@media (max-width: 600px) {
    .features-grid {
        grid-template-columns: 1fr;
    }

    .features-header h2 {
        font-size: 1.8rem;
    }

    .feature-card {
        height: 400px;
    }
}