.album-preview, .album-grid {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: clamp(.65rem, 2vw, 1.2rem);
}
.album-preview { margin-top: clamp(1.2rem, 3vw, 2.15rem); }
.album-photo {
  display: block;
  min-width: 0;
  border-radius: .85rem;
  color: var(--ink);
  text-decoration: none;
  scroll-margin-top: 1.2rem;
}
.album-card {
  display: grid;
  height: 100%;
  grid-template-rows: 1fr auto;
  overflow: hidden;
  border: 1px solid #c9d9f0;
  border-radius: inherit;
  background: #fff;
}
.album-screen {
  display: grid;
  place-items: center;
  overflow: hidden;
  padding: clamp(.7rem, 1.65vw, 1.15rem);
  background: linear-gradient(145deg, #edf4ff, #dce9fd);
}
.album-screen img {
  width: min(100%, 11.7rem);
  height: auto;
  border: 1px solid #c8d6e9;
  border-radius: .7rem;
  box-shadow: 0 .35rem 1.05rem #16385b2b;
}
.album-card figcaption {
  padding: .65rem .75rem;
  border-top: 1px solid #dce5f1;
  font-size: clamp(.83rem, 1.4vw, 1rem);
  font-weight: 690;
  text-align: center;
}
.album-photo:hover .album-card, .album-photo:target .album-card { border-color: #75a2e4; }
.album-photo:hover figcaption { color: var(--primary); }

.download-band { align-items: center; }
.download-continue { margin-top: .85rem; }
.store-qr-grid {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: clamp(.65rem, 2vw, 1rem);
}
.store-qr {
  display: grid;
  justify-items: center;
  min-width: 0;
  padding: clamp(.55rem, 1.6vw, .95rem);
  border: 1px solid #bfcfeb;
  border-radius: .75rem;
  background: #fff;
  color: #163d78;
  text-align: center;
  text-decoration: none;
}
.store-qr:hover { border-color: var(--primary); }
.store-qr img {
  width: 147px;
  max-width: 100%;
  height: auto;
  aspect-ratio: 1;
  image-rendering: pixelated;
}
.store-qr-platform { margin-top: .15rem; color: var(--muted); font-size: .78rem; }
.store-qr strong { font-size: 1rem; white-space: nowrap; }
.store-qr strong span { margin-left: .1rem; color: var(--primary); }

.album-hero {
  padding-block: clamp(2.3rem, 5vw, 4.3rem);
  color: #fff;
  background: linear-gradient(115deg, var(--night), #154991 72%, var(--primary));
}
.album-hero h1 {
  margin-top: .55rem;
  font-size: clamp(2.35rem, 6.25vw, 4.65rem);
  line-height: 1.09;
  letter-spacing: -.052em;
}
.album-hero p { margin-top: .7rem; color: #e2efff; font-size: clamp(1rem, 1.8vw, 1.2rem); }
.album-back { color: #e2efff; text-decoration: none; font-weight: 680; }
.album-back:hover { text-decoration: underline; text-underline-offset: .18em; }
.album-back:focus-visible { outline-color: #a0d4ff; }
.album-main { padding-block: clamp(1.55rem, 3.7vw, 2.8rem) clamp(3rem, 6vw, 5rem); }
.album-jumps { display: flex; flex-wrap: wrap; gap: .55rem; }
.album-jumps a {
  display: inline-flex;
  align-items: center;
  min-height: 2.45rem;
  padding: .36rem .7rem;
  border: 1px solid #c4d6f1;
  border-radius: .5rem;
  background: #fff;
  color: #225198;
  font-size: .93rem;
  font-weight: 650;
  text-decoration: none;
}
.album-jumps a:hover { border-color: #7ea7e9; background: #edf4ff; }
.album-group { margin-top: clamp(1.8rem, 4vw, 3.4rem); }
.album-group h2 { margin-bottom: 1rem; font-size: clamp(1.55rem, 3.95vw, 2.4rem); }
.album-group:target > h2 { color: var(--primary); }

.album-open { overflow: hidden; }
.album-dialog {
  inline-size: min(calc(100vw - 1.25rem), 39rem);
  max-block-size: calc(100dvh - 1rem);
  padding: 0;
  border: 1px solid #5478a4;
  border-radius: .85rem;
  background: #102c55;
  color: #fff;
}
.album-dialog::backdrop { background: #061327e8; }
.album-viewer { display: grid; }
.album-viewer-head, .album-viewer-foot {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: .55rem;
  padding: .65rem clamp(.6rem, 2vw, 1rem);
}
.album-viewer-head h2 { font-size: clamp(1rem, 2.7vw, 1.28rem); letter-spacing: -.02em; }
.album-control {
  display: inline-flex;
  gap: .4rem;
  align-items: center;
  justify-content: center;
  min-height: 2.45rem;
  padding: .33rem .58rem;
  border: 1px solid #a3c3ec68;
  border-radius: .45rem;
  background: #1a4276;
  color: inherit;
  font-family: inherit;
  font-size: .87rem;
  font-weight: 640;
  white-space: nowrap;
  cursor: pointer;
}
.album-control:hover { background: #295990; }
.album-control:focus-visible { outline-color: #9edaff; }
.album-position { color: #dcecff; font-size: .88rem; font-variant-numeric: tabular-nums; white-space: nowrap; }
.album-viewer-photo {
  display: grid;
  place-items: center;
  background: #091c37;
  padding: .4rem;
}
.album-viewer-photo img {
  width: 100%;
  height: min(71dvh, 45rem);
  object-fit: contain;
  touch-action: pan-y pinch-zoom;
  user-select: none;
}

@media (max-width: 54rem) {
  .site-nav .section-link--album { display: none; }
  .album-grid { grid-template-columns: repeat(3, minmax(0, 1fr)); }
  .download-band { align-items: flex-start; }
  .store-qr-grid { width: min(100%, 22rem); }
}

@media (max-width: 40rem) {
  .album-preview, .album-grid { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .album-screen img { border-radius: .5rem; }
  .album-card figcaption { padding-inline: .45rem; }
  .album-jumps a { font-size: .85rem; }
}

@media (max-width: 28rem) {
  .store-qr { padding-inline: .42rem; }
  .store-qr img { width: 98px; }
}
