/* ==========================================================================
   CYBER//TASK — holographic interface
   ========================================================================== */

:root {
  --bg: #050807;
  --bg-soft: #080d0b;
  --bg-deep: #030504;
  --panel: rgba(11, 18, 15, 0.72);
  --panel-solid: #0a100d;
  --line: rgba(124, 255, 214, 0.11);
  --line-2: rgba(124, 255, 214, 0.22);
  --line-hot: rgba(61, 242, 189, 0.45);
  --text: #e8f5ee;
  --muted: #8ba298;
  --dim: #5b7067;
  --mint: #3df2bd;
  --mint-2: #00c896;
  --mint-soft: rgba(61, 242, 189, 0.1);
  --cyan: #6ee7ff;
  --orange: #ff6a2b;
  --orange-soft: rgba(255, 106, 43, 0.1);
  --amber: #ffb547;
  --red: #ff5c7a;
  --violet: #a78bfa;
  --font-display: "Bahnschrift", "DIN Alternate", "HarmonyOS Sans SC", "Microsoft YaHei UI", "Microsoft YaHei", sans-serif;
  --font-body: "Segoe UI Variable Text", "Segoe UI", "Microsoft YaHei UI", "Microsoft YaHei", "PingFang SC", sans-serif;
  --font-mono: "Cascadia Code", "Cascadia Mono", "JetBrains Mono", "Consolas", monospace;
  --rail: 238px;
  --topbar: 72px;
  --ease: cubic-bezier(0.16, 1, 0.3, 1);
  --shadow: 0 30px 80px -40px rgba(0, 0, 0, 0.95);
  --scan-band: linear-gradient(
    180deg,
    transparent 0%,
    rgba(61, 242, 189, 0.015) 34%,
    rgba(61, 242, 189, 0.075) 47%,
    rgba(61, 242, 189, 0.16) 50%,
    rgba(61, 242, 189, 0.075) 53%,
    rgba(61, 242, 189, 0.015) 66%,
    transparent 100%
  );
}

*,
*::before,
*::after {
  box-sizing: border-box;
}

[hidden] {
  display: none !important;
}

html {
  -webkit-text-size-adjust: 100%;
  scrollbar-color: rgba(124, 255, 214, 0.18) #050807;
}

body {
  margin: 0;
  min-height: 100vh;
  background: var(--bg);
  color: var(--text);
  font-family: var(--font-body);
  font-size: 14px;
  line-height: 1.5;
  overflow-x: hidden;
  -webkit-font-smoothing: antialiased;
}

::selection {
  background: rgba(61, 242, 189, 0.28);
  color: #fff;
}

::-webkit-scrollbar {
  width: 9px;
  height: 9px;
}
::-webkit-scrollbar-track {
  background: #050807;
}
::-webkit-scrollbar-thumb {
  background: rgba(124, 255, 214, 0.16);
  border: 2px solid #050807;
}
::-webkit-scrollbar-thumb:hover {
  background: rgba(124, 255, 214, 0.32);
}

a {
  color: inherit;
  text-decoration: none;
}

button,
input,
textarea,
select {
  font: inherit;
  color: inherit;
}

button {
  cursor: pointer;
}

h1, h2, h3, h4, p {
  margin: 0;
}

svg {
  display: block;
}

:focus-visible {
  outline: 1px solid var(--mint);
  outline-offset: 2px;
}

.icon {
  width: 18px;
  height: 18px;
  fill: none;
  stroke: currentColor;
  stroke-width: 1.6;
  stroke-linecap: round;
  stroke-linejoin: round;
  flex: none;
}

.sprite {
  position: absolute;
  width: 0;
  height: 0;
  overflow: hidden;
}

.mono {
  font-family: var(--font-mono);
}
.muted {
  color: var(--muted);
}
.dim {
  color: var(--dim);
}
.accent-text {
  color: var(--mint);
}
.orange-text {
  color: var(--orange);
}
.nowrap {
  white-space: nowrap;
}

/* --------------------------------------------------------------------------
   ambient background
   -------------------------------------------------------------------------- */

.bg-layer {
  position: fixed;
  inset: 0;
  z-index: 0;
  pointer-events: none;
}

