/* ============================================================
   Team roster page — spotlight slideshow + Topps-style cards
   Team colors arrive as CSS vars: --tc1 (primary), --tc2 (secondary)
   ============================================================ */

.team-hero {
  position: relative;
  min-height: 62vh;
  display: flex;
  align-items: flex-end;
  color: var(--white);
  overflow: hidden;
  isolation: isolate;
  background: linear-gradient(150deg, var(--tc2) 0%, color-mix(in srgb, var(--tc2) 60%, var(--tc1)) 70%, var(--tc1) 130%);
}
.team-hero__photo {
  position: absolute; inset: 0; z-index: -1;
  opacity: 0.38;
}
.team-hero__photo img { width: 100%; height: 100%; object-fit: cover; }
.team-hero__scrim {
  position: absolute; inset: 0; z-index: 0;
  background: linear-gradient(180deg, transparent 30%, color-mix(in srgb, var(--tc2) 85%, black) 100%);
}
.team-hero .container { position: relative; z-index: 1; padding: 6rem 0 3.5rem; }
.team-hero .kicker { color: var(--tc1); }
.team-hero h1 span { color: var(--tc1); }

/* ---------- Spotlight slideshow ---------- */
.spotlight {
  position: relative;
  background:
    radial-gradient(1000px 480px at 80% -10%, color-mix(in srgb, var(--tc1) 30%, transparent), transparent 65%),
    linear-gradient(135deg, #0B0B0D 0%, var(--tc2) 100%);
  color: var(--white);
  overflow: hidden;
  padding: 4.5rem 0;
}
.spotlight::after {
  content: "";
  position: absolute; inset: 0;
  background-image: repeating-linear-gradient(-55deg, rgba(255,255,255,0.03) 0 2px, transparent 2px 26px);
  pointer-events: none;
}
.spotlight__stage {
  position: relative;
  min-height: 420px;
}
.spot-slide {
  position: absolute; inset: 0;
  display: grid;
  grid-template-columns: 0.9fr 1.1fr;
  gap: 3rem;
  align-items: center;
  opacity: 0;
  transform: translateX(40px);
  transition: opacity 0.7s var(--ease), transform 0.7s var(--ease);
  pointer-events: none;
}
.spot-slide.active { opacity: 1; transform: none; pointer-events: auto; }
.spot-slide__photo {
  height: 400px;
  border-radius: var(--radius);
  overflow: hidden;
  box-shadow: var(--shadow-lg);
  border: 4px solid color-mix(in srgb, var(--tc1) 55%, transparent);
  background: color-mix(in srgb, var(--tc2) 60%, black);
  display: flex; align-items: center; justify-content: center;
}
.spot-slide__photo img {
  width: 100%; height: 100%; object-fit: cover;
  animation: kenburns 6s ease-out forwards;
}
@keyframes kenburns { from { transform: scale(1.12); } to { transform: scale(1); } }
.spot-slide__photo .silhouette {
  font-family: var(--font-display);
  font-weight: 800;
  font-size: 7rem;
  color: color-mix(in srgb, var(--tc1) 70%, white);
  opacity: 0.6;
}
.spot-num {
  font-family: var(--font-display);
  font-weight: 800;
  font-size: clamp(4rem, 9vw, 7.5rem);
  line-height: 0.9;
  color: var(--tc1);
  opacity: 0.9;
}
.spot-name {
  font-family: var(--font-display);
  font-weight: 800;
  text-transform: uppercase;
  font-size: clamp(2.2rem, 5vw, 3.6rem);
  line-height: 1;
  margin: 0.2em 0 0.3em;
}
.spot-meta {
  display: flex; flex-wrap: wrap; gap: 0.6rem;
  margin-bottom: 1.2rem;
}
.spotlight .dots {
  display: flex; gap: 0.5rem; justify-content: center; margin-top: 2rem;
  position: relative; z-index: 2;
}
.spotlight .dots button {
  width: 10px; height: 10px; border-radius: 50%;
  border: none; cursor: pointer;
  background: rgba(255,255,255,0.3);
  transition: background 0.2s, transform 0.2s;
}
.spotlight .dots button.active { background: var(--tc1); transform: scale(1.3); }
@media (max-width: 820px) {
  .spot-slide { grid-template-columns: 1fr; gap: 1.2rem; }
  .spot-slide__photo { height: 300px; }
  .spotlight__stage { min-height: 640px; }
}

/* ---------- Roster grid ---------- */
.roster-cards {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(200px, 1fr));
  gap: 1.4rem;
}
.mini-card {
  border-radius: 14px;
  overflow: hidden;
  background: var(--white);
  box-shadow: var(--shadow-sm);
  cursor: pointer;
  border: none;
  padding: 0;
  text-align: left;
  transition: transform 0.28s var(--ease), box-shadow 0.28s var(--ease);
  font-family: var(--font-body);
}
.mini-card:hover { transform: translateY(-6px) rotate(-0.5deg); box-shadow: var(--shadow-lg); }
.mini-card__photo {
  aspect-ratio: 1 / 1;
  background: linear-gradient(160deg, color-mix(in srgb, var(--tc1) 30%, white), color-mix(in srgb, var(--tc2) 12%, white));
  display: flex; align-items: center; justify-content: center;
  overflow: hidden;
  position: relative;
}
.mini-card__photo img { width: 100%; height: 100%; object-fit: cover; }
.mini-card__photo .num-ph {
  font-family: var(--font-display); font-weight: 800; font-size: 3.4rem;
  color: var(--tc2); opacity: 0.5;
}
.mini-card__bar {
  background: var(--tc2);
  color: var(--white);
  padding: 0.7rem 0.9rem;
  border-top: 4px solid var(--tc1);
}
.mini-card__bar strong {
  display: block;
  font-family: var(--font-display); font-weight: 700;
  text-transform: uppercase; letter-spacing: 0.05em;
  font-size: 1.02rem; line-height: 1.15;
}
.mini-card__bar span { font-size: 0.82rem; opacity: 0.8; }

