:root {
  --bg-dark: #0b0f19;
  --bg-sidebar: #0e1422;
  --bg-card: rgba(19, 27, 44, 0.75);
  --bg-card-hover: rgba(28, 40, 65, 0.9);
  --border-color: rgba(255, 255, 255, 0.08);
  --blue-team: #00d2ff;
  --blue-glow: rgba(0, 210, 255, 0.25);
  --red-team: #ff3366;
  --red-glow: rgba(255, 51, 102, 0.25);
  --accent-gold: #ffbe0b;
  --text-main: #f0f4f8;
  --text-muted: #8c9ba5;
  --success: #00f59b;
  --warning: #ffb703;
  --danger: #ef233c;
  --tier-s-plus: #ff0055;
  --tier-s: #ffbe0b;
  --tier-a: #00d2ff;
  --tier-b: #8c9ba5;
  --font-family: 'Outfit', -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, sans-serif;
}

* {
  box-sizing: border-box;
  margin: 0;
  padding: 0;
}

body {
  background-color: var(--bg-dark);
  background-image: 
    radial-gradient(circle at 10% 20%, rgba(0, 210, 255, 0.05) 0%, transparent 40%),
    radial-gradient(circle at 90% 20%, rgba(255, 51, 102, 0.05) 0%, transparent 40%),
    radial-gradient(circle at 50% 80%, rgba(255, 190, 11, 0.03) 0%, transparent 50%);
  color: var(--text-main);
  font-family: var(--font-family);
  min-height: 100vh;
  display: flex;
}

/* Sidebar Layout */
.app-sidebar {
  width: 260px;
  background: var(--bg-sidebar);
  border-right: 1px solid var(--border-color);
  display: flex;
  flex-direction: column;
  flex-shrink: 0;
  position: sticky;
  top: 0;
  height: 100vh;
  overflow-y: auto;
  z-index: 100;
}

.sidebar-header {
  padding: 1.25rem 1.5rem;
  display: flex;
  align-items: center;
  gap: 0.8rem;
  border-bottom: 1px solid var(--border-color);
}

