/* ===== BODY ===== */
body {
  font-family: 'Poppins', sans-serif;
    background:#f0f2f5;
    margin:0;
  }
  
  /* ===== HEADER ===== */
  .header{
    background:linear-gradient(135deg,#fcf9f9,#fcf9f9);
    color:white;
    padding:0 60px;
    height:110px;
    display:flex;
    align-items:center;
    justify-content:space-between;
    box-shadow:0 4px 12px rgba(0,0,0,0.2);
  }
  /* mau gio hang */
  .header a{
    display:flex;
    align-items:center;
    gap:5px;
    text-decoration:none;
    color:rgb(71, 125, 71); 
    
  }
  .header img{
    width: 200px;
    height: auto;
    object-fit:contain;
    padding:5px;
  }
  .header h1{
    font-size:24px;
    margin:0;
  }
  .header-left {
    position: relative;
    display: flex;
    align-items: center;   /* căn giữa theo chiều dọc */
    gap: 10px;             /* khoảng cách giữa logo và input */
  }
  
  .header-left .logo {
    height: 200px;          /* kích thước logo */
  }
  /* ===== SEARCH POPUP ===== */
  .title-highlight{
    text-align:center;
    margin-top:20px;
    color:#2e7d32;
    font-size:28px;
    font-weight:600;
    }
/* ===== SEARCH ===== */

.header-left {
  position: relative; /* để popup position:absolute đúng */
}
#searchInput{
  width:400px;
  max-width:100%;
  padding:10px 20px;
  border-radius:6px;
  border:1px solid #08701d;
}

/* popup search */
#searchResults {
  position: absolute;
  top: calc(100% + 2px); /* cách mép dưới input 2px */
  left: 0;
  width: 100%;           /* vừa với input */
  background: #5e9d7d;
  border: 1px solid #ddd;
  border-radius: 6px;
  box-shadow: 0 4px 10px rgba(248, 250, 248, 0.15);
  max-height: 250px;
  overflow-y: auto;
  display: none;
  z-index: 9999;
}

/* item */
#searchResults div{
  
  padding:10px;
  cursor:pointer;
  border-bottom:1px solid #eee;
}

#searchResults div:hover{
  background:#f5f5f5;
}
  
  
  /* ===== LOGIN BUTTON ===== */
 /* ===== HEADER RIGHT: LOGIN + CART ===== */


/* số lượng trên giỏ hàng */
.cart-count {
  position: absolute;
  top: -8px;
  right: -10px;
  background: rgb(191, 5, 5);
  color: white;
  font-size: 12px;   /* đồng bộ với icon */
  width: 18px;
  height: 18px;
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
}


  /* ===== LOGIN POPUP ===== */
  #authPopup{
    display:none;
    position:fixed;
    top:50%;
    left:50%;
    transform:translate(-50%,-50%);
    background:white;
    padding:25px;
    border-radius:12px;
    box-shadow:0 10px 30px rgba(0,0,0,0.3);
    width:300px;
    z-index:1000;
  }
  #authPopup h3{
    text-align:center;
    margin-bottom:15px;
    color:#2e7d32;
  }
  #authPopup input{
    width:100%;
    padding:8px;
    margin:8px 0;
    border-radius:8px;
    border:1px solid #ccc;
  }
  #authPopup button{
    width:48%;
    padding:8px;
    border:none;
    border-radius:8px;
    font-weight:bold;
    cursor:pointer;
  }
  #authPopup button:first-child{
    background:#2e7d32;
    color:white;
    margin-right:4%;
  }
  #authPopup button:last-child{
    background:#999;
    color:white;
  }
  
  
  /* ===== NAVBAR ===== */
  
