/* Cardápio público. Mobile primeiro; tablet a partir de 720 px; computador com pedido lateral a partir de 1100 px. */

html { scrollbar-gutter: stable; }
.wrap { width: 100%; max-width: 1240px; margin: 0 auto; padding: 0 16px; }
@media (min-width: 720px) { .wrap { padding: 0 24px; } }
@media (min-width: 1100px) { .wrap { padding: 0 32px; } }

.disp {
  font-family: var(--font-display); font-weight: var(--display-weight); font-stretch: var(--display-stretch);
  letter-spacing: -.01em;
}

/* ---------- Ambiente: dois brilhos derivando devagar, mais grão ---------- */
.ambiente { position: fixed; inset: 0; z-index: -1; pointer-events: none; overflow: hidden; background: var(--bg); }
.ambiente i { position: absolute; width: 95vmax; height: 95vmax; border-radius: 50%; opacity: var(--amb-op); will-change: transform; }
.ambiente i:nth-child(1) { left: -55vmax; top: -45vmax; background: radial-gradient(closest-side, var(--glow-1), transparent); animation: deriva-a 84s var(--ease-io) infinite alternate -21s; }
.ambiente i:nth-child(2) { right: -60vmax; top: 35vh; background: radial-gradient(closest-side, var(--glow-2), transparent); animation: deriva-b 96s var(--ease-io) infinite alternate -47s; }
.ambiente::after {
  content: ""; position: absolute; inset: 0; opacity: .06;
  background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='180' height='180'%3E%3Cfilter id='n'%3E%3CfeTurbulence type='fractalNoise' baseFrequency='.85' numOctaves='2' stitchTiles='stitch'/%3E%3CfeColorMatrix values='0 0 0 0 .5 0 0 0 0 .5 0 0 0 0 .5 0 0 0 1 0'/%3E%3C/filter%3E%3Crect width='100%25' height='100%25' filter='url(%23n)'/%3E%3C/svg%3E");
}
[data-theme="light"] .ambiente::after { opacity: .045; }
@keyframes deriva-a { to { transform: translate(20vw, 18vh) scale(1.08); } }
@keyframes deriva-b { to { transform: translate(-18vw, -22vh) scale(.9); } }

/* ---------- Capa e cartão da loja ---------- */
.topo { position: relative; }
.capa { position: relative; height: 196px; overflow: hidden; background: var(--bg-3); }
.capa img { width: 100%; height: 100%; object-fit: cover; }
.capa::after {
  content: ""; position: absolute; inset: 0;
  background:
    linear-gradient(to bottom, rgba(5,6,12,.62) 0%, rgba(5,6,12,.08) 34%, rgba(5,6,12,0) 50%),
    linear-gradient(to bottom, transparent 42%, var(--bg) 99%);
}
.topo-acoes {
  position: absolute; left: 0; right: 0; top: calc(12px + env(safe-area-inset-top)); z-index: 2;
  display: flex; align-items: center; justify-content: space-between; gap: 8px;
}
.topo-dir { display: flex; gap: 8px; margin-left: auto; }
.vidro {
  color: #fff; background: rgba(8,10,18,.42); border: 1px solid rgba(255,255,255,.16);
  -webkit-backdrop-filter: blur(10px); backdrop-filter: blur(10px);
}
.vidro:hover { background: rgba(8,10,18,.6); }

.pilula-future {
  position: relative; isolation: isolate;
  display: inline-flex; align-items: center; gap: 8px; height: 36px; padding: 0 14px 0 10px;
  color: #fff; font-size: 12.5px; font-weight: 600; letter-spacing: .02em;
}
.pilula-future::before {
  content: ""; position: absolute; inset: 0; z-index: -1; border-radius: 8px;
  background: rgba(8,10,18,.5); border: 1px solid rgba(255,255,255,.18);
  -webkit-backdrop-filter: blur(10px); backdrop-filter: blur(10px);
  clip-path: polygon(0 0, 100% 0, 100% calc(100% - 9px), calc(100% - 9px) 100%, 0 100%);
}
.pilula-future:hover::before { background: rgba(8,10,18,.7); }
.pilula-future .marca-future { width: 20px; height: 15px; }

.loja { position: relative; margin-top: -58px; display: grid; grid-template-columns: auto minmax(0, 1fr); column-gap: 14px; row-gap: 12px; }
.loja-logo {
  grid-row: 1 / span 2; align-self: end;
  width: 78px; height: 78px; border-radius: 18px; overflow: hidden; background: var(--bg-2);
  box-shadow: 0 0 0 3px var(--bg), 0 12px 30px rgba(0,0,0,.35);
}
.loja-logo img { width: 100%; height: 100%; object-fit: cover; }
.loja-logo.sem { display: grid; place-items: center; background: var(--accent); color: var(--accent-ink); font-size: 26px; }
.capa.sem-capa { background: radial-gradient(70% 120% at 20% 0%, color-mix(in srgb, var(--glow-1) 45%, transparent), transparent 70%), radial-gradient(60% 120% at 90% 10%, color-mix(in srgb, var(--glow-2) 40%, transparent), transparent 70%), var(--bg-3); }
.loja-nome { align-self: end; font-size: clamp(22px, 6.2vw, 44px); line-height: 1.1; overflow-wrap: anywhere; text-shadow: 0 2px 18px rgba(5,6,12,.5); }
[data-theme="light"] .loja-nome { text-shadow: 0 1px 14px rgba(255,255,255,.7); }
.loja-status { display: flex; flex-wrap: wrap; align-items: baseline; gap: 4px 10px; font-size: 14px; }
.status { display: inline-flex; align-items: center; gap: 8px; font-weight: 600; }
.status-ponto { position: relative; width: 8px; height: 8px; border-radius: 50%; background: var(--ok); }
.status-ponto::after {
  content: ""; position: absolute; inset: -4px; border-radius: 50%; background: var(--ok); opacity: .25;
  animation: pulso 4s var(--ease-io) infinite -1.3s;
}
.status.fechado .status-ponto { background: var(--danger); }
.status.fechado .status-ponto::after { background: var(--danger); animation: none; }
.status-det { color: var(--text-2); }
@keyframes pulso { 0%, 100% { transform: scale(.7); opacity: .1; } 50% { transform: scale(1.35); opacity: .3; } }