.logo-circle {
  width: 36px;
  height: 36px;
  border-radius: 8px;
  background: linear-gradient(135deg, #00d2ff, #9b5de5, #ff3366);
  display: flex;
  align-items: center;
  justify-content: center;
  font-weight: 800;
  font-size: 1.2rem;
  color: #fff;
}

.sidebar-brand {
  font-size: 1.25rem;
  font-weight: 800;
  letter-spacing: 0.5px;
  background: linear-gradient(135deg, #fff, #c0d0e0);
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
}

.sidebar-menu {
  padding: 1.2rem 0.8rem;
  display: flex;
  flex-direction: column;
  gap: 1.5rem;
}

.menu-group-title {
  font-size: 0.72rem;
  font-weight: 700;
  color: #5a6a7a;
  text-transform: uppercase;
  letter-spacing: 1px;
  padding: 0 0.8rem 0.4rem;
}

.menu-items-list {
  display: flex;
  flex-direction: column;
  gap: 0.25rem;
}

.menu-item-btn {
  background: transparent;
  border: none;
  color: var(--text-muted);
  font-family: inherit;
  font-weight: 600;
  font-size: 0.9rem;
  padding: 0.65rem 0.9rem;
  border-radius: 8px;
  display: flex;
  align-items: center;
  gap: 0.8rem;
  cursor: pointer;
  transition: all 0.2s ease;
  text-align: left;
  width: 100%;
}

.menu-item-btn:hover {
  background: rgba(255, 255, 255, 0.05);
  color: var(--text-main);
}

.menu-item-btn.active {
  background: rgba(0, 210, 255, 0.12);
  color: var(--blue-team);
  font-weight: 700;
  border-left: 3px solid var(--blue-team);
}

.menu-item-btn .menu-dot {
  width: 7px;
  height: 7px;
  border-radius: 50%;
  background: #5a6a7a;
  transition: all 0.2s;
}

.menu-item-btn.active .menu-dot {
  background: var(--blue-team);
  box-shadow: 0 0 8px var(--blue-team);
}

/* App Main Content Area */
.app-content {
  flex: 1;
  display: flex;
  flex-direction: column;
  min-width: 0;
  overflow-y: auto;
  height: 100vh;
}

.top-bar {
  border-bottom: 1px solid var(--border-color);
  background: rgba(11, 15, 25, 0.85);
  backdrop-filter: blur(12px);
  padding: 0.85rem 2rem;
  display: flex;
  justify-content: space-between;
  align-items: center;
  position: sticky;
  top: 0;
  z-index: 90;
}

.view-title-wrap h1 {
  font-size: 1.3rem;
  font-weight: 800;
  display: flex;
  align-items: center;
  gap: 0.6rem;
}

.view-title-wrap p {
  font-size: 0.8rem;
  color: var(--text-muted);
}

.top-bar-badge {
  background: rgba(255, 190, 11, 0.12);
  border: 1px solid rgba(255, 190, 11, 0.3);
  color: var(--accent-gold);
  font-size: 0.75rem;
  font-weight: 700;
  padding: 0.3rem 0.75rem;
  border-radius: 999px;
  letter-spacing: 0.5px;
}

.main-view-container {
  padding: 1.75rem 2rem;
  max-width: 1400px;
  width: 100%;
  margin: 0 auto;
}

/* Views display */
.page-view {
  display: none;
}

.page-view.active {
  display: block;
}

/* 1. DRAFT MASTER STYLES */
.winrate-gauge-section {
  background: var(--bg-card);
  border: 1px solid var(--border-color);
  border-radius: 12px;
  padding: 1rem 1.5rem;
  margin-bottom: 1.5rem;
  box-shadow: 0 8px 24px rgba(0, 0, 0, 0.3);
  backdrop-filter: blur(8px);
}

.gauge-header {
  display: flex;
  justify-content: space-between;
  align-items: center;
  margin-bottom: 0.6rem;
}

.team-win-val {
  font-size: 1.3rem;
  font-weight: 800;
}

.team-win-val.blue {
  color: var(--blue-team);
  text-shadow: 0 0 12px var(--blue-glow);
}

.team-win-val.red {
  color: var(--red-team);
  text-shadow: 0 0 12px var(--red-glow);
}

.progress-bar-container {
  height: 12px;
  background: rgba(255, 51, 102, 0.4);
  border-radius: 999px;
  overflow: hidden;
  position: relative;
  display: flex;
}

.progress-blue {
  height: 100%;
  background: linear-gradient(90deg, #0077b6, #00d2ff);
  transition: width 0.4s cubic-bezier(0.16, 1, 0.3, 1);
  box-shadow: 0 0 12px rgba(0, 210, 255, 0.6);
}

.draft-board {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 1.5rem;
  margin-bottom: 2rem;
}

.team-column {
  background: var(--bg-card);
  border: 1px solid var(--border-color);
  border-radius: 12px;
  padding: 1.2rem;
  backdrop-filter: blur(8px);
}

.team-column.blue-side {
  border-left: 3px solid var(--blue-team);
}

.team-column.red-side {
  border-right: 3px solid var(--red-team);
}

.team-title {
  display: flex;
  justify-content: space-between;
  align-items: center;
  margin-bottom: 1rem;
  font-size: 1.1rem;
  font-weight: 700;
}

.blue-side .team-title { color: var(--blue-team); }
.red-side .team-title { color: var(--red-team); }

.slots-list {
  display: flex;
  flex-direction: column;
  gap: 0.6rem;
}

.draft-slot {
  display: flex;
  align-items: center;
  justify-content: space-between;
  background: rgba(255, 255, 255, 0.03);
  border: 1px dashed rgba(255, 255, 255, 0.12);
  border-radius: 8px;
  padding: 0.6rem 1rem;
  min-height: 58px;
  cursor: pointer;
  transition: all 0.2s ease;
}

.draft-slot:hover {
  background: rgba(255, 255, 255, 0.06);
  border-color: rgba(255, 255, 255, 0.25);
}

.draft-slot.filled {
  border-style: solid;
  border-color: rgba(255, 255, 255, 0.18);
  background: rgba(255, 255, 255, 0.05);
}

.blue-side .draft-slot.filled { border-left: 3px solid var(--blue-team); }
.red-side .draft-slot.filled { border-left: 3px solid var(--red-team); }

.slot-left {
  display: flex;
  align-items: center;
  gap: 0.8rem;
}

.slot-avatar {
  width: 44px;
  height: 44px;
  border-radius: 8px;
  background: rgba(255, 255, 255, 0.08);
  display: flex;
  align-items: center;
  justify-content: center;
  overflow: hidden;
  border: 1px solid var(--border-color);
}

.slot-avatar img {
  width: 100%;
  height: 100%;
  object-fit: cover;
}

.slot-info h4 {
  font-size: 0.95rem;
  font-weight: 600;
}

.slot-info p {
  font-size: 0.75rem;
  color: var(--text-muted);
}

.slot-remove-btn {
  background: transparent;
  border: none;
  color: var(--text-muted);
  cursor: pointer;
  font-size: 1.1rem;
  padding: 0.2rem 0.5rem;
  border-radius: 4px;
}

.slot-remove-btn:hover {
  color: var(--danger);
  background: rgba(239, 35, 60, 0.1);
}

/* Recommendations Section */
.recommendations-section {
  background: var(--bg-card);
  border: 1px solid var(--border-color);
  border-radius: 12px;
  padding: 1.5rem;
  backdrop-filter: blur(8px);
}

.sec-header {
  display: flex;
  justify-content: space-between;
  align-items: center;
  margin-bottom: 1.2rem;
  flex-wrap: wrap;
  gap: 1rem;
}

.lane-filter-group {
  display: flex;
  gap: 0.4rem;
  flex-wrap: wrap;
}

.filter-btn {
  background: rgba(255, 255, 255, 0.05);
  border: 1px solid var(--border-color);
  color: var(--text-muted);
  font-family: inherit;
  font-size: 0.8rem;
  font-weight: 600;
  padding: 0.4rem 0.8rem;
  border-radius: 6px;
  cursor: pointer;
  transition: all 0.2s ease;
}

.filter-btn:hover {
  color: var(--text-main);
  background: rgba(255, 255, 255, 0.1);
}

.filter-btn.active {
  background: var(--blue-team);
  color: #000;
  border-color: var(--blue-team);
  font-weight: 700;
}

.recommendations-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(280px, 1fr));
  gap: 1rem;
}

.rec-card {
  background: rgba(255, 255, 255, 0.03);
  border: 1px solid var(--border-color);
  border-radius: 10px;
  padding: 1rem;
  display: flex;
  flex-direction: column;
  justify-content: space-between;
  transition: all 0.2s ease;
}

.rec-card:hover {
  transform: translateY(-2px);
  border-color: rgba(0, 210, 255, 0.4);
  box-shadow: 0 6px 20px rgba(0, 210, 255, 0.1);
}

.rec-header {
  display: flex;
  gap: 0.8rem;
  margin-bottom: 0.8rem;
}

.rec-avatar {
  width: 52px;
  height: 52px;
  border-radius: 8px;
  background: rgba(255, 255, 255, 0.08);
  overflow: hidden;
  flex-shrink: 0;
  border: 1px solid var(--border-color);
}

.rec-avatar img {
  width: 100%;
  height: 100%;
  object-fit: cover;
}

.rec-details h4 {
  font-size: 1.05rem;
  font-weight: 700;
}

.badge-role {
  background: rgba(255, 255, 255, 0.08);
  font-size: 0.7rem;
  padding: 0.15rem 0.4rem;
  border-radius: 4px;
  color: var(--text-muted);
}

.badge-uplift {
  background: rgba(0, 245, 155, 0.15);
  color: var(--success);
  border: 1px solid rgba(0, 245, 155, 0.3);
  font-size: 0.75rem;
  font-weight: 700;
  padding: 0.15rem 0.5rem;
  border-radius: 999px;
}

.rec-reason {
  font-size: 0.8rem;
  color: #c0d0e0;
  line-height: 1.4;
  margin-bottom: 1rem;
  background: rgba(0, 0, 0, 0.25);
  padding: 0.6rem;
  border-radius: 6px;
}

.btn-pick-ally {
  background: linear-gradient(135deg, #0077b6, #00d2ff);
  color: #000;
  font-family: inherit;
  font-size: 0.8rem;
  font-weight: 700;
  border: none;
  padding: 0.5rem 1rem;
  border-radius: 6px;
  cursor: pointer;
  transition: all 0.2s ease;
}

.btn-pick-ally:hover {
  box-shadow: 0 0 12px rgba(0, 210, 255, 0.5);
  filter: brightness(1.1);
}

/* 2. COUNTER PICK VIEW STYLES */
.counter-hero-selector {
  background: var(--bg-card);
  border: 1px solid var(--border-color);
  border-radius: 12px;
  padding: 1.5rem;
  margin-bottom: 1.5rem;
  display: flex;
  align-items: center;
  gap: 1.5rem;
  flex-wrap: wrap;
}

.hero-search-input {
  flex: 1;
  min-width: 260px;
  background: rgba(255, 255, 255, 0.05);
  border: 1px solid var(--border-color);
  border-radius: 8px;
  padding: 0.75rem 1rem;
  color: #fff;
  font-family: inherit;
  font-size: 0.95rem;
}

.hero-search-input:focus {
  outline: none;
  border-color: var(--blue-team);
  box-shadow: 0 0 10px rgba(0, 210, 255, 0.3);
}

.selected-hero-banner {
  background: var(--bg-card);
  border: 1px solid var(--border-color);
  border-radius: 12px;
  padding: 1.5rem;
  margin-bottom: 1.5rem;
  display: flex;
  align-items: center;
  gap: 1.5rem;
}

.banner-avatar {
  width: 72px;
  height: 72px;
  border-radius: 12px;
  overflow: hidden;
  border: 2px solid var(--blue-team);
  box-shadow: 0 0 16px var(--blue-glow);
}

.banner-avatar img {
  width: 100%;
  height: 100%;
  object-fit: cover;
}

.banner-info h2 {
  font-size: 1.5rem;
  font-weight: 800;
}

.banner-info p {
  color: var(--text-muted);
  font-size: 0.85rem;
}

.counter-sections-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 1.5rem;
}

.counter-column-card {
  background: var(--bg-card);
  border: 1px solid var(--border-color);
  border-radius: 12px;
  padding: 1.5rem;
}

.counter-column-card h3 {
  font-size: 1.15rem;
  font-weight: 700;
  margin-bottom: 1rem;
  display: flex;
  align-items: center;
  gap: 0.5rem;
}

.matchup-list {
  display: flex;
  flex-direction: column;
  gap: 0.75rem;
}

.matchup-item {
  display: flex;
  align-items: center;
  justify-content: space-between;
  background: rgba(255, 255, 255, 0.03);
  border: 1px solid var(--border-color);
  border-radius: 8px;
  padding: 0.75rem 1rem;
  transition: all 0.2s;
}

.matchup-item:hover {
  background: rgba(255, 255, 255, 0.06);
  border-color: rgba(255, 255, 255, 0.2);
}

.matchup-left {
  display: flex;
  align-items: center;
  gap: 0.8rem;
}

.matchup-avatar {
  width: 44px;
  height: 44px;
  border-radius: 8px;
  overflow: hidden;
  border: 1px solid var(--border-color);
}

.matchup-avatar img {
  width: 100%;
  height: 100%;
  object-fit: cover;
}

.matchup-advantage {
  font-size: 0.95rem;
  font-weight: 700;
  color: var(--success);
}

/* Counter Items Section */
.counter-items-card {
  background: var(--bg-card);
  border: 1px solid var(--border-color);
  border-radius: 12px;
  padding: 1.5rem;
  margin-top: 1.5rem;
}

.items-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(260px, 1fr));
  gap: 1rem;
  margin-top: 1rem;
}

