:root {
  font-family: "Noto Sans SC", "Microsoft YaHei", "PingFang SC", Arial, sans-serif;
  color: #17345f;
  background: #eaf5ff;
}
* { box-sizing: border-box; }
html, body { margin: 0; min-height: 100%; max-width: 100%; overflow-x: hidden; }
button, a { -webkit-tap-highlight-color: transparent; }
button { font: inherit; }
body.nursery-page {
  min-height: 100vh;
  background: url("assets/images/backgrounds/textbook-selector/textbook-selector-bg-landscape.png") center top / cover fixed;
}
.nursery-shell {
  width: min(920px, 100%);
  margin: auto;
  padding: 10px 14px 36px;
}
.nursery-topbar {
  position: relative;
  display: flex;
  align-items: center;
  min-height: 72px;
  margin-bottom: 20px;
  padding: 10px 18px;
  border: 2px solid #8fc1f4;
  border-radius: 22px;
  background: rgba(255, 255, 255, 0.78);
  box-shadow: 0 18px 34px rgba(38, 88, 145, 0.2);
}
.nursery-topbar > div { width: 100%; }
.nursery-topbar p,
.nursery-player-copy p {
  margin: 0;
  color: #4f82c4;
  font-size: 12px;
  font-weight: 900;
}
.nursery-topbar h1 {
  margin: 2px 0 0;
  color: #17345f;
  font-family: "Source Han Serif SC", "Noto Serif SC", "SimSun", serif;
  font-size: 25px;
  font-weight: 950;
}
.nursery-back,
.nursery-list-back {
  padding: 9px 13px;
  border: 1.5px solid rgba(91, 137, 190, 0.5);
  border-radius: 999px;
  color: #1e4778;
  background: linear-gradient(180deg, #fff, #def2ff);
  font-size: 14px;
  font-weight: 900;
  text-decoration: none;
  cursor: pointer;
}
.nursery-back {
  position: absolute;
  top: 50%;
  right: 16px;
  transform: translateY(-50%);
}

.nursery-grid {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 18px;
}
.nursery-video-card {
  display: grid;
  grid-template-rows: auto 1fr;
  min-width: 0;
  padding: 0;
  overflow: hidden;
  border: 3px solid rgba(218, 166, 78, 0.92);
  border-radius: 8px;
  color: inherit;
  background: rgba(255, 250, 235, 0.9);
  box-shadow: 0 18px 42px rgba(4, 15, 39, 0.26), inset 0 0 0 2px rgba(75, 155, 255, 0.16);
  text-align: left;
  cursor: pointer;
}
.nursery-video-card:focus-visible {
  outline: 4px solid rgba(65, 139, 226, 0.5);
  outline-offset: 3px;
}
.nursery-cover {
  position: relative;
  aspect-ratio: 16 / 9;
  overflow: hidden;
  background: #12243d;
}
.nursery-cover img {
  display: block;
  width: 100%;
  height: 100%;
  object-fit: cover;
  transition: transform 180ms ease;
}
.nursery-video-card:hover .nursery-cover img { transform: scale(1.025); }
.nursery-play {
  position: absolute;
  left: 18px;
  bottom: 16px;
  width: 48px;
  height: 48px;
  border: 2px solid rgba(255, 255, 255, 0.88);
  border-radius: 50%;
  background: rgba(20, 52, 95, 0.86);
  box-shadow: 0 8px 18px rgba(6, 21, 43, 0.28);
}
.nursery-play::after {
  position: absolute;
  top: 50%;
  left: 52%;
  width: 0;
  height: 0;
  border-top: 9px solid transparent;
  border-bottom: 9px solid transparent;
  border-left: 14px solid #fff;
  content: "";
  transform: translate(-38%, -50%);
}
.nursery-duration {
  position: absolute;
  right: 12px;
  bottom: 12px;
  padding: 5px 8px;
  border-radius: 6px;
  color: #fff;
  background: rgba(7, 22, 43, 0.78);
  font-size: 12px;
  font-weight: 900;
}
.nursery-card-copy { min-width: 0; padding: 16px 18px 18px; }
.nursery-card-copy strong {
  display: block;
  overflow-wrap: anywhere;
  color: #17345f;
  font-size: 21px;
  line-height: 1.25;
}
.nursery-card-copy span {
  display: block;
  margin-top: 7px;
  color: #6682a3;
  font-size: 14px;
  font-weight: 800;
}
.nursery-player-view[hidden] { display: none; }
.nursery-list-back { margin: 0 0 14px 4px; }
.nursery-player-card {
  overflow: hidden;
  border: 3px solid rgba(218, 166, 78, 0.92);
  border-radius: 8px;
  background: rgba(255, 250, 235, 0.92);
  box-shadow: 0 18px 50px rgba(4, 15, 39, 0.32), inset 0 0 0 2px rgba(75, 155, 255, 0.18);
}
.nursery-video-frame {
  width: 100%;
  aspect-ratio: 16 / 9;
  background: #07111f;
}
.nursery-video-frame video {
  display: block;
  width: 100%;
  height: 100%;
  background: #07111f;
  object-fit: cover;
}
.nursery-player-copy { padding: 18px 20px 8px; text-align: center; }
.nursery-player-copy h2 {
  margin: 5px 0 3px;
  overflow-wrap: anywhere;
  color: #17345f;
  font-family: "Source Han Serif SC", "Noto Serif SC", "SimSun", serif;
  font-size: 28px;
}
.nursery-player-copy > span {
  color: #6682a3;
  font-size: 14px;
  font-weight: 800;
}
.nursery-playback-mode {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  width: min(360px, calc(100% - 40px));
  margin: 10px auto 0;
  padding: 4px;
  border: 2px solid rgba(201, 149, 57, 0.78);
  border-radius: 999px;
  background: rgba(211, 230, 247, 0.9);
  box-shadow: inset 0 2px 5px rgba(27, 71, 116, 0.18), 0 2px 0 rgba(255, 255, 255, 0.75);
}
.nursery-playback-mode label {
  position: relative;
  min-width: 0;
  cursor: pointer;
}
.nursery-playback-mode input {
  position: absolute;
  width: 1px;
  height: 1px;
  clip-path: inset(50%);
  opacity: 0;
}
.nursery-playback-mode span {
  display: flex;
  align-items: center;
  justify-content: center;
  min-height: 38px;
  padding: 0 14px;
  border-radius: 999px;
  color: #4f7298;
  font-size: 14px;
  font-weight: 900;
  white-space: nowrap;
  transition: color 160ms ease, background 160ms ease, box-shadow 160ms ease;
}
.nursery-playback-mode input:checked + span {
  color: #fff;
  background: linear-gradient(180deg, #438fd2, #205f9f);
  box-shadow: inset 0 0 0 1px rgba(255, 222, 145, 0.75), 0 2px 5px rgba(20, 63, 107, 0.28);
}
.nursery-playback-mode input:focus-visible + span {
  outline: 3px solid rgba(65, 139, 226, 0.42);
  outline-offset: 2px;
}.nursery-player-actions {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 12px;
  padding: 12px 20px 20px;
}
.nursery-player-actions button {
  min-height: 44px;
  border: 2px solid #8fc1f4;
  border-radius: 999px;
  color: #1e4778;
  background: rgba(255, 255, 255, 0.78);
  font-weight: 900;
  cursor: pointer;
}
.nursery-player-actions button:disabled {
  opacity: 0.42;
  cursor: default;
}
@media (max-width: 600px) {
  body.nursery-page {
    background-image: url("assets/images/backgrounds/textbook-selector/textbook-selector-bg-portrait.png");
  }
  .nursery-shell { padding: 8px 10px 26px; }
  .nursery-topbar { min-height: 64px; padding-left: 18px; padding-right: 112px; }
  .nursery-topbar h1 { font-size: 22px; }
  .nursery-back { right: 10px; font-size: 12px; }
  .nursery-grid { grid-template-columns: 1fr; gap: 14px; }
  .nursery-card-copy { padding: 13px 15px 15px; }
  .nursery-card-copy strong { font-size: 19px; }
  .nursery-player-copy h2 { font-size: 23px; }
  .nursery-playback-mode { width: min(320px, calc(100% - 28px)); }
  .nursery-playback-mode span { min-height: 36px; padding: 0 10px; font-size: 13px; }
  .nursery-player-actions { padding: 10px 14px 16px; }
}