/**
 * HSDC Interactive Map Styles
 */

/* Cooper Hewitt Bold font for heavier weight */
@font-face {
	font-family: 'CooperHewitt';
	font-weight: 600;
	src: url('../../../../themes/cooperhewitt/assets/stylesheets/fonts/CooperHewitt-Bold.eot');
	src: url('../../../../themes/cooperhewitt/assets/stylesheets/fonts/CooperHewitt-Bold.eot?#iefix') format('embedded-opentype'),
		 url('../../../../themes/cooperhewitt/assets/stylesheets/fonts/CooperHewitt-Bold.woff') format('woff'),
		 url('../../../../themes/cooperhewitt/assets/stylesheets/fonts/CooperHewitt-Bold.svg#webfont') format('svg');
}

:root {
	--ch-ink: #000;
	--ch-paper: #fff;
	--ch-red: #e64650;
	--ch-orange: #f77f00;
	--ch-gray: #b4b4b4;
}

/* ========================================
   Accessibility Utilities
   ======================================== */

/* Screen reader only - visually hidden but accessible */
.hsdc-sr-only {
	position: absolute;
	width: 1px;
	height: 1px;
	padding: 0;
	margin: -1px;
	overflow: hidden;
	clip: rect(0, 0, 0, 0);
	white-space: nowrap;
	border: 0;
}

/* Skip links for keyboard navigation */
.hsdc-skip-link {
	position: absolute;
	left: -9999px;
	z-index: 9999;
	padding: 8px 16px;
	background: var(--ch-ink);
	color: var(--ch-paper);
	text-decoration: none;
	font-family: "CooperHewitt", sans-serif;
	font-size: 14px;
	font-weight: 600;
}

.hsdc-skip-link:focus {
	left: 8px;
	top: 8px;
	outline: 2px solid var(--ch-orange);
	outline-offset: 2px;
}

/* Map Container */
.hsdc-wrap {
	width: 100%;
	max-width: 100%;
	height: 800px;
	position: relative;
	background: var(--ch-paper);
	border: 1px solid #e0e0e0;
}

#hsdc-map {
	width: 100%;
	max-width: 100%;
	height: 100%;
	min-height: 800px;
}

/* State Polygons */
.leaflet-interactive {
	fill: var(--ch-gray);
	stroke: #fff;
	stroke-width: 1;
	transition: fill 0.2s ease;
}

.leaflet-interactive.is-active {
	fill: var(--ch-orange);
}

/* Markers */
.hsdc-marker {
	transition: all 0.15s ease;
	cursor: pointer;
}

.leaflet-interactive.hsdc-marker {
	fill: #000000 !important;
	stroke: none !important;
}

/* Winner Star Markers */
.hsdc-marker-star {
	cursor: pointer;
}

.hsdc-marker-star .hsdc-star-marker {
	transition: all 0.15s ease;
	filter: drop-shadow(0 2px 4px rgba(0, 0, 0, 0.4));
}

.hsdc-marker-star .hsdc-star-marker path {
	fill: #fbdd41;
	transition: fill 0.15s ease;
}

.hsdc-marker-star:hover .hsdc-star-marker,
.hsdc-marker-star.is-highlighted .hsdc-star-marker {
	transform: scale(1.4);
}

.hsdc-marker-star:hover .hsdc-star-marker path,
.hsdc-marker-star.is-highlighted .hsdc-star-marker path {
	fill: #fbdd41;
}

/* Winner markers - always visible, not clustered */
.hsdc-marker-winner {
	z-index: 1000 !important;
}

.hsdc-marker-winner .hsdc-star-marker {
	filter: drop-shadow(0 3px 6px rgba(0, 0, 0, 0.5));
}

/* Marker Clusters */
.marker-cluster-small,
.marker-cluster-medium,
.marker-cluster-large {
	background-color: rgba(0, 0, 0, 0.6);
}

.marker-cluster-small div,
.marker-cluster-medium div,
.marker-cluster-large div {
	background-color: var(--ch-ink);
	border: none;
	border-radius: 50%;
	width: 40px;
	height: 40px;
	display: flex;
	align-items: center;
	justify-content: center;
	transition: all 0.2s ease;
}

.marker-cluster-small div:hover,
.marker-cluster-medium div:hover,
.marker-cluster-large div:hover {
	background-color: var(--ch-orange);
	transform: scale(1.15);
	border: none;
}

.marker-cluster-medium div {
	width: 50px;
	height: 50px;
}

.marker-cluster-large div {
	width: 60px;
	height: 60px;
}

