/* Incremental ledger UI, matching the confirmed 402 × 874 screen proportion. */
.phone{width:402px;height:874px;aspect-ratio:402/874}.ledger-screen{padding:14px 17px 27px;overflow:hidden}.ledger-nav{display:grid;grid-template-columns:68px 1fr 68px;align-items:center;height:43px;margin:0 0 23px}.ledger-nav h2{text-align:center;margin:0;font-size:23px;font-weight:400}.ledger-nav button{width:30px;height:32px;padding:3px}.nav-tools{display:flex;justify-content:flex-end;gap:9px}.ledger-nav .icon{width:24px;height:24px}.range-tabs{display:flex;justify-content:space-between;background:#f4f0e8;border-radius:19px;margin-bottom:17px;padding:2px}.range-tabs button{font-size:16px;padding:11px 9px;border-radius:18px;color:#848074}.range-tabs button.selected{background:#eae1d2;color:#262621}.ledger-summary{display:grid;grid-template-columns:1fr 1fr;gap:2px;margin-bottom:18px;border-radius:17px;overflow:hidden;flex-shrink:0}.sumcard{background:#fffdf8;padding:17px 15px;display:flex;flex-direction:column;gap:7px}.sumcard span{font-size:16px}.sumcard strong{font-family:-apple-system,sans-serif;font-size:24px;font-weight:500;letter-spacing:-.6px}.ledger-results{overflow:auto;flex:1;min-height:0;scrollbar-width:none}.day-heading{display:flex;justify-content:space-between;padding:8px 4px 12px;font-size:14px}.day-heading span:last-child{color:#8b867b;font-size:12px}.ledger-group{background:#fffdf8;border-radius:17px;padding:2px 10px;margin-bottom:17px}.ledger-item{display:flex;gap:12px;padding:17px 2px;align-items:center;width:100%;text-align:left;border-bottom:1px solid #f1ece3}.ledger-item:last-child{border-bottom:0}.ledger-item>.icon{width:26px;height:26px;flex-shrink:0}.ledger-item-info{display:flex;flex-direction:column;gap:7px;flex:1;min-width:0}.ledger-item-info strong{font-size:18px;font-weight:400;overflow-wrap:anywhere}.ledger-item-info small{font-family:-apple-system,sans-serif;font-size:10px;color:#918a7f;line-height:1.5}.ledger-amount{font-family:-apple-system,sans-serif;font-size:15px;white-space:nowrap}.ledger-search{display:flex;align-items:center;background:#f0ebe2;border-radius:14px;margin:-4px 0 14px;padding:3px 10px}.ledger-search input{font:inherit;width:100%;background:none;border:0;padding:9px 0;outline:none;font-size:15px}.ledger-search button{padding:4px}.ledger-search .icon{width:18px;height:18px}.ledger-empty{text-align:center;padding:60px 15px;color:#8d877d}.ledger-empty .icon{width:32px;height:32px;opacity:.55}.ledger-empty p{font-size:18px}.ledger-empty span{font-size:13px;line-height:1.8}.detail-title{display:flex;align-items:center;gap:14px;margin:30px 4px 35px}.detail-title>.icon{width:34px;height:34px}.detail-title>div{flex:1;min-width:0}.detail-title h3{font-size:21px;font-weight:400;margin:0 0 7px;overflow-wrap:anywhere}.detail-title small{font-family:-apple-system,sans-serif;font-size:10px;color:#969080}.detail-title>strong{font-family:-apple-system,sans-serif;font-size:19px;font-weight:500;white-space:nowrap}.detail-fields{background:#fffdf8;border-radius:17px;padding:4px 18px}.detail-fields>div{display:flex;justify-content:space-between;gap:18px;padding:18px 0;border-bottom:1px solid #eee9e0;font-size:17px}.detail-fields>div:last-child{border-bottom:0}.detail-fields span:last-child{color:#6f6a60;text-align:right;max-width:65%;overflow-wrap:anywhere}.detail-actions{display:flex;gap:15px;margin:22px 0 0}.detail-actions button{flex:1;padding:15px 7px;border:1px solid #e2dccf;border-radius:18px;font-size:18px;line-height:1.3}.detail-actions .icon{width:22px;height:22px;margin-right:6px}.ledger-label{display:block;font-size:17px;margin:13px 0}.ledger-label input,.ledger-label select,.ledger-label textarea{width:100%;font-family:inherit;font-size:16px;padding:11px 13px;background:#fffdf8;border:1px solid #e9e2d5;border-radius:11px;margin-top:7px;color:#504c43}.ledger-label textarea{min-height:90px;resize:vertical}.ledger-edit-fields{overflow:auto;min-height:0;flex:1;padding:0 2px}#ledgerEditForm{display:flex;flex-direction:column;flex:1;min-height:0}.delete-copy{font-size:18px;line-height:1.8;margin:25px 0}.ledger-screen .primary{font-family:inherit}.ledger-screen form .primary{margin-bottom:6px}.ledger-nav,.range-tabs,.ledger-search{flex-shrink:0}
@media(max-width:700px){.phone{width:min(402px,100%);height:auto;aspect-ratio:402/874}.ledger-screen{padding:14px 15px 27px}.ledger-nav h2{font-size:22px}.range-tabs button{font-size:15px;padding:10px 7px}.sumcard{padding:15px 13px}.sumcard strong{font-size:23px}.ledger-item{padding:16px 1px;gap:10px}.ledger-amount{font-size:14px}.detail-title{gap:10px}.detail-title>strong{font-size:17px}}

.ledger-date-range{flex-shrink:0;text-align:center;font-size:15px;color:#797366;margin:-5px 0 16px}.ledger-date-range+.ledger-search{margin-top:0}

.ledger-swipe-row{position:relative;overflow:hidden;border-bottom:1px solid #f1ece3}.ledger-swipe-row:last-child{border-bottom:0}.ledger-swipe-row .ledger-item{position:relative;z-index:1;background:#fffdf8;border-bottom:0;transition:transform .18s ease;touch-action:pan-y;user-select:none;-webkit-user-select:none}.ledger-swipe-row .ledger-item.swiping{transition:none}.ledger-swipe-row .ledger-item img{pointer-events:none;-webkit-user-drag:none}.ledger-swipe-delete{position:absolute;right:0;top:0;bottom:0;width:84px;background:#2f2d29;color:#fffdf8;font:inherit;font-size:17px;border-radius:10px;z-index:0}.ledger-swipe-delete[hidden]{display:none}@media(prefers-reduced-motion:reduce){.ledger-swipe-row .ledger-item{transition:none}}

.ledger-edit-row{display:flex;align-items:center;gap:12px;width:100%;min-height:60px;padding:16px 2px;border-bottom:1px solid #eee9e0;text-align:left}.ledger-edit-row span{font-size:17px;color:#292722;white-space:nowrap}.ledger-edit-row strong{flex:1;min-width:0;text-align:right;font-size:16px;font-weight:400;color:#696358;overflow-wrap:anywhere}.ledger-edit-row .icon{width:16px;height:16px;opacity:.72;flex-shrink:0}.ledger-save-button{margin-top:18px;flex-shrink:0}.ledger-toast{position:absolute;left:50%;bottom:58px;transform:translateX(-50%);z-index:8;background:#2f2d29;color:#fffdf8;border-radius:999px;padding:11px 18px;font-size:15px;box-shadow:0 8px 24px rgba(54,48,39,.16);white-space:nowrap}.ledger-screen .choices{max-height:260px;overflow:auto}.ledger-screen .choice span:first-of-type{overflow-wrap:anywhere}.ledger-screen .number-display input{min-width:0}
