#red-writing-workspace #red-show-note-editor {
  --studio-ink:var(--red-ink,#302c2b);--studio-muted:var(--red-muted,#817873);
  --studio-line:var(--red-line,#50392c1f);--studio-paper:var(--red-paper,#fffdf9);
  --studio-canvas:var(--red-canvas,#f8f5ee);--studio-panel:var(--red-panel,#ece9e1);--studio-red:#ab343e;
  margin:18px 0;color:var(--studio-ink);min-width:0;
}
#red-writing-workspace #red-show-note-editor .rehearsal-notes-heading {flex-wrap:wrap;}
#red-writing-workspace #red-show-note-editor button {min-height:44px;}
#red-writing-workspace #red-show-note-editor .rehearsal-notes-type textarea {box-sizing:border-box;max-width:100%;font-size:18px;}
#red-writing-workspace #red-show-note-editor .rehearsal-notes-viewport {width:100%;box-sizing:border-box;}
#red-writing-workspace .red-show-note-ink {display:block;width:100%;max-width:700px;height:auto;border:1px solid var(--red-line,#50392c1f);border-radius:14px 14px 0 0;margin:12px 0;background:#fffdf9;box-shadow:0 5px 14px #302c2b0b;clip-path:polygon(0 0,100% 0,100% 99.7%,92% 99.9%,81% 99.6%,69% 99.8%,57% 100%,43% 99.7%,30% 99.9%,17% 99.6%,7% 99.9%,0 99.7%);}
#red-writing-workspace .red-show-note-dialog {position:fixed;inset:auto;left:50%;top:calc(var(--show-note-top,0px) + 12px);transform:translateX(-50%);margin:0;width:min(900px,calc(100vw - 32px));height:min(840px,calc(var(--show-note-height,100dvh) - 24px));max-height:calc(var(--show-note-height,100dvh) - 24px);overflow:hidden;animation:none;}
#red-writing-workspace .red-show-note-dialog[open] {display:flex;flex-direction:column;}
#red-writing-workspace .red-show-note-heading {padding:20px 24px 12px;flex:none;}
#red-writing-workspace .red-show-note-heading h2 {margin:0;font-size:25px;}
#red-writing-workspace .red-show-note-body {flex:1;min-height:0;overflow:auto;padding:12px 24px;overscroll-behavior:contain;}
#red-writing-workspace .red-show-note-actions {display:flex;flex-wrap:wrap;justify-content:flex-end;align-items:center;gap:10px;padding:14px 24px 20px;border-top:1px solid var(--studio-line);flex:none;}
#red-writing-workspace .red-show-note-actions button {min-height:44px;}
#red-writing-workspace .red-show-note-message {flex-basis:100%;margin:0;font-size:14px;color:var(--studio-muted);}
#red-writing-workspace .red-show-note-actions .is-primary {background:var(--studio-red);color:white;border-color:var(--studio-red);}
@media(max-width:600px) {
  #red-writing-workspace #red-show-note-editor .rehearsal-notes-heading h3 {flex-basis:100%;}
  #red-writing-workspace #red-show-note-editor .rehearsal-notes-tools {gap:4px;}
  #red-writing-workspace #red-show-note-editor .rehearsal-notes-options-panel {min-width:250px;max-width:calc(100vw - 60px);}
}

#red-writing-workspace .red-show-note-body {display:flex;flex-direction:column;}
#red-writing-workspace .red-show-note-body .rehearsal-notes {display:flex;flex:1;flex-direction:column;min-height:0;}
#red-writing-workspace .red-show-note-dialog .rehearsal-notes-type {display:flex;flex:1;min-height:160px;}
#red-writing-workspace .red-show-note-dialog .rehearsal-notes-type textarea {flex:1;height:100%;max-height:none;min-height:160px;resize:none;box-sizing:border-box;}
#red-writing-workspace .red-show-note-dialog .rehearsal-notes-viewport {flex:1;min-height:220px;height:auto;}

#red-writing-workspace .show-note-context {flex:none;padding:14px 16px;margin-bottom:16px;border:1px solid var(--red-line);border-radius:14px;background:var(--red-panel);color:var(--red-ink);}
#red-writing-workspace .show-note-context label {display:grid;gap:6px;font-size:13px;font-weight:650;min-width:0;}
#red-writing-workspace .show-note-context input,#red-writing-workspace .show-note-context select,#red-writing-workspace .show-note-context textarea {box-sizing:border-box;width:100%;min-height:44px;border:1px solid var(--red-line);border-radius:10px;padding:10px 12px;font:inherit;font-size:16px;color:var(--red-ink);background:var(--red-paper);}
#red-writing-workspace .show-note-context-details {display:grid;grid-template-columns:minmax(0,1fr) minmax(0,2fr);gap:12px;margin-top:12px;}
#red-writing-workspace .show-note-context-details[hidden],#red-writing-workspace .show-note-bit-search[hidden],#red-writing-workspace .show-note-context button[hidden] {display:none;}
#red-writing-workspace .show-note-context-hint,#red-writing-workspace .show-note-context-status {font-size:13px;line-height:1.6;color:var(--red-muted);margin:8px 0 0;}
#red-writing-workspace .show-note-context-status:empty {display:none;}
#red-writing-workspace .show-note-bit-search {display:flex;gap:8px;margin-top:12px;}
#red-writing-workspace .show-note-context button {min-height:44px;padding:8px 12px;border:1px solid var(--red-line);border-radius:10px;background:var(--red-paper);color:var(--red-ink);font:inherit;font-size:14px;}
#red-writing-workspace .red-show-note-writing-surface {display:flex;flex-direction:column;flex:1;min-height:220px;}
#red-writing-workspace .show-note-saved-context {font-size:13px;font-weight:650;color:var(--red-accent);}
#red-writing-workspace .show-note-takeaway {font-weight:650;}
#red-writing-workspace .show-feedback-dialog {box-sizing:border-box;width:min(760px,calc(100vw - 24px));max-height:calc(100dvh - 24px);padding:22px;border:1px solid var(--red-line);border-radius:20px;color:var(--red-ink);background:var(--red-paper);overflow:auto;}
#red-writing-workspace .show-feedback-dialog::backdrop {background:#17191a66;backdrop-filter:blur(8px);}
#red-writing-workspace .show-feedback-dialog>header {display:flex;align-items:center;justify-content:space-between;gap:16px;}
#red-writing-workspace .show-feedback-dialog h2 {margin:0;font-size:25px;}
#red-writing-workspace .show-feedback-dialog button,#red-writing-workspace .show-feedback-dialog summary {min-height:44px;cursor:pointer;}
#red-writing-workspace .show-feedback-dialog button {border:1px solid var(--red-line);border-radius:10px;padding:9px 13px;background:var(--red-panel);color:var(--red-ink);font:inherit;}
#red-writing-workspace .show-feedback-list {display:grid;gap:12px;margin-top:18px;}
#red-writing-workspace .show-feedback-card {padding:16px;border:1px solid var(--red-line);border-radius:14px;background:var(--red-canvas);min-width:0;overflow-wrap:anywhere;}
#red-writing-workspace .show-feedback-origin {font-size:12px;color:var(--red-muted);margin:0 0 8px;}
#red-writing-workspace .show-feedback-summary {font-size:18px;line-height:1.6;margin:0;}
#red-writing-workspace .show-feedback-card details {margin:12px 0;}
#red-writing-workspace .show-feedback-card summary {display:flex;align-items:center;font-size:14px;font-weight:650;color:var(--red-accent);}
#red-writing-workspace .show-feedback-card details p {white-space:pre-wrap;line-height:1.7;}
@media(max-width:600px){#red-writing-workspace .show-note-context-details{grid-template-columns:minmax(0,1fr);}#red-writing-workspace .show-feedback-dialog{padding:18px;}#red-writing-workspace .show-feedback-dialog h2{font-size:23px;}}

/* Keep the notebook footer in rows when the Shows page stacks its own actions. */
#red-writing-workspace .red-show-note-dialog > .red-show-note-actions {flex-direction:row;}
