/* Cachepô Kids: papel quadriculado, títulos serifados e rabiscos do catálogo */

:root {
  --azul: #004AAD;
  --framboesa: #AF2B5A;
  --laranja: #FF751F;
  --menta: #51B8A1;
  --amarelo: #EB9F08;
  --rosa: #DE4573;
  --violeta: #271C6B;
  --base: #FAFAF6;
  --laranja-botao: #B85500;
  --laranja-botao-escuro: #9C4800;
  --verde: #237B68;
  --branco: #FFFFFF;

  --linha-salmao: #F1CFC3;
  --linha-salmao-claro: #F7E2DA;
  --linha-amarelo: #F5E2AC;
  --linha-azul: #D8E0EB;
  --linha-cinza: #E0E0DA;

  --serif: "DM Serif Display", Georgia, "Times New Roman", serif;
  --texto: "Nunito", "Trebuchet MS", Verdana, sans-serif;

  --passo-papel: 40px;
  --altura-topo: 76px;
  --gutter: 32px;
}

*, *::before, *::after { box-sizing: border-box; }

html {
  scroll-padding-top: calc(var(--altura-topo) + 12px);
  -webkit-text-size-adjust: 100%;
}

@media (prefers-reduced-motion: no-preference) {
  html { scroll-behavior: smooth; }
}

body {
  margin: 0;
  background: var(--base);
  color: var(--violeta);
  font-family: var(--texto);
  font-size: 17px;
  line-height: 1.5;
}

img, svg { display: block; max-width: 100%; }
h1, h2, h3, p, ul, ol, figure, fieldset { margin: 0; padding: 0; }
ul, ol { list-style: none; }
fieldset { border: 0; min-width: 0; }
button, input, textarea { font: inherit; color: inherit; }
button { cursor: pointer; }
a { color: var(--azul); }

:focus-visible {
  outline: 3px solid var(--azul);
  outline-offset: 2px;
  border-radius: 4px;
}

.sprite { position: absolute; width: 0; height: 0; }

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

.pular {
  position: absolute;
  left: 12px;
  top: -80px;
  z-index: 60;
  padding: 10px 16px;
  background: var(--violeta);
  color: var(--branco);
  border-radius: 8px;
  font-weight: 800;
}
.pular:focus { top: 8px; }

.sem-js {
  padding: 16px var(--gutter);
  background: var(--branco);
  text-align: center;
  font-weight: 700;
}

/* ---------- Papel quadriculado ------------------------------------------ */

.papel {
  --linha: var(--linha-cinza);
  background-color: var(--base);
  background-image:
    linear-gradient(var(--linha) 1px, transparent 1px),
    linear-gradient(90deg, var(--linha) 1px, transparent 1px);
  background-size: var(--passo-papel) var(--passo-papel);
  background-position: center top;
}
.papel-salmao { --linha: var(--linha-salmao); }
.papel-salmao-claro { --linha: var(--linha-salmao-claro); }
.papel-amarelo { --linha: var(--linha-amarelo); }
.papel-azul { --linha: var(--linha-azul); }
.papel-cinza { --linha: var(--linha-cinza); }

/* ---------- Cor dos rabiscos -------------------------------------------- */

.r-azul { color: var(--azul); }
.r-amarelo { color: var(--amarelo); }

/* ---------- Número laranja ---------------------------------------------- */

.numero {
  flex: none;
  display: inline-grid;
  place-items: center;
  width: 34px;
  height: 34px;
  border-radius: 50%;
  background: var(--laranja-botao);
  color: var(--branco);
  font-family: var(--serif);
  font-size: 19px;
  line-height: 1;
}
.numero-grande { width: 56px; height: 56px; font-size: 30px; }
.numero-pequeno { width: 28px; height: 28px; background: var(--azul); font-size: 16px; }

/* ---------- Botões ------------------------------------------------------ */

.botao {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-height: 52px;
  padding: 10px 26px;
  border: 2px solid var(--laranja-botao);
  border-radius: 999px;
  background: var(--laranja-botao);
  color: var(--branco);
  font-family: var(--texto);
  font-size: 19px;
  font-weight: 800;
  line-height: 1.2;
  text-align: center;
  text-decoration: none;
  transition: background-color .15s ease, border-color .15s ease, color .15s ease;
}
.botao:hover { background: var(--laranja-botao-escuro); border-color: var(--laranja-botao-escuro); }
.botao-grande { min-height: 58px; padding: 12px 36px; font-size: 21px; }
.botao-cheio { width: 100%; }
.botao-contorno { width: 100%; background: var(--branco); color: var(--laranja-botao-escuro); }
.botao-contorno:hover { background: var(--laranja-botao-escuro); color: var(--branco); }

.botao-fechar {
  flex: none;
  min-height: 44px;
  padding: 6px 16px;
  border: 2px solid var(--violeta);
  border-radius: 999px;
  background: var(--branco);
  color: var(--violeta);
  font-weight: 800;
  transition: background-color .15s ease, color .15s ease;
}
.botao-fechar:hover { background: var(--violeta); color: var(--branco); }

