/* ── בונה כדורגלן ─────────────────────────────────────────────────────────────
   Two screens with one shape between them: a grid of numbers you choose from,
   and a table of years you read afterwards. Both scroll inside themselves — the
   attribute table is seven columns wide and the page must never scroll sideways
   because of it. */

/* the role picker */
.pb-role-q { text-align: center; font-weight: 700; margin: 18px 0 10px; }
.pb-roles { display: grid; gap: 10px; max-width: 520px; margin: 0 auto 24px; }
.pb-role {
  display: block; width: 100%; text-align: right;
  background: var(--surface2); border: 1px solid var(--border);
  border-radius: var(--radius); padding: 12px 14px; cursor: pointer;
  color: var(--text); transition: background .15s, border-color .15s;
}
.pb-role:hover { background: var(--hover); border-color: var(--accent); }
.pb-role-name { display: block; font-weight: 700; font-size: 1.05rem; }
.pb-role-sub { display: block; color: var(--dim); font-size: .86rem; margin-top: 3px; }

/* the round header */
.pb-head {
  display: flex; align-items: center; gap: 10px; flex-wrap: wrap;
  justify-content: center; margin: 14px 0 12px;
}
.pb-round { color: var(--dim); font-size: .9rem; }
.pb-role-tag {
  background: var(--surface2); border: 1px solid var(--border);
  border-radius: 999px; padding: 2px 10px; font-size: .82rem; font-weight: 600;
}

/* the six slots, always on screen: the whole decision is which ones are left */
.pb-slots {
  display: grid; grid-template-columns: repeat(6, 1fr); gap: 6px;
  max-width: 640px; margin: 0 auto 16px;
}
.pb-slot {
  background: var(--surface2); border: 1px dashed var(--border);
  border-radius: var(--radius); padding: 7px 4px; text-align: center; min-width: 0;
}
.pb-slot.filled { border-style: solid; border-color: var(--accent); background: var(--panel); }
.pb-slot-name { display: block; font-size: .72rem; color: var(--dim); }
.pb-slot-val { display: block; font-weight: 800; font-size: 1.15rem; }
.pb-slot-from {
  display: block; font-size: .66rem; color: var(--dim);
  overflow: hidden; text-overflow: ellipsis; white-space: nowrap;
}

/* ── the reel ──────────────────────────────────────────────────────────────
   One name at a time. The blur and the lift are what sell it as a draw rather
   than a label being rewritten. */
.pb-reel {
  max-width: 420px; margin: 0 auto 14px; padding: 18px 14px;
  background: var(--panel); border: 2px solid var(--border);
  border-radius: var(--radius); text-align: center;
  transition: border-color .2s, box-shadow .2s;
}
.pb-reel.spinning { border-color: var(--accent2); }
.pb-reel:not(.spinning) {
  border-color: var(--accent);
  box-shadow: 0 0 0 3px color-mix(in srgb, var(--accent) 18%, transparent);
}
.pb-reel-face { min-height: 92px; display: flex; flex-direction: column;
  align-items: center; justify-content: center; gap: 2px; }
.pb-face-name { font-size: 1.5rem; font-weight: 800; line-height: 1.15; }
.pb-face-club { color: var(--dim); font-size: .88rem; }
.pb-face-ovr {
  margin-top: 4px; font-size: 1.5rem; font-weight: 800; color: var(--accent);
  font-variant-numeric: tabular-nums;
}
/* a spinning frame is deliberately hard to read — you are watching it pass */
.pb-blur { filter: blur(2.5px); opacity: .75; }
.pb-reel:not(.spinning) .pb-face-name { animation: pb-land .28s ease-out; }
@keyframes pb-land {
  from { transform: translateY(-10px) scale(.94); opacity: .3; }
  to   { transform: none; opacity: 1; }
}

