/* ===== MOBILE FIRST (theo mockup) ===== */
:root {
  --bg: #f8fbfd;
  --card: #ffffff;
  --muted: #8d9aa6;
  --text: #1f2a37;
  --mint: #e8fbf6;
  --shadow: 0 8px 20px rgba(31, 42, 55, 0.08);
}

* {
  box-sizing: border-box;
  margin: 0;
  padding: 0;
}

html,
body {
  height: 100%;
}

body {
  font-family: ui-sans-serif, system-ui, -apple-system, Segoe UI, Roboto, sans-serif;
  color: var(--text);
  background: var(--bg);
}

body.contact-popup-open {
  overflow: hidden;
}

.contact-popup-modal {
  position: fixed;
  inset: 0;
  z-index: 12050;
  display: none;
}

.contact-popup-modal.show {
  display: block;
}

.contact-popup-backdrop {
  position: absolute;
  inset: 0;
  background: rgba(15, 23, 42, 0.55);
  backdrop-filter: blur(6px);
}

.contact-popup-sheet {
  position: absolute;
  left: 50%;
  bottom: 18px;
  transform: translateX(-50%) translateY(18px);
  width: calc(100% - 28px);
  max-width: 520px;
  background: rgba(255, 255, 255, 0.98);
  border: 1px solid rgba(148, 163, 184, 0.35);
  border-radius: 18px;
  box-shadow: 0 30px 60px rgba(0, 0, 0, 0.35);
  padding: 14px 14px 16px;
  opacity: 0;
  transition: transform 0.22s ease, opacity 0.22s ease;
}

.contact-popup-modal.show .contact-popup-sheet {
  transform: translateX(-50%) translateY(0);
  opacity: 1;
}

.contact-popup-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 10px;
}

.contact-popup-title {
  font-weight: 900;
  font-size: 16px;
  color: #0f172a;
}

.contact-popup-close {
  width: 38px;
  height: 38px;
  border-radius: 12px;
  border: 1px solid rgba(148, 163, 184, 0.35);
  background: #f8fafc;
  color: #0f172a;
  font-size: 24px;
  line-height: 1;
  cursor: pointer;
}

.contact-popup-subtitle {
  margin-top: 6px;
  color: #475569;
  font-size: 14px;
  font-weight: 600;
}

.contact-popup-grid {
  margin-top: 14px;
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: 10px;
}

@media (min-width: 420px) {
  .contact-popup-grid {
    grid-template-columns: repeat(5, minmax(0, 1fr));
  }
}

.contact-popup-item {
  text-decoration: none;
  background: #ffffff;
  border: 1px solid rgba(226, 232, 240, 0.95);
  border-radius: 14px;
  padding: 10px 8px;
  display: grid;
  gap: 8px;
  place-items: center;
  transition: transform 0.15s ease, box-shadow 0.15s ease, border-color 0.15s ease;
}

.contact-popup-item:hover {
  transform: translateY(-2px);
  border-color: rgba(14, 165, 233, 0.55);
  box-shadow: 0 10px 24px rgba(14, 165, 233, 0.15);
}

.contact-popup-icon {
  width: 42px;
  height: 42px;
  border-radius: 14px;
  display: grid;
  place-items: center;
  background: linear-gradient(135deg, rgba(14, 165, 233, 0.14), rgba(107, 253, 181, 0.22));
  border: 1px solid rgba(14, 165, 233, 0.16);
}

.contact-popup-icon svg {
  width: 22px;
  height: 22px;
  fill: #0f172a;
}

.contact-popup-label {
  font-size: 11px;
  font-weight: 800;
  color: #0f172a;
}

.contact-popup-empty {
  grid-column: 1 / -1;
  padding: 12px;
  text-align: center;
  color: #475569;
  font-weight: 700;
  font-size: 13px;
}

.page {
  min-height: 100vh;
  display: flex;
  flex-direction: column;
}

/* ===== HEADER - Banner Trung Thu ===== */
/* ===== HEADER ===== */
/* ===== HEADER ===== */
.header {
  height: 65px !important;
  display: flex !important;
  align-items: center !important;
  justify-content: space-between !important;
  padding: 0 20px !important;
  background: var(--bg);
  box-shadow: 0 2px 10px rgba(0, 0, 0, 0.05);
  /* Keep shadow */
  position: relative;
  z-index: 50;
}

.logo img {
  height: 40px;
  /* Adjust to fit 65px height (65 - 20 padding? No, padding is horizontal. Height is fixed.) */
  /* If height is 65px and we want items centered, logo max-height should be ~40-50px */
  max-height: 45px;
  width: auto;
  display: block;
  object-fit: contain;
  margin: 0;
}

/* Remove legacy top-bar if it exists in other files, but here we cleaner it */

/* Header actions (from auth-helper) */
.header-actions {
  display: flex;
  gap: 10px;
  align-items: center;
}

.user-info {
  display: flex;
  align-items: center;
  gap: 8px;
  padding: 6px 12px;
  background: rgba(255, 255, 255, 0.1);
  border-radius: 20px;
}

.user-info img {
  width: 28px;
  height: 28px;
  border-radius: 50%;
  object-fit: cover;
}

.user-info span {
  font-size: 13px;
  font-weight: 600;
  color: #2b0a42;
}

