:root {
  --bg: #05070a;
  --surface: rgba(9, 13, 16, 0.78);
  --surface-2: rgba(13, 18, 22, 0.64);
  --line: rgba(152, 182, 194, 0.16);
  --line-strong: rgba(188, 218, 228, 0.3);
  --text: #eef4f5;
  --muted: #93a7ae;
  --dim: #5d7079;
  --red: #ff4d3d;
  --cyan: #3cdbd0;
  --green: #8be37b;
  --amber: #f2b544;
  --blue: #4d8bff;
}

* {
  box-sizing: border-box;
}

html,
body {
  margin: 0;
  min-height: 100%;
}

body {
  background: var(--bg) fixed center/cover no-repeat url("/assets/backdrop.png");
  color: var(--text);
  font-family: "Avenir Next", "PingFang SC", "Hiragino Sans GB", "Microsoft YaHei", sans-serif;
  overflow-x: hidden;
}

body::after {
  content: "";
  position: fixed;
  inset: 0;
  z-index: 0;
  pointer-events: none;
  background: linear-gradient(180deg, rgba(3, 5, 7, 0.62), rgba(3, 5, 7, 0.3) 46%, rgba(3, 5, 7, 0.72));
}

.scanline {
  position: fixed;
  inset: 0;
  z-index: 20;
  overflow: hidden;
  pointer-events: none;
  background: repeating-linear-gradient(
    0deg,
    rgba(255, 255, 255, 0.022) 0 1px,
    transparent 1px 3px
  );
  mix-blend-mode: screen;
}

.scanline::after {
  content: "";
  position: absolute;
  left: 0;
  right: 0;
  top: -22%;
  height: 130px;
  background: linear-gradient(180deg, transparent, rgba(60, 219, 208, 0.05), transparent);
  animation: scan 9s linear infinite;
}

@keyframes scan {
  from {
    transform: translateY(0);
  }
  to {
    transform: translateY(140vh);
  }
}

.page {
  position: relative;
  z-index: 1;
  display: flex;
  flex-direction: column;
  width: min(100%, 1440px);
  min-height: 100vh;
  margin: 0 auto;
  padding: 0 clamp(16px, 4vw, 52px) 18px;
}

.mast {
  display: flex;
  align-items: center;
  justify-content: space-between;
  flex-wrap: wrap;
  gap: 12px 22px;
  padding: 18px 0 14px;
  border-bottom: 1px solid var(--line);
}

.brand {
  display: flex;
  align-items: center;
  gap: 12px;
  color: var(--text);
  text-decoration: none;
}

.brand-mark {
  display: grid;
  grid-template-columns: auto auto;
  align-items: center;
  justify-content: center;
  gap: 5px;
  width: 42px;
  height: 42px;
  flex: none;
  border: 1px solid var(--line-strong);
  border-radius: 6px;
  background: rgba(5, 8, 10, 0.72);
  box-shadow: 0 0 22px rgba(61, 219, 208, 0.12), inset 0 1px 0 rgba(255, 255, 255, 0.04);
  transform: rotate(-3deg);
}

.brand-mark span:first-child {
  font-family: ui-monospace, SFMono-Regular, Menlo, monospace;
  font-size: 15px;
  font-weight: 800;
  line-height: 1;
}

.brand-mark i {
  width: 5px;
  height: 5px;
  border-radius: 50%;
  background: var(--red);
  box-shadow: 0 0 9px var(--red);
}

.brand-mark span:last-child {
  font-family: ui-monospace, SFMono-Regular, Menlo, monospace;
  font-size: 8px;
  letter-spacing: 0.08em;
  color: var(--cyan);
}

.brand-copy strong {
  display: block;
  font-size: 16px;
  line-height: 1.05;
  letter-spacing: 0.04em;
}

.brand-copy small {
  display: block;
  margin-top: 4px;
  font-family: ui-monospace, SFMono-Regular, Menlo, monospace;
  font-size: 9px;
  letter-spacing: 0.2em;
  color: var(--dim);
}

.mast-identity {
  display: flex;
  align-items: center;
  gap: 12px;
  font-family: ui-monospace, SFMono-Regular, Menlo, monospace;
  font-size: 11px;
  letter-spacing: 0.08em;
}

