@import url("https://fonts.googleapis.com/css2?family=Rajdhani:wght@500;700&family=Sora:wght@400;600;700;800&display=swap");

:root {
  --bg: #07090d;
  --bg-soft: #0e141d;
  --card: #111a26;
  --card-soft: #1a2533;
  --line: #2f3d4e;
  --text: #f4f6f8;
  --muted: #aab9c8;
  --purple: #8b5cf6;
  --purple-soft: #b794ff;
  --purple-dark: #3f2b78;
  --blue-soft: #4ec1ff;
  --ok: #3dd58a;
  --ko: #ff6b7d;
  --radius: 16px;
  --shadow: 0 20px 50px rgba(0, 0, 0, 0.45);
  --mouse-x: 50%;
  --mouse-y: 50%;
}

* {
  box-sizing: border-box;
}

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

body {
  font-family: "Sora", "Segoe UI", sans-serif;
  background:
    radial-gradient(900px 500px at 12% 12%, rgba(139, 92, 246, 0.3), transparent 70%),
    radial-gradient(900px 500px at 88% 6%, rgba(49, 168, 255, 0.19), transparent 70%),
    linear-gradient(180deg, #090d14 0%, #05080d 100%);
  color: var(--text);
  overflow-x: hidden;
}

.mouse-glow {
  position: fixed;
  left: 0;
  top: 0;
  pointer-events: none;
  z-index: 0;
  opacity: 0;
  transition: opacity 0.18s ease;
}

.mouse-glow {
  width: 128px;
  height: 128px;
  border-radius: 50%;
  background: radial-gradient(
    circle,
    rgba(168, 132, 255, 0.28) 0%,
    rgba(140, 102, 255, 0.14) 44%,
    rgba(128, 90, 255, 0) 74%
  );
  filter: blur(1px);
}

.bg-orb {
  position: fixed;
  left: 0;
  right: 0;
  top: -120px;
  height: 380px;
  pointer-events: none;
  background: radial-gradient(circle at center, rgba(139, 92, 246, 0.33), transparent 72%);
  filter: blur(28px);
  z-index: 0;
}

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

.bg-particles::before {
  content: "";
  position: absolute;
  inset: 0;
  background: repeating-linear-gradient(
    -16deg,
    rgba(137, 183, 228, 0.06) 0px,
    rgba(137, 183, 228, 0.06) 1px,
    transparent 1px,
    transparent 34px
  );
  opacity: 0.35;
}

.bg-particles .streak {
  position: absolute;
  left: -45vw;
  top: var(--streak-top, 50%);
  width: var(--streak-length, 180px);
  height: var(--streak-thickness, 2px);
  border-radius: 999px;
  background: linear-gradient(
    90deg,
    rgba(78, 193, 255, 0),
    rgba(150, 202, 255, 0.42) 28%,
    rgba(180, 140, 255, 0.9) 62%,
    rgba(235, 224, 255, 0.95) 76%,
    rgba(78, 193, 255, 0)
  );
  box-shadow:
    0 0 9px rgba(106, 186, 255, 0.45),
    0 0 20px rgba(162, 120, 255, 0.38);
  transform: rotate(var(--streak-angle, -16deg));
  transform-origin: center;
  animation: streakTravel var(--streak-duration, 12s) linear infinite;
  animation-delay: var(--streak-delay, 0s);
  opacity: 0;
}

.bg-particles .streak::after {
  content: "";
  position: absolute;
  right: 0;
  top: 50%;
  width: 4px;
  height: 4px;
  border-radius: 50%;
  transform: translate(50%, -50%);
  background: rgba(224, 206, 255, 0.98);
  box-shadow:
    0 0 6px rgba(186, 150, 255, 0.82),
    0 0 12px rgba(113, 188, 255, 0.42);
}

.bg-particles .streak.bolt {
  height: calc(var(--streak-thickness, 2px) + 1px);
  background: linear-gradient(
    90deg,
    rgba(88, 200, 255, 0),
    rgba(176, 223, 255, 0.58) 22%,
    rgba(193, 158, 255, 0.98) 58%,
    rgba(240, 233, 255, 0.98) 76%,
    rgba(88, 200, 255, 0)
  );
  box-shadow:
    0 0 14px rgba(121, 199, 255, 0.56),
    0 0 30px rgba(162, 124, 255, 0.46);
}

@keyframes streakTravel {
  0% {
    transform: translate3d(-12vw, 0, 0) rotate(var(--streak-angle, -16deg));
    opacity: 0;
  }
  7% {
    opacity: 0.75;
  }
  75% {
    opacity: 0.35;
  }
  100% {
    transform: translate3d(148vw, 0, 0) rotate(var(--streak-angle, -16deg));
    opacity: 0;
  }
}

@media (pointer: coarse) {
  .mouse-glow {
    display: none;
  }
}

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

.topbar {
  position: sticky;
  top: 0;
  z-index: 1000;
  display: grid;
  grid-template-columns: auto 1fr auto;
  align-items: center;
  gap: 16px;
  padding: 14px 24px;
  border-bottom: 1px solid rgba(112, 132, 156, 0.3);
  backdrop-filter: blur(12px);
  background: rgba(8, 12, 18, 0.72);
}

.page {
  position: relative;
  z-index: 1;
}

.brand {
  display: inline-flex;
  align-items: center;
  justify-content: flex-start;
  min-height: 56px;
  justify-self: start;
}

.brand-logo {
  display: block;
  height: 56px;
  width: auto;
  object-fit: contain;
}

.main-nav {
  display: flex;
  align-items: center;
  justify-content: center;
  justify-self: center;
  gap: 16px;
  min-width: 0;
}

.main-nav a {
  padding: 8px 14px;
  border-radius: 999px;
  border: 1px solid transparent;
  color: var(--muted);
}

.main-nav a:hover {
  color: var(--text);
  border-color: rgba(168, 130, 255, 0.4);
  background: rgba(140, 100, 255, 0.12);
}

.nav-right {
  display: flex;
  align-items: center;
  gap: 10px;
  justify-self: end;
}

.site-footer {
  position: relative;
  z-index: 1;
  margin-top: 10px;
  padding: 14px 20px;
  text-align: center;
  font-size: 13px;
  color: var(--muted);
  border-top: 1px solid rgba(112, 132, 156, 0.3);
  background: rgba(8, 12, 18, 0.72);
  backdrop-filter: blur(10px);
}

.signin-btn,
.outline-btn {
  border: 0;
  cursor: pointer;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  padding: 10px 16px;
  border-radius: 999px;
  font-family: "Rajdhani", "Sora", sans-serif;
  font-weight: 700;
  letter-spacing: 0.04em;
}

.signin-btn {
  background: linear-gradient(135deg, var(--orange), #6d3df2);
  color: #f7f4ff;
  border: 1px solid rgba(186, 161, 255, 0.5);
}

.outline-btn {
  background: rgba(20, 31, 44, 0.6);
  color: var(--text);
  border: 1px solid rgba(125, 144, 168, 0.4);
}

.scale-on-hover {
  transition: transform 0.14s ease, box-shadow 0.2s ease;
}

.scale-on-hover:hover {
  transform: translateY(-1px) scale(1.05);
  box-shadow: 0 10px 24px rgba(0, 0, 0, 0.35);
}

.user-menu {
  position: relative;
}

.user-menu summary {
  list-style: none;
  cursor: pointer;
  display: inline-flex;
  align-items: center;
  gap: 10px;
  padding: 7px 10px;
  border-radius: 999px;
  border: 1px solid rgba(123, 145, 173, 0.4);
  background: rgba(18, 27, 38, 0.8);
}

.user-menu summary::-webkit-details-marker {
  display: none;
}

.user-avatar {
  width: 28px;
  height: 28px;
  border-radius: 50%;
  border: 1px solid rgba(190, 163, 255, 0.7);
}

.user-dropdown {
  position: absolute;
  right: 0;
  top: calc(100% + 8px);
  min-width: 150px;
  border: 1px solid rgba(124, 144, 167, 0.45);
  border-radius: 12px;
  background: rgba(14, 21, 31, 0.95);
  overflow: hidden;
  box-shadow: var(--shadow);
}

.user-dropdown a {
  display: block;
  padding: 10px 12px;
}

.user-dropdown a:hover {
  background: rgba(139, 92, 246, 0.16);
}

.page {
  width: min(1280px, calc(100% - 36px));
  margin: 26px auto 60px;
  display: grid;
  gap: 18px;
}

.hero {
  padding: 26px;
  border-radius: 22px;
  border: 1px solid rgba(122, 148, 180, 0.35);
  background: linear-gradient(130deg, rgba(139, 92, 246, 0.2), rgba(40, 123, 187, 0.15));
}

.eyebrow {
  margin: 0 0 8px;
  color: var(--orange-soft);
  text-transform: uppercase;
  letter-spacing: 0.14em;
  font-size: 12px;
}

.hero h1 {
  margin: 0;
  font-size: clamp(34px, 4vw, 56px);
  font-family: "Rajdhani", "Sora", sans-serif;
  line-height: 0.95;
}

.hero p {
  margin: 8px 0 0;
  max-width: 700px;
  color: var(--muted);
}

.menu-hero h1 {
  margin-bottom: 10px;
}

.video-section {
  border: 1px solid rgba(113, 138, 166, 0.35);
  border-radius: var(--radius);
  background: linear-gradient(180deg, rgba(13, 21, 30, 0.94), rgba(9, 14, 21, 0.96));
  box-shadow: var(--shadow);
  padding: 18px;
}

.video-section h2 {
  margin: 0 0 12px;
  font-size: 26px;
}

.video-frame {
  position: relative;
  width: min(100%, 1080px);
  margin: 0 auto;
  aspect-ratio: 16 / 9;
  border-radius: 14px;
  overflow: hidden;
  border: 1px solid rgba(255, 255, 255, 0.14);
  background: #000;
}

.video-frame iframe {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  border: 0;
}

.hero-stat {
  margin-top: 16px;
  display: inline-flex;
  align-items: center;
  gap: 8px;
  padding: 10px 14px;
  border-radius: 999px;
  background: rgba(8, 14, 21, 0.55);
  border: 1px solid rgba(120, 143, 170, 0.38);
  color: #d6e7f7;
}

.hero-stat strong {
  color: var(--orange-soft);
  font-size: 18px;
}

.podium-shell {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 16px;
  align-items: end;
}

.podium-card {
  position: relative;
  padding: 48px 18px 18px;
  border-radius: 18px;
  border: 1px solid rgba(115, 140, 170, 0.34);
  background: linear-gradient(180deg, rgba(20, 29, 40, 0.93), rgba(10, 15, 22, 0.95));
  box-shadow: var(--shadow);
  text-align: center;
  min-height: 280px;
}

.podium-card.first {
  transform: translateY(-16px);
  padding-top: 56px;
  background: linear-gradient(180deg, rgba(139, 92, 246, 0.3), rgba(20, 14, 38, 0.9));
  border-color: rgba(176, 142, 255, 0.48);
}

.podium-badge-wrap {
  position: absolute;
  left: 50%;
  top: -36px;
  transform: translateX(-50%);
  z-index: 2;
  pointer-events: none;
  animation: coin-bounce 1.35s ease-in-out infinite;
}

.podium-badge-img {
  width: 72px;
  height: 72px;
  object-fit: contain;
  filter: drop-shadow(0 0 12px rgba(255, 206, 104, 0.35));
}

.podium-card.first .podium-badge-wrap {
  top: -44px;
}

.podium-card.first .podium-badge-img {
  width: 84px;
  height: 84px;
}

.podium-card:nth-child(1) .podium-badge-wrap {
  animation-delay: 0s;
}

.podium-card:nth-child(2) .podium-badge-wrap {
  animation-delay: 0.18s;
}

.podium-card:nth-child(3) .podium-badge-wrap {
  animation-delay: 0.33s;
}

@keyframes coin-bounce {
  0%,
  100% {
    transform: translateX(-50%) translateY(-8px);
  }
  50% {
    transform: translateX(-50%) translateY(8px);
  }
}

@media (prefers-reduced-motion: reduce) {
  .podium-badge-wrap {
    animation: none;
  }
}

.podium-rank {
  position: absolute;
  top: 10px;
  right: 10px;
  border-radius: 999px;
  padding: 4px 10px;
  font-size: 12px;
  font-weight: 700;
  background: rgba(139, 92, 246, 0.24);
  border: 1px solid rgba(176, 142, 255, 0.5);
}

.podium-card > img {
  width: 86px;
  height: 86px;
  border-radius: 50%;
  border: 2px solid rgba(182, 148, 255, 0.72);
}

.podium-card h3 {
  margin: 12px 0 6px;
  font-size: 20px;
}

.podium-value {
  margin: 0;
  font-size: 34px;
  font-weight: 800;
  color: #ddcbff;
}

.podium-sub {
  margin: 5px 0 0;
  color: var(--muted);
  letter-spacing: 0.05em;
}

.board-shell,
.profile-box,
.player-search-box,
.history-wrap {
  border: 1px solid rgba(113, 138, 166, 0.35);
  border-radius: var(--radius);
  background: linear-gradient(180deg, rgba(13, 21, 30, 0.94), rgba(9, 14, 21, 0.96));
  box-shadow: var(--shadow);
}

.filters {
  display: flex;
  flex-wrap: wrap;
  gap: 14px;
  justify-content: space-between;
  align-items: center;
  padding: 16px;
  border-bottom: 1px solid rgba(113, 138, 166, 0.24);
}

.metric-chips {
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
}

.metric-chip {
  border: 1px solid rgba(122, 146, 170, 0.4);
  background: rgba(14, 23, 34, 0.75);
  color: var(--text);
  border-radius: 999px;
  padding: 8px 12px;
  cursor: pointer;
  font-family: "Rajdhani", "Sora", sans-serif;
  font-weight: 700;
  letter-spacing: 0.04em;
}

.metric-chip.active {
  border-color: rgba(177, 144, 255, 0.68);
  background: rgba(139, 92, 246, 0.2);
  color: #e4d3ff;
}

.search-wrap {
  display: flex;
  align-items: center;
  gap: 10px;
}

#leaderboard-search,
.player-search-form input {
  width: min(380px, 72vw);
  border: 1px solid rgba(123, 145, 170, 0.45);
  background: rgba(9, 15, 23, 0.8);
  color: var(--text);
  border-radius: 999px;
  padding: 10px 14px;
  outline: none;
}

#leaderboard-search:focus,
.player-search-form input:focus {
  border-color: rgba(175, 141, 255, 0.7);
}

.table-wrap {
  overflow: auto;
}

.pagination-wrap {
  display: flex;
  align-items: center;
  justify-content: flex-end;
  gap: 10px;
  padding: 12px 16px 16px;
}

#leaderboard-page-info {
  color: var(--muted);
  font-size: 13px;
  min-width: 90px;
  text-align: center;
}

table {
  width: 100%;
  border-collapse: collapse;
}

th,
td {
  text-align: left;
  padding: 12px 14px;
  border-bottom: 1px solid rgba(98, 121, 145, 0.26);
}

th {
  color: #e6c89d;
  font-size: 13px;
  letter-spacing: 0.04em;
}

tbody tr:hover {
  background: rgba(139, 92, 246, 0.1);
}

.rank-cell {
  color: #dac7ff;
  font-weight: 700;
}

.player-cell {
  display: flex;
  align-items: center;
  gap: 10px;
  min-width: 240px;
}

.player-cell img {
  width: 34px;
  height: 34px;
  border-radius: 50%;
  border: 1px solid rgba(183, 151, 255, 0.58);
}

.player-cell small {
  display: block;
  color: var(--muted);
  font-size: 11px;
}

.profile-hero {
  display: flex;
  align-items: center;
  gap: 16px;
  padding: 18px;
  border-radius: var(--radius);
  border: 1px solid rgba(109, 134, 162, 0.34);
  background: linear-gradient(130deg, rgba(139, 92, 246, 0.18), rgba(48, 133, 199, 0.14));
}

.profile-hero img {
  width: 74px;
  height: 74px;
  border-radius: 50%;
  border: 2px solid rgba(183, 151, 255, 0.72);
}

.profile-hero h1 {
  margin: 2px 0 4px;
}

.stats-grid {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 12px;
}

.stat-card {
  border: 1px solid rgba(113, 137, 165, 0.38);
  border-radius: 14px;
  padding: 14px;
  background: rgba(10, 18, 27, 0.75);
}

.stat-card p {
  margin: 0;
  color: var(--muted);
  letter-spacing: 0.05em;
  font-size: 12px;
}

.stat-card strong {
  display: block;
  margin-top: 8px;
  font-size: 24px;
  color: #e6d8ff;
}

.history-wrap {
  padding: 14px;
}

.history-wrap h2 {
  margin: 2px 4px 12px;
}

.ok {
  color: var(--ok);
  font-weight: 700;
}

.ko {
  color: var(--ko);
  font-weight: 700;
}

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

.player-search-box {
  padding: 18px;
}

.player-search-box h1 {
  margin: 0;
}

.player-search-form {
  margin-top: 12px;
  display: flex;
  gap: 10px;
  flex-wrap: wrap;
}

.profile-box {
  padding: 18px;
}

.empty-state {
  border: 1px dashed rgba(120, 147, 178, 0.45);
  border-radius: 14px;
  padding: 24px;
  color: var(--muted);
  text-align: center;
}

.match-history-hero {
  text-align: center;
  padding: 18px 12px 6px;
}

.match-history-hero h1 {
  margin: 0;
  font-family: "Rajdhani", "Sora", sans-serif;
  font-size: clamp(36px, 4.2vw, 58px);
}

.match-history-hero p {
  margin: 8px 0 0;
  color: var(--muted);
}

.match-history-filters {
  width: min(420px, 100%);
  margin: 0 auto;
  padding: 14px;
  border: 1px solid rgba(113, 138, 166, 0.35);
  border-radius: 14px;
  background: linear-gradient(180deg, rgba(13, 21, 30, 0.94), rgba(9, 14, 21, 0.96));
  box-shadow: var(--shadow);
  display: grid;
  gap: 12px;
}

.match-history-filters label {
  display: grid;
  gap: 6px;
}

.match-history-filters span {
  color: var(--muted);
  font-size: 12px;
  letter-spacing: 0.08em;
  font-weight: 700;
}

.match-history-filters select {
  border: 1px solid rgba(123, 145, 170, 0.45);
  background: rgba(9, 15, 23, 0.8);
  color: var(--text);
  border-radius: 10px;
  padding: 10px 12px;
  outline: none;
  font-family: "Sora", "Segoe UI", sans-serif;
  font-weight: 600;
}

.match-history-filters select:focus {
  border-color: rgba(175, 141, 255, 0.7);
}

.match-history-grid {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 16px;
}

.match-card {
  border: 1px solid rgba(113, 138, 166, 0.35);
  border-radius: var(--radius);
  background: linear-gradient(180deg, rgba(13, 21, 30, 0.94), rgba(9, 14, 21, 0.96));
  box-shadow: var(--shadow);
  overflow: hidden;
}

.match-card-header {
  display: flex;
  justify-content: space-between;
  gap: 14px;
  align-items: flex-start;
  padding: 14px 14px 10px;
  border-bottom: 1px solid rgba(98, 121, 145, 0.26);
}

.match-card-header h3 {
  margin: 0;
  font-family: "Rajdhani", "Sora", sans-serif;
  font-size: 27px;
}

.match-card-header p {
  margin: 4px 0 0;
  color: var(--muted);
  font-size: 12px;
}

.match-card-actions {
  display: inline-flex;
  gap: 8px;
  flex-wrap: wrap;
  justify-content: flex-end;
}

.mini-btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  padding: 7px 11px;
  border-radius: 8px;
  font-size: 12px;
  letter-spacing: 0.04em;
  font-weight: 700;
}