.bg-grid {
  background-image:
    linear-gradient(rgba(124, 255, 214, 0.038) 1px, transparent 1px),
    linear-gradient(90deg, rgba(124, 255, 214, 0.038) 1px, transparent 1px);
  background-size: 74px 74px;
  mask-image: radial-gradient(ellipse 130% 90% at 50% 0%, #000 12%, rgba(0, 0, 0, 0.5) 55%, transparent 88%);
  -webkit-mask-image: radial-gradient(ellipse 130% 90% at 50% 0%, #000 12%, rgba(0, 0, 0, 0.5) 55%, transparent 88%);
  animation: grid-drift 90s linear infinite;
  opacity: 0.8;
}

.bg-glow {
  background:
    radial-gradient(720px 520px at 8% -8%, rgba(0, 220, 160, 0.12), transparent 62%),
    radial-gradient(620px 480px at 98% 2%, rgba(255, 106, 43, 0.06), transparent 64%),
    radial-gradient(900px 700px at 48% 112%, rgba(0, 180, 140, 0.055), transparent 70%);
}

.bg-scan {
  height: 160px;
  background: linear-gradient(to bottom, transparent, rgba(61, 242, 189, 0.055), transparent);
  animation: scan-down 16s linear infinite;
  opacity: 0.8;
  mix-blend-mode: screen;
}

.bg-noise {
  opacity: 0.035;
  background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='160' height='160'%3E%3Cfilter id='n'%3E%3CfeTurbulence type='fractalNoise' baseFrequency='0.9' numOctaves='3' stitchTiles='stitch'/%3E%3C/filter%3E%3Crect width='100%25' height='100%25' filter='url(%23n)' opacity='0.55'/%3E%3C/svg%3E");
}

#dust {
  opacity: 0.55;
}

.frame {
  position: fixed;
  inset: 10px;
  z-index: 60;
  pointer-events: none;
  border: 1px solid rgba(124, 255, 214, 0.04);
}
.frame span {
  position: absolute;
  width: 16px;
  height: 16px;
  border-color: rgba(61, 242, 189, 0.45);
  border-style: solid;
  border-width: 0;
}
.frame-tl { left: -1px; top: -1px; border-left-width: 1px !important; border-top-width: 1px !important; }
.frame-tr { right: -1px; top: -1px; border-right-width: 1px !important; border-top-width: 1px !important; }
.frame-bl { left: -1px; bottom: -1px; border-left-width: 1px !important; border-bottom-width: 1px !important; }
.frame-br { right: -1px; bottom: -1px; border-right-width: 1px !important; border-bottom-width: 1px !important; }

/* --------------------------------------------------------------------------
   boot
   -------------------------------------------------------------------------- */

.boot {
  position: fixed;
  inset: 0;
  z-index: 300;
  display: grid;
  place-items: center;
  background: var(--bg-deep);
  overflow: hidden;
  transition: opacity 0.6s var(--ease), visibility 0.6s;
}
.boot.done {
  opacity: 0;
  visibility: hidden;
  pointer-events: none;
}
.boot::before {
  content: "";
  position: absolute;
  inset: 0;
  background-image:
    linear-gradient(rgba(124, 255, 214, 0.05) 1px, transparent 1px),
    linear-gradient(90deg, rgba(124, 255, 214, 0.05) 1px, transparent 1px);
  background-size: 56px 56px;
  mask-image: radial-gradient(circle at 50% 50%, #000, transparent 65%);
  animation: grid-drift 40s linear infinite;
}
.boot-scan {
  position: absolute;
  left: 0;
  right: 0;
  height: 1px;
  background: linear-gradient(90deg, transparent, var(--mint), transparent);
  box-shadow: 0 0 24px var(--mint);
  animation: boot-scan 3.2s var(--ease) infinite;
  opacity: 0.6;
}
.boot-inner {
  position: relative;
  width: min(440px, calc(100vw - 64px));
  text-align: center;
}
.boot-mark {
  width: 58px;
  height: 58px;
  margin: 0 auto 26px;
  position: relative;
  display: grid;
  place-items: center;
  border: 1px solid var(--line-2);
  transform: rotate(45deg);
  animation: boot-pulse 2.4s ease-in-out infinite;
}
.boot-mark::before {
  content: "";
  position: absolute;
  inset: 9px;
  border: 1px solid rgba(61, 242, 189, 0.5);
}
.boot-mark i {
  width: 10px;
  height: 10px;
  background: var(--mint);
  box-shadow: 0 0 24px var(--mint);
}
.boot-name {
  font-family: var(--font-mono);
  font-size: 22px;
  font-weight: 700;
  letter-spacing: 0.16em;
  color: var(--text);
}
.boot-name span {
  color: var(--mint);
}
.boot-sub {
  margin-top: 10px;
  font-family: var(--font-mono);
  font-size: 9px;
  letter-spacing: 0.36em;
  color: var(--dim);
}
.boot-bar {
  height: 2px;
  margin: 36px 0 14px;
  background: rgba(124, 255, 214, 0.1);
  overflow: hidden;
}
.boot-bar i {
  display: block;
  height: 100%;
  width: 0%;
  background: var(--mint);
  box-shadow: 0 0 16px var(--mint);
  transition: width 0.4s var(--ease);
}
.boot-log {
  font-family: var(--font-mono);
  font-size: 10px;
  letter-spacing: 0.14em;
  color: var(--muted);
  min-height: 16px;
}
.boot-coord {
  margin-top: 32px;
  font-family: var(--font-mono);
  font-size: 8px;
  letter-spacing: 0.28em;
  color: rgba(91, 112, 103, 0.8);
}

/* --------------------------------------------------------------------------
   shell
   -------------------------------------------------------------------------- */

.app {
  position: relative;
  z-index: 2;
  display: flex;
  min-height: 100vh;
}

.rail {
  position: fixed;
  inset: 0 auto 0 0;
  z-index: 40;
  width: var(--rail);
  display: flex;
  flex-direction: column;
  padding: 24px 16px 18px;
  border-right: 1px solid var(--line);
  background: linear-gradient(180deg, rgba(8, 13, 11, 0.92), rgba(4, 7, 6, 0.86));
  backdrop-filter: blur(22px);
}
.rail::after {
  content: "";
  position: absolute;
  top: 0;
  right: -1px;
  width: 1px;
  height: 160px;
  background: linear-gradient(to bottom, var(--mint), transparent);
  opacity: 0.5;
}

.brand {
  display: flex;
  align-items: center;
  gap: 14px;
  padding: 2px 8px 22px;
  border-bottom: 1px solid var(--line);
}
.brand-mark {
  position: relative;
  width: 36px;
  height: 36px;
  flex: none;
  display: grid;
  place-items: center;
}
.brand-mark::before {
  content: "";
  position: absolute;
  inset: 1px;
  border: 1px solid rgba(61, 242, 189, 0.55);
  transform: rotate(45deg);
  box-shadow: 0 0 20px rgba(61, 242, 189, 0.18), inset 0 0 14px rgba(61, 242, 189, 0.08);
}
.brand-mark::after {
  content: "";
  position: absolute;
  inset: 11px;
  border: 1px solid rgba(61, 242, 189, 0.35);
  transform: rotate(45deg);
}
.brand-mark i {
  width: 6px;
  height: 6px;
  background: var(--mint);
  box-shadow: 0 0 14px var(--mint);
}
.brand-text {
  display: flex;
  flex-direction: column;
  gap: 5px;
  min-width: 0;
}
.brand-name {
  font-family: var(--font-mono);
  font-size: 15px;
  font-weight: 700;
  letter-spacing: 0.07em;
  white-space: nowrap;
}
.brand-name b {
  color: var(--mint);
  font-weight: 700;
}
.brand-sub {
  font-family: var(--font-mono);
  font-size: 8px;
  letter-spacing: 0.2em;
  color: var(--dim);
  white-space: nowrap;
}

.nav {
  display: flex;
  flex-direction: column;
  gap: 3px;
  margin-top: 18px;
}
.nav-label {
  padding: 16px 12px 8px;
  font-family: var(--font-mono);
  font-size: 8.5px;
  letter-spacing: 0.22em;
  color: rgba(91, 112, 103, 0.75);
}
.nav-label:first-child {
  padding-top: 2px;
}
.nav-item {
  position: relative;
  display: flex;
  align-items: center;
  gap: 12px;
  width: 100%;
  height: 44px;
  padding: 0 12px;
  border: 1px solid transparent;
  background: transparent;
  color: var(--muted);
  text-align: left;
  transition: color 0.18s, background 0.18s, border-color 0.18s;
}
.nav-item .icon {
  width: 17px;
  height: 17px;
  opacity: 0.85;
}
.nav-text {
  font-size: 12.5px;
  letter-spacing: 0.03em;
}
.nav-idx {
  margin-left: auto;
  font-family: var(--font-mono);
  font-size: 9px;
  letter-spacing: 0.1em;
  color: rgba(91, 112, 103, 0.7);
}
.nav-item:hover {
  color: var(--text);
  background: rgba(61, 242, 189, 0.035);
}
.nav-item.active {
  color: var(--text);
  border-color: rgba(61, 242, 189, 0.16);
  background: linear-gradient(90deg, rgba(61, 242, 189, 0.11), rgba(61, 242, 189, 0.015));
}
.nav-item.active::before {
  content: "";
  position: absolute;
  left: -1px;
  top: 8px;
  bottom: 8px;
  width: 2px;
  background: var(--mint);
  box-shadow: 0 0 12px var(--mint);
}
.nav-item.active .icon {
  color: var(--mint);
  opacity: 1;
}
.nav-item.active .nav-idx {
  color: var(--mint);
}

.rail-foot {
  margin-top: auto;
  padding-top: 14px;
  border-top: 1px solid var(--line);
}
.node-chip {
  display: flex;
  align-items: center;
  gap: 11px;
  padding: 8px;
}
.node-avatar {
  width: 34px;
  height: 34px;
  display: grid;
  place-items: center;
  flex: none;
  font-family: var(--font-mono);
  font-size: 12px;
  font-weight: 700;
  color: var(--mint);
  border: 1px solid rgba(61, 242, 189, 0.28);
  background: rgba(61, 242, 189, 0.06);
  clip-path: polygon(0 0, calc(100% - 8px) 0, 100% 8px, 100% 100%, 8px 100%, 0 calc(100% - 8px));
}
.node-info {
  display: flex;
  flex-direction: column;
  gap: 5px;
  min-width: 0;
}
.node-info b {
  font-size: 11.5px;
  font-weight: 600;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
  max-width: 130px;
}
.node-info small {
  display: flex;
  align-items: center;
  gap: 6px;
  font-family: var(--font-mono);
  font-size: 8px;
  letter-spacing: 0.12em;
  color: var(--dim);
}

.rail-admin {
  display: flex;
  align-items: center;
  gap: 9px;
  width: 100%;
  height: 38px;
  margin-top: 8px;
  padding: 0 10px;
  border: 1px solid var(--line);
  background: rgba(0, 0, 0, 0.18);
  color: var(--dim);
  font-size: 10.5px;
  text-align: left;
  transition: 0.18s;
}
.rail-admin .icon {
  width: 14px;
  height: 14px;
}
.rail-admin:hover {
  color: var(--text);
  border-color: var(--line-2);
}
.rail-admin.is-admin {
  color: var(--mint);
  border-color: rgba(61, 242, 189, 0.25);
  background: rgba(61, 242, 189, 0.06);
}
.rail-admin-arrow {
  margin-left: auto;
  width: 12px !important;
  height: 12px !important;
}

.main {
  flex: 1;
  min-width: 0;
  margin-left: var(--rail);
  display: flex;
  flex-direction: column;
  min-height: 100vh;
}

.topbar {
  position: sticky;
  top: 0;
  z-index: 30;
  height: var(--topbar);
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 16px;
  padding: 0 clamp(18px, 2.6vw, 38px);
  border-bottom: 1px solid var(--line);
  background: rgba(5, 8, 7, 0.72);
  backdrop-filter: blur(22px);
}
.topbar::after {
  content: "";
  position: absolute;
  left: 0;
  right: 0;
  bottom: -1px;
  height: 1px;
  background: linear-gradient(90deg, transparent, rgba(61, 242, 189, 0.3), transparent);
  opacity: 0.5;
}
.crumb {
  display: flex;
  align-items: baseline;
  gap: 10px;
  font-family: var(--font-mono);
  font-size: 9.5px;
  letter-spacing: 0.18em;
  color: var(--dim);
  white-space: nowrap;
}
.crumb-idx {
  color: var(--orange);
  font-weight: 700;
}
.crumb-sep {
  color: rgba(91, 112, 103, 0.5);
}
.crumb-section {
  color: var(--muted);
}
.crumb-title {
  font-family: var(--font-body);
  font-size: 12px;
  letter-spacing: 0.08em;
  color: var(--text);
  padding-left: 4px;
}
.crumb-title::before {
  content: "/";
  margin-right: 10px;
  color: rgba(91, 112, 103, 0.5);
  font-family: var(--font-mono);
}

.topbar-right {
  display: flex;
  align-items: center;
  gap: 10px;
}
.clock {
  display: flex;
  flex-direction: column;
  align-items: flex-end;
  gap: 2px;
  margin-right: 6px;
  line-height: 1;
}
.clock-time {
  font-family: var(--font-mono);
  font-size: 15px;
  letter-spacing: 0.08em;
  color: var(--text);
  font-variant-numeric: tabular-nums;
}
.clock-date {
  font-family: var(--font-mono);
  font-size: 8px;
  letter-spacing: 0.16em;
  color: var(--dim);
}
.link-state {
  display: flex;
  align-items: center;
  gap: 7px;
  height: 28px;
  padding: 0 10px;
  border: 1px solid var(--line);
  font-family: var(--font-mono);
  font-size: 8.5px;
  letter-spacing: 0.14em;
  color: var(--dim);
  white-space: nowrap;
}
.link-state[data-state="online"] {
  color: var(--mint);
  border-color: rgba(61, 242, 189, 0.22);
  background: rgba(61, 242, 189, 0.04);
}
.link-state[data-state="offline"] {
  color: var(--red);
  border-color: rgba(255, 92, 122, 0.25);
}
.link-state[data-state="connecting"] {
  color: var(--amber);
  border-color: rgba(255, 181, 71, 0.2);
}

.dot {
  width: 5px;
  height: 5px;
  border-radius: 50%;
  background: currentColor;
  box-shadow: 0 0 8px currentColor;
  display: inline-block;
  flex: none;
}
.link-state[data-state="online"] .dot {
  animation: dot-pulse 2.2s ease-in-out infinite;
}

.icon-btn {
  width: 34px;
  height: 34px;
  display: grid;
  place-items: center;
  border: 1px solid var(--line);
  background: rgba(0, 0, 0, 0.16);
  color: var(--muted);
  transition: 0.18s;
}
.icon-btn:hover {
  color: var(--text);
  border-color: var(--line-2);
  background: rgba(61, 242, 189, 0.05);
}
.icon-btn.is-off {
  color: var(--dim);
  opacity: 0.6;
}
.icon-btn .icon {
  width: 16px;
  height: 16px;
}

.admin-chip {
  display: flex;
  align-items: center;
  gap: 6px;
  height: 34px;
  padding: 0 11px;
  border: 1px solid var(--line);
  background: rgba(0, 0, 0, 0.16);
  color: var(--dim);
  font-family: var(--font-mono);
  font-size: 9px;
  letter-spacing: 0.16em;
  transition: 0.18s;
}
.admin-chip .icon {
  width: 13px;
  height: 13px;
}
.admin-chip.is-admin {
  color: var(--mint);
  border-color: rgba(61, 242, 189, 0.3);
  background: rgba(61, 242, 189, 0.07);
}
.admin-chip:hover {
  border-color: var(--line-2);
}

.view {
  flex: 1;
  width: 100%;
  max-width: 1680px;
  margin: 0 auto;
  padding: clamp(22px, 3.2vw, 42px) clamp(18px, 3.4vw, 52px) 48px;
  outline: none;
}
.view.is-enter > .page {
  animation: page-in 0.55s var(--ease) both;
}
.view.is-leaving > .page {
  animation: page-out 0.16s ease-in both;
  pointer-events: none;
}
.view.is-enter > .page > .page-head,
.view.is-enter > .page > .hero {
  animation: reveal-up 0.55s 0.04s var(--ease) both;
}

.statusline {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 16px;
  min-height: 34px;
  padding: 8px clamp(18px, 3.4vw, 52px);
  border-top: 1px solid var(--line);
  font-family: var(--font-mono);
  font-size: 8px;
  letter-spacing: 0.16em;
  color: rgba(91, 112, 103, 0.85);
  background: rgba(3, 6, 5, 0.5);
}
.status-left,
.status-right {
  display: flex;
  align-items: center;
  gap: 9px;
  white-space: nowrap;
}
.status-code {
  color: rgba(61, 242, 189, 0.7);
}
.status-sep {
  color: rgba(91, 112, 103, 0.35);
}
.status-live {
  display: inline-flex;
  align-items: center;
  gap: 6px;
}
.status-mid {
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
  text-align: center;
}

/* --------------------------------------------------------------------------
   page primitives
   -------------------------------------------------------------------------- */

.page {
  width: 100%;
}

.page-head {
  display: flex;
  align-items: flex-end;
  justify-content: space-between;
  gap: 24px;
  margin-bottom: 26px;
  flex-wrap: wrap;
}
.page-head > div:first-child {
  min-width: 0;
}
.eyebrow {
  display: flex;
  align-items: center;
  gap: 10px;
  font-family: var(--font-mono);
  font-size: 9px;
  letter-spacing: 0.26em;
  text-transform: uppercase;
  color: var(--muted);
}
.eyebrow::before {
  content: "";
  width: 24px;
  height: 1px;
  background: var(--orange);
  box-shadow: 0 0 8px rgba(255, 106, 43, 0.5);
}
.page-title {
  margin-top: 12px;
  font-family: var(--font-display);
  font-size: clamp(30px, 3.5vw, 46px);
  font-weight: 700;
  line-height: 1.04;
  letter-spacing: -0.025em;
}
.page-desc {
  margin-top: 10px;
  max-width: 640px;
  color: var(--muted);
  font-size: 12.5px;
  line-height: 1.7;
}
.head-actions {
  display: flex;
  align-items: center;
  gap: 9px;
  flex-wrap: wrap;
}

.panel {
  position: relative;
  background-color: rgba(7, 12, 9, 0.86);
  background-image: linear-gradient(158deg, rgba(14, 23, 19, 0.78), rgba(6, 10, 8, 0.88));
  background-size: 100% 100%;
  background-repeat: no-repeat;
  background-position: 0 0;
  border: 1px solid var(--line);
  backdrop-filter: blur(14px);
  box-shadow: inset 0 1px 0 rgba(255, 255, 255, 0.025), var(--shadow);
}
@media (hover: hover) {
  .panel:hover {
    background-image: var(--scan-band), linear-gradient(158deg, rgba(14, 23, 19, 0.78), rgba(6, 10, 8, 0.88));
    background-size: 100% 180px, 100% 100%;
    background-position: 0 -180px, 0 0;
    animation: panel-scan 2.8s linear infinite;
  }
}
.panel::before,
.panel::after {
  content: "";
  position: absolute;
  width: 13px;
  height: 13px;
  pointer-events: none;
  opacity: 0.55;
}
.panel::before {
  left: -1px;
  top: -1px;
  border-left: 1px solid var(--mint);
  border-top: 1px solid var(--mint);
}
.panel::after {
  right: -1px;
  bottom: -1px;
  border-right: 1px solid var(--mint);
  border-bottom: 1px solid var(--mint);
}
.panel-hd {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 16px;
  min-height: 54px;
  padding: 14px 20px;
  border-bottom: 1px solid var(--line);
}
.panel-title {
  display: flex;
  align-items: center;
  gap: 10px;
  font-size: 13px;
  font-weight: 600;
  letter-spacing: 0.03em;
}
.panel-title::before {
  content: "";
  width: 5px;
  height: 5px;
  background: var(--mint);
  box-shadow: 0 0 9px var(--mint);
  flex: none;
}
.panel-meta {
  font-family: var(--font-mono);
  font-size: 8.5px;
  letter-spacing: 0.18em;
  color: var(--dim);
  white-space: nowrap;
}
.panel-link {
  display: inline-flex;
  align-items: center;
  gap: 5px;
  font-family: var(--font-mono);
  font-size: 9px;
  letter-spacing: 0.12em;
  color: var(--muted);
  background: none;
  border: 0;
  padding: 0;
  transition: color 0.18s;
}
.panel-link:hover {
  color: var(--mint);
}
.panel-link .icon {
  width: 12px;
  height: 12px;
}
.panel-bd {
  padding: 20px;
}
.panel-bd--flush {
  padding: 0;
}

/* buttons */

.btn {
  --btn-h: 38px;
  position: relative;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  height: var(--btn-h);
  padding: 0 16px;
  border: 1px solid var(--line-2);
  background: rgba(61, 242, 189, 0.03);
  color: var(--text);
  font-family: var(--font-body);
  font-size: 12px;
  font-weight: 500;
  letter-spacing: 0.02em;
  white-space: nowrap;
  clip-path: polygon(0 0, calc(100% - 10px) 0, 100% 10px, 100% 100%, 0 100%);
  transition: background 0.18s, border-color 0.18s, box-shadow 0.18s, color 0.18s;
}
.btn .icon {
  width: 15px;
  height: 15px;
}
.btn:hover {
  border-color: rgba(61, 242, 189, 0.45);
  background: rgba(61, 242, 189, 0.08);
  box-shadow: 0 0 26px -10px rgba(61, 242, 189, 0.5);
}
.btn:active {
  transform: translateY(1px);
}
.btn-primary {
  color: #03110c;
  background: var(--mint);
  border-color: var(--mint);
  font-weight: 700;
}
.btn-primary:hover {
  color: #02100b;
  background: #6bffd3;
  border-color: #6bffd3;
  box-shadow: 0 0 34px -6px rgba(61, 242, 189, 0.55);
}
.btn-accent {
  color: #180703;
  background: var(--orange);
  border-color: var(--orange);
  font-weight: 700;
}
.btn-accent:hover {
  color: #180703;
  background: #ff8a55;
  border-color: #ff8a55;
  box-shadow: 0 0 30px -8px rgba(255, 106, 43, 0.55);
}
.btn-ghost {
  background: transparent;
  border-color: var(--line);
  color: var(--muted);
}
.btn-ghost:hover {
  color: var(--text);
}
.btn-danger {
  color: var(--red);
  border-color: rgba(255, 92, 122, 0.28);
  background: rgba(255, 92, 122, 0.04);
}
.btn-danger:hover {
  color: var(--red);
  background: rgba(255, 92, 122, 0.1);
  border-color: rgba(255, 92, 122, 0.5);
  box-shadow: 0 0 24px -10px rgba(255, 92, 122, 0.6);
}
.btn-sm {
  --btn-h: 30px;
  padding: 0 10px;
  font-size: 10.5px;
}
.btn-sm .icon {
  width: 12px;
  height: 12px;
}
.btn-icon {
  width: 38px;
  padding: 0;
}
.btn:disabled {
  opacity: 0.35;
  cursor: not-allowed;
  box-shadow: none;
}
.btn:disabled:hover {
  box-shadow: none;
  transform: none;
}

/* inputs */

.field {
  display: flex;
  flex-direction: column;
  gap: 8px;
}
.field > label,
.field-label {
  display: flex;
  justify-content: space-between;
  gap: 10px;
  font-family: var(--font-mono);
  font-size: 8.5px;
  letter-spacing: 0.2em;
  color: var(--dim);
  text-transform: uppercase;
}
.input,
.textarea,
.select {
  width: 100%;
  border: 1px solid var(--line);
  background: rgba(3, 7, 6, 0.55);
  color: var(--text);
  height: 40px;
  padding: 0 12px;
  font-family: var(--font-body);
  font-size: 12.5px;
  outline: none;
  transition: border-color 0.18s, box-shadow 0.18s, background 0.18s;
}
.input::placeholder,
.textarea::placeholder {
  color: rgba(91, 112, 103, 0.7);
}
.input:hover,
.textarea:hover,
.select:hover {
  border-color: rgba(124, 255, 214, 0.22);
}
.input:focus,
.textarea:focus,
.select:focus {
  border-color: rgba(61, 242, 189, 0.6);
  background: rgba(3, 9, 7, 0.8);
  box-shadow: 0 0 0 1px rgba(61, 242, 189, 0.14), 0 0 26px -14px var(--mint);
}
.textarea {
  height: auto;
  min-height: 92px;
  padding: 10px 12px;
  resize: vertical;
  line-height: 1.65;
}
.select {
  appearance: none;
  -webkit-appearance: none;
  padding-right: 30px;
  background-image: linear-gradient(45deg, transparent 50%, var(--dim) 50%), linear-gradient(135deg, var(--dim) 50%, transparent 50%);
  background-position: calc(100% - 15px) 17px, calc(100% - 10px) 17px;
  background-size: 5px 5px, 5px 5px;
  background-repeat: no-repeat;
}
select option {
  background: #0a120e;
  color: var(--text);
}
.form-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 18px;
}
.form-grid .full {
  grid-column: 1 / -1;
}
.form-row {
  display: flex;
  gap: 10px;
  align-items: center;
}
.form-note {
  font-size: 11px;
  color: var(--dim);
  line-height: 1.6;
}

.chips {
  display: flex;
  flex-wrap: wrap;
  gap: 7px;
}
.chip {
  height: 30px;
  padding: 0 11px;
  border: 1px solid var(--line);
  background: rgba(0, 0, 0, 0.18);
  color: var(--muted);
  font-size: 11px;
  transition: 0.16s;
}
.chip:hover {
  border-color: var(--line-2);
  color: var(--text);
}
.chip.active {
  color: var(--mint);
  border-color: rgba(61, 242, 189, 0.4);
  background: rgba(61, 242, 189, 0.08);
  box-shadow: inset 0 0 16px rgba(61, 242, 189, 0.05);
}
.chip.active[data-priority="urgent"] {
  color: var(--red);
  border-color: rgba(255, 92, 122, 0.4);
  background: rgba(255, 92, 122, 0.08);
}
.chip.active[data-priority="high"] {
  color: var(--amber);
  border-color: rgba(255, 181, 71, 0.4);
  background: rgba(255, 181, 71, 0.08);
}
.chip.active[data-priority="normal"] {
  color: var(--cyan);
  border-color: rgba(110, 231, 255, 0.4);
  background: rgba(110, 231, 255, 0.08);
}

input[type="checkbox"].cb {
  appearance: none;
  -webkit-appearance: none;
  width: 15px;
  height: 15px;
  border: 1px solid var(--line-2);
  background: rgba(0, 0, 0, 0.28);
  cursor: pointer;
  position: relative;
  flex: none;
  transition: 0.15s;
}
input[type="checkbox"].cb:checked {
  background: var(--mint);
  border-color: var(--mint);
}
input[type="checkbox"].cb:checked::after {
  content: "";
  position: absolute;
  left: 4px;
  top: 1px;
  width: 5px;
  height: 9px;
  border: solid #04120c;
  border-width: 0 2px 2px 0;
  transform: rotate(45deg);
}

.switch {
  position: relative;
  display: inline-block;
  width: 42px;
  height: 22px;
  flex: none;
}
.switch input {
  opacity: 0;
  width: 0;
  height: 0;
  position: absolute;
}
.switch-track {
  position: absolute;
  inset: 0;
  border: 1px solid var(--line-2);
  background: rgba(0, 0, 0, 0.4);
  cursor: pointer;
  transition: 0.2s;
}
.switch-track::after {
  content: "";
  position: absolute;
  top: 3px;
  left: 3px;
  width: 14px;
  height: 14px;
  background: var(--dim);
  transition: 0.2s var(--ease);
}
.switch input:checked + .switch-track {
  border-color: rgba(61, 242, 189, 0.55);
  background: rgba(61, 242, 189, 0.12);
}
.switch input:checked + .switch-track::after {
  transform: translateX(20px);
  background: var(--mint);
  box-shadow: 0 0 12px rgba(61, 242, 189, 0.6);
}

/* --------------------------------------------------------------------------
   hero + dashboard
   -------------------------------------------------------------------------- */

.hero {
  position: relative;
  display: grid;
  grid-template-columns: minmax(0, 1.08fr) minmax(320px, 0.92fr);
  align-items: center;
  gap: clamp(24px, 4vw, 64px);
  min-height: 390px;
  padding: 18px 0 36px;
  border-bottom: 1px solid var(--line);
  margin-bottom: 26px;
}
.hero::before {
  content: "SECTOR 01 / LIVE";
  position: absolute;
  top: 0;
  right: 0;
  font-family: var(--font-mono);
  font-size: 8px;
  letter-spacing: 0.26em;
  color: rgba(91, 112, 103, 0.65);
}
.hero::after {
  content: "";
  position: absolute;
  left: 0;
  bottom: -1px;
  width: 120px;
  height: 1px;
  background: var(--orange);
  box-shadow: 0 0 12px rgba(255, 106, 43, 0.5);
}
.hero-copy {
  position: relative;
  z-index: 2;
}
.hero-title {
  margin-top: 18px;
  font-family: var(--font-display);
  font-size: clamp(40px, 5.4vw, 76px);
  font-weight: 700;
  line-height: 1.02;
  letter-spacing: -0.04em;
}
.hero-title .accent {
  color: var(--orange);
  text-shadow: 0 0 60px rgba(255, 106, 43, 0.16);
  position: relative;
}
.hero-title .accent::after {
  content: "";
  position: absolute;
  left: 0;
  right: 0;
  bottom: 0.06em;
  height: 0.055em;
  background: var(--orange);
  opacity: 0.35;
}
.hero-desc {
  max-width: 470px;
  margin-top: 20px;
  color: var(--muted);
  font-size: 13px;
  line-height: 1.85;
}
.hero-actions {
  display: flex;
  align-items: center;
  gap: 10px;
  margin-top: 28px;
  flex-wrap: wrap;
}
.hero-meta {
  display: flex;
  align-items: center;
  gap: 12px;
  margin-top: 28px;
  font-family: var(--font-mono);
  font-size: 8.5px;
  letter-spacing: 0.18em;
  color: var(--dim);
}
.hero-meta b {
  color: var(--mint);
  font-weight: 400;
}
.hero-meta .sep {
  color: rgba(91, 112, 103, 0.35);
}

.hero-core {
  position: relative;
  display: grid;
  place-items: center;
  min-height: 340px;
}
.core {
  position: relative;
  width: min(100%, 350px);
  aspect-ratio: 1;
  display: grid;
  place-items: center;
}
.core::before {
  content: "";
  position: absolute;
  inset: 30%;
  border-radius: 50%;
  background: radial-gradient(circle, rgba(61, 242, 189, 0.17), rgba(61, 242, 189, 0.03) 45%, transparent 70%);
  filter: blur(8px);
  animation: core-glow 5s ease-in-out infinite;
}
.core::after {
  content: "";
  position: absolute;
  inset: -14px;
  border: 1px solid rgba(124, 255, 214, 0.06);
  border-radius: 50%;
  border-left-color: rgba(61, 242, 189, 0.25);
  border-right-color: rgba(255, 106, 43, 0.18);
  animation: spin 70s linear infinite;
}
.core-ring {
  position: absolute;
  border-radius: 50%;
  border: 1px solid rgba(61, 242, 189, 0.14);
  pointer-events: none;
}
.core-ring.r1 {
  inset: 0;
  border-style: dashed;
  border-color: rgba(61, 242, 189, 0.16);
  animation: spin 80s linear infinite;
}
.core-ring.r2 {
  inset: 11%;
  border-color: rgba(61, 242, 189, 0.18);
  border-top-color: var(--mint);
  border-right-color: rgba(61, 242, 189, 0.45);
  animation: spin 22s linear infinite;
  box-shadow: 0 0 30px -18px var(--mint);
}
.core-ring.r3 {
  inset: 24%;
  border-color: rgba(255, 106, 43, 0.18);
  border-bottom-color: var(--orange);
  animation: spin-rev 15s linear infinite;
}
.core-ring.r4 {
  inset: 37%;
  border-color: rgba(124, 255, 214, 0.09);
  animation: spin 45s linear infinite reverse;
}
.core-orbit {
  position: absolute;
  inset: 0;
  animation: spin 34s linear infinite;
  pointer-events: none;
}
.core-orbit i {
  position: absolute;
  top: 50%;
  left: -3px;
  width: 6px;
  height: 6px;
  border-radius: 50%;
  background: var(--mint);
  box-shadow: 0 0 16px var(--mint), 0 0 40px rgba(61, 242, 189, 0.5);
}
.core-orbit.o2 {
  inset: 17%;
  animation: spin-rev 24s linear infinite;
}
.core-orbit.o2 i {
  left: auto;
  right: -2px;
  width: 4px;
  height: 4px;
  background: var(--orange);
  box-shadow: 0 0 14px var(--orange);
}
.core-center {
  position: relative;
  z-index: 2;
  text-align: center;
}
.core-value {
  font-family: var(--font-display);
  font-size: clamp(46px, 6vw, 64px);
  font-weight: 700;
  line-height: 1;
  letter-spacing: -0.04em;
  color: var(--text);
  font-variant-numeric: tabular-nums;
}
.core-value small {
  font-size: 0.35em;
  color: var(--muted);
  margin-left: 2px;
}
.core-label {
  margin-top: 10px;
  font-family: var(--font-mono);
  font-size: 8px;
  letter-spacing: 0.3em;
  color: var(--dim);
}
.core-sub {
  margin-top: 6px;
  font-family: var(--font-mono);
  font-size: 8px;
  letter-spacing: 0.1em;
  color: rgba(61, 242, 189, 0.6);
}
.core-tick {
  position: absolute;
  width: 1px;
  height: 7px;
  background: rgba(61, 242, 189, 0.4);
  left: 50%;
  top: -18px;
  transform-origin: 0 195px;
}
.core-tick:nth-child(2) { transform: rotate(90deg); }
.core-tick:nth-child(3) { transform: rotate(180deg); }
.core-tick:nth-child(4) { transform: rotate(270deg); }

.core-readout {
  position: absolute;
  bottom: -4px;
  left: 50%;
  transform: translateX(-50%);
  display: flex;
  gap: 20px;
  font-family: var(--font-mono);
  font-size: 8px;
  letter-spacing: 0.12em;
  color: var(--dim);
  white-space: nowrap;
}
.core-readout span b {
  color: var(--mint);
  font-weight: 400;
}

.stat-grid {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 1px;
  background: var(--line);
  border: 1px solid var(--line);
  margin-bottom: 26px;
}
.stat {
  position: relative;
  padding: 18px 20px 16px;
  background-color: rgba(7, 12, 10, 0.94);
  background-image: linear-gradient(180deg, rgba(10, 17, 14, 0.94), rgba(5, 9, 7, 0.94));
  background-size: 100% 100%;
  background-repeat: no-repeat;
  background-position: 0 0;
  overflow: hidden;
  min-height: 126px;
}
@media (hover: hover) {
  .stat:hover {
    background-image: var(--scan-band), linear-gradient(180deg, rgba(10, 17, 14, 0.94), rgba(5, 9, 7, 0.94));
    background-size: 100% 160px, 100% 100%;
    background-position: 0 -160px, 0 0;
    animation: panel-scan 2.4s linear infinite;
  }
}
.stat::after {
  content: "";
  position: absolute;
  left: 0;
  bottom: 0;
  width: 0;
  height: 1px;
  background: var(--orange);
  transition: width 0.6s var(--ease);
}
.stat:hover::after {
  width: 100%;
}
.stat-top {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 8px;
}
.stat-label {
  font-family: var(--font-mono);
  font-size: 8.5px;
  letter-spacing: 0.2em;
  color: var(--dim);
  text-transform: uppercase;
}
.stat-icon {
  color: var(--dim);
  opacity: 0.7;
}
.stat-icon .icon {
  width: 14px;
  height: 14px;
}
.stat-value {
  margin-top: 14px;
  font-family: var(--font-display);
  font-size: clamp(28px, 2.7vw, 38px);
  font-weight: 700;
  line-height: 1;
  letter-spacing: -0.02em;
  font-variant-numeric: tabular-nums;
}
.stat-value.accent {
  color: var(--orange);
  text-shadow: 0 0 30px rgba(255, 106, 43, 0.15);
}
.stat-value.mint {
  color: var(--mint);
}
.stat-foot {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 8px;
  margin-top: 11px;
  font-family: var(--font-mono);
  font-size: 8px;
  letter-spacing: 0.1em;
  color: var(--dim);
}
.stat-foot b {
  color: var(--muted);
  font-weight: 400;
}
.spark {
  display: flex;
  align-items: flex-end;
  gap: 2px;
  height: 15px;
  opacity: 0.65;
}
.spark i {
  width: 3px;
  background: rgba(61, 242, 189, 0.35);
  transition: height 0.4s var(--ease);
}
.spark i:last-child {
  background: var(--mint);
  box-shadow: 0 0 6px rgba(61, 242, 189, 0.4);
}

.dash-grid {
  display: grid;
  grid-template-columns: minmax(0, 1.45fr) minmax(300px, 0.8fr);
  gap: 18px;
  align-items: start;
}
.dash-side {
  display: flex;
  flex-direction: column;
  gap: 18px;
}
.dash-feed {
  min-height: 100%;
}

.feed {
  display: flex;
  flex-direction: column;
}
.feed-item {
  display: grid;
  grid-template-columns: 34px minmax(0, 1fr) auto;
  align-items: center;
  gap: 13px;
  padding: 14px 20px;
  border-bottom: 1px solid rgba(124, 255, 214, 0.06);
  transition: background 0.16s;
  cursor: pointer;
}
.feed-item:last-child {
  border-bottom: 0;
}
.feed-item:hover {
  background: rgba(61, 242, 189, 0.035);
}
.feed-idx {
  font-family: var(--font-mono);
  font-size: 8.5px;
  letter-spacing: 0.08em;
  color: var(--dim);
}
.feed-main {
  min-width: 0;
}
.feed-title {
  font-size: 12.5px;
  font-weight: 500;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}
.feed-sub {
  display: flex;
  align-items: center;
  gap: 8px;
  margin-top: 5px;
  font-family: var(--font-mono);
  font-size: 8px;
  letter-spacing: 0.08em;
  color: var(--dim);
}
.feed-sub .sep {
  opacity: 0.4;
}
.feed-end {
  display: flex;
  align-items: center;
  gap: 10px;
}

.status-pill {
  display: inline-flex;
  align-items: center;
  gap: 5px;
  height: 21px;
  padding: 0 8px;
  border: 1px solid currentColor;
  font-family: var(--font-mono);
  font-size: 8px;
  letter-spacing: 0.12em;
  white-space: nowrap;
  opacity: 0.9;
}
.status-pill::before {
  content: "";
  width: 4px;
  height: 4px;
  border-radius: 50%;
  background: currentColor;
  box-shadow: 0 0 7px currentColor;
}
.status-pill--todo { color: #8aa79b; background: rgba(138, 167, 155, 0.06); }
.status-pill--doing { color: var(--cyan); background: rgba(110, 231, 255, 0.06); }
.status-pill--review { color: var(--amber); background: rgba(255, 181, 71, 0.06); }
.status-pill--done { color: var(--mint); background: rgba(61, 242, 189, 0.06); }

.empty {
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  text-align: center;
  padding: 46px 24px;
  min-height: 220px;
  position: relative;
}
.empty-icon {
  position: relative;
  width: 54px;
  height: 54px;
  display: grid;
  place-items: center;
  margin-bottom: 18px;
  color: var(--dim);
  border: 1px solid var(--line);
  transform: rotate(45deg);
}
.empty-icon .icon {
  width: 20px;
  height: 20px;
  transform: rotate(-45deg);
  opacity: 0.7;
}
.empty-icon::after {
  content: "";
  position: absolute;
  inset: 8px;
  border: 1px solid rgba(61, 242, 189, 0.1);
}
.empty-title {
  font-size: 13px;
  font-weight: 600;
  letter-spacing: 0.04em;
}
.empty-text {
  margin-top: 7px;
  max-width: 320px;
  font-size: 11.5px;
  line-height: 1.7;
  color: var(--dim);
}
.empty-actions {
  display: flex;
  gap: 8px;
  margin-top: 18px;
  flex-wrap: wrap;
  justify-content: center;
}

.mini-clients {
  display: flex;
  flex-direction: column;
}
.mini-client {
  display: flex;
  align-items: center;
  gap: 11px;
  padding: 11px 18px;
  border-bottom: 1px solid rgba(124, 255, 214, 0.05);
}
.mini-client:last-child {
  border-bottom: 0;
}
.mini-avatar {
  width: 28px;
  height: 28px;
  display: grid;
  place-items: center;
  flex: none;
  font-family: var(--font-mono);
  font-size: 9px;
  color: var(--mint);
  border: 1px solid rgba(61, 242, 189, 0.2);
  background: rgba(61, 242, 189, 0.05);
}
.mini-info {
  min-width: 0;
  display: flex;
  flex-direction: column;
  gap: 3px;
}
.mini-info b {
  font-size: 11px;
  font-weight: 500;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}
.mini-info small {
  font-family: var(--font-mono);
  font-size: 7.5px;
  letter-spacing: 0.08em;
  color: var(--dim);
}
.mini-state {
  margin-left: auto;
  display: flex;
  align-items: center;
  gap: 6px;
  font-family: var(--font-mono);
  font-size: 7.5px;
  letter-spacing: 0.1em;
  color: var(--dim);
}
.mini-state.online {
  color: var(--mint);
}

.storage-body {
  padding: 18px 20px 20px;
}
.storage-top {
  display: flex;
  align-items: flex-end;
  justify-content: space-between;
  gap: 12px;
}
.storage-num {
  font-family: var(--font-display);
  font-size: 30px;
  font-weight: 700;
  line-height: 1;
}
.storage-num small {
  font-family: var(--font-mono);
  font-size: 9px;
  color: var(--dim);
  font-weight: 400;
  margin-left: 4px;
}
.storage-label {
  font-family: var(--font-mono);
  font-size: 8px;
  letter-spacing: 0.18em;
  color: var(--dim);
}
.meter {
  height: 3px;
  margin-top: 16px;
  background: rgba(124, 255, 214, 0.08);
  overflow: hidden;
}
.meter-fill {
  height: 100%;
  background: linear-gradient(90deg, var(--mint-2), var(--mint));
  box-shadow: 0 0 12px rgba(61, 242, 189, 0.55);
  transition: width 0.6s var(--ease);
}
.storage-foot {
  display: flex;
  justify-content: space-between;
  gap: 10px;
  margin-top: 10px;
  font-family: var(--font-mono);
  font-size: 7.5px;
  letter-spacing: 0.1em;
  color: var(--dim);
}

.activity {
  max-height: 258px;
  overflow: auto;
}
.activity-item {
  display: grid;
  grid-template-columns: 8px minmax(0, 1fr) auto;
  gap: 10px;
  align-items: start;
  padding: 10px 18px;
  border-bottom: 1px solid rgba(124, 255, 214, 0.05);
}
.activity-item:last-child {
  border-bottom: 0;
}
.activity-dot {
  width: 5px;
  height: 5px;
  margin-top: 5px;
  background: var(--mint);
  box-shadow: 0 0 7px rgba(61, 242, 189, 0.5);
}
.activity-text {
  font-size: 11px;
  line-height: 1.55;
  color: var(--muted);
}
.activity-time {
  font-family: var(--font-mono);
  font-size: 7.5px;
  color: var(--dim);
  white-space: nowrap;
  margin-top: 3px;
}

.ticker {
  position: relative;
  display: flex;
  align-items: center;
  gap: 14px;
  height: 38px;
  margin-top: 24px;
  border-top: 1px solid var(--line);
  border-bottom: 1px solid var(--line);
  overflow: hidden;
  font-family: var(--font-mono);
  font-size: 8.5px;
  letter-spacing: 0.14em;
  color: var(--dim);
}
.ticker-tag {
  position: relative;
  z-index: 2;
  display: flex;
  align-items: center;
  gap: 7px;
  height: 100%;
  padding: 0 14px 0 0;
  background: var(--bg);
  color: var(--orange);
  white-space: nowrap;
}
.ticker-track {
  display: flex;
  align-items: center;
  gap: 34px;
  white-space: nowrap;
  animation: marquee 38s linear infinite;
}
.ticker-track i {
  width: 3px;
  height: 3px;
  background: rgba(61, 242, 189, 0.4);
  flex: none;
}
.ticker:hover .ticker-track {
  animation-play-state: paused;
}

/* --------------------------------------------------------------------------
   tasks
   -------------------------------------------------------------------------- */

.toolbar {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 14px;
  flex-wrap: wrap;
  margin-bottom: 16px;
}
.toolbar-left,
.toolbar-right {
  display: flex;
  align-items: center;
  gap: 9px;
  flex-wrap: wrap;
}
.segmented {
  display: inline-flex;
  gap: 2px;
  padding: 3px;
  border: 1px solid var(--line);
  background: rgba(3, 7, 6, 0.45);
}
.seg {
  display: inline-flex;
  align-items: center;
  gap: 7px;
  height: 30px;
  padding: 0 12px;
  border: 1px solid transparent;
  background: transparent;
  color: var(--muted);
  font-size: 11px;
  white-space: nowrap;
  transition: 0.16s;
}
.seg:hover {
  color: var(--text);
}
.seg.active {
  color: var(--text);
  border-color: rgba(61, 242, 189, 0.2);
  background: rgba(61, 242, 189, 0.08);
}
.seg-count {
  font-family: var(--font-mono);
  font-size: 8.5px;
  color: var(--dim);
}
.seg.active .seg-count {
  color: var(--mint);
}

.searchbox {
  position: relative;
  display: flex;
  align-items: center;
  height: 36px;
  border: 1px solid var(--line);
  background: rgba(3, 7, 6, 0.5);
  transition: border-color 0.18s;
}
.searchbox:focus-within {
  border-color: rgba(61, 242, 189, 0.45);
}
.searchbox .icon {
  width: 14px;
  height: 14px;
  margin-left: 11px;
  color: var(--dim);
}
.searchbox input {
  width: 172px;
  height: 100%;
  border: 0;
  background: transparent;
  padding: 0 10px;
  font-size: 11.5px;
  outline: none;
}
.searchbox input::placeholder {
  color: rgba(91, 112, 103, 0.7);
}

.select-mini {
  height: 36px;
  border: 1px solid var(--line);
  background-color: rgba(3, 7, 6, 0.5);
  color: var(--muted);
  padding: 0 28px 0 11px;
  font-size: 11px;
  appearance: none;
  background-image: linear-gradient(45deg, transparent 50%, var(--dim) 50%), linear-gradient(135deg, var(--dim) 50%, transparent 50%);
  background-position: calc(100% - 14px) 15px, calc(100% - 9px) 15px;
  background-size: 5px 5px, 5px 5px;
  background-repeat: no-repeat;
  outline: none;
}
.select-mini:focus {
  border-color: rgba(61, 242, 189, 0.4);
}

.table-panel {
  overflow: hidden;
}
.bulkbar {
  display: none;
  align-items: center;
  gap: 12px;
  padding: 10px 18px;
  border-bottom: 1px solid rgba(61, 242, 189, 0.18);
  background: linear-gradient(90deg, rgba(61, 242, 189, 0.1), rgba(61, 242, 189, 0.02));
  font-family: var(--font-mono);
  font-size: 9px;
  letter-spacing: 0.12em;
  color: var(--mint);
}
.bulkbar.active {
  display: flex;
}
.bulkbar .btn {
  margin-left: 4px;
}
.bulk-actions {
  margin-left: auto;
  display: flex;
  gap: 7px;
}

.table-wrap {
  width: 100%;
  overflow-x: auto;
}
.task-table {
  width: 100%;
  border-collapse: collapse;
  font-size: 12px;
  min-width: 980px;
}
.task-table th {
  padding: 11px 12px;
  border-bottom: 1px solid var(--line);
  font-family: var(--font-mono);
  font-size: 8px;
  font-weight: 400;
  letter-spacing: 0.18em;
  color: var(--dim);
  text-align: left;
  white-space: nowrap;
  background: rgba(4, 8, 6, 0.4);
}
.task-table th:first-child,
.task-table td:first-child {
  padding-left: 18px;
  width: 38px;
}
.task-table th:last-child,
.task-table td:last-child {
  padding-right: 16px;
  text-align: right;
}
.task-table td {
  padding: 12px;
  border-bottom: 1px solid rgba(124, 255, 214, 0.055);
  vertical-align: middle;
}
.task-table tbody tr {
  transition: background 0.15s;
  cursor: pointer;
}
.task-table tbody tr:hover {
  background: rgba(61, 242, 189, 0.032);
}
.task-table tbody tr.selected {
  background: rgba(61, 242, 189, 0.055);
}
.task-table tbody tr:last-child td {
  border-bottom: 0;
}
.task-table tr.is-updating {
  opacity: 0.55;
}
.task-id {
  font-family: var(--font-mono);
  font-size: 9px;
  letter-spacing: 0.05em;
  color: var(--dim);
  white-space: nowrap;
}
.task-cell-main {
  min-width: 220px;
  max-width: 430px;
}
.task-title {
  display: flex;
  align-items: center;
  gap: 7px;
  font-size: 12.5px;
  font-weight: 500;
  color: var(--text);
  line-height: 1.4;
}
.task-title .pin {
  width: 5px;
  height: 5px;
  border-radius: 50%;
  background: var(--orange);
  box-shadow: 0 0 7px var(--orange);
  flex: none;
}
.task-desc {
  margin-top: 4px;
  font-size: 10.5px;
  color: var(--dim);
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
  max-width: 420px;
}
.task-tags {
  display: flex;
  gap: 5px;
  margin-top: 6px;
  flex-wrap: wrap;
}
.tag {
  font-family: var(--font-mono);
  font-size: 7.5px;
  letter-spacing: 0.06em;
  color: rgba(139, 162, 152, 0.8);
  border: 1px solid rgba(124, 255, 214, 0.1);
  padding: 2px 5px;
  background: rgba(0, 0, 0, 0.2);
}
.user {
  display: flex;
  align-items: center;
  gap: 8px;
  min-width: 90px;
}
.avatar {
  width: 24px;
  height: 24px;
  display: grid;
  place-items: center;
  flex: none;
  font-family: var(--font-mono);
  font-size: 8px;
  color: var(--cyan);
  border: 1px solid rgba(110, 231, 255, 0.22);
  background: rgba(110, 231, 255, 0.05);
}
.user-name {
  font-size: 11px;
  color: var(--muted);
  max-width: 100px;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}
.user-name.none {
  color: var(--dim);
  font-style: italic;
}

.priority {
  display: inline-flex;
  align-items: center;
  gap: 5px;
  font-family: var(--font-mono);
  font-size: 8px;
  letter-spacing: 0.1em;
  white-space: nowrap;
}
.priority::before {
  content: "";
  width: 4px;
  height: 4px;
  background: currentColor;
  box-shadow: 0 0 6px currentColor;
}
.priority--low { color: #7f978c; }
.priority--normal { color: var(--cyan); }
.priority--high { color: var(--amber); }
.priority--urgent { color: var(--red); }

.status-select {
  height: 26px;
  min-width: 82px;
  border: 1px solid var(--line);
  background-color: rgba(3, 7, 6, 0.55);
  padding: 0 22px 0 8px;
  font-family: var(--font-mono);
  font-size: 8px;
  letter-spacing: 0.08em;
  appearance: none;
  background-image: linear-gradient(45deg, transparent 50%, currentColor 50%), linear-gradient(135deg, currentColor 50%, transparent 50%);
  background-position: calc(100% - 11px) 11px, calc(100% - 7px) 11px;
  background-size: 4px 4px, 4px 4px;
  background-repeat: no-repeat;
  outline: none;
  cursor: pointer;
}
.status-select.st-todo { color: #9fb4aa; border-color: rgba(159, 180, 170, 0.2); }
.status-select.st-doing { color: var(--cyan); border-color: rgba(110, 231, 255, 0.25); }
.status-select.st-review { color: var(--amber); border-color: rgba(255, 181, 71, 0.25); }
.status-select.st-done { color: var(--mint); border-color: rgba(61, 242, 189, 0.25); }

.due {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  font-family: var(--font-mono);
  font-size: 9px;
  color: var(--dim);
  white-space: nowrap;
}
button.due {
  padding: 0;
  border: 0;
  background: none;
  cursor: pointer;
  transition: color 0.15s;
}
button.due:hover {
  color: var(--mint);
}
.due .icon {
  width: 11px;
  height: 11px;
  opacity: 0.6;
}
.due.overdue {
  color: var(--red);
}
.due.soon {
  color: var(--amber);
}

.row-actions {
  display: inline-flex;
  align-items: center;
  gap: 2px;
  opacity: 0.55;
  transition: opacity 0.16s;
}
tr:hover .row-actions {
  opacity: 1;
}
.row-action {
  width: 28px;
  height: 28px;
  display: grid;
  place-items: center;
  border: 1px solid transparent;
  background: transparent;
  color: var(--muted);
  transition: 0.16s;
}
.row-action:hover {
  color: var(--mint);
  border-color: var(--line);
  background: rgba(61, 242, 189, 0.05);
}
.row-action.danger:hover {
  color: var(--red);
  border-color: rgba(255, 92, 122, 0.28);
  background: rgba(255, 92, 122, 0.06);
}
.row-action .icon {
  width: 13px;
  height: 13px;
}

/* inline editing */

.inline-input {
  width: 100%;
  height: 28px;
  border: 1px solid rgba(61, 242, 189, 0.45);
  background: rgba(3, 9, 7, 0.9);
  padding: 0 7px;
  font-size: 11px;
  outline: none;
  box-shadow: 0 0 0 1px rgba(61, 242, 189, 0.1);
}
.cell-editable {
  cursor: text;
  border-bottom: 1px dashed transparent;
  display: inline-block;
  max-width: 100%;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
  vertical-align: middle;
}
.cell-editable:hover {
  border-bottom-color: rgba(124, 255, 214, 0.25);
}

/* task form / drawer */

.drawer-backdrop {
  position: fixed;
  inset: 0;
  z-index: 95;
  background: rgba(2, 5, 4, 0.66);
  backdrop-filter: blur(5px);
  animation: fade-in 0.22s ease both;
}
.drawer {
  position: fixed;
  top: 0;
  right: 0;
  bottom: 0;
  z-index: 96;
  width: min(540px, 100vw);
  display: flex;
  flex-direction: column;
  background: linear-gradient(165deg, #0b1410, #060a08 70%);
  border-left: 1px solid var(--line-2);
  box-shadow: -40px 0 120px -40px #000;
  animation: drawer-in 0.38s var(--ease) both;
}
.drawer-hd {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  gap: 14px;
  padding: 22px 24px 18px;
  border-bottom: 1px solid var(--line);
}
.drawer-eyebrow {
  font-family: var(--font-mono);
  font-size: 8px;
  letter-spacing: 0.22em;
  color: var(--dim);
}
.drawer-title {
  margin-top: 9px;
  font-family: var(--font-display);
  font-size: 24px;
  font-weight: 700;
  letter-spacing: -0.02em;
  line-height: 1.2;
}
.drawer-bd {
  flex: 1;
  overflow: auto;
  padding: 22px 24px;
}
.drawer-ft {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 10px;
  padding: 16px 24px;
  border-top: 1px solid var(--line);
  background: rgba(3, 7, 5, 0.5);
  flex-wrap: wrap;
}
.drawer-ft .left,
.drawer-ft .right {
  display: flex;
  gap: 8px;
}
.meta-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 1px;
  margin-top: 22px;
  border: 1px solid var(--line);
  background: var(--line);
}
.meta-item {
  padding: 11px 12px;
  background: rgba(6, 11, 9, 0.9);
}
.meta-label {
  font-family: var(--font-mono);
  font-size: 7.5px;
  letter-spacing: 0.16em;
  color: var(--dim);
}
.meta-value {
  margin-top: 5px;
  font-family: var(--font-mono);
  font-size: 9.5px;
  color: var(--muted);
  word-break: break-all;
}
.form-section {
  margin-top: 22px;
}
.form-section:first-child {
  margin-top: 0;
}
.section-label {
  display: flex;
  align-items: center;
  gap: 8px;
  margin-bottom: 12px;
  font-family: var(--font-mono);
  font-size: 8px;
  letter-spacing: 0.2em;
  color: var(--dim);
}
.section-label::after {
  content: "";
  flex: 1;
  height: 1px;
  background: var(--line);
}

/* publish preview */

.publish-box {
  border: 1px solid var(--line);
  background: rgba(3, 7, 6, 0.45);
  padding: 14px;
}
.publish-task-list {
  display: flex;
  flex-direction: column;
  gap: 7px;
  max-height: 160px;
  overflow: auto;
}
.publish-task {
  display: flex;
  align-items: center;
  gap: 8px;
  font-size: 11.5px;
}
.publish-task .dot {
  color: var(--mint);
}
.publish-task span {
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}

/* --------------------------------------------------------------------------
   files
   -------------------------------------------------------------------------- */

.file-toolbar {
  display: flex;
  align-items: center;
  gap: 12px;
  flex-wrap: wrap;
  margin-bottom: 16px;
}
.breadcrumb {
  display: flex;
  align-items: center;
  gap: 4px;
  flex-wrap: wrap;
  font-family: var(--font-mono);
  font-size: 9px;
  letter-spacing: 0.06em;
  color: var(--dim);
  min-height: 30px;
  flex: 1;
}
.crumb-link {
  padding: 4px 6px;
  color: var(--muted);
  background: none;
  border: 0;
  transition: color 0.15s;
}
.crumb-link:hover {
  color: var(--mint);
}
.crumb-link.current {
  color: var(--text);
}
.breadcrumb .sep {
  opacity: 0.4;
}
.file-toolbar-actions {
  display: flex;
  align-items: center;
  gap: 7px;
}

.dropzone {
  position: relative;
  display: flex;
  align-items: center;
  gap: 14px;
  padding: 16px 20px;
  margin-bottom: 16px;
  border: 1px dashed rgba(61, 242, 189, 0.22);
  background: rgba(61, 242, 189, 0.025);
  transition: 0.2s;
  cursor: pointer;
}
.dropzone:hover,
.dropzone.dragover {
  border-color: rgba(61, 242, 189, 0.6);
  background: rgba(61, 242, 189, 0.07);
}
.dropzone.dragover {
  box-shadow: inset 0 0 50px rgba(61, 242, 189, 0.06), 0 0 40px -20px var(--mint);
}
.dropzone-icon {
  width: 42px;
  height: 42px;
  display: grid;
  place-items: center;
  flex: none;
  border: 1px solid rgba(61, 242, 189, 0.22);
  color: var(--mint);
  background: rgba(61, 242, 189, 0.04);
}
.dropzone-text b {
  font-size: 12px;
  font-weight: 600;
}
.dropzone-text p {
  margin-top: 3px;
  font-size: 10.5px;
  color: var(--dim);
}
.dropzone-hint {
  margin-left: auto;
  font-family: var(--font-mono);
  font-size: 8px;
  letter-spacing: 0.12em;
  color: var(--dim);
  white-space: nowrap;
}

.file-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(200px, 1fr));
  gap: 12px;
}
.file-card {
  position: relative;
  border: 1px solid var(--line);
  background: linear-gradient(160deg, rgba(12, 20, 16, 0.85), rgba(5, 9, 7, 0.9));
  transition: border-color 0.18s, transform 0.18s, box-shadow 0.18s;
  overflow: hidden;
  min-width: 0;
}
.file-card:hover {
  border-color: rgba(61, 242, 189, 0.3);
  transform: translateY(-2px);
  box-shadow: 0 18px 40px -30px #000, 0 0 30px -18px rgba(61, 242, 189, 0.35);
}
.file-card::after,
.node-card::after {
  content: "";
  position: absolute;
  left: 0;
  right: 0;
  top: -35%;
  height: 35%;
  z-index: 2;
  pointer-events: none;
  opacity: 0;
  transition: opacity 0.18s;
  background: linear-gradient(
    180deg,
    transparent 0%,
    rgba(61, 242, 189, 0.02) 32%,
    rgba(61, 242, 189, 0.09) 47%,
    rgba(61, 242, 189, 0.18) 50%,
    rgba(61, 242, 189, 0.09) 53%,
    rgba(61, 242, 189, 0.02) 68%,
    transparent 100%
  );
  mix-blend-mode: screen;
}
@media (hover: hover) {
  .file-card:hover::after,
  .node-card:hover::after {
    opacity: 1;
    animation: card-scan 2.4s linear infinite;
  }
}
.file-thumb {
  position: relative;
  height: 112px;
  display: grid;
  place-items: center;
  overflow: hidden;
  border-bottom: 1px solid var(--line);
  background:
    linear-gradient(rgba(124, 255, 214, 0.025) 1px, transparent 1px),
    linear-gradient(90deg, rgba(124, 255, 214, 0.025) 1px, transparent 1px),
    rgba(0, 0, 0, 0.22);
  background-size: 18px 18px;
}
.file-thumb img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  opacity: 0.72;
  transition: opacity 0.25s, transform 0.4s var(--ease);
}
.file-card:hover .file-thumb img {
  opacity: 1;
  transform: scale(1.045);
}
.file-glyph {
  font-family: var(--font-display);
  font-size: 21px;
  font-weight: 700;
  letter-spacing: 0.08em;
  color: var(--mint);
  opacity: 0.75;
}
.file-glyph .icon {
  width: 32px;
  height: 32px;
  margin: 0 auto;
  opacity: 0.85;
}
.file-thumb-label {
  position: absolute;
  top: 8px;
  right: 8px;
  font-family: var(--font-mono);
  font-size: 7px;
  letter-spacing: 0.1em;
  color: rgba(232, 245, 238, 0.55);
  background: rgba(0, 0, 0, 0.55);
  padding: 3px 5px;
  border: 1px solid rgba(124, 255, 214, 0.12);
}
.file-card-bd {
  padding: 11px 12px 12px;
  min-width: 0;
}
.file-name {
  font-size: 11.5px;
  font-weight: 500;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}
.file-meta {
  display: flex;
  justify-content: space-between;
  gap: 8px;
  margin-top: 6px;
  font-family: var(--font-mono);
  font-size: 7.5px;
  letter-spacing: 0.06em;
  color: var(--dim);
}
.file-actions {
  position: absolute;
  left: 8px;
  right: 8px;
  bottom: 8px;
  z-index: 3;
  display: flex;
  gap: 4px;
  justify-content: flex-end;
  opacity: 0;
  transform: translateY(4px);
  transition: 0.18s;
}
.file-card:hover .file-actions {
  opacity: 1;
  transform: translateY(0);
}
.file-action {
  width: 26px;
  height: 26px;
  display: grid;
  place-items: center;
  border: 1px solid rgba(124, 255, 214, 0.16);
  background: rgba(5, 10, 8, 0.88);
  color: var(--muted);
  backdrop-filter: blur(6px);
  transition: 0.15s;
}
.file-action:hover {
  color: var(--mint);
  border-color: rgba(61, 242, 189, 0.4);
}
.file-action.danger:hover {
  color: var(--red);
  border-color: rgba(255, 92, 122, 0.4);
}
.file-action .icon {
  width: 12px;
  height: 12px;
}

.file-list .task-table {
  min-width: 720px;
}
.file-row-name {
  display: flex;
  align-items: center;
  gap: 10px;
}
.file-icon {
  width: 28px;
  height: 28px;
  display: grid;
  place-items: center;
  border: 1px solid var(--line);
  color: var(--mint);
  flex: none;
}
.file-icon .icon {
  width: 14px;
  height: 14px;
}
.file-icon.dir {
  color: var(--cyan);
  border-color: rgba(110, 231, 255, 0.2);
  background: rgba(110, 231, 255, 0.04);
}

.upload-queue {
  position: fixed;
  right: 24px;
  bottom: 52px;
  z-index: 80;
  width: min(340px, calc(100vw - 32px));
  background: rgba(7, 12, 10, 0.95);
  border: 1px solid var(--line-2);
  backdrop-filter: blur(18px);
  box-shadow: 0 30px 80px -30px #000;
  animation: notice-in 0.35s var(--ease) both;
}
.upload-hd {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 10px 12px;
  border-bottom: 1px solid var(--line);
  font-family: var(--font-mono);
  font-size: 8px;
  letter-spacing: 0.16em;
  color: var(--dim);
}
.upload-hd b {
  color: var(--mint);
  font-weight: 400;
}
.upload-list {
  max-height: 220px;
  overflow: auto;
}
.upload-item {
  padding: 9px 12px;
  border-bottom: 1px solid rgba(124, 255, 214, 0.05);
}
.upload-item:last-child {
  border-bottom: 0;
}
.upload-row {
  display: flex;
  justify-content: space-between;
  gap: 8px;
  font-size: 10px;
}
.upload-name {
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}
.upload-status {
  font-family: var(--font-mono);
  font-size: 7.5px;
  color: var(--dim);
  white-space: nowrap;
}
.upload-status.done {
  color: var(--mint);
}
.upload-status.error {
  color: var(--red);
}
.upload-bar {
  height: 2px;
  margin-top: 7px;
  background: rgba(124, 255, 214, 0.08);
  overflow: hidden;
}
.upload-bar i {
  display: block;
  height: 100%;
  width: 0;
  background: var(--mint);
  box-shadow: 0 0 8px var(--mint);
  transition: width 0.18s;
}

.lightbox {
  position: fixed;
  inset: 0;
  z-index: 110;
  display: flex;
  flex-direction: column;
  background: rgba(2, 4, 3, 0.92);
  backdrop-filter: blur(12px);
  animation: fade-in 0.2s;
}
.lightbox-hd {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 14px;
  padding: 14px 20px;
  border-bottom: 1px solid var(--line);
}
.lightbox-title {
  font-family: var(--font-mono);
  font-size: 10px;
  letter-spacing: 0.1em;
  color: var(--muted);
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}
.lightbox-bd {
  flex: 1;
  display: grid;
  place-items: center;
  padding: 24px;
  overflow: auto;
}
.lightbox-bd img,
.lightbox-bd video {
  max-width: 100%;
  max-height: 100%;
  border: 1px solid var(--line);
  box-shadow: 0 30px 100px -20px #000;
}
.lightbox-bd iframe {
  min-height: 70vh;
}
.lightbox-bd pre {
  width: min(900px, 100%);
  max-height: 100%;
  overflow: auto;
  margin: 0;
  padding: 20px;
  border: 1px solid var(--line);
  background: rgba(5, 9, 7, 0.9);
  font-family: var(--font-mono);
  font-size: 11px;
  line-height: 1.7;
  color: var(--muted);
  white-space: pre-wrap;
  word-break: break-word;
}

/* --------------------------------------------------------------------------
   push
   -------------------------------------------------------------------------- */

.push-grid {
  display: grid;
  grid-template-columns: minmax(0, 1.35fr) minmax(300px, 0.65fr);
  gap: 18px;
  align-items: start;
}
.push-form {
  padding: 22px;
}
.push-form .form-grid {
  gap: 16px;
}
.composer-head {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  margin-bottom: 18px;
}
.composer-title {
  font-family: var(--font-display);
  font-size: 19px;
  font-weight: 700;
  letter-spacing: -0.01em;
}
.composer-sub {
  margin-top: 4px;
  font-family: var(--font-mono);
  font-size: 8px;
  letter-spacing: 0.16em;
  color: var(--dim);
}
.compose-actions {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  margin-top: 20px;
  padding-top: 18px;
  border-top: 1px solid var(--line);
  flex-wrap: wrap;
}
.char-count {
  font-family: var(--font-mono);
  font-size: 8px;
  color: var(--dim);
}

.level-chips {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 6px;
}
.level-chip {
  height: 36px;
  border: 1px solid var(--line);
  background: rgba(0, 0, 0, 0.18);
  color: var(--muted);
  font-family: var(--font-mono);
  font-size: 8.5px;
  letter-spacing: 0.1em;
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 7px;
  transition: 0.16s;
}
.level-chip i {
  width: 5px;
  height: 5px;
  border-radius: 50%;
  background: currentColor;
}
.level-chip:hover {
  border-color: var(--line-2);
  color: var(--text);
}
.level-chip.active {
  border-color: currentColor;
  background: rgba(255, 255, 255, 0.03);
}
.level-chip[data-level="info"].active { color: var(--cyan); }
.level-chip[data-level="success"].active { color: var(--mint); }
.level-chip[data-level="warn"].active { color: var(--amber); }
.level-chip[data-level="urgent"].active { color: var(--red); }

.sound-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 6px;
}
.sound-card {
  display: flex;
  align-items: center;
  gap: 10px;
  height: 42px;
  padding: 0 10px;
  border: 1px solid var(--line);
  background: rgba(0, 0, 0, 0.18);
  color: var(--muted);
  transition: 0.16s;
  text-align: left;
}
.sound-card:hover {
  border-color: var(--line-2);
}
.sound-card.active {
  border-color: rgba(61, 242, 189, 0.4);
  background: rgba(61, 242, 189, 0.06);
  color: var(--text);
}
.sound-card .sound-name {
  display: block;
  font-family: var(--font-mono);
  font-size: 8.5px;
  letter-spacing: 0.1em;
}
.sound-card .sound-desc {
  display: block;
  font-size: 8.5px;
  color: var(--dim);
  margin-top: 2px;
}
.sound-card .sound-wave {
  margin-left: auto;
  display: flex;
  align-items: flex-end;
  gap: 2px;
  height: 14px;
}
.sound-wave i {
  display: block;
  width: 2px;
  background: currentColor;
  opacity: 0.5;
  height: 4px;
}
.sound-card.active .sound-wave i {
  opacity: 1;
  animation: wave 0.9s ease-in-out infinite;
}
.sound-wave i:nth-child(1) { height: 5px; animation-delay: -0.2s; }
.sound-wave i:nth-child(2) { height: 11px; animation-delay: -0.5s; }
.sound-wave i:nth-child(3) { height: 7px; animation-delay: -0.1s; }
.sound-wave i:nth-child(4) { height: 14px; animation-delay: -0.7s; }
.sound-wave i:nth-child(5) { height: 6px; animation-delay: -0.3s; }

