@import url('https://fonts.googleapis.com/css2?family=Lobster&family=Roboto:wght@300;400;500;700;900&display=swap');

:root {
    --sf-bg: #121212;
    --sf-panel: #1E1E1E;
    --sf-panel-2: #2A2A2A;
    --sf-line: #2f2f2f;
    --sf-text: #FFFFFF;
    --sf-muted: #9BA1A6;
    --sf-orange: #FF5A00;
    --sf-orange-soft: rgba(255, 90, 0, 0.14);
    --sf-green: #00E676;
    --sf-red: #ff4747;
    --sf-shadow: 0 18px 45px rgba(0, 0, 0, 0.45);
}

* {
    box-sizing: border-box;
    margin: 0;
    padding: 0;
}

html,
body {
    min-height: 100%;
}

body.menu-dark {
    font-family: "Roboto", system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif;
    background: var(--sf-bg);
    color: var(--sf-text);
    overflow: hidden;
}

button,
input,
textarea {
    font: inherit;
}

button {
    cursor: pointer;
}

.aplicativo {
    display: flex;
    height: 100vh;
    height: 100dvh;
    background: var(--sf-bg);
}

.menu-lateral {
    flex: 0 0 240px;
    background: var(--sf-panel);
    border-right: 1px solid var(--sf-line);
    display: flex;
    flex-direction: column;
    padding: 22px 14px;
    text-align: center;
    z-index: 10;
}

.logo {
    margin-bottom: 26px;
    display: grid;
    gap: 8px;
    justify-items: center;
}

.logo-marca {
    width: 48px;
    height: 48px;
    border-radius: 16px;
    background: var(--sf-orange);
    display: grid;
    place-items: center;
    font-size: 26px;
    box-shadow: 0 0 30px rgba(255, 90, 0, 0.28);
}

.logo h1 {
    font-family: "Lobster", cursive;
    font-size: 34px;
    line-height: 0.95;
    color: var(--sf-text);
}

.logo span {
    color: var(--sf-orange);
}

.lista-botoes {
    display: flex;
    flex-direction: column;
    gap: 14px;
    overflow-y: auto;
    padding-right: 4px;
}

.botao-categoria {
    background: transparent;
    border: 1px solid transparent;
    color: var(--sf-muted);
    padding: 13px 12px;
    border-radius: 14px;
    display: flex;
    align-items: center;
    gap: 12px;
    text-align: left;
    font-size: 16px;
    font-weight: 800;
    transition: 0.2s ease;
}

.botao-categoria .cat-emoji {
    width: 30px;
    height: 30px;
    border-radius: 10px;
    display: grid;
    place-items: center;
    background: #151515;
    border: 1px solid var(--sf-line);
}

.botao-categoria:hover {
    color: var(--sf-orange);
    border-color: rgba(255, 90, 0, 0.35);
}

.botao-categoria.ativo {
    background: var(--sf-orange);
    color: white;
    box-shadow: 0 10px 24px rgba(255, 90, 0, 0.22);
}

.botao-categoria.ativo .cat-emoji {
    background: rgba(255,255,255,0.18);
    border-color: rgba(255,255,255,0.22);
}

.sessao-mesa-desktop {
    margin-top: auto;
    padding-top: 18px;
    border-top: 1px solid var(--sf-line);
    display: grid;
    gap: 10px;
}

.botao-pedidos-sidebar,
.botao-link-sidebar {
    width: 100%;
    background: transparent;
    color: var(--sf-orange);
    border: 1px solid var(--sf-orange);
    padding: 12px;
    border-radius: 12px;
    font-weight: 900;
    text-decoration: none;
    display: block;
}

.botao-pedidos-sidebar:hover,
.botao-link-sidebar:hover {
    background: var(--sf-orange);
    color: white;
}

.tela-principal {
    flex: 1;
    height: 100%;
    overflow-y: auto;
    padding: 28px;
    padding-bottom: 122px;
}

.topo-mesa {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 14px;
    margin-bottom: 22px;
}

.botao-menu-mobile {
    display: none;
    background: var(--sf-panel);
    color: var(--sf-text);
    border: 1px solid var(--sf-line);
    padding: 10px 14px;
    border-radius: 12px;
    font-weight: 900;
}

