/*

Theme Name: Hokarion Candy Theme

Theme URI: hokarion.com

Author: PHUONG LOAI MOD

Author URI: hokarion.com

Description: This is a custom theme created for my website.

Version: 1.50

License: Hokarion Candy

License URI: hokarion candy

Text Domain: thiet ke boi aragami candy

*/

/* sự sống còn của website và size */
body {

    height: 1000px;

    margin: 0;

    padding: 0;

 }



/* css cho index.php */





/* Khu vực bình luận */

.comments-area {

    margin-top: 40px;

    background-color: #fff;

    padding: 20px;

    border-radius: 8px;

    box-shadow: 0 4px 10px rgba(0, 0, 0, 0.1);

}



/* Tiêu đề bình luận */

.comments-title {

    font-size: 20px;

    margin-bottom: 20px;

    color: #333;

    font-weight: bold;

}



/* Danh sách bình luận */

.comment-list {

    list-style: none;

    padding: 0;

    margin: 0;

}



/* Bình luận cá nhân */

.comment-list .comment {

    margin-bottom: 20px;

    padding: 10px;

    border: 1px solid #ddd;

    border-radius: 8px;

    display: flex;

    gap: 15px;

}



/* Avatar bình luận */

.comment-list .comment-author .avatar {

    border-radius: 50%;

    width: 50px;

    height: 50px;

}



/* Nội dung bình luận */

.comment-list .comment-body {

    flex: 1;

}



.comment-list .comment-author {

    font-weight: bold;

    margin-bottom: 5px;

    color: #0073e6;

}



.comment-list .comment-metadata {

    font-size: 12px;

    color: #999;

    margin-bottom: 10px;

}



.comment-list .comment-content {

    font-size: 14px;

    color: #444;

}



/* Điều hướng bình luận */

.comment-navigation {

    display: flex;

    justify-content: space-between;

    margin-top: 20px;

}



.comment-navigation .nav-previous,

.comment-navigation .nav-next {

    font-size: 14px;

    color: #0073e6;

}



.comment-navigation a:hover {

    text-decoration: underline;

}



/* Form bình luận */

.comment-reply-title {

    font-size: 18px;

    margin-bottom: 20px;

    font-weight: bold;

    color: #333;

}



.comment-form {

    margin-top: 20px;

}



.comment-form label {

    display: block;

    font-size: 14px;

    color: #333;

    margin-bottom: 5px;

}



.comment-form input[type="text"],

.comment-form input[type="email"],

.comment-form textarea {

    width: 100%;

    padding: 10px;

    margin-bottom: 15px;

    border: 1px solid #ddd;

    border-radius: 5px;

    font-size: 14px;

    box-sizing: border-box;

}



.comment-form textarea {

    height: 100px;

    resize: vertical;

}



.comment-form input[type="submit"] {

    background-color: #0073e6;

    color: #fff;

    padding: 10px 20px;

    border: none;

    border-radius: 5px;

    cursor: pointer;

    font-size: 14px;

}



.comment-form input[type="submit"]:hover {

    background-color: #005bb5;

}



/* Responsive */

@media (max-width: 768px) {

    .comment-list .comment {

        flex-direction: column;

        gap: 10px;

    }



    .comment-list .comment-author .avatar {

        width: 40px;

        height: 40px;

    }

}



   /* CSS cho phần giới thiệu */

    .site-intro {

      width: 100%;

      background: linear-gradient(135deg, #4f46e5, #9333ea);

      color: #fff;

      padding: 80px 20px;

      text-align: center;

      display: flex;

      flex-wrap: wrap;

      justify-content: center;

      align-items: center;

      box-sizing: border-box;

    }



    .intro-container {

      max-width: 900px;

      margin: 0 auto;

      padding: 0 15px;

      box-sizing: border-box;

    }



    .intro-title {

      font-size: 2.5rem;

      font-weight: 700;

      margin-bottom: 20px;

      flex: 1 1 100%;

    }



    .intro-text {

      font-size: 1.2rem;

      line-height: 1.6;

      margin-bottom: 30px;

      flex: 1 1 100%;

    }



    .intro-btn {

      display: inline-block;

      background: #fff;

      color: #4f46e5;

      padding: 12px 30px;

      border-radius: 30px;

      font-weight: 600;

      transition: all 0.3s ease;

      text-decoration: none;

      flex: 1 1 auto;

      max-width: 250px;

    }



    .intro-btn:hover {

      background: #f3f4f6;

      color: #9333ea;

    }



    /* Responsive */

    @media (max-width: 468px) {

      .intro-title {

        font-size: 2rem;

        word-wrap: break-word;

      }

      .intro-text {

        font-size: 1rem;

        word-wrap: break-word;

      }

      .intro-btn {

        width: 100%;

        max-width: 100%;

      }

    }











     #intro-time {

  background: #4f46e5;

  color: #fff;

  padding: 20px;

}



    header {

      text-align: center;

      padding: 20px;

    }



    h1 {

      font-size: 2rem;

      margin-bottom: 10px;

    }



    p {

      font-size: 1rem;

      

    }



    .slider {

      max-width: 600px;

      margin: 40px auto;

      overflow: hidden;

      border-radius: 10px;

      box-shadow: 0 4px 10px rgba(0,0,0,0.1);

    }



    .slides {

      display: flex;

      transition: transform 0.5s ease-in-out;

      width: 100%;

    }



    .slide {

      min-width: 100%;

      box-sizing: border-box;

      background: #fff;

      text-align: center;

      padding: 20px;

    }



    .slide img {

      max-width: 100%;

      height: auto;

      border-radius: 10px;

      margin-bottom: 15px;

    }



    .slide h2 {

      font-size: 1.5rem;

      margin-bottom: 10px;

    }



    .slide p {

      font-size: 1rem;

      color: #374151;

    }



  /* nút điều hướng silde trái phải */

  .nav-btn {

  position: absolute;

  top: 50%;

  transform: translateY(-50%);

  background: rgba(0,0,0,0.5);

  color: #fff;

  border: none;

  padding: 10px 15px;

  cursor: pointer;

  font-size: 24px;

  border-radius: 50%;

  transition: background 0.3s ease;

}



.nav-btn:hover {

  background: rgba(0,0,0,0.7);

}



