/*!
Theme Name: ketquaxoso
Theme URI: http://underscores.me/
Author: xskt.net
Author URI: https://xskt.net
Description: Template WordPress - Kết quả xổ số kiến thiết 3 miền
Version: 2.0.0
Tested up to: 6.4
Requires PHP: 7.4
License: GNU General Public License v2 or later
License URI: LICENSE
Text Domain: ketquaxoso
*/

/* ==========================================================================
   CSS Variables
   ========================================================================== */

:root {
	--color-primary: #e8730c;
	--color-primary-dark: #d06a0a;
	--color-dark: #333;
	--color-darker: #3c3c3c;
	--color-nav: #ee6205;
	--color-footer: #2d2d2d;
	--color-text: #333;
	--color-text-light: #666;
	--color-border: #ddd;
	--color-bg: #f0f0f0;
	--color-white: #fff;
	--color-sidebar-header: #dddddd;
	--font-family: "Roboto", sans-serif;;
}

/* ==========================================================================
   Base
   ========================================================================== */

body {
	font-family: var(--font-family);
	font-size: 14px;
	color: var(--color-text);
	background-color: var(--color-bg);
	line-height: 1.5;
}

a {
	color: var(--color-text);
	text-decoration: none;
	transition: color 0.2s;
}

a:hover {
	color: var(--color-primary);
	text-decoration: none;
}

img {
	max-width: 100%;
	height: auto;
}

/* Screen reader text */
.screen-reader-text {
	border: 0;
	clip: rect(1px, 1px, 1px, 1px);
	clip-path: inset(50%);
	height: 1px;
	margin: -1px;
	overflow: hidden;
	padding: 0;
	position: absolute !important;
	width: 1px;
	word-wrap: normal !important;
}

/* ==========================================================================
   Top Announcement Bar
   ========================================================================== */

.top-bar {
    color: #fff;
    text-align: left;
    padding: 7px 0;
    font-size: 13px;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
    border-bottom: 1px solid #555;
	background: var(--color-darker);
}

/* ==========================================================================
   Header / Logo
   ========================================================================== */

.site-header {
	background: var(--color-darker);
	padding: 12px 0;
}

.site-branding {
	line-height: 1;
}

.site-logo-text {
	font-size: 34px;
	font-weight: 900;
	text-decoration: none !important;
	display: inline-block;
	line-height: 1;
}

.logo-xskt {
	color: var(--color-primary);
	font-style: italic;
}

.logo-dot {
	color: #fff;
	font-style: normal;
}

.site-logo-text:hover {
	opacity: 0.85;
	color: #fff;
}

/* Custom logo image */
.site-branding .custom-logo-link img {
	max-height: 50px;
	width: auto;
}

/* Header separator & date */
.header-sep {
	color: #888;
	font-size: 28px;
	font-weight: 300;
	margin: 0 15px;
	line-height: 1;
}

.header-date {
	font-size: 14px;
	color: #fff;
	white-space: nowrap;
}

/* ==========================================================================
   Desktop Navigation
   ========================================================================== */

.main-nav {
	background: var(--color-nav);
	position: relative;
	z-index: 100;
	transition: box-shadow 0.2s;
}

.main-nav.sticky {
	position: fixed;
	top: 0;
	left: 0;
	width: 100%;
	box-shadow: 0 2px 6px rgba(0,0,0,0.15);
}

/* Home icon */
.nav-home-icon {
	display: flex;
	align-items: center;
	justify-content: center;
	color: #fff !important;
	font-size: 18px;
	padding: 10px 14px 10px 5px;
	flex-shrink: 0;
	text-decoration: none !important;
	transition: opacity 0.2s;
}

.nav-home-icon:hover {
	opacity: 0.8;
	color: #fff !important;
}

/* Menu wrapper */
.nav-menu-wrap {
	flex: 1;
}

/* WordPress default ul.menu */
.nav-menu-wrap .menu {
	display: flex;
	flex-wrap: nowrap;
	list-style: none;
	margin: 0;
	padding: 0;
	align-items: center;
}

.nav-menu-wrap .menu > .menu-item {
	position: relative;
}

.nav-menu-wrap .menu > .menu-item > a {
    display: block;
    color: #fff;
    padding: 10px 13px;
    font-size: 14px;
    white-space: nowrap;
    text-decoration: none;
    transition: color 0.2s;
    font-weight: bold;
    text-transform: uppercase;
}

.nav-menu-wrap .menu > .menu-item > a:hover,
.nav-menu-wrap .menu > .menu-item.current-menu-item > a,
.nav-menu-wrap .menu > .menu-item.current-menu-ancestor > a {
	color: #fff;
	text-shadow: 0 0 1px rgba(255,255,255,0.5);
}

/* Dropdown caret */
.nav-menu-wrap .menu > .menu-item-has-children > a::after {
    content: ' \25BE';
    font-size: 16px;
    opacity: 1;
    margin-left: 0px;
}

/* Sub-menu dropdown */
.nav-menu-wrap .sub-menu {
	display: none;
	position: absolute;
	top: 100%;
	left: 0;
	background: var(--color-white);
	min-width: 200px;
	box-shadow: 0 4px 15px rgba(0, 0, 0, 0.15);
	border-radius: 0 0 4px 4px;
	list-style: none;
	margin: 0;
	padding: 5px 0;
	z-index: 1000;
}

.nav-menu-wrap .sub-menu .menu-item a {
	display: block;
	padding: 7px 16px;
	color: var(--color-text);
	font-size: 13px;
	text-decoration: none;
	transition: background 0.15s, color 0.15s;
}

.nav-menu-wrap .sub-menu .menu-item a:hover {
	background: #f5f5f5;
	color: var(--color-primary);
}

/* Show dropdown on hover */
.nav-menu-wrap .menu > .menu-item:hover > .sub-menu,
.nav-menu-wrap .menu > .menu-item.focus > .sub-menu {
	display: block;
}

/* Level 2 items with children */
.nav-menu-wrap .sub-menu .menu-item-has-children {
	position: relative;
}

.nav-menu-wrap .sub-menu .menu-item-has-children > a {
	display: flex;
	justify-content: space-between;
	align-items: center;
}

.nav-menu-wrap .sub-menu .menu-item-has-children > a::after {
	content: '\25B8';
	font-size: 11px;
	margin-left: 8px;
	opacity: 0.5;
}

/* Nested sub-menu (level 3+) */
.nav-menu-wrap .sub-menu .sub-menu {
	top: 0;
	left: 100%;
	border-radius: 4px;
}

/* If near right edge, open to the left */
.nav-menu-wrap .menu > .menu-item:last-child .sub-menu .sub-menu,
.nav-menu-wrap .menu > .menu-item:nth-last-child(2) .sub-menu .sub-menu {
	left: auto;
	right: 100%;
}

.nav-menu-wrap .sub-menu .menu-item-has-children:hover > .sub-menu {
	display: block;
}

/* ==========================================================================
   Mobile Navigation Bar
   ========================================================================== */

