:root {
  --bg: #0b0a0e;
  --surface: #121017;
  --surface-2: #1a1721;
  --surface-hover: #211e2a;
  --border: rgba(235, 224, 206, 0.09);
  --border-strong: rgba(212, 162, 76, 0.26);
  --rail: rgba(212, 162, 76, 0.06);
  --text: #f5efe6;
  --text-muted: #b0a69a;
  --text-dim: #7c7369;

  --accent: #d4a24c;
  --accent-hover: #e2b45f;
  --accent-ink: #120d05;
  --accent-dim: rgba(212, 162, 76, 0.12);
  --accent-border: rgba(212, 162, 76, 0.34);

  --crimson: #d64559;
  --crimson-dim: rgba(214, 69, 89, 0.12);
  --crimson-border: rgba(214, 69, 89, 0.34);

  --blue-truth: #5a94e8;
  --blue-truth-dim: rgba(90, 148, 232, 0.12);
  --blue-truth-border: rgba(90, 148, 232, 0.34);

  --sage: #3db88b;
  --sage-dim: rgba(61, 184, 139, 0.12);
  --sage-border: rgba(61, 184, 139, 0.34);

  --highlight: inset 0 1px 0 rgba(245, 239, 230, 0.04);
  --font-sans: 'Plus Jakarta Sans', -apple-system, BlinkMacSystemFont, 'Segoe UI', sans-serif;
  --font-mono: 'JetBrains Mono', ui-monospace, SFMono-Regular, Menlo, monospace;
  --radius: 12px;
  --ease: cubic-bezier(0.2, 0, 0, 1);
}

html[data-theme="light"] {
  --bg: #faf7f1;
  --surface: #ffffff;
  --surface-2: #f2ece1;
  --surface-hover: #e8e0d2;
  --border: rgba(28, 22, 16, 0.10);
  --border-strong: rgba(154, 109, 31, 0.28);
  --rail: rgba(28, 22, 16, 0.055);
  --text: #1c1814;
  --text-muted: #574e44;
  --text-dim: #7a7064;

  --accent: #9a6d1f;
  --accent-hover: #7f5816;
  --accent-ink: #ffffff;
  --accent-dim: rgba(154, 109, 31, 0.09);
  --accent-border: rgba(154, 109, 31, 0.28);

  --crimson: #a61f33;
  --crimson-dim: rgba(166, 31, 51, 0.09);
  --crimson-border: rgba(166, 31, 51, 0.26);

  --blue-truth: #2457a6;
  --blue-truth-dim: rgba(36, 87, 166, 0.09);
  --blue-truth-border: rgba(36, 87, 166, 0.26);

  --sage: #187a56;
  --sage-dim: rgba(24, 122, 86, 0.09);
  --sage-border: rgba(24, 122, 86, 0.26);

  --highlight: 0 1px 2px rgba(28, 22, 16, 0.04);
}

* { box-sizing: border-box; margin: 0; padding: 0; }
html {
  scroll-behavior: smooth;
  scroll-padding-top: 72px;
  background: var(--bg);
  color: var(--text);
  overflow-x: clip;
  -webkit-text-size-adjust: 100%;
}
body {
  font-family: var(--font-sans);
  background-color: var(--bg);
  color: var(--text);
  line-height: 1.55;
  -webkit-font-smoothing: antialiased;
  -webkit-tap-highlight-color: transparent;
  min-height: 100dvh;
  display: flex;
  flex-direction: column;
  overflow-x: clip;
  transition: background-color 0.2s var(--ease), color 0.2s var(--ease);
}
a { color: inherit; text-decoration: none; touch-action: manipulation; }
button, input, summary { font-family: inherit; touch-action: manipulation; }
a:focus-visible, button:focus-visible, input:focus-visible, summary:focus-visible {
  outline: 2px solid var(--accent);
  outline-offset: 2px;
}
.hidden { display: none !important; }

