﻿/* =====================================================
   ðŸŽ¨ CONFIGURAÃ‡Ã•ES GERAIS (variÃ¡veis do tema)
   ===================================================== */
:root {
  /* Textura base usada no fundo */
  --bg-url: url("../images/fundo.png");

  /* Tamanho original da textura */
  --img-w: 1336px;
  --img-h: 1293px;

  /* Escala do fundo da tela e do painel */
  --tile-scale-body: 0.200;   /* fundo geral */
  --tile-scale-panel: 0.300;  /* fundo do painel central */

  /* Cores principais */
  --gold: #ffd700;
  --gold-border: #d4af37;
  --orange: #d46a2e;

  /* Cores dos itens da lista */
  --row-default: rgba(0, 0, 0, 0.22);     /* cor normal */
  --row-selected: rgba(38, 52, 95, 0.32); /* cor azulada ao selecionar */

  /* Caminho padrÃ£o das cantoneiras decorativas */
  --corner-image: url("../images/cantoneira.png");
  --wsdb-corner-image: url("data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAABYAAAAVCAYAAABCIB6VAAAAAXNSR0IArs4c6QAAAARnQU1BAACxjwv8YQUAAAAJcEhZcwAADsMAAA7DAcdvqGQAAAAYdEVYdFNvZnR3YXJlAHBhaW50Lm5ldCA0LjEuNWRHWFIAAAGnSURBVEhLrVUtc4UwEHz/orISiUQikcjIJyMjIyORSGQkMhKJREYiIyORyO1dyKOinbZT2JmdCfnY3F3ujscLy9hi7Cq4vkIY3xNXy3xL48h0n9yYU4HdN9jXJxAkUSGGASFYnKJ70AjLkygw2wbPpoIQElIaKNVDDxHaAmbc0RHneURc2sQwV3RewsjjHPMUjV6iM5LEFAJZM6jyFFekqIwj8YBu8JinAd5V5GEJ2VaQTZ3GycoXvBOnaD9uUL2HkgLLUCThONXY2SJ/7PPumGfqZ4l5KL+KMhzFdZ1EsjSJEo2W5F4LRdaotsw8xJj56M+wmm+sk/vsNnMj6zoKRd7yPzhzuDaaktwu6IICfFle/j8WihFb+XLzz67+Bg4+pxOLB3oojmVeuobF0gOZkTKhw0avr8VNwmFqoPs1ibMwZ0BeuoZIlaYt5W+3UI6K+2IcFirFVKIWbmjvE44kzLXvvU21nqevY6My5V7BtX+btYxtVUDUqeZvFd6phzKVqJN4nr4O7gtxrr9vfVfAjXql/nCrKIN7LFubP+8D/59ufbSEx+MDZqqfpMMQbhAAAAAASUVORK5CYII=");
  /* Unidade de viewport dinÃ¢mica corrigida via JS para iOS (100 * var(--vh) = altura real) */
  --vh: 1vh;
}

@font-face {
  font-family: "Press Start 2P Local";
  src: url("../fonts/press-start-2p.ttf") format("truetype");
  font-weight: 400;
  font-style: normal;
  font-display: swap;
}

:root {
  --number-font: "Lucida Console", "Consolas", "Courier New", monospace;
}

/* =====================================================
   ðŸŒ† FUNDO DO SITE
   ===================================================== */
html, body {
  height: 100%;
  min-height: 100dvh; /* ocupa toda a altura inclusive em navegadores mÃ³veis modernos */
  margin: 0;
}
body {
  /* Cor base escura para evitar fundo branco caso a imagem nÃ£o carregue */
  /* background-color: #111; */
  /* Imagem de textura repetida */
  background-image: var(--bg-url);
  background-repeat: repeat;
  background-size: calc(var(--img-w) * var(--tile-scale-body))
                   calc(var(--img-h) * var(--tile-scale-body));
  image-rendering: pixelated;
  color: var(--gold);
  font-family: 'Segoe UI', system-ui, -apple-system, sans-serif;
  line-height: 1.5;
  display: flex; /* permite centralizar verticalmente no desktop e ajustar no mobile */
  align-items: center;
  justify-content: center;
  padding-top: env(safe-area-inset-top); /* evita Ã¡rea branca em iPhones notch */
  padding-bottom: env(safe-area-inset-bottom);
  box-sizing: border-box;
}

body.detail-page {
  align-items: flex-start;
  padding-top: max(18px, env(safe-area-inset-top));
}

/* =====================================================
   MENU DE IDIOMAS (3 pontinhos)
   ===================================================== */
.language-menu {
  position: fixed;
  top: max(12px, env(safe-area-inset-top));
  left: max(12px, env(safe-area-inset-left));
  z-index: 120;
}

.language-menu-toggle {
  width: 46px;
  height: 42px;
  display: grid;
  place-items: center;
  border: 2px solid rgba(212, 175, 55, 0.78);
  border-radius: 6px;
  background:
    linear-gradient(180deg, rgba(82, 100, 176, 0.92), rgba(50, 55, 128, 0.96)),
    rgba(0,0,0,0.55);
  color: #ffea00;
  box-shadow:
    inset 0 0 0 1px rgba(255,255,255,0.12),
    0 3px 0 rgba(0,0,0,0.62);
  cursor: pointer;
  text-shadow: 2px 2px 0 #000;
}

.language-menu-toggle span {
  font-size: 34px;
  line-height: 0.7;
  transform: translateY(-1px);
}

.language-menu-toggle:hover,
.language-menu-toggle:focus-visible {
  outline: none;
  border-color: #fff07a;
  filter: brightness(1.08);
}

.language-menu-backdrop {
  position: fixed;
  inset: 0;
  display: none;
  background: rgba(0,0,0,0.18);
  z-index: -1;
}

.language-sidebar {
  position: fixed;
  top: max(62px, calc(env(safe-area-inset-top) + 58px));
  left: max(12px, env(safe-area-inset-left));
  width: min(230px, calc(100vw - 24px));
  max-height: min(70vh, 430px);
  display: none;
  overflow-y: auto;
  border: 2px solid rgba(212, 175, 55, 0.78);
  border-radius: 6px;
  background-image:
    linear-gradient(rgba(0, 0, 0, 0.10), rgba(0, 0, 0, 0.36)),
    var(--bg-url);
  background-repeat: repeat;
  background-size: auto,
    calc(var(--img-w) * var(--tile-scale-panel))
    calc(var(--img-h) * var(--tile-scale-panel));
  box-shadow:
    inset 0 0 0 1px rgba(255,255,255,0.08),
    0 10px 24px rgba(0, 0, 0, 0.42);
  image-rendering: pixelated;
}

.language-menu.is-open .language-sidebar,
.language-menu.is-open .language-menu-backdrop {
  display: block;
}

.language-options {
  display: grid;
  gap: 0;
  padding: 7px 0;
}

.language-options button {
  width: 100%;
  min-height: 34px;
  padding: 7px 14px;
  border: 0;
  border-radius: 0;
  background: rgba(255, 255, 255, 0.035);
  color: #fff;
  font: inherit;
  font-size: 18px;
  line-height: 1.12;
  text-align: left;
  text-shadow:
    2px 2px 0 #000,
    -1px 1px 0 #000,
    1px -1px 0 #000;
  cursor: pointer;
}

.language-options button:hover,
.language-options button:focus-visible {
  color: var(--gold);
  background: rgba(40, 55, 105, 0.30);
  outline: none;
}

.language-options button.active {
  color: var(--gold);
  background:
    linear-gradient(90deg, rgba(40, 55, 105, 0.62), rgba(40, 55, 105, 0.18)),
    rgba(0, 0, 0, 0.15);
  box-shadow: inset 3px 0 0 var(--gold-border);
}

/* =====================================================
   ðŸªŸ PAINEL CENTRAL
   ===================================================== */
.panel {
  position: relative; /* deixa o fluxo natural para permitir rolagem total em mobile */
  width: min(92vw, 540px);
  max-height: calc(var(--vh) * 95); /* usa altura real corrigida no mobile */
  border: 2px solid var(--gold-border);
  background-image: var(--bg-url);
  background-repeat: repeat;
  background-size: calc(var(--img-w) * var(--tile-scale-panel))
                   calc(var(--img-h) * var(--tile-scale-panel));
  box-sizing: border-box;
  display: flex;
  flex-direction: column; /* permite que o conteÃºdo seja rolÃ¡vel */
  overflow: hidden; /* esconde o overflow do painel principal */
  margin: 16px auto; /* espaÃ§o respirÃ¡vel em mobile */
}

.panel::before,
.panel::after {
  content: "";
  position: absolute;
  bottom: 0;
  width: 44px;
  height: 42px;
  background-image: var(--wsdb-corner-image);
  background-repeat: no-repeat;
  background-size: 44px 42px;
  image-rendering: pixelated;
  pointer-events: none;
  z-index: 8;
}

.panel::before {
  left: 0;
  transform: scaleY(-1);
}

.panel::after {
  right: 0;
  transform: scale(-1, -1);
}

/* =====================================================
   ðŸ§© CANTONEIRAS DECORATIVAS
   ===================================================== */
.corner {
  position: absolute;
  width: 44px;
  height: 42px;
  background-image: var(--wsdb-corner-image);
  background-size: 44px 42px;
  background-repeat: no-repeat;
  image-rendering: pixelated;
  pointer-events: none; /* evita clique nelas */
  z-index: 8;
}

/* imagem da esquerda */
.corner.top-left {
  top: 0;
  left: 0;
}

/* mesma imagem espelhada Ã  direita */
.corner.top-right {
  top: 0;
  right: 0;
  transform: scaleX(-1);
}

/* =====================================================
   ðŸ“œ CABEÃ‡ALHO DO PAINEL
   ===================================================== */
.header {
  padding: 10px 14px;
  border-bottom: 2px solid var(--gold-border);
  background-image: linear-gradient(var(--orange), var(--orange)), var(--bg-url);
  background-repeat: no-repeat, repeat;
  background-size: cover,
    calc(var(--img-w) * var(--tile-scale-panel))
    calc(var(--img-h) * var(--tile-scale-panel));
  background-blend-mode: multiply, normal;
  position: relative;
}

.title {
  margin: 0;
  text-align: center;
  letter-spacing: 0.5px;
  font-weight: 700;
  font-size: 26px;
  color: var(--gold);
}

/* BotÃ£o voltar */
.back-button {
  position: absolute;
  left: 14px;
  top: 50%;
  transform: translateY(-50%);
  background: transparent;
  border: none;
  color: var(--gold);
  font-size: 24px;
  cursor: pointer;
  padding: 0;
  width: 32px;
  height: 32px;
  display: flex;
  align-items: center;
  justify-content: center;
}

.back-button:hover {
  color: #fff;
}

/* =====================================================
   ðŸ“‹ LISTA DE OPÃ‡Ã•ES
   ===================================================== */
.list { 
  display: grid;
  overflow-y: auto; /* adiciona rolagem vertical */
  overflow-x: hidden; /* esconde rolagem horizontal */
  max-height: calc(var(--vh) * 95 - 140px); /* altura mÃ¡xima considerando header e footer */
}

/* EstilizaÃ§Ã£o da barra de rolagem */
.list::-webkit-scrollbar {
  width: 10px;
}

.list::-webkit-scrollbar-track {
  background: rgba(0, 0, 0, 0.3);
  border-left: 1px solid var(--gold-border);
}

.list::-webkit-scrollbar-thumb {
  background: rgba(212, 175, 55, 0.5);
  border-radius: 5px;
}

.list::-webkit-scrollbar-thumb:hover {
  background: rgba(212, 175, 55, 0.8);
}

/* Scroll indicator */
.list::after {
  content: '';
  position: sticky;
  bottom: 0;
  left: 0;
  right: 0;
  height: 20px;
  background: linear-gradient(transparent, rgba(0,0,0,0.6));
  pointer-events: none;
  opacity: 0;
  transition: opacity 200ms;
}
.list.has-scroll::after {
  opacity: 1;
}

/* item padrÃ£o */
.row {
  display: grid;
  grid-template-columns: 64px 1fr;
  gap: 16px;
  align-items: center;
  padding: 16px;
  border-bottom: 2px solid var(--gold-border);
  background: var(--row-default);
  transition: background 0.2s ease;
  outline: none;
  cursor: pointer;
  position: relative; /* necessÃ¡rio para badge absoluta */
  min-height: 56px;
}

/* item selecionado / hover */
.row:hover,
.row:focus-visible,
.row.active {
  background: var(--row-selected);
}

/* Ã­cone da opÃ§Ã£o */
.icon {
  width: 64px; 
  height: 64px;
  object-fit: cover;
  border: 2px solid var(--gold-border);
  background: #1a1a1a;
  display: block;
}
/* wrapper para Ã­cone permitindo badge de contagem */
.icon-wrapper {
  position: relative;
  display: inline-block;
  width: 64px;
  height: 64px;
}
.icon-wrapper .icon { width:100%; height:100%; }

/* texto das opÃ§Ãµes */
.label {
  font-size: 22px;
  line-height: 1.1;
  color: var(--gold);
  padding-right: 40px;
}

/* Badge de contagem (prÃ³ximo nÃ­vel) */
.count-badge {
  position: absolute;
  right: 2px;
  bottom: 0;
  background: transparent;
  color: #fff;
  border: 0;
  border-radius: 0;
  padding: 0;
  min-width: 0;
  font-family: "Arial Black", Impact, "Segoe UI", sans-serif;
  font-size: 15px;
  font-weight: 900;
  line-height: 1;
  letter-spacing: 0;
  pointer-events: none;
  -webkit-text-stroke: 1px #111;
  text-shadow:
    -1px -1px 0 #111,
     1px -1px 0 #111,
    -1px  1px 0 #111,
     1px  1px 0 #111,
     0 2px 0 #111;
}

a {
  color: var(--gold);
  text-decoration: none;
}

/* =====================================================
   ðŸ”˜ RODAPÃ‰ (botÃ£o de aÃ§Ã£o)
   ===================================================== */
.footer {
  padding: 10px 12px;
  border-top: 0.1px solid var(--gold-border);
  background: rgba(0, 0, 0, 0.18);
}

/* botÃ£o "LOGIN" */
.login-btn {
  display: inline-block;
  padding: 8px 14px;
  border: 1px solid var(--gold-border);
  background: rgba(96, 96, 160, 0.6);
  color: var(--gold);
  font-weight: 700;
  text-decoration: none;
  border-radius: 6px;
  transition: background 0.2s ease;
  cursor: pointer;
  font-size: 14px;
}

/* botÃ£o ao passar o mouse */
.login-btn:hover {
  background: rgba(150, 200, 255, 0.35);
}

/* =====================================================
   ðŸ“ DETALHES DO ITEM
   ===================================================== */
.item-details {
  padding: 20px;
  color: var(--gold);
  overflow-y: auto; /* adiciona rolagem vertical */
  overflow-x: hidden; /* esconde rolagem horizontal */
  max-height: calc(var(--vh) * 95 - 140px); /* altura mÃ¡xima considerando header e footer */
}

/* EstilizaÃ§Ã£o da barra de rolagem para item-details */
.item-details::-webkit-scrollbar {
  width: 10px;
}

.item-details::-webkit-scrollbar-track {
  background: rgba(0, 0, 0, 0.3);
  border-left: 1px solid var(--gold-border);
}

.item-details::-webkit-scrollbar-thumb {
  background: rgba(212, 175, 55, 0.5);
  border-radius: 5px;
}

.item-details::-webkit-scrollbar-thumb:hover {
  background: rgba(212, 175, 55, 0.8);
}

.item-details-image {
  text-align: center;
  margin-bottom: 20px;
}

.item-details-image img {
  max-width: 200px;
  max-height: 200px;
  border: 2px solid var(--gold-border);
  background: #1a1a1a;
}

.item-details-info {
  background: var(--row-default);
  padding: 16px;
  border: 2px solid var(--gold-border);
}

.item-details-info h2 {
  margin-top: 0;
  color: var(--gold);
}

.item-details-info p {
  margin: 10px 0;
  color: var(--gold);
}

/* =============================
   ðŸ’± ÃCONES DE PREÃ‡O / LINHAS
   ============================= */
