/* ==========================================
   CONSULTA
=========================================== */

.luvaepi-ca-consulta {
    width: 100%;
    font-family: inherit;
    color: #222;
}

.luvaepi-ca-consulta label {
    display: block;
    font-weight: 600;
    margin-bottom: 7px;
    color: #333;
}

.luvaepi-ca-busca {
    width: 100%;
}

.luvaepi-ca-numero {
    width: 100%;
    padding: 14px;
    border: 1px solid #d5d5d5;
    border-radius: 8px;
    font-size: 16px;
    box-sizing: border-box;
    outline: none;
    background: #fff;
}

.luvaepi-ca-numero:focus {
    border-color: #e60012;
}

.luvaepi-ca-botao {
    width: 100%;
    margin-top: 6px;
    min-height: 54px !important;
    padding: 0 14px !important;
    border: none;
    border-radius: 8px;
    font-size: 15px;
    font-weight: 700;
    cursor: pointer;
    background: #e60012;
    color: #fff;

    display: flex !important;
    align-items: center !important;
    justify-content: center !important;
    text-align: center !important;
    line-height: normal !important;
    box-sizing: border-box !important;
}

.luvaepi-ca-botao:hover {
    opacity: .9;
}

.luvaepi-ca-botao:disabled {
    opacity: .65;
    cursor: wait;
}

.luvaepi-ca-resultado {
    margin-top: 22px;
}


/* ==========================================
   CARD PRINCIPAL
=========================================== */

.ca-card {
    border: 1px solid #e3e3e3;
    border-radius: 10px;
    overflow: hidden;
    background: #fff;
}


/* ==========================================
   CABEÇALHO
=========================================== */

.ca-cabecalho {
    padding: 20px;
    background: #fafafa;
    border-bottom: 1px solid #e8e8e8;
}

.ca-cabecalho-topo {
    display: flex;
    justify-content: space-between;
    align-items: flex-start;
    gap: 15px;
}

.ca-titulo {
    margin: 0;
    font-size: 26px;
    line-height: 1.2;
    font-weight: 800;
    color: #222;
}

.ca-subtitulo {
    margin-top: 4px;
    font-size: 12px;
    color: #777;
}

.ca-comparar-botao {
    margin-top: 8px;
    padding: 6px 10px;
    border: 1px solid #ee0012;
    border-radius: 6px;
    background: #fff;
    color: #ee0012;
    font-size: 12px;
    font-weight: 700;
    cursor: pointer;
    transition: all .2s ease;
}

.ca-comparar-botao:hover,
.ca-comparar-botao:focus {
    background: #ee0012;
    color: #fff;
    border-color: #ee0012;
}

/* =========================================
   COMPARADOR DE CA
========================================= */

.ca-comparador-overlay {
    position: fixed;
    inset: 0;
    z-index: 99999;
    background: rgba(0, 0, 0, 0.55);
    align-items: center;
    justify-content: center;
    padding: 20px;
    box-sizing: border-box;
}

.ca-comparador-modal {
    width: 100%;
    max-width: 760px;
    max-height: 90vh;
    background: #ffffff;
    border-radius: 12px;
    box-shadow: 0 18px 50px rgba(0, 0, 0, 0.28);
    overflow: hidden;
    display: flex;
    flex-direction: column;
}

.ca-comparador-topo {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 15px;
    padding: 18px 20px;
    border-bottom: 1px solid #e5e5e5;
}

.ca-comparador-topo h3 {
    margin: 0;
    font-size: 19px;
    line-height: 1.3;
    color: #222222;
}

.ca-comparador-fechar {
    flex: 0 0 auto;
    width: 36px;
    height: 36px;
    padding: 0;
    border: none;
    border-radius: 50%;
    background: #f3f3f3;
    color: #555555;
    font-size: 22px;
    line-height: 36px;
    text-align: center;
    cursor: pointer;
}

.ca-comparador-fechar:hover,
.ca-comparador-fechar:focus {
    background: #ee0012;
    color: #ffffff;
}

