@import url("https://fonts.googleapis.com/css2?family=Baloo+2:wght@600;700;800&family=Poppins:wght@400;500;600;700&display=swap");

body {
  margin: 0;
  font-family: Arial, sans-serif;
  background: #eef5f0;
}
@font-face {
  font-family: "lato";
  src: url(../font/Lato-Regular.ttf);
}
@font-face {
  font-family: "jetbrains", sans-serif;
  src: url(../font/JetBrainsMonoNL-Regular.ttf);
}
/* header */
* {
  margin: 0;
  padding: 0;
  box-sizing: border-box;
  font-family: "Poppins", sans-serif;
}
header {
  background: linear-gradient(135deg, #0c937b, #0a7d68);
  padding: 14px 20px 0;
  color: #f5f5f5;
  position: sticky;
  top: 0;
  z-index: 500;
  box-shadow: 0 2px 14px rgba(0, 0, 0, 0.18);
}

.navbar {
  display: flex;
  align-items: center;
  justify-content: space-between;
  flex-wrap: wrap;
  gap: 14px;
  max-width: 1200px;
  margin: 0 auto;
  padding-bottom: 12px;
}
.brand-link {
  display: flex;
  align-items: center;
  gap: 10px;
  text-decoration: none;
  color: white;
}
.nav-logo {
  width: 48px;
  height: 48px;
  background: rgba(255, 255, 255, 0.16);
  border-radius: 12px;
  padding: 4px;
  transition: transform 0.3s ease;
}
.brand-link:hover .nav-logo {
  transform: rotate(-8deg) scale(1.06);
}
.logo {
  font-family: "Baloo 2", "Poppins", sans-serif;
  font-size: 1.7rem;
  font-weight: 800;
  letter-spacing: 0.4px;
  color: #ffffff;
}
.logo span {
  color: #ffd94a;
}

.search-box {
  position: relative;
  flex: 1 1 300px;
  max-width: 540px;
}
.search-bar {
  margin: 0;
  padding: 11px 48px 11px 18px;
  border-radius: 999px;
  border: 2px solid transparent;
  outline: none;
  width: 100%;
  min-width: 200px;
  font-size: 0.95rem;
  color: #222;
  background: white;
  transition: border-color 0.2s ease, box-shadow 0.2s ease;
}
.search-bar:focus {
  border-color: #7ef0d0;
  box-shadow: 0 0 0 4px rgba(255, 255, 255, 0.18);
}

.quick-links {
  display: flex;
  align-items: center;
  gap: 6px;
  flex-wrap: wrap;
  max-width: 1200px;
  margin: 0 auto;
  padding-bottom: 12px;
}
.quick-link {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  color: rgba(255, 255, 255, 0.88);
  text-decoration: none;
  font-size: 0.85rem;
  font-weight: 600;
  padding: 6px 14px;
  border-radius: 999px;
  border: 1px solid transparent;
  transition: background 0.2s ease, color 0.2s ease;
}
.quick-link:hover {
  background: rgba(255, 255, 255, 0.18);
  color: white;
}

.nav-buttons {
  display: flex;
  align-items: center;
  gap: 10px;
  flex-wrap: wrap;
}
.nav-buttons button {
  border: none;
  padding: 9px 22px;
  border-radius: 999px;
  font-weight: 700;
  font-size: 0.9rem;
  cursor: pointer;
  transition: transform 0.15s ease, box-shadow 0.15s ease, background 0.2s ease;
}
#loginBtn {
  background: rgba(255, 255, 255, 0.14);
  color: white;
  border: 1.5px solid rgba(255, 255, 255, 0.65);
}
#loginBtn:hover {
  background: rgba(255, 255, 255, 0.28);
  transform: translateY(-1px);
  box-shadow: 0 3px 10px rgba(0, 0, 0, 0.15);
}
#daftarBtn {
  background: linear-gradient(135deg, #ffd76a, #ffb347);
  color: #5a3b00;
  box-shadow: 0 3px 10px rgba(0, 0, 0, 0.15);
}
#daftarBtn:hover {
  transform: translateY(-1px);
  box-shadow: 0 5px 14px rgba(0, 0, 0, 0.22);
}

/* Agar anchor tidak tertutup header sticky */
section {
  scroll-margin-top: 130px;
}

/* Banner */
.banner img {
  width: 100%;
  height: 350px;
  object-fit: cover;
}

/* Container */
.container {
  max-width: 1100px;
  margin: 20px auto;
  padding: 10px;
}

/* Card */
.card {
  background: #ffffff;
  padding: 22px;
  border-radius: 16px;
  margin-bottom: 20px;
  border: 1px solid #e8f1ec;
  box-shadow: 0 4px 16px rgba(16, 60, 45, 0.07);
}
#inputId {
  display: flex;
  gap: 10px;
}
#inputId > input {
  width: 100%;
}
#inputId > input:nth-child(2) {
  max-width: 35%;
}
.card h3 {
  margin-top: 0;
  font-family: "Baloo 2", "Poppins", sans-serif;
  font-size: 1.15rem;
  color: #123c33;
  padding-left: 12px;
  border-left: 5px solid #0fd6a8;
  letter-spacing: 0.2px;
}

/* Layanan card */
.layanan .logo-area {
  display: flex;
  align-items: center;
  gap: 14px;
}

.layanan img {
  width: 64px;
  height: 64px;
  object-fit: cover;
  border: 3px solid #ffffff;
  box-shadow: 0 6px 14px rgba(12, 147, 123, 0.28);
}

