/**
 * Advantages Features - Horizontal Tabs Layout
 * Tabs on top, content (text + image) below
 */

.advantages-features-accordion {
    /* padding: 5rem 0; */
    background-color: #f8f9fa;
}

.advantages-features-accordion .container {
    padding: 0 !important;
    max-width: 1280px !important;
    margin: 0 auto;
}

.features-accordion-container {
    padding: 0 var(--spacing-sm);
}

.features-accordion-container {
    display: flex;
    flex-direction: column;
    gap: 0;
}

/* Horizontal Tabs Row - Top of section */
.features-events {
    display: flex;
    flex-direction: row;
    gap: 0;
    background-color: #ffffff;
    border-bottom: 3px solid #e5e7eb;
    overflow-x: auto;
    -webkit-overflow-scrolling: touch;
}

/* Individual Tab Button */
.feature-event-item {
    position: relative;
    padding: 1.5rem 2rem;
    border-bottom: 3px solid transparent;
    cursor: pointer;
    transition: all 0.3s ease;
    background-color: #ffffff;
    display: flex;
    flex-direction: row;
    align-items: center;
    justify-content: center;
    gap: 1rem;
    flex: 1;
    text-align: left;
}

.feature-event-item:not(:last-child) {
    border-right: 1px solid #e5e7eb;
}

.feature-event-item:hover {
    background-color: #f8f9fa;
}

.feature-event-item.active {
    background-color: var(--brand-mid-blue-gray);
    border-bottom-color: var(--brand-primary-orange);
    box-shadow: 0 4px 12px rgba(92, 123, 146, 0.15);
}

/* Tab Icon */
.feature-event-icon {
    width: 2rem;
    height: 2rem;
    display: flex;
    align-items: center;
    justify-content: center;
    color: var(--brand-primary-blue);
    transition: color 0.3s ease;
    flex-shrink: 0;
}

.feature-event-item.active .feature-event-icon {
    color: #ffffff;
}

.feature-event-icon i {
    font-size: 1.5rem;
}

/* Tab Title (only title shows in tab) */
.feature-event-title {
    font-size: 1rem;
    font-weight: 600;
    color: var(--text-primary);
    margin: 0;
    transition: color 0.3s ease;
    white-space: nowrap;
}

.feature-event-item.active .feature-event-title {
    color: #ffffff;
}

/* Hide description in tabs - will show in content area below */
.feature-event-description {
    display: none;
}

/* Content Area Below Tabs - Two columns: text left, image right */
.features-content-area {
    position: relative;
    background-color: #ffffff;
    padding: 3rem;
    min-height: 253px;
}

.features-content-wrapper {
    display: grid;
    grid-template-columns: 1fr 450px;
    gap: 3rem;
    align-items: center;
}

/* Content Text (Left) */
.features-content-text {
    position: relative;
}

.feature-content-item {
    display: none;
}

.feature-content-item.active {
    display: block;
    animation: fadeIn 0.6s ease-in-out;
}

@keyframes fadeIn {
    from {
        opacity: 0;
        transform: translateY(10px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

.feature-content-item h3 {
    font-size: 1.75rem;
    font-weight: 600;
    color: var(--text-primary);
    margin-bottom: 1.5rem;
}

.feature-content-item p {
    font-size: 1.0625rem;
    line-height: 1.8;
    color: var(--text-secondary);
    margin: 0;
}

/* Content Images (Right - 450px with 16:9 aspect ratio) */
.features-images {
    position: relative;
    background-color: #e5e7eb;
    border-radius: 0;
    overflow: hidden;
    height: 253px;
    width: 450px;
}

.feature-image-item {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    opacity: 0;
    transition: opacity 0.6s ease-in-out;
}

.feature-image-item.active {
    opacity: 1;
    z-index: 1;
}

.feature-image-item img {
    width: 100%;
    height: 100%;
    object-fit: cover;
}

/* Blue overlay on feature images - 90% transparent */
.feature-image-item::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background-color: rgba(43, 72, 141, 0.1);
    z-index: 1;
    pointer-events: none;
}

.feature-image-placeholder {
    width: 100%;
    height: 100%;
    background: linear-gradient(135deg, #e5e7eb 0%, #d1d5db 100%);
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    color: #9ca3af;
    font-size: 1.125rem;
}

.feature-image-placeholder i {
    font-size: 4rem;
    margin-bottom: 1rem;
    opacity: 0.5;
}

/* Responsive Design */
@media (max-width: 1024px) {
    .features-content-wrapper {
        grid-template-columns: 1fr;
        gap: 2rem;
    }

    .features-images {
        width: 100%;
        height: auto;
        aspect-ratio: 16 / 9;
        order: -1;
    }

    .features-content-area {
        padding: 2rem;
    }

    .feature-event-item {
        padding: 1.25rem 1.5rem;
        flex-direction: column;
        gap: 0.5rem;
    }
}

@media (max-width: 768px) {
    .advantages-features-accordion {
        padding: 3rem 0;
    }

    .features-content-area {
        padding: 1.5rem;
    }

    .feature-content-item h3 {
        font-size: 1.5rem;
    }

    .feature-content-item p {
        font-size: 1rem;
    }

    .feature-event-item {
        min-width: 140px;
        padding: 1rem 1.25rem;
        flex-direction: column;
        gap: 0.5rem;
    }

    .feature-event-icon {
        width: 2rem;
        height: 2rem;
    }

    .feature-event-icon i {
        font-size: 1.5rem;
    }

    .feature-event-title {
        font-size: 0.875rem;
        white-space: normal;
        text-align: center;
    }

    .features-images {
        height: auto;
        aspect-ratio: 16 / 9;
    }
}
