﻿
/* Container */
.tintuc-container {
	max-width: 1200px;
	padding-top: 50px;
	padding-bottom: 50px;
}

/* Header */
.tintuc-title {
	font-weight: 800;
	font-size: 2rem;
	color: #333;
}

.tintuc-hr {
	width: 60px;
	height: 3px;
	background: linear-gradient(90deg, #007bff, #00c6ff);
	margin: 0 auto 2rem auto;
	border: none;
	border-radius: 5px;
}

.tintuc-row {
	display: flex;
	flex-wrap: wrap;
	margin: 0 -10px;
}

	.tintuc-row .col-md-4 {
		padding: 10px;
		box-sizing: border-box;
	}

/* Card */
.tintuc-card {
	border: none; /* bỏ border */
	border-radius: 0.75rem;
	overflow: hidden;
	box-shadow: 0 4px 12px rgba(0,0,0,0.08);
	transition: all 0.3s ease;
	height: 550px;
	background: white;

}

	.tintuc-card:hover {
		transform: scale(1.05); /* phóng to khi hover */
		box-shadow: 0 8px 20px rgba(0,0,0,0.15);
	}

.card .card-img-top {
	width: auto;
	height: 250px !important; /* hoặc chiều cao bạn mong muốn */
	object-fit: cover; /* giúp ảnh không bị méo, cắt phần dư */
	border-top-left-radius: calc(.25rem - 1px);
	border-top-right-radius: calc(.25rem - 1px);
}


/*.tintuc-card-title {
	font-size: 1.25rem;
	margin-bottom: 0.5rem;
	font-weight: 600;
}
*/
.tintuc-card-link {
	text-decoration: none;
	color: #222;
	transition: color 0.2s;
}

	.tintuc-card-link:hover {
		color: #007bff;
		text-decoration: underline;
	}

.tintuc-card-date {
	font-size: 0.9rem;
	margin-bottom: 0.75rem;
}

.tintuc-card-summary {
	color: #555;
	font-size: 0.95rem;
}

/* Link Chi tiết */
.tintuc-card-detail {
	text-decoration: none;
	color: #007bff;
	font-weight: 500;
	transition: all 0.2s;
}

	.tintuc-card-detail:hover {
		text-decoration: underline;
		color: #0056b3;
	}


.tintuc-card-date {
	font-size: 0.9rem;
	color: #888;
	margin-bottom: 1rem;
}

.tintuc-card-summary {
	font-size: 1rem;
	margin-bottom: 1rem;
}

.tintuc-card-detail {
	font-size: 0.9rem;
	padding: 0.375rem 0.75rem;
}

.tintuc-wrapper {
	display: flex;
	justify-content: center;
	margin-top: 100px !important;
	max-width: 80%;
}

.tintuc-content {
	width: 120%;
	background: #fff;
	padding: 30px;
	border-radius: 12px;
	box-shadow: 0 4px 12px rgba(0, 0, 0, 0.1);
}



.tintuc-card-title {
	font-size: 1.3rem;
	font-weight: bold;
	color: #2c3e50;
	margin-bottom: 0.5rem;
	font-weight: 600;
	display: -webkit-box;
	-webkit-line-clamp: 3; /* Giới hạn 2 dòng */
	-webkit-box-orient: vertical;
	overflow: hidden;
	text-overflow: ellipsis;
}
.tintuc-hr {
	border: 0;
	border-top: 2px solid #007bff;
	width: 120px;
	margin: 0 auto;
}


.tintuc-date {
	font-size: 0.9rem;
}
.tintuc-card-summary {
	color: #555;
	font-size: 0.95rem;
	line-height: 1.5; /* giúp chữ dễ đọc hơn */
	display: -webkit-box;
	-webkit-line-clamp: 5; /* Giới hạn 5 dòng */
	-webkit-box-orient: vertical;
	overflow: hidden;
	text-overflow: ellipsis;
	height: 110px;
}


.tintuc-result {
	display: block; /* phải set lại display sau khi unset */
	font-family: Arial, sans-serif;
	font-size: 16px;
	line-height: 1.5;
	color: #333;
}

	.tintuc-result p {
		margin: 0 0 1em;
	}

	.tintuc-result img {
		width: 100% !important;
		height: auto !important;
		display: block !important;
		margin: 15px auto !important;
	}



.tintuc-back {
	min-width: 200px;
	border-radius: 30px;
}

@media (min-width: 1200px) {
	.tintuc-row .col-md-4 {
		width: 25%;  4 card 
	}
}

@media (min-width: 768px) and (max-width: 1199px) {
	.tintuc-row .col-md-4 {
		width: 33.33%;  3 card 
	}
}

@media (max-width: 767px) {
	.tintuc-row {
		width: 95%;
		margin: auto !important;
	}
	.card .card-img-top {
		height: 120px !important;
	}
	.tintuc-card{
		height:350px;
	}
	.tintuc-row .col-md-4 {
		width: 50%;  2 card 
	}
	.tintuc-container{
		padding-left: 0 !important;
		padding-right: 0 !important;
	}
	.tintuc-card-summary {
		color: #555;
		font-size: 0.95rem;
		line-height: 1.5;  giúp chữ dễ đọc hơn 
		display: -webkit-box;
		-webkit-line-clamp: 3;  Giới hạn 5 dòng 
		-webkit-box-orient: vertical;
		overflow: hidden;
		text-overflow: ellipsis;
		height: 65px;
		margin-bottom: 5px;
	}	.tintuc-card-nguon {
		color: #555;
		font-size: 0.95rem;
		line-height: 1.5;  giúp chữ dễ đọc hơn 
		display: -webkit-box;
		-webkit-line-clamp: 1;  Giới hạn 5 dòng 
		-webkit-box-orient: vertical;
		overflow: hidden;
		text-overflow: ellipsis;
		height: 16px;
		margin-bottom:5px;
	}
}

@media (max-width: 380px) {
	.tintuc-row {
		width: 95%;
		margin: auto !important;
	}
	.tintuc-row .col-md-4 {
		width: 100%;
		margin: auto !important;
	}
	.tintuc-card-summary {
		-webkit-line-clamp: 5;  Giới hạn 5 dòng 
	}
}


/* --- PHẦN NÀY ĐẢM BẢO DESKTOP KHÔNG HỎNG --- */
@media (min-width: 769px) {
	/* Ép ID này hiển thị dạng Row bình thường của Bootstrap */
	#tintuc-slider-mobile.owl-carousel {
		display: flex !important;
		flex-wrap: wrap !important;
	}
	/* Vô hiệu hóa các thẻ bọc của Owl trên Desktop */
	#tintuc-slider-mobile .owl-stage-outer,
	#tintuc-slider-mobile .owl-stage {
		display: block !important;
		width: 100% !important;
		transform: none !important;
	}
	/* Đảm bảo chia 4 cột đúng CSS cũ của bạn */
	#tintuc-slider-mobile .tintuc-item-wrapper {
		width: 25% !important;
		max-width: 25% !important;
		flex: 0 0 25% !important;
		float: left;
	}
	#tintuc-slider-mobile2.owl-carousel {
		display: flex !important;
		flex-wrap: wrap !important;
	}
	/* Vô hiệu hóa các thẻ bọc của Owl trên Desktop */
	#tintuc-slider-mobile2 .owl-stage-outer,
	#tintuc-slider-mobile2 .owl-stage {
		display: block !important;
		width: 100% !important;
		transform: none !important;
	}
	/* Đảm bảo chia 4 cột đúng CSS cũ của bạn */
	#tintuc-slider-mobile2 .tintuc-item-wrapper {
		width: 25% !important;
		max-width: 25% !important;
		flex: 0 0 25% !important;
		float: left;
	}
}

