/* Spielerprofil (tag.php) – baut auf front.css + category.css auf */

/* Kopf */
.ri-player-hero {
	position: relative;
	display: grid;
	grid-template-columns: 112px 1fr;
	gap: 16px;
	align-items: end;
	padding: 20px var(--ri-pad) 0;
	overflow: hidden;
	background: radial-gradient(120% 100% at 80% 0%, #163A74 0%, var(--ri-navy) 55%, #081E44 100%);
	color: #fff;
}
.ri-player-hero::after {
	/* großes Kronen-Wasserzeichen */
	content: "";
	position: absolute;
	right: -40px;
	top: -30px;
	width: 220px;
	height: 220px;
	background: url("logo/realinside-icon-square.svg") center / contain no-repeat;
	opacity: .06;
	pointer-events: none;
}
.ri-player-photo {
	align-self: end;
	width: 112px;
	aspect-ratio: 3 / 4;
	overflow: hidden;
	background: rgba(255, 255, 255, .08);
	border-bottom: 4px solid var(--ri-accent);
}
.ri-player-photo img { display: block; width: 100%; height: 100%; object-fit: cover; object-position: 50% 20%; }
.ri-player-id { padding-bottom: 16px; min-width: 0; }
.ri-player-no { color: var(--ri-accent); font-size: 28px; font-weight: 800; line-height: 1; }
.ri-app .ri-player-name { margin: 4px 0 0; color: #fff; font-size: 26px; font-weight: 800; line-height: 1.1; letter-spacing: -0.01em; }
.ri-player-club, .ri-player-nation { display: flex; flex-wrap: wrap; align-items: center; gap: 6px; margin: 8px 0 0; color: #D5DDEE; font-size: 14px; font-weight: 600; }
.ri-player-club img, .ri-player-nation img { width: 20px; height: 20px; object-fit: contain; }
.ri-player-injured { margin-left: 4px; padding: 2px 6px; background: #D6283B; color: #fff; font-size: 11px; font-weight: 800; letter-spacing: .06em; text-transform: uppercase; }
.ri-player-value {
	grid-column: 1 / -1;
	display: flex;
	align-items: baseline;
	justify-content: space-between;
	margin: 0 calc(-1 * var(--ri-pad));
	padding: 12px var(--ri-pad);
	background: rgba(0, 0, 0, .25);
}
.ri-player-value span { color: #A9B8D6; font-size: 12px; font-weight: 800; letter-spacing: .1em; text-transform: uppercase; }
.ri-player-value strong { color: var(--ri-accent); font-size: 22px; font-weight: 800; }

/* Tabs: drei nebeneinander */
.ri-playerpage .ri-tabs--3 { grid-template-columns: repeat(3, 1fr); }

/* Saison-Kennzahlen */
.ri-player-kpis {
	display: grid;
	grid-template-columns: repeat(3, 1fr);
	gap: 1px;
	background: var(--ri-line);
	border-bottom: 1px solid var(--ri-line);
}
.ri-kpi { display: flex; flex-direction: column; align-items: center; gap: 2px; padding: 14px 6px; background: #fff; text-align: center; }
.ri-kpi strong { color: var(--ri-navy); font-size: 26px; font-weight: 800; line-height: 1.1; font-variant-numeric: tabular-nums; }
.ri-kpi.is-key strong { color: var(--ri-accent); }
.ri-kpi span { color: var(--ri-muted); font-size: 11px; font-weight: 700; letter-spacing: .04em; text-transform: uppercase; }
.ri-player-season { grid-column: 1 / -1; margin: 0; padding: 8px var(--ri-pad); background: #F6F7FA; color: var(--ri-muted); font-size: 12px; font-weight: 600; text-align: center; }

/* Steckbrief */
.ri-facts { margin: 0; padding: 0 var(--ri-pad); }
.ri-facts div { display: flex; justify-content: space-between; gap: 16px; padding: 10px 0; border-bottom: 1px solid var(--ri-line); font-size: 15px; }
.ri-facts dt { color: var(--ri-muted); font-weight: 600; }
.ri-facts dd { margin: 0; font-weight: 700; text-align: right; }

/* Leistungsdaten-Tabelle */
.ri-perf td, .ri-perf th { text-align: center; }
.ri-perf .ri-table-team { text-align: left; }
.ri-perf tr.is-real td { font-weight: 800; }

/* Form der letzten 5 Spiele (Kopf) */
.ri-player-form { display: flex; align-items: center; gap: 6px; margin-top: 14px; }
.ri-player-form-label { margin-right: 4px; color: #A9B8D6; font-size: 11px; font-weight: 800; letter-spacing: .12em; text-transform: uppercase; }
.ri-app .ri-form-tile {
	display: flex;
	flex-direction: column;
	align-items: center;
	gap: 3px;
	width: 38px;
	padding: 5px 0 4px;
	background: rgba(255, 255, 255, .08);
	border-bottom: 3px solid #7E8794;
	color: #fff;
}
.ri-form-tile.is-s { border-bottom-color: #1E9E57; }
.ri-form-tile.is-n { border-bottom-color: #D6283B; }
.ri-form-tile img { width: 22px; height: 22px; object-fit: contain; }
.ri-form-tile b { color: var(--ri-accent); font-size: 11px; font-weight: 800; line-height: 1; white-space: nowrap; }

/* Spiele: nach Monat, als Paarung */
.ri-pmatches { padding: 4px var(--ri-pad) 24px; }
.ri-app .ri-pmonth {
	margin: 20px 0 8px;
	color: var(--ri-muted);
	font-size: 12px;
	font-weight: 800;
	letter-spacing: .12em;
	text-transform: uppercase;
}
.ri-app .ri-pmatch {
	display: grid;
	gap: 10px;
	margin-bottom: 8px;
	padding: 12px 14px;
	background: #F6F7FA;
	border-left: 4px solid #9A9FA8;
	color: var(--ri-text);
	transition: background .15s;
}
.ri-app .ri-pmatch:hover { background: #EEF1F6; }
.ri-pmatch.is-s { border-left-color: #1E9E57; }
.ri-pmatch.is-n { border-left-color: #D6283B; }
.ri-pmatch-meta { display: flex; align-items: center; gap: 6px; color: var(--ri-muted); font-size: 12px; font-weight: 700; }
.ri-pmatch-meta img { width: 18px; height: 18px; object-fit: contain; }
.ri-pmatch-meta time { margin-left: auto; }
.ri-pmatch-teams { display: grid; grid-template-columns: minmax(0, 1fr) auto minmax(0, 1fr); align-items: center; gap: 10px; }
.ri-pmatch-team { display: flex; align-items: center; justify-content: flex-end; gap: 8px; min-width: 0; font-size: 15px; font-weight: 600; }
.ri-pmatch-team span { overflow: hidden; white-space: nowrap; text-overflow: ellipsis; }
.ri-pmatch-team img { flex: 0 0 auto; width: 28px; height: 28px; object-fit: contain; }
.ri-pmatch-team--away { justify-content: flex-start; }
.ri-pmatch-team .is-abbr { display: none; letter-spacing: .02em; }
@media (max-width: 479px) {
	.ri-pmatch-team .is-full { display: none; }
	.ri-pmatch-team .is-abbr { display: inline; }
}
.ri-pmatch-team.is-real { font-weight: 800; }
.ri-pmatch-score {
	min-width: 56px;
	padding: 5px 8px;
	background: var(--ri-navy);
	color: #fff;
	font-size: 17px;
	font-weight: 800;
	text-align: center;
	font-variant-numeric: tabular-nums;
}
.ri-pmatch-contrib { display: flex; flex-wrap: wrap; align-items: center; justify-content: center; gap: 6px; }
.ri-chip-g, .ri-chip-a { padding: 3px 8px; font-size: 12px; font-weight: 800; }
.ri-chip-g { background: var(--ri-accent); color: var(--ri-navy); }
.ri-chip-a { background: var(--ri-navy); color: var(--ri-accent); }
.ri-chip-card { width: 10px; height: 14px; background: #F2C230; }
.ri-chip-card.is-red { background: #D6283B; }
.ri-chip-none { color: var(--ri-muted); font-size: 12px; font-weight: 600; }

@media (min-width: 1024px) {
	.ri-player-hero { grid-template-columns: 200px minmax(0, 1fr) auto; gap: 32px; padding-top: 32px; }
	.ri-player-hero::after { width: 420px; height: 420px; top: -80px; right: 5%; }
	.ri-player-photo { width: 200px; }
	.ri-player-id { padding-bottom: 28px; }
	.ri-player-no { font-size: 40px; }
	.ri-app .ri-player-name { font-size: 44px; }
	.ri-player-club, .ri-player-nation { font-size: 16px; }
	.ri-player-value { grid-column: auto; flex-direction: column; align-items: flex-end; gap: 4px; align-self: end; margin: 0 0 28px; padding: 16px 20px; border: 1px solid rgba(231, 185, 76, .4); background: rgba(0, 0, 0, .2); }
	.ri-player-value strong { font-size: 32px; }

	.ri-player-kpis { grid-template-columns: repeat(6, 1fr); padding-inline: var(--ri-pad); background: #fff; gap: 0; }
	.ri-kpi { padding: 20px 6px; border-right: 1px solid var(--ri-line); }
	.ri-kpi:first-child { border-left: 1px solid var(--ri-line); }
	.ri-kpi strong { font-size: 34px; }
	.ri-player-season { background: #fff; border-top: 1px solid var(--ri-line); }

	.ri-playerpage .ri-tabs { display: flex; gap: 8px; }
	.ri-playerpage .ri-tab { padding: 0 20px; }
	.ri-player-main { padding-inline: var(--ri-pad); padding-top: 12px; }
	.ri-player-main > .ri-panel { --ri-pad: 0px; }
	.ri-player-grid { display: grid; grid-template-columns: 360px minmax(0, 1fr); gap: 48px; align-items: start; }
	#ri-panel-news:not([hidden]) { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 0 40px; }
	#ri-panel-news .ri-pager { grid-column: 1 / -1; }
	.ri-pmatches { padding-inline: 0; }
	.ri-app .ri-pmatch { grid-template-columns: 200px minmax(0, 1fr) 220px; align-items: center; gap: 24px; padding: 14px 20px; }
	.ri-pmatch-meta { flex-wrap: wrap; }
	.ri-pmatch-meta time { order: -1; width: 100%; margin: 0 0 2px; color: var(--ri-text); font-size: 13px; }
	.ri-pmatch-contrib { justify-content: flex-end; }
	.ri-player-form { margin-top: 18px; }
	.ri-app .ri-form-tile { width: 46px; }
}
