/* board.css
   Styles for /board/ — the media wall + modal + search/filter bar.
   Colors and type follow the existing style.css palette:
   #222 page bg, #101010 panel/card bg, #62CBB8 teal accent,
   #F9F976 yellow accent, #ADADAD/#999 muted text.

   The search box and filter chip rules below intentionally mirror
   #searchWrapper / #calendarSettingsBar / #calendarFilterPanel / #activeFilters
   from style.css so the board's search + filter UI matches the calendar
   page's look — just scoped to board-prefixed ids so this page's markup
   stays consistent with the rest of the "board" naming used here.
*/

#boardSpace.page {
	align-items: flex-start;
}

#boardSpace .main,
#boardContent .main {
	margin-bottom: 0 !important;
}

/* --- Search + filter bar ----------------------------------------------- */

#boardSettingsBar {
	display: flex;
	flex-wrap: wrap;
	align-items: center;
	justify-content: space-between;
	gap: 16px;
	margin-bottom: 24px;
}

#boardSearchWrapper {
	position: relative;
	display: inline-flex;
	width: 75%;
	max-width: 825px;
	height: 70px;
}

#boardSearch {
	width: 100%;
	min-height: 60px;
	background-color: #101010;
	border: 3px solid #333;
	border-radius: 9px;
	font-family: "Plus Jakarta Sans", sans-serif;
	font-optical-sizing: auto;
	font-size: 16px;
	padding-right: 60px;
}

#boardSearch:focus {
	border-color: #62CBB8;
}

#boardSearchWrapper.hasValue #boardSearch {
	border: 3px solid #F9F976;
}

#boardSearchGo {
	height: 100%;
	position: absolute;
	right: 16px;
	background: none;
	border: none;
	display: flex;
	align-items: center;
	justify-content: center;
	cursor: pointer;
}

#boardSearchReset {
	display: none;
}

#boardSearchWrapper.hasValue #boardSearchGo {
	display: none;
}

#boardSearchWrapper.hasValue #boardSearchReset {
	height: 100%;
	position: absolute;
	right: 16px;
	background: none;
	border: none;
	display: flex;
	align-items: center;
	justify-content: center;
	cursor: pointer;
}

#boardSearchGo .icon, #boardSearchReset .icon {
	width: 40px;
	height: 40px;
}

#boardSettingsBar .filter-toggle {
	font-family: "Plus Jakarta Sans", sans-serif;
	font-size: 16px;
	letter-spacing: 0.05em;
	padding: 12px 16px;
	border-radius: 9px;
	border: none;
	color: #FFFFFF;
	background: transparent;
	cursor: pointer;
	display: inline-flex;
	align-items: center;
	gap: 8px;
	margin-right: 6%;
}

#boardSettingsBar .filter-toggle .icon {
	width: 32px;
	height: 32px;
}

#boardSettingsBar .filter-toggle.active {
	border: 1px solid #F9F976;
	color: #F9F976;
}

#boardFilterPanel .filter-panel {
	margin-top: 16px;
	margin-bottom: 24px;
	display: flex;
	flex-direction: column;
	width: 100%;
	gap: 10px;
}

#boardFilterPanel .filter-group-label {
	font-family: "Bebas Neue", sans-serif;
	font-style: normal;
	font-weight: 100;
	font-size: 16px;
	letter-spacing: 0.05em;
	color: #FCFCFC;
	margin-bottom: 8px;
}

#boardFilterPanel .filter-row {
	display: flex;
	gap: 8px;
	flex-wrap: wrap;
}

#boardFilterPanel .chip {
	font-family: "Space Mono", monospace;
	font-size: 14px;
	letter-spacing: 0.05em;
	padding: 6px 12px;
	border: 1px solid rgba(255, 255, 255, 0.15);
	border-radius: 20px;
	color: #FFF;
	cursor: pointer;
	background: transparent;
	transition: all .15s ease;
}

#boardFilterPanel .chip.active {
	border-color: #F9F976 !important;
	color: #F9F976;
}

/* Genre chips in the filter panel get the same per-genre --genre-color
   treatment as the calendar's/acts page's own genre filter chips. */
#boardFilterPanel .chip[style*="--genre-color"] {
	border-color: var(--genre-color);
	color: var(--genre-color);
}

#boardFilterPanel .chip[style*="--genre-color"].active {
	background: var(--genre-color) !important;
	border-color: var(--genre-color) !important;
	color: #101010;
}

/* Shots (All/Photos/Videos) — segmented-control look instead of pill chips,
   matching #calendarToggle's Day/Week toggle on the main calendar page
   (style.css). Rescoped to #boardFormatFilters since this row overrides
   the default .filter-row flex/gap used by the other filter groups. */