.counter-item-card {
  background: rgba(255, 255, 255, 0.03);
  border: 1px solid var(--border-color);
  border-radius: 8px;
  padding: 1rem;
  display: flex;
  gap: 0.8rem;
  align-items: flex-start;
}

.item-icon-box {
  width: 48px;
  height: 48px;
  border-radius: 8px;
  background: rgba(0, 0, 0, 0.4);
  border: 1px solid rgba(255, 255, 255, 0.1);
  overflow: hidden;
  flex-shrink: 0;
}

.item-icon-box img {
  width: 100%;
  height: 100%;
  object-fit: cover;
}

.item-info h4 {
  font-size: 0.95rem;
  font-weight: 700;
  color: var(--accent-gold);
}

.item-info p {
  font-size: 0.75rem;
  color: var(--text-muted);
  line-height: 1.4;
  margin-top: 0.2rem;
}

/* 3. STATISTIK HERO (MYTHIC+) VIEW STYLES */
.stats-banner {
  background: linear-gradient(135deg, rgba(255, 190, 11, 0.1), rgba(0, 210, 255, 0.1));
  border: 1px solid rgba(255, 190, 11, 0.3);
  border-radius: 12px;
  padding: 1rem 1.5rem;
  margin-bottom: 1.5rem;
  display: flex;
  justify-content: space-between;
  align-items: center;
}

