:root{
  --primary:#ffcc00;
  --bg:#fafafa;
  --card:#fff;
  --shadow:0 4px 12px rgba(0,0,0,0.15);
  --muted:#666;
}

* {
  box-sizing: border-box;
  margin:0;
  padding:0;
}

body {
  font-family:'Poppins',sans-serif;
  background:var(--bg);
  color:#222;
  overflow-x:hidden;
}

header {
  display:flex;
  align-items:center;
  justify-content:space-between;
  background:#fff;
  padding:10px;
  box-shadow: var(--shadow);
  position:sticky;
  top:0;
  z-index: 100;
}

.logo img {
  width:120px;
}

.actions button { 
  background:none;
  border:none;
  cursor:pointer;
}

.categories{
  display:flex;
  gap:10px;
  overflow-x:auto;
  padding:20px;
  background:#fff;
  box-shadow:var(--shadow);
  margin-bottom:50px;
}

.cat-item{
  flex:0 0 auto;
  padding:8px 14px;
  border-radius: 999px;
  background:#f6f6f6;
  font-size:14px;
  cursor:pointer;
  white-space:nowrap;
  transition:.3s;
}

.cat-item:hover,.cat-item.active { 
  background:var(--primary);;
  color:#fff;
}

.products{
  display:grid;
  gap:14px;
  padding:0 16px 100px;
  transition:opacity .4s,transform .4s;
}

@media (min-width:900px){
  .products {
    grid-template-columns:repeat(4,1fr);
  }
}

@media (min-width:600px) and (max-width:899px){
  .products{grid-template-columns:repeat(3,1fr);
  }
}

@media (max-width:599px){
  .products { 
    grid-template-columns:repeat(2,1fr);
  }
}

.card { 
  background:var(--card);
  border-radius:12px;
  padding:10px;
  box-shadow:0 3px 8px rgba(0,0,0,0.1);
  display:flex;
  flex-direction:column;
  gap:8px;
  opacity:0;
  transform:translateY(30px);
  transition:transform .3s,opacity .3s;
}

.card.show { 
  opacity:1;
  transform:translateY(0);
}

.thumb img {
  width:100%;
  height:clamp(100px,20vh,140px);
  object-fit:contain;border-radius:8px;
}

.title {
  font-size:clamp(12px,2vw,14px);
  font-weight:600;
}

.price { 
  color:var(--primary);
  font-weight:700;
  font-size:clamp(12px,2vw,14px);
}

.btn { 
  background:var(--primary);
  border:none;
  color:#fff;
  border-radius:8px;
  padding:6px 10px;
  cursor:pointer;
  font-weight:600;
  transition:background .3s;
}

.btn:hover { 
  background:#e6b800;
}

.footer-wrapper { 
  position:fixed;
  bottom:0;
  left:0;
  right:0;
  background:#fff;
  border-top:1px solid #ddd;
  height:70px;
  display:flex;
  align-items:center;
  justify-content:center;
  box-shadow:0 -2px 10px rgba(0,0,0,0.1);
  z-index:99;
}

.home-btn { 
  background:linear-gradient(135deg,#f4b400,gold);
  width:70px;
  height:70px;
  border-radius:50%;
  display:flex;
  align-items:center;
  justify-content:center;
  transform:translateY(-20%);
  box-shadow:0 6px 14px rgba(0,0,0,0.25);
  cursor:pointer;
  transition:.3s;
}

.home-btn:hover {
  transform:translateY(-25%) scale(1.05);
}

.sidebar{
  position:fixed;
  top:0;
  left:-300px;
  width:260px;
  height:100%;
  background:linear-gradient(135deg,#f4b400,gold);
  box-shadow:2px 0 12px rgba(0,0,0,0.2);
  padding:20px;
  transition:left .3s;
  z-index:150;
}

.sidebar.show {
  left:0;
}

.sidebar h3 { 
  margin-top:0;
  color:#000;
  font-size:18px;
}

.sidebar ul { 
  list-style:none;
  padding:0;
  margin:20px 0 0;
  display:flex;
  flex-direction:column;
  gap:15px;
}

.sidebar ul li a {
  text-decoration:none;
  color:#fff;
  font-weight:600;
  display:flex;
  align-items:center;
  gap:10px;
}

.sidebar ul li a:hover {
  color:#000
}

.overlay { 
  position:fixed;
  inset:0;
  background:rgba(0,0,0,0.4);
  opacity:0;
  visibility:hidden;
  transition:opacity .3s;
  z-index:140;
}

.overlay.show { 
  opacity:1;
  visibility:visible;
}

.popup { 
  position:fixed;
  inset:0;
  background:rgba(0,0,0,0.6);
  display:flex;
  align-items:center;
  justify-content:center;
  z-index:999999;
  opacity:0;
  visibility:hidden;
}

.popup.show { 
  opacity:1;
  visibility:visible;
}

.popup-content {
  background:#fff;
  border-radius:16px;
  padding:18px;
  width:92%;
  max-width:760px;
  box-shadow:var(--shadow);
  color:#000;
  max-height:90vh;
  overflow-y:auto;
  position:relative;
  transform:translateY(30px);
  transition:transform .35s ease,opacity .35s;
}

.popup.show .popup-content { 
  transform:translateY(0);
  opacity:1;
}

.popup-content .close { 
  position:absolute;
  top:12px;
  right:14px;
  font-size:30px;
  background:none;
  border:none;
  cursor:pointer;
  color:#555;
  z-index: 9999999999;
}


.popup-grid { 
  display:flex;
  gap:16px;
  align-items:flex-start;
  opacity:0;
  transform:translateY(10px);
  transition:opacity .45s,transform .45s;
}

.popup-grid.show { 
  opacity:1;
  transform:translateY(0);
}

.left-info { 
  flex:0 0 42%;
  background:#f7f7f9;
  border-radius:12px;
  padding:14px;
  box-shadow:0 2px 8px rgba(0,0,0,0.06);
}

.left-info p {
  margin:8px 0;
  font-size:14px;
  color:#111;
}

.left-info .label {
  color:var(--muted);
  font-size:13px;
}

.right-form { 
  flex:1 1 58%;
}

.right-form label { 
  display:block;
  margin:8px 0 6px;
  font-weight:600;
  font-size:13px;
}

.right-form select,.right-form input { 
  width:100%;
  padding:10px;
  border-radius:8px;
  border:1px solid #ddd;
  outline:none;
  font-size:14px;
}

.right-form .account-info {
  background:#f0f0f0;
  padding:10px;
  border-radius:8px;
  margin-bottom:10px;
  font-size:13px;
}

.right-form .account-info p { 
  margin:4px 0;
  color:#111;
}

.right-form .qris-img { 
  display:block;
  margin:8px auto;
  width:160px;
  max-width:100%;
  border-radius:6px;
  background:#fff;
  padding:8px;
  box-shadow:0 2px 6px rgba(0,0,0,0.06);
}

.nominal-line { 
  margin-top:8px;
  font-weight:700;
  font-size:15px;
  color:var(--primary);
  text-align:left;
}

.send-row { 
  margin-top:12px;
}

.send-row button { 
  width:100%;
  padding:12px;
  border-radius:8px;
  border:none;
  background:var(--primary);
  color:#fff;
  font-weight:700;
  cursor:pointer;
  transition:background .3s;
}
.send-row button:hover { 
  background:#e6b800;
}

@media (max-width:700px){
  .popup-grid {
    flex-direction:column;
  }
  .left-info,.right-form {
    width:100%;
    flex-basis:auto;
  }
}
