/* --- BIẾN MÀU SẮC & FONT (VARIABLES) --- */
@import url('https://fonts.googleapis.com/css2?family=Montserrat:wght@400;500;700&display=swap');

:root {
  --primary-color: #8D6E63;
  --dark-color: #333333;
  --light-color: #FFFFFF;
  --bg-color: #f9f9f9;
  --border-color: #eeeeee;
  --shadow: 0 4px 15px rgba(0, 0, 0, 0.08);
  --shadow-hover: 0 6px 20px rgba(0, 0, 0, 0.12);
}

/* --- THIẾT LẬP CHUNG & RESET --- */
* {
  box-sizing: border-box;
}

body {
  font-family: 'Montserrat', sans-serif;
  margin: 0;
  padding: 0;
  background-color: var(--bg-color);
  color: var(--dark-color);
  line-height: 1.6;
  text-align: center;
}

/* --- HEADER, NAV, FOOTER (Giữ nguyên) --- */
header { display: flex; justify-content: space-around; align-items: center; padding: 15px 40px; background-color: var(--light-color); box-shadow: var(--shadow); position: sticky; top: 0; z-index: 1000; }
.logo img { height: 50px; }
nav ul { list-style: none; display: flex; margin: 0; padding: 0; }
nav li { margin-left: 30px; }
nav a { text-decoration: none; color: var(--dark-color); font-weight: 500; position: relative; padding: 5px 0; transition: color 0.3s ease; }
nav a::after { content: ''; position: absolute; width: 0; height: 2px; bottom: 0; left: 0; background-color: var(--primary-color); transition: width 0.3s ease; }
nav a:hover { color: var(--primary-color); }
nav a:hover::after { width: 100%; }
footer { text-align: center; padding: 20px; background-color: var(--light-color); border-top: 1px solid var(--border-color); margin-top: 40px; }


/* --- BANNER (SWIPER) --- */
.swiper-container, .swiper {
  width: 100%;
  padding: 50px 0;
  margin-bottom: 3rem;
}

.swiper-slide {
  width: 75%; 
  max-width: 1216px;
  
  /* **THAY ĐỔI TỈ LỆ KHUNG ẢNH TẠI ĐÂY** */
  aspect-ratio: 21 / 9;
  
  border-radius: 15px;
  overflow: hidden;
  
  transform: scale(0.8);
  opacity: 0.5;
  
  transition: transform 0.5s ease, opacity 0.5s ease;
}

.swiper-slide-active {
  transform: scale(1);
  opacity: 1;
  box-shadow: 0 8px 30px rgba(0,0,0,0.15);
}

.swiper-slide img {
  width: 100%;
  height: 100%;
  object-fit: cover;
}

.swiper-button-next, .swiper-button-prev {
  color: white;
}


/* --- KHU VỰC ƯU ĐÃI (OFFERS) --- */
.offers {
  display: grid;
  grid-template-columns: repeat(auto-fit, 280px);
  justify-content: center;
  gap: 2rem;
  padding: 40px 20px;
  max-width: 1216px; 
  margin: 0 auto;
}