.botao-texto {
  min-height: 44px;
  padding: 6px 4px;
  border: 0;
  background: none;
  color: var(--azul);
  font-weight: 700;
  text-decoration: underline;
  text-underline-offset: 3px;
  transition: color .15s ease;
}
.botao-texto:hover { color: var(--framboesa); }

/* ---------- Cabeçalho --------------------------------------------------- */

.topo {
  position: sticky;
  top: 0;
  z-index: 40;
  background: var(--base);
  border-bottom: 4px solid transparent;
  border-image: linear-gradient(90deg,
    var(--azul) 0 16.66%, var(--framboesa) 0 33.33%, var(--laranja) 0 50%,
    var(--menta) 0 66.66%, var(--amarelo) 0 83.33%, var(--rosa) 0) 1;
}
.topo-dentro {
  display: flex;
  align-items: center;
  gap: 16px 28px;
  max-width: 1400px;
  min-height: 72px;
  margin-inline: auto;
  padding: 8px var(--gutter);
}
.topo-logo { flex: none; display: block; }
.topo-logo img { width: 130px; min-width: 120px; height: auto; }
.topo-nav { display: flex; gap: 4px 24px; margin-inline: auto; }
.topo-nav a {
  display: inline-flex;
  align-items: center;
  min-height: 44px;
  padding-inline: 6px;
  color: var(--violeta);
  font-weight: 800;
  text-decoration: none;
  transition: color .15s ease;
}
.topo-nav a:hover { color: var(--laranja-botao); }

.botao-sacola {
  flex: none;
  display: inline-flex;
  align-items: center;
  gap: 8px;
  min-height: 48px;
  padding: 6px 12px 6px 16px;
  border: 2px solid var(--violeta);
  border-radius: 999px;
  background: var(--violeta);
  color: var(--branco);
  font-weight: 800;
  transition: background-color .15s ease, border-color .15s ease;
}
.botao-sacola:hover { background: var(--azul); border-color: var(--azul); }
.contador {
  display: grid;
  place-items: center;
  min-width: 28px;
  height: 28px;
  padding-inline: 6px;
  border-radius: 999px;
  background: var(--branco);
  color: var(--violeta);
  font-size: 16px;
  font-weight: 900;
  line-height: 1;
}

/* ---------- Abertura ---------------------------------------------------- */

.abertura { overflow-x: clip; }
.abertura-dentro {
  display: grid;
  grid-template-columns: minmax(0, 5fr) minmax(0, 8fr);
  align-items: end;
  gap: 24px 40px;
  max-width: 1400px;
  margin-inline: auto;
  padding: 24px var(--gutter) 0;
}
.abertura-palco {
  position: relative;
  order: 2;
  width: 100%;
  max-width: 800px;
  margin-inline: auto;
  aspect-ratio: 760 / 600;
}
.arco-titulo { position: absolute; inset: 0; margin: 0; font-weight: 400; }
.arco { width: 100%; height: 100%; }
.arco-texto {
  fill: var(--verde);
  font-family: var(--serif);
  font-size: 73px;
  letter-spacing: .5px;
}
.crianca {
  position: absolute;
  bottom: 0;
  width: auto;
  max-width: none;
}
.crianca-esq { left: 10.1%; height: 48%; }
.crianca-meio { left: 30.5%; height: 70%; }
.crianca-dir { left: 69.7%; height: 48%; }

.abertura-texto {
  position: relative;
  order: 1;
  align-self: center;
  padding-bottom: 40px;
}
.abertura-chamada {
  font-family: var(--serif);
  font-size: clamp(40px, 4.4vw, 66px);
  line-height: 1.06;
  color: var(--laranja-botao);
  text-wrap: balance;
}
.abertura-onda {
  width: 150px;
  height: 25px;
  margin-block: 18px 14px;
  color: var(--amarelo);
}
.abertura-apoio {
  max-width: 30em;
  margin-bottom: 26px;
  font-size: 19px;
  font-weight: 600;
}

/* ---------- Faixa ------------------------------------------------------- */

.faixa {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
}
.faixa li {
  display: grid;
  place-items: center;
  min-height: 62px;
  padding: 10px 12px;
  color: var(--branco);
  font-size: 19px;
  font-weight: 800;
  line-height: 1.2;
  text-align: center;
}
.faixa li:nth-child(1) { background: var(--azul); }
.faixa li:nth-child(2) { background: var(--framboesa); }
.faixa li:nth-child(3) { background: var(--verde); }

/* ---------- Seções ------------------------------------------------------ */

.secao { padding-block: 72px; }
.dentro {
  max-width: 1400px;
  margin-inline: auto;
  padding-inline: var(--gutter);
}
.dentro-estreito { max-width: 800px; }

