/* Catálogos públicos DUCOR: mesma linguagem da landing (site novo no Framer). Leem o PAINEL DUCOR (Supabase) ao vivo. Tema único claro. */
:root {
  --preto: #000; --texto: #474747; --cinza: #8a8a8a; --linha: #e2e2de; --pilula: #e4e4e4; --fundo: #fff; --suave: #f4f4f4;
  --lado: max(16px, clamp(16px, 4.2vw, 64px));
  color-scheme: light;
}
* { box-sizing: border-box; }
html { scroll-behavior: smooth; }
body { margin: 0; background: var(--fundo); color: var(--texto); font: 300 15px/1.6 Inter, Arial, sans-serif; -webkit-font-smoothing: antialiased; }
img { display: block; max-width: 100%; }
a { color: inherit; text-decoration: none; }
h1, h2, h3, p { margin: 0; }
button, input, select { font: inherit; color: inherit; }
button { cursor: pointer; }
:focus-visible { outline: 2px solid var(--preto); outline-offset: 2px; }

/* topo fixo, como no Framer */
.topo { position: sticky; top: 0; z-index: 40; height: 64px; display: flex; align-items: center; justify-content: space-between; gap: 20px;
  padding: 0 var(--lado); background: rgba(255,255,255,.97); border-bottom: 1px solid #eee; }
.topo .logo { height: 14px; width: auto; }
.topo nav { display: flex; gap: clamp(16px, 3vw, 48px); }
.topo nav a { font-size: 11px; font-weight: 400; letter-spacing: .04em; text-transform: uppercase; color: var(--preto); padding: 4px 0; border-bottom: 1px solid transparent; }
.topo nav a[aria-current="page"] { border-bottom-color: var(--preto); }

.titulo { font-size: clamp(18px, 1.7vw, 22px); font-weight: 300; text-transform: uppercase; color: var(--texto); letter-spacing: .02em; }
.nome { color: var(--preto); font-weight: 200; }
.nome b { font-weight: 600; letter-spacing: .02em; }
.lbl { font-size: 11px; letter-spacing: .06em; text-transform: uppercase; color: var(--cinza); }
.pilula { display: inline-flex; align-items: center; justify-content: center; gap: 8px; border: 0; border-radius: 999px; padding: 11px 22px;
  font-size: 13px; font-weight: 400; background: var(--pilula); color: var(--texto); transition: background .2s, color .2s; white-space: nowrap; }
.pilula:hover { background: #d4d4d4; }
.pilula.preta { background: var(--preto); color: #fff; }
.pilula.preta:hover { background: #333; }

/* cabeça da página */
.cabeca { padding: clamp(48px, 7vw, 96px) var(--lado) 24px; display: grid; grid-template-columns: 1fr auto; gap: 24px; align-items: end; }
.cabeca h1 { font-size: clamp(32px, 4.6vw, 60px); font-weight: 200; line-height: 1.05; letter-spacing: -.02em; color: var(--preto); }
.cabeca h1 b { font-weight: 600; }
.cabeca p { margin-top: 14px; max-width: 560px; }
.legenda { font-size: 11px; text-transform: uppercase; letter-spacing: .08em; color: var(--cinza); text-align: right; line-height: 1.7; }

/* busca e filtros */
.ferramentas { position: sticky; top: 64px; z-index: 30; background: rgba(255,255,255,.97); padding: 14px var(--lado); border-bottom: 1px solid #f0f0f0;
  display: flex; flex-wrap: wrap; gap: 10px 14px; align-items: center; }
.busca { flex: 1 1 220px; max-width: 340px; border: 1px solid var(--linha); border-radius: 999px; padding: 9px 16px; background: #fff; font-size: 13px; }
.busca:focus { outline: none; border-color: var(--preto); }
.seletor { border: 1px solid var(--linha); border-radius: 999px; padding: 9px 14px; background: #fff; font-size: 13px; max-width: 260px; }
.chips { display: flex; flex-wrap: wrap; gap: 8px; padding: 18px var(--lado) 0; }
.chips button { border: 1px solid var(--linha); background: #fff; border-radius: 999px; padding: 7px 14px; font-size: 12px; color: var(--texto); }
.chips button:hover { border-color: var(--preto); color: var(--preto); }
.chips button[aria-pressed="true"] { background: var(--preto); border-color: var(--preto); color: #fff; }
.contagem { font-size: 12px; color: var(--cinza); margin-left: auto; }

/* grade de produtos, como no Framer */
.lista { padding: 8px var(--lado) clamp(64px, 8vw, 120px); }
.grupo { padding-top: clamp(40px, 5vw, 72px); }
.grupo > h2 { margin-bottom: 28px; display: flex; align-items: baseline; gap: 14px; }
.grupo > h2 small { font-size: 12px; color: var(--cinza); text-transform: none; letter-spacing: 0; }
.grade { display: grid; grid-template-columns: repeat(4, 1fr); gap: clamp(28px, 3vw, 48px) clamp(12px, 2.4vw, 36px); }
.item { display: block; text-align: center; border: 0; background: none; padding: 0; }
.item .foto { position: relative; aspect-ratio: 4 / 3; overflow: hidden; background: #fff; }
.item .foto img { position: absolute; inset: 0; width: 100%; height: 100%; object-fit: contain; transition: opacity .35s; }
.item .foto img + img { opacity: 0; }
.item:hover .foto img:first-child { opacity: 0; }
.item:hover .foto img + img { opacity: 1; }
.item:hover .foto img:only-child { opacity: 1; }
.item:hover .rotulo b { text-decoration: underline; text-underline-offset: 3px; }
.item .rotulo { margin-top: 10px; font-size: 13px; }
.item .detalhe { font-size: 11px; color: var(--cinza); margin-top: 2px; }
.vazio { padding: 64px 0; color: var(--cinza); text-align: center; }

/* página do produto: tela dividida, como a ficha do Framer */
.produto { display: grid; grid-template-columns: 1.15fr 1fr; min-height: calc(100vh - 64px); }
.galeria { background: #fff; padding: clamp(16px, 3vw, 48px); display: flex; flex-direction: column; gap: 14px; border-right: 1px solid #f0f0f0; }
.galeria .principal { position: relative; aspect-ratio: 4 / 3; width: 100%; max-height: 72vh; overflow: hidden; margin: auto 0; }
.galeria .principal img { position: absolute; inset: 0; width: 100%; height: 100%; object-fit: contain; }
.miniaturas { display: flex; flex-wrap: wrap; gap: 8px; }
.miniaturas button { position: relative; width: 76px; height: 57px; border: 1px solid var(--linha); background: #fff; padding: 0; overflow: hidden; }
.miniaturas button[aria-current="true"] { border-color: var(--preto); box-shadow: inset 0 0 0 1px var(--preto); }
.miniaturas img { position: absolute; inset: 0; width: 100%; height: 100%; object-fit: contain; }
.ficha { padding: clamp(32px, 5vw, 80px) clamp(20px, 4vw, 72px); display: flex; flex-direction: column; gap: 22px; }
.ficha .voltar { font-size: 12px; color: var(--cinza); }
.ficha .voltar:hover { color: var(--preto); }
.ficha h1 { font-size: clamp(28px, 3.2vw, 44px); font-weight: 200; line-height: 1.1; color: var(--preto); letter-spacing: -.01em; }
.ficha h1 b { font-weight: 600; }
.combinacoes { display: grid; gap: 8px; }
.combinacao { display: flex; align-items: center; gap: 12px; width: 100%; text-align: left; border: 1px solid var(--linha); background: #fff; padding: 9px 12px; font-size: 12.5px; }
.combinacao:hover { border-color: #999; }
.combinacao[aria-current="true"] { border-color: var(--preto); box-shadow: inset 0 0 0 1px var(--preto); }
.amostras { display: flex; gap: 4px; flex: none; }
.amostras i { width: 22px; height: 22px; border-radius: 50%; display: block; border: 1px solid rgba(0,0,0,.12); background-size: cover; background-position: center; }
.linhas { list-style: none; margin: 0; padding: 0; border-top: 1px solid var(--linha); }
.linhas li { display: flex; justify-content: space-between; gap: 16px; padding: 12px 2px; border-bottom: 1px solid var(--linha); font-size: 13px; }
.linhas li span:first-child { text-transform: uppercase; letter-spacing: .03em; font-size: 12px; }
.linhas li span:last-child { color: var(--preto); text-align: right; }
.acoes { display: flex; flex-wrap: wrap; gap: 10px; }

/* acabamentos */
.amostrario { display: grid; grid-template-columns: repeat(auto-fill, minmax(180px, 1fr)); gap: 32px 20px; }
.sw { display: flex; flex-direction: column; gap: 10px; text-align: left; border: 0; background: none; padding: 0; }
.sw .tex { aspect-ratio: 4 / 5; width: 100%; transition: transform .3s; }
.sw:hover .tex { transform: scale(1.02); }
.sw h3 { font-size: 14px; font-weight: 400; color: var(--preto); }
.sw .cod { font-size: 11px; color: var(--cinza); letter-spacing: .06em; }
.tex-grande { aspect-ratio: 1; width: 100%; max-height: 70vh; }

dialog { border: 0; padding: 0; width: min(1100px, 100vw); max-height: 100dvh; background: #fff; color: var(--texto); }
dialog::backdrop { background: rgba(0, 0, 0, .35); }
dialog .produto { min-height: 0; }

footer.rodape { padding: 40px var(--lado) 48px; display: flex; justify-content: space-between; align-items: flex-end; gap: 24px; flex-wrap: wrap;
  font-size: 12px; border-top: 1px solid var(--linha); }
footer.rodape .logo { height: 14px; }
.carregando { color: var(--cinza); padding: 64px var(--lado); }

@media (max-width: 900px) {
  .grade { grid-template-columns: repeat(2, 1fr); }
  .produto { grid-template-columns: 1fr; }
  .galeria { border-right: 0; border-bottom: 1px solid #f0f0f0; }
  .cabeca { grid-template-columns: 1fr; } .legenda { text-align: left; }
  .contagem { margin-left: 0; width: 100%; }
}

/* versão para imprimir / salvar em PDF */
@media print {
  @page { margin: 14mm; }
  .topo, .ferramentas, .chips, .acoes, .voltar, .miniaturas, footer.rodape .so-tela, #ducor-whats { display: none !important; }
  body { font-size: 11px; }
  .cabeca { padding: 0 0 12px; }
  .lista { padding: 0; }
  .grupo { padding-top: 18px; break-inside: avoid-page; }
  .grade { grid-template-columns: repeat(4, 1fr); gap: 14px 10px; }
  .item { break-inside: avoid; }
  .item .foto img + img { display: none; }
  .item .foto img:first-child { opacity: 1 !important; }
  .produto { grid-template-columns: 1fr 1fr; min-height: 0; }
  .amostrario { grid-template-columns: repeat(5, 1fr); gap: 14px 10px; }
  .sw { break-inside: avoid; }
  * { -webkit-print-color-adjust: exact; print-color-adjust: exact; }
}
