/* --- BIẾN MÀU VÀ CÀI ĐẶT CƠ BẢN --- */
:root {
    --primary-color: #0288d1;
    --primary-dark: #0277bd;
    --secondary: #4fc3f7;
    --accent: #b2ebf2;
    --bg: #f1fafe;
    --text-main: #263238;
    --text-sub: #607d8b;
    --white: #ffffff;
}

* {
  margin: 0;
  padding: 0;
  box-sizing: border-box;
}

body {
    margin: 0;
    font-family: 'Roboto', sans-serif;
    color: var(--text-main);
    font-size: 16px;
}

/* 3. Reset cho các thẻ phổ biến */
h1, h2, h3, h4, h5, h6, p {
  margin: 0;
  font-weight: normal;
}

ul, ol {
    list-style: none;
    padding: 0;
    margin: 0;
    list-style-position: inside;
}

a {
  color: inherit;
  text-decoration: none;
}

/* 4. Ảnh responsive */
img {
  max-width: 100%;
  height: auto;
  display: block;
}

/* 5. Form control */
input, textarea, select, button {
  font: inherit;
  outline: none;
  border: none;
  background: none;
}
img, svg, video, canvas, audio, iframe, embed, object {
    display: block;
    vertical-align: middle;
}

.container {
    width: 100%;
    padding: 0 15px;
    margin: 0 auto;
    box-sizing: border-box;
}

/* --- TIỆN ÍCH CHUNG & RESET --- */

.menu-toggle,
.mobile-nav-close,
.submenu-toggle {
    background: none;
    border: none;
    padding: 0;
    cursor: pointer;
}

/* ------------------------------------------- */
/* --- GIAO DIỆN MOBILE (MOBILE FIRST) --- */
/* ------------------------------------------- */

/* Ẩn các thành phần của desktop trên mobile */
.desktop-only,
.nav-bar,
.mega-menu,
.sub-category-panel,
.hotline-header {
    display: none;
}

/* --- HEADER & SEARCH (MOBILE) --- */
.header-main {
    padding: 10px 0;
}

.header-main .container {
    display: flex;
    flex-wrap: wrap;
    align-items: center;
    row-gap: 10px;
}

.logo {
    order: 1;
    width: 100%;
    text-align: center;
    padding-bottom: 10px;
    position: static;
    transform: none;
}

.logo img {
    height: 100px;
    object-fit: contain;
    display: inline-block;
}

.menu-toggle {
    display: block;
    order: 2;
    color: var(--primary-color);
    font-size: 24px;
}

.search-bar {
    order: 3;
    flex-grow: 1;
    display: flex;
    margin: 0 10px;
    width: 80%;
}

.search-bar input {
    width: 100%;
    padding: 10px 15px;
    border: 1px solid #ddd;
    border-radius: 25px 0 0 25px;
    outline: none;
    font-size: 14px;
}

.search-bar button {
    padding: 0 15px;
    border: none;
    background-color: var(--primary-color);
    color: var(--white);
    border-radius: 0 25px 25px 0;
    cursor: pointer;
    font-size: 16px;
}

/* --- MOBILE NAVIGATION PANEL --- */
.mobile-nav {
    display: flex;
    flex-direction: column;
    position: fixed;
    top: 0;
    left: 0;
    width: 300px;
    height: 100%;
    background-color: var(--white);
    z-index: 1002;
    transform: translateX(-100%);
    transition: transform 0.3s ease-in-out, opacity 0.3s ease-in-out;
    visibility: hidden;
    opacity: 0;
}

.mobile-nav-overlay {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background-color: rgba(0, 0, 0, 0.5);
    z-index: 1001;
    visibility: hidden;
    opacity: 0;
    transition: opacity 0.3s ease-in-out, visibility 0.3s ease-in-out;
}

/* Lớp .active để hiển thị menu mobile */
.mobile-nav.active {
    transform: translateX(0);
    visibility: visible;
    opacity: 1;
}

.mobile-nav-overlay.active {
    visibility: visible;
    opacity: 1;
}

.mobile-nav-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 15px;
    background-color: var(--primary-color);
    color: var(--white);
    flex-shrink: 0;
    border-bottom: 1px solid #eee;
}

.mobile-nav-header p {
    margin: 0;
    font-weight: bold;
    font-size: 18px;
    color: var(--white);
}

.mobile-nav-close {
    font-size: 28px;
    color: var(--white);
}

.mobile-nav-body {
    overflow-y: auto;
    flex-grow: 1;
}

.mobile-menu li {
    border-bottom: 1px solid #f0f0f0;
    position: relative;
    display: flex;
    align-items: center;
}

.mobile-menu li.has-submenu {
    flex-wrap: wrap;
}

.mobile-menu a {
    padding: 15px 35px 15px 15px;
    color: #333;
    font-size: 15px;
    text-transform: uppercase;
    display: block;
    border-bottom: none;
}

.mobile-menu li.has-submenu > a {
    flex-grow: 1;
}

.mobile-menu a i {
    margin-right: 5px;
    width: 20px;
    color: #555;
}

.submenu-toggle {
    padding: 15px;
    font-size: 14px;
    color: #888;
    position: absolute;
    top: 0;
    right: 5px;
}

.submenu-toggle i {
    transition: transform 0.3s;
}

/* Style khi mở submenu */
.mobile-menu li.has-submenu.open > a {
    color: var(--primary-color);
    font-weight: bold;
}

.mobile-menu li.has-submenu.open > .submenu-toggle i {
    transform: rotate(180deg);
}

.mobile-menu .submenu {
    background-color: #f8f9fa;
    max-height: 0;
    overflow: hidden;
    transition: max-height 0.4s ease-in-out;
    width: 100%;
    list-style: none;
    padding-left: 0;
}

.mobile-menu .has-submenu.open > .submenu {
    max-height: 1000px;
}

