/* css/viewer.css - the full-screen gallery viewer (scripts/gallery/viewer.js). */

html.gv-lock, html.gv-lock body { overflow: hidden; }

.gv { --v-bg: #050608; --v-ink: #e8e6e1; --v-dim: rgba(232, 230, 225, .55); --v-faint: rgba(232, 230, 225, .3);
  position: fixed; inset: 0; z-index: 1000; background: var(--v-bg); color: var(--v-ink);
  font-family: ui-monospace, SFMono-Regular, Menlo, Consolas, "Liberation Mono", monospace; animation: gv-in 220ms ease-out; }
@keyframes gv-in { from { opacity: 0; } }

.gv-stage { position: absolute; inset: 0; cursor: grab; touch-action: none; user-select: none; -webkit-user-select: none; }
.gv-stage.is-dragging { cursor: grabbing; }
.gv-grid { position: absolute; inset: 0; width: 100%; height: 100%; display: block; }
.gv-plate { position: absolute; left: 0; top: 0; transform-origin: 0 0; will-change: transform; pointer-events: none;
  box-shadow: 0 40px 120px rgba(0, 0, 0, .85), 0 10px 30px rgba(0, 0, 0, .6); }
.gv-layer { position: absolute; inset: 0; width: 100%; height: 100%; max-width: none; display: block; user-select: none; -webkit-user-drag: none;
  transition: opacity 520ms cubic-bezier(.4, 0, .2, 1); }
.gv-placeholder { filter: blur(0.5px); }

.gv-close { position: absolute; top: 20px; right: 20px; z-index: 10; width: 44px; height: 44px; border: 0; border-radius: 50%;
  background: rgba(5, 6, 8, .55); cursor: pointer; backdrop-filter: blur(6px); }
.gv-close::before, .gv-close::after { content: ""; position: absolute; left: 13px; top: 21px; width: 18px; height: 1.5px; background: var(--v-ink); }
.gv-close::before { transform: rotate(45deg); }
.gv-close::after { transform: rotate(-45deg); }
.gv-close:hover { background: rgba(255, 255, 255, .12); }
.gv button:focus-visible { outline: 2px solid #fbbf24; outline-offset: 3px; }

.gv-shade { position: absolute; left: 0; right: 0; bottom: 0; height: 260px; z-index: 5; pointer-events: none; transition: opacity 300ms;
  background: linear-gradient(to top, rgba(5, 6, 8, .92), rgba(5, 6, 8, .6) 45%, rgba(5, 6, 8, 0)); }
.gv-bottom-shade { display: none; }

.gv-meta { position: absolute; left: 28px; bottom: 26px; z-index: 10; max-width: 440px; pointer-events: none;
  text-shadow: 0 1px 12px rgba(0, 0, 0, .9); transition: opacity 300ms; }
.gv-cat { font-size: 12px; letter-spacing: .2em; color: var(--v-dim); text-transform: uppercase; }
.gv-title { margin: 6px 0 16px; font-size: 28px; font-weight: 600; letter-spacing: .02em; line-height: 1.2; }
.gv-meta dl { display: grid; grid-template-columns: auto 1fr; gap: 5px 18px; margin: 0; font-size: 12.5px; }
.gv-meta dt { color: var(--v-faint); text-transform: uppercase; letter-spacing: .12em; font-size: 11px; padding-top: 1px; }
.gv-meta dd { margin: 0; }

.gv-layers { position: absolute; left: 50%; bottom: 26px; transform: translateX(-50%); z-index: 10; display: flex; gap: 26px;
  font-size: 13px; letter-spacing: .14em; text-transform: uppercase; }
.gv-layers button { background: none; border: 0; padding: 6px 0; color: var(--v-dim); font: inherit; letter-spacing: inherit; text-transform: inherit;
  cursor: pointer; border-bottom: 1px solid transparent; }
.gv-layers button:hover { color: var(--v-ink); }
.gv-layers button:disabled { cursor: progress; opacity: .5; }
.gv-layers button[aria-pressed="true"] { color: var(--v-ink); border-bottom-color: #fbbf24; }

.gv-details { display: none; }
.gv-readout { position: absolute; right: 28px; bottom: 26px; z-index: 10; font-size: 12px; color: var(--v-dim); text-align: right; line-height: 1.8; }
.gv-readout b { color: var(--v-ink); font-weight: 500; }
.gv-keys { color: var(--v-faint); }

.gv.is-bare .gv-meta, .gv.is-bare .gv-shade { opacity: 0; }

@media (hover: none) { .gv-keys { display: none; } }

@media (max-width: 700px) {
  .gv-close { top: 14px; right: 12px; }
  .gv-meta { left: 18px; right: 72px; top: 18px; bottom: auto; max-width: none; pointer-events: auto; }
  .gv-cat { font-size: 11px; }
  .gv-title { font-size: 20px; margin: 4px 0 0; }
  .gv-meta dl { position: fixed; left: 0; right: 0; bottom: 0; z-index: 12; padding: 22px 20px calc(84px + env(safe-area-inset-bottom));
    background: rgba(5, 6, 8, .96); border-top: 1px solid rgba(232, 230, 225, .12);
    transform: translateY(100%); transition: transform 280ms cubic-bezier(.2, .7, .2, 1); }
  .gv-meta.is-open dl { transform: none; }
  .gv.is-bare .gv-meta { opacity: 1; }
  .gv-shade { top: 0; bottom: auto; height: 140px; background: linear-gradient(to bottom, rgba(5, 6, 8, .85), rgba(5, 6, 8, 0)); }
  .gv-bottom-shade { display: block; position: absolute; left: 0; right: 0; bottom: 0; height: 90px; z-index: 11; pointer-events: none;
    background: linear-gradient(to top, rgba(5, 6, 8, .9), rgba(5, 6, 8, 0)); }
  .gv-layers { left: 18px; transform: none; bottom: calc(18px + env(safe-area-inset-bottom)); z-index: 13; gap: 20px; font-size: 12px; }
  .gv-readout { display: none; }
  .gv-details { display: block; position: absolute; right: 18px; bottom: calc(18px + env(safe-area-inset-bottom)); z-index: 13;
    background: none; border: 0; color: var(--v-dim); font: inherit; font-size: 12px; letter-spacing: .14em; text-transform: uppercase; padding: 6px 0; }
  .gv-details[aria-expanded="true"] { color: var(--v-ink); }
}
