/* =========================================================
   PETRA MOBILIÁRIO — CATÁLOGO DIGITAL
   catalogo.css
   ========================================================= */

@import url('fonts.css');

/* RESET */

* {
  margin: 0;
  padding: 0;
  box-sizing: border-box;
}

:root {
  --bg: #f3eee7;
  --bg-light: #f8f5f0;
  --bg-card: #eee8df;
  --text: #1d1814;
  --muted: #665a50;
  --soft-muted: #8b8178;
  --accent: #8a6241;
  --line: rgba(29, 24, 20, 0.18);
  --line-strong: rgba(29, 24, 20, 0.28);
  --white: #ffffff;
  --font-display: "NewTitle", "Cormorant Garamond", "Georgia", serif;
  --font-body: "Bricolage Grotesque", "Segoe UI", Arial, Helvetica, sans-serif;
}

/* rolagem suave desativada — deixava o scroll "preso" no mouse/Windows */

body {
  font-family: var(--font-body);
  background: var(--bg);
  color: var(--text);
}

img {
  display: block;
  width: 100%;
}

a {
  color: inherit;
  text-decoration: none;
}

button {
  font-family: inherit;
}

/* =========================================================
   HERO GERAL
   ========================================================= */

.catalog-hero {
  position: relative;
  min-height: 430px;
  height: 52vh;
  background-image: url("img/hero-catalogo.webp");
  background-size: cover;
  background-position: center;
  overflow: hidden;
}

.hero-overlay {
  position: absolute;
  inset: 0;
  background:
    linear-gradient(
      90deg,
      rgba(30, 22, 17, 0.72) 0%,
      rgba(30, 22, 17, 0.36) 46%,
      rgba(30, 22, 17, 0.50) 100%
    ),
    linear-gradient(
      180deg,
      rgba(0, 0, 0, 0.20) 0%,
      rgba(0, 0, 0, 0.04) 45%,
      rgba(0, 0, 0, 0.36) 100%
    );
}

.hero-inner {
  position: relative;
  z-index: 2;
  width: min(1220px, calc(100% - 56px));
  height: 100%;
  margin: 0 auto;
  color: var(--white);
  display: flex;
  flex-direction: column;
  justify-content: space-between;
  padding: 38px 0 70px;
}

.hero-top {
  display: flex;
  align-items: center;
  justify-content: space-between;
}

.brand-name {
  font-size: 0.76rem;
  text-transform: uppercase;
  letter-spacing: 0.28em;
  font-weight: 500;
}

.hero-title {
  max-width: 720px;
}

.hero-logo {
  display: block;
  width: auto;
  max-width: 110px;
  height: auto;
  margin-bottom: 24px;
  filter: brightness(0) invert(1);
  opacity: 0.92;
}

@media (max-width: 768px) {
  .hero-logo {
    max-width: 80px;
    margin-bottom: 16px;
  }
}

.hero-subtitle {
  display: block;
  font-size: 0.74rem;
  text-transform: uppercase;
  letter-spacing: 0.32em;
  margin-bottom: 22px;
  color: rgba(255, 255, 255, 0.78);
}

.hero-title h1 {
  font-family: var(--font-display);
  font-size: clamp(4.4rem, 10vw, 9rem);
  line-height: 0.9;
  font-weight: 300;
  letter-spacing: -0.035em;
}

/* =========================================================
   PÁGINA PRINCIPAL DO CATÁLOGO
   ========================================================= */

.catalog-page {
  width: min(1220px, calc(100% - 56px));
  margin: 0 auto;
  padding: 86px 0 110px;
}

/* INTRO */

.catalog-intro {
  display: grid;
  grid-template-columns: 220px 1fr;
  gap: 60px;
  align-items: start;
  margin-bottom: 76px;
}

.small-label {
  font-size: 0.72rem;
  text-transform: uppercase;
  letter-spacing: 0.28em;
  color: var(--accent);
  padding-top: 16px;
}

.intro-content {
  max-width: 640px;
}

.intro-content h2 {
  font-family: var(--font-display);
  font-size: clamp(2.4rem, 5.4vw, 5.4rem);
  line-height: 1;
  font-weight: 300;
  letter-spacing: -0.025em;
  margin-bottom: 28px;
}

.intro-content p {
  font-size: 1rem;
  line-height: 1.8;
  color: var(--muted);
  max-width: 500px;
}

/* =========================================================
   CATEGORIAS — PRIMEIRA PÁGINA
   ========================================================= */

.categories-section {
  width: 100%;
}

.categories-grid {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 58px 34px;
}

.category-card {
  display: block;
  cursor: pointer;
}

.category-image {
  width: 100%;
  aspect-ratio: 1 / 1.18;
  background: #dfd2c4;
  overflow: hidden;
}

.category-image img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  object-position: center;
  transition: transform 0.8s ease, filter 0.8s ease;
}

.category-info {
  padding-top: 18px;
  padding-bottom: 14px;
  border-bottom: 1px solid var(--line-strong);
  display: flex;
  align-items: flex-end;
  justify-content: space-between;
  gap: 16px;
}

.category-info h3 {
  font-size: 1.02rem;
  font-weight: 400;
  letter-spacing: 0.01em;
}

.category-info span {
  font-size: 0.62rem;
  text-transform: uppercase;
  letter-spacing: 0.18em;
  color: var(--accent);
  opacity: 0;
  transform: translateX(-8px);
  transition: opacity 0.35s ease, transform 0.35s ease;
  white-space: nowrap;
}

.category-card:hover .category-image img {
  transform: scale(1.04);
  filter: contrast(1.04) saturate(1.02);
}

.category-card:hover .category-info span {
  opacity: 1;
  transform: translateX(0);
}

/* =========================================================
   PÁGINA DE CATEGORIA
   ========================================================= */

.category-hero {
  min-height: 390px;
  height: 46vh;
}

.back-link {
  color: var(--white);
  font-size: 0.72rem;
  text-transform: uppercase;
  letter-spacing: 0.22em;
  opacity: 0.82;
  transition: opacity 0.3s ease;
}

.back-link:hover {
  opacity: 1;
}