/* --- CHỈ CHỈNH SỬA TRÊN MOBILE --- */
@media (max-width: 768px) {
	#tintuc-slider-mobile, #tintuc-slider-mobile2{
		margin-left:50px;
		margin-top:20px
	}
	.tintuc-hr {
		border: 0;
		border-top: 2px solid #007bff;
		width: 120px;
		margin: 30px auto;
	}
	#tintuc-slider-mobile.owl-carousel {
		display: block !important;
	}
	/* Giữ nguyên các thông số font-size, height mobile bạn đã viết trước đó */
	#tintuc-slider-mobile .tintuc-item-wrapper {
		width: 100% !important; /* Owl tự tính toán 2 cột */
		padding: 0 5px !important;
	}

	#tintuc-slider-mobile .tintuc-card {
		height: 380px !important;
	}
	.owl-item {
		margin-right: 0 !important;
	}

	#tintuc-slider-mobile2.owl-carousel {
		display: block !important;
	}
	/* Giữ nguyên các thông số font-size, height mobile bạn đã viết trước đó */
	#tintuc-slider-mobile2 .tintuc-item-wrapper {
		width: 100% !important; /* Owl tự tính toán 2 cột */
		padding: 0 5px !important;
	}

	#tintuc-slider-mobile2 .tintuc-card {
		height: 380px !important;
	}

	.owl-item {
		margin-right: 0 !important;
	}
}

/* PC & Tablet: Ép hiển thị dạng hàng (Grid) kể cả khi có class owl-carousel */
/*@media (min-width: 768px) {
	#tintuc-slider-mobile.owl-carousel {
		display: flex !important;
		flex-wrap: wrap !important;
	}

	#tintuc-slider-mobile .owl-stage-outer,
	#tintuc-slider-mobile .owl-stage {
		display: block !important;
		width: 100% !important;
	}

	#tintuc-slider-mobile .owl-item {
		float: left;
	}*/

	/* PC ≥ 1200px (4 card) */
	/*@media (min-width: 1200px) {
		#tintuc-slider-mobile .p-item-news {
			width: 25% !important;
		}
	}*/
	/* Tablet (768px – 1199px) => 3 card */
	/*@media (max-width: 1199px) {
		#tintuc-slider-mobile .p-item-news {
			width: 33.33% !important;
		}
	}
}*/

/* Mobile (<768px) => Biến thành Slide */
/*@media (max-width: 767px) {
	#tintuc-slider-mobile.owl-carousel {
		display: block !important;*/ /* Owl cần block để chạy slide */
		/*width: 100% !important;
	}

	.p-item-news {
		width: 100% !important;*/ /* Owl sẽ tự chia 2 cột qua JS */
		/*padding: 0 5px;
	}

	.tintuc-row {
		width: 100%;*/ /* Để slide tràn sát lề một chút cho đẹp */
		/*margin: 0 !important;
	}

	.card .card-img-top {
		height: 120px !important;
		object-fit: cover;
	}

	.tintuc-card {
		height: 380px;*/ /* Tăng nhẹ để không bị mất nút xem chi tiết */
		/*margin-bottom: 10px;
	}

	.tintuc-card-summary {
		color: #555;
		font-size: 0.85rem;
		line-height: 1.4;
		display: -webkit-box;
		-webkit-line-clamp: 3;
		-webkit-box-orient: vertical;
		overflow: hidden;
		height: 55px;
	}

	.tintuc-card-nguon {
		font-size: 0.8rem;
		height: 16px;
		margin-bottom: 5px;
	}
}*/
