
@import url('href="https://fonts.googleapis.com/css2?family=Pacifico&display=swap" rel="stylesheet"');
* {
  margin: 0;
  padding: 0;
  box-sizing: border-box;
  font-family: "Roboto", sans-serif;
}

body {
  width: 100%;
  min-height: 100vh;
  background-color: #ffffff;
}

.container {
  width: 100%;
  margin: 0 auto;
  padding: 0 1rem;
  align-items: center;
}

.promo-banner {
  background-color: #5cb85c;
  color: white;
  width: 100%;
  overflow: hidden;
}

.scroller {
  display: inline-flex;
  gap: 2rem;
  animation: scroll 22s linear infinite;
}

.scroller-item {
  font-size: 16px;
  font-weight: bold;
  color: white;
  text-transform: uppercase;
  display: inline-flex;
  align-items: center;
  gap: 1rem;
  white-space: nowrap;
}
.scroller::after {
  content: attr(data-content);
  display: inline-flex;
  gap: 2rem;
}

@keyframes scroll {
  0% {
    transform: translateX(0);
  }
  100% {
    transform: translateX(-50%);
  }
}

.header {
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 1rem 0;
  background-color: #ffffff;
  width: 100%;
  position: sticky;
  z-index: 1000;
  top: 0;
}

.hamburger {
    display: none;
    cursor: pointer;
}

  .logo {
    font-family: "Pacifico", serif;
    font-size: 1.8rem;
    color: #4a7c59;
    text-decoration: none;
    display: flex;
    align-items: center;
  }

.imglogo {
  width: 50px;
  height: 50px;
  margin-right: 0.5rem;
  border-radius: 100%;
}

.nav {
  display: flex;
  list-style: none;
}

.nav.show-menu {
    display: flex; /* Khi có class show-menu, thì hiện menu ra */
    flex-direction: column;
    background-color: white;
    position: absolute;
    top: 60px;
    left: 0;
    width: 100%;
    z-index: 100;
    box-shadow: 0 2px 8px rgba(0, 0, 0, 0.2);
  }
.nav-item {
  margin: 0 1rem;
}

.nav-link {
  text-decoration: none;
  color: #333;
  font-weight: 500;
  padding: 0.5rem 0;
  position: relative;
}

.nav-link:hover {
  color: #4a7c59;
}

.nav-link:after {
  content: "";
  position: absolute;
  width: 0;
  height: 2px;
  background-color: #4a7c59;
  bottom: 0;
  left: 0;
  transition: width 0.3s;
}

.nav-link:hover:after {
  width: 100%;
}

.search-cart {
  display: flex;
  align-items: center;
}

.search-form {
  display: flex;
  align-items: center;
  border: 1px solid #ddd;
  border-radius: 4px;
  overflow: hidden;
  margin-right: 1rem;
}

.search-input {
  border: none;
  padding: 0.5rem;
  outline: none;
  width: 180px;
}

.search-btn {
  background: none;
  border: none;
  padding: 0.5rem;
  cursor: pointer;
  display: flex;
  align-items: center;
  justify-content: center;
}

.cart-btn {
  display: flex;
  align-items: center;
  text-decoration: none;
  color: #333;
  margin-right: 1rem;
}

.user-account {
  width: 32px;
  height: 32px;
  border-radius: 50%;
  background-color: #f0f0f0;
  display: flex;
  align-items: center;
  justify-content: center;
  cursor: pointer;
}

/* Nền mờ toàn màn hình */
.popup-form {
  display: none;
  position: fixed;
  top: 0; left: 0;
  width: 100%; height: 100%;
  background-color: rgba(0,0,0,0.5);
  z-index: 999;
  justify-content: center;
  align-items: center;
}

/* Nội dung popup */
.popup-content {
  display: flex;
  width: 700px;
  background: #fff;
  box-shadow: 0 0 15px rgba(0,0,0,0.3);
  border-radius: 8px;
  overflow: hidden;
}

/* Bên trái - đăng ký */
.popup-left {
  width: 50%;
  background: #7c8ca1;
  color: white;
  padding: 30px;
  text-align: center;
}

