:root {
  --bg: #06080d;
  --bg-soft: #0b1017;
  --panel: rgba(12, 18, 28, 0.82);
  --panel-strong: rgba(16, 22, 34, 0.94);
  --panel-soft: rgba(255, 255, 255, 0.035);
  --border: rgba(255, 255, 255, 0.08);
  --border-strong: rgba(255, 255, 255, 0.12);
  --text: #f5f7fb;
  --muted: #9aa7bb;
  --muted-2: #758399;
  --cyan: #16d5ff;
  --cyan-soft: rgba(22, 213, 255, 0.12);
  --cyan-soft-2: rgba(22, 213, 255, 0.18);
  --danger: #ff6679;
  --danger-soft: rgba(255, 102, 121, 0.12);
  --shadow: 0 24px 80px rgba(0, 0, 0, 0.34);
  --shadow-soft: 0 12px 34px rgba(0, 0, 0, 0.22);
  --radius-xl: 28px;
  --radius-lg: 22px;
  --radius-md: 18px;
  --radius-sm: 14px;
}

* {
  box-sizing: border-box;
}

html,
body {
  margin: 0;
  padding: 0;
  min-height: 100%;
  font-family: Arial, sans-serif;
  color: var(--text);
  background:
    radial-gradient(circle at top, rgba(22, 213, 255, 0.08), transparent 28%),
    linear-gradient(180deg, #05070b 0%, #0a0f18 100%);
}

body {
  position: relative;
  overflow-x: hidden;
}

.shell {
  width: min(1320px, calc(100% - 28px));
  margin-left: auto;
  margin-right: auto;
}

.bg-grid {
  position: fixed;
  inset: 0;
  pointer-events: none;
  background-image:
    linear-gradient(rgba(255, 255, 255, 0.016) 1px, transparent 1px),
    linear-gradient(90deg, rgba(255, 255, 255, 0.016) 1px, transparent 1px);
  background-size: 28px 28px;
  mask-image: radial-gradient(circle at center, black 48%, transparent 100%);
}

.bg-glow {
  position: fixed;
  border-radius: 999px;
  filter: blur(90px);
  pointer-events: none;
  opacity: 0.22;
}

.bg-glow-1 {
  width: 260px;
  height: 260px;
  background: rgba(22, 213, 255, 0.12);
  top: 90px;
  left: -30px;
}

.bg-glow-2 {
  width: 280px;
  height: 280px;
  background: rgba(22, 213, 255, 0.08);
  right: -60px;
  top: 340px;
}

.topbar {
  margin-top: 14px;
  padding: 14px 16px;
  border-radius: 22px;
  border: 1px solid var(--border);
  background: rgba(7, 11, 18, 0.72);
  backdrop-filter: blur(14px);
  box-shadow: var(--shadow-soft);
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: 16px;
  position: sticky;
  top: 10px;
  z-index: 40;
}

.brand-wrap {
  min-width: 0;
}

.brand {
  font-size: 19px;
  font-weight: 800;
  letter-spacing: 0.14em;
}

.subtitle {
  margin-top: 3px;
  color: var(--muted);
  font-size: 12px;
}

.topbar-actions {
  display: flex;
  gap: 10px;
  flex-wrap: wrap;
}

.page {
  margin-top: 16px;
  margin-bottom: 38px;
}

.hero-card,
.panel,
.stat-card {
  border: 1px solid var(--border);
  background: var(--panel);
  backdrop-filter: blur(12px);
  box-shadow: var(--shadow-soft);
}

.hero-card {
  border-radius: var(--radius-xl);
  padding: 28px;
  display: grid;
  grid-template-columns: minmax(0, 1.4fr) 300px;
  gap: 18px;
  margin-bottom: 16px;
}

.hero-card h1 {
  margin: 0 0 10px;
  font-size: clamp(30px, 4.2vw, 54px);
  line-height: 1.02;
  letter-spacing: -0.03em;
}

.hero-card p {
  margin: 0;
  color: var(--muted);
  max-width: 720px;
  line-height: 1.6;
  font-size: 15px;
}

.hero-right {
  display: grid;
  gap: 12px;
  align-content: center;
}

.hero-stat {
  background: rgba(255, 255, 255, 0.03);
  border: 1px solid var(--border);
  border-radius: 18px;
  padding: 15px 16px;
}

.hero-stat-label {
  display: block;
  color: var(--muted-2);
  font-size: 11px;
  text-transform: uppercase;
  letter-spacing: 0.1em;
  margin-bottom: 8px;
}

.hero-stat-value {
  font-size: clamp(20px, 2vw, 34px);
  font-weight: 800;
  word-break: break-word;
  line-height: 1.15;
}

.cyan {
  color: var(--cyan);
}

.stats-grid {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: 14px;
  margin-bottom: 16px;
}

.stat-card {
  border-radius: 22px;
  padding: 18px 18px 17px;
}

.stat-label {
  color: var(--muted-2);
  font-size: 11px;
  text-transform: uppercase;
  letter-spacing: 0.1em;
  margin-bottom: 10px;
}

.stat-value {
  font-size: clamp(24px, 2.5vw, 34px);
  font-weight: 800;
  line-height: 1.1;
  word-break: break-word;
}

.center-stream-wrap {
  display: flex;
  justify-content: center;
  margin-bottom: 16px;
}

.stream-panel-centered {
  width: min(100%, 1040px);
}

.bottom-grid {
  display: grid;
  grid-template-columns: 340px minmax(0, 1fr);
  gap: 16px;
  align-items: start;
}

.sidebar,
.content {
  min-width: 0;
}

.sidebar {
  display: grid;
  gap: 16px;
}

.panel {
  border-radius: 24px;
  padding: 18px;
  min-width: 0;
}

.panel-head {
  display: flex;
  justify-content: space-between;
  align-items: flex-start;
  gap: 12px;
  margin-bottom: 16px;
}

.panel-head h2 {
  margin: 0;
  font-size: 19px;
  letter-spacing: -0.02em;
}

.panel-subtext {
  margin: 4px 0 0;
  font-size: 13px;
  color: var(--muted);
}

.stream-count {
  color: var(--muted);
  font-size: 14px;
  white-space: nowrap;
  padding-top: 3px;
}

.scan-position-box {
  background: rgba(255, 255, 255, 0.03);
  border: 1px solid var(--border);
  border-radius: 18px;
  padding: 17px;
  margin-bottom: 14px;
}

.scan-position-label {
  color: var(--muted-2);
  font-size: 11px;
  text-transform: uppercase;
  letter-spacing: 0.1em;
  margin-bottom: 8px;
}

.scan-position-value {
  color: var(--cyan);
  font-size: 19px;
  font-weight: 800;
  word-break: break-word;
  line-height: 1.25;
}

.status-strip {
  display: flex;
  align-items: flex-start;
  gap: 12px;
  background: linear-gradient(180deg, rgba(22, 213, 255, 0.12), rgba(22, 213, 255, 0.06));
  border: 1px solid rgba(22, 213, 255, 0.18);
  border-radius: 18px;
  padding: 14px;
  margin-bottom: 14px;
}

.hidden {
  display: none !important;
}

.pulse-dot {
  width: 11px;
  height: 11px;
  flex: 0 0 auto;
  border-radius: 50%;
  background: var(--cyan);
  box-shadow: 0 0 18px rgba(22, 213, 255, 0.55);
  animation: pulse 1.2s infinite;
  margin-top: 4px;
}

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

.status-title {
  font-weight: 700;
  margin-bottom: 4px;
}

.status-subtitle {
  color: var(--muted);
  font-size: 12px;
  line-height: 1.45;
  word-break: break-word;
}

.controls-stack {
  display: grid;
  gap: 10px;
}

.control-row {
  display: flex;
  gap: 10px;
}

.dual-row {
  display: grid;
  grid-template-columns: 1fr auto;
  gap: 10px;
}

input[type="number"] {
  width: 100%;
  min-width: 0;
  border-radius: 15px;
  border: 1px solid var(--border);
  background: rgba(8, 13, 20, 0.85);
  color: var(--text);
  padding: 13px 14px;
  outline: none;
  font-size: 14px;
  transition: border-color 0.15s ease, box-shadow 0.15s ease, background 0.15s ease;
}

input[type="number"]::placeholder {
  color: #7a8799;
}

input[type="number"]:focus {
  border-color: rgba(22, 213, 255, 0.42);
  box-shadow: 0 0 0 4px rgba(22, 213, 255, 0.08);
  background: rgba(11, 17, 26, 0.95);
}

.btn {
  border: 1px solid var(--border);
  border-radius: 15px;
  background: rgba(255, 255, 255, 0.03);
  color: var(--text);
  padding: 13px 15px;
  cursor: pointer;
  font-size: 13px;
  font-weight: 700;
  white-space: nowrap;
  transition: transform 0.14s ease, border-color 0.14s ease, background 0.14s ease, box-shadow 0.14s ease;
  text-decoration: none;
  display: inline-flex;
  align-items: center;
  justify-content: center;
}

.btn:hover {
  transform: translateY(-1px);
  border-color: var(--border-strong);
}

.btn-primary {
  background: linear-gradient(180deg, rgba(22, 213, 255, 0.2), rgba(22, 213, 255, 0.1));
  border-color: rgba(22, 213, 255, 0.28);
  color: #ddfbff;
  box-shadow: 0 10px 24px rgba(22, 213, 255, 0.08);
}

.btn-ghost {
  background: rgba(255, 255, 255, 0.025);
}

.btn-danger {
  background: var(--danger-soft);
  border-color: rgba(255, 102, 121, 0.18);
  color: #ffd6db;
}

.latest-panel .featured-card {
  min-height: 210px;
}

.featured-card {
  background: rgba(255, 255, 255, 0.03);
  border: 1px solid var(--border);
  border-radius: 20px;
  padding: 16px;
}

.empty-featured,
.empty-state {
  display: grid;
  place-items: center;
  text-align: center;
  color: var(--muted);
}

.empty-title {
  color: var(--text);
  font-size: 18px;
  font-weight: 700;
  margin-bottom: 8px;
}

.empty-subtitle {
  font-size: 14px;
  line-height: 1.5;
  max-width: 420px;
}

.featured-row {
  display: flex;
  gap: 14px;
  align-items: center;
}

.featured-avatar {
  width: 72px;
  height: 72px;
  object-fit: cover;
  border-radius: 50%;
  border: 2px solid rgba(22, 213, 255, 0.28);
  background: #111;
  box-shadow: 0 0 0 4px rgba(22, 213, 255, 0.05);
}

.featured-name {
  font-size: 16px;
  font-weight: 800;
  margin-bottom: 4px;
  word-break: break-word;
}

.featured-username {
  color: var(--muted);
  margin-bottom: 10px;
  word-break: break-word;
  font-size: 13px;
}

.featured-meta {
  display: grid;
  gap: 10px;
  margin-top: 16px;
}

.meta-line {
  display: flex;
  justify-content: space-between;
  gap: 14px;
  padding-top: 10px;
  border-top: 1px solid rgba(255, 255, 255, 0.06);
  font-size: 13px;
}

.meta-key {
  color: var(--muted-2);
}

.meta-value {
  text-align: right;
  word-break: break-word;
}

.stream-panel {
  min-height: 270px;
}

.empty-state {
  min-height: 190px;
}

.stream-viewport {
  width: 100%;
  overflow-x: auto;
  overflow-y: hidden;
  padding-bottom: 8px;
  min-height: 196px;
  scrollbar-width: thin;
}

.stream-viewport::-webkit-scrollbar {
  height: 10px;
}

.stream-viewport::-webkit-scrollbar-track {
  background: rgba(255, 255, 255, 0.04);
  border-radius: 999px;
}

.stream-viewport::-webkit-scrollbar-thumb {
  background: rgba(255, 255, 255, 0.16);
  border-radius: 999px;
}

.stream-row {
  display: flex;
  gap: 14px;
  align-items: stretch;
  min-height: 180px;
  min-width: fit-content;
}

.account-card {
  position: relative;
  width: 188px;
  min-width: 188px;
  flex: 0 0 188px;
  min-height: 174px;
  border-radius: 20px;
  border: 1px solid rgba(255, 255, 255, 0.07);
  background: linear-gradient(180deg, rgba(255,255,255,0.035), rgba(255,255,255,0.018));
  padding: 16px 14px 14px;
  overflow: hidden;
  box-shadow: inset 0 1px 0 rgba(255,255,255,0.03);
  cursor: pointer;
  transition: transform 0.14s ease, border-color 0.14s ease, box-shadow 0.14s ease;
}

.account-card:hover {
  transform: translateY(-2px);
  border-color: rgba(22, 213, 255, 0.22);
  box-shadow: 0 14px 28px rgba(0, 0, 0, 0.22);
}

.account-card::before {
  content: "";
  position: absolute;
  left: 0;
  top: 16px;
  bottom: 16px;
  width: 3px;
  border-radius: 999px;
  background: var(--cyan);
  opacity: 0.9;
}

.new-badge {
  position: absolute;
  right: 10px;
  top: 10px;
  padding: 4px 8px;
  border-radius: 999px;
  font-size: 10px;
  font-weight: 800;
  letter-spacing: 0.08em;
  color: #dffaff;
  background: rgba(22, 213, 255, 0.17);
  border: 1px solid rgba(22, 213, 255, 0.2);
}

.avatar {
  width: 44px;
  height: 44px;
  object-fit: cover;
  border-radius: 50%;
  display: block;
  background: #11141b;
  border: 1px solid rgba(255,255,255,0.08);
  margin-bottom: 12px;
}

.account-name {
  font-size: 15px;
  font-weight: 800;
  margin-bottom: 3px;
  word-break: break-word;
}

.account-username,
.account-id,
.account-created,
.account-status {
  color: var(--muted);
  font-size: 12px;
  line-height: 1.42;
  word-break: break-word;
}

.account-status {
  margin-top: 7px;
}

.status-pill {
  display: inline-flex;
  align-items: center;
  width: fit-content;
  padding: 6px 10px;
  border-radius: 999px;
  font-size: 11px;
  font-weight: 800;
}

.status-active {
  background: rgba(22, 213, 255, 0.14);
  color: #dffaff;
  border: 1px solid rgba(22, 213, 255, 0.18);
}

.status-banned {
  background: rgba(255, 102, 121, 0.12);
  color: #ffd6db;
  border: 1px solid rgba(255, 102, 121, 0.18);
}

.status-deleted {
  background: rgba(255, 255, 255, 0.07);
  color: #f0f3f7;
  border: 1px solid rgba(255, 255, 255, 0.12);
}

.modal {
  position: fixed;
  inset: 0;
  z-index: 100;
  display: grid;
  place-items: center;
  padding: 20px;
}

.modal-backdrop {
  position: absolute;
  inset: 0;
  background: rgba(3, 6, 10, 0.7);
  backdrop-filter: blur(8px);
}

.modal-card {
  position: relative;
  z-index: 1;
  width: min(100%, 560px);
  border-radius: 24px;
  border: 1px solid rgba(255, 255, 255, 0.1);
  background: rgba(12, 18, 28, 0.96);
  box-shadow: 0 30px 90px rgba(0, 0, 0, 0.45);
  padding: 24px;
}

.modal-close {
  position: absolute;
  top: 12px;
  right: 12px;
  width: 38px;
  height: 38px;
  border: 1px solid rgba(255, 255, 255, 0.1);
  background: rgba(255, 255, 255, 0.04);
  color: var(--text);
  border-radius: 999px;
  font-size: 24px;
  cursor: pointer;
  line-height: 1;
}

.modal-top {
  display: flex;
  gap: 16px;
  align-items: center;
  padding-right: 36px;
}

.modal-avatar {
  width: 88px;
  height: 88px;
  border-radius: 50%;
  object-fit: cover;
  border: 2px solid rgba(22, 213, 255, 0.28);
  background: #111;
}

.modal-top-copy {
  min-width: 0;
}

.modal-display-name {
  font-size: 24px;
  font-weight: 800;
  line-height: 1.1;
  margin-bottom: 6px;
  word-break: break-word;
}

.modal-username {
  color: var(--muted);
  margin-bottom: 12px;
  word-break: break-word;
}

.modal-meta {
  display: grid;
  gap: 10px;
  margin-top: 22px;
}

.modal-line {
  display: flex;
  justify-content: space-between;
  gap: 16px;
  padding-top: 10px;
  border-top: 1px solid rgba(255, 255, 255, 0.06);
}

.modal-key {
  color: var(--muted-2);
  font-size: 14px;
}

.modal-value {
  text-align: right;
  font-size: 14px;
  word-break: break-word;
}

.modal-small {
  font-size: 12px;
}

.modal-actions {
  margin-top: 20px;
  display: flex;
  justify-content: flex-end;
}

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

@media (max-width: 1120px) {
  .hero-card,
  .bottom-grid {
    grid-template-columns: 1fr;
  }

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

  .hero-card {
    padding: 24px;
  }
}

@media (max-width: 700px) {
  .shell {
    width: min(100% - 18px, 1320px);
  }

  .topbar {
    padding: 14px;
    top: 8px;
  }

  .stats-grid {
    grid-template-columns: 1fr;
  }

  .topbar-actions,
  .control-row,
  .dual-row {
    flex-direction: column;
    display: flex;
  }

  .btn,
  input[type="number"] {
    width: 100%;
  }

  .featured-row,
  .modal-top {
    align-items: flex-start;
    flex-direction: column;
  }

  .hero-card {
    padding: 20px;
  }

  .panel {
    padding: 16px;
  }

  .modal-card {
    padding: 18px;
  }

  .modal-line {
    flex-direction: column;
    gap: 6px;
  }

  .modal-value {
    text-align: left;
  }
}