.preview-panel {
  position: sticky;
  top: calc(var(--topbar) + 18px);
}
.preview-stage {
  padding: 22px 18px;
  background:
    radial-gradient(circle at 50% 0%, rgba(61, 242, 189, 0.06), transparent 60%),
    linear-gradient(rgba(124, 255, 214, 0.03) 1px, transparent 1px),
    linear-gradient(90deg, rgba(124, 255, 214, 0.03) 1px, transparent 1px);
  background-size: auto, 20px 20px, 20px 20px;
}
.preview-label {
  display: flex;
  justify-content: space-between;
  gap: 10px;
  margin-bottom: 14px;
  font-family: var(--font-mono);
  font-size: 7.5px;
  letter-spacing: 0.16em;
  color: var(--dim);
}
.preview-window {
  position: relative;
  border: 1px solid var(--line-2);
  background: linear-gradient(155deg, rgba(13, 23, 18, 0.98), rgba(6, 10, 8, 0.98));
  box-shadow: 0 26px 60px -30px #000, 0 0 34px -20px var(--mint);
  overflow: hidden;
}
.preview-window::before {
  content: "";
  position: absolute;
  left: 0;
  top: 0;
  bottom: 0;
  width: 2px;
  background: var(--accent, var(--mint));
  box-shadow: 0 0 16px var(--accent, var(--mint));
}
.preview-hd {
  display: flex;
  align-items: center;
  gap: 7px;
  padding: 8px 11px;
  border-bottom: 1px solid var(--line);
  background: rgba(255, 255, 255, 0.02);
}
.preview-dots {
  display: flex;
  gap: 3px;
}
.preview-dots i {
  width: 4px;
  height: 4px;
  border: 1px solid var(--dim);
  border-radius: 50%;
}
.preview-kicker {
  font-family: var(--font-mono);
  font-size: 7px;
  letter-spacing: 0.16em;
  color: var(--dim);
}
.preview-level {
  margin-left: auto;
  font-family: var(--font-mono);
  font-size: 7px;
  letter-spacing: 0.08em;
  color: var(--accent, var(--mint));
  border: 1px solid currentColor;
  padding: 1px 4px;
}
.preview-bd {
  padding: 13px 14px 15px;
}
.preview-title {
  font-size: 12.5px;
  font-weight: 600;
  line-height: 1.4;
  overflow: hidden;
  text-overflow: ellipsis;
  display: -webkit-box;
  -webkit-line-clamp: 2;
  -webkit-box-orient: vertical;
}
.preview-text {
  margin-top: 5px;
  font-size: 10.5px;
  line-height: 1.6;
  color: var(--muted);
  overflow: hidden;
  display: -webkit-box;
  -webkit-line-clamp: 3;
  -webkit-box-orient: vertical;
  min-height: 32px;
}
.preview-ft {
  display: flex;
  justify-content: space-between;
  gap: 8px;
  padding: 0 14px 12px;
  font-family: var(--font-mono);
  font-size: 7px;
  letter-spacing: 0.08em;
  color: var(--dim);
}
.preview-note {
  margin-top: 14px;
  font-size: 9.5px;
  line-height: 1.65;
  color: var(--dim);
  text-align: center;
}

