html {
    font-size: 15px; /* default usually 16px */
}

body {
  /*background-image: url('../assets/img/background.jpg'); /* Ganti 'gambar.jpg' dengan path atau URL gambar */
  background-size: cover;              /* Agar gambar menutupi seluruh layar */
  background-repeat: no-repeat;        /* Jangan ulang gambar */
  background-attachment: fixed;        /* Supaya tetap saat scroll */
  font-family: 'Segoe UI', sans-serif;
  color: #333;
}

/* Overlay transparan */
    body::before {
      content: "";
      position: fixed;
      top: 0; left: 0;
      width: 100%;
      height: 100%;
      background-color: rgba(255, 255, 255, 0.4); /* Ubah tingkat transparansi di sini */
      z-index: -1; /* Tetap di belakang semua konten */
    }


.navbar-brand {
  font-size: 1.4rem;
}

.badge {
  font-size: 0.6rem;
}


.main-container {
  background-color: rgba(255, 255, 255, 0.95);
  border-radius: 16px;
  padding: 30px;
  margin-top: 30px;
  margin-bottom: 30px;
  box-shadow: 0 10px 30px rgba(0,0,0,0.1);
}

.sidebar {
  min-width: 200px;
  border-right: 1px solid #ddd;
}

.produk-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(200px, 1fr));
  gap: 1rem;
}

.produk-item {
  display: flex;
  width: 100%;
    max-width: 100%;
}

.product-card {
  border: 1px solid #f5f9fa;
  border-radius: 12px;
  transition: transform 0.2s, box-shadow 0.2s;
  background: white;
}

.product-card:hover {
  border: 1px solid #fa98b7;
  transform: scale(1.02);
  box-shadow: 0 6px 20px rgba(0,0,0,0.15);
}

.product-img-wrapper {
    position: relative;
    width: 100%;
    aspect-ratio: 1 / 1;
    overflow: hidden;
    border-radius: 0.5rem;
    background-color: #fff; /* fallback bg */
    display: flex;
    align-items: center;
    justify-content: center;
}

.product-img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    object-position: center;
}

.product-actions {
    position: absolute;
    bottom: 8px;
    right: 8px;
    opacity: 0;
    transform: translateY(10px);
    transition: all 0.3s ease;
}

.product-img-wrapper:hover .product-actions {
    opacity: 1;
    transform: translateY(0);
}

.price {
  color: #fa4520 !important;
  font-weight: bold;
}

.kategoriList a {
  color: #333; /* warna teks kategori, ganti sesuai selera */
  text-decoration: none; /* hilangkan garis bawah */
  font-weight: 5000;
  display: block;
  border-radius: 4px;
  transition: background-color 0.2s ease;
  list-style: none;     /* Hilangkan bullet/marker */
  padding-left: 0;      /* Hilangkan indentasi bawaan */
  margin-bottom: 0;
}

.kategori-item {
  padding: 8px 12px;
  border-radius: 5px;
  cursor: pointer;
  list-style: none;     /* Hilangkan bullet/marker */
}

.kategori-item:hover {
  background-color: #f5f9fa !important;
  color: black;
}
.kategori-item.active {
  background-color: #f76a6a !important;
  color: white;
}

.product-title {
    font-family: 'Poppins', sans-serif;
    font-weight: 400;
    font-size: 0.9rem;
    line-height: 1.3;
    display: -webkit-box;
    -webkit-line-clamp: 2;
    -webkit-box-orient: vertical;
    overflow: hidden;
    height: calc(1rem * 1.3 * 2); /* 2 baris teks */
}

.variant-card {
    cursor: pointer;
    border: 2px solid transparent;
    transition: all 0.2s ease-in-out; /* Animasi transisi untuk hover dan selected */
    border-radius: 8px; /* Sudut membulat */
    overflow: hidden; /* Pastikan gambar tidak keluar dari sudut membulat */
    box-shadow: 0 2px 5px rgba(0,0,0,0.05); /* Sedikit bayangan */
}

.variant-card:hover:not(.disabled) {
    border-color: #007bff; /* Warna border saat hover */
    box-shadow: 0 4px 10px rgba(0,0,0,0.1); /* Bayangan lebih besar saat hover */
    transform: translateY(-2px); /* Efek sedikit terangkat saat hover */
}

.variant-card.selected {
    border-color: #007bff; /* Warna border saat dipilih */
    background-color: #eaf5ff; /* Latar belakang sedikit biru saat dipilih */
    box-shadow: 0 0 0 0.25rem rgba(0, 123, 255, 0.25); /* Glow effect saat dipilih */
    transform: scale(1.02); /* Sedikit membesar saat dipilih */
}

.variant-card.disabled {
    opacity: 0.6;
    cursor: not-allowed;
    background-color: #f8f9fa;
    filter: grayscale(100%); /* Gambar jadi abu-abu */
}

.variant-card.disabled .card-title,
.variant-card.disabled .card-text {
    color: #6c757d;
}

.variant-card img {
  width: 100%;
  height: auto;
  max-height: 200px;
  object-fit: contain;
  padding: 7px;
}

.variant-card .card-body {
    padding: 0.75rem; /* Padding dalam body kartu */
}

/* Tambahan untuk responsivitas modal */
@media (max-width: 576px) {
    .modal-dialog {
        margin: 0.5rem;
    }
    .variant-card img {
        height: 80px;
    }
    .variant-card .card-body h6 {
        font-size: 0.85rem;
    }
    .variant-card .card-body p {
        font-size: 0.75rem;
    }
}

/* Custom 5 kolom di layar besar */
@media (min-width: 1200px) {
  .col-xl-5th {
    width: 20%;
    flex: 0 0 auto;
  }
}

@media (max-width: 768px) {
    html {
        font-size: 12px; /* Lebih kecil di mobile (tablet dan HP) */
    }
    .main-container {
        box-shadow: none;
    }
}

@media (max-width: 576px) {
    html {
        font-size: 11px; /* Tambahan: lebih kecil lagi di HP kecil */
    }
    .main-container {
        box-shadow: none;
    }
}