#boardFormatFilters {
	display: inline-flex;
	flex-wrap: nowrap;
	gap: 0 !important;
	border-radius: 9px;
	border: 1px solid rgba(249, 249, 118, 0.25);
	background: rgba(0, 0, 0, 0.25);
	width: fit-content;
}

#boardFormatFilters .toggle-button {
	font-family: "Plus Jakarta Sans", sans-serif;
	font-size: 16px;
	letter-spacing: 0.05em;
	padding: 12px 16px;
	color: #F9F976;
	border: 1px solid rgba(249, 249, 118, 0.25);
	background: rgba(0, 0, 0, 0.25);
	cursor: pointer;
	display: inline-flex;
	align-items: center;
	gap: 0;
	height: 100%;
}

#boardFormatFilters .toggle-button:first-child {
	border-radius: 8px 0 0 8px;
}

#boardFormatFilters .toggle-button:last-child {
	border-radius: 0 8px 8px 0;
}

#boardFormatFilters .toggle-button.active {
	color: #101010;
	background: #F9F976;
	font-weight: 900;
	border: 1px solid #F9F976;
}

#boardFilterPanel .chip-show-all {
	font-family: "Plus Jakarta Sans", sans-serif;
	border-style: none;
	color: #F9F976;
	padding: 8px 0;
	padding-left: 8px;
	margin-right: 80px;
}

#boardActiveFiltersWrapper {
	display: flex;
	flex-wrap: wrap;
	align-items: baseline;
	gap: 8px;
	margin-bottom: 32px;
}

#boardActiveFiltersWrapper #boardActiveFiltersLabel {
	font-family: "Bebas Neue", sans-serif;
	font-style: normal;
	font-weight: 100;
	font-size: 16px;
	letter-spacing: 0.05em;
	color: #FFF;
}

#boardActiveFilters {
	display: flex;
	flex-wrap: wrap;
	align-items: center;
	gap: 8px;
}

#boardActiveFilters .chip {
	display: inline-flex;
	align-items: baseline;
	font-family: "Plus Jakarta Sans", sans-serif;
	font-size: 16px;
	color: #FFF;
	background: transparent;
	border-style: none;
	cursor: pointer;
	gap: 8px;
}

#boardActiveFilters .chip-remove {
	color: #FF6262;
	font-size: 20px;
}

#boardActiveFilters .chip-reset {
	text-decoration: underline;
	color: #FFF;
}

#boardContent .main .subHead {
	margin-top: 40px;
}

#boardSubmitTrigger {
	cursor: pointer;
}


@media (hover: hover) and (pointer: fine) {
	#boardSettingsBar .filter-toggle:hover {
		color: #F9F976;
	}

	#boardFilterPanel .chip:hover {
		border-color: #62CBB8;
	}

	#boardFilterPanel .chip[data-filter="genre"]:hover {
		border-color: var(--genre-color);
		filter: brightness(1.2);
	}

	#boardFilterPanel .chip-show-all:hover {
		text-decoration: underline;
	}

	#boardActiveFilters .chip-reset:hover {
		color: #F9F976;
	}
}

@media screen and (max-width: 984px) {
	#boardSettingsBar .filter-toggle {
		margin-right: 3%;
	}
}

@media screen and (max-width: 774px) {
	#boardSettingsBar {
		justify-content: space-between;
	}

	#boardFilterToggle {
		margin-top: 4px;
	}

	.buttonLabel {
		display: none;
	}

	#boardSettingsBar .filter-toggle {
		margin-right: 6%;
	}

	#boardContent .main .subHead {
		margin-top: 40px;
	}
}

@media screen and (max-width:535px){
	#boardSearch {
		font-size: 14px;
		padding-right: 32px;
	}

	#boardSearchGo .icon, #boardSearchReset .icon {
		width: 32px !important;
		height: 32px !important;
	}

	#boardSearchGo, #boardSearchWrapper.hasValue #boardSearchReset {
		top: 0;
		right: 8px;
	}

	#boardSearchWrapper {
		width: 74%;
	}

	#boardSettingsBar .filter-toggle {
		margin-right: 2%;
	}
}


/* --- Media grid ---------------------------------------------------------- */

#boardGrid {
	display: grid;
	grid-template-columns: repeat(3, 1fr);
	gap: 24px;
	width: 100%;
	margin-bottom: 40px;
}