nav{
  display:flex;
  justify-content:center;
  align-items:center;
  gap:35px;
  background:#ffffff;
  padding:14px 20px;
  border-bottom:1px solid #eee;
  box-shadow:0 2px 6px rgba(0,0,0,0.05);
  flex-wrap:wrap;
  }
  
  /* menu item */
  nav a{
  display:flex;
  flex-direction:column;
  align-items:center;
  justify-content:center;
  text-decoration:none;
  color:#2e7d32;
  font-size:18px;
  font-weight:500;
  gap:6px;
  padding:8px 6px;
  transition:all .25s ease;
  position:relative;
  }
  
  /* icon */
  nav a img{
  width:52px;
  height:52px;
  object-fit:cover;
  border-radius:50%;
  background:#f6f6f6;
  padding:6px;
  transition:all .25s ease;
  }
  
  /* text */
  nav a span{
  font-size:13px;
  }
  
  /* hover */
  nav a:hover img{
  background:#4CAF50;
  transform:scale(1.08);
  box-shadow:0 4px 10px rgba(0,0,0,0.15);
  }
  
  nav a:hover{
  color:#4CAF50;
  }
  
  /* admin link */
  #adminOrdersLink{
  font-weight:600;
  color:#e53935;
  }

  /* ===== PRODUCT GRID ===== */
  .grid{
    display:grid;
    grid-template-columns: repeat(7, 1fr); /* PC 4 sản phẩm */
    gap:20px;
    padding:20px;
    margin:0 20px;
  }
  /* chỉ nút mua ngay */
  button.buy-now {
    background: #c53b09 !important; /* đỏ cam */
    color: white !important;
  }
  
  button.buy-now:hover {
    background: #ff6347 !important; /* đỏ cam sáng hơn khi hover */
    transform: translateY(-2px);
    box-shadow: 0 6px 12px rgba(0,0,0,0.2);
  }
  /* ===== CARD ===== */
  /* Container scroll ngang */
#highlight, #saleProducts {
  position: relative;
    border: 1px solid #ddd;
    border-radius: 8px;
    padding: 10px;
    background: #fff;
    text-align: center;
    transition: transform 0.2s; /* mượt trên mobile */
}

/* Card */
.card {
  flex: 0 0 52%;       /* chiếm 52% width container → card to hơn */
  min-width: 52%;      /* đảm bảo card không co quá nhỏ */
  background: white;
  border-radius: 15px;
  overflow: hidden;
  box-shadow: 0 4px 15px rgba(0,0,0,0.15);
  display: flex;
  flex-direction: column;
  transition: 0.3s;
}


.card:hover {
  transform: translateY(-8px) scale(1.03);
}

/* Card image */
.card img {
  width: 100%;
  height: 260px;
  object-fit: cover;
  
}

/* Card content */
.card-price{
  font-size:18px;
  font-weight:700;
  color:#070101;
  margin-top:auto;
}

.card-price .price{
  color:#333;
  font-weight:600;
}

.card-price .sale-price{
  color:#e53935;
  font-weight:700;
  font-size:18px;
}

.card-price .old-price{
  color:#999;
  text-decoration:line-through;
  font-size:14px;
}
/*  */
.card-content{
  display:flex;
  flex-direction:column;
  justify-content:space-between; /* chia đều khoảng */
  align-items:center; /* căn giữa ngang */
  text-align:center;
  padding:12px;
  flex:1;
}

.card-content h3 {
  color: #2e7d32;
  margin: 8px 0;
}

.card-content button {
  margin-top: auto;
  padding: 10px;
  border: none;
  border-radius: 8px;
  background: linear-gradient(135deg,#66bb6a,#2e7d32);
  color: white;
  cursor: pointer;
}
/* ===== BANNER ===== */
.banner-container{
  width:90%;
  max-width:1200px;
  margin:auto;
  border-radius:12px;
  overflow:hidden;
  box-shadow:0 4px 12px rgba(0,0,0,0.2);
}

/* slider */
.banner-slider{
  position:relative;
  width:100%;
  height:600px;
  overflow:hidden;
}

/* slides */
.banner-slider .slides{
  display:flex;
  height:100%;
  transition:transform 0.5s ease;
}

/* mỗi slide */
.banner-slider .slides > div{
  flex:0 0 100%;      /* QUAN TRỌNG */
  width:100%;
  height:100%;
  position:relative;
}

/* image */
.banner-slider .slides img{
  width:100%;
  height:100%;
  object-fit:cover;
  object-position:center;
  display:block;
}

/* nút prev next */
.banner-slider button.prev,
.banner-slider button.next{
  position:absolute;
  top:50%;
  transform:translateY(-50%);
  background:rgba(0,0,0,0.4);
  color:#fff;
  border:none;
  padding:10px 15px;
  cursor:pointer;
  border-radius:4px;
  font-size:22px;
  z-index:10;
}

.banner-slider button.prev{ left:10px; }
.banner-slider button.next{ right:10px; }

.banner-slider button.prev:hover,
.banner-slider button.next:hover{
  background:rgba(0,0,0,0.6);
}

/* dots */
#bannerDots{
  text-align:center;
  margin-top:10px;
}

