/**
 * Hurricane Live Search — full-screen overlay styles.
 */

/* ============================================================
   Body lock
   ============================================================ */
body.hls-locked {
	overflow: hidden;
}

/* ============================================================
   Overlay
   ============================================================ */
.hls-overlay {
	position: fixed;
	inset: 0;
	z-index: 99999;
	background: rgba(15, 15, 20, 0.92);
	backdrop-filter: blur(8px);
	-webkit-backdrop-filter: blur(8px);
	opacity: 0;
	transition: opacity 0.25s ease;
	overflow-y: auto;
	-webkit-overflow-scrolling: touch;
}

.hls-overlay.is-open {
	opacity: 1;
}

.hls-overlay[hidden] {
	display: none !important;
}

.hls-overlay__inner {
	max-width: 760px;
	margin: 0 auto;
	padding: 80px 24px 48px;
	min-height: 100%;
	display: flex;
	flex-direction: column;
}

.hls-overlay__close {
	position: fixed;
	top: 24px;
	right: 24px;
	background: rgba(255, 255, 255, 0.08);
	border: none;
	color: #fff;
	width: 44px;
	height: 44px;
	border-radius: 50%;
	cursor: pointer;
	display: flex;
	align-items: center;
	justify-content: center;
	transition: background 0.15s ease;
}

.hls-overlay__close:hover,
.hls-overlay__close:focus-visible {
	background: rgba(255, 255, 255, 0.18);
	outline: none;
}

/* ============================================================
   Search bar
   ============================================================ */
.hls-search-bar {
	position: relative;
	display: flex;
	align-items: center;
	background: #fff;
	border-radius: 8px;
	padding: 0 18px;
	box-shadow: 0 8px 32px rgba(0, 0, 0, 0.24);
}

.hls-search-bar__icon {
	color: #6b7280;
	flex-shrink: 0;
}

.hls-search-bar__input {
	flex: 1;
	border: none;
	outline: none;
	font-size: 18px;
	padding: 18px 14px;
	background: transparent;
	color: #111;
	font-family: inherit;
}

.hls-search-bar__input::placeholder {
	color: #9ca3af;
}

.hls-search-bar__spinner {
	display: none;
	width: 16px;
	height: 16px;
	border: 2px solid #e5e7eb;
	border-top-color: #6d28d9;
	border-radius: 50%;
	animation: hls-spin 0.7s linear infinite;
	flex-shrink: 0;
}

.hls-overlay.is-busy .hls-search-bar__spinner {
	display: block;
}

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

/* ============================================================
   Results
   ============================================================ */
.hls-results {
	margin-top: 24px;
	transition: opacity 0.15s ease;
}

.hls-results.is-loading {
	opacity: 0.55;
}

.hls-hint {
	color: rgba(255, 255, 255, 0.62);
	text-align: center;
	padding: 48px 16px;
	font-size: 15px;
}

/* ============================================================
   Section
   ============================================================ */
.hls-section {
	margin-bottom: 24px;
}