.status-mesa {
    display: inline-flex;
    align-items: center;
    gap: 8px;
    color: var(--sf-orange);
    background: var(--sf-panel);
    border: 1px solid var(--sf-line);
    border-radius: 12px;
    padding: 10px 14px;
    font-weight: 900;
}

.status-mesa.erro {
    color: #ffb3b3;
    border-color: var(--sf-red);
    background: rgba(255, 71, 71, 0.12);
}

.pedir-atendimento {
    background: var(--sf-panel);
    color: var(--sf-green);
    border: 1px solid var(--sf-green);
    padding: 11px 16px;
    border-radius: 12px;
    font-weight: 900;
    transition: 0.2s ease;
}

.pedir-atendimento:hover {
    background: var(--sf-green);
    color: #121212;
}

.cabecalho {
    margin-bottom: 18px;
}

.cabecalho h2 {
    font-family: "Lobster", cursive;
    font-size: clamp(34px, 5vw, 54px);
    color: white;
    margin-bottom: 5px;
}

.cabecalho p {
    color: var(--sf-muted);
}

.busca-cardapio {
    width: min(480px, 100%);
    margin-top: 16px;
    background: var(--sf-panel);
    color: var(--sf-text);
    border: 1px solid var(--sf-line);
    border-radius: 12px;
    padding: 13px 15px;
    outline: none;
}

.busca-cardapio:focus {
    border-color: var(--sf-orange);
    box-shadow: 0 0 0 4px var(--sf-orange-soft);
}

.titulo-subcategoria {
    grid-column: 1 / -1;
    font-family: "Lobster", cursive;
    color: var(--sf-orange);
    font-size: 30px;
    padding-top: 12px;
    padding-bottom: 10px;
    border-bottom: 1px solid var(--sf-line);
}

.grade-produtos {
    display: grid;
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 20px;
}

.cartao-produto {
    background: var(--sf-panel);
    border: 1px solid var(--sf-line);
    border-radius: 14px;
    padding: 15px;
    display: flex;
    flex-direction: column;
    min-height: 100%;
    box-shadow: 0 6px 18px rgba(0,0,0,0.14);
}

.caixa-imagem {
    height: 160px;
    border-radius: 12px;
    overflow: hidden;
    margin-bottom: 12px;
    background: #161616;
}

.caixa-imagem img {
    width: 100%;
    height: 100%;
    object-fit: cover;
}

.cartao-produto h3 {
    font-size: 20px;
    font-weight: 900;
    color: white;
    margin-bottom: 6px;
}

.cartao-produto p {
    color: var(--sf-muted);
    font-size: 14px;
    line-height: 1.35;
    margin-bottom: 16px;
    flex: 1;
}

.rodape-cartao {
    display: flex;
    justify-content: space-between;
    align-items: center;
    gap: 12px;
}

.preco {
    color: var(--sf-orange);
    font-size: 24px;
    font-weight: 900;
}

.botao-comprar {
    width: 44px;
    height: 44px;
    border-radius: 12px;
    border: 1px solid var(--sf-muted);
    background: transparent;
    color: white;
    font-size: 28px;
    line-height: 1;
    display: grid;
    place-items: center;
    transition: 0.2s ease;
}

.botao-comprar:hover {
    background: var(--sf-orange);
    border-color: var(--sf-orange);
}

.botao-comprar.adicionado {
    background: var(--sf-green);
    border-color: var(--sf-green);
    color: #121212;
}

.carrinho-flutuante {
    position: fixed;
    left: 264px;
    right: 28px;
    bottom: 20px;
    min-height: 80px;
    background: var(--sf-panel-2);
    border: 1px solid var(--sf-line);
    border-radius: 16px;
    box-shadow: var(--sf-shadow);
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 18px;
    padding: 14px 18px;
    z-index: 50;
}

.resumo-carrinho {
    display: flex;
    align-items: center;
    gap: 14px;
}

.icone-carrinho {
    position: relative;
    width: 48px;
    height: 48px;
    border-radius: 14px;
    background: #151515;
    display: grid;
    place-items: center;
    font-size: 24px;
}

.contador-carrinho {
    position: absolute;
    top: -7px;
    right: -7px;
    width: 24px;
    height: 24px;
    border-radius: 999px;
    background: var(--sf-orange);
    color: white;
    display: grid;
    place-items: center;
    font-size: 12px;
    font-weight: 900;
}