.mobile-nav {
	background: var(--color-nav);
	display: flex;
	align-items: center;
	padding: 0;
	position: relative;
	z-index: 100;
	transition: box-shadow 0.2s;
}

.mobile-nav.sticky {
	position: fixed;
	top: 0;
	left: 0;
	width: 100%;
	box-shadow: 0 2px 6px rgba(0,0,0,0.15);
}

.mobile-toggle {
	background: none;
	border: none;
	color: #fff;
	font-size: 20px;
	padding: 10px 14px;
	cursor: pointer;
	flex-shrink: 0;
	line-height: 1;
}

.mobile-quick-links {
	flex: 1;
	overflow-x: auto;
	white-space: nowrap;
	-webkit-overflow-scrolling: touch;
	scrollbar-width: none;
}

.mobile-quick-links::-webkit-scrollbar {
	display: none;
}

.mobile-quick-links .quick-menu {
	display: flex;
	list-style: none;
	margin: 0;
	padding: 0;
}

.mobile-quick-links .quick-menu > .menu-item > a {
	display: block;
	color: #fff;
	padding: 10px 12px;
	font-size: 14px;
	font-weight: 600;
	text-decoration: none;
	white-space: nowrap;
}

.mobile-quick-links .quick-menu > .menu-item > a:hover {
	opacity: 0.8;
}

/* ==========================================================================
   Mobile Off-canvas Menu
   ========================================================================== */

.mobile-overlay {
	display: none;
	position: fixed;
	top: 0;
	left: 0;
	right: 0;
	bottom: 0;
	background: rgba(0, 0, 0, 0.45);
	z-index: 9998;
}

.mobile-overlay.active {
	display: block;
}

.mobile-panel {
	position: fixed;
	top: 0;
	left: -85%;
	width: 80%;
	max-width: 320px;
	height: 100%;
	background: var(--color-white);
	z-index: 9999;
	transition: left 0.3s ease;
	overflow-y: auto;
	box-shadow: 2px 0 15px rgba(0, 0, 0, 0.2);
}

.mobile-panel.active {
	left: 0;
}

.mobile-panel-header {
	display: flex;
	align-items: center;
	justify-content: space-between;
	padding: 15px;
	border-bottom: 1px solid var(--color-border);
	background: #fafafa;
}

.mobile-panel-brand {
	font-size: 13px;
	color: var(--color-text-light);
	flex: 1;
}

.mobile-panel-brand strong {
	color: var(--color-primary);
	font-size: 16px;
}

.mobile-panel-close {
	background: none;
	border: none;
	font-size: 18px;
	color: var(--color-text);
	cursor: pointer;
	padding: 5px 8px;
	margin-left: 10px;
}

/* Mobile menu items (wp_nav_menu output) */
.mobile-nav-container .mobile-menu {
	list-style: none;
	margin: 0;
	padding: 0;
}

.mobile-nav-container .mobile-menu > .menu-item {
	border-bottom: 1px solid #f0f0f0;
}

.mobile-nav-container .mobile-menu > .menu-item > a {
	display: block;
	padding: 12px 15px;
	font-weight: 700;
	font-size: 15px;
	color: var(--color-text);
	text-decoration: none;
}

/* Colored dots before parent section headers */
.mobile-nav-container .mobile-menu > .menu-item-has-children > a::before {
	content: '\25CF';
	margin-right: 8px;
	font-size: 12px;
}

.mobile-nav-container .mobile-menu > .menu-item-has-children:nth-child(1) > a::before {
	color: #e74c3c;
}

.mobile-nav-container .mobile-menu > .menu-item-has-children:nth-child(2) > a::before {
	color: #e67e22;
}

.mobile-nav-container .mobile-menu > .menu-item-has-children:nth-child(3) > a::before {
	color: #27ae60;
}

.mobile-nav-container .mobile-menu > .menu-item-has-children:nth-child(4) > a::before {
	color: #3498db;
}

.mobile-nav-container .mobile-menu > .menu-item-has-children:nth-child(5) > a::before {
	color: #9b59b6;
}

/* Level 2 sub-menu as 2-column grid */
.mobile-nav-container .sub-menu {
	display: grid;
	grid-template-columns: 1fr 1fr;
	gap: 2px;
	list-style: none;
	margin: 0;
	padding: 0 10px 12px;
}

.mobile-nav-container .sub-menu .menu-item a {
	display: block;
	padding: 7px 10px;
	color: var(--color-text-light);
	font-size: 14px;
	text-decoration: none;
	border-radius: 4px;
}

.mobile-nav-container .sub-menu .menu-item a:hover {
	background: #f0f0f0;
	color: var(--color-primary);
}

/* Level 2 items with children - span full width + toggle arrow */
.mobile-nav-container .sub-menu > .menu-item-has-children {
	grid-column: 1 / -1;
}

.mobile-nav-container .sub-menu > .menu-item-has-children > a {
	display: flex;
	justify-content: space-between;
	align-items: center;
	font-weight: 600;
	color: var(--color-text);
}

.mobile-nav-container .sub-menu > .menu-item-has-children > a .submenu-arrow {
	font-size: 11px;
	transition: transform 0.2s;
	margin-left: 6px;
	opacity: 0.5;
}

.mobile-nav-container .sub-menu > .menu-item-has-children.open > a .submenu-arrow {
	transform: rotate(90deg);
}

/* Level 3 sub-menu - hidden by default */
.mobile-nav-container .sub-menu .sub-menu {
	display: none;
	grid-template-columns: 1fr 1fr;
	gap: 1px;
	padding: 2px 0 8px 5px;
	background: #fafafa;
	border-radius: 4px;
	margin-top: 2px;
}

.mobile-nav-container .sub-menu > .menu-item-has-children.open > .sub-menu {
	display: grid;
}

.mobile-nav-container .sub-menu .sub-menu .menu-item a {
	font-size: 13px;
	padding: 6px 8px;
	color: var(--color-text-light);
}

/* ==========================================================================
   Layout / Content
   ========================================================================== */

.site-content {
	padding: 15px 0;
}

.content-area {
	min-height: 300px;
}

/* ==========================================================================
   Sidebar Boxes (slide1.php / slide2.php)
   ========================================================================== */

.sidebar-box {
	background: var(--color-white);
	border: 1px solid var(--color-border);
	border-radius: 4px;
	margin-bottom: 15px;
	overflow: hidden;
}

.sidebar-box-title {
	background: var(--color-sidebar-header);
	color: #222;
	padding: 10px 15px;
	margin: 0;
	font-size: 15px;
	font-weight: 700;
}

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

.sidebar-list li {
	border-bottom: 1px solid #f0f0f0;
}

.sidebar-list li:last-child {
	border-bottom: none;
}

.sidebar-list li a {
	display: flex;
	align-items: center;
	justify-content: space-between;
	padding: 9px 15px;
	color: var(--color-text);
	text-decoration: none;
	font-size: 14px;
}

.sidebar-list li a:hover {
	background: #f8f8f8;
	color: var(--color-primary);
}

