/**
 * Sahifa blog-listing features (ported). Each rule is scoped to a body class so
 * the two toggles are independent:
 *   .atr-blog-image-sizing  — Theme Options → "Listing: natural-size featured images"
 *   .atr-blog-read-more     — Theme Options → "Excerpt read-more button"
 * Both target core block markup, so they work for any child theme's query loop.
 */

/* Natural-size featured images: show each at its native size capped at the
   column width, never upscaled (the Sahifa blog look). Scoped to query loops so
   single-post featured images are unaffected. The !important beats lazy-load
   plugins (e.g. WP Smush) that set inline width/aspect on the <img>. */
body.atr-blog-image-sizing .wp-block-query .wp-block-post-featured-image img {
	width: auto !important;
	height: auto !important;
	max-width: 100% !important;
}

/* Excerpt read-more accent button. --atr-accent lets a child theme set the
   colour; defaults to the Sahifa global colour. */
body.atr-blog-read-more .wp-block-post-excerpt__more-link {
	display: inline-block;
	background: var(--atr-accent, #4c6775);
	color: #fff !important;
	padding: 2px 8px;
	margin-top: 4px;
	text-decoration: none;
}
body.atr-blog-read-more .wp-block-post-excerpt__more-link:hover {
	opacity: 0.9;
}
