/* === RESET & FONT === */
@import url('https://fonts.googleapis.com/css2?family=Poppins:wght@300;400;600;700&display=swap');

* {
  margin: 0;
  padding: 0;
  box-sizing: border-box;
}

body, html {
  height: 100%;
  font-family: 'Poppins', sans-serif;
  background-color: #f9f9f9;
  color: #222;
  line-height: 1.6;
}

/* === NAVBAR === */
.navbar {
  background: white;
  box-shadow: 0 2px 5px rgba(0,0,0,0.1);
  padding: 10px 20px;
  position: sticky;
  top: 0;
  z-index: 999;
}

.navbar-container {
  display: flex;
  justify-content: space-between;
  align-items: center;
  flex-wrap: wrap;
}

.logo a {
  text-decoration: none;
  font-size: 22px;
  font-weight: 700;
  padding-left: 10px;
  color: #1e88e5;
}

.navbar-icons {
  display: flex;
  align-items: center;
  gap: 10px;
}

.navbar-icons i {
  font-size: 18px;
  color: #1e88e5;
  margin-left: 15px;
  cursor: pointer;
}

.navbar-search-input {
  display: none;
  padding: 6px 10px;
  font-size: 14px;
  border: 1px solid #ccc;
  border-radius: 6px;
  outline: none;
  margin-left: 12px;
  transition: all 0.3s ease;
}

.navbar-search-input.show {
  display: block !important;
  width: 100%;
  margin-top: 10px;
  padding: 10px 14px;
  border-radius: 10px;
}

/* === LAYOUT PRODUK === */
.produk-layout {
  display: flex;
  gap: 20px;
  padding: 20px;
  flex: 1;
}

.filter-kiri {
  width: 230px;
  background: #fff;
  padding: 15px;
  border-radius: 10px;
  box-shadow: 0 1px 6px rgba(0, 0, 0, 0.1);
  position: sticky;
  top: 90px;
  height: fit-content;
}

.filter-search input {
  width: 100%;
  padding: 8px 12px;
  margin-bottom: 15px;
  border: 1px solid #ccc;
  border-radius: 8px;
}

.kategori-bar-vertikal a {
  display: block;
  padding: 8px 10px;
  margin: 5px 0;
  border-radius: 6px;
  text-decoration: none;
  color: #333;
  transition: background 0.2s;
}

.kategori-bar-vertikal a:hover {
  background: #e3f2fd;
  color: #1e88e5;
}

/* === PRODUK KANAN === */
.produk-kanan {
  flex: 1;
  position: relative;
}

.produk-kanan::after {
  content: '';
  display: block;
  height: 60px;
}

.produk-section h2 {
  margin-bottom: 10px;
  color: #1565c0;
}

.produk-deskripsi {
  font-size: 16px;
  margin-bottom: 25px;
}

/* === GRID PRODUK === */
.product-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(240px, 1fr));
  gap: 20px;
  width: 100%;
}

/* === CARD PRODUK === */
.card-produk {
  background: white;
  border-radius: 12px;
  overflow: hidden;
  box-shadow: 0 2px 6px rgba(0,0,0,0.08);
  display: flex;
  flex-direction: column;
  height: 100%;
  opacity: 0;
  transform: translateY(30px);
  transition: opacity 0.6s ease, transform 0.6s ease;
}

.card-produk.show {
  opacity: 1;
  transform: translateY(0);
}

.card-produk:hover {
  transform: translateY(-4px);
}

.card-produk img {
  width: 100%;
  height: 180px;
  object-fit: cover;
}

.card-produk .content {
  padding: 12px;
  display: flex;
  flex-direction: column;
  flex-grow: 1;
}

.card-produk h4 {
  font-size: 16px;
  color: #1565c0;
  margin: 0;
}

.card-produk .lokasi {
  font-size: 13px;
  color: #00796b;
}

.card-produk p {
  margin-top: 10px;
  font-size: 14px;
  color: #555;
  display: -webkit-box;
  -webkit-line-clamp: 3;
  -webkit-box-orient: vertical;
  overflow: hidden;
  text-overflow: ellipsis;
}

.card-produk .harga {
  color: #00a86b;
  font-weight: 600;
}

.card-icons {
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding-top: 10px;
  border-top: 1px solid #eee;
  margin-top: auto;
}

.card-icons button {
  background: none;
  border: none;
  color: #555;
  font-size: 16px;
  cursor: pointer;
}

.card-icons button:hover {
  color: #1e88e5;
}

/* === FOOTER === */
.footer-bottom {
  text-align: center;
  font-size: 14px;
  color: #1e88e5;
  padding: 15px 20px;
  background: #e3f2fd;
  border-top: 1px solid rgba(0, 0, 0, 0.1);
  margin-top: auto;
}

.filter-kiri,
.kategori-bar-vertikal {
  display: none !important;
}


@media screen and (max-width: 991px) {
  .produk-layout {
    flex-direction: column;
    gap: 12px;
    padding: 12px 16px;
  }

  .produk-kanan {
    width: 100%;
  }

  .filter-kiri,
  .kategori-bar-vertikal {
    display: none !important;
  }

  .product-grid {
    grid-template-columns: repeat(auto-fill, minmax(150px, 1fr));
    gap: 12px;
  }

  .card-produk {
    margin-bottom: 12px;
    height: auto; /* biar tidak terlalu tinggi */
  }

  .card-produk img {
    height: 140px;
  }

  .navbar {
    padding: 8px 16px;
  }

  .navbar-container {
    flex-direction: column;
    align-items: flex-start;
    padding-bottom: 6px;
  }

  .navbar-icons {
    width: 100%;
    justify-content: flex-end;
    margin-top: 4px;
  }

  .icon-search {
    display: inline-block !important;
    font-size: 20px;
    color: #1e88e5;
    margin-left: 8px;
    cursor: pointer;
  }

  .navbar-search-input {
    display: none !important;
  }

  .navbar-search-input.show {
    display: block !important;
    width: 100%;
    margin-top: 8px;
    padding: 8px 12px;
    border-radius: 8px;
  }

  .produk-section h2 {
    font-size: 18px;
    margin-bottom: 6px;
  }

  .produk-deskripsi {
    font-size: 14px;
    margin-bottom: 14px;
  }
  
   .filter-kiri,
  .kategori-bar-vertikal {
    display: none !important;
    visibility: hidden !important;
    width: 0 !important;
    height: 0 !important;
    overflow: hidden !important;
    padding: 0 !important;
    margin: 0 !important;
  }
}


@media screen and (max-width: 400px) {
  .product-grid {
    grid-template-columns: repeat(2, 1fr);
  }

  .card-produk h4 {
    font-size: 13.5px;
    margin-top: 6px;
  }

  .card-produk p {
    font-size: 12.5px;
  }

  .card-produk .lokasi {
    font-size: 11.5px;
  }

  .navbar {
    padding: 6px 12px;
  }

  .logo a {
    font-size: 16px;
  }

  .navbar-icons i {
    font-size: 15px;
  }

  .card-produk img {
    height: 130px;
  }

  .produk-layout {
    padding: 10px;
  }
}
