/* Enhanced Feature Cards - Desktop-First Design */

.features {
    padding: 6rem 0;
    background: linear-gradient(135deg, rgba(15, 23, 42, 0.95) 0%, rgba(30, 41, 59, 0.95) 100%);
    position: relative;
    overflow: hidden;
}

.features::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: url('data:image/svg+xml,<svg xmlns="http://www.w3.org/2000/svg" viewBox="0 0 100 100"><defs><pattern id="grid" width="10" height="10" patternUnits="userSpaceOnUse"><path d="M 10 0 L 0 0 0 10" fill="none" stroke="rgba(255,255,255,0.03)" stroke-width="0.5"/></pattern></defs><rect width="100%" height="100%" fill="url(%23grid)"/></svg>');
    opacity: 0.3;
}

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

.section-title {
    font-size: clamp(2.5rem, 4vw, 3.5rem);
    font-weight: 700;
    color: var(--text-primary);
    margin-bottom: 1rem;
    line-height: 1.2;
    background: linear-gradient(135deg, #E2E8F0 0%, #CBD5E1 100%);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
}

.section-subtitle {
    font-size: clamp(1.1rem, 2vw, 1.3rem);
    color: var(--text-secondary);
    max-width: 600px;
    margin: 0 auto;
    line-height: 1.6;
}

.features-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(380px, 1fr));
    gap: 2.5rem;
    max-width: 1400px;
    margin: 0 auto;
    position: relative;
    z-index: 2;
}

.feature-card {
    background: rgba(255, 255, 255, 0.05);
    border: 1px solid rgba(255, 255, 255, 0.1);
    border-radius: 1.5rem;
    padding: 2.5rem;
    position: relative;
    transition: all 0.4s cubic-bezier(0.4, 0, 0.2, 1);
    backdrop-filter: blur(10px);
    overflow: hidden;
    cursor: pointer;
    transform: translateY(0);
}

.feature-card::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: linear-gradient(135deg, rgba(255, 255, 255, 0.1) 0%, rgba(255, 255, 255, 0.05) 100%);
    opacity: 0;
    transition: opacity 0.3s ease;
}

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

.feature-card:hover {
    transform: translateY(-8px);
    border-color: rgba(255, 255, 255, 0.2);
    box-shadow: 
        0 25px 50px -12px rgba(0, 0, 0, 0.25),
        0 0 0 1px rgba(255, 255, 255, 0.1),
        0 0 50px rgba(255, 107, 107, 0.15);
}

.featured-card {
    background: linear-gradient(135deg, rgba(255, 107, 107, 0.1) 0%, rgba(76, 175, 80, 0.1) 100%);
    border-color: rgba(255, 107, 107, 0.3);
}

.featured-card:hover {
    box-shadow: 
        0 25px 50px -12px rgba(0, 0, 0, 0.25),
        0 0 0 1px rgba(255, 107, 107, 0.3),
        0 0 50px rgba(255, 107, 107, 0.2);
}

.feature-icon {
    width: 80px;
    height: 80px;
    background: linear-gradient(135deg, rgba(255, 107, 107, 0.2) 0%, rgba(76, 175, 80, 0.2) 100%);
    border-radius: 1.5rem;
    display: flex;
    align-items: center;
    justify-content: center;
    margin-bottom: 1.5rem;
    transition: all 0.3s ease;
    position: relative;
    overflow: hidden;
}

.feature-icon::before {
    content: '';
    position: absolute;
    top: 50%;
    left: 50%;
    width: 120%;
    height: 120%;
    background: radial-gradient(circle, rgba(255, 107, 107, 0.3) 0%, transparent 70%);
    transform: translate(-50%, -50%) scale(0);
    transition: transform 0.3s ease;
}

.feature-card:hover .feature-icon::before {
    transform: translate(-50%, -50%) scale(1);
}

