* {

    box-sizing: border-box;

}


body {

    margin: 0;

    font-family:
        Arial,
        Helvetica,
        sans-serif;

    background: #f4f6f8;

    color: #171717;

}


/* ============================================================
   LOGIN
============================================================ */

.login-container {

    min-height: 100vh;

    display: flex;

    justify-content: center;

    align-items: center;

}


.login-box {

    width: 400px;

    background: white;

    padding: 40px;

    border-radius: 14px;

    box-shadow:
        0 8px 30px
        rgba(0, 0, 0, .08);

}


.logo-login {

    display: block;

    width: 220px;

    max-width: 85%;

    height: auto;

    margin:
        0 auto 25px;

}


.login-box h1 {

    margin:
        0 0 8px;

    font-size: 25px;

}


.login-box p {

    color: #777;

    margin-bottom: 30px;

}


.login-box label {

    display: block;

    margin-top: 15px;

    margin-bottom: 7px;

    font-weight: 600;

    font-size: 14px;

}


.login-box input {

    width: 100%;

    padding: 13px;

    border:
        1px solid #ddd;

    border-radius: 7px;

    font-size: 15px;

    outline: none;

}


.login-box input:focus {

    border-color: #c00000;

}


.login-box button {

    width: 100%;

    margin-top: 25px;

    padding: 14px;

    border: 0;

    border-radius: 7px;

    background: #171717;

    color: white;

    font-size: 15px;

    font-weight: 600;

    cursor: pointer;

}


.login-box button:hover {

    opacity: .9;

}


.erro {

    margin-top: 20px;

    padding: 12px;

    background: #ffe5e5;

    color: #b00000;

    border-radius: 7px;

    font-size: 14px;

}


/* ============================================================
   CABEÇALHO
============================================================ */

.topbar {

    height: 82px;

    background: white;

    padding:
        8px 70px;

    display: flex;

    justify-content: space-between;

    align-items: center;

    box-shadow:
        0 2px 10px
        rgba(0, 0, 0, .06);

}


.brand {

    display: flex;

    align-items: center;

    gap: 20px;

}


.logo-portal {
    width: 78px;
    height: 62px;
    object-fit: contain;
    display: block;
}


.brand strong {

    font-size: 21px;

}


.cliente-topo {
    display: flex;
    align-items: center;
    gap: 18px;
}

.cliente-dados {
    display: flex;
    flex-direction: column;
    align-items: flex-end;
    gap: 5px;
    min-width: 0;
}

.cliente-nome-topo {
    font-size: 14px;
    font-weight: 700;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
    max-width: 520px;
}

.cliente-contatos-topo {
    display: flex;
    align-items: center;
    justify-content: flex-end;
    gap: 14px;
    flex-wrap: wrap;
}

.cliente-contato-topo {
    display: inline-flex;
    align-items: center;
    gap: 5px;
    color: #777;
    font-size: 11px;
    font-weight: 400;
    white-space: nowrap;
}

.cliente-contato-topo svg {
    width: 14px;
    height: 14px;
    fill: none;
    stroke: currentColor;
    stroke-width: 1.8;
    stroke-linecap: round;
    stroke-linejoin: round;
}


.btn-sair {

    margin-left: 22px;

    color: #c00000;

    text-decoration: none;

    font-weight: 600;

    font-size: 14px;

    display: flex;

    align-items: center;

    gap: 6px;

}


.btn-sair:hover {

    text-decoration: underline;

}


.icone-sair {

    width: 18px;

    height: 18px;

    fill: none;

    stroke: currentColor;

    stroke-width: 2;

    stroke-linecap: round;

    stroke-linejoin: round;

}


/* ============================================================
   CONTADOR DE SESSÃO
============================================================ */

.contador-sessao {

    display: flex;

    align-items: center;

    gap: 6px;

    margin-left: 18px;

    padding:
        7px 10px;

    border:
        1px solid #ddd;

    border-radius: 6px;

    background: #fafafa;

    color: #666;

    font-size: 12px;

    font-weight: 600;

}