.history-list {
  display: flex;
  flex-direction: column;
  max-height: 340px;
  overflow: auto;
}
.history-item {
  display: grid;
  grid-template-columns: 6px minmax(0, 1fr) auto;
  gap: 10px;
  align-items: start;
  padding: 11px 18px;
  border-bottom: 1px solid rgba(124, 255, 214, 0.05);
}
.history-item:last-child {
  border-bottom: 0;
}
.history-dot {
  width: 5px;
  height: 5px;
  margin-top: 5px;
  background: var(--accent, var(--mint));
  box-shadow: 0 0 7px var(--accent, var(--mint));
}
.history-title {
  font-size: 11px;
  line-height: 1.5;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}
.history-meta {
  margin-top: 4px;
  font-family: var(--font-mono);
  font-size: 7.5px;
  color: var(--dim);
  letter-spacing: 0.05em;
}
.history-time {
  font-family: var(--font-mono);
  font-size: 7.5px;
  color: var(--dim);
  white-space: nowrap;
}

/* --------------------------------------------------------------------------
   nodes
   -------------------------------------------------------------------------- */

.join-box {
  display: flex;
  align-items: center;
  gap: 12px;
  padding: 13px 16px;
  margin-bottom: 18px;
  border: 1px solid var(--line);
  background: rgba(61, 242, 189, 0.025);
}
.join-box .join-label {
  font-family: var(--font-mono);
  font-size: 8px;
  letter-spacing: 0.18em;
  color: var(--dim);
  white-space: nowrap;
}
.join-url {
  flex: 1;
  font-family: var(--font-mono);
  font-size: 10.5px;
  color: var(--mint);
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.node-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(290px, 1fr));
  gap: 14px;
}
.node-card {
  position: relative;
  padding: 18px;
  border: 1px solid var(--line);
  background: linear-gradient(155deg, rgba(13, 22, 18, 0.85), rgba(5, 9, 7, 0.9));
  transition: border-color 0.2s, transform 0.2s;
  overflow: hidden;
}
.node-card:hover {
  border-color: rgba(61, 242, 189, 0.28);
  transform: translateY(-2px);
}
.node-card.offline {
  opacity: 0.62;
}
.node-card-hd {
  display: flex;
  align-items: flex-start;
  gap: 12px;
}
.node-avatar-lg {
  width: 42px;
  height: 42px;
  display: grid;
  place-items: center;
  flex: none;
  font-family: var(--font-mono);
  font-size: 13px;
  font-weight: 700;
  color: var(--mint);
  border: 1px solid rgba(61, 242, 189, 0.25);
  background: rgba(61, 242, 189, 0.05);
  clip-path: polygon(0 0, calc(100% - 10px) 0, 100% 10px, 100% 100%, 10px 100%, 0 calc(100% - 10px));
}
.node-name {
  font-size: 13px;
  font-weight: 600;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}