.category-header {
  display: grid;
  grid-template-columns: 1fr 420px;
  gap: 60px;
  align-items: end;
  margin-bottom: 78px;
}

.category-header h2 {
  font-family: var(--font-display);
  font-size: clamp(2.6rem, 5.4vw, 5.8rem);
  line-height: 1;
  font-weight: 300;
  letter-spacing: -0.025em;
}

.category-header p {
  font-size: 1rem;
  line-height: 1.8;
  color: var(--muted);
  padding-bottom: 10px;
}

/* =========================================================
   PRODUTOS — GRADE DA CATEGORIA
   ========================================================= */

.products-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 68px 42px;
}

.product-card {
  display: block;
  cursor: pointer;
}

.product-image {
  width: 100%;
  aspect-ratio: 1280 / 1600;
  background: var(--bg-light);
  overflow: hidden;
}

.product-image img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  object-position: center;
  padding: 0;
  transition: transform 0.8s ease, filter 0.8s ease;
}

.product-card:hover .product-image img {
  transform: scale(1.035);
  filter: contrast(1.03);
}

.product-info {
  border-bottom: 1px solid var(--line-strong);
  padding: 16px 0 13px;
  display: flex;
  justify-content: space-between;
  align-items: flex-end;
  gap: 16px;
}

.product-info h3 {
  font-size: 1.02rem;
  font-weight: 400;
  letter-spacing: 0.01em;
}

.product-info span {
  font-size: 0.62rem;
  text-transform: uppercase;
  letter-spacing: 0.18em;
  color: var(--accent);
  opacity: 0;
  transform: translateX(-8px);
  transition: opacity 0.35s ease, transform 0.35s ease;
  white-space: nowrap;
}

.product-card:hover .product-info span {
  opacity: 1;
  transform: translateX(0);
}

/* CATEGORIA VAZIA */

.empty-category {
  padding: 80px 0;
  max-width: 520px;
}

.empty-category h2 {
  font-family: var(--font-display);
  font-size: 2.6rem;
  font-weight: 300;
  letter-spacing: -0.02em;
  margin-bottom: 18px;
}

.empty-category p {
  color: var(--muted);
  line-height: 1.7;
  margin-bottom: 28px;
}

.empty-category a {
  display: inline-block;
  border-bottom: 1px solid var(--text);
  padding-bottom: 8px;
  font-size: 0.76rem;
  text-transform: uppercase;
  letter-spacing: 0.18em;
}

/* =========================================================
   PÁGINA DO PRODUTO
   ========================================================= */

.product-page {
  min-height: 100vh;
  background: var(--bg);
  color: var(--text);
  width: min(1320px, calc(100% - 56px));
  margin: 0 auto;
  padding: 38px 0 72px;
}

.product-top {
  display: flex;
  align-items: center;
  justify-content: space-between;
  margin-bottom: 54px;
}

.product-back,
.product-catalog-link {
  font-size: 0.72rem;
  text-transform: uppercase;
  letter-spacing: 0.22em;
  color: var(--text);
  opacity: 0.76;
  transition: opacity 0.3s ease;
}

.product-back:hover,
.product-catalog-link:hover {
  opacity: 1;
}

.product-view {
  display: grid;
  grid-template-columns: minmax(0, 1.35fr) 430px;
  gap: 70px;
  align-items: center;
  min-height: calc(100vh - 180px);
}

/* GALERIA DO PRODUTO */

.product-gallery {
  position: relative;
  min-width: 0;
}

.gallery-viewport {
  width: 100%;
  overflow: hidden;
  cursor: grab;
  /* permite rolagem vertical da página; só captura gesto horizontal (swipe) */
  touch-action: pan-y;
}

.gallery-viewport.dragging {
  cursor: grabbing;
}

.gallery-track {
  display: flex;
  transition: transform 0.55s ease;
  will-change: transform;
}

.gallery-slide {
  min-width: 100%;
  display: flex;
  align-items: center;
  justify-content: center;
  background: var(--bg-light);
  aspect-ratio: 1280 / 1600;
  overflow: hidden;
  cursor: zoom-in;
}

.gallery-viewport.dragging .gallery-slide {
  cursor: grabbing;
}

.gallery-slide img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  object-position: center;
  padding: 0;
  user-select: none;
  pointer-events: none;
}

.gallery-arrow {
  position: absolute;
  top: 50%;
  transform: translateY(-50%);
  z-index: 5;
  border: none;
  background: transparent;
  color: var(--text);
  font-size: 2.2rem;
  font-weight: 300;
  cursor: pointer;
  opacity: 0.72;
  transition: opacity 0.3s ease;
}

.gallery-arrow:hover {
  opacity: 1;
}

.gallery-prev {
  left: -34px;
}

.gallery-next {
  right: -34px;
}

.gallery-dots {
  display: flex;
  justify-content: center;
  gap: 10px;
  margin-top: 24px;
}

.gallery-dot {
  width: 28px;
  height: 1px;
  border: none;
  background: rgba(29, 24, 20, 0.28);
  cursor: pointer;
  transition: background 0.3s ease, width 0.3s ease;
}

.gallery-dot.active {
  width: 42px;
  background: var(--accent);
}

/* DETALHES DO PRODUTO */

.product-details {
  align-self: center;
}

.product-category {
  display: block;
  font-size: 0.72rem;
  text-transform: uppercase;
  letter-spacing: 0.28em;
  color: var(--accent);
  margin-bottom: 24px;
}

.product-details h1 {
  font-family: var(--font-display);
  font-size: clamp(2.9rem, 5.4vw, 5.6rem);
  line-height: 1;
  font-weight: 300;
  letter-spacing: -0.025em;
  margin-bottom: 30px;
}

.product-description {
  font-size: 1rem;
  line-height: 1.8;
  color: var(--muted);
  margin-bottom: 46px;
}

.specs-block {
  border-top: 1px solid var(--line);
  padding-top: 28px;
  margin-bottom: 42px;
}

.specs-block h2 {
  font-size: 0.72rem;
  text-transform: uppercase;
  letter-spacing: 0.24em;
  color: var(--accent);
  font-weight: 500;
  margin-bottom: 24px;
}

