/* Identidade visual: luxo minimalista em preto absoluto, branco puro e cinza-claro */
:root {
  --cor-marca: #000000;
  --cor-marca-clara: #f2f2f2;
  --cor-fundo: #ffffff;
  --cor-cartao: #ffffff;
  --cor-texto: #000000;
  --cor-texto-suave: rgba(0, 0, 0, .58);
  --cor-borda: #e6e6e6;
  --cor-promo: #000000;
  --cor-whatsapp: #000000;
  --raio: 2px;
  --largura: 560px;
  --serifa: "Cormorant Garamond", Georgia, "Times New Roman", serif;
}

* { box-sizing: border-box; }

html { -webkit-text-size-adjust: 100%; }

body {
  margin: 0;
  background: var(--cor-fundo);
  color: var(--cor-texto);
  font: 16px/1.4 system-ui, -apple-system, "Segoe UI", Roboto, sans-serif;
}

a { color: inherit; }

button { font: inherit; }

img { display: block; max-width: 100%; }

/* --- topo --- */
.topo {
  position: sticky;
  top: 0;
  z-index: 10;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  padding: 10px 16px;
  padding-top: max(10px, env(safe-area-inset-top));
  background: var(--cor-marca);
  color: #fff;
}

.marca { text-decoration: none; min-width: 0; }
.marca strong { display: block; font-size: 1.15rem; letter-spacing: .2px; }
.marca small { display: block; font-size: .78rem; opacity: .85; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }

.acoes-topo { display: flex; gap: 4px; flex: none; }