.icon-svg {
    width: 32px;
    height: 32px;
    color: #FF6B6B;
    z-index: 1;
    transition: all 0.3s ease;
}

.feature-card:hover .icon-svg {
    transform: scale(1.1);
    color: #FF5252;
}

.feature-card h3 {
    font-size: 1.5rem;
    font-weight: 700;
    color: var(--text-primary);
    margin-bottom: 1rem;
    line-height: 1.3;
    transition: color 0.3s ease;
}

.feature-card:hover h3 {
    color: #FFFFFF;
}

.feature-card p {
    font-size: 1.1rem;
    color: var(--text-secondary);
    line-height: 1.6;
    margin-bottom: 1.5rem;
    transition: color 0.3s ease;
}

.feature-card:hover p {
    color: var(--text-primary);
}

/* Interactive Feature Elements */
.feature-example {
    background: rgba(255, 255, 255, 0.05);
    border: 1px solid rgba(255, 255, 255, 0.1);
    border-radius: 0.75rem;
    padding: 1rem;
    margin-top: 1.5rem;
    transition: all 0.3s ease;
}

.example-tag {
    display: inline-block;
    background: linear-gradient(135deg, #FF6B6B, #FF5252);
    color: white;
    padding: 0.25rem 0.75rem;
    border-radius: 1rem;
    font-size: 0.8rem;
    font-weight: 600;
    margin-bottom: 0.5rem;
}

.example-text {
    display: block;
    font-style: italic;
    color: var(--text-secondary);
    font-size: 0.95rem;
}

.feature-demo {
    display: flex;
    flex-direction: column;
    gap: 1rem;
    margin-top: 1.5rem;
}

.demo-btn {
    background: linear-gradient(135deg, #FF6B6B, #FF5252);
    color: white;
    border: none;
    padding: 0.75rem 1.5rem;
    border-radius: 0.75rem;
    font-weight: 600;
    cursor: pointer;
    transition: all 0.3s ease;
    transform: scale(1);
}

.demo-btn:hover {
    transform: scale(1.05);
    box-shadow: 0 8px 25px rgba(255, 107, 107, 0.4);
}

.demo-celebration {
    text-align: center;
    color: #4CAF50;
    font-weight: 600;
    opacity: 0;
    transform: translateY(10px);
    animation: fadeInUp 0.6s ease forwards;
}

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

.feature-progress {
    margin-top: 1.5rem;
}

.streak-counter {
    font-size: 1.2rem;
    font-weight: 700;
    color: #FF6B6B;
    margin-bottom: 0.5rem;
}

.progress-bar {
    height: 8px;
    background: rgba(255, 255, 255, 0.1);
    border-radius: 4px;
    overflow: hidden;
}

.progress-fill {
    height: 100%;
    background: linear-gradient(90deg, #FF6B6B, #4CAF50);
    border-radius: 4px;
    transition: width 0.3s ease;
}

.progress-insights {
    margin-top: 0.5rem;
    text-align: center;
}

.progress-insights small {
    color: var(--text-tertiary);
    font-size: 0.8rem;
    font-style: italic;
}

.feature-script {
    margin-top: 1.5rem;
}

.script-bubble {
    background: rgba(255, 255, 255, 0.08);
    border: 1px solid rgba(255, 255, 255, 0.15);
    border-radius: 1rem;
    padding: 1rem;
    position: relative;
    font-style: italic;
    color: var(--text-primary);
    line-height: 1.5;
}

.script-bubble::before {
    content: '"';
    position: absolute;
    top: -10px;
    left: 15px;
    font-size: 2rem;
    color: #FF6B6B;
}

.feature-stats {
    display: flex;
    gap: 1rem;
    margin-top: 1.5rem;
    flex-wrap: wrap;
}

.testimonials-list {
    display: flex;
    flex-direction: column;
    gap: 1.5rem;
    margin-top: 2.5rem;
    max-width: 800px;
    margin-left: auto;
    margin-right: auto;
}

@media (max-width: 768px) {
    .testimonials-list {
        gap: 1.2rem;
        margin-top: 2rem;
        padding: 0 1rem;
    }
    
    .testimonial-quote {
        font-size: 1.1rem;
        padding: 2rem;
    }
}

.testimonial-quote {
    font-size: 1.3rem;
    font-weight: 400;
    color: var(--text-primary);
    line-height: 1.6;
    padding: 2.5rem 3rem;
    background: rgba(255, 255, 255, 0.04);
    border-left: 3px solid #3B82F6;
    border-radius: 0 1rem 1rem 0;
    position: relative;
    transition: all 0.3s ease;
    font-style: italic;
}

.testimonial-quote::before {
    content: '"';
    position: absolute;
    left: 1rem;
    top: 0.5rem;
    font-size: 3rem;
    color: rgba(59, 130, 246, 0.3);
    line-height: 1;
    font-family: serif;
}

.testimonial-quote:hover {
    background: rgba(255, 255, 255, 0.06);
    border-left-color: #8B5CF6;
    transform: translateX(5px);
}

.testimonial-quote:nth-child(even) {
    border-left: none;
    border-right: 3px solid #8B5CF6;
    border-radius: 1rem 0 0 1rem;
    text-align: right;
}

.testimonial-quote:nth-child(even)::before {
    left: auto;
    right: 1rem;
}

.testimonial-quote:nth-child(even):hover {
    border-right-color: #3B82F6;
    transform: translateX(-5px);
}

/* Legacy stats grid - keeping for backward compatibility */
.stat-item {
    flex: 1;
    min-width: 80px;
    text-align: center;
    padding: 0.75rem;
    background: rgba(255, 255, 255, 0.05);
    border-radius: 0.75rem;
    border: 1px solid rgba(255, 255, 255, 0.1);
    transition: all 0.3s ease;
}

.stat-item:hover {
    background: rgba(255, 255, 255, 0.08);
    transform: translateY(-2px);
}

.stat-number {
    display: block;
    font-size: 1.5rem;
    font-weight: 700;
    color: #FF6B6B;
}

.stat-label {
    display: block;
    font-size: 0.9rem;
    color: var(--text-secondary);
    margin-top: 0.25rem;
}

.feature-personalization {
    margin-top: 1.5rem;
}

.personal-tags {
    display: flex;
    flex-wrap: wrap;
    gap: 0.5rem;
}

.tag {
    background: linear-gradient(135deg, rgba(255, 107, 107, 0.2), rgba(76, 175, 80, 0.2));
    color: var(--text-primary);
    padding: 0.5rem 1rem;
    border-radius: 1rem;
    font-size: 0.85rem;
    font-weight: 600;
    border: 1px solid rgba(255, 255, 255, 0.1);
    transition: all 0.3s ease;
}

.tag:hover {
    transform: translateY(-2px);
    box-shadow: 0 4px 12px rgba(255, 107, 107, 0.3);
}

/* Responsive Design */
@media (max-width: 768px) {
    .features-grid {
        grid-template-columns: 1fr;
        gap: 1.5rem;
    }
    
    .feature-card {
        padding: 2rem;
    }
    
    .feature-icon {
        width: 60px;
        height: 60px;
    }
    
    .icon-svg {
        width: 24px;
        height: 24px;
    }
    
    .feature-stats {
        flex-direction: column;
        gap: 1rem;
    }
    
    .personal-tags {
        justify-content: center;
    }
}

/* Animation on scroll */
@media (prefers-reduced-motion: no-preference) {
    .feature-card {
        animation: slideInUp 0.6s ease forwards;
        opacity: 0;
        transform: translateY(30px);
    }
    
    .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; }
    
    @keyframes slideInUp {
        to {
            opacity: 1;
            transform: translateY(0);
        }
    }
}

/* Analytics Preview Section */
.analytics-preview {
    padding: 5rem 0;
    background: linear-gradient(135deg, rgba(139, 92, 246, 0.1) 0%, rgba(59, 130, 246, 0.1) 100%);
    border-top: 1px solid rgba(255, 255, 255, 0.1);
}

.analytics-header {
    text-align: center;
    margin-bottom: 3rem;
}

.analytics-header h2 {
    font-size: clamp(1.5rem, 2.8vw, 2.2rem);
    font-weight: 700;
    color: var(--text-primary);
    margin-bottom: 1rem;
    background: linear-gradient(135deg, #8B5CF6 0%, #3B82F6 100%);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
}

.analytics-header p {
    font-size: clamp(0.95rem, 2vw, 1.05rem);
    color: var(--text-secondary);
    max-width: 600px;
    margin: 0 auto;
    line-height: 1.5;
}

.analytics-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(280px, 1fr));
    gap: 2rem;
    max-width: 1200px;
    margin: 0 auto;
}

.analytics-card {
    background: rgba(255, 255, 255, 0.03);
    border: 1px solid rgba(255, 255, 255, 0.08);
    border-radius: 1rem;
    padding: 2rem;
    text-align: center;
    transition: all 0.3s ease;
    backdrop-filter: blur(10px);
}

.analytics-card:hover {
    transform: translateY(-5px);
    border-color: rgba(139, 92, 246, 0.3);
    box-shadow: 0 15px 35px rgba(139, 92, 246, 0.1);
}

.analytics-icon {
    font-size: 2.5rem;
    margin-bottom: 1rem;
    display: block;
}

.analytics-card h4 {
    font-size: 1.25rem;
    font-weight: 600;
    color: var(--text-primary);
    margin-bottom: 1rem;
}

.analytics-card p {
    color: var(--text-secondary);
    line-height: 1.6;
    font-size: 0.95rem;
}

/* Desktop-specific enhancements */
@media (min-width: 1200px) {
    .features-grid {
        grid-template-columns: repeat(3, 1fr);
        gap: 3rem;
    }
    
    .feature-card {
        padding: 3rem;
    }
    
    .feature-icon {
        width: 100px;
        height: 100px;
    }
    
    .icon-svg {
        width: 40px;
        height: 40px;
    }
    
    .feature-card h3 {
        font-size: 1.75rem;
    }
    
    .feature-card p {
        font-size: 1.15rem;
    }
    
    .analytics-grid {
        grid-template-columns: repeat(4, 1fr);
        gap: 2.5rem;
    }
}

/* Guide Link Styling */
.feature-guide-link {
    margin-top: 1.5rem;
    padding-top: 1.5rem;
    border-top: 1px solid rgba(255, 255, 255, 0.1);
}

.guide-link {
    display: inline-flex;
    align-items: center;
    gap: 0.5rem;
    color: var(--primary-color);
    text-decoration: none;
    font-weight: 500;
    font-size: 0.95rem;
    transition: all 0.3s ease;
    padding: 0.5rem 0;
    border-radius: 0.5rem;
    position: relative;
    overflow: hidden;
}

.guide-link::before {
    content: '';
    position: absolute;
    top: 0;
    left: -100%;
    width: 100%;
    height: 100%;
    background: linear-gradient(90deg, transparent, rgba(59, 130, 246, 0.1), transparent);
    transition: left 0.5s ease;
}

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

.guide-link:hover {
    color: #60A5FA;
    transform: translateX(3px);
}

.guide-link i {
    font-size: 0.9rem;
    transition: transform 0.3s ease;
}

.guide-link:hover i {
    transform: rotate(5deg) scale(1.1);
}

/* Mobile responsive */
@media (max-width: 768px) {
    .feature-guide-link {
        margin-top: 1rem;
        padding-top: 1rem;
    }
    
    .guide-link {
        font-size: 0.9rem;
    }
}