/*
 * Event photo album (template-album.php). Loaded only on this template.
 * Dark page in the look of the AI Horizon Conference 2026 page.
 */

/* ---------- page shell: dark like the conference page ---------- */
body.page-template-template-album { background: #111; color: #fff; }
body.page-template-template-album .header,
body.page-template-template-album .footer { background: #111; }
body.page-template-template-album .header-top { background: rgba(255, 255, 255, .05); }
body.page-template-template-album .header-row:not(.sticky) .aiei-nav__top { color: #eaf0f5; }
body.page-template-template-album .header-row:not(.sticky) .aiei-nav__top .aiei-ico { color: #c6d5e2; }
body.page-template-template-album .header-row:not(.sticky) :is(.aiei-nav__top:hover, .aiei-nav__top[aria-expanded="true"], .is-current > .aiei-nav__top) { background: rgba(255, 255, 255, .08); }
body.page-template-template-album .header-row:not(.sticky) .aiei-acct__btn { background: transparent; color: #fff; border-color: rgba(234, 240, 245, .35); }

#aiei-album {
	--al-surface: #1a1a1a;
	--al-line: rgba(255, 255, 255, .1);
	--al-muted: rgba(255, 255, 255, .68);
	--al-accent: #cd5c2b;
	--al-btn: #bd4812;
	--al-btn-hover: #a63f10;
	--al-gap: 8px;
	--al-radius: 10px;
	background: #111;
	color: #fff;
	font-family: "Open Sans", sans-serif;
	-webkit-font-smoothing: antialiased;
}
#aiei-album ::selection { background: var(--al-accent); color: #fff; }
#aiei-album h1, #aiei-album h2 { text-wrap: balance; color: #fff; }
#aiei-album a:focus-visible, #aiei-album button:focus-visible { outline: 2px solid var(--al-accent); outline-offset: 3px; }

/* ---------- buttons ---------- */
#aiei-album .album-actions { display: flex; flex-wrap: wrap; gap: 12px; }
#aiei-album .album-btn {
	display: inline-flex; align-items: center; gap: 8px; height: 46px; padding: 0 22px;
	border-radius: 8px; background: var(--al-btn); color: #fff; text-decoration: none;
	font: 600 15px/1 "Open Sans", sans-serif; white-space: nowrap; border: 0; cursor: pointer;
	transition: background .2s ease, transform .1s ease;
}
#aiei-album .album-btn:hover { background: var(--al-btn-hover); color: #fff; }
#aiei-album .album-btn:active { transform: translateY(1px); }
#aiei-album .album-btn--ghost { background: transparent; box-shadow: inset 0 0 0 1px rgba(255, 255, 255, .3); }
#aiei-album .album-btn--ghost:hover { background: rgba(255, 255, 255, .08); }
#aiei-album .album-btn svg { flex: none; }

/* ---------- hero ---------- */
#aiei-album .album-hero { padding: 64px 0 56px; }
#aiei-album .album-hero__grid { display: grid; grid-template-columns: repeat(12, minmax(0, 1fr)); gap: 40px; align-items: center; }
#aiei-album .album-hero__grid::before, #aiei-album .album-hero__grid::after { content: none; } /* bootstrap clearfix on .container */
#aiei-album .album-hero__text { grid-column: span 5; display: flex; flex-direction: column; gap: 20px; }
#aiei-album .album-hero__grid > :only-child { grid-column: 1 / -1; max-width: 720px; }
#aiei-album .album-hero h1 { margin: 0; font-size: 52px; line-height: 1.15; font-weight: 700; letter-spacing: -.01em; }
#aiei-album .album-hero__meta { margin: 0; font-size: 15px; font-weight: 600; color: var(--al-accent); font-variant-numeric: tabular-nums; }
#aiei-album .album-hero__lead { font-size: 17px; line-height: 1.65; color: var(--al-muted); max-width: 46ch; }
#aiei-album .album-hero__lead > :first-child { margin-top: 0; }
#aiei-album .album-hero__lead > :last-child { margin-bottom: 0; }
#aiei-album .album-hero__lead a { color: #fff; }
#aiei-album .album-hero__media {
	grid-column: span 7; position: relative; display: block; width: 100%; aspect-ratio: 16 / 10;
	border-radius: 16px; overflow: hidden; background: var(--al-surface); border: 0; padding: 0;
	cursor: pointer; color: #fff; font-family: inherit;
}
#aiei-album .album-hero__media img { display: block; width: 100%; height: 100%; object-fit: cover; transition: transform .6s cubic-bezier(.16, 1, .3, 1); }
#aiei-album .album-hero__media:hover img { transform: scale(1.03); }
#aiei-album .album-hero__media::after { content: ""; position: absolute; inset: 0; background: linear-gradient(180deg, rgba(17, 17, 17, 0) 55%, rgba(17, 17, 17, .55)); pointer-events: none; }
#aiei-album .album-hero__play { position: absolute; inset: 0; z-index: 1; display: flex; align-items: center; justify-content: center; }
#aiei-album .album-hero__play span {
	display: inline-flex; align-items: center; justify-content: center; width: 84px; height: 84px; border-radius: 999px;
	background: var(--al-btn); color: #fff; box-shadow: 0 18px 40px rgba(0, 0, 0, .45);
	transition: transform .3s cubic-bezier(.16, 1, .3, 1);
}
#aiei-album .album-hero__media:hover .album-hero__play span { transform: scale(1.07); }
#aiei-album .album-hero__label { position: absolute; left: 20px; bottom: 16px; z-index: 1; font-size: 14px; font-weight: 600; color: #fff; text-shadow: 0 1px 8px rgba(0, 0, 0, .6); }

/* ---------- mosaic ---------- */
#aiei-album .album-photos { border-top: 1px solid var(--al-line); padding: 28px 0 96px; }
#aiei-album .album-photos__hint { margin: 0 0 20px; font-size: 14px; color: var(--al-muted); }
#aiei-album .album-photos__empty { margin: 40px 0 8px; font-size: 18px; }
#aiei-album .album-photos__admin { margin: 0; font-size: 14px; color: var(--al-muted); }
#aiei-album .album-mosaic { container-type: inline-size; display: flex; flex-direction: column; gap: var(--al-gap); }
#aiei-album .album-band {
	display: grid; grid-template-columns: repeat(12, minmax(0, 1fr));
	grid-auto-rows: calc((100cqw - 11 * var(--al-gap)) / 12); gap: var(--al-gap);
}
#aiei-album .album-tile { position: relative; display: block; overflow: hidden; border-radius: var(--al-radius); background: var(--al-surface); cursor: zoom-in; }
#aiei-album .album-tile img { display: block; width: 100%; height: 100%; object-fit: cover; transition: opacity .5s ease, transform .6s cubic-bezier(.16, 1, .3, 1); }
#aiei-album.is-js .album-tile img:not(.is-loaded) { opacity: 0; transform: scale(1.015); }
#aiei-album .album-tile:hover img { transform: scale(1.03); }
#aiei-album .album-tile::after { content: ""; position: absolute; inset: 0; border-radius: inherit; box-shadow: inset 0 0 0 1px rgba(255, 255, 255, .06); pointer-events: none; }

