/*
 * SGP Blog. Only blog-specific rules; header/footer styling comes from the
 * original site stylesheets. Colours reuse the site's orange (#ff9f41) and teal (#48b9b7).
 */

[hidden] {
	display: none !important;
}

.screen-reader-text {
	position: absolute;
	width: 1px;
	height: 1px;
	margin: -1px;
	padding: 0;
	overflow: hidden;
	clip: rect(0, 0, 0, 0);
	white-space: nowrap;
	border: 0;
}

.sgp-blog {
	padding-bottom: 30px;
}

.sgp-blog__title {
	margin: 0 0 20px;
	font-size: 28px;
	font-weight: 700;
	color: #333;
}

/* Toolbar: search + categories */
.sgp-toolbar {
	margin-bottom: 15px;
}

.sgp-search .form-control {
	height: 40px;
}

.sgp-search .btn {
	height: 40px;
}

.sgp-cats {
	display: flex;
	flex-wrap: wrap;
	gap: 8px;
	margin-top: 15px;
}

.sgp-cat {
	padding: 6px 14px;
	border: 1px solid #48b9b7;
	border-radius: 3px;
	background: #fff;
	color: #48b9b7;
	font-size: 13px;
	line-height: 1.4;
	cursor: pointer;
}

.sgp-cat:hover,
.sgp-cat:focus,
.sgp-cat.is-active {
	background: #48b9b7;
	color: #fff;
}

.sgp-status {
	min-height: 20px;
	margin: 0 0 10px;
	color: #6b6b6b;
	font-size: 13px;
}

/* Post grid: flex so cards in a row share height */
.sgp-grid {
	display: flex;
	flex-wrap: wrap;
	transition: opacity 0.15s ease;
}

.sgp-grid::before,
.sgp-grid::after {
	display: none;
}

.sgp-grid.is-loading {
	opacity: 0.45;
	pointer-events: none;
}

.sgp-card-col {
	display: flex;
	margin-bottom: 30px;
}

.sgp-card {
	display: flex;
	flex-direction: column;
	width: 100%;
	border: 1px solid #dadada;
	border-radius: 3px;
	background: #fff;
	overflow: hidden;
}

.sgp-card__thumb {
	display: block;
	aspect-ratio: 3 / 2;
	background: #f2f2f2;
	overflow: hidden;
}

.sgp-card__thumb img,
.sgp-card__placeholder {
	display: block;
	width: 100%;
	height: 100%;
	object-fit: cover;
}

.sgp-card__placeholder {
	background: #ececec;
}

.sgp-card__body {
	display: flex;
	flex: 1;
	flex-direction: column;
	padding: 15px;
}

.sgp-card__cat {
	margin-bottom: 6px;
	color: #48b9b7;
	font-size: 12px;
	font-weight: 700;
	text-transform: uppercase;
}

.sgp-card__title {
	margin: 0 0 6px;
	font-size: 18px;
	line-height: 1.3;
}

.sgp-card__title a {
	color: #333;
}

.sgp-card__title a:hover {
	color: #48b9b7;
}

.sgp-card__date {
	margin-bottom: 8px;
	color: #6b6b6b;
	font-size: 12px;
}

.sgp-card__excerpt {
	flex: 1;
	margin-bottom: 12px;
	color: #555;
	font-size: 14px;
}

.sgp-card__more {
	align-self: flex-start;
}

.sgp-more {
	margin-top: 5px;
}

.sgp-none {
	padding: 40px 15px;
	text-align: center;
	color: #6b6b6b;
}

/* Sidebar */
.sgp-widget {
	margin-bottom: 30px;
	padding: 15px;
	border: 1px solid #dadada;
	border-radius: 3px;
	background: #fff;
}

.sgp-widget__title {
	margin: 0 0 15px;
	padding-bottom: 10px;
	border-bottom: 2px solid #ff9f41;
	font-size: 18px;
	font-weight: 700;
	color: #333;
}

.sgp-popular__list {
	margin: 0;
	padding: 0;
	list-style: none;
}

.sgp-popular__item {
	display: flex;
	gap: 12px;
	padding: 10px 0;
	border-bottom: 1px solid #ececec;
}

.sgp-popular__item:last-child {
	padding-bottom: 0;
	border-bottom: 0;
}

.sgp-popular__thumb {
	display: block;
	flex: 0 0 70px;
	width: 70px;
	height: 70px;
	background: #ececec;
	overflow: hidden;
}

.sgp-popular__thumb img {
	display: block;
	width: 100%;
	height: 100%;
	object-fit: cover;
}

.sgp-popular__text {
	min-width: 0;
}

.sgp-popular__text a {
	display: block;
	color: #333;
	font-size: 14px;
	line-height: 1.3;
}

.sgp-popular__text a:hover {
	color: #48b9b7;
}

.sgp-popular__text time {
	color: #6b6b6b;
	font-size: 12px;
}

/* Single post */
.sgp-single__title {
	margin: 0 0 10px;
	font-size: 30px;
	font-weight: 700;
	line-height: 1.25;
	color: #333;
}

.sgp-single__meta {
	margin-bottom: 20px;
	color: #6b6b6b;
	font-size: 13px;
}

.sgp-single__meta a {
	color: #48b9b7;
}

.sgp-sep {
	margin: 0 6px;
}

.sgp-single__image {
	margin: 0 0 25px;
}

.sgp-single__image img {
	display: block;
	max-width: 100%;
	height: auto;
}

.sgp-single__content {
	font-size: 16px;
	line-height: 1.7;
	color: #333;
	overflow-wrap: break-word;
}

.sgp-single__content img,
.sgp-single__content iframe,
.sgp-single__content video {
	max-width: 100%;
	height: auto;
}

.sgp-single__content h2,
.sgp-single__content h3,
.sgp-single__content h4 {
	margin: 28px 0 12px;
	font-weight: 700;
}

.sgp-single__content a {
	color: #48b9b7;
	text-decoration: underline;
}

.sgp-single__content table {
	display: block;
	max-width: 100%;
	overflow-x: auto;
}

.sgp-single__tags {
	margin-top: 25px;
	font-size: 13px;
}

.sgp-single__tags a {
	color: #48b9b7;
}

.sgp-related {
	margin-top: 40px;
	padding-top: 25px;
	border-top: 1px solid #dadada;
}

.sgp-related__title {
	margin: 0 0 20px;
	font-size: 22px;
	font-weight: 700;
	color: #333;
}

/* Pagination (archives / search fallback) */
.navigation.pagination {
	text-align: center;
}

.navigation.pagination .page-numbers {
	display: inline-block;
	margin: 0 2px;
	padding: 6px 12px;
	border: 1px solid #dadada;
	border-radius: 3px;
	color: #333;
}

.navigation.pagination .page-numbers.current {
	border-color: #ff9f41;
	background: #ff9f41;
	color: #fff;
}

@media (max-width: 991px) {
	.sgp-sidebar {
		margin-top: 20px;
	}
}

@media (max-width: 767px) {
	.sgp-blog__title,
	.sgp-single__title {
		font-size: 24px;
	}
}