.marker-cluster div span {
	color: var(--ch-paper);
	font-family: "CooperHewitt", sans-serif;
	font-weight: 600;
	font-size: 14px;
	line-height: 1;
}

.marker-cluster-medium div span {
	font-size: 16px;
}

.marker-cluster-large div span {
	font-size: 18px;
}

.marker-cluster {
	background-clip: padding-box;
	border-radius: 50%;
}

.leaflet-cluster-anim .leaflet-marker-icon,
.leaflet-cluster-anim .leaflet-marker-shadow {
	transition: transform 0.3s ease-out, opacity 0.3s ease-in;
}

/* Drawer */
.hsdc-drawer {
	position: fixed;
	right: 0;
	top: 0;
	bottom: 0;
	width: min(520px, 90vw);
	background: var(--ch-paper);
	box-shadow: -16px 0 32px rgba(0, 0, 0, 0.08);
	transform: translateX(100%);
	transition: transform 0.25s ease;
	z-index: 10000;
	overflow-y: auto;
	padding: 32px;
}

.hsdc-drawer.open {
	transform: translateX(0);
}

.hsdc-drawer-header {
	margin-bottom: 24px;
}

.hsdc-drawer-title {
	font-family: "CooperHewitt", sans-serif;
	font-size: 28px;
	font-weight: 600;
	color: var(--ch-ink);
	margin: 0 0 8px 0;
	border: none !important;
	padding: 0 !important;
}

.hsdc-drawer-meta {
	font-family: "CooperHewitt", sans-serif;
	font-size: 16px;
	color: #666;
	margin: 0;
}

.hsdc-drawer-content {
	margin-top: 24px;
}

.hsdc-drawer-description {
	margin: 0 0 16px 0;
	font-family: "CooperHewitt", sans-serif;
}

.hsdc-drawer-description-title {
	font-family: "CooperHewitt", sans-serif;
	font-size: 16px;
	font-weight: 600;
	color: var(--ch-ink);
	margin: 0 0 8px 0;
	border: none !important;
	padding: 0 !important;
}

.hsdc-drawer-description p {
	font-size: 14px;
	line-height: 1.6;
	color: #333;
	margin: 0;
}

.hsdc-drawer-close {
	position: absolute;
	top: 24px;
	right: 24px;
	background: none;
	border: none;
	font-size: 32px;
	line-height: 1;
	cursor: pointer;
	color: var(--ch-ink);
	padding: 0;
	width: 32px;
	height: 32px;
	display: flex;
	align-items: center;
	justify-content: center;
	outline: none;
}

.hsdc-drawer-close:hover,
.hsdc-drawer-close:focus {
	color: var(--ch-orange);
	background: none;
	outline: none;
}

.hsdc-drawer-image-wrapper {
	margin: 0 0 24px 0;
	width: 100%;
}

.hsdc-drawer-image-wrapper figure {
	margin: 0;
}

.hsdc-drawer-image-wrapper img {
	width: 100%;
	height: auto;
	display: block;
	cursor: pointer;
	transition: opacity 0.2s ease;
	border-radius: 0;
}

.hsdc-drawer-image-wrapper img:hover {
	opacity: 0.8;
}

.hsdc-drawer-image-wrapper .hsdc-image-fallback-icon {
	width: 100px;
	height: 100px;
}

/* Image Container and Fallback */
.hsdc-image-container {
	position: relative;
	width: 100%;
}

.hsdc-image-loading {
	position: absolute;
	top: 0;
	left: 0;
	right: 0;
	bottom: 0;
	display: flex;
	align-items: center;
	justify-content: center;
	background-color: #f5f5f5;
	z-index: 1;
}

.hsdc-image-loading-spinner {
	width: 24px;
	height: 24px;
	border: 2px solid #e0e0e0;
	border-top-color: var(--ch-orange);
	border-radius: 50%;
	animation: hsdc-spin 0.8s linear infinite;
	margin-top: 20px;
	margin-bottom: 20px;
}

@keyframes hsdc-spin {
	to {
		transform: rotate(360deg);
	}
}

.hsdc-image-container img.loaded ~ .hsdc-image-loading,
.hsdc-image-container .hsdc-image-fallback[style*="block"] ~ .hsdc-image-loading {
	display: none;
}

.hsdc-image-fallback {
	display: none;
	width: 100%;
	min-height: 200px;
	background-color: #e0e0e0;
}

.hsdc-image-fallback-bg {
	display: flex;
	flex-direction: column;
	align-items: center;
	justify-content: center;
	padding: 40px 20px 20px 20px;
	min-height: 150px;
}

.hsdc-image-fallback-error {
	font-family: "CooperHewitt", sans-serif;
	font-size: 12px;
	color: #666;
	text-align: center;
	margin: 0 0 12px 0;
	padding: 0;
	line-height: 1.4;
}

