:root {
  /* A página de produto reaproveita os tokens globais. */
  --pdp-accent: var(--accent);
  --pdp-accent-dark: var(--accent-hover);
  --pdp-promo-bg: var(--accent-soft);
  --pdp-border: var(--line);
  --pdp-muted: var(--muted);
  --pdp-text: var(--text);
  --pdp-bg: var(--bg);
}

.product-page-body .top-offer-carousel {
  font-size: 14px;
}

.pdp-breadcrumb {
  display: flex;
  align-items: center;
  flex-wrap: wrap;
  gap: 8px;
  max-width: 1320px;
  margin: 0 auto;
  padding: 18px 24px 0;
  font-size: 13px;
  color: var(--pdp-muted);
}

.pdp-breadcrumb a {
  color: inherit;
  text-decoration: none;
}

.pdp-breadcrumb a:hover {
  color: var(--pdp-accent);
}

.pdp-breadcrumb-home {
  display: inline-flex;
  color: var(--pdp-text);
}

.pdp-breadcrumb-sep {
  display: inline-flex;
  opacity: 0.5;
}

.pdp {
  max-width: 1320px;
  margin: 0 auto;
  padding: 24px 24px 80px;
  color: var(--pdp-text);
}

.pdp-layout {
  display: grid;
  grid-template-columns: minmax(0, 1.05fr) minmax(0, 1.15fr) 320px;
  gap: 28px;
  align-items: start;
}

.pdp-gallery {
  display: grid;
  grid-template-columns: 72px minmax(0, 1fr);
  gap: 16px;
  align-items: start;
}

/* .pdp-main-image-wrap não tem altura própria: ele só acompanha o tamanho de
   .pdp-main-image (aspect-ratio 1/1). A coluna de miniaturas nunca pode
   ultrapassar essa altura — como um % de height não trava nada num grid com
   linha de altura automática, o JS mede a altura real da imagem e grava em
   --pdp-thumbs-max (px), que é o que de fato limita .pdp-thumbs aqui.

   .pdp-thumb-more fica FORA do fluxo do scroll (position:absolute, não
   sticky): com sticky ele é só mais um item da lista, então assim que a
   lista excede a altura disponível ele já nasce "grudado" no fundo — por
   cima da miniatura que naturalmente estaria ali, escondendo ela. Como
   overlay absoluto ele não empurra nem é empurrado por ninguém, e o
   padding-bottom em .pdp-thumbs-scroll reserva o espaço dele no fim da
   lista, garantindo que dá pra rolar até a última miniatura sair
   completamente de baixo dele. */
.pdp-thumbs {
  position: relative;
}

.pdp-thumbs-scroll {
  display: flex;
  flex-direction: column;
  gap: 10px;
  max-height: var(--pdp-thumbs-max, 520px);
  overflow-y: auto;
}

.pdp-thumbs-scroll.has-more-visible {
  padding-bottom: 94px; /* altura do .pdp-thumb-more (84px) + gap (10px) */
}

.pdp-thumb,
.pdp-thumb-more {
  width: 84px;
  height: 84px;
  flex-shrink: 0;
  border: 1px solid var(--pdp-border);
  border-radius: 8px;
  background: var(--surface);
  padding: 4px;
  cursor: pointer;
}

.pdp-thumb.is-active {
  /* border-color: var(--brand-1) solid 1px; */
  /* box-shadow: 0 0 0 1px var(--pdp-text); */
}

.pdp-thumb img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  border-radius: 4px;
}

.pdp-thumb-more {
  display: flex;
  align-items: center;
  justify-content: center;
  color: var(--pdp-muted);
  position: absolute;
  left: 0;
  bottom: 0;
  z-index: 2;
  box-shadow: 0 -8px 10px -4px rgba(0, 0, 0, 0.08);
}

.pdp-thumb-more[hidden] {
  display: none;
}

.pdp-thumb-more svg {
  transition: transform 0.2s ease;
}

.pdp-thumb-more.is-at-end svg {
  transform: rotate(180deg);
}

.pdp-main-image-wrap {
  position: relative;
}

.pdp-main-image {
  width: 100%;
  border: 0;
  padding: 0;
  background: var(--surface);
  border-radius: 12px;
  min-height: 520px;
  display: flex;
  align-items: center;
  justify-content: center;
  overflow: hidden;
  cursor: zoom-in;
}

.pdp-main-image img {
  width: 100%;
  max-height: 520px;
  object-fit: contain;
}

