/* 📄 Invoice Modal - CSS Limpo e Responsivo */

/* Modal Base */
#invoiceModal {
    display: none;
    position: fixed;
    z-index: 10000;
    left: 0;
    top: 0;
    width: 100%;
    height: 100%;
    background: rgba(0, 0, 0, 0.7);
    backdrop-filter: blur(8px);
    align-items: center;
    justify-content: center;
    overflow: visible;
}

#invoiceModal.show {
    display: flex;
}

/* Modal Content Container */
#invoiceModal .modal-content {
    background: linear-gradient(145deg, #ffffff 0%, #f8faff 100%);
    border: 2px solid rgba(0, 255, 65, 0.2);
    border-radius: 16px;
    width: min(85vw, 900px);
    max-width: 900px;
    max-height: 85vh;
    position: relative;
    box-shadow: 0 20px 40px rgba(0, 0, 0, 0.15);
    overflow: visible;
    animation: modalFadeIn 0.3s ease-out;
}

@keyframes modalFadeIn {
    from {
        opacity: 0;
        transform: scale(0.9);
    }
    to {
        opacity: 1;
        transform: scale(1);
    }
}

/* Modal Close Button */
#invoiceModal .modal-close {
    position: absolute;
    top: 12px;
    right: 12px;
    background: rgba(239, 68, 68, 0.1);
    border: 1px solid rgba(239, 68, 68, 0.3);
    color: #ef4444;
    width: 32px;
    height: 32px;
    border-radius: 50%;
    font-size: 16px;
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    transition: all 0.2s ease;
    z-index: 100;
}

#invoiceModal .modal-close:hover {
    background: rgba(239, 68, 68, 0.2);
    transform: scale(1.1);
    box-shadow: 0 4px 12px rgba(239, 68, 68, 0.3);
}

/* Modal Header */
#invoiceModal .modal-header {
    padding: 24px 24px 16px;
    text-align: center;
    border-bottom: 2px solid rgba(0, 255, 65, 0.1);
    background: linear-gradient(135deg, rgba(0, 255, 65, 0.05) 0%, rgba(255, 255, 255, 0.8) 100%);
}

#invoiceModal .modal-header h2 {
    color: #1e293b;
    font-size: 22px;
    font-weight: 700;
    margin: 0 0 8px;
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 8px;
}

#invoiceModal .modal-header h2 i {
    color: #00ff41;
    font-size: 20px;
}

#invoiceModal .modal-header p {
    color: #64748b;
    font-size: 16px;
    margin: 0;
    line-height: 1.4;
}

/* Modal Body */
#invoiceModal .modal-body {
    padding: 20px 24px 24px;
    max-height: calc(85vh - 120px);
    overflow-y: auto;
}

/* Form Styles */
#invoiceModal .cpf-form {
    margin-bottom: 20px;
}

#invoiceModal .form-group {
    margin-bottom: 16px;
}

#invoiceModal .form-group label {
    display: block;
    color: #374151;
    font-size: 16px;
    font-weight: 600;
    margin-bottom: 8px;
}

#invoiceModal .form-control {
    width: 100%;
    padding: 12px 16px;
    border: 2px solid #e2e8f0;
    border-radius: 10px;
    font-size: 16px;
    background: #fff;
    color: #1e293b; /* Garantir texto escuro no input */
    transition: all 0.3s ease;
    box-sizing: border-box;
}

#invoiceModal .form-control:focus {
    outline: none;
    border-color: #00ff41;
    box-shadow: 0 0 0 4px rgba(0, 255, 65, 0.15);
    background: #fafffe;
    color: #1e293b; /* Garantir texto escuro no foco */
}

/* Placeholder dos inputs */
#invoiceModal .form-control::placeholder {
    color: #64748b;
    opacity: 1;
}

