/* Collectanea V4.0.20 · compact shelf density + adaptive compartment height */

/* Each visible book gets only its own rendered width plus a 1px breathing gap.
   No max-scale reservation is left between neighbouring books. */
#libraryRoom .ct419-shelf-back{
  gap:0!important;
}
#libraryRoom .ct419-shelf-back > .ct406-book-unit,
#libraryRoom .ct419-shelf-back > .ct408-book-unit{
  flex:0 0 var(--unit-slot-w)!important;
  width:var(--unit-slot-w)!important;
  min-width:var(--unit-slot-w)!important;
  max-width:var(--unit-slot-w)!important;
}

/* Compartment opening = tallest currently visible book + 1.5 cm clearance.
   --row-book-h already contains that clearance; only the physical shelf plank is added here. */
#libraryRoom .ct419-real-shelf,
#libraryRoom .ct419-real-shelf.ct403-real-shelf,
#libraryRoom .ct419-real-shelf.ct404-real-shelf,
#libraryRoom .ct419-real-shelf.ct406-real-shelf,
#libraryRoom .ct419-real-shelf.ct408-real-shelf{
  height:calc(var(--row-book-h) + 30px)!important;
  min-height:0!important;
  max-height:none!important;
  margin:0!important;
  padding:0!important;
  overflow:hidden!important;
}
#libraryRoom .ct419-shelf-back,
#libraryRoom .ct419-real-shelf .ct419-shelf-back{
  bottom:28px!important;
  height:var(--row-book-h)!important;
  min-height:0!important;
  max-height:var(--row-book-h)!important;
  overflow:hidden!important;
}

/* Content teaser on the daily object stays compact but actually carries several lines of content. */
#view .today-object-teaser{
  display:-webkit-box!important;
  -webkit-box-orient:vertical!important;
  -webkit-line-clamp:5!important;
  overflow:hidden!important;
  max-height:7em!important;
}
