/* ==================== MODAL DE PAGAMENTO PIX ==================== */

/* Modal Overlay */
.pix-modal-overlay {
    display: none;
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: rgba(0, 0, 0, 0.8);
    z-index: 9999;
    align-items: center;
    justify-content: center;
    padding: 20px;
}

.pix-modal-overlay.active {
    display: flex;
}

/* Modal Container */
.pix-modal {
    background: white;
    border-radius: 25px;
    max-width: 500px;
    width: 100%;
    max-height: 90vh;
    overflow-y: auto;
    box-shadow: 0 20px 60px rgba(0,0,0,0.3);
    animation: modalSlideIn 0.3s ease;
}

@keyframes modalSlideIn {
    from {
        opacity: 0;
        transform: translateY(-50px) scale(0.9);
    }
    to {
        opacity: 1;
        transform: translateY(0) scale(1);
    }
}

/* Modal Header */
.pix-modal-header {
    background: linear-gradient(135deg, #00c9a7, #00a884);
    padding: 30px;
    text-align: center;
    border-radius: 25px 25px 0 0;
    position: relative;
}

.pix-modal-close {
    position: absolute;
    top: 15px;
    right: 15px;
    background: rgba(255,255,255,0.2);
    border: none;
    color: white;
    width: 35px;
    height: 35px;
    border-radius: 50%;
    font-size: 1.3em;
    cursor: pointer;
    transition: all 0.3s ease;
}

.pix-modal-close:hover {
    background: rgba(255,255,255,0.3);
    transform: rotate(90deg);
}

.pix-icon-large {
    width: 80px;
    height: 80px;
    background: white;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    margin: 0 auto 15px;
    box-shadow: 0 4px 15px rgba(0,0,0,0.2);
}

.pix-icon-large i {
    font-size: 2.5em;
    color: #00c9a7;
}

.pix-modal-header h2 {
    color: white !important;
    font-size: 1.8em !important;
    font-weight: 800 !important;
    margin-bottom: 8px;
}

.pix-modal-header p {
    color: rgba(255,255,255,0.9) !important;
    font-size: 1em !important;
    font-weight: 500 !important;
}

/* Modal Body */
.pix-modal-body {
    padding: 35px 30px;
}

/* Valor Info */
.pix-valor-info {
    background: linear-gradient(135deg, #f0f9ff, #e0f2fe);
    border-left: 5px solid #3b82f6;
    padding: 20px;
    border-radius: 12px;
    margin-bottom: 25px;
    text-align: center;
}

.pix-valor-info .label {
    color: #64748b !important;
    font-size: 0.9em;
    font-weight: 600;
    text-transform: uppercase;
    letter-spacing: 0.5px;
    margin-bottom: 5px;
}

.pix-valor-info .valor {
    color: #1e293b !important;
    font-size: 2.5em !important;
    font-weight: 800 !important;
}

/* QR Code Container */
.qrcode-container {
    background: white;
    padding: 25px;
    border-radius: 15px;
    border: 3px solid #e2e8f0;
    text-align: center;
    margin-bottom: 25px;
}

.qrcode-container img {
    max-width: 100%;
    width: 280px;
    height: 280px;
    border-radius: 10px;
    margin-bottom: 15px;
}

.qrcode-container p {
    color: #64748b !important;
    font-size: 0.95em;
    font-weight: 600;
    margin-bottom: 15px;
}

.qrcode-instructions {
    background: #fef3c7;
    border-left: 4px solid #f59e0b;
    padding: 18px;
    border-radius: 10px;
    margin-bottom: 25px;
}

.qrcode-instructions h4 {
    color: #92400e !important;
    font-size: 1.1em !important;
    font-weight: 800 !important;
    margin-bottom: 12px;
    display: flex;
    align-items: center;
    gap: 8px;
}

.qrcode-instructions ol {
    color: #78350f !important;
    font-size: 0.95em;
    font-weight: 600;
    line-height: 1.8;
    padding-left: 20px;
}

.qrcode-instructions ol li {
    margin-bottom: 8px;
}

/* Upload Comprovante */
.upload-comprovante {
    background: #f8fafc;
    border: 2px dashed #cbd5e1;
    border-radius: 12px;
    padding: 25px;
    text-align: center;
    margin-bottom: 20px;
    transition: all 0.3s ease;
}

.upload-comprovante:hover {
    border-color: #3b82f6;
    background: #f0f9ff;
}

.upload-comprovante input[type="file"] {
    display: none;
}

.upload-label {
    cursor: pointer;
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 12px;
}

.upload-icon {
    width: 60px;
    height: 60px;
    background: linear-gradient(135deg, #3b82f6, #2563eb);
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    color: white;
    font-size: 1.8em;
}

.upload-label h4 {
    color: #1e293b !important;
    font-size: 1.15em !important;
    font-weight: 700 !important;
}

.upload-label p {
    color: #64748b !important;
    font-size: 0.9em;
}

.file-selected {
    background: #d1fae5;
    padding: 15px;
    border-radius: 10px;
    margin-top: 15px;
    display: flex;
    align-items: center;
    gap: 12px;
    border: 2px solid #10b981;
}

.file-selected i {
    color: #059669;
    font-size: 1.5em;
}

.file-selected .file-info {
    flex: 1;
    text-align: left;
}

.file-selected .file-name {
    color: #065f46 !important;
    font-weight: 700;
    font-size: 0.95em;
}

.file-selected .file-size {
    color: #047857 !important;
    font-size: 0.85em;
}

.btn-remove-file {
    background: #ef4444;
    color: white;
    border: none;
    width: 30px;
    height: 30px;
    border-radius: 50%;
    cursor: pointer;
    font-size: 0.9em;
}

/* Buttons */
.pix-actions {
    display: flex;
    flex-direction: column;
    gap: 12px;
}

.btn-pix-action {
    padding: 16px;
    border: none;
    border-radius: 12px;
    font-size: 1.05em;
    font-weight: 700;
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 10px;
    transition: all 0.3s ease;
}

.btn-enviar-comprovante {
    background: linear-gradient(135deg, #10b981, #059669);
    color: white;
}

.btn-enviar-comprovante:hover {
    transform: translateY(-3px);
    box-shadow: 0 8px 25px rgba(16, 185, 129, 0.4);
}

.btn-enviar-comprovante:disabled {
    opacity: 0.5;
    cursor: not-allowed;
    transform: none;
}

.btn-enviar-whatsapp {
    background: linear-gradient(135deg, #25d366, #128c7e);
    color: white;
}

.btn-enviar-whatsapp:hover {
    transform: translateY(-3px);
    box-shadow: 0 8px 25px rgba(37, 211, 102, 0.4);
}

.btn-cancelar-pix {
    background: #f1f5f9;
    color: #475569;
}

.btn-cancelar-pix:hover {
    background: #e2e8f0;
}

/* Loading State */
.loading-spinner {
    display: inline-block;
    width: 16px;
    height: 16px;
    border: 2px solid rgba(255,255,255,0.3);
    border-top-color: white;
    border-radius: 50%;
    animation: spin 0.6s linear infinite;
}

@keyframes spin {
    to { transform: rotate(360deg); }
}

/* Success Message */
.success-message {
    background: #d1fae5;
    border-left: 4px solid #10b981;
    padding: 18px;
    border-radius: 10px;
    margin-bottom: 20px;
    display: flex;
    align-items: center;
    gap: 12px;
}

.success-message i {
    color: #059669;
    font-size: 1.5em;
}

.success-message p {
    color: #065f46 !important;
    font-weight: 600;
    flex: 1;
}

/* Responsive */
@media (max-width: 768px) {
    .pix-modal {
        margin: 10px;
        max-height: 95vh;
    }
    
    .pix-modal-header,
    .pix-modal-body {
        padding: 25px 20px;
    }
    
    .qrcode-container img {
        width: 240px;
        height: 240px;
    }
    
    .pix-valor-info .valor {
        font-size: 2em !important;
    }
}