.btn-header {
  background: linear-gradient(135deg, #ffffff 0%, #ede2f9 100%);
  color: #000000;
  border: none;
  padding: 8px 20px;
  border-radius: 20px;
  font-size: 13px;
  font-weight: 600;
  cursor: pointer;
  box-shadow: 0 4px 12px rgba(102, 126, 234, 0.3);
  transition: transform 0.2s, box-shadow 0.2s;
}

.btn-header.primary {
  background: linear-gradient(135deg, #ffffff 0%, #ffffff 100%);
}

.btn-header:hover {
  transform: translateY(-2px);
  box-shadow: 0 6px 16px rgba(102, 126, 234, 0.4);
}

.btn-login:active {
  transform: translateY(0);
}

/* Banner */
.hero {
  width: 100%;
  border-radius: 16px;
  overflow: hidden;
  box-shadow: 0 4px 20px rgba(0, 0, 0, 0.12);
  border: 1px solid rgba(0, 0, 0, 0.08);
}

.hero img {
  display: block;
  width: 100%;
  height: 120px;
  object-fit: cover;
}

/* ===== CONTENT - Cột trái + Main ===== */
.content-wrap {
  flex: 1;
  padding: 12px 12px 100px;
  display: flex;
  gap: 8px;
}

/* Cột shortcut pills bên trái - luôn sát trái */
.left-rail {
  flex-shrink: 0;
  width: 68px;
}

.pill-stack {
  display: flex;
  flex-direction: column;
  gap: 10px;
  position: sticky;
  top: 12px;
}

.pill-item {
  display: flex;
  flex-direction: column;
  align-items: center;
  text-decoration: none;
  gap: 4px;
}

.pill {
  width: 48px;
  height: 48px;
  border-radius: 12px;
  background: linear-gradient(180deg, #d4f1f9, #e0e4eb);
  box-shadow: 0 3px 10px rgba(0, 0, 0, 0.1);
  border: 2px solid rgba(255, 255, 255, 0.8);
  cursor: pointer;
  transition: transform 0.2s, box-shadow 0.2s, border-color 0.2s, background 0.2s;
  overflow: hidden;
  display: flex;
  align-items: center;
  justify-content: center;
}

.pill img {
  width: 100%;
  height: 100%;
  object-fit: cover;
}

.pill:hover {
  transform: scale(1.05);
  box-shadow: 0 5px 15px rgba(0, 0, 0, 0.15);
}

/* Active state cho pill với hiệu ứng ánh sáng */
.pill-item.active .pill {
  background: linear-gradient(135deg, #f4ed4f, #e26540);
  border: 3px solid #edeef3;
  box-shadow:
    0 0 20px rgb(255 175 73 / 70%),
    0 0 40px rgb(234 150 102 / 40%),
    0 4px 16px rgb(234 203 102 / 50%),
    inset 0 0 10px rgba(255, 255, 255, 0.3);
  animation: glow 2s ease-in-out infinite alternate;
}

@keyframes glow {
  from {
    box-shadow:
      0 0 20px rgb(29 243 255 / 60%),
      0 0 40px rgb(27 255 228 / 40%),
      0 4px 16px rgb(52 238 242 / 50%),
      inset 0 0 10px rgba(255, 255, 255, 0.3);
  }

  to {
    box-shadow:
      0 0 30px rgb(240 84 28 / 44%),
      0 0 60px rgb(244 231 165 / 78%),
      0 6px 20px rgb(240 145 18 / 70%),
      inset 0 0 15px rgba(255, 255, 255, 0.5);
  }
}

.pill-item.active .pill-label {
  color: #c23333;
  font-weight: 700;
  text-shadow: 0 0 10px rgb(234 149 102 / 50%);
}

/* ===== HOME SYSTEM POPUP (Bootstrap modal - Dark Gaming Theme) ===== */
.home-system-popup {
  z-index: 11000;
}

.home-system-popup .modal-dialog {
  max-width: 560px;
  padding: 0 12px;
}

.home-system-popup .modal-content {
  background: linear-gradient(180deg, #1a1a2e 0%, #0b0d14 100%);
  border-radius: 18px;
  border: 1px solid rgba(255, 215, 0, 0.55);
  box-shadow:
    0 25px 60px rgba(0, 0, 0, 0.55),
    0 0 0 1px rgba(0, 255, 209, 0.10),
    0 0 40px rgba(0, 255, 209, 0.12);
  overflow: hidden;
}

.home-system-popup .modal-header {
  border-bottom: 1px solid rgba(255, 255, 255, 0.08);
  background: rgba(255, 255, 255, 0.02);
  padding: 16px 18px;
}

.home-system-popup .modal-title {
  font-weight: 900;
  letter-spacing: 0.6px;
  text-transform: uppercase;
  color: #ffe28a;
  text-shadow: 0 0 16px rgba(255, 204, 0, 0.22);
  font-size: 16px;
}

.home-system-popup .modal-body {
  padding: 18px;
  color: #e5e7eb;
  font-size: 15px;
  line-height: 1.7;
  max-height: 70vh;
  overflow-y: auto;
}

.home-system-popup .modal-body::-webkit-scrollbar {
  width: 10px;
}

.home-system-popup .modal-body::-webkit-scrollbar-thumb {
  background: rgba(255, 226, 138, 0.25);
  border-radius: 999px;
  border: 2px solid rgba(18, 20, 35, 0.9);
}

.home-system-popup .modal-body::-webkit-scrollbar-track {
  background: rgba(255, 255, 255, 0.04);
}

.home-system-popup .modal-footer {
  border-top: 1px solid rgba(255, 255, 255, 0.08);
  background: rgba(255, 255, 255, 0.02);
  padding: 14px 18px;
}

.home-system-popup .btn-home-popup-close {
  min-width: 160px;
  border-radius: 999px;
  font-weight: 800;
  letter-spacing: 0.3px;
  border: 1px solid rgba(255, 215, 0, 0.55);
  color: #0b0d14;
  background: linear-gradient(135deg, #ffd86b 0%, #ffb300 55%, #ffa000 100%);
  box-shadow:
    0 12px 26px rgba(255, 179, 0, 0.22),
    0 0 0 1px rgba(0, 255, 209, 0.08);
  transition: transform 0.15s ease, box-shadow 0.15s ease, filter 0.15s ease;
}

.home-system-popup .btn-home-popup-close:hover {
  transform: translateY(-1px);
  filter: brightness(1.05);
  box-shadow:
    0 16px 34px rgba(255, 179, 0, 0.28),
    0 0 28px rgba(0, 255, 209, 0.14);
}

.home-system-popup .btn-home-popup-close:active {
  transform: translateY(0);
}

/* Hỗ trợ ảnh/banner và nội dung dài trong Pop-up */
#home-popup-content img {
  max-width: 100%;
  height: auto;
  border-radius: 8px;
  display: block;
  margin: 10px auto;
}

#home-popup-content a {
  color: #5eead4;
  text-decoration: none;
}

#home-popup-content a:hover {
  text-decoration: underline;
}

/* ===== TOP NẠP: Avatar fix (không méo, không vỡ khung) ===== */
.rank-avatar {
  width: 40px !important;
  height: 40px !important;
  border-radius: 50% !important;
  object-fit: cover !important;
  object-position: center !important;
  display: block;
}

.pill-label {
  font-size: 10px;
  color: var(--text);
  text-align: center;
  font-weight: 500;
  max-width: 68px;
  line-height: 1.2;
  transition: color 0.2s, font-weight 0.2s;
}

/* Khu vực nội dung chính */
.main-area {
  flex: 1;
  min-height: 400px;
  display: flex;
  flex-direction: column;
  color: var(--text);
  background: var(--card);
  border-radius: 12px;
  padding: 16px;
  gap: 16px;
  border: 1px solid #e8e8e8;
  box-shadow: 0 2px 12px rgba(0, 0, 0, 0.06);
}

 .main-area .tabs,
 .main-area .skyblock-container {
  width: calc(100% + 24px);
  margin-left: -12px;
  margin-right: -12px;
 }

 .main-area .tabs {
  padding-left: 2px;
  padding-right: 2px;
 }

/* Empty State */
.empty-state {
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  min-height: 400px;
  text-align: center;
  padding: 40px 20px;
}

.empty-state svg {
  color: #d0d0d0;
  margin-bottom: 20px;
}

.empty-state h3 {
  font-size: 24px;
  font-weight: 700;
  color: var(--text);
  margin: 0 0 12px;
}

.empty-state p {
  font-size: 15px;
  color: var(--muted);
  margin: 0;
  max-width: 400px;
}

/* Tabs */
.tabs {
  display: flex;
  gap: 8px;
  flex-wrap: wrap;
}

 .main-area .tabs {
  justify-content: flex-start;
 }

.tab-btn {
  background: #f5f5f5;
  border: 2px solid #e0e0e0;
  padding: 8px 18px;
  border-radius: 20px;
  font-size: 13px;
  font-weight: 600;
  color: #666;
  cursor: pointer;
  transition: all 0.2s;
}

.tab-btn.active {
  background: #fff9c4;
  border-color: #ffd54f;
  color: #333;
}

.tab-btn:hover {
  transform: translateY(-1px);
  box-shadow: 0 2px 8px rgba(0, 0, 0, 0.1);
}

/* Product Grid */
.product-grid {
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  gap: 12px;
}

/* Product Card */
/* Product Card - Light Glassmorphism */
.product-card {
  background: rgba(255, 255, 255, 0.85);
  /* Glass BG */
  backdrop-filter: blur(10px);
  -webkit-backdrop-filter: blur(10px);
  border: 1px solid rgba(255, 255, 255, 0.6);
  border-radius: 16px;
  overflow: hidden;
  box-shadow: 0 4px 20px rgba(100, 116, 139, 0.1);
  transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
  position: relative;
  display: flex;
  flex-direction: column;
}

.product-card:hover {
  transform: translateY(-5px);
  box-shadow: 0 12px 28px rgba(100, 116, 139, 0.2), 0 0 15px rgba(251, 146, 60, 0.3);
  /* Orange glow */
  background: rgba(255, 255, 255, 0.95);
  border-color: rgba(251, 146, 60, 0.4);
  z-index: 5;
}

/* SOLD STATE (Account đã bán) */
.product-card.is-sold {
  filter: none;
  opacity: 1;
}

.product-card.is-sold:hover {
  transform: none;
  box-shadow: 0 2px 8px rgba(0, 0, 0, 0.06);
  border-color: rgba(0, 0, 0, 0.12);
}

.product-card.is-sold .product-image {
  pointer-events: none;
}

.product-card.is-sold .product-image img {
  filter: grayscale(100%);
  opacity: 0.55;
}

.product-card.is-sold .product-info {
  opacity: 0.65;
}

.product-card.is-sold .product-badge,
.product-card.is-sold .product-tag,
.product-card.is-sold .product-price-current,
.product-card.is-sold .product-price-new,
.product-card.is-sold .product-price-old {
  opacity: 0.75;
}

.btn-card-action.sold {
  background: #e2e8f0;
  color: #64748b;
  border-color: #cbd5e1;
  cursor: not-allowed;
  pointer-events: none;
}

.product-badge {
  position: absolute;
  top: 8px;
  left: 8px;
  background: rgba(15, 23, 42, 0.8);
  color: white;
  padding: 4px 10px;
  border-radius: 12px;
  font-size: 11px;
  font-weight: 800;
  letter-spacing: 0.2px;
  backdrop-filter: blur(6px);
  z-index: 10;
  box-shadow: 0 2px 8px rgba(0, 0, 0, 0.2);
}

/* Sold Stamp Style */
.sold-stamp {
  position: absolute;
  top: 50%;
  left: 50%;
  transform: translate(-50%, -50%) rotate(-15deg);
  border: 3px solid #ef4444;
  color: #ef4444;
  font-size: 24px;
  font-weight: 900;
  padding: 8px 16px;
  text-transform: uppercase;
  border-radius: 8px;
  opacity: 0.95;
  z-index: 9999;
  background: transparent;
  box-shadow: 0 6px 18px rgba(0, 0, 0, 0.18);
  pointer-events: none;
  letter-spacing: 2px;
  text-shadow: 0 2px 10px rgba(255, 255, 255, 0.35);
}

.product-badge.hot {
  background: linear-gradient(135deg, #f97316, #ef4444);
}

.product-image {
  width: 100%;
  aspect-ratio: 16 / 10;
  /* Slightly taller than rental */
  overflow: hidden;
  background: #f1f5f9;
  display: block;
  position: relative;
}

.product-image img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  transition: transform 0.5s ease;
}

.product-card:hover .product-image img {
  transform: scale(1.08);
  /* Enhance zoom */
}

.product-sale-badge {
  position: absolute;
  top: 8px;
  right: 8px;
  z-index: 2;
  padding: 4px 10px;
  border-radius: 20px;
  background: linear-gradient(135deg, #ef4444, #b91c1c);
  color: #fff;
  font-size: 11px;
  font-weight: 800;
  box-shadow: 0 4px 10px rgba(239, 68, 68, 0.4);
}

.product-info {
  padding: 14px;
  flex: 1;
  display: flex;
  flex-direction: column;
}

.product-price {
  color: #d97706;
  /* Vivid Orange/Gold */
  font-size: 1.4rem;
  font-weight: 800;
  line-height: 1.2;
  margin-bottom: 4px;
  display: flex;
  align-items: baseline;
  gap: 8px;
  text-shadow: 0 0 1px rgba(217, 119, 6, 0.1);
}

.product-price-old {
  color: #94a3b8;
  font-size: 0.85rem;
  font-weight: 600;
  text-decoration: line-through;
}

.product-price-new {
  color: inherit;
  font-size: inherit;
  font-weight: inherit;
}

.product-title {
  color: #1e293b;
  /* Dark text */
  font-size: 15px;
  font-weight: 700;
  line-height: 1.4;
  margin-bottom: 8px;
  display: -webkit-box;
  -webkit-line-clamp: 2;
  line-clamp: 2;
  -webkit-box-orient: vertical;
  overflow: hidden;
}

.product-tag {
  background: rgba(224, 242, 254, 0.8);
  color: #0369a1;
  padding: 3px 8px;
  border-radius: 6px;
  font-size: 11px;
  font-weight: 700;
  display: inline-block;
  margin-bottom: 8px;
  border: 1px solid rgba(186, 230, 253, 0.6);
}

.product-tag.hot {
  background: rgba(254, 242, 242, 0.8);
  color: #b91c1c;
  border-color: rgba(254, 202, 202, 0.6);
}

.product-desc {
  font-size: 12px;
  color: #64748b;
  margin: 0 0 12px;
  line-height: 1.5;
  display: -webkit-box;
  -webkit-line-clamp: 2;
  line-clamp: 2;
  -webkit-box-orient: vertical;
  overflow: hidden;
}

.btn-view {
  width: 100%;
  background: linear-gradient(135deg, #f97316 0%, #ea580c 100%);
  /* Orange Gradient */
  border: none;
  padding: 10px 0;
  border-radius: 12px;
  font-size: 13px;
  font-weight: 700;
  cursor: pointer;
  transition: all 0.3s ease;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  text-decoration: none;
  color: white;
  text-transform: uppercase;
  margin-top: auto;
  box-shadow: 0 4px 12px rgba(249, 115, 22, 0.3);
}

.btn-view:hover {
  background: linear-gradient(135deg, #fb923c 0%, #c2410c 100%);
  transform: translateY(-2px);
  box-shadow: 0 6px 16px rgba(249, 115, 22, 0.5), 0 0 12px rgba(251, 146, 60, 0.4);
  /* Glow */
}

.btn-view.sold {
  background: linear-gradient(135deg, #e2e8f0 0%, #cbd5e1 100%);
  /* Silver */
  color: #64748b;
  box-shadow: none;
  cursor: not-allowed;
  border: 1px solid #cbd5e1;
}

.btn-view.sold:hover {
  transform: none;
  background: #cbd5e1;
}

.btn-view img {
  display: none;
  /* Hide icon for cleaner look */
}

.product-card:hover {
  transform: translateY(-4px);
  box-shadow: 0 8px 24px rgba(0, 0, 0, 0.15);
  border-color: #d0d0d0;
}

.product-badge {
  position: absolute;
  top: 8px;
  left: 8px;
  background: rgba(0, 0, 0, 0.6);
  color: white;
  padding: 4px 10px;
  border-radius: 12px;
  font-size: 11px;
  font-weight: 800;
  letter-spacing: 0.2px;
  backdrop-filter: blur(6px);
  z-index: 1;
}

.product-badge.hot {
  background: linear-gradient(135deg, #ff6b6b, #ee5a6f);
}

.product-image {
  width: 100%;
  aspect-ratio: 3 / 2;
  overflow: hidden;
  background: #f0f0f0;
  display: block;
  position: relative;
}

.product-image img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  position: absolute;
  top: 0;
  left: 0;
}

.product-sale-badge {
  position: absolute;
  top: 8px;
  right: 8px;
  z-index: 2;
  padding: 6px 12px;
  border-radius: 999px;
  background: linear-gradient(135deg, #ff1f1f, #b30000);
  color: #fff;
  font-size: 12px;
  font-weight: 900;
  letter-spacing: 0.2px;
  box-shadow: 0 10px 22px rgba(179, 0, 0, 0.45);
  pointer-events: none;
}

.product-info {
  padding: 10px;
}

.product-price {
  color: #ff3b30;
  font-size: 16px;
  font-weight: 800;
  line-height: 1.15;
  margin-bottom: 6px;
  display: flex;
  align-items: baseline;
  gap: 8px;
}

.product-price-old {
  color: #9ca3af;
  font-size: 12px;
  font-weight: 800;
  text-decoration: line-through;
}

.product-price-new {
  color: inherit;
  font-size: inherit;
  font-weight: inherit;
}

.product-title {
  color: #111;
  font-size: 18px;
  font-weight: 800;
  line-height: 1.25;
  margin-bottom: 6px;
  display: -webkit-box;
  line-clamp: 2;
  -webkit-line-clamp: 2;
  -webkit-box-orient: vertical;
  overflow: hidden;
}

.product-tag {
  background: #e3f2fd;
  color: #1976d2;
  padding: 4px 8px;
  border-radius: 8px;
  font-size: 10px;
  font-weight: 600;
  display: inline-block;
  margin-bottom: 6px;
}

.product-tag.hot {
  background: #ffebee;
  color: #c62828;
}

.product-desc {
  font-size: 12px;
  color: #555;
  margin: 0 0 10px;
  line-height: 1.4;
}

.btn-view {
  width: 100%;
  background: white;
  border: 2px solid #000;
  padding: 6px 12px;
  border-radius: 18px;
  font-size: 11px;
  font-weight: 700;
  cursor: pointer;
  transition: all 0.2s;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  text-decoration: none;
  color: #000;
  min-height: 32px;
}

.btn-view:hover {
  background: #000;
  color: white;
}

.btn-view img {
  max-width: 100%;
  max-height: 16px;
  object-fit: contain;
}

.topup-container {
  display: flex;
  flex-direction: column;
  gap: 16px;
}

.topup-header {
  display: flex;
  flex-direction: column;
  gap: 12px;
}

.topup-game-info {
  display: flex;
  gap: 12px;
  align-items: center;
}

.topup-game-icon-wrap {
  width: 54px;
  height: 54px;
  border-radius: 14px;
  overflow: hidden;
  background: #f3f4f6;
  flex-shrink: 0;
}

.topup-game-icon {
  width: 100%;
  height: 100%;
  object-fit: cover;
  display: block;
}

.topup-game-text h2 {
  font-size: 16px;
  margin: 0 0 4px;
}

.topup-game-text p {
  margin: 0;
  color: #666;
  font-size: 12px;
  line-height: 1.4;
}

.topup-warning {
  background: #fff7ed;
  border: 1px solid #fed7aa;
  border-radius: 14px;
  padding: 10px 12px;
  font-size: 12px;
  color: #7c2d12;
  display: grid;
  gap: 4px;
}

.topup-form {
  display: flex;
  flex-direction: column;
  gap: 12px;
}

.form-group {
  display: grid;
  gap: 8px;
}

.form-label {
  font-weight: 700;
  font-size: 12px;
  color: #111827;
}

.form-input {
  width: 100%;
  padding: 10px 12px;
  border-radius: 12px;
  border: 1px solid #e5e7eb;
  outline: none;
  background: #fff;
}

.form-hint {
  font-size: 12px;
  color: #6b7280;
}

.topup-packages-grid {
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  gap: 10px;
}

.topup-package-card {
  background: #ffffff;
  border: 2px solid #f0f0f0;
  border-radius: 14px;
  padding: 10px;
  cursor: pointer;
  box-shadow: 0 4px 12px rgba(0, 0, 0, 0.06);
  display: grid;
  gap: 4px;
}

.topup-package-card.selected {
  border-color: #111827;
  box-shadow: 0 10px 24px rgba(0, 0, 0, 0.12);
}

.topup-package-name {
  font-weight: 800;
  font-size: 12px;
}

.topup-package-diamonds,
.topup-package-price,
.topup-package-note {
  font-size: 11px;
  color: #4b5563;
}

.topup-paymethods {
  display: grid;
  grid-template-columns: 1fr;
  gap: 10px;
}

.topup-paymethod-card {
  background: #ffffff;
  border: 2px solid #f0f0f0;
  border-radius: 14px;
  padding: 10px;
  cursor: pointer;
}

.topup-paymethod-card.selected {
  border-color: #111827;
}

.topup-paymethod-label {
  font-weight: 800;
  font-size: 12px;
}

.topup-paymethod-desc {
  font-size: 11px;
  color: #4b5563;
  margin-top: 2px;
}

.topup-summary {
  background: #f8fafc;
  border: 1px solid #e5e7eb;
  border-radius: 14px;
  padding: 10px 12px;
  display: grid;
  gap: 8px;
}

.topup-summary-row {
  display: flex;
  justify-content: space-between;
  gap: 12px;
  font-size: 12px;
}

.form-actions {
  display: flex;
}

.btn-submit {
  width: 100%;
  min-height: 44px;
  border: 0;
  border-radius: 14px;
  background: #111827;
  color: #ffffff;
  font-weight: 800;
  cursor: pointer;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 10px;
  padding: 12px 14px;
}

.btn-submit svg {
  width: 18px;
  height: 18px;
}

.topup-history-section {
  background: #ffffff;
  border: 1px solid #e5e7eb;
  border-radius: 14px;
  padding: 12px;
}

.topup-history-header h3 {
  margin: 0 0 4px;
  font-size: 14px;
}

.topup-history-header p {
  margin: 0;
  font-size: 12px;
  color: #6b7280;
}

.sell-back-container {
  display: grid;
  gap: 12px;
}

.sell-back-tabs {
  display: flex;
  gap: 8px;
  flex-wrap: wrap;
}

.sell-back-tab-btn {
  background: #f5f5f5;
  border: 2px solid #e0e0e0;
  padding: 8px 14px;
  border-radius: 20px;
  font-size: 12px;
  font-weight: 700;
  color: #444;
  cursor: pointer;
  display: inline-flex;
  align-items: center;
  gap: 8px;
}

.sell-back-tab-btn.active {
  background: #fff9c4;
  border-color: #ffd54f;
}

.sell-back-pane {
  display: none;
}

.sell-back-pane.active {
  display: block;
}

.badge-count {
  min-width: 18px;
  height: 18px;
  border-radius: 999px;
  background: #111827;
  color: #fff;
  font-size: 11px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  padding: 0 6px;
}

.skyblock-container {
  display: grid;
  gap: 12px;
  width: 100%;
  max-width: 1200px;
  margin: 0;
}

 .main-area .skyblock-container {
  max-width: 100%;
 }

 .main-area .skyblock-controls,
 .main-area .skyblock-categories,
 .main-area .skyblock-grid {
  padding-left: 2px;
  padding-right: 2px;
 }

 .main-area .skyblock-grid {
  width: 100%;
 }

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

.search-wrapper {
  flex: 1;
  min-width: 220px;
  position: relative;
}

.search-icon {
  position: absolute;
  left: 12px;
  top: 50%;
  transform: translateY(-50%);
  color: #6b7280;
}

.skyblock-search {
  width: 100%;
  padding: 10px 12px 10px 36px;
  border-radius: 12px;
  border: 1px solid #e5e7eb;
}

.skyblock-sort {
  padding: 10px 12px;
  border-radius: 12px;
  border: 1px solid #e5e7eb;
  background: #fff;
}

.skyblock-grid {
  display: grid;
  grid-template-columns: 1fr;
  gap: 10px;
}

.skyblock-item-horizontal {
  background: #ffffff;
  border: 1px solid #e5e7eb;
  border-radius: 14px;
  padding: 10px;
  display: grid;
  grid-template-columns: 76px 1fr;
  gap: 10px;
  align-items: center;
}

.item-image-wrapper-horizontal {
  width: 76px;
  height: 56px;
  border-radius: 12px;
  overflow: hidden;
  background: #f3f4f6;
}

.item-image-horizontal {
  width: 100%;
  height: 100%;
  object-fit: cover;
  display: block;
}

@media (min-width: 768px) {
  .topup-packages-grid {
    grid-template-columns: repeat(3, 1fr);
  }

  .topup-paymethods {
    grid-template-columns: repeat(2, 1fr);
  }

  .skyblock-grid {
    grid-template-columns: repeat(2, 1fr);
  }
}

@media (min-width: 1024px) {
  .skyblock-grid {
    grid-template-columns: repeat(3, 1fr);
  }
}

/* ===== BOTTOM NAVIGATION ===== */
/* ===== BOTTOM NAVIGATION (User Provided Style) ===== */
/* ===== BOTTOM NAVIGATION (User Provided Style + Fixes) ===== */
.bottom-nav {
  position: fixed;
  bottom: 20px;
  left: 50%;
  transform: translateX(-50%);
  width: 92%;
  max-width: 460px;
  /* Constrain width on desktop */
  background: #eaf7f3;
  /* Mint background */
  border-radius: 32px;
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding: 12px 20px;
  box-shadow: 0 10px 30px rgba(0, 0, 0, 0.1);
  z-index: 1000;
}

.nav-item {
  text-align: center;
  font-size: 11px;
  color: #8a8a8a;
  cursor: pointer;
  flex: 1;
  text-decoration: none;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  height: 48px;
  transition: all 0.3s;
  border-radius: 20px;
}

.nav-item i {
  display: flex;
  justify-content: center;
  margin-bottom: 3px;
}

.nav-item svg {
  width: 22px;
  height: 22px;
  fill: currentColor;
  transition: transform 0.2s;
}

/* Active State - White Pill (Image 2 style) */
.nav-item.active {
  background: #fdfbfb00;
  color: #7eda3b;
  /* Mint green text */
  font-weight: 700;
  box-shadow: 0 4px 15px rgb(255 255 255 / 15%);
  flex: 1.3;
  /* Grow slightly */
  margin: 0 6px;
}

.nav-item.active svg {
  transform: translateY(-2px);
  fill: #2abb44;
}

/* Center Avatar - Fixed Class Name */
.nav-avatar {
  position: relative;
  width: 54px;
  height: 54px;
  border-radius: 50%;
  border: 4px solid #ffffff;
  margin-top: -36px;
  /* Float effect */
  background-color: #eee;
  box-shadow: 0 6px 15px rgba(0, 0, 0, 0.15);
  z-index: 1001;
  flex-shrink: 0;
  margin-left: 8px;
  margin-right: 8px;
}

.nav-avatar img {
  width: 100%;
  height: 100%;
  border-radius: 50%;
  object-fit: cover;
  display: block;
}

/* Responsive adjustments */
@media (max-width: 480px) {
  .bottom-nav {
    bottom: 12px;
    padding: 10px 12px;
  }

  .nav-avatar {
    width: 48px;
    height: 48px;
    margin-top: -30px;
  }
}

/* ===== TABLET (768px+) ===== */
@media (min-width: 768px) {
  .header {
    padding: 16px;
  }

  .logo img {
    height: 40px;
  }

  .btn-login {
    padding: 10px 24px;
    font-size: 14px;
  }

  .hero img {
    height: 160px;
  }

  .content-wrap {
    padding: 16px 16px 100px;
    gap: 12px;
  }

  .left-rail {
    width: 76px;
  }

  .pill {
    width: 56px;
    height: 56px;
  }

  .pill-label {
    font-size: 11px;
  }

  .product-grid {
    grid-template-columns: repeat(2, 1fr);
    gap: 14px;
  }

  .tab-btn {
    font-size: 14px;
    padding: 9px 22px;
  }

  .bottom-bar {
    left: 50%;
    transform: translateX(-50%);
    width: min(720px, 96%);
    bottom: 12px;
    border-radius: 24px;
    padding: 12px 16px 16px;
    grid-template-columns: 1fr 1fr 64px 1fr 1fr;
  }

  .nav-item {
    font-size: 11px;
  }

  .fab {
    width: 60px;
    height: 60px;
  }
}

/* ===== DESKTOP (1024px+) ===== */
@media (min-width: 1024px) {
  .logo img {
    height: 44px;
  }

  .btn-login {
    padding: 12px 28px;
    font-size: 15px;
  }

  .hero img {
    height: 200px;
  }

  .content-wrap {
    padding: 20px 20px 100px;
    gap: 16px;
  }

  .left-rail {
    width: 84px;
  }

  .pill {
    width: 64px;
    height: 64px;
  }

  .pill-label {
    font-size: 12px;
  }

  .main-area {
    min-height: 600px;
    padding: 20px;
  }

  .product-grid {
    grid-template-columns: repeat(3, 1fr);
    gap: 16px;
  }

  .product-info {
    padding: 12px;
  }

  .product-tag {
    font-size: 11px;
  }

  .product-desc {
    font-size: 12px;
  }

  .bottom-bar {
    width: min(800px, 92%);
    padding: 12px 16px 16px;
    grid-template-columns: 1fr 1fr 72px 1fr 1fr;
  }

  .nav-item {
    font-size: 12px;
  }

  .nav-item svg {
    width: 26px;
    height: 26px;
  }

  .fab {
    width: 64px;
    height: 64px;
  }
}

/* ===== LARGE DESKTOP (1440px+) ===== */
@media (min-width: 1440px) {
  .logo img {
    height: 48px;
  }

  .hero img {
    height: 240px;
  }

  .left-rail {
    width: 92px;
  }

  .pill {
    width: 72px;
    height: 72px;
  }

  .pill-label {
    font-size: 13px;
  }

  .product-grid {
    grid-template-columns: repeat(4, 1fr);
    gap: 18px;
  }
}

/* =========================================
   SKY BLOCK REDESIGN (REFRESHED)
   ========================================= */

/* --- Banner Header --- */
.skyblock-coin-banner {
  /* Background Image with Dark Overlay */
  background: linear-gradient(rgba(0, 0, 0, 0.7), rgba(0, 0, 0, 0.7)), url('https://img.freepik.com/free-vector/pixel-art-sky-background-with-clouds-cloudscape_107791-17707.jpg');
  background-size: cover;
  background-position: center;
  color: white;
  border-radius: 12px;
  width: 100%;
  max-width: 1200px;
  margin: 0 auto;
  aspect-ratio: 16 / 6;
  padding: 24px;
  display: flex;
  justify-content: flex-end;
  align-items: flex-end;
  gap: 20px;
  margin-bottom: 24px;
  box-shadow:
    0 12px 28px rgba(0, 0, 0, 0.22),
    0 0 0 1px rgba(255, 255, 255, 0.06) inset;
  position: relative;
  overflow: hidden;
}

.skyblock-coin-banner::before {
  content: '';
  position: absolute;
  inset: 0;
  border-radius: 12px;
  padding: 2px;
  background: conic-gradient(
    from 0deg,
    rgba(255, 214, 10, 0.95),
    rgba(0, 214, 255, 0.75),
    rgba(167, 139, 250, 0.85),
    rgba(255, 214, 10, 0.95)
  );
  -webkit-mask:
    linear-gradient(#000 0 0) content-box,
    linear-gradient(#000 0 0);
  mask:
    linear-gradient(#000 0 0) content-box,
    linear-gradient(#000 0 0);
  -webkit-mask-composite: xor;
  mask-composite: exclude;
  opacity: 0.85;
  animation: sb_banner_border_spin 6s linear infinite;
  pointer-events: none;
  z-index: 0;
}

.skyblock-coin-banner::after {
  content: '';
  position: absolute;
  inset: -40% -60%;
  background: radial-gradient(circle at 30% 30%, rgba(255, 214, 10, 0.20), transparent 55%),
              radial-gradient(circle at 70% 60%, rgba(0, 214, 255, 0.18), transparent 60%),
              radial-gradient(circle at 50% 80%, rgba(167, 139, 250, 0.16), transparent 55%);
  filter: blur(18px);
  transform: translateX(-10%);
  animation: sb_banner_aurora 7.5s ease-in-out infinite;
  pointer-events: none;
  z-index: 0;
}

.skyblock-coin-banner > * {
  position: relative;
  z-index: 1;
}

@keyframes sb_banner_border_spin {
  0% { transform: rotate(0deg); }
  100% { transform: rotate(360deg); }
}

@keyframes sb_banner_aurora {
  0% { transform: translateX(-12%) translateY(-6%) scale(1); opacity: 0.55; }
  50% { transform: translateX(6%) translateY(2%) scale(1.02); opacity: 0.75; }
  100% { transform: translateX(-12%) translateY(-6%) scale(1); opacity: 0.55; }
}

/* On mobile, stack them */
@media (max-width: 768px) {
  .skyblock-coin-banner {
    flex-direction: column;
    text-align: center;
  }

  .coin-banner-btn {
    width: 100%;
  }
}

/* Button "Giao Dịch Ngay" - Big Dark Button per request */
.coin-banner-btn {
  background-color: #616161;
  color: white;
  border: 2px solid rgba(255, 255, 255, 0.1);
  padding: 14px 32px;
  border-radius: 12px;
  font-size: 16px;
  font-weight: 800;
  cursor: pointer;
  transition: all 0.2s;
  flex-shrink: 0;
  box-shadow: 0 4px 10px rgba(0, 0, 0, 0.2);
  display: inline-flex;
  align-items: center;
  justify-content: center;
}

.coin-banner-btn:hover {
  background-color: #757575;
  transform: translateY(-2px);
  box-shadow: 0 8px 16px rgba(0, 0, 0, 0.3);
  border-color: rgba(255, 255, 255, 0.3);
}

.coin-banner-btn span {
  text-transform: uppercase;
  letter-spacing: 0.5px;
}

/* --- Item Cards Horizontal (List View style) --- */
.skyblock-item-horizontal {
  display: flex;
  background: white;
  border: 1px solid #e5e7eb;
  border-radius: 16px;
  padding: 12px;
  gap: 12px;
  align-items: stretch;
  width: 100%;
  max-width: 100%;
  box-sizing: border-box;
  box-shadow: 0 4px 12px rgba(86, 193, 99, 0.448);
  transition: transform 0.2s, box-shadow 0.2s;
  position: relative;
  /* CRITICAL: Allow Overlay to Pop Out */
  overflow: visible !important;
  z-index: 1;
}

/* Hover OR Active: Lift card and bring to front */
.skyblock-item-horizontal:hover,
.skyblock-item-horizontal.active {
  transform: translateY(-2px);
  box-shadow: 0 10px 25px rgba(0, 0, 0, 0.1);
  border-color: #d1d5db;
  z-index: 999;
  /* Highest priority when active */
}

.item-image-section {
  flex-shrink: 0;
  position: relative;
  /* Ensure no clipping here either */
  overflow: visible !important;
  z-index: 10;
}

/* Main Image Wrapper: Relative container */
.item-image-wrapper-horizontal {
  width: 100px;
  aspect-ratio: 1 / 1;
  height: auto;
  position: relative;
  overflow: visible !important;
  /* Never clip the overlay */
  z-index: 10;
}

/* Inner Wrapper for Base Image: Clipped & Rounded */
.layer-base-wrapper {
  width: 100%;
  height: 100%;
  border-radius: 12px;
  overflow: hidden;
  /* Only clip the base image */
  position: relative;
  z-index: 1;
  border: 1px solid #f3f4f6;
  background: #f3f4f6;
}

.layer-base {
  width: 100%;
  height: 100%;
  object-fit: cover;
  transition: transform 0.5s;
}

/* Ensure our newer markup (layer-1 img) behaves like .layer-base */
.item-image-wrapper-horizontal .layer-1 {
  width: 100%;
  height: 100%;
  object-fit: cover;
  transition: transform 0.5s;
}

/* Base Image Zoom on hover/active */
.skyblock-item-horizontal:hover .layer-base {
  transform: scale(1.05);
}

.skyblock-item-horizontal:hover .item-image-wrapper-horizontal .layer-1 {
  transform: scale(1.05);
}

/* Base Image Darken when Active (Focus Effect) */
.skyblock-item-horizontal.active .layer-base {
  transform: scale(1.05);
  /* Tăng độ mờ nền một chút để ảnh lớp 2 không bị nhiễu bởi chi tiết nền */
  filter: brightness(0.25) blur(2.5px);
  transition: all 0.5s ease;
}

/* Overlay Character: Hiệu ứng trượt lên và làm mờ biên sâu */
.layer-overlay {
  position: absolute;
  bottom: 0;
  left: 0;
  width: 100%;
  height: 100%;
  object-fit: contain;

  /* Bắt đầu thấp để trượt lên */
  opacity: 0;
  transform: translateY(20%);

  z-index: 1000;
  transition: all 0.5s cubic-bezier(0.22, 1, 0.36, 1);
  /* Trượt mượt hơn */
  pointer-events: none;

  /* Đổi bóng đổ thành dạng phát sáng nhẹ (Glow) để nhân vật nổi bật */
  filter: drop-shadow(0 0 15px rgba(255, 255, 255, 0.2));

  /* --- LÀM MỜ RÌA CỰC MẠNH --- */
  /* Chỉnh black về 30% và transparent về 75% để triệt tiêu mép cạnh */
  -webkit-mask-image: radial-gradient(circle at center,
      black 25%,
      rgba(0, 0, 0, 0.5) 55%,
      transparent 75%);
  mask-image: radial-gradient(circle at center,
      black 25%,
      rgba(0, 0, 0, 0.5) 55%,
      transparent 75%);
}

/* Trạng thái Active khi Click */
.skyblock-item-horizontal.active .layer-overlay {
  opacity: 1;
  /* Trượt lên cao đúng 1/2 (50%) */
  transform: translateY(-50%);
}

/* ACTIVE STATE ONLY: Slide Up Effect (No Hover) */
.skyblock-item-horizontal.active .layer-overlay {
  opacity: 1;
  /* Slide up 50% of height */
  transform: translateY(-50%) scale(1.1);
  /* Slight scale up for emphasis */
}

/* Hot Badge Adjustment */
.item-image-wrapper-horizontal .item-badge {
  z-index: 20;
  /* Ensure badge stays on top */
}

.quick-view-btn-horizontal {
  z-index: 30;
  /* Ensure button stays on top */
}

.item-content-section {
  flex: 1;
  display: flex;
  flex-direction: column;
  justify-content: space-between;
  padding: 0;
  min-width: 0;
}

.item-header-horizontal {
  display: flex;
  flex-direction: column;
  /* Fixed */
  gap: 4px;
}

.item-name-horizontal {
  font-size: 20px;
  font-weight: 800;
  color: #111827;
  margin: 0;
  line-height: 1.2;
  display: -webkit-box;
  -webkit-line-clamp: 2;
  line-clamp: 2;
  -webkit-box-orient: vertical;
  overflow: hidden;
}

/* Targeted Orange Rarity Text */
.item-rarity-text {
  font-size: 14px;
  font-weight: 700;
  color: #f97316 !important;
  /* Force Orange override */
  font-style: italic;
  display: inline-flex;
  align-items: center;
  gap: 6px;
}

.item-rarity-text::before {
  content: '';
  display: inline-block;
  width: 8px;
  height: 8px;
  background: currentColor;
  border-radius: 50%;
}

.item-price-section {
  display: flex;
  align-items: center;
  justify-content: flex-start;
  gap: 10px;
  margin-top: 10px;
  background: #fdfdfd;
}

 .item-price-section .item-price-horizontal {
  flex: 1 1 auto;
  min-width: 0;
 }

 .item-price-section .btn-buy-horizontal {
  flex: 0 0 auto;
  margin-left: auto;
 }

.item-price-horizontal {
  font-size: 22px;
  font-weight: 900;
  color: #f97316;
  /* Orange */
  letter-spacing: -0.8px;
}

/* "Mua Ngay" Gradient Arrow Button */
.btn-buy-horizontal {
  background: linear-gradient(90deg, #6bfdb5 0%, #0ea5e9 100%);
  /* Fresh Mint to Sky Blue */
  color: white;
  font-family: ui-sans-serif, system-ui, sans-serif;
  font-weight: 800;
  font-style: normal;
  font-size: 15px;
  text-transform: uppercase;
  border: none;
  cursor: pointer;

  padding: 10px 22px 10px 18px;
  clip-path: polygon(0 0, 86% 0, 100% 50%, 86% 100%, 0 100%);
  width: clamp(104px, 22vw, 140px);
  min-width: 0;
  text-align: center;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  white-space: nowrap;
  line-height: 1;
  border-radius: 0;
  text-shadow: 0 1px 2px rgba(0, 0, 0, 0.15);
  transition: all 0.2s;
}

.btn-buy-horizontal:hover {
  filter: brightness(1.1);
}

.skyblock-grid {
  grid-template-columns: 1fr !important;
}

@media (min-width: 1024px) {
  .skyblock-grid {
    grid-template-columns: repeat(auto-fit, minmax(340px, 1fr)) !important;
    align-items: start;
  }
}

@media (min-width: 1024px) {
  .skyblock-item-horizontal {
    padding: 12px;
    gap: 14px;
    border-radius: 14px;
  }

  .item-image-wrapper-horizontal {
    width: 92px;
    aspect-ratio: 1 / 1;
    height: auto;
  }

  .item-name-horizontal {
    font-size: 16px;
    -webkit-line-clamp: 2;
    line-clamp: 2;
  }

  .item-price-horizontal {
    font-size: 18px;
  }

  .btn-buy-horizontal {
    font-size: 13px;
    padding: 9px 20px 9px 16px;
    width: 160px;
    min-width: 160px;
  }
}

@media (max-width: 420px) {
  .item-image-wrapper-horizontal {
    width: 86px;
  }

  .btn-buy-horizontal {
    font-size: 12px;
    padding: 9px 18px 9px 14px;
    min-width: 124px;
  }
}

/* --- FILTER RELAYOUT & UPGRADE --- */

/* 1. Layout Spacing */
.skyblock-header {
  margin-bottom: 20px;
  /* Increased from default */
}

.category-filter {
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
  margin-bottom: 24px;
  /* Increased spacing */
}

/* 2. Upgrade Search & Sort Inputs */
.skyblock-search,
.skyblock-sort,
.price-input {
  border: 1px solid #e5e7eb;
  border-radius: 12px;
  padding: 12px 16px;
  /* More padding */
  font-size: 14px;
  transition: all 0.2s ease;
  outline: none;
  background: white;
}

/* Search Icon Positioning correction */
.skyblock-search {
  padding-left: 44px;
  /* Space for icon */
}

.search-icon {
  left: 14px;
  /* Adjust icon position */
  color: #9ca3af;
}

/* Focus State matched with Turquoise theme */
.skyblock-search:focus,
.skyblock-sort:focus,
.price-input:focus {
  border-color: #0ea5e9;
  /* Sky Blue */
  box-shadow: 0 0 0 4px rgba(14, 165, 233, 0.15);
  /* Soft glow */
}

/* 3. Upgrade Tags (Categories) */
.category-btn {
  background-color: #f3f4f6;
  /* Light Gray */
  border: 1px solid transparent;
  color: #4b5563;
  padding: 8px 20px;
  border-radius: 20px;
  /* Pill shape */
  font-size: 13px;
  font-weight: 600;
  cursor: pointer;
  transition: all 0.2s;
}

.category-btn:hover {
  background-color: #e0f2fe;
  /* Light Blue tint */
  color: #0ea5e9;
  transform: translateY(-1px);
}

.category-btn.active {
  background: linear-gradient(90deg, #6bfdb5 0%, #0ea5e9 100%);
  /* Match "Mua Ngay" */
  color: white;
  border-color: transparent;
  box-shadow: 0 4px 12px rgba(14, 165, 233, 0.3);
}

/* 4. Upgrade Price Filter Section */
.price-filter {
  display: flex;
  flex-direction: column;
  gap: 10px;
  margin-bottom: 24px;
  background: white;
  padding: 16px;
  border-radius: 16px;
  border: 1px solid #f3f4f6;
  box-shadow: 0 2px 8px rgba(0, 0, 0, 0.03);
}

.price-filter label {
  font-weight: 700;
  color: #374151;
  font-size: 14px;
}

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

.price-input {
  width: 120px;
  text-align: center;
}

/* 5. Upgrade "Áp dụng" Button */
.price-filter-btn {
  background: linear-gradient(90deg, #6bfdb5 0%, #0ea5e9 100%);
  /* Match "Mua Ngay" */
  color: white;
  border: none;
  border-radius: 12px;
  padding: 10px 24px;
  font-weight: 700;
  cursor: pointer;
  transition: all 0.2s;
  box-shadow: 0 4px 12px rgba(14, 165, 233, 0.25);
  margin-left: auto;
  /* Push to right if needed, or keep inline */
}

.price-filter-btn:hover {
  filter: brightness(1.1);
  transform: translateY(-1px);
  box-shadow: 0 6px 16px rgba(14, 165, 233, 0.35);
}

/* ===== SKY BLOCK CONTROLS ===== */
.skyblock-controls {
  display: flex;
  gap: 16px;
  flex-wrap: wrap;
  margin-bottom: 24px;
  align-items: center;
}

 .main-area .skyblock-controls {
  margin-left: -4px;
 }

.search-box {
  position: relative;
  flex: 1;
  min-width: 200px;
}

.search-box input {
  width: 100%;
  padding: 10px 12px 10px 40px;
  border: 2px solid #e0f2fe;
  border-radius: 12px;
  font-size: 14px;
  color: #334155;
  background: #f0f9ff;
  transition: all 0.2s;
  outline: none;
}

.search-box input:focus {
  background: white;
  border-color: #38bdf8;
  box-shadow: 0 4px 12px rgba(56, 189, 248, 0.15);
}

.search-box svg {
  position: absolute;
  left: 12px;
  top: 50%;
  transform: translateY(-50%);
  color: #94a3b8;
  pointer-events: none;
}

.filter-group {
  display: flex;
  gap: 10px;
}

.sort-select {
  padding: 10px 36px 10px 16px;
  border-radius: 12px;
  border: 1px solid #e2e8f0;
  background-color: white;
  color: #334155;
  font-size: 14px;
  font-weight: 500;
  cursor: pointer;
  appearance: none;
  background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' fill='none' viewBox='0 0 24 24' stroke='%2364748b'%3E%3Cpath stroke-linecap='round' stroke-linejoin='round' stroke-width='2' d='M19 9l-7 7-7-7'%3E%3C/path%3E%3C/svg%3E");
  background-repeat: no-repeat;
  background-position: right 12px center;
  background-size: 16px;
  transition: all 0.2s;
}

.sort-select:hover {
  border-color: #cbd5e1;
  background-color: #f8fafc;
}

.sort-select:focus {
  border-color: #38bdf8;
  outline: none;
  box-shadow: 0 0 0 3px rgba(56, 189, 248, 0.1);
}

.price-filter-popup-trigger {
  position: relative;
}

.price-filter-dropdown {
  position: absolute;
  top: calc(100% + 8px);
  right: 0;
  width: 280px;
  background: white;
  border-radius: 16px;
  padding: 16px;
  box-shadow: 0 10px 40px -10px rgba(0, 0, 0, 0.15);
  border: 1px solid #f1f5f9;
  z-index: 50;
  display: none;
  /* Hidden by default, toggled via hover or click */
}

/* Show dropdown on hover (simple version) or toggle via JS */
.price-filter-popup-trigger:hover .price-filter-dropdown,
.price-filter-dropdown:hover {
  display: block;
}

.price-input-group {
  display: flex;
  align-items: center;
  gap: 8px;
  margin-bottom: 12px;
}

.price-input-group input {
  flex: 1;
  width: 100%;
  padding: 8px;
  border: 1px solid #e2e8f0;
  border-radius: 8px;
  font-size: 13px;
}

.price-input-group span {
  color: #94a3b8;
  font-weight: 500;
}

/* Category Buttons */
.skyblock-categories {
  display: flex;
  gap: 10px;
  overflow-x: auto;
  padding-bottom: 4px;
  scrollbar-width: none;
  /* Firefox */
}

 .main-area .skyblock-categories {
  margin-left: -4px;
 }

.skyblock-categories::-webkit-scrollbar {
  display: none;
  /* Chrome/Safari */
}

.category-btn {
  white-space: nowrap;
  padding: 8px 16px;
  border-radius: 20px;
  border: 1px solid #e2e8f0;
  background: white;
  color: #64748b;
  font-size: 13px;
  font-weight: 600;
  cursor: pointer;
  transition: all 0.2s;
}

.category-btn:hover {
  background: #f8fafc;
  color: #334155;
}

/* ==========================================================================
   RESTORED CSS FROM tabs-account.css
   ========================================================================== */

/* TABS STYLES */
.tabs {
  display: flex;
  justify-content: center;
  gap: 15px;
  margin-bottom: 25px;
  flex-wrap: wrap;
  padding: 10px;
}

.tab-btn[data-tab-name="Mới nhất"] {
  --tab-color: #06b6d4;
  --tab-bg-custom: var(--tab-bg-mới-nhất);
}

.tab-btn[data-tab-name="Account"] {
  --tab-color: #f97316;
  --tab-bg-custom: var(--tab-bg-account);
}

.tab-btn[data-tab-name="Thuê Acc"] {
  --tab-color: #d946ef;
  --tab-bg-custom: var(--tab-bg-thuê-acc);
}

.tab-btn[data-tab-name="Nạp Game"] {
  --tab-color: #3b82f6;
  --tab-bg-custom: var(--tab-bg-nạp-game);
}

.tab-btn[data-tab-name="Bán Lại"] {
  --tab-color: #10b981;
  --tab-bg-custom: var(--tab-bg-bán-lại);
}

.tab-btn[data-tab-name="Treo Bán"] {
  --tab-color: #8b5cf6;
}

.tab-btn[data-tab-name="Item"] {
  --tab-color: #f43f5e;
}

.tab-btn[data-tab-name="Robux"] {
  --tab-color: #0ea5e9;
}

.tab-btn[data-tab-name="Random"] {
  --tab-color: #eab308;
}

.tab-btn {
  --tab-color: #64748b;
  position: relative;
  padding: 10px 20px;
  border-radius: 12px;
  background: rgba(255, 255, 255, 0.1);
  backdrop-filter: blur(10px);
  -webkit-backdrop-filter: blur(10px);
  border: 1px solid rgba(255, 255, 255, 0.2);
  font-weight: 700;
  color: #ffffff;
  text-shadow: -1px -1px 0 #000, 1px -1px 0 #000, -1px 1px 0 #000, 1px 1px 0 #000;
  cursor: pointer;
  transition: all 0.3s ease;
  font-size: 14px;
  min-width: 120px;
  display: flex;
  align-items: center;
  justify-content: center;
  overflow: hidden;
  z-index: 10;
}

.tab-btn::before {
  content: '';
  position: absolute;
  inset: 0;
  z-index: -1;
  background-image: var(--tab-bg-custom);
  background-position: center;
  background-size: cover;
  background-repeat: no-repeat;
  opacity: 0.8;
  transition: all 0.3s ease;
  border-radius: 12px;
}

.tab-btn:hover {
  background: rgba(255, 255, 255, 0.2);
  transform: translateY(-2px);
}

.tab-btn.active {
  background: rgba(255, 255, 255, 0.4);
  color: var(--tab-color);
  border-color: var(--tab-color);
  box-shadow: 0 0 15px var(--tab-color);
  text-shadow: none;
}

.tab-btn.active::before {
  opacity: 1;
}

/* Light Sweep Animation with Click Safety */
.tab-btn.active::after {
  content: '';
  position: absolute;
  top: 0;
  left: -100%;
  width: 50%;
  height: 100%;
  background: linear-gradient(to right, rgba(255, 255, 255, 0) 0%, rgba(255, 255, 255, 0.8) 50%, rgba(255, 255, 255, 0) 100%);
  transform: skewX(-25deg);
  z-index: 10;
  pointer-events: none !important;
  /* CRITICAL FIX */
  animation: lightSweep 3s infinite ease-in-out;
}

@keyframes lightSweep {
  0% {
    left: -100%;
    opacity: 0;
  }

  5% {
    opacity: 1;
  }

  40% {
    left: 200%;
    opacity: 0;
  }

  100% {
    left: 200%;
    opacity: 0;
  }
}

/* PRODUCT GRID STYLES */
.product-grid {
  display: grid !important;
  grid-template-columns: repeat(4, 1fr) !important;
  gap: 20px !important;
  padding: 16px;
  width: 100% !important;
}

@media (max-width: 1200px) {
  .product-grid {
    grid-template-columns: repeat(3, 1fr) !important;
  }
}

@media (max-width: 768px) {
  .product-grid {
    grid-template-columns: repeat(2, 1fr) !important;
  }
}

@media (max-width: 480px) {
  .product-grid {
    grid-template-columns: 1fr !important;
  }
}

.product-card {
  border: 1px solid rgba(0, 0, 0, 0.1);
  border-radius: 16px;
  overflow: hidden;
  background: rgba(255, 255, 255, 0.85);
  backdrop-filter: blur(10px);
  -webkit-backdrop-filter: blur(10px);
  transition: all 0.3s ease;
  display: flex;
  flex-direction: column;
  position: relative;
  box-shadow: 0 2px 5px rgba(0, 0, 0, 0.05);
  max-width: 100%;
  width: auto !important;
  height: 330px;
  /* Forced Grid Fix */
  margin: 0 !important;
}

@media (max-width: 768px) {
  .product-card {
    height: 310px;
  }
}

@media (max-width: 480px) {
  .product-card {
    height: 300px;
  }
}

.rental-card {
  height: 330px;
}

@media (max-width: 768px) {
  .rental-card {
    height: 310px;
  }
}

@media (max-width: 480px) {
  .rental-card {
    height: 300px;
  }
}

.product-card:hover {
  transform: translateY(-4px);
  box-shadow: 0 10px 15px -3px rgba(0, 0, 0, 0.1), 0 4px 6px -2px rgba(0, 0, 0, 0.05);
  border-color: #cbd5e1;
}

.product-image-wrapper {
  position: relative;
  width: 100%;
  aspect-ratio: 16/9;
  overflow: hidden;
  background: #f1f5f9;
}

.product-image {
  position: absolute;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  display: block;
  z-index: 1;
}

.product-image img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  transition: transform 0.5s ease;
}

.product-card:hover .product-image img {
  transform: scale(1.05);
}

.product-info {
  padding: 14px;
  display: flex;
  flex-direction: column;
  flex: 1;
  gap: 6px;
}

.product-meta-row {
  display: flex;
  align-items: center;
  gap: 8px;
  font-size: 11px;
  color: #5d2400;
  font-weight: 600;
}

.product-tag {
  background: rgb(227 210 238 / 25%);
  padding: 3px 8px;
  border-radius: 6px;
  color: #6d008a;
  border: 1px solid rgba(226, 232, 240, 0.8);
}

.product-price-row {
  display: flex;
  align-items: baseline;
  gap: 4px;
  margin-bottom: 8px;
  min-height: auto;
}

.product-price-current {
  font-size: 1.3rem;
  font-weight: 800;
  color: #fe3e2b;
  line-height: 1;
}

.product-price-sold {
  font-size: 16px;
  font-weight: 700;
  color: #94a3b8;
  text-transform: uppercase;
}

.product-title {
  font-size: 15px;
  font-weight: 700;
  color: #1e293b;
  line-height: 1.4;
  display: -webkit-box;
  -webkit-line-clamp: 2;
  -webkit-box-orient: vertical;
  overflow: hidden;
  min-height: auto;
  margin-bottom: 12px;
}

.btn-card-action {
  display: block;
  width: 100%;
  text-align: center;
  padding: 10px 0;
  border: none;
  background: linear-gradient(135deg, #ffb74d 0%, #ff9800 100%);
  color: #ffffff;
  font-weight: 700;
  text-transform: uppercase;
  font-size: 12px;
  border-radius: 12px;
  text-decoration: none;
  transition: all 0.2s;
  margin-top: auto;
  box-shadow: 0 4px 10px rgba(255, 152, 0, 0.25);
}

.btn-card-action:hover {
  background: linear-gradient(135deg, #ffcc80 0%, #fb8c00 100%);
  color: #ffffff;
  transform: translateY(-1px);
  box-shadow: 0 10px 18px rgba(0, 0, 0, 0.18);
}

/* RENTAL STYLES */
.rental-grid-custom {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(220px, 1fr));
  gap: 16px;
  padding: 16px;
}

@media (max-width: 768px) {
  .rental-grid-custom {
    grid-template-columns: repeat(2, 1fr);
    gap: 12px;
    padding: 10px;
  }
}

.rental-card {
  background: rgba(255, 255, 255, 0.85);
  backdrop-filter: blur(10px);
  -webkit-backdrop-filter: blur(10px);
  border-radius: 16px;
  overflow: hidden;
  position: relative;
  transition: all 0.3s ease;
  border: 1px solid rgba(255, 255, 255, 0.6);
  box-shadow: 0 4px 20px rgba(100, 116, 139, 0.1);
  display: flex;
  flex-direction: column;
}

.rental-card:hover {
  transform: translateY(-5px);
  box-shadow: 0 12px 28px rgba(236, 72, 153, 0.2), 0 0 15px rgba(236, 72, 153, 0.3);
  background: rgba(255, 255, 255, 0.95);
  border-color: rgba(236, 72, 153, 0.3);
}

.rental-image-wrapper {
  position: relative;
  width: 100%;
  aspect-ratio: 16/9;
  border-top-left-radius: 16px;
  border-top-right-radius: 16px;
  overflow: hidden;
}

.rental-image-wrapper img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  transition: transform 0.5s ease;
}

.rental-card:hover .rental-image-wrapper img {
  transform: scale(1.05);
}

.rental-badge-pill {
  position: absolute;
  top: 10px;
  left: 10px;
  padding: 5px 10px;
  border-radius: 20px;
  font-size: 10px;
  font-weight: 800;
  text-transform: uppercase;
  display: flex;
  align-items: center;
  gap: 4px;
  z-index: 10;
  backdrop-filter: blur(8px);
  box-shadow: 0 2px 8px rgba(0, 0, 0, 0.15);
}

.rental-badge-pill.available {
  background: rgb(173 246 176 / 95%);
  color: #166534;
  border: 1px solid #22c55e;
}

.rental-badge-pill.renting {
  background: rgb(241 161 161 / 95%);
  color: #991b1b;
  border: 1px solid #ef4444;
}

.rental-info {
  padding: 14px;
  flex: 1;
  display: flex;
  flex-direction: column;
  background: transparent;
}

.rental-tags {
  display: flex;
  flex-wrap: wrap;
  gap: 6px;
  margin-bottom: 8px;
}

.rental-tag {
  background: rgb(157 1 196 / 9%);
  color: #45008f;
  padding: 3px 8px;
  border-radius: 6px;
  font-size: 11px;
  font-weight: 600;
  border: 1px solid rgba(226, 232, 240, 0.8);
}

.rental-price-row {
  display: flex;
  align-items: baseline;
  gap: 4px;
  margin-bottom: 8px;
}

.rental-price-value {
  font-size: 1.3rem;
  font-weight: 800;
  color: #f59e0b;
  margin: 0;
  line-height: 1;
}

.rental-price-unit {
  font-size: 0.85rem;
  color: #64748b;
  font-weight: 600;
}

.rental-title {
  font-size: 15px;
  font-weight: 700;
  color: #1e293b;
  margin-bottom: 12px;
  line-height: 1.4;
  display: -webkit-box;
  -webkit-line-clamp: 2;
  -webkit-box-orient: vertical;
  overflow: hidden;
}

.btn-rental {
  width: 100%;
  padding: 10px 0;
  border-radius: 12px;
  font-size: 12px;
  font-weight: 700;
  text-transform: uppercase;
  border: none;
  cursor: pointer;
  transition: all 0.3s ease;
  margin-top: auto;
  box-shadow: 0 4px 6px rgba(0, 0, 0, 0.05);
}

.btn-rental.available {
  background: linear-gradient(135deg, #38bdf8 0%, #3b82f6 100%);
  color: white;
}

.btn-rental.renting {
  background: #e2e8f0;
  color: #94a3b8;
  cursor: not-allowed;
  border: 1px solid #cbd5e1;
  box-shadow: none;
}

/* MODAL */
.rental-detail-overlay {
  position: fixed;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  background: rgba(0, 0, 0, 0.8);
  z-index: 10000;
  display: flex;
  align-items: center;
  justify-content: center;
  backdrop-filter: blur(5px);
}

.rental-detail-content {
  background: white;
  width: 900px;
  max-width: 95%;
  max-height: 90vh;
  border-radius: 16px;
  overflow: hidden;
  display: flex;
  flex-direction: row;
  position: relative;
  box-shadow: 0 25px 50px -12px rgba(0, 0, 0, 0.25);
}

.rental-modal-close {
  position: absolute;
  top: 15px;
  right: 15px;
  background: rgba(0, 0, 0, 0.5);
  color: white;
  border: none;
  width: 40px;
  height: 40px;
  border-radius: 50%;
  cursor: pointer;
  z-index: 20;
  font-size: 24px;
  display: flex;
  align-items: center;
  justify-content: center;
}

.rental-modal-left {
  flex: 1.5;
  background: #0f172a;
  position: relative;
  display: flex;
  align-items: center;
  justify-content: center;
  min-height: 400px;
}

.rental-modal-right {
  flex: 1;
  padding: 24px;
  display: flex;
  flex-direction: column;
  overflow-y: auto;
  background: white;
}

.rental-modal-title {
  font-size: 24px;
  color: #1e293b;
  font-weight: 800;
  margin-bottom: 16px;
}

.rental-modal-price-value {
  font-size: 28px;
  font-weight: 800;
  color: #059669;
}

.rent-input-group {
  display: flex;
  gap: 10px;
  margin-bottom: 16px;
}

.rent-input-btn {
  width: 44px;
  height: 44px;
  font-size: 20px;
  border: 1px solid #cbd5e1;
  border-radius: 8px;
  background: white;
  cursor: pointer;
}

.rent-days-input {
  flex: 1;
  text-align: center;
  font-size: 18px;
  font-weight: 600;
  border: 1px solid #cbd5e1;
  border-radius: 8px;
  height: 44px;
}

.btn-rent-confirm {
  width: 100%;
  padding: 16px;
  background: linear-gradient(135deg, #4f46e5 0%, #7c3aed 100%);
  color: white;
  border: none;
  border-radius: 12px;
  font-weight: 700;
  cursor: pointer;
}

@media (max-width: 768px) {
  .rental-detail-content {
    flex-direction: column;
    width: 90%;
  }

  .rental-modal-left {
    height: 250px;
    flex: none;
  }

  .rental-modal-right {
    flex: 1;
    padding: 16px;
  }
}

.category-btn.active {
  background: #0ea5e9;
  color: white;
  border-color: #0ea5e9;
  box-shadow: 0 4px 12px rgba(14, 165, 233, 0.2);
}

/* =========================================
   SKYBLOCK COIN EXCHANGE MODAL (UI POLISH)
   ========================================= */

.coin-exchange-wrapper {
  font-family: ui-sans-serif, system-ui, -apple-system, Segoe UI, Roboto, sans-serif;
  color: #0f172a;
}

/* Tighten modal container spacing a bit */
#coin-exchange-modal > div {
  max-width: 760px !important;
}

#coin-exchange-body {
  padding: 14px !important;
}

.coin-exchange-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  padding: 6px 2px 14px;
  border-bottom: 1px solid #e2e8f0;
  margin-bottom: 14px;
}

.coin-exchange-header h2 {
  margin: 0;
  font-size: 18px;
  font-weight: 800;
  letter-spacing: -0.2px;
}

.admin-status-indicator {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  background: #f8fafc;
  border: 1px solid #e2e8f0;
  padding: 8px 12px;
  border-radius: 999px;
  font-size: 12px;
  font-weight: 700;
  color: #334155;
}

.admin-status-indicator .status-dot {
  width: 10px;
  height: 10px;
  border-radius: 999px;
  background: #22c55e;
  box-shadow: 0 0 0 4px rgba(34, 197, 94, 0.15);
}

.form-section h3 {
  margin: 14px 0 12px;
  font-size: 14px;
  font-weight: 800;
  color: #334155;
}

/* Grid layout for coin packages */
.coin-packages.sb-coin-grid {
  display: grid;
  grid-template-columns: repeat(5, minmax(0, 1fr));
  gap: 10px;
}

@media (max-width: 900px) {
  .coin-packages.sb-coin-grid {
    grid-template-columns: repeat(4, minmax(0, 1fr));
  }
}

@media (max-width: 760px) {
  .coin-packages.sb-coin-grid {
    grid-template-columns: repeat(3, minmax(0, 1fr));
  }
}

@media (max-width: 600px) {
  .coin-packages.sb-coin-grid {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }
}

/* Card styles inspired by inventory cards */
.sb-coin-card {
  background: #ffffff;
  border-radius: 14px;
  position: relative;
  overflow: hidden;
  border: 1px solid #e2e8f0;
  box-shadow: 0 6px 18px rgba(15, 23, 42, 0.08);
  transition: transform 0.18s ease, box-shadow 0.18s ease, border-color 0.18s ease;
}

.sb-coin-card.is-sold-out {
  opacity: 0.7;
}

.sb-coin-card .sold-out-stamp {
  position: absolute;
  top: 50%;
  left: 50%;
  transform: translate(-50%, -50%) rotate(-30deg);
  z-index: 10;
  pointer-events: none;

  padding: 10px 18px;
  border: 3px solid #b91c1c;
  color: #b91c1c;
  background: rgba(255, 255, 255, 0.78);
  border-radius: 12px;
  font-weight: 900;
  letter-spacing: 2px;
  text-transform: uppercase;
  font-size: 22px;
  line-height: 1;
  box-shadow: 0 10px 22px rgba(185, 28, 28, 0.22);
}

.sb-coin-card:hover {
  transform: translateY(-2px);
  box-shadow: 0 14px 30px rgba(15, 23, 42, 0.14);
  border-color: #cbd5e1;
}

.sb-coin-card__img {
  position: relative;
  width: 100%;
  aspect-ratio: 2 / 1;
  background: #f1f5f9;
}

.sb-coin-card.robux-package-card .sb-coin-card__img {
  padding: 8px;
  background: #0b1220;
}

.sb-coin-card__img img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  display: block;
}

.sb-coin-card__body {
  padding: 8px;
  display: flex;
  flex-direction: column;
  gap: 6px;
}

.sb-coin-card__title {
  font-size: 15px;
  font-weight: 800;
  color:  #052143;
  line-height: 1.25;
}

.sb-coin-card__coins {
  font-size: 12px;
  font-weight: 800;
  color: #856710d6;
  background: #e1db3314;
  border: 1px solid #c6bfab;
  padding: 4px 8px;
  border-radius: 10px;
  width: fit-content;
}

.sb-coin-card__price {
  font-size: 18px;
  font-weight: 900;
  color: #534403;
}

/* ========================================================================== */
/* ROBUX TAB UI OVERRIDES */
/* ========================================================================== */

.robux-banner-wrap {
  width: 100%;
  border-radius: 12px;
  overflow: hidden;
  box-shadow: 0 4px 15px rgba(0, 0, 0, 0.3);
  margin-bottom: 25px;
  background: #73860bc2;
  animation: robuxBannerPulse 2.6s ease-in-out infinite;
}

.robux-banner-img {
  width: 100%;
  height: auto;
  display: block;
  object-fit: cover;
  aspect-ratio: 4 / 1;
}

@keyframes robuxBannerPulse {
  0% {
    transform: scale(1);
    box-shadow: 0 4px 15px rgba(0, 0, 0, 0.25);
    filter: saturate(1);
  }
  50% {
    transform: scale(1.01);
    box-shadow:  0 8px 24px rgb(215 215 98 / 67%);
    filter: saturate(1.15);
  }
  100% {
    transform: scale(1);
    box-shadow: 0 4px 15px rgba(0, 0, 0, 0.25);
    filter: saturate(1);
  }
}

/* Grid for Robux packages */
.coin-packages.sb-coin-grid.robux-packages-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(450px, 1fr));
  gap: 15px;
}

/* Horizontal card for Robux (match Skyblock Pet style: image left, content right) */
.sb-coin-card.robux-package-card {
  width: 100%;
  display: flex !important;
  flex-direction: row !important;
  align-items: stretch;
  padding: 10px;
  gap: 0;
}

/* Image on the left */
.sb-coin-card.robux-package-card .sb-coin-card__img {
  width: 96px !important;
  height: 96px !important;
  flex: 0 0 auto;
  padding: 0 !important;
  background: transparent !important;
  aspect-ratio: 1 / 1;
}

.sb-coin-card.robux-package-card .sb-coin-card__img img {
  width: 96px !important;
  height: 96px !important;
  object-fit: cover;
  border-radius: 8px;
  margin-right: 15px;
}

.sb-coin-card.robux-package-card .sb-coin-card__body {
  flex: 1;
  padding: 0 !important;
  text-align: left !important;
}

.sb-coin-card.robux-package-card .robux-package-actions {
  flex: 0 0 auto;
  display: flex;
  flex-direction: column;
  align-items: flex-end;
  justify-content: flex-end;
  margin-left: 12px;
  padding-bottom: 2px;
}

.sb-coin-card.robux-package-card .robux-package-price-right {
  font-size: 18px;
  font-weight: 900;
  color: #534403;
  line-height: 1.1;
  margin-bottom: 8px;
  white-space: nowrap;
}

.sb-coin-card.robux-package-card .robux-package-actions .robux-package-buy-btn {
  width: 140px;
  max-width: 140px;
}

@media (max-width: 420px) {
  .sb-coin-card.robux-package-card {
    flex-direction: column !important;
    align-items: stretch;
  }

  .sb-coin-card.robux-package-card .sb-coin-card__img {
    width: 100% !important;
    height: auto !important;
    aspect-ratio: 1 / 1;
  }

  .sb-coin-card.robux-package-card .sb-coin-card__img img {
    width: 100% !important;
    height: auto !important;
    aspect-ratio: 1 / 1;
    margin-right: 0;
  }

  .sb-coin-card.robux-package-card .robux-package-actions {
    margin-left: 0;
    margin-top: 10px;
  }

  .sb-coin-card.robux-package-card .robux-package-actions .robux-package-buy-btn {
    width: 100%;
    max-width: none;
  }
}

.sb-coin-card.robux-package-card .sb-coin-card__title {
  font-size: 16px;
}

.robux-package-meta {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 10px;
}

.robux-package-stock {
  margin-top: 6px;
  font-size: 12px;
  opacity: 0.8;
}

.robux-package-actions {
  margin-top: 10px;
}

/* Buy button polish */
.sb-coin-buy-btn,
.robux-package-buy-btn {
  width: 100%;
  border: none;
  border-radius: 12px;
  padding: 9px 10px;
  font-weight: 800;
  cursor: pointer;
  color: #250f34;
  background: linear-gradient(135deg, #d4d4a2 0%, #e7e4d8 60%, #48452c 100%);
  box-shadow: 0 10px 18px rgb(235 221 37 / 22%);
  transition: transform 0.15s ease, filter 0.15s ease, box-shadow 0.15s ease;
}

.sb-coin-buy-btn:hover,
.robux-package-buy-btn:hover {
  filter: brightness(1.05);
  transform: translateY(-1px);
  box-shadow: 0 16px 26px rgb(235 207 37 / 28%);
}

.sb-coin-buy-btn:active,
.robux-package-buy-btn:active {
  transform: translateY(0);
  filter: brightness(0.98);
}

.sb-coin-buy-btn:disabled,
.robux-package-buy-btn:disabled {
  background: #e2e8f0;
  color:  #171615;
  cursor: not-allowed;
  box-shadow: none;
}

@media (max-width: 768px) {
  /* 1. Fix Grid: Trên mobile chỉ hiện 1 cột, rộng 100% màn hình */
  .coin-packages.sb-coin-grid.robux-packages-grid {
    grid-template-columns: 1fr !important; /* Bỏ cái minmax 450px đi */
    gap: 10px;
  }

  /* 2. Fix Banner: Co lại theo tỉ lệ màn hình */
  .robux-banner-img {
    width: 100% !important;
    height: auto !important;
    aspect-ratio: 2/1 !important; /* Tỷ lệ 2:1 cho mobile đỡ bị dẹt */
    object-fit: cover;
  }

  /* 3. Fix Thẻ Gói Robux: Giữ layout ngang nhưng thu nhỏ ảnh */
  .sb-coin-card.robux-package-card {
    padding: 8px !important;
  }

  .sb-coin-card.robux-package-card img {
    width: 90px !important; /* Thu nhỏ ảnh gói */
    height: 90px !important;
    margin-right: 10px !important;
  }

  /* 4. Fix Con Dấu Hết Hàng: Thu nhỏ lại không che hết chữ */
  .sold-out-stamp {
    font-size: 14px !important;
    padding: 5px 10px !important;
    border-width: 2px !important;
    transform: translate(-50%, -50%) rotate(-20deg) !important; /* Xoay ít hơn tí */
  }
}

.coin-packages.sb-coin-grid.robux-packages-grid {
  grid-template-columns: repeat(auto-fit, minmax(350px, 1fr)) !important;
}

@media (max-width: 768px) {
  .coin-packages.sb-coin-grid.robux-packages-grid {
    grid-template-columns: 1fr !important;
  }
}

.sb-coin-card.robux-package-card {
  display: flex !important;
  flex-wrap: wrap !important;
  align-items: center;
  padding: 2px;
}

.sb-coin-card.robux-package-card .sb-coin-card__img,
.sb-coin-card.robux-package-card .sb-coin-card__img img {
  width: 80px !important;
  height: 80px !important;
  object-fit: cover;
}

.sb-coin-card.robux-package-card .sb-coin-card__img {
  margin-right: 10px !important;
}

.sb-coin-card.robux-package-card .sb-coin-card__body {
  flex: 1;
  text-align: left;
}

.sb-coin-card.robux-package-card .sb-coin-buy-btn {
  width: auto !important;
}

@media (max-width: 768px) {
  .sb-coin-card.robux-package-card .sb-coin-buy-btn {
    width: 100% !important;
    margin-top: 10px !important;
    order: 99;
    flex-basis: 100%;
  }
}

/* ========================================================================== */
/* SKYBLOCK ITEM: 3-LAYER OVERLAY UI (NO MODAL) */
/* ========================================================================== */

.skyblock-item-horizontal .item-image-wrapper-horizontal {
  position: relative;
  overflow: visible;
}

.skyblock-item-horizontal .item-image-wrapper-horizontal .layer-base-wrapper {
  position: relative;
  z-index: 1;
}

.skyblock-item-horizontal .item-image-wrapper-horizontal .layer-1 {
  position: relative;
  z-index: 1;
}

.skyblock-item-horizontal .item-image-wrapper-horizontal .layer-2,
.skyblock-item-horizontal .item-image-wrapper-horizontal .layer-3 {
  position: absolute;
  bottom: 0;
  left: 50%;
  transform: translateX(-50%) translateY(18px);
  height: 110%;
  width: auto;
  z-index: 10;
  pointer-events: none;
  opacity: 0;
  transition: transform 0.3s ease, opacity 0.3s ease;
}

.skyblock-item-horizontal.show-layer-2 .item-image-wrapper-horizontal .layer-2 {
  opacity: 1;
  transform: translateX(-50%) translateY(-10px);
}

.skyblock-item-horizontal.show-layer-3 .item-image-wrapper-horizontal .layer-3 {
  opacity: 1;
  transform: translateX(-50%) translateY(-10px);
}

.skyblock-item-horizontal.show-layer-2 .item-image-wrapper-horizontal .layer-1,
.skyblock-item-horizontal.show-layer-3 .item-image-wrapper-horizontal .layer-1 {
  filter: brightness(0.35) blur(1.5px);
}

.skyblock-item-horizontal .item-image-wrapper-horizontal .question-mark-btn {
  position: absolute;
  top: 8px;
  right: 8px;
  z-index: 25;
  width: 22px;
  height: 22px;
  border-radius: 999px;
  background: rgba(15, 23, 42, 0.75);
  color: #fff;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 13px;
  font-weight: 900;
  cursor: pointer;
  user-select: none;
  border: 1px solid rgba(255, 255, 255, 0.25);
}

.skyblock-item-horizontal .item-image-wrapper-horizontal .question-mark-btn:hover {
  background: rgba(15, 23, 42, 0.9);
}

/* =========================================
   MODERN UI ENHANCEMENTS & ANIMATIONS
   ========================================= */

/* 
   REMOVED: Product, Rental, and Tab styles have been moved to css/tabs-account.css 
   to eliminate conflicts and restore Grid Layout. 
*/

/* ========================================================================== */
/* SKYBLOCK MARKETPLACE: 3-LAYER OVERLAY FOR .sb-coin-card */
/* ========================================================================== */

/* 1. QUAN TRỌNG NHẤT: Cho phép phần tử con tràn ra ngoài thẻ cha */
.sb-coin-card {
  position: relative !important;
  overflow: visible !important;
  z-index: 1;
}

/* 2. Layer 1 (Ảnh nền) */
.sb-coin-card img.layer-1 {
  width: 100% !important;
  height: auto !important;
  display: block;
  border-radius: 8px;
}

/* 3. Layer 2 (Overlay) - Trạng thái ẩn */
.sb-coin-card img.layer-2 {
  position: absolute !important;
  bottom: 0 !important;
  left: 50% !important;
  transform: translateX(-50%) translateY(20px) scale(0.8);
  width: auto !important;
  max-width: 120% !important;
  height: auto !important;
  max-height: 150% !important;
  z-index: 100;
  opacity: 0;
  transition: all 0.4s cubic-bezier(0.34, 1.56, 0.64, 1);
  pointer-events: none;
}

/* 4. Layer 2 (Overlay) - Trạng thái hiện (POP-OUT) */
.sb-coin-card.show-layer-2 img.layer-2 {
  opacity: 1 !important;
  top: -40px !important;
  bottom: auto !important;
  transform: translateX(-50%) scale(1.1) !important;
}

/* 5. Layer 3 (Info) - Panel xổ sang bên phải, tỷ lệ 3:2, to ~3x */
.sb-coin-card img.layer-3 {
  position: absolute !important;
  top: 0 !important;
  left: calc(100% + 12px) !important;
  width: 300% !important;
  height: auto !important;
  aspect-ratio: 3 / 2;
  object-fit: cover;
  border-radius: 12px;
  z-index: 120;
  opacity: 0;
  transform: translateX(10px) scale(0.98);
  transition: transform 0.25s ease, opacity 0.25s ease;
  pointer-events: none;
}

.sb-coin-card.show-layer-3 img.layer-3 {
  opacity: 1 !important;
  transform: translateX(0) scale(1) !important;
}

.skyblock-item-horizontal .layer-3.text-panel {
  position: absolute !important;
  top: 0 !important;
  left: calc(100% + 12px) !important;
  width: 250px !important;
  background-color: #1a1b26 !important;
  border-radius: 8px;
  border: 1px solid #2f334d;
  padding: 12px;
  color: #fff;
  font-size: 13px;
  line-height: 1.5;
  text-align: center;
  z-index: 120 !important;
  opacity: 0;
  pointer-events: none;
  transform: translateX(10px) scale(0.98) !important;
  transition: all 0.25s ease;
  box-shadow: 0 4px 15px rgba(0,0,0,0.5);
}

.skyblock-item-horizontal.show-layer-3 .layer-3.text-panel {
  opacity: 1 !important;
  transform: translateX(0) scale(1) !important;
}

.skyblock-item-horizontal .layer-3.text-panel .text-content {
  color: #e0def4;
}

@media (max-width: 768px) {
  .sb-coin-card img.layer-3 {
    left: 50% !important;
    top: 100% !important;
    width: min(92vw, 560px) !important;
    transform: translateX(-50%) translateY(10px) scale(0.98);
  }

  .sb-coin-card.show-layer-3 img.layer-3 {
    transform: translateX(-50%) translateY(0) scale(1) !important;
  }
}

/* End of trangchu.css */