.contador-sessao svg {

    width: 16px;

    height: 16px;

    fill: none;

    stroke: currentColor;

    stroke-width: 2;

    stroke-linecap: round;

    stroke-linejoin: round;

}


.contador-sessao.sessao-alerta {

    color: #b00000;

    background: #fff0f0;

    border-color: #f0bcbc;

}


/* ============================================================
   CONTAINER
============================================================ */

.container {

    max-width: 1320px;

    margin:
        34px auto;

    padding:
        0 25px;

}


/* ============================================================
   IDENTIFICAÇÃO DO CLIENTE
============================================================ */

.boas-vindas {

    margin-bottom: 28px;

}


.portal-label {

    display: block;

    color: #c00000;

    font-size: 12px;

    font-weight: 700;

    letter-spacing: 1.2px;

    margin-bottom: 7px;

}


.boas-vindas h1 {

    margin: 0;

    font-size: 31px;

    line-height: 1.15;

    font-weight: 700;

}


.boas-vindas p {

    margin:
        8px 0 0;

    color: #666;

    font-size: 15px;

}


/* ============================================================
   CARDS
============================================================ */

.cards {

    display: grid;

    grid-template-columns:
        repeat(4, 1fr);

    gap: 20px;

    margin-bottom: 28px;

}


.card {

    background: white;

    padding:
        20px 23px;

    border-radius: 11px;

    box-shadow:
        0 3px 12px
        rgba(0, 0, 0, .06);

    min-height: 105px;

    display: flex;

    align-items: center;

    gap: 15px;

}


.card-icone {

    width: 52px;

    height: 52px;

    min-width: 52px;

    border-radius: 10px;

    display: flex;

    align-items: center;

    justify-content: center;

}


.card-icone svg {

    width: 28px;

    height: 28px;

    fill: none;

    stroke: currentColor;

    stroke-width: 2;

    stroke-linecap: round;

    stroke-linejoin: round;

}


.card-conteudo {

    min-width: 0;

}


.card span {

    display: block;

    color: #666;

    font-size: 13px;

    margin-bottom: 8px;

}


.card strong {

    font-size: 22px;

    font-weight: 700;

    white-space: nowrap;

}


/* ============================================================
   CORES DOS CARDS
============================================================ */

.card-total .card-icone {

    background: #ffe4e4;

    color: #d00000;

}


.card-titulos .card-icone {

    background: #eeeeee;

    color: #333;

}


.card-vencido .card-icone {

    background: #ffe1e1;

    color: #d00000;

}


.card-vencido strong {

    color: #d00000;

}


.card-futuro .card-icone {

    background: #dcf5e5;

    color: #159447;

}


.card-futuro strong {

    color: #159447;

}


/* ============================================================
   EXTRATO
============================================================ */

.box {

    background: white;

    border-radius: 12px;

    padding:
        25px;

    box-shadow:
        0 3px 12px
        rgba(0, 0, 0, .05);

}


.extrato-header {

    display: flex;

    justify-content: space-between;

    align-items: center;

    margin-bottom: 18px;

}


.extrato-header h2 {

    margin:
        0 0 5px;

    font-size: 21px;

}


.contador {

    color: #888;

    font-size: 12px;

}


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

.tabela-container {

    overflow-x: auto;

}


table {

    width: 100%;

    border-collapse: collapse;

    border: 1px solid #d9d9d9;

}


/* ============================================================
   CABEÇALHO DA TABELA
============================================================ */

thead th {

    background: #f1f2f3;

    color: #222;

    font-size: 12px;

    font-weight: 700;

    text-align: left;

    padding:
        13px 12px;

    white-space: nowrap;

    border:
        1px solid #d9d9d9;

}


/* ============================================================
   LINHAS DA TABELA
============================================================ */

tbody td {

    padding:
        13px 12px;

    font-size: 13px;

    white-space: nowrap;

    border:
        1px solid #e0e0e0;

    background: white;

}


/* ============================================================
   EFEITO AO PASSAR O MOUSE
============================================================ */

tbody tr:hover td {

    background: #fafafa;

}