.hls-section__header {
	display: flex;
	align-items: center;
	justify-content: space-between;
	padding: 12px 18px;
	background: linear-gradient(135deg, #4c1d95 0%, #7c3aed 60%, #c026d3 100%);
	border-radius: 6px 6px 0 0;
	color: #fff;
}

.hls-section__label {
	font-weight: 700;
	font-size: 14px;
	letter-spacing: 0.5px;
	text-transform: uppercase;
}

.hls-section__count {
	font-size: 12px;
	background: rgba(255, 255, 255, 0.2);
	padding: 2px 10px;
	border-radius: 999px;
	font-weight: 600;
}

.hls-section__list {
	list-style: none;
	margin: 0;
	padding: 0;
	background: #fff;
	border-radius: 0 0 6px 6px;
	overflow: hidden;
}

/* ============================================================
   Item
   ============================================================ */
.hls-item + .hls-item {
	border-top: 1px solid #f1f1f4;
}

.hls-item__link {
	display: flex;
	align-items: flex-start;
	gap: 14px;
	padding: 14px 16px;
	text-decoration: none;
	color: #111;
	transition: background 0.12s ease;
}

.hls-item__link:hover,
.hls-item__link:focus-visible {
	background: #faf5ff;
	outline: none;
}

.hls-item__thumb {
	flex-shrink: 0;
	width: 56px;
	height: 56px;
	border-radius: 6px;
	overflow: hidden;
	background: #f3f4f6;
	display: flex;
	align-items: center;
	justify-content: center;
}

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

.hls-item__thumb--empty {
	background: linear-gradient(135deg, #ede9fe 0%, #fce7f3 100%);
}

.hls-item__body {
	flex: 1;
	min-width: 0;
	display: flex;
	flex-direction: column;
	gap: 2px;
}

.hls-item__title {
	font-size: 15px;
	font-weight: 500;
	line-height: 1.35;
	color: #111;
	overflow: hidden;
	text-overflow: ellipsis;
	display: -webkit-box;
	-webkit-line-clamp: 2;
	-webkit-box-orient: vertical;
}

.hls-item__title mark {
	background: #fef3c7;
	color: inherit;
	padding: 0 2px;
	border-radius: 2px;
	font-weight: 700;
}

.hls-item__cat {
	font-size: 12px;
	color: #6b7280;
	text-transform: uppercase;
	letter-spacing: 0.4px;
}

.hls-item__snippet {
	font-size: 13px;
	line-height: 1.5;
	color: #4b5563;
	margin-top: 4px;
	overflow: hidden;
	text-overflow: ellipsis;
	display: -webkit-box;
	-webkit-line-clamp: 2;
	-webkit-box-orient: vertical;
}

.hls-item__snippet mark {
	background: #fef3c7;
	color: inherit;
	padding: 0 2px;
	border-radius: 2px;
	font-weight: 600;
}

/* ============================================================
   Footer (View all)
   ============================================================ */
.hls-footer {
	margin-top: 16px;
	text-align: center;
}

.hls-footer__all {
	display: inline-flex;
	align-items: center;
	gap: 8px;
	color: #fff;
	background: rgba(255, 255, 255, 0.1);
	padding: 12px 24px;
	border-radius: 6px;
	text-decoration: none;
	font-weight: 600;
	font-size: 14px;
	transition: background 0.15s ease;
}

.hls-footer__all:hover,
.hls-footer__all:focus-visible {
	background: rgba(255, 255, 255, 0.2);
	color: #fff;
	outline: none;
}

/* ============================================================
   Mobile
   ============================================================ */
@media (max-width: 640px) {
	.hls-overlay__inner {
		padding: 64px 16px 32px;
	}

	.hls-overlay__close {
		top: 12px;
		right: 12px;
	}

	.hls-search-bar__input {
		font-size: 16px; /* prevents iOS zoom on focus */
		padding: 14px 10px;
	}

	.hls-item__thumb {
		width: 48px;
		height: 48px;
	}

	.hls-item__title {
		font-size: 14px;
	}
}

/* ============================================================
   Shortcode triggers — [hurricane_search]
   ============================================================ */
.hls-shortcode {
	--hls-sc-width: auto;
	display: flex;
	width: 100%;
}

.hls-shortcode--align-left   { justify-content: flex-start; }
.hls-shortcode--align-center { justify-content: center; }
.hls-shortcode--align-right  { justify-content: flex-end; }

/* ----- Style: input (searchbar look-alike, but it's a button) ----- */
.hls-sc-input {
	display: inline-flex;
	align-items: center;
	gap: 10px;
	width: var(--hls-sc-width, 320px);
	max-width: 100%;
	padding: 12px 18px;
	background: #fff;
	border: 1px solid #e5e7eb;
	border-radius: 8px;
	cursor: pointer;
	color: #6b7280;
	font-family: inherit;
	font-size: 15px;
	text-align: left;
	transition: border-color 0.15s ease, box-shadow 0.15s ease;
}

.hls-sc-input:hover,
.hls-sc-input:focus-visible {
	border-color: #7c3aed;
	box-shadow: 0 0 0 3px rgba(124, 58, 237, 0.12);
	outline: none;
}

.hls-sc-input svg {
	flex-shrink: 0;
	color: #9ca3af;
}

.hls-sc-input__placeholder {
	flex: 1;
	overflow: hidden;
	text-overflow: ellipsis;
	white-space: nowrap;
}

/* ----- Style: button (black pill) ----- */
.hls-sc-button {
	display: inline-flex;
	align-items: center;
	gap: 8px;
	padding: 12px 22px;
	background: #0a0a0d;
	color: #fff;
	border: none;
	border-radius: 8px;
	cursor: pointer;
	font-family: inherit;
	font-size: 14px;
	font-weight: 600;
	letter-spacing: 0.3px;
	transition: transform 0.15s ease, background 0.15s ease;
}

.hls-sc-button:hover,
.hls-sc-button:focus-visible {
	transform: translateY(-1px);
	background: #1f1f2a;
	outline: none;
}

/* ----- Style: icon-only ----- */
.hls-sc-icon {
	display: inline-flex;
	align-items: center;
	justify-content: center;
	width: 44px;
	height: 44px;
	background: transparent;
	border: none;
	border-radius: 50%;
	cursor: pointer;
	color: inherit;
	transition: background 0.15s ease;
}

.hls-sc-icon:hover,
.hls-sc-icon:focus-visible {
	background: rgba(124, 58, 237, 0.12);
	color: #7c3aed;
	outline: none;
}

/* ============================================================
   Custom Search Results Page (/hls-search/)
   ============================================================ */
.hls-page {
	width: 100%;
}

/* When theme provides its own hero (Vizion page-header partial),
   skip our hero and adjust container spacing. */
.hls-page--with-theme-hero .hls-page__container {
	margin-top: 32px;
}

/* Vizion theme's .c-page-header has margin-top: -85px which makes it overlap
   the site header. On our search page we don't want that overlap. */
.hls-theme-hero-wrapper .c-page-header {
	margin-top: 0 !important;
}

.hls-page__hero {
	background: linear-gradient(135deg, #0a0a0d 0%, #1a1a22 60%, #2a2a35 100%);
	padding: 80px 24px;
	color: #fff;
	text-align: left;
}

.hls-page__hero-inner {
	max-width: 1200px;
	margin: 0 auto;
}

.hls-page__title {
	font-size: 56px;
	font-weight: 800;
	letter-spacing: 1px;
	text-transform: uppercase;
	margin: 0;
	color: #fff;
}

.hls-page__container {
	max-width: 1000px;
	margin: -32px auto 64px;
	padding: 0 24px;
	position: relative;
	z-index: 2;
}

.hls-page__form-inner {
	display: flex;
	align-items: center;
	gap: 12px;
	background: #fff;
	border-radius: 12px;
	padding: 8px 8px 8px 20px;
	box-shadow: 0 12px 40px rgba(0, 0, 0, 0.18);
}

.hls-page__form-inner svg {
	color: #6b7280;
	flex-shrink: 0;
}

.hls-page__input {
	flex: 1;
	border: none;
	outline: none;
	font-size: 18px;
	padding: 16px 8px;
	background: transparent;
	color: #111;
	font-family: inherit;
}

.hls-page__input::placeholder {
	color: #9ca3af;
}

.hls-page__submit {
	background: #0a0a0d;
	color: #fff;
	border: none;
	border-radius: 8px;
	padding: 14px 28px;
	font-size: 15px;
	font-weight: 600;
	cursor: pointer;
	font-family: inherit;
	transition: transform 0.15s ease, background 0.15s ease;
}

.hls-page__submit:hover,
.hls-page__submit:focus-visible {
	transform: translateY(-1px);
	background: #1f1f2a;
	outline: none;
}

.hls-page__summary {
	margin: 32px 0 24px;
	color: #4b5563;
	font-size: 16px;
}

.hls-page__empty {
	background: #f9fafb;
	border: 1px solid #e5e7eb;
	border-radius: 12px;
	padding: 48px 24px;
	text-align: center;
	color: #6b7280;
	font-size: 16px;
}

.hls-page__sections {
	display: flex;
	flex-direction: column;
	gap: 24px;
}

.hls-page__section {
	border-radius: 12px;
	overflow: hidden;
	box-shadow: 0 2px 8px rgba(0, 0, 0, 0.04);
	border: 1px solid #f1f1f4;
	background: #fff;
}

.hls-page__section-header {
	display: flex;
	align-items: center;
	justify-content: space-between;
	padding: 14px 22px;
	background: #0a0a0d;
	color: #fff;
}

.hls-page__section-label {
	font-size: 15px;
	font-weight: 700;
	text-transform: uppercase;
	letter-spacing: 0.5px;
	margin: 0;
	color: #fff;
}

.hls-page__section-count {
	background: rgba(255, 255, 255, 0.18);
	padding: 3px 12px;
	border-radius: 999px;
	font-size: 13px;
	font-weight: 600;
}

.hls-page__list {
	list-style: none;
	margin: 0;
	padding: 0;
}

.hls-page__item + .hls-page__item {
	border-top: 1px solid #f1f1f4;
}

.hls-page__link {
	display: flex;
	align-items: flex-start;
	gap: 16px;
	padding: 18px 22px;
	text-decoration: none;
	color: #111;
	transition: background 0.12s ease;
}

.hls-page__link:hover,
.hls-page__link:focus-visible {
	background: #f9fafb;
	outline: none;
}

.hls-page__thumb {
	flex-shrink: 0;
	width: 72px;
	height: 72px;
	border-radius: 8px;
	overflow: hidden;
	background: #f3f4f6;
}

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

.hls-page__thumb--empty {
	background: linear-gradient(135deg, #e5e7eb 0%, #d1d5db 100%);
}

.hls-page__body {
	flex: 1;
	min-width: 0;
	display: flex;
	flex-direction: column;
	gap: 4px;
}

.hls-page__item-title {
	font-size: 17px;
	font-weight: 600;
	line-height: 1.35;
	color: #111;
}

.hls-page__item-title mark {
	background: #fef3c7;
	color: inherit;
	padding: 0 2px;
	border-radius: 2px;
	font-weight: 700;
}

.hls-page__item-cat {
	font-size: 12px;
	color: #6b7280;
	text-transform: uppercase;
	letter-spacing: 0.4px;
}

.hls-page__item-snippet {
	font-size: 14px;
	line-height: 1.5;
	color: #4b5563;
	margin-top: 4px;
	overflow: hidden;
	text-overflow: ellipsis;
	display: -webkit-box;
	-webkit-line-clamp: 2;
	-webkit-box-orient: vertical;
}

.hls-page__item-snippet mark {
	background: #fef3c7;
	color: inherit;
	padding: 0 2px;
	border-radius: 2px;
	font-weight: 600;
}

@media (max-width: 640px) {
	.hls-page__hero {
		padding: 56px 20px;
	}
	.hls-page__title {
		font-size: 36px;
	}
	.hls-page__container {
		margin: -24px auto 48px;
		padding: 0 16px;
	}
	.hls-page__input {
		font-size: 16px;
	}
	.hls-page__submit {
		padding: 12px 18px;
		font-size: 14px;
	}
	.hls-page__thumb {
		width: 56px;
		height: 56px;
	}
}