/* Button Styles */
#invoiceModal .btn {
    background: linear-gradient(135deg, #00ff41 0%, #00c853 100%);
    color: white;
    border: none;
    padding: 14px 20px;
    border-radius: 10px;
    font-size: 16px;
    font-weight: 600;
    cursor: pointer;
    transition: all 0.3s ease;
    width: 100%;
    box-shadow: 0 4px 15px rgba(0, 255, 65, 0.2);
}

#invoiceModal .btn:hover {
    transform: translateY(-2px);
    box-shadow: 0 8px 25px rgba(0, 255, 65, 0.4);
    background: linear-gradient(135deg, #00c853 0%, #00ff41 100%);
}

#invoiceModal .btn:active {
    transform: translateY(0);
    box-shadow: 0 4px 15px rgba(0, 255, 65, 0.3);
}

#invoiceModal .btn:disabled {
    opacity: 0.5;
    cursor: not-allowed;
    transform: none;
    box-shadow: none;
}

/* Loading State */
#invoiceModal .loading {
    text-align: center;
    padding: 40px 20px;
    display: none;
}

#invoiceModal .loading p {
    color: #64748b;
    font-size: 16px;
    margin-top: 16px;
}

#invoiceModal .spinner {
    border: 3px solid #f3f4f6;
    border-top: 3px solid #00ff41;
    border-radius: 50%;
    width: 32px;
    height: 32px;
    animation: spin 1s linear infinite;
    margin: 0 auto;
}

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

/* Customer Info */
#invoiceModal .customer-info {
    background: linear-gradient(135deg, rgba(0, 255, 65, 0.08) 0%, rgba(0, 255, 65, 0.03) 100%);
    border: 2px solid rgba(0, 255, 65, 0.15);
    border-radius: 12px;
    padding: 16px;
    margin-bottom: 20px;
}

#invoiceModal .customer-info h3 {
    color: #1e293b;
    font-size: 18px;
    font-weight: 700;
    margin: 0 0 12px;
    display: flex;
    align-items: center;
    gap: 8px;
}

#invoiceModal .customer-info h3 i {
    color: #00ff41;
    font-size: 18px;
}

#invoiceModal .customer-info p {
    color: #64748b;
    font-size: 15px;
    margin: 6px 0;
    line-height: 1.4;
}

#invoiceModal .customer-info strong {
    color: #374151;
    font-weight: 600;
}

#invoiceModal .services-header {
    margin-bottom: 16px;
}

#invoiceModal .services-header h3 {
    color: #1e293b;
    font-size: 18px;
    font-weight: 700;
    margin: 0 0 4px;
    display: flex;
    align-items: center;
    gap: 8px;
}

#invoiceModal .services-header h3 i {
    color: #00ff41;
}

#invoiceModal .services-header p {
    color: #64748b;
    font-size: 15px;
    margin: 0;
}

/* Services Grid */
#invoiceModal .services-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(280px, 1fr));
    gap: 16px;
    margin-bottom: 20px;
}

/* Service Cards */
#invoiceModal .service-card {
    background: #fff;
    border: 2px solid #e2e8f0;
    border-radius: 12px;
    padding: 16px;
    cursor: pointer;
    transition: all 0.3s ease;
    position: relative;
    box-shadow: 0 2px 8px rgba(0, 0, 0, 0.05);
}

#invoiceModal .service-card:hover {
    border-color: #00ff41;
    transform: translateY(-3px);
    box-shadow: 0 12px 30px rgba(0, 255, 65, 0.2);
}

#invoiceModal .service-card.selected {
    border-color: #00ff41;
    background: linear-gradient(135deg, rgba(0, 255, 65, 0.08) 0%, rgba(0, 255, 65, 0.03) 100%);
    box-shadow: 0 8px 25px rgba(0, 255, 65, 0.15);
}

#invoiceModal .service-header {
    display: flex;
    justify-content: space-between;
    align-items: flex-start;
    margin-bottom: 12px;
    gap: 12px;
    min-height: 32px;
}

