/* 承天传奇官网 · 移动端 H5
   与桌面端共用同一套配色与图片资源，布局按单手竖向浏览重排。 */

:root {
  --ink: #0a0705;
  --ink-soft: #120c07;
  --line: rgba(242, 201, 107, 0.16);
  --line-strong: rgba(242, 201, 107, 0.42);
  --gold: #f2c96b;
  --gold-deep: #c9902c;
  --text: #efe4d3;
  --muted: #a1947f;
  --bar-h: 62px;
}

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

body {
  margin: 0;
  background: var(--ink);
  color: var(--text);
  font: 15px/1.8 "Microsoft YaHei", "PingFang SC", "Hiragino Sans GB", "Noto Sans SC", sans-serif;
  -webkit-font-smoothing: antialiased;
  -webkit-tap-highlight-color: transparent;
  padding-bottom: calc(var(--bar-h) + env(safe-area-inset-bottom, 0px));
}

img {
  max-width: 100%;
}

a {
  color: inherit;
  text-decoration: none;
}

ul {
  margin: 0;
  padding: 0;
  list-style: none;
}

h1,
h2,
h3,
p {
  margin: 0;
}

.h5 {
  max-width: 560px;
  margin: 0 auto;
  overflow-x: hidden;
}

/* ---------------------------------------------------------------- header */

.h5-head {
  position: relative;
  z-index: 2;
  display: flex;
  align-items: center;
  gap: 12px;
  padding: 14px 16px;
  background: linear-gradient(180deg, rgba(9, 6, 3, 0.98), rgba(9, 6, 3, 0.82));
  border-bottom: 1px solid var(--line);
}

.h5-head img {
  width: 32px;
  height: 32px;
  border-radius: 8px;
  box-shadow: 0 0 0 1px var(--line-strong);
}

