/**
 * Events View Switcher – Stylesheet
 * Structural base only. Colors/spacing overridden by Elementor controls.
 *
 * @package ecom-events
 */

/* ==========================================================================
   Root
   ========================================================================== */

.ecom-events-switcher {
	width: 100%;
	box-sizing: border-box;
}

/* ==========================================================================
   Switcher bar
   ========================================================================== */

.ecom-evs-bar {
	display: flex;
	align-items: center;
	justify-content: space-between;
	padding-bottom: 12px;
	gap: 16px;
}

/* ==========================================================================
   Title
   ========================================================================== */

.ecom-evs-title {
	font-family: 'Instrument Serif', Georgia, serif;
	font-size: 60px;
	line-height: 60px;
	letter-spacing: -0.6px;
	color: #181d27;
	font-style: normal;
	font-weight: 400;
	margin: 0;
	padding: 0;
	flex-shrink: 0;
}

/* ==========================================================================
   Desktop segmented control pill
   ========================================================================== */

.ecom-evs-tabs {
	display: flex;
	align-items: center;
	gap: 8px;
	padding: 4px;
	background-color: #f5f5f5;
	border-radius: 9999px;
	flex-shrink: 0;
}

.ecom-evs-tab-btn {
	display: inline-flex;
	align-items: center;
	gap: 4px;
	height: 40px;
	padding: 6px 12px;
	background-color: transparent;
	color: #414651;
	border: 1px solid transparent;
	border-radius: 9999px;
	font-family: 'Lexend Deca', system-ui, sans-serif;
	font-size: 18px;
	font-weight: 400;
	line-height: 28px;
	cursor: pointer;
	white-space: nowrap;
	transition: background-color 0.15s ease, color 0.15s ease, border-color 0.15s ease;
	box-shadow: 0 1px 0.5px 0.05px rgba(24, 24, 27, 0.04);
	-webkit-appearance: none;
	        appearance: none;
	outline: none;
}

.ecom-evs-tab-btn:focus-visible {
	outline: 2px solid #414651;
	outline-offset: 2px;
}

.ecom-evs-tab-btn.ecom-evs-active {
	background-color: #ffffff;
	border-color: #e9eaeb;
	color: #181d27;
	font-weight: 500;
	box-shadow: 0 1px 0.5px 0.05px rgba(24, 24, 27, 0.04);
}

.ecom-evs-tab-btn:hover:not(.ecom-evs-active) {
	background-color: rgba(255, 255, 255, 0.6);
	color: #181d27;
}

.ecom-evs-tab-btn i,
.ecom-evs-tab-btn svg {
	flex-shrink: 0;
	width: 24px;
	height: 24px;
	font-size: 24px;
}

/* ==========================================================================
   Mobile custom dropdown  (hidden above breakpoint)
   ========================================================================== */

.ecom-evs-mob-wrap {
	display: none;
	position: relative;
	flex-shrink: 0;
}

.ecom-evs-mob-trigger {
	display: inline-flex;
	align-items: center;
	gap: 8px;
	padding: 4px 8px 4px 4px;
	background-color: #f5f5f5;
	border: none;
	border-radius: 9999px;
	cursor: pointer;
	font-family: inherit;
	-webkit-appearance: none;
	        appearance: none;
	outline: none;
}

.ecom-evs-mob-trigger:focus-visible {
	outline: 2px solid #414651;
	outline-offset: 2px;
}

.ecom-evs-mob-current {
	display: inline-flex;
	align-items: center;
	gap: 4px;
	height: 40px;
	padding: 6px 8px;
	font-family: 'Lexend Deca', system-ui, sans-serif;
	font-size: 18px;
	font-weight: 400;
	line-height: 28px;
	color: #414651;
	white-space: nowrap;
	box-shadow: 0 1px 0.5px 0.05px rgba(24, 24, 27, 0.04);
	background-color: #ffffff;
	border: 1px solid #e9eaeb;
	border-radius: 9999px;
}

.ecom-evs-mob-current i,
.ecom-evs-mob-current svg:not(.ecom-evs-mob-chevron) {
	flex-shrink: 0;
	width: 24px;
	height: 24px;
	font-size: 24px;
}

