:root {
  --bg: #fff8f4;
  --surface: #ffffff;
  --text: #1d1428;
  --muted: #6d6478;
  --line: #f1e4dc;
  --brand: #ff5a1f;
  --brand2: #ff2e63;
  --grad: linear-gradient(135deg, #ff8a3d 0%, #ff5a1f 45%, #ff2e63 100%);
  --shadow: 0 10px 30px -12px rgba(255, 90, 31, .28), 0 2px 8px -2px rgba(29, 20, 40, .06);
  --radius: 20px;
}
[data-theme="dark"] {
  --bg: #120d18;
  --surface: #1c1524;
  --text: #f6eff9;
  --muted: #a99db5;
  --line: #2c2236;
  --shadow: 0 10px 30px -12px rgba(0, 0, 0, .6);
}
* { box-sizing: border-box; }
html { scroll-behavior: smooth; }
body {
  margin: 0; font-family: "Plus Jakarta Sans", system-ui, sans-serif; background: var(--bg); color: var(--text);
  -webkit-font-smoothing: antialiased; overflow-x: hidden; transition: background .3s, color .3s;
}
a { color: inherit; }
.hidden { display: none !important; }

/* Fundo animado */
.bg-blobs { position: fixed; inset: 0; z-index: -1; pointer-events: none; overflow: hidden; }
.bg-blobs span { position: absolute; width: 520px; height: 520px; border-radius: 50%; filter: blur(90px); opacity: .35; animation: drift 18s ease-in-out infinite alternate; }
.bg-blobs span:nth-child(1) { background: #ffb37a; top: -160px; left: -120px; }
.bg-blobs span:nth-child(2) { background: #ff7aa2; top: 120px; right: -180px; animation-delay: -6s; }
.bg-blobs span:nth-child(3) { background: #ffd166; bottom: -220px; left: 30%; animation-delay: -12s; opacity: .22; }
[data-theme="dark"] .bg-blobs span { opacity: .14; }
@keyframes drift { to { transform: translate(60px, 40px) scale(1.12); } }

/* Topo */
.topbar {
  position: sticky; top: 12px; z-index: 50; margin: 12px auto 0; max-width: 1200px; width: calc(100% - 24px);
  display: flex; align-items: center; gap: 16px; padding: 10px 14px 10px 18px; border-radius: 999px;
  background: color-mix(in srgb, var(--surface) 72%, transparent); backdrop-filter: blur(16px) saturate(160%);
  border: 1px solid var(--line); box-shadow: var(--shadow);
}
.brand { display: flex; align-items: center; gap: 10px; text-decoration: none; font-weight: 800; font-size: 20px; letter-spacing: -.02em; }
.brand b { color: var(--brand); }
.logo { width: 34px; height: 34px; border-radius: 11px; background: var(--grad); color: #fff; display: grid; place-items: center; }
.logo svg { width: 20px; height: 20px; }
.nav { margin-left: auto; display: flex; gap: 6px; }
.nav a { text-decoration: none; font-weight: 600; font-size: 14px; color: var(--muted); padding: 8px 14px; border-radius: 999px; transition: .2s; }
.nav a:hover { color: var(--text); background: var(--line); }
.icon-btn { border: 0; background: var(--line); color: var(--text); width: 40px; height: 40px; border-radius: 50%; cursor: pointer; display: grid; place-items: center; }

/* Hero */
main { max-width: 1200px; margin: 0 auto; padding: 0 20px; }
.hero { display: grid; grid-template-columns: minmax(0,1.25fr) minmax(0,.75fr); gap: 40px; align-items: center; padding: 72px 0 40px; }
.pill { display: inline-flex; align-items: center; gap: 8px; font-size: 13px; font-weight: 600; padding: 7px 14px; border-radius: 999px; background: var(--surface); border: 1px solid var(--line); color: var(--muted); }
.dot { width: 8px; height: 8px; border-radius: 50%; background: #22c55e; box-shadow: 0 0 0 4px rgba(34, 197, 94, .2); animation: pulse 2s infinite; }
@keyframes pulse { 50% { box-shadow: 0 0 0 8px rgba(34, 197, 94, 0); } }
.eyebrow { margin: 22px 0 0; font-weight: 800; font-size: 15px; letter-spacing: .18em; text-transform: uppercase; color: var(--brand); }
.eyebrow + h1 { margin-top: 8px; }
h1 { font-size: clamp(38px, 6vw, 68px); line-height: 1.02; letter-spacing: -.045em; margin: 18px 0 16px; font-weight: 800; }
.grad { background: var(--grad); -webkit-background-clip: text; background-clip: text; color: transparent; }
.lead { font-size: 18px; color: var(--muted); max-width: 540px; line-height: 1.55; margin: 0 0 28px; }

.search { display: flex; align-items: center; gap: 10px; background: var(--surface); border: 2px solid var(--line); border-radius: 999px; padding: 8px 8px 8px 20px; box-shadow: var(--shadow); max-width: 600px; transition: border-color .2s; }
.search:focus-within { border-color: var(--brand); }
.search svg { color: var(--muted); flex: none; }
.search input { flex: 1; border: 0; outline: 0; background: transparent; font: inherit; font-size: 16px; color: var(--text); min-width: 0; }
.search button, .buy, .primary { border: 0; cursor: pointer; font: inherit; font-weight: 700; color: #fff; background: var(--grad); border-radius: 999px; padding: 13px 24px; text-decoration: none; transition: transform .15s, box-shadow .2s; box-shadow: 0 8px 20px -8px rgba(255, 46, 99, .6); }
.search button:hover, .buy:hover, .primary:hover { transform: translateY(-1px); box-shadow: 0 12px 24px -8px rgba(255, 46, 99, .7); }

.chips { display: flex; flex-wrap: wrap; gap: 8px; margin-top: 18px; }
.chip { border: 1px solid var(--line); background: var(--surface); color: var(--text); font: inherit; font-weight: 600; font-size: 14px; padding: 8px 14px; border-radius: 999px; cursor: pointer; transition: .2s; }
.chip:hover, .chip.active { border-color: var(--brand); color: var(--brand); background: color-mix(in srgb, var(--brand) 8%, var(--surface)); }

.hero-art { position: relative; height: 380px; }
.bag { position: absolute; inset: 40px 30px; display: grid; place-items: center; animation: bob 5s ease-in-out infinite; }
.bag svg { width: 100%; max-width: 280px; filter: drop-shadow(0 30px 40px rgba(255, 46, 99, .35)); }
@keyframes bob { 50% { transform: translateY(-14px) rotate(-2deg); } }
.float-card { position: absolute; z-index: 2; background: var(--surface); border: 1px solid var(--line); border-radius: 16px; padding: 12px 16px; box-shadow: var(--shadow); display: flex; flex-direction: column; animation: bob 6s ease-in-out infinite; }
.float-card b { font-size: 20px; }
.float-card small { color: var(--muted); font-size: 12px; font-weight: 600; }
.fc1 { top: 20px; left: 0; } .fc1 b { color: var(--brand2); }
.fc2 { top: 140px; right: -10px; animation-delay: -2s; } .fc2 b { color: #f5a524; }
.fc3 { bottom: 20px; left: 30px; animation-delay: -4s; } .fc3 b { color: #16a34a; }

/* Blocos */
.block { padding: 36px 0; }
.block-head { display: flex; align-items: end; justify-content: space-between; gap: 20px; flex-wrap: wrap; margin-bottom: 22px; }
h2 { font-size: clamp(26px, 3.4vw, 36px); letter-spacing: -.03em; margin: 0; }
.block-head p { margin: 6px 0 0; color: var(--muted); }
.tabs { display: flex; gap: 4px; background: var(--surface); padding: 5px; border-radius: 999px; border: 1px solid var(--line); overflow-x: auto; max-width: 100%; }
.tabs button { border: 0; background: transparent; font: inherit; font-weight: 700; font-size: 14px; color: var(--muted); padding: 9px 16px; border-radius: 999px; cursor: pointer; white-space: nowrap; }
.tabs button.active { background: var(--text); color: var(--bg); }
.demo-banner { background: color-mix(in srgb, #f5a524 14%, var(--surface)); border: 1px dashed #f5a524; padding: 12px 16px; border-radius: 14px; margin-bottom: 18px; font-size: 14px; }

/* Cards */
.grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(220px, 1fr)); gap: 18px; }
.rail { display: grid; grid-auto-flow: column; grid-auto-columns: minmax(230px, 260px); gap: 18px; overflow-x: auto; padding-bottom: 12px; scroll-snap-type: x mandatory; }
.rail .card { scroll-snap-align: start; }
.card { background: var(--surface); border: 1px solid var(--line); border-radius: var(--radius); overflow: hidden; display: flex; flex-direction: column; transition: transform .25s, box-shadow .25s; animation: rise .5s both; }
.card:hover { transform: translateY(-5px); box-shadow: var(--shadow); }
@keyframes rise { from { opacity: 0; transform: translateY(14px); } }
.thumb { position: relative; display: block; aspect-ratio: 1; background: var(--line); overflow: hidden; }
.thumb img { width: 100%; height: 100%; object-fit: cover; transition: transform .5s; }
.card:hover .thumb img { transform: scale(1.06); }
.badge { position: absolute; font-size: 12px; font-weight: 800; padding: 5px 9px; border-radius: 9px; }
.badge.off { top: 10px; left: 10px; background: var(--brand2); color: #fff; }
.badge.rank { top: 10px; right: 10px; background: var(--text); color: var(--bg); min-width: 30px; text-align: center; }
.badge.pin { background: #f5a524; color: #1d1428; }
.badge.official { bottom: 10px; left: 10px; background: rgba(255, 255, 255, .92); color: #d0011b; }
.body { padding: 14px; display: flex; flex-direction: column; gap: 8px; flex: 1; }
.name { font-size: 14.5px; font-weight: 600; line-height: 1.35; margin: 0; display: -webkit-box; -webkit-line-clamp: 2; -webkit-box-orient: vertical; overflow: hidden; min-height: 2.7em; }
.meta { display: flex; gap: 10px; font-size: 12.5px; color: var(--muted); font-weight: 600; }
.rating { color: #f5a524; }
.price { font-size: 22px; font-weight: 800; letter-spacing: -.02em; color: var(--brand); }
.price small { font-size: 13px; font-weight: 700; }
.actions { display: flex; gap: 8px; margin-top: auto; }
.actions .buy { flex: 1; text-align: center; padding: 11px 12px; font-size: 14px; }
.actions button { border: 1px solid var(--line); background: var(--surface); color: var(--muted); width: 42px; border-radius: 12px; cursor: pointer; display: grid; place-items: center; transition: .2s; }
.actions .share:hover { color: #16a34a; border-color: #16a34a; }
.actions .copy:hover { color: var(--brand); border-color: var(--brand); }

.skeleton { border-radius: var(--radius); background: linear-gradient(90deg, var(--line) 25%, var(--surface) 50%, var(--line) 75%); background-size: 200% 100%; animation: shimmer 1.2s infinite; aspect-ratio: .68; }
@keyframes shimmer { to { background-position: -200% 0; } }

.more { text-align: center; margin-top: 28px; }
.ghost { border: 2px solid var(--text); background: transparent; color: var(--text); font: inherit; font-weight: 700; padding: 12px 28px; border-radius: 999px; cursor: pointer; transition: .2s; }
.ghost:hover { background: var(--text); color: var(--bg); }
.empty { grid-column: 1 / -1; text-align: center; padding: 50px 20px; color: var(--muted); }

.how { text-align: center; }
.steps { display: grid; grid-template-columns: repeat(3, 1fr); gap: 18px; margin-top: 26px; }
.step { background: var(--surface); border: 1px solid var(--line); border-radius: var(--radius); padding: 28px; text-align: left; }
.step span { width: 42px; height: 42px; border-radius: 14px; display: grid; place-items: center; background: var(--grad); color: #fff; font-weight: 800; font-size: 18px; }
.step h3 { margin: 16px 0 6px; } .step p { margin: 0; color: var(--muted); }

.footer { max-width: 1200px; margin: 40px auto 0; padding: 30px 20px 50px; border-top: 1px solid var(--line); text-align: center; }
.footer .fine { color: var(--muted); font-size: 13px; max-width: 680px; margin: 8px auto 0; line-height: 1.5; }

.credit { margin: 18px 0 0; font-size: 13px; color: var(--muted); }
.credit a { color: var(--brand); font-weight: 600; text-decoration: none; }
.credit a:hover { text-decoration: underline; }
.toast { position: fixed; bottom: 24px; left: 50%; transform: translate(-50%, 120px); background: var(--text); color: var(--bg); padding: 12px 20px; border-radius: 999px; font-weight: 700; transition: transform .3s, opacity .3s; z-index: 100; opacity: 0; pointer-events: none; }
.toast.show { transform: translate(-50%, 0); opacity: 1; }

@media (max-width: 860px) {
  .brand { font-size: 17px; }
  .hero { grid-template-columns: minmax(0,1fr); padding-top: 44px; }
  .search button { padding: 12px 16px; }
  .lead { font-size: 16px; }
  .hero-art { display: none; }
  .nav { display: none; }
  .icon-btn { margin-left: auto; }
  .steps { grid-template-columns: 1fr; }
  .grid { grid-template-columns: repeat(2, 1fr); gap: 12px; }
  .body { padding: 10px; }
  .price { font-size: 18px; }
  .actions .buy { font-size: 13px; padding: 10px 8px; }
  .actions button { width: 36px; }
}