.handle {
  color: var(--muted);
}

.online {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  padding-left: 12px;
  border-left: 1px solid var(--line);
  color: var(--green);
}

.online i {
  width: 6px;
  height: 6px;
  border-radius: 50%;
  background: var(--green);
  box-shadow: 0 0 9px var(--green);
  animation: pulse 1.8s ease-in-out infinite;
}

@keyframes pulse {
  0%,
  100% {
    opacity: 1;
    transform: scale(1);
  }
  50% {
    opacity: 0.55;
    transform: scale(0.78);
  }
}

.mast-stats {
  display: flex;
  align-items: center;
  gap: 22px;
}

.stat {
  display: flex;
  flex-direction: column;
  align-items: flex-end;
  min-width: 54px;
}

.stat b {
  font-family: ui-monospace, SFMono-Regular, Menlo, monospace;
  font-size: 18px;
  line-height: 1.05;
}

.stat span {
  margin-top: 4px;
  font-family: ui-monospace, SFMono-Regular, Menlo, monospace;
  font-size: 9px;
  letter-spacing: 0.16em;
  color: var(--dim);
}

.mast-clock {
  display: grid;
  grid-template-columns: auto auto auto auto;
  align-items: baseline;
  gap: 4px 10px;
}

.clock-label {
  font-family: ui-monospace, SFMono-Regular, Menlo, monospace;
  font-size: 9px;
  letter-spacing: 0.14em;
  color: var(--dim);
}

.mast-clock b {
  font-family: ui-monospace, SFMono-Regular, Menlo, monospace;
  font-size: 13px;
  letter-spacing: 0.04em;
  color: var(--text);
}

.ticker {
  display: flex;
  align-items: center;
  gap: 18px;
  margin-top: 12px;
  padding: 8px 0;
  overflow: hidden;
  border-bottom: 1px solid var(--line);
  white-space: nowrap;
}

.ticker-item {
  font-family: ui-monospace, SFMono-Regular, Menlo, monospace;
  font-size: 10px;
  letter-spacing: 0.14em;
  color: var(--dim);
}

.ticker-item--live {
  display: inline-flex;
  align-items: center;
  gap: 7px;
  color: var(--green);
}

.ticker-item--live i {
  width: 5px;
  height: 5px;
  border-radius: 50%;
  background: var(--green);
  box-shadow: 0 0 8px var(--green);
}

.meter {
  display: flex;
  align-items: flex-end;
  gap: 4px;
  height: 18px;
  margin-left: auto;
}

.meter i {
  display: block;
  width: 3px;
  height: 6px;
  border-radius: 1px;
  background: var(--cyan);
  transform-origin: bottom;
  animation: bars 1.2s ease-in-out infinite alternate;
}

.meter i:nth-child(2n) {
  background: var(--red);
  animation-delay: -0.4s;
}

.meter i:nth-child(3n) {
  background: var(--green);
  animation-delay: -0.8s;
}

.meter i:nth-child(4n) {
  animation-delay: -0.2s;
}

.meter i:nth-child(6n) {
  animation-delay: -0.6s;
}

@keyframes bars {
  from {
    transform: scaleY(0.35);
  }
  to {
    transform: scaleY(1);
  }
}

.workspace {
  display: grid;
  grid-template-columns: minmax(270px, 320px) minmax(0, 1fr);
  align-items: start;
  gap: 20px;
  padding: 22px 0 32px;
}

.profile {
  position: relative;
  overflow: hidden;
  padding: 18px;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: linear-gradient(180deg, rgba(10, 15, 18, 0.84), rgba(6, 9, 12, 0.72));
  box-shadow: 0 18px 46px rgba(0, 0, 0, 0.26), inset 0 1px 0 rgba(255, 255, 255, 0.04);
  backdrop-filter: blur(16px);
  -webkit-backdrop-filter: blur(16px);
}

.profile::before {
  content: "";
  position: absolute;
  top: 0;
  left: 0;
  right: 0;
  height: 1px;
  background: linear-gradient(90deg, transparent, rgba(60, 219, 208, 0.55), transparent);
  opacity: 0.6;
}