.titulo-bloco {
  position: relative;
  width: fit-content;
  max-width: 100%;
  margin-inline: auto;
  padding-inline: 84px;
}
.titulo {
  color: var(--laranja-botao);
  font-family: var(--serif);
  font-size: clamp(38px, 5.4vw, 76px);
  font-weight: 400;
  line-height: 1.08;
  text-align: center;
  text-wrap: balance;
}
.titulo-medio { font-size: clamp(38px, 4.2vw, 58px); }
.subtitulo { margin-top: 12px; font-size: 19px; font-weight: 600; text-align: center; }

.risco {
  position: absolute;
  top: 50%;
  width: 58px;
  height: 52px;
  margin-top: -26px;
}
.risco-esq { left: 4px; }
.risco-dir { right: 4px; }

/* ---------- Grade de estampas ------------------------------------------- */

.grade {
  display: grid;
  grid-template-columns: repeat(5, minmax(0, 1fr));
  gap: 20px;
  margin-top: 40px;
}
.cartao {
  --chao: var(--azul);
  --linha: var(--linha-salmao-claro);
  position: relative;
  display: flex;
  flex-direction: column;
  background-color: var(--branco);
  background-image:
    linear-gradient(var(--linha) 1px, transparent 1px),
    linear-gradient(90deg, var(--linha) 1px, transparent 1px);
  background-size: 28px 28px;
  border: 1px solid var(--linha-cinza);
  border-radius: 10px;
  overflow: hidden;
  transition: border-color .15s ease;
}
.cartao:hover { border-color: var(--laranja-botao); }
.cartao:nth-child(7n+2) { --chao: var(--framboesa); --linha: var(--linha-amarelo); }
.cartao:nth-child(7n+3) { --chao: var(--laranja); --linha: var(--linha-azul); }
.cartao:nth-child(7n+4) { --chao: var(--menta); --linha: var(--linha-salmao-claro); }
.cartao:nth-child(7n+5) { --chao: var(--amarelo); --linha: var(--linha-azul); }
.cartao:nth-child(7n+6) { --chao: var(--rosa); --linha: var(--linha-amarelo); }
.cartao:nth-child(7n+7) { --chao: var(--violeta); --linha: var(--linha-salmao-claro); }

.cartao-topo { flex: 1; padding: 12px 14px 8px; }
.cartao-marcas { display: flex; align-items: center; justify-content: space-between; gap: 6px; min-height: 34px; margin-bottom: 6px; }
.cartao-nome {
  color: var(--laranja-botao);
  font-family: var(--serif);
  font-size: 26px;
  font-weight: 400;
  line-height: 1.1;
}
.cartao-ref { margin-top: 2px; font-size: 16px; font-weight: 700; }

.selo {
  flex: none;
  padding: 4px 10px;
  border-radius: 999px;
  background: var(--framboesa);
  color: var(--branco);
  font-size: 15px;
  font-weight: 800;
  line-height: 1.2;
  white-space: nowrap;
}

/* A foto sempre encosta na faixa de baixo: nunca fica um tronco flutuando. */
.cartao-foto { position: relative; aspect-ratio: 3 / 4; flex: none; }
.cartao-foto img {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  object-fit: contain;
  object-position: center bottom;
}
.cartao-base {
  border-top: 5px solid var(--chao);
  padding: 10px 14px 14px;
  background: var(--branco);
}
.cartao-preco { line-height: 1.2; font-size: 16px; font-weight: 700; }
.cartao-preco strong {
  display: block;
  color: var(--laranja-botao);
  font-size: 23px;
  font-weight: 900;
  white-space: nowrap;
}
.cartao-botao {
  width: 100%;
  min-height: 48px;
  margin-top: 10px;
  padding: 8px 10px;
  font-size: 19px;
}
.cartao-botao::after { content: ""; position: absolute; inset: 0; }
.cartao:hover .cartao-botao { background: var(--laranja-botao-escuro); border-color: var(--laranja-botao-escuro); }

/* ---------- Preços (como a página 4 do catálogo) ------------------------ */