.prev {

  left: 10px;

}



.next {

  right: 10px;

}



.slider {

  position: relative; /* để nút nằm trên slider */

}


/* 404 css */
/* Định dạng tổng quan */

.error-404 {

    text-align: center;

    padding: 50px;

    background-color: #f4f4f4;

    border-radius: 8px;

    box-shadow: 0 4px 8px rgba(0, 0, 0, 0.1);

    margin-top: 100px;

}



.error-404 h1 {

    font-size: 48px;

    color: #ff6347;

    font-family: 'Arial', sans-serif;

    font-weight: bold;

    margin-bottom: 20px;

}



.error-404 p {

    font-size: 18px;

    color: #666;

    font-family: 'Arial', sans-serif;

    margin-bottom: 30px;

}



.error-404 .page-content {

    max-width: 600px;

    margin: 0 auto;

    background-color: #ffffff;

    padding: 20px;

    border-radius: 8px;

    box-shadow: 0 2px 5px rgba(0, 0, 0, 0.1);

}



.error-404 .search-form {

    margin: 20px 0;

}



.error-404 .search-form input[type="search"] {

    padding: 10px;

    font-size: 16px;

    width: 80%;

    max-width: 300px;

    border: 1px solid #ccc;

    border-radius: 4px;

    margin-right: 10px;

}



.error-404 .search-form button {

    padding: 10px 15px;

    font-size: 16px;

    background-color: #ff6347;

    color: #fff;

    border: none;

    border-radius: 4px;

    cursor: pointer;

}



.error-404 .search-form button:hover {

    background-color: #ff4500;

}



/* Các widget gần đây */

.error-404 .widget {

    margin-top: 30px;

}



.error-404 .widget h2 {

    font-size: 24px;

    color: #333;

    font-family: 'Arial', sans-serif;

    margin-bottom: 10px;

}



.error-404 .widget ul {

    list-style: none;

    padding-left: 0;

}



.error-404 .widget ul li {

    margin-bottom: 10px;

}



.error-404 .widget ul li a {

    text-decoration: none;

    color: #0073aa;

    font-size: 16px;

}



.error-404 .widget ul li a:hover {

    color: #ff6347;

}



/* Điều chỉnh cho màn hình nhỏ */

@media (max-width: 600px) {

    .error-404 h1 {

        font-size: 36px;

    }



    .error-404 p {

        font-size: 16px;

    }



    .error-404 .search-form input[type="search"] {

        width: 70%;

    }

}

/* comment */
.comment-list-wrap {

    background: #f9f9f9;

    padding: 20px;

    border-radius: 8px;

    margin-top: 40px;

    box-sizing: border-box;

    max-width: 100%;

    overflow-x: hidden;

}



.comment-list {

    list-style: none;

    padding: 0;

    margin: 0;

}



.comment-list li {

    border-bottom: 1px solid #e0e0e0;

    margin-bottom: 15px;

    padding-bottom: 15px;

    box-sizing: border-box;

    overflow-wrap: break-word;

}



.comment-body {

    display: flex;

    align-items: flex-start;

    gap: 10px;

    word-break: break-word;

}



.comment-author {

    font-weight: 600;

    color: #333;

    font-size: 16px;

    display: flex;

    align-items: center;

    gap: 8px;

}



.comment-author img {

    width: 30px;

    height: 30px;

    border-radius: 50%;

    object-fit: cover;

    flex-shrink: 0;

}



.comment-content {

    color: #555;

    font-size: 15px;

    line-height: 1.6;

    margin-top: 4px;

    word-break: break-word;

    width: 100%;

}



.reply-btn {

    display: inline-block;

    font-size: 13px;

    color: #007bff;

    text-decoration: none;

    cursor: pointer;

    transition: 0.2s;

    margin-top: 5px;

}



.reply-btn:hover {

    text-decoration: underline;

    color: #0056b3;

}



.comment-list .children {

    margin-left: 40px;

    padding-left: 15px;

    border-left: 2px dashed #ddd;

    box-sizing: border-box;

}



.custom-comment-form {

    margin-top: 30px;

    background: #f4f4f4;

    padding: 20px;

    border-radius: 8px;

    box-sizing: border-box;

}



.custom-comment-form textarea {

    width: 100%;

    height: 100px;

    padding: 10px;

    font-size: 15px;

    border: 1px solid #ddd;

    border-radius: 5px;

    resize: vertical;

    box-sizing: border-box;

}



.custom-comment-form button {

    margin-top: 10px;

    padding: 10px 25px;

    background-color: #007bff;

    border: none;

    color: white;

    font-size: 15px;

    border-radius: 5px;

    cursor: pointer;

    transition: 0.3s;

}



.custom-comment-form button:hover {

    background-color: #0056b3;

}







/* Giao diện Swal dành riêng cho bình luận */

.swal2-popup.swal-comment-popup {

  border-radius: 12px !important;

  box-shadow: 0 0 25px rgba(0, 184, 148, 0.4);

}



.swal2-title.swal-comment-title {

  color: #00b894 !important;

  font-weight: 600;

  letter-spacing: 0.5px;

}



.swal2-confirm.swal-comment-confirm {

  background-color: #00b894 !important;

  border: none !important;

}



.swal2-confirm.swal-comment-confirm:hover {

  background-color: #019170 !important;

}



.swal2-cancel.swal-comment-cancel {

  background-color: #d63031 !important;

  border: none !important;

}



.swal2-cancel.swal-comment-cancel:hover {

  background-color: #b71c1c !important;

}

/* footer css */
/* ==========================================================================
   2. FOOTER TỔNG THỂ
   ========================================================================== */
.site-footer {
    background: #1a1a1a;
    color: #eeeeee;
    padding: 50px 20px 20px;
    font-family: system-ui, -apple-system, sans-serif;
}

.footer-top {
    display: flex;
    justify-content: space-between;
    flex-wrap: wrap;
    gap: 30px;
    max-width: 1200px;
    margin: 0 auto 40px;
}

