/* assets/css/pages/post.css — placeholder. Estilos específicos del template post se desarrollan en Sprint 3-4. */

/* 2026-08-13: la clienta pide ocultar las fechas de las entradas de
   momento. `.bc-post-meta` vive en single.php (fecha + autor). Quitar
   cuando se decida qué mostrar en su lugar. */
.bc-post-meta {
	display: none;
}

/* ── Cuerpo del post (single.php > .bc-post-body) ────────────
   Tipografía editorial + imágenes inline responsive.
   Imágenes vienen del HTML de Drupal con width/height hardcoded
   (ej. width="276" height="414") — necesitan max-width fluid +
   height:auto para no quedar diminutas en pantallas anchas. */

.bc-post-body {
	/* Sin max-width propio para alinearse con el .bc-post-header
	   del tema (mismo container width). El ancho de lectura se
	   controla en .bc-section/.bc-container del wrapper padre. */
	font-family: var(--bc-font-serif);
	font-size: var(--bc-fs-md);
	line-height: var(--bc-lh-relaxed);
	color: var(--bc-text);
}

.bc-post-body > * {
	max-width: 100%;
}

/* Espacio entre párrafos consistente — antes era muy apretado.
   Usamos 1.25em para escalar con el font-size del párrafo. */
.bc-post-body p {
	margin: 0 0 1.25em;
}

.bc-post-body p:last-child {
	margin-bottom: 0;
}

/* Subheaders dentro del post (h1..h6) — separación clara.
   Cubrimos también h1 aunque no debería aparecer (el título del post
   ya es el h1 de la página) — defensivo contra contenido migrado. */
.bc-post-body h1,
.bc-post-body h2,
.bc-post-body h3,
.bc-post-body h4,
.bc-post-body h5,
.bc-post-body h6 {
	margin-block: 1.5em 0.6em;
	font-family: var(--bc-font-display, var(--bc-font-serif));
	font-weight: var(--bc-fw-regular);
	line-height: 1.25;
	color: var(--bc-text);
	letter-spacing: normal;
}

.bc-post-body h1,
.bc-post-body h2 { font-size: var(--bc-fs-xl); }
.bc-post-body h3 { font-size: var(--bc-fs-lg); }
.bc-post-body h4 { font-size: var(--bc-fs-md); font-weight: var(--bc-fw-semi); }
.bc-post-body h5 { font-size: var(--bc-fs-md); font-weight: var(--bc-fw-semi); }
.bc-post-body h6 { font-size: var(--bc-fs-sm); font-weight: var(--bc-fw-semi); text-transform: uppercase; letter-spacing: var(--bc-ls-widest); }

/* Neutralizar inline styles heredados del Drupal migrado.
   El contenido tiene ~417 posts con style="" hardcoded (font-family,
   font-size, color) que rompen la tipografía consistente. Override con
   [style] selector y !important — es lo más limpio para content que no
   podemos reeditar a mano. */
.bc-post-body [style*="font-family"],
.bc-post-body [style*="font-size"],
.bc-post-body [style*="color"],
.bc-post-body [style*="line-height"],
.bc-post-body [style*="letter-spacing"] {
	font-family: inherit !important;
	font-size: inherit !important;
	color: inherit !important;
	line-height: inherit !important;
	letter-spacing: inherit !important;
}

/* Los headings sí mantienen su tamaño del theme aunque el content
   traiga font-size inline (sobreescribimos con selector más específico). */
.bc-post-body h1[style*="font-size"],
.bc-post-body h2[style*="font-size"],
.bc-post-body h3[style*="font-size"],
.bc-post-body h4[style*="font-size"],
.bc-post-body h5[style*="font-size"],
.bc-post-body h6[style*="font-size"] {
	font-size: revert-layer;
}
.bc-post-body h1[style] { font-size: var(--bc-fs-xl) !important; }
.bc-post-body h2[style] { font-size: var(--bc-fs-xl) !important; }
.bc-post-body h3[style] { font-size: var(--bc-fs-lg) !important; }
.bc-post-body h4[style] { font-size: var(--bc-fs-md) !important; }
.bc-post-body h5[style] { font-size: var(--bc-fs-md) !important; }
.bc-post-body h6[style] { font-size: var(--bc-fs-sm) !important; }

