/*
Theme Name: Max789
Theme URI: https://max789.top
Author: Max789
Author URI: https://max789.top
Description: Theme casino gaming cho Max789 - Nổ Hũ, Game Bài, Casino, Lô Đề
Version: 1.0.0
License: GNU General Public License v2 or later
Text Domain: max789
*/

/* ============================================
   DESIGN TOKENS
   ============================================ */
:root {
  /* Brand colors từ logo */
  --purple:       #7C3AED;
  --purple-dark:  #4C1D95;
  --purple-light: #A855F7;
  --gold:         #F59E0B;
  --gold-dark:    #B45309;
  --gold-light:   #FCD34D;
  --red:          #DC2626;
  --red-dark:     #991B1B;

  /* Backgrounds */
  --bg:           #0A0612;
  --bg-2:         #110820;
  --bg-3:         #1A0D2E;
  --surface:      #1E1035;
  --surface-2:    #251445;

  /* Text */
  --text:         #F1EEF9;
  --text-muted:   #9B8EC4;
  --text-dim:     #6B5FA0;

  /* Borders */
  --border:       rgba(124,58,237,.2);
  --border-gold:  rgba(245,158,11,.25);

  /* Effects */
  --glow-purple:  0 0 40px rgba(124,58,237,.2);
  --glow-gold:    0 0 40px rgba(245,158,11,.2);

  /* Typography */
  --f-head: 'Barlow Condensed', 'Arial Narrow', sans-serif;
  --f-body: 'Be Vietnam Pro', system-ui, sans-serif;

  /* Radius */
  --r:    8px;
  --r-lg: 14px;
  --r-xl: 20px;
}

/* ============================================
   RESET & BASE
   ============================================ */
*, *::before, *::after { box-sizing: border-box; margin: 0; padding: 0; }
html { scroll-behavior: smooth; }
body {
  background: var(--bg);
  color: var(--text);
  font-family: var(--f-body);
  font-size: 15px;
  line-height: 1.65;
  overflow-x: hidden;
}
img { max-width: 100%; height: auto; display: block; }
a { color: inherit; text-decoration: none; }
ul { list-style: none; }

/* ============================================
   TYPOGRAPHY
   ============================================ */
h1, h2, h3, h4, h5 {
  font-family: var(--f-head);
  line-height: 1.1;
  font-weight: 800;
  color: var(--text);
}
h1 { font-size: clamp(36px, 6vw, 72px); }
h2 { font-size: clamp(28px, 4vw, 48px); }
h3 { font-size: clamp(20px, 3vw, 32px); }
h4 { font-size: 20px; }
p  { color: var(--text-muted); line-height: 1.75; }

/* ============================================
   LAYOUT HELPERS
   ============================================ */
.container {
  width: min(1200px, 100%);
  margin-inline: auto;
  padding-inline: 20px;
}
.section { padding-block: 72px; }
.section-sm { padding-block: 48px; }

.section-head { text-align: center; margin-bottom: 48px; }
.section-label {
  display: inline-block;
  font-size: 11px;
  font-weight: 700;
  letter-spacing: .14em;
  text-transform: uppercase;
  color: var(--gold);
  margin-bottom: 10px;
}
.section-title {
  font-family: var(--f-head);
  font-size: clamp(30px, 5vw, 52px);
  font-weight: 900;
  color: var(--text);
  text-wrap: balance;
}
.section-title .accent { color: var(--gold); }
.section-desc {
  color: var(--text-muted);
  max-width: 580px;
  margin: 14px auto 0;
  font-size: 14px;
}

/* ============================================
   BUTTONS
   ============================================ */
