/* Catálogo JPA Sales — pensado primeiro para o celular.
   Cores pela regra 60-30-10:
   60% (--c60)  fundo da página e do topo com a foto
   30% (--c30)  barra superior (depois de rolar), faixa de destaques, rodapé
   10% (--c10)  detalhes: "JPA" gigante, botões, preços em promoção, sacola
   O tema vem de settings.theme (painel) em <html data-theme="...">. */

:root,
[data-theme="oliva"] {
  --c60: #EDEFE9; --c60-ink: #1B2018; --c60-muted: #4D5547;
  --c30: #2E3829; --c30-ink: #EEF0E8; --c30-muted: #B9C2AE;
  --c10: #C79B5B; --c10-ink: #1B2018; --c10-text: #8A6230; --c10-on30: #D9B16F;
  --surface: #FBFCF9; --tile: #DDE2D4; --line: #CDD3C4;
  --photo-shadow: rgba(46, 56, 41, .24);
  color-scheme: light;
}
[data-theme="preto"] {
  --c60: #0E0D0C; --c60-ink: #F3EEE5; --c60-muted: #ABA498;
  --c30: #24211D; --c30-ink: #F3EEE5; --c30-muted: #B5AD9F;
  --c10: #D2AE62; --c10-ink: #15120D; --c10-text: #DDBA70; --c10-on30: #DDBA70;
  --surface: #181715; --tile: #1E1C19; --line: #34302B;
  --photo-shadow: rgba(210, 174, 98, .22);
  color-scheme: dark;
}
[data-theme="branco"] {
  --c60: #FFFFFF; --c60-ink: #1C1A16; --c60-muted: #6A645A;
  --c30: #F1E8D6; --c30-ink: #1C1A16; --c30-muted: #6A645A;
  --c10: #C39847; --c10-ink: #1C1A16; --c10-text: #8A6420; --c10-on30: #7E5A1A;
  --surface: #FFFFFF; --tile: #F7F2E8; --line: #E7DFCF;
  --photo-shadow: rgba(140, 105, 40, .2);
  color-scheme: light;
}
[data-theme="rosa"] {
  --c60: #FFF6F7; --c60-ink: #3B1E28; --c60-muted: #7E5D67;
  --c30: #F2C4CE; --c30-ink: #3B1E28; --c30-muted: #6B4753;
  --c10: #A3305A; --c10-ink: #FFFFFF; --c10-text: #A3305A; --c10-on30: #8A2149;
  --surface: #FFFFFF; --tile: #FBE7EB; --line: #F0D4DA;
  --photo-shadow: rgba(163, 48, 90, .18);
  color-scheme: light;
}

:root {
  --whats: #1F7A4D;
  --serif: "Bodoni Moda", "Didot", Georgia, serif;
  --sans: "Figtree", system-ui, -apple-system, "Segoe UI", sans-serif;
  --gutter: clamp(16px, 4.5vw, 40px);
  --max: 1180px;
  --safe-top: env(safe-area-inset-top, 0px);
  --safe-bottom: env(safe-area-inset-bottom, 0px);
  --bar: calc(56px + var(--safe-top));
  --filters: 58px;
  --ease: cubic-bezier(.2, .8, .2, 1);
}

*, *::before, *::after { box-sizing: border-box; }
html { -webkit-text-size-adjust: 100%; scroll-padding-top: calc(var(--bar) + var(--filters) + 8px); }
@media (prefers-reduced-motion: reduce) { *, *::before, *::after { animation: none !important; transition: none !important; } }
body {
  margin: 0;
  background: var(--c60);
  color: var(--c60-ink);
  font: 400 16px/1.5 var(--sans);
  -webkit-font-smoothing: antialiased;
  -webkit-tap-highlight-color: transparent;
  transition: background-color .3s ease, color .3s ease;
}
img { display: block; max-width: 100%; }
button, input, textarea { font: inherit; color: inherit; }
button { cursor: pointer; touch-action: manipulation; }
a { color: inherit; }
:focus-visible { outline: 2px solid var(--c10); outline-offset: 3px; border-radius: 6px; }
[hidden] { display: none !important; }
svg { fill: none; stroke: currentColor; stroke-width: 1.8; stroke-linecap: round; stroke-linejoin: round; }