#invoiceModal .service-title {
    color: #1e293b;
    font-size: 17px;
    font-weight: 700;
    margin: 0;
    flex: 1;
    line-height: 1.3;
    word-wrap: break-word;
    overflow-wrap: break-word;
    max-width: calc(100% - 120px);
}

#invoiceModal .service-status {
    padding: 6px 12px;
    border-radius: 20px;
    font-size: 11px;
    font-weight: 600;
    text-transform: uppercase;
    color: white;
    background: #10b981;
    min-width: 100px;
    max-width: 130px;
    width: auto;
    text-align: center;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
    flex-shrink: 0;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    height: 26px;
    box-sizing: border-box;
}

#invoiceModal .service-status.suspended {
    background: #f59e0b;
}

#invoiceModal .service-status.cancelled {
    background: #ef4444;
}

#invoiceModal .service-details {
    margin-bottom: 6px;
}

#invoiceModal .service-info {
    display: flex;
    align-items: center;
    margin-bottom: 8px;
    padding: 8px 12px;
    border-radius: 8px;
    background: rgba(248, 250, 255, 0.7);
    transition: all 0.3s ease;
}

#invoiceModal .service-info:hover {
    background: rgba(0, 255, 65, 0.05);
}

#invoiceModal .service-info i {
    color: #00ff41;
    width: 12px;
    margin-right: 6px;
    font-size: 10px;
}

#invoiceModal .service-info strong {
    color: #64748b;
    font-size: 13px;
    font-weight: 600;
    margin-right: 8px;
    min-width: 70px;
    text-transform: uppercase;
}

#invoiceModal .service-info span {
    color: #1e293b;
    font-size: 15px;
    font-weight: 500;
    flex: 1;
    line-height: 1.3;
}

#invoiceModal .service-price {
    font-size: 17px;
    font-weight: 700;
    color: #00ff41;
    text-shadow: 0 1px 2px rgba(0, 255, 65, 0.3);
}

#invoiceModal .service-actions {
    text-align: center;
    margin-top: 12px;
}

#invoiceModal .service-actions .btn {
    padding: 10px 20px;
    font-size: 14px;
    font-weight: 600;
    width: auto;
    display: inline-block;
    min-width: 120px;
}

/* Invoice Results */
#invoiceModal .invoice-results {
    display: none;
}

/* Invoice Filters */
#invoiceModal .invoice-filters {
    display: flex;
    gap: 8px;
    margin-bottom: 16px;
    padding: 8px;
    background: linear-gradient(135deg, rgba(0, 255, 65, 0.05) 0%, rgba(255, 255, 255, 0.8) 100%);
    border-radius: 10px;
    border: 1px solid rgba(0, 255, 65, 0.1);
    flex-wrap: wrap;
    justify-content: center;
}

#invoiceModal .filter-btn {
    background: linear-gradient(135deg, #f1f5f9 0%, #e2e8f0 100%);
    color: #64748b;
    border: 1px solid #e2e8f0;
    padding: 8px 12px;
    border-radius: 8px;
    font-size: 12px;
    font-weight: 600;
    cursor: pointer;
    transition: all 0.3s ease;
    display: flex;
    align-items: center;
    gap: 4px;
    text-transform: uppercase;
    letter-spacing: 0.5px;
    min-width: 70px;
    justify-content: center;
    flex: 1;
}

#invoiceModal .filter-btn:hover {
    transform: translateY(-1px);
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.1);
    background: linear-gradient(135deg, #e2e8f0 0%, #cbd5e1 100%);
    color: #475569;
}

#invoiceModal .filter-btn.active {
    background: linear-gradient(135deg, #00ff41 0%, #00c853 100%);
    color: white;
    border-color: #00ff41;
    box-shadow: 0 4px 15px rgba(0, 255, 65, 0.3);
    transform: translateY(-1px);
}

#invoiceModal .filter-btn.active:hover {
    background: linear-gradient(135deg, #00c853 0%, #00ff41 100%);
    box-shadow: 0 6px 20px rgba(0, 255, 65, 0.4);
}