.footer-left { display: flex; align-items: center; gap: 20px; }
.image-bar img { width: 60px; height: 60px; border-radius: 50%; object-fit: cover; }
.footer-about h3 { color: #fff; margin: 0 0 5px; font-size: 22px; }
.footer-about p { color: #bdbdbd; font-size: 14px; margin: 0; max-width: 300px; }

/* Social & DMCA */
.footer-right { text-align: right; }
.footer-right h3 { color: #fff; font-size: 18px; margin-bottom: 15px; }

.social-links.auto-icon {
    display: flex;
    justify-content: flex-end;
    gap: 12px;
    list-style: none !important;
    padding: 0;
}

.social-links.auto-icon a {
    display: flex;
    align-items: center;
    padding: 12px; /* Đích chạm 44px chuẩn Google */
    background: rgba(255,255,255,0.08);
    border-radius: 8px;
    color: #fff;
    text-decoration: none;
    transition: background 0.3s;
}

.social-links.auto-icon a:hover { background: #00aced; }

/* Menu Columns */
.footer-container {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(180px, 1fr));
    gap: 40px;
    max-width: 1200px;
    margin: 0 auto;
    border-top: 1px solid #333;
    padding-top: 40px;
}

.footer-section h3 {
    color: #fff;
    font-size: 17px;
    margin-bottom: 20px;
    text-transform: uppercase;
    letter-spacing: 1px;
}

.footer-menu { list-style: none !important; padding: 0; margin: 0; }
.footer-menu li { margin-bottom: 10px; }

.footer-menu a {
    color: #bbb;
    text-decoration: none;
    display: inline-block;
    padding: 8px 0; /* Tăng vùng bấm dọc */
    font-size: 15px;
    transition: color 0.2s;
}

.footer-menu a:hover { color: #00aced; }

.footer-bottom {
    text-align: center;
    margin-top: 50px;
    padding-top: 20px;
    border-top: 1px solid #333;
    font-size: 13px;
    color: #888;
}

/* Mobile Responsive */
@media (max-width: 768px) {
    .footer-top, .footer-right, .footer-left { 
        flex-direction: column; 
        text-align: center; 
        align-items: center; 
        justify-content: center;
    }
    .social-links.auto-icon { justify-content: center; }
    .footer-menu a { padding: 12px 20px; width: 100%; }
}

 /* header css */
 .submenu {

    list-style-type: none; /* Loại bỏ dấu chấm */

    padding-left: 0; /* Loại bỏ khoảng cách bên trái */

}



.submenu li {

    padding-left: 0; /* Đảm bảo không có lề bên trái */

}



/* Căn chỉnh menu theo left, center, right */

.menu {

    display: flex;

    list-style-type: none;

    margin: 0;

    padding: 0;

    flex-wrap: nowrap; /* Không tự động xuống dòng */

}



/* Căn trái */

.menu.left {

    justify-content: flex-start;

}



/* Căn giữa */

.menu.center {

    justify-content: center;

}



/* Căn phải */

.menu.right {

    justify-content: flex-end;

}



.menu > li {

    position: relative;

    display: inline-block;

}



/* Menu chính không có màu nền, chữ màu đen */

.menu > li > a {

    text-decoration: none;

    color: black;

    padding: 10px 20px;

    display: block;

    background-color: transparent;

    border-radius: 5px;

    font-weight: bold;

    transition: box-shadow 0.3s ease;

    display: flex;

    align-items: center;

}



/* Khi di chuột vào menu chính, thêm viền đen mờ */

.menu > li:hover > a,

.menu > li.active > a {

    box-shadow: 0 0 10px rgba(0, 0, 0, 0.2);

}



.menu > li > a img {

    margin-right: 8px;

    width: 20px;

    height: 20px;

    display: inline-block;

}



/* Submenu ẩn đi mặc định */

.submenu {

    display: none;

    position: absolute;

    top: 100%;

    left: 0;

    background-color: white;

    min-width: 160px;

    box-shadow: 0px 8px 16px rgba(0, 0, 0, 0.2);

    border-radius: 5px;

    z-index: 1000;

}



.submenu li a {

    color: black;

    padding: 12px 16px;

    text-decoration: none;

    display: block;

}



.submenu li a:hover {

    background-color: rgba(0, 0, 0, 0.1);

}



/* Đảm bảo submenu xuất hiện khi di chuột vào ▼ and ▲ */

.menu > li:hover > .submenu {

    display: block;

}



.menu > li > a::after {

    content: ' ▼';

    font-size: 12px;

    margin-left: 5px;

    transition: transform 0.3s ease;

}



.menu > li.active > a::after {

    content: '▼';

    transform: rotate(180deg);

}



.submenu li a::after {

    content: '';

}



/* Căn thẳng hàng cho các menu con theo class .thanghang */

.thanghang.hedieuhanh, .thanghang.taikhoan, .thanghang.games {

    display: flex;

    align-items: center; /* Căn thẳng hàng các mục con trong menu */

}



/* Căn thẳng hàng riêng cho menu "Hệ điều hành" */

.thanghang.hedieuhanh {

    justify-content: flex-start; /* Căn menu Hệ điều hành về bên trái */

}



/* Căn thẳng hàng riêng cho menu "Tài khoản" */

.thanghang.taikhoan {

    justify-content: flex-start; /* Căn menu Tài khoản về bên trái */

}



/* Thêm căn thẳng hàng cho menu "Games" */

.thanghang.games {

    justify-content: flex-start; /* Căn menu Games về bên trái */

}



/* ===== CSS CHO MOBILE MENU ===== */

.mobile-menu-toggle {

    display: none;

    margin-left: 10px;

    cursor: pointer;

}



.mobile-menu {

    display: none;

    background: #fff;

    padding: 15px;

    position: absolute;

    top: 60px;

    left: 0;

    width: 100%;

    z-index: 999;

    box-shadow: 0 2px 8px rgba(0,0,0,0.15);

}



.mobile-menu ul {

    list-style: none;

    padding: 0;

    margin: 0;

}



.mobile-menu ul li {

    padding: 10px 0;

    border-bottom: 1px solid #eee;

}



.mobile-menu ul li a {

    color: black;

    text-decoration: none;

    font-weight: bold;

}



/* ===== RESPONSIVE: ẨN/HIỆN THEO MÀN HÌNH ===== */

@media screen and (max-width: 768px) {

    /* Ẩn toàn bộ menu desktop */

    .menu {

        display: none !important;

    }



    /* Hiện hamburger */

    .mobile-menu-toggle {

        display: block;

    }



    /* Hiện mobile menu khi active */

    .mobile-menu.active {

        display: block;

    }

}





.mobile-menu ul ul {

    margin-left: 15px;

    padding-left: 10px;

    border-left: 2px solid #eee;

}



.mobile-menu strong {

    display: block;

    padding: 10px 0 5px;

    font-size: 16px;

    color: #333;

    border-bottom: 1px solid #ccc;

}



/* search-box*/

.mobile-menu .search-form {

    display: flex;

    flex-direction: column;

    gap: 8px;

    margin-bottom: 15px;

}



.mobile-menu .search-field {

    width: 100%;

    padding: 8px;

    border: 1px solid #ccc;

    border-radius: 5px;

    font-size: 14px;

    box-sizing: border-box;

}



.mobile-menu .search-submit {

    padding: 8px;

    background-color: #0073aa;

    color: white;

    border: none;

    border-radius: 5px;

    font-size: 14px;

    cursor: pointer;

    text-align: center;

}



.mobile-menu .search-submit:hover {

    background-color: #005f8d;

}



/* desktop and other */

/* ================================

   🔍 Quick Search Popup

   Namespace: .quick-search-wrap

   ================================ */



.quick-search-wrap {

  position: relative;

  display: inline-block;

  z-index: 999;

}



/* --- Nút Toggle --- */

#qsToggle {

  display: inline-flex;

  align-items: center;

  justify-content: center;

  background: transparent;

  border: none;

  padding: 6px;

  border-radius: 10px;

  cursor: pointer;

  transition: transform 0.15s ease, box-shadow 0.2s ease;

}



#qsToggle img {

  width: 36px;

  height: 36px;

  display: block;

  filter: drop-shadow(0 0 4px rgba(34,211,238,0.3));

}



#qsToggle:hover,

#qsToggle:focus {

  transform: translateY(-2px) scale(1.05);

  box-shadow: 0 6px 16px rgba(34,211,238,0.15);

  outline: none;

}



/* --- Form popup --- */

.qs-form {

  position: absolute;

  right: 0;

  top: calc(100% + 12px);

  min-width: 280px;

  max-width: 420px;

  border-radius: 14px;

  box-shadow: 0 12px 32px rgba(0, 0, 0, 0.5);

  background: rgba(15, 23, 42, 0.92);

  backdrop-filter: blur(10px);

  transform: translateY(-10px) scale(0.96);

  opacity: 0;

  pointer-events: none;

  transition: all 0.2s ease;

}



/* Khi hiện form */

.qs-form.open,

.qs-form:not([hidden]) {

  transform: translateY(0) scale(1);

  opacity: 1;

  pointer-events: auto;

}



/* --- Bên trong form --- */

.qs-form form {

  display: flex;

  align-items: center;

  gap: 6px;

  padding: 10px;

}



.qs-form input[type="search"] {

  flex: 1;

  border: none;

  background: rgba(255, 255, 255, 0.1);

  color: #e6eef6;

  font-size: 15px;

  border-radius: 8px;

  padding: 8px 10px;

  outline: none;

  transition: background 0.2s ease;

}



.qs-form input::placeholder {

  color: #9aa7b2;

}



.qs-form input:focus {

  background: rgba(255, 255, 255, 0.2);

}



/* --- Nút đóng --- */

#qsClose {

  background: transparent;

  border: none;

  color: #9aa7b2;

  font-size: 20px;

  cursor: pointer;

  padding: 4px;

  transition: color 0.2s ease;

}

