:root {
  --creme: #fbeee7;
  --creme-2: #fbede4; /* mesmo fundo das fotos do PDF */
  --papel: #fffaf6;
  --azul: #1f2b47;
  --azul-2: #3b4766;
  --ouro: #c49a5e;
  --preto: #141414;
  --zap: #1f9d55;
  --linha: #ead5c8;
  --raio: 14px;
  --serif: 'Lora', Georgia, serif;
  --sans: 'DM Sans', system-ui, -apple-system, sans-serif;
}
* { box-sizing: border-box; }
html { -webkit-text-size-adjust: 100%; }
body { margin: 0; background: var(--creme); color: var(--azul); font: 15px/1.45 var(--sans); }
img { display: block; max-width: 100%; }
button { font: inherit; color: inherit; cursor: pointer; }
h1, h2 { font-family: var(--serif); font-weight: 600; margin: 0; }

/* faixa BLACK */
.faixa-black { background: var(--preto); color: #fff; overflow: hidden; white-space: nowrap; font-weight: 700; letter-spacing: .08em; font-size: 13px; }
.faixa-trilho { display: inline-flex; gap: 18px; padding: 8px 0; animation: rolar 38s linear infinite; }
.faixa-trilho span:nth-child(odd) { text-transform: uppercase; }
@keyframes rolar { to { transform: translateX(-33.333%); } }
@media (prefers-reduced-motion: reduce) { .faixa-trilho { animation: none; } }

/* topo: céu da logo (lua, estrelas, nuvens) */
.hero { position: relative; overflow: hidden; color: var(--creme); padding: 26px 16px 64px;
  background: radial-gradient(120% 90% at 85% 10%, #3b4a78 0%, transparent 55%), linear-gradient(180deg, #10182e 0%, #1f2b47 70%, #2c3a5e 100%); }
.ceu { position: absolute; inset: 0; pointer-events: none; }
.estrela { position: absolute; border-radius: 50%; background: #fff6e6; opacity: .25; animation: piscar var(--d, 3s) ease-in-out var(--a, 0s) infinite; }
.estrela.brilho { width: 9px !important; height: 9px !important; background: none; opacity: .9; }
.estrela.brilho::before, .estrela.brilho::after { content: ''; position: absolute; left: 50%; top: 50%; background: #fff3dc; border-radius: 2px; transform: translate(-50%, -50%); }
.estrela.brilho::before { width: 2px; height: 9px; } .estrela.brilho::after { width: 9px; height: 2px; }
@keyframes piscar { 50% { opacity: 1; transform: scale(1.25); } }
.lua { position: absolute; width: 54px; height: 54px; right: 6px; top: -4px; filter: drop-shadow(0 0 28px rgba(240, 200, 140, .55)); animation: lua-sobe 1.4s cubic-bezier(.2,.8,.2,1) both, lua-flutua 7s ease-in-out 1.4s infinite; }
@keyframes lua-sobe { from { transform: translateY(60px) rotate(-12deg); opacity: 0; } }
@keyframes lua-flutua { 50% { transform: translateY(-8px) rotate(2deg); filter: drop-shadow(0 0 40px rgba(240, 200, 140, .75)); } }
.hero-conteudo { position: relative; z-index: 1; max-width: 1180px; margin: 0 auto; display: flex; align-items: center; gap: 16px; }
.disco-logo { flex: none; width: 104px; height: 104px; border-radius: 50%; background: var(--creme); display: grid; place-items: center;
  box-shadow: 0 0 0 6px rgba(251, 238, 231, .12), 0 0 40px rgba(240, 200, 140, .35); animation: entra-logo .9s cubic-bezier(.2,.9,.3,1.3) .15s both; }
.logo { width: 92px; height: 92px; object-fit: contain; }
@keyframes entra-logo { from { transform: scale(.4) rotate(-20deg); opacity: 0; } }
.hero-texto > * { animation: sobe .7s ease both; }
.hero-texto > :nth-child(1) { animation-delay: .35s; } .hero-texto > :nth-child(2) { animation-delay: .45s; } .hero-texto > :nth-child(3) { animation-delay: .55s; }
@keyframes sobe { from { transform: translateY(14px); opacity: 0; } }
.chapeu { margin: 0; font-size: 11.5px; font-weight: 700; letter-spacing: .14em; text-transform: uppercase; color: var(--ouro); }
.hero h1 { font-size: 30px; line-height: 1.1; color: #fff8f1; }
.hero h1 em { font-style: italic; color: #f0cf9c; }
.hero-texto p:last-child { margin: 6px 0 0; color: rgba(251, 238, 231, .78); font-size: 14px; max-width: 34ch; }
.nuvens { position: absolute; left: -5%; bottom: -1px; width: 110%; height: 64px; }
.nuvens .n1 { fill: rgba(201, 195, 222, .35); animation: deriva 14s ease-in-out infinite alternate; }
.nuvens .n2 { fill: var(--creme); animation: deriva 18s ease-in-out infinite alternate-reverse; }
@keyframes deriva { to { transform: translateX(-3%); } }
@media (min-width: 720px) {
  .hero { padding: 40px 24px 84px; }
  .hero h1 { font-size: 44px; }
  .disco-logo { width: 140px; height: 140px; } .logo { width: 124px; height: 124px; }
  .lua { width: 250px; height: 250px; right: 7%; top: 6px; }
  .nuvens { height: 90px; }
}
@media (prefers-reduced-motion: reduce) { .hero *, .hero *::before, .hero *::after { animation: none !important; } }

/* barra fixa */
.barra { position: sticky; top: 0; z-index: 5; background: color-mix(in srgb, var(--creme) 94%, transparent); backdrop-filter: blur(8px);
  border-bottom: 1px solid var(--linha); padding: 10px 16px 10px; }
.barra > * { max-width: 1180px; margin-left: auto; margin-right: auto; }
.busca { display: flex; align-items: center; gap: 8px; background: var(--papel); border: 1px solid var(--linha); border-radius: 999px; padding: 0 14px; height: 44px; }
.busca svg, .btn-filtros svg { width: 18px; height: 18px; fill: none; stroke: currentColor; stroke-width: 2; stroke-linecap: round; flex: none; }
.busca input { border: 0; outline: 0; background: transparent; flex: 1; font: inherit; color: var(--azul); min-width: 0; height: 100%; }
.busca:focus-within { border-color: var(--azul-2); }
.abas { display: flex; gap: 6px; overflow-x: auto; margin-top: 10px; scrollbar-width: none; }
.abas::-webkit-scrollbar { display: none; }
.aba { flex: none; border: 1px solid var(--linha); background: var(--papel); border-radius: 999px; padding: 7px 14px; font-weight: 500; font-size: 14px; }
.aba[aria-pressed="true"] { background: var(--azul); border-color: var(--azul); color: #fff; }
.aba small { opacity: .6; margin-left: 3px; }
.linha-filtros { display: flex; align-items: center; gap: 8px; margin-top: 8px; }
.btn-filtros { flex: none; display: inline-flex; align-items: center; gap: 6px; border: 1px solid var(--azul); background: transparent; border-radius: 999px; padding: 6px 12px; font-size: 14px; font-weight: 500; }
.contador { background: var(--azul); color: #fff; border-radius: 999px; font-size: 11px; padding: 1px 6px; }
.chips-tamanho { display: flex; gap: 6px; overflow-x: auto; scrollbar-width: none; }
.chips-tamanho::-webkit-scrollbar { display: none; }
.chip-tam { flex: none; min-width: 38px; height: 34px; border-radius: 999px; border: 1px solid var(--linha); background: var(--papel); font-size: 13px; font-weight: 500; padding: 0 10px; }
.chip-tam[aria-pressed="true"] { background: var(--azul); color: #fff; border-color: var(--azul); }

/* grade */
main { max-width: 1180px; margin: 0 auto; padding: 14px 16px 40px; }
.resumo { margin: 0 0 12px; font-size: 13px; color: var(--azul-2); }
.grade { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 12px; }
@media (min-width: 720px) { .grade { grid-template-columns: repeat(3, 1fr); gap: 18px; } }
@media (min-width: 1040px) { .grade { grid-template-columns: repeat(4, 1fr); } }
.card { background: var(--papel); border-radius: var(--raio); overflow: hidden; border: 1px solid var(--linha); text-align: left; padding: 0; display: flex; flex-direction: column;
  transition: transform .15s ease, box-shadow .15s ease; }
.card:hover { transform: translateY(-2px); box-shadow: 0 8px 22px rgba(31, 43, 71, .10); }
.card:focus-visible { outline: 2px solid var(--azul); outline-offset: 2px; }
.card-foto { position: relative; background: var(--creme-2); aspect-ratio: 3 / 4; overflow: hidden; }
.card-foto img { width: 100%; height: 100%; object-fit: contain; object-position: center bottom; }
.card.quadrado .card-foto img { object-fit: cover; object-position: center; }
.selo { position: absolute; top: 8px; left: 8px; background: var(--preto); color: #fff; font-size: 11px; font-weight: 700; letter-spacing: .04em; border-radius: 6px; padding: 3px 7px; }
.card-info { padding: 10px 12px 12px; display: flex; flex-direction: column; gap: 3px; flex: 1; }
.card-nome { font-family: var(--serif); font-weight: 600; font-size: 16px; line-height: 1.2; }
.card-sub { font-size: 12.5px; color: var(--azul-2); }
.bolinhas { display: flex; gap: 4px; margin: 4px 0 2px; align-items: center; }
.bolinha { width: 18px; height: 18px; border-radius: 50%; background-size: 260%; background-position: 50% 32%; border: 1px solid var(--linha); }
.bolinhas small { font-size: 11.5px; color: var(--azul-2); margin-left: 2px; }
.card-preco { margin-top: auto; padding-top: 6px; }
.pix { font-weight: 700; font-size: 18px; color: var(--azul); }
.pix small { font-weight: 500; font-size: 12px; color: var(--azul-2); }
.credito { font-size: 12px; color: var(--azul-2); }
.de { text-decoration: line-through; font-size: 12px; color: #9a7f72; margin-right: 4px; }

/* vazio */
.vazio { text-align: center; padding: 40px 10px; }
.vazio p { font-family: var(--serif); font-size: 18px; }

/* info */
.info { display: grid; gap: 22px; margin-top: 40px; padding: 22px; background: var(--papel); border: 1px solid var(--linha); border-radius: var(--raio); }
@media (min-width: 720px) { .info { grid-template-columns: 1fr 2fr; } }
.info h2 { font-size: 18px; margin-bottom: 6px; }
.info p, .info li { font-size: 14px; color: var(--azul-2); }
.info ul { margin: 0; padding-left: 18px; }
.info li { margin-bottom: 4px; }
.rodape { text-align: center; padding: 10px 16px 40px; color: var(--azul-2); font-size: 13px; }
.logo-mini { width: 54px; margin: 0 auto 4px; }

/* botões */
.btn-zap { display: inline-flex; align-items: center; justify-content: center; gap: 8px; background: var(--zap); color: #fff; text-decoration: none; font-weight: 700; border-radius: 999px; padding: 11px 20px; border: 0; }
.btn-zap svg { width: 20px; height: 20px; fill: currentColor; }
.btn-zap.grande { width: 100%; padding: 15px 20px; font-size: 16px; margin-top: 16px; position: sticky; bottom: 12px; box-shadow: 0 6px 18px rgba(31,157,85,.35); }
.btn-zap.inativo { background: #8fbfa3; }
.link { background: none; border: 0; text-decoration: underline; color: var(--azul-2); padding: 8px; }

/* ficha */
dialog { border: 0; padding: 0; color: var(--azul); background: var(--papel); }
dialog::backdrop { background: rgba(20, 22, 35, .55); }
.ficha { width: min(920px, 100vw); max-height: 100dvh; border-radius: 18px; margin: auto; }
@media (max-width: 719px) { .ficha { margin: auto 0 0; width: 100vw; max-width: 100vw; border-radius: 18px 18px 0 0; max-height: 94dvh; } }
.ficha-corpo { display: grid; }
@media (min-width: 720px) { .ficha-corpo { grid-template-columns: 1fr 1fr; } }
.ficha-foto { background: var(--creme-2); display: flex; align-items: flex-end; justify-content: center; min-height: 300px; }
.ficha-foto img { max-height: 62dvh; width: auto; object-fit: contain; }
@media (max-width: 719px) { .ficha-foto { min-height: 0; } .ficha-foto img { max-height: 38dvh; } }
.ficha-info { padding: 20px 20px 24px; }
.ficha-cat { text-transform: uppercase; letter-spacing: .08em; font-size: 11.5px; font-weight: 700; color: var(--ouro); margin: 0; }
.ficha h2 { font-size: 26px; margin-top: 2px; }
.ficha-tecido { margin: 2px 0 12px; color: var(--azul-2); }
.ficha-preco .pix { font-size: 26px; }
.ficha-preco .credito { font-size: 14px; }
.rotulo { font-size: 13px; font-weight: 500; margin: 16px 0 8px; color: var(--azul-2); }
.rotulo b { color: var(--azul); font-weight: 600; }
.cores { display: flex; gap: 8px; flex-wrap: wrap; }
.cor { width: 52px; height: 52px; border-radius: 12px; border: 2px solid transparent; background-color: var(--creme-2); background-size: 230%; background-position: 50% 30%; padding: 0; outline: 1px solid var(--linha); }
.cor[aria-pressed="true"] { border-color: var(--azul); outline-color: var(--azul); }
.tamanhos { display: flex; gap: 8px; flex-wrap: wrap; }
.tam { min-width: 48px; height: 44px; border-radius: 10px; border: 1px solid var(--linha); background: #fff; font-weight: 500; padding: 0 12px; }
.tam[aria-pressed="true"] { background: var(--azul); color: #fff; border-color: var(--azul); }
.dica { font-size: 12.5px; color: var(--azul-2); margin: 8px 0 0; }
.aviso-tam { font-size: 12.5px; color: #a0522d; text-align: center; margin: 8px 0 0; }
.fechar { position: absolute; top: 10px; right: 10px; z-index: 2; width: 38px; height: 38px; border-radius: 50%; border: 0; background: rgba(255,255,255,.9); font-size: 24px; line-height: 1; box-shadow: 0 1px 4px rgba(0,0,0,.15); }

/* filtros */
.filtros { width: min(460px, 100vw); border-radius: 18px; padding: 18px 20px 20px; margin: auto; }
@media (max-width: 719px) { .filtros { margin: auto 0 0; width: 100vw; max-width: 100vw; border-radius: 18px 18px 0 0; } }
.filtros-topo { display: flex; justify-content: space-between; align-items: center; }
.filtros .fechar { position: static; box-shadow: none; background: var(--creme); }
.opcoes { display: flex; gap: 6px; flex-wrap: wrap; }
.opcao { border: 1px solid var(--linha); background: #fff; border-radius: 999px; padding: 7px 13px; font-size: 14px; }
.opcao[aria-pressed="true"] { background: var(--azul); color: #fff; border-color: var(--azul); }
.faixa-preco { display: flex; align-items: center; gap: 12px; }
.faixa-preco input { flex: 1; accent-color: var(--azul); }
.faixa-preco output { font-weight: 700; min-width: 74px; text-align: right; }
.filtros-acoes { display: flex; justify-content: space-between; align-items: center; margin-top: 22px; }
.btn-ver { background: var(--azul); color: #fff; border: 0; border-radius: 999px; padding: 12px 24px; font-weight: 700; }

/* painel de eventos (?debug) */
.debug-painel { position: fixed; left: 12px; bottom: 12px; z-index: 50; width: min(320px, calc(100vw - 24px)); background: rgba(14, 18, 30, .92); color: #e8ecf5; border-radius: 12px; padding: 10px 12px; font-size: 12px; box-shadow: 0 8px 30px rgba(0,0,0,.3); }
.debug-painel b { display: block; color: #9fb3ff; margin-bottom: 6px; font-size: 11px; text-transform: uppercase; letter-spacing: .08em; }
.debug-painel div { padding: 3px 0; border-top: 1px solid rgba(255,255,255,.08); animation: entra .3s ease; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.debug-painel code { color: #7ee2a8; font-weight: 700; }
@keyframes entra { from { background: rgba(126, 226, 168, .25); } }

/* movimento: cards entrando, troca de foto, ficha abrindo, brilho no botão */
.card.revela { opacity: 0; transform: translateY(18px); }
.card.revelado { opacity: 1; transform: none; transition: opacity .5s ease, transform .5s cubic-bezier(.2,.8,.2,1), box-shadow .15s ease; transition-delay: var(--atraso, 0s); }
.card-foto img { transition: transform .5s cubic-bezier(.2,.8,.2,1); }
.card:hover .card-foto img { transform: scale(1.04); }
.card-foto::after { content: ''; position: absolute; inset: 0; background: linear-gradient(110deg, transparent 40%, rgba(255,255,255,.35) 50%, transparent 60%); transform: translateX(-100%); pointer-events: none; }
.card:hover .card-foto::after { transform: translateX(100%); transition: transform .8s ease; }
.ficha[open] { animation: ficha-abre .35s cubic-bezier(.2,.8,.2,1); }
.filtros[open] { animation: ficha-abre .3s cubic-bezier(.2,.8,.2,1); }
@keyframes ficha-abre { from { transform: translateY(24px) scale(.98); opacity: 0; } }
@media (max-width: 719px) { @keyframes ficha-abre { from { transform: translateY(100%); } } }
dialog[open]::backdrop { animation: escurece .3s ease; }
@keyframes escurece { from { background: rgba(20, 22, 35, 0); } }
#fichaFoto.troca { animation: troca-foto .35s ease; }
@keyframes troca-foto { from { opacity: 0; transform: scale(.97); } }
.btn-zap.grande { overflow: hidden; }
.btn-zap.grande::after { content: ''; position: absolute; inset: 0; background: linear-gradient(110deg, transparent 35%, rgba(255,255,255,.35) 50%, transparent 65%); transform: translateX(-120%); animation: reflexo 3.2s ease-in-out 1s infinite; pointer-events: none; }
@keyframes reflexo { 40%, 100% { transform: translateX(120%); } }
.aba, .chip-tam, .opcao, .tam, .cor { transition: background-color .2s ease, color .2s ease, border-color .2s ease, transform .1s ease; }
.aba:active, .chip-tam:active, .opcao:active, .tam:active, .cor:active { transform: scale(.94); }
.resumo { transition: opacity .2s; }
@media (prefers-reduced-motion: reduce) {
  .card.revela { opacity: 1; transform: none; }
  .ficha[open], .filtros[open], #fichaFoto.troca, .btn-zap.grande::after, dialog[open]::backdrop { animation: none; }
}
