/* ============================================================
   SINGLE POST — Blog entry template
   Cargado solo en is_singular('post')
   ============================================================ */

/* ── Variables locales ───────────────────────────────────────────── */
.single-post-main {
	background-color: var(--colorBrandColor02);
	padding-top: 15rem;
	--post-text:       #20222A;
	--post-text-muted: #64666D;
	--post-text-mid:   #4E4F57;
	--post-rule:       #BFC1C7;
	--post-rule-light: #D6D7DE;
	--post-gold:       var(--colorBrandColor05, #DB9600);
	--post-radius:     1.2rem;
}

/* ── Layout contenedor ───────────────────────────────────────────── */
.single-post-container {
	padding-top: 2.4rem;
	padding-bottom: 6rem;
}

/* Grid: artículo + sidebar */
.single-post-layout {
	display: grid;
	grid-template-columns: 1fr 37rem;
	gap: 4rem;
	align-items: stretch;
	margin-top: 2.4rem;
}

/* ── Breadcrumb ──────────────────────────────────────────────────── */
.single-post-breadcrumb {
	display: flex;
	align-items: center;
	gap: 0.6rem;
	font-size: 1.2rem;
	font-weight: 100;
	color: var(--colorGrayGray07);
	flex-wrap: wrap;
	font-weight: 300;
}

.single-post-breadcrumb a {
	font-weight: 100;
	color: var(--colorBrandColor04);
	text-decoration: none;

	&:hover { text-decoration: underline; }
}

.single-post-breadcrumb__sep {
	display: flex;
	align-items: center;
	opacity: 0.5;

	& img {
		display: block;
		width: 1.4rem;
		height: 1.4rem;
	}
}

/* ── Artículo ────────────────────────────────────────────────────── */
.single-post-content__title {
	font-family: var(--font-body);
	font-size: 3.4rem;
	font-weight: 900;
	color: var(--colorGrayGray10);
	text-transform: uppercase;
	line-height: 1.15;
	margin: 0 0 1.6rem;
}

.single-post-content__title-rule {
	border: none;
	border-top: 1px solid var(--colorGrayGray02);
	margin: 0 0 1.6rem;
}

/* Autor + fecha */
.single-post-content__meta {
	display: flex;
	align-items: center;
	gap: 0.8rem;
	font-size: 1.4rem;
	color: var(--post-text-muted);
	margin-bottom: 2.4rem;

	.single-post-content__date {
		font-weight: 100;
	}
}

.single-post-content__avatar img {
	border-radius: 50%;
	display: block;
}

.single-post-content__author {
	font-weight: 500;
}

/* Imagen destacada */
.single-post-content__thumbnail {
	margin-bottom: 3.2rem;

	& img {
		width: 100%;
		height: auto;
		border-radius: var(--post-radius);
		display: block;
		object-fit: cover;
	}
}

/* ── Índice de contenido ─────────────────────────────────────────── */
.single-post-toc {
	border: 1px solid var(--colorBrandColor04);
	border-radius: var(--post-radius);
	padding: 4rem 10%;
	margin-bottom: 3.2rem;
}

.single-post-toc__toggle {
	display: flex;
	align-items: center;
	justify-content: center;
	width: 100%;
	background: none;
	border: none;
	cursor: pointer;
	font-family: inherit;
	font-size: 1.5rem;
	font-weight: 300;
	color: var(--colorGrayGray06);
	/* text-transform: uppercase; */
	/* letter-spacing: 0.06em; */
	padding: 0 0 2rem 0;
	margin-bottom: 2rem;
	gap: 1rem;
	border-bottom: 0.1rem solid var(--colorBrandColor04);
}

.single-post-toc__chevron {
	flex-shrink: 0;
	transition: transform 0.25s ease;
	color: var(--post-text-muted);
}

.single-post-toc__list,
.single-post-toc__sublist {
	margin: 1.2rem 0 0;
	padding-left: 2rem;
	list-style: decimal;
}

.single-post-toc__sublist {
	list-style: lower-alpha;
	margin-top: 0.4rem;
}

.single-post-toc__item {
	margin-bottom: 0.6rem;
	font-size: 1.4rem;
	font-weight: 300;
	color: var(--colorGrayGray06);
	line-height: 1.4;

	& a {
		color: inherit;
		text-decoration: none;

		&:hover {
			color: var(--post-gold);
			text-decoration: underline;
		}
	}

	& .single-post-toc__item--h3 { font-size: 1.35rem; }
	& .single-post-toc__item--h4 { font-size: 1.3rem; }
}

/* ── Cuerpo del artículo ─────────────────────────────────────────── */
.single-post-content__body {
	font-size: 1.6rem;
	color: var(--colorGrayGray10);
	line-height: 1.75;

	& h2 {
		font-family: var(--font-body);
		font-size: 2.4rem;
		font-weight: 700;
		margin: 3.2rem 0 1.2rem;
		color: var(--colorGrayGray10);
		scroll-margin-top: 9rem;
	}

	& h3 {
		font-family: var(--font-body);
		font-size: 2rem;
		font-weight: 700;
		margin: 2.4rem 0 1rem;
		color: var(--colorGrayGray10);
		scroll-margin-top: 9rem;
	}

	& h4 {
		font-family: var(--font-body);
		font-size: 1.7rem;
		font-weight: 600;
		margin: 2rem 0 0.8rem;
		color: var(--colorGrayGray10);
		scroll-margin-top: 9rem;
	}

	& p { margin: 0 0 1.6rem; }

	& ul, & ol {
		padding-left: 2.4rem;
		margin-bottom: 1.6rem;
	}

	& li { margin-bottom: 0.4rem; }

	& a {
		color: var(--post-gold);
		text-decoration: underline;
	}

	& img {
		max-width: 100%;
		height: auto;
		border-radius: var(--post-radius);
	}

	& figure { margin: 2rem 0; }

	& figcaption {
		font-size: 1.3rem;
		color: var(--post-text-muted);
		text-align: center;
		margin-top: 0.6rem;
	}

	& blockquote {
		border-left: 4px solid var(--post-gold);
		margin: 2.4rem 0;
		padding: 1.2rem 2rem;
		background: #f6f5f3;
		border-radius: 0 var(--post-radius) var(--post-radius) 0;
		font-style: italic;
		color: var(--post-text-mid);
	}

	& code {
		background: #f0f0f0;
		border-radius: 0.4rem;
		padding: 0.2em 0.5em;
		font-size: 0.9em;
	}

	& pre {
		background: #20222A;
		color: #f0f0f0;
		border-radius: var(--post-radius);
		padding: 2rem;
		overflow-x: auto;
		margin: 2rem 0;

		& code { background: none; padding: 0; }
	}
}

/* ── Nav prev / next ─────────────────────────────────────────────── */
.single-post-nav {
	display: flex;
	justify-content: space-between;
	gap: 2rem;
	margin-top: 4rem;
	padding-top: 2.4rem;
	border-top: 1px solid var(--colorBrandColor04);
}

.single-post-nav__link {
	display: flex;
	align-items: center;
	gap: 0.6rem;
	font-size: 1.6rem;
	font-weight: 600;
	color: var(--post-text);
	text-decoration: none;
	transition: color 0.2s;

	&:hover { color: var(--post-gold); }

	&--next { margin-left: auto; }
}

/* ── Sidebar widgets ─────────────────────────────────────────────── */
.single-post-sidebar {
	/* El aside ocupa toda la altura del grid gracias a align-items: stretch */
}

.single-post-sidebar__sticky {
	position: sticky;
	top: 2rem;
	display: flex;
	flex-direction: column;
	gap: 3.2rem;

	@media (max-width: 1024px) {
		position: static;
	}
}

.single-post-widget__title {
	font-family: var(--font-body);
	font-size: 1.8rem;
	font-weight: 600;
	text-transform: uppercase;
	color: var(--colorGrayGray10);
	padding-bottom: 1.5rem;
	margin: 0 0 1.5rem 0;
	border-bottom: 0.1rem solid var(--colorBrandColor04);
}

.single-post-widget__rule {
	border: none;
	border-top: 1px solid var(--post-rule);
	margin: 0 0 1.6rem;
}

/* Entradas recientes */
.single-post-recent {
	list-style: none;
	margin: 0;
	padding: 0;
	display: flex;
	flex-direction: column;
	gap: 0;
}

.single-post-recent__item {
	border-bottom: 1px solid var(--post-rule);

	&:last-child { border-bottom: none; }
}

.single-post-recent__link {
	display: flex;
	align-items: center;
	gap: 1.2rem;
	padding: 1.2rem 0;
	text-decoration: none;
	color: var(--post-text-mid);
	font-size: 1.5rem;
	font-weight: 500;
	line-height: 1.35;
	transition: color 0.2s;

	&:hover { color: var(--post-gold); }
}

.single-post-recent__thumb {
	flex-shrink: 0;
	width: 10rem;
	height: 8rem;

	& img {
		width: 100%;
		height: 100%;
		object-fit: cover;
		border-radius: var(--post-radius);
		display: block;
	}
}

/* Tours en sidebar */
.single-post-tours {
	display: flex;
	flex-direction: column;
	gap: 1.6rem;

	
}

/* ── Tour card variante sidebar (horizontal) ─────────────────────── */
.tour-card.tour-card--sidebar {
	background: var(--colorGrayGray10, #20222A);
	border-radius: 1.2rem;
	overflow: hidden;
	width: 100%;

	/* Anulamos el flex-direction column del card original */
	& .tour-card__link {
		display: flex;
		flex-direction: row;
		align-items: stretch;
		gap: 0.8rem;
		padding: 1.5rem;
	}

	/* Imagen cuadrada a la izquierda */
	& .tour-card__image {
		flex-shrink: 0;
		width: 13rem;
		height: 12rem;
		border-radius: 1.2rem;
		overflow: hidden;
		position: relative;
		padding: 0;
		
		& img {
			/* width: 100%; */
			/* height: 100%; */
			object-fit: cover;
			display: block;
		}
	}

	/* Badge dentro de la imagen */
	& .tour-card__badge {
		/* position: absolute; */
		top: 0.7rem;
		left: 0.7rem;
		/* font-size: 1.2rem; */
	}

	/* Columna derecha: nombre + body apilados */
	& .tour-card__info {
		flex: 1;
		display: flex;
		flex-direction: column;
		justify-content: space-between;
		padding: 0;
		gap: 1rem;
	}

	& .tour-card__name {
		padding: 0;
	}

	& .tour-card__title {
		font-size: 1.6rem;
		font-weight: 700;
		text-transform: uppercase;
		color: var(--colorBrandColor05, #DB9600);
		line-height: 1.2;
		margin: 0;
	}

	& .tour-card__body {
		display: flex;
		align-items: center;
		gap: 1.2rem;
		background: var(--colorBrandColor05, #DB9600);
		border-radius: 0.8rem;
		padding: 0.8rem 1.2rem;
		flex: none;
	}

	& .tour-card__pricing {
		display: flex;
		flex-direction: column;
		gap: 0;
		flex: 1;
	}

	& .tour-card__price-before { display: none; }

	& .tour-card__price-current {
		display: flex;
		align-items: baseline;
		gap: 0.2rem;
	}

	& .tour-card__price-currency {
		font-size: 1.4rem;
		font-weight: 900;
		color: var(--colorBrandBlue, #08144C);
	}

	& .tour-card__price-amount {
		font-size: 2.8rem;
		font-weight: 900;
		color: var(--colorBrandBlue, #08144C);
		line-height: 1;
	}

	& .tour-card__price-label {
		font-size: 1rem;
		font-weight: 500;
		color: var(--colorBrandBlue, #08144C);
		text-transform: uppercase;
		letter-spacing: 0.05em;
	}

	& .tour-card__cta {
		display: flex;
		align-items: center;
		gap: 0.6rem;
		border: 1px solid var(--colorBrandColor01);
		border-radius: var(--radius-md);
		padding: 0.6rem 0.6rem;
		font-size: 1.3rem;
		font-weight: 100;
		color: #fff;
		white-space: nowrap;
		flex-shrink: 0;
	}
}

/* ── Share ───────────────────────────────────────────────────────── */
.single-post-share {
	display: flex;
	align-items: center;
	gap: 1.2rem;
}

.single-post-share__label {
	font-size: 1.6rem;
	font-weight: 700;
	text-transform: uppercase;
	color: var(--colorBrandColor04, #9B897B);
	margin: 0;
	letter-spacing: 0.05em;
}

.single-post-share__icons {
	display: flex;
	flex-wrap: wrap;
	gap: 1rem;
}

.single-post-share__icon {
	display: flex;
	align-items: center;
	justify-content: center;
	width: 3.6rem;
	height: 3.6rem;
	border-radius: 50%;
	transition: background 0.2s, transform 0.15s;

	& img {
		width: 3.2rem;
		height: 3.2rem;
		display: block;
	}

	&:hover {
		background: var(--color-white);
		transform: scale(1.1);
	}
}

.site-footer--inner::before {
	content: none;
}

/* ── Blog archive ────────────────────────────────────────────────── */
.blog-archive-main {
	background-color: var(--colorBrandColor02);
}

.blog-archive-content__title {
	font-family: var(--font-body);
	font-size: 3.4rem;
	font-weight: 900;
	color: var(--post-text);
	margin: 0 0 2rem;
	text-transform: uppercase;
}

/* Lista de cards */
.blog-archive-list {
	display: flex;
	flex-direction: column;
	gap: 0;
}

/* Card individual */
.blog-post-card {
	border-bottom: 1px solid var(--post-rule-light);
	padding-bottom: 2rem;
	margin-bottom: 2rem;

	&:last-child {
		border-bottom: none;
	}
}

.blog-post-card__link {
	display: flex;
	align-items: flex-start;
	gap: 2rem;
	text-decoration: none;
	color: inherit;
}

.blog-post-card__thumb {
	flex-shrink: 0;
	width: 27rem;
	height: 25rem;
	border-radius: var(--post-radius);
	overflow: hidden;

	& img {
		width: 100%;
		height: 100%;
		object-fit: cover;
		display: block;
		transition: transform 0.35s ease;
	}
}

.blog-post-card:hover .blog-post-card__thumb img {
	transform: scale(1.04);
}

.blog-post-card__content {
	flex: 1;
	display: flex;
	flex-direction: column;
	gap: 1.6rem;
	min-width: 0;
}

.blog-post-card__title {
	font-family: var(--font-body);
	font-size: 2.4rem;
	font-weight: 700;
	color: var(--colorGrayGray10);
	text-transform: uppercase;
	line-height: 1.2;
	margin: 0;
	transition: color 0.2s;
}

.blog-post-card:hover .blog-post-card__title {
	color: var(--post-gold);
}

.blog-post-card__excerpt {
	font-size: 1.6rem;
	font-weight: 300;
	color: var(--colorGrayGray10);
	line-height: 1.35;
	text-align: justify;
	margin: 0;
	display: -webkit-box;
	-webkit-line-clamp: 5;
	-webkit-box-orient: vertical;
	overflow: hidden;
}

/* Meta autor */
.blog-post-card__meta {
	margin-top: auto;
	display: flex;
	flex-direction: column;
	gap: 1rem;
}

.blog-post-card__meta-rule {
	border: none;
	border-top: 1px solid var(--post-rule-light);
	margin: 0;
}

.blog-post-card__author-row {
	display: flex;
	align-items: center;
	gap: 0.6rem;
	font-size: 1.4rem;
	color: var(--post-text-muted);
}

.blog-post-card__avatar img {
	border-radius: 50%;
	display: block;
}

.blog-post-card__author {
	font-weight: 500;
}

.blog-post-card__date {
	font-weight: 300;
}

/* Paginación */
.blog-archive-pagination {
	display: flex;
	justify-content: space-between;
	align-items: center;
	margin-top: 2.4rem;
	gap: 1.2rem;
}

.blog-archive-pagination__btn {
	display: flex;
	align-items: center;
	gap: 0.6rem;
	padding: 1rem 2rem;
	border: 1px solid var(--colorBrandColor04, #9B897B);
	border-radius: 1.2rem;
	font-size: 1.8rem;
	font-weight: 500;
	color: var(--colorBrandColor04, #9B897B);
	text-decoration: none;
	transition: background 0.2s, color 0.2s;

	&:hover {
		background: var(--colorBrandColor04, #9B897B);
		color: #fff;
	}

	&--next { margin-left: auto; }
}

.blog-archive-empty {
	font-size: 1.6rem;
	color: var(--post-text-muted);
	padding: 4rem 0;
}

/* ── Responsive ──────────────────────────────────────────────────── */
@media (max-width: 1024px) {
	.single-post-layout {
		grid-template-columns: 1fr;
	}
	.single-post-main {
		padding-top: 10rem;
	}
}

@media (max-width: 768px) {
	.blog-post-card__link {
		flex-direction: column;
		
		.blog-post-card__thumb {
			width: 100%;
		}
	}
	
	
	.single-post-content__title {
		font-size: 2.4rem;
	}

	.single-post-nav {
		flex-direction: column;
		gap: 1.2rem;
	}

	.single-post-nav__link--next {
		margin-left: 0;
	}
}
