/* Familiar ledger and keypad interactions, with Qingzhang's own visual identity. */
:root{--canvas:#f7f8fa;--paper:#fff;--ink:#26302e;--muted:#939b97;--line:#edf0ee;--mint:#238368;--mint-dark:#216e58;--mint-soft:#e9f5ef}
.brand-splash{display:none}
.qz-pocket-home{background:#fff;animation:none}
.qz-pocket-home>.app-topbar{padding:calc(18px + env(safe-area-inset-top)) 20px 12px;background:#f0f7f2}
.app-book-button h1{font-size:18px;font-weight:600;max-width:190px}
.app-brand-mark{width:29px;height:31px;border-radius:8px;background:#438969}
.qz-header-actions{display:flex;gap:5px;align-items:center}
.qz-header-actions .app-header-button{width:32px;min-height:36px;padding:4px;color:#577764}
.qz-pocket-summary.app-month-summary{margin:0;padding:0 22px 16px;background:#f0f7f2;border-radius:0;color:#35533e}
.qz-pocket-summary .app-summary-top{margin-bottom:10px}
.qz-pocket-summary .month-navigator>span{font-size:12px;color:#7c9485;font-weight:400}
.qz-pocket-summary .app-eye{color:#94ac9b}
.qz-pocket-totals{display:grid;grid-template-columns:1.15fr 1fr 1fr;gap:15px}
.qz-pocket-totals>div{min-width:0;display:flex;flex-direction:column;gap:7px}
.qz-pocket-totals span{font-size:11px;color:#8aa091}
.qz-pocket-totals strong,.qz-pocket-totals .app-month-expense{display:block;margin:0;font-size:21px;line-height:1.25;font-weight:550;letter-spacing:-.6px;color:#2d513a;font-variant-numeric:tabular-nums;overflow-wrap:anywhere}
.qz-pocket-totals .app-month-expense{font-size:24px;font-weight:650}
.qz-pocket-budget{border:0;border-top:1px solid #e1ece3;background:none;display:flex;gap:8px;align-items:center;width:100%;min-height:34px;margin:16px 0 -7px;padding:8px 0 2px;text-align:left;color:#9aaba0;font-size:10px}
.qz-pocket-budget b{font-weight:400;color:#799382}.qz-pocket-budget svg{margin-left:auto}
.qz-pocket-home .app-ledger-section{padding:0;margin:0}
.qz-ledger-tabs{display:flex;align-items:center;justify-content:space-between;padding:15px 21px 9px;border-bottom:1px solid #eff2f0;background:#fff}
.qz-ledger-tabs>.text-button{color:#a0aaa3;font-size:11px;min-height:36px}
.qz-view-switch{display:flex;gap:26px}
.qz-view-switch button{position:relative;min-height:38px;padding:0 0 8px;background:none;border:0;color:#a2aaa6;font-size:15px;font-weight:400}
.qz-view-switch button.active{color:#2d4e3a;font-weight:600}
.qz-view-switch button.active:after{content:'';position:absolute;bottom:0;left:50%;transform:translateX(-50%);height:3px;width:18px;border-radius:2px;background:#5d9a76}
.qz-pocket-home .app-day-group{margin:0}
.qz-pocket-home .app-day-heading{padding:12px 21px 9px;background:#f8f9fa;color:#8b948f}
.qz-pocket-home .app-day-heading>span{font-size:12px;color:#7c8981}
.qz-pocket-home .app-day-heading small{font-size:10px;color:#a6afa9}
.qz-pocket-home .app-day-list{border-radius:0;background:#fff}
.qz-pocket-home .transaction-row{padding:14px 21px;min-height:76px;gap:14px}
.qz-pocket-home .category-icon{width:35px;height:35px;border-radius:12px}
.qz-pocket-home .transaction-copy b{font-size:14px;font-weight:500}
.qz-pocket-home .transaction-copy span{font-size:10px;color:#a5afa8;margin-top:4px}
.qz-pocket-home .transaction-amount b{font-size:16px;font-weight:500;color:#46584b}
.qz-pocket-home .transaction-amount small{font-size:10px;color:#b0b8b2}
.qz-pocket-home .app-transaction-button+.app-transaction-button:before{left:70px;right:21px}
.qz-pocket-home .app-list-end{padding:18px;margin:0;background:#f8f9fa;color:#bdc4bf;min-height:50px}
.qz-pocket-home .app-empty-ledger{padding:44px 20px;background:#fafbfa}
.qz-pocket-home .app-empty-ledger>span{background:transparent;padding:12px;color:#ced9d0}
.qz-pocket-home .app-empty-ledger h3{font-size:14px}.qz-pocket-home .app-empty-ledger p{font-size:11px;color:#a5b2a8}
.qz-pocket-home .app-load-more{border-top:1px solid #f1f3f1;border-radius:0;font-size:11px}
.qz-calendar{padding:9px 15px 15px;border-bottom:6px solid #f7f9f7;background:#fff}
.qz-calendar-week,.qz-calendar-days{display:grid;grid-template-columns:repeat(7,minmax(0,1fr));gap:3px;text-align:center}
.qz-calendar-week{font-size:10px;color:#b0bab3;padding:8px 0 10px}
.qz-calendar-days>button{min-height:49px;display:flex;flex-direction:column;align-items:center;justify-content:center;gap:5px;min-width:0;background:transparent;border:0;border-radius:11px;color:#5f7165;padding:5px 1px}
.qz-calendar-days b{font-size:13px;font-weight:500}.qz-calendar-days small{font-size:8px;color:#d18f72;white-space:nowrap;max-width:100%;overflow:hidden;text-overflow:ellipsis;font-variant-numeric:tabular-nums}
.qz-calendar-days>button.today b{color:#37836a}.qz-calendar-days>button.selected{background:#e9f4ec;color:#34794f}.qz-calendar-days>button.selected b{font-weight:650}
.bottom-nav{height:calc(75px + env(safe-area-inset-bottom));background:#fff;border-color:#edf0ed;box-shadow:0 -2px 10px #32443103}
.bottom-nav .nav-add-wrap .nav-add{width:47px;height:40px;min-height:40px;border-radius:14px;background:#2d8869}
.bottom-nav>button.active{color:#42856a}.bottom-nav>button{color:#abb5ae}
.qz-native-entry{position:relative}
.modal-backdrop:has(.qz-native-entry){animation:none;opacity:1}
.modal-sheet:has(.qz-native-entry){display:flex;flex-direction:column;height:min(820px,92dvh);max-height:92dvh;padding:0;overflow:hidden;animation:none;transform:none;opacity:1}
.modal-sheet:has(.qz-native-entry)>header{flex-shrink:0;padding:17px 20px;min-height:64px;border:0;position:relative;justify-content:center}
.modal-sheet:has(.qz-native-entry)>header h2{font-size:17px;font-weight:550;text-align:center}
.modal-sheet:has(.qz-native-entry)>header>.icon-button{position:absolute;left:14px;background:transparent;color:#7b9083}
.modal-sheet>.modal-body:has(>.qz-native-entry){padding:0;overflow:hidden;display:flex;min-height:0;flex:1}
.qz-native-entry.form-stack{display:flex;flex-direction:column;gap:0;width:100%;height:100%;min-height:0}
.qz-entry-content{padding:0 21px;flex:1;min-height:0;overflow-y:auto;scrollbar-width:none}
.qz-entry-content::-webkit-scrollbar{display:none}
.qz-native-entry .type-tabs{display:flex;align-items:center;justify-content:center;gap:30px;background:none;padding:0;border:0;border-radius:0;margin:0 0 3px}
.qz-native-entry .type-tabs button{position:relative;flex:none;padding:8px 4px 12px;font-size:15px;color:#a0aaa3;min-height:42px;font-weight:400}
.qz-native-entry .type-tabs button.active{background:none;box-shadow:none;color:#397d57;font-weight:550}
.qz-native-entry .type-tabs button.active:after{content:'';position:absolute;bottom:0;left:50%;transform:translateX(-50%);width:22px;height:3px;background:#73a783;border-radius:2px}
.qz-native-entry .amount-field{display:block;margin:10px 0 13px;padding:9px 0 13px;background:#fff;border:0;border-bottom:1px solid #edf1ed;border-radius:0;box-shadow:none}
.qz-native-entry .amount-field>span{display:block;min-height:18px;font-size:11px;color:#97a79a;line-height:1.6}
.qz-native-entry .amount-field>div{display:flex;gap:7px;align-items:baseline;margin:4px 0 0}
.qz-native-entry .amount-field b{color:#5d7765;font-size:25px;font-weight:400}
.qz-native-entry .amount-field input{background:none;min-width:0;color:#31593f;font-size:40px!important;line-height:1.3;font-weight:550;letter-spacing:-.8px;padding:0;border:0;outline:none!important}
.qz-native-entry .amount-field input::placeholder{color:#b5c3b9}
.qz-native-entry .category-picker{margin:0 0 6px}.qz-native-entry .field-label{display:none}
.qz-native-entry .category-picker>div{display:grid;grid-template-columns:repeat(4,minmax(0,1fr));gap:1px 5px}
.qz-native-entry .category-picker button{padding:9px 0 7px;min-height:74px;border-radius:12px;gap:7px;font-size:11px;background:#fff;color:#9aa79d}
.qz-native-entry .category-picker button.active{background:#f0f7f1;color:#537d5d}
.qz-native-entry .category-icon{width:34px;height:34px;border:0;border-radius:50%;box-shadow:none;background:#f5f7f5}
.qz-native-entry .category-picker button.active .category-icon{background:#dfefdf;color:#78a167}
.qz-entry-merchant{margin:9px 0 3px}.qz-entry-merchant .field{display:block}
.qz-entry-merchant .field>span{display:none}.qz-entry-merchant .field input{min-height:41px;height:41px;padding:8px 0;border:0;border-bottom:1px solid #f0f3f0;border-radius:0;background:none;font-size:13px!important;color:#5d7262}
.qz-entry-merchant .field input::placeholder{color:#b5bfb7}
.qz-entry-chips{display:flex;align-items:center;gap:8px;padding:9px 0 12px;min-height:48px}
.qz-entry-chips>button{display:flex;align-items:center;gap:5px;min-height:31px;background:#f4f7f4;border:0;border-radius:8px;padding:6px 9px;font-size:10px;color:#85998a;min-width:0;max-width:52%}
.qz-entry-chips>button span{overflow:hidden;text-overflow:ellipsis;white-space:nowrap}.qz-entry-chips>button svg{flex-shrink:0}
.qz-keyboard{flex-shrink:0;background:#f6f8f6;padding:5px 10px calc(10px + env(safe-area-inset-bottom));border-top:1px solid #eef2ee}
.qz-keyboard.typing{display:none}
.qz-keyboard-head{display:flex;align-items:center;justify-content:space-between;padding:0 5px 4px;min-height:23px;font-size:9px;color:#abb9ae}
.qz-keyboard-head>button{border:0;background:none;color:#9baea1;font-size:10px;min-height:23px;padding:1px 7px}
.qz-keyboard-grid{display:grid;grid-template-columns:repeat(4,minmax(0,1fr));gap:5px}
.qz-key{border:0;border-radius:8px;background:#fff;color:#4b6051;min-width:0;min-height:47px;font-size:24px;font-weight:400;font-family:-apple-system,BlinkMacSystemFont,'Segoe UI',sans-serif;line-height:1;display:grid;place-items:center;padding:8px}
.qz-key.operator{background:#eaf2eb;color:#6d9276;font-size:23px}.qz-key:active{background:#e3eee4;transform:none}
.qz-key-save.primary-button{min-width:0;min-height:47px;border-radius:8px;background:#398b64;color:#fff;font-size:14px;padding:6px 2px;box-shadow:none!important;margin:0}
.qz-entry-details[hidden]{display:none!important}
.qz-entry-details{position:fixed;bottom:0;left:0;right:0;z-index:8;margin:0 auto;max-width:520px;padding:22px 22px calc(25px + env(safe-area-inset-bottom));background:#fff;border-radius:22px 22px 0 0;box-shadow:0 0 0 100vmax #2543304a;display:grid;gap:17px;max-height:88dvh;overflow:auto}
.qz-entry-details>header{display:flex;align-items:center;justify-content:space-between;border:0;padding:0;min-height:33px;margin:0}
.qz-entry-details h3{font-size:16px;font-weight:550;margin:0}.qz-entry-details .text-button{color:#689472;font-size:13px}
.qz-entry-details .field>span{font-size:11px;color:#90a093}.qz-entry-details .field input,.qz-entry-details .field select{background:#f8faf8;border-color:#e9eee9;font-size:15px!important;min-height:46px}
.qz-transfer-preview{display:flex;gap:16px;justify-content:space-between;align-items:center;padding:35px 12px;color:#819888;font-size:13px;background:#f6faf6;border-radius:14px;margin:12px 0 20px}
.qz-native-entry .qz-form-error{margin:5px 0 10px;font-size:11px;color:#b57b61}
.app-stats-page .section-card{border-radius:11px}.app-assets-page .asset-overview-card{border-radius:12px;background:#edf6f0}.app-assets-page .account-grid{border-radius:11px}
@media(max-width:599px){
  .modal-sheet:has(.qz-native-entry){height:100dvh;max-height:100dvh;padding-top:env(safe-area-inset-top)}
}
@media(min-width:600px){
  .qz-pocket-home>.app-topbar{padding-top:23px}.qz-pocket-summary.app-month-summary{padding-left:25px;padding-right:25px}
  .qz-pocket-totals strong,.qz-pocket-totals .app-month-expense{font-size:27px}
  .qz-entry-content{padding-left:24px;padding-right:24px}.qz-key{min-height:53px}
  .qz-entry-details{bottom:4dvh;border-radius:20px;max-width:500px}
}
@media(max-width:359px){
  .qz-pocket-home>.app-topbar{padding-left:16px;padding-right:13px}.app-book-button h1{font-size:17px;max-width:158px}.qz-header-actions{gap:0}
  .qz-pocket-summary.app-month-summary{padding-left:18px;padding-right:18px}.qz-pocket-totals{gap:10px}.qz-pocket-totals strong{font-size:19px}.qz-pocket-totals .app-month-expense{font-size:21px}
  .qz-pocket-home .transaction-row{padding-left:17px;padding-right:17px;gap:12px}.qz-pocket-home .app-day-heading{padding-left:17px;padding-right:17px}
  .qz-native-entry .type-tabs{gap:22px}.qz-entry-content{padding-left:17px;padding-right:17px}.qz-native-entry .category-picker button{min-height:68px}
  .qz-entry-chips{gap:6px}.qz-entry-chips>button{padding:6px 7px;font-size:9px}.qz-key{min-height:43px;font-size:22px}
}
@media(max-height:700px){.qz-native-entry .category-picker button{min-height:64px}.qz-native-entry .amount-field{margin-top:4px;margin-bottom:7px}.qz-key{min-height:43px}}