#bannerDots span{
  display:inline-block;
  width:10px;
  height:10px;
  border-radius:50%;
  background:#ccc;
  margin:0 5px;
  cursor:pointer;
}

#bannerDots span.active{
  background:#333;
}
  /* ===== ADMIN ===== */
  .admin{
    background:white;
    padding:25px;
    margin:40px auto;
    text-align:center;
    border-radius:15px;
    box-shadow:0 5px 20px rgba(0,0,0,0.2);
    max-width:450px;
    display:none;
  }
  .admin input,
  .admin select,
  .admin button{
    width:90%;
    padding:10px;
    margin:10px 0;
    border-radius:8px;
    border:1px solid #ccc;
  }
  
  /* ===== FOOTER ===== */
  .footer {
    background: #f5f5f5;
    padding: 40px 20px 20px;
    font-family: 'Outfit', sans-serif;
    color: #333;
    box-sizing: border-box;
  }
  
  .footer-container {
    display: flex;
    flex-wrap: wrap;
    justify-content: space-between;
    gap: 40px;
    max-width: 1200px; /* căn giữa PC */
    margin: 0 auto;
  }
  
  .footer-col {
    flex: 1 1 250px; /* cố định cột tối thiểu 250px */
    min-width: 200px; /* tránh bị quá nhỏ */
  }
  
  .footer-col h3 {
    margin-bottom: 12px;
    font-size: 16px;
    color: #3adb1e;
  }
  
  .footer-col p {
    margin: 6px 0;
    font-size: 14px;
    color: #555;
  }
  
  .footer-col .social {
    display: flex;
    gap: 10px;
    margin-top: 10px;
  }
  
  .footer-col .social a img {
    width: 28px;
    height: 28px;
    object-fit: cover;
    display: block;
  }
  
  /* FOOTER BOTTOM */
  .footer-bottom {
    border-top: 1px solid #ddd;
    margin-top: 20px;
    padding-top: 12px;
    text-align: center;
    font-size: 13px;
    color: #555;
    display: flex;
    flex-direction: column;
    gap: 4px;
    align-items: center;
  }
  

  .search-box button{
  border:none;
  background:#2e7d32;
  color:white;
  padding:8px 14px;
  cursor:pointer;
  font-size:14px;
  transition:0.2s;
  }
  
  .search-box button:hover{
  background:#1b5e20;
  }
  /* Search dropdown */


#searchResults div {
  padding: 10px;
  cursor: pointer;
}

#searchResults div:hover,
#searchResults div.active {
  background-color: #66bb6a; /* xanh nhạt giống màu header */
  color: white;              /* chữ trắng nổi bật khi hover */
}
 /* ===== MOBILE ===== */