#invoiceModal .filter-btn i {
    font-size: 10px;
}

#invoiceModal .invoices-list {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(350px, 1fr));
    gap: 12px;
}

#invoiceModal .invoice-card {
    background: #fff;
    border: 1px solid #e2e8f0;
    border-radius: 6px;
    padding: 8px;
    transition: all 0.3s ease;
}

#invoiceModal .invoice-card:hover {
    border-color: #00ff41;
    box-shadow: 0 4px 15px rgba(0, 255, 65, 0.1);
}

#invoiceModal .invoice-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 6px;
}

#invoiceModal .invoice-number {
    color: #1e293b;
    font-size: 17px;
    font-weight: 700;
    margin: 0;
}

#invoiceModal .invoice-status {
    padding: 2px 6px;
    border-radius: 12px;
    font-size: 8px;
    font-weight: 500;
    text-transform: uppercase;
    color: white;
}

#invoiceModal .invoice-status.success {
    background: #10b981;
}

#invoiceModal .invoice-status.warning {
    background: #f59e0b;
}

#invoiceModal .invoice-status.danger {
    background: #ef4444;
}

#invoiceModal .invoice-info {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(80px, 1fr));
    gap: 4px;
    margin-bottom: 6px;
}

#invoiceModal .invoice-detail {
    display: flex;
    flex-direction: column;
    background: rgba(248, 250, 255, 0.5);
    padding: 8px;
    border-radius: 8px;
}

#invoiceModal .invoice-detail strong {
    color: #64748b;
    font-size: 13px;
    font-weight: 600;
    text-transform: uppercase;
    margin-bottom: 4px;
}

#invoiceModal .invoice-detail span {
    color: #1e293b;
    font-size: 15px;
    font-weight: 600;
    line-height: 1.3;
}

#invoiceModal .invoice-actions {
    text-align: center;
    border-top: 1px solid #e2e8f0;
    padding-top: 12px;
    margin-top: 8px;
}

#invoiceModal .btn-download {
    background: linear-gradient(135deg, #3b82f6 0%, #1d4ed8 100%);
    color: white;
    text-decoration: none;
    padding: 8px 16px;
    border-radius: 8px;
    font-size: 13px;
    font-weight: 600;
    display: inline-flex;
    align-items: center;
    gap: 6px;
    transition: all 0.3s ease;
    box-shadow: 0 2px 8px rgba(59, 130, 246, 0.2);
}

#invoiceModal .btn-download:hover {
    transform: translateY(-1px);
    box-shadow: 0 4px 15px rgba(59, 130, 246, 0.3);
}

/* Back Button */
#invoiceModal .btn-back {
    background: linear-gradient(135deg, #6b7280 0%, #4b5563 100%);
    color: white;
    border: none;
    padding: 10px 20px;
    border-radius: 8px;
    font-size: 14px;
    font-weight: 600;
    cursor: pointer;
    display: inline-flex;
    align-items: center;
    gap: 8px;
    transition: all 0.3s ease;
    box-shadow: 0 2px 8px rgba(107, 114, 128, 0.2);
}

#invoiceModal .btn-back:hover {
    transform: translateY(-1px);
    box-shadow: 0 4px 15px rgba(107, 114, 128, 0.3);
}

/* Back Section */
.back-section {
    text-align: center;
    margin-top: 20px;
    padding-top: 16px;
    border-top: 1px solid rgba(0, 255, 65, 0.1);
}

