:root {
  color-scheme: dark;
  --bg: #0b0d12;
  --bg-2: #12151d;
  --panel: #171b26;
  --panel-2: #1e2433;
  --line: rgba(61, 160, 245, 0.18);
  --line-strong: rgba(61, 160, 245, 0.38);
  --text: #f5f7fa;
  --muted: #9aa8bf;
  --brand: #1088f0;
  --brand-2: #0068d8;
  --aqua: #00b4d8;
  --ok: #22c55e;
  --warn: #f59e0b;
  --danger: #ef4444;
  --sidebar-w: 280px;
  --radius: 16px;
  --font-display: -apple-system, BlinkMacSystemFont, "SF Pro Display", "Segoe UI", Roboto, Helvetica, Arial, sans-serif;
  --font-body: -apple-system, BlinkMacSystemFont, "SF Pro Text", "Segoe UI", Roboto, Helvetica, Arial, sans-serif;
  --shadow: 0 18px 50px rgba(0, 0, 0, 0.45);
  --bottom-nav-h: 0px;
  --safe-bottom: env(safe-area-inset-bottom, 0px);
  --safe-top: env(safe-area-inset-top, 0px);
}

*, *::before, *::after { box-sizing: border-box; }
html {
  color-scheme: dark;
  background-color: #0b0d12;
  -webkit-text-size-adjust: 100%;
}
html, body {
  margin: 0;
  min-height: 100%;
  min-height: 100dvh;
  background-color: #0b0d12;
  -webkit-user-select: none;
  user-select: none;
  -webkit-touch-callout: none;
  -webkit-tap-highlight-color: transparent;
  touch-action: manipulation;
}
img, a, svg, video, canvas {
  -webkit-user-drag: none;
  user-drag: none;
  -webkit-touch-callout: none;
}
input, textarea, select, [contenteditable="true"] {
  -webkit-user-select: text;
  user-select: text;
  -webkit-touch-callout: default;
}
body {
  font-family: var(--font-body);
  color: var(--text);
  background-color: #0b0d12;
  background-image:
    radial-gradient(900px 420px at 12% -8%, rgba(16, 136, 240, 0.16), transparent 55%),
    radial-gradient(700px 380px at 100% 0%, rgba(0, 180, 216, 0.1), transparent 50%),
    linear-gradient(180deg, #090b10, var(--bg) 40%, #07090e);
  line-height: 1.45;
  font-size: 16px;
  font-weight: 400;
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
}
body.scroll-lock {
  overflow: hidden;
}
body.modal-open .bottom-nav {
  visibility: hidden;
  pointer-events: none;
}

/* Scrollbars — Firefox */
* {
  scrollbar-width: thin;
  scrollbar-color: rgba(16, 136, 240, 0.55) rgba(12, 16, 24, 0.85);
}

/* Scrollbars — Chrome / Edge / Safari */
*::-webkit-scrollbar {
  width: 10px;
  height: 10px;
}
*::-webkit-scrollbar-track {
  background: rgba(12, 16, 24, 0.9);
  border-radius: 999px;
  border: 1px solid rgba(61, 160, 245, 0.08);
}
*::-webkit-scrollbar-thumb {
  background: linear-gradient(180deg, rgba(16, 136, 240, 0.75), rgba(0, 104, 216, 0.65));
  border-radius: 999px;
  border: 2px solid rgba(12, 16, 24, 0.9);
  background-clip: padding-box;
}
*::-webkit-scrollbar-thumb:hover {
  background: linear-gradient(180deg, rgba(0, 180, 216, 0.9), rgba(16, 136, 240, 0.85));
  border: 2px solid rgba(12, 16, 24, 0.9);
  background-clip: padding-box;
}
*::-webkit-scrollbar-corner {
  background: transparent;
}

button, input, select, textarea {
  font: inherit;
  color: var(--text);
}
input::placeholder,
textarea::placeholder {
  color: #8b9bb3;
  opacity: 1;
}
input::-webkit-input-placeholder { color: #8b9bb3; }
input:-webkit-autofill,
input:-webkit-autofill:hover,
input:-webkit-autofill:focus,
textarea:-webkit-autofill,
select:-webkit-autofill {
  -webkit-text-fill-color: #f5f7fa !important;
  caret-color: #f5f7fa;
  box-shadow: 0 0 0 1000px #0f1420 inset !important;
  transition: background-color 99999s ease-out;
}
img { max-width: 100%; display: block; }
.sr-only {
  position: absolute; width: 1px; height: 1px; padding: 0; margin: -1px;
  overflow: hidden; clip: rect(0,0,0,0); border: 0;
}

.app-shell {
  min-height: 100vh;
  display: grid;
  grid-template-columns: var(--sidebar-w) 1fr;
}

/* ---------- Sidebar ---------- */
.sidebar {
  position: sticky;
  top: 0;
  height: 100vh;
  overflow: auto;
  background: linear-gradient(180deg, #10141d 0%, #0c1018 100%);
  border-right: 1px solid var(--line);
  padding: 1rem 0.9rem 1.2rem;
  display: flex;
  flex-direction: column;
  gap: 1rem;
  z-index: 40;
}

.sidebar-brand {
  display: grid;
  grid-template-columns: auto 1fr auto;
  gap: 0.75rem;
  align-items: center;
  padding: 0.35rem 0.35rem 0.8rem;
  border-bottom: 1px solid var(--line);
}
.brand-mark {
  width: 2.6rem;
  height: 2.6rem;
  border-radius: 12px;
  display: grid;
  place-items: center;
  overflow: hidden;
  flex-shrink: 0;
  background: var(--brand);
  box-shadow: 0 10px 24px rgba(16, 136, 240, 0.35);
}
.brand-mark img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  display: block;
}
.brand-copy strong {
  display: block;
  font-family: var(--font-display);
  font-size: 0.95rem;
  letter-spacing: -0.02em;
  font-weight: 650;
  text-transform: none;
}
.brand-copy small { color: var(--muted); font-size: 0.82rem; font-weight: 400; }
.sidebar-close { display: none; }

.sidebar-search input {
  width: 100%;
  border: 1px solid var(--line);
  background: rgba(255,255,255,0.03);
  border-radius: 12px;
  padding: 0.75rem 0.9rem;
  outline: none;
}
.sidebar-search input:focus {
  border-color: var(--brand);
  box-shadow: 0 0 0 3px rgba(16, 136, 240, 0.18);
}

.nav-label {
  margin: 0 0 0.45rem;
  padding: 0 0.45rem;
  font-size: 0.72rem;
  letter-spacing: 0.06em;
  text-transform: uppercase;
  color: var(--muted);
  font-weight: 600;
}

.sidebar-nav, .sidebar-section { display: grid; gap: 0.3rem; }
.nav-item, .cat-item {
  display: flex;
  align-items: center;
  gap: 0.65rem;
  width: 100%;
  text-align: left;
  border: 1px solid transparent;
  background: transparent;
  color: var(--muted);
  border-radius: 12px;
  padding: 0.72rem 0.8rem;
  cursor: pointer;
  transition: 0.15s ease;
  font-weight: 600;
}
.nav-item:hover, .cat-item:hover {
  color: var(--text);
  background: rgba(16, 136, 240, 0.08);
}
.nav-item.active, .cat-item.active {
  color: var(--text);
  background: linear-gradient(90deg, rgba(16, 136, 240, 0.22), rgba(16, 136, 240, 0.05));
  border-color: var(--line-strong);
}
.nav-ico {
  width: 1.4rem;
  text-align: center;
  opacity: 0.85;
}
.cat-count {
  margin-left: auto;
  font-size: 0.8rem;
  color: var(--muted);
  background: rgba(255,255,255,0.04);
  border-radius: 999px;
  padding: 0.1rem 0.45rem;
}

.sidebar-foot {
  margin-top: auto;
  padding: 0.9rem;
  border-radius: 14px;
  background: rgba(16, 136, 240, 0.08);
  border: 1px solid var(--line);
}
.sidebar-foot p {
  margin: 0.45rem 0 0;
  color: var(--muted);
  font-size: 0.9rem;
}
.pay-badge {
  display: inline-flex;
  font-family: var(--font-display);
  font-size: 0.72rem;
  letter-spacing: 0.02em;
  text-transform: none;
  font-weight: 600;
  padding: 0.35rem 0.55rem;
  border-radius: 999px;
  background: rgba(0, 180, 216, 0.15);
  color: var(--aqua);
}

.sidebar-backdrop {
  display: none;
  position: fixed;
  inset: 0;
  background: rgba(0,0,0,0.55);
  backdrop-filter: blur(4px);
  z-index: 35;
}

/* ---------- Main ---------- */
.main-col { min-width: 0; }
.topbar {
  position: sticky;
  top: 0;
  z-index: 20;
  display: flex;
  align-items: center;
  gap: 0.8rem;
  padding: 0.85rem 1.25rem;
  padding-top: calc(0.85rem + var(--safe-top));
  background: #0b0d12;
  background: rgba(11, 13, 18, 0.94);
  -webkit-backdrop-filter: blur(14px);
  backdrop-filter: blur(14px);
  border-bottom: 1px solid var(--line);
}
.menu-toggle { display: none; }
.topbar-title {
  display: flex;
  flex-direction: column;
  min-width: 0;
}
.topbar-title span {
  font-family: var(--font-display);
  font-size: 1.05rem;
  letter-spacing: -0.02em;
  font-weight: 650;
  text-transform: none;
}
.topbar-title small { color: var(--muted); }
.topbar-actions {
  margin-left: auto;
  display: flex;
  align-items: center;
  gap: 0.5rem;
  min-width: 0;
}
.mobile-search {
  display: none;
  width: min(42vw, 11rem);
  border: 1px solid var(--line);
  background: rgba(255,255,255,0.04);
  border-radius: 12px;
  padding: 0.55rem 0.75rem;
  outline: none;
  font-size: 0.92rem;
  min-height: 44px;
}
.mobile-search:focus {
  border-color: var(--brand);
  box-shadow: 0 0 0 3px rgba(16, 136, 240, 0.16);
}
.desktop-only { display: inline-flex; }

.icon-btn, .chip-btn {
  border: 1px solid var(--line);
  background: rgba(255,255,255,0.03);
  border-radius: 12px;
  cursor: pointer;
}
.icon-btn {
  width: 2.5rem;
  height: 2.5rem;
  display: grid;
  place-items: center;
}
.chip-btn {
  padding: 0.55rem 0.9rem;
  font-weight: 700;
}
.chip-btn:hover, .icon-btn:hover {
  border-color: var(--line-strong);
  background: rgba(16, 136, 240, 0.12);
}

.content {
  padding: 1.25rem clamp(1rem, 2.5vw, 1.8rem) 2.5rem;
  width: min(1200px, 100%);
  margin: 0 auto;
}

.view { display: none; animation: rise 0.28s ease; }
.view.active { display: block; }
@keyframes rise {
  from { opacity: 0; transform: translateY(8px); }
  to { opacity: 1; transform: none; }
}

/* Billboard / Epic-style hero */
.billboard {
  position: relative;
  overflow: hidden;
  border-radius: 22px;
  min-height: clamp(240px, 38vw, 360px);
  border: 1px solid var(--line);
  background: #0a0d14;
  box-shadow: var(--shadow);
  margin-bottom: 1.5rem;
}
.billboard-media {
  position: absolute;
  inset: 0;
  background:
    linear-gradient(90deg, rgba(8,10,16,0.92) 18%, rgba(8,10,16,0.55) 55%, rgba(8,10,16,0.2)),
    radial-gradient(circle at 70% 40%, rgba(16,136,240,0.35), transparent 45%),
    linear-gradient(135deg, #10182a, #0a1220 50%, #071018);
  background-size: cover;
  background-position: center;
}
.billboard-body {
  position: relative;
  z-index: 1;
  max-width: 520px;
  padding: clamp(1.4rem, 4vw, 2.4rem);
}
.eyebrow {
  margin: 0 0 0.6rem;
  color: var(--aqua);
  text-transform: none;
  letter-spacing: -0.01em;
  font-size: 0.82rem;
  font-weight: 600;
}
.billboard h1, .catalog-head h2, .rail-head h2 {
  margin: 0;
  font-family: var(--font-display);
  letter-spacing: -0.03em;
  line-height: 1.12;
  font-weight: 700;
}
.billboard h1 { font-size: clamp(1.55rem, 4vw, 2.4rem); margin-bottom: 0.7rem; }
.lede, .muted { color: var(--muted); margin: 0 0 1.1rem; }
.hero-actions { display: flex; gap: 0.65rem; flex-wrap: wrap; }

.btn {
  border: 0;
  border-radius: 999px;
  padding: 0.8rem 1.2rem;
  font-weight: 700;
  cursor: pointer;
  transition: transform 0.15s ease, box-shadow 0.15s ease;
}
.btn:hover { transform: translateY(-1px); }
.btn:disabled { opacity: 0.45; cursor: not-allowed; transform: none; }
.btn.primary {
  color: #fff;
  background: linear-gradient(145deg, var(--brand), var(--brand-2));
  box-shadow: 0 12px 28px rgba(0, 104, 216, 0.35);
}
.btn.secondary {
  background: var(--panel-2);
  border: 1px solid var(--line);
}
.btn.ghost {
  background: transparent;
  border: 1px solid rgba(255,255,255,0.18);
}

.rail-head, .catalog-head {
  display: flex;
  align-items: end;
  justify-content: space-between;
  gap: 1rem;
  margin: 0.4rem 0 0.9rem;
}
.rail-head h2, .catalog-head h2 { font-size: 1.15rem; }
.text-link {
  border: 0;
  background: none;
  color: var(--brand);
  cursor: pointer;
  font-weight: 700;
}

.product-rail {
  display: grid;
  grid-auto-flow: column;
  grid-auto-columns: minmax(210px, 240px);
  gap: 0.9rem;
  overflow-x: auto;
  padding-bottom: 0.6rem;
  margin-bottom: 1.6rem;
  scroll-snap-type: x mandatory;
}
.feature-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(220px, 1fr));
  gap: 0.85rem;
}
.feature-card {
  background: linear-gradient(180deg, rgba(30,36,51,0.95), rgba(18,21,29,0.95));
  border: 1px solid var(--line);
  border-radius: var(--radius);
  padding: 1.1rem;
}
.feature-card h3 {
  margin: 0 0 0.4rem;
  font-family: var(--font-display);
  font-size: 1rem;
  letter-spacing: -0.02em;
  font-weight: 650;
}
.feature-card p { margin: 0; color: var(--muted); }

.sort-row select {
  border: 1px solid var(--line);
  background: var(--panel);
  border-radius: 12px;
  padding: 0.65rem 0.8rem;
  outline: none;
}

.product-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(220px, 1fr));
  gap: 1rem;
}

