/* ==========================================================================================
   B17 — the player profile. Linked after gameplan.css and game.css: every token, .btn, .icon-btn and .back-btn are
   theirs. The player on the left, his Game Plan piece large in his kit (round 2, the user: no hexagon, no card stats);
   his file on the right, one plate, three tabs. A layer over the page it was opened from, with no bar.
   Colour: the kit colours the piece; blue is only the selected tab and the sliders; green and red keep the form
   meanings (up / down); nothing else is coloured.
   ========================================================================================== */

:root[data-profile] .career-bar { opacity: 0; visibility: hidden; pointer-events: none; }
:root[data-profile] .career-page { visibility: hidden; }

.pp {
  --pp-gap: clamp(20px, 2.6vw, 60px);
  --pp-up: var(--form-win);
  --pp-down: var(--form-loss);
  position: fixed; inset: 0; z-index: 45;
  display: grid; grid-template-columns: minmax(0, 41fr) minmax(0, 59fr); grid-template-rows: auto minmax(0, 1fr) auto;
  grid-template-areas: "top file" "hero file" "hero actions";
  column-gap: var(--pp-gap); row-gap: clamp(10px, 1.6vh, 18px);
  padding: clamp(24px, 6vh, 72px) calc(var(--frame-x) * 0.8);
  color: var(--ink-900);
}
.pp > * { position: relative; z-index: 1; }
.pp.is-busy .pp-file, .pp.is-busy .pp-actions { cursor: progress; }

/* --- the top row -------------------------------------------------------------------------------------------- */
.pp-top { grid-area: top; display: flex; align-items: center; gap: 10px; min-height: 44px; }
.pp-top-gap { flex: 1; }
.pp-switch { display: flex; align-items: stretch; height: 44px; box-shadow: var(--shadow-1); }
.pp-switch[hidden] { display: none; }
.pp-arrow {
  width: 44px; border: 0; cursor: pointer; display: grid; place-items: center; background: var(--paper); color: var(--ink-900);
  transition: background var(--t-micro), transform var(--t-micro) var(--ease-out);
}
.pp-arrow svg { width: 18px; height: 18px; }
.pp-arrow:hover { background: var(--paper-2); }
.pp-arrow:active { transform: scale(0.94); }
.pp-count {
  display: grid; place-items: center; min-width: 76px; padding: 0 12px; background: var(--surface); backdrop-filter: blur(var(--blur)); -webkit-backdrop-filter: blur(var(--blur));
  font-family: var(--font-display); font-weight: 600; font-size: 16px; letter-spacing: 0.1em; color: var(--ink-500);
}

