/* Vitrine · "o preço na etiqueta"
   Cada cesta leva uma etiqueta de presente de papel, presa por um fio, com o preço escrito
   em Young Serif (a mesma etiqueta da seção Sobre, agora fazendo o trabalho de vender).
   A abertura usa a mesma etiqueta para dizer "a partir de" e entra no fim da animação do sol.
   Tamanhos, espaços e raios seguem melhorias/regras-de-design.md (tokens --t-*, --e-* em estilo.css). */

:root { --tag-papel: #FFF8EC; }

.so-leitor {
  position: absolute; width: 1px; height: 1px; overflow: hidden;
  clip: rect(0 0 0 0); clip-path: inset(50%); white-space: nowrap;
}

/* ---------- Etiqueta de preço (peça comum) ---------- */
.tag-preco {
  --gira: -5deg;
  position: absolute; z-index: 2;
  display: grid; justify-items: center;
  color: var(--mar); text-decoration: none;
  transform: rotate(var(--gira)); transform-origin: 50% 9px;
  /* nos cards só um contorno de contato (cards da grade não têm sombra) */
  filter: drop-shadow(0 1px 1.5px rgba(15,59,68,.3));
}
/* o papel: retângulo com os cantos de cima cortados, como etiqueta de presente */
.tag-preco::before {
  content: ""; position: absolute; inset: 0; z-index: -1;
  background: radial-gradient(130% 90% at 50% 0%, #FFFDF8, var(--tag-papel) 70%);
  clip-path: polygon(24% 0, 76% 0, 100% 16px, 100% 100%, 0 100%, 0 16px);
  border-radius: 0 0 8px 8px;
}
/* o fio que sobe do ilhós */
.tag-preco::after {
  content: ""; position: absolute; left: 50%; bottom: calc(100% - 9px); width: 1.5px; height: 32px;
  background: var(--bronze); transform-origin: 50% 100%; transform: rotate(18deg); border-radius: 2px;
}
.tag-preco__ilhos {
  position: absolute; left: 50%; top: 9px; width: 9px; height: 9px; translate: -50% -50%;
  border-radius: 50%; background: var(--nevoa);
  box-shadow: 0 0 0 2.5px var(--bronze), inset 0 1px 2px rgba(15,59,68,.35);
}

/* preço: "R$" e centavos a ~60%, alinhados ao topo; o valor inteiro em Young Serif, cor tinta */
.preco {
  display: inline-flex; align-items: flex-start; line-height: 1;
  font-family: var(--serif); font-weight: 400; letter-spacing: -.01em; white-space: nowrap;
  font-variant-numeric: lining-nums; color: var(--mar);
}
.preco__moeda { font-family: var(--sans); font-weight: 600; font-size: .5em; color: var(--bronze-texto); margin: .14em .18em 0 0; }
.preco__cent { font-size: .6em; margin: .06em 0 0 .03em; }
.preco--consulta { font-family: var(--sans); font-size: var(--t-s); font-weight: 500; line-height: 1.2; padding: var(--e-1) 0; }

/* ---------- Abertura ---------- */
.abertura__fatos {
  list-style: none; margin: var(--e-5) 0 0; padding: 0;
  display: grid; gap: var(--e-2); font-size: var(--t-s); line-height: 1.4; color: var(--texto-suave);
}
.abertura__fatos li { display: flex; align-items: center; gap: var(--e-3); }
.abertura__fatos svg { flex: none; width: 20px; height: 20px; fill: none; stroke: var(--agua-funda); stroke-width: 1.7; stroke-linecap: round; stroke-linejoin: round; }
.abertura__fatos b { font-weight: 500; color: var(--mar); }

.tag-preco--abertura {
  --gira: 7deg;
  left: 61%; top: 31%; z-index: 4;
  padding: var(--e-5) var(--e-4) var(--e-3); min-width: 150px; gap: 2px;
  /* esta flutua: a sombra única da marca, em tinta */
  filter: drop-shadow(0 14px 14px rgba(15,59,68,.24));
}
.tag-preco--abertura::after { height: 46px; transform: rotate(-38deg); }
.tag-preco--abertura small { font-size: var(--t-xs); font-weight: 500; line-height: 1.2; color: var(--texto-suave); }
.tag-preco__valor { display: block; font-weight: 400; }
.tag-preco--abertura .preco { font-size: var(--t-2xl); margin: var(--e-1) 0; }
.tag-preco__ver {
  font-size: var(--t-xs); font-weight: 600; line-height: 1.2; color: var(--agua-funda);
  border-top: 1px dashed rgba(166,112,42,.45); padding-top: var(--e-2); width: 100%; text-align: center;
}
.tag-preco--abertura:hover .tag-preco__ver { text-decoration: underline; text-underline-offset: 3px; }
.tag-preco--abertura:focus-visible { outline: none; }
.tag-preco--abertura:focus-visible::before { outline: 3px solid var(--bronze); }
.tag-preco--abertura:focus-visible .tag-preco__ver { text-decoration: underline; }

/* a etiqueta entra por último na animação única do sol (estilo.css): raios → cestas → etiqueta */
@media (prefers-reduced-motion: no-preference) {
  .tag-preco--abertura { animation: vitrine-tag-cai 1.2s 1.15s cubic-bezier(.3,.6,.3,1) both; }
  .tag-preco--abertura::after { animation: vitrine-fio .3s 1.1s cubic-bezier(.2,.8,.2,1) both; }
}
@keyframes vitrine-tag-cai {
  0% { opacity: 0; transform: translateY(-28px) rotate(-26deg); }
  20% { opacity: 1; }
  45% { transform: translateY(0) rotate(16deg); }
  68% { transform: rotate(3deg); }
  86% { transform: rotate(9deg); }
  100% { transform: rotate(var(--gira)); }
}
@keyframes vitrine-fio { from { clip-path: inset(0 0 100% 0); } to { clip-path: inset(0); } }

/* ---------- Ocasiões (com quantas cestas há em cada uma) ---------- */
.filtro { display: inline-flex; align-items: center; gap: var(--e-2); padding: 0 var(--e-3) 0 var(--e-4); }
.filtro__n {
  min-width: 24px; height: 24px; padding: 0 var(--e-2); border-radius: 999px;
  display: inline-grid; place-items: center;
  background: var(--nevoa); color: var(--agua-funda); font-size: var(--t-xs); font-weight: 600; line-height: 1;
  font-variant-numeric: tabular-nums;
}
.filtro[aria-pressed="true"] .filtro__n { background: rgba(255,255,255,.16); color: var(--sol); }

/* ---------- Faixa de preço e ordem ---------- */
.ajustes {
  display: flex; align-items: center; justify-content: space-between; gap: var(--e-3) var(--e-5); flex-wrap: wrap;
}
.faixas { display: flex; gap: var(--e-2); flex-wrap: wrap; }
.faixa {
  height: 44px; padding: 0 var(--e-4); border-radius: 999px;
  border: 1.5px dashed rgba(166,112,42,.55); background: transparent;
  font-size: var(--t-s); font-weight: 500; line-height: 1.2; color: var(--mar-2);
  transition: background-color .2s, border-color .2s, color .2s;
}
.faixa:hover:not(:disabled) { border-color: var(--bronze); }
.faixa[aria-pressed="true"] { background: var(--areia); border-style: solid; border-color: var(--bronze); color: var(--mar); }
.faixa:disabled { opacity: .45; cursor: not-allowed; }
.ordem { display: inline-flex; align-items: center; gap: var(--e-3); font-size: var(--t-s); color: var(--texto-suave); }
.ordem select {
  height: 44px; padding: 0 40px 0 var(--e-4); border-radius: 14px; border: 1.5px solid var(--nevoa-2);
  font: inherit; font-weight: 500; color: var(--mar); cursor: pointer;
  appearance: none; -webkit-appearance: none;
  background: var(--branco) url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 12 8'%3E%3Cpath d='M1 1.5l5 5 5-5' fill='none' stroke='%23137A8C' stroke-width='1.8' stroke-linecap='round' stroke-linejoin='round'/%3E%3C/svg%3E") no-repeat right 16px center / 12px 8px;
}
.ordem select:hover { border-color: var(--agua); }
.ordem select:focus-visible { outline: 3px solid var(--bronze); outline-offset: 2px; }
.vitrine__conta { font-size: var(--t-s); color: var(--texto-suave); margin: var(--e-4) 0 var(--e-6); font-variant-numeric: tabular-nums; }

/* ---------- Grade e cards (sem sombra; três tamanhos por card: --t-s, --t-l, --t-xl) ---------- */
.grade {
  list-style: none; margin: 0; padding: 0;
  display: grid; grid-template-columns: repeat(auto-fill, minmax(250px, 1fr)); gap: var(--e-7) var(--e-5);
}
.cesta { display: flex; flex-direction: column; min-width: 0; }
.cesta__abrir {
  position: relative; display: block; padding: 0; border: 0; background: none; text-align: left;
  border-radius: var(--arco);
}
.cesta__abrir:focus-visible { outline-offset: 5px; border-radius: var(--arco); }
.cesta__foto {
  position: relative; display: block; aspect-ratio: 4/5; overflow: hidden;
  border-radius: var(--arco); background: var(--nevoa);
}
.cesta__foto img { width: 100%; height: 100%; object-fit: cover; transition: transform .6s cubic-bezier(.2,.8,.2,1); }
.cesta__selo {
  position: absolute; left: 50%; top: var(--e-4); translate: -50% 0;
  display: inline-flex; align-items: center; gap: 6px;
  padding: var(--e-1) var(--e-3) var(--e-1) 10px; border-radius: 999px;
  background: var(--mar); color: var(--sol); font-size: var(--t-s); font-weight: 500; line-height: 1.2; white-space: nowrap;
}
.cesta__selo svg { width: 16px; height: 10px; fill: none; stroke: var(--sol); stroke-width: 1.8; stroke-linecap: round; }

.tag-preco--cesta { right: 9%; bottom: -14px; padding: 22px var(--e-4) 10px; min-width: 92px; }
.tag-preco--cesta .preco { font-size: var(--t-xl); }
.cesta--destaque .tag-preco--cesta::before { background: radial-gradient(130% 90% at 50% 0%, #FFFBF2, #FCEBD0 75%); }

/* resposta ao gesto: a foto aproxima e a etiqueta balança de leve */
@media (hover: hover) and (prefers-reduced-motion: no-preference) {
  .tag-preco--cesta { transition: transform .25s cubic-bezier(.2,.8,.2,1); }
  .cesta__abrir:hover .cesta__foto img { transform: scale(1.045); }
  .cesta__abrir:hover .tag-preco--cesta { transform: rotate(2deg); }
}

.cesta__nome { font-size: var(--t-l); line-height: 1.15; margin-top: var(--e-5); padding-right: var(--e-1); }
.cesta__gratis {
  align-self: flex-start; display: inline-flex; align-items: center; gap: 6px; margin-top: var(--e-2);
  padding: 2px var(--e-3) 2px var(--e-2); border-radius: 999px; background: var(--areia);
  font-size: var(--t-s); font-weight: 500; line-height: 1.4; color: var(--mar);
}
.cesta__gratis svg { width: 18px; height: 18px; fill: none; stroke: var(--bronze-texto); stroke-width: 1.7; stroke-linecap: round; stroke-linejoin: round; }
.cesta__itens {
  color: var(--texto-suave); font-size: var(--t-s); margin-top: var(--e-2); line-height: 1.55;
  display: -webkit-box; -webkit-line-clamp: 2; -webkit-box-orient: vertical; overflow: hidden;
}
.cesta__base { display: flex; align-items: center; gap: var(--e-2); margin-top: auto; padding-top: var(--e-4); }
.cesta__mais {
  flex: 1; height: 44px; padding: 0 var(--e-4); border-radius: 999px;
  border: 1.5px solid var(--nevoa-2); background: var(--branco);
  color: var(--agua-funda); font-weight: 600; font-size: var(--t-s); line-height: 1.2;
  transition: background-color .2s, border-color .2s;
}
.cesta__mais:hover { background: var(--nevoa); border-color: var(--agua); }
/* adicionar direto: ação secundária (o botão cheio da tela é o da abertura/detalhe) */
.cesta__add {
  flex: none; position: relative; width: 44px; height: 44px; border-radius: 50%; border: 0;
  display: grid; place-items: center; background: var(--nevoa); color: var(--agua-funda);
  transition: background-color .2s, color .2s, transform .15s;
}
.cesta__add:hover { background: var(--agua-funda); color: #fff; }
.cesta__add:active { transform: scale(.94); }
.cesta__add svg { width: 24px; height: 24px; fill: none; stroke: currentColor; stroke-width: 1.7; stroke-linecap: round; stroke-linejoin: round; }
.cesta__add .ok { opacity: 0; }
.cesta__add.feito { background: var(--agua-funda); color: #fff; }
.cesta__add.feito .mais { opacity: 0; }
.cesta__add.feito .ok { opacity: 1; stroke-width: 2.2; }
@media (prefers-reduced-motion: no-preference) {
  .cesta__add.feito { animation: vitrine-guardou .25s cubic-bezier(.2,.8,.2,1); }
  .cesta__add.feito .ok { stroke-dasharray: 12; animation: vitrine-risca .25s .05s cubic-bezier(.2,.8,.2,1) both; }
}
@keyframes vitrine-guardou { 50% { transform: scale(1.12); } }
@keyframes vitrine-risca { from { stroke-dashoffset: 12; } to { stroke-dashoffset: 0; } }

/* ---------- Vazio ---------- */
.vitrine__vazia { text-align: center; color: var(--texto-suave); padding: var(--e-7) var(--e-4); border: 1.5px dashed var(--nevoa-2); border-radius: 28px; }
.vitrine__vazia-acoes { display: flex; flex-wrap: wrap; justify-content: center; gap: var(--e-3); margin-top: var(--e-5); }

/* ---------- Tablet ---------- */
@media (max-width: 960px) {
  .tag-preco--abertura { left: 61%; top: 36%; }
  .rodape { grid-template-columns: 1fr 1fr; }
  .rodape__marca { grid-column: 1 / -1; }
}

/* ---------- Celular: a primeira tela já mostra cestas e preço ---------- */
@media (max-width: 600px) {
  .abertura { padding-top: var(--e-2); gap: var(--e-1); }
  .abertura__cena { order: -1; height: 268px; }
  .abertura__texto { padding-bottom: var(--e-7); }
  .tag-preco--abertura { left: auto; right: 0; top: 28px; min-width: 0; padding: 20px var(--e-3) 10px; --gira: 6deg; }
  .tag-preco--abertura::after { height: 30px; transform: rotate(-42deg); }
  .tag-preco--abertura .preco { font-size: var(--t-xl); }
  .tag-preco__ver { display: none; }

  .ajustes { flex-direction: column; align-items: stretch; }
  .faixas { flex-wrap: nowrap; overflow-x: auto; margin: 0 calc(-1 * var(--lado)); padding: 2px var(--lado) var(--e-1); scrollbar-width: none; }
  .faixas::-webkit-scrollbar { display: none; }
  .faixa { flex: none; }
  .ordem { justify-content: space-between; }
  .ordem select { flex: 1; max-width: 240px; }
  .vitrine__conta { margin: var(--e-3) 0 var(--e-5); }

  .grade { grid-template-columns: 1fr 1fr; gap: var(--e-6) var(--e-3); }
  .cesta__selo { top: 10px; padding: 2px var(--e-2) 2px 6px; gap: var(--e-1); }
  .cesta__selo svg { width: 13px; height: 8px; }
  .tag-preco--cesta { right: 6px; bottom: -12px; padding: 18px 10px var(--e-2); min-width: 0; }
  .tag-preco--cesta::after { height: 22px; }
  .cesta__nome { font-size: var(--t-m); margin-top: var(--e-5); }
  .cesta__itens { display: none; }
  .cesta__gratis svg { display: none; }
  .cesta__gratis { padding: 2px var(--e-2); }
  .cesta__base { padding-top: var(--e-3); }
  .cesta__mais { padding: 0 var(--e-2); }
  .vitrine__vazia-acoes .botao { flex: 1 1 100%; }

  .natal h2 { max-width: 16ch; }
  .rodape { grid-template-columns: 1fr; gap: var(--e-6); }
  .rodape [data-rodape-ocasioes] { grid-template-columns: 1fr 1fr; column-gap: var(--e-4); }
}