.profile-top {
  display: flex;
  align-items: center;
  gap: 14px;
}

.avatar {
  width: 66px;
  height: 66px;
  flex: none;
  object-fit: cover;
  border: 1px solid var(--line-strong);
  border-radius: 6px;
  background: var(--surface-2);
  box-shadow: 0 0 0 3px rgba(60, 219, 208, 0.08), 0 10px 24px rgba(0, 0, 0, 0.25);
}

.profile-name {
  min-width: 0;
}

.profile-name strong {
  display: block;
  font-size: 17px;
  line-height: 1.2;
}

.profile-name span {
  display: block;
  margin-top: 4px;
  font-family: ui-monospace, SFMono-Regular, Menlo, monospace;
  font-size: 11px;
  letter-spacing: 0.06em;
  color: var(--cyan);
}

.profile-bio {
  margin: 15px 0 0;
  color: var(--muted);
  font-size: 13px;
  line-height: 1.65;
}

.profile-stats {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  margin-top: 15px;
  padding: 13px 0;
  border-top: 1px solid var(--line);
  border-bottom: 1px solid var(--line);
}

.profile-stats div {
  display: flex;
  flex-direction: column;
  gap: 4px;
  min-width: 0;
}

.profile-stats div + div {
  padding-left: 14px;
  border-left: 1px solid var(--line);
}

.profile-stats b {
  font-family: ui-monospace, SFMono-Regular, Menlo, monospace;
  font-size: 17px;
  line-height: 1.1;
}

.profile-stats span {
  font-size: 10px;
  letter-spacing: 0.1em;
  color: var(--dim);
}

.quick-grid {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 8px;
  margin-top: 14px;
}

.quick-btn {
  display: flex;
  align-items: center;
  gap: 8px;
  height: 46px;
  min-width: 0;
  padding: 0 12px;
  border: 1px solid var(--line);
  border-radius: 6px;
  background: rgba(255, 255, 255, 0.025);
  color: var(--text);
  font-size: 12px;
  text-decoration: none;
  transition: border-color 0.16s ease, background 0.16s ease, transform 0.16s ease;
}

.quick-btn i,
.quick-btn svg {
  width: 15px;
  height: 15px;
  flex: none;
  color: var(--accent);
}

.quick-btn span {
  overflow: hidden;
  white-space: nowrap;
  text-overflow: ellipsis;
}

.quick-btn:hover {
  border-color: var(--accent);
  background: var(--accent-soft);
  transform: translateY(-1px);
}

.profile-sig {
  display: grid;
  grid-template-columns: repeat(12, 1fr);
  align-items: end;
  gap: 4px;
  height: 26px;
  margin-top: 16px;
  opacity: 0.55;
}

.profile-sig span {
  height: 8px;
  border-radius: 1px;
  background: var(--cyan);
  transform-origin: bottom;
  animation: sig 1.8s ease-in-out infinite alternate;
}

.profile-sig span:nth-child(2n) {
  background: var(--red);
  animation-delay: -0.5s;
}

.profile-sig span:nth-child(3n) {
  background: var(--green);
  animation-delay: -0.9s;
}

.profile-sig span:nth-child(4n) {
  height: 15px;
}

.profile-sig span:nth-child(7n) {
  height: 21px;
}

.profile-sig span:nth-child(10n) {
  height: 12px;
}

@keyframes sig {
  from {
    transform: scaleY(0.45);
  }
  to {
    transform: scaleY(1);
  }
}

.index {
  min-width: 0;
}

.index-head {
  display: flex;
  align-items: flex-end;
  justify-content: space-between;
  gap: 18px;
  padding: 2px 4px 17px;
  border-bottom: 1px solid var(--line);
}

.eyebrow {
  display: block;
  font-family: ui-monospace, SFMono-Regular, Menlo, monospace;
  font-size: 10px;
  letter-spacing: 0.22em;
  color: var(--cyan);
}

.index-head h1 {
  margin: 9px 0 8px;
  font-size: clamp(26px, 3vw, 34px);
  line-height: 1.04;
  letter-spacing: 0;
  text-shadow: 0 0 30px rgba(60, 219, 208, 0.14);
}

