/* ═══════════════════════════════════════════════════════════════════════════
   ÁREAS FORMATIVAS - Instituto Serca
   Grid de áreas con efectos hover y responsive design
   ═══════════════════════════════════════════════════════════════════════════ */

/* ─────────────────────────────────────────────────────────────────────────────
   Contenedor Principal
   ───────────────────────────────────────────────────────────────────────────── */
.cont_areas {
	margin: 40px 0;
}

.cont_areas .row {
	margin-bottom: 20px;
}

/* ─────────────────────────────────────────────────────────────────────────────
   Cards de Áreas - Efecto Hover
   ───────────────────────────────────────────────────────────────────────────── */
.NW_efectohover {
	position: relative;
	overflow: hidden;
	margin: 0 0 15px 0;
	border-radius: 0;
	box-shadow: 0 4px 15px rgba(0, 0, 0, 0.1);
	transition: all 0.3s ease;
	height: 340px;
	min-height: 340px;
	max-height: 340px;
}

.NW_efectohover:hover {
	transform: translateY(-5px);
	box-shadow: 0 8px 25px rgba(0, 0, 0, 0.2);
}

/* ─────────────────────────────────────────────────────────────────────────────
   Contenedor de Imagen
   ───────────────────────────────────────────────────────────────────────────── */
.NW_bg_imgpro {
	position: absolute;
	top: 0;
	left: 0;
	width: 100%;
	height: 100%;
	overflow: hidden;
	z-index: 1;
	background: #f0f0f0;
}

.NW_bg_imgpro img {
	position: absolute;
	top: 0;
	left: 0;
	width: 100%;
	height: 100%;
	object-fit: cover;
	object-position: center;
	transition: transform 0.5s ease;
	display: block;
	min-width: 100%;
	min-height: 100%;
}

.NW_efectohover:hover .NW_bg_imgpro img {
	transform: scale(1.1);
}

/* ─────────────────────────────────────────────────────────────────────────────
   Overlay y Contenido
   ───────────────────────────────────────────────────────────────────────────── */
.NW_efectohover figcaption {
	position: absolute;
	top: 0;
	left: 0;
	width: 100%;
	height: 100%;
	background: rgba(0, 83, 72, 0.75);
	display: flex;
	flex-direction: column;
	align-items: center;
	justify-content: center;
	padding: 15px;
	transition: background 0.3s ease;
	z-index: 2;
	gap: 0;
}

.NW_efectohover:hover figcaption {
	background: rgba(0, 83, 72, 0.90);
	flex-direction: row;
	flex-wrap: wrap;
	gap: 8px;
}

/* ─────────────────────────────────────────────────────────────────────────────
   Título del Área
   ───────────────────────────────────────────────────────────────────────────── */
.NW_efectohover figcaption h3 {
	color: #ffffff;
	font-size: 29px;
	font-weight: 700;
	text-transform: uppercase;
	letter-spacing: 1.5px;
	margin: 0;
	text-align: center;
	text-shadow: 0 2px 4px rgba(0, 0, 0, 0.3);
	width: 100%;
	flex-basis: 100%;
	transition: margin 0.4s ease;
}

/* Agregar margen inferior al título cuando hay hover */
.NW_efectohover:hover figcaption h3 {
	margin-bottom: 8px;
}

/* ─────────────────────────────────────────────────────────────────────────────
   Enlaces de Tipos de Formación - Layout en 2 columnas
   ───────────────────────────────────────────────────────────────────────────── */
.NW_efectohover figcaption a {
	display: inline-flex;
	align-items: center;
	justify-content: center;
	color: #ffffff;
	font-size: 14px;
	font-weight: 600;
	text-decoration: none;
	padding: 0;
	margin: 0;
	border: 2px solid rgba(255, 255, 255, 0.6);
	border-radius: 25px;
	transition: all 0.4s ease;
	text-align: center;
	background: transparent;
	flex: 0 1 calc(50% - 8px);
	max-width: calc(50% - 8px);
	min-height: 0;
	max-height: 0;
	line-height: 1.3;
	opacity: 0;
	overflow: hidden;
	pointer-events: none;
}