.node-id {
  margin-top: 4px;
  font-family: var(--font-mono);
  font-size: 7.5px;
  letter-spacing: 0.08em;
  color: var(--dim);
}
.node-status {
  margin-left: auto;
  display: flex;
  align-items: center;
  gap: 6px;
  font-family: var(--font-mono);
  font-size: 7.5px;
  letter-spacing: 0.1em;
  color: var(--dim);
  white-space: nowrap;
}
.node-status.online {
  color: var(--mint);
}
.node-meta {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 1px;
  margin-top: 16px;
  border: 1px solid var(--line);
  background: var(--line);
}
.node-meta div {
  padding: 8px 9px;
  background: rgba(6, 11, 9, 0.9);
}
.node-meta small {
  display: block;
  font-family: var(--font-mono);
  font-size: 7px;
  letter-spacing: 0.12em;
  color: var(--dim);
}
.node-meta b {
  display: block;
  margin-top: 4px;
  font-family: var(--font-mono);
  font-size: 8.5px;
  font-weight: 400;
  color: var(--muted);
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}
.node-actions {
  display: flex;
  gap: 7px;
  margin-top: 14px;
}
.node-actions .btn {
  flex: 1;
}

/* --------------------------------------------------------------------------
   settings
   -------------------------------------------------------------------------- */