.tabela-info {
  margin-top: 6px;
  font-family: var(--serif);
  font-size: 20px;
  letter-spacing: 1.6px;
  text-align: center;
}
.precos { display: grid; gap: 20px; margin-top: 32px; }
.preco-linha {
  position: relative;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px 20px;
  padding: 22px 28px 22px 34px;
  background: var(--branco);
  border: 2px solid var(--linha-cinza);
  border-radius: 18px;
}
.preco-linha::before {
  content: "";
  position: absolute;
  left: -3px;
  top: -2px;
  bottom: -2px;
  width: 8px;
  border-radius: 8px;
  background: var(--laranja);
}
.preco-linha:first-child { border-color: var(--laranja); }
.preco-nome { font-size: 28px; font-weight: 900; line-height: 1.15; color: var(--violeta); }
.preco-faixa { font-size: 17px; font-weight: 600; }
.preco-linha > div:first-child { min-width: 0; }
.preco-valor {
  flex: none;
  color: var(--laranja-botao);
  font-size: clamp(26px, 8vw, 48px);
  font-weight: 900;
  line-height: 1.1;
  white-space: nowrap;
}
.filete {
  width: 280px;
  max-width: 70%;
  height: 5px;
  margin: 36px auto 14px;
  border: 0;
  background: var(--linha-salmao);
}
.precos-rodape {
  color: var(--laranja-botao);
  font-family: var(--serif);
  font-size: 30px;
  line-height: 1.15;
  text-align: center;
}
.arroba { margin-top: 8px; font-family: var(--serif); font-size: 24px; text-align: center; }
.arroba a { color: var(--laranja-botao-escuro); text-decoration: none; transition: color .15s ease; }
.arroba a:hover { color: var(--framboesa); text-decoration: underline; }

/* ---------- Como comprar ------------------------------------------------ */

.passos {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: 36px;
  margin-top: 44px;
}
.passos li { position: relative; }
.passos h3 {
  margin-top: 14px;
  color: var(--laranja-botao);
  font-family: var(--serif);
  font-size: 32px;
  font-weight: 400;
  line-height: 1.12;
}
.passos p { margin-top: 8px; font-size: 18px; font-weight: 600; }
.passo-seta {
  position: absolute;
  top: 6px;
  left: 78px;
  right: 0;
  width: calc(100% - 78px);
  max-width: 130px;
  height: 46px;
}

/* ---------- Para pedidos e política ------------------------------------- */

.duas-folhas {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 56px;
  max-width: 1200px;
}
.folha p { margin-top: 12px; font-size: 18px; font-weight: 600; }
.folha-subtitulo {
  margin-top: 14px;
  font-size: 18px;
  font-weight: 800;
  letter-spacing: .6px;
  text-align: center;
  text-transform: uppercase;
}
.lista-rabisco { margin-top: 22px; display: grid; gap: 16px; font-size: 24px; font-family: var(--serif); line-height: 1.35; }
.lista-rabisco li { position: relative; padding-left: 40px; }
.lista-rabisco li::before {
  content: "";
  position: absolute;
  left: 0;
  top: 4px;
  width: 26px;
  height: 26px;
  background: var(--amarelo);
  -webkit-mask: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 56 56'%3E%3Cpath fill='none' stroke='%23000' stroke-width='5' stroke-linecap='round' stroke-linejoin='round' d='M28 4c2 8 4 13 7 17 6 0 12 0 18 2-5 4-10 8-13 12 2 6 4 12 4 18-6-4-11-7-16-10-6 3-12 7-17 10 1-7 3-13 5-18-4-4-9-8-13-12 6-2 12-2 18-2 3-5 5-10 8-18'/%3E%3C/svg%3E") center / contain no-repeat;
  mask: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 56 56'%3E%3Cpath fill='none' stroke='%23000' stroke-width='5' stroke-linecap='round' stroke-linejoin='round' d='M28 4c2 8 4 13 7 17 6 0 12 0 18 2-5 4-10 8-13 12 2 6 4 12 4 18-6-4-11-7-16-10-6 3-12 7-17 10 1-7 3-13 5-18-4-4-9-8-13-12 6-2 12-2 18-2 3-5 5-10 8-18'/%3E%3C/svg%3E") center / contain no-repeat;
}

/* ---------- Não encontrou ----------------------------------------------- */

.nao-encontrou { text-align: center; }
.nao-encontrou-risco { width: 58px; height: 54px; margin: 0 auto 10px; }
.nao-encontrou-texto {
  margin-block: 14px 26px;
  color: var(--laranja-botao-escuro);
  font-family: var(--serif);
  font-size: clamp(25px, 2.6vw, 32px);
  line-height: 1.25;
}

/* ---------- Rodapé ------------------------------------------------------ */

.rodape { padding-block: 56px 44px; text-align: center; }
.rodape-logo { width: 200px; height: auto; margin: 0 auto 24px; }
.rodape-obrigada {
  color: var(--laranja-botao);
  font-family: var(--serif);
  font-size: clamp(52px, 7vw, 92px);
  line-height: 1;
}
.rodape-pedido {
  margin-top: 6px;
  color: var(--laranja-botao);
  font-family: var(--serif);
  font-size: clamp(28px, 3.2vw, 40px);
  line-height: 1.15;
}

/* ---------- Dialogs ----------------------------------------------------- */

dialog {
  padding: 0;
  border: 0;
  color: var(--violeta);
  background: var(--base);
  max-width: none;
  max-height: none;
}
dialog::backdrop { background: rgba(39, 28, 107, .55); }
dialog[open] { animation: aparecer .16s ease-out; }
@keyframes aparecer { from { opacity: 0; } to { opacity: 1; } }

/* ---------- Painel de escolha ------------------------------------------- */

