/* ═══ FeedPlay — Light Game Portal (inspired by html5games.com) ═══ */
:root {
  --bg: #f5f6fa;
  --white: #ffffff;
  --card: #ffffff;
  --card-h: #f0f2f8;
  --border: #e2e6ee;
  --text: #1a1d26;
  --text2: #6b7280;
  --accent: #f97316;
  --accent-h: #ea580c;
  --nav-bg: #1e293b;
  --nav-text: #e2e8f0;
  --green: #10b981;
  --blue: #3b82f6;
  --purple: #8b5cf6;
  --hot: #ef4444;
  --radius: 12px;
  --radius-sm: 8px;
  --shadow: 0 1px 3px rgba(0,0,0,.06), 0 1px 2px rgba(0,0,0,.04);
  --shadow-h: 0 4px 16px rgba(0,0,0,.1);
}
*, *::before, *::after { box-sizing: border-box; margin: 0; padding: 0; }

/* ── Global scrollbar hide ── */
::-webkit-scrollbar { display: none; width: 0; height: 0; }
* { scrollbar-width: none; -ms-overflow-style: none; }

html { scroll-behavior: smooth; -webkit-text-size-adjust: 100%; }
body { font-family: -apple-system,BlinkMacSystemFont,"Segoe UI",Inter,"Noto Sans SC",Roboto,sans-serif; background: var(--bg); color: var(--text); line-height: 1.5; min-height: 100vh; overflow-x: hidden; }

