.prompt-management-heading { margin-bottom:20px; }
.prompt-management-heading h2 { margin:0 0 8px; font-size:24px; }
.prompt-management-heading p { margin:0; }
.prompt-management-layout { display:grid; grid-template-columns:minmax(200px,270px) minmax(0,1fr); gap:20px; align-items:start; }
.prompt-directory,.prompt-editor { min-width:0; border:1px solid var(--line); border-radius:12px; background:var(--surface); box-shadow:none; }
.prompt-directory { padding:16px; }
.prompt-directory-heading { display:flex; flex-wrap:wrap; align-items:center; justify-content:space-between; gap:8px; padding-bottom:12px; border-bottom:1px solid var(--line); }
.prompt-directory-heading h3 { margin:0; font-size:16px; }
.prompt-directory-items { overflow:auto; max-height:calc(100dvh - 270px); min-height:120px; padding-top:8px; }
.prompt-directory-group { margin:0 0 16px; }
.prompt-directory-group h4 { margin:12px 8px 6px; color:var(--muted); font-size:13px; font-weight:600; }
.prompt-directory-item { display:flex; align-items:start; gap:8px; width:100%; padding:12px 10px; min-height:44px; text-align:left; border:0; border-radius:8px; background:transparent; color:var(--ink); font:inherit; font-size:14px; cursor:pointer; }
.prompt-directory-item > i { flex:0 0 auto; margin-top:3px; }
.prompt-directory-item > span { min-width:0; overflow-wrap:anywhere; }
.prompt-directory-item:hover:not(:disabled),.prompt-directory-item[aria-current="true"] { background:var(--ui-selected,var(--surface-soft)); }
.prompt-directory-item[aria-current="true"] { font-weight:600; }
.prompt-editor { display:flex; flex-direction:column; gap:10px; padding:20px; }
.prompt-editor h3 { margin:0; font-size:19px; }
.prompt-editor p { margin:0; overflow-wrap:anywhere; }
.prompt-editor .field-label { margin:0; }
.prompt-editor-content { width:100%; min-height:180px; height:clamp(180px,calc(100dvh - 470px),560px); padding:14px; resize:vertical; overflow:auto; border:1px solid var(--line-strong); border-radius:8px; background:var(--surface); color:var(--ink); font:14px/1.65 ui-monospace,SFMono-Regular,Consolas,"Microsoft YaHei",monospace; tab-size:2; }
.prompt-editor-content:disabled { background:var(--surface-soft); }
.prompt-variables { display:flex; flex-wrap:wrap; gap:6px; align-items:center; }
.prompt-variable { padding:3px 6px; background:var(--surface-soft); border-radius:4px; color:var(--ink); white-space:pre-wrap; overflow-wrap:anywhere; }
.prompt-editor-actions { display:flex; flex-wrap:wrap; align-items:center; justify-content:flex-end; gap:8px; padding-top:12px; border-top:1px solid var(--line); }
.prompt-editor-actions .button,.prompt-directory-heading .button { display:inline-flex; align-items:center; justify-content:center; gap:6px; min-height:44px; }
.prompt-dirty-status { margin-right:auto; color:var(--muted); font-size:13px; }
.prompt-management-layout :focus-visible { outline:2px solid var(--ui-accent); outline-offset:3px; }
.prompt-template-update-action { display:inline-flex; align-items:center; gap:6px; margin-top:8px; min-height:44px; }
@media (max-width:1100px) { .prompt-management-layout { grid-template-columns:minmax(0,1fr); } .prompt-directory-items { max-height:220px; } .prompt-editor-content { height:320px; } }
@media (max-height:680px) and (min-width:1101px) { .prompt-editor-content { height:180px; } .prompt-directory-items { max-height:300px; } }
