:root {
  --primary-color: #dc3545;
  --primary-dark: #b02a37;
  --secondary-color: #f8f9fa;
  --dark-color: #343a40;
  --gold-color: #ffc107;
}

body {
  font-family: "Poppins", sans-serif;
  background-color: #f4f6f9;
  color: #444;
  display: flex;
  flex-direction: column;
  min-height: 100vh;
}

/* --- NAVBAR --- */
.navbar {
  box-shadow: 0 4px 12px rgba(0, 0, 0, 0.05);
  padding-top: 12px;
  padding-bottom: 12px;
  background-color: #fff;
}
.navbar-brand {
  font-weight: 800;
  color: var(--primary-color) !important;
  font-size: 1.4rem;
  letter-spacing: -0.5px;
}
.nav-link {
  font-weight: 500;
  color: var(--dark-color);
  margin: 0 10px;
  font-size: 1rem;
}
.nav-link:hover,
.nav-link.active {
  color: var(--primary-color) !important;
}
.input-group-text {
  background: transparent;
  border-right: none;
}
.form-control-search {
  border-left: none;
}
.form-control-search:focus {
  box-shadow: none;
  border-color: #ced4da;
}

.btn-action-view,
.btn-action-cart {
  text-decoration: none !important;
}

/* --- HERO SECTION --- */
/* Pastikan gambar ada di public/assets/market.jpg */
.hero-section {
  background: linear-gradient(rgba(0, 0, 0, 0.6), rgba(0, 0, 0, 0.6)), url("../asset/market.jpg");
  background-size: cover;
  background-position: center;
  background-attachment: fixed;
  color: white;
  padding: 140px 0;
  margin-bottom: 50px;
  position: relative;
}
.hero-title {
  font-weight: 800;
  text-shadow: 2px 2px 4px rgba(0, 0, 0, 0.5);
  font-size: 2.5rem;
}
.hero-btn {
  background-color: var(--primary-color);
  color: white;
  padding: 12px 35px;
  border-radius: 50px;
  text-decoration: none;
  font-weight: 600;
  transition: 0.3s;
  text-transform: uppercase;
  letter-spacing: 1px;
  border: 2px solid var(--primary-color);
}
.hero-btn:hover {
  background-color: transparent;
  border-color: white;
  color: white;
  transform: translateY(-3px);
}

/* --- SECTION TITLES --- */
.section-title {
  text-align: center;
  margin-bottom: 40px;
  position: relative;
}
.section-title h2 {
  font-weight: 700;
  color: var(--dark-color);
  text-transform: uppercase;
  letter-spacing: 1px;
  display: inline-block;
  position: relative;
  z-index: 1;
}
.section-title h2::after {
  content: "";
  display: block;
  width: 60px;
  height: 4px;
  background: var(--primary-color);
  margin: 15px auto 0;
  border-radius: 2px;
}

