.preview-stage{display:block;position:relative}
.preview-stage>[role="tabpanel"][hidden]{display:none!important}
#pdf-preview-panel{min-height:100%;width:100%}
.empty-preview{margin:60px auto}
#formatted-preview{width:max-content;min-width:100%;padding:0 4px 12px;display:flex;flex-direction:column;align-items:center;gap:24px}
#formatted-preview[hidden]{display:none}
#formatted-preview canvas{display:block;flex:none;background:white;box-shadow:0 3px 16px #0003}
#pdf{height:100%;min-height:700px}
.preview-head>div{gap:8px}
.source-heading{display:flex;align-items:center;font-size:12px}
.preview-tabs{height:100%;display:flex;gap:16px;align-items:center}
.preview-head .preview-tab{width:auto;height:47px;padding:0 4px;border-radius:0;font-weight:700;color:var(--muted);border-bottom:2px solid transparent}
.preview-head .preview-tab.active{color:var(--ink);border-bottom-color:var(--accent)}
.preview-head .preview-tab:focus-visible{outline:2px solid var(--accent);outline-offset:-4px}
#html-preview{width:100%;max-width:794px;min-height:1050px;margin:0 auto;padding:64px 56px;background:white;color:#111;box-shadow:0 3px 16px #0003;font:16px/1.65 "Times New Roman",serif;overflow-wrap:break-word}
#html-preview[hidden],#empty-preview[hidden]{display:none}
#html-preview h1{font-size:28px;font-weight:400;line-height:1.25}
#html-preview h2{font-size:23px;line-height:1.3;margin:1.3em 0 .6em}
#html-preview h3{font-size:19px;margin:1.2em 0 .5em}
#html-preview h4{font-size:17px}
#html-preview img{display:block;max-width:100%;height:auto;margin:20px auto}
#html-preview .html-title{text-align:center;margin-bottom:40px}
#html-preview .html-title p{margin:8px 0}
#html-preview .html-center{text-align:center}
#html-preview .html-paragraph-gap{height:1em}
#html-preview li{padding-left:4px;margin:.4em 0}
#html-preview .katex-display{overflow-x:auto;overflow-y:hidden;padding:6px 0}
#html-preview .unsupported-preview{font:13px/1.5 system-ui;color:var(--muted);border:1px dashed var(--line);padding:14px}
#html-preview .html-page-break{border:0;border-top:1px dashed var(--line);margin:32px 0}
#html-preview code{font-size:.8em;white-space:pre-wrap}
@media(max-width:1000px){#html-preview{padding:36px 28px}}