#qsClose:hover {

  color: #fff;

}



/* --- Kết quả gợi ý --- */

#searchResults {

  margin: 4px 8px 10px;

  border-top: 1px solid rgba(255, 255, 255, 0.08);

  max-height: 250px;

  overflow-y: auto;

}



.qs-result-item {

  display: flex;

  align-items: center;

  gap: 10px;

  padding: 8px 10px;

  color: #e6eef6;

  text-decoration: none;

  border-radius: 8px;

  transition: background 0.2s ease, transform 0.15s ease;

}



.qs-result-item:hover {

  background: rgba(34, 211, 238, 0.15);

  transform: translateX(4px);

}



.qs-result-item img {

  width: 36px;

  height: 36px;

  border-radius: 6px;

  object-fit: cover;

}



/* Không có kết quả */

#searchResults p {

  color: #9aa7b2;

  text-align: center;

  padding: 10px;

  font-size: 14px;

  margin: 0;

}



/* --- Responsive: ẩn trên mobile --- */

@media (max-width: 768px) {

  .quick-search-wrap {

    display: none !important;

  }

}

/* index.css */

/* Category Search CSS */
.category-search {
    margin: 20px 0;
    text-align: center;
   
}

.category-search label {
    font-size: 16px;
    margin-right: 10px;
    font-weight: bold;
}

#category-search {
    font-size: 16px;
    padding: 8px;
    width: 80%;
    border: 1px solid #ccc;
    border-radius: 4px;
    background-color: #fff;
    cursor: pointer;
    transition: all 0.3s ease;
}

#category-search:hover {
    border-color: #0073aa;
}

#category-search:focus {
    outline: none;
    border-color: #0073aa;
    box-shadow: 0 0 5px rgba(0, 115, 170, 0.5);
}



/* bài viết tất cả */
/* ===============================
   STYLE CHUNG CHO CÁC SECTION
================================ */
.section-wrapper {
    margin: 40px 0;
    padding: 20px 0;
}

.section-header {
    margin-bottom: 30px;
    text-align: center;
}

.section-title {
    font-size: 2rem;
    font-weight: 700;
    color: #1f2937; /* FIX CONTRAST */
    margin-bottom: 10px;
    text-transform: uppercase;
    letter-spacing: 1px;
}

