/* Features Scroll Section */
.features-scroll-section {
    background-color: #1c1c1e;
    padding: 128px 0;

    /* Safer Full Width Breakout */
    width: 100vw;
    height: 920px;
    /* Increased from 800px to prevent cutoff */
    /* Fixed height as requested */
    box-sizing: border-box;
    margin-left: calc(50% - 50vw);
    margin-right: calc(50% - 50vw);
    position: relative;
    left: auto;
    right: auto;

    overflow: hidden;

    /* Define Alignment Variable */
    /* Center (50vw) - Half Content (1280px) = 640px + Padding (32px) */
    --scroll-padding: max(32px, calc(50vw - 640px + 32px));
}

.features-header {
    max-width: 1280px;
    margin: 0 auto 64px auto;
    padding: 0 32px;
    display: flex;
    flex-direction: column;
    align-items: center;
    text-align: center;
    gap: 64px;
}

.features-nav-buttons {
    display: flex;
    gap: 16px;
}

.nav-btn {
    width: 44px;
    height: 44px;
    border-radius: 50%;
    background-color: rgba(255, 255, 255, 0.1);
    border: none;
    display: flex;
    align-items: center;
    justify-content: center;
    cursor: pointer;
    transition: background-color 0.2s, opacity 0.2s;
    color: #FFFFFF;
}

.nav-btn:hover {
    background-color: rgba(255, 255, 255, 0.2);
}

.nav-btn:disabled {
    opacity: 0.3;
    cursor: default;
}

.nav-btn svg {
    width: 24px;
    height: 24px;
    fill: currentColor;
}

.features-title {
    /* Font handled by .text-desktop-title */
    color: #FFFFFF;
    margin: 0;
}

/* Scroll Container */
.features-scroll-wrapper {
    display: flex;
    overflow-x: auto;
    scroll-snap-type: x mandatory;
    gap: 32px;
    width: 100%;

    /* Padding: top | right (overscroll) | bottom | left (align) */
    padding: 0 60vw 32px var(--scroll-padding);

    /* Ensure snap points respect the padding */
    scroll-padding-left: var(--scroll-padding);
    scroll-padding-right: 60vw;
    /* Match padding for consistency */

    /* Hide Scrollbar */
    scrollbar-width: none;
    -ms-overflow-style: none;
    /* IE 10+ */
}

.features-scroll-wrapper::-webkit-scrollbar {
    width: 0px;
    background: transparent;
}

/* Individual Cards */
.feature-card {
    scroll-snap-align: start;
    scroll-snap-stop: always;
    /* Snap to the start (left) align line */
    flex: 0 0 660px;
    /* Reduced from 830px */
    height: 380px;
    /* Reduced from 460px */
    border-radius: 28px;
    /* Scaled radius */
    position: relative;
    overflow: hidden;
    box-sizing: border-box;
    border: 1px solid rgba(235, 235, 245, 0.16);
    /* Transition for hover effects if needed */
}

/* Card Variants */
.feature-card.dark {
    background-color: #000000;
    color: #FFFFFF;
}

.feature-card.light {
    background-color: #FFFFFF;
    color: #000000;
}

/* Card Content Layouts */
.card-content {
    display: flex;
    width: 100%;
    height: 100%;
    padding: 24px;
    /* Reduced from 32px */
    /* Default Padding */
}

/* Card 1 Specifics */
.feature-card.dark .card-content {
    align-items: stretch;
    /* Ensure children fill height */
    justify-content: flex-start;
    padding: 24px 24px 0 24px;
    gap: 24px;
}

.dark-text-block {
    flex: 1;
    /* Font handled by .text-desktop-header */
    padding-bottom: 24px;
    display: flex;
    flex-direction: column;
    justify-content: flex-end;
    /* Align text to bottom */
}

.card-image-wrapper {
    flex-shrink: 0;
    /* Prevent shrinking */
    width: 300px;
    height: auto;
    /* Allow auto height to fill flex container */
    /* Fill vertically */
    background: #2C2C2E;
    /* Placeholder bg */
    border-top-left-radius: 36px;
    border-top-right-radius: 36px;
    box-shadow: 0px 4px 32px 0px rgba(0, 0, 0, 0.25);
    overflow: hidden;
    position: relative;
    margin-bottom: -1px;
    align-self: stretch;
    /* Explicitly stretch */
}

.card-image-wrapper img {
    width: 100%;
    height: 100%;
    object-fit: cover;
}

/* Card 2 Specifics */
.feature-card.light .card-content {
    flex-direction: column;
    justify-content: space-between;
    align-items: flex-start;
    padding: 32px;
    /* Reduced from 48px */
}

.light-top-content {
    display: flex;
    flex-direction: column;
    gap: 24px;
}

.icon-wrapper {
    /* Placeholder for icon */
    width: 48px;
    height: 48px;
    display: flex;
    align-items: center;
    justify-content: center;
}

.light-title {
    /* Font handled by h3 default / class */
    color: #000000;
    margin: 0;
}

.light-bottom-content p {
    /* Font handled by p default / class */
    color: #000000;
    margin: 0;
}

.text-gray {
    color: rgba(0, 0, 0, 0.6);
}

/* Footer Quote */
.features-footer {
    display: flex;
    justify-content: space-between;
    align-items: flex-start;
    max-width: 1280px;
    /* Match header max width or similar constraints */
    margin: 32px auto 0;
    /* Center it */
    padding: 0 32px;
    color: #FFFFFF;
    margin-left: auto;
    /* Remove offset margin to utilize centering */
    margin-right: auto;
}

.features-footer p {
    text-align: left;
    max-width: 600px;
    /* Reduced from 660px as requested */
    transition: opacity 0.3s ease;
    opacity: 1;
    margin: 0;

    /* Limit to 3 lines and enforce fixed height */
    overflow: hidden;
    display: -webkit-box;
    -webkit-line-clamp: 3;
    line-clamp: 3;
    -webkit-box-orient: vertical;
    /* Assuming line-height is approx 1.4-1.5, 3 lines is roughly 4.5em. 
       Let's use a pixel value based on typical body text (20px * 1.4 * 3 = 84px) */
    min-height: 84px;
    line-height: 1.4;
    /* Ensure consistent line height */
}

.features-footer p {
    transition: opacity 0.3s ease;
    opacity: 1;
    margin: 0;
}

/* Responsive adjustments */
@media (max-width: 1024px) {
    .features-title {
        font-size: 32px;
    }

    .feature-card {
        flex: 0 0 85vw;
        /* Adaptive width on tablet */
        height: auto;
        min-height: 380px;
        /* Reduced from 460px */
    }

    .feature-card.dark .card-content {
        flex-direction: column;
        align-items: flex-start;
        padding: 24px;
        /* Reduced from 32px */
    }

    .card-image-wrapper {
        width: 100%;
        height: 300px;
        order: 2;
        border-radius: 24px;
        margin-top: 24px;
    }

    .dark-text-block {
        padding-bottom: 0;
        font-size: 20px;
        /* Reduced to match desktop/scale */
    }
}