/* Service Grid for Elementor */
.sgx-wrap { width: 100%; }

.sgx-grid {
	display: grid;
	grid-template-columns: repeat(3, minmax(0, 1fr));
	gap: 30px;
}

.sgx-item { min-width: 0; }
.sgx-item.sgx-hidden { display: none; }
.sgx-item.sgx-enter { animation: sgx-fade-in .45s ease both; }

@keyframes sgx-fade-in {
	from { opacity: 0; transform: translateY(14px); }
	to   { opacity: 1; transform: none; }
}

/* ---------- Tarjeta ---------- */
.sgx-card {
	position: relative;
	display: block;
	width: 100%;
	height: 430px;
	overflow: hidden;
	background: #111;
	transition: box-shadow .4s ease;
}

.sgx-img {
	position: absolute !important;
	top: 0; left: 0; right: 0; bottom: 0;
	width: 100%; height: 100%;
	overflow: hidden;
}
.sgx-img img {
	position: absolute !important;
	top: 0; left: 0;
	display: block !important;
	width: 100% !important;
	height: 100% !important;
	max-width: none !important;
	max-height: none !important;
	object-fit: cover !important;
	margin: 0 !important;
	transition: transform .6s ease;
}
.sgx-zoom .sgx-item:hover .sgx-img img,
.sgx-zoom .sgx-item.is-active .sgx-img img { transform: scale(1.08); }

/* ---------- Barra inferior (estado normal) ---------- */
.sgx-bar {
	position: absolute;
	left: 0; right: 0; bottom: 0;
	z-index: 2;
	transition: opacity .4s ease, transform .4s ease;
}
.sgx-hide-bar .sgx-item:hover .sgx-bar,
.sgx-hide-bar .sgx-item.is-active .sgx-bar,
.sgx-hide-bar .sgx-item:focus-within .sgx-bar { opacity: 0; }

.sgx-meta {
	display: flex;
	align-items: center;
	gap: 15px;
}

.sgx-icon {
	display: inline-flex;
	align-items: center;
	justify-content: center;
	flex: 0 0 auto;
	width: 42px; height: 42px;
	font-size: 20px;
	line-height: 1;
	color: #fff;
	background: #2c9cf0;
	transition: all .3s ease;
}
.sgx-icon i, .sgx-icon svg { display: block; }
.sgx-icon svg { width: 1em; height: 1em; fill: currentColor; }

.sgx-title {
	margin: 0;
	padding: 0;
	color: #fff;
	font-size: 20px;
	line-height: 1.3;
	transition: color .3s ease;
}

/* ---------- Panel hover ---------- */
.sgx-panel {
	position: absolute;
	inset: 0; top: 0; left: 0; right: 0; bottom: 0;
	z-index: 3;
	overflow: hidden;
	box-sizing: border-box;
	background: rgba(15, 25, 160, .93);
	transition: clip-path .5s ease, opacity .5s ease;
	pointer-events: none;
	display: flex;
	flex-direction: column;
}

/* forma decorativa tipo "V" */
.sgx-panel::before { display: none; }
.sgx-has-pattern .sgx-panel::before {
	display: block;
	content: "";
	position: absolute;
	top: 0; bottom: 0; left: 0;
	width: 100%;
	background-color: rgba(255, 255, 255, .06);
	clip-path: polygon(0 0, 34% 0, 62% 100%, 0 100%);
	pointer-events: none;
}

.sgx-panel-inner {
	position: relative;
	z-index: 1;
	display: flex;
	flex-direction: column;
	justify-content: center;
	align-items: flex-start;
	height: 100%;
}
.sgx-panel-inner > * {
	opacity: 0;
	transform: translateY(18px);
	transition: opacity .5s ease, transform .5s ease;
}
.sgx-panel-inner > *:nth-child(2) { transition-delay: .08s; }
.sgx-panel-inner > *:nth-child(3) { transition-delay: .16s; }

/* alineación de contenido (prefix_class) */
.sgx-palign-left .sgx-panel,   .sgx-palign-left .sgx-panel .sgx-meta { text-align: left; justify-content: flex-start; }
.sgx-palign-center .sgx-panel, .sgx-palign-center .sgx-panel .sgx-meta { text-align: center; justify-content: center; }
.sgx-palign-right .sgx-panel,  .sgx-palign-right .sgx-panel .sgx-meta { text-align: right; justify-content: flex-end; }
.sgx-palign-center .sgx-panel-inner { align-items: center; }
.sgx-palign-right  .sgx-panel-inner { align-items: flex-end; }

