/* Responsive padding for nav and hero (match info/events) */
@media (max-width: 992px) {
  .site-header {
    padding-left: 0;
    padding-right: 0;
  }
  .main-navigation .container,
  .top-navigation .container {
    padding-left: 32px;
    padding-right: 32px;
  }
  .rankings-hero .container {
    padding-left: 48px;
    padding-right: 48px;
  }
}

@media (max-width: 768px) {
  .main-navigation .container,
  .top-navigation .container {
    padding-left: 20px;
    padding-right: 20px;
  }
  .rankings-hero .container {
    padding-left: 28px;
    padding-right: 28px;
  }
}

@media (max-width: 480px) {
  .main-navigation .container,
  .top-navigation .container {
    padding-left: 12px;
    padding-right: 12px;
  }
  .rankings-hero .container {
    padding-left: 14px;
    padding-right: 14px;
  }
}
/* Champion Card Responsive Styles */
@media (max-width: 992px) {
  .champion-card {
    flex-direction: column;
    min-height: 320px;
    align-items: stretch;
  }
  .champ-info {
    padding: 32px 24px;
    align-items: flex-start;
  }
  .champ-name {
    font-size: 32px;
    margin-bottom: 18px;
  }
  .rank-badge-lg {
    font-size: 56px;
    margin-bottom: 10px;
  }
  .champ-stats-grid {
    gap: 10px;
    padding-top: 16px;
  }
}

@media (max-width: 576px) {
  .champion-card {
    flex-direction: column;
    min-height: 220px;
    align-items: stretch;
  }
  .champ-info {
    padding: 18px 8px;
    align-items: flex-start;
  }
  .champ-name {
    font-size: 20px;
    margin-bottom: 10px;
  }
  .rank-badge-lg {
    font-size: 32px;
    margin-bottom: 6px;
  }
  .champ-label {
    font-size: 10px;
    margin-bottom: 4px;
  }
  .champ-badges {
    gap: 5px;
    margin-bottom: 12px;
  }
  .champ-stats-grid {
    grid-template-columns: 1fr;
    gap: 6px;
    padding-top: 8px;
  }
  .champ-image {
    min-height: 120px;
    max-height: 180px;
  }
  .champ-image img {
    min-height: 120px;
    max-height: 180px;
    object-fit: cover;
  }
}
/* Responsive Table Wrapper */
.table-responsive {
  width: 100%;
  overflow-x: auto;
}

@media (max-width: 992px) {
  .table-responsive {
    margin-bottom: 1.5rem;
  }
  .data-grid {
    min-width: 700px;
    font-size: 15px;
  }
}

@media (max-width: 768px) {
  .container {
    padding-left: 6px;
    padding-right: 6px;
  }
  .data-grid {
    min-width: 600px;
    font-size: 14px;
  }
}

@media (max-width: 576px) {
  .container {
    padding-left: 2px;
    padding-right: 2px;
  }
  .data-grid {
    min-width: 520px;
    font-size: 13px;
  }
}

html, body {
  max-width: 100vw;
  overflow-x: hidden;
}
/* Pagination Controls - Match Control Panel */
.pagination-controls {
  display: flex;
  justify-content: center;
  align-items: center;
  gap: 0.5rem;
  margin-top: 1.5rem;
}
.pagination-btn {
  background: #fff;
  color: var(--secondary-color);
  border: 1px solid #eee;
  border-radius: 0;
  padding: 8px 18px;
  font-family: 'Oswald', sans-serif;
  font-weight: 600;
  text-transform: uppercase;
  font-size: 13px;
  cursor: pointer;
  transition: background 0.2s, color 0.2s, border-color 0.2s;
  box-shadow: 0 1px 4px rgba(0,0,0,0.03);
}
.pagination-btn.active, .pagination-btn:disabled {
  background: var(--secondary-color);
  color: #fff;
  border-color: var(--secondary-color);
  cursor: default;
}
.pagination-btn:hover:not(:disabled), .pagination-btn:focus:not(:disabled) {
  background: #f4f4f4;
  color: var(--primary-color);
  border-color: var(--primary-color);
  outline: none;
}
/* --- Rankings Hero (Dojo Dark Style) --- */
.rankings-hero {
  background-color: #050505;
  color: #fff;
  padding: 140px 0 160px;
  text-align: left;
  position: relative;
  overflow: hidden;
  border-bottom: 1px solid #222;
}