/* ---------- Barra superior: transparente sobre a foto, cor 30 depois de rolar ---------- */
.topbar {
  position: sticky; top: 0; z-index: 30;
  display: flex; align-items: center; justify-content: space-between; gap: 8px;
  height: var(--bar); padding: var(--safe-top) var(--gutter) 0;
  color: var(--c60-ink); background: transparent;
  transition: background-color .25s ease, color .25s ease, box-shadow .25s ease;
}
.topbar.is-solid { background: var(--c30); color: var(--c30-ink); box-shadow: 0 1px 0 rgba(0, 0, 0, .06); }
.brand {
  font: 500 1.2rem/1 var(--serif); text-decoration: none; letter-spacing: .01em;
  opacity: 0; transform: translateY(4px); transition: opacity .25s ease, transform .25s ease;
}
.topbar.is-solid .brand { opacity: 1; transform: none; }
.bag-btn {
  position: relative; display: inline-flex; align-items: center; gap: 8px;
  min-height: 42px; padding: 0 14px 0 12px; border-radius: 999px;
  border: 1px solid color-mix(in srgb, currentColor 28%, transparent); background: transparent;
  font-weight: 600; font-size: .95rem; color: inherit;
}
.bag-btn svg { width: 20px; height: 20px; }
.bag-count {
  min-width: 20px; height: 20px; padding: 0 6px; border-radius: 999px;
  background: var(--c10); color: var(--c10-ink); font-size: .75rem; line-height: 20px; text-align: center;
}
.bag-btn.bump { animation: pop .4s var(--ease); }
@keyframes pop { 40% { transform: scale(1.12); } }

/* ---------- Hero (60): "JPA" gigante (10) atrás da dona ---------- */
.hero {
  position: relative; max-width: var(--max); margin: calc(var(--bar) * -1) auto 0;
  padding: calc(var(--bar) + 4px) var(--gutter) 0;
  display: grid; grid-template-columns: 1fr; overflow: hidden;
}
.hero-mark {
  position: absolute; z-index: 0; left: 50%;
  top: calc(var(--bar) + clamp(96px, 27vw, 140px));
  transform: translateX(-50%);
  font: 700 clamp(8rem, 46vw, 22rem)/.8 var(--serif);
  font-variation-settings: "opsz" 11; letter-spacing: -.04em;
  color: var(--c10); white-space: nowrap; user-select: none;
  animation: mark-in 1.1s var(--ease) both;
  transition: color .3s ease;
}
@keyframes mark-in { from { opacity: 0; letter-spacing: .08em; } to { opacity: 1; letter-spacing: -.04em; } }
.hero-text { position: relative; z-index: 2; text-align: center; }
.hero h1 { margin: 0; font: 500 clamp(2.3rem, 10vw, 3.4rem)/1 var(--serif); letter-spacing: -.01em; }
.hero-cats { margin: 8px 0 0; font-size: 1rem; font-weight: 600; color: var(--c60-muted); }
.hero-text .hero-tagline, .hero-text .hero-actions { display: none; }
.hero-photo { position: relative; z-index: 1; margin: 56px auto 0; width: min(84%, 420px); }
.hero-photo img { width: 100%; height: auto; filter: drop-shadow(0 18px 34px var(--photo-shadow)); }
.hero-photo figcaption {
  position: absolute; left: 50%; bottom: 16px; transform: translateX(-50%);
  padding: 6px 16px; border-radius: 999px; background: var(--surface); color: var(--c60-ink);
  font: 500 1rem/1.3 var(--serif); font-style: italic; white-space: nowrap;
  box-shadow: 0 8px 20px rgba(0, 0, 0, .18);
}
.hero-after { max-width: var(--max); margin: 0 auto; padding: 20px var(--gutter) 24px; text-align: center; }
.hero-after p { margin: 0 auto 18px; max-width: 32ch; color: var(--c60-muted); font-size: 1.02rem; }
.hero-actions { display: grid; grid-template-columns: 1fr 1fr; gap: 10px; max-width: 420px; margin: 0 auto; }
.hero-actions .btn:only-child { grid-column: 1 / -1; }

