
* {
  box-sizing: border-box;
}

html {
  background-color: #111038;
}

body {
  margin: 0;
  font-family: Arial, sans-serif;
  background-color: #111038;
  color: #ffffff;
}

/* TOP BAR */
.top-bar {
  background-color: #0b0a24;
  color: #ffffff;
  padding: 10px 30px;
  font-size: 13px;
  display: flex;
  justify-content: space-between;
  align-items: center;
  border-bottom: 1px solid #2a2a50;
  position: relative;
  z-index: 9999 ;      /* Số cực lớn để nổi lên trên cùng */
  overflow: visible ;
  gap:15px;
}

.top-bar a {
  color: #ffffff;
  text-decoration: none;
  transition: color 0.3s;
 
}

.top-bar a:hover {
  color: #FF7E00;
  /* Hover chuyển sang màu logo */
}

.top-bar i {
  color: #FF7E00;
  /* Icon màu logo */
  margin-right: 5px;
}

.top-bar .divider {
  margin: 0 10px;
  color: #ccc;
}
.user-actions {
    display: flex ;      /* Bắt buộc xếp ngang hàng */
    align-items: center ; /* Căn giữa theo chiều dọc */
    gap: 20px;            /* Khoảng cách giữa chữ 'Giỏ hàng' và 'Tài khoản' */
}
.user-actions a, 
.user-actions span {
    display: flex ;
    align-items: center;
    gap: 5px;                  /* Khoảng cách giữa Icon và Chữ */
    text-decoration: none;
}
/* HEADER */
.header {
  background-color: #111038;
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding: 15px 30px;
  border-bottom: 1px solid #2a2a50;
  gap: 20px;
  position: relative ;
  z-index: 500 ;  
}
  


.logo {
  display: flex;
  align-items: center;
  gap: 10px;
  font-size: 26px;
  color: #d75a7c;
  font-weight: bold;
  flex-shrink: 0;
}

.social-icons i {
  font-size: 22px;
  margin-right: 12px;
  cursor: pointer;
}

.search-box {
  display: flex;
  align-items: center;
  border: 1px solid #ccc;
  border-radius: 25px;
  padding: 5px 20px;
  /* Tăng padding trái phải từ 10px lên 20px cho rộng rãi */
  overflow: hidden;
  background: #fff;
  /* Đảm bảo nền trắng */
  width: 300px;
  /* Cố định chiều rộng để không bị co giãn lung tung */
}

.search-box input {
  border: none;
  outline: none;
  padding: 6px;
  flex: 1;
  /* Để ô nhập chiếm hết khoảng trống còn lại */
  font-size: 14px;
}

.search-box button {
  /* Style cho nút kính lúp */
  background: #d75a7c;
  border: none;
  color: white;
  padding: 0 20px;
  height: 100%;
  cursor: pointer;
  font-size: 16px;
  transition: 0.3s;
}

.search-box button:hover {
  background: #c04060;
}

/* MENU */
nav {
  background: #111038;
  border-bottom: 1px solid #2a2a50;
  position: sticky;
  /* cố định khi trượt */
  top: 0;
  /* Dính chặt vào đỉnh màn hình */
  z-index: 9999;
  /* Đảm bảo menu luôn nổi lên trên các ảnh/banner khác */
}
.menu {
    position: sticky ;
    z-index: 100 ;       /* Số nhỏ nhất */
}
.menu ul {
  margin: 0;
  padding: 0;
  list-style: none;
  display: flex;
  justify-content: center;
  align-items: center;
  gap: 50px;
  padding: 10px 0;
}

.menu-item {
  position: relative;
  font-size: 16px;
  text-transform: uppercase;
  font-weight: 600;
  color: #ffffff;
  cursor: pointer;
}

.menu-item:hover,
.menu-item:hover>a {
  color: #FF7E00;
}

.menu-item a {
  text-decoration: none;
  color: inherit;
  padding: 12px 5px;
  display: inline-block;
  
}

