:root {
  --btv-red: #ce0205;
  --btv-dark: #373737;
  --btv-black: #0a0a0c;
  --btv-line: rgba(255, 255, 255, 0.22);
  --btv-muted: #c8c8c8;
  --gold: #f2c94c;
  --silver: #d8dde4;
  --bronze: #c97834;
}

* {
  box-sizing: border-box;
}

html {
  background: var(--btv-black);
  color: #fff;
  font-family: "Bebas Neue", "Arial Narrow", Impact, Arial, sans-serif;
}

body {
  margin: 0;
  min-height: 100vh;
  background: #0a0a0c;
}

.topbar {
  display: grid;
  grid-template-columns: minmax(0, 1fr) minmax(160px, 270px);
  align-items: center;
  gap: 24px;
  padding: 24px clamp(18px, 4vw, 64px);
  border-bottom: 4px solid var(--btv-red);
  background: linear-gradient(90deg, #050505, #171717 58%, #2a0506);
}

.home-title {
  display: inline-block;
  width: fit-content;
  color: inherit;
  text-decoration: none;
}

.home-title:hover h1,
.home-title:focus-visible h1 {
  color: #fff;
  text-shadow: 0 0 12px rgba(206, 2, 5, 0.7);
}

.home-title:focus-visible {
  outline: 2px solid #fff;
  outline-offset: 6px;
}

.kicker,
.section-head p,
.meta,
.footer,
.top-credit {
  margin: 0;
  font-family: Arial, sans-serif;
  letter-spacing: 0;
}

.kicker {
  color: var(--btv-muted);
  font-size: 15px;
  text-transform: uppercase;
}

h1,
h2,
h3,
p {
  margin: 0;
}

h1 {
  font-size: clamp(52px, 10vw, 112px);
  line-height: 0.95;
  text-transform: uppercase;
}

.top-credit {
  margin-top: 8px;
  color: rgba(255, 255, 255, 0.72);
  font-size: 15px;
}

h2 {
  font-size: clamp(34px, 5vw, 58px);
  text-transform: uppercase;
}

.btv-title-mark {
  color: var(--btv-red);
  text-shadow: 0 0 10px rgba(206, 2, 5, 0.55);
}

.meta {
  justify-self: end;
  color: #fff;
  font-size: 14px;
  text-align: right;
}

main {
  width: min(1320px, calc(100% - 32px));
  margin: 0 auto;
  padding: 28px 0 40px;
}

.section + .section {
  margin-top: 34px;
}

.section-head {
  display: flex;
  align-items: end;
  justify-content: space-between;
  gap: 18px;
  margin-bottom: 16px;
  border-bottom: 1px solid var(--btv-line);
  padding-bottom: 10px;
}

.section-head p {
  color: var(--btv-muted);
  font-size: 14px;
  text-align: right;
}

.section-seo-intro {
  border: 1px solid var(--btv-line);
  border-left: 6px solid var(--btv-red);
  border-radius: 8px;
  background: #101012;
  padding: 18px clamp(16px, 3vw, 28px);
}

.section-seo-intro h2 {
  font-size: clamp(32px, 5vw, 56px);
}

.section-seo-intro p {
  max-width: 900px;
  color: var(--btv-muted);
  font-family: Arial, sans-serif;
  font-size: 16px;
  letter-spacing: 0;
  line-height: 1.45;
}

.section-seo-intro h2 + p {
  margin-top: 8px;
}

.seo-share-callout {
  margin-top: 10px !important;
  color: #fff !important;
  font-weight: 700;
}

.seo-eyebrow {
  margin-bottom: 6px;
  color: #fff !important;
  font-size: 13px !important;
  font-weight: 700;
  text-transform: uppercase;
}

.season-progress {
  max-width: 720px;
  margin-top: 16px;
  font-family: Arial, sans-serif;
  letter-spacing: 0;
}

.season-progress-top {
  display: flex;
  align-items: baseline;
  justify-content: space-between;
  gap: 14px;
  margin-bottom: 8px;
}

.season-progress strong {
  color: #fff;
  font-size: 16px;
  font-weight: 800;
}

.season-progress span {
  color: var(--btv-muted);
  font-size: 13px;
  font-weight: 700;
}

.season-progress-bar {
  height: 12px;
  overflow: hidden;
  border: 1px solid rgba(255, 255, 255, 0.24);
  border-radius: 999px;
  background: rgba(255, 255, 255, 0.08);
}

.season-progress-bar span {
  display: block;
  width: var(--season-progress, 0%);
  height: 100%;
  border-radius: inherit;
  background: linear-gradient(90deg, var(--btv-red), #ff3030);
}

.season-progress p {
  margin-top: 7px;
  font-size: 13px;
}

.podium-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(min(100%, 330px), 1fr));
  gap: 12px;
}

