/* PE Spotlight overlay + Search Workshop page. Brand tokens from the PE palette. */

:root {
	--pe-navy: #0e2e53;
	--pe-blue: #005cb9;
	--pe-red: #ea0029;
	--pe-text: #3e4043;
	--pe-mid: #c1c5c8;
	--pe-light: #f2f4f5;
	--pe-white: #ffffff;

	/* Body type scale — mirrors the site's fluid Bricks scale (body-m ~15→17,
	   body-s the next step down ~14→16). The site defines these as global classes,
	   not CSS variables, so we localize the same values here for this widget. */
	--body-m: clamp( 15px, 14.1429px + 0.2381vi, 17px );
	--body-s: clamp( 14px, 13.1429px + 0.2381vi, 16px );
}

/* ------------------------------------------------------------------ */
/* Spotlight overlay                                                   */
/* ------------------------------------------------------------------ */

body.pe-spot-lock { overflow: hidden; }

.pe-spot {
	position: fixed;
	inset: 0;
	z-index: 100000;
	display: flex;
	justify-content: center;
	align-items: flex-start;
	padding: 12vh 16px 16px;
	font-family: "Inter", -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, Helvetica, Arial, sans-serif;
	font-size: var(--body-m);
}
.pe-spot[hidden] { display: none; }
.pe-spot * { box-sizing: border-box; }

.pe-spot__backdrop {
	position: absolute;
	inset: 0;
	background: rgba( 14, 46, 83, 0.55 );
	backdrop-filter: blur( 4px );
	-webkit-backdrop-filter: blur( 4px );
}

.pe-spot__panel {
	position: relative;
	width: 100%;
	max-width: 600px;
	background: var(--pe-white);
	border-radius: 16px;
	box-shadow: 0 24px 80px rgba( 0, 0, 0, 0.35 );
	overflow: hidden;
	animation: pe-spot-in 0.14s ease-out;
}
@keyframes pe-spot-in {
	from { opacity: 0; transform: translateY( -8px ) scale( 0.99 ); }
	to   { opacity: 1; transform: none; }
}

.pe-spot__inputwrap {
	display: flex;
	align-items: center;
	gap: 12px;
	padding: 16px 18px;
	border-bottom: 1px solid #eceff1;
}
.pe-spot__icon { display: inline-flex; color: var(--pe-blue); flex: 0 0 auto; }
.pe-spot__icon svg { width: 20px; height: 20px; }
.pe-spot__input {
	flex: 1;
	border: 0;
	outline: none;
	font-size: 20px;
	color: var(--pe-navy);
	background: transparent;
}
.pe-spot__input::placeholder { color: #9aa0a6; }
.pe-spot__esc {
	font-size: 12px;
	font-weight: 700;
	color: #6b6f73;
	background: var(--pe-light);
	border-radius: 6px;
	padding: 4px 8px;
	cursor: pointer;
	flex: 0 0 auto;
}

.pe-spot__list {
	list-style: none;
	margin: 0;
	padding: 6px;
	max-height: 56vh;
	overflow-y: auto;
}
.pe-spot__group {
	font-family: "Montserrat", "Inter", sans-serif;
	font-size: 12px;
	font-weight: 700;
	text-transform: uppercase;
	letter-spacing: 0.06em;
	color: #8a9099;
	padding: 12px 12px 6px;
}
.pe-spot__item {
	display: flex;
	align-items: center;
	gap: 12px;
	padding: 9px 12px;
	border-radius: 10px;
	cursor: pointer;
}
.pe-spot__item.is-active { background: #eef5ff; }
.pe-spot__item.is-active .pe-spot__enter { opacity: 1; }
.pe-spot__thumb {
	flex: 0 0 auto;
	width: 40px;
	height: 40px;
	border-radius: 8px;
	background-size: cover;
	background-position: center;
	background-color: var(--pe-light);
}
.pe-spot__thumb--empty {
	background-image: linear-gradient( 135deg, #e7ebef, #f4f6f8 );
}
.pe-spot__text { min-width: 0; display: flex; flex-direction: column; gap: 2px; }
.pe-spot__title {
	font-size: var(--body-m);
	font-weight: 600;
	color: var(--pe-navy);
	white-space: nowrap;
	overflow: hidden;
	text-overflow: ellipsis;
}
.pe-spot__excerpt {
	font-size: var(--body-s);
	color: #6b6f73;
	white-space: nowrap;
	overflow: hidden;
	text-overflow: ellipsis;
}
.pe-spot__enter {
	margin-left: auto;
	flex: 0 0 auto;
	color: var(--pe-blue);
	font-size: 16px;
	opacity: 0;
}
.pe-spot__status {
	padding: 11px 18px;
	border-top: 1px solid #eceff1;
	font-size: var(--body-s);
	color: #8a9099;
	min-height: 20px;
}

@media (max-width: 480px) {
	.pe-spot { padding: 8vh 10px 10px; }
	.pe-spot__excerpt { display: none; }
}