/* Live indicator dots */
.live-dot {
	color: #e74c3c;
	font-size: 10px;
	letter-spacing: 2px;
}

/* News Latest (sidebar) */
.news-latest {
	padding: 0;
}

.news-featured {
	display: block;
	text-decoration: none;
	color: var(--color-text);
	border-bottom: 1px solid #f0f0f0;
}

.news-featured-img {
	width: 100%;
	overflow: hidden;
}

.news-featured-img img {
	width: 100%;
	height: auto;
	display: block;
}

.news-featured-title {
	margin: 0;
	padding: 10px 12px 4px;
	font-size: 15px;
	font-weight: 700;
	line-height: 1.4;
	color: #222;
}

.news-featured-excerpt {
	margin: 0;
	padding: 0 12px 10px;
	font-size: 13px;
	color: #666;
	line-height: 1.5;
}

.news-featured:hover .news-featured-title {
	color: var(--color-primary);
}

.news-item {
	display: flex;
	align-items: center;
	gap: 10px;
	padding: 8px 12px;
	text-decoration: none;
	color: var(--color-text);
	border-bottom: 1px solid #f0f0f0;
}

.news-item:last-child {
	border-bottom: none;
}

.news-item-thumb {
	width: 80px;
	height: 60px;
	flex-shrink: 0;
	border-radius: 4px;
	overflow: hidden;
}

.news-item-thumb img {
	width: 100%;
	height: 100%;
	object-fit: cover;
	display: block;
}

.news-item-thumb.news-no-thumb {
	background: #f0f0f0;
	display: flex;
	align-items: center;
	justify-content: center;
	color: #bbb;
	font-size: 20px;
}

.news-item-title {
	margin: 0;
	font-size: 13px;
	font-weight: 600;
	line-height: 1.4;
	color: #222;
	display: -webkit-box;
	-webkit-line-clamp: 3;
	-webkit-box-orient: vertical;
	overflow: hidden;
}

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

@media (max-width: 767.98px) {
	.news-featured {
		display: flex;
		align-items: center;
		gap: 10px;
		padding: 8px 12px;
	}
	.news-featured-img {
		width: 80px;
		height: 60px;
		flex-shrink: 0;
		border-radius: 4px;
	}
	.news-featured-img img {
		height: 100%;
		object-fit: cover;
	}
	.news-featured-title {
		padding: 0;
		font-size: 13px;
		font-weight: 600;
		display: -webkit-box;
		-webkit-line-clamp: 3;
		-webkit-box-orient: vertical;
		overflow: hidden;
	}
	.news-featured-excerpt {
		display: none;
	}
}

/* Calendar box */
.calendar-box {
	background: var(--color-white);
	border: 1px solid var(--color-border);
	border-radius: 4px;
	margin-bottom: 15px;
	overflow: hidden;
}

.calendar-header {
	display: flex;
	align-items: center;
	justify-content: space-between;
	padding: 10px 12px;
	font-weight: 700;
	font-size: 14px;
}

.calendar-header a {
	color: var(--color-text);
	text-decoration: none;
	font-size: 16px;
	padding: 0 5px;
}

.calendar-header a:hover {
	color: var(--color-primary);
}

.calendar-table {
	width: 100%;
	text-align: center;
	font-size: 13px;
	border-collapse: collapse;
}

.calendar-table th {
	padding: 6px 4px;
	font-weight: 700;
	color: var(--color-text);
	border-bottom: 1px solid #eee;
}

.calendar-table td {
	padding: 6px 4px;
}

.calendar-table td a {
	display: inline-block;
	width: 28px;
	height: 28px;
	line-height: 28px;
	border-radius: 4px;
	color: var(--color-text);
	text-decoration: none;
}

.calendar-table td a:hover {
	background: #f0f0f0;
}

.calendar-table td a.today {
	background: var(--color-primary);
	color: #fff;
	font-weight: 700;
}

.calendar-table td.future {
	color: #ccc;
}

/* Dò vé số form */
.doveso-box {
	background: var(--color-white);
	border: 1px solid var(--color-border);
	border-radius: 4px;
	margin-bottom: 15px;
	overflow: hidden;
	padding: 15px;
}

.doveso-box .box-title {
	font-size: 16px;
	font-weight: 700;
	margin: 0 0 12px;
	color: var(--color-text);
}

.doveso-row {
	display: flex;
	gap: 8px;
	margin-bottom: 8px;
}

.doveso-row input,
.doveso-row select {
	flex: 1;
	padding: 7px 10px;
	border: 1px solid var(--color-border);
	border-radius: 4px;
	font-size: 13px;
	color: var(--color-text);
}

.doveso-row .btn-doveso {
	background: var(--color-primary);
	color: #fff;
	border: none;
	border-radius: 4px;
	padding: 7px 16px;
	font-size: 14px;
	font-weight: 600;
	cursor: pointer;
	white-space: nowrap;
}

.doveso-row .btn-doveso:hover {
	background: var(--color-primary-dark);
}

/* ==========================================================================
   Footer
   ========================================================================== */

.site-footer {
	background: var(--color-footer);
	color: #bbb;
	padding: 35px 0 0;
	margin-top: 20px;
}

.footer-col-title {
	color: #fff;
	font-size: 16px;
	font-weight: 700;
	margin-bottom: 15px;
	padding-bottom: 8px;
	border-bottom: 2px solid #555;
}

.footer-menu {
	list-style: none;
	margin: 0;
	padding: 0;
}

.footer-menu .menu-item a {
	display: block;
	color: #bbb;
	padding: 4px 0;
	font-size: 14px;
	text-decoration: none;
	transition: color 0.2s;
}

.footer-menu .menu-item a:hover {
	color: #fff;
}

.footer-divider {
	border-color: #555;
	margin: 25px 0 15px;
	opacity: 0.5;
}

.footer-tags {
	text-align: center;
	margin-bottom: 20px;
	font-size: 14px;
}

.footer-tag {
	display: inline-block;
	background: #555;
	color: #fff !important;
	padding: 4px 14px;
	border-radius: 3px;
	margin: 0 3px;
	font-size: 13px;
	text-decoration: none !important;
	transition: background 0.2s;
}

.footer-tag:hover {
	background: #777;
	color: #fff !important;
}

.footer-bottom {
	text-align: center;
	padding: 20px 0;
	border-top: 1px solid #444;
}

.footer-bottom-logo {
	margin-bottom: 5px;
}

.footer-logo-text {
	font-size: 30px;
	color: #fff;
}

.footer-logo-text strong {
	color: var(--color-primary);
	font-style: italic;
}

.footer-slogan {
	font-weight: 700;
	color: #fff;
	margin: 5px 0;
	font-size: 14px;
}

.footer-contact {
	color: #fff;
	margin: 3px 0;
	font-size: 13px;
}

.footer-copyright {
	color: #999;
	font-size: 13px;
	margin: 5px 0 0;
}

/* ==========================================================================
   Scroll to top button (optional)
   ========================================================================== */

