:root {
  --azul: #0d2b4e;
  --azul-medio: #1a4a7a;
  --azul-claro: #e8f0f9;
  --branco: #ffffff;
  --cinza-borda: #d0dce8;
  --cinza-texto: #555;
  --sombra: 0 4px 20px rgba(13, 43, 78, 0.12);
  --radius: 12px;
}

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

body {
  font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif;
  background: var(--branco);
  color: #1a1a2e;
  min-height: 100vh;
}

/* ── Header ── */
header {
  background: var(--azul);
  padding: 0 2rem;
  height: 56px;
  display: flex;
  align-items: center;
  gap: 1rem;
  position: sticky;
  top: 0;
  z-index: 100;
  box-shadow: 0 2px 8px rgba(0,0,0,0.3);
}

.logo {
  color: var(--branco);
  font-size: 1.4rem;
  font-weight: 800;
  letter-spacing: -0.5px;
  text-decoration: none;
  flex-shrink: 0;
}

.logo span { color: #5ba3f5; }
.logo .beta-badge {
  color: var(--azul);
  background: #5ba3f5;
  font-size: 0.6rem;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.5px;
  padding: 1px 6px;
  border-radius: 999px;
  margin-left: 6px;
  vertical-align: super;
}

/* ── Search bar no header ── */
.header-search { display: none; flex: 1; max-width: 560px; }
.header-search.visible { display: flex; }

/* ── Hero ── */
.hero {
  display: flex;
  flex-direction: column;
  align-items: center;
  padding: 5rem 1rem 3rem;
  text-align: center;
  transition: padding 0.3s;
}

.hero.compact { padding: 2rem 1rem 1.5rem; }

.hero h1 {
  font-size: 2.2rem;
  font-weight: 800;
  color: var(--azul);
  margin-bottom: 0.4rem;
  line-height: 1.2;
}

.hero h1 span { color: #5ba3f5; }

.hero p {
  color: var(--cinza-texto);
  margin-bottom: 2rem;
  font-size: 1rem;
}

.hero-tagline {
  transition: opacity 0.2s, transform 0.25s;
  transform-origin: top center;
}

.hero-tagline.oculto {
  opacity: 0;
  transform: scaleY(0);
  pointer-events: none;
  height: 0;
  overflow: hidden;
  margin: 0;
}

/* ── Search box ── */
.search-wrap {
  position: relative;
  width: 100%;
  max-width: 620px;
}

.search-wrap input {
  width: 100%;
  padding: 1rem 3.5rem 1rem 1.2rem;
  font-size: 1.05rem;
  border: 2px solid var(--cinza-borda);
  border-radius: 50px;
  outline: none;
  background: var(--branco);
  transition: border-color 0.2s, box-shadow 0.2s;
  box-shadow: var(--sombra);
}

.search-wrap input:focus {
  border-color: var(--azul-medio);
  box-shadow: 0 0 0 4px rgba(26, 74, 122, 0.12), var(--sombra);
}

.search-wrap .icon-search {
  position: absolute;
  right: 1.1rem;
  top: 50%;
  transform: translateY(-50%);
  color: var(--azul-medio);
  pointer-events: none;
  font-size: 1.2rem;
}

.search-wrap .spinner {
  display: none;
  position: absolute;
  right: 1.1rem;
  top: 50%;
  transform: translateY(-50%);
  width: 18px;
  height: 18px;
  border: 2px solid var(--cinza-borda);
  border-top-color: var(--azul-medio);
  border-radius: 50%;
  animation: spin 0.6s linear infinite;
}

@keyframes spin { to { transform: translateY(-50%) rotate(360deg); } }

.search-wrap.sm input {
  padding: 0.55rem 2.8rem 0.55rem 1rem;
  font-size: 0.95rem;
  box-shadow: none;
}
.search-wrap.sm .icon-search { right: 0.8rem; font-size: 1rem; }

/* ── Banners ── */
.banners-section {
  max-width: 900px;
  margin: 0 auto 1.5rem;
  padding: 0 1rem;
}

.banners-viewport {
  overflow: hidden;
  border-radius: var(--radius);
  box-shadow: var(--sombra);
}

.banners-track {
  display: flex;
  transition: transform 0.45s cubic-bezier(0.4, 0, 0.2, 1);
}

.banner-slide {
  flex-shrink: 0;
  width: 100%;
  height: 180px;
  display: flex;
  align-items: center;
  padding: 1.5rem 2rem;
  gap: 1.5rem;
  border-radius: var(--radius);
  overflow: hidden;
  position: relative;
}

.banner-slide.destaque {
  background: linear-gradient(135deg, var(--azul) 0%, #1a4a7a 60%, #2563a8 100%);
  color: var(--branco);
}

.banner-slide.loja-cremer  { background: linear-gradient(135deg, #065f46, #059669); color: #fff; }
.banner-slide.loja-speed   { background: linear-gradient(135deg, #7c2d12, #ea580c); color: #fff; }
.banner-slide.loja-surya   { background: linear-gradient(135deg, #4c1d95, #7c3aed); color: #fff; }
.banner-slide.loja-medsul  { background: linear-gradient(135deg, #164e63, #0891b2); color: #fff; }
.banner-slide.loja-outro   { background: linear-gradient(135deg, #1e3a5f, #2d6a9f); color: #fff; }

.banner-img-wrap {
  flex-shrink: 0;
  width: 130px;
  height: 130px;
  background: rgba(255,255,255,0.15);
  border-radius: 10px;
  display: flex;
  align-items: center;
  justify-content: center;
  overflow: hidden;
}

.banner-img-wrap img {
  width: 100%;
  height: 100%;
  object-fit: contain;
  padding: 6px;
}

.banner-img-icon {
  font-size: 3.5rem;
  opacity: 0.6;
}

/* Logo da loja parceira (tile branco) */
.banner-logo {
  flex-shrink: 0;
  width: 120px;
  height: 120px;
  border-radius: 12px;
  background: #fff;
  display: flex;
  align-items: center;
  justify-content: center;
  overflow: hidden;
  box-shadow: 0 2px 10px rgba(0,0,0,0.2);
}
.banner-logo img { width: 100%; height: 100%; object-fit: contain; padding: 10px; }
.banner-logo.vazio { background: rgba(255,255,255,0.15); }
.banner-logo.vazio span { font-size: 3rem; opacity: 0.7; }

/* Pílula com a nota do Reclame Aqui (inline no título) */
.ra-pill {
  display: inline-flex;
  align-items: center;
  gap: 3px;
  font-size: 0.85rem;
  font-weight: 800;
  color: #fff;
  border-radius: 20px;
  padding: 2px 10px;
  vertical-align: middle;
  margin-left: 0.4rem;
}
.ra-pill.ra-otimo   { background: #16a34a; }
.ra-pill.ra-bom     { background: #2563eb; }
.ra-pill.ra-regular { background: #d97706; }
.ra-pill.ra-ruim    { background: #dc2626; }
.ra-pill.ra-sem     { background: rgba(255,255,255,0.22); font-size: 0.72rem; font-weight: 600; }

.banner-texto { flex: 1; min-width: 0; }

.banner-tag {
  font-size: 0.7rem;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 1px;
  opacity: 0.7;
  margin-bottom: 0.35rem;
}

.banner-titulo {
  font-size: 1.15rem;
  font-weight: 800;
  line-height: 1.25;
  margin-bottom: 0.4rem;
  display: -webkit-box;
  -webkit-line-clamp: 2;
  -webkit-box-orient: vertical;
  overflow: hidden;
}

.banner-sub {
  font-size: 0.85rem;
  opacity: 0.8;
  margin-bottom: 0.5rem;
}

.banner-preco {
  font-size: 1rem;
  font-weight: 700;
  opacity: 0.95;
}

.banner-slide.clicavel { cursor: pointer; }
.banner-cta {
  font-size: 0.8rem;
  font-weight: 600;
  opacity: 0.9;
  margin-left: 0.4rem;
  white-space: nowrap;
}
.banner-slide.clicavel:hover .banner-cta { text-decoration: underline; }

.banners-dots {
  display: flex;
  justify-content: center;
  gap: 6px;
  margin-top: 0.6rem;
}

.banner-dot {
  width: 8px;
  height: 8px;
  border-radius: 50%;
  background: var(--cinza-borda);
  border: none;
  cursor: pointer;
  transition: background 0.2s, transform 0.2s;
  padding: 0;
}

.banner-dot.ativo {
  background: var(--azul);
  transform: scale(1.2);
}

/* ── Nav de páginas no topo ── */
.site-nav { display: flex; gap: 0.25rem; align-items: center; flex: 1; }
.site-link {
  color: rgba(255,255,255,0.8);
  font-size: 0.85rem;
  font-weight: 600;
  padding: 6px 12px;
  border-radius: 20px;
  cursor: pointer;
  text-decoration: none;
  white-space: nowrap;
  transition: background 0.15s, color 0.15s;
}
.site-link:hover, .site-link.ativo { background: rgba(255,255,255,0.2); color: #fff; }

/* ── Layout: barra azul fixa à esquerda + conteúdo à direita ── */
#app-layout { display: block; }
#conteudo { margin-left: 230px; padding: 0 1rem; min-width: 0; }

/* ── Menu de categorias (barra azul, colada na borda esquerda) ── */
#cat-menu {
  position: fixed;
  left: 0;
  top: 56px;
  bottom: 0;
  width: 230px;
  background: var(--azul);
  color: #fff;
  overflow-y: auto;
  padding: 1.1rem 0.7rem 2rem;
  z-index: 80;
  scrollbar-width: thin;
}
.cat-menu-titulo {
  font-size: 0.72rem;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.7px;
  color: rgba(255,255,255,0.55);
  margin: 0 0.6rem 0.5rem;
}
.cat-menu-item {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 0.4rem;
  width: 100%;
  background: none;
  border: none;
  border-radius: 8px;
  padding: 0.45rem 0.6rem;
  font-size: 0.85rem;
  color: rgba(255,255,255,0.82);
  cursor: pointer;
  text-align: left;
  line-height: 1.25;
  transition: background 0.12s, color 0.12s;
}
.cat-menu-item:hover { background: rgba(255,255,255,0.1); color: #fff; }
.cat-menu-item.ativa { background: rgba(255,255,255,0.16); color: #fff; font-weight: 600; }
.cat-menu-total { font-size: 0.7rem; color: rgba(255,255,255,0.45); flex-shrink: 0; }
.cat-menu-item.ativa .cat-menu-total { color: rgba(255,255,255,0.8); }

/* ── Página Sobre/Contato ── */
.pagina-box {
  max-width: 720px;
  margin: 1.5rem auto;
  background: var(--branco);
  border: 1px solid var(--cinza-borda);
  border-radius: var(--radius);
  padding: 1.75rem;
}
.pagina-box h2 { color: var(--azul); margin-bottom: 0.9rem; }
.pagina-box p { color: #1a1a2e; line-height: 1.6; margin-bottom: 0.8rem; }

/* Página de texto longo (Termos de Uso) */
.pagina-texto h3 {
  color: var(--azul);
  font-size: 1.02rem;
  margin: 1.3rem 0 0.5rem;
}
.pagina-texto .termos-data {
  font-size: 0.82rem;
  color: var(--cinza-texto);
  margin-bottom: 1.2rem;
}

/* Estado "em breve" (Contato) */
.em-breve { text-align: center; padding: 1.5rem 0.5rem; }
.em-breve-icon { font-size: 2.6rem; margin-bottom: 0.5rem; }
.em-breve-titulo {
  font-size: 1.25rem; font-weight: 700; color: var(--azul);
  margin-bottom: 0.4rem;
}

/* ── Rodapé ── */
.site-footer {
  border-top: 1px solid var(--cinza-borda);
  padding: 1.5rem 2rem;
  margin-top: 2rem;
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  justify-content: center;
  gap: 0.4rem 1.2rem;
  font-size: 0.85rem;
  color: var(--cinza-texto);
}
.site-footer a {
  color: var(--azul-medio);
  text-decoration: none;
  cursor: pointer;
  font-weight: 600;
}
.site-footer a:hover { text-decoration: underline; }
.site-footer .footer-sep { color: var(--cinza-borda); }
.site-footer .footer-copy { width: 100%; text-align: center; font-size: 0.78rem; }

/* ── Sidebar de subcategorias (dentro da barra azul) ── */
#cat-menu #sidebar {
  margin-top: 1rem;
  padding-top: 0.85rem;
  border-top: 1px solid rgba(255,255,255,0.15);
  position: static;
  width: auto;
  max-height: none;
  overflow: visible;
}
#cat-menu .sidebar-titulo {
  color: rgba(255,255,255,0.55);
  border-bottom: 1px solid rgba(255,255,255,0.15);
}
#cat-menu .sidebar-btn { color: rgba(255,255,255,0.82); }
#cat-menu .sidebar-btn:hover { background: rgba(255,255,255,0.1); }
#cat-menu .sidebar-btn.ativo { background: rgba(255,255,255,0.18); color: #fff; }
#cat-menu .sidebar-btn .sub-total {
  background: rgba(255,255,255,0.15);
  color: rgba(255,255,255,0.8);
}
#cat-menu .sidebar-btn.ativo .sub-total { background: rgba(255,255,255,0.28); color: #fff; }

.sidebar-titulo {
  font-size: 0.72rem;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.7px;
  color: var(--cinza-texto);
  margin-bottom: 0.6rem;
  padding-bottom: 0.4rem;
  border-bottom: 1px solid var(--cinza-borda);
}

.sidebar-btn {
  display: flex;
  align-items: center;
  justify-content: space-between;
  width: 100%;
  background: none;
  border: none;
  border-radius: 8px;
  padding: 0.4rem 0.6rem;
  font-size: 0.83rem;
  color: #1a1a2e;
  cursor: pointer;
  text-align: left;
  line-height: 1.3;
  transition: background 0.12s;
  gap: 0.4rem;
}

.sidebar-btn:hover { background: var(--azul-claro); }

.sidebar-btn.ativo {
  background: var(--azul);
  color: var(--branco);
  font-weight: 600;
}

.sidebar-btn .sub-total {
  font-size: 0.72rem;
  color: var(--cinza-texto);
  flex-shrink: 0;
  background: var(--branco);
  border-radius: 20px;
  padding: 1px 5px;
}

.sidebar-btn.ativo .sub-total {
  background: rgba(255,255,255,0.2);
  color: rgba(255,255,255,0.8);
}

/* ── Resultados ── */
#resultados { flex: 1; min-width: 0; }

.resultado-info {
  font-size: 0.85rem;
  color: var(--cinza-texto);
  margin-bottom: 1rem;
  padding-left: 0.2rem;
}

.card {
  display: grid;
  grid-template-columns: 100px 1fr;
  gap: 1rem;
  background: var(--branco);
  border: 1px solid var(--cinza-borda);
  border-radius: var(--radius);
  padding: 1rem;
  margin-bottom: 0.75rem;
  box-shadow: 0 2px 8px rgba(13,43,78,0.06);
  transition: box-shadow 0.15s, transform 0.15s;
}

.card:hover {
  box-shadow: var(--sombra);
  transform: translateY(-1px);
}

.card-img {
  width: 100px;
  height: 100px;
  object-fit: contain;
  border-radius: 8px;
  background: var(--azul-claro);
  padding: 4px;
}

.card-img-placeholder {
  width: 100px;
  height: 100px;
  border-radius: 8px;
  background: var(--azul-claro);
  display: flex;
  align-items: center;
  justify-content: center;
  color: var(--cinza-borda);
  font-size: 2rem;
}

.card-body { display: flex; flex-direction: column; gap: 0.5rem; }

.card-nome {
  font-size: 0.97rem;
  font-weight: 600;
  color: #1a1a2e;
  line-height: 1.3;
}

.card-marca {
  font-size: 0.78rem;
  color: var(--cinza-texto);
  text-transform: uppercase;
  letter-spacing: 0.4px;
}

.card-specs {
  display: flex;
  flex-wrap: wrap;
  gap: 0.35rem;
  margin-top: -0.1rem;
}

.card-specs span {
  font-size: 0.72rem;
  font-weight: 600;
  color: var(--azul-medio);
  background: var(--azul-claro);
  border-radius: 5px;
  padding: 1px 7px;
  white-space: nowrap;
}

.card-ofertas {
  display: flex;
  flex-wrap: wrap;
  gap: 0.5rem;
  margin-top: 0.2rem;
}

.oferta-chip {
  display: flex;
  align-items: center;
  gap: 0.4rem;
  background: var(--azul-claro);
  border: 1px solid var(--cinza-borda);
  border-radius: 8px;
  padding: 0.35rem 0.7rem;
  text-decoration: none;
  transition: background 0.15s;
}

.oferta-chip:hover { background: #d0e4f7; }

.oferta-chip .loja-nome {
  font-size: 0.78rem;
  color: var(--cinza-texto);
  font-weight: 500;
}

.oferta-chip .preco {
  font-size: 0.95rem;
  font-weight: 700;
  color: var(--azul);
}

.oferta-chip.melhor-preco {
  background: var(--azul);
  border-color: var(--azul);
}

.oferta-chip.melhor-preco .loja-nome { color: rgba(255,255,255,0.75); }
.oferta-chip.melhor-preco .preco { color: var(--branco); }

.badge-economia {
  font-size: 0.75rem;
  background: #16a34a;
  color: white;
  border-radius: 6px;
  padding: 3px 8px;
  font-weight: 700;
  align-self: center;
  white-space: nowrap;
}

/* ── Categorias ── */
.cats-section {
  max-width: 900px;
  margin: 0 auto;
  padding: 0.5rem 1rem 2rem;
}

.cats-titulo {
  font-size: 0.8rem;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.8px;
  color: var(--cinza-texto);
  margin-bottom: 1rem;
}

.cats-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(200px, 1fr));
  gap: 0.7rem;
}

.cats-loading {
  color: var(--cinza-texto);
  font-size: 0.9rem;
  grid-column: 1/-1;
}

.cat-chip {
  display: flex;
  align-items: center;
  gap: 0.6rem;
  min-height: 58px;
  background: var(--azul-claro);
  border: 1px solid var(--cinza-borda);
  border-radius: 10px;
  padding: 0.6rem 0.9rem;
  cursor: pointer;
  font-size: 0.9rem;
  font-weight: 500;
  color: var(--azul);
  transition: background 0.15s, border-color 0.15s, transform 0.12s;
  text-align: left;
  line-height: 1.25;
}

.cat-chip:hover {
  background: #d0e4f7;
  border-color: var(--azul-medio);
  transform: translateY(-1px);
}

.cat-chip.ativa {
  background: var(--azul);
  border-color: var(--azul);
  color: var(--branco);
}

.cat-chip .cat-total {
  font-size: 0.72rem;
  color: var(--cinza-texto);
  margin-left: auto;
  flex-shrink: 0;
  background: var(--branco);
  border-radius: 20px;
  padding: 1px 6px;
}

.cat-chip.ativa .cat-total {
  background: rgba(255,255,255,0.2);
  color: rgba(255,255,255,0.85);
}

.cat-img {
  width: 38px;
  height: 38px;
  flex-shrink: 0;
  object-fit: contain;
  border-radius: 8px;
  background: var(--branco);
  border: 1px solid var(--cinza-borda);
  padding: 2px;
}

.cat-emoji {
  width: 38px;
  height: 38px;
  flex-shrink: 0;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 1.3rem;
  background: var(--branco);
  border-radius: 8px;
}

.cat-nome {
  flex: 1;
  min-width: 0;
  overflow-wrap: anywhere;
  hyphens: auto;
}

.cat-chip.ativa .cat-img,
.cat-chip.ativa .cat-emoji { border-color: rgba(255,255,255,0.4); }

/* ── Filtros ── */
.filtros-bar {
  background: var(--branco);
  border-bottom: 1px solid var(--cinza-borda);
  position: sticky;
  top: 56px;
  z-index: 90;
}

.filtros-inner {
  max-width: 1080px;
  margin: 0 auto;
  padding: 0.6rem 1rem;
  display: flex;
  gap: 1.5rem;
  flex-wrap: wrap;
  align-items: center;
}

.filtro-grupo {
  display: flex;
  align-items: center;
  gap: 0.5rem;
}

.filtro-label {
  font-size: 0.75rem;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.5px;
  color: var(--cinza-texto);
  white-space: nowrap;
}

.filtro-btns {
  display: flex;
  gap: 0.3rem;
  flex-wrap: wrap;
}

.filtro-btn {
  border: 1px solid var(--cinza-borda);
  background: var(--branco);
  border-radius: 20px;
  padding: 0.3rem 0.8rem;
  font-size: 0.82rem;
  cursor: pointer;
  color: var(--azul);
  font-weight: 500;
  transition: background 0.15s, border-color 0.15s;
  white-space: nowrap;
}

.filtro-btn:hover { background: var(--azul-claro); }

.filtro-btn.ativo {
  background: var(--azul);
  border-color: var(--azul);
  color: var(--branco);
}

.filtro-select {
  border: 1px solid var(--cinza-borda);
  background: var(--branco);
  border-radius: 20px;
  padding: 0.3rem 2rem 0.3rem 0.8rem;
  font-size: 0.82rem;
  cursor: pointer;
  color: var(--azul);
  font-weight: 500;
  appearance: none;
  background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='10' height='6'%3E%3Cpath d='M0 0l5 6 5-6z' fill='%231a4a7a'/%3E%3C/svg%3E");
  background-repeat: no-repeat;
  background-position: right 0.7rem center;
  outline: none;
  transition: border-color 0.15s;
  max-width: 200px;
}

.filtro-select:focus { border-color: var(--azul-medio); }

/* Paginação */
.paginacao {
  display: flex;
  align-items: center;
  gap: 0.5rem;
  justify-content: center;
  margin-top: 1.5rem;
  flex-wrap: wrap;
}

.paginacao button {
  border: 1px solid var(--cinza-borda);
  background: var(--branco);
  border-radius: 8px;
  padding: 0.4rem 0.9rem;
  font-size: 0.88rem;
  cursor: pointer;
  color: var(--azul);
  font-weight: 500;
  transition: background 0.15s;
}

.paginacao button:hover:not(:disabled) { background: var(--azul-claro); }
.paginacao button:disabled { opacity: 0.35; cursor: default; }

.paginacao .pg-info {
  font-size: 0.82rem;
  color: var(--cinza-texto);
}

/* Header nav cats */
.header-cats {
  display: none;
  gap: 0.4rem;
  overflow-x: auto;
  scrollbar-width: none;
  flex: 1;
}
.header-cats::-webkit-scrollbar { display: none; }
.header-cats.visible { display: flex; align-items: center; }

.header-cat-btn {
  flex-shrink: 0;
  font-size: 0.78rem;
  color: rgba(255,255,255,0.7);
  background: rgba(255,255,255,0.1);
  border: none;
  border-radius: 20px;
  padding: 4px 10px;
  cursor: pointer;
  white-space: nowrap;
  transition: background 0.15s, color 0.15s;
}
.header-cat-btn:hover, .header-cat-btn.ativa { background: rgba(255,255,255,0.25); color: #fff; }

/* ── Estado vazio / erro ── */
.estado {
  text-align: center;
  padding: 3rem 1rem;
  color: var(--cinza-texto);
}

.estado .icon { font-size: 3rem; margin-bottom: 0.75rem; }
.estado p { font-size: 0.95rem; }

/* ── Responsivo ── */
/* ── Carrinho ── */
.cart-btn {
  flex-shrink: 0;
  background: rgba(255,255,255,0.12);
  border: none;
  border-radius: 20px;
  padding: 0.35rem 0.8rem;
  color: var(--branco);
  font-size: 0.95rem;
  cursor: pointer;
  display: flex;
  align-items: center;
  gap: 0.3rem;
  transition: background 0.15s;
  white-space: nowrap;
}
.cart-btn:hover { background: rgba(255,255,255,0.22); }

.cart-count {
  background: #ef4444;
  color: #fff;
  font-size: 0.7rem;
  font-weight: 700;
  border-radius: 50%;
  min-width: 18px;
  height: 18px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  padding: 0 3px;
}

.cart-overlay {
  display: none;
  position: fixed;
  inset: 0;
  background: rgba(0,0,0,0.35);
  z-index: 200;
}
.cart-overlay.aberto { display: block; }

.cart-drawer {
  position: fixed;
  top: 0;
  right: 0;
  width: 380px;
  max-width: 100vw;
  height: 100vh;
  background: var(--branco);
  z-index: 201;
  box-shadow: -4px 0 24px rgba(0,0,0,0.18);
  display: flex;
  flex-direction: column;
  transform: translateX(100%);
  transition: transform 0.3s cubic-bezier(0.4, 0, 0.2, 1);
}
.cart-drawer.aberto { transform: translateX(0); }

.cart-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 1rem 1.2rem;
  border-bottom: 1px solid var(--cinza-borda);
  flex-shrink: 0;
}
.cart-titulo { font-size: 1rem; font-weight: 700; color: var(--azul); }
.cart-close {
  background: none;
  border: none;
  font-size: 1.1rem;
  cursor: pointer;
  color: var(--cinza-texto);
  padding: 0.2rem 0.4rem;
  border-radius: 6px;
  transition: background 0.15s;
}
.cart-close:hover { background: var(--azul-claro); }

.cart-body {
  flex: 1;
  overflow-y: auto;
  padding: 1rem 1.2rem;
}

.cart-vazio {
  text-align: center;
  padding: 2rem 1rem 1rem;
  color: var(--cinza-texto);
}
.cart-vazio .icon { font-size: 2.5rem; margin-bottom: 0.5rem; }

.cart-grupo {
  margin-bottom: 1.5rem;
  border: 1px solid var(--cinza-borda);
  border-radius: var(--radius);
  overflow: hidden;
}

.cart-grupo-header {
  background: var(--azul-claro);
  padding: 0.6rem 0.9rem;
  display: flex;
  align-items: center;
  justify-content: space-between;
}
.cart-grupo-loja { font-weight: 700; font-size: 0.88rem; color: var(--azul); }
.cart-grupo-subtotal { font-size: 0.82rem; color: var(--azul-medio); font-weight: 600; }

.cart-item {
  display: flex;
  align-items: center;
  gap: 0.7rem;
  padding: 0.65rem 0.9rem;
  border-top: 1px solid var(--cinza-borda);
}
.cart-item-img {
  width: 44px;
  height: 44px;
  object-fit: contain;
  border-radius: 6px;
  background: var(--azul-claro);
  flex-shrink: 0;
  padding: 2px;
}
.cart-item-info { flex: 1; min-width: 0; }
.cart-item-nome {
  font-size: 0.82rem;
  font-weight: 600;
  color: #1a1a2e;
  line-height: 1.3;
  display: -webkit-box;
  -webkit-line-clamp: 2;
  -webkit-box-orient: vertical;
  overflow: hidden;
}
.cart-item-marca { font-size: 0.72rem; color: var(--cinza-texto); }
.cart-item-preco { font-size: 0.9rem; font-weight: 700; color: var(--azul); white-space: nowrap; }
.cart-item-remove {
  background: none;
  border: none;
  cursor: pointer;
  color: var(--cinza-texto);
  font-size: 1rem;
  padding: 0.2rem;
  border-radius: 4px;
  flex-shrink: 0;
  transition: color 0.15s, background 0.15s;
}
.cart-item-remove:hover { color: #ef4444; background: #fee2e2; }

.cart-grupo-footer {
  padding: 0.75rem 0.9rem;
  border-top: 1px solid var(--cinza-borda);
  background: #f8fafd;
}
.btn-ir-loja {
  width: 100%;
  background: var(--azul);
  color: var(--branco);
  border: none;
  border-radius: 8px;
  padding: 0.6rem;
  font-size: 0.85rem;
  font-weight: 600;
  cursor: pointer;
  transition: background 0.15s;
}
.btn-ir-loja:hover { background: var(--azul-medio); }

.cart-total-geral {
  margin-top: 0.5rem;
  padding-top: 0.75rem;
  border-top: 2px solid var(--cinza-borda);
  font-size: 0.9rem;
  font-weight: 700;
  color: var(--azul);
  display: flex;
  justify-content: space-between;
}

.btn-limpar-cart {
  width: 100%;
  margin-top: 0.9rem;
  background: none;
  border: 1px solid var(--cinza-borda);
  color: #b91c1c;
  border-radius: 8px;
  padding: 0.55rem;
  font-size: 0.82rem;
  font-weight: 600;
  cursor: pointer;
  transition: background 0.15s, border-color 0.15s;
}
.btn-limpar-cart:hover { background: #fee2e2; border-color: #fca5a5; }

/* Assistente de finalização */
.assist-voltar {
  background: none;
  border: none;
  color: var(--azul-medio);
  font-size: 0.82rem;
  font-weight: 600;
  cursor: pointer;
  padding: 0.2rem 0;
  margin-bottom: 0.75rem;
}
.assist-voltar:hover { text-decoration: underline; }

.assist-cabecalho {
  margin-bottom: 1rem;
}
.assist-loja {
  font-size: 1.05rem;
  font-weight: 800;
  color: var(--azul);
  margin-bottom: 0.4rem;
}
.assist-instrucoes {
  font-size: 0.82rem;
  color: var(--cinza-texto);
  line-height: 1.45;
  background: var(--azul-claro);
  border-radius: 8px;
  padding: 0.6rem 0.75rem;
  margin-bottom: 0.6rem;
}
.assist-progresso {
  font-size: 0.78rem;
  font-weight: 600;
  color: var(--azul-medio);
}

.assist-item {
  display: flex;
  align-items: center;
  gap: 0.7rem;
  padding: 0.7rem 0;
  border-bottom: 1px solid var(--cinza-borda);
}
.assist-item.aberto { opacity: 0.6; }

.btn-abrir-prod {
  flex-shrink: 0;
  background: var(--azul);
  color: var(--branco);
  border: none;
  border-radius: 8px;
  padding: 0.45rem 0.8rem;
  font-size: 0.78rem;
  font-weight: 600;
  cursor: pointer;
  transition: background 0.15s;
  white-space: nowrap;
}
.btn-abrir-prod:hover { background: var(--azul-medio); }
.assist-item.aberto .btn-abrir-prod { background: #16a34a; }

.assist-final {
  margin-top: 1rem;
  background: #dcfce7;
  color: #15803d;
  border-radius: 8px;
  padding: 0.75rem;
  font-size: 0.85rem;
  font-weight: 600;
  text-align: center;
}

/* Botão + nas ofertas */
.oferta-wrap {
  display: flex;
  align-items: center;
  gap: 3px;
}
.btn-add-cart {
  width: 24px;
  height: 24px;
  border-radius: 50%;
  border: 1.5px solid var(--cinza-borda);
  background: var(--branco);
  color: var(--azul);
  font-size: 1rem;
  line-height: 1;
  cursor: pointer;
  flex-shrink: 0;
  display: flex;
  align-items: center;
  justify-content: center;
  transition: background 0.15s, border-color 0.15s, color 0.15s;
  padding: 0;
}
.btn-add-cart:hover { background: var(--azul); border-color: var(--azul); color: var(--branco); }
.btn-add-cart.adicionado { background: #16a34a; border-color: #16a34a; color: var(--branco); }

@media (max-width: 700px) {
  #cat-menu { display: none; }
  #conteudo { margin-left: 0; padding: 0 0.75rem; }
  .banner-slide { height: 140px; padding: 1rem; gap: 1rem; }
  .banner-img-wrap { width: 90px; height: 90px; }
  .banner-logo { width: 90px; height: 90px; }
  .banner-titulo { font-size: 0.95rem; }
}

@media (max-width: 560px) {
  .site-nav { display: none; }
}

@media (max-width: 500px) {
  .hero h1 { font-size: 1.6rem; }
  .card { grid-template-columns: 72px 1fr; }
  .card-img, .card-img-placeholder { width: 72px; height: 72px; }
  .banner-img-wrap { display: none; }
}

/* ── Espaço de anúncio (placeholder p/ Google Ads) ── */
.ad-slot {
  max-width: 728px;
  min-height: 90px;
  margin: 1.5rem auto 0;
  display: flex;
  align-items: center;
  justify-content: center;
  background: repeating-linear-gradient(45deg, #f3f6fa, #f3f6fa 12px, #eef3f9 12px, #eef3f9 24px);
  border: 1px dashed var(--cinza-borda);
  border-radius: 8px;
  color: var(--cinza-texto);
}
.ad-slot[hidden] { display: none; }
.ad-slot-label {
  font-size: 0.7rem;
  text-transform: uppercase;
  letter-spacing: 1px;
  font-weight: 600;
}

/* ── Banner de consentimento de cookies (LGPD) ── */
.cookie-banner {
  position: fixed;
  left: 1rem;
  right: 1rem;
  bottom: 1rem;
  z-index: 1000;
  max-width: 720px;
  margin: 0 auto;
  background: var(--azul);
  color: var(--branco);
  border-radius: var(--radius);
  box-shadow: var(--sombra);
  padding: 1rem 1.2rem;
  display: flex;
  align-items: center;
  gap: 1rem;
  flex-wrap: wrap;
}
.cookie-text { flex: 1; min-width: 200px; font-size: 0.85rem; line-height: 1.5; }
.cookie-text a { color: #9ecbff; text-decoration: underline; cursor: pointer; }
.cookie-acoes { display: flex; gap: 0.5rem; }
.cookie-btn {
  border: none;
  border-radius: 8px;
  padding: 0.5rem 1.1rem;
  font-size: 0.85rem;
  font-weight: 700;
  cursor: pointer;
}
.cookie-btn.aceitar { background: #5ba3f5; color: var(--azul); }
.cookie-btn.aceitar:hover { background: #7db8f7; }
.cookie-btn.recusar { background: transparent; color: var(--branco); border: 1px solid rgba(255,255,255,0.4); }
.cookie-btn.recusar:hover { background: rgba(255,255,255,0.1); }

@media (max-width: 560px) {
  .cookie-banner { flex-direction: column; align-items: stretch; }
  .cookie-acoes { justify-content: flex-end; }
}
