.page{ padding:18px 0 80px; }

.categories{
  display:grid;
  grid-template-columns: repeat(10, minmax(72px, 1fr));
  gap:14px;
  padding:18px 0 10px;
  overflow:auto;
}

.category-card{
  display:flex;
  flex-direction:column;
  align-items:center;
  gap:8px;
  padding:10px 8px;
}

.category-card img{
  width:44px;
  height:44px;
  object-fit:contain;
}

.category-card span{
  font-size:12px;
  font-weight:700;
  text-align:center;
}

.section{ margin-top:18px; }

.section-head{
  display:flex;
  align-items:center;
  justify-content:space-between;
  margin-bottom:12px;
}

.section-head h2{
  margin:0;
  font-size:26px;
}

.section-head a{
  color:#f97316;
  font-weight:800;
  font-size:13px;
}

.scroll{
  display:flex;
  gap:14px;
  overflow:auto;
  padding-bottom:10px;
}

/* ===================================
   CARD DE PRODUTO - COMPACTO
   =================================== */

.product{
  width:220px;
  min-width:220px;
  background:white;
  border:1px solid #eef2f7;
  border-radius:12px;
  box-shadow:0 4px 12px rgba(0,0,0,.08);
  overflow:hidden;
  position:relative;
  display:flex;
  flex-direction:column;
}

/* Container da imagem COM BORDA BRANCA */
.product .media{
  position:relative;
  padding:12px;
  background:white;
}

.product .media img{
  width:100%;
  height:auto;
  aspect-ratio:1;
  object-fit:cover;
  border-radius:8px;
}

/* Badge promocional */
.product .product-badge {
  position:absolute;
  top:16px;
  left:16px;
  background:#3b82f6;
  color:white;
  padding:4px 10px;
  border-radius:4px;
  font-size:10px;
  font-weight:700;
  text-transform:uppercase;
  box-shadow:0 2px 4px rgba(0,0,0,0.2);
  z-index:10;
}

/* ESCONDER Ribbon */
.ribbon{
  display:none !important;
}

/* Corpo do card */
.product .body{ 
  padding:8px 12px 12px;
  display:flex;
  flex-direction:column;
  gap:6px;
  flex:1;
}

/* Nome do produto */
.product .name{
  font-size:13px;
  font-weight:600;
  line-height:1.3;
  color:#1f2937;
  min-height:34px;
  display:-webkit-box;
  -webkit-line-clamp:2;
  -webkit-box-orient:vertical;
  overflow:hidden;
  text-decoration:none;
}

.product .name:hover{
  color:#3b82f6;
}

/* PREÇO ANTIGO + % NA MESMA LINHA */
.product .old-price-line {
  display:flex;
  align-items:center;
  gap:6px;
  margin-bottom:2px;
}

/* Preço antigo */
.product .old-price {
  font-size:12px;
  color:#9ca3af;
  text-decoration:line-through;
}

/* Badge de desconto verde */
.product .discount-badge {
  background:#10b981;
  color:white;
  font-size:10px;
  font-weight:700;
  padding:2px 6px;
  border-radius:3px;
}

/* PREÇO ATUAL (sozinho) */
.product .price {
  font-size:24px;
  font-weight:900;
  color:#1f2937;
  line-height:1;
  display:block;
  margin-bottom:3px;
}

/* Texto PIX */
.product .pix-text {
  font-size:11px;
  color:#374151;
  line-height:1.5;
  margin-bottom:2px;
}

.product .pix-text .pix-label {
  font-weight:600;
  color:#059669;
}

.product .pix-text strong {
  color:#1f2937;
  font-weight:700;
  font-size:12px;
}

/* Botão Comprar */
.product .btn-buy {
  width:100%;
  padding:12px;
  background:#dc2626;
  color:white;
  border:none;
  border-radius:8px;
  font-size:14px;
  font-weight:700;
  cursor:pointer;
  text-decoration:none;
  text-align:center;
  display:block;
  transition:background 0.2s;
}

.product .btn-buy:hover {
  background:#b91c1c;
}

/* ESCONDER elementos antigos */
.product .prices {
  display:none !important;
}

.product .add {
  display:none !important;
}

.product .price-area {
  display:none !important;
}

.product .current-price-line {
  display:none !important;
}

/* ===================================
   CARRINHO E TOAST
   =================================== */

.fab-cart{
  position:fixed;
  right:16px;
  bottom:16px;
  z-index:45;
  width:56px;
  height:56px;
  border-radius:999px;
  border:0;
  background:#f97316;
  color:#fff;
  cursor:pointer;
  box-shadow:var(--shadow);
  display:none;
}

.fab-cart .badge{
  position:absolute;
  right:-2px;
  top:-2px;
  width:22px;
  height:22px;
  border-radius:999px;
  background:#fff;
  color:#111;
  display:flex;
  align-items:center;
  justify-content:center;
  font-weight:900;
  font-size:12px;
}