.section-divider {
    height: 3px;
    width: 80px;
    background: linear-gradient(90deg, #c0392b, #0f766e); /* FIX */
    margin: 0 auto;
    border-radius: 2px;
}

/* ===============================
   CONTAINER SLIDER (QUAN TRỌNG)
================================ */
.posts-slider-container {
    position: relative;
    max-width: 1200px;
    margin: 0 auto;
    padding: 0 60px;
    overflow: hidden;
}

/* ===============================
   SLIDER (JS ĐIỀU KHIỂN)
================================ */
.homepage-posts-slider {
    display: flex;
    gap: 25px;
    transition: transform 0.4s ease;
    will-change: transform;
}

/* ===============================
   NÚT ĐIỀU KHIỂN
================================ */
.slider-btn {
    position: absolute;
    top: 50%;
    transform: translateY(-50%);
    width: 50px;
    height: 50px;
    background: #ffffff;
    border: 2px solid #9ca3af;
    border-radius: 50%;
    font-size: 1.5rem;
    color: #1f2937; /* FIX */
    cursor: pointer;
    z-index: 20;
    display: flex;
    align-items: center;
    justify-content: center;
    transition: all 0.3s ease;
    box-shadow: 0 4px 12px rgba(0,0,0,0.1);
}

.slider-btn:hover {
    background: #1f2937; /* FIX */
    color: #ffffff;
    border-color: #1f2937;
    transform: translateY(-50%) scale(1.1);
}

.prev-btn { left: 0; }
.next-btn { right: 0; }

.slider-btn:disabled {
    opacity: 0.5;
    cursor: not-allowed;
}

/* ===============================
   CARD BÀI VIẾT
================================ */
.post-card-slider {
    flex: 0 0 300px;
    max-width: 300px;
    background: #ffffff;
    border-radius: 12px;
    overflow: hidden;
    box-shadow: 0 6px 20px rgba(0,0,0,0.1);
    display: flex;
    flex-direction: column;
    transition: transform 0.3s ease, box-shadow 0.3s ease;
    animation: fadeIn 0.5s ease;
}

.post-card-slider:hover {
    transform: translateY(-8px);
    box-shadow: 0 12px 30px rgba(0,0,0,0.15);
}

/* ===============================
   ẢNH ĐẠI DIỆN
================================ */
.post-thumbnail {
    height: 180px;
    overflow: hidden;
}

.post-thumbnail a {
    display: block;
    width: 100%;
    height: 100%;
}

.post-thumbnail img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    transition: transform 0.5s ease;
}

.post-card-slider:hover img {
    transform: scale(1.05);
}

/* ===============================
   NỘI DUNG
================================ */
.post-content {
    padding: 20px;
    display: flex;
    flex-direction: column;
    flex-grow: 1;
}

/* CATEGORY */
.post-category {
    margin-bottom: 10px;
}

.post-category a {
    display: inline-block;
    padding: 4px 12px;
    font-size: 0.75rem;
    font-weight: 600;
    color: #ffffff;
    border-radius: 20px;
    text-transform: uppercase;
    letter-spacing: 0.5px;
    text-decoration: none;
    transition: all 0.3s ease;
}

.post-category a:hover {
    transform: scale(1.05);
}