.mini-btn-disabled {
  border: 1px solid rgba(105, 122, 141, 0.35);
  background: rgba(16, 24, 33, 0.5);
  color: var(--muted);
}

.match-card-body {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 12px;
  padding: 14px;
}

.team-panel {
  border: 1px solid rgba(113, 138, 166, 0.35);
  border-radius: 12px;
  padding: 10px;
  background: rgba(9, 15, 22, 0.7);
}

.team-panel h4 {
  margin: 0 0 10px;
  font-size: 22px;
  font-family: "Rajdhani", "Sora", sans-serif;
}

.winner-panel h4 {
  color: var(--ok);
}

.loser-panel h4 {
  color: var(--ko);
}

.team-list {
  margin: 0;
  padding: 0;
  list-style: none;
  display: grid;
  gap: 7px;
}

.team-entry {
  display: flex;
  justify-content: space-between;
  gap: 10px;
  align-items: center;
  font-size: 14px;
}

.team-entry.empty {
  justify-content: flex-start;
}

.delta-pos {
  color: var(--ok);
}

.delta-neg {
  color: var(--ko);
}

.match-card-footer {
  display: flex;
  justify-content: space-between;
  gap: 10px;
  align-items: center;
  padding: 10px 14px 14px;
  border-top: 1px solid rgba(98, 121, 145, 0.2);
  color: var(--muted);
  font-size: 12px;
}