.ca-comparador-corpo {
    padding: 20px;
    overflow-y: auto;
}

.ca-comparador-atual {
    margin-bottom: 16px;
    padding: 10px 12px;
    border-radius: 6px;
    background: #f5f5f5;
    color: #444444;
    font-size: 13px;
}

.ca-comparador-label {
    display: block;
    margin-bottom: 6px;
    font-size: 12px;
    font-weight: 700;
    color: #333333;
}

.ca-comparador-input {
    width: 100%;
    min-height: 46px;
    padding: 10px 12px;
    border: 1px solid #bdbdbd;
    border-radius: 6px;
    background: #ffffff;
    color: #222222;
    font-size: 15px;
    box-sizing: border-box;
}

.ca-comparador-input:focus {
    border-color: #ee0012;
    outline: none;
}

.ca-comparador-executar {
    width: 100%;
    margin-top: 14px;
    min-height: 46px;
    padding: 10px 14px;
    border: 1px solid #ee0012;
    border-radius: 6px;
    background: #ee0012;
    color: #ffffff;
    font-size: 13px;
    font-weight: 800;
    cursor: pointer;
}

.ca-comparador-executar:hover,
.ca-comparador-executar:focus {
    background: #c9000f;
    border-color: #c9000f;
}

/* =========================================
   RESULTADO DA COMPARAÇÃO
========================================= */

.ca-comparador-resultado {
    margin-top: 20px;
}

.ca-comparacao-grid {
    display: grid;
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 16px;
}

.ca-comparacao-coluna {
    border: 1px solid #e2e2e2;
    border-radius: 8px;
    background: #ffffff;
    overflow: hidden;
}

.ca-comparacao-coluna h4 {
    margin: 0;
    padding: 12px 14px;
    background: #f5f5f5;
    border-bottom: 2px solid #ee0012;
    font-size: 18px;
    color: #222222;
}

.ca-comparacao-item {
    padding: 10px 14px;
    border-bottom: 1px solid #eeeeee;
}

.ca-comparacao-item:last-child {
    border-bottom: none;
}

.ca-comparacao-item span {
    display: block;
    margin-bottom: 3px;
    font-size: 11px;
    font-weight: 700;
    color: #777777;
    text-transform: uppercase;
}

.ca-comparacao-item strong {
    display: block;
    font-size: 13px;
    line-height: 1.5;
    color: #222222;
    word-break: break-word;
}

.ca-comparacao-comercial-controle {
    margin-top: 18px;
}

.ca-comparacao-comercial-botao {
    width: 100%;
    min-height: 46px;
    padding: 12px 14px;
    border: 1px solid #ee0012;
    border-radius: 7px;
    background: #ee0012;
    color: #ffffff;
    font-size: 13px;
    font-weight: 800;
    line-height: 1.4;
    cursor: pointer;
    box-sizing: border-box;
}

.ca-comparacao-comercial-botao:hover,
.ca-comparacao-comercial-botao:focus {
    background: #c9000f;
    border-color: #c9000f;
    color: #ffffff;
}

.ca-status {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    padding: 7px 11px;
    border-radius: 20px;
    font-size: 12px;
    font-weight: 800;
    white-space: nowrap;
}

.ca-status-valido {
    background: #e7f6ea;
    color: #207227;
}

.ca-status-vencido {
    background: #fff1d6;
    color: #9a5800;
}

.ca-status-alerta {
    background: #fde8e7;
    color: #b42318;
}


/* ==========================================
   VALIDADE
=========================================== */

.ca-validade-box {
    margin-top: 17px;
    display: grid;
    grid-template-columns: repeat(2, minmax(130px, 1fr));
    column-gap: 25px;
    row-gap: 4px;
}

.ca-info-rapida {
    min-width: 130px;
}

.ca-info-rapida-label {
    font-size: 10px;
    font-weight: 800;
    text-transform: uppercase;
    letter-spacing: .4px;
    color: #777;
}

