/* src/assets/css/main.css */

@import url('https://fonts.maateen.me/solaiman-lipi/font.css');
@import url('https://fonts.googleapis.com/css2?family=Inter:wght@300;400;500;600;700&display=swap');
@import url('https://cdnjs.cloudflare.com/ajax/libs/font-awesome/6.5.1/css/all.min.css');

/* ── Variables ─────────────────────────────────────────── */
:root {
  --bg:        #FFFFFF;
  --card:      #FFFFFF;
  --card-hover:#F8FAFC;
  --primary:   #2563EB;
  --primary-d: #1D4ED8;
  --success:   #16A34A;
  --success-d: #15803D;
  --danger:    #DC2626;
  --danger-d:  #B91C1C;
  --warning:   #D97706;
  --text:      #0F172A;
  --text-muted:#64748B;
  --text-soft: #475569;
  --border:    transparent;
  --shadow-sm: none;
  --shadow-md: none;
  --shadow-lg: none;
  --radius:    12px;
  --radius-sm: 8px;
  --radius-lg: 16px;
  --font-bn:   'SolaimanLipi', 'Noto Sans Bengali', sans-serif;
  --font-en:   'Inter', sans-serif;
  --transition:0.18s ease;
  --navbar-height: 64px;
  --notice-height: 40px;
  --header-offset: calc(var(--navbar-height) + var(--notice-height));
}

/* ── Reset ─────────────────────────────────────────────── */
*, *::before, *::after { box-sizing: border-box; margin: 0; padding: 0; }

html { 
  scroll-behavior: smooth;
  -webkit-text-size-adjust: 100%;
  text-size-adjust: 100%;
}

body {
  background: var(--bg);
  color: var(--text);
  font-family: var(--font-bn);
  font-size: 15px;
  line-height: 1.65;
  min-height: 100vh;
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
  overflow-x: hidden;
}

a { color: var(--primary); text-decoration: none; transition: color var(--transition); }
a:hover { color: var(--primary-d); }

img { max-width: 100%; display: block; }