.btn {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  font-family: var(--f-head);
  font-weight: 800;
  letter-spacing: .06em;
  text-transform: uppercase;
  border: none;
  border-radius: var(--r);
  cursor: pointer;
  transition: filter .18s, transform .12s, box-shadow .18s;
  text-decoration: none;
}
.btn:hover { transform: translateY(-2px); }
.btn-primary {
  background: linear-gradient(135deg, var(--gold) 0%, var(--gold-dark) 100%);
  color: #0A0612;
  font-size: 16px;
  padding: 13px 32px;
  box-shadow: 0 4px 24px rgba(245,158,11,.3);
}
.btn-primary:hover { filter: brightness(1.1); box-shadow: 0 8px 40px rgba(245,158,11,.5); }
.btn-purple {
  background: linear-gradient(135deg, var(--purple) 0%, var(--purple-dark) 100%);
  color: #fff;
  font-size: 16px;
  padding: 13px 32px;
  box-shadow: 0 4px 24px rgba(124,58,237,.3);
}
.btn-purple:hover { filter: brightness(1.15); }
.btn-outline {
  background: transparent;
  color: var(--text);
  font-size: 15px;
  padding: 12px 28px;
  border: 1px solid var(--border);
}
.btn-outline:hover { border-color: var(--gold); color: var(--gold); background: rgba(245,158,11,.06); }
.btn-sm { font-size: 13px; padding: 9px 20px; }

/* ============================================
   HEADER / NAV
   ============================================ */
#masthead {
  position: fixed;
  top: 0; left: 0; right: 0;
  z-index: 999;
  background: rgba(10,6,18,.92);
  backdrop-filter: blur(16px);
  border-bottom: 1px solid var(--border);
}
.nav-wrap {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 24px;
  padding-block: 14px;
}
.site-logo {
  font-family: var(--f-head);
  font-size: 28px;
  font-weight: 900;
  letter-spacing: .02em;
  line-height: 1;
}
.site-logo .logo-max { color: var(--purple-light); }
.site-logo .logo-789 { color: var(--gold); }
.site-logo img { height: 44px; width: auto; }

.main-nav { display: flex; align-items: center; gap: 4px; }
.main-nav a {
  font-size: 13px;
  font-weight: 500;
  color: var(--text-muted);
  padding: 7px 14px;
  border-radius: var(--r);
  transition: color .15s, background .15s;
  white-space: nowrap;
}
.main-nav a:hover,
.main-nav .current-menu-item a,
.main-nav .current-menu-parent > a {
  color: var(--text);
  background: var(--surface);
}

/* Mobile menu toggle */
.nav-toggle {
  display: none;
  background: none;
  border: 1px solid var(--border);
  border-radius: var(--r);
  color: var(--text);
  padding: 8px 10px;
  cursor: pointer;
  font-size: 18px;
}

/* ============================================
   HERO (trang chủ)
   ============================================ */
