

.album-view {
  display: flex;
  flex-direction: column;
  gap: 16px;
  width: min(100%, 760px);
}

.album-head {
  display: flex;
  flex-direction: column;
  gap: 10px;
  padding: 14px;
  border: var(--pixel-line) solid var(--plum);
  border-radius: 10px;
  background: var(--card);
  box-shadow: var(--pixel-shadow-sm);
}

.album-head-top {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 10px;
}

.album-kicker {
  color: var(--strawberry);
  font-family: var(--font-pixel);
  font-size: 11px;
  font-weight: 700;
  letter-spacing: 0.16em;
  text-transform: uppercase;
}

.album-count {
  color: var(--plum);
  font-family: var(--font-pixel);
  font-size: 12px;
  font-weight: 700;
}

.album-progress {
  display: grid;
  grid-template-columns: repeat(20, 1fr);
  gap: 2px;
  height: 10px;
}

.album-progress i {
  border: 1.5px solid var(--plum);
  background: var(--card);
}

.album-progress i.is-filled {
  background: var(--strawberry);
}

.album-head-actions {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
}

.album-head-actions .btn {
  min-height: 42px;
  padding: 0 14px;
  font-size: 13.5px;
}


.chapter-rail {
  display: grid;
  grid-template-columns: repeat(9, minmax(0, 1fr));
  gap: 4px;
  padding: 8px;
  border: 2px solid var(--plum);
  border-radius: 10px;
  background: var(--card);
}

.chapter-node {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 2px;
  padding: 5px 2px;
  border: 0;
  border-radius: 6px;
  background: transparent;
  color: var(--plum);
  font-family: var(--font-pixel);
  font-size: 9px;
  cursor: pointer;
}

.chapter-node i {
  width: 13px;
  height: 13px;
  border: 2px solid var(--plum);
  border-radius: 3px;
  background: var(--card);
}

.chapter-node.is-current i,
.chapter-node:hover i {
  background: var(--sun);
}

.chapter-node.is-done i {
  background: var(--strawberry);
}

.chapter-node span {
  font-size: 8.5px;
  opacity: 0.7;
}


.album-chapter {
  display: flex;
  flex-direction: column;
  gap: 10px;
  scroll-margin-top: calc(var(--topbar-h) + var(--safe-top) + 16px);
}

.album-chapter-head {
  display: flex;
  align-items: baseline;
  gap: 10px;
  padding: 0 2px;
}

.album-chapter-no {
  color: var(--strawberry);
  font-family: var(--font-pixel);
  font-size: 12px;
  font-weight: 700;
}

.album-chapter-title {
  color: var(--plum);
  font-size: 19px;
  font-weight: 800;
  letter-spacing: 0.02em;
}

.album-section {
  display: flex;
  flex-direction: column;
  gap: 8px;
  padding: 10px;
  border: 2px solid var(--plum);
  border-radius: 10px;
  background: var(--card);
  scroll-margin-top: calc(var(--topbar-h) + var(--safe-top) + 16px);
}

.album-hero {
  position: relative;
  width: 100%;
  border: 3px solid var(--plum);
  border-radius: 6px;
  background: var(--plum);
  overflow: hidden;
  cursor: zoom-in;
}

.album-hero img,
.album-strip img {
  display: block;
  width: 100%;
  height: auto; 
  object-fit: contain;
}

.album-strip {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 5px;
}

.album-strip .album-photo {
  border: 2px solid var(--plum);
  border-radius: 4px;
  background: var(--plum);
  overflow: hidden;
  cursor: zoom-in;
}

.album-photo.is-collected {
  outline: 3px solid var(--mint);
  outline-offset: -1px;
}

.album-photo .collect-dot {
  position: absolute;
  right: 6px;
  bottom: 6px;
  z-index: 2;
  display: none;
  width: 14px;
  height: 14px;
  border: 2px solid var(--plum);
  border-radius: 3px;
  background: var(--mint);
}

.album-photo {
  position: relative;
}

.album-photo.is-collected .collect-dot {
  display: block;
}


.double-take {
  position: relative;
  width: 100%;
  aspect-ratio: 3 / 4;
  max-height: 62dvh;
  border: 3px solid var(--plum);
  border-radius: 6px;
  background: var(--plum);
  overflow: hidden;
  cursor: pointer;
}

.double-take img {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  object-fit: contain;
  opacity: 0;
  transition: opacity 480ms var(--ease-soft);
}

.double-take img.is-active {
  opacity: 1;
}

.double-take-hint {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 8px;
  padding: 2px 2px 0;
  color: var(--plum-soft);
  font-size: 13px;
}

.double-take-hint button {
  min-height: 36px;
  padding: 0 10px;
  border: 2px solid var(--plum);
  border-radius: 6px;
  background: var(--card);
  color: var(--plum);
  font-size: 12.5px;
  font-weight: 700;
  cursor: pointer;
}

.album-ending {
  padding: 18px 6px 26px;
  color: var(--plum);
  font-family: var(--font-display);
  font-size: 18px;
  letter-spacing: 0.06em;
  text-align: center;
  line-height: 1.7;
}

.album-locked {
  max-width: 34rem;
}


.lightbox {
  position: fixed;
  inset: 0;
  z-index: 90;
  display: grid;
  place-items: center;
  padding: calc(var(--safe-top) + 14px) 14px calc(var(--safe-bottom) + 14px);
  background: rgb(73 59 81 / 78%);
  -webkit-backdrop-filter: blur(4px);
  backdrop-filter: blur(4px);
}

.lightbox[hidden] {
  display: none;
}

.lightbox img {
  max-width: 100%;
  max-height: 82dvh;
  border: 3px solid var(--cream);
  border-radius: 6px;
  object-fit: contain;
}