.layanan .logo-area h2 {
  font-family: "Baloo 2", "Poppins", sans-serif;
  font-size: 1.65rem;
  letter-spacing: 0.3px;
  color: #0c6e5c;
}

.features {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
}

.features p {
  margin: 0;
  background: #ecfbf5;
  border: 1px solid #c9f0e2;
  color: #0b6b58;
  padding: 7px 13px;
  border-radius: 999px;
  font-size: 0.85rem;
  font-weight: 600;
}

.btn-merah,
.link-merah {
  background: linear-gradient(90deg, #0fd6a8, #0a9d8f);
  color: #fff;
  border: none;
  padding: 12px 20px;
  border-radius: 12px;
  cursor: pointer;
  font-weight: 700;
  font-size: 0.9rem;
  margin: 6px 6px 0 0;
  display: inline-block;
  text-decoration: none;
  box-shadow: 0 4px 12px rgba(15, 214, 168, 0.35);
  transition: transform 0.18s ease, box-shadow 0.18s ease, filter 0.18s ease;
}
.btn-merah:hover,
.link-merah:hover {
  transform: translateY(-2px);
  box-shadow: 0 8px 18px rgba(15, 214, 168, 0.45);
  filter: brightness(1.05);
}
/* sembunyikan tombol kosong agar tidak jadi blob hijau */
.btn-merah:empty {
  display: none;
}


/* Input */
input {
  width: 100%;
  padding: 12px 14px;
  border-radius: 10px;
  border: 2px solid #dce9e2;
  background: #fbfffd;
  margin: 10px 0;
  font-size: 0.95rem;
  color: #22303c;
  transition: border-color 0.2s ease, box-shadow 0.2s ease, background 0.2s ease;
}
input:focus {
  outline: none;
  border-color: #0fd6a8;
  background: #ffffff;
  box-shadow: 0 0 0 4px rgba(15, 214, 168, 0.15);
}
input::placeholder {
  color: #9ab5ab;
}
#perkiraanHarga {
  margin: 2px 0 8px;
  font-weight: 700;
  color: #0a9d4e;
  min-height: 1.3em;
}
#perkiraanHarga.error {
  color: #e63946;
}
.nominal-warning {
  margin: 0 0 6px;
  min-height: 1.2em;
  font-size: 0.85rem;
  font-weight: 600;
  color: #e63946;
}

/* Tabs */
.tabs {
  display: flex;
  gap: 8px;
  background: #e9f6f1;
  padding: 6px;
  border-radius: 14px;
  margin: 4px 0 14px;
}

.tab {
  flex: 1;
  padding: 11px;
  border-radius: 10px;
  background: transparent;
  border: none;
  cursor: pointer;
  font-weight: 700;
  color: #4b6b60;
  transition: background 0.2s ease, color 0.2s ease, box-shadow 0.2s ease;
}

