:root {
  --page-bg: #08111f;
  --page-bg-soft: #0f1d32;
  --panel-bg: #13233b;
  --panel-bg-soft: #172a46;
  --panel-border: rgba(151, 197, 255, 0.12);
  --row-dark: #14253e;
  --row-light: #182c49;
  --text: #edf5ff;
  --muted: #8ea8ca;
  --accent: #67b7ff;
  --accent-strong: #3f95ff;
  --gold: #d8c362;
  --silver: #b7c3d9;
  --bronze: #d49569;
  --shadow: 0 24px 70px rgba(0, 0, 0, 0.28);
}

* {
  box-sizing: border-box;
}

html {
  color-scheme: dark;
}

body {
  margin: 0;
  min-height: 100vh;
  color: var(--text);
  font-family: "Trebuchet MS", Verdana, sans-serif;
  background:
    radial-gradient(circle at top left, rgba(103, 183, 255, 0.15), transparent 22%),
    radial-gradient(circle at top right, rgba(63, 149, 255, 0.1), transparent 20%),
    linear-gradient(180deg, var(--page-bg) 0%, var(--page-bg-soft) 100%);
}

.page-shell {
  width: min(1120px, calc(100vw - 28px));
  margin: 0 auto;
  padding: 22px 0 40px;
}

.board-shell,
.profile-shell {
  background: linear-gradient(180deg, rgba(20, 38, 63, 0.96), rgba(13, 25, 43, 0.98));
  border: 1px solid var(--panel-border);
  border-radius: 14px;
  box-shadow: var(--shadow);
  overflow: hidden;
}

.selector-bar {
  display: flex;
  justify-content: flex-start;
  padding: 16px;
  background: linear-gradient(180deg, rgba(30, 53, 87, 0.96), rgba(22, 41, 68, 0.96));
  border-bottom: 1px solid rgba(151, 197, 255, 0.08);
}

.search-shell {
  position: relative;
  display: block;
  width: min(30%, 340px);
  min-width: 260px;
}

.search-shell input {
  width: 100%;
  min-height: 42px;
  padding: 0 12px;
  border: 1px solid rgba(151, 197, 255, 0.14);
  border-radius: 10px;
  background: linear-gradient(180deg, rgba(255, 255, 255, 0.08), rgba(255, 255, 255, 0.04));
  color: var(--text);
  font: inherit;
  font-weight: 700;
  appearance: none;
}

.search-shell input::placeholder {
  color: #9ab5d8;
}

.table-panel {
  background: rgba(13, 25, 43, 0.86);
}

.table-wrap {
  overflow-x: auto;
}

table {
  width: 100%;
  border-collapse: collapse;
  min-width: 720px;
}

thead th {
  padding: 13px 16px;
  text-align: left;
  color: var(--muted);
  font-size: 0.78rem;
  text-transform: uppercase;
  letter-spacing: 0.06em;
  background: rgba(255, 255, 255, 0.04);
  border-bottom: 1px solid rgba(151, 197, 255, 0.08);
}

tbody td {
  padding: 14px 16px;
  border-bottom: 1px solid rgba(151, 197, 255, 0.06);
}

tbody tr:nth-child(odd) {
  background: var(--row-dark);
}

tbody tr:nth-child(even) {
  background: var(--row-light);
}

tbody tr:hover {
  background: #20375a;
}

.rank-column {
  width: 96px;
}

.rank-badge {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-width: 36px;
  height: 32px;
  padding: 0 10px;
  border-radius: 7px;
  background: rgba(255, 255, 255, 0.08);
  color: #ffffff;
  font-weight: 700;
}