.popup-left h2 {
  margin-bottom: 10px;
}
.popup-left p {
  margin-bottom: 20px;
}
.btn-register {
  padding: 10px 20px;
  border: 1px solid white;
  background: transparent;
  color: white;
  cursor: pointer;
}

/* Bên phải - login */
.popup-right {
  width: 50%;
  padding: 30px;
}

.popup-right form {
  display: flex;
  flex-direction: column;
}

.popup-right input[type="text"],
.popup-right input[type="password"] {
  margin-bottom: 15px;
  padding: 10px;
  border: 1px solid #ccc;
}

.checkbox {
  margin-bottom: 15px;
}

.btn-login {
  padding: 10px;
  background-color: #153d2e;
  color: white;
  border: none;
  cursor: pointer;
}

.hero-slider {
  position: relative;
  width: 100%;
  height: 400px;
  overflow: hidden;
  margin-bottom: 2rem;
}

.slide {
  display: flex;
  width: 100%;
  height: 100%;
  display: none;
}
.slide.active {
  display: flex;
}

.slide-content {
  flex: 1;
  padding: 5rem;
  background-color: #f9f9f9;
  display: flex;
  flex-direction: column;
  justify-content: center;
}

.slide-title {
  font-size: 1.8rem;
  margin-bottom: 1rem;
  color: #333;
}

.slide-desc {
  margin-bottom: 1rem;
  color: #666;
  font-size: 0.9rem;
}

.slide-specs {
  margin-bottom: 1rem;
  font-size: 0.9rem;
  color: #666;
}

.slide-price {
  font-size: 1.2rem;
  font-weight: bold;
  color: #4a7c59;
  margin-bottom: 1rem;
}

.slide-img {
  flex: 1;
  display: flex;
  background-color: #f9f9f9;
  justify-content: center;
  align-items: center;
}
.slide-img img{
  height: 100%;
  width: 100%;
  object-fit: contain;
}


.slider-nav {
  position: absolute;
  top: 50%;
  transform: translateY(-50%);
  width: 40px;
  height: 40px;
  background-color: rgba(207, 202, 202, 0.7);
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  cursor: pointer;
  z-index: 10;
}

.slider-prev {
  left: 1rem;
}

.slider-next {
  right: 1rem;
}

/* Category Section */
.category-section {
  background: #fff;
  padding: 38px 0 23px 0;
  border-bottom: 1.2px solid #ece8e4;
}

.category-grid {

  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 25px 20px;
  justify-items: stretch;
}
.category-item {
  background: #f4f2ef;
  display: flex;
  flex-direction: column;
  align-items: center;
  border-radius: 14px;
  padding: 11px 8px 15px 8px;
  box-shadow: 0px 1px 7px 0 rgba(150, 170, 130, 0.14);
  cursor: pointer;
  border: 2px solid transparent;
  min-width: 120px;
  transition: box-shadow 0.17s, border 0.16s, transform 0.13s;
}
.category-item:hover {
  box-shadow: 0 8px 30px 0 #9f5a4631;
  border-color: #61b9796b;
  transform: translateY(-4px) scale(1.06);
}
.category-item img {
  width: 90px;
  height: 90px;
  object-fit: cover;
  border-radius: 10px;
  margin-bottom: 11px;
  border: 1.4px solid #eee;
}
.category-item span {
  color: #355435;
  font-weight: 700;
  font-size: 1.07rem;
}
.section-title {
  font-size: 1.5rem;
  margin: 2rem 0 1rem;
  color: #333;
  position: relative;
  padding-bottom: 0.5rem;
}

.section-title:after {
  content: "";
  position: absolute;
  width: 50px;
  height: 3px;
  background-color: #4a7c59;
  bottom: 0;
  left: 0;
}

.product-grid {
  display: flex;
  flex-wrap: wrap;
  margin: 0 -10px;
}

.product-card {
  width: calc(33.33% - 20px);
  margin: 10px;
  background-color: #fff;
  border-radius: 8px;
  overflow: hidden;
  box-shadow: 0 2px 10px rgba(0, 0, 0, 0.05);
  transition: transform 0.3s, box-shadow 0.3s;
}

.product-card-link {
  text-decoration: none;
  color: inherit;
}