.stats-filter-bar {
  display: flex;
  gap: 1rem;
  margin-bottom: 1.5rem;
  flex-wrap: wrap;
  align-items: center;
  justify-content: space-between;
}

.stats-table-wrap {
  background: var(--bg-card);
  border: 1px solid var(--border-color);
  border-radius: 12px;
  overflow: hidden;
}

.stats-table {
  width: 100%;
  border-collapse: collapse;
  font-size: 0.9rem;
}

.stats-table th, .stats-table td {
  padding: 0.85rem 1.2rem;
  text-align: left;
  border-bottom: 1px solid var(--border-color);
}

.stats-table th {
  color: var(--text-muted);
  font-weight: 700;
  background: rgba(255, 255, 255, 0.02);
  cursor: pointer;
  user-select: none;
}

.stats-table th:hover {
  color: #fff;
}

.stats-table tr:hover {
  background: rgba(255, 255, 255, 0.04);
}

.hero-cell {
  display: flex;
  align-items: center;
  gap: 0.8rem;
}

.hero-cell-avatar {
  width: 40px;
  height: 40px;
  border-radius: 6px;
  overflow: hidden;
  border: 1px solid var(--border-color);
}

.hero-cell-avatar img {
  width: 100%;
  height: 100%;
  object-fit: cover;
}

