/* Shared league/team pickers + mobile filter dropdowns (Team Match, Standings) */

/* --- Mobile filter dropdowns (Liga + Team) --- */
.tm-mobile-filters {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 0.75rem;
  width: 100%;
  margin-bottom: 1rem;
}

@media (max-width: 479px) {
  .tm-mobile-filters {
    grid-template-columns: 1fr;
  }
}

.tm-mobile-filter-col {
  display: flex;
  flex-direction: column;
  gap: 0.3rem;
  min-width: 0;
  margin: 0;
}

.tm-mobile-filter-label {
  font-size: 0.6875rem;
  text-transform: uppercase;
  letter-spacing: 0.05em;
  color: rgba(255, 255, 255, 0.45);
  padding-left: 0.15rem;
}

.tm-filter {
  display: flex;
  align-items: center;
  gap: 0.55rem;
  min-width: 0;
  padding: 0.7rem 0.8rem;
  min-height: 2.75rem;
  border-radius: 0.75rem;
  border: 1px solid rgba(168, 85, 247, 0.35);
  background: linear-gradient(
    165deg,
    rgba(30, 27, 75, 0.55) 0%,
    rgba(0, 0, 0, 0.55) 100%
  );
  box-shadow: inset 0 1px 0 rgba(255, 255, 255, 0.05);
}

.tm-filter-ic {
  display: inline-flex;
  width: 1.4rem;
  height: 1.4rem;
  align-items: center;
  justify-content: center;
  border-radius: 0.4rem;
  background: rgba(168, 85, 247, 0.15);
  color: rgba(233, 213, 255, 0.95);
  flex-shrink: 0;
}

.tm-filter-select {
  flex: 1 1 auto;
  min-width: 0;
  max-width: 100%;
  width: 100%;
  appearance: none;
  -webkit-appearance: none;
  background: transparent;
  border: none;
  color: #fff;
  font-size: 0.8125rem;
  font-weight: 600;
  line-height: 1.25;
  padding: 0.15rem 1.4rem 0.15rem 0;
  cursor: pointer;
  background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='12' height='12' viewBox='0 0 24 24' fill='none' stroke='rgba(216%2C180%2C254%2C0.9)' stroke-width='2.2'%3E%3Cpath d='m6 9 6 6 6-6'/%3E%3C/svg%3E");
  background-repeat: no-repeat;
  background-position: right 0 center;
  background-size: 0.85rem;
}

.tm-filter-select:focus {
  outline: none;
}

.tm-filter-select option {
  background: #15102e;
  color: #fff;
  padding: 0.5rem;
  font-weight: 500;
}

.tm-filter-select option:checked {
  background: rgba(124, 58, 237, 0.35);
  color: #fff;
}

@media (min-width: 1024px) {
  .tm-mobile-filters {
    display: none;
  }
}

@media (max-width: 1023px) {
  .tm-league-sidebar {
    display: none !important;
  }
}

@media (min-width: 1024px) {
  .tm-league-sidebar {
    display: block;
  }
}

/* --- Sidebar Pilih Liga --- */
.league-picker-box {
  border-radius: 1rem;
  border: 1px solid rgba(168, 85, 247, 0.22);
  background: linear-gradient(
    165deg,
    rgba(15, 23, 42, 0.65) 0%,
    rgba(0, 0, 0, 0.45) 50%,
    rgba(30, 27, 75, 0.35) 100%
  );
  box-shadow:
    inset 0 1px 0 rgba(255, 255, 255, 0.06),
    0 0 0 1px rgba(0, 0, 0, 0.2),
    0 8px 40px rgba(124, 58, 237, 0.12);
  padding: 1rem 1.1rem 1.15rem;
  margin-bottom: 1rem;
}

@media (min-width: 768px) {
  .league-picker-box {
    padding: 1.2rem 1.25rem 1.35rem;
  }
}

.league-picker-box__title {
  margin: 0 0 0.75rem;
  padding-bottom: 0.65rem;
  border-bottom: 1px solid rgba(255, 255, 255, 0.1);
}

.league-side {
  display: flex;
  align-items: center;
  gap: 0.6rem;
  padding: 0.55rem 0.7rem;
  border-radius: 0.625rem;
  border: 1px solid rgba(255, 255, 255, 0.08);
  background: rgba(255, 255, 255, 0.02);
  color: rgba(255, 255, 255, 0.78);
  font-size: 0.8125rem;
  font-weight: 500;
  text-decoration: none;
  transition: background 0.15s ease, border-color 0.15s ease;
}