/* ---------- closing band ---------- */
#aiei-album .album-close { border-top: 1px solid var(--al-line); padding: 72px 0 88px; }
#aiei-album .album-close__row { display: flex; flex-wrap: wrap; gap: 32px; align-items: flex-end; justify-content: space-between; }
#aiei-album .album-close__row::before, #aiei-album .album-close__row::after { content: none; }
#aiei-album .album-close h2 { margin: 0 0 12px; font-size: 32px; line-height: 1.3; font-weight: 700; }
#aiei-album .album-close p { margin: 0; font-size: 16px; line-height: 1.65; color: var(--al-muted); max-width: 56ch; }

/* ---------- photo viewer ---------- */
.album-ibtn {
	position: relative; display: inline-flex; align-items: center; justify-content: center; width: 44px; height: 44px;
	border-radius: 999px; background: rgba(255, 255, 255, .08); color: #fff; border: 0; padding: 0; cursor: pointer;
	text-decoration: none; transition: background .2s ease;
}
.album-ibtn:hover { background: rgba(255, 255, 255, .18); color: #fff; }
.album-ibtn:focus-visible { outline: 2px solid #cd5c2b; outline-offset: 3px; }
.album-ibtn--lg { width: 56px; height: 56px; flex: none; }

#aiei-album .album-lb {
	position: fixed; inset: 0; width: 100%; height: 100%; max-width: none; max-height: none; margin: 0; padding: 0; border: 0;
	background: #0b0b0b; color: #fff; font-family: "Open Sans", sans-serif;
}
#aiei-album .album-lb::backdrop { background: #0b0b0b; }
#aiei-album .album-lb[open] { display: flex; flex-direction: column; animation: album-in .25s ease-out; }
@keyframes album-in { from { opacity: 0; } to { opacity: 1; } }
#aiei-album .album-lb__bar { height: 72px; flex: none; display: grid; grid-template-columns: 1fr auto 1fr; align-items: center; gap: 16px; padding: 0 20px; }
#aiei-album .album-lb__title { font-size: 15px; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; min-width: 0; }
#aiei-album .album-lb__count { font-size: 15px; color: var(--al-muted); font-variant-numeric: tabular-nums; }
#aiei-album .album-lb__tools { display: flex; gap: 8px; justify-content: flex-end; }
#aiei-album .album-lb__stage { position: relative; flex: 1; min-height: 0; display: flex; align-items: center; justify-content: center; gap: 20px; padding: 0 20px; touch-action: pan-y; }
#aiei-album .album-lb__frame { position: relative; flex: 1; min-width: 0; height: 100%; display: flex; align-items: center; justify-content: center; }
#aiei-album .album-lb__img { max-width: 100%; max-height: 100%; object-fit: contain; border-radius: 4px; user-select: none; -webkit-user-drag: none; transition: opacity .2s ease; }
#aiei-album .album-lb__img.is-swapping { opacity: 0; }
#aiei-album .album-lb__foot { height: 112px; flex: none; display: flex; align-items: center; padding: 0 20px; }
#aiei-album .album-lb__strip { flex: 1; min-width: 0; display: flex; gap: 8px; overflow-x: auto; scrollbar-width: none; padding: 6px 4px; scroll-behavior: smooth; }
#aiei-album .album-lb__strip::-webkit-scrollbar { display: none; }
#aiei-album .album-lb__thumb { flex: none; width: 88px; aspect-ratio: 3 / 2; border-radius: 6px; overflow: hidden; border: 0; padding: 0; cursor: pointer; opacity: .45; background: #1a1a1a; transition: opacity .2s ease, box-shadow .2s ease; }
#aiei-album .album-lb__thumb img { display: block; width: 100%; height: 100%; object-fit: cover; }
#aiei-album .album-lb__thumb:hover { opacity: .85; }
#aiei-album .album-lb__thumb[aria-current="true"] { opacity: 1; box-shadow: 0 0 0 2px #0b0b0b, 0 0 0 4px #cd5c2b; }
#aiei-album .album-lb__toast { position: absolute; left: 50%; bottom: 24px; transform: translateX(-50%); background: #fff; color: #111; font-size: 14px; font-weight: 600; padding: 10px 16px; border-radius: 8px; opacity: 0; pointer-events: none; transition: opacity .2s ease; max-width: 90vw; overflow-wrap: anywhere; }
#aiei-album .album-lb__toast.is-on { opacity: 1; }

/* ---------- recap video ---------- */
#aiei-album .album-video { border: 0; padding: 0; background: transparent; max-width: min(1100px, 92vw); width: 100%; overflow: visible; }
#aiei-album .album-video::backdrop { background: rgba(0, 0, 0, .85); }
#aiei-album .album-video__box { position: relative; aspect-ratio: 16 / 9; background: #000; border-radius: 12px; overflow: hidden; }
#aiei-album .album-video__box video { display: block; width: 100%; height: 100%; }
#aiei-album .album-video__close { position: absolute; top: 12px; right: 12px; z-index: 2; }

/* ---------- responsive (theme breakpoints) ---------- */
@media only screen and (max-width: 1023px) {
	#aiei-album .album-hero__grid { gap: 28px; }
	#aiei-album .album-hero__text, #aiei-album .album-hero__media { grid-column: 1 / -1; }
	#aiei-album .album-hero h1 { font-size: 40px; }
}
@media only screen and (max-width: 743px) {
	#aiei-album .album-hero { padding: 40px 0; }
	#aiei-album .album-hero h1 { font-size: 32px; }
	#aiei-album .album-close h2 { font-size: 26px; }
	#aiei-album .album-mosaic { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); grid-auto-flow: dense; gap: 6px; }
	#aiei-album .album-band { display: contents; }
	#aiei-album .album-tile { grid-column: auto !important; grid-row: auto !important; aspect-ratio: 4 / 5; }
	#aiei-album .album-tile[data-o="L"]:is([data-size="xl"], [data-size="lg"]) { grid-column: 1 / -1 !important; aspect-ratio: 3 / 2; }
	#aiei-album .album-lb__bar { grid-template-columns: 1fr auto; }
	#aiei-album .album-lb__title { display: none; }
	#aiei-album .album-lb__stage { padding: 0; }
	#aiei-album .album-lb__stage .album-ibtn--lg { display: none; }
	#aiei-album .album-lb__foot { height: 88px; }
}
@media (prefers-reduced-motion: reduce) {
	#aiei-album *, #aiei-album *::before, #aiei-album *::after { transition: none !important; animation: none !important; }
	#aiei-album.is-js .album-tile img:not(.is-loaded) { opacity: 1; transform: none; }
}
