.pdf-entry {
  display: flex;
  align-items: flex-start;
  gap: 10px;
  text-decoration: none;
  white-space: normal;
  word-break: break-word;
  margin-bottom: 8px;
  max-width: 100%;
}

.pdf-icon {
  width: 25px;
  height: 25px;
  flex-shrink: 0;
}

.pdf-title {
  flex: 1;
  display: block;
  line-height: 1.4;
  color: inherit;
}

.category-thumb {
  width: 273px;
  height: 182px;
  overflow: hidden;
  /* center the contained image */
  display: flex;
  align-items: center;
  justify-content: center;
  background: #fff;           /* optional: fill behind letterboxing */
}

.category-thumb img {
  /* contain scales the image so all of it fits */
  max-width: 100%;
  max-height: 100%;
  object-fit: contain;
  /* remove inline-gap */
  display: block;
}



.sidebar ul {
  max-height: none;
}
/* once the screen is ≤ 991px, limit to ~5 items and scroll */
@media (max-width: 991px) {
  .sidebar ul {
    max-height: calc(5 * 2.5em); /* roughly 5 × line‑height (~2.5em) */
    overflow-y: auto;
  }
  .sidebar ul::-webkit-scrollbar {
    width: 6px;
  }
  .sidebar ul::-webkit-scrollbar-thumb {
    background: rgba(0,0,0,0.2);
    border-radius: 3px;
  }
}
