.features-stack {
    padding: 120px 0;
    background: linear-gradient(180deg, #ffffff 0%, #f0f9ff 50%, #e0f2fe 100%);
    position: relative;
}

.features-stack::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background-image: url("data:image/svg+xml,%3Csvg width='20' height='20' viewBox='0 0 20 20' xmlns='http://www.w3.org/2000/svg'%3E%3Cg fill='%233b82f6' fill-opacity='0.02' fill-rule='evenodd'%3E%3Ccircle cx='3' cy='3' r='3'/%3E%3Ccircle cx='13' cy='13' r='3'/%3E%3C/g%3E%3C/svg%3E");
    pointer-events: none;
}

.card-stack-container {
    margin-top: 80px;
}

.card-stack-stage {
    position: relative;
    width: 100%;
    height: 400px;
    perspective: 1100px;
}

.card-stack-spotlight {
    position: absolute;
    top: 24px;
    left: 50%;
    transform: translateX(-50%);
    width: 70%;
    height: 192px;
    background: rgba(0, 0, 0, 0.05);
    border-radius: 50%;
    filter: blur(48px);
    pointer-events: none;
}

.card-stack-shadow {
    position: absolute;
    bottom: 0;
    left: 50%;
    transform: translateX(-50%);
    width: 76%;
    height: 160px;
    background: rgba(0, 0, 0, 0.1);
    border-radius: 50%;
    filter: blur(48px);
    pointer-events: none;
}

.cards-wrapper {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    display: flex;
    align-items: end;
    justify-content: center;
}

.feature-stack-card {
    position: absolute;
    bottom: 0;
    width: 450px;
    height: 320px;
    background: rgba(255, 255, 255, 0.9);
    backdrop-filter: blur(10px);
    border: 4px solid rgba(0, 0, 0, 0.1);
    border-radius: 16px;
    padding: 30px;
    cursor: pointer;
    transition: transform 0.6s cubic-bezier(0.175, 0.885, 0.32, 1.275), opacity 0.6s ease;
    box-shadow: 0 25px 50px rgba(0, 0, 0, 0.15);
    transform-style: preserve-3d;
    will-change: transform;
    user-select: none;
    overflow: hidden;
}

.feature-stack-card.active {
    cursor: grab;
}

.feature-stack-card.active:active {
    cursor: grabbing;
}

.feature-stack-card::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: linear-gradient(135deg, rgba(30, 64, 175, 0.03), rgba(59, 130, 246, 0.03));
    border-radius: 12px;
    opacity: 0;
    transition: opacity 0.5s;
}

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

.feature-stack-card .feature-icon {
    width: 60px;
    height: 60px;
    border-radius: 14px;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 1.5rem;
    margin-bottom: 20px;
    box-shadow: 0 8px 25px rgba(30, 64, 175, 0.25);
    transition: transform 0.5s;
    color: white;
}

.feature-stack-card:hover .feature-icon {
    transform: scale(1.1) rotate(5deg);
}

.feature-stack-card h3 {
    font-size: 1.4rem;
    margin-bottom: 12px;
    font-weight: 700;
    color: #1e40af;
    line-height: 1.3;
}

.feature-stack-card p {
    color: #334155;
    line-height: 1.6;
    margin-bottom: 20px;
    font-size: 0.95rem;
}

.feature-stack-card .feature-badge {
    display: inline-block;
    background: rgba(30, 64, 175, 0.1);
    border: 1px solid rgba(30, 64, 175, 0.3);
    color: #1e40af;
    padding: 6px 14px;
    border-radius: 50px;
    font-size: 0.75rem;
    font-weight: 600;
}

.feature-stack-card .feature-badge.ai {
    background: rgba(59, 130, 246, 0.1);
    border-color: rgba(59, 130, 246, 0.3);
    color: #3b82f6;
}

.card-stack-dots {
    display: flex;
    justify-content: center;
    gap: 8px;
    margin-top: 24px;
}

.stack-dot {
    width: 8px;
    height: 8px;
    border-radius: 50%;
    border: none;
    background: rgba(15, 23, 42, 0.3);
    cursor: pointer;
    transition: all 0.3s;
}

.stack-dot.active {
    background: #0f172a;
}

.stack-dot:hover {
    background: rgba(15, 23, 42, 0.5);
}

/* Responsive */
@media (max-width: 768px) {
    .feature-stack-card {
        width: 320px;
        height: 240px;
        padding: 25px;
    }
    
    .feature-stack-card h3 {
        font-size: 1.2rem;
    }
    
    .feature-stack-card p {
        font-size: 0.9rem;
    }
    
    .feature-stack-card .feature-icon {
        width: 50px;
        height: 50px;
        font-size: 1.3rem;
    }
}