.tier-badge {
  font-weight: 800;
  font-size: 0.75rem;
  padding: 0.2rem 0.5rem;
  border-radius: 4px;
  text-align: center;
  display: inline-block;
}

.tier-s-plus { background: rgba(255, 0, 85, 0.2); color: var(--tier-s-plus); border: 1px solid var(--tier-s-plus); }
.tier-s { background: rgba(255, 190, 11, 0.2); color: var(--tier-s); border: 1px solid var(--tier-s); }
.tier-a { background: rgba(0, 210, 255, 0.2); color: var(--tier-a); border: 1px solid var(--tier-a); }
.tier-b { background: rgba(140, 155, 165, 0.2); color: var(--tier-b); border: 1px solid var(--tier-b); }

/* 4. BUILD ITEM VIEW STYLES */
.build-section-card {
  background: var(--bg-card);
  border: 1px solid var(--border-color);
  border-radius: 12px;
  padding: 1.5rem;
  margin-bottom: 1.5rem;
}

.build-box {
  background: rgba(255, 255, 255, 0.03);
  border: 1px solid var(--border-color);
  border-radius: 10px;
  padding: 1.2rem;
  margin-bottom: 1.2rem;
}

.build-box-header {
  display: flex;
  justify-content: space-between;
  align-items: center;
  margin-bottom: 1rem;
}

.build-items-row {
  display: flex;
  gap: 1rem;
  flex-wrap: wrap;
  align-items: center;
}

.build-item-slot {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 0.4rem;
  width: 72px;
}