.scroll-top {
	position: fixed;
	bottom: 20px;
	right: 20px;
	width: 40px;
	height: 40px;
	background: var(--color-primary);
	color: #fff;
	border: none;
	border-radius: 4px;
	font-size: 18px;
	cursor: pointer;
	display: none;
	align-items: center;
	justify-content: center;
	z-index: 999;
	transition: background 0.2s;
}

.scroll-top:hover {
	background: var(--color-primary-dark);
}

.scroll-top.visible {
	display: flex;
}

/* ==========================================================================
   Responsive
   ========================================================================== */

@media (max-width: 767.98px) {
	.top-bar {
		font-size: 11px;
		padding: 5px 10px;
	}

	.site-header {
		padding: 8px 0;
	}

	.site-logo-text {
		font-size: 26px;
	}

	.header-sep {
		margin: 0 8px;
		font-size: 22px;
	}

	.header-date {
		font-size: 12px;
	}

	.site-content {
		padding: 10px 0;
	}

	.footer-links-row {
		text-align: center;
	}

	.footer-col {
		margin-bottom: 20px;
	}

	.footer-col-title {
		font-size: 15px;
	}

	.site-footer {
		padding: 25px 0 0;
	}
}

@media (min-width: 992px) and (max-width: 1199.98px) {
	.nav-menu-wrap .menu > .menu-item > a {
		padding: 10px 9px;
		font-size: 13px;
	}
}

/* iPad / tablet: ẩn center sidebar, giãn 2 col còn lại */
@media (max-width: 991.98px) {
	.center-side-bar {
		display: none !important;
	}
}

@media (min-width: 768px) and (max-width: 991.98px) {
	.row.margin-b > .col-md-6:first-child {
		width: 75% !important;
		flex: 0 0 75% !important;
		max-width: 75% !important;
	}

	.row.margin-b > .col-md-3.fix-width-right {
		width: 25% !important;
		flex: 0 0 25% !important;
		max-width: 25% !important;
	}
}

/* ==========================================================================
   Lottery Result Tables
   ========================================================================== */

/* --- boxResult Container --- */
.boxResult {
	background: #fff;
	margin-bottom: 15px;
}

/* --- Loto Trực Tiếp --- */
.loto-tructiep {
	border: 1px solid #dee2e6;
	border-top: none;
}

.ltt-tabs {
	display: flex;
	background: #f5f5f5;
	border-bottom: 1px solid #dee2e6;
}

.ltt-tab {
	flex: 1;
	text-align: center;
	padding: 6px 4px;
	font-size: 13px;
	font-weight: 700;
	cursor: pointer;
	border-right: 1px solid #dee2e6;
	background: #fff;
	color: #333;
}

.ltt-tab:last-child {
	border-right: none;
}

.ltt-tab.active {
    background: #019386;
    color: #fff;
}

.ltt-header {
    background: #bee5eb;
    color: #222;
    text-align: center;
    padding: 4px 0;
    font-size: 13px;
    font-weight: 700;
}

.ltt-grid {
	margin-top:0px;
	width: 100%;
	table-layout: fixed;
	border-collapse: collapse;
	background: #fff;
}

.ltt-grid td {
	border: 1px solid #dee2e6;
	text-align: center;
	padding: 3px 0;
	font-size: 14px;
	font-weight: 700;
}

.ltt-grid td.text-red {
	color: #d0021b;
}

