/* Cestify · fluxo de compra
   Detalhe da cesta, aviso flutuante, sacola (com botão flutuante no celular) e a página do pedido.
   A peça que marca o fluxo é a etiqueta de presente: o recado do cartão é escrito direto nela
   (Caveat só ali) e ela reaparece na sacola e no acompanhamento do pedido.
   Carrega depois de estilo.css (e sobre.css) e sobrescreve só as regras dessas áreas.
   Segue melhorias/regras-de-design.md: escala --t-*, grade de 8 px --e-*, uma sombra só. */
@import url("https://fonts.googleapis.com/css2?family=Caveat:wght@500;700&display=swap");

:root {
  /* tokens das regras de design (mesmos nomes e valores do estilo.css; aqui como garantia) */
  --t-xs: .8rem; --t-s: .9rem; --t-m: 1rem; --t-l: 1.25rem; --t-xl: 1.56rem; --t-2xl: 1.95rem;
  --t-3xl: clamp(2.2rem, 4vw, 3.1rem); --t-4xl: clamp(2.5rem, 5vw, 3.9rem);
  --e-1: 4px; --e-2: 8px; --e-3: 12px; --e-4: 16px; --e-5: 24px; --e-6: 32px; --e-7: 48px; --e-8: 64px; --e-9: 96px;
  --sombra: 0 18px 40px -22px rgba(15, 59, 68, .45);

  --mao: "Caveat", "Segoe Print", "Bradley Hand", cursive;
  --papel: #FFF8EC;
  --erro: #B03A2E;
  --erro-fundo: #FDF0EE;
  --whats-botao: #15803F; /* verde do WhatsApp escurecido: branco sobre ele passa 4,5:1 */
  --curva: cubic-bezier(.2, .8, .2, 1);
}

.visualmente-oculto {
  position: absolute !important; width: 1px; height: 1px; padding: 0; margin: -1px;
  overflow: hidden; clip: rect(0 0 0 0); white-space: nowrap; border: 0;
}

/* ---------- Sol do logo (raios + disco), gerado por js/compra.js ---------- */
.raios-sol { display: block; overflow: visible; }
.raios-sol line { stroke: var(--sol); stroke-width: 6; stroke-linecap: round; }
.raios-sol__disco { fill: none; stroke: var(--bronze); stroke-width: 6; stroke-linecap: round; }

/* ---------- Detalhe da cesta ---------- */
.detalhe {
  --w: 272px; /* largura do arco da foto */
  width: min(1000px, calc(100vw - var(--e-6)));
  height: min(760px, calc(100dvh - var(--e-6))); max-height: none;
  border-radius: 32px; overflow: hidden; box-shadow: var(--sombra);
}
.detalhe[open] { display: grid; grid-template-columns: .92fr 1.08fr; }
.detalhe::backdrop { background: rgba(15,59,68,.6); }
.detalhe__fechar { top: var(--e-3); right: var(--e-3); }
.detalhe__fechar button { color: var(--mar); box-shadow: var(--sombra); }