.loja-desc { grid-column: 1 / -1; color: var(--text-2); font-size: 15px; line-height: 1.5; max-width: 62ch; }
.chips { grid-column: 1 / -1; display: flex; flex-wrap: wrap; gap: 8px; }
@media (max-width: 719.98px) {
  .chips { flex-wrap: nowrap; overflow-x: auto; margin: 0 -16px; padding: 0 16px 2px; scrollbar-width: none; overscroll-behavior-x: contain; }
  .chips::-webkit-scrollbar { display: none; }
  .chip { flex: none; white-space: nowrap; }
}
.chip {
  display: inline-flex; align-items: center; gap: 6px; min-height: 32px; padding: 5px 10px;
  border-radius: 8px; background: color-mix(in srgb, var(--bg-2) 86%, transparent); border: 1px solid var(--line);
  font-size: 13px; color: var(--text-2); line-height: 1.25;
}
.chip .ic { width: 16px; height: 16px; color: var(--text-3); }
.chip b { color: var(--text); font-weight: 600; }
.loja-botoes { grid-column: 1 / -1; display: flex; gap: 10px; }
.loja-botoes .btn { flex: 1 1 0; min-width: 0; }
.aviso-fechado {
  grid-column: 1 / -1; display: flex; gap: 10px; align-items: flex-start;
  padding: 12px 14px; border-radius: 10px; font-size: 14px;
  background: color-mix(in srgb, var(--danger) 12%, transparent); border: 1px solid color-mix(in srgb, var(--danger) 35%, transparent);
}
.aviso-fechado .ic { color: var(--danger); margin-top: 1px; }

@media (min-width: 720px) {
  .capa { height: 300px; }
  .loja { margin-top: -84px; grid-template-columns: auto minmax(0, 1fr) auto; column-gap: 24px; }
  .loja-nome { font-size: clamp(26px, 3.6vw, 44px); }
  .loja-logo { width: 112px; height: 112px; border-radius: 24px; grid-row: 1 / span 3; }
  .loja-desc { grid-column: 2 / 3; }
  .chips { grid-column: 2 / -1; }
  .loja-botoes { grid-column: 3; grid-row: 1 / span 2; align-self: end; flex-wrap: nowrap; }
  .aviso-fechado { grid-column: 2 / -1; }
}
@media (min-width: 1100px) { .capa { height: 340px; } }