.specs-list {
  display: grid;
}

.specs-list div {
  display: flex;
  align-items: center;
  justify-content: space-between;
  border-bottom: 1px solid rgba(29, 24, 20, 0.12);
  padding: 14px 0;
}

.specs-list dt {
  font-size: 0.84rem;
  color: var(--muted);
}

.specs-list dd {
  font-size: 0.92rem;
  color: var(--text);
}

.contact-button {
  display: inline-flex;
  width: 100%;
  align-items: center;
  justify-content: center;
  min-height: 52px;
  border: 1px solid var(--text);
  background: var(--text);
  color: var(--bg);
  font-size: 0.72rem;
  text-transform: uppercase;
  letter-spacing: 0.22em;
  transition: background 0.35s ease, color 0.35s ease;
}

.contact-button:hover {
  background: transparent;
  color: var(--text);
}

/* =========================================================
   TAG LANCAMENTO
   ========================================================= */

.product-image {
  position: relative;
}

.tag-lancamento {
  position: absolute;
  top: 12px;
  left: 12px;
  background: var(--accent);
  color: #fff;
  font-size: 0.6rem;
  letter-spacing: 0.18em;
  text-transform: uppercase;
  padding: 5px 10px;
  z-index: 3;
  font-weight: 500;
  pointer-events: none;
}

.tag-lancamento-detalhe {
  position: static;
  display: inline-block;
  vertical-align: middle;
  margin-left: 14px;
  font-size: 0.62rem;
  padding: 5px 10px;
  letter-spacing: 0.2em;
}

@media (max-width: 768px) {
  .tag-lancamento {
    top: 8px;
    left: 8px;
    font-size: 0.55rem;
    padding: 4px 8px;
  }
}

/* =========================================================
   AÇÕES DO PRODUTO (botão download + contato)
   ========================================================= */

.product-actions {
  display: flex;
  flex-direction: column;
  gap: 10px;
}

.btn-download {
  background: transparent;
  color: var(--text);
  border: 1px solid var(--text);
  cursor: pointer;
}

.btn-download:hover {
  background: var(--text);
  color: var(--bg);
}

.btn-download:disabled {
  opacity: 0.5;
  cursor: progress;
}

/* =========================================================
   BARRA DE BUSCA (nome ou código)
   ========================================================= */
.busca-form {
  display: flex;
  align-items: center;
  gap: 8px;
  width: 100%;
  max-width: 480px;
  margin: 24px auto 0;
  background: var(--white);
  border: 1px solid var(--line);
  border-radius: 999px;
  padding: 6px 6px 6px 18px;
  box-shadow: 0 8px 26px rgba(29, 24, 20, 0.12);
}
.busca-icon { display: flex; color: var(--soft-muted); flex-shrink: 0; }
.busca-icon svg { width: 18px; height: 18px; }
.busca-input {
  flex: 1;
  min-width: 0;
  border: none;
  outline: none;
  background: transparent;
  font-family: inherit;
  font-size: 0.95rem;
  color: var(--text);
  padding: 9px 4px;
}
.busca-input::placeholder { color: var(--soft-muted); }
.busca-btn {
  flex-shrink: 0;
  border: none;
  cursor: pointer;
  background: var(--accent);
  color: #fff;
  border-radius: 999px;
  padding: 11px 22px;
  font-family: inherit;
  font-size: 0.7rem;
  letter-spacing: 0.18em;
  text-transform: uppercase;
  transition: background 0.3s ease;
}
.busca-btn:hover { background: var(--text); }

.product-info-meta {
  display: block;
  font-size: 0.74rem;
  color: var(--soft-muted);
  letter-spacing: 0.03em;
  margin-top: 5px;
}

@media (max-width: 560px) {
  .busca-btn { padding: 11px 16px; font-size: 0; letter-spacing: 0; }
  .busca-btn::after { content: "🔍"; font-size: 15px; }
}

.product-codigo {
  display: inline-block;
  font-size: 0.78rem;
  letter-spacing: 0.08em;
  color: var(--muted);
  background: var(--bg-card);
  border: 1px solid var(--line);
  border-radius: 6px;
  padding: 4px 11px;
  margin-bottom: 22px;
  font-weight: 600;
}

.btn-share {
  background: var(--accent);
  color: #fff;
  border: 1px solid var(--accent);
  cursor: pointer;
}
.btn-share:hover {
  background: transparent;
  color: var(--accent);
}
.btn-share:disabled {
  opacity: 0.6;
  cursor: progress;
}

.contact-button-ghost {
  background: transparent;
  color: var(--text);
}
.contact-button-ghost:hover {
  background: var(--text);
  color: var(--bg);
}

/* =========================================================
   LEGENDA DA GALERIA + CHIPS DE MEDIDA + MÓDULOS
   ========================================================= */

.gallery-caption {
  text-align: center;
  margin-top: 16px;
  min-height: 1.2em;
  font-size: 0.78rem;
  letter-spacing: 0.16em;
  text-transform: uppercase;
  color: var(--accent);
  font-weight: 500;
}

.specs-head {
  display: flex;
  align-items: baseline;
  justify-content: space-between;
  gap: 12px;
  margin-bottom: 24px;
}
.specs-head h2 {
  margin-bottom: 0;
}
.specs-current {
  font-size: 0.72rem;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  color: var(--soft-muted);
}

.specs-list dd {
  display: flex;
  flex-wrap: wrap;
  gap: 6px;
  justify-content: flex-end;
}
.spec-chip {
  display: inline-block;
  background: var(--bg-card);
  border: 1px solid var(--line);
  border-radius: 999px;
  padding: 3px 11px;
  font-size: 0.82rem;
  color: var(--text);
  white-space: nowrap;
}