/* Phân cấp thụt lề */
.mobile-menu .submenu a {
    padding-left: 20px;
}

.mobile-menu .submenu .submenu a {
    padding-left: 35px;
    width: 100%;
}
/* =========================================== */
/* === CSS FOR SLICK SLIDER (BANNER) === */
/* =========================================== */
.hero-slider-wrapper {
    position: relative;
    width: 100%;
}

.hero-slider .slide img {
    width: 100%;
    display: block;
}
/* =========================================== */
/* === MỚI: DANH MỤC SẢN PHẨM SLIDER (HOME) === */
/* =========================================== */
.home-categories-section {
    background-color: var(--white);
    padding: 20px 0;
    margin-top: 20px;
}

.home-categories-section .container {
    display: block; /* Ghi đè display:flex của container chung */
}

.section-title {
    margin-bottom: 20px;
    position: relative;
    display: flex;
    align-items: center;
    justify-content: space-between;
}

.section-title h2 {
    margin: 0;
    font-size: 16px;
    text-transform: uppercase;
    color: var(--white);
    background-color: var(--primary-color);
    padding: 8px 20px;
    border-radius: 5px;
    position: relative;
    z-index: 1;
}

/* Hiệu ứng mũi tên cho tiêu đề */
.section-title h2::after {
    content: '';
    position: absolute;
    top: 50%;
    right: -8px;
    transform: translateY(-50%) rotate(45deg);
    width: 16px;
    height: 16px;
    background-color: var(--primary-color);
    z-index: -1;
}
/* Tạo khoảng trống cho mỗi slide */
.category-slider .slick-slide {
    margin: 0 10px;
}

/* Bù lại khoảng trống thừa ở hai đầu của slider */
.category-slider .slick-list {
    margin: 0 -10px;
}

.category-item {
    padding: 0 8px; /* Khoảng cách giữa các mục */
    text-align: center;
}

.category-image {
    width: 100%;
    margin-bottom: 10px;
    /*border: 1px solid var(--primary-color);
    border-radius: 15px;*/
    background-color: #eee;
    padding: 7px;
    clip-path: polygon(0 0, calc(100% - 20px) 0, 100% 20px, 100% 100%, 20px 100%, 0 calc(100% - 20px));
    -webkit-clip-path: polygon(0 0, calc(100% - 20px) 0, 100% 20px, 100% 100%, 20px 100%, 0 calc(100% - 20px));
    transition: clip-path 0.4s ease-in-out, -webkit-clip-path 0.4s ease-in-out;
}
.category-image:hover{
    clip-path: polygon(0 0, 100% 0, 100% 100%, 100% 100%, 0 100%, 0 100%);
    -webkit-clip-path: polygon(0 0, 100% 0, 100% 100%, 100% 100%, 0 100%, 0 100%);
    background-color: var(--secondary);
}

.category-image img {
    width: 100%;
    object-fit: contain;
    transition: box-shadow 0.3s, transform 0.3s;

}

.category-item a:hover > .category-image img{
    transform: scale(1.05);

}

.category-name {
    font-size: 12px;
    color: var(--text-main);
    margin: 0;
    text-align: center;
}
/* =========================================== */
/* === MỚI: KHU VỰC SẢN PHẨM (HOME) === */
/* =========================================== */
.product-section {
    padding: 20px 0;
}

.product-section .container {
    display: block;
   /* background-color: var(--white);
    border-radius: 8px;
    box-shadow: 0 2px 10px rgba(0,0,0,0.05);*/
}

.product-section-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 20px;
    border-bottom: 2px solid var(--primary-color);
    padding-bottom: 10px;
    gap:5px;
}

.product-section-header h3 {
    margin: 0;
    font-size: 16px;
    text-transform: uppercase;
    color: var(--text-main);
}

.view-all-link {
    font-size: 13px;
    color: var(--primary-color);
    font-weight: bold;
    white-space: nowrap;
    text-transform: uppercase;
}
.view-all-link i {
    margin-left: 5px;
}

.product-grid {
    display: grid;
    grid-template-columns: repeat(2, 1fr);
    gap: 10px;
}
.product-card:hover{
   -webkit-box-shadow: 0 1px 8px rgba(0, 0, 0, 0.25);
    box-shadow: 0 1px 8px rgba(0, 0, 0, 0.25);
}
.product-card:hover .product-card-image img {
    transform: scale(1.05);
    color: var(--primary-color)
}
.product-card {
    position: relative;
    border-radius: 4px;
    overflow: hidden;
    background-color: var(--white);
    border: solid 1px #f1f3f6;
}

@keyframes pulse {
  50% {
    opacity: 0.5;
  }
}

.hot-badge {
    position: absolute;
    left: 0.25rem; /* left-1 */
    top: 0.75rem; /* top-3 */
    z-index: 1; /* z-[1] */
    transform: translateX(-33.33%) translateY(-33.33%) rotate(-40deg); /* -translate-x-1/3 -translate-y-1/3 -rotate-[40deg] */
    animation: pulse 2s cubic-bezier(0.4, 0, 0.6, 1) infinite; /* animate-pulse */
    background-color: rgb(185 28 28); /* bg-red-700 */
    color: rgb(255 255 255); /* text-white */
    font-size: 0.875rem; /* text-sm */
    line-height: 1.25rem;
    padding-left: 2rem; /* px-8 */
    padding-right: 2rem; /* px-8 */
}

/* Class cho chữ "HOT" bên trong */
.hot-badge .hot-text {
    font-weight: 500; /* font-medium */
    color: rgb(254 240 138); /* text-yellow-200 */
    text-shadow: 0 1px 2px rgb(0 0 0 / 0.1), 0 1px 1px rgb(0 0 0 / 0.06); /* shadow-sm */
}

.product-card-image {
    position: relative;
    width: 100%;
}