.ecom-evs-mob-chevron {
	flex-shrink: 0;
	width: 24px;
	height: 24px;
	color: #414651;
	transition: transform 0.18s ease;
}

.ecom-evs-mob-trigger[aria-expanded="true"] .ecom-evs-mob-chevron {
	transform: rotate(180deg);
}

/* Dropdown menu */
.ecom-evs-mob-menu {
	position: absolute;
	top: calc(100% + 6px);
	right: 0;
	min-width: 160px;
	background: #ffffff;
	border: 1px solid #e9eaeb;
	border-radius: 12px;
	box-shadow: 0 4px 16px rgba(24, 24, 27, 0.10);
	padding: 4px;
	list-style: none;
	margin: 0;
	z-index: 200;
}

.ecom-evs-mob-option {
	display: flex;
	align-items: center;
	gap: 8px;
	padding: 8px 12px;
	border-radius: 8px;
	font-family: 'Lexend Deca', system-ui, sans-serif;
	font-size: 16px;
	font-weight: 400;
	line-height: 24px;
	color: #414651;
	cursor: pointer;
	transition: background-color 0.12s ease;
	list-style: none;
}

.ecom-evs-mob-option:hover {
	background-color: #f5f5f5;
	color: #181d27;
}

.ecom-evs-mob-option.ecom-evs-active {
	background-color: #f5f5f5;
	color: #181d27;
	font-weight: 500;
}

.ecom-evs-mob-option i,
.ecom-evs-mob-option svg {
	flex-shrink: 0;
	width: 20px;
	height: 20px;
	font-size: 20px;
}

/* ==========================================================================
   Responsive swap  (CSS fallback — JS reads data-mobile-bp for exact value)
   ========================================================================== */

@media ( max-width: 767px ) {
	.ecom-evs-title {
		font-size: 36px;
		line-height: 42px;
		letter-spacing: -0.36px;
	}

	.ecom-evs-tabs         { display: none; }
	.ecom-evs-mob-wrap     { display: block; }
}

/* ==========================================================================
   Content panels
   ========================================================================== */

.ecom-evs-panels {
	width: 100%;
}

.ecom-evs-panel {
	display: none;
}

.ecom-evs-panel.ecom-evs-active {
	display: block;
}

/* Map panel: guarantee a minimum height so tiles render */
.ecom-evs-panel-map {
	min-height: 400px;
}

/* ==========================================================================
   Elementor editor mode
   Show all panels stacked so the designer can interact with each one.
   ========================================================================== */

.ecom-evs-editor-mode .ecom-evs-panel {
	display: block;
	margin-bottom: 24px;
	border: 2px dashed #c8d4e0;
	border-radius: 4px;
	position: relative;
}

/* Label badge */
/* .ecom-evs-editor-mode .ecom-evs-panel::before {
	content: attr( data-panel );
	display: block;
	padding: 4px 12px;
	background: #eef2f7;
	border-bottom: 1px solid #c8d4e0;
	font-size: 11px;
	font-weight: 700;
	text-transform: uppercase;
	letter-spacing: 0.06em;
	color: #7a8fa6;
} */

/* ==========================================================================
   Empty / placeholder state (no template selected yet)
   ========================================================================== */

.ecom-evs-placeholder {
	display: flex;
	flex-direction: column;
	align-items: center;
	justify-content: center;
	gap: 12px;
	padding: 40px 24px;
	background: #f8fafc;
	border: 2px dashed #d0dae6;
	border-radius: 8px;
	text-align: center;
	color: #8fa3b1;
}

.ecom-evs-placeholder-icon {
	display: flex;
	opacity: 0.5;
}

.ecom-evs-placeholder p {
	margin: 0;
	font-size: 14px;
	line-height: 1.6;
}

.ecom-evs-placeholder strong {
	color: #414651;
}

/* ==========================================================================
   RTL
   ========================================================================== */

[dir="rtl"] .ecom-evs-tabs           { flex-direction: row-reverse; }
[dir="rtl"] .ecom-evs-tab-btn        { flex-direction: row-reverse; }
[dir="rtl"] .ecom-evs-mob-menu       { right: auto; left: 0; }
[dir="rtl"] .ecom-evs-mob-current    { flex-direction: row-reverse; }