.modulos-block {
  border-top: 1px solid var(--line);
  padding-top: 28px;
  margin-bottom: 42px;
}
.modulos-block h2 {
  font-size: 0.72rem;
  text-transform: uppercase;
  letter-spacing: 0.24em;
  color: var(--accent);
  font-weight: 500;
  margin-bottom: 12px;
}
.modulos-hint {
  font-size: 0.84rem;
  color: var(--muted);
  line-height: 1.6;
  margin-bottom: 18px;
}
.modulos-list {
  list-style: none;
  display: grid;
  gap: 10px;
}
.modulo-item {
  border: 1px solid var(--line);
  border-radius: 12px;
  padding: 12px 14px;
  background: var(--bg-light);
}
.modulo-nome {
  font-weight: 600;
  font-size: 0.95rem;
  display: flex;
  align-items: center;
  gap: 10px;
}
.modulo-cod {
  font-size: 0.62rem;
  letter-spacing: 0.06em;
  background: var(--bg-card);
  border: 1px solid var(--line);
  color: var(--muted);
  padding: 2px 8px;
  border-radius: 6px;
  font-weight: 600;
}
.modulo-badge {
  font-size: 0.58rem;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  background: var(--accent);
  color: #fff;
  padding: 2px 8px;
  border-radius: 999px;
  font-weight: 500;
}
.modulo-medidas {
  margin-top: 7px;
  display: flex;
  flex-wrap: wrap;
  gap: 4px 16px;
  font-size: 0.84rem;
  color: var(--muted);
}
.modulo-medida b {
  color: var(--text);
  font-weight: 600;
}
.modulo-medidas-vazio {
  font-style: italic;
  color: var(--soft-muted);
}

/* Toast (fallback de download/legenda) */
.petra-toast {
  position: fixed;
  left: 50%;
  bottom: 28px;
  transform: translateX(-50%) translateY(20px);
  background: var(--text);
  color: var(--bg);
  padding: 13px 22px;
  border-radius: 10px;
  font-size: 0.86rem;
  max-width: 90vw;
  text-align: center;
  z-index: 9999;
  opacity: 0;
  pointer-events: none;
  transition: opacity 0.3s ease, transform 0.3s ease;
}
.petra-toast.show {
  opacity: 1;
  transform: translateX(-50%) translateY(0);
}

/* =========================================================
   LOGO NO TOPO DA PAGINA DE PRODUTO
   ========================================================= */

.product-top {
  align-items: center;
}

.product-top-logo {
  display: block;
  width: 90px;
  height: auto;
  flex: 0 0 auto;
}

.product-top-logo img {
  width: 100%;
  height: auto;
  display: block;
}

@media (max-width: 768px) {
  .product-top-logo {
    width: 60px;
  }
}

/* =========================================================
   ORIENTACAO POR CATEGORIA — PAISAGEM PARA PECAS LARGAS
   ========================================================= */

body.cat-sofas .product-image,
body.cat-sofas .gallery-slide,
body.cat-sofas-modulares .product-image,
body.cat-sofas-modulares .gallery-slide,
body.cat-mesas .product-image,
body.cat-mesas .gallery-slide,
body.cat-mesas-de-centro .product-image,
body.cat-mesas-de-centro .gallery-slide,
body.cat-mesas-laterais .product-image,
body.cat-mesas-laterais .gallery-slide,
body.cat-aparadores .product-image,
body.cat-aparadores .gallery-slide,
body.cat-buffets .product-image,
body.cat-buffets .gallery-slide,
body.cat-bancos .product-image,
body.cat-bancos .gallery-slide,
body.cat-outros .product-image,
body.cat-outros .gallery-slide,
body.cat-bares .product-image,
body.cat-bares .gallery-slide {
  aspect-ratio: 4 / 3;
}

/* =========================================================
   LIGHTBOX / ZOOM DA GALERIA DO PRODUTO
   ========================================================= */

.lightbox {
  position: fixed;
  inset: 0;
  background: rgba(18, 14, 11, 0.94);
  z-index: 1000;
  display: none;
  align-items: center;
  justify-content: center;
  opacity: 0;
  transition: opacity 0.3s ease;
  overscroll-behavior: contain;
}

.lightbox.active {
  display: flex;
  opacity: 1;
}

.lightbox-content {
  position: relative;
  width: 100%;
  height: 100%;
  display: flex;
  align-items: center;
  justify-content: center;
  overflow: hidden;
  padding: 24px;
}

.lightbox-image {
  max-width: 92vw;
  max-height: 90vh;
  width: auto;
  height: auto;
  object-fit: contain;
  cursor: zoom-in;
  transition: transform 0.45s ease;
  user-select: none;
  -webkit-user-drag: none;
  display: block;
}

.lightbox-image.zoomed {
  transform: scale(2);
  cursor: zoom-out;
}

.lightbox-close {
  position: fixed;
  top: 22px;
  right: 22px;
  width: 46px;
  height: 46px;
  border-radius: 50%;
  background: rgba(255, 255, 255, 0.12);
  border: 1px solid rgba(255, 255, 255, 0.3);
  color: #fff;
  font-size: 1.5rem;
  line-height: 1;
  cursor: pointer;
  z-index: 1002;
  display: flex;
  align-items: center;
  justify-content: center;
  transition: background 0.3s ease, transform 0.3s ease;
}

.lightbox-close:hover {
  background: rgba(255, 255, 255, 0.22);
  transform: rotate(90deg);
}

.lightbox-hint {
  position: fixed;
  bottom: 24px;
  left: 50%;
  transform: translateX(-50%);
  color: rgba(255, 255, 255, 0.62);
  font-size: 0.62rem;
  text-transform: uppercase;
  letter-spacing: 0.28em;
  pointer-events: none;
  z-index: 1001;
}

body.lightbox-open {
  overflow: hidden;
}

@media (max-width: 700px) {
  .lightbox-content {
    padding: 12px;
  }

  .lightbox-image {
    max-width: 96vw;
    max-height: 86vh;
  }

  .lightbox-close {
    top: 14px;
    right: 14px;
    width: 40px;
    height: 40px;
    font-size: 1.3rem;
  }

  .lightbox-hint {
    font-size: 0.58rem;
    letter-spacing: 0.22em;
    bottom: 16px;
  }
}

/* =========================================================
   FOOTER
   ========================================================= */

