:root {
  --bg-0: #0c1017;
  --bg-1: #111722;
  --bg-2: #171f2b;
  --text-main: #ecf2ff;
  --text-muted: #99a8c8;
  --line: #2a3445;
  --accent: #1ed0ff;
  --accent-2: #32ffa5;
  --danger: #ff6877;
  --radius-lg: 22px;
  --radius-md: 14px;
  --shadow: 0 24px 50px rgba(0, 0, 0, 0.42);
}

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

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

body {
  font-family: "Space Grotesk", sans-serif;
  color: var(--text-main);
  background: radial-gradient(circle at 20% 10%, #1d2837 0%, var(--bg-0) 45%),
    linear-gradient(160deg, #0a0d13 0%, #0f131b 100%);
  overflow-x: hidden;
}

.bg-grid {
  position: fixed;
  inset: 0;
  background-image: linear-gradient(var(--line) 1px, transparent 1px),
    linear-gradient(90deg, var(--line) 1px, transparent 1px);
  background-size: 42px 42px;
  opacity: 0.2;
  pointer-events: none;
}

.orb {
  position: fixed;
  width: 36rem;
  height: 36rem;
  border-radius: 50%;
  filter: blur(80px);
  pointer-events: none;
  z-index: -1;
}

.orb-a {
  top: -10rem;
  right: -12rem;
  background: rgba(30, 208, 255, 0.18);
}

.orb-b {
  bottom: -12rem;
  left: -10rem;
  background: rgba(50, 255, 165, 0.14);
}

.layout {
  width: min(1100px, calc(100vw - 1.5rem));
  max-width: 100%;
  margin: 3.5rem auto;
  display: grid;
  grid-template-columns: clamp(72px, 12vw, 140px) minmax(0, 1fr);
  gap: 1rem;
}

.server-rail {
  background: rgba(12, 16, 23, 0.68);
  border: 1px solid rgba(153, 168, 200, 0.18);
  border-radius: var(--radius-lg);
  min-height: 720px;
  display: flex;
  flex-direction: column;
  align-items: center;
  padding: 0.7rem;
  gap: 0.75rem;
  backdrop-filter: blur(8px);
  min-width: 0;
}

.rail-btn {
  position: relative;
  border: 1px solid rgba(153, 168, 200, 0.2);
  background: rgba(35, 47, 65, 0.7);
  color: #c7d4ef;
  font-weight: 700;
  border-radius: 18px;
  width: 76px;
  height: 76px;
  display: grid;
  place-items: center;
  gap: 0.24rem;
  padding: 0.35rem;
  cursor: pointer;
  transition: transform 0.2s ease, background-color 0.2s ease, border-radius 0.2s ease;
}

.rail-btn.active {
  background: linear-gradient(150deg, #1ed0ff, #17a5d2);
  color: #031119;
  border-color: transparent;
  border-radius: 24px;
}

.rail-btn:hover {
  transform: translateY(-2px);
}

.server-rail .rail-link-box,
.server-rail .rail-link-box:visited,
.server-rail .rail-link-box:link,
.server-rail .rail-link-box:active {
  border: 1px solid rgba(153, 168, 200, 0.2);
  background: rgba(35, 47, 65, 0.7);
  color: #c7d4ef;
  font-weight: 700;
  border-radius: 18px;
  width: 76px;
  height: 76px;
  display: grid;
  place-items: center;
  gap: 0.24rem;
  padding: 0.35rem;
  cursor: pointer;
  text-decoration: none;
  transition: transform 0.2s ease, background-color 0.2s ease, border-radius 0.2s ease;
}

.rail-link-box:hover {
  transform: translateY(-2px);
  background: linear-gradient(150deg, #1ed0ff, #17a5d2);
  color: #031119;
  border-color: transparent;
  border-radius: 24px;
}

.rail-icon {
  width: 22px;
  height: 22px;
  display: inline-grid;
}

.rail-icon svg {
  width: 100%;
  height: 100%;
}

.rail-label {
  font-size: 0.68rem;
  letter-spacing: 0.02em;
}

.rail-status-dot {
  position: absolute;
  top: 7px;
  right: 7px;
  width: 10px;
  height: 10px;
  border-radius: 999px;
  border: 2px solid rgba(12, 16, 23, 0.85);
  background: #32ffa5;
  box-shadow: 0 0 0 1px rgba(50, 255, 165, 0.2);
}

.rail-status-dot.maintenance {
  background: #ffd166;
  box-shadow: 0 0 0 1px rgba(255, 209, 102, 0.25);
}

.panel {
  background: linear-gradient(
    155deg,
    rgba(23, 31, 43, 0.96),
    rgba(17, 23, 34, 0.9)
  );
  border: 1px solid rgba(153, 168, 200, 0.2);
  border-radius: var(--radius-lg);
  padding: 1rem;
  box-shadow: var(--shadow);
  min-width: 0;
}

.panel-top {
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: 1rem;
  background: rgba(12, 16, 23, 0.65);
  border: 1px solid rgba(153, 168, 200, 0.18);
  border-radius: var(--radius-md);
  padding: 0.65rem 0.9rem;
}

.site-maintenance-banner {
  margin-bottom: 0.75rem;
  display: flex;
  align-items: center;
  gap: 0.65rem;
  flex-wrap: wrap;
  overflow: hidden;
  border: 1px solid rgba(255, 104, 119, 0.45);
  background: linear-gradient(135deg, rgba(255, 104, 119, 0.16), rgba(255, 187, 96, 0.08));
  border-radius: 12px;
  padding: 0.65rem 0.8rem;
  width: 100%;
  min-width: 0;
}

.news-banner {
  margin-bottom: 0.75rem;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 0.65rem;
  flex-wrap: wrap;
  overflow: hidden;
  border: 1px solid rgba(30, 208, 255, 0.45);
  background: linear-gradient(135deg, rgba(30, 208, 255, 0.14), rgba(50, 255, 165, 0.08));
  border-radius: 12px;
  padding: 0.65rem 0.8rem;
  width: 100%;
  min-width: 0;
}

.news-banner p {
  margin: 0;
  font-size: 0.92rem;
  color: var(--text-main);
}

.banner-ticker {
  flex: 1 1 0%;
  min-width: 0;
  overflow: hidden;
  position: relative;
  width: 100%;
}

.banner-track {
  display: inline-flex;
  white-space: nowrap;
  padding-left: 100%;
  min-width: max-content;
  animation: ticker-scroll 20s linear infinite;
}

.site-maintenance-banner .banner-track {
  animation-duration: 18s;
}

.banner-track span {
  font-size: 0.92rem;
  color: var(--text-main);
}

.site-maintenance-banner:hover .banner-track,
.news-banner:hover .banner-track {
  animation-play-state: paused;
}

.news-banner-link {
  text-decoration: none;
  color: #04121b;
  background: linear-gradient(135deg, var(--accent), #1e9eff);
  border-radius: 9px;
  padding: 0.35rem 0.62rem;
  font-weight: 700;
  font-size: 0.82rem;
  flex: 0 0 auto;
}

.tab-panel {
  display: none;
}

.tab-panel.active {
  display: block;
}

.hidden {
  display: none !important;
}

.ghost-btn {
  text-decoration: none;
  color: var(--text-main);
  border: 1px solid rgba(153, 168, 200, 0.3);
  padding: 0.48rem 0.82rem;
  border-radius: 10px;
  font-size: 0.9rem;
}

.hero {
  padding: 3.2rem 1rem 2.4rem;
  text-align: center;
}

.community-logo {
  width: 96px;
  height: 96px;
  border-radius: 26px;
  margin-bottom: 0.8rem;
  box-shadow: 0 14px 35px rgba(30, 208, 255, 0.22);
}

.eyebrow {
  text-transform: uppercase;
  letter-spacing: 0.12em;
  color: var(--accent);
  margin: 0;
  font-weight: 700;
  font-size: 0.82rem;
}

h1 {
  margin: 0.35rem 0 0.7rem;
  font-family: "Sora", sans-serif;
  font-size: clamp(2rem, 5vw, 4.3rem);
  line-height: 1.02;
}

.lead {
  margin: 0 auto;
  max-width: 62ch;
  color: var(--text-muted);
  font-size: 1.04rem;
}

.hero-cta {
  margin-top: 1.4rem;
  display: grid;
  gap: 0.55rem;
  place-items: center;
}

.cta-btn {
  background: linear-gradient(135deg, var(--accent), #1e9eff);
  color: #04121b;
  text-decoration: none;
  padding: 0.9rem 1.45rem;
  border-radius: 12px;
  font-family: "Sora", sans-serif;
  font-weight: 700;
  transition: transform 0.2s ease, filter 0.2s ease;
}

.cta-btn:hover {
  transform: translateY(-2px);
  filter: brightness(1.06);
}

.cta-note {
  margin: 0;
  color: var(--text-muted);
  font-size: 0.9rem;
}

.channels {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 0.95rem;
  padding: 0.2rem;
}

.channel-card {
  background: rgba(12, 16, 23, 0.66);
  border: 1px solid rgba(153, 168, 200, 0.16);
  border-radius: 14px;
  padding: 1rem;
  transform: translateY(12px);
  opacity: 0;
}

.channel-card.visible {
  transform: translateY(0);
  opacity: 1;
  transition: transform 0.6s ease, opacity 0.6s ease;
}

.channel-name {
  margin: 0 0 0.35rem;
  color: var(--accent);
  font-weight: 700;
}

.channel-card p {
  margin: 0;
  color: var(--text-muted);
}

.game-servers {
  margin-top: 1rem;
  background: rgba(12, 16, 23, 0.66);
  border: 1px solid rgba(153, 168, 200, 0.16);
  border-radius: 14px;
  padding: 0.9rem;
}

.game-servers-head {
  margin-bottom: 0.7rem;
}

.game-servers-head h2 {
  margin: 0;
  font-family: "Sora", sans-serif;
  font-size: 1.02rem;
}

.game-servers-head p {
  margin: 0.3rem 0 0;
  color: var(--text-muted);
  font-size: 0.9rem;
}

.streams-section {
  margin-top: 1rem;
  background: rgba(12, 16, 23, 0.66);
  border: 1px solid rgba(153, 168, 200, 0.16);
  border-radius: 14px;
  padding: 0.9rem;
}

.streams-head h2 {
  margin: 0;
  font-family: "Sora", sans-serif;
  font-size: 1.02rem;
}

.streams-head p {
  margin: 0.3rem 0 0.75rem;
  color: var(--text-muted);
  font-size: 0.9rem;
}

.streams-grid {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 0.75rem;
}

.stream-card {
  border: 1px solid rgba(153, 168, 200, 0.16);
  border-radius: 12px;
  background: rgba(15, 19, 27, 0.82);
  overflow: hidden;
}

.stream-preview {
  position: relative;
  aspect-ratio: 16 / 9;
  background: rgba(10, 14, 20, 0.9);
}

.stream-preview img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  display: block;
}

.stream-preview-fallback {
  width: 100%;
  height: 100%;
  display: grid;
  place-items: center;
  color: var(--text-muted);
  font-weight: 700;
  letter-spacing: 0.08em;
}

.stream-preview-empty {
  width: 100%;
  height: 100%;
}

.stream-offline-overlay {
  position: absolute;
  inset: 0;
  display: grid;
  place-items: center;
  background: repeating-linear-gradient(
    -35deg,
    rgba(0, 0, 0, 0.56),
    rgba(0, 0, 0, 0.56) 16px,
    rgba(255, 104, 119, 0.22) 16px,
    rgba(255, 104, 119, 0.22) 32px
  );
}

.stream-offline-text {
  display: inline-block;
  color: #ffd5db;
  font-family: "Sora", sans-serif;
  font-size: clamp(1.2rem, 3.2vw, 2rem);
  font-weight: 800;
  letter-spacing: 0.14em;
  text-transform: uppercase;
  text-shadow: 0 2px 10px rgba(0, 0, 0, 0.45);
  transform: rotate(-20deg);
  transform-origin: center center;
}

.stream-state {
  position: absolute;
  top: 0.6rem;
  left: 0.6rem;
  border-radius: 999px;
  font-size: 0.75rem;
  font-weight: 700;
  padding: 0.2rem 0.52rem;
  border: 1px solid transparent;
}

.stream-state.online {
  color: #32ffa5;
  background: rgba(50, 255, 165, 0.12);
  border-color: rgba(50, 255, 165, 0.35);
}

.stream-state.offline {
  color: #ff8c98;
  background: rgba(255, 104, 119, 0.12);
  border-color: rgba(255, 104, 119, 0.35);
}

.stream-body {
  padding: 0.7rem;
}

.stream-name {
  margin: 0;
  font-family: "Sora", sans-serif;
  font-size: 0.95rem;
}

.stream-meta {
  margin: 0.24rem 0 0;
  color: var(--text-muted);
  font-size: 0.85rem;
}

.stream-description {
  margin: 0.38rem 0 0;
  color: #b7c5e4;
  font-size: 0.85rem;
}

.stream-link {
  margin-top: 0.6rem;
  display: inline-block;
  text-decoration: none;
  color: #04121b;
  background: linear-gradient(135deg, var(--accent), #1e9eff);
  border-radius: 9px;
  padding: 0.38rem 0.7rem;
  font-weight: 700;
  font-size: 0.82rem;
}

.server-list {
  display: grid;
  gap: 0.7rem;
}

.server-entry {
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: 0.8rem;
  border: 1px solid rgba(153, 168, 200, 0.16);
  border-radius: 12px;
  padding: 0.75rem;
  background: rgba(15, 19, 27, 0.8);
}

.server-main {
  display: flex;
  align-items: flex-start;
  gap: 0.56rem;
}

.game-icon {
  width: 34px;
  height: 34px;
  flex: 0 0 34px;
  display: inline-grid;
  place-items: center;
  font-size: 1rem;
  border-radius: 10px;
  background: rgba(30, 208, 255, 0.13);
  border: 1px solid rgba(30, 208, 255, 0.28);
}

.server-title {
  margin: 0;
  font-family: "Sora", sans-serif;
  font-size: 1rem;
}

.server-meta,
.server-address {
  margin: 0.2rem 0 0;
  color: var(--text-muted);
  font-size: 0.88rem;
}

.server-actions {
  display: grid;
  gap: 0.45rem;
  justify-items: end;
}

.server-state {
  font-size: 0.78rem;
  font-weight: 700;
  padding: 0.24rem 0.48rem;
  border-radius: 999px;
  border: 1px solid transparent;
}

.server-state.online {
  color: #32ffa5;
  background: rgba(50, 255, 165, 0.12);
  border-color: rgba(50, 255, 165, 0.35);
}

.server-state.maintenance {
  color: #ffd166;
  background: rgba(255, 209, 102, 0.12);
  border-color: rgba(255, 209, 102, 0.35);
}

.server-state.offline {
  color: #ff8c98;
  background: rgba(255, 104, 119, 0.12);
  border-color: rgba(255, 104, 119, 0.35);
}

.server-note {
  margin: 0.25rem 0 0;
  color: #b7c5e4;
  font-size: 0.85rem;
}

.server-join {
  text-decoration: none;
  color: #04121b;
  background: linear-gradient(135deg, var(--accent), #1e9eff);
  border-radius: 9px;
  padding: 0.42rem 0.72rem;
  font-weight: 700;
  font-size: 0.84rem;
}

.server-join.disabled {
  pointer-events: none;
  color: var(--text-muted);
  background: rgba(153, 168, 200, 0.14);
}

.admin-shell {
  margin-top: 1rem;
  background: rgba(12, 16, 23, 0.66);
  border: 1px solid rgba(153, 168, 200, 0.16);
  border-radius: 14px;
  padding: 0.9rem;
}

.admin-auth h2,
.admin-head h2 {
  margin: 0;
  font-family: "Sora", sans-serif;
  font-size: 1.02rem;
}

.admin-auth p {
  margin: 0.4rem 0 0.7rem;
  color: var(--text-muted);
}

.admin-login-form {
  display: flex;
  gap: 0.6rem;
  flex-wrap: wrap;
}

.login-password-wrap {
  display: grid;
  grid-template-columns: minmax(0, 1fr) auto;
  gap: 0.5rem;
  flex: 1 1 260px;
}

.admin-login-form input,
.server-form input,
.server-form textarea,
.server-form select,
.stream-form input,
.stream-form textarea,
.tracking-form input,
.tracking-form select {
  background: rgba(15, 19, 27, 0.8);
  border: 1px solid rgba(153, 168, 200, 0.25);
  color: var(--text-main);
  border-radius: 10px;
  padding: 0.55rem 0.65rem;
  font: inherit;
}

.server-checkbox-row {
  display: flex;
  align-items: center;
  gap: 0.45rem;
  color: var(--text-muted);
  font-size: 0.9rem;
}

.server-checkbox-row input[type="checkbox"] {
  width: 16px;
  height: 16px;
}

.admin-login-form button,
.server-form button,
.admin-logout-btn {
  background: linear-gradient(135deg, var(--accent), #1e9eff);
  border: 0;
  color: #04121b;
  border-radius: 10px;
  font-weight: 700;
  padding: 0.55rem 0.8rem;
  cursor: pointer;
}

.toggle-password-btn {
  min-width: 92px;
}

.admin-login-msg {
  min-height: 1.1rem;
  margin: 0.55rem 0 0;
  color: var(--text-muted);
  font-size: 0.88rem;
}

.admin-panel-msg {
  min-height: 1.1rem;
  margin: 0.35rem 0 0.7rem;
  color: var(--text-muted);
  font-size: 0.88rem;
}

.admin-head {
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: 0.8rem;
  margin-bottom: 0.5rem;
}

.admin-head-actions {
  display: flex;
  gap: 0.5rem;
}

.admin-restore-btn {
  background: rgba(15, 19, 27, 0.8);
  border: 1px solid rgba(153, 168, 200, 0.25);
  color: var(--text-main);
  border-radius: 10px;
  font-weight: 700;
  padding: 0.55rem 0.8rem;
  cursor: pointer;
}

.admin-restore-btn:disabled {
  opacity: 0.6;
  cursor: wait;
}

.admin-intro {
  margin: 0 0 0.75rem;
  color: var(--text-muted);
  font-size: 0.9rem;
}

.admin-quicknav {
  display: flex;
  flex-wrap: wrap;
  gap: 0.5rem;
  margin-bottom: 0.9rem;
}

.admin-quicknav a {
  text-decoration: none;
  color: var(--text-main);
  border: 1px solid rgba(153, 168, 200, 0.24);
  background: rgba(15, 19, 27, 0.7);
  border-radius: 999px;
  padding: 0.32rem 0.62rem;
  font-size: 0.82rem;
}

.admin-grid {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 0.75rem;
}

.admin-card {
  margin-top: 0;
  padding: 0.85rem;
  border: 1px solid rgba(153, 168, 200, 0.2);
  border-radius: 12px;
  background: rgba(15, 19, 27, 0.78);
}

.analytics-total {
  border: 1px solid rgba(153, 168, 200, 0.18);
  border-radius: 10px;
  background: rgba(12, 16, 23, 0.7);
  padding: 0.65rem;
}

.analytics-window-switch {
  display: flex;
  gap: 0.45rem;
  flex-wrap: wrap;
  margin-bottom: 0.65rem;
}

.analytics-window-btn {
  background: rgba(153, 168, 200, 0.14);
  color: var(--text-main);
  border: 1px solid rgba(153, 168, 200, 0.22);
  border-radius: 999px;
  padding: 0.3rem 0.62rem;
  font: inherit;
  font-size: 0.8rem;
  cursor: pointer;
}

.analytics-window-btn.active {
  background: linear-gradient(135deg, var(--accent), #1e9eff);
  border-color: transparent;
  color: #04121b;
  font-weight: 700;
}

.analytics-total-label {
  margin: 0;
  color: var(--text-muted);
  font-size: 0.82rem;
}

.analytics-total-value {
  margin: 0.3rem 0 0;
  font-family: "Sora", sans-serif;
  font-size: 1.6rem;
  line-height: 1.1;
}

.analytics-chart {
  margin-top: 0.65rem;
  display: grid;
  gap: 0.45rem;
}

.analytics-row {
  display: grid;
  grid-template-columns: 84px minmax(0, 1fr) 58px;
  align-items: center;
  gap: 0.45rem;
}

.analytics-source {
  color: var(--text-muted);
  font-size: 0.82rem;
}

.analytics-bar-wrap {
  position: relative;
  height: 10px;
  border-radius: 999px;
  background: rgba(153, 168, 200, 0.14);
  overflow: hidden;
}

.analytics-bar {
  height: 100%;
  border-radius: 999px;
  background: linear-gradient(135deg, var(--accent), #1e9eff);
}

.analytics-value {
  text-align: right;
  font-size: 0.8rem;
  color: var(--text-main);
}

.analytics-updated {
  margin: 0.55rem 0 0;
  color: var(--text-muted);
  font-size: 0.8rem;
}

.admin-card-wide {
  grid-column: 1 / -1;
}

.server-form {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 0.55rem;
}

.stream-form {
  display: grid;
  gap: 0.55rem;
}

.admin-form-actions {
  display: flex;
  gap: 0.55rem;
}

.server-form .ghost {
  background: rgba(153, 168, 200, 0.15);
  color: var(--text-main);
}

.admin-server-list {
  margin-top: 0.8rem;
  display: grid;
  gap: 0.55rem;
}

.admin-stream-list {
  margin-top: 0.8rem;
  display: grid;
  gap: 0.55rem;
}

.admin-server-row {
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: 0.8rem;
  border: 1px solid rgba(153, 168, 200, 0.16);
  border-radius: 10px;
  padding: 0.65rem;
  background: rgba(15, 19, 27, 0.8);
}

.admin-stream-row {
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: 0.8rem;
  border: 1px solid rgba(153, 168, 200, 0.16);
  border-radius: 10px;
  padding: 0.65rem;
  background: rgba(15, 19, 27, 0.8);
}

.admin-server-row p {
  margin: 0;
}

.admin-stream-row p {
  margin: 0;
}

.admin-row-actions {
  display: flex;
  gap: 0.45rem;
}

.admin-row-actions button {
  background: rgba(153, 168, 200, 0.15);
  color: var(--text-main);
  border: 1px solid rgba(153, 168, 200, 0.25);
  border-radius: 8px;
  padding: 0.35rem 0.6rem;
  cursor: pointer;
}

.admin-subsection {
  margin-top: 0;
  scroll-margin-top: 0.8rem;
}

.admin-subsection h3 {
  margin: 0;
  font-family: "Sora", sans-serif;
  font-size: 0.96rem;
}

.admin-subsection p {
  margin: 0.35rem 0 0.7rem;
  color: var(--text-muted);
  font-size: 0.88rem;
}

.highlights-form {
  display: grid;
  gap: 0.65rem;
}

.news-form {
  display: grid;
  gap: 0.55rem;
}

.legal-form {
  display: grid;
  gap: 0.55rem;
}

.maintenance-form {
  display: grid;
  gap: 0.55rem;
}

.tracking-form {
  display: grid;
  gap: 0.55rem;
}

.highlights-editor {
  display: grid;
  gap: 0.55rem;
}

.highlight-row {
  display: grid;
  grid-template-columns: 1fr 2fr auto;
  gap: 0.5rem;
  align-items: center;
}

.highlight-row textarea {
  min-height: 42px;
  resize: vertical;
  background: rgba(15, 19, 27, 0.8);
  border: 1px solid rgba(153, 168, 200, 0.25);
  color: var(--text-main);
  border-radius: 10px;
  padding: 0.55rem 0.65rem;
  font: inherit;
}

.highlight-remove {
  background: rgba(255, 104, 119, 0.12);
  color: #ffb6bf;
  border: 1px solid rgba(255, 104, 119, 0.35);
  border-radius: 8px;
  padding: 0.35rem 0.55rem;
  cursor: pointer;
}

.discord-live {
  margin-top: 1rem;
  background: rgba(12, 16, 23, 0.66);
  border: 1px solid rgba(153, 168, 200, 0.16);
  border-radius: 14px;
  padding: 0.9rem;
}

.discord-live-head {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 0.8rem;
  flex-wrap: wrap;
  margin-bottom: 0.65rem;
}

.discord-live-head h2 {
  margin: 0;
  font-family: "Sora", sans-serif;
  font-size: 1.02rem;
}

.discord-live-head a {
  color: var(--accent);
  text-decoration: none;
  font-weight: 700;
  font-size: 0.9rem;
}

.live-grid {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: 0.7rem;
}

.live-card {
  border: 1px solid rgba(153, 168, 200, 0.16);
  border-radius: 12px;
  padding: 0.75rem;
  background: rgba(15, 19, 27, 0.8);
}

.live-label {
  margin: 0;
  color: var(--text-muted);
  font-size: 0.82rem;
}

.live-value {
  margin: 0.35rem 0 0;
  font-family: "Sora", sans-serif;
  font-size: 1.15rem;
  color: var(--text-main);
}

.widget-note {
  margin: 0.65rem 0 0;
  color: var(--text-muted);
  font-size: 0.88rem;
}

.panel-footer {
  margin-top: 1rem;
  border-top: 1px solid rgba(153, 168, 200, 0.18);
  padding: 0.95rem 0.4rem 0.4rem;
  display: flex;
  justify-content: space-between;
  align-items: center;
  flex-wrap: wrap;
  gap: 0.65rem;
}

.panel-footer p {
  margin: 0;
  color: var(--text-muted);
}

.footer-menu {
  display: flex;
  align-items: center;
  gap: 0.7rem;
  flex-wrap: wrap;
}

.footer-link {
  color: var(--accent-2);
  text-decoration: none;
  font-weight: 700;
}

.footer-menu-link {
  background: transparent;
  border: 1px solid rgba(153, 168, 200, 0.25);
  color: var(--text-muted);
  border-radius: 9px;
  padding: 0.34rem 0.6rem;
  font: inherit;
  cursor: pointer;
}

.footer-menu-link:hover {
  color: var(--text-main);
}

.legal-modal {
  position: fixed;
  inset: 0;
  background: rgba(5, 8, 12, 0.7);
  display: grid;
  place-items: center;
  z-index: 40;
  padding: 1rem;
}

.legal-modal-card {
  width: min(760px, 100%);
  max-height: 85vh;
  overflow: auto;
  background: linear-gradient(155deg, rgba(23, 31, 43, 0.98), rgba(17, 23, 34, 0.98));
  border: 1px solid rgba(153, 168, 200, 0.24);
  border-radius: 14px;
  padding: 0.9rem;
}

.legal-modal-head {
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: 0.7rem;
  margin-bottom: 0.7rem;
}

.legal-modal-head h2 {
  margin: 0;
  font-family: "Sora", sans-serif;
  font-size: 1rem;
}

.legal-close-btn {
  border: 1px solid rgba(153, 168, 200, 0.25);
  background: rgba(153, 168, 200, 0.1);
  color: var(--text-main);
  border-radius: 8px;
  width: 32px;
  height: 32px;
  cursor: pointer;
}

.legal-content h3 {
  margin: 1rem 0 0.4rem;
  font-size: 0.95rem;
}

.legal-content p {
  margin: 0;
  color: var(--text-muted);
  line-height: 1.5;
}

.consent-modal {
  position: fixed;
  inset: 0;
  background: rgba(5, 8, 12, 0.72);
  display: grid;
  place-items: center;
  z-index: 70;
  padding: 1rem;
}

.consent-modal-card {
  width: min(560px, 100%);
  border: 1px solid rgba(153, 168, 200, 0.28);
  border-radius: 14px;
  background: linear-gradient(155deg, rgba(23, 31, 43, 0.98), rgba(17, 23, 34, 0.98));
  box-shadow: var(--shadow);
  padding: 1rem;
}

.consent-modal-card h3 {
  margin: 0;
  font-family: "Sora", sans-serif;
  font-size: 1rem;
}

.consent-modal-card p {
  margin: 0.55rem 0 0;
  color: var(--text-muted);
  font-size: 0.92rem;
}

.consent-actions {
  display: flex;
  gap: 0.5rem;
  flex-wrap: wrap;
}

.consent-actions button {
  background: linear-gradient(135deg, var(--accent), #1e9eff);
  border: 0;
  color: #04121b;
  border-radius: 10px;
  font-weight: 700;
  padding: 0.5rem 0.8rem;
  cursor: pointer;
}

.consent-actions .ghost {
  background: rgba(153, 168, 200, 0.15);
  color: var(--text-main);
  border: 1px solid rgba(153, 168, 200, 0.25);
}

@keyframes pulse {
  0% {
    box-shadow: 0 0 0 0 rgba(50, 255, 165, 0.5);
  }
  70% {
    box-shadow: 0 0 0 12px rgba(50, 255, 165, 0);
  }
  100% {
    box-shadow: 0 0 0 0 rgba(50, 255, 165, 0);
  }
}

@keyframes ticker-scroll {
  0% {
    transform: translateX(0);
  }
  100% {
    transform: translateX(-100%);
  }
}

@media (prefers-reduced-motion: reduce) {
  .banner-track {
    animation: none;
    padding-left: 0;
  }
}

@media (max-width: 960px) {
  .channels {
    grid-template-columns: 1fr;
  }

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

  .server-entry {
    align-items: start;
  }

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

@media (max-width: 720px) {
  .layout {
    grid-template-columns: 1fr;
    margin: 1rem auto 2rem;
  }

  .server-rail {
    min-height: auto;
    flex-direction: row;
    justify-content: flex-start;
    padding: 0.6rem;
    overflow-x: auto;
  }

  .rail-btn {
    width: 72px;
    height: 72px;
    flex: 0 0 auto;
  }

  .panel {
    padding: 0.8rem;
  }

  .hero {
    padding: 2rem 0.5rem 1.6rem;
    text-align: left;
  }

  .community-logo {
    width: 78px;
    height: 78px;
    margin-bottom: 0.7rem;
  }

  .hero-cta {
    place-items: start;
  }

  .panel-top {
    flex-wrap: wrap;
  }

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

  .server-entry {
    flex-direction: column;
    align-items: stretch;
  }

  .server-actions {
    justify-items: start;
  }

  .server-form {
    grid-template-columns: 1fr;
  }

  .highlight-row {
    grid-template-columns: 1fr;
  }

  .footer-menu {
    width: 100%;
  }

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

  .consent-modal-card {
    width: 100%;
  }
}