/* ===== MOBILE STYLES (≤768px) ===== */
@media (max-width:768px){

  .banner-container{
    width:100%;
    overflow:hidden;
  }

  .banner-slider{
    width:100%;
    height:220px;
    overflow:hidden;
    position:relative;
    background:#f5f5f5; /* tránh trắng */
  }

  /* CHỈ DÙNG FLEX + TRANSFORM (theo JS của bạn) */
  .banner-slider .slides{
    display:flex;
    width:100%;
    height:100%;
    transition: transform 0.5s ease;
  }

  .banner-slider .slides > div{
    flex:0 0 100%;
    width:100%;
    height:100%;
  }

  .banner-slider .slides img{
    width:100%;
    height:100%;
    object-fit:cover;
    display:block;
  }

  .banner-slider .next,
  .banner-slider .prev{
    display:none;
  }
}
/* ===== MOBILE STYLES (≤768px) ===== */
/* ===== MOBILE BANNER (≤768px) ===== */
@media (max-width:768px){

  .banner-container{
    width:100%;
    overflow:hidden;
  }

  .banner-slider{
    width:100%;
    height:220px;
    overflow:hidden;
    position:relative;
  }

  /* container slide */
  .banner-slider .slides{
    display:flex;
    width:100%;
    height:100%;

    /* overflow-x:auto;
    scroll-snap-type:x mandatory;
    scroll-behavior:smooth;

    -webkit-overflow-scrolling:touch; */
  }

  /* mỗi banner */
  .banner-slider .slides > div{
    flex:0 0 100%;
    width:100%;
    height:100%;
    scroll-snap-align:start;
  }

  /* ảnh banner */
  .banner-slider .slides img{
    width:100%;
    height:100%;
    object-fit:cover;
    display:block;
  }

  /* ẩn scrollbar */
  .banner-slider .slides::-webkit-scrollbar{
    display:none;
  }

 /* ẩn nút next + prev trên điện thoại */
 .banner-slider .next,
 .banner-slider .prev{
   display: none;
 }
  

  .grid{
    grid-template-columns: repeat(2,1fr);
    gap:12px;
    
  }


  .card img{
    height:200px;
    border-radius:10px;
   
  }

  .card-content{
    padding:8px;
  }

  .card-content h3{
    font-size:14px;
    margin:4px 0;
  }

  .card-content button{
    padding:6px;
    font-size:13px;
    
  }
  .card-price{
    font-size:15px;
    font-weight:700;
    color:#070101;
    margin-top:auto;
  }
}

  


 
/* //mobile */
@media (max-width:768px){
  /* Giỏ hàng */
  .header-right .cart-icon {
    font-size: 24px;
  }
  .header-right .cart-icon .cart-count {
    width: 16px;
    height: 16px;
    font-size: 10px;
    top: -6px;
    right: -6px;
  }

 
}
@media (max-width:768px){
  /* HEADER nhỏ gọn: logo + title + search cùng hàng */
  .header {
    
    flex-direction: row;
    align-items: center;
    justify-content: space-between;
    padding: 8px 12px;
    height: 60px;
    gap: 8px;
  }
   /* Logo */
   .header img{
    width: 100px;      /* logo vừa nhìn rõ */
    height: auto;
  }
  .header h1 {
    font-size: 10px;
    margin: 0;
    flex: 1;
    text-align: left;
  }

  /* Giỏ hàng */
  .cart-icon {
    font-size: 18px;  /* nhỏ lại, không lấn header */
  }
  /* HEADER MOBILE */
.header-left {
  flex: 1;
  display: flex;
  align-items: center;
  gap: 4px;
  transform: translateX(-20px); 
}

#searchInput {
  flex: 1;
  max-width: 245px;  /* giới hạn chiều rộng */
  min-width: 120px;  /* tránh quá nhỏ */
  padding: 10px 10px;
  font-size: 14px;
  border-radius: 6px;
  transform: translateX(-30px); 
}

