:root {
  --bg: #05060f;
  --text: #ffffff;
  --muted: rgba(255, 255, 255, 0.7);
  --glass: rgba(255, 255, 255, 0.03);
  --border: rgba(255, 255, 255, 0.15);
  --accent-from: #7dd3fc;
  --accent-via: #60a5fa;
  --accent-to: #2563eb;
  --indigo-glow: rgba(129, 140, 248, 0.5);
  --danger: #f87171;
  --ok: #86efac;
  --online: #4ade80;
}

* {
  box-sizing: border-box;
}

html, body {
  margin: 0;
  min-height: 100%;
  background: var(--bg);
  color: var(--text);
  font-family: "Segoe UI", "Helvetica Neue", sans-serif;
}

button, input, textarea {
  font: inherit;
  color: inherit;
}

a {
  color: inherit;
  text-decoration: none;
}

.hidden {
  display: none !important;
}

.sky {
  position: relative;
  min-height: 100vh;
  overflow: hidden;
}

.sky-bg {
  position: absolute;
  inset: 0;
  background: url('/space-bg.jpg') center / cover no-repeat;
}

.sky-veil {
  position: absolute;
  inset: 0;
  background: rgba(0, 0, 0, 0.4);
}

.stars {
  pointer-events: none;
  position: absolute;
  inset: 0;
  overflow: hidden;
}

.star {
  position: absolute;
  border-radius: 999px;
  background: #fff;
  animation: twinkle 3s ease-in-out infinite;
}

.shoot {
  position: absolute;
  animation-name: shoot;
  animation-iteration-count: infinite;
  animation-timing-function: ease-in;
}

