.highscores-page {
	--highscores-gold: #d8aa57;
	--highscores-gold-bright: #f3d28d;
	--highscores-red: #c84741;
	--highscores-panel: rgba(18, 11, 9, 0.78);
	--highscores-border: rgba(216, 170, 87, 0.2);
	max-width: 100%;
	padding: 4px 0 20px;
}

.highscores-hero {
	position: relative;
	display: flex;
	align-items: center;
	justify-content: space-between;
	min-height: 116px;
	margin-bottom: 14px;
	padding: 20px 24px;
	overflow: hidden;
	background:
		radial-gradient(circle at 85% 20%, rgba(216, 170, 87, 0.17), transparent 34%),
		linear-gradient(135deg, rgba(72, 31, 24, 0.88), rgba(20, 12, 10, 0.96) 68%);
	border: 1px solid var(--highscores-border);
	border-radius: 10px;
	box-shadow: 0 12px 30px rgba(0, 0, 0, 0.28), inset 0 1px rgba(255, 255, 255, 0.04);
}

.highscores-hero::after {
	content: "";
	position: absolute;
	right: -38px;
	bottom: -74px;
	width: 190px;
	height: 190px;
	border: 1px solid rgba(216, 170, 87, 0.13);
	border-radius: 50%;
}

.highscores-eyebrow {
	display: block;
	margin-bottom: 3px;
	color: var(--highscores-gold-bright);
	font-size: 10px;
	font-weight: 700;
	letter-spacing: 1.8px;
	text-transform: uppercase;
}

.highscores-hero h1 {
	margin: 0;
	color: #f1e9df;
	font-family: "Cinzel", Georgia, serif;
	font-size: 31px;
	font-weight: 650;
	letter-spacing: 0.5px;
	line-height: 1.15;
	text-shadow: 0 2px 10px rgba(0, 0, 0, 0.65);
}

.highscores-hero p {
	max-width: 430px;
	margin: 7px 0 0;
	color: #b9aaa0;
	font-size: 12px;
	line-height: 1.5;
}

.highscores-trophy {
	position: relative;
	z-index: 1;
	display: grid;
	width: 64px;
	height: 64px;
	margin-right: 7px;
	place-items: center;
	background: linear-gradient(145deg, rgba(243, 210, 141, 0.2), rgba(216, 170, 87, 0.04));
	border: 1px solid rgba(243, 210, 141, 0.32);
	border-radius: 50%;
	box-shadow: 0 0 28px rgba(216, 170, 87, 0.12), inset 0 0 14px rgba(216, 170, 87, 0.08);
}

.highscores-trophy::before,
.highscores-trophy::after {
	content: "";
	position: absolute;
	top: 21px;
	width: 15px;
	height: 19px;
	border: 2px solid rgba(216, 170, 87, 0.65);
}

.highscores-trophy::before {
	left: -7px;
	border-right: 0;
	border-radius: 12px 0 0 12px;
}

.highscores-trophy::after {
	right: -7px;
	border-left: 0;
	border-radius: 0 12px 12px 0;
}

.highscores-trophy span {
	color: var(--highscores-gold-bright);
	font-family: "Cinzel", Georgia, serif;
	font-size: 25px;
	font-weight: 700;
	text-shadow: 0 0 12px rgba(243, 210, 141, 0.36);
}

.highscores-filters {
	display: grid;
	grid-template-columns: 1fr 1.2fr 0.76fr auto;
	align-items: end;
	gap: 8px;
	margin-bottom: 12px;
	padding: 13px;
	background: var(--highscores-panel);
	border: 1px solid rgba(255, 255, 255, 0.08);
	border-radius: 8px;
	box-shadow: inset 0 1px rgba(255, 255, 255, 0.025);
}

.highscores-filter label {
	display: block;
	margin: 0 0 5px 2px;
	color: #9e8e84;
	font-size: 9px;
	font-weight: 700;
	letter-spacing: 0.9px;
	text-transform: uppercase;
}

.highscores-filter select {
	width: 100%;
	height: 34px;
	padding: 6px 8px;
	background: rgba(5, 3, 3, 0.58);
	border-color: rgba(216, 170, 87, 0.16);
	color: #d4c7bd;
}

