/* The games hub (/play): three cards (ALL-22 PRO, BOWL, SLUGGER), your sport first, then Your All-22 (with ALL-22
   PRO's regions) and Your franchise. Built on site.css (its tokens, buttons, chips, lower thirds); the stills and logos
   are pixel art, drawn at whole device pixels by hub.js where it can. Linked by its hash (tools/site/shell.mjs). */

.pl { display: flex; flex-direction: column; padding: 24px 32px 28px; }
.pl-top { display: flex; align-items: flex-end; gap: 24px; }
.pl-ttl { flex: 1; min-width: 0; }
.pl h1 { margin: 6px 0 0; font: 800 38px/1 var(--ds-rc); text-transform: uppercase; color: var(--ds-text); }
.pl-note { max-width: 470px; margin: 0; font-size: 14px; line-height: 1.5; color: var(--ds-muted); text-align: right; }
/* the music: a small, quiet icon button (on: the waves; off: a cross) */
.ds button.pl-music { flex: none; display: grid; place-items: center; width: 36px; height: 36px; margin: 0; padding: 0; border: 1px solid var(--ds-ghost); border-radius: var(--ds-r); background: transparent; color: var(--ds-muted); font: inherit; cursor: pointer; }
.ds button.pl-music:hover { color: var(--ds-text); border-color: var(--ds-hoverb); }
.pl-music .ds-i { width: 18px; height: 18px; }
.pl-music .pl-on { display: none; }
.pl-music[aria-pressed="true"] { color: var(--ds-gold); }
.pl-music[aria-pressed="true"] .pl-on { display: inline; }
.pl-music[aria-pressed="true"] .pl-off { display: none; }

/* the cards: football's two and baseball's one, the sport in play first */
.pl-games { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); column-gap: 32px; row-gap: 10px; margin-top: 20px; }
.pl-g .ds-i { width: 15px; height: 15px; }
.pl-g-fb { grid-column: span 2; order: 1; }
.pl-g-bb { order: 2; }
.pl-pro { order: 3; } .pl-bowl { order: 4; } .pl-slugger { order: 5; }
html.ds-bb .pl-g-bb { order: 1; }
html.ds-bb .pl-g-fb { order: 2; }
html.ds-bb .pl-slugger { order: 3; } html.ds-bb .pl-pro { order: 4; } html.ds-bb .pl-bowl { order: 5; }

