.page-studio .studio-shell { padding-top: 32px; }
.page-studio .studio-head { align-items: center; padding-bottom: 22px; }
.page-studio .studio-head h1 { font: 650 28px var(--sans); margin: 0 0 10px; }
.page-studio .studio-head a { color: var(--forest); font-size: 14px; }
.page-studio .studio-split { grid-template-columns: 240px minmax(0, 1fr); gap: 24px; }
.page-studio .studio-form-grid { grid-template-columns: repeat(2, minmax(0, 1fr)); }
.page-studio .studio-form .post-title input { font-size: 24px; min-height: 58px; font-weight: 600; }
.page-studio .studio-toolbar { align-items: center; padding: 10px 0; gap: 10px; }
.page-studio #publish-post { background: var(--forest); color: var(--paper-strong); }
.page-studio button:disabled { opacity: .5; cursor: not-allowed; }
.post-filter { display: grid; gap: 6px; margin: 18px 0 12px; color: var(--muted); font-size: 13px; }
.post-filter select, .post-lifecycle button, .cover-upload button { min-height: 40px; padding: 8px 12px; border: 1px solid var(--line); background: var(--paper-strong); color: var(--ink); border-radius: 4px; }
.page-studio .studio-list strong { overflow-wrap: anywhere; }
.page-studio .studio-status { font-family: var(--sans); font-size: 13px; overflow-wrap: anywhere; }
.page-studio [data-kind=error], #studio-load-error { color: var(--signal); }
.page-studio [data-kind=ok] { color: var(--forest); }
.body-editor { min-width: 0; }
.editor-modes { display: flex; flex-wrap: wrap; gap: 6px; margin-bottom: 10px; }
.editor-modes button { padding: 8px 12px; border: 1px solid var(--line); border-radius: 4px; background: var(--paper-strong); color: var(--ink); cursor: pointer; }
.editor-modes [aria-pressed=true] { background: var(--ink); color: var(--paper); }
#rich-editor { border: 1px solid var(--line); border-radius: 4px; background: var(--paper-strong); }
.rich-toolbar { display: flex; flex-wrap: wrap; align-items: center; gap: 4px; padding: 8px; border-bottom: 1px solid var(--line); }
.rich-toolbar button { display: grid; place-items: center; width: 34px; height: 34px; flex: 0 0 34px; padding: 0; border: 0; border-radius: 3px; color: var(--ink); background: transparent; cursor: pointer; }
.rich-toolbar button:hover, .rich-toolbar [aria-pressed=true] { background: var(--soft-green); color: var(--forest); }
.rich-toolbar select { width: auto; min-height: 34px; max-width: 140px; font-size: 13px; padding: 4px; }
.rich-surface { min-width: 0; max-height: 650px; overflow: auto; }
.rich-surface .tiptap { min-height: 400px; padding: 24px; outline: none; font: 16px/1.85 var(--sans); white-space: pre-wrap; overflow-wrap: anywhere; }
.rich-surface .tiptap:focus { box-shadow: inset 0 0 0 2px var(--forest); }
.rich-surface h1 { font-size: 28px; }
.rich-surface h2 { font-size: 24px; }
.rich-surface h3 { font-size: 20px; }
.rich-surface h1, .rich-surface h2, .rich-surface h3 { font-family: var(--sans); line-height: 1.4; }
.rich-surface p { margin: .75em 0; }
.rich-surface a { color: var(--tech); text-decoration: underline; }
.rich-surface img { display: block; max-width: 100%; height: auto; }
.rich-surface ul, .rich-surface ol { padding-left: 1.5em; }
.rich-surface pre { padding: 16px; white-space: pre-wrap; background: var(--paper); font-family: var(--mono); }
.rich-surface blockquote { margin: 1em 0; padding-left: 18px; border-left: 3px solid var(--forest); }
.rich-surface table { border-collapse: collapse; width: 100%; table-layout: fixed; }
.rich-surface td, .rich-surface th { border: 1px solid var(--line); padding: 8px; position: relative; }
.rich-surface .selectedCell { background: var(--soft-green); }
.rich-surface .ProseMirror-selectednode { outline: 2px solid var(--forest); }
.rich-surface .ProseMirror-gapcursor { display: none; }
.cover-upload { align-self: end; }
.post-lifecycle { display: flex; flex-wrap: wrap; gap: 8px; margin-top: 24px; padding-top: 18px; border-top: 1px solid var(--line); }
.page-studio .editor-preview { margin-top: 24px; }
.page-studio .editor-preview h2 { font-size: 20px; }
.page-studio .revision-list button { display: grid; gap: 6px; padding: 12px; width: 100%; text-align: left; border: 1px solid var(--line); background: var(--paper-strong); color: var(--ink); }
@media (max-width: 900px) {
  .page-studio .studio-split { grid-template-columns: 1fr; }
  .page-studio .studio-list { max-height: 180px; }
  .page-studio .studio-form-grid { grid-template-columns: minmax(0, 1fr); }
  .page-studio .studio-form .post-title input { font-size: 20px; }
  .rich-surface .tiptap { padding: 16px; min-height: 340px; }
}