.shoot-trail {
  display: block;
  height: 2px;
  width: 6rem;
  border-radius: 999px;
  background: linear-gradient(to right, #fff, rgba(255, 255, 255, 0.7), transparent);
  box-shadow: 0 0 8px 2px rgba(255, 255, 255, 0.7);
}

@keyframes twinkle {
  0%, 100% { opacity: 0.2; }
  50% { opacity: 1; }
}

@keyframes shoot {
  0% {
    transform: translate3d(0, 0, 0) rotate(215deg);
    opacity: 0;
  }
  10% { opacity: 1; }
  70% { opacity: 1; }
  100% {
    transform: translate3d(-800px, 800px, 0) rotate(215deg);
    opacity: 0;
  }
}

.glass-nav {
  position: relative;
  z-index: 10;
  margin: 1rem 1rem 0;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 1rem;
  overflow: hidden;
  border-radius: 1rem;
  border: 1px solid var(--border);
  background: var(--glass);
  padding: 0.75rem 1rem;
  box-shadow:
    0 20px 50px rgba(0, 0, 0, 0.5),
    inset 0 1px 1px rgba(255, 255, 255, 0.1);
  backdrop-filter: blur(40px);
}

@media (min-width: 768px) {
  .glass-nav {
    margin: 1.5rem 2rem 0;
    padding: 0.875rem 1.5rem;
  }
}

.nav-sheen {
  pointer-events: none;
  position: absolute;
  inset: 0;
  background: linear-gradient(to bottom, rgba(255, 255, 255, 0.1), transparent);
}

.brand {
  position: relative;
  z-index: 1;
  font-size: 1.05rem;
  font-weight: 600;
  letter-spacing: 0.04em;
}

.nav-tabs {
  position: relative;
  z-index: 1;
  display: flex;
  gap: 0.25rem;
  list-style: none;
  margin: 0;
  padding: 0.25rem;
  border-radius: 0.75rem;
  border: 1px solid rgba(255, 255, 255, 0.05);
  background: rgba(255, 255, 255, 0.02);
}

.nav-tabs a {
  position: relative;
  display: block;
  border-radius: 0.5rem;
  padding: 0.4rem 0.9rem;
  font-size: 0.875rem;
  font-weight: 500;
  transition: background 0.2s ease;
}

.nav-tabs a:hover {
  background: rgba(255, 255, 255, 0.05);
}

.nav-tabs a.active::before {
  content: "";
  position: absolute;
  inset: 0;
  border-radius: 0.5rem;
  border: 1px solid rgba(255, 255, 255, 0.1);
  background: rgba(255, 255, 255, 0.1);
  box-shadow: inset 0 1px 1px rgba(255, 255, 255, 0.1);
}

.nav-tabs a span {
  position: relative;
  z-index: 1;
}

.nav-logout {
  position: relative;
  z-index: 1;
  border: 1px solid rgba(255, 255, 255, 0.15);
  background: rgba(255, 255, 255, 0.05);
  border-radius: 0.6rem;
  padding: 0.4rem 0.85rem;
  font-size: 0.8rem;
  cursor: pointer;
  transition: background 0.2s ease;
}

.nav-logout:hover {
  background: rgba(255, 255, 255, 0.1);
}

.nav-glow {
  position: absolute;
  bottom: 0;
  left: 50%;
  width: 33%;
  height: 1px;
  transform: translateX(-50%);
  background: linear-gradient(to right, transparent, var(--indigo-glow), transparent);
}

.stage {
  position: relative;
  z-index: 10;
  max-width: 56rem;
  margin: 0 auto;
  padding: 3.5rem 1.5rem 6rem;
}

.panel {
  display: flex;
  flex-direction: column;
  align-items: center;
  text-align: center;
  animation: rise 0.55s ease both;
}

@keyframes rise {
  from {
    opacity: 0;
    transform: translateY(12px);
  }
  to {
    opacity: 1;
    transform: translateY(0);
  }
}

.hero-title {
  margin: 0;
  font-size: clamp(2.75rem, 8vw, 5.5rem);
  font-weight: 700;
  letter-spacing: -0.03em;
  line-height: 1.05;
  background: linear-gradient(to bottom, var(--accent-from), var(--accent-via), var(--accent-to));
  -webkit-background-clip: text;
  background-clip: text;
  color: transparent;
  filter: drop-shadow(0 0 30px rgba(59, 130, 246, 0.5));
}

.hero-title--sm {
  font-size: clamp(2rem, 5vw, 3.25rem);
  text-align: left;
}

.hero-sub {
  margin: 1.1rem 0 0;
  max-width: 28rem;
  font-size: 1.1rem;
  color: var(--muted);
}

.dash-head {
  width: 100%;
  display: flex;
  flex-wrap: wrap;
  align-items: flex-end;
  justify-content: space-between;
  gap: 1rem;
  text-align: left;
  margin-bottom: 1.75rem;
}

.dash-head .hero-sub {
  text-align: left;
}

.welcome {
  margin: 0;
  color: rgba(255, 255, 255, 0.55);
  font-size: 0.95rem;
}

.glass-card {
  position: relative;
  width: 100%;
  max-width: 28rem;
  margin-top: 2.5rem;
  overflow: hidden;
  border-radius: 1rem;
  border: 1px solid var(--border);
  background: var(--glass);
  padding: 2rem;
  text-align: left;
  box-shadow:
    0 20px 50px rgba(0, 0, 0, 0.5),
    inset 0 1px 1px rgba(255, 255, 255, 0.1);
  backdrop-filter: blur(40px);
}

.card-sheen {
  pointer-events: none;
  position: absolute;
  inset: 0;
  background: linear-gradient(to bottom, rgba(255, 255, 255, 0.1), transparent);
}

.card-glow {
  position: absolute;
  bottom: 0;
  left: 50%;
  width: 33%;
  height: 1px;
  transform: translateX(-50%);
  background: linear-gradient(to right, transparent, var(--indigo-glow), transparent);
}

.glass-card h2,
.glass-card label,
.glass-card button,
.glass-card p {
  position: relative;
  z-index: 1;
}

.glass-card h2 {
  margin: 0 0 1.25rem;
  font-size: 1.35rem;
  font-weight: 600;
}

.form-card label {
  display: block;
  margin-bottom: 1rem;
}

.form-card label span {
  display: block;
  margin-bottom: 0.4rem;
  font-size: 0.85rem;
  color: rgba(255, 255, 255, 0.65);
}

.form-card label em {
  font-style: normal;
  opacity: 0.55;
}

.form-card input,
.form-card textarea {
  width: 100%;
  border-radius: 0.65rem;
  border: 1px solid rgba(255, 255, 255, 0.14);
  background: rgba(0, 0, 0, 0.35);
  padding: 0.7rem 0.85rem;
  outline: none;
  transition: border-color 0.2s ease, box-shadow 0.2s ease;
}

.form-card input:focus,
.form-card textarea:focus {
  border-color: rgba(96, 165, 250, 0.55);
  box-shadow: 0 0 0 3px rgba(59, 130, 246, 0.15);
}

.form-row {
  display: grid;
  gap: 0.75rem;
}

@media (min-width: 640px) {
  .form-row {
    grid-template-columns: 1fr 1fr;
  }
}

.btn-primary {
  width: 100%;
  margin-top: 0.35rem;
  border: 0;
  border-radius: 0.7rem;
  padding: 0.8rem 1rem;
  font-weight: 600;
  cursor: pointer;
  color: #061018;
  background: linear-gradient(135deg, #93c5fd, #60a5fa 45%, #3b82f6);
  box-shadow: 0 10px 30px rgba(59, 130, 246, 0.35);
  transition: transform 0.15s ease, filter 0.15s ease;
}

.btn-primary:hover {
  filter: brightness(1.06);
  transform: translateY(-1px);
}

.btn-primary:disabled {
  opacity: 0.55;
  cursor: not-allowed;
  transform: none;
}

.form-error {
  color: var(--danger);
  font-size: 0.875rem;
  margin: 0 0 0.75rem;
}

.banner {
  width: 100%;
  margin: 0 0 1.25rem;
  padding: 0.85rem 1rem;
  border-radius: 0.75rem;
  border: 1px solid rgba(251, 191, 36, 0.35);
  background: rgba(251, 191, 36, 0.08);
  color: #fde68a;
  font-size: 0.9rem;
  text-align: left;
}

.discord-grid {
  width: 100%;
  display: grid;
  gap: 1rem;
}

@media (min-width: 700px) {
  .discord-grid {
    grid-template-columns: 1fr 1fr;
  }
}

.discord-card {
  position: relative;
  overflow: hidden;
  border-radius: 1rem;
  border: 1px solid var(--border);
  background: var(--glass);
  padding: 1.25rem 1.35rem;
  text-align: left;
  box-shadow:
    0 20px 50px rgba(0, 0, 0, 0.45),
    inset 0 1px 1px rgba(255, 255, 255, 0.08);
  backdrop-filter: blur(40px);
  animation: rise 0.45s ease both;
}

.discord-card .card-sheen {
  opacity: 0.85;
}

.discord-top {
  position: relative;
  z-index: 1;
  display: flex;
  align-items: flex-start;
  gap: 0.85rem;
}

.discord-icon {
  width: 3rem;
  height: 3rem;
  border-radius: 0.85rem;
  object-fit: cover;
  background: rgba(255, 255, 255, 0.08);
  border: 1px solid rgba(255, 255, 255, 0.12);
  flex-shrink: 0;
}

.discord-icon.placeholder {
  display: grid;
  place-items: center;
  font-weight: 700;
  color: #93c5fd;
}

.discord-meta h3 {
  margin: 0;
  font-size: 1.1rem;
  font-weight: 600;
}

.discord-meta .guild-name {
  margin: 0.2rem 0 0;
  font-size: 0.8rem;
  color: rgba(255, 255, 255, 0.45);
}

.discord-desc {
  position: relative;
  z-index: 1;
  margin: 0.85rem 0 0;
  font-size: 0.9rem;
  color: var(--muted);
  line-height: 1.45;
}

.stats {
  position: relative;
  z-index: 1;
  display: flex;
  gap: 1rem;
  margin-top: 1rem;
}

.stat {
  display: flex;
  flex-direction: column;
  gap: 0.15rem;
}

.stat strong {
  font-size: 1.35rem;
  font-weight: 700;
  letter-spacing: -0.02em;
}

.stat span {
  font-size: 0.75rem;
  text-transform: uppercase;
  letter-spacing: 0.06em;
  color: rgba(255, 255, 255, 0.45);
}

.stat.online strong {
  color: var(--online);
}

.status-err {
  position: relative;
  z-index: 1;
  margin: 0.85rem 0 0;
  font-size: 0.8rem;
  color: #fca5a5;
}

.discord-actions {
  position: relative;
  z-index: 1;
  display: flex;
  gap: 0.5rem;
  margin-top: 1.1rem;
}

.btn-ghost {
  border: 1px solid rgba(255, 255, 255, 0.14);
  background: rgba(255, 255, 255, 0.04);
  border-radius: 0.55rem;
  padding: 0.45rem 0.75rem;
  font-size: 0.8rem;
  cursor: pointer;
  transition: background 0.15s ease;
}

.btn-ghost:hover {
  background: rgba(255, 255, 255, 0.1);
}

.btn-danger {
  border-color: rgba(248, 113, 113, 0.35);
  color: #fecaca;
}

.btn-danger:hover {
  background: rgba(248, 113, 113, 0.12);
}

.empty {
  grid-column: 1 / -1;
  padding: 2rem;
  border-radius: 1rem;
  border: 1px dashed rgba(255, 255, 255, 0.18);
  color: rgba(255, 255, 255, 0.55);
}

.add-card {
  max-width: none;
  margin-top: 1.75rem;
}

.nav-actions {
  position: relative;
  z-index: 1;
  display: flex;
  gap: 0.5rem;
}

.btn-block {
  display: block;
  width: 100%;
  margin-top: 0.75rem;
  text-align: center;
}

.owner-tools {
  width: 100%;
}

.visibility-field {
  position: relative;
  z-index: 1;
  margin: 0 0 1rem;
  padding: 0.85rem 1rem;
  border-radius: 0.75rem;
  border: 1px solid rgba(255, 255, 255, 0.12);
  background: rgba(0, 0, 0, 0.2);
}

.visibility-field legend {
  padding: 0 0.35rem;
  font-size: 0.85rem;
  color: rgba(255, 255, 255, 0.65);
}

.radio-line {
  display: flex !important;
  align-items: flex-start;
  gap: 0.65rem;
  margin: 0.55rem 0 0 !important;
  cursor: pointer;
}

.radio-line input {
  width: auto !important;
  margin-top: 0.2rem;
  accent-color: #60a5fa;
}

.radio-line span {
  color: rgba(255, 255, 255, 0.85) !important;
  font-size: 0.9rem !important;
  line-height: 1.35;
}

.radio-line strong {
  color: #fff;
}

.vis-badge {
  display: inline-block;
  margin-top: 0.4rem;
  padding: 0.2rem 0.55rem;
  border-radius: 999px;
  border: 1px solid rgba(255, 255, 255, 0.14);
  background: rgba(255, 255, 255, 0.05);
  font-size: 0.7rem;
  letter-spacing: 0.04em;
  text-transform: uppercase;
  color: rgba(255, 255, 255, 0.65);
}

.vis-select {
  display: block;
  margin-top: 0.45rem;
}

.vis-select select {
  border-radius: 0.5rem;
  border: 1px solid rgba(255, 255, 255, 0.14);
  background: rgba(0, 0, 0, 0.4);
  color: #fff;
  padding: 0.3rem 0.5rem;
  font-size: 0.8rem;
  outline: none;
}

.sr-only {
  position: absolute;
  width: 1px;
  height: 1px;
  padding: 0;
  margin: -1px;
  overflow: hidden;
  clip: rect(0, 0, 0, 0);
  border: 0;
}

.hint {
  position: relative;
  z-index: 1;
  margin: -0.5rem 0 1rem;
  font-size: 0.85rem;
  color: rgba(255, 255, 255, 0.55);
  line-height: 1.4;
}

.admin-list {
  position: relative;
  z-index: 1;
  list-style: none;
  margin: 1.25rem 0 0;
  padding: 0;
  display: flex;
  flex-direction: column;
  gap: 0.75rem;
}

.admin-list > li.admin-empty {
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 1rem;
  color: rgba(255, 255, 255, 0.45);
  border: 1px dashed rgba(255, 255, 255, 0.12);
  border-radius: 1rem;
  background: rgba(0, 0, 0, 0.15);
}

.admin-card {
  position: relative;
  overflow: hidden;
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  justify-content: space-between;
  gap: 0.85rem 1rem;
  padding: 0.95rem 1.05rem;
  border-radius: 1rem;
  border: 1px solid var(--border);
  background: var(--glass);
  box-shadow:
    0 12px 30px rgba(0, 0, 0, 0.35),
    inset 0 1px 1px rgba(255, 255, 255, 0.08);
  backdrop-filter: blur(28px);
}

.admin-card-main {
  position: relative;
  z-index: 1;
  display: flex;
  align-items: center;
  gap: 0.8rem;
  min-width: 0;
  flex: 1;
}

.admin-avatar {
  width: 2.6rem;
  height: 2.6rem;
  border-radius: 0.8rem;
  display: grid;
  place-items: center;
  flex-shrink: 0;
  font-weight: 700;
  letter-spacing: 0.02em;
  background: linear-gradient(135deg, rgba(125, 211, 252, 0.35), rgba(37, 99, 235, 0.35));
  border: 1px solid rgba(255, 255, 255, 0.14);
}

.admin-info {
  min-width: 0;
  display: flex;
  flex-direction: column;
  gap: 0.25rem;
}

.admin-info strong {
  font-size: 0.98rem;
  font-weight: 650;
}

.admin-meta {
  display: flex;
  flex-wrap: wrap;
  gap: 0.35rem;
  align-items: center;
}

.admin-badge {
  display: inline-flex;
  align-items: center;
  padding: 0.18rem 0.5rem;
  border-radius: 999px;
  border: 1px solid rgba(255, 255, 255, 0.12);
  background: rgba(255, 255, 255, 0.06);
  font-size: 0.72rem;
  color: rgba(255, 255, 255, 0.7);
}

.admin-badge.is-perm {
  border-color: rgba(96, 165, 250, 0.35);
  background: rgba(59, 130, 246, 0.18);
  color: #bfdbfe;
}

.admin-badge.is-discord {
  border-color: rgba(167, 139, 250, 0.35);
  background: rgba(139, 92, 246, 0.18);
  color: #ddd6fe;
}

.admin-badge.is-muted {
  opacity: 0.75;
}

.staff-discord-link {
  margin: 1rem 0;
}

.admin-card-actions {
  position: relative;
  z-index: 1;
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 0.55rem;
}

.admin-perm-line {
  display: flex !important;
  align-items: center;
  gap: 0.45rem;
  margin: 0 !important;
  padding: 0.4rem 0.65rem;
  border-radius: 0.7rem;
  border: 1px solid rgba(255, 255, 255, 0.12);
  background: rgba(0, 0, 0, 0.22);
  font-size: 0.78rem;
  color: rgba(255, 255, 255, 0.78);
  cursor: pointer;
  user-select: none;
}

.admin-perm-line input {
  accent-color: #60a5fa;
}

.admin-list > li:not(.admin-card):not(.admin-empty) {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 0.75rem;
  padding: 0.85rem 1rem;
  border-radius: 1rem;
  border: 1px solid var(--border);
  background: var(--glass);
  box-shadow: inset 0 1px 1px rgba(255, 255, 255, 0.06);
  font-size: 0.9rem;
}


.head-side {
  display: flex;
  flex-direction: column;
  align-items: flex-end;
  gap: 0.35rem;
}

.refreshed {
  margin: 0;
  font-size: 0.8rem;
  color: rgba(255, 255, 255, 0.4);
}

.status-bar {
  width: 100%;
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 0.75rem 1rem;
  margin-bottom: 1rem;
  text-align: left;
}

.bot-pill {
  display: inline-flex;
  align-items: center;
  gap: 0.4rem;
  padding: 0.35rem 0.7rem;
  border-radius: 999px;
  border: 1px solid rgba(255, 255, 255, 0.14);
  background: rgba(255, 255, 255, 0.05);
  font-size: 0.8rem;
  color: rgba(255, 255, 255, 0.75);
}

.bot-pill::before {
  content: "";
  width: 0.5rem;
  height: 0.5rem;
  border-radius: 50%;
  background: #94a3b8;
}

.bot-pill.is-ok::before {
  background: #4ade80;
  box-shadow: 0 0 8px rgba(74, 222, 128, 0.6);
}

.bot-pill.is-bad::before {
  background: #f87171;
}

.summary-line {
  font-size: 0.85rem;
  color: rgba(255, 255, 255, 0.55);
}

.toolbar {
  width: 100%;
  display: grid;
  grid-template-columns: 1fr auto;
  gap: 0.65rem;
  margin-bottom: 1rem;
}

.toolbar input,
.toolbar select {
  border-radius: 0.65rem;
  border: 1px solid rgba(255, 255, 255, 0.14);
  background: rgba(0, 0, 0, 0.35);
  color: #fff;
  padding: 0.65rem 0.85rem;
  outline: none;
}

.toolbar input:focus,
.toolbar select:focus {
  border-color: rgba(96, 165, 250, 0.55);
}

.guild-id {
  margin: 0.15rem 0 0;
  font-size: 0.72rem;
  color: rgba(255, 255, 255, 0.35);
  font-family: ui-monospace, Consolas, monospace;
}

.status-ok {
  position: relative;
  z-index: 1;
  margin: 0.75rem 0 0;
  font-size: 0.8rem;
  color: #86efac;
}

.modal {
  position: fixed;
  inset: 0;
  z-index: 50;
  display: grid;
  place-items: center;
  padding: 1.25rem;
  background: rgba(5, 6, 15, 0.72);
  backdrop-filter: blur(8px);
}

.modal-card {
  margin: 0;
  max-width: 28rem;
  width: 100%;
}

.modal-actions {
  position: relative;
  z-index: 1;
  display: flex;
  gap: 0.6rem;
  justify-content: flex-end;
  margin-top: 0.5rem;
}

.btn-inline {
  width: auto;
  margin-top: 0;
  padding-left: 1.25rem;
  padding-right: 1.25rem;
}

.toast {
  position: fixed;
  bottom: 1.25rem;
  left: 50%;
  transform: translateX(-50%);
  z-index: 60;
  padding: 0.65rem 1rem;
  border-radius: 0.65rem;
  border: 1px solid rgba(255, 255, 255, 0.15);
  background: rgba(15, 23, 42, 0.92);
  color: #fff;
  font-size: 0.85rem;
  opacity: 0;
  pointer-events: none;
  transition: opacity 0.2s ease;
}

.category-tabs {
  width: 100%;
  display: flex;
  flex-wrap: wrap;
  gap: 0.45rem;
  margin: 0 0 1.15rem;
  text-align: left;
}

.category-tab {
  border: 1px solid rgba(255, 255, 255, 0.12);
  background: rgba(255, 255, 255, 0.04);
  color: rgba(255, 255, 255, 0.7);
  border-radius: 999px;
  padding: 0.45rem 0.9rem;
  font-size: 0.85rem;
  font-weight: 600;
  cursor: pointer;
  transition: background 0.15s ease, border-color 0.15s ease, color 0.15s ease;
}

.category-tab:hover {
  background: rgba(255, 255, 255, 0.08);
}

.category-tab.active {
  color: #061018;
  border-color: transparent;
  background: linear-gradient(135deg, #bfdbfe, #60a5fa 55%, #3b82f6);
  box-shadow: 0 8px 22px rgba(59, 130, 246, 0.28);
}

.tab-checks {
  display: flex;
  flex-wrap: wrap;
  gap: 0.45rem 0.85rem;
}

.tab-checks .radio-line {
  margin: 0 !important;
}

.tab-create-action {
  display: flex;
  align-items: flex-end;
}

.tab-create-action .btn-primary {
  width: 100%;
  margin: 0;
}

#ownerTabs {
  grid-template-columns: repeat(2, 1fr);
}

@media (min-width: 640px) {
  #ownerTabs {
    grid-template-columns: repeat(4, 1fr);
  }
}

.source-badge {
  display: inline-block;
  margin-left: 0.35rem;
  font-size: 0.68rem;
  letter-spacing: 0.04em;
  text-transform: uppercase;
  color: rgba(147, 197, 253, 0.9);
}

.manage-shell {
  position: relative;
  width: min(560px, 100%);
  animation: manageIn 0.35s cubic-bezier(0.22, 1, 0.36, 1) both;
}

@keyframes manageIn {
  from {
    opacity: 0;
    transform: translateY(18px) scale(0.96);
  }
  to {
    opacity: 1;
    transform: translateY(0) scale(1);
  }
}

.manage-aurora {
  pointer-events: none;
  position: absolute;
  inset: -20% -10% auto;
  height: 70%;
  background:
    radial-gradient(ellipse at 30% 40%, rgba(96, 165, 250, 0.45), transparent 55%),
    radial-gradient(ellipse at 75% 30%, rgba(167, 139, 250, 0.35), transparent 50%),
    radial-gradient(ellipse at 50% 80%, rgba(56, 189, 248, 0.2), transparent 60%);
  filter: blur(28px);
  animation: auroraShift 8s ease-in-out infinite alternate;
}

@keyframes auroraShift {
  from { transform: translate(-4%, -2%) rotate(0deg); }
  to { transform: translate(4%, 3%) rotate(4deg); }
}

.manage-panel {
  position: relative;
  margin: 0;
  width: 100%;
  max-width: none;
  padding: 1.5rem 1.5rem 1.75rem;
  border-color: rgba(147, 197, 253, 0.28);
  box-shadow:
    0 30px 80px rgba(0, 0, 0, 0.65),
    0 0 0 1px rgba(255, 255, 255, 0.06) inset,
    0 0 60px rgba(59, 130, 246, 0.18);
}

.manage-head {
  position: relative;
  z-index: 1;
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  gap: 1rem;
  margin-bottom: 1.15rem;
}

.manage-kicker {
  margin: 0 0 0.25rem;
  font-size: 0.72rem;
  letter-spacing: 0.14em;
  text-transform: uppercase;
  color: rgba(147, 197, 253, 0.85);
}

.manage-head h2 {
  margin: 0;
  font-size: 1.75rem;
  font-weight: 700;
  letter-spacing: -0.03em;
  background: linear-gradient(135deg, #e0f2fe, #93c5fd 40%, #60a5fa);
  -webkit-background-clip: text;
  background-clip: text;
  color: transparent;
}

.manage-close {
  width: 2.25rem;
  height: 2.25rem;
  border-radius: 0.65rem;
  border: 1px solid rgba(255, 255, 255, 0.14);
  background: rgba(255, 255, 255, 0.05);
  color: #fff;
  font-size: 1.35rem;
  line-height: 1;
  cursor: pointer;
  transition: background 0.15s ease, transform 0.15s ease;
}

.manage-close:hover {
  background: rgba(255, 255, 255, 0.12);
  transform: scale(1.04);
}

.manage-tabs {
  position: relative;
  z-index: 1;
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 0.35rem;
  padding: 0.3rem;
  margin-bottom: 1.25rem;
  border-radius: 0.85rem;
  border: 1px solid rgba(255, 255, 255, 0.1);
  background: rgba(0, 0, 0, 0.35);
}

.manage-tab {
  border: 0;
  border-radius: 0.65rem;
  padding: 0.7rem 0.85rem;
  background: transparent;
  color: rgba(255, 255, 255, 0.55);
  font-weight: 600;
  font-size: 0.9rem;
  cursor: pointer;
  transition: background 0.2s ease, color 0.2s ease, box-shadow 0.2s ease;
}

.manage-tab.active {
  color: #061018;
  background: linear-gradient(135deg, #bfdbfe, #60a5fa 55%, #3b82f6);
  box-shadow: 0 8px 24px rgba(59, 130, 246, 0.35);
}

.manage-body {
  position: relative;
  z-index: 1;
}

.manage-pane {
  display: none;
  animation: manageIn 0.28s ease both;
}

.manage-pane.active {
  display: block;
}

.manage-pane .hint {
  margin: 0 0 1rem;
}

.manage-pane .btn-primary {
  margin-top: 0.5rem;
}

.manage-panel label {
  display: block;
  margin-bottom: 1rem;
}

.manage-panel label span {
  display: block;
  margin-bottom: 0.4rem;
  font-size: 0.85rem;
  color: rgba(255, 255, 255, 0.65);
}

.manage-panel label em {
  font-style: normal;
  opacity: 0.55;
}

.manage-panel input,
.manage-panel textarea {
  width: 100%;
  border-radius: 0.65rem;
  border: 1px solid rgba(255, 255, 255, 0.14);
  background: rgba(0, 0, 0, 0.35);
  padding: 0.7rem 0.85rem;
  outline: none;
  color: #fff;
  transition: border-color 0.2s ease, box-shadow 0.2s ease;
}

.manage-panel input:focus,
.manage-panel textarea:focus {
  border-color: rgba(96, 165, 250, 0.55);
  box-shadow: 0 0 0 3px rgba(59, 130, 246, 0.15);
}

#adminPanelBtn {
  border-color: rgba(96, 165, 250, 0.45);
  background: linear-gradient(135deg, rgba(96, 165, 250, 0.25), rgba(59, 130, 246, 0.12));
  color: #dbeafe;
}

#adminPanelBtn:hover {
  background: linear-gradient(135deg, rgba(96, 165, 250, 0.4), rgba(59, 130, 246, 0.2));
}

.staff-server-list {
  list-style: none;
  margin: 0 0 1.25rem;
  padding: 0;
  max-height: 240px;
  overflow: auto;
}

.staff-server-list li {
  display: flex;
  justify-content: space-between;
  gap: 0.75rem;
  padding: 0.7rem 0;
  border-top: 1px solid rgba(255, 255, 255, 0.08);
  font-size: 0.9rem;
}

.staff-server-list li:first-child {
  border-top: 0;
}

.staff-server-list .meta {
  color: rgba(255, 255, 255, 0.45);
  font-size: 0.8rem;
}

.admin-stats {
  position: relative;
  z-index: 1;
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(7.5rem, 1fr));
  gap: 0.55rem;
  margin: 0 0 1rem;
}

