:root {
  color-scheme: light;
  --paper: #f6f7f3;
  --white: #fff;
  --ink: #152e3e;
  --muted: #4a626c;
  --line: #d7e1de;
  --teal: #006b72;
  --teal-soft: #e3f2ee;
  --navy: #123347;
  --amber: #965214;
  --gutter: clamp(20px, 5vw, 76px);
  --content: 1440px;
  --shadow: 0 16px 44px #17354812;
}

* { box-sizing: border-box; }
[hidden] { display: none !important; }
html { scroll-padding-top: 24px; }
body {
  margin: 0;
  background: var(--paper);
  color: var(--ink);
  font-family: "PingFang SC", "Microsoft YaHei", system-ui, sans-serif;
  -webkit-font-smoothing: antialiased;
}
a { color: inherit; text-decoration: none; }
button, input, select { font: inherit; color: inherit; }
button { cursor: pointer; }
button:disabled { cursor: default; opacity: .5; }
img { display: block; max-width: 100%; }
:focus-visible { outline: 3px solid var(--teal); outline-offset: 4px; }
.skip, .sr-only { position: absolute; clip-path: inset(50%); }
.skip:focus { clip-path: none; z-index: 10; background: var(--white); padding: 12px; }

header, .hero, .section, .spotlight-band, footer {
  width: min(100%, var(--content));
  margin-inline: auto;
  padding-inline: var(--gutter);
}
header, footer { display: flex; align-items: center; justify-content: space-between; gap: 22px; }
header { min-height: 84px; }
.brand { display: inline-flex; align-items: center; gap: 11px; font-size: 1.2rem; font-weight: 760; white-space: nowrap; }
.brand small { display: block; margin-top: 3px; color: var(--muted); font: 650 .59rem/1.15 system-ui, sans-serif; letter-spacing: .14em; }
.brand-symbol {
  position: relative;
  display: grid;
  place-items: center;
  flex: none;
  width: 40px;
  height: 40px;
  padding-right: 3px;
  border-radius: 11px;
  background: var(--navy);
  color: #edf8f6;
  font: 760 25px/1 system-ui, sans-serif;
}
.brand-symbol span { position: absolute; top: 4px; right: 4px; color: #77dfd8; font: 750 10px/1 system-ui, sans-serif; }
header nav { display: flex; align-items: center; gap: clamp(16px, 3vw, 34px); font-size: .875rem; }
header nav > a:hover, footer > a:last-child:hover, .quiet-link:hover { color: var(--teal); }
.nav-list, .button, .feature-play, .card-play, .round-button {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 9px;
  border: 1px solid transparent;
  border-radius: 10px;
  min-height: 40px;
  padding: 9px 14px;
  font-size: .875rem;
  font-weight: 700;
  line-height: 1.4;
}
.nav-list { border-color: var(--line); background: var(--white); white-space: nowrap; }
.nav-list span { min-width: 22px; padding: 3px; border-radius: 6px; background: var(--teal-soft); color: var(--teal); }
.button { min-height: 47px; padding: 11px 18px; }
.primary, .feature-play { background: var(--navy); color: var(--white); }
.primary:hover, .feature-play:hover { background: var(--teal); }
.secondary, .card-play, .round-button { border-color: #c4d9d7; background: var(--teal-soft); color: #075760; }
.secondary:hover, .card-play:hover, .round-button:hover { background: #d5ebe6; }

.hero {
  position: relative;
  isolation: isolate;
  display: grid;
  grid-template-columns: minmax(0, 4fr) minmax(0, 6fr);
  align-items: center;
  gap: clamp(26px, 5vw, 80px);
  padding-block: clamp(35px, 5vw, 72px) 45px;
}
.hero::before {
  position: absolute;
  z-index: -1;
  inset: 0;
  content: "";
  background: radial-gradient(ellipse at 79% 10%, #ddecf0 0, transparent 70%);
  pointer-events: none;
}
.eyebrow {
  margin: 0 0 16px;
  color: var(--teal);
  font-size: .79rem;
  font-weight: 720;
  line-height: 1.5;
  letter-spacing: .08em;
}
.status-dot { display: inline-block; width: 7px; height: 7px; margin-right: 6px; border-radius: 50%; background: #00878c; }
.hero h1 {
  margin: 0;
  font-size: clamp(2.65rem, 5.4vw, 5.25rem);
  font-weight: 780;
  line-height: 1.1;
  letter-spacing: -.07em;
}
.accent, .contact-copy h2 span { color: var(--teal); }
.hero-desc { max-width: 28em; margin: 20px 0 23px; color: var(--muted); font-size: 1rem; line-height: 1.8; }
.hero-actions { display: flex; flex-wrap: wrap; align-items: center; gap: 16px; }
.quiet-link { color: var(--muted); font-size: .875rem; text-underline-offset: 4px; }
.quiet-link:hover { text-decoration: underline; }
.hero-stats { display: flex; gap: clamp(10px, 2vw, 25px); margin-top: 31px; }
.hero-stats > div + div { border-left: 1px solid #cbdad7; padding-left: clamp(10px, 2vw, 24px); }
.hero-stats strong { display: block; font-size: clamp(1.54rem, 2.8vw, 2.4rem); font-variant-numeric: tabular-nums; line-height: 1.1; }
.hero-stats span { display: block; margin-top: 5px; color: var(--muted); font-size: .78rem; white-space: nowrap; }
.hero-art { min-width: 0; overflow: hidden; border: 1px solid #ccdbda; border-radius: 21px; background: var(--white); box-shadow: var(--shadow); }
.hero-cover { display: block; width: 100%; aspect-ratio: 16 / 10; padding: 0; border: 0; overflow: hidden; background: var(--navy); }
.hero-cover:focus-visible, .card-image:focus-visible { outline-offset: -4px; }
.hero-cover img, .card-image img { width: 100%; height: 100%; object-fit: cover; }
.hero-caption { display: flex; align-items: center; justify-content: space-between; gap: 12px; padding: 14px 19px; }
.hero-caption p { margin: 0 0 3px; color: var(--amber); font-size: .77rem; font-weight: 680; }
.hero-caption h2 { margin: 0; font-size: clamp(1rem, 2vw, 1.38rem); }
.feature-title, .card-title-row h3 button { padding: 0; border: 0; background: none; text-align: left; font: inherit; }
.feature-title:hover, .card-title-row h3 button:hover { color: var(--teal); }

.spotlight-band { display: flex; align-items: center; gap: 18px; padding-block: 0 31px; }
.spotlight-heading { font-size: .86rem; font-weight: 720; white-space: nowrap; }
#spotlight-games { flex: 1; min-width: 0; display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 10px; }
.spotlight-card {
  min-width: 0;
  display: flex;
  align-items: center;
  gap: 12px;
  padding: 8px;
  border-radius: 12px;
  border: 1px solid var(--line);
  background: #fbfcfa;
  text-align: left;
}
.spotlight-card:hover, .game-card:hover { border-color: #8ebbb8; }
.spotlight-card img { width: 63px; aspect-ratio: 4 / 3; object-fit: cover; border-radius: 6px; }
.spotlight-card small { display: block; color: var(--teal); font-size: .72rem; }
.spotlight-card strong { font-size: .9rem; }

.section { padding-block: 44px; }
.section h2 { margin: 0; font-size: clamp(1.65rem, 3vw, 2.55rem); letter-spacing: -.035em; line-height: 1.3; }
.section-top { display: flex; flex-wrap: wrap; justify-content: space-between; align-items: center; gap: 10px; margin-bottom: 22px; }
.text-button, .clear-filters { border: 0; background: none; color: var(--teal); font-size: .875rem; font-weight: 700; }
.text-button { padding: 6px 0; }
.text-button span { margin-left: 7px; }
.catalog-layout { display: grid; grid-template-columns: 178px minmax(0, 1fr); gap: 24px; align-items: start; }
.catalog-sidebar { min-width: 0; border: 1px solid var(--line); border-radius: 14px; padding: 13px; background: #fcfdfa; }
.sidebar-title { margin: 4px 7px 11px; font-size: .88rem; font-weight: 760; }
.filters { display: grid; gap: 4px; }
.filter {
  display: flex;
  justify-content: space-between;
  gap: 8px;
  padding: 8px 9px;
  border: 1px solid transparent;
  border-radius: 8px;
  background: none;
  color: var(--muted);
  font-size: .82rem;
  text-align: left;
  white-space: nowrap;
}
.filter:hover, .filter.active { border-color: #afd3cd; background: var(--teal-soft); color: #075760; }
.filter.active { font-weight: 700; }
.catalog-content { min-width: 0; }
.toolbar, .facet-row { display: flex; align-items: center; flex-wrap: wrap; gap: 10px 15px; }
.facet-row { margin-top: 12px; padding-bottom: 13px; border-bottom: 1px solid var(--line); }
.search {
  display: flex;
  flex: 1 1 240px;
  align-items: center;
  gap: 8px;
  min-width: 0;
  padding-inline: 11px;
  border: 1px solid var(--line);
  border-radius: 9px;
  background: var(--white);
}
.search span { color: var(--teal); font-size: 1.3rem; }
.search input { width: 100%; min-width: 0; min-height: 41px; border: 0; background: none; }
.search input::placeholder { color: #5e7278; }
.select-field { display: flex; align-items: center; gap: 6px; color: var(--muted); font-size: .82rem; }
.select-field select { min-height: 38px; max-width: 100%; padding-inline: 8px; border: 1px solid var(--line); border-radius: 8px; background: var(--white); }
.results, .collection-note { margin-block: 13px; color: var(--muted); font-size: .83rem; line-height: 1.6; }
.game-grid { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 16px; }
.game-card { min-width: 0; display: flex; flex-direction: column; overflow: hidden; border: 1px solid var(--line); border-radius: 15px; background: var(--white); }
.card-image { position: relative; width: 100%; aspect-ratio: 16 / 10; padding: 0; border: 0; background: #dae7e9; }
.game-card[data-orientation="竖屏"] .card-image img { object-fit: contain; }
.preview-chip {
  position: absolute;
  left: 9px;
  bottom: 9px;
  padding: 5px 8px;
  border: 1px solid #ffffff65;
  border-radius: 7px;
  background: #173548ef;
  color: var(--white);
  font-size: .74rem;
  font-weight: 680;
}
.preview-chip i { display: inline-block; width: 6px; height: 6px; margin-right: 2px; border-radius: 50%; background: #77dfd8; }
.card-open { display: none; }
.card-body { display: flex; flex: 1; flex-direction: column; padding: 13px; }
.card-meta, .tags { display: flex; flex-wrap: wrap; gap: 5px 7px; }
.card-meta { margin-bottom: 6px; color: var(--muted); font-size: .74rem; }
.card-meta span + span::before { content: "·"; padding-right: 7px; color: #6b8588; }
.card-title-row { display: flex; align-items: center; justify-content: space-between; gap: 7px; }
.card-title-row h3 { margin: 0; font-size: 1.13rem; line-height: 1.35; }
.save { flex: none; width: 32px; height: 32px; padding: 0; border: 1px solid var(--line); border-radius: 8px; background: var(--white); color: var(--teal); font-size: 1.1rem; }
.save[aria-pressed="true"] { background: var(--teal-soft); border-color: #a5cfc8; }
.card-body p { margin: 9px 0; color: var(--muted); font-size: .85rem; line-height: 1.65; }
.tags { margin-bottom: 13px; }
.tags span { padding: 3px 6px; border-radius: 5px; background: #eaf2f1; color: #37555f; font-size: .72rem; }
.card-bottom { display: flex; flex-wrap: wrap; justify-content: space-between; align-items: center; gap: 7px; margin-top: auto; padding-top: 10px; border-top: 1px solid var(--line); }
.card-bottom button, .compare-tray > button:not(.primary) { padding: 4px 0; border: 0; background: none; color: var(--muted); font-size: .8rem; }
.card-bottom button[aria-pressed="true"] { color: var(--teal); font-weight: 700; }
.card-play { min-height: 35px; padding: 5px 9px; font-size: .8rem; }
.empty, .load-error { padding: 28px 12px; border: 1px solid var(--line); border-radius: 12px; text-align: center; background: var(--white); }
.pagination { display: flex; justify-content: center; gap: 7px; margin-top: 20px; }
.pagination button { min-width: 36px; min-height: 36px; border: 1px solid var(--line); border-radius: 8px; background: var(--white); }
.pagination button[aria-current] { background: var(--navy); color: var(--white); }

.continuation { width: min(calc(100% - 2 * var(--gutter)), 1288px); padding: 24px; border-block: 1px solid var(--line); text-align: center; }
.continuation h2 { font-size: clamp(1rem, 2vw, 1.35rem); }
.continuation p { margin: 7px 0 0; color: var(--muted); font-size: .84rem; }
.approach { display: grid; grid-template-columns: 1fr 1fr; gap: 34px; padding-block: 65px; }
.guide-heading > p:last-child, .guide-steps p, .contact-copy p { color: var(--muted); line-height: 1.7; }
.guide-steps article { padding: 0 0 14px 14px; border-left: 2px solid #b6d9d2; }
.guide-steps h3 { margin: 0 0 5px; font-size: 1rem; }
.guide-steps p { margin: 0; font-size: .9rem; }
.closing.contact {
  width: min(calc(100% - 2 * var(--gutter)), 1288px);
  padding: clamp(30px, 5vw, 62px) 20px;
  border: 1px solid #c6ddda;
  border-radius: 24px;
  background: radial-gradient(ellipse at 50% 0, #fff, #e6f2ef 69%, #dcecec);
  text-align: center;
}
.contact-copy { max-width: 620px; margin-inline: auto; }
.contact-copy .eyebrow { color: var(--teal); }
.contact-intro { margin: 15px 0 0; }
.contact-note { margin: 4px 0 20px; font-size: .86rem; }
footer { flex-wrap: wrap; min-height: 110px; padding-block: 20px; }
footer p, footer > a:last-child { color: var(--muted); font-size: .82rem; line-height: 1.65; }

dialog {
  width: min(940px, calc(100% - 22px));
  max-height: 91dvh;
  overflow: auto;
  padding: clamp(18px, 3vw, 37px);
  border: 1px solid #bdd3d2;
  border-radius: 18px;
  background: var(--white);
  color: var(--ink);
  box-shadow: 0 25px 95px #102d4260;
}
dialog::backdrop { background: #12334793; backdrop-filter: blur(4px); }
body:has(dialog[open]) { overflow: hidden; }
dialog h2 { margin: 0 30px 16px 0; font-size: clamp(1.35rem, 3vw, 2rem); }
.close { position: absolute; z-index: 2; right: 11px; top: 11px; width: 35px; height: 35px; padding: 0; border: 1px solid #bdd3d2; border-radius: 9px; color: var(--navy); background: #eaf5f2; font-size: 1.35rem; }
#detail-dialog { width: min(1100px, calc(100% - 22px)); }
.detail-layout { display: grid; grid-template-columns: minmax(0, 1.2fr) minmax(0, 1fr); gap: 19px; }
.gallery-stage { position: relative; display: grid; place-items: center; aspect-ratio: 16 / 10; overflow: hidden; border-radius: 11px; background: #1a3c50; }
.gallery-stage img, .gallery-stage video { width: 100%; height: 100%; min-height: 0; object-fit: contain; }
.gallery-expand { position: absolute; right: 8px; bottom: 8px; width: 34px; height: 34px; border: 1px solid #b8d5d8; border-radius: 8px; background: var(--white); color: var(--navy); }
.gallery-thumbs { display: flex; flex-wrap: wrap; gap: 6px; }
.gallery-thumbs button { width: 62px; height: 42px; padding: 0; overflow: hidden; border: 2px solid transparent; border-radius: 6px; background: #ebf1f2; }
.gallery-thumbs button.active { border-color: var(--teal); }
.gallery-thumbs img { width: 100%; height: 100%; object-fit: cover; }
.gallery-caption, .demo-hint, .fine-print, #expanded-caption { color: var(--muted); font-size: .8rem; line-height: 1.6; }
.detail-section-label { margin: 0 0 7px; color: var(--teal); font-size: .82rem; font-weight: 740; }
.detail-description, .detail-features, .detail-note, .controls-note { color: var(--muted); font-size: .88rem; line-height: 1.68; }
.detail-description { margin: 0 0 10px; }
.detail-features { margin: 0 0 12px; padding: 0; list-style: none; }
.detail-features li { display: flex; gap: 9px; padding: 6px 0; border-bottom: 1px solid var(--line); }
.detail-features span { color: var(--teal); }
.detail-note, .controls-note { padding: 10px 12px; border-radius: 8px; background: var(--teal-soft); }
.detail-note { margin-top: 15px; }
.controls-note { margin-bottom: 12px; }
.controls-note p { margin: 3px 0 0; }
.demo-link, #detail-save { display: flex; width: 100%; }
.demo-hint { text-align: center; }
#image-dialog { width: min(1200px, calc(100% - 16px)); padding: 12px; text-align: center; }
#expanded-image { margin-inline: auto; max-height: 76dvh; object-fit: contain; }
.table-scroll { overflow-x: auto; border: 1px solid var(--line); border-radius: 9px; }
table { width: 100%; min-width: 540px; border-collapse: collapse; color: var(--muted); font-size: .85rem; line-height: 1.5; }
th, td { padding: 10px 12px; border-bottom: 1px solid var(--line); text-align: left; }
thead { background: var(--navy); color: var(--white); }
tbody th { background: #eaf3f1; color: var(--ink); }
.shortlist-item { display: flex; align-items: center; gap: 10px; padding: 9px 0; border-bottom: 1px solid var(--line); }
.shortlist-item img { width: 62px; aspect-ratio: 4 / 3; border-radius: 6px; object-fit: cover; }
.shortlist-item h3, .shortlist-item p { margin: 0; }
.shortlist-item p, .list-empty { color: var(--muted); font-size: .85rem; line-height: 1.6; }
.shortlist-item button { margin-left: auto; border: 0; background: none; color: var(--teal); white-space: nowrap; }
.list-actions { display: flex; flex-wrap: wrap; gap: 8px; margin-top: 15px; }
.compare-tray, .toast {
  position: fixed;
  z-index: 5;
  bottom: 12px;
  left: 50%;
  max-width: calc(100% - 24px);
  transform: translateX(-50%);
  padding: 8px 12px;
  border-radius: 11px;
  border: 1px solid #a7cbc7;
  font-size: .8rem;
}
.compare-tray { display: flex; align-items: center; gap: 9px; background: var(--white); box-shadow: var(--shadow); }
.compare-tray .button { min-height: 36px; padding: 7px 9px; white-space: nowrap; }
.toast { z-index: 6; bottom: 67px; background: var(--navy); color: var(--white); opacity: 0; pointer-events: none; }
.toast.show { opacity: 1; }

@media (max-width: 1060px) {
  .game-grid { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .catalog-layout { grid-template-columns: 149px minmax(0, 1fr); gap: 15px; }
  .hero { gap: 22px; }
}
@media (max-width: 700px) {
  header { min-height: 64px; }
  header nav > a { display: none; }
  .brand { font-size: 1.05rem; }
  .brand-symbol { width: 36px; height: 36px; }
  .hero { grid-template-columns: minmax(0, 1fr); padding-block: 28px 19px; gap: 20px; }
  .hero h1 { font-size: clamp(2.4rem, 11vw, 3.7rem); }
  .hero-desc { margin: 12px 0 16px; font-size: .9rem; }
  .hero-stats { margin-top: 18px; }
  .hero-caption { padding: 9px 12px; }
  .hero-art { border-radius: 15px; }
  .spotlight-band { display: block; padding-bottom: 12px; }
  .spotlight-heading { margin-bottom: 8px; }
  #spotlight-games { grid-template-columns: repeat(3, minmax(146px, 1fr)); overflow-x: auto; padding-bottom: 4px; }
  .spotlight-card { gap: 7px; padding: 6px; }
  .spotlight-card img { width: 45px; }
  .spotlight-card strong { font-size: .8rem; }
  .section { padding-block: 24px; }
  .catalog-layout, .approach, .detail-layout { grid-template-columns: minmax(0, 1fr); gap: 13px; }
  .catalog-sidebar .filters { display: flex; overflow-x: auto; padding-bottom: 4px; }
  .catalog-sidebar { padding: 7px; }
  .sidebar-title { margin: 3px 6px 5px; }
  .search { flex-basis: 100%; }
  .game-grid { grid-template-columns: minmax(0, 1fr); }
  .approach { padding-block: 35px; }
  .closing.contact { border-radius: 16px; }
  footer p { order: 3; width: 100%; margin: 0; }
  dialog { max-height: 88dvh; }
}
