/* ===============================
   Boxscore Page Layout
   =============================== */

body.boxscore-page main{
  max-width: 1500px;
}
.boxscore-page h1{
  text-align: center;
}

.team-pill, .mid-pill { box-sizing: border-box; }

/* Scoreboard wrapper (label + bar) */
body.boxscore-page .scoreboard{
  display: flex;
  flex-direction: column;
  align-items: stretch;          /* IMPORTANT: don’t “center-squeeze” */
  width: min(1500px, 100%);
  padding: 0;                    /* allow full edge docking */
  margin: 32px 0 24px;
  box-sizing: border-box;
}

/* FINAL / PREVIEW label */
.result-label{
  text-align: center;
  margin-bottom: 12px;

  font-size: 24px;
  font-weight: 900;
  letter-spacing: 0.16em;
  text-transform: uppercase;
  color: #b8c0cc;
}

/* ===============================
   SCOREBAR (3 BLOCKS)
   Constant-width team pills
   =============================== */

body.boxscore-page .scorebar{
  display: grid;
  grid-template-columns: 1fr auto 1fr;  /* equal widths */
  align-items: center;
  gap: 32px;
  width: 100%;
}

/* Team pills (left/right) */
.team-pill{
  display: flex;
  align-items: center;
  gap: 18px;

  padding: 30px 42px;
  border-radius: 999px;
  font-weight: 950;
  box-shadow: 0 14px 36px rgba(0,0,0,0.6);

  width: 100%;
  min-width: 0;
  overflow: hidden; /* keeps content inside rounded pill */
}

/* Force pills to fill their grid column so outer edges dock */
.team-pill{
  justify-self: stretch;
}

.team-pill.left{  justify-content: flex-start; }
.team-pill.right{ justify-content: flex-end; }

.pill-logo{
  width: 124px;
  height: 124px;
  object-fit: contain;
  flex: 0 0 auto;
}

.pill-name{
  font-size: 28px;
  font-weight: 950;
  white-space: nowrap;

  overflow: hidden;
  text-overflow: ellipsis;
  min-width: 0;
}

/* Middle score tile */
.mid-pill{
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;

  padding: 30px 48px;
  min-width: 200px;

  border-radius: 22px; /* rounded rectangle */
  background: #0f1319;
  border: 2px solid #232a35;

  box-shadow: 0 14px 36px rgba(0,0,0,0.55);
}

.mid-score{
  font-size: 48px;
  font-weight: 1000;
  letter-spacing: 0.08em;
  white-space: nowrap;
}

/* ===============================
   Team pill SOG (under team name)
   Centered in the open space between logo and far edge
   =============================== */

.pill-text{
  flex: 1 1 auto;     /* KEY: fill remaining space in the pill */
  min-width: 0;       /* allow ellipsis */
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: 6px;
}

