/* ============================================================
   J&R STORY — Estilos premium v3 (Mobile-First, tema claro/escuro)
   Identidade: dark futurista + neon suave (violeta/ciano)
   ------------------------------------------------------------
   Organização:
   01. Tokens          06. Botões / Forms      11. Página do anúncio
   02. Reset / Base    07. Painéis / Listas    12. Página do vendedor
   03. Splash          08. Perfil              13. Overlays (drawer/sheet/modal)
   04. Topbar / Nav    09. Cards / Grids       14. Feedback (toast/empty/skeleton)
   05. Animações       10. Chips / Banners     15. Responsividade / A11y
   ============================================================ */

/* ---------- 01. Tokens ---------- */
:root {
  --font-display: 'Sora', system-ui, sans-serif;
  --font-body: 'Inter', system-ui, sans-serif;

  --radius-sm: 12px;
  --radius: 18px;
  --radius-lg: 26px;
  --radius-full: 999px;

  /* Escala de espaçamento consistente */
  --sp-1: 4px;
  --sp-2: 8px;
  --sp-3: 12px;
  --sp-4: 16px;
  --sp-5: 20px;
  --sp-6: 24px;
  --sp-8: 32px;

  /* Padding lateral fluido: 14px no mobile, cresce suave até 24px */
  --pad-x: clamp(14px, 3.5vw, 24px);

  --gap: 14px;
  --topbar-h: 62px;
  --bottomnav-h: 66px;

  --ease: cubic-bezier(0.22, 1, 0.36, 1);
  --ease-bounce: cubic-bezier(0.34, 1.56, 0.64, 1);
  --dur: 0.28s;
  --dur-fast: 0.16s;
}