/* Tab color variants */
.ltt-tabs.tabs-green .ltt-tab.active { background: #28a745; color: #fff; }
.ltt-tabs.tabs-red .ltt-tab.active { background: #dc3545; color: #fff; }

/* --- Result Header (Red bar) --- */
.result-header {
    text-align: center;
    padding: 5px 0;
    border: 1px solid #d8d7d7;
    background: #ffeeba;
    color: #000;
}

.result-header h2,
.result-header h3 {
	font-weight: normal;
	padding: 0;
	margin: 0 !important;
}

.result-header .title,
.result-header h2 .title {
	text-decoration: none;
	font-size: 20px;
	color: #333;
	font-weight: 500;
}

.result-header .title-link-item a,
.result-header a {
	text-decoration: underline;
	color: #007bff;
	font-size: 15px;
	font-weight: 400;
}

.result-header .title-link-item {
	font-size: 15px;
}

/* --- Override Bootstrap 5 table conflicts for lottery tables --- */
.table.table-result > :not(caption) > * > * {
	padding: 0;
	padding-top: .75rem;
	box-shadow: none;
	background-color: transparent;
	--bs-table-bg-type: transparent;
	--bs-table-bg-state: transparent;
	--bs-table-accent-bg: transparent;
}

.table.table-result {
    --bs-table-striped-bg: transparent;
    --bs-table-bg: #fff;
    border-color: #ababab;
    padding-top: 0px;
    margin-top: -1px !important;
}

.table.table-result > :not(caption) > * {
	box-shadow: none;
}

/* table-result base */
.table-result td {
	padding: 0;
	padding-top: .75rem;
	vertical-align: middle;
	border-color: #dee2e6;
}

.table-result td:first-child {
	font-size: 14px;
	width: 15%;
	vertical-align: middle;
}

/* --- text-number (prize numbers) --- */
.table-result .text-number {
	line-height: 1;
	font-weight: 700;
	font-size: 18px;
	width: 100%;
	padding-bottom: .75rem;
	display: inline-block;
	color: #333;
}

/* First row text-number: red (mã trúng thưởng / G8 first row) */
.table-result tr:first-child .text-number {
    color: #d0021b;
    font-size: 15px;
    padding-top: 10px;
}

/* ===================== XSMB ===================== */
/* Row 1: Mã trúng thưởng (bg-yellow1) */
.table-result-xsmb tr:first-child td {
	padding: 0;
}

/* Row 2: ĐB - Large red */
.table-result-xsmb tr:nth-child(2) .text-number {
	font-size: 24px;
	color: #d0021b;
}

/* Row 4: G2 (2 numbers) */
.table-result-xsmb tr:nth-child(4) .text-number {
	width: 49%;
}

/* Row 5: G3 (6 numbers) */
.table-result-xsmb tr:nth-child(5) .text-number {
	width: 30%;
}

/* Row 6: G4 (4 numbers) */
.table-result-xsmb tr:nth-child(6) .text-number {
	width: 23%;
}

/* Row 7: G5 (6 numbers) */
.table-result-xsmb tr:nth-child(7) .text-number {
	width: 30%;
}

/* Row 8: G6 (3 numbers) */
.table-result-xsmb tr:nth-child(8) .text-number {
	width: 30%;
}

/* Row 9: G7 (4 numbers, 2-digit) - RED */
.table-result-xsmb tr:nth-child(9) .text-number {
	width: 23%;
	color: #d0021b;
}

/* ===================== XSMN/XSMT Multi-column ===================== */
/* Province header row */
.table-result-multi tr:first-child td {
	padding: .5rem 0;
}

.table-result-multi tr:first-child td b a {
	color: #333;
	text-decoration: none;
	font-weight: 700;
}

.table-result-multi tr:first-child td b a:hover {
	color: var(--color-primary);
}

/* G8 row (2nd row, 2-digit) - RED */
.table-result-multi tr:nth-child(2) .text-number {
	color: #d0021b;
}

/* ĐB row (last row) - RED */
.table-result-multi tr:last-child .text-number {
	color: #d0021b;
}

/* ===================== XS Tỉnh (single province) ===================== */
/* G6 row - 3 numbers */
.table-result-tinh tr:nth-child(3) .text-number {
	width: 33%;
}

/* G4 row - 7 numbers (XSMN) or 4 (XSMB) */
.table-result-tinh tr:nth-child(5) .text-number {
	width: 25%;
}

/* G3 row - 2 numbers */
.table-result-tinh tr:nth-child(6) .text-number {
	width: 50%;
}

/* G1 row - RED */
.table-result-tinh tr:nth-child(8) .text-number {
	color: #d0021b;
}

/* ĐB row - RED, large */
.table-result-tinh tr:nth-child(9) .text-number {
	color: #d0021b;
	font-size: 200%;
}

/* ===================== Color Utilities ===================== */
.bg-yellow1 {
	background-color: #fff9dc !important;
}

.bg-blue1 {
	background-color: #33496d !important;
}

.bg-gray2 {
	background-color: #e0e0e0 !important;
}

.bg-red1 {
	background-color: #d0021b !important;
}

.text-red1 {
	color: #d0021b !important;
}

.text-red {
	color: #d0021b;
}

/* ===================== Loto Table ===================== */
.table.table-loto > :not(caption) > * > * {
	padding: .3rem .5rem;
	box-shadow: none;
	background-color: transparent;
	--bs-table-bg-type: transparent;
	--bs-table-bg-state: transparent;
	--bs-table-accent-bg: transparent;
}

.table.table-loto {
	--bs-table-striped-bg: transparent;
	--bs-table-bg: #fff;
}

.table-loto td:first-child {
	width: 15%;
	text-align: center;
}

.table-loto td {
	text-align: left;
	vertical-align: middle;
	font-size: 14px;
}

.table-loto th {
	font-size: 14px;
	text-align: center;
}

.table-loto span:not(:last-child):after {
	content: ', ';
}

.table-loto-single td:nth-child(1),
.table-loto-single td:nth-child(3) {
	width: 10%;
	text-align: center;
}

.table-loto-single td:nth-child(2),
.table-loto-single td:nth-child(4) {
	width: 40%;
}

/* ===================== footerResult ===================== */
.footerResult {
	background: #fff;
}

.footerResult label {
	cursor: pointer;
	display: flex;
	align-items: center;
	gap: 5px;
	font-size: 14px;
}

.footerResult input[type=radio],
.footerResult input[type=checkbox] {
	appearance: none;
	-webkit-appearance: none;
	position: relative;
	width: 18px;
	height: 18px;
	min-width: 18px;
	background: #fff;
	border: 1px solid #dee2e6;
	display: inline-flex;
	align-items: center;
	justify-content: center;
	flex-shrink: 0;
	cursor: pointer;
	margin: 0;
	vertical-align: middle;
	border-radius: 0;
}

.footerResult input[type=radio]:checked,
.footerResult input[type=checkbox]:checked {
	background: #d0021b;
	border-color: #d0021b;
}

.footerResult input[type=radio]:checked:after,
.footerResult input[type=checkbox]:checked:after {
	content: "\2713";
	color: #fff;
	font-size: 13px;
	font-weight: 700;
}

/* check-number circles */
div.check-number ul {
	display: flex;
	margin: 0;
	padding: 0;
	list-style: none;
}

div.check-number ul li {
	list-style-type: none;
	width: 24px;
	height: 24px;
	background: #fff;
	color: #797979;
	border: 2px solid #797979;
	border-radius: 50%;
	line-height: 20px;
	text-align: center;
	vertical-align: middle;
	margin: 0 5px 0 0;
	cursor: pointer;
	font-size: 12px;
}

div.check-number ul li.active,
div.check-number ul li:hover {
	color: #f38a08;
	border-color: #f38a08;
}

/* Highlight number khi click toolbar */
.text-number.highlight-number {
	background: #fff3cd;
	color: #d0021b;
	font-weight: bold;
	border-radius: 3px;
}

/* ===================== Show Today & Table-B ===================== */
.show-today {
	border: 1px solid #fff;
	border-top-left-radius: 4px;
	border-top-right-radius: 4px;
	overflow: hidden;
	text-align: center;
	white-space: nowrap;
	height: 43px;
	border-bottom: 2px solid #f83f55;
	background: #fff;
}

.show-today .title {
	font-size: 18px;
	font-weight: 700;
	height: inherit;
	vertical-align: middle;
	line-height: 43px;
	color: #3e3f42;
}

.table-b {
	width: 100%;
	text-align: center;
	background: #fff;
}

.table-b tr td {
	padding: .75rem;
	vertical-align: top;
}

.table-b tr td:not(:last-child) {
	border-right: 1px solid #dee2e6;
}

.table-b tr:not(:last-child) td {
	border-bottom: 1px solid #dee2e6;
}

.table-b a {
	color: #333;
	text-decoration: none;
}

.table-b a:hover {
	color: var(--color-primary);
}

/* ===================== title-bg-red & title-bg-blue ===================== */
.title-bg-red {
	min-height: 40px;
	display: flex;
	align-items: center;
	color: #fff;
	text-transform: uppercase;
	padding: 0 1rem;
	margin: 0;
	border-top-left-radius: 6px;
	border-top-right-radius: 6px;
	background: #d0021b;
	font-size: 16px;
}

.title-bg-red a {
	color: #fff;
}

.title-bg-blue {
	min-height: 40px;
	display: flex;
	align-items: center;
	color: #fff;
	text-transform: uppercase;
	padding: 0 1rem;
	margin: 0;
	border-top-left-radius: 6px;
	border-top-right-radius: 6px;
	background: #33496d;
	font-size: 15px;
}

.title-bg-blue a {
	color: #fff;
}

.title-border-bottom {
	min-height: 40px;
	display: flex;
	align-items: center;
	border-bottom: 2px solid #d0021b;
	text-transform: uppercase;
	color: #d0021b;
	font-weight: 700;
	padding: .5rem;
	justify-content: center;
	margin-bottom: 0;
	background: #fff;
}

/* ===================== BS4 Compatibility Utilities ===================== */
.font-weight-bold {
	font-weight: 700 !important;
}

.font-weight-normal {
	font-weight: 400 !important;
}

.font-14 {
	font-size: 14px;
}

.mr-1 { margin-right: .25rem !important; }
.mr-2 { margin-right: .5rem !important; }
.mr-3 { margin-right: 1rem !important; }
.ml-1 { margin-left: .25rem !important; }
.ml-2 { margin-left: .5rem !important; }
.pr-1 { padding-right: .25rem !important; }
.pr-2 { padding-right: .5rem !important; }
.pl-1 { padding-left: .25rem !important; }
.pl-2 { padding-left: .5rem !important; }

.no-gutters {
	margin-right: 0;
	margin-left: 0;
}

.no-gutters > .col,
.no-gutters > [class*="col-"] {
	padding-right: 0;
	padding-left: 0;
}

/* ===================== Font Size Utilities ===================== */
.fs-14 { font-size: 14px; }
.fs-15 { font-size: 15px; }
.fs-16 { font-size: 16px; }
.fs-18 { font-size: 18px; }
.fs-20 { font-size: 20px; }
.fs16 { font-size: 16px !important; }

@media screen and (min-width: 992px) {
	.fs-lg-14 { font-size: 14px; }
	.fs-lg-15 { font-size: 15px; }
	.fs-lg-16 { font-size: 16px; }
	.fs-lg-18 { font-size: 18px; }
	.fs-lg-20 { font-size: 20px; }
}

/* ===================== btn-load-more ===================== */
.btn-load-more {
	background: #fff;
	width: 100%;
	height: 40px;
	border: 1px solid #dee2e6;
	border-radius: 2px;
	font-size: 14px;
	color: #717171;
	display: flex;
	align-items: center;
	justify-content: center;
	cursor: pointer;
}

.btn-load-more:hover {
	background: #f5f5f5;
}

/* ===================== Spinning Number Animation ===================== */
.number-running {
	display: inline-block;
	width: 24px;
	height: 24px;
	border: 3px solid #f3f3f3;
	border-top: 3px solid #3498db;
	border-radius: 50%;
	animation: spin 0.8s linear infinite;
}

/* ===================== Desktop: Larger numbers ===================== */
@media screen and (min-width: 992px) {
	.table-result .text-number {
		font-size: 20px;
	}

	.table-result-xsmb tr:nth-child(2) .text-number {
		font-size: 30px;
	}

	.result-header .title {
		font-size: 20px;
	}
}

/* ===================== Mobile Responsive ===================== */
@media (max-width: 767.98px) {
	.table-result .text-number {
		font-size: 16px;
	}

	.table-result-xsmb tr:nth-child(2) .text-number {
		font-size: 22px;
	}

	.table-result-tinh tr:nth-child(9) .text-number {
		font-size: 150%;
	}

	.result-header .title {
		font-size: 16px;
	}

	.result-header .title-link-item a {
		font-size: 13px;
	}

	.show-today .title {
		font-size: 14px;
	}

	div.check-number ul li {
		width: 20px;
		height: 20px;
		line-height: 16px;
		font-size: 11px;
		margin: 0 3px 0 0;
	}
}

@media (max-width: 479px) {
	.table-result .text-number {
		font-size: 14px;
	}

	.table-result-xsmb tr:nth-child(2) .text-number {
		font-size: 20px;
	}

	.show-today .title {
		font-size: 12px;
	}

	.result-header .title {
		font-size: 14px;
	}

	.result-header .title-link-item a {
		font-size: 12px;
	}
}

/* =============================================
   THỐNG KÊ XSMB BOX
   ============================================= */

.thongke-box {
	background: #fff;
	border-radius: 6px;
	overflow: hidden;
	box-shadow: 0 1px 3px rgba(0,0,0,.1);
}

/* Tabs */
.thongke-tabs {
	display: flex;
	background: #f5f5f5;
	border-bottom: 2px solid #ddd;
}

.thongke-tab {
	flex: 1;
	text-align: center;
	padding: 10px 8px;
	font-size: 13px;
	font-weight: 600;
	color: #555;
	text-decoration: none;
	border-bottom: 3px solid transparent;
	transition: all .2s;
}

.thongke-tab:hover {
	color: #d22121;
	text-decoration: none;
}

.thongke-tab.active {
	color: #fff;
	background: #d22121;
	border-bottom-color: #d22121;
}

/* Content */
.thongke-content {
	padding: 12px 15px;
}

/* Section */
.thongke-section {
	margin-bottom: 14px;
	padding-bottom: 14px;
	border-bottom: 1px dashed #eee;
}

.thongke-section:last-child {
	margin-bottom: 0;
	padding-bottom: 0;
	border-bottom: none;
}

.thongke-title {
	font-size: 14px;
	font-weight: 700;
	color: #333;
	margin-bottom: 10px;
	padding-left: 8px;
	border-left: 3px solid #d22121;
}

/* Numbers container */
.thongke-numbers {
	display: flex;
	flex-wrap: wrap;
	gap: 8px;
}

/* Circle numbers */
.so-circle {
	display: inline-flex;
	flex-direction: column;
	align-items: center;
	justify-content: center;
	width: 44px;
	height: 44px;
	border-radius: 50%;
	font-size: 15px;
	font-weight: 700;
	line-height: 1;
	position: relative;
}

.so-circle small {
	font-size: 9px;
	font-weight: 400;
	opacity: .8;
	margin-top: 1px;
}

.so-circle.so-red {
	background: #d22121;
	color: #fff;
}

.so-circle.so-green {
	background: #28a745;
	color: #fff;
}

.so-circle.so-blue {
	background: #007bff;
	color: #fff;
}

.so-circle.so-gray {
	background: #ccc;
	color: #666;
}

/* Small circle for table cells */
.so-circle.so-sm {
	width: 32px;
	height: 32px;
	font-size: 13px;
}

.so-circle.so-sm small {
	display: none;
}

/* Thống kê table */
.thongke-table-wrap {
	overflow-x: auto;
}

.thongke-table {
	width: 100%;
	border-collapse: collapse;
	text-align: center;
}

.thongke-table th {
	font-size: 11px;
	font-weight: 600;
	color: #666;
	padding: 4px 2px 6px;
	white-space: nowrap;
}

.thongke-table td {
	padding: 4px 2px;
}

/* Responsive */
@media (max-width: 767px) {
	.thongke-tab {
		font-size: 11px;
		padding: 8px 4px;
	}

	.thongke-content {
		padding: 10px 10px;
	}

	.so-circle {
		width: 38px;
		height: 38px;
		font-size: 13px;
	}

	.so-circle.so-sm {
		width: 28px;
		height: 28px;
		font-size: 11px;
	}

	.thongke-title {
		font-size: 13px;
	}

	.thongke-numbers {
		gap: 6px;
	}
}

/* Hub pages: Thống Kê, Soi Cầu, Công Cụ - link grid */
.hub-links {
	display: grid;
	grid-template-columns: 1fr 1fr;
	gap: 4px 16px;
	padding: 10px 20px 15px;
}
.hub-link-item {
	display: flex;
	align-items: baseline;
	gap: 8px;
	color: #0056b3;
	text-decoration: none;
	font-size: 14px;
	padding: 4px 0;
	line-height: 1.5;
}
.hub-link-item:hover {
	color: #003d80;
	text-decoration: underline;
}
.hub-arrow {
	color: #333;
	font-size: 10px;
	flex-shrink: 0;
}
@media (max-width: 767px) {
	.hub-links {
		grid-template-columns: 1fr;
		padding: 8px 15px 12px;
	}
	.hub-link-item {
		font-size: 13px;
	}
}

/* =============================================
   SINGLE POST (sp-*)
   ============================================= */
.sp-breadcrumb {
	font-size: 13px;
	padding: 10px 0;
	color: #666;
}
.sp-breadcrumb a {
	color: #0056b3;
	text-decoration: none;
}
.sp-breadcrumb a:hover {
	text-decoration: underline;
}
.sp-breadcrumb .sep {
	margin: 0 6px;
	color: #999;
}
.sp-breadcrumb .current {
	color: #333;
}

.sp-article {
	background: #fff;
	border: 1px solid #e0e0e0;
	border-radius: 4px;
	overflow: hidden;
	margin-bottom: 15px;
}
.sp-header {
	padding: 15px 18px 10px;
	border-bottom: 1px solid #f0f0f0;
}
.sp-title {
	font-size: 20px;
	font-weight: 700;
	color: #222;
	margin: 0 0 8px;
	line-height: 1.35;
}
.sp-meta {
	display: flex;
	flex-wrap: wrap;
	gap: 6px 16px;
	font-size: 13px;
	color: #777;
}
.sp-meta i {
	margin-right: 4px;
	color: #999;
}
.sp-meta a {
	color: #0056b3;
	text-decoration: none;
}

.sp-thumbnail {
	border-bottom: 1px solid #f0f0f0;
}
.sp-thumbnail img {
	width: 100%;
	height: auto;
	display: block;
}

.sp-content {
	padding: 18px;
	font-size: 15px;
	line-height: 1.7;
	color: #333;
	word-wrap: break-word;
}
.sp-content p { margin-bottom: 12px; }
.sp-content img { max-width: 100%; height: auto; }
.sp-content h2 { font-size: 18px; margin: 20px 0 10px; color: #222; }
.sp-content h3 { font-size: 16px; margin: 16px 0 8px; color: #333; }
.sp-content ul, .sp-content ol { padding-left: 24px; margin-bottom: 12px; }
.sp-content blockquote {
	border-left: 3px solid #dc3545;
	margin: 15px 0;
	padding: 10px 16px;
	background: #fafafa;
	color: #555;
}
.sp-content table {
	width: 100%;
	border-collapse: collapse;
	margin-bottom: 12px;
}
.sp-content table th, .sp-content table td {
	border: 1px solid #ddd;
	padding: 6px 10px;
}

.sp-page-links {
	padding: 10px 0;
	font-weight: 600;
}
.sp-page-links a {
	display: inline-block;
	padding: 2px 8px;
	margin: 0 3px;
	background: #f0f0f0;
	border-radius: 3px;
	text-decoration: none;
	color: #333;
}

.sp-tags {
	padding: 12px 18px;
	border-top: 1px solid #f0f0f0;
	font-size: 13px;
}
.sp-tags i {
	color: #999;
	margin-right: 6px;
}
.sp-tags a {
	display: inline-block;
	background: #f5f5f5;
	border: 1px solid #e0e0e0;
	border-radius: 3px;
	padding: 3px 10px;
	margin: 3px 4px 3px 0;
	color: #555;
	text-decoration: none;
	font-size: 12px;
}
.sp-tags a:hover {
	background: #dc3545;
	border-color: #dc3545;
	color: #fff;
}

/* Prev / Next navigation */
.sp-nav {
	display: flex;
	gap: 12px;
	margin-bottom: 15px;
}
.sp-nav-prev, .sp-nav-next {
	flex: 1;
	display: block;
	background: #fff;
	border: 1px solid #e0e0e0;
	border-radius: 4px;
	padding: 12px 15px;
	text-decoration: none;
	transition: border-color .2s;
}
.sp-nav-prev:hover, .sp-nav-next:hover {
	border-color: #dc3545;
}
.sp-nav-next {
	text-align: right;
}
.sp-nav-label {
	display: block;
	font-size: 12px;
	color: #999;
	margin-bottom: 4px;
}
.sp-nav-title {
	display: block;
	font-size: 13px;
	color: #333;
	font-weight: 600;
	line-height: 1.4;
	display: -webkit-box;
	-webkit-line-clamp: 2;
	-webkit-box-orient: vertical;
	overflow: hidden;
}

/* Related posts */
.sp-related {
	background: #fff;
	border: 1px solid #e0e0e0;
	border-radius: 4px;
	padding: 15px;
	margin-bottom: 15px;
}
.sp-related-title {
	font-size: 16px;
	font-weight: 700;
	color: #222;
	margin: 0 0 12px;
	padding-bottom: 8px;
	border-bottom: 2px solid #dc3545;
}
.sp-related-grid {
	display: grid;
	grid-template-columns: 1fr 1fr;
	gap: 12px;
}
.sp-related-item {
	display: block;
	text-decoration: none;
	border: 1px solid #f0f0f0;
	border-radius: 4px;
	overflow: hidden;
	transition: box-shadow .2s;
}
.sp-related-item:hover {
	box-shadow: 0 2px 8px rgba(0,0,0,.1);
}
.sp-related-thumb {
	height: 100px;
	overflow: hidden;
	background: #f5f5f5;
}
.sp-related-thumb img {
	width: 100%;
	height: 100%;
	object-fit: cover;
}
.sp-no-thumb {
	display: flex;
	align-items: center;
	justify-content: center;
	color: #ccc;
	font-size: 28px;
}
.sp-related-item h4 {
	font-size: 13px;
	font-weight: 600;
	color: #333;
	margin: 8px 10px 4px;
	line-height: 1.4;
	display: -webkit-box;
	-webkit-line-clamp: 2;
	-webkit-box-orient: vertical;
	overflow: hidden;
}
.sp-related-date {
	display: block;
	font-size: 11px;
	color: #999;
	margin: 0 10px 8px;
}

/* Comments section */
.sp-comments {
	background: #fff;
	border: 1px solid #e0e0e0;
	border-radius: 4px;
	padding: 18px;
	margin-bottom: 15px;
}
.sp-comments .comments-title {
	font-size: 16px;
	font-weight: 700;
	margin: 0 0 12px;
	padding-bottom: 8px;
	border-bottom: 2px solid #dc3545;
}
.sp-comments .comment-list {
	list-style: none;
	padding: 0;
	margin: 0;
}
.sp-comments .comment-list li {
	padding: 12px 0;
	border-bottom: 1px solid #f0f0f0;
}
.sp-comments .comment-list li:last-child {
	border-bottom: none;
}
.sp-comments .comment-author {
	font-weight: 600;
	font-size: 14px;
}
.sp-comments .comment-author img {
	border-radius: 50%;
	margin-right: 8px;
	vertical-align: middle;
}
.sp-comments .comment-metadata {
	font-size: 12px;
	color: #999;
	margin-bottom: 6px;
}
.sp-comments .comment-metadata a {
	color: #999;
	text-decoration: none;
}
.sp-comments .comment-content {
	font-size: 14px;
	line-height: 1.6;
}
.sp-comments .comment-content p {
	margin: 4px 0;
}
.sp-comments .reply a {
	font-size: 12px;
	color: #0056b3;
}
.sp-comments .comment-respond {
	margin-top: 15px;
}
.sp-comments .comment-reply-title {
	font-size: 16px;
	font-weight: 700;
	margin-bottom: 10px;
}
.sp-comments .comment-form label {
	display: block;
	font-size: 13px;
	font-weight: 600;
	margin-bottom: 4px;
}
.sp-comments .comment-form input[type="text"],
.sp-comments .comment-form input[type="email"],
.sp-comments .comment-form input[type="url"],
.sp-comments .comment-form textarea {
	width: 100%;
	padding: 8px 12px;
	border: 1px solid #ddd;
	border-radius: 4px;
	font-size: 14px;
	margin-bottom: 10px;
	box-sizing: border-box;
}
.sp-comments .comment-form textarea {
	height: 120px;
	resize: vertical;
}
.sp-comments .form-submit input[type="submit"] {
	background: #dc3545;
	color: #fff;
	border: none;
	padding: 9px 24px;
	border-radius: 4px;
	font-size: 14px;
	font-weight: 600;
	cursor: pointer;
}
.sp-comments .form-submit input[type="submit"]:hover {
	background: #c82333;
}

/* =============================================
   PAGE (pg-*)
   ============================================= */
.pg-article {
	background: #fff;
	border: 1px solid #e0e0e0;
	border-radius: 4px;
	overflow: hidden;
	margin-bottom: 15px;
}
.pg-header {
	padding: 15px 18px 12px;
	border-bottom: 1px solid #f0f0f0;
}
.pg-title {
	font-size: 20px;
	font-weight: 700;
	color: #222;
	margin: 0;
	line-height: 1.35;
}
.pg-thumbnail {
	border-bottom: 1px solid #f0f0f0;
}
.pg-thumbnail img {
	width: 100%;
	height: auto;
	display: block;
}
.pg-content {
	padding: 18px;
	font-size: 15px;
	line-height: 1.7;
	color: #333;
	word-wrap: break-word;
}
.pg-content p { margin-bottom: 12px; }
.pg-content img { max-width: 100%; height: auto; }
.pg-content h2 { font-size: 18px; margin: 20px 0 10px; color: #222; }
.pg-content h3 { font-size: 16px; margin: 16px 0 8px; color: #333; }
.pg-content ul, .pg-content ol { padding-left: 24px; margin-bottom: 12px; }
.pg-content table {
	width: 100%;
	border-collapse: collapse;
	margin-bottom: 12px;
}
.pg-content table th, .pg-content table td {
	border: 1px solid #ddd;
	padding: 6px 10px;
}

/* =============================================
   ARCHIVE (ar-*)
   ============================================= */
.ar-header {
	background: #fff;
	border: 1px solid #e0e0e0;
	border-radius: 4px;
	padding: 15px 18px;
	margin-bottom: 12px;
}
.ar-title {
	font-size: 18px;
	font-weight: 700;
	color: #222;
	margin: 0;
}
.ar-desc {
	font-size: 14px;
	color: #666;
	margin-top: 6px;
	line-height: 1.5;
}
.ar-desc p { margin: 0; }

.ar-list {
	display: flex;
	flex-direction: column;
	gap: 10px;
}
.ar-item {
	display: flex;
	gap: 14px;
	background: #fff;
	border: 1px solid #e0e0e0;
	border-radius: 4px;
	padding: 12px;
	transition: box-shadow .2s;
}
.ar-item:hover {
	box-shadow: 0 2px 8px rgba(0,0,0,.08);
}
.ar-thumb {
	flex-shrink: 0;
	width: 120px;
	height: 85px;
	border-radius: 4px;
	overflow: hidden;
}
.ar-thumb img {
	width: 100%;
	height: 100%;
	object-fit: cover;
}
.ar-body {
	flex: 1;
	min-width: 0;
}
.ar-item-title {
	font-size: 15px;
	font-weight: 700;
	margin: 0 0 5px;
	line-height: 1.35;
}
.ar-item-title a {
	color: #222;
	text-decoration: none;
}
.ar-item-title a:hover {
	color: #dc3545;
}
.ar-item-meta {
	display: flex;
	gap: 12px;
	font-size: 12px;
	color: #999;
	margin-bottom: 6px;
}
.ar-item-meta i {
	margin-right: 3px;
}
.ar-excerpt {
	font-size: 13px;
	color: #555;
	margin: 0 0 6px;
	line-height: 1.5;
	display: -webkit-box;
	-webkit-line-clamp: 2;
	-webkit-box-orient: vertical;
	overflow: hidden;
}
.ar-readmore {
	font-size: 13px;
	color: #0056b3;
	text-decoration: none;
	font-weight: 600;
}
.ar-readmore:hover {
	color: #dc3545;
}

.ar-empty {
	background: #fff;
	border: 1px solid #e0e0e0;
	border-radius: 4px;
	padding: 40px 18px;
	text-align: center;
}
.ar-empty .ar-title {
	font-size: 18px;
	margin-bottom: 8px;
}
.ar-empty p {
	color: #999;
	margin: 0;
}

/* Pagination */
.ar-pagination {
	margin: 15px 0;
	text-align: center;
}
.ar-pagination ul {
	list-style: none;
	padding: 0;
	margin: 0;
	display: inline-flex;
	gap: 4px;
}
.ar-pagination li {
	display: inline-block;
}
.ar-pagination li a,
.ar-pagination li span {
	display: inline-flex;
	align-items: center;
	justify-content: center;
	min-width: 34px;
	height: 34px;
	padding: 0 8px;
	border: 1px solid #ddd;
	border-radius: 4px;
	font-size: 13px;
	color: #333;
	text-decoration: none;
	background: #fff;
}
.ar-pagination li a:hover {
	background: #f0f0f0;
	border-color: #ccc;
}
.ar-pagination li span.current {
	background: #dc3545;
	border-color: #dc3545;
	color: #fff;
	font-weight: 700;
}

/* =============================================
   RESPONSIVE: single / page / archive
   ============================================= */
@media (max-width: 767px) {
	.sp-title { font-size: 17px; }
	.sp-header { padding: 12px 14px 8px; }
	.sp-content { padding: 14px; font-size: 14px; }
	.sp-meta { font-size: 12px; gap: 4px 10px; }
	.sp-tags { padding: 10px 14px; }
	.sp-nav { flex-direction: column; gap: 8px; }
	.sp-related-grid { grid-template-columns: 1fr 1fr; gap: 8px; }
	.sp-related-thumb { height: 80px; }
	.sp-related-item h4 { font-size: 12px; margin: 6px 8px 3px; }
	.sp-related-date { margin: 0 8px 6px; }
	.sp-comments { padding: 14px; }

	.pg-title { font-size: 17px; }
	.pg-header { padding: 12px 14px 10px; }
	.pg-content { padding: 14px; font-size: 14px; }

	.ar-item { gap: 10px; padding: 10px; }
	.ar-thumb { width: 90px; height: 65px; }
	.ar-item-title { font-size: 14px; }
	.ar-excerpt { font-size: 12px; -webkit-line-clamp: 2; }
}
