/* Native PreviewSurface: 16pt frame, 52pt top controls, 12pt content gap. */
#desktop #editor {
  position:fixed;inset:0;margin:auto;width:min(920px,calc(100vw - 64px));
  max-height:calc(100dvh - 40px);overflow:auto;padding:0 16px 16px;
  border:1px solid #ffffffe0;border-radius:22px;background:#eff4fa;color:#26272c;
  box-shadow:0 24px 80px #03050d70,0 4px 14px #03050d35;color-scheme:light;
}
#desktop #editor::backdrop{background:#080b1475;backdrop-filter:blur(5px)}
#editor .native-editor-top{height:51px;position:relative;display:flex;align-items:center;justify-content:center;gap:12px}
#editor #editor-dimensions{position:absolute;left:0;color:#697381;font:500 11px ui-monospace,monospace}
#desktop #editor .editor-zoom{display:flex;align-items:center;gap:5px;white-space:nowrap;color:#3c424c}
#desktop #editor .editor-zoom button,#desktop #editor #close-editor{
  display:grid;place-items:center;padding:0;min-height:28px;height:28px;width:29px;
  border:0;border-radius:7px;background:#dfe4eb;color:#343b46;font:500 19px system-ui;
  box-shadow:none;
}
#desktop #editor .editor-zoom button:hover{background:#d1d8e2}
#desktop #editor #editor-fit{padding:0 10px;width:auto;font-size:12px;font-weight:550}
#editor #editor-zoom-value{min-width:44px;text-align:center;font-size:12px;font-weight:600;font-variant-numeric:tabular-nums}
#desktop #editor #close-editor{position:absolute;right:0;width:28px;background:none;color:#687181}
#desktop #editor #close-editor:hover{background:#dfe4eb;color:#242a34}
#editor #close-editor svg{width:16px;height:16px;fill:none;stroke:currentColor;stroke-width:1.65;stroke-linecap:round}
#desktop #editor .markup-stage{
  display:flex;align-items:stretch;justify-content:flex-start;position:relative;
  min-height:100px;min-width:0;overflow:auto;padding:0;border:0;border-radius:12px;
  background:#fff;box-shadow:none;overscroll-behavior:contain;
}
#editor .markup-plane{position:relative;flex:none;margin:auto}
#desktop #editor #markup{
  display:block;max-width:none;max-height:none;margin:0;aspect-ratio:auto;object-fit:fill;
  border:0;border-radius:0;background:transparent;box-shadow:none;touch-action:none;
}
#editor #markup[data-annotation-mode="view"]{cursor:default}
#editor #markup[data-annotation-mode="note"]{cursor:crosshair}
#editor #markup[data-annotation-mode="picker"]{cursor:crosshair}
#editor #markup:focus-visible{outline:2px solid #7476ff70;outline-offset:-2px}
#editor #editor-decoration{position:absolute;inset:0;display:block;width:100%;height:100%;pointer-events:none;overflow:hidden}
#editor .note-draft{
  position:absolute;z-index:2;transform-origin:0 0;box-sizing:border-box;
  background:rgba(29,32,39,.95);outline:1px solid #7476ffc0;
  pointer-events:none;
}
#editor .note-draft.editing{pointer-events:auto}
#desktop #editor #annotation-text{
  display:block;box-sizing:border-box;width:100%;padding:0;margin:0;min-width:0;min-height:0;
  font-family:system-ui,sans-serif;font-weight:500;color:#fff;caret-color:#fff;
  border:0;border-radius:0;background:transparent;box-shadow:none;outline:none;
  resize:none;overflow:hidden;white-space:pre-wrap;word-break:normal;overflow-wrap:anywhere;
}
#editor #annotation-text::placeholder{color:#a0abbe}
#editor .native-toolbar{
  display:flex;align-items:center;justify-content:center;gap:16px;flex-wrap:wrap;
  position:relative;width:max-content;max-width:100%;margin:12px auto 0;padding:12px;
  border:1px solid #ffffff2b;border-radius:22px;background:#1e1e22;
  box-shadow:0 4px 9px #0e101b29;color:#fff;
}
#editor .native-tool-group{display:flex;align-items:center;gap:4px;position:relative;flex:none}
#editor .native-tool-group+.native-tool-group::before{
  content:"";position:absolute;left:-9px;top:50%;height:20px;width:1px;
  transform:translateY(-50%);background:#ffffff2b;
}
#desktop #editor .native-toolbar button{
  display:inline-grid;place-items:center;flex:none;width:40px;height:40px;min-height:40px;padding:0;
  color:#fff;background:transparent;border:0;border-radius:10px;box-shadow:none;
  font:500 11.5px system-ui;line-height:1;
}
#desktop #editor .native-toolbar button:not(:disabled):hover{background:#ffffff28;color:#fff}
#desktop #editor .native-toolbar button[aria-pressed="true"]{
  border:0;background:rgba(255,255,255,.22);color:#fff;text-shadow:none;
  box-shadow:inset 0 0 0 1px rgba(255,255,255,.24);
}
#desktop #editor .native-toolbar button[aria-pressed="true"]:hover{background:rgba(255,255,255,.3);color:#fff}
#desktop #editor .native-toolbar button.native-done{
  border:0;background:#f2f4fa;color:#11131a;text-shadow:none;box-shadow:none;
}
#desktop #editor .native-toolbar button.native-done:hover{background:#fff;color:#0b0d12}
#desktop #editor .native-toolbar button[data-native-action="close"]:hover{background:#ff453a}
#editor .native-toolbar button:disabled{opacity:.38;cursor:default}
#editor .native-toolbar button[aria-disabled="true"]{opacity:.48}
#editor .native-toolbar button:focus-visible{outline:2px solid #9ea6ff;outline-offset:2px}
#editor .native-toolbar svg{width:18px;height:18px;fill:none;stroke:currentColor;stroke-width:1.7;stroke-linecap:round;stroke-linejoin:round}
#editor .ink-dot{width:13px;height:13px;border-radius:50%;border:1.4px solid #fffffff0;background:var(--ink);box-sizing:border-box}
#editor .native-toolbar .mask-style-group{background:#ffffff0f;border-radius:9px;padding:2px;gap:4px;margin-block:4px}
#desktop #editor .native-toolbar .mask-style{width:48px;height:28px;min-height:28px;border-radius:7px;color:#ffffffa8}
#desktop #editor .native-toolbar .mask-style:last-child{width:62px}
#desktop #editor .native-toolbar .mask-style[aria-pressed="true"]{background:#ffffff33;color:white;font-weight:650}
#desktop #editor .native-toolbar .mask-style:hover{background:#ffffff1a}
#desktop #editor .native-toolbar .mask-style[aria-pressed="true"]:hover{background:#ffffff4d}
#editor #editor-tooltip,#editor #editor-feedback{
  position:absolute;z-index:7;margin:0;padding:6px 10px;max-width:calc(100% - 32px);
  width:max-content;border:1px solid #ffffff2b;border-radius:9px;background:#1e1e22f5;
  color:#fff;font-size:12px;line-height:1.4;box-shadow:0 2px 6px #0e101b26;
  pointer-events:none;white-space:normal;text-align:center;
}
#editor #editor-feedback{left:50%;top:61px;transform:translateX(-50%);font-size:12px;max-width:calc(100% - 52px)}
#editor #stroke-options{
  position:absolute;z-index:8;min-width:132px;padding:5px;border:1px solid #dce1e9;border-radius:10px;
  background:#f8fafd;box-shadow:0 8px 28px #17233040;
}
#desktop #editor #stroke-options button{
  width:100%;display:flex;align-items:center;gap:10px;min-height:28px;padding:4px 8px;border:0;
  border-radius:6px;background:none;color:#292c35;font-size:12px;text-align:left;
}
#desktop #editor #stroke-options button:hover,#desktop #editor #stroke-options button[aria-pressed="true"]{background:#e5e8ee}
#editor #stroke-options i{display:inline-block;flex:none;width:22px;background:currentColor;border-radius:99px}
#editor #watermark-guides{position:absolute;inset:0;pointer-events:none}
#desktop #editor #watermark-guides button{
  position:absolute;pointer-events:auto;width:14px;height:14px;min-height:0;padding:0;border-radius:50%;
  border:2px solid #0e1018;background:#ffffff;transform:translate(-50%,-50%);box-shadow:0 2px 8px rgba(0,0,0,.55);
}
#desktop #editor #watermark-guides button:hover{background:#e2e8f8;transform:translate(-50%,-50%) scale(1.18)}
#editor #watermark-form{
  position:absolute;z-index:8;left:50%;top:65px;transform:translateX(-50%);
  display:flex;align-items:center;flex-wrap:wrap;gap:8px;padding:12px;
  background:#f8fafd;border:1px solid #d8dee9;border-radius:12px;box-shadow:0 6px 24px #17233030;
}
#editor #watermark-form label{width:100%;font-size:12px;font-weight:600}
#desktop #editor #watermark-text{max-width:260px;background:#fff;border:1px solid #cbd3df;color:#252933;border-radius:7px;font-size:13px}
#desktop #editor #watermark-text-done{border:0;background:#1e1e22;color:white;border-radius:7px;white-space:nowrap;font-size:12px}
#editor .editor-inspection{display:flex;gap:10px;align-items:center;justify-content:center;min-width:0;max-width:calc(100% - 80px);font-size:11px;color:#495365}
#editor .editor-inspection:not([hidden])~*{display:none}
#editor.has-inspection :is(.editor-zoom,#editor-dimensions){display:none}
#desktop #editor .editor-inspection button{padding:4px 8px;min-height:26px;border:0;border-radius:6px;background:#dfe4eb;color:#343b46;font-size:11px}
#editor:has(#markup[data-annotation-mode="picker"]) .editor-inspection:not(:empty)::before{content:"";width:18px;height:18px;flex:none;border-radius:5px;border:1px solid #c2c9d5;background:var(--sample)}
@media(max-width:960px){
  #desktop #editor{width:calc(100vw - 32px)}
}
@media(max-width:760px){
  #desktop #editor{width:calc(100vw - 20px);padding-inline:10px;padding-bottom:10px;border-radius:18px}
  #editor .native-toolbar{gap:10px;padding:9px;border-radius:19px}
  #editor .native-tool-group+.native-tool-group::before{left:-6px}
  #editor #editor-dimensions{font-size:9px}
}

