.hg-archive {
	--hg-ink: #454f5e;
	--hg-heading: #52656a;
	--hg-accent: #3aa6b9;
	--hg-muted: #6d7a82;
	--hg-line: #e3e8ea;
	--hg-paper: #f4f7f8;
	width: 100%;
	margin: 0.5rem 0 3rem;
	color: var(--hg-ink);
	font-family: "Open Sans", sans-serif;
}

.hg-archive__title {
	margin: 0.25rem 0 1.35rem;
	color: var(--hg-heading);
	font-family: "Open Sans", sans-serif;
	font-size: 1.65rem;
	font-weight: 600;
	letter-spacing: 0.06em;
	line-height: 1.25;
	text-transform: uppercase;
}

.hg-archive__tabs {
	display: flex;
	flex-wrap: wrap;
	gap: 0 1.35rem;
	margin: 0 0 0.25rem;
	border-bottom: 1px solid var(--hg-line);
}

.hg-archive__tab {
	appearance: none;
	margin: 0 0 -1px;
	padding: 0.85rem 0 0.7rem;
	border: 0;
	border-bottom: 2px solid transparent;
	border-radius: 0;
	background: transparent;
	box-shadow: none;
	color: var(--hg-muted);
	font: inherit;
	font-size: 0.95rem;
	font-weight: 600;
	line-height: 1.35;
	cursor: pointer;
}

.hg-archive .hg-archive__tab:hover,
.hg-archive .hg-archive__tab:focus,
.hg-archive .hg-archive__tab:active {
	background: transparent !important;
	background-color: transparent !important;
	box-shadow: none;
	color: var(--hg-heading);
}

.hg-archive__tab[aria-selected="true"] {
	color: var(--hg-heading);
	border-bottom-color: var(--hg-accent);
}

.hg-archive__tab:focus-visible {
	outline: 2px solid var(--hg-accent);
	outline-offset: 3px;
}

.hg-archive__count {
	margin-left: 0.35em;
	color: var(--hg-muted);
	font-size: 0.78rem;
	font-weight: 500;
}

.hg-archive__tab[aria-selected="true"] .hg-archive__count {
	color: var(--hg-accent);
}

.hg-archive__count.is-zero {
	opacity: 0.7;
}

.hg-archive__panel[hidden] {
	display: none !important;
}

.hg-archive__list {
	list-style: none;
	margin: 0;
	padding: 0;
}

.hg-archive__item {
	display: grid;
	grid-template-columns: 108px minmax(0, 1fr) auto;
	gap: 0 1.35rem;
	align-items: center;
	padding: 1.05rem 0.35rem;
	border-bottom: 1px solid var(--hg-line);
	color: inherit;
	text-decoration: none;
}

.hg-archive__item:hover,
.hg-archive__item:focus-visible {
	background: transparent;
}

.hg-archive__item:focus-visible {
	outline: 2px solid var(--hg-accent);
	outline-offset: -2px;
}

.hg-archive__thumb {
	display: block;
	width: 108px;
	height: 132px;
	overflow: hidden;
	border: 1px solid var(--hg-line);
	background-color: #f7f5f2;
	background-repeat: no-repeat;
	background-position: center;
	background-size: contain;
}

.hg-archive__thumb img {
	display: none !important;
}

.hg-archive__thumb--pdf {
	display: flex;
	align-items: center;
	justify-content: center;
}

.hg-archive__file {
	color: var(--hg-heading);
	font-size: 13px;
	font-weight: 700;
	letter-spacing: 0.08em;
}

.hg-archive__caption {
	margin: 0;
	font-size: 1rem;
	line-height: 1.55;
}

.hg-archive__open {
	color: var(--hg-accent);
	font-size: 0.92rem;
	font-weight: 600;
	white-space: nowrap;
}

.hg-archive__item:hover .hg-archive__open,
.hg-archive__item:focus-visible .hg-archive__open {
	text-decoration: underline;
	text-underline-offset: 0.18em;
}

.hg-archive__empty {
	margin: 0;
	padding: 2.75rem 0.25rem;
	color: var(--hg-muted);
	font-size: 0.98rem;
	line-height: 1.5;
}

.hg-lightbox[hidden] {
	display: none !important;
}