.rankings-hero::before {
  content: '';
  position: absolute;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  background: url('../images/dojo-bg-overlay.jpg') center/cover no-repeat;
  opacity: 0.2;
  pointer-events: none;
}

.hero-badge {
  font-family: 'Oswald', sans-serif;
  font-size: 12px;
  font-weight: 700;
  color: #e01e1e;
  text-transform: uppercase;
  letter-spacing: 2px;
  display: inline-block;
  margin-bottom: 15px;
  border: 1px solid #e01e1e;
  padding: 5px 10px;
  border-radius: 4px;
  background: rgba(224, 30, 30, 0.1);
}

.rankings-hero h1 {
  font-family: 'Oswald', sans-serif;
  font-size: 56px;
  font-weight: 700;
  margin-bottom: 15px;
  text-transform: uppercase;
  line-height: 1.1;
  color: #fff;
  position: relative;
}

.rankings-hero p {
  font-family: 'Open Sans', sans-serif;
  font-size: 18px;
  color: #888;
  max-width: 600px;
  margin: 0;
  line-height: 1.6;
  position: relative;
}

/* --- Control Panel (Glassmorphism) --- */
.control-panel {
  position: sticky;
  top: 80px;
  z-index: 90;
  padding: 0;
  pointer-events: none;
  margin-top: -50px;
  margin-bottom: 30px;
}

.control-panel .container {
  pointer-events: auto;
  max-width: 1440px;
}

.control-card {
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: 15px;
  background: #fff;
  padding: 15px 25px;
  border-radius: 0;
  box-shadow: 0 2px 10px rgba(0, 0, 0, 0.05);
  border: 1px solid #eee;
  flex-wrap: wrap;
  width: 100%;
}

.control-group {
  display: flex;
  gap: 10px;
  align-items: center;
}

.rank-select {
  background-color: #f4f4f4;
  color: #333;
  border: 1px solid #e0e0e0;
  padding: 10px 20px;
  border-radius: 0;
  font-family: 'Oswald', sans-serif;
  font-weight: 600;
  text-transform: uppercase;
  cursor: pointer;
  transition: all 0.2s;
  font-size: 13px;
}

.rank-select:hover {
  background-color: #eee;
}

.rank-select:focus {
  outline: none;
  border-color: #e01e1e;
  background-color: #fff;
}

/* --- Toggle Group (Pill Style) --- */
.view-toggles {
  display: flex;
  background: #f4f4f4;
  padding: 4px;
  border-radius: 0;
  gap: 2px;
}

.toggle-btn {
  border: none;
  background: transparent;
  padding: 8px 20px;
  font-family: 'Oswald', sans-serif;
  font-size: 13px;
  font-weight: 700;
  text-transform: uppercase;
  color: #888;
  border-radius: 0;
  cursor: pointer;
  transition: all 0.2s;
}

.toggle-btn:hover {
  color: #555;
}

.toggle-btn.active {
  background: #fff;
  color: #222;
  box-shadow: 0 1px 3px rgba(0,0,0,0.1);
}

.right-group {
  display: flex;
  gap: 10px;
  align-items: center;
}

.search-wrapper {
  position: relative;
  flex: 1;
  max-width: 300px;
}

.rank-search {
  width: 100%;
  background-color: #f4f4f4;
  border: 1px solid #e0e0e0;
  color: #333;
  padding: 10px 15px 10px 40px;
  border-radius: 0;
  font-family: 'Open Sans', sans-serif;
  font-size: 14px;
  transition: all 0.2s;
}

.rank-search:focus {
  outline: none;
  border-color: #e01e1e;
  background-color: #fff;
}

.search-icon {
  position: absolute;
  left: 14px;
  top: 50%;
  transform: translateY(-50%);
  color: #888;
  font-size: 14px;
}

