:root {
  --page-bg: #262833;
  --surface: #2f3341;
  --text-main: #ffffff;
  --text-sub: #c8cfde;
  --hot-tag: #ff4757;
  --radius-lg: 16px;
  --radius-md: 12px;
  --shadow: 0 10px 24px rgba(8, 10, 20, 0.35);
}

* { box-sizing: border-box; }

body {
  margin: 0;
  background: var(--page-bg);
  color: var(--text-main);
  font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, Arial, sans-serif;
}

.main-content {
  max-width: 420px;
  margin: 0 auto;
  padding: 50px 15px 16px;
  
}

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

.mobile-ad-container {
  display: flex;
  align-items: center;
  width: 100%;
  height: 250px;
  border-radius: 10px;
  overflow: hidden;
}

.ad-center {
  position: relative;
  width: 300px;
  height: 250px;
  flex-shrink: 0;
}

.ad-side-mark {
  flex: 1;
  height: 100%;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 12px;
  font-weight: 700;
  letter-spacing: 0.08em;
  color: #9ca3af;
  writing-mode: vertical-rl;
  text-orientation: mixed;
  white-space: nowrap;
}

.bottom-ad-content {
  position: fixed;
  bottom: 0;
  left: 50%;
  transform: translateX(-50%);
  z-index: 1000;
  width: 320px;
  height: 100px;
  overflow: hidden;
}

.ad-fallback {
  position: absolute;
  inset: 0;
  display: none;
  z-index: 2;
}

.ad-fallback img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  display: block;
}

.ad-fallback.is-visible {
  display: block;
}

.ad-fallback-bottom img {
  object-fit: contain;
  background: #fff;
}

.ad-placeholder {
  width: 100%;
  min-height: 66px;
  border-radius: 8px;
  border: 1px dashed #9ca3af;
  color: #6b7280;
  background: #f3f4f6;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 12px;
  text-align: center;
}

.featured-card {
  position: relative;
  border-radius: var(--radius-lg);
  overflow: hidden;
  box-shadow: var(--shadow);
}

.featured-media {
  position: relative;
  width: 100%;
  aspect-ratio: 1;
  background: #1f2330;
}

.featured-cover {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  object-fit: cover;
  display: block;
  background: #22b8cf;
  opacity: 1;
  transition: opacity 0.25s ease;
}

.featured-cover.is-hidden {
  opacity: 0;
}

.featured-video {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  object-fit: cover;
  display: block;
  opacity: 0;
  transition: opacity 0.25s ease;
}

.featured-video.is-ready {
  opacity: 1;
}

.featured-play-btn {
  position: absolute;
  top: 50%;
  left: 50%;
  transform: translate(-50%, -50%);
  z-index: 3;
  width: 72px;
  height: 72px;
  border: 0;
  background: transparent;
  padding: 0;
  cursor: pointer;
  transition: opacity 0.2s ease;
}

.featured-play-btn img {
  width: 100%;
  height: 100%;
  object-fit: contain;
  display: block;
}

.featured-play-btn.is-hidden {
  opacity: 0;
  pointer-events: none;
}

.featured-popular-badge {
  position: absolute;
  top: 10px;
  left: 10px;
  width: 78px;
  height: 28px;
  object-fit: contain;
  z-index: 3;
}

.volume-toggle-btn {
  position: absolute;
  top: 10px;
  right: 10px;
  z-index: 3;
  width: 28px;
  height: 28px;
  border: 0;
  border-radius: 999px;
  background: rgba(0, 0, 0, 0.2);
  padding: 0;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  cursor: pointer;
}

.volume-toggle-btn img {
  width: 20px;
  height: 20px;
  object-fit: contain;
}

.featured-info {
  position: absolute;
  bottom: 0;
  left: 0;
  right: 0;
  width: 100%;
  height: 80px;
  background: rgba(0, 0, 0, 0.4);
  -webkit-backdrop-filter: blur(10px);
  backdrop-filter: blur(10px);
  padding: 10px 12px;
  display: flex;
  align-items: center;
  gap: 10px;
}

.featured-icon {
  width: 56px;
  height: 56px;
  border-radius: 10px;
  object-fit: cover;
  flex-shrink: 0;
  background: #1e3a5f;
}

.featured-name {
  flex: 1;
  min-width: 0;
  font-size: 17px;
  font-weight: 700;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

.play-now-btn {
  border: 0;
  background: #ffffff;
  color: #222;
  border-radius: 999px;
  padding: 8px 14px;
  font-size: 13px;
  font-weight: 700;
  cursor: pointer;
  flex-shrink: 0;
}

.hot-header {
  margin: 0 0 12px;
  font-size: 22px;
  line-height: 33px;
  letter-spacing: -0.01em;
  font-weight: 700;
  margin-top: 40px;
}

/* 参考 detail-hot-card.vue：wrap + 每项宽度计算，保证移动端一行 3 个 */
.hot-games-list {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  width: 100%;
  justify-content: flex-start;
}

.hot-game-item {
  position: relative;
  width: calc((100% - 16px) / 3);
  min-width: 0;
  text-decoration: none;
  color: var(--text-main);
  display: block;
  margin-bottom: 20px;
}

.hot-thumb-wrap {
  width: 100%;
  aspect-ratio: 1;
  border-radius: 12px;
  position: relative;
  min-height: 90px;
}

.hot-game-thumb {
  width: 100%;
  height: 100%;
  object-fit: cover;
  display: block;
  border-radius: 24px;
}

/* 参考组件里的 Hot 徽标位置与形态 */
.hot-badge {
  position: absolute;
  top: 0;
  left: 0;
  transform: translate(0%, -20%);
  width: 39px;
  height: 22px;
  object-fit: contain;
  z-index: 10;
  pointer-events: none;
}

.hot-name {
  margin-top: 6px;
  font-size: 11px;
  text-align: center;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
  color: #e9edff;
}

.show-more-btn {
  margin-top: 12px;
  width: 100%;
  border: 1px solid #7c70dc;
  border-radius: 999px;
  background: transparent;
  color: #ece9ff;
  font-size: 14px;
  font-weight: 600;
  padding: 11px 16px;
  cursor: pointer;
}

.mobile-ad-overlay {
  position: fixed;
  inset: 0;
  background: rgba(0, 0, 0, 0.75);
  z-index: 99999;
  display: none;
  align-items: center;
  justify-content: center;
  padding: 20px;
}

.mobile-ad-overlay.open { display: flex; }

.mobile-ad-overlay-content {
  width: 100%;
  max-width: 360px;
  background: #fff;
  border-radius: var(--radius-md);
  padding: 16px;
  position: relative;
}

.mobile-ad-overlay-close {
  position: absolute;
  top: 8px;
  right: 8px;
  width: 30px;
  height: 30px;
  border: 0;
  border-radius: 999px;
  background: rgba(0, 0, 0, 0.12);
  font-size: 18px;
  cursor: pointer;
}

.mobile-ad-overlay-ad {
  min-height: 220px;
  display: flex;
  align-items: center;
  justify-content: center;
  margin-top: 10px;
}
