/* The account pages look like the game's menus: the same colours, type and measures
   as crates/client/src/ui/style.rs. A dark sheet, one gold thing to do on it. */

@font-face { font-family: "Barlow"; font-weight: 400; src: url("fonts/Barlow-Regular.ttf"); font-display: swap; }
@font-face { font-family: "Barlow"; font-weight: 500; src: url("fonts/Barlow-Medium.ttf"); font-display: swap; }
@font-face { font-family: "Barlow"; font-weight: 600; src: url("fonts/Barlow-SemiBold.ttf"); font-display: swap; }
@font-face { font-family: "Barlow Condensed"; font-weight: 700; src: url("fonts/BarlowCondensed-Bold.ttf"); font-display: swap; }
@font-face { font-family: "Barlow Condensed"; font-weight: 800; src: url("fonts/BarlowCondensed-ExtraBold.ttf"); font-display: swap; }
@font-face { font-family: "Barlow Condensed"; font-weight: 800; font-style: italic; src: url("fonts/BarlowCondensed-ExtraBoldItalic.ttf"); font-display: swap; }

:root {
	--ground: #020409;
	--sheet: #0c111d;
	--night: #060911;
	--plate: #161d2f;
	--plate-hover: #202941;
	--plate-down: #293450;
	--line: #263047;
	--ice: #f0f5fc;
	--soft: #a6b3cc;
	--faint: #75829e;
	--gold: #ffd133;
	--on-gold: #171205;
	--well: #78de94;
	--wrong: #ff8c73;
	--home: #d6292e;
	--away: #265cdb;
	--text: "Barlow", system-ui, sans-serif;
	--display: "Barlow Condensed", "Barlow", system-ui, sans-serif;
	color-scheme: dark;
}

* { box-sizing: border-box; }

html { background: var(--ground); }

body {
	margin: 0;
	min-height: 100vh;
	display: flex;
	flex-direction: column;
	align-items: center;
	justify-content: center;
	gap: 20px;
	padding: 32px 16px;
	/* The rink's two ends, far off in the dark. */
	background:
		radial-gradient(60vw 50vh at 0% 0%, rgb(214 41 46 / 0.13), transparent 70%),
		radial-gradient(60vw 50vh at 100% 100%, rgb(38 92 219 / 0.15), transparent 70%),
		var(--ground);
	color: var(--ice);
	font: 400 17px/1.45 var(--text);
	font-variant-numeric: tabular-nums;
	-webkit-font-smoothing: antialiased;
}

.sheet {
	width: 100%;
	max-width: 440px;
	padding: 32px;
	background: var(--sheet);
	border: 1px solid var(--line);
	border-radius: 16px;
	box-shadow: 0 18px 48px rgb(0 0 5 / 0.55);
}

.sheet.wide { max-width: 560px; }

header { margin-bottom: 28px; }

.brand {
	display: block;
	font: italic 800 56px/0.84 var(--display);
	color: var(--ice);
	text-decoration: none;
}

.colours { display: flex; gap: 6px; margin-top: 10px; }
.colours i { width: 44px; height: 4px; border-radius: 2px; }
.colours .home { background: var(--home); }
.colours .away { background: var(--away); }

h1 {
	margin: 0 0 16px;
	font: 800 40px/1 var(--display);
	letter-spacing: 0.6px;
	text-transform: uppercase;
	overflow-wrap: anywhere;
}

h2 {
	margin: 0 0 12px;
	font: 700 20px/1 var(--display);
	letter-spacing: 0.6px;
	text-transform: uppercase;
}

.label {
	margin: 0 0 6px;
	font: 700 13px/1 var(--display);
	letter-spacing: 1.3px;
	text-transform: uppercase;
	color: var(--faint);
}

/* Whatever is yours is gold, as your name over your skater is. */
.own { color: var(--gold); }
h1.own { text-transform: none; margin-bottom: 8px; }

p { margin: 0 0 16px; color: var(--soft); }
p b { color: var(--ice); font-weight: 600; }
p b.own { color: var(--gold); }

.other { margin: 16px 0 0; font-size: 14px; color: var(--faint); }

a { color: var(--ice); text-underline-offset: 3px; }
a:hover { color: var(--gold); }

form { display: flex; flex-direction: column; gap: 14px; }

label {
	display: flex;
	flex-direction: column;
	gap: 6px;
	font: 500 15px/1.2 var(--text);
	color: var(--soft);
}