.build-item-slot .slot-img {
  width: 52px;
  height: 52px;
  border-radius: 10px;
  background: rgba(0, 0, 0, 0.5);
  border: 1px solid rgba(255, 255, 255, 0.15);
  overflow: hidden;
  transition: all 0.2s;
  cursor: pointer;
}

.build-item-slot .slot-img:hover {
  transform: scale(1.08);
  border-color: var(--accent-gold);
}

.build-item-slot .slot-img img {
  width: 100%;
  height: 100%;
  object-fit: cover;
}

.build-item-slot span {
  font-size: 0.7rem;
  color: var(--text-muted);
  text-align: center;
  line-height: 1.2;
}

.emblem-talents-row {
  display: flex;
  gap: 0.8rem;
  align-items: center;
  margin-top: 1rem;
  padding-top: 0.8rem;
  border-top: 1px solid var(--border-color);
}

.emblem-pill {
  background: rgba(255, 255, 255, 0.06);
  border: 1px solid var(--border-color);
  padding: 0.3rem 0.8rem;
  border-radius: 999px;
  font-size: 0.75rem;
  color: #c0d0e0;
}

/* 5. MLOPS DRIFT VIEW */
.kpi-row {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(220px, 1fr));
  gap: 1rem;
  margin-bottom: 1.5rem;
}

.kpi-card {
  background: var(--bg-card);
  border: 1px solid var(--border-color);
  border-radius: 10px;
  padding: 1.2rem;
}

.kpi-title {
  font-size: 0.75rem;
  color: var(--text-muted);
  text-transform: uppercase;
  letter-spacing: 0.5px;
  margin-bottom: 0.4rem;
}

.kpi-value {
  font-size: 1.8rem;
  font-weight: 800;
}

.kpi-value.good { color: var(--success); }
.kpi-value.alert { color: var(--danger); }

.kpi-desc {
  font-size: 0.75rem;
  color: var(--text-muted);
  margin-top: 0.3rem;
}

.table-card {
  background: var(--bg-card);
  border: 1px solid var(--border-color);
  border-radius: 10px;
  padding: 1.2rem;
}

.drift-table {
  width: 100%;
  border-collapse: collapse;
  font-size: 0.85rem;
}

.drift-table th, .drift-table td {
  padding: 0.75rem 1rem;
  text-align: left;
  border-bottom: 1px solid var(--border-color);
}

.btn-retrain {
  background: linear-gradient(135deg, #ffbe0b, #fb5607);
  color: #000;
  font-family: inherit;
  font-size: 0.9rem;
  font-weight: 700;
  border: none;
  padding: 0.75rem 1.5rem;
  border-radius: 8px;
  cursor: pointer;
  transition: all 0.2s ease;
}

.btn-retrain:hover {
  filter: brightness(1.1);
  box-shadow: 0 4px 16px rgba(251, 86, 7, 0.4);
}

/* Modal Picker */
.modal-overlay {
  position: fixed;
  top: 0; left: 0; right: 0; bottom: 0;
  background: rgba(0, 0, 0, 0.75);
  backdrop-filter: blur(8px);
  z-index: 200;
  display: flex;
  align-items: center;
  justify-content: center;
  opacity: 0;
  pointer-events: none;
  transition: opacity 0.2s ease;
}

.modal-overlay.active {
  opacity: 1;
  pointer-events: all;
}

.modal-content {
  background: #111726;
  border: 1px solid var(--border-color);
  border-radius: 12px;
  width: 90%;
  max-width: 720px;
  max-height: 85vh;
  display: flex;
  flex-direction: column;
  box-shadow: 0 16px 40px rgba(0, 0, 0, 0.6);
}

.modal-header {
  padding: 1rem 1.5rem;
  border-bottom: 1px solid var(--border-color);
  display: flex;
  justify-content: space-between;
  align-items: center;
}

.modal-body {
  padding: 1.2rem 1.5rem;
  overflow-y: auto;
  flex: 1;
}

.hero-selection-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(80px, 1fr));
  gap: 0.75rem;
}

.hero-item {
  display: flex;
  flex-direction: column;
  align-items: center;
  padding: 0.5rem;
  background: rgba(255, 255, 255, 0.03);
  border: 1px solid transparent;
  border-radius: 8px;
  cursor: pointer;
  transition: all 0.2s ease;
}