@media (max-width:768px){
  nav{
    display: flex;
    flex-wrap: nowrap;           /* không xuống dòng */
    overflow-x: auto;            /* cho phép kéo ngang */
    -webkit-overflow-scrolling: touch;
    gap: 8px;
    padding: 8px;
    margin: 10px;
    background: #ffffff;
    border: 2px solid #b8c9b9;
    border-radius: 12px;
    justify-content: flex-start; /* canh trái */
  }

  nav a {
    flex: 0 0 auto;              /* không co giãn */
    width: 70px;                 /* giữ kích thước cũ */
    height: 40px;                /* chiều cao nhỏ hơn */
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    text-align: center;
    background: #66bb6a;
    color: white;
    border-radius: 8px;
    font-size: 11px;
    line-height: 1.2;
    padding: 2px;
    white-space: normal;
    word-break: break-word;
  }

  nav a img {
    width: 24px;
    height: 24px;
    margin-bottom: 2px;
  }

  nav a span {
    font-size: 10px;
    line-height: 1.1;
  }

  /* ẩn thanh cuộn cho đẹp */
  nav::-webkit-scrollbar {
    display: none;
  }
}
}




  /* SEARCH BOX */
  .search-box input{
    font-size:16px;
    padding:10px 12px;
    width:100%;
    max-width:250px; 
  }
  .search-box button{
    padding:10px 14px;
    font-size:16px;
  }
  

/* ==== SỐ LƯỢNG THÊM GIỎ HÀNG ==== */
.cart-qty {
  display: flex;
  align-items: center;
  gap: 8px;
  margin: 12px 0;
}

.cart-qty button {
  width: 32px;
  height: 32px;
  font-size: 18px;
  font-weight: bold;
  border: none;
  background: #66bb6a;
  color: white;
  border-radius: 6px;
  cursor: pointer;
}

.cart-qty button:hover { background: #2e7d32; }

#qtyInput {
  width: 35px;
  height: 35px;
  border: 1px solid #000c01;
  background: white;
  color: #000c01;
  font-size: 18px;
  cursor: pointer;
  padding: 0;
  display: flex;
  align-items: center;
  justify-content: center;
}

  /* ADMIN */
  .admin input,
  .admin select,
  .admin button{
    width:95%;
    padding:12px;
    font-size:16px;
  }

.search-item{
  display:flex;
  align-items:center;
  gap:10px;
  padding:8px;
  cursor:pointer;
}

.search-item img{
  width:35px;
  height:35px;
  object-fit:cover;
  border-radius:6px;
}

.search-item:hover{
  background:#f2f2f2;
}
/* thêm */
#floatingBtn {
  position: fixed;
  bottom: 20px;
  right: 20px;
  width: 60px;
  height: 60px;
  border-radius:60px;
  overflow: hidden;
  box-shadow: 0 4px 8px rgba(0,0,0,0.2);
  z-index: 9999;
  cursor: pointer;
  transition: transform 0.3s ease;
}
#floatingBtn img { width:100%; height:100%; object-fit:cover; }
#floatingBtn:hover { transform: scale(1.1); }

#contactPopup {
  position: fixed;
  bottom: 90px;
  right: 20px;
  display: none;
  flex-direction: column;
  gap: 10px;
  z-index: 9999;
}
#contactPopup a {
  width:50px;
  height:50px;
  display:flex;
  align-items:center;
  justify-content:center;
  border-radius:50%;
  overflow:hidden;
  background:white;
  box-shadow:0 4px 8px rgba(0,0,0,0.2);
}


#contactPopup a img { width:100%; height:100%; object-fit:cover; }
#contactPopup a:hover { transform: scale(1.1); }
/* icon giỏ hàng */
.cart-icon{
  position:relative;
  font-size:40px;
  color:#12ac4d;
  text-decoration:none;
  }
  
  .cart-count{
  position:absolute;
  top:-8px;
  right:-10px;
  background:rgb(191, 5, 5);
  color:white;
  font-size:11px;
  width:18px;
  height:18px;
  border-radius:50%;
  display:flex;
  align-items:center;
  justify-content:center;
  }
  body{
    font-family:'Outfit', sans-serif;
    }
    
    h1,h2,h3{
    font-weight:600;
    }
    
    button{
    font-family:'Poppins',sans-serif;
    font-weight:500;
    background: #66bb6a;
    
    color:white;
    padding:12px 20px;
    border:none;
    border-radius:6px;
    cursor:pointer;
    font-size:16px;
    
    }
    button{
      font-family:'Poppins',sans-serif;
      font-weight:500;
      background:#66bb6a;
      color:white;
      padding:12px 20px;
      border:none;
      border-radius:6px;
      cursor:pointer;
      font-size:16px;
      transition: all 0.25s ease;
    }
    
    /* hiệu ứng khi rê chuột */
    button:hover{
      background:#4caf50;
      transform: translateY(-3px);
      box-shadow:0 6px 12px rgba(0,0,0,0.25);
    }
    
    /* hiệu ứng khi bấm */
    button:active{
      transform: translateY(0);
      box-shadow:0 2px 5px rgba(0,0,0,0.2);
    }
    
    /* FOOTER */