/* Mostrar botones al hacer hover sobre la card */
.NW_efectohover:hover figcaption a {
	opacity: 1;
	padding: 10px 20px;
	min-height: 42px;
	max-height: none;
	pointer-events: auto;
}

/* Efecto hover individual del botón */
.NW_efectohover:hover figcaption a:hover {
	background: #FF8200;
	border-color: #FF8200;
	color: #ffffff;
	transform: translateY(0) scale(1.05);
}

/* Botón único centrado (para Enfermería y Turismo) */
.NW_efectohover figcaption a:only-of-type {
	flex: 0 1 auto;
	max-width: 200px;
	min-width: 160px;
}

/* Botón CURSOS centrado con mismo ancho que los demás (5º botón en tarjetas grandes) */
.NW_efectohover figcaption a.btn-area-cursos {
	flex: 0 1 calc(50% - 8px);
	max-width: calc(50% - 8px);
	margin-left: auto;
	margin-right: auto;
}

/* TCAE: título largo — subirlo al inicio de la tarjeta para mejor equilibrio */
.NW_efectohover.hover_tcae figcaption {
	justify-content: flex-start;
	padding-top: 30px;
}
.NW_efectohover.hover_tcae figcaption a {
	margin-left: auto;
	margin-right: auto;
}

/* Enlace especial con salto de línea */
.NW_efectohover figcaption a.d_espe_hover {
	line-height: 1.2;
	padding: 8px 10px;
	font-size: 11px;
	min-height: 48px;
}

/* ─────────────────────────────────────────────────────────────────────────────
   Contenedor flex para enlaces (usado en Enfermería y Turismo)
   ───────────────────────────────────────────────────────────────────────────── */
.cont_flex_hove {
	display: flex;
	flex-direction: column;
	gap: 10px;
	width: 100%;
	align-items: center;
}

/* ─────────────────────────────────────────────────────────────────────────────
   Enfermería usa la clase hover_enfermeria (independiente de los estilos antiguos)
   ───────────────────────────────────────────────────────────────────────────── */

/* ─────────────────────────────────────────────────────────────────────────────
   Variantes de Color por Área - DESACTIVADAS (todas usan el color verde)
   ───────────────────────────────────────────────────────────────────────────── */

/* Todas las áreas usan el mismo color verde corporativo de Serca */

/* ─────────────────────────────────────────────────────────────────────────────
   Responsive - Tablet (max-width: 992px)
   ───────────────────────────────────────────────────────────────────────────── */
@media (max-width: 992px) {
	.NW_efectohover {
		height: 320px;
	}

	.NW_efectohover figcaption h3 {
		font-size: 22px;
		margin-bottom: 20px;
	}

	.NW_efectohover figcaption a {
		font-size: 14px;
		padding: 8px 20px;
	}
}

/* ─────────────────────────────────────────────────────────────────────────────
   Responsive - Mobile (max-width: 768px)
   ───────────────────────────────────────────────────────────────────────────── */
@media (max-width: 768px) {
	.cont_areas {
		margin: 30px 0;
	}

	.cont_areas .row {
		margin-bottom: 15px;
	}

	.NW_efectohover {
		height: 250px;
		margin-bottom: 15px;
	}

	.NW_efectohover figcaption h3 {
		font-size: 20px;
		margin-bottom: 15px;
	}

	.NW_efectohover figcaption a {
		font-size: 13px;
		padding: 7px 18px;
		margin: 4px 0;
	}

	.NW_efectohover figcaption a.d_espe_hover {
		font-size: 12px;
		padding: 6px 15px;
	}
}

/* ─────────────────────────────────────────────────────────────────────────────
   Responsive - Mobile Small (max-width: 576px)
   ───────────────────────────────────────────────────────────────────────────── */
@media (max-width: 576px) {
	.NW_efectohover {
		height: 220px;
	}

	.NW_efectohover figcaption {
		padding: 15px;
	}

	.NW_efectohover figcaption h3 {
		font-size: 18px;
		margin-bottom: 12px;
		letter-spacing: 1px;
	}

	.NW_efectohover figcaption a {
		font-size: 12px;
		padding: 6px 15px;
		margin: 3px 0;
	}
}
