/* === Tìm theo danh mục === */
.main-content-wrapper {
    display: flex;
    flex-wrap: wrap; /* Cho phép xuống dòng khi màn hình nhỏ */
    justify-content: space-between;
    max-width: 1200px;
    margin: 40px auto;
    padding: 0 20px;
    box-sizing: border-box;
}

/* Cột trái - bài viết */
.left-content {
    flex: 0 0 70%;
    box-sizing: border-box;
    min-width: 300px; /* để không quá nhỏ */
}

/* Cột phải - sidebar */
.right-sidebar {
    flex: 0 0 28%;
    box-sizing: border-box;
    min-width: 250px;
}

/* bài viết */
/* Căn chỉnh phần lưới bài viết */
.left-content {
    padding: 20px;
}

.post-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(300px, 1fr));
    gap: 30px;
    align-items: start;
}

.post-grid .pagination {
    grid-column: 1 / -1; /* Chiếm toàn bộ hàng */
    justify-self: center;
    margin-top: 30px;
}


/* Kiểu cho từng bài viết */
.post-item {
    background-color: #ffffff;
    border: 1px solid #e0e0e0;
    border-radius: 10px;
    overflow: hidden;
    box-shadow: 0 2px 6px rgba(0,0,0,0.1);
    transition: transform 0.3s ease, box-shadow 0.3s ease;
}

.post-item:hover {
    transform: translateY(-5px);
    box-shadow: 0 6px 16px rgba(0,0,0,0.15);
}

/* Ảnh thumbnail */
.post-item img {
    width: 100%;
    height: auto;
    display: block;
}

/* Tiêu đề bài viết */
.post-title {
    font-size: 20px;
    margin: 15px;
}

.post-title a {
    text-decoration: none;
    color: #333;
    transition: color 0.3s ease;
}

.post-title a:hover {
    color: #0073aa;
}

/* Đoạn trích */
.post-excerpt {
    margin: 0 15px 10px 15px;
    color: #555;
    font-size: 15px;
    line-height: 1.5;
}

/* Thông tin meta */
.post-meta {
    margin: 0 15px 15px 15px;
    font-size: 13px;
    color: #888;
}

/* Nút Read more */
.read-more {
    display: inline-block;
    margin: 0 15px 15px 15px;
    padding: 8px 14px;
    background-color: #0073aa;
    color: white;
    text-decoration: none;
    border-radius: 5px;
    transition: background-color 0.3s ease;
}

.read-more:hover {
    background-color: #005f8d;
}

/* Phân trang */
.pagination {
    text-align: center;
    margin-top: 40px;
}

.pagination a,
.pagination span {
    display: inline-block;
    margin: 0 5px;
    padding: 8px 12px;
    color: #0073aa;
    text-decoration: none;
    border: 1px solid #ddd;
    border-radius: 4px;
    transition: all 0.3s ease;
}

.pagination a:hover {
    background-color: #0073aa;
    color: white;
    border-color: #0073aa;
}

.pagination .current {
    background-color: #0073aa;
    color: white;
    border-color: #0073aa;
}


/* 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);
}

/* Latest Posts */
.latest-posts {
    margin-top: 40px;
    background-color: #f9f9f9;
    padding: 15px;
    border-radius: 8px;
}

.latest-posts h3 {
    font-size: 18px;
    margin-bottom: 10px;
}

.latest-posts ul {
    list-style: none;
    padding: 0;
    margin: 0;
}

.latest-posts li {
    margin-bottom: 8px;
}

.latest-posts a {
    text-decoration: none;
    color: #0073aa;
}

.latest-posts a:hover {
    text-decoration: underline;
}

/* === Responsive === */
@media screen and (max-width: 768px) {
  .left-content, .right-sidebar {
    flex: 0 0 100%; max-width: 100%;
  }
  .post-item {
    width: 100% !important; /* 1 bài 1 dòng khi nhỏ */
    }
.latest-posts {
 margin-top: 40px;
}
    
    
  
}

.woocommerce-all {
    text-align: center
}

.products-grid {
    display: flex;
    flex-wrap: wrap;
    justify-content: center;
    gap: 30px;
}
.product-item {
    width: 250px;
    border: 1px solid #eee;
    border-radius: 10px;
    padding: 20px;
    box-shadow: 0 0 10px rgba(0,0,0,0.05);
    text-align: center;
}
.product-item img {
    max-width: 100%;
    height: auto;
}
.product-title {
    font-size: 18px;
    margin: 10px 0;
}
.product-price {
    font-weight: bold;
    color: #007cba;
}

/* bộ cứu hộ css */
.tnpboot-title {
    text-align: center;
}
        table {
            margin: 0 auto;
            border-collapse: collapse;
            width: 80%;
            max-width: 800px;
            background: #fff;
            box-shadow: 0 0 10px rgba(0,0,0,0.1);
        }
        th, td {
            border: 1px solid #ddd;
            padding: 15px;
            text-align: center;
        }
        th {
            background-color: #007cba;
            color: white;
        }
        tr:nth-child(even) {
            background-color: #f9f9f9;
        }
        .check {
            color: green;
            font-weight: bold;
        }
        .cross {
            color: red;
            font-weight: bold;
        }
        .button-row {
            display: flex;
            justify-content: center;
            margin-top: 30px;
            gap: 40px;
            flex-wrap: wrap;
        }
        .btn {
            padding: 12px 25px;
            font-size: 16px;
            border: none;
            border-radius: 8px;
            cursor: pointer;
            text-decoration: none;
            color: white;
            transition: background 0.3s;
        }
        .btn-download {
            background-color: #28a745;
        }
        .btn-download:hover {
            background-color: #218838;
        }
        .btn-buy {
            background-color: #dc3545;
        }
        .btn-buy:hover {
            background-color: #c82333;
        }

        /* câu hỏi thường gặp */
         .faq-title {
      text-align: center;
      color: #007cba;
      margin-bottom: 40px;
    }

    .faq-item {
      background: #fff;
      border-radius: 8px;
      margin-bottom: 15px;
      box-shadow: 0 2px 6px rgba(0,0,0,0.1);
      overflow: hidden;
    }

    .faq-question {
      padding: 18px 20px;
      cursor: pointer;
      font-weight: bold;
      background: #007cba;
      color: white;
      transition: background 0.3s;
    }

    .faq-question:hover {
      background: #005c91;
    }

    .faq-answer {
      padding: 15px 20px;
      display: none;
      background: #f7f7f7;
      border-top: 1px solid #ddd;
    }

    .faq-item.active .faq-answer {
      display: block;
    }

    /* donate */
    .donate-box {
    background-color: #ffffff; /* Nền trắng */
    padding: 20px;
    border: 1px solid #ddd;
    border-radius: 8px;
    box-shadow: 0 2px 5px rgba(0,0,0,0.05);
    text-align: center;
}

.donate-box h3 {
    margin-bottom: 10px;
    font-size: 18px;
    color: #333;
}

.donate-box p {
    margin-bottom: 15px;
    color: #555;
    font-size: 15px;
}

.donate-button {
    display: inline-block;
    background-color: #ff9900;
    color: white;
    padding: 10px 20px;
    border-radius: 6px;
    text-decoration: none;
    font-weight: bold;
    transition: background-color 0.3s ease;
}

.donate-button:hover {
    background-color: #e68a00;
}

.zalopay-button {
    background-color: #00b3ff;
    margin-top: 10px;
    cursor: pointer; /* Hiển thị bàn tay khi di chuột */
}

.zalopay-button:hover {
    background-color: #0099dd;
}
