/* ============================================
   ESTILOS PARA GESTÃO DE COBRANÇAS
   ============================================ */

/* Cores personalizadas */
:root {
    --payment-primary: #1E40AF;
    --payment-secondary: #F3F4F6;
    --payment-success: #10B981;
    --payment-warning: #F59E0B;
    --payment-danger: #EF4444;
    --payment-info: #3B82F6;
    --payment-dark: #374151;
}

/* ============================================
   LAYOUT GERAL
   ============================================ */

.payment-management-container {
    background-color: var(--payment-secondary);
    min-height: 100vh;
}

/* ============================================
   CARDS E COMPONENTES
   ============================================ */

.payment-card {
    border: none;
    border-radius: 12px;
    box-shadow: 0 4px 6px -1px rgba(0, 0, 0, 0.1);
    transition: all 0.3s ease;
}

.payment-card:hover {
    transform: translateY(-2px);
    box-shadow: 0 10px 25px -3px rgba(0, 0, 0, 0.1);
}

.payment-card-header {
    border-radius: 12px 12px 0 0 !important;
    border-bottom: none;
    padding: 1.25rem 1.5rem;
}

.payment-card-body {
    padding: 1.5rem;
}

/* ============================================
   FILTROS
   ============================================ */

.payment-filters {
    background: white;
    border-radius: 12px;
    box-shadow: 0 2px 4px rgba(0, 0, 0, 0.05);
    margin-bottom: 2rem;
}

.payment-filters .form-label {
    font-weight: 600;
    color: var(--payment-dark);
    margin-bottom: 0.5rem;
}

.payment-filters .form-control,
.payment-filters .form-select {
    border: 2px solid #E5E7EB;
    border-radius: 8px;
    padding: 0.75rem 1rem;
    transition: all 0.3s ease;
}

.payment-filters .form-control:focus,
.payment-filters .form-select:focus {
    border-color: var(--payment-primary);
    box-shadow: 0 0 0 3px rgba(30, 64, 175, 0.1);
}

/* ============================================
   ESTATÍSTICAS
   ============================================ */

.payment-stats-card {
    border-radius: 12px;
    border: none;
    transition: transform 0.3s ease;
}

.payment-stats-card:hover {
    transform: translateY(-2px);
}

.payment-stats-card .card-body {
    padding: 1.5rem;
}

.payment-stats-card h6 {
    font-size: 0.875rem;
    font-weight: 600;
    margin-bottom: 0.5rem;
    opacity: 0.9;
}

.payment-stats-card h3 {
    font-size: 2rem;
    font-weight: 700;
    margin-bottom: 0;
}

.payment-stats-card i {
    opacity: 0.8;
}

/* ============================================
   TABELA
   ============================================ */

.payment-table {
    background: white;
    border-radius: 12px;
    overflow: hidden;
    box-shadow: 0 4px 6px -1px rgba(0, 0, 0, 0.1);
}

.payment-table .table {
    margin-bottom: 0;
}

.payment-table .table thead th {
    background-color: #F8FAFC;
    border-bottom: 2px solid #E5E7EB;
    font-weight: 600;
    color: var(--payment-dark);
    padding: 1rem 1.5rem;
    font-size: 0.875rem;
    text-transform: uppercase;
    letter-spacing: 0.05em;
}

.payment-table .table tbody td {
    padding: 1rem 1.5rem;
    vertical-align: middle;
    border-bottom: 1px solid #F3F4F6;
}

.payment-table .table tbody tr:hover {
    background-color: #F8FAFC;
}

.payment-table .table tbody tr:last-child td {
    border-bottom: none;
}

/* ============================================
   BADGES E STATUS
   ============================================ */

.payment-badge {
    font-size: 0.75rem;
    font-weight: 600;
    padding: 0.5rem 0.75rem;
    border-radius: 6px;
    text-transform: uppercase;
    letter-spacing: 0.025em;
}

.payment-badge-pending {
    background-color: #FEF3C7;
    color: #92400E;
}

.payment-badge-received {
    background-color: #DBEAFE;
    color: #1E40AF;
}

.payment-badge-confirmed {
    background-color: #D1FAE5;
    color: #065F46;
}

.payment-badge-overdue {
    background-color: #FEE2E2;
    color: #991B1B;
}

.payment-badge-refunded {
    background-color: #F3F4F6;
    color: #374151;
}

.payment-badge-cancelled {
    background-color: #1F2937;
    color: #F9FAFB;
}

/* ============================================
   BOTÕES
   ============================================ */

.payment-btn {
    border-radius: 8px;
    font-weight: 600;
    padding: 0.5rem 1rem;
    transition: all 0.3s ease;
    border: 2px solid transparent;
}

.payment-btn:hover {
    transform: translateY(-1px);
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.15);
}

.payment-btn-primary {
    background-color: var(--payment-primary);
    border-color: var(--payment-primary);
    color: white;
}

.payment-btn-primary:hover {
    background-color: #1D4ED8;
    border-color: #1D4ED8;
    color: white;
}

.payment-btn-outline {
    background-color: transparent;
    border-color: #D1D5DB;
    color: #374151;
}

.payment-btn-outline:hover {
    background-color: #F9FAFB;
    border-color: #9CA3AF;
    color: #111827;
}

/* ============================================
   PAGINAÇÃO
   ============================================ */

.payment-pagination {
    background: white;
    border-top: 1px solid #E5E7EB;
    padding: 1.5rem;
}

.payment-pagination .pagination {
    margin-bottom: 0;
}

.payment-pagination .page-link {
    border: 2px solid #E5E7EB;
    color: #374151;
    font-weight: 600;
    padding: 0.75rem 1rem;
    margin: 0 0.25rem;
    border-radius: 8px;
    transition: all 0.3s ease;
}