.pl-card { position: relative; display: flex; flex-direction: column; min-width: 0; border: 1px solid var(--ds-line); border-radius: var(--ds-r-lg); background: var(--ds-panel); overflow: hidden; transition: border-color 0.15s, box-shadow 0.15s; }
.pl-card.is-sel { border-color: rgba(242, 194, 48, 0.6); box-shadow: 0 0 0 1px rgba(242, 194, 48, 0.45); }
.pl-win { position: relative; display: block; height: 240px; overflow: hidden; background: #05070a; border-bottom: 1px solid var(--ds-line); }
.pl-still { position: absolute; left: 0; top: 0; width: 100%; height: 100%; object-fit: cover; image-rendering: pixelated; }
.pl-still.snapped { object-fit: fill; }
.pl-bug { position: absolute; left: 12px; top: 12px; display: flex; align-items: center; gap: 6px; height: 24px; padding: 0 8px; border: 1px solid var(--ds-tagb); border-radius: 4px; background: rgba(9, 13, 17, 0.88); font: 800 11.5px/1 var(--ds-rc); letter-spacing: 0.07em; text-transform: uppercase; color: var(--ds-text); white-space: nowrap; }
.pl-bug i { display: inline-block; width: 6px; height: 6px; border-radius: 1px; background: var(--ds-gold); }
/* the logo stands on the picture's bottom edge */
.pl-logo { position: relative; z-index: 2; height: 0; margin: 0 0 0 16px; }
.pl-logo img { position: absolute; left: 0; bottom: -36px; height: auto; image-rendering: pixelated; filter: drop-shadow(0 6px 10px rgba(0, 0, 0, 0.55)); }
.pl-pro .pl-logo img { width: 196px; }
.pl-bowl .pl-logo img { width: 216px; }
.pl-slugger .pl-logo img { width: 248px; }
.pl-body { display: flex; flex: 1; flex-direction: column; padding: 50px 20px 18px; }
.pl-desc { margin: 0; font-size: 14px; line-height: 1.5; color: var(--ds-nav); text-wrap: pretty; }
.pl-chips { display: flex; flex-wrap: wrap; gap: 6px; margin: 12px 0 0; padding: 0; list-style: none; }
.pl-body .play { margin-top: auto; }
.pl-chips + .play { margin-top: 16px; }

/* Your All-22 and Your franchise */
.pl-yours { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 32px; margin-top: 24px; }
.pl-team { grid-column: span 2; min-width: 0; }
.pl-fr { min-width: 0; border-radius: 8px; }
.pl-yh { display: flex; align-items: center; gap: 12px; min-height: 30px; margin-bottom: 10px; }
.pl-yh .ds-sech { flex: 1; }
.pl-regions { display: flex; flex-wrap: wrap; justify-content: flex-end; gap: 4px; }
.ds .pl-regions button { height: 28px; margin: 0; padding: 0 8px; border: 1px solid var(--ds-ghost); border-radius: 4px; background: var(--ds-tag); color: var(--ds-muted); font: 800 11.5px/1 var(--ds-rc); letter-spacing: 0.05em; text-transform: uppercase; cursor: pointer; }
.ds .pl-regions button:hover { color: var(--ds-text); border-color: var(--ds-hoverb); }
.ds .pl-regions button[aria-pressed="true"] { background: var(--ds-text); border-color: var(--ds-text); color: var(--ds-bg); }
.ds .pl-regions .reg-all { border-color: rgba(242, 194, 48, 0.45); }
.pl-stars { display: flex; align-items: center; gap: 4px; margin: 0; padding: 0 8px 0 12px; list-style: none; }
.pl-stars .star { display: flex; flex-direction: column; align-items: center; gap: 2px; width: 54px; }
.pl-stars .star:nth-child(n + 7) { display: none; }
.pl-stars .star-pic { display: grid; place-items: center; width: 52px; height: 52px; }
.pl-stars .star-pic img { width: 52px; height: 52px; image-rendering: pixelated; }
.pl-stars .star-pos { padding: 1px 5px; border: 1px solid var(--ds-tagb); border-radius: 3px; background: var(--ds-tag); font: 800 10.5px/1.1 var(--ds-rc); color: var(--ds-gold); }
.pl-stars .star-pos.def { color: var(--ds-def); }
.pl-stars .star-nm { position: absolute; width: 1px; height: 1px; overflow: hidden; clip-path: inset(50%); white-space: nowrap; }
.pl-team .ds-l3t b { text-transform: uppercase; }
.pl-team .ds-l3t small b { color: var(--ds-text); font-weight: 700; }
.pl-fr .ds-l3t b { gap: 8px; }

@media (min-width: 1000px) and (max-width: 1279px) {
  .pl { padding-inline: 24px; }
  .pl-games, .pl-yours { column-gap: 20px; }
  .pl-yours { gap: 20px; }
  .pl-win { height: 200px; }
  .pl-pro .pl-logo img { width: 160px; }
  .pl-bowl .pl-logo img { width: 180px; }
  .pl-slugger .pl-logo img { width: 200px; }
  .pl-stars .star:nth-child(n + 5) { display: none; }
}

/* phones and tablets: the cards one under another, each a picture, its logo and its Play button */
@media (max-width: 999px) {
  .pl { padding: 14px 0 24px; }
  .pl-top { align-items: center; padding: 0 var(--ds-gutter); }
  .pl h1 { margin-top: 4px; font-size: 28px; }
  .pl-note { display: none; }
  .pl-games { grid-template-columns: minmax(0, 1fr); row-gap: 10px; margin-top: 12px; padding: 0 var(--ds-gutter); }
  .pl-g { margin-top: 6px; }
  .pl-g-fb { grid-column: auto; order: 1; } .pl-pro { order: 2; } .pl-bowl { order: 3; } .pl-g-bb { order: 4; } .pl-slugger { order: 5; }
  html.ds-bb .pl-g-bb { order: 1; } html.ds-bb .pl-slugger { order: 2; } html.ds-bb .pl-g-fb { order: 3; } html.ds-bb .pl-pro { order: 4; } html.ds-bb .pl-bowl { order: 5; }
  .pl-win { height: 104px; }
  .pl-bug { left: 10px; top: 10px; height: 22px; padding: 0 7px; font-size: 11px; letter-spacing: 0.06em; }
  .pl-logo { margin-left: 12px; }
  .pl-logo img { bottom: -42px; }
  .pl-pro .pl-logo img { width: 147px; }
  .pl-bowl .pl-logo img { width: 144px; }
  .pl-slugger .pl-logo img { width: 155px; }
  .pl-body { flex-direction: row; justify-content: flex-end; align-items: center; min-height: 58px; padding: 8px 12px; }
  .pl-desc, .pl-chips { display: none; }
  .pl-body .play { margin: 0; }
  .pl-yours { grid-template-columns: minmax(0, 1fr); gap: 20px; margin-top: 22px; padding: 0 var(--ds-gutter); }
  .pl-team { grid-column: auto; }
  .pl-yh { flex-wrap: wrap; }
  .pl-regions { justify-content: flex-start; }
  .pl-team .ds-l3 { flex-wrap: wrap; }
  .pl-team .ds-l3k { width: 100%; flex-direction: row; align-items: baseline; gap: 6px; padding: 7px 12px; }
  .pl-stars { width: 100%; justify-content: space-between; padding: 10px 12px 0; }
  .pl-stars .star { width: auto; flex: 1; }
  .pl-stars .star-pic, .pl-stars .star-pic img { width: 44px; height: 44px; }
  .pl-team .ds-l3t { flex: 1 1 100%; }
  .pl-team .ds-l3a { flex: 1 1 100%; padding: 0 12px 12px; }
  .pl-team .ds-l3a .ds-btn { width: 100%; }
  /* your franchise: the key across the top, as Your All-22's */
  .pl-fr .ds-l3 { flex-wrap: wrap; }
  .pl-fr .ds-l3k { width: 100%; flex-direction: row; align-items: baseline; gap: 6px; padding: 7px 12px; }
  .pl-fr .ds-l3t { flex: 1 1 100%; }
  .pl-fr .ds-l3a { flex: 1 1 100%; padding: 0 12px 12px; }
  .pl-fr .ds-l3a .ds-btn { width: 100%; }
}
@media (min-width: 600px) and (max-width: 999px) {
  .pl-top, .pl-games, .pl-yours { width: 100%; max-width: 640px; margin-left: auto; margin-right: auto; }
}
@media (prefers-reduced-motion: reduce) {
  .pl-card { transition: none; }
}
