/**
 * Blog Sức Khỏe - Archive Styles
 * 
 * CSS isolation hoàn toàn - KHÔNG sử dụng styles từ Flatsome theme
 * 
 * @package Blog_Suc_Khoe
 * @version 1.0.0
 */

/* ==========================================================================
   1. RESET & ISOLATION
   ========================================================================== */

.sk-blog {
	all: revert;
	box-sizing: border-box;
	-webkit-font-smoothing: antialiased;
	-moz-osx-font-smoothing: grayscale;
}

.sk-blog *,
.sk-blog *::before,
.sk-blog *::after {
	box-sizing: border-box;

}

/* Reset Typography */
.sk-blog h1,
.sk-blog h2,
.sk-blog h3,
.sk-blog h4,
.sk-blog h5,
.sk-blog h6 {
	font-weight: 600;
	line-height: 1.2;
	color: #111827;
}

.sk-blog p {
	margin: 0 auto;
	line-height: 1.6;
	padding-bottom: 10px;
}

.sk-blog a {
	color: inherit;
	text-decoration: none;
}

.sk-blog ul,
.sk-blog ol {
	list-style: none;
}

.sk-blog img {
	max-width: 100%;
	height: auto;
	display: block;
}

.sk-blog button {
	cursor: pointer;
	border: none;
	background: none;
	font-family: inherit;
	margin: 0 !important;
	top: 24px;
}

.sk-blog input,
.sk-blog textarea {
	font-family: inherit;
	font-size: inherit;
}

/* ==========================================================================
   2. VARIABLES
   ========================================================================== */

:root {
	--sk-primary: #8DC63F;
	--sk-primary-dark: #76a831;
	--sk-secondary: #2c5f2d;
	--sk-bg-light: #F9FAFB;
	--sk-surface: #FFFFFF;
	--sk-text: #374151;
	--sk-text-dark: #111827;
	--sk-text-muted: #6B7280;
	--sk-border: #E5E7EB;
	--sk-border-light: #F3F4F6;
	--sk-shadow-sm: 0 1px 2px 0 rgba(0, 0, 0, 0.05);
	--sk-shadow: 0 1px 3px 0 rgba(0, 0, 0, 0.1), 0 1px 2px 0 rgba(0, 0, 0, 0.06);
	--sk-shadow-md: 0 4px 6px -1px rgba(0, 0, 0, 0.1), 0 2px 4px -1px rgba(0, 0, 0, 0.06);
	--sk-shadow-lg: 0 10px 15px -3px rgba(0, 0, 0, 0.1), 0 4px 6px -2px rgba(0, 0, 0, 0.05);
	--sk-shadow-xl: 0 20px 25px -5px rgba(0, 0, 0, 0.1), 0 10px 10px -5px rgba(0, 0, 0, 0.04);
	--sk-radius: 0.5rem;
	--sk-radius-xl: 1rem;
	--sk-radius-2xl: 1.5rem;
}

/* ==========================================================================
   3. CONTAINER & LAYOUT
   ========================================================================== */

.sk-container {
	max-width: 1280px;
	margin: 0 auto;
	padding: 0 1rem;
}

@media (min-width: 640px) {
	.sk-container {
		padding: 0 1.5rem;
	}
}

@media (min-width: 1024px) {
	.sk-container {
		padding: 0 2rem;
	}
}

.sk-grid-wrapper {
	display: grid;
	grid-template-columns: 1fr;
	gap: 2rem;
}

@media (min-width: 1024px) {
	.sk-grid-wrapper {
		grid-template-columns: 2fr 1fr;
	}
}

/* ==========================================================================
   4. HEADER SECTION
   ========================================================================== */

