/* =========================================================
   Grudou: design system "sticker"
   Roxo + amarelo, borda branca de vinil recortado, sombra sólida
   deslocada, leve rotação e canto descolando.
   ========================================================= */

:root {
  --roxo: #6C2DFF;
  --roxo-escuro: #4A12C9;
  --roxo-claro: #9B6BFF;
  --roxo-bg: #F3EDFF;
  --amarelo: #FFC632;
  --amarelo-escuro: #E0A400;
  --amarelo-claro: #FFE08A;
  --vinil: #FFFFFF;
  --tinta: #1A0B3D;
  --tinta-suave: #5B4E7A;
  --verde: #18B979;
  --chart-bar: #6C2DFF;
  --vermelho: #F0445B;

  --bg: #FBF8FF;
  --surface: #FFFFFF;
  --surface-2: #F3EDFF;
  --text: var(--tinta);
  --text-muted: var(--tinta-suave);
  --line: #E4DAFB;

  --sticker-border: 6px;
  --sticker-shadow: 6px 6px 0 var(--tinta);
  --sticker-shadow-sm: 3px 3px 0 var(--tinta);
  --radius: 22px;
  --radius-sm: 14px;
  --font-display: "Lilita One", "Baloo 2", system-ui, sans-serif;
  --font-body: "Nunito", system-ui, -apple-system, "Segoe UI", sans-serif;
}

@media (prefers-color-scheme: dark) {
  :root:not([data-theme="light"]) {
    --bg: #120826;
    --surface: #1E1140;
    --surface-2: #2A1858;
    --text: #F5F0FF;
    --text-muted: #BFB2E3;
    --line: #3A2775;
    --roxo-bg: #2A1858;
    --chart-bar: #9B6BFF;
    --sticker-shadow: 6px 6px 0 #000;
    --sticker-shadow-sm: 3px 3px 0 #000;
  }
}
:root[data-theme="dark"] {
  --bg: #120826;
  --surface: #1E1140;
  --surface-2: #2A1858;
  --text: #F5F0FF;
  --text-muted: #BFB2E3;
  --line: #3A2775;
  --roxo-bg: #2A1858;
  --chart-bar: #9B6BFF;
  --sticker-shadow: 6px 6px 0 #000;
  --sticker-shadow-sm: 3px 3px 0 #000;
}

*, *::before, *::after { box-sizing: border-box; }
html { -webkit-text-size-adjust: 100%; }
body {
  margin: 0;
  font-family: var(--font-body);
  font-size: 16px;
  line-height: 1.5;
  color: var(--text);
  background: var(--bg);
  background-image: radial-gradient(circle at 1px 1px, color-mix(in srgb, var(--roxo) 12%, transparent) 1px, transparent 0);
  background-size: 22px 22px;
  min-height: 100vh;
  overflow-x: clip;
}
html { overflow-x: clip; }
img { max-width: 100%; display: block; }
a { color: var(--roxo); font-weight: 700; }
h1, h2, h3, .display { font-family: var(--font-display); font-weight: 400; letter-spacing: .3px; line-height: 1.1; margin: 0 0 .4em; }
h1 { font-size: clamp(2rem, 6vw, 3.4rem); }
h2 { font-size: clamp(1.5rem, 4vw, 2.2rem); }
h3 { font-size: 1.25rem; }
p { margin: 0 0 1em; }
small, .muted { color: var(--text-muted); }
.container { width: 100%; max-width: 1120px; margin: 0 auto; padding: 0 16px; }
.narrow { max-width: 560px; }
.stack > * + * { margin-top: 1rem; }
.row { display: flex; gap: 12px; flex-wrap: wrap; align-items: center; }
.between { justify-content: space-between; }
.grid { display: grid; gap: 20px; align-items: start; }
.grid-2 { grid-template-columns: repeat(auto-fit, minmax(260px, 1fr)); }
.grid-3 { grid-template-columns: repeat(auto-fit, minmax(220px, 1fr)); }
.grid-4 { grid-template-columns: repeat(auto-fit, minmax(160px, 1fr)); }
.center { text-align: center; }
.mt-0 { margin-top: 0; } .mt-1 { margin-top: .5rem; } .mt-2 { margin-top: 1rem; } .mt-3 { margin-top: 2rem; } .mt-4 { margin-top: 3rem; }
.hidden { display: none !important; }
.sr-only { position: absolute; width: 1px; height: 1px; overflow: hidden; clip: rect(0 0 0 0); white-space: nowrap; }

