:root {
  color-scheme: light;
  font-family: Arial, "Microsoft YaHei", sans-serif;
  background: #eef3f5;
  color: #082033;
}

* {
  box-sizing: border-box;
}

[hidden] {
  display: none !important;
}

body {
  margin: 0;
  min-height: 100vh;
  background: #eef3f5;
  overflow-x: hidden;
}

button {
  font: inherit;
}

.app {
  width: min(100%, 1180px);
  min-height: 100vh;
  margin: 0 auto;
  padding: 14px 14px 92px;
}

.rotatePrompt {
  display: none;
}

.topbar {
  position: sticky;
  top: 0;
  z-index: 4;
  display: flex;
  align-items: center;
  justify-content: flex-end;
  gap: 14px;
  padding: 8px 0 10px;
  background: rgba(238, 243, 245, 0.92);
  backdrop-filter: blur(16px);
}

.eyebrow,
.sectionLabel {
  margin: 0 0 4px;
  font-size: 12px;
  font-weight: 700;
  letter-spacing: 0;
  color: #00788d;
}

h1,
h2 {
  margin: 0;
  letter-spacing: 0;
}

h1 {
  font-size: 22px;
  line-height: 1.2;
}

h2 {
  font-size: 18px;
  line-height: 1.35;
}

.pill,
.status {
  flex: 0 0 auto;
  border: 1px solid rgba(8, 32, 51, 0.16);
  border-radius: 999px;
  padding: 7px 10px;
  font-size: 12px;
  font-weight: 700;
  color: #29445a;
  background: #ffffff;
}

.chapters,
.chapter {
  display: grid;
  gap: 14px;
}

.stage {
  display: grid;
  grid-template-columns: minmax(0, 68.4fr) minmax(180px, 31.6fr);
  align-items: stretch;
  aspect-ratio: 16 / 9;
  overflow: hidden;
  border: 1px solid rgba(8, 32, 51, 0.16);
  border-radius: 8px;
  background: #ffffff;
  box-shadow: 0 18px 46px rgba(8, 32, 51, 0.12);
}

.stage.isFullSlide {
  grid-template-columns: 1fr;
}

.stage.isFullSlide .slideImage {
  object-fit: contain;
}

.slidePane {
  position: relative;
  min-width: 0;
  margin: 0;
  background: #ffffff;
}

.slideImage {
  display: block;
  width: 100%;
  height: 100%;
  object-fit: contain;
  background: #ffffff;
}

.videoPane {
  position: relative;
  min-width: 0;
  overflow: hidden;
  background: #082033;
}

.video {
  display: block;
  width: 100%;
  height: 100%;
  min-height: 100%;
  aspect-ratio: 9 / 16;
  object-fit: cover;
  background: #082033;
}

.contentVideoLayer {
  position: absolute;
  overflow: hidden;
  background: #061827;
}

.contentVideoLayer .video {
  object-fit: cover;
}

.playButton {
  position: absolute;
  left: 50%;
  top: 50%;
  z-index: 2;
  width: 58px;
  height: 58px;
  transform: translate(-50%, -50%);
  border: 0;
  border-radius: 999px;
  background: rgba(255, 255, 255, 0.9);
  box-shadow: 0 12px 32px rgba(8, 32, 51, 0.24);
}

.playButton::before {
  content: "";
  position: absolute;
  left: 23px;
  top: 18px;
  width: 0;
  height: 0;
  border-top: 11px solid transparent;
  border-bottom: 11px solid transparent;
  border-left: 17px solid #00788d;
}

.playButton.isHidden {
  opacity: 0;
  pointer-events: none;
}

.dock {
  position: fixed;
  left: 50%;
  bottom: 16px;
  transform: translateX(-50%);
  z-index: 6;
  width: min(calc(100% - 28px), 520px);
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 10px;
  padding: 10px;
  border: 1px solid rgba(8, 32, 51, 0.16);
  border-radius: 8px;
  background: rgba(255, 255, 255, 0.92);
  backdrop-filter: blur(18px);
  box-shadow: 0 18px 46px rgba(8, 32, 51, 0.18);
}

