div.date-range {
    display: flex;
    align-items: center;
    justify-content: center;
    margin-bottom: 20px;
}

input#dateRange {
    text-align: center;
    font-weight: bold;
    color: inherit;
    padding: 10px 20px;
    border-radius: 5px;
    margin: 0 10px;
}

button {
    padding: 10px 20px;
    border: none;
    border-radius: 5px;
    background-color: #007bff;
    color: #fff;
    cursor: pointer;
    transition: background-color 0.3s;
}

button:hover {
    background-color: #0056b3;
}

button:disabled {
    background-color: #ccc;
    cursor: not-allowed;
}

.match-link-media {
  text-align: right;
}
.match-schedules,
.match-header,
.match-result {
    display: flex;
    align-items: center;
    justify-content: space-between;
    flex-wrap: wrap;
    padding: 5px;
}

.team-info {
    flex: 1;
    display: flex;
    align-items: center;
}

.team-info.home {
    justify-content: flex-end;
}

.team-info.away {
    justify-content: flex-start;
}

.team-info.score {
  display: flex;
  align-items: center;
  justify-content: center;
  flex: 0 1 100px;
  text-align: center;
}

.team-info.score-header {
    display: flex;
    align-items: center;
    justify-content: center;
    flex: 0 1 100px;
    text-align: center;
    font-size: 18px;
    font-weight: bold;
}

.team-info .team-name {
    margin: 0 10px;
}

.team-info .team-name-header {
    font-weight: 500;
    font-size: 24px;
    margin: 0 20px;
}

.team-info .team-logo {
    width: 22px;
    height: 22px;
    border-radius: 50%;
    object-fit: cover;
    object-position: center;
}

.team-info .team-logo-header {
    width: 40px;
    height: 40px;
    border-radius: 50% !important;
    object-fit: cover;
    object-position: center;
}

.input-score-form {
  display: flex;
  flex-direction: column;
  align-items: center;
  margin: 20px auto;
}


.score-input-row {
  display: flex;
  align-items: center;
  justify-content: space-between;
  margin-bottom: 10px;
  gap: 20px;
}

.team-score {
  display: flex;
  flex-direction: column;
  flex: 1;
}

.team-score label {
  font-weight: bold;
  margin-bottom: 5px;
  font-size: 14px;
}


.team-score input {
  width: 60px;
  padding: 6px 10px;
  font-size: 16px;
  border: 1px solid #ccc;
  border-radius: 6px;
  text-align: center;
}

.score-separator {
  font-size: 18px;
  font-weight: bold;
  margin: 0 10px;
}

.score-submit {
  margin-top: 10px;
}

.btn-score {
  padding: 8px 20px;
  background-color: #007bff;
  color: white;
  border: none;
  border-radius: 6px;
  font-weight: bold;
  cursor: pointer;
  transition: background-color 0.3s;
}

.btn-score:hover {
  background-color: #0056b3;
}



/* Responsive */
@media (max-width: 600px) {
    .team-info {
        justify-content: center;
    }

    .team-info.home {
        justify-content: flex-end;
        text-align: end;
    }

    .team-info.away {
        justify-content: flex-start;
    }

    .team-info.score {
        margin: 0 10px;
        flex: 0 1 auto;
    }

    /* Responsif untuk match-header */
    .match-header .team-info.home, .match-header .team-info.away {
        flex-direction: column;
        align-items: center;
    }

    .match-header .team-info.home .team-logo-header,
    .match-header .team-info.away .team-logo-header {
        order: 1;
        margin-bottom: 5px;
    }

    .match-header .team-info.home .team-name-header,
    .match-header .team-info.away .team-name-header {
        order: 2;
        text-align: center;
        margin: 0;
        font-size: 13px;
        font-weight: 500;
    }

    /* Responsif untuk match-schedules */
    .match-schedules .team-info.home, .match-schedules .team-info.away {
        flex-direction: row; /* Tetap menggunakan row di layar kecil */
        align-items: center;
    }

    .match-schedules .team-info.home {
        justify-content: flex-end; /* Tambahkan ini */
    }

    .match-schedules .team-info.away {
        justify-content: flex-start; /* Tambahkan ini */
    }

    .match-schedules .team-info .team-name {
        font-size: 13px;
        line-height: 1.2;
    }

}


/* ----------------------------Ini buat statistik head to head */
.team-stat-container {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 20px; /* Jarak antar elemen */
    padding: 10px;
    text-align: center;
}

/* Logo */
.team-logo {
    width: 40px;
    height: 40px;
    border-radius: 50%;
    object-fit: cover;
}

/* Statistik (Bagian Tengah) */
.team-stat-numbers {
    display: flex;
    gap: 30px; /* Jarak antar statistik */
}

.stat-item {
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 5px; /* Jarak antara badge dan label */
}

/* Badge untuk Angka */
.stat-badge {
    display: inline-block;
    padding: 6px 25px;
    border-radius: 20px; /* Membuat seperti badge */
    font-size: 16px;
    font-weight: bold;
    color: #fff;
    text-align: center;
    min-width: 40px; /* Ukuran minimal agar seragam */
}

.stat-win {
    background-color: #ced4da; /* Hijau untuk Win */
    color: #000;
}

.stat-draw {
    background-color: #ced4da; /* Kuning untuk Draw */
    color: #000; /* Teks gelap agar kontras */
}

.stat-loss {
    background-color: #ced4da; /* Merah untuk Loss */
    color: #000;
}

.stat-label {
    font-size: 14px;

}

/* Responsif */
@media (max-width: 600px) {
    .team-stat-container {
        flex-wrap: nowrap; /* Tetap satu baris */
    }

    .team-stat-numbers {
        gap: 15px; /* Kurangi jarak antar statistik */
    }

    .stat-badge {
        font-size: 14px; /* Perkecil ukuran badge */
        padding: 6px 10px;
    }

    .stat-label {
        font-size: 10px; /* Perkecil label */
    }
}


