/* Reset e configurações básicas */
* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

body {
    font-family: 'Segoe UI', Tahoma, Geneva, Verdana, sans-serif;
    background: #ffffff;
    min-height: 100vh;
    color: #333;
}

/* Container e Header Padrão */
.dividas-distribuidores-container {
    max-width: 1200px;
    margin: 0 auto;
    padding: 20px;
}

/* Header Moderno */
.header {
    margin-bottom: 30px;
    color: #333;
    background: linear-gradient(135deg, #38b6ff, #1e88e5);
    padding: 30px;
    border-radius: 15px;
    box-shadow: 0 8px 25px rgba(56, 182, 255, 0.2);
}

.header-content {
    display: flex;
    justify-content: space-between;
    align-items: center;
    flex-wrap: wrap;
    gap: 20px;
}

.header-info {
    flex: 1;
    text-align: left;
}

.header-info h1 {
    font-size: 2.5rem;
    margin-bottom: 10px;
    color: white;
    text-shadow: 2px 2px 4px rgba(0,0,0,0.2);
    display: flex;
    align-items: center;
    gap: 12px;
}

.header-info p {
    font-size: 1.1rem;
    color: rgba(255, 255, 255, 0.9);
    margin: 0;
}

.header-actions {
    display: flex;
    gap: 15px;
}

.btn-voltar-painel {
    background: rgba(255, 255, 255, 0.2);
    color: white;
    border: 2px solid rgba(255, 255, 255, 0.3);
    padding: 12px 20px;
    border-radius: 10px;
    font-size: 0.9rem;
    font-weight: 600;
    cursor: pointer;
    transition: all 0.3s ease;
    backdrop-filter: blur(10px);
    display: flex;
    align-items: center;
    gap: 8px;
}

.btn-voltar-painel:hover {
    background: rgba(255, 255, 255, 0.3);
    border-color: rgba(255, 255, 255, 0.5);
    transform: translateY(-2px);
    box-shadow: 0 5px 15px rgba(255, 255, 255, 0.2);
}

.header h1 {
    font-size: 2.5rem;
    margin-bottom: 10px;
    color: white;
    text-shadow: 2px 2px 4px rgba(0,0,0,0.2);
}

.header p {
    font-size: 1.1rem;
    color: rgba(255, 255, 255, 0.9);
}

/* Dashboard Cards - Versão Discreta */
.dashboard-cards {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(220px, 1fr));
    gap: 1rem;
    margin-bottom: 2rem;
    padding: 0 0.5rem;
}

.card {
    border-radius: 12px;
    padding: 1.2rem;
    background: white;
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.1);
    transition: all 0.3s ease;
    position: relative;
    cursor: pointer;
    min-height: 110px;
    display: flex;
    flex-direction: column;
    justify-content: space-between;
    border-left: 4px solid;
}

.card:hover {
    transform: translateY(-3px);
    box-shadow: 0 8px 20px rgba(0, 0, 0, 0.15);
}

/* Card Total - Azul Discreto */
.card-total {
    border-left-color: #4a90e2;
}

.card-total .card-icon {
    color: #4a90e2;
}

/* Card Em Aberto - Laranja Suave */
.card-aberto {
    border-left-color: #f39c12;
}

.card-aberto .card-icon {
    color: #f39c12;
}

/* Card Pagas - Verde Suave */
.card-pagas {
    border-left-color: #27ae60;
}

.card-pagas .card-icon {
    color: #27ae60;
}

/* Card Vencidas - Vermelho Suave */
.card-vencidas {
    border-left-color: #e74c3c;
}

.card-vencidas .card-icon {
    color: #e74c3c;
}

.card-icon {
    font-size: 1.8rem;
    margin-bottom: 0.5rem;
    transition: all 0.3s ease;
}

.card-content {
    flex: 1;
}

.card-content h3 {
    font-size: 0.9rem;
    margin: 0 0 0.5rem 0;
    font-weight: 600;
    color: #666;
    text-transform: uppercase;
    letter-spacing: 0.5px;
}

.card-content p {
    font-size: 1.6rem;
    font-weight: 700;
    margin: 0;
    color: #333;
}

.card-subtitle {
    font-size: 0.75rem;
    color: #888;
    font-weight: 400;
    margin-top: 0.3rem;
    display: block;
}