.league-side:hover {
  border-color: rgba(168, 85, 247, 0.4);
}

.league-side.is-active {
  color: #fff;
  border-color: rgba(168, 85, 247, 0.55);
  background: linear-gradient(
    135deg,
    rgba(124, 58, 237, 0.32),
    rgba(168, 85, 247, 0.12)
  );
  box-shadow: 0 0 14px rgba(124, 58, 237, 0.18);
}

.league-side__logo {
  width: 1.25rem;
  height: 1.25rem;
  border-radius: 0.375rem;
  object-fit: contain;
  background: rgba(255, 255, 255, 0.08);
  flex-shrink: 0;
}

.league-side__logo--ph {
  display: block;
  background: rgba(168, 85, 247, 0.15);
}

.league-side__name {
  min-width: 0;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}

/* --- Sidebar Pilih Team / Negara --- */
.team-picker-box {
  border-radius: 1rem;
  border: 1px solid rgba(168, 85, 247, 0.22);
  background: linear-gradient(
    165deg,
    rgba(15, 23, 42, 0.65) 0%,
    rgba(0, 0, 0, 0.45) 50%,
    rgba(30, 27, 75, 0.35) 100%
  );
  box-shadow:
    inset 0 1px 0 rgba(255, 255, 255, 0.06),
    0 0 0 1px rgba(0, 0, 0, 0.2),
    0 8px 40px rgba(124, 58, 237, 0.12);
  padding: 1rem 1.1rem 1.15rem;
}

@media (min-width: 768px) {
  .team-picker-box {
    padding: 1.2rem 1.25rem 1.35rem;
  }
}

.tm-search-field {
  display: flex;
  align-items: center;
  gap: 0.5rem;
  padding: 0.5rem 0.7rem;
  border-radius: 0.625rem;
  border: 1px solid rgba(255, 255, 255, 0.1);
  background: rgba(0, 0, 0, 0.35);
  margin-bottom: 0.75rem;
}

.tm-search-ic {
  color: rgba(216, 180, 254, 0.7);
  flex-shrink: 0;
}

.tm-search-input {
  flex: 1 1 auto;
  min-width: 0;
  background: transparent;
  border: none;
  outline: none;
  color: #fff;
  font-size: 0.8125rem;
}

.tm-search-input::placeholder {
  color: rgba(255, 255, 255, 0.4);
}

.tm-search-input::-webkit-search-cancel-button {
  -webkit-appearance: none;
}

.tm-team-list {
  list-style: none;
  margin: 0;
  padding: 0;
  display: flex;
  flex-direction: column;
  gap: 0.35rem;
  max-height: 22rem;
  overflow-y: auto;
  scrollbar-width: thin;
  scrollbar-color: rgba(168, 85, 247, 0.4) transparent;
}

.tm-team-list::-webkit-scrollbar {
  width: 4px;
}

.tm-team-list::-webkit-scrollbar-thumb {
  background: rgba(168, 85, 247, 0.4);
  border-radius: 4px;
}

.team-side {
  display: flex;
  align-items: center;
  gap: 0.6rem;
  padding: 0.5rem 0.65rem;
  border-radius: 0.625rem;
  border: 1px solid rgba(255, 255, 255, 0.08);
  background: rgba(255, 255, 255, 0.02);
  color: rgba(255, 255, 255, 0.78);
  font-size: 0.8125rem;
  font-weight: 500;
  text-decoration: none;
  transition: background 0.15s ease, border-color 0.15s ease;
}

.team-side:hover {
  border-color: rgba(168, 85, 247, 0.4);
}

.team-side.is-active {
  color: #fff;
  border-color: rgba(168, 85, 247, 0.55);
  background: linear-gradient(
    135deg,
    rgba(124, 58, 237, 0.32),
    rgba(168, 85, 247, 0.12)
  );
}

.team-side.is-hidden {
  display: none;
}

.tm-team-list li:has(.team-side.is-hidden) {
  display: none;
}

.team-side__logo {
  width: 1.5rem;
  height: 1.5rem;
  border-radius: 999px;
  object-fit: contain;
  background: rgba(255, 255, 255, 0.08);
  flex-shrink: 0;
}

.team-side__logo--ph {
  display: block;
  background: rgba(168, 85, 247, 0.12);
}

.team-side__name {
  min-width: 0;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}
