/* ==========================================================================
   游戏站 · 前台样式
   浅色蓝调风格：页头 / 首页轮播 / 玩家社群 / 游戏列表 / 服务保障 / 详情页
   断点：1101px+（轮播右侧推荐栏）、≤900、≤768、≤700（手机）
   ========================================================================== */

:root {
  --ink: #132238;
  --ink-soft: #34536d;
  --muted: #6a7890;
  --muted-2: #94a3b8;
  --line: #e5ebf3;
  --blue: #2166d5;
  --blue-btn: #237fd9;
  --blue-btn-dark: #1768be;
  --blue-light: #4da3f3;
  --blue-sky: #5bb3f5;
  --blue-soft: #eaf4ff;
  --surface: #f5f8fc;
  --card: #fff;
  --green: #10b981;
  --radius-lg: 24px;
  --radius-md: 16px;
  --radius-sm: 10px;
  --shadow-card: 0 3px 12px rgba(20, 42, 67, 0.025);
  --shadow-lift: 0 14px 26px rgba(32, 84, 135, 0.11);
  --font: Inter, "PingFang SC", "HarmonyOS Sans SC", "Microsoft YaHei", "Noto Sans SC", system-ui, -apple-system, "Segoe UI", sans-serif;
  --mono: "SF Mono", "JetBrains Mono", Consolas, Monaco, monospace;
}

/* ---------------------------------------------------------- 基础 ---------- */

*,
*::before,
*::after {
  box-sizing: border-box;
}

html {
  scroll-behavior: smooth;
  scroll-padding-top: 92px;
  -webkit-text-size-adjust: 100%;
}

body {
  margin: 0;
  background: var(--surface);
  color: var(--ink);
  font-family: var(--font);
  font-size: 14px;
  line-height: 1.6;
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
  text-rendering: optimizeLegibility;
  overflow-x: hidden;
}

h1,
h2,
h3,
p,
ul,
ol,
figure {
  margin: 0;
}

ul,
ol {
  padding: 0;
}

a {
  color: var(--blue);
  text-decoration: none;
}

img {
  max-width: 100%;
}

button {
  font-family: inherit;
  cursor: pointer;
}

::selection {
  background: rgba(35, 127, 217, 0.2);
}

[hidden] {
  display: none !important;
}

:focus-visible {
  outline: 3px solid rgba(33, 102, 213, 0.45);
  outline-offset: 2px;
}

.sr-only {
  position: absolute;
  width: 1px;
  height: 1px;
  overflow: hidden;
  clip-path: inset(50%);
  white-space: nowrap;
}

.shell {
  width: min(1352px, calc(100% - 48px));
  margin: 0 auto;
}

.shell-narrow {
  width: min(1100px, calc(100% - 48px));
}

.arrow {
  display: inline-block;
  font-weight: inherit;
  transition: transform 0.2s ease;
}

/* 没有上传图片时显示的占位块，颜色由 --hue 决定 */
.ph {
  display: grid;
  place-items: center;
  width: 100%;
  height: 100%;
  color: rgba(255, 255, 255, 0.94);
  background:
    radial-gradient(120% 120% at 18% 12%, rgba(255, 255, 255, 0.3), transparent 52%),
    linear-gradient(135deg, hsl(var(--hue, 212) 78% 58%), hsl(calc(var(--hue, 212) + 48) 82% 40%));
  font-weight: 800;
  line-height: 1;
  user-select: none;
}

/* ---------------------------------------------------------- 按钮 ---------- */

.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 10px;
  min-height: 46px;
  padding: 0 22px;
  border: 1px solid transparent;
  border-radius: 999px;
  font-size: 14px;
  font-weight: 700;
  line-height: 1.2;
  white-space: nowrap;
  transition: transform 0.2s ease, box-shadow 0.2s ease, background-color 0.2s ease, color 0.2s ease;
}

.btn:hover .arrow {
  transform: translateX(3px);
}