.pdp-gallery-nav {
  position: absolute;
  top: 50%;
  transform: translateY(-50%);
  width: 40px;
  height: 40px;
  border: 0;
  border-radius: 50%;
  background: rgba(255, 255, 255, 0.92);
  box-shadow: 0 2px 10px rgba(0, 0, 0, 0.08);
  display: inline-flex;
  align-items: center;
  justify-content: center;
  cursor: pointer;
  color: var(--pdp-text);
  z-index: 2;
}

.pdp-gallery-prev {
  left: 12px;
}

.pdp-gallery-next {
  right: 12px;
}

.pdp-features {
  /*grid-column: 1 / -1;*/
  list-style: none;
  margin: 18px 0 0;
  padding: 0;
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 12px;
}

.pdp-features li {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 8px;
  text-align: center;
  font-size: 12px;
  color: var(--pdp-muted);
}

.pdp-feature-icon {
  width: 42px;
  height: 42px;
  border-radius: 50%;
  background: var(--surface);
  border: 1px solid var(--pdp-border);
  display: inline-flex;
  align-items: center;
  justify-content: center;
  color: var(--pdp-accent);
}

.pdp-brand {
  margin: 0 0 8px;
  font-size: 12px;
  font-weight: 700;
  letter-spacing: 0.08em;
  color: var(--pdp-accent);
}

.pdp-title-row {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  gap: 16px;
}

.pdp-title {
  margin: 0;
  font-size: clamp(24px, 2.4vw, 34px);
  line-height: 1.15;
  font-weight: 700;
  color: var(--text);
}

.pdp-title-actions {
  display: flex;
  gap: 10px;
  flex-shrink: 0;
  position: relative;
}

.pdp-icon-btn {
  width: 40px;
  height: 40px;
  border: 1px solid var(--pdp-border);
  border-radius: 50%;
  background: var(--surface);
  display: inline-flex;
  align-items: center;
  justify-content: center;
  cursor: pointer;
  color: var(--pdp-text);
}

.pdp-rating-row {
  display: flex;
  align-items: center;
  flex-wrap: wrap;
  gap: 14px;
  margin: 14px 0 22px;
}

.pdp-stars {
  display: inline-flex;
  align-items: center;
  gap: 2px;
}

.pdp-stars strong {
  margin-left: 8px;
  font-size: 14px;
}

.pdp-reviews-link {
  margin-left: 4px;
  color: var(--pdp-muted);
  text-decoration: underline;
  font-size: 14px;
}

.pdp-star {
  color: var(--line);
  display: inline-flex;
}

.pdp-star.is-filled,
.pdp-star.is-half {
  color: var(--orange-400);
}


.pdp-variant {
  margin-bottom: 20px;
}

.pdp-variant-label {
  display: block;
  margin-bottom: 12px;
  font-size: 14px;
}

.pdp-swatches {
  display: flex;
  gap: 12px;
  flex-wrap: wrap;
}

.pdp-swatch {
  position: relative;
  width: 34px;
  height: 34px;
  border-radius: 50%;
  border: 2px solid transparent;
  background: var(--swatch-color, var(--line-strong));
  cursor: pointer;
  padding: 0;
}

.pdp-swatch.is-active {
  border-color: var(--text);
  box-shadow: 0 0 0 2px var(--surface) inset;
}

.pdp-swatch-badge {
  position: absolute;
  top: -18px;
  left: 50%;
  transform: translateX(-50%);
  background: var(--pdp-accent);
  color: var(--surface);
  font-size: 9px;
  font-weight: 700;
  padding: 2px 6px;
  border-radius: 4px;
  white-space: nowrap;
}

.pdp-sizes {
  display: flex;
  gap: 8px;
  flex-wrap: wrap;
}

.pdp-size {
  min-width: 48px;
  height: 42px;
  padding: 0 14px;
  border: 1px solid var(--pdp-border);
  background: var(--surface);
  color: var(--pdp-text);
  font: inherit;
  font-size: 14px;
  font-weight: 700;
  cursor: pointer;
  border-radius: 6px;
}

.pdp-size:hover {
  border-color: var(--pdp-text);
}

.pdp-size.is-active {
  border-color: var(--primary, var(--primary));
  background: var(--primary, var(--primary));
  color: var(--surface);
}

/* Tamanho sem unidades: continua visível para o cliente saber que existe, mas
   não é clicável. */
.pdp-size.is-sold-out {
  color: var(--pdp-muted);
  background: var(--surface-2);
  border-style: dashed;
  cursor: not-allowed;
  position: relative;
}