/* ── Top Nav Bar ── */
.top-nav { background: var(--nav-bg); position: sticky; top: 0; z-index: 100; }
.nav-in { max-width: 1240px; margin: 0 auto; display: flex; align-items: center; height: 52px; padding: 0 24px; gap: 6px; }
.nav-logo { display: flex; align-items: center; gap: 8px; color: #fff; text-decoration: none; font-size: 18px; font-weight: 700; margin-right: 16px; flex-shrink: 0; }
.nav-logo-ic { font-size: 22px; }
.nav-links { display: flex; gap: 4px; overflow-x: auto; scrollbar-width: none; -ms-overflow-style: none; flex: 1; }
.nav-links::-webkit-scrollbar { display: none; }
.nav-link { flex: 0 0 auto; padding: 7px 13px; color: var(--nav-text); text-decoration: none; font-size: 13px; font-weight: 600; border-radius: 6px; white-space: nowrap; transition: .18s; cursor: pointer; background: none; border: none; }
.nav-link:hover, .nav-link.active { background: rgba(255,255,255,.12); color: #fff; }
.nav-link.new-badge::after { content: "new"; display: inline-block; background: var(--accent); color: #fff; font-size: 9px; font-weight: 700; padding: 1px 6px; border-radius: 3px; margin-left: 4px; text-transform: uppercase; }
.nav-more { display: none; }
.nav-hamburger { display: none; background: none; border: none; color: #fff; font-size: 22px; cursor: pointer; padding: 4px 8px; }

/* ── Mobile Nav Overlay ── */
.mobile-nav-overlay { display: none; position: fixed; inset: 0; z-index: 200; background: rgba(0,0,0,.4); }
.mobile-nav-panel { position: fixed; top: 0; left: 0; bottom: 0; width: 80%; max-width: 320px; background: var(--white); z-index: 210; overflow-y: auto; padding: 20px; box-shadow: 2px 0 16px rgba(0,0,0,.15); transform: translateX(-100%); transition: transform .25s ease; }
.mobile-nav-panel.open { transform: translateX(0); }
.mnv-close { display: block; margin-left: auto; background: none; border: none; font-size: 22px; cursor: pointer; color: var(--text); margin-bottom: 12px; }
.mnv-link { display: block; padding: 14px 12px; color: var(--text); text-decoration: none; font-size: 15px; font-weight: 600; border-radius: 8px; transition: .15s; cursor: pointer; background: none; border: none; width: 100%; text-align: left; }
.mnv-link:hover, .mnv-link.active { background: #f3f4f6; color: var(--accent); }

/* ── Hero ── */
.hero { max-width: 1240px; margin: 28px auto 0; padding: 0 24px; }
.hero-card { display: flex; background: #fff; border-radius: 16px; overflow: hidden; box-shadow: var(--shadow); border: 1px solid var(--border); }
.hero-img { width: 48%; min-height: 280px; background: #e8ecf4; position: relative; overflow: hidden; }
.hero-img img { width: 100%; height: 100%; object-fit: cover; position: absolute; inset: 0; }
.hero-body { flex: 1; padding: 36px 32px; display: flex; flex-direction: column; justify-content: center; gap: 14px; }
.hero-tag { display: inline-flex; align-items: center; gap: 6px; font-size: 12px; font-weight: 700; color: var(--accent); text-transform: uppercase; letter-spacing: .5px; }
.hero-tag::before { content: ""; width: 6px; height: 6px; background: var(--accent); border-radius: 50%; animation: pulse 2s infinite; }
@keyframes pulse { 0%,100% { opacity: 1; } 50% { opacity: .3; } }
.hero-title { font-size: clamp(22px,3.5vw,32px); font-weight: 800; line-height: 1.2; }
.hero-desc { font-size: 15px; color: var(--text2); line-height: 1.6; display: -webkit-box; -webkit-line-clamp: 3; -webkit-box-orient: vertical; overflow: hidden; }
.hero-btn { display: inline-flex; align-items: center; gap: 8px; padding: 13px 28px; background: var(--accent); color: #fff; border: none; border-radius: 8px; font-size: 15px; font-weight: 700; cursor: pointer; text-decoration: none; transition: .2s; width: fit-content; }
.hero-btn:hover { background: var(--accent-h); transform: translateY(-1px); box-shadow: 0 4px 12px rgba(249,115,22,.35); }

/* ── Section ── */
.sec { max-width: 1240px; margin: 0 auto; padding: 36px 24px; }
.sec-hd { display: flex; align-items: baseline; justify-content: space-between; margin-bottom: 20px; }
.sec-hd h2 { font-size: 22px; font-weight: 800; }
.sec-hd a, .sec-hd .show-all { font-size: 14px; font-weight: 600; color: var(--accent); text-decoration: none; cursor: pointer; background: none; border: none; }
.sec-hd a:hover, .sec-hd .show-all:hover { color: var(--accent-h); }

/* ── Game Grid ── */
.grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(185px, 1fr)); gap: 18px; }
.gc { background: var(--card); border: 1px solid var(--border); border-radius: var(--radius); overflow: hidden; text-decoration: none; color: var(--text); transition: .2s; cursor: pointer; }
.gc:hover { transform: translateY(-3px); box-shadow: var(--shadow-h); border-color: #d1d5db; }
.gc-thumb { width: 100%; aspect-ratio: 16/11; overflow: hidden; background: #e8ecf4; position: relative; }
.gc-thumb img { width: 100%; height: 100%; object-fit: cover; transition: transform .35s; }
.gc:hover .gc-thumb img { transform: scale(1.05); }
.gc-tag { position: absolute; top: 8px; left: 8px; background: var(--accent); color: #fff; font-size: 10px; font-weight: 700; padding: 3px 8px; border-radius: 4px; text-transform: uppercase; }
.gc-info { padding: 12px 14px 14px; }
.gc-name { font-size: 14px; font-weight: 700; line-height: 1.35; display: -webkit-box; -webkit-line-clamp: 2; -webkit-box-orient: vertical; overflow: hidden; }
.gc-cat { font-size: 12px; color: var(--text2); margin-top: 5px; }

/* ── Ad ── */
.ad-w { display: flex; justify-content: center; padding: 12px 0 0; }

/* ── Info Cards Row ── */
.info-cards { max-width: 1240px; margin: 0 auto; padding: 0 24px 36px; display: grid; grid-template-columns: repeat(3, 1fr); gap: 18px; }
.info-card { background: #fff; border: 1px solid var(--border); border-radius: var(--radius); padding: 24px; text-decoration: none; color: var(--text); transition: .2s; }
.info-card:hover { box-shadow: var(--shadow-h); transform: translateY(-3px); }
.info-card .ic-icon { width: 44px; height: 44px; border-radius: 10px; display: flex; align-items: center; justify-content: center; font-size: 22px; margin-bottom: 12px; }
.ic-blue { background: #eff6ff; color: var(--blue); }
.ic-green { background: #ecfdf5; color: var(--green); }
.ic-purple { background: #f5f3ff; color: var(--purple); }
.info-card h3 { font-size: 16px; font-weight: 700; margin-bottom: 6px; }
.info-card p { font-size: 14px; color: var(--text2); line-height: 1.5; }

/* ── Load More ── */
.lm { display: flex; justify-content: center; margin-top: 24px; }
.lm-btn { padding: 12px 36px; background: #fff; color: var(--accent); border: 2px solid var(--accent); border-radius: 8px; font-size: 15px; font-weight: 700; cursor: pointer; transition: .2s; }
.lm-btn:hover { background: var(--accent); color: #fff; }

/* ── Footer ── */
.ft { background: var(--nav-bg); padding: 36px 24px; margin-top: 12px; }
.ft-in { max-width: 1240px; margin: 0 auto; display: flex; flex-direction: column; gap: 14px; align-items: center; }
.ft-brand { color: #fff; font-size: 17px; font-weight: 700; }
.ft-links { display: flex; gap: 22px; flex-wrap: wrap; justify-content: center; }
.ft-links a { color: #94a3b8; text-decoration: none; font-size: 14px; transition: .2s; }
.ft-links a:hover { color: #fff; }
.ft-copy { color: #64748b; font-size: 13px; }

/* ── Game Page ── */
.game-main { max-width: 960px; margin: 0 auto; padding: 24px 24px 40px; }
.bc { font-size: 13px; color: var(--text2); margin-bottom: 12px; }
.bc a { color: var(--text2); text-decoration: none; }
.bc a:hover { color: var(--accent); }
.g-title { font-size: clamp(22px,4vw,30px); font-weight: 800; margin-bottom: 8px; }
.g-meta { font-size: 14px; color: var(--text2); margin-bottom: 18px; display: flex; gap: 16px; flex-wrap: wrap; }
.g-meta b { color: var(--text); font-weight: 600; }
.iframe-w { position: relative; width: 100%; aspect-ratio: 16/9; background: #000; border-radius: var(--radius); overflow: hidden; border: 1px solid var(--border); }
.iframe-w iframe { position: absolute; inset: 0; width: 100%; height: 100%; border: 0; }
.ad-slot-sm { display: flex; justify-content: center; margin: 24px 0; }
.rel-section { margin-top: 32px; }
.sec-title { font-size: 19px; font-weight: 800; margin-bottom: 14px; }
.strip { display: grid; grid-template-columns: repeat(auto-fill, minmax(140px, 1fr)); gap: 14px; }
.rel-card { background: #fff; border: 1px solid var(--border); border-radius: var(--radius-sm); overflow: hidden; text-decoration: none; color: var(--text); transition: .2s; }
.rel-card:hover { box-shadow: var(--shadow-h); transform: translateY(-3px); }
.rel-card img { width: 100%; aspect-ratio: 16/11; object-fit: cover; background: #e8ecf4; }
.rel-card span { display: block; padding: 9px 11px; font-size: 13px; font-weight: 600; }

/* ── Category Page ── */
.cat-main { max-width: 1240px; margin: 0 auto; padding: 28px 24px 40px; }
.page-title { font-size: 28px; font-weight: 800; margin-bottom: 24px; }
.cat-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(160px, 1fr)); gap: 16px; }
.cat-card { display: flex; flex-direction: column; align-items: center; gap: 10px; padding: 28px 16px; background: #fff; border: 1px solid var(--border); border-radius: var(--radius); text-decoration: none; color: var(--text); transition: .2s; }
.cat-card:hover { box-shadow: var(--shadow-h); transform: translateY(-4px); }
.cat-card .cat-emoji { font-size: 32px; }
.cat-card .cat-name { font-size: 15px; font-weight: 700; }
.cat-card .cat-num { font-size: 12px; color: var(--text2); }

/* ═══ MOBILE ═══ */
@media (max-width: 768px) {
  .nav-hamburger { display: block; }
  .nav-links { display: none; }
  .mobile-nav-overlay.show { display: block; }
  .nav-in { padding: 0 16px; height: 50px; }
  .hero { padding: 0 16px; margin-top: 18px; }
  .hero-card { flex-direction: column; }
  .hero-img { width: 100%; min-height: 200px; }
  .hero-body { padding: 24px 20px; gap: 10px; }
  .hero-desc { display: none; }
  .hero-btn { padding: 12px 24px; font-size: 14px; }
  .sec { padding: 24px 16px; }
  .sec-hd h2 { font-size: 19px; }
  .grid { grid-template-columns: repeat(2, 1fr); gap: 12px; }
  .gc-info { padding: 10px 10px 12px; }
  .gc-name { font-size: 13px; }
  .info-cards { grid-template-columns: 1fr; padding: 0 16px 24px; gap: 12px; }
  .game-main { padding: 16px 16px 40px; }
  .cat-main { padding: 20px 16px 40px; }
  .cat-grid { grid-template-columns: repeat(2, 1fr); gap: 12px; }
  .ft { padding: 28px 16px; }
}
@media (max-width: 380px) {
  .grid { gap: 10px; }
  .hero-img { min-height: 160px; }
  .hero-title { font-size: 20px; }
}

/* ── Anchor Ad (bottom sticky) ── */
.gpt-anchor { position: fixed; bottom: 0; left: 0; right: 0; z-index: 999; display: flex; justify-content: center; background: rgba(0,0,0,0.6); padding: 4px 0; }
.gpt-anchor-inner { min-width: 320px; min-height: 50px; width: 320px; height: 50px; }

/* ── Interstitial Ad ── */
.gpt-interstitial { position: fixed; inset: 0; z-index: 1000; background: rgba(0,0,0,0.85); display: none; align-items: center; justify-content: center; }
.gpt-interstitial-inner { min-width: 300px; min-height: 250px; width: 300px; height: 250px; }
.gpt-interstitial-close { position: absolute; top: 16px; right: 16px; background: #fff; border: none; border-radius: 50%; width: 36px; height: 36px; font-size: 18px; cursor: pointer; z-index: 1001; }