.hsdc-image-fallback-icon {
	width: 40px;
	height: 40px;
	opacity: 0.5;
}

.hsdc-image-fallback-text {
	font-family: "CooperHewitt", sans-serif;
	font-size: 14px;
	color: #666;
	text-align: center;
	padding: 0 20px 20px 20px;
	margin: 0;
	line-height: 1.4;
}

/* Overlay */
.hsdc-overlay {
	position: fixed;
	top: 0;
	left: 0;
	right: 0;
	bottom: 0;
	background: rgba(0, 0, 0, 0.5);
	opacity: 0;
	visibility: hidden;
	transition: opacity 0.25s ease, visibility 0.25s ease;
	z-index: 9999;
}

.hsdc-overlay.open {
	opacity: 1;
	visibility: visible;
}

/* Lightbox */
.hsdc-lightbox {
	position: fixed;
	top: 0;
	left: 0;
	right: 0;
	bottom: 0;
	background: rgba(0, 0, 0, 0.9);
	display: none;
	align-items: center;
	justify-content: center;
	z-index: 10001;
	padding: 40px;
}

.hsdc-lightbox.open {
	display: flex;
}

.hsdc-lightbox img {
	max-width: 100%;
	max-height: 100%;
	object-fit: contain;
}

.hsdc-lightbox-close {
	position: absolute;
	top: 20px;
	right: 20px;
	background: none;
	border: none;
	font-size: 20px;
	line-height: 1;
	cursor: pointer;
	color: var(--ch-paper);
	padding: 6px 12px;
}

.hsdc-lightbox-close:hover {
	background: none;
	color: var(--ch-orange);
}

/* Hover Popup */
.hsdc-marker-popup .leaflet-popup-content-wrapper {
	background: var(--ch-paper);
	border-radius: 8px;
	box-shadow: 0 4px 16px rgba(0, 0, 0, 0.15);
	padding: 0;
	min-width: 300px;
}

.hsdc-marker-popup .leaflet-popup-tip {
	background: var(--ch-paper);
}

.hsdc-popup {
	padding: 12px;
	font-family: "CooperHewitt", sans-serif;
}

.hsdc-popup-header {
	display: flex;
	height: auto;
	flex-direction: row;
	justify-content: space-between;
	align-items: center;
	margin-bottom: 10px;
	gap: 10px;
}

.hsdc-popup-title {
	margin: 0 0 0px 0;
	font-size: 24px;
	font-weight: 600;
	color: var(--ch-ink);
	font-family: "CooperHewitt", sans-serif;
	border: none !important;
	padding: 0 !important;
}

.hsdc-popup-meta {
	margin: 0 !important;
	font-size: 12px;
	color: #666;
	font-family: "CooperHewitt", sans-serif;
}

.hsdc-popup-images {
	width: 100%;
}

.hsdc-popup-images img {
	width: 100%;
	height: auto;
	border-radius: 0px;
	display: block;
}

.hsdc-popup-images .hsdc-image-fallback {
	min-height: 120px;
}

.hsdc-popup-images .hsdc-image-fallback-bg {
	min-height: 100px;
	padding: 20px 15px 15px 15px;
}

.hsdc-popup-images .hsdc-image-fallback-error {
	font-size: 11px;
	margin-bottom: 8px;
}

.hsdc-popup-images .hsdc-image-fallback-icon {
	width: 40px;
	height: 40px;
}

/* Reset Button */
.leaflet-control-custom {
	background: #fff;
	border: 2px solid rgba(0, 0, 0, 0.2);
	border-radius: 4px;
	background-clip: padding-box;
	margin-top: 0;
	cursor: pointer;
	box-shadow: 0 2px 16px rgba(0, 0, 0, 0.15) !important;
	width: 44px;
	height: 44px;
	padding: 0;
	overflow: hidden;
	display: flex;
	align-items: center;
	justify-content: center;
}

/* Zoom Control */
.leaflet-control-zoom {
	box-shadow: 0 2px 16px rgba(0, 0, 0, 0.15) !important;
}

.leaflet-control-custom a {
	display: flex;
	align-items: center;
	justify-content: center;
	width: 100%;
	height: 100%;
	color: #000;
	text-decoration: none;
	font-size: 18px;
	line-height: 1;
	background: transparent;
}

.leaflet-control-custom a img {
	width: 20px;
	height: 20px;
	display: block;
	object-fit: contain;
	transition: filter 0.2s ease;
	background: transparent;
}

.leaflet-control-custom:hover {
	background-color: #f4f4f4;
}