.product-card-image img {
    width: 100%;
    display: block;
    aspect-ratio: 1 / 1;
    object-fit: contain;
    padding: 10px;
    box-sizing: border-box;
    transform: none;
    transition: transform 0.3s ease, opacity 0.3s ease, color 0.3s ease;
}

.discount-badge {
    background: #FFDCD9;
    border-radius: 3px;
    font-weight: 600;
    color: var(--text-main);
    padding: 2px 5px;
    font-size: 10px;
}

.product-card-content {
    padding: 10px;
    position: relative;
    min-height: 120px;
    box-sizing: border-box;
}

.product-name {
    font-size: 14px;
    line-height: 1.4;
    font-weight: 600;
    color: var(--primary-color);
    margin: 0;
    display: -webkit-box;
    -webkit-line-clamp: 3;
    -webkit-box-orient: vertical;
    overflow: hidden;
    text-overflow: ellipsis;
}

.product-price {
    margin: 0px 0 15px;
    display: -webkit-box;
    display: -ms-flexbox;
    display: flex;
    -ms-flex-wrap: wrap;
    flex-wrap: wrap;
    -webkit-box-align: center;
    -ms-flex-align: center;
    align-items: center;
    position: absolute;
    bottom: 0;
}

.sale-price {
    color: #d32f2f;
    width: 100%;
    font-weight: 700;
    font-size: 16px;
}

.original-price {
    text-decoration: line-through;
    margin: 0 10px 0 0;
    font-size: 13px;
    color: #999;
}

/* =========================================== */
/* === MỚI: KHU VỰC BÀI VIẾT (HOME) === */
/* =========================================== */
.post-section {
    padding: 20px 0;
}
.post-section .container {
    display: block;
    padding: 15px;
    /*background-color: var(--white);
    border-radius: 8px;
    box-shadow: 0 2px 10px rgba(0,0,0,0.05);*/
}

.post-section .product-section-header h3{
    position: relative;
}

.post-section .product-section-header{
    display: block;
}

.post-section .product-section-header .view-all-link{
    position: absolute;
    right: 0;
    bottom: 0;
}

.post-grid {
    display: grid;
    grid-template-columns: 1fr; /* 1 cột trên mobile */
    gap: 15px;
}

.post-card {
    display: flex;
    gap: 15px;
   -webkit-box-shadow: inset 1px 0px 0px #EDEDED, inset -1px 0px 0px #EDEDED, inset 0px 1px 0px #EDEDED, inset 0px -1px 0px #EDEDED;
    box-shadow: inset 1px 0px 0px #EDEDED, inset -1px 0px 0px #EDEDED, inset 0px 1px 0px #EDEDED, inset 0px -1px 0px #EDEDED;
    border-radius: 12px;
    overflow: hidden;
    transition: box-shadow 0.3s;
}

.post-card:hover {
    box-shadow: 0 4px 15px rgba(0,0,0,0.1);
}

.post-card-image {
    flex-shrink: 0;
    width: 120px;
    height: 90px;
}

.post-card-image img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    border-radius: 12px;
}

.post-card-content {
    flex-grow: 1;
    padding: 10px 8px 8px 0;
}

.post-meta {
    font-size: 12px;
    color: var(--text-sub);
    margin-bottom: 8px;
}

.post-meta span {
    margin-right: 15px;
}

.post-meta i {
    margin-right: 4px;
}

.post-title {
    margin: 0;
    font-size: 14px;
    line-height: 1.4;
}

.post-title a {
    color: var(--text-main);
    display: -webkit-box;
    -webkit-line-clamp: 2;
    -webkit-box-orient: vertical;
    overflow: hidden;
    text-overflow: ellipsis;
    font-weight: bold;
}

.post-title a:hover {
    color: var(--primary-color);
}
/* =========================================== */
/* === MỚI: KHU VỰC VIDEOS (HOME) === */
/* =========================================== */
.video-section {
    padding: 20px 0;
    background-color: #f9f9f9;
}
.video-section .container{
    display: block;
    padding: 15px;
}
.video-grid {
    display: grid;
    grid-template-columns: repeat(2, 1fr);
    gap: 20px;
}
@media (min-width: 768px) {
    .video-grid {
        grid-template-columns: repeat(3, 1fr);
    }
}
.video-item {
    cursor: pointer;
    transition: transform 0.3s ease;
}
.video-item:hover {
    transform: translateY(-5px);
}
.video-thumbnail-wrapper {
    position: relative;
    border-radius: 8px;
    overflow: hidden;
    aspect-ratio: 16/9;
}
.video-thumbnail-wrapper img {
    width: 100%;
    height: 100%;
    object-fit: cover;
}
.play-button {
    position: absolute;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%);
    width: 50px;
    height: 50px;
    background-color: rgba(0,0,0,0.6);
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    color: #fff;
    font-size: 20px;
    border: 2px solid #fff;
    transition: background-color 0.3s;
}
.video-item:hover .play-button {
    background-color: #ff0000;
    border-color: #ff0000;
}
.video-title {
    margin-top: 10px;
    font-size: 16px;
    font-weight: 600;
    line-height: 1.4;
    color: #333;
    display: -webkit-box;
    -webkit-line-clamp: 2;
    -webkit-box-orient: vertical;
    overflow: hidden;
}

/* Video Modal CSS */
.video-modal {
    display: none;
    position: fixed;
    z-index: 9999;
    left: 0;
    top: 0;
    width: 100%;
    height: 100%;
    overflow: auto;
    background-color: rgba(0,0,0,0.9);
    align-items: center;
    justify-content: center;
}
.video-modal-content {
    position: relative;
    width: 90%;
    max-width: 900px;
    background-color: #000;
    border-radius: 8px;
    box-shadow: 0 5px 15px rgba(0,0,0,0.5);
}
.close-video-modal {
    position: absolute;
    top: -35px;
    right: 0;
    color: #fff;
    font-size: 35px;
    font-weight: bold;
    cursor: pointer;
    z-index: 10000;
}
.iframe-container {
    position: relative;
    width: 100%;
    padding-bottom: 56.25%; /* 16:9 Aspect Ratio */
    height: 0;
}
.iframe-container iframe {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
}
/* =========================================== */
/* === MỚI: PARTNER SLIDER (FOOTER) === */
/* =========================================== */
.partner-section {
    padding: 20px 0;
    background-color: var(--white);
}