.shell {
  width: 100%;
  max-width: 520px;
  margin: 0 auto;
  padding: 0 16px;
}
.page-main {
  flex: 1;
  padding: 20px 0 32px;
}
@media (min-width: 600px) {
  .shell { padding: 0 20px; }
  .page-main {
    padding: 28px 0 44px;
    background-image: linear-gradient(
      to right,
      transparent calc(50% - 260px),
      var(--rail) calc(50% - 260px),
      var(--rail) calc(50% - 259px),
      transparent calc(50% - 259px),
      transparent calc(50% + 259px),
      var(--rail) calc(50% + 259px),
      var(--rail) calc(50% + 260px),
      transparent calc(50% + 260px)
    );
  }
}
.stack { display: grid; gap: 16px; }

.icon-sm { width: 16px; height: 16px; flex-shrink: 0; display: inline-block; vertical-align: middle; }
.brand-mark { width: 22px; height: 22px; display: block; }

.site-header {
  position: sticky;
  top: 0;
  z-index: 40;
  padding-top: env(safe-area-inset-top);
  background: rgba(11, 10, 14, 0.92);
  backdrop-filter: blur(12px);
  border-bottom: 1px solid var(--border);
}
html[data-theme="light"] .site-header {
  background: rgba(250, 247, 241, 0.94);
}
.nav-inner {
  height: 56px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
}
.brand {
  display: flex;
  align-items: center;
  gap: 10px;
  font-weight: 600;
  font-size: 15px;
  letter-spacing: -0.015em;
}
.brand-svg {
  width: 30px;
  height: 30px;
  border-radius: 8px;
  background: #131118;
  border: 1px solid rgba(212, 162, 76, 0.32);
  display: grid;
  place-items: center;
}
.nav-right { display: flex; align-items: center; gap: 8px; }

.menu-wrap { position: relative; }
.menu-btn {
  width: 40px;
  height: 40px;
  padding: 0;
  border-radius: 8px;
  background: var(--surface);
  color: var(--text);
  border: 1px solid var(--border);
  display: inline-flex;
  align-items: center;
  justify-content: center;
  cursor: pointer;
  transition: background-color 0.15s var(--ease), border-color 0.15s var(--ease), color 0.15s var(--ease);
}
.menu-btn:hover,
.menu-btn[aria-expanded="true"] {
  background: var(--surface-2);
  border-color: var(--border-strong);
  color: var(--accent);
}
.nav-dropdown {
  position: absolute;
  top: calc(100% + 8px);
  right: 0;
  width: 210px;
  background: var(--surface);
  border: 1px solid var(--border-strong);
  border-radius: 10px;
  padding: 6px;
  display: grid;
  gap: 2px;
  box-shadow: 0 12px 28px rgba(0, 0, 0, 0.28);
  z-index: 60;
}
html[data-theme="light"] .nav-dropdown {
  box-shadow: 0 10px 24px rgba(28, 22, 16, 0.10);
}
.nav-dropdown a {
  display: flex;
  align-items: center;
  min-height: 40px;
  padding: 8px 12px;
  border-radius: 7px;
  font-size: 13.5px;
  color: var(--text-muted);
  transition: background-color 0.14s var(--ease), color 0.14s var(--ease);
}
.nav-dropdown a:hover {
  background: var(--surface-2);
  color: var(--text);
}

.status-pill {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  min-height: 36px;
  font-family: var(--font-mono);
  font-size: 12px;
  color: var(--text-muted);
  background: var(--surface);
  border: 1px solid var(--border);
  padding: 0 10px;
  border-radius: 8px;
}
.status-dot {
  width: 7px;
  height: 7px;
  border-radius: 50%;
  background: var(--sage);
  display: inline-block;
  flex-shrink: 0;
}
.status-dot.offline { background: var(--crimson); }