.ca-info-rapida-valor {
    margin-top: 3px;
    font-size: 14px;
    font-weight: 700;
}

.ca-validade-mensagem {
    grid-column: 2;
    margin-top: -2px;
    font-size: 11px;
    line-height: 1.4;
    font-weight: 500;
    color: #777;
}


/* ==========================================
   SEÇÕES
=========================================== */

.ca-secao {
    padding: 20px;
    border-bottom: 1px solid #ededed;
}

.ca-secao:last-of-type {
    border-bottom: none;
}

.ca-secao-titulo {
    margin: 0 0 15px 0;
    padding-bottom: 8px;
    border-bottom: 2px solid #e60012;
    font-size: 14px;
    font-weight: 800;
    text-transform: uppercase;
    color: #222;
}


/* ==========================================
   CAMPOS
=========================================== */

.ca-grid {
    display: grid;
    grid-template-columns:
        repeat(2, minmax(0, 1fr));
    gap: 0 25px;
}

.ca-campo {
    padding: 11px 0;
    border-bottom: 1px solid #eeeeee;
    min-width: 0;
}

.ca-campo-largo {
    grid-column: 1 / -1;
}

.ca-label {
    margin-bottom: 5px;
    font-size: 10px;
    line-height: 1.3;
    font-weight: 800;
    text-transform: uppercase;
    letter-spacing: .25px;
    color: #666;
}

.ca-valor {
    font-size: 14px;
    line-height: 1.6;
    color: #222;
    white-space: pre-line;
    overflow-wrap: anywhere;
}


/* ==========================================
   BOTÃO DETALHES
=========================================== */

.ca-detalhes-controle {
    padding: 0 20px 20px;
}

.ca-detalhes-botao {
    width: 100%;
    padding: 13px 15px;
    border: 1px solid #dddddd;
    border-radius: 7px;
    background: #f7f7f7;
    color: #333;
    font-size: 12px;
    font-weight: 800;
    cursor: pointer;
}

.ca-detalhes-botao:hover {
    background: #eeeeee;
}


/* ==========================================
   FONTE
=========================================== */

.ca-fonte {
    padding: 13px 20px;
    border-top: 1px solid #ededed;
    background: #fafafa;
    font-size: 10px;
    line-height: 1.5;
    color: #777;
}


/* ==========================================
   MENSAGENS
=========================================== */

.ca-aviso,
.ca-nao-encontrado,
.ca-erro {
    padding: 16px;
    border-radius: 8px;
    background: #f5f5f5;
    line-height: 1.5;
}

.ca-nao-encontrado {
    border-left: 4px solid #777;
}

.ca-erro {
    border-left: 4px solid #e60012;
}

.ca-carregando {
    padding: 15px 0;
}


/* ==========================================
   MOBILE
=========================================== */

@media (max-width: 600px) {

    .ca-cabecalho {
        padding: 16px;
    }

    .ca-cabecalho-topo {
        flex-direction: column;
        gap: 10px;
    }

    .ca-titulo {
        font-size: 23px;
    }
    
    .ca-comparar-botao {
        margin-top: 6px;
        padding: 6px 9px;
        font-size: 11px;
        align-self: flex-start;
    }
    
    .ca-comparador-overlay {
    padding: 14px;
}

.ca-comparador-modal {
    max-width: 100%;
    max-height: 92vh;
    border-radius: 10px;
}

.ca-comparador-topo {
    padding: 16px;
    gap: 10px;
}

.ca-comparador-topo h3 {
    font-size: 17px;
}

.ca-comparador-fechar {
    width: 34px;
    height: 34px;
    font-size: 20px;
    line-height: 34px;
}

.ca-comparador-corpo {
    padding: 16px;
}

.ca-comparador-atual {
    margin-bottom: 14px;
    font-size: 12px;
}

.ca-comparador-input {
    min-height: 44px;
    font-size: 14px;
}

.ca-comparador-executar {
    min-height: 44px;
    font-size: 12px;
}

.ca-comparacao-grid {
    grid-template-columns: 1fr;
}

.ca-comparacao-coluna h4 {
    font-size: 17px;
}

.ca-comparacao-comercial-controle {
    margin-top: 14px;
}

.ca-comparacao-comercial-botao {
    min-height: 52px;
    padding: 12px 10px;
    font-size: 11px;
    line-height: 1.35;
    white-space: normal;
    text-align: center;
}

    .ca-validade-box {
        gap: 15px;
    }

    .ca-secao {
        padding: 16px;
    }

    .ca-grid {
        grid-template-columns: 1fr;
    }

    .ca-campo-largo {
        grid-column: auto;
    }

    .ca-detalhes-controle {
        padding: 0 16px 16px;
    }

    .ca-fonte {
        padding: 12px 16px;
    }

    .ca-valor {
        font-size: 13px;
        line-height: 1.65;
    }
    
    .ca-ficha-campo:nth-child(5) .ca-ficha-valor {
    text-align: left !important;
    }
}