.btn-primary {
  color: #fff;
  background: linear-gradient(180deg, #2b8ae4, var(--blue-btn));
  box-shadow: 0 6px 16px rgba(35, 127, 217, 0.26);
}

.btn-primary:hover {
  color: #fff;
  transform: translateY(-2px);
  box-shadow: 0 12px 26px rgba(29, 80, 150, 0.24);
}

.btn-sky {
  color: #fff;
  background: linear-gradient(180deg, #74c0fa, #3d9df2);
  border-radius: 10px;
}

.btn-sky:hover {
  color: #fff;
  transform: translateY(-2px);
  box-shadow: 0 12px 26px rgba(61, 157, 242, 0.32);
}

.btn-plain {
  color: var(--ink);
  padding: 0 10px;
}

.btn-plain:hover {
  color: var(--blue);
}

.btn-sm {
  min-height: 38px;
  padding: 0 14px;
  border-radius: 8px;
  font-size: 13px;
  justify-self: start;
}

/* ---------------------------------------------------------- 文字 ---------- */

.kicker {
  margin: 0 0 9px;
  color: var(--blue-light);
  font-size: 11px;
  font-weight: 800;
  letter-spacing: 0.16em;
  text-transform: uppercase;
}

.section-title {
  color: var(--ink);
  font-size: clamp(28px, 3.2vw, 34px);
  font-weight: 700;
  line-height: 1.25;
  letter-spacing: -0.01em;
}

.section-head {
  display: flex;
  align-items: flex-end;
  justify-content: space-between;
  gap: 24px;
  margin-bottom: 28px;
}

.section-lead {
  max-width: 520px;
  margin-top: 12px;
  color: var(--muted);
  line-height: 1.75;
}

.text-link {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  flex-shrink: 0;
  padding: 10px 16px;
  border: 1px solid #d6e0ec;
  border-radius: 999px;
  background: var(--card);
  color: var(--blue-light);
  font-size: 13px;
  font-weight: 700;
  white-space: nowrap;
  transition: border-color 0.2s ease, color 0.2s ease, transform 0.2s ease;
}

.text-link:hover {
  border-color: #a9c7ef;
  color: var(--blue);
}

.text-link:hover .arrow {
  transform: translateX(3px);
}

/* ---------------------------------------------------------- 页头 ---------- */

.site-header {
  position: sticky;
  z-index: 20;
  top: 0;
  background: rgba(245, 248, 252, 0.96);
  -webkit-backdrop-filter: blur(14px);
  backdrop-filter: blur(14px);
  border-bottom: 1px solid #e5edf6;
}

.header-inner {
  display: flex;
  align-items: center;
  gap: 24px;
  height: 76px;
}

.brand {
  display: inline-flex;
  align-items: center;
  gap: 12px;
  flex-shrink: 0;
  color: var(--ink);
}

.brand-mark {
  display: block;
  width: 40px;
  height: 40px;
  overflow: hidden;
  border-radius: 10px;
  background: #eaf3ff;
  font-size: 18px;
}

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

.brand-text strong {
  display: block;
  font-size: 16px;
  letter-spacing: 0.01em;
  line-height: 1.25;
}

.brand-text small {
  display: block;
  margin-top: 3px;
  color: var(--muted);
  font-size: 11px;
  line-height: 1.3;
}

.platform-note {
  display: grid;
  gap: 4px;
  margin: 0 0 0 16px;
  color: #2c82d3;
}

.platform-note strong {
  font-size: 14px;
  line-height: 1.2;
}

.platform-note span {
  color: var(--muted);
  font-size: 10px;
  font-weight: 700;
}

.main-nav {
  display: flex;
  align-items: center;
  gap: 30px;
  margin-left: auto;
  color: #50617a;
  font-size: 14px;
}

.main-nav a {
  padding: 6px 0;
  color: inherit;
  transition: color 0.2s ease;
}

.main-nav a:hover,
.main-nav a.is-active {
  color: var(--blue);
}

.main-nav a.is-active {
  font-weight: 600;
}

.header-cta {
  margin-left: 8px;
  color: var(--blue);
  font-size: 13px;
  font-weight: 700;
  white-space: nowrap;
}

.header-cta:hover .arrow {
  transform: translateX(3px);
}

.nav-toggle {
  display: none;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: 5px;
  width: 42px;
  height: 42px;
  margin-left: auto;
  padding: 0;
  border: 0;
  border-radius: 8px;
  color: currentColor;
  background: transparent;
}

.nav-toggle span {
  width: 20px;
  height: 2px;
  border-radius: 2px;
  background: currentColor;
  transition: transform 0.2s ease, opacity 0.2s ease;
}

.nav-toggle[aria-expanded="true"] span:nth-child(1) {
  transform: translateY(7px) rotate(45deg);
}

.nav-toggle[aria-expanded="true"] span:nth-child(2) {
  opacity: 0;
}

.nav-toggle[aria-expanded="true"] span:nth-child(3) {
  transform: translateY(-7px) rotate(-45deg);
}

/* ---------------------------------------------------- 首页轮播 ---------- */

.hero {
  padding: 24px 0 26px;
}

.hero-carousel {
  min-width: 0;
}

.hero-stage {
  position: relative;
  aspect-ratio: 16 / 7;
  overflow: hidden;
  isolation: isolate;
  border-radius: var(--radius-lg);
  background: #101824;
}

.hero-slide {
  position: absolute;
  inset: 0;
  display: block;
  opacity: 0;
  transition: opacity 0.9s ease;
}

.hero-slide.is-active {
  opacity: 1;
}

.hero-slide img {
  display: block;
  width: 100%;
  height: 100%;
  object-fit: cover;
  transform: scale(1.07);
  transition: transform 9s linear;
}

.hero-slide.is-active img {
  transform: scale(1);
}

.hero-pagination {
  position: absolute;
  z-index: 4;
  right: 156px; /* stops short of the prev / next / pause controls */
  bottom: 16px;
  left: 16px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 17px;
  color: rgba(255, 255, 255, 0.86);
  font-size: 13px;
  font-weight: 800;
  letter-spacing: 0.14em;
}

.hero-dots {
  display: flex;
  align-items: center;
  gap: 11px;
  max-width: calc(100% - 90px);
  padding: 9px 13px;
  overflow-x: auto;
  border: 1px solid rgba(255, 255, 255, 0.22);
  border-radius: 999px;
  background: rgba(8, 13, 22, 0.35);
  -webkit-backdrop-filter: blur(8px);
  backdrop-filter: blur(8px);
  scrollbar-width: none;
}

.hero-dots::-webkit-scrollbar {
  display: none;
}

.hero-dot {
  flex: 0 0 22px;
  width: 22px;
  height: 4px;
  padding: 0;
  border: 0;
  border-radius: 99px;
  background: rgba(255, 255, 255, 0.42);
  transition: background-color 0.2s ease;
}

.hero-dot:hover {
  background: rgba(255, 255, 255, 0.72);
}

.hero-dot.is-active {
  background: #4a9bea;
}

.hero-controls {
  position: absolute;
  z-index: 4;
  right: 20px;
  bottom: 14px;
  display: flex;
  gap: 7px;
}

.hero-controls button {
  display: grid;
  place-items: center;
  width: 36px;
  height: 36px;
  padding: 0;
  border: 1px solid rgba(255, 255, 255, 0.32);
  border-radius: 50%;
  color: #fff;
  background: rgba(8, 13, 22, 0.36);
  transition: background-color 0.2s ease, border-color 0.2s ease;
}

.hero-controls button:hover {
  border-color: #fff;
  background: rgba(255, 255, 255, 0.18);
}

.hero-controls .icon-play,
.hero-carousel.is-paused .icon-pause {
  display: none;
}

.hero-carousel.is-paused .icon-play {
  display: block;
}

.hero-progress {
  position: absolute;
  right: 0;
  bottom: 0;
  left: 0;
  z-index: 4;
  height: 3px;
  background: rgba(255, 255, 255, 0.14);
}

.hero-progress span {
  display: block;
  width: 100%;
  height: 100%;
  background: #4a9bea;
  transform: scaleX(0);
  transform-origin: left center;
  animation: hero-progress 6s linear;
}

@keyframes hero-progress {
  from {
    transform: scaleX(0);
  }
  to {
    transform: scaleX(1);
  }
}

body:has(.lightbox[open]) {
  overflow: hidden;
}

/* 轮播图下方：当前游戏的图标、名称、口号和两个按钮 */
.hero-captions {
  position: relative;
  height: 92px;
}

.hero-caption {
  position: absolute;
  inset: 0;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 24px;
  opacity: 0;
  visibility: hidden;
  transition: opacity 0.45s ease, visibility 0s linear 0.45s;
}

.hero-caption.is-active {
  opacity: 1;
  visibility: visible;
  transition: opacity 0.45s ease 0.15s;
}

.hero-identity {
  display: flex;
  align-items: center;
  gap: 13px;
  min-width: 0;
  color: var(--ink);
}

.hero-logo {
  display: block;
  flex: 0 0 auto;
  width: 54px;
  height: 54px;
  overflow: hidden;
  border-radius: 11px;
  background: #eaf1fa;
  box-shadow: 0 5px 13px rgba(20, 42, 67, 0.14);
  font-size: 22px;
}

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

.hero-id-text {
  display: grid;
  gap: 4px;
  min-width: 0;
}

.hero-id-text strong {
  overflow: hidden;
  font-size: 20px;
  line-height: 1.25;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.hero-id-text small {
  overflow: hidden;
  color: var(--muted);
  font-size: 14px;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.hero-actions {
  display: flex;
  align-items: center;
  gap: 10px;
  flex-shrink: 0;
}

/* 右侧精选推荐（宽屏） */
.hero-recs {
  display: none;
}

/* ------------------------------------------------------ 玩家社群 ---------- */

.community-band {
  padding: 40px 0;
  background: #fbfdff;
  border-top: 1px solid var(--line);
  border-bottom: 1px solid var(--line);
}

.community-entry {
  display: grid;
  grid-template-columns: minmax(260px, 0.9fr) minmax(300px, 1.25fr) auto;
  align-items: center;
  gap: 36px;
  padding: 28px 40px;
  border: 1px solid #c9ddf5;
  border-radius: var(--radius-lg);
  background: #f7fbff;
  color: var(--ink);
  transition: transform 0.2s ease, border-color 0.2s ease, box-shadow 0.2s ease;
}

.community-entry:hover {
  border-color: #8dbcee;
  box-shadow: 0 14px 30px rgba(33, 102, 213, 0.1);
  transform: translateY(-2px);
}

.community-copy .kicker {
  margin-bottom: 7px;
}

.community-title {
  margin-bottom: 8px;
  background: linear-gradient(92deg, #f7b933, #f08a1d);
  -webkit-background-clip: text;
  background-clip: text;
  color: transparent;
  font-size: 22px;
  font-weight: 800;
  line-height: 1.3;
}

.community-desc {
  color: var(--muted);
  line-height: 1.7;
}

.community-benefits {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  list-style: none;
}

.community-benefits li {
  display: grid;
  gap: 7px;
  min-width: 0;
  padding: 4px 18px;
  border-left: 1px solid #d6e4f4;
}

.community-benefits li:first-child {
  border-left: 0;
}

.community-benefits strong {
  color: #2c82d3;
  font-size: 13px;
}

.community-benefits span {
  color: var(--muted);
  font-size: 12px;
  line-height: 1.55;
}

.community-action {
  min-height: 44px;
  padding: 0 22px;
  font-size: 13px;
}

/* ------------------------------------------------------ 游戏列表 ---------- */

.games-section {
  padding: 56px 0 44px;
}

.browser {
  min-width: 0;
  padding: 22px 26px;
  border: 1px solid #dbe5f2;
  border-radius: 20px;
  background: var(--card);
  box-shadow: 0 4px 18px rgba(20, 42, 67, 0.025);
}

.browser-head {
  display: flex;
  align-items: baseline;
  justify-content: space-between;
  gap: 16px;
  margin-bottom: 18px;
}

.browser-title {
  color: var(--ink);
  font-size: 14px;
  font-weight: 700;
}

.browser-count {
  color: var(--muted);
  font-size: 12px;
  white-space: nowrap;
}

.browser-count strong {
  color: var(--blue);
}

.browser-controls {
  display: grid;
  grid-template-columns: minmax(0, 1fr) 160px;
  gap: 14px;
}

.browser-search,
.browser-sort {
  display: grid;
  gap: 6px;
  min-width: 0;
  color: var(--blue-light);
  font-size: 11px;
  font-weight: 700;
}

.browser-search {
  position: relative;
}

.browser-search input,
.browser-sort select {
  width: 100%;
  height: 44px;
  padding: 0 14px;
  border: 1px solid #d6e0ec;
  border-radius: var(--radius-sm);
  outline: none;
  color: var(--ink);
  background: #fbfdff;
  font: inherit;
  font-size: 14px;
  transition: border-color 0.15s ease, box-shadow 0.15s ease;
}

.browser-search input {
  padding-right: 44px;
}

.browser-search input::-webkit-search-cancel-button,
.browser-search input::-webkit-search-decoration {
  -webkit-appearance: none;
}

.browser-sort select {
  padding-right: 10px;
  appearance: none;
  background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 12 8' width='12' height='8'%3E%3Cpath d='M1 1.5l5 5 5-5' fill='none' stroke='%236a7890' stroke-width='1.8' stroke-linecap='round' stroke-linejoin='round'/%3E%3C/svg%3E");
  background-repeat: no-repeat;
  background-position: right 12px center;
  cursor: pointer;
}

.browser-search input::placeholder {
  color: #9aa9bc;
}

.browser-search input:focus,
.browser-sort select:focus {
  border-color: var(--blue);
  background-color: #fff;
  box-shadow: 0 0 0 3px rgba(33, 102, 213, 0.12);
}

.browser-clear {
  position: absolute;
  right: 6px;
  bottom: 6px;
  display: grid;
  place-items: center;
  width: 32px;
  height: 32px;
  padding: 0;
  border: 0;
  border-radius: 50%;
  color: var(--muted);
  background: transparent;
  font-size: 20px;
  line-height: 1;
}

.browser-clear:hover {
  color: var(--blue);
  background: #edf4ff;
}

.browser-cats-wrap {
  grid-column: 1 / -1;
  min-width: 0;
}

.browser-cats {
  display: flex;
  flex-wrap: wrap;
  gap: 7px;
}

.browser-cat {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  min-height: 40px;
  padding: 0 14px;
  border: 1px solid #e1e8f1;
  border-radius: 11px;
  color: var(--muted);
  background: var(--surface);
  font-size: 13px;
  font-weight: 600;
  white-space: nowrap;
  transition: color 0.15s ease, border-color 0.15s ease, background-color 0.15s ease;
}

.browser-cat small {
  padding: 4px 5px;
  border-radius: 5px;
  background: rgba(16, 32, 48, 0.06);
  font-size: 10px;
  font-variant-numeric: tabular-nums;
  line-height: 1;
}

.browser-cat:hover {
  border-color: #a9c7ef;
  color: var(--blue);
  background: #fff;
}

.browser-cat.is-active {
  border-color: var(--blue);
  background: linear-gradient(180deg, #3f95ea, var(--blue));
  color: #fff;
}

.browser-cat.is-active small {
  background: rgba(255, 255, 255, 0.18);
}

/* 网格与卡片 */
.browser-grid {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 12px 16px;
  margin-top: 18px;
}

.card {
  position: relative;
  min-width: 0;
  overflow: hidden;
  border: 1px solid #dde5ef;
  border-radius: var(--radius-md);
  background: var(--card);
  box-shadow: var(--shadow-card);
  transition: transform 0.18s ease, box-shadow 0.18s ease, border-color 0.18s ease;
}

.card:hover {
  border-color: #c9d9ec;
  box-shadow: var(--shadow-lift);
  transform: translateY(-2px);
}

.card-link {
  display: grid;
  grid-template-columns: 58px minmax(0, 1fr) auto;
  align-items: center;
  gap: 13px;
  min-height: 86px;
  padding: 11px 16px;
  color: inherit;
}

.card-logo {
  display: block;
  width: 58px;
  height: 58px;
  overflow: hidden;
  border-radius: 11px;
  background: #eaf1fa;
  box-shadow: 0 5px 13px rgba(20, 42, 67, 0.12);
  font-size: 22px;
}

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

.card-copy {
  display: grid;
  gap: 3px;
  min-width: 0;
}

.card-title {
  display: flex;
  align-items: center;
  gap: 7px;
  min-width: 0;
}

.card-title strong {
  overflow: hidden;
  color: var(--ink);
  font-size: 16px;
  line-height: 1.45;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.card-tags {
  overflow: hidden;
  color: var(--muted);
  font-size: 11px;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.card-action {
  padding: 6px 14px;
  border-radius: 9px;
  background: var(--blue-soft);
  color: var(--blue);
  font-size: 12px;
  font-weight: 700;
  line-height: 18px;
  white-space: nowrap;
}

.badge {
  flex-shrink: 0;
  max-width: 45%;
  overflow: hidden;
  padding: 3px 8px;
  border-radius: 999px;
  background: linear-gradient(135deg, #4aa8f5, #237fd9);
  color: #fff;
  font-size: 10px;
  font-weight: 800;
  line-height: 1.2;
  text-overflow: ellipsis;
  white-space: nowrap;
}

/* 带封面的大卡片：桌面端排在列表最前面 */
.card-media {
  position: relative;
  display: block;
  grid-column: 1 / -1;
  overflow: hidden;
  border-radius: 12px;
  aspect-ratio: 16 / 9.9;
  background: #eaf1fa;
}

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

.badge-corner {
  position: absolute;
  top: 8px;
  right: 8px;
  max-width: calc(100% - 16px);
  box-shadow: 0 4px 10px rgba(31, 54, 82, 0.2);
}

.browser-empty {
  grid-column: 1 / -1;
  display: grid;
  justify-items: center;
  align-content: center;
  gap: 6px;
  min-height: 180px;
  padding: 28px;
  border: 1px dashed #c8d7e8;
  border-radius: var(--radius-sm);
  color: var(--muted);
  background: rgba(255, 255, 255, 0.72);
  text-align: center;
}

.browser-empty strong {
  color: var(--ink);
  font-size: 15px;
}

.browser-more {
  display: flex;
  justify-content: center;
  padding-top: 22px;
}

.browser-more:empty {
  display: none;
}

.browser-more-btn {
  position: relative;
  min-width: 144px;
  min-height: 44px;
  padding: 8px 28px;
  overflow: hidden;
  border: 0;
  border-radius: 999px;
  background: linear-gradient(180deg, #66baf8, #3b9cf0);
  color: #fff;
  font-size: 14px;
  font-weight: 700;
  transition: transform 0.2s ease, box-shadow 0.2s ease;
}

.browser-more-btn:hover {
  box-shadow: 0 8px 20px rgba(61, 157, 242, 0.36);
  transform: translateY(-2px);
}

/* ---------------------------------------------------- 服务保障 ---------- */

.services {
  margin-top: 24px;
  padding: 80px 0 76px;
  background: #f7fafd;
  border-top: 1px solid var(--line);
}

.services-heading {
  display: grid;
  grid-template-columns: minmax(0, 1fr) minmax(320px, 594px);
  align-items: end;
  gap: 54px;
}

.service-community {
  display: grid;
  justify-items: start;
  gap: 8px;
  padding: 24px 28px;
  border: 1px solid #bed9f7;
  border-radius: var(--radius-md);
  background: var(--card);
  box-shadow: 0 10px 25px rgba(35, 102, 181, 0.08);
  color: var(--ink);
  transition: transform 0.2s ease, box-shadow 0.2s ease, border-color 0.2s ease;
}

.service-community:hover {
  border-color: #8dbcee;
  box-shadow: 0 16px 34px rgba(35, 102, 181, 0.15);
  transform: translateY(-2px);
}

.service-community-kicker {
  color: var(--blue-light);
  font-size: 11px;
  font-weight: 800;
  letter-spacing: 0.14em;
}

.service-community strong {
  font-size: 18px;
  line-height: 1.35;
}

.service-community p {
  color: var(--muted);
  font-size: 13px;
  line-height: 1.6;
}

.service-community .btn {
  margin-top: 6px;
}

.service-grid {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 16px;
  margin-top: 30px;
}

.service-item {
  padding: 28px;
  border: 1px solid #dce9f8;
  border-radius: var(--radius-md);
  background: rgba(255, 255, 255, 0.68);
}

.service-number {
  color: var(--blue-light);
  font-size: 13px;
  font-weight: 800;
  letter-spacing: 0.12em;
}

.service-item p {
  margin-top: 18px;
  color: #52637b;
  line-height: 1.7;
}

/* ---------------------------------------------------------- 页脚 ---------- */

.site-footer {
  padding: 36px 0;
  background: #fff;
  border-top: 1px solid var(--line);
  color: #687a94;
  font-size: 12px;
}

.footer-inner {
  display: flex;
  justify-content: space-between;
  gap: 30px;
}

.footer-inner a {
  color: inherit;
}

.footer-inner a:hover {
  color: var(--blue);
}

/* ------------------------------------------------------ 福利浮窗 ---------- */

.welfare-float {
  position: fixed;
  z-index: 30;
  right: 22px;
  bottom: calc(22px + env(safe-area-inset-bottom, 0px));
  width: min(344px, calc(100vw - 44px));
  border: 1px solid #bddafb;
  border-radius: var(--radius-md);
  background: rgba(255, 255, 255, 0.95);
  box-shadow: 0 14px 32px rgba(33, 102, 213, 0.16);
  -webkit-backdrop-filter: blur(16px);
  backdrop-filter: blur(16px);
  animation: float-in 0.4s ease both;
}

.welfare-float::before {
  content: "";
  position: absolute;
  top: 0;
  bottom: 0;
  left: 0;
  width: 5px;
  background: var(--blue);
}

.wf-link {
  display: grid;
  grid-template-columns: minmax(0, 1fr) auto;
  align-items: center;
  column-gap: 18px;
  padding: 15px 34px 15px 22px;
  color: var(--ink);
}

.wf-kicker {
  grid-column: 1;
  color: var(--blue);
  font-size: 11px;
  font-weight: 800;
  letter-spacing: 0.12em;
}

.wf-title {
  grid-column: 1;
  overflow: hidden;
  color: #26344b;
  font-size: 15px;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.wf-note {
  grid-column: 1;
  margin-top: 3px;
  color: #7d8ba1;
  font-size: 11px;
  font-style: normal;
  letter-spacing: 0.04em;
}

.wf-btn {
  grid-column: 2;
  grid-row: 1 / 4;
  display: grid;
  place-items: center;
  min-width: 44px;
  height: 44px;
  padding: 0 10px;
  border-radius: 7px;
  background: var(--blue);
  color: #fff;
  font-size: 19px;
  transition: transform 0.2s ease;
}

.wf-link:hover .wf-btn {
  transform: translateX(2px);
}

.wf-close {
  position: absolute;
  top: 4px;
  right: 6px;
  display: grid;
  place-items: center;
  width: 24px;
  height: 24px;
  padding: 0;
  border: 0;
  border-radius: 50%;
  color: #9aa9bc;
  background: transparent;
  font-size: 18px;
  line-height: 1;
  opacity: 0;
  transition: opacity 0.15s ease, color 0.15s ease, background-color 0.15s ease;
}

.welfare-float:hover .wf-close,
.wf-close:focus-visible {
  opacity: 1;
}

.wf-close:hover {
  color: var(--ink);
  background: #edf2f8;
}

@keyframes float-in {
  from {
    opacity: 0;
    transform: translateY(14px);
  }
}

/* ========================================================== 详情页 ========== */

.page-games,
.page-detail,
.page-error {
  background: linear-gradient(180deg, #edf4fc 0, var(--surface) 560px) no-repeat;
}

.crumbs {
  display: flex;
  align-items: center;
  gap: 8px;
  min-height: 56px;
  padding-top: 16px;
  color: var(--muted-2);
  font-size: 13px;
}

.crumbs span {
  color: #cbd5e1;
}

.crumbs a {
  color: #64748b;
  transition: color 0.2s ease;
}

.crumbs a:hover {
  color: var(--blue);
}

.crumbs b {
  overflow: hidden;
  color: var(--ink);
  font-weight: 600;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.d-hero {
  position: relative;
  display: grid;
  grid-template-columns: 128px minmax(0, 1fr);
  align-items: flex-start;
  gap: 36px;
  min-height: 340px;
  padding: 48px;
  overflow: hidden;
  border-radius: var(--radius-lg);
  background:
    radial-gradient(90% 130% at 88% 8%, hsl(var(--hue, 212) 70% 42% / 0.55), transparent 62%),
    linear-gradient(118deg, #0b1729, #12294a 62%, #1a3a63);
  box-shadow: 0 20px 60px rgba(15, 52, 96, 0.25);
  color: #fff;
}

.d-hero-bg {
  position: absolute;
  inset: 0;
  z-index: 0;
  width: 100%;
  height: 100%;
  object-fit: cover;
}

.d-hero-wash {
  position: absolute;
  inset: 0;
  z-index: 1;
  background: linear-gradient(90deg, rgba(8, 18, 35, 0.82), rgba(8, 18, 35, 0.55) 40%, rgba(8, 18, 35, 0.15) 75%, rgba(8, 18, 35, 0.05));
}

.d-icon {
  position: relative;
  z-index: 2;
  width: 128px;
  height: 128px;
  overflow: hidden;
  border-radius: 28px;
  background: #1a2a4a;
  box-shadow: 0 8px 24px rgba(0, 0, 0, 0.25);
  font-size: 52px;
}

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

.d-copy {
  position: relative;
  z-index: 2;
  min-width: 0;
}

.d-tags {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  margin-bottom: 14px;
}

.d-tag {
  padding: 4px 12px;
  border: 1px solid rgba(255, 255, 255, 0.25);
  border-radius: 8px;
  background: rgba(255, 255, 255, 0.15);
  -webkit-backdrop-filter: blur(10px);
  backdrop-filter: blur(10px);
  font-size: 12px;
  font-weight: 600;
}

.d-tag.is-badge {
  border-color: transparent;
  background: linear-gradient(135deg, #f093fb, #f5576c);
  box-shadow: 0 6px 18px rgba(245, 87, 108, 0.36);
  font-weight: 700;
}

.d-title {
  margin-bottom: 10px;
  color: #fff;
  font-size: clamp(30px, 4vw, 44px);
  font-weight: 800;
  line-height: 1.2;
  text-shadow: 0 2px 20px rgba(0, 0, 0, 0.3);
  overflow-wrap: anywhere;
}

.d-slogan {
  margin-bottom: 20px;
  color: #f3d58c;
  font-size: 20px;
  font-style: italic;
  font-weight: 500;
  line-height: 1.5;
}

.d-meta {
  display: flex;
  flex-wrap: wrap;
  gap: 12px 24px;
  margin-bottom: 24px;
  color: rgba(255, 255, 255, 0.72);
  font-size: 13px;
}

.d-meta > span {
  display: inline-flex;
  align-items: center;
  gap: 6px;
}

.d-meta b {
  margin-right: 2px;
  color: rgba(255, 255, 255, 0.92);
  font-weight: 600;
}

.d-status i {
  width: 8px;
  height: 8px;
  flex-shrink: 0;
  border-radius: 50%;
  background: var(--green);
  box-shadow: 0 0 8px rgba(16, 185, 129, 0.6);
  animation: status-pulse 2s ease-in-out infinite;
}

.d-status.is-beta i {
  background: #38bdf8;
  box-shadow: 0 0 8px rgba(56, 189, 248, 0.6);
}

.d-status.is-soon i {
  background: #fbbf24;
  box-shadow: 0 0 8px rgba(251, 191, 36, 0.6);
}

@keyframes status-pulse {
  50% {
    opacity: 0.45;
  }
}

.d-actions {
  display: flex;
  flex-wrap: wrap;
  gap: 12px;
}

.d-btn {
  position: relative;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  min-height: 50px;
  padding: 13px 28px;
  overflow: hidden;
  border: 1px solid var(--blue-btn);
  border-radius: var(--radius-sm);
  background: var(--blue-btn);
  color: #fff;
  font-size: 15px;
  font-weight: 700;
  white-space: nowrap;
  transition: transform 0.18s ease, background-color 0.2s ease, border-color 0.2s ease, box-shadow 0.2s ease;
}

.d-btn > * {
  position: relative;
  z-index: 1;
}

.d-btn:hover {
  border-color: var(--blue-btn);
  background: var(--blue-btn-dark);
  box-shadow: 0 10px 24px rgba(8, 30, 60, 0.28);
  transform: translateY(-2px);
}

.d-btn:hover .arrow {
  transform: translateX(3px);
}

.d-btn:active {
  transform: translateY(1px) scale(0.985);
}

/* 悬停时扫过的高光 */
.d-btn::after {
  content: "";
  position: absolute;
  top: -70%;
  left: -45%;
  z-index: 0;
  width: 26%;
  height: 240%;
  background: rgba(255, 255, 255, 0.45);
  filter: blur(2px);
  opacity: 0;
  transform: rotate(18deg);
  pointer-events: none;
}

.d-btn:hover::after {
  animation: btn-shine 0.62s ease-out;
}

@keyframes btn-shine {
  from {
    opacity: 1;
    transform: rotate(18deg) translateX(0);
  }
  to {
    opacity: 0;
    transform: rotate(18deg) translateX(620%);
  }
}

.d-btn.is-soft {
  border-color: rgba(255, 255, 255, 0.34);
  background: rgba(255, 255, 255, 0.14);
  -webkit-backdrop-filter: blur(10px) saturate(140%);
  backdrop-filter: blur(10px) saturate(140%);
}

.d-btn.is-soft:hover {
  border-color: rgba(255, 255, 255, 0.6);
  background: rgba(255, 255, 255, 0.24);
  box-shadow: none;
}

.d-btn.is-gold {
  border-color: transparent;
  background: linear-gradient(135deg, #ffd77a, #f0a92e);
  color: #4a2c00;
}

.d-btn.is-gold:hover {
  border-color: transparent;
  background: linear-gradient(135deg, #ffe19a, #f6b544);
  box-shadow: 0 10px 24px rgba(240, 169, 46, 0.3);
}

.d-btn.is-ghost {
  border-color: rgba(255, 255, 255, 0.45);
  background: rgba(12, 20, 33, 0.34);
}

.d-btn.is-ghost:hover {
  border-color: #fff;
  background: rgba(12, 20, 33, 0.5);
  box-shadow: none;
}

.d-note {
  display: inline-flex;
  align-items: flex-start;
  gap: 10px;
  margin-top: 16px;
  padding: 10px 14px;
  border: 1px solid rgba(255, 255, 255, 0.14);
  border-radius: var(--radius-sm);
  background: rgba(8, 18, 35, 0.45);
  -webkit-backdrop-filter: blur(10px);
  backdrop-filter: blur(10px);
  color: rgba(255, 255, 255, 0.9);
  font-size: 13px;
  line-height: 1.6;
  white-space: pre-line;
}

.d-note svg {
  flex-shrink: 0;
  margin-top: 2px;
  color: #9cc8ff;
}

/* 进群卡片 */
.d-community-wrap {
  margin-top: 28px;
}

.d-community {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 24px;
  min-height: 104px;
  padding: 18px 22px;
  border: 1px solid #cfe1f5;
  border-radius: var(--radius-md);
  background: linear-gradient(135deg, #fff, #f1f8ff);
  box-shadow: 0 12px 28px rgba(35, 102, 181, 0.09);
  color: var(--ink);
  transition: transform 0.2s ease, box-shadow 0.2s ease, border-color 0.2s ease;
}

.d-community:hover {
  border-color: #7eb5eb;
  box-shadow: 0 16px 34px rgba(35, 102, 181, 0.15);
  transform: translateY(-2px);
}

.d-community-left {
  display: flex;
  align-items: center;
  gap: 16px;
  min-width: 0;
}

.d-community-icon {
  display: grid;
  place-items: center;
  flex: 0 0 auto;
  width: 52px;
  height: 52px;
  border-radius: 13px;
  background: linear-gradient(145deg, #2e8be0, #1765bc);
  box-shadow: 0 8px 18px rgba(35, 127, 217, 0.25);
  color: #fff;
}

.d-community-text {
  display: grid;
  gap: 5px;
  min-width: 0;
}

.d-community-text strong {
  overflow: hidden;
  color: #17324d;
  font-size: 18px;
  line-height: 1.35;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.d-community-text span {
  overflow: hidden;
  color: #71839a;
  font-size: 13px;
  line-height: 1.55;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.d-community-btn {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  flex: 0 0 auto;
  min-height: 42px;
  padding: 0 17px;
  border-radius: var(--radius-sm);
  background: var(--blue-btn);
  box-shadow: 0 7px 16px rgba(35, 127, 217, 0.22);
  color: #fff;
  font-size: 13px;
  font-weight: 800;
  white-space: nowrap;
}

.d-community-btn:hover .arrow {
  transform: translateX(3px);
}

/* 详情页各版块 */
.d-body {
  padding-top: 28px;
}

.d-section {
  padding-bottom: 28px;
  margin-bottom: 28px;
  border-bottom: 1px solid #e2e8f0;
}

.d-section:last-child {
  padding-bottom: 0;
  margin-bottom: 0;
  border-bottom: 0;
}

.d-section-head {
  display: flex;
  align-items: flex-start;
  gap: 12px;
  margin-bottom: 18px;
}

.d-section-accent {
  flex-shrink: 0;
  width: 4px;
  height: 44px;
  margin-top: 2px;
  border-radius: 4px;
  background: linear-gradient(180deg, #237fd9, #1b5fa8);
}

.d-section-head .kicker {
  margin-bottom: 2px;
}

.d-section-head h2 {
  color: #17324d;
  font-size: 26px;
  font-weight: 700;
  letter-spacing: -0.01em;
  line-height: 1.3;
}

.d-section-sub {
  margin-top: 4px;
  color: var(--muted-2);
  font-size: 13px;
}

.d-section-head .text-link {
  margin-left: auto;
  align-self: center;
}

/* 游戏介绍的内容块样式见 intro.css（后台预览共用） */

/* 兑换码 */
.cdk-list {
  display: grid;
  gap: 14px;
}

.cdk-item {
  position: relative;
  display: grid;
  grid-template-columns: minmax(110px, 160px) minmax(0, 1fr) 100px;
  align-items: center;
  gap: 22px;
  padding: 18px 22px;
  overflow: hidden;
  border: 1px solid #e1e9f3;
  border-radius: 14px;
  background: var(--card);
  box-shadow: 0 2px 7px rgba(23, 50, 77, 0.02);
  transition: border-color 0.18s ease, box-shadow 0.18s ease;
}

.cdk-item::before {
  content: "";
  position: absolute;
  top: 0;
  bottom: 0;
  left: 0;
  width: 4px;
  background: linear-gradient(180deg, #237fd9, #1b5fa8);
}

.cdk-item.is-claimed {
  border-color: #c6e6d8;
  background: #fbfefd;
}

.cdk-item.is-claimed::before {
  background: linear-gradient(180deg, #22a37b, #17835f);
}

.cdk-item:hover {
  border-color: #b9d2ee;
  box-shadow: 0 5px 18px rgba(23, 50, 77, 0.05);
}

.cdk-code {
  min-width: 0;
  width: 100%;
  padding: 11px 12px;
  overflow: hidden;
  border: 1px solid rgba(35, 127, 217, 0.15);
  border-radius: var(--radius-sm);
  background: #eef5ff;
  color: var(--blue);
  font-family: var(--mono);
  font-size: 15px;
  font-weight: 800;
  letter-spacing: 1px;
  line-height: 1.5;
  text-align: center;
  overflow-wrap: anywhere;
}

.cdk-reward {
  min-width: 0;
  color: #475569;
  font-size: 14px;
  line-height: 1.75;
  overflow-wrap: anywhere;
}

.cdk-tag {
  display: inline-block;
  margin-bottom: 6px;
  padding: 3px 10px;
  border-radius: 6px;
  background: #fef3c7;
  color: #b45309;
  font-size: 12px;
  font-weight: 600;
  line-height: 1.5;
}

.cdk-reward strong {
  display: block;
  color: var(--ink);
  font-weight: 500;
  white-space: pre-line;
}

.cdk-actions {
  display: flex;
  flex-direction: column;
  align-items: stretch;
  gap: 4px;
}

.cdk-copy,
.cdk-claim {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 6px;
  border: 1px solid transparent;
  font: inherit;
  transition: color 0.15s ease, background-color 0.15s ease, border-color 0.15s ease;
}

.cdk-copy {
  min-height: 38px;
  padding: 8px 12px;
  border-color: #d7e7f9;
  border-radius: 9px;
  background: #f0f6ff;
  color: #246ab8;
  font-size: 12px;
  font-weight: 600;
}

.cdk-copy:hover {
  border-color: #bcd6f4;
  background: #e5f0fe;
  color: #195599;
}

.cdk-copy.is-copied {
  border-color: #90c5aa;
  background: #e3f3eb;
  color: #226343;
}

.cdk-claim {
  min-height: 30px;
  padding: 4px 8px;
  border-radius: 8px;
  background: transparent;
  color: #748399;
  font-size: 11px;
}

.cdk-claim:hover {
  background: #f1f5fa;
  color: var(--ink);
}

.cdk-claim[aria-pressed="true"] {
  background: #eff8f4;
  color: #2d8068;
}

.cdk-note {
  margin-top: 10px;
  color: #64758b;
  font-size: 12px;
}

/* 福利长图 */
.welfare-grid {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  align-items: start;
  gap: 18px;
}

.welfare-card {
  position: relative;
  display: block;
  width: 100%;
  padding: 0;
  overflow: hidden;
  border: 1px solid #e2e8f0;
  border-radius: 18px;
  background: var(--card);
  aspect-ratio: 4 / 5;
  cursor: zoom-in;
  text-align: left;
  transition: transform 0.2s ease, box-shadow 0.2s ease, border-color 0.2s ease;
}

.welfare-card:hover {
  border-color: rgba(35, 127, 217, 0.3);
  box-shadow: 0 16px 40px rgba(0, 0, 0, 0.1);
  transform: translateY(-4px);
}

.welfare-card img {
  display: block;
  width: 100%;
  height: 100%;
  object-fit: cover;
  object-position: top center;
  transition: transform 0.4s ease;
  transform-origin: top center;
}

.welfare-card:hover img {
  transform: scale(1.03);
}

.welfare-card-veil {
  position: absolute;
  inset: 0;
  background: linear-gradient(180deg, transparent 58%, rgba(8, 18, 35, 0.82) 92%);
  pointer-events: none;
}

.welfare-card-hint {
  position: absolute;
  right: 14px;
  bottom: 14px;
  left: 14px;
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  color: #fff;
  font-size: 13px;
  font-weight: 700;
  text-shadow: 0 1px 6px rgba(0, 0, 0, 0.4);
}

.welfare-card-caption {
  position: absolute;
  top: 12px;
  left: 12px;
  max-width: calc(100% - 24px);
  overflow: hidden;
  padding: 5px 10px;
  border-radius: 8px;
  background: rgba(8, 18, 35, 0.55);
  -webkit-backdrop-filter: blur(8px);
  backdrop-filter: blur(8px);
  color: #fff;
  font-size: 12px;
  text-overflow: ellipsis;
  white-space: nowrap;
}

/* 更多游戏 */
.d-related {
  padding: 40px 0 48px;
}

.d-related .d-section-head {
  align-items: center;
  margin-bottom: 18px;
}

.d-related .d-section-accent {
  height: 40px;
  margin-top: 0;
}

.d-related .d-section-head h2 {
  font-size: 22px;
}

/* 查看长图 */
.lightbox {
  width: min(1100px, 96vw);
  max-width: none;
  height: min(94dvh, 980px);
  max-height: none;
  margin: auto;
  padding: 14px;
  border: 0;
  border-radius: 16px;
  background: #0e1c31;
  color: #fff;
}

.lightbox[open] {
  display: flex;
  flex-direction: column;
  gap: 12px;
}

.lightbox::backdrop {
  background: rgba(8, 18, 35, 0.9);
  -webkit-backdrop-filter: blur(4px);
  backdrop-filter: blur(4px);
}

.lightbox-bar {
  display: flex;
  align-items: center;
  gap: 12px;
  flex-shrink: 0;
  padding: 0 2px;
}

.lightbox-title {
  flex: 1;
  min-width: 0;
  overflow: hidden;
  font-size: 14px;
  font-weight: 600;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.lightbox-nav {
  display: inline-flex;
  align-items: center;
  gap: 8px;
}

.lightbox-nav button,
.lightbox-close {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-width: 40px;
  height: 40px;
  padding: 0 12px;
  border: 1px solid rgba(255, 255, 255, 0.2);
  border-radius: 10px;
  background: rgba(255, 255, 255, 0.1);
  color: #fff;
  font-size: 13px;
  font-weight: 700;
  transition: background-color 0.2s ease, border-color 0.2s ease;
}

.lightbox-nav button {
  font-size: 20px;
  line-height: 1;
}

.lightbox-nav button:hover,
.lightbox-close:hover {
  border-color: rgba(255, 255, 255, 0.36);
  background: rgba(255, 255, 255, 0.2);
}

.lightbox-index {
  color: rgba(255, 255, 255, 0.8);
  font-size: 13px;
  font-variant-numeric: tabular-nums;
}

.lightbox-close {
  margin-left: 8px;
  background: rgba(214, 63, 76, 0.78);
}

.lightbox-close:hover {
  background: rgba(230, 76, 89, 0.92);
}

.lightbox-viewport {
  flex: 1;
  min-height: 0;
  overflow: auto;
  border-radius: 12px;
  scrollbar-gutter: stable;
  -webkit-overflow-scrolling: touch;
}

.lightbox-viewport img {
  display: block;
  width: auto;
  max-width: 100%;
  height: auto;
  margin: 0 auto;
  border-radius: 12px;
  box-shadow: 0 20px 60px rgba(0, 0, 0, 0.5);
  user-select: none;
  -webkit-user-drag: none;
}

/* ---------------------------------------------------------- 404 ---------- */

.error-page {
  min-height: 52vh;
  display: grid;
  place-items: center;
  padding: 72px 0 96px;
}

.error-card {
  text-align: center;
}

.error-card .section-title {
  font-size: 40px;
}

.error-card .section-lead {
  margin: 14px auto 0;
}

.error-actions {
  display: flex;
  flex-wrap: wrap;
  justify-content: center;
  gap: 12px;
  margin-top: 28px;
}

/* ======================================================== 响应式 ========== */

@media (min-width: 1101px) {
  .hero-frame.has-recs {
    display: grid;
    grid-template-columns: minmax(0, 1fr) 286px;
    grid-template-rows: auto auto;
    column-gap: 18px;
    align-items: stretch;
  }

  /* The carousel wrapper dissolves so the recommendation panel can sit beside
     the image only (the caption row below spans the left column alone). */
  .hero-frame.has-recs .hero-carousel {
    display: contents;
  }

  /* The image sets the row height; the panel stretches to match it and scrolls
     internally instead of growing the row to fit all of its cards. */
  .hero-frame.has-recs .hero-stage {
    grid-row: 1;
    grid-column: 1;
    align-self: start;
    min-width: 0;
  }

  .hero-frame.has-recs .hero-captions {
    grid-row: 2;
    grid-column: 1;
    min-width: 0;
  }

  .hero-frame.has-recs .hero-recs {
    display: flex;
    grid-row: 1;
    grid-column: 2;
    flex-direction: column;
    min-height: 0;
    contain: size;
    padding: 12px;
    border: 1px solid #dfe8f2;
    border-radius: 20px;
    background: linear-gradient(145deg, rgba(255, 255, 255, 0.93), rgba(237, 245, 255, 0.7));
    box-shadow: 0 8px 24px rgba(33, 56, 81, 0.04);
  }

  .hero-recs-head {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 8px;
    padding: 2px 3px 12px;
    color: var(--ink);
  }

  .hero-recs-head strong {
    font-size: 15px;
  }

  .hero-recs-head span {
    color: var(--muted);
    font-size: 11px;
  }

  .hero-recs-list {
    display: grid;
    grid-auto-rows: 132px;
    align-content: start;
    gap: 10px;
    min-height: 0;
    padding-right: 4px;
    overflow-y: auto;
    overscroll-behavior: contain;
    scrollbar-width: thin;
    scrollbar-color: #b6c9df transparent;
  }

  .rec-card {
    position: relative;
    display: block;
    overflow: hidden;
    isolation: isolate;
    border-radius: 12px;
    background: #18304c;
    color: #fff;
  }

  .rec-card img {
    display: block;
    width: 100%;
    height: 100%;
    object-fit: cover;
    transition: transform 0.25s ease;
  }

  .rec-card:hover img {
    transform: scale(1.035);
  }

  .rec-caption {
    position: absolute;
    right: 0;
    bottom: 0;
    left: 0;
    display: flex;
    align-items: flex-end;
    justify-content: space-between;
    gap: 8px;
    padding: 28px 12px 10px;
    background: linear-gradient(transparent, rgba(16, 36, 61, 0.9));
  }

  .rec-text {
    display: grid;
    gap: 4px;
    min-width: 0;
  }

  .rec-text strong {
    overflow: hidden;
    font-size: 14px;
    line-height: 1.4;
    text-overflow: ellipsis;
    white-space: nowrap;
  }

  .rec-text small {
    overflow: hidden;
    color: #d6e5f7;
    font-size: 11px;
    text-overflow: ellipsis;
    white-space: nowrap;
  }

  .rec-caption b {
    flex-shrink: 0;
    font-size: 19px;
    line-height: 1;
  }
}

@media (min-width: 701px) {
  /* 大卡片：封面在上、标题和按钮在下 */
  .card-poster .card-link {
    grid-template-columns: minmax(0, 1fr) auto;
    gap: 12px;
    min-height: 0;
    padding: 8px 8px 14px;
  }

  .card-poster .card-logo {
    display: none;
  }

  .card-poster .card-copy {
    align-self: center;
    padding: 0 8px;
  }

  /* 首页第 4 张大卡片在桌面端退回为普通行，保证第一行正好 3 张封面 */
  .card-poster-fix .card-link {
    grid-template-columns: 58px minmax(0, 1fr) auto;
    gap: 13px;
    min-height: 86px;
    padding: 11px 16px;
  }

  .card-poster-fix .card-media {
    display: none;
  }

  .card-poster-fix .card-logo {
    display: block;
  }

  .card-poster-fix .card-copy {
    align-self: center;
    padding: 0;
  }
}

@media (max-width: 1280px) {
  .main-nav {
    gap: 20px;
  }

  .platform-note {
    display: none;
  }
}

@media (max-width: 1100px) {
  .hero-stage {
    aspect-ratio: 16 / 8;
  }
}

@media (max-width: 900px) {
  .browser-grid {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }

  .community-entry {
    grid-template-columns: minmax(0, 1fr);
    gap: 22px;
    padding: 28px;
  }

  .services-heading {
    grid-template-columns: minmax(0, 1fr);
    align-items: stretch;
    gap: 26px;
  }
}

@media (max-width: 768px) {
  .d-hero {
    min-height: 0;
    padding: 36px 24px 32px;
  }

  .d-community {
    align-items: flex-start;
    flex-wrap: wrap;
    gap: 14px;
    padding: 16px;
    border-radius: 14px;
  }

  .d-community-left {
    flex: 1 1 220px;
    gap: 12px;
  }

  .d-community-icon {
    width: 46px;
    height: 46px;
    border-radius: 12px;
  }

  .d-community-icon svg {
    width: 22px;
    height: 22px;
  }

  .d-community-text strong {
    font-size: 16px;
  }

  .d-community-text span {
    font-size: 12px;
  }

  .d-community-btn {
    flex: 1 0 100%;
    justify-content: center;
    min-height: 40px;
  }

  .cdk-item {
    grid-template-columns: minmax(0, 1fr) 94px;
    gap: 12px 16px;
    padding: 16px;
    border-radius: 13px;
  }

  .cdk-code {
    width: fit-content;
    max-width: 100%;
    text-align: left;
  }

  .cdk-reward {
    grid-row: 2;
    grid-column: 1 / -1;
    padding-top: 12px;
    border-top: 1px dashed #e2eaf4;
  }

  .cdk-actions {
    grid-row: 1;
    grid-column: 2;
  }

  .welfare-grid {
    grid-template-columns: minmax(0, 1fr);
  }

  .d-related .browser-grid {
    grid-template-columns: minmax(0, 1fr);
  }
}

@media (max-width: 700px) {
  .shell {
    width: calc(100% - 32px);
  }

  .shell-narrow {
    width: calc(100% - 32px);
  }

  .header-inner {
    height: 68px;
    gap: 16px;
  }

  .brand-text small,
  .main-nav,
  .platform-note,
  .header-cta {
    display: none;
  }

  .main-nav.is-open {
    position: absolute;
    top: calc(100% + 8px);
    right: 16px;
    display: grid;
    min-width: 148px;
    gap: 0;
    margin-left: 0;
    padding: 7px;
    border: 1px solid #dbe6f4;
    border-radius: 12px;
    background: rgba(255, 255, 255, 0.98);
    box-shadow: 0 12px 28px rgba(16, 35, 63, 0.16);
    color: #34445d;
  }

  .main-nav.is-open a {
    padding: 11px 12px;
    border-radius: 8px;
  }

  .nav-toggle {
    display: inline-flex;
  }

  .section-head {
    display: block;
    margin-bottom: 20px;
  }

  .section-head .text-link {
    display: inline-flex;
    margin-top: 14px;
  }

  .kicker {
    margin-bottom: 7px;
  }

  .section-title {
    font-size: 28px;
  }

  /* 轮播 */
  .hero {
    padding: 14px 0 24px;
  }

  .hero .shell {
    width: calc(100% - 24px);
  }

  .hero-stage {
    aspect-ratio: 9 / 7;
    border-radius: 20px;
  }

  .hero-slide img {
    object-position: center;
  }

  .hero-pagination {
    right: 12px;
    bottom: 12px;
    left: 12px;
    gap: 13px;
  }

  .hero-dots {
    flex: 1;
    max-width: none;
    justify-content: flex-start;
    gap: 7px;
    padding: 8px 13px;
  }

  .hero-dot {
    flex-basis: 18px;
    width: 18px;
  }

  .hero-counter {
    padding: 0 10px;
    font-size: 12px;
  }

  .hero-controls {
    display: none;
  }

  .hero-captions {
    height: auto;
    min-height: 128px;
    padding: 4px 4px 0;
  }

  .hero-caption {
    flex-direction: column;
    align-items: stretch;
    gap: 16px;
  }

  .hero-id-text strong {
    font-size: 18px;
  }

  .hero-actions {
    gap: 6px;
  }

  .hero-actions .btn {
    min-height: 46px;
    padding: 0 20px;
  }

  /* 社群 */
  .community-band {
    padding: 24px 0;
  }

  .community-entry {
    gap: 20px;
    padding: 24px 20px;
    border-radius: 20px;
  }

  .community-title {
    font-size: 20px;
  }

  .community-benefits {
    grid-template-columns: minmax(0, 1fr);
  }

  .community-benefits li {
    grid-template-columns: 96px minmax(0, 1fr);
    align-items: center;
    gap: 12px;
    padding: 12px 0;
    border-top: 1px solid #d6e4f4;
    border-left: 0;
  }

  .community-benefits li:first-child {
    border-top: 1px solid #d6e4f4;
  }

  .community-action {
    justify-self: start;
  }

  /* 游戏列表 */
  .games-section {
    padding: 40px 0 32px;
  }

  .browser {
    padding: 16px 14px;
    border-radius: 16px;
  }

  .browser-head {
    flex-direction: column;
    gap: 5px;
    margin-bottom: 14px;
  }

  .browser-title {
    font-size: 13px;
  }

  .browser-count {
    font-size: 11px;
  }

  .browser-controls {
    grid-template-columns: minmax(0, 1fr) 108px;
    gap: 10px;
  }

  .browser-search input,
  .browser-sort select {
    height: 44px;
    font-size: 13px;
  }

  .browser-cats {
    flex-wrap: nowrap;
    max-width: 100%;
    padding: 2px 2px 7px;
    overflow-x: auto;
    overscroll-behavior-x: contain;
    scrollbar-width: thin;
  }

  .browser-cat {
    flex-shrink: 0;
    min-height: 38px;
    padding: 0 12px;
  }

  .browser-grid {
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 12px;
    margin-top: 6px;
  }

  .browser-grid > .card {
    grid-column: 1 / -1;
  }

  .browser-grid > .card-poster {
    grid-column: auto;
  }

  .card-poster .card-link {
    display: flex;
    flex-direction: column;
    align-items: stretch;
    gap: 10px;
    height: 100%;
    padding: 8px 8px 12px;
  }

  .card-poster .card-media {
    aspect-ratio: 4 / 3;
  }

  .card-poster .card-logo {
    display: none;
  }

  .card-poster .card-copy {
    flex: 1;
    align-self: stretch;
    padding: 0 3px;
    gap: 4px;
  }

  .card-poster .card-title strong {
    display: -webkit-box;
    min-height: 40px;
    white-space: normal;
    font-size: 14px;
    -webkit-box-orient: vertical;
    -webkit-line-clamp: 2;
  }

  .card-poster .card-action {
    align-self: flex-start;
    margin: 0 3px;
    padding: 7px 11px;
  }

  .card-poster-fix .card-title .badge {
    display: none;
  }

  .card-link {
    min-height: 76px;
    padding: 12px;
  }

  .browser-empty {
    min-height: 150px;
  }

  .browser-more-btn {
    min-height: 46px;
  }

  /* 服务保障 */
  .services {
    margin-top: 16px;
    padding: 56px 0;
  }

  .service-grid {
    grid-template-columns: minmax(0, 1fr);
    gap: 12px;
    margin-top: 22px;
  }

  .service-item {
    padding: 22px;
  }

  .service-item p {
    margin-top: 12px;
  }

  .service-community {
    padding: 22px;
  }

  .footer-inner {
    display: block;
  }

  .footer-inner p + p {
    margin-top: 8px;
  }

  .welfare-float {
    right: 12px;
    bottom: calc(12px + env(safe-area-inset-bottom, 0px));
    width: min(300px, calc(100vw - 24px));
  }

  .wf-link {
    padding: 12px 30px 12px 18px;
  }

  .wf-title {
    font-size: 14px;
  }

  .wf-btn {
    width: 42px;
    min-width: 42px;
    height: 42px;
    padding: 0;
    border-radius: 10px;
  }

  /* 详情页 */
  .crumbs {
    min-height: 44px;
    gap: 6px;
    padding-top: 12px;
    font-size: 12px;
  }

  .d-hero {
    grid-template-columns: minmax(0, 1fr) clamp(78px, 24vw, 96px);
    align-items: start;
    gap: 14px;
    padding: 28px 18px 24px;
    border-radius: 18px;
  }

  .d-icon {
    grid-row: 1;
    grid-column: 2;
    width: clamp(78px, 24vw, 96px);
    height: auto;
    margin-top: 6px;
    border-radius: 22px;
    aspect-ratio: 1;
    font-size: 36px;
  }

  .d-copy {
    grid-row: 1;
    grid-column: 1;
    width: 100%;
  }

  .d-tags {
    gap: 6px;
    margin-bottom: 12px;
  }

  .d-tag {
    padding: 4px 10px;
  }

  .d-title {
    font-size: clamp(26px, 8vw, 34px);
  }

  .d-slogan {
    margin-bottom: 16px;
    font-size: 15px;
  }

  .d-meta {
    gap: 8px 12px;
    margin-bottom: 18px;
    font-size: 12px;
  }

  .d-actions {
    flex-direction: column;
    width: 100%;
  }

  .d-actions .d-btn {
    width: 100%;
  }

  .d-note {
    display: flex;
    width: 100%;
    font-size: 12px;
  }

  .d-community-wrap {
    margin-top: 18px;
  }

  .d-body {
    padding-top: 22px;
  }

  .d-section {
    padding-bottom: 22px;
    margin-bottom: 22px;
  }

  .d-section-head h2 {
    font-size: 22px;
  }

  .d-section-accent {
    height: 40px;
  }

  .intro {
    font-size: 14px;
    line-height: 1.8;
  }

  .intro-h {
    font-size: 18px;
  }

  .welfare-card {
    aspect-ratio: 4 / 4.6;
  }

  .d-related {
    padding-bottom: 32px;
  }

  .lightbox {
    width: 100%;
    height: 100%;
    max-height: 100dvh;
    margin: 0;
    padding: 10px;
    border-radius: 0;
  }

  .lightbox-bar {
    padding-top: env(safe-area-inset-top, 0px);
  }
}

@media (prefers-reduced-motion: reduce) {
  html {
    scroll-behavior: auto;
  }

  *,
  *::before,
  *::after {
    animation-duration: 0.01ms !important;
    animation-iteration-count: 1 !important;
    transition-duration: 0.01ms !important;
  }

  .hero-slide img {
    transform: none;
  }

  .card:hover,
  .community-entry:hover,
  .d-community:hover,
  .welfare-card:hover,
  .service-community:hover,
  .btn:hover,
  .d-btn:hover,
  .browser-more-btn:hover {
    transform: none;
  }
}