.hg-lightbox {
	position: fixed;
	inset: 0;
	z-index: 100000;
	display: flex;
	align-items: center;
	justify-content: center;
	padding: 4.5rem 5.5rem 2rem;
}

.hg-lightbox__backdrop,
.hg-lightbox__backdrop:hover,
.hg-lightbox__backdrop:focus,
.hg-lightbox__backdrop:active {
	position: absolute;
	inset: 0;
	border: 0;
	border-radius: 0;
	box-shadow: none;
	background: rgba(22, 28, 30, 0.94) !important;
	background-color: rgba(22, 28, 30, 0.94) !important;
	color: transparent;
	cursor: pointer;
}

.hg-lightbox__dialog {
	position: relative;
	z-index: 1;
	display: flex;
	flex-direction: column;
	align-items: center;
	width: min(1080px, 100%);
	max-height: 100%;
	margin: 0;
}

.hg-lightbox__dialog img {
	display: block;
	width: auto;
	max-width: 100%;
	height: auto;
	max-height: calc(100vh - 11rem);
	object-fit: contain;
	box-shadow: 0 18px 50px rgba(0, 0, 0, 0.35);
	background: #f7f4ef;
}

.hg-lightbox__meta {
	width: min(42rem, 100%);
	margin-top: 0.9rem;
	color: #f4f7f7;
	text-align: center;
}

.hg-lightbox__index {
	display: block;
	margin-bottom: 0.35rem;
	color: rgba(244, 247, 247, 0.62);
	font-size: 0.78rem;
	letter-spacing: 0.08em;
}

.hg-lightbox__text {
	display: block;
	font-size: 0.98rem;
	line-height: 1.5;
}

.hg-lightbox__text:empty {
	display: none;
}

.hg-lightbox__close,
.hg-lightbox__nav {
	position: absolute;
	z-index: 2;
	display: flex;
	align-items: center;
	justify-content: center;
	width: 44px;
	height: 44px;
	padding: 0;
	border: 0;
	border-radius: 50%;
	background: rgba(255, 255, 255, 0.12);
	color: #fff;
	cursor: pointer;
}

.hg-lightbox__close:hover,
.hg-lightbox__nav:hover,
.hg-lightbox__close:focus-visible,
.hg-lightbox__nav:focus-visible {
	background: rgba(255, 255, 255, 0.22);
	outline: 2px solid #fff;
	outline-offset: 2px;
}

.hg-lightbox__close {
	top: 16px;
	right: 16px;
}

.hg-lightbox__nav--prev {
	top: 50%;
	left: 16px;
	transform: translateY(-50%);
}

.hg-lightbox__nav--next {
	top: 50%;
	right: 16px;
	transform: translateY(-50%);
}

.hg-lightbox__nav[hidden] {
	display: none !important;
}

html.hg-lightbox-open,
html.hg-lightbox-open body {
	overflow: hidden;
}

@media (max-width: 782px) {
	.hg-archive__tabs {
		flex-wrap: nowrap;
		gap: 0 1.1rem;
		overflow-x: auto;
		-webkit-overflow-scrolling: touch;
		scrollbar-width: none;
	}

	.hg-archive__tabs::-webkit-scrollbar {
		display: none;
	}

	.hg-archive__tab {
		flex: 0 0 auto;
		white-space: nowrap;
	}

	.hg-archive__item {
		grid-template-columns: 84px minmax(0, 1fr);
		gap: 0.35rem 0.85rem;
		padding: 0.9rem 0.15rem;
	}

	.hg-archive__thumb {
		grid-row: 1 / span 2;
		width: 84px;
		height: 104px;
	}

	.hg-archive__open {
		justify-self: start;
	}

	.hg-lightbox {
		padding: 4.25rem 0.75rem 1.25rem;
	}

	.hg-lightbox__dialog img {
		max-height: calc(100vh - 12.5rem);
	}

	.hg-lightbox__nav--prev {
		left: 8px;
	}

	.hg-lightbox__nav--next {
		right: 8px;
	}
}

@media print {
	.hg-archive__tabs,
	.hg-archive__open,
	.hg-lightbox {
		display: none !important;
	}

	.hg-archive__panel {
		display: block !important;
	}

	.hg-archive__panel::before {
		content: attr(data-label);
		display: block;
		margin: 1.25rem 0 0.35rem;
		font-weight: 700;
	}
}
