/**
 * Styles pour l'édition de factures
 */

.wprentals_modal_overlay {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background-color: rgba(0, 0, 0, 0.5);
    display: flex;
    align-items: center;
    justify-content: center;
    z-index: 9999;
    opacity: 0;
    pointer-events: none;
    transition: opacity 0.3s ease;
}

.wprentals_modal_overlay.show {
    opacity: 1;
    pointer-events: auto;
}

.wprentals_modal_content {
    background: #ffffff;
    border-radius: 8px;
    box-shadow: 0 4px 20px rgba(0, 0, 0, 0.15);
    max-width: 600px;
    width: 90%;
    max-height: 80vh;
    overflow-y: auto;
    position: relative;
    margin-top: 32px;
}

@keyframes slideInUp {
    from {
        transform: translateY(30px);
        opacity: 0;
    }
    to {
        transform: translateY(0);
        opacity: 1;
    }
}

.wprentals_modal_content .modal-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 20px;
    border-bottom: 1px solid #e8ebf0;
    background-color: #51AF6B;
}

.wprentals_modal_content .modal-header h3 {
    margin: 0;
    color: #ffffff;
    font-size: 18px;
    font-weight: 600;
}

.wprentals_modal_content .close-modal {
    font-size: 28px;
    font-weight: bold;
    color: #ffffff;
    cursor: pointer;
    border: none;
    background: none;
    padding: 0;
    transition: opacity 0.3s ease;
}

.wprentals_modal_content .close-modal:hover {
    opacity: 0.8;
}

.wprentals_modal_content .modal-body {
    padding: 20px;
}

.invoice_edit_info {
    background-color: #f8fafd;
    border: 1px solid #e8ebf0;
    border-radius: 6px;
    padding: 15px;
    margin-bottom: 20px;
}

.invoice_edit_info .info_row {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 8px 0;
    border-bottom: 1px solid #e8ebf0;
}

.invoice_edit_info .info_row:last-child {
    border-bottom: none;
}

.invoice_edit_info .info_row label {
    font-weight: 600;
    color: #3e4453;
    margin: 0;
}

.invoice_edit_info .info_row span {
    color: #666;
    font-weight: 500;
}

.invoice_edit_info .info_row.balance-due span {
    color: #d9534f;
    font-weight: 700;
    font-size: 16px;
}

.wprentals_modal_content .form-group {
    margin-bottom: 20px;
}

.wprentals_modal_content .form-group label {
    display: block;
    margin-bottom: 8px;
    color: #3e4453;
    font-weight: 600;
    font-size: 14px;
}

.wprentals_modal_content .form-group input[type="number"],
.wprentals_modal_content .form-group textarea {
    width: 100%;
    padding: 10px 12px;
    border: 1px solid #cdd3db;
    border-radius: 4px;
    font-size: 14px;
    box-sizing: border-box;
}

.wprentals_modal_content .form-group input[type="number"]:focus,
.wprentals_modal_content .form-group textarea:focus {
    outline: none;
    border-color: #005ba5;
    box-shadow: 0 0 0 3px rgba(0, 91, 165, 0.1);
}

.wprentals_modal_content .form-group textarea {
    min-height: 100px;
    resize: vertical;
}

.wprentals_modal_content .form-group.checkbox {
    display: flex;
    align-items: flex-start;
    gap: 10px;
}

.wprentals_modal_content .form-group.checkbox input[type="checkbox"] {
    margin-top: 4px;
}

.wprentals_modal_content .form-group.checkbox label {
    margin: 0;
    font-weight: 400;
}

.wprentals_modal_content .modal-footer {
    display: flex;
    justify-content: flex-end;
    gap: 10px;
    padding-top: 15px;
    border-top: 1px solid #e8ebf0;
}

.wprentals_modal_content .btn {
    padding: 10px 20px;
    border: none;
    border-radius: 4px;
    font-size: 14px;
    font-weight: 600;
    cursor: pointer;
    transition: all 0.3s ease;
}

.wprentals_modal_content .btn-primary {
    background-color: #005ba5;
    color: #ffffff;
}

.wprentals_modal_content .btn-primary:hover:not(:disabled) {
    background-color: #004a84;
}

.wprentals_modal_content .btn-primary:disabled {
    opacity: 0.6;
    cursor: not-allowed;
}

.wprentals_modal_content .btn-secondary {
    background-color: #e8ebf0;
    color: #3e4453;
}

.wprentals_modal_content .btn-secondary:hover {
    background-color: #d8dfe0;
}

.edit_invoice_button {
    display: inline-block;
    padding: 6px 12px;
    margin-left: 8px;
    background-color: #f5f7fa;
    border: 1px solid #cdd3db;
    border-radius: 3px;
    color: #005ba5;
    font-size: 13px;
    font-weight: 600;
    cursor: pointer;
    transition: all 0.3s ease;
    text-decoration: none;
}

.edit_invoice_button:hover {
    background-color: #e8f0f8;
    border-color: #005ba5;
    color: #003f7f;
}

@media (max-width: 768px) {
    .wprentals_modal_content {
        width: 95%;
    }

    .invoice_edit_info .info_row {
        flex-direction: column;
        align-items: flex-start;
    }

    .wprentals_modal_content .modal-footer {
        flex-direction: column-reverse;
    }

    .wprentals_modal_content .btn {
        width: 100%;
    }
}