.settings-grid {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 16px;
  align-items: start;
}
.setting-panel {
  padding: 0;
}
.setting-body {
  padding: 6px 20px 18px;
}
.setting-row {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 18px;
  padding: 14px 0;
  border-bottom: 1px solid rgba(124, 255, 214, 0.06);
}
.setting-row:last-child {
  border-bottom: 0;
}
.setting-info {
  min-width: 0;
}
.setting-label {
  font-size: 12px;
  font-weight: 500;
}
.setting-desc {
  margin-top: 4px;
  font-size: 10px;
  line-height: 1.55;
  color: var(--dim);
}
.setting-control {
  flex: none;
  display: flex;
  align-items: center;
  gap: 8px;
}
.setting-control .input {
  width: 180px;
  height: 34px;
  font-size: 11px;
}
.volume-wrap {
  display: flex;
  align-items: center;
  gap: 9px;
  width: 150px;
}
input[type="range"] {
  -webkit-appearance: none;
  width: 100%;
  height: 2px;
  background: rgba(124, 255, 214, 0.14);
  outline: none;
}
input[type="range"]::-webkit-slider-thumb {
  -webkit-appearance: none;
  width: 10px;
  height: 10px;
  background: var(--mint);
  box-shadow: 0 0 10px rgba(61, 242, 189, 0.6);
  cursor: pointer;
}
.volume-val {
  font-family: var(--font-mono);
  font-size: 8px;
  color: var(--dim);
  min-width: 26px;
  text-align: right;
}
.server-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 1px;
  background: var(--line);
  border: 1px solid var(--line);
}
.server-cell {
  padding: 11px 12px;
  background: rgba(6, 11, 9, 0.9);
  min-width: 0;
}
.server-cell small {
  display: block;
  font-family: var(--font-mono);
  font-size: 7px;
  letter-spacing: 0.14em;
  color: var(--dim);
}
.server-cell b {
  display: block;
  margin-top: 5px;
  font-family: var(--font-mono);
  font-size: 10px;
  font-weight: 400;
  color: var(--muted);
  word-break: break-all;
}
.danger-zone {
  border-color: rgba(255, 92, 122, 0.2) !important;
}
.danger-zone .panel-title::before {
  background: var(--red);
  box-shadow: 0 0 9px var(--red);
}
.key-row {
  display: flex;
  gap: 7px;
}
.key-row .input {
  flex: 1;
  width: auto;
}