.transcript-wrap {
  border: 1px solid rgba(113, 138, 166, 0.35);
  border-radius: var(--radius);
  background: linear-gradient(180deg, rgba(13, 21, 30, 0.94), rgba(9, 14, 21, 0.96));
  box-shadow: var(--shadow);
  overflow: hidden;
}

.transcript-header {
  padding: 18px;
  border-bottom: 1px solid rgba(98, 121, 145, 0.26);
}

.transcript-header h1 {
  margin: 0;
  font-size: clamp(30px, 3.4vw, 48px);
  font-family: "Rajdhani", "Sora", sans-serif;
}

.transcript-header p {
  margin: 8px 0 0;
  color: var(--muted);
}

.transcript-list {
  display: grid;
  gap: 10px;
  padding: 14px;
}

.transcript-message {
  border-left: 2px solid rgba(255, 76, 76, 0.95);
  padding: 8px 10px 8px 12px;
  background: rgba(9, 15, 22, 0.55);
  border-radius: 10px;
}

.transcript-message-head {
  display: flex;
  gap: 10px;
  align-items: baseline;
  flex-wrap: wrap;
}

.transcript-message-head strong {
  color: #dde7f6;
}

.transcript-message-head span {
  color: var(--muted);
  font-size: 12px;
}

.transcript-message-body {
  margin-top: 6px;
  display: grid;
  gap: 7px;
}

