/* Doxa Book Cover v6 · official ∴ mark + reflowed editorial cover */

/* Shared academy renderer: .volume-card / .volume-ribbon */
.volume-card {
  height: 336px;
  min-height: 336px;
  position: relative;
  display: flex;
  flex-direction: column;
  overflow: visible;
  background: none;
  border: 0;
  border-radius: 0;
  transition: transform .2s ease;
}
.volume-card:hover { transform: translateY(-4px); }
.volume-ribbon {
  --cover-accent: var(--library-accent, #1E2A78);
  --cover-green: var(--library-green, #15A06A);
  position: relative;
  height: 228px;
  min-height: 228px;
  display: flex;
  flex-direction: column;
  padding: 19px 17px 14px 28px;
  overflow: hidden;
  isolation: isolate;
  color: #1E2A78;
  background: var(--cover-accent);
  border-radius: 4px 10px 10px 4px;
  box-shadow: inset 9px 0 0 rgba(0,0,0,.2), inset 12px 0 0 rgba(255,255,255,.08), 5px 5px 0 rgba(30,42,120,.1), 0 12px 24px rgba(20,22,31,.12);
}
.volume-ribbon::before {
  content: "";
  position: absolute;
  z-index: 0;
  inset: 10px 10px 10px 24px;
  background: #F4EFE4;
  border: 1px solid rgba(30,42,120,.48);
  box-shadow: inset 0 0 0 1px rgba(255,255,255,.35);
}
.volume-ribbon::after {
  content: "";
  position: absolute;
  z-index: 0;
  left: 40px;
  right: 24px;
  bottom: 39px;
  height: 1px;
  background: #C9C0B0;
}
.volume-cover-logo {
  position: absolute;
  z-index: 3;
  top: 18px;
  right: 27px;
  width: 24px;
  height: 21px;
  object-fit: contain;
}
.volume-signal { display: none !important; }
.volume-cover-index,
.volume-cover-series,
.volume-cover-title,
.volume-cover-form,
.volume-cover-status {
  position: relative;
  z-index: 2;
  color: #1E2A78;
}
.volume-cover-index {
  font-family: var(--font-mono);
  font-size: .53rem;
  letter-spacing: .11em;
  opacity: .76;
}
.volume-cover-series {
  max-width: 74%;
  margin-top: 12px;
  overflow: hidden;
  white-space: nowrap;
  text-overflow: ellipsis;
  font-size: .58rem;
  letter-spacing: .11em;
  text-transform: uppercase;
  opacity: .82;
}
.volume-cover-title {
  height: 4.2em;
  min-height: 4.2em;
  max-height: 4.2em;
  display: -webkit-box;
  overflow: hidden;
  margin: 10px 0 0;
  color: #1E2A78;
  font-family: var(--font-serif);
  font-size: 1.08rem;
  line-height: 1.4;
  -webkit-box-orient: vertical;
  -webkit-line-clamp: 3;
  overflow-wrap: anywhere;
}
.volume-cover-form {
  margin-top: auto;
  padding-bottom: 1px;
  font-family: var(--font-mono);
  font-size: .59rem;
  letter-spacing: .06em;
  opacity: .9;
}
.volume-cover-status {
  right: 14px;
  bottom: 12px;
  position: absolute;
  padding: 3px 6px;
  border: 1px solid var(--cover-green);
  border-radius: 1px;
  background: transparent;
  color: #1E2A78;
  font-size: .52rem;
  font-weight: 700;
  letter-spacing: .04em;
}
.volume-card.is-draft .volume-ribbon { opacity: .92; }
.volume-card.is-draft .volume-cover-status { border-color: #8B8F9C; color: #5A5E70; }
.volume-card[data-form] .volume-ribbon { background: var(--cover-accent); }
.volume-body {
  height: 98px;
  min-height: 98px;
  padding: 9px 2px 0;
  display: grid;
  grid-template-rows: 1fr auto;
  min-width: 0;
}
.volume-body p {
  height: 2.9em;
  min-height: 2.9em;
  max-height: 2.9em;
  display: -webkit-box;
  overflow: hidden;
  margin: 0;
  color: #5A5E70;
  font-size: .76rem;
  line-height: 1.48;
  -webkit-box-orient: vertical;
  -webkit-line-clamp: 2;
}
.volume-meta { display: flex; gap: 6px; align-items: center; margin: 5px 0 0; }
.volume-chip { color: #1E2A78; background: #EEF0F8; }
.volume-foot { bottom: 6px; }

/* Math / AI renderer: .book / .book-cover */
.book {
  height: 336px;
  min-height: 336px;
}
.book-front .book-cover {
  --cover-accent: var(--library-accent, var(--math-indigo, #1E2A78));
  --cover-green: var(--library-green, var(--math-green, #15A06A));
  position: relative;
  height: 228px;
  min-height: 228px;
  padding: 19px 17px 14px 28px;
  display: flex;
  flex-direction: column;
  justify-content: flex-start;
  align-items: stretch;
  isolation: isolate;
  overflow: hidden;
  color: #1E2A78;
  background: var(--cover-accent);
  border-radius: 4px 10px 10px 4px;
  box-shadow: inset 9px 0 0 rgba(0,0,0,.2), inset 12px 0 0 rgba(255,255,255,.08), 5px 5px 0 rgba(30,42,120,.1), 0 12px 24px rgba(20,22,31,.12);
}
.book-front .book-cover::before {
  content: "";
  position: absolute;
  z-index: 0;
  inset: 10px 10px 10px 24px;
  width: auto;
  background: #F4EFE4;
  border: 1px solid rgba(30,42,120,.48);
  border-radius: 0;
  box-shadow: inset 0 0 0 1px rgba(255,255,255,.35);
}
.book-front .book-cover::after {
  content: "";
  position: absolute;
  z-index: 0;
  left: 40px;
  right: 24px;
  top: auto;
  bottom: 39px;
  width: auto;
  height: 1px;
  background: #C9C0B0;
}
.book-cover-logo {
  position: absolute;
  z-index: 3;
  top: 18px;
  right: 27px;
  width: 24px;
  height: 21px;
  object-fit: contain;
}
.book-signal { display: none !important; }
.book-front .book-cover-index,
.book-front .book-cover-series,
.book-front .book-cover-title,
.book-front .book-cover-form,
.book-front .seal {
  position: relative;
  z-index: 2;
  color: #1E2A78;
}
.book-front .book-cover-index {
  font-family: var(--font-mono);
  font-size: .53rem;
  letter-spacing: .11em;
  opacity: .76;
}
.book-front .book-cover-series {
  max-width: 74%;
  margin-top: 12px;
  overflow: hidden;
  white-space: nowrap;
  text-overflow: ellipsis;
  font-size: .58rem;
  letter-spacing: .11em;
  text-transform: uppercase;
  opacity: .82;
}
.book-front .book-cover-title {
  height: 4.2em;
  min-height: 4.2em;
  max-height: 4.2em;
  display: -webkit-box;
  overflow: hidden;
  margin: 10px 0 0;
  color: #1E2A78;
  font-family: var(--font-serif);
  font-size: 1.08rem;
  line-height: 1.4;
  -webkit-box-orient: vertical;
  -webkit-line-clamp: 3;
  overflow-wrap: anywhere;
}
.book-front .book-cover-form {
  margin-top: auto;
  padding-bottom: 1px;
  font-family: var(--font-mono);
  font-size: .59rem;
  letter-spacing: .06em;
  opacity: .9;
}
.book-front .seal {
  top: auto;
  right: 14px;
  bottom: 12px;
  position: absolute;
  padding: 3px 6px;
  border: 1px solid var(--cover-green);
  border-radius: 1px;
  background: transparent;
  box-shadow: none;
  color: #1E2A78;
  font-size: .52rem;
  font-weight: 700;
  letter-spacing: .04em;
}
.book-cover.is-draft { filter: none; opacity: .92; }
.book-cover.is-draft .book-cover-index,
.book-cover.is-draft .book-cover-series,
.book-cover.is-draft .book-cover-title,
.book-cover.is-draft .book-cover-form,
.book-cover.is-draft .seal { color: #5A5E70; }
.book-cover.is-draft .seal { border-color: #8B8F9C; }
.book[data-form] .book-cover:not(.is-draft) { background: var(--cover-accent); color: #1E2A78; }
.book[data-form="书单"] .book-cover:not(.is-draft) { background: var(--cover-accent); color: #1E2A78; }
.book-front .book-desc {
  height: 98px;
  min-height: 98px;
  padding-top: 9px;
}

.volume-ribbon::before,
.book-front .book-cover::before { display: none; }
.volume-cover-paper,
.book-cover-paper {
  position: absolute;
  z-index: 0;
  inset: 10px 10px 10px 24px;
  display: block;
  pointer-events: none;
  background: #F4EFE4;
  border: 1px solid rgba(30,42,120,.48);
  box-shadow: inset 0 0 0 1px rgba(255,255,255,.35);
}

@media (max-width: 700px) {
  .volume-card, .book { height: 326px; min-height: 326px; }
  .volume-ribbon, .book-front .book-cover { height: 220px; min-height: 220px; }
  .volume-cover-title, .book-front .book-cover-title { font-size: 1rem; }
}
@media (max-width: 460px) {
  .volume-card, .book { height: 304px; min-height: 304px; }
  .volume-ribbon, .book-front .book-cover { height: 204px; min-height: 204px; padding: 16px 12px 11px 22px; }
  .volume-cover-logo, .book-cover-logo { top: 15px; right: 21px; width: 22px; height: 19px; }
  .volume-cover-series, .book-front .book-cover-series { font-size: .53rem; }
  .volume-cover-title, .book-front .book-cover-title { font-size: .92rem; }
  .volume-body, .book-front .book-desc { height: 90px; min-height: 90px; }
}
@media (prefers-reduced-motion: reduce) {
  .volume-card, .book, .book-cover { transition: none; }
  .volume-card:hover, .book:hover, .book:hover .book-cover { transform: none; }
}
