/* PUSAT AKUN — tema terang, aksen oranye (gaya marketplace top-up) */
:root {
  --accent: #ff5722;         /* oranye utama */
  --accent-2: #ff8a3d;       /* oranye muda (gradient) */
  --accent-ink: #d84315;     /* teks oranye gelap */
  --bg: #f4f5f7;             /* latar abu muda */
  --surface: #ffffff;        /* kartu/panel */
  --text: #1b1f27;
  --muted: #6b7280;
  --line: #e8eaef;
  --shadow: 0 6px 24px rgba(20, 25, 40, .06);
}
* { box-sizing: border-box; }
html { scroll-behavior: smooth; }
body {
  margin: 0;
  font-family: "Plus Jakarta Sans", system-ui, -apple-system, Segoe UI, Roboto, sans-serif;
  background: var(--bg);
  color: var(--text);
}
.container { max-width: 1180px; margin: 0 auto; padding: 0 18px; }
a { color: inherit; }

/* ---------- Top bar ---------- */
.topbar { background: var(--surface); border-bottom: 1px solid var(--line); position: sticky; top: 0; z-index: 20; }
.topbar-inner { display: flex; align-items: center; gap: 18px; height: 66px; }
.brand { display: flex; align-items: center; gap: 10px; text-decoration: none; font-weight: 800; letter-spacing: .3px; color: var(--text); white-space: nowrap; }
.brand-mark {
  display: grid; place-items: center; width: 34px; height: 34px; border-radius: 10px;
  background: linear-gradient(135deg, var(--accent), var(--accent-2));
  color: #fff; font-weight: 800; font-size: 14px;
}
.brand-text { font-size: 17px; }