.payment-pagination .page-link:hover {
    background-color: var(--payment-primary);
    border-color: var(--payment-primary);
    color: white;
    transform: translateY(-1px);
}

.payment-pagination .page-item.active .page-link {
    background-color: var(--payment-primary);
    border-color: var(--payment-primary);
    color: white;
}

.payment-pagination .page-item.disabled .page-link {
    background-color: #F9FAFB;
    border-color: #E5E7EB;
    color: #9CA3AF;
    cursor: not-allowed;
}

/* ============================================
   MODAIS
   ============================================ */

.payment-modal .modal-content {
    border-radius: 12px;
    border: none;
    box-shadow: 0 25px 50px -12px rgba(0, 0, 0, 0.25);
}

.payment-modal .modal-header {
    border-bottom: 2px solid #E5E7EB;
    padding: 1.5rem;
}

.payment-modal .modal-body {
    padding: 2rem;
}

.payment-modal .modal-footer {
    border-top: 2px solid #E5E7EB;
    padding: 1.5rem;
}

/* ============================================
   DETALHES DA COBRANÇA
   ============================================ */

.payment-details-section {
    margin-bottom: 2rem;
}

.payment-details-section .card-header {
    font-weight: 700;
    font-size: 1.1rem;
    padding: 1.25rem 1.5rem;
}

.payment-details-section .form-label {
    font-weight: 600;
    color: var(--payment-dark);
    margin-bottom: 0.5rem;
}

.payment-details-section .form-control-plaintext {
    font-size: 1rem;
    color: #374151;
    padding: 0.5rem 0;
}

.payment-details-section .h4 {
    font-weight: 700;
    margin-bottom: 0;
}

/* ============================================
   SIDEBAR DE AÇÕES
   ============================================ */

.payment-actions-sidebar .card {
    margin-bottom: 1.5rem;
}

.payment-actions-sidebar .btn {
    width: 100%;
    margin-bottom: 0.5rem;
    justify-content: flex-start;
}

.payment-actions-sidebar .btn:last-child {
    margin-bottom: 0;
}

/* ============================================
   RESPONSIVIDADE
   ============================================ */

@media (max-width: 768px) {
    .payment-table .table thead th,
    .payment-table .table tbody td {
        padding: 0.75rem 1rem;
        font-size: 0.875rem;
    }
    
    .payment-stats-card h3 {
        font-size: 1.5rem;
    }
    
    .payment-filters .row > div {
        margin-bottom: 1rem;
    }
    
    .payment-details-section .row > div {
        margin-bottom: 1rem;
    }
}

@media (max-width: 576px) {
    .payment-table {
        font-size: 0.8rem;
    }
    
    .payment-stats-card .card-body {
        padding: 1rem;
    }
    
    .payment-stats-card h3 {
        font-size: 1.25rem;
    }
    
    .payment-btn {
        padding: 0.375rem 0.75rem;
        font-size: 0.875rem;
    }
}

/* ============================================
   ANIMAÇÕES
   ============================================ */

@keyframes fadeIn {
    from {
        opacity: 0;
        transform: translateY(20px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

.payment-fade-in {
    animation: fadeIn 0.5s ease-out;
}

@keyframes pulse {
    0%, 100% {
        opacity: 1;
    }
    50% {
        opacity: 0.5;
    }
}

.payment-loading {
    animation: pulse 1.5s ease-in-out infinite;
}

/* ============================================
   UTILITÁRIOS
   ============================================ */

.payment-text-truncate {
    overflow: hidden;
    text-overflow: ellipsis;
    white-space: nowrap;
}

.payment-cursor-pointer {
    cursor: pointer;
}

.payment-user-select-none {
    user-select: none;
}

.payment-transition {
    transition: all 0.3s ease;
}

/* ============================================
   ESTADOS DE CARREGAMENTO
   ============================================ */

.payment-loading-overlay {
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background-color: rgba(255, 255, 255, 0.8);
    display: flex;
    align-items: center;
    justify-content: center;
    z-index: 10;
}

.payment-spinner {
    width: 3rem;
    height: 3rem;
    border: 0.25rem solid #E5E7EB;
    border-top: 0.25rem solid var(--payment-primary);
    border-radius: 50%;
    animation: spin 1s linear infinite;
}

@keyframes spin {
    0% { transform: rotate(0deg); }
    100% { transform: rotate(360deg); }
}

/* ============================================
   NOTIFICAÇÕES
   ============================================ */

.payment-notification {
    position: fixed;
    top: 20px;
    right: 20px;
    z-index: 9999;
    min-width: 300px;
    max-width: 400px;
    border-radius: 8px;
    box-shadow: 0 10px 25px rgba(0, 0, 0, 0.1);
    animation: slideInRight 0.3s ease-out;
}

@keyframes slideInRight {
    from {
        transform: translateX(100%);
        opacity: 0;
    }
    to {
        transform: translateX(0);
        opacity: 1;
    }
}

/* ============================================
   MELHORIAS DE ACESSIBILIDADE
   ============================================ */

.payment-focus-visible:focus-visible {
    outline: 2px solid var(--payment-primary);
    outline-offset: 2px;
}

.payment-sr-only {
    position: absolute;
    width: 1px;
    height: 1px;
    padding: 0;
    margin: -1px;
    overflow: hidden;
    clip: rect(0, 0, 0, 0);
    white-space: nowrap;
    border: 0;
}

/* ============================================
   IMPRESSÃO
   ============================================ */

@media print {
    .payment-no-print {
        display: none !important;
    }
    
    .payment-table {
        box-shadow: none;
        border: 1px solid #000;
    }
    
    .payment-card {
        box-shadow: none;
        border: 1px solid #000;
    }
}