.menu-arrow {
  margin-left: 5px;
  font-size: 12px;
}

/* dropdown submenu */
.submenu {
  display: none;
  position: absolute;
  top: 100%;
  left: 0;
  background: #1a1a40;
  min-width: 170px;
  border: 1px solid #FF7E00;
  border-radius: 6px;
  box-shadow: 0 4px 8px rgba(0, 0, 0, 0.1);
  overflow: hidden;
}

.submenu a {
  display: block;
  padding: 10px 14px;
  font-size: 14px;
  text-transform: none;
  color: #fff;
  border-bottom: 1px solid #2a2a50;
  font-family: Arial, sans-serif;
}

.submenu a:hover {
  background: #FF7E00;
  color: #fff;
}

.menu-item:hover .submenu {
  display: block;
}

/* mở submenu bằng click trên PC/mobile */
.menu-item.open .submenu {
  display: block;
}

/* --- BỘ LỌC & DANH MỤC --- */
.container {
  display: flex;
  margin: 30px;
}

.filter-box {
  width: 220px;
  background: #1a1a40;
  padding: 15px;
  border-radius: 8px;
  height: fit-content;
  border: 1px solid #FF7E00;
  color: #fff;
}

.filter-box h3 {
  color: #FF7E00;
  margin-top: 0;
  border-bottom: 1px solid #FF7E00;
  padding-bottom: 10px;
  font-size: 16px;
}

.filter-box label {
  display: block;
  margin: 10px 0;
  font-size: 14px;
  cursor: pointer;
}

/* --- DANH SÁCH SẢN PHẨM & HOVER EFFECT --- */
.product-area {
  flex: 1;
  display: flex;
  flex-wrap: wrap;
  justify-content: flex-start;
  gap: 20px;
}

.product {
  background: #1a1a40;
  color: white;
  border: 1px solid #2a2a50; /* Viền mờ mặc định */
  padding: 10px;
  width: calc(25% - 20px);
  text-align: center;
  border-radius: 8px;
  box-sizing: border-box;
  /* không bị vỡ khung */
  margin-bottom: 20px;
  /* Thêm khoảng cách dưới */

  /* --- Thêm hiệu ứng chuyển động mượt --- */
  transition: all 0.4s ease;
  overflow: hidden; /* Để ảnh zoom không tràn ra ngoài */
}

/* Hiệu ứng Hover vào thẻ: Nổi lên & Viền cam */
.product:hover {
  transform: translateY(-5px);
  border-color: #FF7E00;
  box-shadow: 0 8px 20px rgba(255, 126, 0, 0.3);
}

.product a {
  display: block;
  overflow: hidden; /* Bao quanh ảnh để zoom đẹp */
  border-radius: 6px;
}

.product img {
  width: 100%;
  height: 200px;
  object-fit: cover;
  border-radius: 6px;
  /* --- Hiệu ứng zoom ảnh mượt --- */
  transition: transform 0.5s ease;
}

/* Hiệu ứng Hover vào ảnh: Phóng to */
.product:hover img {
  transform: scale(1.1);
}

.btn {
  background-color: #FF7E00;
  border: 1px solid #FF7E00;
  color: white;
  padding: 6px 12px;
  cursor: pointer;
  border-radius: 5px;
  transition: 0.3s;
}

/* Hiệu ứng Hover nút: Nền trắng chữ cam */
.btn:hover {
  background-color: #ffffff;
  color: #FF7E00;
  border: 1px solid #FF7E00;
}

/* --- FOOTER --- */
.flower-footer {
  background-color: #0b0a24;
  /* Nền xanh rất đậm (tối hơn nền body) để tạo chiều sâu */
  color: #b0b0b0;
  /* Chữ màu xám bạc sáng -> Dễ đọc trên nền tối */
  padding: 50px 50px 20px;
  border-top: 3px solid #FF7E00;
  /* Viền trên màu Cam đậm làm điểm nhấn */
  margin-top: auto;
}