/* tipos de entrada */
.sgx-fx-slide-up   .sgx-panel { clip-path: inset(100% 0 0 0); }
.sgx-fx-slide-down .sgx-panel { clip-path: inset(0 0 100% 0); }
.sgx-fx-slide-left .sgx-panel { clip-path: inset(0 100% 0 0); }
.sgx-fx-fade       .sgx-panel { opacity: 0; }
.sgx-fx-none       .sgx-panel { opacity: 0; transition: none; }
.sgx-fx-none       .sgx-panel-inner > * { transition: none; }

/* estado hover / activo (táctil) / foco por teclado */
.sgx-item:hover .sgx-panel,
.sgx-item.is-active .sgx-panel,
.sgx-item:focus-within .sgx-panel {
	pointer-events: auto;
}
.sgx-fx-slide-up:not(.x)   .sgx-item:hover .sgx-panel,
.sgx-fx-slide-up:not(.x)   .sgx-item.is-active .sgx-panel,
.sgx-fx-slide-up:not(.x)   .sgx-item:focus-within .sgx-panel,
.sgx-fx-slide-down:not(.x) .sgx-item:hover .sgx-panel,
.sgx-fx-slide-down:not(.x) .sgx-item.is-active .sgx-panel,
.sgx-fx-slide-down:not(.x) .sgx-item:focus-within .sgx-panel,
.sgx-fx-slide-left:not(.x) .sgx-item:hover .sgx-panel,
.sgx-fx-slide-left:not(.x) .sgx-item.is-active .sgx-panel,
.sgx-fx-slide-left:not(.x) .sgx-item:focus-within .sgx-panel { clip-path: inset(0 0 0 0); }

.sgx-fx-fade .sgx-item:hover .sgx-panel,
.sgx-fx-fade .sgx-item.is-active .sgx-panel,
.sgx-fx-fade .sgx-item:focus-within .sgx-panel,
.sgx-fx-none .sgx-item:hover .sgx-panel,
.sgx-fx-none .sgx-item.is-active .sgx-panel,
.sgx-fx-none .sgx-item:focus-within .sgx-panel { opacity: 1; }

.sgx-item:hover .sgx-panel-inner > *,
.sgx-item.is-active .sgx-panel-inner > *,
.sgx-item:focus-within .sgx-panel-inner > * {
	opacity: 1;
	transform: none;
}

/* ---------- Descripción y botón ---------- */
.sgx-desc {
	margin: 15px 0 25px;
	color: #fff;
	font-size: 15px;
	line-height: 1.6;
}
.sgx-readmore { line-height: 1; }
.sgx-btn {
	display: inline-block;
	padding: 10px 24px;
	color: #fff;
	background: #2c9cf0;
	border: 0 solid transparent;
	border-radius: 3px;
	font-size: 14px;
	font-weight: 600;
	line-height: 1.4;
	text-decoration: none;
	cursor: pointer;
	transition: all .3s ease;
}

/* ---------- Paginación ---------- */
.sgx-pager {
	--sgx-pg-size: 10px;
	--sgx-pg-color: #b9c2d6;
	--sgx-pg-text: #10163a;
	--sgx-pg-active: #2c9cf0;
	--sgx-pg-text-active: #fff;
	--sgx-pg-radius: 50%;
	display: flex;
	align-items: center;
	justify-content: center;
	flex-wrap: wrap;
	gap: 8px;
	margin-top: 30px;
}
.sgx-pager button {
	appearance: none;
	-webkit-appearance: none;
	margin: 0;
	padding: 0;
	cursor: pointer;
	border: 0;
	transition: all .3s ease;
	border-radius: var(--sgx-pg-radius);
}
/* puntos */
.sgx-pager button.sgx-dot {
	width: var(--sgx-pg-size);
	height: var(--sgx-pg-size);
	background: var(--sgx-pg-color);
	font-size: 0;
}
.sgx-pager button.sgx-dot.is-current,
.sgx-pager button.sgx-dot:hover { background: var(--sgx-pg-active); }
.sgx-pager button.sgx-dot.is-current { transform: scale(1.25); }
/* números y flechas */
.sgx-pager button.sgx-num,
.sgx-pager button.sgx-arrow {
	min-width: calc(var(--sgx-pg-size) * 3);
	height: calc(var(--sgx-pg-size) * 3);
	padding: 0 6px;
	color: var(--sgx-pg-text);
	background: var(--sgx-pg-color);
	line-height: 1;
}
.sgx-pager button.sgx-num { font-size: calc(var(--sgx-pg-size) + 3px); }
.sgx-pager button.sgx-arrow { font-size: calc(var(--sgx-pg-size) + 6px); }
.sgx-pager button.sgx-num.is-current,
.sgx-pager button.sgx-num:hover,
.sgx-pager button.sgx-arrow:hover {
	color: var(--sgx-pg-text-active);
	background: var(--sgx-pg-active);
}
.sgx-pager button:disabled { opacity: .4; cursor: default; }
