/* Vitrine Deliza — perfil do restaurante (/r/:slug). Marca v3, tema claro: goiaba neon sobre branco, Sora + Manrope.
   Sacola flutuante e sheets seguem o mesmo vocabulário do feed.css (classes montadas pelo vitrine-comum). */
:root {
  --branco: #FFFFFF; --nevoa: #FFF0F4; --goiaba-claro: #FFD6E0; --goiaba-suave: #FF8FB1;
  --goiaba: #FF2E63; --goiaba-forte: #FF1744; --tinta: #241A1B; --tinta-suave: #8C7A7C;
  --ok: #2E9E5B; --erro: #A51C30;
  --brilho: 0 0 18px rgba(255, 46, 99, .45), 0 0 46px rgba(255, 23, 68, .22);
  --r-pires: 14px; --r-pill: 999px;
  --desliza: cubic-bezier(.22, 1, .36, 1); --babei: cubic-bezier(.34, 1.56, .64, 1);
  --display: 'Sora', system-ui, sans-serif; --texto: 'Manrope', system-ui, sans-serif;
  --linha: #F3E3E7; --fundo: #FCF8F9;
  --topo-seg: env(safe-area-inset-top, 0px); --pe-seg: env(safe-area-inset-bottom, 0px);
  /* coluna da página: tela cheia no celular, 680px centrada no desktop */
  --coluna: 680px;
  --lado: max(0px, calc((100vw - var(--coluna)) / 2));
}

* { box-sizing: border-box; -webkit-tap-highlight-color: transparent; }
html, body { margin: 0; background: var(--fundo); color: var(--tinta); }
body { font: 400 15px/1.45 var(--texto); -webkit-font-smoothing: antialiased; overflow-x: clip; }
h1, h2, h3, h4 { font-family: var(--display); font-weight: 800; margin: 0; letter-spacing: -.03em; }
p { margin: 0; }
a { color: inherit; text-decoration: none; }
button, input, textarea { font: inherit; color: inherit; }
button { cursor: pointer; border: 0; background: none; padding: 0; }
[hidden] { display: none !important; }
.num { font-variant-numeric: tabular-nums; }
svg { flex: none; }
@media (min-width: 720px) {
  body { background:
    radial-gradient(40% 40% at 88% 6%, rgba(255, 143, 177, .3), transparent 70%),
    radial-gradient(40% 50% at 6% 70%, rgba(255, 214, 224, .7), transparent 70%), var(--nevoa); }
}

.perfil { position: relative; max-width: var(--coluna); min-height: 100vh; min-height: 100dvh; margin: 0 auto; background: var(--fundo);
  padding-bottom: calc(28px + var(--pe-seg)); }
body.tem-sacola .perfil { padding-bottom: calc(100px + var(--pe-seg)); }
@media (min-width: 720px) { .perfil { box-shadow: 0 0 0 1px var(--linha), 0 40px 90px -40px rgba(120, 0, 30, .25); } }

/* ---------- barra fixa (aparece ao rolar) ---------- */
.barra { position: fixed; z-index: 15; top: 0; left: var(--lado); right: var(--lado); display: flex; align-items: center; gap: 10px;
  padding: calc(8px + var(--topo-seg)) 12px 8px; background: rgba(252, 248, 249, .92); backdrop-filter: blur(14px); -webkit-backdrop-filter: blur(14px);
  border-bottom: 1px solid var(--linha); transform: translateY(-105%); transition: transform .35s var(--desliza); }