.footer-container {
  display: flex;
  justify-content: space-between;
  flex-wrap: wrap;
  gap: 30px;
  max-width: 1200px;
  margin: 0 auto;
}

/* Tiêu đề cột (Liên hệ, Chính sách...) */
.footer-column h3,
.footer-follow h4 {
  font-size: 16px;
  color: #FF7E00;
  /* Màu Cam chủ đạo */
  margin-bottom: 20px;
  text-transform: uppercase;
  font-weight: 700;
  letter-spacing: 1px;
  position: relative;
  padding-bottom: 10px;
  border: none;
  /* Xóa gạch chân dài cũ */
}

/* Tạo gạch chân ngắn tinh tế dưới tiêu đề */
.footer-column h3::after,
.footer-follow h4::after {
  content: "";
  position: absolute;
  left: 0;
  bottom: 0;
  width: 40px;
  /* Chỉ dài 40px thôi */
  height: 3px;
  background-color: #FF7E00;
  border-radius: 2px;
}

.footer-column ul,
.footer-follow ul {
  list-style: none;
  padding: 0;
  margin: 0;
}

.footer-column li,
.footer-follow li {
  margin-bottom: 12px;
  /* Tăng khoảng cách dòng cho thoáng */
  font-size: 14px;
  display: flex;
  align-items: center;
  gap: 10px;
}

/* Link trong footer */
.footer-column a,
.footer-follow a {
  text-decoration: none;
  color: #b0b0b0;
  /* Màu xám bạc */
  transition: all 0.3s ease;
}

/* Hiệu ứng khi di chuột vào link */
.footer-column a:hover,
.footer-follow a:hover {
  color: #FF7E00;
  /* Sáng màu cam lên */
  padding-left: 5px;
  /* Dịch chuyển nhẹ sang phải */
}

/* Icon mạng xã hội/liên hệ */
.footer-column i,
.footer-follow i {
  color: #FF7E00;
  width: 20px;
  /* Cố định chiều rộng để thẳng hàng */
}

/* Dòng bản quyền dưới cùng */
.footer-bottom {
  text-align: center;
  border-top: 1px solid #2a2a50;
  /* Đường kẻ mờ, tinh tế */
  margin-top: 40px;
  padding-top: 20px;
  font-size: 13px;
  color: #666;
  /* Màu tối hơn chút để không tranh chấp với nội dung chính */
}

@media (max-width: 992px) {
  .footer-container {
    flex-direction: column;
    align-items: center;
    text-align: center;
  }

  .footer-column h3::after,
  .footer-follow h4::after {
    left: 50%;
    transform: translateX(-50%);
  }
}

.banner-container {
  position: relative;
  width: 100%;
  max-height: 430px;
  overflow: hidden;
  margin-bottom: 20px;
}

.banner-slide {
  display: none;
}

.banner-slide img {
  width: 100%;
  height: 430px;
  object-fit: cover;
  border-radius: 5px;
}

.prev,
.next {
  cursor: pointer;
  position: absolute;
  top: 50%;
  transform: translateY(-50%);
  padding: 10px 15px;
  color: white;
  font-size: 24px;
  font-weight: bold;
  transition: 0.3s;
  user-select: none;
  background-color: rgba(0, 0, 0, 0.3);
  border-radius: 50%;
}

.prev:hover,
.next:hover {
  background-color: rgba(0, 0, 0, 0.6);
}

.prev {
  left: 15px;
}

.next {
  right: 15px;
}

.fade {
  animation-name: fade;
  animation-duration: 1s;
}

@keyframes fade {
  from {
    opacity: 0.4;
  }

  to {
    opacity: 1;
  }
}


/* Tablet (768px → 1023px) */
@media (min-width: 768px) and (max-width: 1023px) {
  nav {
    width: 30%;
    /* menu chiếm 1 phần */
  }

  main {
    width: 70%;
    /* phần main lớn hơn */
  }

  aside {
    width: 100%;
    /* sidebar xuống dưới */
  }
}

/* Mobile (≤767px) */

