.pmht-demo{color:#1f2937;background:#f8fafc;font-family:Inter,ui-sans-serif,system-ui,-apple-system,BlinkMacSystemFont,Segoe UI,sans-serif;line-height:1.5;min-width:320px;min-height:100vh}.pmht-demo,.pmht-demo *{box-sizing:border-box}.pmht-demo button{border:1px solid #cbd5e1;border-radius:8px;background:#fff;color:#0f172a;cursor:pointer;font:inherit;padding:.34rem .56rem;font-size:.82rem;line-height:1.1;transition:background .15s ease,border-color .15s ease,transform .15s ease}.pmht-demo button:hover{background:#f1f5f9;border-color:#94a3b8;transform:translateY(-1px)}.pmht-demo button.danger{border-color:#fecaca;color:#991b1b}.pmht-demo button.danger:hover{background:#fef2f2;border-color:#fca5a5}.pmht-demo code{border-radius:6px;background:#e2e8f0;padding:.1rem .3rem}.pmht-demo.demo-shell{margin:0 auto;max-width:1280px;padding:.75rem 1rem 1rem}.pmht-demo .hero{margin-bottom:.55rem}.pmht-demo .hero h1{margin:0 0 .2rem;color:#0f172a;font-size:1rem;font-weight:700;line-height:1.3}.pmht-demo .hero p{margin:0;max-width:none;color:#475569;font-size:.88rem;line-height:1.35}.pmht-demo .toolbar{display:flex;flex-wrap:wrap;gap:.32rem;margin-bottom:.65rem;padding:.5rem .55rem;border:1px solid #e2e8f0;border-radius:12px;background:#ffffffdb}.pmht-demo .content-grid{display:block}.pmht-demo .panel{min-width:0;border-radius:12px;background:#fff;overflow:hidden}.pmht-demo .panel.editor-panel{overflow:visible}.pmht-demo .editor-panel .tiptap{min-height:380px;padding:.85rem 1rem;outline:none}.pmht-demo .editor-panel p{margin:.35rem 0}.pmht-demo .editor-panel table{margin:.65rem 0;border-collapse:collapse;overflow:hidden}.pmht-demo .editor-panel .html-table-node__wrapper{--pmht-selection-gutter: 1rem;position:relative;width:100%;overflow-x:auto;margin:.65rem 0;padding:var(--pmht-selection-gutter) 1.4rem 1.25rem var(--pmht-selection-gutter)}.pmht-demo .editor-panel .html-table-node__table{background:#fff;margin:0}.pmht-demo .editor-panel .html-table-overlay{position:absolute;top:0;left:0;right:0;bottom:0;z-index:5;pointer-events:none}.pmht-demo .editor-panel .html-table-overlay[hidden],.pmht-demo .editor-panel .html-table-overlay [hidden]{display:none!important}.pmht-demo .editor-panel .html-table-overlay__rows,.pmht-demo .editor-panel .html-table-overlay__columns,.pmht-demo .editor-panel .html-table-overlay__resizers{position:absolute;top:0;right:0;bottom:0;left:0;pointer-events:none}.pmht-demo .editor-panel .html-table-overlay__selection-band{position:absolute;z-index:0;border-radius:8px;background:#bfdbfe33;box-shadow:inset 0 0 0 1px #2563eb29;pointer-events:none}.pmht-demo .editor-panel .html-table-overlay__selection-band--row{transform:translateY(-1px)}.pmht-demo .editor-panel .html-table-overlay__selection-band--column{transform:translate(-1px)}.pmht-demo .editor-panel .html-table-overlay__cell-selection-handle{position:absolute;z-index:3;width:.52rem;height:.52rem;min-width:0;padding:0;border:0;border-radius:999px;background:#2563eb;box-shadow:0 0 0 2px #fff;pointer-events:auto;transform:translateY(-50%)}.pmht-demo .editor-panel .html-table-overlay__cell-selection-handle[aria-expanded=true]{background:#1d4ed8;box-shadow:0 0 0 2px #fff,0 8px 18px #2563eb47}.pmht-demo .editor-panel .html-table-overlay__cell-selection-handle.is-menu-open{background:#1d4ed8}.pmht-demo .editor-panel .html-table-overlay__handle{position:absolute;z-index:1;min-width:0;padding:0;border:0;border-radius:999px;background:transparent;box-shadow:none;opacity:1;pointer-events:auto;transform:translate(-50%,-50%);transition:background .15s ease,box-shadow .15s ease,color .15s ease}.pmht-demo .editor-panel .html-table-overlay__handle:after{content:"•••";position:absolute;top:50%;left:50%;color:#2563ebf5;font-size:.58rem;font-weight:700;letter-spacing:.08rem;line-height:1;transform:translate(-50%,-50%)}.pmht-demo .editor-panel .html-table-overlay__handle:not(.is-hovered):not(.is-selected):not(:hover){background:transparent;box-shadow:none}.pmht-demo .editor-panel .html-table-overlay__handle.is-hovered,.pmht-demo .editor-panel .html-table-overlay__handle.is-selected{background:#2563ebe0;box-shadow:0 4px 12px #2563eb3d}.pmht-demo .editor-panel .html-table-overlay__handle.is-menu-open{background:#1d4ed8;box-shadow:0 6px 16px #2563eb4d}.pmht-demo .editor-panel .html-table-overlay__handle.is-hovered:after,.pmht-demo .editor-panel .html-table-overlay__handle.is-selected:after{color:#fff}.pmht-demo .editor-panel .html-table-overlay__handle.is-menu-open:after{color:#fff}.pmht-demo .editor-panel .html-table-overlay__handle--row{min-height:.95rem}.pmht-demo .editor-panel .html-table-overlay__handle--row:after{writing-mode:vertical-rl;text-orientation:mixed;letter-spacing:0}.pmht-demo .editor-panel .html-table-overlay__handle--column{min-width:1.2rem}.pmht-demo .editor-panel .html-table-overlay__resize-handle{position:absolute;z-index:2;width:12px;min-width:0;padding:0;border:0;background:transparent;cursor:col-resize;pointer-events:auto;transform:translate(-50%)}.pmht-demo .editor-panel .html-table-overlay__resize-handle:before{content:"";position:absolute;top:0;bottom:0;left:50%;width:3px;border-radius:999px;background:linear-gradient(180deg,#2563eb00,#2563eb73,#2563eb00);opacity:0;transform:translate(-50%);transition:opacity .15s ease,background .15s ease}.pmht-demo .editor-panel .html-table-overlay__resize-handle:hover:before,.pmht-demo .editor-panel .html-table-overlay__resize-handle.is-active:before,.pmht-demo .editor-panel .html-table-overlay--resizing .html-table-overlay__resize-handle:before{opacity:1}.pmht-demo .editor-panel .html-table-overlay__resize-handle.is-active:before{background:linear-gradient(180deg,#2563eb0d,#2563ebe6,#2563eb0d)}.pmht-demo .editor-panel .html-table-overlay__extend-button{position:absolute;z-index:2;min-width:0;width:1.2rem;height:1.2rem;padding:0;border:1px solid rgba(37,99,235,.38);border-radius:999px;background:#fffffffa;box-shadow:0 3px 10px #2563eb24;color:#2563eb;font-size:.9rem;font-weight:700;line-height:1;pointer-events:auto;transform:translate(-50%,-50%)}.pmht-demo .editor-panel .html-table-overlay__extend-button:hover{background:#dbeafe;border-color:#2563ebb3;box-shadow:0 5px 14px #2563eb33}.pmht-demo .editor-panel .html-table-overlay__context-trigger{position:absolute;z-index:4;min-width:0;width:1.35rem;height:1.35rem;padding:0;border:1px solid rgba(37,99,235,.3);border-radius:999px;background:#fffffffa;box-shadow:0 6px 16px #0f172a24;color:#2563eb;font-size:.8rem;font-weight:700;line-height:1;pointer-events:auto;transform:translate(-50%,-50%)}.pmht-demo .editor-panel .html-table-overlay__context-trigger[aria-expanded=true]{background:#2563eb;border-color:#1d4ed8;box-shadow:0 8px 18px #2563eb47;color:#fff}.pmht-demo .editor-panel .html-table-overlay__context-menu{position:absolute;z-index:4;display:grid;gap:.45rem;min-width:12rem;max-width:16rem;padding:.55rem;border:1px solid rgba(148,163,184,.28);border-radius:.9rem;background:#fffffffa;box-shadow:0 16px 36px #0f172a2e;overflow-y:auto;pointer-events:auto}.pmht-demo .editor-panel .html-table-overlay__context-menu:before{content:"";position:absolute;width:.72rem;height:.72rem;border-top:1px solid rgba(148,163,184,.28);border-left:1px solid rgba(148,163,184,.28);background:#fffffffa;transform:rotate(45deg)}.pmht-demo .editor-panel .html-table-overlay__context-menu[data-placement=right-start]:before,.pmht-demo .editor-panel .html-table-overlay__context-menu[data-placement=right-center]:before{left:-.38rem}.pmht-demo .editor-panel .html-table-overlay__context-menu[data-placement=right-start]:before{top:.9rem}.pmht-demo .editor-panel .html-table-overlay__context-menu[data-placement=right-center]:before{top:calc(50% - .36rem)}.pmht-demo .editor-panel .html-table-overlay__context-menu[data-placement=left-start]:before,.pmht-demo .editor-panel .html-table-overlay__context-menu[data-placement=left-center]:before{right:-.38rem;transform:rotate(225deg)}.pmht-demo .editor-panel .html-table-overlay__context-menu[data-placement=left-start]:before{top:.9rem}.pmht-demo .editor-panel .html-table-overlay__context-menu[data-placement=left-center]:before{top:calc(50% - .36rem)}.pmht-demo .editor-panel .html-table-overlay__context-menu[data-placement=bottom-center]:before{top:-.38rem;left:calc(50% - .36rem)}.pmht-demo .editor-panel .html-table-overlay__context-menu[data-placement=top-center]:before{bottom:-.38rem;left:calc(50% - .36rem);transform:rotate(225deg)}.pmht-demo .editor-panel .html-table-overlay__context-menu-header{display:grid;gap:.1rem;padding-bottom:.45rem;border-bottom:1px solid rgba(226,232,240,.9)}.pmht-demo .editor-panel .html-table-overlay__context-menu-header-title{color:#0f172a;font-size:.82rem;font-weight:700;line-height:1.2}.pmht-demo .editor-panel .html-table-overlay__context-menu-header-detail{color:#64748b;font-size:.7rem;font-weight:600;line-height:1.2}.pmht-demo .editor-panel .html-table-overlay__context-menu-group{display:grid;gap:.28rem}.pmht-demo .editor-panel .html-table-overlay__context-menu-group:not(:last-child){padding-bottom:.45rem;border-bottom:1px solid rgba(226,232,240,.9)}.pmht-demo .editor-panel .html-table-overlay__context-menu-group-label{color:#64748b;font-size:.66rem;font-weight:700;letter-spacing:.06em;text-transform:uppercase}.pmht-demo .editor-panel .html-table-overlay__context-menu-action{position:relative;width:100%;min-width:0;padding:.42rem .55rem;border:0;border-radius:.6rem;background:transparent;color:#0f172a;font-size:.78rem;font-weight:600;line-height:1.2;text-align:left;pointer-events:auto}.pmht-demo .editor-panel .html-table-overlay__context-menu-action[data-role=menuitemcheckbox],.pmht-demo .editor-panel .html-table-overlay__context-menu-action[data-role=menuitemradio]{padding-left:1.9rem}.pmht-demo .editor-panel .html-table-overlay__context-menu-action[data-role=menuitemcheckbox]:before,.pmht-demo .editor-panel .html-table-overlay__context-menu-action[data-role=menuitemradio]:before{content:"";position:absolute;left:.6rem;top:50%;width:.72rem;height:.72rem;border:1px solid rgba(148,163,184,.85);background:#fff;transform:translateY(-50%)}.pmht-demo .editor-panel .html-table-overlay__context-menu-action[data-role=menuitemcheckbox]:before{border-radius:.22rem}.pmht-demo .editor-panel .html-table-overlay__context-menu-action[data-role=menuitemradio]:before{border-radius:999px}.pmht-demo .editor-panel .html-table-overlay__context-menu-action[data-checked=true]:before{border-color:#2563ebf2;background:#2563eb;box-shadow:inset 0 0 0 2px #fff}.pmht-demo .editor-panel .html-table-overlay__context-menu-action:focus-visible{outline:none;background:#2563eb1f;box-shadow:inset 0 0 0 1px #2563eb59;color:#1d4ed8}.pmht-demo .editor-panel .html-table-overlay__context-menu-action:hover:not(:disabled),.pmht-demo .editor-panel .html-table-overlay__context-menu-action.is-active{background:#2563eb1a;color:#1d4ed8}.pmht-demo .editor-panel .html-table-overlay__context-menu-action.is-primary{background:#2563eb0f}.pmht-demo .editor-panel .html-table-overlay__context-menu-action.is-primary:before{content:"";display:inline-block;width:.42rem;height:.42rem;margin-right:.45rem;border-radius:999px;background:currentColor;vertical-align:middle}.pmht-demo .editor-panel .html-table-overlay__context-menu-action.is-destructive{color:#b91c1c}.pmht-demo .editor-panel .html-table-overlay__context-menu-action.is-destructive:hover:not(:disabled){background:#dc262614;color:#991b1b}.pmht-demo .editor-panel .html-table-overlay__context-menu-action:disabled{color:#94a3b8;cursor:default}.pmht-demo .editor-panel .html-table-overlay--resizing,.pmht-demo .editor-panel .html-table-overlay--resizing *{cursor:col-resize;-webkit-user-select:none;user-select:none}.pmht-demo .editor-panel caption{margin-bottom:.5rem;color:#334155;font-weight:700;text-align:left}.pmht-demo .editor-panel th,.pmht-demo .editor-panel td{position:relative;border:1px solid #cbd5e1;padding:.65rem;vertical-align:top;transition:box-shadow .15s ease,background .15s ease}.pmht-demo .editor-panel th{background:#eff6ff;color:#1e3a8a;font-weight:700}.pmht-demo .editor-panel tfoot td,.pmht-demo .editor-panel tfoot th{background:#f8fafc;font-weight:700}.pmht-demo .editor-panel .html-table-cell--selected{background:linear-gradient(180deg,#bfdbfe61,#dbeafe80);box-shadow:inset 0 0 0 2px #2563eb59}.pmht-demo .output-panel pre{max-height:620px;margin:0;overflow:auto;padding:1.25rem;background:#0f172a;color:#e2e8f0;font-size:.82rem;line-height:1.65;white-space:pre-wrap}.pmht-demo .output-panel code{background:transparent;padding:0}@media(max-width:960px){.pmht-demo.demo-shell{padding:.6rem .7rem .8rem}}
