/* 对接方看清算单的页面：一列，手机上铺满，宽屏居中最宽 760。深色底，金额用等宽数字。 */
:root { --bg: #16181d; --card: #20232b; --line: #343844; --txt: #eef0f4; --mute: #9aa1b2; --acc: #ffd36a; --pos: #ff9a8a; --neg: #7fe0a2; --num: "DIN Alternate", "Roboto Condensed", "Arial Narrow", Arial, sans-serif; }
* { box-sizing: border-box; }
html, body { margin: 0; min-height: 100%; background: var(--bg); }
body { color: var(--txt); font: 14px/1.45 system-ui, -apple-system, "Segoe UI", Roboto, "PingFang SC", "Noto Sans Myanmar", "Noto Sans Bengali", sans-serif; padding: env(safe-area-inset-top, 0) env(safe-area-inset-right, 0) env(safe-area-inset-bottom, 0) env(safe-area-inset-left, 0); }
button, input { font: inherit; }
[hidden] { display: none !important; }
.num { font-family: var(--num); font-variant-numeric: tabular-nums; white-space: nowrap; }
#top { position: sticky; top: 0; z-index: 5; display: flex; align-items: center; gap: 10px; max-width: 760px; margin: 0 auto; padding: 10px 16px; background: var(--bg); border-bottom: 1px solid var(--line); }
#top b { flex: 1; min-width: 0; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
#main { max-width: 760px; margin: 0 auto; padding: 16px; }
h1 { font-size: 20px; margin: 8px 0 16px; }
h2 { font-size: 16px; margin: 20px 0 10px; }
.card { background: var(--card); border: 1px solid var(--line); border-radius: 10px; padding: 14px; margin-bottom: 12px; }
label { display: block; margin: 10px 0 4px; color: var(--mute); }
input { width: 100%; padding: 10px 12px; border-radius: 8px; border: 1px solid var(--line); background: #11131a; color: var(--txt); }
.btn { display: inline-block; padding: 10px 18px; border: 0; border-radius: 8px; background: var(--acc); color: #2a1800; font-weight: 600; cursor: pointer; }
.btn.wide { width: 100%; margin-top: 16px; }
.btn.ghost { background: transparent; color: var(--txt); border: 1px solid var(--line); }
.link { border: 0; background: none; color: var(--acc); cursor: pointer; padding: 4px; }
.hint { color: var(--mute); font-size: 12.5px; margin: 8px 0 0; }
.err { color: var(--pos); margin: 10px 0 0; }
.kv { display: grid; grid-template-columns: repeat(auto-fit, minmax(150px, 1fr)); gap: 10px; }
.kv div { background: #191c23; border-radius: 8px; padding: 10px; }
.kv small { display: block; color: var(--mute); font-size: 12px; }
.kv b { font-size: 16px; }
.warn { border-color: #8a4b2a; background: #2b1d17; }
.row { display: flex; align-items: center; gap: 10px; width: 100%; text-align: left; color: inherit; cursor: pointer; }
.row .grow { flex: 1; min-width: 0; }
.row small { display: block; color: var(--mute); }
.tag { display: inline-block; padding: 1px 8px; border-radius: 10px; font-size: 12px; background: #3a3f4c; white-space: nowrap; }
.tag.draft { background: #5a4a14; color: #ffe39a; }
.tag.confirmed { background: #173d5a; color: #a6d8ff; }
.tag.settled { background: #1d4a2c; color: #a7f0c0; }
.pay { font-size: 17px; font-weight: 700; text-align: right; }
.pay small { font-weight: 400; font-size: 11.5px; color: var(--mute); }
.pay.p { color: var(--pos); } .pay.n { color: var(--neg); }
.scroll { overflow-x: auto; -webkit-overflow-scrolling: touch; }
table { width: 100%; border-collapse: collapse; font-size: 13px; }
th, td { padding: 7px 6px; border-bottom: 1px solid var(--line); text-align: right; white-space: nowrap; }
th:first-child, td:first-child { text-align: left; }
th { color: var(--mute); font-weight: 500; white-space: normal; vertical-align: bottom; }
@media (max-width: 480px) { table { font-size: 12px; } th, td { padding: 6px 3px; } }
tfoot td { font-weight: 700; border-bottom: 0; }
.acts { display: flex; gap: 10px; flex-wrap: wrap; margin-top: 14px; }
#toast { position: fixed; left: 50%; bottom: calc(20px + env(safe-area-inset-bottom, 0px)); transform: translateX(-50%); max-width: calc(100% - 32px); padding: 10px 16px; border-radius: 8px; background: #000c; color: #fff; opacity: 0; pointer-events: none; transition: opacity .2s; }
#toast.on { opacity: 1; }