.transcript-text {
  white-space: normal;
  word-break: break-word;
  color: #e9edf3;
  line-height: 1.45;
}

.transcript-embed {
  border: 1px solid rgba(113, 138, 166, 0.35);
  border-radius: 10px;
  padding: 8px 10px;
  background: rgba(14, 24, 35, 0.75);
}

.transcript-embed p {
  margin: 0;
}

.transcript-embed-fields {
  margin-top: 6px;
  display: grid;
  gap: 6px;
}

.transcript-embed-field {
  display: grid;
  gap: 2px;
  font-size: 13px;
  color: #dce7f5;
}

.transcript-embed-field strong {
  color: #f0f6ff;
}

.transcript-attachments {
  font-size: 13px;
  color: var(--muted);
}

.transcript-attachments a {
  color: #cdb1ff;
  text-decoration: underline;
}

.transcript-meta {
  font-size: 12px;
  color: var(--muted);
}

.transcript-footer {
  border-top: 1px solid rgba(98, 121, 145, 0.26);
  background: rgba(6, 10, 15, 0.75);
  color: #dbe6f2;
  padding: 14px 16px;
}

.tournament-filter-shell {
  display: flex;
  align-items: center;
  flex-wrap: wrap;
  gap: 10px;
  margin: 0 auto 14px;
  width: min(1120px, 100%);
  padding: 0 16px;
}

