@import url('https://fonts.googleapis.com/css2?family=Acme&family=Josefin+Sans:wght@400;700&display=swap');

/* Reset simples */
* {
    box-sizing: border-box;
    margin: 0;
    padding: 0;
}

body {
    
    height: auto;
    font-family: 'Josefin Sans', sans-serif;
    font-weight: lighter;
    font-size: 18px;
    margin: 0;
    padding: 0;
    color: #121113;
}

.titulo-operacao {
    width: 100%;
    min-height: 40px;
    background-color: #ffffff40;
    font-weight: bold;
    font-size: 18px;
    display: grid;
    justify-content: center;
    place-items: center;/* Centralização perfeita */
}

h1, h2, h3, h4, h5, h6 {
    font-family: 'Acme', sans-serif; /* Usando Acme para títulos */
    margin: 0;
    padding: 0;
    display: inline;
    font-weight: 500;
}

h1 {
    font-size: 34px;
}

h2 {
    font-size: 28px;
}

h3 {
    font-size: 22px;
}

h4 {
    font-size: 18px;
}

h5 {
    font-size: 16px;
}

h6 {
    font-size: 14px;
}

/* container geral */
.app {
    margin: 0 auto;
    min-height: 100vh;
    display: flex;
    flex-direction: column;
}

/* HEADER (divheader) */
.header {
    background-color: #ffffff;
    display: flex;
    align-items: stretch;
    justify-content: space-between;
    border-bottom: 1px solid #3B7D87;
    min-height: 130px;
    padding-bottom: 10px;
}

/* container das 3 colunas do header */
.header-blocos-container {
    display: flex;
    flex: 1;
}

/* colunas 03, 04, 05 */
.header-bloco {
    flex: 1;
    min-height: 120px;
    display: flex;
    align-items: center;
    justify-content: center;
}

.header-blocos-container > #divlogo {
    padding-top: 5px;
    flex: 0 0 300px; /* não cresce, não encolhe, base = 200px */
    width: 300px;
}

.dados-login {
    display: flex;
    flex: 1;
    flex-direction: column;
    line-height: 20px;
    min-height: 120px;
    padding: 5px;
}

#logout {
    flex: 0 100px;
    width: 100px;
    justify-content: center;
    place-items: center;/* Centralização perfeita */
}

.barra-menu-mobile {
    display: none;
    align-items: stretch;
    justify-content: space-between;
}

/* Botão de menu – escondido no desktop */
.menu-toggle {
    display: none;
    border: 0;
    color: #000000;
    font-size: 18px;
    cursor: pointer;
    height: 50px;
    width: 50px;
}

.menu-toggle-checkbox {
    position: absolute;
    opacity: 0;
    width: 0;
    height: 0;
}

#label-menu-toggle {
    width: 50px;
    height: 50px;
    display: grid;
    place-items: center;
    cursor: pointer;
    user-select: none;
}

/* menu (desktop e mobile) */
.container-menu {
    background: #71B5C7;      /* ciano, como no desenho */
    border-bottom: 1px solid #3B7D87;
    padding: 4px 8px 0px 0px;/*Top|Right|Bottom|Left*/
    min-height: 50px;
}

ul {
    margin: 0;
    padding: 0;
}

li {
    width: auto;
    min-width: 250px;
    height: 40px;
    position: relative;
    float: left;
    display: grid;
    font-weight: 500;
    place-items: center;/* Centralização perfeita */
    border-right: 1px solid #3B7D87;
}

ol{
    width: auto;
    display: none;
    color: #121113;
    position: absolute;
    top: 100%;        /* abre logo abaixo do li */
    left: 0;          /* alinhado à esquerda do li */
    margin-top: 0;    /* remove o empurrão fixo */
    background-color: #ebf9fc;
    z-index: 99999;
    /* opcional, mas recomendado para muitos itens */
    max-height: 320px;
    overflow-y: auto;
}


ol li{
    height: 40px;
    width: 100%;
    text-align: left;
    justify-items: start; /* caso use grid */
    padding-left: 10px;
}

li:hover ol{
    display:block;
}

ol li:hover{
    color: #055164;
    font-weight: bold;
    background-color: #d0eaf0;
}

ul > li:hover {
    color: #055164;
    font-weight: bold;
    transition: transform 0.3s ease, color 0.3s ease;
    cursor: pointer;
    background-color: #ebf9fc;
}

.menu > li {
    position: relative;
}

/* botão fechar – só aparece no mobile */
.menu-close {
    display: none;
    border: 0;
    background: #ffffff30;
    float: right;
    cursor: pointer;
    height: 50px;
    width: 50px;
    border-radius: 5px;
}

/* itens do menu – desktop: em linha */
.menu-mobile-itens {
    display: none;
    gap: 8px;
    align-items: center;
}

.menu-item {
    text-decoration: none;
    color: #000;
    padding: 0;
}

/* Conteúdo (conteudo) ocupa o espaço flexível */
.conteudo {
    flex: 1;
    padding: 10px;
    text-align: center;
}