.theme-toggle {
  width: 40px;
  height: 40px;
  padding: 0;
  border-radius: 8px;
  background: var(--surface);
  color: var(--accent);
  border: 1px solid var(--border-strong);
  display: inline-flex;
  align-items: center;
  justify-content: center;
  cursor: pointer;
  transition: background-color 0.15s var(--ease), border-color 0.15s var(--ease);
}
.theme-toggle:hover { background: var(--surface-2); border-color: var(--accent); }
.theme-toggle .icon-moon { display: none; }
html[data-theme="light"] .theme-toggle .icon-sun { display: none; }
html[data-theme="light"] .theme-toggle .icon-moon { display: inline-block; }

.card {
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  padding: 18px;
  box-shadow: var(--highlight);
}
.card-primary { padding: 20px; }
@media (min-width: 600px) {
  .card { padding: 20px; }
  .card-primary { padding: 24px; }
}
.card-head {
  display: flex;
  justify-content: space-between;
  align-items: flex-start;
  gap: 12px;
  padding-bottom: 16px;
  margin-bottom: 16px;
  border-bottom: 1px solid var(--border);
}
h1 {
  font-size: 20px;
  font-weight: 600;
  letter-spacing: -0.02em;
  line-height: 1.25;
}
.price-row {
  display: flex;
  align-items: baseline;
  gap: 6px;
  margin-top: 6px;
}
.price-main {
  font-family: var(--font-mono);
  font-size: 26px;
  font-weight: 600;
  color: var(--accent);
  font-variant-numeric: tabular-nums;
  letter-spacing: -0.02em;
}
.price-unit { font-size: 13.5px; color: var(--text-muted); }
.price-note { font-size: 12px; color: var(--text-dim); margin-top: 4px; }
.code-badge {
  font-family: var(--font-mono);
  font-size: 12px;
  color: var(--accent);
  background: var(--accent-dim);
  border: 1px solid var(--accent-border);
  padding: 4px 8px;
  border-radius: 6px;
  flex-shrink: 0;
}

.view-stack { display: flex; flex-direction: column; gap: 16px; }

.benefit-grid {
  list-style: none;
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 10px 12px;
  padding: 12px 14px;
  border-radius: 8px;
  background: var(--surface-2);
  border: 1px solid var(--border);
}
.benefit-grid li {
  display: flex;
  align-items: center;
  gap: 8px;
  font-size: 13px;
  color: var(--text-muted);
}
.check-icon { color: var(--sage); }

.field-group { display: flex; flex-direction: column; gap: 6px; }
.field-label { font-size: 13.5px; font-weight: 500; color: var(--text); }
.field-input {
  width: 100%;
  min-height: 48px;
  padding: 12px 14px;
  border-radius: 8px;
  background: var(--surface-2);
  border: 1px solid var(--border);
  color: var(--text);
  font-size: 16px;
  transition: border-color 0.15s var(--ease), background-color 0.15s var(--ease);
}
.field-input::placeholder { color: var(--text-dim); }
.field-input:focus { border-color: var(--accent); background: var(--surface); outline: none; }
.field-input.invalid { border-color: var(--crimson); }
.mono-input { font-family: var(--font-mono); font-size: 14px; }
.field-error { font-size: 12.5px; color: var(--crimson); }
.field-hint { font-size: 12.5px; color: var(--text-dim); line-height: 1.5; }
.inline-row { display: flex; gap: 8px; }
.inline-row .field-input { flex: 1; min-width: 0; }

.progress-wrap { display: flex; flex-direction: column; gap: 6px; }
.progress-head {
  display: flex;
  justify-content: space-between;
  font-size: 12.5px;
  color: var(--text-muted);
}
.progress-track {
  width: 100%;
  height: 6px;
  background: var(--surface-2);
  border-radius: 4px;
  overflow: hidden;
}
.progress-fill {
  width: 0%;
  height: 100%;
  background: var(--accent);
  transition: width 0.2s var(--ease);
}