.tournament-filter-shell label {
  color: #d6e2f5;
  font-weight: 700;
}

.tournament-filter-shell select {
  border: 1px solid rgba(126, 160, 203, 0.4);
  background: rgba(8, 14, 23, 0.92);
  color: #e9f1fb;
  border-radius: 10px;
  padding: 8px 12px;
}

.tournament-list {
  width: min(1120px, 100%);
  margin: 0 auto;
  display: grid;
  gap: 16px;
  padding: 0 16px 18px;
}

.tournament-list-header {
  width: min(1120px, 100%);
  margin: 0 auto;
  padding: 0 16px 10px;
}

.tournament-list-header h2 {
  margin: 0;
}

.tournament-card {
  border: 1px solid rgba(88, 117, 156, 0.34);
  border-radius: 16px;
  background: rgba(7, 12, 20, 0.82);
  overflow: hidden;
}

.tournament-card-head {
  padding: 14px 16px;
  border-bottom: 1px solid rgba(90, 120, 156, 0.24);
}

.tournament-card-head h2 {
  margin: 0;
}

.tournament-card-head p {
  margin: 6px 0 0;
  color: var(--muted);
}

.tournament-participants {
  padding: 12px 16px;
  color: #dce8f9;
  border-bottom: 1px solid rgba(90, 120, 156, 0.18);
}