.detalhe__foto {
  position: relative; overflow: hidden; padding: 0;
  display: grid; grid-template: minmax(0, 1fr) / minmax(0, 1fr); place-items: center;
  background: radial-gradient(120% 70% at 50% 100%, var(--nevoa-2), var(--nevoa) 60%, #F5FCFD);
}
.detalhe__foto > * { grid-area: 1 / 1; }
/* o arco da foto é o disco do sol; os raios nascem em volta dele */
.detalhe__arco {
  position: relative; z-index: 1; width: var(--w); aspect-ratio: 4 / 5; margin-top: var(--e-7);
  border-radius: var(--arco); overflow: hidden;
  border: 6px solid var(--branco); background: var(--areia); box-shadow: var(--sombra);
}
.detalhe__arco img { width: 100%; height: 100%; max-height: none; object-fit: cover; border-radius: 0; }
.detalhe__foto .raios-sol {
  width: calc(var(--w) * 2.43); max-width: none; align-self: center;
  translate: 0 calc(var(--w) * -0.73 + var(--e-5));
}
.detalhe__foto .raios-sol line { stroke-width: 3; }
.detalhe__foto .raios-sol__disco { stroke-width: 2.4; }
.detalhe__ondas { position: relative; z-index: 2; align-self: end; width: 120%; height: 40px; margin-bottom: var(--e-4); }
.detalhe__ondas path { fill: none; stroke: var(--agua); stroke-width: 3; stroke-linecap: round; }
.detalhe__ondas path + path { stroke: var(--agua-funda); stroke-width: 2; opacity: .45; }

@media (prefers-reduced-motion: no-preference) {
  .detalhe[open] .raios-sol line { stroke-dasharray: 1; stroke-dashoffset: 1; animation: compra-raio .35s calc(.1s + var(--i) * 20ms) var(--curva) forwards; }
  .detalhe[open] .raios-sol__disco { stroke-dasharray: 1; stroke-dashoffset: 1; animation: compra-raio .5s var(--curva) forwards; }
  .detalhe[open] .detalhe__arco { animation: compra-subir .4s var(--curva); }
}
@keyframes compra-raio { to { stroke-dashoffset: 0; } }
@keyframes compra-subir { from { opacity: 0; translate: 0 var(--e-5); } }

.detalhe__info { padding: var(--e-7) var(--e-7) 0; overflow-y: auto; overscroll-behavior: contain; }
.detalhe__ocasioes { font-size: var(--t-s); line-height: 1.2; }
.detalhe h2 { font-size: var(--t-2xl); line-height: 1.1; margin-top: var(--e-2); padding-right: var(--e-7); text-wrap: balance; }
/* preço: Young Serif grande, "R$" e centavos menores e no alto */
.detalhe__preco {
  display: flex; align-items: flex-start; margin-top: var(--e-3);
  font-family: var(--serif); font-weight: 400; font-size: var(--t-3xl); line-height: 1;
  color: var(--mar); font-variant-numeric: tabular-nums;
}
.detalhe__preco .moeda, .detalhe__preco .cent { font-size: .6em; line-height: 1.15; }
.detalhe__preco .moeda { margin-right: .2em; }
.detalhe__preco.consulta { font-family: var(--sans); font-size: var(--t-l); font-weight: 500; color: var(--texto-suave); }
.detalhe__frete { margin-top: var(--e-3); font-size: var(--t-s); line-height: 1.55; color: var(--texto-suave); text-wrap: pretty; }
.detalhe__frete b { font-weight: 500; color: var(--mar); }
.detalhe h3 { margin: var(--e-5) 0 var(--e-2); font-size: var(--t-m); line-height: 1.2; }
.detalhe__itens li { padding: var(--e-2) 0 var(--e-2) 28px; font-size: var(--t-s); line-height: 1.55; }
.detalhe__itens li::before { top: 14px; }

/* recado: prévia do cartão em estilo bilhete, escrita direto na etiqueta */
.recado { margin-top: var(--e-6); }
.recado__rotulo { display: block; font-weight: 500; font-size: var(--t-m); line-height: 1.2; }
.recado__rotulo small { font-weight: 400; color: var(--texto-suave); }
.recado__dica { margin-top: var(--e-1); font-size: var(--t-s); line-height: 1.55; color: var(--texto-suave); }
.etiqueta {
  position: relative; margin: var(--e-4) var(--e-2) 0; padding: var(--e-7) var(--e-5) var(--e-3);
  transform: rotate(-1.2deg);
  filter: drop-shadow(0 12px 14px rgba(15,59,68,.16)) drop-shadow(0 1px 1px rgba(15,59,68,.18));
}
.etiqueta::before {
  content: ""; position: absolute; inset: 0; z-index: -1;
  background: radial-gradient(120% 80% at 50% 0%, #FFFDF8, var(--papel) 70%);
  clip-path: polygon(20px 0, calc(100% - 20px) 0, 100% 24px, 100% 100%, 0 100%, 0 24px);
  border-radius: 0 0 14px 14px;
}
.etiqueta__ilhos {
  position: absolute; left: 50%; top: var(--e-4); width: 14px; height: 14px; translate: -50% 0;
  border-radius: 50%; background: var(--nevoa);
  box-shadow: 0 0 0 3px var(--bronze), inset 0 1px 2px rgba(15,59,68,.35);
}
.etiqueta__texto {
  --linha: 2rem;
  display: block; width: 100%; min-height: calc(var(--linha) * 3); padding: 0 var(--e-1); margin: 0;
  border: 0; resize: none; background: transparent;
  font-family: var(--mao); font-size: var(--t-xl); font-weight: 500; line-height: var(--linha); color: var(--mar);
  background-image: repeating-linear-gradient(180deg, transparent 0 calc(var(--linha) - 1px), rgba(19,122,140,.22) calc(var(--linha) - 1px) var(--linha));
  background-attachment: local;
}
.etiqueta__texto::placeholder { color: #5F7D84; }
.etiqueta__texto:focus { outline: none; }
.etiqueta:focus-within .etiqueta__texto { outline: 1.5px dashed var(--agua-funda); outline-offset: var(--e-2); border-radius: 4px; }
.etiqueta:focus-within .etiqueta__ilhos { box-shadow: 0 0 0 3px var(--agua-funda), inset 0 1px 2px rgba(15,59,68,.35); }
.recado__conta { margin-top: var(--e-3); text-align: right; font-size: var(--t-xs); line-height: 1.2; color: var(--texto-suave); font-variant-numeric: tabular-nums; }
.recado__conta.perto { color: var(--bronze); font-weight: 500; }

.detalhe__direto {
  display: flex; align-items: center; min-height: 44px; margin: var(--e-5) 0 var(--e-2);
  text-align: left; font-size: var(--t-s); line-height: 1.2; font-weight: 500; color: var(--agua-funda);
}

/* barra de ação sempre à vista: quantidade + o único botão principal da tela */
.detalhe__acoes {
  position: sticky; bottom: 0; z-index: 3; gap: var(--e-3);
  margin: var(--e-4) calc(var(--e-7) * -1) 0; padding: var(--e-4) var(--e-7) var(--e-5);
  background: rgba(255,255,255,.96); backdrop-filter: blur(8px); -webkit-backdrop-filter: blur(8px);
  border-top: 1px solid var(--nevoa-2);
}
.detalhe__info > .detalhe__acoes { margin-top: auto; }
.qtd output { font-variant-numeric: tabular-nums; }
.qtd button:disabled { opacity: .3; cursor: default; }
.detalhe__adicionar { justify-content: space-between; padding: 0 var(--e-5); gap: var(--e-4); font-weight: 600; line-height: 1.2; }
.detalhe__adicionar b { font-weight: 600; padding-left: var(--e-4); border-left: 1px solid rgba(255,255,255,.4); font-variant-numeric: tabular-nums; }
.detalhe__adicionar b:empty { display: none; }
.detalhe__adicionar:has(b:empty) { justify-content: center; }

@media (max-width: 960px) {
  .detalhe { height: auto; max-height: calc(100dvh - var(--e-6)); overflow-y: auto; }
  .detalhe[open] { display: block; }
  .detalhe__info { overflow: visible; padding: var(--e-6) var(--e-6) 0; }
  .detalhe__acoes { margin: var(--e-4) calc(var(--e-6) * -1) 0; padding: var(--e-3) var(--e-6) calc(var(--e-3) + env(safe-area-inset-bottom)); }
}
@media (max-width: 600px) {
  .detalhe { --w: min(60vw, 240px); width: 100%; max-width: 100%; height: 100dvh; max-height: 100dvh; border-radius: 0; box-shadow: none; }
  .detalhe__arco { margin-top: var(--e-8); aspect-ratio: 5 / 6; border-width: 4px; }
  .detalhe__ondas { margin-bottom: var(--e-2); height: 32px; }
  .detalhe__info { padding: var(--e-5) var(--e-4) 0; }
  .detalhe h2 { padding-right: 0; }
  .detalhe__preco { font-size: var(--t-3xl); }
  .etiqueta { margin-inline: var(--e-1); }
  .detalhe__acoes { margin: var(--e-4) calc(var(--e-4) * -1) 0; padding: var(--e-3) var(--e-4) calc(var(--e-3) + env(safe-area-inset-bottom)); }
  .detalhe__acoes .qtd { height: 52px; }
  .detalhe__acoes .qtd button { width: 44px; }
  .detalhe__acoes .detalhe__adicionar {
    flex: 1; min-width: 0; flex-direction: column; justify-content: center; gap: 0;
    padding: 0 var(--e-3); white-space: normal;
  }
  .detalhe__adicionar b { padding: 0; border: 0; font-size: var(--t-s); font-weight: 500; opacity: .92; }
}

/* ---------- Aviso flutuante ---------- */
.aviso-flutuante {
  display: flex; align-items: center; gap: var(--e-3);
  width: max-content; max-width: calc(100vw - var(--e-6)); white-space: normal; line-height: 1.2;
  padding: var(--e-1) var(--e-1) var(--e-1) var(--e-3); min-height: 52px; box-shadow: var(--sombra);
}
.aviso-flutuante:not(:has(button)) { padding-right: var(--e-5); }
.aviso-flutuante__ok {
  flex: none; width: 24px; height: 24px; padding: var(--e-1); border-radius: 50%;
  background: var(--sol); fill: none; stroke: var(--mar); stroke-width: 2.6; stroke-linecap: round; stroke-linejoin: round;
}
.aviso-flutuante button {
  flex: none; pointer-events: auto; min-height: 44px; padding: 0 var(--e-4); border-radius: 999px; border: 0;
  background: rgba(255,255,255,.14); color: #fff; font-weight: 600; white-space: nowrap;
}
.aviso-flutuante button:hover { background: rgba(255,255,255,.24); }
.aviso-flutuante:not(.ativo) button { pointer-events: none; }

/* ---------- Botão flutuante da sacola (celular) ---------- */
.sacola-flutuante { display: none; }
@media (max-width: 600px) {
  .sacola-flutuante {
    position: fixed; left: var(--e-4); right: var(--e-4); bottom: calc(var(--e-4) + env(safe-area-inset-bottom)); z-index: 40;
    display: flex; align-items: center; gap: var(--e-3); min-height: 56px; padding: 0 var(--e-2) 0 var(--e-4);
    border: 1.5px solid rgba(233,181,102,.45); /* destaca a barra também sobre o rodapé escuro */
    border-radius: 999px; background: var(--mar); color: #fff; font-weight: 500; line-height: 1.2; text-align: left;
    box-shadow: var(--sombra);
  }
  .sacola-flutuante svg { flex: none; width: 24px; height: 24px; fill: none; stroke: var(--sol); stroke-width: 1.8; stroke-linejoin: round; }
  .sacola-flutuante span { flex: 1; }
  .sacola-flutuante b {
    padding: 0 var(--e-4); min-height: 44px; display: grid; place-items: center; border-radius: 999px;
    background: var(--sol); color: var(--mar); font-weight: 600; font-variant-numeric: tabular-nums;
  }
  body.sacola-aberta .sacola-flutuante { display: none; }
  /* espaço para a barra não cobrir o fim do rodapé: 56 px da barra + 16 px de margem + 16 px de folga */
  body.tem-sacola .rodape { padding-bottom: calc(var(--e-6) + 88px + env(safe-area-inset-bottom)); }
  body.tem-sacola:not(:has(.rodape)) { padding-bottom: calc(88px + env(safe-area-inset-bottom)); }
  body.tem-sacola .aviso-flutuante { bottom: calc(88px + env(safe-area-inset-bottom)); }
  @media (prefers-reduced-motion: no-preference) {
    .sacola-flutuante { animation: compra-subir .25s var(--curva); }
  }
}

/* ---------- Sacola ---------- */
.sacola__fundo { background: rgba(15,59,68,.55); }
.sacola__painel { width: min(460px, 100%); border-radius: 32px 0 0 32px; overflow: hidden; box-shadow: var(--sombra); }
.sacola__topo { padding: var(--e-4) var(--e-4) var(--e-3) var(--e-5); }
.sacola__topo h2 { font-size: var(--t-xl); line-height: 1.1; display: flex; align-items: baseline; gap: var(--e-3); }
.sacola__topo h2 small { font-family: var(--sans); font-size: var(--t-s); color: var(--texto-suave); font-variant-numeric: tabular-nums; }
.sacola__corpo { padding: 0 var(--e-5) var(--e-5); overscroll-behavior: contain; }

.etapa { padding: var(--e-5) 0 var(--e-2); }
.etapa + .etapa, .sacola__form .etapa:first-child { border-top: 1px dashed var(--nevoa-2); margin-top: var(--e-4); }
.etapa__titulo { display: flex; align-items: center; gap: var(--e-3); font-size: var(--t-l); line-height: 1.15; }
.etapa__titulo b {
  flex: none; width: 32px; height: 32px; display: grid; place-items: center; border-radius: 50%;
  border: 1.5px solid var(--agua); color: var(--bronze); font-weight: 400; font-size: var(--t-s);
}

.item { grid-template-columns: 64px 1fr; gap: var(--e-4); padding: var(--e-4) 0; border-bottom: 1px solid var(--nevoa); }
.item:last-child { border-bottom: 0; }
.item img { width: 64px; height: 80px; border-radius: var(--arco); }
.item__cabeca { display: flex; justify-content: space-between; align-items: baseline; gap: var(--e-3); }
.item h4 { margin: 0; font-family: var(--serif); font-weight: 400; font-size: var(--t-m); line-height: 1.15; }
.item__preco { flex: none; font-weight: 600; font-variant-numeric: tabular-nums; }
.item__unid { font-size: var(--t-xs); color: var(--texto-suave); font-variant-numeric: tabular-nums; }
/* o recado vira uma etiquetinha (bilhete) */
.item__recado {
  position: relative; display: inline-block; max-width: 100%; margin-top: var(--e-2);
  padding: var(--e-1) var(--e-3) var(--e-1) var(--e-5); border-radius: 4px 12px 12px 4px;
  background: var(--papel); box-shadow: 0 1px 2px rgba(15,59,68,.16), 0 8px 12px -8px rgba(15,59,68,.3);
  font-family: var(--mao); font-size: var(--t-l); font-style: normal; line-height: 1.15; color: var(--mar);
  transform: rotate(-1deg); overflow-wrap: anywhere;
}
.item__recado::before {
  content: ""; position: absolute; left: var(--e-2); top: 50%; width: 8px; height: 8px; translate: 0 -50%;
  border-radius: 50%; background: var(--branco); box-shadow: 0 0 0 2px var(--bronze);
}
.item__sem-recado { margin-top: var(--e-1); font-size: var(--t-xs); color: var(--texto-suave); }
.item__linha { margin-top: var(--e-3); gap: var(--e-2); }
.qtd--mini { height: 44px; }
.qtd--mini button { width: 44px; }
.item__remover { min-height: 44px; padding: 0 var(--e-2); font-size: var(--t-s); }

.frete-gratis { margin-top: var(--e-2); padding: var(--e-3) var(--e-4) var(--e-4); border-radius: 14px; background: var(--nevoa); font-size: var(--t-s); line-height: 1.4; }
.frete-gratis b { font-weight: 600; color: var(--agua-funda); font-variant-numeric: tabular-nums; }
.frete-gratis__trilho { position: relative; height: 8px; margin-top: var(--e-3); border-radius: 999px; background: var(--branco); }
.frete-gratis__trilho span {
  position: absolute; left: 0; top: 0; bottom: 0; min-width: 8px; border-radius: inherit;
  background: linear-gradient(90deg, var(--agua), var(--agua-funda));
  transition: width .25s var(--curva);
}
.frete-gratis__trilho span::after {
  content: ""; position: absolute; right: -8px; top: 50%; width: 16px; height: 16px; translate: 0 -50%;
  border-radius: 50%; background: var(--sol); box-shadow: 0 0 0 3px var(--branco);
}
.frete-gratis.ok { background: var(--areia); }
.frete-gratis.ok b { color: var(--mar); }
.frete-gratis.ok .frete-gratis__trilho span { background: linear-gradient(90deg, var(--sol), var(--bronze)); }

/* selo do cuidado (mesmas palavras da etiqueta do Sobre) */
.sacola__cuidado { display: flex; align-items: center; gap: var(--e-2); margin-top: var(--e-4); font-size: var(--t-xs); line-height: 1.4; color: var(--texto-suave); }
.sacola__cuidado svg { flex: none; width: 24px; height: 14px; overflow: visible; }

.sacola__vazia { padding: var(--e-7) var(--e-2); }
.sacola__vazia .raios-sol { width: 152px; margin: 0 auto var(--e-4); }
.sacola__vazia p { margin: 0 auto var(--e-5); max-width: 22rem; line-height: 1.55; }
.sacola__vazia b { display: block; font-family: var(--serif); font-weight: 400; font-size: var(--t-l); line-height: 1.15; color: var(--mar); margin-bottom: var(--e-2); }

.botao-texto {
  display: flex; align-items: center; justify-content: center; min-height: 44px; margin: var(--e-2) auto 0; padding: 0 var(--e-4);
  border: 0; background: none; color: var(--agua-funda); font-weight: 500; text-decoration: underline; text-underline-offset: 3px;
}

/* campos */
.campo { margin-top: var(--e-4); gap: var(--e-2); }
.campo span { font-size: var(--t-s); line-height: 1.2; }
.campo input, .campo select, .campo textarea { min-height: 48px; padding: var(--e-3) var(--e-4); border-radius: 14px; font-size: var(--t-m); }
.campo input::placeholder { color: #5F7D84; }
.campo input[aria-invalid="true"] { border-color: var(--erro); background: var(--erro-fundo); }
.campo input[aria-invalid="true"]:focus { box-shadow: 0 0 0 3px rgba(176,58,46,.2); }
.campos-lado { gap: 0 var(--e-3); }
.etapa > .campos-lado:first-of-type .campo { margin-top: var(--e-4); }
.campo__dica { margin-top: var(--e-2); font-size: var(--t-s); line-height: 1.4; color: var(--texto-suave); }
.campo__erro { display: flex; gap: var(--e-2); align-items: flex-start; margin-top: var(--e-2); font-size: var(--t-s); line-height: 1.4; font-weight: 500; color: var(--erro); }
.campo__erro::before {
  content: "!"; flex: none; width: 18px; height: 18px; margin-top: 1px; display: grid; place-items: center;
  border-radius: 50%; background: var(--erro); color: #fff; font-size: var(--t-xs); font-weight: 600; line-height: 1;
}
.escolha { margin-top: var(--e-4); gap: var(--e-2); }
.escolha legend { font-size: var(--t-s); margin-bottom: var(--e-2); line-height: 1.2; }
.escolha label { position: relative; }
.escolha span { border-radius: 14px; min-height: 48px; }
.escolha--receber span {
  height: auto; min-height: 64px; padding: var(--e-3) var(--e-4); place-items: start;
  grid-template-columns: 24px 1fr; column-gap: var(--e-3); text-align: left; align-content: center;
}
.escolha--receber svg { grid-row: span 2; width: 24px; height: 24px; fill: none; stroke: currentColor; stroke-width: 1.7; stroke-linejoin: round; }
.escolha--receber b { font-weight: 600; line-height: 1.2; }
.escolha small { display: block; font-size: var(--t-xs); font-weight: 400; color: var(--texto-suave); line-height: 1.3; }
.escolha input:checked + span { box-shadow: inset 0 0 0 1px var(--agua-funda); }
.escolha input:checked + span small { color: var(--mar-2); }
.sacola__retirada { margin-top: var(--e-3); padding: var(--e-3) var(--e-4); border-radius: 14px; font-size: var(--t-s); line-height: 1.45; }
.sacola__retirada b { font-weight: 600; }
.escolha--pagamento span { min-height: 64px; padding: var(--e-3) var(--e-4); gap: var(--e-1); }
.escolha--pagamento small { font-size: var(--t-xs); }
.pagamento-unico { margin-top: var(--e-3); padding: var(--e-3) var(--e-4); border-radius: 14px; background: var(--nevoa); font-size: var(--t-s); line-height: 1.45; }
.pagamento-unico b { display: block; font-weight: 600; color: var(--mar); }

/* rodapé com total e o botão final */
.sacola__rodape { padding: var(--e-4) var(--e-5) calc(var(--e-4) + env(safe-area-inset-bottom)); border-top: 1px solid var(--nevoa-2); }
.sacola__aviso { margin: 0 0 var(--e-3); padding: var(--e-3) var(--e-4); border-radius: 14px; background: var(--erro-fundo); color: var(--erro); font-size: var(--t-s); line-height: 1.4; }
/* parciais numa linha só (cestas | entrega), total embaixo: rodapé mais baixo no celular */
.sacola__total {
  grid-template-columns: auto 1fr auto auto; gap: var(--e-1) 0; margin: 0 0 var(--e-3);
  font-size: var(--t-s); line-height: 1.4; text-align: left; font-variant-numeric: tabular-nums;
}
.sacola__total dd { text-align: left; color: var(--mar); padding-left: var(--e-2); }
.sacola__total dt { padding-right: 0; }
.sacola__total dd:nth-of-type(1) { padding-right: var(--e-3); }
.sacola__total dd:nth-of-type(2) { text-align: right; }
.sacola__total .total { padding-top: var(--e-2); margin-top: var(--e-1); border-top: 1px dashed var(--nevoa-2); font-size: var(--t-m); font-weight: 600; align-self: end; }
.sacola__total dt.total { grid-column: 1 / 3; }
.sacola__total dd.total { grid-column: 3 / 5; text-align: right; }
/* o total a pagar é o único texto em Outfit 700 */
.sacola__total dd.total { font-family: var(--sans); font-weight: 700; font-size: var(--t-l); line-height: 1.2; }
.sacola__total .gratis { color: var(--agua-funda); font-weight: 600; }
.botao { line-height: 1.2; }
.botao--whats { background: var(--whats-botao); font-weight: 600; }
.botao--whats:hover { background: #126B35; }
.botao--whats .giro { display: none; }
.botao--pagar { background: var(--agua-funda); }
.botao.carregando { opacity: 1; }
.botao.carregando .giro {
  display: block; width: 20px; height: 20px; border-radius: 50%;
  border: 2.5px solid rgba(255,255,255,.4); border-top-color: #fff; animation: compra-giro .8s linear infinite;
}
.botao.carregando svg { display: none !important; }
@keyframes compra-giro { to { transform: rotate(360deg); } }
.sacola__nota { margin-top: var(--e-2); text-align: center; font-size: var(--t-xs); color: var(--texto-suave); line-height: 1.4; text-wrap: pretty; }

@media (max-width: 600px) {
  /* no celular a sacola sobe como uma folha, com o topo arredondado */
  .sacola__painel { top: var(--e-3); width: 100%; border-radius: 28px 28px 0 0; animation-name: compra-folha; }
  .sacola__corpo { padding: 0 var(--e-4) var(--e-5); }
  .sacola__topo { padding: var(--e-3) var(--e-3) var(--e-3) var(--e-4); }
  .sacola__rodape { padding: var(--e-3) var(--e-4) calc(var(--e-3) + env(safe-area-inset-bottom)); }
}
@keyframes compra-folha { from { transform: translateY(100%); } }

/* ---------- Página do pedido ---------- */
.acomp { max-width: 640px; margin: 0 auto; padding: var(--e-6) var(--e-4) var(--e-8); text-align: center; }
.acomp__cena { position: relative; width: 240px; height: 132px; margin: 0 auto var(--e-2); }
.acomp__cena .raios-sol { width: 100%; }
.acomp__cena .raios-sol line, .acomp__cena .raios-sol__disco { stroke-width: 7; }
.acomp__ondas { position: absolute; left: calc(var(--e-5) * -1); bottom: calc(var(--e-2) * -1); width: calc(100% + var(--e-7)); height: 24px; }
.acomp__ondas path { fill: none; stroke: var(--agua); stroke-width: 3; stroke-linecap: round; }
.acomp h1 { font-size: var(--t-3xl); line-height: 1.1; text-wrap: balance; }
.acomp h1:focus { outline: none; }
.acomp__sub { margin: var(--e-3) auto 0; max-width: 34rem; color: var(--texto-suave); line-height: 1.6; text-wrap: pretty; }

/* o número do pedido numa etiqueta de presente */
.acomp__etiqueta {
  position: relative; display: inline-flex; flex-direction: column; align-items: center;
  margin: var(--e-5) auto 0; padding: var(--e-6) var(--e-6) var(--e-3); transform: rotate(-2deg);
  filter: drop-shadow(0 12px 14px rgba(15,59,68,.16)) drop-shadow(0 1px 1px rgba(15,59,68,.18));
}
.acomp__etiqueta::before {
  content: ""; position: absolute; inset: 0; z-index: -1; background: var(--papel);
  clip-path: polygon(16px 0, calc(100% - 16px) 0, 100% 24px, 100% 100%, 0 100%, 0 24px);
  border-radius: 0 0 14px 14px;
}
.acomp__etiqueta::after {
  content: ""; position: absolute; left: 50%; top: var(--e-3); width: 12px; height: 12px; translate: -50% 0;
  border-radius: 50%; background: var(--branco); box-shadow: 0 0 0 2.5px var(--bronze);
}
.acomp__etiqueta span { font-family: var(--mao); font-size: var(--t-l); color: var(--bronze); line-height: 1; }
.acomp__etiqueta b { font-size: var(--t-xl); font-weight: 600; line-height: 1.2; letter-spacing: .04em; color: var(--mar); font-variant-numeric: tabular-nums; }

.acomp__passo {
  margin: var(--e-6) 0 0; padding: var(--e-5); border-radius: 28px; text-align: left;
  background: var(--areia); display: grid; gap: var(--e-4);
}
.acomp__passo p { line-height: 1.55; }
.acomp__passo b { font-weight: 600; color: var(--mar); }
.acomp__passo .botao { width: 100%; }

.linha { list-style: none; padding: 0; margin: var(--e-6) 0; display: grid; grid-template-columns: repeat(4, 1fr); }
.linha li { position: relative; font-size: var(--t-s); color: var(--texto-suave); line-height: 1.2; }
.linha li + li::before {
  content: ""; position: absolute; top: 15px; right: calc(50% + 20px); left: calc(-50% + 20px); height: 3px;
  border-radius: 3px; background: var(--nevoa-2);
}
.linha li.feito + li.feito::before { background: var(--agua-funda); }
.linha b {
  display: grid; place-items: center; width: 32px; height: 32px; margin: 0 auto var(--e-2); border-radius: 50%;
  background: var(--branco); border: 2.5px solid var(--nevoa-2); font-family: var(--serif); font-weight: 400; color: var(--texto-suave);
}
.linha li.feito b { background: var(--agua-funda); border-color: var(--agua-funda); color: #fff; }
.linha li.feito { color: var(--mar); font-weight: 500; }
.linha li.agora b { box-shadow: 0 0 0 4px rgba(108,217,234,.4); }

.cartao { background: var(--nevoa); border-radius: 28px; padding: var(--e-5); text-align: left; }
.cartao h2 { font-size: var(--t-l); line-height: 1.15; margin-bottom: var(--e-2); }
.cartao ul { list-style: none; margin: 0; padding: 0; }
.cartao li { display: flex; justify-content: space-between; align-items: flex-start; gap: var(--e-3); padding: var(--e-3) 0; border-bottom: 1px dashed var(--nevoa-2); }
.cartao li > span:last-child { flex: none; font-weight: 500; font-variant-numeric: tabular-nums; }
.cartao li .item__recado { display: table; margin-top: var(--e-2); }
.cartao dl { display: grid; grid-template-columns: 1fr auto; gap: var(--e-2) var(--e-3); margin: var(--e-4) 0 0; font-variant-numeric: tabular-nums; }
.cartao dt { color: var(--texto-suave); }
.cartao dd { margin: 0; text-align: right; }
.cartao .total { font-weight: 600; color: var(--mar); padding-top: var(--e-2); border-top: 1px dashed var(--nevoa-2); }
.cartao dd.total { font-weight: 700; font-size: var(--t-l); line-height: 1.2; }
.acoes { display: flex; flex-wrap: wrap; gap: var(--e-3); justify-content: center; margin-top: var(--e-6); }
.alerta { margin-top: var(--e-5); padding: var(--e-3) var(--e-4); border-radius: 14px; background: var(--areia); }
.acomp__carregando { display: block; width: 32px; height: 32px; margin: var(--e-5) auto 0; border-radius: 50%; border: 3px solid var(--nevoa-2); border-top-color: var(--agua-funda); animation: compra-giro .8s linear infinite; }

@media (prefers-reduced-motion: no-preference) {
  .acomp.festa .raios-sol line { stroke-dasharray: 1; stroke-dashoffset: 1; animation: compra-raio .35s calc(.1s + var(--i) * 25ms) var(--curva) forwards; }
  .acomp.festa .raios-sol__disco { stroke-dasharray: 1; stroke-dashoffset: 1; animation: compra-raio .5s var(--curva) forwards; }
  .acomp.festa .acomp__etiqueta { animation: compra-balanco .6s .3s var(--curva) both; transform-origin: 50% 12px; }
}
@keyframes compra-balanco {
  0% { opacity: 0; transform: translateY(-16px) rotate(-10deg); }
  55% { opacity: 1; transform: translateY(0) rotate(3deg); }
  100% { transform: rotate(-2deg); }
}
@media (prefers-reduced-motion: reduce) {
  .sacola__painel { animation: none; }
  .frete-gratis__trilho span { transition: none; }
}
@media (max-width: 600px) {
  .acomp { padding-top: var(--e-5); }
  .acomp__cena { width: 200px; height: 110px; }
  .cartao { padding: var(--e-5) var(--e-4); }
  .acoes .botao { flex: 1 1 100%; }
}