/* Name centered within the available space */
.pill-text .pill-name{
  width: 100%;
  margin: 0;
  text-align: center;

  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

/* SOG centered under the name */
.pill-sog{
  font-size: 24px;
  font-weight: 900;
  letter-spacing: 0.10em;
  text-transform: uppercase;
  opacity: 0.9;
  text-align: center;
}

/* ===============================
   Banner / Status Message
   =============================== */

.banner{
  margin: 10px 0 14px;
  padding: 10px 14px;
  border-radius: 12px;
  background: rgba(255,255,255,0.05);
  border: 1px solid #232a35;
  color: #e7e7e7;
  font-size: 14px;
}


/* ===============================
   Two Column Layout
   =============================== */

.two-col{
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 14px;
  margin-top: 14px;
}

@media (max-width: 980px){
  /* Stack on mobile */
  .two-col{ grid-template-columns: 1fr; }

  /* Scorebar stacks nicely too */
  .scorebar{
    grid-template-columns: 1fr;
    gap: 14px;
    width: 100%;
  }

  .team-pill.left,
  .team-pill.right{
    justify-content: center;
  }

  .mid-pill{
    width: 100%;
  }
}


/* ===============================
   Card Styles
   =============================== */

.card{
  background: #0f1319;
  border: 1px solid #232a35;
  border-radius: 14px;
  overflow: hidden;
}

.card-title{
  padding: 10px 14px;
  font-weight: 950;
  border-bottom: 1px solid #1b2028;
}

.card-body{
  padding: 10px 14px;
  font-size: 13px;
  color: #d7dde6;
}

.summary-record{
  font-size: 15px;
  font-weight: 800;
  margin-bottom: 8px;
}

/* ===============================
   Team-colored card title strip only
   =============================== */

/* Base card stays neutral */
.card{
  background: #0f1319;
  border: 1px solid #232a35;
  border-radius: 14px;
  overflow: hidden;
}

/* Subtle team-accented border (very light) */
.card[style]{
  border-color:
    color-mix(
      in srgb,
      var(--team-bg) 35%,
      #232a35
    );
}

/* Card title gets full team treatment */
.card[style] .card-title{
  background: var(--team-bg);
  color: var(--team-fg);
  font-weight: 950;
  border-bottom: none;
}

/* Body stays neutral and readable */
.card[style] .card-body{
  background: #0f1319;
  color: #d7dde6;
}

/* Tables stay neutral */
.card[style] .data-table th,
.card[style] .data-table td{
  color: inherit;
}


/* ===============================
   Subheadings
   =============================== */

.subhead{
  margin: 12px 14px 6px;
  font-size: 12px;
  color: #b8c0cc;
  letter-spacing: 0.06em;
  text-transform: uppercase;
}


/* ===============================
   Table Tweaks (Box Score)
   =============================== */

.data-table{
  width: 100%;
}

.data-table th,
.data-table td{
  padding: 6px 8px;
}

.data-table th{
  font-size: 12px;
  text-transform: uppercase;
}

.data-table td{
  font-size: 13px;
  white-space: nowrap;
}

.table-wrap{
  padding: 0 10px 10px;
}


/* ===============================
   Player Links
   =============================== */

.data-table a{
  color: inherit;
  text-decoration: none;
  font-weight: 700;
}

.data-table a:hover{
  text-decoration: underline;
}

.team-pill{
  --border-lighten: 32%;  
  --border-width: 3px;

  --pill-bg: var(--team-bg, #2a3340);

  border: var(--border-width) solid
    color-mix(
      in srgb,
      var(--pill-bg) calc(100% - var(--border-lighten)),
      white var(--border-lighten)
    );

  box-shadow:
    0 14px 36px rgba(0,0,0,0.55),
    inset 0 0 0 1px rgba(255,255,255,0.04);
}

/* Stars */
.data-table td .team-link{
  display: inline-flex;
  align-items: center;
  gap: 6px;
}

/* ===============================
   Game Stars (1st / 2nd / 3rd)
   =============================== */

.game-star{
  margin-left: 6px;
  font-size: 14px;
  line-height: 1;
  vertical-align: middle;
}

.star-gold{
  color: #f5c542;
}

.star-silver{
  color: #cfd6dd;
}

.star-bronze{
  color: #8b5a2b; 
}

/* ===============================
   Shot Map (Plotly)
   =============================== */

.shotmap-wrap{
  padding: 0 10px 10px;
}

.shotmap{
  width: 100%;
  height: 380px;              /* tweak later if you want taller */
  border-radius: 12px;
  border: 1px solid #232a35;
  background: #0b0f14;
  overflow: hidden;
}
.subhead.center {
  text-align: center;
}

.boxscore-title{
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 18px;
}

/* icon-only nav arrows */
.game-nav-btn{
  background: transparent;
  border: none;
  padding: 0;
  margin: 0;

  color: #e7e7e7;
  font-size: 22px;
  font-weight: 900;
  line-height: 1;
  cursor: pointer;

  opacity: 0.85;
  transform: translateY(-1px);
}

.game-nav-btn:hover{
  opacity: 1;
  filter: drop-shadow(0 6px 10px rgba(0,0,0,0.35));
}

.game-nav-btn.disabled{
  opacity: 0.25;
  cursor: default;
  pointer-events: none;
  filter: none;
}

