#lp251-dialog{--lp-bg:#fff;--lp-ink:#14213a;--lp-line:#dce4f0;color:var(--lp-ink);background:var(--lp-bg);font:14px/1.5 Outfit,system-ui,sans-serif;border:1px solid var(--lp-line);border-radius:22px;padding:0;width:min(1120px,96vw);height:min(840px,94dvh);max-width:96vw;max-height:94dvh;margin:auto;overflow:hidden;box-sizing:border-box;box-shadow:0 24px 90px #07152c55}#lp251-dialog::backdrop{background:#0b193c88;backdrop-filter:blur(5px)}#lp251-dialog[open]{display:flex;flex-direction:column}#lp251-dialog *{box-sizing:border-box}#lp251-dialog header,#lp251-dialog footer{display:flex;align-items:center;justify-content:space-between;gap:12px;padding:14px 20px;flex:none}#lp251-dialog header{border-bottom:1px solid var(--lp-line)}#lp251-dialog h2{font-size:21px;margin:0}#lp251-dialog small{font-size:10px;letter-spacing:.12em;color:#64748b}#lp251-dialog button{border:1px solid var(--lp-line);border-radius:10px;background:var(--lp-bg);color:inherit;font:inherit;padding:9px 13px;cursor:pointer;min-height:40px}#lp251-dialog button:disabled{opacity:.45;cursor:default}#lp251-dialog button:focus-visible,#lp251-dialog input:focus-visible,#lp251-dialog select:focus-visible{outline:3px solid #60a5fa;outline-offset:2px}#lp251-dialog button[aria-pressed=true]{border-color:#2563eb;color:#2563eb;background:#2563eb10}.lp251-body{display:grid;grid-template-columns:minmax(0,1fr) 310px;min-height:0;flex:1}.lp251-preview{display:flex;flex-direction:column;min-height:0;min-width:0;background:#eef3fa;padding:14px;gap:12px}#lp251-view{width:100%;height:100%;min-height:0;object-fit:contain;flex:1;touch-action:none;background:repeating-conic-gradient(#dce4ec 0% 25%,#f2f5f8 0% 50%) 50%/18px 18px;border-radius:12px}.lp251-paint{display:flex;justify-content:center;gap:7px;flex:none}.lp251-paint button{font-size:12px!important;padding:6px 10px!important}.lp251-settings{min-height:0;display:flex;flex-direction:column;border-left:1px solid var(--lp-line)}.lp251-settings nav{display:none}.lp251-scroll{overflow:auto;min-height:0;padding:8px 18px 18px;overscroll-behavior:contain}.lp251-scroll h3{font-size:15px;margin:12px 0}.lp251-scroll section{padding-bottom:15px;border-bottom:1px solid var(--lp-line)}.lp251-scroll label{display:block;font-weight:500;margin:12px 0 5px}.lp251-scroll input:not([type=checkbox]),.lp251-scroll select{display:block;width:100%;font:inherit;font-size:16px;min-width:0;color:inherit;background:var(--lp-bg)}.lp251-scroll input[type=text],#lp251-text,.lp251-scroll select{padding:9px;border:1px solid var(--lp-line);border-radius:9px}.lp251-scroll input[type=range]{accent-color:#2563eb;margin-top:8px}.lp251-scroll input[type=color]{height:35px;padding:2px;border:1px solid var(--lp-line);border-radius:8px}.lp251-scroll input[type=checkbox]{accent-color:#2563eb}.lp251-scroll p{font-size:12px;color:#64748b;margin:9px 0}.lp251-row{display:flex;gap:10px}.lp251-row>*{flex:1;min-width:0}.lp251-upload{border:1px dashed #83a7f5;border-radius:10px;padding:9px;color:#2563eb}.lp251-upload input{font-size:12px!important}.lp251-presets{display:flex;gap:5px;margin-top:14px}.lp251-presets button{flex:1;padding:7px!important;font-size:12px!important}#lp251-dialog footer{border-top:1px solid var(--lp-line)}#lp251-status{margin:0;font-size:12px;max-width:70%;overflow-wrap:anywhere}#lp251-apply{background:#2563eb!important;color:#fff!important;border-color:#2563eb!important;white-space:nowrap}.lp251-entry{display:inline-flex;align-items:center;justify-content:center;gap:7px}.lp251-entry svg{flex:none;width:19px;height:19px}html[data-theme=dark] #lp251-dialog{--lp-bg:#132037;--lp-ink:#edf3ff;--lp-line:#33425a}html[data-theme=dark] .lp251-preview{background:#0b1528}html[data-theme=dark] .lp251-scroll p,html[data-theme=dark] #lp251-dialog small{color:#a6b5cc}@media(max-width:700px){#lp251-dialog{width:calc(100vw - 12px);max-width:calc(100vw - 12px);height:calc(100dvh - 20px);max-height:calc(100dvh - 20px);border-radius:16px}#lp251-dialog header{padding:10px 14px}#lp251-dialog h2{font-size:18px}.lp251-body{display:flex;flex-direction:column}.lp251-preview{flex:1;min-height:140px;padding:8px;gap:7px}.lp251-settings{height:226px;flex:none;border-left:0;border-top:1px solid var(--lp-line)}.lp251-settings nav{display:flex;gap:4px;padding:6px 9px;flex:none}.lp251-settings nav button{flex:1;padding:5px;font-size:12px;min-height:34px}.lp251-scroll{padding:0 14px 12px}.lp251-scroll section{display:none;border:0;padding:0}.lp251-scroll h3{display:none}#lp251-dialog[data-tab=photo] [data-lp-section=photo],#lp251-dialog[data-tab=letter] [data-lp-section=letter],#lp251-dialog[data-tab=position] [data-lp-section=position],#lp251-dialog[data-tab=style] [data-lp-section=style]{display:block}#lp251-dialog footer{padding:9px 12px}#lp251-status{font-size:11px;line-height:1.3;max-width:58%}#lp251-dialog footer button{padding:8px 12px}.lp251-scroll label{margin:7px 0 3px}.lp251-scroll p{margin:5px 0;font-size:11px}}@media(max-height:520px) and (min-width:701px){#lp251-dialog{height:96dvh;max-height:96dvh}.lp251-preview{padding:7px}.lp251-paint button{min-height:30px!important}#lp251-dialog header,#lp251-dialog footer{padding:7px 14px}}
/* Isolate the new modal from the editor's legacy generic dialog/footer rules. */
body #lp251-dialog{padding:0!important}body #lp251-dialog>header,body #lp251-dialog>footer{height:auto!important;position:static!important;transform:none!important;width:auto!important;margin:0!important}body #lp251-dialog>footer{min-height:62px!important}body #lp251-dialog button{font-size:14px!important}.lp251-paint button{font-size:12px!important}@media(max-width:700px){body #lp251-dialog button{font-size:12px!important}body #lp251-dialog>footer{min-height:62px!important}#lp251-dialog .lp251-settings{height:220px}.lp251-entry.pg88-caption-launch{flex:0 0 38px!important;min-width:38px!important;width:38px!important;padding:7px!important}.lp251-entry.pg88-caption-launch span{display:none}}

#lp251-dialog .lp251-preview{position:relative}#lp251-notice{position:absolute;z-index:2;inset:20% 12% auto;padding:16px;border-radius:12px;background:var(--lp-bg);color:var(--lp-ink);box-shadow:0 6px 26px #0002;font-size:14px;text-align:center;pointer-events:none}#lp251-notice[hidden]{display:none}#lp251-dialog[data-error=true] #lp251-notice{border:1px solid #f87171}#lp251-dialog[data-loading=true] #lp251-notice{display:block}#lp251-dialog[data-error=true] #lp251-status{color:#dc2626}html[data-theme=dark] #lp251-dialog[data-error=true] #lp251-status{color:#fca5a5}