.lightbox-bar {
  position: absolute;
  top: calc(var(--safe-top) + 10px);
  right: 14px;
  display: flex;
  gap: 8px;
}

.lightbox-bar button {
  min-height: 44px;
  padding: 0 14px;
  border: 2.5px solid var(--cream);
  border-radius: 8px;
  background: var(--plum);
  color: var(--cream);
  font-size: 13px;
  font-weight: 700;
  cursor: pointer;
}

.lightbox-caption {
  position: absolute;
  bottom: calc(var(--safe-bottom) + 14px);
  left: 50%;
  max-width: min(92vw, 40rem);
  padding: 6px 12px;
  border: 2px solid var(--cream);
  border-radius: 6px;
  background: var(--plum);
  color: var(--cream);
  font-size: 13px;
  transform: translateX(-50%);
}



.album-stories {
  display: grid;
  gap: 8px;
  margin-top: 4px;
}

.album-story {
  padding: 11px 12px;
  border: 2px dashed rgb(73 59 81 / 45%);
  border-radius: 8px;
  background: var(--paper);
  color: var(--plum);
  font-size: 16px;
  line-height: 1.75;
}

.album-story-tag {
  display: inline-block;
  margin-bottom: 4px;
  padding: 1px 7px;
  border: 2px solid var(--plum);
  border-radius: 4px;
  background: var(--sun);
  font-family: var(--font-pixel);
  font-size: 10px;
  font-weight: 700;
}


.album-resume {
  margin: 4px 0 0;
  padding: 8px 10px;
  border: 2px dashed rgb(73 59 81 / 40%);
  border-radius: 6px;
  background: var(--paper);
  color: var(--plum);
  font-size: 13px;
  line-height: 1.6;
}

.album-photo.is-resumed,
.double-take.is-resumed {
  outline: 3px solid var(--strawberry);
  outline-offset: 3px;
}


.album-quiz-note {
  margin: 2px 0 0;
  color: var(--ink-faint);
  font-size: 12.5px;
  line-height: 1.6;
}

.album-complete {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 8px;
  margin-top: 18px;
  padding: 18px 14px;
  border: 3px solid var(--plum);
  border-radius: 10px;
  background: var(--paper);
  box-shadow: var(--pixel-shadow-sm);
  text-align: center;
}

.album-complete-title {
  color: var(--plum);
  font-family: var(--font-display);
  font-size: 20px;
  font-weight: 700;
}

.album-complete-sub {
  color: var(--plum-soft);
  font-size: 14px;
  line-height: 1.6;
}

.album-complete .btn {
  min-height: 48px;
  padding: 0 22px;
}

.album-incomplete {
  margin-top: 16px;
  color: var(--plum-soft);
  font-size: 14px;
  line-height: 1.7;
  text-align: center;
}

.album-incomplete[hidden],
.album-complete[hidden] {
  display: none;
}



.album-finish {
  display: flex;
  flex-direction: column;
  gap: 8px;
  margin: 18px 0 calc(var(--safe-bottom) + 18px);
  padding: 18px 14px;
  border: 3px solid var(--plum);
  border-radius: 10px;
  background: var(--paper);
  box-shadow: var(--pixel-shadow);
  text-align: center;
}

.album-finish-kicker {
  color: var(--strawberry);
  font-family: var(--font-pixel);
  font-size: 10.5px;
  font-weight: 700;
  letter-spacing: 0.14em;
}

.album-finish-title {
  color: var(--plum);
  font-family: var(--font-display);
  font-size: 20px;
  font-weight: 700;
  line-height: 1.5;
}

.album-finish-sub,
.album-finish-hint {
  color: var(--plum-soft);
  font-size: 13.5px;
  line-height: 1.65;
}

.album-finish-hint {
  color: var(--ink-faint);
  font-size: 12.5px;
}

.album-manual-note {
  color: var(--strawberry);
  font-size: 12.5px;
  font-weight: 700;
  line-height: 1.6;
}

.album-manual-note[hidden] {
  display: none;
}

.album-finish .btn {
  width: 100%;
  min-height: 52px;
  margin-top: 4px;
  font-size: 16px;
}

.album-continue-confirm {
  position: fixed;
  inset: 0;
  z-index: 130;
  display: grid;
  place-items: center;
  padding: calc(var(--safe-top) + 18px) calc(var(--safe-right) + 18px)
    calc(var(--safe-bottom) + 18px) calc(var(--safe-left) + 18px);
  background: rgb(73 59 81 / 68%);
}

.album-continue-panel {
  width: min(100%, 380px);
  max-height: calc(100dvh - 36px);
  padding: 20px;
  overflow-y: auto;
  border: 3px solid var(--plum);
  border-radius: 10px;
  background: var(--paper);
  box-shadow: var(--pixel-shadow);
  text-align: center;
}

.album-continue-kicker {
  color: var(--strawberry);
  font-family: var(--font-pixel);
  font-size: 10.5px;
  font-weight: 700;
  letter-spacing: 0.14em;
}

.album-continue-panel h2 {
  margin: 8px 0;
  color: var(--plum);
  font-size: 18px;
  line-height: 1.55;
}

.album-continue-count {
  margin-bottom: 12px;
  color: var(--plum-soft);
  font-size: 13px;
  line-height: 1.65;
}

.album-continue-actions {
  display: grid;
  gap: 8px;
}

.album-continue-actions .btn {
  width: 100%;
  min-height: 48px;
  font-size: 14.5px;
}


.album-story-date {
  display: inline-block;
  margin-left: 8px;
  color: var(--strawberry);
  font-family: var(--font-pixel);
  font-size: 10.5px;
  font-weight: 700;
}
