/* Solutions Page Styles */

body {
    background-color: var(--colors-interface--neutral-1);
}

.usecases-hero {
    padding: 80px 0 56px;
    text-align: center;
}

.usecases-hero-title {
    font-size: clamp(36px, 5vw, 56px);
    font-weight: 400;
    letter-spacing: -0.03em;
    line-height: 1.08;
    color: #0a0a0a;
    margin: 0;
}

.usecases-hero-title-light {
    font-size: clamp(36px, 5vw, 56px);
    font-weight: 400;
    letter-spacing: -0.03em;
    line-height: 1.08;
    color: rgba(0, 0, 0, 0.55);
    margin: 0 0 28px;
}

.usecases-hero-body {
    font-size: 16px;
    color: rgba(0, 0, 0, 0.55);
    max-width: 450px;
    margin: 0 auto;
    line-height: 1.65;
}

/* Cards */
.usecases-section {
    padding: 0 120px;
    padding-bottom: 80px;
}

.usecases-cards {
    display: flex;
    flex-direction: column;
    gap: 12px;
}

.usecase-card {
    border: 1px solid rgba(0, 0, 0, 0.1);
    border-radius: 12px;
    padding-top: 28px;
    padding-left: 28px;
    padding-bottom: 28px;
    background: #ffffff;
    transition: border-color 0.22s ease;
    overflow: hidden;
}

.usecase-card:hover {
    border-color: rgba(0, 0, 0, 0.35);
}

.usecase-card-title {
    font-size: 20px;
    font-weight: 500;
    color: #0a0a0a;
    margin: 0 0 24px;
    letter-spacing: -0.01em;
}

.usecase-card-image {
    display: block;
    width: 100%;
    max-width: 720px;
    height: auto;
}

/* View Details button */
.usecase-card-footer {
    display: flex;
    justify-content: flex-end;
    align-items: center;
    gap: 8px;
    padding-right: 28px;
    padding-top: 16px;
}

.usecase-toggle-btn {
    background: #0a0a0a;
    border: 1px solid #0a0a0a;
    border-radius: 8px;
    padding: 4px 9px;
    font-size: 12px;
    font-weight: 500;
    color: #fff;
    cursor: pointer;
    transition: background 0.18s ease, color 0.18s ease;
    letter-spacing: -0.01em;
}

.usecase-toggle-btn:hover {
    background: #2a2a2a;
    border-color: #2a2a2a;
}

.usecase-card.is-expanded .usecase-toggle-btn {
    background: transparent;
    color: #0a0a0a;
    border-color: rgba(0, 0, 0, 0.35);
}

.usecase-card.is-expanded .usecase-toggle-btn:hover {
    background: rgba(0, 0, 0, 0.06);
    border-color: #0a0a0a;
}

/* Learn More button */
.usecase-learn-btn {
    display: none;
    background: #0a0a0a;
    border: 1px solid #0a0a0a;
    border-radius: 8px;
    padding: 4px 9px;
    font-size: 12px;
    font-weight: 500;
    color: #fff;
    text-decoration: none;
    cursor: pointer;
    transition: background 0.18s ease;
    letter-spacing: -0.01em;
}

.usecase-learn-btn:hover {
    background: #2a2a2a;
    border-color: #2a2a2a;
}

.usecase-card.is-expanded .usecase-learn-btn {
    display: inline-block;
}

/* Card body */
.usecase-card-body {
    display: flex;
    align-items: center;
    justify-content: center;
    height: 260px;
    overflow: hidden;
}

.usecase-card-image-wrap {
    flex-shrink: 0;
    width: 100%;
    height: 100%;
    display: flex;
    align-items: center;
    justify-content: center;
    transition: width 0.4s ease;
}

/* Shrink image when card is expanded */
.usecase-card.is-expanded .usecase-card-image-wrap {
    width: 36%;
}

.usecase-card-image-wrap .usecase-card-image {
    width: 100%;
    height: 100%;
    object-fit: contain;
    margin: 0;
}

.usecase-card-desc {
    flex: 1;
    opacity: 0;
    max-width: 0;
    overflow: hidden;
    transition: opacity 0.35s ease 0.15s, max-width 0.4s ease, padding 0.4s ease;
    padding: 0;
    font-size: 14px;
    color: rgba(0, 0, 0, 0.65);
    line-height: 1.7;
    height: 100%;
    display: flex;
    flex-direction: column;
    justify-content: center;
}

.usecase-card.is-expanded .usecase-card-desc {
    opacity: 1;
    max-width: 600px;
    padding: 4px 28px 4px 24px;
    overflow-y: auto;
    overflow-x: hidden;
}

.usecase-card-desc p {
    margin: 0;
}

.usecase-card-desc h3 {
    font-size: 16px;
    font-weight: 600;
    color: #0a0a0a;
    margin: 0 0 12px;
    letter-spacing: -0.01em;
}

/* Tablet */
@media (min-width: 769px) and (max-width: 1024px) {
    .usecases-section {
        padding: 0 48px;
        padding-bottom: 64px;
    }

    .usecase-card {
        padding-top: 24px;
        padding-left: 24px;
        padding-bottom: 24px;
    }

    .usecase-card-body {
        height: 220px;
    }

    .usecase-card-image-wrap{
        width: 85%;
    }

    .usecase-card.is-expanded .usecase-card-image-wrap {
        width: 38%;
    }

    .usecase-card.is-expanded .usecase-card-desc {
        max-width: 500px;
        padding: 4px 20px 4px 20px;
    }

    .usecase-card-footer {
        padding-right: 24px;
        gap: 8px;
    }
}

@media (max-width: 768px) {
    .usecases-hero {
        padding: 56px 0 40px;
    }

    .usecases-hero-body {
        font-size: 15px;
        padding: 0 16px;
    }

    .usecase-card {
        border-radius: 10px;
        padding: 16px;
    }

    .usecases-section {
        padding: 20px 20px;
    }

    .usecase-card-title {
        font-size: 16px;
    }

    /* Column layout: image on top, desc slides in below */
    .usecase-card-body {
        flex-direction: column;
        height: auto;
        overflow: visible;
        align-items: stretch;
        justify-content: flex-start;
    }

    /* Image keeps a fixed height — never resizes */
    .usecase-card-image-wrap {
        width: 100%;
        height: 180px;
        flex-shrink: 0;
    }

    /* Image stays exactly the same when expanded */
    .usecase-card.is-expanded .usecase-card-image-wrap {
        width: 100% !important;
        height: 180px;
    }

    /* Switch to max-height animation for column layout */
    .usecase-card-desc {
        max-width: 100%;
        width: 100%;
        max-height: 0;
        transition: opacity 0.35s ease 0.15s, max-height 0.4s ease, padding 0.4s ease;
        overflow: hidden;
        justify-content: flex-start;
    }

    .usecase-card.is-expanded .usecase-card-desc {
        max-width: 100%;
        max-height: 220px;
        padding: 12px 0 0;
        overflow-y: auto;
        overflow-x: hidden;
    }

    .usecase-card-footer {
        padding-right: 0;
    }
}

@media (max-width: 480px) {
    .usecase-card-image-wrap {
        height: 160px;
    }

    .usecase-card.is-expanded .usecase-card-image-wrap {
        height: 160px !important;
    }

    .usecase-card.is-expanded .usecase-card-desc {
        max-height: 180px;
    }
}