.hero-item:hover {
  background: rgba(255, 255, 255, 0.08);
  border-color: var(--blue-team);
  transform: translateY(-2px);
}

.hero-item img {
  width: 48px;
  height: 48px;
  border-radius: 6px;
  object-fit: cover;
  margin-bottom: 0.3rem;
  border: 1px solid var(--border-color);
}

.hero-item span {
  font-size: 0.75rem;
  font-weight: 500;
  text-align: center;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
  max-width: 70px;
}

/* Official Moonton Select Controls */
.moonton-select-wrap {
  position: relative;
  display: inline-block;
}

.moonton-select {
  background: #111a24;
  color: #fff;
  border: 1px solid rgba(255, 255, 255, 0.15);
  padding: 0.45rem 1.8rem 0.45rem 0.8rem;
  border-radius: 6px;
  font-family: inherit;
  font-size: 0.85rem;
  font-weight: 600;
  cursor: pointer;
  outline: none;
  appearance: none;
  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='%238899a6' stroke-width='2' stroke-linecap='round' stroke-linejoin='round'%3E%3Cpolyline points='6 9 12 15 18 9'%3E%3C/polyline%3E%3C/svg%3E");
  background-repeat: no-repeat;
  background-position: right 0.6rem center;
  transition: all 0.2s;
}

.moonton-select:hover, .moonton-select:focus {
  border-color: var(--blue-team);
  background-color: #162230;
}

/* Rank Badges (Gold, Silver, Bronze) */
.rank-badge {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 28px;
  height: 28px;
  border-radius: 6px;
  font-weight: 800;
  font-size: 0.85rem;
}

.rank-gold {
  background: linear-gradient(135deg, #ffd700, #ff9900);
  color: #000;
  box-shadow: 0 0 10px rgba(255, 184, 0, 0.4);
}

.rank-silver {
  background: linear-gradient(135deg, #e0e0e0, #9e9e9e);
  color: #000;
}

.rank-bronze {
  background: linear-gradient(135deg, #cd7f32, #8b4513);
  color: #fff;
}

.rank-plain {
  color: var(--text-muted);
  font-weight: 600;
}

/* Official Counter Heroes Row (Moonton Style) */
.official-counters-row {
  display: flex;
  align-items: center;
  gap: 6px;
}

.counter-mini-avatar-wrap {
  position: relative;
  cursor: pointer;
}

.counter-mini-avatar {
  width: 32px;
  height: 32px;
  border-radius: 50%;
  border: 1.5px solid rgba(255, 77, 77, 0.4);
  background: #111a24;
  object-fit: cover;
  transition: transform 0.2s, border-color 0.2s;
}

.counter-mini-avatar:hover {
  transform: scale(1.2);
  border-color: #ff4d4d;
  box-shadow: 0 0 8px rgba(255, 77, 77, 0.5);
  z-index: 10;
}

.counter-mini-avatar.prey {
  border-color: rgba(16, 185, 129, 0.4);
}

.counter-mini-avatar.prey:hover {
  border-color: #10b981;
  box-shadow: 0 0 8px rgba(16, 185, 129, 0.5);
}

/* Autocomplete dropdown for counter hero selector */
.autocomplete-dropdown {
  position: absolute;
  top: calc(100% + 4px);
  left: 0;
  right: 0;
  background: #111a24;
  border: 1px solid var(--border-color);
  border-radius: 8px;
  box-shadow: 0 10px 30px rgba(0, 0, 0, 0.6);
  z-index: 100;
  max-height: 280px;
  overflow-y: auto;
}

.autocomplete-item {
  display: flex;
  align-items: center;
  gap: 0.75rem;
  padding: 0.6rem 1rem;
  cursor: pointer;
  border-bottom: 1px solid rgba(255, 255, 255, 0.05);
  transition: background 0.15s ease;
}

.autocomplete-item:last-child {
  border-bottom: none;
}

.autocomplete-item:hover {
  background: rgba(59, 130, 246, 0.15);
}