/* ----------------------------------------------------------- Grid Input Score*/
.match-score-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(320px, 1fr));
  gap: 20px;
}

.match-score-desc {
  display: flex;
  justify-content: center;
  align-items: center;
  text-align: center;
  text-transform: uppercase;
      font-weight: 500;
      color: #8392a5;
}

.match-score-header {
  display: grid;
  grid-template-columns: 1fr auto 1fr; /* Home | Time | Away */
  align-items: center;
  gap: 5px;
  padding: 10px 0;
}

.match-score-team {
  display: flex;
  align-items: center;
  min-width: 0;
  flex: 1;
  overflow: hidden;
}

.match-score-home {
  display: flex;
  flex-direction: row;      /* logo kiri, nama kanan */
  justify-content: flex-start;
  align-items: center;
  gap: 8px;
  min-width: 0;
}

.match-score-away {
  display: flex;
  flex-direction: row-reverse;     /* nama kiri, logo kanan */
  justify-content: flex-start;     /* tetap ke kiri dalam grid cell, tapi karena dir-reverse jadi kanan visual */
  align-items: center;
  gap: 8px;
  min-width: 0;
  text-align: right;
}

.match-score-logo {
  width: 28px;
  height: 28px;
  border-radius: 50%;
  object-fit: cover;
  flex-shrink: 0;
  /*border: 1px solid #ccc;*/
}

.match-score-team-name {
  font-weight: 500;
  font-size: 14px;
  overflow: hidden;
  white-space: nowrap;
  text-overflow: ellipsis;
  display: inline-block;
  max-width: 100%;
}

.match-score-time {
  text-align: center;
  font-weight: bold;
  font-size: 13px;
  width: 80px;
  flex-shrink: 0;
}

.match-score-stat {
  display: flex;
  flex-direction: column;
  gap: 4px;
}

.match-score-stat-row {
  display: grid;
  grid-template-columns: 1fr auto 1fr auto; /* Home Nick | KDA | Away Nick | KDA */
  gap: 6px;
  align-items: center;
}

.match-score-stat-team {
  display: flex;
  align-items: center;
  gap: 6px;
  min-width: 0;
}

.match-score-stat-home {
  justify-content: flex-start;
}

.match-score-stat-away {
  justify-content: flex-end;
  text-align: right;
  flex-direction: row-reverse;
}

.match-score-stat-logo {
  width: 22px;
  height: 22px;
  object-fit: cover;
  border-radius: 50%;
  flex-shrink: 0;
}

.match-score-stat-name {
  font-weight: 500;
  font-size: 13px;
  overflow: hidden;
  white-space: nowrap;
  text-overflow: ellipsis;
  display: inline-block;
  max-width: 100%;
}

.match-score-stat-value-home,
.match-score-stat-value-away {
  font-size: 12px;
  color: #6c757d;
  white-space: nowrap;
};


.match-score-inputs {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 10px;
  margin-top: 10px;
}

.match-score-inputs input {
  width: 60px;
  text-align: center;
  padding: 6px;
  border-radius: 6px;
  border: 1px solid #ccc;
}

.match-score-submit {
  margin-top: 10px;
  text-align: center;
}

.match-score-submit button {
  background-color: #007bff;
  color: #fff;
  border: none;
  padding: 6px 14px;
  border-radius: 6px;
  cursor: pointer;
}

.match-score-submit button:hover {
  background-color: #0056b3;
}

.match-score-status {
  display: block;
  margin-top: 5px;
  font-size: 13px;
}

.match-score-search {
  margin-bottom: 20px;
  text-align: right;
}

.match-score-search input {
  padding: 8px 12px;
  width: 100%;
  max-width: 300px;
  border: 1px solid #ccc;
  border-radius: 6px;
}




/* ---------------------------------------------------KDA Score input */
.kda-score-inputs {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 20px;
  margin-top: 10px;
}

.kda-score-inputs input {
  margin-top: 4px;
  padding: 5px;
  border-radius: 6px;
  border: 1px solid #ccc;
  width: 100%;
}
.team-kda label {
  display: block;
  width: 100%;
}

.team-kda.home label {
  text-align: left;
}

.team-kda.away label {
  text-align: right;
}


/*----*/
.kda-grid {
  display: flex;
  flex-direction: column;
  gap: 16px;
}

.kda-row {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 12px;
  align-items: center;
}

.kda-side {
  display: flex;
  flex-direction: column;
  align-items: flex-start;
  gap: 6px;
}

.kda-side.away {
  align-items: flex-end;
}

.kda-info {
  display: flex;
  align-items: center;
  gap: 6px;
}

.kda-info img {
  width: 32px;
  height: 32px;
  border-radius: 50%;
  object-fit: cover;
}

.kda-name {
  font-size: 0.8rem;
  font-weight: 500;
  overflow: hidden;
  white-space: nowrap;
  text-overflow: ellipsis;
  display: inline-block;
  max-width: 100%;
}

.kda-inputs {
  display: flex;
  gap: 6px;
}

.kda-inputs input {
  width: 44px;
  padding: 4px 5px;
  font-size: 0.8rem;
  text-align: center;
  border: 1px solid #ccc;
  border-radius: 4px;
}

/* ✅ Responsive fix */
@media (max-width: 576px) {
  .kda-grid{
    flex-direction: row;
  }
  .kda-row {
    grid-template-columns: 1fr;
    gap: 16px;
  }

  .kda-side.away {
    align-items: flex-start;
  }

  .kda-info {
    flex-direction: row;
  }
}