.partner-section .container {
    display: block;
}

.partner-slider-wrapper {
    position: relative;
}

.partner-item {
    padding: 0 5px;
}

.partner-item a {
    display: flex;
    align-items: center;
    justify-content: center;
    border-radius: 8px;
    padding: 5px;
    box-sizing: border-box;
    position: relative;
    transition: box-shadow 0.3s;
}

.partner-item a::before {
    content: "";
    position: absolute;
    top: 0;
    left: -15%;
    bottom: 0;
    width: 0;
    height: 100%;
    background-color: rgba(255, 255, 255, 0.5);
    -webkit-transition: none;
    transition: none;
    -webkit-transform: skewX(-25deg);
    transform: skewX(-25deg);
}

.partner-item a:hover::before {
    width: 120%;
    background-color: rgba(255, 255, 255, 0);
    -webkit-transition: all .45s ease-out;
    transition: all .45s ease-out;
    z-index: 2;
}

.partner-item img {
    max-width: 100%;
    max-height: 100%;
    object-fit: contain;
}

.partner-item a:hover img {
    filter: grayscale(0%);
    opacity: 1;
}

.slider-arrow {
    position: absolute;
    top: 50%;
    transform: translateY(-50%);
    background-color: #e0e0e0;
    border: none;
    width: 30px;
    height: 30px;
    border-radius: 50%;
    cursor: pointer;
    z-index: 10;
    font-size: 16px;
    color: #888;
    display: flex;
    align-items: center;
    justify-content: center;
    transition: background-color 0.2s, color 0.2s;
}

.slider-arrow:hover {
    background-color: var(--primary-color);
    color: var(--white);
}

.partner-prev {
    left: -15px;
}

.partner-next {
    right: -15px;
}

/* Mặc định ẩn mũi tên của slider đối tác trên mobile */
.slider-arrow.partner-prev,
.slider-arrow.partner-next {
    display: none;
}

/* =========================================== */
/* === FOOTER SUBSCRIBE BAR === */
/* =========================================== */
.footer-subscribe-bar {
    background-color: var(--primary-color);
    color: var(--white);
    padding: 20px 0;
}

.footer-subscribe-bar .container {
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 20px;
}

.subscribe-content {
    text-align: center;
}

.subscribe-content p {
    margin: 0 0 15px 0;
    font-size: 16px;
    font-weight: bold;
}

.social-icons {
    display: flex;
    justify-content: center;
    gap: 15px;
}

.social-icons a {
    display: flex;
    align-items: center;
    justify-content: center;
    width: 40px;
    height: 40px;
    transition: transform 0.2s;
}

.social-icons a:hover {
    transform: scale(1.1);
}

.custom-icon {
    font-size: 30px;
}

.subscribe-form-wrapper {
    width: 100%;
    max-width: 350px;
}

#footer-consultation-form {
    display: flex;
}

#footer-consultation-form input {
    flex-grow: 1;
    border: 1px solid var(--white);
    background-color: var(--white);
    padding: 10px 15px;
    border-radius: 5px 0 0 5px;
    outline: none;
    font-size: 14px;
}

#footer-consultation-form button {
    border: 1px solid var(--white);
    background-color: transparent;
    color: var(--white);
    font-weight: bold;
    padding: 10px 20px;
    border-radius: 0 5px 5px 0;
    cursor: pointer;
    transition: background-color 0.2s, color 0.2s;
}

#footer-consultation-form button:hover {
    background-color: var(--primary-dark);
    color: var(--white);
}

.form-message {
    margin-top: 5px;
    font-size: 13px;
    text-align: center;
    font-weight: bold;
    height: 15px; /* Giữ không gian để không bị giật layout */
}
.form-message.success {
    color: var(--white); /* Light green */
}
.form-message.error {
    color: #ef9a9a; /* Light red */
}

/* =========================================== */
/* === MAIN FOOTER === */
/* =========================================== */
.main-footer {
    background-color: #f8f9fa;
    padding-top: 30px;
    color: var(--text-main);
    font-size: 14px;
}

.main-footer .container {
    display: block;
}

.footer-grid {
    display: grid;
    grid-template-columns: 1fr; /* 1 cột trên mobile */
    gap: 20px;
}

.footer-title {
    font-size: 14px;
    font-weight: bold;
    color: var(--text-main);
    margin-top: 0;
    margin-bottom: 15px;
    text-transform: uppercase;
}

.contact-info li {
    display: flex;
    align-items: flex-start;
    margin-bottom: 10px;
}
.contact-info li span{
    text-align: justify;
}
.contact-info i {
    margin-right: 10px;
    margin-top: 2px;
    width: 15px;
    text-align: center;
    color: var(--primary-color);
}
.contact-info li a{
    color: var(--primary-color);
    margin-left: 3px;
}
.footer-links li {
    margin-bottom: 8px;
}
.footer-links a {
    transition: color 0.2s;
}
.footer-links a:hover {
    color: var(--primary-color);
}

.footer-map, .footer-fanpage {
    margin-bottom: 15px;
}
.footer-map iframe, .footer-fanpage iframe {
    width: 100%;
    height: 150px;
    border: none;
    border-radius: 5px;
}

