body {
    font-family: 'Roboto', sans-serif;
    margin: 0;
    padding: 0;
    background-color: #f0f0f0; /* Màu nền của trang */
    color: white; /* Màu chữ mặc định */
    line-height: 1.6; /* Khoảng cách giữa các dòng */
    font-size:14px;
}

a {
    color: white; /* Màu chữ cho liên kết */
    text-decoration: none; /* Bỏ gạch chân mặc định */
    transition: color 0.3s ease; /* Hiệu ứng chuyển màu khi hover */
}

a:hover {
    color: #0056b3; /* Màu chữ khi người dùng di chuột qua liên kết */
    text-decoration: underline; /* Gạch chân khi hover */
}
/* css cho grid*/
.grid-container {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(200px, 1fr));
    gap: 5px;
    padding: 20px;
    max-width: 100%; /* Đảm bảo container không vượt quá kích thước màn hình */
    box-sizing: border-box;
   
}
/* nút top lên đầu trang*/
#btnTop {
    position: fixed;
    bottom: 20px;
    left: 20px; /* Chuyển từ right sang left */
    width: 50px;
    height: 50px;
    background-color: #007bff;
    color: white;
    border: none;
    border-radius: 50%;
    font-size: 24px;
    cursor: pointer;
    display: none; /* Ẩn nút khi trang chưa cuộn */
    box-shadow: 0 4px 6px rgba(0, 0, 0, 0.2);
    transition: opacity 0.3s, transform 0.3s;
}

#btnTop:hover {
    background-color: #0056b3;
}

#btnTop.show {
    display: block;
    opacity: 1;
    transform: scale(1);
}

/*kết thúc nút top đầu trang*/

.item {
    border: 1px solid #ddd;
    padding: 10px;
    background-color: #f9f9f9;
    border-radius: 8px;
    text-align: center;
    box-shadow: 0 2px 8px rgba(0, 0, 0, 0.1);
    box-sizing: border-box;
    display:flex;
    flex-direction: column;
    justify-content: space-between;
}

.product-image-container {
    position: relative; /* Cần thiết để đặt các phần tử con sử dụng position: absolute */
    width: 100%; /* Đảm bảo container chiếm toàn bộ chiều rộng nếu cần */
}

.product-image-container img {
    width: 100%; /* Đảm bảo hình ảnh chiếm toàn bộ chiều rộng của container */
    height: auto; /* Giữ tỷ lệ khung hình */
}


.product-title {
    font-size: 14px;
    font-weight: bold;
    color: #333;
    margin-bottom: 2px;
}
.product-name {
    position: absolute; /* Định vị phần tử này */
    bottom: 0; /* Đưa nó xuống đáy */
    right: 0; /* Đưa nó về phía góc phải */
    background: rgba(0, 0, 0, 0.3); /* Nền tối mờ để chữ dễ đọc */
    color: white; /* Màu chữ trắng */
    padding: 5px 10px; /* Khoảng cách giữa văn bản và các cạnh */
    font-size: 12px; /* Đặt kích thước chữ */
    z-index: 1; /* Đảm bảo nó nằm trên hình ảnh */
}
.add-to-cart {
    background-color: #0084ff;
    color: #ffffff;
    padding: 5px 12px;
    border: none;
    min-width: 50px;
    border-radius: 14px 0 14px 0;
    cursor: pointer;
    display: inline-block;
    text-align: center;
}

.add-to-cart:hover {
    background-color: #0056b3;
}

.add-to-cart:focus {
    outline: none;
}


.share-item {
    background-color: #0084ff;
    color: #ffffff;
    padding: 5px 12px;
    border: none;
    min-width: 50px;
    border-radius: 14px 0 14px 0;
    cursor: pointer;
    display: inline-block;
    text-align: center;
}

.share-item:hover {
    background-color: #0056b3;
}

.share-item:focus {
    outline: none;
}



.detail {
    display: flex;
    justify-content: space-between;
    align-items: center;
}
/* -----*/
.partner {
    font-size: 18px;
    font-weight: bold;
    color: #e70707;
    display: flex;
    justify-content: space-around;
    margin-top: 20px;
}


/* Trường nhập tìm kiếm */
#search {
    width: 200px; /* Độ rộng của trường */
    padding: 10px; /* Khoảng cách bên trong */
    margin-left:20px;
    border: 1px solid #ccc; /* Đường viền */
    border-radius: 5px; /* Bo góc */
    font-size: 16px; /* Kích thước chữ */
    transition: border-color 0.3s; /* Hiệu ứng chuyển tiếp */
}

/* Thay đổi đường viền khi người dùng nhập */
#search:focus {
    border-color: #007bff; /* Màu viền khi trường được chọn */
    outline: none; /* Xóa outline mặc định */
}