.admin-stat {
  padding: 0.7rem 0.8rem;
  border-radius: 0.85rem;
  border: 1px solid rgba(255, 255, 255, 0.12);
  background: rgba(0, 0, 0, 0.22);
}

.admin-stat strong {
  display: block;
  font-size: 1.15rem;
  font-weight: 700;
}

.admin-stat span {
  font-size: 0.72rem;
  color: rgba(255, 255, 255, 0.55);
}

.preset-block {
  position: relative;
  z-index: 1;
  margin: 0 0 1.25rem;
  padding: 0.9rem;
  border-radius: 1rem;
  border: 1px solid rgba(255, 255, 255, 0.12);
  background: rgba(0, 0, 0, 0.2);
}

.preset-head {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  gap: 0.75rem;
  margin-bottom: 0.75rem;
}

.preset-block input[type="search"] {
  width: 100%;
  margin-bottom: 0.75rem;
  padding: 0.65rem 0.8rem;
  border-radius: 0.7rem;
  border: 1px solid rgba(255, 255, 255, 0.14);
  background: rgba(0, 0, 0, 0.3);
}

.preset-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(11rem, 1fr));
  gap: 0.55rem;
  max-height: 220px;
  overflow: auto;
}

.preset-card {
  display: flex;
  flex-direction: column;
  gap: 0.45rem;
  padding: 0.7rem;
  border-radius: 0.85rem;
  border: 1px solid rgba(255, 255, 255, 0.12);
  background: rgba(255, 255, 255, 0.04);
  text-align: left;
  cursor: pointer;
  color: inherit;
  transition: border-color 0.15s ease, background 0.15s ease;
}