/* Imágenes — respetar el width/height hardcoded del HTML Drupal
   (que el autor escogió en el editor), pero limitar a 100% del
   container en mobile. NO usar `width: auto` porque eso ignora el
   attribute width y estiraría imágenes pequeñas hasta su intrinsic
   size (que en Drupal era full-resolution = enormes).
   `max-width: 100%` + `height: auto` mantiene aspect ratio si el
   container es más estrecho que el width hardcoded. */
.bc-post-body img {
	display: block;
	max-width: 100%;
	height: auto;
	margin-block: var(--bc-space-md);
	margin-inline: auto;
}

/* Imágenes en figure */
.bc-post-body figure {
	margin: var(--bc-space-md) 0;
	text-align: center;
}

.bc-post-body figure img {
	margin: 0 auto;
}

.bc-post-body figcaption {
	margin-top: 0.5rem;
	font-size: var(--bc-fs-sm);
	color: var(--bc-text-muted);
	font-style: italic;
}

/* Si la imagen está dentro de <a>, eliminar border default */
.bc-post-body a img {
	border: 0;
}

.bc-post-body a {
	color: var(--bc-accent-deep);
	text-decoration: underline;
	text-underline-offset: 3px;
}

.bc-post-body a:hover {
	color: var(--bc-text);
}

.bc-post-body strong {
	font-weight: var(--bc-fw-semi);
}

.bc-post-body ul,
.bc-post-body ol {
	padding-inline-start: 1.5rem;
	margin: 0 0 1.25em;
}

.bc-post-body li {
	margin-block: 0.35em;
}

/* Blockquotes editoriales */
.bc-post-body blockquote {
	margin: 1.5em 0;
	padding: 0.5em 0 0.5em 1.5em;
	border-left: 3px solid var(--bc-accent-deep);
	font-style: italic;
	color: var(--bc-text-muted);
}

/* Quitar wrappers Drupal residuales (en posts viejos con field-name-body) */
.bc-post-body .field,
.bc-post-body .field-items,
.bc-post-body .field-item {
	display: contents;
}

/* ── Paginación archive (index.php > the_posts_pagination()) ─────
   Aparece en /blog/, archives de categoría, archives de tag.
   Genera: .navigation.pagination > .nav-links > .page-numbers
   Genera: .current, .dots, .prev/.next, plain links */

.navigation.pagination {
	margin: var(--bc-space-xl) 0;
	padding-top: var(--bc-space-md);
	border-top: 1px solid var(--bc-border);
	text-align: center;
}

.navigation.pagination .nav-links {
	display: inline-flex;
	flex-wrap: wrap;
	justify-content: center;
	align-items: center;
	gap: 0.4em;
	font-family: var(--bc-font-sans);
	font-size: var(--bc-fs-sm);
	letter-spacing: 0.05em;
	color: var(--bc-text-muted);
}

.navigation.pagination .page-numbers {
	display: inline-flex;
	justify-content: center;
	align-items: center;
	min-width: 2.4em;
	height: 2.4em;
	padding: 0 0.7em;
	color: var(--bc-text);
	text-decoration: none;
	border: 1px solid var(--bc-border);
	border-radius: var(--bc-radius);
	transition: all 180ms ease;
	background: transparent;
}

.navigation.pagination a.page-numbers:hover {
	background: var(--bc-text);
	color: var(--bc-bg-warm, var(--bc-off-white));
	border-color: var(--bc-text);
}

.navigation.pagination .page-numbers.current {
	background: var(--bc-text);
	color: var(--bc-bg-warm, var(--bc-off-white));
	border-color: var(--bc-text);
	font-weight: var(--bc-fw-semi);
}

.navigation.pagination .page-numbers.dots {
	border: 0;
	background: transparent;
	color: var(--bc-text-muted);
	min-width: 1.5em;
}

.navigation.pagination .page-numbers.prev,
.navigation.pagination .page-numbers.next {
	padding: 0 1.2em;
}

.navigation.pagination .screen-reader-text {
	position: absolute !important;
	width: 1px; height: 1px;
	margin: -1px; padding: 0;
	overflow: hidden;
	clip: rect(0,0,0,0);
	border: 0;
}
