* { box-sizing: border-box; }
body {
    margin: 0;
    background: #0c0d11;
    color: #f4f5f8;
    font: 14px/1.5 "Microsoft YaHei UI", "Segoe UI", sans-serif;
}
a { color: #c4b5fd; }
.gate { min-height: 100vh; display: grid; place-items: center; }
.top {
    display: flex;
    gap: 16px;
    align-items: center;
    padding: 16px 24px;
    background: #16181f;
    border-bottom: 1px solid #2c303c;
}
.top span { color: #8b93a7; margin-right: auto; }
.shell { height: 100vh; overflow: hidden; }
.workspace { display: flex; height: calc(100vh - 53px); }
.tree {
    width: 232px;
    flex: none;
    background: #12141a;
    border-right: 1px solid #2c303c;
    padding: 16px 12px;
    overflow: auto;
}
.tree-root {
    margin: 14px 8px 6px;
    color: #8b93a7;
    font-size: 12px;
}
.tree ul { list-style: none; margin: 0; padding: 0 0 0 12px; border-left: 1px solid #2c303c; }
.tree li a {
    display: flex;
    justify-content: space-between;
    margin: 2px 0;
    padding: 7px 10px;
    border-radius: 8px;
    color: #d5d8e2;
    text-decoration: none;
}
.tree li.current a, .tree li a:hover { background: #6d5efc; color: white; }
.tree em { color: inherit; font-style: normal; opacity: 0.75; }
.list-pane { flex: 1; min-width: 0; padding: 18px 22px; overflow: auto; }
.list-bar { display: flex; align-items: center; justify-content: space-between; margin-bottom: 12px; }
.table-wrap {
    background: #16181f;
    border: 1px solid #2c303c;
    border-radius: 14px;
    overflow: auto;
}
.card {
    width: min(460px, calc(100% - 32px));
    background: #16181f;
    border: 1px solid #2c303c;
    border-radius: 14px;
    padding: 22px;
}
.modal {
    display: none;
    position: fixed;
    inset: 0;
    background: rgba(6, 7, 10, 0.72);
    place-items: center;
    z-index: 20;
}
.modal.open { display: grid; }
.dialog {
    width: min(520px, calc(100% - 32px));
    max-height: calc(100vh - 48px);
    overflow: auto;
    background: #16181f;
    border: 1px solid #3a3f50;
    border-radius: 14px;
    padding: 20px;
}
.dialog-head { display: flex; align-items: center; justify-content: space-between; }
.button.ghost { background: #2a2c38; color: #d5d8e2; }
.empty { color: #8b93a7; text-align: center; }
h1, h2 { margin: 0 0 8px; font-size: 20px; }
.muted { color: #8b93a7; }
.warn, .ok { border-radius: 8px; padding: 8px 12px; }
.warn { background: #1c160f; color: #f3d7a1; }
.ok { background: #10241a; color: #6ee7b7; }
label { display: block; margin: 12px 0; color: #c5cad6; }
input, select {
    display: block;
    width: 100%;
    margin-top: 6px;
    background: #0e1016;
    color: #f4f5f8;
    border: 1px solid #2c3140;
    border-radius: 8px;
    padding: 8px 10px;
}
button, .button {
    background: #6d5efc;
    color: white;
    border: 0;
    border-radius: 8px;
    padding: 8px 14px;
    text-decoration: none;
    cursor: pointer;
}
button.danger { background: transparent; color: #fda4af; border: 1px solid #6b2433; }
.row, .actions { display: flex; gap: 8px; align-items: center; flex-wrap: wrap; }
table { width: 100%; border-collapse: collapse; }
th, td { text-align: left; padding: 10px 8px; border-bottom: 1px solid #2c303c; vertical-align: middle; }
th { color: #8b93a7; font-weight: 600; }
td form { display: inline; }