.tab.active {
  background: linear-gradient(90deg, #0fd6a8, #0a9d8f);
  color: #fff;
  box-shadow: 0 4px 12px rgba(15, 214, 168, 0.4);
}

.tab:disabled {
  opacity: 0.45;
  cursor: not-allowed;
}

/* Grid */
.grid {
  display: none;
  margin-top: 15px;
  grid-template-columns: repeat(auto-fill, minmax(150px, 1fr));
  gap: 12px;
}

.grid.active {
  display: grid;
}

/* Nominal item */
.item {
  border-radius: 8px;
  padding: 15px;
  background: #f8fff8;
  border: 1px solid #cceccb;
  cursor: pointer;
  font-weight: bold;
}

.item span {
  display: block;
  margin-top: 6px;
  color: #088a2f;
}

/* Payment */
.payment-group {
  display: flex;
  flex-direction: column;
  gap: 10px;
}

.payment {
  padding: 13px 16px;
  border-radius: 12px;
  background: linear-gradient(90deg, #0fd6a8, #0a9d8f);
  color: #fff;
  font-weight: bold;
  border: none;
  cursor: pointer;
  box-shadow: 0 4px 12px rgba(15, 214, 168, 0.3);
  transition: transform 0.18s ease, box-shadow 0.18s ease, filter 0.18s ease;
}
.payment:hover {
  transform: translateY(-2px);
  filter: brightness(1.05);
  box-shadow: 0 8px 16px rgba(15, 214, 168, 0.4);
}

/* Button hijau */
#btn-hijau {
  width: 100%;
  padding: 14px;
  background: linear-gradient(90deg, #10cc67, #0a9d8f);
  color: #fff;
  border: none;
  font-weight: bold;
  font-size: 1rem;
  letter-spacing: 0.3px;
  border-radius: 12px;
  display: block;
  cursor: pointer;
  text-align: center;
  text-decoration: none;
  box-shadow: 0 6px 16px rgba(16, 204, 103, 0.35);
  transition: transform 0.18s ease, box-shadow 0.18s ease, filter 0.18s ease;
}
#btn-hijau:hover {
  transform: translateY(-2px);
  filter: brightness(1.05);
  box-shadow: 0 10px 20px rgba(16, 204, 103, 0.45);
}
.item {
  position: relative;
  border-radius: 14px;
  padding: 14px 15px;
  background: linear-gradient(160deg, #ffffff 0%, #f4fbf8 100%);
  border: 2px solid #e2f0e9;
  cursor: pointer;
  font-weight: bold;
  color: #22303c;
  box-shadow: 0 2px 6px rgba(16, 60, 45, 0.06);
  transition: transform 0.18s ease, box-shadow 0.18s ease, border-color 0.18s ease;
}
.item::after {
  content: "";
  position: absolute;
  top: -16px;
  right: -16px;
  width: 44px;
  height: 44px;
  border-radius: 50%;
  background: radial-gradient(circle, rgba(15, 214, 168, 0.18), transparent 70%);
  pointer-events: none;
}
.item:hover {
  transform: translateY(-3px);
  border-color: #0fd6a8;
  box-shadow: 0 8px 18px rgba(12, 147, 123, 0.2);
}
.item > h4,
.item > p {
  font-family: "Poppins", sans-serif;
  margin: 0;
}
.item span {
  display: block;
  margin-top: 6px;
  color: #0a9d4e;
  font-family: "Baloo 2", "Poppins", sans-serif;
  letter-spacing: 0.3px;
}
/* Efek ketika dipilih */
.item.selected {
  background: linear-gradient(160deg, #e6fff4 0%, #ccffe9 100%);
  border-color: #00c46b;
  box-shadow: 0 0 0 4px rgba(0, 196, 107, 0.15), 0 8px 18px rgba(0, 180, 80, 0.28);
  transform: translateY(-2px) scale(1.02);
}
.item.selected::before {
  content: "✓";
  position: absolute;
  top: 8px;
  right: 10px;
  width: 20px;
  height: 20px;
  border-radius: 50%;
  background: #00c46b;
  color: #fff;
  font-size: 0.75rem;
  font-weight: 700;
  display: flex;
  align-items: center;
  justify-content: center;
}
.payment-methods {
  display: flex;
  gap: 15px;
  border: 2px;
  flex-wrap: wrap;
}

.payment-card {
  width: 140px;
  padding: 15px;
  margin: 10px;
  border: 2px solid #ccc;
  border-radius: 12px;
  text-align: center;
  cursor: pointer;
  transition: 0.2s;
  display: flex;
  flex-direction: column;
  gap: 8px;
  align-items: center;
  transition: 0.3s;
}
.payment-card img {
  width: 50px;
  border-radius: 10px;
}

.payment-card input {
  display: none;
}

.payment-card:has(input:checked) {
  border: 3px solid #4caf50;
  box-shadow: 0 0 8px rgba(76, 175, 80, 0.2);
  color: #4caf50;
  transform: scale(1.05);
  background: #d2ffe0;
}
.payment-card:hover {
  border-color: #888;
}

/* ============================================================
   INVOICE — MODERN REDESIGN
   ============================================================ */
@keyframes inv-fade-up {
  from { opacity: 0; transform: translateY(14px); }
  to   { opacity: 1; transform: translateY(0); }
}
@keyframes inv-pulse-ring {
  0%   { box-shadow: 0 0 0 0 rgba(14, 177, 147, 0.45); }
  70%  { box-shadow: 0 0 0 9px rgba(14, 177, 147, 0); }
  100% { box-shadow: 0 0 0 0 rgba(14, 177, 147, 0); }
}
@keyframes inv-dot-blink {
  0%, 100% { opacity: 1; transform: scale(1); }
  50%      { opacity: 0.45; transform: scale(0.8); }
}
@keyframes inv-slide-bg {
  from { background-position: 0% 50%; }
  to   { background-position: 100% 50%; }
}
@keyframes inv-pop {
  0%   { transform: scale(0.6); opacity: 0; }
  70%  { transform: scale(1.06); }
  100% { transform: scale(1); opacity: 1; }
}
@keyframes confetti-fall {
  0%   { transform: translate3d(0, -12px, 0) rotate(0deg); opacity: 1; }
  100% { transform: translate3d(var(--cx, 0px), 340px, 0) rotate(var(--cr, 540deg)); opacity: 0; }
}

/* --- Header: gradient brand bergerak + dekorasi --- */
.invoice-header {
  display: flex;
  justify-content: space-between;
  align-items: center;
  background: linear-gradient(120deg, #0a7d68, #0c937b 35%, #12b588 60%, #0a7d68);
  background-size: 220% 100%;
  animation: inv-slide-bg 7s ease-in-out infinite alternate;
  padding: 18px 22px;
  color: #fff;
  border-radius: 16px;
  flex-wrap: wrap;
  gap: 10px;
  position: relative;
  overflow: hidden;
  box-shadow: 0 10px 24px rgba(10, 125, 104, 0.28);
}
.invoice-header::after {
  content: "";
  position: absolute;
  inset: 0;
  background:
    radial-gradient(120px 70px at 88% 20%, rgba(255, 255, 255, 0.18), transparent 70%),
    radial-gradient(160px 90px at 8% 110%, rgba(255, 255, 255, 0.12), transparent 70%);
  pointer-events: none;
}
.invoice-header h2 {
  display: inline-flex;
  align-items: center;
  gap: 10px;
  font-size: 1.25rem;
  font-weight: 800;
  letter-spacing: 0.4px;
  margin: 0;
}
.invoice-header h2::before {
  content: "🧾";
  filter: drop-shadow(0 2px 3px rgba(0, 0, 0, 0.25));
}
.print-btn {
  background: rgba(255, 255, 255, 0.16);
  color: #fff;
  border: 1.5px solid rgba(255, 255, 255, 0.55);
  padding: 9px 18px;
  border-radius: 999px;
  cursor: pointer;
  font-weight: 700;
  font-size: 0.85rem;
  transition: background 0.2s ease, transform 0.15s ease;
  position: relative;
  z-index: 1;
}
.print-btn:hover {
  background: rgba(255, 255, 255, 0.3);
  transform: translateY(-1px);
}
.print-btn::before { content: "🖨️ "; }

/* --- Box utama --- */
.invoice-box {
  background: #ffffff;
  margin-top: 18px;
  padding: clamp(16px, 3vw, 26px);
  border-radius: 20px;
  border: 1px solid #e4efe9;
  box-shadow: 0 8px 22px rgba(16, 60, 50, 0.07);
  position: relative;
  overflow: hidden;
}
#ordered.revealed .invoice-box > * {
  animation: inv-fade-up 0.55s ease both;
}
#ordered.revealed .invoice-box > *:nth-child(2) { animation-delay: 0.06s; }
#ordered.revealed .invoice-box > *:nth-child(3) { animation-delay: 0.12s; }
#ordered.revealed .invoice-box > *:nth-child(4) { animation-delay: 0.18s; }
#ordered.revealed .invoice-box > *:nth-child(5) { animation-delay: 0.24s; }
#ordered.revealed .invoice-box > *:nth-child(6) { animation-delay: 0.3s; }
#ordered.revealed .invoice-box > *:nth-child(7) { animation-delay: 0.36s; }

/* INV-PART-1B */

/* --- Baris info atas: ID invoice + tanggal --- */
.top-info {
  display: flex;
  justify-content: space-between;
  align-items: center;
  flex-wrap: wrap;
  gap: 10px;
}
#invoice-id {
  display: inline-flex;
  align-items: center;
  gap: 10px;
  margin: 0;
  font-family: "JetBrainsMono", monospace;
  font-size: 1.05rem;
  font-weight: 700;
  letter-spacing: 1.5px;
  color: #0a7d68;
  background: #e8faf4;
  border: 1.5px dashed #7ad7bf;
  padding: 8px 14px;
  border-radius: 12px;
}
.copy-chip {
  border: none;
  background: #0eb193;
  color: #fff;
  font-size: 0.72rem;
  font-weight: 700;
  padding: 5px 11px;
  border-radius: 999px;
  cursor: pointer;
  letter-spacing: 0.3px;
  transition: background 0.2s ease, transform 0.12s ease;
}
.copy-chip:hover { background: #0a7d68; transform: translateY(-1px); }
.copy-chip:active { transform: scale(0.94); }
.copy-chip.copied { background: #18a558; }
.top-info .date {
  color: #7a8a84;
  font-size: 0.85rem;
  font-weight: 600;
}
.top-info .date::before { content: "🕒 "; }

/* --- Stepper status (Dibuat -> Verifikasi -> Selesai) --- */
.order-stepper {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  margin: 20px 4px 6px;
  position: relative;
}
.order-stepper .step {
  flex: 1;
  text-align: center;
  position: relative;
  z-index: 1;
}
.order-stepper .step .dot {
  width: 34px;
  height: 34px;
  border-radius: 50%;
  margin: 0 auto 7px;
  display: flex;
  align-items: center;
  justify-content: center;
  font-weight: 800;
  font-size: 0.9rem;
  background: #e8e8e8;
  color: #9aa5a0;
  border: 2px solid #dfe5e2;
  transition: background 0.3s ease, color 0.3s ease, border-color 0.3s ease;
}
.order-stepper .step .lbl {
  font-size: 0.72rem;
  font-weight: 700;
  color: #9aa5a0;
  letter-spacing: 0.3px;
  text-transform: uppercase;
}
.order-stepper .step::before,
.order-stepper .step::after {
  content: "";
  position: absolute;
  top: 17px;
  height: 3px;
  background: #e2e8e5;
  border-radius: 3px;
  width: calc(50% - 24px);
  transition: background 0.4s ease;
}
.order-stepper .step::before { left: 0; }
.order-stepper .step::after  { right: 0; }
.order-stepper .step:first-child::before,
.order-stepper .step:last-child::after { display: none; }
.order-stepper .step.is-done .dot {
  background: linear-gradient(135deg, #0c937b, #2ed9b3);
  border-color: transparent;
  color: #fff;
}
.order-stepper .step.is-done .lbl { color: #0a7d68; }
.order-stepper .step.is-done::before,
.order-stepper .step.is-done::after,
.order-stepper .step.is-active::before {
  background: linear-gradient(90deg, #0c937b, #2ed9b3);
}
.order-stepper .step.is-active .dot {
  background: #fff;
  border-color: #0eb193;
  color: #0a7d68;
  animation: inv-pulse-ring 1.8s ease-out infinite;
}
.order-stepper .step.is-active .lbl { color: #0c937b; }
.order-stepper.is-error .step .dot {
  background: #fdecee;
  border-color: #e63946;
  color: #c0303d;
  animation: none;
}
.order-stepper.is-error .step .lbl { color: #c0303d; }

/* INV-PART-2 */
/* --- Pill status di dalam invoice (scoped ke #ordered, bukan tab produk) --- */
#ordered .tabs {
  display: flex;
  margin-top: 16px;
  flex-wrap: wrap;
}
#ordered .tabs .tab {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  flex: 0 1 auto;
  padding: 8px 18px;
  background: #e8faf4;
  color: #0a7d68;
  border: 1.5px solid #b9e8da;
  cursor: default;
  border-radius: 999px;
  margin: 0;
  min-width: 0;
  font-weight: 800;
  font-size: 0.9rem;
  letter-spacing: 0.3px;
  transition: background 0.3s ease, color 0.3s ease, border-color 0.3s ease;
}
#ordered .tabs .tab::before {
  content: "";
  width: 9px;
  height: 9px;
  border-radius: 50%;
  background: #0eb193;
  animation: inv-dot-blink 1.4s ease-in-out infinite;
}
#ordered .tabs .tab.tab--done {
  background: #e6f9f3;
  border-color: #0eb193;
  color: #0b7a63;
  animation: inv-pop 0.45s ease both;
}
#ordered .tabs .tab.tab--done::before {
  content: "✓";
  width: auto;
  height: auto;
  background: none;
  animation: none;
  font-size: 0.9rem;
}
#ordered .tabs .tab.tab--failed {
  background: #fdecee;
  border-color: #e63946;
  color: #c0303d;
}
#ordered .tabs .tab.tab--failed::before {
  background: #e63946;
  animation: none;
}

/* --- Timer kedaluwarsa: kartu jam digital --- */
.timer-box {
  text-align: center;
  margin: 20px auto 4px;
  max-width: 400px;
  background: linear-gradient(160deg, #123c33, #1d5c4d);
  border-radius: 18px;
  padding: 16px 18px 14px;
  color: #d9efe8;
  box-shadow: 0 10px 20px rgba(18, 60, 51, 0.22);
  position: relative;
  overflow: hidden;
}
.timer-box::after {
  content: "";
  position: absolute;
  inset: 0;
  background: radial-gradient(140px 60px at 85% 0%, rgba(46, 217, 179, 0.25), transparent 70%);
  pointer-events: none;
}
.timer-box p {
  margin: 0 0 8px;
  font-size: 0.78rem;
  font-weight: 700;
  letter-spacing: 1.2px;
  text-transform: uppercase;
  color: #9fd8c9;
}
#timer {
  display: inline-block;
  font-family: "JetBrainsMono", monospace;
  font-size: 34px;
  font-weight: 700;
  letter-spacing: 4px;
  color: #3ef0c2;
  text-shadow: 0 0 14px rgba(62, 240, 194, 0.45);
  line-height: 1.1;
  position: relative;
  z-index: 1;
}
.timer-box .timer-progress {
  height: 5px;
  border-radius: 5px;
  background: rgba(255, 255, 255, 0.14);
  margin-top: 12px;
  overflow: hidden;
  position: relative;
  z-index: 1;
}
.timer-box .timer-progress::after {
  content: "";
  display: block;
  height: 100%;
  width: var(--p, 100%);
  border-radius: 5px;
  background: linear-gradient(90deg, #2ed9b3, #ffd94a);
  transition: width 0.6s linear, background 0.4s ease;
}
.timer-box.warn {
  background: linear-gradient(160deg, #4d3612, #7a5a1d);
}
.timer-box.warn #timer {
  color: #ffd94a;
  text-shadow: 0 0 14px rgba(255, 217, 74, 0.5);
}
.timer-box.warn .timer-progress::after {
  background: linear-gradient(90deg, #ffb347, #ffd94a);
}
.timer-box.danger {
  background: linear-gradient(160deg, #5c1d1d, #8a3030);
  animation: inv-dot-blink 1.6s ease-in-out infinite;
}
.timer-box.danger #timer {
  color: #ff8a8a;
  text-shadow: 0 0 16px rgba(255, 138, 138, 0.55);
}
.timer-box.danger .timer-progress::after {
  background: linear-gradient(90deg, #e63946, #ff8a8a);
}

/* INV-PART-2B */

/* --- Konten dua kolom --- */
.content {
  display: grid;
  grid-template-columns: 1.05fr 0.95fr;
  gap: 20px;
  margin-top: 22px;
}
.left,
.right {
  background: #fbfefd;
  border: 1px solid #e4efe9;
  padding: 20px;
  border-radius: 18px;
  min-width: 0;
}

/* Gambar Produk */
.product-img {
  width: 116px;
  border-radius: 16px;
  max-width: 100%;
  box-shadow: 0 8px 18px rgba(16, 60, 50, 0.18);
  border: 3px solid #fff;
  outline: 1.5px solid #dcefe7;
  transition: transform 0.25s ease;
}
.product-img:hover { transform: scale(1.04) rotate(-1deg); }

/* Detail pesanan (baris label-nilai rapi) */
.detail {
  margin-top: 16px;
  display: flex;
  flex-direction: column;
  gap: 4px;
}
.detail .row {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  padding: 9px 12px;
  border-radius: 10px;
  transition: background 0.15s ease;
}
.detail .row:hover { background: #f2faf7; }
.detail .row .k {
  font-size: 0.72rem;
  font-weight: 800;
  letter-spacing: 1px;
  text-transform: uppercase;
  color: #8ba39b;
  white-space: nowrap;
}
.detail .row .v {
  font-weight: 700;
  color: #223c34;
  text-align: right;
  word-break: break-word;
  display: inline-flex;
  align-items: center;
  gap: 8px;
}
.detail .total-row {
  margin-top: 8px;
  background: linear-gradient(135deg, #e8faf4, #dcf7ee);
  border: 1.5px solid #b9e8da;
}
.detail .total-row .v {
  font-size: 1.15rem;
  font-weight: 800;
  color: #0a7d68;
}
.copy-mini {
  border: none;
  background: #e4f5ef;
  color: #0a7d68;
  width: 26px;
  height: 26px;
  border-radius: 8px;
  cursor: pointer;
  font-size: 0.8rem;
  line-height: 1;
  transition: background 0.2s ease, transform 0.12s ease;
  flex-shrink: 0;
}
.copy-mini:hover { background: #cdeee2; transform: translateY(-1px); }
.copy-mini:active { transform: scale(0.9); }
.detail .mini-note {
  margin-top: 10px;
  font-size: 0.85rem;
  line-height: 1.5;
  padding: 10px 14px;
  border-radius: 12px;
  background: #f6fbf9;
  border: 1px dashed #cfe6dd;
}
.detail .mini-note.ok { color: #0b7a63; }
.detail .mini-note.warn { color: #b26a00; }
.detail .mini-note.muted { color: #7a8a84; }
.detail .mini-note a { color: #0eb193; font-weight: 700; }

/* --- Panel pembayaran --- */
#paymentOrdered h3 {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  margin: 0 0 4px;
  font-size: 1rem;
  color: #223c34;
}
#paymentOrdered h3::before { content: "💳"; }
#paymentOrdered .pay-method {
  display: inline-block;
  background: #eef7f3;
  border: 1px solid #d7ebe2;
  color: #0a7d68;
  font-weight: 700;
  font-size: 0.8rem;
  padding: 4px 12px;
  border-radius: 999px;
  margin-bottom: 12px;
}
.qris-img {
  width: 230px;
  max-width: 100%;
  display: block;
  margin: 6px auto 14px;
  border-radius: 18px;
  border: 1.5px solid #e0efe8;
  box-shadow: 0 10px 22px rgba(16, 60, 50, 0.12);
  transition: transform 0.25s ease, box-shadow 0.25s ease;
}
.qris-img:hover {
  transform: translateY(-3px) scale(1.02);
  box-shadow: 0 14px 28px rgba(16, 60, 50, 0.18);
}
#totalPembayaran {
  text-align: center;
  margin: 0 0 12px;
  color: #7a8a84;
  font-size: 0.85rem;
  font-weight: 600;
}
#totalPembayaran b {
  display: block;
  margin-top: 2px;
  font-size: 1.45rem;
  font-weight: 800;
  background: linear-gradient(120deg, #0a7d68, #12b588);
  -webkit-background-clip: text;
  background-clip: text;
  color: transparent;
  letter-spacing: 0.5px;
}
.pay-note {
  font-size: 0.83rem;
  color: #7a8a84;
  line-height: 1.55;
  background: #fff9ec;
  border: 1px dashed #f0d9a0;
  border-radius: 12px;
  padding: 10px 14px;
  margin-top: 12px;
}
.pay-note b { color: #8a5a00; }

/* INV-PART-3 */

/* --- Tombol unduh QR dengan efek shine --- */
.download-btn {
  width: 100%;
  background: linear-gradient(120deg, #0c937b, #2ed9b3);
  color: #fff;
  font-family: inherit;
  font-size: 0.92rem;
  font-weight: 800;
  letter-spacing: 0.3px;
  border: none;
  padding: 12px;
  border-radius: 999px;
  cursor: pointer;
  position: relative;
  overflow: hidden;
  transition: transform 0.15s ease, box-shadow 0.2s ease;
  box-shadow: 0 6px 16px rgba(14, 177, 147, 0.35);
}
.download-btn::before {
  content: "⬇ ";
  font-size: 0.9rem;
}
.download-btn::after {
  content: "";
  position: absolute;
  top: 0;
  left: 0;
  width: 45%;
  height: 100%;
  background: linear-gradient(105deg, transparent, rgba(255, 255, 255, 0.45), transparent);
  transform: translateX(-130%) skewX(-18deg);
  animation: inv-shine 3.2s ease-in-out infinite;
}
.download-btn:hover {
  transform: translateY(-2px);
  box-shadow: 0 10px 22px rgba(14, 177, 147, 0.45);
}
.download-btn:active { transform: scale(0.97); }

/* --- Tombol konfirmasi WhatsApp --- */
.konfirm-btn {
  background: linear-gradient(120deg, #128c7e, #25d366);
  width: 100%;
  border: none;
  padding: 14px;
  border-radius: 999px;
  cursor: pointer;
  font-family: inherit;
  font-size: 0.98rem;
  font-weight: 800;
  letter-spacing: 0.3px;
  color: #fff;
  margin-top: 22px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 10px;
  position: relative;
  overflow: hidden;
  box-shadow: 0 8px 20px rgba(18, 140, 126, 0.35);
  transition: transform 0.15s ease, box-shadow 0.2s ease, filter 0.2s ease;
}
.konfirm-btn::before { content: "💬"; font-size: 1.05rem; }
.konfirm-btn::after {
  content: "";
  position: absolute;
  top: 0;
  left: 0;
  width: 45%;
  height: 100%;
  background: linear-gradient(105deg, transparent, rgba(255, 255, 255, 0.35), transparent);
  transform: translateX(-130%) skewX(-18deg);
  animation: inv-shine 4s ease-in-out infinite;
}
@keyframes inv-shine {
  0%        { transform: translateX(-130%) skewX(-18deg); }
  55%, 100% { transform: translateX(230%) skewX(-18deg); }
}
.konfirm-btn:hover {
  transform: translateY(-2px);
  box-shadow: 0 12px 26px rgba(18, 140, 126, 0.45);
  filter: saturate(1.1);
}
.konfirm-btn:active { transform: scale(0.98); }

/* Link "buat orderan lagi" -> pill ghost di tengah */
#ordered .invoice-box > a {
  display: table;
  margin: 16px auto 0;
  font-size: 0.85rem;
  font-weight: 700;
  color: #0a7d68;
  text-decoration: none;
  padding: 8px 20px;
  border-radius: 999px;
  border: 1.5px dashed #9fd8c9;
  transition: background 0.2s ease, border-color 0.2s ease, transform 0.15s ease;
}
#ordered .invoice-box > a:hover {
  background: #e8faf4;
  border-color: #0eb193;
  transform: translateY(-1px);
}

/* --- Banner status order (#orderStatusBanner) --- */
#orderStatusBanner {
  margin: 0 0 16px;
  padding: 13px 16px;
  border-radius: 14px;
  font-size: 0.9rem;
  font-weight: 600;
  line-height: 1.55;
  border: 1px solid transparent;
  animation: inv-fade-up 0.4s ease both;
}
#orderStatusBanner.st-pending {
  background: #fff9ec;
  color: #8a5a00;
  border-color: #f0d9a0;
}
#orderStatusBanner.st-done {
  background: #e6f9f3;
  color: #0b7a63;
  border-color: #0eb193;
  animation: inv-pop 0.5s ease both;
}
#orderStatusBanner.st-failed {
  background: #fdecee;
  color: #c0303d;
  border-color: #e63946;
}

/* --- Confetti saat pesanan selesai --- */
.confetti {
  position: absolute;
  inset: 0;
  pointer-events: none;
  overflow: hidden;
  z-index: 5;
}
.confetti i {
  position: absolute;
  top: -12px;
  width: 8px;
  height: 14px;
  border-radius: 2px;
  background: var(--c, #2ed9b3);
  left: var(--x, 50%);
  animation: confetti-fall var(--d, 2.4s) ease-in var(--dl, 0s) forwards;
  opacity: 0;
}

/* --- Toast notifikasi kecil (copy, dsb.) --- */
#hekaToast {
  position: fixed;
  left: 50%;
  bottom: 28px;
  transform: translate(-50%, 16px);
  background: #123c33;
  color: #eafff8;
  font-size: 0.85rem;
  font-weight: 700;
  padding: 10px 22px;
  border-radius: 999px;
  box-shadow: 0 10px 26px rgba(0, 0, 0, 0.25);
  opacity: 0;
  pointer-events: none;
  transition: opacity 0.25s ease, transform 0.25s ease;
  z-index: 9999;
}
#hekaToast.show {
  opacity: 1;
  transform: translate(-50%, 0);
}

/* --- Responsif invoice --- */
@media (max-width: 820px) {
  .content {
    grid-template-columns: 1fr;
  }
  .konfirm-btn,
  .download-btn {
    font-size: 0.9rem;
  }
}
@media (max-width: 480px) {
  .invoice-header {
    flex-direction: column;
    text-align: center;
    gap: 10px;
  }
  .invoice-header h2 { justify-content: center; }
  #timer { font-size: 27px; letter-spacing: 3px; }
  .product-img { width: 100px; }
  .order-stepper .step .lbl { font-size: 0.62rem; }
  .order-stepper .step .dot { width: 29px; height: 29px; font-size: 0.8rem; }
  .order-stepper .step::before,
  .order-stepper .step::after { width: calc(50% - 20px); }
  .detail .row { flex-direction: column; align-items: flex-start; gap: 2px; }
  .detail .row .v { text-align: left; }
}

/* --- Mode cetak / simpan PDF: bersihkan halaman, invoice saja --- */
@media print {
  header, footer, .banner-slider, .section:not(#ordered), .chooseBuy,
  #formUserId, #pilihNominal, #metodePembayaran, #dataPemesan, #deskripsiLayanan,
  #orderStatusBanner, .timer-box, .print-btn, .order-stepper {
    display: none !important;
  }
  #ordered {
    display: block !important;
  }
  body { background: #fff; }
  .invoice-box {
    box-shadow: none;
    border: 1px solid #ccc;
  }
  .left, .right { border: 1px solid #ddd; }
  .download-btn { display: none; }
}

@media (prefers-reduced-motion: reduce) {
  .invoice-header,
  #timer,
  #ordered .tabs .tab::before,
  .order-stepper .step.is-active .dot,
  .download-btn::after,
  .konfirm-btn::after,
  .timer-box.danger {
    animation: none !important;
  }
}

#ordered {
  display: none;
}

#caraGamepass {
  width: 100%;
  max-width: 1100px;
  border-radius: 10px;
  position: static;
  margin: auto;
  z-index: 999;
}
#formUserId {
  margin-top: 15px;
}
.notes {
  font-size: small;
  color: #555555;
}
#tutorialScroll {
  cursor: pointer;
  color: #007bff;
  text-decoration: underline;
}

/* Make the card full-width and flow with document on small screens */
@media (max-width: 768px) {
  #caraGamepass {
    position: static;
    width: 100%;
    transform: none;
    margin: 0 auto 20px;
  }
}


/* footer */
.footer {
    background: #0f8c7a;
    color: white;
    padding: 40px 20px 20px;
    font-family: Arial, sans-serif;
}

.footer-container {
    display: flex;
    flex-wrap: wrap;
    justify-content: space-between;
    max-width: 1200px;
    margin: auto;
}

.footer-section {
    width: 23%;
    margin-bottom: 25px;
}

.footer-section h4,
.footer-section h3 {
    margin-bottom: 10px;
}

.footer-section p {
    font-size: 14px;
    line-height: 1.6;
}

.footer-section ul {
    list-style: none;
    padding: 0;
}

.footer-section ul li {
    margin: 6px 0;
}

.footer-section ul li a {
    color: white;
    text-decoration: none;
}

.footer-section ul li a:hover {
    text-decoration: underline;
}

.footer-logo {
  display: flex;
  align-items: center;
}
.footer-logo >img {
    width: 64px;
    margin-bottom: 10px;
    animation: float 3s ease-in-out infinite;
}

/* gambar bergerak (naik-turun lembut) */
@keyframes float {
    0%, 100% { transform: translateY(0); }
    50% { transform: translateY(-6px); }
}
.social-icons {margin-bottom: 10px;}
.social-icons img,
.payment-logos img {
    width: 35px;
    margin-right: 8px;
    margin-top: 6px;
}

.payment-logos img {
    width: 90px;
    height: 30px;
    border-radius: 2.5px;
}

.footer-bottom {
    text-align: center;
    padding-top: 20px;
    font-size: 14px;
    opacity: 0.8;
}

/* Responsif */
@media (max-width: 800px) {
    .footer-section {
        width: 45%;
    }
}

@media (max-width: 500px) {
    .footer-section {
        width: 100%;
    }
}
/* --------------------
   RESPONSIVE BREAKPOINTS
   -------------------- */

/* Tablet (≤768px) */
@media (max-width: 768px) {
  .content {
    flex-direction: column;
  }

  .left,
  .right {
    width: 100%;
  }
}

/* -------------------- 
   HEADER RESPONSIF 
   Layout rapi 3 baris:
   1) Logo (kiri) + Login/Daftar (kanan, kompak)
   2) Search bar penuh lebar
   3) Kategori chip geser horizontal
   -------------------- */
@media (max-width: 768px) {
  header {
    padding: 12px 14px 0;
  }
  .navbar {
    flex-wrap: wrap;
    row-gap: 10px;
    column-gap: 10px;
    padding-bottom: 4px;
  }
  .nav-buttons {
    order: 2;
    margin-left: auto;
    gap: 8px;
  }
  .nav-buttons button {
    padding: 8px 16px;
    font-size: 0.85rem;
  }
  .search-box {
    order: 3;
    flex: 1 1 100%;
    max-width: none;
    margin-top: 2px;
  }
  .search-bar {
    padding: 10px 16px;
    font-size: 16px; /* 16px penuh = iOS tidak auto-zoom saat input fokus */
  }
  .brand-link {
    gap: 8px;
  }
  .logo {
    font-size: 1.3rem;
  }
  .nav-logo {
    width: 40px;
    height: 40px;
  }
  .quick-links {
    flex-wrap: nowrap;
    overflow-x: auto;
    gap: 8px;
    padding: 4px 2px 10px;
    scrollbar-width: none;
    -webkit-overflow-scrolling: touch;
    scroll-snap-type: x proximity;
    -webkit-mask-image: linear-gradient(90deg, transparent, #000 14px, #000 calc(100% - 14px), transparent);
    mask-image: linear-gradient(90deg, transparent, #000 14px, #000 calc(100% - 14px), transparent);
  }
  .quick-links::-webkit-scrollbar {
    display: none;
  }
  /* ===== Tanda "bisa digeser" di baris chip =====
     Muncul hanya kalau barisnya benar-benar overflow (class .swipeable
     dipasang oleh js/animate.js pada pembungkus .quick-links-wrap).
     Isinya hanya dua panah bulat kecil: ‹ di kiri dan › di kanan, chevron
     putih di atas latar gelap agar kontras. Panah di-position absolute di
     atas pembungkus (yang tidak ikut scroll), jadi tidak menggeser layout,
     tidak menutup chip, dan tidak terseret scroll-snap. .swipe-can-left /
     .swipe-can-right mengikuti posisi scroll yang aktual. */
  .quick-links-wrap {
    position: relative;
  }
  .quick-links-wrap.swipeable::before,
  .quick-links-wrap.swipeable::after {
    position: absolute;
    top: 50%;
    transform: translateY(-50%);
    width: 24px;
    height: 24px;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 18px;
    font-weight: 800;
    line-height: 1;
    color: #ffffff;
    background: rgba(17, 24, 39, 0.55);
    border-radius: 999px;
    box-shadow: 0 1px 4px rgba(0, 0, 0, 0.25);
    pointer-events: none;
    opacity: 0;
    transition: opacity 0.2s ease;
    z-index: 2;
  }
  .quick-links-wrap.swipeable::before {
    content: "\2039";
    left: 16px;
  }
  .quick-links-wrap.swipeable::after {
    content: "\203A";
    right: 16px;
  }
  .quick-links-wrap.swipeable.swipe-can-left::before {
    opacity: 1;
    animation: qlSwipeHintL 1.5s ease-in-out infinite;
  }
  .quick-links-wrap.swipeable.swipe-can-right::after {
    opacity: 1;
    animation: qlSwipeHintR 1.5s ease-in-out infinite;
  }
  @keyframes qlSwipeHintL {
    0%, 100% { transform: translateY(-50%); opacity: 0.75; }
    50% { transform: translateY(-50%) translateX(-3px); opacity: 1; }
  }
  @keyframes qlSwipeHintR {
    0%, 100% { transform: translateY(-50%); opacity: 0.75; }
    50% { transform: translateY(-50%) translateX(3px); opacity: 1; }
  }
  @media (prefers-reduced-motion: reduce) {
    .quick-links-wrap.swipeable.swipe-can-left::before,
    .quick-links-wrap.swipeable.swipe-can-right::after {
      animation: none;
    }
  }
  .quick-link {
    flex: 0 0 auto;
    scroll-snap-align: start;
    white-space: nowrap;
    font-size: 0.8rem;
    padding: 6px 13px;
  }
  /* "Beranda" = logo, tidak perlu jadi chip di layar sempit */
  .quick-link[href="#bannerSlider"],
  .quick-link[href="../index.html"] {
    display: none;
  }
}