.preset-card:hover:not(:disabled) {
  border-color: rgba(96, 165, 250, 0.45);
  background: rgba(59, 130, 246, 0.12);
}

.preset-card:disabled,
.preset-card.is-listed {
  opacity: 0.55;
  cursor: default;
}

.preset-card-top {
  display: flex;
  align-items: center;
  gap: 0.55rem;
}

.preset-icon {
  width: 2.1rem;
  height: 2.1rem;
  border-radius: 0.55rem;
  object-fit: cover;
  background: rgba(255, 255, 255, 0.08);
  border: 1px solid rgba(255, 255, 255, 0.12);
  flex-shrink: 0;
  display: grid;
  place-items: center;
  font-size: 0.85rem;
  font-weight: 700;
}

.preset-card strong {
  font-size: 0.82rem;
  line-height: 1.25;
}

.preset-card .meta {
  font-size: 0.7rem;
  color: rgba(255, 255, 255, 0.5);
}

.preset-empty {
  grid-column: 1 / -1;
  padding: 0.85rem;
  text-align: center;
  color: rgba(255, 255, 255, 0.45);
  font-size: 0.85rem;
}

.field-hint {
  display: block;
  margin-top: 0.35rem;
  font-size: 0.75rem;
  color: rgba(255, 255, 255, 0.45);
  line-height: 1.35;
}

