/****************************************************************************************************/
/* competitions Table
/****************************************************************************************************/
.competitions-table {
  width: 100%;
  background: #ffffff;
  table-layout: fixed;
  border-collapse: collapse;
  font-size: clamp(0.75rem, 2vw, 1.125rem);
  color: #111827; /* gray-900 */
}

/* Override default table cell alignment */
.competitions-table td {
  text-align: left;          /* baseline */
  vertical-align: middle;
  padding: 0.5rem;
  white-space: nowrap;
}

/* Center column override */
.competitions-table .competitions-cell--center {
  text-align: center !important;   /* ensures override */
}

/* Left and right alignment */
.competitions-table .competitions-cell--left {
  text-align: right !important;
  position: relative;
}

.competitions-table .competitions-cell--right {
  text-align: left !important;
}

/* Score block */
.competitions-table .competitions-score {
  display: flex;
  align-items: center;
  justify-content: center;   /* CRITICAL */
  gap: 0.5rem;
  line-height: 1;
}

.competitions-table .competitions-score-separator {
  width: 0.25rem;
  height: 1.2em;
  background-color: #facc15; /* yellow-400 */
  border-radius: 2px;
  display: inline-block;
}

/* Accent bar */
.competitions-table .competitions-accent {
  position: absolute;
  left: 0;
  top: 0;
  bottom: 0;
  width: 0.25rem;
  background-color: #d1d5db; /* gray-300 */
}

.competitions-table .competitions-accent--win {
  background-color: #34d399; /* emerald-400 */
}

/* Row behaviour */
.competitions-table .competitions-row {
  border-top: 1px solid #e5e7eb;
  border-bottom: 1px solid #e5e7eb;
  transition: background-color 0.15s ease;
}

.competitions-table .competitions-row:hover {
  background-color: #f9fafb;
}

.competitions-table .competitions-row--clickable {
  cursor: pointer;
}

.competitions-table .competitions-row--clickable:active {
  background-color: #f3f4f6;
}

.competitions-table .competitions-row--clickable:focus-visible {
  outline: 2px solid #059669;
  outline-offset: 2px;
}

/* Spacer row */
.competitions-table .competitions-spacer {
  height: 0.5rem;
  background-color: #f9fafb;
}


/****************************************************************************************************/
/* Tables */
/****************************************************************************************************/
.competitionplayers {
  background-color: #ffffff; /* bg-white */
  min-width: 100%;           /* min-w-full */
  table-layout: fixed;       /* table-fixed */
  border-collapse: collapse;
}

/* =========================
   Table header
========================= */
.competitionplayers thead tr {
  color: #111827;            /* text-gray-900 */
  background-color: #f3f4f6; /* bg-gray-100 */
  border-bottom: 1px solid #d1d5db; /* border-gray-300 */
  text-transform: uppercase;
  letter-spacing: 0.05em;    /* tracking-wider */
  font-size: 0.875rem;       /* text-sm */
}

.competitionplayers th {
  vertical-align: middle;    /* align-middle */
  font-weight: 600;          /* font-semibold */
}

.competitionplayers th.text-left {
  text-align: left;
}

.competitionplayers th.text-center {
  text-align: center;
}

.competitionplayers th.py-3 {
  padding-top: 0.75rem;
  padding-bottom: 0.75rem;
}

.competitionplayers th.px-4 {
  padding-left: 1rem;
  padding-right: 1rem;
}

/* =========================
   Table body
========================= */
.competitionplayers tbody {
  color: #111827;            /* text-gray-900 */
  line-height: 1.25;         /* leading-tight */
}

.competitionplayers tbody tr {
  border-bottom: 1px solid #e5e7eb; /* border-gray-200 */
  position: relative;
  cursor: default;
  transition: background-color 150ms ease;
}

.competitionplayers tbody tr:hover {
  background-color: #f9fafb; /* hover:bg-gray-50 */
}

/* Champion hover */
.competitionplayers tbody tr.hover-emerald:hover {
  background-color: #ecfdf5; /* hover:bg-emerald-50 */
}

/* Relegation hover */
.competitionplayers tbody tr.hover-red:hover {
  background-color: #fef2f2; /* hover:bg-red-50 */
}

/* =========================
   Table cells
========================= */
.competitionplayers td {
  vertical-align: middle; /* align-middle */
}

.competitionplayers td.py-3 {
  padding-top: 0.75rem;
  padding-bottom: 0.75rem;
}

.competitionplayers td.pl-2 {
  padding-left: 0.5rem;
}

.competitionplayers td.pr-1 {
  padding-right: 0.25rem;
}

.competitionplayers td.text-left {
  text-align: left;
}

.competitionplayers td.text-center {
  text-align: center;
}

.competitionplayers td.font-semibold {
  font-weight: 600;
}

/* =========================
   Rank column
========================= */
.competitionplayers td.w-8 {
  width: 2rem;
  position: relative;
  z-index: 1;
}

/* =========================
   Left indicator bar
========================= */
.competitionplayers td span {
  position: absolute;
  left: 0;
  top: 0;
  bottom: 0;
  width: 0.25rem; /* w-1 */
  z-index: 0;
}

.competitionplayers .bg-emerald {
  background-color: #059669; /* emerald-600 */
}

.competitionplayers .bg-gray {
  background-color: #d1d5db; /* gray-300 */
}

.competitionplayers .bg-red {
  background-color: #f87171; /* red-400 */
}

/* =========================
   Text truncation
========================= */
.competitionplayers .whitespace-nowrap {
  white-space: nowrap;
}

.competitionplayers .overflow-hidden {
  overflow: hidden;
}

.competitionplayers .text-ellipsis {
  text-overflow: ellipsis;
}

.competitionplayers .max-w-48 {
  max-width: 12rem;
}

/* Accent bar */
.competitionplayers .competitionplayers-accent {
  position: absolute;
  left: 0;
  top: 0;
  bottom: 0;
  width: 0.25rem;
  background-color: #d1d5db;
}