.pdp-size.is-sold-out::after {
  content: '';
  position: absolute;
  left: 6px;
  right: 6px;
  top: 50%;
  height: 1px;
  background: currentColor;
  opacity: 0.5;
}

.pdp-size.is-sold-out:hover {
  border-color: var(--pdp-border);
}

.pdp-size-stock {
  margin: 10px 0 0;
  font-size: 13px;
  font-weight: 600;
  color: var(--warning);
}

.pdp-size-availability {
  list-style: none;
  margin: 0 0 14px;
  padding: 0;
  display: flex;
  flex-wrap: wrap;
  gap: 8px 18px;
}

.pdp-size-availability li {
  display: flex;
  gap: 6px;
  font-size: 14px;
  color: var(--pdp-muted);
}

.pdp-size-availability strong {
  color: var(--pdp-text);
}

.pdp-sku {
  margin: 0 0 20px;
  font-size: 13px;
  color: var(--pdp-muted);
}

.pdp-promo {
  display: flex;
  gap: 14px;
  align-items: flex-start;
  background: var(--pdp-promo-bg);
  border-radius: 10px;
  padding: 16px 18px;
  margin-bottom: 24px;
}

.pdp-promo-icon {
  color: var(--pdp-accent);
  flex-shrink: 0;
}

.pdp-promo strong {
  display: block;
  margin-bottom: 4px;
  font-size: 15px;
}

.pdp-promo p {
  margin: 0;
  font-size: 13px;
  color: var(--pdp-muted);
  line-height: 1.45;
}

.pdp-summary h2 {
  margin: 0 0 12px;
  font-size: 18px;
}

.pdp-summary p {
  margin: 0 0 14px;
  line-height: 1.6;
  color: var(--text-2);
}

.pdp-summary ul {
  list-style: none;
  margin: 0;
  padding: 0;
}

.pdp-summary li {
  display: flex;
  align-items: flex-start;
  gap: 10px;
  margin-bottom: 10px;
  font-size: 14px;
  line-height: 1.45;
}

.pdp-summary li svg {
  color: var(--pdp-accent);
  flex-shrink: 0;
  margin-top: 2px;
}

.pdp-more-details {
  margin-top: 18px;
  border: 0;
  background: none;
  color: var(--pdp-accent);
  font-weight: 600;
  display: inline-flex;
  align-items: center;
  gap: 6px;
  cursor: pointer;
  padding: 0;
}

.pdp-buy-card {
  position: sticky;
  top: 110px;
  min-width: 0;
  background: var(--surface);
  border: 1px solid var(--pdp-border);
  border-radius: 14px;
  padding: 22px;
  box-shadow: 0 8px 28px rgba(0, 0, 0, 0.06);
}

.pdp-price-old {
  font-size: 16px;
  color: var(--muted);
  text-decoration: line-through;
  margin-bottom: 4px;
}

.pdp-price {
  font-size: 34px;
  font-weight: 800;
  line-height: 1;
  margin-bottom: 8px;
}

.pdp-installments {
  margin: 0 0 18px;
  font-size: 14px;
  color: var(--pdp-muted);
}

.pdp-seller {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 10px;
  font-size: 13px;
  color: var(--pdp-muted);
  padding-bottom: 18px;
  border-bottom: 1px solid var(--pdp-border);
  margin-bottom: 18px;
}

.pdp-seller-check {
  color: var(--danger);
  flex-shrink: 0;
}

.pdp-stock {
  margin: 0 0 16px;
  font-size: 13px;
  font-weight: 600;
}

.pdp-stock--available {
  color: var(--success);
}

.pdp-stock--out {
  color: var(--danger);
}

.pdp-qty-row {
  margin-bottom: 14px;
}

.pdp-qty {
  display: inline-flex;
  align-items: center;
  border: 1px solid var(--pdp-border);
  border-radius: 8px;
  overflow: hidden;
}

.pdp-qty button {
  width: 42px;
  height: 42px;
  border: 0;
  background: var(--surface);
  cursor: pointer;
  display: inline-flex;
  align-items: center;
  justify-content: center;
}

.pdp-qty input {
  width: 52px;
  height: 42px;
  border: 0;
  border-left: 1px solid var(--pdp-border);
  border-right: 1px solid var(--pdp-border);
  text-align: center;
  font-size: 16px;
  font-weight: 600;
  appearance: textfield;
}