.leaflet-control-custom:hover a img {
	filter: invert(48%) sepia(79%) saturate(2476%) hue-rotate(1deg)
		brightness(103%) contrast(101%);
}

/* Zoom Button Icons */
.leaflet-control-zoom-in,
.leaflet-control-zoom-out {
	width: 40px !important;
	height: 40px !important;
	font-size: 0 !important;
	display: flex !important;
	align-items: center;
	justify-content: center;
}

.leaflet-control-zoom-in::before,
.leaflet-control-zoom-out::before {
	content: "";
	display: block;
	width: 24px;
	height: 24px;
	background-size: contain;
	background-repeat: no-repeat;
	background-position: center;
	transition: filter 0.2s ease;
}

.leaflet-control-zoom-in::before {
	background-image: url("../images/search-plus.svg");
}

.leaflet-control-zoom-out::before {
	background-image: url("../images/search-minus.svg");
}

.leaflet-control-zoom-in:hover::before,
.leaflet-control-zoom-out:hover::before {
	filter: invert(48%) sepia(79%) saturate(2476%) hue-rotate(1deg)
		brightness(103%) contrast(101%);
}

/* Leaflet overrides */
.leaflet-container,
.leaflet-popup-content-wrapper {
	font-family: "CooperHewitt", sans-serif;
}

.leaflet-control-attribution {
	display: none;
}

.leaflet-top {
	top: 10px;
}

.leaflet-bottom {
	bottom: 10px;
}

.leaflet-left {
	left: 10px;
}

.leaflet-right {
	right: 10px;
}

.leaflet-popup-content {
	margin: 0;
	line-height: 1.4;
}

/* Search Control */
.hsdc-search-control,
.hsdc-search-control.leaflet-bar {
	background: transparent;
	border: none !important;
	box-shadow: none;
}

.hsdc-search-wrapper {
	position: relative;
	width: 250px;
	border: none;
}

.hsdc-search-input {
	width: 100%;
	height: 46px;
	padding: 0 40px 0 16px;
	font-family: "CooperHewitt", sans-serif;
	font-size: 14px;
	font-weight: normal;
	border: 2px solid rgba(0, 0, 0, 0.2) !important;
	border-radius: 4px;
	background: var(--ch-paper);
	background-clip: padding-box;
	color: var(--ch-ink);
	outline: 0 !important;
	box-shadow: 0 2px 6px rgba(0, 0, 0, 0.1);
	-webkit-appearance: none;
	-moz-appearance: none;
	appearance: none;
	transition: box-shadow 0.2s ease;
	box-sizing: border-box;
}

.hsdc-search-icon {
	position: absolute;
	right: 12px;
	top: 50%;
	transform: translateY(-50%);
	width: 18px;
	height: 18px;
	pointer-events: none;
	opacity: 0.5;
}

.hsdc-search-input:focus {
	outline: 0 !important;
	box-shadow: 0 4px 12px rgba(0, 0, 0, 0.15);
}

.hsdc-search-input::placeholder {
	color: #888;
	font-weight: 400;
}

.hsdc-search-dropdown {
	position: absolute;
	top: calc(100% + 10px);
	left: 0;
	right: 0;
	width: 100%;
	max-width: 250px;
	background: var(--ch-paper);
	background-clip: padding-box;
	border: 2px solid rgba(0, 0, 0, 0.2);
	border-radius: 4px;
	max-height: 400px;
	overflow-y: auto;
	overflow-x: hidden;
	display: none;
	box-shadow: 0 4px 12px rgba(0, 0, 0, 0.15);
	z-index: 1000;
	box-sizing: border-box;
}

.hsdc-search-dropdown.open {
	display: block;
}

.hsdc-search-result {
	padding: 0px 16px;
	height: 46px;
	cursor: pointer;
	display: flex;
	flex-direction: row;
	justify-content: space-between;
	align-items: center;
	gap: 6px;
	&:not(:last-child) {
		border-bottom: 2px solid #e0e0e0;
	}
	transition: background-color 0.15s ease, color 0.15s ease;
	max-width: 100%;
	overflow: hidden;
}

.hsdc-search-result:last-child {
	border-bottom: 1px solid #e0e0e0;
}

.hsdc-search-result:hover {
	background-color: var(--ch-ink);
	cursor: pointer;
}

.hsdc-search-result:hover .hsdc-search-result-name {
	color: var(--ch-paper);
}

.hsdc-search-result:hover .hsdc-search-result-location {
	color: rgba(255, 255, 255, 0.7);
}