small { font: 400 13px/1.4 var(--text); color: var(--faint); }
small.well { color: var(--well); }
small.wrong { color: var(--wrong); }

input {
	width: 100%;
	height: 44px;
	padding: 0 12px;
	background: var(--night);
	border: 1px solid var(--line);
	border-radius: 8px;
	color: var(--ice);
	font: 600 17px var(--text);
}

input:focus-visible { outline: 2px solid var(--gold); outline-offset: 1px; border-color: transparent; }
input:disabled { color: var(--faint); }

button {
	height: 44px;
	padding: 0 18px;
	background: var(--plate);
	border: 1px solid var(--line);
	border-radius: 8px;
	color: var(--ice);
	font: 700 18px/1 var(--display);
	letter-spacing: 0.6px;
	text-transform: uppercase;
	cursor: pointer;
}

/* A link that is the one thing to do on a page looks like the button it would be. */
a.button {
	display: flex;
	align-items: center;
	justify-content: center;
	border: 1px solid;
	border-radius: 8px;
	font: 700 18px/1 var(--display);
	letter-spacing: 0.6px;
	text-transform: uppercase;
	text-decoration: none;
}

button:hover { background: var(--plate-hover); }
button:active { background: var(--plate-down); }
button:focus-visible { outline: 2px solid var(--gold); outline-offset: 2px; }
button:disabled { color: var(--faint); cursor: default; background: var(--plate); }

button.primary, a.button.primary {
	height: 52px;
	margin-top: 4px;
	background: var(--gold);
	border-color: var(--gold);
	color: var(--on-gold);
	font-size: 22px;
	font-weight: 800;
	box-shadow: 0 8px 36px rgb(255 209 51 / 0.2);
}

button.primary:hover, a.button.primary:hover { background: #ffdc5c; color: var(--on-gold); }
button.primary:active { background: #e6bc2e; }
button.primary:focus-visible { outline-color: var(--ice); }

button.danger { color: var(--wrong); border-color: rgb(255 140 115 / 0.4); }

.notice {
	margin: 0 0 16px;
	padding: 12px 14px;
	border: 1px solid;
	border-radius: 8px;
	font: 500 15px/1.4 var(--text);
}

.notice.wrong { color: var(--wrong); border-color: rgb(255 140 115 / 0.35); background: rgb(255 140 115 / 0.07); }
.notice.well { color: var(--well); border-color: rgb(120 222 148 / 0.3); background: rgb(120 222 148 / 0.06); }

/* The code a game shows: read off one screen and checked on the other. */
.code {
	font: 800 44px/1 var(--display);
	letter-spacing: 4px;
	color: var(--ice);
}

p.code {
	margin: 0 0 20px;
	padding: 18px;
	text-align: center;
	background: var(--night);
	border: 1px solid var(--line);
	border-radius: 10px;
}

input.code { height: 64px; text-align: center; text-transform: uppercase; }
input.code::placeholder { color: var(--line); }

section { margin-top: 28px; padding-top: 24px; border-top: 1px solid var(--line); }
section > small { display: block; margin-top: 8px; }

/* A box and its button side by side, their feet in line. */
.row { flex-direction: row; align-items: flex-end; gap: 8px; }
.row label { flex: 1; }

.signed, .plain { margin: 0; padding: 0; list-style: none; }

.signed li {
	display: flex;
	align-items: center;
	justify-content: space-between;
	gap: 16px;
	min-height: 56px;
	border-bottom: 1px solid var(--line);
}

.signed li:last-child { border-bottom: 0; }
.signed span { display: flex; flex-direction: column; gap: 2px; }
.signed b { font-weight: 600; }
.signed button { height: 36px; padding: 0 14px; font-size: 16px; }

.plain li { margin-bottom: 10px; padding-left: 14px; border-left: 2px solid var(--line); color: var(--soft); }
.plain b { color: var(--ice); font-weight: 600; }

details { margin-top: 20px; }
summary { cursor: pointer; color: var(--faint); font-size: 14px; }
summary:hover { color: var(--ice); }
details[open] summary { margin-bottom: 12px; }

footer { font-size: 13px; }
footer a { color: var(--faint); }

@media (max-width: 480px) {
	body { justify-content: flex-start; padding: 16px 12px; }
	.sheet { padding: 24px 20px; }
	.brand { font-size: 48px; }
	h1 { font-size: 34px; }
	.code { font-size: 36px; }
	.row { flex-direction: column; align-items: stretch; }
}