.product-card {
  scroll-snap-align: start;
  text-align: left;
  border: 1px solid var(--line);
  background: var(--panel);
  border-radius: 18px;
  overflow: hidden;
  cursor: pointer;
  padding: 0;
  color: inherit;
  transition: transform 0.18s ease, border-color 0.18s ease, box-shadow 0.18s ease;
  position: relative;
}
.product-card:hover {
  transform: translateY(-4px);
  border-color: var(--line-strong);
  box-shadow: 0 16px 36px rgba(0,0,0,0.35);
}
.product-card:disabled {
  opacity: 0.55;
  cursor: not-allowed;
  transform: none;
}
.product-card:disabled:hover {
  transform: none;
  border-color: var(--line);
  box-shadow: none;
}
.product-card:disabled:hover .art img { transform: none; }
.product-card-locked {
  filter: grayscale(0.35);
}
.ribbon-locked {
  background: linear-gradient(135deg, #64748b, #475569) !important;
  box-shadow: none !important;
}
.product-card .art {
  aspect-ratio: 16 / 10;
  background: #0a0d14;
  overflow: hidden;
}
.product-card .art img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  transition: transform 0.35s ease;
}
.product-card:hover .art img { transform: scale(1.05); }
.product-card .body { padding: 0.9rem 0.95rem 1rem; }
.product-card h3 {
  margin: 0 0 0.35rem;
  font-family: var(--font-display);
  font-size: 0.95rem;
  letter-spacing: -0.02em;
  font-weight: 650;
}
.product-meta {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 0.5rem;
}
.price-brl {
  color: #7ef0c4;
  font-weight: 800;
  font-size: 1.15rem;
}
.price-gems, .hint { color: var(--muted); font-size: 0.92rem; }
.badge, .ribbon {
  display: inline-flex;
  align-items: center;
  padding: 0.22rem 0.5rem;
  border-radius: 999px;
  background: rgba(245, 158, 11, 0.18);
  color: var(--warn);
  font-size: 0.7rem;
  font-weight: 650;
  letter-spacing: 0.01em;
}
.ribbon {
  position: absolute;
  top: 0.7rem;
  left: 0.7rem;
  z-index: 2;
}