.tournament-rounds {
  display: grid;
  gap: 12px;
  padding: 12px 16px 16px;
}

.tournament-round h3 {
  margin: 0 0 10px;
}

.tournament-round-matches {
  display: grid;
  gap: 10px;
}

.tournament-match-card {
  border: 1px solid rgba(118, 149, 194, 0.3);
  border-radius: 12px;
  background: rgba(12, 20, 33, 0.8);
  padding: 10px;
}

.tournament-match-head {
  display: flex;
  justify-content: space-between;
  gap: 10px;
  align-items: center;
  margin-bottom: 8px;
}

.tournament-match-team {
  border: 1px solid rgba(114, 146, 185, 0.26);
  border-radius: 10px;
  padding: 8px;
  background: rgba(7, 13, 22, 0.8);
}

.tournament-match-team.winner {
  border-color: rgba(55, 216, 157, 0.7);
}

.tournament-team-name {
  font-weight: 700;
}

.tournament-team-players {
  margin-top: 4px;
  font-size: 13px;
  color: #d2e1f5;
}

.tournament-match-vs {
  text-align: center;
  font-weight: 700;
  color: #96abc9;
  margin: 6px 0;
}

.tournament-actions {
  display: flex;
  gap: 8px;
  margin-top: 10px;
}

.tournament-actions form {
  margin: 0;
}

