/* Wettbewerbsseiten – gleiche Regeln wie das Spielerprofil (Zellen, Listen, 15 px Kante, eckig) */

.fi-comppage { --pl-line: #ececef; --pl-muted: #6b6f76; --pl-pink: #e6197a; background: #fff; }

/* Kopf */
.fi-cp-head { padding: 20px 15px 16px; border-top: 1px solid var(--pl-line); }
.fi-cp-title { display: flex; align-items: center; gap: 16px; }
.fi-cp-logo { display: grid; place-items: center; flex: none; width: 64px; height: 64px; }
.fi-cp-logo img { display: block; max-width: 64px; max-height: 64px; width: auto; height: auto; }
.fi-cp-title h1 { margin: 4px 0 0; color: #111; font-size: 26px; font-weight: 800; line-height: 1.1; letter-spacing: -.03em; }

/* Kennzahlen (Zellen aus fi-player.css) */
.fi-cp-cells { border-top: 1px solid var(--pl-line); }
.fi-cp-cells .fi-pl-cell > b { color: #111; }
.fi-cp-cells .fi-pl-cell:first-child > b { color: var(--pl-pink); }
.fi-cp-form { display: flex; gap: 3px; height: 26px; align-items: center; }
.fi-cp-form i { display: grid; place-items: center; width: 20px; height: 20px; color: #fff; font-size: 11px; font-style: normal; font-weight: 800; }
.fi-cp-form .is-w { background: #1e9e57; }
.fi-cp-form .is-d { background: #9a9ca1; }
.fi-cp-form .is-l { background: #d6283b; }

/* Nächstes / letztes Spiel */
.fi-cp-duo { border-bottom: 1px solid var(--pl-line); }
.fi-cp-duo .fi-pl-kicker { padding-bottom: 0; }
.fi-cp-duo .fi-cp-games li:last-child a { border-bottom: 0; }

/* Spielzeile: Datum/Runde | Paarung | Ergebnis */
.fi-cp-games { margin: 0 15px; padding: 0; list-style: none; }
.fi-cp-game { display: grid; grid-template-columns: 76px minmax(0, 1fr) 58px; align-items: center; gap: 12px; padding: 12px 0; border-bottom: 1px solid var(--pl-line); color: #111; text-decoration: none; }
.fi-cp-game-when { display: flex; flex-direction: column; gap: 4px; min-width: 0; }
.fi-cp-game-when b { font-size: 13px; font-weight: 800; white-space: nowrap; }
.fi-cp-game-when small { overflow: hidden; color: var(--pl-muted); font-size: 11.5px; line-height: 1.2; text-overflow: ellipsis; }
.fi-cp-game-teams { display: flex; flex-direction: column; gap: 6px; min-width: 0; }
.fi-cp-game-teams > span { display: flex; align-items: center; gap: 8px; overflow: hidden; color: #3a3a40; font-size: 14px; text-overflow: ellipsis; white-space: nowrap; }
.fi-cp-game-teams > span.is-own { color: #111; font-weight: 800; }
.fi-cp-score { display: flex; flex-direction: column; align-items: center; gap: 3px; }
.fi-cp-score b { display: grid; place-items: center; min-width: 50px; height: 28px; padding: 0 6px; background: #f4f4f6; color: #111; font-size: 14px; font-weight: 800; font-variant-numeric: tabular-nums; }
.fi-cp-score small { color: var(--pl-muted); font-size: 10.5px; }
.fi-cp-score.is-s b { background: #1e9e57; color: #fff; }
.fi-cp-score.is-u b { background: #9a9ca1; color: #fff; }
.fi-cp-score.is-n b { background: #d6283b; color: #fff; }
.fi-cp-score.is-live b { background: var(--pl-pink); color: #fff; }
.fi-cp-score.is-pre { align-self: center; }
.fi-cp-score.is-pre b { background: var(--pl-pink, #e6197a); color: #fff; }
.fi-cp-game:hover .fi-cp-game-teams .is-own { color: var(--pl-pink); }
#fi-cp-spiele .fi-cp-games { margin-bottom: 8px; }

/* Reiter */
.fi-cp-tabs { grid-template-columns: repeat(3, 1fr) !important; }
.fi-cp-tabs.is-two { grid-template-columns: repeat(2, 1fr) !important; }

/* Tabelle */
.fi-cp-table { width: calc(100% - 30px); margin: 12px 15px 0; border-collapse: collapse; font-size: 14px; font-variant-numeric: tabular-nums; }
.fi-cp-table th { padding: 8px 4px; border-bottom: 1px solid #111; color: var(--pl-muted); font-size: 11px; font-weight: 800; letter-spacing: .08em; text-align: right; text-transform: uppercase; }
.fi-cp-table td { padding: 10px 4px; border-bottom: 1px solid var(--pl-line); text-align: right; }
.fi-cp-table th:nth-child(1), .fi-cp-table td:nth-child(1) { width: 28px; padding-left: 8px; text-align: left; }
.fi-cp-table th:nth-child(2), .fi-cp-table td:nth-child(2) { text-align: left; }
.fi-cp-table th:last-child, .fi-cp-table td:last-child { padding-right: 0; }
.fi-cp-table td:nth-child(1) { box-shadow: inset 3px 0 0 transparent; color: var(--pl-muted); font-weight: 700; }
.fi-cp-team { display: flex; align-items: center; gap: 10px; min-width: 0; }
.fi-cp-team > span:last-child { overflow: hidden; max-width: 170px; text-overflow: ellipsis; white-space: nowrap; }
.fi-cp-table tr.is-own td { background: #fdeef5; font-weight: 800; }
.fi-cp-table tr.is-own td:nth-child(1) { color: var(--pl-pink); }
/* Zonen als Streifen links */
.z-cl td:nth-child(1) { box-shadow: inset 3px 0 0 #e6197a !important; }
.z-playoff td:nth-child(1) { box-shadow: inset 3px 0 0 #f29ac4 !important; }
.z-el td:nth-child(1) { box-shadow: inset 3px 0 0 #111 !important; }
.z-ecl td:nth-child(1) { box-shadow: inset 3px 0 0 #9a9ca1 !important; }
.z-relplay td:nth-child(1) { box-shadow: inset 3px 0 0 #f0a35b !important; }
.z-down td:nth-child(1) { box-shadow: inset 3px 0 0 #d6283b !important; }
.fi-cp-legend { display: flex; flex-wrap: wrap; gap: 8px 16px; margin: 12px 15px 24px; padding: 0; list-style: none; color: var(--pl-muted); font-size: 12px; }
.fi-cp-legend li { display: flex; align-items: center; gap: 6px; }
.fi-cp-legend li::before { content: ""; width: 3px; height: 14px; }
.fi-cp-legend .z-cl::before { background: #e6197a; }
.fi-cp-legend .z-playoff::before { background: #f29ac4; }
.fi-cp-legend .z-el::before { background: #111; }
.fi-cp-legend .z-ecl::before { background: #9a9ca1; }
.fi-cp-legend .z-relplay::before { background: #f0a35b; }
.fi-cp-legend .z-down::before { background: #d6283b; }
.fi-pl-cell > small { display: block; overflow: hidden; text-overflow: ellipsis; }
.fi-pl-cell > small.fi-pl-trend { display: flex; }

/* Tabelle mit schmalerem Außenrand, damit sie nicht gequetscht wirkt (alle Wettbewerbe) */
.fi-cp-table { width: calc(100% - 12px); margin: 12px 6px 0; }
.fi-cp-table th:last-child, .fi-cp-table td:last-child { padding-right: 8px; }
.fi-cp-table th:nth-child(2), .fi-cp-table td:nth-child(2) { padding-left: 2px; }

/* Computer: Titel + Kennzahlen in einer Zeile, darunter letztes (links) und nächstes Spiel (rechts) nebeneinander,
 * ohne Spiele-Leiste oben. Handy unverändert. */
@media (min-width: 1024px) {
	body.fi-comppage .fi-fixtures { display: none; }
	.fi-cp-top { display: grid; grid-template-columns: auto minmax(0, 1fr); align-items: center; gap: 48px; max-width: var(--w-max); margin: 0 auto; padding: 28px var(--w-pad) 24px; box-sizing: border-box; }
	body.fi-comppage .fi-cp-top > :is(.fi-cp-head, .fi-cp-cells) { max-width: none !important; margin: 0 !important; padding: 0 !important; border: 0; } /* gegen die Breiten-Regel in fi-wide.css (enthält eine ID) */
	.fi-cp-logo, .fi-cp-logo img { width: 72px; height: 72px; max-width: 72px; max-height: 72px; }
	.fi-cp-title h1 { font-size: 40px; letter-spacing: -.035em; }
	.fi-cp-top .fi-pl-cell { padding: 4px 28px; }
	.fi-cp-top .fi-pl-cell:last-child { padding-right: 0; }

	body.fi-comppage .fi-cp-duo { display: grid; grid-template-columns: minmax(0, 1fr) minmax(0, 1fr); gap: var(--w-gap); padding-bottom: 8px; border-top: 1px solid var(--pl-line); }
	.fi-cp-duo-last { order: -1; }
	.fi-cp-duo .fi-pl-kicker { padding-inline: 0; }
	.fi-cp-duo .fi-cp-games { margin: 0; }
}