.empty-state {
  margin-top: 2rem;
  text-align: center;
  color: var(--muted);
  padding: 2rem;
  border: 1px dashed var(--line);
  border-radius: var(--radius);
}
.hidden { display: none !important; }

.rules-list { display: grid; gap: 0.75rem; }
.rule-item {
  background: var(--panel);
  border: 1px solid var(--line);
  border-radius: var(--radius);
  padding: 1.1rem 1.15rem;
}
.rule-item h3 {
  margin: 0 0 0.35rem;
  font-family: var(--font-display);
  font-size: 1rem;
  letter-spacing: -0.02em;
  font-weight: 650;
}
.rule-item p { margin: 0; color: var(--muted); }

.toast {
  position: fixed;
  left: 50%;
  bottom: 1.2rem;
  transform: translateX(-50%);
  z-index: 80;
  background: rgba(18, 21, 29, 0.96);
  border: 1px solid var(--line-strong);
  border-radius: 999px;
  padding: 0.8rem 1.15rem;
  box-shadow: var(--shadow);
}
.toast.error { border-color: rgba(239,68,68,0.5); }
.toast.success { border-color: rgba(34,197,94,0.5); }

/* ---------- Modal storefront ---------- */
.modal {
  border: 0;
  padding: 0;
  background: transparent;
  max-width: min(980px, calc(100vw - 1rem));
  width: 100%;
}
.modal::backdrop {
  background: rgba(4, 6, 10, 0.78);
  backdrop-filter: blur(8px);
}
.modal-shell {
  position: relative;
  background: linear-gradient(180deg, #161b27, #10141d);
  border: 1px solid var(--line-strong);
  border-radius: 22px;
  overflow: hidden;
  box-shadow: var(--shadow);
}
.modal-close {
  position: absolute;
  top: 0.75rem;
  right: 0.75rem;
  z-index: 3;
  background: rgba(0,0,0,0.45);
}
.modal-layout {
  display: grid;
  grid-template-columns: 1.05fr 1.1fr;
}
.modal-media {
  position: relative;
  min-height: 320px;
  background: #090c12;
}
.modal-media img {
  width: 100%;
  height: 100%;
  object-fit: cover;
}
.modal-panel {
  padding: 1.35rem 1.3rem 1.15rem;
  display: flex;
  flex-direction: column;
  gap: 0.85rem;
  background: #121722;
  min-height: 0;
}
.modal-scroll {
  display: flex;
  flex-direction: column;
  gap: 0.85rem;
  min-height: 0;
}
.mobile-footnote { display: none; }
.desktop-footnote { display: block; }
.modal-cat {
  margin: 0;
  color: var(--aqua);
  text-transform: none;
  letter-spacing: -0.01em;
  font-size: 0.85rem;
  font-weight: 600;
}
.modal-title {
  margin: 0;
  font-family: var(--font-display);
  font-weight: 700;
  font-size: clamp(1.45rem, 3vw, 1.85rem);
  letter-spacing: -0.03em;
  color: #fff;
  line-height: 1.15;
}
.price-box {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 0.8rem;
  flex-wrap: wrap;
  padding: 0.9rem 1rem;
  border-radius: 14px;
  background: rgba(16, 136, 240, 0.1);
  border: 1px solid var(--line-strong);
}
.price-caption, .checkout-label, .info-title, .field-help {
  display: block;
  color: #c5d0e0;
  font-size: 0.92rem;
  font-weight: 600;
}
.price-caption { margin-bottom: 0.15rem; }
.price-box .price-brl {
  font-size: 1.55rem;
  line-height: 1;
}
.price-note {
  display: block;
  color: var(--muted);
  font-size: 0.88rem;
  max-width: 210px;
  text-align: right;
}
.price-box-side {
  display: grid;
  gap: 0.35rem;
  justify-items: end;
}
.info-block {
  padding: 0.75rem 0.85rem;
  border-radius: 12px;
  background: rgba(0,0,0,0.22);
  border: 1px solid var(--line);
}
.info-title { margin: 0 0 0.4rem; color: #fff; }
.benefits {
  margin: 0;
  padding-left: 1.1rem;
  color: #d7e0ee;
  max-height: 110px;
  overflow: auto;
}
.benefits li { margin-bottom: 0.2rem; }
.field-block label {
  display: flex;
  align-items: center;
  gap: 0.45rem;
  margin-bottom: 0.25rem;
  font-weight: 700;
  color: #fff;
  font-size: 1rem;
}
.optional-tag {
  font-size: 0.75rem;
  font-weight: 700;
  color: var(--muted);
  background: rgba(255,255,255,0.06);
  border-radius: 999px;
  padding: 0.12rem 0.45rem;
  text-transform: uppercase;
  letter-spacing: 0.04em;
}
.field-help {
  margin: 0 0 0.45rem;
  color: var(--muted);
  font-weight: 500;
}
.field-block input {
  width: 100%;
  border: 1px solid var(--line);
  background: rgba(0,0,0,0.28);
  border-radius: 12px;
  padding: 0.8rem 0.9rem;
  outline: none;
  font-size: 1.05rem;
}
.field-block input:focus {
  border-color: var(--brand);
  box-shadow: 0 0 0 3px rgba(16,136,240,0.16);
}
.inline-fields {
  display: grid;
  grid-template-columns: 1fr auto;
  gap: 0.55rem;
}
.inline-fields .btn.secondary {
  white-space: nowrap;
  padding-inline: 1rem;
  min-height: 48px;
}
.status-hint.ok { color: var(--ok); font-weight: 700; }
.status-hint.err { color: #ff8e8e; font-weight: 700; }
.hint { color: var(--muted); font-size: 0.92rem; margin: 0.4rem 0 0; }
.choice-list {
  display: grid;
  gap: 0.4rem;
  max-height: 150px;
  overflow: auto;
}
.choice-item {
  display: flex;
  gap: 0.55rem;
  align-items: center;
  padding: 0.55rem 0.65rem;
  border-radius: 10px;
  background: rgba(0,0,0,0.22);
  border: 1px solid var(--line);
}
.checkout-bar {
  margin-top: 0.2rem;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 0.8rem;
  padding: 0.95rem 0 0;
  border-top: 1px solid var(--line);
}
.checkout-bar strong {
  display: block;
  font-size: 1.45rem;
  color: #7ef0c4;
  margin-top: 0.1rem;
}
.checkout-bar .btn.primary {
  min-width: 180px;
  min-height: 48px;
  font-size: 1.05rem;
}
.pay-hint {
  display: none;
  margin: 0.15rem 0 0;
  font-size: 0.88rem;
  color: #b7c4d8 !important;
  text-align: left;
  line-height: 1.35;
}
.pay-hint.visible {
  display: block;
}

/* Status page */
.status-page {
  min-height: 100vh;
  min-height: 100dvh;
  display: grid;
  place-items: center;
  padding: 1.5rem;
  padding-bottom: calc(1.5rem + var(--safe-bottom));
}
.status-card {
  width: min(460px, 100%);
  background: var(--panel);
  border: 1px solid var(--line);
  border-radius: 22px;
  padding: 2rem 1.4rem;
  text-align: center;
  box-shadow: var(--shadow);
}
.status-card h1 {
  font-family: var(--font-display);
  font-size: 1.45rem;
  letter-spacing: -0.03em;
  font-weight: 700;
  margin: 0 0 0.6rem;
}
.status-pill {
  display: inline-flex;
  margin: 0.5rem 0 1rem;
  padding: 0.35rem 0.75rem;
  border-radius: 999px;
  background: rgba(16,136,240,0.16);
  font-weight: 600;
}
.status-pill.ok { background: rgba(34,197,94,0.16); color: var(--ok); }
.status-pill.wait { background: rgba(245,158,11,0.16); color: var(--warn); }
.status-pill.fail { background: rgba(239,68,68,0.16); color: var(--danger); }

/* ---------- Category chips (mobile primary) ---------- */
.mobile-filters {
  display: none;
  gap: 0.55rem;
  margin: 0 0 1rem;
}
.chip-rail {
  display: flex;
  gap: 0.5rem;
  overflow-x: auto;
  padding: 0.15rem 0 0.35rem;
  scroll-snap-type: x proximity;
  -webkit-overflow-scrolling: touch;
}
.chip-rail::-webkit-scrollbar { height: 0; }
.filter-chip {
  flex: 0 0 auto;
  scroll-snap-align: start;
  border: 1px solid var(--line);
  background: rgba(255,255,255,0.03);
  color: var(--muted);
  border-radius: 999px;
  padding: 0.65rem 0.95rem;
  min-height: 44px;
  font-weight: 600;
  font-size: 0.92rem;
  cursor: pointer;
  white-space: nowrap;
}
.filter-chip.active {
  color: #fff;
  background: rgba(16, 136, 240, 0.28);
  border-color: var(--line-strong);
}
.chip-rail-sub .filter-chip {
  background: transparent;
  border-style: dashed;
}

/* ---------- Bottom nav (mobile) ---------- */
.bottom-nav {
  display: none;
  position: fixed;
  left: 0;
  right: 0;
  bottom: 0;
  z-index: 45;
  grid-template-columns: repeat(4, 1fr);
  gap: 0.15rem;
  padding: 0.35rem 0.4rem calc(0.35rem + var(--safe-bottom));
  background: #0a0c12;
  background: rgba(10, 12, 18, 0.98);
  -webkit-backdrop-filter: blur(18px);
  backdrop-filter: blur(18px);
  border-top: 1px solid var(--line);
}
.bottom-nav-item {
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: 0.15rem;
  min-height: 52px;
  border: 0;
  background: transparent;
  color: var(--muted);
  font-size: 0.68rem;
  font-weight: 600;
  letter-spacing: -0.01em;
  cursor: pointer;
  border-radius: 12px;
  padding: 0.35rem 0.2rem;
}
.bottom-nav-item .bn-ico {
  font-size: 1.15rem;
  line-height: 1;
}
.bottom-nav-item.active {
  color: #fff;
  background: rgba(16, 136, 240, 0.16);
}

/* ---------- Mobile ---------- */
@media (max-width: 980px) {
  :root { --bottom-nav-h: 64px; }

  .app-shell { grid-template-columns: 1fr; }
  .sidebar {
    position: fixed;
    left: 0;
    top: 0;
    width: min(88vw, 340px);
    height: 100dvh;
    padding-top: calc(1rem + var(--safe-top));
    padding-bottom: calc(1.2rem + var(--safe-bottom));
    transform: translateX(-105%);
    transition: transform 0.22s ease;
    box-shadow: var(--shadow);
    z-index: 50;
  }
  body.sidebar-open .sidebar { transform: translateX(0); }
  body.sidebar-open .sidebar-backdrop { display: block; }
  .sidebar-close, .menu-toggle { display: grid; }
  .menu-toggle, .sidebar-close, .icon-btn {
    min-width: 44px;
    min-height: 44px;
  }

  .desktop-only { display: none !important; }
  .mobile-search { display: block; }
  .mobile-filters { display: grid; }
  .bottom-nav { display: grid; }

  .content {
    padding: 1rem 0.9rem calc(2rem + var(--bottom-nav-h) + var(--safe-bottom));
  }

  .billboard {
    min-height: 220px;
    border-radius: 18px;
    margin-bottom: 1.1rem;
  }
  .billboard-body {
    max-width: none;
    padding: 1.15rem 1.1rem 1.25rem;
  }
  .hero-actions {
    flex-direction: column;
    align-items: stretch;
  }
  .hero-actions .btn {
    width: 100%;
    min-height: 48px;
    text-align: center;
    justify-content: center;
  }

  .product-rail {
    grid-auto-columns: minmax(72vw, 260px);
    gap: 0.75rem;
    margin-bottom: 1.2rem;
    padding-bottom: 0.4rem;
  }
  .product-grid {
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 0.75rem;
  }
  .product-card .body { padding: 0.75rem 0.8rem 0.85rem; }
  .product-card h3 { font-size: 0.9rem; }
  .price-brl { font-size: 1rem; }

  .catalog-head {
    flex-direction: column;
    align-items: stretch;
  }
  .sort-row select {
    width: 100%;
    min-height: 48px;
    font-size: 1rem;
  }

  .toast {
    bottom: calc(var(--bottom-nav-h) + var(--safe-bottom) + 0.85rem);
    max-width: calc(100vw - 1.5rem);
    text-align: center;
  }

  /* Modal = fullscreen sheet */
  .modal {
    max-width: 100vw;
    width: 100vw;
    height: 100dvh;
    max-height: 100dvh;
    margin: 0;
    padding: 0;
    border: 0;
    overflow: hidden;
  }
  .modal-shell {
    height: 100dvh;
    max-height: 100dvh;
    border-radius: 0;
    border: 0;
    display: flex;
    flex-direction: column;
    overflow: hidden;
  }
  .modal-layout {
    grid-template-columns: 1fr;
    flex: 1 1 auto;
    min-height: 0;
    height: 100%;
    display: grid;
    grid-template-rows: minmax(140px, 28vw) minmax(0, 1fr);
    overflow: hidden;
  }
  .modal-media {
    min-height: 140px;
    max-height: none;
    height: 100%;
  }
  .modal-close {
    top: calc(0.65rem + var(--safe-top));
    right: 0.75rem;
    width: 44px;
    height: 44px;
  }
  .modal-panel {
    padding: 0;
    min-height: 0;
    height: 100%;
    max-height: 100%;
    display: flex;
    flex-direction: column;
    gap: 0;
    overflow: hidden;
  }
  .modal-scroll {
    flex: 1 1 auto;
    min-height: 0;
    overflow: auto;
    -webkit-overflow-scrolling: touch;
    padding: 1rem 1rem 1.1rem;
    gap: 0.9rem;
    overscroll-behavior: contain;
  }
  .desktop-footnote { display: none; }
  .mobile-footnote {
    display: none;
  }
  .checkout-bar {
    position: relative;
    flex: 0 0 auto;
    z-index: 6;
    margin: 0;
    flex-direction: column;
    align-items: stretch;
    gap: 0.55rem;
    padding: 0.85rem 1rem calc(0.85rem + var(--safe-bottom));
    border-top: 1px solid var(--line);
    background: rgba(12, 16, 24, 0.98);
    backdrop-filter: blur(12px);
    box-shadow: 0 -10px 30px rgba(0,0,0,0.35);
  }
  .checkout-bar .btn,
  .checkout-bar .btn.primary {
    width: 100%;
    min-height: 52px;
    font-size: 1.05rem;
  }
  .pay-hint {
    text-align: center;
  }
  .inline-fields {
    grid-template-columns: 1fr;
  }
  .inline-fields .btn.secondary {
    width: 100%;
    min-height: 48px;
  }
  .field-block input {
    min-height: 48px;
    font-size: 16px; /* evita zoom iOS */
  }
  .nav-item, .cat-item {
    min-height: 48px;
  }
}

@media (max-width: 400px) {
  .product-grid {
    grid-template-columns: 1fr;
  }
  .product-rail {
    grid-auto-columns: minmax(78vw, 280px);
  }
}

@media (max-width: 560px) {
  .content { padding-left: 0.8rem; padding-right: 0.8rem; }
  .vehicle-choice-grid { grid-template-columns: repeat(2, minmax(0, 1fr)); max-height: 360px; }
  .status-page {
    padding: 1.1rem 1rem calc(1.5rem + var(--safe-bottom));
  }
}

/* ---------- Modal contrast fix (texto preto ilegível) ---------- */
.modal,
.modal-shell,
.modal-panel {
  color: #f5f7fa !important;
}
.modal-title,
.field-block label,
.info-title {
  color: #ffffff !important;
}
.modal-cat { color: #5fd4ef !important; }
.price-caption,
.checkout-label,
.field-help,
.price-note,
.hint,
.checkout-footnote,
.optional-tag {
  color: #b7c4d8 !important;
}
.benefits,
.benefits li,
.choice-item {
  color: #e4ebf5 !important;
}
.price-box .price-brl,
.checkout-bar strong {
  color: #7ef0c4 !important;
}
.status-hint.ok { color: #3ddc84 !important; }
.status-hint.err { color: #ff8e8e !important; }

.modal-panel input,
.modal-panel textarea,
.modal-panel select,
.field-block input {
  color: #f5f7fa !important;
  -webkit-text-fill-color: #f5f7fa !important;
  caret-color: #f5f7fa !important;
  background: #0c111b !important;
  border-color: rgba(61, 160, 245, 0.28) !important;
}
.modal-panel input::placeholder,
.field-block input::placeholder {
  color: #8b9bb3 !important;
  -webkit-text-fill-color: #8b9bb3 !important;
  opacity: 1 !important;
}
.modal-panel input:-webkit-autofill,
.modal-panel input:-webkit-autofill:focus,
.field-block input:-webkit-autofill {
  -webkit-text-fill-color: #f5f7fa !important;
  caret-color: #f5f7fa !important;
  box-shadow: 0 0 0 1000px #0c111b inset !important;
}
.modal-panel .btn,
.modal-panel .btn.secondary,
.modal-panel .btn.primary,
.inline-fields .btn.secondary {
  color: #ffffff !important;
}
.modal-close {
  color: #ffffff !important;
}
.sidebar-search input {
  color: #f5f7fa !important;
  -webkit-text-fill-color: #f5f7fa !important;
  background: #0c111b !important;
}
.sidebar-search input::placeholder {
  color: #8b9bb3 !important;
  -webkit-text-fill-color: #8b9bb3 !important;
}
.sort-row select {
  color: #f5f7fa !important;
  background: #171b26 !important;
}

/* ---------- Vehicle multichoice (foto + VehicleName) ---------- */
.vehicle-choice-section {
  display: grid;
  gap: 0.55rem;
}
.vehicle-choice-head {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 0.6rem;
}
.vehicle-choice-head p {
  margin: 0;
  color: #fff !important;
  font-weight: 700;
}
.vehicle-choice-head span {
  color: #9aa8bf !important;
  font-size: 0.85rem;
  font-weight: 700;
}
.vehicle-choice-head span.ok { color: #3ddc84 !important; }
.vehicle-choice-grid {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 0.65rem;
  max-height: 280px;
  overflow: auto;
  padding-right: 0.15rem;
}
.vehicle-choice-card {
  position: relative;
  display: grid;
  gap: 0.45rem;
  text-align: left;
  border: 1px solid rgba(61, 160, 245, 0.22);
  background: linear-gradient(180deg, #151b28, #0f141f);
  border-radius: 14px;
  padding: 0.55rem;
  cursor: pointer;
  color: #f5f7fa !important;
  transition: transform 0.15s ease, border-color 0.15s ease, box-shadow 0.15s ease;
}
.vehicle-choice-card:hover {
  transform: translateY(-2px);
  border-color: rgba(16, 136, 240, 0.55);
}
.vehicle-choice-card.selected {
  border-color: #1088f0;
  box-shadow: 0 0 0 1px rgba(16, 136, 240, 0.45), 0 10px 24px rgba(0, 104, 216, 0.2);
  background: linear-gradient(180deg, rgba(16, 136, 240, 0.18), #101621);
}
.vehicle-choice-art {
  height: 84px;
  border-radius: 10px;
  background:
    radial-gradient(circle at 50% 30%, rgba(16,136,240,0.18), transparent 55%),
    #0a0e16;
  display: grid;
  place-items: center;
  overflow: hidden;
}
.vehicle-choice-art img {
  width: 100%;
  height: 100%;
  object-fit: contain;
  padding: 0.25rem;
}
.vehicle-choice-art.no-img,
.vehicle-choice-fallback {
  color: #7a8ba8;
  font-size: 1.6rem;
}
.vehicle-choice-meta strong {
  display: block;
  color: #ffffff !important;
  font-size: 0.95rem;
  font-weight: 700;
  line-height: 1.15;
}
.vehicle-choice-meta small {
  display: block;
  margin-top: 0.15rem;
  color: #8b9bb3 !important;
  font-size: 0.78rem;
}
.vehicle-choice-check {
  position: absolute;
  top: 0.45rem;
  right: 0.45rem;
  width: 1.35rem;
  height: 1.35rem;
  border-radius: 999px;
  display: grid;
  place-items: center;
  font-size: 0.75rem;
  font-weight: 800;
  color: #fff;
  background: rgba(255,255,255,0.08);
  opacity: 0;
}
.vehicle-choice-card.selected .vehicle-choice-check {
  opacity: 1;
  background: #1088f0;
}
#choiceList.choice-list {
  max-height: none;
  overflow: visible;
}
@media (max-width: 560px) {
  .vehicle-choice-grid {
    grid-template-columns: repeat(2, minmax(0, 1fr));
    max-height: 360px;
    gap: 0.55rem;
  }
  .vehicle-choice-card {
    min-height: 0;
  }
  .vehicle-choice-art {
    min-height: 72px;
  }
}