.pdp-qty input::-webkit-outer-spin-button,
.pdp-qty input::-webkit-inner-spin-button {
  appearance: none;
  margin: 0;
}

.pdp-add-cart {
  width: 100%;
  height: 52px;
  border: 0;
  border-radius: 8px;
  background: var(--pdp-accent);
  color: var(--surface);
  font-size: 16px;
  font-weight: 700;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 10px;
  cursor: pointer;
}

.pdp-add-cart:hover {
  background: var(--pdp-accent-dark);
}

.pdp-add-cart--disabled,
.pdp-add-cart:disabled {
  background: var(--line-strong);
  color: var(--muted);
  cursor: not-allowed;
}

.pdp-add-cart--disabled:hover,
.pdp-add-cart:disabled:hover {
  background: var(--line-strong);
}

.pdp-cashback {
  display: flex;
  align-items: center;
  gap: 8px;
  margin: 16px 0 20px;
  font-size: 13px;
  color: var(--pdp-muted);
}

.pdp-shipping {
  padding-top: 18px;
  border-top: 1px solid var(--pdp-border);
}

.pdp-shipping h3 {
  margin: 0 0 12px;
  font-size: 15px;
}

.pdp-shipping-form {
  display: flex;
  gap: 8px;
  align-items: stretch;
  width: 100%;
  min-width: 0;
}

.pdp-shipping-form input {
  flex: 1 1 0;
  min-width: 0;
  width: 100%;
  height: 42px;
  border: 1px solid var(--pdp-border);
  border-radius: 8px;
  padding: 0 12px;
  font-size: 16px;
  -webkit-text-size-adjust: 100%;
  text-size-adjust: 100%;
}

.pdp-shipping-form button {
  flex: 0 0 auto;
  height: 42px;
  border: 0;
  border-radius: 8px;
  background: var(--text);
  color: var(--surface);
  padding: 0 14px;
  font-size: 14px;
  font-weight: 700;
  white-space: nowrap;
  cursor: pointer;
}

.pdp-shipping-result {
  margin: 10px 0 0;
  font-size: 13px;
}

.pdp-shipping-result.is-success {
  color: var(--success);
}

.pdp-shipping-result.is-error {
  color: var(--danger);
}

.pdp-shipping-result.is-loading {
  color: var(--muted);
}

.pdp-shipping-options {
  list-style: none;
  margin: 0;
  padding: 0;
  display: grid;
  gap: 8px;
}

.pdp-shipping-options li {
  display: grid;
  gap: 2px;
  padding: 8px 10px;
  border: 1px solid var(--pdp-border);
  border-radius: 8px;
  background: var(--surface-2);
}

.pdp-shipping-option-name {
  font-weight: 700;
  color: var(--text);
}

.pdp-shipping-option-meta {
  color: var(--success);
}

.pdp-trust {
  list-style: none;
  margin: 18px 0 0;
  padding: 0;
  border-top: 1px solid var(--pdp-border);
}

.pdp-trust li {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  padding: 14px 0;
  border-bottom: 1px solid var(--pdp-border);
  font-size: 14px;
}

.pdp-trust li span {
  display: inline-flex;
  align-items: center;
  gap: 10px;
}

.pdp-tabs {
  margin-top: 56px;
  border-top: 1px solid var(--pdp-border);
}

.pdp-tabs-nav {
  display: flex;
  gap: 28px;
  border-bottom: 1px solid var(--pdp-border);
  overflow-x: auto;
}

.pdp-tabs-nav button {
  border: 0;
  background: none;
  padding: 18px 0;
  font-size: 15px;
  font-weight: 600;
  color: var(--pdp-muted);
  cursor: pointer;
  position: relative;
  white-space: nowrap;
}

.pdp-tabs-nav button.is-active {
  color: var(--pdp-text);
}

.pdp-tabs-nav button.is-active::after {
  content: "";
  position: absolute;
  left: 0;
  right: 0;
  bottom: -1px;
  height: 3px;
  background: var(--pdp-accent);
  border-radius: 3px 3px 0 0;
}

.pdp-tab-panels {
  padding-top: 28px;
}

.pdp-tab-panel[hidden] {
  display: none !important;
}

.pdp-tab-content {
  display: grid;
  grid-template-columns: 1.2fr 0.8fr;
  gap: 32px;
  align-items: center;
}

.pdp-tab-content--single {
  grid-template-columns: 1fr;
  max-width: 820px;
}

.pdp-tab-text h2,
.pdp-tab-content--single h2 {
  margin: 0 0 16px;
  font-size: 24px;
}

