:root {
  color-scheme: dark;
  --bg: #0a0b0f;
  --panel: #111319;
  --panel-2: #151820;
  --line: #262a34;
  --line-soft: #1c1f27;
  --text: #f4f5f7;
  --muted: #8c929f;
  --orange: #ff6b2c;
  --orange-soft: rgba(255, 107, 44, .13);
  --green: #51d99a;
  --red: #ff6470;
  --blue: #68a8ff;
  --purple: #a28bff;
  --sidebar: 230px;
  font-family: Inter, "PingFang SC", "Microsoft YaHei", system-ui, sans-serif;
}

* { box-sizing: border-box; }
html, body { margin: 0; min-height: 100%; background: var(--bg); color: var(--text); }
button, input, select { font: inherit; }
button { color: inherit; }
.hidden, [hidden] { display: none !important; }

body::before {
  content: "";
  position: fixed;
  inset: 0;
  pointer-events: none;
  opacity: .18;
  background-image: linear-gradient(rgba(255,255,255,.02) 1px, transparent 1px), linear-gradient(90deg, rgba(255,255,255,.02) 1px, transparent 1px);
  background-size: 36px 36px;
}

.login-shell { min-height: 100vh; display: grid; place-items: center; padding: 24px; }
.login-panel {
  position: relative;
  width: min(980px, 100%);
  min-height: 610px;
  overflow: hidden;
  padding: 42px 54px;
  border: 1px solid var(--line);
  border-radius: 22px;
  background: radial-gradient(circle at 72% 48%, rgba(255,107,44,.12), transparent 28%), #0e1015;
  box-shadow: 0 35px 90px rgba(0,0,0,.5);
  display: grid;
  grid-template-columns: 1.15fr .85fr;
  grid-template-rows: auto 1fr auto;
  gap: 30px 80px;
}
.login-panel::after {
  content: "";
  position: absolute;
  width: 430px; height: 430px; border: 1px solid rgba(255,107,44,.2); border-radius: 50%;
  right: 80px; top: 105px; box-shadow: 0 0 0 55px rgba(255,107,44,.025), 0 0 0 110px rgba(255,107,44,.018);
  pointer-events: none;
}
.brand { display: flex; align-items: center; gap: 12px; min-height: 58px; }
.brand-mark {
  width: 38px; height: 38px; display: grid; place-items: center; border-radius: 10px;
  background: var(--orange); color: #111; font-weight: 950; font-style: italic; transform: skew(-6deg);
  box-shadow: 0 7px 24px rgba(255,107,44,.25);
}
.brand strong, .brand small { display: block; }
.brand strong { font-size: 14px; letter-spacing: .14em; }
.brand small { color: var(--muted); font-size: 10px; letter-spacing: .12em; margin-top: 3px; }
.brand-large { grid-column: 1 / -1; }
.brand-large .brand-mark { width: 44px; height: 44px; }
.login-copy { position: relative; z-index: 2; align-self: center; }
.eyebrow { color: var(--muted); font-size: 10px; font-weight: 800; letter-spacing: .2em; }
.eyebrow i { display: inline-block; width: 18px; height: 2px; vertical-align: middle; background: var(--orange); margin-right: 8px; }
.login-copy h1 { font-size: clamp(42px, 6vw, 68px); line-height: 1.03; margin: 22px 0; letter-spacing: -.05em; }
.login-copy h1 em { color: var(--orange); font-style: normal; }
.login-copy p { color: var(--muted); max-width: 420px; line-height: 1.8; font-size: 14px; }
.login-form { position: relative; z-index: 3; align-self: center; padding: 26px; border: 1px solid var(--line); border-radius: 16px; background: rgba(17,19,25,.88); backdrop-filter: blur(14px); }
.login-form label { display: block; color: #b6bac3; font-size: 12px; margin-bottom: 17px; }
.login-form input {
  display: block; width: 100%; margin-top: 8px; padding: 13px 14px; color: var(--text);
  border: 1px solid var(--line); border-radius: 9px; background: #0c0e13; outline: none;
}
.login-form input:focus { border-color: var(--orange); box-shadow: 0 0 0 3px var(--orange-soft); }
.login-form button {
  width: 100%; border: 0; padding: 14px; border-radius: 9px; background: var(--orange); color: #0b0c0e;
  font-weight: 850; cursor: pointer; display: flex; justify-content: center; gap: 10px;
}
.login-form button:hover { filter: brightness(1.08); }
.form-error { min-height: 18px; color: var(--red); font-size: 11px; margin: 12px 0 0; text-align: center; }
.login-orbit { display: none; }
.login-panel footer { grid-column: 1 / -1; color: #555b67; font-size: 9px; letter-spacing: .18em; }

.app-shell { min-height: 100vh; }
.sidebar {
  position: fixed; z-index: 20; inset: 0 auto 0 0; width: var(--sidebar);
  padding: 24px 18px; border-right: 1px solid var(--line-soft); background: #0d0f14;
  display: flex; flex-direction: column;
}
.sidebar .brand { padding: 0 10px 30px; }
.sidebar nav { display: grid; gap: 5px; }
.sidebar nav button {
  border: 0; border-radius: 9px; padding: 12px 13px; background: transparent; color: #8f95a1;
  display: flex; align-items: center; gap: 13px; text-align: left; cursor: pointer; font-size: 13px;
}
.sidebar nav button span { width: 20px; color: #69707c; font-size: 18px; text-align: center; }
.sidebar nav button:hover { color: #fff; background: #151820; }
.sidebar nav button.active { color: #fff; background: var(--orange-soft); box-shadow: inset 3px 0 var(--orange); }
.sidebar nav button.active span { color: var(--orange); }
.nav-group { display: grid; gap: 4px; }
.nav-parent b { margin-left: auto; color: #59606c; font-size: 11px; transition: transform .2s ease; }
.nav-group.open .nav-parent b { transform: rotate(180deg); }
.nav-submenu { display: none; gap: 3px; padding: 2px 0 4px 40px; }
.nav-group.open .nav-submenu { display: grid; }
.sidebar nav .nav-submenu button {
  position: relative; padding: 9px 10px; border-radius: 6px; font-size: 11px;
}
.sidebar nav .nav-submenu button::before {
  content: ""; position: absolute; left: -13px; width: 5px; height: 5px; border-radius: 50%; background: #3f4550;
}
.sidebar nav .nav-submenu button.active { background: transparent; box-shadow: none; color: var(--orange); }
.sidebar nav .nav-submenu button.active::before { background: var(--orange); box-shadow: 0 0 8px var(--orange); }
.sidebar-foot { margin-top: auto; border-top: 1px solid var(--line-soft); padding-top: 18px; }
.mini-status { display: flex; gap: 10px; align-items: center; padding: 10px; }
.mini-status i, .live-pill i, .status-dot, .service-state i { width: 7px; height: 7px; border-radius: 50%; background: var(--green); box-shadow: 0 0 10px var(--green); flex: none; }
.mini-status strong, .mini-status small { display: block; font-size: 10px; }
.mini-status small { color: var(--muted); margin-top: 3px; }
.logout { width: 100%; margin-top: 10px; padding: 9px; border: 1px solid var(--line); border-radius: 8px; color: var(--muted); background: transparent; cursor: pointer; font-size: 11px; }
.logout:hover { color: var(--red); border-color: rgba(255,100,112,.35); }

.workspace { margin-left: var(--sidebar); min-height: 100vh; }
.topbar {
  height: 96px; padding: 20px 34px; border-bottom: 1px solid var(--line-soft); background: rgba(10,11,15,.88);
  backdrop-filter: blur(18px); display: flex; align-items: center; gap: 16px; position: sticky; top: 0; z-index: 10;
}
.topbar h1 { margin: 5px 0 0; font-size: 22px; letter-spacing: -.03em; }
.top-actions { margin-left: auto; display: flex; align-items: center; gap: 13px; }
.live-pill, .demo-badge {
  border: 1px solid rgba(81,217,154,.22); border-radius: 100px; padding: 6px 10px;
  color: var(--green); background: rgba(81,217,154,.07); font-size: 9px; font-weight: 800; letter-spacing: .12em;
}
.demo-badge { border-color: rgba(162,139,255,.25); color: var(--purple); background: rgba(162,139,255,.08); letter-spacing: .05em; }
.live-pill { display: flex; align-items: center; gap: 7px; }
.clock { color: var(--muted); font: 11px ui-monospace, monospace; min-width: 72px; }
.icon-button, .menu-button {
  width: 34px; height: 34px; border: 1px solid var(--line); border-radius: 8px; background: var(--panel); cursor: pointer;
}
.icon-button:hover { border-color: var(--orange); color: var(--orange); }
.icon-button.loading { animation: spin .8s linear infinite; }
.avatar { width: 34px; height: 34px; border-radius: 9px; display: grid; place-items: center; background: #222631; color: #d4d7df; font-size: 10px; font-weight: 800; }
.menu-button { display: none; }
.content { padding: 28px 34px 50px; max-width: 1680px; margin: auto; }

.section-heading { display: flex; align-items: flex-end; justify-content: space-between; gap: 20px; margin-bottom: 18px; }
.section-heading h2 { margin: 0; font-size: 14px; }
.section-heading p { margin: 6px 0 0; color: var(--muted); font-size: 11px; }
.refresh-note { color: #686e7a; font: 10px ui-monospace, monospace; }
.kpi-grid { display: grid; grid-template-columns: repeat(4, 1fr); gap: 12px; }
.kpi-card, .panel, .service-card {
  border: 1px solid var(--line-soft); border-radius: 12px; background: linear-gradient(145deg, var(--panel), #0e1015);
}
.kpi-card { padding: 20px; min-height: 138px; position: relative; overflow: hidden; }
.kpi-card::after { content: ""; position: absolute; right: -35px; bottom: -60px; width: 120px; height: 120px; border-radius: 50%; background: var(--accent, var(--orange)); opacity: .05; filter: blur(2px); }
.kpi-label { display: flex; align-items: center; justify-content: space-between; color: var(--muted); font-size: 10px; letter-spacing: .08em; }
.kpi-icon { width: 30px; height: 30px; display: grid; place-items: center; border-radius: 8px; background: color-mix(in srgb, var(--accent, var(--orange)) 12%, transparent); color: var(--accent, var(--orange)); font-size: 15px; }
.kpi-value { margin: 18px 0 6px; font: 700 29px ui-monospace, "SFMono-Regular", monospace; letter-spacing: -.06em; }
.kpi-meta { color: #686e79; font-size: 10px; }
.kpi-meta strong { color: var(--green); }

.dashboard-grid { display: grid; grid-template-columns: minmax(0, 1.7fr) minmax(280px, .9fr); gap: 12px; margin-top: 12px; }
.panel { padding: 20px; min-width: 0; }
.panel-head { display: flex; justify-content: space-between; align-items: center; gap: 14px; margin-bottom: 18px; }
.panel-head h3 { margin: 0; font-size: 12px; }
.panel-head span { color: var(--muted); font-size: 10px; }
.chart-wrap { height: 218px; position: relative; }
.chart-wrap canvas { width: 100%; height: 100%; }
.chart-legend { display: flex; gap: 17px; color: var(--muted); font-size: 9px; }
.chart-legend i { display: inline-block; width: 7px; height: 7px; border-radius: 50%; margin-right: 5px; }
.service-list { display: grid; gap: 9px; }
.service-card { padding: 14px; display: grid; grid-template-columns: 35px 1fr auto; align-items: center; gap: 12px; background: #0d0f14; }
.service-icon { width: 35px; height: 35px; display: grid; place-items: center; border: 1px solid var(--line); border-radius: 9px; color: var(--orange); }
.service-card h4 { margin: 0; font-size: 11px; }
.service-card p { margin: 4px 0 0; color: var(--muted); font-size: 9px; }
.service-state { text-align: right; }
.service-state span { display: block; color: var(--green); font-size: 9px; font-weight: 800; }
.service-state small { color: var(--muted); font: 9px ui-monospace, monospace; }
.service-card.offline .service-state span { color: var(--red); }
.service-card.offline .service-state i { background: var(--red); box-shadow: 0 0 8px var(--red); }
.service-state i { display: inline-block; margin-right: 5px; width: 6px; height: 6px; }

.toolbar { display: flex; gap: 10px; align-items: center; flex-wrap: wrap; margin-bottom: 14px; }
.action-button {
  border: 1px solid var(--line); border-radius: 8px; padding: 9px 13px; background: #171a21; color: #d8dbe2;
  font-size: 10px; font-weight: 750; cursor: pointer;
}
.action-button:hover { border-color: var(--orange); color: #fff; }
.action-button.primary { width: 100%; padding: 13px 16px; border-color: var(--orange); background: var(--orange); color: #101114; font-size: 11px; }
.action-button.primary.purple { border-color: var(--purple); background: var(--purple); }
.action-button:disabled { opacity: .55; cursor: wait; }
.search-field { position: relative; flex: 1; min-width: 220px; }
.search-field input, .toolbar select {
  height: 38px; border: 1px solid var(--line); border-radius: 8px; background: #0e1015; color: var(--text); outline: none;
}
.search-field input { width: 100%; padding: 0 13px 0 36px; }
.search-field::before { content: "⌕"; position: absolute; left: 13px; top: 8px; color: var(--muted); }
.toolbar select { padding: 0 34px 0 12px; min-width: 130px; }
.toolbar input:focus, .toolbar select:focus { border-color: var(--orange); }
.count-chip { margin-left: auto; color: var(--muted); font-size: 10px; }
.data-panel { border: 1px solid var(--line-soft); border-radius: 12px; background: var(--panel); overflow: hidden; }
.table-scroll { overflow: auto; max-width: 100%; }
table { width: 100%; border-collapse: collapse; font-size: 11px; }
th { position: sticky; top: 0; z-index: 1; padding: 12px 15px; color: #6f7580; background: #0e1015; font-size: 9px; letter-spacing: .09em; text-align: left; white-space: nowrap; border-bottom: 1px solid var(--line); }
td { padding: 13px 15px; border-bottom: 1px solid var(--line-soft); color: #c5c8d0; white-space: nowrap; max-width: 310px; overflow: hidden; text-overflow: ellipsis; }
tbody tr:hover td { background: rgba(255,255,255,.018); color: #fff; }
tbody tr:last-child td { border-bottom: 0; }
.primary-cell { color: #fff; font-weight: 650; }
.secondary { display: block; color: #666d79; font-size: 9px; margin-top: 4px; }
.tag { display: inline-flex; padding: 4px 7px; border-radius: 5px; background: rgba(104,168,255,.09); color: var(--blue); font-size: 9px; }
.tag.green { background: rgba(81,217,154,.09); color: var(--green); }
.tag.orange { background: var(--orange-soft); color: var(--orange); }
.rank-number { width: 26px; height: 26px; display: grid; place-items: center; border-radius: 7px; background: #1b1e25; color: #868c98; font: 800 10px ui-monospace, monospace; }
.rank-number.top { color: #111; background: var(--orange); }
.pagination { padding: 13px 15px; border-top: 1px solid var(--line-soft); display: flex; justify-content: flex-end; align-items: center; gap: 8px; color: var(--muted); font-size: 10px; }
.pagination button { border: 1px solid var(--line); background: #0d0f14; border-radius: 6px; padding: 6px 9px; cursor: pointer; }
.pagination button:disabled { opacity: .35; cursor: default; }

.database-layout { display: grid; grid-template-columns: 250px minmax(0, 1fr); gap: 12px; }
.collection-list { padding: 10px; border: 1px solid var(--line-soft); border-radius: 12px; background: var(--panel); align-self: start; }
.collection-list h3 { margin: 8px 9px 12px; font-size: 11px; }
.collection-button {
  width: 100%; display: flex; align-items: center; justify-content: space-between; gap: 8px; padding: 10px;
  border: 0; border-radius: 7px; background: transparent; color: var(--muted); cursor: pointer; text-align: left; font-size: 10px;
}
.collection-button:hover, .collection-button.active { color: #fff; background: #1a1d25; }
.collection-button.active { box-shadow: inset 2px 0 var(--orange); }
.collection-button span:last-child { color: #5e6470; font: 9px ui-monospace, monospace; }
.json-value { color: var(--purple); font-family: ui-monospace, monospace; cursor: help; }
.empty-state { padding: 80px 20px; text-align: center; color: var(--muted); }
.empty-state strong { display: block; color: #d8dbe2; margin-bottom: 8px; }
.loading-state { display: grid; place-items: center; min-height: 330px; color: var(--muted); font-size: 11px; }
.loading-state i { width: 24px; height: 24px; border: 2px solid var(--line); border-top-color: var(--orange); border-radius: 50%; animation: spin .7s linear infinite; margin-bottom: 12px; }
.server-grid { display: grid; grid-template-columns: repeat(3, 1fr); gap: 12px; }
.server-card { padding: 20px; border: 1px solid var(--line-soft); border-radius: 12px; background: var(--panel); }
.server-card-head { display: flex; align-items: center; justify-content: space-between; }
.server-card h3 { margin: 0; font-size: 14px; }
.server-card .server-id { color: var(--orange); font: 10px ui-monospace, monospace; }
.server-card-body { display: grid; grid-template-columns: 1fr 1fr; gap: 16px; margin-top: 28px; }
.server-card-body span { display: block; color: var(--muted); font-size: 9px; }
.server-card-body strong { display: block; margin-top: 6px; font: 600 15px ui-monospace, monospace; }
.toast {
  position: fixed; z-index: 100; left: 50%; top: 18px; transform: translate(-50%, -80px);
  padding: 10px 16px; border: 1px solid var(--line); border-radius: 8px; background: #191c24; color: #fff; font-size: 11px;
  opacity: 0; transition: .25s ease;
}
.toast.show { opacity: 1; transform: translate(-50%, 0); }
.operation-grid { display: grid; grid-template-columns: minmax(0, 1.18fr) minmax(330px, .82fr); gap: 14px; align-items: start; }
.form-panel { border: 1px solid var(--line-soft); border-radius: 13px; background: var(--panel); padding: 22px; }
.form-panel-wide { max-width: 980px; }
.ops-layout { display: grid; grid-template-columns: minmax(320px, 1fr) minmax(320px, 1fr); gap: 20px; align-items: start; }
.template-grid { display: grid; gap: 12px; }
.template-card { padding: 16px; }
.template-card .form-panel-head { padding-bottom: 12px; }
.template-preview { color: var(--muted); font-size: 10px; line-height: 1.6; white-space: pre-wrap; max-height: 80px; overflow: hidden; }
.template-actions { display: flex; gap: 8px; justify-content: flex-end; }
.form-panel-head { display: flex; gap: 13px; align-items: center; padding-bottom: 18px; border-bottom: 1px solid var(--line-soft); }
.form-panel-head h2 { margin: 0; font-size: 13px; }
.form-panel-head p { margin: 5px 0 0; color: var(--muted); font-size: 9px; }
.form-icon { width: 38px; height: 38px; display: grid; place-items: center; border-radius: 9px; background: var(--orange-soft); color: var(--orange); font-size: 17px; }
.form-icon.purple { background: rgba(162,139,255,.1); color: var(--purple); }
.ops-form { display: grid; gap: 15px; margin-top: 20px; }
.form-row { display: grid; grid-template-columns: 1fr 1fr; gap: 12px; }
.ops-form label { display: block; color: #b8bdc7; font-size: 10px; }
.ops-form label > small { color: #646a75; margin-left: 5px; }
.ops-form input, .ops-form select, .ops-form textarea {
  display: block; width: 100%; margin-top: 7px; padding: 11px 12px; border: 1px solid var(--line);
  border-radius: 8px; background: #0c0e13; color: var(--text); outline: none; font-size: 11px;
}
.ops-form textarea { min-height: 116px; resize: vertical; line-height: 1.6; }
.ops-form input:focus, .ops-form select:focus, .ops-form textarea:focus { border-color: var(--orange); box-shadow: 0 0 0 3px var(--orange-soft); }
.ops-form label > input + small { display: block; margin: 6px 0 0; line-height: 1.5; }
.form-notice { display: flex; gap: 9px; padding: 11px; border: 1px solid rgba(255,107,44,.2); border-radius: 8px; background: rgba(255,107,44,.05); font-size: 9px; }
.form-notice strong { color: var(--orange); flex: none; }
.form-notice span { color: var(--muted); }
.inline-result { min-height: 16px; margin: 0; text-align: center; color: var(--muted); font-size: 10px; }
.inline-result.success { color: var(--green); }
.inline-result.error { color: var(--red); }
.server-preview { position: relative; overflow: hidden; min-height: 125px; padding: 20px; border: 1px solid var(--line); border-radius: 10px; background: radial-gradient(circle at 85% 30%, rgba(162,139,255,.14), transparent 42%), #0d0f14; }
.server-preview::after { content: ""; position: absolute; right: -30px; top: -45px; width: 130px; height: 130px; border: 1px solid rgba(162,139,255,.15); border-radius: 50%; }
.server-preview span, .server-preview strong, .server-preview code { display: block; position: relative; z-index: 1; }
.server-preview span { color: var(--muted); font-size: 9px; letter-spacing: .1em; }
.server-preview strong { margin-top: 18px; font-size: 18px; }
.server-preview code { margin-top: 7px; color: var(--purple); font: 10px ui-monospace, monospace; }
.reward-section { padding: 15px; border: 1px solid var(--line-soft); border-radius: 10px; background: #0d0f14; }
.reward-section-head { display: flex; align-items: center; justify-content: space-between; gap: 15px; margin-bottom: 11px; }
.reward-section-head strong, .reward-section-head span { display: block; }
.reward-section-head strong { font-size: 11px; }
.reward-section-head span { margin-top: 4px; color: var(--muted); font-size: 9px; }
#reward-list { display: grid; gap: 7px; }
.reward-row { display: grid; grid-template-columns: 34px minmax(160px, 1fr) minmax(110px, .45fr) 30px; gap: 8px; align-items: end; padding: 9px; border: 1px solid var(--line-soft); border-radius: 8px; background: #11131a; }
.reward-row label { margin: 0; }
.reward-row input { margin-top: 5px; padding: 9px 10px; }
.reward-index { align-self: center; color: #5f6671; font: 10px ui-monospace, monospace; text-align: center; }
.remove-reward { width: 30px; height: 34px; border: 1px solid var(--line); border-radius: 7px; background: transparent; color: var(--muted); cursor: pointer; }
.remove-reward:hover:not(:disabled) { border-color: rgba(255,100,112,.4); color: var(--red); }
.remove-reward:disabled { opacity: .25; cursor: default; }
.server-operation-grid { grid-template-columns: minmax(420px, 620px) minmax(240px, 340px); }
.operation-help { min-height: 230px; }
.operation-help h3 { margin: 20px 0 8px; font-size: 13px; }
.operation-help p { color: var(--muted); font-size: 10px; line-height: 1.8; }
.operation-help strong, .operation-help > span { display: block; margin-top: 20px; font-size: 9px; color: var(--muted); }
.operation-help > span { margin-top: 5px; color: var(--green); font: 600 16px ui-monospace, monospace; }
.server-manage-list { display: grid; gap: 8px; margin-top: 14px; }
.server-manage-list button { display: flex; align-items: center; justify-content: space-between; gap: 12px; width: 100%; padding: 12px; border: 1px solid var(--line-soft); border-radius: 8px; background: #101218; color: inherit; text-align: left; cursor: pointer; }
.server-manage-list button:hover { border-color: rgba(162,139,255,.45); }
.server-manage-list span, .server-manage-list strong, .server-manage-list small { display: block; }
.server-manage-list small { margin-top: 4px; color: var(--muted); font-size: 9px; }
.server-manage-list b { color: var(--purple); font-size: 9px; white-space: nowrap; }
.announcement-layout { display: grid; grid-template-columns: minmax(380px, .85fr) minmax(420px, 1.15fr); gap: 14px; align-items: start; }
.character-count { float: right; margin-top: 6px !important; color: #5f6671 !important; font: 9px ui-monospace, monospace; }
.format-hint { display: inline-block; margin: 6px 0 0 !important; color: #727986 !important; font: 9px ui-monospace, monospace; }
.announcement-preview { min-height: 120px; padding: 16px; border: 1px solid var(--line); border-radius: 10px; background: radial-gradient(circle at 100% 0, rgba(255,107,44,.1), transparent 42%), #0d0f14; }
.announcement-preview > span { color: var(--orange); font-size: 9px; font-weight: 800; letter-spacing: .08em; }
.announcement-preview p { margin: 18px 0 0; color: #d5d8df; font-size: 11px; line-height: 1.8; white-space: pre-wrap; overflow-wrap: anywhere; }
.announcement-history { padding-bottom: 8px; }
.announcement-list { display: grid; max-height: 620px; overflow: auto; }
.announcement-item { padding: 15px 3px; border-bottom: 1px solid var(--line-soft); }
.announcement-item:last-child { border-bottom: 0; }
.announcement-item > div { display: flex; align-items: center; gap: 10px; }
.announcement-edit { margin-left: auto; padding: 5px 10px; }
.announcement-number { color: var(--orange); font: 800 9px ui-monospace, monospace; }
.announcement-item time { color: #626975; font: 9px ui-monospace, monospace; }
.announcement-item p { margin: 10px 0 0; color: #c3c7cf; font-size: 10px; line-height: 1.75; white-space: pre-wrap; overflow-wrap: anywhere; }
.account-layout { grid-template-columns: minmax(380px, .9fr) minmax(420px, 1.1fr); }
.permission-title { margin-bottom: -5px; }
.permission-grid { display: grid; grid-template-columns: 1fr 1fr; gap: 8px; }
.permission-option { display: flex !important; align-items: center; gap: 10px; padding: 10px; border: 1px solid var(--line-soft); border-radius: 8px; background: #101218; cursor: pointer; }
.permission-option input { width: auto !important; margin: 0 !important; accent-color: var(--orange); }
.permission-option span, .permission-option strong, .permission-option small { display: block; }
.permission-option strong { color: #d5d8df; font-size: 10px; }
.permission-option small { margin-top: 3px; color: #626975; font: 8px ui-monospace, monospace; }
.enabled-option { margin-top: 4px; }
.account-list { display: grid; gap: 9px; margin-top: 14px; }
.account-item { padding: 14px; border: 1px solid var(--line-soft); border-radius: 9px; background: #101218; }
.account-item > div:first-child { display: flex; align-items: center; gap: 9px; }
.account-item p { margin: 10px 0 7px; color: var(--muted); font-size: 10px; line-height: 1.6; }
.account-item small { color: #5f6671; font-size: 9px; }
.account-actions { display: flex; gap: 7px; margin-top: 12px; }
.danger-button { padding: 8px 12px; border: 1px solid rgba(255,100,112,.35); border-radius: 7px; background: transparent; color: var(--red); cursor: pointer; }
@keyframes spin { to { transform: rotate(360deg); } }

@media (max-width: 1060px) {
  .kpi-grid { grid-template-columns: 1fr 1fr; }
  .dashboard-grid { grid-template-columns: 1fr; }
  .server-grid { grid-template-columns: 1fr 1fr; }
  .login-panel { grid-template-columns: 1fr 1fr; gap: 30px; padding: 38px; }
}
@media (max-width: 760px) {
  :root { --sidebar: 220px; }
  .sidebar { transform: translateX(-100%); transition: transform .25s ease; box-shadow: 20px 0 50px rgba(0,0,0,.45); }
  .sidebar.open { transform: translateX(0); }
  .workspace { margin-left: 0; }
  .menu-button { display: block; }
  .topbar { height: 82px; padding: 14px 18px; }
  .topbar .eyebrow, .clock { display: none; }
  .content { padding: 20px 16px 40px; }
  .database-layout { grid-template-columns: 1fr; }
  .operation-grid { grid-template-columns: 1fr; }
  .ops-layout { grid-template-columns: 1fr; }
  .server-operation-grid { grid-template-columns: 1fr; }
  .announcement-layout { grid-template-columns: 1fr; }
  .account-layout { grid-template-columns: 1fr; }
  .collection-list { display: flex; overflow: auto; gap: 5px; }
  .collection-list h3 { display: none; }
  .collection-button { width: auto; min-width: max-content; }
  .login-panel { grid-template-columns: 1fr; min-height: auto; padding: 28px; gap: 20px; }
  .brand-large, .login-panel footer { grid-column: auto; }
  .login-copy h1 { font-size: 43px; }
  .login-panel::after { display: none; }
}
@media (max-width: 520px) {
  .kpi-grid, .server-grid { grid-template-columns: 1fr; }
  .top-actions { gap: 7px; }
  .live-pill, .avatar { display: none; }
  .kpi-card { min-height: 120px; }
  .section-heading { align-items: flex-start; flex-direction: column; }
  .form-row { grid-template-columns: 1fr; }
  .permission-grid { grid-template-columns: 1fr; }
  .reward-section-head { align-items: flex-start; flex-direction: column; }
  .reward-row { grid-template-columns: 28px 1fr 30px; }
  .reward-index { grid-column: 1; grid-row: 1 / 3; }
  .reward-row label:nth-of-type(1) { grid-column: 2; grid-row: 1; }
  .reward-row label:nth-of-type(2) { grid-column: 2; grid-row: 2; }
  .remove-reward { grid-column: 3; grid-row: 1 / 3; align-self: center; }
}
