.npr-theme {
  --npr-bg: #0c0c0e;
  --npr-card: #19191d;
  --npr-highlight: #30171d;
  --npr-red: #ff414d;
  --npr-muted: #a5a5b0;
  --npr-border: #303037;
  color: #fff;
  background: var(--npr-bg);
  display: grid;
  gap: 10px;
  padding: 10px;
  border-radius: 14px;
  font-variant-numeric: tabular-nums;
}
.npr-panel { padding: 12px; border-radius: 12px; background: var(--npr-card); border: 1px solid var(--npr-border); min-width: 0; }
.npr-panel h3 { margin: 0 0 8px; }
.npr-panel header { display: flex; align-items: center; gap: 8px; margin: 0; padding: 0; }
.npr-panel header > div { flex: 1; min-width: 0; overflow-wrap: anywhere; }
.npr-panel header strong { flex-shrink: 0; }
.npr-theme small { display: block; color: var(--npr-muted); overflow-wrap: anywhere; }
.npr-note { font-size: .86rem; line-height: 1.35; color: var(--npr-muted); margin: 6px 0; }
.npr-metric { display: grid; grid-template-columns: minmax(0, 1fr) fit-content(47%); align-items: start; gap: 16px; border-bottom: 1px solid var(--npr-border); padding: 8px 0; overflow-wrap: anywhere; }
.npr-metric > div { min-width: 0; text-align: right; }
.npr-metric:last-child { border-bottom: 0; }
.npr-theme select, .npr-theme input, .npr-theme button { min-height: 48px; color: #fff; background: #111114; border: 1px solid var(--npr-border); border-radius: 8px; }
.npr-theme :focus-visible { outline: 2px solid var(--npr-red); outline-offset: 1px; }
.npr-theme select, .npr-theme input { width: 100%; min-width: 0; margin-top: 4px; padding: 0 6px; }
.npr-controls { display: grid; grid-template-columns: repeat(auto-fit, minmax(min(100%, 145px), 1fr)); gap: 8px; }
.npr-theme .npr-list-row { display: block; width: 100%; margin: 5px 0; text-align: left; overflow-wrap: anywhere; }
.npr-theme button:hover { background-color: var(--npr-highlight); }
.npr-rating-table { width: 100%; border-collapse: collapse; text-align: left; }
.npr-rating-table th, .npr-rating-table td { padding: 6px; border-bottom: 1px solid var(--npr-border); }
.npr-rating-table thead { color: var(--npr-muted); font-size: .86rem; }
.npr-rating-table th:last-child, .npr-rating-table td:not(:first-child) { text-align: right; }
.npr-rating-table th[scope="row"] { overflow-wrap: anywhere; }
.npr-rating-table th[scope="row"] button { width: 100%; text-align: left; overflow-wrap: anywhere; }
.npr-theme details summary { min-height: 48px; display: list-item; align-content: center; cursor: pointer; color: #ff858d; }
.npr-theme details + button, .npr-theme label + .npr-panel, .npr-panel + .npr-panel { margin-top: 8px; }
.npr-theme .npr-positive { color: #59d99b; }
.npr-theme .npr-negative { color: #ff858d; }
.npr-theme .npr-position-def { color: #72afff; }
.npr-theme .npr-position-mid { color: #59d99b; }
.npr-theme .npr-position-att { color: #ff858d; }
.npr-theme .npr-position-gk { color: #e0e0e7; }
.npr-chart-scroll { overflow-x: auto; max-width: 100%; }
.npr-chart { position: relative; }
.npr-chart svg { display: block; }
.npr-chart-controls { position: absolute; display: flex; inset: 0; }
.app .npr-chart-controls button { flex: 1 1 0; min-width: 0; padding: 0; border: 0; background: transparent; }
.app .npr-chart-controls button:hover, .app .npr-chart-controls button:focus-visible { background-color: #ff414d19; }

/* Clean Club uses the same club palette as Android. */
:root { --bg:#0C0C0E; --panel:#19191D; --panel2:#111114; --line:#303037; --text:#FFFFFF; --muted:#A5A5B0; --blue:#72AFFF; --green:#59D99B; --red:#FF858D; --yellow:#E6BD71; }
body { background:var(--bg); color:var(--text); font-variant-numeric:tabular-nums; }
.app { padding-inline:16px; }
.app .panel, .app .kpi, .app .match, .app .player-card { background:var(--panel); border-color:var(--line); }
.app button, .app select, .app summary { min-height:48px; }
.app button, .app select { background:var(--panel2); border-color:var(--line); color:var(--text); }
.app .primary, .app button.active, .app button[aria-pressed=true], .app .match.selected { background:#30171D; border-color:#FF414D; color:#FFFFFF; }
.app .win { color:#59D99B; }.app .draw { color:#E0E0E7; }.app .loss { color:#FF858D; }
.app .hidden { display:none !important; }
.web-identity, .clean-score { display:flex; align-items:center; gap:12px; }
.web-identity img { object-fit:contain; }
.clean-score { justify-content:space-between; margin:12px 0; padding:16px; border-radius:14px; background:#30171D; }
.clean-score > div { flex:1; min-width:0; display:grid; justify-items:center; gap:4px; text-align:center; overflow-wrap:anywhere; }
.clean-score strong { font-size:clamp(20px, 5vw, 34px); }
.clean-score small { color:var(--muted); }
.crest-fallback { display:grid; place-items:center; min-height:40px; color:var(--muted); font-size:28px; }
.clean-filters { display:flex; flex-wrap:wrap; gap:6px; margin:8px 0; }
.clean-filters > button, .clean-filters > select { flex:1 1 auto; }
.clean-match-kpis { display:grid; grid-template-columns:repeat(auto-fit,minmax(min(100%,120px),1fr)); gap:6px; margin:10px 0; }
.clean-event { display:grid; grid-template-columns:45px 1fr; gap:16px; padding:10px 0; border-bottom:1px solid var(--line); }
.goal-chart { display:block; width:100%; max-height:210px; }
.goal-chart line { stroke:#303037; stroke-width:1; }.goal-chart text { fill:#A5A5B0; font-size:9px; text-anchor:middle; }
.app .status, .app .notice { background:#111114; color:#E0E0E7; border-color:#303037; }
.app .kpi b { color:#FFFFFF; }.app .kpi span { color:#A5A5B0; }
.app .npr-rating-table { min-width:0 !important; table-layout:fixed; }
.app .npr-rating-table th, .app .npr-rating-table td {
  position:static; background:transparent; border:0; border-bottom:1px solid #303037; min-width:0; width:auto;
  text-align:left; white-space:normal; overflow-wrap:anywhere; padding:6px 4px;
}
.app .npr-rating-table th:first-child, .app .npr-rating-table td:first-child { width:10%; }
.app .npr-rating-table th:nth-child(3):not(:last-child), .app .npr-rating-table td:nth-child(3):not(:last-child) { width:16%; text-align:right; }
.app .npr-rating-table th:last-child, .app .npr-rating-table td:last-child { width:24%; text-align:right; }
.app .npr-rating-table th[scope=row] { font-weight:400; }
.app .npr-rating-table th[scope=row] button { width:100%; font-weight:700; padding:5px 3px; background:transparent; border:0; }
.app .npr-rating-table th[scope=row] button:hover { background:#30171D; }
.app .npr-panel .npr-rating-table th[scope=row] small { font-weight:400; }
.app nav.clean-filters { display:grid; grid-template-columns:repeat(auto-fit,minmax(min(100%,108px),1fr)); }
.app .clean-score img { width:42px; height:42px; object-fit:contain; }
.app .clean-score > div { flex:1.15; }
.app .clean-score > div:nth-child(2) { flex:.9; }
.app .clean-score > div:last-child b { font-size:.88rem; }
.npr-match-winner { display:flex; align-items:center; justify-content:space-between; gap:16px; min-width:0; }
.npr-match-winner > div { flex:1; min-width:0; }
.npr-match-winner button { width:100%; text-align:left; white-space:normal; overflow-wrap:anywhere; }
.app .npr-compare-table th:first-child { width:42%; }
.app .npr-compare-table th:nth-child(2), .app .npr-compare-table th:last-child { width:29%; }
.app .npr-rating-table thead th { font-size:clamp(11px,3vw,13px); overflow-wrap:normal; }
.app .npr-rating-table th:nth-child(3):not(:last-child), .app .npr-rating-table td:nth-child(3):not(:last-child) { width:19%; }

.app .polish-tabs { display:flex; flex-wrap:nowrap; max-width:100%; overflow-x:auto; margin:8px 0; }
.app .polish-tabs button {
  flex:1 0 auto; min-height:48px; padding:6px 7px; font-size:.875rem; white-space:nowrap; min-width:max-content;
  border:0; border-radius:0; border-bottom:2px solid var(--line); background:transparent; color:var(--muted);
}
.app .polish-tabs button[aria-pressed=true] { color:#FF414D; border-color:#FF414D; }
.app .npr-appearances { white-space:normal; table-layout:auto; }
.app .npr-appearances th, .app .npr-appearances td { border:0; border-bottom:1px solid var(--line); padding:6px 3px; }
.app .npr-appearances th { position:static; background:transparent; color:var(--muted); }
.app .npr-appearances :is(th,td):not(:first-child) { width:1%; white-space:nowrap; text-align:right; padding-inline:6px; }
.app .npr-appearances th:first-child b { white-space:nowrap; }
.app .npr-appearances th:first-child button { text-align:left; background:transparent; border:0; padding:4px 0; min-height:48px; }
.app .npr-appearances small { overflow-wrap:normal; }
.clean-event { grid-template-columns:auto minmax(0,1fr) auto; gap:9px; }
.clean-event small { display:block; }
.clean-event .home-goal { color:#FF414D; }
.clean-event .away-goal { color:#72AFFF; }
.clean-event .yellow-card { color:#F1CF53; }
.clean-event .red-card { color:#FF858D; }
.timeline-break { display:flex; justify-content:space-between; gap:12px; margin:12px 0; padding:10px; background:var(--panel); border-radius:8px; }
.app .stats-table { border-collapse:separate; border-spacing:0; }
.app .stats-table thead { position:sticky; top:0; z-index:3; }
.app .stats-table :is(th,td) { border:0; border-bottom:1px solid var(--line); background:var(--panel); }
.app .stats-table thead th { position:static; background:#30171D; color:var(--text); }
.app .stats-table th:first-child { position:sticky; left:0; min-width:112px; width:112px; max-width:112px; white-space:normal; }
.app .stats-table tbody th:first-child { z-index:2; }
.position-marker { display:inline-block; width:4px; height:1em; margin-inline-end:5px; border-radius:2px; background:currentColor; }
.analytics-switch {
  display:flex; align-items:center; gap:10px; background:#19191D; border:1px solid #C91E33;
  border-radius:12px; padding:6px 10px; margin:6px 0 14px; min-height:58px; cursor:pointer;
}
.analytics-switch > span:last-child { flex:1; display:grid; min-width:0; }
.analytics-switch .analytics-icon { background:#30171D; color:#FF414D; padding:8px 12px; border-radius:8px; }
.app .analytics-switch select {
  min-width:0; min-height:48px; padding:4px 8px; font-weight:750;
  background:transparent; border-color:transparent; cursor:pointer; color-scheme:dark;
}
.analytics-switch:focus-within { outline:2px solid #FF414D; outline-offset:2px; }
.analytics-group { margin:8px 0; }
.analytical-row { display:flex; justify-content:space-between; align-items:baseline; gap:16px; padding:6px 0; }
.analytical-row b { text-align:right; }
.analytical-row .positive { color:#59D99B; }
.analytical-row .negative { color:#FF858D; }
.accuracy-target { height:6px; position:relative; border-radius:4px; background:#303037; margin:1px 0 9px; }
.accuracy-target i { position:absolute; height:100%; border-radius:4px; }
.accuracy-target .positive { background:#59D99B; }
.accuracy-target .negative { background:#FF858D; }
.accuracy-target .neutral { background:#A5A5B0; }
.accuracy-target .mark { width:2px; height:10px; top:-2px; background:#E0E0E7; }
.analytics-filter { display:flex; flex-wrap:wrap; gap:8px; align-items:center; }

.compare-cards{display:grid;grid-template-columns:repeat(2,minmax(0,1fr));gap:8px;margin:8px 0}
.player-compare-cards{grid-template-columns:repeat(auto-fit,minmax(min(100%,10em),1fr))}
.player-compare-cards h3{overflow-wrap:normal;hyphens:none}
.compare-card{border-top:3px solid currentColor;min-width:0;overflow-wrap:break-word}
.compare-a{color:#ff414d}.compare-b{color:#72afff}
.compare-card p,.compare-card .npr-metric{color:#fff}
.metric-group{margin:8px 0;background:#111114;border:1px solid #303037;border-radius:8px;padding:3px 8px;min-width:0}
.metric-group summary{font-weight:700;cursor:pointer;min-height:48px;align-content:center}
.metrics-table-wrap{overflow-x:auto;max-width:100%}
.app .metrics-table{width:100%;min-width:var(--metrics-width,24em)!important;font-size:.75rem;table-layout:fixed;white-space:normal}
.app .metrics-table :is(th,td){position:static;min-width:0!important;border:0;border-bottom:1px solid #303037;background:transparent;padding:6px 3px;font-variant-numeric:tabular-nums}
.app .metrics-table :is(th,td):first-child{width:28%;text-align:left;overflow-wrap:break-word}
.app .metrics-table thead th{font-size:.68rem;padding-inline:2px;text-align:center;overflow-wrap:normal}
.app .metrics-table thead th:first-child{text-align:left}
.app .metrics-table td{text-align:center;white-space:nowrap}
.app .metrics-table small{display:block;color:#a5a5b0}
.dual-chart{display:grid;text-align:center;margin:3px 0;padding:8px 3px;border-bottom:1px solid #303037;gap:4px}
.dual-chart > .dual-bars{display:grid;grid-template-columns:1fr 1fr;gap:4px;align-items:center}
.dual-chart > .dual-values{display:flex;justify-content:space-between;gap:8px;font-variant-numeric:tabular-nums;font-weight:800}
.dual-chart .npr-missing,.metrics-table .npr-missing{color:#A5A5B0}
.dual-chart small{color:#A5A5B0}
.dual-chart i{background:#303037;display:flex;height:6px;border-radius:4px;overflow:hidden}
.dual-chart i.left{justify-content:flex-end}
.dual-chart em{background:#72afff}.dual-chart .left em{background:#ff414d}
.dual-chart .npr-positive,.metrics-table .npr-positive{color:#59d99b}
.dual-chart .npr-negative,.metrics-table .npr-negative{color:#ff858d}
.npr-rating-table progress{max-width:100%;height:5px;accent-color:#ff414d}
.compare-pinned{position:sticky;top:0;z-index:2;background:#0c0c0e}
.compare-pinned .sfl-crest{vertical-align:middle;margin-right:8px}
.comparison-legend{font-size:.85rem;color:#a5a5b0}
.comparison-legend .positive{color:#59d99b}.comparison-legend .negative{color:#ff858d}
.match-rating-details summary{align-content:center;color:#ff858d;font-weight:700;cursor:pointer}
#teamSummary label{display:inline-grid;margin:3px 7px 6px 0}
#teamSummary label select{width:100%;min-width:0;max-width:100%}
.match-link{display:inline-block;color:#ff858d;padding:12px 0}

/* Compact rating identity and bounded progress on narrow screens. */
.app .npr-panel{min-width:0;max-width:100%}.app .npr-rating-table{width:100%;max-width:100%;table-layout:fixed}.app .npr-rating-table th,.app .npr-rating-table td{min-width:0;padding:6px 3px;white-space:normal}.npr-rank-identity{display:flex;align-items:center;gap:6px;min-width:0}.npr-rank-identity button{min-width:0;flex:1}.npr-rank-identity .sfl-portrait{width:28px;height:28px;flex-shrink:0}.app .npr-rating-table progress{display:block;width:100%;min-width:0;max-width:100%}.app .npr-rating-table th[scope=row] small{display:block;overflow-wrap:anywhere}.app .npr-rating-table td{font-variant-numeric:tabular-nums}.app .npr-rating-table thead th{overflow-wrap:anywhere}