/* --------------------------------------------------------------------------
   modal
   -------------------------------------------------------------------------- */

.modal-backdrop {
  position: fixed;
  inset: 0;
  z-index: 100;
  display: grid;
  place-items: center;
  padding: 20px;
  background: rgba(2, 5, 4, 0.72);
  backdrop-filter: blur(8px);
  animation: fade-in 0.2s ease both;
  overflow-y: auto;
}
.modal {
  position: relative;
  width: min(580px, 100%);
  max-height: calc(100vh - 40px);
  display: flex;
  flex-direction: column;
  background: linear-gradient(160deg, #0c1511, #060a08 75%);
  border: 1px solid var(--line-2);
  box-shadow: 0 50px 140px -40px #000, 0 0 80px -50px rgba(61, 242, 189, 0.5);
  animation: modal-in 0.36s var(--ease) both;
}
.modal::before {
  content: "";
  position: absolute;
  left: -1px;
  top: -1px;
  width: 18px;
  height: 18px;
  border-left: 1px solid var(--mint);
  border-top: 1px solid var(--mint);
}
.modal--wide {
  width: min(760px, 100%);
}
.modal-hd {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  gap: 16px;
  padding: 22px 24px 16px;
  border-bottom: 1px solid var(--line);
}
.modal-eyebrow {
  font-family: var(--font-mono);
  font-size: 8px;
  letter-spacing: 0.22em;
  color: var(--orange);
}
.modal-title {
  margin-top: 9px;
  font-family: var(--font-display);
  font-size: 24px;
  font-weight: 700;
  letter-spacing: -0.02em;
}
.modal-sub {
  margin-top: 5px;
  font-size: 10.5px;
  color: var(--dim);
  line-height: 1.6;
}
.modal-x {
  width: 30px;
  height: 30px;
  display: grid;
  place-items: center;
  flex: none;
  border: 1px solid var(--line);
  background: transparent;
  color: var(--muted);
  transition: 0.16s;
}
.modal-x:hover {
  color: var(--text);
  border-color: var(--line-2);
}
.modal-x .icon {
  width: 14px;
  height: 14px;
}
.modal-bd {
  padding: 20px 24px;
  overflow: auto;
}
.modal-ft {
  display: flex;
  align-items: center;
  justify-content: flex-end;
  gap: 8px;
  padding: 16px 24px;
  border-top: 1px solid var(--line);
  background: rgba(3, 7, 5, 0.45);
  flex-wrap: wrap;
}

.auth-lock {
  width: 54px;
  height: 54px;
  display: grid;
  place-items: center;
  margin: 0 auto 18px;
  border: 1px solid rgba(61, 242, 189, 0.3);
  color: var(--mint);
  background: rgba(61, 242, 189, 0.04);
  transform: rotate(45deg);
}
.auth-lock .icon {
  width: 20px;
  height: 20px;
  transform: rotate(-45deg);
}

/* --------------------------------------------------------------------------
   notifications / toast
   -------------------------------------------------------------------------- */

#notify-layer {
  position: fixed;
  top: 84px;
  right: 22px;
  z-index: 130;
  display: flex;
  flex-direction: column;
  gap: 11px;
  width: min(356px, calc(100vw - 28px));
  pointer-events: none;
}
.notice {
  --accent: var(--mint);
  position: relative;
  pointer-events: auto;
  overflow: hidden;
  background-image:
    linear-gradient(rgba(124, 255, 214, 0.018) 1px, transparent 1px),
    linear-gradient(90deg, rgba(124, 255, 214, 0.018) 1px, transparent 1px),
    linear-gradient(155deg, rgba(12, 23, 18, 0.97), rgba(5, 9, 7, 0.98));
  background-size: 20px 20px, 20px 20px, 100% 100%;
  border: 1px solid rgba(61, 242, 189, 0.26);
  box-shadow: inset 0 1px 0 rgba(255, 255, 255, 0.035), 0 30px 80px -24px #000, 0 0 40px -20px var(--accent);
  backdrop-filter: blur(20px);
  animation: notice-in 0.45s var(--ease) both;
}
.notice--task {
  border-color: color-mix(in srgb, var(--accent) 45%, transparent);
  box-shadow: inset 0 0 30px rgba(61, 242, 189, 0.035), 0 30px 80px -20px #000, 0 0 50px -18px var(--accent);
}
.notice--urgent {
  box-shadow: inset 0 0 34px rgba(255, 92, 122, 0.06), 0 30px 80px -20px #000, 0 0 60px -16px var(--red);
}
.notice-scan {
  position: absolute;
  left: 0;
  right: 0;
  top: -35%;
  height: 35%;
  z-index: 0;
  pointer-events: none;
  opacity: 0;
  transition: opacity 0.2s;
  background: linear-gradient(
    180deg,
    transparent 0%,
    rgba(61, 242, 189, 0.02) 32%,
    rgba(61, 242, 189, 0.1) 47%,
    rgba(61, 242, 189, 0.2) 50%,
    rgba(61, 242, 189, 0.1) 53%,
    rgba(61, 242, 189, 0.02) 68%,
    transparent 100%
  );
  mix-blend-mode: screen;
}
@media (hover: hover) {
  .notice:hover .notice-scan {
    opacity: 1;
    animation: card-scan 2.4s linear infinite;
  }
}
.notice::before {
  content: "";
  position: absolute;
  left: 0;
  top: 0;
  bottom: 0;
  width: 2px;
  background: var(--accent);
  box-shadow: 0 0 18px var(--accent);
  z-index: 2;
}
.notice::after {
  content: "";
  position: absolute;
  top: 0;
  right: 0;
  width: 42px;
  height: 42px;
  background:
    linear-gradient(225deg, color-mix(in srgb, var(--accent) 22%, transparent), transparent 62%);
  border-top: 1px solid color-mix(in srgb, var(--accent) 55%, transparent);
  border-right: 1px solid color-mix(in srgb, var(--accent) 55%, transparent);
  pointer-events: none;
  z-index: 2;
}
.notice--info { --accent: var(--cyan); border-color: rgba(110, 231, 255, 0.28); }
.notice--success { --accent: var(--mint); }
.notice--warn { --accent: var(--amber); border-color: rgba(255, 181, 71, 0.3); }
.notice--urgent { --accent: var(--red); border-color: rgba(255, 92, 122, 0.4); }
.notice-hd {
  position: relative;
  z-index: 1;
  display: flex;
  align-items: center;
  gap: 7px;
  padding: 8px 11px;
  border-bottom: 1px solid var(--line);
  background: linear-gradient(90deg, rgba(255, 255, 255, 0.035), rgba(255, 255, 255, 0.005));
  cursor: grab;
  user-select: none;
  touch-action: none;
}
.notice--task .notice-hd {
  background: linear-gradient(90deg, color-mix(in srgb, var(--accent) 12%, transparent), rgba(255, 255, 255, 0.01));
}
.notice-hd:active {
  cursor: grabbing;
}
.notice-dots {
  display: flex;
  gap: 3px;
}
.notice-dots i {
  width: 4px;
  height: 4px;
  border-radius: 50%;
  border: 1px solid var(--dim);
}
.notice-dots i:first-child {
  background: var(--accent);
  border-color: var(--accent);
  box-shadow: 0 0 6px var(--accent);
}
.notice-kicker {
  font-family: var(--font-mono);
  font-size: 7px;
  letter-spacing: 0.18em;
  color: var(--dim);
}
.notice-kind {
  font-family: var(--font-mono);
  font-size: 6.5px;
  letter-spacing: 0.14em;
  color: var(--orange);
  border: 1px solid rgba(255, 106, 43, 0.45);
  background: rgba(255, 106, 43, 0.08);
  padding: 1px 4px;
}
.notice-level {
  margin-left: auto;
  font-family: var(--font-mono);
  font-size: 7px;
  letter-spacing: 0.1em;
  color: var(--accent);
  border: 1px solid color-mix(in srgb, var(--accent) 45%, transparent);
  padding: 1px 5px;
}
.notice-x {
  width: 18px;
  height: 18px;
  display: grid;
  place-items: center;
  border: 0;
  background: transparent;
  color: var(--dim);
  padding: 0;
}
.notice-x:hover {
  color: var(--text);
}
.notice-x .icon {
  width: 11px;
  height: 11px;
}
.notice-bd {
  position: relative;
  z-index: 1;
  padding: 12px 15px 10px;
}
.notice-title {
  font-size: 13px;
  font-weight: 600;
  line-height: 1.45;
  padding-right: 10px;
  display: -webkit-box;
  -webkit-line-clamp: 2;
  -webkit-box-orient: vertical;
  overflow: hidden;
}
.notice-tags {
  display: flex;
  flex-wrap: wrap;
  gap: 5px;
  margin-top: 8px;
}
.notice-tag {
  display: inline-flex;
  align-items: center;
  gap: 5px;
  padding: 3px 6px;
  border: 1px solid color-mix(in srgb, var(--accent) 22%, transparent);
  background: rgba(0, 0, 0, 0.24);
  color: var(--muted);
  font-family: var(--font-mono);
  font-size: 8px;
  letter-spacing: 0.04em;
}
.notice-tag i {
  font-style: normal;
  font-size: 6.5px;
  letter-spacing: 0.12em;
  color: var(--dim);
}
.notice-text {
  margin-top: 7px;
  font-size: 11px;
  line-height: 1.65;
  color: var(--muted);
  word-break: break-word;
  max-height: 108px;
  overflow: auto;
}
.notice-ft {
  position: relative;
  z-index: 1;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 8px;
  padding: 0 15px 12px;
  font-family: var(--font-mono);
  font-size: 7px;
  letter-spacing: 0.08em;
  color: var(--dim);
}
.notice-ft .icon {
  width: 10px;
  height: 10px;
}
.notice-action {
  display: inline-flex;
  align-items: center;
  gap: 4px;
  background: none;
  border: 0;
  padding: 0;
  font-family: var(--font-mono);
  font-size: 7px;
  letter-spacing: 0.08em;
  color: var(--accent);
}
.notice-progress {
  position: absolute;
  left: 0;
  bottom: 0;
  height: 1px;
  width: 100%;
  background: var(--accent);
  opacity: 0.65;
  transform-origin: left;
  animation: notice-progress var(--dur, 9s) linear forwards;
}
.notice:hover .notice-progress {
  animation-play-state: paused;
}