/* --- VOUCHER CARD --- */
.voucher-card {
  background: linear-gradient(135deg, #ffffff 0%, #fff0f0 100%);
  border: 1px solid #ffcdd2;
  border-radius: 12px;
  padding: 20px;
  position: relative;
  overflow: hidden;
  transition: 0.3s;
  box-shadow: 0 4px 10px rgba(220, 53, 69, 0.1);
  border-left: 5px solid var(--primary-color);
  height: 100%;
}
.voucher-card:hover {
  transform: translateY(-5px);
  box-shadow: 0 8px 20px rgba(220, 53, 69, 0.2);
}
.voucher-card::before,
.voucher-card::after {
  content: "";
  position: absolute;
  width: 20px;
  height: 20px;
  background-color: #f4f6f9;
  border-radius: 50%;
  right: -10px;
}
.voucher-card::before {
  top: -10px;
}
.voucher-card::after {
  bottom: -10px;
}
.voucher-icon {
  font-size: 2rem;
  color: var(--primary-color);
  opacity: 0.2;
  position: absolute;
  right: 15px;
  top: 15px;
}
.voucher-title {
  font-weight: 800;
  color: var(--primary-color);
  font-size: 1.2rem;
  margin-bottom: 5px;
}
.voucher-code {
  background: var(--dark-color);
  color: #fff;
  padding: 6px 15px;
  border-radius: 4px;
  font-family: "Courier New", monospace;
  font-weight: bold;
  letter-spacing: 1.5px;
  display: inline-block;
  margin-top: 10px;
  border: 1px dashed white;
}

/* --- PRODUCT CARD --- */
.product-card {
  background: white;
  border: none;
  border-radius: 15px;
  overflow: hidden;
  box-shadow: 0 5px 15px rgba(0, 0, 0, 0.05);
  transition: all 0.3s ease;
  height: 100%;
  display: flex;
  flex-direction: column;
  position: relative;
}
.product-card:hover {
  transform: translateY(-5px);
  box-shadow: 0 15px 30px rgba(0, 0, 0, 0.1);
}
.card-img-wrap {
  height: 200px;
  width: 100%;
  background-color: #fff;
  position: relative;
  overflow: hidden;
}
.card-img-top {
  width: 100%;
  height: 100%;
  object-fit: cover;
  transition: transform 0.5s;
}
.product-card:hover .card-img-top {
  transform: scale(1.08);
}

/* Badges */
.badge-promo {
  position: absolute;
  top: 12px;
  left: 0;
  background: var(--primary-color);
  color: white;
  padding: 5px 12px;
  font-size: 0.75rem;
  font-weight: 600;
  border-radius: 0 20px 20px 0;
  z-index: 5;
  box-shadow: 2px 2px 5px rgba(0, 0, 0, 0.2);
}
.badge-point {
  position: absolute;
  top: 12px;
  right: 12px;
  background: rgba(255, 193, 7, 0.95);
  color: #fff;
  padding: 5px 10px;
  font-size: 0.7rem;
  font-weight: 700;
  border-radius: 20px;
  z-index: 5;
  box-shadow: 0 2px 5px rgba(0, 0, 0, 0.1);
  display: flex;
  align-items: center;
  gap: 4px;
}

/* Card Body */
.card-body {
  padding: 18px;
  flex-grow: 1;
  display: flex;
  flex-direction: column;
  justify-content: space-between;
}
.star-rating {
  color: var(--gold-color);
  font-size: 0.8rem;
  margin-bottom: 5px;
}
.card-title {
  font-size: 1rem;
  font-weight: 600;
  margin-bottom: 10px;
  color: var(--dark-color);
  display: -webkit-box;
  -webkit-line-clamp: 2;
  -webkit-box-orient: vertical;
  overflow: hidden;
  height: 2.8em;
}
.price-real {
  font-size: 1.1rem;
  font-weight: 700;
  color: var(--primary-color);
}
.price-coret {
  font-size: 0.85rem;
  color: #999;
  text-decoration: line-through;
}

/* Buttons */
.card-actions {
  display: flex;
  gap: 10px;
  margin-top: 15px;
}
.btn-action-view {
  width: 42px;
  height: 42px;
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  border: 2px solid #eee;
  color: var(--dark-color);
  background: #fff;
  transition: 0.3s;
  flex-shrink: 0;
}
.btn-action-view:hover {
  background: var(--dark-color);
  color: #fff;
  border-color: var(--dark-color);
}
.btn-action-cart {
  flex-grow: 1;
  border-radius: 50px;
  font-weight: 600;
  font-size: 0.9rem;
  background-color: var(--primary-color);
  color: white;
  border: none;
  transition: 0.3s;
  display: flex;
  align-items: center;
  justify-content: center;
}
.btn-action-cart:hover {
  background-color: var(--primary-dark);
}

/* --- FOOTER & CONTACT --- */
#kontak .card {
  border-radius: 20px;
  box-shadow: 0 10px 30px rgba(0, 0, 0, 0.08) !important;
}
footer {
  background-color: #212529;
  color: #bbb;
  padding: 70px 0 30px;
  margin-top: auto;
}
footer h5 {
  color: white;
  font-weight: 700;
  margin-bottom: 25px;
}
footer a {
  color: #bbb;
  text-decoration: none;
  transition: 0.3s;
}
footer a:hover {
  color: var(--primary-color);
  padding-left: 5px;
}
footer ul li {
  margin-bottom: 12px;
}
.social-link {
  width: 40px;
  height: 40px;
  background: rgba(255, 255, 255, 0.1);
  display: inline-flex;
  align-items: center;
  justify-content: center;
  border-radius: 50%;
  margin-right: 10px;
  color: white;
  transition: 0.3s;
}
.social-link:hover {
  background: var(--primary-color);
  transform: translateY(-3px);
}

/* --- MOBILE RESPONSIVE --- */
@media (max-width: 768px) {
  .hero-section {
    padding: 100px 0;
  }
  .hero-title {
    font-size: 2rem;
  }
  .card-img-wrap {
    height: 150px;
  }
  .card-body {
    padding: 12px;
  }
  .card-title {
    font-size: 0.9rem;
    height: auto;
    -webkit-line-clamp: 2;
  }
  .badge-promo {
    font-size: 0.65rem;
    padding: 4px 8px;
  }
  .badge-point {
    font-size: 0.65rem;
    padding: 3px 8px;
    right: 8px;
    top: 8px;
  }
  .btn-action-view {
    width: 35px;
    height: 35px;
    font-size: 0.85rem;
  }
  .btn-action-cart {
    font-size: 0.85rem;
  }
  .d-lg-block {
    display: none !important;
  }
  .navbar-brand {
    font-size: 1.2rem;
  }
}