.index-head p {
  margin: 0;
  color: var(--muted);
  font-size: 13px;
  line-height: 1.55;
}

.index-count {
  display: flex;
  align-items: baseline;
  gap: 9px;
  flex: none;
  font-family: ui-monospace, SFMono-Regular, Menlo, monospace;
}

.index-count b {
  font-size: clamp(34px, 5vw, 46px);
  line-height: 0.9;
}

.index-count span {
  color: var(--dim);
  font-size: 14px;
}

.toolbar {
  display: flex;
  flex-direction: column;
  gap: 11px;
  padding: 14px 4px 8px;
}

.search {
  display: flex;
  align-items: center;
  gap: 10px;
  height: 46px;
  padding: 0 12px;
  border: 1px solid var(--line);
  border-radius: 6px;
  background: rgba(7, 10, 13, 0.7);
  color: var(--muted);
  transition: border-color 0.16s ease, box-shadow 0.16s ease;
}

.search:focus-within {
  border-color: rgba(60, 219, 208, 0.5);
  box-shadow: 0 0 0 3px rgba(60, 219, 208, 0.08);
}

.search i,
.search svg {
  width: 17px;
  height: 17px;
  flex: none;
  color: var(--cyan);
}

.search input {
  flex: 1;
  min-width: 0;
  height: 100%;
  border: 0;
  outline: 0;
  background: transparent;
  color: var(--text);
  font: inherit;
  font-size: 14px;
}

.search input::placeholder {
  color: var(--dim);
}

.icon-button {
  display: grid;
  place-items: center;
  width: 30px;
  height: 30px;
  flex: none;
  padding: 0;
  border: 1px solid transparent;
  border-radius: 6px;
  background: transparent;
  color: var(--muted);
  cursor: pointer;
  transition: color 0.16s ease, background 0.16s ease;
}

.icon-button:hover {
  background: rgba(255, 255, 255, 0.06);
  color: var(--text);
}

.icon-button svg,
.icon-button i {
  width: 15px;
  height: 15px;
}

.filters {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
}

.filter-btn {
  display: inline-flex;
  align-items: center;
  height: 32px;
  padding: 0 13px;
  border: 1px solid var(--line);
  border-radius: 6px;
  background: rgba(255, 255, 255, 0.02);
  color: var(--muted);
  font: inherit;
  font-size: 12px;
  white-space: nowrap;
  cursor: pointer;
  transition: color 0.16s ease, background 0.16s ease, border-color 0.16s ease;
}

.filter-btn:hover {
  color: var(--text);
  border-color: var(--line-strong);
}

.filter-btn.active {
  background: var(--cyan);
  border-color: var(--cyan);
  color: #051013;
  font-weight: 700;
}

.signal-list {
  display: flex;
  flex-direction: column;
  margin-top: 4px;
}

.card {
  display: grid;
  grid-template-columns: 44px minmax(0, 1fr) 28px;
  align-items: center;
  gap: 13px;
  min-height: 78px;
  padding: 13px 8px;
  border-bottom: 1px solid var(--line);
  color: var(--text);
  text-decoration: none;
  transition: background 0.16s ease;
}

.card:hover {
  background: linear-gradient(90deg, var(--accent-soft), transparent 72%);
}

.card-icon {
  display: grid;
  place-items: center;
  width: 40px;
  height: 40px;
  border: 1px solid var(--accent);
  border-radius: 6px;
  background: var(--accent-soft);
  color: var(--accent);
  box-shadow: 0 0 20px var(--accent-soft);
}

.card-icon i,
.card-icon svg {
  width: 18px;
  height: 18px;
}

.card-copy {
  min-width: 0;
}

.card-copy strong {
  display: block;
  font-size: 15px;
  line-height: 1.3;
}

.card-copy p {
  display: -webkit-box;
  overflow: hidden;
  margin: 3px 0 7px;
  color: var(--muted);
  font-size: 12.5px;
  line-height: 1.5;
  -webkit-box-orient: vertical;
  -webkit-line-clamp: 2;
}