.barra.mostra { transform: translateY(0); }
.barra .av { width: 34px; height: 34px; font-size: 14px; box-shadow: none; border-width: 0; }
.barra b { flex: 1; min-width: 0; font: 700 15px/1.2 var(--display); letter-spacing: -.02em; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.barra .ver { flex: none; display: inline-flex; align-items: center; gap: 6px; height: 36px; padding: 0 14px; border-radius: var(--r-pill);
  background: var(--goiaba-forte); color: #fff; font: 800 13px/1 var(--display); letter-spacing: -.02em; box-shadow: 0 0 14px rgba(255, 46, 99, .4); }
.barra .ver svg { width: 12px; height: 12px; fill: #fff; }

/* ---------- capa + cabeçalho da loja ---------- */
.capa { position: relative; height: 132px; overflow: hidden;
  background: radial-gradient(90% 120% at 80% 0%, #FF6B91, transparent 60%), radial-gradient(80% 120% at 0% 100%, #C2002F, transparent 70%), var(--goiaba-forte); }
.capa img { position: absolute; inset: -20px; width: calc(100% + 40px); height: calc(100% + 40px); object-fit: cover; filter: blur(14px) saturate(1.2); transform: scale(1.05); }
.capa::after { content: ''; position: absolute; inset: 0; background: linear-gradient(rgba(36, 26, 27, .1), rgba(255, 23, 68, .28) 60%, rgba(36, 26, 27, .35)); }
.capa .wm { position: absolute; z-index: 1; right: 14px; top: calc(12px + var(--topo-seg)); font: 800 15px/1 var(--display); letter-spacing: -.05em; color: rgba(255, 255, 255, .9); }
.capa .wm i { font-style: normal; color: #fff; text-shadow: 0 0 10px rgba(255, 255, 255, .8); }
.compartilhar { position: absolute; z-index: 1; left: 12px; top: calc(10px + var(--topo-seg)); width: 38px; height: 38px; border-radius: 50%; display: grid; place-items: center;
  background: rgba(20, 12, 13, .3); backdrop-filter: blur(10px); -webkit-backdrop-filter: blur(10px); }
.compartilhar svg { width: 18px; height: 18px; stroke: #fff; fill: none; stroke-width: 2.2; stroke-linecap: round; stroke-linejoin: round; }

.cabeca { position: relative; padding: 0 16px; margin-top: -48px; text-align: center; }
.av { display: grid; place-items: center; flex: none; border-radius: 50%; overflow: hidden; color: #fff; font: 800 34px/1 var(--display); letter-spacing: -.04em;
  background: linear-gradient(140deg, #FF4A78, var(--goiaba-forte)); }
.av img { width: 100%; height: 100%; object-fit: cover; }
.cabeca .av { position: relative; width: 96px; height: 96px; margin: 0 auto; border: 4px solid var(--fundo); box-shadow: 0 0 0 2px var(--goiaba), var(--brilho); }
.cabeca h1 { margin-top: 12px; font-size: 27px; line-height: 1.1; letter-spacing: -.04em; overflow-wrap: anywhere; }
.cabeca .desc { position: relative; max-width: 440px; margin: 6px auto 0; font-size: 14.5px; font-weight: 500; color: #5E4F51; }
.desc p { display: -webkit-box; -webkit-line-clamp: 2; -webkit-box-orient: vertical; overflow: hidden; }
.desc.aberta p { display: block; }
.desc .mais { position: absolute; right: 0; bottom: 0; padding-left: 28px; font-size: 14.5px; font-weight: 700; color: var(--goiaba-forte);
  background: linear-gradient(90deg, rgba(252, 248, 249, 0), var(--fundo) 26px); }
.selos { display: flex; flex-wrap: wrap; justify-content: center; gap: 6px; margin-top: 12px; }
.status, .mesa-tag { display: inline-flex; align-items: center; gap: 6px; height: 28px; padding: 0 12px; border-radius: var(--r-pill); font-size: 12.5px; font-weight: 700; }
.status { background: rgba(46, 158, 91, .1); color: #1F7A45; }
.status::before { content: ''; width: 7px; height: 7px; border-radius: 50%; background: #2FBF6A; box-shadow: 0 0 6px #4ADE80; }
.status.pausado { background: #FFF5E0; color: #9A6200; }
.status.pausado::before { background: #E6A100; box-shadow: none; }
.status.fechado { background: #F3EAEC; color: var(--tinta-suave); }
.status.fechado::before { background: #B9A7AA; box-shadow: none; }
.mesa-tag { background: var(--tinta); color: #fff; }

/* números da loja: uma linha discreta */
.stats { display: flex; justify-content: center; flex-wrap: wrap; gap: 0 2px; margin: 8px 16px 0; font-size: 13px; font-weight: 600; color: var(--tinta-suave); }
.stats b { font-weight: 800; color: var(--tinta); }
.stats i { font-style: normal; margin: 0 6px; color: #D3C3C6; }

/* ---------- pedido pelo link: pílulas compactas ---------- */
.acoes { display: flex; justify-content: center; flex-wrap: wrap; gap: 8px; margin: 12px 16px 0; }
.canal { display: inline-flex; align-items: center; gap: 7px; height: 38px; padding: 0 15px 0 12px; border-radius: var(--r-pill); background: #fff; border: 1.5px solid var(--linha);
  font-size: 13.5px; transition: border-color .2s, transform .2s var(--babei); }
.canal:active { transform: scale(.96); }
.canal:hover { border-color: var(--goiaba-claro); }
.canal svg { width: 18px; height: 18px; stroke: var(--goiaba-forte); fill: none; stroke-width: 2; stroke-linecap: round; stroke-linejoin: round; }
.canal b { font: 700 13.5px/1 var(--display); letter-spacing: -.02em; }
.canal small { font-size: 13px; font-weight: 700; color: var(--tinta-suave); }
.aviso-loja { padding: 8px 14px; border-radius: var(--r-pill); background: #F3EAEC; color: #5E4F51; font-size: 12.5px; font-weight: 600; text-align: center; }

/* ---------- chips de categoria ---------- */
.chips { position: sticky; z-index: 10; top: 0; display: flex; gap: 6px; margin-top: 14px; padding: 10px 16px; overflow-x: auto; scrollbar-width: none;
  background: rgba(252, 248, 249, .92); backdrop-filter: blur(14px); -webkit-backdrop-filter: blur(14px); transition: top .35s var(--desliza); }
.chips::-webkit-scrollbar { display: none; }
body.barra-on .chips { top: calc(51px + var(--topo-seg)); border-bottom: 1px solid var(--linha); }
.chip { flex: none; display: inline-flex; align-items: center; gap: 6px; height: 36px; padding: 0 14px; border-radius: var(--r-pill); background: #fff; border: 1.5px solid var(--linha);
  font-size: 13.5px; font-weight: 700; color: #5E4F51; transition: background .2s, color .2s, border-color .2s; }
.chip em { font-style: normal; font-size: 11.5px; font-weight: 800; color: #C2B1B4; }
.chip.ativa { background: var(--tinta); border-color: var(--tinta); color: #fff; }
.chip.ativa em { color: var(--goiaba-suave); }

/* ---------- grade de pratos ---------- */
.secao { padding: 0 16px; }
.secao h2 { display: flex; align-items: baseline; gap: 8px; margin: 18px 0 10px; font-size: 19px; letter-spacing: -.035em; }
.secao h2 small { font: 700 12px/1 var(--texto); letter-spacing: 0; color: var(--tinta-suave); }
.grade { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 10px; }
@media (min-width: 560px) { .grade { grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 12px; } }
.card { position: relative; display: block; aspect-ratio: 3 / 4; border-radius: 20px; overflow: hidden; isolation: isolate;
  background: radial-gradient(120% 70% at 50% 38%, #5A2618, #1B0C08 75%); color: #fff; box-shadow: 0 10px 24px -16px rgba(36, 26, 27, .6);
  transition: transform .25s var(--babei); }
.card:active { transform: scale(.97); }
.card img, .card video { position: absolute; inset: 0; z-index: -1; width: 100%; height: 100%; object-fit: cover; }
@media (hover: hover) { .card img { transition: transform .5s var(--desliza); } .card:hover img { transform: scale(1.05); } }
.card::after { content: ''; position: absolute; inset: 0; z-index: -1; background: linear-gradient(rgba(0, 0, 0, .3), transparent 26%, transparent 46%, rgba(0, 0, 0, .82)); }
.card .vazia { position: absolute; inset: 0; z-index: -1; display: grid; place-items: center; font: 800 30px/1 var(--display); letter-spacing: -.05em; color: rgba(255, 255, 255, .16); }
.card .vazia i { font-style: normal; color: rgba(255, 46, 99, .45); }
.card .likes { position: absolute; top: 9px; left: 9px; display: inline-flex; align-items: center; gap: 4px; height: 24px; padding: 0 8px; border-radius: var(--r-pill);
  background: rgba(20, 12, 13, .38); backdrop-filter: blur(8px); -webkit-backdrop-filter: blur(8px); font-size: 11.5px; font-weight: 800; }
.card .likes svg { width: 13px; height: 13px; fill: var(--goiaba); filter: drop-shadow(0 0 4px rgba(255, 46, 99, .8)); }
.card .tocar { position: absolute; top: 9px; right: 9px; width: 26px; height: 26px; border-radius: 50%; display: grid; place-items: center;
  background: rgba(20, 12, 13, .38); backdrop-filter: blur(8px); -webkit-backdrop-filter: blur(8px); }
.card .tocar svg { width: 11px; height: 11px; fill: #fff; margin-left: 2px; }
.card .quente { position: absolute; top: 40px; left: 9px; height: 22px; padding: 0 8px; border-radius: var(--r-pill); display: inline-flex; align-items: center;
  background: var(--goiaba-forte); box-shadow: 0 0 12px rgba(255, 46, 99, .55); font-size: 11px; font-weight: 800; }
.card .info { position: absolute; left: 11px; right: 11px; bottom: 11px; }
.card h3 { font-size: 15px; line-height: 1.15; letter-spacing: -.025em; text-shadow: 0 1px 8px rgba(0, 0, 0, .4);
  display: -webkit-box; -webkit-line-clamp: 2; -webkit-box-orient: vertical; overflow: hidden; }
.card .linha { display: flex; align-items: center; justify-content: space-between; gap: 6px; margin-top: 8px; }
.card .preco { display: inline-flex; align-items: center; height: 28px; padding: 0 10px; border-radius: var(--r-pill); background: #fff; color: var(--tinta);
  font: 800 13.5px/1 var(--display); letter-spacing: -.03em; white-space: nowrap; }
.card .add { width: 32px; height: 32px; flex: none; border-radius: 50%; display: grid; place-items: center; background: var(--goiaba-forte); box-shadow: 0 0 14px rgba(255, 46, 99, .55);
  transition: transform .25s var(--babei); }
.card .add:active { transform: scale(.85); }
.card .add svg { width: 16px; height: 16px; stroke: #fff; fill: none; stroke-width: 3; stroke-linecap: round; }
.card .add.pulo { animation: bate .5s var(--babei); }
@keyframes bate { 40% { transform: scale(1.3); } }

.vazio { padding: 40px 16px; text-align: center; color: var(--tinta-suave); font-weight: 600; }
.vazio h2 { color: var(--tinta); font-size: 19px; margin-bottom: 6px; }
.erro-carga { padding: 30vh 24px 0; text-align: center; }
.erro-carga h2 { font-size: 21px; }
.erro-carga p { margin-top: 6px; color: var(--tinta-suave); font-weight: 600; }
.erro-carga button { margin-top: 18px; height: 48px; padding: 0 22px; border-radius: var(--r-pill); background: var(--goiaba-forte); color: #fff; font: 800 15px/1 var(--display); box-shadow: var(--brilho); }

/* esqueleto enquanto carrega (sem animação de opacidade: WebView congelada mostraria vazio) */
.esq { background: linear-gradient(90deg, #F3E7EA, #FBF1F3, #F3E7EA); background-size: 200% 100%; animation: brilha 1.4s linear infinite; }
@keyframes brilha { to { background-position: -200% 0; } }
.esq-nome { width: 180px; height: 26px; margin: 14px auto 0; border-radius: 10px; }
.esq-card { aspect-ratio: 3 / 4; border-radius: 20px; }

/* ---------- rodapé ---------- */
.rodape { margin-top: 34px; padding: 0 16px; text-align: center; }
.rodape a { display: inline-flex; align-items: center; gap: 6px; height: 38px; padding: 0 16px; border-radius: var(--r-pill); background: #fff; border: 1px solid var(--linha);
  font-size: 12.5px; font-weight: 600; color: var(--tinta-suave); }
.rodape b { font: 800 15px/1 var(--display); letter-spacing: -.05em; color: var(--tinta); }
.rodape b i { font-style: normal; color: var(--goiaba-forte); }

/* ---------- sacola flutuante (vitrine-comum monta o botão) ---------- */
.sacola-fab { position: fixed; z-index: 12; left: calc(var(--lado) + 10px); right: calc(var(--lado) + 10px); bottom: calc(10px + var(--pe-seg));
  display: flex; align-items: center; gap: 12px; height: 62px; padding: 0 7px 0 8px; border-radius: var(--r-pill); background: var(--tinta); color: #fff; text-align: left;
  box-shadow: 0 18px 44px -12px rgba(36, 26, 27, .6); transform: translateY(140%); transition: transform .5s var(--desliza); }
@media (min-width: 720px) { .sacola-fab { left: calc(var(--lado) + 120px); right: calc(var(--lado) + 120px); } }
.sacola-fab.mostra { transform: translateY(0); }
.sacola-fab .saco { position: relative; width: 46px; height: 46px; flex: none; border-radius: 50%; background: rgba(255, 255, 255, .1); display: grid; place-items: center; }
.sacola-fab .saco svg { width: 22px; height: 22px; stroke: #fff; fill: none; stroke-width: 2; stroke-linecap: round; stroke-linejoin: round; }
.sacola-fab .qtd { position: absolute; top: -3px; right: -3px; min-width: 21px; height: 21px; padding: 0 5px; border-radius: 11px; background: var(--goiaba-forte); color: #fff;
  border: 2px solid var(--tinta); font-size: 11.5px; font-weight: 800; display: grid; place-items: center; }
.sacola-fab.pulo .saco { animation: bate .5s var(--babei); }
.sacola-fab .rotulo { min-width: 0; }
.sacola-fab .rotulo b { display: block; font: 700 14.5px/1.2 var(--display); letter-spacing: -.02em; }
.sacola-fab .rotulo small { display: block; font-size: 12px; font-weight: 600; color: rgba(255, 255, 255, .65); white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.sacola-fab .ir { margin-left: auto; flex: none; display: inline-flex; align-items: center; gap: 8px; height: 48px; padding: 0 8px 0 16px; border-radius: var(--r-pill);
  background: var(--goiaba-forte); color: #fff; font: 800 15px/1 var(--display); letter-spacing: -.02em; box-shadow: 0 0 16px rgba(255, 46, 99, .45); }
.sacola-fab .ir > span { width: 32px; height: 32px; border-radius: 50%; background: rgba(255, 255, 255, .2); display: grid; place-items: center; }
.sacola-fab .ir svg { width: 16px; height: 16px; stroke: #fff; fill: none; stroke-width: 2.6; stroke-linecap: round; stroke-linejoin: round; }

/* ---------- sheets (vitrine-comum: .sheet .sheet-cab .sheet-corpo .sheet-pe + .fundo) ---------- */
.fundo { position: fixed; inset: 0; z-index: 20; background: rgba(36, 26, 27, .45); opacity: 0; pointer-events: none; transition: opacity .3s; }
.fundo.aberto { opacity: 1; pointer-events: auto; }
.sheet { position: fixed; z-index: 21; left: max(0px, calc((100vw - 520px) / 2)); right: max(0px, calc((100vw - 520px) / 2)); bottom: 0; max-height: 88%;
  display: flex; flex-direction: column; background: #fff; color: var(--tinta); border-radius: 28px 28px 0 0; transform: translateY(105%); transition: transform .45s var(--desliza); }
.sheet.aberto { transform: translateY(0); }
.sheet::before { content: ''; position: absolute; left: 50%; top: 8px; width: 40px; height: 5px; margin-left: -20px; border-radius: 5px; background: var(--linha); }
.sheet-cab { display: flex; align-items: center; gap: 10px; padding: 22px 16px 4px; }
.sheet-cab h3 { flex: 1; min-width: 0; font-size: 19px; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.sheet-cab .fechar { flex: none; width: 34px; height: 34px; border-radius: 50%; background: var(--nevoa); color: var(--goiaba-forte); font-size: 14px; font-weight: 800; }
.sheet-corpo { flex: 1; overflow-y: auto; padding: 8px 16px; scrollbar-width: none; }
.sheet-pe { padding: 8px 16px calc(16px + var(--pe-seg)); }
.sheet-pe:empty { display: none; }
.sheet .vazio { padding: 28px 8px; }
.sheet .btn { display: flex; align-items: center; justify-content: center; gap: 10px; width: 100%; height: 54px; padding: 0 22px; border-radius: var(--r-pill);
  background: var(--goiaba-forte); color: #fff; font: 800 16px/1 var(--display); letter-spacing: -.02em; box-shadow: var(--brilho); transition: transform .2s; }
.sheet .btn:active { transform: scale(.98); }
.sheet .btn[disabled] { background: #F1E4E7; color: var(--tinta-suave); box-shadow: none; cursor: not-allowed; }
.sheet .campo { width: 100%; height: 46px; padding: 0 13px; border: 1.5px solid var(--linha); border-radius: var(--r-pires); background: #fff;
  font-size: 15px; font-weight: 500; color: var(--tinta); outline: none; }
.sheet .campo:focus { border-color: var(--goiaba); box-shadow: 0 0 0 4px rgba(255, 46, 99, .14); }
.sac-item { display: grid; grid-template-columns: 1fr auto; gap: 8px 12px; align-items: center; padding: 12px 0; border-bottom: 1px solid var(--linha); }
.sac-item h4 { font: 700 15px/1.25 var(--display); letter-spacing: -.015em; }
.sac-item .sub { font-size: 13px; font-weight: 600; color: var(--tinta-suave); }
.qtd-ctrl { display: inline-flex; align-items: center; height: 38px; border-radius: var(--r-pill); border: 1.5px solid var(--linha); }
.qtd-ctrl button { width: 38px; height: 38px; border-radius: 50%; display: grid; place-items: center; color: var(--goiaba-forte); font-size: 20px; font-weight: 700; line-height: 1; }
.qtd-ctrl b { min-width: 28px; text-align: center; font: 800 17px/1 var(--display); }
.sac-item .campo { grid-column: 1 / -1; height: 40px; font-size: 14px; }
.sac-total { display: flex; justify-content: space-between; align-items: baseline; margin-bottom: 10px; font-weight: 600; color: var(--tinta-suave); }
.sac-total span:last-child { font: 800 21px/1 var(--display); letter-spacing: -.03em; color: var(--tinta); }
.sac-aviso { margin-bottom: 10px; padding: 10px 12px; border-radius: 12px; background: var(--nevoa); color: var(--goiaba-forte); font-size: 13px; font-weight: 700; text-align: center; }

/* toast */
.toast { position: fixed; z-index: 40; left: 50%; bottom: calc(24px + var(--pe-seg)); transform: translate(-50%, 12px); opacity: 0; display: flex; align-items: center; gap: 9px;
  padding: 10px 15px; border-radius: var(--r-pill); background: var(--tinta); color: #fff; font-size: 13.5px; font-weight: 700; max-width: calc(100vw - 32px); text-align: center;
  box-shadow: 0 16px 36px -12px rgba(36, 26, 27, .6); pointer-events: none; transition: opacity .25s, transform .4s var(--desliza); }
.toast.mostra { opacity: 1; transform: translate(-50%, 0); }
.toast.erro { background: var(--erro); }
body.tem-sacola .toast { bottom: calc(84px + var(--pe-seg)); }

/* navegador que congela transição/animação (o perfil.js detecta): tudo muda na hora */
.sem-anim *, .sem-anim *::before, .sem-anim *::after { transition: none !important; animation: none !important; }

@media (prefers-reduced-motion: reduce) { *, *::before, *::after { animation-duration: .01ms !important; transition-duration: .01ms !important; } }