.h5-head__name {
  font-family: "STZhongsong", "Songti SC", "SimSun", serif;
  font-size: 19px;
  font-weight: 700;
  letter-spacing: 0.12em;
  background: linear-gradient(180deg, #ffe9ab, #f3c45c 55%, #bb7a1c);
  -webkit-background-clip: text;
  background-clip: text;
  color: transparent;
}

.h5-head__slogan {
  display: block;
  font-size: 11px;
  letter-spacing: 0.06em;
  color: var(--muted);
}

/* ------------------------------------------------------------ marquee */

.h5-marquee {
  display: flex;
  align-items: center;
  gap: 10px;
  padding: 9px 14px;
  font-size: 12px;
  color: #e3d0a8;
  background: rgba(255, 150, 50, 0.08);
  border-bottom: 1px solid var(--line);
  overflow: hidden;
}

.h5-marquee__tag {
  flex: none;
  padding: 2px 8px;
  font-size: 11px;
  letter-spacing: 0.1em;
  color: #2a1600;
  background: linear-gradient(180deg, #ffe190, #d99a26);
  border-radius: 3px;
}

.h5-marquee__viewport {
  overflow: hidden;
  white-space: nowrap;
}

.h5-marquee__text {
  display: inline-block;
  padding-left: 100%;
  animation: h5-marquee 26s linear infinite;
}

@keyframes h5-marquee {
  from {
    transform: translateX(0);
  }
  to {
    transform: translateX(-100%);
  }
}

/* ------------------------------------------------------------------ hero */

.h5-hero {
  position: relative;
  padding: 30px 18px 0;
  text-align: center;
  overflow: hidden;
  background:
    radial-gradient(560px 320px at 50% 0, rgba(255, 138, 40, 0.24), transparent 68%),
    var(--ink);
}

.h5-hero__sky {
  position: absolute;
  top: 0;
  left: 0;
  width: 100%;
  height: 200px;
  /* 首屏天空图来自后台（siteContent → PC 首屏 → 首屏背景图），
     由页面写成 --h5-sky 变量；改名/换图后台改一次即可，不再硬编码路径。 */
  background-image: var(--h5-sky, none);
  background-position: center top;
  background-size: cover;
  background-repeat: no-repeat;
  -webkit-mask-image: linear-gradient(180deg, #000 0%, rgba(0, 0, 0, 0.5) 62%, transparent 100%);
  mask-image: linear-gradient(180deg, #000 0%, rgba(0, 0, 0, 0.5) 62%, transparent 100%);
  opacity: 0.9;
}

.h5-hero__inner {
  position: relative;
  z-index: 2;
}

.h5-hero__title {
  font-family: "STZhongsong", "Songti SC", "SimSun", serif;
  font-size: 42px;
  line-height: 1.15;
  letter-spacing: 0.12em;
  text-indent: 0.12em;
  background: linear-gradient(180deg, #fff2c8 4%, #f6cd6c 46%, #d1932a 70%, #ffe8ad 96%);
  -webkit-background-clip: text;
  background-clip: text;
  color: transparent;
  filter: drop-shadow(0 8px 20px rgba(255, 120, 30, 0.35));
}

.h5-hero__sub {
  margin-top: 8px;
  font-size: 13px;
  letter-spacing: 0.24em;
  color: #e5cf9f;
}

.h5-tags {
  display: flex;
  flex-wrap: wrap;
  justify-content: center;
  gap: 8px;
  margin-top: 16px;
}

.h5-tags li {
  padding: 5px 12px;
  font-size: 12px;
  letter-spacing: 0.06em;
  color: #e9d7b3;
  border: 1px solid var(--line);
  border-radius: 999px;
  background: rgba(255, 255, 255, 0.04);
}

.h5-hero__lead {
  margin-top: 16px;
  font-size: 13px;
  line-height: 1.95;
  color: #bfb09a;
}

.h5-hero__actions {
  display: grid;
  gap: 10px;
  margin-top: 20px;
}

.h5-btn {
  display: block;
  padding: 13px 18px;
  border: 1px solid transparent;
  border-radius: 8px;
  font-size: 16px;
  font-weight: 700;
  letter-spacing: 0.08em;
  text-align: center;
}

.h5-btn small {
  display: block;
  margin-top: 2px;
  font-size: 11px;
  font-weight: 500;
  opacity: 0.75;
}

.h5-btn--gold {
  color: #2a1600;
  background: linear-gradient(180deg, #ffe190, #e2a52f 55%, #b8741a);
  box-shadow: 0 12px 28px -16px rgba(255, 170, 60, 0.95), inset 0 1px 0 rgba(255, 255, 255, 0.5);
}

.h5-btn--ghost {
  color: #f0dcb4;
  border-color: var(--line-strong);
  background: rgba(12, 8, 5, 0.6);
}

.h5-band {
  margin-top: 22px;
}

.h5-band img {
  display: block;
  width: 100%;
  -webkit-mask-image: linear-gradient(180deg, transparent 0%, #000 18%, #000 84%, transparent 100%);
  mask-image: linear-gradient(180deg, transparent 0%, #000 18%, #000 84%, transparent 100%);
}

/* --------------------------------------------------------------- blocks */

.h5-block {
  padding: 34px 18px;
  border-top: 1px solid rgba(242, 201, 107, 0.08);
}

.h5-block--soft {
  background: linear-gradient(180deg, var(--ink), var(--ink-soft) 50%, var(--ink));
}

.h5-title {
  display: flex;
  align-items: baseline;
  gap: 10px;
  margin-bottom: 18px;
}

.h5-title h2 {
  font-family: "STZhongsong", "Songti SC", "SimSun", serif;
  font-size: 22px;
  letter-spacing: 0.14em;
  color: #f8ecd4;
}

.h5-title span {
  font-size: 11px;
  letter-spacing: 0.24em;
  text-transform: uppercase;
  color: var(--gold-deep);
}

.h5-lead {
  padding-left: 14px;
  border-left: 3px solid rgba(242, 201, 107, 0.5);
  font-size: 15px;
  line-height: 1.9;
  color: #ecdfc6;
}

.h5-para {
  margin-top: 12px;
  font-size: 13px;
  line-height: 1.95;
  color: var(--muted);
}

.h5-promise {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  margin-top: 14px;
}

.h5-promise li {
  padding: 5px 12px;
  font-size: 12px;
  letter-spacing: 0.08em;
  color: #f0dcb4;
  border: 1px solid rgba(242, 201, 107, 0.28);
  border-radius: 999px;
  background: rgba(10, 7, 5, 0.6);
}

.h5-points {
  display: grid;
  gap: 10px;
  margin-top: 18px;
}

.h5-point {
  position: relative;
  padding: 16px 16px 16px 18px;
  border: 1px solid var(--line);
  border-left: 3px solid rgba(242, 201, 107, 0.45);
  border-radius: 8px;
  background: linear-gradient(160deg, rgba(255, 190, 90, 0.08), rgba(255, 255, 255, 0.015));
}

.h5-point h3 {
  font-size: 15px;
  letter-spacing: 0.06em;
  color: var(--gold);
}

.h5-point p {
  margin-top: 6px;
  font-size: 13px;
  line-height: 1.85;
  color: var(--muted);
}

/* --------------------------------------------------------------- gallery */

.h5-gallery {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 10px;
}

.h5-shot {
  padding: 0;
  border: 1px solid var(--line);
  border-radius: 8px;
  overflow: hidden;
  background: #0c0805;
}

.h5-shot img {
  display: block;
  width: 100%;
  aspect-ratio: 3 / 4;
  object-fit: cover;
}

/* -------------------------------------------------------------- download */

.h5-dl {
  display: grid;
  gap: 10px;
}

.h5-dl-card {
  display: flex;
  align-items: center;
  gap: 14px;
  padding: 16px;
  border: 1px solid var(--line);
  border-radius: 10px;
  background: linear-gradient(160deg, rgba(255, 190, 90, 0.08), rgba(255, 255, 255, 0.015));
}

.h5-dl-card__body {
  flex: 1;
  min-width: 0;
}

.h5-dl-card b {
  display: block;
  font-size: 15px;
  letter-spacing: 0.06em;
  color: #f4e6cb;
}

.h5-dl-card span {
  display: block;
  margin-top: 3px;
  font-size: 12px;
  color: var(--muted);
}

.h5-dl-card__go {
  flex: none;
  padding: 9px 16px;
  font-size: 13px;
  font-weight: 700;
  color: #2a1600;
  border-radius: 999px;
  background: linear-gradient(180deg, #ffe190, #e2a52f 60%, #b8741a);
}

.h5-notice {
  margin-top: 14px;
  font-size: 12px;
  line-height: 1.9;
  color: var(--muted);
}

/* ---------------------------------------------------------------- footer */

.h5-foot {
  padding: 26px 18px 30px;
  border-top: 1px solid var(--line);
  background: #070504;
  font-size: 12px;
  line-height: 2;
  color: #8d8172;
  text-align: center;
}

.h5-foot a {
  color: #a8987f;
}

.h5-foot__brand {
  font-family: "STZhongsong", "Songti SC", serif;
  font-size: 16px;
  letter-spacing: 0.12em;
  color: #d8c39a;
}

.h5-auth {
  margin: 16px auto;
  padding: 14px;
  border: 1px solid var(--line);
  border-radius: 10px;
  background: linear-gradient(160deg, rgba(255, 190, 90, 0.08), rgba(255, 255, 255, 0.015));
}

.h5-auth__frame {
  display: block;
  width: 190px;
  margin: 0 auto 10px;
  aspect-ratio: 4 / 3;
  border: 1px solid var(--line);
  border-radius: 8px;
  overflow: hidden;
  background: #0d0906;
}

.h5-auth__frame img {
  display: block;
  width: 100%;
  height: 100%;
  object-fit: contain;
}

.h5-auth b {
  display: block;
  font-size: 14px;
  letter-spacing: 0.1em;
  color: var(--gold);
}

.h5-auth span {
  display: block;
  margin-top: 6px;
  font-size: 12px;
  line-height: 1.8;
  color: var(--muted);
}

/* ------------------------------------------------------------- bottom bar */

.h5-bar {
  position: fixed;
  inset: auto 0 0;
  z-index: 50;
  display: flex;
  gap: 8px;
  max-width: 560px;
  margin: 0 auto;
  padding: 8px 12px calc(8px + env(safe-area-inset-bottom, 0px));
  background: rgba(9, 6, 3, 0.94);
  backdrop-filter: blur(10px);
  border-top: 1px solid var(--line);
}

.h5-bar .h5-btn {
  flex: 1;
  padding: 11px 8px;
  font-size: 14px;
}

/* -------------------------------------------------------------- lightbox */

.lightbox {
  position: fixed;
  inset: 0;
  z-index: 100;
  display: none;
  place-items: center;
  padding: 4vh 12px;
  background: rgba(4, 3, 2, 0.95);
}

.lightbox.is-open {
  display: grid;
}

.lightbox img {
  width: auto;
  height: min(72vh, 620px);
  max-width: 88vw;
  border: 1px solid var(--line-strong);
  border-radius: 8px;
}

.lightbox__nav {
  position: absolute;
  top: 50%;
  transform: translateY(-50%);
  width: 40px;
  height: 40px;
  border: 1px solid var(--line-strong);
  border-radius: 50%;
  background: rgba(16, 11, 7, 0.85);
  color: var(--gold);
  font-size: 18px;
}

.lightbox__nav--prev {
  left: 8px;
}

.lightbox__nav--next {
  right: 8px;
}

.lightbox__close {
  position: absolute;
  top: 18px;
  right: 14px;
  width: 40px;
  height: 40px;
  border: 1px solid var(--line-strong);
  border-radius: 50%;
  background: rgba(16, 11, 7, 0.85);
  color: #f0dcb4;
  font-size: 18px;
}

.lightbox__count {
  position: absolute;
  bottom: 22px;
  left: 50%;
  transform: translateX(-50%);
  font-size: 12px;
  letter-spacing: 0.2em;
  color: rgba(242, 201, 107, 0.8);
}

@media (prefers-reduced-motion: reduce) {
  .h5-marquee__text {
    animation: none;
    padding-left: 0;
  }
}