.hsdc-search-result-name {
	font-family: "CooperHewitt", sans-serif;
	font-size: 15px;
	font-weight: 600;
	color: var(--ch-ink);
	white-space: nowrap;
	overflow: hidden;
	text-overflow: ellipsis;
	flex: 1;
	min-width: 0;
}

.hsdc-search-result-location {
	font-family: "CooperHewitt", sans-serif;
	font-size: 12px;
	font-weight: 400;
	color: #666;
	white-space: nowrap;
	flex-shrink: 0;
}

.hsdc-search-no-results {
	padding: 16px;
	font-family: "CooperHewitt", sans-serif;
	font-size: 14px;
	font-weight: normal;
	color: #888;
	text-align: center;
}

/* Responsive */
@media (max-width: 1024px) {
	.hsdc-drawer {
		right: auto;
		left: 0;
		width: 100%;
		height: 100vh;
		bottom: 0;
		top: 0;
		transform: translateY(100%);
	}

	.hsdc-drawer.open {
		transform: translateY(0);
	}
}

@media (max-width: 768px) {
	.hsdc-wrap,
	#hsdc-map {
		width: 100%;
		max-width: 100%;
		height: 80vh;
		min-height: 80vh;
	}

	.leaflet-left {
		left: 4px;
	}

	.leaflet-right {
		right: 4px;
	}

	.leaflet-top {
		top: 4px;
	}

	.hsdc-drawer {
		padding: 24px;
	}

	.hsdc-drawer-title {
		font-size: 24px;
	}

	.hsdc-drawer-image-wrapper {
		margin: 0 0 16px 0;
	}

	.hsdc-marker-popup .leaflet-popup-content-wrapper {
		min-width: 300px;
	}

	.hsdc-popup-title {
		font-size: 18px;
	}

	.hsdc-popup {
		padding: 10px;
	}

	/* Search responsive */
	.hsdc-search-wrapper {
		width: 150px;
	}

	.hsdc-search-input {
		padding: 8px 10px;
		font-size: 13px;
		height: 40px;
	}

	.hsdc-search-dropdown {
		max-height: 240px;
		max-width: 150px;
	}

	.hsdc-search-result {
		padding: 10px 12px;
		flex-direction: column;
		align-items: flex-start;
		gap: 2px;
		height: fit-content;
	}

	.hsdc-search-result-name {
		font-size: 14px;
	}

	.hsdc-search-result-location {
		font-size: 11px;
	}
}

/* ==========================================================================
   List View Styles
   ========================================================================== */

/* List Container */
.hsdc-list {
	font-family: "CooperHewitt", sans-serif;
	max-width: 1200px;
	margin: 0 auto;
	padding: 0;
}

/* List Header */
.hsdc-list-header {
	display: flex;
	flex-direction: row;
	justify-content: space-between;
	align-items: center;
	gap: 16px;
	margin-bottom: 32px;
	flex-wrap: wrap;
}

/* Back to Map Link */
.hsdc-list-back-btn {
	display: inline-flex;
	align-items: center;
	gap: 6px;
	font-family: "CooperHewitt", sans-serif;
	font-size: 16px;
	font-weight: normal;
	color: #000;
	text-decoration: underline;
	text-underline-offset: 3px;
	transition: color 0.15s ease;
}

.hsdc-list-back-btn:hover {
	color: var(--ch-orange);
}

.hsdc-list-back-btn:focus {
	outline: 2px solid var(--ch-ink);
	outline-offset: 2px;
	color: var(--ch-orange);
}

.hsdc-list-back-btn svg {
	flex-shrink: 0;
}

/* List Search */
.hsdc-list-search {
	position: relative;
	flex-shrink: 0;
	width: 400px;
	max-width: 100%;
}

.hsdc-list-search-input {
	width: 100%;
	max-width: 100%;
	height: 50px;
	padding: 0 50px 0 20px;
	font-family: "CooperHewitt", sans-serif;
	font-size: 16px;
	font-weight: normal;
	border: 2px solid var(--ch-ink);
	border-radius: 0;
	background: var(--ch-paper);
	scroll-margin-top: 100px;
	color: var(--ch-ink);
	outline: none;
	transition: border-color 0.2s ease, box-shadow 0.2s ease;
	box-sizing: border-box;
}

.hsdc-list-search-input:focus {
	border-color: var(--ch-ink);
	box-shadow: 0 0 0 3px rgba(247, 127, 0, 0.3);
	outline: 2px solid var(--ch-ink);
	outline-offset: 0;
}

/* Search Icon */
.hsdc-list-search-icon {
	position: absolute;
	right: 16px;
	top: 50%;
	transform: translateY(-50%);
	pointer-events: none;
	color: var(--ch-ink);
}