/* ... Các CSS còn lại cho .offer giữ nguyên ... */
.offer { text-align: center; background-color: var(--light-color); border-radius: 12px; box-shadow: var(--shadow); overflow: hidden; transition: transform 0.3s ease, box-shadow 0.3s ease; }
.offer:hover { transform: translateY(-8px); box-shadow: var(--shadow-hover); }
.offer img { width: 100%; height: auto; aspect-ratio: 1245 / 1900; object-fit: cover; display: block; }
.offer-content { padding: 20px; }
.offer h3 { margin-top: 0; margin-bottom: 10px; font-size: 1.1rem; }
.offer p { margin-bottom: 0; font-size: 0.9rem; color: #666; }

/* --- RESPONSIVE --- */
@media (max-width: 768px) {
  header {
    flex-direction: column;
    gap: 15px;
  }
  .swiper-slide {
    width: 90%;
  }
  .offers {
    /* Buộc layout chỉ có 1 cột */
    grid-template-columns: repeat(2, 1fr);
  }
}
.container {
  text-align: left;
  width: 100%;
  max-width: 1216px;
  margin: auto;
  padding: 0 15px;
}

.blog-post {
  background-color: #ffffff;
  border-radius: 8px;
  box-shadow: 0 4px 6px rgba(0, 0, 0, 0.1);
  padding: 30px;
  line-height: 1.6;
}

h2 {
  color: #333;
  text-align: center;
  margin-bottom: 25px;
  font-weight: bold;
}

ul {
  list-style: none;
  padding: 0;
  margin: 0;
}

li {
  margin-bottom: 15px;
  color: #555;
  font-size: 16px;
}

li strong {
  color: #000;
  margin-right: 5px;
}


/* --- Bố cục cho bài viết chính --- */
.blog-post-item {
    display: flex;
    background-color: #fff;
    border: 1px solid #e0e0e0;
    border-radius: 5px;
    padding: 20px;
    margin-bottom: 20px;
    align-items: flex-start;
}

.post-media {
    position: relative;
    width: 200px; /* Đặt chiều rộng cố định cho khối media */
    height: 120px; /* Đặt chiều cao cố định cho khối media */
    margin-right: 20px;
    overflow: visible; /* Cho phép phần ngày tháng hiển thị ra ngoài */
}

.image-wrapper {
    width: 100%;
    height: 100%;
    overflow: hidden; /* Cắt bỏ phần ảnh thừa */
    border-radius: 5px;
}

.post-thumbnail {
    width: 100%;
    height: 100%;
    object-fit: cover; /* Đảm bảo ảnh lấp đầy và không bị méo */
    display: block; /* Loại bỏ khoảng trắng dưới ảnh */
}

.post-date {
    position: absolute;
    top: -10px; /* Điều chỉnh vị trí ngày tháng */
    left: -10px; /* Điều chỉnh vị trí ngày tháng */
    width: 70px;
    height: 70px;
    background-color: #007bff;
    color: #fff;
    display: flex;
    flex-direction: column;
    justify-content: center;
    align-items: center;
    border-top-left-radius: 5px;
    z-index: 10;
    box-shadow: 0 4px 8px rgba(0, 0, 0, 0.2);
}

.post-date .day, .post-date .month {
    display: block;
    font-weight: bold;
    line-height: 1.2;
}

.post-date .day {
    font-size: 1.8rem;
}

.post-date .month {
    font-size: 0.9rem;
    text-transform: uppercase;
}

.post-body {
    flex: 1;
}

.post-title {
    margin: 0 0 10px 0;
    text-align: left;
}

.post-title a {
    text-decoration: none;
    color: #333;
    font-size: 1.2rem;
    font-weight: bold;
}

.post-excerpt {
    color: #666;
    font-size: 0.9rem;
}

.read-more {
    color: #007bff;
    font-weight: bold;
}

/* --- Bố cục cho sidebar --- */
.sidebar-widget {
    background-color: #fff;
    border: 1px solid #e0e0e0;
    border-radius: 5px;
    padding: 15px;
    margin-bottom: 20px;
}

.widget-title {
    font-size: 1.1rem;
    color: #333;
    border-bottom: 2px solid #007bff;
    padding-bottom: 5px;
    margin-bottom: 15px;
}

.recent-posts-list {
    list-style: none;
    padding: 0;
    margin: 0;
}

.recent-posts-list li {
    display: flex;
    align-items: center;
    margin-bottom: 15px;
}

.post-thumbnail-small-wrapper {
    position: relative;
    width: 60px; /* Đặt chiều rộng cố định cho khung ảnh nhỏ */
    height: 60px; /* Đặt chiều cao cố định cho khung ảnh nhỏ */
    margin-right: 10px;
    overflow: visible; /* Cho phép phần ngày tháng hiển thị ra ngoài */
}

.image-wrapper-small {
    width: 100%;
    height: 100%;
    overflow: hidden; /* Cắt bỏ phần ảnh thừa */
    border-radius: 5px;
}

.post-thumbnail-small {
    width: 100%;
    height: 100%;
    object-fit: cover; /* Đảm bảo ảnh lấp đầy và không bị méo */
    display: block;
}

.post-date-small {
    position: absolute;
    top: -5px; /* Điều chỉnh vị trí ngày tháng nhỏ */
    left: -5px; /* Điều chỉnh vị trí ngày tháng nhỏ */
    background-color: #007bff;
    color: #fff;
    padding: 5px;
    border-radius: 5px;
    font-size: 0.7rem;
    text-align: center;
    line-height: 1;
}

.recent-posts-list li a {
    text-decoration: none;
    color: #333;
    font-size: 0.9rem;
    font-weight: bold;
}

/* Thiết lập chính */
body {
    font-family: Arial, sans-serif;
    margin: 0;
    padding: 0;
    background-color: #f5f6f8;
}


.main-content {
    display: flex; /* Dùng Flexbox để tạo bố cục 2 cột */
    gap: 30px; /* Khoảng cách giữa 2 cột */
    margin-top: 30px;
}

.blog-post-list {
    flex: 3; /* Cột này chiếm 3 phần không gian */
}

.sidebar {
    flex: 1; /* Cột này chiếm 1 phần không gian */
    min-width: 280px;
}


/* Image Grid */
.post-media-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(180px, 1fr));
    gap: 15px;
    margin: 30px 0;
}