.btn {
  display: inline-flex; align-items: center; justify-content: center; gap: 8px;
  min-height: 50px; padding: 0 22px; border-radius: 999px; border: 1px solid transparent;
  font-weight: 600; font-size: 1rem; text-decoration: none; white-space: nowrap;
  transition: transform .12s ease, filter .15s ease, background-color .15s ease;
}
.btn:active { transform: scale(.97); }
.btn svg { width: 20px; height: 20px; }
.btn-accent { background: var(--c10); color: var(--c10-ink); }
.btn-ghost { border-color: currentColor; color: var(--c60-ink); background: transparent; }
.btn-whats { background: var(--whats); color: #fff; width: 100%; }
.btn-whats svg { fill: currentColor; stroke: none; }
.btn[disabled] { opacity: .5; pointer-events: none; }
@media (hover: hover) {
  .btn-accent:hover { filter: brightness(1.06); }
  .btn-ghost:hover { background: color-mix(in srgb, var(--c60-ink) 8%, transparent); }
  .btn-whats:hover { background: #18663f; }
}

@media (min-width: 860px) {
  .hero { grid-template-columns: 1fr 1.05fr; align-items: end; min-height: min(680px, 100vh); padding-top: var(--bar); }
  .hero-mark { left: auto; right: var(--gutter); transform: none; top: 16%; font-size: clamp(13rem, 24vw, 20rem); }
  .hero-text { text-align: left; align-self: center; padding: 0 0 40px; }
  .hero h1 { font-size: clamp(3.2rem, 5.6vw, 4.8rem); }
  .hero-cats { font-size: 1.2rem; }
  .hero-text .hero-tagline { display: block; margin: 18px 0 26px; max-width: 38ch; font-size: 1.08rem; color: var(--c60-muted); }
  .hero-text .hero-actions { display: flex; margin: 0; }
  .hero-photo { margin: 0 0 0 auto; width: min(100%, 520px); }
  .hero-after { display: none; }
}

/* ---------- Busca + categorias: uma linha fixa ---------- */
main { max-width: var(--max); margin: 0 auto; padding: 0 var(--gutter) 40px; }
.filters {
  position: sticky; top: var(--bar); z-index: 20;
  margin: 0 calc(var(--gutter) * -1); padding: 0 var(--gutter);
  background: var(--c60); border-bottom: 1px solid var(--line);
  transition: background-color .3s ease;
}
.filters-row { display: flex; align-items: center; gap: 8px; height: var(--filters); }
.search-toggle {
  flex: none; width: 42px; height: 42px; border-radius: 50%;
  display: grid; place-items: center; border: 1px solid var(--line); background: var(--surface);
}
.search-toggle svg { width: 20px; height: 20px; }
.chips {
  flex: 1; min-width: 0; display: flex; gap: 8px; overflow-x: auto; scrollbar-width: none;
  margin-right: calc(var(--gutter) * -1); padding-right: var(--gutter);
  scroll-behavior: smooth; -webkit-overflow-scrolling: touch;
  mask-image: linear-gradient(90deg, #000 85%, transparent);
}
.chips::-webkit-scrollbar { display: none; }
.chip {
  flex: none; min-height: 40px; padding: 0 16px; border-radius: 999px;
  border: 1px solid var(--line); background: var(--surface); font-weight: 600; font-size: .94rem;
  transition: background-color .2s ease, color .2s ease, border-color .2s ease;
}
.chip[aria-current="true"] { background: var(--c10); border-color: var(--c10); color: var(--c10-ink); }
.search { position: relative; flex: 1; display: block; }
.search svg { position: absolute; left: 14px; top: 50%; width: 20px; height: 20px; transform: translateY(-50%); color: var(--c60-muted); }
.search input {
  width: 100%; height: 44px; padding: 0 14px 0 42px; font-size: 16px; /* 16px evita o zoom do iPhone */
  border: 1px solid var(--line); border-radius: 999px; background: var(--surface);
  -webkit-appearance: none; appearance: none;
}
.search input::placeholder { color: var(--c60-muted); }
.search input:focus { outline: none; border-color: var(--c10); box-shadow: 0 0 0 3px color-mix(in srgb, var(--c10) 25%, transparent); }
.search-cancel { flex: none; border: 0; background: none; padding: 10px 2px; font-weight: 600; color: var(--c10-text); }

/* ---------- Faixa de destaques (30, de ponta a ponta) ---------- */
.featured {
  --c60-ink: var(--c30-ink); --c60-muted: var(--c30-muted); --c10-text: var(--c10-on30);
  margin-top: 22px; padding: 2px 0 30px;
  background: var(--c30); color: var(--c30-ink);
  box-shadow: 0 0 0 100vmax var(--c30); clip-path: inset(0 -100vmax);
}
.rail { padding-top: 24px; }
.rail + .rail { border-top: 1px solid color-mix(in srgb, var(--c30-ink) 12%, transparent); margin-top: 26px; }
.rail h2, .cat-section h2, .brands h2 { margin: 0 0 14px; font: 500 clamp(1.7rem, 7vw, 2.2rem)/1.1 var(--serif); }
.cat-section { padding-top: 30px; }
.cat-section h2 small, .rail h2 small { font: 500 .9rem var(--sans); color: var(--c60-muted); margin-left: 8px; }
.featured-row {
  display: grid; grid-auto-flow: column; grid-auto-columns: 46%;
  gap: 12px; overflow-x: auto; scroll-snap-type: x mandatory; scrollbar-width: none;
  scroll-padding-inline: var(--gutter); overscroll-behavior-x: contain;
  margin: 0 calc(var(--gutter) * -1); padding: 0 var(--gutter) 4px;
}
.featured-row::-webkit-scrollbar { display: none; }
.featured-row .card { scroll-snap-align: start; }
@media (min-width: 640px) { .featured-row { grid-auto-columns: 30%; } }
@media (min-width: 860px) { .featured-row { grid-auto-columns: calc((100% - 36px) / 4); margin: 0; padding: 0; } }

/* ---------- Cards ---------- */
.grid { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 22px 12px; }
@media (min-width: 640px) { .grid { grid-template-columns: repeat(3, minmax(0, 1fr)); } }
@media (min-width: 1000px) { .grid { grid-template-columns: repeat(4, minmax(0, 1fr)); gap: 30px 22px; } }

.card { position: relative; container-type: inline-size; }
.card-open { display: block; width: 100%; padding: 0; border: 0; background: none; text-align: left; color: inherit; }
.card-media {
  position: relative; aspect-ratio: 4 / 5; width: 100%;
  border-radius: 16px 16px 120px 120px / 16px 16px 56px 56px;
  background: var(--tile); overflow: hidden;
  transition: transform .15s ease;
}
.card-open:active .card-media { transform: scale(.975); }
.card-media img { width: 100%; height: 100%; object-fit: cover; transition: transform .35s ease, opacity .3s ease; }
@media (hover: hover) { .card-open:hover .card-media img { transform: scale(1.03); } }
.no-photo { width: 100%; height: 100%; display: grid; place-items: center; font: 500 3.2rem/1 var(--serif); color: var(--c60-muted); opacity: .6; }
.tag {
  position: absolute; left: 8px; top: 8px; max-width: calc(100% - 16px);
  padding: 4px 10px; border-radius: 999px; font-size: .74rem; font-weight: 700; line-height: 1.3;
  background: var(--c10); color: var(--c10-ink);
}
.card.is-soldout .card-media img, .card.is-soldout .no-photo { filter: grayscale(.9); opacity: .55; }
.card.is-soldout .tag { background: var(--c60-ink); color: var(--c60); }
.card-body { padding: 10px 2px 0; }
.card-brand { margin: 0; font-size: .8rem; color: var(--c60-muted); white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.card-name {
  margin: 2px 0 0; font-weight: 600; font-size: .96rem; line-height: 1.3;
  display: -webkit-box; -webkit-line-clamp: 2; -webkit-box-orient: vertical; overflow: hidden;
}
.card-size { color: var(--c60-muted); font-weight: 400; }

/* Botão "+" do card: põe 1 na sacola sem abrir o produto */
.card-add {
  position: absolute; right: 8px; top: calc(125cqw - 52px);
  width: 44px; height: 44px; border-radius: 50%; border: 0;
  display: grid; place-items: center;
  background: var(--c10); color: var(--c10-ink);
  box-shadow: 0 6px 16px rgba(0, 0, 0, .25);
  transition: transform .12s ease;
}
.card-add:active { transform: scale(.9); }
.card-add svg { width: 22px; height: 22px; stroke-width: 2.2; }
.card-add .ok { display: none; }
.card-add.done .plus { display: none; }
.card-add.done .ok { display: block; }
.card-add.done { animation: pop .4s var(--ease); }

.price { margin: 6px 0 0; font-weight: 700; font-size: 1.04rem; }
.price s { font-weight: 400; color: var(--c60-muted); font-size: .85em; margin-right: 6px; }
.price .promo { color: var(--c10-text); }

.empty { padding: 56px 0; text-align: center; color: var(--c60-muted); max-width: 34ch; margin: 0 auto; }

/* ---------- Compre por marca ---------- */
.brands { padding-top: 38px; }
.brand-grid { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 10px; }
@media (min-width: 640px) { .brand-grid { grid-template-columns: repeat(4, minmax(0, 1fr)); } }
.brand-btn {
  display: grid; gap: 2px; padding: 14px 16px; min-height: 64px; text-align: left;
  border: 1px solid var(--line); border-radius: 16px; background: var(--surface);
  transition: transform .12s ease, border-color .15s ease;
}
.brand-btn:active { transform: scale(.97); border-color: var(--c10); }
.brand-btn span { font: 500 1.08rem/1.2 var(--serif); overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.brand-btn small { font-size: .8rem; color: var(--c60-muted); }
.brand-filter {
  display: flex; align-items: center; justify-content: space-between; gap: 12px;
  margin-top: 16px; padding: 10px 10px 10px 16px; border-radius: 16px; background: var(--tile);
}
.brand-filter p { margin: 0; font-size: .95rem; }
.brand-filter span { color: var(--c60-muted); }
.btn-sm { min-height: 38px; padding: 0 14px; font-size: .88rem; }

/* ---------- Apresentação da consultora ---------- */
.about { padding: 54px var(--gutter) 60px; }
.about-inner { max-width: 920px; margin: 0 auto; display: grid; gap: 26px; justify-items: center; text-align: center; }
.about-photo {
  width: min(70%, 260px); aspect-ratio: 4 / 5; overflow: hidden;
  border-radius: 999px 999px 24px 24px; background: var(--c30);
  display: flex; align-items: flex-end; justify-content: center;
}
.about-photo img { width: 112%; max-width: none; height: auto; margin-bottom: -2px; }
.about-role { margin: 0; font-weight: 700; font-size: .95rem; color: var(--c10-text); }
.about-text h2 { margin: 4px 0 12px; font: 500 clamp(2rem, 9vw, 2.8rem)/1.05 var(--serif); }
.about-bio { margin: 0 auto; max-width: 36ch; color: var(--c60-muted); font-size: 1.04rem; line-height: 1.6; }
.about-points { list-style: none; margin: 20px auto 24px; padding: 0; display: grid; gap: 10px; max-width: 34ch; text-align: left; }
.about-points li { display: flex; gap: 10px; align-items: baseline; }
.about-points li::before { content: ""; flex: none; width: 8px; height: 8px; border-radius: 50%; background: var(--c10); transform: translateY(-2px); }
.about-actions { display: grid; grid-template-columns: 1fr 1fr; gap: 10px; max-width: 420px; margin: 0 auto; }
.about-actions .btn:only-child { grid-column: 1 / -1; }
@media (min-width: 760px) {
  .about-inner { grid-template-columns: 300px 1fr; text-align: left; align-items: center; }
  .about-photo { width: 100%; }
  .about-bio, .about-points { margin-left: 0; }
  .about-actions { margin: 0; }
}
.hero-about-link { display: inline-block; margin-top: 16px; padding: 6px 4px; font-weight: 600; color: var(--c10-text); text-underline-offset: 5px; }

/* Pedir só este produto */
.pd-whats {
  display: inline-flex; align-items: center; gap: 8px; margin: 8px 0 6px; padding: 8px 0;
  font-weight: 600; color: var(--c60-ink); text-underline-offset: 4px;
}
.pd-whats svg { width: 20px; height: 20px; fill: var(--whats); stroke: none; }

/* ---------- Rodapé (30) ---------- */
.footer {
  background: var(--c30); color: var(--c30-muted);
  padding: 44px var(--gutter) calc(110px + var(--safe-bottom)); text-align: center;
}
.footer p { margin: 0 auto 6px; max-width: 40ch; }
.footer-name { font: 500 2rem/1.1 var(--serif); color: var(--c30-ink); margin-bottom: 12px !important; }
.footer-cta { margin: 18px auto 6px; width: min(100%, 340px); }
.footer-links { display: flex; justify-content: center; gap: 18px; margin-top: 14px !important; }
.footer-links a { font-weight: 600; color: var(--c30-ink); text-underline-offset: 4px; }

/* ---------- Sacola flutuante (10) ---------- */
.bag-float {
  position: fixed; z-index: 25;
  left: 50%; bottom: calc(14px + var(--safe-bottom)); transform: translateX(-50%);
  display: flex; align-items: center; gap: 12px;
  width: min(calc(100% - 28px), 440px); min-height: 60px; padding: 0 20px 0 10px;
  border: 0; border-radius: 999px; background: var(--c10); color: var(--c10-ink);
  font-weight: 600; font-size: 1rem;
  box-shadow: 0 14px 34px rgba(0, 0, 0, .32);
  animation: float-in .35s var(--ease);
}
.bag-float-icon {
  position: relative; width: 42px; height: 42px; border-radius: 50%;
  display: grid; place-items: center; background: color-mix(in srgb, var(--c10-ink) 14%, transparent);
}
.bag-float-icon svg { width: 22px; height: 22px; }
.bag-float-icon b {
  position: absolute; top: -3px; right: -3px; min-width: 20px; height: 20px; padding: 0 5px;
  border-radius: 999px; background: var(--c10-ink); color: var(--c10); font-size: .72rem; line-height: 20px; text-align: center;
}
.bag-float-text { flex: 1; text-align: left; }
@keyframes float-in { from { transform: translate(-50%, 24px); opacity: 0; } }
.bag-float.bump { animation: bump .4s ease; }
@keyframes bump { 45% { transform: translate(-50%, -5px) scale(1.03); } }
body.sheet-open .bag-float { display: none; }

/* ---------- Janelas de baixo para cima ---------- */
.sheet {
  width: 100%; max-width: 560px; max-height: 92vh; max-height: 92dvh;
  margin: auto auto 0; padding: 0; border: 0;
  border-radius: 24px 24px 0 0; background: var(--surface); color: var(--c60-ink);
  overflow-y: auto; overscroll-behavior: contain;
}
.sheet::backdrop { background: rgba(0, 0, 0, .55); backdrop-filter: blur(2px); }
.sheet[open] { animation: sheet-up .32s var(--ease); }
.sheet.dragging { transition: none; }
.sheet.snap { transition: transform .22s var(--ease); }
@keyframes sheet-up { from { transform: translateY(60px); opacity: 0; } }
@media (min-width: 700px) { .sheet { margin: auto; border-radius: 24px; } }

.sheet-grip { position: sticky; top: 0; z-index: 3; height: 0; display: flex; justify-content: center; touch-action: none; }
.sheet-grip span { display: block; width: 40px; height: 5px; margin-top: 8px; border-radius: 999px; background: color-mix(in srgb, var(--c60-ink) 30%, transparent); }
.product-sheet .sheet-grip span { background: rgba(255, 255, 255, .85); box-shadow: 0 1px 4px rgba(0, 0, 0, .3); }

.icon-btn { width: 40px; height: 40px; border-radius: 50%; border: 0; background: var(--tile); color: var(--c60-ink); font-size: 1.5rem; line-height: 1; }
.sheet-close-row { position: sticky; top: 0; z-index: 2; height: 0; display: flex; justify-content: flex-end; }
.sheet-close-row .icon-btn { margin: 14px 14px 0 0; background: color-mix(in srgb, var(--surface) 88%, transparent); backdrop-filter: blur(6px); }

.pd-media { aspect-ratio: 4 / 5; max-height: 54vh; max-height: 54dvh; width: 100%; background: var(--tile); }
.pd-media img { width: 100%; height: 100%; object-fit: cover; }
.pd-media .no-photo { font-size: 5rem; }
.pd-body { padding: 18px 22px 8px; }
.pd-title-row { display: flex; align-items: flex-start; justify-content: space-between; gap: 12px; }
.pd-brand { margin: 0; color: var(--c60-muted); font-size: .9rem; }
.pd-body h2 { margin: 2px 0 0; font: 500 1.7rem/1.15 var(--serif); }
.pd-size { margin: 4px 0 0; color: var(--c60-muted); }
.pd-size:empty, .pd-brand:empty, .pd-desc:empty { display: none; }
.share-btn { flex: none; width: 44px; height: 44px; border-radius: 50%; border: 1px solid var(--line); background: none; display: grid; place-items: center; color: var(--c60-ink); }
.share-btn svg { width: 20px; height: 20px; }
.pd-price { font-size: 1.35rem; margin-top: 12px; }
.left-note { margin-left: 8px; font-size: .8rem; font-weight: 700; color: var(--c10-text); }
.pd-desc { margin: 12px 0 8px; color: var(--c60-muted); white-space: pre-line; }
.soldout-msg { margin: 0; padding: 12px 14px; border-radius: 12px; background: var(--tile); color: var(--c60-muted); }

/* Rodapé fixo das janelas: o botão principal fica sempre à mão */
.sheet-foot {
  position: sticky; bottom: 0; z-index: 2;
  padding: 12px 18px calc(12px + var(--safe-bottom));
  background: var(--surface); border-top: 1px solid var(--line);
}
.pd-buy { display: flex; gap: 10px; }
.pd-buy .btn { flex: 1; min-width: 0; padding: 0 12px; font-size: .98rem; overflow: hidden; text-overflow: ellipsis; }
.sheet:focus { outline: none; }
.sheet { overflow-x: hidden; }

.stepper { display: inline-flex; align-items: center; border: 1px solid var(--line); border-radius: 999px; flex: none; }
.stepper button { width: 44px; height: 48px; border: 0; background: none; font-size: 1.35rem; }
.stepper button[disabled] { opacity: .3; pointer-events: none; }
.stepper output { min-width: 24px; text-align: center; font-weight: 700; }
.stepper.small button { width: 38px; height: 38px; font-size: 1.15rem; }

.bag-head { display: flex; align-items: center; justify-content: space-between; padding: 22px 16px 10px 22px; }
.bag-head h2 { margin: 0; font: 500 1.7rem/1 var(--serif); }
.bag-list { list-style: none; margin: 0; padding: 0 22px; }
.bag-item { display: grid; grid-template-columns: 62px minmax(0, 1fr) auto; gap: 12px; align-items: center; padding: 12px 0; border-bottom: 1px solid var(--line); }
.bag-item .thumb { width: 62px; height: 62px; border-radius: 12px; overflow: hidden; background: var(--tile); }
.bag-item .thumb img { width: 100%; height: 100%; object-fit: cover; }
.bag-item .thumb .no-photo { font-size: 1.4rem; }
.bag-item p { margin: 0; }
.bag-item .name { font-weight: 600; line-height: 1.25; display: -webkit-box; -webkit-line-clamp: 2; -webkit-box-orient: vertical; overflow: hidden; }
.bag-item .sub { font-size: .88rem; color: var(--c60-muted); }
.bag-empty { padding: 30px 22px 40px; color: var(--c60-muted); text-align: center; }
.bag-empty p { margin: 0 0 16px; }
.bag-form { padding: 16px 22px 18px; display: grid; gap: 14px; }
.bag-form label { display: block; font-weight: 600; font-size: .95rem; }
.bag-form label > input, .bag-form label > textarea { display: block; margin-top: 6px; }
.bag-form .opt { font-weight: 400; color: var(--c60-muted); }
.bag-form input, .bag-form textarea {
  width: 100%; padding: 12px 14px; font-size: 16px; border: 1px solid var(--line); border-radius: 14px;
  background: var(--c60); font-weight: 400; resize: none;
}
.bag-form input:focus, .bag-form textarea:focus { outline: none; border-color: var(--c10); box-shadow: 0 0 0 3px color-mix(in srgb, var(--c10) 25%, transparent); }
.bag-foot { display: grid; gap: 10px; }
.bag-total { display: flex; justify-content: space-between; align-items: baseline; font-size: 1rem; }
.bag-total strong { font-size: 1.4rem; }
.bag-note { margin: 0; font-size: .84rem; color: var(--c60-muted); text-align: center; }
.bag-note:empty { display: none; }

.toast {
  position: fixed; z-index: 60; left: 50%; bottom: calc(88px + var(--safe-bottom)); transform: translate(-50%, 24px);
  padding: 11px 18px; border-radius: 999px; background: var(--c60-ink); color: var(--c60);
  font-weight: 600; font-size: .92rem; opacity: 0; transition: opacity .2s ease, transform .25s var(--ease);
  pointer-events: none; max-width: calc(100% - 32px); text-align: center;
}
.toast.show { opacity: 1; transform: translate(-50%, 0); }

/* ---------- Seletor de cores da demonstração (js/demo.js) ---------- */
.demo-themes { position: relative; margin: 0 6px 0 auto; }
.demo-themes .demo-panel { position: absolute; right: 0; top: calc(100% + 8px); z-index: 40; }
.demo-toggle {
  min-height: 38px; padding: 0 14px; border: 0; border-radius: 999px;
  background: var(--c10); color: var(--c10-ink); font-weight: 600; font-size: .88rem;
}
.demo-panel {
  display: grid; gap: 6px; padding: 10px; border-radius: 18px; width: 220px;
  background: var(--surface); color: var(--c60-ink); border: 1px solid var(--line);
  box-shadow: 0 16px 40px rgba(0, 0, 0, .25);
}
.demo-panel p { margin: 2px 4px 4px; font-size: .82rem; color: var(--c60-muted); }
.demo-opt {
  display: grid; grid-template-columns: 54px 1fr; gap: 10px; align-items: center;
  padding: 8px 6px; border: 1px solid transparent; border-radius: 12px; background: none; text-align: left; font-weight: 600; font-size: .92rem;
}
.demo-opt[aria-pressed="true"] { border-color: var(--c10); }
.swatch { display: flex; height: 28px; border-radius: 8px; overflow: hidden; box-shadow: inset 0 0 0 1px rgba(0, 0, 0, .12); }
.swatch i { display: block; height: 100%; }
.swatch i:nth-child(1) { flex: 6; } .swatch i:nth-child(2) { flex: 3; } .swatch i:nth-child(3) { flex: 1; }
html:not([data-demo]) .demo-themes { display: none; }

/* Celulares bem estreitos (360px ou menos) */
@media (max-width: 370px) {
  .bag-label { display: none; }
  .bag-btn { padding: 0 12px; }
  .chip { padding: 0 13px; font-size: .9rem; }
  .pd-buy .btn { font-size: .92rem; }
  .card-name { font-size: .92rem; }
}
