/* /teams/ (templates/teams-index.php). Desktop TeamsIndexDesktop.dc.html, phone TeamsIndexPhone.dc.html. */
.cd-teams-index [hidden] { display: none !important; }

.cd-tidx-hero { display: grid; grid-template-columns: repeat(12, minmax(0, 1fr)); column-gap: 24px; padding-top: 72px; align-items: end; }
.cd-tidx-h1 { grid-column: span 7; }
.cd-tidx-tools { grid-column: span 5; display: flex; flex-direction: column; gap: 14px; }
.cd-tidx-search { background: var(--cd-raised); padding: 4px 4px 4px 22px; min-height: 52px; }
.cd-tidx-search input { font-size: 17px; min-height: 44px; }
.cd-tidx-search__go { min-height: 44px; padding: 10px 20px; }
.cd-js .cd-tidx-search__go { display: none; }
.cd-tidx-jump { display: flex; flex-wrap: wrap; gap: 10px; font-size: 14px; }
.cd .cd-tidx-jump a { display: inline-flex; align-items: center; min-height: 44px; color: var(--cd-text); border: var(--cd-line) solid var(--cd-border); border-radius: 999px; padding: 0 16px; }
.cd .cd-tidx-jump a:hover { border-color: var(--cd-accent); color: var(--cd-accent); }
.cd-tidx-short { display: none; }
.cd-tidx-none { padding-top: 48px; font-size: 17px; color: var(--cd-text-2); }