.rank-gold {
  background: linear-gradient(180deg, var(--gold) 0%, #c0a94b 100%);
  color: #2a2205;
}

.rank-silver {
  background: linear-gradient(180deg, var(--silver) 0%, #96a7c3 100%);
  color: #111a28;
}

.rank-bronze {
  background: linear-gradient(180deg, var(--bronze) 0%, #bb7545 100%);
  color: #241005;
}

.player-link,
.back-link {
  color: #dff0ff;
  text-decoration: none;
  font-weight: 700;
}

.player-link:hover,
.back-link:hover {
  color: #ffffff;
  text-decoration: underline;
}

.games-value,
.wr-value {
  font-size: 1.02rem;
  font-weight: 700;
}

.wr-value {
  color: inherit;
}

.empty-state {
  padding: 18px;
}

.empty-state p {
  margin: 0;
  color: #d8e5f8;
}

.board-page {
  color: #f2f7ff;
  font-family: "Rajdhani", "Trebuchet MS", Verdana, sans-serif;
  background:
    linear-gradient(180deg, rgba(9, 14, 22, 0.7), rgba(9, 14, 22, 0.86)),
    radial-gradient(circle at top center, rgba(49, 92, 176, 0.24), transparent 34%),
    linear-gradient(180deg, #0b1018 0%, #101723 48%, #0a0f16 100%);
}

.board-page .page-shell {
  width: min(1180px, calc(100vw - 28px));
  padding: 22px 0 48px;
}

.board-page .board-shell {
  background: none;
  border: 0;
  box-shadow: none;
  overflow: visible;
}

.board-page .board-header,
.board-page .selector-bar,
.board-page .table-panel {
  border: 1px solid rgba(112, 142, 194, 0.24);
  border-radius: 8px;
  background: linear-gradient(180deg, rgba(28, 37, 54, 0.98), rgba(20, 28, 42, 0.98));
  box-shadow: 0 18px 36px rgba(0, 0, 0, 0.22);
}

.board-page .board-header {
  position: relative;
  overflow: hidden;
  padding: 18px 20px;
}

.board-page .board-header::after {
  content: "";
  position: absolute;
  inset: 0;
  background:
    linear-gradient(120deg, transparent 0%, rgba(91, 136, 255, 0.08) 48%, transparent 100%),
    repeating-linear-gradient(90deg, transparent 0 44px, rgba(255, 255, 255, 0.02) 44px 45px);
  pointer-events: none;
}

.board-page .board-header-copy {
  position: relative;
  z-index: 1;
  display: grid;
  gap: 4px;
}

.board-page .board-home-link,
.board-page .board-kicker {
  margin: 0;
  color: #8fa1c1;
  font-size: 0.74rem;
  font-weight: 700;
  letter-spacing: 0.14em;
  text-transform: uppercase;
}

.board-page .board-home-link {
  text-decoration: none;
}

.board-page .board-home-link:hover {
  color: #ffffff;
}

.board-page .board-header h1 {
  margin: 0;
  color: #ffffff;
  font-family: "Barlow Condensed", "Trebuchet MS", sans-serif;
  font-size: clamp(2.6rem, 4vw, 4rem);
  line-height: 0.95;
  letter-spacing: 0.01em;
  text-transform: uppercase;
}

.board-page .selector-bar {
  margin-top: 14px;
  padding: 12px 16px;
  background: linear-gradient(180deg, rgba(22, 30, 45, 0.98), rgba(18, 25, 38, 0.98));
}

.board-page .board-controls {
  display: flex;
  gap: 12px;
  align-items: center;
}

.board-page .search-shell {
  width: min(30%, 340px);
  min-width: 260px;
}

.board-page .board-filter-shell {
  display: block;
  width: 120px;
}

.board-page .search-shell input {
  min-height: 40px;
  border: 1px solid rgba(112, 142, 194, 0.2);
  border-radius: 6px;
  background: #1a2232;
  color: #f2f7ff;
  font-family: inherit;
  font-weight: 600;
}

.board-page .search-shell input::placeholder {
  color: #8fa1c1;
}

.board-page .board-filter-shell select {
  width: 100%;
  min-height: 40px;
  padding: 0 38px 0 12px;
  border: 1px solid rgba(112, 142, 194, 0.2);
  border-radius: 6px;
  background: #1a2232;
  color: #f2f7ff;
  font: inherit;
  font-weight: 600;
  appearance: none;
  background-image:
    url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='14' height='14' viewBox='0 0 14 14' fill='none'%3E%3Cpath d='M3.5 5.5L7 9L10.5 5.5' stroke='%23dff4ff' stroke-width='1.5' stroke-linecap='round' stroke-linejoin='round'/%3E%3C/svg%3E");
  background-repeat: no-repeat;
  background-position: calc(100% - 12px) 50%;
}

.board-page .table-panel {
  margin-top: 14px;
  overflow: hidden;
}

.board-page .table-wrap {
  overflow-x: auto;
}

.board-page table {
  min-width: 760px;
}

.board-page thead th {
  padding: 13px 16px;
  color: #8fa1c1;
  font-family: "Rajdhani", "Trebuchet MS", sans-serif;
  font-size: 0.8rem;
  font-weight: 700;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  background: rgba(255, 255, 255, 0.02);
  border-bottom: 1px solid rgba(112, 142, 194, 0.16);
}

.board-page tbody td {
  padding: 16px;
  border-bottom: 1px solid rgba(112, 142, 194, 0.14);
  background: linear-gradient(180deg, rgba(35, 46, 68, 0.98), rgba(30, 39, 58, 0.98));
}

.board-page tbody tr:hover td {
  background: linear-gradient(180deg, rgba(41, 54, 81, 0.98), rgba(35, 46, 68, 0.98));
}

.board-page .rank-column {
  width: 100px;
}

.board-page .rank-badge {
  min-width: 44px;
  height: 36px;
  border-radius: 6px;
  background: rgba(255, 255, 255, 0.06);
  color: #ffffff;
  font-family: "Barlow Condensed", "Trebuchet MS", sans-serif;
  font-size: 1.2rem;
  font-weight: 700;
  letter-spacing: 0.03em;
}

.board-page .rank-gold {
  background: linear-gradient(180deg, #d8c362 0%, #c0a94b 100%);
  color: #2a2205;
}

.board-page .rank-silver {
  background: linear-gradient(180deg, #b7c3d9 0%, #96a7c3 100%);
  color: #111a28;
}

.board-page .rank-bronze {
  background: linear-gradient(180deg, #d49569 0%, #bb7545 100%);
  color: #241005;
}

.board-page .player-link {
  color: #ffffff;
  font-family: "Barlow Condensed", "Trebuchet MS", sans-serif;
  font-size: 1.6rem;
  font-weight: 700;
  letter-spacing: 0.01em;
  text-decoration: none;
  text-transform: uppercase;
}

.board-page .player-link:hover {
  color: #dfe9ff;
  text-decoration: none;
}

.board-page .games-value,
.board-page .wr-value {
  color: #f2f7ff;
  font-family: "Barlow Condensed", "Trebuchet MS", sans-serif;
  font-size: 1.55rem;
  line-height: 0.92;
  letter-spacing: 0.01em;
}

.board-page .empty-state {
  padding: 20px 16px;
}

.board-page .empty-state p {
  color: #8fa1c1;
}

.board-page .pagination {
  display: flex;
  justify-content: center;
  gap: 8px;
  flex-wrap: wrap;
  padding: 0 16px 18px;
}

.board-page .pagination-button {
  min-width: 38px;
  height: 36px;
  border: 1px solid rgba(112, 142, 194, 0.18);
  border-radius: 6px;
  background: #1a2232;
  color: #d4def0;
  font: inherit;
  font-weight: 700;
  cursor: pointer;
}

.board-page .pagination-button:hover {
  color: #ffffff;
  border-color: rgba(112, 142, 194, 0.3);
}

.board-page .pagination-button-active {
  border-color: rgba(112, 142, 194, 0.34);
  background: linear-gradient(180deg, rgba(60, 88, 151, 0.95), rgba(33, 49, 89, 0.98));
  color: #ffffff;
}

.profile-page {
  color: #f2f7ff;
  font-family: "Rajdhani", "Trebuchet MS", Verdana, sans-serif;
  background:
    linear-gradient(180deg, rgba(9, 14, 22, 0.7), rgba(9, 14, 22, 0.86)),
    radial-gradient(circle at top center, rgba(49, 92, 176, 0.24), transparent 34%),
    linear-gradient(180deg, #0b1018 0%, #101723 48%, #0a0f16 100%);
}

.profile-page .page-shell {
  width: min(1180px, calc(100vw - 28px));
  padding: 22px 0 48px;
}

.profile-page .profile-shell {
  padding: 0;
  background: none;
  border: 0;
  box-shadow: none;
  overflow: visible;
}

.profile-page .profile-header,
.profile-page .overview-switcher,
.profile-page .summary-strip,
.profile-page .history-panel {
  border: 1px solid rgba(112, 142, 194, 0.24);
  border-radius: 8px;
  background: linear-gradient(180deg, rgba(28, 37, 54, 0.98), rgba(20, 28, 42, 0.98));
  box-shadow: 0 18px 36px rgba(0, 0, 0, 0.22);
}

.profile-page .profile-header {
  position: relative;
  display: grid;
  gap: 4px;
  padding: 18px 20px;
  overflow: hidden;
}

.profile-page .profile-header::after {
  content: "";
  position: absolute;
  inset: 0;
  background:
    linear-gradient(120deg, transparent 0%, rgba(91, 136, 255, 0.08) 48%, transparent 100%),
    repeating-linear-gradient(90deg, transparent 0 44px, rgba(255, 255, 255, 0.02) 44px 45px);
  pointer-events: none;
}

.profile-page .profile-header > * {
  position: relative;
  z-index: 1;
}

.profile-page .profile-header h1,
.profile-page .history-panel h2 {
  margin: 0;
}

.profile-page .profile-header h1 {
  font-family: "Barlow Condensed", "Trebuchet MS", sans-serif;
  font-size: clamp(2.5rem, 4vw, 4rem);
  line-height: 0.95;
  letter-spacing: 0.01em;
  text-transform: uppercase;
}

.profile-page .back-link {
  color: #b8c9e6;
  font-size: 0.95rem;
  font-weight: 600;
  letter-spacing: 0.04em;
  text-transform: uppercase;
}

.profile-page .back-link:hover {
  color: #ffffff;
}

.profile-page .profile-kicker,
.profile-page .profile-age,
.profile-page .summary-label,
.profile-page .summary-meta,
.profile-page .history-meta,
.profile-page .history-filter span,
.profile-page .history-room-caption,
.profile-page .history-room-kicker,
.profile-page .history-performance-label,
.profile-page .summary-list-label,
.profile-page .summary-empty-copy {
  margin: 0;
  color: #8fa1c1;
}

.profile-page .profile-kicker,
.profile-page .summary-label,
.profile-page .history-filter span,
.profile-page .history-room-kicker {
  font-size: 0.74rem;
  font-weight: 700;
  letter-spacing: 0.14em;
  text-transform: uppercase;
}

.profile-page .profile-age {
  font-size: 1rem;
}

.profile-page .profile-overview {
  margin-top: 14px;
}

.profile-page .overview-switcher {
  display: grid;
  grid-template-columns: 46px minmax(0, 1fr) 46px;
  gap: 10px;
  align-items: center;
  margin-top: 14px;
  padding: 10px 12px;
  background: linear-gradient(180deg, rgba(22, 30, 45, 0.98), rgba(18, 25, 38, 0.98));
}

.profile-page .overview-tabs {
  display: flex;
  justify-content: center;
  gap: 10px;
  flex-wrap: wrap;
}

.profile-page .overview-tab,
.profile-page .overview-arrow {
  border: 1px solid rgba(112, 142, 194, 0.18);
  background: #1a2232;
  color: #d4def0;
  font: inherit;
  font-weight: 700;
}

.profile-page .overview-tab {
  min-width: 86px;
  min-height: 38px;
  padding: 0 16px;
  border-radius: 999px;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  cursor: pointer;
}

.profile-page .overview-tab-active {
  border-color: rgba(112, 142, 194, 0.34);
  background: linear-gradient(180deg, rgba(60, 88, 151, 0.95), rgba(33, 49, 89, 0.98));
  color: #ffffff;
}

.profile-page .overview-tab-empty {
  color: #7f91b2;
}

.profile-page .overview-arrow {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 46px;
  height: 38px;
  border-radius: 6px;
  font-family: "Barlow Condensed", "Trebuchet MS", sans-serif;
  font-size: 1.4rem;
  line-height: 1;
  cursor: pointer;
}

.profile-page .overview-arrow:hover,
.profile-page .overview-tab:hover {
  color: #ffffff;
  border-color: rgba(112, 142, 194, 0.28);
}

.profile-page .summary-strip {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  overflow: hidden;
}

.profile-page .summary-segment {
  min-height: 198px;
  padding: 16px 18px;
  border-right: 1px solid rgba(112, 142, 194, 0.16);
}

.profile-page .summary-segment:last-child {
  border-right: 0;
}

.profile-page .summary-segment-highlight {
  background:
    linear-gradient(180deg, rgba(31, 44, 68, 0.86), rgba(21, 31, 48, 0.94)),
    radial-gradient(circle at top left, rgba(64, 122, 253, 0.18), transparent 42%);
}

.profile-page .summary-value {
  margin: 8px 0 10px;
  color: #ffffff;
  font-family: "Barlow Condensed", "Trebuchet MS", sans-serif;
  font-size: 3.2rem;
  font-weight: 700;
  line-height: 0.92;
  letter-spacing: 0.01em;
}

.profile-page .summary-value-win {
  color: #62e296;
}

.profile-page .summary-meta {
  font-size: 0.98rem;
  line-height: 1.15;
}

.profile-page .summary-meta-strong {
  color: #edf5ff;
  font-weight: 700;
}

.profile-page .summary-recordline {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 10px;
  margin: 14px 0 16px;
}

.profile-page .summary-segment-record {
  display: flex;
  flex-direction: column;
}

.profile-page .summary-recordline strong {
  display: block;
  color: #ffffff;
  font-family: "Barlow Condensed", "Trebuchet MS", sans-serif;
  font-size: 2.6rem;
  line-height: 0.92;
}

.profile-page .summary-recordline span {
  display: block;
  margin-top: 4px;
  color: #8fa1c1;
  font-size: 0.9rem;
  font-weight: 700;
  letter-spacing: 0.12em;
  text-transform: uppercase;
}

.profile-page .summary-record-footer {
  margin-top: auto;
  display: grid;
  gap: 4px;
}

.profile-page .summary-stack {
  display: grid;
  gap: 12px;
  margin-top: 12px;
}

.profile-page .summary-segment-head {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
}

.profile-page .summary-room-pill {
  display: inline-flex;
  align-items: center;
  min-height: 28px;
  padding: 0 10px;
  border-radius: 999px;
  background: rgba(255, 255, 255, 0.06);
  color: #f2f7ff;
  font-size: 0.8rem;
  font-weight: 700;
  letter-spacing: 0.08em;
  text-transform: uppercase;
}

.profile-page .summary-list-row {
  display: grid;
  gap: 6px;
}

.profile-page .summary-list-row-head {
  display: flex;
  justify-content: space-between;
  gap: 12px;
  align-items: center;
}

.profile-page .summary-list-value {
  color: #f2f7ff;
  font-weight: 700;
}

.profile-page .summary-meter {
  height: 6px;
  overflow: hidden;
  border-radius: 999px;
  background: rgba(255, 255, 255, 0.07);
}

.profile-page .summary-meter-wide {
  margin-top: 14px;
}

.profile-page .summary-meter-winrate {
  background: linear-gradient(90deg, rgba(255, 111, 138, 0.58), rgba(243, 81, 103, 0.58));
}

.profile-page .summary-meter-fill {
  display: block;
  height: 100%;
  border-radius: inherit;
  background: linear-gradient(90deg, #5e87ff, #73b0ff);
}

.profile-page .summary-meter-fill-win,
.profile-page .summary-meter-fill-goals {
  background: linear-gradient(90deg, #4de384, #7dffbd);
}

.profile-page .summary-meter-fill-assists {
  background: linear-gradient(90deg, #4da6ff, #8ec8ff);
}

.profile-page .summary-meter-fill-clean-sheets {
  background: linear-gradient(90deg, #9d84ff, #c0acff);
}

.profile-page .summary-meter-fill-1v1 {
  background: linear-gradient(90deg, #ffb25d, #ffd18d);
}

.profile-page .summary-meter-fill-3v3 {
  background: linear-gradient(90deg, #34dfbd, #7af0d7);
}

.profile-page .summary-meter-fill-4v4,
.profile-page .summary-meter-fill-overall {
  background: linear-gradient(90deg, #6893ff, #8db5ff);
}

.profile-page .summary-segment-stats {
  display: grid;
  grid-template-rows: auto minmax(0, 1fr);
  min-height: 198px;
}

.profile-page .summary-room-empty {
  min-height: 100%;
}

.profile-page .summary-scroll {
  margin-top: 12px;
  max-height: 128px;
  padding-right: 8px;
  overflow-y: auto;
}

.profile-page .summary-scroll::-webkit-scrollbar {
  width: 8px;
}

.profile-page .summary-scroll::-webkit-scrollbar-track {
  background: rgba(255, 255, 255, 0.04);
  border-radius: 999px;
}

.profile-page .summary-scroll::-webkit-scrollbar-thumb {
  background: rgba(112, 142, 194, 0.38);
  border-radius: 999px;
}

.profile-page .summary-scroll-row {
  display: flex;
  justify-content: space-between;
  gap: 12px;
  align-items: center;
  padding: 7px 0;
  border-bottom: 1px solid rgba(112, 142, 194, 0.12);
}

.profile-page .summary-scroll-row:last-child {
  border-bottom: 0;
}

.profile-page .summary-scroll-label,
.profile-page .summary-scroll-value {
  font-size: 0.95rem;
}

.profile-page .summary-scroll-label {
  color: #8fa1c1;
}

.profile-page .summary-scroll-value {
  color: #ffffff;
  font-weight: 700;
}

.profile-page .history-panel {
  margin-top: 14px;
  overflow: hidden;
}

.profile-page .history-head {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 16px;
  padding: 12px 16px;
  border-bottom: 1px solid rgba(112, 142, 194, 0.16);
  background: rgba(255, 255, 255, 0.02);
}

.profile-page .history-panel h2 {
  font-family: "Barlow Condensed", "Trebuchet MS", sans-serif;
  font-size: 1.9rem;
  letter-spacing: 0.01em;
  text-transform: uppercase;
}

.profile-page .history-filter {
  display: grid;
  gap: 4px;
  min-width: 190px;
}

.profile-page .history-filter select {
  min-height: 38px;
  padding: 0 40px 0 12px;
  border: 1px solid rgba(112, 142, 194, 0.2);
  border-radius: 6px;
  background: #1a2232;
  color: #f2f7ff;
  font: inherit;
  font-weight: 600;
  appearance: none;
  background-image:
    url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='14' height='14' viewBox='0 0 14 14' fill='none'%3E%3Cpath d='M3.5 5.5L7 9L10.5 5.5' stroke='%23dff4ff' stroke-width='1.5' stroke-linecap='round' stroke-linejoin='round'/%3E%3C/svg%3E");
  background-repeat: no-repeat;
  background-position: calc(100% - 12px) 50%;
}

.profile-page .history-list {
  display: grid;
  gap: 8px;
  padding: 12px;
}

.profile-page .history-item {
  display: grid;
  grid-template-columns: 6px minmax(0, 1.4fr) minmax(0, 0.8fr) 180px;
  align-items: stretch;
  gap: 0;
  overflow: hidden;
  border: 1px solid rgba(112, 142, 194, 0.16);
  border-radius: 8px;
  background: linear-gradient(180deg, rgba(35, 46, 68, 0.98), rgba(30, 39, 58, 0.98));
}

.profile-page .history-item-accent {
  background: #1fe893;
}

.profile-page .history-item-loss .history-item-accent {
  background: #ef506e;
}

.profile-page .history-item-draw .history-item-accent {
  background: #5b8cff;
}

.profile-page .history-copy,
.profile-page .history-performance,
.profile-page .history-room {
  min-height: 96px;
}

.profile-page .history-copy,
.profile-page .history-performance {
  display: flex;
  flex-direction: column;
  justify-content: center;
  padding: 14px 18px;
}

.profile-page .history-performance {
  border-left: 1px solid rgba(112, 142, 194, 0.14);
}

.profile-page .history-title,
.profile-page .history-performance-value,
.profile-page .history-room-value {
  margin: 0;
  color: #ffffff;
}

.profile-page .history-title,
.profile-page .history-performance-value,
.profile-page .history-room-value {
  font-family: "Barlow Condensed", "Trebuchet MS", sans-serif;
  font-weight: 700;
}

.profile-page .history-title {
  font-size: 1.9rem;
  line-height: 0.92;
  text-transform: uppercase;
}

.profile-page .history-meta {
  margin-top: 4px;
  font-size: 0.98rem;
}

.profile-page .history-subline {
  display: flex;
  gap: 8px;
  align-items: center;
  flex-wrap: wrap;
  margin-top: 8px;
  padding-top: 8px;
  border-top: 1px solid rgba(112, 142, 194, 0.14);
}

.profile-page .history-result,
.profile-page .history-length {
  font-weight: 700;
  letter-spacing: 0.08em;
  text-transform: uppercase;
}

.profile-page .history-result {
  color: #1fe893;
}

.profile-page .history-result-loss {
  color: #ff7b92;
}

.profile-page .history-result-draw {
  color: #8fb4ff;
}

.profile-page .history-length {
  color: #c4d1e8;
}

.profile-page .history-performance {
  align-items: flex-start;
  gap: 4px;
}

.profile-page .history-performance-value {
  font-size: 2.4rem;
  line-height: 0.92;
}

.profile-page .history-performance-label {
  font-size: 0.82rem;
  font-weight: 700;
  letter-spacing: 0.16em;
  text-transform: uppercase;
}

.profile-page .history-room {
  display: flex;
  align-items: stretch;
  border-left: 1px solid rgba(112, 142, 194, 0.14);
  padding: 10px;
}

.profile-page .history-room-card {
  position: relative;
  width: 100%;
  min-height: 76px;
  overflow: hidden;
  border: 1px solid rgba(255, 255, 255, 0.08);
  border-radius: 6px;
  background:
    linear-gradient(135deg, rgba(73, 114, 214, 0.92), rgba(34, 57, 109, 0.96)),
    repeating-linear-gradient(135deg, rgba(255, 255, 255, 0.08) 0 10px, transparent 10px 20px);
  display: flex;
  flex-direction: column;
  justify-content: space-between;
  padding: 10px 12px;
}

.profile-page .history-room-card::after {
  content: "";
  position: absolute;
  inset: auto -10% -20% auto;
  width: 110px;
  height: 110px;
  border-radius: 50%;
  background: radial-gradient(circle, rgba(255, 255, 255, 0.16), transparent 68%);
}

.profile-page .history-room-card-1v1 {
  background:
    linear-gradient(135deg, rgba(216, 132, 42, 0.92), rgba(106, 58, 17, 0.96)),
    repeating-linear-gradient(135deg, rgba(255, 255, 255, 0.08) 0 10px, transparent 10px 20px);
}

.profile-page .history-room-card-3v3 {
  background:
    linear-gradient(135deg, rgba(25, 154, 130, 0.92), rgba(14, 74, 66, 0.96)),
    repeating-linear-gradient(135deg, rgba(255, 255, 255, 0.08) 0 10px, transparent 10px 20px);
}

.profile-page .history-room-card-4v4 {
  background:
    linear-gradient(135deg, rgba(69, 118, 228, 0.92), rgba(31, 54, 109, 0.96)),
    repeating-linear-gradient(135deg, rgba(255, 255, 255, 0.08) 0 10px, transparent 10px 20px);
}

.profile-page .history-room-kicker,
.profile-page .history-room-caption,
.profile-page .history-room-value {
  position: relative;
  z-index: 1;
}

.profile-page .history-room-kicker,
.profile-page .history-room-caption {
  color: rgba(255, 255, 255, 0.82);
}

.profile-page .history-room-value {
  font-size: 2.3rem;
  line-height: 0.92;
  text-transform: uppercase;
}

.hidden {
  display: none;
}

@media (max-width: 980px) {
  .profile-page .overview-switcher {
    grid-template-columns: 40px minmax(0, 1fr) 40px;
  }

  .profile-page .summary-strip {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }

  .profile-page .summary-segment:nth-child(2) {
    border-right: 0;
  }

  .profile-page .summary-segment:nth-child(n + 3) {
    border-top: 1px solid rgba(112, 142, 194, 0.16);
  }

  .profile-page .history-item {
    grid-template-columns: 6px minmax(0, 1fr) minmax(0, 0.75fr);
  }

  .profile-page .history-room {
    grid-column: 2 / -1;
    border-left: 0;
    border-top: 1px solid rgba(112, 142, 194, 0.14);
  }
}

@media (max-width: 700px) {
  .page-shell {
    width: min(100vw - 14px, 1120px);
    padding-top: 10px;
  }

  .search-shell {
    width: 100%;
    min-width: 100%;
  }

  .board-page .page-shell {
    width: min(100vw - 14px, 1180px);
  }

  .board-page .board-header {
    padding: 16px;
  }

  .board-page .search-shell {
    width: 100%;
    min-width: 100%;
  }

  .board-page .board-controls {
    flex-direction: column;
    align-items: stretch;
  }

  .board-page .board-filter-shell {
    width: 100%;
  }

  .profile-page .page-shell {
    width: min(100vw - 14px, 1180px);
  }

  .profile-page .profile-header {
    padding: 16px;
  }

  .profile-page .overview-switcher {
    grid-template-columns: 1fr;
  }

  .profile-page .overview-arrow {
    display: none;
  }

  .profile-page .summary-strip {
    grid-template-columns: 1fr;
  }

  .profile-page .summary-segment {
    min-height: auto;
    border-right: 0;
    border-top: 1px solid rgba(112, 142, 194, 0.16);
  }

  .profile-page .summary-segment:first-child {
    border-top: 0;
  }

  .profile-page .history-head {
    align-items: stretch;
    flex-direction: column;
  }

  .profile-page .history-filter {
    min-width: 100%;
  }

  .profile-page .history-item {
    grid-template-columns: 6px 1fr;
  }

  .profile-page .history-performance,
  .profile-page .history-room {
    border-left: 0;
    border-top: 1px solid rgba(112, 142, 194, 0.14);
  }
}
