/* ==============================
  Album Page
============================== */

.alb-container {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 14px;
  width: 100%;
  max-width: none;
}

.alb-page-btn {
  flex-shrink: 0;
  background: none;
  border: none;
  color: rgba(90, 55, 20, 0.28);
  font-size: 5rem;
  cursor: pointer;
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 0 4px;
  line-height: 0;
  transition: color 0.22s, transform 0.16s, filter 0.22s;
  filter: drop-shadow(0 2px 5px rgba(60, 30, 5, 0.12));
  user-select: none;
}

.alb-page-btn:hover {
  color: rgba(80, 40, 8, 0.80);
  transform: scale(1.15);
  filter: drop-shadow(0 3px 10px rgba(80, 40, 5, 0.28));
}

.alb-page-btn:active {
  transform: scale(1.05);
}

.alb-page-btn.hidden {
  opacity: 0;
  pointer-events: none;
}

.alb-book {
  flex: 0 1 auto;
  min-width: 0;
  width: min(calc(100% - 110px), calc((100vh - 380px) * 16 / 9));
  aspect-ratio: 16 / 9;
  position: relative;
  isolation: isolate;
}

.alb-book::before {
  content: '';
  position: absolute;
  inset: 0;
  background: #ede8e1;
  box-shadow: 0 6px 24px rgba(0,0,0,0.13);
  transform: rotate(-3deg);
  transform-origin: center center;
  z-index: 0;
  border-radius: 2px;
}

.alb-page {
  width: 100%;
  height: 100%;
  position: relative;
  overflow: hidden;
  background: #f5f2ee;
  box-shadow: 0 6px 32px rgba(0,0,0,0.16), 0 2px 8px rgba(0,0,0,0.08);
  z-index: 1;
}

.alb-photo {
  position: absolute;
  background: white;
  padding: 6px 6px 22px;
  box-shadow: 2px 4px 10px rgba(0,0,0,0.28);
  transform-origin: center center;
  cursor: pointer;
  transition: box-shadow 0.15s;
}

.alb-photo:hover {
  box-shadow: 5px 8px 20px rgba(0,0,0,0.48);
  z-index: 999 !important;
}

.alb-photo img {
  display: block;
  width: 100%;
  height: 100%;
  object-fit: cover;
}

.alb-indicator {
  position: absolute;
  bottom: 7px;
  right: 9px;
  z-index: 500;
  font-size: 1.5rem;
  color: rgba(0,0,0,0.28);
  pointer-events: none;
  font-family: 'Caveat', cursive;
  letter-spacing: .03em;
}

@media (max-width: 900px) {
  .alb-page-btn { font-size: 4rem; }
  .alb-container { gap: 8px; }
}

@media (max-width: 860px) {
  .alb-book { width: min(calc(100% - 110px), calc((100vh - 280px) * 16 / 9)); }
  .alb-container + .notice { margin-top: 120px; }
}

@media (max-width: 600px) {
  .alb-page-btn { font-size: 3rem; padding: 0 2px; }
  .alb-container { gap: 4px; }
  .alb-book {
    width: calc(100% - 60px);
    height: auto;
    aspect-ratio: 9 / 16;
    max-width: none;
  }
  .alb-container + .notice { margin-top: 60px; }
}

@media (max-width: 480px) {
  .alb-page-btn { font-size: 2.5rem; }
  #albLbPrev, #albLbNext { font-size: 3.5rem; }
  #albLbPrev { left: 8px; }
  #albLbNext { right: 8px; }
}

.alb-container + .notice {
  margin-top: 200px;
}

.alb-lightbox {
  display: none;
  position: fixed;
  inset: 0;
  background: rgba(0,0,0,0.92);
  z-index: 2000;
  align-items: center;
  justify-content: center;
}

.alb-lightbox.open { display: flex; }

.alb-lb-wrap img {
  display: block;
  max-width: 88vw;
  max-height: 88vh;
  object-fit: contain;
  box-shadow: 0 0 60px rgba(0,0,0,0.6);
}

.alb-lb-btn {
  position: fixed;
  background: none;
  border: none;
  cursor: pointer;
  line-height: 0;
  padding: 0;
  display: flex;
  align-items: center;
  justify-content: center;
}

#albLbClose {
  top: 16px; right: 22px;
  width: 42px; height: 42px;
  border-radius: 50%;
  font-size: 1.2rem;
  background: rgba(255,255,255,0.18);
  color: #fff;
  transition: background 0.15s, transform 0.14s;
}
#albLbClose:hover {
  background: rgba(255,255,255,0.35);
  transform: scale(1.1);
}

#albLbPrev,
#albLbNext {
  color: rgba(255,255,255,0.45);
  font-size: 5rem;
  filter: drop-shadow(0 2px 8px rgba(0,0,0,0.55));
  transition: color 0.2s, transform 0.16s, filter 0.2s;
}
#albLbPrev {
  top: 50%; left: 18px;
  transform: translateY(-50%);
}
#albLbNext {
  top: 50%; right: 18px;
  transform: translateY(-50%);
}
#albLbPrev:hover {
  color: rgba(255,255,255,0.95);
  transform: translateY(-50%) scale(1.15);
  filter: drop-shadow(0 3px 14px rgba(255,255,255,0.25));
}
#albLbNext:hover {
  color: rgba(255,255,255,0.95);
  transform: translateY(-50%) scale(1.15);
  filter: drop-shadow(0 3px 14px rgba(255,255,255,0.25));
}
#albLbPrev:active { transform: translateY(-50%) scale(1.05); }
#albLbNext:active { transform: translateY(-50%) scale(1.05); }

.alb-lb-counter {
  position: fixed;
  bottom: 16px;
  left: 50%;
  transform: translateX(-50%);
  color: rgba(255,255,255,0.55);
  font-size: 0.8rem;
  pointer-events: none;
}

[data-theme="dark"] .alb-page-btn {
  color: rgba(215, 185, 145, 0.55);
  filter: drop-shadow(0 2px 6px rgba(0, 0, 0, 0.35));
}

[data-theme="dark"] .alb-page-btn:hover {
  color: rgba(230, 200, 160, 0.92);
  filter: drop-shadow(0 3px 12px rgba(0, 0, 0, 0.55));
}