.sk-blog-header {
	background-image: linear-gradient(to right, #006838 0%, #8DC63F 100%);
	padding: 3rem 0 5rem;
	border-bottom: 1px solid var(--sk-border-light);
	text-align: center;
}

.sk-container h1,
.sk-container p {
	color: white;
}

@media (min-width: 640px) {
	.sk-blog-header {
		padding: 5rem 0;
	}
}

.sk-subtitle {
	display: inline-block;
	color: var(--sk-primary);
	font-weight: 700;
	font-size: 0.8rem;
	text-transform: uppercase;
	letter-spacing: 0.08em;
	margin-bottom: 0.5rem;
	padding: 0.35rem 0.9rem;
	border-radius: 9999px;
	background: rgb(255, 255, 255);
	position: relative;
}

.sk-subtitle::before {
	content: '';
	display: inline-block;
	width: 8px;
	height: 8px;
	border-radius: 50%;
	background: var(--sk-primary);
	margin-right: 8px;
	vertical-align: middle;
}

h2.sk-featured-title {
	font-size: 22px;
	margin-bottom: 10px;
}

.sk-title {
	font-size: 2.5rem;
	font-weight: 700;
	color: var(--sk-text-dark);
	margin: 0.5rem 0 1rem;
}

@media (min-width: 640px) {
	.sk-title {
		font-size: 3rem;
	}
}


.sk-description {
	max-width: 42rem;
	margin: 0 auto 2rem;
	font-size: 18px;
	color: var(--sk-text-muted);
	line-height: 1.75;
}

/* ==========================================================================
   5. TABS NAVIGATION
   ========================================================================== */

.sk-tabs {
	display: flex;
	flex-wrap: wrap;
	justify-content: center;
	gap: 0.75rem;
	margin-top: 2rem;
}

.sk-tab {
	display: inline-block;
	padding: 0.5rem 1.25rem;
	border-radius: 9999px;
	font-weight: 500;
	font-size: 0.875rem;
	transition: all 0.2s ease;
	cursor: pointer;
	border: 1px solid var(--sk-border);
	background: var(--sk-surface);
	color: var(--sk-text);
}

.sk-tab:hover {
	border-color: var(--sk-primary);
	color: var(--sk-primary);
}

.sk-tab-active {
	background: var(--sk-primary);
	color: #fff;
	border-color: var(--sk-primary);
	box-shadow: 0 4px 14px 0 rgba(141, 198, 63, 0.3);
}

/* ==========================================================================
   6. MAIN CONTENT
   ========================================================================== */

.sk-main {
	padding: 3rem 0;
	background: var(--sk-bg-light);
}

.sk-content {
	display: flex;
	flex-direction: column;
	gap: 3rem;
}

/* ==========================================================================
   7. FEATURED POST (Bài viết lớn)
   ========================================================================== */

.sk-featured-post {
	margin-bottom: 30px;
	display: flex;
	flex-direction: column;
	background: var(--sk-surface);
	border-radius: var(--sk-radius-2xl);
	box-shadow: var(--sk-shadow-lg);
	overflow: hidden;
	transition: box-shadow 0.3s ease;
}

.sk-featured-post:hover {
	box-shadow: var(--sk-shadow-xl);
}

.sk-featured-thumb {
	position: relative;
	height: 16rem;
	overflow: hidden;
}

@media (min-width: 640px) {
	.sk-featured-thumb {
		height: 20rem;
	}
}

.sk-featured-thumb img {
	width: 100%;
	height: 100%;
	object-fit: cover;
	transition: transform 0.5s ease;
}

.sk-featured-post:hover .sk-featured-thumb img {
	transform: scale(1.05);
}

.sk-featured-badge {
	position: absolute;
	top: 1rem;
	left: 1rem;
	background: rgba(255, 255, 255, 0.9);
	color: var(--sk-primary);
	font-size: 0.75rem;
	font-weight: 700;
	padding: 0.5rem 0.75rem;
	border-radius: 9999px;
	box-shadow: var(--sk-shadow-sm);
	backdrop-filter: blur(4px);
}

.sk-featured-content {
	padding: 1.5rem 2rem 2rem;
	display: flex;
	flex-direction: column;
	flex: 1;
}

.sk-meta {
	display: flex;
	align-items: center;
	gap: 10px;
	font-size: 0.875rem;
	color: var(--sk-text-muted);
	margin-bottom: 0.75rem;
}

.sk-meta-cat {
	font-weight: 600;
	color: var(--sk-primary);
}

.sk-meta-sep {
	color: var(--sk-border);
}

.sk-meta .sk-icon {
	color: var(--sk-primary);
	font-size: 0.95rem;
}

.sk-blog .fa-calendar {
	color: #8DC63F;
}

.sk-featured-title {
	font-size: 1.5rem;
	font-weight: 700;
	color: var(--sk-text-dark);
	margin-bottom: 1rem;
	line-height: 1.3;
}

@media (min-width: 640px) {
	.sk-featured-title {
		font-size: 1.875rem;
	}
}

.sk-featured-title a {
	transition: color 0.2s ease;
}

.sk-featured-post:hover .sk-featured-title a {
	color: var(--sk-primary);
}

.sk-featured-excerpt {
	color: var(--sk-text);
	margin-bottom: 15px;
	flex: 1;
	font-size: 14px;
}

.sk-read-more {
	display: inline-flex;
	align-items: center;
	gap: 0.5rem;
	font-weight: 700;
	color: var(--sk-primary);
	transition: all 0.3s ease;
	margin-top: auto;
}

.sk-read-more:hover {
	color: var(--sk-primary-dark);
}

.sk-featured-post:hover .sk-read-more {
	transform: translateX(0.25rem);
}

.sk-read-more .sk-icon {
	font-size: 1.125rem;
}

/* ==========================================================================
   8. GRID POSTS (Bài viết nhỏ 2 cột)
   ========================================================================== */

.sk-grid {
	display: grid;
	grid-template-columns: 1fr;
	gap: 2rem;
}

@media (min-width: 768px) {
	.sk-grid {
		grid-template-columns: repeat(2, 1fr);
	}
}

.sk-card {
	display: flex;
	flex-direction: column;
	background: var(--sk-surface);
	border-radius: var(--sk-radius-xl);
	box-shadow: var(--sk-shadow-sm);
	border: 1px solid var(--sk-border-light);
	overflow: hidden;
	transition: all 0.3s ease;
}

.sk-card:hover {
	box-shadow: var(--sk-shadow-md);
	transform: translateY(-2px);
}

.sk-card-thumb {
	position: relative;
	height: 12rem;
	overflow: hidden;
}

.sk-card-thumb img {
	width: 100%;
	height: 100%;
	object-fit: cover;
	transition: transform 0.5s ease;
}

.sk-card:hover .sk-card-thumb img {
	transform: scale(1.05);
}

.sk-card-thumb::after {
	content: '';
	position: absolute;
	bottom: 0;
	left: 0;
	right: 0;
	height: 50%;
	background: linear-gradient(to top, rgba(0, 0, 0, 0.5), transparent);
}

.sk-card-badge {
	position: absolute;
	bottom: 0.75rem;
	left: 0.75rem;
	background: var(--sk-primary);
	color: #fff;
	font-size: 0.75rem;
	font-weight: 700;
	padding: 0.25rem 0.5rem;
	border-radius: 0.25rem;
	z-index: 1;
}

.sk-card-content {
	padding: 1.25rem;
	display: flex;
	flex-direction: column;
	flex: 1;
}

.sk-card-meta {
	font-size: 0.75rem;
	color: var(--sk-text-muted);
	margin-bottom: 0.5rem;
	display: flex;
	align-items: center;
	gap: 0.35rem;
}

.sk-card-meta .sk-icon {
	color: var(--sk-primary);
	font-size: 0.95rem;
}

.sk-card-title {
	font-size: 18px;
	font-weight: 700;
	color: var(--sk-text-dark);
	margin-bottom: 0.75rem;
	line-height: 1.4;
	display: -webkit-box;
	-webkit-line-clamp: 2;
	-webkit-box-orient: vertical;
	overflow: hidden;
}

.sk-card-title a {
	transition: color 0.2s ease;
}

.sk-card:hover .sk-card-title a {
	color: var(--sk-primary);
}

.sk-card-excerpt {
	font-size: 0.875rem;
	color: var(--sk-text);
	line-height: 1.6;
	margin-bottom: 1rem;
	flex: 1;
	display: -webkit-box;
	-webkit-line-clamp: 3;
	-webkit-box-orient: vertical;
	overflow: hidden;
}


/* ==========================================================================
   9. PAGINATION
   ========================================================================== */

.bsk-pagination,
.sk-pagination {
	display: flex;
	justify-content: center;
	align-items: center;
	gap: 0.75rem;
	margin-top: 4rem;
	flex-wrap: wrap;
	padding: 2rem 0 1rem;
}

.bsk-pagination a,
.bsk-pagination span,
.sk-pagination a.page-numbers,
.sk-pagination span.page-numbers {
	display: inline-flex;
	align-items: center;
	justify-content: center;
	min-width: 2.5rem;
	height: 2.5rem;
	padding: 0 0.75rem;
	border-radius: 9999px;
	font-weight: 700;
	font-size: 0.875rem;
	text-decoration: none;
	transition: all 0.2s ease;
	background: var(--sk-surface);
	color: var(--sk-text-muted);
	border: 1px solid var(--sk-border-light);
}

/* Số trang mặc định */
.bsk-pagination a.page-numbers,
.sk-pagination a.page-numbers {
	background: var(--sk-surface);
	color: var(--sk-text-muted);
	border: 1px solid var(--sk-border-light);
}

.bsk-pagination a.page-numbers:hover,
.sk-pagination a.page-numbers:hover {
	background: var(--sk-bg-light);
	color: var(--sk-text-dark);
}

/* Trang hiện tại (active) */
.bsk-pagination a.page-numbers.current,
.bsk-pagination span.page-numbers.current,
.sk-pagination a.page-numbers.current,
.sk-pagination span.page-numbers.current {
	background: var(--sk-primary);
	color: #fff;
	border: 1px solid var(--sk-primary);
	box-shadow: 0 2px 8px rgba(141, 198, 63, 0.3);
}

/* Separator (dấu ...) */
.bsk-pagination span.page-numbers,
.sk-pagination span.page-numbers {
	background: none;
	border: none;
	color: var(--sk-text-muted);
	cursor: default;
	min-width: auto;
}

/* Icons trong pagination */
.bsk-pagination i,
.sk-pagination i {
	font-size: 0.875rem;
}

/* Prev/Next button */
.bsk-pagination__prev,
.bsk-pagination__next,
.bsk-pagination a.prev,
.bsk-pagination a.next,
.sk-pagination a.prev,
.sk-pagination a.next {
	padding: 0 1.5rem;
	background: var(--sk-surface);
	color: var(--sk-text-dark);
	border: 1px solid var(--sk-border-light);
	gap: 0.5rem;
	display: inline-flex;
	align-items: center;
	justify-content: center;
	min-width: auto;
	font-weight: 700;
	font-size: 0.875rem;
}

.bsk-pagination__prev:hover,
.bsk-pagination__next:hover,
.bsk-pagination a.prev:hover,
.bsk-pagination a.next:hover,
.sk-pagination a.prev:hover,
.sk-pagination a.next:hover {
	background: var(--sk-bg-light);
	border-color: var(--sk-text-muted);
	color: var(--sk-text-dark);
	box-shadow: 0 2px 4px rgba(0, 0, 0, 0.05);
}

.bsk-pagination__next i,
.bsk-pagination a.next i,
.sk-pagination a.next i {
	transition: transform 0.2s ease;
	margin-left: 0.35rem;
}

.bsk-pagination__next:hover i,
.bsk-pagination a.next:hover i,
.sk-pagination a.next:hover i {
	transform: translateX(2px);
}

/* Load more */
/* Load more removed - now using pagination */

/* ==========================================================================
   10. SIDEBAR
   ========================================================================== */

.sk-sidebar {
	display: flex;
	flex-direction: column;
	gap: 2rem;
	position: sticky;
	top: 90px;
	height: fit-content;
}

.sk-widget {
	background: var(--sk-surface);
	padding: 1.5rem;
	border-radius: var(--sk-radius-xl);
	box-shadow: var(--sk-shadow-sm);
	border: 1px solid var(--sk-border-light);
}

.sk-widget-title {
	font-size: 1.125rem;
	font-weight: 700;
	color: var(--sk-text-dark);
	margin-bottom: 1rem;
	display: flex;
	align-items: center;
	gap: 0.5rem;
}

.sk-widget .sk-icon {
	font-size: 1.25rem;
}

.sk-widget .fa-calendar {
	font-size: 0.95rem;
}

/* Popular widget icon color */
.sk-widget-title .fa-chart-line {
	color: #95C121;
}

/* Search Widget */
.sk-search-form {
	position: relative;
	display: flex;
	margin: 0 !important;
}

.sk-content p {
	color: black;
}

.sk-search-input {
	width: 100%;
	padding: 0.75rem 3rem 0.75rem 1rem;
	border: 1px solid var(--sk-border);
	border-radius: var(--sk-radius);
	font-size: 0.875rem;
	transition: all 0.2s ease;
}

.sk-search-input:focus {
	outline: none;
	border-color: var(--sk-primary);
	box-shadow: 0 0 0 3px rgba(141, 198, 63, 0.1);
}

.sk-search-btn {
	position: absolute;
	right: 0.5rem;
	top: 50%;
	transform: translateY(-50%);
	width: 2rem;
	height: 2rem;
	display: flex;
	align-items: center;
	justify-content: center;
	background: none;
	border: none;
	color: var(--sk-text-muted);
	cursor: pointer;
}

/* Popular Posts Widget */
.sk-popular-posts {
	display: flex;
	flex-direction: column;
	gap: 1rem;
}

.sk-popular-item {
	display: flex;
	gap: 1rem;
	align-items: flex-start;
	transition: all 0.2s ease;
}

.sk-popular-item:hover {
	transform: translateX(2px);
}

.sk-popular-thumb {
	flex-shrink: 0;
	width: 5rem;
	height: 5rem;
	border-radius: var(--sk-radius);
	overflow: hidden;
	position: relative;
}

.sk-popular-thumb img {
	width: 100%;
	height: 100%;
	object-fit: cover;
	transition: transform 0.3s ease;
}

.sk-popular-item:hover .sk-popular-thumb img {
	transform: scale(1.1);
}

.sk-popular-thumb::after {
	content: '';
	position: absolute;
	inset: 0;
	background: rgba(0, 0, 0, 0.1);
	transition: background 0.3s ease;
}

.sk-popular-item:hover .sk-popular-thumb::after {
	background: transparent;
}

.sk-popular-content {
	flex: 1;
}

.sk-popular-title {
	font-size: 0.875rem;
	font-weight: 600;
	color: var(--sk-text-dark);
	line-height: 1.4;
	margin-bottom: 0.25rem;
	display: -webkit-box;
	-webkit-line-clamp: 2;
	-webkit-box-orient: vertical;
	overflow: hidden;
	transition: color 0.2s ease;
}

.sk-popular-item:hover .sk-popular-title {
	color: var(--sk-primary);
}

.sk-popular-date {
	font-size: 0.75rem;
	color: var(--sk-text-muted);
}

/* Newsletter Widget */
.sk-widget-newsletter {
	background: linear-gradient(135deg, var(--sk-primary) 0%, var(--sk-secondary) 100%);
	color: #fff;
	position: relative;
	overflow: hidden;
}

.sk-widget-newsletter::before {
	content: '';
	position: absolute;
	top: -2.5rem;
	right: -2.5rem;
	width: 8rem;
	height: 8rem;
	background: rgba(255, 255, 255, 0.1);
	border-radius: 50%;
	filter: blur(2rem);
}

.sk-widget-newsletter .sk-widget-title {
	color: #fff;
	position: relative;
	z-index: 1;
}

.sk-newsletter-desc {
	font-size: 0.875rem;
	color: rgba(255, 255, 255, 0.9);
	line-height: 1.6;
	margin-bottom: 1rem;
	position: relative;
	z-index: 1;
}

.sk-newsletter-form {
	display: flex;
	flex-direction: column;
	gap: 0.5rem;
	position: relative;
	z-index: 1;
}

.sk-newsletter-input {
	width: 100%;
	padding: 0.5rem 0.75rem;
	border: none;
	border-radius: 0.375rem;
	background: rgba(255, 255, 255, 0.9);
	color: var(--sk-text-dark);
	font-size: 0.875rem;
}

.sk-newsletter-input::placeholder {
	color: var(--sk-text-muted);
}

.sk-newsletter-input:focus {
	outline: none;
	box-shadow: 0 0 0 2px rgba(255, 255, 255, 0.5);
}

.sk-newsletter-btn {
	width: 100%;
	padding: 0.5rem 0.75rem;
	background: #111827;
	color: #fff;
	font-weight: 600;
	font-size: 0.875rem;
	border: none;
	border-radius: 0.375rem;
	transition: all 0.2s ease;
	cursor: pointer;
}

.sk-newsletter-btn:hover {
	background: #1F2937;
}

/* Category List Widget */
.sk-category-list {
	display: flex;
	flex-direction: column;
	margin-top: 0.5rem;
}

.sk-category-item {
	border-bottom: 1px solid var(--sk-border-light);
	padding-bottom: 0.5rem;
}

.sk-category-item:last-child {
	border-bottom: none;
	padding-bottom: 0;
}

.sk-category-link {
	display: flex;
	justify-content: space-between;
	align-items: center;
	color: var(--sk-text);
	font-size: 0.9rem;
	font-weight: 600;
	transition: color 0.2s ease;
	padding: 0.35rem 0.5rem;
	border-radius: 0.5rem;
}

.sk-category-link:hover {
	color: var(--sk-primary);
	background: rgba(141, 198, 63, 0.06);
}

.sk-category-count {
	display: inline-flex;
	align-items: center;
	justify-content: center;
	min-width: 1.5rem;
	height: 1.5rem;
	padding: 0 0.5rem;
	background: var(--sk-bg-light);
	color: var(--sk-text-muted);
	font-size: 0.75rem;
	border-radius: 9999px;
	transition: all 0.2s ease;
	border: 1px solid var(--sk-border);
}

/* Tags Cloud (match bsk-tag style) */
.sk-tags-cloud {
	display: flex;
	flex-wrap: wrap;
	gap: 0.5rem;
}

.sk-tag-link {
	display: inline-block;
	padding: 0.25rem 0.75rem;
	background: #f2f4f0;
	color: #141811;
	font-size: 12px;
	font-weight: 400;
	border-radius: 9999px;
	transition: background 0.2s ease, color 0.2s ease;
}

.sk-tag-link:hover {
	background: var(--sk-primary);
	color: var(--sk-text);
}

.sk-category-link:hover .sk-category-count {
	background: rgba(141, 198, 63, 0.1);
	color: var(--sk-primary);
}

/* ==========================================================================
   11. UTILITIES & STATES
   ========================================================================== */

.sk-no-posts {
	padding: 4rem 2rem;
	text-align: center;
	color: var(--sk-text-muted);
	font-size: 1.125rem;
}

.sk-icon {
	display: inline-block;
	line-height: 1;
}

/* Loading State */
.sk-loading-overlay {
	position: fixed;
	top: 0;
	left: 0;
	right: 0;
	bottom: 0;
	background: rgba(255, 255, 255, 0.8);
	display: flex;
	align-items: center;
	justify-content: center;
	z-index: 9999;
	opacity: 0;
	visibility: hidden;
	transition: all 0.3s ease;
}

.sk-loading-overlay.active {
	opacity: 1;
	visibility: visible;
}

.sk-spinner {
	width: 3rem;
	height: 3rem;
	border: 4px solid var(--sk-border);
	border-top-color: var(--sk-primary);
	border-radius: 50%;
	animation: sk-spin 0.8s linear infinite;
}

@keyframes sk-spin {
	to {
		transform: rotate(360deg);
	}
}

/* ==========================================================================
   12. RESPONSIVE ADJUSTMENTS
   ========================================================================== */

@media (max-width: 767px) {
	.sk-blog-header {
		padding: 2rem 0 3rem;
	}

	.sk-title {
		font-size: 2rem;
	}

	.sk-description {
		font-size: 1rem;
	}

	.sk-tabs {
		gap: 0.5rem;
	}

	.sk-tab {
		font-size: 0.8125rem;
		padding: 0.375rem 1rem;
	}

	.sk-featured-content {
		padding: 1.25rem 1.5rem 1.5rem;
	}

	.sk-featured-title {
		font-size: 1.25rem;
	}
}

@media (max-width: 1023px) {
	.sk-sidebar {
		margin-top: 2rem;
	}
}