.dock button {
  min-height: 44px;
  border: 0;
  border-radius: 7px;
  color: #ffffff;
  background: #082033;
  font-weight: 700;
}

.dock button:disabled {
  color: #6b7d8c;
  background: #dce7eb;
}

@media (max-width: 920px) and (orientation: landscape) {
  body {
    height: 100vh;
    overflow: hidden;
  }

  .app {
    width: 100%;
    height: 100vh;
    min-height: 100vh;
    padding: 0;
    overflow: hidden;
  }

  .stage {
    grid-template-columns: minmax(0, 68.4fr) minmax(160px, 31.6fr);
    aspect-ratio: 16 / 9;
    width: min(100vw, calc(100vh * 16 / 9));
    height: min(100vh, calc(100vw * 9 / 16));
    margin: 0 auto;
    border-radius: 0;
  }

  .topbar {
    position: fixed;
    top: 8px;
    right: 8px;
    z-index: 7;
    padding: 0;
    background: transparent;
    backdrop-filter: none;
  }

  .pill {
    padding: 5px 9px;
    font-size: 12px;
  }

  .dock {
    left: 8px;
    right: auto;
    bottom: 8px;
    width: auto;
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 6px;
    padding: 5px;
    border: 1px solid rgba(8, 32, 51, 0.12);
    border-radius: 7px;
    background: rgba(255, 255, 255, 0.72);
    box-shadow: none;
    backdrop-filter: blur(14px);
    pointer-events: none;
    transform: none;
  }

  .dock button {
    min-width: 72px;
    min-height: 32px;
    padding: 0 8px;
    border-radius: 6px;
    font-size: 12px;
    pointer-events: auto;
    box-shadow: 0 8px 20px rgba(8, 32, 51, 0.18);
  }

  #prevBtn {
    color: #082033;
    background: #dbe8ed;
  }

  #nextBtn {
    color: #ffffff;
    background: #00788d;
  }
}

@media (max-width: 520px) {
  .topbar {
    align-items: center;
  }
}

@media (max-width: 720px) and (orientation: portrait) {
  body {
    width: 100vw;
    height: 100vh;
    overflow: hidden;
  }

  .app {
    display: block;
    width: 100vh;
    height: 100vw;
    min-height: 100vw;
    padding: 0;
    overflow: hidden;
    position: fixed;
    left: 50%;
    top: 50%;
    margin: 0;
    transform: translate(-50%, -50%) rotate(90deg);
    transform-origin: center center;
  }

  .rotatePrompt {
    display: none;
  }

  .topbar {
    position: fixed;
    top: 8px;
    right: 8px;
    z-index: 7;
    padding: 0;
    background: transparent;
    backdrop-filter: none;
  }

  .pill {
    padding: 5px 9px;
    font-size: 12px;
  }

  .chapters,
  .chapter {
    gap: 0;
  }

  .stage {
    grid-template-columns: minmax(0, 68.4fr) minmax(160px, 31.6fr);
    width: min(100vh, calc(100vw * 16 / 9));
    height: min(100vw, calc(100vh * 9 / 16));
    margin: 0 auto;
    border-radius: 0;
  }

  .dock {
    left: 8px;
    right: auto;
    bottom: 8px;
    width: auto;
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 6px;
    padding: 5px;
    border: 1px solid rgba(8, 32, 51, 0.12);
    border-radius: 7px;
    background: rgba(255, 255, 255, 0.72);
    box-shadow: none;
    backdrop-filter: blur(14px);
    pointer-events: none;
    transform: none;
  }

  .dock button {
    min-width: 72px;
    min-height: 32px;
    padding: 0 8px;
    border-radius: 6px;
    font-size: 12px;
    pointer-events: auto;
    box-shadow: 0 8px 20px rgba(8, 32, 51, 0.18);
  }

  #prevBtn {
    color: #082033;
    background: #dbe8ed;
  }

  #nextBtn {
    color: #ffffff;
    background: #00788d;
  }

  .playButton {
    width: 46px;
    height: 46px;
  }

  .playButton::before {
    left: 18px;
    top: 14px;
    border-top-width: 9px;
    border-bottom-width: 9px;
    border-left-width: 14px;
  }
}
