/* THE GALLERY VIEWER (2026-10-07): her gallery's pictures full screen, one at a time. Hayden: "make it so that on
   their galleries, I can click or tap on an image to see it full screen". Code/gallery/README.md.
   Every picture is shown WHOLE (contain): the controls sit at the top and at the middle of each side, so nothing covers
   or crops its bottom-right corner, where the mark is. The buttons are glass over art (design-system.md §8), the accent
   #ef4444 on hover and focus, the icons drawn (§7). */

.wiki-gallery__tile.is-open { cursor: zoom-in; }
.wiki-gallery__tile.is-open:focus-visible { outline: 2px solid #ef4444; outline-offset: 3px; }

html.ll-lb-open,
html.ll-lb-open body { overflow: hidden; }

.ll-lb {
	position: fixed;
	inset: 0;
	z-index: 9000;                                         /* over the menu bar (1000) and search (2000); under the age gate */
	background: #060607;                                   /* solid: the page is gone while she is on screen */
	opacity: 0;
	transition: opacity 150ms ease;
	overscroll-behavior: contain;
	-webkit-tap-highlight-color: transparent;
}
.ll-lb[hidden] { display: none; }
.ll-lb.is-on { opacity: 1; }
.ll-lb:fullscreen { background: #000; }
.ll-lb:-webkit-full-screen { background: #000; }

.ll-lb__stage {
	position: absolute;
	inset: 0;
	display: flex;
	align-items: center;
	justify-content: center;
	padding: 68px 88px 40px;
	cursor: zoom-out;
}
.ll-lb__img {
	display: block;
	max-width: 100%;
	max-height: 100%;
	width: auto;
	height: auto;
	object-fit: contain;
	cursor: default;
	-webkit-user-select: none;
	user-select: none;
	-webkit-user-drag: none;
	transition: opacity 150ms ease;
}
.ll-lb.is-loading .ll-lb__img { opacity: .4; }
.ll-lb.is-error .ll-lb__img { opacity: 0; }
.ll-lb.is-error .ll-lb__stage::after {
	content: "This picture didn\2019t load. Try the next one.";
	position: absolute;
	font: 500 15px/1.4 var(--font-body, sans-serif);
	color: #b0b0b0;
}

.ll-lb__bar {
	position: absolute;
	top: 0;
	left: 0;
	right: 0;
	display: flex;
	align-items: center;
	justify-content: space-between;
	padding: 12px 14px 12px 20px;
	pointer-events: none;
	transition: opacity 150ms ease;
}
.ll-lb__bar > * { pointer-events: auto; }
.ll-lb__count {
	font: 600 13px/1 var(--font-body, sans-serif);
	letter-spacing: .06em;
	color: #f0f0f0;
	font-variant-numeric: tabular-nums;
}
.ll-lb__tools { display: flex; gap: 8px; }

.ll-lb__btn {
	-webkit-appearance: none;
	appearance: none;
	display: inline-flex;
	align-items: center;
	justify-content: center;
	width: 44px;
	height: 44px;
	padding: 0;
	border-radius: 999px;
	border: 1px solid rgba(255, 255, 255, .16);
	background: rgba(10, 10, 10, .55);
	-webkit-backdrop-filter: blur(10px);
	backdrop-filter: blur(10px);
	color: #f0f0f0;
	cursor: pointer;
	transition: color 150ms ease, border-color 150ms ease, opacity 150ms ease;
}
.ll-lb__btn[hidden] { display: none; }
.ll-lb__btn svg { width: 20px; height: 20px; }
.ll-lb__btn:hover { color: #ef4444; border-color: rgba(239, 68, 68, .6); }
.ll-lb__btn:focus-visible { outline: 2px solid #ef4444; outline-offset: 2px; }

.ll-lb__nav {
	position: absolute;
	top: 50%;
	width: 52px;
	height: 52px;
	margin-top: -26px;
}
.ll-lb__nav svg { width: 24px; height: 24px; }
.ll-lb__prev { left: 18px; }
.ll-lb__next { right: 18px; }
.ll-lb.is-single .ll-lb__nav { display: none; }

/* a tap on the picture moves the controls aside, and another brings them back */
.ll-lb.ui-off .ll-lb__bar,
.ll-lb.ui-off .ll-lb__nav { opacity: 0; pointer-events: none; }
.ll-lb.ui-off .ll-lb__bar > * { pointer-events: none; }

/* phones: the picture takes the width; the arrows are smaller and lighter over her edges; a swipe does the same */
@media (max-width: 640px) {
	.ll-lb__stage { padding: 60px 0 20px; }
	.ll-lb__bar { padding: 8px 8px 8px 16px; }
	.ll-lb__nav { width: 40px; height: 40px; margin-top: -20px; background: rgba(10, 10, 10, .4); }
	.ll-lb__nav svg { width: 20px; height: 20px; }
	.ll-lb__prev { left: 8px; }
	.ll-lb__next { right: 8px; }
}

@media (prefers-reduced-motion: reduce) {
	.ll-lb,
	.ll-lb__img,
	.ll-lb__bar,
	.ll-lb__btn { transition: none; }
}
