* { box-sizing: border-box; }
[hidden] { display: none !important; }
body { margin: 0; font-family: -apple-system, "PingFang SC", "Microsoft YaHei", sans-serif; color: #111; background: #f5f5f5; font-size: 17px; line-height: 1.5; }
.top { position: sticky; top: 0; z-index: 5; display: flex; align-items: center; justify-content: space-between; padding: 10px 14px; background: #fff; border-bottom: 1px solid #ddd; }
.top h1 { font-size: 22px; margin: 0; }
.top-actions { display: flex; gap: 8px; }
main { max-width: 640px; margin: 0 auto; padding: 8px 12px 80px; }
.hint { color: #555; padding: 24px 4px; }
.msg { margin: 8px 12px; padding: 10px 12px; border-radius: 8px; background: #eef6ff; }
.msg.err { background: #fdecea; color: #a00; }
h2.batch { font-size: 20px; margin: 18px 0 4px; }
.day-head { background: #fff; border-radius: 10px; padding: 12px; margin: 12px 0 8px; border: 1px solid #ddd; }
.day-head h3 { margin: 0 0 4px; font-size: 20px; }
.day-sum { color: #444; font-size: 15px; margin-bottom: 8px; }
.card { background: #fff; border: 1px solid #ccc; border-radius: 12px; padding: 12px; margin: 10px 0; }
.card.shipped { border-color: #4a4; background: #f1faf1; }
.card .head { display: flex; align-items: center; gap: 8px; font-size: 18px; }
.card .num { min-width: 28px; height: 28px; line-height: 28px; text-align: center; border-radius: 14px; background: #222; color: #fff; font-size: 14px; }
.card .content { margin-left: auto; color: #333; font-size: 15px; }
.card .note { margin: 6px 0; padding: 4px 8px; background: #fff3cd; border-radius: 6px; font-weight: bold; }
.card .line { word-break: break-all; }
.card a { color: #0a58ca; }
button, .filebtn, a.ghost { font-size: 16px; padding: 10px 14px; border-radius: 8px; border: 1px solid #888; background: #f4f4f4; color: #111; text-decoration: none; display: inline-block; text-align: center; cursor: pointer; }
button.big { width: 100%; padding: 13px 0; margin-top: 10px; font-size: 17px; }
button.primary { background: #1f6feb; border-color: #1f6feb; color: #fff; }
button.ghost, a.ghost { background: #fff; }
button:disabled { opacity: .6; }
.ship { margin-top: 12px; padding-top: 10px; border-top: 1px dashed #bbb; }
.ship .status { font-weight: bold; margin-bottom: 6px; }
.card.shipped .ship .status { color: #2a7a2a; }
.ship label { display: block; font-size: 15px; color: #444; }
.ship .row { display: flex; gap: 8px; margin: 6px 0; align-items: center; }
.ship input { width: 100%; font-size: 17px; padding: 10px; border: 1px solid #999; border-radius: 8px; }
.ship .row input { flex: 1; }
.ship .track { margin-left: auto; font-size: 16px; }
.costs { display: grid; grid-template-columns: repeat(3, 1fr); gap: 8px; margin-top: 6px; }
.costs input { margin-top: 2px; }
.photos { display: flex; gap: 6px; flex-wrap: wrap; }
.photos img { width: 72px; height: 72px; object-fit: cover; border-radius: 6px; border: 1px solid #ccc; }
.saved { margin-top: 6px; color: #2a7a2a; font-size: 15px; }
.scanner { position: fixed; inset: 0; background: rgba(0,0,0,.85); z-index: 20; display: flex; align-items: center; justify-content: center; }
.scanner-box { width: 92%; max-width: 480px; background: #fff; border-radius: 12px; padding: 12px; }
.scanner-box p { margin: 0 0 8px; }
#reader { width: 100%; min-height: 200px; }
.viewer { position: fixed; inset: 0; background: rgba(0,0,0,.9); z-index: 30; display: flex; flex-direction: column; align-items: center; justify-content: center; }
.viewer img { max-width: 100%; max-height: 85vh; }
.viewer p { color: #fff; }
.photos img { cursor: pointer; }