/* ---------- Logo ---------- */
.logo {
  font-family: var(--font-display);
  font-size: 1.9rem;
  color: var(--roxo);
  text-decoration: none;
  -webkit-text-stroke: 0;
  text-shadow:
    -3px -3px 0 var(--vinil), 3px -3px 0 var(--vinil), -3px 3px 0 var(--vinil), 3px 3px 0 var(--vinil),
    0 -3px 0 var(--vinil), 0 3px 0 var(--vinil), -3px 0 0 var(--vinil), 3px 0 0 var(--vinil),
    5px 6px 0 var(--amarelo);
  display: inline-block;
  transform: rotate(-3deg);
  line-height: 1;
  padding: 4px 6px;
}
.logo .dot { color: var(--amarelo); }

/* ---------- Sticker base ---------- */
.sticker {
  --tilt: 0deg;
  position: relative;
  background: var(--surface);
  border: var(--sticker-border) solid var(--vinil);
  border-radius: var(--radius);
  box-shadow: 0 0 0 2px var(--line), var(--sticker-shadow);
  padding: 20px;
  transform: rotate(var(--tilt));
  transition: transform .2s cubic-bezier(.34, 1.56, .64, 1), box-shadow .2s;
}
.sticker::before { /* brilho do vinil */
  content: "";
  position: absolute; inset: 0;
  border-radius: calc(var(--radius) - 6px);
  background: linear-gradient(125deg, rgba(255,255,255,.35) 0%, rgba(255,255,255,0) 35%, rgba(255,255,255,0) 70%, rgba(255,255,255,.18) 100%);
  pointer-events: none;
}
.sticker.peel::after { /* canto descolando */
  content: "";
  position: absolute; right: -6px; top: -6px;
  width: 34px; height: 34px;
  background: linear-gradient(225deg, var(--bg) 0 48%, #e9e2f7 50%, #ffffff 62%, #d9cff0 100%);
  border-top-right-radius: var(--radius);
  box-shadow: -2px 2px 4px rgba(26, 11, 61, .18);
}
.tilt-l { --tilt: -2deg; }
.tilt-r { --tilt: 2deg; }
.tilt-l2 { --tilt: -4deg; }
.tilt-r2 { --tilt: 4deg; }
a.sticker { display: block; }
a.sticker, .sticker.hoverable { cursor: pointer; text-decoration: none; color: inherit; }
a.sticker:hover, .sticker.hoverable:hover { transform: rotate(0deg) scale(1.02) translateY(-2px); box-shadow: 0 0 0 2px var(--line), 9px 9px 0 var(--tinta); }

.sticker.roxo { background: var(--roxo); color: #fff; }
.sticker.roxo a { color: var(--amarelo); }
.sticker.amarelo { background: var(--amarelo); color: var(--tinta); }
.sticker.amarelo a { color: var(--roxo-escuro); }
.sticker.flat { box-shadow: 0 0 0 2px var(--line), var(--sticker-shadow-sm); }

/* "colar" o sticker ao aparecer */
@keyframes stick {
  /* parte de um estado visível: se a animação atrasar, nada some nem estoura a tela */
  0% { transform: rotate(calc(var(--tilt) - 4deg)) scale(1.03); }
  60% { transform: rotate(calc(var(--tilt) + 1deg)) scale(.99); }
  100% { transform: rotate(var(--tilt)) scale(1); }
}
.stick-in { animation: stick .5s cubic-bezier(.34, 1.56, .64, 1); }
@media (prefers-reduced-motion: reduce) { .stick-in { animation: none; } }

/* ---------- Botões ---------- */
.btn {
  --btn-bg: var(--roxo);
  --btn-fg: #fff;
  display: inline-flex; align-items: center; justify-content: center; gap: 8px;
  font-family: var(--font-display);
  font-size: 1.1rem;
  letter-spacing: .4px;
  color: var(--btn-fg);
  background: var(--btn-bg);
  border: 4px solid var(--vinil);
  border-radius: 999px;
  padding: 12px 24px;
  box-shadow: 0 0 0 2px var(--tinta), 4px 5px 0 2px var(--tinta);
  cursor: pointer;
  text-decoration: none;
  transition: transform .12s, box-shadow .12s;
  min-height: 48px;
  white-space: nowrap;
}
.btn:hover { transform: translateY(-2px) rotate(-1deg); }
.btn:active { transform: translate(3px, 4px); box-shadow: 0 0 0 2px var(--tinta), 1px 1px 0 2px var(--tinta); }
.btn:disabled, .btn[aria-disabled="true"] { opacity: .55; cursor: not-allowed; transform: none; }
.btn.amarelo { --btn-bg: var(--amarelo); --btn-fg: var(--tinta); }
.btn.branco { --btn-bg: #fff; --btn-fg: var(--roxo); }
.btn.perigo { --btn-bg: var(--vermelho); }
.btn.verde { --btn-bg: var(--verde); }
.btn.sm { font-size: .9rem; padding: 6px 14px; min-height: 36px; border-width: 3px; box-shadow: 0 0 0 2px var(--tinta), 2px 3px 0 2px var(--tinta); }
.btn.lg { font-size: 1.35rem; padding: 16px 32px; }
.btn.block { width: 100%; }
.btn-link { background: none; border: 0; color: var(--roxo); font: inherit; font-weight: 800; cursor: pointer; padding: 0; text-decoration: underline; }

/* ---------- Badges / selos ---------- */
.badge {
  display: inline-flex; align-items: center; gap: 4px;
  font-weight: 800; font-size: .78rem; text-transform: uppercase; letter-spacing: .5px;
  padding: 3px 10px;
  border-radius: 999px;
  background: var(--roxo-bg);
  color: var(--roxo);
  border: 2px solid var(--vinil);
  box-shadow: 0 0 0 1.5px var(--line);
}
.badge.amarelo { background: var(--amarelo); color: var(--tinta); }
.badge.roxo { background: var(--roxo); color: #fff; }
.badge.verde { background: #D6F5E8; color: #0B7A4E; }
.badge.cinza { background: var(--surface-2); color: var(--text-muted); }
.badge.vermelho { background: #FFE1E5; color: #B3172E; }

.seal { /* selo redondo tipo figurinha */
  display: inline-grid; place-items: center;
  width: 92px; height: 92px;
  border-radius: 50%;
  background: var(--amarelo);
  color: var(--tinta);
  border: 5px solid var(--vinil);
  box-shadow: 0 0 0 2px var(--tinta), 4px 4px 0 2px var(--tinta);
  font-family: var(--font-display);
  text-align: center; line-height: 1;
  transform: rotate(-12deg);
  padding: 8px;
}

/* ---------- Formulários ---------- */
label { display: block; font-weight: 800; margin-bottom: 6px; }
.field { margin-bottom: 16px; }
.hint { font-size: .85rem; color: var(--text-muted); margin-top: 4px; }
input:not([type]), input[type=text], input[type=email], input[type=password], input[type=tel], input[type=number], input[type=date],
input[type=datetime-local], input[type=url], select, textarea {
  width: 100%;
  font: inherit;
  color: var(--text);
  background: var(--surface);
  border: 3px solid var(--line);
  border-radius: var(--radius-sm);
  padding: 12px 14px;
  min-height: 48px;
  transition: border-color .15s, box-shadow .15s;
}
input:focus, select:focus, textarea:focus { outline: none; border-color: var(--roxo); box-shadow: 0 0 0 4px color-mix(in srgb, var(--roxo) 22%, transparent); }
textarea { min-height: 110px; resize: vertical; }
.check { display: flex; gap: 10px; align-items: flex-start; font-weight: 600; cursor: pointer; }
.check input { width: 22px; height: 22px; accent-color: var(--roxo); flex: none; margin-top: 2px; }
input.code-input { font-family: var(--font-display); font-size: 1.6rem; letter-spacing: 3px; text-align: center; text-transform: uppercase; }

/* ---------- Alertas ---------- */
.flash { padding: 12px 16px; border-radius: var(--radius-sm); border: 3px solid var(--vinil); box-shadow: 0 0 0 2px var(--line), var(--sticker-shadow-sm); font-weight: 700; margin-bottom: 16px; }
.flash.success { background: #D6F5E8; color: #075C3B; }
.flash.error { background: #FFE1E5; color: #8C1023; }
.flash.info { background: var(--amarelo-claro); color: var(--tinta); }

/* ---------- Navegação ---------- */
.topbar { padding: 14px 0; }
.topbar .container { display: flex; align-items: center; justify-content: space-between; gap: 12px; }
.topbar nav { display: flex; gap: 8px; align-items: center; flex-wrap: wrap; }
.navlink { color: var(--text); text-decoration: none; font-weight: 800; padding: 6px 10px; border-radius: 999px; }
.navlink:hover { background: var(--roxo-bg); color: var(--roxo); }

.panel-shell { display: grid; grid-template-columns: 240px minmax(0, 1fr); gap: 24px; padding-block: 16px 48px; }
.sidebar { position: sticky; top: 16px; align-self: start; }
.sidebar a { display: flex; align-items: center; gap: 10px; padding: 10px 14px; border-radius: 14px; color: var(--text); text-decoration: none; font-weight: 800; }
.sidebar a:hover { background: var(--roxo-bg); color: var(--roxo); }
.sidebar a.active { background: var(--roxo); color: #fff; box-shadow: var(--sticker-shadow-sm); transform: rotate(-1deg); }
.sidebar .ico { font-size: 1.2rem; width: 26px; text-align: center; }
.sidebar .count { margin-left: auto; background: var(--amarelo); color: var(--tinta); border-radius: 999px; font-size: .75rem; padding: 0 8px; }
.panel-main { min-width: 0; }
.panel-head { display: flex; justify-content: space-between; align-items: flex-start; gap: 16px; flex-wrap: wrap; margin-bottom: 20px; }
.panel-head h1 { font-size: clamp(1.7rem, 4vw, 2.4rem); }

@media (max-width: 860px) {
  .panel-shell { grid-template-columns: 1fr; }
  .sidebar { position: static; display: flex; gap: 6px; overflow-x: auto; margin: 0 -16px; padding: 4px 16px 12px; scrollbar-width: none; }
  .sidebar a { white-space: nowrap; flex: none; }
  .sidebar .side-foot { display: none; }
}

/* ---------- Stat tiles ---------- */
.stat { padding: 16px 18px; }
.stat .value { font-family: var(--font-display); font-size: 2.2rem; line-height: 1; color: var(--roxo); }
.stat.amarelo .value, .stat.roxo .value { color: inherit; }
.stat .label { font-weight: 800; font-size: .9rem; margin-top: 6px; }
.stat .sub { font-size: .8rem; color: var(--text-muted); }
.sticker.roxo .sub { color: #E5DAFF; }

/* ---------- Tabelas ---------- */
.table-wrap { overflow-x: auto; }
.table-wrap table { min-width: 560px; }
table { width: 100%; border-collapse: collapse; font-size: .95rem; }
th { text-align: left; font-size: .78rem; text-transform: uppercase; letter-spacing: .5px; color: var(--text-muted); padding: 8px 10px; border-bottom: 2px solid var(--line); }
td { padding: 10px; border-bottom: 1px solid var(--line); vertical-align: middle; }
tr:last-child td { border-bottom: 0; }
.num { font-variant-numeric: tabular-nums; text-align: right; }

/* ---------- Barras (jogadas por dia) ---------- */
.bars { display: flex; align-items: flex-end; gap: 6px; height: 140px; padding-top: 8px; }
.bars .bar { flex: 1; display: flex; flex-direction: column; justify-content: flex-end; align-items: center; height: 100%; gap: 4px; min-width: 0; }
.bars .fill { width: 100%; max-width: 28px; background: var(--chart-bar); border-radius: 4px 4px 0 0; min-height: 2px; }
.bars .bar:hover .fill, .bars .bar:focus .fill { opacity: .8; }
.bars .bar:focus { outline: 2px solid var(--roxo); outline-offset: 2px; border-radius: 4px; }
.bars .baseline { border-top: 1px solid var(--line); }
.bars .tick { font-size: .65rem; color: var(--text-muted); white-space: nowrap; }
.bars .bar .tip { font-size: .7rem; font-weight: 800; color: var(--text); opacity: 0; transition: opacity .15s; }
.bars .bar:hover .tip, .bars .bar:focus .tip { opacity: 1; }

/* ---------- Hero / landing ---------- */
.hero { padding: 32px 0 56px; }
.hero-grid { display: grid; grid-template-columns: 1.1fr .9fr; gap: 40px; align-items: center; }
@media (max-width: 860px) { .hero-grid { grid-template-columns: 1fr; } }
.hero h1 .hl { background: var(--amarelo); padding: 0 .2em; border-radius: 10px; box-shadow: var(--sticker-shadow-sm); display: inline-block; transform: rotate(-2deg); }
.lead { font-size: 1.2rem; color: var(--text-muted); max-width: 560px; }
.sticker-cloud { position: relative; min-height: 380px; }
.sticker-cloud .sticker { position: absolute; }
.feature .emoji { font-size: 2.2rem; line-height: 1; display: block; margin-bottom: 10px; }
.section { padding: 56px 0; }
.band { background: var(--roxo); color: #fff; padding: 56px 0; border-top: 6px solid var(--vinil); border-bottom: 6px solid var(--vinil); box-shadow: 0 0 0 2px var(--tinta); }
.band h2 { color: #fff; }
.steps { counter-reset: step; }
.step { position: relative; padding-left: 64px; }
.step::before { counter-increment: step; content: counter(step); position: absolute; left: 0; top: 0; width: 46px; height: 46px; display: grid; place-items: center; border-radius: 50%; background: var(--amarelo); color: var(--tinta); font-family: var(--font-display); font-size: 1.4rem; border: 4px solid #fff; box-shadow: 3px 3px 0 var(--tinta); }

.price-card { display: flex; flex-direction: column; }
.price-card .price { font-family: var(--font-display); font-size: 2.6rem; color: var(--roxo); line-height: 1; }
.price-card.featured { background: var(--roxo); color: #fff; }
.price-card.featured .price { color: var(--amarelo); }
.price-card ul { list-style: none; padding: 0; margin: 16px 0; flex: 1; }
.price-card li { padding: 6px 0 6px 28px; position: relative; }
.price-card li::before { content: "★"; position: absolute; left: 0; color: var(--amarelo-escuro); }
.price-card.featured li::before { color: var(--amarelo); }
.price-card li.off { opacity: .45; text-decoration: line-through; }
.price-card li.off::before { content: "–"; }

/* ---------- Área do cliente (jogar) ---------- */
.play-wrap { max-width: 480px; margin: 0 auto; padding: 12px 16px 40px; }
.store-head { display: flex; align-items: center; gap: 12px; margin-bottom: 16px; }
.store-logo { width: 56px; height: 56px; border-radius: 50%; object-fit: cover; border: 4px solid var(--vinil); box-shadow: 0 0 0 2px var(--tinta), 3px 3px 0 2px var(--tinta); background: var(--amarelo); display: grid; place-items: center; font-family: var(--font-display); font-size: 1.6rem; color: var(--tinta); flex: none; }
.store-head .name { font-family: var(--font-display); font-size: 1.4rem; line-height: 1.1; }
.plays-pill { display: inline-flex; align-items: center; gap: 6px; background: var(--amarelo); color: var(--tinta); font-family: var(--font-display); padding: 6px 14px; border-radius: 999px; border: 3px solid #fff; box-shadow: 0 0 0 2px var(--tinta), 3px 3px 0 2px var(--tinta); }
.made-with { text-align: center; font-size: .8rem; color: var(--text-muted); margin-top: 32px; }
.made-with a { text-decoration: none; }
.tabbar {
  display: flex; justify-content: space-around; gap: 4px;
  position: sticky; bottom: calc(10px + env(safe-area-inset-bottom, 0px)); z-index: 20;
  margin: 24px 0 0; padding: 6px;
  background: var(--surface); border: 4px solid var(--vinil); border-radius: 22px;
  box-shadow: 0 0 0 2px var(--line), 4px 5px 0 var(--tinta);
}
.tabbar a { flex: 1; text-align: center; text-decoration: none; color: var(--text); font-weight: 800; font-size: .85rem; padding: 8px 4px; border-radius: 14px; }
.tabbar a .ico { display: block; font-size: 1.5rem; }
.tabbar a.active { background: var(--roxo); color: #fff; box-shadow: var(--sticker-shadow-sm); }

/* Roleta */
.wheel-box { position: relative; width: min(340px, 86vw); max-width: 100%; aspect-ratio: 1; margin: 34px auto 24px; }
.wheel-box svg.wheel { width: 100%; height: 100%; border-radius: 50%; border: 8px solid var(--vinil); box-shadow: 0 0 0 3px var(--tinta), 7px 8px 0 3px var(--tinta); transition: transform 5s cubic-bezier(.12, .8, .14, 1); background: var(--surface); }
.wheel-pointer { position: absolute; left: 50%; top: -18px; transform: translateX(-50%); width: 46px; height: 56px; z-index: 2; filter: drop-shadow(3px 3px 0 var(--tinta)); }
.wheel-hub { position: absolute; left: 50%; top: 50%; transform: translate(-50%, -50%); width: 56px; height: 56px; border-radius: 50%; background: var(--amarelo); border: 5px solid #fff; box-shadow: 0 0 0 3px var(--tinta); display: grid; place-items: center; font-family: var(--font-display); font-size: .75rem; z-index: 2; color: var(--tinta); }

/* Raspadinha */
.scratch-box { position: relative; width: min(340px, 86vw); aspect-ratio: 4/3; margin: 10px auto 24px; border-radius: var(--radius); border: 8px solid var(--vinil); box-shadow: 0 0 0 3px var(--tinta), 7px 8px 0 3px var(--tinta); overflow: hidden; background: var(--amarelo-claro); transform: rotate(-1.5deg); touch-action: none; }
.scratch-prize { position: absolute; inset: 0; display: grid; place-items: center; text-align: center; padding: 16px; }
.scratch-prize .emoji { font-size: 4rem; line-height: 1; }
.scratch-prize .label { font-family: var(--font-display); font-size: 1.6rem; color: var(--tinta); }
.scratch-box canvas { position: absolute; inset: 0; width: 100%; height: 100%; cursor: grab; }

/* Jackpot */
.slot { width: min(360px, 90vw); margin: 10px auto 24px; padding: 18px; border-radius: 28px; background: var(--roxo); border: 8px solid var(--vinil); box-shadow: 0 0 0 3px var(--tinta), 7px 8px 0 3px var(--tinta); }
.slot-title { font-family: var(--font-display); color: var(--amarelo); text-align: center; font-size: 1.5rem; margin-bottom: 10px; text-shadow: 2px 2px 0 var(--tinta); }
.reels { display: grid; grid-template-columns: repeat(3, 1fr); gap: 10px; }
.reel { height: 110px; overflow: hidden; background: #fff; border-radius: 16px; border: 4px solid var(--amarelo); position: relative; }
.reel-strip { position: absolute; left: 0; right: 0; top: 0; }
.reel-item { height: 110px; display: grid; place-items: center; font-size: 3.2rem; }
.reel::after { content: ""; position: absolute; inset: 0; background: linear-gradient(#fff 0, transparent 22%, transparent 78%, #fff 100%); pointer-events: none; opacity: .7; }

/* Modal de resultado */
.modal-back { position: fixed; inset: 0; background: rgba(26, 11, 61, .65); display: grid; place-items: center; padding: 16px; z-index: 50; }
.modal { width: 100%; max-width: 420px; text-align: center; max-height: 92vh; overflow-y: auto; }
.prize-emoji { font-size: 4.5rem; line-height: 1; margin: 8px 0; }
.coupon-code { font-family: var(--font-display); font-size: 1.7rem; letter-spacing: 2px; background: var(--amarelo); color: var(--tinta); padding: 8px 14px; border-radius: 12px; display: inline-block; border: 3px dashed var(--tinta); }

/* Cartela de figurinhas */
.card-grid { display: grid; grid-template-columns: repeat(4, 1fr); gap: 10px; }
.slot-stamp { aspect-ratio: 1; border-radius: 50%; border: 3px dashed var(--line); display: grid; place-items: center; font-size: 1.6rem; color: var(--line); background: var(--surface-2); }
.slot-stamp.on { border: 4px solid #fff; background: var(--amarelo); color: var(--tinta); box-shadow: 0 0 0 2px var(--tinta), 2px 3px 0 2px var(--tinta); transform: rotate(-8deg); }
.slot-stamp.on:nth-child(even) { transform: rotate(7deg); background: var(--roxo-claro); }
.slot-stamp.goal { border-color: var(--roxo); color: var(--roxo); font-size: 1.3rem; }

/* Cupom (carteira) */
.coupon { display: flex; gap: 14px; align-items: center; }
.coupon .qr { flex: none; width: 96px; height: 96px; background: #fff; padding: 6px; border-radius: 10px; }
.coupon .qr img, .coupon .qr canvas { width: 100% !important; height: 100% !important; }
.coupon.used { opacity: .5; filter: grayscale(.8); }

/* Mural / álbum */
.mural { columns: 2 160px; column-gap: 14px; }
.photo-sticker { break-inside: avoid; margin-bottom: 16px; background: #fff; padding: 8px 8px 10px; border-radius: 16px; box-shadow: 0 0 0 2px var(--tinta), 4px 4px 0 2px var(--tinta); transform: rotate(var(--tilt, -2deg)); color: var(--tinta); }
.photo-sticker:nth-child(3n+2) { --tilt: 2.5deg; }
.photo-sticker:nth-child(3n) { --tilt: -1deg; }
.photo-sticker img { border-radius: 10px; width: 100%; aspect-ratio: 1; object-fit: cover; }
.photo-sticker .cap { font-size: .85rem; font-weight: 700; margin-top: 6px; }
.photo-sticker .meta { display: flex; justify-content: space-between; align-items: center; font-size: .8rem; color: #5B4E7A; }
.like-btn { background: none; border: 0; font: inherit; font-weight: 800; cursor: pointer; color: var(--roxo); }

/* QR imprimível */
.qr-sheet { display: grid; grid-template-columns: repeat(4, 1fr); gap: 6mm; }
.qr-sticker { border: 2px dashed #bbb; border-radius: 50%; aspect-ratio: 1; display: flex; flex-direction: column; align-items: center; justify-content: center; padding: 6mm; background: var(--amarelo); color: var(--tinta); text-align: center; break-inside: avoid; }
.qr-sticker .qr { background: #fff; padding: 4px; border-radius: 8px; width: 62%; aspect-ratio: 1; }
.qr-sticker .qr img, .qr-sticker .qr canvas { width: 100% !important; height: auto !important; }
.qr-sticker .t { font-family: var(--font-display); font-size: 12pt; line-height: 1; margin-bottom: 2mm; }
.qr-sticker .c { font-size: 7pt; font-weight: 800; letter-spacing: 1px; margin-top: 1mm; }
@media print {
  .no-print { display: none !important; }
  body { background: #fff; }
  .qr-sticker { -webkit-print-color-adjust: exact; print-color-adjust: exact; }
}

/* Editor de prêmios */
.prize-row { display: grid; grid-template-columns: 52px minmax(150px, 2fr) minmax(150px, 1.5fr) 76px 76px 84px 64px 44px; gap: 8px; align-items: center; padding: 8px 0; border-bottom: 1px dashed var(--line); }
.prize-row input, .prize-row select { min-height: 42px; padding: 8px 10px; }
.prize-row .pr-emoji { text-align: center; font-size: 1.3rem; padding: 4px; }
.prize-row label { margin: 0; font-weight: 400; }
.prize-row .mini { display: none; font-size: .7rem; font-weight: 800; text-transform: uppercase; color: var(--text-muted); margin-bottom: 2px; }
.prize-head { font-size: .72rem; font-weight: 800; text-transform: uppercase; color: var(--text-muted); border-bottom: 2px solid var(--line); }
.chance { font-weight: 800; color: var(--roxo); font-variant-numeric: tabular-nums; font-size: .9rem; }
@media (max-width: 1100px) {
  .prize-head { display: none; }
  .prize-row {
    grid-template-columns: 52px 1fr 1fr 1fr;
    grid-template-areas: "emoji label label remove" "kind kind kind kind" "value weight stock chance";
    background: var(--surface-2); border-radius: 14px; padding: 10px; margin-bottom: 10px; border: 0;
  }
  .prize-row .pr-emoji { grid-area: emoji; } .prize-row .pr-label { grid-area: label; } .prize-row .pr-kind { grid-area: kind; }
  .prize-row .pr-value { grid-area: value; } .prize-row .pr-weight { grid-area: weight; } .prize-row .pr-stock { grid-area: stock; }
  .prize-row .chance { grid-area: chance; align-self: end; padding-bottom: 10px; text-align: center; }
  .prize-row [data-remove] { grid-area: remove; justify-self: end; }
  .prize-row .mini { display: block; }
}

/* Confete */
.confetti { position: fixed; top: -12px; width: 10px; height: 14px; z-index: 60; pointer-events: none; animation: fall linear forwards; border-radius: 2px; }
@keyframes fall { to { transform: translateY(105vh) rotate(720deg); } }

/* Toast */
.toast { position: fixed; left: 50%; bottom: 24px; transform: translateX(-50%); background: var(--tinta); color: #fff; padding: 12px 20px; border-radius: 999px; font-weight: 800; z-index: 70; box-shadow: 4px 4px 0 var(--amarelo); max-width: calc(100vw - 32px); }

/* Story preview */
.story-preview { width: 100%; max-width: 220px; aspect-ratio: 9/16; margin: 0 auto; border-radius: 16px; box-shadow: 0 0 0 2px var(--tinta), 4px 4px 0 2px var(--tinta); }

.empty { text-align: center; padding: 36px 16px; color: var(--text-muted); }
.empty .emoji { font-size: 3rem; display: block; margin-bottom: 8px; }
.kbd { font-family: ui-monospace, Consolas, monospace; background: var(--surface-2); padding: 2px 6px; border-radius: 6px; font-size: .85em; word-break: break-all; }
.upsell { border-style: dashed !important; }

/* Ajuda "como ganhar jogadas" e caixa da loja demo */
.how-list { list-style: none; padding: 0; margin: 0; display: grid; gap: 12px; }
.how-list li { display: flex; gap: 12px; align-items: flex-start; }
.how-list li > span { font-size: 1.6rem; line-height: 1; flex: none; width: 32px; text-align: center; }
.demo-box { border-style: dashed !important; }

/* Seletor de arquivo como botão sticker */
.file-pick { display: flex; align-items: center; gap: 12px; flex-wrap: wrap; }
.file-pick input[type=file] { position: absolute; width: 1px; height: 1px; opacity: 0; }
.file-pick .file-name { font-weight: 700; font-size: .9rem; color: var(--tinta); min-width: 0; overflow-wrap: anywhere; }
.file-pick input[type=file]:focus-visible + .btn { outline: 3px solid var(--roxo); outline-offset: 3px; }
.photo-preview { width: 100%; max-height: 220px; object-fit: cover; border-radius: 14px; border: 4px solid #fff; box-shadow: 0 0 0 2px var(--tinta); }

/* Site comercial no celular */
@media (max-width: 640px) {
  .topbar .navlink.hide-sm { display: none; }
  .topbar .logo { font-size: 1.6rem; }
  .topbar .btn.sm { padding: 6px 12px; }
  .topbar nav { gap: 4px; flex-wrap: nowrap; }
  .hero { padding-top: 12px; }
  .sticker-cloud { min-height: 0; display: grid; gap: 18px; padding: 8px 6px 0; }
  .sticker-cloud .sticker, .sticker-cloud .seal { position: relative !important; inset: auto !important; width: auto !important; }
  .sticker-cloud .seal { display: none; }
  .steps { grid-template-columns: 1fr; }
}
@media (max-width: 400px) { .topbar .navlink.hide-xs { display: none; } }

/* Cabeçalho do painel no celular */
@media (max-width: 640px) {
  .topbar .plan-badge { display: none; }
  .topbar .page-link .long { display: none; }
}

/* Texto secundário legível sobre os cartões amarelos (em qualquer tema) */
.sticker.amarelo small, .sticker.amarelo .hint, .sticker.amarelo .muted, .sticker.amarelo label small { color: #4A3D6B; }
td .kbd, .kbd.nowrap { white-space: nowrap; word-break: normal; }

/* Vídeo de apresentação na landing */
.video-grid { display: grid; grid-template-columns: minmax(0, 1fr) 260px; gap: 24px; align-items: start; }
.video-frame { padding: 0; overflow: hidden; }
.video-frame video { display: block; width: 100%; height: auto; aspect-ratio: 16 / 9; background: var(--roxo-escuro); border-radius: calc(var(--radius) - 6px); }
.chapters h3 { margin-bottom: 8px; }
.chapters ol { list-style: none; padding: 0; margin: 0; display: grid; gap: 2px; }
.chapter { display: flex; gap: 10px; width: 100%; text-align: left; background: none; border: 0; padding: 7px 8px; border-radius: 10px; font: inherit; font-weight: 800; color: var(--text); cursor: pointer; }
.chapter:hover, .chapter:focus-visible { background: var(--roxo-bg); color: var(--roxo); }
.chapter .t { font-variant-numeric: tabular-nums; color: var(--roxo); min-width: 38px; }
@media (max-width: 860px) {
  .video-grid { grid-template-columns: 1fr; }
  .chapters ol { grid-template-columns: repeat(2, minmax(0, 1fr)); }
}
