/* Features Section - Elegant Redesign */
.features {
    padding: 100px 0;
    background: linear-gradient(135deg, #0a1628 0%, #162238 100%);
    position: relative;
    overflow: hidden;
}

.features::before {
    content: '';
    position: absolute;
    top: -50%;
    right: -50%;
    width: 200%;
    height: 200%;
    background: radial-gradient(circle, rgba(0, 212, 170, 0.05) 0%, transparent 70%);
    animation: rotate 30s linear infinite;
}

@keyframes rotate {
    from { transform: rotate(0deg); }
    to { transform: rotate(360deg); }
}

.features-header {
    text-align: center;
    margin-bottom: 60px;
    position: relative;
    z-index: 2;
}

.section-title {
    font-size: 3rem;
    font-weight: 800;
    background: linear-gradient(90deg, #00d4aa, #ffd700);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
    margin-bottom: 20px;
}

.section-subtitle {
    font-size: 1.2rem;
    color: rgba(255, 255, 255, 0.7);
    max-width: 600px;
    margin: 0 auto;
}

/* Features Grid - Complex Layout */
.features-grid {
    display: grid;
    grid-template-columns: repeat(6, 1fr);
    gap: 24px;
    position: relative;
    z-index: 2;
}

/* Feature Card Base */
.feature-card {
    position: relative;
    border-radius: 24px;
    overflow: hidden;
    background: #1a2332;
    transition: all 0.4s cubic-bezier(0.175, 0.885, 0.32, 1.275);
    cursor: pointer;
    display: flex;
    align-items: flex-end;
}

.feature-card:hover {
    transform: translateY(-10px) scale(1.02);
    box-shadow: 0 30px 60px rgba(0, 212, 170, 0.3);
}

/* Feature Overlay */
.feature-overlay {
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: linear-gradient(180deg,
        rgba(10, 22, 40, 0.2) 0%,
        rgba(10, 22, 40, 0.7) 50%,
        rgba(10, 22, 40, 0.95) 100%);
    transition: all 0.4s ease;
}

.feature-card:hover .feature-overlay {
    background: linear-gradient(180deg,
        rgba(0, 212, 170, 0.1) 0%,
        rgba(10, 22, 40, 0.8) 50%,
        rgba(10, 22, 40, 0.95) 100%);
}

/* Feature Content */
.feature-content {
    position: relative;
    z-index: 2;
    padding: 30px;
    width: 100%;
}

/* Feature Badge */
.feature-badge {
    position: absolute;
    top: 20px;
    right: 20px;
    background: linear-gradient(135deg, #00d4aa, #00a884);
    color: white;
    padding: 6px 12px;
    border-radius: 20px;
    font-size: 0.7rem;
    font-weight: 700;
    letter-spacing: 1px;
    animation: pulse 2s infinite;
}

/* Feature Icon */
.feature-icon-wrapper {
    width: 60px;
    height: 60px;
    background: rgba(0, 212, 170, 0.2);
    border: 2px solid rgba(0, 212, 170, 0.3);
    border-radius: 20px;
    display: flex;
    align-items: center;
    justify-content: center;
    margin-bottom: 20px;
    transition: all 0.3s ease;
}

.feature-card:hover .feature-icon-wrapper {
    background: rgba(0, 212, 170, 0.3);
    border-color: #00d4aa;
    transform: rotate(10deg) scale(1.1);
}

.feature-icon {
    font-size: 1.8rem;
    filter: drop-shadow(0 0 10px rgba(0, 212, 170, 0.5));
}

.feature-card h3 {
    color: white;
    font-size: 1.4rem;
    font-weight: 700;
    margin-bottom: 12px;
}

.feature-card p {
    color: rgba(255, 255, 255, 0.7);
    font-size: 0.95rem;
    line-height: 1.5;
}

/* Feature Stats */
.feature-stats {
    display: flex;
    gap: 15px;
    margin-top: 20px;
    flex-wrap: wrap;
}

.feature-stats span {
    display: inline-flex;
    align-items: center;
    gap: 5px;
    padding: 6px 12px;
    background: rgba(255, 255, 255, 0.1);
    border-radius: 15px;
    font-size: 0.85rem;
    color: rgba(255, 255, 255, 0.8);
}

/* Feature Tag */
.feature-tag {
    display: inline-block;
    margin-top: 15px;
    padding: 6px 12px;
    background: rgba(255, 215, 0, 0.2);
    border: 1px solid rgba(255, 215, 0, 0.3);
    border-radius: 15px;
    color: #ffd700;
    font-size: 0.85rem;
    font-weight: 600;
}

/* Large Feature Cards (2x2) */
.feature-large {
    grid-column: span 2;
    grid-row: span 2;
    min-height: 400px;
    background-size: cover;
    background-position: center;
}

.feature-large .feature-content {
    padding: 40px;
}

.feature-large h3 {
    font-size: 1.8rem;
}

.feature-large p {
    font-size: 1.05rem;
}

/* Medium Feature Cards (2x1) */
.feature-medium {
    grid-column: span 2;
    min-height: 200px;
    background-size: cover;
    background-position: center;
}

/* Small Feature Cards (1x1) */
.feature-small {
    grid-column: span 1;
    min-height: 180px;
}

.feature-small .feature-content {
    padding: 20px;
}

.feature-small .feature-icon-wrapper {
    width: 50px;
    height: 50px;
    margin-bottom: 15px;
}

.feature-small .feature-icon {
    font-size: 1.5rem;
}

.feature-small h3 {
    font-size: 1.1rem;
}

.feature-small p {
    font-size: 0.85rem;
}

/* Full Width Feature Card */
.feature-full {
    grid-column: span 6;
    min-height: 300px;
    background-size: cover;
    background-position: center;
}

.feature-full .feature-content {
    display: flex;
    flex-direction: column;
    align-items: center;
    text-align: center;
    padding: 50px;
}

.feature-full h3 {
    font-size: 2rem;
    margin-bottom: 20px;
}

.feature-full p {
    font-size: 1.1rem;
    max-width: 700px;
}

.feature-full .feature-stats {
    justify-content: center;
    margin-top: 30px;
}

/* Feature Gradient Background */
.feature-gradient {
    width: 100%;
    height: 100%;
    padding: 20px;
    display: flex;
    flex-direction: column;
    justify-content: flex-end;
    position: relative;
}

.feature-gradient .feature-icon-wrapper {
    background: rgba(255, 255, 255, 0.2);
    border-color: rgba(255, 255, 255, 0.3);
}

/* Hover Effects */
.feature-card::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: radial-gradient(circle at var(--x, 50%) var(--y, 50%),
        rgba(0, 212, 170, 0.3) 0%,
        transparent 50%);
    opacity: 0;
    transition: opacity 0.3s ease;
    pointer-events: none;
}

.feature-card:hover::before {
    opacity: 1;
}

/* Responsive Design */
@media (max-width: 1200px) {
    .features-grid {
        grid-template-columns: repeat(4, 1fr);
    }

    .feature-large {
        grid-column: span 2;
    }

    .feature-full {
        grid-column: span 4;
    }
}

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

    .feature-card {
        grid-column: span 1 !important;
        grid-row: span 1 !important;
        min-height: 250px;
    }

    .feature-large,
    .feature-medium,
    .feature-small,
    .feature-full {
        grid-column: span 1;
        min-height: 250px;
    }

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

    .feature-content {
        padding: 25px;
    }
}

/* Animation Classes */
.feature-card {
    animation: fadeInUp 0.6s ease-out forwards;
    opacity: 0;
}

.feature-card:nth-child(1) { animation-delay: 0.1s; }
.feature-card:nth-child(2) { animation-delay: 0.2s; }
.feature-card:nth-child(3) { animation-delay: 0.3s; }
.feature-card:nth-child(4) { animation-delay: 0.4s; }
.feature-card:nth-child(5) { animation-delay: 0.5s; }
.feature-card:nth-child(6) { animation-delay: 0.6s; }
.feature-card:nth-child(7) { animation-delay: 0.7s; }
.feature-card:nth-child(8) { animation-delay: 0.8s; }
.feature-card:nth-child(9) { animation-delay: 0.9s; }
.feature-card:nth-child(10) { animation-delay: 1.0s; }
.feature-card:nth-child(11) { animation-delay: 1.1s; }

@keyframes fadeInUp {
    from {
        opacity: 0;
        transform: translateY(30px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

@keyframes pulse {
    0%, 100% {
        transform: scale(1);
        opacity: 1;
    }
    50% {
        transform: scale(1.05);
        opacity: 0.8;
    }
}