/* ── Scrollbar ─────────────────────────────────────────── */
::-webkit-scrollbar { width: 6px; height: 6px; }
::-webkit-scrollbar-track { background: #F1F5F9; }
::-webkit-scrollbar-thumb { background: #CBD5E1; border-radius: 99px; }
::-webkit-scrollbar-thumb:hover { background: #94A3B8; }

/* ── Layout ────────────────────────────────────────────── */
.container { max-width: 1280px; margin: 0 auto; padding: 0 20px; }
.container-sm { max-width: 860px; margin: 0 auto; padding: 0 20px; }

.page-wrapper { padding-top: calc(var(--header-offset) + 12px); min-height: 100vh; }
.page-wrapper:has(.dashboard-layout) { background: #F8FAFC; }

/* ── Safe area for mobile devices ──────────────────────── */
@supports (padding: max(0px)) {
  .page-wrapper {
    padding-left: max(0px, env(safe-area-inset-left));
    padding-right: max(0px, env(safe-area-inset-right));
  }
  .navbar {
    padding-left: max(0px, env(safe-area-inset-left));
    padding-right: max(0px, env(safe-area-inset-right));
  }
  .navbar-inner {
    padding-left: max(20px, calc(20px + env(safe-area-inset-left)));
    padding-right: max(20px, calc(20px + env(safe-area-inset-right)));
  }
  @media (max-width: 768px) {
    .navbar-inner {
      padding-left: max(16px, calc(16px + env(safe-area-inset-left)));
      padding-right: max(16px, calc(16px + env(safe-area-inset-right)));
    }
  }
  @media (max-width: 480px) {
    .navbar-inner {
      padding-left: max(12px, calc(12px + env(safe-area-inset-left)));
      padding-right: max(12px, calc(12px + env(safe-area-inset-right)));
    }
  }
  @media (max-width: 360px) {
    .navbar-inner {
      padding-left: max(10px, calc(10px + env(safe-area-inset-left)));
      padding-right: max(10px, calc(10px + env(safe-area-inset-right)));
    }
  }
}

/* ── Back button ────────────────────────────────────────── */
.back-btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 40px;
  height: 40px;
  border-radius: 50%;
  background: #F1F5F9;
  color: var(--text-soft);
  text-decoration: none;
  transition: background-color 0.15s ease, color 0.15s ease;
  font-size: 16px;
  flex-shrink: 0;
}
.back-btn:hover {
  background: #E2E8F0;
  color: var(--text);
}
.back-btn i {
  margin-left: -2px;
}

/* ── Card ──────────────────────────────────────────────── */
.card {
  background: #FFFFFF;
  border-radius: var(--radius);
  overflow: hidden;
}
.card-body { padding: 20px; }
.card-header { padding: 16px 20px; background: #FFFFFF; }
.card-footer { padding: 14px 20px; background: #F8FAFC; }

/* ── Buttons ───────────────────────────────────────────── */
.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  padding: 10px 20px;
  font-size: 14px;
  font-family: var(--font-bn);
  font-weight: 600;
  border-radius: 16px;
  border: none;
  cursor: pointer;
  transition: all var(--transition);
  white-space: nowrap;
  line-height: 1;
  letter-spacing: 0.01em;
}
.btn:disabled { opacity: 0.55; cursor: not-allowed; pointer-events: none; }
.btn-sm  { padding: 7px 14px; font-size: 13px; }
.btn-lg  { padding: 13px 28px; font-size: 16px; }
.btn-block { width: 100%; }

.btn-primary  { background: var(--primary);  color: #fff; }
.btn-primary:hover  { background: var(--primary-d); }

#nav-login { 
  border-radius: 0; 
  padding: 9px 18px; 
  font-size: 14px;
}
#nav-login:hover { background: var(--primary); }

.btn-success  { background: var(--success);  color: #fff; }
.btn-success:hover  { background: var(--success-d); }

.btn-danger   { background: var(--danger);   color: #fff; }
.btn-danger:hover   { background: var(--danger-d); }

/* Prevent link-buttons from changing text color on hover (override global a:hover) */
a.btn.btn-primary:hover,
a.btn.btn-success:hover,
a.btn.btn-danger:hover { color: #fff; }

.btn-ghost    { background: transparent; color: var(--text-soft); }
.btn-ghost:hover    { background: var(--card-hover); color: var(--text); }

.btn-outline-primary { background: transparent; color: var(--primary); }
.btn-outline-primary:hover { background: var(--primary); color: #fff; }

/* ── Forms ─────────────────────────────────────────────── */
.form-group { margin-bottom: 18px; }
.form-label { display: block; margin-bottom: 7px; font-size: 14px; color: var(--text-soft); font-weight: 500; }
.form-label span.required { color: var(--danger); margin-left: 3px; }

.form-control {
  width: 100%;
  background: #F8FAFC;
  color: var(--text);
  padding: 11px 14px;
  border-radius: 16px;
  font-size: 14px;
  font-family: var(--font-bn);
  transition: background var(--transition);
  outline: none;
  border: none;
  -webkit-appearance: none;
  -moz-appearance: none;
  appearance: none;
}
select.form-control {
  padding-right: 36px;
  background-color: #F8FAFC;
  background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='12' height='12' viewBox='0 0 12 12'%3E%3Cpath fill='%23475569' d='M6 8L1 3h10z'/%3E%3C/svg%3E");
  background-repeat: no-repeat;
  background-position: right 14px center;
  cursor: pointer;
}
select.form-control::-ms-expand {
  display: none;
}
select.form-control:focus {
  background-color: #F1F5F9;
  background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='12' height='12' viewBox='0 0 12 12'%3E%3Cpath fill='%23475569' d='M6 8L1 3h10z'/%3E%3C/svg%3E");
}
.form-control:focus {
  background-color: #F1F5F9;
}
.form-control::placeholder { color: #94A3B8; }
.form-control:invalid:not(:placeholder-shown) { }

textarea.form-control { resize: vertical; min-height: 100px; }

.form-hint { font-size: 12px; color: var(--text-muted); margin-top: 5px; }
.form-error { font-size: 12px; color: var(--danger); margin-top: 5px; display: none; }
.form-error.show { display: block; }

/* ── Custom Dropdown (glass style) ──────────────────────── */
.custom-select {
  position: relative;
  display: inline-block;
  min-width: 160px;
}
.custom-select.form-control-width {
  width: 100%;
  min-width: 100%;
}
.custom-select-trigger {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 8px;
  padding: 10px 14px;
  background: rgba(255,255,255,0.7);
  backdrop-filter: blur(12px);
  -webkit-backdrop-filter: blur(12px);
  border-radius: 16px;
  font-size: 14px;
  font-family: var(--font-bn);
  color: var(--text);
  cursor: pointer;
  transition: background var(--transition);
  user-select: none;
}
.custom-select-trigger:hover {
  background: rgba(255,255,255,0.85);
}
.custom-select-trigger::after {
  content: '';
  width: 10px;
  height: 6px;
  background: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='12' height='12' viewBox='0 0 12 12'%3E%3Cpath fill='%23475569' d='M6 8L1 3h10z'/%3E%3C/svg%3E") no-repeat center;
  background-size: 10px 6px;
  flex-shrink: 0;
  transition: transform var(--transition);
}
.custom-select.open .custom-select-trigger::after {
  transform: rotate(180deg);
}
.custom-select-dropdown {
  position: absolute;
  top: calc(100% + 6px);
  left: 0;
  right: 0;
  min-width: 100%;
  background: rgba(255,255,255,0.65);
  backdrop-filter: blur(16px);
  -webkit-backdrop-filter: blur(16px);
  border-radius: 16px;
  padding: 6px;
  opacity: 0;
  visibility: hidden;
  transform: translateY(-8px);
  transition: all 0.2s ease;
  z-index: 1000;
  max-height: 240px;
  overflow-y: auto;
}
.custom-select.open .custom-select-dropdown {
  opacity: 1;
  visibility: visible;
  transform: translateY(0);
}
.custom-select-option {
  display: block;
  padding: 10px 14px;
  border-radius: 12px;
  font-size: 14px;
  color: var(--text-soft);
  cursor: pointer;
  transition: all var(--transition);
}
.custom-select-option:hover {
  background: rgba(255,255,255,0.6);
  color: var(--text);
}
.custom-select-option.active {
  background: rgba(37,99,235,0.15);
  color: var(--primary);
  font-weight: 600;
}

/* ── Badge ─────────────────────────────────────────────── */
.badge {
  display: inline-flex;
  align-items: center;
  padding: 3px 10px;
  border-radius: 99px;
  font-size: 11px;
  font-weight: 700;
  letter-spacing: 0.04em;
  text-transform: uppercase;
}
.badge-primary  { background: rgba(59,130,246,0.18); color: var(--primary); }
.badge-success  { background: rgba(34,197,94,0.18);  color: var(--success); }
.badge-danger   { background: rgba(239,68,68,0.18);  color: var(--danger); }
.badge-warning  { background: rgba(245,158,11,0.18); color: var(--warning); }
.badge-muted    { background: rgba(148,163,184,0.14);color: var(--text-muted); }

/* ── Navbar & Notice ───────────────────────────────────── */
.site-header { position: relative; }
.site-header::after {
  content: "";
  display: block;
  clear: both;
}
.navbar {
  position: fixed;
  top: 0; left: 0; right: 0;
  z-index: 1000;
  height: var(--navbar-height);
  background: rgba(255,255,255,0.95);
  backdrop-filter: blur(10px);
  -webkit-backdrop-filter: blur(10px);
  display: flex;
  align-items: center;
}
.navbar-inner {
  display: flex;
  align-items: center;
  justify-content: space-between;
  width: 100%;
  max-width: 1280px;
  margin: 0 auto;
  padding: 0 20px;
}
.navbar-brand {
  display: flex;
  align-items: center;
  gap: 10px;
  font-size: 20px;
  font-weight: 700;
  color: var(--text);
  text-decoration: none;
}
.navbar-brand .brand-logo {
  height: 36px;
  width: auto;
  max-width: 140px;
  object-fit: contain;
  flex-shrink: 0;
}
.navbar-nav {
  display: flex;
  align-items: center;
  gap: 4px;
  list-style: none;
}
.navbar-nav a {
  color: var(--text-soft);
  padding: 7px 14px;
  border-radius: 8px;
  font-size: 14px;
  font-weight: 500;
  transition: all var(--transition);
}
.navbar-nav a:hover,
.navbar-nav a.active { color: var(--text); background: #F1F5F9; }

.navbar-actions { display: flex; align-items: center; gap: 8px; }

.notice-bar {
  position: fixed;
  top: var(--navbar-height);
  left: 0;
  right: 0;
  z-index: 999;
  background: var(--primary);
  color: #fff;
  padding: 10px 20px;
  font-size: 14px;
  text-align: center;
}
.notice-bar-inner {
  max-width: 1280px;
  margin: 0 auto;
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 10px;
  flex-wrap: nowrap;
  overflow: hidden;
}
.notice-bar-inner > i {
  flex: 0 0 auto;
}
.notice-bar-text-wrap {
  flex: 1 1 auto;
  min-width: 0;
  overflow: hidden;
}
.notice-bar-text {
  display: inline-block;
  white-space: nowrap;
  max-width: 100%;
}
.notice-bar-text.notice-moving {
  will-change: transform;
  animation-name: notice-marquee;
  animation-duration: var(--notice-marquee-duration, 15s);
  animation-timing-function: linear;
  animation-iteration-count: infinite;
}
@keyframes notice-marquee {
  from { transform: translateX(100%); }
  to { transform: translateX(calc(-1 * var(--notice-scroll-distance, 100%))); }
}
@media (prefers-reduced-motion: reduce) {
  .notice-bar-text.notice-moving {
    animation: none;
    transform: none;
  }
}

.wallet-chip {
  display: flex;
  align-items: center;
  gap: 6px;
  background: #F1F5F9;
  color: var(--text-soft);
  padding: 6px 14px;
  border-radius: 8px;
  font-size: 13px;
  font-weight: 500;
  text-decoration: none;
  cursor: pointer;
  transition: all var(--transition);
}
.wallet-chip:hover {
  background: #E2E8F0;
  color: var(--text);
}
.wallet-chip #nav-wallet-amount {
  color: var(--success);
  font-weight: 600;
}

.notif-btn {
  position: relative;
  background: transparent;
  border: none;
  color: var(--text-soft);
  width: 38px; height: 38px;
  border-radius: 50%;
  cursor: pointer;
  display: flex; align-items: center; justify-content: center;
  transition: all var(--transition);
  font-size: 16px;
}
.notif-btn:hover { color: var(--text); }
.notif-badge {
  position: absolute;
  top: 4px; right: 4px;
  width: 8px; height: 8px;
  background: var(--danger);
  border-radius: 50%;
}

.hamburger {
  display: none;
  flex-direction: column;
  gap: 5px;
  background: none;
  border: none;
  cursor: pointer;
  padding: 8px 4px;
  min-width: 44px;
  min-height: 44px;
  justify-content: center;
  align-items: center;
  border-radius: var(--radius-sm);
  transition: background var(--transition);
}
.hamburger:hover { background: #F1F5F9; }
.hamburger span {
  display: block;
  width: 22px; height: 2px;
  background: var(--text-soft);
  border-radius: 2px;
  transition: all var(--transition);
}
.hamburger.active span:nth-child(1) { transform: rotate(45deg) translate(6px, 6px); }
.hamburger.active span:nth-child(2) { opacity: 0; }
.hamburger.active span:nth-child(3) { transform: rotate(-45deg) translate(6px, -6px); }

/* ── Hero Banner Slider ───────────────────────────────── */
.hero-slider-wrap {
  position: relative;
  width: 100%;
  overflow: hidden;
  background: #E2E8F0;
}
.hero-slider {
  position: relative;
  width: 100%;
  aspect-ratio: 1280 / 420;
  max-height: 420px;
}
.hero-slide {
  position: absolute;
  inset: 0;
  display: flex;
  opacity: 0;
  pointer-events: none;
  transition: opacity 0.5s ease;
}
.hero-slide.active {
  opacity: 1;
  pointer-events: auto;
}
.hero-slide img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  display: block;
}
.hero-slider-dots {
  position: absolute;
  bottom: 16px;
  left: 50%;
  transform: translateX(-50%);
  display: flex;
  gap: 8px;
  z-index: 10;
}
.hero-slider-dot {
  width: 10px;
  height: 10px;
  border-radius: 50%;
  background: rgba(255,255,255,0.5);
  border: none;
  cursor: pointer;
  padding: 0;
  transition: background 0.2s;
}
.hero-slider-dot.active { background: #fff; }
.hero-slider-prev,
.hero-slider-next {
  position: absolute;
  top: 50%;
  transform: translateY(-50%);
  width: 44px;
  height: 44px;
  border-radius: 50%;
  background: rgba(255,255,255,0.9);
  border: none;
  cursor: pointer;
  display: flex;
  align-items: center;
  justify-content: center;
  color: var(--text);
  font-size: 18px;
  z-index: 10;
  transition: background 0.2s, opacity 0.2s;
}
.hero-slider-prev:hover,
.hero-slider-next:hover { background: #fff; }
.hero-slider-prev { left: 16px; }
.hero-slider-next { right: 16px; }

/* ── Hero (Game logos) ────────────────────────────────── */
.hero {
  background: linear-gradient(180deg, #F8FAFC 0%, #FFFFFF 100%);
  padding: 32px 0 40px;
  text-align: center;
  position: relative;
  overflow: hidden;
}
.hero::before { content: none; }

.hero-banners {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 16px;
  margin-bottom: 28px;
  max-width: 900px;
  margin-left: auto;
  margin-right: auto;
}
.hero-banner {
  display: flex;
  align-items: center;
  gap: 14px;
  padding: 18px 20px;
  border-radius: 14px;
  text-decoration: none;
  transition: transform 0.2s ease, box-shadow 0.2s ease;
  border: 1px solid transparent;
}
.hero-banner:hover {
  transform: translateY(-2px);
  box-shadow: 0 8px 24px rgba(0,0,0,0.08);
}
.hero-banner--primary {
  background: linear-gradient(135deg, rgba(37,99,235,0.12), rgba(37,99,235,0.06));
  border-color: rgba(37,99,235,0.2);
  color: var(--primary);
}
.hero-banner--primary .hero-banner-desc { color: var(--text-muted); }
.hero-banner--accent {
  background: linear-gradient(135deg, rgba(22,163,74,0.12), rgba(22,163,74,0.06));
  border-color: rgba(22,163,74,0.2);
  color: var(--success);
}
.hero-banner--accent .hero-banner-desc { color: var(--text-muted); }
.hero-banner--muted {
  background: #F8FAFC;
  border-color: #E2E8F0;
  color: var(--text);
}
.hero-banner--muted .hero-banner-desc { color: var(--text-muted); }
.hero-banner-icon {
  width: 48px;
  height: 48px;
  display: flex;
  align-items: center;
  justify-content: center;
  background: rgba(255,255,255,0.8);
  border-radius: 12px;
  font-size: 20px;
  flex-shrink: 0;
}
.hero-banner--primary .hero-banner-icon { color: var(--primary); }
.hero-banner--accent .hero-banner-icon { color: var(--success); }
.hero-banner--muted .hero-banner-icon { color: var(--text-soft); }
.hero-banner-content {
  flex: 1;
  min-width: 0;
  display: flex;
  flex-direction: column;
  gap: 4px;
}
.hero-banner-title { font-weight: 700; font-size: 15px; }
.hero-banner-desc { font-size: 13px; }
.hero-banner-arrow {
  font-size: 14px;
  opacity: 0.6;
  transition: transform 0.2s ease;
}
.hero-banner:hover .hero-banner-arrow { transform: translateX(4px); opacity: 1; }

.search-bar {
  display: flex;
  align-items: center;
  max-width: 560px;
  margin: 0 auto;
  background: #FFFFFF;
  border: 1px solid #E2E8F0;
  border-radius: 14px;
  padding: 4px 4px 4px 18px;
  box-shadow: 0 1px 3px rgba(0,0,0,0.04);
  transition: border-color var(--transition), box-shadow var(--transition);
}
.search-bar:focus-within {
  border-color: var(--primary);
  box-shadow: 0 0 0 3px rgba(37,99,235,0.12);
}
.search-bar-icon {
  color: #94A3B8;
  font-size: 16px;
  display: flex;
  align-items: center;
  margin-right: 4px;
}
.search-bar:focus-within .search-bar-icon { color: var(--primary); }
.search-bar input {
  flex: 1;
  min-width: 0;
  background: none;
  border: none;
  color: var(--text);
  font-size: 15px;
  font-family: var(--font-bn);
  outline: none;
  padding: 12px 8px 12px 0;
}
.search-bar input::placeholder { color: #94A3B8; }
.search-bar button {
  background: var(--primary);
  color: #fff;
  border: none;
  padding: 12px 24px;
  border-radius: 10px;
  font-size: 14px;
  font-family: var(--font-bn);
  font-weight: 600;
  cursor: pointer;
  transition: background var(--transition), transform 0.15s ease;
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
}
.search-bar button:hover { background: var(--primary-d); }
.search-bar button:active { transform: scale(0.98); }

.search-bar--inline {
  margin: 0;
  flex: 1;
  min-width: 200px;
  max-width: 460px;
}

/* ── Game Category Pills ───────────────────────────────── */
.category-pills { display: flex; gap: 8px; flex-wrap: wrap; justify-content: center; margin-top: 24px; }
.pill {
  padding: 6px 16px;
  border-radius: 99px;
  background: #F1F5F9;
  color: var(--text-soft);
  font-size: 13px;
  cursor: pointer;
  transition: all var(--transition);
}
.pill:hover, .pill.active {
  background: var(--primary);
  color: #fff;
}

/* ── Game Logos ────────────────────────────────────────── */
.game-logos {
  display: flex;
  gap: 24px;
  flex-wrap: wrap;
  justify-content: center;
  margin-top: 28px;
}
.game-logo-item {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 10px;
  cursor: pointer;
  transition: opacity 0.15s ease;
}
.game-logo-item:hover {
  opacity: 0.9;
}
.game-logo-item.active .game-logo-img {
  outline: 2px solid var(--primary);
  outline-offset: 2px;
}
.game-logo-img {
  width: 100px;
  height: 100px;
  border-radius: 22px;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 22px;
  font-weight: 700;
  color: #fff;
  overflow: hidden;
}
.game-logo-img img {
  width: 100%;
  height: 100%;
  object-fit: cover;
}
.game-logo-name {
  font-size: 15px;
  font-weight: 500;
  color: var(--text-soft);
  text-align: center;
}
.game-logo-item.active .game-logo-name {
  color: var(--primary);
}

/* ── Game Cards ────────────────────────────────────────── */
.game-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(240px, 1fr)); gap: 20px; }

.game-card {
  background: #FFFFFF;
  border-radius: var(--radius);
  overflow: hidden;
  transition: background-color 0.15s ease;
  display: flex;
  flex-direction: column;
  cursor: pointer;
}
.game-card:hover {
  background: var(--card-hover);
}
.game-card-img {
  width: 100%;
  aspect-ratio: 16/10;
  object-fit: cover;
  background: #E2E8F0;
}
.game-card-img-wrap { position: relative; width: 100%; aspect-ratio: 16/10; }
.game-card-img-wrap .game-card-img-placeholder { position: absolute; inset: 0; }
.game-card-img-placeholder {
  width: 100%;
  aspect-ratio: 16/10;
  background: linear-gradient(135deg, #F1F5F9, #E2E8F0);
  display: flex; align-items: center; justify-content: center;
  font-size: 42px;
  color: #94A3B8;
}
.game-card-body { padding: 14px 16px; flex: 1; display: flex; flex-direction: column; gap: 8px; }
.game-card-title { font-size: 15px; font-weight: 600; color: var(--text); }
.game-card-ref { font-size: 11px; color: var(--text-muted); font-family: monospace; }
.game-card-price { font-size: 18px; font-weight: 700; color: var(--success); margin-top: auto; }
.game-card-meta { display: flex; align-items: center; justify-content: space-between; }
.game-card-seller { font-size: 12px; color: var(--text-muted); display: flex; align-items: center; gap: 4px; }
.star-rating { color: #FBBF24; font-size: 12px; }

.game-card-footer { padding: 12px 16px; }

/* ── Section ───────────────────────────────────────────── */
.section { padding: 40px 0; }
.section-header { display: flex; align-items: center; justify-content: space-between; margin-bottom: 24px; }
.section-title { font-size: 20px; font-weight: 700; }
.section-title::before { content: ''; display: inline-block; width: 4px; height: 20px; background: var(--primary); border-radius: 4px; margin-right: 10px; vertical-align: -3px; }

/* ── How It Works ──────────────────────────────────────── */
.how-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(220px, 1fr));
  gap: 16px;
}
.how-card {
  background: #F8FAFC;
  border-radius: var(--radius);
  padding: 18px;
}
.how-step {
  width: 30px;
  height: 30px;
  border-radius: 999px;
  background: #DBEAFE;
  color: var(--primary);
  display: inline-flex;
  align-items: center;
  justify-content: center;
  font-weight: 700;
  font-size: 13px;
  margin-bottom: 10px;
}
.how-title {
  font-size: 15px;
  font-weight: 700;
  margin-bottom: 6px;
}
.how-text {
  color: var(--text-muted);
  font-size: 14px;
}

/* ── Alert / Toast ─────────────────────────────────────── */
.alert {
  padding: 13px 16px;
  border-radius: var(--radius-sm);
  font-size: 14px;
  margin-bottom: 16px;
  display: flex;
  align-items: flex-start;
  gap: 10px;
}
.alert-success { background: #DCFCE7;  color: #166534; }
.alert-danger   { background: #FEE2E2;  color: #991B1B; }
.alert-info     { background: #DBEAFE; color: #1E40AF; }
.alert-warning  { background: #FEF3C7; color: #92400E; }

#toast-container {
  position: fixed;
  top: 80px; right: 20px;
  z-index: 9999;
  display: flex; flex-direction: column; gap: 10px;
  pointer-events: none;
}
.toast {
  background: var(--card);
  border-radius: var(--radius-sm);
  padding: 14px 16px;
  font-size: 14px;
  max-width: 320px;
  pointer-events: all;
  animation: slideIn 0.25s ease;
  display: flex; align-items: center; gap: 10px;
}
.toast.success { background: #FFFFFF; }
.toast.error   { background: #FFFFFF; }
.toast.info    { background: #FFFFFF; }
@keyframes slideIn { from { opacity:0; transform: translateX(20px); } to { opacity:1; transform: translateX(0); } }

/* ── Modal ─────────────────────────────────────────────── */
.modal-overlay {
  position: fixed; inset: 0;
  background: rgba(0,0,0,0.4);
  backdrop-filter: blur(4px);
  z-index: 2000;
  display: flex; align-items: center; justify-content: center;
  padding: 20px;
  opacity: 0; pointer-events: none;
  transition: opacity var(--transition);
}
.modal-overlay.open { opacity: 1; pointer-events: all; }
.modal {
  background: var(--card);
  border-radius: var(--radius-lg);
  width: 100%;
  max-width: 520px;
  max-height: 90vh;
  overflow-y: auto;
  transform: scale(0.95);
  transition: transform var(--transition);
}
.modal-overlay.open .modal { transform: scale(1); }
.modal-header {
  padding: 20px 24px 16px;
  display: flex; align-items: center; justify-content: space-between;
}
.modal-title { font-size: 17px; font-weight: 700; }
.modal-close {
  background: none; border: none; color: var(--text-muted);
  cursor: pointer; font-size: 20px; line-height: 1;
  transition: color var(--transition);
}
.modal-close:hover { color: var(--text); }
.modal-body { padding: 20px 24px; }
.modal-footer { padding: 16px 24px 20px; display: flex; justify-content: flex-end; gap: 10px; }

/* ── Table ─────────────────────────────────────────────── */
.table-wrapper { overflow-x: auto; }
table { width: 100%; border-collapse: collapse; }
th { text-align: left; padding: 11px 14px; font-size: 12px; text-transform: uppercase; letter-spacing: 0.06em; color: var(--text-muted); white-space: nowrap; }
td { padding: 13px 14px; font-size: 14px; }
tr { transition: background-color 0.12s ease; }
tr:hover td { background: #F8FAFC; }
tr:last-child td { border-bottom: none; }

/* ── Dashboard Sidebar ─────────────────────────────────── */
.dashboard-layout { display: flex; gap: 24px; align-items: flex-start; }

.sidebar {
  width: 230px;
  flex-shrink: 0;
  background: #FFFFFF;
  border-radius: var(--radius);
  overflow: hidden;
  position: sticky;
  top: 80px;
}
.sidebar > div:first-child {
  padding: 20px 16px 12px;
  border-bottom: 1px solid #F1F5F9;
}
.sidebar-menu { list-style: none; padding: 8px; }
.sidebar-menu li a {
  display: flex;
  align-items: center;
  gap: 10px;
  padding: 10px 14px;
  border-radius: 8px;
  color: var(--text-soft);
  font-size: 14px;
  font-weight: 500;
  transition: background-color 0.15s ease, color 0.15s ease;
}
.sidebar-menu li a:hover,
.sidebar-menu li a.active { color: var(--text); background: #F1F5F9; }
.sidebar-menu li a.active { color: var(--primary); background: rgba(37,99,235,0.08); }
.sidebar-menu .icon { font-size: 16px; opacity: 0.8; }

.dashboard-content { flex: 1; min-width: 0; }

.dashboard-menu-toggle { display: none; margin-bottom: 0; border: none; }

/* ── Stats Cards ───────────────────────────────────────── */
.stats-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(180px, 1fr)); gap: 16px; margin-bottom: 24px; }
.stat-card {
  background: #FFFFFF;
  border-radius: var(--radius);
  padding: 20px;
  transition: background-color 0.15s ease;
}
.stat-card:hover { background: #FFFFFF; }
.stat-label { font-size: 12px; color: var(--text-muted); text-transform: uppercase; letter-spacing: 0.06em; margin-bottom: 8px; }
.stat-value { font-size: 26px; font-weight: 800; }
.stat-value.green { color: var(--success); }
.stat-value.blue  { color: var(--primary); }
.stat-value.red   { color: var(--danger); }

/* ── Dashboard filters/tabs ─────────────────────────────── */
.dashboard-content .filter-tab,
.dashboard-content .tab-btn {
  padding: 6px 14px;
  border-radius: var(--radius-sm);
  background: #F1F5F9;
  color: var(--text-muted);
  font-size: 13px;
  cursor: pointer;
  border: none;
  font-family: var(--font-bn);
  font-weight: 500;
  transition: background-color 0.15s ease, color 0.15s ease;
}
.dashboard-content .filter-tab:hover,
.dashboard-content .tab-btn:hover {
  background: #E2E8F0;
  color: var(--text);
}
.dashboard-content .filter-tab.active,
.dashboard-content .tab-btn.active {
  background: var(--primary);
  color: #fff;
}

/* ── Order Status Colors ───────────────────────────────── */
.status-pending          { color: var(--warning); }
.status-payment_pending  { color: var(--warning); }
.status-payment_received { color: var(--primary); }
.status-processing       { color: #a78bfa; }
.status-completed        { color: var(--success); }
.status-cancelled        { color: var(--danger); }
.status-disputed         { color: #fb923c; }

/* ── Chat ──────────────────────────────────────────────── */
.chat-window {
  display: flex;
  flex-direction: column;
  height: 480px;
  background: linear-gradient(180deg, #FFFFFF 0%, #F8FAFC 100%);
  border-radius: var(--radius);
  overflow: hidden;
}
.chat-messages { flex: 1; overflow-y: auto; padding: 16px; display: flex; flex-direction: column; gap: 10px; }
.chat-msg { max-width: 72%; }
.chat-msg.mine { align-self: flex-end; }
.chat-msg.theirs { align-self: flex-start; }
.chat-sender-row { display: flex; align-items: center; gap: 6px; margin: 0 2px 2px; }
.chat-msg-avatar {
  width: 24px; height: 24px;
  border-radius: 50%;
  object-fit: cover;
  flex-shrink: 0;
  border: 1px solid rgba(0,0,0,0.08);
}
.chat-sender-label { font-size: 11px; color: var(--text-muted); }
.chat-bubble {
  padding: 11px 14px;
  border-radius: 14px;
  font-size: 14px;
  line-height: 1.5;
  word-break: break-word;
  box-shadow: 0 8px 24px rgba(15, 23, 42, 0.08);
}
.chat-msg.mine   .chat-bubble { background: linear-gradient(135deg, #2563EB 0%, #1D4ED8 100%); color: #fff; border-bottom-right-radius: 6px; box-shadow: 0 10px 24px rgba(37, 99, 235, 0.28); }
.chat-msg.theirs .chat-bubble { background: #FFFFFF; color: var(--text); border-bottom-left-radius: 6px; }
.chat-msg-meta { font-size: 11px; color: var(--text-muted); margin-top: 3px; }
.chat-msg.mine .chat-msg-meta { text-align: right; }
.chat-time-divider {
  align-self: center;
  font-size: 11px;
  color: var(--text-muted);
  background: rgba(148,163,184,0.16);
  padding: 4px 10px;
  border-radius: 999px;
  margin: 6px 0;
}
.chat-input-bar { padding: 12px 16px 16px; display: flex; gap: 8px; margin-top: auto; flex-shrink: 0; }
.chat-input-bar .form-control { border-radius: 99px; padding: 10px 16px; }

/* Chat with footer (input fixed at bottom of chat section, messages scroll above) */
.chat-card-with-footer { display: flex; flex-direction: column; overflow: hidden; min-height: 0; }
.chat-card-with-footer .chat-messages-wrap { flex: 1 1 auto; min-height: 200px; overflow-y: auto; overflow-x: hidden; background: linear-gradient(180deg, #FFFFFF 0%, #F8FAFC 100%); }
.chat-card-with-footer .chat-messages-wrap .chat-messages { padding: 16px; display: flex; flex-direction: column; gap: 10px; min-height: min-content; }
.chat-card-with-footer .chat-footer { flex: 0 0 auto; padding: 12px 16px; background: #FFFFFF; box-shadow: 0 -8px 24px rgba(15, 23, 42, 0.06); }
.chat-card-with-footer .chat-footer .chat-input-bar { padding: 0; margin: 0; }

/* Premium chat lists (support + unified messages) */
#messages-list .msg-item,
#ticket-list .support-ticket-item {
  margin: 6px 8px;
  border-radius: 12px;
}
#messages-list .msg-item:hover,
#ticket-list .support-ticket-item:hover {
  background: #F8FAFC !important;
}

/* ── Pagination ────────────────────────────────────────── */
.pagination { display: flex; gap: 4px; justify-content: center; margin-top: 32px; flex-wrap: wrap; }
.page-btn {
  min-width: 36px; height: 36px;
  display: flex; align-items: center; justify-content: center;
  border-radius: 8px;
  background: var(--card);
  color: var(--text-soft);
  font-size: 14px;
  cursor: pointer;
  transition: all var(--transition);
}
.page-btn:hover { background: var(--card-hover); color: var(--text); }
.page-btn.active { background: var(--primary); color: #fff; }

/* ── Loading Skeleton ──────────────────────────────────── */
.skeleton {
  background: linear-gradient(90deg, #F1F5F9 25%, #E2E8F0 50%, #F1F5F9 75%);
  background-size: 200% 100%;
  animation: shimmer 1.4s infinite;
  border-radius: var(--radius-sm);
}
@keyframes shimmer { 0%{background-position:200% 0} 100%{background-position:-200% 0} }

/* ── Verified Badge ────────────────────────────────────── */
.verified { color: var(--primary); font-size: 13px; }

/* ── Footer ─────────────────────────────────────────────── */
.site-footer {
  background: #F8FAFC;
  padding: 40px 0 24px;
  margin-top: auto;
}

.footer-grid {
  display: grid;
  grid-template-columns: 2fr 1fr 1fr 1fr;
  gap: 32px;
  margin-bottom: 32px;
}

.footer-col {
  display: flex;
  flex-direction: column;
}

.footer-col-brand {
  max-width: 300px;
}

.footer-brand {
  display: flex;
  align-items: center;
  gap: 10px;
  margin-bottom: 14px;
}

.footer-brand-logo {
  height: 34px;
  width: auto;
  max-width: 120px;
  object-fit: contain;
  flex-shrink: 0;
}

.footer-brand-text {
  font-size: 18px;
  font-weight: 800;
  color: var(--text);
}

.footer-description {
  color: var(--text-muted);
  font-size: 14px;
  line-height: 1.7;
  margin-bottom: 14px;
}

.footer-social {
  display: flex;
  gap: 10px;
  margin-top: 4px;
}

.footer-social-link {
  width: 38px;
  height: 38px;
  background: #E2E8F0;
  border-radius: 10px;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 18px;
  text-decoration: none;
}

.footer-social-link .fa-facebook-f { color: #1877F2; }
.footer-social-link .fa-telegram { color: #26A5E4; }
.footer-social-link .fa-whatsapp { color: #25D366; }

.footer-title {
  font-size: 13px;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.06em;
  color: var(--text-muted);
  margin-bottom: 14px;
}

.footer-links {
  list-style: none;
  display: flex;
  flex-direction: column;
  gap: 10px;
  padding: 0;
  margin: 0;
}

.footer-links li {
  margin: 0;
  padding: 0;
}

.footer-links a {
  color: var(--text-soft);
  font-size: 14px;
  text-decoration: none;
  transition: color var(--transition);
  display: inline-block;
}

.footer-links a:hover {
  color: var(--text);
}

.footer-payment {
  padding-top: 20px;
  margin-bottom: 16px;
}

.footer-payment-label {
  font-size: 13px;
  color: var(--text-muted);
  margin-right: 12px;
}

.footer-payment-methods {
  display: flex;
  align-items: center;
  gap: 16px;
  flex-wrap: wrap;
  margin-top: 8px;
}

.footer-payment-logo {
  height: 36px;
  width: auto;
  object-fit: contain;
  border-radius: 6px;
}

.footer-bottom {
  display: flex;
  align-items: center;
  justify-content: space-between;
  flex-wrap: wrap;
  gap: 10px;
  padding-top: 16px;
}

.footer-copyright,
.footer-security {
  color: var(--text-muted);
  font-size: 13px;
  margin: 0;
}

/* ── Divider ───────────────────────────────────────────── */
.divider { height: 1px; background: #F1F5F9; margin: 20px 0; }

/* ── Upload Zone ───────────────────────────────────────── */
.upload-zone {
  background: #F8FAFC;
  border-radius: var(--radius);
  padding: 32px;
  text-align: center;
  cursor: pointer;
  transition: background-color 0.15s ease, color 0.15s ease;
  color: var(--text-muted);
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
}
.upload-zone:hover, .upload-zone.drag-over {
  background: #F1F5F9;
  color: var(--text-soft);
}

/* ── Rating Stars ──────────────────────────────────────── */
.stars { display: flex; gap: 4px; }
.star { font-size: 22px; cursor: pointer; color: #CBD5E1; transition: color var(--transition); }
.star.filled, .star:hover { color: #FBBF24; }

/* ── Responsive ────────────────────────────────────────── */

/* Tablet and below (1024px) */
@media (max-width: 1024px) {
  .container { padding: 0 16px; }
  .container-sm { padding: 0 16px; }
  
  /* Navbar tablet */
  .navbar-inner { padding: 0 16px; }
  .navbar-nav { gap: 2px; }
  .navbar-nav a { padding: 6px 12px; font-size: 13px; }
  .navbar-actions { gap: 6px; }
  .wallet-chip { padding: 5px 12px; font-size: 12px; }
  
  .game-grid { grid-template-columns: repeat(auto-fill, minmax(200px, 1fr)); gap: 16px; }
  .stats-grid { grid-template-columns: repeat(3, 1fr); }
  
  .hero { padding: 48px 0 40px; }
  .hero-title { font-size: clamp(24px, 4vw, 36px); }
  
  .section { padding: 32px 0; }
  .section-header { flex-direction: column; align-items: flex-start; gap: 12px; }
  
  /* Footer tablet */
  .footer-grid {
    grid-template-columns: 1.5fr 1fr 1fr 1fr;
    gap: 28px;
  }
  
  .footer-col-brand {
    max-width: 280px;
  }
  
  /* Dashboard tablet */
  .dashboard-layout { gap: 20px; flex-direction: column; }
  .sidebar { width: 200px; }
  .dashboard-menu-toggle {
    display: flex; align-items: center; gap: 8px; padding: 12px 16px;
    background: var(--card); border-radius: var(--radius); cursor: pointer; font-weight: 600;
    margin-bottom: 16px; margin-top: 16px;
  }
  .dashboard-menu-toggle i { transition: transform 0.2s; }
  .dashboard-menu-toggle.open i { transform: rotate(180deg); }
  .dashboard-layout .sidebar {
    width: 100%; position: relative; top: auto; height: auto; max-height: 0;
    overflow: hidden; padding: 0 10px; transition: max-height 0.3s ease;
  }
  .dashboard-layout .sidebar.open { max-height: 450px; padding: 16px 10px; }
}

/* Mobile landscape and below (768px) */
@media (max-width: 768px) {
  :root {
    --navbar-height: 60px;
  }
  /* Typography improvements */
  body { font-size: 14px; }
  
  /* Navbar mobile improvements */
  .navbar { 
    height: 60px; 
    position: fixed;
    top: 0;
    left: 0;
    right: 0;
  }
  .navbar-inner { 
    padding: 0 16px; 
    max-width: 100%;
  }
  .navbar-brand { 
    font-size: 18px; 
    gap: 8px; 
    flex-shrink: 0;
  }
  .navbar-brand .brand-logo { 
    height: 32px; 
    max-width: 120px;
  }
  .notice-bar { top: var(--navbar-height); padding: 8px 16px; font-size: 13px; }
  .notice-bar-inner { gap: 8px; padding: 0 4px; }
  .navbar-nav {
    display: none;
    position: fixed;
    top: var(--header-offset);
    left: 0; 
    right: 0;
    background: var(--card); 
    flex-direction: column; 
    padding: 12px 16px;
    gap: 4px;
    max-height: calc(100vh - var(--header-offset));
    overflow-y: auto;
    -webkit-overflow-scrolling: touch;
  }
  .navbar-nav.mobile-open { display: flex; }
  .navbar-nav li { 
    width: 100%; 
    list-style: none;
  }
  .navbar-nav a { 
    display: flex;
    align-items: center;
    padding: 12px 16px; 
    border-radius: var(--radius-sm);
    width: 100%;
    font-size: 15px;
    min-height: 44px;
    box-sizing: border-box;
  }
  
  .hamburger { 
    display: flex; 
    flex-shrink: 0;
  }
  
  .navbar-actions { 
    gap: 6px; 
    flex-shrink: 0;
    align-items: center;
  }
  .wallet-chip { 
    padding: 5px 12px; 
    font-size: 12px;
    gap: 4px;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
    max-width: 120px;
  }
  .wallet-chip span:first-child {
    display: none;
  }
  .notif-btn { 
    width: 36px; 
    height: 36px; 
    font-size: 15px; 
    flex-shrink: 0;
  }
  .btn-sm { 
    padding: 8px 14px; 
    font-size: 12px; 
    white-space: nowrap;
    min-height: 36px;
  }
  
  /* User dropdown mobile */
  .nav-user-wrap {
    position: relative;
  }
  .user-dropdown {
    right: 0;
    left: auto;
    min-width: 200px;
    max-width: calc(100vw - 32px);
  }
  
  /* Hero slider mobile */
  .hero-slider { aspect-ratio: 16/9; max-height: 220px; }
  .hero-slider-prev, .hero-slider-next { width: 36px; height: 36px; font-size: 14px; }
  .hero-slider-prev { left: 8px; }
  .hero-slider-next { right: 8px; }
  .hero-slider-dots { bottom: 10px; }
  .hero-slider-dot { width: 8px; height: 8px; }
  
  /* Hero section mobile */
  .hero { padding: 24px 0 28px; }
  
  .hero-banners {
    grid-template-columns: repeat(2, 1fr);
    gap: 12px;
    margin-bottom: 24px;
  }
  .hero-banner { padding: 14px 16px; }
  .hero-banner-icon { width: 42px; height: 42px; font-size: 18px; }
  .hero-banner-title { font-size: 14px; }
  .hero-banner-desc { font-size: 12px; }
  
  .search-bar { 
    max-width: 100%;
    padding: 4px 4px 4px 14px;
    border-radius: 12px;
  }
  .search-bar input { font-size: 14px; padding: 10px 6px 10px 0; }
  .search-bar button { 
    padding: 10px 18px; 
    font-size: 13px;
    white-space: nowrap;
    border-radius: 8px;
  }
  
  .category-pills { 
    gap: 6px; 
    margin-top: 20px;
    justify-content: flex-start;
    overflow-x: auto;
    padding-bottom: 4px;
    -webkit-overflow-scrolling: touch;
    scrollbar-width: none;
  }
  .category-pills::-webkit-scrollbar { display: none; }
  .pill { 
    padding: 6px 14px; 
    font-size: 12px;
    white-space: nowrap;
    flex-shrink: 0;
  }
  .game-logos {
    gap: 14px;
    margin-top: 20px;
    overflow-x: auto;
    justify-content: flex-start;
    padding-bottom: 4px;
    -webkit-overflow-scrolling: touch;
    scrollbar-width: none;
  }
  .game-logos::-webkit-scrollbar { display: none; }
  .game-logo-item { flex-shrink: 0; }
  .game-logo-img { width: 80px; height: 80px; font-size: 18px; }
  .game-logo-name { font-size: 14px; }
  
  /* Layout improvements */
  .dashboard-layout { flex-direction: column; gap: 16px; }
  .sidebar { 
    width: 100%; 
    position: static; 
    top: auto;
    border-radius: var(--radius);
  }
  .sidebar-menu { padding: 6px; }
  .sidebar-menu li a { 
    padding: 12px 14px; 
    font-size: 14px;
    gap: 12px;
  }
  
  .dashboard-content { width: 100%; }
  
  /* Cards and grids */
  .game-grid { 
    grid-template-columns: repeat(auto-fill, minmax(150px, 1fr)); 
    gap: 12px; 
  }
  .game-card-body { padding: 12px 14px; gap: 6px; }
  .game-card-title { font-size: 14px; }
  .game-card-price { font-size: 16px; }
  .game-card-footer { padding: 10px 14px; }
  
  .stats-grid { 
    grid-template-columns: repeat(2, 1fr); 
    gap: 12px; 
  }
  .stat-card { padding: 16px; }
  .stat-label { font-size: 11px; }
  .stat-value { font-size: 22px; }
  
  /* Forms mobile */
  .form-group { margin-bottom: 16px; }
  .form-label { font-size: 13px; margin-bottom: 6px; }
  .form-control { 
    padding: 12px 14px; 
    font-size: 14px;
    border-radius: var(--radius-sm);
    -webkit-appearance: none;
    appearance: none;
  }
  textarea.form-control { min-height: 90px; }
  
  /* Buttons mobile */
  .btn { 
    padding: 11px 18px; 
    font-size: 14px;
    min-height: 44px; /* Better touch target */
  }
  .btn-sm { 
    padding: 8px 14px; 
    font-size: 13px;
    min-height: 36px;
  }
  .btn-lg { 
    padding: 14px 24px; 
    font-size: 15px;
    min-height: 48px;
  }
  
  /* Cards */
  .card-body { padding: 16px; }
  .card-header { padding: 14px 16px; }
  .card-footer { padding: 12px 16px; }
  
  /* Modals mobile */
  .modal-overlay { padding: 16px; align-items: flex-end; }
  .modal { 
    max-width: 100%; 
    max-height: 90vh;
    border-radius: var(--radius-lg) var(--radius-lg) 0 0;
    margin-bottom: 0;
  }
  .modal-header { padding: 18px 20px 14px; }
  .modal-title { font-size: 16px; }
  .modal-body { padding: 18px 20px; }
  .modal-footer { 
    padding: 14px 20px 18px; 
    flex-direction: column-reverse;
    gap: 8px;
  }
  .modal-footer .btn { width: 100%; }
  
  /* Tables mobile */
  .table-wrapper { 
    overflow-x: auto;
    -webkit-overflow-scrolling: touch;
  }
  table { min-width: 600px; }
  th { padding: 10px 12px; font-size: 11px; }
  td { padding: 11px 12px; font-size: 13px; }
  
  /* Section spacing */
  .section { padding: 24px 0; }
  .section-title { font-size: 18px; }
  
  
  /* Footer mobile */
  .site-footer {
    padding: 32px 0 20px;
  }
  
  .footer-grid {
    grid-template-columns: 1fr 1fr;
    gap: 20px;
    margin-bottom: 24px;
  }
  
  .footer-col-brand {
    grid-column: 1 / -1;
    max-width: 100%;
    margin-bottom: 8px;
  }
  
  .footer-brand {
    margin-bottom: 12px;
  }
  
  .footer-brand-text {
    font-size: 16px;
  }
  
  .footer-description {
    font-size: 13px;
    margin-bottom: 12px;
  }
  
  .footer-title {
    font-size: 12px;
    margin-bottom: 10px;
  }
  
  .footer-links {
    gap: 6px;
  }
  
  .footer-links a {
    font-size: 13px;
  }
  
  .footer-payment {
    padding-top: 16px;
    margin-bottom: 14px;
  }
  
  .footer-payment-label {
    font-size: 12px;
    display: block;
    margin-bottom: 8px;
    margin-right: 0;
  }
  
  .footer-payment-methods {
    gap: 10px;
    margin-top: 0;
  }
  
  .footer-payment-logo {
    height: 32px;
  }
  
  .footer-bottom {
    flex-direction: column;
    align-items: flex-start;
    gap: 8px;
    padding-top: 14px;
  }
  
  .footer-copyright,
  .footer-security {
    font-size: 12px;
    width: 100%;
  }
  
  /* Toast mobile */
  #toast-container { 
    top: 70px; 
    right: 16px; 
    left: 16px;
    max-width: none;
  }
  .toast { 
    max-width: 100%;
    padding: 12px 14px;
    font-size: 13px;
  }
  
  /* Chat mobile */
  .chat-window { height: 400px; }
  .chat-messages { padding: 12px; }
  .chat-bubble { padding: 9px 12px; font-size: 13px; }
  .chat-input-bar { padding: 10px; }
  
  /* Pagination mobile */
  .pagination { gap: 4px; margin-top: 24px; }
  .page-btn { 
    min-width: 32px; 
    height: 32px;
    font-size: 13px;
  }
  
  /* Badge mobile */
  .badge { padding: 2px 8px; font-size: 10px; }
  
  /* Alert mobile */
  .alert { 
    padding: 12px 14px; 
    font-size: 13px;
    margin-bottom: 12px;
  }
  
  /* Upload zone mobile */
  .upload-zone { padding: 24px 16px; }
  
  /* Stars mobile */
  .star { font-size: 20px; }
}

/* Small mobile (480px and below) */
@media (max-width: 480px) {
  /* Container padding */
  .container { padding: 0 12px; }
  .container-sm { padding: 0 12px; }
  
  /* Navbar small mobile */
  .navbar-inner { padding: 0 12px; }
  .navbar-brand { font-size: 16px; }
  .navbar-brand .brand-logo { height: 28px; max-width: 100px; }
  .navbar-brand span {
    font-size: 15px;
  }
  .wallet-chip {
    max-width: 100px;
    font-size: 11px;
    padding: 5px 8px;
  }
  .notif-btn {
    width: 34px;
    height: 34px;
    font-size: 14px;
  }
  .btn-sm {
    padding: 6px 12px;
    font-size: 12px;
  }
  /* Hide username text on small mobile, keep avatar visible */
  .nav-user-wrap .btn .nav-username {
    display: none;
  }
  .user-dropdown {
    min-width: 180px;
    right: 0;
    left: auto;
  }
  
  /* Dashboard menu small mobile */
  .dashboard-menu-toggle { margin-top: 24px; }
  
  /* Hero small mobile */
  .hero { padding: 20px 0 24px; }
  .hero-slider { max-height: 180px; }
  
  .hero-banners { grid-template-columns: 1fr; gap: 10px; margin-bottom: 20px; }
  .hero-banner { padding: 12px 14px; gap: 10px; }
  .hero-banner-icon { width: 38px; height: 38px; font-size: 16px; }
  .hero-banner-title { font-size: 13px; }
  .hero-banner-desc { font-size: 11px; }
  
  .search-bar { 
    padding: 12px;
    flex-direction: column;
    gap: 10px;
    border-radius: 12px;
  }
  .search-bar input { 
    padding: 12px 14px;
    border-radius: 8px;
    background: #F8FAFC;
    width: 100%;
    box-sizing: border-box;
  }
  .search-bar button { 
    width: 100%;
    border-radius: 8px;
    padding: 12px 16px;
  }
  
  .category-pills { 
    margin-top: 16px;
    gap: 4px;
  }
  .pill { 
    padding: 5px 12px; 
    font-size: 11px;
  }
  .game-logos { gap: 14px; margin-top: 16px; }
  .game-logo-img { width: 68px; height: 68px; font-size: 16px; }
  .game-logo-name { font-size: 13px; }
  
  /* Grids small mobile */
  .game-grid { 
    grid-template-columns: repeat(2, 1fr); 
    gap: 10px; 
  }
  .game-card-body { padding: 10px 12px; }
  .game-card-title { font-size: 13px; }
  .game-card-price { font-size: 15px; }
  .game-card-footer { padding: 8px 12px; }
  
  .stats-grid { 
    grid-template-columns: 1fr; 
    gap: 10px; 
  }
  .stat-card { padding: 14px; }
  
  /* Forms small mobile */
  .form-group { margin-bottom: 14px; }
  .form-control { padding: 11px 12px; }
  
  /* Buttons small mobile */
  .btn { 
    padding: 10px 16px; 
    font-size: 13px;
    min-height: 42px;
  }
  .btn-sm { 
    padding: 7px 12px; 
    font-size: 12px;
    min-height: 34px;
  }
  
  /* Cards small mobile */
  .card-body { padding: 14px; }
  .card-header { padding: 12px 14px; }
  
  /* Modals small mobile */
  .modal-overlay { padding: 12px; }
  .modal-header { padding: 16px 18px 12px; }
  .modal-body { padding: 16px 18px; }
  .modal-footer { padding: 12px 18px 16px; }
  
  /* Section small mobile */
  .section { padding: 20px 0; }
  .section-title { font-size: 17px; }
  
  
  /* Footer small mobile - keep 2 columns */
  .site-footer {
    padding: 24px 0 16px;
  }
  
  .footer-grid {
    grid-template-columns: 1fr 1fr;
    gap: 16px;
    margin-bottom: 20px;
  }
  
  .footer-col-brand {
    grid-column: 1 / -1;
    margin-bottom: 4px;
  }
  
  .footer-brand-logo {
    height: 32px;
    max-width: 100px;
  }
  
  .footer-brand-text {
    font-size: 15px;
  }
  
  .footer-description {
    font-size: 12px;
    line-height: 1.6;
    margin-bottom: 10px;
  }
  
  .footer-social {
    gap: 8px;
  }
  
  .footer-social-link {
    width: 34px;
    height: 34px;
    font-size: 16px;
  }
  
  .footer-title {
    font-size: 11px;
    margin-bottom: 8px;
  }
  
  .footer-links {
    gap: 5px;
  }
  
  .footer-links a {
    font-size: 12px;
    padding: 2px 0;
  }
  
  .footer-payment {
    padding-top: 14px;
    margin-bottom: 12px;
  }
  
  .footer-payment-label {
    font-size: 11px;
    margin-bottom: 6px;
  }
  
  .footer-payment-methods {
    gap: 8px;
  }
  
  .footer-payment-logo {
    height: 28px;
  }
  
  .footer-bottom {
    gap: 6px;
    padding-top: 12px;
  }
  
  .footer-copyright,
  .footer-security {
    font-size: 11px;
    line-height: 1.5;
  }
  
  /* Toast small mobile */
  #toast-container { 
    top: 65px; 
    right: 12px; 
    left: 12px;
  }
  
  /* Chat small mobile */
  .chat-window { height: 350px; }
  
  /* Sidebar small mobile */
  .sidebar-menu li a { 
    padding: 11px 12px; 
    font-size: 13px;
  }
  
  /* Table small mobile */
  th { padding: 8px 10px; font-size: 10px; }
  td { padding: 9px 10px; font-size: 12px; }
  
  /* Pagination small mobile */
  .page-btn { 
    min-width: 28px; 
    height: 28px;
    font-size: 12px;
  }
}

/* Extra small mobile (360px and below) */
@media (max-width: 360px) {
  .container { padding: 0 10px; }
  
  /* Navbar extra small */
  .navbar-inner { padding: 0 10px; }
  .navbar-brand span {
    display: none;
  }
  .navbar-brand {
    gap: 0;
  }
  .wallet-chip {
    max-width: 80px;
    font-size: 10px;
    padding: 4px 6px;
  }
  .wallet-chip span:first-child {
    display: none;
  }
  .notif-btn {
    width: 32px;
    height: 32px;
    font-size: 13px;
  }
  .btn-sm {
    padding: 6px 10px;
    font-size: 11px;
  }
  
  .hero-title { font-size: 18px; }
  .game-grid { gap: 8px; }
  .game-card-body { padding: 8px 10px; }
  
  .btn { padding: 9px 14px; font-size: 12px; }
  .card-body { padding: 12px; }
}

/* Landscape orientation adjustments */
@media (max-width: 768px) and (orientation: landscape) {
  .hero { padding: 24px 0 20px; }
  .hero-title { font-size: 24px; }
  .modal-overlay { align-items: center; }
  .modal { border-radius: var(--radius-lg); }
}

/* Touch device improvements */
@media (hover: none) and (pointer: coarse) {
  .btn:hover { transform: none; }
  .btn:active { transform: scale(0.98); opacity: 0.9; }
  
  .game-card:hover { transform: none; }
  .game-card:active { transform: scale(0.98); }
  
  .pill:hover { transform: none; }
  .pill:active { transform: scale(0.95); }
  
  /* Better touch targets */
  .navbar-nav a { min-height: 44px; }
  .sidebar-menu li a { min-height: 44px; }
  .pill { min-height: 32px; }
}
