/* Sarani Tembakau — v1 (tema hijau tembakau & krem, mobile-first) */

:root {
  --hijau: #0e5c4f;
  --hijau-tua: #0a3f36;
  --hijau-muda: #e3f0ec;
  --krem: #faf6ec;
  --emas: #c19a4b;
  --coklat: #7a5230;
  --tinta: #26302d;
  --abu: #6b7572;
  --merah: #b3452e;
  --kartu: #ffffff;
  --radius: 14px;
  --bayangan: 0 1px 3px rgba(20, 40, 35, .10), 0 4px 14px rgba(20, 40, 35, .06);
}

* { box-sizing: border-box; }

/* atribut hidden harus selalu menang atas display dari class lain (mis. .modal) */
[hidden] { display: none !important; }

body {
  margin: 0;
  font-family: "Segoe UI", system-ui, -apple-system, Roboto, "Helvetica Neue", Arial, sans-serif;
  color: var(--tinta);
  background: var(--krem);
  line-height: 1.5;
}

a { color: var(--hijau); }

/* ===== Topbar ===== */
.topbar {
  position: sticky;
  top: 0;
  z-index: 20;
  display: flex;
  flex-wrap: wrap;
  gap: 6px 16px;
  align-items: center;
  justify-content: space-between;
  padding: 10px 16px;
  background: var(--krem);
  border-bottom: 2px solid var(--hijau);
}

.brand { display: flex; align-items: center; gap: 10px; }
.brand-logo {
  width: 42px; height: 42px;
  border-radius: 50%;
  object-fit: cover;
  border: 2px solid var(--emas);
  background: #efe6d2;
}
.brand-text strong {
  display: block;
  font-family: Georgia, "Times New Roman", serif;
  font-size: 18px;
  letter-spacing: .06em;
  color: var(--hijau-tua);
}
.brand-text small { color: var(--abu); font-size: 11px; }

.nav { display: flex; gap: 4px; flex-wrap: wrap; }
.nav a {
  text-decoration: none;
  font-size: 13px;
  font-weight: 600;
  color: var(--hijau-tua);
  padding: 7px 10px;
  border-radius: 999px;
}
.nav a:hover { background: var(--hijau-muda); }

/* ===== Hero ===== */
.hero {
  padding: 34px 16px 40px;
  text-align: center;
  color: #f4f1e6;
  background:
    radial-gradient(circle at 85% 15%, rgba(193, 154, 75, .25), transparent 45%),
    radial-gradient(circle at 10% 90%, rgba(193, 154, 75, .18), transparent 40%),
    linear-gradient(160deg, var(--hijau) 0%, var(--hijau-tua) 100%);
}
.hero-logo {
  display: block;
  width: 132px; height: 132px;
  margin: 0 auto 16px;
  border-radius: 50%;
  object-fit: cover;
  border: 3px solid rgba(244, 241, 230, .85);
  box-shadow: 0 10px 30px rgba(0, 0, 0, .30);
}
.hero h1 {
  margin: 0 auto 10px;
  max-width: 560px;
  font-family: Georgia, "Times New Roman", serif;
  font-size: clamp(24px, 5vw, 34px);
  line-height: 1.25;
}
.hero p { margin: 0 auto 16px; max-width: 520px; opacity: .92; }

.hero-info {
  display: flex;
  flex-direction: column;
  gap: 4px;
  align-items: center;
  font-size: 14px;
  opacity: .95;
}

.hero-aksi { display: flex; gap: 10px; justify-content: center; flex-wrap: wrap; margin: 18px 0 10px; }
.hero-note { font-size: 12px; opacity: .75; }

