:root{--edit-ink:#15221a;--edit-muted:#778075;--edit-line:#e5e9e2;--edit-green:#41704b;--edit-pale:#f3f5f1;--edit-rail:#202d50}
.editor-page{height:100vh;min-height:620px;overflow:hidden;background:#f1f2ef;color:var(--edit-ink);font-family:'Inter',Arial,Helvetica,sans-serif}.reference-editor-header{height:62px;background:#fff;border-bottom:1px solid var(--edit-line);display:flex;align-items:center;gap:clamp(12px,2vw,32px);padding:0 18px 0 20px;position:relative;z-index:20}.reference-editor-header>.editor-logo{display:flex;align-items:center;width:160px;flex:none}.editor-logo img{width:100%;height:auto}.editor-back{display:flex;align-items:center;gap:6px;font-size:12px;color:#5e685e;white-space:nowrap}.editor-back svg{width:15px;height:15px}.template-select-label{display:flex;align-items:center;gap:9px;margin-left:8px;font-size:11px;color:#666f65;white-space:nowrap}.template-select-label select{max-width:205px;padding:8px 29px 8px 10px;border:1px solid #dce1d9;border-radius:6px;background:#fff;color:#243124;font:inherit;font-size:11px}.save-state{margin-left:auto;color:#8b9188;font-size:10px;white-space:nowrap}.save-state.is-saved{color:#4e8054}.reset-editor,.preview-button{display:inline-flex;align-items:center;justify-content:center;gap:7px;min-height:34px;padding:0 12px;background:#fff;border:1px solid var(--edit-line);border-radius:7px;color:#455145;font-size:11px;white-space:nowrap}.reset-editor{color:#8a4644}.preview-button{background:#1d2a22;color:white;border-color:#1d2a22}.reset-editor svg,.preview-button svg{height:15px;width:15px}
.reference-editor-layout{height:calc(100dvh - 62px);min-height:558px;display:grid;grid-template-columns:78px 276px minmax(0,1fr) 68px;overflow:hidden}.tool-rail{min-height:0;overflow-y:auto;background:var(--edit-rail);color:#fff;display:flex;flex-direction:column;align-items:stretch;padding:13px 8px 12px;gap:5px}.tool-rail-label{text-align:center;font-size:8px;letter-spacing:1.4px;color:#b8c5db;padding:5px 0 9px}.tool-tab{position:relative;display:flex;min-height:58px;align-items:center;justify-content:center;flex-direction:column;gap:5px;padding:7px 2px;border:0;border-radius:7px;background:transparent;color:#d5deeb;font:inherit;cursor:pointer}.tool-tab svg{width:19px;height:19px;stroke-width:1.8}.tool-tab span{font-size:9px}.tool-tab:hover{background:#ffffff13}.tool-tab.is-selected{background:#ffffff1b;color:#fff}.tool-tab.is-selected:before{content:"";position:absolute;left:-8px;top:9px;bottom:9px;width:3px;border-radius:0 3px 3px 0;background:#d8edaf}.rail-guard{display:flex;align-items:center;justify-content:center;flex-direction:column;gap:5px;margin-top:auto;padding:10px 0 3px;color:#ced7e4;font-size:8px}.rail-guard svg{width:16px;height:16px;color:#d8edaf}
.tool-settings{min-width:0;min-height:0;display:flex;flex-direction:column;background:#f8f9f7;border-right:1px solid #dfe3dc}.settings-heading{height:59px;flex:none;display:flex;align-items:center;justify-content:space-between;padding:0 16px;background:#fff;border-bottom:1px solid var(--edit-line)}.settings-heading>div>span{font-size:8px;letter-spacing:1.3px;color:#858c83}.settings-heading h1{font-size:15px;line-height:1.15;font-weight:500;margin:4px 0 0}.settings-close{display:none;align-items:center;justify-content:center;border:0;background:#f0f2ee;border-radius:50%;height:30px;width:30px}.settings-close svg{width:16px;height:16px}.settings-content{min-height:0;flex:1;overflow:auto;padding:13px 15px 25px;scrollbar-width:thin;scrollbar-color:#c7cdc3 transparent}.settings-group{background:#fff;border:1px solid #e9ece7;border-radius:8px;padding:12px;margin-bottom:13px;box-shadow:0 2px 7px #12201006}.settings-group h2{font-size:10px;letter-spacing:.6px;font-weight:600;margin:0 0 12px;color:#414a40}.element-toggle{min-height:27px;display:flex;align-items:center;gap:9px;color:#5f675e;font-size:10px;cursor:pointer}.element-toggle input{position:absolute;opacity:0;width:1px;height:1px}.fake-check{height:15px;width:15px;display:grid;place-items:center;border:1px solid #c8cec6;background:#fff;border-radius:3px;flex:none}.element-toggle input:checked+.fake-check{background:#45774d;border-color:#45774d}.element-toggle input:checked+.fake-check:after{content:"";height:7px;width:4px;border:solid white;border-width:0 1.5px 1.5px 0;transform:rotate(45deg);margin-top:-2px}.element-toggle input:focus-visible+.fake-check{outline:2px solid #3b7349;outline-offset:2px}.dynamic-group{padding:13px}.settings-group>label:not(.element-toggle),.setting-row label{display:block;font-size:9px;color:#626b61;margin:11px 0 5px}.settings-group>label>span,.setting-row label span{margin-left:5px;font-size:7px;letter-spacing:.7px;color:#9aa096}.setting-input{display:block;width:100%;height:32px;padding:0 9px;background:#fff;border:1px solid #dfe4dc;border-radius:5px;color:#354035;font:inherit;font-size:10px}.setting-input:focus{outline:2px solid #537b5826;border-color:#719276}.setting-row{display:grid;grid-template-columns:1fr 1fr;gap:8px}.setting-amount{height:32px;display:flex;align-items:center;padding-left:9px;border:1px solid #dfe4dc;border-radius:5px;background:#fff;font-size:10px;color:#697368}.setting-amount .setting-input{height:30px;border:0;padding-left:5px;min-width:0}.tool-hint{font-size:10px;line-height:1.6;color:#758071;margin:10px 0}.upload-choice{min-height:40px;display:flex;gap:9px;align-items:center;padding:9px;border:1px dashed #bdc9bb;border-radius:6px;color:#446447;font-size:10px;cursor:pointer}.upload-choice svg{width:17px;height:17px}.visually-hidden-input{position:absolute;width:1px;height:1px;overflow:hidden;clip:rect(0 0 0 0);white-space:nowrap}.text-action{margin-top:10px;padding:4px 0;background:none;color:#587052;font:inherit;font-size:10px;cursor:pointer}.text-action:disabled{opacity:.45;cursor:default}.security-note{display:flex;align-items:center;gap:7px;font-size:9px;line-height:1.45;color:#70806e}.security-note svg{width:15px;height:15px;flex:none}.shape-chip{display:flex;align-items:center;gap:8px;padding:10px;background:#f7f8f5;border:1px solid var(--edit-line);border-radius:6px;font-size:10px}.shape-chip svg{width:16px;height:16px}
.paper-workspace{display:flex;flex-direction:column;min-height:0;min-width:0;background:#eff0ed}.canvas-toolbar{height:48px;flex:none;display:flex;align-items:center;justify-content:space-between;padding:0 clamp(12px,2vw,26px);border-bottom:1px solid #e0e3dd;background:#fff}.canvas-title{display:flex;align-items:center;gap:7px;font-size:8px;letter-spacing:1.2px;color:#70786e}.canvas-live-dot{height:7px;width:7px;border-radius:50%;background:#6c9e5b;box-shadow:0 0 0 3px #6c9e5b1b}.canvas-actions{display:flex;align-items:center;gap:5px;color:#61695f}.canvas-actions button{display:flex;align-items:center;justify-content:center;gap:5px;min-width:27px;height:27px;padding:0 5px;background:transparent;border:0;border-radius:5px;color:inherit;font:inherit;font-size:9px;cursor:pointer}.canvas-actions button:hover,.canvas-actions button[aria-pressed=true]{background:#edf2e9;color:#3d7043}.canvas-actions svg{width:14px;height:14px}.canvas-divider{height:19px;width:1px;background:#e3e6df;margin:0 5px}.canvas-actions #zoom-value{min-width:33px;text-align:center;font-size:9px}.canvas-scroll{flex:1;min-height:0;overflow:auto;padding:30px clamp(18px,3vw,46px);overscroll-behavior:contain;scrollbar-width:thin;scrollbar-color:#c6cbc2 transparent;background-image:radial-gradient(#daddd6 .8px,transparent .8px);background-size:16px 16px}.canvas-scroll.grid-hidden{background-image:none}.paper-stack{width:min(100%,735px);margin:0 auto;display:flex;flex-direction:column;gap:7px;transform-origin:top center;transition:transform .15s}.paper-sheet{position:relative;overflow:hidden;flex:none;background:#fff;border:1px solid #dce0d8;box-shadow:0 2px 8px #20261c08;color:#333c33;font-family:'Inter',Arial,Helvetica,sans-serif}.voucher-check{height:auto;aspect-ratio:2.05/1;padding:4.1% 4.2% 7%}.sheet-header{display:grid;grid-template-columns:1.12fr 1fr auto;align-items:start;gap:6px}.sheet-payer{display:flex;flex-direction:column;align-items:flex-start;gap:3px;min-width:0}.sheet-payer>strong,.stub-payer>strong{font-size:clamp(8px,.83vw,12px);font-weight:600}.print-address{white-space:pre-line;font-size:clamp(6px,.62vw,9px);line-height:1.4;color:#50584f}.payer-logo{display:none;max-width:45px;max-height:25px;object-fit:contain}.payer-logo.is-visible{display:block}.sheet-bank{text-align:center;font-size:clamp(7px,.7vw,10px);font-weight:600;letter-spacing:.45px}.sheet-bank small{font-weight:400;font-size:clamp(5px,.49vw,7px);letter-spacing:.8px;color:#868d84}.print-number{font-size:clamp(6px,.65vw,9px);white-space:nowrap}.sheet-payarea{position:absolute;left:4.3%;right:26%;top:39%;display:flex;align-items:center;gap:9px;height:14%;border-bottom:1px solid #929b90}.sheet-payarea>span,.print-date-label{font-size:clamp(5px,.55vw,8px);line-height:1.2;flex:none}.print-payee{font-size:clamp(7px,.8vw,11px);font-weight:400}.sheet-amount-box{position:absolute;right:4.5%;top:36%;height:17%;width:21%;display:flex;align-items:center;gap:5px;border:1px solid #687367;padding:0 7px}.sheet-amount-box>span{font-size:clamp(10px,1.1vw,15px)}.sheet-amount-box>strong{font-size:clamp(8px,.85vw,12px);font-weight:500}.print-date-label{position:absolute;right:23%;top:24%;color:#686f66}.print-date{position:absolute;right:4.5%;top:24%;font-size:clamp(6px,.63vw,9px);border-bottom:1px solid #abb1a8;padding:0 4px 3px}.sheet-words{position:absolute;left:21%;right:4.5%;top:56%;display:flex;justify-content:space-between;gap:8px;border-bottom:1px solid #aab1a7;padding:0 0 4px;font-size:clamp(5px,.57vw,8px)}.dollar-word{white-space:nowrap}.sheet-memo{position:absolute;left:4.3%;bottom:19%;width:46%;display:flex;align-items:center;gap:8px;border-bottom:1px solid #aab1a7;padding-bottom:4px}.sheet-memo>span{font-size:clamp(5px,.54vw,8px)}.sheet-memo>strong{font-size:clamp(6px,.62vw,9px);font-weight:400}.sheet-signature{position:absolute;right:5%;bottom:14%;width:28%;display:flex;flex-direction:column;align-items:center}.signature-line{width:100%;height:15px;border-bottom:1px solid #757d73}.print-signature{font-family:cursive;font-size:clamp(7px,.8vw,11px);font-weight:400}.sheet-signature>small{font-size:clamp(4px,.5vw,7px);margin-top:2px}.sheet-micr{position:absolute;left:0;right:0;bottom:3.5%;font-family:monospace;text-align:center;letter-spacing:1px;font-size:clamp(6px,.78vw,10px);color:#232923}.sheet-stamp{position:absolute;left:50%;top:50%;transform:translate(-50%,-50%) rotate(-15deg);white-space:nowrap;font-size:clamp(10px,1.55vw,21px);font-weight:600;letter-spacing:2px;color:#10241410;pointer-events:none}.stub-sheet{height:230px;padding:24px 30px}.stub-header{display:flex;justify-content:space-between;padding-bottom:13px;border-bottom:1px solid #c7cdc4;font-size:9px;letter-spacing:.8px}.stub-payer{display:flex;flex-direction:column;gap:3px;margin:14px 0 20px}.stub-recipient{display:flex;align-items:center;gap:13px;font-size:9px}.stub-recipient>span,.stub-values>div>span{font-size:8px;letter-spacing:.7px;color:#6d756b}.stub-recipient>strong{font-size:11px;font-weight:500}.stub-values{display:grid;grid-template-columns:1fr 1fr 1.3fr;gap:20px;margin-top:22px;padding:14px 0;border-top:1px solid #e1e5de;border-bottom:1px solid #e1e5de}.stub-values>div{display:flex;flex-direction:column;gap:7px}.stub-values>div>strong{font-size:10px;font-weight:500}.stub-values i{font-style:normal}.stub-foot{display:flex;justify-content:space-between;margin-top:16px;font-size:8px;color:#747b71}.stub-foot>span:last-child{letter-spacing:.7px}.template-standard .stub-sheet{display:none}.template-wallet{max-width:520px}.template-wallet .voucher-check{aspect-ratio:2.05/1}.template-wallet .stub-sheet{display:none}.template-three-up{gap:12px}.template-three-up .voucher-check{aspect-ratio:2.25/1}.canvas-status{height:38px;flex:none;display:flex;align-items:center;justify-content:space-between;padding:0 18px;background:#fff;border-top:1px solid #e2e5de;color:#737c70;font-size:9px}.canvas-status>span{display:flex;align-items:center;gap:7px}.canvas-status svg{width:13px;height:13px}.canvas-status button{display:flex;align-items:center;gap:6px;border:0;background:none;color:#4b6847;font-size:9px;cursor:pointer}.canvas-status button svg{width:13px;height:13px}.action-rail{min-height:0;overflow:auto;display:flex;flex-direction:column;align-items:stretch;gap:3px;padding:9px 5px;background:#fff;border-left:1px solid var(--edit-line)}.action-rail>button,.action-rail>a{display:flex;min-height:50px;align-items:center;justify-content:center;flex-direction:column;gap:4px;background:transparent;border:0;border-radius:6px;color:#606a60;text-decoration:none;font:inherit;cursor:pointer}.action-rail svg{height:18px;width:18px}.action-rail span{font-size:8px}.action-rail .active-action{background:#eff5ed;color:#3e7b4d}.action-rail .checkout-action{min-height:58px;margin-top:auto;background:#192a20;color:#fff}.rail-separator{height:1px;background:#ebeee8;margin:6px 3px}.mobile-action-dock{display:none}.visually-hidden-input{position:absolute!important}
.review-dialog{width:min(420px,calc(100% - 28px));padding:30px;border:1px solid #e5e9e2;border-radius:18px}.review-dialog::backdrop{background:#14201875;backdrop-filter:blur(3px)}.review-dialog h2{font-size:25px;font-weight:500;margin:18px 0 7px}.review-dialog>p:not(.auth-terms){font-size:12px;line-height:1.6;color:#737b70}.review-close{position:absolute;right:12px;top:12px;width:29px;height:29px;display:grid;place-items:center;border:0;border-radius:50%;background:#f0f2ed}.review-close svg{width:15px;height:15px}.review-actions{display:flex;justify-content:flex-end;gap:8px;margin-top:20px}.editor-primary,.editor-secondary{min-height:36px;padding:0 13px;border-radius:7px;font:inherit;font-size:11px}.editor-primary{background:#1d2a22;color:#fff;border:1px solid #1d2a22}.editor-primary svg,.editor-secondary svg{width:14px;height:14px}.editor-secondary{background:#fff;color:#3f4b3f;border:1px solid #dfe4dc}.auth-terms{text-align:center;font-size:9px;line-height:1.5;color:#888f84;margin:14px 0 0}.editor-page .auth-dialog{z-index:50}.tool-error{padding:9px 10px;margin:8px 0;border-radius:6px;background:#fff1ed;color:#8d4633;font-size:10px;line-height:1.5}.preview-only .tool-rail,.preview-only .tool-settings,.preview-only .action-rail,.preview-only .settings-heading,.preview-only .canvas-toolbar #grid-toggle,.preview-only .canvas-toolbar #undo-action,.preview-only .canvas-toolbar #redo-action,.preview-only .canvas-toolbar .canvas-divider,.preview-only .canvas-toolbar #zoom-out,.preview-only .canvas-toolbar #zoom-in,.preview-only .canvas-toolbar #zoom-value{display:none!important}.preview-only .reference-editor-layout{grid-template-columns:minmax(0,1fr)}.preview-only .paper-workspace{grid-column:1}.preview-only .canvas-scroll{padding:50px 5vw}.preview-only .paper-stack{width:min(100%,900px)}.preview-only #editor-preview-button:after{content:'Close preview'}
@media(max-width:1150px) and (min-width:761px){.reference-editor-layout{grid-template-columns:68px 245px minmax(0,1fr) 58px}.reference-editor-header>.editor-logo{width:145px}.tool-tab{min-height:53px}.tool-tab span{font-size:8px}.canvas-scroll{padding-inline:16px}.stub-sheet{height:205px;padding:20px 24px}.action-rail>button,.action-rail>a{min-height:45px}.editor-back span{display:none}}
@media(max-width:760px){.editor-page{height:auto;min-height:100dvh;overflow:auto;padding-bottom:64px}.reference-editor-header{position:sticky;top:0;height:55px;padding:0 10px;gap:9px}.reference-editor-header>.editor-logo{width:120px}.editor-back{font-size:10px}.editor-back svg{width:14px}.template-select-label{margin-left:auto;gap:0}.template-select-label>span,.save-state,.reset-editor{display:none}.template-select-label select{max-width:138px;height:31px;padding:4px 20px 4px 7px;font-size:9px}.preview-button{min-height:31px;width:33px;padding:0}.preview-button span{display:none}.preview-button svg{width:16px}.reference-editor-layout{height:auto;min-height:0;overflow:visible;display:grid;grid-template-columns:minmax(0,1fr);grid-template-rows:auto auto auto}.tool-rail{grid-row:1;position:sticky;top:55px;z-index:8;overflow-x:auto;overflow-y:hidden;flex-direction:row;align-items:stretch;padding:5px 8px;gap:3px;border-bottom:1px solid #182346;background:var(--edit-rail);scrollbar-width:none}.tool-rail::-webkit-scrollbar{display:none}.tool-rail-label,.rail-guard{display:none}.tool-tab{flex:none;min-width:58px;min-height:47px;gap:3px}.tool-tab svg{width:17px;height:17px}.tool-tab span{font-size:8px}.tool-tab.is-selected:before{left:7px;right:7px;top:auto;bottom:-5px;height:3px;width:auto;border-radius:3px 3px 0 0}.tool-settings{grid-row:2;display:flex;max-height:none;border:0;border-bottom:1px solid #dfe3dc}.settings-heading{height:45px;padding:0 13px}.settings-heading h1{font-size:13px}.settings-close{display:grid}.settings-content{max-height:285px;overflow:auto;padding:10px 12px}.settings-group{padding:10px;margin-bottom:8px}.dynamic-group{display:grid;grid-template-columns:1fr 1fr;column-gap:10px;align-items:center}.dynamic-group h2{grid-column:1/-1}.dynamic-group>label{margin-top:7px!important}.dynamic-group>.setting-input{margin-bottom:5px}.dynamic-group .setting-row{grid-column:1/-1;width:100%}.dynamic-group>label[for="memo"],.dynamic-group>#memo,.dynamic-group>label[for="check-number-input"],.dynamic-group>#check-number-input{grid-column:1/-1}.paper-workspace{grid-row:3;min-height:0}.canvas-toolbar{height:40px;padding:0 10px}.canvas-scroll{height:min(66vw,330px);min-height:215px;flex:none;overflow:auto;padding:17px 11px}.paper-stack{width:min(100%,600px);gap:5px}.voucher-check{min-width:405px;transform-origin:top left}.canvas-scroll .paper-stack{width:100%}.paper-workspace{overflow:hidden}.stub-sheet{height:165px;min-width:405px;padding:16px 20px}.stub-header{font-size:8px;padding-bottom:8px}.stub-payer{margin:9px 0 11px}.stub-values{margin-top:12px;padding:8px 0;gap:10px}.stub-foot{margin-top:9px}.canvas-status{height:auto;min-height:36px;padding:6px 10px;gap:8px}.canvas-status>span{font-size:8px;line-height:1.4}.canvas-status button{font-size:8px;white-space:nowrap}.action-rail{display:none}.mobile-action-dock{position:fixed;z-index:15;left:0;right:0;bottom:0;display:flex;justify-content:space-around;align-items:center;height:61px;padding:5px max(8px,env(safe-area-inset-left)) calc(5px + env(safe-area-inset-bottom));background:#fff;border-top:1px solid #dfe3dc;box-shadow:0 -5px 16px #1b2a1809}.mobile-action-dock button{display:flex;align-items:center;justify-content:center;flex-direction:column;gap:3px;min-width:52px;height:46px;border:0;border-radius:6px;background:transparent;color:#586357;font:inherit}.mobile-action-dock svg{width:17px;height:17px}.mobile-action-dock span{font-size:8px}.mobile-action-dock #mobile-continue{padding:0 15px;flex-direction:row;gap:7px;border-radius:20px;background:#1d2a22;color:#fff}.mobile-action-dock #mobile-continue span{font-size:10px}.tool-settings.settings-collapsed{display:none}.preview-only .canvas-scroll{height:auto;min-height:65dvh}.preview-only .paper-stack{width:100%}.preview-only .voucher-check,.preview-only .stub-sheet{min-width:0}}
@media(max-width:430px){.reference-editor-header>.editor-logo{width:105px}.template-select-label select{max-width:112px}.editor-back span{display:none}.canvas-actions{gap:1px}.canvas-title{font-size:7px}.canvas-actions button{min-width:24px;padding:0 3px}.canvas-scroll .paper-stack{width:100%}.paper-workspace:not(.expanded-preview) .voucher-check{width:560px;transform:scale(calc((100vw - 24px)/560));transform-origin:top left;margin-bottom:calc((100vw - 24px)/560 * -107px)}.paper-workspace:not(.expanded-preview) .stub-sheet{width:560px;transform:scale(calc((100vw - 24px)/560));transform-origin:top left;margin-bottom:calc((100vw - 24px)/560 * -110px)}.paper-workspace .canvas-scroll{overflow-x:hidden}.canvas-scroll .paper-stack{gap:0}.settings-content{max-height:260px}.dynamic-group{grid-template-columns:1fr 1fr}.review-dialog{padding:24px 20px}.review-actions{justify-content:stretch}.review-actions>button{flex:1}}
.setting-field{width:100%}.setting-field label{display:block;font-size:9px;color:#626b61;margin:11px 0 5px}.setting-field label span{margin-left:5px;font-size:7px;letter-spacing:.7px;color:#9aa096}@media(max-width:760px){.dynamic-group>.setting-field{grid-column:1/-1;width:100%}.setting-field label{font-size:11px}}
@media(max-width:430px){.reference-editor-header{gap:7px;padding-inline:8px}.reference-editor-header>.editor-logo{display:none}.template-select-label{margin-left:0;min-width:0;flex:1}.template-select-label select{width:100%;max-width:none}.reference-editor-header .header-cart-btn{flex:none;width:36px}.tool-rail{width:100%;max-width:100vw;min-width:0}}
@media(prefers-reduced-motion:reduce){.paper-stack,.paper-check{transition:none}}
@media print{.editor-page{height:auto;min-height:0;overflow:visible;background:#fff;padding:0}.reference-editor-header,.tool-rail,.tool-settings,.canvas-toolbar,.canvas-status,.action-rail,.mobile-action-dock,.sheet-stamp{display:none!important}.reference-editor-layout{display:block;height:auto;min-height:0;overflow:visible}.paper-workspace,.canvas-scroll{display:block;height:auto;min-height:0;overflow:visible;padding:0;background:#fff}.paper-stack{width:100%;max-width:none;gap:0}.paper-sheet{box-shadow:none;break-inside:avoid}.stub-sheet{height:230px}.template-standard .stub-sheet,.template-wallet .stub-sheet{display:block}}