/* Responsividade para Cards */
@media (max-width: 768px) {
    .dashboard-cards {
        grid-template-columns: repeat(2, 1fr);
        gap: 0.8rem;
    }
    
    .card {
        padding: 1rem;
        min-height: 100px;
    }
    
    .card-icon {
        font-size: 1.5rem;
    }
    
    .card-content p {
        font-size: 1.3rem;
    }
    
    .card-content h3 {
        font-size: 0.8rem;
    }
}

@media (max-width: 480px) {
    .dashboard-cards {
        grid-template-columns: 1fr;
    }
}

/* Botão Nova Dívida */
.nova-divida-container {
    display: flex;
    justify-content: center;
    margin-bottom: 30px;
}

.btn-nova-divida {
    background: linear-gradient(135deg, #38b6ff, #1e88e5);
    color: white;
    border: none;
    padding: 15px 30px;
    border-radius: 50px;
    font-size: 1.1rem;
    font-weight: 600;
    cursor: pointer;
    box-shadow: 0 8px 25px rgba(56, 182, 255, 0.3);
    transition: all 0.3s ease;
    display: flex;
    align-items: center;
    gap: 10px;
    min-width: 250px;
    justify-content: center;
}

.btn-nova-divida:hover {
    transform: translateY(-2px);
    box-shadow: 0 12px 35px rgba(56, 182, 255, 0.4);
    background: linear-gradient(135deg, #1e88e5, #1565c0);
}

.btn-nova-divida i {
    font-size: 1.2rem;
}

/* Filtros */
.filtros {
    background: white;
    border-radius: 15px;
    padding: 25px;
    margin-bottom: 30px;
    box-shadow: 0 8px 25px rgba(0,0,0,0.1);
    display: flex;
    gap: 20px;
    flex-wrap: wrap;
    align-items: center;
}

.filtro-grupo {
    display: flex;
    align-items: center;
    gap: 10px;
    flex: 1;
    min-width: 200px;
}

.filtro-input {
    flex: 1;
    padding: 12px 15px;
    border: 2px solid #e0e0e0;
    border-radius: 10px;
    font-size: 1rem;
    transition: all 0.3s ease;
}

.filtro-input:focus {
    outline: none;
    border-color: #38b6ff;
    box-shadow: 0 0 0 3px rgba(56, 182, 255, 0.1);
}

.filtro-select {
    flex: 1;
    padding: 12px 15px;
    border: 2px solid #e0e0e0;
    border-radius: 10px;
    font-size: 1rem;
    background: white;
    cursor: pointer;
    transition: all 0.3s ease;
}

.filtro-select:focus {
    outline: none;
    border-color: #38b6ff;
    box-shadow: 0 0 0 3px rgba(56, 182, 255, 0.1);
}

.btn-filtro-filtrar {
    background: #38b6ff;
    color: white;
    border: none;
    padding: 12px 20px;
    border-radius: 10px;
    cursor: pointer;
    transition: all 0.3s ease;
    font-size: 1rem;
    font-weight: 600;
    display: flex;
    align-items: center;
    gap: 8px;
}

.btn-filtro-filtrar:hover {
    background: #1e88e5;
    transform: translateY(-2px);
    box-shadow: 0 5px 15px rgba(56, 182, 255, 0.3);
}

.btn-filtro-limpar {
    background: #ff4757;
    color: white;
    border: none;
    padding: 12px 20px;
    border-radius: 10px;
    cursor: pointer;
    transition: all 0.3s ease;
    font-size: 1rem;
    font-weight: 600;
    display: flex;
    align-items: center;
    gap: 8px;
}

.btn-filtro-limpar:hover {
    background: #ff3742;
    transform: translateY(-2px);
    box-shadow: 0 5px 15px rgba(255, 71, 87, 0.3);
}

/* Tabela */
.tabela-container {
    background: white;
    border-radius: 15px;
    overflow: hidden;
    box-shadow: 0 8px 25px rgba(0,0,0,0.1);
}

.tabela-dividas {
    width: 100%;
    border-collapse: collapse;
}

.tabela-dividas th {
    background: #f8f9fa;
    padding: 20px 15px;
    text-align: left;
    font-weight: 600;
    color: #495057;
    font-size: 1rem;
    border-bottom: 2px solid #e9ecef;
}

.tabela-dividas td {
    padding: 20px 15px;
    border-bottom: 1px solid #e9ecef;
    font-size: 1rem;
}

.tabela-dividas tr:hover {
    background: #f8f9fa;
}

.status-badge {
    padding: 8px 16px;
    border-radius: 25px;
    font-size: 0.85rem;
    font-weight: 600;
    text-transform: uppercase;
    letter-spacing: 0.5px;
}

.status-badge.EM-ABERTO {
    background: #fff3cd;
    color: #856404;
}

.status-badge.PAGA {
    background: #d4edda;
    color: #155724;
}

.status-badge.VENCIDA {
    background: #f8d7da;
    color: #721c24;
}

.acoes-container {
    display: flex;
    gap: 10px;
}

.btn-acao {
    width: 40px;
    height: 40px;
    border: none;
    border-radius: 10px;
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 1rem;
    transition: all 0.3s ease;
    color: white;
}

.btn-acao.editar {
    background: linear-gradient(135deg, #38b6ff, #1e88e5);
}

.btn-acao.editar:hover {
    transform: translateY(-2px);
    box-shadow: 0 5px 15px rgba(56, 182, 255, 0.3);
}

.btn-acao.baixa {
    background: linear-gradient(135deg, #28a745, #20c997);
}

.btn-acao.baixa:hover {
    transform: translateY(-2px);
    box-shadow: 0 5px 15px rgba(40, 167, 69, 0.3);
}

.btn-acao.baixa:disabled {
    background: #6c757d;
    cursor: not-allowed;
    transform: none;
    box-shadow: none;
}

.btn-acao.excluir {
    background: #e74c3c;
    color: white;
}

.btn-acao.excluir:hover {
    background: #c0392b;
    transform: translateY(-2px);
    box-shadow: 0 5px 15px rgba(231, 76, 60, 0.3);
}

.estado-vazio {
    text-align: center;
    padding: 60px 20px;
    color: #6c757d;
}

.estado-vazio i {
    font-size: 4rem;
    margin-bottom: 20px;
    color: #dee2e6;
}

.estado-vazio p {
    font-size: 1.2rem;
    margin: 0;
}

/* Modais */
.modal {
    display: none;
    position: fixed;
    z-index: 2000;
    left: 0;
    top: 0;
    width: 100%;
    height: 100%;
    background-color: rgba(0, 0, 0, 0.5);
    backdrop-filter: blur(5px);
}

.modal-content {
    background: linear-gradient(135deg, #ffffff 0%, #f8f9fa 100%);
    margin: 5vh auto;
    padding: 0;
    border-radius: 14px;
    width: 88%;
    max-width: 560px;
    max-height: 85vh;
    overflow: auto;
    box-shadow: 0 25px 80px rgba(0, 0, 0, 0.25);
    animation: modalSlideIn 0.4s ease;
    border: 1px solid rgba(56, 182, 255, 0.1);
}

/* Tamanhos específicos por modal */
#modal-baixa .modal-content {
    max-width: 560px;
    max-height: 85vh;
    overflow: auto;
}

#modal-confirmar-exclusao .modal-content {
    max-width: 480px;
    max-height: 70vh;
    overflow: auto;
}

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

.modal-header {
    padding: 30px 30px 20px 30px;
    background: linear-gradient(135deg, #38b6ff, #1e88e5);
    color: white;
    display: flex;
    justify-content: space-between;
    align-items: center;
    position: relative;
}

.modal-header::after {
    content: none;
}

/* Evitar rolagem horizontal causada por transformações/overflows sutis */
html, body {
    overflow-x: hidden;
}

.modal-header h2 {
    font-size: 1.6rem;
    font-weight: 700;
    color: white;
    margin: 0;
    text-shadow: 1px 1px 2px rgba(0,0,0,0.1);
}

.fechar-modal {
    background: rgba(255, 255, 255, 0.2);
    border: none;
    font-size: 1.8rem;
    color: white;
    cursor: pointer;
    padding: 0;
    width: 45px;
    height: 45px;
    display: flex;
    align-items: center;
    justify-content: center;
    border-radius: 50%;
    transition: all 0.3s ease;
    backdrop-filter: blur(10px);
}

.fechar-modal:hover {
    background: rgba(255, 255, 255, 0.3);
    color: white;
    transform: scale(1.1);
    box-shadow: 0 5px 15px rgba(0, 0, 0, 0.2);
}

/* Formulários */
#form-divida,
#form-baixa {
    padding: 22px;
}

.form-grupo {
    margin-bottom: 16px;
    position: relative;
}

.form-grupo label {
    display: block;
    font-size: 1rem;
    font-weight: 600;
    color: #495057;
    margin-bottom: 10px;
    position: relative;
}

.form-grupo label::after {
    content: '';
    position: absolute;
    left: 0;
    bottom: -2px;
    width: 0;
    height: 2px;
    background: linear-gradient(90deg, #38b6ff, #1e88e5);
    transition: width 0.3s ease;
}

.form-grupo:focus-within label::after {
    width: 100%;
}

.form-grupo input,
.form-grupo select {
    width: 100%;
    padding: 12px 14px;
    border: 2px solid #e0e0e0;
    border-radius: 12px;
    font-size: 1rem;
    transition: all 0.3s ease;
    background: #ffffff;
    box-shadow: 0 2px 8px rgba(0, 0, 0, 0.05);
}

.form-grupo input:focus,
.form-grupo select:focus {
    outline: none;
    border-color: #38b6ff;
    box-shadow: 0 0 0 4px rgba(56, 182, 255, 0.1), 0 4px 12px rgba(56, 182, 255, 0.15);
    transform: translateY(-1px);
}

.form-grupo input:disabled {
    background: #f8f9fa;
    color: #6c757d;
    border-color: #dee2e6;
}

/* Estilos para validação de erro */
.form-grupo input.erro,
.form-grupo select.erro {
    border-color: #e74c3c;
    box-shadow: 0 0 0 4px rgba(231, 76, 60, 0.1);
    animation: shake 0.5s ease-in-out;
}

@keyframes shake {
    0%, 100% { transform: translateX(0); }
    25% { transform: translateX(-5px); }
    75% { transform: translateX(5px); }
}

.erro-validacao {
    color: #e74c3c;
    font-size: 0.9rem;
    margin-top: 8px;
    padding: 8px 12px;
    background: linear-gradient(135deg, #fdf2f2, #fde8e8);
    border: 1px solid #fecaca;
    border-radius: 8px;
    display: flex;
    align-items: center;
    gap: 8px;
    animation: slideIn 0.3s ease;
}

.erro-validacao i {
    color: #e74c3c;
    font-size: 1rem;
}

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

.valor-final {
    background: transparent;
    border: none;
    color: #2c3e50;
    font-weight: 700;
    box-shadow: none;
    position: relative;
}

.form-acoes {
    display: flex;
    gap: 15px;
    justify-content: flex-end;
    padding: 18px 22px;
    background: linear-gradient(135deg, #f8f9fa, #ffffff);
    border-top: 1px solid #e9ecef;
    position: relative;
}

.form-acoes::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    height: 1px;
    background: linear-gradient(90deg, transparent, #38b6ff, transparent);
}

.btn-salvar,
.btn-confirmar {
    background: linear-gradient(135deg, #38b6ff, #1e88e5);
    color: white;
    border: none;
    padding: 10px 18px;
    border-radius: 12px;
    font-size: 1rem;
    font-weight: 600;
    cursor: pointer;
    transition: all 0.3s ease;
    position: relative;
    overflow: hidden;
    box-shadow: 0 4px 15px rgba(56, 182, 255, 0.3);
}

.btn-salvar::before,
.btn-confirmar::before {
    content: '';
    position: absolute;
    top: 0;
    left: -100%;
    width: 100%;
    height: 100%;
    background: linear-gradient(90deg, transparent, rgba(255, 255, 255, 0.2), transparent);
    transition: left 0.5s ease;
}

.btn-salvar:hover::before,
.btn-confirmar:hover::before {
    left: 100%;
}

.btn-salvar:hover,
.btn-confirmar:hover {
    transform: translateY(-3px);
    box-shadow: 0 8px 25px rgba(56, 182, 255, 0.4);
    background: linear-gradient(135deg, #1e88e5, #1565c0);
}

.btn-cancelar {
    background: linear-gradient(135deg, #6c757d, #5a6268);
    color: white;
    border: none;
    padding: 10px 18px;
    border-radius: 12px;
    font-size: 1rem;
    font-weight: 600;
    cursor: pointer;
    transition: all 0.3s ease;
    box-shadow: 0 4px 15px rgba(108, 117, 125, 0.3);
}

.btn-cancelar:hover {
    background: linear-gradient(135deg, #5a6268, #495057);
    transform: translateY(-3px);
    box-shadow: 0 8px 25px rgba(108, 117, 125, 0.4);
}

.btn-excluir {
    background: #e74c3c;
    color: white;
    border: none;
    padding: 12px 25px;
    border-radius: 10px;
    font-size: 1rem;
    font-weight: 600;
    cursor: pointer;
    transition: all 0.3s ease;
}

.btn-excluir:hover {
    background: #c0392b;
    transform: translateY(-2px);
    box-shadow: 0 8px 25px rgba(231, 76, 60, 0.3);
}

.modal-body {
    padding: 30px;
    background: linear-gradient(135deg, #ffffff, #f8f9fa);
}

.modal-body p {
    font-size: 1.2rem;
    color: #495057;
    margin-bottom: 25px;
    line-height: 1.6;
}

.dados-exclusao {
    background: linear-gradient(135deg, #f8f9fa, #e9ecef);
    padding: 25px;
    border-radius: 15px;
    margin-bottom: 25px;
    border: 1px solid #dee2e6;
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.05);
}

.dados-exclusao p {
    margin: 12px 0;
    font-size: 1.1rem;
    display: flex;
    justify-content: space-between;
    align-items: center;
}

.dados-exclusao strong {
    color: #495057;
    font-weight: 700;
}

/* Toast */
.toast {
    position: fixed;
    top: 20px;
    right: 20px;
    background: #28a745;
    color: white;
    padding: 15px 25px;
    border-radius: 10px;
    font-weight: 600;
    z-index: 3000;
    transform: translateX(400px);
    transition: transform 0.3s ease;
    box-shadow: 0 5px 15px rgba(0, 0, 0, 0.2);
}

.toast.show {
    transform: translateX(0);
}

/* Modal de Visualização de Pagamento */
.modal-pagamento {
    max-width: 700px;
    max-height: 90vh;
    overflow-y: auto;
}

.modal-body-pagamento {
    padding: 30px;
    background: linear-gradient(135deg, #f8f9fa, #e9ecef);
    border-radius: 0 0 15px 15px;
}

.info-pagamento {
    display: flex;
    flex-direction: column;
    gap: 30px;
}

.info-grupo {
    background: white;
    padding: 25px;
    border-radius: 12px;
    box-shadow: 0 4px 15px rgba(0, 0, 0, 0.08);
    border-left: 4px solid #38b6ff;
}

.info-grupo h3 {
    margin: 0 0 20px 0;
    color: #2c3e50;
    font-size: 1.2rem;
    font-weight: 600;
    display: flex;
    align-items: center;
    gap: 10px;
}

.info-grupo h3 i {
    color: #38b6ff;
    font-size: 1.1rem;
}

.info-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(250px, 1fr));
    gap: 15px;
    align-items: start;
}

.info-item {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 12px 0;
    border-bottom: 1px solid #f1f3f4;
}

.info-item:last-child {
    border-bottom: none;
}

.info-item .label {
    font-weight: 600;
    color: #5a6c7d;
    font-size: 0.95rem;
}

.info-item .valor {
    font-weight: 500;
    color: #2c3e50;
    font-size: 1rem;
}

.status-badge {
    background: #e3f2fd;
    color: #1976d2;
    padding: 4px 12px;
    border-radius: 20px;
    font-size: 0.85rem;
    font-weight: 600;
    text-transform: uppercase;
}

.valor-final-item {
    background: linear-gradient(135deg, #d4edda, #c3e6cb);
    border-radius: 8px;
    padding: 15px !important;
    margin-top: 10px;
    border: 2px solid #28a745;
    grid-column: 1 / -1;
    box-shadow: 0 2px 8px rgba(40, 167, 69, 0.1);
}

.valor-final-item .label {
    color: #155724;
    font-weight: 700;
}

.valor-final-item .valor {
    color: #155724;
    font-weight: 700;
    font-size: 1.1rem;
}

.comprovante-container {
    margin-top: 15px;
}

.comprovante-estado {
    width: 100%;
}

.comprovante-vazio {
    text-align: center;
    padding: 40px 20px;
    background: #f8f9fa;
    border: 2px dashed #dee2e6;
    border-radius: 12px;
    color: #6c757d;
}

.comprovante-vazio i {
    font-size: 3rem;
    color: #adb5bd;
    margin-bottom: 15px;
    display: block;
}

.comprovante-vazio p {
    font-size: 1.1rem;
    font-weight: 600;
    margin-bottom: 8px;
    color: #495057;
}

.comprovante-vazio small {
    font-size: 0.9rem;
    color: #6c757d;
}

.comprovante-info {
    background: white;
    border: 1px solid #e9ecef;
    border-radius: 12px;
    padding: 20px;
    box-shadow: 0 2px 8px rgba(0, 0, 0, 0.1);
}

.comprovante-detalhes {
    display: flex;
    flex-direction: column;
    gap: 12px;
    margin-bottom: 20px;
}

.comprovante-item {
    display: flex;
    align-items: center;
    gap: 12px;
    padding: 12px 0;
    border-bottom: 1px solid #f1f3f4;
    transition: all 0.3s ease;
}

.comprovante-item:last-child {
    border-bottom: none;
}

.comprovante-item:hover {
    background: #f8f9fa;
    border-radius: 6px;
    padding-left: 8px;
    padding-right: 8px;
}

.comprovante-item i {
    color: #38b6ff;
    width: 20px;
    text-align: center;
    font-size: 1.1rem;
}

.comprovante-item span {
    font-weight: 600;
    color: #2c3e50;
    font-size: 0.95rem;
}

.comprovante-acoes {
    display: flex;
    gap: 15px;
    flex-wrap: wrap;
    justify-content: center;
    margin-top: 20px;
    padding: 0 10px;
}

.comprovante-imagem {
    max-width: 100%;
    max-height: 300px;
    border-radius: 8px;
    box-shadow: 0 4px 15px rgba(0, 0, 0, 0.1);
    border: 2px solid #e9ecef;
}

/* Botão Visualizar Pagamento */
.btn-acao.visualizar {
    background: linear-gradient(135deg, #17a2b8, #138496);
    color: white;
    border: none;
}

.btn-acao.visualizar:hover {
    background: linear-gradient(135deg, #138496, #117a8b);
    transform: translateY(-2px);
    box-shadow: 0 6px 20px rgba(23, 162, 184, 0.3);
}

/* Botão Anexar Comprovante */
.btn-acao.anexar {
    background: linear-gradient(135deg, #6f42c1, #5a32a3);
    color: white;
    border: none;
}

.btn-acao.anexar:hover {
    background: linear-gradient(135deg, #5a32a3, #4c2a85);
    transform: translateY(-2px);
    box-shadow: 0 6px 20px rgba(111, 66, 193, 0.3);
}

/* Botão Ver Comprovante */
.btn-acao.ver-comprovante {
    background: linear-gradient(135deg, #17a2b8, #138496);
    color: white;
    border: none;
}

.btn-acao.ver-comprovante:hover {
    background: linear-gradient(135deg, #138496, #0f6674);
    transform: translateY(-2px);
    box-shadow: 0 6px 20px rgba(23, 162, 184, 0.3);
}

/* Botão Visualizar */
.btn-visualizar {
    background: linear-gradient(135deg, #6f42c1, #5a32a3);
    color: white;
    border: none;
    padding: 8px 16px;
    border-radius: 8px;
    cursor: pointer;
    font-size: 0.9rem;
    transition: all 0.3s ease;
}

.btn-visualizar:hover {
    background: linear-gradient(135deg, #5a32a3, #4c2a85);
    transform: translateY(-2px);
}

/* Responsividade */
@media (max-width: 768px) {
    .container {
        padding: 15px;
    }
    
    .header h1 {
        font-size: 2rem;
    }
    
    .dashboard-cards {
        grid-template-columns: 1fr;
        gap: 15px;
    }
    
    .filtros {
        flex-direction: column;
        gap: 15px;
    }
    
    .filtro-grupo {
        width: 100%;
        min-width: auto;
    }
    
    .btn-filtro-filtrar,
    .btn-filtro-limpar {
        width: 100%;
        justify-content: center;
    }
    
    .btn-nova-divida {
        min-width: 200px;
        padding: 12px 20px;
        font-size: 1rem;
    }
    
    .tabela-dividas {
        font-size: 0.9rem;
    }
    
    .tabela-dividas th,
    .tabela-dividas td {
        padding: 15px 10px;
    }
    
    .acoes-container {
        flex-direction: column;
        gap: 5px;
    }
    
    .btn-acao {
        width: 35px;
        height: 35px;
        font-size: 0.9rem;
    }
    
    .modal-content {
        width: 94%;
        max-width: 520px;
        max-height: 82vh;
        margin: 6vh auto;
    }
    
    .form-acoes {
        flex-direction: column;
    }
    
    .btn-salvar,
    .btn-confirmar,
    .btn-cancelar {
        width: 100%;
    }

    .comprovante-acoes {
        flex-direction: column;
        align-items: center;
    }

    .btn-visualizar,
    .btn-download {
        width: 100%;
        max-width: 200px;
        justify-content: center;
    }

    .info-grid {
        grid-template-columns: 1fr;
    }

    .valor-final-item {
        grid-column: 1;
    }
}

@media (max-width: 480px) {
    .header h1 {
        font-size: 1.8rem;
    }
    
    .card {
        padding: 20px;
    }
    
    .card-content p {
        font-size: 1.5rem;
    }
    
    .btn-nova-divida {
        min-width: 180px;
        padding: 10px 15px;
        font-size: 0.9rem;
    }
}

/* Estilos do modal de comprovante */
.modal-comprovante {
    max-width: 800px;
    max-height: 90vh;
    overflow: hidden;
}

.modal-body-comprovante {
    padding: 20px;
    max-height: 70vh;
    overflow-y: auto;
}

.comprovante-visualizador {
    text-align: center;
    margin-bottom: 20px;
    min-height: 300px;
    display: flex;
    align-items: center;
    justify-content: center;
    border: 2px dashed #e5e7eb;
    border-radius: 8px;
    background-color: #f9fafb;
}

.comprovante-imagem-full {
    max-width: 100%;
    max-height: 500px;
    border-radius: 8px;
    box-shadow: 0 4px 12px rgba(0,0,0,0.1);
}

.comprovante-pdf-full {
    width: 100%;
    height: 500px;
    border: none;
    border-radius: 8px;
}

.comprovante-loading {
    color: #6b7280;
    font-size: 16px;
}

.comprovante-loading i {
    font-size: 24px;
    margin-bottom: 10px;
    display: block;
}

.comprovante-erro {
    color: #ef4444;
    text-align: center;
}

.comprovante-erro i {
    font-size: 48px;
    margin-bottom: 10px;
    display: block;
}

.comprovante-detalhes {
    background-color: #f3f4f6;
    padding: 15px;
    border-radius: 8px;
    margin-top: 15px;
}

.comprovante-detalhes p {
    margin: 5px 0;
    font-size: 14px;
}

.comprovante-info {
    display: flex;
    flex-direction: column;
    gap: 5px;
    margin-bottom: 15px;
}

.comprovante-info span {
    font-size: 14px;
    color: #6b7280;
}

.comprovante-acoes {
    display: flex;
    gap: 10px;
    justify-content: center;
}

.btn-visualizar {
    background: linear-gradient(135deg, #6f42c1, #5a32a3);
    color: white;
    border: none;
    padding: 12px 24px;
    border-radius: 8px;
    cursor: pointer;
    display: flex;
    align-items: center;
    gap: 8px;
    font-size: 14px;
    font-weight: 600;
    transition: all 0.3s ease;
    box-shadow: 0 2px 8px rgba(111, 66, 193, 0.2);
    min-width: 140px;
    justify-content: center;
    white-space: nowrap;
}

.btn-visualizar:hover {
    background: linear-gradient(135deg, #5a32a3, #4c2a85);
    transform: translateY(-2px);
    box-shadow: 0 4px 12px rgba(111, 66, 193, 0.3);
}

.btn-download {
    background: linear-gradient(135deg, #28a745, #20c997);
    color: white;
    border: none;
    padding: 12px 24px;
    border-radius: 8px;
    cursor: pointer;
    display: flex;
    align-items: center;
    gap: 8px;
    font-size: 14px;
    font-weight: 600;
    transition: all 0.3s ease;
    box-shadow: 0 2px 8px rgba(40, 167, 69, 0.2);
    min-width: 100px;
    justify-content: center;
    white-space: nowrap;
}

.btn-download:hover {
    background: linear-gradient(135deg, #20c997, #17a2b8);
    transform: translateY(-2px);
    box-shadow: 0 4px 12px rgba(40, 167, 69, 0.3);
}
/* Respo
nsividade */
@media (max-width: 768px) {
    .dividas-distribuidores-container {
        padding: 10px;
    }

    .header-content {
        flex-direction: column;
        text-align: center;
    }

    .header-info h1 {
        font-size: 2rem;
    }

    .header-info p {
        font-size: 1rem;
    }
}