/**
 * Styles pour formulaire messages CUSTOMER - Alignement visuel avec VENDOR
 * Conserve la logique existante, améliore seulement l'apparence
 * 
 * @package BricksChild
 * @subpackage Interface/Customer
 * @version 1.0.0
 */

/* ============================================
   CONTAINER PRINCIPAL FORMULAIRE CUSTOMER
   ============================================ */

.message-form {
    background: #f8f9fa;
    border: 1px solid #e1e8ed;
    border-radius: 8px;
    padding: 20px;
    margin-bottom: 20px;
}

/* ============================================
   TEXTAREA MESSAGE CUSTOMER
   ============================================ */

.message-form textarea[name="message"] {
    width: 100%;
    min-height: 80px;
    padding: 12px;
    border: 1px solid #ddd;
    border-radius: 6px;
    font-size: 14px;
    font-family: inherit;
    resize: vertical;
    margin-bottom: 15px;
    box-sizing: border-box;
}

.message-form textarea[name="message"]:focus {
    border-color: var(--form-primary);
    outline: none;
    box-shadow: 0 0 0 2px rgba(0, 124, 186, 0.1);
}

/* ============================================
   SECTION UPLOAD CUSTOMER
   ============================================ */

.attachment-section {
    margin-bottom: 15px;
}

.attachment-input {
    display: none !important;
}

/* ============================================
   ACTIONS FORMULAIRE CUSTOMER
   ============================================ */

.message-form-actions {
    margin-top: 15px;
    display: flex;
    gap: 10px;
    flex-direction: column;
}

/* Bouton d'ajout de pièce jointe - style VENDOR upload-zone exact */
.message-form .attach-file-button,
#attach-file-btn.attach-file-button {
    background: #fff !important;
    border: 2px dashed #cbd5db !important;
    color: #333 !important;
    padding: 20px !important;
    border-radius: 8px !important;
    font-size: 0 !important; /* Masque le texte original */
    cursor: pointer !important;
    transition: all 0.3s ease !important;
    width: 100% !important;
    display: flex !important;
    flex-direction: column !important;
    align-items: center !important;
    justify-content: center !important;
    gap: 8px !important;
    min-height: 120px !important;
    text-align: center !important;
    line-height: 1.4 !important;
    position: relative !important;
    box-sizing: border-box !important;
}

/* Restructurer le contenu pour correspondre à vendor */
.message-form .attach-file-button .emoji,
#attach-file-btn.attach-file-button .emoji {
    font-size: 24px !important;
    margin-bottom: 8px !important;
    width: 24px !important;
    height: 24px !important;
    display: block !important;
}

/* Remplacer le texte par le contenu vendor */
.message-form .attach-file-button::before,
#attach-file-btn.attach-file-button::before {
    content: 'Cliquer pour joindre des fichiers' !important;
    font-size: 14px !important;
    font-weight: 500 !important;
    color: #333 !important;
    margin-bottom: 4px !important;
    display: block !important;
}

.message-form .attach-file-button::after,
#attach-file-btn.attach-file-button::after {
    content: 'Formats acceptés: JPG, PNG, PDF, DOC, ZIP (max 10MB)' !important;
    font-size: 12px !important;
    color: #666 !important;
    display: block !important;
}

.message-form .attach-file-button:hover,
#attach-file-btn.attach-file-button:hover {
    border-color: var(--form-primary) !important;
    transform: translateY(-2px) !important;
}

.message-form .attach-file-button:hover .emoji,
#attach-file-btn.attach-file-button:hover .emoji {
    transform: scale(1.1) !important;
    transition: transform 0.2s ease !important;
}

/* ============================================
   AFFICHAGE FICHIER SÉLECTIONNÉ
   ============================================ */

.attachment-info {
    margin-top: 10px;
    padding: 10px;
    background: #fff;
    border: 1px solid #e1e8ed;
    border-radius: 6px;
    display: flex;
    align-items: center;
    justify-content: space-between;
}

.attachment-info.visible {
    display: flex !important;
}

.attachment-name {
    font-size: 13px;
    color: #333;
    font-weight: 500;
}

.remove-attachment {
    background: none;
    border: none;
    color: #d63638;
    cursor: pointer;
    font-size: 14px;
    padding: 4px;
    border-radius: 3px;
}

.remove-attachment:hover {
    background: #f0f0f0;
}

/* Bouton d'envoi - style identique au vendor */
.message-form-actions button[type="submit"] {
    background: linear-gradient(135deg, #6300ff 0%, #4a00cc 100%) !important;
    color: white !important;
    border: none !important;
    padding: 15px 20px !important;
    font-size: 16px !important;
    font-weight: 600 !important;
    border-radius: 6px !important;
    cursor: pointer !important;
    transition: all 0.3s ease !important;
    display: flex !important;
    align-items: center !important;
    justify-content: center !important;
    gap: 8px !important;
    width: 100% !important;
    min-height: 55px !important;
    box-sizing: border-box !important;
}

.message-form-actions button[type="submit"] .emoji {
    width: 18px !important;
    height: 18px !important;
}

.message-form-actions button[type="submit"]:hover {
    transform: translateY(-1px) !important;
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.15) !important;
}

.message-form-actions button[type="submit"]:active {
    transform: translateY(0) !important;
}

/* ============================================
   RESPONSIVE
   ============================================ */

@media (max-width: 768px) {
    .message-form {
        padding: 15px;
        margin-bottom: 15px;
    }
    
    .attachment-section {
        padding: 15px;
    }
    
    .message-form-actions button[type="submit"] {
        padding: 10px 15px;
        font-size: 13px;
    }
}