/* Rodapé (div08) */
.rodape {
    background: #e7f5f8;
    border-top: 1px solid #3B7D87;
    text-align: center;
    font-size: 16px;
    min-height: 80px;
    position: relative;
    display: grid;
    place-items: center;/* Centralização perfeita */
}

#back {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    min-height: 100vh;
    background-image: url("../imagens/cliente-vendedor-negociacao.jpg");
    background-size: cover;
    background-repeat: no-repeat;
    background-position: center;
    z-index: -1; /* Mantém a imagem no fundo */
}

/* ========= RESPONSIVO ========= */

/* Até 768px – modo “celular” */
@media (max-width: 768px) {
    h1 {
        font-size: 32px;
    }

    h2 {
        font-size: 26px;
    }

    h3 {
        font-size: 20px;
    }

    h4 {
        font-size: 16px;
    }

    h5 {
        font-size: 14px;
    }

    h6 {
        font-size: 12px;
    }

    /* Header vira a barra azul com botão ☰ */
    .header {
        height: auto;
        min-height: 80px;
        background: #71B5C7;
        color: #fff;
        align-items: center;
        padding: 4px 8px 0px 0px;/*Top|Right|Bottom|Left*/
    }

    /* esconde colunas 03/04/05 */
    .header-blocos-container {
        display: none;
    }

    .barra-menu-mobile {
        flex: 1;
        display: flex;
        align-items: center;
        justify-content: space-between;
        padding: 0;
    }

    /* 1ª div: logo – largura só o necessário, não estica */
    .barra-menu-mobile .menu-item:first-child {
        flex: 0 0 auto;       /* não cresce, não encolhe */
        display: flex;
        background-color: #ffffff20;
        align-items: center;      /* centraliza verticalmente */
        border-radius: 15px;
    }

    /* Título = ocupa todo o resto */
    .barra-menu-mobile .menu-item:last-child {
        flex: 1;          /* 🔹 OCUPA 100% DO ESPAÇO SOBRANDO */
        width: auto;      /* não precisa width fixo */
        display: flex;
        justify-content: center;  /* centraliza o texto horizontalmente */
        align-items: center;      /* centraliza verticalmente */
    }

    /* mostra botão ☰ */
    .menu-toggle {
        display: inline-block;
        background: #ffffff30;
        border-radius: 5px;
        margin-left: auto;   /* empurra para a direita no flex */
        /* ✅ centraliza o conteúdo */
        display: grid;
        place-items: center;
    }

    /* menu fechado por padrão */
    .container-menu {
        display: none;
        height: auto;
        padding: 4px 0px 0px 0px;/*Top|Right|Bottom|Left*/
    }

    /* quando body.menu-open, mostramos o menu (menu) 
    e garantimos que ele cresça conforme o conteúdo */
    body.menu-open #menu {
        display: flex;
        flex-wrap: wrap;
        height: auto;        /* força sobrescrita de qualquer height anterior */
        min-height: 80px;    /* opcional: um mínimo pra não ficar pequeno demais */
    }

    /* Ícone padrão (menu fechado) */
    #label-menu-toggle::before{
        content: "☰";
        font-size: 26px;
        line-height: 1;
        margin-top: 5px;
    }

    /* Quando o menu estiver aberto (body.menu-open), troca para X */
    body.menu-open #label-menu-toggle::before{
        content: "✕";
        font-size: 26px;
        margin-top: 5px;
    }

    /* menu item fechado por padrão */
    .menu-item {
        min-height: 100px;
        height: auto;
    }

    /* <ul class="menu"> normal */
    .menu {
        list-style: none;
        margin: 10px 0px 0px 0px;/*Top|Right|Bottom|Left*/
        padding: 0;
    }

    .menu .dropdown > li {
        width: 100%;
        height: 40px;
        border: 0;
        text-align: left;
        justify-items: start;
    }

    /* Quando passar o mouse no li que contém o dropdown, mostra o submenu */
    .menu li:hover > .dropdown {
        display: block;
    }

    /* 🔹 cada item em BLOCO, sem float e sem altura fixa */
    .menu li {
        float: left;                 /* 🔹 remove totalmente o float */
        display: block;               /* 🔹 permite centralizar vertical e horizontal */
        width: 100%;
        min-height: 40px;
        height: auto;
        line-height: 40px;           /* 🔹 centraliza verticalmente o texto */
        border-right: 0;
        border-bottom: 1px solid #3B7D87;
        background-color: #ffffff;
    }


    /* botão fechar visível no mobile */
    .menu-close {
        margin-left: auto;   /* empurra o botão totalmente para a direita */
        margin-top: 25px;
        margin-right: 8px;
        display: flex;
        justify-content: center;
        align-items: center;
        height: 50px;
        flex: 0 0 auto;      /* não estica */
    }

    /* itens empilhados (como na terceira imagem) */
    .menu-mobile-itens {
        width: 100%;
        margin-top: 0px;
        display: flex;
        align-items: center;
        flex-direction: column;
    }

    /* este é o pai das duas "divs abaixo" */
    #divdatelogin{
        width: 100%;
        display: flex;
        align-items: center;
    }

    /* a div que deve ocupar o espaço restante */
    #divdatelogin > .dados-login:not(#logout){
        flex: 1 1 auto;          /* ocupa o restante */
        min-width: 0;            /* importante p/ não estourar */
    }

    #menu-desktop {
        display: none;
    }

    li {
        width: 100%;
        text-align: left;
        justify-items: start; /* caso use grid */
        border-right: 0;
        border-bottom: 1px solid #3B7D87;
        align-items: center;
        justify-content: center;
        padding: 0px 5px 0px 5px;/*Top|Right|Bottom|Left*/
    }

    ol {
        position: static;   /* 🔹 tira o absolute */
        margin: 0;      /* não empurra pra baixo artificialmente */
        width: 100%;
        display: none;      /* continua escondido até o hover */
        background-color: #ebf9fc;
        align-items: center;
        justify-content: center;
    }

    ol > li {
        width: 100%;
        height: 40px;
        border: 0;
        padding-left: 5px;
    }
}

