:root { --teal: #0f766e; --deep: #0f3d3a; --gold: #facc15; --ink: #14201f; --muted: #647572; --line: #e2e9e7; --bg: #f4f7f6; --card: #fff; --red: #b42318; --amber: #fff7e0; --amber-line: #f1d48a; --ok: #177245; }
[hidden] { display: none !important; }
* { box-sizing: border-box; -webkit-tap-highlight-color: transparent; }
html, body { margin: 0; height: 100%; background: var(--bg); color: var(--ink); font: 16px/1.4 system-ui, -apple-system, "Segoe UI", Roboto, sans-serif; }
button, input, select, textarea { font: inherit; color: inherit; }
#app { min-height: 100%; display: flex; flex-direction: column; max-width: 560px; margin: 0 auto; background: var(--bg); }
.boot { margin: auto; color: var(--teal); font-weight: 700; font-size: 22px; padding: 40vh 0; text-align: center; }
.top { background: var(--deep); color: #fff; padding: calc(12px + env(safe-area-inset-top, 0px)) 16px 12px; position: sticky; top: 0; z-index: 5; }
.top h1 { margin: 0; font-size: 17px; font-weight: 700; display: flex; align-items: center; gap: 8px; }
.top .sub { font-size: 12.5px; opacity: .8; margin-top: 2px; display: flex; gap: 8px; align-items: center; flex-wrap: wrap; }
.dot { width: 8px; height: 8px; border-radius: 50%; background: #9aa; display: inline-block; } .dot.on { background: #4ade80; } .dot.off { background: var(--gold); }
.top .sync { margin-left: auto; background: rgba(255,255,255,.14); border: 0; color: #fff; border-radius: 999px; padding: 6px 12px; font-size: 13px; font-weight: 600; }
main { flex: 1; padding: 14px 16px calc(92px + env(safe-area-inset-bottom, 0px)); display: grid; gap: 12px; align-content: start; }
.card { background: var(--card); border: 1px solid var(--line); border-radius: 14px; padding: 14px; }
.card h2 { margin: 0 0 8px; font-size: 13px; letter-spacing: .04em; text-transform: uppercase; color: var(--muted); font-weight: 700; }
.big { font-size: 30px; font-weight: 800; letter-spacing: -.01em; font-variant-numeric: tabular-nums; } .big small { font-size: 14px; font-weight: 600; color: var(--muted); margin-left: 6px; }
.hero { background: var(--teal); color: #fff; border: 0; } .hero h2 { color: rgba(255,255,255,.75); } .hero .big small { color: rgba(255,255,255,.8); }
.grid2 { display: grid; grid-template-columns: 1fr 1fr; gap: 8px; margin-top: 10px; } .grid2 div { background: rgba(255,255,255,.12); border-radius: 10px; padding: 8px 10px; } .grid2 span { display: block; font-size: 12px; opacity: .8; } .grid2 b { font-variant-numeric: tabular-nums; }
.row { display: flex; justify-content: space-between; gap: 12px; padding: 9px 0; border-top: 1px solid var(--line); align-items: baseline; } .row:first-of-type { border-top: 0; }
.row .l { min-width: 0; } .row .l small { display: block; color: var(--muted); font-size: 12.5px; } .row .r { font-weight: 700; font-variant-numeric: tabular-nums; white-space: nowrap; text-align: right; } .row .r small { display: block; font-weight: 500; color: var(--muted); font-size: 12px; }
.neg { color: var(--red); } .muted { color: var(--muted); } .note { background: var(--amber); border: 1px solid var(--amber-line); border-radius: 12px; padding: 10px 12px; font-size: 14px; }
.tabs { position: fixed; bottom: 0; left: 0; right: 0; max-width: 560px; margin: 0 auto; background: #fff; border-top: 1px solid var(--line); display: flex; padding-bottom: env(safe-area-inset-bottom, 0px); z-index: 6; }
.tabs button { flex: 1; border: 0; background: none; padding: 9px 2px 8px; font-size: 11.5px; font-weight: 600; color: var(--muted); display: grid; gap: 2px; justify-items: center; position: relative; }
.tabs button svg { width: 22px; height: 22px; } .tabs button.on { color: var(--teal); } .tabs .badge { position: absolute; top: 4px; left: 54%; background: var(--gold); color: var(--deep); border-radius: 999px; font-size: 10.5px; font-weight: 800; padding: 0 5px; min-width: 16px; }
label.f { display: grid; gap: 4px; font-weight: 600; font-size: 14px; } label.f input, label.f select, label.f textarea { border: 1px solid #cfd9d7; border-radius: 10px; padding: 12px; background: #fff; width: 100%; font-weight: 400; font-size: 16px; }
.btn { border: 0; border-radius: 12px; background: var(--teal); color: #fff; font-weight: 700; padding: 14px 16px; width: 100%; font-size: 16px; } .btn.gold { background: var(--gold); color: var(--deep); } .btn.ghost { background: #fff; color: var(--teal); border: 1px solid var(--teal); } .btn.danger { background: #fff; color: var(--red); border: 1px solid #e7b6b1; } .btn:disabled { opacity: .5; }
.seg { display: flex; background: #e8eeec; border-radius: 12px; padding: 3px; } .seg button { flex: 1; border: 0; background: none; padding: 9px 4px; border-radius: 10px; font-weight: 600; font-size: 14px; color: var(--muted); } .seg button.on { background: #fff; color: var(--ink); box-shadow: 0 1px 2px rgba(0,0,0,.12); }
.chips { display: flex; gap: 6px; overflow-x: auto; padding-bottom: 2px; scrollbar-width: none; } .chips::-webkit-scrollbar { display: none; } .chips button { border: 1px solid var(--line); background: #fff; border-radius: 999px; padding: 6px 12px; white-space: nowrap; font-size: 13.5px; font-weight: 600; color: var(--muted); } .chips button.on { background: var(--deep); color: #fff; border-color: var(--deep); }
.items { display: grid; gap: 0; } .item { display: flex; align-items: center; gap: 10px; padding: 10px 0; border-top: 1px solid var(--line); } .item:first-child { border-top: 0; } .item .l { flex: 1; min-width: 0; } .item .l b { display: block; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; font-weight: 600; } .item .l small { color: var(--muted); font-size: 12.5px; }
.qty { display: flex; align-items: center; gap: 6px; } .qty button { width: 36px; height: 36px; border-radius: 10px; border: 1px solid var(--line); background: #fff; font-size: 20px; font-weight: 700; color: var(--teal); line-height: 1; } .qty button.add { background: var(--teal); color: #fff; border-color: var(--teal); } .qty span { min-width: 22px; text-align: center; font-weight: 700; }
.cartbar { position: fixed; left: 0; right: 0; bottom: calc(58px + env(safe-area-inset-bottom, 0px)); max-width: 560px; margin: 0 auto; padding: 0 12px 8px; z-index: 6; } .cartbar button { display: flex; justify-content: space-between; align-items: center; box-shadow: 0 6px 18px rgba(15,61,58,.28); }
.sheet { position: fixed; inset: 0; background: rgba(10,25,24,.5); z-index: 20; display: flex; align-items: flex-end; } .sheet > div { background: #fff; border-radius: 18px 18px 0 0; width: 100%; max-width: 560px; margin: 0 auto; padding: 16px 16px calc(18px + env(safe-area-inset-bottom, 0px)); max-height: 92vh; overflow: auto; display: grid; gap: 12px; } .sheet h3 { margin: 0; font-size: 18px; display: flex; justify-content: space-between; align-items: center; } .sheet h3 button { border: 0; background: #eef2f1; border-radius: 999px; width: 32px; height: 32px; font-size: 18px; }
.pill { display: inline-block; border-radius: 999px; padding: 1px 9px; font-size: 12px; font-weight: 700; } .pill.wait { background: var(--amber); color: #7a5a00; } .pill.sent { background: #e6eefc; color: #1d4ed8; } .pill.ok { background: #e3f4ea; color: var(--ok); } .pill.no { background: #fdecec; color: var(--red); }
.pair { padding: calc(28px + env(safe-area-inset-top, 0px)) 20px 28px; display: grid; gap: 16px; align-content: start; flex: 1; background: var(--deep); color: #fff; } .pair img { width: 72px; height: 72px; border-radius: 18px; } .pair h1 { margin: 0; font-size: 28px; } .pair p { margin: 0; opacity: .85; } .pair .box { background: #fff; color: var(--ink); border-radius: 16px; padding: 16px; display: grid; gap: 12px; }
.code { text-align: center; font: 700 24px/1.2 ui-monospace, Menlo, Consolas, monospace; letter-spacing: .08em; text-transform: uppercase; } .steps { margin: 0; padding-left: 20px; display: grid; gap: 6px; font-size: 14.5px; }
.err { color: var(--red); font-weight: 600; font-size: 14px; } .toast { position: fixed; left: 16px; right: 16px; top: calc(10px + env(safe-area-inset-top, 0px)); max-width: 528px; margin: 0 auto; background: var(--deep); color: #fff; padding: 12px 14px; border-radius: 12px; z-index: 30; font-weight: 600; text-align: center; }
.empty { text-align: center; color: var(--muted); padding: 18px 0; } .total { display: flex; justify-content: space-between; font-size: 20px; font-weight: 800; padding-top: 8px; border-top: 2px solid var(--ink); }
.menu { display: flex; width: 100%; justify-content: space-between; align-items: center; gap: 10px; background: none; border: 0; border-top: 1px solid var(--line); padding: 12px 0; text-align: left; } .menu:first-of-type { border-top: 0; } .menu b { display: block; font-weight: 600; } .menu small { color: var(--muted); font-size: 13px; } .menu i { font-style: normal; color: var(--muted); font-size: 22px; }
.line { border: 1px solid var(--line); border-radius: 12px; padding: 10px; display: grid; gap: 8px; background: #fafcfb; } #i-lines, #b-lines { display: grid; gap: 8px; } .two { display: grid; grid-template-columns: 1fr 1fr; gap: 8px; } .two > * { min-width: 0; }
.row.sub { border-top: 0; padding: 2px 0 2px 12px; font-size: 14.5px; } .row.sub .r { font-weight: 500; }
