* {
  box-sizing: border-box;
}
html, body {
  overflow-x: hidden;
}
body {
  font-family: 'Poppins', sans-serif;
  margin: 0;
  background: #fafafa;
}

/* NAVBAR MODERN */
.navbar {
  background: linear-gradient(90deg,#ff9800,#ff5722);
  padding: 12px 0;
  position: sticky;
  top: 0;
  z-index: 1000;
}

.nav-container {
  width: 100%;
  max-width: 1200px;
  margin: auto;
  padding: 0 20px;   /* kasih jarak kiri kanan */
  display: flex;
  justify-content: space-between;
  align-items: center;
}

.logo {
  font-size: 20px;
  font-weight: 700;
  color: white;
}

.menu {
  list-style: none;
  display: flex;
  gap: 25px;
  margin: 0;
  padding: 0;
}

.menu li a {
  color: white;
  text-decoration: none;
  font-weight: 500;
  transition: 0.3s;
}

.menu li a:hover {
  opacity: 0.8;
}


.menu li a {
  position: relative;
  color: white;
  text-decoration: none;
  font-weight: 500;
  padding: 5px 0;
  transition: 0.3s;
}

/* Garis bawah hidden dulu */
.menu li a::after {
  content: "";
  position: absolute;
  left: 0;
  bottom: -4px;
  width: 0%;
  height: 3px;
  background: black;
  transition: 0.3s ease;
  border-radius: 3px;
}

/* Saat hover */
.menu li a:hover::after {
  width: 100%;
}
/* SLIDER */

.slider {
  width: 100%;
  height: 280px;
  overflow: hidden;
  position: relative;
}

.slide {
  display: none;
  width: 100%;
  height: 100%;
}

.slide img {
  width: 100%;
  height: 140%;
  object-fit: cover;
  object-position: center;
}
.slide.active {
  display: block;
  animation: fade 1s ease-in-out;
}

@media (min-width: 768px) {
  .slider {
    height: 350px;
  }
}

@media (min-width: 1200px) {
  .slider {
    height: 420px;
  }
}




/* ABOUT SECTION */
.about {
  padding: 60px 20px;
  background: #f9f9f9;
}

.about-container {
  max-width: 1100px;
  margin: auto;
  display: flex;
  align-items: center;
  gap: 40px;
  flex-wrap: wrap;
}

.about-image {
  flex: 1;
}

.about-image img {
  width: 100%;
  border-radius: 15px;
  box-shadow: 0 5px 20px rgba(0,0,0,0.1);
}

.about-text {
  flex: 1;
}

.about-text h2 {
  font-size: 28px;
  margin-bottom: 15px;
  color: #ff5722;
}

.about-text p {
  line-height: 1.6;
  margin-bottom: 10px;
}


/* PRODUK */
.products {
  display: grid;
  grid-template-columns: repeat(auto-fit,minmax(220px,1fr));
  gap: 20px;
  padding: 20px;
}
.card {
  background: white;
  padding: 20px;
  border-radius: 15px;
  box-shadow: 0 5px 15px rgba(0,0,0,0.08);
  text-align: center;
  transition: 0.3s;
}
.card:hover {
  transform: translateY(-5px);
}
button {
  background: #ff5722;
  color: white;
  border: none;
  padding: 8px 15px;
  border-radius: 20px;
  cursor: pointer;
}

.card img {
  width: 50%;
  aspect-ratio: 1 / 1;   
  object-fit: cover;
  border-radius: 12px;
  margin-bottom: 10px;
}

.card h3 {
  margin: 10px 0 5px;
}

.price {
  font-weight: bold;
  color: #ff5722;
  margin-bottom: 10px;
}

.card button {
  background: #ff5722;
  color: white;
  border: none;
  padding: 8px 15px;
  border-radius: 20px;
  cursor: pointer;
  transition: 0.3s;
}

.card button:hover {
  background: #e64a19;
}

.btn-produk {
  display: inline-block;
  background: #ff5722;
  color: white;
  padding: 8px 15px;
  border-radius: 20px;
  text-decoration: none;
  transition: 0.3s;
}

.btn-produk:hover {
  background: #e64a19;
}


.section-title {
  text-align: center;
  margin-top: 60px;
  margin-bottom: 30px;
}

.section-title h2 {
  font-size: 28px;
  color: #ff5722;
  position: relative;
  display: inline-block;
}

/* Garis bawah dekoratif */
.section-title h2::after {
  content: "";
  display: block;
  width: 60%;
  height: 4px;
  background: #ff5722;
  margin: 8px auto 0;
  border-radius: 3px;
}

/* CART */



/* CART */

.cart-menu {
  position: relative;
  display: flex;
  align-items: center;
}

.cart-link {
  position: relative;
  display: flex;                 /* 🔥 WAJIB flex */
  align-items: center;
  justify-content: center;
  width: 45px;                   /* 🔥 perbesar area klik */
  height: 45px;
  font-size: 22px;
  background: rgba(255,255,255,0.15);
  border-radius: 50%;
  cursor: pointer;
  transition: 0.2s ease;
}

.cart-link:active {
  transform: scale(0.92);
}

.cart-badge {
  position: absolute;
  top: 5px;
  right: 5px;
  background: red;
  color: white;
  font-size: 11px;
  padding: 3px 6px;
  border-radius: 50%;
  font-weight: bold;
  pointer-events: none;   /* 🔥 penting supaya tidak nutup klik */
}

@media (max-width: 768px){
  .cart-link{
    width: 50px;
    height: 50px;
    font-size: 24px;
  }
}

/* ================= FIX CART DI MENU MOBILE ================= */
@media (max-width: 992px){

  .menu li.cart-menu{
    display: flex;
    justify-content: center;   /* 🔥 ini bikin kembali ke tengah */
  }

  .cart-menu{
    width: 100%;
  }

}



/* MODAL */
.modal {
  position: fixed;
  inset: 0;
  background: rgba(0,0,0,0.5);
  display: none;
  justify-content: center;
  align-items: center;
  padding: 20px;
  z-index: 9999;
}

/* CONTENT MODAL */
.modal-content {
  background: #fff;
  width: 100%;
  max-width: 520px;
  max-height: 85vh;        /* BATAS TINGGI */
  overflow-y: auto;        /* SCROLL DI DALAM */
  border-radius: 20px;
  padding: 20px;           /* KECILKAN PADDING */
}

.cart-summary {
  margin: 15px 0;
}

.input-style {
  padding: 8px;
  margin-bottom: 10px;
}

.modal-buttons {
  margin-top: 10px;
}


.cart-item {
  display: flex;
  justify-content: space-between;
  align-items: center;
  margin-bottom: 10px;
}
.qty-btn {
  background: #ddd;
  padding: 3px 8px;
  cursor: pointer;
}
.remove {
  color: red;
  cursor: pointer;
}

input, textarea {
  width: 100%;
  padding: 8px;
  margin: 5px 0;
}






/* FOOTER */
.footer {
  background: #1e1e1e;
  color: #fff;
  padding: 50px 20px 20px;
  margin-top: 60px;
}

.footer-container {
  max-width: 1100px;
  margin: auto;
  display: flex;
  justify-content: space-between;
  flex-wrap: wrap;
  gap: 40px;
}

.footer-col {
  flex: 1;
  min-width: 220px;
}

.footer-col h3,
.footer-col h4 {
  margin-bottom: 15px;
  color: #ff5722;
}

.footer-col p {
  line-height: 1.6;
  font-size: 14px;
}

.footer-col ul {
  list-style: none;
  padding: 0;
}

.footer-col ul li {
  margin-bottom: 8px;
}

.footer-col ul li a {
  text-decoration: none;
  color: #ccc;
  transition: 0.3s;
}

.footer-col ul li a:hover {
  color: #ff5722;
}

.footer-bottom {
  text-align: center;
  margin-top: 40px;
  padding-top: 20px;
  border-top: 1px solid #333;
  font-size: 14px;
  color: #aaa;
}


/* ================= MOBILE RESPONSIVE ================= */
@media (max-width: 768px) {

  /* NAVBAR FIX */
  .nav-container {
    display: flex;
    justify-content: space-between;
    align-items: center;
    position: relative;
  }

  /* Hamburger tampil */
  .hamburger {
    display: block;
  }

  /* Menu hidden default */
  .menu {
    display: none;
    flex-direction: column;
    background: #ff5722;
    width: 100%;
    position: absolute;
    top: 60px;
    left: 0;
    padding: 15px 0;
  }

  .menu li {
    text-align: center;
    margin: 10px 0;
  }

  .menu.show {
    display: flex;
  }

  /* Slider */
  .slider img {
    width: 100%;
    height: auto;
  }

  /* About */
  .about-container {
    flex-direction: column;
    text-align: center;
  }

  .about-image img {
    max-width: 80%;
    margin: 0 auto;
  }

  /* Produk */
  .products,
  .products-page {
    grid-template-columns: 1fr;
  }

  /* Lokasi */
  .lokasi-section {
    flex-direction: column;
  }

  /* Modal */
  .modal-content {
    width: 95%;
    max-height: 90vh;
  }
}

/* HAMBURGER DEFAULT */
.hamburger {
  display: none;
  font-size: 26px;
  cursor: pointer;
  color: white;
  margin-left: 15px;
}
/* ================= NAVBAR RESPONSIVE FIX ================= */

/* Default desktop */
.hamburger {
  display: none;
}

/* Mobile & Tablet */
@media (max-width: 992px){

  .nav-container{
    width:100% !important;
    max-width:none !important;   /* INI WAJIB */
    margin:0 !important;         /* INI WAJIB */
    padding:0 20px;
    position:relative;
  }

  .hamburger{
    display:block !important;
    font-size: 26px;
    color: white;
    cursor: pointer;
  }

  .menu{
    display: none;
    position: absolute;
    top: 60px;
    left: 0;
    width: 100%;
    background: linear-gradient(90deg,#ff9800,#ff5722);
    flex-direction: column;
    text-align: center;
    padding: 15px 0;
  }

  .menu li{
    margin: 12px 0;
  }

  .menu.show{
    display: flex;
  }

}


/* loading cekout */
/* FULLSCREEN LOADING */
.global-loading{
  position: fixed;
  inset: 0;
  background: rgba(0,0,0,0.6);
  display: none;
  justify-content: center;
  align-items: center;
  z-index: 99999;
}

.loader-box{
  background: white;
  padding: 35px 45px;
  border-radius: 18px;
  text-align: center;
  box-shadow: 0 15px 40px rgba(0,0,0,0.25);
  animation: fadeIn 0.3s ease;
}

.spinner{
  width: 55px;
  height: 55px;
  border: 6px solid #eee;
  border-top: 6px solid #ff5722;
  border-radius: 50%;
  margin: 0 auto 15px;
  animation: spin 1s linear infinite;
}

@keyframes spin{
  0%{ transform: rotate(0deg); }
  100%{ transform: rotate(360deg); }
}

@keyframes fadeIn{
  from{ opacity: 0; transform: scale(0.9); }
  to{ opacity: 1; transform: scale(1); }
}