/* Responsive Design */
@media (max-width: 768px) {
    #invoiceModal .modal-content {
        width: min(95vw, 418px);
        max-height: 90vh;
    }
    
    
    #invoiceModal .modal-header {
        padding: 20px 20px 12px;
    }
    
    #invoiceModal .modal-body {
        padding: 16px 20px 20px;
        max-height: calc(90vh - 100px);
    }
    
    #invoiceModal .modal-header h2 {
        font-size: 20px;
    }
    
    #invoiceModal .modal-header p {
        font-size: 15px;
    }
    
    #invoiceModal .service-header {
        flex-direction: row;
        gap: 8px;
        align-items: flex-start;
        min-height: 28px;
    }
    
    #invoiceModal .service-title {
        font-size: 15px;
        max-width: calc(100% - 90px);
        line-height: 1.2;
    }

    #invoiceModal .service-status {
        font-size: 10px;
        padding: 4px 8px;
        min-width: 70px;
        max-width: 80px;
        height: 20px;
    }
    
    #invoiceModal .invoice-info {
        grid-template-columns: 1fr;
        gap: 8px;
    }
    
    #invoiceModal .service-card,
    #invoiceModal .invoice-card {
        padding: 12px;
    }
    
    #invoiceModal .customer-info {
        padding: 12px;
    }
    
    #invoiceModal .form-control {
        padding: 10px 14px;
        font-size: 16px;
    }
    
    #invoiceModal .btn {
        padding: 12px 16px;
        font-size: 15px;
    }
    
    #invoiceModal .filter-btn {
        padding: 6px 8px;
        font-size: 10px;
        min-width: 60px;
    }
}

@media (max-width: 480px) {
    #invoiceModal .modal-content {
        width: min(98vw, 385px);
        margin: 10px;
    }
    
    
    #invoiceModal .modal-header,
    #invoiceModal .modal-body {
        padding-left: 16px;
        padding-right: 16px;
    }
    
    #invoiceModal .service-info strong {
        min-width: 60px;
        font-size: 12px;
    }
    
    #invoiceModal .service-info span,
    #invoiceModal .invoice-detail span {
        font-size: 14px;
    }
    
    #invoiceModal .filter-btn {
        padding: 5px 6px;
        font-size: 9px;
        min-width: 50px;
        gap: 2px;
    }
    
    #invoiceModal .filter-btn i {
        font-size: 8px;
    }

    /* Ajuste adicional para service header em telas pequenas */
    #invoiceModal .service-header {
        flex-wrap: nowrap;
        align-items: center;
    }
    
    #invoiceModal .service-title {
        font-size: 14px;
        max-width: calc(100% - 85px);
    }

    #invoiceModal .service-status {
        font-size: 9px;
        padding: 3px 6px;
        min-width: 65px;
        max-width: 75px;
        height: 18px;
    }
}

@media (max-width: 320px) {
    #invoiceModal .modal-content {
        width: min(96vw, 330px);
    }
    
    
    #invoiceModal .modal-header h2 {
        font-size: 18px;
    }
    
    
    #invoiceModal .filter-btn {
        padding: 4px 5px;
        font-size: 8px;
        min-width: 45px;
    }

    /* Service header para telas muito pequenas */
    #invoiceModal .service-title {
        font-size: 13px;
        max-width: calc(100% - 75px);
    }

    #invoiceModal .service-status {
        font-size: 8px;
        padding: 2px 4px;
        min-width: 55px;
        max-width: 65px;
        height: 16px;
    }
}

#invoiceModal .mascot-container {
    position: absolute;
    top: 40%;
    left: calc(100% + 30px);
    transform: translateY(-52%);
    width: 400px;
    height: 400px;
    z-index: 101;
}

/* Imagem do boleto no lado esquerdo */
#invoiceModal .boleto-container {
    position: absolute;
    top: 50%;
    left: calc(-15vw - 15px);
    transform: translateY(-50%);
    width: min(20vw, 250px);
    height: auto;
    z-index: 102;
    padding: 5px;
    box-sizing: border-box;
    /* Garantir que não saia da tela */
    min-width: 0;
    overflow: visible;
}

#invoiceModal .boleto-image {
    width: 100%;
    height: auto;
    object-fit: contain;
    filter: drop-shadow(0 8px 16px rgba(0, 0, 0, 0.2));
    border-radius: 12px;
}

