/* Styles pour les éléments select - OnMyShop */

/* Styles de base pour tous les select */
select {
    appearance: none;
    -webkit-appearance: none;
    -moz-appearance: none;
    background: #ffffff;
    border: 2px solid #e9ecef;
    border-radius: 8px;
    padding: 12px 40px 12px 16px;
    font-size: 16px;
    font-weight: 500;
    color: #2c3e50;
    cursor: pointer;
    transition: all 0.3s ease;
    background-image: url("data:image/svg+xml;charset=UTF-8,%3csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='%23666' stroke-width='2' stroke-linecap='round' stroke-linejoin='round'%3e%3cpolyline points='6,9 12,15 18,9'%3e%3c/polyline%3e%3c/svg%3e");
    background-repeat: no-repeat;
    background-position: right 12px center;
    background-size: 16px;
    min-height: 48px;
    width: 100%;
}

/* Focus state */
select:focus {
    outline: none;
    border-color: #4f88ed;
    box-shadow: 0 0 0 3px rgba(79, 136, 237, 0.1);
    background-color: #ffffff;
}

/* Hover state */
select:hover {
    border-color: #4f88ed;
    background-color: #f8f9fa;
}

/* Disabled state */
select:disabled {
    background-color: #f8f9fa;
    color: #6c757d;
    cursor: not-allowed;
    opacity: 0.6;
}

/* Styles spécifiques pour le formulaire de contact */
.contact__from-input select,
.contact-select {
    height: 60px;
    padding: 0 50px 0 20px;
    line-height: 60px;
    border: 2px solid #e9ecef;
    border-radius: 8px;
    font-size: 16px;
    font-weight: 500;
    color: #2c3e50;
    background-color: #ffffff;
    transition: all 0.3s ease;
    appearance: none;
    -webkit-appearance: none;
    -moz-appearance: none;
    background-image: url("data:image/svg+xml;charset=UTF-8,%3csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='%23666' stroke-width='2' stroke-linecap='round' stroke-linejoin='round'%3e%3cpolyline points='6,9 12,15 18,9'%3e%3c/polyline%3e%3c/svg%3e");
    background-repeat: no-repeat;
    background-position: right 15px center;
    background-size: 18px;
}

.contact__from-input select:focus,
.contact-select:focus {
    border-color: #4f88ed;
    box-shadow: 0 0 0 3px rgba(79, 136, 237, 0.1);
    background-color: #ffffff;
    outline: none;
}

.contact__from-input select:hover,
.contact-select:hover {
    border-color: #4f88ed;
    background-color: #f8f9fa;
}

/* Styles pour les selects dans les pages admin */
.admin-select,
.form-select {
    appearance: none;
    -webkit-appearance: none;
    -moz-appearance: none;
    background: #ffffff;
    border: 1px solid #d1d5db;
    border-radius: 6px;
    padding: 8px 35px 8px 12px;
    font-size: 14px;
    font-weight: 500;
    color: #374151;
    cursor: pointer;
    transition: all 0.2s ease;
    background-image: url("data:image/svg+xml;charset=UTF-8,%3csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='%236b7280' stroke-width='2' stroke-linecap='round' stroke-linejoin='round'%3e%3cpolyline points='6,9 12,15 18,9'%3e%3c/polyline%3e%3c/svg%3e");
    background-repeat: no-repeat;
    background-position: right 8px center;
    background-size: 14px;
    min-height: 40px;
}

.admin-select:focus,
.form-select:focus {
    outline: none;
    border-color: #3b82f6;
    box-shadow: 0 0 0 2px rgba(59, 130, 246, 0.1);
}

.admin-select:hover,
.form-select:hover {
    border-color: #3b82f6;
    background-color: #f8f9fa;
}

/* Styles pour les selects dans les formulaires de checkout */
.checkout-form-list select {
    height: 50px;
    padding: 0 40px 0 15px;
    border: 2px solid #e9ecef;
    border-radius: 8px;
    font-size: 16px;
    font-weight: 500;
    color: #2c3e50;
    background-color: #ffffff;
    transition: all 0.3s ease;
}

.checkout-form-list select:focus {
    border-color: #4f88ed;
    box-shadow: 0 0 0 3px rgba(79, 136, 237, 0.1);
}

/* Styles pour les selects dans les filtres */
.filter-select {
    appearance: none;
    -webkit-appearance: none;
    -moz-appearance: none;
    background: #ffffff;
    border: 1px solid #d1d5db;
    border-radius: 6px;
    padding: 6px 30px 6px 10px;
    font-size: 14px;
    font-weight: 500;
    color: #374151;
    cursor: pointer;
    transition: all 0.2s ease;
    background-image: url("data:image/svg+xml;charset=UTF-8,%3csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='%236b7280' stroke-width='2' stroke-linecap='round' stroke-linejoin='round'%3e%3cpolyline points='6,9 12,15 18,9'%3e%3c/polyline%3e%3c/svg%3e");
    background-repeat: no-repeat;
    background-position: right 6px center;
    background-size: 12px;
    min-height: 36px;
}

.filter-select:focus {
    outline: none;
    border-color: #3b82f6;
    box-shadow: 0 0 0 2px rgba(59, 130, 246, 0.1);
}

/* Styles pour les selects dans les modales */
.modal select {
    appearance: none;
    -webkit-appearance: none;
    -moz-appearance: none;
    background: #ffffff;
    border: 1px solid #d1d5db;
    border-radius: 6px;
    padding: 10px 35px 10px 12px;
    font-size: 14px;
    font-weight: 500;
    color: #374151;
    cursor: pointer;
    transition: all 0.2s ease;
    background-image: url("data:image/svg+xml;charset=UTF-8,%3csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='%236b7280' stroke-width='2' stroke-linecap='round' stroke-linejoin='round'%3e%3cpolyline points='6,9 12,15 18,9'%3e%3c/polyline%3e%3c/svg%3e");
    background-repeat: no-repeat;
    background-position: right 8px center;
    background-size: 14px;
    min-height: 42px;
    width: 100%;
}

.modal select:focus {
    outline: none;
    border-color: #3b82f6;
    box-shadow: 0 0 0 2px rgba(59, 130, 246, 0.1);
}

/* Styles pour les selects avec validation */
select.is-invalid {
    border-color: #dc3545;
}

select.is-invalid:focus {
    border-color: #dc3545;
    box-shadow: 0 0 0 3px rgba(220, 53, 69, 0.1);
}

select.is-valid {
    border-color: #28a745;
}

select.is-valid:focus {
    border-color: #28a745;
    box-shadow: 0 0 0 3px rgba(40, 167, 69, 0.1);
}

/* Responsive */
@media (max-width: 768px) {
    select {
        font-size: 16px; /* Empêche le zoom sur iOS */
        padding: 12px 35px 12px 12px;
    }
    
    .contact__from-input select {
        height: 50px;
        padding: 0 40px 0 15px;
        line-height: 50px;
    }
    
    .admin-select {
        font-size: 14px;
        padding: 8px 30px 8px 10px;
        min-height: 36px;
    }
}

/* Dark mode support */
@media (prefers-color-scheme: dark) {
    select {
        background-color: #1f2937;
        border-color: #374151;
        color: #f9fafb;
    }
    
    select:focus {
        border-color: #3b82f6;
        background-color: #1f2937;
    }
    
    select:hover {
        background-color: #374151;
    }
}