.footer{
  background:#ffffff;
  padding:30px 40px;   /* giảm chiều cao footer */
  font-size:14px;
  }
  
  /* layout cột */
  .footer-container{
  display:grid;
  grid-template-columns:repeat(3,1fr);
  gap:40px;
  max-width:1100px;
  margin:auto;
  }
  
  /* cột footer */
  .footer-col{
  display:flex;
  flex-direction:column;
  align-items:center;
  text-align:center;
  }
  
  /* tiêu đề */
  .footer-col h3{
  margin:0 0 8px 0;
  font-size:16px;
  color:#0fd233;
  }
  
  /* nội dung */
  .footer-col p{
  margin:4px 0;
  color:#333;
  font-size:14px;
  }
  
  /* icon mạng xã hội */
  .social{
  display:flex;
  justify-content:center;
  gap:8px;       /* icon gần nhau hơn */
  margin-top:6px;
  }
  
  .social img{
  width:28px;    /* icon nhỏ lại */
  height:28px;
  cursor:pointer;
  transition:0.25s;
  }
  
  .social img:hover{
  transform:scale(1.15);
  }
  
  /* dòng dưới cùng */
  .footer-bottom{
  text-align:center;
  padding-top:12px;
  border-top:1px solid #ddd;
  margin-top:20px;
  font-size:13px;
  color:#555;
  }
/* ===== MOBILE ===== */
.category-title{
  text-align:center;
  margin-top:20px;
  }
  
  .category-text{
  color:#2e7d32;
  font-size:28px;
  font-weight:600;
  font-family:'Outfit', sans-serif;
  }
/* ===== MINI NAVBAR LOGIN ===== */
/* CSS chung cho các icon header */
/* HEADER CHUNG */
.header {
  overflow-y: hidden;  /* tắt scroll dọc */
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding: 10px 8px; /* giảm padding 2 bên để vừa màn hình */
  box-sizing: border-box;
  overflow-x: hidden; /* ngăn tràn ngang */
  width: 100%;
}

/* HEADER LEFT */
.header-left {
  display: flex;
  align-items: center;
  gap: 6px;          /* giảm gap giữa logo và search */
  flex: 1 1 auto;    /* co giãn theo chiều ngang */
  min-width: 0;      /* tránh search tràn */
}

/* SEARCH BOX */
.search-box {
  flex: 1 1 auto;
  min-width: 0;      /* cực quan trọng */
  position: relative;
}

.search-box input {
  width: 100%;
  box-sizing: border-box;
}

/* HEADER RIGHT */
.header-right {
  display: flex;
  align-items: center;
  gap: 6px;
  flex-shrink: 0; /* không bị co nhỏ */
}
/*  */
 /* Chỉnh Login / Logout + Giỏ hàng cùng size */
/* Login / Logout / Cart cùng size */
/* ===== LOGIN / LOGOUT / CART ===== */
.header-right {
  display: flex;
  align-items: center;
  gap: 12px;  /* khoảng cách giữa các nút */
}

/* Nút chung */
#loginBtn, #logoutBtn, .cart-icon {
  display: flex;
  align-items: center;
  justify-content: center;
  width: 50px;
  height: 50px;
  border-radius: 8px;
  background: #fff;
  box-shadow: 0 1px 4px rgba(0,0,0,0.1);
  cursor: pointer;
  transition: 0.3s;
}