/* ============================================================
   DATAS COLORIDAS
============================================================ */

.data-vencido {

    color: #d00000;

    font-weight: 700;

}


.data-futuro {

    color: #159447;

    font-weight: 700;

}


.data-hoje {

    color: #b07a00;

    font-weight: 700;

}


/* ============================================================
   STATUS
============================================================ */

.status {

    display: inline-block;

    padding:
        5px 10px;

    border-radius: 20px;

    font-size: 10px;

    font-weight: 700;

    white-space: nowrap;

}


.status-vencido {

    background: #ffe1e1;

    color: #d00000;

}


.status-futuro {

    background: #dcf5e5;

    color: #159447;

}


.status-hoje {

    background: #fff0c7;

    color: #b07a00;

}


/* ============================================================
   AÇÕES DOS TÍTULOS
============================================================ */

.acoes-titulo {

    display: flex;

    flex-direction: column;

    gap: 6px;

    min-width: 125px;

}


/* ============================================================
   BOTÃO 2ª VIA
============================================================ */

.btn-segunda-via {

    border: 0;

    background: #171717;

    color: white;

    padding:
        7px 12px;

    border-radius: 5px;

    cursor: pointer;

    font-size: 11px;

    font-weight: 600;

    transition: .2s;

}


.btn-segunda-via:hover {

    background: #333;

}


/* ============================================================
   BOTÃO LINHA DIGITÁVEL
============================================================ */

.btn-linha {

    border:
        1px solid #d8d8d8;

    background: #f5f5f5;

    color: #333;

    padding:
        7px 12px;

    border-radius: 5px;

    cursor: pointer;

    font-size: 11px;

    font-weight: 600;

    transition: .2s;

}


.btn-linha:hover {

    background: #e9e9e9;

}


.icone-acao {

    margin-right: 3px;

}


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

.paginacao {

    display: flex;

    justify-content: center;

    align-items: center;

    gap: 6px;

    padding:
        20px 0 0;

}


.pagina {

    min-width: 34px;

    height: 34px;

    padding:
        0 9px;

    display: flex;

    align-items: center;

    justify-content: center;

    border:
        1px solid #d9d9d9;

    border-radius: 6px;

    background: white;

    color: #222;

    text-decoration: none;

    font-size: 13px;

    cursor: pointer;

}


.pagina:hover {

    background: #f4f4f4;

}


.pagina.ativa {

    background: #d00000;

    border-color: #d00000;

    color: white;

    font-weight: 700;

}


.pagina.seta {

    font-size: 21px;

    line-height: 1;

}


.pagina.desabilitado {

    color: #bbb;

    background: #fafafa;

    cursor: default;

}


.pagina.pontos {

    border: 0;

    cursor: default;

    background: transparent;

}


/* ============================================================
   SEM REGISTROS
============================================================ */

.sem-registros {

    text-align: center;

    padding:
        45px 20px !important;

    color: #777;

}


/* ============================================================
   MODAL — LINHA DIGITÁVEL
============================================================ */

.modal-overlay {

    position: fixed;

    inset: 0;

    width: 100%;

    height: 100%;

    background:
        rgba(0, 0, 0, .55);

    display: none;

    align-items: center;

    justify-content: center;

    padding: 20px;

    z-index: 9999;

}


.modal-overlay.modal-aberto {

    display: flex;

}


.modal-box {

    position: relative;

    width: 100%;

    max-width: 620px;

    background: white;

    border-radius: 12px;

    padding: 28px;

    box-shadow:
        0 15px 50px
        rgba(0, 0, 0, .25);

}


.modal-fechar {

    position: absolute;

    top: 12px;

    right: 16px;

    border: 0;

    background: transparent;

    color: #777;

    font-size: 28px;

    line-height: 1;

    cursor: pointer;

}


.modal-fechar:hover {

    color: #222;

}


.modal-icone {

    width: 45px;

    height: 45px;

    display: flex;

    align-items: center;

    justify-content: center;

    background: #eeeeee;

    border-radius: 9px;

    font-size: 22px;

    margin-bottom: 12px;

}


