.trigger { cursor: zoom-in; } .overlay { position: fixed; inset: 0; z-index: 1000; background: rgba(0, 0, 0, 0.85); display: flex; align-items: center; justify-content: center; padding: 24px; overflow: hidden; overscroll-behavior: none; } .container { display: flex; flex-direction: column; align-items: center; max-width: calc(100vw - 48px); max-height: calc(100vh - 48px); } .imageWrapper { width: calc((100vh - 100px) * var(--lb-ratio)); max-width: calc(100vw - 48px); aspect-ratio: var(--lb-ratio); flex-shrink: 0; cursor: default; } .imageWrapper.zoomed { cursor: zoom-out; } .image { display: block; width: 100%; height: 100%; object-fit: contain; } .closeButton { margin-top: 12px; padding: 0; background: none; border: none; color: hsla(0, 0%, 100%, 0.5); cursor: pointer; font-family: system-ui, sans-serif; font-size: 0.9rem; flex-shrink: 0; transition: color 0.15s; } .closeButton:hover { color: hsla(0, 0%, 100%, 0.85); }