.boardTile {
	position: relative;
	display: flex;
	flex-direction: column;
	width: 100%;
	padding: 0;
	border: 3px solid #333;
	border-radius: 9px;
	overflow: hidden;
	background: #101010;
	cursor: pointer;
	font: inherit;
	color: inherit;
	text-align: left;
}

.boardTileThumb {
	position: relative;
	width: 100%;
	aspect-ratio: 4/3;
	overflow: hidden;
	background-color: #101010;
}

.boardTileThumb img {
	width: 100%;
	height: 100%;
	object-fit: cover;
	display: block;
}

.boardTileThumb-empty {
	display: flex;
	align-items: center;
	justify-content: center;
	color: #999;
	font-family: "Space Mono", monospace;
	font-size: 14px;
	letter-spacing: 0.05em;
}

.boardTilePlayIcon {
	position: absolute;
	top: 50%;
	left: 50%;
	width: 48px;
	height: 48px;
	transform: translate(-50%, -50%);
	border-radius: 50%;
	background-color: rgba(16, 16, 16, 0.65);
	pointer-events: none;
}

.boardTilePlayIcon::before {
	content: "";
	position: absolute;
	top: 50%;
	left: 56%;
	transform: translate(-50%, -50%);
	border-style: solid;
	border-width: 9px 0 9px 15px;
	border-color: transparent transparent transparent #FFF;
}

.boardTileCaption {
	margin: 8px 8px 0px;
	font-family: "Plus Jakarta Sans", sans-serif;
	font-size: 20px;
	line-height: 1.2;
	color: #FFF;
}

.boardTileGenres {
	display: flex;
	flex-wrap: wrap;
	gap: 6px;
	margin: 6px 8px 0px;
}

.boardTileGenres .genre-chip {
	display: inline-flex;
	align-items: center;
	font-family: 'Space Mono', monospace;
	font-size: 11px;
	letter-spacing: 0.03em;
	padding: 3px 10px;
	border: 1px solid var(--genre-color, rgba(255,255,255,0.15));
	border-radius: 20px;
	color: var(--genre-color, #FFF);
	background: transparent;
	white-space: nowrap;
}

.boardTileVenue {
	margin: 4px 8px 0px;
	font-family: "Plus Jakarta Sans", sans-serif;
	font-size: 14px;
	line-height: 1.2;
	color: #ADADAD;
}

.boardTileSub {
	margin: 4px 8px 8px;
	font-family: "Space Mono", monospace;
	font-size: 14px;
	line-height: 1.2;
	color: #ADADAD;
}

.boardTileSubValue {
	color: #FFF;
}

.boardStateMsg {
	width: 100%;
	margin: 0px 0px 40px;
	text-align: center;
	font-family: "Plus Jakarta Sans", sans-serif;
	font-size: 14px;
	letter-spacing: 0.05em;
	color: #FFF;
}

#boardEnd a {
	color: #62CBB8;
}

@media (hover: hover) and (pointer: fine) {
	#boardEnd a:hover {
		text-decoration: underline;
	}
}

.board-load {
	font-family: "Plus Jakarta Sans", sans-serif;
	font-size: 16px;
	letter-spacing: 0.05em;
	padding: 12px 16px;
	border-radius: 9px;
	border: 1px solid #F9F976;
	color: #FFFFFF;
	background: transparent;
	cursor: pointer;
	display: flex;
	align-items: center;
	justify-content: center;
	gap: 8px;
	width: fit-content;
	margin: 0 auto 60px;
}

.board-load[hidden] {
	display: none;
}

@media (hover: hover) and (pointer: fine) {
	.boardTile:hover,
	.boardTile:focus-visible {
		transform: translateY(-2px);
		border-color: #62CBB8;
	}
}

/* Responsive: 2-up on tablet, 1-up on phones (matches .main breakpoints) */
@media screen and (max-width: 774px) {
	#boardGrid {
		grid-template-columns: repeat(2, 1fr);
		gap: 16px;
	}
}

@media screen and (max-width: 535px) {
	.boardTileCaption {
		font-size: 16px;
	}

	.boardTileSub {
		font-size: 12px;
	}
}

/* --- Modal ------------------------------------------------------------ */

.boardModal[hidden] {
	display: none;
	opacity: 0;
}

.boardModal {
	position: fixed;
	inset: 0;
	z-index: 1000;
	display: flex;
	align-items: center;
	justify-content: center;
	opacity: 1;
	transition: opacity 200ms ease, display 200ms allow-discrete;
}

@starting-style {
	.boardModal:not([hidden]) {
		opacity: 0;
	}
}

.boardModalBackdrop {
	position: absolute;
	inset: 0;
	background-color: rgba(16, 16, 16, 0.9);
}