/* SỬA ĐỔI: CSS CHO SUB-FOOTER */
.sub-footer {
    background-color: #f1f1f1;
    padding: 20px 0;
    font-size: 13px;
    color: #555;
}
.sub-footer .container {
    display: flex;
    flex-direction: column;
    align-items: center;
    text-align: center;
    gap: 20px;
}
.sub-footer-left {
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 15px;
}
.footer-logo img {
    max-height: 100px;
}
.footer-info-text p {
    margin: 5px 0;
    line-height: 1.6;
}
.sub-footer-right img {
    max-height: 60px;
}

/* =========================================== */
/* === MỚI: TRANG DANH MỤC TIN TỨC === */
/* =========================================== */
.page-container {
    padding-top: 20px;
    padding-bottom: 20px;
    display: block;
}
.breadcrumb-nav {
    margin-bottom: 20px;
}
.breadcrumb {
    display: ruby;
    padding: 0;
    margin: 0;
    list-style: none;
    font-size: 14px;
}
.breadcrumb-item + .breadcrumb-item::before {
    font-family: "Font Awesome 5 Free";
    content: "\f105";
    font-weight: 900;
    padding: 0 8px;
    color: var(--primary-color);
}
.breadcrumb-item.home{
    color: var(--primary-color);
}
.breadcrumb-item a:hover{
    color: var(--primary-color);
    font-weight: bold;
}
.breadcrumb-item.active {
    color: #6c757d;
}
.page-title-wrapper {
    text-align: center;
    margin-bottom: 30px;
}
.page-title {
    color: var(--primary-color);
    font-size: 24px;
    margin: 0 0 10px 0;
    text-transform: uppercase;
}
.page-subtitle {
    font-size: 15px;
    color: var(--text-sub);
    margin: 0;
}
.posts-grid-container {
    display: grid;
    grid-template-columns: 1fr; /* 1 cột mobile */
    gap: 20px;
}
.post-card-large {
    background-color: var(--white);
    border-radius: 8px;
    box-shadow: 0 2px 8px rgba(0,0,0,0.08);
    overflow: hidden;
    transition: transform 0.3s, box-shadow 0.3s;
}
.post-card-large:hover {
    transform: translateY(-5px);
    box-shadow: 0 5px 15px rgba(0,0,0,0.12);
}
.post-card-large-image {
    display: block;
    position: relative;
}
.post-card-large-image img {
    width: 100%;
    height: 200px;
    object-fit: cover;
    display: block;
}
.post-date-badge {
    position: absolute;
    top: 15px;
    left: 15px;
    background-color: var(--primary-color);
    color: var(--white);
    border-radius: 5px;
    text-align: center;
    padding: 5px 0;
    width: 45px;
    font-weight: bold;
}
.post-date-badge .day {
    display: block;
    font-size: 20px;
    line-height: 1;
}
.post-date-badge .month {
    display: block;
    font-size: 12px;
    text-transform: uppercase;
}
.post-card-large-content {
    padding: 15px;
}
.post-title-large {
    margin: 0 0 10px 0;
    font-size: 16px;
}
.post-title-large a {
    color: var(--primary-color);
}
.post-excerpt {
    font-size: 14px;
    color: var(--text-sub);
    line-height: 1.6;
    margin: 0 0 15px 0;
}
.post-meta-large {
    font-size: 12px;
    color: var(--text-sub);
}
.post-meta-large span {
    margin-right: 15px;
}
.post-meta-large i {
    margin-right: 5px;
}

/* Phân trang */
.pagination-wrapper {
    margin-top: 30px;
}
.pagination {
    display: flex;
    justify-content: center;
    padding-left: 0;
    list-style: none;
}
.page-item .page-link {
    position: relative;
    display: block;
    padding: 8px 12px;
    margin-left: -1px;
    line-height: 1.25;
    color: var(--primary-color);
    background-color: #fff;
    border: 1px solid #dee2e6;
    transition: all 0.2s;
}
.page-item:first-child .page-link {
    border-top-left-radius: .25rem;
    border-bottom-left-radius: .25rem;
}
.page-item:last-child .page-link {
    border-top-right-radius: .25rem;
    border-bottom-right-radius: .25rem;
}
.page-item.active .page-link {
    z-index: 3;
    color: #fff;
    background-color: var(--primary-color);
    border-color: var(--primary-color);
}
.page-item:not(.active) .page-link:hover {
    z-index: 2;
    color: var(--primary-dark);
    background-color: #e9ecef;
    border-color: #dee2e6;
}

/* =========================================== */
/* === MỚI: TRANG CHI TIẾT BÀI VIẾT === */
/* =========================================== */
.main-content-grid {
    display: grid;
    grid-template-columns: 1fr; /* 1 cột mobile */
    gap: 30px;
}
.post-header {
    margin-bottom: 20px;
}
.post-detail-title {
    font-size: 22px;
    line-height: 1.2;
    margin: 0 0 10px 0;
    color: var(--primary-color);
}
.post-detail-meta {
    font-size: 13px;
    color: var(--text-sub);
    border-top: 1px solid #eee;
    padding-top: 15px;
}
.post-detail-meta span{
    color: #fba646;
    font-weight: bold;
}
.post-content {
    line-height: 1.7;
    font-size: 16px;
}
.post-content p{
    color: var(--text-main);
    font-size: 16px;
    font-family: Roboto, sans-serif;
    font-weight: 400;
    letter-spacing: 0;
    line-height: 1.5;
    margin-top: 0;
    margin-bottom: 15px;
    text-align: justify;
}
.post-content h2{
    color: var(--primary-color);
    font-family: Roboto, sans-serif;
    font-weight: 600;
    letter-spacing: .05em;
    margin-bottom: 0;
    font-size: 23px;
    line-height: 1.2;
    max-width: 600px;
    text-transform: uppercase;
    text-align: center !important;
    position: relative;
    margin: 0 auto 15px;
    padding-bottom: 20px;
}
.post-content h2:before{
    content: url(../img/sub-single.png);
    position: absolute;
    bottom: 5px;
    left: 0;
    right: 0;
    margin: 0 auto;
}
.post-content h3{
    color: #bb3704;
    letter-spacing: .05em;
    line-height: 1.2;
    text-transform: uppercase;
    text-align: left !important;
    margin-bottom: 15px;
}
.post-content iframe,
.post-content table{
    max-width: 100%;
    margin: 0 auto;
}
.post-content img {
    height: auto !important;
    display: inline-block;
    vertical-align: middle;
}
.post-content p > img:only-child {
    display: block;
    margin: 0 auto;
}
.sidebar-widget{
    display: none;
}