.painel {
  width: min(1060px, calc(100vw - 48px));
  height: min(760px, calc(100vh - 48px));
  height: min(760px, calc(100dvh - 48px));
  margin: auto;
  border-radius: 18px;
  overflow: hidden;
}
.painel[open] { display: flex; flex-direction: column; }

.painel-barra {
  flex: none;
  display: flex;
  align-items: center;
  gap: 12px;
  padding: 12px 20px;
  background: var(--branco);
  border-bottom: 1px solid var(--linha-cinza);
}
.painel-titulo { min-width: 0; margin-right: auto; }
.painel-titulo h2 {
  color: var(--laranja-botao);
  font-family: var(--serif);
  font-size: 32px;
  font-weight: 400;
  line-height: 1.08;
}
.painel-titulo p { font-size: 16px; font-weight: 700; }

.painel-corpo {
  flex: 1;
  min-height: 0;
  display: grid;
  grid-template-columns: minmax(0, 46%) minmax(0, 1fr);
}
.painel-fotos {
  display: flex;
  flex-direction: column;
  min-height: 0;
  border-right: 1px solid var(--linha-cinza);
}
.bolinhas {
  flex: none;
  display: flex;
  justify-content: center;
  gap: 2px;
  padding-top: 8px;
}
.bolinhas[hidden] { display: none; }
.bolinhas button {
  display: grid;
  place-items: center;
  width: 40px;
  height: 40px;
  padding: 0;
  border: 0;
  background: none;
}
.bolinhas button::before {
  content: "";
  width: 16px;
  height: 16px;
  border: 2px solid var(--violeta);
  border-radius: 50%;
  background: var(--branco);
  transition: background-color .15s ease;
}
.bolinhas button:hover::before { background: var(--linha-amarelo); }
.bolinhas button[aria-current="true"]::before { background: var(--violeta); }

.painel-foto { position: relative; flex: 1; min-height: 0; touch-action: pan-y; }
.painel-foto > img {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  object-fit: contain;
  object-position: center bottom;
}
.detalhe {
  position: absolute;
  top: 12px;
  right: 12px;
  width: 136px;
  text-align: center;
}
.detalhe[hidden] { display: none; }
.detalhe img { width: 116px; height: 116px; margin-inline: auto; }
.detalhe figcaption { margin-top: 2px; font-size: 16px; font-weight: 800; line-height: 1.2; }

.painel-opcoes {
  display: flex;
  flex-direction: column;
  gap: 18px;
  min-height: 0;
  padding: 18px 24px 0;
  overflow-y: auto;
  overscroll-behavior: contain;
  scroll-padding-bottom: 170px;
  background: var(--branco);
}
.painel-versao-unica { font-size: 18px; font-weight: 800; }
.passo legend {
  display: flex;
  align-items: center;
  gap: 8px;
  padding: 0;
  margin-bottom: 8px;
  font-size: 19px;
  font-weight: 800;
}

.opcoes { display: grid; gap: 8px; }
.opcoes-versao { grid-template-columns: repeat(auto-fit, minmax(150px, 1fr)); }
.opcoes-tamanho { grid-template-columns: repeat(auto-fill, minmax(72px, 1fr)); }
.opcao { position: relative; display: block; cursor: pointer; }
.opcao input {
  position: absolute;
  opacity: 0;
  width: 100%;
  height: 100%;
  margin: 0;
  cursor: pointer;
}
.opcao-caixa {
  display: flex;
  align-items: center;
  gap: 10px;
  min-height: 52px;
  padding: 7px 14px 7px 10px;
  border: 2px solid #B9B4D4;
  border-radius: 12px;
  background: var(--branco);
  font-weight: 700;
  line-height: 1.2;
  transition: background-color .15s ease, border-color .15s ease;
}
.opcao:hover .opcao-caixa { border-color: var(--violeta); }
.opcao-marca {
  flex: none;
  display: grid;
  place-items: center;
  width: 24px;
  height: 24px;
  border: 2px solid #8C86B3;
  border-radius: 50%;
  background: var(--branco);
}
.opcao-marca::after {
  content: "";
  width: 11px;
  height: 6px;
  margin-top: -3px;
  border-left: 3px solid var(--branco);
  border-bottom: 3px solid var(--branco);
  transform: rotate(-45deg);
  opacity: 0;
}
.opcao-texto { flex: 1; min-width: 0; }
.opcao-texto small { display: block; font-size: 16px; font-weight: 600; }
.opcao-preco { flex: none; color: var(--laranja-botao-escuro); font-size: 19px; font-weight: 900; white-space: nowrap; }

.opcao input:checked + .opcao-caixa {
  border-color: var(--violeta);
  background: #FFF3E6;
  box-shadow: inset 0 0 0 1px var(--violeta);
}
.opcao input:checked + .opcao-caixa .opcao-marca { background: var(--violeta); border-color: var(--violeta); }
.opcao input:checked + .opcao-caixa .opcao-marca::after { opacity: 1; }
.opcao input:focus-visible + .opcao-caixa { outline: 3px solid var(--azul); outline-offset: 2px; }

