/* Elements Plus — frontend */

/* ---------- Hero Slider ---------- */
.ep-hero { position: relative; overflow: hidden; }
.ep-hero-track { display: flex; transition: transform 0.6s cubic-bezier(0.22, 1, 0.36, 1); will-change: transform; }
.ep-hero-slide {
	position: relative;
	background-size: cover;
	background-position: center;
	display: flex;
	align-items: center;
	height: 520px;
}
/* Width/flex only for the built-in track; Swiper sizes its own slides. */
.ep-hero-track > .ep-hero-slide {
	flex: 0 0 100%;
	min-width: 100%;
}
.ep-hero-slide::before {
	content: "";
	position: absolute;
	inset: 0;
	background: rgba(0, 0, 0, 0.4);
}
.ep-hero-content {
	position: relative;
	z-index: 2;
	max-width: 720px;
	padding: 0 6%;
	width: 100%;
}
.ep-hero-content.ep-align-center { margin: 0 auto; text-align: center; }
.ep-hero-content.ep-align-right { margin-left: auto; text-align: right; }
.ep-hero-content.ep-align-left { text-align: left; }
.ep-hero-heading { color: #fff; font-size: clamp(28px, 5vw, 56px); margin: 0 0 14px; line-height: 1.1; }
.ep-hero-sub { color: #f2f2f2; font-size: clamp(15px, 2vw, 20px); margin: 0 0 22px; }
.ep-hero-btn {
	display: inline-block;
	background: #fff;
	color: #111;
	padding: 12px 28px;
	border-radius: 6px;
	text-decoration: none;
	font-weight: 600;
	transition: transform 0.15s ease, opacity 0.15s ease;
}
.ep-hero-btn:hover { transform: translateY(-2px); opacity: 0.92; }

.ep-hero-arrow {
	position: absolute;
	top: 50%;
	transform: translateY(-50%);
	z-index: 3;
	background: rgba(0, 0, 0, 0.35);
	color: #fff;
	border: none;
	width: 46px;
	height: 46px;
	border-radius: 50%;
	font-size: 26px;
	line-height: 1;
	cursor: pointer;
	transition: background 0.15s ease;
}
.ep-hero-arrow:hover { background: rgba(0, 0, 0, 0.6); }
.ep-hero-prev { left: 16px; }
.ep-hero-next { right: 16px; }

.ep-hero-dots {
	position: absolute;
	bottom: 18px;
	left: 0;
	right: 0;
	z-index: 3;
	display: flex;
	gap: 8px;
	justify-content: center;
}
.ep-hero-dot {
	width: 11px;
	height: 11px;
	border-radius: 50%;
	border: 2px solid #fff;
	background: transparent;
	cursor: pointer;
	padding: 0;
}
.ep-hero-dot.is-active { background: #fff; }

/* Swiper engine: recolor Elementor's default blue controls to white. */
.ep-hero-swiper .swiper-button-prev,
.ep-hero-swiper .swiper-button-next { color: #fff; }
.ep-hero-swiper .swiper-pagination-bullet { background: #fff; opacity: 0.6; }
.ep-hero-swiper .swiper-pagination-bullet-active { opacity: 1; }
/* If the Swiper library never loads, keep only the first slide visible. */
.ep-hero-swiper.ep-swiper-nolib .swiper-wrapper { display: block; }
.ep-hero-swiper.ep-swiper-nolib .swiper-slide:not(:first-child) { display: none; }

/* ---------- Popups ---------- */
.ep-popup-overlay {
	position: fixed;
	inset: 0;
	background: rgba(15, 15, 25, 0.6);
	display: none;
	align-items: center;
	justify-content: center;
	z-index: 99999;
	opacity: 0;
	transition: opacity 0.25s ease;
	padding: 20px;
}
.ep-popup-overlay.is-open { display: flex; opacity: 1; }
.ep-popup-box {
	position: relative;
	background: #fff;
	border-radius: 12px;
	width: 100%;
	max-width: 640px;
	max-height: 90vh;
	overflow: auto;
	transform: translateY(14px) scale(0.98);
	transition: transform 0.25s ease;
	box-shadow: 0 30px 80px rgba(0, 0, 0, 0.3);
}
.ep-popup-overlay.is-open .ep-popup-box { transform: translateY(0) scale(1); }
.ep-popup-small { max-width: 420px; }
.ep-popup-medium { max-width: 640px; }
.ep-popup-large { max-width: 900px; }
.ep-popup-fullscreen { max-width: 96vw; width: 96vw; min-height: 90vh; }
.ep-popup-content { padding: 28px; }
.ep-popup-close {
	position: absolute;
	top: 10px;
	right: 12px;
	background: transparent;
	border: none;
	font-size: 30px;
	line-height: 1;
	color: #888;
	cursor: pointer;
	z-index: 2;
}
.ep-popup-close:hover { color: #222; }

/* ---------- Portfolio ---------- */
.ep-portfolio-filters {
	display: flex;
	flex-wrap: wrap;
	gap: 8px;
	margin-bottom: 22px;
	justify-content: center;
}
.ep-filter {
	background: transparent;
	border: 1px solid #d9d9e3;
	color: #444;
	padding: 8px 18px;
	border-radius: 999px;
	cursor: pointer;
	font-size: 14px;
	transition: all 0.15s ease;
}
.ep-filter:hover { border-color: #6d4aff; color: #6d4aff; }
.ep-filter.is-active { background: #6d4aff; border-color: #6d4aff; color: #fff; }

.ep-portfolio-grid {
	display: grid;
	grid-template-columns: repeat(var(--ep-cols, 3), 1fr);
	gap: 22px;
}
@media (max-width: 1024px) { .ep-portfolio-grid { grid-template-columns: repeat(2, 1fr); } }
@media (max-width: 600px) { .ep-portfolio-grid { grid-template-columns: 1fr; } }

.ep-portfolio-item {
	background: #fff;
	border-radius: 12px;
	overflow: hidden;
	box-shadow: 0 4px 18px rgba(0, 0, 0, 0.06);
	transition: transform 0.2s ease, box-shadow 0.2s ease;
}
.ep-portfolio-item.is-hidden { display: none; }
.ep-portfolio-item:hover { transform: translateY(-4px); box-shadow: 0 12px 30px rgba(0, 0, 0, 0.12); }

.ep-portfolio-media { position: relative; aspect-ratio: 4 / 3; overflow: hidden; }
.ep-portfolio-media img { width: 100%; height: 100%; object-fit: cover; transition: transform 0.4s ease; }
.ep-portfolio-item:hover .ep-portfolio-media img { transform: scale(1.06); }
.ep-portfolio-noimg { width: 100%; height: 100%; background: linear-gradient(135deg, #efeefc, #e3e0fb); }

.ep-portfolio-overlay {
	position: absolute;
	inset: 0;
	background: rgba(109, 74, 255, 0.55);
	display: flex;
	align-items: center;
	justify-content: center;
	opacity: 0;
	transition: opacity 0.2s ease;
}
.ep-portfolio-item:hover .ep-portfolio-overlay { opacity: 1; }
.ep-portfolio-link {
	width: 54px;
	height: 54px;
	border-radius: 50%;
	background: #fff;
	color: #6d4aff;
	display: flex;
	align-items: center;
	justify-content: center;
	font-size: 28px;
	text-decoration: none;
}
.ep-portfolio-plus { line-height: 1; }

.ep-portfolio-body { padding: 18px; }
.ep-portfolio-cat { font-size: 12px; text-transform: uppercase; letter-spacing: 0.05em; color: #6d4aff; font-weight: 600; }
.ep-portfolio-title { margin: 6px 0 4px; font-size: 18px; line-height: 1.3; }
.ep-portfolio-client { font-size: 13px; color: #777; }
.ep-portfolio-excerpt { font-size: 14px; color: #555; margin: 8px 0 0; }
.ep-portfolio-empty { color: #777; }

/* ---------- Lightbox ---------- */
.ep-lightbox {
	position: fixed;
	inset: 0;
	background: rgba(0, 0, 0, 0.9);
	display: none;
	align-items: center;
	justify-content: center;
	z-index: 100000;
	padding: 30px;
}
.ep-lightbox.is-open { display: flex; }
.ep-lightbox img { max-width: 92vw; max-height: 92vh; border-radius: 6px; }
.ep-lightbox-close {
	position: absolute;
	top: 18px;
	right: 24px;
	background: transparent;
	border: none;
	color: #fff;
	font-size: 40px;
	cursor: pointer;
}

/* HTML block wrapper never adds spacing of its own */
.ep-html-block { display: block; }

/* ---------- Nav Menu ---------- */
.ep-nav { display: flex; align-items: center; position: relative; }
.ep-nav-menu-wrap { flex: 1; }
.ep-nav-menu { list-style: none; margin: 0; padding: 0; display: flex; flex-wrap: wrap; align-items: center; gap: 8px; }
.ep-nav-vertical .ep-nav-menu { flex-direction: column; align-items: flex-start; }
.ep-nav-menu li { position: relative; }
.ep-nav-menu a { display: block; padding: 8px 12px; text-decoration: none; color: #1e1e2e; transition: color 0.15s ease; }
.ep-nav-menu .sub-menu {
	list-style: none;
	margin: 0;
	padding: 6px 0;
	position: absolute;
	top: 100%;
	left: 0;
	min-width: 190px;
	background: #fff;
	box-shadow: 0 12px 30px rgba(0, 0, 0, 0.12);
	border-radius: 8px;
	opacity: 0;
	visibility: hidden;
	transform: translateY(6px);
	transition: opacity 0.18s ease, transform 0.18s ease, visibility 0.18s ease;
	z-index: 50;
}
.ep-nav-menu li:hover > .sub-menu { opacity: 1; visibility: visible; transform: translateY(0); }
.ep-nav-menu .sub-menu .sub-menu { top: 0; left: 100%; }

.ep-nav-toggle {
	display: none;
	align-items: center;
	justify-content: center;
	flex-direction: column;
	gap: 4px;
	width: 42px;
	height: 42px;
	background: transparent;
	border: none;
	cursor: pointer;
	color: #1e1e2e;
}
.ep-nav-bar { width: 24px; height: 2px; background: currentColor; transition: transform 0.2s ease, opacity 0.2s ease; }
.ep-nav-open .ep-nav-toggle .ep-nav-bar:nth-child(1) { transform: translateY(6px) rotate(45deg); }
.ep-nav-open .ep-nav-toggle .ep-nav-bar:nth-child(2) { opacity: 0; }
.ep-nav-open .ep-nav-toggle .ep-nav-bar:nth-child(3) { transform: translateY(-6px) rotate(-45deg); }
.ep-nav-placeholder { padding: 12px; border: 1px dashed #c9c9d6; color: #777; border-radius: 6px; }

/* ---------- Theme Builder widgets ---------- */
.ep-tb { width: 100%; }
.ep-post-title { margin: 0 0 0.4em; }
.ep-post-title a { text-decoration: none; color: inherit; }
.ep-featured-image img { max-width: 100%; height: auto; display: block; }
.ep-featured-image-empty,
.ep-posts-empty { padding: 14px; border: 1px dashed #c9c9d6; color: #777; border-radius: 6px; }
.ep-post-content { line-height: 1.7; }
.ep-post-content img { max-width: 100%; height: auto; }
.ep-post-excerpt { line-height: 1.6; }
.ep-archive-title { margin: 0 0 0.5em; }

.ep-post-meta { display: flex; flex-wrap: wrap; align-items: center; gap: 8px; font-size: 14px; color: #6b6b7b; margin: 0 0 0.6em; }
.ep-post-meta a { color: inherit; }
.ep-meta-sep { opacity: 0.5; }

.ep-posts-grid {
	display: grid;
	grid-template-columns: repeat(var(--ep-cols, 3), 1fr);
	gap: 24px;
}
@media (max-width: 1024px) { .ep-posts-grid { grid-template-columns: repeat(2, 1fr); } }
@media (max-width: 600px) { .ep-posts-grid { grid-template-columns: 1fr; } }

.ep-post-card {
	background: #fff;
	border-radius: 12px;
	overflow: hidden;
	box-shadow: 0 4px 18px rgba(0, 0, 0, 0.06);
	display: flex;
	flex-direction: column;
	transition: transform 0.2s ease, box-shadow 0.2s ease;
}
.ep-post-card:hover { transform: translateY(-4px); box-shadow: 0 12px 30px rgba(0, 0, 0, 0.12); }
.ep-post-card-media { display: block; aspect-ratio: 16 / 10; overflow: hidden; }
.ep-post-card-media img { width: 100%; height: 100%; object-fit: cover; transition: transform 0.4s ease; }
.ep-post-card:hover .ep-post-card-media img { transform: scale(1.05); }
.ep-post-card-body { padding: 18px; display: flex; flex-direction: column; gap: 8px; }
.ep-post-card-meta { font-size: 13px; color: #8a8a99; text-transform: uppercase; letter-spacing: 0.04em; }
.ep-post-card-title { margin: 0; font-size: 20px; line-height: 1.3; }
.ep-post-card-title a { text-decoration: none; color: #1e1e2e; }
.ep-post-card-title a:hover { color: #6d4aff; }
.ep-post-card-excerpt { color: #555; font-size: 15px; line-height: 1.55; }
.ep-post-more { align-self: flex-start; font-weight: 600; color: #6d4aff; text-decoration: none; }
.ep-post-more:hover { text-decoration: underline; }

.ep-posts-pagination { margin-top: 30px; display: flex; justify-content: center; }
.ep-posts-pagination .page-numbers {
	display: inline-block;
	padding: 8px 14px;
	margin: 0 3px;
	border-radius: 8px;
	border: 1px solid #d9d9e3;
	text-decoration: none;
	color: #444;
}
.ep-posts-pagination .page-numbers.current { background: #6d4aff; border-color: #6d4aff; color: #fff; }
.ep-posts-pagination .page-numbers:hover { border-color: #6d4aff; color: #6d4aff; }
.ep-posts-pagination .current:hover { color: #fff; }

/* ---------- Form ---------- */
.ep-form-fields { display: flex; flex-wrap: wrap; gap: 16px; }
.ep-form-field { display: flex; flex-direction: column; gap: 6px; flex: 1 1 100%; }
.ep-form-field.ep-col-50 { flex: 1 1 calc(50% - 8px); }
.ep-form-field.ep-col-33 { flex: 1 1 calc(33.333% - 11px); }
.ep-form-field.ep-col-25 { flex: 1 1 calc(25% - 12px); }
@media (max-width: 600px) { .ep-form-field { flex: 1 1 100%; } }

.ep-form-label { font-size: 14px; font-weight: 600; color: #1e1e2e; }
.ep-form-req { color: #dc2626; }
.ep-form-input {
	width: 100%;
	padding: 11px 14px;
	border: 1px solid #d5d5e0;
	border-radius: 8px;
	background: #fff;
	color: #1e1e2e;
	font-size: 15px;
	font-family: inherit;
	transition: border-color 0.15s ease, box-shadow 0.15s ease;
}
.ep-form-input:focus { outline: none; border-color: #6d4aff; box-shadow: 0 0 0 3px rgba(109, 74, 255, 0.15); }
textarea.ep-form-input { resize: vertical; min-height: 120px; }

.ep-form-choices { display: flex; flex-wrap: wrap; gap: 12px; }
.ep-form-choice { display: inline-flex; align-items: center; gap: 6px; font-size: 15px; color: #333; cursor: pointer; }
.ep-form-acceptance { align-items: flex-start; }

.ep-form-field.ep-field-error .ep-form-input { border-color: #dc2626; }
.ep-form-field.ep-field-error .ep-form-label { color: #dc2626; }

.ep-form-actions { display: flex; margin-top: 18px; }
.ep-form-submit {
	appearance: none;
	border: none;
	background: #6d4aff;
	color: #fff;
	padding: 12px 30px;
	border-radius: 8px;
	font-size: 16px;
	font-weight: 600;
	cursor: pointer;
	transition: transform 0.15s ease, opacity 0.15s ease;
}
.ep-form-submit:hover { transform: translateY(-1px); }
.ep-form-submit:disabled { opacity: 0.6; cursor: default; transform: none; }
.ep-form-submit-full { width: 100%; }
.ep-form-submit.is-loading { position: relative; color: transparent; }
.ep-form-submit.is-loading::after {
	content: "";
	position: absolute;
	top: 50%;
	left: 50%;
	width: 18px;
	height: 18px;
	margin: -9px 0 0 -9px;
	border: 2px solid rgba(255, 255, 255, 0.5);
	border-top-color: #fff;
	border-radius: 50%;
	animation: ep-spin 0.7s linear infinite;
}
@keyframes ep-spin { to { transform: rotate(360deg); } }

.ep-form-message { margin-top: 14px; font-size: 15px; }
.ep-form-message.is-success { color: #16a34a; }
.ep-form-message.is-error { color: #dc2626; }