.modal-box h2 {

    margin:
        0 0 22px;

    font-size: 21px;

    color: #222;

}


/* ============================================================
   INFORMAÇÕES DO TÍTULO
============================================================ */

.modal-info {

    display: grid;

    grid-template-columns:
        repeat(3, 1fr);

    gap: 10px;

    margin-bottom: 22px;

}


.modal-info div {

    padding: 12px;

    background: #f7f7f7;

    border:
        1px solid #e1e1e1;

    border-radius: 6px;

}


.modal-info span {

    display: block;

    color: #777;

    font-size: 10px;

    text-transform: uppercase;

    margin-bottom: 5px;

}


.modal-info strong {

    display: block;

    color: #222;

    font-size: 13px;

}


/* ============================================================
   CAMPO DA LINHA DIGITÁVEL
============================================================ */

.modal-box > label {

    display: block;

    margin-bottom: 7px;

    font-size: 12px;

    font-weight: 700;

    color: #444;

}


.linha-campo {

    display: flex;

    align-items: stretch;

    gap: 8px;

}


.linha-campo input {

    flex: 1;

    min-width: 0;

    height: 42px;

    padding:
        0 12px;

    border:
        1px solid #d5d5d5;

    border-radius: 6px;

    background: #f7f7f7;

    color: #333;

    font-size: 12px;

    outline: none;

}


.linha-campo input:focus {

    border-color: #c00000;

}


.btn-copiar {

    height: 42px;

    padding:
        0 16px;

    border: 0;

    border-radius: 6px;

    background: #171717;

    color: white;

    font-size: 12px;

    font-weight: 600;

    cursor: pointer;

    white-space: nowrap;

    transition: .2s;

}


.btn-copiar:hover {

    background: #333;

}


/* ============================================================
   MENSAGEM COPIADO
============================================================ */

.mensagem-copiado {

    display: none;

    margin-top: 12px;

    padding: 10px;

    border:
        1px solid #bde5c5;

    border-radius: 6px;

    background: #edf9ef;

    color: #237a35;

    text-align: center;

    font-size: 12px;

    font-weight: 600;

}


/* ============================================================
   RESPONSIVO
============================================================ */

@media (max-width: 1100px) {

    .topbar {

        padding:
            8px 30px;

    }


    .cards {

        grid-template-columns:
            repeat(2, 1fr);

    }

}


@media (max-width: 700px) {

    .topbar {

        height: auto;

        padding:
            10px 15px;

    }


    .brand {

        gap: 10px;

    }


    .logo-portal {
        width: 65px;
        height: 52px;
    }


    .brand strong {

        font-size: 16px;

    }


    .cliente-topo {
        gap: 10px;
    }

    .cliente-dados {
        align-items: flex-end;
        max-width: 300px;
    }

    .cliente-nome-topo {
        max-width: 300px;
        font-size: 12px;
    }

    .cliente-contatos-topo {
        gap: 7px;
    }

    .cliente-contato-topo {
        font-size: 10px;
    }


    .btn-sair {

        margin-left: 10px;

    }


    .contador-sessao {

        margin-left: 8px;

    }


    .container {

        margin:
            25px auto;

        padding:
            0 15px;

    }


    .boas-vindas h1 {

        font-size: 24px;

    }


    .cards {

        grid-template-columns: 1fr;

        gap: 12px;

    }


    .card {

        min-height: auto;

        padding:
            18px 20px;

    }


    .box {

        padding:
            18px 12px;

    }


    .extrato-header {

        padding:
            0 5px;

    }


    .extrato-header h2 {

        font-size: 18px;

    }


    thead th,
    tbody td {

        font-size: 12px;

        padding:
            10px 8px;

    }


    /* MODAL NO CELULAR */

    .modal-box {

        padding: 22px 18px;

    }


    .modal-info {

        grid-template-columns: 1fr;

    }


    .linha-campo {

        flex-direction: column;

    }


    .linha-campo input {

        width: 100%;

    }


    .btn-copiar {

        width: 100%;

    }


    .acoes-titulo {

        min-width: 115px;

    }


    .btn-segunda-via,
    .btn-linha {

        width: 100%;

    }

}