.ca-observacoes-botao {
    width: 100%;
    margin-top: 5px;
    padding: 11px 13px;
    border: 1px solid #dddddd !important;
    border-radius: 6px;
    background: #f7f7f7 !important;
    color: #333333 !important;
    font-size: 11px;
    font-weight: 800;
    cursor: pointer;
    box-shadow: none !important;
}

.ca-observacoes-botao:hover {
    background: #eeeeee !important;
    color: #333333 !important;
}

.ca-observacoes-conteudo {
    margin-top: 12px;
    padding: 16px;
    background: #fafafa;
    border-radius: 6px;
    font-size: 15px;
    line-height: 1.65;
    overflow-wrap: anywhere;
    word-break: normal;
}

.ca-quebra-mobile {
    display: block;
}

.ca-detalhes-botao,
.ca-detalhes-botao:hover,
.ca-detalhes-botao:focus,
.ca-detalhes-botao:active {
    background: #f7f7f7 !important;
    color: #333333 !important;
    border-color: #dddddd !important;
    box-shadow: none !important;
}

.ca-referencia {
    line-height: 1.8;
    word-spacing: 2px;
}

.luvaepi-ca-botao[aria-busy="true"] {
    position: relative;
    cursor: wait;
}

.luvaepi-ca-botao[aria-busy="true"]::after {
    content: "";
    display: inline-block;
    width: 12px;
    height: 12px;
    margin-left: 8px;
    border: 2px solid rgba(255,255,255,.55);
    border-top-color: #fff;
    border-radius: 50%;
    vertical-align: -2px;
    animation: luvaepi-spin .8s linear infinite;
}

@keyframes luvaepi-spin {
    to {
        transform: rotate(360deg);
    }
}

/* ==========================================
   NOVA CONSULTA
=========================================== */

.ca-nova-consulta-controle {
    padding: 0 20px 20px;
}

.luvaepi-ca-consulta .ca-nova-consulta-botao {
    width: 100% !important;
    padding: 13px 15px !important;
    border: 1px solid #e60012 !important;
    border-radius: 7px !important;
    background: #ffffff !important;
    color: #e60012 !important;
    font-size: 12px !important;
    font-weight: 800 !important;
    cursor: pointer !important;
    box-shadow: none !important;
    transition: all .2s ease !important;
}

.luvaepi-ca-consulta .ca-nova-consulta-botao:hover,
.luvaepi-ca-consulta .ca-nova-consulta-botao:focus {
    background: #e60012 !important;
    color: #ffffff !important;
    border-color: #e60012 !important;
}

/* ==========================================
   CTA COMERCIAL
========================================== */

.ca-comercial-controle {
    padding: 10px 20px 0;
    margin-bottom: 12px;
}

.ca-comercial-linha-2 {
    display: inline;
}