.hero {
  position: relative;
  min-height: 100svh;
  display: flex;
  align-items: center;
  overflow: hidden;
  padding-top: 72px;
}
.hero-bg {
  position: absolute;
  inset: 0;
  background:
    radial-gradient(ellipse 70% 60% at 20% 50%, rgba(124,58,237,.18) 0%, transparent 60%),
    radial-gradient(ellipse 50% 70% at 80% 30%, rgba(245,158,11,.1) 0%, transparent 60%),
    linear-gradient(180deg, var(--bg) 0%, var(--bg-2) 100%);
}
.hero-grid {
  position: absolute;
  inset: 0;
  background-image:
    linear-gradient(rgba(124,58,237,.07) 1px, transparent 1px),
    linear-gradient(90deg, rgba(124,58,237,.07) 1px, transparent 1px);
  background-size: 50px 50px;
  mask-image: radial-gradient(ellipse 80% 80% at 50% 50%, black 20%, transparent 100%);
}
.hero-inner {
  position: relative;
  z-index: 1;
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 60px;
  align-items: center;
  padding-block: 80px;
}
.hero-content {}
.hero-eyebrow {
  display: inline-flex;
  align-items: center;
  gap: 10px;
  font-size: 11px;
  font-weight: 700;
  letter-spacing: .14em;
  text-transform: uppercase;
  color: var(--gold);
  margin-bottom: 20px;
}
.hero-eyebrow::before, .hero-eyebrow::after {
  content: "";
  display: block;
  width: 28px; height: 1px;
  background: var(--gold-dark);
}
.hero-title {
  font-family: var(--f-head);
  font-size: clamp(48px, 8vw, 96px);
  font-weight: 900;
  line-height: .9;
  margin-bottom: 20px;
}
.hero-title .line1 { color: var(--text); display: block; }
.hero-title .line2 { color: var(--gold); display: block; }
.hero-title .line3 { color: var(--purple-light); display: block; font-size: .6em; }
.hero-sub {
  font-size: 16px;
  color: var(--text-muted);
  margin-bottom: 36px;
  max-width: 480px;
  line-height: 1.7;
}
.hero-actions { display: flex; flex-wrap: wrap; gap: 12px; margin-bottom: 48px; }
.hero-stats {
  display: flex;
  gap: 32px;
  flex-wrap: wrap;
  padding-top: 32px;
  border-top: 1px solid var(--border);
}
.hero-stat-num {
  font-family: var(--f-head);
  font-size: 28px;
  font-weight: 900;
  color: var(--gold);
  line-height: 1;
}
.hero-stat-label { font-size: 11px; color: var(--text-dim); letter-spacing: .08em; text-transform: uppercase; margin-top: 3px; }