/* Tema escuro (padrão): preto profundo + neon violeta/ciano — futurista */
[data-theme='dark'] {
  color-scheme: dark;
  --bg: #05070f;
  --bg-2: #090c18;
  --surface: #0d1124;
  --surface-2: #131936;
  --surface-3: #1a2148;
  --border: #232c5c;
  --border-soft: #1a2148;
  --text: #f0f3ff;
  --text-dim: #9ba5cf;
  --text-mute: #6b74a3;

  --primary: #1e3a8a;
  --primary-bright: #3b5df0;
  --secondary: #b794f6;
  --secondary-soft: #c9b4fb;
  --neon: #22d3ee;

  --accent-grad: linear-gradient(135deg, #3b5df0 0%, #7c5cf0 50%, #b794f6 100%);
  --hero-grad: radial-gradient(120% 90% at 50% 0%, rgba(124, 92, 240, 0.16) 0%, transparent 60%);
  --card: #0e1329;
  --glass: rgba(13, 17, 36, 0.72);
  --shadow: 0 12px 34px -14px rgba(0, 0, 0, 0.75);
  --shadow-soft: 0 8px 26px -10px rgba(93, 82, 240, 0.55);
  --glow: 0 0 0 1px rgba(124, 92, 240, 0.25), 0 8px 30px -8px rgba(124, 92, 240, 0.5);
  --danger: #f4587a;
  --success: #34d399;
  --warning: #fbbf24;
  --online: #22c55e;
  --offline: #6b74a3;
}

/* Tema claro: fundo branco, roxo escuro, azul claro */
[data-theme='light'] {
  color-scheme: light;
  --bg: #f4f5fb;
  --bg-2: #ffffff;
  --surface: #ffffff;
  --surface-2: #f5f4ff;
  --surface-3: #ecebff;
  --border: #e3e2f2;
  --border-soft: #edecf8;
  --text: #171633;
  --text-dim: #565477;
  --text-mute: #8b89a8;

  --primary: #4c1d95;
  --primary-bright: #6d28d9;
  --secondary: #38bdf8;
  --secondary-soft: #7dd3fc;
  --neon: #0ea5e9;

  --accent-grad: linear-gradient(135deg, #6d28d9 0%, #7c3aed 45%, #38bdf8 100%);
  --hero-grad: radial-gradient(120% 90% at 50% 0%, rgba(124, 58, 237, 0.10) 0%, transparent 60%);
  --card: #ffffff;
  --glass: rgba(255, 255, 255, 0.78);
  --shadow: 0 14px 34px -18px rgba(76, 29, 149, 0.35);
  --shadow-soft: 0 8px 24px -12px rgba(56, 189, 248, 0.45);
  --glow: 0 0 0 1px rgba(124, 58, 237, 0.18), 0 8px 26px -10px rgba(124, 58, 237, 0.35);
  --danger: #e11d48;
  --success: #059669;
  --warning: #d97706;
  --online: #16a34a;
  --offline: #8b89a8;
}

/* ---------- 02. Reset / Base ---------- */
* { margin: 0; padding: 0; box-sizing: border-box; -webkit-tap-highlight-color: transparent; }
html, body { height: 100%; }
html { scroll-behavior: smooth; }
body {
  font-family: var(--font-body);
  background: var(--bg);
  background-image: var(--hero-grad);
  background-repeat: no-repeat;
  color: var(--text);
  line-height: 1.5;
  overflow-x: hidden;
  -webkit-font-smoothing: antialiased;
  text-rendering: optimizeLegibility;
  transition: background var(--dur) var(--ease), color var(--dur) var(--ease);
}

/* CORREÇÃO: links nunca herdam o sublinhado padrão do navegador.
   Era isso que fazia chips, categorias, "Ver todas" e itens de menu
   parecerem links sublinhados. A cor também é herdada — cada
   componente define a sua. */
a { color: inherit; text-decoration: none; }
a:hover, a:focus, a:active, a:visited { text-decoration: none; }

svg { width: 22px; height: 22px; fill: none; stroke: currentColor; stroke-width: 2; stroke-linecap: round; stroke-linejoin: round; flex-shrink: 0; }
input, button, textarea, select { font-family: inherit; font-size: inherit; color: inherit; }
button { cursor: pointer; border: none; background: none; text-align: inherit; }
img { max-width: 100%; display: block; }
.hidden { display: none !important; }

::selection { background: color-mix(in srgb, var(--secondary) 35%, transparent); }

/* Scrollbar discreto (desktop) */
::-webkit-scrollbar { width: 10px; height: 10px; }
::-webkit-scrollbar-track { background: transparent; }
::-webkit-scrollbar-thumb { background: var(--surface-3); border-radius: 8px; border: 2px solid var(--bg); }
::-webkit-scrollbar-thumb:hover { background: var(--border); }

/* Foco visível consistente (teclado) — nunca some, nunca “gruda” no toque */
:focus { outline: none; }
:focus-visible {
  outline: 2px solid var(--secondary);
  outline-offset: 2px;
  border-radius: 6px;
}

/* ---------- 03. Splash (animação de entrada do site) ---------- */
.splash {
  position: fixed; inset: 0; z-index: 100;
  display: flex; flex-direction: column; align-items: center; justify-content: center; gap: 22px;
  background: radial-gradient(circle at 50% 30%, var(--bg-2), var(--bg));
  transition: opacity 0.45s var(--ease), visibility 0.45s;
}
.splash.leaving { opacity: 0; visibility: hidden; pointer-events: none; }
.splash__logo {
  width: 96px; height: 96px; border-radius: 26px;
  display: grid; place-items: center; overflow: hidden;
  font-family: var(--font-display); font-weight: 800; font-size: 27px; color: #fff;
  background: var(--accent-grad);
  box-shadow: var(--glow);
  animation: pop 0.55s var(--ease-bounce), float 2.6s var(--ease) 0.55s infinite alternate;
}
.splash__logo img { width: 100%; height: 100%; object-fit: cover; }
.splash__brand {
  font-family: var(--font-display); font-weight: 800; font-size: 20px; letter-spacing: 3px;
  background: var(--accent-grad); -webkit-background-clip: text; background-clip: text; color: transparent;
  animation: fadeUp 0.6s var(--ease) 0.15s both;
}
.splash__spinner {
  width: 30px; height: 30px; border-radius: 50%;
  border: 3px solid var(--surface-3); border-top-color: var(--secondary);
  animation: spin 0.8s linear infinite;
}

/* ---------- 04. Topbar ---------- */
.topbar {
  position: fixed; top: 0; left: 0; right: 0; z-index: 40; height: var(--topbar-h);
  display: flex; align-items: center; gap: 8px; padding: 8px var(--pad-x);
  padding-top: max(8px, env(safe-area-inset-top));
  background: var(--glass);
  backdrop-filter: blur(16px); -webkit-backdrop-filter: blur(16px);
  border-bottom: 1px solid var(--border-soft);
}
.topbar.search-mode .notif-btn { display: none; }

.icon-btn {
  width: 42px; height: 42px; flex: 0 0 auto; border-radius: var(--radius-sm);
  display: grid; place-items: center; color: var(--text); text-align: center;
  transition: background var(--dur-fast) var(--ease), transform var(--dur-fast) var(--ease), color var(--dur-fast);
}
.icon-btn:active { transform: scale(0.9); background: var(--surface-2); }

.search-wrap { flex: 1; display: flex; align-items: center; gap: 6px; min-width: 0; }
.search-box {
  flex: 1; display: flex; align-items: center; gap: 8px; height: 44px; padding: 0 14px; min-width: 0;
  background: var(--surface-2); border: 1px solid var(--border); border-radius: var(--radius-full);
  transition: border-color var(--dur), box-shadow var(--dur), background var(--dur);
}
.search-box:focus-within {
  border-color: var(--secondary);
  box-shadow: 0 0 0 3px color-mix(in srgb, var(--secondary) 22%, transparent);
  background: var(--surface);
}
.search-ic { width: 18px; height: 18px; color: var(--text-mute); }
.search-box input { flex: 1; min-width: 0; background: none; border: none; outline: none; font-size: 15px; }
.search-box input::placeholder { color: var(--text-mute); }
.search-box input::-webkit-search-cancel-button { -webkit-appearance: none; }

.notif-btn { position: relative; }
.notif-dot {
  position: absolute; top: 8px; right: 9px; width: 10px; height: 10px; border-radius: 50%;
  background: var(--danger); border: 2px solid var(--bg-2);
  animation: pop 0.3s var(--ease-bounce);
}

/* ---------- Container do app ---------- */
.app {
  min-height: 100vh;
  min-height: 100dvh;
  padding-top: calc(var(--topbar-h) + 8px);
  padding-bottom: calc(var(--bottomnav-h) + 24px + env(safe-area-inset-bottom));
  max-width: 720px; margin: 0 auto;
  animation: pageIn 0.4s var(--ease);
}
.app.no-top { padding-top: max(10px, env(safe-area-inset-top)); }
.app.no-bottom { padding-bottom: 28px; }

.section { padding: 4px var(--pad-x) 8px; }
.section-title {
  font-family: var(--font-display); font-weight: 700;
  font-size: clamp(17px, 2.4vw, 19px); letter-spacing: -0.2px;
  display: flex; align-items: center; justify-content: space-between; gap: 10px;
  margin: 20px 0 12px;
}
.section-title .link {
  font-family: var(--font-body); font-size: 13px; color: var(--secondary); font-weight: 600;
  display: inline-flex; align-items: center; gap: 4px; padding: 4px 8px; margin: -4px -8px;
  border-radius: var(--radius-sm);
  transition: background var(--dur-fast), color var(--dur-fast);
}
.section-title .link:active { background: var(--surface-2); }
.section-title .accent {
  background: var(--accent-grad); -webkit-background-clip: text; background-clip: text; color: transparent;
}

/* ---------- Barra inferior de navegação ---------- */
.bottomnav {
  position: fixed; bottom: 0; left: 0; right: 0; z-index: 40; height: calc(var(--bottomnav-h) + env(safe-area-inset-bottom));
  padding-bottom: env(safe-area-inset-bottom);
  display: flex; align-items: stretch;
  background: var(--glass);
  backdrop-filter: blur(18px); -webkit-backdrop-filter: blur(18px);
  border-top: 1px solid var(--border-soft);
}
.bottomnav a {
  flex: 1; display: flex; flex-direction: column; align-items: center; justify-content: center; gap: 3px;
  color: var(--text-mute); font-size: 11px; font-weight: 600; position: relative;
  transition: color var(--dur) var(--ease), transform var(--dur-fast) var(--ease);
}
.bottomnav a.active { color: var(--secondary); }
.bottomnav a.active::before {
  content: ''; position: absolute; top: 0; width: 30px; height: 3px; border-radius: 0 0 4px 4px;
  background: var(--accent-grad);
  animation: navIn 0.3s var(--ease);
}
.bottomnav a.active svg { transform: translateY(-1px); }
.bottomnav a svg { width: 24px; height: 24px; transition: transform var(--dur) var(--ease); }
.bottomnav a:active { transform: scale(0.94); }

/* ---------- 05. Animações ---------- */
@keyframes pageIn  { from { opacity: 0; transform: translateY(10px); } }
@keyframes fadeUp  { from { opacity: 0; transform: translateY(8px); } }
@keyframes fadeIn  { from { opacity: 0; } }
@keyframes cardIn  { from { opacity: 0; transform: translateY(12px) scale(0.98); } }
@keyframes navIn   { from { transform: scaleX(0); } }
@keyframes pop     { from { transform: scale(0.6); opacity: 0; } }
@keyframes float   { to { transform: translateY(-6px); } }
@keyframes spin    { to { transform: rotate(360deg); } }
@keyframes shimmer { to { background-position: -200% 0; } }
@keyframes pulseDot {
  0%   { box-shadow: 0 0 0 0 color-mix(in srgb, var(--online) 55%, transparent); }
  70%  { box-shadow: 0 0 0 7px transparent; }
  100% { box-shadow: 0 0 0 0 transparent; }
}

/* ---------- 09. Cards / Grids ---------- */
.grid {
  display: grid; grid-template-columns: repeat(2, 1fr); gap: var(--gap); padding: 4px var(--pad-x);
}
.card {
  background: var(--card); border: 1px solid var(--border-soft); border-radius: var(--radius);
  overflow: hidden; box-shadow: var(--shadow); color: inherit;
  display: flex; flex-direction: column;
  transition: transform 0.2s var(--ease), box-shadow var(--dur), border-color var(--dur);
  animation: cardIn 0.45s var(--ease) both;
}
/* Entrada em cascata sutil */
.grid .card:nth-child(2), .hscroll .card:nth-child(2) { animation-delay: 0.05s; }
.grid .card:nth-child(3), .hscroll .card:nth-child(3) { animation-delay: 0.10s; }
.grid .card:nth-child(4), .hscroll .card:nth-child(4) { animation-delay: 0.15s; }
.grid .card:nth-child(5), .hscroll .card:nth-child(5) { animation-delay: 0.20s; }
.grid .card:nth-child(6), .hscroll .card:nth-child(6) { animation-delay: 0.25s; }
.grid .card:nth-child(n+7) { animation-delay: 0.3s; }

.card:active { transform: scale(0.97); }
@media (hover: hover) {
  .card:hover { transform: translateY(-4px); box-shadow: var(--glow); border-color: color-mix(in srgb, var(--secondary) 45%, var(--border)); }
  .card:hover .card__media img { transform: scale(1.06); }
}
.card__media { position: relative; aspect-ratio: 4/3; background: var(--surface-2); overflow: hidden; }
.card__media img { width: 100%; height: 100%; object-fit: cover; transition: transform 0.5s var(--ease); }
.card__media .noimg { width: 100%; height: 100%; display: grid; place-items: center; color: var(--text-mute); background: var(--surface-3); }
.card__badge {
  position: absolute; top: 8px; left: 8px; padding: 4px 9px; border-radius: var(--radius-full);
  font-size: 10.5px; font-weight: 700; color: #fff; background: var(--danger);
  box-shadow: 0 4px 10px -3px rgba(0,0,0,.4); letter-spacing: 0.2px;
}
.card__badge.feat { background: var(--accent-grad); left: auto; right: 8px; }
.card__wish {
  position: absolute; bottom: 8px; right: 8px; width: 34px; height: 34px; border-radius: 50%;
  display: grid; place-items: center; background: color-mix(in srgb, var(--bg) 55%, transparent);
  backdrop-filter: blur(6px); color: #fff;
  transition: transform var(--dur-fast) var(--ease-bounce);
}
.card__wish:active { transform: scale(1.2); }
.card__wish.on { color: var(--danger); }
.card__wish svg { width: 18px; height: 18px; fill: none; }
.card__wish.on svg { fill: var(--danger); }
.card__body { padding: 11px 12px 13px; display: flex; flex-direction: column; gap: 4px; flex: 1; }
.card__title {
  font-size: 13.5px; font-weight: 600; line-height: 1.35;
  display: -webkit-box; -webkit-line-clamp: 2; -webkit-box-orient: vertical; overflow: hidden;
  min-height: calc(2 * 1.35em); /* altura estável: cards sempre alinhados */
}
.card__price { margin-top: auto; display: flex; flex-direction: column; padding-top: 4px; }
.card__from { font-size: 11px; color: var(--text-mute); text-decoration: line-through; }
.card__now { font-family: var(--font-display); font-weight: 700; font-size: 16px; color: var(--text); letter-spacing: -0.2px; }
.card__now.promo { color: var(--secondary); }

/* Carrossel horizontal para destaques */
.hscroll {
  display: flex; gap: var(--gap); overflow-x: auto; padding: 4px var(--pad-x) 12px;
  scrollbar-width: none; scroll-snap-type: x mandatory; scroll-padding-left: var(--pad-x);
}
.hscroll::-webkit-scrollbar { display: none; }
.hscroll .card { flex: 0 0 46%; max-width: 240px; scroll-snap-align: start; }

/* ---------- 10. Chips / Banners ---------- */
.chips { display: flex; gap: 9px; overflow-x: auto; padding: 6px var(--pad-x) 12px; scrollbar-width: none; scroll-padding-left: var(--pad-x); }
.chips::-webkit-scrollbar { display: none; }
.chip {
  flex: 0 0 auto; display: inline-flex; align-items: center; justify-content: center;
  padding: 9px 16px; border-radius: var(--radius-full);
  background: var(--surface-2); border: 1px solid var(--border); color: var(--text-dim);
  font-size: 13px; font-weight: 600; white-space: nowrap;
  transition: background var(--dur) var(--ease), color var(--dur), border-color var(--dur), transform var(--dur-fast) var(--ease), box-shadow var(--dur);
}
.chip.active { background: var(--accent-grad); color: #fff; border-color: transparent; box-shadow: var(--shadow-soft); }
.chip:active { transform: scale(0.94); }

.banners {
  display: flex; gap: var(--gap); overflow-x: auto; padding: 6px var(--pad-x) 10px;
  scroll-snap-type: x mandatory; scrollbar-width: none; scroll-padding-left: var(--pad-x);
}
.banners::-webkit-scrollbar { display: none; }
.banner {
  flex: 0 0 86%; scroll-snap-align: center; aspect-ratio: 16/8; border-radius: var(--radius);
  overflow: hidden; background: var(--surface-2); box-shadow: var(--shadow); position: relative;
  border: 1px solid var(--border-soft);
  animation: cardIn 0.5s var(--ease) both;
}
.banner img { width: 100%; height: 100%; object-fit: cover; }
.banner--placeholder {
  display: grid; place-items: center;
  background: var(--accent-grad); color: #fff; text-align: center; padding: 16px;
}
.banner--placeholder small { opacity: 0.85; font-weight: 500; }

/* ---------- Barra de confiança (home) ---------- */
.trustbar {
  display: grid; grid-template-columns: repeat(3, 1fr); gap: 10px; padding: 10px var(--pad-x) 2px;
}
.trust-item {
  display: flex; flex-direction: column; align-items: center; gap: 6px; text-align: center;
  background: color-mix(in srgb, var(--surface) 80%, transparent);
  border: 1px solid var(--border-soft); border-radius: var(--radius);
  padding: 13px 8px; backdrop-filter: blur(8px);
  animation: fadeUp 0.5s var(--ease) both;
}
.trust-item:nth-child(2) { animation-delay: 0.07s; }
.trust-item:nth-child(3) { animation-delay: 0.14s; }
.trust-item svg { width: 20px; height: 20px; color: var(--neon, var(--secondary)); }
.trust-item b { font-size: 11.5px; font-weight: 700; }
.trust-item span { font-size: 10px; color: var(--text-mute); line-height: 1.25; }

/* ---------- 06. Botões ---------- */
.btn {
  display: inline-flex; align-items: center; justify-content: center; gap: 8px;
  height: 50px; padding: 0 20px; border-radius: var(--radius); font-weight: 700; font-size: 15px;
  width: 100%; text-align: center; user-select: none;
  transition: transform var(--dur-fast) var(--ease), filter var(--dur), box-shadow var(--dur), background var(--dur), opacity var(--dur);
}
.btn:active { transform: scale(0.97); }
.btn--primary { background: var(--accent-grad); color: #fff; box-shadow: var(--shadow-soft); position: relative; overflow: hidden; }
.btn--primary::after {
  content: ''; position: absolute; inset: 0;
  background: linear-gradient(110deg, transparent 30%, rgba(255,255,255,0.25) 50%, transparent 70%);
  transform: translateX(-100%); transition: transform 0.6s var(--ease);
}
.btn--primary:hover::after, .btn--primary:focus-visible::after { transform: translateX(100%); }
.btn--primary:hover { box-shadow: var(--glow); }
.btn--primary:active { filter: brightness(1.05); }
.btn--ghost { background: var(--surface-2); color: var(--text); border: 1px solid var(--border); }
.btn--ghost:hover { border-color: color-mix(in srgb, var(--secondary) 40%, var(--border)); }
.btn--outline { background: transparent; color: var(--secondary); border: 1.5px solid var(--secondary); }
.btn--outline:hover { background: color-mix(in srgb, var(--secondary) 10%, transparent); }
.btn--wa { background: #25d366; color: #062b17; }
.btn--wa:hover { filter: brightness(1.05); }
.btn--danger { background: color-mix(in srgb, var(--danger) 16%, transparent); color: var(--danger); }
.btn--danger:hover { background: color-mix(in srgb, var(--danger) 24%, transparent); }
.btn--sm { height: 40px; font-size: 13.5px; border-radius: var(--radius-sm); }
.btn--auto { width: auto; }
.btn svg { width: 20px; height: 20px; }
.btn:disabled { opacity: 0.55; pointer-events: none; filter: saturate(0.6); }

/* ---------- 06b. Formulários ---------- */
.field { margin-bottom: 14px; }
.field label { display: block; font-size: 13px; font-weight: 600; color: var(--text-dim); margin-bottom: 7px; }
.input, .textarea, .select {
  width: 100%; min-height: 50px; padding: 13px 16px; background: var(--surface-2);
  border: 1px solid var(--border); border-radius: var(--radius-sm); font-size: 15px; outline: none;
  transition: border-color var(--dur), box-shadow var(--dur), background var(--dur);
}
.textarea { min-height: 100px; resize: vertical; line-height: 1.5; }
.input:focus, .textarea:focus, .select:focus {
  border-color: var(--secondary);
  box-shadow: 0 0 0 3px color-mix(in srgb, var(--secondary) 20%, transparent);
  background: var(--surface);
}
.input:disabled, .textarea:disabled, .select:disabled { opacity: 0.55; cursor: not-allowed; }
.input::placeholder, .textarea::placeholder { color: var(--text-mute); }
.select {
  appearance: none; -webkit-appearance: none;
  background-image: linear-gradient(45deg, transparent 50%, var(--text-mute) 50%), linear-gradient(135deg, var(--text-mute) 50%, transparent 50%);
  background-position: calc(100% - 20px) 50%, calc(100% - 15px) 50%;
  background-size: 5px 5px, 5px 5px; background-repeat: no-repeat;
  padding-right: 40px;
}
.input-row { display: flex; gap: 10px; }
.input-row > * { flex: 1; min-width: 0; }
.hint { font-size: 12px; color: var(--text-mute); margin-top: 6px; line-height: 1.45; }

/* Checkbox estilizado */
input[type='checkbox'] {
  accent-color: var(--primary-bright);
  width: 20px; height: 20px; cursor: pointer;
}

/* Switch (status do vendedor) */
.switch { position: relative; display: inline-flex; flex: 0 0 auto; width: 52px; height: 30px; }
.switch input { opacity: 0; width: 100%; height: 100%; position: absolute; inset: 0; cursor: pointer; z-index: 1; }
.switch .track {
  position: absolute; inset: 0; border-radius: var(--radius-full);
  background: var(--surface-3); border: 1px solid var(--border);
  transition: background var(--dur) var(--ease), border-color var(--dur);
}
.switch .track::after {
  content: ''; position: absolute; top: 50%; left: 3px; width: 22px; height: 22px;
  transform: translateY(-50%); border-radius: 50%;
  background: var(--text-mute);
  transition: left var(--dur) var(--ease-bounce), background var(--dur);
}
.switch input:checked + .track { background: color-mix(in srgb, var(--online) 30%, var(--surface-2)); border-color: var(--online); }
.switch input:checked + .track::after { left: calc(100% - 25px); background: var(--online); box-shadow: 0 0 10px color-mix(in srgb, var(--online) 60%, transparent); }
.switch input:focus-visible + .track { outline: 2px solid var(--secondary); outline-offset: 2px; }

/* ---------- 07. Painéis / Listas ---------- */
.panel {
  background: var(--surface); border: 1px solid var(--border-soft); border-radius: var(--radius);
  padding: 16px; box-shadow: var(--shadow); margin: 12px var(--pad-x);
  animation: fadeUp 0.4s var(--ease) both;
}
.panel + .panel { margin-top: 14px; }

.list-item {
  display: flex; align-items: center; gap: 14px; padding: 15px 16px; width: calc(100% - 2 * var(--pad-x));
  background: var(--surface); border: 1px solid var(--border-soft); border-radius: var(--radius);
  margin: 10px var(--pad-x); box-shadow: var(--shadow); color: inherit; text-align: left;
  transition: transform var(--dur-fast) var(--ease), border-color var(--dur), background var(--dur);
  animation: fadeUp 0.4s var(--ease) both;
}
.list-item:active { transform: scale(0.98); background: var(--surface-2); }
.list-item .li-ic { width: 42px; height: 42px; border-radius: 12px; display: grid; place-items: center; background: var(--surface-2); color: var(--secondary); flex: 0 0 auto; }
.list-item .li-main { flex: 1; min-width: 0; display: flex; flex-direction: column; gap: 1px; }
.list-item .li-title { font-weight: 600; font-size: 15px; }
.list-item .li-sub { font-size: 12.5px; color: var(--text-mute); }
.list-item .li-chev { color: var(--text-mute); transition: transform var(--dur-fast) var(--ease); }

.pill-info {
  background: var(--surface-2); border: 1px solid var(--border-soft); border-radius: var(--radius-sm);
  padding: 12px 14px; font-size: 13.5px; color: var(--text-dim); line-height: 1.5;
}

/* ---------- 08. Perfil ---------- */
.profile-hero { margin: 0 0 8px; padding: 0; position: relative; }
.profile-banner { height: clamp(130px, 22vw, 170px); border-radius: 0 0 var(--radius-lg) var(--radius-lg); }
.profile-info { padding: 0 var(--pad-x); margin-top: -46px; display: flex; align-items: flex-end; gap: 14px; }
.avatar {
  width: 88px; height: 88px; border-radius: 26px; border: 4px solid var(--bg); overflow: hidden;
  background: var(--surface-3); flex: 0 0 auto; display: grid; place-items: center; box-shadow: var(--shadow);
  position: relative;
}
.avatar img { width: 100%; height: 100%; object-fit: cover; }
.avatar span { font-family: var(--font-display); font-weight: 800; font-size: 30px; color: var(--secondary); }
.profile-meta { padding-bottom: 6px; min-width: 0; }
.profile-meta h2 { font-family: var(--font-display); font-size: 19px; display: flex; align-items: center; gap: 8px; flex-wrap: wrap; }
.profile-meta .pid {
  display: inline-flex; align-items: center; gap: 6px; margin-top: 5px; font-size: 12px; font-weight: 600;
  color: var(--secondary); background: var(--surface-2); padding: 4px 10px; border-radius: var(--radius-full);
  border: 1px solid var(--border-soft);
}
.profile-meta .pid svg { width: 13px; height: 13px; }
.tag-admin { font-size: 10.5px; font-weight: 800; padding: 3px 9px; border-radius: var(--radius-full); background: var(--accent-grad); color: #fff; letter-spacing: 0.4px; }

/* ---------- Status Online / Offline (vendedor) ---------- */
.online-badge {
  display: inline-flex; align-items: center; gap: 7px;
  font-size: 12px; font-weight: 700; letter-spacing: 0.2px;
  padding: 5px 12px; border-radius: var(--radius-full);
  border: 1px solid transparent; white-space: nowrap;
}
.online-badge .odot { width: 9px; height: 9px; border-radius: 50%; flex: 0 0 auto; }
.online-badge--on {
  color: var(--online);
  background: color-mix(in srgb, var(--online) 13%, transparent);
  border-color: color-mix(in srgb, var(--online) 35%, transparent);
}
.online-badge--on .odot { background: var(--online); animation: pulseDot 1.8s var(--ease) infinite; }
.online-badge--off {
  color: var(--text-mute);
  background: color-mix(in srgb, var(--text-mute) 10%, transparent);
  border-color: var(--border-soft);
}
.online-badge--off .odot { background: var(--offline); }

/* Card de controle "Status do vendedor" (perfil admin) */
.seller-status-card {
  display: flex; align-items: center; gap: 14px;
  background: var(--surface); border: 1px solid var(--border-soft); border-radius: var(--radius);
  padding: 15px 16px; margin: 10px var(--pad-x); box-shadow: var(--shadow);
  animation: fadeUp 0.4s var(--ease) both;
}
.seller-status-card .li-ic { width: 42px; height: 42px; border-radius: 12px; display: grid; place-items: center; background: var(--surface-2); color: var(--online); flex: 0 0 auto; }
.seller-status-card.is-off .li-ic { color: var(--text-mute); }
.seller-status-card .ssc-main { flex: 1; min-width: 0; }
.seller-status-card .ssc-title { font-weight: 600; font-size: 15px; }
.seller-status-card .ssc-sub { font-size: 12.5px; color: var(--text-mute); }

/* ---------- 11. Página do anúncio ---------- */
.ad-page { animation: fadeIn 0.35s var(--ease); }
.ad-back {
  position: fixed; top: max(14px, env(safe-area-inset-top)); left: 14px; z-index: 30;
  width: 42px; height: 42px; border-radius: 50%; background: color-mix(in srgb, var(--bg) 60%, transparent);
  backdrop-filter: blur(10px); display: grid; place-items: center; color: var(--text);
  border: 1px solid color-mix(in srgb, var(--border) 60%, transparent);
  transition: transform var(--dur-fast) var(--ease), background var(--dur-fast),
              opacity 0.25s var(--ease), visibility 0.25s;
}
.ad-back:active { transform: scale(0.9); }
/* Some ao rolar para longe do topo — não colide com o conteúdo */
.ad-back.is-hidden { opacity: 0; visibility: hidden; pointer-events: none; }

.gallery { position: relative; animation: fadeIn 0.4s var(--ease); }
.gallery__main { aspect-ratio: 4/3; background: var(--surface-2); overflow: hidden; position: relative; }
.gallery__main img, .gallery__main video { width: 100%; height: 100%; object-fit: cover; animation: fadeIn 0.3s var(--ease); }
.gallery__count {
  position: absolute; bottom: 12px; right: 12px; z-index: 2;
  font-size: 11.5px; font-weight: 700; color: #fff;
  background: rgba(0, 0, 0, 0.55); backdrop-filter: blur(6px);
  padding: 4px 11px; border-radius: var(--radius-full);
}
.gallery__main img { cursor: zoom-in; }

/* Lightbox (zoom das fotos do anúncio) */
.lightbox {
  position: fixed; inset: 0; z-index: 80;
  display: none; align-items: center; justify-content: center;
  background: rgba(2, 3, 8, 0.93); backdrop-filter: blur(6px);
}
.lightbox.open { display: flex; animation: fadeIn 0.2s var(--ease); }
.lightbox img {
  max-width: 96vw; max-height: 86vh; max-height: 86dvh; object-fit: contain;
  border-radius: 10px; animation: pop 0.25s var(--ease-bounce);
}
.lightbox__close {
  position: absolute; top: max(14px, env(safe-area-inset-top)); right: 14px;
  width: 44px; height: 44px; border-radius: 50%; display: grid; place-items: center;
  background: rgba(255, 255, 255, 0.1); color: #fff;
  transition: background var(--dur-fast), transform var(--dur-fast) var(--ease);
}
.lightbox__close:active { transform: scale(0.9); }
.lightbox__nav {
  position: absolute; top: 50%; transform: translateY(-50%);
  width: 44px; height: 60px; display: grid; place-items: center; color: #fff;
  background: rgba(255, 255, 255, 0.08); border-radius: 12px;
  transition: background var(--dur-fast);
}
.lightbox__nav:active { background: rgba(255, 255, 255, 0.2); }
.lightbox__nav--prev { left: 10px; }
.lightbox__nav--next { right: 10px; }
.lightbox__count {
  position: absolute; bottom: max(18px, env(safe-area-inset-bottom)); left: 50%; transform: translateX(-50%);
  font-size: 12.5px; font-weight: 700; color: #fff;
  background: rgba(255, 255, 255, 0.12); padding: 5px 14px; border-radius: var(--radius-full);
}

.gallery__thumbs { display: flex; gap: 8px; overflow-x: auto; padding: 10px var(--pad-x); scrollbar-width: none; }
.gallery__thumbs::-webkit-scrollbar { display: none; }
.thumb {
  flex: 0 0 64px; height: 64px; border-radius: 12px; overflow: hidden;
  border: 2px solid transparent; opacity: 0.75; padding: 0;
  transition: border-color var(--dur-fast), opacity var(--dur-fast), transform var(--dur-fast) var(--ease);
}
.thumb:active { transform: scale(0.93); }
.thumb.active { border-color: var(--secondary); opacity: 1; }
.thumb img, .thumb video { width: 100%; height: 100%; object-fit: cover; }

/* Cabeçalho do anúncio: código, título e preço */
.ad-head { padding: 16px var(--pad-x) 4px; display: flex; flex-direction: column; gap: 10px; animation: fadeUp 0.45s var(--ease) both; }
.ad-head__meta { display: flex; align-items: center; gap: 8px; flex-wrap: wrap; }
.code-chip {
  display: inline-flex; align-items: center; gap: 6px;
  font-size: 12px; font-weight: 700; color: var(--secondary);
  background: var(--surface-2); border: 1px dashed color-mix(in srgb, var(--secondary) 45%, var(--border));
  padding: 5px 12px; border-radius: var(--radius-full);
}
.code-chip svg { width: 13px; height: 13px; }
.cat-chip {
  display: inline-flex; align-items: center; gap: 5px; font-size: 12px; font-weight: 600;
  color: var(--text-dim); background: var(--surface-2); border: 1px solid var(--border-soft);
  padding: 5px 12px; border-radius: var(--radius-full);
}
.cat-chip--new {
  color: var(--warning);
  border-color: color-mix(in srgb, var(--warning) 40%, transparent);
  background: color-mix(in srgb, var(--warning) 10%, transparent);
  font-weight: 700;
}
.ad-title {
  font-family: var(--font-display); font-weight: 700;
  font-size: clamp(20px, 5vw, 26px); line-height: 1.25; letter-spacing: -0.3px;
}
.ad-views { display: inline-flex; align-items: center; gap: 5px; font-size: 12px; color: var(--text-mute); }
.ad-views svg { width: 14px; height: 14px; }

/* Bloco de preço em destaque */
.price-card {
  margin: 10px var(--pad-x) 4px; padding: 16px 18px;
  background: linear-gradient(135deg, color-mix(in srgb, var(--secondary) 9%, var(--surface)) 0%, var(--surface) 65%);
  border: 1px solid color-mix(in srgb, var(--secondary) 30%, var(--border-soft));
  border-radius: var(--radius); box-shadow: var(--shadow);
  animation: fadeUp 0.5s var(--ease) both;
}
.price-block { display: flex; align-items: baseline; gap: 10px; flex-wrap: wrap; }
.price-block .from { color: var(--text-mute); text-decoration: line-through; font-size: 15px; }
.price-block .now {
  font-family: var(--font-display); font-weight: 800;
  font-size: clamp(28px, 7vw, 34px); letter-spacing: -0.5px;
  background: var(--accent-grad); -webkit-background-clip: text; background-clip: text; color: transparent;
}
.price-block .off {
  background: var(--danger); color: #fff; font-size: 12px; font-weight: 800;
  padding: 4px 10px; border-radius: var(--radius-full);
  animation: pop 0.4s var(--ease-bounce) 0.3s both;
}
.price-card .price-note { font-size: 12px; color: var(--text-mute); margin-top: 6px; display: flex; align-items: center; gap: 6px; }
.price-card .price-note svg { width: 13px; height: 13px; color: var(--success); }

/* Rótulo de seção interna dos painéis */
.panel-label {
  font-family: var(--font-display); font-weight: 700; font-size: 15px;
  display: flex; align-items: center; gap: 8px; margin-bottom: 10px;
}
.panel-label svg { width: 17px; height: 17px; color: var(--secondary); }
.ad-desc { white-space: pre-wrap; color: var(--text-dim); font-size: 14.5px; line-height: 1.65; overflow-wrap: break-word; }

/* Card do vendedor (página do anúncio) */
.seller-card {
  display: flex; align-items: center; gap: 14px;
  background: linear-gradient(135deg, color-mix(in srgb, var(--secondary) 10%, var(--surface)) 0%, var(--surface) 60%);
  border: 1px solid color-mix(in srgb, var(--secondary) 35%, var(--border));
  border-radius: var(--radius); padding: 15px 16px; margin: 12px var(--pad-x); box-shadow: var(--shadow);
  color: inherit;
  transition: transform var(--dur-fast) var(--ease), box-shadow var(--dur), border-color var(--dur);
  animation: fadeUp 0.5s var(--ease) both;
}
.seller-card:active { transform: scale(0.985); }
@media (hover: hover) {
  .seller-card:hover { box-shadow: var(--glow); border-color: color-mix(in srgb, var(--secondary) 55%, var(--border)); }
}
.seller-card__avatar {
  width: 56px; height: 56px; border-radius: 16px; overflow: hidden; flex: 0 0 auto;
  background: var(--accent-grad); display: grid; place-items: center; position: relative;
  color: #fff; font-family: var(--font-display); font-weight: 800; font-size: 22px;
  box-shadow: var(--shadow-soft);
}
.seller-card__avatar img { width: 100%; height: 100%; object-fit: cover; }
.avatar-wrap { position: relative; flex: 0 0 auto; }
.avatar-wrap .presence {
  position: absolute; bottom: -2px; right: -2px; width: 16px; height: 16px; border-radius: 50%;
  border: 3px solid var(--surface); background: var(--offline);
}
.avatar-wrap .presence.on { background: var(--online); animation: pulseDot 1.8s var(--ease) infinite; }
.seller-card__main { flex: 1; min-width: 0; display: flex; flex-direction: column; gap: 3px; }
.seller-card__label { font-size: 11.5px; color: var(--text-mute); }
.seller-card__name { font-weight: 700; font-size: 15.5px; display: flex; align-items: center; gap: 6px; min-width: 0; }
.seller-card__name span { overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.seller-card__badges { display: flex; align-items: center; gap: 8px; flex-wrap: wrap; margin-top: 3px; }
.seller-card__chev { color: var(--text-mute); flex: 0 0 auto; }
.badge-verified {
  display: inline-flex; align-items: center; gap: 5px;
  font-size: 11px; font-weight: 800; letter-spacing: 0.3px;
  padding: 4px 10px; border-radius: var(--radius-full);
  background: var(--accent-grad); color: #fff; box-shadow: var(--shadow-soft);
  white-space: nowrap;
}
.badge-verified svg { width: 12px; height: 12px; }

/* Barra fixa de compra */
.buybar {
  position: fixed; bottom: 0; left: 0; right: 0; z-index: 35; padding: 12px var(--pad-x);
  padding-bottom: max(12px, env(safe-area-inset-bottom));
  background: var(--glass); backdrop-filter: blur(16px); -webkit-backdrop-filter: blur(16px);
  border-top: 1px solid var(--border-soft); display: flex; gap: 10px; align-items: center;
  max-width: 720px; margin: 0 auto;
  animation: buybarIn 0.45s var(--ease) 0.2s both;
}
@keyframes buybarIn { from { transform: translateY(100%); } }
.buybar__price { display: none; flex-direction: column; min-width: 0; padding-right: 4px; }
.buybar__price .bp-label { font-size: 10.5px; color: var(--text-mute); font-weight: 600; }
.buybar__price .bp-value { font-family: var(--font-display); font-weight: 800; font-size: 18px; white-space: nowrap; }
.buybar .wish-btn {
  width: 52px; height: 50px; flex: 0 0 auto; border: 1px solid var(--border); border-radius: var(--radius);
  display: grid; place-items: center; background: var(--surface-2);
  transition: transform var(--dur-fast) var(--ease-bounce), border-color var(--dur);
}
.buybar .wish-btn:active { transform: scale(1.12); }
.buybar .wish-btn svg { width: 22px; height: 22px; }

/* ---------- 12. Página pública do vendedor ---------- */
.seller-hero { position: relative; margin-bottom: 8px; animation: fadeIn 0.4s var(--ease); }
.seller-hero__banner {
  height: clamp(140px, 26vw, 200px);
  border-radius: 0 0 var(--radius-lg) var(--radius-lg);
  background-image: var(--hero-grad); background-size: cover; background-position: center;
  position: relative; overflow: hidden;
}
.seller-hero__banner::after {
  content: ''; position: absolute; inset: 0;
  background: linear-gradient(180deg, transparent 40%, color-mix(in srgb, var(--bg) 55%, transparent));
}
.seller-hero__info {
  padding: 0 var(--pad-x); margin-top: -48px; position: relative; z-index: 1;
  display: flex; align-items: flex-end; gap: 14px;
}
.seller-hero__avatar {
  width: 96px; height: 96px; border-radius: 28px; overflow: hidden; flex: 0 0 auto;
  border: 4px solid var(--bg); background: var(--accent-grad);
  display: grid; place-items: center; color: #fff;
  font-family: var(--font-display); font-weight: 800; font-size: 34px;
  box-shadow: var(--shadow); position: relative;
  animation: pop 0.5s var(--ease-bounce) both;
}
.seller-hero__avatar img { width: 100%; height: 100%; object-fit: cover; }
.seller-hero__meta { min-width: 0; padding-bottom: 4px; display: flex; flex-direction: column; gap: 6px; }
.seller-hero__name {
  font-family: var(--font-display); font-weight: 800; font-size: clamp(19px, 5vw, 24px);
  letter-spacing: -0.3px; display: flex; align-items: center; gap: 8px; flex-wrap: wrap;
}
.seller-hero__badges { display: flex; align-items: center; gap: 8px; flex-wrap: wrap; }

.seller-bio {
  margin: 14px var(--pad-x) 0; color: var(--text-dim); font-size: 14px; line-height: 1.6;
  animation: fadeUp 0.45s var(--ease) 0.1s both;
}
.seller-since { display: flex; align-items: center; gap: 6px; margin: 10px var(--pad-x) 0; font-size: 12.5px; color: var(--text-mute); }
.seller-since svg { width: 14px; height: 14px; }

.seller-stats {
  display: grid; grid-template-columns: repeat(3, 1fr); gap: 10px;
  padding: 16px var(--pad-x) 4px;
}
.stat-box {
  background: var(--surface); border: 1px solid var(--border-soft); border-radius: var(--radius);
  padding: 14px 10px; text-align: center; box-shadow: var(--shadow);
  display: flex; flex-direction: column; gap: 3px; align-items: center;
  animation: fadeUp 0.5s var(--ease) both;
}
.stat-box:nth-child(2) { animation-delay: 0.07s; }
.stat-box:nth-child(3) { animation-delay: 0.14s; }
.stat-box b {
  font-family: var(--font-display); font-weight: 800; font-size: clamp(18px, 5vw, 22px);
  background: var(--accent-grad); -webkit-background-clip: text; background-clip: text; color: transparent;
}
.stat-box span { font-size: 11px; color: var(--text-mute); font-weight: 600; line-height: 1.3; }

.seller-socials { display: flex; gap: 9px; flex-wrap: wrap; padding: 14px var(--pad-x) 0; }
.social-chip {
  display: inline-flex; align-items: center; gap: 7px;
  font-size: 12.5px; font-weight: 700; color: var(--text-dim);
  background: var(--surface-2); border: 1px solid var(--border); border-radius: var(--radius-full);
  padding: 8px 14px;
  transition: color var(--dur-fast), border-color var(--dur-fast), transform var(--dur-fast) var(--ease);
}
.social-chip:active { transform: scale(0.94); }
.social-chip svg { width: 15px; height: 15px; }

/* ---------- 13. Overlays: Drawer / Sheet / Modal ---------- */
.drawer, .sheet, .modal { position: fixed; inset: 0; z-index: 60; visibility: hidden; }
.drawer.open, .sheet.open, .modal.open { visibility: visible; }
.drawer__backdrop, .sheet__backdrop, .modal__backdrop {
  position: absolute; inset: 0; background: rgba(0, 0, 0, .55);
  backdrop-filter: blur(2px);
  opacity: 0; transition: opacity var(--dur) var(--ease);
}
.drawer.open .drawer__backdrop, .sheet.open .sheet__backdrop, .modal.open .modal__backdrop { opacity: 1; }

.drawer__panel {
  position: absolute; top: 0; bottom: 0; left: 0; width: min(82%, 340px);
  background: var(--bg-2); border-right: 1px solid var(--border-soft);
  transform: translateX(-100%); transition: transform var(--dur) var(--ease);
  display: flex; flex-direction: column; padding-top: env(safe-area-inset-top);
  box-shadow: 20px 0 60px -30px rgba(0, 0, 0, 0.6);
}
.drawer.open .drawer__panel { transform: translateX(0); }
.drawer__head { display: flex; align-items: center; justify-content: space-between; padding: 18px 16px; border-bottom: 1px solid var(--border-soft); }
.drawer__brand { font-family: var(--font-display); font-weight: 700; font-size: 17px; display: flex; align-items: center; gap: 10px; min-width: 0; }
.brand-badge {
  width: 36px; height: 36px; border-radius: 10px; overflow: hidden; flex: 0 0 auto;
  display: grid; place-items: center; background: var(--accent-grad); color: #fff; font-weight: 800; font-size: 14px;
}
.brand-badge img { width: 100%; height: 100%; object-fit: cover; }
.drawer__body { overflow-y: auto; padding: 10px 0; overscroll-behavior: contain; }
.drawer-cat {
  display: flex; align-items: center; gap: 12px; padding: 15px 20px;
  font-weight: 600; color: var(--text-dim);
  transition: background var(--dur-fast), color var(--dur-fast), padding-left var(--dur-fast) var(--ease);
}
.drawer-cat:active { background: var(--surface-2); color: var(--text); padding-left: 24px; }
.drawer-cat .dot { width: 8px; height: 8px; border-radius: 50%; background: var(--secondary); flex: 0 0 auto; }

.sheet__panel, .modal__panel {
  position: absolute; left: 0; right: 0; bottom: 0; background: var(--bg-2);
  border-radius: var(--radius-lg) var(--radius-lg) 0 0; border: 1px solid var(--border-soft); border-bottom: none;
  max-height: 86vh; max-height: 86dvh; display: flex; flex-direction: column;
  transform: translateY(100%); transition: transform 0.32s var(--ease);
  padding-bottom: env(safe-area-inset-bottom);
  box-shadow: 0 -20px 60px -30px rgba(0, 0, 0, 0.65);
}
.sheet.open .sheet__panel, .modal.open .modal__panel { transform: translateY(0); }
.sheet__head { display: flex; align-items: center; justify-content: space-between; padding: 18px 18px 10px; }
.sheet__head h3 { font-family: var(--font-display); font-size: 17px; }
.sheet__body { overflow-y: auto; padding: 6px 14px 20px; overscroll-behavior: contain; }

.modal__panel { max-width: 720px; margin: 0 auto; padding: 22px 18px; display: block; overflow-y: auto; }
.modal__panel::before { content: ''; display: block; width: 42px; height: 4px; border-radius: 3px; background: var(--surface-3); margin: 0 auto 16px; }
.modal h3 { font-family: var(--font-display); font-size: 19px; margin-bottom: 8px; }
.modal p { color: var(--text-dim); font-size: 14.5px; margin-bottom: 16px; line-height: 1.55; }

.code-box {
  display: flex; align-items: center; justify-content: space-between; gap: 10px;
  background: var(--surface-2); border: 1px dashed var(--secondary); border-radius: var(--radius-sm);
  padding: 14px 16px; margin-bottom: 16px;
}
.code-box .code { font-family: var(--font-display); font-weight: 800; font-size: 20px; letter-spacing: 1px; }

/* ---------- Notificações ---------- */
.notif-item { display: flex; gap: 12px; padding: 13px 12px; border-radius: var(--radius-sm); animation: fadeUp 0.35s var(--ease) both; }
.notif-item:nth-child(2) { animation-delay: 0.05s; }
.notif-item:nth-child(3) { animation-delay: 0.1s; }
.notif-item:nth-child(n+4) { animation-delay: 0.15s; }
.notif-item.unread { background: var(--surface-2); }
.notif-item .ni-ic { width: 40px; height: 40px; border-radius: 12px; display: grid; place-items: center; background: var(--surface-3); color: var(--secondary); flex: 0 0 auto; }
.notif-item .ni-title { font-weight: 600; font-size: 14.5px; }
.notif-item .ni-body { font-size: 13px; color: var(--text-mute); }
.notif-item .ni-time { font-size: 11px; color: var(--text-mute); margin-top: 3px; }

/* ---------- Card de pedido ---------- */
.order-card {
  display: flex; gap: 12px; padding: 12px; background: var(--surface); border: 1px solid var(--border-soft);
  border-radius: var(--radius); box-shadow: var(--shadow); margin: 10px var(--pad-x); align-items: stretch;
  animation: fadeUp 0.4s var(--ease) both;
}
.order-card__img { width: 84px; height: 84px; border-radius: 14px; overflow: hidden; background: var(--surface-2); flex: 0 0 auto; }
.order-card__img img { width: 100%; height: 100%; object-fit: cover; }
.order-card__main { flex: 1; min-width: 0; display: flex; flex-direction: column; gap: 3px; }
.order-card__title { font-weight: 600; font-size: 14.5px; overflow: hidden; text-overflow: ellipsis; }
.order-card__meta { font-size: 12px; color: var(--text-mute); }
.order-card__actions { display: flex; flex-direction: column; gap: 6px; justify-content: center; flex: 0 0 auto; }

.status-pill {
  align-self: flex-start; margin-top: auto; font-size: 11.5px; font-weight: 700; padding: 4px 10px;
  border-radius: var(--radius-full); white-space: nowrap;
}
.status-created { background: color-mix(in srgb, var(--text-mute) 22%, transparent); color: var(--text-dim); }
.status-awaiting_payment { background: color-mix(in srgb, var(--warning) 20%, transparent); color: var(--warning); }
.status-paid { background: color-mix(in srgb, var(--secondary) 22%, transparent); color: var(--secondary); }
.status-preparing { background: color-mix(in srgb, var(--primary-bright) 25%, transparent); color: var(--primary-bright); }
.status-delivered { background: color-mix(in srgb, var(--success) 20%, transparent); color: var(--success); }

/* ---------- Segment / tabs ---------- */
.segment { display: flex; gap: 6px; background: var(--surface-2); border-radius: var(--radius-full); padding: 5px; margin: 12px var(--pad-x); border: 1px solid var(--border-soft); }
.segment button {
  flex: 1; height: 40px; border-radius: var(--radius-full); font-weight: 600; font-size: 13.5px; color: var(--text-dim);
  text-align: center; transition: background var(--dur) var(--ease), color var(--dur);
}
.segment button.active { background: var(--accent-grad); color: #fff; box-shadow: var(--shadow-soft); }

/* ---------- Stars ---------- */
.stars { display: flex; gap: 6px; }
.stars button { display: grid; place-items: center; transition: transform var(--dur-fast) var(--ease-bounce); }
.stars button:active { transform: scale(1.25); }
.stars svg { width: 30px; height: 30px; color: var(--warning); fill: none; transition: fill var(--dur-fast); }
.stars svg.on { fill: var(--warning); }

/* ---------- Avaliações (cards) ---------- */
.reviews-strip { display: flex; gap: var(--gap); overflow-x: auto; padding: 4px var(--pad-x) 12px; scrollbar-width: none; scroll-snap-type: x mandatory; scroll-padding-left: var(--pad-x); }
.reviews-strip::-webkit-scrollbar { display: none; }
.review-card {
  flex: 0 0 78%; max-width: 320px; scroll-snap-align: start;
  background: var(--surface); border: 1px solid var(--border-soft); border-radius: var(--radius);
  padding: 14px 16px; box-shadow: var(--shadow); display: flex; flex-direction: column; gap: 8px;
  animation: cardIn 0.45s var(--ease) both;
}
.review-card__head { display: flex; align-items: center; gap: 10px; }
.review-card__avatar {
  width: 38px; height: 38px; border-radius: 12px; overflow: hidden; flex: 0 0 auto;
  background: var(--accent-grad); display: grid; place-items: center;
  color: #fff; font-weight: 800; font-family: var(--font-display); font-size: 16px;
}
.review-card__avatar img { width: 100%; height: 100%; object-fit: cover; }
.review-card__name { font-weight: 700; font-size: 13.5px; }
.review-card__stars { display: flex; gap: 2px; }
.review-card__stars svg { width: 13px; height: 13px; color: var(--warning); fill: var(--warning); }
.review-card__stars svg.off { fill: none; opacity: 0.35; }
.review-card__text {
  font-size: 13px; color: var(--text-dim); line-height: 1.5;
  display: -webkit-box; -webkit-line-clamp: 3; -webkit-box-orient: vertical; overflow: hidden;
}
.review-summary { display: flex; align-items: center; gap: 8px; padding: 0 var(--pad-x) 6px; font-size: 13px; color: var(--text-dim); }
.review-summary b { font-family: var(--font-display); font-size: 20px; color: var(--text); }

/* ---------- 14. Feedback: vazio / skeleton / toast ---------- */
.empty { text-align: center; padding: 56px 24px; color: var(--text-mute); animation: fadeUp 0.4s var(--ease); }
.empty .em-ic { width: 64px; height: 64px; margin: 0 auto 14px; opacity: 0.4; }
.empty .em-ic svg { width: 100%; height: 100%; }
.empty h3 { font-family: var(--font-display); color: var(--text-dim); margin-bottom: 6px; }
.empty p { font-size: 13.5px; line-height: 1.5; max-width: 300px; margin: 0 auto; }

.skeleton {
  background: linear-gradient(90deg, var(--surface-2) 25%, var(--surface-3) 50%, var(--surface-2) 75%);
  background-size: 200% 100%; animation: shimmer 1.2s infinite;
  border-radius: var(--radius); border: 1px solid var(--border-soft);
}
.sk-card { aspect-ratio: 4/5; }

.toast {
  position: fixed; left: 50%; bottom: calc(var(--bottomnav-h) + 20px + env(safe-area-inset-bottom));
  transform: translate(-50%, 20px) scale(0.95);
  z-index: 90; background: var(--surface-3); color: var(--text); padding: 13px 20px; border-radius: var(--radius-full);
  box-shadow: var(--shadow); font-size: 14px; font-weight: 600; opacity: 0; pointer-events: none;
  transition: opacity var(--dur), transform var(--dur) var(--ease-bounce); max-width: min(90%, 420px); text-align: center;
  border: 1px solid var(--border-soft);
}
.toast.show { opacity: 1; transform: translate(-50%, 0) scale(1); }
.toast.err { background: var(--danger); color: #fff; border-color: transparent; }
.toast.ok { background: var(--success); color: #04210f; border-color: transparent; }

/* ---------- Auth ---------- */
.auth { padding: 30px 20px 40px; max-width: 440px; margin: 0 auto; animation: fadeUp 0.45s var(--ease); }
.auth__logo {
  width: 84px; height: 84px; border-radius: 24px; overflow: hidden;
  background: var(--accent-grad); display: grid; place-items: center;
  color: #fff; font-family: var(--font-display); font-weight: 800; font-size: 26px;
  margin: 10px auto 18px; box-shadow: var(--shadow-soft);
  animation: pop 0.5s var(--ease-bounce);
}
.auth__logo img { width: 100%; height: 100%; object-fit: cover; }
.auth h1 { font-family: var(--font-display); text-align: center; font-size: clamp(22px, 6vw, 26px); margin-bottom: 4px; letter-spacing: -0.3px; }
.auth .sub { text-align: center; color: var(--text-mute); margin-bottom: 24px; font-size: 14px; }
.social-row { display: flex; flex-direction: column; gap: 10px; margin-top: 8px; }
.btn--google { background: #fff; color: #1f1f1f; border: 1px solid #dadce0; }
.btn--facebook { background: #1877f2; color: #fff; }
.divider { display: flex; align-items: center; gap: 12px; margin: 20px 0; color: var(--text-mute); font-size: 12px; }
.divider::before, .divider::after { content: ''; flex: 1; height: 1px; background: var(--border); }
.auth-switch { text-align: center; margin-top: 20px; font-size: 14px; color: var(--text-dim); cursor: pointer; }
.auth-switch b { color: var(--secondary); }

/* ---------- Rodapé ---------- */
.footer {
  margin: 28px var(--pad-x) 10px; padding: 22px 16px 8px; text-align: center;
  border-top: 1px solid var(--border-soft);
}
.footer__brand {
  font-family: var(--font-display); font-weight: 800; font-size: 17px; letter-spacing: 2px;
  background: var(--accent-grad); -webkit-background-clip: text; background-clip: text; color: transparent;
}
.footer p { font-size: 11.5px; color: var(--text-mute); margin-top: 6px; line-height: 1.6; }

/* ---------- Utils ---------- */
.stack { display: flex; flex-direction: column; gap: 12px; }
.row { display: flex; gap: 10px; align-items: center; }
.spacer { flex: 1; }
.muted { color: var(--text-mute); }
.center { text-align: center; }
.mt { margin-top: 14px; }
.color-swatches { display: flex; gap: 10px; flex-wrap: wrap; }
.swatch {
  width: 44px; height: 44px; border-radius: 12px; border: 2px solid transparent;
  transition: transform var(--dur-fast) var(--ease-bounce), border-color var(--dur-fast);
}
.swatch:active { transform: scale(0.9); }
.swatch.active { border-color: var(--text); transform: scale(1.08); }
.thumb-wrap { position: relative; flex: 0 0 64px; }

/* ---------- 15. Responsividade ---------- */

/* Celulares muito pequenos (≤ 350px): tudo respira melhor */
@media (max-width: 350px) {
  .grid { grid-template-columns: 1fr 1fr; gap: 10px; }
  .hscroll .card { flex-basis: 62%; }
  .trustbar { grid-template-columns: repeat(3, 1fr); gap: 6px; }
  .trust-item b { font-size: 10.5px; }
  .btn { font-size: 14px; padding: 0 14px; }
  .price-block .now { font-size: 26px; }
}

/* Telas ≥ 400px: mostra o preço na barra de compra (abaixo disso o CTA
   "Comprar via WhatsApp" precisa do espaço; o preço já aparece logo acima) */
@media (min-width: 400px) {
  .buybar__price { display: flex; }
}

/* Tablets (≥ 720px) */
@media (min-width: 720px) {
  .grid { grid-template-columns: repeat(3, 1fr); }
  .hscroll .card { flex-basis: 30%; }
  .banner { flex-basis: 60%; }
  .review-card { flex-basis: 44%; }
  .buybar { border-radius: var(--radius) var(--radius) 0 0; border: 1px solid var(--border-soft); border-bottom: none; }
}

/* Notebooks (≥ 1000px): container maior e 4 colunas */
@media (min-width: 1000px) {
  .app, .buybar { max-width: 960px; }
  .grid { grid-template-columns: repeat(4, 1fr); }
  .hscroll .card { flex-basis: 23%; }
  .banner { flex-basis: 48%; }
  .review-card { flex-basis: 31%; }
  .seller-stats { max-width: 640px; }
}

/* Desktop largo (≥ 1280px) */
@media (min-width: 1280px) {
  .app, .buybar { max-width: 1080px; }
  .banner { flex-basis: 40%; }
}

/* Hover global refinado (apenas dispositivos com mouse) */
@media (hover: hover) {
  .icon-btn:hover { background: var(--surface-2); }
  .list-item:hover { border-color: color-mix(in srgb, var(--secondary) 40%, var(--border)); transform: translateY(-1px); }
  .list-item:hover .li-chev { transform: translateX(3px); }
  .chip:hover { border-color: var(--secondary); color: var(--text); }
  .drawer-cat:hover { background: var(--surface-2); color: var(--text); }
  .section-title .link:hover { background: var(--surface-2); }
  .thumb:hover { opacity: 1; }
  .social-chip:hover { color: var(--secondary); border-color: var(--secondary); }
  .swatch:hover { transform: scale(1.1); }
  .card__wish:hover { transform: scale(1.12); }
  .buybar .wish-btn:hover { border-color: var(--danger); }
  .banner:hover img { transform: scale(1.02); transition: transform 0.6s var(--ease); }
}

/* Acessibilidade: usuários que preferem menos movimento */
@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after {
    animation-duration: 0.01ms !important;
    animation-iteration-count: 1 !important;
    transition-duration: 0.01ms !important;
    scroll-behavior: auto !important;
  }
}