.texto-total {
    display: grid;
    gap: 3px;
}

.label-total {
    color: var(--sf-muted);
    font-size: 13px;
}

.numero-total {
    color: white;
    font-weight: 900;
    font-size: 24px;
}

.botao-finalizar {
    background: var(--sf-orange);
    color: white;
    border: 0;
    border-radius: 12px;
    padding: 15px 22px;
    font-weight: 900;
    text-transform: uppercase;
}

.botao-finalizar:hover {
    background: white;
    color: #121212;
}

.botao-finalizar:disabled {
    opacity: .55;
    cursor: not-allowed;
}

.modal-oculto {
    display: none;
    position: fixed;
    inset: 0;
    background: rgba(0,0,0,.82);
    z-index: 999;
    align-items: center;
    justify-content: center;
    padding: 20px;
}

.modal-oculto.ativo {
    display: flex;
}

.modal-conteudo {
    width: min(560px, 100%);
    max-height: 88vh;
    overflow-y: auto;
    background: var(--sf-panel);
    border: 1px solid var(--sf-line);
    border-radius: 18px;
    box-shadow: var(--sf-shadow);
    padding: 22px;
}

.modal-cabecalho {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 14px;
    margin-bottom: 12px;
}

.modal-cabecalho h2 {
    font-family: "Lobster", cursive;
    color: var(--sf-orange);
    font-size: 30px;
}

.modal-fechar {
    border: 0;
    background: transparent;
    color: var(--sf-muted);
    font-size: 24px;
    font-weight: 900;
}

.modal-fechar:hover {
    color: var(--sf-red);
}

.modal-produto-descricao {
    color: var(--sf-muted);
    line-height: 1.4;
    margin-bottom: 16px;
}

.modal-linha {
    margin: 14px 0;
}

.modal-linha label,
.modal-label {
    display: block;
    color: white;
    font-weight: 900;
    margin-bottom: 8px;
}

.controle-quantidade {
    display: flex;
    align-items: center;
    gap: 10px;
}

.controle-quantidade button {
    width: 40px;
    height: 40px;
    border: 1px solid var(--sf-line);
    background: #151515;
    color: white;
    border-radius: 12px;
    font-size: 22px;
    font-weight: 900;
}

.controle-quantidade span {
    min-width: 40px;
    text-align: center;
    font-size: 22px;
    font-weight: 900;
}

.lista-opcoes {
    display: grid;
    gap: 10px;
}

.item-opcao {
    display: flex;
    justify-content: space-between;
    align-items: center;
    gap: 14px;
    background: #151515;
    border: 1px solid var(--sf-line);
    border-radius: 12px;
    padding: 13px;
    cursor: pointer;
}

.item-opcao.selecionado {
    border-color: var(--sf-green);
    background: rgba(0, 230, 118, .08);
}

.item-opcao small {
    color: var(--sf-orange);
    display: block;
    margin-top: 3px;
}

.observacao-item,
.observacao-pedido {
    width: 100%;
    min-height: 86px;
    resize: vertical;
    background: #151515;
    border: 1px solid var(--sf-line);
    color: white;
    border-radius: 12px;
    padding: 12px;
}

.modal-total {
    border-top: 1px solid var(--sf-line);
    padding-top: 16px;
    margin-top: 16px;
    display: flex;
    align-items: center;
    justify-content: space-between;
    color: var(--sf-orange);
    font-size: 22px;
    font-weight: 900;
}

.botao-modal-confirmar {
    width: 100%;
    margin-top: 16px;
    background: var(--sf-orange);
    color: white;
    border: 0;
    border-radius: 12px;
    padding: 15px;
    font-weight: 900;
    text-transform: uppercase;
}

.lista-carrinho {
    display: grid;
    gap: 12px;
}

.item-carrinho {
    background: #151515;
    border: 1px solid var(--sf-line);
    border-radius: 12px;
    padding: 14px;
    display: flex;
    justify-content: space-between;
    gap: 14px;
    align-items: flex-start;
}

.item-carrinho h4 {
    color: white;
    font-size: 17px;
    margin-bottom: 5px;
}

.item-carrinho p,
.item-carrinho small {
    color: var(--sf-muted);
}

.botao-remover {
    background: transparent;
    color: var(--sf-red);
    border: 1px solid var(--sf-red);
    border-radius: 10px;
    padding: 8px 10px;
    font-weight: 900;
}