.luvaepi-ca-consulta .ca-comercial-botao {
    width: 100% !important;
    padding: 14px 15px !important;
    border: 2px solid #ee0012 !important;
    border-radius: 7px !important;
    background: #ee0012 !important;
    color: #ffffff !important;
    font-size: 13px !important;
    font-weight: 800 !important;
    cursor: pointer !important;
    box-shadow: none !important;
    transition: all .2s ease !important;
}

.luvaepi-ca-consulta .ca-comercial-botao:hover,
.luvaepi-ca-consulta .ca-comercial-botao:focus {
    background: #c9000f !important;
    border-color: #c9000f !important;
    color: #ffffff !important;
}

@media (max-width: 600px) {

    .ca-nova-consulta-controle {
        padding: 0 16px 16px;
    }
    
    .ca-comercial-linha-2 {
        display: block;
        margin-top: 2px;
    }
}

/* ==========================================
   DESKTOP - CONSULTA MAIS LARGA
=========================================== */

@media (min-width: 768px) {

    .luvaepi-ca-consulta {
        max-width: 900px;
        margin-left: auto;
        margin-right: auto;
    }

    .ca-card {
        width: 100%;
    }

    .ca-validade-box {
        display: grid;
        grid-template-columns: 180px 180px;
        column-gap: 30px;
        row-gap: 4px;
        justify-content: start;
    }

    .ca-info-rapida {
        min-width: 0;
    }

    .ca-validade-mensagem {
        grid-column: 2;
    }

    .ca-grid {
        grid-template-columns:
            repeat(2, minmax(0, 1fr));
        gap: 0 30px;
    }
}

/* ==========================================
   IMPRIMIR
=========================================== */

.ca-imprimir-controle {
    padding: 0 20px 10px;
}

.ca-imprimir-botao {
    width: 100% !important;
    padding: 13px 15px !important;
    border: 1px solid #dddddd !important;
    border-radius: 7px !important;
    background: #f7f7f7 !important;
    color: #333333 !important;
    font-size: 12px !important;
    font-weight: 800 !important;
    cursor: pointer !important;
    box-shadow: none !important;
}

.ca-imprimir-botao:hover,
.ca-imprimir-botao:focus {
    background: #eeeeee !important;
    color: #333333 !important;
}

@media (max-width: 600px) {
    .ca-imprimir-controle {
        padding: 0 16px 10px;
    }
}


/* ==========================================
   IMPRESSÃO
=========================================== */

/* ==========================================
   IMPRESSÃO DA FICHA
=========================================== */

