@font-face{font-family:Allura;src:url("../vendor/fonts/allura-latin-400-normal.woff2") format("woff2");font-display:swap}
@font-face{font-family:Caveat;src:url("../vendor/fonts/caveat-latin-400-normal.woff2") format("woff2");font-display:swap}
@font-face{font-family:"Dancing Script";src:url("../vendor/fonts/dancing-script-latin-400-normal.woff2") format("woff2");font-display:swap}
@font-face{font-family:"Noto Naskh Arabic";src:url("../vendor/fonts/noto-naskh-arabic-arabic-400-normal.woff2") format("woff2");font-display:swap;unicode-range:U+0600-06FF,U+0750-077F,U+0870-089F,U+08A0-08FF,U+FB50-FDFF,U+FE70-FEFF}
:root{color-scheme:light;--paper:#fff;--bg:#f6f9f6;--text:#142822;--muted:#506960;--edge:#d9e5dd;--green:#064e3b;--action:#146648;--tint:#e8f5eb;--accent:#b8efc8;--shadow:0 16px 44px #13352612}
:root[data-theme=dark]{color-scheme:dark;--paper:#172821;--bg:#101e18;--text:#e8f4ec;--muted:#b0c9bb;--edge:#344b40;--action:#096044;--tint:#223c30;--accent:#a8e7bc;--shadow:0 16px 44px #0005}
*{box-sizing:border-box}body{margin:0;background:var(--bg);color:var(--text);font-family:system-ui,-apple-system,"Segoe UI",sans-serif;line-height:1.5}[hidden]{display:none!important}
a{color:inherit}button,input,select,textarea{font:inherit;color:inherit}
button, input:not([type=range]),select,textarea{border:1px solid var(--edge);background:var(--paper);border-radius:8px;padding:.45rem .65rem}
button{cursor:pointer;display:inline-flex;align-items:center;justify-content:center;gap:.5rem;min-height:38px;transition:background .15s,border-color .15s}
button:hover,button[aria-pressed=true]{background:var(--tint);border-color:var(--accent)}button:disabled{opacity:.45;cursor:default}button:focus-visible,a:focus-visible,input:focus-visible,select:focus-visible,textarea:focus-visible{outline:2px solid #35a477;outline-offset:2px}
svg.lucide{width:19px;height:19px;flex:none;vertical-align:middle}.icon{width:40px;padding:.45rem;flex:none}
.primary{background:var(--green);border-color:var(--green);color:#fff;font-weight:650;padding:.65rem 1.1rem}.primary:hover{background:#137154;border-color:#137154}
.site-head{height:72px;background:var(--paper);border-bottom:1px solid var(--edge);display:grid;grid-template-columns:1fr auto 1fr;align-items:center;padding:0 max(4vw,16px);gap:1rem}.site-head>button{justify-self:end}.brand{display:inline-flex;align-items:center;gap:.5rem;width:max-content;color:var(--text);font-size:1.55rem;font-weight:750;letter-spacing:-.07em;text-decoration:none}.brand span{color:#2f9b6d;margin-left:-.45rem}.site-head nav{display:flex;gap:2rem}.site-head nav a,footer>a:last-child{font-weight:550;text-decoration:none;color:var(--muted);font-size:.92rem}.site-head nav a:hover,footer>a:hover{text-decoration:underline}
.hero{padding:64px 18px 65px;text-align:center;border-bottom:1px solid var(--edge);background:radial-gradient(ellipse at 50% 28%,var(--tint),transparent 68%),var(--bg)}
.eyebrow{display:inline-flex;align-items:center;gap:.45rem;margin:0 0 16px;padding:5px 12px;border:1px solid var(--edge);border-radius:20px;background:var(--paper);font-size:.86rem;color:var(--muted);font-weight:650}.eyebrow svg{width:16px;height:16px}
h1{margin:0;font-size:clamp(2.5rem,6vw,5rem);font-weight:760;line-height:1.04;letter-spacing:-.075em}h1 em{color:#22805b;font-family:Georgia,serif;font-weight:500;letter-spacing:-.065em}h2{font-weight:730;letter-spacing:-.04em}.subtitle{color:var(--muted);margin:19px auto 32px;font-size:1.12rem}
.drop{display:flex;flex-direction:column;align-items:center;gap:10px;max-width:670px;margin:auto;padding:29px 16px;border:1.5px dashed #78ae90;border-radius:19px;background:var(--paper);box-shadow:var(--shadow);color:var(--muted)}.drop.dragging{background:var(--tint);outline:3px solid var(--accent)}.drop strong{font-size:1.2rem;color:var(--text)}.drop .primary{margin:5px 0}.upload-icon{background:var(--tint);color:#288160;padding:12px;border-radius:14px}.upload-icon svg{width:28px;height:28px}
.landing-section{max-width:1080px;margin:auto;padding:50px 20px}.tool-grid,.instructions ol{display:grid;grid-template-columns:repeat(4,minmax(0,1fr));gap:14px;margin:19px 0 0}.tool-grid button,.instructions li{background:var(--paper);border:1px solid var(--edge);border-radius:14px;padding:19px;text-align:left;display:flex;align-items:flex-start;flex-direction:column;gap:.5rem}.tool-grid button:hover{border-color:#5caa80}.tool-grid button svg{color:#288160}.tool-grid button span,.instructions li{color:var(--muted)}.instructions ol{grid-template-columns:repeat(3,1fr);padding:0}.instructions strong{color:var(--text)}.faq details{border-bottom:1px solid var(--edge);padding:14px 0}.faq summary{cursor:pointer;font-weight:650}.faq details p{margin:.7rem 0 0;color:var(--muted)}
footer{display:flex;align-items:center;justify-content:space-between;gap:1rem;flex-wrap:wrap;background:var(--paper);border-top:1px solid var(--edge);padding:22px max(4vw,16px);color:var(--muted)}
body.editing{height:100dvh;display:flex;flex-direction:column;overflow:hidden}body.editing .site-head{height:55px;flex:none}.editing .site-head{grid-template-columns:1fr auto}
#editor{flex:1;min-height:0;display:flex;flex-direction:column;background:var(--bg);color:var(--text)}#editor:fullscreen{height:100%;width:100%}
.document-bar,.toolbar,.view-bar{display:flex;align-items:center;gap:6px;background:var(--paper);padding:7px 12px;border-bottom:1px solid var(--edge)}.document-bar input{width:min(320px,32vw);min-width:0;font-weight:650}.document-actions{display:flex;align-items:center;gap:5px;margin-left:auto}.toolbar{overflow:auto;flex:none}.toolbar button{flex:none;border-color:transparent;font-size:.86rem;white-space:nowrap}.toolbar button[aria-pressed=true]{border-color:#78ae90;color:var(--text)}.toolbar svg{width:16px;height:16px}
.editor-grid{display:flex;flex:1;min-height:0;position:relative}.side{width:168px;flex:none;background:var(--paper);padding:14px;overflow:auto;border-right:1px solid var(--edge)}.side h2{font-size:1rem;margin:0 0 13px}.side p{font-size:.9rem;color:var(--muted)}#properties{width:241px;border-right:none;border-left:1px solid var(--edge)}#page-list{display:grid;gap:10px}.thumbnail{flex-direction:column;width:100%;padding:.5rem;gap:.25rem;font-size:.85rem}.thumbnail canvas{object-fit:contain;max-width:100%;background:white;border:1px solid var(--edge)}.thumbnail[aria-current=true]{background:var(--tint);border-color:#5caa80}
.center{display:flex;flex-direction:column;flex:1;min-width:0}.view-bar{position:relative;z-index:3;justify-content:center;flex:none;border-bottom:none;border-top:1px solid var(--edge)}#page-count{white-space:nowrap}
#workspace{overflow:auto;flex:1;min-height:0;padding:20px;background:var(--tint);overscroll-behavior:contain}
#workspace.locked #overlay{pointer-events:none}
#replacement{position:absolute;z-index:1;transform-origin:top left;box-sizing:content-box;min-width:1em;min-height:1em;max-width:none;resize:none;overflow:hidden;margin:0;padding:0;border:0;border-radius:0;background:white;color:#172a22;outline:2px solid #258760;outline-offset:0;line-height:1.16;white-space:pre}
#page-sheet{position:relative;margin:0 auto;background:white;box-shadow:0 4px 18px #0002;width:max-content;line-height:0}#page-sheet canvas{display:block}#overlay{position:absolute;inset:0}
label{display:flex;flex-direction:column;gap:.25rem;margin-bottom:.6rem;font-size:.88rem;font-weight:550}label input,label select,label textarea{min-width:0;width:100%}label input[type=color]{height:35px;padding:.2rem}.property-pair{display:grid;grid-template-columns:1fr 1fr;gap:8px}.property-row{display:flex;gap:5px;margin-bottom:.55rem}.property-row button{min-width:37px}.danger{color:#ba3939}
dialog{width:min(520px,calc(100vw - 24px));max-height:calc(100dvh - 24px);overflow:auto;border:1px solid var(--edge);border-radius:16px;padding:20px;color:var(--text);background:var(--paper);box-shadow:var(--shadow)}dialog::backdrop{background:#13282188}dialog p{color:var(--muted)}.dialog-head,.dialog-actions{display:flex;align-items:center;justify-content:space-between;gap:.75rem}.dialog-head h2{font-size:1.35rem;margin:0}.dialog-actions{justify-content:flex-end}.signature-tabs{display:flex;gap:6px;margin:12px 0}.signature-tabs button{flex:1}.check-label{flex-direction:row;align-items:center}.check-label input{width:auto}#signature-dialog canvas{display:block;width:100%;height:140px;border:1px solid var(--edge);border-radius:10px;background:#fff;margin-bottom:.6rem;object-fit:contain}#signature-canvas{touch-action:none}
.notice,#toast{position:fixed;bottom:16px;right:16px;z-index:10;background:var(--paper);color:var(--text);border:1px solid var(--edge);box-shadow:var(--shadow);border-radius:10px;padding:12px 16px;max-width:calc(100vw - 32px)}.notice{display:flex;align-items:center;gap:.5rem}.notice progress{width:70px}#toast{pointer-events:none}.notice:not([hidden])+#toast{bottom:74px}
@media(max-width:850px){.editor-grid .side{position:absolute;inset:0 auto 0 0;z-index:2;box-shadow:var(--shadow)}.editor-grid #properties{left:auto;right:0}.editor-grid .side:not(.expanded){display:none}.tool-grid{grid-template-columns:repeat(2,1fr)}}
@media(min-width:851px){.editor-grid .side.collapsed{display:none}}
@media(max-width:580px){.site-head{grid-template-columns:1fr auto}.site-head nav,.desktop-break{display:none}.hero{padding-top:45px;padding-bottom:45px}.landing-section{padding:34px 14px}.instructions ol{grid-template-columns:1fr}.toolbar{order:2;border-top:1px solid var(--edge)}.document-bar{padding:6px;gap:4px;flex-wrap:wrap}.document-bar .icon{width:33px}.document-bar .primary{padding:.45rem .55rem;font-size:.83rem}.document-actions{gap:3px}#workspace{padding:10px}.view-bar{padding:5px;gap:4px}.view-bar .icon{width:36px}}
@media(prefers-reduced-motion:reduce){*{transition:none!important}}