.post-grid-item {
    position: relative;
    overflow: hidden;
    border-radius: 5px;
}

.post-grid-item img {
    width: 100%;
    height: auto;
    display: block;
    object-fit: cover;
}

.post-grid-overlay {
    position: absolute;
    top: 5px;
    right: 5px;
    color: var(--light-color);
    padding: 5px 8px;
    border-radius: 3px;
    font-size: 0.8rem;
    font-weight: bold;
    display: flex;
    flex-direction: column;
    align-items: flex-end;
}

.post-grid-code {
    background-color: var(--brand-blue);
    padding: 2px 5px;
    border-radius: 3px;
    margin-bottom: 3px;
}

.post-grid-desc {
    font-size: 0.7rem;
    text-align: right;
    white-space: nowrap;
    background-color: rgba(0, 0, 0, 0.6);
}

/* Voucher Sections */
.voucher-section {
    background-color: #f9f9f9;
    border: 1px solid var(--border-color);
    border-radius: 8px;
    padding: 20px;
    margin: 30px 0;
}

.voucher-title {
    text-align: left;
    font-size: 1.5rem;
    font-weight: bold;
    color: var(--dark-color);
    margin-top: 0;
}

.voucher-content {
    display: flex;
    gap: 20px;
    align-items: flex-start;
}

.voucher-image {
    flex-shrink: 0;
    position: relative;
    width: 350px;
}

.voucher-image img {
    width: 100%;
    height: auto;
    border-radius: 5px;
    display: block;
}

.voucher-code {
    position: absolute;
    top: 10px;
    right: 10px;
    background-color: var(--brand-red);
    color: var(--light-color);
    padding: 5px 10px;
    border-radius: 5px;
    font-size: 0.9rem;
    font-weight: bold;
}

.voucher-details {
    flex-grow: 1;
    text-align: left;
}

.voucher-list {
    list-style: none;
    padding-left: 0;
}

.voucher-list li {
    padding-left: 20px;
    position: relative;
    margin-bottom: 10px;
    font-size: 0.9rem;
    line-height: 1.4;
    color: #555;
}

.voucher-list li::before {
    content: "•";
    position: absolute;
    left: 0;
    color: var(--brand-blue);
    font-weight: bold;
}

.voucher-button {
    display: block;
    width: 100%;
    text-align: center;
    padding: 12px;
    background-color: #880000;;
    color: var(--light-color);
    border: none;
    border-radius: 5px;
    font-weight: bold;
    transition: background-color 0.3s ease;
}

.voucher-button:hover {
    color: #b9582a;
}

.hamburger-menu {
  display: none; /* Ẩn nút theo mặc định */
  cursor: pointer;
  padding: 10px;
  position: absolute;
  right: 20px;
  top: 15px; /* Thêm dòng này để định vị nút */
  z-index: 1001;
}

.hamburger-menu .bar {
  width: 25px;
  height: 3px;
  background-color: var(--dark-color);
  margin: 4px 0;
  transition: all 0.3s ease;
}

/* Biến đổi icon khi menu được mở */
.hamburger-menu.open .bar:nth-child(1) {
  transform: rotate(-45deg) translate(-5px, 6px);
}
.hamburger-menu.open .bar:nth-child(2) {
  opacity: 0;
}
.hamburger-menu.open .bar:nth-child(3) {
  transform: rotate(45deg) translate(-5px, -6px);
}

/* Responsive adjustments for mobile */
@media (max-width: 768px) {
    .main-content {
        flex-direction: column;
    }

    .voucher-content {
        flex-direction: column;
    }

    .voucher-image {
        width: 100%;
    }

    .sidebar {
        display: none;
    }

    .post-media-grid {
        grid-template-columns: 2fr;
    }

    .blog-post-item {
        display: block !important;
    }
    .hamburger-menu {
        display: block;
    }
  
    .main-nav {
        display: none; /* Ẩn toàn bộ nav bar */
        flex-direction: column;
        position: fixed;
        top: 0;
        left: 0;
        width: 100%;
        height: 100%;
        background-color: var(--light-color);
        padding-top: 80px;
        z-index: 999;
        align-items: center;
        justify-content: flex-start;
        box-shadow: none;
    }

    .main-nav.open {
        display: flex; /* Hiển thị nav bar khi có class 'open' */
    }

    .main-nav ul {
        flex-direction: column;
        text-align: center;
        width: 100%;
    }

    .main-nav li {
        margin: 15px 0;
    }

    .main-nav a {
        font-size: 1.5rem;
    }
}