.catalog-footer {
  border-top: 1px solid rgba(29, 24, 20, 0.12);
  padding: 34px 28px;
  display: flex;
  justify-content: space-between;
  align-items: center;
  color: #5c5047;
  font-size: 0.78rem;
  letter-spacing: 0.08em;
  text-transform: uppercase;
}

.catalog-footer div {
  display: flex;
  gap: 18px;
  align-items: center;
}

.catalog-footer strong {
  font-weight: 500;
  color: var(--text);
}

.catalog-footer span {
  color: var(--soft-muted);
}

.catalog-footer a {
  color: var(--accent);
}

/* =========================================================
   ANIMAÇÃO
   ========================================================= */

.reveal {
  opacity: 0;
  transform: translateY(24px);
  transition: opacity 0.8s ease, transform 0.8s ease;
}

.reveal.visible {
  opacity: 1;
  transform: translateY(0);
}

/* =========================================================
   RESPONSIVO — TABLET
   ========================================================= */

@media (max-width: 1100px) {
  .categories-grid {
    grid-template-columns: repeat(3, 1fr);
    gap: 50px 28px;
  }

  .catalog-intro {
    grid-template-columns: 160px 1fr;
    gap: 40px;
  }

  .category-header {
    grid-template-columns: 1fr;
    gap: 28px;
    margin-bottom: 58px;
  }

  .category-header p {
    max-width: 560px;
  }

  .products-grid {
    grid-template-columns: repeat(2, 1fr);
    gap: 54px 28px;
  }

  .product-view {
    grid-template-columns: minmax(0, 1fr);
    gap: 54px;
    min-height: auto;
  }

  .product-details {
    max-width: 620px;
  }

  .gallery-prev {
    left: 10px;
  }

  .gallery-next {
    right: 10px;
  }

  .gallery-arrow {
    background: rgba(243, 238, 231, 0.72);
    width: 48px;
    height: 48px;
    font-size: 1.6rem;
  }
}

/* =========================================================
   RESPONSIVO — MOBILE
   ========================================================= */

@media (max-width: 768px) {
  .catalog-hero {
    min-height: 340px;
    height: 48vh;
    background-position: center;
  }

  .category-hero {
    min-height: 310px;
    height: 42vh;
  }

  .hero-inner {
    width: calc(100% - 32px);
    padding: 28px 0 48px;
  }

  .brand-name {
    font-size: 0.66rem;
    letter-spacing: 0.22em;
  }

  .hero-subtitle {
    font-size: 0.64rem;
    letter-spacing: 0.24em;
    margin-bottom: 18px;
  }

  .hero-title h1 {
    font-size: clamp(4rem, 20vw, 5.8rem);
  }

  .back-link {
    font-size: 0.66rem;
    letter-spacing: 0.18em;
  }

  .catalog-page {
    width: calc(100% - 32px);
    padding: 58px 0 78px;
  }

  .catalog-intro {
    display: block;
    margin-bottom: 48px;
  }

  .small-label {
    display: block;
    padding-top: 0;
    margin-bottom: 20px;
    font-size: 0.66rem;
  }

  .intro-content h2 {
    font-size: 2.65rem;
    margin-bottom: 20px;
  }

  .intro-content p {
    font-size: 0.94rem;
    line-height: 1.7;
  }

  .categories-grid {
    grid-template-columns: repeat(2, 1fr);
    gap: 38px 14px;
  }

  .category-image {
    aspect-ratio: 1 / 1.22;
  }

  .category-info {
    display: block;
    padding-top: 14px;
    padding-bottom: 12px;
  }

  .category-info h3 {
    font-size: 0.92rem;
  }

  .category-info span {
    display: none;
  }

  .category-header {
    margin-bottom: 46px;
  }

  .category-header h2 {
    font-size: 2.7rem;
  }

  .category-header p {
    font-size: 0.94rem;
    line-height: 1.7;
  }

  .products-grid {
    grid-template-columns: repeat(2, 1fr);
    gap: 38px 14px;
  }

  .product-image {
    aspect-ratio: 1280 / 1600;
  }

  .product-info {
    display: block;
    padding: 13px 0 11px;
  }

  .product-info h3 {
    font-size: 0.9rem;
    line-height: 1.35;
  }

  .product-info span {
    display: none;
  }

  .product-page {
    width: calc(100% - 28px);
    padding: 26px 0 56px;
  }

  .product-top {
    margin-bottom: 34px;
  }

  .product-back,
  .product-catalog-link {
    font-size: 0.64rem;
    letter-spacing: 0.18em;
  }

  .product-view {
    gap: 42px;
  }

  .gallery-slide {
    aspect-ratio: 1280 / 1600;
  }

  .gallery-slide img {
    padding: 0px;
  }

  .gallery-arrow {
    width: 40px;
    height: 40px;
    font-size: 1.35rem;
  }

  .gallery-prev {
    left: 0;
  }

  .gallery-next {
    right: 0;
  }

  .gallery-dots {
    margin-top: 18px;
  }

  .gallery-dot {
    width: 22px;
  }

  .gallery-dot.active {
    width: 36px;
  }

  .product-category {
    font-size: 0.66rem;
    letter-spacing: 0.22em;
    margin-bottom: 18px;
  }

  .product-details h1 {
    font-size: 2.65rem;
    margin-bottom: 24px;
  }

  .product-description {
    font-size: 0.94rem;
    line-height: 1.7;
    margin-bottom: 34px;
  }

  .specs-block {
    padding-top: 24px;
    margin-bottom: 34px;
  }

  .contact-button {
    min-height: 50px;
    font-size: 0.66rem;
    letter-spacing: 0.18em;
  }

  .catalog-footer {
    flex-direction: column;
    gap: 16px;
    text-align: center;
    font-size: 0.68rem;
    padding: 30px 20px;
  }

  .catalog-footer div {
    flex-direction: column;
    gap: 8px;
  }
}

/* =========================================================
   RESPONSIVO — MOBILE PEQUENO
   ========================================================= */

