/* เกมสล็อตยอดนิยม + ผู้ได้รับรางวัล (#popular) */

/* ---------- เกมสล็อตยอดนิยม + ผู้ได้รับรางวัล (#popular) ---------- */
.pop-grid { display: grid; gap: 16px; }
@media (min-width: 768px) { .pop-grid { grid-template-columns: 270px minmax(0, 1fr); align-items: start; } }
@media (min-width: 1024px) { .pop-grid { grid-template-columns: 280px minmax(0, 1fr) minmax(0, 360px); } }
.pop-left { display: flex; flex-direction: column; gap: 12px; }
.pop-title { display: flex; align-items: center; gap: 10px; margin: 0; padding: 12px 14px; border-radius: 10px; font-size: 20px; font-weight: 900; color: #fff;
  background: linear-gradient(180deg, #2b1d12, #160e0a); box-shadow: inset 0 0 0 1px rgba(255,224,138,.3), 0 10px 18px -12px #000; }
.pop-title { flex-direction: column; align-items: stretch; gap: 6px; }
.pop-title h2 { display: flex; align-items: center; gap: 10px; margin: 0; font-size: 20px; font-weight: 900; color: #fff; }
.live-badge { display: inline-flex; flex-shrink: 0; align-items: center; gap: 5px; padding: 3px 8px 3px 7px; border-radius: 6px; color: #fff; font-size: 12px; font-weight: 800; letter-spacing: .08em;
  background: linear-gradient(180deg, #ef4444, #b91c1c); box-shadow: 0 0 0 1px rgba(255,255,255,.15) inset, 0 0 14px rgba(239,68,68,.6); }
.live-badge i { width: 7px; height: 7px; border-radius: 50%; background: #fff; animation: liveDot 1.2s ease-in-out infinite; }
@keyframes liveDot { 50% { opacity: .25; transform: scale(.7); } }
.live-now { display: flex; align-items: center; gap: 8px; margin: 0; color: #d6d3d1; font-size: 13px; font-weight: 500; }
.live-now b { color: #ffe08a; font-size: 15px; font-variant-numeric: tabular-nums; }
.live-eq { display: inline-flex; align-items: flex-end; gap: 2px; height: 14px; }
.live-eq span { width: 3px; border-radius: 1px; background: #ef4444; animation: liveEq .9s ease-in-out infinite alternate; }
.live-eq span:nth-child(2) { animation-delay: -.3s; } .live-eq span:nth-child(3) { animation-delay: -.6s; } .live-eq span:nth-child(4) { animation-delay: -.15s; }
@keyframes liveEq { from { height: 3px; } to { height: 14px; } }
.pop-viewers { position: absolute; right: 6px; top: 6px; z-index: 1; display: inline-flex; align-items: center; gap: 4px; padding: 2px 7px; border-radius: 999px; color: #fff; font-size: 10.5px; font-weight: 600;
  background: rgba(0,0,0,.68); box-shadow: inset 0 0 0 1px rgba(255,255,255,.12); backdrop-filter: blur(2px); font-variant-numeric: tabular-nums; }
.pop-viewers i { width: 6px; height: 6px; border-radius: 50%; background: #ef4444; box-shadow: 0 0 6px #ef4444; animation: liveDot 1.2s ease-in-out infinite; }
.pop-game:hover .pop-viewers, .pop-game.active .pop-viewers { opacity: 0; }
.win-box { overflow: hidden; border-radius: 10px; background: linear-gradient(180deg, #1d130e, #120b09); box-shadow: inset 0 0 0 1px rgba(255,224,138,.22); }
.win-head { display: flex; align-items: center; gap: 8px; margin: 0; padding: 9px 12px; color: #ffe08a; font-size: 14px; font-weight: 700;
  background: linear-gradient(90deg, rgba(245,179,1,.18), transparent); border-bottom: 1px solid rgba(255,224,138,.15); }
.win-head img { width: 22px; height: 22px; }
.win-head .jp-live { margin-left: auto; }
.win-view { position: relative; height: 304px; overflow: hidden; -webkit-mask-image: linear-gradient(transparent, #000 14px, #000 calc(100% - 22px), transparent); mask-image: linear-gradient(transparent, #000 14px, #000 calc(100% - 22px), transparent); }
/* รายชื่อผู้ได้รางวัล: ซ้ำ 2 ชุดแล้วเลื่อนขึ้นครึ่งหนึ่ง จึงวนต่อกันไม่มีช่องว่าง */
.win-list { display: flex; flex-direction: column; margin: 0; padding: 0; list-style: none; animation: winUp var(--win-dur, 30s) linear infinite; }
.win-view:hover .win-list { animation-play-state: paused; }
@keyframes winUp { to { transform: translateY(-50%); } }
.win-item { display: flex; align-items: center; gap: 10px; padding: 8px 12px; border-bottom: 1px dashed rgba(255,224,138,.1); }
.win-item img { width: 52px; height: 52px; flex-shrink: 0; border-radius: 8px; object-fit: cover; box-shadow: 0 0 0 1px rgba(255,224,138,.35); }
.win-item p { margin: 0; min-width: 0; line-height: 1.35; }
.win-user { color: #d6d3d1; font-size: 12px; }
.win-amt { color: #fff; font-size: 13px; }
.win-amt b { color: #ffe08a; font-weight: 800; font-size: 15px; text-shadow: 0 0 8px rgba(245,179,1,.4); }
.win-game { display: block; overflow: hidden; color: #a8a29e; font-size: 11.5px; white-space: nowrap; text-overflow: ellipsis; }
.pop-banner { position: relative; display: block; overflow: hidden; border-radius: 10px; box-shadow: inset 0 0 0 1px rgba(255,224,138,.3); }
.pop-banner img { display: block; width: 100%; height: auto; transition: transform .5s ease; }
.pop-banner span { position: absolute; right: 8px; bottom: 8px; padding: 3px 10px; border-radius: 999px; color: #241500; font-size: 12px; font-weight: 700; background: linear-gradient(180deg, #f7d27a, #e9b23a); }
.pop-banner:hover img { transform: scale(1.06); }
.pop-center { min-width: 0; overflow: hidden; border-radius: 12px; background: linear-gradient(180deg, #23150f, #120a08); box-shadow: inset 0 0 0 1px rgba(255,224,138,.22), 0 16px 30px -18px #000; }
.pop-tabs-wrap { display: flex; align-items: stretch; border-bottom: 1px solid rgba(255,224,138,.18); background: rgba(0,0,0,.25); }
.pop-arrow { display: grid; flex-shrink: 0; place-items: center; width: 32px; color: #ffe08a; transition: background-color .2s; }
.pop-arrow:hover { background: rgba(245,179,1,.12); }
.pop-arrow svg { width: 18px; height: 18px; }
.pop-tabs { display: flex; flex: 1; gap: 6px; overflow-x: auto; padding: 8px 4px; scroll-behavior: smooth; }
.pop-tab { position: relative; display: grid; flex: 0 0 120px; place-items: center; height: 46px; border-radius: 8px; background: rgba(255,255,255,.03); box-shadow: inset 0 0 0 1px rgba(255,255,255,.08); transition: background-color .2s, box-shadow .2s; }
.pop-tab img { grid-area: 1 / 1; width: 104px; height: 40px; object-fit: contain; transition: opacity .2s; }
.pop-tab .pl-n { filter: grayscale(1) brightness(1.45); opacity: .75; }
.pop-tab .pl-a { opacity: 0; }
.pop-tab:hover, .pop-tab[aria-selected="true"] { background: radial-gradient(ellipse 80% 100% at 50% 100%, rgba(245,179,1,.25), transparent 70%), rgba(255,255,255,.04); box-shadow: inset 0 0 0 1.5px #e9b23a; }
.pop-tab:is(:hover, [aria-selected="true"]) .pl-n { opacity: 0; }
.pop-tab:is(:hover, [aria-selected="true"]) .pl-a { opacity: 1; }
.pop-games { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 10px; padding: 12px; }
@media (min-width: 640px) { .pop-games { gap: 14px; padding: 16px; } }
.pop-game { position: relative; overflow: hidden; aspect-ratio: 1; border-radius: 10px; background: #1a120c; box-shadow: inset 0 0 0 1px rgba(255,224,138,.25), 0 8px 14px -10px #000; animation: popIn .45s cubic-bezier(.2,.8,.2,1) both; animation-delay: calc(var(--i) * 55ms); }
@keyframes popIn { from { opacity: 0; transform: translateY(14px) scale(.94); } }
.pop-game img { width: 100%; height: 100%; object-fit: cover; transition: transform .4s ease; }
.pop-game .ov { position: absolute; inset: 0; display: flex; flex-direction: column; align-items: center; justify-content: center; gap: 6px; padding: 8px; background: rgba(12,8,6,.72); opacity: 0; transition: opacity .2s; }
.pop-game:hover .ov, .pop-game:focus-within .ov, .pop-game.active .ov { opacity: 1; }
.pop-game:hover img, .pop-game.active img { transform: scale(1.08); }
.pop-game:hover, .pop-game.active { box-shadow: 0 0 0 1.5px #ffe08a, 0 0 18px rgba(245,179,1,.3); }
.pop-right { position: relative; align-self: stretch; display: none; }
@media (min-width: 1024px) { .pop-right { display: flex; flex-direction: column; align-items: center; justify-content: center; } }
.pop-stage { position: relative; display: grid; width: 100%; place-items: center; }
.pop-stage::before { content: ""; position: absolute; left: 50%; top: 52%; width: 120%; aspect-ratio: 1; transform: translate(-50%, -50%); border-radius: 50%; background: radial-gradient(circle, rgba(245,179,1,.32), rgba(185,28,28,.14) 40%, transparent 66%); }
.pop-rays { position: absolute; left: 50%; top: 50%; width: 130%; aspect-ratio: 1; margin: 0; transform: translate(-50%, -50%); border-radius: 50%; pointer-events: none;
  background: repeating-conic-gradient(rgba(255,224,138,.12) 0 6deg, transparent 6deg 16deg); -webkit-mask-image: radial-gradient(circle, #000 18%, transparent 62%); mask-image: radial-gradient(circle, #000 18%, transparent 62%); animation: popRays 36s linear infinite; }
@keyframes popRays { to { transform: translate(-50%, -50%) rotate(1turn); } }
.pop-hero { position: relative; z-index: 1; width: 100%; max-width: 380px; height: auto; filter: drop-shadow(0 18px 20px rgba(0,0,0,.6)); animation: popFloat 4s ease-in-out infinite; }
@keyframes popFloat { 50% { transform: translateY(-8px); } }
.pop-hero.swap-l { animation: heroInL .55s cubic-bezier(.2,.8,.2,1), popFloat 4s ease-in-out .55s infinite; }
.pop-hero.swap-r { animation: heroInR .55s cubic-bezier(.2,.8,.2,1), popFloat 4s ease-in-out .55s infinite; }
@keyframes heroInL { from { opacity: 0; transform: translateX(-70px) scale(.92); } }
@keyframes heroInR { from { opacity: 0; transform: translateX(70px) scale(.92); } }
.pop-hero-name { margin: 4px 0 0; padding: 4px 16px; border-radius: 999px; color: #ffe08a; font-size: 14px; background: rgba(0,0,0,.4); box-shadow: inset 0 0 0 1px rgba(255,224,138,.3); }
/* มือถือ: เรียง หัวข้อ > เกม > ผู้ได้รางวัล > แบนเนอร์ */
@media (max-width: 767px) {
  .pop-grid { grid-template-columns: minmax(0, 1fr); }
  .pop-left { display: contents; }
  .pop-title { order: 0; } .pop-center { order: 1; } .win-box { order: 2; } .pop-banner { order: 3; }
  .win-view { height: 232px; }
  .pop-banner img { height: 110px; object-fit: cover; object-position: 30% 50%; }
}