.boardModalContent {
	position: relative;
	z-index: 1;
	display: flex;
	flex-direction: column;
	max-width: 900px;
	max-height: 90vh;
	width: 100%;
	background-color: #222;
	overflow: hidden;
	padding: 48px 24px 24px;
	border-radius: 9px;
	opacity: 1;
	transform: scale(1);
	transition: opacity 200ms ease, transform 200ms ease;
}

.boardModal[hidden] .boardModalContent {
	opacity: 0;
	transform: scale(0.96);
}

@starting-style {
	.boardModal:not([hidden]) .boardModalContent {
		opacity: 0;
		transform: scale(0.96);
	}
}

.note {
	font-size: 14px;
}

.boardModalClose {
	position: absolute;
	top: 8px;
	right: 12px;
	z-index: 2;
	background: none;
	border: none;
	color: #FFF;
	font-size: 32px;
	line-height: 1;
	cursor: pointer;
	padding: 4px 8px;
}

.boardForm {
	margin-top: 24px;
}

.boardForm label {
	color: #FFF;
	font-size: 14px;
}

.boardSubmitModalBody a {
	color: #62CBB8;
}

#attachLabel {
	display: inline-block;
	width: 100%;
}

#boardFormAttachments {
	color: #ADADAD;
	font-family: "Space Mono", monospace;
	font-size: 14px;
	align-items: start;
}

#boardFormAttachments::file-selector-button,
#boardFormAttachments::-webkit-file-upload-button {
	background: none !important;
	border: 2px solid #F9F976 !important;
	display: block;
	text-align: center;
	color: #F9F976 !important;
	padding: 12px 40px !important;
	font-size: 16px;
	letter-spacing: 2px;
	cursor: pointer;
	margin-top: 8px;
}


@media (hover: hover) and (pointer: fine) {
	.boardModalClose:hover {
		color: #FF6262;
	}

	.boardSubmitModalBody a:hover {
		text-decoration: underline;
	}
}

.boardModalMedia {
	position: relative;
	display: flex;
	align-items: center;
	justify-content: center;
	background-color: #000;
	max-height: 70vh;
}

/* Keeps the wrapper invisible to layout so the img/video inside behave
   exactly as if they were still direct children of .boardModalMedia —
   this wrapper exists purely so JS can clear/replace the media without
   also wiping out the nav buttons below. */
.boardModalMediaInner {
	display: contents;
}

.boardModalNavBtn {
	position: absolute;
	top: 50%;
	transform: translateY(-50%);
	z-index: 2;
	width: 48px;
	height: 48px;
	display: flex;
	align-items: center;
	justify-content: center;
	background-color: rgba(16, 16, 16, 0.65);
	border: none;
	border-radius: 50%;
	cursor: pointer;
}

.boardModalNavPrev {
	left: 12px;
}

.boardModalNavNext {
	right: 12px;
}

.boardModalNavBtn[hidden] {
	display: none;
}

.boardModalNavBtn[disabled] {
	opacity: 0.25;
	cursor: default;
	pointer-events: none;
}

@media (hover: hover) and (pointer: fine) {
	.boardModalNavBtn:hover {
		background-color: #171717;
	}
}

.boardModalMedia img,
.boardModalMedia video {
	width: 100%;
	max-height: 70vh;
	object-fit: contain;
	display: block;
}

.boardModalMeta {
	padding: 16px 0px 0px;
}

.boardModalMeta h2 {
	font-size: 24px;
	margin-bottom: 8px !important;
}

.boardModalGenres {
	display: flex;
	flex-wrap: wrap;
	gap: 6px;
	margin: 0 0 12px;
}

.boardModalGenres .genre-chip {
	display: inline-flex;
	align-items: center;
	font-family: 'Space Mono', monospace;
	font-size: 11px;
	letter-spacing: 0.03em;
	padding: 3px 10px;
	border: 1px solid var(--genre-color, rgba(255,255,255,0.15));
	border-radius: 20px;
	color: var(--genre-color, #FFF);
	background: transparent;
	white-space: nowrap;
}

.boardModalSub {
	font-family: "Space Mono", monospace;
	font-size: 16px;
	letter-spacing: 0.05em;
	color: #ADADAD;
	margin: 0 0 8px;
}

.boardModalCredit {
	font-family: "Space Mono", monospace;
	font-size: 14px;
	letter-spacing: 0.05em;
	color: #ADADAD;
	margin: 0;
}

.boardModalCreditValue {
	color: #FFF;
}

body.boardModalOpen {
	overflow: hidden;
}