.search { flex: 1; position: relative; max-width: 560px; }
.search svg { position: absolute; left: 14px; top: 50%; transform: translateY(-50%); width: 18px; height: 18px; fill: none; stroke: var(--muted); stroke-width: 2; }
.search input {
  width: 100%; height: 42px; padding: 0 16px 0 42px; border-radius: 999px;
  border: 1px solid var(--line); background: #f7f8fa; color: var(--text); font-size: 14px; outline: none;
}
.search input:focus { border-color: var(--accent); background: #fff; }

.auth { display: flex; gap: 10px; }
.btn { border: none; cursor: pointer; border-radius: 10px; font-size: 14px; font-weight: 700; padding: 10px 18px; white-space: nowrap; }
.btn-ghost { background: transparent; color: var(--text); border: 1px solid var(--line); }
.btn-ghost:hover { border-color: var(--accent); color: var(--accent-ink); }
.btn-primary { background: var(--accent); color: #fff; }
.btn-primary:hover { background: var(--accent-ink); }

/* nav kategori */
.catnav { border-top: 1px solid var(--line); background: var(--surface); }
.catnav-inner { display: flex; gap: 6px; overflow-x: auto; padding: 8px 0; }
.cat {
  border: none; background: transparent; cursor: pointer; white-space: nowrap;
  color: var(--muted); font-size: 14px; font-weight: 600; padding: 8px 14px; border-radius: 999px;
}
.cat:hover { color: var(--text); background: #f2f3f6; }
.cat.active { color: #fff; background: var(--accent); }

/* ---------- Hero ---------- */
.hero { background: linear-gradient(120deg, #ff5722, #ff8a3d); color: #fff; }
.hero-inner { padding: 40px 0; }
.hero-eyebrow { display: inline-block; background: rgba(255,255,255,.18); padding: 5px 12px; border-radius: 999px; font-size: 13px; font-weight: 600; }
.hero h1 { margin: 14px 0 8px; font-size: clamp(26px, 4vw, 40px); line-height: 1.1; }
.hero h1 span { color: #fff3e0; text-decoration: underline; text-decoration-color: rgba(255,255,255,.5); }
.hero p { margin: 0 0 18px; max-width: 60ch; font-size: 15px; opacity: .95; }
.hero-badges { display: flex; flex-wrap: wrap; gap: 10px; }
.hero-badges span { background: rgba(255,255,255,.16); border: 1px solid rgba(255,255,255,.25); padding: 8px 14px; border-radius: 10px; font-size: 13px; font-weight: 600; }

/* ---------- Section + grid ---------- */
.section-head { display: flex; align-items: center; justify-content: space-between; padding: 28px 0 14px; }
.section-head h2 { margin: 0; font-size: 20px; }

.grid { display: grid; gap: 16px; grid-template-columns: repeat(auto-fill, minmax(170px, 1fr)); padding-bottom: 44px; }
.gcard {
  background: var(--surface); border: 1px solid var(--line); border-radius: 16px; overflow: hidden;
  text-decoration: none; color: var(--text); box-shadow: var(--shadow);
  transition: transform .14s, box-shadow .14s;
}
.gcard:hover { transform: translateY(-4px); box-shadow: 0 12px 28px rgba(20,25,40,.12); }
.gcard-cover {
  position: relative; aspect-ratio: 1 / 1; display: grid; place-items: center;
  background: linear-gradient(135deg, #ffab7a, #ff5722);
}
.gcard-letter { font-size: 54px; font-weight: 800; color: #fff; opacity: .92; }
.gcard-badge {
  position: absolute; top: 10px; left: 10px; background: #fff; color: var(--accent-ink);
  font-size: 11px; font-weight: 800; padding: 4px 9px; border-radius: 8px; box-shadow: var(--shadow);
}
.gcard-body { padding: 12px 14px 16px; }
.gcard-body h3 { margin: 0 0 2px; font-size: 15px; }
.gcard-pub { margin: 0 0 8px; font-size: 12px; color: var(--muted); }
.gcard-price { margin: 0; font-size: 13px; color: var(--muted); }
.gcard-price b { color: var(--accent-ink); font-weight: 800; }

.empty { text-align: center; color: var(--muted); padding: 48px 0; }

/* ---------- Footer ---------- */
.footer { background: var(--surface); border-top: 1px solid var(--line); margin-top: 20px; }
.footer-inner { display: grid; gap: 24px; grid-template-columns: 2fr 1fr 1fr 1fr; padding: 36px 0 24px; }
.foot-desc { color: var(--muted); font-size: 14px; margin: 12px 0 0; max-width: 34ch; }
.foot-col { display: flex; flex-direction: column; gap: 8px; }
.foot-col strong { font-size: 14px; margin-bottom: 4px; }
.foot-col a { color: var(--muted); text-decoration: none; font-size: 14px; }
.foot-col a:hover { color: var(--accent-ink); }
.foot-bottom { border-top: 1px solid var(--line); padding: 18px; color: var(--muted); font-size: 13px; }

/* ---------- Halaman detail ---------- */
.detail { padding-top: 22px; padding-bottom: 48px; }
.back { color: var(--muted); text-decoration: none; font-size: 14px; }
.back:hover { color: var(--accent-ink); }

.detail-head { display: flex; gap: 20px; align-items: center; padding: 18px 0 8px; }
.detail-thumb {
  flex: none; width: 96px; height: 96px; border-radius: 18px; display: grid; place-items: center;
  font-size: 44px; font-weight: 800; color: #fff; box-shadow: var(--shadow);
  background: linear-gradient(135deg, #ffab7a, #ff5722);
}
.detail-head h1 { margin: 8px 0 2px; font-size: 24px; }
.pill { display: inline-block; font-size: 12px; font-weight: 700; color: var(--accent-ink); background: #fff2ec; border-radius: 999px; padding: 4px 12px; }
.pub { color: var(--muted); font-size: 14px; margin: 2px 0 0; }
.desc { margin: 8px 0 0; color: var(--muted); font-size: 14px; max-width: 62ch; }

.detail-grid { display: grid; gap: 16px; margin-top: 20px; grid-template-columns: 1fr; }
.panel { background: var(--surface); border: 1px solid var(--line); border-radius: 16px; padding: 18px; box-shadow: var(--shadow); }
.panel h2 { margin: 0 0 14px; font-size: 16px; display: flex; align-items: center; gap: 10px; }
.step { display: grid; place-items: center; width: 24px; height: 24px; border-radius: 50%; background: var(--accent); color: #fff; font-size: 13px; font-weight: 800; }

.nominal { display: grid; gap: 10px; grid-template-columns: repeat(auto-fill, minmax(150px, 1fr)); }
.nom {
  text-align: left; cursor: pointer; background: #fafbfc; color: var(--text);
  border: 1.5px solid var(--line); border-radius: 12px; padding: 12px 14px;
  display: flex; flex-direction: column; gap: 4px; transition: border-color .12s, background .12s;
}
.nom:hover { border-color: var(--accent); }
.nom.active { border-color: var(--accent); background: #fff2ec; }
.nom-label { font-size: 14px; font-weight: 700; }
.nom-price { font-size: 13px; color: var(--accent-ink); font-weight: 800; }

.field { display: block; margin-bottom: 14px; }
.field span { display: block; font-size: 13px; color: var(--muted); margin-bottom: 6px; }
.field input { width: 100%; background: #fafbfc; border: 1.5px solid var(--line); border-radius: 10px; color: var(--text); padding: 11px 13px; font-size: 15px; outline: none; }
.field input:focus { border-color: var(--accent); background: #fff; }
.hint { font-size: 12px; color: var(--muted); margin: 4px 0 0; }
.hint.center { text-align: center; }

.summary { margin-top: 16px; background: var(--surface); border: 1px solid var(--line); border-radius: 16px; padding: 18px; box-shadow: var(--shadow); }
.summary h3 { margin: 0 0 14px; font-size: 16px; }
.sum-row { display: flex; justify-content: space-between; font-size: 14px; padding: 7px 0; color: var(--muted); }
.sum-row b { color: var(--text); font-weight: 700; }
.sum-row.total { border-top: 1px solid var(--line); margin-top: 6px; padding-top: 12px; font-size: 16px; }
.sum-row.total b { color: var(--accent-ink); font-size: 18px; }
.btn-buy { width: 100%; margin-top: 14px; border: none; border-radius: 12px; cursor: pointer; background: var(--accent); color: #fff; font-size: 15px; font-weight: 800; padding: 14px; transition: background .12s; }
.btn-buy:disabled { opacity: .45; cursor: not-allowed; }
.btn-buy:not(:disabled):hover { background: var(--accent-ink); }

@media (min-width: 860px) {
  .detail-grid { grid-template-columns: 1fr 1fr; }
  .detail { display: grid; grid-template-columns: 1fr 330px; gap: 24px; align-items: start; }
  .detail > .back, .detail > .detail-head, .detail > .detail-grid { grid-column: 1; }
  .summary { grid-column: 2; grid-row: 2 / 4; margin-top: 0; position: sticky; top: 90px; }
}
@media (max-width: 720px) {
  .brand-text { display: none; }
  .auth .btn-ghost { display: none; }
  .footer-inner { grid-template-columns: 1fr 1fr; }
}