#invoiceModal .mascot-image {
    width: 100%;
    height: 100%;
    object-fit: contain;
    filter: drop-shadow(0 4px 12px rgba(0, 0, 0, 0.15));
}

/* Resoluções entre 1200px e 768px */
@media (max-width: 1200px) {
    #invoiceModal .modal-content {
        width: min(90vw, 800px);
    }
    
    #invoiceModal .boleto-container {
        left: calc(-14vw - 12px);
        width: min(18vw, 200px);
    }
}

/* Resoluções entre 992px e 768px */
@media (max-width: 992px) {
    #invoiceModal .modal-content {
        width: min(92vw, 700px);
    }
    
    #invoiceModal .boleto-container {
        left: calc(-12vw - 10px);
        width: min(16vw, 160px);
    }
}

@media (max-width: 768px) {
    #invoiceModal .mascot-container {
        width: 80px;
        height: 80px;
        left: calc(100% + 8px);
    }
    
    #invoiceModal .boleto-container {
        width: min(14vw, 110px);
        left: calc(-10vw - 8px);
        top: 30%;
        padding: 3px;
    }
}

@media (max-width: 480px) {
    #invoiceModal .mascot-container {
        width: 70px;
        height: 70px;
        left: calc(100% + 6px);
    }
    
    #invoiceModal .boleto-container {
        width: min(12vw, 90px);
        left: calc(-8vw - 5px);
        top: 25%;
        padding: 2px;
    }
}

/* Para telas muito pequenas */
@media (max-width: 320px) {
    #invoiceModal .boleto-container {
        width: min(10vw, 70px);
        left: calc(-6vw - 3px);
        top: 20%;
        padding: 1px;
    }
}

/* Abordagem mais conservadora para telas pequenas */
@media (max-width: 800px) {
    #invoiceModal .boleto-container {
        /* Usar porcentagem menor e mais margem de segurança */
        left: calc(-11vw - 10px);
        width: min(15vw, 120px);
    }
}

/* Breakpoints adicionais para modal totalmente responsivo */
@media (max-width: 640px) {
    #invoiceModal .modal-content {
        width: min(94vw, 600px);
    }
    
    #invoiceModal .boleto-container {
        left: calc(-9vw - 8px);
        width: min(13vw, 100px);
        top: 35%;
    }
}

@media (max-width: 540px) {
    #invoiceModal .modal-content {
        width: min(96vw, 500px);
    }
    
    #invoiceModal .boleto-container {
        left: calc(-7vw - 6px);
        width: min(11vw, 80px);
        top: 30%;
    }
}

@media (max-width: 420px) {
    #invoiceModal .modal-content {
        width: min(97vw, 400px);
    }
    
    #invoiceModal .boleto-container {
        left: calc(-6vw - 4px);
        width: min(9vw, 65px);
        top: 25%;
    }
}

@media (max-width: 360px) {
    #invoiceModal .modal-content {
        width: min(98vw, 340px);
    }
    
    #invoiceModal .boleto-container {
        left: calc(-5vw - 3px);
        width: min(8vw, 55px);
        top: 22%;
    }
}

/* Para telas extremamente pequenas - ocultar imagem se necessário */
@media (max-width: 280px) {
    #invoiceModal .modal-content {
        width: min(99vw, 270px);
    }
    
    #invoiceModal .boleto-container {
        display: none;
    }
}

/* ===== ESTILOS PARA CORREÇÃO DE CONTRASTE ===== */

/* Garantir contraste adequado para texto em fundos brancos */
#invoiceModal .modal-content {
    color: #1e293b; /* Cor escura padrão para todo o conteúdo */
}

/* Serviços suspensos - tema vermelho */
#invoiceModal .modal-content.suspended-service {
    border: 2px solid rgba(239, 68, 68, 0.3);
    background: linear-gradient(145deg, #fef2f2 0%, #fce8e8 100%);
}