.hsdc-list-search-input::placeholder {
	color: #888;
	font-weight: 400;
}

/* List Layout - TOC sidebar + entries main */
.hsdc-list-layout {
	display: grid;
	grid-template-columns: 220px 1fr;
	gap: 48px;
	align-items: start;
}

/* Table of Contents */
.hsdc-list-toc {
	position: sticky;
	top: 120px !important;
	max-height: calc(100vh - 120px);
	overflow-y: auto;
	padding-top: 4px;
	padding-right: 16px;
	padding-left: 4px;
}

.hsdc-list-toc-title {
	font-family: "CooperHewitt", sans-serif;
	font-size: 14px;
	font-weight: 600;
	text-transform: uppercase;
	letter-spacing: 0.05em;
	color: #666;
	margin: 0 0 16px 0;
	padding: 0;
	border: none;
}

.hsdc-list-toc-list {
	list-style: none;
	margin: 0;
	padding: 0;
}

.hsdc-list-toc-list li {
	margin: 0;
	padding: 0;
}

.hsdc-list-toc-list a {
	display: flex;
	justify-content: space-between;
	align-items: center;
	padding: 8px 0;
	font-family: "CooperHewitt", sans-serif;
	font-size: 15px;
	font-weight: normal;
	color: var(--ch-ink);
	text-decoration: none;
	border-bottom: 1px solid #e0e0e0;
	transition: color 0.15s ease;
}

.hsdc-list-toc-list a:hover,
.hsdc-list-toc-list a.active {
	color: var(--ch-orange);
}

.hsdc-list-toc-list a:focus {
	outline: 2px solid var(--ch-orange);
	outline-offset: 2px;
	color: var(--ch-orange);
}

.hsdc-list-toc-count {
	font-size: 13px;
	font-weight: 400;
	color: #888;
}

/* Back to Top Button - Desktop (in TOC) */
.hsdc-list-back-to-top {
	display: flex;
	align-items: center;
	justify-content: center;
	gap: 6px;
	margin-top: 24px;
	padding: 10px 16px;
	margin-bottom: 1rem;
	font-family: "CooperHewitt", sans-serif;
	font-size: 14px;
	font-weight: normal;
	color: var(--ch-ink);
	background: var(--ch-paper);
	border: 1px solid #e0e0e0;
	border-radius: 4px;
	cursor: pointer;
	transition: all 0.15s ease;
	width: 100%;
	opacity: 0;
	visibility: hidden;
	pointer-events: none;
}

.hsdc-list-back-to-top.visible {
	opacity: 1;
	visibility: visible;
	pointer-events: auto;
}

.hsdc-list-back-to-top:hover {
	color: var(--ch-paper);
	background: var(--ch-ink);
	border-color: var(--ch-ink);
}

.hsdc-list-back-to-top:focus {
	outline: 2px solid var(--ch-orange);
	outline-offset: 2px;
	color: var(--ch-orange);
}

.hsdc-list-back-to-top:focus:not(:focus-visible) {
	outline: none;
}

.hsdc-list-back-to-top svg {
	flex-shrink: 0;
	transition: transform 0.15s ease;
}

.hsdc-list-back-to-top:hover svg {
	transform: translateY(-2px);
}

/* Back to Top Button - Mobile (fixed bottom right) */
.hsdc-list-back-to-top-mobile {
	display: none;
	position: fixed;
	bottom: 24px;
	right: 24px;
	width: 48px;
	height: 48px;
	padding: 0;
	background: var(--ch-ink);
	color: var(--ch-paper);
	border: none;
	border-radius: 50%;
	cursor: pointer;
	transition: all 0.2s ease;
	z-index: 1000;
	opacity: 0;
	visibility: hidden;
	pointer-events: none;
	box-shadow: 0 2px 8px rgba(0, 0, 0, 0.2);
	align-items: center;
	justify-content: center;
}

.hsdc-list-back-to-top-mobile.visible {
	opacity: 1;
	visibility: visible;
	pointer-events: auto;
}

.hsdc-list-back-to-top-mobile:hover {
	background: #333;
	transform: translateY(-2px);
	box-shadow: 0 4px 12px rgba(0, 0, 0, 0.3);
}

.hsdc-list-back-to-top-mobile:focus {
	outline: 2px solid var(--ch-orange);
	outline-offset: 2px;
}

.hsdc-list-back-to-top-mobile:focus:not(:focus-visible) {
	outline: none;
}

.hsdc-list-back-to-top-mobile:active {
	transform: translateY(0);
}

.hsdc-list-back-to-top-mobile svg {
	flex-shrink: 0;
}