@media print {

    body * {
        visibility: hidden !important;
    }

    .ca-ficha-imprimindo,
    .ca-ficha-imprimindo * {
        visibility: visible !important;
    }

    .ca-ficha-imprimindo {
        display: block !important;
        position: absolute !important;
        left: 0 !important;
        top: 0 !important;
        right: 0 !important;
        width: 100% !important;
        height: auto !important;
        padding: 0 !important;
        margin: 0 !important;
        background: #ffffff !important;
        overflow: visible !important;
    }
    
    .ca-ficha-imprimindo.ca-ficha-overlay {
        position: absolute !important;
        inset: auto !important;
        left: 0 !important;
        top: 0 !important;
        right: auto !important;
        bottom: auto !important;

        width: 100% !important;
        height: auto !important;
        min-height: 0 !important;
        max-height: none !important;

        margin: 0 !important;
        padding: 0 !important;

        display: block !important;
        overflow: visible !important;
    }

    .ca-ficha-imprimindo .ca-ficha-modal {
        width: 100% !important;
        max-width: none !important;
        
        height: auto !important;
        min-height: 0 !important;
        max-height: none !important;
        
        margin: 0 !important;
        padding: 0 !important;
        background: #ffffff !important;
        box-shadow: none !important;
        border-radius: 0 !important;
    }

    .ca-ficha-imprimindo .ca-ficha-topo,
    .ca-ficha-imprimindo .ca-ficha-acoes {
        display: none !important;
    }

    .ca-ficha-imprimindo .ca-ficha-a4 {
        width: 100% !important;
        max-width: none !important;
        min-height: 0 !important;
        margin: 0 !important;
        padding: 5mm !important;
        border: 1px solid #244b8f !important;
        box-shadow: none !important;
        page-break-inside: auto;
    }

    .ca-ficha-imprimindo .ca-ficha-corpo {
        display: block !important;
        overflow: visible !important;
        border: 1px solid #d9dfe8 !important;
    }

    .ca-ficha-imprimindo .ca-ficha-campo {
        display: block !important;
        break-inside: auto !important;
        page-break-inside: auto !important;
    }

    /* Permite que o campo Observação utilize
        o espaço restante da primeira página */
    .ca-ficha-imprimindo
    .ca-ficha-campo:nth-child(5) {
        break-inside: auto !important;
        page-break-inside: auto !important;
    }

    .ca-ficha-imprimindo
    .ca-ficha-campo:nth-child(5)
    .ca-ficha-valor {
        display: block !important;
        break-inside: auto !important;
        page-break-inside: auto !important;
        overflow: visible !important;
    }

    /* Mantém Laudos e Empresa juntos */
    .ca-ficha-imprimindo .ca-ficha-bloco {
        break-inside: avoid !important;
        page-break-inside: avoid !important;
    }

    .ca-ficha-imprimindo .ca-ficha-a4 {
    font-size: 9px !important;
}

.ca-ficha-imprimindo .ca-ficha-cabecalho {
    padding-bottom: 8px !important;
    margin-bottom: 8px !important;
}

.ca-ficha-imprimindo .ca-ficha-cabecalho h2 {
    font-size: 16px !important;
    margin-bottom: 5px !important;
}

.ca-ficha-imprimindo .ca-ficha-orgao {
    font-size: 9px !important;
    line-height: 1.2 !important;
}

.ca-ficha-imprimindo .ca-ficha-subtitulo {
    margin-top: 5px !important;
    font-size: 10px !important;
}

.ca-ficha-imprimindo .ca-ficha-resumo {
    gap: 5px !important;
    margin-bottom: 5px !important;
}

.ca-ficha-imprimindo .ca-ficha-resumo .ca-ficha-campo {
    padding: 5px 6px !important;
}

.ca-ficha-imprimindo .ca-ficha-campo {
    padding: 5px 7px !important;
}

.ca-ficha-imprimindo .ca-ficha-label {
    margin-bottom: 2px !important;
    font-size: 8px !important;
}

.ca-ficha-imprimindo .ca-ficha-valor {
    font-size: 8px !important;
    line-height: 1.25 !important;
}

.ca-ficha-imprimindo .ca-ficha-campo:nth-child(5) .ca-ficha-valor {
    font-size: 7.5px !important;
    line-height: 1.25 !important;
}

.ca-ficha-imprimindo .ca-ficha-rodape-grid {
    gap: 5px !important;
    margin-top: 5px !important;
}

.ca-ficha-imprimindo .ca-ficha-bloco h3 {
    padding: 5px 7px !important;
    font-size: 9px !important;
}

.ca-ficha-imprimindo .ca-ficha-aviso {
    margin-top: 5px !important;
    padding: 5px 7px !important;
    font-size: 7px !important;
}
    
    @page {
        size: A4 portrait;
        margin: 3mm;
    }
}

/* ==========================================
   FICHA DO CA - OVERLAY
=========================================== */

body.ca-ficha-aberta {
    overflow: hidden !important;
}

.ca-ficha-overlay {
    position: fixed;
    inset: 0;
    z-index: 999999;
    background: rgba(0, 0, 0, .62);
    padding: 25px;
    overflow-y: auto;
    align-items: flex-start;
    justify-content: center;
    box-sizing: border-box;
}

.ca-ficha-modal {
    width: 100%;
    max-width: 1000px;
    margin: auto;
    background: #f4f4f4;
    border-radius: 12px;
    box-shadow: 0 15px 50px rgba(0,0,0,.30);
    overflow: hidden;
}