/* FIX CONTRAST CATEGORY */
.news-category a { background: #c0392b; }
.game-category a { background: #0f766e; }
.history-category a { background: #1e40af; }

/* TIÊU ĐỀ */
.post-title {
    font-size: 1.15rem;
    font-weight: 700;
    line-height: 1.4;
    margin: 10px 0;
}

.post-title a {
    color: #1f2937; /* FIX */
    text-decoration: none;
    display: -webkit-box;
    -webkit-line-clamp: 2;
    -webkit-box-orient: vertical;
    overflow: hidden;
}

.post-title a:hover {
    color: #0f766e;
}

/* EXCERPT */
.post-excerpt {
    font-size: 0.95rem;
    color: #374151; /* FIX */
    line-height: 1.5;
    margin: 10px 0;
    flex-grow: 1;
    display: -webkit-box;
    -webkit-line-clamp: 3;
    -webkit-box-orient: vertical;
    overflow: hidden;
}

/* META */
.post-meta {
    margin-top: 15px;
    padding-top: 10px;
    border-top: 1px solid #e5e7eb;
    font-size: 0.85rem;
    color: #4b5563; /* FIX */
}

.post-date::before {
    content: "📅 ";
}

/* ===============================
   NO POSTS
================================ */
.no-posts {
    width: 100%;
    text-align: center;
    padding: 40px;
    background: #f3f4f6; /* FIX */
    border: 2px dashed #9ca3af;
    border-radius: 10px;
    color: #1f2937; /* FIX */
}

/* ===============================
   RESPONSIVE
================================ */
@media (max-width: 1024px) {
    .post-card-slider {
        flex: 0 0 280px;
        max-width: 280px;
    }
}

@media (max-width: 768px) {
    .posts-slider-container {
        padding: 0 40px;
    }

    .post-card-slider {
        flex: 0 0 260px;
        max-width: 260px;
    }

    .slider-btn {
        width: 42px;
        height: 42px;
        font-size: 1.2rem;
    }
}

@media (max-width: 576px) {
    .posts-slider-container {
        padding: 0 30px;
    }

    .post-card-slider {
        flex: 0 0 240px;
        max-width: 240px;
    }

    .post-thumbnail {
        height: 160px;
    }

    .post-content {
        padding: 15px;
    }

    .section-title {
        font-size: 1.4rem;
    }
}

/* ===============================
   ANIMATION
================================ */
@keyframes fadeIn {
    from {
        opacity: 0;
        transform: translateY(20px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}




/* sản phẩm trưng bày */
.tbp-product-list {
    display: flex;
    flex-wrap: wrap;
    gap: 20px;
    justify-content: center;
    padding: 20px;
}

.tbp-product {
    width: 260px;
    background: #ffffff;
    border-radius: 10px;
    overflow: hidden;
    box-shadow: 0 4px 8px rgba(0,0,0,0.1);
    text-align: center;
    transition: 0.25s;
}

.tbp-product:hover {
    transform: translateY(-5px);
    box-shadow: 0 6px 18px rgba(0,0,0,0.15);
}

.tbp-product img {
    width: 100%;
    height: 200px;
    object-fit: cover;
}

.tbp-info {
    padding: 15px;
}

.tbp-title {
    font-size: 18px;
    margin-bottom: 8px;
    color: #212121; /* Thêm màu đen rõ cho tiêu đề */
    font-weight: 600;
}

.tbp-desc {
    font-size: 14px;
    color: #545454; /* Đã tăng độ đậm từ #666 */
    margin-bottom: 10px;
    line-height: 1.4;
}

.tbp-price {
    font-size: 18px;
    font-weight: bold;
    color: #d32f2f; /* Đỏ đậm hơn để tăng tương phản */
    margin-bottom: 15px;
}

.tbp-btn {
    display: inline-block;
    padding: 10px 20px;
    background: #1976d2; /* Xanh đậm hơn #2196f3 để chữ trắng đạt chuẩn tương phản */
    color: #ffffff;
    border-radius: 6px;
    text-decoration: none;
    transition: 0.25s;
    font-weight: 500;
}

.tbp-btn:hover {
    background: #1565c0;
}

header-trungbay-product {
    display: block;
    width: 100%;
    max-width: 100%;
    box-sizing: border-box;
    text-align: center;
    padding: 40px 20px;
    /* Sử dụng gradient đậm hơn để tương phản với chữ trắng */
    background: linear-gradient(135deg, #1976d2, #1565c0);
    color: #ffffff;
    border-radius: 0 0 15px 15px;
    box-shadow: 0 4px 15px rgba(0,0,0,0.15);
    margin: 0 0 30px 0;
    overflow: hidden;
}

header-trungbay-product h1 {
    margin: 0;
    font-size: 32px;
    font-weight: 700;
    letter-spacing: 1px;
    word-wrap: break-word;
}

header-trungbay-product p {
    margin-top: 10px;
    font-size: 16px;
    opacity: 1; /* Để opacity 1 thay vì 0.9 để rõ nét nhất */
    word-wrap: break-word;
}

/* world app */
/* ================== FORM XWORLD ================== */
.xworld-form {
    max-width: 900px;
    margin: 30px auto;
    padding: 0 10px;
}

.xworld-form-inner {
    display: flex;
    align-items: center;
    gap: 24px;
    padding: 24px 28px;
    border-radius: 16px;
    background: linear-gradient(135deg, #1e1e2f, #2c2c44);
    box-shadow: 0 14px 35px rgba(0,0,0,0.2);
    color: #fff;
}

/* LOGO */
.xworld-logo {
    flex-shrink: 0;
}

.xworld-logo img {
    width: 90px;
    height: 90px;
    object-fit: contain;
    border-radius: 14px;
    background: #fff;
    padding: 10px;
}

/* TEXT */
.xworld-text h3 {
    font-size: 22px;
    margin-bottom: 8px;
    color: #4ecdc4;
}

.xworld-text p {
    font-size: 15px;
    line-height: 1.6;
    margin-bottom: 14px;
    color: #e0e0e0;
}

/* BUTTON */
.xworld-btn {
    display: inline-block;
    padding: 12px 26px;
    background: linear-gradient(90deg, #4ecdc4, #ff6b6b);
    color: #fff;
    font-weight: 600;
    text-decoration: none;
    border-radius: 30px;
    transition: transform 0.3s ease, box-shadow 0.3s ease;
}

.xworld-btn:hover {
    transform: translateY(-2px);
    box-shadow: 0 8px 20px rgba(0,0,0,0.25);
}


/* page.php */
/* ================== PAGE.PHP ================== */

.single-post .post-container {

    max-width: 900px;       /* Giới hạn chiều rộng */

    margin: 0 auto;         /* Căn giữa container */

    padding: 20px;

    text-align: center;     /* Căn giữa toàn bộ nội dung */

    background: #fff;

    border-radius: 12px;

    box-shadow: 0 4px 16px rgba(0,0,0,0.08);

}



/* Tiêu đề */

.single-post .post-title {

    font-size: 32px;

    font-weight: 700;

    color: #222;

    margin-bottom: 15px;

    line-height: 1.3;

}



/* Meta (ngày, tác giả, danh mục) */

.single-post .post-meta {

    font-size: 14px;

    color: #666;

    margin-bottom: 20px;

}

.single-post .post-meta span {

    margin: 0 8px;

}



/* Thumbnail */

.single-post .post-thumbnail img {

    max-width: 100%;

    height: auto;

    border-radius: 10px;

    margin-bottom: 20px;

    object-fit: cover;

}



/* Nội dung */

.single-post .post-content {

    font-size: 16px;

    line-height: 1.8;

    color: #333;

    text-align: left;      /* Nội dung văn bản đọc dễ hơn khi canh trái */

}



/* Nếu có ảnh trong nội dung */

.single-post .post-content img {

    max-width: 90%;

    margin: 20px auto;

    display: block;

    border-radius: 8px;

}



/* Phân trang */

.single-post .page-links {

    margin-top: 20px;

    font-size: 14px;

    font-weight: 500;

    color: #0073aa;

}



/* Footer - Tags */

.single-post .post-footer {

    margin-top: 25px;

    font-size: 14px;

    color: #444;

}

.single-post .post-tags {

    margin-top: 10px;

}

.single-post .post-tags a {

    background: #f0f0f0;

    padding: 6px 12px;

    border-radius: 6px;

    margin: 0 5px;

    text-decoration: none;

    color: #0073aa;

    transition: all 0.3s;

}

.single-post .post-tags a:hover {

    background: #0073aa;

    color: #fff;

}

/* single.php */
/* ================== LAYOUT TỔNG ================== */
.single-page .single-container {
    display: grid;
    grid-template-columns: 3fr 1fr; /* Nội dung : Sidebar */
    gap: 30px;
    padding: 20px 0;         /* chỉ padding trên dưới */
    width: 100%;
    max-width: 1400px;
    margin: 0 auto;
    background: #fff;
    align-items: start;
    box-sizing: border-box;
    overflow-x: hidden;      /* tránh bị kéo ngang */
    flex-wrap: wrap;         /* 👈 cho phép xuống dòng nếu cần */
}

/* Nếu không có sidebar thì 1 cột full width */
.single-page .single-container:not(:has(.single-right)) {
    grid-template-columns: 1fr;
}

/* ================== BÊN TRÁI ================== */
.single-left {
    padding-left: 0;
}

.single-left h1.post-title {
    font-size: 28px;
    font-weight: 700;
    margin-bottom: 20px;
    line-height: 1.4;
    color: #222;
}

.single-left .post-thumbnail-wrapper {
    margin-bottom: 20px;
    text-align: center;
}

/* Hình ảnh chính bài viết */
.single-left .post-thumbnail {
    max-width: 780px;
    width: 100%;
    aspect-ratio: 16 / 9;
    object-fit: cover;
    border-radius: 8px;
    display: block;
    margin: 0 auto;
}

/* ================== RESPONSIVE MOBILE ================== */
@media (max-width: 768px) {
    .single-page .single-container {
        display: flex;          
        flex-direction: column; 
        flex-wrap: wrap;        
        gap: 20px;
        padding: 15px;          /* padding ngang để không dính mép */
    }

    .single-left {
        max-width: 100%;
        padding: 0;
    }

    /* Ảnh chính bài viết full width */
    .single-left .post-thumbnail {
        width: 100% !important;
        max-width: 100% !important;
        height: auto;
        border-radius: 6px;
        aspect-ratio: auto;     /* bỏ ép tỉ lệ 16:9 trên mobile */
        object-fit: contain;    /* hiển thị toàn bộ ảnh */
    }

    /* Ảnh trong nội dung full width */
    .single-left .post-content img {
        width: 100% !important;
        max-width: 100% !important;
        height: auto !important;
        margin: 15px auto;
        border-radius: 6px;
        object-fit: contain;    /* không crop ảnh */
    }
}


/* ================== HÌNH ẢNH CHÍNH BÀI VIẾT (LANDSCAPE 16:9) ================== */
.single-left .post-thumbnail {
    max-width: 900px;        /* rộng hơn một chút cho desktop */
    width: 100%;
    aspect-ratio: 16 / 9;    /* luôn giữ tỷ lệ landscape */
    object-fit: cover;       /* crop gọn ảnh thừa */
    border-radius: 10px;
    display: block;
    margin: 0 auto 20px auto;
    box-shadow: 0 4px 10px rgba(0,0,0,0.08);
}

/* Mobile: ảnh chính landscape nhưng full chiều ngang */
@media (max-width: 768px) {
    .single-left .post-thumbnail {
        width: 100%;
        max-width: 100%;
        aspect-ratio: 16 / 9;
        border-radius: 8px;
    }
}

/* ================== THUMBNAIL BÀI VIẾT (ẢNH ĐẠI DIỆN) ================== */
.single-left .post-thumbnail-wrapper {
    width: 100%;
    margin: 0 auto 28px;
    text-align: center;
}

/* Ảnh thumbnail chính */
.single-left .post-thumbnail {
    width: 100%;
    max-width: 900px;
    height: auto;
    aspect-ratio: 16 / 9;
    object-fit: cover;
    display: block;
    margin: 0 auto;
    border-radius: 14px;
    background-color: #f2f2f2; /* fallback khi ảnh load chậm */
    box-shadow: 0 12px 30px rgba(0, 0, 0, 0.12);
    transition: transform 0.4s ease, box-shadow 0.4s ease;
}

/* Hover nhẹ (chỉ desktop) */
@media (hover: hover) {
    .single-left .post-thumbnail:hover {
        transform: scale(1.015);
        box-shadow: 0 16px 40px rgba(0, 0, 0, 0.16);
    }
}



/* ================== ẢNH TRONG NỘI DUNG ================== */
.single-left .post-content img {
    max-width: 650px;        /* 👈 nhỏ hơn ảnh chính một chút */
    width: 90%;              /* responsive: chỉ chiếm ~90% khung content */
    height: auto;
    display: block;
    margin: 20px auto;
    border-radius: 8px;
    object-fit: contain;     /* giữ nguyên tỷ lệ, không crop */
    box-shadow: 0 2px 8px rgba(0,0,0,0.08);
    transition: transform 0.3s ease;
}

/* Hover: nhẹ nhàng */
.single-left .post-content img:hover {
    transform: scale(1.02);
}

/* Mobile: ảnh content vừa phải, không full sát màn hình */
@media (max-width: 768px) {
    .single-left .post-content img {
        width: 95%;          /* không full 100% để cân đối chữ */
        max-width: 95%;
        margin: 15px auto;
        border-radius: 6px;
    }
}



/* ================== RESPONSIVE ================== */
@media (max-width: 992px) {
    .single-page .single-container {
        grid-template-columns: 1fr; /* 1 cột */
    }

    /* Sidebar chuyển thành row khi tablet */
    .single-right {
        flex-direction: row;
        flex-wrap: wrap;
        justify-content: center; /* căn giữa hàng ngang */
        gap: 15px;
    }

    .single-right > div {
        flex: 1 1 45%;
        max-width: 400px;
    }
}

@media (max-width: 600px) {
    /* Sidebar xuống dưới và căn giữa khi mobile */
    .single-right {
        flex-direction: column;
        align-items: center; /* căn giữa theo cột */
    }

    .single-right > div {
        flex: 1 1 100%;
        width: 90%;           /* gọn khung */
        max-width: 400px;     /* không quá to */
        margin: 0 auto;
    }

    .latest-post-item,
    .popular-related-posts .post-item,
    .random-products .product-item {
        flex-direction: column;
        align-items: flex-start;
    }
}

/* ================== META ================== */
.post-meta p {
    margin: 6px 0;
    font-size: 14px;
    color: #555;
}
.post-meta strong {
    color: #111;
}


/* ================== FORM 2: Bài viết mới nhất ================== */
.latest-post-item {
    display: flex;
    align-items: center;
    gap: 12px;
    padding: 10px;
    border: 1px solid #e5e7eb;
    border-radius: 10px;
    background: #fff;
    transition: all 0.3s ease;
    box-shadow: 0 2px 6px rgba(0,0,0,0.05);
}
.latest-post-item:hover {
    transform: translateY(-3px);
    box-shadow: 0 4px 12px rgba(0,0,0,0.12);
}

.latest-post-thumb {
    width: 70px;
    height: 70px;
    object-fit: cover;
    border-radius: 8px;
    flex-shrink: 0;
}

.latest-post-item p {
    margin: 0;
    font-size: 15px;
    font-weight: 500;
    line-height: 1.4;
}

.latest-post-item a {
    color: #1a73e8;
    text-decoration: none;
    transition: color 0.2s ease;
}
.latest-post-item a:hover {
    color: #0d47a1;
}

/* ================== FORM 3: Bài viết phổ biến & liên quan ================== */
.popular-related-posts .post-item {
    display: flex;
    align-items: flex-start;
    gap: 12px;
    padding: 10px;
    border-bottom: 1px solid #f0f0f0;
    transition: background 0.3s ease;
}
.popular-related-posts .post-item:last-child {
    border-bottom: none;
}
.popular-related-posts .post-item:hover {
    background: #f9fafb;
    border-radius: 8px;
}

.popular-related-posts .post-thumb {
    width: 65px;
    height: 65px;
    object-fit: cover;
    border-radius: 8px;
    flex-shrink: 0;
    box-shadow: 0 2px 6px rgba(0,0,0,0.1);
}

.popular-related-posts .post-title {
    font-size: 15px;
    font-weight: 500;
    color: #1a73e8;
    line-height: 1.4;
    display: -webkit-box;
    -webkit-line-clamp: 2;   /* Giới hạn 2 dòng */
    -webkit-box-orient: vertical;
    overflow: hidden;
}
.popular-related-posts .post-title:hover {
    color: #0d47a1;
    text-decoration: underline;
}

/* ================== Nút Xem thêm ================== */
#load-more-btn {
    background: linear-gradient(135deg, #1a73e8, #005f85);
    color: #fff;
    border: none;
    padding: 10px 16px;
    border-radius: 8px;
    font-size: 14px;
    font-weight: 500;
    cursor: pointer;
    transition: all 0.3s ease;
    display: inline-block;
    margin-top: 12px;
}
#load-more-btn:hover {
    background: linear-gradient(135deg, #005f85, #003c5a);
    transform: translateY(-2px);
    box-shadow: 0 4px 12px rgba(0,0,0,0.15);
}



/* === Khung chứa các video === */
.video-flex-container {
  display: flex;
  flex-wrap: wrap;
  justify-content: center; /* căn giữa các video */
  align-items: flex-start;
  gap: 16px; /* khoảng cách giữa các video */
  width: 100%;
  box-sizing: border-box;
  overflow: hidden;
}

/* === KHỐNG CHẾ VIDEO / IFRAME TRONG BÀI VIẾT === */
.single-left .post-content iframe,
.single-left .post-content video,
.single-left .post-content embed,
.single-left .post-content object {
  display: block;
  max-width: 800px;           /* 👈 Giới hạn chiều rộng trên desktop */
  width: 100%;
  height: auto;
  aspect-ratio: 16 / 9;
  margin: 20px auto;
  border: none;
  border-radius: 10px;
  background: #000;
  box-shadow: 0 3px 10px rgba(0,0,0,0.08);
  box-sizing: border-box;
}

/* Định dạng cơ bản cho toàn bộ bảng */
table {
    width: 100%; /* Bảng chiếm toàn bộ chiều rộng của vùng chứa */
    border-collapse: collapse; /* Gộp các đường viền lại thành một */
    margin-bottom: 20px; /* Khoảng cách dưới cùng của bảng */
}

/* Định dạng cho tiêu đề bảng và các ô dữ liệu */
th, td {
    border: 1px solid #ccc; /* Viền 1px, màu xám nhạt */
    padding: 8px; /* Khoảng đệm bên trong các ô */
    text-align: left; /* Căn lề trái cho nội dung ô */
}

/* Định dạng đặc biệt cho phần tiêu đề bảng (header) */
thead th {
    background-color: #f2f2f2; /* Màu nền xám nhạt cho hàng tiêu đề */
    color: #333; /* Màu chữ đen */
    font-weight: bold; /* Chữ đậm */
}

/* Tạo hiệu ứng sọc (zebra-striping) cho các hàng */
/* Định dạng cho các hàng chẵn (2, 4, 6, ...) */
tbody tr:nth-child(even) {
    background-color: #f9f9f9; /* Màu nền rất nhạt cho hàng chẵn */
}

/* Thêm hiệu ứng hover khi di chuột qua hàng */
tbody tr:hover {
    background-color: #e5e5e5;
}

/* === MOBILE: ép chặt, tránh lệch phải === */
@media (max-width: 768px) {
  html, body {
    overflow-x: hidden !important;
    width: 100%;
  }

  .single-left .post-content iframe,
  .single-left .post-content video,
  .single-left .post-content embed,
  .single-left .post-content object {
    max-width: 100% !important;
    width: 100% !important;
    height: auto !important;
    aspect-ratio: 16 / 9;
    margin: 12px auto;
    border-radius: 6px;
  }

  /* Đảm bảo mọi phần tử không tràn */
  .single-left .post-content * {
    max-width: 100% !important;
    box-sizing: border-box !important;
    overflow-x: hidden !important;
  }
}


/* search.php */
.search-results-list {

    list-style: none;

    padding: 0;

}



.search-item {

    padding: 15px 0;

    border-bottom: 1px solid #ddd;

}



.item-inner {

    display: flex;

    align-items: flex-start;

    gap: 15px;

}



.thumbnail-wrapper {

    width: 60px;

    height: 60px;

    overflow: hidden;

    flex-shrink: 0;

    border-radius: 5px;

    border: 1px solid #ccc;

}



.search-thumb {

    width: 100%;

    height: 100%;

    object-fit: cover;

}



.item-content {

    flex: 1;

}



.post-title a {

    font-size: 18px;

    text-decoration: none;

    color: #0073aa;

}



.post-title a:hover {

    text-decoration: underline;

}



.post-categories {

    margin-top: 5px;

    font-size: 14px;

    color: #555;

}



.category-name {

    background: #f1f1f1;

    padding: 3px 6px;

    border-radius: 3px;

    margin-right: 5px;

}



.no-category {

    font-size: 13px;

    color: #999;

    font-style: italic;

}



.search-submit {

    background: none;

    border: none;

    padding: 0;

    cursor: pointer;

}



.search-box {

    display: none; /* ẩn mặc định */

    position: absolute; /* hoặc tuỳ layout */

    top: 100%;

    left: 0;

    width: 100%;

    background: white;

    border: 1px solid #ccc;

    z-index: 9999;

    /* thêm padding, box-shadow,... nếu cần */

}