@media (max-width: 430px) {
  .catalog-hero {
    min-height: 310px;
  }

  .category-hero {
    min-height: 285px;
  }

  .hero-inner {
    width: calc(100% - 26px);
  }

  .catalog-page {
    width: calc(100% - 26px);
  }

  .categories-grid {
    gap: 34px 12px;
  }

  .intro-content h2 {
    font-size: 2.35rem;
  }

  .category-info h3 {
    font-size: 0.86rem;
  }

  .category-header h2 {
    font-size: 2.35rem;
  }

  .products-grid {
    gap: 32px 12px;
  }

  .product-image {
    aspect-ratio: 1280 / 1600;
  }

  .product-info h3 {
    font-size: 0.84rem;
  }

  .product-details h1 {
    font-size: 2.25rem;
  }

  .gallery-slide img {
    padding: 0px;
  }

  .specs-list dt,
  .specs-list dd {
    font-size: 0.82rem;
  }
}

/* =========================================================
   PÁGINA DIVISORA — PETRA
   ========================================================= */

.split-body {
  background: #f3eee7;
  color: #1d1814;
  min-height: 100vh;
}

.split-page {
  min-height: 100vh;
  width: min(1320px, calc(100% - 56px));
  margin: 0 auto;
  padding: 52px 0;
  display: grid;
  grid-template-rows: auto 1fr;
  gap: 52px;
}

.split-intro {
  text-align: center;
  max-width: 720px;
  margin: 0 auto;
  animation: splitFadeUp 0.9s ease both;
}

.split-logo-wrap {
  display: flex;
  justify-content: center;
  margin-bottom: 28px;
}

.split-logo {
  width: min(220px, 58vw);
  height: auto;
  object-fit: contain;
}

.split-label {
  display: block;
  font-size: 0.72rem;
  text-transform: uppercase;
  letter-spacing: 0.28em;
  color: #8a6241;
  margin-bottom: 20px;
}

.split-intro h1 {
  font-size: clamp(2.7rem, 6vw, 6.4rem);
  line-height: 0.9;
  font-weight: 300;
  letter-spacing: -0.07em;
  margin-bottom: 24px;
}

.split-intro p {
  font-size: 1rem;
  line-height: 1.8;
  color: #665a50;
  max-width: 520px;
  margin: 0 auto;
}

.split-options {
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  gap: 24px;
  align-items: stretch;
  animation: splitFadeUp 1s ease 0.18s both;
}

.split-card {
  position: relative;
  min-height: 520px;
  overflow: hidden;
  display: flex;
  align-items: flex-end;
  background: #1d1814;
  isolation: isolate;
}

.split-card-bg {
  position: absolute;
  inset: 0;
  z-index: -2;
}

.split-card-bg img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  object-position: center;
  transition: transform 1.1s ease, filter 1.1s ease;
}

.split-card-overlay {
  position: absolute;
  inset: 0;
  z-index: -1;
  background:
    linear-gradient(
      180deg,
      rgba(29, 24, 20, 0.12) 0%,
      rgba(29, 24, 20, 0.38) 45%,
      rgba(29, 24, 20, 0.76) 100%
    );
}

.split-card-content {
  width: 100%;
  color: #fff;
  padding: 42px;
}

.split-card-content span {
  display: block;
  font-size: 0.72rem;
  text-transform: uppercase;
  letter-spacing: 0.26em;
  color: rgba(255, 255, 255, 0.72);
  margin-bottom: 18px;
}

.split-card-content h2 {
  font-size: clamp(2.4rem, 5vw, 5.7rem);
  line-height: 0.9;
  font-weight: 300;
  letter-spacing: -0.065em;
  margin-bottom: 22px;
}

.split-card-content p {
  max-width: 360px;
  font-size: 0.96rem;
  line-height: 1.7;
  color: rgba(255, 255, 255, 0.78);
}

.split-card:hover .split-card-bg img {
  transform: scale(1.055);
  filter: contrast(1.05) saturate(1.02);
}

@keyframes splitFadeUp {
  from {
    opacity: 0;
    transform: translateY(26px);
  }

  to {
    opacity: 1;
    transform: translateY(0);
  }
}

/* MOBILE — PÁGINA DIVISORA */

@media (max-width: 768px) {
  .split-page {
    width: calc(100% - 28px);
    padding: 34px 0;
    gap: 38px;
  }

  .split-logo {
    width: min(180px, 56vw);
  }

  .split-label {
    font-size: 0.64rem;
    letter-spacing: 0.22em;
  }

  .split-intro h1 {
    font-size: 3.15rem;
  }

  .split-intro p {
    font-size: 0.94rem;
    line-height: 1.7;
  }

  .split-options {
    grid-template-columns: repeat(2, 1fr);
    gap: 12px;
  }

  .split-card {
    min-height: 340px;
  }

  .split-card-content {
    padding: 18px;
  }

  .split-card-content h2 {
    font-size: 1.8rem;
  }

  .split-card-content p {
    font-size: 0.8rem;
  }
}

@media (max-width: 430px) {
  .split-page {
    width: calc(100% - 24px);
  }

  .split-intro h1 {
    font-size: 2.65rem;
  }

  .split-card {
    min-height: 260px;
  }

  .split-card-content {
    padding: 14px;
  }

  .split-card-content h2 {
    font-size: 2.55rem;
  }
}

/* =========================================================
   INTRO DE ENTRADA — PETRA
   ========================================================= */

.intro-loading {
  overflow: hidden;
}

.intro-loader {
  position: fixed;
  inset: 0;
  z-index: 9999;
  background: #f3eee7;
  display: flex;
  align-items: center;
  justify-content: center;
  transition:
    opacity 0.9s ease,
    visibility 0.9s ease;
}

.intro-loader.hide {
  opacity: 0;
  visibility: hidden;
  pointer-events: none;
}

.intro-logo-wrap {
  display: flex;
  align-items: center;
  justify-content: center;
  animation: introLogoIn 1.35s ease both;
}

.intro-logo {
  width: min(260px, 62vw);
  height: auto;
  object-fit: contain;
}

@keyframes introLogoIn {
  0% {
    opacity: 0;
    transform: translateY(18px) scale(0.96);
    filter: blur(6px);
  }

  45% {
    opacity: 1;
    transform: translateY(0) scale(1);
    filter: blur(0);
  }

  100% {
    opacity: 1;
    transform: translateY(0) scale(1);
    filter: blur(0);
  }
}