.podium-card {
  min-height: 168px;
  border: 1px solid var(--btv-line);
  border-radius: 8px;
  background: #111;
  padding: 18px;
}

.podium-photo-wrap {
  margin: -18px -18px 16px;
  overflow: hidden;
  border-radius: 8px 8px 0 0;
  background: #050505;
  aspect-ratio: 16 / 9;
}

.podium-photo {
  display: block;
  width: 100%;
  height: 100%;
  object-fit: cover;
  object-position: center 20%;
}

.podium-card.rank-1 {
  border-color: var(--gold);
}

.podium-card.rank-2 {
  border-color: var(--silver);
}

.podium-card.rank-3 {
  border-color: var(--bronze);
}

.podium-rank {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 46px;
  height: 46px;
  border-radius: 50%;
  background: var(--btv-red);
  font-size: 30px;
}

.podium-name {
  margin-top: 18px;
  font-size: clamp(28px, 4vw, 46px);
  line-height: 1;
}

.podium-points {
  margin-top: 10px;
  color: var(--btv-muted);
  font-family: Arial, sans-serif;
  font-size: 16px;
}

.podium-detail {
  margin-top: 16px;
  overflow: hidden;
  border: 1px solid rgba(255, 255, 255, 0.18);
  border-radius: 6px;
  font-family: Arial, sans-serif;
}

.podium-detail-row {
  display: grid;
  grid-template-columns: 64px minmax(0, 1.4fr) 44px 42px 40px;
  min-height: 34px;
  align-items: center;
  border-top: 1px solid rgba(255, 255, 255, 0.12);
  color: #fff;
  font-size: 12px;
}

.podium-detail-row:first-child {
  border-top: 0;
}

.podium-detail-row span {
  min-width: 0;
  overflow: hidden;
  padding: 5px 6px;
  text-align: center;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.podium-detail-row span:nth-child(2) {
  text-align: left;
}

.national-cell {
  display: flex;
  align-items: center;
  gap: 6px;
}

.national-cell strong {
  min-width: 0;
  overflow: hidden;
  font: inherit;
  text-overflow: ellipsis;
}

.podium-detail-row.is-btv-direct .national-cell {
  background: var(--btv-red);
  color: #fff;
  font-weight: 700;
}

.direct-btv-badge {
  flex: 0 0 auto;
  border: 1px solid rgba(255, 255, 255, 0.72);
  border-radius: 4px;
  padding: 2px 4px;
  color: #fff;
  font-size: 10px;
  font-style: normal;
  line-height: 1;
}

.podium-detail-head {
  min-height: 32px;
  background: var(--btv-red);
  font-weight: 700;
  text-transform: uppercase;
}

.directs-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(min(100%, 260px), 1fr));
  gap: 12px;
}

.direct-card {
  min-height: 126px;
  border: 1px solid var(--btv-line);
  border-left: 6px solid var(--btv-red);
  border-radius: 8px;
  background: #101012;
  padding: 14px;
}

.direct-card-top {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 8px;
  margin-bottom: 12px;
}

.direct-period,
.direct-replay {
  color: var(--btv-muted);
  font-family: Arial, sans-serif;
  font-size: 13px;
  letter-spacing: 0;
}

.direct-pill {
  flex: 0 0 auto;
  border-radius: 5px;
  background: var(--btv-red);
  color: #fff;
  font-family: Arial, sans-serif;
  font-size: 11px;
  font-weight: 700;
  letter-spacing: 0;
  padding: 5px 7px;
  text-transform: uppercase;
}

