/* Safir Hero Banner - Frontend Styles */

.sfhb-hero-banner {
	display: flex;
	flex-direction: column;
	width: 100%;
	box-sizing: border-box;
}

.sfhb-hero-banner * {
	box-sizing: border-box;
}

/* ---------- Header ---------- */
.sfhb-header {
	display: flex;
	flex-wrap: wrap;
	width: 100%;
	justify-content: center;
	align-items: center;
	text-align: center;
}

.sfhb-header-item {
	display: flex;
	flex-direction: column;
	align-items: center;
	gap: 10px;
}

.sfhb-logo,
.sfhb-photo {
	display: block;
	max-width: 100%;
	object-fit: cover;
}

.sfhb-title,
.sfhb-subtitle {
	margin: 0;
	line-height: 1.5;
}

/* ---------- Buttons ---------- */
.sfhb-buttons {
	display: flex;
	flex-direction: row;
	flex-wrap: wrap;
	width: 100%;
	margin-top: 20px;
}

.sfhb-btn {
	display: inline-flex;
	align-items: center;
	justify-content: center;
	gap: 8px;
	border: none;
	cursor: pointer;
	text-decoration: none;
	transition: transform .2s ease, filter .2s ease, box-shadow .2s ease;
	font-family: inherit;
	line-height: 1.3;
	padding: 0 18px;
}

.sfhb-btn-icon {
	display: inline-flex;
	align-items: center;
	justify-content: center;
	flex-shrink: 0;
}

.sfhb-btn-icon svg {
	width: 1em;
	height: 1em;
	fill: currentColor;
}

.sfhb-btn-icon-top {
	display: flex;
}

.sfhb-btn:has(.sfhb-btn-icon-top) {
	flex-direction: column;
	gap: 4px;
}

.sfhb-btn-text {
	white-space: nowrap;
	overflow: hidden;
	text-overflow: ellipsis;
}

/* Buttons stack automatically on mobile via Elementor responsive control (buttons_direction),
   fallback safety net below 767px in case the control wasn't customized: */
@media (max-width: 767px) {
	.sfhb-buttons {
		flex-direction: column;
	}
	.sfhb-btn {
		width: 100%;
	}
}

/* ---------- Popup (glassmorphism) ---------- */
.sfhb-popup-overlay {
	position: fixed;
	inset: 0;
	z-index: 999999;
	display: flex;
	align-items: center;
	justify-content: center;
	padding: 20px;
	opacity: 0;
	visibility: hidden;
	transition: opacity .3s ease, visibility .3s ease;
}

.sfhb-popup-overlay.sfhb-active {
	opacity: 1;
	visibility: visible;
}

.sfhb-popup-box {
	position: relative;
	width: 100%;
	max-width: 480px;
	max-height: 90vh;
	overflow-y: auto;
	padding: 32px;
	border: 1px solid rgba(255, 255, 255, .3);
	box-shadow: 0 8px 40px rgba(0, 0, 0, .25);
	transform: translateY(24px) scale(.96);
	opacity: 0;
	transition: transform .35s ease, opacity .35s ease;
	text-align: center;
}

.sfhb-popup-overlay.sfhb-active .sfhb-popup-box {
	transform: translateY(0) scale(1);
	opacity: 1;
}

.sfhb-popup-close {
	position: absolute;
	top: 14px;
	inset-inline-end: 14px;
	width: 34px;
	height: 34px;
	border: none;
	background: rgba(255, 255, 255, .15);
	border-radius: 50%;
	cursor: pointer;
	display: flex;
	align-items: center;
	justify-content: center;
	font-size: 18px;
	line-height: 1;
	transition: background .2s ease;
}

.sfhb-popup-close:hover {
	background: rgba(255, 255, 255, .3);
}

.sfhb-popup-image {
	width: 100%;
	max-height: 220px;
	object-fit: cover;
	border-radius: 12px;
	margin-bottom: 18px;
}

.sfhb-popup-title {
	margin: 0 0 6px;
	font-size: 22px;
	font-weight: 700;
}

.sfhb-popup-subtitle {
	margin: 0 0 12px;
	font-size: 15px;
	opacity: .9;
}

.sfhb-popup-desc {
	margin: 0 0 20px;
	font-size: 15px;
	line-height: 1.8;
}

.sfhb-popup-link {
	display: inline-flex;
	align-items: center;
	justify-content: center;
	padding: 10px 26px;
	border-radius: 10px;
	background: #fff;
	color: #111;
	text-decoration: none;
	font-weight: 600;
	transition: opacity .2s ease;
}

.sfhb-popup-link:hover {
	opacity: .85;
}

body.sfhb-popup-open {
	overflow: hidden;
}

/* ---------- Ticker ---------- */
.sfhb-ticker {
	width: 100%;
	overflow: hidden;
	margin-top: 16px;
}

.sfhb-ticker-track {
	display: flex;
	width: max-content;
	animation: sfhb-ticker-scroll var(--sfhb-ticker-duration, 25s) linear infinite;
}

.sfhb-ticker[data-direction="ltr"] .sfhb-ticker-track {
	animation-direction: reverse;
}

.sfhb-ticker-row {
	display: flex;
	flex-wrap: nowrap;
	align-items: center;
	white-space: nowrap;
}

.sfhb-ticker-item {
	display: inline-flex;
	white-space: nowrap;
}

.sfhb-ticker-item a {
	color: inherit;
	text-decoration: none;
}

.sfhb-ticker-item a:hover {
	text-decoration: underline;
}

.sfhb-ticker:hover .sfhb-ticker-track {
	animation-play-state: paused;
}

@keyframes sfhb-ticker-scroll {
	from { transform: translateX(0); }
	to   { transform: translateX(-50%); }
}

@media (prefers-reduced-motion: reduce) {
	.sfhb-ticker-track {
		animation: none;
	}
}