.pdp-tab-text p,
.pdp-tab-content--single p,
.pdp-tab-content--single ol {
  line-height: 1.7;
  color: var(--text-2);
}

.pdp-tab-media img {
  width: 100%;
  border-radius: 12px;
  object-fit: cover;
  background: var(--surface);
}

.pdp-reviews-summary {
  display: flex;
  align-items: center;
  gap: 18px;
  margin-bottom: 24px;
}

.pdp-reviews-score {
  font-size: 48px;
  font-weight: 800;
  line-height: 1;
}

.pdp-stars--lg {
  margin-bottom: 6px;
}

.pdp-review-card {
  border: 1px solid var(--pdp-border);
  border-radius: 10px;
  padding: 16px;
  margin-bottom: 12px;
}

.pdp-review-card strong {
  display: block;
  margin-bottom: 6px;
}

.pdp-review-card p {
  margin: 10px 0 0;
  color: var(--text-2);
  line-height: 1.55;
}

/* ---------------------------------------------------- avaliar / lista / curtir */
.pdp-review-cta {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  height: 44px;
  padding: 0 20px;
  margin: 16px 0 24px;
  border: 1.5px solid var(--pdp-accent);
  border-radius: 8px;
  background: transparent;
  color: var(--pdp-accent);
  font-size: 14px;
  font-weight: 700;
  cursor: pointer;
  transition: background 0.15s ease, color 0.15s ease;
}

.pdp-review-cta:hover {
  background: var(--pdp-accent);
  color: var(--surface);
}

.pdp-review-list {
  margin-top: 8px;
}

.pdp-review-head {
  display: flex;
  align-items: flex-start;
  gap: 10px;
}

.pdp-review-avatar {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 36px;
  height: 36px;
  flex-shrink: 0;
  border-radius: 50%;
  background: var(--surface-2, #eef3f3);
  color: var(--muted);
}

.pdp-review-head-info {
  flex: 1;
  min-width: 0;
}

.pdp-review-date {
  flex-shrink: 0;
  font-size: 12.5px;
  color: var(--muted);
}

.pdp-review-image-btn {
  display: block;
  width: 72px;
  height: 72px;
  margin-top: 12px;
  padding: 0;
  border: 1px solid var(--pdp-border);
  border-radius: 8px;
  overflow: hidden;
  cursor: pointer;
  background: none;
}

.pdp-review-image-btn img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  display: block;
}

.pdp-review-like {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  margin-top: 12px;
  padding: 0;
  border: 0;
  background: none;
  color: var(--muted);
  font-size: 13px;
  font-weight: 600;
  cursor: pointer;
}

.pdp-review-like svg {
  width: 16px;
  height: 16px;
  transition: fill 0.15s ease, color 0.15s ease;
}