/* Hero visual / cards stack */
.hero-visual {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 12px;
}
.hero-game-card {
  border-radius: var(--r-lg);
  border: 1px solid var(--border);
  overflow: hidden;
  aspect-ratio: 3/4;
  position: relative;
  display: flex;
  align-items: flex-end;
  padding: 16px;
  transition: transform .2s, box-shadow .2s;
}
.hero-game-card:hover { transform: translateY(-4px); box-shadow: var(--glow-purple); }
.hero-game-card:nth-child(1) { background: linear-gradient(145deg, #1A0D35 0%, #0A0612 100%); margin-top: 24px; }
.hero-game-card:nth-child(2) { background: linear-gradient(145deg, #1A0A0A 0%, #0A0612 100%); }
.hero-game-card:nth-child(3) { background: linear-gradient(145deg, #0A1A0A 0%, #0A0612 100%); }
.hero-game-card:nth-child(4) { background: linear-gradient(145deg, #0A0A1A 0%, #0A0612 100%); margin-top: -24px; }
.hero-card-emoji { position: absolute; top: 50%; left: 50%; transform: translate(-50%,-60%); font-size: 56px; opacity: .9; }
.hero-card-name { font-family: var(--f-head); font-size: 16px; font-weight: 800; color: var(--text); position: relative; z-index: 1; }
.hero-card-badge {
  position: absolute; top: 10px; right: 10px;
  background: var(--red); color: #fff;
  font-size: 9px; font-weight: 700; letter-spacing: .08em; text-transform: uppercase;
  padding: 3px 8px; border-radius: 100px;
}

/* ============================================
   TRUST BAR
   ============================================ */
.trust-bar {
  background: var(--bg-2);
  border-top: 1px solid var(--border);
  border-bottom: 1px solid var(--border);
  padding-block: 18px;
}
.trust-list { display: flex; justify-content: center; flex-wrap: wrap; gap: 32px; }
.trust-item { display: flex; align-items: center; gap: 10px; font-size: 13px; font-weight: 500; color: var(--text-muted); }
.trust-icon {
  width: 32px; height: 32px; border-radius: 50%;
  background: rgba(124,58,237,.12);
  border: 1px solid var(--border);
  display: flex; align-items: center; justify-content: center;
  font-size: 15px; flex-shrink: 0;
}

/* ============================================
   CATEGORY SECTION
   ============================================ */
.cat-grid {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 16px;
}
.cat-card {
  border-radius: var(--r-xl);
  border: 1px solid var(--border);
  overflow: hidden;
  position: relative;
  aspect-ratio: 3/4;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: flex-end;
  padding: 24px 20px;
  text-align: center;
  cursor: pointer;
  transition: transform .2s, box-shadow .2s, border-color .2s;
  text-decoration: none;
}
.cat-card:hover { transform: translateY(-6px); box-shadow: 0 20px 60px rgba(0,0,0,.4); border-color: var(--gold-dark); }
.cat-no-hu  { background: linear-gradient(160deg, #1A0D35 0%, #2D1B69 50%, #0A0612 100%); }
.cat-game-bai { background: linear-gradient(160deg, #1A0A0A 0%, #3B0F0F 50%, #0A0612 100%); }
.cat-casino { background: linear-gradient(160deg, #0A1A0A 0%, #0F3B0F 50%, #0A0612 100%); }
.cat-lo-de  { background: linear-gradient(160deg, #0A0A1A 0%, #0F0F3B 50%, #0A0612 100%); }

.cat-emoji { font-size: 64px; margin-bottom: 12px; position: relative; z-index: 1; filter: drop-shadow(0 4px 12px rgba(0,0,0,.5)); }
.cat-glow {
  position: absolute;
  width: 200px; height: 200px;
  border-radius: 50%;
  top: 20%; left: 50%; transform: translateX(-50%);
  opacity: .25;
  filter: blur(40px);
  pointer-events: none;
}
.cat-no-hu .cat-glow   { background: var(--purple-light); }
.cat-game-bai .cat-glow { background: var(--red); }
.cat-casino .cat-glow  { background: #22c55e; }
.cat-lo-de .cat-glow   { background: #3b82f6; }

.cat-name { font-family: var(--f-head); font-size: 22px; font-weight: 900; color: var(--text); position: relative; z-index: 1; margin-bottom: 6px; }
.cat-count { font-size: 12px; color: var(--text-muted); position: relative; z-index: 1; }
.cat-arrow {
  position: absolute; bottom: 20px; right: 20px;
  width: 32px; height: 32px; border-radius: 50%;
  background: rgba(245,158,11,.15);
  border: 1px solid var(--border-gold);
  display: flex; align-items: center; justify-content: center;
  color: var(--gold); font-size: 14px;
  transition: background .15s;
  z-index: 1;
}
.cat-card:hover .cat-arrow { background: var(--gold); color: #000; }

/* ============================================
   POSTS GRID (trang chủ — bài mới nhất)
   ============================================ */
.posts-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 20px;
}
.post-card {
  border-radius: var(--r-lg);
  border: 1px solid var(--border);
  background: var(--bg-3);
  overflow: hidden;
  transition: border-color .2s, box-shadow .2s, transform .2s;
  display: flex;
  flex-direction: column;
}
.post-card:hover { border-color: rgba(124,58,237,.4); box-shadow: var(--glow-purple); transform: translateY(-3px); }
.post-thumbnail {
  aspect-ratio: 16/9;
  overflow: hidden;
  position: relative;
  background: var(--surface);
  display: flex; align-items: center; justify-content: center;
}
.post-thumb-placeholder {
  width: 100%; height: 100%;
  display: flex; flex-direction: column; align-items: center; justify-content: center;
  gap: 8px;
  font-size: 48px;
}
.post-thumb-placeholder .thumb-label {
  font-family: var(--f-head);
  font-size: 11px;
  font-weight: 700;
  letter-spacing: .1em;
  text-transform: uppercase;
  color: var(--text-muted);
}
.post-thumbnail img { width: 100%; height: 100%; object-fit: cover; transition: transform .4s; }
.post-card:hover .post-thumbnail img { transform: scale(1.05); }

.post-cat-badge {
  position: absolute; top: 12px; left: 12px;
  font-size: 10px; font-weight: 700; letter-spacing: .08em; text-transform: uppercase;
  padding: 4px 10px; border-radius: 100px;
  backdrop-filter: blur(8px);
}
.badge-no-hu   { background: rgba(124,58,237,.8); color: #fff; }
.badge-game-bai { background: rgba(220,38,38,.8); color: #fff; }
.badge-casino  { background: rgba(34,197,94,.8); color: #000; }
.badge-lo-de   { background: rgba(59,130,246,.8); color: #fff; }

.post-body { padding: 20px; flex: 1; display: flex; flex-direction: column; }
.post-meta { display: flex; align-items: center; gap: 12px; font-size: 12px; color: var(--text-dim); margin-bottom: 10px; }
.post-title {
  font-family: var(--f-head);
  font-size: 18px;
  font-weight: 800;
  color: var(--text);
  line-height: 1.25;
  margin-bottom: 10px;
  display: -webkit-box;
  -webkit-line-clamp: 2;
  -webkit-box-orient: vertical;
  overflow: hidden;
  transition: color .15s;
}
.post-card:hover .post-title { color: var(--gold); }
.post-excerpt { font-size: 13.5px; color: var(--text-muted); line-height: 1.65; flex: 1; display: -webkit-box; -webkit-line-clamp: 3; -webkit-box-orient: vertical; overflow: hidden; }
.post-footer { margin-top: 16px; padding-top: 14px; border-top: 1px solid var(--border); display: flex; justify-content: space-between; align-items: center; }
.post-read-more { font-size: 12px; font-weight: 600; color: var(--gold); letter-spacing: .06em; text-transform: uppercase; }

/* ============================================
   FEATURED POST (bài nổi bật — 1 bài lớn)
   ============================================ */
.featured-posts { display: grid; grid-template-columns: 2fr 1fr; gap: 20px; }
.featured-main {
  border-radius: var(--r-xl);
  border: 1px solid var(--border);
  overflow: hidden;
  position: relative;
  min-height: 420px;
  display: flex; align-items: flex-end;
  background: var(--bg-3);
  transition: box-shadow .2s;
}
.featured-main:hover { box-shadow: 0 20px 60px rgba(124,58,237,.2); }
.featured-main-bg {
  position: absolute; inset: 0;
  background: linear-gradient(to top, rgba(10,6,18,.95) 30%, rgba(10,6,18,.3) 100%);
  z-index: 1;
}
.featured-main-emoji { position: absolute; top: 50%; left: 50%; transform: translate(-50%,-60%); font-size: 100px; opacity: .3; }
.featured-main-content { position: relative; z-index: 2; padding: 28px; }
.featured-main .post-title { font-size: clamp(22px, 3vw, 32px); -webkit-line-clamp: 3; }
.featured-main .post-excerpt { -webkit-line-clamp: 2; }

.featured-side { display: flex; flex-direction: column; gap: 12px; }
.featured-side .post-card .post-thumbnail { aspect-ratio: 16/7; }

/* ============================================
   PROMOTIONS STRIP
   ============================================ */
.promo-strip {
  background: linear-gradient(135deg, var(--purple-dark) 0%, var(--bg-2) 50%, var(--bg-3) 100%);
  border-top: 1px solid var(--border);
  border-bottom: 1px solid var(--border);
  padding-block: 48px;
}
.promo-cards { display: grid; grid-template-columns: 2fr 1fr 1fr; gap: 16px; margin-top: 40px; }
.promo-card {
  border-radius: var(--r-lg);
  border: 1px solid var(--border-gold);
  background: rgba(245,158,11,.05);
  padding: 24px;
  position: relative;
  overflow: hidden;
  transition: box-shadow .2s;
}
.promo-card:hover { box-shadow: var(--glow-gold); }
.promo-tag { display: inline-block; font-size: 10px; font-weight: 700; letter-spacing: .1em; text-transform: uppercase; color: var(--gold); border: 1px solid var(--gold-dark); padding: 3px 10px; border-radius: 100px; margin-bottom: 12px; }
.promo-big { font-family: var(--f-head); font-size: clamp(44px,6vw,72px); font-weight: 900; color: var(--gold); line-height: 1; }
.promo-desc { font-size: 13.5px; color: var(--text-muted); margin-top: 8px; line-height: 1.6; }
.promo-cta { display: inline-block; margin-top: 16px; font-family: var(--f-head); font-size: 13px; font-weight: 800; letter-spacing: .08em; text-transform: uppercase; color: var(--gold); border-bottom: 1px solid var(--gold-dark); padding-bottom: 1px; }

/* ============================================
   CTA BAND
   ============================================ */
.cta-band {
  text-align: center;
  padding-block: 80px;
  background: radial-gradient(ellipse 60% 80% at 50% 50%, rgba(124,58,237,.12) 0%, transparent 70%);
  border-top: 1px solid var(--border);
}
.cta-band h2 { margin-bottom: 16px; }
.cta-band p { margin-bottom: 32px; max-width: 440px; margin-inline: auto; }
.cta-actions { display: flex; gap: 12px; justify-content: center; flex-wrap: wrap; }

/* ============================================
   FOOTER
   ============================================ */
#colophon {
  background: var(--bg);
  border-top: 1px solid var(--border);
  padding-top: 56px;
}
.footer-top {
  display: grid;
  grid-template-columns: 2fr 1fr 1fr 1fr;
  gap: 48px;
  padding-bottom: 48px;
}
.footer-brand .site-logo { display: block; margin-bottom: 16px; }
.footer-brand p { font-size: 13px; color: var(--text-muted); line-height: 1.7; max-width: 280px; }
.footer-social { display: flex; gap: 10px; margin-top: 20px; }
.footer-social a {
  width: 36px; height: 36px; border-radius: 50%;
  background: var(--surface);
  border: 1px solid var(--border);
  display: flex; align-items: center; justify-content: center;
  font-size: 16px;
  transition: background .15s, border-color .15s;
}
.footer-social a:hover { background: var(--purple); border-color: var(--purple); }

.footer-col h4 {
  font-family: var(--f-head);
  font-size: 13px;
  font-weight: 800;
  letter-spacing: .1em;
  text-transform: uppercase;
  color: var(--text);
  margin-bottom: 18px;
}
.footer-col ul { display: flex; flex-direction: column; gap: 10px; }
.footer-col a { font-size: 13px; color: var(--text-muted); transition: color .15s; }
.footer-col a:hover { color: var(--gold); }

.footer-trust {
  display: flex;
  justify-content: center;
  flex-wrap: wrap;
  gap: 20px;
  padding-block: 20px;
  border-top: 1px solid var(--border);
  border-bottom: 1px solid var(--border);
}
.footer-trust span { font-size: 12px; color: var(--text-dim); }

.footer-bottom {
  display: flex;
  justify-content: space-between;
  align-items: center;
  flex-wrap: wrap;
  gap: 12px;
  padding-block: 20px;
  font-size: 12px;
  color: var(--text-dim);
}

/* ============================================
   ARCHIVE PAGE
   ============================================ */
.archive-hero {
  padding: 100px 0 48px;
  text-align: center;
  background: radial-gradient(ellipse 60% 60% at 50% 0%, rgba(124,58,237,.15) 0%, transparent 70%);
  border-bottom: 1px solid var(--border);
}
.archive-hero h1 { margin-bottom: 12px; }
.archive-emoji-big { font-size: 72px; margin-bottom: 20px; display: block; }

.archive-layout {
  display: grid;
  grid-template-columns: 1fr 320px;
  gap: 32px;
  padding-block: 48px;
}
.archive-posts { display: grid; grid-template-columns: 1fr 1fr; gap: 20px; align-content: start; }

/* ============================================
   SINGLE POST
   ============================================ */
.single-layout {
  display: grid;
  grid-template-columns: 1fr 320px;
  gap: 32px;
  padding-block: 48px;
}
.single-hero {
  padding-top: 90px;
  padding-bottom: 40px;
  border-bottom: 1px solid var(--border);
  margin-bottom: 0;
}
.single-hero .post-cat-badge { position: static; display: inline-block; margin-bottom: 16px; }
.single-hero h1 { margin-bottom: 16px; }
.single-meta { display: flex; gap: 20px; font-size: 13px; color: var(--text-dim); flex-wrap: wrap; }

.single-content {
  font-size: 15px;
  line-height: 1.8;
  color: var(--text-muted);
  padding-top: 32px;
}
.single-content h2 { font-size: 26px; color: var(--text); margin: 36px 0 14px; padding-bottom: 10px; border-bottom: 1px solid var(--border); }
.single-content h3 { font-size: 20px; color: var(--text); margin: 28px 0 12px; }
.single-content p { margin-bottom: 18px; }
.single-content ul, .single-content ol { padding-left: 24px; margin-bottom: 18px; }
.single-content li { margin-bottom: 8px; color: var(--text-muted); }
.single-content strong { color: var(--text); }
.single-content a { color: var(--gold); text-decoration: underline; }
.single-content blockquote {
  border-left: 3px solid var(--purple);
  background: var(--bg-3);
  padding: 16px 20px;
  border-radius: 0 var(--r) var(--r) 0;
  margin: 24px 0;
  font-style: italic;
}
.single-content table { width: 100%; border-collapse: collapse; margin: 24px 0; }
.single-content th { background: var(--surface); color: var(--text); padding: 12px 16px; text-align: left; font-family: var(--f-head); font-size: 13px; letter-spacing: .05em; text-transform: uppercase; }
.single-content td { padding: 12px 16px; border-bottom: 1px solid var(--border); color: var(--text-muted); }

/* ============================================
   SIDEBAR
   ============================================ */
.sidebar { display: flex; flex-direction: column; gap: 24px; }
.widget {
  border-radius: var(--r-lg);
  border: 1px solid var(--border);
  background: var(--bg-3);
  overflow: hidden;
}
.widget-title {
  font-family: var(--f-head);
  font-size: 14px;
  font-weight: 800;
  letter-spacing: .1em;
  text-transform: uppercase;
  color: var(--text);
  padding: 16px 20px;
  border-bottom: 1px solid var(--border);
  background: var(--surface);
}
.widget-body { padding: 16px 20px; }

/* Widget: danh mục */
.widget-cats ul { display: flex; flex-direction: column; gap: 2px; }
.widget-cats a {
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding: 10px 12px;
  border-radius: var(--r);
  font-size: 13.5px;
  color: var(--text-muted);
  transition: background .15s, color .15s;
}
.widget-cats a:hover { background: var(--surface); color: var(--text); }
.widget-cats .cat-count-badge { font-size: 11px; background: var(--surface); padding: 2px 8px; border-radius: 100px; color: var(--text-dim); }

/* Widget: bài mới */
.widget-recent li { padding-block: 10px; border-bottom: 1px solid var(--border); }
.widget-recent li:last-child { border-bottom: none; }
.widget-recent a { font-size: 13px; color: var(--text-muted); line-height: 1.4; display: block; transition: color .15s; }
.widget-recent a:hover { color: var(--gold); }
.widget-recent .post-date { font-size: 11px; color: var(--text-dim); margin-top: 4px; }

/* Widget: banner CTA */
.widget-cta {
  text-align: center;
  padding: 24px 20px;
  background: linear-gradient(145deg, var(--purple-dark), var(--bg-3));
}
.widget-cta .cta-big { font-family: var(--f-head); font-size: 40px; font-weight: 900; color: var(--gold); line-height: 1; margin-bottom: 8px; }
.widget-cta p { font-size: 13px; color: var(--text-muted); margin-bottom: 16px; }

/* ============================================
   PAGINATION
   ============================================ */
.pagination { display: flex; gap: 6px; justify-content: center; padding-block: 40px; flex-wrap: wrap; }
.pagination a, .pagination span {
  display: flex; align-items: center; justify-content: center;
  width: 40px; height: 40px;
  border-radius: var(--r);
  font-family: var(--f-head);
  font-size: 15px;
  font-weight: 700;
  border: 1px solid var(--border);
  color: var(--text-muted);
  transition: background .15s, color .15s, border-color .15s;
}
.pagination a:hover { background: var(--surface); color: var(--text); }
.pagination .current { background: var(--purple); color: #fff; border-color: var(--purple); }

/* ============================================
   BREADCRUMB
   ============================================ */
.breadcrumb { font-size: 12px; color: var(--text-dim); padding-block: 12px; display: flex; gap: 6px; align-items: center; flex-wrap: wrap; }
.breadcrumb a { color: var(--text-dim); transition: color .15s; }
.breadcrumb a:hover { color: var(--gold); }
.breadcrumb .sep { opacity: .4; }
.breadcrumb .current-item { color: var(--text-muted); }

/* ============================================
   RELATED POSTS
   ============================================ */
.related-posts { padding-block: 48px; border-top: 1px solid var(--border); }
.related-posts h3 { margin-bottom: 24px; }
.related-grid { display: grid; grid-template-columns: repeat(3,1fr); gap: 16px; }

/* ============================================
   MOBILE MENU (overlay)
   ============================================ */
.mobile-menu {
  display: none;
  position: fixed;
  inset: 0;
  z-index: 998;
  background: rgba(10,6,18,.97);
  backdrop-filter: blur(20px);
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: 8px;
}
.mobile-menu.open { display: flex; }
.mobile-menu a {
  font-family: var(--f-head);
  font-size: 28px;
  font-weight: 800;
  color: var(--text-muted);
  letter-spacing: .02em;
  transition: color .15s;
  padding: 8px 24px;
}
.mobile-menu a:hover { color: var(--gold); }
.mobile-menu-close {
  position: absolute; top: 20px; right: 20px;
  background: none; border: 1px solid var(--border);
  color: var(--text); border-radius: var(--r);
  padding: 8px 12px; cursor: pointer; font-size: 20px;
}

/* ============================================
   RESPONSIVE
   ============================================ */
@media (max-width: 1024px) {
  .hero-inner { grid-template-columns: 1fr; gap: 40px; }
  .hero-visual { grid-template-columns: repeat(4,1fr); }
  .hero-game-card:nth-child(1),
  .hero-game-card:nth-child(4) { margin-top: 0; }
  .cat-grid { grid-template-columns: repeat(2,1fr); }
  .posts-grid { grid-template-columns: repeat(2,1fr); }
  .footer-top { grid-template-columns: 1fr 1fr; gap: 32px; }
  .archive-layout,
  .single-layout { grid-template-columns: 1fr; }
  .sidebar { display: grid; grid-template-columns: 1fr 1fr; }
  .promo-cards { grid-template-columns: 1fr; }
  .featured-posts { grid-template-columns: 1fr; }
  .related-grid { grid-template-columns: 1fr 1fr; }
}
@media (max-width: 640px) {
  .nav-toggle { display: flex; }
  .main-nav { display: none; }
  .hero-visual { grid-template-columns: 1fr 1fr; }
  .hero-game-card { aspect-ratio: 1; }
  .cat-grid { grid-template-columns: 1fr 1fr; }
  .cat-card { aspect-ratio: 1; }
  .posts-grid { grid-template-columns: 1fr; }
  .footer-top { grid-template-columns: 1fr; }
  .sidebar { grid-template-columns: 1fr; }
  .archive-posts { grid-template-columns: 1fr; }
  .related-grid { grid-template-columns: 1fr; }
}
@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after { animation: none !important; transition: none !important; }
}
