/* =========================================================
   FP Vial · Blog archive
   Diseño adaptado a la identidad visual de fpvial.es
   Color marca: #191e34 (navy oficial)
   Cárgalo en el style.css del tema hijo o vía wp_enqueue_style.
   ========================================================= */

:root {
	--fpv-navy: #191e34;
	--fpv-navy-700: #2a3252;
	--fpv-navy-50: #f4f5f9;
	--fpv-accent: #fbbf24;
	--fpv-accent-soft: #fef3c7;
	--fpv-marker: #ff0000;
	--fpv-text: #1f2433;
	--fpv-text-soft: #5b6478;
	--fpv-border: #e5e7ee;
	--fpv-card-bg: #ffffff;
	--fpv-shadow-sm: 0 1px 3px rgba(25, 30, 52, .06), 0 1px 2px rgba(25, 30, 52, .04);
	--fpv-shadow-lg: 0 18px 40px rgba(25, 30, 52, .14), 0 6px 12px rgba(25, 30, 52, .06);
	--fpv-radius: 14px;
	--fpv-radius-sm: 8px;
}

/* ---- Wrapper ---- */
.fpv-blog {
	max-width: 1280px;
	margin-inline: auto;
	padding: clamp(1rem, 2vw, 1.5rem) clamp(1rem, 3vw, 1.5rem) clamp(2rem, 5vw, 4.5rem);
	color: var(--fpv-text);
}

/* ---- Grid ---- */
.fpv-grid {
	display: grid;
	grid-template-columns: repeat(auto-fill, minmax(min(100%, 320px), 1fr));
	gap: clamp(1.5rem, 2.5vw, 2.25rem);
	align-items: start;
}

/* ---- Card ---- */
.fpv-card {
	display: flex;
	flex-direction: column;
	background: var(--fpv-card-bg);
	border: 1px solid var(--fpv-border);
	border-radius: var(--fpv-radius);
	overflow: hidden;
	box-shadow: var(--fpv-shadow-sm);
	transition: transform .25s ease, box-shadow .25s ease, border-color .25s ease;
	position: relative;
}

.fpv-card:hover,
.fpv-card:focus-within {
	transform: translateY(-4px);
	box-shadow: var(--fpv-shadow-lg);
	border-color: transparent;
}

/* ---- Imagen ---- */
.fpv-card__image {
	position: relative;
	aspect-ratio: 16 / 9;
	overflow: hidden;
	background: var(--fpv-navy-50);
}

.fpv-card__image img {
	width: 100%;
	height: 100%;
	object-fit: cover;
	display: block;
	transition: transform .5s ease;
}

.fpv-card:hover .fpv-card__image img,
.fpv-card:focus-within .fpv-card__image img {
	transform: scale(1.06);
}

/* ---- Body de la card ---- */
.fpv-card__body {
	display: flex;
	flex-direction: column;
	gap: .75rem;
	padding: 1.5rem;
}

.fpv-card__meta {
	display: flex;
	align-items: center;
	gap: .5rem;
	flex-wrap: wrap;
	font-size: .8125rem;
	color: var(--fpv-text-soft);
	font-weight: 500;
}

.fpv-card__date,
.fpv-card__reading {
	color: var(--fpv-text-soft);
}

.fpv-card__sep {
	opacity: .5;
}

/* ---- Título ---- */
.fpv-card__title {
	font-size: 1.25rem;
	line-height: 1.35;
	margin: 0;
	font-weight: 800;
	letter-spacing: -0.005em;
	color: var(--fpv-navy);
}

.fpv-card__title a {
	color: var(--fpv-navy);
	text-decoration: none;
	background-image: linear-gradient(transparent 65%, var(--fpv-marker) 65%);
	background-size: 0 100%;
	background-repeat: no-repeat;
	background-position: 0 0;
	transition: background-size .35s ease;
	padding: 0 2px;
	margin: 0 -2px;
}

.fpv-card__title a:hover,
.fpv-card__title a:focus-visible {
	color: var(--fpv-navy)!important;
	background-size: 100% 100%;
}

.fpv-card__title a:focus-visible {
	outline: 2px solid var(--fpv-navy);
	outline-offset: 4px;
	border-radius: 2px;
}

/* ---- Excerpt ---- */
.fpv-card__excerpt {
	font-size: .9375rem;
	line-height: 1.6;
	color: var(--fpv-text-soft);
	margin: 0;
}