.tournament-history-list {
  width: min(1120px, 100%);
  margin: 0 auto 18px;
  display: grid;
  gap: 10px;
  padding: 0 16px;
}

.tournament-history-item {
  border: 1px solid rgba(88, 117, 156, 0.34);
  border-radius: 12px;
  background: rgba(7, 12, 20, 0.82);
  padding: 12px 14px;
}

.tournament-history-item-head {
  display: flex;
  justify-content: space-between;
  gap: 12px;
  align-items: center;
}

.tournament-history-item p {
  margin: 8px 0 0;
  color: var(--muted);
}

.reports-hero {
  text-align: center;
  padding: 18px 12px 6px;
}

.reports-hero h1 {
  margin: 0;
  font-family: "Rajdhani", "Sora", sans-serif;
  font-size: clamp(32px, 4vw, 52px);
}

.reports-hero p {
  margin: 8px 0 0;
  color: var(--muted);
}

.reports-columns {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 16px;
}

.reports-column {
  border: 1px solid rgba(113, 138, 166, 0.35);
  border-radius: var(--radius);
  background: linear-gradient(180deg, rgba(13, 21, 30, 0.94), rgba(9, 14, 21, 0.96));
  box-shadow: var(--shadow);
  overflow: hidden;
}

.reports-column h2 {
  margin: 0;
  padding: 14px;
  border-bottom: 1px solid rgba(98, 121, 145, 0.26);
  font-family: "Rajdhani", "Sora", sans-serif;
  font-size: 24px;
}