.pdp-review-like:hover svg,
.pdp-review-like.is-liked svg {
  fill: var(--danger, #e0245e);
  color: var(--danger, #e0245e);
}

.pdp-review-like.is-liked {
  color: var(--danger, #e0245e);
}

/* --------------------------------------------------------- lightbox da imagem */
.review-lightbox-overlay {
  position: fixed;
  inset: 0;
  z-index: 1400;
  background: rgba(0, 0, 0, 0.85);
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 24px;
}

.review-lightbox-overlay[hidden] {
  display: none;
}

.review-lightbox-overlay img {
  max-width: 100%;
  max-height: 90vh;
  border-radius: 8px;
}

.review-lightbox-close {
  position: absolute;
  top: 20px;
  right: 24px;
  width: 40px;
  height: 40px;
  border: 0;
  border-radius: 50%;
  background: rgba(255, 255, 255, 0.15);
  color: #fff;
  font-size: 26px;
  line-height: 1;
  cursor: pointer;
}

@media (max-width: 1100px) {
  .pdp-layout {
    grid-template-columns: minmax(0, 1fr) 300px;
  }

  .pdp-details {
    grid-column: 1 / -1;
    order: 2;
  }

  .pdp-gallery {
    order: 1;
  }

  .pdp-buy {
    order: 3;
    grid-column: 2;
    grid-row: 1;
  }
}

@media (max-width: 900px) {
  .pdp {
    padding: 16px 16px 60px;
  }

  .pdp-layout {
    grid-template-columns: 1fr;
  }

  .pdp-buy,
  .pdp-details,
  .pdp-gallery {
    grid-column: auto;
    grid-row: auto;
    order: initial;
  }

  .pdp-gallery {
    grid-template-columns: 56px minmax(0, 1fr);
  }

  /* A coluna de miniaturas encolhe pra 56px aqui pra sobrar mais espaço pra
     imagem — a miniatura precisa acompanhar, senão vaza pra fora da coluna. */
  .pdp-thumb,
  .pdp-thumb-more {
    width: 84px;
    height: 84px;
  }

  .pdp-thumbs-scroll.has-more-visible {
    padding-bottom: 90px; /* altura do .pdp-thumb-more (56px) + gap (10px) */
  }

  .pdp-main-image {
    min-height: 360px;
  }

  .pdp-features {
    grid-template-columns: repeat(2, 1fr);
  }

  .pdp-buy-card {
    position: static;
  }

  .pdp-tab-content {
    grid-template-columns: 1fr;
  }
}

@media (max-width: 600px) {
  .pdp-title-row {
    flex-direction: column;
  }

  .pdp-breadcrumb {
    padding-top: 12px;
  }

  .pdp-tabs-nav {
    gap: 18px;
  }
}

.pdp-lightbox {
  position: fixed;
  inset: 0;
  z-index: 1000;
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 24px;
  background: rgba(0, 0, 0, 0.88);
  opacity: 0;
  visibility: hidden;
  transition: opacity 0.25s ease, visibility 0.25s ease;
}

.pdp-lightbox.is-open {
  opacity: 1;
  visibility: visible;
}

.pdp-lightbox[hidden] {
  display: none !important;
}

.pdp-lightbox-close {
  position: absolute;
  top: 16px;
  right: 16px;
  width: 44px;
  height: 44px;
  border: 0;
  border-radius: 50%;
  background: rgba(255, 255, 255, 0.12);
  color: var(--surface);
  font-size: 28px;
  line-height: 1;
  cursor: pointer;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  z-index: 3;
  transition: background 0.2s ease;
}

.pdp-lightbox-close:hover {
  background: rgba(255, 255, 255, 0.22);
}

.pdp-lightbox-stage {
  position: relative;
  width: min(92vw, 1100px);
  height: min(82vh, 900px);
  display: flex;
  align-items: center;
  justify-content: center;
}

.pdp-lightbox-stage img {
  max-width: 100%;
  max-height: 100%;
  object-fit: contain;
  user-select: none;
  -webkit-user-drag: none;
}

.pdp-lightbox-nav {
  position: absolute;
  top: 50%;
  transform: translateY(-50%);
  width: 48px;
  height: 48px;
  border: 0;
  border-radius: 50%;
  background: var(--teal-700);
  color: var(--surface);
  display: inline-flex;
  align-items: center;
  justify-content: center;
  cursor: pointer;
  z-index: 3;
  box-shadow: 0 2px 10px rgba(0, 0, 0, 0.25);
  transition: background 0.2s ease;
}

.pdp-lightbox-nav:hover {
  background: var(--teal-800);
}

.pdp-lightbox-prev {
  left: 16px;
}

.pdp-lightbox-next {
  right: 16px;
}

.pdp-lightbox-counter {
  position: absolute;
  bottom: 20px;
  left: 50%;
  transform: translateX(-50%);
  padding: 6px 14px;
  border-radius: 999px;
  background: rgba(0, 0, 0, 0.45);
  color: var(--surface);
  font-size: 13px;
  font-weight: 600;
  letter-spacing: 0.04em;
  z-index: 3;
}

/* trava de scroll no <html> — ver style.css */

@media (max-width: 600px) {
  .pdp-lightbox {
    padding: 12px;
  }

  .pdp-lightbox-nav {
    width: 40px;
    height: 40px;
  }

  .pdp-lightbox-prev {
    left: 8px;
  }

  .pdp-lightbox-next {
    right: 8px;
  }

  .pdp-lightbox-close {
    top: 10px;
    right: 10px;
  }
}

/* ==========================================================================
   Produtos similares
   ========================================================================== */
.pdp-similar {
  max-width: calc(var(--container) + var(--gutter) * 2);
  margin: 0 auto;
  padding: 8px var(--gutter) 48px;
}

.pdp-similar .carousel-head {
  display: flex;
  align-items: flex-end;
  justify-content: space-between;
  gap: 20px;
  margin-bottom: 22px;
}

.pdp-similar h2 {
  position: relative;
  margin: 0 0 10px;
  padding-bottom: 10px;
  font-size: 24px;
  font-weight: 800;
  letter-spacing: -0.02em;
  color: var(--text);
}

.pdp-similar h2::after {
  content: '';
  position: absolute;
  left: 0;
  bottom: 0;
  width: 56px;
  height: 3px;
  border-radius: var(--radius-pill);
  background: linear-gradient(90deg, var(--brand-1), var(--brand-2));
}

.pdp-similar .sub {
  margin: 0;
  font-size: 14.5px;
  color: var(--muted);
}

@media (max-width: 900px) {
  .pdp-similar h2 {
    font-size: 21px;
  }
}

/* ==========================================================================
   PÁGINA DE PRODUTO — duas colunas
   As colunas de informação e de compra foram unificadas, o que sobra de
   espaço vai para a galeria.
   ========================================================================== */
.pdp-layout {
  grid-template-columns: minmax(0, 1.35fr) minmax(0, 1fr);
  gap: 40px;
}

.pdp-gallery {
  grid-template-columns: 84px minmax(0, 1fr);
  gap: 14px;
  position: sticky;
  top: 110px;
}

.pdp-main-image {
  min-height: 0;
  aspect-ratio: 1 / 1;
  border-radius: var(--radius-md);
  border: 1px solid var(--pdp-border);
}

.pdp-main-image img {
  max-height: none;
  height: 100%;
}

.pdp-thumb {
  width: 84px;
  height: 84px;
  border-radius: var(--radius-sm);
}

.pdp-details {
  min-width: 0;
}

.pdp-title {
  font-size: 27px;
  line-height: 1.2;
  letter-spacing: -0.02em;
}

.pdp-price-block {
  margin: 18px 0 4px;
}

.pdp-cashback {
  margin-bottom: 18px;
}

/* ------------------------------------------- mini cards de produtos similares */
.pdp-variants {
  margin: 20px 0 22px;
  padding-top: 18px;
  border-top: 1px solid var(--pdp-border);
}

.pdp-variants-list {
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
  margin-top: 10px;
}

.pdp-variant-thumb {
  display: block;
  width: 64px;
  height: 64px;
  padding: 3px;
  border: 1px solid var(--pdp-border);
  border-radius: var(--radius-sm);
  background: var(--surface-2);
  overflow: hidden;
  transition: border-color var(--dur-1) var(--ease), transform var(--dur-1) var(--ease),
    box-shadow var(--dur-1) var(--ease);
}

.pdp-variant-thumb:hover {
  border-color: var(--brand-1);
  transform: translateY(-2px);
  box-shadow: var(--shadow-sm);
}

.pdp-variant-thumb img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  border-radius: calc(var(--radius-sm) - 4px);
  display: block;
}

/* ------------------------------------------------------ numeração redonda */
.pdp-size-head {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  flex-wrap: wrap;
  margin-bottom: 4px;
}

.pdp-size-guide-btn {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  padding: 6px 10px;
  border: 1px solid var(--pdp-border);
  border-radius: var(--radius-pill);
  background: var(--surface);
  color: var(--primary);
  font: inherit;
  font-size: 12.5px;
  font-weight: 700;
  cursor: pointer;
  transition: border-color var(--dur-1) var(--ease), background var(--dur-1) var(--ease);
}

.pdp-size-guide-btn:hover {
  border-color: var(--brand-1);
  background: var(--surface-2);
}

.pdp-sizes {
  gap: 10px;
}

.pdp-size {
  width: 48px;
  min-width: 48px;
  height: 48px;
  padding: 0;
  border-radius: 50%;
  border: 1.5px solid var(--pdp-border);
  font-size: 14px;
  font-weight: 700;
  color: var(--text-2);
  transition: border-color var(--dur-1) var(--ease), background var(--dur-1) var(--ease),
    color var(--dur-1) var(--ease), transform var(--dur-1) var(--ease);
}

.pdp-size:hover:not(.is-sold-out) {
  border-color: var(--brand-1);
  /*color: var(--primary);*/
}

.pdp-size.is-active {
  background: var(--primary);
  border-color: var(--primary);
  color: var(--on-primary);
  transform: scale(1.04);
}

.pdp-size.is-sold-out {
  border-style: solid;
  border-color: var(--pdp-border);
  background: var(--surface-2);
  color: var(--muted);
}

.pdp-size.is-sold-out::after {
  left: 9px;
  right: 9px;
  transform: rotate(-38deg);
}

/* ------------------------------------------- quantidade + comprar na mesma linha */
.pdp-buy-row {
  display: flex;
  align-items: stretch;
  gap: 12px;
  margin: 24px 0 14px;
}

.pdp-buy-row .pdp-qty {
  flex: 0 0 auto;
  height: 54px;
  border-radius: var(--radius-sm);
}

.pdp-buy-row .pdp-add-cart {
  flex: 1;
  height: 54px;
  margin: 0;
  border-radius: var(--radius-sm);
}

.pdp-shipping {
  margin-top: 6px;
  padding: 18px;
  border: 1px solid var(--pdp-border);
  border-radius: var(--radius-md);
  background: var(--surface-2);
}

.pdp-trust {
  margin-top: 16px;
}

.pdp-trust li {
  cursor: default;
}

/* ==========================================================================
   Modal da tabela de medidas
   ========================================================================== */
html.size-guide-open {
  overflow: hidden;
}

.size-guide-overlay {
  position: fixed;
  inset: 0;
  z-index: 1300;
  background: var(--overlay);
  backdrop-filter: blur(2px);
}

.size-guide {
  position: fixed;
  z-index: 1301;
  left: 50%;
  top: 50%;
  transform: translate(-50%, -46%);
  width: min(440px, calc(100vw - 32px));
  max-height: calc(100vh - 40px);
  overflow-y: auto;
  padding: 28px 26px 24px;
  background: var(--surface);
  border-radius: var(--radius-lg);
  box-shadow: var(--shadow-lg);
  opacity: 0;
  transition: opacity 0.2s ease, transform 0.2s ease;
}

.size-guide.is-open {
  opacity: 1;
  transform: translate(-50%, -50%);
}

.size-guide-close {
  position: absolute;
  top: 10px;
  right: 12px;
  width: 36px;
  height: 36px;
  border: 0;
  background: none;
  font-size: 28px;
  line-height: 1;
  color: var(--muted);
  cursor: pointer;
}

.size-guide-close:hover {
  color: var(--primary);
}

.size-guide h3 {
  margin: 0 0 16px;
  font-size: 19px;
  font-weight: 800;
  color: var(--text);
}

.size-guide-help {
  padding: 14px 16px;
  margin-bottom: 18px;
  border-radius: var(--radius-sm);
  background: var(--surface-2);
  border: 1px solid var(--pdp-border);
}

.size-guide-help strong {
  display: block;
  font-size: 14px;
  color: var(--text);
}

.size-guide-help p {
  margin: 4px 0 0;
  font-size: 13.5px;
  line-height: 1.5;
  color: var(--muted);
}

.size-guide-table-wrap {
  overflow-x: auto;
}

.size-guide-table {
  width: 100%;
  border-collapse: collapse;
  font-size: 14px;
}

.size-guide-table th {
  text-align: left;
  padding: 10px 12px;
  background: var(--primary);
  color: var(--on-primary);
  font-size: 12px;
  font-weight: 800;
  letter-spacing: 0.04em;
  text-transform: uppercase;
}

.size-guide-table th:first-child {
  border-radius: var(--radius-xs) 0 0 0;
}

.size-guide-table th:last-child {
  border-radius: 0 var(--radius-xs) 0 0;
}

.size-guide-table td {
  padding: 10px 12px;
  border-bottom: 1px solid var(--pdp-border);
  color: var(--text-2);
}

.size-guide-table tbody tr:nth-child(odd) td {
  background: var(--surface-2);
}

.size-guide-table td:first-child {
  font-weight: 800;
  color: var(--text);
}

.size-guide-note {
  margin: 16px 0 0;
  font-size: 13px;
  line-height: 1.5;
  color: var(--muted);
}

/* --------------------------------------------------------------- responsivo */
@media (max-width: 960px) {
  .pdp-layout {
    grid-template-columns: minmax(0, 1fr);
    gap: 28px;
  }

  .pdp-gallery {
    position: static;
  }

  .pdp-title {
    font-size: 23px;
  }
}

@media (max-width: 600px) {
  .pdp-buy-row {
    flex-wrap: wrap;
  }

  .pdp-buy-row .pdp-qty,
  .pdp-buy-row .pdp-add-cart {
    width: 100%;
    flex: 1 1 100%;
  }

  .size-guide {
    top: auto;
    bottom: 0;
    transform: translate(-50%, 100%);
    width: 100vw;
    max-height: 88vh;
    border-radius: var(--radius-lg) var(--radius-lg) 0 0;
    padding: 24px 18px 20px;
  }

  .size-guide.is-open {
    transform: translate(-50%, 0);
  }
}