.card-tags {
  display: flex;
  flex-wrap: wrap;
  gap: 6px;
}

.card-tags span {
  padding: 2px 6px;
  border: 1px solid var(--accent);
  border-radius: 4px;
  background: var(--accent-soft);
  color: var(--accent);
  font-family: ui-monospace, SFMono-Regular, Menlo, monospace;
  font-size: 9px;
  letter-spacing: 0.08em;
  white-space: nowrap;
}

.card-arrow {
  display: grid;
  place-items: center;
  width: 28px;
  height: 28px;
  color: var(--dim);
  transition: color 0.16s ease, transform 0.16s ease;
}

.card-arrow svg,
.card-arrow i {
  width: 17px;
  height: 17px;
}

.card:hover .card-arrow {
  color: var(--accent);
  transform: translate(2px, -2px);
}

.empty-state {
  padding: 46px 12px;
  border: 1px dashed var(--line);
  border-radius: 6px;
  color: var(--muted);
  font-family: ui-monospace, SFMono-Regular, Menlo, monospace;
  font-size: 12px;
  letter-spacing: 0.16em;
  text-align: center;
}

.empty-state[hidden] {
  display: none;
}

.footer {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  margin-top: auto;
  padding: 14px 0 18px;
  border-top: 1px solid var(--line);
  color: var(--dim);
  font-family: ui-monospace, SFMono-Regular, Menlo, monospace;
  font-size: 10px;
  letter-spacing: 0.16em;
}

.footer a {
  display: inline-flex;
  align-items: center;
  gap: 7px;
  color: var(--cyan);
  text-decoration: none;
}

.footer a svg,
.footer a i {
  width: 13px;
  height: 13px;
}

@media (max-width: 980px) {
  .workspace {
    grid-template-columns: minmax(0, 1fr);
  }

  .profile {
    display: grid;
    grid-template-columns: minmax(0, 1fr) minmax(0, 1fr);
    gap: 0 20px;
  }

  .profile-top,
  .profile-bio {
    grid-column: 1 / -1;
  }

  .profile-bio {
    margin-top: 13px;
  }

  .quick-grid {
    align-self: center;
  }

  .profile-sig {
    grid-column: 1 / -1;
  }
}

@media (max-width: 720px) {
  .mast {
    display: grid;
    grid-template-columns: minmax(0, 1fr) auto;
    gap: 12px 14px;
  }

  .brand {
    min-width: 0;
  }

  .mast-identity {
    justify-self: end;
  }

  .mast-stats {
    gap: 14px;
  }

  .mast-clock {
    grid-column: 1 / -1;
    justify-self: start;
  }

  .ticker {
    gap: 14px;
    overflow-x: auto;
    scrollbar-width: none;
  }

  .ticker::-webkit-scrollbar {
    display: none;
  }

  .meter {
    display: none;
  }

  .profile {
    padding: 15px;
  }

  .index-head {
    align-items: center;
  }

  .index-head h1 {
    margin-top: 7px;
  }

  .index-head p {
    max-width: 46ch;
  }
}

@media (max-width: 520px) {
  .page {
    padding: 0 13px 14px;
  }

  .mast {
    grid-template-columns: minmax(0, 1fr);
  }

  .mast-identity,
  .mast-stats {
    justify-self: start;
  }

  .mast-stats {
    width: 100%;
    justify-content: space-between;
  }

  .mast-clock {
    width: 100%;
  }

  .profile {
    display: block;
  }

  .index-head {
    align-items: flex-start;
    flex-direction: column;
    gap: 10px;
  }

  .index-count {
    align-self: flex-end;
    margin-top: -8px;
  }

  .card {
    grid-template-columns: 42px minmax(0, 1fr) 22px;
    gap: 10px;
    padding: 12px 3px;
  }

  .card-icon {
    width: 38px;
    height: 38px;
  }

  .card-copy strong {
    font-size: 14px;
  }

  .footer {
    align-items: flex-start;
    flex-direction: column;
  }
}

@media (prefers-reduced-motion: reduce) {
  *,
  *::before,
  *::after {
    animation: none !important;
    transition: none !important;
  }
}