/* ==========================================
   TOPO DA FICHA
=========================================== */

.ca-ficha-topo {
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: 18px 24px;
    background: #ffffff;
    border-bottom: 1px solid #dddddd;
}

.ca-ficha-topo-titulo {
    font-size: 24px;
    line-height: 1.2;
    font-weight: 800;
    color: #222222;
}

.ca-ficha-fechar {
    width: 40px !important;
    height: 40px !important;
    padding: 0 !important;
    border: 0 !important;
    background: transparent !important;
    color: #555555 !important;
    font-size: 30px !important;
    line-height: 40px !important;
    cursor: pointer;
    box-shadow: none !important;
}


/* ==========================================
   AÇÕES
=========================================== */

.ca-ficha-acoes {
    display: flex;
    justify-content: flex-end;
    gap: 10px;
    padding: 12px 24px;
    background: #ffffff;
    border-bottom: 1px solid #dddddd;
}

.ca-ficha-imprimir,
.ca-ficha-pdf {
    width: auto !important;
    min-width: 150px;
    padding: 11px 18px !important;
    border-radius: 6px !important;
    font-size: 12px !important;
    font-weight: 800 !important;
    cursor: pointer;
    box-shadow: none !important;
}

.ca-ficha-imprimir {
    border: 1px solid #cccccc !important;
    background: #ffffff !important;
    color: #333333 !important;
}

.ca-ficha-imprimir:hover {
    background: #eeeeee !important;
}

.ca-ficha-pdf {
    border: 1px solid #174ea6 !important;
    background: #174ea6 !important;
    color: #ffffff !important;
}

.ca-ficha-pdf:hover {
    opacity: .90;
}


/* ==========================================
   FOLHA A4
=========================================== */

.ca-ficha-a4 {
    width: calc(100% - 40px);
    max-width: 794px;
    min-height: 1123px;
    margin: 20px auto 35px;
    padding: 28px;
    box-sizing: border-box;
    background: #ffffff;
    border: 2px solid #244b8f;
    color: #111111;
    font-family: Arial, Helvetica, sans-serif;
    box-shadow: 0 5px 18px rgba(0,0,0,.12);
}


/* ==========================================
   CABEÇALHO DO CERTIFICADO
=========================================== */

.ca-ficha-cabecalho {
    padding-bottom: 16px;
    margin-bottom: 15px;
    border-bottom: 1px solid #b9c6dc;
}

.ca-ficha-cabecalho h2 {
    margin: 0 0 10px;
    font-size: 23px;
    line-height: 1.25;
    font-weight: 800;
    color: #111111;
}

.ca-ficha-cabecalho .ca-status {
    margin-bottom: 12px;
}

.ca-ficha-orgao {
    margin: 2px 0;
    font-size: 14px;
    line-height: 1.35;
    font-weight: 700;
    color: #173c7a;
}

.ca-ficha-subtitulo {
    margin-top: 10px;
    font-size: 15px;
    font-weight: 800;
    color: #222222;
}


/* ==========================================
   RESUMO
=========================================== */

.ca-ficha-resumo {
    display: grid;
    grid-template-columns: repeat(3, minmax(0, 1fr));
    gap: 10px;
    margin-bottom: 12px;
}

.ca-ficha-resumo .ca-ficha-campo {
    border: 1px solid #d9dfe8;
    border-radius: 6px;
    padding: 11px 12px;
}


/* ==========================================
   CAMPOS DA FICHA
=========================================== */

.ca-ficha-corpo {
    border: 1px solid #d9dfe8;
    border-radius: 6px;
    overflow: hidden;
}

.ca-ficha-campo {
    padding: 11px 13px;
    border-bottom: 1px solid #dde2ea;
}

.ca-ficha-corpo .ca-ficha-campo:last-child {
    border-bottom: 0;
}

