body.page-elo .content {
  padding-left: 0;
  padding-right: 72px;
}
.page-elo-main .ess-views {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 6px;
  margin: 0 0 4px;
}
.page-elo-main .elo-side-sep {
  height: 1px;
  margin: 8px 0 6px;
  background: var(--line);
}
.page-elo-main .ess-views.is-hero-kpis .f1-dash-item {
  min-width: 0;
  width: auto;
  border: 1px solid var(--line);
  background: color-mix(in srgb, var(--panel) 88%, transparent);
  border-radius: 12px;
  box-shadow: var(--shadow);
  padding: 8px 10px 10px;
  cursor: default;
}
.page-elo-main .elo-goto-me {
  width: 100%;
  margin: 0 0 10px;
  justify-content: center;
}
.page-elo-main .elo-formula-link {
  display: block;
  text-align: center;
  text-decoration: none;
  color: var(--text);
}
.elo-rank-board .champ-pw-cal { max-height: none; overflow: visible; }
.elo-rank-board .champ-pw-row { min-width: 0; width: 100%; }
.elo-rank-board .champ-pw-id {
  grid-template-columns: 40px minmax(0, 1fr);
  width: 240px;
  min-width: 200px;
}
.elo-rank-board .champ-pw-rounds { flex: 1 1 auto; min-width: 0; }
.elo-rank-board .elo-kpi-h,
.elo-rank-board .rd.elo-kpi-cell,
.elo-rank-board .rd.elo-history-btn {
  flex: 1 1 0;
  width: auto;
  min-width: 0;
  max-width: none;
}
.elo-rank-board .elo-kpi-h {
  height: auto;
  min-height: 52px;
  cursor: pointer;
  gap: 4px;
  padding: 6px 4px;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  text-align: center;
}
.elo-rank-board .elo-kpi-h.is-static { cursor: default; }
.elo-rank-board .elo-kpi-h i,
.elo-rank-board .elo-kpi-h svg {
  display: block;
  flex: 0 0 auto;
  margin: 0 auto;
  font-size: 15px;
  color: var(--cyan);
}
.elo-rank-board .elo-kpi-h span {
  display: block;
  width: 100%;
  text-align: center;
  font-size: 9px;
  font-weight: 800;
  letter-spacing: .2px;
  text-transform: uppercase;
  color: var(--muted);
}
.elo-rank-board .champ-pw-who-txt {
  overflow: hidden;
}
.elo-rank-board .champ-pw-pilot.elo-pilot {
  display: block;
  max-width: 100%;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}