#invoiceModal .modal-content.suspended-service .modal-header {
    background: linear-gradient(135deg, rgba(239, 68, 68, 0.1) 0%, rgba(255, 255, 255, 0.9) 100%);
    border-bottom: 2px solid rgba(239, 68, 68, 0.2);
}

#invoiceModal .modal-content.suspended-service .customer-info {
    background: linear-gradient(135deg, rgba(239, 68, 68, 0.08) 0%, rgba(239, 68, 68, 0.03) 100%);
    border: 2px solid rgba(239, 68, 68, 0.2);
}

/* Status suspenso específico */
.status-suspended {
    color: #dc2626 !important;
    font-weight: 700;
}

/* Garantir que todos os textos em elementos com fundo branco sejam escuros */
#invoiceModal .service-card,
#invoiceModal .invoice-card,
#invoiceModal .customer-info,
#invoiceModal .modal-content {
    color: #1e293b;
}

/* Textos específicos que devem ser escuros */
#invoiceModal .service-card h4,
#invoiceModal .service-card p,
#invoiceModal .service-card span:not(.service-status),
#invoiceModal .invoice-card h4,
#invoiceModal .invoice-card p,
#invoiceModal .invoice-card span:not(.invoice-status),
#invoiceModal .customer-info p,
#invoiceModal .customer-info h3,
#invoiceModal .service-info span,
#invoiceModal .service-info strong,
#invoiceModal .invoice-detail span,
#invoiceModal .invoice-detail strong {
    color: #1e293b !important;
}

/* Garantir que títulos sejam sempre visíveis */
#invoiceModal .service-title,
#invoiceModal .invoice-number {
    color: #1e293b !important;
    font-weight: 700;
}

/* Status badges - manter cores de fundo mas garantir contraste */
#invoiceModal .service-status,
#invoiceModal .invoice-status {
    color: white !important;
}

/* Ícones mantêm cor verde */
#invoiceModal .service-info i,
#invoiceModal .modal-header h2 i {
    color: #00ff41 !important;
}

/* Preços mantêm cor verde */
#invoiceModal .service-price {
    color: #00ff41 !important;
}

/* Botões mantêm suas cores originais */
#invoiceModal .btn,
#invoiceModal .btn-download,
#invoiceModal .btn-back,
#invoiceModal .filter-btn {
    /* Cores originais preservadas */
}

/* Hover states com melhor contraste */
#invoiceModal .service-info:hover,
#invoiceModal .invoice-detail:hover {
    background: rgba(0, 255, 65, 0.05);
    color: #1e293b !important;
}

/* Links no rodapé */
#invoiceModal a {
    color: #00ff41 !important;
}

/* ===== CORREÇÕES ADICIONAIS DE CONTRASTE ===== */

/* Garantir que TODOS os elementos de texto sejam legíveis */
#invoiceModal * {
    /* Resetar qualquer herança problemática */
}

/* Textos em geral */
#invoiceModal p,
#invoiceModal h1,
#invoiceModal h2,
#invoiceModal h3,
#invoiceModal h4,
#invoiceModal h5,
#invoiceModal h6,
#invoiceModal div,
#invoiceModal span:not(.service-status):not(.invoice-status),
#invoiceModal label {
    color: #1e293b !important;
}

/* Específico para elementos que podem ter problemas */
#invoiceModal .services-header p,
#invoiceModal .services-header h3,
#invoiceModal .customer-details p,
#invoiceModal .selectedServiceInfo p,
#invoiceModal .invoice-results h3 {
    color: #1e293b !important;
}

/* Loading text */
#invoiceModal .loading p {
    color: #64748b !important;
}

/* Garantir que inputs sejam sempre legíveis */
#invoiceModal input,
#invoiceModal textarea,
#invoiceModal select {
    color: #1e293b !important;
    background: #fff !important;
}

/* Para casos específicos de debug - temporário */
#invoiceModal .debug-text {
    color: #dc2626 !important;
    font-weight: bold;
    background: yellow !important;
}