.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  min-height: 46px;
  padding: 10px 16px;
  border-radius: 8px;
  font-size: 14px;
  font-weight: 500;
  cursor: pointer;
  border: 1px solid transparent;
  transition: background-color 0.15s var(--ease), border-color 0.15s var(--ease), color 0.15s var(--ease), transform 0.12s var(--ease);
}
.btn:active { transform: translateY(1px); }
.btn:disabled { opacity: 0.6; cursor: not-allowed; transform: none; }
.btn-full { width: 100%; }
.btn-grow { flex: 1; }
.btn-row { display: flex; gap: 8px; }
.btn-stack-mobile { display: flex; flex-direction: column; gap: 8px; }
.btn-primary { background: var(--accent); color: var(--accent-ink); font-weight: 600; }
.btn-primary:hover:not(:disabled) { background: var(--accent-hover); }
.btn-secondary { background: var(--surface-2); color: var(--text); border-color: var(--border-strong); }
.btn-secondary:hover:not(:disabled) { background: var(--surface-hover); border-color: var(--accent); }
.btn-ghost { background: transparent; color: var(--text-muted); border-color: var(--border); }
.btn-ghost:hover:not(:disabled) { color: var(--text); border-color: var(--border-strong); background: var(--surface-2); }

.text-btn {
  background: transparent;
  border: none;
  min-height: 36px;
  padding: 4px 2px;
  font-size: 13px;
  color: var(--text-muted);
  cursor: pointer;
  transition: color 0.15s var(--ease);
}
.text-btn:hover { color: var(--accent); }

.card-foot-meta {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  justify-content: space-between;
  gap: 8px;
  padding-top: 10px;
  border-top: 1px solid var(--border);
}
.foot-trust { font-size: 12.5px; color: var(--text-dim); }
.lookup-row { display: flex; gap: 8px; }
.lookup-row .field-input { flex: 1; min-width: 0; }