.cd-tidx-confs { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); column-gap: 24px; row-gap: 72px; padding-top: var(--cd-section); }
.cd-tidx-conf { display: flex; flex-direction: column; gap: 28px; scroll-margin-top: 16px; min-width: 0; }
.cd-tidx-div { display: flex; flex-direction: column; }
.cd-tidx-divhead { display: flex; justify-content: space-between; padding-bottom: 10px; font-size: 13px; font-weight: 700; letter-spacing: 1.5px; text-transform: uppercase; color: var(--cd-muted); }
.cd-tidx-list { list-style: none; padding: 0; }
.cd-tidx-row { display: flex; align-items: center; gap: 16px; padding: 12px 0; border-top: 1px solid var(--cd-hair); color: var(--cd-text) !important; }
.cd-tidx-row .cd-icon { color: var(--cd-muted); }
.cd-tidx-row:hover .cd-tidx-name, .cd-tidx-row:hover .cd-icon { color: var(--cd-accent); }
.cd-tidx-logo { background: #FFFFFF; border-radius: 12px; width: 64px; height: 64px; flex-shrink: 0; display: flex; align-items: center; justify-content: center; overflow: hidden; }
.cd .cd-tidx-logo__img { width: 80%; height: 80%; object-fit: contain; }
.cd-tidx-name { flex-grow: 1; font-size: 18px; font-weight: 700; line-height: 1.3; min-width: 0; }
.cd-tidx-count { font-size: 14px; color: var(--cd-muted); white-space: nowrap; }

.cd-tidx-beyond { display: flex; flex-direction: column; gap: 28px; scroll-margin-top: 16px; }
.cd-tidx-cards { list-style: none; padding: 0; display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); gap: 20px; }
.cd-tidx-cards--3 { grid-template-columns: repeat(3, minmax(0, 1fr)); }
.cd-tidx-cards--2, .cd-tidx-cards--1 { grid-template-columns: repeat(2, minmax(0, 1fr)); }
.cd-tidx-cards > li { display: flex; }
.cd-tidx-card { display: flex; flex-direction: column; width: 100%; background: var(--cd-raised); border: var(--cd-line) solid var(--cd-hair); border-radius: var(--cd-radius); overflow: hidden; color: var(--cd-text) !important; }
.cd-tidx-card:hover { border-color: var(--cd-border-hover); }
.cd-tidx-card > .cd-icon { display: none; }
.cd-tidx-card__logo { background: #FFFFFF; height: 170px; display: flex; align-items: center; justify-content: center; }
.cd .cd-tidx-card__img { width: 70%; height: 76%; object-fit: contain; }
.cd-tidx-card__text { display: flex; align-items: baseline; justify-content: space-between; gap: 12px; padding: 20px 22px 24px; }
.cd-tidx-card__name { font-family: var(--cd-display); font-size: 32px; line-height: 1; text-transform: uppercase; }
.cd-tidx-card:hover .cd-tidx-card__name { color: var(--cd-accent); }
.cd-tidx-card__count { font-size: 14px; color: var(--cd-muted); flex-shrink: 0; }

@media (max-width: 1099px) {
  .cd-tidx-hero { padding-top: 48px; row-gap: 24px; }
  .cd-tidx-h1, .cd-tidx-tools { grid-column: 1 / -1; }
  .cd-tidx-tools { max-width: 640px; }
  .cd-tidx-confs { grid-template-columns: minmax(0, 1fr); }
  .cd-tidx-cards, .cd-tidx-cards--3 { grid-template-columns: repeat(2, minmax(0, 1fr)); }
}

@media (max-width: 767px) {
  .cd-tidx-hero { padding-top: 32px; row-gap: 18px; }
  .cd-tidx-search { padding-left: 18px; }
  .cd-tidx-search input { font-size: 16px; }
  .cd-tidx-jump { gap: 8px; flex-wrap: nowrap; }
  .cd .cd-tidx-jump a { padding: 0 14px; white-space: nowrap; }
  .cd-tidx-long { display: none; }
  .cd-tidx-short { display: inline; }
  .cd-tidx-confs { padding-top: 44px; row-gap: 44px; }
  .cd-tidx-logo { width: 48px; height: 48px; }
  .cd-tidx-name { font-size: 17px; }
  .cd-tidx-beyond { gap: 14px; padding-top: 44px; }
  .cd-tidx-cards, .cd-tidx-cards--3, .cd-tidx-cards--2, .cd-tidx-cards--1 { display: flex; flex-direction: column; gap: 0; }
  .cd-tidx-card { flex-direction: row; align-items: center; gap: 14px; background: none; border: 0; border-top: 1px solid var(--cd-hair); border-radius: 0; padding: 14px 0; overflow: visible; }
  .cd-tidx-card > .cd-icon { display: block; color: var(--cd-muted); }
  .cd-tidx-card__logo { width: 56px; height: 56px; border-radius: 12px; flex-shrink: 0; overflow: hidden; }
  .cd .cd-tidx-card__img { width: 80%; height: 80%; }
  .cd-tidx-card__text { flex-grow: 1; padding: 0; justify-content: flex-start; gap: 8px; }
  .cd-tidx-card__name { font-family: var(--cd-body); font-weight: 700; font-size: 17px; text-transform: none; line-height: 1.3; }
  .cd-tidx-card__count { font-size: 14px; }
  .cd-tidx-card__count::before { content: "· "; }
}

/* Panels (design B2, Zack 2026-10-18; shared rules in base.css). Each conference and Beyond the NBA is a panel; the
   division headings lost their player counts with the corner text. */
.cd-tidx-confs { row-gap: 24px; padding-top: 48px; }
.cd .cd-tidx-confs > .cd-panel { margin-top: 0; }
@media (max-width: 767px) { .cd-tidx-confs { row-gap: 16px; padding-top: 24px; } .cd .cd-tidx-beyond.cd-panel { margin-top: 16px; } }
/* A long name (INTERNATIONAL) and its count no longer fit on one line in the narrower panel, so on tablet and desktop the
   count always sits under the name. The panel's flex gap already spaces the ruled heading from what follows. */
@media (min-width: 768px) { .cd .cd-panel .cd-tidx-card__text { flex-direction: column; align-items: flex-start; gap: 6px; } }
.cd .cd-panel.cd-tidx-conf > .cd-h2, .cd .cd-panel.cd-tidx-beyond > .cd-h2 { margin-bottom: 0; }