/* ==============================
   Quadro flutuante - Envio Automático
============================== */

.fab-autoenvio {
    position: fixed;
    right: 16px;
    bottom: 16px;
    width: 280px;
    background: #ffffffcc;
    backdrop-filter: blur(6px);
    border: 1px solid #3B7D87;
    border-radius: 12px;
    box-shadow: 0 10px 25px rgba(0,0,0,.15);
    z-index: 999999;
    user-select: none;
    overflow: hidden;
}

.fab-autoenvio.minimized .fab-body {
    display: none;
}

.fab-header {
    display: flex;
    align-items: center;
    gap: 10px;
    padding: 10px 10px;
    background: #71B5C7;
    border-bottom: 1px solid #3B7D87;
    cursor: grab;
}

.fab-header:active {
    cursor: grabbing;
}

.fab-title {
    font-family: 'Acme', sans-serif;
    font-size: 16px;
    font-weight: 500;
    color: #121113;
    flex: 1;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
}

.fab-actions {
    display: flex;
    gap: 6px;
}

.fab-iconbtn {
    height: 28px;
    width: 28px;
    border: 0;
    border-radius: 8px;
    background: #ffffff55;
    cursor: pointer;
    display: grid;
    place-items: center;
    font-size: 16px;
}

.fab-iconbtn:hover {
    background: #ffffff85;
}

.fab-body {
    padding: 10px;
}

.fab-grid {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 8px;
}

.fab-btn {
    border: 1px solid #3B7D87;
    background: #ebf9fc;
    color: #121113;
    border-radius: 10px;
    padding: 8px 10px;
    cursor: pointer;
    font-weight: 600;
    font-size: 11px;
    text-align: center;
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 8px;
}

.fab-btn:hover {
    background: #d0eaf0;
}

.fab-btn .dot {
    width: 10px;
    height: 10px;
    border-radius: 99px;
    background: #999; /* neutro */
    flex: 0 0 10px;
    box-shadow: inset 0 0 0 1px rgba(0,0,0,.12);
}

.fab-btn.on {
    background: #d7f7de;
    border-color: #2f8a4a;
}

.fab-btn.on .dot {
    background: #2f8a4a;
}

.fab-btn.off {
    background: #ffe1e1;
    border-color: #a22b2b;
}

.fab-btn.off .dot {
    background: #a22b2b;
}

.fab-footer {
    margin-top: 10px;
    font-size: 12px;
    opacity: .85;
}

/* Mobile: menor e mais “compacto” */
@media (max-width: 768px) {
    .fab-autoenvio {
        width: 260px;
        right: 10px;
        bottom: 10px;
    }
}

/* melhora drag no mobile */
#fab-autoenvio-header {
    touch-action: none;            /* impede scroll/zoom enquanto arrasta no header */
    -webkit-user-select: none;
    user-select: none;
}

.fab-header {
    touch-action: none;
}

/* botão/bolha para reabrir quando estiver fechado */
.fab-autoenvio-reopen {
    position: fixed;
    right: 16px;
    bottom: 16px;
    z-index: 999999;
    width: 54px;
    height: 54px;
    border-radius: 999px;
    border: 1px solid #3B7D87;
    background: #71B5C7;
    box-shadow: 0 10px 25px rgba(0,0,0,.18);
    display: none;                 /* só aparece quando o quadro estiver oculto */
    cursor: pointer;
    user-select: none;
    -webkit-user-select: none;
}

.fab-autoenvio-reopen span {
    display: grid;
    place-items: center;
    height: 100%;
    font-family: 'Acme', sans-serif;
    font-size: 18px;
    color: #121113;
}

/* mobile */
@media (max-width: 768px) {
    .fab-autoenvio-reopen {
        right: 10px;
        bottom: 10px;
    }
}
