.album {
  position: fixed;
  inset: 0;
  z-index: 1;
  background: #0e0e0e;
  color: #e0e5e9;
  font: 14px Tahoma, Verdana, sans-serif;
}
.album.album-final { background: transparent; pointer-events: none; }
.album .sr-only { position: absolute; margin: 0; }
#album-image {
  display: block;
  width: 100%;
  height: 100%;
  object-fit: cover;
}
.album-nav {
  position: absolute;
  inset: auto 0 max(12px, env(safe-area-inset-bottom));
  display: grid;
  justify-items: center;
  padding-inline: 10px;
  pointer-events: none;
}
.album-controls {
  display: grid;
  grid-template-columns: minmax(98px, 1fr) auto minmax(98px, 1fr);
  align-items: center;
  gap: clamp(6px, 2vw, 16px);
  text-align: center;
}
#album-count {
  padding: 6px 8px;
  border-radius: 4px;
  background: #14181ce0;
  font-variant-numeric: tabular-nums;
  white-space: nowrap;
}
.album-nav button, .album-end button {
  min-height: 44px;
  border: 1px solid #cbd0d573;
  border-radius: 4px;
  background: #171c22eb;
  color: #f2f4f6;
  white-space: nowrap;
  pointer-events: auto;
}
.album-nav button:enabled:hover, .album-end button:hover { background: #303943; }
.album-nav button:disabled { visibility: hidden; }
.album-final #album-next:disabled { visibility: visible; }
.album-nav button span[aria-hidden] { font-size: 19px; line-height: .8; }
.album-end {
  position: absolute;
  inset: 0;
  align-content: center;
  justify-items: center;
  display: grid;
  text-align: center;
  padding: 22px;
}
.album-end h2 { margin: 0 0 8px; font-size: clamp(25px, 5vw, 38px); }
.album-end p { margin: 5px 0; }
.album-end button { margin-top: 19px; }
.album .photo-frame { background: #181818; }
.album[data-number="2"] .photo-frame {
  width: 100%;
  height: 100vh;
  height: 100dvh;
  background: inherit;
}
.album[data-number="2"] #album-image { object-fit: contain; }
.album-image-loading { animation: album-photo-bands 940ms step-end both; }
@keyframes album-photo-bands {
  0% { clip-path: inset(0 0 80%); }
  28% { clip-path: inset(0 0 56%); }
  62% { clip-path: inset(0 0 27%); }
  100% { clip-path: inset(0); }
}
@media (prefers-reduced-motion: reduce) {
  .album-image-loading { animation-duration: 1ms; }
}

.windows-error {
  width: min(402px, calc(100vw - 20px));
  max-width: none;
  padding: 0 5px 5px;
  color: #161616;
  border: 1px solid #29343d;
  border-radius: 7px;
  background: linear-gradient(155deg, #e5f1fa9e, #98b5ca9c 39%, #d6e3ecd4 75%);
  backdrop-filter: blur(10px);
  box-shadow: 0 0 0 1px #f4f9f67a inset, 2px 5px 13px #0009;
  font: 12px "Segoe UI", Tahoma, Arial, sans-serif;
}
.windows-error::backdrop { background: transparent; }
.windows-error form { margin: 0; }
.windows-error header {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  gap: 8px;
  min-height: 24px;
  padding-left: 4px;
  color: #161616;
  text-shadow: 0 0 5px #fff, 0 0 8px #fff;
}
.windows-error header span { padding-top: 5px; }
.windows-error .windows-close {
  width: 45px;
  min-height: 17px;
  flex: 0 0 45px;
  padding: 0;
  border: 1px solid #8b5c56;
  border-top: 0;
  border-radius: 0 0 4px 4px;
  background: linear-gradient(#ecab9d, #c96756 49%, #b84437 51%, #d68573);
  box-shadow: inset 0 0 0 1px #ffe0d183;
  color: #fff;
  text-shadow: 0 1px 1px #692d29;
  font: bold 14px/15px "Segoe UI", Arial, sans-serif;
}
.windows-error .windows-close:hover { background: linear-gradient(#ffb290, #d04a33 54%, #df6d4d); }
.windows-body {
  border: 1px solid #566370;
  background: #f0f0f0;
  box-shadow: 0 0 0 1px #fff9;
}
.windows-message { display: flex; align-items: flex-start; gap: 12px; padding: 12px 13px 13px; }
.windows-icon { flex: 0 0 29px; }
.windows-message p { margin: 0; line-height: 1.34; }
#album-error-help { margin-top: 8px; }
.windows-error footer { display: flex; justify-content: center; gap: 7px; padding: 6px 10px 9px; }
.windows-error footer button {
  min-width: 76px;
  min-height: 22px;
  padding: 2px 8px;
  border: 1px solid #8e8f8f;
  border-radius: 3px;
  color: #111;
  background: linear-gradient(#fff, #f0f0f0 49%, #e3e3e3 51%, #f2f2f2);
  box-shadow: inset 0 0 0 1px #fff9;
}
.windows-error footer button[autofocus] {
  border-color: #3984a8;
  box-shadow: inset 0 0 0 1px #75c6e5;
  background: linear-gradient(#f4fbff, #e5f4fc 49%, #caeaf9 51%, #e9f7ff);
}
.windows-error footer button:hover { background: #e6f5ff; }
.windows-error button:focus-visible { outline: 1px dotted #242424; outline-offset: -4px; }