/* State Sections */
.hsdc-list-state-section {
	margin-bottom: 48px;
	scroll-margin-top: 100px;
}

.hsdc-list-state-header {
	font-family: "CooperHewitt", sans-serif;
	font-size: 32px;
	font-weight: 600;
	color: var(--ch-ink);
	margin: 0 0 24px 0;
	padding: 0 0 12px 0;
	border: none;
	border-bottom: 3px solid var(--ch-ink);
}

.hsdc-list-state-entries {
	display: flex;
	flex-direction: column;
	gap: 12px;
}

/* Entry Cards */
.hsdc-entry {
	background: var(--ch-paper);
	border: 2px solid #e0e0e0;
	transition: border-color 0.2s ease;
	scroll-margin-top: 100px;
}

.hsdc-entry:hover {
	border-color: #ccc;
}

.hsdc-entry.expanded {
	border-color: var(--ch-ink);
}

.hsdc-entry-header {
	display: flex;
	justify-content: space-between;
	align-items: center;
	padding: 16px 20px;
	cursor: pointer;
	user-select: none;
	transition: background-color 0.15s ease;
}

.hsdc-entry-header:hover {
	background-color: #f9f9f9;
}

.hsdc-entry.expanded .hsdc-entry-header {
	background-color: var(--ch-ink);
}

.hsdc-entry.expanded .hsdc-entry-header .hsdc-entry-name,
.hsdc-entry.expanded .hsdc-entry-header .hsdc-entry-location,
.hsdc-entry.expanded .hsdc-entry-header .hsdc-entry-toggle {
	color: var(--ch-paper);
}

.hsdc-entry.expanded .hsdc-entry-header .hsdc-entry-winner-badge {
	color: var(--ch-orange);
}

.hsdc-entry-header-info {
	display: flex;
	align-items: center;
	gap: 12px;
	flex: 1;
	min-width: 0;
}

.hsdc-entry-winner-badge {
	color: var(--ch-orange);
	font-size: 20px;
	line-height: 1;
	flex-shrink: 0;
}

.hsdc-entry-name {
	font-family: "CooperHewitt", sans-serif;
	font-size: 18px;
	font-weight: 600;
	color: var(--ch-ink);
	margin: 0;
	padding: 0;
	border: none;
	transition: color 0.15s ease;
}

.hsdc-entry-location {
	font-family: "CooperHewitt", sans-serif;
	font-size: 14px;
	font-weight: 400;
	color: #666;
	transition: color 0.15s ease;
}

.hsdc-entry-toggle {
	/* Reset button styles to match original span appearance */
	background: none;
	border: none;
	padding: 0;
	margin: 0;
	cursor: pointer;
	/* Original visual styles */
	font-family: "CooperHewitt", sans-serif;
	font-size: 24px;
	font-weight: normal;
	color: var(--ch-ink);
	line-height: 1;
	flex-shrink: 0;
	width: 24px;
	text-align: center;
	transition: color 0.15s ease;
	scroll-margin-top: 100px;
}

.hsdc-entry-toggle:focus {
	outline: 2px solid var(--ch-orange);
	outline-offset: 2px;
}

.hsdc-entry.expanded .hsdc-entry-toggle:focus {
	outline-color: var(--ch-paper);
}

/* Entry Content (collapsed by default) */
.hsdc-entry-content {
	display: none;
	padding: 24px 20px;
	border-top: 1px solid #e0e0e0;
}

.hsdc-entry.expanded .hsdc-entry-content {
	display: block;
}

.hsdc-entry-content:focus {
	outline: 2px solid var(--ch-orange);
	outline-offset: -2px;
}

.hsdc-entry-description h4,
.hsdc-entry-description p,
.hsdc-entry-image img {
	scroll-margin-top: 100px;
}

.hsdc-entry-description h4:focus,
.hsdc-entry-description p:focus {
	outline: 2px solid var(--ch-orange);
	outline-offset: 2px;
}

.hsdc-entry-image img:focus {
	outline: 2px solid var(--ch-orange);
	outline-offset: 2px;
}

.hsdc-entry-description {
	margin-bottom: 20px;
}

.hsdc-entry-description h4 {
	font-family: "CooperHewitt", sans-serif;
	font-size: 14px;
	font-weight: 600;
	text-transform: uppercase;
	letter-spacing: 0.03em;
	color: var(--ch-ink);
	margin: 0 0 8px 0;
	padding: 0;
	border: none;
}

.hsdc-entry-description p {
	font-family: "CooperHewitt", sans-serif;
	font-size: 15px;
	line-height: 1.6;
	color: #333;
	margin: 0;
	white-space: pre-wrap;
}