.opcoes-tamanho .opcao-caixa { justify-content: center; padding-inline: 6px; gap: 6px; font-size: 19px; font-weight: 800; }
.opcoes-tamanho .opcao-texto { flex: none; }

.nota-foto { margin-top: 8px; font-size: 16px; font-weight: 600; font-style: italic; }

.erro {
  margin-top: 6px;
  color: var(--framboesa);
  font-size: 16px;
  font-weight: 800;
}
.erro::before { content: "! "; font-weight: 900; }
.erro[hidden] { display: none; }

.painel-fechamento {
  position: sticky;
  bottom: 0;
  display: grid;
  grid-template-columns: auto 1fr;
  align-items: center;
  gap: 10px 20px;
  margin: auto -24px 0;
  padding: 12px 24px 16px;
  background: var(--branco);
  border-top: 2px solid var(--linha-amarelo);
}
.painel-fechamento .botao { grid-column: 1 / -1; }
.rotulo { display: block; font-size: 16px; font-weight: 800; }
.painel-total { text-align: right; }
.painel-total strong {
  color: var(--laranja-botao);
  font-size: 30px;
  font-weight: 900;
  line-height: 1.1;
  white-space: nowrap;
}

.qtd {
  display: inline-flex;
  align-items: center;
  border: 2px solid var(--violeta);
  border-radius: 999px;
  background: var(--branco);
  overflow: hidden;
}
.qtd button {
  width: 46px;
  height: 44px;
  border: 0;
  background: none;
  color: var(--violeta);
  font-size: 24px;
  font-weight: 800;
  line-height: 1;
  transition: background-color .15s ease;
}
.qtd button:hover:not(:disabled) { background: var(--linha-amarelo); }
.qtd button:disabled { color: #A9A5C2; cursor: not-allowed; }
.qtd button:focus-visible { outline-offset: -3px; }
.qtd output, .qtd span { min-width: 34px; font-size: 19px; font-weight: 900; text-align: center; }

/* ---------- Sacola ------------------------------------------------------ */

.gaveta {
  width: min(500px, 100vw);
  height: 100vh;
  height: 100dvh;
  margin: 0 0 0 auto;
}
.gaveta[open] { display: flex; flex-direction: column; }

.gaveta-barra {
  flex: none;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  padding: 12px 20px;
  background: var(--branco);
  border-bottom: 1px solid var(--linha-cinza);
}
.gaveta-barra h2 {
  color: var(--laranja-botao);
  font-family: var(--serif);
  font-size: 34px;
  font-weight: 400;
  line-height: 1.1;
}
.gaveta-barra h2:focus { outline: none; }

.gaveta-corpo {
  flex: 1;
  min-height: 0;
  display: flex;
  flex-direction: column;
  gap: 16px;
  padding: 16px 20px 28px;
  overflow-y: auto;
  overscroll-behavior: contain;
  background-size: 32px 32px;
}
.sacola-vazia { padding-block: 28px 4px; font-size: 19px; font-weight: 700; text-align: center; }
.sacola-vazia[hidden] { display: none; }

.itens { display: grid; gap: 12px; }
.itens:empty { display: none; }
.item {
  display: grid;
  grid-template-columns: 76px minmax(0, 1fr);
  gap: 12px;
  padding: 10px;
  background: var(--branco);
  border: 1px solid var(--linha-cinza);
  border-radius: 12px;
}
.item-foto {
  height: 102px;
  border-bottom: 3px solid var(--laranja);
  align-self: start;
}
.item-foto img {
  width: 100%;
  height: 100%;
  object-fit: contain;
  object-position: center bottom;
}
.item-nome {
  color: var(--laranja-botao);
  font-family: var(--serif);
  font-size: 23px;
  font-weight: 400;
  line-height: 1.12;
}
.item-info { font-size: 16px; font-weight: 600; line-height: 1.3; margin-top: 2px; }
.item-acoes {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  justify-content: space-between;
  gap: 6px 10px;
  margin-top: 8px;
}
.item-acoes .qtd button { width: 42px; height: 40px; font-size: 22px; }
.item-subtotal { font-size: 19px; font-weight: 900; color: var(--laranja-botao-escuro); white-space: nowrap; }
.item .botao-texto { justify-self: start; }

.sacola-total {
  display: flex;
  align-items: baseline;
  justify-content: space-between;
  gap: 12px;
  padding: 12px 14px;
  background: var(--branco);
  border-left: 7px solid var(--laranja);
  border-radius: 10px;
  font-weight: 800;
}
.sacola-total strong { color: var(--laranja-botao); font-size: 30px; font-weight: 900; line-height: 1.1; white-space: nowrap; }
.aviso-frete { margin-top: 8px; font-weight: 800; text-align: right; }

.pedido, .pedido-pronto {
  display: grid;
  gap: 14px;
  padding: 16px;
  background: var(--branco);
  border: 1px solid var(--linha-cinza);
  border-radius: 12px;
}
.pedido[hidden], .pedido-pronto[hidden] { display: none; }
.pedido-pronto:focus { outline: none; }
.pedido h3, .pedido-pronto h3 {
  color: var(--laranja-botao);
  font-family: var(--serif);
  font-size: 27px;
  font-weight: 400;
  line-height: 1.12;
}
.campo label { display: block; margin-bottom: 4px; font-weight: 800; }
.obrigatorio { font-weight: 600; }
.campo input, .campo textarea, #pronto-mensagem {
  display: block;
  width: 100%;
  min-height: 48px;
  padding: 10px 12px;
  border: 2px solid #8C86B3;
  border-radius: 10px;
  background: var(--branco);
  font-size: 17px;
  line-height: 1.4;
}
.campo textarea, #pronto-mensagem { resize: vertical; }
.campo input[aria-invalid="true"] { border-color: var(--framboesa); box-shadow: inset 0 0 0 1px var(--framboesa); }
.campo input::placeholder { color: #6A6490; }
.campo input:focus-visible, .campo textarea:focus-visible, #pronto-mensagem:focus-visible { outline: 3px solid var(--azul); outline-offset: 1px; border-radius: 10px; }
#pronto-mensagem { font-size: 16px; background: #FFFBF3; }
.pronto-instrucao { font-size: 19px; font-weight: 800; }
.pronto-status { min-height: 24px; color: var(--verde); font-weight: 800; }

/* ---------- Tablet ------------------------------------------------------ */

@media (max-width: 1099px) {
  .grade { grid-template-columns: repeat(3, minmax(0, 1fr)); }
  .cartao:last-child:nth-child(3n+1) { grid-column: 2; }
  .passos { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .passos li:nth-child(2) .passo-seta { display: none; }
  .abertura-dentro { grid-template-columns: minmax(0, 1fr); gap: 8px; }
  .abertura-texto { order: 1; align-self: start; padding-bottom: 0; text-align: center; }
  .abertura-chamada { font-size: clamp(36px, 6vw, 56px); }
  .abertura-onda { margin-inline: auto; }
  .abertura-apoio { margin-inline: auto; }
  .abertura-palco { order: 2; }
}

/* ---------- Celular ----------------------------------------------------- */

@media (max-width: 760px) {
  :root { --gutter: 16px; --passo-papel: 32px; --altura-topo: 112px; }
  body { font-size: 16px; }

  .topo-dentro { flex-wrap: wrap; min-height: 0; padding-block: 6px 0; justify-content: space-between; gap: 2px 12px; }
  .topo-nav { order: 3; width: 100%; margin: 0; justify-content: space-between; gap: 4px; }
  .topo-nav a { min-height: 44px; padding-inline: 2px; font-size: 16px; }

  .abertura-dentro { padding-top: 16px; }
  .abertura-palco { width: calc(100% + 32px); max-width: none; margin-inline: -16px; }
  .abertura-apoio { font-size: 18px; margin-bottom: 18px; }

  .faixa li { min-height: 60px; padding: 8px 5px; font-size: 16px; }

  .secao { padding-block: 52px; }
  .titulo-bloco { padding-inline: 44px; }
  .risco { width: 36px; height: 32px; margin-top: -16px; }
  .risco-esq { left: 0; }
  .risco-dir { right: 0; }

  .grade { grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 12px; margin-top: 28px; }
  .cartao:last-child:nth-child(3n+1) { grid-column: auto; }
  .cartao-topo { padding: 10px 10px 6px; }
  .cartao-nome { font-size: 24px; }
  .cartao-base { padding: 8px 10px 10px; }
  .selo { font-size: 14px; padding-inline: 8px; }

  .preco-linha { padding: 18px 18px 18px 26px; }
  .preco-nome { font-size: 22px; }

  .passos { grid-template-columns: minmax(0, 1fr); gap: 28px; }
  .passos li { display: grid; grid-template-columns: 56px minmax(0, 1fr); column-gap: 14px; }
  .passos .numero { grid-row: 1 / span 2; }
  .passos h3 { margin-top: 0; font-size: 29px; }
  .passo-seta { display: none; }

  .duas-folhas { grid-template-columns: minmax(0, 1fr); gap: 44px; }
  .lista-rabisco { font-size: 22px; }

  /* Painel e sacola em tela cheia */
  .painel, .gaveta {
    width: 100vw;
    height: 100vh;
    height: 100dvh;
    margin: 0;
    border-radius: 0;
  }
  .painel-barra { padding: 8px 16px; }
  .painel-titulo h2 { font-size: 26px; }
  .painel-corpo { display: block; overflow-y: auto; overscroll-behavior: contain; scroll-padding-bottom: 170px; }
  .painel-fotos { height: clamp(280px, 46vh, 420px); border-right: 0; border-bottom: 1px solid var(--linha-cinza); }
  .painel-opcoes { overflow: visible; padding: 16px 16px 0; }
  .painel-fechamento { margin-inline: -16px; padding-inline: 16px; }
  .detalhe { top: 8px; right: 6px; width: 104px; }
  .detalhe img { width: 84px; height: 84px; }
}

@media (max-width: 359px) {
  .painel-barra .selo { display: none; }
  .botao-fechar { padding-inline: 12px; }
  .topo-dentro { gap: 2px 8px; }
  .topo-logo img { width: 120px; }
  .titulo { font-size: 34px; }
  .titulo-bloco { padding-inline: 34px; }
  .risco { width: 28px; height: 26px; margin-top: -13px; }
  .cartao-topo { padding-inline: 8px; }
  .cartao-marcas { gap: 4px; }
  .cartao-marcas .numero { width: 30px; height: 30px; font-size: 17px; }
  .cartao .selo { padding-inline: 6px; }
}

@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after {
    animation: none !important;
    transition: none !important;
    scroll-behavior: auto !important;
  }
}

/* ---------- Checkout online ---------- */
.checkout-online #pedido, .checkout-online .aviso-frete { display: none !important; }
.campo-linha { display: flex; gap: 8px; align-items: stretch; }
.campo-linha input { flex: 1; min-width: 0; }
.campo-linha .botao { flex: none; padding-inline: 20px; }
.frete-status { min-height: 24px; font-weight: 700; }
.fretes { margin: 8px 0 0; padding: 0; border: 0; min-width: 0; }
.fretes legend { padding: 0; margin-bottom: 8px; font-weight: 800; }
.frete-opcao { display: flex; align-items: center; gap: 10px; min-height: 56px; padding: 10px 12px; margin-bottom: 8px; background: var(--branco); border: 2px solid var(--linha-cinza); border-radius: 10px; cursor: pointer; }
.frete-opcao:has(input:checked) { border-color: var(--violeta); background: #FFF4E6; }
.frete-opcao input { width: 20px; height: 20px; flex: none; accent-color: var(--violeta); }
.frete-texto { flex: 1; min-width: 0; display: grid; }
.frete-nome { font-weight: 800; }
.frete-prazo { font-size: 15px; }
.frete-opcao strong { white-space: nowrap; }
#ck-dados h3 { margin-top: 22px; }
#checkout .campo { margin-top: 14px; }
#checkout h3 + .campo { margin-top: 8px; }
.ck-totais { margin: 22px 0 12px; }
.ck-totais div, .retorno-totais div { display: flex; justify-content: space-between; gap: 12px; padding: 4px 0; }
.ck-totais dd, .retorno-totais dd { margin: 0; font-weight: 800; white-space: nowrap; }
.ck-total, .retorno-total { margin-top: 6px; padding-top: 10px !important; border-top: 2px solid var(--linha-cinza); font-size: 20px; }
.ck-total dd, .retorno-total dd { color: var(--laranja-botao); font-size: 26px; font-weight: 900; }
.ck-politica { margin-bottom: 12px; }
.ck-politica summary { min-height: 32px; cursor: pointer; font-weight: 800; text-decoration: underline; }
.ck-politica p { margin-top: 6px; font-size: 16px; line-height: 1.5; }
.ck-aceite { display: flex; align-items: flex-start; gap: 10px; min-height: 48px; font-weight: 800; cursor: pointer; }
.ck-aceite input { width: 22px; height: 22px; margin: 2px 0 0; flex: none; accent-color: var(--violeta); }
.ck-aceite input[aria-invalid="true"] { outline: 2px solid var(--framboesa); }
.ck-nota { margin: 8px 0; font-size: 16px; }
#ck-erro { margin-bottom: 10px; }
#ck-pagar:disabled, #ck-calcular:disabled { opacity: .6; cursor: default; }

/* ---------- Retorno do pagamento ---------- */
.retorno { min-height: 100vh; padding: 32px 16px; }
.retorno-caixa { max-width: 620px; margin: 0 auto; padding: 28px 24px; background: var(--branco); border: 1px solid var(--linha-cinza); border-radius: 16px; }
.retorno-logo { width: 160px; height: auto; margin-bottom: 18px; }
.retorno h1 { color: var(--laranja-botao); font-family: var(--serif); font-size: 38px; font-weight: 400; line-height: 1.12; outline: none; }
.retorno h2 { margin-top: 24px; font-size: 20px; }
#mensagem { margin-top: 10px; font-size: 18px; line-height: 1.5; }
#lista { margin: 10px 0 0; padding-left: 20px; }
.retorno-totais { margin: 18px 0 0; }
#rastreio { margin-top: 14px; font-weight: 800; }
.retorno-acoes { display: flex; flex-wrap: wrap; align-items: center; gap: 16px; margin-top: 26px; }
