/* 首页实体书：从原版恢复的封面、书脊、页边和书签，独立维护。 */
.feat-course__media--book {
  position: relative;
  width: min(84%, 396px);
  aspect-ratio: 400 / 540;
  margin: 0 auto;
  align-self: center;
  perspective: 1800px;
  perspective-origin: 42% 46%;
}

.feat-course__media--book::after {
  content: "";
  position: absolute;
  left: 6%;
  right: 2%;
  bottom: -2%;
  height: 14%;
  background: radial-gradient(50% 50% at 50% 50%, #14110d42, #14110d00 70%);
  filter: blur(12px);
  pointer-events: none;
}

.book-3d {
  position: absolute;
  inset: 0;
  transform-style: preserve-3d;
  transform: rotateY(-20deg) rotateX(2deg);
  transition: transform .8s cubic-bezier(.22, .8, .24, 1);
}

.book-3d:hover {
  transform: rotateY(-14deg) rotateX(1deg);
}

.book-pages {
  position: absolute;
  top: .6%;
  bottom: .6%;
  right: 0;
  width: 44px;
  transform-origin: right center;
  transform: rotateY(-90deg);
  background:
    linear-gradient(90deg, #00000057, #0000 30%),
    repeating-linear-gradient(90deg, #f4ecd9 0 1px, #bfae8c 1px 2px, #e4d8bd 2px 3px, #cdbc99 3px 4px);
  box-shadow: inset -14px 0 18px #46382266, inset 0 0 0 1px #46382240;
}

.book-spine {
  position: absolute;
  inset: 0 auto 0 0;
  width: 44px;
  display: flex;
  align-items: center;
  justify-content: center;
  transform-origin: left center;
  transform: rotateY(90deg);
  background: linear-gradient(90deg, #050403, #14100b 30%, #1c1710 46%, #100c08 74%, #050403);
  box-shadow: inset 0 0 0 1px #b8913f2e, inset -8px 0 10px -8px #000000e6;
  backface-visibility: hidden;
}

.book-spine__title {
  writing-mode: vertical-rl;
  font-family: var(--font-sans);
  font-size: 12px;
  font-weight: 700;
  letter-spacing: .28em;
  color: #d8b26a9e;
  text-shadow: 0 1px 0 #000000b3;
}

.book-spine__band {
  position: absolute;
  left: 8px;
  right: 8px;
  height: 1px;
  background: #b8913f73;
}

.book-spine__band--top { top: 26px; }
.book-spine__band--bottom { bottom: 26px; }

.book-ribbon {
  position: absolute;
  right: 26%;
  bottom: -2.2%;
  width: 9px;
  height: 16%;
  background: linear-gradient(#8f2f2a, #6c221e 70%, #521815);
  transform: translateZ(6px) rotate(1.4deg);
  box-shadow: 0 2px 6px -3px #0009;
}

.book-ribbon::after {
  content: "";
  position: absolute;
  inset: auto 0 -1px;
  height: 7px;
  background: #521815;
  clip-path: polygon(0 0, 50% 100%, 100% 0);
}

.book-cover {
  position: absolute;
  inset: 0;
  overflow: hidden;
  border: 1px solid #b8913f61;
  border-radius: 3px;
  background:
    radial-gradient(ellipse 120% 80% at 18% 8%, #d8b26a24, #d8b26a00 60%),
    linear-gradient(158deg, #17130d, #0d0b08 46%, #060504);
  box-shadow: inset -1px 0 0 #00000073, inset -12px 0 20px -12px #0000006b,
    inset 0 0 0 5px #0b0a07, inset 0 0 0 6px #b8913f38;
}

.book-cover::before,
.book-cover::after {
  content: "";
  position: absolute;
  inset: 0;
  pointer-events: none;
}

.book-cover::before {
  background:
    repeating-linear-gradient(45deg, #ffffff05 0 1px, #0000 1px 3px),
    repeating-linear-gradient(-45deg, #00000038 0 1px, #0000 1px 3px);
  opacity: .55;
}

.book-cover::after {
  background: repeating-linear-gradient(48deg, #d8b26a0d 0 1px, #0000 1px 11px);
}

.book-cover__frame {
  position: absolute;
  inset: 14px;
  border: 1px solid #b8913f29;
  border-radius: 2px;
  pointer-events: none;
}

.book-cover__foil,
.book-cover__geo {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  pointer-events: none;
}

.book-cover__copy {
  position: absolute;
  top: 50%;
  left: 26px;
  right: 26px;
  z-index: 2;
  transform: translateY(-50%);
}

.book-cover__meta {
  margin: 0;
  font-size: 10px;
  letter-spacing: .04em;
  color: #d8b26ab3;
  text-shadow: 0 1px 0 #0009;
}

.book-cover__title {
  margin: 30px 0 0;
  font-family: var(--font-sans);
  font-size: clamp(25px, 2.4vw, 34px);
  font-weight: 900;
  line-height: 1.38;
  letter-spacing: .02em;
  color: #e8d1a0;
  text-shadow: 0 1px 0 #0009;
}

.book-cover__sub {
  margin: 16px 0 0;
  font-size: 13px;
  letter-spacing: .08em;
  color: #f3ead6cc;
}

.book-cover__author {
  margin: 14px 0 0;
  font-family: var(--font-sans);
  font-size: 14.5px;
  letter-spacing: .12em;
  color: #d8b26a;
  text-shadow: 0 1px 0 #0009;
}

.book-cover__author em {
  margin-left: 6px;
  font-family: var(--font-sans);
  font-size: 10px;
  font-style: normal;
  letter-spacing: .2em;
  color: #d8b26a9e;
}

.book-cover__foot {
  position: absolute;
  left: 26px;
  right: 20px;
  bottom: 16px;
  z-index: 2;
  margin: 0;
  font-size: 8.5px;
  letter-spacing: .1em;
  color: #f3ead66b;
}

@media (max-width: 900px) {
  .feat-course__media--book {
    width: min(76%, 330px);
    margin-bottom: 8px;
    perspective: none;
  }

  .book-3d,
  .book-3d:hover {
    transform: none;
  }

  .book-pages,
  .book-spine {
    display: none;
  }
}