/* --- Champion Showcase (Premium Dark) --- */
.champion-showcase {
  padding: 0 0 20px;
  background-color: transparent;
  background-image: none;
}

.champion-card {
  display: flex;
  background: #0a0a0a;
  border-radius: 4px;
  overflow: hidden;
  box-shadow: 0 25px 60px rgba(0,0,0,0.2);
  border: none;
  position: relative;
  min-height: 450px;
  cursor: pointer;
  transition: transform 0.3s ease, box-shadow 0.3s ease;
}

.champion-card:hover {
  transform: translateY(-5px);
  box-shadow: 0 30px 70px rgba(0,0,0,0.3);
}

.champion-card::before {
  content: '';
  position: absolute;
  top: 0;
  left: 0;
  width: 6px;
  height: 100%;
  background-color: #e01e1e;
  z-index: 2;
}

.champ-image {
  flex: 1;
  background-color: #050505;
  position: relative;
  overflow: hidden;
}

.champ-image img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  filter: grayscale(100%) contrast(1.1);
  transition: filter 0.5s ease;
}

.champ-image:hover img {
  filter: grayscale(0%) contrast(1);
}

.champ-info {
  flex: 1.2;
  padding: 50px;
  display: flex;
  flex-direction: column;
  justify-content: center;
  position: relative;
}

.champ-label {
  font-family: 'Oswald', sans-serif;
  font-size: 13px;
  color: #e01e1e;
  text-transform: uppercase;
  letter-spacing: 2px;
  margin-bottom: 10px;
  font-weight: 700;
}

.rank-badge-lg {
  font-family: 'Oswald', sans-serif;
  font-size: 90px;
  color: #fff;
  line-height: 0.9;
  font-weight: 700;
  margin-bottom: 15px;
  text-shadow: 4px 4px 0px rgba(224, 30, 30, 0.2);
}

.champ-name {
  font-family: 'Oswald', sans-serif;
  font-size: 48px;
  font-weight: 700;
  text-transform: uppercase;
  margin-bottom: 25px;
  line-height: 1;
  color: #fff;
}

.champ-badges {
  display: flex;
  gap: 10px;
  margin-bottom: 30px;
}

.c-badge {
  background: #222;
  color: #ccc;
  padding: 6px 12px;
  border-radius: 4px;
  font-size: 11px;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.5px;
  border: 1px solid #333;
}

.champ-stats-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 20px;
  border-top: 1px solid #222;
  padding-top: 25px;
}

.c-stat label {
  display: block;
  font-size: 10px;
  color: #666;
  text-transform: uppercase;
  margin-bottom: 5px;
  font-weight: 700;
}

.c-stat span {
  font-family: 'Oswald', sans-serif;
  font-size: 28px;
  font-weight: 500;
  color: #fff;
}

.c-stat.highlight span {
  color: #e01e1e;
}

/* --- Leaderboard (Clean Data Grid) --- */
.leaderboard-section {
  padding: 20px 0;

  min-height: 600px;
}

.data-grid {
  width: 100%;
  border-collapse: separate;
  border-spacing: 0;
  background: #fff;
  border-radius: 12px;
  overflow: hidden;
  box-shadow: 0 5px 20px rgba(0,0,0,0.05);
}

.data-grid thead th {
  background-color: #fff;
  padding: 20px;
  text-align: left;
  font-family: 'Oswald', sans-serif;
  font-size: 12px;
  font-weight: 700;
  color: #999;
  text-transform: uppercase;
  letter-spacing: 1px;
  border-bottom: 2px solid #f0f0f0;
}

.data-grid tbody tr {
  transition: background-color 0.2s;
  cursor: pointer;
}

.data-grid tbody tr:hover {
  background-color: #f8f9fa;
}

.data-grid td {
  padding: 20px;
  vertical-align: middle;
  border-bottom: 1px solid #f0f0f0;
  color: #333;
  font-size: 15px;
}

.data-grid tbody tr:last-child td {
  border-bottom: none;
}