.pedido-mesa-card {
    background: #151515;
    border: 1px solid var(--sf-line);
    border-radius: 14px;
    padding: 14px;
    margin: 12px 0;
}

.pedido-mesa-topo {
    display: flex;
    justify-content: space-between;
    gap: 10px;
    margin-bottom: 10px;
}

.pedido-status {
    display: inline-block;
    border-radius: 999px;
    padding: 5px 9px;
    font-size: 12px;
    font-weight: 900;
    text-transform: uppercase;
    background: var(--sf-orange-soft);
    color: var(--sf-orange);
}

.pedido-itens {
    list-style: none;
    display: grid;
    gap: 8px;
    color: #eaeaea;
}

.pedido-itens li {
    border-top: 1px solid var(--sf-line);
    padding-top: 8px;
}

.alerta {
    background: var(--sf-panel);
    border: 1px solid var(--sf-line);
    border-radius: 14px;
    padding: 16px;
    color: var(--sf-muted);
}

.alerta.erro {
    color: #ffd0d0;
    border-color: var(--sf-red);
    background: rgba(255, 71, 71, .08);
}

.drawer-overlay {
    position: fixed;
    inset: 0;
    background: rgba(0,0,0,.64);
    z-index: 200;
    display: flex;
    align-items: stretch;
    transition: opacity .25s ease;
}

.drawer-fechado {
    opacity: 0;
    pointer-events: none;
}

.drawer-fechado .drawer-painel {
    transform: translateX(-100%);
}

.drawer-painel {
    width: min(320px, 78vw);
    background: #1A1A1A;
    border-right: 1px solid var(--sf-line);
    padding: 24px 18px;
    overflow-y: auto;
    transition: transform .25s ease;
}

.drawer-logo {
    display: flex;
    align-items: center;
    gap: 12px;
    margin-bottom: 18px;
}

.drawer-logo .logo-marca {
    width: 38px;
    height: 38px;
    border-radius: 12px;
    font-size: 22px;
}

.drawer-nome {
    font-family: "Lobster", cursive;
    font-size: 26px;
    line-height: 1;
}

.drawer-sub {
    color: var(--sf-orange);
    font-weight: 900;
}

.drawer-secao-label {
    color: var(--sf-muted);
    text-transform: uppercase;
    letter-spacing: .08em;
    font-size: 12px;
    font-weight: 900;
    margin: 18px 0 8px;
}

.drawer-cat-btn,
.drawer-pedidos-btn {
    width: 100%;
    text-align: left;
    background: transparent;
    color: var(--sf-text);
    border: 1px solid var(--sf-line);
    border-radius: 12px;
    padding: 13px;
    margin-bottom: 8px;
    font-weight: 900;
}

.drawer-cat-btn.ativo,
.drawer-cat-btn:hover,
.drawer-pedidos-btn:hover {
    background: var(--sf-orange);
    border-color: var(--sf-orange);
    color: white;
}

@media (max-width: 1024px) {
    body.menu-dark {
        overflow: hidden;
    }

    .aplicativo {
        display: block;
        overflow: hidden;
    }

    .menu-lateral {
        display: none;
    }

    .tela-principal {
        height: 100vh;
        height: 100dvh;
        padding: 16px;
        padding-bottom: 116px;
    }

    .botao-menu-mobile {
        display: inline-flex;
    }

    .topo-mesa {
        position: sticky;
        top: 0;
        z-index: 40;
        background: rgba(18,18,18,.92);
        backdrop-filter: blur(12px);
        padding: 10px 0;
    }

    .pedir-atendimento {
        padding: 10px 11px;
        font-size: 13px;
    }

    .grade-produtos {
        grid-template-columns: 1fr;
        gap: 14px;
    }

    .caixa-imagem {
        height: 150px;
    }

    .carrinho-flutuante {
        left: 12px;
        right: 12px;
        bottom: 12px;
        min-height: 76px;
        padding: 12px;
    }

    .botao-finalizar {
        padding: 12px 14px;
        font-size: 13px;
    }

    .numero-total {
        font-size: 19px;
    }

    .cabecalho h2 {
        font-size: 36px;
    }
}

@media (min-width: 1280px) {
    .grade-produtos {
        grid-template-columns: repeat(3, minmax(0, 1fr));
    }
}