/* The feature illustration uses a clean dark macOS editor preview. */
.feature-edit .mini-editor{
  display:flex;flex-direction:column;gap:6px;padding:7px;
  background:#151822;border:1px solid rgba(255,255,255,.12);border-radius:12px;
  box-shadow:0 12px 28px rgba(0,0,0,.45);
}
.feature-edit .mini-document{order:0;border-radius:7px}
.feature-edit .mini-document svg{stroke:#ff4d5a;stroke-width:2.4;filter:drop-shadow(0 1px 3px rgba(0,0,0,.55))}
.feature-edit .mini-document span{
  left:14%;top:66%;background:rgba(16,18,26,.9);color:#f3f5fc;
  border:1px solid rgba(255,255,255,.16);border-radius:6px;padding:3px 7px;
  font-size:clamp(.55rem,.9vw,.68rem);font-weight:580;box-shadow:0 4px 10px rgba(0,0,0,.38);
}
.feature-edit .mini-toolbar{
  order:1;width:max-content;margin:auto;gap:6px;padding:4px 7px;
  background:#1e212d;border:1px solid rgba(255,255,255,.1);color:#d7dceb;border-radius:9px;
}
.feature-edit .mini-toolbar svg{width:17px;height:17px;padding:2px;box-sizing:content-box;stroke-width:1.7}
.feature-edit .mini-toolbar svg:first-child{
  background:#f2f4fa;color:#11131a;border-radius:5px;
}
.feature-edit .mini-toolbar i{margin-left:0;background:#e8362c;border:1px solid white;width:8px;height:8px}
.feature-edit .mini-document span{background:#1d2027f2;color:white;font-weight:500}
.feature-edit .mini-document svg{stroke:#e8362c;filter:none}