/* ============================================================
   MENU LATERAL - NOTAS FISCAIS
============================================================ */

.btn-menu {
    border: 0;
    background: transparent;
    font-size: 24px;
    cursor: pointer;
    color: #222;
    padding: 5px 8px;
    line-height: 1;
}

.menu-lateral {
    position: fixed;
    top: 0;
    left: -280px;
    width: 280px;
    height: 100vh;
    background: #171717;
    z-index: 10000;
    transition: left .25s ease;
    display: flex;
    flex-direction: column;
    box-shadow: 4px 0 20px rgba(0, 0, 0, .18);
}

.menu-lateral.menu-aberto {
    left: 0;
}

.menu-logo {
    height: 82px;
    display: flex;
    align-items: center;
    padding: 12px 25px;
    background: white;
    border-bottom: 1px solid #ddd;
}

.menu-logo img {
    width: 115px;
    height: auto;
}

.menu-lateral nav {
    padding-top: 12px;
}

.menu-item {
    display: flex;
    align-items: center;
    gap: 13px;
    width: 100%;
    padding: 14px 25px;
    color: #ddd;
    text-decoration: none;
    font-size: 14px;
    font-weight: 600;
    transition: .2s;
}

.menu-item span {
    width: 23px;
    text-align: center;
    font-size: 17px;
}

.menu-item:hover {
    background: #292929;
    color: white;
}

.menu-item.ativo {
    background: #c00000;
    color: white;
}

.menu-footer {
    margin-top: auto;
    padding: 10px 0;
    border-top: 1px solid #333;
}

.menu-overlay {
    position: fixed;
    inset: 0;
    background: rgba(0, 0, 0, .45);
    z-index: 9999;
    display: none;
}

.menu-overlay.menu-overlay-aberto {
    display: block;
}


/* ============================================================
   FILTROS - NOTAS FISCAIS
============================================================ */

.filtros-notas {
    background: white;
    border-radius: 12px;
    padding: 20px 22px;
    margin-bottom: 20px;
    box-shadow: 0 3px 12px rgba(0, 0, 0, .05);
    border: 1px solid #eeeeee;
}

.filtros-notas form {
    display: flex;
    align-items: flex-end;
    gap: 15px;
    flex-wrap: wrap;
}

.filtro {
    display: flex;
    flex-direction: column;
    gap: 6px;
}

.filtro label {
    font-size: 11px;
    font-weight: 700;
    color: #666;
}

.filtro input,
.filtro select {
    height: 40px;
    min-width: 180px;
    padding: 0 11px;
    border: 1px solid #d8d8d8;
    border-radius: 6px;
    background: white;
    color: #333;
    outline: none;
    font-family: Arial, Helvetica, sans-serif;
    font-size: 12px;
}

.filtro input:focus,
.filtro select:focus {
    border-color: #c00000;
    box-shadow: 0 0 0 2px rgba(192, 0, 0, .08);
}

.btn-filtrar {
    height: 40px;
    padding: 0 20px;
    border: 0;
    border-radius: 6px;
    background: #171717;
    color: white;
    font-size: 12px;
    font-weight: 600;
    cursor: pointer;
    transition: .2s;
}

.btn-filtrar:hover {
    background: #333;
}


/* ============================================================
   LISTA DE NOTAS
============================================================ */

.lista-notas {
    display: flex;
    flex-direction: column;
    gap: 10px;
}

.nota-card {
    background: white;
    border: 1px solid #dcdcdc;
    border-radius: 8px;
    overflow: hidden;
}

.nota-header {
    width: 100%;
    border: 0;
    background: white;
    padding: 14px 15px;
    display: grid;
    grid-template-columns: 1fr auto 25px;
    align-items: center;
    gap: 20px;
    text-align: left;
    cursor: pointer;
    font-family: Arial, Helvetica, sans-serif;
}

.nota-header:hover {
    background: #fafafa;
}