/* Hover hiệu ứng */
#loginBtn:hover, #logoutBtn:hover, .cart-icon:hover {
  background: #e8f5e9;
  transform: translateY(-2px);
}

/* Icon */
#loginBtn i, #logoutBtn i, .cart-icon i {
  font-size: 24px;
  color: #4CAF50; /* màu xanh theme */
}

/* Cart count */
.cart-count {
  position: absolute;
  top: -5px;
  right: -5px;
  font-size: 12px;
  width: 18px;
  height: 18px;
  background: red;
  color: #fff;
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
}

/* Responsive mobile */
@media (max-width: 480px) {
  #loginBtn, #logoutBtn, .cart-icon {
    width: 40px;
    height: 40px;
  }

  #loginBtn i, #logoutBtn i, .cart-icon i {
    font-size: 20px;
  }

  .cart-count {
    font-size: 10px;
    width: 16px;
    height: 16px;
  }
 

}
@media (max-width: 480px) {
  .footer {
    padding: 15px 10px;       /* padding vừa đủ 2 bên */
    box-sizing: border-box;    /* cực quan trọng, để padding ko làm tràn */
    width: 100%;               /* chắc chắn không vượt màn hình */
    overflow-x: hidden;        /* phòng ngừa tràn ngang */
  }

  .footer-container {
    flex-direction: column;    /* xếp cột dọc trên mobile */
    gap: 10px;
    width: 100%;
  }

  .footer-col {
    width: 100%;               /* mỗi cột chiếm full width */
    min-width: 0;              /* tránh overflow do chữ dài */
  }

  .footer-bottom {
    font-size: 12px;
    padding: 0 10px;
    box-sizing: border-box;
  }
}

/*  */

/* MOBILE <480px */
@media (max-width: 480px) {
  .header-left {
    flex: 1 1 65%;   /* chiếm 65% */
  }
  .header-right {
    flex: 1 1 30%;   /* chiếm 30% */
    justify-content: flex-end;
  }
  .search-box input {
    font-size: 14px;
    padding: 5px 6px;
    
  }
  /* ===== Nút mua ngay + thêm giỏ cùng hàng ===== */
.btn-group {
  display: flex;
  gap: 10px;          /* khoảng cách giữa 2 nút */
  margin-top: auto;    /* đẩy xuống đáy card */
  flex-wrap: wrap;     /* xuống dòng nếu quá nhỏ */
}

/* nút Mua ngay */
button.buy-now {
  background: #ff4500 !important; 
  color: white !important;
  flex: 1;             /* chiếm đều hàng */
}

}
/* /* Ẩn nút Mua ngay trên điện thoại <=768px */
@media (max-width: 768px) {
  .buy-now {
    display: none !important;
  }}
/* Ẩn nút Mua ngay trên điện thoại <=768px

/* ===== MOBILE: 2 nút bằng nhau, căn giữa ===== */
/* ===== MOBILE: 2 nút bằng nhau và căn giữa ===== */
/* ===== MOBILE: 2 nút bằng nhau và căn giữa ===== */
@media (max-width: 768px) {
  /* nhóm 2 nút */
  .card-content .btn-group {
    display: flex !important;         /* dùng flex */
    justify-content: center !important; /* căn giữa nhóm */
    gap: 10px;                        /* khoảng cách giữa 2 nút */
    margin-top: 12px;
    width: 100%;
    flex-wrap: nowrap;                 /* không xuống dòng */
    box-sizing: border-box;
  }

  /* mỗi nút bằng nhau */
  .card-content .btn-group button {
    flex: 1 1 45% !important;         /* 2 nút bằng nhau */
    max-width: 150px;                  /* tối đa cho nút */
    min-width: 120px;                  /* tối thiểu */
    padding: 10px 0;
    text-align: center;
    font-size: 14px;
    border-radius: 8px;
    box-sizing: border-box;
  }
 
  /* màu nút */
  .card-content .btn-group .buy-now {
    background: #ff4500 !important;
    color: white !important;
  }

  .card-content .btn-group .add-cart {
    background: #2e7d32 !important;
    color: white !important;
  }
}