/**
 * Styles pour le module de demande de devis
 * Path: modules/quoterequest/views/css/quoterequest.css V2
 */

/* Bouton principal */
.quote-request-wrapper {
    margin: 20px 0;
}

#openQuoteModal {
    padding: 12px 30px;
    font-size: 16px;
    font-weight: 600;
    display: inline-flex;
    align-items: center;
    gap: 8px;
    transition: all 0.3s ease;
}

#openQuoteModal:hover {
    transform: translateY(-2px);
    box-shadow: 0 4px 12px rgba(0,123,255,0.3);
}

/* Modal */
.quote-modal {
    position: fixed;
    z-index: 9999;
    left: 0;
    top: 0;
    width: 100%;
    height: 100%;
    overflow: auto;
    background-color: rgba(0,0,0,0.5);
}

.quote-modal-content {
    background-color: #fff;
    margin: 3% auto;
    padding: 0;
    border: none;
    border-radius: 8px;
    width: 90%;
    max-width: 700px;
    box-shadow: 0 5px 30px rgba(0,0,0,0.3);
    animation: slideDown 0.3s ease;
}

@keyframes slideDown {
    from {
        opacity: 0;
        transform: translateY(-50px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

.quote-modal-header {
    background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
    color: white;
    padding: 20px 30px;
    border-radius: 8px 8px 0 0;
    display: flex;
    justify-content: space-between;
    align-items: center;
}

.quote-modal-header h2 {
    margin: 0;
    font-size: 24px;
    font-weight: 600;
}

.quote-close {
    color: white;
    font-size: 32px;
    font-weight: bold;
    cursor: pointer;
    transition: all 0.2s;
    line-height: 1;
}

.quote-close:hover,
.quote-close:focus {
    color: #f1f1f1;
    transform: rotate(90deg);
}

.quote-modal-body {
    padding: 30px;
}

.quote-article-info {
    background: #f8f9fa;
    padding: 15px;
    border-radius: 6px;
    margin-bottom: 25px;
    border-left: 4px solid #667eea;
}

/* Formulaire */
#quoteRequestForm .form-group {
    margin-bottom: 20px;
}

#quoteRequestForm label {
    font-weight: 600;
    margin-bottom: 8px;
    color: #333;
    display: block;
}

#quoteRequestForm .form-control {
    border: 2px solid #e1e8ed;
    border-radius: 6px;
    padding: 12px 15px;
    font-size: 15px;
    transition: all 0.3s;
}

#quoteRequestForm .form-control:focus {
    border-color: #667eea;
    box-shadow: 0 0 0 3px rgba(102, 126, 234, 0.1);
    outline: none;
}

#quoteRequestForm .form-control.is-invalid {
    border-color: #dc3545;
}

#quoteRequestForm .error-message {
    color: #dc3545;
    font-size: 13px;
    margin-top: 5px;
    display: none;
}

#quoteRequestForm textarea.form-control {
    resize: vertical;
    min-height: 100px;
}

/* Radio buttons */
.form-check-inline {
    margin-right: 20px;
}

.form-check-input {
    cursor: pointer;
}

.form-check-label {
    cursor: pointer;
    font-weight: normal;
}

/* Checkboxes RGPD */
.custom-control {
    padding-left: 30px;
    margin-bottom: 15px;
}

.custom-control-input {
    cursor: pointer;
}

.custom-control-label {
    cursor: pointer;
    font-size: 14px;
    color: #666;
    line-height: 1.5;
}

/* Bouton soumettre */
#quoteRequestForm button[type="submit"] {
    padding: 14px 30px;
    font-size: 16px;
    font-weight: 600;
    margin-top: 20px;
    border-radius: 6px;
    transition: all 0.3s;
}

#quoteRequestForm button[type="submit"]:hover {
    transform: translateY(-2px);
    box-shadow: 0 4px 12px rgba(40, 167, 69, 0.3);
}

/* Messages */
.alert {
    padding: 15px;
    border-radius: 6px;
    margin-bottom: 20px;
}

.alert-success {
    background-color: #d4edda;
    border: 1px solid #c3e6cb;
    color: #155724;
}

.alert-danger {
    background-color: #f8d7da;
    border: 1px solid #f5c6cb;
    color: #721c24;
}

.alert ul {
    margin: 0;
    padding-left: 20px;
}

/* Responsive */
@media (max-width: 768px) {
    .quote-modal-content {
        width: 95%;
        margin: 10% auto;
    }
    
    .quote-modal-body {
        padding: 20px;
    }
    
    .quote-modal-header {
        padding: 15px 20px;
    }
    
    .quote-modal-header h2 {
        font-size: 20px;
    }
    
    .form-row {
        display: block;
    }
    
    .form-row .form-group {
        width: 100%;
    }
}

/* Produits additionnels - Checkboxes stylées */
.custom-control.custom-checkbox {
    position: relative;
    display: flex;
    align-items: baseline;
    justify-content: space-between;
    padding-left: 38px !important;
}
.custom-control+.custom-control {
    margin-left: 0;
}

.custom-control.custom-checkbox:hover {
    background: #f0f4ff !important;
    box-shadow: 0 2px 8px rgba(102, 126, 234, 0.1);
}

.custom-control-input {
    position: absolute;
    left: 10px;
    top: 21px;
    transform: translateY(-50%);
    width: 18px;
    height: 18px;
    cursor: pointer;
    opacity: 1 !important;
    z-index: 2;
    margin-top: 0;
}

.custom-control-label {
    margin: 0;
    padding: 0;
}

.custom-control-input:checked ~ .custom-control-label {
    font-weight: 600;
    color: #667eea;
}
.custom-control-label .d-flex{
    width: 100%;
    justify-content: space-between;
    align-items: baseline;
}
#addotherproduit {
    margin: 15px 0;
}
.otherproduits{
    max-height: 300px; overflow-y: auto; border: 1px solid #e1e8ed; border-radius: 6px; padding: 15px; background: #f9f9f9;
    display: none;
}
.otherproduits.show { display: block; }

/* Scrollbar personnalisée pour la liste de produits */
.quote-modal-body div[style*="overflow-y: auto"]::-webkit-scrollbar {
    width: 8px;
}

.quote-modal-body div[style*="overflow-y: auto"]::-webkit-scrollbar-track {
    background: #f1f1f1;
    border-radius: 4px;
}

.quote-modal-body div[style*="overflow-y: auto"]::-webkit-scrollbar-thumb {
    background: #667eea;
    border-radius: 4px;
}

.quote-modal-body div[style*="overflow-y: auto"]::-webkit-scrollbar-thumb:hover {
    background: #5568d3;
}