.product-card:hover {
  transform: translateY(-5px);
  box-shadow: 0 5px 15px rgba(0, 0, 0, 0.1);
}

.product-img {
  width: 95%;
  height: 400px;
  object-fit: cover;
  object-position: top;
}

.product-info {
  padding: 1rem;
}

.product-name {
  font-size: 1rem;
  margin-bottom: 0.5rem;
  color: #333;
}

.product-desc {
  font-size: 0.8rem;
  color: #666;
  margin-bottom: 0.5rem;
}

.product-price {
  font-size: 1.1rem;
  font-weight: bold;
  color: #4a7c59;
}

.view-more {
  display: block;
  width: fit-content;
  margin: 1.5rem auto;
  padding: 0.5rem 1.5rem;
  background-color: transparent;
  border: 1px solid #4a7c59;
  color: #4a7c59;
  border-radius: 8px;
  text-decoration: none;
  transition: background-color 0.3s, color 0.3s;
  cursor: pointer;
}

.view-more:hover {
  background-color: #4a7c59;
  color: white;
}

.footer {
  background-color: #4a7c59;
  color: white;
  padding: 2rem 0;
  margin-top: 3rem;
}

.footer-content {
  display: flex;
  justify-content: space-between;
  flex-wrap: wrap;
}

.footer-section {
  flex: 1;
  min-width: 250px;
  margin-bottom: 1.5rem;
  justify-items: center;
}

.footer-title {
  font-size: 1.2rem;
  margin-bottom: 1rem;
  position: relative;
  padding-bottom: 0.5rem;
}

.footer-title:after {
  content: "";
  position: absolute;
  width: 100%;
  height: 2px;
  background-color: white;
  bottom: 0;
  left: 0;
}

.footer-logo {
  font-family: "Pacifico", serif;
  font-size: 1.5rem;
  margin-bottom: 1rem;
}

.footer-desc {
  font-size: 0.9rem;
  margin: 0 27px ;
}

.signup-form {
  display: flex;
  margin-bottom: 1rem;
}

.signup-input {
  flex: 1;
  padding: 0.5rem;
  border: none;
  border-radius: 4px 0 0 4px;
  outline: none;
}

.signup-btn {
  padding: 0.5rem 1rem;
  background-color: #5cb85c;
  border: none;
  border-radius: 0 4px 4px 0;
  color: white;
  cursor: pointer;
  transition: background-color 0.3s;
}

.signup-btn:hover {
  background-color: #4cae4c;
}

.contact-info {
  font-size: 0.9rem;
  margin-bottom: 0.5rem;
}

.contact-info i {
  margin-right: 0.5rem;
  width: 20px;
  text-align: center;
}

.footer-bottom {
  text-align: center;
  padding-top: 1.5rem;
  margin-top: 1.5rem;
  border-top: 1px solid rgba(255, 255, 255, 0.2);
  font-size: 0.9rem;
}
.social-icons{
        text-align: center;
        padding: 0;
    }
    .social-icons li{
        display: inline-block;
        text-align: center;
        padding: 5px;
    }
    .social-icons i{
        color: white;
        font-size: 25px;
    }

@media (max-width: 768px) {
    .product-card {
        width: calc(50% - 20px);
      }
    .category-grid {
        grid-template-columns: repeat(2, 1fr);
      }
      .search-input{
        width: 80px;
      }
    .nav {
        display: none; /* Ẩn menu trên màn hình nhỏ */
        flex-direction: column;
        position: absolute;
        top: 60px; /* Đặt vị trí menu */
        left: 0;
        background-color: white;
        width: 100%;
        z-index: 1000;
    }
    .nav.active {
        display: flex; /* Hiện menu khi có class active */
    }
    .logo{
      display: none;
    }
    .hamburger {
      position: absolute;
      left: 0px;
      width: 50px;
      height: 50px;
      z-index: 1000;
      display: flex;
      align-items: center;
      justify-content: center;
      cursor: pointer;    }
    .nav-item {
        padding: 10px 20px; /* Thêm khoảng cách cho các mục menu */
    }
    .nav-link {
        text-decoration: none;
        color: #333;
        font-weight: 500;
    }
}
@media (max-width: 576px) {
  .product-card {
    width: 100%;
  }
}