@media (max-width: 768px) {

  .top-bar {
        padding: 10px 15px; /* Giảm khoảng cách cho gọn */
    }
    .user-actions a, 
    .user-actions span {
        font-size: 0; /* Mẹo: Ẩn chữ về size 0 */
    }

    .user-actions i {
        font-size: 15px; /* Tăng kích thước Icon lên cho dễ bấm */
        color: #FF7E00;
        margin: 0 10px;  /* Cách xa nhau ra chút */
    }
  /* 1. HEADER: Logo và Tìm kiếm xếp dọc */
  .header {
    flex-direction: column;
    /* Xếp chồng lên nhau */
    align-items: stretch;
    /* Kéo dãn ra 2 bên */
    height: auto;
    /* Chiều cao tự động */
    padding: 15px;
    gap: 15px;
  }

  .logo {
    justify-content: center;
    /* Logo căn giữa */
    margin-bottom: 5px;
  }

  .search-box {
    width: 100% !important;
    /* Bắt buộc full màn hình */
    max-width: none;
    /* Bỏ giới hạn chiều rộng */
    margin: 0;
  }

  /* 2. MENU: Các mục tự xuống dòng nếu chật */
  .menu ul {
    flex-wrap: wrap;
    gap: 10px;
    padding: 5px 0;
  }

  .menu-item {
    font-size: 13px;
    /* Chữ nhỏ lại xíu cho vừa */
  }

  /* 3. KHUNG CHÍNH: Bộ lọc trên, Sản phẩm dưới */
  .container {
    flex-direction: column;
    margin: 15px;
    width: auto;
    /* Tự động theo màn hình */
  }

  /* 4. BỘ LỌC: Full chiều ngang */
  .filter-box {
    width: 100%;
    margin-bottom: 20px;
  }

  /* 5. DANH SÁCH SẢN PHẨM: 2 Cột */
  .product-area {
    justify-content: space-between;
    /* Đẩy ra 2 mép */
    gap: 10px;
  }

  .product {
    width: 48%;
    /* Để 48% thay vì 50% để trừ hao khoảng cách gap, tránh rớt dòng */
    margin-bottom: 10px;
  }

  /* 6. VOUCHER & FOOTER */
  div[style*="display:flex; justify-content:center"] {
    flex-wrap: wrap;
    /* Cho phép voucher xuống dòng */
  }

  .footer-container {
    flex-direction: column;
    text-align: center;
  }

  .footer-column,
  .footer-follow {
    width: 100%;
    /* Chiếm hết chiều ngang */
    margin-bottom: 20px;
  }

  .footer-column h3::after,
  .footer-follow h4::after {
    left: 50%;
    transform: translateX(-50%);
    /* Căn giữa gạch chân */
    
  }
}
    /* CSS cho menu thả xuống (Dùng chung cho cả Guest và User) */
    .custom-dropdown {
        display: none; /* Mặc định ẩn */
        position: absolute;
        top: 30px; /* Cách top bar 1 đoạn */
        right: 0;
        background-color: #1a1a40; 
        box-shadow: 0 4px 8px rgba(0,0,0,0.2);
        border-radius: 4px;
        min-width: 150px;
        padding: 0;
        list-style: none;
        z-index: 9999;
    }

    .custom-dropdown li {
        border-bottom: 1px solid #1a1a40;
    }
    .custom-dropdown li:last-child { border-bottom: none; }

    .custom-dropdown li a {
        display: block;
        padding: 10px 15px;
        color: white; /* Chữ trắng */
        text-decoration: none;
        font-size: 14px;
    }

    .custom-dropdown li a:hover {
        background-color: rgba(255,255,255,0.1); /* Hiệu ứng khi di chuột */
    }

    /* Mũi tên nhỏ chỉ lên trên (Trang trí) */
    .custom-dropdown::before {
        content: "";
        position: absolute;
        top: -6px;
        right: 20px;
        border-left: 6px solid transparent;
        border-right: 6px solid transparent;
        border-bottom: 6px solid #1a1a40;
    }