/* ===== Tombol ===== */
.btn {
  display: inline-block;
  padding: 10px 18px;
  border-radius: 999px;
  border: 2px solid transparent;
  font-weight: 700;
  font-size: 14px;
  text-decoration: none;
  cursor: pointer;
  transition: transform .06s ease, filter .15s ease;
}
.btn:active { transform: scale(.97); }
.btn-primary { background: var(--hijau); color: #fff; }
.btn-primary:hover { filter: brightness(1.08); }
.btn-wa { background: #1faa53; color: #fff; }
.btn-wa:hover { filter: brightness(1.06); }
.btn-ghost-terang { border-color: rgba(255,255,255,.6); color: #fff; }
.btn-ghost-terang:hover { background: rgba(255,255,255,.12); }
.btn-outline { border-color: var(--hijau); color: var(--hijau); background: transparent; }
.btn-pesan { width: 100%; text-align: center; padding: 8px 12px; font-size: 13px; background: var(--hijau-muda); color: var(--hijau-tua); }

/* ===== Katalog ===== */
.katalog { max-width: 1020px; margin: 0 auto; padding: 34px 16px 10px; }
.katalog h2 { margin: 0 0 4px; font-family: Georgia, serif; color: var(--hijau-tua); font-size: 24px; }
.katalog .sub { margin: 0 0 16px; color: var(--abu); font-size: 14px; }

.tag-21 {
  display: inline-block;
  vertical-align: middle;
  margin-left: 6px;
  padding: 2px 9px;
  border-radius: 999px;
  background: var(--coklat);
  color: #fff;
  font-family: "Segoe UI", system-ui, sans-serif;
  font-size: 12px;
  letter-spacing: .04em;
}

.toolbar { display: flex; flex-direction: column; gap: 10px; margin-bottom: 16px; }
#cari {
  width: 100%;
  padding: 11px 16px;
  border: 2px solid var(--hijau-muda);
  border-radius: 999px;
  font-size: 15px;
  background: #fff;
  outline: none;
}
#cari:focus { border-color: var(--hijau); }

.chips { display: flex; gap: 8px; flex-wrap: wrap; }
.chip {
  padding: 7px 14px;
  border-radius: 999px;
  border: 1.5px solid var(--hijau-muda);
  background: #fff;
  color: var(--hijau-tua);
  font-size: 13px;
  font-weight: 600;
  cursor: pointer;
}
.chip.aktif { background: var(--hijau); border-color: var(--hijau); color: #fff; }

/* ===== Grid produk ===== */
.grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(160px, 1fr));
  gap: 12px;
}

.kartu {
  display: flex;
  flex-direction: column;
  gap: 6px;
  padding: 14px 12px 12px;
  background: var(--kartu);
  border-radius: var(--radius);
  box-shadow: var(--bayangan);
}
.kartu .avatar {
  width: 44px; height: 44px;
  display: grid; place-items: center;
  border-radius: 12px;
  background: var(--hijau-muda);
  color: var(--hijau);
  font-weight: 800;
  font-size: 15px;
  letter-spacing: .02em;
}

/* ilustrasi kemasan produk tembakau */
.foto {
  position: relative;
  height: 170px;
  border-radius: 12px;
  overflow: hidden;
  background: #ece1cb;
  border: 1px solid #e0d2b4;
  display: grid;
  place-items: center;
}
.foto img {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  object-fit: cover;
}
.foto .avatar-foto { width: 54px; height: 54px; border-radius: 50%; font-size: 17px; }
.kartu h3 {
  margin: 2px 0 0;
  font-size: 14px;
  line-height: 1.35;
  min-height: 2.7em;
}
.kartu .grup { font-size: 11px; color: var(--emas); font-weight: 700; text-transform: uppercase; letter-spacing: .05em; }
.kartu-bawah { display: flex; flex-direction: column; gap: 4px; margin-top: auto; }
.kartu .harga { font-size: 16px; color: var(--hijau-tua); }

/* keputusan pemilik: jumlah & status stok tidak ditampilkan di website */

/* ===== Gerbang umur ===== */
.katalog-tembakau { padding-bottom: 50px; }

.gate-box {
  text-align: center;
  padding: 34px 18px;
  background: #f3ece0;
  border: 2px dashed #d8c9ae;
  border-radius: var(--radius);
  color: var(--coklat);
}
.gate-ikon { font-size: 34px; margin-bottom: 6px; }
.gate-box .btn { margin-top: 14px; }

/* ===== Modal verifikasi umur ===== */
.modal {
  position: fixed; inset: 0; z-index: 50;
  display: grid; place-items: center;
  padding: 16px;
  background: rgba(10, 35, 30, .62);
}
.modal-card {
  width: min(420px, 100%);
  background: var(--krem);
  border-radius: 18px;
  padding: 26px 22px;
  text-align: center;
  box-shadow: 0 18px 50px rgba(0,0,0,.35);
}
.modal-card h3 { margin: 0 0 8px; font-family: Georgia, serif; color: var(--hijau-tua); }
.modal-card p { margin: 6px 0; }
.modal-kecil { font-size: 12.5px; color: var(--abu); }
.modal-aksi { display: flex; gap: 10px; justify-content: center; flex-wrap: wrap; margin-top: 14px; }
.gate-ditolak {
  margin-top: 14px;
  padding: 10px 12px;
  background: #f9e8e2;
  border-radius: 10px;
  color: var(--merah);
  font-size: 13.5px;
}

/* ===== Footer ===== */
.footer {
  margin-top: 30px;
  padding: 30px 16px 20px;
  background: var(--hijau-tua);
  color: #e9efe7;
}
.footer-kolom { max-width: 1020px; margin: 0 auto; display: grid; gap: 18px; }
.footer h3 { margin: 0 0 8px; font-family: Georgia, serif; }
.footer p { margin: 4px 0; font-size: 14px; }
.footer a { color: #f0d9a8; }
.footer-peringatan {
  padding: 12px 14px;
  background: rgba(0,0,0,.22);
  border-left: 4px solid var(--emas);
  border-radius: 8px;
  font-size: 13px;
}
.footer-kaki { max-width: 1020px; margin: 18px auto 0; padding-top: 12px; border-top: 1px solid rgba(255,255,255,.18); font-size: 12px; opacity: .75; text-align: center; }

.kosong { text-align: center; color: var(--abu); padding: 26px 0; }

/* ===== Layar lebih lebar ===== */
@media (min-width: 640px) {
  .toolbar { flex-direction: row; align-items: center; }
  #cari { width: 300px; }
  .hero-info { flex-direction: row; gap: 18px; flex-wrap: wrap; justify-content: center; }
  .footer-kolom { grid-template-columns: 1fr 1fr; align-items: start; }
}