#toast-layer {
  position: fixed;
  left: 50%;
  bottom: 54px;
  z-index: 140;
  transform: translateX(-50%);
  display: flex;
  flex-direction: column-reverse;
  gap: 8px;
  align-items: center;
  pointer-events: none;
  width: max-content;
  max-width: calc(100vw - 32px);
}
.toast {
  --accent: var(--mint);
  display: flex;
  align-items: center;
  gap: 9px;
  max-width: 100%;
  padding: 9px 14px;
  border: 1px solid rgba(61, 242, 189, 0.25);
  background: rgba(7, 13, 10, 0.96);
  backdrop-filter: blur(14px);
  box-shadow: 0 18px 50px -20px #000;
  color: var(--text);
  font-size: 11.5px;
  line-height: 1.4;
  animation: toast-in 0.3s var(--ease) both;
}
.toast .icon {
  width: 14px;
  height: 14px;
  color: var(--accent);
}
.toast--error { --accent: var(--red); border-color: rgba(255, 92, 122, 0.3); }
.toast--warn { --accent: var(--amber); border-color: rgba(255, 181, 71, 0.3); }
.toast--info { --accent: var(--cyan); border-color: rgba(110, 231, 255, 0.25); }
.toast.out {
  animation: toast-out 0.25s ease both;
}

.update-banner {
  position: fixed;
  top: 14px;
  left: 50%;
  transform: translateX(-50%);
  z-index: 150;
  display: flex;
  align-items: center;
  gap: 8px;
  padding: 8px 14px;
  border: 1px solid rgba(61, 242, 189, 0.4);
  background: rgba(5, 12, 9, 0.96);
  box-shadow: 0 0 40px -10px rgba(61, 242, 189, 0.5);
  font-family: var(--font-mono);
  font-size: 9px;
  letter-spacing: 0.12em;
  color: var(--mint);
  animation: toast-in 0.3s var(--ease) both;
}

.audio-hint {
  position: fixed;
  left: calc(var(--rail) + 24px);
  bottom: 52px;
  z-index: 85;
  display: flex;
  align-items: center;
  gap: 9px;
  padding: 9px 13px;
  border: 1px solid rgba(61, 242, 189, 0.3);
  background: rgba(6, 13, 10, 0.94);
  color: var(--muted);
  font-size: 10.5px;
  letter-spacing: 0.03em;
  backdrop-filter: blur(12px);
  box-shadow: 0 16px 40px -20px #000;
  opacity: 0;
  transform: translateY(8px);
  pointer-events: none;
  transition: 0.3s var(--ease);
}
.audio-hint.visible {
  opacity: 1;
  transform: none;
  pointer-events: auto;
}
.audio-hint .icon {
  width: 14px;
  height: 14px;
  color: var(--mint);
}

/* --------------------------------------------------------------------------
   animations
   -------------------------------------------------------------------------- */

@keyframes grid-drift {
  from { background-position: 0 0; }
  to { background-position: 74px 74px; }
}
@keyframes scan-down {
  0% { transform: translateY(-160px); opacity: 0; }
  10% { opacity: 0.8; }
  90% { opacity: 0.8; }
  100% { transform: translateY(100vh); opacity: 0; }
}
@keyframes spin {
  to { transform: rotate(360deg); }
}
@keyframes spin-rev {
  to { transform: rotate(-360deg); }
}
@keyframes core-glow {
  0%, 100% { opacity: 0.7; transform: scale(0.98); }
  50% { opacity: 1; transform: scale(1.03); }
}
@keyframes dot-pulse {
  0%, 100% { opacity: 1; }
  50% { opacity: 0.35; }
}
@keyframes boot-pulse {
  0%, 100% { box-shadow: 0 0 0 rgba(61, 242, 189, 0); }
  50% { box-shadow: 0 0 38px rgba(61, 242, 189, 0.22); }
}
@keyframes boot-scan {
  0% { top: 0; opacity: 0; }
  15% { opacity: 0.8; }
  85% { opacity: 0.8; }
  100% { top: 100%; opacity: 0; }
}
@keyframes page-in {
  0% { opacity: 0; transform: translateY(18px) scale(0.992); filter: blur(5px); }
  60% { filter: blur(0); }
  100% { opacity: 1; transform: none; filter: none; }
}
@keyframes page-out {
  from { opacity: 1; transform: none; filter: none; }
  to { opacity: 0; transform: translateY(-10px) scale(0.995); filter: blur(3px); }
}
@keyframes reveal-up {
  from { opacity: 0; transform: translateY(12px); }
  to { opacity: 1; transform: none; }
}
@keyframes panel-scan {
  0% { background-position: 0 -200px, 0 0; }
  100% { background-position: 0 calc(100% + 200px), 0 0; }
}
@keyframes card-scan {
  0% { transform: translateY(-120%); }
  100% { transform: translateY(420%); }
}
@keyframes fade-in {
  from { opacity: 0; }
  to { opacity: 1; }
}
@keyframes modal-in {
  from { opacity: 0; transform: translateY(18px) scale(0.985); }
  to { opacity: 1; transform: none; }
}
@keyframes drawer-in {
  from { transform: translateX(40px); opacity: 0; }
  to { transform: none; opacity: 1; }
}
@keyframes notice-in {
  from { opacity: 0; transform: translateX(26px) scale(0.98); filter: blur(4px); }
  to { opacity: 1; transform: none; filter: none; }
}
@keyframes toast-in {
  from { opacity: 0; transform: translateY(10px); }
  to { opacity: 1; transform: none; }
}
@keyframes toast-out {
  to { opacity: 0; transform: translateY(6px); }
}
@keyframes notice-progress {
  from { transform: scaleX(1); }
  to { transform: scaleX(0); }
}
@keyframes marquee {
  from { transform: translateX(0); }
  to { transform: translateX(-50%); }
}
@keyframes wave {
  0%, 100% { transform: scaleY(0.5); }
  50% { transform: scaleY(1); }
}

/* --------------------------------------------------------------------------
   responsive
   -------------------------------------------------------------------------- */

@media (max-width: 1240px) {
  :root { --rail: 76px; }
  .rail { padding: 22px 12px 16px; align-items: center; }
  .brand { padding: 2px 0 20px; justify-content: center; }
  .brand-text { display: none; }
  .nav { width: 100%; }
  .nav-label { display: none; }
  .nav-item { justify-content: center; height: 46px; padding: 0; }
  .nav-text, .nav-idx { display: none; }
  .nav-item .icon { width: 19px; height: 19px; }
  .rail-foot { width: 100%; }
  .node-chip { justify-content: center; padding: 6px 0; }
  .node-info { display: none; }
  .rail-admin { justify-content: center; padding: 0; }
  .rail-admin span, .rail-admin-arrow { display: none; }
  .rail-admin .icon { width: 17px; height: 17px; }
  .hero { grid-template-columns: 1fr 360px; }
}

@media (max-width: 1080px) {
  .hero { grid-template-columns: 1fr; min-height: 0; padding-top: 4px; }
  .hero-core { min-height: 300px; margin-top: 6px; }
  .core { width: 280px; }
  .core-readout { display: none; }
  .dash-grid { grid-template-columns: 1fr; }
  .dash-side { display: grid; grid-template-columns: 1fr 1fr; }
  .push-grid { grid-template-columns: 1fr; }
  .preview-panel { position: static; }
  .settings-grid { grid-template-columns: 1fr; }
  .stat-grid { grid-template-columns: 1fr 1fr; }
}

@media (max-width: 820px) {
  :root { --topbar: 62px; }
  .crumb-title, .crumb-sep { display: none; }
  .clock { display: none; }
  .link-state { padding: 0 8px; }
  .topbar { padding: 0 16px; }
  .view { padding: 20px 16px 36px; }
  .statusline { padding: 8px 16px; font-size: 7px; }
  .status-mid { display: none; }
  .status-live { display: none; }
  .dash-side { grid-template-columns: 1fr; }
  .file-grid { grid-template-columns: repeat(auto-fill, minmax(155px, 1fr)); gap: 9px; }
  .file-thumb { height: 96px; }
  .file-toolbar { align-items: flex-start; }
  .file-toolbar-actions { width: 100%; }
  .dropzone-hint { display: none; }
  .join-box { flex-wrap: wrap; }
  .join-box .btn { width: 100%; }
  .page-head { align-items: flex-start; }
  .head-actions { width: 100%; }
  .searchbox { flex: 1; }
  .searchbox input { width: 100%; }
  .level-chips { grid-template-columns: 1fr 1fr; }
  .sound-grid { grid-template-columns: 1fr; }
  .stat { min-height: 112px; padding: 15px 16px; }
  .stat-value { font-size: 30px; }
  .form-grid { grid-template-columns: 1fr; }
  .form-grid .full { grid-column: auto; }
  .server-grid { grid-template-columns: 1fr; }
  .modal-hd, .modal-bd, .modal-ft { padding-left: 18px; padding-right: 18px; }
  .drawer-hd, .drawer-bd, .drawer-ft { padding-left: 18px; padding-right: 18px; }
  #notify-layer { top: 70px; right: 14px; }
  .frame { display: none; }
  .upload-queue { right: 16px; bottom: 44px; }
  .audio-hint { display: none; }
}

@media (max-width: 620px) {
  .rail {
    position: fixed;
    inset: auto 0 0 0;
    width: 100%;
    height: 62px;
    flex-direction: row;
    align-items: center;
    padding: 0 4px;
    border-right: 0;
    border-top: 1px solid var(--line-2);
    background: rgba(5, 9, 7, 0.96);
    backdrop-filter: blur(20px);
  }
  .rail::after { display: none; }
  .brand, .rail-foot, .nav-label { display: none; }
  .nav { flex-direction: row; justify-content: space-around; margin: 0; width: 100%; gap: 0; }
  .nav-item { height: 54px; flex: 1; border: 0; flex-direction: column; gap: 3px; justify-content: center; }
  .nav-item.active { background: transparent; }
  .nav-item.active::before {
    left: 30%;
    right: 30%;
    top: auto;
    bottom: 2px;
    width: auto;
    height: 2px;
  }
  .nav-item .icon { width: 17px; height: 17px; }
  .nav-text { display: block; font-size: 8px; letter-spacing: 0; color: var(--dim); }
  .nav-item.active .nav-text { color: var(--mint); }
  .main { margin-left: 0; padding-bottom: 62px; }
  .topbar { padding: 0 14px; }
  .admin-chip span { display: none; }
  .admin-chip { padding: 0 9px; }
  .hero-title { font-size: clamp(34px, 10vw, 48px); }
  .hero-core { min-height: 250px; }
  .core { width: 230px; }
  .hero-actions .btn { flex: 1; }
  .stat-grid { grid-template-columns: 1fr 1fr; }
  .stat { min-height: 104px; }
  .stat-label { font-size: 7.5px; }
  .stat-value { font-size: 26px; margin-top: 10px; }
  .stat-foot { font-size: 7px; }
  .spark { display: none; }
  .toolbar { gap: 9px; }
  .segmented { width: 100%; overflow-x: auto; }
  .seg { flex: 1; justify-content: center; padding: 0 8px; }
  .toolbar-right { width: 100%; }
  .select-mini { flex: 1; }
  .page-title { font-size: 30px; }
  .empty { padding: 34px 16px; }
  .node-grid { grid-template-columns: 1fr; }
  .file-name { font-size: 10.5px; }
  .notice { width: 100%; }
  #notify-layer { width: calc(100vw - 24px); left: 12px; right: 12px; }
  #toast-layer { bottom: 78px; }
  .status-left .status-code, .status-left .status-sep { display: none; }
  .status-right #foot-uptime { display: none; }
  .modal-ft { justify-content: stretch; }
  .modal-ft .btn { flex: 1; }
  .drawer-ft { justify-content: stretch; }
  .drawer-ft .left, .drawer-ft .right { flex: 1; }
  .drawer-ft .btn { flex: 1; }
  .ticker { display: none; }
  .upload-queue { bottom: 74px; }
  .setting-row { flex-wrap: wrap; row-gap: 10px; }
  .setting-info { flex: 1 1 100%; }
  .setting-control { flex: 1 1 100%; justify-content: flex-start; }
  .setting-control .input { flex: 1; width: auto; min-width: 0; }
  .volume-wrap { width: 100%; max-width: 220px; }
  .key-row { width: 100%; }
}

/* --------------------------------------------------------------------------
   accessibility
   -------------------------------------------------------------------------- */

@media (hover: none) {
  .file-actions {
    opacity: 1;
    transform: none;
  }
  .row-actions {
    opacity: 1;
  }
}

@media (prefers-reduced-motion: reduce) {
  .bg-grid,
  .bg-scan {
    animation: none !important;
  }
}

body.no-motion *,
body.no-motion *::before,
body.no-motion *::after {
  animation-duration: 0.001ms !important;
  animation-iteration-count: 1 !important;
  transition-duration: 0.001ms !important;
  scroll-behavior: auto !important;
}

body.no-motion .notice-progress {
  animation-duration: var(--dur, 9s) !important;
}
