/* Case Studies Section Styling */
.case-studies {
    padding: 80px 20px;
    background-color: #f9fafb;
}

.case-studies-header {
    text-align: center;
    margin-bottom: 50px;
}

.case-studies-headline {
    font-size: 2.5rem;
    font-weight: 800;
    color: #1a1a1a;
    margin-bottom: 10px;
}

.case-studies-subheadline {
    font-size: 1.25rem;
    font-weight: 700;
    color: #323842;
    max-width: 800px;
    margin: 0 auto;
}

/* Case Study Card */
.case-study-card {
    background: #ffffff;
    border-radius: 12px;
    box-shadow: 0 10px 30px rgba(0, 0, 0, 0.05);
    /* Soft shadow */
    max-width: 900px;
    margin: 0 auto;
    padding: 40px;
    border: 1px solid #f0f0f0;
}

/* Top Layout: Video and Stats */
.card-top-layout {
    display: grid;
    grid-template-columns: 1.2fr 1fr;
    gap: 30px;
    margin-bottom: 30px;
}

.video-embed-container {
    position: relative;
    padding-bottom: 56.25%;
    /* 16:9 Aspect Ratio */
    height: 0;
    overflow: hidden;
    border-radius: 8px;
    border: 1px solid #e0e0e0;
}

.video-embed-container iframe {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
}

.case-study-stats {
    list-style: none;
    padding: 0;
    margin: 0 0 20px 0;
}

.stat-item {
    display: flex;
    align-items: center;
    gap: 12px;
    margin-bottom: 12px;
    font-size: 1.1rem;
    font-weight: 500;
    color: #374151;
}

.stat-item i {
    color: #ff4d4d;
    font-size: 1.2rem;
    width: 24px;
    text-align: center;
}

/* Quote Box */
.testimonial-box {
    background-color: #fff5eb;
    padding: 20px;
    border-radius: 8px;
    margin-top: 10px;
}

.testimonial-text {
    font-style: italic;
    font-weight: 500;
    font-size: 1rem;
    line-height: 1.5;
    color: #4b5563;
    margin-bottom: 10px;
}

.testimonial-author {
    color: #ff4d4d;
    font-weight: 700;
    font-size: 0.95rem;
}

/* Expandable Content */
.expandable-content {
    max-height: 0;
    overflow: hidden;
    transition: max-height 0.4s ease-out, opacity 0.3s ease-in-out;
    opacity: 0;
}

.expandable-content.active {
    max-height: 2000px;
    /* Large enough value */
    opacity: 1;
}

.case-detail-section {
    margin-top: 30px;
}

.case-detail-section h3 {
    font-size: 1.4rem;
    font-weight: 700;
    color: #1a1a1a;
    margin-bottom: 15px;
}

.case-detail-section p,
.case-detail-section li {
    font-size: 1.1rem;
    font-weight: 500;
    line-height: 1.6;
    color: #4b5563;
}

.case-detail-section ul,
.case-detail-section ol {
    padding-left: 20px;
    margin-top: 10px;
}

.case-detail-section li {
    margin-bottom: 8px;
}

/* Toggle Button */
.toggle-interaction {
    text-align: center;
    margin-top: 40px;
}

.toggle-details-btn {
    background-color: #ef4444;
    /* Match image red */
    color: white;
    padding: 14px 28px;
    border-radius: 6px;
    font-weight: 700;
    font-size: 1.1rem;
    border: none;
    cursor: pointer;
    transition: transform 0.2s, background-color 0.2s;
    box-shadow: 0 4px 12px rgba(239, 68, 68, 0.3);
}

.toggle-details-btn:hover {
    background-color: #dc2626;
    transform: translateY(-2px);
}

.toggle-details-btn:active {
    transform: translateY(0);
}

/* Responsive Adjustments */
@media (max-width: 768px) {
    .card-top-layout {
        grid-template-columns: 1fr;
    }

    .case-study-card {
        padding: 25px;
    }

    .case-studies-headline {
        font-size: 2rem;
    }

    .case-studies-subheadline {
        font-size: 1.25rem;
    }
}