.tree-layout {display:grid;grid-template-columns:minmax(260px,.9fr) minmax(300px,1.2fr);gap:28px;margin-top:28px;align-items:start}
.tree-outline,.tree-editor {border:1px solid var(--line,#d9d2c7);border-radius:18px;padding:22px;background:var(--surface,#fffdf9);min-width:0}
.tree-outline {position:sticky;top:90px;max-height:calc(100vh - 120px);overflow:auto}
.tree-outline-list,.tree-outline-list ul {list-style:none;padding-inline-start:18px;margin:0}
.tree-outline-list {padding-inline-start:0}
.tree-outline-list ul {border-inline-start:1px solid var(--line,#d9d2c7);margin-inline-start:18px}
.tree-branch {display:flex;align-items:center;flex-wrap:wrap;gap:6px;padding:7px 6px;margin-block:6px;border:1px solid transparent;border-radius:10px}
.tree-branch.is-selected {border-color:var(--accent,#a66e43);background:color-mix(in srgb,#ac784e 10%,transparent)}
.tree-branch.is-archived {opacity:.55}
.tree-branch .btn:first-child {font-weight:600;text-align:start;flex:1}
.tree-kind {font-size:.7rem;color:var(--muted,#746a5b)}
.tree-branch .tree-kind {width:100%;padding-inline-start:12px}
.tree-field {display:flex;flex-direction:column;gap:8px;margin-block:16px;font-size:.86rem}
.tree-field input,.tree-field select,.tree-field textarea {font:inherit;color:inherit;background:var(--bg,#faf7f1);border:1px solid var(--line,#d9d2c7);border-radius:9px;padding:12px;width:100%;min-width:0;box-sizing:border-box}
.tree-field textarea {resize:vertical}
.tree-form-grid {display:grid;grid-template-columns:repeat(2,minmax(0,1fr));gap:0 16px}
.tree-check {display:flex;align-items:center;gap:10px;line-height:1.6;margin-block:20px}
.tree-check input {width:20px;height:20px}
.tree-form-actions,.tree-editor-head {display:flex;gap:12px;justify-content:space-between;align-items:center;flex-wrap:wrap}
.tree-form-actions {justify-content:flex-start;margin-block:20px}
.tree-history {border-block-start:1px solid var(--line,#d9d2c7);padding-block:18px;margin-block:20px}
.tree-history summary {cursor:pointer;min-height:44px;line-height:44px}
.tree-history-event {padding:14px 0;border-block-end:1px solid var(--line,#d9d2c7);font-size:.85rem}
.tree-history pre {overflow:auto;font-size:.75rem;max-height:350px}
.tree-save-status {overflow-wrap:anywhere}
.tree-workspace input:focus-visible,.tree-workspace textarea:focus-visible,.tree-workspace select:focus-visible {outline:3px solid var(--accent,#a66e43);outline-offset:3px}
@media(max-width:1000px) {.tree-layout {grid-template-columns:1fr}.tree-outline {position:static;max-height:480px}}
@media(max-width:540px) {.tree-form-grid {grid-template-columns:1fr}.tree-outline,.tree-editor {padding:16px}.tree-outline-list ul {padding-inline-start:12px;margin-inline-start:10px}}
