:root {
  --bg: #1a0d05;
  --bg2: #26140a;
  --card: #2f1a0d;
  --line: #4a2c17;
  --text: #fff6ee;
  --muted: #c9ab94;
  --accent: #ff7a00;
  --accent-soft: rgba(255, 122, 0, .14);
  --warn: #ffcf66;
}
* { box-sizing: border-box; margin: 0; padding: 0; }
html { -webkit-text-size-adjust: 100%; }
body {
  background: var(--bg);
  color: var(--text);
  font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", "Apple SD Gothic Neo", "Noto Sans KR", "PingFang SC", "Hiragino Sans", "Microsoft YaHei", sans-serif;
  line-height: 1.55;
}
.wrap { max-width: 640px; margin: 0 auto; padding: 0 16px; }
header { display: flex; align-items: center; justify-content: space-between; padding: 18px 0; }
.logo { display: flex; align-items: center; gap: 8px; font-weight: 800; letter-spacing: .02em; white-space: nowrap; }
.logo b { background: var(--accent); color: var(--bg); border-radius: 6px; padding: 2px 7px; font-size: 18px; }
.logo span { font-size: 14px; color: var(--muted); }
.langs { display: flex; gap: 4px; }
.langs button {
  background: none; border: 1px solid var(--line); color: var(--muted);
  border-radius: 6px; padding: 4px 7px; font-size: 12px; cursor: pointer; white-space: nowrap;
}
.langs button.on { border-color: var(--accent); color: var(--text); }
.langs a {
  border: 1px solid var(--line); color: var(--muted); text-decoration: none;
  border-radius: 6px; padding: 4px 7px; font-size: 12px; white-space: nowrap;
}
.langs a.on { border-color: var(--accent); color: var(--text); }

.hero { padding: 26px 0 8px; }
h1 { font-size: 30px; line-height: 1.25; font-weight: 800; }
h1 em { font-style: normal; color: var(--accent); }
.lead { color: var(--muted); margin-top: 10px; font-size: 16px; }

.prices { display: grid; grid-template-columns: 1fr 1fr; gap: 10px; margin-top: 22px; }
.price { background: var(--card); border: 1px solid var(--line); border-radius: 14px; padding: 16px; }
.price .trx { font-size: 26px; font-weight: 800; color: var(--accent); }
.price .trx small { font-size: 15px; font-weight: 700; }
.price .en { font-size: 17px; font-weight: 700; margin-top: 2px; }
.price .when { font-size: 13px; color: var(--muted); margin-top: 6px; }

