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

body {
  font-family: 'Segoe UI', sans-serif;
  background: #0d1117;
  color: #f0f0f0;
  min-height: 100vh;
}

/* Header */
header {
  background: #0d1117;
  border-bottom: 2px solid #e84e0f;
  padding: 30px 20px;
  text-align: center;
}

.header-logo {
  height: 120px;
  width: auto;
  object-fit: contain;
}

header p {
  margin-top: 10px;
  font-size: 1rem;
  color: #aaa;
  letter-spacing: 1px;
  text-transform: uppercase;
}

/* Filters */
.filters {
  display: flex;
  gap: 20px;
  justify-content: center;
  flex-wrap: wrap;
  padding: 30px 20px;
  background: #10151c;
  border-bottom: 1px solid #1e2530;
}

.filter-group label {
  font-size: 0.85rem;
  text-transform: uppercase;
  letter-spacing: 1px;
  color: #e84e0f;
}

.filter-group select,
.filter-group input[type="text"] {
  background: #161c25;
  color: #f0f0f0;
  border: 1px solid #2a3340;
  border-radius: 8px;
  padding: 10px 16px;
  font-size: 1rem;
  outline: none;
  min-width: 180px;
  transition: border-color 0.2s;
}

.filter-group select {
  cursor: pointer;
}

.filter-group input[type="text"]::placeholder {
  color: #556;
}

.filter-group select:focus,
.filter-group input[type="text"]:focus {
  border-color: #e84e0f;
}

.search-group input[type="text"] {
  min-width: 240px;
}

/* Players grid */
.players-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(260px, 1fr));
  gap: 24px;
  padding: 40px 40px;
  max-width: 1400px;
  margin: 0 auto;
}

/* Player card */
.player-card {
  background: #10151c;
  border-radius: 16px;
  overflow: hidden;
  border: 1px solid #1e2530;
  cursor: pointer;
  transition: transform 0.2s, box-shadow 0.2s;
}

.player-card:hover {
  transform: translateY(-6px);
  box-shadow: 0 12px 30px rgba(232, 78, 15, 0.3);
}

.player-card img {
  width: 100%;
  height: 220px;
  object-fit: contain;
  background: #0d1117;
  padding: 8px;
}

.player-card .card-body {
  padding: 16px;
}

.player-card h3 {
  font-size: 1.2rem;
  margin-bottom: 8px;
}

.badges {
  display: flex;
  gap: 8px;
  flex-wrap: wrap;
  margin-bottom: 10px;
}

.badge {
  font-size: 0.75rem;
  padding: 4px 10px;
  border-radius: 20px;
  font-weight: 600;
  text-transform: uppercase;
  letter-spacing: 0.5px;
}

.badge-position {
  background: #161c25;
  color: #90a0c0;
  border: 1px solid #2a3a55;
}

.badge-club {
  background: #1a1206;
  color: #e8a020;
  border: 1px solid #7a4a00;
}

.player-card p {
  font-size: 0.9rem;
  color: #aaa;
  line-height: 1.5;
  display: -webkit-box;
  -webkit-line-clamp: 3;
  -webkit-box-orient: vertical;
  overflow: hidden;
}

/* No results */
.no-results {
  grid-column: 1 / -1;
  text-align: center;
  color: #666;
  font-size: 1.2rem;
  padding: 60px 0;
}

/* Modal */
.modal {
  position: fixed;
  inset: 0;
  background: rgba(0, 0, 0, 0.75);
  display: flex;
  align-items: center;
  justify-content: center;
  z-index: 100;
  padding: 20px;
}

.modal.hidden {
  display: none;
}

.modal-content {
  background: #10151c;
  border-radius: 20px;
  max-width: 520px;
  width: 100%;
  overflow: hidden;
  position: relative;
  border: 1px solid #1e2530;
}

.modal-content img {
  width: 100%;
  height: 280px;
  object-fit: contain;
  background: #0d1117;
  padding: 10px;
}

.modal-content h2 {
  font-size: 1.6rem;
  margin: 16px 20px 8px;
}

.modal-content .badges {
  padding: 0 20px;
}

.modal-content p {
  padding: 12px 20px;
  color: #bbb;
  line-height: 1.6;
  font-size: 0.95rem;
}

.btn-video {
  display: block;
  margin: 0 20px 20px;
  background: #e84e0f;
  color: white;
  text-align: center;
  padding: 12px;
  border-radius: 10px;
  text-decoration: none;
  font-weight: 600;
  transition: background 0.2s;
}

.btn-video:hover {
  background: #c43d0a;
}

.modal-close {
  position: absolute;
  top: 12px;
  right: 14px;
  background: rgba(0,0,0,0.5);
  border: none;
  color: white;
  font-size: 1.1rem;
  width: 32px;
  height: 32px;
  border-radius: 50%;
  cursor: pointer;
  z-index: 10;
}

/* Player detail page */
.player-page {
  max-width: 1000px;
  margin: 0 auto;
  padding: 40px 24px;
}

.btn-back {
  display: inline-block;
  margin-bottom: 28px;
  color: #e84e0f;
  text-decoration: none;
  font-size: 0.95rem;
  font-weight: 600;
  letter-spacing: 0.5px;
  transition: opacity 0.2s;
}

.btn-back:hover {
  opacity: 0.75;
}

.player-detail {
  display: flex;
  gap: 48px;
  align-items: flex-start;
}

.player-detail-left {
  flex: 0 0 320px;
  display: flex;
  flex-direction: column;
  gap: 16px;
}

.player-detail-left img {
  width: 100%;
  border-radius: 16px;
  object-fit: contain;
  background: #10151c;
  border: 1px solid #1e2530;
  padding: 12px;
}

.player-detail-right {
  flex: 1;
  padding-top: 8px;
}

.player-detail-right h1 {
  font-size: 2rem;
  margin-bottom: 14px;
}

.player-detail-right .badges {
  margin-bottom: 20px;
}

.player-detail-right p {
  color: #bbb;
  line-height: 1.7;
  font-size: 1rem;
}

@media (max-width: 700px) {
  .player-detail {
    flex-direction: column;
    gap: 24px;
  }

  .player-detail-left {
    flex: unset;
    width: 100%;
  }
}

@media (max-width: 600px) {
  .players-grid {
    padding: 20px;
  }

  header h1 {
    font-size: 2rem;
  }
}