/* ---------- Topps-style card modal ---------- */
.card-modal {
  position: fixed; inset: 0; z-index: 200;
  display: none;
  align-items: center; justify-content: center;
  background: rgba(8, 12, 10, 0.82);
  backdrop-filter: blur(6px);
  padding: 4vh 4vw;
}
.card-modal.open { display: flex; }
.tcard-wrap { perspective: 1400px; }
.tcard {
  width: min(360px, 86vw);
  aspect-ratio: 3 / 4.2;
  position: relative;
  transform-style: preserve-3d;
  transition: transform 0.7s cubic-bezier(0.3, 1.4, 0.4, 1);
  cursor: pointer;
  animation: cardIn 0.55s var(--ease);
}
@keyframes cardIn { from { transform: translateY(60px) rotateZ(-4deg); opacity: 0; } to { opacity: 1; } }
.tcard.flipped { transform: rotateY(180deg); }
.tcard__face {
  position: absolute; inset: 0;
  backface-visibility: hidden;
  border-radius: 18px;
  overflow: hidden;
  box-shadow: 0 24px 70px rgba(0,0,0,0.55);
  background: linear-gradient(160deg, var(--tc1), var(--tc2) 130%);
  padding: 12px;
}
.tcard__face--back { transform: rotateY(180deg); }
/* animated foil sheen */
.tcard__face::after {
  content: "";
  position: absolute; inset: 0;
  background: linear-gradient(115deg, transparent 30%, rgba(255,255,255,0.28) 46%, rgba(255,255,255,0.05) 54%, transparent 70%);
  background-size: 260% 260%;
  animation: sheen 3.4s ease-in-out infinite;
  pointer-events: none;
  mix-blend-mode: overlay;
}
@keyframes sheen { 0% { background-position: 120% 120%; } 55% { background-position: -30% -30%; } 100% { background-position: -30% -30%; } }
.tcard__inner {
  position: relative;
  height: 100%;
  border-radius: 10px;
  background: #FBFAF6;
  display: flex; flex-direction: column;
  overflow: hidden;
}
.tcard__photo {
  flex: 1;
  overflow: hidden;
  background: linear-gradient(170deg, color-mix(in srgb, var(--tc1) 35%, white), color-mix(in srgb, var(--tc2) 18%, white));
  display: flex; align-items: center; justify-content: center;
  position: relative;
}
.tcard__photo img { width: 100%; height: 100%; object-fit: cover; }
.tcard__photo .num-ph {
  font-family: var(--font-display); font-weight: 800; font-size: 7rem;
  color: var(--tc2); opacity: 0.4;
}
.tcard__team {
  position: absolute; top: 10px; left: 12px;
  font-family: var(--font-display); font-weight: 700;
  text-transform: uppercase; letter-spacing: 0.14em; font-size: 0.72rem;
  background: var(--tc2); color: var(--white);
  padding: 0.3rem 0.7rem; border-radius: 999px;
  box-shadow: var(--shadow-sm);
}
.tcard__numball {
  position: absolute; top: 8px; right: 10px;
  width: 52px; height: 52px; border-radius: 50%;
  background: var(--tc1); color: var(--tc2);
  font-family: var(--font-display); font-weight: 800; font-size: 1.5rem;
  display: flex; align-items: center; justify-content: center;
  border: 3px solid #FBFAF6;
  box-shadow: var(--shadow-sm);
}
.tcard__banner {
  background: var(--tc2);
  color: var(--white);
  padding: 0.85rem 1rem 0.9rem;
  border-top: 5px solid var(--tc1);
}
.tcard__banner strong {
  display: block;
  font-family: var(--font-display); font-weight: 800;
  text-transform: uppercase; letter-spacing: 0.04em;
  font-size: 1.5rem; line-height: 1;
}
.tcard__banner span {
  font-family: var(--font-display); font-weight: 600;
  text-transform: uppercase; letter-spacing: 0.16em;
  font-size: 0.78rem; color: color-mix(in srgb, var(--tc1) 80%, white);
}
/* back */
.tcard__backbody {
  flex: 1;
  padding: 1.1rem 1.2rem;
  display: flex; flex-direction: column;
}
.tcard__backbody h4 {
  font-family: var(--font-display); font-weight: 800;
  text-transform: uppercase; font-size: 1.3rem;
  color: var(--tc2); margin: 0 0 0.2rem;
}
.tcard__backbody .sub {
  font-family: var(--font-display); font-weight: 600;
  text-transform: uppercase; letter-spacing: 0.14em; font-size: 0.75rem;
  color: color-mix(in srgb, var(--tc2) 60%, gray);
  margin-bottom: 0.9rem;
}
.stat-table { width: 100%; border-collapse: collapse; font-size: 0.92rem; }
.stat-table td { padding: 0.45rem 0.2rem; border-bottom: 1px solid #E7E4DA; }
.stat-table td:first-child {
  font-family: var(--font-display); font-weight: 700;
  text-transform: uppercase; letter-spacing: 0.08em; font-size: 0.8rem;
  color: var(--tc2);
}
.stat-table td:last-child { text-align: right; font-weight: 600; }
.tcard__rookie {
  margin: auto 0; text-align: center;
  color: color-mix(in srgb, var(--tc2) 55%, gray);
  font-style: italic; font-size: 0.95rem;
}
.tcard__backfoot {
  margin-top: auto;
  font-family: var(--font-display); font-weight: 600;
  text-transform: uppercase; letter-spacing: 0.14em; font-size: 0.68rem;
  color: color-mix(in srgb, var(--tc2) 45%, gray);
  text-align: center; padding-top: 0.8rem;
}
.flip-hint {
  text-align: center; color: rgba(255,255,255,0.75);
  font-size: 0.9rem; margin-top: 1rem;
  font-family: var(--font-display); text-transform: uppercase; letter-spacing: 0.14em;
}
.card-modal__close {
  position: absolute; top: 20px; right: 26px;
  background: none; border: none; color: #fff;
  font-size: 2.2rem; cursor: pointer; line-height: 1;
}
@media (prefers-reduced-motion: reduce) {
  .tcard__face::after { animation: none; }
  .spot-slide__photo img { animation: none; }
}