/* --- the hero ----------------------------------------------------------------------------------------------- */
.pp-hero { grid-area: hero; container-type: inline-size; display: flex; flex-direction: column; justify-content: center; min-height: 0; touch-action: pan-y; }
.pp-card { display: grid; grid-template-columns: 25cqw minmax(0, 1fr); align-items: center; }
.pp-rating { display: flex; flex-direction: column; align-items: flex-start; gap: 0.6cqw; align-self: start; padding-top: 7cqw; }
.pp-ovr {
  font-family: var(--font-display); font-weight: 700; font-size: 22cqw; line-height: 0.8; letter-spacing: -0.01em;
  text-shadow: 0 2px 0 rgba(255, 255, 255, 0.55);
}
.pp-pos { font-family: var(--font-display); font-weight: 700; font-size: 7cqw; line-height: 1; letter-spacing: 0.06em; margin-top: 1.4cqw; }
.pp-role { font-weight: 600; font-size: clamp(12px, 2.3cqw, 18px); color: var(--ink-500); line-height: 1.2; max-width: 23cqw; }
.pp-squad-role {
  margin-top: 1.8cqw; padding: 4px 10px 3px; font-family: var(--font-display); font-weight: 700; font-size: clamp(13px, 2.4cqw, 19px);
  letter-spacing: 0.12em; text-transform: uppercase; background: var(--surface-strong); color: var(--ink-900); box-shadow: 0 1px 2px rgba(16, 24, 40, 0.12);
}
.pp-squad-role[data-role="key"] { background: var(--ink-900); color: #fff; }
.pp-squad-role[data-role="prospect"], .pp-squad-role[data-role="rotation"] { color: var(--ink-500); }
.pp-squad-role[hidden] { display: none; }
/* the season's change, FIFA-style (8 Oct 2026): a small triangle and the number at the overall's shoulder, green up,
   red down; no box, no words (they are in its title) */
.pp-ovr-line { display: flex; align-items: flex-start; gap: 1.2cqw; }
.pp-change {
  display: inline-flex; align-items: center; gap: 0.6cqw; margin-top: 0.6cqw;
  font-family: var(--font-display); font-weight: 700; font-size: max(22px, 8.1cqw); line-height: 1;
  text-shadow: 0 1px 0 rgba(255, 255, 255, 0.6);
}
.pp-change svg { width: 0.62em; height: 0.5em; fill: currentColor; }
.pp-change[data-dir="up"] { color: var(--pp-up); }
.pp-change[data-dir="down"] { color: var(--pp-down); }
.pp-change[data-dir="down"] svg { margin-top: 0.08em; }
.pp-change[hidden] { display: none; }

/* the piece, straight on the stadium (round 2, the user: no stage behind it) */
.pp-stage { position: relative; width: min(100%, 50vh); aspect-ratio: 1; justify-self: center; container-type: inline-size; }
.pp-orb { position: absolute; left: 50%; top: 48%; width: 62%; aspect-ratio: 1; margin: -31% 0 0 -31%; }
.pp-orb-roll { position: absolute; inset: 0; border-radius: 50%; }
/* the ball is the Game Plan's piece (A4: one kit everywhere), as big as the orb */
.pp-ball { --sphere: 62cqw; }
.pp-ball .sphere-label { font-size: calc(var(--sphere) * 0.33); text-shadow: 0 1px 0 rgba(0, 0, 0, 0.5), 0 -1px 0 rgba(255, 255, 255, 0.28), 0 0 10px rgba(0, 0, 0, 0.25); }

.pp-name { margin: 2.2cqw 0 0; display: flex; flex-direction: column; gap: 0.6cqw; font-weight: 400; min-width: 0; }
.pp-first { font-family: var(--font-display); font-weight: 600; font-size: clamp(14px, 3.2cqw, 28px); letter-spacing: 0.26em; text-transform: uppercase; color: var(--ink-700); line-height: 1; }
.pp-first[hidden] { display: none; }
.pp-last {
  --fit: 1; display: block; white-space: nowrap; width: max-content; max-width: none;
  font-family: var(--font-display); font-weight: 700; font-size: calc(16.5cqw * var(--fit)); line-height: 0.84; letter-spacing: 0.004em; text-transform: uppercase;
  text-shadow: 0 2px 0 rgba(255, 255, 255, 0.55);
}
.pp-meta { margin: 1.8cqw 0 0; display: flex; flex-wrap: wrap; align-items: center; gap: 0 0.6em; font-weight: 600; font-size: clamp(13px, 2.5cqw, 20px); color: var(--ink-700); }
.pp-sep { color: var(--ink-300); font-weight: 400; }
.pp-stars { display: inline-flex; gap: 2px; margin-left: 0.3em; vertical-align: -1px; }
.pp-stars i { width: 0.78em; height: 0.78em; background: rgba(16, 21, 31, 0.18); clip-path: polygon(50% 0, 61% 35%, 98% 35%, 68% 57%, 79% 91%, 50% 70%, 21% 91%, 32% 57%, 2% 35%, 39% 35%); }
.pp-stars i.is-on { background: var(--ink-900); }
.pp-crest { display: inline-block; width: 1.5em; flex: none; filter: drop-shadow(0 2px 4px rgba(16, 24, 40, 0.18)); }
.pp-crest .crest { width: 100%; height: auto; display: block; }
.pp-also { margin: 1.8cqw 0 0; display: flex; align-items: center; flex-wrap: wrap; gap: 6px; }
.pp-also .pp-k { margin-right: 4px; }
.pp-alt {
  display: inline-flex; align-items: center; gap: 7px; height: 30px; padding: 0 10px; background: var(--surface); backdrop-filter: blur(var(--blur)); -webkit-backdrop-filter: blur(var(--blur));
  box-shadow: 0 1px 2px rgba(16, 24, 40, 0.1); font-family: var(--font-display); font-weight: 700; font-size: clamp(13px, 2.2cqw, 17px); letter-spacing: 0.06em; color: var(--ink-500);
}
.pp-alt b { color: var(--ink-900); font-size: 1.12em; }
.pp-alt.is-natural { box-shadow: inset 0 -2px 0 var(--ok), 0 1px 2px rgba(16, 24, 40, 0.1); }
.pp-standing { margin: 1cqw 0 0; display: flex; align-items: center; gap: 10px; font-family: var(--font-display); font-weight: 600; font-size: clamp(13px, 2.3cqw, 19px); letter-spacing: 0.08em; text-transform: uppercase; color: var(--ink-500); }
.pp-armband { font-style: normal; padding: 2px 8px; background: var(--ink-900); color: #fff; font-size: 0.8em; letter-spacing: 0.1em; }

/* --- the file ----------------------------------------------------------------------------------------------- */
.pp-file {
  grid-area: file; position: relative; min-height: 0; display: flex; flex-direction: column; overflow: hidden;
  background: var(--surface); backdrop-filter: blur(var(--blur)); -webkit-backdrop-filter: blur(var(--blur)); box-shadow: var(--shadow-1);
}
.pp-tabs { position: relative; display: flex; flex: none; height: clamp(46px, 5.8vh, 62px); background: rgba(255, 255, 255, 0.4); box-shadow: inset 0 -1px 0 var(--line); }
.pp-tab {
  position: relative; z-index: 1; flex: 1; border: 0; background: transparent; cursor: pointer;
  font-family: var(--font-display); font-weight: 700; font-size: clamp(15px, 1.2vw, 22px); letter-spacing: 0.08em; text-transform: uppercase; color: var(--ink-500);
  transition: color var(--t-fast);
}
.pp-tab:hover, .pp-tab.is-on { color: var(--ink-900); }
.pp-tab:focus-visible { outline: 2px solid var(--accent); outline-offset: -4px; }
.pp-tab-indicator {
  position: absolute; z-index: 0; top: 0; bottom: 0; left: 0; width: 0; background: var(--paper); box-shadow: 0 4px 12px rgba(16, 24, 40, 0.1);
  transition: left var(--t-page) var(--ease-out), width var(--t-page) var(--ease-out);
}
.pp-tab-indicator::after { content: ""; position: absolute; left: 0; right: 0; bottom: 0; height: 3px; background: var(--accent); }

.pp-body { flex: 1; min-height: 0; overflow-y: auto; overscroll-behavior: contain; scrollbar-width: thin; scrollbar-color: rgba(16, 21, 31, 0.22) transparent; }
.pp-body::-webkit-scrollbar { width: 6px; }
.pp-body::-webkit-scrollbar-thumb { background: rgba(16, 21, 31, 0.22); }
.pp-panel { display: flex; flex-direction: column; gap: clamp(12px, 2.1vh, 24px); padding: clamp(16px, 2.6vh, 30px) clamp(18px, 1.9vw, 36px) clamp(18px, 2.8vh, 32px); }
.pp-panel.is-fresh > * { animation: pp-rise 460ms var(--ease-out) backwards; }
.pp-panel.is-fresh > :nth-child(2) { animation-delay: 50ms; }
.pp-panel.is-fresh > :nth-child(3) { animation-delay: 100ms; }
.pp-panel.is-fresh > :nth-child(4) { animation-delay: 150ms; }
.pp-panel.is-fresh > :nth-child(5) { animation-delay: 200ms; }
@keyframes pp-rise { from { opacity: 0; transform: translateY(10px); } to { opacity: 1; transform: none; } }

.pp-k { font-family: var(--font-display); font-weight: 700; font-size: clamp(11px, 0.78vw, 14px); letter-spacing: 0.14em; text-transform: uppercase; color: var(--ink-500); }
.pp-quiet { margin: 0; color: var(--ink-500); font-weight: 500; font-size: clamp(13px, 0.9vw, 16px); }
.pp-bio { margin: 0; max-width: 62ch; font-weight: 500; font-size: clamp(15px, 1.1vw, 21px); line-height: 1.42; text-wrap: pretty; }

.pp-vitals { display: grid; grid-template-columns: repeat(auto-fit, minmax(0, 1fr)); grid-auto-flow: column; border-top: 1px solid var(--line); border-bottom: 1px solid var(--line); }
.pp-vital { display: flex; flex-direction: column; gap: 5px; padding: clamp(9px, 1.4vh, 16px) clamp(10px, 1vw, 18px); min-width: 0; }
.pp-vital + .pp-vital { box-shadow: inset 1px 0 0 var(--line); }
.pp-vital:first-child { padding-left: 0; }
.pp-vital b { font-family: var(--font-display); font-weight: 700; font-size: clamp(17px, 1.3vw, 25px); line-height: 1.05; display: flex; align-items: center; gap: 7px; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.pp-vital small { font-size: clamp(12px, 0.8vw, 14px); font-weight: 500; color: var(--ink-500); line-height: 1.25; }
.pp-emoji { font-size: 1.05em; line-height: 1; }
.pp-form-row { display: flex; align-items: flex-end; gap: 10px; height: clamp(22px, 2.6vh, 30px); }
.pp-form { display: flex; align-items: flex-end; gap: 3px; height: 100%; }
.pp-form i { width: clamp(6px, 0.45vw, 9px); height: calc(var(--h) * 100%); background: rgba(16, 21, 31, 0.28); }
.pp-form i.is-last { background: var(--ink-900); }
.pp-form-row b { line-height: 0.9; }
.pp-avail i { width: 9px; height: 9px; border-radius: 50%; background: var(--pp-down); flex: none; }
.pp-avail.is-ok i { background: var(--pp-up); }
.pp-trust { display: inline-flex; gap: 3px; height: 8px; margin: 5px 0 2px; }
.pp-trust i { width: clamp(14px, 1.1vw, 20px); background: rgba(16, 21, 31, 0.13); }
.pp-trust i.is-on { background: var(--ink-900); }

.pp-rows { display: flex; flex-direction: column; }
.pp-row { display: grid; grid-template-columns: clamp(78px, 7vw, 124px) minmax(0, 1fr) auto; align-items: baseline; gap: 14px; padding: clamp(7px, 1.1vh, 12px) 0; }
.pp-row + .pp-row { border-top: 1px solid var(--line); }
.pp-v { font-weight: 600; font-size: clamp(14px, 1vw, 18px); min-width: 0; }
.pp-v b { font-family: var(--font-display); font-weight: 700; font-size: 1.25em; }
.pp-side { font-size: clamp(12px, 0.85vw, 15px); font-weight: 600; color: var(--ink-500); white-space: nowrap; }
.pp-delta[data-dir="up"] { color: var(--pp-up); }
.pp-delta[data-dir="down"] { color: var(--pp-down); }

.pp-numbers span { display: flex; flex-direction: column; }
.pp-season { display: flex; flex-direction: column; gap: 10px; }
.pp-season .pp-numbers { display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); gap: clamp(10px, 1.4vw, 28px); }
.pp-numbers span { flex-direction: column; gap: 4px; padding-top: 10px; border-top: 1px solid var(--line); }
.pp-numbers b { font-family: var(--font-display); font-weight: 700; font-size: clamp(34px, 3.2vw, 64px); line-height: 0.88; }
.pp-positions { display: inline-flex; flex-wrap: wrap; gap: 6px; }
.pp-pos-chip {
  display: inline-flex; align-items: center; height: 28px; padding: 0 10px; background: var(--paper-2);
  font-family: var(--font-display); font-weight: 700; font-size: clamp(14px, 1vw, 18px); letter-spacing: 0.08em; color: var(--ink-700);
}
.pp-pos-chip.is-own { background: var(--paper); color: var(--ink-900); box-shadow: inset 0 -2px 0 var(--ok), 0 1px 2px rgba(16, 24, 40, 0.1); }
.pp-numbers small { font-family: var(--font-display); font-weight: 600; font-size: clamp(11px, 0.75vw, 13px); letter-spacing: 0.12em; text-transform: uppercase; color: var(--ink-500); }
/* --- man-management --------------------------------------------------------------------------------------- */
.pp-block { display: flex; flex-direction: column; gap: clamp(8px, 1.2vh, 14px); min-width: 0; }
.pp-h { margin: 0; padding-bottom: 6px; border-bottom: 2px solid var(--ink-900); font-family: var(--font-display); font-weight: 700; font-size: clamp(12px, 0.85vw, 15px); letter-spacing: 0.16em; text-transform: uppercase; }
.pp-quote { margin: 0; position: relative; padding-left: 1.2em; font-weight: 500; font-size: clamp(15px, 1.08vw, 20px); line-height: 1.4; color: var(--ink-900); }
.pp-quote::before { content: "“"; position: absolute; left: -0.05em; top: -0.18em; font-family: var(--font-display); font-weight: 700; font-size: 2.3em; line-height: 1; color: var(--ink-300); }
/* A5 (ADR-069): his character, before the canon's quote */
.pp-char { display: grid; gap: 4px; margin: 0 0 12px; }
.pp-char b { justify-self: start; font: 700 clamp(11px, 0.78vw, 14px) var(--font-display); letter-spacing: 0.14em; text-transform: uppercase; color: var(--paper); background: var(--dark); padding: 3px 8px; }
.pp-char span { font: 500 clamp(14px, 1vw, 18px) / 1.35 var(--font-ui); color: var(--ink-900); }
.pp-char small { font: 500 clamp(12px, 0.85vw, 15px) var(--font-ui); color: var(--ink-500); }
.pp-traits { display: flex; flex-wrap: wrap; gap: 6px; }
.pp-trait { display: inline-flex; align-items: center; min-height: 32px; padding: 0 12px; background: var(--paper); box-shadow: 0 1px 2px rgba(16, 24, 40, 0.1); font-weight: 600; font-size: clamp(13px, 0.9vw, 16px); }
.pp-trait.is-hint { background: transparent; box-shadow: inset 0 0 0 1px var(--line-strong); color: var(--ink-700); font-weight: 500; }
.pp-trait.is-unknown { background: transparent; box-shadow: none; color: var(--ink-500); font-weight: 500; padding-left: 4px; }
.pp-split { display: grid; grid-template-columns: minmax(0, 0.8fr) minmax(0, 1.2fr); gap: clamp(16px, 1.8vw, 36px); align-items: start; }
.pp-split:has(> :only-child) { grid-template-columns: minmax(0, 1fr); }
.pp-split-even { grid-template-columns: minmax(0, 1fr) minmax(0, 1fr); }
.pp-stack { display: flex; flex-direction: column; gap: clamp(12px, 2vh, 22px); min-width: 0; }
@media (max-height: 820px) { .pp-story:nth-child(n + 3) { display: none; } .pp-rel:nth-child(n + 4) { display: none; } }
.pp-trust-big { display: flex; flex-direction: column; gap: 8px; }
.pp-trust-big .pp-trust { height: 12px; margin: 2px 0 0; }
.pp-trust-big .pp-trust i { width: clamp(22px, 2vw, 36px); }
.pp-trust-big b { font-family: var(--font-display); font-weight: 700; font-size: clamp(19px, 1.5vw, 28px); line-height: 1.05; }
.pp-camp { margin: 0; font-family: var(--font-display); font-weight: 700; font-size: clamp(14px, 1vw, 18px); letter-spacing: 0.06em; text-transform: uppercase; }
.pp-rels { list-style: none; margin: 0; padding: 0; display: flex; flex-direction: column; }
.pp-rel { display: grid; grid-template-columns: auto minmax(0, 1fr) auto; align-items: center; gap: 12px; padding: 7px 0; }
.pp-rel + .pp-rel { border-top: 1px solid var(--line); }
.pp-rel-text { display: flex; flex-direction: column; min-width: 0; }
.pp-rel-text b { font-weight: 600; font-size: clamp(14px, 0.95vw, 17px); }
.pp-rel-text small { font-size: clamp(12px, 0.82vw, 14px); color: var(--ink-500); line-height: 1.3; overflow: hidden; display: -webkit-box; -webkit-line-clamp: 2; -webkit-box-orient: vertical; }
.pp-rel-kind { display: inline-flex; align-items: center; gap: 6px; font-family: var(--font-display); font-weight: 700; font-size: clamp(11px, 0.78vw, 14px); letter-spacing: 0.1em; text-transform: uppercase; }
.pp-rel-kind::before { content: ""; width: 7px; height: 7px; border-radius: 50%; background: var(--ink-300); }
.pp-rel[data-tone="good"] .pp-rel-kind::before { background: var(--pp-up); }
.pp-rel[data-tone="bad"] .pp-rel-kind::before { background: var(--pp-down); }
.pp-mini { --sphere: clamp(28px, 2.2vw, 38px); }
.pp-stories { list-style: none; margin: 0; padding: 0; display: flex; flex-direction: column; }
.pp-story { display: grid; grid-template-columns: clamp(96px, 7.6vw, 140px) minmax(0, 1fr) auto; gap: 14px; padding: clamp(8px, 1.2vh, 13px) 0; align-items: start; }
.pp-story + .pp-story { border-top: 1px solid var(--line); }
.pp-story-meta { display: flex; flex-direction: column; gap: 2px; }
.pp-story-meta b { font-family: var(--font-display); font-weight: 700; font-size: clamp(12px, 0.85vw, 15px); letter-spacing: 0.1em; text-transform: uppercase; }
.pp-story-meta small { font-size: clamp(11px, 0.75vw, 13px); color: var(--ink-500); font-weight: 500; }
.pp-story-text { display: flex; flex-direction: column; gap: 3px; min-width: 0; }
.pp-story-q { font-size: clamp(12px, 0.82vw, 14px); color: var(--ink-500); font-weight: 500; overflow: hidden; display: -webkit-box; -webkit-line-clamp: 1; -webkit-box-orient: vertical; }
.pp-story-o { font-weight: 600; font-size: clamp(14px, 0.95vw, 17px); line-height: 1.35; }
.pp-story-o.is-waiting { color: var(--accent-ink); }
.pp-story-a { display: inline-flex; align-items: center; gap: 8px; white-space: nowrap; font-family: var(--font-display); font-weight: 600; font-size: clamp(12px, 0.82vw, 14px); letter-spacing: 0.06em; text-transform: uppercase; color: var(--ink-500); }
.pp-story-a i { width: 0; height: 0; border-left: 6px solid transparent; border-right: 6px solid transparent; }
.pp-story[data-valence="good"] .pp-story-a i { border-bottom: 9px solid var(--pp-up); }
.pp-story[data-valence="bad"] .pp-story-a i { border-top: 9px solid var(--pp-down); }
.pp-story[data-valence="mixed"] .pp-story-a i { width: 8px; height: 8px; border: 0; border-radius: 50%; background: var(--form-draw); }
.pp-story[data-valence="quiet"] .pp-story-meta b { color: var(--ink-500); }

/* --- career ----------------------------------------------------------------------------------------------- */
.pp-table { width: 100%; border-collapse: collapse; font-size: clamp(13px, 0.92vw, 17px); }
.pp-table th, .pp-table td { text-align: right; padding: clamp(6px, 1vh, 11px) 8px; }
.pp-table th:first-child, .pp-table td.pp-club-cell, .pp-table th:nth-child(2) { text-align: left; }
.pp-table thead th { font-family: var(--font-display); font-weight: 700; font-size: clamp(11px, 0.75vw, 13px); letter-spacing: 0.12em; text-transform: uppercase; color: var(--ink-500); padding-top: 0; }
.pp-table tbody tr { border-top: 1px solid var(--line); }
.pp-table tbody th { font-family: var(--font-display); font-weight: 700; letter-spacing: 0.04em; padding-left: 10px; }
.pp-table tbody tr.is-current { background: var(--paper); }
.pp-table tbody tr.is-current th { box-shadow: inset 3px 0 0 var(--ink-900); }
.pp-num-strong { font-family: var(--font-display); font-weight: 700; font-size: 1.2em; }
.pp-club-cell { display: flex; flex-wrap: wrap; gap: 4px 14px; }
.pp-club { display: inline-flex; align-items: center; gap: 8px; font-weight: 600; white-space: nowrap; }
.pp-club .crest { width: 18px; height: auto; flex: none; }
.pp-chart { width: 100%; height: auto; max-height: 22vh; overflow: visible; }
.pp-chart-base { stroke: var(--line-strong); stroke-width: 1; }
.pp-chart-area { fill: rgba(16, 21, 31, 0.07); }
.pp-chart-line { fill: none; stroke: var(--ink-900); stroke-width: 2; stroke-linejoin: round; }
.pp-chart-dot { fill: #fff; stroke: var(--ink-900); stroke-width: 1.6; }
.pp-chart-dot.is-last { fill: var(--ink-900); stroke: #fff; stroke-width: 2; }
.pp-chart-v { font-family: var(--font-display); font-weight: 700; font-size: 15px; fill: var(--ink-900); }
.pp-chart-x { font-family: var(--font-display); font-weight: 600; font-size: 10px; letter-spacing: 0.08em; fill: var(--ink-500); text-transform: uppercase; }
.pp-honours { list-style: none; margin: 0; padding: 0; display: flex; flex-direction: column; gap: 8px; }
.pp-honours li { display: grid; grid-template-columns: 24px auto auto 1fr; gap: 10px; align-items: center; }
.pp-honours svg { width: 22px; height: 22px; color: #b0852a; }
.pp-honours b { font-family: var(--font-display); font-weight: 700; letter-spacing: 0.06em; text-transform: uppercase; }
.pp-honours small { color: var(--ink-500); font-weight: 500; }

/* --- actions and sheets ------------------------------------------------------------------------------------- */
.pp-actions { grid-area: actions; display: flex; justify-content: flex-end; align-items: center; gap: 8px; flex-wrap: wrap; }
.pp-actions[hidden] { display: none; }
.pp-btn { min-height: 48px; padding: 0 clamp(16px, 1.4vw, 28px); font-size: clamp(14px, 0.95vw, 18px); box-shadow: var(--shadow-1); }
.pp-btn.is-ghost { background: var(--surface-strong); color: var(--ink-900); backdrop-filter: blur(var(--blur)); -webkit-backdrop-filter: blur(var(--blur)); }
.pp-btn.is-ghost:hover { background: var(--paper); }
.pp-btn:disabled { background: rgba(16, 21, 31, 0.5); color: rgba(255, 255, 255, 0.92); cursor: default; transform: none; }
.pp-btn.has-why { flex-direction: column; justify-content: center; gap: 1px; line-height: 1.05; }
.pp-btn.has-why small { font-family: var(--font-ui); font-weight: 500; font-size: 11.5px; letter-spacing: 0; text-transform: none; opacity: 0.9; }
.pp-listed { order: -2; display: flex; flex-direction: column; justify-content: center; min-height: 48px; padding: 0 16px; background: var(--paper); box-shadow: var(--shadow-1); font-family: var(--font-display); font-weight: 700; font-size: clamp(15px, 1vw, 19px); }
.pp-listed b { font-size: 0.72em; letter-spacing: 0.14em; text-transform: uppercase; color: var(--ink-500); }

.pp-sheet {
  position: absolute; left: 0; right: 0; bottom: 0; z-index: 5; max-height: 92%; display: flex; flex-direction: column;
  background: var(--paper); box-shadow: 0 -10px 30px rgba(16, 24, 40, 0.18), 0 -1px 0 var(--line);
}
.pp-sheet[hidden] { display: none; }
.pp-sheet-head { display: flex; align-items: flex-start; justify-content: space-between; gap: 16px; padding: clamp(14px, 2.2vh, 24px) clamp(18px, 1.9vw, 32px) 6px; }
.pp-sheet-head h2 { margin: 0; font-family: var(--font-display); font-weight: 700; font-size: clamp(22px, 1.8vw, 34px); letter-spacing: 0.03em; text-transform: uppercase; line-height: 1; }
.pp-sheet-head p { margin: 6px 0 0; font-weight: 500; font-size: clamp(13px, 0.95vw, 17px); color: var(--ink-500); }
.pp-sheet-head p b { color: var(--ink-900); font-family: var(--font-display); font-weight: 700; font-size: 1.15em; }
.pp-sheet-close { width: 44px; height: 44px; flex: none; background: var(--paper-2); }
.pp-sheet-body { overflow-y: auto; display: flex; flex-direction: column; gap: clamp(12px, 2vh, 22px); padding: clamp(10px, 1.6vh, 18px) clamp(18px, 1.9vw, 32px); }
.pp-sheet-foot { display: flex; justify-content: flex-end; padding: 12px clamp(18px, 1.9vw, 32px) clamp(14px, 2vh, 22px); border-top: 1px solid var(--line); }
.pp-sheet-foot .btn { min-height: 48px; min-width: 200px; justify-content: center; }
.pp-field { display: flex; flex-direction: column; gap: 8px; }
.pp-note { font-size: 13px; color: var(--ink-500); font-weight: 500; }
.pp-seg { display: flex; flex-wrap: wrap; gap: 4px; background: transparent; box-shadow: none; backdrop-filter: none; -webkit-backdrop-filter: none; }
.pp-seg .seg-btn {
  flex: 1 1 0; min-width: 88px; min-height: 48px; display: flex; flex-direction: column; align-items: center; justify-content: center; gap: 2px;
  padding: 6px 10px; background: var(--paper-2); color: var(--ink-500); box-shadow: inset 0 -3px 0 transparent;
  transition: background var(--t-micro), color var(--t-micro), box-shadow var(--t-fast);
}
.pp-seg .seg-btn small { font-family: var(--font-ui); font-weight: 500; font-size: 12px; letter-spacing: 0; text-transform: none; color: var(--ink-500); }
.pp-seg .seg-btn.is-on { background: var(--paper); color: var(--ink-900); box-shadow: inset 0 -3px 0 var(--accent), 0 4px 12px rgba(16, 24, 40, 0.12); }
.pp-seg .seg-btn:focus-visible { outline: 2px solid var(--accent); outline-offset: 2px; }
.pp-slider-row { display: flex; align-items: center; gap: 28px; }
.pp-slider-row .pp-slider { margin-right: 4px; }
.pp-slider { position: relative; flex: 1; height: 36px; cursor: pointer; touch-action: none; outline: none; }
.pp-slider-track { position: absolute; left: 0; right: 0; top: 50%; height: 6px; margin-top: -3px; background: rgba(16, 21, 31, 0.1); overflow: hidden; }
.pp-slider-shut { position: absolute; left: 0; top: 0; bottom: 0; width: calc(var(--shut, 0) * 100%); background: repeating-linear-gradient(135deg, rgba(16, 21, 31, 0.2) 0 3px, transparent 3px 6px); }
.pp-slider-ticks { position: absolute; left: 0; right: 0; top: 50%; pointer-events: none; }
.pp-slider-ticks i { position: absolute; top: 9px; font-style: normal; width: 1px; height: 6px; background: rgba(16, 21, 31, 0.3); }
.pp-slider-ticks b { position: absolute; top: 8px; left: 50%; transform: translateX(-50%); font-family: var(--font-display); font-weight: 600; font-size: 12px; color: var(--ink-500); }
.pp-slider:has(.pp-slider-ticks) { height: 48px; margin-bottom: 4px; }
.pp-slider-fill { position: absolute; left: 0; top: 0; bottom: 0; width: calc(var(--v) * 100%); background: linear-gradient(90deg, #5d93e6, var(--accent)); }
.pp-slider-thumb {
  position: absolute; top: 50%; left: calc(var(--v) * 100%); width: 24px; height: 24px; margin: -12px 0 0 -12px; border-radius: 50%;
  background: #fff; box-shadow: 0 0 0 2px var(--accent), 0 3px 8px rgba(16, 24, 40, 0.25); transition: transform var(--t-micro) var(--ease-out), box-shadow var(--t-micro);
}
.pp-slider:hover .pp-slider-thumb { transform: scale(1.12); }
.pp-slider:focus-visible .pp-slider-thumb, .pp-slider.is-dragging .pp-slider-thumb { transform: scale(1.2); box-shadow: 0 0 0 2px var(--accent), 0 0 0 8px var(--accent-soft), 0 3px 8px rgba(16, 24, 40, 0.25); }
.pp-slider-value { min-width: 7ch; white-space: nowrap; text-align: right; font-family: var(--font-display); font-weight: 700; font-size: clamp(22px, 1.8vw, 32px); }
.pp-answer { display: grid; grid-template-columns: auto 1fr; gap: 4px 12px; align-items: baseline; padding: 12px 14px; background: var(--paper-2); animation: pp-rise 380ms var(--ease-out); }
.pp-answer b { font-family: var(--font-display); font-weight: 700; font-size: clamp(17px, 1.3vw, 24px); text-transform: uppercase; letter-spacing: 0.04em; color: var(--pp-down); }
.pp-answer.is-signed b { color: var(--pp-up); }
.pp-answer span { font-weight: 600; font-size: clamp(14px, 1vw, 17px); }
.pp-error { margin: 0; font-weight: 600; color: var(--pp-down); font-size: 14px; }

/* --- the entrance ------------------------------------------------------------------------------------------- */
.pp.is-entering .pp-disc, .pp.is-entering .pp-ring, .pp.is-entering .pp-spoke { animation: pp-disc 760ms var(--ease-out) 120ms backwards; transform-origin: 0 0; }
.pp.is-entering .pp-rating { animation: pp-rise-big 620ms var(--ease-out) 260ms backwards; }
.pp.is-entering .pp-name { animation: pp-rise-big 680ms var(--ease-out) 380ms backwards; }
.pp.is-entering .pp-meta, .pp.is-entering .pp-standing { animation: pp-rise 560ms var(--ease-out) 520ms backwards; }
.pp.is-entering .pp-file { animation: pp-file 680ms var(--ease-out) 160ms backwards; }
.pp.is-entering .pp-actions, .pp.is-entering .pp-top { animation: pp-fade 520ms var(--ease-std) 460ms backwards; }
@keyframes pp-fade { from { opacity: 0; } to { opacity: 1; } }
@keyframes pp-disc { from { opacity: 0; transform: scale(0.72); } to { opacity: 1; transform: none; } }
@keyframes pp-rise-big { from { opacity: 0; transform: translateY(22px); } to { opacity: 1; transform: none; } }
@keyframes pp-file { from { opacity: 0; transform: translateX(34px); } to { opacity: 1; transform: none; } }

@media (prefers-reduced-motion: reduce) {
  .pp *, .pp { animation-duration: 1ms !important; animation-delay: 0ms !important; transition-duration: 1ms !important; }
}

/* --- big screens ---------------------------------------------------------------------------------------------- */
@media (min-width: 2200px) {
  .pp-count { font-size: 20px; min-width: 96px; }
  .pp-switch, .pp-arrow { height: 56px; }
  .pp-arrow { width: 56px; }
  .pp-top { min-height: 56px; }
  /* the file's type steps up with the screen (its clamps stop at 1920): one zoom keeps every proportion */
  .pp-tabs, .pp-panel, .pp-sheet-head, .pp-sheet-body, .pp-sheet-foot, .pp-actions { zoom: 1.3; }
}

/* --- phones, landscape (the user, B11) ------------------------------------------------------------------------ */
@media (max-height: 520px) {
  .pp { grid-template-columns: minmax(0, 37fr) minmax(0, 63fr); padding: 6px max(12px, env(safe-area-inset-right)) 8px max(12px, env(safe-area-inset-left)); row-gap: 6px; column-gap: 14px; }
  .pp-top { min-height: 40px; }
  .pp-top .back-btn { height: 40px; font-size: 14px; }
  .pp-switch { height: 40px; }
  .pp-arrow { width: 44px; }
  .pp-count { min-width: 56px; font-size: 13px; }
  .pp-stage { width: min(100%, 48vh); }
  .pp-role, .pp-crest { display: none; }
  .pp-idplate { padding: 5px 8px; margin-top: 5px; }
  .pp-ovr { font-size: 20cqw; }
  .pp-name { margin-top: 0; }
  .pp-last { font-size: calc(13cqw * var(--fit)); }
  .pp-first { font-size: 11px; letter-spacing: 0.2em; }
  .pp-meta { font-size: 11.5px; margin-top: 5px; }
  .pp-standing { font-size: 11px; margin-top: 3px; }
  .pp-tabs { height: 40px; }
  .pp-tab { font-size: 13px; letter-spacing: 0.06em; }
  .pp-panel { padding: 10px 14px 14px; gap: 10px; }
  .pp-bio { font-size: 13px; line-height: 1.35; display: -webkit-box; -webkit-line-clamp: 3; -webkit-box-orient: vertical; overflow: hidden; }
  .pp-k { font-size: 10px; }
  .pp-vital { padding: 6px 8px; gap: 3px; }
  .pp-vital b { font-size: 14px; }
  .pp-vital small { font-size: 10.5px; }
  .pp-form-row { height: 18px; }
  .pp-row { grid-template-columns: 66px minmax(0, 1fr) auto; padding: 5px 0; gap: 8px; }
  .pp-v { font-size: 12.5px; }
  .pp-side { font-size: 11px; }
  .pp-numbers b { font-size: 26px; }
  .pp-pos-chip { height: 24px; font-size: 13px; padding: 0 8px; }
  .pp-squad-role { font-size: 12px; padding: 3px 8px 2px; }
  .pp-numbers small { font-size: 9.5px; }
  .pp-h { font-size: 11px; padding-bottom: 4px; }
  .pp-quote, .pp-rel-text b, .pp-story-o { font-size: 12.5px; }
  .pp-trait { min-height: 26px; font-size: 12px; padding: 0 9px; }
  .pp-story { grid-template-columns: 78px minmax(0, 1fr) auto; gap: 8px; padding: 6px 0; }
  .pp-story-meta b, .pp-story-a { font-size: 10.5px; }
  .pp-story-meta small, .pp-story-q, .pp-rel-text small { font-size: 10.5px; }
  .pp-trust-big b { font-size: 16px; }
  .pp-table { font-size: 12px; }
  .pp-actions { gap: 6px; }
  .pp-btn { min-height: 44px; font-size: 13px; padding: 0 12px; }
  .pp-why { font-size: 11px; padding: 4px 8px; }
  .pp-listed { min-height: 44px; font-size: 13px; padding: 0 10px; }
  .pp-sheet { max-height: 100%; }
  .pp-sheet-head { padding: 10px 14px 2px; }
  .pp-sheet-head h2 { font-size: 20px; }
  .pp-sheet-head p { font-size: 12px; }
  .pp-sheet-body { padding: 8px 14px; gap: 10px; }
  .pp-sheet-foot { padding: 8px 14px; }
  .pp-sheet-foot .btn { min-width: 160px; min-height: 44px; }
  .pp-seg .seg-btn { min-height: 44px; min-width: 64px; font-size: 13px; }
  .pp-seg .seg-btn small { font-size: 10px; }
  .pp-slider-value { font-size: 20px; }
}

/* --- the lists that open a profile (Squad Hub, Youth Academy, the Squad card) ----------------------------------- */
.sh-row.is-player, .ac-row.is-player, .sq-item[data-player] { cursor: pointer; transition: background var(--t-micro); }
.sh-row.is-player:hover, .ac-row.is-player:hover, .sq-item[data-player]:hover { background: var(--paper); }
.sh-row.is-player:focus-visible, .ac-row.is-player:focus-visible { outline: 2px solid var(--accent); outline-offset: -2px; }
.sh-row.is-player:active, .ac-row.is-player:active { background: var(--paper-2); }

/* contrast (the user, round 2): big type stands on the stadium with a white lift; everything smaller sits on a plate */
.pp-ovr, .pp-pos, .pp-last { text-shadow: 0 2px 0 rgba(255, 255, 255, 0.6), 0 0 28px rgba(255, 255, 255, 0.75); }
.pp-first { color: var(--ink-900); text-shadow: 0 1px 0 rgba(255, 255, 255, 0.7), 0 0 16px rgba(255, 255, 255, 0.8); }
.pp-tags { display: flex; flex-wrap: wrap; align-items: center; gap: 6px; margin-top: 1.8cqw; }
.pp-tags .pp-squad-role { margin-top: 0; }
.pp-role {
  max-width: none; padding: 4px 10px 3px; background: var(--surface-strong); color: var(--ink-900); box-shadow: 0 1px 2px rgba(16, 24, 40, 0.12);
  font-weight: 600; font-size: clamp(12px, 2.2cqw, 17px); line-height: 1.25; white-space: nowrap;
}
.pp-idplate {
  align-self: flex-start; margin-top: 1.8cqw; padding: clamp(6px, 1.2cqw, 12px) clamp(10px, 1.8cqw, 16px); display: flex; flex-direction: column; gap: 4px;
  background: var(--surface); backdrop-filter: blur(var(--blur)); -webkit-backdrop-filter: blur(var(--blur)); box-shadow: var(--shadow-1);
}
.pp-idplate .pp-meta, .pp-idplate .pp-standing { margin: 0; color: var(--ink-900); }
.pp-idplate .pp-standing { color: var(--ink-700); }

/* --- A2: parting by mutual consent --------------------------------------------------------------------------------- */
.pp-release { display: grid; grid-template-columns: auto 1fr; align-items: baseline; gap: 4px 14px; margin: 0; padding: 14px 16px; background: var(--paper-2); }
.pp-release span { font-weight: 500; color: var(--ink-500); }
.pp-release b { font-family: var(--font-display); font-weight: 700; font-size: clamp(26px, 2.2vw, 40px); color: var(--ink-900); line-height: 0.9; }
.pp-release small { grid-column: 2; font-size: 13px; font-weight: 500; color: var(--ink-500); }
.pp-release-room { margin: 12px 0 6px; font-size: clamp(14px, 1vw, 17px); font-weight: 600; color: var(--ink-900); }
/* the phone keeps the size the user picked (22px beside a 60px overall) */
@media (max-height: 520px) { .pp-change { font-size: 22px; } }
