:root {
  --page: #eef3f9;
  --panel: #ffffff;
  --ink: #172033;
  --muted: #5e6b82;
  --blue: #1668ff;
  --blue-2: #3ca7ff;
  --cyan: #2de0ff;
  --red: #ff2727;
  --shadow: 0 20px 50px rgba(38, 69, 120, .14);
}

* {
  box-sizing: border-box;
}

html {
  min-height: 100%;
  background: var(--page);
}

body {
  min-height: 100%;
  margin: 0;
  color: var(--ink);
  font-family: "Microsoft YaHei", "PingFang SC", "Noto Sans SC", sans-serif;
  background:
    linear-gradient(180deg, rgba(255,255,255,.92), rgba(238,243,249,.95) 36%, #e8eef7 100%),
    radial-gradient(circle at 15% 20%, rgba(22,104,255,.12), transparent 28%),
    radial-gradient(circle at 83% 12%, rgba(45,224,255,.12), transparent 24%);
}

a {
  color: inherit;
}

button {
  font: inherit;
}

.live-page {
  width: 100%;
  max-width: 940px;
  margin: 0 auto;
  padding: 24px 20px 40px;
}

.player-shell {
  width: 100%;
  max-width: 100%;
  margin: 0 auto 32px;
}

.mobile-access-notice {
  display: none;
  align-items: center;
  justify-content: space-between;
  gap: 14px;
  margin-bottom: 12px;
  padding: 14px 16px;
  border: 1px solid rgba(22,104,255,.14);
  border-radius: 8px;
  background: rgba(255,255,255,.92);
  box-shadow: var(--shadow);
}

.mobile-access-notice p {
  margin: 0;
  color: #172033;
  font-size: 15px;
  font-weight: 700;
}

.mobile-access-notice button {
  flex: 0 0 auto;
  min-height: 38px;
  padding: 0 14px;
  border: 0;
  border-radius: 8px;
  color: #fff;
  background: #1668ff;
  font-size: 14px;
  font-weight: 700;
  cursor: pointer;
  box-shadow: 0 10px 18px rgba(22,104,255,.2);
}

.mobile-access-notice button:active {
  transform: translateY(1px);
}

.live-page.is-mobile-mode .mobile-access-notice {
  display: flex;
}

.live-page.is-mobile-mode .center-play,
.live-page.is-mobile-mode .player-controls,
.live-page.is-mobile-mode .playlist {
  display: none;
}

/* 播放列表 */
.playlist {
  margin-top: 12px;
  border-radius: 8px;
  background: rgba(255,255,255,.86);
  box-shadow: var(--shadow);
  backdrop-filter: blur(16px);
  overflow: hidden;
}

.playlist-title {
  margin: 0;
  padding: 14px 20px 10px;
  color: #161f31;
  font-size: 15px;
  font-weight: 700;
  border-bottom: 1px solid #e8ecf3;
}

.playlist-items {
  list-style: none;
  margin: 0;
  padding: 0;
}

.playlist-item {
  display: flex;
  align-items: center;
  gap: 12px;
  padding: 12px 20px;
  cursor: pointer;
  transition: background .15s;
  border-bottom: 1px solid #f2f4f8;
}

.playlist-item:last-child {
  border-bottom: 0;
}

.playlist-item:hover {
  background: #f3f6fc;
}

.playlist-item.active {
  background: #e8f1ff;
}

.playlist-item.active .playlist-name {
  color: #1668ff;
}

.playlist-item.active .playlist-icon {
  display: block;
  color: #1668ff;
}

.playlist-num {
  width: 26px;
  height: 26px;
  display: flex;
  align-items: center;
  justify-content: center;
  border-radius: 4px;
  background: #e8ecf3;
  color: #5e6b82;
  font-size: 12px;
  font-weight: 700;
  flex-shrink: 0;
}

.playlist-item.active .playlist-num {
  background: #1668ff;
  color: #fff;
}

.playlist-name {
  flex: 1;
  color: #3d485e;
  font-size: 14px;
  font-weight: 600;
}

.playlist-icon {
  display: none;
  width: 18px;
  height: 18px;
  flex-shrink: 0;
}

.player-stage {
  position: relative;
  width: 100%;
  max-width: 100%;
  overflow: hidden;
  isolation: isolate;
  aspect-ratio: 16 / 9;
  border: 1px solid rgba(255, 255, 255, .14);
  border-radius: 8px;
  background: #000;
  box-shadow:
    0 2px 0 rgba(255,255,255,.36) inset,
    0 26px 54px rgba(2, 12, 35, .28);
}

.player-stage::before {
  content: "";
  display: block;
  padding-top: 56.25%;
}

.main-video {
  position: absolute;
  inset: 0;
  display: block;
  width: 100%;
  height: 100%;
  max-width: 100%;
  background: #000;
  outline: none;
}

.top-meta,
.player-controls {
  position: absolute;
}

.video-poster {
  position: absolute;
  inset: 0;
  z-index: 3;
  overflow: hidden;
}

.video-poster img {
  display: block;
  width: 100%;
  height: 100%;
  max-width: 100%;
  min-width: 0;
  object-fit: cover;
}

.video-poster.hidden {
  display: none;
}

.center-play {
  position: absolute;
  inset: 0;
  z-index: 4;
  display: flex;
  align-items: center;
  justify-content: center;
  cursor: pointer;
  opacity: 1;
  transition: opacity .3s;
}

.center-play svg {
  width: 80px;
  height: 80px;
  filter: drop-shadow(0 4px 24px rgba(0,0,0,.5));
  transition: transform .2s;
}

.center-play:hover svg {
  transform: scale(1.1);
}

.player-stage.is-playing .center-play {
  opacity: 0;
  pointer-events: none;
}

.player-stage:not(.is-playing) .center-play {
  opacity: 1;
  pointer-events: auto;
}

.top-meta {
  top: 14px;
  left: 14px;
  display: flex;
  align-items: center;
  gap: 12px;
  z-index: 2;
}

.live-badge {
  display: inline-flex;
  align-items: center;
  height: 26px;
  padding: 0 14px;
  border-radius: 999px;
  color: #fff;
  background: #1768ff;
  font-size: 13px;
  font-weight: 700;
  line-height: 1;
}

.player-controls {
  left: 24px;
  right: 24px;
  bottom: 16px;
  z-index: 3;
  display: grid;
  grid-template-columns: 34px 34px minmax(80px, 1fr) auto auto 34px;
  align-items: center;
  gap: 10px;
}

.icon-button {
  display: inline-grid;
  place-items: center;
  min-width: 34px;
  height: 34px;
  border: 0;
  color: #fff;
  background: transparent;
  cursor: pointer;
}

.icon-button svg {
  width: 22px;
  height: 22px;
  fill: currentColor;
  stroke: currentColor;
  stroke-linecap: round;
  stroke-linejoin: round;
  stroke-width: 1.8;
}

.icon-button:hover {
  color: var(--cyan);
}

.play-icon,
.sound-off,
.player-stage.is-playing .pause-icon,
.player-stage.is-muted .sound-on {
  display: none;
}

.player-stage:not(.is-playing) .play-icon,
.player-stage.is-muted .sound-off {
  display: block;
}

.player-stage:not(.is-playing) .pause-icon {
  display: none;
}

.progress {
  position: relative;
  height: 4px;
  border-radius: 999px;
  background: rgba(255,255,255,.35);
  cursor: pointer;
}

.progress-fill {
  position: absolute;
  inset: 0 auto 0 0;
  width: 0%;
  border-radius: inherit;
  background: #1668ff;
  transition: width .15s linear;
}

.time-display {
  min-width: 13ch;
  color: rgba(255,255,255,.9);
  font-size: 12px;
  font-variant-numeric: tabular-nums;
  line-height: 1;
  text-align: center;
  white-space: nowrap;
}

.dot-live {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  color: #fff;
  font-size: 13px;
  white-space: nowrap;
}

.content-grid {
  display: grid;
  grid-template-columns: minmax(0, 1.1fr) minmax(280px, .85fr);
  gap: 24px;
  align-items: stretch;
}

.panel {
  min-width: 0;
  height: 100%;
  border-radius: 8px;
  background: rgba(255,255,255,.86);
  box-shadow: var(--shadow);
  backdrop-filter: blur(16px);
}

.intro-panel {
  display: flex;
  flex-direction: column;
  padding: 34px 36px;
}

.flow-panel {
  padding: 34px;
}

.panel h2 {
  margin: 0 0 22px;
  color: #161f31;
  font-size: 21px;
  letter-spacing: 0;
}

.intro-panel > p {
  max-width: 560px;
  margin: 0 0 30px;
  color: #3d485e;
  font-size: 15px;
  line-height: 1.9;
}

.platform-card {
  position: relative;
  display: flex;
  align-items: center;
  margin-top: auto;
  min-height: 148px;
  overflow: hidden;
  border-radius: 8px;
  padding: 28px 30px;
  background:
    linear-gradient(90deg, rgba(22,104,255,.1) 1px, transparent 1px) 0 0 / 28px 28px,
    linear-gradient(180deg, rgba(255,255,255,.88), rgba(255,255,255,.62)),
    linear-gradient(135deg, #d8e9ff 0%, #f5fbff 52%, #e0f2ff 100%);
  border: 1px solid rgba(22,104,255,.12);
}

.platform-copy {
  position: relative;
  z-index: 1;
  display: grid;
  width: 100%;
  grid-template-columns: minmax(0, 1fr) auto;
  grid-template-areas:
    "title action"
    "desc action";
  align-items: center;
  column-gap: 28px;
  row-gap: 10px;
}

.platform-copy h3 {
  grid-area: title;
  margin: 0;
  color: #173c8f;
  font-size: 25px;
  line-height: 1.24;
}

.platform-copy p {
  grid-area: desc;
  margin: 0;
  color: #24426d;
  font-size: 15px;
  font-weight: 700;
}

.primary-link {
  grid-area: action;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  min-height: 44px;
  min-width: 126px;
  padding: 0 20px;
  border-radius: 8px;
  color: #fff;
  background:
    linear-gradient(115deg, transparent 0%, transparent 35%, rgba(255,255,255,.58) 48%, transparent 62%, transparent 100%) -140% 0 / 90% 100% no-repeat,
    linear-gradient(135deg, #0d63ff, #0951d8);
  text-decoration: none;
  font-size: 15px;
  font-weight: 700;
  overflow: hidden;
  box-shadow: 0 12px 24px rgba(13, 99, 255, .28);
  transition: transform .25s ease, box-shadow .25s ease, background-position .55s ease;
}

.primary-link:hover {
  color: #fff;
  background-position: 220% 0, 0 0;
  transform: translateY(-2px);
  box-shadow: 0 16px 32px rgba(13, 99, 255, .34);
}

.primary-link:active {
  transform: translateY(0);
}

.primary-link svg {
  width: 17px;
  height: 17px;
  fill: none;
  stroke: currentColor;
  stroke-linecap: round;
  stroke-linejoin: round;
  stroke-width: 2;
  transition: transform .25s ease;
}

.primary-link:hover svg {
  transform: translateX(3px);
}

.flow-list {
  position: relative;
  display: grid;
  gap: 22px;
  margin: 0;
  padding: 0;
  list-style: none;
}

.flow-list::before {
  content: "";
  position: absolute;
  left: 12px;
  top: 26px;
  bottom: 26px;
  width: 2px;
  background: linear-gradient(180deg, rgba(22,104,255,.28), rgba(22,104,255,.04));
}

.flow-list li {
  position: relative;
  display: grid;
  grid-template-columns: 26px minmax(0, 1fr);
  gap: 16px;
}

.flow-list li > span {
  display: grid;
  place-items: center;
  width: 26px;
  height: 26px;
  border-radius: 50%;
  color: #fff;
  background: linear-gradient(135deg, #176bff, #2298ff);
  font-size: 13px;
  font-weight: 800;
  box-shadow: 0 8px 16px rgba(22,104,255,.22);
}

.flow-list strong {
  display: block;
  margin-bottom: 7px;
  color: #182236;
  font-size: 15px;
}

.flow-list p,
.flow-list a {
  margin: 0;
  color: #4c5b72;
  font-size: 13px;
  line-height: 1.65;
  word-break: break-word;
}

.flow-list a {
  color: #1466e8;
  text-decoration: none;
}

.player-stage.is-wide {
  /* 全屏时不做额外限制 */
}

@media (max-width: 820px) {
  .live-page {
    padding: 16px 12px 28px;
  }

  .content-grid {
    grid-template-columns: 1fr;
    gap: 18px;
  }
}

@media (max-width: 560px) {
  .mobile-access-notice {
    align-items: stretch;
    flex-direction: column;
  }

  .mobile-access-notice button {
    width: 100%;
  }

  .top-meta {
    top: 12px;
    left: 12px;
  }

  .live-badge {
    height: 22px;
    padding-inline: 10px;
    font-size: 12px;
  }

  .player-controls {
    left: 12px;
    right: 12px;
    bottom: 10px;
    grid-template-columns: 28px 28px minmax(58px, 1fr) auto auto 28px;
    gap: 5px;
  }

  .icon-button {
    min-width: 28px;
    height: 28px;
  }

  .icon-button svg {
    width: 18px;
    height: 18px;
  }

  .dot-live {
    font-size: 12px;
  }

  .time-display {
    min-width: 11ch;
    font-size: 11px;
  }

  .intro-panel,
  .flow-panel {
    padding: 24px 18px;
  }

  .panel h2 {
    margin-bottom: 16px;
    font-size: 18px;
  }

  .intro-panel > p {
    margin-bottom: 22px;
    font-size: 14px;
  }

  .platform-card {
    padding: 22px 18px;
  }

  .platform-copy {
    grid-template-columns: 1fr;
    grid-template-areas:
      "title"
      "desc"
      "action";
    row-gap: 12px;
  }

  .platform-copy h3 {
    font-size: 23px;
  }

  .primary-link {
    justify-self: start;
    margin-top: 4px;
  }

}