.price-line {
  display: flex;
  align-items: center;
  gap: 6px;
  margin: 6px 0;
  font-size: 14px;
}
.price-label { font-weight: 700; }
.price-value { font-weight: 600; color: #ffd700; }
.price-icon {
  width: 20px;
  height: 20px;
  background-size: contain;
  background-repeat: no-repeat;
  display: inline-block;
  border: 1px solid var(--gold-border);
  border-radius: 4px;
  box-sizing: border-box;
}
/* Moeda do jogo (dourada) */
.price-icon.game-coin {
  border: 0;
  border-radius: 50%;
  background-image: url("../images/uploads/gold_coin.png");
  background-position: left top;
  background-size: 188.235% 188.235%;
}
/* Real (verde com cifra R$) */
.price-icon.brl-coin {
  background-image: url("data:image/svg+xml;utf8,<svg xmlns='http://www.w3.org/2000/svg' width='64' height='64'><rect width='64' height='64' rx='8' fill='%230a0a0a'/><rect x='12' y='12' width='40' height='40' rx='8' fill='%2307a359' stroke='%23057a44' stroke-width='4'/><text x='32' y='38' font-size='18' text-anchor='middle' fill='%23fff' font-family='Arial' font-weight='700'>R$</text></svg>");
}

/* =============================
   ðŸ“² BOTÃƒO WHATSAPP COMPRA
   ============================= */
.purchase-actions { margin-top: 12px; }
.btn-whatsapp {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  padding: 10px 16px;
  background: #1e1e1e;
  border: 2px solid var(--gold-border);
  color: var(--gold);
  font-weight: 600;
  font-size: 14px;
  border-radius: 8px;
  cursor: pointer;
  box-shadow: 0 2px 4px rgba(0,0,0,0.6);
  transition: background 0.2s, transform 0.15s;
}
.btn-whatsapp:hover { background:#2a2a2a; }
.btn-whatsapp:active { transform: translateY(1px); }
.wa-icon {
  width:20px;
  height:20px;
  background-size:contain;
  background-repeat:no-repeat;
  background-image:url("data:image/svg+xml;utf8,<svg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 100 100'><circle cx='50' cy='50' r='46' fill='%2300a884' stroke='%2300664d' stroke-width='8'/><path d='M33 25h34c4 0 7 3 7 7v36c0 4-3 7-7 7H45l-12 12V32c0-4 3-7 7-7z' fill='%23fff' opacity='0.25'/><path d='M50 27c-13 0-23 10-23 23 0 4 1 8 3 11l-4 14 14-4c3 2 7 3 10 3 13 0 23-10 23-24 0-12-10-23-23-23zm13 32c-1 2-6 3-8 2-2-1-5-2-7-4-2-1-4-5-5-6-1-2-1-3 0-4 0-1 0-2 1-2l2-2c1-1 1-1 2 0l2 4c1 1 1 1 0 2l-1 1c0 1 1 2 2 3 2 2 3 2 4 2l1-1c1-1 2-1 3 0 1 0 4 2 4 3 0 1 0 2 0 2z' fill='%23fff'/></svg>");
}

/* Admin buttons — base (modern admin overrides where needed) */
.admin-button {
  padding: 8px 14px;
  border: 1px solid var(--gold-border);
  background: rgba(96, 96, 160, 0.6);
  color: var(--gold);
  font-weight: 700;
  border-radius: 6px;
  cursor: pointer;
  transition: background 0.2s ease;
}

.admin-button:hover {
  background: rgba(150, 200, 255, 0.35);
}

.admin-button.danger {
  background: rgba(160, 96, 96, 0.6);
}

.admin-button.danger:hover {
  background: rgba(255, 150, 150, 0.35);
}

.admin-button.info {
  background: rgba(96, 160, 96, 0.6);
}

.admin-button.info:hover {
  background: rgba(150, 255, 150, 0.35);
}

/* =====================================================
   ðŸ“š ADMIN ACCORDIONS
   ===================================================== */
.accordion {
  display: flex;
  flex-direction: column;
  gap: 12px;
}

.accordion-item {
  border: 2px solid var(--gold-border);
  border-radius: 8px;
  background: rgba(0, 0, 0, 0.45);
  overflow: hidden;
}

.accordion-item summary {
  list-style: none;
  cursor: pointer;
  padding: 14px 18px;
  font-weight: 700;
  color: var(--gold);
  background: linear-gradient(90deg, rgba(212, 175, 55, 0.25), rgba(0, 0, 0, 0.2));
  display: flex;
  justify-content: space-between;
  align-items: center;
}

.accordion-item summary::-webkit-details-marker {
  display: none;
}

.accordion-item[open] summary {
  background: linear-gradient(90deg, rgba(212, 175, 55, 0.4), rgba(0, 0, 0, 0.3));
}

.accordion-chevron {
  transform: rotate(0deg);
  transition: transform 0.2s ease;
}

.accordion-item[open] .accordion-chevron {
  transform: rotate(90deg);
}

.accordion-content {
  padding: 16px 18px 20px;
  border-top: 1px solid rgba(212, 175, 55, 0.5);
  background: rgba(0, 0, 0, 0.3);
  display: flex;
  flex-direction: column;
  gap: 14px;
}

.accordion-filters {
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
  align-items: center;
}

.accordion-filters label {
  font-size: 14px;
}

.accordion-filters input,
.accordion-filters select {
  padding: 6px 8px;
  border: 1px solid rgba(255, 255, 255, 0.06);
  background: rgba(0, 0, 0, 0.4);
  color: var(--gold);
  border-radius: 4px;
}

.accordion-list {
  display: flex;
  flex-direction: column;
  gap: 10px;
}

.accordion-list .admin-row {
  border-radius: 6px;
}

.accordion-group-title {
  margin: 4px 0 6px;
  font-size: 16px;
  font-weight: 700;
  color: var(--gold);
}

.accordion-empty {
  opacity: 0.7;
  font-size: 14px;
}

.admin-list {
  margin-top: 20px;
  overflow-y: auto; /* adiciona rolagem vertical */
  overflow-x: hidden; /* esconde rolagem horizontal */
  max-height: calc(var(--vh) * 95 - 300px); /* altura mÃ¡xima considerando outros elementos */
}

/* EstilizaÃ§Ã£o da barra de rolagem para admin-list */
.admin-list::-webkit-scrollbar {
  width: 10px;
}

.admin-list::-webkit-scrollbar-track {
  background: rgba(0, 0, 0, 0.3);
  border-left: 1px solid var(--gold-border);
}

.admin-list::-webkit-scrollbar-thumb {
  background: rgba(212, 175, 55, 0.5);
  border-radius: 5px;
}

.admin-list::-webkit-scrollbar-thumb:hover {
  background: rgba(212, 175, 55, 0.8);
}

/* Admin row — layout base para linhas de itens */
.admin-row {
  display: grid;
  grid-template-columns: 64px 1fr auto;
  gap: 12px;
  align-items: center;
  padding: 12px;
  border-bottom: 2px solid var(--gold-border);
  background: var(--row-default);
}

.admin-row .thumb { width: 64px; height: 64px; object-fit: cover; border: 2px solid var(--gold-border); background:#1a1a1a; }
.admin-row .title { font-weight: 700; color: var(--gold); }
.admin-row .subtitle { font-size: 12px; opacity: 0.9; }

/* =====================================================
   ï¿½ðŸªŸ MODAL / FORMULÃRIOS ADMIN
   ===================================================== */
.modal-overlay {
  position: fixed;
  left: 0;
  top: 0;
  right: 0;
  bottom: 0;
  background: rgba(0,0,0,0.6);
  display: flex;
  align-items: center;
  justify-content: center;
  z-index: 9999;
}

.modal {
  width: min(92vw, 720px);
  max-height: 90vh;
  overflow-y: auto;
  background: rgba(0,0,0,0.9);
  border: 2px solid var(--gold-border);
  padding: 18px;
  box-sizing: border-box;
}

.form-row {
  display: flex;
  gap: 10px;
  margin-bottom: 12px;
  align-items: center;
}

.form-row label {
  width: 160px;
  font-weight: 700;
}

.form-row input[type="text"],
.form-row input[type="number"],
.form-row textarea,
.form-row select {
  flex: 1;
  padding: 8px;
  border: 1px solid rgba(255,255,255,0.06);
  background: rgba(0,0,0,0.4);
  color: var(--gold);
  border-radius: 4px;
}

.modal .form-actions {
  display: flex;
  gap: 10px;
  justify-content: flex-end;
  margin-top: 8px;
}

.modal .form-actions .btn {
  padding: 8px 12px;
  border-radius: 6px;
  border: 1px solid var(--gold-border);
  background: rgba(96,96,160,0.6);
  color: var(--gold);
  cursor: pointer;
}

.modal .form-actions .btn.cancel {
  background: rgba(160,96,96,0.4);
}

/* =====================================================
   ðŸ”” TOASTS (avisos no visual do sistema)
   ===================================================== */
.toast-container {
  position: fixed;
  top: 12px;
  left: 50%;
  transform: translateX(-50%);
  z-index: 10000;
  display: flex;
  flex-direction: column;
  gap: 8px;
}

.toast {
  min-width: 260px;
  max-width: 90vw;
  padding: 10px 14px;
  border: 2px solid var(--gold-border);
  background: rgba(0, 0, 0, 0.8);
  color: var(--gold);
  box-shadow: 0 2px 8px rgba(0,0,0,0.4);
}

.toast.success { background: rgba(96, 160, 96, 0.6); }
.toast.error { background: rgba(160, 96, 96, 0.6); }
.toast.info { background: rgba(96, 96, 160, 0.6); }

.admin-item {
  display: grid;
  grid-template-columns: 64px 1fr auto;
  gap: 16px;
  align-items: center;
  padding: 16px;
  border-bottom: 2px solid var(--gold-border);
  background: var(--row-default);
}

.admin-item img {
  width: 64px;
  height: 64px;
  object-fit: cover;
  border: 2px solid var(--gold-border);
  background: #1a1a1a;
}

.admin-item-info {
  color: var(--gold);
}

.admin-item-actions {
  display: flex;
  gap: 8px;
}

/* â­ FAVORITE ICON */
.fav-icon {
  cursor: pointer;
  font-size: 20px;
  user-select: none;
  position: absolute;
  right: 12px;
  top: 50%;
  transform: translateY(-50%);
  z-index: 2;
  transition: transform 0.15s;
}
.fav-icon:hover {
  transform: translateY(-50%) scale(1.2);
}

/* =====================================================
   ðŸ‘¤ USER INFO BAR
   ===================================================== */
.user-info-bar {
    text-align: center;
    font-size: 12px;
    color: rgba(255, 255, 255, 0.85);
    padding: 4px 0 0;
    opacity: 0.9;
}

/* =====================================================
   ðŸ” SEARCH BAR
   ===================================================== */
/* =====================================================
   ðŸ“Š STATS CARD
   ===================================================== */
.stats-card {
    display: flex;
    gap: 12px;
    padding: 12px 14px;
    border-bottom: 1px solid rgba(212, 175, 55, 0.2);
}
.stat-item {
    flex: 1;
    text-align: center;
    padding: 10px;
    background: rgba(255, 215, 0, 0.06);
    border-radius: 8px;
    border: 1px solid rgba(212, 175, 55, 0.2);
}
.stat-value {
    font-size: 22px;
    font-weight: 700;
    color: var(--gold);
}
.stat-label {
    font-size: 11px;
    color: #999;
    margin-top: 2px;
}

/* =====================================================
   ðŸ” MODERN LOGIN (glassmorphism)
   ===================================================== */
.login-container {
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 20px;
}
.login-card {
    background: rgba(20, 20, 30, 0.85);
    backdrop-filter: blur(16px);
    -webkit-backdrop-filter: blur(16px);
    border: 2px solid var(--gold-border);
    border-radius: 16px;
    padding: 32px 24px;
    max-width: 380px;
    width: 100%;
    text-align: center;
    box-shadow: 0 8px 32px rgba(0, 0, 0, 0.5);
}
.login-icon {
    font-size: 48px;
    margin-bottom: 8px;
}
.login-card h2 {
    margin: 0;
    color: var(--gold);
    font-size: 24px;
}
.login-subtitle {
    color: #999;
    font-size: 14px;
    margin-bottom: 24px;
}
.login-field {
    position: relative;
    margin-bottom: 16px;
}
.login-field-icon {
    position: absolute;
    left: 12px;
    top: 50%;
    transform: translateY(-50%);
    font-size: 18px;
    z-index: 1;
    pointer-events: none;
}
.login-field input {
    width: 100%;
    padding: 12px 12px 12px 44px;
    background: rgba(255, 255, 255, 0.06);
    border: 1px solid rgba(212, 175, 55, 0.3);
    border-radius: 8px;
    color: #fff;
    font-size: 15px;
    box-sizing: border-box;
    transition: border-color 200ms, box-shadow 200ms;
}
.login-field input:focus {
    outline: none;
    border-color: var(--gold);
    box-shadow: 0 0 8px rgba(255, 215, 0, 0.15);
}
.login-field input::placeholder {
    color: rgba(255, 255, 255, 0.3);
}
.login-submit {
    width: 100%;
    padding: 14px;
    background: linear-gradient(135deg, #d46a2e, #b85a1e);
    border: none;
    border-radius: 8px;
    color: #fff;
    font-size: 16px;
    font-weight: 600;
    cursor: pointer;
    margin-bottom: 12px;
    transition: transform 100ms, box-shadow 200ms;
}
.login-submit:hover {
    transform: translateY(-1px);
    box-shadow: 0 4px 16px rgba(212, 106, 46, 0.4);
}
.login-submit:active {
    transform: translateY(0);
}

/* =====================================================
   ðŸ“± MOBILE NAV (rodapÃ© fixo)
   ===================================================== */
.mobile-nav {
  display: none;
  position: fixed;
  bottom: 0;
  left: 0;
  right: 0;
  background: #1a1a1a;
  border-top: 2px solid #d4af37;
  padding: 8px 16px;
  z-index: 100;
  justify-content: space-around;
}
.mobile-nav button {
  background: transparent;
  border: none;
  color: #ffd700;
  font-size: 20px;
  padding: 8px 16px;
  cursor: pointer;
}
@media (max-width: 768px) {
  .mobile-nav { display: flex; }
  body { padding-bottom: 70px; }
  .language-menu {
    top: max(8px, env(safe-area-inset-top));
    left: max(8px, env(safe-area-inset-left));
  }
  .language-menu-toggle {
    width: 42px;
    height: 38px;
  }
  .language-sidebar {
    top: max(52px, calc(env(safe-area-inset-top) + 48px));
    left: max(8px, env(safe-area-inset-left));
    max-height: min(58vh, 360px);
  }
  .language-options button {
    min-height: 32px;
    font-size: 16px;
  }
}

/* =====================================================
   ðŸ“± RESPONSIVIDADE MOBILE
   - Ajustes para evitar corte de elementos em telas menores
   ===================================================== */
@media (max-width: 768px) {
  body { align-items: flex-start; }
  .panel { width: 96vw; margin: 12px auto 24px; }
  .title { font-size: 22px; }
  .row { grid-template-columns: 52px 1fr; gap: 12px; padding: 12px; }
  .icon { width: 52px; height: 52px; }
  .label { font-size: 18px; }
  .footer { padding: 8px 10px; }
  .login-btn { font-size: 13px; padding: 6px 12px; }
  .list, .item-details, .admin-panel, .admin-list { max-height: none; } /* usa rolagem da pÃ¡gina */
}

@media (max-width: 480px) {
  .title { font-size: 20px; }
  .row { padding: 10px; }
  .label { font-size: 16px; }
}

/* =====================================================
   ðŸ‘‘ PREMIUM ADMIN UI
   ===================================================== */

.admin-panel { padding: 0; }

.admin-tabs {
  display: flex;
  gap: 2px;
  padding: 8px;
  background: rgba(0,0,0,0.3);
  border-bottom: 2px solid var(--gold-border);
  overflow-x: auto;
  flex-shrink: 0;
}

.admin-tab {
  padding: 10px 20px;
  background: rgba(255,215,0,0.05);
  border: 1px solid rgba(212,175,55,0.2);
  border-radius: 8px 8px 0 0;
  color: #999;
  cursor: pointer;
  font-size: 13px;
  font-weight: 600;
  white-space: nowrap;
  transition: all 150ms;
  user-select: none;
}

.admin-tab.active {
  background: rgba(255,215,0,0.12);
  color: var(--gold);
  border-color: var(--gold-border);
  border-bottom-color: transparent;
}

.admin-tab:hover {
  background: rgba(255,215,0,0.08);
  color: #fff;
}

.admin-content {
  padding: 12px;
  max-height: 50vh;
  overflow-y: auto;
  flex: 1;
}

.admin-card {
  background: rgba(20,20,30,0.7);
  border: 1px solid rgba(212,175,55,0.25);
  border-radius: 12px;
  padding: 16px;
  margin-bottom: 12px;
}

.admin-card-header {
  font-size: 15px;
  font-weight: 700;
  color: var(--gold);
  margin-bottom: 12px;
  padding-bottom: 8px;
  border-bottom: 1px solid rgba(212,175,55,0.15);
}

.admin-table {
  width: 100%;
  border-collapse: collapse;
}

.admin-table th {
  text-align: left;
  padding: 8px 10px;
  font-size: 11px;
  text-transform: uppercase;
  letter-spacing: 1px;
  color: #888;
  border-bottom: 1px solid rgba(212,175,55,0.2);
}

.admin-table td {
  padding: 10px;
  border-bottom: 1px solid rgba(255,255,255,0.05);
  font-size: 13px;
  color: #ccc;
}

.admin-table tr:hover td {
  background: rgba(255,215,0,0.03);
}

.admin-badge {
  display: inline-block;
  padding: 3px 10px;
  border-radius: 12px;
  font-size: 11px;
  font-weight: 600;
}

.badge-active {
  background: rgba(0,200,0,0.2);
  color: #4caf50;
}

.badge-inactive {
  background: rgba(200,0,0,0.2);
  color: #f44336;
}

/* Autocomplete dropdown */
.autocomplete-wrap {
  position: relative;
}

.autocomplete-dropdown {
  position: absolute;
  top: 100%;
  left: 0;
  right: 0;
  z-index: 20;
  background: #1a1a2e;
  border: 1px solid var(--gold-border);
  border-radius: 0 0 8px 8px;
  max-height: 200px;
  overflow-y: auto;
  display: none;
}

.autocomplete-dropdown.active {
  display: block;
}

.autocomplete-item {
  position: relative;
  display: grid;
  grid-template-columns: 44px minmax(0, 1fr) auto;
  align-items: center;
  gap: 10px;
  padding: 8px 12px;
  cursor: pointer;
  color: #ccc;
  border-bottom: 1px solid rgba(255,255,255,0.05);
}

.autocomplete-item:hover {
  background: rgba(255,215,0,0.1);
  color: #fff;
}

.autocomplete-item img {
  width: 38px;
  height: 38px;
  object-fit: contain;
}

.ac-icon-wrap {
  position: relative;
  width: 44px;
  height: 44px;
  display: block;
  background-image: url("../images/wsdb_slot_frame.png");
  background-repeat: no-repeat;
  background-size: 132px 88px;
  background-position: 0 -44px;
  image-rendering: pixelated;
}

.ac-icon-wrap img {
  position: absolute;
  left: 7px;
  top: 6px;
  width: 30px;
  height: 30px;
  object-fit: contain;
}

.ac-icon-wrap b {
  position: absolute;
  left: 5px;
  top: 4px;
  color: #ffe500;
  font: 900 12px/1 "Arial Black", Impact, sans-serif;
  -webkit-text-stroke: 1px #111;
  text-shadow: 1px 1px 0 #111;
}

.autocomplete-item .ac-name {
  min-width: 0;
  font-size: 13px;
  font-weight: 900;
  line-height: 1.1;
  text-shadow: -1px 0 1px #000, 0 -1px 1px #000, 1px 0 1px #000, 0 1px 1px #000;
}

.ac-main {
  min-width: 0;
  display: flex;
  align-items: center;
  gap: 10px;
}

.ac-inline-stats {
  display: flex;
  align-items: center;
  gap: 5px;
  flex: 0 0 auto;
}

.ac-mini-stat {
  position: relative;
  width: 36px;
  height: 36px;
  display: block;
  background-image: url("../images/wsdb_slot_frame.png");
  background-repeat: no-repeat;
  background-size: 108px 72px;
  background-position: 0 -36px;
  image-rendering: pixelated;
}

.ac-mini-stat img {
  position: absolute;
  left: 7px;
  top: 6px;
  width: 23px;
  height: 23px;
  object-fit: contain;
  image-rendering: pixelated;
}

.ac-mini-stat b {
  position: absolute;
  right: 3px;
  bottom: 3px;
  color: #fff;
  font: 900 10px/1 "Arial Black", Impact, sans-serif;
  -webkit-text-stroke: 0.7px #111;
  text-shadow: 1px 1px 0 #111;
}

.autocomplete-item .ac-cat {
  font-size: 10px;
  color: #888;
}

/* Scrollbar for admin-content */
.admin-content::-webkit-scrollbar {
  width: 8px;
}

.admin-content::-webkit-scrollbar-track {
  background: rgba(0,0,0,0.3);
}

.admin-content::-webkit-scrollbar-thumb {
  background: rgba(212,175,55,0.4);
  border-radius: 4px;
}

.admin-content::-webkit-scrollbar-thumb:hover {
  background: rgba(212,175,55,0.7);
}

/* Sparkle / glow animation for login card */
@keyframes borderGlow {
  0%, 100% { box-shadow: 0 0 20px rgba(212,175,55,0.1); }
  50% { box-shadow: 0 0 40px rgba(212,175,55,0.25); }
}

.login-card {
  animation: borderGlow 3s ease-in-out infinite;
}

/* Modal form improvements */
.modal .form-row label {
  min-width: 120px;
  font-size: 13px;
}

.modal .form-row input[type="text"],
.modal .form-row input[type="number"],
.modal .form-row textarea,
.modal .form-row select {
  font-size: 14px;
}

/* Responsive admin tabs */
@media (max-width: 480px) {
  .admin-tab {
    padding: 8px 12px;
    font-size: 12px;
  }
  .admin-content {
    max-height: 45vh;
    padding: 8px;
  }
}

/* =====================================================
   âš”ï¸ ITEM STATS (atributos detalhados)
   ===================================================== */
.item-stats {
    margin: 16px 0;
    padding: 14px;
    background: rgba(0, 0, 0, 0.3);
    border: 1px solid rgba(212, 175, 55, 0.25);
    border-radius: 8px;
}
.item-stats h3 {
    margin: 0 0 10px 0;
    font-size: 14px;
    color: var(--gold);
    letter-spacing: 0.5px;
}
.stat-row {
    display: flex;
    align-items: center;
    gap: 8px;
    padding: 5px 0;
    font-size: 13px;
    border-bottom: 1px solid rgba(255, 255, 255, 0.04);
}
.stat-icon {
    width: 20px;
    height: 20px;
    object-fit: contain;
}
.stat-label {
    color: #aaa;
    min-width: 100px;
}
.stat-value {
    color: #fff;
    font-weight: 600;
}
.stat-set {
    margin-top: 6px;
    border-top: 1px solid rgba(212, 175, 55, 0.2);
    padding-top: 8px;
}
.stat-set .stat-label,
.stat-set-bonus .stat-label {
    color: var(--gold);
}

.stat-header {
    display: flex; justify-content: space-between; align-items: center;
    padding: 6px 0 10px 0; margin-bottom: 8px;
    border-bottom: 2px solid rgba(212,175,55,0.3);
    font-size: 14px; font-weight: 700; color: #fff;
}
.stat-section {
    margin-top: 12px; padding: 6px 0;
    font-size: 12px; font-weight: 700; color: var(--gold);
    text-transform: uppercase; letter-spacing: 1px;
    border-top: 1px solid rgba(212,175,55,0.15);
}

/* =====================================================
   ADMIN MODERNO
   ===================================================== */
.admin-dashboard-panel {
  width: min(96vw, 1120px);
  max-height: calc(var(--vh) * 94);
}

.admin-login-panel {
  width: min(94vw, 860px);
}

.admin-hero {
  min-height: 86px;
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: 18px;
  padding: 18px 26px;
}

.admin-hero .title {
  text-align: left;
}

.admin-hero-actions,
.admin-action-list {
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
}

.admin-button.ghost {
  background: rgba(0,0,0,0.28);
}

.admin-shell {
  display: grid;
  grid-template-columns: 220px minmax(0, 1fr);
  padding: 0;
  min-height: 560px;
  max-height: calc(var(--vh) * 94 - 126px);
  overflow: hidden;
}

.admin-sidebar {
  padding: 14px;
  border-right: 1px solid rgba(212,175,55,0.35);
  background: rgba(0,0,0,0.34);
  display: flex;
  flex-direction: column;
  gap: 8px;
}

.admin-nav-item {
  min-height: 44px;
  display: flex;
  align-items: center;
  gap: 10px;
  padding: 10px 12px;
  border: 1px solid rgba(212,175,55,0.16);
  border-radius: 8px;
  background: rgba(255,255,255,0.035);
  color: rgba(255,255,255,0.72);
  cursor: pointer;
  font-weight: 700;
  text-align: left;
}

.admin-nav-item:hover,
.admin-nav-item.active {
  color: var(--gold);
  border-color: rgba(255,215,0,0.55);
  background: rgba(255,215,0,0.1);
}

.admin-nav-icon {
  width: 26px;
  height: 26px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  border-radius: 6px;
  background: rgba(0,0,0,0.32);
  color: var(--gold);
}

.admin-workspace {
  min-width: 0;
  overflow: hidden;
}

.admin-content {
  max-height: 100%;
  padding: 18px;
  overflow: auto;
}

.admin-page-head {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 16px;
  margin-bottom: 14px;
}

.admin-page-head h2 {
  margin: 0;
  color: var(--gold);
  font-size: 22px;
}

.admin-page-head p {
  margin: 4px 0 0;
  color: rgba(255,255,255,0.66);
  font-size: 13px;
}

.admin-metrics {
  display: grid;
  grid-template-columns: repeat(6, minmax(0, 1fr));
  gap: 10px;
  margin-bottom: 14px;
}

.admin-metric {
  border: 1px solid rgba(212,175,55,0.22);
  border-radius: 8px;
  padding: 12px;
  background: rgba(0,0,0,0.32);
}

.admin-metric span {
  display: block;
  color: #fff;
  font-size: 26px;
  font-weight: 800;
  line-height: 1;
}

.admin-metric small {
  display: block;
  margin-top: 6px;
  color: rgba(255,255,255,0.58);
}

.admin-grid-two {
  display: grid;
  grid-template-columns: 0.85fr 1.15fr;
  gap: 14px;
}

.admin-card {
  border-radius: 8px;
  background: rgba(10,10,14,0.58);
}

.admin-table-wrap {
  overflow-x: auto;
}

.admin-cat-thumb {
  width: 42px;
  height: 42px;
  object-fit: contain;
  border: 1px solid rgba(212,175,55,0.45);
  border-radius: 6px;
  background: rgba(0,0,0,0.45);
}

.admin-cat-grid,
.admin-tree-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(210px, 1fr));
  gap: 10px;
}

.admin-tree-group {
  display: flex;
  flex-direction: column;
  gap: 8px;
}

.admin-subcat-row {
  display: grid;
  grid-template-columns: 1fr;
  gap: 6px;
  padding-left: 10px;
  border-left: 1px solid rgba(212,175,55,0.22);
}

.admin-cat-card {
  display: grid;
  grid-template-columns: 46px minmax(0, 1fr) auto;
  align-items: center;
  gap: 10px;
  padding: 10px;
  border: 1px solid rgba(212,175,55,0.2);
  border-radius: 8px;
  background: rgba(0,0,0,0.3);
}

.admin-cat-card.compact {
  padding: 8px;
  grid-template-columns: 34px minmax(0, 1fr) auto;
}

.admin-cat-card img {
  width: 46px;
  height: 46px;
  object-fit: contain;
  border-radius: 6px;
  background: rgba(0,0,0,0.35);
}

.admin-cat-card.compact img {
  width: 34px;
  height: 34px;
}

.admin-cat-card strong {
  display: block;
  color: var(--gold);
  line-height: 1.15;
}

.admin-cat-card span {
  display: block;
  margin-top: 3px;
  color: rgba(255,255,255,0.58);
  font-size: 12px;
}

.admin-cat-card small {
  min-width: 24px;
  text-align: center;
  color: #fff;
  font-weight: 800;
}

.admin-login-layout {
  display: grid;
  grid-template-columns: 1fr 360px;
  gap: 24px;
  padding: 34px;
}

.admin-login-brand {
  display: flex;
  flex-direction: column;
  justify-content: center;
  min-height: 360px;
}

.admin-login-brand span {
  color: rgba(255,255,255,0.64);
  font-size: 13px;
  text-transform: uppercase;
}

.admin-login-brand h1 {
  margin: 10px 0;
  color: var(--gold);
  font-size: 42px;
  line-height: 1;
}

.admin-login-brand p {
  max-width: 480px;
  color: rgba(255,255,255,0.72);
}

.admin-login-box {
  padding: 22px;
  border: 1px solid rgba(212,175,55,0.36);
  border-radius: 8px;
  background: rgba(0,0,0,0.42);
}

.admin-login-box h2 {
  margin: 0 0 18px;
  color: var(--gold);
}

.admin-login-box label {
  display: block;
  margin: 12px 0 6px;
  color: rgba(255,255,255,0.66);
  font-size: 13px;
}

.admin-login-box input {
  width: 100%;
  box-sizing: border-box;
  padding: 12px;
  border: 1px solid rgba(212,175,55,0.34);
  border-radius: 8px;
  background: rgba(0,0,0,0.42);
  color: #fff;
}

.admin-login-box .login-submit {
  margin-top: 18px;
}

@media (max-width: 900px) {
  .admin-shell {
    grid-template-columns: 1fr;
    max-height: none;
  }
  .admin-sidebar {
    flex-direction: row;
    overflow-x: auto;
    border-right: 0;
    border-bottom: 1px solid rgba(212,175,55,0.35);
  }
  .admin-nav-item {
    white-space: nowrap;
  }
  .admin-metrics {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }
  .admin-grid-two,
  .admin-login-layout {
    grid-template-columns: 1fr;
  }
  .admin-login-brand {
    min-height: auto;
  }
}

/* =====================================================
   ITEM DO COMPRADOR - VITRINE MODERNA
   ===================================================== */
.item-showcase-panel {
  width: min(94vw, 1120px);
  max-height: calc(var(--vh) * 94);
  margin-left: auto;
  margin-right: auto;
  box-shadow: 0 24px 70px rgba(0,0,0,0.45);
}

.item-showcase-header {
  min-height: 112px;
  display: grid;
  grid-template-columns: 48px minmax(0, 1fr);
  align-items: center;
  gap: 14px;
  padding: 18px 28px;
  background:
    linear-gradient(135deg, rgba(26,9,5,0.92), rgba(92,37,8,0.78)),
    rgba(0,0,0,0.2);
}

.item-showcase-header .title {
  margin: 4px 0 0;
  text-align: left;
  font-size: clamp(28px, 4vw, 46px);
  line-height: 1.06;
}

.item-back-button {
  position: static;
  width: 42px;
  height: 42px;
  border: 1px solid rgba(255,215,0,0.55);
  border-radius: 8px;
  background: rgba(0,0,0,0.35);
  color: var(--gold);
  display: inline-flex;
  align-items: center;
  justify-content: center;
  font-size: 26px;
}

.item-back-button:hover {
  background: rgba(255,215,0,0.12);
}

.item-header-copy {
  min-width: 0;
}

.item-eyebrow {
  display: block;
  max-width: 100%;
  overflow: hidden;
  color: rgba(255,255,255,0.64);
  font-size: 12px;
  font-weight: 800;
  text-overflow: ellipsis;
  text-transform: uppercase;
  white-space: nowrap;
}

.item-showcase {
  display: grid;
  grid-template-columns: minmax(220px, 290px) minmax(320px, 520px) minmax(240px, 310px);
  align-items: stretch;
  justify-content: center;
  gap: 16px;
  padding: 18px;
  overflow: auto;
}

.item-showcase::-webkit-scrollbar {
  width: 10px;
}

.item-showcase::-webkit-scrollbar-track {
  background: rgba(0,0,0,0.24);
}

.item-showcase::-webkit-scrollbar-thumb {
  background: rgba(212,175,55,0.5);
  border-radius: 8px;
}

.item-visual-card,
.item-buy-card,
.item-spec-section .item-stats {
  border: 1px solid rgba(212,175,55,0.34);
  border-radius: 8px;
  background:
    linear-gradient(180deg, rgba(12,14,22,0.86), rgba(7,7,10,0.74)),
    rgba(0,0,0,0.44);
  box-shadow: inset 0 1px 0 rgba(255,255,255,0.08);
}

.item-visual-card {
  display: flex;
  flex-direction: column;
  gap: 14px;
  padding: 16px;
}

.item-icon-stage {
  position: relative;
  width: 88px;
  height: 88px;
  min-height: 88px;
  align-self: center;
  border: 0;
  border-radius: 0;
  background-image: url("../images/wsdb_slot_frame.png");
  background-repeat: no-repeat;
  background-size: 264px 176px;
  background-position: 0 -88px;
  image-rendering: pixelated;
}

.item-icon-stage img {
  position: absolute;
  left: 14px;
  top: 12px;
  width: 60px;
  height: 60px;
  object-fit: contain;
  image-rendering: pixelated;
  filter: none;
}

.item-meta-grid {
  display: grid;
  gap: 8px;
}

.item-meta-grid div {
  display: grid;
  grid-template-columns: 92px minmax(0, 1fr);
  gap: 8px;
  align-items: center;
  padding: 10px;
  border-radius: 8px;
  background: rgba(255,255,255,0.045);
}

.item-meta-grid span,
.item-price-card span,
.item-buy-head p {
  color: rgba(255,255,255,0.66);
}

.item-meta-grid span,
.item-price-card span {
  font-size: 12px;
  font-weight: 800;
  text-transform: uppercase;
}

.item-meta-grid strong {
  min-width: 0;
  overflow: hidden;
  color: #fff;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.item-buy-card {
  grid-column: 3;
  display: flex;
  flex-direction: column;
  gap: 16px;
  justify-content: center;
  padding: 20px;
}

.item-buy-head {
  display: grid;
  gap: 8px;
}

.item-store-tag {
  width: max-content;
  padding: 5px 9px;
  border: 1px solid rgba(60,214,126,0.45);
  border-radius: 8px;
  background: rgba(60,214,126,0.12);
  color: #6ff0a5;
  font-size: 12px;
  font-weight: 900;
  text-transform: uppercase;
}

.item-buy-head p {
  margin: 0;
  font-size: 15px;
}

.item-price-stack {
  display: grid;
  grid-template-columns: 1fr;
  gap: 10px;
}

.item-price-card {
  display: grid;
  gap: 6px;
  padding: 12px;
  border: 1px solid rgba(255,255,255,0.1);
  border-radius: 0;
  background: rgba(255,255,255,0.055);
}

.item-price-card.primary {
  width: min(100%, 210px);
  grid-template-columns: 42px minmax(0, 1fr);
  align-items: center;
  gap: 8px;
  padding: 10px;
  border-color: rgba(255,215,0,0.35);
  background: transparent;
}

.item-price-card.primary span {
  font-size: 0;
  gap: 0;
  z-index: 2;
}

.item-price-card.primary strong {
  min-height: 36px;
  display: grid;
  align-items: center;
  padding: 4px 10px;
  border: 3px solid rgba(230,220,158,0.78);
  border-radius: 0;
  background: rgba(31,33,31,0.82);
  text-align: right;
}

.item-price-card.primary .price-icon.game-coin {
  margin-right: 0;
}

.item-price-card span {
  display: inline-flex;
  align-items: center;
  gap: 7px;
}

.item-price-card .price-icon.game-coin {
  width: 36px;
  height: 36px;
}

.item-price-card strong {
  color: #ffea00;
  font-family: var(--number-font);
  font-size: clamp(15px, 1.45vw, 20px);
  font-weight: 400;
  line-height: 1.35;
  letter-spacing: 0;
  -webkit-text-stroke: 1px #050505;
  text-shadow:
    -1px -1px 0 #111,
     1px -1px 0 #111,
    -1px  1px 0 #111,
     1px  1px 0 #111,
     0 2px 0 #050505;
}

.item-primary-buy {
  width: 100%;
  justify-content: center;
  min-height: 52px;
  border: 1px solid rgba(255,215,0,0.55);
  border-radius: 8px;
  background: linear-gradient(135deg, #118a52, #0d5f3a);
  color: #fff;
  font-size: 16px;
  font-weight: 900;
  text-transform: uppercase;
}

.item-primary-buy:hover {
  background: linear-gradient(135deg, #14a765, #0f7346);
}

.item-spec-section {
  grid-column: 2;
  grid-row: 1;
  min-width: 0;
}

.item-spec-section .item-stats {
  margin: 0;
  padding: 16px;
}

.outfit-preview-box {
  position: relative;
  grid-column: 2;
  grid-row: 1 / span 2;
  justify-self: center;
  width: min(100%, 520px);
  min-width: 0;
  border: 1px solid rgba(255,215,0,0.72);
  border-radius: 6px;
  background:
    linear-gradient(180deg, rgba(22,34,47,0.84), rgba(15,24,34,0.74)),
    rgba(0,0,0,0.55);
  box-shadow: inset 0 0 0 1px rgba(0,0,0,0.5);
  overflow: hidden;
}

.outfit-preview-title {
  min-height: 34px;
  display: grid;
  place-items: center;
  border-bottom: 1px solid rgba(255,215,0,0.6);
  background: rgba(30,30,40,0.82);
  color: #ffea00;
  font: 900 18px/1 "Arial Black", Impact, sans-serif;
  -webkit-text-stroke: 1px #111;
  text-shadow: 1px 1px 0 #000;
}

.outfit-preview-name {
  display: grid;
  grid-template-columns: 58px minmax(0, 1fr);
  align-items: center;
  gap: 10px;
  padding: 10px 14px;
  border-bottom: 1px solid rgba(255,215,0,0.42);
}

.outfit-preview-name img {
  width: 58px;
  height: 58px;
  object-fit: contain;
  border: 2px solid #f2d33d;
  background: rgba(0,0,0,0.45);
  image-rendering: pixelated;
}

.outfit-preview-name span {
  min-width: 0;
  font-size: 20px;
  font-weight: 900;
  line-height: 1.1;
  text-shadow: -1px 0 1px #000, 0 -1px 1px #000, 1px 0 1px #000, 0 1px 1px #000;
}

.outfit-controls {
  --outfit-slot-size: 76px;
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  justify-content: center;
  gap: 10px;
  padding: 10px 8px;
  border-bottom: 1px solid rgba(255,215,0,0.32);
  background:
    linear-gradient(180deg, rgba(255,255,255,0.04), rgba(0,0,0,0.18)),
    rgba(0,0,0,0.24);
}

.outfit-control-btn {
  border: 0;
  padding: 0;
  background: transparent;
  cursor: pointer;
  color: #ffe16a;
}

.outfit-control-btn:hover,
.outfit-control-btn:focus-visible {
  outline: none;
  filter: brightness(1.08);
}

.outfit-control-btn:active {
  transform: translateY(1px);
}

.outfit-reset-btn svg {
  position: relative;
  z-index: 1;
  width: 38px;
  height: 38px;
  fill: none;
  stroke: currentColor;
  stroke-width: 2;
  stroke-linecap: round;
  stroke-linejoin: round;
}

.outfit-slot-button {
  width: var(--outfit-slot-size);
  height: var(--outfit-slot-size);
  display: grid;
  place-items: center;
  position: relative;
  padding: 0 !important;
  border: 0 !important;
  border-radius: 0 !important;
  background-image: url("../images/wsdb_slot_frame.png");
  background-repeat: no-repeat;
  background-position: 0 calc(var(--outfit-slot-size) * -1);
  background-size: calc(var(--outfit-slot-size) * 3) calc(var(--outfit-slot-size) * 2);
  background-color: transparent !important;
  box-shadow: none !important;
  outline: none;
  text-shadow: none;
  image-rendering: pixelated;
}

.outfit-preview-box .outfit-slot-button,
.outfit-preview-box .outfit-slot-button:hover,
.outfit-preview-box .outfit-slot-button:focus-visible,
.outfit-preview-box .outfit-slot-button.is-selected {
  border: 0 !important;
  border-radius: 0 !important;
  background-image: url("../images/wsdb_slot_frame.png");
  background-repeat: no-repeat;
  background-size: calc(var(--outfit-slot-size) * 3) calc(var(--outfit-slot-size) * 2);
  background-color: transparent !important;
  box-shadow: none !important;
  outline: none;
}

.outfit-slot-button::before {
  content: "";
  position: absolute;
  left: 16%;
  top: 15%;
  width: 68%;
  height: 68%;
  border-radius: 5px;
  background:
    radial-gradient(circle at 50% 38%, rgba(255,255,255,0.10), transparent 38%),
    linear-gradient(180deg, #2a2519, #11180e 58%, #071007);
  box-shadow: inset 0 0 12px rgba(0,0,0,0.88);
}

.outfit-slot-button:active,
.outfit-slot-button.is-selected {
  background-position: 0 0;
}

.outfit-wsdb-icon {
  position: relative;
  z-index: 1;
  display: block;
  width: 52px;
  height: 52px;
  background-position: center;
  background-repeat: no-repeat;
  background-size: contain;
  image-rendering: pixelated;
  image-rendering: crisp-edges;
}

.outfit-wsdb-icon-hair {
  background-image: url("https://wsdb.xyz/icons/1858.webp");
}

.outfit-wsdb-icon-palette {
  background-image: url("https://wsdb.xyz/icons/1859.webp");
}

.outfit-wsdb-gender-icon {
  width: 54px;
  height: 54px;
  background-image: url(data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAABYAAAAsCAYAAABhVUjwAAAABHNCSVQICAgIfAhkiAAABUJJREFUSIm1lyFsI0sShr/dMygQUMDSNlhpByxo8MCAAIMFAx4weMBggcEDBgcCDgQuOBAY8EDgggMGBwwDHhhwwGDBnBQwIGDAntQgoJ8UUMCggKU7MLaTOHbeKtIVGml6vvm7q+rv7jcfPnz4L/+HGLzmIxEBBADff+n2SrA7OrtEywoFgjhRoVBIKXP15Ry3/DrFuIM7BqgIpgEJEFEQAX+NYhHs+gqrv4IIPr0kSwAguO/W5u1LqvpxiiP9+I1St4ybEcbn6GiEdS1tl8j9IOCQYnfQQDGqKKsK0QJzxyyTu5bc1Lg7xewKHVVY05AXX5DZJZ1Etkkd7EOlKMlxgo8qzmYRc8jW60g+oW2n5OxILLG2Ic/PcDMQ3Sju482ujjdQG834A+WdZwpr8dTg7kiIhGqKlJNeVOpor2aQE4ii1QQRxZYL3O1BsYji5ZQ/CLzLDdrOyWb91AQ8L7G2QauGYvqFWChJA5YT4Fg93yX3afJiiWnBBzLaLTbTk+2S7Z5tOSfXc0IIlOMpvgH172WHe7tLWFGBCJIaPOcng56GkJdzcjbiqEI0HBz1oFgVFcDyEeCOC+6krqOIgSDSCzsKFkVVX4bu8Uvd+sYLihUnFAUSDk9tn1rGgGXDzF4GkxpEBB2NN/3+fHpAX5axYtFmzq8WPfiA6h4sQm6ukdwRqzFhfP4A3/5g8yyxwuKEfycjNfXOJvfjL6p6AcBqxcoSp9XPfPxU4SeR1abQ1wyQ4idOTn/hPn7GOaG4b+D2dxgc9rE3T3YQd0I1ZvzlEtFAlyF3HbiTHZI5WEbTEul6zzgWD4oBBgNW3zu6bzWs15zoEBkOWa2Fu+/fkfsOvfkn69t/sT6KPKT4cbiDCFoUgPRW+WLj/Cj48Q/gh4Hb+NMdZIfb/MB55B+vAYs5UZSogRAUB9yMzozWDNeX6Qd3kOAwG42YjMdoCMhWrTs5G8u2YdE0JMCP8PfKDUbA+XTKaDIGh9S25JzBnSIUhDJCLGiva+ZXX7nmcOc9UVxsodMJnjKLxYK6aXE3sghBhHEomJyfUZ6fMRMhXVyScGwP/lDH7sziKZ9nv2Lpjr//9hvztiUNnDwQVgLZ19zkO+zmhp/iRz5+HsNt4lvX4TI4DC7WA84/TxgOh8znc/5xe8tapW/Z7TcDWMuAu/8YJ/eZ902L5jtuVivyXsvs3C2KEosCS4m67eCFrOd3wjIlurYjd5mo4Zkbvt0mTbTfs3LO2POj3pMQgeyOC6gqhQiy98lGsT/UvCr6MncXKgqqB2U8+LH1OkOML/o89PUcN1UiInRuD7v1U8VgZnRti45KqqpC/fiCqEMVCoIIrkKb87NG2YET0DQtALPLCyaxJBrPT9bmjIuCcSwQVZY5kd0pzAn2MHhXbs6A9V3i/YlSvA+c/N4wHAhDAVk5YQ3FGn49PeVvnz6hwPLe+PptSVTlbFQxsBV3bvhgcKilhWkZ0WS9b4TQl54KqkoQBRxzuGiWBA3MqooQC+rrmsv6mqSyZ0ICrRs0LVWMFBKQoAigQXGHZEbYqDgbjYiiINB1HdddS96s9VGjDw4BKFQBQVVou0RQ5WI0IuCAYMAiJRapo8N3B5ijfpwFMtBan0HNUBWRs7LsFW9uTp0b864lb0rvWfKOxgB0teZyPOGvv/xM0BO6lXFjxkcdMtyYz839HetHR4Hjd5BHIdLfjkSEukuc1zUXdc0yJyQUTMZjRsiT0vyhW1MW4XJZE9uGOiWyCkGgblpiWdK0Xc981CR/vks/js2RYBvB+32xNeuN/hH4f4u+m4j3G5JNAAAAAElFTkSuQmCC);
  background-position: 0 0;
  background-size: 54px 108px;
}

.outfit-wsdb-gender-female {
  background-position: 0 -54px;
}

.outfit-reset-btn {
  color: #ffe16a;
}

.outfit-controls.is-loading .outfit-control-btn {
  opacity: 0.72;
  cursor: progress;
}

.outfit-picker-host {
  position: fixed;
  inset: 0;
  pointer-events: none;
  z-index: 1200;
}

.outfit-picker {
  position: absolute;
  inset: 0;
  display: grid;
  place-items: start center;
  padding: max(18px, env(safe-area-inset-top)) 14px 14px;
  background: rgba(3, 10, 18, 0.46);
  pointer-events: auto;
}

.outfit-picker-panel {
  width: min(100%, 604px);
  max-height: min(86%, 694px);
  display: grid;
  grid-template-rows: auto minmax(0, 1fr);
  container-type: inline-size;
  overflow: hidden;
  border: 2px solid #d4af37;
  background:
    linear-gradient(180deg, rgba(18, 33, 49, 0.92), rgba(9, 23, 38, 0.90)),
    rgba(0,0,0,0.62);
  box-shadow: 0 10px 24px rgba(0,0,0,0.55);
}

.outfit-picker-title {
  min-height: 40px;
  display: grid;
  grid-template-columns: 1fr 42px;
  align-items: center;
  border-bottom: 2px solid #d4af37;
  background: rgba(24, 25, 36, 0.86);
  color: #ffea00;
  font: 900 20px/1 "Arial Black", Impact, sans-serif;
  text-align: center;
  -webkit-text-stroke: 1px #111;
  text-shadow: 1px 1px 0 #000;
}

.outfit-picker-close {
  width: 42px;
  height: 40px;
  border: 0;
  border-left: 1px solid rgba(255,215,0,0.48);
  background: transparent;
  color: #ffe16a;
  font: 900 24px/1 Arial, sans-serif;
  cursor: pointer;
  text-shadow: 1px 1px 0 #000;
}

.outfit-picker-content {
  min-height: 180px;
  overflow-y: auto;
  overflow-x: hidden;
  padding: 14px 18px;
}

.outfit-picker-grid {
  display: grid;
  grid-template-columns: repeat(4, 88px);
  justify-content: space-between;
  justify-items: center;
  gap: 14px 18px;
}

.outfit-picker-grid.compact {
  grid-template-columns: repeat(2, 88px);
  justify-content: center;
}

.outfit-picker-option {
  --outfit-slot-size: 88px;
}

.outfit-picker-preview {
  position: relative;
  z-index: 1;
  width: 62px;
  height: 62px;
  object-fit: contain;
  object-position: center;
  image-rendering: pixelated;
  image-rendering: crisp-edges;
}

.outfit-picker-preview:not([src]) {
  opacity: 0.35;
}

.outfit-picker-loading {
  min-height: 180px;
  display: grid;
  place-items: center;
  color: #ffea00;
  font-weight: 900;
  text-shadow: 1px 1px 0 #000;
}

@container (max-width: 430px) {
  .outfit-picker-grid {
    grid-template-columns: repeat(2, 88px);
    justify-content: space-around;
  }
}

.outfit-stage {
  min-height: 400px;
  display: grid;
  place-items: center;
  background:
    linear-gradient(rgba(255,255,255,0.025) 1px, transparent 1px),
    linear-gradient(90deg, rgba(255,255,255,0.025) 1px, transparent 1px),
    rgba(18,30,43,0.66);
  background-size: 24px 24px;
}

.outfit-canvas {
  width: 180px;
  height: 210px;
  transform: translateY(-72px);
  image-rendering: pixelated;
  image-rendering: crisp-edges;
}

.item-spec-section .stat-header {
  padding: 0 0 12px;
  margin-bottom: 8px;
  border-bottom: 1px solid rgba(255,215,0,0.28);
  color: #fff;
  font-size: 15px;
}

.rarity-pill {
  display: inline-flex;
  align-items: center;
  min-height: 26px;
  padding: 3px 10px;
  border-radius: 8px;
  background: rgba(255,255,255,0.1);
  color: #fff;
  font-size: 12px;
  font-weight: 900;
  text-transform: uppercase;
}

.rarity-1 { background: rgba(65,196,102,0.18); color: #8af2a6; }
.rarity-2 { background: rgba(76,154,255,0.18); color: #99c5ff; }
.rarity-3 { background: rgba(154,105,255,0.2); color: #c4a6ff; }
.rarity-4 { background: rgba(255,158,58,0.2); color: #ffc37b; }
.rarity-5 { background: rgba(255,76,76,0.2); color: #ff9a9a; }

.rarity-name-0 { color: #d6d6d6 !important; }
.rarity-name-1 { color: #61f06f !important; }
.rarity-name-2 { color: #7cb7ff !important; }
.rarity-name-3 { color: #ff64ff !important; }
.rarity-name-4 { color: #ff6464 !important; }
.rarity-name-5 { color: #ffd94f !important; }
.rarity-name-6 { color: #ff9e3a !important; }

.visual-stats .stat-section,
.visual-stats .stat-row {
  display: none;
}

.item-spec-section .stat-row {
  display: grid;
  grid-template-columns: minmax(0, 1fr) auto;
  gap: 14px;
  align-items: center;
  min-height: 46px;
  padding: 8px 0;
  border-bottom: 1px solid rgba(255,255,255,0.06);
}

.item-spec-section .stat-label {
  min-width: 0;
  display: inline-flex;
  align-items: center;
  gap: 10px;
  color: rgba(255,255,255,0.72);
}

.item-spec-section .stat-icon {
  width: 30px;
  height: 30px;
  border-radius: 6px;
  background: rgba(0,0,0,0.32);
}

.item-spec-section .stat-value {
  color: #fff;
  font-size: 26px;
  font-weight: 900;
}

.item-spec-section .stat-section {
  margin-top: 12px;
  padding-top: 10px;
  color: var(--gold);
  font-size: 12px;
}

.empty-stats {
  min-height: 72px;
}

.item-showcase-footer {
  display: flex;
  justify-content: flex-start;
  padding: 12px 18px;
}

@media (max-width: 940px) {
  .item-showcase-panel {
    width: 96vw;
    max-height: none;
  }

  .item-showcase-header {
    grid-template-columns: 42px minmax(0, 1fr);
    min-height: 92px;
    padding: 14px 16px;
  }

  .item-showcase {
    grid-template-columns: 1fr;
    padding: 12px;
  }

  .item-visual-card {
    order: 1;
  }

  .item-spec-section {
    order: 2;
    grid-column: 1;
    grid-row: auto;
  }

  .outfit-preview-box {
    order: 2;
    grid-column: 1;
    grid-row: auto;
  }

  .item-buy-card {
    order: 3;
    grid-column: 1;
  }

  .item-icon-stage {
    min-height: 88px;
  }

  .item-price-stack {
    grid-template-columns: 1fr;
  }

  .item-meta-grid div {
    grid-template-columns: 82px minmax(0, 1fr);
  }
}

/* =====================================================
   ADMIN - FORMULARIO LIMPO DE ITEM
   ===================================================== */
.modal {
  width: min(94vw, 880px);
  border: 1px solid rgba(255,215,0,0.62);
  border-radius: 8px;
  background:
    linear-gradient(180deg, rgba(7,8,12,0.92), rgba(5,5,8,0.78)),
    rgba(0,0,0,0.72);
  box-shadow: 0 24px 80px rgba(0,0,0,0.55);
  backdrop-filter: blur(10px);
}

.item-form-modern {
  display: grid;
  gap: 16px;
  color: var(--gold);
}

.item-form-head {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  gap: 14px;
  padding-bottom: 12px;
  border-bottom: 1px solid rgba(212,175,55,0.22);
}

.item-form-head span {
  display: block;
  color: rgba(255,255,255,0.58);
  font-size: 12px;
  font-weight: 800;
  text-transform: uppercase;
}

.item-form-head h2 {
  margin: 3px 0 0;
  color: var(--gold);
  font-size: 30px;
  line-height: 1.1;
}

.item-form-hidden {
  display: none;
}

.item-field {
  display: grid;
  gap: 7px;
  color: rgba(255,255,255,0.7);
  font-size: 12px;
  font-weight: 800;
  text-transform: uppercase;
}

.item-field-full {
  width: 100%;
}

.item-field input,
.item-field textarea {
  width: 100%;
  box-sizing: border-box;
  border: 1px solid rgba(212,175,55,0.26);
  border-radius: 8px;
  background: rgba(255,255,255,0.055);
  color: #fff;
  font-size: 15px;
  outline: none;
}

.item-field input {
  min-height: 44px;
  padding: 10px 12px;
}

.item-field textarea {
  min-height: 96px;
  padding: 12px;
  resize: vertical;
}

.item-field input:focus,
.item-field textarea:focus {
  border-color: rgba(255,215,0,0.72);
  box-shadow: 0 0 0 3px rgba(255,215,0,0.08);
}

.item-form-modern .autocomplete-wrap {
  width: 100%;
}

.item-form-modern .autocomplete-dropdown {
  background: rgba(13,14,22,0.96);
  backdrop-filter: blur(10px);
}

.item-selected-card {
  display: grid;
  grid-template-columns: 58px minmax(0, 1fr);
  gap: 12px;
  align-items: center;
  min-height: 76px;
  padding: 12px;
  border: 1px solid rgba(212,175,55,0.25);
  border-radius: 8px;
  background: rgba(255,255,255,0.045);
}

.item-selected-card.is-empty {
  border-style: dashed;
  opacity: 0.84;
}

.item-selected-thumb {
  position: relative;
  width: 66px;
  height: 66px;
  display: block;
  border: 0;
  border-radius: 0;
  background-image: url("../images/wsdb_slot_frame.png");
  background-repeat: no-repeat;
  background-size: 198px 132px;
  background-position: 0 -66px;
  image-rendering: pixelated;
}

.item-selected-thumb b,
.item-icon-stage b {
  position: absolute;
  top: 7px;
  left: 8px;
  color: #ffea00;
  font: 900 16px/1 "Arial Black", Impact, sans-serif;
  -webkit-text-stroke: 1px #111;
  text-shadow: 1px 1px 0 #111;
}

.item-icon-stage b {
  top: 9px;
  left: 10px;
}

.item-selected-thumb img {
  position: absolute;
  left: 10px;
  top: 9px;
  width: 45px;
  height: 45px;
  object-fit: contain;
  image-rendering: pixelated;
}

.item-selected-card strong,
.item-selected-card span {
  display: block;
  min-width: 0;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.item-selected-card strong {
  color: #fff;
  font-size: 16px;
}

.item-selected-card span {
  margin-top: 3px;
  color: rgba(255,255,255,0.58);
  font-size: 12px;
}

.item-form-grid {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: 12px;
}

.item-form-modern .form-actions {
  display: flex;
  justify-content: flex-end;
  gap: 10px;
  margin-top: 2px;
  padding-top: 14px;
  border-top: 1px solid rgba(212,175,55,0.18);
}

@media (max-width: 760px) {
  .modal {
    width: 94vw;
    padding: 14px;
  }

  .item-form-head h2 {
    font-size: 24px;
  }

  .item-form-grid {
    grid-template-columns: 1fr 1fr;
  }
}

@media (max-width: 460px) {
  .item-form-grid {
    grid-template-columns: 1fr;
  }
}

/* =====================================================
   ADMIN/VENDEDOR - LISTA DE ANUNCIOS
   ===================================================== */
.admin-card .market-ad-list,
.market-ad-list {
  display: grid;
  gap: 6px;
}

.admin-card .market-ad-row,
.market-ad-row {
  display: grid !important;
  grid-template-columns: 72px minmax(260px, 1fr) 168px 92px;
  align-items: center;
  gap: 10px;
  min-height: 78px;
  padding: 8px 10px;
  border: 0;
  border-radius: 0;
  background: rgba(25,25,32,0.34);
}

.market-ad-row:hover {
  border-color: rgba(255,215,0,0.4);
  background: rgba(255,215,0,0.055);
}

.market-ad-icon {
  width: 72px;
  height: 72px;
  display: block;
  border: 0;
  border-radius: 0;
  background-image: url("../images/wsdb_slot_frame.png");
  background-repeat: no-repeat;
  background-size: 216px 144px;
  background-position: 0 -72px;
  image-rendering: pixelated;
}

.market-ad-icon img {
  position: absolute;
  left: 11px;
  top: 10px;
  width: 49px;
  height: 49px;
  object-fit: contain;
  image-rendering: pixelated;
}

.market-ad-info {
  min-width: 0;
}

.market-ad-info strong,
.market-ad-info span,
.market-ad-info small {
  display: block;
  min-width: 0;
  overflow: hidden;
  text-overflow: ellipsis;
}

.market-ad-info strong {
  color: #f173ff;
  font-size: 20px;
  line-height: 1.18;
}

.market-ad-info small {
  margin-top: 7px;
  color: #ff6d7a;
  font-size: 16px;
  white-space: nowrap;
}

.market-ad-info span { display: none; }

.market-ad-price {
  justify-self: end;
  width: 178px;
  min-width: 178px;
  display: grid;
  grid-template-columns: 42px minmax(0, 1fr);
  align-items: center;
  gap: 8px;
  padding: 0;
  border: 0;
  background: transparent;
  box-shadow: none;
}

.market-coin-dot {
  width: 36px;
  height: 36px;
  z-index: 2;
  margin-right: 0;
  border-radius: 50%;
  background-image: url("../images/uploads/gold_coin.png");
  background-position: left top;
  background-repeat: no-repeat;
  background-size: 188.235% 188.235%;
  border: 0;
  box-shadow: none;
}

.market-ad-price > div {
  min-height: 42px;
  display: grid;
  align-items: center;
  padding: 5px 10px;
  border: 3px solid rgba(230,220,158,0.78);
  border-radius: 0;
  background: rgba(31,33,31,0.82);
  box-shadow: inset 0 0 0 1px rgba(0,0,0,0.55);
}

.market-ad-icon {
  position: relative;
}

.market-ad-icon b {
  position: absolute;
  top: 7px;
  left: 8px;
  color: #ffea00;
  font: 900 15px/1 "Arial Black", Impact, sans-serif;
  -webkit-text-stroke: 1px #111;
  text-shadow: 1px 1px 0 #111;
}

.game-market-row {
  position: relative;
  display: grid;
  grid-template-columns: 82px minmax(0, 1fr) 190px;
  align-items: center;
  gap: 10px;
  min-height: 88px;
  padding: 8px 42px 8px 12px;
  border-bottom: 1px solid rgba(255,215,0,0.65);
  background: rgba(38,44,58,0.34);
  cursor: pointer;
  transition: transform 0.18s ease, background 0.18s ease;
}

.game-market-row:hover {
  background: rgba(96,108,140,0.32);
  transform: translateY(-4px);
}

.game-market-name {
  color: #7cb7ff;
  font-size: 21px;
  line-height: 1.12;
  text-shadow: -1px 0 1px #000, 0 -1px 1px #000, 1px 0 1px #000, 0 1px 1px #000;
}

.game-market-copy {
  min-width: 0;
  overflow: hidden;
}

.game-market-copy .game-market-name {
  display: -webkit-box;
  overflow: hidden;
  text-overflow: ellipsis;
  -webkit-box-orient: vertical;
  -webkit-line-clamp: 2;
}

.game-market-fav {
  position: absolute;
  right: 10px;
  top: 10px;
  width: 28px;
  height: 28px;
  border: 0;
  background: transparent;
  cursor: pointer;
  font-size: 22px;
  line-height: 1;
  padding: 0;
  filter: drop-shadow(0 2px 2px #000);
}

.visual-stats .stat-visual-grid {
  display: flex;
  flex-wrap: wrap;
  gap: 12px;
  padding-top: 10px;
}

.stat-visual-card,
.ac-stat-box {
  width: 72px;
  height: 72px;
  display: block;
  position: relative;
  background-image: url("../images/wsdb_slot_frame.png");
  background-repeat: no-repeat;
  background-size: 216px 144px;
  background-position: 0 -72px;
  image-rendering: pixelated;
}

.ac-stat-box {
  width: 56px;
  height: 56px;
  background-size: 168px 112px;
  background-position: 0 -56px;
}

.stat-visual-card img,
.ac-stat-box img {
  position: absolute;
  left: 15px;
  top: 12px;
  width: 42px;
  height: 42px;
  object-fit: contain;
  image-rendering: pixelated;
}

.ac-stat-box img {
  left: 9px;
  top: 8px;
  width: 32px;
  height: 32px;
}

.stat-visual-card strong,
.ac-stat-box strong {
  position: absolute;
  right: 7px;
  bottom: 6px;
  color: #fff;
  font: 900 15px/1 "Arial Black", Impact, sans-serif;
  -webkit-text-stroke: 1px #111;
  text-shadow: 1px 1px 0 #111;
}

@media (max-width: 520px) {
  .game-market-row {
    grid-template-columns: 68px minmax(0, 1fr) 132px;
    padding-right: 34px;
  }
  .game-market-name {
    font-size: 17px;
  }
}

.market-ad-price strong {
  display: block;
  color: #ffea00;
  font-family: var(--number-font);
  font-size: 17px;
  font-weight: 400;
  line-height: 1.35;
  letter-spacing: 0;
  text-align: right;
  -webkit-text-stroke: 1px #050505;
  text-shadow:
    -1px -1px 0 #111,
     1px -1px 0 #111,
    -1px  1px 0 #111,
     1px  1px 0 #111,
     0 2px 0 #050505;
}

.market-ad-price small {
  display: none;
  color: rgba(255,255,255,0.58);
  font-size: 11px;
  white-space: nowrap;
}

.market-ad-actions {
  display: grid;
  gap: 5px;
}

.market-ad-actions .admin-button {
  min-width: 76px;
  padding: 5px 10px;
  font-size: 12px;
}

@media (max-width: 820px) {
  .market-ad-row {
    grid-template-columns: 64px minmax(0, 1fr) 160px;
  }

  .market-ad-actions {
    grid-column: 2 / -1;
    grid-template-columns: repeat(2, max-content);
    justify-content: end;
  }
}

@media (max-width: 520px) {
  .market-ad-row {
    grid-template-columns: 58px minmax(0, 1fr) 118px;
    align-items: start;
  }

  .market-ad-icon {
    width: 58px;
    height: 58px;
    background-size: 174px 116px;
    background-position: 0 -58px;
  }

  .market-ad-icon img {
    left: 9px;
    top: 8px;
    width: 39px;
    height: 39px;
  }

  .market-ad-icon b {
    top: 5px;
    left: 6px;
    font-size: 12px;
  }

  .market-ad-price {
    grid-column: 3;
    justify-self: end;
    width: 132px;
    min-width: 132px;
    grid-template-columns: 32px minmax(0, 1fr);
    padding: 0;
  }

  .market-coin-dot {
    width: 28px;
    height: 28px;
    margin-right: 0;
  }

  .market-ad-price > div {
    min-height: 34px;
    padding: 4px 8px;
    border-width: 2px;
  }

  .market-ad-price strong {
    font-size: 12px;
  }

  .market-ad-actions {
    grid-column: 2;
    justify-content: stretch;
  }

  .market-ad-actions .admin-button {
    min-width: 0;
  }
}

/* Ajustes finais de mercado/detalhe - 2026-06-29 */
.items-toolbar {
  display: flex;
  justify-content: flex-end;
  padding: 0 0 8px;
}

.favorites-link {
  min-height: 36px;
  padding: 6px 12px;
  border-radius: 6px;
}

.item-price-card.primary {
  width: min(100%, 250px);
  grid-template-columns: 42px minmax(0, 1fr);
}

.item-price-card.primary strong,
.market-ad-price > div {
  height: 36px;
  min-height: 36px;
  box-sizing: border-box;
  border-radius: 5px;
  padding: 2px 8px;
}

.item-price-card strong,
.market-ad-price strong {
  white-space: nowrap;
  overflow: hidden;
  text-overflow: clip;
  color: #ffea00;
  font-family: var(--number-font);
  font-variant-numeric: tabular-nums lining-nums;
  font-feature-settings: "tnum" 1, "lnum" 1;
  font-weight: 700;
  letter-spacing: 0;
  -webkit-text-stroke: 0;
  text-shadow:
    1px 0 0 #050505,
    0 1px 0 #050505,
    2px 2px 0 #000,
    0 0 4px rgba(255, 234, 0, 0.2);
}

.item-price-card strong.gold-fit-lg,
.market-ad-price strong.gold-fit-lg {
  font-size: 15px;
}

.item-price-card strong.gold-fit-xl,
.market-ad-price strong.gold-fit-xl {
  font-size: 13px;
}

.item-price-card strong.gold-fit-compact,
.market-ad-price strong.gold-fit-compact {
  font-size: 16px;
  letter-spacing: 0.02em;
}

.gold-amount-inline {
  color: #ffea00;
  font-family: var(--number-font);
  font-variant-numeric: tabular-nums lining-nums;
  font-feature-settings: "tnum" 1, "lnum" 1;
  font-weight: 700;
  white-space: nowrap;
  text-shadow:
    1px 0 0 #050505,
    0 1px 0 #050505,
    2px 2px 0 #000,
    0 0 4px rgba(255, 234, 0, 0.2);
}

.game-market-row {
  grid-template-columns: 82px minmax(0, 1fr) minmax(210px, 224px);
}

.market-ad-price {
  width: 210px;
  min-width: 210px;
}

.stat-visual-card strong,
.ac-stat-box strong,
.ac-mini-stat b {
  right: 4px;
  bottom: 4px;
  min-width: 22px;
  height: 18px;
  display: grid;
  place-items: center;
  padding: 0 2px;
  border-radius: 4px;
  background: rgba(0,0,0,0.28);
  box-sizing: border-box;
}

.ac-mini-stat b {
  right: 2px;
  bottom: 2px;
  min-width: 14px;
  height: 11px;
  border-radius: 3px;
  font-size: 9px;
  -webkit-text-stroke: 0.6px #111;
}

.stat-skill-card em {
  position: absolute;
  left: 4px;
  right: 4px;
  bottom: 4px;
  display: block;
  overflow: hidden;
  color: #fff;
  font-size: 9px;
  font-style: normal;
  font-weight: 900;
  line-height: 1.05;
  text-align: center;
  text-overflow: ellipsis;
  text-shadow: 1px 1px 0 #111;
  white-space: nowrap;
}

.item-field select,
.form-row select,
.accordion-filters select {
  min-height: 44px;
  border: 1px solid rgba(212,175,55,0.26);
  border-radius: 8px;
  background: #08090d;
  color: #fff;
  color-scheme: dark;
}

.item-field select option,
.form-row select option,
.accordion-filters select option {
  background: #08090d;
  color: #fff;
}

@media (max-width: 520px) {
  .game-market-row {
    grid-template-columns: 58px minmax(0, 1fr) 142px;
  }

  .market-ad-price {
    width: 138px;
    min-width: 138px;
  }

  .market-ad-price > div {
    height: 28px;
    min-height: 28px;
    padding: 2px 5px;
  }

  .market-ad-price strong.gold-fit-xl,
  .item-price-card strong.gold-fit-xl {
    font-size: 9px;
  }

  .market-ad-price strong.gold-fit-compact,
  .item-price-card strong.gold-fit-compact {
    font-size: 13px;
  }
}

/* =====================================================
   ITEM FILTERS BAR (Sort/Filter/Pagination/Sold Out)
   ===================================================== */
.items-filters-bar {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  padding: 10px 0;
  align-items: center;
}

.items-sort-filter-bar {
  margin: 8px 0 12px;
  padding: 12px;
  border: 1px solid rgba(212,175,55,0.2);
  border-radius: 8px;
  background: rgba(12,14,22,0.5);
}

.sort-filter-row {
  display: flex;
  flex-wrap: wrap;
  gap: 12px;
  align-items: flex-end;
}

.sort-filter-group {
  display: flex;
  flex-direction: column;
  gap: 4px;
  min-width: 120px;
}

.sort-filter-group label {
  font-size: 11px;
  font-weight: 800;
  text-transform: uppercase;
  color: rgba(255,255,255,0.55);
  letter-spacing: 0.5px;
}

.sort-filter-group select,
.sort-filter-group input {
  min-height: 36px;
  padding: 4px 10px;
  border: 1px solid rgba(212,175,55,0.26);
  border-radius: 6px;
  background: #08090d;
  color: #fff;
  color-scheme: dark;
  font-size: 13px;
}

.sort-filter-group select option {
  background: #08090d;
  color: #fff;
}

.sort-filter-group.price-range {
  min-width: 200px;
}

.price-range-inputs {
  display: flex;
  align-items: center;
  gap: 6px;
}

.price-range-inputs input {
  width: 80px;
  min-height: 36px;
  padding: 4px 8px;
  border: 1px solid rgba(212,175,55,0.26);
  border-radius: 6px;
  background: #08090d;
  color: #fff;
  color-scheme: dark;
  font-size: 13px;
  -moz-appearance: textfield;
}

.price-range-inputs input::-webkit-outer-spin-button,
.price-range-inputs input::-webkit-inner-spin-button {
  -webkit-appearance: none;
  margin: 0;
}

.price-range-sep {
  color: rgba(255,255,255,0.4);
  font-size: 14px;
}

.esgotado-badge-detail {
  position: absolute;
  bottom: 2px;
  left: 50%;
  transform: translateX(-50%);
  z-index: 5;
  color: #ff4444;
  font: 900 12px/1 "Arial Black", Impact, sans-serif;
  text-align: center;
  text-shadow:
    -1px -1px 0 #000,
     1px -1px 0 #000,
    -1px  1px 0 #000,
     1px  1px 0 #000,
     0 0 4px #000;
  background: rgba(0,0,0,0.7);
  padding: 3px 6px;
  border-radius: 3px;
  white-space: nowrap;
  letter-spacing: 0.5px;
}

/* Load more button */
.load-more-wrapper {
  text-align: center;
  padding: 16px 0 8px;
}

.load-more-wrapper .login-btn {
  min-width: 200px;
  padding: 12px 24px;
  font-size: 15px;
  font-weight: 800;
}

.load-more-wrapper .login-btn:disabled {
  opacity: 0.5;
  cursor: default;
}

/* Responsivo: sort/filter bar */
@media (max-width: 640px) {
  .sort-filter-row {
    flex-direction: column;
    gap: 10px;
  }

  .sort-filter-group {
    width: 100%;
    min-width: 0;
  }

  .sort-filter-group.price-range {
    width: 100%;
    min-width: 0;
  }

  .price-range-inputs {
    width: 100%;
  }

  .price-range-inputs input {
    flex: 1;
    width: auto;
  }
}
.items-filters-bar select,
.items-filters-bar input {
  padding: 7px 10px;
  border: 1px solid var(--gold-border);
  background: rgba(0,0,0,0.5);
  color: var(--gold);
  border-radius: 6px;
  font-size: 13px;
}
.items-filters-bar input[type="number"] {
  width: 80px;
}
.items-filters-bar label {
  font-size: 12px;
  color: rgba(255,215,0,0.7);
  white-space: nowrap;
}

/* =====================================================
   SOLD OUT BADGE — consolidated below
   ===================================================== */

/* =====================================================
   LOAD MORE BUTTON
   ===================================================== */
.load-more-btn {
  display: block;
  width: 100%;
  padding: 12px;
  margin: 12px 0;
  border: 1px solid var(--gold-border);
  background: rgba(96,96,160,0.4);
  color: var(--gold);
  font-weight: 700;
  font-size: 14px;
  border-radius: 6px;
  cursor: pointer;
  transition: background 0.2s;
  text-align: center;
}
.load-more-btn:hover {
  background: rgba(150,200,255,0.3);
}
.load-more-btn:disabled {
  opacity: 0.4;
  cursor: default;
}

/* =====================================================
   SHARE BUTTON
   ===================================================== */
.btn-share {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  padding: 8px 14px;
  border: 1px solid var(--gold-border);
  background: rgba(96,160,96,0.4);
  color: var(--gold);
  font-weight: 700;
  font-size: 13px;
  border-radius: 6px;
  cursor: pointer;
  transition: background 0.2s;
}
.btn-share:hover {
  background: rgba(150,255,150,0.25);
}

/* =====================================================
   RECENTLY VIEWED
   ===================================================== */
.recently-viewed-section {
  margin-bottom: 16px;
}
.recently-viewed-title {
  font-size: 12px;
  color: rgba(255,215,0,0.6);
  margin-bottom: 8px;
  text-transform: uppercase;
  letter-spacing: 1px;
}
.recently-viewed-row {
  display: flex;
  gap: 10px;
  overflow-x: auto;
  padding-bottom: 8px;
}
.recently-viewed-item {
  flex: 0 0 auto;
  width: 64px;
  text-align: center;
  cursor: pointer;
  transition: transform 0.15s;
}
.recently-viewed-item:hover {
  transform: scale(1.08);
}
.recently-viewed-item img {
  width: 48px;
  height: 48px;
  object-fit: contain;
  border: 1px solid rgba(255,215,0,0.3);
  border-radius: 6px;
  background: rgba(0,0,0,0.4);
  display: block;
  margin: 0 auto 4px;
}
.recently-viewed-item span {
  font-size: 10px;
  color: var(--gold);
  display: block;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}

/* =====================================================
   SEARCH BAR IN HEADER
   ===================================================== */
.header-search {
  display: flex;
  gap: 8px;
  align-items: center;
  margin-top: 8px;
}
.header-search input {
  flex: 1;
  padding: 8px 12px;
  border: 1px solid var(--gold-border);
  background: rgba(0,0,0,0.5);
  color: var(--gold);
  border-radius: 6px;
  font-size: 14px;
  min-width: 0;
}
.header-search button {
  padding: 8px 16px;
  border: 1px solid var(--gold-border);
  background: rgba(96,96,160,0.5);
  color: var(--gold);
  font-weight: 700;
  border-radius: 6px;
  cursor: pointer;
  white-space: nowrap;
}

/* =====================================================
   PAGINATION INFO
   ===================================================== */
.pagination-info {
  text-align: center;
  font-size: 12px;
  color: rgba(255,215,0,0.5);
  padding: 8px 0;
}

/* Botões compactos de estoque rápido (+/-) */
.stock-btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 20px;
  height: 20px;
  border: 1px solid var(--gold-border);
  background: rgba(0,0,0,0.5);
  color: var(--gold);
  font-size: 14px;
  font-weight: 700;
  line-height: 1;
  border-radius: 4px;
  cursor: pointer;
  padding: 0;
  vertical-align: middle;
  transition: background 0.15s;
}
.stock-btn:hover {
  background: rgba(96,160,96,0.5);
}
.stock-btn:first-of-type:hover {
  background: rgba(160,96,96,0.5);
}
.stock-qty {
  display: inline-block;
  min-width: 24px;
  text-align: center;
  font-weight: 700;
  color: #fff;
  vertical-align: middle;
}

/* =====================================================
   ACABAMENTO RPG - CONTROLES, MODAIS, CUPONS E DETALHES
   ===================================================== */
:root {
  --rpg-panel-blue: rgba(6, 20, 38, 0.30);
  --rpg-panel-blue-strong: rgba(6, 20, 38, 0.48);
  --rpg-control-bg: rgba(3, 5, 10, 0.54);
  --rpg-control-border: rgba(255, 215, 0, 0.64);
  --rpg-control-glow: rgba(255, 215, 0, 0.22);
}

button,
.login-btn,
.admin-button,
.btn,
.btn-whatsapp,
.login-submit,
.header-search button,
.rpg-action-btn,
.rpg-mini-btn {
  border: 1px solid var(--rpg-control-border);
  border-radius: 8px;
  background:
    linear-gradient(180deg, rgba(95, 73, 142, 0.72), rgba(42, 30, 70, 0.78)),
    rgba(0,0,0,0.3);
  color: #ffea00;
  box-shadow:
    inset 0 1px 0 rgba(255,255,255,0.16),
    0 2px 0 rgba(0,0,0,0.52);
  font-weight: 900;
  text-shadow: 1px 1px 0 #000;
}

button:hover,
.login-btn:hover,
.admin-button:hover,
.btn:hover,
.btn-whatsapp:hover,
.login-submit:hover,
.header-search button:hover,
.rpg-action-btn:hover,
.rpg-mini-btn:hover {
  background:
    linear-gradient(180deg, rgba(127, 100, 178, 0.86), rgba(58, 42, 92, 0.9)),
    rgba(0,0,0,0.35);
  box-shadow:
    inset 0 0 0 1px rgba(255,255,255,0.12),
    0 0 14px var(--rpg-control-glow);
}

.admin-button.danger,
.modal .form-actions .btn.cancel {
  background: linear-gradient(180deg, rgba(119,42,42,0.72), rgba(58,22,22,0.84));
}

.admin-button.info {
  background: linear-gradient(180deg, rgba(42,112,71,0.72), rgba(19,62,39,0.84));
}

.rpg-mini-btn {
  min-height: 28px;
  padding: 4px 10px;
  font-size: 11px;
}

input[type="text"],
input[type="number"],
input[type="email"],
input[type="password"],
textarea,
select,
.header-search input,
.item-field input,
.item-field textarea,
.item-field select,
.form-row input[type="text"],
.form-row input[type="number"],
.form-row input[type="email"],
.form-row input[type="password"],
.form-row textarea,
.form-row select {
  border: 1px solid rgba(255,215,0,0.42);
  border-radius: 8px;
  background:
    linear-gradient(180deg, rgba(5,8,14,0.62), rgba(2,3,7,0.72)),
    var(--rpg-panel-blue);
  color: #ffea00;
  box-shadow: inset 0 0 0 1px rgba(0,0,0,0.36);
  color-scheme: dark;
}

input::placeholder,
textarea::placeholder {
  color: rgba(255,255,255,0.46);
}

input[type="number"] {
  -moz-appearance: textfield;
}

input[type="number"]::-webkit-outer-spin-button,
input[type="number"]::-webkit-inner-spin-button {
  -webkit-appearance: none;
  margin: 0;
}

.number-stepper {
  display: grid;
  grid-template-columns: 38px minmax(72px, 1fr) 38px;
  align-items: stretch;
  min-width: 150px;
  border: 1px solid rgba(255,215,0,0.46);
  border-radius: 9px;
  background: var(--rpg-panel-blue);
  overflow: hidden;
}

.number-stepper input {
  width: 100%;
  min-width: 0;
  min-height: 38px;
  border: 0 !important;
  border-radius: 0 !important;
  background: rgba(0,0,0,0.42) !important;
  color: #ffea00;
  font-family: var(--number-font);
  font-size: 13px;
  text-align: center;
}

.stepper-btn {
  width: 38px;
  min-height: 38px;
  padding: 0;
  border: 0;
  border-radius: 0;
  background: linear-gradient(180deg, rgba(96,74,152,0.84), rgba(42,31,78,0.92));
  font-size: 20px;
  line-height: 1;
}

.stepper-btn.plus {
  color: #a8ff85;
}

.stepper-btn.minus {
  color: #ff8a8a;
}

.stock-btn {
  width: 28px;
  height: 28px;
  border-radius: 8px;
  background: linear-gradient(180deg, rgba(96,74,152,0.84), rgba(42,31,78,0.92));
  font-size: 18px;
}

.stock-qty {
  min-width: 34px;
  padding: 3px 6px;
  border: 1px solid rgba(255,215,0,0.34);
  border-radius: 6px;
  background: rgba(0,0,0,0.36);
}

.modal-overlay {
  background: rgba(0,0,0,0.58);
  backdrop-filter: blur(4px);
}

.modal {
  background:
    linear-gradient(180deg, rgba(6,20,38,0.34), rgba(5,12,24,0.30)),
    var(--bg-url);
  background-size: calc(var(--img-w) * var(--tile-scale-panel))
                   calc(var(--img-h) * var(--tile-scale-panel));
  border: 1px solid rgba(255,215,0,0.72);
  border-radius: 8px;
  box-shadow:
    0 24px 80px rgba(0,0,0,0.62),
    inset 0 0 0 1px rgba(0,0,0,0.44);
}

.admin-card,
.accordion-item,
.item-selected-card,
.item-visual-card,
.item-buy-card,
.item-spec-section .item-stats,
.item-reviews,
.outfit-preview-box {
  background:
    linear-gradient(180deg, rgba(6,20,38,0.34), rgba(6,13,28,0.28)),
    rgba(0,0,0,0.18);
  border-color: rgba(255,215,0,0.34);
  border-radius: 8px;
}

.coupon-form-grid {
  display: grid;
  grid-template-columns: minmax(180px, 1.5fr) minmax(150px, 0.8fr) minmax(170px, 0.9fr) auto;
  gap: 12px;
  align-items: end;
}

.coupon-form-grid .rpg-action-btn {
  min-height: 42px;
  padding: 8px 18px;
}

.coupon-actions {
  display: flex;
  gap: 8px;
  flex-wrap: wrap;
}

.coupon-actions .admin-button {
  padding: 6px 10px;
  font-size: 12px;
}

.coupon-list-state {
  color: rgba(255,234,0,0.72);
}

.items-sort-filter-bar {
  margin: 4px 0 10px;
  padding: 8px 10px;
  border: 1px solid rgba(255,215,0,0.26);
  border-radius: 0;
  background: rgba(6,20,38,0.30);
}

.sort-filter-row {
  gap: 8px;
  align-items: center;
}

.sort-filter-group {
  min-width: 118px;
  gap: 3px;
}

.sort-filter-group label {
  color: rgba(255,234,0,0.72);
  font-size: 10px;
  letter-spacing: 0;
}

.sort-filter-group select,
.sort-filter-group input,
.price-range-inputs input {
  min-height: 34px;
  border-radius: 7px;
  background: rgba(0,0,0,0.32);
  color: #ffea00;
}

.sort-filter-group.price-range {
  min-width: 176px;
}

.price-range-inputs input {
  width: 70px;
}

.game-market-row.item-esgotado {
  opacity: 0.62;
  pointer-events: auto;
}

.game-market-row.item-esgotado .market-ad-price {
  opacity: 0.55;
}

/* =====================================================
   SOLD OUT RIBBON — selo diagonal sobre moldura dourada
   Filho direto de .game-market-row (position:relative)
   ===================================================== */
.esgotado-badge {
  position: absolute;
  top: 62px;
  left: -4px;
  width: max-content;
  transform: rotate(-18deg);
  transform-origin: left top;
  z-index: 100;
  padding: 6px 18px;
  border: 2px solid rgba(255,122,122,0.95);
  border-radius: 4px;
  background:
    linear-gradient(180deg, rgba(150,38,38,0.96), rgba(72,18,18,0.97));
  color: #fff;
  font: 900 15px/1 "Arial Black", Impact, sans-serif;
  letter-spacing: 2px;
  text-transform: uppercase;
  pointer-events: none;
  box-shadow: 0 4px 18px rgba(0,0,0,0.78);
  white-space: nowrap;
}

.esgotado-badge-detail {
  top: 50%;
  bottom: auto;
  width: max-content;
  transform: translate(-50%, -50%) rotate(-12deg);
  padding: 8px 20px;
  border: 2px solid rgba(255,122,122,0.95);
  background:
    linear-gradient(180deg, rgba(150,38,38,0.96), rgba(72,18,18,0.96));
  color: #fff;
  font-size: 18px;
  letter-spacing: 2px;
  box-shadow: 0 4px 16px rgba(0,0,0,0.62);
}

.recently-viewed-head {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 10px;
  margin-bottom: 8px;
}

.recently-viewed-section {
  padding: 8px 12px 10px;
  margin: 0;
  border-bottom: 1px solid rgba(255,215,0,0.38);
  background: rgba(6,20,38,0.20);
}

.recently-viewed-title {
  margin: 0;
}

.item-showcase-panel {
  width: min(92vw, 780px);
  max-height: none;
}

.item-showcase-header {
  min-height: 76px;
  padding: 12px 28px;
}

.item-showcase-header .title {
  font-size: clamp(26px, 3vw, 40px);
}

.item-showcase {
  grid-template-columns: minmax(0, 1fr);
  gap: 12px;
  padding: 14px 18px 10px;
  overflow: visible;
}

.item-buy-card {
  justify-content: start;
  padding: 16px;
}

.item-visual-card {
  padding: 14px;
}

.outfit-stage {
  min-height: 300px;
}

.outfit-canvas {
  transform: translateY(-36px);
}

.item-reviews {
  display: grid;
  gap: 10px;
  padding: 12px;
  align-self: start;
}

.reviews-head {
  display: flex;
  justify-content: space-between;
  gap: 10px;
  align-items: start;
  border-bottom: 1px solid rgba(255,215,0,0.22);
  padding-bottom: 8px;
}

.reviews-title {
  margin: 0;
  font-size: 22px;
  color: var(--gold);
}

.reviews-head span,
.reviews-count,
.review-date {
  color: rgba(255,255,255,0.58);
  font-size: 12px;
}

.reviews-list {
  display: grid;
  gap: 8px;
  max-height: 132px;
  overflow: auto;
}

.review-item,
.review-empty,
.reviews-loading {
  padding: 8px 10px;
  border: 1px solid rgba(255,215,0,0.18);
  border-radius: 8px;
  background: rgba(0,0,0,0.24);
}

.review-header {
  display: flex;
  flex-wrap: wrap;
  gap: 6px 10px;
  align-items: center;
}

.review-comment {
  margin-top: 5px;
  color: rgba(255,255,255,0.78);
  font-size: 13px;
}

.review-comprou-badge {
  width: max-content;
  margin-top: 6px;
  padding: 3px 8px;
  border: 1px solid rgba(84,255,146,0.38);
  border-radius: 999px;
  color: #8dffb3;
  background: rgba(33,118,68,0.22);
  font-size: 11px;
  font-weight: 800;
}

.review-form {
  display: grid;
  gap: 8px;
  padding-top: 8px;
  border-top: 1px solid rgba(255,215,0,0.18);
}

.review-form h3 {
  margin: 0;
  font-size: 15px;
}

.review-form-grid {
  display: grid;
  grid-template-columns: 1fr auto;
  gap: 8px;
  align-items: end;
}

.review-form-field {
  display: grid;
  gap: 4px;
  color: rgba(255,234,0,0.78);
  font-size: 12px;
  font-weight: 800;
}

.checkbox-field {
  display: flex;
  align-items: center;
  min-height: 34px;
  white-space: nowrap;
}

.review-form textarea {
  min-height: 54px;
  resize: vertical;
}

@media (max-width: 940px) {
  .coupon-form-grid {
    grid-template-columns: 1fr;
  }

  .item-showcase {
    grid-template-columns: 1fr;
    overflow: visible;
  }

  .item-reviews {
    grid-column: 1;
    grid-row: auto;
    order: 4;
  }

  .reviews-list {
    max-height: none;
  }
}

@media (max-width: 640px) {
  .number-stepper {
    width: 100%;
  }

  .sort-filter-row {
    display: grid;
    grid-template-columns: 1fr 1fr;
  }

  .sort-filter-group.price-range {
    grid-column: 1 / -1;
  }

  .item-showcase-header {
    padding: 12px 14px;
  }

  .review-form-grid {
    grid-template-columns: 1fr;
  }

  .game-market-row .esgotado-badge {
    top: 54px;
    left: -6px;
    transform: rotate(-16deg);
    transform-origin: left top;
    font-size: 11px;
    padding: 4px 10px;
    letter-spacing: 1px;
  }
}

.game-market-fav {
  background: transparent;
  border: 0;
  box-shadow: none;
  color: rgba(255, 255, 255, 0.7);
  min-height: auto;
  padding: 4px;
  text-shadow: none;
}

.game-market-fav:hover {
  background: transparent;
  box-shadow: none;
  color: #ff3b3b;
  transform: none;
}

.item-showcase.no-outfit-preview {
  grid-template-columns: minmax(260px, 360px) minmax(300px, 330px);
  align-items: start;
}

.item-showcase.no-outfit-preview .item-buy-card {
  grid-column: 2;
  grid-row: 1;
}

.item-showcase.no-outfit-preview .item-reviews {
  grid-column: 2;
  grid-row: 2;
}

.item-showcase.no-outfit-preview .item-spec-section {
  grid-column: 1 / -1;
  grid-row: 2;
}

@media (max-width: 940px) {
  .item-showcase.no-outfit-preview {
    grid-template-columns: 1fr;
  }

  .item-showcase.no-outfit-preview .item-buy-card,
  .item-showcase.no-outfit-preview .item-reviews,
  .item-showcase.no-outfit-preview .item-spec-section {
    grid-column: 1;
    grid-row: auto;
  }
}

/* Final detail/login polish */
.header {
  padding-left: 58px;
}

.header .back-button {
  top: 10px;
  left: 14px;
  transform: none;
  z-index: 12;
  width: 38px;
  height: 38px;
  border: 1px solid rgba(255,215,0,0.55);
  border-radius: 8px;
  background:
    linear-gradient(180deg, rgba(61, 43, 100, 0.82), rgba(18, 13, 32, 0.94)),
    rgba(0,0,0,0.36);
  box-shadow: inset 0 0 0 1px rgba(255,255,255,0.08), 0 3px 0 rgba(0,0,0,0.65);
}

.header-search {
  width: 100%;
}

.item-showcase-header {
  padding-left: 28px;
}

.item-showcase-header .item-back-button {
  position: static;
  transform: none;
  flex: none;
}

.game-market-copy {
  min-width: 0;
  display: grid;
  gap: 6px;
}

.market-stock-pill {
  width: max-content;
  max-width: 100%;
  padding: 4px 9px;
  border: 1px solid rgba(255,215,0,0.4);
  border-radius: 7px;
  background: rgba(4, 16, 32, 0.32);
  color: rgba(255,255,255,0.82);
  font-size: 13px;
  font-weight: 800;
  text-shadow: 1px 1px 0 #000;
}

.market-stock-pill strong {
  color: var(--gold);
}

.market-stock-pill.is-empty {
  border-color: rgba(255,80,80,0.55);
  color: #ff8a8a;
}

.stock-line {
  display: flex;
  align-items: center;
  flex-wrap: wrap;
  gap: 8px;
  color: #ff6767;
  font-size: 16px;
}

.stock-label {
  color: #ff8b8b;
  font-weight: 900;
  letter-spacing: 0;
  text-shadow: 1px 1px 0 #000;
}

.stock-control {
  display: inline-grid;
  grid-template-columns: 28px minmax(34px, auto) 28px;
  align-items: center;
  gap: 4px;
  padding: 3px;
  border: 1px solid rgba(255,215,0,0.42);
  border-radius: 10px;
  background: rgba(5, 16, 34, 0.38);
}

.stock-control .stock-qty {
  min-width: 34px;
  color: var(--gold);
  font-size: 18px;
  font-weight: 900;
  text-align: center;
}

.quick-stock-control {
  grid-template-columns: 34px minmax(48px, auto) 34px;
  padding: 4px;
  border-color: rgba(255,215,0,0.75);
  background:
    linear-gradient(180deg, rgba(46,33,78,0.76), rgba(11,15,30,0.72)),
    rgba(0,0,0,0.25);
  box-shadow: inset 0 0 0 1px rgba(255,255,255,0.08), 0 4px 0 rgba(0,0,0,0.45);
}

.quick-stock-control .stock-btn {
  width: 34px;
  height: 32px;
  border-radius: 8px;
  border: 1px solid rgba(255,215,0,0.9);
  background: linear-gradient(180deg, #6540a0, #20143f);
  color: var(--gold);
  font-size: 22px;
  font-weight: 900;
  line-height: 1;
  text-shadow: 1px 1px 0 #000;
  cursor: pointer;
}

.quick-stock-control .stock-btn:hover {
  background: linear-gradient(180deg, #7d53bd, #2c1a54);
  transform: translateY(-1px);
}

.quick-stock-control .stock-qty {
  min-width: 48px;
  padding: 0 6px;
  color: #fff7a6;
  font-size: 22px;
  font-weight: 900;
}

.item-showcase.has-outfit-preview,
.item-showcase.no-outfit-preview.has-stats,
.item-showcase.no-outfit-preview.no-stats {
  grid-template-columns: minmax(0, 1fr);
  align-items: stretch;
}

.item-showcase.has-outfit-preview .item-visual-card,
.item-showcase.has-outfit-preview .outfit-preview-box,
.item-showcase.has-outfit-preview .item-buy-card,
.item-showcase.has-outfit-preview .item-reviews,
.item-showcase.no-outfit-preview.has-stats .item-visual-card,
.item-showcase.no-outfit-preview.has-stats .item-spec-section,
.item-showcase.no-outfit-preview.has-stats .item-buy-card,
.item-showcase.no-outfit-preview.has-stats .item-reviews,
.item-showcase.no-outfit-preview.no-stats .item-buy-card,
.item-showcase.no-outfit-preview.no-stats .item-reviews {
  grid-column: 1;
  grid-row: auto;
}

.item-showcase.has-outfit-preview .item-visual-card,
.item-showcase.no-outfit-preview.has-stats .item-visual-card {
  order: 1;
}

.item-showcase.has-outfit-preview .outfit-preview-box,
.item-showcase.no-outfit-preview.has-stats .item-spec-section {
  order: 2;
}

.item-showcase.has-outfit-preview .item-buy-card,
.item-showcase.no-outfit-preview.has-stats .item-buy-card,
.item-showcase.no-outfit-preview.no-stats .item-buy-card {
  order: 3;
}

.item-showcase.has-outfit-preview .item-reviews,
.item-showcase.no-outfit-preview.has-stats .item-reviews,
.item-showcase.no-outfit-preview.no-stats .item-reviews {
  order: 4;
}

.item-spec-section .item-stats.visual-stats {
  padding: 14px;
}

.visual-stats .stat-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 10px;
  min-height: auto;
  padding: 0 0 10px;
  margin-bottom: 10px;
}

.visual-stats .stat-visual-grid {
  display: grid;
  grid-template-columns: repeat(4, minmax(72px, 1fr));
  gap: 12px;
  align-items: start;
}

.visual-stats .stat-visual-card {
  position: relative;
  min-width: 0;
  aspect-ratio: 1;
  display: grid;
  place-items: center;
  border: 1px solid rgba(255,215,0,0.46);
  border-radius: 8px;
  background:
    radial-gradient(circle at 50% 42%, rgba(255,215,0,0.18), transparent 54%),
    rgba(0,0,0,0.34);
  box-shadow: inset 0 0 0 1px rgba(255,255,255,0.06), 0 6px 16px rgba(0,0,0,0.22);
  overflow: hidden;
}

.visual-stats .stat-visual-card img {
  width: 58px;
  height: 58px;
  object-fit: contain;
  image-rendering: pixelated;
}

.visual-stats .stat-visual-card strong {
  position: absolute;
  right: 5px;
  bottom: 3px;
  color: #fff;
  font-size: 18px;
  line-height: 1;
  text-shadow: 2px 2px 0 #000, -1px -1px 0 #000;
}

.visual-stats .stat-skill-card,
.visual-stats .stat-main-skill-card {
  grid-column: span 1;
}

.visual-stats .stat-skill-card em,
.visual-stats .stat-row,
.visual-stats .stat-section {
  display: none;
}

.outfit-stage-fallback {
  min-height: 300px;
  display: grid;
  place-items: center;
  background:
    radial-gradient(circle at 50% 42%, rgba(255,215,0,0.13), transparent 48%),
    linear-gradient(180deg, rgba(7, 21, 42, 0.46), rgba(3, 9, 20, 0.32));
}

.outfit-stage-fallback img {
  width: 136px;
  height: 136px;
  object-fit: contain;
  image-rendering: pixelated;
  filter: drop-shadow(0 18px 22px rgba(0,0,0,0.65));
}

.auth-panel {
  width: min(92vw, 760px);
}

.auth-header {
  min-height: 72px;
  display: grid;
  align-items: center;
}

.auth-shell {
  display: grid;
  grid-template-columns: 240px minmax(0, 1fr);
  gap: 18px;
  padding: 22px;
  background:
    linear-gradient(180deg, rgba(5, 18, 34, 0.24), rgba(4, 9, 22, 0.18));
}

.auth-emblem,
.auth-card {
  border: 1px solid rgba(255,215,0,0.34);
  border-radius: 8px;
  background:
    linear-gradient(180deg, rgba(6,20,38,0.34), rgba(6,13,28,0.28)),
    rgba(0,0,0,0.22);
  box-shadow: inset 0 0 0 1px rgba(255,255,255,0.05);
}

.auth-emblem {
  min-height: 260px;
  display: grid;
  place-items: center;
  align-content: center;
  gap: 10px;
  text-align: center;
  color: var(--gold);
}

.auth-orb {
  width: 86px;
  height: 86px;
  display: grid;
  place-items: center;
  border: 1px solid rgba(255,215,0,0.55);
  border-radius: 10px;
  background: rgba(0,0,0,0.38);
}

.auth-orb img {
  width: 58px;
  height: 58px;
  object-fit: contain;
  image-rendering: pixelated;
}

.auth-emblem strong {
  font-size: 22px;
  text-shadow: 2px 2px 0 #000;
}

.auth-emblem span {
  color: rgba(255,255,255,0.74);
  font-weight: 800;
}

.auth-card {
  display: grid;
  gap: 14px;
  padding: 18px;
}

.auth-field {
  display: grid;
  gap: 6px;
  color: var(--gold);
  font-weight: 900;
}

.auth-field input {
  width: 100%;
}

.auth-submit {
  min-height: 48px;
  font-size: 18px;
}

.auth-footer {
  justify-content: flex-start;
}

@media (max-width: 940px) {
  .item-showcase.has-outfit-preview,
  .item-showcase.no-outfit-preview.has-stats,
  .item-showcase.no-outfit-preview.no-stats {
    grid-template-columns: 1fr;
  }

  .item-showcase.has-outfit-preview .item-visual-card,
  .item-showcase.has-outfit-preview .outfit-preview-box,
  .item-showcase.has-outfit-preview .item-buy-card,
  .item-showcase.has-outfit-preview .item-reviews,
  .item-showcase.no-outfit-preview.has-stats .item-visual-card,
  .item-showcase.no-outfit-preview.has-stats .item-spec-section,
  .item-showcase.no-outfit-preview.has-stats .item-buy-card,
  .item-showcase.no-outfit-preview.has-stats .item-reviews,
  .item-showcase.no-outfit-preview.no-stats .item-buy-card,
  .item-showcase.no-outfit-preview.no-stats .item-reviews {
    grid-column: 1;
    grid-row: auto;
  }

  .item-showcase.has-outfit-preview .item-visual-card,
  .item-showcase.no-outfit-preview.has-stats .item-visual-card {
    order: 1;
  }

  .item-showcase.has-outfit-preview .outfit-preview-box,
  .item-showcase.no-outfit-preview.has-stats .item-spec-section {
    order: 2;
  }

  .item-showcase.has-outfit-preview .item-buy-card,
  .item-showcase.no-outfit-preview.has-stats .item-buy-card,
  .item-showcase.no-outfit-preview.no-stats .item-buy-card {
    order: 3;
  }

  .item-showcase.has-outfit-preview .item-reviews,
  .item-showcase.no-outfit-preview.has-stats .item-reviews,
  .item-showcase.no-outfit-preview.no-stats .item-reviews {
    order: 4;
  }
}

@media (max-width: 700px) {
  .auth-shell {
    grid-template-columns: 1fr;
    padding: 14px;
  }

  .auth-emblem {
    min-height: 150px;
  }

  .visual-stats .stat-visual-grid {
    grid-template-columns: repeat(3, minmax(70px, 1fr));
  }
}

@media (max-width: 520px) {
  .header {
    padding-left: 54px;
  }

  .game-market-row {
    grid-template-columns: 58px minmax(0, 1fr) 132px;
  }

  .market-stock-pill {
    font-size: 12px;
    padding: 3px 7px;
  }

  .visual-stats .stat-visual-grid {
    grid-template-columns: repeat(2, minmax(74px, 1fr));
  }
}

/* WSDB-like item view and final stock/review polish */
.item-spec-section .item-stats.wsdb-item-viewer {
  padding: 0;
  overflow: hidden;
  border-color: rgba(255,215,0,0.5);
  background:
    linear-gradient(180deg, rgba(15, 30, 50, 0.52), rgba(5, 12, 24, 0.36)),
    rgba(0,0,0,0.22);
}

.wsdb-view-title {
  min-height: 34px;
  display: grid;
  place-items: center;
  color: #fff200;
  font-size: 20px;
  font-weight: 900;
  text-shadow: 2px 2px 0 #000;
  border-bottom: 1px solid rgba(255,215,0,0.55);
  background: rgba(23, 22, 35, 0.82);
}

.wsdb-view-item-head {
  min-height: 82px;
  display: grid;
  grid-template-columns: 72px minmax(0, 1fr) auto;
  align-items: center;
  gap: 12px;
  padding: 10px 14px;
  border-bottom: 1px solid rgba(255,215,0,0.35);
}

.wsdb-view-item-head img {
  width: 64px;
  height: 64px;
  object-fit: contain;
  border: 2px solid #f3d54c;
  background: rgba(0,0,0,0.44);
  image-rendering: pixelated;
}

.wsdb-view-item-head span {
  min-width: 0;
  font-size: 22px;
  font-weight: 900;
  line-height: 1.08;
  text-shadow: -1px 0 1px #000, 0 -1px 1px #000, 1px 0 1px #000, 0 1px 1px #000;
}

.wsdb-view-item-head .rarity-pill {
  align-self: start;
}

.wsdb-view-body {
  display: grid;
  gap: 12px;
  padding: 14px 18px 18px;
}

.wsdb-view-top {
  display: grid;
  grid-template-columns: 150px minmax(0, 1fr);
  gap: 18px;
}

.wsdb-stat-section h3 {
  margin: 0 0 8px;
  color: #fff;
  font-size: 20px;
  font-weight: 800;
  text-shadow: 2px 2px 0 #000;
}

.wsdb-stat-grid {
  display: flex;
  flex-wrap: wrap;
  gap: 16px 28px;
  align-items: center;
}

.wsdb-stat-section.bonuses .wsdb-stat-grid {
  justify-content: space-between;
}

.wsdb-stat-slot {
  position: relative;
  width: 88px;
  height: 88px;
  flex: 0 0 88px;
  background-image: url("../images/wsdb_slot_frame.png");
  background-repeat: no-repeat;
  background-size: 264px 176px;
  background-position: 0 -88px;
  image-rendering: pixelated;
}

.wsdb-stat-slot img {
  position: absolute;
  left: 16px;
  top: 14px;
  width: 56px;
  height: 56px;
  object-fit: contain;
  image-rendering: pixelated;
}

.wsdb-stat-slot strong {
  position: absolute;
  right: 8px;
  bottom: 7px;
  min-width: 34px;
  color: #fff;
  font-size: 20px;
  line-height: 1;
  font-family: "Arial Black", Impact, sans-serif;
  font-weight: 900;
  text-align: right;
  -webkit-text-stroke: 1px #111;
  text-shadow: 2px 2px 0 #000, -1px -1px 0 #000;
}

.wsdb-level-slot strong {
  inset: 0;
  display: grid;
  place-items: center;
  min-width: 0;
  font-size: 38px;
  text-align: center;
  color: #fff;
  -webkit-text-stroke: 2px #111;
}

.wsdb-empty-slot {
  filter: grayscale(1);
  opacity: 0.48;
}

.wsdb-empty-slot::after {
  content: "";
  position: absolute;
  left: 16px;
  top: 14px;
  width: 56px;
  height: 56px;
  border-radius: 6px;
  background:
    repeating-linear-gradient(45deg, rgba(255,255,255,0.12) 0 5px, rgba(0,0,0,0.2) 5px 10px),
    rgba(0,0,0,0.34);
}

.outfit-stage {
  position: relative;
  min-height: 430px;
}

.outfit-canvas {
  width: 216px;
  height: 252px;
  transform: translateY(0);
  image-rendering: pixelated;
  filter: drop-shadow(0 22px 22px rgba(0,0,0,0.68));
  opacity: 0;
  transition: opacity 160ms ease;
}

.outfit-canvas.is-ready {
  opacity: 1;
}

.outfit-loading {
  position: absolute;
  inset: auto 0 22px;
  margin: auto;
  width: max-content;
  max-width: calc(100% - 28px);
  color: var(--gold);
  font-size: 15px;
  font-weight: 900;
  text-shadow: 2px 2px 0 #000;
  pointer-events: none;
}

.outfit-stage-fallback img {
  width: 170px;
  height: 170px;
}

.market-stock-control,
.detail-stock-control {
  width: max-content;
  max-width: 100%;
}

.market-stock-control .stock-btn,
.detail-stock-control .stock-btn {
  width: 30px;
  height: 30px;
  font-size: 19px;
}

.market-stock-control .stock-qty,
.detail-stock-control .stock-qty {
  min-width: 42px;
  font-size: 20px;
}

.reviews-summary .review-star,
.review-stars .review-star {
  display: inline-block;
  font-size: 30px;
  line-height: 1;
  margin-left: 1px;
  text-shadow: 2px 2px 0 #000;
}

.reviews-summary .review-star {
  font-size: 34px;
}

.review-star.filled {
  color: #ffd700;
}

.review-star.empty {
  color: rgba(255,255,255,0.22);
}

@media (max-width: 940px) {
  .wsdb-view-top {
    grid-template-columns: 1fr;
  }

  .wsdb-stat-section.bonuses .wsdb-stat-grid {
    justify-content: flex-start;
  }

  .outfit-canvas {
    width: 180px;
    height: 210px;
  }
}

@media (max-width: 520px) {
  .wsdb-view-item-head {
    grid-template-columns: 60px minmax(0, 1fr);
  }

  .outfit-controls {
    --outfit-slot-size: 62px;
    gap: 8px;
    padding: 9px 6px;
  }

  .outfit-wsdb-icon {
    width: 44px;
    height: 44px;
  }

  .outfit-wsdb-gender-icon {
    width: 46px;
    height: 46px;
    background-size: 46px 92px;
  }

  .outfit-wsdb-gender-female {
    background-position: 0 -46px;
  }

  .outfit-reset-btn svg {
    width: 32px;
    height: 32px;
  }

  .wsdb-view-item-head .rarity-pill {
    grid-column: 2;
    justify-self: start;
  }

  .wsdb-stat-grid {
    gap: 12px 18px;
  }

  .wsdb-stat-slot {
    width: 74px;
    height: 74px;
    flex-basis: 74px;
    background-size: 222px 148px;
    background-position: 0 -74px;
  }

  .wsdb-stat-slot img {
    left: 13px;
    top: 12px;
    width: 48px;
    height: 48px;
  }

  .wsdb-stat-slot strong {
    right: 6px;
    bottom: 6px;
    font-size: 17px;
  }

  .wsdb-level-slot strong {
    font-size: 31px;
  }
}

/* Detalhe do item: preview visual primeiro, igual ao mobile enviado */
.item-showcase-panel-preview-first {
  width: min(94vw, 820px);
}

.item-showcase-panel-preview-first .item-showcase-header-compact {
  display: none;
}

.item-showcase-panel-preview-first .item-showcase {
  grid-template-columns: minmax(0, 1fr);
  align-items: stretch;
  justify-content: stretch;
  gap: 10px;
  padding: 18px 20px;
}

.item-showcase-panel-preview-first .item-spec-section,
.item-showcase-panel-preview-first .outfit-preview-box,
.item-showcase-panel-preview-first .item-buy-card,
.item-showcase-panel-preview-first .item-reviews {
  grid-column: 1;
  grid-row: auto;
  width: 100%;
}

.item-showcase-panel-preview-first .item-spec-section {
  order: 1;
}

.item-showcase-panel-preview-first .outfit-preview-box {
  order: 2;
}

.item-showcase-panel-preview-first .item-buy-card {
  order: 3;
  justify-content: flex-start;
}

.item-showcase-panel-preview-first .item-reviews {
  order: 4;
}

.item-showcase-panel-preview-first .item-stats.wsdb-item-viewer {
  width: 100%;
}

.item-showcase-panel-preview-first .wsdb-view-item-head {
  min-height: 104px;
  grid-template-columns: 90px minmax(0, 1fr) auto;
  gap: 14px;
  padding: 16px 20px;
}

.item-showcase-panel-preview-first .wsdb-view-item-head img {
  width: 84px;
  height: 84px;
}

.item-showcase-panel-preview-first .wsdb-view-item-head span {
  font-size: 28px;
}

.item-showcase-panel-preview-first .wsdb-view-top {
  grid-template-columns: 1fr;
  gap: 12px;
}

.item-showcase-panel-preview-first .wsdb-stat-section.bonuses .wsdb-stat-grid {
  justify-content: flex-start;
}

@media (max-width: 520px) {
  .item-showcase-panel-preview-first .item-showcase {
    padding: 12px;
  }

  .item-showcase-panel-preview-first .wsdb-view-item-head {
    min-height: 82px;
    grid-template-columns: 60px minmax(0, 1fr);
    gap: 12px;
    padding: 10px 14px;
  }

  .item-showcase-panel-preview-first .wsdb-view-item-head img {
    width: 64px;
    height: 64px;
  }

  .item-showcase-panel-preview-first .wsdb-view-item-head span {
    font-size: 22px;
  }

  .item-showcase-panel-preview-first .wsdb-view-item-head .rarity-pill {
    grid-column: 2;
    justify-self: start;
  }
}

/* Preview de anuncio: molduras alinhadas em uma grade fixa */
.item-ad-preview-panel {
  width: min(94vw, 560px);
  max-height: none;
}

.item-ad-preview-panel .item-detail-heading {
  margin: 52px 12px 22px;
  padding: 0;
  color: #ffea00;
  font-size: 21px;
  font-weight: 900;
  line-height: 1.15;
  text-align: left;
  text-shadow: 2px 2px 0 #000;
}

.item-ad-preview-panel .item-showcase {
  padding: 0 12px 12px;
  overflow: visible;
}

.item-ad-preview-panel .item-stats.wsdb-item-viewer {
  border-color: rgba(255,215,0,0.72);
}

.item-ad-preview-panel .wsdb-view-item-head {
  min-height: 64px;
  grid-template-columns: 48px minmax(0, 1fr) auto;
  gap: 8px;
  padding: 8px 10px;
}

.item-ad-preview-panel .wsdb-view-item-head img {
  width: 44px;
  height: 44px;
}

.item-ad-preview-panel .wsdb-view-item-head span {
  font-size: 14px;
  line-height: 1.1;
}

.item-ad-preview-panel .wsdb-view-item-head .rarity-pill {
  min-height: 18px;
  padding: 2px 7px;
  border-radius: 6px;
  font-size: 9px;
}

.item-ad-preview-panel .wsdb-view-body {
  display: grid;
  grid-template-columns: repeat(4, 64px);
  justify-content: space-between;
  align-items: start;
  row-gap: 9px;
  padding: 10px 10px 14px;
}

.item-ad-preview-panel .wsdb-view-top {
  display: contents;
}

.item-ad-preview-panel .wsdb-stat-section.requirements {
  grid-column: 1;
  grid-row: 1;
}

.item-ad-preview-panel .wsdb-stat-section.parameters {
  grid-column: 2 / 5;
  grid-row: 1;
}

.item-ad-preview-panel .wsdb-stat-section.bonuses {
  grid-column: 1 / 5;
  grid-row: 2;
}

.item-ad-preview-panel .wsdb-stat-section.enchants {
  grid-column: 1 / 5;
  grid-row: 3;
}

.item-ad-preview-panel .wsdb-stat-section h3 {
  margin: 0 0 6px;
  font-size: 13px;
  line-height: 1;
}

.item-ad-preview-panel .wsdb-stat-grid {
  display: grid;
  align-items: start;
  gap: 0;
}

.item-ad-preview-panel .wsdb-stat-section.requirements .wsdb-stat-grid {
  grid-template-columns: 64px;
}

.item-ad-preview-panel .wsdb-stat-section.parameters .wsdb-stat-grid {
  grid-template-columns: repeat(3, 64px);
  justify-content: space-between;
}

.item-ad-preview-panel .wsdb-stat-section.bonuses .wsdb-stat-grid {
  grid-template-columns: repeat(4, 64px);
  justify-content: space-between;
}

.item-ad-preview-panel .wsdb-stat-section.enchants .wsdb-stat-grid {
  grid-template-columns: repeat(2, 64px);
  justify-content: start;
  column-gap: 10px;
}

.item-ad-preview-panel .wsdb-stat-slot {
  width: 64px;
  height: 64px;
  flex: 0 0 64px;
  background-size: 192px 128px;
  background-position: 0 -64px;
}

.item-ad-preview-panel .wsdb-stat-slot img {
  left: 12px;
  top: 10px;
  width: 40px;
  height: 40px;
}

.item-ad-preview-panel .wsdb-stat-slot strong {
  right: 5px;
  bottom: 4px;
  min-width: 24px;
  font-size: 13px;
  -webkit-text-stroke: 0.8px #111;
  text-shadow: 1px 1px 0 #000, -1px -1px 0 #000;
}

.item-ad-preview-panel .wsdb-level-slot strong {
  font-size: 30px;
  -webkit-text-stroke: 1.6px #111;
}

.item-ad-preview-panel .wsdb-empty-slot::after {
  left: 12px;
  top: 10px;
  width: 40px;
  height: 40px;
}

@media (max-width: 520px) {
  .item-ad-preview-panel {
    width: min(94vw, 560px);
  }

  .item-ad-preview-panel .item-detail-heading {
    margin: 34px 10px 18px;
    font-size: 19px;
  }

  .item-ad-preview-panel .item-showcase {
    padding: 0 10px 10px;
  }

  .item-ad-preview-panel .wsdb-view-body {
    grid-template-columns: repeat(4, 56px);
    padding: 9px;
  }

  .item-ad-preview-panel .wsdb-stat-section.requirements .wsdb-stat-grid {
    grid-template-columns: 56px;
  }

  .item-ad-preview-panel .wsdb-stat-section.parameters .wsdb-stat-grid {
    grid-template-columns: repeat(3, 56px);
  }

  .item-ad-preview-panel .wsdb-stat-section.bonuses .wsdb-stat-grid {
    grid-template-columns: repeat(4, 56px);
  }

  .item-ad-preview-panel .wsdb-stat-section.enchants .wsdb-stat-grid {
    grid-template-columns: repeat(2, 56px);
  }

  .item-ad-preview-panel .wsdb-stat-slot {
    width: 56px;
    height: 56px;
    flex-basis: 56px;
    background-size: 168px 112px;
    background-position: 0 -56px;
  }

  .item-ad-preview-panel .wsdb-stat-slot img,
  .item-ad-preview-panel .wsdb-empty-slot::after {
    left: 10px;
    top: 9px;
    width: 36px;
    height: 36px;
  }

  .item-ad-preview-panel .wsdb-stat-slot strong {
    font-size: 12px;
  }

  .item-ad-preview-panel .wsdb-level-slot strong {
    font-size: 26px;
  }
}

/* Item detail as a single WSDB-style advert image */
.sr-only {
  position: absolute;
  width: 1px;
  height: 1px;
  padding: 0;
  margin: -1px;
  overflow: hidden;
  clip: rect(0, 0, 0, 0);
  white-space: nowrap;
  border: 0;
}

body.detail-page {
  align-items: flex-start;
  padding-top: max(10px, env(safe-area-inset-top));
}

.item-ad-preview-panel {
  width: min(96vw, 690px);
  max-height: none;
  margin: 10px auto;
  overflow: visible;
  background: transparent;
  box-shadow: none;
}

.item-ad-preview-panel .corner {
  width: 44px;
  height: 44px;
}

.item-ad-preview-panel .item-detail-actions {
  position: absolute;
  z-index: 30;
  left: 18px;
  top: 42px;
}

.item-ad-preview-panel .item-back-button {
  width: 40px;
  height: 40px;
  border-radius: 8px;
  box-shadow: 0 4px 0 rgba(0,0,0,0.62);
}

.item-ad-preview-panel .item-showcase {
  display: grid;
  grid-template-columns: minmax(0, 1fr);
  justify-items: center;
  gap: 0;
  padding: 14px;
  overflow: visible;
}

.item-ad-preview-panel .item-visual-card,
.item-ad-preview-panel .item-buy-card,
.item-ad-preview-panel .item-reviews,
.item-ad-preview-panel .item-showcase-footer {
  display: none !important;
}

.item-ad-preview-panel .item-spec-section,
.item-ad-preview-panel .outfit-preview-box {
  grid-column: 1;
  grid-row: 1;
  width: min(100%, 640px);
  order: 1;
}

.item-ad-preview-panel .item-stats.wsdb-item-viewer,
.item-ad-preview-panel .outfit-preview-box {
  border-radius: 0;
  border: 2px solid #d4af37;
  background:
    linear-gradient(180deg, rgba(24, 41, 58, 0.84), rgba(15, 28, 42, 0.82)),
    rgba(0,0,0,0.54);
}

.item-ad-preview-panel .wsdb-view-title,
.item-ad-preview-panel .outfit-preview-title {
  min-height: 38px;
  font-size: 21px;
  border-bottom: 2px solid #d4af37;
}

.item-ad-preview-panel .wsdb-view-item-head,
.item-ad-preview-panel .outfit-preview-name {
  min-height: 78px;
  grid-template-columns: 72px minmax(0, 1fr);
  padding: 10px 20px;
  gap: 12px;
}

.item-ad-preview-panel .wsdb-view-item-head .rarity-pill {
  display: none;
}

.item-ad-preview-panel .wsdb-view-item-head img,
.item-ad-preview-panel .outfit-preview-name img {
  width: 64px;
  height: 64px;
}

.item-ad-preview-panel .wsdb-view-item-head span,
.item-ad-preview-panel .outfit-preview-name span {
  font-size: 22px;
}

.item-ad-preview-panel .wsdb-view-body {
  min-height: 408px;
  gap: 10px;
  padding: 12px 28px 18px;
}

.item-ad-preview-panel .wsdb-view-top {
  grid-template-columns: 170px minmax(0, 1fr);
  gap: 26px;
}

.item-ad-preview-panel .wsdb-stat-section h3 {
  margin-bottom: 6px;
  font-size: 21px;
}

.item-ad-preview-panel .wsdb-stat-grid {
  gap: 12px 34px;
}

.item-ad-preview-panel .wsdb-stat-section.bonuses .wsdb-stat-grid {
  justify-content: space-between;
}

.item-ad-preview-panel .wsdb-stat-slot {
  width: 82px;
  height: 82px;
  flex: 0 0 82px;
  background-size: 246px 164px;
  background-position: 0 -82px;
}

.item-ad-preview-panel .wsdb-stat-slot img {
  left: 15px;
  top: 13px;
  width: 52px;
  height: 52px;
}

.item-ad-preview-panel .wsdb-stat-slot strong {
  font-size: 20px;
}

.item-ad-preview-panel .wsdb-level-slot strong {
  font-size: 36px;
}

.item-ad-preview-panel .outfit-controls {
  padding: 8px 12px;
}

@media (min-width: 521px) {
  .item-ad-preview-panel .outfit-controls {
    --outfit-slot-size: 76px;
    gap: 10px;
  }
}

.item-ad-preview-panel .outfit-stage {
  min-height: 430px;
}

.item-ad-preview-panel .outfit-canvas {
  width: 210px;
  height: 245px;
}

@media (min-width: 900px) and (max-height: 780px) {
  .item-ad-preview-panel {
    width: min(96vw, 650px);
    margin-top: 6px;
  }

  .item-ad-preview-panel .item-showcase {
    padding: 10px;
  }

  .item-ad-preview-panel .wsdb-view-title,
  .item-ad-preview-panel .outfit-preview-title {
    min-height: 32px;
    font-size: 19px;
  }

  .item-ad-preview-panel .wsdb-view-item-head,
  .item-ad-preview-panel .outfit-preview-name {
    min-height: 66px;
    padding: 7px 18px;
  }

  .item-ad-preview-panel .wsdb-view-item-head img,
  .item-ad-preview-panel .outfit-preview-name img {
    width: 56px;
    height: 56px;
  }

  .item-ad-preview-panel .wsdb-view-body {
    min-height: 368px;
    padding: 10px 24px 14px;
  }

  .item-ad-preview-panel .wsdb-stat-slot {
    width: 74px;
    height: 74px;
    flex-basis: 74px;
    background-size: 222px 148px;
    background-position: 0 -74px;
  }

  .item-ad-preview-panel .wsdb-stat-slot img {
    left: 13px;
    top: 12px;
    width: 48px;
    height: 48px;
  }

  .item-ad-preview-panel .wsdb-stat-grid {
    gap: 9px 30px;
  }

  .item-ad-preview-panel .outfit-stage {
    min-height: 370px;
  }
}

@media (max-width: 520px) {
  .item-ad-preview-panel {
    width: 96vw;
    margin-top: 8px;
  }

  .item-ad-preview-panel .item-showcase {
    padding: 8px;
  }

  .item-ad-preview-panel .item-detail-actions {
    left: 10px;
    top: 34px;
  }

  .item-ad-preview-panel .wsdb-view-body {
    min-height: auto;
    padding: 12px 16px 16px;
  }

  .item-ad-preview-panel .wsdb-view-top {
    grid-template-columns: 1fr;
    gap: 10px;
  }

  .item-ad-preview-panel .wsdb-stat-section.bonuses .wsdb-stat-grid {
    justify-content: flex-start;
  }

  .item-ad-preview-panel .outfit-stage {
    min-height: 360px;
  }

  .item-ad-preview-panel .outfit-canvas {
    width: 180px;
    height: 210px;
  }
}

/* Layout definitivo do anuncio: grade alinhada + informacoes abaixo */
.item-ad-preview-panel {
  width: min(96vw, 690px);
  margin: 10px auto;
  overflow: visible;
  background: transparent;
  box-shadow: none;
}

.item-ad-preview-panel .item-detail-topline {
  display: grid;
  grid-template-columns: auto minmax(0, 1fr);
  align-items: center;
  gap: 12px;
  margin: 48px 14px 22px;
}

.item-ad-preview-panel .item-detail-heading {
  min-width: 0;
  margin: 0;
  color: #ffea00;
  font-size: 21px;
  font-weight: 900;
  line-height: 1.15;
  text-align: left;
  text-shadow: 2px 2px 0 #000;
}

.item-detail-back-button {
  min-width: 42px;
  min-height: 36px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 5px;
  padding: 6px 8px;
  border: 1px solid rgba(255,215,0,0.82);
  border-radius: 8px;
  background:
    linear-gradient(180deg, rgba(79, 50, 128, 0.88), rgba(22, 15, 42, 0.96)),
    rgba(0,0,0,0.58);
  color: #ffea00;
  box-shadow:
    inset 0 0 0 1px rgba(255,255,255,0.1),
    0 3px 0 rgba(0,0,0,0.72),
    0 0 12px rgba(255,215,0,0.12);
  cursor: pointer;
  font: 900 12px/1 "Arial Black", Impact, sans-serif;
  text-shadow: 1px 1px 0 #000;
  text-transform: uppercase;
}

.item-detail-back-button span {
  font-size: 22px;
  line-height: 1;
}

.item-detail-back-button:hover,
.item-detail-back-button:focus-visible {
  outline: none;
  border-color: #fff07a;
  background:
    linear-gradient(180deg, rgba(98, 62, 154, 0.96), rgba(34, 20, 66, 0.98)),
    rgba(0,0,0,0.64);
  transform: translateY(-1px);
}

.item-detail-back-button:active {
  transform: translateY(1px);
  box-shadow:
    inset 0 0 0 1px rgba(255,255,255,0.08),
    0 1px 0 rgba(0,0,0,0.72);
}

.item-ad-preview-panel .item-showcase {
  display: grid;
  grid-template-columns: minmax(0, 1fr);
  justify-items: center;
  gap: 12px;
  padding: 0 14px 14px;
  overflow: visible;
}

.item-ad-preview-panel .item-visual-card {
  display: none !important;
}

.item-ad-preview-panel .item-buy-card {
  display: flex !important;
  width: min(100%, 640px);
  order: 3;
}

.item-ad-preview-panel .item-price-card.primary {
  border: 0;
  background: transparent;
  box-shadow: none;
  padding: 0;
}

.item-ad-preview-panel .item-reviews {
  display: block !important;
  width: min(100%, 640px);
  order: 4;
}

.item-ad-preview-panel .item-showcase-footer {
  display: flex !important;
}

.item-ad-preview-panel .item-spec-section,
.item-ad-preview-panel .outfit-preview-box {
  grid-column: 1;
  width: min(100%, 640px);
  order: 1;
}

.item-ad-preview-panel .outfit-preview-box {
  order: 2;
}

.item-ad-preview-panel .item-stats.wsdb-item-viewer {
  border: 2px solid #d4af37;
  border-radius: 0;
  background:
    linear-gradient(180deg, rgba(24, 41, 58, 0.84), rgba(15, 28, 42, 0.82)),
    rgba(0,0,0,0.54);
}

.item-ad-preview-panel .wsdb-view-item-head {
  min-height: 78px;
  grid-template-columns: 72px minmax(0, 1fr) auto;
  gap: 12px;
  padding: 10px 20px;
}

.item-ad-preview-panel .wsdb-view-item-head img {
  width: 64px;
  height: 64px;
}

.item-ad-preview-panel .wsdb-view-item-head span {
  font-size: 22px;
}

.item-ad-preview-panel .wsdb-view-item-head .rarity-pill {
  justify-self: end;
  min-height: 22px;
  padding: 3px 8px;
  font-size: 10px;
}

.item-ad-preview-panel .wsdb-view-body {
  display: grid;
  grid-template-columns: repeat(4, 82px);
  column-gap: 52px;
  row-gap: 26px;
  justify-content: start;
  align-items: start;
  min-height: 392px;
  padding: 14px 28px 22px;
}

.item-ad-preview-panel .wsdb-view-top {
  display: contents;
}

.item-ad-preview-panel .wsdb-stat-section.requirements {
  grid-column: 1;
  grid-row: 1;
}

.item-ad-preview-panel .wsdb-stat-section.parameters {
  grid-column: 2 / 5;
  grid-row: 1;
}

.item-ad-preview-panel .wsdb-stat-section.bonuses {
  grid-column: 1 / 5;
  grid-row: 2;
}

.item-ad-preview-panel .wsdb-stat-section.enchants {
  grid-column: 1 / 5;
  grid-row: 3;
}

.item-ad-preview-panel .wsdb-stat-section h3 {
  margin: 0 0 8px;
  font-size: 21px;
  line-height: 1;
}

.item-ad-preview-panel .wsdb-stat-grid {
  display: grid;
  gap: 0;
  justify-content: start;
  align-items: start;
}

.item-ad-preview-panel .wsdb-stat-section.requirements .wsdb-stat-grid {
  grid-template-columns: 82px;
}

.item-ad-preview-panel .wsdb-stat-section.parameters .wsdb-stat-grid {
  grid-template-columns: repeat(3, 82px);
  column-gap: 52px;
}

.item-ad-preview-panel .wsdb-stat-section.bonuses .wsdb-stat-grid {
  grid-template-columns: repeat(4, 82px);
  column-gap: 52px;
  justify-content: start;
}

.item-ad-preview-panel .wsdb-stat-section.enchants .wsdb-stat-grid {
  grid-template-columns: repeat(2, 82px);
  column-gap: 10px;
}

.item-ad-preview-panel .wsdb-stat-slot {
  width: 82px;
  height: 82px;
  flex: 0 0 82px;
  background-size: 246px 164px;
  background-position: 0 -82px;
}

.item-ad-preview-panel .wsdb-stat-slot img {
  left: 15px;
  top: 13px;
  width: 52px;
  height: 52px;
}

.item-ad-preview-panel .wsdb-stat-slot strong {
  right: 6px;
  bottom: 5px;
  font-size: 20px;
}

.item-ad-preview-panel .wsdb-level-slot strong {
  font-size: 36px;
}

.item-ad-preview-panel .wsdb-empty-slot::after {
  left: 15px;
  top: 13px;
  width: 52px;
  height: 52px;
}

@media (max-width: 760px) {
  .item-ad-preview-panel {
    width: 96vw;
  }

  .item-ad-preview-panel .item-showcase {
    padding: 0 10px 12px;
  }

  .item-ad-preview-panel .wsdb-view-body {
    grid-template-columns: repeat(4, 72px);
    column-gap: 28px;
    row-gap: 22px;
    min-height: 340px;
    padding: 12px 18px 18px;
  }

  .item-ad-preview-panel .wsdb-stat-section.requirements .wsdb-stat-grid {
    grid-template-columns: 72px;
  }

  .item-ad-preview-panel .wsdb-stat-section.parameters .wsdb-stat-grid {
    grid-template-columns: repeat(3, 72px);
    column-gap: 28px;
  }

  .item-ad-preview-panel .wsdb-stat-section.bonuses .wsdb-stat-grid {
    grid-template-columns: repeat(4, 72px);
    column-gap: 28px;
  }

  .item-ad-preview-panel .wsdb-stat-section.enchants .wsdb-stat-grid {
    grid-template-columns: repeat(2, 72px);
  }

  .item-ad-preview-panel .wsdb-stat-slot {
    width: 72px;
    height: 72px;
    flex-basis: 72px;
    background-size: 216px 144px;
    background-position: 0 -72px;
  }

  .item-ad-preview-panel .wsdb-stat-slot img,
  .item-ad-preview-panel .wsdb-empty-slot::after {
    left: 13px;
    top: 11px;
    width: 46px;
    height: 46px;
  }

  .item-ad-preview-panel .wsdb-stat-slot strong {
    font-size: 17px;
  }

  .item-ad-preview-panel .wsdb-level-slot strong {
    font-size: 32px;
  }
}

@media (max-width: 520px) {
  .item-ad-preview-panel .item-detail-topline {
    gap: 8px;
    margin: 34px 10px 18px;
  }

  .item-ad-preview-panel .item-detail-heading {
    font-size: 19px;
  }

  .item-detail-back-button {
    width: 38px;
    min-width: 38px;
    min-height: 34px;
    padding: 5px;
  }

  .item-detail-back-button strong {
    position: absolute;
    width: 1px;
    height: 1px;
    margin: -1px;
    overflow: hidden;
    clip: rect(0, 0, 0, 0);
    white-space: nowrap;
    border: 0;
  }

  .item-ad-preview-panel .wsdb-view-item-head {
    grid-template-columns: 60px minmax(0, 1fr);
    padding: 9px 12px;
  }

  .item-ad-preview-panel .wsdb-view-item-head .rarity-pill {
    grid-column: 2;
    justify-self: start;
  }

  .item-ad-preview-panel .wsdb-view-body {
    grid-template-columns: repeat(4, 56px);
    column-gap: 16px;
    row-gap: 18px;
    padding: 10px 12px 14px;
  }

  .item-ad-preview-panel .wsdb-stat-section h3 {
    font-size: 16px;
  }

  .item-ad-preview-panel .wsdb-stat-section.requirements .wsdb-stat-grid {
    grid-template-columns: 56px;
  }

  .item-ad-preview-panel .wsdb-stat-section.parameters .wsdb-stat-grid {
    grid-template-columns: repeat(3, 56px);
    column-gap: 16px;
  }

  .item-ad-preview-panel .wsdb-stat-section.bonuses .wsdb-stat-grid {
    grid-template-columns: repeat(4, 56px);
    column-gap: 16px;
  }

  .item-ad-preview-panel .wsdb-stat-section.enchants .wsdb-stat-grid {
    grid-template-columns: repeat(2, 56px);
    column-gap: 8px;
  }

  .item-ad-preview-panel .wsdb-stat-slot {
    width: 56px;
    height: 56px;
    flex-basis: 56px;
    background-size: 168px 112px;
    background-position: 0 -56px;
  }

  .item-ad-preview-panel .wsdb-stat-slot img,
  .item-ad-preview-panel .wsdb-empty-slot::after {
    left: 10px;
    top: 9px;
    width: 36px;
    height: 36px;
  }

  .item-ad-preview-panel .wsdb-stat-slot strong {
    font-size: 12px;
  }

  .item-ad-preview-panel .wsdb-level-slot strong {
    font-size: 26px;
  }
}

/* Admin: monitoramento e estoque rapido */
.admin-stock-overview {
  display: grid;
  grid-template-columns: repeat(4, minmax(110px, 1fr));
  gap: 8px;
  margin: 0 0 12px;
}

.admin-stock-card {
  min-height: 62px;
  display: grid;
  align-content: center;
  gap: 4px;
  padding: 8px 10px;
  border: 1px solid rgba(255,215,0,0.55);
  border-radius: 8px;
  background:
    linear-gradient(180deg, rgba(65,45,94,0.72), rgba(15,18,32,0.76)),
    rgba(0,0,0,0.28);
  color: #fff;
  box-shadow: inset 0 0 0 1px rgba(255,255,255,0.07), 0 3px 0 rgba(0,0,0,0.55);
  cursor: pointer;
  text-align: left;
}

.admin-stock-card span {
  color: #ffea00;
  font: 900 24px/1 var(--number-font);
  text-shadow: 2px 2px 0 #000;
}

.admin-stock-card small {
  color: rgba(255,255,255,0.82);
  font-weight: 900;
  text-transform: uppercase;
  text-shadow: 1px 1px 0 #000;
}

.admin-stock-card.is-ok { border-color: rgba(80,230,130,0.62); }
.admin-stock-card.is-low { border-color: rgba(255,215,0,0.9); }
.admin-stock-card.is-out { border-color: rgba(255,80,80,0.72); }

.admin-card .market-ad-row.admin-stock-row {
  grid-template-columns: 72px minmax(220px, 1fr) 178px 250px 92px;
  gap: 10px;
}

.admin-stock-row.stock-low {
  background: rgba(115, 86, 20, 0.26);
}

.admin-stock-row.stock-out {
  background: rgba(90, 18, 24, 0.3);
}

.admin-stock-cell {
  display: grid;
  gap: 6px;
  justify-items: start;
}

.admin-stock-state {
  min-width: 74px;
  min-height: 22px;
  display: inline-grid;
  place-items: center;
  padding: 2px 8px;
  border: 1px solid rgba(255,215,0,0.45);
  border-radius: 7px;
  background: rgba(0,0,0,0.34);
  color: #fff;
  font-size: 12px;
  font-weight: 900;
  text-transform: uppercase;
  text-shadow: 1px 1px 0 #000;
}

.admin-stock-state.stock-ok {
  border-color: rgba(80,230,130,0.72);
  color: #72f0a2;
}

.admin-stock-state.stock-low {
  border-color: rgba(255,215,0,0.9);
  color: #ffea00;
}

.admin-stock-state.stock-out {
  border-color: rgba(255,80,80,0.85);
  color: #ff7a7a;
}

.admin-stock-quick {
  display: grid;
  grid-template-columns: 38px 38px minmax(48px, auto) 38px 38px;
  align-items: center;
  gap: 4px;
  padding: 4px;
  border: 1px solid rgba(255,215,0,0.74);
  border-radius: 9px;
  background:
    linear-gradient(180deg, rgba(46,33,78,0.76), rgba(11,15,30,0.72)),
    rgba(0,0,0,0.25);
  box-shadow: inset 0 0 0 1px rgba(255,255,255,0.08), 0 3px 0 rgba(0,0,0,0.5);
}

.admin-stock-quick button {
  width: 38px;
  height: 30px;
  border: 1px solid rgba(255,215,0,0.86);
  border-radius: 7px;
  background: linear-gradient(180deg, #6540a0, #20143f);
  color: #ffea00;
  cursor: pointer;
  font-size: 13px;
  font-weight: 900;
  text-shadow: 1px 1px 0 #000;
}

.admin-stock-quick button:hover {
  background: linear-gradient(180deg, #7d53bd, #2c1a54);
  transform: translateY(-1px);
}

.admin-stock-quick .stock-qty {
  min-width: 48px;
  color: #fff7a6;
  font-size: 22px;
  font-weight: 900;
  text-align: center;
  text-shadow: 1px 1px 0 #000;
}

@media (max-width: 1120px) {
  .admin-card .market-ad-row.admin-stock-row {
    grid-template-columns: 72px minmax(180px, 1fr) 178px 1fr;
  }

  .admin-stock-cell {
    grid-column: 2 / 4;
    grid-row: 2;
  }

  .admin-stock-row .market-ad-actions {
    grid-column: 4;
    grid-row: 1 / span 2;
  }
}

@media (max-width: 760px) {
  .admin-stock-overview {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }

  .admin-card .market-ad-row.admin-stock-row {
    grid-template-columns: 72px minmax(0, 1fr);
  }

  .admin-stock-cell,
  .admin-stock-row .market-ad-price,
  .admin-stock-row .market-ad-actions {
    grid-column: 1 / -1;
    grid-row: auto;
  }

  .admin-stock-quick {
    grid-template-columns: 38px 38px minmax(48px, auto) 38px 38px;
    max-width: 100%;
  }
}

/* Admin: compactar estoque/preco para evitar sobreposicao lateral */
.admin-card .market-ad-row.admin-stock-row {
  grid-template-columns: 72px minmax(200px, 1fr) 148px 198px 82px;
  gap: 8px;
}

.admin-stock-row .market-ad-price {
  width: 148px;
  min-width: 148px;
  grid-template-columns: 34px minmax(0, 1fr);
  gap: 6px;
}

.admin-stock-row .market-coin-dot {
  width: 32px;
  height: 32px;
}

.admin-stock-row .market-ad-price > div {
  min-height: 36px;
  padding: 4px 8px;
  border-width: 2px;
}

.admin-stock-row .market-ad-price strong {
  font-size: 14px;
}

.admin-stock-cell {
  gap: 5px;
}

.admin-stock-state {
  min-width: 64px;
  min-height: 20px;
  padding: 2px 7px;
  font-size: 11px;
}

.admin-stock-quick {
  grid-template-columns: 31px 31px 42px 31px 31px;
  gap: 3px;
  padding: 3px;
  border-radius: 8px;
}

.admin-stock-quick button {
  width: 31px;
  height: 28px;
  border-radius: 6px;
  font-size: 11px;
}

.admin-stock-quick .stock-qty {
  min-width: 42px;
  font-size: 18px;
}

.admin-stock-quick {
  padding: 0;
  border: 0;
  border-radius: 0;
  background: transparent;
  box-shadow: none;
}

.admin-stock-quick .stock-qty {
  min-width: 34px;
  padding: 0;
  border: 0;
  background: transparent;
  box-shadow: none;
  color: #fff7a6;
  font-size: 18px;
  line-height: 28px;
  text-align: center;
}

.admin-stock-row .market-ad-actions .admin-button {
  min-width: 70px;
  padding: 5px 8px;
}

@media (max-width: 1120px) {
  .admin-card .market-ad-row.admin-stock-row {
    grid-template-columns: 72px minmax(180px, 1fr) 148px 210px;
  }

  .admin-stock-cell {
    grid-column: 4;
    grid-row: 1;
  }

  .admin-stock-row .market-ad-actions {
    grid-column: 4;
    grid-row: 2;
    grid-template-columns: repeat(2, max-content);
    justify-content: start;
  }
}

@media (max-width: 860px) {
  .admin-card .market-ad-row.admin-stock-row {
    grid-template-columns: 72px minmax(0, 1fr) 148px;
  }

  .admin-stock-cell {
    grid-column: 2 / -1;
    grid-row: 2;
  }

  .admin-stock-row .market-ad-actions {
    grid-column: 2 / -1;
    grid-row: 3;
  }
}

/* Login comprador WsMkt */
.auth-panel {
  width: min(94vw, 860px);
}

.auth-panel .auth-header {
  min-height: 88px;
}

.auth-panel .auth-header .title {
  color: #ffea00;
  font-size: clamp(28px, 3vw, 36px);
  text-shadow: 2px 2px 0 #000;
}

.auth-panel .auth-shell {
  grid-template-columns: 270px minmax(0, 1fr);
  gap: 22px;
  padding: 26px;
}

.auth-panel .auth-emblem,
.auth-panel .auth-card {
  border-color: rgba(255,215,0,0.58);
  background:
    linear-gradient(180deg, rgba(18, 30, 45, 0.72), rgba(8, 14, 24, 0.68)),
    rgba(0,0,0,0.28);
  box-shadow:
    inset 0 0 0 1px rgba(255,255,255,0.06),
    0 4px 0 rgba(0,0,0,0.42);
}

.auth-panel .auth-card {
  min-width: 0;
  gap: 16px;
  padding: 24px 26px;
}

.auth-panel .auth-emblem strong {
  color: #ffea00;
  font-size: 28px;
}

.auth-panel .auth-field {
  gap: 8px;
  color: #ffea00;
  font-size: 16px;
  text-shadow: 1px 1px 0 #000;
}

.auth-panel .auth-field input {
  width: 100%;
  min-height: 42px;
  padding: 10px 14px;
  border: 1px solid rgba(255,215,0,0.58);
  border-radius: 9px;
  background:
    linear-gradient(180deg, rgba(18, 22, 26, 0.9), rgba(5, 7, 10, 0.88)),
    rgba(0,0,0,0.64);
  color: #fff;
  font-size: 16px;
  box-sizing: border-box;
  outline: none;
  box-shadow: inset 0 0 0 1px rgba(0,0,0,0.48);
  transition: border-color 160ms ease, box-shadow 160ms ease, background 160ms ease;
}

.auth-panel .auth-field input:hover {
  border-color: rgba(255,215,0,0.78);
}

.auth-panel .auth-field input:focus,
.auth-panel .auth-field input:focus-visible {
  border-color: #ffea00 !important;
  outline: none !important;
  box-shadow:
    inset 0 0 0 1px rgba(0,0,0,0.56),
    0 0 0 2px rgba(255,215,0,0.24),
    0 0 14px rgba(255,215,0,0.2) !important;
}

.auth-panel .auth-field input::placeholder {
  color: rgba(255,255,255,0.48);
}

.auth-panel .auth-submit {
  min-height: 54px;
  border-color: rgba(255,215,0,0.9);
  font-size: 20px;
}

/* Switch link entre login/cadastro */
.auth-switch {
  text-align: center;
  color: rgba(255,255,255,0.6);
  font-size: 13px;
  font-weight: 600;
}
.auth-switch a {
  color: #ffea00;
  text-decoration: none;
  font-weight: 900;
}
.auth-switch a:hover {
  text-decoration: underline;
}

/* Profile info rows */
.profile-info {
  display: grid;
  gap: 10px;
}
.profile-row {
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding: 8px 0;
  border-bottom: 1px solid rgba(255,215,0,0.18);
}
.profile-row span {
  color: rgba(255,255,255,0.6);
  font-size: 13px;
  font-weight: 700;
}
.profile-row strong {
  color: #ffea00;
  font-size: 15px;
  text-shadow: 1px 1px 0 #000;
}

@media (max-width: 760px) {
  .auth-panel {
    width: 96vw;
  }

  .auth-panel .auth-shell {
    grid-template-columns: 1fr;
    gap: 14px;
    padding: 16px;
  }

  .auth-panel .auth-emblem {
    min-height: 140px;
  }

  .auth-panel .auth-card {
    padding: 18px;
  }
}

/* Login comprador limpo: conteudo direto no fundo principal */
.auth-panel .auth-shell {
  align-items: center;
  background: transparent;
}

.auth-panel .auth-emblem,
.auth-panel .auth-card {
  border: 0;
  border-radius: 0;
  background: transparent;
  box-shadow: none;
}

.auth-panel .auth-emblem {
  min-height: 260px;
}

.auth-panel .auth-card {
  padding: 10px 4px;
}

.auth-panel .auth-header .title,
.auth-panel .auth-emblem strong,
.auth-panel .auth-field {
  -webkit-text-stroke: 0.6px #050505;
  text-shadow:
    -1px -1px 0 #050505,
     1px -1px 0 #050505,
    -1px  1px 0 #050505,
     1px  1px 0 #050505,
     0 2px 0 #000;
}

.auth-panel .auth-emblem span {
  color: #f3f3f3;
  font-weight: 900;
  text-shadow:
    -1px -1px 0 #050505,
     1px -1px 0 #050505,
    -1px  1px 0 #050505,
     1px  1px 0 #050505;
}

.auth-panel .auth-orb {
  width: 112px;
  height: 112px;
  position: relative;
  display: block;
  border: 0;
  border-radius: 0;
  background-color: transparent;
  background-image: url("../images/wsdb_slot_frame.png");
  background-repeat: no-repeat;
  background-size: 336px 224px;
  background-position: 0 -112px;
  image-rendering: pixelated;
}

.auth-panel .auth-orb::after {
  content: "";
  position: absolute;
  left: 15px;
  top: 13px;
  width: 82px;
  height: 82px;
  background-image: url("../images/uploads/gold_coin.png");
  background-repeat: no-repeat;
  background-position: left top;
  background-size: 188.235% 188.235%;
  image-rendering: pixelated;
}

/* Auth/home role actions */
.primary-market-row {
  min-height: 72px;
}

/* Auth buttons — dentro do footer do painel, ao lado do FECHAR */
.home-footer-bar {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 10px;
}

/* =====================================================
   AUTH IMAGE BUTTONS — sem fundo/borda/herança global
   ===================================================== */
.auth-image-button,
.auth-image-button:hover,
.auth-image-button:focus,
.auth-image-button:focus-visible,
.auth-image-button:active {
  background: transparent;
  background-color: transparent;
  border: none;
  border-radius: 0;
  box-shadow: none;
  outline: none;
  color: inherit;
  font-weight: normal;
  text-shadow: none;
}

.auth-image-button {
  padding: 0;
  margin: 0;
  cursor: pointer;
  display: block;
  width: 100%;
  line-height: 0;
}

.auth-image-button img {
  width: 100%;
  max-width: 80px;
  height: auto;
  display: block;
  margin: 0 auto;
  transition:
    transform 0.12s ease,
    filter 0.12s ease;
}

.auth-image-button:hover img {
  transform: translateY(2px) scale(0.98);
  filter: brightness(1.08);
}

.auth-image-button:active img {
  transform: translateY(5px) scale(0.95);
  filter: brightness(0.92);
}

/* Variante inline para footer (FECHAR + auth lado a lado) */
.auth-image-inline {
  display: inline-block;
  width: auto;
}

.auth-image-inline img {
  max-width: 80px;
  height: auto;
  vertical-align: middle;
}

.muted-row {
  cursor: default;
  opacity: 0.72;
}

/* Cart */
.cart-row {
  display: grid;
  grid-template-columns: 44px minmax(0, 1fr) auto 32px;
  gap: 10px;
  align-items: center;
  padding: 12px 14px;
  border-bottom: 2px solid var(--gold-border);
  background: var(--row-default);
}

.cart-row-icon {
  width: 38px;
  height: 38px;
  object-fit: contain;
  border-radius: 4px;
}

.cart-row-main {
  display: grid;
  gap: 2px;
  min-width: 0;
}

.cart-row-main strong,
.cart-row-main span,
.cart-row-main small {
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.cart-row-main span,
.cart-row-main small {
  color: rgba(255, 255, 255, 0.66);
  font-size: 12px;
}

.cart-qty-control {
  display: grid;
  grid-template-columns: 28px 34px 28px;
  align-items: center;
  border: 1px solid rgba(212, 175, 55, 0.45);
  border-radius: 5px;
  overflow: hidden;
}

.cart-qty-control button,
.cart-remove-btn {
  min-height: 30px;
  border: 0;
  background: rgba(0, 0, 0, 0.34);
  color: var(--gold);
  cursor: pointer;
  font-weight: 900;
}

.cart-qty-control span {
  text-align: center;
  color: #fff;
  font-weight: 800;
}

.cart-remove-btn {
  border: 1px solid rgba(212, 175, 55, 0.35);
  border-radius: 5px;
}

.cart-total-line {
  display: flex;
  justify-content: space-between;
  align-items: center;
  flex-wrap: wrap;
  gap: 10px;
  padding: 14px;
  border-bottom: 2px solid var(--gold-border);
  background: rgba(0, 0, 0, 0.30);
  font-weight: 900;
}

.cart-total-line strong {
  min-width: 0;
  text-align: right;
}

/* Seller dashboard */
.seller-metrics-grid {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 8px;
  margin-bottom: 12px;
}

.seller-admin-grid {
  display: grid;
  grid-template-columns: minmax(0, 1fr) minmax(0, 1fr);
  gap: 12px;
  margin-bottom: 12px;
}

.seller-store-card p {
  margin: 0;
  color: rgba(255, 255, 255, 0.68);
  font-size: 13px;
}

.seller-review-row {
  display: grid;
  gap: 3px;
  padding: 8px 0;
  border-bottom: 1px solid rgba(212, 175, 55, 0.18);
}

.seller-review-row:last-child {
  border-bottom: 0;
}

.seller-review-row span,
.seller-review-row small {
  color: rgba(255, 255, 255, 0.68);
  font-size: 12px;
}

@media (max-width: 620px) {
  .cart-row {
    grid-template-columns: 40px minmax(0, 1fr);
  }

  .cart-qty-control,
  .cart-remove-btn {
    grid-column: 2;
    justify-self: start;
  }

  .seller-metrics-grid,
  .seller-admin-grid {
    grid-template-columns: 1fr;
  }
}

.auth-panel .auth-orb img {
  opacity: 0;
}

.auth-panel .auth-field input {
  border-color: rgba(255,215,0,0.62);
}

.auth-panel .auth-field input:focus,
.auth-panel .auth-field input:focus-visible {
  border-color: #ffea00 !important;
}

@media (max-width: 760px) {
  .auth-panel .auth-emblem {
    min-height: 150px;
  }

  .auth-panel .auth-orb {
    width: 88px;
    height: 88px;
    background-size: 264px 176px;
    background-position: 0 -88px;
  }

  .auth-panel .auth-orb::after {
    left: 14px;
    top: 12px;
    width: 60px;
    height: 60px;
  }
}

/* Auth WSDB/RPG account panels */
.auth-panel {
  width: min(96vw, 610px);
  max-height: calc(var(--vh) * 96);
  border: 2px solid #e0b44d;
  background-image:
    linear-gradient(rgba(84, 68, 53, 0.54), rgba(84, 68, 53, 0.54)),
    var(--bg-url);
  background-repeat: repeat;
  background-size:
    auto,
    calc(var(--img-w) * var(--tile-scale-panel))
    calc(var(--img-h) * var(--tile-scale-panel));
  box-shadow:
    0 0 0 1px rgba(92, 48, 14, 0.95),
    inset 0 0 0 1px rgba(255, 238, 143, 0.18),
    0 18px 42px rgba(0, 0, 0, 0.55);
}

.auth-panel::before,
.auth-panel::after {
  content: "";
  position: absolute;
  bottom: 0;
  width: 44px;
  height: 42px;
  background-image: var(--wsdb-corner-image);
  background-repeat: no-repeat;
  background-size: 44px 42px;
  image-rendering: pixelated;
  pointer-events: none;
  z-index: 8;
}

.auth-panel::before {
  left: 0;
  transform: scaleY(-1);
}

.auth-panel::after {
  right: 0;
  transform: scale(-1, -1);
}

.auth-panel .corner {
  width: 44px;
  height: 42px;
  background-image: var(--wsdb-corner-image);
  background-repeat: no-repeat;
  background-size: 44px 42px;
  image-rendering: pixelated;
  z-index: 8;
}

.auth-panel .corner.top-left {
  top: 0;
  left: 0;
}

.auth-panel .corner.top-right {
  top: 0;
  right: 0;
  transform: scaleX(-1);
}

.auth-panel .auth-header {
  min-height: 52px;
  padding: 10px 58px;
  border-bottom: 1px solid rgba(125, 72, 29, 0.74);
  background-image:
    linear-gradient(rgba(181, 92, 35, 0.76), rgba(181, 92, 35, 0.76)),
    var(--bg-url);
  background-repeat: repeat;
  background-size:
    auto,
    calc(var(--img-w) * var(--tile-scale-panel))
    calc(var(--img-h) * var(--tile-scale-panel));
  background-blend-mode: multiply, normal;
}

.auth-panel .auth-header .title {
  color: #ffea00;
  font-size: clamp(20px, 3.2vw, 26px);
  line-height: 1.15;
  letter-spacing: 0;
  -webkit-text-stroke: 0.4px #161000;
  text-shadow:
    -1px -1px 0 #000,
     1px -1px 0 #000,
    -1px  1px 0 #000,
     1px  1px 0 #000,
     0 2px 0 #000;
}

.auth-panel .back-button {
  left: 54px;
  color: #ffea00;
  text-shadow: 1px 1px 0 #000;
}

.auth-panel .auth-shell {
  display: block;
  padding: 26px 30px 32px;
  background: transparent;
  overflow-y: auto;
  overflow-x: hidden;
}

.auth-panel .auth-emblem {
  display: none;
}

.auth-panel .auth-card {
  display: grid;
  gap: 17px;
  padding: 0;
  border: 0;
  border-radius: 0;
  background: transparent;
  box-shadow: none;
}

.auth-panel .auth-field {
  display: grid;
  gap: 9px;
  color: #fff;
  font-size: clamp(18px, 3.8vw, 24px);
  line-height: 1.1;
  font-weight: 800;
  -webkit-text-stroke: 0;
  text-shadow:
    -1px -1px 0 #000,
     1px -1px 0 #000,
    -1px  1px 0 #000,
     1px  1px 0 #000,
     0 2px 0 #000;
}

.auth-panel .auth-field input {
  width: 100%;
  min-height: 64px;
  padding: 10px 18px;
  border: 3px solid #e1d99d;
  border-left-color: #b18b43;
  border-right-color: #b18b43;
  border-radius: 20px;
  background:
    linear-gradient(180deg, #2e3228, #272b22);
  color: #fff;
  font-size: 20px;
  line-height: 1.2;
  box-sizing: border-box;
  outline: none;
  box-shadow:
    inset 0 0 0 2px rgba(40, 29, 10, 0.72),
    0 0 0 1px rgba(93, 57, 20, 0.8);
}

.auth-panel .auth-field input:hover {
  border-color: #fff0a9;
}

.auth-panel .auth-field input:focus,
.auth-panel .auth-field input:focus-visible {
  border-color: #fff3ae !important;
  box-shadow:
    inset 0 0 0 2px rgba(40, 29, 10, 0.72),
    0 0 0 2px rgba(255, 234, 0, 0.34),
    0 0 14px rgba(255, 234, 0, 0.24) !important;
}

.auth-panel .auth-field input::placeholder {
  color: rgba(255, 255, 255, 0.36);
}

.auth-panel .login-btn {
  border: 2px solid #e6b15c;
  border-radius: 8px;
  background:
    linear-gradient(180deg, #9fb2ff 0 20%, #6b7dd2 21% 56%, #5754a6 57% 100%);
  color: #ffeb55;
  font-size: clamp(24px, 5vw, 34px);
  line-height: 1.05;
  font-weight: 400;
  text-align: center;
  text-shadow: 1px 1px 0 rgba(0, 0, 0, 0.75);
  box-shadow:
    inset 0 3px 0 rgba(255, 255, 255, 0.2),
    inset 0 -4px 0 rgba(35, 38, 103, 0.45),
    0 3px 0 rgba(77, 38, 12, 0.9);
}

.auth-panel .login-btn:hover {
  background:
    linear-gradient(180deg, #b5c4ff 0 20%, #788ae2 21% 56%, #625eb6 57% 100%);
  transform: translateY(-1px);
}

.auth-panel .login-btn:active {
  transform: translateY(2px);
  box-shadow:
    inset 0 2px 0 rgba(255, 255, 255, 0.13),
    inset 0 -2px 0 rgba(35, 38, 103, 0.45),
    0 1px 0 rgba(77, 38, 12, 0.9);
}

.auth-panel .auth-submit {
  width: 100%;
  min-height: 74px;
  margin-top: 2px;
  padding: 10px 14px;
}

.auth-panel .auth-switch {
  color: #fff;
  font-size: 15px;
  font-weight: 800;
  text-shadow: 1px 1px 0 #000;
}

.auth-panel .auth-switch a {
  color: #ffea00;
  text-shadow: 1px 1px 0 #000;
}

.auth-panel .auth-footer {
  display: none;
}

.auth-panel .profile-card,
.auth-panel .profile-info {
  gap: 16px;
}

.auth-panel .profile-line,
.auth-panel .profile-row {
  display: grid;
  gap: 10px;
  padding: 0 4px 10px;
  border-bottom: 2px solid rgba(255, 255, 255, 0.74);
}

.auth-panel .profile-line span,
.auth-panel .profile-row span {
  color: #fff;
  font-size: clamp(18px, 3.8vw, 24px);
  font-weight: 800;
  text-shadow:
    -1px -1px 0 #000,
     1px -1px 0 #000,
    -1px  1px 0 #000,
     1px  1px 0 #000,
     0 2px 0 #000;
}

.auth-panel .profile-line strong,
.auth-panel .profile-row strong {
  color: #fff;
  font-size: clamp(17px, 3.6vw, 23px);
  font-weight: 800;
  word-break: break-word;
  text-shadow:
    -1px -1px 0 #000,
     1px -1px 0 #000,
    -1px  1px 0 #000,
     1px  1px 0 #000,
     0 2px 0 #000;
}

.auth-panel .auth-actions {
  display: grid;
  gap: 14px;
  margin-top: 2px;
}

@media (max-width: 520px) {
  .auth-panel {
    width: 96vw;
    margin: 8px auto;
  }

  .auth-panel .auth-header {
    min-height: 48px;
    padding: 10px 48px;
  }

  .auth-panel .auth-shell {
    padding: 22px 20px 28px;
  }

  .auth-panel .auth-field input {
    min-height: 56px;
    border-radius: 18px;
    font-size: 18px;
  }

  .auth-panel .auth-submit {
    min-height: 66px;
  }
}

body.auth-page .mobile-nav {
  display: none;
}

/* Admin login uses the same account/auth visual language. */
.admin-login-panel {
  width: min(96vw, 610px);
  border: 2px solid #e0b44d;
  background-image:
    linear-gradient(rgba(84, 68, 53, 0.54), rgba(84, 68, 53, 0.54)),
    var(--bg-url);
  box-shadow:
    0 0 0 1px rgba(92, 48, 14, 0.95),
    inset 0 0 0 1px rgba(255, 238, 143, 0.18),
    0 18px 42px rgba(0, 0, 0, 0.55);
}

.admin-login-panel .admin-login-layout {
  display: block;
  padding: 26px 30px 32px;
  background: transparent;
}

.admin-login-panel .admin-login-brand {
  display: none;
}

.admin-login-panel .admin-login-box {
  display: grid;
  gap: 14px;
  padding: 0;
  border: 0;
  background: transparent;
  box-shadow: none;
}

.admin-login-panel .admin-login-box h2 {
  margin: -8px 0 10px;
  color: #ffea00;
  font-size: clamp(20px, 3.2vw, 26px);
  text-align: center;
  text-shadow:
    -1px -1px 0 #000,
     1px -1px 0 #000,
    -1px  1px 0 #000,
     1px  1px 0 #000,
     0 2px 0 #000;
}

.admin-login-panel .admin-login-box label {
  color: #fff;
  font-size: clamp(18px, 3.8vw, 24px);
  font-weight: 800;
  text-shadow:
    -1px -1px 0 #000,
     1px -1px 0 #000,
    -1px  1px 0 #000,
     1px  1px 0 #000,
     0 2px 0 #000;
}

.admin-login-panel .admin-login-box input {
  width: 100%;
  min-height: 64px;
  padding: 10px 18px;
  border: 3px solid #e1d99d;
  border-left-color: #b18b43;
  border-right-color: #b18b43;
  border-radius: 20px;
  background: linear-gradient(180deg, #2e3228, #272b22);
  color: #fff;
  font-size: 20px;
  box-sizing: border-box;
  outline: none;
}

.admin-login-panel .login-submit,
.admin-login-panel .login-btn {
  width: 100%;
  min-height: 74px;
  border: 2px solid #e6b15c;
  border-radius: 8px;
  background:
    linear-gradient(180deg, #9fb2ff 0 20%, #6b7dd2 21% 56%, #5754a6 57% 100%);
  color: #ffeb55;
  font-size: clamp(24px, 5vw, 34px);
  font-weight: 400;
  text-align: center;
  text-shadow: 1px 1px 0 rgba(0, 0, 0, 0.75);
  box-shadow:
    inset 0 3px 0 rgba(255, 255, 255, 0.2),
    inset 0 -4px 0 rgba(35, 38, 103, 0.45),
    0 3px 0 rgba(77, 38, 12, 0.9);
}