/* Nút tìm kiếm */
.search-button {
    background-color: red; /* Màu nền của nút */
    color: white; /* Màu chữ */
    border: none; /* Không có đường viền */
    border-radius: 5px; /* Bo góc */
    padding: 10px 15px; /* Khoảng cách bên trong */
    font-size: 16px; /* Kích thước chữ */
  /*  margin-left: 10px;  Khoảng cách bên trái */
    cursor: pointer; /* Con trỏ chuột thành hình bàn tay */
    transition: background-color 0.3s; /* Hiệu ứng chuyển tiếp */
}

/* Hiệu ứng khi di chuột qua nút */
.search-button:hover {
    background-color: #0b3b52; /* Thay đổi màu nền khi di chuột */
}

/* Hiệu ứng khi nhấn nút */
.search-button:active {
    background-color: #004085 ; /* Màu nền khi nhấn */
}

.container{
  
    display: flex;
    flex-direction: column;
    flex-wrap: wrap;
    align-content: center;
    width: 100vw;  /* Chiều rộng bằng 100% của viewport (chiều rộng của màn hình) */
}

/*nút phân trang*/
.pagination {
    display: flex;
    flex-wrap: wrap;
    justify-content: flex-start;
    gap: 5px;
    padding: 2px 0;
    align-items: center;
    margin-top:2px;
    margin-bottom:2px;
    justify-content: center;
}

.pagination a {
    color: #007bff;
    text-decoration: none;
    padding: 5px 15px;
    border: 1px solid #dee2e6;
    border-radius: 4px;
    transition: background-color 0.3s, color 0.3s;
}

.pagination a:hover {
    background-color: #007bff;
    color: #fff;
}

.pagination a.active {
    background-color: #007bff;
    color: #fff;
    font-weight: bold;
    pointer-events: none;
}

.pagination .prev,
.pagination .next {
    font-weight: bold;
}

.pagination .dots {
    padding: 5px 15px;
    color: #666;
}

/* css cho menu*/
.Logo {
    height: 30px;
    width: 30px;
    border-radius: 30px;
    box-shadow: 0px 0px 20px 10px rgba(247, 249, 250, 0.8);
}
.menu{
    display:flex;
    flex-direction: row;
    flex-wrap: wrap;
    justify-content: space-around;
    align-items: center;
    width: 100vw;  /* Chiều rộng bằng 100% của viewport (chiều rộng của màn hình) */
    background-color: #0b3b52;
    color: white;
  
}
.sharebtn{
    margin-right:5px;
}
.searchcontainer{
    display:flex;  
    flex-wrap: wrap;
    margin-top:10px;
  
   
}
.facebook-share-button {
    background-image: url(icon/icon-facebook.png);
    background-size: 30px 30px;
    background-repeat: no-repeat;
    background-position: left center;
    color: white;
    border: none;
    padding: 15px;
    border-radius: 5px;
    cursor: pointer;
    background-color: #3b5998;
    display: inline-block;
}


.price {
    font-size:14px;
    font-weight:bold;
    color:blue;
    text-decoration: line-through;
}
.pricediscount{
font-size:14px;
font-weight:bold;
color:red;
}
.item-info{
    display:flex;
    flex-direction: column;
    align-items: flex-end;

}
.cart-count{
    display:flex;
    align-items: center;
}

.cart-icon{
    display:flex;
    align-items: center;

}

/* Thay đổi màu sắc của các liên kết trong khu vực chatbox */
#messages a {
    color: #007bff; /* Màu của liên kết (thay đổi theo ý muốn) */
    text-decoration: none; /* Tắt gạch dưới mặc định */
}

/* Thay đổi màu của liên kết khi di chuột qua */
#messages a:hover {
    color: #ff6347; /* Màu khi hover (thay đổi theo ý muốn) */
    text-decoration: underline; /* Thêm gạch dưới khi hover */
}

.recording-indicator {
  display: none;
  position: fixed;
  bottom: 90px;
  right: 10px;
  background-color: red;
  color: white;
  padding: 6px 12px;
  border-radius: 8px;
  font-weight: bold;
  z-index: 99999;
  box-shadow: 0 2px 8px rgba(0,0,0,0.2);
}


/* áp dụng cho kích thước mobile */
@media (max-width: 600px) {
    .grid-container {
        grid-template-columns: repeat(2, 1fr); /* 2 cột cho màn hình nhỏ hơn 600px */
        padding:0px;
    }
    
}

@media (max-width: 375px) {
    .grid-container {
        grid-template-columns: repeat(2, 1fr); /* 2 cột cho màn hình nhỏ hơn 400px */
        gap:0px;
        padding:0px;
    }
    .searchcontainer {
        display: flex;
        flex-wrap: wrap;
        margin: 0px;
    }
    #search{
        margin:0px;
    }
    
}
@media (max-width: 390px) {
    .grid-container {
        grid-template-columns: repeat(2, 1fr); /* 2 cột cho màn hình nhỏ hơn 400px */
        gap:0px;
        padding:0px;
    }
    .searchcontainer {
        display: flex;
        flex-wrap: wrap;
        margin: 0px;
    }
    #search{
        margin:0px;
    }
    
}



  