.nota-documento {
    display: flex;
    align-items: center;
    gap: 12px;
}

.icone-nota {
    width: 40px;
    height: 40px;
    min-width: 40px;
    display: flex;
    align-items: center;
    justify-content: center;
    border-radius: 7px;
    background: #f1f1f1;
    font-size: 18px;
}

.nota-documento strong {
    display: block;
    color: #222;
    font-size: 13px;
    margin-bottom: 4px;
}

.nota-documento span:not(.icone-nota) {
    display: block;
    color: #777;
    font-size: 11px;
}

.nota-resumo {
    display: flex;
    align-items: center;
    gap: 18px;
}

.nota-resumo > strong {
    color: #222;
    font-size: 14px;
    white-space: nowrap;
}

.nota-seta {
    color: #777;
    font-size: 11px;
    transition: transform .2s ease;
}

.nota-aberta .nota-seta {
    transform: rotate(90deg);
}


/* ============================================================
   STATUS DAS NOTAS
============================================================ */

.status-nota {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    padding: 5px 10px;
    border-radius: 20px;
    font-size: 9px;
    font-weight: 700;
    white-space: nowrap;
}

.status-autorizada {
    background: #dcf5e5;
    color: #159447;
}

.status-rejeitada {
    background: #ffe1e1;
    color: #d00000;
}

.status-denegada {
    background: #ffe1e1;
    color: #b00000;
}

.status-cancelada {
    background: #eeeeee;
    color: #555;
}

.status-processamento {
    background: #fff0c7;
    color: #a16c00;
}

.status-inutilizada {
    background: #eeeeee;
    color: #777;
}


/* ============================================================
   PRODUTOS DA NOTA
============================================================ */

.nota-produtos {
    display: none;
    border-top: 1px solid #ddd;
    background: #fafafa;
}

.nota-aberta .nota-produtos {
    display: block;
}

.produtos-titulo {
    padding: 13px 15px;
    color: #555;
    font-size: 11px;
    font-weight: 700;
    text-transform: uppercase;
}

.tabela-produtos-container {
    overflow-x: auto;
}

.tabela-produtos {
    width: 100%;
    min-width: 750px;
    border-collapse: collapse;
}

.tabela-produtos th {
    background: #f1f2f3;
    color: #555;
    font-size: 10px;
    font-weight: 700;
    text-align: left;
    text-transform: uppercase;
    padding: 10px 12px;
    border: 1px solid #ddd;
}

.tabela-produtos td {
    background: white;
    color: #333;
    font-size: 11px;
    padding: 10px 12px;
    border: 1px solid #e1e1e1;
}

.tabela-produtos tbody tr:hover td {
    background: #fafafa;
}


/* ============================================================
   NENHUMA NOTA
============================================================ */

.sem-notas {
    min-height: 180px;
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    gap: 8px;
    color: #777;
    text-align: center;
}

.sem-notas strong {
    color: #444;
    font-size: 14px;
}

.sem-notas span {
    font-size: 12px;
}


/* ============================================================
   RESPONSIVO - NOTAS
============================================================ */

@media (max-width: 700px) {

    .btn-menu {
        font-size: 22px;
        padding: 4px 6px;
    }

    .menu-lateral {
        width: 260px;
        left: -260px;
    }

    .filtros-notas {
        padding: 16px;
    }

    .filtros-notas form {
        flex-direction: column;
        align-items: stretch;
    }

    .filtro {
        width: 100%;
    }

    .filtro input,
    .filtro select {
        width: 100%;
        min-width: 0;
    }

    .btn-filtrar {
        width: 100%;
    }

    .nota-header {
        grid-template-columns: 1fr 25px;
        gap: 8px;
    }

    .nota-resumo {
        grid-column: 1 / -1;
        justify-content: space-between;
        padding-left: 52px;
    }

    .nota-seta {
        grid-column: 2;
        grid-row: 1;
    }

    .nota-documento strong {
        font-size: 12px;
    }

    .nota-resumo > strong {
        font-size: 13px;
    }

}
