/* Loja alinhada ao visual da home (styles.css) */
.loja-page-main {
  padding: 1.25rem 0 2.5rem;
}

.loja-page-title {
  font-size: clamp(1.35rem, 3vw, 1.75rem);
  margin: 0 0 1rem;
  font-weight: 800;
}

/* Ofertas em destaque / Destaques / Todos os produtos — cor de marca (igual .logo-mark / tema) */
.loja-page-main .products-section .section-head h2 {
  color: var(--brand);
}

.loja-muted {
  color: var(--muted);
  font-size: 0.92rem;
}

.loja-messages {
  margin-bottom: 1rem;
}

.auth-success {
  margin: 0 0 1rem;
  padding: 0.75rem;
  background: rgba(63, 185, 80, 0.15);
  border: 1px solid #3fb950;
  border-radius: 8px;
  color: #3fb950;
  font-size: 0.9rem;
}

.auth-success a {
  color: var(--brand);
  text-decoration: underline;
}

.loja-discord-btn {
  display: inline-block;
  padding: 0.65rem 1rem;
  background: #5865f2;
  color: #fff !important;
  border-radius: 9px;
  font-weight: 700;
  font-size: 0.95rem;
}

.loja-pagamentos-box {
  margin-bottom: 1.5rem;
  padding: 0.85rem 1rem;
  background: rgba(77, 166, 255, 0.08);
  border: 1px solid var(--line);
  border-radius: 12px;
}

.loja-pagamentos-box strong {
  display: block;
  margin-bottom: 0.35rem;
  font-size: 0.95rem;
}

.loja-pagamentos-box p {
  margin: 0;
  white-space: pre-line;
  color: var(--muted);
  font-size: 0.92rem;
}

/* Miniatura 1:1 (mesmo padrao da vitrine / placeholder); cards iguais na grade */
#loja-products-grid .product > .product-thumb,
.loja-featured-grid .product > .product-thumb {
  aspect-ratio: 1 / 1;
  margin: -0.44rem -0.44rem 0.32rem -0.44rem;
  width: calc(100% + 0.88rem);
  max-width: none;
  border-radius: 14px 14px 0 0;
  border: none;
  border-bottom: 1px solid #2d3348;
}

#loja-products-grid .product,
.loja-featured-grid .product {
  display: flex;
  flex-direction: column;
  height: 100%;
  min-height: 0;
  padding: 0.44rem;
  box-sizing: border-box;
}

#loja-products-grid .product .product-category,
.loja-featured-grid .product .product-category {
  margin: 0 0 0.078rem;
  font-size: 0.69rem;
  line-height: 1.14;
}

#loja-products-grid .product .product-title,
.loja-featured-grid .product .product-title {
  display: -webkit-box;
  -webkit-box-orient: vertical;
  -webkit-line-clamp: 2;
  overflow: hidden;
  min-height: 2.38em;
  margin: 0 0 0.15rem;
  font-size: 0.85rem;
  font-weight: 700;
  line-height: 1.19;
}

#loja-products-grid .product .price-old,
.loja-featured-grid .product .price-old {
  margin-top: 0.11rem;
  font-size: 0.71rem;
  min-height: 1.15em;
  line-height: 1.15;
}

#loja-products-grid .product .price-now,
.loja-featured-grid .product .price-now {
  margin-top: 0;
  font-size: 0.97rem;
  line-height: 1.14;
}

/* Sem preco antigo: reserva a mesma altura da linha do .price-old para alinhar precos */
#loja-products-grid .product:not(:has(.price-old)) .price-now,
.loja-featured-grid .product:not(:has(.price-old)) .price-now {
  margin-top: calc(0.11rem + 1.15em);
}

#loja-products-grid .product .loja-add-form,
.loja-featured-grid .product .loja-add-form {
  margin-top: auto;
  display: flex;
  flex-direction: column;
  gap: 0.24rem;
}

#loja-products-grid .product .loja-qty-label,
.loja-featured-grid .product .loja-qty-label {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 0.4rem;
  font-size: 0.74rem;
  color: var(--muted);
  margin: 0;
}

#loja-products-grid .product .loja-qty-label input,
.loja-featured-grid .product .loja-qty-label input {
  width: 2.98rem;
  padding: 0.22rem 0.27rem;
  border-radius: 5px;
  border: 1px solid #2d3348;
  background: #0d1017;
  color: var(--text);
  font-family: inherit;
  font-size: 0.8rem;
}

#loja-products-grid .product .buy,
.loja-featured-grid .product .buy {
  width: 100%;
  margin-top: 0.27rem;
  padding: 0.4rem 0.44rem;
  font-size: 0.84rem;
}

.loja-footer-note {
  margin-top: 2rem;
  padding-top: 1rem;
  border-top: 1px solid var(--line);
  font-size: 0.9rem;
  color: var(--muted);
}

.loja-footer-note a {
  color: var(--brand);
}

/* Grade 4 colunas x ate 8 linhas (32 cards/pagina) no desktop */
.loja-grid-catalog {
  grid-template-columns: repeat(4, minmax(0, 1fr)) !important;
  align-items: stretch;
  gap: 17px;
}

@media (max-width: 900px) {
  .loja-grid-catalog {
    grid-template-columns: repeat(2, minmax(0, 1fr)) !important;
  }
}

@media (max-width: 520px) {
  .loja-grid-catalog {
    grid-template-columns: 1fr !important;
  }
}

.loja-tabs-nav {
  display: flex;
  flex-wrap: wrap;
  gap: 0.55rem;
  align-items: center;
}

/* Abas de categoria centralizadas (com o título da seção) */
.products-section .section-head:has(.loja-tabs-nav) {
  flex-direction: column;
  align-items: center;
  text-align: center;
}

.products-section .section-head:has(.loja-tabs-nav) h2 {
  width: 100%;
  margin-bottom: 0;
}

.products-section .section-head:has(.loja-tabs-nav) .loja-tabs-nav {
  justify-content: center;
  width: 100%;
}

.loja-tabs-nav .tab {
  text-decoration: none;
  display: inline-flex;
  align-items: center;
  justify-content: center;
}

.loja-pagination {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 1rem;
  flex-wrap: wrap;
  margin-top: 1.25rem;
}

.loja-page-link {
  color: var(--brand);
  font-weight: 600;
  text-decoration: none;
}

.loja-page-link:hover {
  text-decoration: underline;
}

.loja-page-info {
  font-size: 0.9rem;
  color: var(--muted);
}