.icon-preview-row {
  position: relative;
  z-index: 1;
  display: flex;
  align-items: center;
  gap: 0.75rem;
  margin: 0 0 1rem;
  padding: 0.65rem 0.75rem;
  border-radius: 0.75rem;
  border: 1px solid rgba(255, 255, 255, 0.1);
  background: rgba(0, 0, 0, 0.2);
}

.icon-preview {
  width: 3rem;
  height: 3rem;
  border-radius: 0.85rem;
  object-fit: cover;
  border: 1px solid rgba(255, 255, 255, 0.14);
  background: rgba(255, 255, 255, 0.06);
}

.toggle-line {
  position: relative;
  z-index: 1;
  display: flex !important;
  align-items: center;
  justify-content: space-between;
  gap: 1rem;
  margin: 0 0 1.25rem !important;
  padding: 0.9rem 1rem;
  border-radius: 0.85rem;
  border: 1px solid rgba(255, 255, 255, 0.12);
  background: rgba(0, 0, 0, 0.28);
  cursor: pointer;
}

.toggle-line span {
  display: flex !important;
  flex-direction: column;
  gap: 0.2rem;
  margin: 0 !important;
}

.toggle-line strong {
  color: #fff;
  font-size: 0.95rem;
}

.toggle-line em {
  font-style: normal;
  font-size: 0.8rem;
  color: rgba(255, 255, 255, 0.5);
}

