/* ========================================
   Diagnostic Page - Brand Tab Switcher
   ======================================== */

/* Brand Tab Bar */
.brand-tabs {
    display: flex;
    justify-content: center;
    gap: 0;
    padding: 0 0 40px;
    max-width: 600px;
    margin: 0 auto;
    position: relative;
    z-index: 2;
}

.brand-tab {
    flex: 1;
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 10px;
    padding: 18px 24px;
    background: var(--card-bg);
    border: 1px solid var(--card-border);
    color: var(--text-secondary);
    font-size: 16px;
    font-weight: 600;
    cursor: pointer;
    transition: all 0.3s ease;
    position: relative;
    overflow: hidden;
}

.brand-tab:first-child {
    border-radius: 14px 0 0 14px;
}

.brand-tab:last-child {
    border-radius: 0 14px 14px 0;
    border-left: none;
}

.brand-tab.active {
    color: #fff;
}

.brand-tab[data-brand="porsche"].active {
    background: linear-gradient(135deg, rgba(213, 0, 28, 0.15), rgba(184, 157, 99, 0.1));
    border-color: var(--porsche-gold, #B89D63);
    box-shadow: 0 0 24px rgba(213, 0, 28, 0.12);
}

.brand-tab[data-brand="porsche"].active .brand-tab-icon {
    color: var(--porsche-gold, #B89D63);
}

.brand-tab[data-brand="bmw"].active {
    background: linear-gradient(135deg, rgba(0, 102, 177, 0.15), rgba(0, 61, 122, 0.1));
    border-color: var(--bmw-blue, #0066B1);
    box-shadow: 0 0 24px rgba(0, 102, 177, 0.12);
}

.brand-tab[data-brand="bmw"].active .brand-tab-icon {
    color: var(--bmw-blue, #0066B1);
}

.brand-tab-icon {
    width: 24px;
    height: 24px;
    flex-shrink: 0;
    transition: color 0.3s ease;
}

.brand-tab:hover:not(.active) {
    background: var(--bg-card-hover, rgba(255, 255, 255, 0.05));
    color: var(--text-primary);
}

/* Brand Content Sections */
.brand-section {
    display: none;
    animation: fadeInUp 0.4s ease;
}

.brand-section.active {
    display: block;
}

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

/* Light theme adjustments */
[data-theme="light"] .brand-tab {
    background: rgba(255, 255, 255, 0.7);
    border-color: rgba(0, 0, 0, 0.08);
}

[data-theme="light"] .brand-tab[data-brand="porsche"].active {
    background: linear-gradient(135deg, rgba(213, 0, 28, 0.08), rgba(184, 157, 99, 0.06));
}

[data-theme="light"] .brand-tab[data-brand="bmw"].active {
    background: linear-gradient(135deg, rgba(0, 102, 177, 0.08), rgba(0, 61, 122, 0.06));
}

[data-theme="light"] .brand-tab.active {
    color: var(--text-primary);
}

/* Responsive */
@media (max-width: 640px) {
    .brand-tabs {
        flex-direction: column;
        gap: 8px;
    }

    .brand-tab {
        border-radius: 14px !important;
        border-left: 1px solid var(--card-border) !important;
    }
}
