body {
  font-family: 'Helvetica Neue', Arial, 'Hiragino Kaku Gothic ProN', 'Hiragino Sans', sans-serif;
  background: #f1f0ee;
  color: #222;
  margin: 0;
  padding: 0 2.5rem 4rem;
  max-width: 1100px;
}

h1 {
  font-size: 1.6rem;
  font-weight: normal;
  margin: 2.5rem 0 1.5rem;
  letter-spacing: 0.05em;
}

#filter-bar {
  display: flex;
  gap: 1.5rem;
  border-bottom: 1px solid #ddd;
  padding-bottom: 0.6rem;
  margin-bottom: 2.5rem;
}

.filter-btn {
  background: none;
  border: none;
  cursor: pointer;
  font-size: 0.9rem;
  color: #aaa;
  padding: 0;
  font-family: inherit;
  letter-spacing: 0.02em;
  transition: color 0.2s;
}

.filter-btn:hover {
  color: #555;
}

.filter-btn.active {
  color: #222;
  font-weight: bold;
  border-bottom: 2px solid #222;
  padding-bottom: 0.4rem;
  margin-bottom: -0.6rem;
}

#book-list {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 2.5rem 1.5rem;
}

@media (max-width: 768px) {
  #book-list {
    grid-template-columns: repeat(2, 1fr);
  }
}

@media (max-width: 480px) {
  body { padding: 0 1rem 3rem; }
  #book-list {
    grid-template-columns: repeat(2, 1fr);
    gap: 1.5rem 1rem;
  }
}

.book-item {
  cursor: default;
}

.book-cover-wrapper {
  position: relative;
  overflow: hidden;
  background: #d9d6d4;
  aspect-ratio: 3 / 4;
}

.book-cover {
  width: 100%;
  height: 100%;
  object-fit: cover;
  display: block;
}

.book-cover-wrapper.no-image {
  display: flex;
  align-items: center;
  justify-content: center;
  background: #ffffff;
}

.no-image-text {
  font-size: 0.85rem;
  color: #888;
  text-align: center;
  padding: 0.5rem;
  line-height: 1.5;
}

.book-overlay {
  position: absolute;
  top: 0;
  left: 0;
  right: 0;
  bottom: 0;
  background: rgba(255, 255, 255, 0.93);
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: flex-start;
  gap: 0;
  opacity: 0;
  transition: opacity 0.25s ease;
  padding: 1rem;
  text-align: center;
  overflow-y: auto;
  box-sizing: border-box;
}

.book-cover-wrapper:hover .book-overlay {
  opacity: 1;
}

.overlay-meta {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 0.3rem;
  padding-top: 0.5rem;
  flex-shrink: 0;
}

.overlay-publisher {
  font-size: 0.85rem;
  font-weight: bold;
  color: #111;
  margin: 0;
}

.overlay-year {
  font-size: 0.8rem;
  color: #555;
  margin: 0;
}

.overlay-author {
  font-size: 0.85rem;
  color: #333;
  margin: 0;
}

.overlay-divider {
  width: 60%;
  height: 1px;
  background: #ccc;
  margin: 0.7rem 0;
  flex-shrink: 0;
}

.overlay-comment {
  font-size: 0.82rem;
  color: #444;
  line-height: 1.7;
  margin: 0;
  text-align: left;
  width: 100%;
}

.book-title {
  margin: 0.6rem 0 0;
  font-size: 0.88rem;
  line-height: 1.5;
  color: #222;
}