/* ビューワー固有のスタイル（base.css のあとに読む。4作品が同じものを読む） */

/* ヘッダー */
.header {
  position: sticky;
  top: 0;
  z-index: 100;
  background: rgba(18, 18, 18, 0.97);
  backdrop-filter: blur(8px);
  border-bottom: 1px solid #252525;
  padding: 10px 16px;
  display: flex;
  align-items: center;
  gap: 8px;
  flex-wrap: wrap;
}
.home-link {
  color: #777; text-decoration: none; font-size: 0.9rem;
  border: 1px solid #333; border-radius: 5px; padding: 4px 9px;
  white-space: nowrap;
}
.home-link:hover { color: #ddd; background: #272727; }
.btn {
  background: #242424;
  color: #bbb;
  border: 1px solid #3a3a3a;
  padding: 5px 12px;
  border-radius: 5px;
  cursor: pointer;
  font-size: 0.85rem;
  white-space: nowrap;
  transition: background 0.12s;
}
.btn:hover:not(:disabled) { background: #333; color: #fff; }
.btn:disabled { opacity: 0.25; cursor: default; }
.vol-select {
  background: #242424;
  color: #ddd;
  border: 1px solid #3a3a3a;
  padding: 5px 10px;
  border-radius: 5px;
  font-size: 0.9rem;
  cursor: pointer;
  min-width: 88px;
}
.vol-select:focus { outline: none; border-color: #555; }
.page-counter { font-size: 0.82rem; color: #555; white-space: nowrap; min-width: 64px; text-align: right; }

/* 本文 */
#viewer { max-width: 800px; margin: 0 auto; padding: 8px 2px 40px; }
.page-img { display: block; width: 100%; height: auto; aspect-ratio: auto 2 / 3; margin-bottom: 2px; background: #141414; }
#status { text-align: center; padding: 80px 20px; color: #444; font-size: 0.9rem; }

/* 先頭へボタン */
.to-top {
  position: fixed;
  bottom: 24px; right: 20px;
  background: #2a2a2a;
  color: #aaa;
  border: 1px solid #3a3a3a;
  border-radius: 50%;
  width: 40px; height: 40px;
  font-size: 1.1rem;
  cursor: pointer;
  display: flex;
  align-items: center;
  justify-content: center;
  opacity: 0;
  transition: opacity 0.2s;
  pointer-events: none;
}
.to-top.show { opacity: 1; pointer-events: auto; }
.to-top:hover { background: #383838; }
