:root{
  --glass: rgba(12,12,20,.78);
  --glass2: rgba(255,255,255,.06);
  --line: rgba(255,255,255,.10);
  --text: rgba(255,255,255,.90);
  --muted: rgba(255,255,255,.72);
  --pink: #ff2f92;
  --vio: #7a3cff;
}

*{ box-sizing:border-box; }

body{
  margin:0;
  min-height:100vh;
  font-family:"Bangers", system-ui, -apple-system, Segoe UI, Roboto, Arial, sans-serif;
  color:#fff;
  overflow-x:hidden;
  display:block !important;
  background:
    radial-gradient(circle at top, #2b145f 0%, transparent 40%),
    linear-gradient(135deg, #0b0b18, #140c2e, #0b0b18);
}

/* background layers */
.bg{
  position:fixed; inset:0;
  background: url("bg.jpg") center/cover no-repeat;
  opacity:.12;
  filter: blur(1px) saturate(1.1);
  pointer-events:none;
  z-index:0;
}
.stars{
  position:fixed; inset:0;
  pointer-events:none;
  z-index:1;
  background-image: radial-gradient(#ffffff22 1px, transparent 1px);
  background-size: 40px 40px;
  animation: starsMove 60s linear infinite;
}
@keyframes starsMove{
  from{ transform: translateY(0); }
  to{ transform: translateY(-200px); }
}

/* page width like your screenshot (wide) */
.page{
  position:relative;
  z-index:2;
  width:min(1180px, 96%);
  margin: 12px auto 36px;
}

/* ===== TOP NAV CARD (compact like screenshot) ===== */
.topcard{
  background: rgba(12,12,20,.55);
  border: 1px solid rgba(255,255,255,.08);
  border-radius: 18px;
  padding: 10px 14px 12px;
  box-shadow: 0 0 26px rgba(255,0,140,.14);
  backdrop-filter: blur(10px);
  display:flex;
  flex-direction:column;
  align-items:center;
  gap: 8px;
}

.topbrand{
  letter-spacing:2px;
  font-size: 14px;           /* менше, як на скріні */
  opacity:.95;
}

.topnav{
  display:flex;
  gap:10px;
  flex-wrap:wrap;
  justify-content:center;
}

.pill{
  font-family: Arial, sans-serif;
  text-decoration:none;
  color:#fff;
  opacity:.9;
  padding:8px 14px;
  border-radius: 999px;
  background: rgba(255,255,255,0.06);
  border: 1px solid rgba(255,255,255,0.08);
  transition: transform .12s ease, opacity .12s ease, background .12s ease;
  font-size: 13px;
}
.pill:hover{ opacity:1; transform: scale(1.02); background: rgba(255,255,255,0.09); }
.pill.active{
  background: linear-gradient(90deg, var(--pink), var(--vio));
  border-color: transparent;
  opacity:1;
}

.topsub{
  font-family: Arial, sans-serif;
  font-size: 11px;
  opacity: .70;
}

/* ===== MAIN CARD (more flat + wide like screenshot) ===== */
.card{
  margin-top: 12px;
  background: var(--glass);
  border: 1px solid rgba(255,255,255,.10);
  border-radius: 22px;
  padding: 16px 16px 14px;
  box-shadow: 0 0 28px rgba(255, 0, 140, 0.14);
  backdrop-filter: blur(10px);
}

/* header row like screenshot: title left, filters right */
.head{
  display:flex;
  align-items:flex-start;
  justify-content:space-between;
  gap: 12px;
}

.hicon{
  font-size: 42px;
  line-height: 1;
  margin-right: 10px;
}

.head > div:first-child{
  display:flex;
  gap:10px;
  align-items:flex-start;
}

h1{
  margin:0;
  font-size: 44px;
  letter-spacing: 2px;
}

.head p{
  margin: 6px 0 0;
  font-family: Arial, sans-serif;
  color: var(--muted);
  font-size: 13px;
}

.filters{
  display:flex;
  gap:10px;
  justify-content:flex-end;
  flex-wrap:wrap;
  margin-top: 6px;
}
.filters select{
  font-family: Arial, sans-serif;
  color:#fff;
  background: rgba(255,255,255,0.06);
  border: 1px solid rgba(255,255,255,0.10);
  border-radius: 12px;
  padding: 8px 10px;
  outline:none;
  font-size: 12px;
}

/* ===== TOP 3 PODIUM (exact vibe: 3 flat cards) ===== */
.top3{
  margin-top: 12px;
  display:grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 12px;
}

.podium{
  background: rgba(255,255,255,0.05);
  border: 1px solid rgba(255,255,255,0.08);
  border-radius: 16px;
  padding: 12px;
}

.place{
  font-family: Arial, sans-serif;
  font-size: 11px;
  opacity:.80;
  margin-bottom: 10px;
}

.avatar{
  width: 54px;
  height: 54px;
  border-radius: 14px;
  margin: 0 auto 8px;
  display:flex;
  align-items:center;
  justify-content:center;
  font-family: Arial, sans-serif;
  font-weight: 900;
  letter-spacing: 1px;
  background: linear-gradient(135deg, var(--pink), var(--vio));
  box-shadow: 0 0 14px rgba(255,0,140,0.22);
}

.nick{
  text-align:center;
  font-size: 16px;
  letter-spacing: 1px;
  margin-bottom: 6px;
  opacity:.95;
}

.meta{
  display:flex;
  justify-content:space-between;
  align-items:center;
  gap: 8px;
  font-family: Arial, sans-serif;
  font-size: 11px;
  color: var(--text);
  opacity:.95;
}
.badge{
  display:inline-flex;
  align-items:center;
  gap: 6px;
  padding: 6px 9px;
  border-radius: 999px;
  background: rgba(0,0,0,0.28);
  border: 1px solid rgba(255,255,255,0.08);
}

/* ===== TABLE (more like screenshot: flat, clear grid) ===== */
.table{
  margin-top: 12px;
  border-radius: 16px;
  overflow:hidden;
  border: 1px solid rgba(255,255,255,0.08);
  background: rgba(255,255,255,0.035);
}

.thead, .row{
  display:grid;
  grid-template-columns: 44px 1.6fr 0.8fr 0.7fr 0.7fr 0.55fr;
  gap: 10px;
  align-items:center;
}

.thead{
  padding: 10px 12px;
  font-family: Arial, sans-serif;
  font-size: 11px;
  opacity:.82;
  border-bottom: 1px solid rgba(255,255,255,0.08);
}

.tbody .row{
  padding: 10px 12px;
  border-bottom: 1px solid rgba(255,255,255,0.06);
  font-family: Arial, sans-serif;
  font-size: 12px;
}
.tbody .row:last-child{ border-bottom: none; }
.tbody .row:hover{
  background: rgba(255,255,255,0.03);
}

.player{
  display:flex;
  align-items:center;
  gap: 10px;
  min-width: 0;
}
.pfp{
  width: 34px;
  height: 34px;
  border-radius: 12px;
  background: rgba(255,255,255,0.10);
  display:flex;
  align-items:center;
  justify-content:center;
  font-weight: 900;
  letter-spacing: 1px;
}
.pname{
  white-space:nowrap;
  overflow:hidden;
  text-overflow:ellipsis;
}
.right{ text-align:right; }

.rankchip .rbadge{
  display:inline-flex;
  gap:6px;
  align-items:center;
  padding: 5px 9px;
  border-radius: 999px;
  background: rgba(0,0,0,0.28);
  border: 1px solid rgba(255,255,255,0.08);
}

/* ===== BUTTONS layout like screenshot (two rows, same height) ===== */
.btn{
  display:block;
  width:100%;
  border: none;
  cursor:pointer;
  text-decoration:none;
  text-align:center;
  padding: 12px 12px;
  border-radius: 14px;
  color:#fff;
  font-family: Arial, sans-serif;
  background: linear-gradient(90deg, var(--pink), var(--vio));
  transition: transform .12s ease, filter .12s ease;
}
.btn:hover{ transform: scale(1.01); filter: brightness(1.05); }

.btn.ghost{
  background: rgba(255,255,255,0.07);
  border: 1px solid rgba(255,255,255,0.10);
}

/* row 1: demo/clear, row 2: home/tests */
.actions, .footer{
  display:grid;
  grid-template-columns: 1fr 1fr;
  gap: 12px;
  margin-top: 12px;
}

.hint{
  margin-top: 10px;
  font-family: Arial, sans-serif;
  font-size: 12px;
  opacity: .82;
  text-align:center;
}

/* ===== responsive ===== */
@media (max-width: 860px){
  .head{
    flex-direction:column;
    align-items:flex-start;
  }
  .filters{ justify-content:flex-start; }
}

@media (max-width: 700px){
  .top3{ grid-template-columns: 1fr; }
  h1{ font-size: 38px; }

  .thead, .row{
    grid-template-columns: 36px 1.25fr 0.75fr 0.7fr;
  }

  /* hide tests + W on phones like before */
  .thead > div:nth-child(5),
  .thead > div:nth-child(6),
  .row  > div:nth-child(5),
  .row  > div:nth-child(6){
    display:none;
  }

  .actions, .footer{
    grid-template-columns: 1fr;
  }
}