.reports-list {
  display: grid;
  gap: 10px;
  padding: 12px;
}

.report-ticket-card {
  border: 1px solid rgba(113, 138, 166, 0.35);
  border-radius: 12px;
  background: rgba(9, 15, 22, 0.72);
  overflow: hidden;
}

.report-ticket-head {
  display: flex;
  justify-content: space-between;
  align-items: flex-start;
  gap: 10px;
  padding: 12px;
  border-bottom: 1px solid rgba(98, 121, 145, 0.22);
}

.report-ticket-head h3 {
  margin: 0;
  font-size: 20px;
  font-family: "Rajdhani", "Sora", sans-serif;
}

.report-ticket-head p {
  margin: 4px 0 0;
  color: var(--muted);
  font-size: 12px;
}

.report-ticket-body {
  padding: 12px;
  display: grid;
  gap: 8px;
}

.report-ticket-body p {
  margin: 0;
  line-height: 1.45;
  word-break: break-word;
}

.report-ticket-body a {
  color: #cdb1ff;
  text-decoration: underline;
}

.report-replies-wrap {
  display: grid;
  gap: 8px;
}

.report-replies-list {
  display: grid;
  gap: 8px;
}

.report-replies-empty {
  font-size: 13px;
}

.report-reply {
  border: 1px solid rgba(113, 138, 166, 0.28);
  border-radius: 10px;
  padding: 8px 10px;
  background: rgba(10, 17, 26, 0.8);
}

.report-reply-staff {
  border-left: 3px solid var(--ok);
}

.report-reply-user {
  border-left: 3px solid var(--blue-soft);
}

.report-reply header {
  display: flex;
  align-items: center;
  gap: 8px;
  flex-wrap: wrap;
  margin-bottom: 4px;
}

.report-reply header strong {
  font-size: 13px;
}

.report-reply header span {
  color: var(--muted);
  font-size: 12px;
}

.reply-dm-status {
  margin-left: auto;
  font-size: 11px;
}

.reply-dm-status-pending {
  color: #f7d774;
}

.reply-dm-status-sent {
  color: var(--ok);
}

.reply-dm-status-failed {
  color: var(--ko);
}

.report-reply-body {
  white-space: normal;
  word-break: break-word;
  line-height: 1.45;
}

.report-reply-form {
  display: grid;
  gap: 8px;
}

.report-reply-form textarea {
  border: 1px solid rgba(123, 145, 170, 0.45);
  background: rgba(9, 15, 23, 0.8);
  color: var(--text);
  border-radius: 10px;
  padding: 10px 12px;
  outline: none;
  resize: vertical;
  min-height: 84px;
  font-family: "Sora", "Segoe UI", sans-serif;
}

.report-reply-form textarea:focus {
  border-color: rgba(175, 141, 255, 0.7);
}

.report-status-open {
  color: var(--ok);
}

.report-status-closed {
  color: var(--ko);
}

@media (max-width: 980px) {
  .main-nav {
    display: none;
  }

  .podium-shell {
    grid-template-columns: 1fr;
  }

  .podium-card.first {
    transform: none;
  }

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

  .search-wrap {
    width: 100%;
    flex-wrap: wrap;
  }

  #leaderboard-search {
    width: 100%;
  }

  .pagination-wrap {
    justify-content: center;
    flex-wrap: wrap;
  }

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

  .match-history-grid {
    grid-template-columns: 1fr;
  }

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

@media (max-width: 640px) {
  .page {
    width: calc(100% - 20px);
    margin-top: 16px;
  }

  .topbar {
    padding: 10px 12px;
  }

  .brand {
    min-height: 44px;
  }

  .brand-logo {
    height: 44px;
  }

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

  .match-card-body {
    grid-template-columns: 1fr;
  }

  .match-card-header {
    flex-direction: column;
  }
}