/* ---- Paginación ---- */
.fpv-blog .pagination,
.fpv-blog .navigation.pagination {
	margin-top: clamp(2.5rem, 5vw, 4rem);
	display: flex;
	justify-content: center;
}

.fpv-blog .nav-links {
	display: flex;
	flex-wrap: wrap;
	gap: .5rem;
	align-items: center;
}

.fpv-blog .page-numbers {
	min-width: 44px;
	height: 44px;
	padding: 0 1rem;
	display: inline-flex;
	align-items: center;
	justify-content: center;
	border-radius: var(--fpv-radius-sm);
	color: var(--fpv-navy);
	text-decoration: none;
	font-weight: 700;
	background: #fff;
	border: 1px solid var(--fpv-border);
	transition: background .2s ease, color .2s ease, border-color .2s ease;
}

.fpv-blog .page-numbers:hover,
.fpv-blog .page-numbers:focus-visible {
	background: var(--fpv-navy-50);
	border-color: var(--fpv-navy);
}

.fpv-blog .page-numbers.current {
	background: var(--fpv-navy);
	color: #fff;
	border-color: var(--fpv-navy);
}

/* ---- CTA final ---- */
.fpv-cta {
	margin-top: clamp(3rem, 6vw, 5rem);
	background: linear-gradient(135deg, var(--fpv-navy) 0%, var(--fpv-navy-700) 100%);
	color: #fff;
	border-radius: var(--fpv-radius);
	padding: clamp(2rem, 4vw, 3rem);
	display: grid;
	grid-template-columns: 1fr auto;
	align-items: center;
	gap: 2rem;
	box-shadow: var(--fpv-shadow-lg);
	position: relative;
	overflow: hidden;
}

.fpv-cta::before {
	content: "";
	position: absolute;
	width: 320px;
	height: 320px;
	background: radial-gradient(circle, rgba(251, 191, 36, .18) 0%, transparent 70%);
	right: -80px;
	top: -120px;
	pointer-events: none;
}

.fpv-cta__title {
	margin: 0 0 .5rem;
	font-size: clamp(1.4rem, 2.4vw, 1.75rem);
	font-weight: 800;
	color: #fff;
	letter-spacing: -0.01em;
}

.fpv-cta__text {
	margin: 0;
	color: rgba(255, 255, 255, .85);
	font-size: 1rem;
	line-height: 1.55;
}

.fpv-cta__actions {
	display: flex;
	gap: .75rem;
	flex-wrap: wrap;
	position: relative;
	z-index: 1;
}

/* ---- Botones ---- */
.fpv-btn {
	display: inline-flex;
	align-items: center;
	justify-content: center;
	padding: .85rem 1.5rem;
	border-radius: var(--fpv-radius-sm);
	font-weight: 700;
	font-size: .95rem;
	text-decoration: none;
	letter-spacing: .01em;
	transition: transform .15s ease, background .2s ease, color .2s ease, box-shadow .2s ease;
	white-space: nowrap;
}

.fpv-btn--primary {
	background: #ff0000;
	color: #fff;
	box-shadow: 0 4px 14px rgba(251, 191, 36, .35);
}

.fpv-btn--primary:hover,
.fpv-btn--primary:focus-visible {
	transform: translateY(-1px);
	background: #ff0000;
	box-shadow: 0 6px 18px rgba(251, 191, 36, .45);
}

.fpv-btn--ghost {
	background: transparent;
	color: #fff;
	border: 1.5px solid rgba(255, 255, 255, .35);
}

.fpv-btn--ghost:hover,
.fpv-btn--ghost:focus-visible {
	background: rgba(255, 255, 255, .1);
	border-color: #fff;
}

.fpv-btn:focus-visible {
	outline: 2px solid #fff;
	outline-offset: 3px;
}

/* ---- Estado vacío ---- */
.fpv-blog__empty {
	text-align: center;
	color: var(--fpv-text-soft);
	padding: 3rem 1rem;
}

/* ---- Responsive del CTA ---- */
@media (max-width: 720px) {
	.fpv-cta {
		grid-template-columns: 1fr;
		text-align: center;
	}
	.fpv-cta__actions {
		justify-content: center;
	}
}

/* ---- Reduce motion ---- */
@media (prefers-reduced-motion: reduce) {
	.fpv-card,
	.fpv-card__image img,
	.fpv-btn {
		transition: none;
	}
}