.direct-card h3 {
  overflow: hidden;
  font-size: clamp(26px, 3vw, 36px);
  line-height: 1;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.direct-replay {
  margin-top: 10px;
}

.direct-replay a {
  color: #fff;
  font-weight: 700;
}

.direct-card.replay-available {
  border-color: rgba(255, 255, 255, 0.42);
  border-left-color: #fff;
}

.direct-card.replay-scheduled {
  border-left-color: #f2c94c;
}

.direct-card.replay-uploading {
  border-left-color: #2f80ed;
}

.direct-card.replay-none {
  border-left-color: #6d6d6d;
}

.counted-events {
  margin-top: 16px;
  border-top: 1px solid var(--btv-line);
  padding-top: 12px;
}

.counted-events p {
  margin-bottom: 8px;
  color: var(--btv-muted);
  font-family: Arial, sans-serif;
  font-size: 13px;
  letter-spacing: 0;
}

.counted-events ul {
  display: flex;
  flex-wrap: wrap;
  gap: 6px;
  margin: 0;
  padding: 0;
  list-style: none;
}

.counted-events li {
  display: inline-flex;
  align-items: baseline;
  gap: 6px;
  border: 1px solid rgba(255, 255, 255, 0.18);
  border-left: 3px solid var(--btv-red);
  border-radius: 4px;
  background: rgba(255, 255, 255, 0.035);
  padding: 5px 7px;
  color: #fff;
  font-family: Arial, sans-serif;
  font-size: 11px;
  font-weight: 700;
  letter-spacing: 0;
  text-transform: uppercase;
}

.counted-event-period {
  color: var(--btv-muted);
  font-size: 10px;
  font-weight: 400;
  text-transform: none;
}

.ranking-table {
  border: 1px solid var(--btv-line);
  border-radius: 8px;
  overflow: hidden;
}

.ranking-row {
  display: grid;
  grid-template-columns: 86px minmax(0, 1fr) 110px 210px;
  min-height: 52px;
  align-items: center;
  border-top: 1px solid rgba(255, 255, 255, 0.12);
  background: #0f0f10;
}

.ranking-row:first-child {
  border-top: 0;
}

.ranking-row.header {
  min-height: 48px;
  background: var(--btv-red);
  color: #fff;
  font-size: 25px;
  text-transform: uppercase;
}

.ranking-row > div {
  padding: 9px 14px;
}

.rank,
.points,
.move {
  text-align: center;
}

.rank {
  font-size: 28px;
}

.player {
  overflow: hidden;
  font-size: clamp(23px, 3vw, 34px);
  line-height: 1;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.points {
  font-size: 30px;
}

.move {
  font-family: Arial, sans-serif;
  font-size: 14px;
  font-weight: 700;
}

.move.hausse {
  color: #fff;
}

.move.baisse {
  color: #ff2c2c;
}

.move.entreeTop,
.move.nouveau {
  color: #fff;
}

.move-badge {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-width: 68px;
  min-height: 30px;
  border-radius: 6px;
  background: var(--btv-red);
  padding: 4px 8px;
  width: 100%;
  white-space: nowrap;
}

.move-badge-compact {
  display: none;
}

.ranking-actions {
  display: flex;
  justify-content: center;
  margin-top: 18px;
}

.section-more-actions {
  margin-top: 22px;
}

.share-before-following {
  margin-top: 28px;
}

.share-after-following {
  margin-top: 28px;
}

.share-intro {
  max-width: 780px;
  margin: -6px 0 12px;
  color: var(--btv-muted);
  font-family: Arial, sans-serif;
  font-size: 15px;
  font-weight: 700;
  letter-spacing: 0;
  line-height: 1.35;
}

.primary-action {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-height: 44px;
  border: 0;
  border-radius: 6px;
  background: var(--btv-red);
  color: #fff;
  cursor: pointer;
  font: inherit;
  font-size: 24px;
  line-height: 1;
  padding: 10px 22px;
  text-align: center;
  text-decoration: none;
  text-transform: uppercase;
}

.primary-action:hover,
.primary-action:focus-visible {
  background: #f00b10;
  outline: 2px solid #fff;
  outline-offset: 3px;
}

.share-block button:disabled {
  cursor: not-allowed;
  opacity: 0.42;
}

.share-block button:disabled:hover,
.share-block button:disabled:focus-visible {
  outline: 0;
}

.share-block .primary-action:disabled:hover {
  background: var(--btv-red);
}

.share-panel {
  display: grid;
  grid-template-columns: minmax(0, 1fr) auto;
  gap: 10px;
  align-items: start;
}

.share-input-wrap {
  position: relative;
  min-width: 0;
}

.share-panel input {
  width: 100%;
  min-width: 0;
  min-height: 44px;
  border: 1px solid var(--btv-line);
  border-radius: 6px;
  background: #101012;
  color: #fff;
  font-family: Arial, sans-serif;
  font-size: 17px;
  padding: 10px 48px 10px 12px;
}

.share-panel input:focus {
  border-color: var(--btv-red);
  outline: 2px solid rgba(206, 2, 5, 0.35);
}

.share-clear {
  position: absolute;
  top: 5px;
  right: 5px;
  display: inline-flex;
  width: 34px;
  height: 34px;
  align-items: center;
  justify-content: center;
  border: 1px solid rgba(255, 255, 255, 0.22);
  border-radius: 5px;
  background: #18181a;
  color: #fff;
  cursor: pointer;
  font-family: Arial, sans-serif;
  font-size: 22px;
  line-height: 1;
}

.share-clear[hidden],
.share-suggestions[hidden] {
  display: none;
}

.share-suggestions {
  display: grid;
  gap: 6px;
  max-height: 282px;
  overflow-y: auto;
  margin-top: 8px;
  border: 1px solid var(--btv-line);
  border-radius: 6px;
  background: #0d0d0f;
  padding: 6px;
}

.share-suggestion {
  display: grid;
  grid-template-columns: minmax(0, 1fr) auto;
  gap: 10px;
  align-items: center;
  min-height: 44px;
  border: 1px solid rgba(255, 255, 255, 0.12);
  border-radius: 5px;
  background: #141416;
  color: #fff;
  cursor: pointer;
  font-family: Arial, sans-serif;
  letter-spacing: 0;
  padding: 9px 10px;
  text-align: left;
}

.share-suggestion:hover,
.share-suggestion:focus-visible {
  border-color: #fff;
  outline: 2px solid rgba(255, 255, 255, 0.22);
  outline-offset: 1px;
}

.share-suggestion-name {
  min-width: 0;
  overflow: hidden;
  font-size: 15px;
  font-weight: 800;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.share-suggestion-meta {
  color: var(--btv-muted);
  font-size: 12px;
  font-weight: 700;
}

.share-actions {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: 8px;
  margin-top: 10px;
}

.share-action {
  min-height: 40px;
  border: 1px solid var(--btv-line);
  border-radius: 6px;
  background: #101012;
  color: #fff;
  cursor: pointer;
  font-family: Arial, sans-serif;
  font-size: 13px;
  font-weight: 700;
  letter-spacing: 0;
  padding: 8px 10px;
}

.share-action:hover,
.share-action:focus-visible {
  border-color: #fff;
  outline: 2px solid rgba(255, 255, 255, 0.26);
  outline-offset: 2px;
}

.share-action:disabled:hover,
.share-action:disabled:focus-visible {
  border-color: var(--btv-line);
}

.share-action.facebook {
  border-color: #1877f2;
}

.share-action.instagram {
  border-color: #e1306c;
}

.share-action.tiktok {
  border-color: #25f4ee;
}

.share-action.download {
  border-color: var(--btv-red);
}

.share-status {
  min-height: 20px;
  margin-top: 10px;
  color: var(--btv-muted);
  font-family: Arial, sans-serif;
  font-size: 14px;
  letter-spacing: 0;
}

.sr-only {
  position: absolute;
  width: 1px;
  height: 1px;
  overflow: hidden;
  clip: rect(0, 0, 0, 0);
  white-space: nowrap;
}

.footer {
  display: flex;
  justify-content: space-between;
  gap: 24px;
  padding: 18px clamp(18px, 4vw, 64px) 28px;
  color: var(--btv-muted);
  border-top: 1px solid rgba(255, 255, 255, 0.12);
  font-size: 13px;
}

@media (max-width: 780px) {
  .topbar {
    grid-template-columns: 1fr;
  }

  .meta {
    justify-self: start;
    text-align: left;
  }

  .section-head {
    display: block;
  }

  .section-head p {
    margin-top: 6px;
    text-align: left;
  }

  .ranking-row {
    grid-template-columns: 58px minmax(0, 1fr) 62px 116px;
  }

  .ranking-row > div {
    padding: 8px;
  }

  .ranking-row.header {
    font-size: 19px;
  }

  .rank,
  .points {
    font-size: 22px;
  }

  .player {
    font-size: 22px;
  }

  .move {
    font-size: 10px;
  }

  .ranking-actions {
    justify-content: stretch;
  }

  .primary-action {
    width: 100%;
    font-size: 21px;
  }

  .share-panel {
    grid-template-columns: 1fr;
  }

  .share-actions {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }
}

@media (max-width: 780px) {
  .move.entreeTop {
    display: flex;
    justify-content: center;
  }

  .move-badge-entry {
    width: 64px;
    min-width: 64px;
    min-height: 34px;
    padding: 4px 6px;
    line-height: 1.05;
  }

  .move-badge-wide {
    display: none;
  }

  .move-badge-compact {
    display: block;
  }
}