.recent-posts-widget-title{
    background-color: #dfe0e0;
    position: relative;
    margin-left: -15px;
    margin-right: -15px;
}
.recent-posts-widget-title h3{
    background-color: var(--primary-color);
    display: inline-block;
    text-transform: uppercase;
    font-weight: 700;
    color: #fff;
    padding: 10px 20px 10px 45px;
    text-shadow: 1px 2px 3px #000;
}
.recent-posts-widget-title h3::before {
    content: '';
    width: 18px;
    height: 18px;
    background: url(../img/icons.png) -76px -326px no-repeat;
    position: absolute;
    top: 0;
    left: 15px;
    bottom: 0;
    margin: auto;
}
.recent-posts-widget-list{
    display: flex;
    flex-wrap: wrap;
    flex-direction: column;
    gap: 10px;
    margin: 15px 0;
}
.recent-posts-widget-list li{
    width: 100%;
    -webkit-box-shadow: 0px 0px 5px rgb(0 0 0 / 30%);
    box-shadow: 0px 0px 5px rgb(0 0 0 / 30%);
}
.recent-post-image {
    aspect-ratio: 16 / 9;
    width: 100%;
    overflow: hidden;
}
.recent-post-image img {
    width: 100%;
    height: 100%;
    object-fit: cover;
}
.recent-post-title {
    display: -webkit-box;
    -webkit-line-clamp: 2;
    -webkit-box-orient: vertical;
    overflow: hidden;
    text-overflow: ellipsis;
    font-size: 16px;
    font-weight: 500;
    margin: 10px;
    color: var(--primary-color);
    font-weight: bold;
}

/* MỚI: CSS cho khu vực Tags */
.post-tags-wrapper {
    margin-top: 20px;
    padding-top: 20px;
    border-top: 1px solid #eee;
    display: flex;
    align-items: center;
    flex-wrap: wrap;
    gap: 10px;
}
.tags-label {
    font-weight: bold;
    font-size: 15px;
}
.tags-label i {
    margin-right: 5px;
    color: var(--primary-color);
}
.tags-list {
    display: flex;
    flex-wrap: wrap;
    gap: 8px;
}
.post-tag {
    background-color: #e0e0e0;
    color: #333;
    padding: 5px 12px;
    border-radius: 15px;
    font-size: 13px;
    transition: background-color 0.2s, color 0.2s;
}
.post-tag:hover {
    background-color: var(--primary-color);
    color: var(--white);
}