.icone {
  position: relative;
  display: grid;
  place-items: center;
  width: 44px;
  height: 44px;
  border-radius: 50%;
}
.icone svg { width: 24px; height: 24px; fill: none; stroke: #fff; stroke-width: 2; stroke-linecap: round; stroke-linejoin: round; }

.contador {
  position: absolute;
  top: 3px;
  right: 1px;
  min-width: 19px;
  height: 19px;
  padding: 0 5px;
  border-radius: 10px;
  background: var(--cor-promo);
  color: #3a2a00;
  font-size: .72rem;
  font-weight: 700;
  line-height: 19px;
  text-align: center;
}

main {
  max-width: var(--largura);
  margin: 0 auto;
  padding: 14px 16px 40px;
}

.aviso-carregando, .vazio { color: var(--cor-texto-suave); text-align: center; padding: 40px 0; }

.rotulo-secao {
  margin: 18px 0 8px;
  color: var(--cor-marca);
  font-size: .78rem;
  font-weight: 700;
  letter-spacing: .6px;
  text-transform: uppercase;
}

/* --- faixa de tipos --- */
.chips {
  display: flex;
  gap: 8px;
  margin: 0 -16px;
  padding: 2px 16px 4px;
  overflow-x: auto;
  scrollbar-width: none;
}
.chips::-webkit-scrollbar { display: none; }

.chip {
  flex: none;
  padding: 7px 14px;
  border: 1px solid #c9a3ae;
  border-radius: 999px;
  background: #fff;
  color: var(--cor-texto);
  font-size: .88rem;
  text-decoration: none;
  white-space: nowrap;
  cursor: pointer;
}
.chip[aria-current="true"] { background: var(--cor-marca); border-color: var(--cor-marca); color: #fff; }

/* --- vitrines --- */
.grade-vitrines {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 10px;
}

.cartao-vitrine {
  display: block;
  min-height: 108px;
  padding: 14px 12px;
  border-radius: var(--raio);
  background: var(--cor-marca-clara);
  text-decoration: none;
}
.cartao-vitrine b { display: block; font-size: 1rem; line-height: 1.2; }
.cartao-vitrine span { display: block; margin-top: 6px; color: var(--cor-texto-suave); font-size: .84rem; line-height: 1.3; }

.cabecalho-pagina { margin: 4px 0 12px; }
.cabecalho-pagina h1 { margin: 0; font-size: 1.3rem; line-height: 1.2; }
.cabecalho-pagina p { margin: 4px 0 0; color: var(--cor-texto-suave); }

.voltar {
  display: inline-flex;
  align-items: center;
  min-height: 44px;
  color: var(--cor-marca);
  font-weight: 600;
  text-decoration: none;
}

/* --- produtos --- */
.grade-produtos {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 10px;
  margin-top: 12px;
}

.cartao-produto {
  position: relative;
  display: block;
  overflow: hidden;
  border: 1px solid var(--cor-borda);
  border-radius: var(--raio);
  background: var(--cor-cartao);
  text-decoration: none;
}
.cartao-produto img { width: 100%; aspect-ratio: 1; object-fit: cover; background: var(--cor-marca-clara); }
.cartao-produto .info { padding: 8px 10px 10px; font-size: .9rem; line-height: 1.25; }
.cartao-produto .nome { display: -webkit-box; -webkit-line-clamp: 2; -webkit-box-orient: vertical; overflow: hidden; }
.cartao-produto .oferta { margin-top: 3px; color: var(--cor-texto-suave); font-size: .8rem; }

.preco { margin-top: 4px; font-weight: 700; color: var(--cor-marca); }
.preco del { margin-right: 4px; color: #9b8a87; font-weight: 400; font-size: .85em; }

.selo {
  position: absolute;
  top: 8px;
  left: 8px;
  padding: 2px 7px;
  border-radius: 6px;
  background: var(--cor-promo);
  color: #3a2a00;
  font-size: .72rem;
  font-weight: 800;
  letter-spacing: .4px;
}

.esgotado img, .esgotado .info { opacity: .45; }
.esgotado::after {
  content: "Esgotado";
  position: absolute;
  top: 38%;
  left: 50%;
  transform: translate(-50%, -50%);
  padding: 4px 10px;
  border-radius: 6px;
  background: rgba(255, 255, 255, .92);
  color: var(--cor-marca);
  font-weight: 800;
  font-size: .85rem;
}

/* --- página do produto --- */
.foto-grande { width: 100%; aspect-ratio: 1; object-fit: cover; border-radius: var(--raio); background: var(--cor-marca-clara); }
.detalhe h1 { margin: 14px 0 4px; font-size: 1.35rem; line-height: 1.25; }
.detalhe .preco { font-size: 1.35rem; }
.detalhe .oferta { color: var(--cor-texto-suave); }
.detalhe .descricao { margin: 10px 0 0; color: var(--cor-texto-suave); }

.pilulas { display: flex; flex-wrap: wrap; gap: 6px; margin-top: 12px; }
.pilula { padding: 4px 10px; border-radius: 999px; background: var(--cor-marca-clara); font-size: .82rem; text-decoration: none; }

.botao {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  width: 100%;
  min-height: 52px;
  margin-top: 16px;
  padding: 12px 16px;
  border: 0;
  border-radius: var(--raio);
  background: var(--cor-marca);
  color: #fff;
  font-weight: 700;
  font-size: 1.02rem;
  text-align: center;
  text-decoration: none;
  cursor: pointer;
}
.botao.whatsapp { background: var(--cor-whatsapp); }
.botao[aria-disabled="true"], .botao:disabled { background: #c9bdbb; pointer-events: none; }
.botao.secundario { background: transparent; color: var(--cor-marca); border: 1px solid var(--cor-marca); min-height: 44px; }

.nota { margin: 10px 0 0; color: var(--cor-texto-suave); font-size: .85rem; text-align: center; }

/* --- sacola --- */
.item-sacola {
  display: flex;
  align-items: center;
  gap: 10px;
  padding: 10px 0;
  border-bottom: 1px solid var(--cor-borda);
}
.item-sacola img { width: 56px; height: 56px; flex: none; border-radius: 8px; object-fit: cover; background: var(--cor-marca-clara); }
.item-sacola .texto { flex: 1; min-width: 0; font-size: .92rem; }
.item-sacola .texto a { text-decoration: none; }
.item-sacola.indisponivel .texto { color: #9b8a87; text-decoration: line-through; }
.item-sacola .motivo { color: var(--cor-marca); font-size: .8rem; text-decoration: none; display: block; }

.quantidade { display: flex; align-items: center; gap: 2px; flex: none; }
.quantidade button, .remover {
  width: 36px;
  height: 36px;
  border: 1px solid #c9a3ae;
  border-radius: 8px;
  background: #fff;
  color: var(--cor-texto);
  font-size: 1.1rem;
  cursor: pointer;
}
.quantidade span { min-width: 26px; text-align: center; font-weight: 600; }

.total { display: flex; justify-content: space-between; margin-top: 14px; font-size: 1.1rem; font-weight: 700; }
.aviso-total { margin: 6px 0 0; color: var(--cor-texto-suave); font-size: .85rem; }

/* --- busca --- */
.campo-busca {
  width: 100%;
  min-height: 48px;
  padding: 10px 14px;
  border: 1px solid #c9a3ae;
  border-radius: 999px;
  background: #fff;
  font: inherit;
}

.erro-carga { text-align: center; padding: 40px 0; }

/* --- aviso flutuante --- */
.toast {
  position: fixed;
  left: 50%;
  bottom: max(20px, env(safe-area-inset-bottom));
  transform: translateX(-50%);
  width: min(92vw, 420px);
  padding: 12px 16px;
  border-radius: var(--raio);
  background: #2b2220;
  color: #fff;
  text-align: center;
  box-shadow: 0 6px 24px rgba(0, 0, 0, .2);
}
.toast a { color: #ffd98a; font-weight: 700; margin-left: 6px; }

:focus-visible { outline: 3px solid #e8b04b; outline-offset: 2px; }

/* --- identidade luxo minimalista: tipografia e acabamentos --- */
body { font-family: "Inter", system-ui, -apple-system, "Segoe UI", sans-serif; font-weight: 400; letter-spacing: .1px; }

.topo { background: #fff; color: #000; border-bottom: 1px solid var(--cor-borda); padding-top: 14px; padding-bottom: 14px; }
.marca strong { font-family: var(--serifa); font-weight: 500; font-size: 1.12rem; letter-spacing: .26em; text-transform: uppercase; white-space: nowrap; }
.marca small { font-size: .58rem; letter-spacing: .14em; text-transform: uppercase; opacity: 1; color: var(--cor-texto-suave); margin-top: 2px; }
.icone svg { stroke: #000; stroke-width: 1.5; }
.contador { background: #000; color: #fff; }

.rotulo-secao { color: #000; font-weight: 500; font-size: .7rem; letter-spacing: .28em; margin: 26px 0 14px; }

.chip { border: 1px solid #000; border-radius: 0; background: #fff; color: #000; font-size: .72rem; letter-spacing: .16em; text-transform: uppercase; padding: 9px 16px; }
.chip[aria-current="true"] { background: #000; color: #fff; border-color: #000; }

.grade-vitrines { gap: 12px; }
.cartao-vitrine { background: #fff; border: 1px solid var(--cor-borda); border-radius: 0; padding: 20px 16px; min-height: 124px; transition: border-color .2s; }
.cartao-vitrine:hover { border-color: #000; }
.cartao-vitrine b { font-family: var(--serifa); font-weight: 500; font-size: 1.28rem; line-height: 1.12; }
.cartao-vitrine span { font-size: .78rem; line-height: 1.45; margin-top: 8px; }

.cabecalho-pagina h1 { font-family: var(--serifa); font-weight: 500; font-size: 1.85rem; letter-spacing: .01em; }
.cabecalho-pagina p { font-size: .86rem; }
.voltar { color: #000; font-weight: 400; font-size: .72rem; letter-spacing: .2em; text-transform: uppercase; }

.grade-produtos { gap: 14px 12px; }
.cartao-produto { border: 0; border-radius: 0; background: #fff; }
.cartao-produto img { background: #fff; border: 1px solid var(--cor-marca-clara); }
.cartao-produto .info { padding: 10px 2px 4px; }
.cartao-produto .nome { font-size: .84rem; line-height: 1.35; }
.cartao-produto .oferta { font-size: .72rem; }
.preco { color: #000; font-weight: 600; letter-spacing: .02em; margin-top: 6px; }
.preco del { color: rgba(0, 0, 0, .4); }
.selo { background: #000; color: #fff; border-radius: 0; font-size: .6rem; letter-spacing: .2em; font-weight: 500; padding: 4px 8px; top: 10px; left: 10px; }
.esgotado::after { background: #fff; color: #000; border: 1px solid #000; border-radius: 0; font-size: .66rem; letter-spacing: .2em; text-transform: uppercase; font-weight: 500; }

.foto-grande { border-radius: 0; background: #fff; border: 1px solid var(--cor-marca-clara); }
.detalhe h1 { font-family: var(--serifa); font-weight: 500; font-size: 1.75rem; }
.detalhe .preco { font-size: 1.2rem; }
.pilula { background: var(--cor-marca-clara); border-radius: 0; font-size: .68rem; letter-spacing: .14em; text-transform: uppercase; padding: 6px 10px; }

.botao { border-radius: 0; background: #000; font-weight: 500; font-size: .78rem; letter-spacing: .22em; text-transform: uppercase; min-height: 54px; }
.botao.whatsapp { background: #000; }
.botao.whatsapp::before { content: ""; width: 18px; height: 18px; background: no-repeat center/contain url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='white'%3E%3Cpath d='M12 2a10 10 0 0 0-8.6 15.1L2 22l5-1.3A10 10 0 1 0 12 2zm0 18.2a8.2 8.2 0 0 1-4.2-1.2l-.3-.2-3 .8.8-2.9-.2-.3A8.2 8.2 0 1 1 12 20.2zm4.5-6.1c-.2-.1-1.5-.7-1.7-.8s-.4-.1-.6.1-.7.8-.8 1-.3.2-.5.1a6.7 6.7 0 0 1-3.3-2.9c-.3-.4.3-.4.7-1.4a.5.5 0 0 0 0-.4l-.8-1.8c-.2-.5-.4-.4-.6-.4h-.5a1 1 0 0 0-.7.3 3 3 0 0 0-.9 2.2 5.2 5.2 0 0 0 1.1 2.7 11.8 11.8 0 0 0 4.5 4c1.7.7 2.3.8 3.1.7a2.7 2.7 0 0 0 1.8-1.3 2.2 2.2 0 0 0 .1-1.3c-.1-.1-.3-.2-.5-.3z'/%3E%3C/svg%3E"); }
.botao[aria-disabled="true"], .botao:disabled { background: #bdbdbd; }
.botao.secundario { background: #fff; color: #000; border: 1px solid #000; }

.item-sacola { border-bottom-color: var(--cor-borda); }
.item-sacola img { border-radius: 0; background: #fff; border: 1px solid var(--cor-marca-clara); }
.quantidade button, .remover { border: 1px solid #000; border-radius: 0; background: #fff; }
.total { font-family: var(--serifa); font-weight: 600; font-size: 1.3rem; }
.campo-busca { border: 1px solid #000; border-radius: 0; }
.toast { background: #000; border-radius: 0; font-size: .82rem; letter-spacing: .04em; }
.toast a { color: #fff; text-decoration: underline; }
:focus-visible { outline: 2px solid #000; outline-offset: 2px; }