.qris-box {
  background: #ffffff;
  border: 1px solid var(--border);
  border-radius: 10px;
  padding: 16px;
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 8px;
}
.qris-img { width: min(224px, 72vw); height: min(224px, 72vw); object-fit: contain; display: block; }
.qris-merchant { font-family: var(--font-mono); font-size: 11.5px; font-weight: 600; color: #1c1814; text-align: center; }

.summary-box {
  background: var(--surface-2);
  border: 1px solid var(--border);
  border-radius: 8px;
  padding: 12px 14px;
  display: grid;
  gap: 10px;
}
.summary-row {
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: 12px;
  font-size: 13.5px;
  color: var(--text-muted);
}
.summary-row strong { color: var(--text); font-weight: 500; text-align: right; }
.summary-row code, .modal-row code, .faq-a code, .note-list code {
  font-family: var(--font-mono);
  font-size: 12px;
  color: var(--text);
  background: var(--surface);
  border: 1px solid var(--border);
  padding: 3px 7px;
  border-radius: 5px;
  word-break: break-all;
}
.mono-val { font-family: var(--font-mono); font-variant-numeric: tabular-nums; color: var(--text); }
.summary-total { padding-top: 10px; border-top: 1px solid var(--border); }
.summary-total strong {
  font-family: var(--font-mono);
  font-size: 17px;
  font-weight: 600;
  color: var(--accent);
  font-variant-numeric: tabular-nums;
}
.copy-btn {
  background: transparent;
  border: none;
  padding: 4px 0;
  cursor: pointer;
  display: inline-flex;
  align-items: center;
}
.copy-btn:hover code, .copy-btn:hover strong { text-decoration: underline; text-underline-offset: 3px; }

.banner {
  padding: 12px 14px;
  border-radius: 8px;
  font-size: 13px;
  line-height: 1.5;
  border: 1px solid var(--border);
}
.banner-info { background: var(--blue-truth-dim); border-color: var(--blue-truth-border); color: var(--text); }
.banner-success { background: var(--sage-dim); border-color: var(--sage-border); color: var(--text); }
.banner-error { background: var(--crimson-dim); border-color: var(--crimson-border); color: var(--text); }

.section-bar {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  margin-bottom: 12px;
}
h2 { font-size: 15.5px; font-weight: 600; letter-spacing: -0.01em; }

.prep-grid,
.feature-grid {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 10px;
}
.prep-item,
.feature-item {
  display: flex;
  align-items: flex-start;
  gap: 10px;
  padding: 12px;
  border-radius: 8px;
  background: var(--surface-2);
  border: 1px solid var(--border);
}
.prep-num {
  font-family: var(--font-mono);
  font-size: 12px;
  font-weight: 600;
  color: var(--accent);
  flex-shrink: 0;
  margin-top: 1px;
}
.feature-icon { color: var(--accent); margin-top: 2px; }
.prep-item h3,
.feature-item h3 { font-size: 13.5px; font-weight: 600; color: var(--text); margin-bottom: 3px; }
.prep-item p,
.feature-item p { font-size: 12.5px; color: var(--text-muted); line-height: 1.45; }

.guide-tabs {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 6px;
  padding: 4px;
  border-radius: 10px;
  background: var(--surface-2);
  border: 1px solid var(--border);
  margin-bottom: 14px;
}
.guide-tabs-3 { grid-template-columns: repeat(3, minmax(0, 1fr)); }
.guide-tab {
  min-height: 40px;
  padding: 8px 6px;
  border-radius: 7px;
  border: 1px solid transparent;
  background: transparent;
  color: var(--text-muted);
  font-size: 13px;
  font-weight: 500;
  cursor: pointer;
  transition: background-color 0.15s var(--ease), color 0.15s var(--ease), border-color 0.15s var(--ease);
}
.guide-tab:hover { color: var(--text); }
.guide-tab.active {
  background: var(--surface);
  border-color: var(--border-strong);
  color: var(--accent);
}
.step-list,
.note-list {
  list-style: none;
  display: grid;
  gap: 10px;
}
.step-list li,
.note-list li {
  display: flex;
  align-items: flex-start;
  gap: 10px;
  font-size: 13px;
  line-height: 1.55;
  color: var(--text-muted);
}
.step-list strong,
.note-list strong { color: var(--text); font-weight: 600; }
.step-num {
  width: 24px;
  height: 24px;
  border-radius: 6px;
  background: var(--surface-2);
  border: 1px solid var(--border);
  color: var(--accent);
  font-family: var(--font-mono);
  font-size: 12px;
  font-weight: 600;
  display: grid;
  place-items: center;
  flex-shrink: 0;
  margin-top: 1px;
}
.note-dot {
  width: 6px;
  height: 6px;
  border-radius: 50%;
  background: var(--accent);
  flex-shrink: 0;
  margin-top: 8px;
}

.sys-status-bar {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 8px;
  margin-bottom: 12px;
}
.sys-metric {
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: 8px;
  padding: 10px 12px;
  border-radius: 8px;
  background: var(--surface-2);
  border: 1px solid var(--border);
  font-size: 12.5px;
}
.sys-label { color: var(--text-dim); }
.sys-val { font-weight: 500; color: var(--text); }
.sys-val.ok { color: var(--sage); }
.sys-val.err { color: var(--crimson); }

.recent-list { display: grid; gap: 8px; }
.recent-row {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  padding: 10px 12px;
  border-radius: 8px;
  background: var(--surface-2);
  border: 1px solid var(--border);
  font-size: 13px;
}
.recent-left { display: flex; flex-direction: column; gap: 2px; min-width: 0; }
.recent-buyer { font-family: var(--font-mono); font-size: 12.5px; color: var(--text); overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.recent-meta { font-size: 12px; color: var(--text-dim); }
.recent-right { display: flex; flex-direction: column; align-items: flex-end; gap: 2px; flex-shrink: 0; }
.recent-price { font-family: var(--font-mono); font-size: 12.5px; font-weight: 600; color: var(--accent); font-variant-numeric: tabular-nums; }
.recent-status { font-size: 11.5px; color: var(--sage); }
.recent-empty { font-size: 13px; color: var(--text-dim); padding: 6px 0; }

.faq-list { display: grid; gap: 8px; }
.faq-item {
  background: var(--surface-2);
  border: 1px solid var(--border);
  border-radius: 8px;
}
.faq-item[open] { border-color: var(--accent-border); }
.faq-q {
  list-style: none;
  min-height: 46px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  padding: 12px 14px;
  cursor: pointer;
  font-size: 13.5px;
  font-weight: 500;
  color: var(--text);
}
.faq-q::-webkit-details-marker { display: none; }
.faq-chevron { width: 16px; height: 16px; flex-shrink: 0; color: var(--text-dim); transition: transform 0.16s var(--ease), color 0.15s var(--ease); }
.faq-item[open] .faq-chevron { transform: rotate(180deg); color: var(--accent); }
.faq-a { padding: 10px 14px 12px; font-size: 13px; line-height: 1.55; color: var(--text-muted); border-top: 1px solid var(--border); }

.disclaimer-box {
  padding: 14px 16px;
  border-radius: var(--radius);
  background: var(--surface);
  border: 1px solid var(--border);
  font-size: 12.5px;
  line-height: 1.55;
  color: var(--text-dim);
}
.disclaimer-box strong { color: var(--text-muted); font-weight: 500; }

.site-footer {
  border-top: 1px solid var(--border);
  background: var(--surface);
  padding: 20px 0 calc(20px + env(safe-area-inset-bottom));
}
.footer-stack { display: grid; gap: 16px; }
.footer-links-grid {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 10px;
}
.footer-action {
  display: flex;
  flex-direction: column;
  gap: 2px;
  min-height: 52px;
  justify-content: center;
  padding: 10px 12px;
  border-radius: 8px;
  background: var(--surface-2);
  border: 1px solid var(--border);
  transition: border-color 0.15s var(--ease), background-color 0.15s var(--ease);
}
.footer-action:hover {
  border-color: var(--accent-border);
  background: var(--surface-hover);
}
.footer-action-label { font-size: 11.5px; color: var(--text-dim); }
.footer-action-val { font-size: 13px; font-weight: 500; color: var(--text); }
.footer-bottom {
  display: flex;
  flex-wrap: wrap;
  justify-content: space-between;
  align-items: center;
  gap: 10px;
  padding-top: 12px;
  border-top: 1px solid var(--border);
  font-size: 12.5px;
  color: var(--text-dim);
}
.footer-domain { font-family: var(--font-mono); color: var(--accent); }

.modal-backdrop {
  position: fixed;
  inset: 0;
  background: rgba(8, 7, 11, 0.72);
  backdrop-filter: blur(4px);
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 16px;
  z-index: 80;
}
.modal-card {
  width: 100%;
  max-width: 400px;
  background: var(--surface);
  border: 1px solid var(--border-strong);
  border-radius: var(--radius);
  padding: 20px;
  display: flex;
  flex-direction: column;
  gap: 14px;
}
.modal-desc { font-size: 13px; color: var(--text-muted); line-height: 1.55; }
.modal-preview {
  background: var(--surface-2);
  border: 1px solid var(--border);
  border-radius: 8px;
  padding: 12px;
  display: grid;
  gap: 8px;
}
.modal-row {
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: 12px;
  font-size: 13px;
  color: var(--text-muted);
}
.modal-row strong { color: var(--text); font-weight: 500; text-align: right; }

.toast {
  position: fixed;
  bottom: calc(16px + env(safe-area-inset-bottom));
  left: 50%;
  transform: translate(-50%, 8px);
  background: var(--text);
  color: var(--bg);
  font-size: 13px;
  font-weight: 500;
  padding: 10px 16px;
  border-radius: 8px;
  opacity: 0;
  pointer-events: none;
  max-width: calc(100vw - 32px);
  text-align: center;
  transition: opacity 0.16s var(--ease), transform 0.16s var(--ease);
  z-index: 100;
}
.toast.show { opacity: 1; transform: translate(-50%, 0); }

@media (max-width: 520px) {
  .benefit-grid,
  .prep-grid,
  .feature-grid,
  .footer-links-grid { grid-template-columns: 1fr; gap: 8px; }
  .inline-row { flex-direction: column; }
}