.toggle-line input {
  width: 1.15rem !important;
  height: 1.15rem;
  accent-color: #60a5fa;
  flex-shrink: 0;
}

.settings-card .hint {
  margin: -0.35rem 0 1rem;
}

@media (max-width: 640px) {
  .glass-nav {
    flex-wrap: wrap;
  }

  .nav-tabs {
    order: 3;
    width: 100%;
    justify-content: center;
  }

  .toolbar {
    grid-template-columns: 1fr;
  }

  .head-side {
    align-items: flex-start;
    width: 100%;
  }
}

.category-tabs {
  width: 100%;
  display: flex;
  flex-wrap: wrap;
  gap: 0.45rem;
  margin: 0 0 1.15rem;
  text-align: left;
}

.category-tab {
  border: 1px solid rgba(255, 255, 255, 0.12);
  background: rgba(255, 255, 255, 0.04);
  color: rgba(255, 255, 255, 0.7);
  border-radius: 999px;
  padding: 0.45rem 0.9rem;
  font-size: 0.85rem;
  font-weight: 600;
  cursor: pointer;
  transition: background 0.15s ease, border-color 0.15s ease, color 0.15s ease;
}

.category-tab:hover {
  background: rgba(255, 255, 255, 0.08);
}

.category-tab.active {
  color: #061018;
  border-color: transparent;
  background: linear-gradient(135deg, #bfdbfe, #60a5fa 55%, #3b82f6);
  box-shadow: 0 8px 22px rgba(59, 130, 246, 0.28);
}

.tab-checks {
  display: flex;
  flex-wrap: wrap;
  gap: 0.45rem 0.85rem;
}

.tab-checks .radio-line {
  margin: 0 !important;
}

.tab-create-action {
  display: flex;
  align-items: flex-end;
}

.tab-create-action .btn-primary {
  width: 100%;
  margin: 0;
}

#ownerTabs {
  grid-template-columns: repeat(2, 1fr);
}

@media (min-width: 640px) {
  #ownerTabs {
    grid-template-columns: repeat(4, 1fr);
  }
}

.source-badge {
  display: inline-block;
  margin-left: 0.35rem;
  font-size: 0.68rem;
  letter-spacing: 0.04em;
  text-transform: uppercase;
  color: rgba(147, 197, 253, 0.9);
}
