:root {
  --bg: #070b17;
  --bg-2: #0b1325;
  --panel: rgba(11, 19, 37, 0.78);
  --line: rgba(88, 123, 255, 0.28);
  --cyan: #37d9ff;
  --cyan-soft: #79ecff;
  --green: #27e46c;
  --white: #f3f7ff;
  --muted: #9bb2d1;
  --pink: #d14dff;
  --shadow: 0 10px 40px rgba(0, 0, 0, 0.4);
}

* { box-sizing: border-box; }

body {
  margin: 0;
  font-family: Inter, Pretendard, Arial, sans-serif;
  color: var(--white);
  background:
    radial-gradient(circle at 15% 20%, rgba(55, 217, 255, 0.18), transparent 28%),
    radial-gradient(circle at 85% 15%, rgba(209, 77, 255, 0.16), transparent 20%),
    linear-gradient(135deg, #02040b 0%, #07101d 40%, #050914 100%);
  min-height: 100vh;
}

body::before {
  content: "";
  position: fixed;
  inset: 0;
  pointer-events: none;
  background-image:
    linear-gradient(rgba(55, 217, 255, 0.08) 1px, transparent 1px),
    linear-gradient(90deg, rgba(55, 217, 255, 0.08) 1px, transparent 1px);
  background-size: 48px 48px;
  mask-image: linear-gradient(to bottom, rgba(255,255,255,0.45), transparent 80%);
}

.wrap {
  width: min(1400px, calc(100% - 32px));
  margin: 28px auto 40px;
}

.hero {
  position: relative;
  overflow: hidden;
  border: 1px solid var(--line);
  border-radius: 24px;
  padding: 28px;
  background: linear-gradient(135deg, rgba(10,16,33,0.94), rgba(5,10,21,0.9));
  box-shadow: var(--shadow);
}

.hero::after {
  content: "";
  position: absolute;
  inset: auto -80px -80px auto;
  width: 260px;
  height: 260px;
  border-radius: 50%;
  background: radial-gradient(circle, rgba(55,217,255,0.22), transparent 70%);
  filter: blur(8px);
}

.eyebrow {
  display: inline-block;
  font-size: 12px;
  letter-spacing: 0.18em;
  text-transform: uppercase;
  color: var(--cyan-soft);
  margin-bottom: 10px;
}

h1 {
  margin: 0;
  line-height: 0.95;
  font-size: clamp(34px, 6vw, 78px);
  font-weight: 900;
  text-transform: uppercase;
}

h1 .cyan { color: var(--cyan); display: block; }
h1 .white { color: var(--white); display: block; }
h1 .green { color: var(--green); display: block; }

.sub {
  max-width: 780px;
  margin-top: 14px;
  color: var(--muted);
  font-size: 15px;
  line-height: 1.6;
}

.toolbar {
  margin-top: 22px;
  display: grid;
  grid-template-columns: 1.2fr 1fr 1fr auto auto;
  gap: 12px;
  align-items: end;
}

.field {
  display: flex;
  flex-direction: column;
  gap: 8px;
}

.field label {
  font-size: 12px;
  color: var(--cyan-soft);
  font-weight: 700;
  letter-spacing: 0.06em;
  text-transform: uppercase;
}

.input, .select, .btn {
  height: 46px;
  border-radius: 14px;
  border: 1px solid rgba(90, 136, 255, 0.26);
  background: rgba(10, 18, 34, 0.92);
  color: var(--white);
  padding: 0 14px;
  font-size: 14px;
  outline: none;
  transition: 0.2s ease;
}

.input:focus, .select:focus {
  border-color: rgba(55, 217, 255, 0.75);
  box-shadow: 0 0 0 3px rgba(55, 217, 255, 0.14);
}

.btn {
  cursor: pointer;
  font-weight: 800;
  padding: 0 18px;
  background: linear-gradient(135deg, rgba(55, 217, 255, 0.18), rgba(39, 228, 108, 0.18));
}

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

.panel {
  margin-top: 18px;
  background: var(--panel);
  border: 1px solid var(--line);
  border-radius: 22px;
  padding: 18px;
  box-shadow: var(--shadow);
  backdrop-filter: blur(8px);
}

.meta {
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: 12px;
  margin-bottom: 14px;
  flex-wrap: wrap;
}

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

.pill {
  padding: 8px 12px;
  border-radius: 999px;
  background: rgba(55, 217, 255, 0.08);
  border: 1px solid rgba(55, 217, 255, 0.16);
  color: var(--cyan-soft);
  font-size: 13px;
}

.table-wrap {
  overflow: auto;
  border-radius: 16px;
  border: 1px solid rgba(90, 136, 255, 0.18);
}

table {
  width: 100%;
  border-collapse: collapse;
  min-width: 900px;
  background: rgba(7, 13, 26, 0.92);
}

thead th {
  position: sticky;
  top: 0;
  z-index: 2;
  background: linear-gradient(180deg, rgba(13,23,45,0.98), rgba(8,15,28,0.98));
  color: var(--cyan-soft);
  text-transform: uppercase;
  letter-spacing: 0.06em;
  font-size: 12px;
  text-align: left;
  padding: 14px 16px;
  border-bottom: 1px solid rgba(90, 136, 255, 0.2);
  cursor: pointer;
  user-select: none;
  white-space: nowrap;
}

tbody td {
  padding: 14px 16px;
  border-bottom: 1px solid rgba(90, 136, 255, 0.09);
  color: #eaf2ff;
  font-size: 14px;
  vertical-align: middle;
}

tbody tr:hover {
  background: rgba(55, 217, 255, 0.04);
}

.rank {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-width: 34px;
  height: 34px;
  border-radius: 12px;
  font-weight: 900;
  color: #06111f;
  background: linear-gradient(135deg, var(--cyan), var(--green));
}

a.link {
  color: var(--cyan-soft);
  text-decoration: none;
  font-weight: 700;
  word-break: break-all;
}

a.link:hover { text-decoration: underline; }

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

.empty, .loading {
  padding: 34px 16px;
  text-align: center;
  color: var(--muted);
}

@media (max-width: 980px) {
  .toolbar {
    grid-template-columns: 1fr 1fr;
  }
  .toolbar .field:first-child {
    grid-column: 1 / -1;
  }
}

@media (max-width: 640px) {
  .wrap { width: min(100% - 20px, 100%); }
  .hero, .panel { padding: 16px; border-radius: 18px; }
  .toolbar { grid-template-columns: 1fr; }
  table { min-width: 720px; }
}
