/* Euonia book page: dynamic tags + slightly larger cover/carpet
   Scope: single book template only. Paste into Additional CSS or a Code Snippets CSS snippet. */

/* --- Tags: fill height beside the description; +N more is an inline chip --- */
html body.single-book #inner-wrap .escore.esc-page-book .ebl-book-tags {
  display: flex !important;
  flex-direction: column;
  min-height: 0;
  box-sizing: border-box;
}
html body.single-book #inner-wrap .escore.esc-page-book .ebl-book-tags .book-tags {
  display: flex;
  flex-wrap: wrap;
  align-items: flex-start;
  align-content: flex-start;
  gap: 8px;
  flex: 1 1 auto;
  min-height: 0;
}
html body.single-book #inner-wrap .escore.esc-page-book .ebl-book-tags .esc-bd-tag-toggle,
html body.single-book #inner-wrap .escore.esc-page-book .ebl-book-tags .ebl-tag-more {
  flex-basis: auto !important;
  margin-top: 0 !important;
  text-align: center !important;
  text-decoration: none !important;
  background: #f7f0ff !important;
  border: 1px dashed #c9a6e8 !important;
  border-radius: 20px !important;
  box-shadow: none !important;
  color: #6b2ea0 !important;
  padding: 6px 17px !important;
  font: 14px/1.5 Arial, sans-serif !important;
  cursor: pointer;
}
html body.single-book #inner-wrap .escore.esc-page-book .ebl-book-tags .esc-bd-tag-toggle:hover,
html body.single-book #inner-wrap .escore.esc-page-book .ebl-book-tags .ebl-tag-more:hover {
  background: #ece1f6 !important;
  border-color: #b799ce !important;
}
html body.single-book #inner-wrap .escore.esc-page-book .ebl-book-tags .tag[hidden],
html body.single-book #inner-wrap .escore.esc-page-book .ebl-book-tags .esc-bd-tag-toggle[hidden] {
  display: none !important;
}

/* --- Cover + flying carpet: +17% on desktop, +16% on compact --- */
html[data-escore-device="desktop"] body.single-book #inner-wrap .escore.esc-page-book .esc-bd-book3d {
  --bd-book-width: 270px; /* was 230px */
}
html[data-escore-device="desktop"] body.single-book #inner-wrap .escore.esc-page-book .esc-bd-cover-stage {
  --bd-stage-gap: 100px; /* was 78px, keeps carpet under the taller book */
  padding-top: 2px;
}
html[data-escore-device="desktop"] body.single-book #inner-wrap .escore.esc-page-book .esc-bd-carpet {
  width: 117% !important; /* was 100% of the stage */
  max-width: 574px !important; /* was 490px */
}

html[data-escore-device="compact"] body.single-book #inner-wrap .escore.esc-page-book .esc-bd-book3d {
  --bd-book-width: 220px; /* was 190px */
  --bd-book-depth: 68.2px;
}
html[data-escore-device="compact"] body.single-book #inner-wrap .escore.esc-page-book .esc-bd-cover-stage {
  --bd-stage-gap: 76px; /* was 65px */
}
html[data-escore-device="compact"] body.single-book #inner-wrap .escore.esc-page-book .esc-bd-carpet {
  width: 114% !important; /* was 110%; keep tassels inside the hero frame */
}

/* Duplicate floating cart: the shop plugin prints it twice; hide the copy at the end of <body>. */
body > a#esh-floating-cart.esh-floating-cart { display: none !important; }

/* Move the cover + flying carpet down so the book doesn't push past the top of its frame. */
html[data-escore-device="desktop"] body.single-book #inner-wrap .escore.esc-page-book .esc-bd-cover-stage { padding-top: 48px !important; }
html[data-escore-device="compact"] body.single-book #inner-wrap .escore.esc-page-book .esc-bd-cover-stage { padding-top: 30px !important; }
