/* F1 Go Baba - Frontend Styles */

.f1-go-baba-container {
    max-width: 1200px;
    margin: 40px auto;
    font-family: -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, Oxygen, Ubuntu, Cantarell, sans-serif;
}

/* Selector Section */
.f1-selector-section {
    background: #ffffff;
    border-radius: 12px;
    box-shadow: 0 4px 6px rgba(0, 0, 0, 0.07);
    padding: 40px;
    margin-bottom: 40px;
}

.f1-selector-header h2 {
    font-size: 28px;
    font-weight: 700;
    color: #1a1a1a;
    margin: 0 0 30px 0;
    text-align: center;
    letter-spacing: -0.5px;
}

/* Driver Selectors */
.f1-driver-selectors {
    display: grid;
    grid-template-columns: 1fr auto 1fr;
    gap: 30px;
    align-items: center;
    margin-bottom: 30px;
}

.f1-driver-select-wrapper {
    display: flex;
    flex-direction: column;
}

.f1-driver-select-wrapper label {
    font-size: 14px;
    font-weight: 600;
    color: #4a4a4a;
    margin-bottom: 8px;
    text-transform: uppercase;
    letter-spacing: 0.5px;
}

.f1-driver-select {
    width: 100%;
    padding: 14px 16px;
    font-size: 16px;
    border: 2px solid #e0e0e0;
    border-radius: 8px;
    background: #ffffff;
    color: #1a1a1a;
    cursor: pointer;
    transition: all 0.3s ease;
}

.f1-driver-select:hover {
    border-color: #e10600;
}

.f1-driver-select:focus {
    outline: none;
    border-color: #e10600;
    box-shadow: 0 0 0 3px rgba(225, 6, 0, 0.1);
}

/* Select2 Customization */
.select2-container--default .select2-selection--single {
    border: 2px solid #e0e0e0;
    border-radius: 8px;
    height: 50px;
    padding: 0;
}

.select2-container--default .select2-selection--single .select2-selection__rendered {
    line-height: 46px;
    padding-left: 16px;
    color: #1a1a1a;
    font-size: 16px;
}

.select2-container--default .select2-selection--single .select2-selection__arrow {
    height: 46px;
    right: 10px;
}

.select2-container--default.select2-container--focus .select2-selection--single,
.select2-container--default.select2-container--open .select2-selection--single {
    border-color: #e10600;
    box-shadow: 0 0 0 3px rgba(225, 6, 0, 0.1);
}

.select2-dropdown {
    border: 2px solid #e10600;
    border-radius: 8px;
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.15);
}

.select2-search--dropdown .select2-search__field {
    border: 2px solid #e0e0e0;
    border-radius: 6px;
    padding: 10px 12px;
    font-size: 15px;
}

.select2-search--dropdown .select2-search__field:focus {
    border-color: #e10600;
    outline: none;
}

.select2-results__option {
    padding: 12px 16px;
    font-size: 15px;
}

.select2-container--default .select2-results__option--highlighted[aria-selected] {
    background-color: #e10600;
}

.select2-container--default .select2-results__option[aria-selected=true] {
    background-color: #f5f5f5;
    color: #1a1a1a;
}

/* VS Divider */
.f1-vs-divider {
    display: flex;
    align-items: center;
    justify-content: center;
    width: 60px;
    height: 60px;
    background: linear-gradient(135deg, #e10600 0%, #ff0800 100%);
    border-radius: 50%;
    box-shadow: 0 4px 12px rgba(225, 6, 0, 0.3);
}

.f1-vs-divider span {
    color: #ffffff;
    font-size: 20px;
    font-weight: 800;
    letter-spacing: 1px;
}

/* Compare Button */
.f1-compare-button-wrapper {
    text-align: center;
}

.f1-compare-button {
    background: linear-gradient(135deg, #e10600 0%, #ff0800 100%);
    color: #ffffff;
    border: none;
    padding: 16px 48px;
    font-size: 18px;
    font-weight: 700;
    border-radius: 8px;
    cursor: pointer;
    transition: all 0.3s ease;
    text-transform: uppercase;
    letter-spacing: 1px;
    box-shadow: 0 4px 12px rgba(225, 6, 0, 0.3);
}

.f1-compare-button:hover:not(:disabled) {
    transform: translateY(-2px);
    box-shadow: 0 6px 16px rgba(225, 6, 0, 0.4);
}

.f1-compare-button:active:not(:disabled) {
    transform: translateY(0);
}

.f1-compare-button:disabled {
    background: #cccccc;
    cursor: not-allowed;
    box-shadow: none;
}

/* Comparison Results */
.f1-comparison-results {
    animation: fadeIn 0.5s ease-in;
}

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

.f1-drivers-intro {
    background: #f8f9fa;
    border-left: 4px solid #e10600;
    padding: 24px 28px;
    margin-bottom: 30px;
    border-radius: 8px;
}

.f1-drivers-intro p {
    font-size: 17px;
    line-height: 1.7;
    color: #2c2c2c;
    margin: 0;
}

.f1-drivers-intro strong {
    color: #e10600;
    font-weight: 700;
}

.f1-shortcodes-output {
    display: flex;
    flex-direction: column;
    gap: 30px;
}

/* Responsive Design */
@media (max-width: 768px) {
    .f1-go-baba-container {
        padding: 0 15px;
        margin: 20px auto;
    }
    
    .f1-selector-section {
        padding: 24px 20px;
    }
    
    .f1-selector-header h2 {
        font-size: 22px;
        margin-bottom: 20px;
    }
    
    .f1-driver-selectors {
        grid-template-columns: 1fr;
        gap: 20px;
    }
    
    .f1-vs-divider {
        order: 2;
        margin: 0 auto;
    }
    
    .f1-driver-select-wrapper:first-child {
        order: 1;
    }
    
    .f1-driver-select-wrapper:last-child {
        order: 3;
    }
    
    .f1-compare-button {
        width: 100%;
        padding: 14px 24px;
        font-size: 16px;
    }
    
    .f1-drivers-intro {
        padding: 18px 20px;
    }
    
    .f1-drivers-intro p {
        font-size: 15px;
    }
}

@media (max-width: 480px) {
    .f1-selector-header h2 {
        font-size: 20px;
    }
    
    .f1-driver-select {
        font-size: 14px;
        padding: 12px 14px;
    }
    
    .select2-container--default .select2-selection--single {
        height: 44px;
    }
    
    .select2-container--default .select2-selection--single .select2-selection__rendered {
        line-height: 40px;
        font-size: 14px;
    }
    
    .f1-vs-divider {
        width: 50px;
        height: 50px;
    }
    
    .f1-vs-divider span {
        font-size: 16px;
    }
}

/* Loading State */
.f1-compare-button.loading {
    position: relative;
    color: transparent;
}

.f1-compare-button.loading::after {
    content: '';
    position: absolute;
    width: 20px;
    height: 20px;
    top: 50%;
    left: 50%;
    margin-left: -10px;
    margin-top: -10px;
    border: 3px solid rgba(255, 255, 255, 0.3);
    border-radius: 50%;
    border-top-color: #ffffff;
    animation: spinner 0.8s linear infinite;
}

@keyframes spinner {
    to {
        transform: rotate(360deg);
    }
}