.pay { margin-top: 16px; background: var(--accent-soft); border: 1px solid var(--accent); border-radius: 16px; padding: 18px; }
.pay .label { font-size: 13px; color: var(--muted); }
.addr {
  font-family: ui-monospace, SFMono-Regular, Menlo, Consolas, monospace;
  font-size: 15px; font-weight: 700; word-break: break-all; margin-top: 6px;
}
.addr i { font-style: normal; color: var(--accent); }
.copy {
  width: 100%; margin-top: 12px; padding: 14px; border: 0; border-radius: 12px;
  background: var(--accent); color: var(--bg); font-size: 17px; font-weight: 800; cursor: pointer;
}
.copy.done { background: #7ad16b; }
.qr { display: flex; gap: 14px; align-items: center; margin-top: 14px; }
.qr img { width: 112px; height: 112px; background: #fff; border-radius: 10px; padding: 6px; flex-shrink: 0; }
.qr p { font-size: 14px; color: var(--muted); }

section { margin-top: 34px; }
.orders { background: var(--card); border: 1px solid var(--line); border-radius: 12px; overflow: hidden; }
.orders .row { display: grid; grid-template-columns: 1.1fr 1.2fr 1fr 1.3fr; gap: 6px; padding: 11px 14px; font-size: 14px; border-top: 1px solid var(--line); }
.orders .row:first-child { border-top: 0; }
.orders .head { color: var(--accent); font-weight: 700; font-size: 13px; background: var(--bg2); }
.orders .ago { color: var(--muted); }
.orders .price { color: var(--accent); font-weight: 700; background: none; border: 0; padding: 0; border-radius: 0; }
.orders .who { font-family: ui-monospace, SFMono-Regular, Menlo, Consolas, monospace; font-size: 13px; text-align: right; }
.orders .head .who { font-family: inherit; }
.live { display: inline-block; width: 8px; height: 8px; border-radius: 50%; background: #7ad16b; margin-left: 8px; vertical-align: middle; }
h2 { font-size: 20px; font-weight: 800; margin-bottom: 12px; }
.steps { list-style: none; counter-reset: s; display: grid; gap: 10px; }
.steps li { counter-increment: s; background: var(--card); border: 1px solid var(--line); border-radius: 12px; padding: 14px 14px 14px 52px; position: relative; }
.steps li::before {
  content: counter(s); position: absolute; left: 14px; top: 13px;
  width: 26px; height: 26px; border-radius: 50%; background: var(--accent); color: var(--bg);
  font-weight: 800; display: grid; place-items: center; font-size: 14px;
}
.steps li b { display: block; }
.steps li span { color: var(--muted); font-size: 14px; }

.save { display: grid; grid-template-columns: 1fr 1fr; gap: 10px; }
.save > div { background: var(--card); border: 1px solid var(--line); border-radius: 12px; padding: 14px; }
.save .k { font-size: 13px; color: var(--muted); }
.save .v { font-size: 18px; font-weight: 800; margin-top: 2px; white-space: nowrap; }
.save .v.good { color: var(--accent); }

.warn { background: var(--bg2); border-left: 3px solid var(--warn); border-radius: 8px; padding: 14px; }
.warn li { margin-left: 18px; margin-top: 6px; font-size: 15px; }
.warn li:first-child { margin-top: 0; }

details { background: var(--card); border: 1px solid var(--line); border-radius: 12px; padding: 14px; margin-top: 8px; }
summary { font-weight: 700; cursor: pointer; list-style: none; display: flex; justify-content: space-between; gap: 10px; }
summary::-webkit-details-marker { display: none; }
summary::after { content: "+"; flex-shrink: 0; color: var(--accent); font-weight: 800; }
details[open] summary::after { content: "−"; }
details p { color: var(--muted); margin-top: 8px; font-size: 15px; }

footer { margin: 40px 0 28px; color: var(--muted); font-size: 13px; text-align: center; }

@media (max-width: 420px) {
  .price { padding: 14px 12px; }
  .price .en { font-size: 15px; white-space: nowrap; }
}
@media (max-width: 380px) {
  h1 { font-size: 26px; }
  .price .trx { font-size: 22px; }
  .addr { font-size: 14px; }
}

/* 메뉴 */
nav.menu { display: flex; gap: 6px; margin: -6px 0 6px; }
nav.menu a {
  color: var(--muted); text-decoration: none; font-size: 14px; font-weight: 700;
  padding: 6px 12px; border-radius: 999px; border: 1px solid var(--line);
}
nav.menu a.on { color: var(--bg); background: var(--accent); border-color: var(--accent); }
a { color: var(--accent); }

/* 도구 */
.tool { background: var(--card); border: 1px solid var(--line); border-radius: 14px; padding: 16px; }
.tool + .tool { margin-top: 12px; }
.tool h3 { font-size: 17px; margin-bottom: 4px; }
.tool .desc { color: var(--muted); font-size: 14px; margin-bottom: 12px; }
.field { display: block; margin-top: 10px; }
.field span { display: block; font-size: 13px; color: var(--muted); margin-bottom: 4px; }
.field input, .field select {
  width: 100%; padding: 12px; border-radius: 10px; border: 1px solid var(--line);
  background: var(--bg); color: var(--text); font-size: 16px; font-family: inherit;
}
.field input:focus, .field select:focus { outline: none; border-color: var(--accent); }
.btn {
  width: 100%; margin-top: 12px; padding: 13px; border: 0; border-radius: 10px;
  background: var(--accent); color: var(--bg); font-size: 16px; font-weight: 800; cursor: pointer;
}
.btn:disabled { opacity: .6; }
.result { margin-top: 14px; display: grid; gap: 8px; }
.result:empty { display: none; }
.kv { display: flex; justify-content: space-between; gap: 10px; padding: 10px 12px; background: var(--bg2); border-radius: 10px; font-size: 15px; }
.kv span:first-child { color: var(--muted); }
.kv b.good { color: #7ad16b; }
.kv b.bad { color: #ff8a65; }
.kv b.hi { color: var(--accent); }
.note { font-size: 14px; color: var(--muted); padding: 10px 12px; border-left: 3px solid var(--accent); background: var(--bg2); border-radius: 8px; }

/* 가이드 */
.guide-list { list-style: none; display: grid; gap: 10px; }
.guide-list a {
  display: block; text-decoration: none; color: var(--text);
  background: var(--card); border: 1px solid var(--line); border-radius: 12px; padding: 14px;
}
.guide-list b { display: block; font-size: 16px; }
.guide-list span { display: block; color: var(--muted); font-size: 14px; margin-top: 4px; }
article { padding-top: 16px; }
article h1 { font-size: 26px; }
article .meta { color: var(--muted); font-size: 13px; margin-top: 6px; }
article h2 { margin-top: 28px; }
article p, article li { font-size: 16px; margin-top: 10px; }
article ul, article ol { padding-left: 20px; }
article .cta {
  display: block; text-align: center; text-decoration: none; margin-top: 28px; padding: 15px;
  background: var(--accent); color: var(--bg); font-weight: 800; border-radius: 12px; font-size: 17px;
}
article .more { margin-top: 30px; }

/* 언어 선택 */
.langsel {
  background: var(--bg); color: var(--text); border: 1px solid var(--line);
  border-radius: 8px; padding: 6px 8px; font-size: 13px; font-family: inherit; max-width: 150px;
}
.langsel:focus { outline: none; border-color: var(--accent); }

/* 텔레그램 문의 버튼 */
.tg-fab {
  position: fixed; right: 16px; bottom: 16px; z-index: 50;
  width: 52px; height: 52px; border-radius: 50%;
  display: grid; place-items: center;
  background: var(--accent); color: var(--bg);
  box-shadow: 0 6px 18px rgba(0, 0, 0, .35);
}
.contact { background: var(--card); border: 1px solid var(--line); border-radius: 14px; padding: 16px; }
.contact p { color: var(--muted); font-size: 15px; }
.contact .btn { display: block; text-align: center; text-decoration: none; }
footer { margin-bottom: 84px; }

/* 메인: 금액 비교, 받는 주소 확인, 안심 뱃지 */
.save-now { margin-top: 12px; text-align: center; font-size: 15px; color: var(--muted); }
.save-now s { color: #ff8a65; }
.save-now b { color: var(--accent); }
.rcv-check { margin-top: 10px; }
.rcv-check summary { font-size: 15px; }
.badges { display: flex; flex-wrap: wrap; gap: 6px; margin-top: 10px; justify-content: center; }
.badges span {
  font-size: 12px; padding: 4px 10px; border-radius: 999px;
  background: rgba(122, 209, 107, .12); color: #9be08d; border: 1px solid rgba(122, 209, 107, .35);
}
.badges span::before { content: "✓ "; }

/* 맨 위로 버튼 (텔레그램 버튼 위) */
.top-fab {
  position: fixed; right: 22px; bottom: 80px; z-index: 50;
  width: 40px; height: 40px; border-radius: 50%; cursor: pointer;
  display: grid; place-items: center;
  background: var(--card); color: var(--text); border: 1px solid var(--line);
  box-shadow: 0 4px 12px rgba(0, 0, 0, .3);
}
.top-fab[hidden] { display: none; }

/* QR 크게 보기 */
.qr img#qrImg { cursor: zoom-in; }
.qr-full {
  position: fixed; inset: 0; z-index: 100; background: rgba(10, 5, 2, .94);
  display: flex; flex-direction: column; align-items: center; justify-content: center; gap: 16px; padding: 16px;
}
.qr-full[hidden] { display: none; }
.qr-full img { width: min(80vw, 420px); height: auto; background: #fff; border-radius: 16px; padding: 14px; }
.qr-full-addr { font-family: ui-monospace, SFMono-Regular, Menlo, Consolas, monospace; font-size: 14px; word-break: break-all; text-align: center; max-width: 420px; }
.qr-full p { color: var(--muted); font-size: 13px; }
/* 도착 확인 */
.arrive { margin-top: 14px; background: var(--bg2); }
.note.ok { border-left-color: #7ad16b; color: #c9f0c1; }