/* =========================================================
   PÁGINA DIVISORA — PETRA
   ========================================================= */

.split-body {
  background: #f3eee7;
  color: #1d1814;
  min-height: 100vh;
}

.split-page {
  min-height: 100vh;
  width: min(1320px, calc(100% - 56px));
  margin: 0 auto;
  padding: 56px 0;
  display: grid;
  grid-template-rows: auto 1fr;
  gap: 52px;
  opacity: 0;
  transform: translateY(20px);
  transition:
    opacity 0.9s ease,
    transform 0.9s ease;
}

.split-body.intro-done .split-page {
  opacity: 1;
  transform: translateY(0);
}

.split-intro {
  text-align: center;
  max-width: 720px;
  margin: 0 auto;
}

.split-label {
  display: block;
  font-size: 0.72rem;
  text-transform: uppercase;
  letter-spacing: 0.28em;
  color: #8a6241;
  margin-bottom: 20px;
}

.split-intro h1 {
  font-size: clamp(2.7rem, 6vw, 6.4rem);
  line-height: 0.9;
  font-weight: 300;
  letter-spacing: -0.07em;
  margin-bottom: 24px;
}

.split-intro p {
  font-size: 1rem;
  line-height: 1.8;
  color: #665a50;
  max-width: 520px;
  margin: 0 auto;
}

.split-options {
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  gap: 24px;
  align-items: stretch;
}

.split-card {
  position: relative;
  min-height: 520px;
  overflow: hidden;
  display: flex;
  align-items: flex-end;
  background: #1d1814;
  isolation: isolate;
  opacity: 0;
  transform: translateY(30px);
}

.split-body.intro-done .split-card:nth-child(1) {
  animation: splitCardIn 0.9s ease 0.15s both;
}

.split-body.intro-done .split-card:nth-child(2) {
  animation: splitCardIn 0.9s ease 0.28s both;
}

.split-card-bg {
  position: absolute;
  inset: 0;
  z-index: -2;
}

.split-card-bg img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  object-position: center;
  transition:
    transform 1.1s ease,
    filter 1.1s ease;
}

.split-card-overlay {
  position: absolute;
  inset: 0;
  z-index: -1;
  background:
    linear-gradient(
      180deg,
      rgba(29, 24, 20, 0.12) 0%,
      rgba(29, 24, 20, 0.38) 45%,
      rgba(29, 24, 20, 0.78) 100%
    );
}

.split-card-content {
  width: 100%;
  color: #fff;
  padding: 42px;
}

.split-card-content span {
  display: block;
  font-size: 0.72rem;
  text-transform: uppercase;
  letter-spacing: 0.26em;
  color: rgba(255, 255, 255, 0.72);
  margin-bottom: 18px;
}

.split-card-content h2 {
  font-size: clamp(2.4rem, 5vw, 5.7rem);
  line-height: 0.9;
  font-weight: 300;
  letter-spacing: -0.065em;
  margin-bottom: 22px;
}

.split-card-content p {
  max-width: 360px;
  font-size: 0.96rem;
  line-height: 1.7;
  color: rgba(255, 255, 255, 0.78);
}

.split-card:hover .split-card-bg img {
  transform: scale(1.055);
  filter: contrast(1.05) saturate(1.02);
}

@keyframes splitCardIn {
  from {
    opacity: 0;
    transform: translateY(34px);
  }

  to {
    opacity: 1;
    transform: translateY(0);
  }
}

/* MOBILE — PÁGINA DIVISORA */

@media (max-width: 768px) {
  .intro-logo {
    width: min(210px, 58vw);
  }

  .split-page {
    width: calc(100% - 28px);
    padding: 38px 0;
    gap: 38px;
  }

  .split-label {
    font-size: 0.64rem;
    letter-spacing: 0.22em;
  }

  .split-intro h1 {
    font-size: 3.15rem;
  }

  .split-intro p {
    font-size: 0.94rem;
    line-height: 1.7;
  }

  .split-options {
    grid-template-columns: repeat(2, 1fr);
    gap: 12px;
  }

  .split-card {
    min-height: 340px;
  }

  .split-card-content {
    padding: 18px;
  }

  .split-card-content h2 {
    font-size: 1.8rem;
  }

  .split-card-content p {
    font-size: 0.8rem;
  }
}

@media (max-width: 430px) {
  .intro-logo {
    width: min(185px, 60vw);
  }

  .split-page {
    width: calc(100% - 24px);
  }

  .split-intro h1 {
    font-size: 2.65rem;
  }

  .split-card {
    min-height: 260px;
  }

  .split-card-content {
    padding: 14px;
  }

  .split-card-content h2 {
    font-size: 2.55rem;
  }
}

.line-hero .hero-inner {
  padding-top: 58px;
}

/* =========================================================
   SOFÁS MODULARES — visualizador de módulos (sem montagem)
   ========================================================= */
.modular-block {
  border-top: 1px solid var(--line);
  padding-top: 28px;
  margin-bottom: 42px;
}
.modular-head {
  display: flex;
  align-items: baseline;
  justify-content: space-between;
  gap: 12px;
  margin-bottom: 8px;
}
.modular-head h2 {
  font-size: 0.72rem;
  text-transform: uppercase;
  letter-spacing: 0.24em;
  color: var(--accent);
  font-weight: 500;
  margin: 0;
}
.modular-count {
  font-size: 0.66rem;
  letter-spacing: 0.1em;
  text-transform: uppercase;
  color: var(--soft-muted);
  background: var(--bg-card);
  border: 1px solid var(--line);
  border-radius: 999px;
  padding: 3px 10px;
}
.modular-hint {
  font-size: 0.84rem;
  color: var(--muted);
  line-height: 1.6;
  margin-bottom: 18px;
}