/* ------------------------------------------- */
/* --- CSS CHO DESKTOP (min-width: 1024px) --- */
/* ------------------------------------------- */
@media (min-width: 1024px) {
    /* --- RESET & LAYOUT CHO DESKTOP --- */
    /* Hiển thị các thành phần desktop, ẩn của mobile */
    .desktop-only,
    .nav-bar,
    .hotline-header {
        display: flex;
    }

    .menu-toggle,
    .mobile-only {
        display: none;
    }

    /* Đảm bảo nav mobile ẩn hoàn toàn trên desktop */
    .mobile-nav,
    .mobile-nav-overlay {
        display: none !important;
    }

    .container {
        max-width: 1240px;
        display: flex;
        align-items: center;
        flex-wrap: nowrap;
        gap: 10px;
    }

    /* --- HEADER (DESKTOP) --- */
    .header-main {
        padding: 20px 0;
        border-bottom: 1px solid #e0e0e0;
    }

    .logo {
        order: 0;
        width: auto;
        padding-bottom: 0;
    }

    .search-bar {
        order: 0;
        margin: 0 40px;
        width: auto;
    }

    .search-bar input {
        padding: 12px 15px;
    }

    .search-bar button {
        padding: 0 20px;
        font-size: 18px;
    }

    .hotline-header {
        display: inline-block;
        padding-left: 55px;
        background-image: url(../img/hotline.png);
        background-repeat: no-repeat;
        background-position: 0px;
        height: 46px;
    }

    .hotline-header p {
        margin-top: 5px;
        margin-bottom: 0px;
        text-transform: capitalize;
    }

    .hotline-header span {
        font-weight: bold;
        color: var(--primary-color);
        font-size: 18px;
        display: block;
    }

    /* --- NAVIGATION BAR & MEGA MENU (DESKTOP) --- */
    .nav-bar {
        background-color: var(--primary-color);
        align-items: center;
        min-height: 55px;
    }

    .nav-bar .container {
        gap: 100px;
    }

    .nav-links {
        display: flex;
        align-items: center;
        gap: 40px;
    }

    .nav-links a {
        color: var(--white);
        text-transform: uppercase;
        font-weight: bold;
        font-size: 14px;
    }

    .nav-links a:hover {
        color: var(--text-main)
    }

    .nav-links i {
        margin-right: 8px;
        color: #555;
    }

    .category-menu-container {
        position: relative;
    }

    .category-button {
        background-color: var(--primary-dark);
        color: var(--white);
        padding: 12px 15px;
        border: none;
        border-radius: 5px;
        font-weight: bold;
        display: flex;
        align-items: center;
        gap: 8px;
        cursor: pointer;
    }

    .category-button i {
        margin-right: 8px;
    }

    .category-menu-container:hover .mega-menu {
        display: flex;
    }

    .mega-menu {
        display: none;
        position: absolute;
        top: 100%;
        left: 0;
        width: max-content;
        max-width: calc(100vw - 50px);
        background-color: var(--white);
        color: #333;
        border: 1px solid #ddd;
        box-shadow: 0 4px 12px rgba(0, 0, 0, 0.15);
        border-top-right-radius: 10px;
        border-bottom-right-radius: 10px;
        z-index: 1000;
    }

    .mega-menu-col-1 {
        width: 250px;
        background-color: #f8f9fa;
        border-right: 1px solid #e9ecef;
        overflow-y: auto;
    }

    .main-category-list > li > a {
        display: flex;
        align-items: center;
        padding: 12px 15px;
        font-size: 14px;
        color: #495057;
        border-bottom: 1px solid #e9ecef;
        transition: background-color 0.2s, color 0.2s;
    }

    .main-category-list > li > a i {
        width: 20px;
        margin-right: 10px;
        color: #6c757d;
    }

    .main-category-list > li > a:hover,
    .main-category-list > li.active > a {
        background-color: var(--white);
        color: var(--primary-color);
        font-weight: bold;
    }

    .main-category-list > li > a .fa-chevron-right {
        margin-left: auto;
        font-size: 0.7em;
    }

    .mega-menu-col-2 {
        flex-grow: 1;
        position: relative;
        overflow-y: auto;
        padding-top: 10px;
        max-height: 450px;
    }

    .sub-category-panel {
      display: none;
    }
    
    .sub-category-panel.active {
        display: block;
    }

    .panel-content {
        display: flex;
        flex-direction: row; 
        flex-wrap: wrap; 
        align-items: flex-start; 
        box-sizing: border-box;
        max-width: 1024px;
    }

    .menu-column {
        width: 250px;
        box-sizing: border-box;
        margin-bottom: 20px;
        flex-shrink: 0;
    }

    .column-title {
        font-weight: bold;
        color: var(--primary-color);
        font-size: 14px;
        margin-bottom: 10px;
        display: block;
        padding-left: 15px;
    }

    .sub-category-list li a {
        display: block;
        padding: 10px 15px;
        color: #6c757d;
        font-size: 14px;
        transition: color 0.2s;
    }

    .sub-category-list li a:hover {
        color: var(--primary-color);
    }

    .panel-content-simple {
        min-width: 250px;
    }

    .sub-category-list-simple li a {
        display: block;
        padding: 10px 15px;
        font-size: 14px;
        color: #333;
        transition: color 0.2s;
    }

    .sub-category-list-simple li:last-child a {
        border-bottom: none;
    }

    .sub-category-list-simple li a:hover {
        background-color: rgb(0 0 0 / .03);
    }

    /* Scrollbar Style */
    .mega-menu-col-2::-webkit-scrollbar {
        width: 6px;
    }

    .mega-menu-col-2::-webkit-scrollbar-track {
        background: #f1f1f1;
    }

    .mega-menu-col-2::-webkit-scrollbar-thumb {
        background: #ccc;
        border-radius: 6px;
    }

    .mega-menu-col-2::-webkit-scrollbar-thumb:hover {
        background: #aaa;
    }
    /* --- HERO SLIDER (DESKTOP) --- */
    /* Tùy chỉnh mũi tên */
    .hero-slider .slick-arrow {
        position: absolute;
        top: 50%;
        transform: translateY(-50%);
        color: white;
        border: none;
        padding: 15px;
        cursor: pointer;
        font-size: 24px;
        z-index: 10;
        border-radius: 50%;
        width: 50px;
        height: 50px;
        display: flex;
        align-items: center;
        justify-content: center;
        transition: background-color 0.2s;
    }
    .hero-slider .slick-prev:before,
    .hero-slider .slick-next:before {
        content: ''; /* Ẩn mũi tên mặc định của Slick */
    }
    .hero-slider .slick-prev {
        left: 20px;
    }
    .hero-slider .slick-next {
        right: 20px;
    }
    .hero-slider .slick-dots {
        bottom: 20px;
    }
    .hero-slider .slick-dots li button {
        width: 12px;
        height: 12px;
    }
    .slick-prev:hover, .slick-prev:focus, 
    .slick-next:hover, .slick-next:focus{
        color: var(--primary-color) !important;
    }
    /* --- CATEGORY SLIDER (DESKTOP) --- */
    .home-categories-section .container {
        max-width: 1200px;
    }
    .section-title h2 {
        font-size: 20px;
    }
    .category-image img {
        height: 120px;
    }
    .category-name {
        font-size: 14px;
    }
    /* --- PRODUCT SECTION (DESKTOP) --- */
    .product-section-header{
        justify-content: center;
        border: none;
        position: relative;
        margin-bottom: 40px;
    }
    .product-section-header h3 {
        font-size: 30px;
        display: inline-block;
        padding-bottom: 15px;
        border-bottom: 1px solid #F5F5F5;
        position: relative;
        line-height: 1.3;
    }
     .product-section-header h3::after {
        content: '';
        width: 110px;
        height: 1px;
        background-color: var(--primary-color);
        position: absolute;
        left: 50%;
        bottom: -1px;
        -webkit-transform: translateX(-50%);
        transform: translateX(-50%);
    }
    .view-all-link {
        font-size: 16px;
        position: absolute;
        right: 0;
        bottom: -20px;
    }
    .product-grid {
        grid-template-columns: repeat(5, 1fr);
        gap: 15px;
    }
    /* Ẩn sản phẩm thứ 6 trở đi trên desktop */
    .product-section .product-grid .product-for-cate:nth-child(n+6) {
        display: none;
    }
    .product-card{
        -webkit-box-shadow: 0 1px 8px rgba(0, 0, 0, 0.25);
        box-shadow: 0 1px 8px rgba(0, 0, 0, 0.25);
    }
    .product-card-content {
        padding: 5px 10px 15px 10px;
    }
    .product-name{
        font-size: 15px;
    }
    .original-price{
        font-size: 14px;
    }
    .discount-badge{
        font-size: 11px;
    }
    /* --- POST SECTION (DESKTOP) --- */
    .post-section .product-section-header{
        padding-bottom: 15px;
        display: -webkit-box;
        display: -ms-flexbox;
        display: flex;
        -webkit-box-align: baseline;
        -ms-flex-align: baseline;
        align-items: baseline;
        -webkit-box-pack: center;
        -ms-flex-pack: center;
        justify-content: center;
        max-width: 630px;
        margin: auto auto 20px;
        position: relative;
        border-bottom: 1px solid #F5F5F5;
        text-transform: uppercase;
    }
    .post-section .product-section-header h3{
        border: 0;
        padding-bottom: 0;
    }
    .post-section .product-section-header h3::after {
        all: unset;
    }
    .post-section .product-section-header::after {
        content: '';
        width: 110px;
        height: 1px;
        background-color: var(--primary-color);
        position: absolute;
        left: 50%;
        bottom: -1px;
        -webkit-transform: translateX(-50%);
        transform: translateX(-50%);
    }
    .post-section .product-section-header .view-all-link{
        all: unset;
        font-size: 16px;
        font-weight: 400;
        margin-left: 15px;
        cursor: pointer;
    }
    .post-section .product-section-header .view-all-link:hover{
        color: var(--primary-color);
    }
    .post-grid {
        grid-template-columns: repeat(2, 1fr); /* 2 cột trên desktop */
        gap: 20px;
    }
    .post-card{
        -webkit-box-shadow: 0 1px 8px rgba(0, 0, 0, 0.25);
        box-shadow: 0 1px 8px rgba(0, 0, 0, 0.25);
    }
    .post-card-image {
        width: 230px;
        height: 150px;
    }
    .post-title {
        font-size: 16px;
    }
    /* --- PARTNER SLIDER (DESKTOP) --- */
    .partner-section .container {
        max-width: 1200px;
    }
    .partner-item {
        padding: 0 8px;
    }
    .partner-prev {
        left: -40px;
    }
    .partner-next {
        right: -40px;
    }
    .slider-arrow.partner-prev,
    .slider-arrow.partner-next {
        display: flex;
    }
    .footer-subscribe-bar .container {
        flex-direction: row;
        justify-content: space-between;
    }
    .subscribe-content {
        text-align: left;
    }
    .subscribe-form-wrapper{
        transform: translateY(20%);
    }
    /* --- FOOTER (DESKTOP) --- */
    .footer-subscribe-bar .container {
        flex-direction: row;
        justify-content: space-between;
    }
    .subscribe-content {
        text-align: left;
    }
    .footer-grid {
        grid-template-columns: 2fr 1fr 1fr 2fr;
        gap: 30px;
    }
    /* --- SUB-FOOTER (DESKTOP) --- */
    .sub-footer .container {
        flex-direction: row;
        justify-content: space-between;
        text-align: left;
    }
    .sub-footer-left {
        flex-direction: row;
        gap: 20px;
    }
    /* --- POST CATEGORY PAGE (DESKTOP) --- */
    .page-container{
        display: block;
    }
    .page-title {
        font-size: 28px;
    }
    .posts-grid-container {
        grid-template-columns: repeat(3, 1fr); /* 3 cột trên desktop */
    }
    /* --- POST DETAIL PAGE (DESKTOP) --- */
    .main-content-grid {
        grid-template-columns: 1fr 300px; /* Cột nội dung linh hoạt, sidebar cố định 300px */
    }
    .post-container{
        border: 1px solid #e0e0e0;
        border-radius: 8px;
        padding: 20px;
    }
    .post-detail-title {
        font-size: 28px;
    }
    .sidebar-widget {
        display: block;
        margin-bottom: 20px;
    }
    .widget-title {
        margin: 0 0 15px 0;
        text-align: center;
        background-image: url(../img/bg_sidebar.jpg);
        background-repeat: no-repeat;
        background-size: cover;
        box-shadow: 0 0 5px 0px rgba(0, 0, 0, .5);
        line-height: 1;
        padding: 30px 0;
        color: var(--white);
        font-size: 20px;
        text-transform: uppercase;
        font-weight: bold;
        display: block;
    }
    .widget-list li a {
        transition: color 0.2s;
        padding: 15px 20px;
        color: var(--text-main);
        border-radius: 5px;
        box-shadow: 0 0 5px 0px rgba(0, 0, 0, .5);
        margin-bottom: 15px;
        display: block;
        text-transform: uppercase;
    }
    .widget-list li a:hover {
        color: var(--white);
        background-color: var(--secondary);
    }
    .widget-list li a:before {
        content: '\f138';
        font-family: 'Font Awesome 5 Free';
        margin-right: 10px;
        color: #00aeef;
        font-weight: 900;
    }
    .widget-list li a:hover:before{
        color: #fff;
    }
    .recent-posts-widget-title{
        margin-left: 0;
        margin-right: 0;
    }
    .recent-posts-widget-list{
        gap: 15px;
    }
}

@font-face {
    font-family: "Font Awesome 5 Free";
    font-style: normal;
    font-weight: 900;
    font-display: swap;
    src: url("https://cdnjs.cloudflare.com/ajax/libs/font-awesome/5.15.4/webfonts/fa-solid-900.woff2") format("woff2");
}

@font-face {
    font-family: "Font Awesome 5 Free";
    font-style: normal;
    font-weight: 400;
    font-display: swap;
    src: url("https://cdnjs.cloudflare.com/ajax/libs/font-awesome/5.15.4/webfonts/fa-regular-400.woff2") format("woff2");
}

@font-face {
    font-family: "Font Awesome 5 Brands";
    font-style: normal;
    font-weight: 400;
    font-display: swap;
    src: url("https://cdnjs.cloudflare.com/ajax/libs/font-awesome/5.15.4/webfonts/fa-brands-400.woff2") format("woff2");
}