.content .highscores-submit {
	height: 34px;
	padding: 6px 13px;
	white-space: nowrap;
	background: linear-gradient(135deg, #a43a35, #792a27);
	border-color: rgba(230, 112, 103, 0.5);
	box-shadow: 0 4px 12px rgba(0, 0, 0, 0.2);
	font-size: 10px;
}

.content .highscores-submit:hover {
	background: linear-gradient(135deg, #c64942, #91312d);
}

.highscores-summary {
	display: grid;
	grid-template-columns: repeat(4, 1fr);
	margin-bottom: 10px;
	background: linear-gradient(180deg, rgba(255, 255, 255, 0.045), rgba(255, 255, 255, 0.018));
	border: 1px solid rgba(255, 255, 255, 0.07);
	border-radius: 7px;
}

.highscores-summary__item {
	position: relative;
	padding: 10px 13px;
	min-width: 0;
}

.highscores-summary__item + .highscores-summary__item::before {
	content: "";
	position: absolute;
	top: 9px;
	bottom: 9px;
	left: 0;
	width: 1px;
	background: rgba(255, 255, 255, 0.07);
}

.highscores-summary__item span,
.highscores-summary__item strong {
	display: block;
	overflow: hidden;
	text-overflow: ellipsis;
	white-space: nowrap;
}

.highscores-summary__item span {
	margin-bottom: 2px;
	color: #7f746e;
	font-size: 8px;
	font-weight: 700;
	letter-spacing: 0.9px;
	text-transform: uppercase;
}

.highscores-summary__item strong {
	color: #cfc2b8;
	font-size: 11px;
	font-weight: 600;
}

.highscores-summary__item--count strong {
	color: var(--highscores-gold-bright);
}

.highscores-own-legend {
	display: flex;
	align-items: center;
	gap: 7px;
	margin: 3px 2px 9px;
	color: #c7ae7d;
	font-size: 10px;
}

.highscores-own-legend__marker {
	width: 9px;
	height: 9px;
	background: rgba(216, 170, 87, 0.65);
	border: 1px solid var(--highscores-gold-bright);
	border-radius: 50%;
	box-shadow: 0 0 8px rgba(216, 170, 87, 0.45);
}

.highscores-table-wrap {
	overflow-x: auto;
	background: rgba(8, 5, 4, 0.48);
	border: 1px solid rgba(255, 255, 255, 0.07);
	border-radius: 8px;
	box-shadow: 0 10px 25px rgba(0, 0, 0, 0.2);
	-webkit-overflow-scrolling: touch;
}

.highscores-table {
	width: 100%;
	min-width: 530px;
	margin: 0;
	border-collapse: separate;
	border-spacing: 0;
	table-layout: auto;
}

.highscores-table thead th {
	padding: 10px 11px;
	background: rgba(63, 31, 25, 0.74);
	border: 0;
	border-bottom: 1px solid rgba(216, 170, 87, 0.18);
	color: #bfa78d;
	font-size: 9px;
	font-weight: 700;
	letter-spacing: 1px;
	text-align: left;
	text-transform: uppercase;
}

.highscores-table tbody td {
	padding: 10px 11px;
	background: rgba(255, 255, 255, 0.018);
	border: 0;
	border-bottom: 1px solid rgba(255, 255, 255, 0.055);
	color: #aaa09a;
	font-size: 11px;
	vertical-align: middle;
	transition: background 0.16s ease, color 0.16s ease;
}

.highscores-table tbody tr:last-child td {
	border-bottom: 0;
}

.highscores-table tbody tr:nth-child(even) td {
	background: rgba(255, 255, 255, 0.032);
}

.highscores-table tbody tr:hover td {
	background: rgba(200, 71, 65, 0.095);
}

.highscores-rank-column,
.highscores-rank-cell {
	width: 48px;
	text-align: center !important;
}

.highscores-rank {
	display: inline-grid;
	width: 26px;
	height: 26px;
	place-items: center;
	color: #887c75;
	font-size: 10px;
	font-weight: 700;
	border: 1px solid rgba(255, 255, 255, 0.08);
	border-radius: 50%;
}

.highscores-rank--1 {
	background: linear-gradient(145deg, #f2d58e, #9b6a23);
	border-color: #f3d79b;
	color: #291b0b;
	box-shadow: 0 0 13px rgba(216, 170, 87, 0.28);
}

.highscores-rank--2 {
	background: linear-gradient(145deg, #d5d5d2, #777773);
	border-color: #dededb;
	color: #262626;
}

.highscores-rank--3 {
	background: linear-gradient(145deg, #c68b58, #704024);
	border-color: #d69a67;
	color: #24140b;
}

.highscores-character-cell {
	min-width: 155px;
}

.highscores-character-cell a {
	color: #d7c7ba;
	font-weight: 650;
	text-decoration: none;
}

.highscores-character-cell a:hover {
	color: #fff0de;
	text-decoration: underline;
	text-decoration-color: rgba(216, 170, 87, 0.5);
	text-underline-offset: 3px;
}

.highscores-number-column,
.highscores-number-cell {
	text-align: right !important;
	font-variant-numeric: tabular-nums;
}

.highscores-number-cell {
	color: #c4b8ae !important;
	font-weight: 600;
}

.highscores-number-cell--accent {
	color: var(--highscores-gold-bright) !important;
}

.highscores-row--own td,
.highscores-row--own:nth-child(even) td {
	background: linear-gradient(90deg, rgba(216, 170, 87, 0.17), rgba(216, 170, 87, 0.07)) !important;
	border-top: 1px solid rgba(243, 210, 141, 0.26) !important;
	border-bottom: 1px solid rgba(243, 210, 141, 0.26) !important;
}

.highscores-row--own td:first-child {
	box-shadow: inset 3px 0 0 var(--highscores-gold);
}

.highscores-row--own .highscores-character-cell a {
	color: #ffe2a4;
	text-shadow: 0 0 10px rgba(216, 170, 87, 0.3);
}

.highscores-you-badge {
	display: inline-block;
	margin-left: 7px;
	padding: 2px 5px;
	background: rgba(216, 170, 87, 0.18);
	border: 1px solid rgba(243, 210, 141, 0.3);
	border-radius: 8px;
	color: #f1d18d;
	font-size: 7px;
	font-weight: 800;
	letter-spacing: 0.65px;
	line-height: 1.2;
	text-transform: uppercase;
	vertical-align: 1px;
}

.highscores-empty {
	padding: 38px 12px !important;
	text-align: center;
}

.highscores-empty strong,
.highscores-empty span {
	display: block;
}

.highscores-empty strong {
	margin-bottom: 4px;
	color: #cbbdb2;
	font-family: "Cinzel", Georgia, serif;
	font-size: 15px;
}

.highscores-empty span {
	color: #80756f;
	font-size: 10px;
}

.highscores-pagination {
	display: grid;
	grid-template-columns: minmax(102px, auto) 1fr minmax(102px, auto);
	align-items: center;
	gap: 10px;
	margin-top: 12px;
	padding: 10px;
	background: var(--highscores-panel);
	border: 1px solid rgba(255, 255, 255, 0.08);
	border-radius: 8px;
	box-shadow: 0 8px 20px rgba(0, 0, 0, 0.18);
}

.highscores-pagination__direction,
.highscores-pagination__page {
	display: inline-flex;
	align-items: center;
	justify-content: center;
	min-height: 34px;
	box-sizing: border-box;
	border: 1px solid rgba(216, 170, 87, 0.2);
	border-radius: 6px;
	color: #cfc2b8;
	font-size: 10px;
	font-weight: 700;
	line-height: 1;
	text-decoration: none;
	transition: background 0.16s ease, border-color 0.16s ease, color 0.16s ease, transform 0.16s ease;
}

.highscores-pagination__direction {
	gap: 6px;
	padding: 0 13px;
	background: rgba(255, 255, 255, 0.035);
	white-space: nowrap;
}

.highscores-pagination__next {
	background: linear-gradient(135deg, #a43a35, #792a27);
	border-color: rgba(230, 112, 103, 0.5);
	color: #fff1e7;
}

.highscores-pagination__direction:not(.is-disabled):hover,
.highscores-pagination__direction:not(.is-disabled):focus-visible,
.highscores-pagination__page:hover,
.highscores-pagination__page:focus-visible {
	background: rgba(216, 170, 87, 0.12);
	border-color: rgba(243, 210, 141, 0.5);
	color: #fff0de;
	outline: none;
	transform: translateY(-1px);
}

.highscores-pagination__next:not(.is-disabled):hover,
.highscores-pagination__next:not(.is-disabled):focus-visible {
	background: linear-gradient(135deg, #c64942, #91312d);
	border-color: rgba(243, 140, 130, 0.7);
}

.highscores-pagination__direction.is-disabled {
	border-color: rgba(255, 255, 255, 0.06);
	color: #645b56;
	cursor: default;
	opacity: 0.6;
}

.highscores-pagination__pages {
	display: flex;
	align-items: center;
	justify-content: center;
	gap: 5px;
	min-width: 0;
}

.highscores-pagination__page {
	width: 34px;
	background: rgba(5, 3, 3, 0.4);
}

.highscores-pagination__page.is-current {
	background: rgba(216, 170, 87, 0.18);
	border-color: rgba(243, 210, 141, 0.48);
	color: var(--highscores-gold-bright);
}

.highscores-pagination__ellipsis {
	color: #70645e;
	font-size: 12px;
}

.highscores-pagination__mobile-label {
	display: none;
}

@media (max-width: 700px) {
	.highscores-filters {
		grid-template-columns: repeat(2, minmax(0, 1fr));
	}

	.highscores-filter--wide {
		grid-column: span 2;
	}

	.content .highscores-submit {
		width: 100%;
	}

	.highscores-pagination {
		grid-template-columns: 1fr 1fr;
	}

	.highscores-pagination__pages {
		grid-column: 1 / -1;
		grid-row: 1;
	}

	.highscores-pagination__previous {
		grid-column: 1;
	}

	.highscores-pagination__next {
		grid-column: 2;
	}
}

@media (max-width: 420px) {
	.highscores-pagination__pages .highscores-pagination__page:not(.is-current),
	.highscores-pagination__ellipsis {
		display: none;
	}

	.highscores-pagination__page.is-current {
		width: auto;
		padding: 0 12px;
	}

	.highscores-pagination__mobile-label {
		display: inline;
	}
}