.hsdc-entry-image {
	margin-bottom: 20px;
}

.hsdc-entry-image:last-child {
	margin-bottom: 0;
}

.hsdc-entry-image img {
	width: 100%;
	max-width: 600px;
	height: auto;
	display: block;
}

.hsdc-entry-image .hsdc-image-fallback {
	min-height: 150px;
}

.hsdc-entry-image .hsdc-image-fallback-bg {
	min-height: 100px;
	padding: 30px 20px 15px 20px;
}

.hsdc-entry-image .hsdc-image-fallback-error {
	font-size: 11px;
	margin-bottom: 10px;
}

.hsdc-entry-image .hsdc-image-fallback-icon {
	width: 40px;
	height: 40px;
}

.hsdc-entry-image .hsdc-image-loading-spinner {
	width: 20px;
	height: 20px;
	border-width: 2px;
	margin-top: 15px;
	margin-bottom: 15px;
}

.hsdc-popup-images .hsdc-image-loading-spinner {
	width: 20px;
	height: 20px;
	border-width: 2px;
	margin-top: 15px;
	margin-bottom: 15px;
}

.hsdc-entry-image .hsdc-image-fallback-text {
	font-size: 13px;
	padding: 0 20px 15px 20px;
}

/* List View Error/Empty States */
.hsdc-list-error,
.hsdc-list-no-entries {
	padding: 48px 24px;
	text-align: center;
	font-family: "CooperHewitt", sans-serif;
	font-size: 16px;
	color: #666;
}

/* List View CTA Link (placed below map) */
.hsdc-list-cta {
	margin-top: 24px;
	text-align: center;
}

.hsdc-list-cta a {
	font-family: "CooperHewitt", sans-serif;
	font-size: 16px;
	font-weight: normal;
	color: var(--ch-ink);
	text-decoration: underline;
	text-underline-offset: 3px;
	transition: color 0.15s ease;
}

.hsdc-list-cta a:hover {
	color: var(--ch-orange);
}

/* ==========================================================================
   List View Responsive
   ========================================================================== */

@media (max-width: 900px) {
	.hsdc-list-layout {
		grid-template-columns: 1fr;
		gap: 32px;
	}

	.hsdc-list-toc {
		position: static;
		max-height: none;
		overflow-y: visible;
		padding-right: 0;
		padding-bottom: 16px;
		border-bottom: 2px solid #e0e0e0;
	}

	/* Hide desktop back to top button on mobile */
	.hsdc-list-back-to-top {
		display: none;
	}

	/* Show mobile back to top button */
	.hsdc-list-back-to-top-mobile {
		display: flex;
	}

	.hsdc-list-toc-list {
		display: flex;
		flex-wrap: wrap;
		gap: 8px 16px;
	}

	.hsdc-list-toc-list a {
		padding: 6px 12px;
		border: 1px solid #e0e0e0;
		border-bottom: 1px solid #e0e0e0;
		border-radius: 4px;
		font-size: 14px;
	}

	.hsdc-list-toc-list a:hover,
	.hsdc-list-toc-list a.active {
		background-color: var(--ch-ink);
		color: var(--ch-paper);
		border-color: var(--ch-ink);
	}

	.hsdc-list-toc-list a.active .hsdc-list-toc-count,
	.hsdc-list-toc-list a:hover .hsdc-list-toc-count {
		color: rgba(255, 255, 255, 0.7);
	}

	.hsdc-list-state-header {
		font-size: 26px;
	}
}

@media (max-width: 600px) {
	.hsdc-list {
		padding: 0;
	}

	.hsdc-list-header {
		flex-direction: column;
		align-items: flex-start;
	}

	.hsdc-list-back-btn {
		font-size: 14px;
	}

	.hsdc-list-search {
		width: 100%;
	}

	.hsdc-list-search-input {
		max-width: 100%;
		height: 46px;
		font-size: 15px;
	}

	.hsdc-list-state-header {
		font-size: 22px;
		margin-bottom: 16px;
	}

	.hsdc-entry-header {
		padding: 14px 16px;
	}

	.hsdc-entry-header-info {
		flex-wrap: wrap;
		gap: 4px 8px;
	}

	.hsdc-entry-name {
		font-size: 16px;
		width: 100%;
		order: 1;
	}

	.hsdc-entry-winner-badge {
		order: 0;
		font-size: 18px;
	}

	.hsdc-entry-location {
		font-size: 13px;
		order: 2;
		width: 100%;
	}

	.hsdc-entry-content {
		padding: 20px 16px;
	}

	.hsdc-entry-description p {
		font-size: 14px;
	}
}