/* ---------- Barra fixa: busca e categorias ---------- */
.barra {
  position: sticky; top: 0; z-index: 30; margin-top: 20px;
  background: color-mix(in srgb, var(--bg) 84%, transparent);
  -webkit-backdrop-filter: saturate(150%) blur(14px); backdrop-filter: saturate(150%) blur(14px);
  border-bottom: 1px solid var(--line);
}
.barra-in { display: flex; align-items: center; gap: 4px; height: 60px; }
.barra-busca { color: var(--text-2); }
.cats {
  position: relative; flex: 1; min-width: 0; height: 100%;
  overflow-x: auto; overscroll-behavior-x: contain; scrollbar-width: none;
  -webkit-mask-image: linear-gradient(to right, transparent 0, #000 10px, #000 calc(100% - 28px), transparent 100%);
  mask-image: linear-gradient(to right, transparent 0, #000 10px, #000 calc(100% - 28px), transparent 100%);
}
.cats::-webkit-scrollbar { display: none; }
.cats-trilho { display: flex; align-items: center; gap: 2px; height: 100%; width: max-content; padding: 0 28px 0 6px; }
.cat {
  height: 40px; padding: 0 12px; border-radius: 8px;
  font-size: 14.5px; font-weight: 500; color: var(--text-2); white-space: nowrap;
  transition: color .2s var(--ease), background-color .2s var(--ease);
}
.cat:hover { color: var(--text); background: var(--accent-soft); }
.cat[aria-current="true"] { color: var(--text); font-weight: 600; }
/* Indicador de dois traços: desliza até a categoria ativa. */
.cats-ind {
  position: absolute; left: 0; bottom: 7px; height: 7px; width: 40px; pointer-events: none;
  transform: translateX(var(--x, 0px)); opacity: 0;
  transition: transform .4s var(--ease), width .4s var(--ease), opacity .2s var(--ease);
}
.cats-ind.on { opacity: 1; }
.cats-ind i { position: absolute; height: 2.5px; border-radius: 1px; transform: skewX(-45deg); }
.cats-ind i:first-child { top: 0; left: 7px; right: 0; background: var(--glyph-1); }
.cats-ind i:last-child { top: 4.5px; left: 2px; right: 9px; background: var(--glyph-2); }

.busca { flex: 1; display: flex; align-items: center; gap: 4px; min-width: 0; }
.busca input {
  flex: 1; min-width: 0; height: 42px; padding: 0 14px; border-radius: 10px;
  background: var(--bg-3); border: 1px solid var(--line-2); font-size: 16px;
}
.busca input:focus { outline: none; border-color: var(--accent); box-shadow: 0 0 0 3px var(--accent-soft); }
.busca input::-webkit-search-cancel-button { display: none; }
.barra.buscando .cats { display: none; }

/* ---------- Estrutura principal ---------- */
.layout { padding-top: 4px; padding-bottom: 132px; }
.principal { min-width: 0; outline: none; }
@media (min-width: 1100px) {
  .layout { display: grid; grid-template-columns: minmax(0, 1fr) 368px; gap: 40px; align-items: start; padding-bottom: 72px; }
}

.aviso-mesa {
  margin-top: 16px; display: flex; align-items: center; gap: 10px;
  padding: 12px 14px; border-radius: 10px; background: var(--accent-soft); border: 1px solid var(--accent-line); font-size: 14px;
}
.aviso-mesa .ic { color: var(--accent-text); }

.secao { padding-top: 30px; scroll-margin-top: 72px; }
.secao-cab { display: flex; align-items: center; gap: 10px; }
.secao-tit { font-size: 19px; line-height: 1.25; }
.secao-qtd { margin-left: auto; font: 500 11.5px/1 var(--font-mono); letter-spacing: .08em; text-transform: uppercase; color: var(--text-3); white-space: nowrap; }
.secao-desc { color: var(--text-2); font-size: 14px; margin: 4px 0 0 32px; max-width: 60ch; }
@media (min-width: 720px) { .secao-tit { font-size: 22px; } }

/* ---------- Destaques ---------- */
.destaques { padding-top: 22px; }
.destaques .secao-cab { margin-bottom: 12px; }
.dest-setas { margin-left: auto; display: none; gap: 6px; }
.dest-setas .btn-ico { width: 38px; height: 38px; border: 1px solid var(--line-2); border-radius: 10px; }
.dest-setas .btn-ico[disabled] { opacity: .35; cursor: default; background: none; }
@media (min-width: 720px) and (pointer: fine) { .dest-setas { display: flex; } }
.trilho-h {
  display: flex; gap: 12px; overflow-x: auto; scroll-snap-type: x mandatory; scroll-padding: 0 16px;
  padding: 2px 16px 10px; margin: 0 -16px; scrollbar-width: none; overscroll-behavior-x: contain;
}
.trilho-h::-webkit-scrollbar { display: none; }
@media (min-width: 720px) { .trilho-h { margin: 0 -24px; padding: 2px 24px 10px; scroll-padding: 0 24px; } }
@media (min-width: 1100px) { .trilho-h { margin: 0; padding: 2px 0 10px; scroll-padding: 0; } }
.dest {
  position: relative; flex: 0 0 min(74vw, 264px); scroll-snap-align: start;
  display: flex; flex-direction: column;
  border-radius: var(--r-m); background: var(--bg-2); border: 1px solid var(--line); overflow: hidden;
  transition: border-color .25s var(--ease), transform .25s var(--ease);
}
.dest:hover { border-color: var(--line-2); transform: translateY(-2px); }
.dest-img { position: relative; aspect-ratio: 4 / 3; background: var(--bg-3); overflow: hidden; }
.dest-img img { width: 100%; height: 100%; object-fit: cover; transition: transform .6s var(--ease); }
.dest:hover .dest-img img { transform: scale(1.04); }
.dest-corpo { flex: 1; display: flex; flex-direction: column; gap: 6px; padding: 12px 14px 14px; }
.dest-nome { font-size: 15.5px; font-weight: 600; line-height: 1.3; }
.dest-nome button { text-align: left; }
.dest-nome button::after { content: ""; position: absolute; inset: 0; z-index: 1; }
.dest .tags { margin-top: auto; }
.dest .item-add { top: auto; right: 10px; bottom: 10px; }

/* ---------- Cartões de produto ---------- */
.itens { margin-top: 8px; }
.item {
  position: relative; display: grid; grid-template-columns: minmax(0, 1fr) 104px; gap: 14px;
  padding: 16px 0; border-bottom: 1px solid var(--line);
}
.item:last-child { border-bottom: 0; }
.item.sem-img { grid-template-columns: minmax(0, 1fr) auto; }
.item-txt { min-width: 0; display: flex; flex-direction: column; gap: 6px; }
.item-nome { font-size: 16px; font-weight: 600; line-height: 1.3; }
.item-abrir { text-align: left; }
.item-abrir::after { content: ""; position: absolute; inset: 0; z-index: 1; border-radius: var(--r-m); }
.item-abrir:focus-visible { outline: none; }
.item-abrir:focus-visible::after { outline: 2px solid var(--accent-text); outline-offset: 2px; }
.item-desc {
  font-size: 14px; line-height: 1.45; color: var(--text-2);
  display: -webkit-box; -webkit-line-clamp: 2; -webkit-box-orient: vertical; overflow: hidden;
}
.item-rodape { margin-top: auto; padding-top: 4px; display: flex; flex-wrap: wrap; align-items: center; gap: 6px 10px; }
.preco { display: inline-flex; align-items: baseline; gap: 6px; flex-wrap: wrap; font-size: 16px; }
.preco b { font-weight: 600; }
.preco small { font-size: 12.5px; color: var(--text-3); font-weight: 500; }
.preco s { font-size: 13px; color: var(--text-3); }
.preco.promo b { color: var(--accent-text); }

.item-img { position: relative; width: 104px; height: 104px; border-radius: 10px; overflow: hidden; background: var(--bg-3); align-self: start; }
.item-img img { width: 100%; height: 100%; object-fit: cover; transition: transform .5s var(--ease), filter .3s var(--ease); }
.item:hover .item-img img { transform: scale(1.05); }

.item-add {
  position: absolute; right: -6px; top: 82px; z-index: 2;
  width: 40px; height: 40px; display: grid; place-items: center; isolation: isolate;
  color: var(--accent-ink); transition: transform .15s var(--ease);
}
.item-add::before {
  content: ""; position: absolute; inset: 0; z-index: -1; border-radius: 10px;
  background: var(--accent); box-shadow: 0 6px 16px rgba(0,0,0,.28);
  clip-path: polygon(0 0, 100% 0, 100% calc(100% - 9px), calc(100% - 9px) 100%, 0 100%);
  transition: background-color .2s var(--ease);
}
.item-add:hover::before { background: var(--accent-hover); }
.item-add:active { transform: scale(.94); }
.item-add .ic { width: 20px; height: 20px; stroke-width: 2.2; }
.item.sem-img .item-add { position: relative; right: auto; top: auto; align-self: end; }
@media (pointer: coarse) { .item-add::after { content: ""; position: absolute; inset: -4px; } }

.tags { display: flex; flex-wrap: wrap; gap: 6px; }
.tag {
  display: inline-flex; align-items: center; gap: 4px; height: 22px; padding: 0 7px; border-radius: 6px;
  font-size: 11.5px; font-weight: 600; letter-spacing: .01em; white-space: nowrap;
  background: var(--bg-3); color: var(--text-2);
}
.tag .ic { width: 13px; height: 13px; }
.tag-promo { background: var(--accent-soft); color: var(--accent-text); }
.tag-popular .ic { color: var(--glyph-1); fill: currentColor; stroke: none; }
.tag-novo { color: var(--text); box-shadow: inset 0 0 0 1px var(--line-2); background: transparent; }

/* Esgotado e indisponível: a faixa inclinada sobre a foto. */
.item.is-out .item-img img, .dest.is-out .dest-img img { filter: grayscale(1) brightness(.62); }
.item.is-out .item-nome, .item.is-out .preco, .item.is-out .item-desc, .dest.is-out .dest-corpo { opacity: .62; }
.faixa {
  position: absolute; left: -12%; right: -12%; top: 50%; z-index: 1;
  transform: translateY(-50%) rotate(-14deg);
  padding: 5px 0; text-align: center;
  background: rgba(8,9,15,.86); color: #fff;
  font: 600 10.5px/1.2 var(--font-mono); letter-spacing: .16em; text-transform: uppercase;
  border-top: 1px solid var(--danger); border-bottom: 1px solid var(--danger);
}
.faixa-pausa { border-color: var(--warn); }
.status-item { display: inline-flex; align-items: center; gap: 6px; font-size: 13px; font-weight: 600; color: var(--danger); }
.status-item.pausa { color: var(--warn); }

@media (min-width: 720px) {
  .itens { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 14px; margin-top: 14px; }
  .item {
    padding: 14px; border: 1px solid var(--line); border-radius: var(--r-m);
    background: color-mix(in srgb, var(--bg-2) 92%, transparent);
    grid-template-columns: minmax(0, 1fr) 116px;
    transition: border-color .25s var(--ease), transform .25s var(--ease), background-color .25s var(--ease);
  }
  .item:last-child { border-bottom: 1px solid var(--line); }
  .item:hover { border-color: var(--line-2); transform: translateY(-2px); }
  .item-img { width: 116px; height: 116px; }
  .item-add { right: 8px; top: 92px; }
  .item.sem-img .item-add { right: auto; top: auto; }
}

/* Entrada suave dos itens ao aparecer na tela (só uma vez). */
.revela { opacity: 0; transform: translateY(10px); transition: opacity .5s var(--ease), transform .6s var(--ease); }
.revela.in { opacity: 1; transform: none; }

/* ---------- Busca ---------- */
.resultados { padding-top: 24px; }
.resultados-tit { font-size: 15px; color: var(--text-2); margin-bottom: 4px; }
.resultados-tit b { color: var(--text); }
.vazio { padding: 40px 8px; text-align: center; color: var(--text-2); display: grid; justify-items: center; gap: 10px; }
.vazio .ic { width: 32px; height: 32px; color: var(--text-3); }
.vazio strong { color: var(--text); font-size: 16px; }

/* ---------- Informações ---------- */
.info { padding-top: 44px; }
.info-grade { display: grid; gap: 12px; margin-top: 16px; }
@media (min-width: 720px) { .info-grade { grid-template-columns: repeat(2, minmax(0, 1fr)); } }
.info-card {
  padding: 18px; border-radius: var(--r-m); background: color-mix(in srgb, var(--bg-2) 92%, transparent); border: 1px solid var(--line);
  display: flex; flex-direction: column; gap: 10px; min-width: 0;
}
.info-card h3 { display: flex; align-items: center; gap: 8px; font-size: 15px; font-weight: 600; }
.info-card h3 .ic { color: var(--accent-text); }
.info-card p { color: var(--text-2); font-size: 14.5px; }
.info-card .btn { align-self: flex-start; }
.horarios { display: grid; gap: 2px; font-size: 14px; }
.horarios li { display: flex; justify-content: space-between; gap: 12px; padding: 6px 8px; border-radius: 8px; color: var(--text-2); }
.horarios li span:last-child { text-align: right; }
.horarios li.hoje { background: var(--accent-soft); color: var(--text); font-weight: 600; }
.horarios li.hoje span:first-child::after { content: " · hoje"; font-weight: 500; color: var(--accent-text); }
.horarios li.fechado span:last-child { color: var(--text-3); }
.linhas-info { display: grid; gap: 8px; font-size: 14px; color: var(--text-2); }
.linhas-info li { display: flex; gap: 10px; align-items: flex-start; }
.linhas-info .ic { width: 18px; height: 18px; color: var(--text-3); margin-top: 1px; }
.linhas-info b { color: var(--text); font-weight: 600; }
.pagamentos { display: flex; flex-wrap: wrap; gap: 6px; }
.contatos { display: flex; flex-wrap: wrap; gap: 8px; }

/* ---------- Rodapé com a assinatura ---------- */
.rodape { padding-top: 28px; padding-bottom: calc(110px + env(safe-area-inset-bottom)); display: grid; justify-items: center; gap: 6px; text-align: center; border-top: 1px solid var(--line); margin-top: 40px; color: var(--text-3); font-size: 13px; }
@media (min-width: 1100px) { .rodape { padding-bottom: 40px; } }
.assinatura { display: inline-flex; align-items: center; gap: 8px; margin-top: 10px; padding: 8px 12px; border-radius: 10px; color: var(--text-2); font-size: 13px; transition: background-color .2s var(--ease), color .2s var(--ease); }
.assinatura:hover { background: var(--accent-soft); color: var(--text); }
.assinatura b { font-family: 'Unbounded', var(--font-text); font-weight: 600; font-size: 12px; letter-spacing: .14em; color: var(--text); }

/* ---------- Pedido: barra no celular, painel lateral no computador ---------- */
.barra-pedido {
  position: fixed; left: 12px; right: 12px; bottom: calc(12px + env(safe-area-inset-bottom)); z-index: 40;
  display: flex; align-items: center; gap: 12px; height: 58px; padding: 0 18px 0 12px;
  color: var(--accent-ink); font-weight: 600; isolation: isolate;
  transform: translateY(0); transition: transform .35s var(--ease), opacity .25s var(--ease);
}
.barra-pedido::before {
  content: ""; position: absolute; inset: 0; z-index: -1; border-radius: 14px; background: var(--accent);
  box-shadow: 0 14px 34px rgba(0,0,0,.4);
  clip-path: polygon(0 0, 100% 0, 100% calc(100% - 13px), calc(100% - 13px) 100%, 0 100%);
}
.barra-pedido.sai { transform: translateY(140%); opacity: 0; pointer-events: none; }
.bp-icone { position: relative; width: 38px; height: 38px; display: grid; place-items: center; border-radius: 10px; background: color-mix(in srgb, var(--accent-ink) 16%, transparent); }
.bp-qtd {
  position: absolute; top: -6px; right: -6px; min-width: 20px; height: 20px; padding: 0 5px; border-radius: 10px;
  background: var(--accent-ink); color: var(--accent); font-size: 11.5px; font-weight: 700; display: grid; place-items: center;
}
.bp-txt { flex: 1; text-align: left; }
.bp-total { font-variant-numeric: tabular-nums; }
.barra-pedido.pulo { animation: pulo .45s var(--ease); }
@keyframes pulo { 0% { transform: scale(1); } 35% { transform: scale(1.035); } 100% { transform: scale(1); } }
@media (min-width: 720px) { .barra-pedido { left: auto; right: 24px; width: 380px; } }
@media (min-width: 1100px) { .barra-pedido { display: none; } }

.zap-flutuante {
  position: fixed; right: 16px; bottom: calc(18px + env(safe-area-inset-bottom)); z-index: 39;
  width: 54px; height: 54px; border-radius: 50%; display: grid; place-items: center;
  background: #1fae55; color: #fff; box-shadow: 0 10px 28px rgba(0,0,0,.35);
  transition: transform .3s var(--ease), bottom .35s var(--ease), background-color .2s var(--ease);
}
.zap-flutuante:hover { background: #22c35e; transform: translateY(-2px); }
.zap-flutuante .ic { width: 28px; height: 28px; stroke-width: 1.6; }
body.com-pedido .zap-flutuante { bottom: calc(84px + env(safe-area-inset-bottom)); }
@media (min-width: 720px) { body.com-pedido .zap-flutuante { bottom: calc(88px + env(safe-area-inset-bottom)); } }
@media (min-width: 1100px) { body.com-pedido .zap-flutuante { bottom: 24px; } .zap-flutuante { right: 24px; bottom: 24px; } }

.pedido {
  position: fixed; z-index: 70; left: 0; right: 0; bottom: 0; height: 92dvh; max-height: 92vh;
  display: flex; flex-direction: column; background: var(--bg-2);
  border-radius: 18px 18px 0 0; box-shadow: 0 -20px 60px rgba(0,0,0,.45);
  transform: translateY(102%); visibility: hidden;
  transition: transform .32s var(--ease), visibility 0s linear .32s;
}
.pedido.on { transform: none; visibility: visible; transition: transform .4s var(--ease), visibility 0s; }
@media (min-width: 720px) and (max-width: 1099.98px) {
  .pedido { left: auto; top: 0; height: 100dvh; max-height: none; width: 420px; border-radius: 16px 0 0 16px; transform: translateX(102%); }
  .pedido.on { transform: none; }
}
@media (min-width: 1100px) {
  .pedido {
    position: sticky; top: 76px; z-index: 1; height: auto; max-height: calc(100vh - 92px); margin-top: 24px;
    transform: none; visibility: visible; transition: none;
    border-radius: var(--r-l); border: 1px solid var(--line); box-shadow: none;
    background: color-mix(in srgb, var(--bg-2) 94%, transparent);
  }
  .pedido-fechar { display: none; }
}
.pedido-cab { display: flex; align-items: center; gap: 10px; padding: 14px 12px 10px 20px; border-bottom: 1px solid var(--line); }
.pedido-cab h2 { font-size: 17px; font-weight: 600; display: flex; align-items: center; gap: 10px; }
.pedido-cab .glifo { width: 18px; height: 10px; }
.pedido-cab .contagem { font: 500 11.5px/1 var(--font-mono); letter-spacing: .06em; color: var(--text-3); text-transform: uppercase; }
.pedido-fechar { margin-left: auto; }
.pedido-corpo { flex: 1; overflow-y: auto; overscroll-behavior: contain; padding: 4px 20px 16px; }
.pedido-pe { padding: 12px 16px calc(14px + env(safe-area-inset-bottom)); border-top: 1px solid var(--line); display: grid; gap: 8px; }
@media (min-width: 1100px) { .pedido-pe { padding-bottom: 16px; } }
.pedido-pe .dica { text-align: center; }

.pedido-vazio { display: grid; justify-items: center; text-align: center; gap: 8px; padding: 36px 10px 24px; color: var(--text-2); font-size: 14px; }
.pedido-vazio .ic { width: 34px; height: 34px; color: var(--text-3); stroke-width: 1.4; }
.pedido-vazio strong { color: var(--text); font-size: 15.5px; }

.linhas > li { padding: 14px 0; border-bottom: 1px solid var(--line); display: grid; gap: 6px; }
.linha-topo { display: flex; gap: 12px; align-items: baseline; justify-content: space-between; }
.linha-topo strong { font-weight: 600; font-size: 15px; line-height: 1.3; }
.linha-topo span { font-weight: 600; font-variant-numeric: tabular-nums; white-space: nowrap; }
.linha-desc, .linha-obs { font-size: 13px; color: var(--text-2); line-height: 1.4; }
.linha-obs { font-style: italic; }
.linha-acoes { display: flex; align-items: center; justify-content: space-between; gap: 10px; margin-top: 2px; }
.linha-remover { display: inline-flex; align-items: center; gap: 6px; font-size: 13px; font-weight: 600; color: var(--text-3); min-height: 36px; padding: 0 6px; border-radius: 8px; }
.linha-remover:hover { color: var(--danger); }
.linha.off strong, .linha.off .linha-topo span { color: var(--text-3); text-decoration: line-through; }
.linha-aviso { display: flex; align-items: center; gap: 6px; font-size: 13px; font-weight: 600; color: var(--danger); }
.linha-aviso .ic { width: 16px; height: 16px; }

.resumo { display: grid; gap: 6px; padding: 14px 0 4px; font-size: 14.5px; }
.resumo div { display: flex; justify-content: space-between; gap: 12px; color: var(--text-2); }
.resumo div span:last-child { font-variant-numeric: tabular-nums; }
.resumo .total { color: var(--text); font-weight: 600; font-size: 17px; padding-top: 8px; border-top: 1px dashed var(--line-2); margin-top: 4px; }
.resumo .gratis { color: var(--ok); font-weight: 600; }
.mais-itens { justify-self: start; margin-top: 4px; }

.form-pedido { display: grid; gap: 18px; padding-top: 12px; }
.form-pedido fieldset { border: 0; padding: 0; margin: 0; display: grid; gap: 8px; min-width: 0; }
.form-pedido legend { padding: 0; margin-bottom: 8px; font-size: 13px; font-weight: 600; color: var(--text-2); }
.form-pedido .seg span { flex-direction: column; gap: 4px; min-height: 64px; }
.form-pedido .seg .ic { width: 22px; height: 22px; }
.seg-pag span { min-height: 44px !important; flex-direction: row !important; font-size: 13.5px; }
.seg-pag label { flex: 1 1 calc(50% - 6px); }
.linha-2 { display: grid; grid-template-columns: minmax(0, 1fr); gap: 10px; }
.voltar { display: inline-flex; align-items: center; gap: 4px; font-size: 14px; font-weight: 600; color: var(--text-2); min-height: 40px; padding: 0 6px 0 0; }
.voltar:hover { color: var(--text); }
.estimativa { font-size: 13px; color: var(--text-3); display: flex; align-items: center; gap: 6px; }
.estimativa .ic { width: 16px; height: 16px; }
.aviso { display: flex; gap: 10px; padding: 12px 14px; border-radius: 10px; font-size: 13.5px; line-height: 1.45; background: var(--bg-3); color: var(--text-2); }
.aviso .ic { flex: none; width: 18px; height: 18px; margin-top: 1px; }
.aviso.alerta { background: color-mix(in srgb, var(--warn) 12%, transparent); color: var(--text); }
.aviso.alerta .ic { color: var(--warn); }
.aviso.erro { background: color-mix(in srgb, var(--danger) 12%, transparent); color: var(--text); }
.aviso.erro .ic { color: var(--danger); }

.enviado { display: grid; justify-items: center; text-align: center; gap: 12px; padding: 34px 6px 12px; }
.enviado-sinal { width: 64px; height: 64px; border-radius: 18px; display: grid; place-items: center; background: color-mix(in srgb, var(--ok) 16%, transparent); color: var(--ok); }
.enviado-sinal .ic { width: 30px; height: 30px; stroke-width: 2.2; }
.enviado h3 { font-size: 19px; }
.enviado p { color: var(--text-2); font-size: 14.5px; max-width: 34ch; }

/* ---------- Camadas: fundo escuro, ficha do produto, apresentação ---------- */
.fundo { position: fixed; inset: 0; z-index: 60; background: rgba(4,5,10,.64); opacity: 0; transition: opacity .28s var(--ease); }
.fundo.on { opacity: 1; }
html.travado { overflow: hidden; }

.ficha {
  position: fixed; z-index: 70; left: 0; right: 0; bottom: 0; max-height: 92dvh; max-height: min(92dvh, 92vh);
  display: flex; flex-direction: column; background: var(--bg-2);
  border-radius: 18px 18px 0 0; box-shadow: 0 -20px 60px rgba(0,0,0,.45); overflow: hidden;
  transform: translateY(102%); visibility: hidden;
  transition: transform .3s var(--ease), visibility 0s linear .3s;
}
.ficha.on { transform: translateY(0); visibility: visible; transition: transform .42s var(--ease), visibility 0s; }
.ficha-rolagem { flex: 1; min-height: 0; overflow-y: auto; overscroll-behavior: contain; }
.ficha-foto { position: relative; aspect-ratio: 16 / 10; background: var(--bg-3); }
.ficha-foto img { width: 100%; height: 100%; object-fit: cover; }
.ficha-foto.sem { aspect-ratio: auto; height: 68px; }
/* Fixo em relação à própria ficha (que tem transform): os botões ficam sempre à mão. */
.ficha-topo { position: fixed; top: 12px; right: 12px; display: flex; gap: 8px; z-index: 3; }
.ficha-corpo { padding: 18px 18px 22px; display: grid; gap: 16px; }
.ficha-nome { font-size: 22px; font-weight: 600; line-height: 1.25; }
.ficha-desc { color: var(--text-2); font-size: 15px; line-height: 1.55; }
.ficha .preco { font-size: 18px; }
.ficha-pe { display: flex; gap: 10px; padding: 12px 16px calc(12px + env(safe-area-inset-bottom)); border-top: 1px solid var(--line); background: var(--bg-2); }
.ficha-pe .btn-acc { flex: 1; justify-content: space-between; padding: 0 18px; min-height: 48px; }
.ficha-pe .btn-acc .num { font-variant-numeric: tabular-nums; }
.ficha-pe .qtd { height: 48px; }
.ficha-pe .qtd button { height: 46px; }
.ficha-aviso { margin: 0; }
.ficha-comp { margin-left: auto; display: inline-flex; align-items: center; gap: 6px; min-height: 36px; padding: 0 10px; border-radius: 8px; font-size: 13px; font-weight: 600; color: var(--text-2); }
.ficha-comp:hover { color: var(--text); background: var(--accent-soft); }

.grupo { border: 0; margin: 0; padding: 0; min-width: 0; scroll-margin-top: 12px; }
.grupo-cab {
  display: flex; align-items: center; gap: 8px; flex-wrap: wrap; width: 100%;
  padding: 12px 14px; margin-bottom: 4px; border-radius: 10px; background: var(--bg-3);
}
.grupo-nome { font-weight: 600; font-size: 15px; }
.grupo-dica { font-size: 13px; color: var(--text-3); width: 100%; order: 3; }
.selo { margin-left: auto; height: 22px; padding: 0 8px; border-radius: 6px; display: inline-flex; align-items: center; font-size: 11.5px; font-weight: 600; background: var(--bg-2); color: var(--text-2); }
.selo.obrig { background: var(--accent-soft); color: var(--accent-text); }
.selo.ok { background: color-mix(in srgb, var(--ok) 16%, transparent); color: var(--ok); }
.grupo.erro .grupo-cab { box-shadow: inset 0 0 0 1.5px var(--danger); animation: tremor .4s var(--ease); }
.grupo-erro { color: var(--danger); font-size: 13px; font-weight: 600; padding: 6px 4px 0; }
@keyframes tremor { 0%, 100% { transform: translateX(0); } 25% { transform: translateX(-4px); } 75% { transform: translateX(4px); } }

.op {
  position: relative; display: flex; align-items: center; gap: 12px; min-height: 54px; padding: 8px 4px 8px 6px;
  border-bottom: 1px solid var(--line); cursor: pointer;
}
.op:last-child { border-bottom: 0; }
.op-txt { flex: 1; min-width: 0; display: grid; gap: 2px; }
.op-nome { font-size: 15px; line-height: 1.3; }
.op-preco { font-size: 13.5px; color: var(--text-2); font-variant-numeric: tabular-nums; }
.op.off { cursor: not-allowed; }
.op.off .op-nome, .op.off .op-preco { color: var(--text-3); }
.op.off .op-preco::after { content: " · esgotado"; }
.op input { position: absolute; opacity: 0; width: 1px; height: 1px; }
.marca {
  flex: none; width: 24px; height: 24px; border: 2px solid var(--line-2); border-radius: 50%;
  display: grid; place-items: center; transition: border-color .2s var(--ease), background-color .2s var(--ease);
}
.marca::after { content: ""; width: 10px; height: 10px; border-radius: 50%; background: var(--accent-ink); transform: scale(0); transition: transform .2s var(--ease); }
.op input:checked ~ .marca { border-color: var(--accent); background: var(--accent); }
.op input:checked ~ .marca::after { transform: scale(1); }
.op input[type="checkbox"] ~ .marca { border-radius: 7px; }
.op input[type="checkbox"] ~ .marca::after { width: 12px; height: 7px; border-radius: 0; background: none; border: solid var(--accent-ink); border-width: 0 0 2.5px 2.5px; transform: translateY(-1px) rotate(-45deg) scale(0); }
.op input[type="checkbox"]:checked ~ .marca::after { transform: translateY(-1px) rotate(-45deg) scale(1); }
.op input:focus-visible ~ .marca { outline: 2px solid var(--accent-text); outline-offset: 2px; }
.op input:disabled ~ .marca { opacity: .4; }
.op .qtd { margin-left: 4px; }

.obs textarea { min-height: 76px; }
.obs-cont { justify-self: end; font: 500 11.5px/1 var(--font-mono); color: var(--text-3); }

@media (min-width: 720px) {
  .ficha {
    left: 50%; top: 50%; right: auto; bottom: auto;
    width: min(940px, calc(100vw - 48px)); height: min(640px, calc(100vh - 64px)); max-height: none;
    border-radius: var(--r-l); padding-left: 44%;
    transform: translate(-50%, -47%) scale(.98); opacity: 0;
    transition: transform .3s var(--ease), opacity .22s var(--ease), visibility 0s linear .3s;
  }
  .ficha.on { transform: translate(-50%, -50%); opacity: 1; transition: transform .38s var(--ease), opacity .25s var(--ease), visibility 0s; }
  .ficha-produto .ficha-foto { position: absolute; left: 0; top: 0; bottom: 0; width: 44%; aspect-ratio: auto; }
  .ficha-produto .ficha-foto.sem { background: radial-gradient(120% 90% at 30% 20%, var(--accent-soft), transparent 70%), var(--bg-3); height: auto; }
  .ficha-topo { right: 14px; top: 14px; }
  .ficha-corpo { padding: 26px 26px 22px; }
  .ficha-nome { font-size: 24px; }
  .ficha-pe { padding: 14px 20px; }
  .ficha-demo { padding-left: 0; width: min(560px, calc(100vw - 48px)); height: auto; max-height: calc(100vh - 64px); }
}

/* Apresentação comercial da Future (pílula "Modelo Future"). */
.demo-corpo { padding: 26px 20px 24px; display: grid; gap: 16px; }
.demo-kicker { display: inline-flex; align-items: center; gap: 10px; font: 500 12px/1 var(--font-mono); letter-spacing: .14em; text-transform: uppercase; color: var(--text-2); }
.demo-kicker .marca-future { width: 30px; height: 22px; }
.demo-corpo h2 { font-size: 21px; line-height: 1.25; font-weight: 600; }
.demo-corpo > p { color: var(--text-2); font-size: 15px; }
.demo-modelos { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 10px; }
.demo-modelo {
  position: relative; display: grid; text-align: left; border-radius: 12px; overflow: hidden;
  border: 1px solid var(--line-2); background: var(--bg-3); transition: border-color .2s var(--ease), transform .2s var(--ease);
}
.demo-modelo:hover { border-color: var(--text-3); transform: translateY(-2px); }
.demo-modelo img { width: 100%; height: auto; aspect-ratio: 16 / 9; object-fit: cover; }
.demo-modelo span { padding: 8px 10px 10px; display: grid; gap: 2px; }
.demo-modelo b { font-size: 14px; }
.demo-modelo small { font-size: 12px; color: var(--text-3); }
.demo-modelo[aria-current="true"] { border-color: var(--accent); box-shadow: 0 0 0 1px var(--accent); }
.demo-modelo[aria-current="true"] small { color: var(--accent-text); }
.demo-acoes { display: grid; gap: 10px; }
.demo-fechar { position: absolute; top: 10px; right: 10px; }

/* Aviso rápido: no celular aparece no topo, longe da barra do pedido e do botão do WhatsApp. */
@media (max-width: 719.98px) {
  .toast { top: calc(70px + env(safe-area-inset-top)); bottom: auto; transform: translate(-50%, -12px); }
  .toast.on { transform: translate(-50%, 0); }
}
#pedido-tit:focus { outline: none; }

/* O voo da foto até o pedido. */
.voo { position: fixed; z-index: 95; width: 56px; height: 56px; pointer-events: none; }
.voo img { width: 100%; height: 100%; object-fit: cover; border-radius: 12px; box-shadow: 0 10px 26px rgba(0,0,0,.4); }

.sem-js { padding: 40px 20px; text-align: center; }
.sem-foto { opacity: 0; }

/* Telas baixas: menos capa. */
@media (max-height: 560px) and (orientation: landscape) { .capa { height: 150px; } }
