:root {
  color-scheme: dark;
  --bg: #050b14;
  --surface: #0a1422;
  --surface-2: #101d2e;
  --border: rgba(148, 180, 214, 0.14);
  --text: #f4f8fc;
  --muted: #91a3b8;
  --blue: #2d8cff;
  --blue-2: #62b4ff;
  --green: #31d47d;
  --amber: #ffb84d;
  --red: #ff6875;
  --safe-bottom: env(safe-area-inset-bottom, 0px);
}

* { box-sizing: border-box; }
html { min-height: 100%; background: var(--bg); }
body {
  margin: 0;
  min-height: 100vh;
  min-height: 100dvh;
  color: var(--text);
  background:
    radial-gradient(circle at 85% 5%, rgba(45, 140, 255, 0.16), transparent 27rem),
    linear-gradient(180deg, #07111f 0%, var(--bg) 52%);
  font-family: -apple-system, BlinkMacSystemFont, "SF Pro Display", "Segoe UI", sans-serif;
  -webkit-font-smoothing: antialiased;
}
button, input, select { font: inherit; }
button, a { -webkit-tap-highlight-color: transparent; }
.hidden { display: none !important; }
.app-shell { width: 100%; min-height: 100dvh; margin: 0 auto; }

.topbar {
  position: sticky;
  top: 0;
  z-index: 10;
  display: flex;
  align-items: center;
  gap: 0.75rem;
  padding: calc(env(safe-area-inset-top, 0px) + 0.75rem) 1.1rem 0.75rem;
  background: rgba(5, 11, 20, 0.78);
  border-bottom: 1px solid var(--border);
  backdrop-filter: blur(24px) saturate(145%);
}
.brand-logo { width: 10rem; height: 3.5rem; padding: 0.25rem 0.45rem; border-radius: 0.72rem; object-fit: contain; object-position: left center; background: rgba(255,255,255,0.96); }
.brand-copy { display: flex; flex: 1; flex-direction: column; min-width: 0; }
.brand-copy strong { font-size: 1rem; line-height: 1.2; }
.brand-copy span { color: var(--muted); font-size: 0.75rem; line-height: 1.3; }
.icon-button, .refresh-button {
  display: grid;
  place-items: center;
  width: 2.75rem;
  height: 2.75rem;
  border: 1px solid var(--border);
  border-radius: 50%;
  color: var(--muted);
  background: rgba(255,255,255,0.035);
}
.icon-button svg, .refresh-button svg { width: 1.25rem; fill: none; stroke: currentColor; stroke-width: 1.8; stroke-linecap: round; stroke-linejoin: round; }
.role-badge { padding: 0.38rem 0.62rem; border: 1px solid rgba(98,180,255,0.24); border-radius: 999px; color: var(--blue-2); background: rgba(45,140,255,0.1); font-size: 0.7rem; font-weight: 750; }

main { padding: 1.25rem 1rem calc(2rem + var(--safe-bottom)); }
.login-view { min-height: calc(100dvh - 7rem); display: flex; flex-direction: column; justify-content: center; align-items: flex-start; padding: 1.5rem 0.25rem 3rem; }
.login-brand-logo { width: min(34rem, 92vw); height: auto; margin-bottom: 2rem; padding: 1rem; border-radius: 1.1rem; background: rgba(255,255,255,0.96); box-shadow: 0 1rem 3rem rgba(0,0,0,0.18); }
.login-orbit {
  position: relative;
  width: 5.25rem;
  height: 5.25rem;
  margin-bottom: 1.75rem;
  border: 1px solid rgba(98,180,255,0.3);
  border-radius: 50%;
  box-shadow: inset 0 0 2rem rgba(45,140,255,0.14), 0 0 3.5rem rgba(45,140,255,0.12);
}
.login-orbit::before, .login-orbit::after { content: ""; position: absolute; border-radius: 50%; }
.login-orbit::before { inset: 0.8rem; border: 1px dashed rgba(98,180,255,0.45); }
.login-orbit::after { inset: 1.7rem; background: linear-gradient(145deg, var(--blue-2), var(--blue)); box-shadow: 0 0 1.4rem rgba(45,140,255,0.45); }
.login-orbit span { position: absolute; z-index: 2; width: 0.55rem; height: 0.55rem; top: 0.4rem; left: 2.35rem; border-radius: 50%; background: white; box-shadow: 0 0 0.8rem white; }
.eyebrow { margin: 0 0 0.35rem; color: var(--blue-2); font-size: 0.75rem; font-weight: 750; letter-spacing: 0.12em; text-transform: uppercase; }
h1 { margin: 0; font-size: clamp(2rem, 9vw, 3.4rem); line-height: 1.04; letter-spacing: -0.045em; }
.login-text { max-width: 34rem; margin: 1.1rem 0 1.8rem; color: var(--muted); font-size: 1.02rem; line-height: 1.55; }
.primary-button {
  display: inline-flex;
  justify-content: center;
  width: 100%;
  padding: 1rem 1.2rem;
  border-radius: 1rem;
  color: white;
  background: linear-gradient(135deg, var(--blue), #1669dc);
  box-shadow: 0 0.9rem 2rem rgba(45, 140, 255, 0.23);
  font-weight: 750;
  text-decoration: none;
}
.privacy-note { align-self: center; margin: 0.9rem 0 0; color: #65788e; font-size: 0.78rem; }

.dashboard { padding-top: 0.45rem; }
.workspace { display: grid; gap: 1rem; }
.fleet-panel { min-width: 0; }
.directory-panel { display: none; }
.desktop-detail-panel { display: none; }
.directory-title { display: flex; align-items: center; justify-content: space-between; margin-bottom: 0.75rem; color: var(--muted); font-size: 0.78rem; font-weight: 750; text-transform: uppercase; letter-spacing: 0.07em; }
.directory-title strong { color: var(--blue-2); }
#directoryTree { display: grid; gap: 0.35rem; }
#directoryTree button, #directoryTree summary { width: 100%; padding: 0.62rem 0.72rem; border: 0; border-radius: 0.7rem; color: var(--muted); background: transparent; text-align: left; cursor: pointer; }
#directoryTree button:hover, #directoryTree summary:hover, #directoryTree .active { color: white; background: rgba(45,140,255,0.13); }
#directoryTree summary { display: flex; align-items: center; justify-content: space-between; list-style: none; }
#directoryTree summary::-webkit-details-marker { display: none; }
#directoryTree details > button { padding-left: 1.4rem; font-size: 0.78rem; }
.welcome-row { display: flex; align-items: center; justify-content: space-between; gap: 1rem; margin: 0.3rem 0 1.25rem; }
.welcome-row h1 { font-size: 2.25rem; }
.stats {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 0.55rem;
  margin-bottom: 1rem;
}
.stats div { padding: 0.85rem 0.75rem; border: 1px solid var(--border); border-radius: 1rem; background: rgba(16,29,46,0.72); }
.stats strong { display: block; font-size: 1.45rem; letter-spacing: -0.04em; }
.stats span { display: block; margin-top: 0.12rem; color: var(--muted); font-size: 0.72rem; }
.search-wrap { position: relative; margin-bottom: 0.75rem; }
.search-wrap svg { position: absolute; left: 0.95rem; top: 50%; width: 1.2rem; transform: translateY(-50%); fill: none; stroke: #7890aa; stroke-width: 1.8; stroke-linecap: round; }
.search-wrap input {
  width: 100%;
  min-height: 3.2rem;
  padding: 0.85rem 1rem 0.85rem 2.9rem;
  border: 1px solid var(--border);
  border-radius: 1rem;
  outline: none;
  color: var(--text);
  background: rgba(16,29,46,0.88);
  font-size: 1rem;
}
.search-wrap input:focus { border-color: rgba(98,180,255,0.65); box-shadow: 0 0 0 3px rgba(45,140,255,0.12); }
.mobile-directory-filters { display: grid; grid-template-columns: 1fr 1fr; gap: 0.5rem; margin-bottom: 0.75rem; }
.filter-toolbar { display: grid; grid-template-columns: minmax(0, 1fr) minmax(0, 1fr); gap: 0.5rem; margin-bottom: 0.75rem; }
.filter-toggle { display: flex; min-height: 2.8rem; align-items: center; gap: 0.48rem; padding: 0.65rem 0.75rem; border: 1px solid var(--border); border-radius: 0.75rem; color: var(--text); background: var(--surface-2); font-weight: 700; text-align: left; }
.filter-toggle svg { width: 1.05rem; fill: none; stroke: #8aa2bb; stroke-width: 1.8; stroke-linecap: round; }
.filter-toggle span { display: inline-grid; min-width: 1.35rem; height: 1.35rem; place-items: center; margin-left: auto; border-radius: 999px; color: white; background: var(--blue); font-size: 0.68rem; }
.advanced-filters { margin: -0.2rem 0 0.85rem; padding: 0.85rem; border: 1px solid var(--border); border-radius: 1rem; background: rgba(10,20,34,0.72); }
.filter-grid { display: grid; gap: 0.65rem; }
.filter-grid label { min-width: 0; color: var(--muted); font-size: 0.7rem; font-weight: 700; letter-spacing: 0.025em; }
.filter-grid select { margin-top: 0.32rem; }
.filter-actions { display: flex; flex-wrap: wrap; justify-content: flex-end; gap: 0.5rem; margin-top: 0.8rem; padding-top: 0.8rem; border-top: 1px solid var(--border); }
.filter-actions .secondary-button, .filter-actions .primary-button { width: auto; min-width: 0; }
select, .form-grid input {
  width: 100%;
  min-height: 2.8rem;
  padding: 0.65rem 0.75rem;
  border: 1px solid var(--border);
  border-radius: 0.75rem;
  outline: none;
  color: var(--text);
  background: var(--surface-2);
}
.filters { display: flex; gap: 0.5rem; margin-bottom: 1rem; overflow-x: auto; scrollbar-width: none; }
.filter { padding: 0.62rem 0.9rem; border: 1px solid var(--border); border-radius: 999px; color: var(--muted); background: transparent; font-size: 0.86rem; font-weight: 650; white-space: nowrap; }
.filter.active { color: white; border-color: rgba(45,140,255,0.65); background: rgba(45,140,255,0.16); }
.recent-section { margin-bottom: 1.15rem; padding: 0.85rem; border: 1px solid rgba(45,140,255,0.24); border-radius: 1rem; background: linear-gradient(145deg, rgba(18,43,70,0.72), rgba(9,24,40,0.72)); }
.list-heading { display: flex; align-items: flex-end; justify-content: space-between; gap: 0.8rem; margin: 0 0 0.65rem; }
.list-heading .eyebrow { margin: 0 0 0.15rem; font-size: 0.58rem; }
.list-heading h2 { margin: 0; font-size: 0.92rem; }
.list-heading > span { color: var(--muted); font-size: 0.66rem; }
.all-agents-heading { margin-top: 0.2rem; }
.all-agents-heading h2 { color: #9fb2c7; font-size: 0.8rem; text-transform: uppercase; letter-spacing: 0.055em; }
.recent-section .agent-card { background: linear-gradient(145deg, rgba(21,43,66,0.98), rgba(11,27,44,0.98)); }

.agent-list { display: grid; min-width: 0; gap: 0.58rem; }
.agent-card { min-width: 0; overflow: hidden; border: 1px solid var(--border); border-radius: 1rem; background: linear-gradient(145deg, rgba(16,29,46,0.96), rgba(9,20,34,0.96)); box-shadow: 0 0.55rem 1.4rem rgba(0,0,0,0.1); }
.agent-card.selected { border-color: rgba(45,140,255,0.52); box-shadow: 0 0 0 1px rgba(45,140,255,0.08), 0 0.8rem 2rem rgba(0,0,0,0.14); }
.agent-summary { display: block; width: 100%; min-width: 0; padding: 0.88rem 0.95rem; border: 0; color: inherit; background: transparent; text-align: left; cursor: pointer; }
.agent-summary:focus-visible { outline: 2px solid var(--blue-2); outline-offset: -3px; }
.agent-main { display: flex; min-width: 0; gap: 0.72rem; }
.status-dot { flex: 0 0 auto; width: 0.65rem; height: 0.65rem; margin-top: 0.42rem; border-radius: 50%; background: var(--muted); box-shadow: 0 0 0 0.3rem rgba(145,163,184,0.08); }
.agent-card.online .status-dot { background: var(--green); box-shadow: 0 0 0 0.3rem rgba(49,212,125,0.1); }
.agent-card.overdue .status-dot, .agent-card.offline .status-dot { background: var(--amber); box-shadow: 0 0 0 0.3rem rgba(255,184,77,0.1); }
.agent-copy { flex: 1; min-width: 0; }
.agent-chevron { flex: 0 0 auto; align-self: center; width: 1.05rem; fill: none; stroke: #667b91; stroke-width: 1.8; stroke-linecap: round; stroke-linejoin: round; transition: transform 160ms ease; }
.agent-card.selected .agent-chevron { transform: rotate(90deg); }
.agent-title-row { display: flex; align-items: flex-start; justify-content: space-between; gap: 0.75rem; }
.agent-title-row h2 { overflow: hidden; margin: 0; font-size: 1.05rem; line-height: 1.35; text-overflow: ellipsis; white-space: nowrap; }
.status-label { flex: 0 0 auto; color: var(--muted); font-size: 0.7rem; }
.agent-location, .agent-os { overflow: hidden; margin: 0.28rem 0 0; color: var(--muted); font-size: 0.8rem; line-height: 1.4; text-overflow: ellipsis; white-space: nowrap; }
.agent-os { color: #6e8299; }
.mobile-agent-detail:empty { display: none; }
.mobile-agent-detail { padding: 0 0.95rem 0.95rem; border-top: 1px solid var(--border); }
.agent-detail { min-width: 0; }
.detail-heading { display: none; }
.detail-eyebrow { margin: 0 0 0.35rem; color: var(--blue-2); font-size: 0.67rem; font-weight: 750; letter-spacing: 0.1em; text-transform: uppercase; }
.detail-heading h2 { overflow-wrap: anywhere; margin: 0; font-size: 1.25rem; line-height: 1.25; }
.detail-location, .detail-os { margin: 0.32rem 0 0; color: var(--muted); font-size: 0.78rem; line-height: 1.4; }
.detail-os { color: #6e8299; }
.detail-status { flex: 0 0 auto; padding: 0.3rem 0.52rem; border-radius: 999px; color: var(--muted); background: rgba(145,163,184,0.1); font-size: 0.68rem; }
.detail-status.online { color: #7cf0ab; background: rgba(49,212,125,0.12); }
.detail-status.overdue, .detail-status.offline { color: #ffd18b; background: rgba(255,184,77,0.12); }
.agent-details { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 0.65rem; margin: 0.95rem 0 0; }
.agent-details div { min-width: 0; }
.agent-details dt { margin-bottom: 0.16rem; color: #667b91; font-size: 0.67rem; font-weight: 700; text-transform: uppercase; letter-spacing: 0.045em; }
.agent-details dd { overflow: hidden; margin: 0; color: #c8d7e6; font-size: 0.78rem; line-height: 1.35; text-overflow: ellipsis; white-space: nowrap; }
.health-grid { display: grid; gap: 0.6rem; margin-top: 0.9rem; }
.health-panel { padding: 0.72rem; border: 1px solid var(--border); border-radius: 0.85rem; background: rgba(3,10,19,0.36); }
.health-heading { display: flex; align-items: center; justify-content: space-between; gap: 0.5rem; }
.health-heading span { color: #aabbd0; font-size: 0.76rem; font-weight: 750; }
.health-heading strong { padding: 0.25rem 0.45rem; border-radius: 999px; font-size: 0.62rem; line-height: 1.2; }
.health-heading strong.ok { color: #7cf0ab; background: rgba(49,212,125,0.12); }
.health-heading strong.warning { color: #ffd18b; background: rgba(255,184,77,0.12); }
.health-heading strong.critical { color: #ff9ba4; background: rgba(255,104,117,0.12); }
.health-heading strong.neutral { color: #a6b8cc; background: rgba(145,163,184,0.1); }
.health-panel p { overflow: hidden; margin: 0.4rem 0 0; color: #7388a0; font-size: 0.7rem; line-height: 1.35; text-overflow: ellipsis; white-space: nowrap; }
.health-panel p:last-child { color: #9db0c4; }
.agent-footer { display: flex; flex-wrap: wrap; align-items: center; justify-content: space-between; gap: 0.75rem; margin-top: 0.9rem; padding-top: 0.8rem; border-top: 1px solid var(--border); }
.last-seen { color: #6f8399; font-size: 0.73rem; }
.agent-actions { display: flex; flex-wrap: wrap; justify-content: flex-end; gap: 0.4rem; }
.action-button { display: inline-flex; align-items: center; gap: 0.34rem; min-height: 2.3rem; padding: 0.5rem 0.7rem; border: 1px solid rgba(98,180,255,0.17); border-radius: 0.72rem; color: white; background: rgba(45,140,255,0.13); font-size: 0.75rem; font-weight: 750; text-decoration: none; cursor: pointer; }
.rustdesk-button { background: linear-gradient(135deg, #1b78eb, #1558c1); }
.mesh-button { background: linear-gradient(135deg, #3c647f, #27475e); }
.wol-button { background: linear-gradient(135deg, #21744b, #19593a); }
.action-button:disabled { cursor: wait; opacity: 0.65; }
.action-button svg { width: 1rem; fill: none; stroke: currentColor; stroke-width: 1.8; stroke-linecap: round; stroke-linejoin: round; }
.loading, .empty-state, .error-card { margin-top: 2rem; padding: 1.5rem; text-align: center; }
.loading span { display: inline-block; width: 0.48rem; height: 0.48rem; margin: 0 0.15rem; border-radius: 50%; background: var(--blue-2); animation: pulse 1s infinite alternate; }
.loading span:nth-child(2) { animation-delay: 0.18s; }
.loading span:nth-child(3) { animation-delay: 0.36s; }
.loading p, .empty-state span { margin: 0.7rem 0 0; color: var(--muted); font-size: 0.85rem; }
.empty-state { display: flex; flex-direction: column; }
.error-card { border: 1px solid rgba(255,104,117,0.25); border-radius: 1rem; color: #ffc0c6; background: rgba(255,104,117,0.08); font-size: 0.9rem; }
@keyframes pulse { to { opacity: 0.25; transform: translateY(-0.2rem); } }

.access-dialog { width: min(1120px, calc(100% - 1.5rem)); max-height: calc(100dvh - 1.5rem); padding: 0; border: 1px solid var(--border); border-radius: 1.2rem; color: var(--text); background: #091421; box-shadow: 0 2rem 6rem rgba(0,0,0,0.55); }
.access-dialog::backdrop { background: rgba(0,5,12,0.78); backdrop-filter: blur(8px); }
.install-dialog { width: min(620px, calc(100% - 1.5rem)); padding: 0; border: 1px solid var(--border); border-radius: 1.2rem; color: var(--text); background: #091421; box-shadow: 0 2rem 6rem rgba(0,0,0,0.55); }
.install-dialog::backdrop { background: rgba(0,5,12,0.78); backdrop-filter: blur(8px); }
.install-dialog-shell { margin: 0; }
.install-dialog-content { padding: 1.1rem; }
.install-dialog-content > p { margin: 0 0 1rem; color: #b7c8d8; line-height: 1.55; }
.installer-actions { display: grid; gap: 0.65rem; }
.installer-actions .primary-button, .installer-actions .secondary-button { display: flex; align-items: center; justify-content: center; width: 100%; text-align: center; }
.installer-link { text-decoration: none; }
.dialog-shell { min-height: min(670px, calc(100dvh - 1.5rem)); }
.dialog-header { display: flex; align-items: center; justify-content: space-between; padding: 1rem 1.1rem; border-bottom: 1px solid var(--border); }
.dialog-header h2 { margin: 0; font-size: 1.2rem; }
.access-layout { display: grid; }
.user-list-panel { padding: 0.9rem; border-bottom: 1px solid var(--border); }
.user-list { display: grid; gap: 0.35rem; margin-top: 0.7rem; }
.user-list button { display: flex; flex-direction: column; align-items: flex-start; padding: 0.65rem; border: 0; border-radius: 0.65rem; color: var(--text); background: transparent; text-align: left; }
.user-list button.active { background: rgba(45,140,255,0.14); }
.user-list small { margin-top: 0.18rem; color: var(--muted); }
.user-editor { padding: 1rem; }
.form-grid { display: grid; gap: 0.8rem; }
.form-grid label { color: var(--muted); font-size: 0.75rem; }
.form-grid label input, .form-grid label select { margin-top: 0.35rem; }
.check-label { display: flex; align-items: center; gap: 0.5rem; }
.check-label input { width: 1rem; height: 1rem; }
.permission-fieldset { display: flex; flex-wrap: wrap; gap: 0.8rem; padding: 0.75rem; border: 1px solid var(--border); border-radius: 0.75rem; }
.permission-fieldset legend { padding: 0 0.35rem; color: var(--muted); font-size: 0.72rem; }
.scope-editor { margin-top: 1rem; padding-top: 1rem; border-top: 1px solid var(--border); }
.scope-editor h3 { margin: 0 0 0.7rem; font-size: 0.9rem; }
.scope-add-row { display: grid; gap: 0.5rem; }
.scope-list { display: grid; gap: 0.4rem; margin-top: 0.65rem; }
.scope-list div { display: flex; align-items: center; justify-content: space-between; gap: 0.5rem; padding: 0.55rem 0.65rem; border: 1px solid var(--border); border-radius: 0.65rem; color: #b7c8d8; font-size: 0.75rem; }
.scope-list button { border: 0; color: #ff98a2; background: transparent; }
.dialog-actions { display: flex; justify-content: space-between; gap: 0.75rem; margin-top: 1rem; }
.primary-button.compact { width: auto; min-width: 9rem; padding: 0.72rem 1rem; border: 0; }
.secondary-button, .danger-button { min-height: 2.7rem; padding: 0.6rem 0.8rem; border: 1px solid var(--border); border-radius: 0.72rem; color: #c9d9e8; background: rgba(255,255,255,0.035); }
.danger-button { color: #ff9ba4; border-color: rgba(255,104,117,0.25); }
.form-error { margin-top: 0.8rem; color: #ff9ba4; font-size: 0.8rem; }

@media (min-width: 680px) {
  .brand-logo { width: 11.5rem; height: 3.75rem; }
  main { padding-inline: 1.5rem; }
  .health-grid { grid-template-columns: 1fr 1fr; }
  .scope-add-row { grid-template-columns: 1fr 1fr auto; }
  .form-grid { grid-template-columns: 1fr 1fr; }
  .filter-grid { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .permission-fieldset { grid-column: 1 / -1; }
  .primary-button { width: auto; min-width: 19rem; }
  .installer-actions { grid-template-columns: 1fr 1fr; }
  .installer-actions .installer-link { grid-column: 1 / -1; }
}
@media (max-width: 520px) {
  .topbar { gap: 0.5rem; padding-inline: 0.7rem; }
  .brand-logo { width: 7.25rem; height: 3rem; }
  .brand-copy strong { overflow: hidden; font-size: 0.82rem; text-overflow: ellipsis; white-space: nowrap; }
  .role-badge { padding-inline: 0.48rem; font-size: 0.62rem; }
  .icon-button { width: 2.5rem; height: 2.5rem; }
}
@media (min-width: 900px) {
  main { padding-inline: 1.6rem; }
  .workspace { grid-template-columns: 250px minmax(0, 1fr); align-items: start; }
  .directory-panel { position: sticky; top: 5.1rem; display: block; max-height: calc(100dvh - 6rem); overflow: auto; padding: 1rem; border: 1px solid var(--border); border-radius: 1rem; background: rgba(10,20,34,0.76); }
  .mobile-directory-filters { display: none; }
  .access-layout { grid-template-columns: 280px 1fr; }
  .user-list-panel { border-right: 1px solid var(--border); border-bottom: 0; }
}
@media (min-width: 1100px) {
  .workspace { grid-template-columns: minmax(220px, 260px) minmax(420px, 1.35fr) minmax(430px, 0.9fr); }
  .desktop-detail-panel { position: sticky; top: 5.1rem; display: block; max-height: calc(100dvh - 6rem); overflow-x: hidden; overflow-y: auto; padding: 1rem; border: 1px solid var(--border); border-radius: 1rem; background: rgba(10,20,34,0.88); }
  .detail-placeholder { display: flex; min-height: 18rem; flex-direction: column; align-items: center; justify-content: center; padding: 2rem; color: var(--muted); text-align: center; }
  .detail-placeholder svg { width: 2.5rem; margin-bottom: 1rem; fill: none; stroke: #66809a; stroke-width: 1.5; stroke-linecap: round; stroke-linejoin: round; }
  .detail-placeholder strong { color: #c8d7e6; }
  .detail-placeholder span { max-width: 16rem; margin-top: 0.4rem; font-size: 0.78rem; line-height: 1.45; }
  .detail-heading { display: flex; align-items: flex-start; justify-content: space-between; gap: 1rem; padding-bottom: 0.95rem; border-bottom: 1px solid var(--border); }
  .desktop-detail-panel .agent-details dd, .desktop-detail-panel .health-panel p { overflow: visible; text-overflow: clip; white-space: normal; overflow-wrap: anywhere; }
  .desktop-detail-panel .health-heading { align-items: flex-start; flex-wrap: wrap; }
  .mobile-agent-detail { display: none; }
  .filter-grid { grid-template-columns: repeat(3, minmax(0, 1fr)); }
}
@media (min-width: 1500px) {
  main { padding-inline: 2rem; }
  .workspace { grid-template-columns: minmax(240px, 290px) minmax(560px, 1.45fr) minmax(500px, 0.85fr); gap: 1.25rem; }
  .desktop-detail-panel, .directory-panel { padding: 1.15rem; }
}
@media (min-width: 1900px) {
  main { padding-inline: 2.5rem; }
  .workspace { grid-template-columns: minmax(260px, 320px) minmax(760px, 1.55fr) minmax(560px, 0.85fr); gap: 1.5rem; }
  .fleet-panel .agent-list { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .fleet-panel .recent-section .agent-list { grid-template-columns: repeat(2, minmax(0, 1fr)); }
}
@media (prefers-reduced-motion: reduce) { *, *::before, *::after { animation-duration: 0.01ms !important; } }
