/* Site-wide Vehicle Mode Toggle Styles */

.site-vehicle-toggle {
    background: rgba(255, 255, 255, 0.95);
    padding: 0.75rem 1rem;
    border-radius: 8px;
    margin-top: 1rem;
    box-shadow: 0 2px 8px rgba(0, 0, 0, 0.15);
}

.site-toggle-content {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 1rem;
    flex-wrap: wrap;
}

.site-vehicle-toggle .toggle-text {
    font-size: 1rem;
    font-weight: 600;
    color: var(--primary-color);
}

.toggle-switch-container {
    display: flex;
    align-items: center;
}

.toggle-switch-label {
    position: relative;
    display: inline-block;
    width: 200px;
    height: 40px;
    cursor: pointer;
}

.toggle-checkbox {
    opacity: 0;
    width: 0;
    height: 0;
}

.toggle-switch-slider {
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background-color: #e0e0e0;
    border-radius: 20px;
    transition: background-color 0.3s ease;
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: 4px;
    overflow: hidden;
}

.toggle-switch-slider::before {
    content: '';
    position: absolute;
    height: 32px;
    width: 96px;
    left: 4px;
    bottom: 4px;
    background: linear-gradient(135deg, var(--secondary-color) 0%, #2980b9 100%);
    border-radius: 16px;
    transition: transform 0.3s ease;
    z-index: 1;
}

.toggle-checkbox:checked + .toggle-switch-slider::before {
    transform: translateX(96px);
}

.toggle-option-text {
    flex: 1;
    text-align: center;
    font-size: 0.875rem;
    font-weight: 600;
    padding: 0 8px;
    z-index: 2;
    position: relative;
    transition: color 0.3s ease;
    color: #666;
}

.toggle-checkbox:not(:checked) + .toggle-switch-slider .toggle-option-text.normal {
    color: white;
}

.toggle-checkbox:checked + .toggle-switch-slider .toggle-option-text.semi {
    color: white;
}

/* Semi-truck mode indicator */
body.semi-truck-mode {
    --primary-accent: #e67e22;
}

body.semi-truck-mode .site-vehicle-toggle {
    border: 2px solid var(--primary-accent, #e67e22);
}

/* Responsive adjustments */
@media (max-width: 768px) {
    .site-toggle-content {
        flex-direction: column;
        gap: 0.5rem;
    }

    .toggle-switch-label {
        width: 180px;
        height: 36px;
    }

    .toggle-switch-slider::before {
        height: 28px;
        width: 86px;
    }

    .toggle-checkbox:checked + .toggle-switch-slider::before {
        transform: translateX(86px);
    }

    .toggle-option-text {
        font-size: 0.8rem;
    }
}

@media (max-width: 480px) {
    .site-vehicle-toggle {
        padding: 0.5rem;
    }

    .toggle-switch-label {
        width: 160px;
        height: 34px;
    }

    .toggle-switch-slider::before {
        height: 26px;
        width: 76px;
    }

    .toggle-checkbox:checked + .toggle-switch-slider::before {
        transform: translateX(76px);
    }
}