.elo-rank-board .elo-me-tag {
  display: inline-block;
  margin-top: 2px;
  font-size: 8px;
  font-weight: 800;
  letter-spacing: .4px;
  text-transform: uppercase;
  color: #f5c518;
}
.elo-rank-board .champ-pw-row.is-me,
.elo-rank-board .champ-pw-row.is-me .champ-pw-id {
  background: color-mix(in srgb, #f5c518 16%, var(--panel));
}
.elo-rank-board .champ-pw-row.is-me .rd.elo-kpi-cell,
.elo-rank-board .champ-pw-row.is-me .rd.elo-history-btn {
  background: color-mix(in srgb, #f5c518 16%, var(--panel2));
  border-color: color-mix(in srgb, #f5c518 40%, var(--line));
}
.elo-rank-board .elo-kpi-h.is-sort {
  border-color: var(--red);
  background: color-mix(in srgb, var(--red) 12%, var(--panel2));
}
.elo-rank-board .elo-kpi-cell {
  cursor: default;
  min-height: 42px;
  font-weight: 800;
}
.elo-rank-board .elo-val {
  color: var(--cyan);
  font-weight: 900;
  font-size: 16px;
}
.elo-rank-board .elo-ratio.is-ratio-top { color: #c9a6ff; font-weight: 900; }
.elo-avatar-ring {
  display: block;
  box-sizing: border-box;
  width: 40px;
  height: 40px;
  border-radius: 50%;
  padding: 2px;
  overflow: hidden;
  background: conic-gradient(from 200deg, var(--cyan), var(--red), var(--cyan));
  flex: 0 0 auto;
}
.elo-avatar-ring img {
  display: block;
  width: 100%;
  height: 100%;
  border-radius: 50%;
  object-fit: cover;
}
.elo-rank-board .elo-history-btn {
  min-height: 42px;
}
.page-elo-main h1 {
  font-weight: 900;
  letter-spacing: var(--title-page-tracking, -1.5px);
  margin: 0 0 4px;
  color: var(--text);
  font-size: var(--title-page-size, clamp(28px, 4vw, 42px));
  line-height: 0.95;
}
.elo-toolbar .circ-sort input {
  width: 88px;
  height: 34px;
  padding: 0 8px;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: var(--panel2);
  color: var(--text);
  font-weight: 700;
  font-size: 13px;
}
.elo-toolbar .circ-pill {
  text-decoration: none;
}
.elo-board {
  position: relative;
  overflow: hidden;
  margin: 0 0 18px;
  border: 1px solid var(--line);
  border-radius: 16px;
  background:
    linear-gradient(180deg, rgba(245, 197, 24, 0.07), transparent 90px),
    var(--panel);
  box-shadow: var(--shadow);
}
.elo-board::after {
  content: "";
  position: absolute;
  right: -80px;
  top: -80px;
  width: 220px;
  height: 220px;
  border: 1px solid #ff304f44;
  border-radius: 50%;
  box-shadow: 0 0 0 34px #ff304f0d, 0 0 0 68px #ff304f08;
  pointer-events: none;
  z-index: 0;
}
.elo-board > * { position: relative; z-index: 1; }
.elo-table-wrap {
  margin: 12px;
  border: 1px solid var(--line);
  border-radius: 12px;
  background: color-mix(in srgb, var(--panel2) 78%, transparent);
  overflow: auto;
}
#eloTable {
  width: 100%;
  border-collapse: collapse;
  color: var(--text);
}
#eloTable th,
#eloTable td {
  padding: 10px 12px;
  border-bottom: 1px solid var(--line);
  vertical-align: middle;
  white-space: nowrap;
}
#eloTable {
  font-size: var(--table-font, 12px);
  border-collapse: collapse;
}
#eloTable thead th {
  font-size: var(--table-th-size, 9px);
  font-weight: 800;
  letter-spacing: 1px;
  text-transform: uppercase;
  color: var(--muted);
  background: transparent;
  cursor: pointer;
  user-select: none;
  padding: 11px 8px;
}
#eloTable thead th:nth-child(3) { cursor: default; }
#eloTable thead th.is-on { color: var(--text); }
#eloTable thead th.is-on::after { content: " ▾"; font-size: 9px; }
#eloTable thead th.is-on.is-asc::after { content: " ▴"; }
#eloTable tbody tr:hover { background: rgba(255, 255, 255, 0.05); }
#eloTable tbody tr.is-gold { background: linear-gradient(90deg, rgba(245, 197, 24, 0.16), transparent 70%); }
#eloTable tbody tr.is-silver { background: linear-gradient(90deg, rgba(180, 196, 214, 0.14), transparent 70%); }
#eloTable tbody tr.is-bronze { background: linear-gradient(90deg, rgba(196, 124, 72, 0.16), transparent 70%); }
.elo-rank-n {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 28px;
  height: 28px;
  border-radius: 8px;
  font-size: 12px;
  font-weight: 900;
  color: var(--muted);
  background: rgba(255, 255, 255, 0.04);
}
tr.is-gold .elo-rank-n { color: #1a1404; background: #f5c518; }
tr.is-silver .elo-rank-n { color: #1a1f26; background: #c5d0dc; }
tr.is-bronze .elo-rank-n { color: #1a1008; background: #d08a4a; }
.elo-pilot {
  border: 0;
  background: none;
  padding: 0;
  color: var(--text);
  font-weight: 800;
  cursor: pointer;
  text-align: left;
}
.elo-pilot:hover { color: var(--red); text-decoration: underline; }
.pw-page #eloTable tbody td.evo-up,
#eloTable td.evo-up {
  color: #42e6a4 !important;
  font-weight: 800;
}
.pw-page #eloTable tbody td.evo-down,
#eloTable td.evo-down {
  color: #ff304f !important;
  font-weight: 800;
}
.pw-page #eloTable tbody td.evo-zero,
#eloTable td.evo-zero {
  color: #f5c518 !important;
  font-weight: 800;
}
.pw-page #eloTable td.elo-val,
#eloTable td.elo-val { color: var(--cyan); font-weight: 900; font-size: 15px; }
.pw-page #eloTable tbody td.elo-ratio.is-ratio-top,
#eloTable td.elo-ratio.is-ratio-top {
  color: #c9a6ff !important;
  font-weight: 900;
}
.elo-history-btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 32px;
  height: 32px;
  border-radius: 8px;
  background: rgba(255, 255, 255, 0.04);
  color: var(--text);
  cursor: pointer;
  border: 1px solid var(--line);
}
.elo-history-btn:hover {
  border-color: var(--red);
  color: var(--red);
}
.elo-history-btn svg {
  width: 16px;
  height: 16px;
  fill: currentColor;
}
.elo-formula {
  background:
    linear-gradient(180deg, rgba(255, 48, 79, 0.08), transparent 90px),
    var(--panel);
}
.elo-formula > header {
  padding: 16px 16px 0;
}
.elo-formula h2 {
  margin: 0;
  font-size: 22px;
  font-weight: 900;
  color: var(--red);
}
.elo-formula-body {
  padding: 12px 16px 18px;
  font-size: 14px;
  font-weight: 650;
  color: var(--text);
  line-height: 1.5;
}
.elo-formula-body p { margin: 0 0 10px; }
.elo-formula-body ul { margin: 0 0 10px; padding-left: 18px; }
.elo-formula-eq {
  text-align: center;
  font-weight: 900;
  color: var(--cyan);
}
.elo-history-modal {
  background: var(--panel);
  color: var(--text);
  border: 1px solid var(--line);
  border-radius: 16px;
  overflow: hidden;
  box-shadow: var(--shadow);
}
.elo-history-modal .modal-header {
  border-bottom: 1px solid var(--line);
  background: linear-gradient(180deg, rgba(245, 197, 24, 0.10), transparent);
  padding: 14px 16px;
}
.elo-history-modal .modal-title {
  font-weight: 900;
  letter-spacing: -0.4px;
  color: #f5c518;
}
.elo-history-modal .modal-body {
  padding: 14px 16px 16px;
}
.elo-hist-toolbar {
  display: flex;
  flex-wrap: wrap;
  align-items: flex-end;
  gap: 10px;
  margin-bottom: 12px;
}
.elo-hist-field {
  display: flex;
  flex-direction: column;
  gap: 4px;
  min-width: 160px;
  flex: 1 1 180px;
}
.elo-hist-field span {
  font-size: 9px;
  font-weight: 800;
  letter-spacing: .8px;
  text-transform: uppercase;
  color: var(--muted);
}
.elo-hist-field select {
  height: 36px;
  padding: 0 10px;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: var(--panel2);
  color: var(--text);
  font-weight: 700;
  font-size: 13px;
}
.elo-hist-go {
  height: 36px;
  padding: 0 14px;
  border: 1px solid var(--red);
  border-radius: 999px;
  background: var(--red);
  color: #fff;
  font-weight: 800;
  font-size: 12px;
}
.elo-hist-go:hover { filter: brightness(1.08); }
.elo-hist-toolbar .circ-pill {
  height: 36px;
}
.elo-hist-toolbar .circ-pill.is-on {
  border-color: var(--cyan);
  color: var(--cyan);
  background: rgba(35, 217, 255, 0.12);
}
.elo-chart-box {
  position: relative;
  overflow: hidden;
  height: 360px;
  border: 1px solid var(--line);
  border-radius: 12px;
  background:
    radial-gradient(ellipse 48% 38% at 100% 0%, color-mix(in srgb, var(--cyan) 10%, transparent), transparent 58%),
    var(--panel2);
  padding: 8px;
}
.elo-chart-note {
  margin: 12px 0 0;
  font-size: 12px;
  font-weight: 700;
  color: var(--muted);
}
html[data-theme="day"] .elo-history-btn {
  background: #fff;
}
@media (max-width: 900px) {
  body.page-elo .content { padding-right: 16px; }
}