.rank-cell {
  font-family: 'Oswald', sans-serif;
  font-weight: 700;
  font-size: 18px;
  color: #222;
  width: 80px;
  text-align: center;
}

.fighter-cell {
  font-weight: 600;
  color: #000;
}

.points-cell {
  font-family: 'Oswald', sans-serif;
  font-weight: 700;
  font-size: 16px;
  color: #e01e1e;
  text-align: right;
}

.trend-icon {
  font-size: 12px;
  margin-right: 5px;
}
.trend-up { color: #28a745; }
.trend-down { color: #dc3545; }
.trend-stable { color: #ccc; }

/* --- Modal (Redesigned Fighter Card) --- */
.modal-backdrop {
  display: none;
  position: fixed;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  background-color: rgba(17, 17, 17, 0.9); /* bg-dojo-dark/90 */
  z-index: 1000;
  align-items: center;
  justify-content: center;
  -webkit-backdrop-filter: blur(4px);
  backdrop-filter: blur(4px);
  padding: 1rem;
}

.modal-backdrop.active {
  display: flex;
  animation: fadeIn 0.2s ease-out;
}

@keyframes fadeIn {
  from { opacity: 0; }
  to { opacity: 1; }
}

.fighter-modal-card {
  background-color: #fff;
  width: 100%;
  max-width: 672px; /* max-w-2xl */
  border-radius: 0.75rem; /* rounded-xl */
  overflow: hidden;
  box-shadow: 0 25px 50px -12px rgba(0, 0, 0, 0.25); /* shadow-2xl */
  display: flex;
  flex-direction: column;
  font-family: 'Roboto', sans-serif;
  max-height: 90vh;
  position: relative;
  animation: slideUp 0.3s ease-out;
}

@keyframes slideUp {
  from { transform: translateY(20px); opacity: 0; }
  to { transform: translateY(0); opacity: 1; }
}

/* Header */
.fighter-card-header {
  background-color: #111; /* bg-dojo-dark */
  padding: 1.5rem; /* p-6 */
  display: flex;
  justify-content: space-between;
  align-items: flex-start;
  color: #fff;
  position: sticky;
  top: 0;
  z-index: 10;
  border-bottom: 1px solid #1f2937; /* border-gray-800 */
}

.fighter-identity {
  display: flex;
  align-items: center;
  gap: 1rem; /* gap-4 */
}

.fighter-avatar-container {
  position: relative;
}

.fighter-avatar {
  width: 4rem; /* w-16 */
  height: 4rem; /* h-16 */
  border-radius: 9999px; /* rounded-full */
  border: 2px solid rgba(255, 255, 255, 0.2); /* border-white/20 */
  box-shadow: 0 10px 15px -3px rgba(0, 0, 0, 0.1); /* shadow-lg */
  object-fit: cover;
}

.rank-badge-circle {
  position: absolute;
  bottom: -0.25rem; /* -bottom-1 */
  right: -0.25rem; /* -right-1 */
  background-color: #fff;
  color: #111; /* text-dojo-dark */
  font-weight: 700;
  width: 1.5rem; /* w-6 */
  height: 1.5rem; /* h-6 */
  display: flex;
  align-items: center;
  justify-content: center;
  border-radius: 9999px;
  font-size: 0.75rem; /* text-xs */
  box-shadow: 0 1px 2px 0 rgba(0, 0, 0, 0.05); /* shadow-sm */
}

.fighter-info-header {
  display: flex;
  flex-direction: column;
  align-items: flex-start;
  justify-content: center;
}

.category-badge {
  display: inline-block;
  padding: 0.125rem 0.5rem; /* px-2 py-0.5 */
  margin-bottom: 0.5rem; /* Increased spacing */
  font-size: 10px; /* text-[10px] */
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.05em; /* tracking-wider */
  background-color: #e01e1e; /* bg-dojo-red */
  color: #fff;
  border-radius: 0.125rem; /* rounded-sm */
  width: fit-content;
  order: -1; /* Force to top */
}

.fighter-info-header h2 {
  font-family: 'Oswald', sans-serif; /* font-display */
  font-size: 1.5rem; /* text-2xl */
  font-weight: 700;
  color: #fff;
  line-height: 1;
  margin: 0;
}

.dojo-text {
  color: #9ca3af; /* text-gray-400 */
  font-size: 0.75rem; /* text-xs */
  margin-top: 0.25rem; /* mt-1 */
  text-transform: uppercase;
  letter-spacing: 0.025em; /* tracking-wide */
}

.modal-close-btn {
  background: none;
  border: none;
  color: #6b7280; /* text-gray-500 */
  cursor: pointer;
  transition: color 0.2s;
  padding: 0;
  display: flex;
  align-items: center;
  justify-content: center;
}

.modal-close-btn:hover {
  color: #fff;
}

.modal-close-btn svg {
  width: 1.5rem;
  height: 1.5rem;
}

/* Stats Bar */
.stats-bar {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  background-color: #f9fafb; /* bg-gray-50 */
  border-bottom: 1px solid #f3f4f6; /* border-gray-100 */
}

.stat-item {
  padding: 1rem; /* p-4 */
  text-align: center;
  border-right: 1px solid #f3f4f6; /* border-gray-100 */
}

.stat-item:last-child {
  border-right: none;
}

.stat-label {
  display: block;
  font-size: 10px; /* text-[10px] */
  color: #9ca3af; /* text-gray-400 */
  text-transform: uppercase;
  font-weight: 700;
  letter-spacing: 0.1em; /* tracking-widest */
}

.stat-value {
  font-family: 'Oswald', sans-serif; /* font-display */
  font-size: 1.5rem; /* text-2xl */
  font-weight: 700;
  display: block;
}

.text-dojo-dark { color: #111; }
.text-green { color: #16a34a; /* text-green-600 */ }
.text-red { color: #e01e1e; /* text-dojo-red */ }

/* Content Grid */
.modal-content-grid {
  padding: 1.5rem; /* p-6 */
  display: grid;
  gap: 2rem; /* gap-8 */
}

@media (min-width: 768px) {
  .modal-content-grid {
    padding: 2rem; /* md:p-8 */
    grid-template-columns: repeat(2, 1fr); /* md:grid-cols-2 */
  }
}

/* Section Titles */
.section-title {
  font-size: 0.75rem; /* text-xs */
  font-weight: 700;
  color: #111827; /* text-gray-900 */
  text-transform: uppercase;
  letter-spacing: 0.1em; /* tracking-widest */
  border-bottom: 1px solid #e5e7eb; /* border-gray-200 */
  padding-bottom: 0.5rem; /* pb-2 */
  margin-bottom: 1rem; /* mb-4 */
  margin-top: 0;
}

.mt-8 { margin-top: 2rem; }

/* Points Breakdown */
.breakdown-list {
  display: flex;
  flex-direction: column;
  gap: 1rem; /* space-y-4 */
}

.breakdown-item {
  display: block;
}

.breakdown-header {
  display: flex;
  justify-content: space-between;
  font-size: 0.75rem; /* text-xs */
  font-weight: 700;
  color: #4b5563; /* text-gray-600 */
  margin-bottom: 0.25rem; /* mb-1 */
}

.progress-bg {
  width: 100%;
  background-color: #f3f4f6; /* bg-gray-100 */
  height: 0.375rem; /* h-1.5 */
  border-radius: 9999px; /* rounded-full */
  overflow: hidden;
}

.progress-bar {
  height: 100%;
}

.bg-blue { background-color: #3b82f6; /* bg-blue-500 */ }
.bg-red { background-color: #e01e1e; /* bg-dojo-red */ }
.bg-green { background-color: #22c55e; /* bg-green-500 */ }

/* Attributes */
.attributes-grid {
  display: flex;
  gap: 1rem; /* gap-4 */
}

.attribute-box {
  flex: 1;
  background-color: #f9fafb; /* bg-gray-50 */
  border-radius: 0.25rem; /* rounded */
  padding: 0.75rem; /* p-3 */
  text-align: center;
  border: 1px solid #f3f4f6; /* border-gray-100 */
}

.attr-label {
  display: block;
  font-size: 10px; /* text-[10px] */
  color: #9ca3af; /* text-gray-400 */
  text-transform: uppercase;
  font-weight: 700;
}

.attr-value {
  font-weight: 700;
  color: #1f2937; /* text-gray-800 */
  display: block;
}

/* Match History */
.match-history-list {
  position: relative;
  border-left: 2px solid #f3f4f6; /* border-gray-100 */
  margin-left: 0.5rem; /* ml-2 */
  display: flex;
  flex-direction: column;
  gap: 1.5rem; /* space-y-6 */
  padding-top: 0.5rem;
  padding-bottom: 0.5rem;
}

.match-item {
  margin-left: 1rem; /* ml-4 */
  position: relative;
}

.match-dot {
  position: absolute;
  left: -1.35rem; /* -left-[21px] approx */
  top: 0.375rem; /* top-1.5 */
  width: 0.75rem; /* w-3 */
  height: 0.75rem; /* h-3 */
  border-radius: 9999px; /* rounded-full */
  border: 2px solid #fff; /* border-white */
}

.match-content {
  display: flex;
  justify-content: space-between;
  align-items: flex-start;
}

.match-opponent {
  font-weight: 700;
  font-size: 0.875rem; /* text-sm */
  color: #1f2937; /* text-gray-800 */
  line-height: 1;
  margin: 0;
}

.match-event {
  font-size: 10px; /* text-[10px] */
  color: #9ca3af; /* text-gray-400 */
  text-transform: uppercase;
  margin-top: 0.25rem; /* mt-1 */
  margin-bottom: 0;
}

.match-result {
  font-size: 0.75rem; /* text-xs */
  font-weight: 700;
  display: block;
  text-align: right;
}

.match-method {
  display: block;
  font-size: 10px; /* text-[10px] */
  color: #9ca3af; /* text-gray-400 */
  text-align: right;
}

/* Footer */
.modal-footer {
  background-color: #f9fafb; /* bg-gray-50 */
  padding: 1rem; /* p-4 */
  border-top: 1px solid #f3f4f6; /* border-gray-100 */
  display: flex;
  justify-content: center;
  align-items: center;
}

.modal-footer-btn {
  background: none;
  border: none;
  font-size: 0.75rem; /* text-xs */
  font-weight: 700;
  color: #6b7280; /* text-gray-500 */
  text-transform: uppercase;
  letter-spacing: 0.1em; /* tracking-widest */
  cursor: pointer;
  transition: color 0.2s;
}

.modal-footer-btn:hover {
  color: #111; /* text-dojo-dark */
}

/* Utility classes for dynamic styles */
.text-center { text-align: center; }
.text-right { text-align: right; }

.loading-text {
  color: #666;
}

.search-results-header {
  text-align: center;
  color: #888;
  padding: 20px;
}

.empty-state {
  text-align: center;
  padding: 30px;
}

.region-badge {
  background: #eee;
  padding: 2px 6px;
  border-radius: 4px;
  font-size: 11px;
  font-weight: 700;
}

/* Region Colors */
.bg-blue-600 { background-color: #2563eb; color: white; }
.bg-orange-500 { background-color: #f97316; color: white; }
.bg-yellow-500 { background-color: #eab308; color: white; }
.bg-green-600 { background-color: #16a34a; color: white; }
.bg-purple-500 { background-color: #a855f7; color: white; }
.bg-gray-500 { background-color: #6b7280; color: white; }


/* Table Header Styles */
.table-header-row {
  display: flex;
  justify-content: space-between;
  align-items: center;
  margin-bottom: 15px;
  padding: 0 10px;
  border-bottom: 1px solid #eee;
  padding-bottom: 10px;
}

.table-title {
  font-family: 'Oswald', sans-serif;
  font-size: 16px;
  font-weight: 700;
  color: #111;
  text-transform: uppercase;
  letter-spacing: 1px;
  margin: 0;
}

.fighter-count {
  font-family: 'Open Sans', sans-serif;
  font-size: 12px;
  color: #888;
  font-weight: 600;
  text-transform: uppercase;
}