/* trilho horizontal de módulos */
.modular-selector {
  display: flex;
  gap: 10px;
  overflow-x: auto;
  padding: 4px 2px 12px;
  scroll-snap-type: x proximity;
  -webkit-overflow-scrolling: touch;
  scrollbar-width: thin;
  scrollbar-color: var(--line-strong) transparent;
}
.modular-selector::-webkit-scrollbar { height: 6px; }
.modular-selector::-webkit-scrollbar-thumb { background: var(--line-strong); border-radius: 999px; }

.mod-chip {
  flex: 0 0 auto;
  width: 112px;
  scroll-snap-align: start;
  display: flex;
  flex-direction: column;
  gap: 8px;
  padding: 8px;
  background: var(--bg-light);
  border: 1px solid var(--line);
  border-radius: 14px;
  cursor: pointer;
  text-align: left;
  transition: border-color 0.2s ease, background 0.2s ease, transform 0.2s ease, box-shadow 0.2s ease;
  font-family: var(--font-body);
}
.mod-chip:hover {
  border-color: var(--line-strong);
  transform: translateY(-2px);
}
.mod-chip.active {
  border-color: var(--accent);
  background: var(--white);
  box-shadow: 0 6px 18px -10px rgba(138, 98, 65, 0.55);
}
.mod-chip-thumb {
  position: relative;
  width: 100%;
  aspect-ratio: 4 / 3;
  border-radius: 9px;
  overflow: hidden;
  background: var(--bg-card);
  display: flex;
  align-items: center;
  justify-content: center;
}
.mod-chip-thumb img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  display: block;
}
.mod-chip-ico {
  font-size: 1.5rem;
  color: var(--soft-muted);
  line-height: 1;
}
.mod-chip.active .mod-chip-thumb { outline: 2px solid var(--accent); outline-offset: -2px; }
.mod-chip-empty .mod-chip-thumb {
  border: 1px dashed var(--line-strong);
  background: repeating-linear-gradient(45deg, var(--bg-card), var(--bg-card) 7px, var(--bg-light) 7px, var(--bg-light) 14px);
}
.mod-chip-text { display: flex; flex-direction: column; gap: 3px; min-width: 0; }
.mod-chip-name {
  font-size: 0.78rem;
  font-weight: 600;
  color: var(--text);
  line-height: 1.25;
}
.mod-chip-cod {
  font-size: 0.6rem;
  letter-spacing: 0.05em;
  color: var(--muted);
  font-weight: 600;
}
.mod-chip-cod-soon {
  font-weight: 500;
  font-style: italic;
  letter-spacing: 0.02em;
  text-transform: none;
  color: var(--soft-muted);
}

/* placeholder de galeria (módulo sem foto) */
.gallery-placeholder {
  width: 100%;
  height: 100%;
  min-height: 320px;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: 12px;
  background: var(--bg-card);
  color: var(--soft-muted);
  font-size: 0.8rem;
  letter-spacing: 0.16em;
  text-transform: uppercase;
}
.gallery-placeholder-icon { font-size: 2.6rem; opacity: 0.6; }

.gallery-dots.is-single { display: none; }

@media (max-width: 560px) {
  .mod-chip { width: 96px; }
}

/* === Refino MOBILE — modulares + medidas === */
@media (max-width: 600px) {
  /* Dimensões: empilha label + chips, chips ocupam a largura e quebram certinho */
  .specs-list div {
    flex-direction: column;
    align-items: flex-start;
    gap: 8px;
    padding: 13px 0;
  }
  .specs-list dd {
    width: 100%;
    justify-content: flex-start;
  }
  .specs-head { margin-bottom: 18px; }

  /* Seletor de módulos: cartões um pouco maiores p/ toque e leitura */
  .modular-selector { gap: 9px; padding-bottom: 14px; }
  .mod-chip { width: 122px; padding: 8px; }
  .mod-chip-name { font-size: 0.8rem; }
  .gallery-placeholder { min-height: 240px; }
  .gallery-placeholder-icon { font-size: 2.1rem; }
}

/* Sofás modulares: frame fixo (estável no carrossel) + contain pra mostrar a peça
   INTEIRA sem cortar. O respiro fica na cor de fundo do catálogo (se mistura). */
body.cat-sofas-modulares .gallery-slide { aspect-ratio: 3 / 2; }
body.cat-sofas-modulares .gallery-slide img { object-fit: contain; }

/* Etiqueta de código por foto (produtos com versões de mesmo nome) */
.gallery-badge {
  position: absolute;
  top: 16px;
  left: 16px;
  z-index: 6;
  background: var(--accent);
  color: #fff;
  font-size: 0.7rem;
  font-weight: 600;
  letter-spacing: 0.08em;
  padding: 5px 13px;
  border-radius: 999px;
  box-shadow: 0 5px 14px -5px rgba(29,24,20,.45);
  pointer-events: none;
}
.gallery-badge[hidden] { display: none; }


/* Rodape da pagina de produto */
.product-footer {
  width: min(1320px, calc(100% - 56px));
  margin: 0 auto;
  padding: 30px 0 48px;
  border-top: 1px solid var(--line);
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 20px;
  flex-wrap: wrap;
}
.product-footer-brand img { width: auto; height: 30px; opacity: 0.65; transition: opacity .3s ease; }
.product-footer-brand:hover img { opacity: 1; }
.product-footer-ig {
  display: inline-flex;
  align-items: center;
  gap: 9px;
  color: var(--muted);
  font-size: 0.82rem;
  letter-spacing: 0.04em;
  transition: color .3s ease;
}
.product-footer-ig svg { width: 18px; height: 18px; flex: 0 0 auto; color: var(--accent); }
.product-footer-ig em { font-style: normal; color: var(--accent); font-weight: 600; }
.product-footer-ig:hover { color: var(--text); }
@media (max-width: 560px) {
  .product-footer { justify-content: center; text-align: center; padding: 24px 0 34px; }
}

/* Link Instagram no rodape das listagens */
.catalog-footer .footer-ig { display: inline-flex; align-items: center; gap: 8px; }
.catalog-footer .footer-ig svg { width: 18px; height: 18px; flex: 0 0 auto; color: var(--accent); }
.catalog-footer .footer-ig em { font-style: normal; color: var(--accent); font-weight: 600; }