.ca-ficha-label {
    margin-bottom: 4px;
    font-size: 12px;
    line-height: 1.3;
    font-weight: 800;
    color: #173c7a;
}

.ca-ficha-valor {
    font-size: 12px;
    line-height: 1.58;
    white-space: pre-line;
    overflow-wrap: anywhere;
    word-break: normal;
    color: #111111;
}

.ca-ficha-campo:nth-child(5) .ca-ficha-valor {
    font-size: 11.5px;
    line-height: 1.65;
    text-align: justify;
}

/* ==========================================
   LAUDOS / EMPRESA
=========================================== */

.ca-ficha-rodape-grid {
    display: grid;
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 10px;
    margin-top: 12px;
}

.ca-ficha-bloco {
    border: 1px solid #d9dfe8;
    border-radius: 6px;
    overflow: hidden;
}

.ca-ficha-bloco h3 {
    margin: 0;
    padding: 10px 13px;
    border-bottom: 1px solid #d9dfe8;
    background: #f6f8fb;
    font-size: 13px;
    font-weight: 800;
    color: #173c7a;
}

.ca-ficha-bloco .ca-ficha-campo:last-child {
    border-bottom: 0;
}


/* ==========================================
   AVISO
=========================================== */

.ca-ficha-aviso {
    margin-top: 12px;
    padding: 10px 12px;
    border: 1px solid #c9d6eb;
    border-radius: 6px;
    background: #f7faff;
    font-size: 10px;
    line-height: 1.45;
    color: #294267;
}


/* ==========================================
   FICHA - CELULAR
=========================================== */

@media (max-width: 700px) {

    .ca-ficha-overlay {
        padding: 8px;
    }

    .ca-ficha-modal {
        border-radius: 8px;
    }

    .ca-ficha-topo {
        padding: 14px;
    }

    .ca-ficha-topo-titulo {
        font-size: 19px;
    }

    .ca-ficha-acoes {
        padding: 10px 14px;
        flex-direction: column;
    }

    .ca-ficha-imprimir,
    .ca-ficha-pdf {
        width: 100% !important;
    }

    .ca-ficha-a4 {
        width: calc(100% - 16px);
        min-height: 0;
        margin: 8px auto 20px;
        padding: 16px;
    }

    .ca-ficha-cabecalho h2 {
        font-size: 18px;
    }

    .ca-ficha-resumo,
    .ca-ficha-rodape-grid {
        grid-template-columns: 1fr;
    }

    .ca-ficha-orgao {
        font-size: 11px;
    }

    .ca-ficha-label {
        font-size: 11px;
    }

    .ca-ficha-valor {
        font-size: 11px;
    }
}

/* =========================================
   PÁGINA INDIVIDUAL DO CA
   Exemplo: /ca/47720/
========================================= */

.luvaepi-ca-pagina-individual {
    width: 100%;
    padding: 32px 20px 48px;
    box-sizing: border-box;
}

.luvaepi-ca-pagina-individual-conteudo {
    width: 100%;
    max-width: 900px;
    margin: 0 auto;
}

.luvaepi-ca-pagina-individual-conteudo > h1 {
    width: 100%;
    margin: 0 0 18px;
    font-size: 30px !important;
    line-height: 1.2;
    text-align: left;
}

.luvaepi-ca-pagina-individual .luvaepi-ca-consulta {
    width: 100%;
    max-width: 900px;
    margin: 0 auto;
}

.luvaepi-ca-pagina-individual .luvaepi-ca-botao {
    width: 100% !important;
    min-height: 54px !important;
    margin-top: 6px !important;
    padding: 0 14px !important;

    display: flex !important;
    align-items: center !important;
    justify-content: center !important;

    background: #e60012 !important;
    color: #fff !important;
    border: none !important;
    border-radius: 8px !important;

    font-size: 15px !important;
    font-weight: 700 !important;
    text-align: center !important;
    cursor: pointer;
}

.luvaepi-ca-pagina-individual .luvaepi-ca-resultado {
    margin-top: 22px !important;
}