:root {
  --bg: #0e0e10;
  --gap: 6px;
}

* {
  box-sizing: border-box;
}

html,
body {
  margin: 0;
  padding: 0;
  background: var(--bg);
}

body.locked {
  overflow: hidden;
}

#gallery {
  position: relative;
  width: 100%;
}

.tile {
  position: absolute;
  top: 0;
  left: 0;
  margin: 0;
  padding: 0;
  border: 0;
  background: none;
  overflow: hidden;
  cursor: zoom-in;
  -webkit-appearance: none;
  appearance: none;
  -webkit-tap-highlight-color: transparent;
  will-change: transform;
}

.tile:focus-visible {
  outline: 2px solid rgba(255, 255, 255, 0.65);
  outline-offset: -2px;
}

.tile img {
  display: block;
  width: 100%;
  height: 100%;
  pointer-events: none;
  user-select: none;
  -webkit-user-drag: none;
}

#lightbox {
  position: fixed;
  inset: 0;
  z-index: 10;
  display: none;
  align-items: center;
  justify-content: center;
  background: rgba(8, 8, 10, 0.94);
  cursor: zoom-out;
}

#lightbox.open {
  display: flex;
}

#lightbox img {
  display: block;
  width: auto;
  height: auto;
  max-width: 96vw;
  max-height: 96vh;
}
