:root{--bg:#0a0a0a;--bg-card:#141414;--bg-raised:#1a1a1a;--border:rgba(255,255,255,0.1);--border-strong:rgba(255,255,255,0.16);--fg:#f5f5f5;--fg-muted:rgba(245,245,245,0.6);--fg-subtle:rgba(245,245,245,0.4);--accent:#7c5cff;--accent-hover:#6b4ce0;--danger:#f87171;--ok:#34d399;color-scheme:dark}*{box-sizing:border-box}body,html{min-height:100%;margin:0}body{background:var(--bg);color:var(--fg);font-family:ui-sans-serif,system-ui,-apple-system,Segoe UI,Roboto,Helvetica,Arial,sans-serif;-webkit-font-smoothing:antialiased}button,input,select,textarea{font:inherit}button{color:inherit}button:focus-visible,input:focus-visible,select:focus-visible,textarea:focus-visible{outline:2px solid var(--accent);outline-offset:2px}.auth-shell,.import-shell{min-height:100dvh;background:var(--bg)}.auth-shell{display:flex;justify-content:center;padding:40px 16px 64px}.auth-page{width:100%;max-width:520px}.brand{display:flex;justify-content:center}.brand img{width:auto;max-width:90%;object-fit:contain}.auth-brand{margin-bottom:24px}.auth-brand img{height:96px}.auth-intro{margin-bottom:28px;text-align:center}.auth-intro h1{margin:0 0 8px;font-size:24px;line-height:1.2;letter-spacing:-.02em}.auth-intro p,.muted{color:var(--fg-muted);font-size:14px;line-height:1.6}.auth-intro p{max-width:440px;margin:0 auto}.auth-card,.import-card{border:1px solid var(--border);border-radius:14px;background:var(--bg-card)}.auth-card{width:100%;padding:22px}.auth-tabs{display:grid;grid-template-columns:repeat(2,minmax(0,1fr));grid-gap:4px;gap:4px;margin-bottom:22px;padding:4px;border:1px solid var(--border);border-radius:10px;background:var(--bg)}.auth-tabs button,.device-switch button{border:0;background:transparent;color:var(--fg-muted);cursor:pointer}.auth-tabs button{min-height:40px;border-radius:7px;padding:9px 10px;font-size:13px;font-weight:600}.auth-tabs button.active,.device-switch button.active{background:var(--bg-raised);color:var(--fg)}.auth-form,.global-controls{display:grid}.auth-form{gap:0}.field{display:block;min-width:0;color:var(--fg);font-size:13px;font-weight:500}.auth-form>.field{margin-bottom:6px}.auth-form>input,.password-control{margin-bottom:16px}.auth-form input,.field input,.field select,.field textarea{width:100%;min-width:0;border:1px solid var(--border);border-radius:9px;background:var(--bg);color:var(--fg);outline:none;transition:border-color .15s,box-shadow .15s}.auth-form input,.field input,.field select{min-height:42px;padding:10px 12px}.auth-form input::placeholder,.field input::placeholder,.field textarea::placeholder{color:var(--fg-subtle)}.auth-form input:focus,.field input:focus,.field select:focus,.field textarea:focus{border-color:var(--accent);box-shadow:0 0 0 3px rgba(124,92,255,.12)}.password-control{position:relative}.password-control input{margin:0;padding-right:76px}.password-control button{position:absolute;inset-block:4px;inset-inline-end:4px;border:0;border-radius:7px;background:transparent;color:var(--accent);cursor:pointer;padding:0 9px;font-size:12px;font-weight:600}.password-control button:hover{background:rgba(124,92,255,.1)}.field-hint{margin:-9px 0 16px;color:var(--fg-subtle);font-size:11.5px}.apply-button,.button-grid button,.delete-button,.element-button-grid button,.full-width-button,.icon-button,.primary-button,.secondary-button,.section-toolbar button,.text-button{cursor:pointer;transition:border-color .15s,background .15s,color .15s,opacity .15s}.primary-button{width:100%;border:0;border-radius:10px;background:var(--accent);color:white;padding:13px 20px;font-size:15px;font-weight:600}.primary-button:hover{background:var(--accent-hover)}.apply-button:disabled,.primary-button:disabled{cursor:not-allowed;opacity:.5}.apply-button{border:1px solid var(--accent);border-radius:8px;background:rgba(124,92,255,.12);color:#c4b8ff;padding:8px 13px;cursor:pointer;font-size:12px;font-weight:600}.apply-button:hover:not(:disabled){background:rgba(124,92,255,.22)}.primary-button.compact{width:auto;padding:9px 14px;font-size:12px}.button-grid button,.element-button-grid button,.full-width-button,.icon-button,.secondary-button,.section-toolbar button{border:1px solid var(--border);border-radius:8px;background:var(--bg);font-weight:500}.secondary-button{padding:8px 12px;font-size:12px}.secondary-button.full{width:100%}.secondary-button.active{border-color:var(--accent);background:rgba(124,92,255,.14);color:#c4b8ff}.text-button{border:0;background:transparent;color:var(--fg-muted);font-size:12px}.text-button:hover{color:var(--fg)}.form-message{margin:0 0 14px;border-radius:9px;padding:10px 12px;font-size:12px;line-height:1.5}.editor-error,.form-message.error{border:1px solid rgba(248,113,113,.35);background:rgba(248,113,113,.08);color:#fca5a5}.form-message.success{border:1px solid rgba(52,211,153,.3);background:rgba(52,211,153,.08);color:#6ee7b7}.auth-footer{margin:24px 0 0;color:var(--fg-subtle);font-size:11.5px;text-align:center}.simple-header{min-height:68px;justify-content:space-between;gap:24px;border-bottom:1px solid var(--border);padding:10px 28px}.account-area,.app-identity,.simple-header{display:flex;align-items:center}.app-identity{min-width:0;gap:14px}.app-identity img{width:auto;height:46px;object-fit:contain}.product-name{border-left:1px solid var(--border-strong);padding-left:14px}.account-area,.product-name{color:var(--fg-muted);font-size:12px}.account-area{gap:14px}.import-card{width:min(680px,calc(100% - 32px));margin:clamp(48px,9vh,96px) auto;padding:clamp(24px,5vw,42px);text-align:center}.eyebrow{margin:0 0 8px;color:var(--accent);font-size:11px;font-weight:700;letter-spacing:.12em;text-transform:uppercase}.import-card h1{max-width:570px;margin:0 auto;font-size:clamp(24px,5vw,34px);line-height:1.18;letter-spacing:-.025em}.import-card>.muted{max-width:520px;margin:12px auto 0}.drop-zone{display:grid;place-items:center;grid-gap:10px;gap:10px;margin-top:28px;border:1.5px dashed var(--border-strong);border-radius:10px;background:var(--bg);padding:34px 22px;transition:border-color .15s,background .15s}.drop-zone.dragging,.drop-zone:hover{border-color:var(--accent);background:rgba(124,92,255,.05)}.drop-zone span,.privacy-note{color:var(--fg-muted);font-size:12px}.upload-icon{display:grid;width:42px;height:42px;place-items:center;border-radius:50%;background:rgba(124,92,255,.12);color:var(--accent);font-size:21px}.privacy-note{margin:18px 0 0}.editor-shell{display:grid;height:100dvh;min-height:640px;grid-template-rows:auto auto minmax(0,1fr);overflow:hidden;background:var(--bg)}.editor-header{display:grid;min-height:62px;grid-template-columns:minmax(180px,1fr) auto auto minmax(300px,1fr);align-items:center;grid-gap:16px;gap:16px;border-bottom:1px solid var(--border);background:var(--bg-card);padding:9px 14px}.device-switch,.document-title,.document-title>div,.header-actions,.history-controls{display:flex;align-items:center}.document-title{min-width:0;gap:10px}.editor-brand-icon{width:34px;height:34px;flex:0 0 34px;border-radius:8px;object-fit:cover}.document-title>div{min-width:0;align-items:flex-start;flex-direction:column}.document-title strong{max-width:280px;overflow:hidden;font-size:12px;text-overflow:ellipsis;white-space:nowrap}.document-title span{color:var(--fg-muted);font-size:10px}.header-actions,.history-controls{gap:6px}.icon-button{width:34px;height:34px;font-size:18px}.icon-button:disabled{cursor:not-allowed;opacity:.3}.device-switch{gap:2px;border:1px solid var(--border);border-radius:9px;background:var(--bg);padding:3px}.device-switch button{border-radius:6px;padding:7px 9px;font-size:10px;font-weight:600}.header-actions{justify-content:flex-end}.editor-error{padding:8px 18px;font-size:12px}.pending-changes{border-bottom:1px solid rgba(124,92,255,.28);background:rgba(124,92,255,.08);padding:8px 18px;color:#c4b8ff;font-size:11px}.editor-workspace{display:grid;grid-row:3;min-height:0;grid-template-columns:minmax(0,1fr) 340px}.preview-stage{display:flex;min-width:0;justify-content:center;overflow:hidden;background-color:#0e0e0e;background-image:radial-gradient(rgba(255,255,255,.075) .7px,transparent 0);background-size:14px 14px;padding:14px}.preview-frame-wrap{position:relative;height:100%;overflow:hidden;border:1px solid var(--border);border-radius:7px;background:white;box-shadow:0 12px 36px rgba(0,0,0,.28);transition:width .2s ease}.preview-frame-wrap iframe{width:100%;height:100%;border:0;background:white}.preview-help{position:absolute;inset-block-start:14px;inset-inline-start:14px;max-width:250px;border:1px solid var(--border-strong);border-radius:8px;background:rgba(10,10,10,.9);padding:8px 10px;color:var(--fg-muted);font-size:11px;line-height:1.45;pointer-events:none;-webkit-backdrop-filter:blur(8px);backdrop-filter:blur(8px)}.properties-panel{overflow-y:auto;border-left:1px solid var(--border);background:var(--bg-card);scrollbar-gutter:stable;overscroll-behavior:contain}.panel-section{border-bottom:1px solid var(--border);padding:18px}.panel-section h2{margin:0 0 14px;color:var(--fg-muted);font-size:10px;font-weight:600;letter-spacing:.11em;text-transform:uppercase}.selection-label{margin:-3px 0 13px;overflow:hidden;color:var(--fg-subtle);font:11px/1.4 ui-monospace,SFMono-Regular,Consolas,monospace;text-overflow:ellipsis;white-space:nowrap}.field textarea{min-height:92px;resize:vertical;padding:10px 12px;line-height:1.45}.field input,.field select{margin-top:6px}.field input[type=color]{min-height:38px;padding:3px;cursor:pointer}.two-columns{display:grid;grid-template-columns:repeat(2,minmax(0,1fr));grid-gap:10px;gap:10px}.panel-section .button-grid,.panel-section .delete-button,.panel-section .field+.field,.panel-section .field+.two-columns,.panel-section .full-width-button,.panel-section .two-columns+.field{margin-top:12px}.color-control{display:flex;align-items:center;gap:8px;margin-top:6px}.color-control input{width:43px;flex:0 0 43px;margin:0}.color-control span{color:var(--fg-muted);font-family:ui-monospace,SFMono-Regular,Consolas,monospace;font-size:10px}.button-grid{display:grid;grid-template-columns:repeat(2,minmax(0,1fr));grid-gap:7px;gap:7px}.element-button-grid{display:grid;grid-template-columns:repeat(3,minmax(0,1fr));grid-gap:7px;gap:7px}.button-grid button,.delete-button,.element-button-grid button,.full-width-button,.section-toolbar button{padding:8px 9px;font-size:10px}.button-grid button:hover,.element-button-grid button:hover,.full-width-button:hover,.icon-button:hover:not(:disabled),.secondary-button:hover,.section-toolbar button:hover{border-color:var(--accent);background:rgba(124,92,255,.08)}.full-width-button,.section-toolbar button{width:100%}.full-width-button.active{border-color:var(--accent);background:rgba(124,92,255,.14);color:#b6a7ff}.field-help{margin:8px 0 0;color:var(--fg-subtle);font-size:10px;line-height:1.45}.delete-button{width:100%;border:1px solid rgba(248,113,113,.24);border-radius:8px;background:rgba(248,113,113,.05);color:#fca5a5}.delete-button:hover{background:rgba(248,113,113,.11)}.section-list{display:grid;grid-gap:2px;gap:2px;margin-top:12px;border-top:1px solid var(--border);padding-top:8px}.sections-card-header{display:flex;align-items:center;justify-content:space-between;gap:12px}.sections-card-header p,.sections-empty{margin:0;color:var(--fg-subtle);font-size:10px}.sections-card-header button{border:1px solid var(--border);border-radius:7px;background:var(--bg);color:var(--fg-muted);padding:6px 9px;cursor:pointer;font-size:10px;font-weight:600}.sections-card-header button:hover{border-color:var(--accent);color:var(--accent)}.sections-empty{padding:8px 4px}.section-row{display:grid;grid-template-columns:minmax(0,1fr) repeat(4,25px);grid-gap:3px;gap:3px}.section-row button{min-width:0;border:0;border-radius:6px;background:transparent;color:var(--fg-muted);cursor:pointer}.section-row button:hover{background:rgba(255,255,255,.055);color:var(--fg)}.section-row button:disabled{cursor:not-allowed;opacity:.25}.section-row button:disabled:hover{background:transparent;color:var(--fg-muted)}.section-row .section-name{overflow:hidden;padding:6px;text-align:left;text-overflow:ellipsis;white-space:nowrap}.section-row .section-name span{color:var(--fg-subtle)}.section-row .danger:hover{color:var(--danger)}.empty-properties{padding:32px 20px;text-align:center}.empty-properties strong{font-size:13px}.empty-properties p{color:var(--fg-muted);font-size:11px;line-height:1.55}.global-controls{gap:12px}@media (max-width:1050px){.editor-header{grid-template-columns:minmax(150px,1fr) auto auto}.header-actions{grid-column:1/-1;justify-content:flex-start}.editor-workspace{grid-template-columns:minmax(0,1fr) 300px}}@media (max-width:760px){.auth-shell{padding-top:28px}.auth-brand img{height:78px}.auth-card{padding:18px}.simple-header{align-items:flex-start;flex-direction:column;padding:12px 16px}.account-area{width:100%;justify-content:space-between}.editor-shell{height:auto;min-height:100dvh;overflow:visible}.editor-header{grid-template-columns:1fr auto}.device-switch{grid-column:1/-1;justify-self:stretch}.device-switch button{flex:1 1}.header-actions{flex-wrap:wrap}.editor-workspace{grid-template-columns:1fr;grid-template-rows:62dvh auto}.properties-panel{max-height:none;border-top:1px solid var(--border);border-left:0}.preview-stage{padding:8px}}@media (max-width:440px){.auth-tabs button{font-size:12px}.app-identity img{height:40px}.product-name{display:none}.account-area>span{max-width:72vw;overflow:hidden;text-overflow:ellipsis;white-space:nowrap}.import-card{width:calc(100% - 24px)}.drop-zone{padding-inline:14px}.document-title strong{max-width:190px}.two-columns{grid-template-columns:1fr}}