/* the six things you may take off him */
.pb-picks {
  display: grid; grid-template-columns: repeat(3, 1fr); gap: 8px;
  max-width: 420px; margin: 0 auto 12px;
}
.pb-take {
  display: flex; flex-direction: column; align-items: center; gap: 2px;
  background: var(--surface2); border: 1px solid var(--border); color: var(--text);
  border-radius: var(--radius); padding: 9px 4px; cursor: pointer;
  transition: background .15s, border-color .15s;
}
.pb-take:hover:not(:disabled), .pb-take:focus:not(:disabled) {
  background: var(--hover); border-color: var(--accent); outline: none;
}
.pb-take-name { font-size: .76rem; color: var(--dim); }
.pb-take-val { font-size: 1.4rem; font-weight: 800; font-variant-numeric: tabular-nums; }
.pb-take.taken { opacity: .35; cursor: not-allowed; }
.pb-take-x { font-size: .64rem; color: var(--dim); }

.pb-actions { text-align: center; margin-bottom: 10px; min-height: 32px; }
.pb-reroll {
  background: var(--surface2); border: 1px solid var(--border); color: var(--text);
  border-radius: var(--radius); padding: 6px 12px; cursor: pointer; font-size: .85rem;
}
.pb-reroll:hover { border-color: var(--accent); }

.pb-foot { text-align: center; color: var(--dim); font-size: .86rem; min-height: 1.3em; }

.pb-tablewrap { overflow-x: auto; margin: 0 auto 12px; max-width: 760px; }
.pb-table { width: 100%; border-collapse: collapse; font-size: .9rem; }
.pb-table th, .pb-table td { padding: 5px 6px; text-align: center; }
.pb-table thead th {
  font-size: .76rem; color: var(--dim); font-weight: 600;
  border-bottom: 1px solid var(--border); white-space: nowrap;
}
.pb-table tbody tr { border-bottom: 1px solid var(--border); }

/* the verdict */
.pb-verdict { text-align: center; margin: 18px 0 10px; }
.pb-legacy { font-size: 3rem; font-weight: 800; line-height: 1; color: var(--accent); }
.pb-legacy-label { color: var(--dim); font-size: .85rem; }
.pb-peak { margin-top: 6px; font-weight: 600; }
.pb-totals {
  display: flex; flex-wrap: wrap; gap: 6px 14px; justify-content: center;
  margin: 0 auto 16px; max-width: 560px; font-size: .88rem; color: var(--dim);
}
.pb-totals span { white-space: nowrap; }

.pb-career td { font-variant-numeric: tabular-nums; }
.pb-career .pb-cl { text-align: right; white-space: nowrap; }
.pb-career .pb-hon { white-space: nowrap; letter-spacing: 1px; }
.pb-lost td { opacity: .55; }
.pb-abroad .pb-cl { font-style: italic; }

/* how he was built — the evidence, kept to the end so it reads as a receipt */
.pb-built { max-width: 560px; margin: 18px auto; }
.pb-built-h { font-weight: 700; margin-bottom: 8px; }
.pb-built-row {
  display: grid; grid-template-columns: auto 1fr; gap: 2px 10px;
  padding: 7px 0; border-bottom: 1px solid var(--border);
}
.pb-built-k { font-weight: 700; }
.pb-built-v { color: var(--dim); text-align: left; }
.pb-built-w { grid-column: 1 / -1; font-size: .78rem; color: var(--dim); }

.pb-again { text-align: center; margin: 20px 0 30px; }

@media (max-width: 560px) {
  .pb-slots { grid-template-columns: repeat(3, 1fr); }
  .pb-table { font-size: .82rem; }
  .pb-legacy { font-size: 2.4rem; }
  .pb-face-name { font-size: 1.3rem; }
}

/* The reel is the one animation here, and it is the whole point of the screen,
   so it degrades to an instant swap rather than disappearing. */
@media (prefers-reduced-motion: reduce) {
  .pb-blur { filter: none; }
  .pb-reel:not(.spinning) .pb-face-name { animation: none; }
}