.toast{
  position:fixed;
  top:90px;
  right:16px;
  z-index:60;
  background:#111827;
  color:#fff;
  padding:10px 12px;
  border-radius:12px;
  box-shadow:var(--shadow);
  opacity:0;
  transform:translateY(-8px);
  pointer-events:none;
  transition:.18s ease;
  font-weight:700;
  font-size:13px;
}

.toast.show{
  opacity:1;
  transform:translateY(0);
}

.cart-overlay{
  position:fixed;
  inset:0;
  background:rgba(0,0,0,.35);
  z-index:9999;
  display:none;
}

.cart-overlay.open{ display:block; }

.cart-panel{
  position:fixed;
  top:0;
  right:0;
  width:380px;
  max-width:92vw;
  height:100vh;
  background:#fff;
  z-index:10000;
  box-shadow:var(--shadow);
  transform:translateX(110%);
  transition:.22s ease;
  display:flex;
  flex-direction:column;
}

.cart-panel.open{ transform:translateX(0); }

.cart-header{
  padding:16px;
  border-bottom:1px solid var(--border);
  display:flex;
  align-items:center;
  justify-content:space-between;
  font-weight:900;
  font-size:18px;
}

.cart-close{
  border:0;
  background:transparent;
  font-size:26px;
  cursor:pointer;
  color:#6b7280;
}

.cart-body{
  padding:12px 16px;
  overflow:auto;
  flex:1;
}

.cart-item{
  display:grid;
  grid-template-columns:52px 1fr auto;
  gap:10px;
  padding:10px 0;
  border-bottom:1px solid #f3f4f6;
}

.cart-item img{
  width:52px;
  height:52px;
  object-fit:contain;
}

.cart-item .title{
  font-weight:900;
  font-size:12px;
  line-height:1.2;
}

.cart-item .cat{
  font-size:11px;
  color:var(--muted);
}

.qty{
  display:flex;
  align-items:center;
  gap:8px;
  margin-top:8px;
}

.qty button{
  width:28px;
  height:28px;
  border-radius:6px;
  border:1px solid var(--border);
  background:#f3f4f6;
  cursor:pointer;
  font-weight:900;
}

.qty span{
  min-width:18px;
  text-align:center;
  font-weight:900;
}

.cart-item .price{
  font-weight:900;
  color:var(--green);
}

.cart-item .remove{
  color:#ef4444;
  font-size:12px;
  cursor:pointer;
  margin-top:6px;
  display:inline-block;
}

.cart-footer{
  border-top:1px solid var(--border);
  padding:12px 16px 16px;
}

.cart-msg{
  background:#ecfdf5;
  border:1px solid #bbf7d0;
  padding:10px;
  border-radius:8px;
  font-size:13px;
  color:#166534;
  font-weight:800;
  margin-bottom:10px;
}

.sum-row{
  display:flex;
  justify-content:space-between;
  font-size:13px;
  margin:8px 0;
}

.sum-row strong{ font-weight:900; }

.hr{ height:1px; background:var(--border); margin:10px 0; }

.checkout-btn{
  width:100%;
  height:48px;
  border-radius:10px;
  border:0;
  background:#f97316;
  color:#fff;
  font-weight:900;
  cursor:pointer;
}

.clear-btn{
  width:100%;
  height:42px;
  margin-top:10px;
  border-radius:10px;
  border:1px solid var(--border);
  background:#fff;
  color:#6b7280;
  cursor:pointer;
  font-weight:800;
}

/* ===================================
   GRID DE CATEGORIA
   =================================== */

.grid{
  display:grid;
  grid-template-columns: repeat(6, 1fr);
  gap:14px;
}

.grid .product{ width:auto; min-width:0; }

/* ===================================
   RESPONSIVE
   =================================== */

@media (max-width: 1100px){
  .categories{ grid-template-columns: repeat(8, minmax(72px, 1fr)); }
  .grid{ grid-template-columns: repeat(4, 1fr); }
}

@media (max-width: 820px){
  .categories{ grid-template-columns: repeat(6, minmax(72px, 1fr)); }
  .grid{ grid-template-columns: repeat(2, 1fr); }
  .fab-cart{ display:block; }

  .cart-panel{
    top:50%;
    left:50%;
    right:auto;
    transform:translate(-50%, 120%);
    width:min(420px, 94vw);
    height:min(680px, 86vh);
    border-radius:22px;
  }

  .cart-panel.open{
    transform:translate(-50%, -50%);
  }
}

@media (max-width: 768px){
  .scroll{
    gap:12px;
    padding:0 12px 12px;
  }

  /* REMOVER LARGURA FORÇADA - MANTER 230PX */

  .product .media{ padding:10px; }
  .product .price{ font-size:20px; }
  .product .btn-buy{ padding:10px; font-size:13px; }

  .section-head h2{
    font-size:18px;
  }

  .grid{
    grid-template-columns: repeat(2, 1fr);
    gap:10px;
  }
}

/* Z-INDEX DO HEADER */
.header-home {
  z-index:99 !important;
}