/* Reset y variables CSS */
:root {
  /* Colores principales */
  --primary-color: #dc2626;
  --primary-dark: #b91c1c;
  --primary-light: #fef2f2;
  --primary-hover: #b91c1c;
  
  /* Colores secundarios */
  --secondary-color: #374151;
  --secondary-light: #6b7280;
  --secondary-dark: #1f2937;
  
  /* Colores de fondo */
  --background: #f8fafc;
  --surface: #ffffff;
  --surface-hover: #f9fafb;
  --surface-secondary: #f3f4f6;
  --surface-tertiary: #fefbfb;
  
  /* Colores de texto */
  --text-primary: #1f2937;
  --text-secondary: #6b7280;
  --text-tertiary: #9ca3af;
  --text-muted: #6c757d;
  --text-dark: #212529;
  --text-light: #ffffff;
  
  /* Colores de borde */
  --border: #d8d9dc;
  --border-light: #f1f5f9;
  --border-dark: #e5e7eb;
  --border-dashed: #dee2e6;
  
  /* Colores de estado */
  --success: #10b981;
  --success-light: #d4edda;
  --success-dark: #155724;
  --warning: #f59e0b;
  --warning-light: #fff3cd;
  --warning-dark: #b45309;
  --danger: #ef4444;
  --danger-light: #fef2f2;
  --danger-dark: #b91c1c;
  --info: #007bff;
  --info-light: #cce7ff;
  --info-dark: #004085;
  
  /* Colores especiales */
  --gold: #ffd700;
  --gold-light: #ffed4e;
  --gold-dark: #b45309;
  --purple: #6366f1;
  --purple-light: #e0e7ff;
  --purple-dark: #4338ca;
  
  /* Colores de estado de transacciones */
  --status-pending: #f59e0b;
  --status-success: #10b981;
  --status-failed: #ef4444;
  --status-canceled: #6b7280;
  --status-unknown: #9ca3af;
  
  /* Sombras */
  --shadow: 0 1px 3px 0 rgba(0, 0, 0, 0.1), 0 1px 2px 0 rgba(0, 0, 0, 0.06);
  --shadow-lg: 0 10px 15px -3px rgba(0, 0, 0, 0.1), 0 4px 6px -2px rgba(0, 0, 0, 0.05);
  --shadow-sm: 0 1px 2px 0 rgba(0, 0, 0, 0.05);
  
  /* Bordes y transiciones */
  --border-radius: 8px;
  --border-radius-sm: 4px;
  --border-radius-lg: 12px;
  --transition: all 0.2s ease-in-out;
  --transition-fast: all 0.15s ease-in-out;
  --transition-slow: all 0.3s ease-in-out;
}

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

html {
  font-size: 16px;
  -webkit-text-size-adjust: 100%;
}

body {
  font-family: 'Inter', -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, sans-serif;
  line-height: 1.6;
  color: var(--text-primary);
  background-color: var(--background);
  overflow-x: hidden;
}

/* Loading Screen */
.loading-screen {
  position: fixed;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  background: var(--primary-color);
  display: flex;
  align-items: center;
  justify-content: center;
  z-index: 9999;
}

.loader {
  align-items: center;
  justify-content: center;
  text-align: center;
  color: white;
}

.loader .app-icon {
  align-items: center;
  justify-content: center;
  margin-bottom: 20px;
  animation: pulse 2s infinite;
}

.loader .app-icon img {
  align-items: center;
  justify-content: center;
  max-width: 80px;
  max-height: 80px;
}

.loader .osasuna-shield {
  margin-bottom: 20px;
  animation: pulse 2s infinite;
}

@keyframes pulse {
  0%, 100% { transform: scale(1); }
  50% { transform: scale(1.1); }
}

.loader p {
  font-size: 18px;
  font-weight: 500;
  opacity: 0.9;
}

/* Auth Screen Styles */
.auth-container {
  min-height: 100vh;
  display: flex;
  align-items: center;
  justify-content: center;
  background: linear-gradient(135deg, #dc2626 0%, #b91c1c 100%);
  padding: 15px;
  width: 100%;
}

.auth-card {
  background: #ffffff;
  border-radius: 24px;
  box-shadow: 0 20px 60px rgba(0, 0, 0, 0.15);
  padding: 15px;
  width: 100%;
  text-align: center;
  position: relative;
  overflow: hidden;
}

.auth-card::before {
  content: '';
  position: absolute;
  top: -50px;
  right: -50px;
  width: 100px;
  height: 100px;
  background: linear-gradient(45deg, #fecaca, #fca5a5);
  border-radius: 50%;
  opacity: 0.1;
}

.auth-card::after {
  content: '';
  position: absolute;
  bottom: -30px;
  left: -30px;
  width: 60px;
  height: 60px;
  background: linear-gradient(45deg, #fecaca, #fca5a5);
  border-radius: 50%;
  opacity: 0.1;
}

.auth-header {
  position: relative;
  z-index: 1;
}

.auth-header .app-icon {
  display: inline-block;
  padding: 16px;
}

.auth-header .osasuna-shield {
  display: inline-block;
  padding: 16px;
}

.auth-header h1 {
  font-size: 2.5rem;
  font-weight: 800;
  color: var(--text-primary);
  margin-bottom: 8px;
  background: linear-gradient(135deg, #dc2626, #b91c1c);
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
  background-clip: text;
}

.auth-header p {
  font-size: 1.1rem;
  color: var(--text-secondary);
  margin: 0;
}

.auth-welcome {
  margin-top: 16px;
  text-align: center;
}

.auth-welcome p {
  margin: 0;
  line-height: 1.5;
}

.auth-welcome .welcome-description {
  font-size: 1.2rem;
  font-weight: 600;
  color: var(--text-dark);
  margin-bottom: 8px;
}

.auth-welcome .welcome-subtitle {
  font-size: 0.95rem;
  color: var(--text-secondary);
  opacity: 0.9;
  margin-bottom: 16px;
}

.auth-welcome .welcome-features {
  margin: 16px 0;
}

.auth-welcome .welcome-features p {
  font-size: 0.9rem;
  color: var(--text-secondary);
  margin: 4px 0;
  opacity: 0.8;
}

.auth-welcome .welcome-cta {
  font-size: 1rem;
  font-weight: 600;
  color: var(--primary-color);
  margin-top: 16px;
  margin-bottom: 0;
}

.auth-content {
  position: relative;
  z-index: 1;
}

.auth-loading {
  text-align: center;
  padding: 40px 0;
}

.auth-loading .loader {
  width: 40px;
  height: 40px;
  border: 3px solid #f3f4f6;
  border-top: 3px solid #dc2626;
  border-radius: 50%;
  animation: spin 1s linear infinite;
  margin: 0 auto 16px;
}

@keyframes spin {
  0% { transform: rotate(0deg); }
  100% { transform: rotate(360deg); }
}

.auth-methods {
  text-align: center;
}

.auth-methods h2 {
  font-size: 1.8rem;
  font-weight: 700;
  color: var(--text-primary);
  margin-bottom: 8px;
}

.auth-methods p {
  font-size: 1rem;
  color: var(--text-secondary);
  margin-bottom: 32px;
}

.auth-buttons {
  display: flex;
  flex-direction: column;
  gap: 16px;
}

.auth-btn {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 12px;
  padding: 16px 24px;
  border: 2px solid #e5e7eb;
  border-radius: 12px;
  background: #ffffff;
  color: var(--text-primary);
  font-size: 1rem;
  font-weight: 600;
  text-decoration: none;
  transition: all 0.2s ease;
  cursor: pointer;
  position: relative;
  overflow: hidden;
}

.auth-btn::before {
  content: '';
  position: absolute;
  top: 0;
  left: -100%;
  width: 100%;
  height: 100%;
  background: linear-gradient(90deg, transparent, rgba(255, 255, 255, 0.4), transparent);
  transition: left 0.5s;
}

.auth-btn:hover::before {
  left: 100%;
}

.auth-btn:hover {
  transform: translateY(-2px);
  box-shadow: 0 8px 25px rgba(0, 0, 0, 0.1);
}

.auth-btn.phone-btn {
  border-color: #10b981;
  color: #10b981;
}

.auth-btn.phone-btn:hover {
  background: #10b981;
  color: white;
}

.auth-btn.email-btn {
  border-color: #3b82f6;
  color: #3b82f6;
}

.auth-btn.email-btn:hover {
  background: #3b82f6;
  color: white;
}

.auth-btn.google-btn {
  border-color: #ea4335;
  color: #ea4335;
}

.auth-btn.google-btn:hover {
  background: #ea4335;
  color: white;
}

.auth-phone,
.auth-email,
.auth-verification,
.auth-success {
  text-align: center;
}

.auth-phone h2,
.auth-email h2,
.auth-verification h2,
.auth-success h2 {
  font-size: 1.8rem;
  font-weight: 700;
  color: var(--text-primary);
  margin-bottom: 8px;
  text-align: center;
}

.auth-phone p,
.auth-email p,
.auth-verification p,
.auth-success p {
  font-size: 1rem;
  color: var(--text-secondary);
  margin-bottom: 24px;
}

.auth-success .success-icon {
  margin-bottom: 24px;
}

.auth-success .success-icon i {
  font-size: 4rem;
  color: #10b981;
  animation: pulse 2s infinite;
}

@keyframes pulse {
  0% { transform: scale(1); }
  50% { transform: scale(1.1); }
  100% { transform: scale(1); }
}

.form-group {
  margin-bottom: 24px;
}

.form-control {
  width: 100%;
  padding: 16px 20px;
  border: 2px solid #e5e7eb;
  border-radius: 12px;
  font-size: 1rem;
  transition: all 0.2s ease;
  background: #ffffff;
}

.form-control:focus {
  outline: none;
  border-color: #dc2626;
  box-shadow: 0 0 0 3px rgba(220, 38, 38, 0.1);
}

.form-actions {
  display: flex;
  gap: 12px;
  justify-content: center;
}

.form-actions .btn {
  padding: 12px 24px;
  border-radius: 8px;
  font-size: 1rem;
  font-weight: 600;
  cursor: pointer;
  transition: all 0.2s ease;
  border: none;
}

.btn-primary {
  background: #dc2626;
  color: white;
}

.btn-primary:hover {
  background: #b91c1c;
  transform: translateY(-1px);
}

.btn-secondary {
  background: #f3f4f6;
  color: var(--text-primary);
}

.btn-secondary:hover {
  background: #e5e7eb;
  transform: translateY(-1px);
}

@media (max-width: 480px) {
  .auth-card {
    padding: 15px;
    margin: 0px;
  }
  
  .auth-header h1 {
    font-size: 2rem;
  }
  
  .form-actions {
    flex-direction: column;
  }
  
  .form-actions .btn {
    width: 100%;
  }
}

/* Main App Layout */
.main-app {
  min-height: 100vh;
  display: flex;
  flex-direction: column;
}

.content-container {
  flex: 1;
  padding-bottom: 80px; /* Espacio para navegación inferior */
}

.content-screen {
  display: none;
  padding: 20px;
  max-width: 1200px;
  margin: 0 auto;
}

.content-screen.active {
  display: block;
}

/* Bottom Navigation */
.bottom-nav {
  position: fixed;
  bottom: 0;
  left: 0;
  right: 0;
  background: var(--surface);
  border-top: 1px solid var(--border);
  display: flex;
  padding: 8px 0;
  z-index: 100;
}

.nav-item {
  flex: 1;
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 4px;
  padding: 8px;
  border: none;
  background: transparent;
  color: var(--text-secondary);
  cursor: pointer;
  transition: var(--transition);
  font-size: 12px;
}

.nav-item.active {
  color: var(--primary-color);
}

.nav-item:hover {
  color: var(--primary-color);
  background: rgba(220, 38, 38, 0.1);
}

/* Headers */
.app-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  margin-bottom: 0px;
  padding: 20px 0;
}

.user-info {
  display: flex;
  align-items: center;
  gap: 5px;
}

.user-shield {
  width: 50px;
  height: 60px;
  display: flex;
  align-items: center;
  justify-content: center;
}

.user-shield svg {
  width: 100%;
  height: 100%;
  object-fit: contain;
}

.user-info h2 {
  font-size: 26px;
  font-weight: 600;
  margin-bottom: 2px;
}

.user-info p {
  color: var(--text-secondary);
  font-size: 14px;
}

/* Header Actions Container */
.header-actions {
  display: flex;
  align-items: center;
  gap: 12px;
}

/* Team Selector */
.team-selector-container {
  position: relative;
}

.team-selector-btn {
  display: flex;
  align-items: center;
  gap: 8px;
  background: var(--surface);
  border: 2px solid var(--border);
  border-radius: var(--border-radius);
  padding: 8px 12px;
  cursor: pointer;
  transition: var(--transition);
  font-size: 14px;
}

.team-selector-btn:hover {
  border-color: var(--primary-color);
  box-shadow: var(--shadow);
}

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

.current-team-logo {
  width: 24px;
  height: 24px;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 12px;
  overflow: hidden;
}

.current-team-logo img {
  width: 100%;
  height: 100%;
  object-fit: cover;
}

.current-team-name {
  font-weight: 500;
  color: var(--text-primary);
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
  max-width: 100px;
}

.team-selector-btn svg {
  color: var(--text-secondary);
  transition: var(--transition);
  flex-shrink: 0;
}

.team-selector-btn:hover svg {
  color: var(--primary-color);
}

/* Team Selector Dropdown */
.team-selector-dropdown {
  position: absolute;
  top: 100%;
  right: 0;
  background: var(--surface);
  border: 2px solid var(--border);
  border-radius: var(--border-radius);
  box-shadow: var(--shadow-lg);
  min-width: 280px;
  max-height: 400px;
  overflow-y: auto;
  z-index: 1000;
  margin-top: 4px;
  display: none;
}

.team-selector-dropdown.show {
  display: block;
}

.dropdown-header {
  padding: 16px;
  border-bottom: 1px solid var(--border);
  background: var(--background);
}

.dropdown-header h3 {
  font-size: 16px;
  font-weight: 600;
  margin-bottom: 4px;
  color: var(--text-primary);
}

.dropdown-header p {
  font-size: 14px;
  color: var(--text-secondary);
}

.dropdown-section {
  padding: 12px 0;
}

.dropdown-section:not(:last-child) {
  border-bottom: 1px solid var(--border);
}

.dropdown-section-title {
  padding: 12px 16px 8px;
  font-size: 14px;
  font-weight: 600;
  color: var(--text-secondary);
  text-transform: uppercase;
  letter-spacing: 0.5px;
  display: flex;
  align-items: center;
  gap: 8px;
  background: var(--background);
  border-bottom: 1px solid var(--border);
  margin-bottom: 4px;
}

.dropdown-section-title i {
  font-size: 12px;
  opacity: 0.8;
}

.dropdown-section-title i.fa-trophy {
  color: #ffd700;
}

.dropdown-section-title i.fa-medal {
  color: #c0c0c0;
}

.team-option {
  display: flex;
  align-items: center;
  gap: 12px;
  padding: 12px 16px;
  cursor: pointer;
  transition: var(--transition);
  border: none;
  background: none;
  width: 100%;
  text-align: left;
}

.team-option:hover {
  background: var(--background);
}

.team-option.current {
  background: rgba(220, 38, 38, 0.1);
  color: var(--primary-color);
}

.team-option-logo {
  width: 32px;
  height: 32px;
  overflow: hidden;
  display: flex;
  align-items: center;
  justify-content: center;
  flex-shrink: 0;
}

.team-option-logo img {
  width: 100%;
  height: 100%;
  object-fit: cover;
}

.team-option-info {
  flex: 1;
  min-width: 0;
  text-align: center;
}

.team-option-name {
  font-weight: 500;
  margin-bottom: 2px;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
  text-align: center;
}

.team-option-fantasy-name {
  font-size: 12px;
  color: var(--text-secondary);
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

.add-team-btn {
  display: flex;
  align-items: center;
  gap: 12px;
  padding: 16px;
  background: var(--primary-color);
  color: white;
  border: none;
  cursor: pointer;
  transition: var(--transition);
  font-weight: 500;
  width: 100%;
}

.add-team-btn:hover {
  background: var(--primary-dark);
}

.add-team-btn svg {
  width: 20px;
  height: 20px;
}

.notification-btn {
  background: transparent;
  border: none;
  padding: 8px;
  border-radius: 50%;
  cursor: pointer;
  color: var(--text-secondary);
  transition: var(--transition);
}

.notification-btn:hover {
  background: var(--background);
  color: var(--primary-color);
}

/* Notificaciones */
.notifications-screen {
  max-width: 100%;
  margin: 0 auto;
  padding: 20px;
  background: var(--surface);
  border-radius: var(--border-radius);
  box-shadow: var(--shadow);
}

.notifications-header {
  display: flex;
  justify-content: space-between;
  align-items: center;
  margin-bottom: 25px;
  padding-bottom: 20px;
  border-bottom: 2px solid var(--border);
}

.notifications-header h2 {
  font-size: 28px;
  font-weight: 700;
  margin: 0;
  color: var(--text-primary);
  display: flex;
  align-items: center;
  gap: 10px;
}

.notifications-header h2::before {
  content: '🔔';
  font-size: 24px;
}

.notifications-list {
  max-height: 400px;
  overflow-y: auto;
  padding: 0 5px;
}

.notification-item {
  display: flex;
  align-items: flex-start;
  padding: 18px 20px;
  margin-bottom: 12px;
  border-radius: 12px;
  border: 1px solid var(--border);
  transition: all 0.3s ease;
  background: white;
}

.notification-item:hover {
  background-color: var(--background);
  transform: translateY(-2px);
  box-shadow: 0 4px 12px rgba(0, 0, 0, 0.1);
}

.notification-item.unread {
  background: linear-gradient(135deg, rgba(220, 38, 38, 0.08) 0%, rgba(220, 38, 38, 0.03) 100%);
  border-left: 4px solid #dc2626;
  border-color: #dc2626;
  box-shadow: 0 2px 8px rgba(220, 38, 38, 0.15);
}

.notification-item.read {
  opacity: 0.8;
  background: #f8f9fa;
}

.notification-icon {
  font-size: 24px;
  margin-right: 18px;
  margin-top: 2px;
  width: 40px;
  height: 40px;
  display: flex;
  align-items: center;
  justify-content: center;
  background: var(--background);
  border-radius: 50%;
  flex-shrink: 0;
}

.notification-content {
  flex: 1;
  min-width: 0;
  padding: 2px 0;
}

.notification-title {
  font-weight: 700;
  font-size: 15px;
  margin-bottom: 6px;
  color: var(--text-primary);
  line-height: 1.3;
}

.notification-message {
  font-size: 14px;
  color: var(--text-secondary);
  margin-bottom: 10px;
  line-height: 1.5;
}

.notification-time {
  font-size: 12px;
  color: var(--text-secondary);
  font-weight: 500;
  opacity: 0.8;
}

.notification-actions {
  display: flex;
  gap: 10px;
  margin-left: 15px;
  align-items: flex-start;
  flex-shrink: 0;
}

.notification-actions .btn-xs {
  padding: 6px 12px;
  font-size: 12px;
  border-radius: 8px;
  font-weight: 600;
  transition: all 0.2s ease;
}

.notification-actions .btn-xs:hover {
  transform: translateY(-1px);
  box-shadow: 0 2px 8px rgba(0, 0, 0, 0.15);
}

/* Pantalla de solicitudes de liga */
.league-requests-screen {
  max-width: 100%;
  margin: 0 auto;
  padding: 20px;
  background: var(--surface);
  border-radius: var(--border-radius);
  box-shadow: var(--shadow);
}

.league-requests-screen h2 {
  font-size: 28px;
  font-weight: 700;
  margin-bottom: 25px;
  color: var(--text-primary);
  display: flex;
  align-items: center;
  gap: 10px;
}

.league-requests-screen h2::before {
  content: '🏆';
  font-size: 24px;
}

.league-requests-list {
  max-height: 400px;
  overflow-y: auto;
  padding: 0 5px;
}

.league-request-item {
  background: white;
  border-radius: 16px;
  padding: 20px;
  margin-bottom: 20px;
  box-shadow: 0 2px 12px rgba(0, 0, 0, 0.08);
  border: 1px solid var(--border);
  transition: all 0.3s ease;
}

.league-request-item:hover {
  transform: translateY(-2px);
  box-shadow: 0 4px 20px rgba(0, 0, 0, 0.12);
}

.league-info h3 {
  font-size: 18px;
  font-weight: 700;
  margin-bottom: 8px;
  color: var(--text-primary);
  display: flex;
  align-items: center;
  gap: 8px;
}

.league-info h3::before {
  content: '🏆';
  font-size: 16px;
}

.league-info p {
  font-size: 14px;
  color: var(--text-secondary);
  margin-bottom: 20px;
  font-weight: 500;
}

.requests-list {
  border-top: 2px solid var(--border);
  padding-top: 20px;
}

.request-item {
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding: 15px 0;
  border-bottom: 1px solid var(--border);
  transition: all 0.2s ease;
}

.request-item:hover {
  background: var(--background);
  margin: 0 -10px;
  padding: 15px 10px;
  border-radius: 8px;
}

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

.user-info .username {
  font-weight: 600;
  color: var(--text-primary);
  font-size: 15px;
}

.request-actions {
  display: flex;
  gap: 10px;
}

.request-actions .btn-xs {
  padding: 8px 16px;
  font-size: 13px;
  border-radius: 8px;
  font-weight: 600;
  transition: all 0.2s ease;
}

.request-actions .btn-xs:hover {
  transform: translateY(-1px);
  box-shadow: 0 2px 8px rgba(0, 0, 0, 0.15);
}

.btn-success {
  background: #28a745;
  color: white;
}

.btn-success:hover {
  background: #218838;
}

.btn-danger {
  background: #dc3545;
  color: white;
}

.btn-danger:hover {
  background: #c82333;
}

/* Responsive */
@media (max-width: 768px) {
  .notifications-screen,
  .league-requests-screen {
    padding: 15px;
  }
  
  .notifications-header {
    flex-direction: column;
    align-items: flex-start;
    gap: 15px;
  }
  
  .notifications-header h2 {
    font-size: 24px;
  }
  
  .notification-item {
    flex-direction: column;
    gap: 15px;
    padding: 15px;
  }
  
  .notification-actions {
    margin-left: 0;
    justify-content: flex-end;
    width: 100%;
  }
  
  .request-item {
    flex-direction: column;
    align-items: flex-start;
    gap: 15px;
  }
  
  .request-actions {
    width: 100%;
    justify-content: flex-end;
  }
  
  .league-requests-screen h2 {
    font-size: 24px;
  }
  
  .league-request-item {
    padding: 15px;
  }
}

.screen-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  margin-bottom: 30px;
  padding-bottom: 15px;
  border-bottom: 1px solid var(--border);
}

.screen-header h2 {
  font-size: 28px;
  font-weight: 600;
}

/* Quick Stats */
.quick-stats {
  display: flex;
  flex-direction: row;
  justify-content: space-between;
  align-items: stretch;
  gap: 10px;
  margin-bottom: 18px;
}
.quick-stats .stat-card {
  flex: 1 1 0;
  min-width: 0;
  text-align: center;
  background: var(--surface);
  border-radius: var(--border-radius);
  box-shadow: var(--shadow);
  padding: 10px 2px 8px 2px;
  font-size: 0.8em;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
}
@media (max-width: 600px) {
  .quick-stats {
    flex-direction: row;
    gap: 4px;
    margin-bottom: 10px;
  }
  .quick-stats .stat-card {
    padding: 6px 0 4px 0;
    font-size: 0.8em;
    min-width: 0;
  }
}

/* Sections */
.section {
  background: var(--surface);
  border-radius: var(--border-radius);
  box-shadow: var(--shadow);
  padding: 25px;
  margin-bottom: 20px;
}

.section h3 {
  font-size: 20px;
  font-weight: 600;
  margin-bottom: 20px;
  color: var(--text-primary);
}

.empty-state {
  text-align: center;
  padding: 40px 20px;
  color: var(--text-secondary);
}

.empty-state p {
  margin-bottom: 15px;
  font-size: 16px;
}

/* Team Status */
.team-status .status-message {
  text-align: center;
  padding: 30px;
  background: var(--warning);
  color: white;
  border-radius: var(--border-radius);
}

.team-status .status-message.success {
  background: var(--success);
}

.team-status .status-message p {
  margin-bottom: 15px;
  font-size: 16px;
}

/* Player Selection */
.selected-team {
  background: var(--surface);
  border-radius: var(--border-radius);
  box-shadow: var(--shadow);
  padding: 25px;
  margin-bottom: 25px;
}

.selected-team h3 {
  margin-bottom: 20px;
  font-size: 20px;
  font-weight: 600;
}

.team-grid {
  display: grid;
  gap: 15px;
  margin-bottom: 25px;
}

.player-slot {
  background: var(--background);
  border: 2px dashed var(--border);
  border-radius: var(--border-radius);
  padding: 20px;
  text-align: center;
  cursor: pointer;
  transition: var(--transition);
  min-height: 80px;
  display: flex;
  align-items: center;
  justify-content: center;
}

.player-slot.empty {
  color: var(--text-secondary);
}

.player-slot.filled {
  background: var(--surface);
  border: 2px solid var(--primary-color);
  border-style: solid;
}

.player-slot.captain {
  background: linear-gradient(135deg, var(--primary-color), var(--primary-dark));
  color: white;
  position: relative;
}

.player-slot.captain::after {
  content: "👑";
  position: absolute;
  top: 5px;
  right: 10px;
  font-size: 16px;
}

.player-slot:hover {
  border-color: var(--primary-color);
  background: rgba(220, 38, 38, 0.05);
}

/* Filter Tabs */
.filter-tabs {
  display: flex;
  background: var(--surface);
  border-radius: var(--border-radius);
  padding: 5px;
  margin-bottom: 20px;
  overflow-x: auto;
  gap: 5px;
}

.filter-tab {
  flex: 1;
  padding: 10px 15px;
  border: none;
  background: transparent;
  border-radius: calc(var(--border-radius) - 3px);
  cursor: pointer;
  transition: var(--transition);
  font-size: 14px;
  font-weight: 500;
  white-space: nowrap;
}

.filter-tab.active {
  background: var(--primary-color);
  color: white;
}

.filter-tab:hover:not(.active) {
  background: var(--background);
}

/* Players List */
.available-players {
  display: grid;
  gap: 12px;
  max-height: 400px;
  overflow-y: auto;
}

.player-card {
  display: flex;
  flex-direction: column;
  align-items: center;
  background: #fff;
  border-radius: 16px;
  box-shadow: 0 2px 8px rgba(0,0,0,0.07);
  padding: 16px 8px 12px 8px;
  margin: 8px;
  width: 120px;
  min-height: 150px;
  position: relative;
  transition: box-shadow 0.2s;
  justify-content: flex-start;
}
.player-card.filled {
  border: 2px solid #e0e0e0;
}
.player-card.captain {
  border: 2.5px solid var(--primary-color);
}
.player-avatar-large {
  width: 72px;
  height: 72px;
  border-radius: 50%;
  overflow: hidden;
  background: var(--surface-tertiary);
  display: flex;
  align-items: center;
  justify-content: center;
  position: relative;
}
.player-avatar-large img {
  width: 100%;
  height: 100%;
  object-fit: cover;
}
.captain-badge {
  position: absolute;
  bottom: -10px;
  right: -10px;
  background: var(--gold);
  color: var(--text-light);
  font-size: 0.85em;
  font-weight: bold;
  border-radius: 12px;
  padding: 2px 8px;
  box-shadow: 0 1px 4px rgba(0,0,0,0.10);
  display: flex;
  align-items: center;
  gap: 4px;
}
.player-name-large {
  margin-top: 8px;
  font-size: 0.9em;
  font-weight: 500;
  color: var(--text-dark);
  text-align: center;
  line-height: 1.18;
  max-width: 100px;
  white-space: normal;
  overflow: hidden;
  text-overflow: ellipsis;
  display: -webkit-box;
  -webkit-line-clamp: 2;
  -webkit-box-orient: vertical;
  word-break: break-word;
  min-height: 2.3em;
}
.player-card.empty {
  border: 2px dashed var(--border-dashed);
  background: var(--surface-secondary);
}
.player-selection-placeholder {
  font-size: 2.5em;
  color: var(--text-tertiary);
}

.player-card.empty {
  border-color: var(--primary-color);
}


.player-card:hover {
  border-color: var(--primary-color);
  transform: translateY(-1px);
  box-shadow: var(--shadow);
}

.player-card.selected {
  border-color: var(--primary-color);
  background: rgba(220, 38, 38, 0.05);
}

.player-card.disabled {
  opacity: 0.5;
  cursor: not-allowed;
}

.player-avatar {
  width: 60px;
  height: 60px;
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  background: #f5f5f5;
  margin-right: 1rem;
  overflow: hidden;
}

.player-photo {
  width: 100%;
  height: 100%;
  object-fit: cover;
  border-radius: 50%;
}

.player-photo-placeholder {
  width: 100%;
  height: 100%;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 1.5rem;
  background: #e0e0e0;
  border-radius: 50%;
}

.player-info {
  flex: 1;
}

.player-info h4 {
  font-size: 16px;
  font-weight: 600;
  margin-bottom: 2px;
}

.player-info p {
  font-size: 14px;
  color: var(--text-secondary);
}

.player-stats {
  text-align: right;
  font-size: 12px;
  color: var(--text-secondary);
}

/* Rankings y pestañas mejoradas */
.ranking-tabs {
  display: flex;
  gap: 8px;
  flex-wrap: nowrap;
  align-items: center;
  overflow-x: auto;
  overflow-y: hidden;
  padding: 8px 0 16px 0;
  scroll-behavior: smooth;
  -webkit-overflow-scrolling: touch;
  /* Scrollbar más visible y atractiva */
  scrollbar-width: thin;
  scrollbar-color: rgba(220, 38, 38, 0.4) rgba(248, 250, 252, 0.8);
}

.ranking-tabs::-webkit-scrollbar {
  height: 6px;
}

.ranking-tabs::-webkit-scrollbar-track {
  background: rgba(248, 250, 252, 0.8);
  border-radius: 3px;
}

.ranking-tabs::-webkit-scrollbar-thumb {
  background: rgba(220, 38, 38, 0.4);
  border-radius: 3px;
  transition: background 0.3s ease;
}

.ranking-tabs::-webkit-scrollbar-thumb:hover {
  background: rgba(220, 38, 38, 0.6);
}

.tab-btn {
  padding: 12px 20px;
  border: 2px solid #e5e7eb;
  background: #ffffff;
  border-radius: 12px;
  cursor: pointer;
  transition: all 0.3s ease;
  font-size: 15px;
  font-weight: 600;
  white-space: nowrap;
  flex-shrink: 0;
  min-width: fit-content;
  position: relative;
  color: #64748b;
  box-shadow: 0 1px 3px rgba(0, 0, 0, 0.05);
  user-select: none;
  display: flex;
  align-items: center;
  gap: 6px;
}

.tab-btn:hover:not(.active) {
  background: #f8fafc;
  border-color: var(--primary-color);
  color: var(--primary-color);
  transform: translateY(-1px);
  box-shadow: 0 4px 12px rgba(220, 38, 38, 0.15);
}

.tab-btn.active {
  background: var(--primary-color);
  color: white;
  border-color: var(--primary-color);
  transform: translateY(-1px);
  box-shadow: 0 4px 16px rgba(220, 38, 38, 0.25);
  font-weight: 700;
}

/* Estilos específicos para pestañas de ligas privadas */
.tab-btn.league-tab {
  background: #f8fafc;
  border-color: #6366f1;
  color: #6366f1;
  position: relative;
  max-width: 180px;
  overflow: hidden;
  text-overflow: ellipsis;
}

.tab-btn.league-tab:before {
  content: "🏆";
  font-size: 14px;
  flex-shrink: 0;
}

.tab-btn.league-tab:hover:not(.active) {
  background: rgba(99, 102, 241, 0.08);
  border-color: #6366f1;
  color: #6366f1;
  transform: translateY(-1px);
  box-shadow: 0 4px 12px rgba(99, 102, 241, 0.15);
}

.tab-btn.league-tab.active {
  background: #6366f1;
  color: white;
  border-color: #6366f1;
  transform: translateY(-1px);
  box-shadow: 0 4px 16px rgba(99, 102, 241, 0.25);
}

/* Separador visual entre tipos de pestañas */
.tab-separator {
  width: 2px;
  height: 28px;
  background: linear-gradient(to bottom, transparent, #e5e7eb, transparent);
  margin: 0 6px;
  flex-shrink: 0;
  border-radius: 1px;
}

/* Indicador visual cuando hay scroll disponible */
.ranking-tabs:after {
  content: "";
  position: absolute;
  right: 0;
  top: 8px;
  bottom: 16px;
  width: 24px;
  background: linear-gradient(to left, rgba(255, 255, 255, 0.9), transparent);
  pointer-events: none;
  opacity: 0;
  transition: opacity 0.3s ease;
  z-index: 1;
  border-radius: 0 12px 12px 0;
}

.ranking-tabs.has-overflow:after {
  opacity: 1;
}

/* Pestañas para friends (heredan el mismo estilo) */
.friends-tabs {
  display: flex;
  gap: 8px;
  align-items: center;
  padding: 8px 0 16px 0;
  border-bottom: 2px solid #f1f5f9;
  margin-bottom: 20px;
  background: #ffffff;
  border-radius: 12px 12px 0 0;
}

.friends-tabs .tab-btn {
  padding: 14px 24px;
  font-size: 16px;
  border-radius: 10px;
  min-width: 120px;
  justify-content: center;
}

/* Responsive para pestañas */
@media (max-width: 768px) {
  .ranking-tabs {
    gap: 6px;
    padding: 6px 0 12px 0;
  }
  
  .tab-btn {
    padding: 10px 16px;
    font-size: 14px;
    min-width: fit-content;
    border-radius: 10px;
  }
  
  .tab-btn.league-tab {
    max-width: 160px;
  }
  
  .tab-btn.league-tab:before {
    font-size: 12px;
  }
  
  .friends-tabs .tab-btn {
    padding: 12px 20px;
    font-size: 15px;
    min-width: 100px;
  }
}

@media (max-width: 480px) {
  .ranking-tabs {
    gap: 4px;
    padding: 4px 0 10px 0;
  }
  
  .tab-btn {
    padding: 8px 14px;
    font-size: 13px;
    border-radius: 8px;
  }
  
  .tab-btn.league-tab {
    max-width: 140px;
  }
  
  .tab-btn.league-tab:before {
    font-size: 11px;
  }
  
  .friends-tabs .tab-btn {
    padding: 10px 16px;
    font-size: 14px;
    min-width: 80px;
  }
  
  .tab-separator {
    height: 24px;
    margin: 0 4px;
  }
}

.ranking-list {
  display: grid;
  gap: 12px;
}

.league-view-controls {
  padding: 1rem;
  background: var(--surface);
}

.league-view-controls h4 {
  margin: 0 0 0.75rem 0;
  font-size: 0.85rem;
  color: var(--text-secondary);
  font-weight: 500;
  text-transform: uppercase;
  letter-spacing: 0.5px;
}

.view-toggle {
  display: flex;
  gap: 1.5rem;
  align-items: center;
}

.view-toggle .btn {
  padding: 0.5rem 0;
  font-size: 0.9rem;
  border: none;
  background: transparent;
  color: var(--text-secondary);
  font-weight: 400;
  cursor: pointer;
  transition: color 0.3s ease;
  position: relative;
  text-align: center;
  white-space: nowrap;
  box-shadow: none !important;
}

.view-toggle .btn::after {
  content: '';
  position: absolute;
  bottom: 0;
  left: 0;
  width: 0;
  height: 2px;
  background: var(--primary-color);
  transition: width 0.3s ease;
}

.view-toggle .btn:hover {
  color: var(--primary-color);
}

.view-toggle .btn.btn-primary {
  background: transparent;
  color: var(--primary-color);
  font-weight: 600;
}

.view-toggle .btn.btn-primary::after {
  width: 100%;
}

.view-toggle .btn.btn-primary:hover {
  color: #dc2626;
}

.view-toggle .btn.btn-primary:hover::after {
  background: #dc2626;
}

.view-toggle .btn.btn-secondary {
  background: transparent;
  color: var(--text-secondary);
}

.view-toggle .btn.btn-secondary:hover {
  color: var(--text-primary);
}

@media (max-width: 768px) {
  .league-view-controls {
    padding: 0.75rem;
  }
  
  .league-view-controls h4 {
    font-size: 0.8rem;
    margin-bottom: 0.5rem;
  }
  
  .view-toggle {
    justify-content: center;
    gap: 1rem;
    flex-wrap: wrap;
  }
  
  .view-toggle .btn {
    padding: 0.4rem 0;
    font-size: 0.85rem;
  }
}

@media (max-width: 480px) {
  .view-toggle {
    gap: 0.75rem;
  }
  
  .view-toggle .btn {
    font-size: 0.8rem;
  }
}

.ranking-item {
  background: var(--surface);
  border-radius: var(--border-radius);
  box-shadow: var(--shadow);
  padding: 10px;
  display: flex;
  align-items: center;
  gap: 5px;
  position: relative;
  min-height: 4rem;
}

.ranking-item.current-user {
  border: 2px solid var(--primary-color);
  background: rgba(220, 38, 38, 0.05);
}

.ranking-item.outside-top-50 {
  background-color: var(--primary-light);
  border-left: 3px solid var(--primary);
  margin-top: 1rem;
  border-top: 1px solid var(--border);
  padding-top: 1rem;
}

.ranking-position {
  width: 40px;
  height: 40px;
  border-radius: 50%;
  background: var(--background);
  display: flex;
  align-items: center;
  justify-content: center;
  font-weight: bold;
  font-size: 18px;
}

.ranking-position.top3 {
  background: linear-gradient(135deg, #ffd700, #ffed4e);
  color: #b45309;
}

.ranking-info {
  flex: 1;
}

.ranking-info h4 {
  font-size: 16px;
  font-weight: 600;
  margin-bottom: 2px;
}

.ranking-info p {
  font-size: 14px;
  color: var(--text-secondary);
}

.ranking-right-section {
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: 0rem;
  flex-shrink: 0;
  min-width: 40px;
  max-width: 60px;
}

.ranking-points {
  text-align: center;
  display: flex;
  flex-direction: row;
  align-items: center;
  justify-content: center;
  gap: 0.3rem;
}

.ranking-points .points {
  font-size: 24px;
  font-weight: 700;
  color: var(--primary-color);
}

.ranking-points .label {
  font-size: 12px;
  color: var(--text-secondary);
}

/* Friends */
.friends-list {
  display: grid;
  gap: 12px;
}

.friend-item {
  background: var(--surface);
  border-radius: var(--border-radius);
  box-shadow: var(--shadow);
  padding: 20px;
  display: flex;
  align-items: center;
  gap: 15px;
}

.friend-shield {
  width: 40px;
  height: 48px;
}

.friend-info {
  flex: 1;
}

.friend-info h4 {
  font-size: 16px;
  font-weight: 600;
  margin-bottom: 2px;
}

.friend-info p {
  font-size: 14px;
  color: var(--text-secondary);
}

.friend-actions {
  display: flex;
  gap: 8px;
}

.friend-actions .btn {
  width: auto;
  padding: 8px 12px;
  font-size: 14px;
  margin: 0;
}

/* Modals */
.modal-overlay {
  position: fixed;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  background: rgba(0, 0, 0, 0.5);
  display: flex;
  align-items: center;
  justify-content: center;
  z-index: 1000;
  padding: 20px;
}

.modal {
  background: var(--surface);
  border-radius: 20px;
  box-shadow: 0 10px 40px rgba(0, 0, 0, 0.2);
  width: 100%;
  max-width: 500px;
  max-height: 90vh;
  overflow-y: auto;
  border: 1px solid var(--border);
}

.modal-header {
  padding: 25px 25px 10px;
  border-bottom: 1px solid var(--border);
  margin-bottom: 20px;
  position: relative;
}

.modal-header h3 {
  font-size: 20px;
  font-weight: 600;
  margin-bottom: 15px;
}

.modal-close-btn {
  position: absolute;
  top: 15px;
  right: 20px;
  background: none;
  border: none;
  font-size: 24px;
  font-weight: bold;
  color: var(--text-secondary);
  cursor: pointer;
  padding: 8px;
  border-radius: 6px;
  transition: all 0.2s ease;
  line-height: 1;
  width: 40px;
  height: 40px;
  display: flex;
  align-items: center;
  justify-content: center;
}

.modal-close-btn:hover {
  background: var(--surface);
  color: var(--text-primary);
}

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

.modal-actions {
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: 10px;
  margin-top: 20px;
}

.modal-actions-left {
  display: flex;
  gap: 10px;
}

.modal-actions-right {
  display: flex;
  gap: 10px;
}

.modal-actions .btn {
  margin: 0;
}

/* Profile */
.shield-customizer {
  display: flex;
  flex-direction: column;
  gap: 1rem;
  padding: 1rem;
}
.shield-preview{
  text-align: center;
}
/* Vista previa principal con navegación */
.shield-preview-section {
  display: flex;
  justify-content: center;
  margin-bottom: 2rem;
}

.shield-preview-container {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 1rem;
  padding: 2rem;
  border-radius: 16px;
  border: 1px solid #dee2e6;
  box-shadow: 0 4px 12px rgba(0, 0, 0, 0.05);
}

.shield-preview-navigation {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 2rem;
  width: 100%;
  max-width: 400px;
}

.shield-preview-main {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 1rem;
  flex: 1;
}

.shield-preview-large {
  display: flex;
  justify-content: center;
  align-items: center;
  padding: 1.5rem;
  transition: all 0.3s ease;
}

.shield-preview-large:hover {
  transform: translateY(-2px);
}

.shield-preview-info {
  text-align: center;
}

.shield-counter {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 0.25rem;
  margin-bottom: 0.5rem;
}

.shield-number {
  font-size: 1.1rem;
  color: #495057;
  font-weight: 600;
}

.shield-total {
  font-size: 0.875rem;
  color: #6c757d;
}

.shield-preview-info p {
  margin: 0;
  color: #6c757d;
  font-size: 0.9rem;
  font-style: italic;
}

/* Controles de personalización */
.shield-controls {
  display: flex;
  flex-direction: column;
  gap: 2rem;
}

.control-section {
  background: white;
  border-radius: 12px;
  padding: 1.5rem;
  border: 1px solid #e9ecef;
  box-shadow: 0 2px 8px rgba(0, 0, 0, 0.05);
}

.section-header {
  margin-bottom: 1.5rem;
}

.section-header h4 {
  margin: 0 0 0.5rem 0;
  color: #495057;
  font-weight: 600;
  font-size: 1.1rem;
  display: flex;
  align-items: center;
  gap: 0.5rem;
}

.section-header p {
  margin: 0;
  color: #6c757d;
  font-size: 0.9rem;
}

/* Navegación de escudos mejorada */
.shape-navigation {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 1rem;
  padding: 1.5rem;
  background: linear-gradient(135deg, #f8f9fa 0%, #e9ecef 100%);
  border-radius: 12px;
  border: 1px solid #dee2e6;
}

.nav-btn {
  background: white;
  border: 2px solid #e5e7eb;
  border-radius: 50%;
  width: 56px;
  height: 56px;
  display: flex;
  align-items: center;
  justify-content: center;
  cursor: pointer;
  transition: all 0.3s ease;
  font-size: 1.4rem;
  font-weight: bold;
  color: #6b7280;
  box-shadow: 0 4px 8px rgba(0, 0, 0, 0.1);
  flex-shrink: 0;
}

.nav-btn:hover {
  background: #f3f4f6;
  border-color: #d1d5db;
  color: #374151;
  transform: scale(1.1);
  box-shadow: 0 6px 12px rgba(0, 0, 0, 0.15);
}

.nav-btn:active {
  transform: scale(0.95);
}

.nav-btn:disabled {
  opacity: 0.5;
  cursor: not-allowed;
  transform: none;
}

.current-shield-info {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 0.75rem;
  flex: 1;
}

.shield-preview-mini {
  width: 48px;
  height: 48px;
  display: flex;
  align-items: center;
  justify-content: center;
  background: white;
  border-radius: 8px;
  box-shadow: 0 2px 4px rgba(0, 0, 0, 0.1);
  overflow: hidden;
}

.shield-preview-mini svg {
  width: 32px;
  height: 32px;
  object-fit: contain;
}

.shield-info {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 0.25rem;
}

.shield-number {
  font-size: 0.875rem;
  color: #495057;
  font-weight: 600;
}

.shield-total {
  font-size: 0.75rem;
  color: #6c757d;
}

/* Controles de color */
.color-controls {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(200px, 1fr));
  gap: 1.5rem;
}

.color-group {
  display: flex;
  flex-direction: column;
  gap: 0.75rem;
}

.color-group label {
  font-weight: 500;
  color: #495057;
  font-size: 0.9rem;
}

.color-picker-container {
  display: flex;
  align-items: center;
  gap: 1rem;
  padding: 0.75rem;
  background: #f8f9fa;
  border-radius: 8px;
  border: 1px solid #e9ecef;
}

.color-picker {
  width: 48px;
  height: 48px;
  border: none;
  border-radius: 8px;
  cursor: pointer;
  box-shadow: 0 2px 4px rgba(0, 0, 0, 0.1);
  transition: transform 0.2s ease;
}

.color-picker:hover {
  transform: scale(1.05);
}

.color-label {
  font-family: 'Courier New', monospace;
  font-size: 0.875rem;
  color: #495057;
  font-weight: 500;
  background: white;
  padding: 0.25rem 0.5rem;
  border-radius: 4px;
  border: 1px solid #dee2e6;
}

/* Control de texto */
.text-control {
  display: flex;
  flex-direction: column;
  gap: 1rem;
}

.text-control input {
  width: 100%;
  padding: 1rem;
  border: 2px solid #e9ecef;
  border-radius: 8px;
  font-size: 1.1rem;
  font-weight: 600;
  text-align: center;
  text-transform: uppercase;
  background: white;
  transition: border-color 0.2s ease;
}

.text-control input:focus {
  outline: none;
  border-color: #007bff;
  box-shadow: 0 0 0 3px rgba(0, 123, 255, 0.1);
}

.text-hint {
  text-align: center;
  padding: 0.75rem;
  background: #e3f2fd;
  border-radius: 8px;
  border: 1px solid #bbdefb;
}

.text-hint span {
  color: #1976d2;
  font-size: 0.875rem;
  font-weight: 500;
}

/* Botones de acción mejorados */
.modal-actions {
  display: flex;
  gap: 1rem;
  justify-content: center;
  padding: 1.5rem 0 0 0;
  border-top: 1px solid #e9ecef;
  margin-top: 2rem;
}

.modal-actions .btn {
  display: flex;
  align-items: center;
  gap: 0.5rem;
  padding: 0.75rem 1.5rem;
  border-radius: 8px;
  font-weight: 500;
  transition: all 0.2s ease;
  min-width: 120px;
  justify-content: center;
}

.btn-outline {
  background: transparent;
  border: 2px solid #6c757d;
  color: #6c757d;
}

.btn-outline:hover {
  background: #6c757d;
  color: white;
}

/* Responsive */
@media (max-width: 768px) {
  .shield-customizer {
    padding: 0.5rem;
  }
  
  .shield-preview-container {
    padding: 1rem;
  }
  
  .shield-preview-navigation {
    gap: 1rem;
    max-width: 100%;
  }
  
  .shield-preview-large {
    padding: 1rem;
  }
  
  .nav-btn {
    width: 48px;
    height: 48px;
    font-size: 1.2rem;
  }
  
  .control-section {
    padding: 1rem;
  }
  
  .color-controls {
    grid-template-columns: 1fr;
  }
  
  .modal-actions {
    flex-direction: column;
  }
  
  .modal-actions .btn {
    width: 100%;
  }
}

@media (max-width: 480px) {
  .shield-preview-navigation {
    gap: 0.5rem;
  }
  
  .shield-preview-large {
    padding: 0.75rem;
  }
  
  .nav-btn {
    width: 40px;
    height: 40px;
    font-size: 1rem;
  }
  
  .shield-number {
    font-size: 1rem;
  }
  
  .shield-total {
    font-size: 0.8rem;
  }
}

/* Ajustar el contenedor de opciones para la nueva navegación */
.shape-options {
  display: block;
  width: 100%;
}

.shape-option {
  width: 40px;
  height: 40px;
  border: 2px solid #d1d5db;
  border-radius: 6px;
  cursor: pointer;
  transition: all 0.2s ease;
  display: flex;
  align-items: center;
  justify-content: center;
  background: white;
  font-size: 16px;
}

.shape-option:hover {
  border-color: var(--primary-color);
  transform: scale(1.05);
}

.shape-option.selected {
  border-color: var(--primary-color);
  background: var(--primary-color);
  color: white;
  transform: scale(1.1);
}

.shield-preview-mini {
  width: 100%;
  height: 100%;
  display: flex;
  align-items: center;
  justify-content: center;
  background: transparent;
  border-radius: 4px;
  overflow: hidden;
}

.shield-preview-mini svg {
  width: 100%;
  height: 100%;
  object-fit: contain;
  max-width: 32px;
  max-height: 32px;
  display: block;
}

.shield-preview-large {
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 20px;
}

.shield-preview-large svg {
  max-width: 100%;
  max-height: 100%;
  object-fit: contain;
  display: block;
}

.stat-card p {
  font-size: 0.8em;
  text-transform: uppercase;
}

/* Responsive Design */
@media (max-width: 768px) {
  .content-screen {
    padding: 15px;
  }
  
  .auth-container {
    padding: 15px;
  }
  
  .app-header {
    padding: 15px 0;
  }
  
  .quick-stats {
    grid-template-columns: repeat(3, 1fr);
    gap: 10px;
  }
  
  .stat-card {
    padding: 15px;
  }
  
  .stat-card h3 {
    font-size: 24px;
  }
  
  .section {
    padding: 20px 15px;
  }
  
  .team-grid {
    grid-template-columns: 1fr;
  }
  
  .filter-tabs {
    overflow-x: auto;
  }
  
  .modal {
    margin: 10px;
  }
}

@media (max-width: 480px) {
  .screen-header {
    flex-direction: column;
    align-items: flex-start;
    gap: 15px;
  }
  
  .ranking-tabs {
    align-self: stretch;
  }
  
  .quick-stats {
    grid-template-columns: 1fr;
  }
}

/* Animations */
.fade-in {
  animation: fadeIn 0.3s ease-in;
}

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

.slide-up {
  animation: slideUp 0.3s ease-out;
}

@keyframes slideUp {
  from { transform: translateY(100%); }
  to { transform: translateY(0); }
}

/* Utility Classes */
.text-center { text-align: center; }
.text-right { text-align: right; }
.mb-0 { margin-bottom: 0 !important; }
.mb-1 { margin-bottom: 0.5rem; }
.mb-2 { margin-bottom: 1rem; }
.mb-3 { margin-bottom: 1.5rem; }
.hidden { display: none !important; }
.visible { display: block !important; } 

.jornadas-nav-container {
  justify-content: space-between;
  align-items: center;
  margin: 20px 0;
  width: 100%;
  gap: 0;  
}
.jornadas-selector {
  display: flex;
  justify-content: space-between;

  align-items: center;
  gap: 0;
  width: auto;
}
.jornada-nav-btn {
  background: #f3f4f6;
  color: var(--primary-color);
  border: 1.5px solid #e5e7eb;
  border-radius: 50%;
  width: 32px;
  height: 32px;
  font-size: 1.1em;
  font-weight: 600;
  display: flex;
  align-items: center;
  justify-content: center;
  box-shadow: none;
  transition: var(--transition);
  cursor: pointer;
  margin: 0 6px;
  outline: none;
}
.jornada-nav-btn:disabled {
  opacity: 0.25;
  cursor: not-allowed;
}
.jornada-nav-btn:hover:not(:disabled), .jornada-nav-btn:focus:not(:disabled) {
  background: #e5e7eb;
  color: var(--primary-dark);
  border-color: var(--primary-color);
}
.jornada-actual-btn {
  background: #fff6f6;
  color: var(--primary-dark);
  border: 1.5px solid var(--primary-color);
  font-size: 1.1em;
  min-width: 80px;
  height: 35px;
  border-radius: 16px;
  box-shadow: none;
  z-index: 2;
  display: flex;
  align-items: center;
  justify-content: center;
  font-weight: 700;
  letter-spacing: 0.5px;
  margin: 0 4px;
  padding: 0 18px;
  transition: var(--transition);
  outline: none;
}
@media (max-width: 600px) {
  .jornadas-nav-container {
    margin: 20px 0;
  }
  .jornada-actual-btn {
    font-size: 0.98em;
    min-width: 60px;
    height: 35px;
    border-radius: 10px;
    margin: 0 2px;
    padding: 0 10px;
  }
  .jornada-nav-btn {
    width: 35px;
    height: 35px;
    font-size: 0.8em;
    margin: 0 2px;
  }
}

.partidos-jornada {
  margin: 1.5rem 0;
  text-align: center;
}

.fixture {
  display: flex;
  justify-content: center;
  align-items: center;
  gap: 1.5em;
  padding: 0.5em 0;
  border-bottom: 1px solid #eee;
  font-size: 1.1em;
}

.alineacion-usada {
  margin: 1.5rem 0;
  text-align: center;
}

.alineacion-usada ul {
  list-style: none;
  padding: 0;
  margin: 0.5em 0;
}

.alineacion-usada li {
  display: inline-block;
  margin: 0 0.5em;
  background: #f5f5f5;
  border-radius: 3px;
  padding: 0.3em 0.7em;
} 

.slot-player-info {
  display: flex;
  align-items: center;
  width: 100%;
}

.slot-player-avatar {
  width: 40px;
  height: 40px;
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  background: #f5f5f5;
  margin-right: 0.5rem;
  overflow: hidden;
  flex-shrink: 0;
}

.slot-player-details {
  flex: 1;
  min-width: 0;
}

.slot-player-details strong {
  display: block;
  font-size: 0.9rem;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

.slot-player-details small {
  font-size: 0.8rem;
  color: #666;
} 

/* Estilos para MVPs de la jornada */
.mvp-list {
  display: flex;
  flex-direction: column;
  gap: 0.5rem;
  margin: 1rem 0;
}

.mvp-item {
  display: flex;
  align-items: center;
  padding: 0.75rem;
  background: #f8f9fa;
  border-radius: 8px;
  border-left: 4px solid #dee2e6;
}

.mvp-winner {
  background: var(--warning-light);
  border-left-color: var(--warning);
}

.mvp-rank {
  width: 30px;
  height: 30px;
  border-radius: 50%;
  background: #6c757d;
  color: white;
  display: flex;
  align-items: center;
  justify-content: center;
  font-weight: bold;
  font-size: 0.9rem;
  margin-right: 0.75rem;
}

.mvp-winner .mvp-rank {
  background: #ffc107;
  color: #212529;
}

.mvp-avatar {
  width: 45px;
  height: 45px;
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  background: #f5f5f5;
  margin-right: 0.75rem;
  overflow: hidden;
  flex-shrink: 0;
}

.mvp-info {
  flex: 1;
  min-width: 0;
}

.mvp-info h4 {
  margin: 0;
  font-size: 1rem;
  font-weight: 600;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

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

.mvp-points {
  text-align: right;
  margin-left: 0.75rem;
}

.mvp-points strong {
  display: block;
  font-size: 1.2rem;
  color: #28a745;
}

.mvp-points small {
  font-size: 0.8rem;
  color: var(--text-muted);
} 

/* Estilos profesionales para partidos de jornada */
.fixtures-header {
  text-align: center;
  margin: 2rem 0 1.5rem 0;
  padding: 1rem;
  background: linear-gradient(135deg, var(--surface-secondary) 0%, var(--border) 100%);
  border-radius: var(--border-radius-lg);
  border: 1px solid var(--border);
}

.fixtures-header h3 {
  margin: 0 0 0.5rem 0;
  color: var(--text-primary);
  font-size: 1.4rem;
  font-weight: 600;
}

.fixtures-count {
  margin: 0;
  color: var(--text-muted);
  font-size: 0.95rem;
}

.fixtures-grid {
  display: flex;
  flex-direction: column;
  gap: 1rem;
  margin: 1rem 0;
}

.fixture-card {
  background: var(--surface);
  border-radius: var(--border-radius-lg);
  box-shadow: var(--shadow);
  border: 1px solid var(--border);
  overflow: hidden;
  transition: var(--transition);
}

.fixture-card:hover {
  transform: translateY(-2px);
  box-shadow: 0 4px 16px rgba(0, 0, 0, 0.15);
}

.fixture-card.completed {
  border-left: 4px solid var(--success);
}

.fixture-card.upcoming {
  border-left: 4px solid var(--info);
}

.fixture-header {
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding: 0.75rem 1rem;
  background: var(--surface-secondary);
  border-bottom: 1px solid var(--border);
}

.fixture-date {
  display: flex;
  align-items: center;
  gap: 0.5rem;
  font-size: 0.9rem;
  color: var(--text-primary);
}

.date-icon {
  font-size: 1rem;
}

.fixture-status {
  padding: 0.25rem 0.75rem;
  border-radius: 20px;
  font-size: 0.8rem;
  font-weight: 500;
}

.status-completed {
  background: var(--success-light);
  color: var(--success-dark);
}

.status-upcoming {
  background: var(--info-light);
  color: var(--info-dark);
}

.fixture-teams {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 1.5rem 1rem;
  gap: 1rem;
}

.team {
  display: flex;
  align-items: center;
  gap: 0.75rem;
  flex: 1;
}

.team-home {
  justify-content: flex-start;
}

.team-away {
  justify-content: flex-end;
  flex-direction: row-reverse;
}

.team-shield {
  width: 50px;
  height: 50px;
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 1.5rem;
  flex-shrink: 0;
  overflow: hidden;
}

.team-shield-img {
  width: 100%;
  height: 100%;
  object-fit: cover;
}

.team-name {
  display: flex;
  flex-direction: column;
  min-width: 0;
}

.team-label {
  font-size: 0.75rem;
  color: #6c757d;
  text-transform: uppercase;
  font-weight: 500;
  margin-bottom: 0.25rem;
}

.team-name strong {
  font-size: 1rem;
  color: #212529;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

.fixture-score {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 0.5rem;
  padding: 0 1rem;
  flex-shrink: 0;
}

.score-display {
  display: flex;
  align-items: center;
  gap: 0.5rem;
  font-size: 1.5rem;
  font-weight: bold;
  color: #212529;
}

.score-number {
  background: #f8f9fa;
  padding: 0.5rem 0.75rem;
  border-radius: 8px;
  min-width: 40px;
  text-align: center;
  border: 2px solid #dee2e6;
}

.score-separator {
  font-size: 1.2rem;
  color: #6c757d;
}

.score-label {
  font-size: 0.75rem;
  color: #6c757d;
  text-transform: uppercase;
  font-weight: 500;
}

.fixture-footer {
  padding: 0.75rem 1rem;
  background: #f8f9fa;
  border-top: 1px solid #e9ecef;
}

.fixture-venue {
  display: flex;
  align-items: center;
  gap: 0.5rem;
  font-size: 0.85rem;
  color: #6c757d;
}

.venue-icon {
  font-size: 1rem;
}

.no-fixtures {
  text-align: center;
  padding: 3rem 1rem;
  background: #f8f9fa;
  border-radius: 12px;
  border: 2px dashed #dee2e6;
}

.no-fixtures-icon {
  font-size: 3rem;
  margin-bottom: 1rem;
  opacity: 0.5;
}

.no-fixtures h3 {
  margin: 0 0 0.5rem 0;
  color: #495057;
  font-size: 1.2rem;
}

.no-fixtures p {
  margin: 0;
  color: #6c757d;
  font-size: 0.95rem;
}

/* Selección de jugadores en home */
.home-team-selection {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 5px;
  margin: 0 auto 18px auto;
  max-width: 700px;
  min-height: 220px;
  padding: 10px 0;
}

.home-team-selection .player-selection-row {
  display: flex;
  justify-content: center;
  align-items: center;
  gap: 15px;
  flex-wrap: nowrap;
  width: 100%;
}

/* Primera fila: 3 jugadores */
.home-team-selection .player-selection-row:first-child {
  justify-content: center;
}

/* Segunda fila: 2 jugadores */
.home-team-selection .player-selection-row:last-child {
  justify-content: center;
  gap: 15px; /* Más espacio entre los 2 jugadores */
}

@media (max-width: 600px) {
  .home-team-selection {
    gap: 5px;
    padding: 15px 0;
  }
  
  .home-team-selection .player-selection-row {
    gap: 5px;
  }
  
  .home-team-selection .player-selection-row:last-child {
    gap: 5px;
  }
  
  .player-card {
    min-width: 110px;
    width: 100px;
    max-width: 120px;
    margin: 0;
  }
}

.player-selection-row {
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: 0.5rem;
}

.player-selection-slot {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 0.5rem;
  cursor: pointer;
  transition: all 0.2s ease;
  padding: 0.5rem;
  border-radius: 8px;
  min-width: 100px;
  max-width: 120px;
  flex: 0 0 auto;
}

.player-selection-slot:hover {
  background: #f8f9fa;
  transform: translateY(-2px);
}

.player-selection-avatar {
  width: 60px;
  height: 60px;
  border-radius: 50%;
  background: #f8f9fa;
  border: 2px solid #dee2e6;
  display: flex;
  align-items: center;
  justify-content: center;
  overflow: hidden;
  transition: all 0.2s ease;
}

.player-selection-avatar img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  border-radius: 50%;
}

.player-selection-placeholder {
  font-size: 1.5rem;
  color: #6c757d;
  font-weight: bold;
}

.player-selection-name {
  font-size: 0.75rem;
  color: #495057;
  text-align: center;
  font-weight: 500;
  max-width: 100px;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
  line-height: 1.2;
}


.player-selection-slot.filled .player-selection-avatar {
  border-color: var(--primary-color);
  background: white;
}

.player-selection-slot.captain .player-selection-avatar {
  border-color: #f59e0b;
  border-width: 3px;
}

.player-selection-slot.captain .player-selection-name::after {
  content: ' (C)';
  color: #f59e0b;
  font-weight: bold;
}


.team-selection-actions {
  display: flex;
  gap: 1rem;
  justify-content: center;
  padding-top: 1rem;
  border-top: 1px solid #e9ecef;
}

/* Modal de selección de jugadores */
.player-picker-modal {
  max-width: 90vw;
  max-height: 80vh;
  overflow: hidden;
  display: flex;
  flex-direction: column;
}

.player-picker-header {
  padding: 1rem;
  border-bottom: 1px solid #e9ecef;
  background: #f8f9fa;
}

.player-picker-content {
  flex: 1;
  overflow-y: auto;
  padding: 1rem;
}

.player-picker-filter {
  display: flex;
  gap: 0.5rem;
  margin-bottom: 1rem;
  overflow-x: auto;
  padding-bottom: 0.5rem;
}

.player-picker-filter button {
  padding: 0.5rem 1rem;
  border: 1px solid #dee2e6;
  background: white;
  border-radius: 20px;
  font-size: 0.875rem;
  white-space: nowrap;
  cursor: pointer;
  transition: all 0.2s ease;
}

.player-picker-filter button.active {
  background: var(--primary-color);
  color: white;
  border-color: var(--primary-color);
}

.player-picker-list {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(150px, 1fr));
  gap: 1rem;
}

.player-picker-item {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 0.5rem;
  padding: 1rem;
  border: 1px solid #e9ecef;
  border-radius: 8px;
  cursor: pointer;
  transition: all 0.2s ease;
  background: white;
}

.player-picker-item:hover {
  border-color: var(--primary-color);
  transform: translateY(-2px);
  box-shadow: 0 4px 12px rgba(0, 0, 0, 0.1);
}

.player-picker-item.disabled {
  opacity: 0.6;
  cursor: not-allowed;
  background: #f8f9fa;
  border-color: #dee2e6;
  position: relative;
}

.player-picker-item.disabled:hover {
  transform: none;
  box-shadow: none;
  border-color: #dee2e6;
}

.player-picker-item.disabled .player-picker-avatar {
  filter: grayscale(70%);
}

.player-picker-item.disabled .player-picker-name {
  color: #6c757d;
}

.player-picker-item.disabled .player-picker-position {
  color: #adb5bd;
}

.player-picker-status {
  font-size: 0.7rem;
  color: #dc3545;
  font-weight: 600;
  margin-top: 0.25rem;
  text-align: center;
  background: rgba(220, 53, 69, 0.1);
  padding: 0.2rem 0.5rem;
  border-radius: 4px;
  border: 1px solid rgba(220, 53, 69, 0.2);
}

/* Estilo para jugadores ya seleccionados en esta jornada */
.player-picker-item.disabled-selected .player-picker-status {
  color: #dc3545;
  background: rgba(220, 53, 69, 0.1);
  border-color: rgba(220, 53, 69, 0.2);
}

/* Estilo para jugadores de jornada anterior */
.player-picker-item.disabled-previous .player-picker-status {
  color: #fd7e14;
  background: rgba(253, 126, 20, 0.1);
  border-color: rgba(253, 126, 20, 0.2);
}

.player-picker-avatar {
  width: 50px;
  height: 50px;
  border-radius: 50%;
  overflow: hidden;
  border: 2px solid #dee2e6;
}

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

.player-picker-info {
  text-align: center;
}

.player-picker-name {
  font-size: 0.875rem;
  font-weight: 500;
  color: #212529;
  margin-bottom: 0.25rem;
}

.player-picker-position {
  font-size: 0.75rem;
  color: #6c757d;
}

/* Modal de selección de capitán */
.captain-options {
  display: flex;
  flex-direction: column;
  gap: 1rem;
  align-items: center;
  padding: 2rem;
}

.captain-options .btn {
  width: 200px;
  justify-content: center;
}

/* Responsive */
@media (max-width: 768px) {
  .player-selection-row {
    gap: 5px;
  }
  
  .player-selection-avatar {
    width: 40px;
    height: 40px;
  }
  
  .player-selection-name {
    font-size: 0.6rem;
    max-width: 50px;
  }
  
  .player-picker-list {
    grid-template-columns: repeat(auto-fill, minmax(120px, 1fr));
    gap: 0.75rem;
  }
  
  .player-picker-item {
    padding: 0.75rem;
  }
} 

/* Centrado horizontal de los equipos y escudos sobre el nombre */
.fixture-teams-centered {
  display: flex;
  flex-direction: row;
  justify-content: center;
  align-items: center;
  gap: 2rem;
  margin: 1.5rem 0 1rem 0;
}
.team-centered {
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  min-width: 90px;
}
.team-shield-centered {
  display: flex;
  align-items: center;
  justify-content: center;
  margin-bottom: 0.5rem;
}
.team-shield-centered img.team-shield-img {
  width: 40px;
  height: 40px;
  object-fit: contain;
  display: block;
}
.team-name-centered {
  text-align: center;
  font-size: 1.1rem;
  font-weight: 600;
  margin-top: 0.2rem;
}
.fixture-score-centered {
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  min-width: 60px;
}
.score-display-centered {
  display: flex;
  flex-direction: row;
  align-items: center;
  font-size: 1.5rem;
  font-weight: bold;
  gap: 0.3rem;
} 

.captain-icon {
  position: absolute;
  top: 8px;
  right: 8px;
  font-size: 1.5em;
  cursor: pointer;
  opacity: 0.7;
  z-index: 2;
  transition: opacity 0.2s, color 0.2s;
}
.captain-icon:hover {
  opacity: 1;
  color: #FFD700;
} 

.captain-band {
  position: absolute;
  left: 8px;
  top: 8px;
  width: 36px;
  height: 24px;
  background: var(--primary-color);
  color: #fff;
  font-weight: bold;
  font-size: 1em;
  text-align: center;
  letter-spacing: 1px;
  padding: 0;
  z-index: 3;
  box-shadow: 0 1px 3px rgba(0,0,0,0.08);
  border-radius: 5px;
  pointer-events: none;
  display: flex;
  align-items: center;
  justify-content: center;
  opacity: 0.78;
}
.player-card.captain {
  position: relative;
}
.make-captain-btn {
  position: absolute;
  top: 8px;
  right: 8px;
  background: #fff;
  border: 1.5px solid var(--primary-color);
  color: var(--primary-color);
  border-radius: 50%;
  width: 32px;
  height: 32px;
  font-size: 1.2em;
  display: flex;
  align-items: center;
  justify-content: center;
  cursor: pointer;
  opacity: 0.85;
  z-index: 2;
  transition: background 0.2s, color 0.2s, opacity 0.2s;
}
.make-captain-btn:hover {
  background: var(--primary-color);
  color: #fff;
  opacity: 1;
} 

.player-card.dragging {
  opacity: 0.5;
  box-shadow: 0 4px 16px rgba(0,0,0,0.18);
}
.player-card.drag-over {
  border: 2.5px dashed #1976d2;
  background: #e3f2fd;
} 

@media (max-width: 600px) {
  .quick-stats-row {
    display: flex;
    flex-direction: row;
    justify-content: space-between;
    align-items: center;
    gap: 8px;
    width: 100%;
    font-size: 0.98em;
    margin-bottom: 10px;
  }
  .quick-stat {
    flex: 1 1 0;
    min-width: 0;
    text-align: center;
    padding: 0 2px;
  }
} 

.player-points {
  margin-top: auto;
  margin-bottom: 0;
  width: 100%;
  min-height: 28px;
  padding: 4px 0;
  position: absolute;
  bottom: 4px;
  left: 0;
  right: 0;
  display: flex;
  justify-content: center;
  align-items: center;
}

/* Badge de puntos con colores según rendimiento */
.points-badge {
  display: flex;
  align-items: center;
  gap: 4px;
  padding: 4px 8px;
  border-radius: 12px;
  font-size: 0.8em;
  font-weight: 700;
  text-align: center;
  box-shadow: 0 1px 3px rgba(0, 0, 0, 0.2);
  min-width: 45px;
  justify-content: center;
}

.points-badge.excellent {
  background: linear-gradient(135deg, #10b981, #059669);
  color: white;
}

.points-badge.good {
  background: linear-gradient(135deg, #3b82f6, #1d4ed8);
  color: white;
}

.points-badge.average {
  background: linear-gradient(135deg, #f59e0b, #d97706);
  color: white;
}

.points-badge.poor {
  background: linear-gradient(135deg, #ef4444, #dc2626);
  color: white;
}

.points-badge.pending {
  background: linear-gradient(135deg, #f3f4f6, #e5e7eb);
  color: #6b7280;
  border: 1px solid #d1d5db;
}

.points-value {
  font-size: 1.1em;
  font-weight: 800;
}

.points-label {
  font-size: 0.75em;
  opacity: 0.9;
  font-weight: 600;
}

.captain-multiplier {
  font-size: 0.7em;
  background: rgba(255, 255, 255, 0.3);
  padding: 1px 4px;
  border-radius: 4px;
  margin-left: 2px;
}

/* Estados pendientes y próximos */
.points-pending, .points-upcoming {
  display: flex;
  align-items: center;
  gap: 4px;
  padding: 4px 8px;
  border-radius: 12px;
  font-size: 0.75em;
  font-weight: 600;
  background: #f3f4f6;
  color: #6b7280;
  border: 1px solid #e5e7eb;
  min-width: 70px;
  justify-content: center;
}

.points-pending {
  background: #fef3c7;
  color: #92400e;
  border-color: #f59e0b;
}

.points-upcoming {
  background: #e0e7ff;
  color: #3730a3;
  border-color: #6366f1;
}

.pending-icon, .upcoming-icon {
  font-size: 0.9em;
}

.pending-text, .upcoming-text {
  font-size: 0.85em;
  font-weight: 600;
}

/* Mejoras para cartas de jugador */
.player-card {
  position: relative;
  padding-bottom: 35px; /* Espacio para los puntos */
}

.player-card.captain .points-badge {
  box-shadow: 0 2px 6px rgba(255, 215, 0, 0.4);
}

/* Responsive */
@media (max-width: 600px) {
  .points-badge {
    font-size: 0.7em;
    padding: 3px 6px;
    min-width: 40px;
  }
  
  .points-value {
    font-size: 1em;
  }
  
  .points-label {
    font-size: 0.7em;
  }
  
  .captain-multiplier {
    font-size: 0.65em;
    padding: 1px 3px;
  }
  
  .points-pending, .points-upcoming {
    font-size: 0.7em;
    padding: 3px 6px;
    min-width: 65px;
  }
}

/* --- INVITACIÓN DE AMIGOS --- */
.invite-modal-bg {
  background: linear-gradient(135deg, #f3f4f6 0%, #e0e7ff 100%);
  padding: 0;
  margin: 0;
  min-height: 100vh;
  display: flex;
  align-items: center;
  justify-content: center;
}
.invite-modal-card {
  background: #fff;
  border-radius: 22px;
  box-shadow: 0 8px 32px rgba(0,0,0,0.13);
  padding: 36px 32px 28px 32px;
  width: 100%;
  text-align: center;
  position: relative;
  animation: pop-in 0.4s cubic-bezier(.68,-0.55,.27,1.55);
}
@keyframes pop-in {
  0% { transform: scale(0.8); opacity: 0; }
  100% { transform: scale(1); opacity: 1; }
}
.invite-modal-header {
  margin-bottom: 18px;
}
.invite-emoji {
  font-size: 2.2em;
  display: block;
  margin-bottom: 6px;
}
.invite-modal-shield {
  margin: 0 auto 12px auto;
  width: 80px;
  height: 96px;
  display: flex;
  align-items: center;
  justify-content: center;
  border-radius: 16px;
  background: #f3f4f6;
  box-shadow: 0 2px 8px rgba(0,0,0,0.07);
}
.invite-modal-team {
  font-size: 1.25em;
  font-weight: 700;
  color: #1e293b;
  margin-bottom: 2px;
}
.invite-modal-username {
  font-size: 1em;
  color: #64748b;
  margin-bottom: 10px;
}
.invite-modal-actions {
  margin-top: 18px;
  display: flex;
  flex-direction: column;
  gap: 10px;
}
.invite-modal-actions .btn-primary {
  background: linear-gradient(90deg, #6366f1 0%, #dc2626 100%);
  color: #fff;
  font-weight: 700;
  font-size: 1.1em;
  border: none;
  border-radius: 10px;
  padding: 14px 0;
  transition: background 0.2s;
  box-shadow: 0 2px 8px rgba(220,38,38,0.08);
}
.invite-modal-actions .btn-primary:disabled {
  background: #cbd5e1;
  color: #64748b;
  cursor: not-allowed;
}
.invite-modal-actions .btn-secondary {
  background: #f3f4f6;
  color: #1e293b;
  border: none;
  border-radius: 10px;
  padding: 12px 0;
  font-weight: 600;
  font-size: 1em;
  transition: background 0.2s;
}
.invite-modal-info {
  margin-top: 12px;
  color: #64748b;
  font-size: 0.98em;
} 

/* --- UNIÓN A LIGA PRIVADA --- */
.league-join-bg {
  background: linear-gradient(135deg, #f3f4f6 0%, #e0e7ff 100%);
  min-height: 100vh;
  display: flex;
  align-items: center;
  justify-content: center;
}
.league-join-card {
  background: #fff;
  border-radius: 22px;
  box-shadow: 0 8px 32px rgba(0,0,0,0.13);
  padding: 36px 32px 28px 32px;
  max-width: 400px;
  width: 100%;
  text-align: center;
  animation: pop-in 0.4s cubic-bezier(.68,-0.55,.27,1.55);
}
@keyframes pop-in {
  0% { transform: scale(0.8); opacity: 0; }
  100% { transform: scale(1); opacity: 1; }
}
.league-join-header {
  margin-bottom: 18px;
}
.league-join-shield {
  margin: 0 auto 12px auto;
  height: 96px;
  display: flex;
  align-items: center;
  justify-content: center;
}
.league-join-title {
  font-size: 1.5em;
  font-weight: 800;
  color: #1e293b;
  margin-bottom: 2px;
}
.league-join-admin {
  font-size: 1em;
  color: #64748b;
  margin-bottom: 10px;
}
.league-join-members-list {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  justify-content: center;
  margin-bottom: 10px;
}
.league-member-pill {
  background: #e0e7ff;
  color: #3730a3;
  border-radius: 12px;
  padding: 4px 12px;
  font-size: 0.98em;
  font-weight: 600;
}
.league-join-btn {
  background: linear-gradient(90deg, #6366f1 0%, #dc2626 100%);
  color: #fff;
  font-weight: 700;
  font-size: 1.1em;
  border: none;
  border-radius: 10px;
  padding: 14px 0;
  width: 100%;
  margin-bottom: 10px;
  transition: background 0.2s;
  box-shadow: 0 2px 8px rgba(220,38,38,0.08);
}
.league-join-btn:disabled {
  background: #cbd5e1;
  color: #64748b;
  cursor: not-allowed;
}
.league-join-status {
  margin: 12px 0;
  color: #64748b;
  font-size: 1.05em;
}
.league-join-back {
  margin-top: 18px;
} 

.section-title {
  font-size: 1.25em;
  font-weight: 800;
  margin-bottom: 10px;
  color: var(--text-primary);
  letter-spacing: 0.01em;
}
.section-separator {
  margin: 28px 0 18px 0;
  border: none;
  border-top: 1.5px solid var(--border);
}
.private-leagues-section, .friends-section {
  margin-bottom: 28px;
}
.leagues-list {
  flex-wrap: wrap;
  gap: 14px;
  margin-bottom: 10px;
}
.league-card {
  background: var(--surface);
  border-radius: var(--border-radius-lg);
  box-shadow: var(--shadow);
  padding: 14px 14px 10px 14px;
  min-width: 220px;
  flex: 1 1 220px;
  max-width: 320px;
  display: flex;
  flex-direction: column;
  align-items: flex-start;
  border: 1px solid var(--border);
  margin-bottom: 10px;
}
.league-card-header {
  display: flex;
  align-items: center;
  gap: 8px;
  margin-bottom: 6px;
}
.league-icon {
  font-size: 1.2em;
}
.league-card-title {
  font-size: 1.08em;
  font-weight: 700;
  color: var(--text-primary);
}
.league-badge {
  border-radius: var(--border-radius);
  padding: 2px 10px;
  font-size: 0.93em;
  font-weight: 600;
  margin-left: auto;
  background: var(--surface-secondary);
  color: var(--text-secondary);
}
.league-badge.admin {
  background: var(--danger-light);
  color: var(--primary-color);
}
.league-badge.member {
  background: var(--info-light);
  color: var(--info);
}
.league-card-members, .league-card-pending {
  margin-bottom: 6px;
  width: 100%;
}
.league-members-pills, .league-pending-pills {
  display: flex;
  flex-wrap: wrap;
  gap: 5px;
  margin-top: 2px;
}
.member-pill, .pending-pill {
  background: var(--purple-light);
  color: var(--purple);
  border-radius: var(--border-radius-lg);
  padding: 2px 8px;
  font-size: 0.95em;
  font-weight: 600;
  display: flex;
  align-items: center;
  gap: 3px;
}
.pending-pill .btn-xs {
  font-size: 0.9em;
  padding: 2px 6px;
  margin-left: 2px;
}
.league-card-actions {
  display: flex;
  gap: 6px;
  width: 100%;
}
.leagues-actions {
  text-align: right;
}
.friends-list-cards {
  display: flex;
  flex-wrap: wrap;
  gap: 14px;
}
.friend-card {
  background: #fff;
  border-radius: 10px;
  box-shadow: 0 1px 4px rgba(30,41,59,0.06);
  padding: 12px 10px 8px 10px;
  min-width: 180px;
  flex: 1 1 180px;
  max-width: 260px;
  display: flex;
  align-items: center;
  gap: 10px;
  border: 1px solid #e5e7eb;
}
.friend-shield {
  width: 38px;
  height: 44px;
  display: flex;
  align-items: center;
  justify-content: center;
  background: #f3f4f6;
  border-radius: 8px;
  margin-right: 4px;
}
.friend-info {
  flex: 1;
}
.friend-username {
  color: #64748b;
  font-size: 0.97em;
  margin-bottom: 2px;
}
.friend-actions {
  display: flex;
  flex-direction: column;
  gap: 5px;
} 

.friends-navtab {
  display: flex;
  gap: 0;
  border-bottom: 2px solid #e5e7eb;
  margin-bottom: 18px;
  background: #fff;
}
.navtab-btn {
  flex: 1 1 0;
  background: none;
  border: none;
  outline: none;
  font-size: 1.08em;
  font-weight: 700;
  color: #64748b;
  padding: 12px 0 10px 0;
  cursor: pointer;
  border-bottom: 2.5px solid transparent;
  transition: color 0.15s, border-bottom 0.15s;
}
.navtab-btn.active {
  color: #3730a3;
  border-bottom: 2.5px solid #6366f1;
  background: #f8fafc;
} 

.fullwidth-list {
  gap: 16px;
}
.fullwidth-card {
  width: 100%;
  min-width: 0;
  max-width: 100%;
  margin: 0 0 12px 0;
  border-radius: var(--border-radius-lg);
  box-shadow: var(--shadow);
  border: 1px solid var(--border);
  display: flex;
  align-items: stretch;
  padding: 16px;
  background: var(--surface);
  transition: var(--transition);
  position: relative;
  overflow: hidden;
}

.fullwidth-card:hover {
  box-shadow: var(--shadow-lg);
  transform: translateY(-1px);
  border-color: var(--border-dark);
}


.fullwidth-card .league-card-header {
  flex: 1;
  display: flex;
  flex-direction: column;
  align-items: flex-start;
  justify-content: flex-start;
  min-width: 0;
  margin-right: 16px;
  gap: 10px;
}

.league-header-main {
  display: flex;
  align-items: flex-start;
  gap: 10px;
  width: 100%;
  min-width: 0;
}

.league-title-section {
  flex: 1;
  min-width: 0;
  display: flex;
  flex-direction: column;
  gap: 8px;
}

.league-badges {
  align-items: right;
  gap: 6px;
  flex-wrap: wrap;
  margin-top: 4px;
}
.fullwidth-card .league-icon {
  font-size: 1.6em;
  color: var(--primary-color);
  width: 44px;
  height: 44px;
  display: flex;
  align-items: center;
  justify-content: center;
  border-radius: var(--border-radius-lg);
  border: 2px solid var(--border);
  flex-shrink: 0;
  transition: var(--transition);
}

.fullwidth-card .league-icon.admin-icon {
  color: var(--text-light);
  border-color: var(--border);
}
.fullwidth-card .league-card-title {
  font-size: 1.1em;
  font-weight: 700;
  color: var(--text-primary);
  margin: 0;
  line-height: 1.3;
  max-width: 100%;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}
.fullwidth-card .league-badge {
  border-radius: var(--border-radius);
  padding: 4px 8px;
  font-size: 0.7em;
  font-weight: 600;
  background: var(--surface);
  color: var(--primary-color);
  border: 1px solid var(--primary-color);
  white-space: nowrap;
  line-height: 1;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-height: 20px;
  text-transform: uppercase;
  letter-spacing: 0.3px;
  transition: var(--transition);
}

.fullwidth-card .league-badge.admin {
  background: var(--surface);
  color: var(--primary-color);
  border-color: var(--primary-color);
}

.fullwidth-card .league-badge.member {
  background: var(--surface);
  color: var(--primary-color);
  border-color: var(--primary-color);
}

.fullwidth-card .league-badge.public {
  background: var(--surface);
  color: var(--primary-color);
  border-color: var(--primary-color);
}

.fullwidth-card .league-badge.private {
  background: var(--surface);
  color: var(--primary-color);
  border-color: var(--primary-color);
}
.fullwidth-card .league-card-meta {
  display: flex;
  align-items: center;
  gap: 10px;
  font-size: 0.8em;
  color: var(--text-secondary);
  width: 100%;
  min-width: 0;
  flex-wrap: wrap;
  justify-content: flex-start;
  padding: 8px 0;
  border-top: 1px solid var(--border-light);
  margin-top: 8px;
}



.league-admin {
  font-weight: 500;
  color: var(--text-secondary);
  font-style: italic;
}

.league-prize {
  font-size: 0.8em;
  color: var(--success);
  font-weight: 600;
  background: var(--success-light);
  padding: 3px 6px;
  border-radius: var(--border-radius-sm);
  border: 1px solid var(--success);
  display: inline-flex;
  align-items: center;
  gap: 3px;
}

.league-conditions {
  font-size: 0.75em;
  color: var(--text-tertiary);
  font-style: italic;
  background: var(--surface-tertiary);
  padding: 3px 6px;
  border-radius: var(--border-radius-sm);
  border: 1px solid var(--border);
  display: inline-flex;
  align-items: center;
  gap: 3px;
}
.fullwidth-card .league-members-count {
  font-weight: 500;
  color: #64748b;
  white-space: nowrap;
}
.fullwidth-card .btn-xs.btn-secondary {
  background: none;
  color: var(--primary-color);
  border: none;
  padding: 0 4px;
  font-size: 0.85em;
  font-weight: 500;
  text-decoration: underline;
  box-shadow: none;
  transition: var(--transition-fast);
  min-width: 0;
  white-space: nowrap;
}

.fullwidth-card .btn-xs.btn-secondary:hover {
  background: var(--background);
  color: var(--text-primary);
}
.fullwidth-card .league-card-actions {
  display: flex;
  align-items: center;
  gap: 6px;
  min-width: 0;
  flex-wrap: wrap;
  padding: 10px 0;
  border-top: 1px solid var(--border-light);
  margin-top: 8px;
}

/* Asegurar que los botones en las acciones de liga estén alineados */
.fullwidth-card .league-card-actions .btn {
  display: flex;
  align-items: center;
  justify-content: center;
  height: 32px;
  min-height: 32px;
  white-space: nowrap;
  font-size: 0.8em;
  padding: 6px 12px;
  border-radius: var(--border-radius);
  font-weight: 600;
  transition: var(--transition);
  border: 1px solid var(--border);
  cursor: pointer;
  min-width: 70px;
  background: var(--surface);
  color: var(--text-primary);
}

.fullwidth-card .league-card-actions .btn:hover {
  background: var(--surface-hover);
  transform: translateY(-1px);
  box-shadow: var(--shadow);
}

.fullwidth-card .league-card-actions .btn-primary {
  background: var(--primary-color);
  color: var(--text-light);
  border-color: var(--primary-color);
}

.fullwidth-card .league-card-actions .btn-primary:hover {
  background: var(--primary-hover);
  border-color: var(--primary-hover);
}

.fullwidth-card .league-card-actions .btn-success {
  background: var(--success);
  color: var(--text-light);
  border-color: var(--success);
}

.fullwidth-card .league-card-actions .btn-success:hover {
  background: var(--success-dark);
  border-color: var(--success-dark);
}

.fullwidth-card .league-card-actions .btn-warning {
  background: var(--warning);
  color: var(--text-light);
  border-color: var(--warning);
}

.fullwidth-card .league-card-actions .btn-warning:hover {
  background: var(--warning-dark);
  border-color: var(--warning-dark);
}

.fullwidth-card .league-card-actions .btn-danger {
  background: var(--danger);
  color: var(--text-light);
  border-color: var(--danger);
}

.fullwidth-card .league-card-actions .btn-danger:hover {
  background: var(--danger-dark);
  border-color: var(--danger-dark);
}

/* Botón de navegación discreto */
.btn-nav {
  display: flex;
  align-items: center;
  gap: 6px;
  padding: 8px 12px;
  font-size: 0.85em;
  font-weight: 500;
  color: var(--text-secondary);
  background: var(--surface);
  border: 2px solid var(--border-dark);
  border-radius: var(--border-radius);
  cursor: pointer;
  transition: var(--transition);
  text-decoration: none;
  white-space: nowrap;
  min-height: 32px;
  margin-left: auto;
  width: fit-content;
  min-width: fit-content;
}

.btn-nav:hover {
  background: var(--surface-hover);
  color: var(--text-primary);
  border-color: var(--primary-color);
  transform: translateY(-1px);
  box-shadow: var(--shadow);
}

.btn-nav svg {
  flex-shrink: 0;
  color: inherit;
}

.btn-nav span {
  font-size: 0.85em;
  font-weight: 500;
}
@media (max-width: 700px) {
  .fullwidth-card {
    flex-direction: column;
    align-items: stretch;
    padding: 16px;
    margin: 0 0 12px 0;
  }
  
  .fullwidth-card .league-card-header {
    margin-bottom: 12px;
    margin-right: 0;
  }
  
  .fullwidth-card .league-card-actions {
    margin-top: 12px;
    flex-direction: column;
    justify-content: flex-start;
    align-items: stretch;
    gap: 8px;
  }
  
  .fullwidth-card .league-card-actions > * {
    width: 100%;
    min-width: 0;
    margin: 0;
  }
  
  .fullwidth-card .league-card-actions .btn {
    height: 44px;
    min-height: 44px;
    justify-content: center;
    align-items: center;
    font-size: 0.9em;
    min-width: 100%;
  }
  
  .league-header-main {
    flex-direction: column;
    align-items: flex-start;
    gap: 8px;
  }
  
  .league-title-section {
    width: 100%;
  }
  
  .league-badges {
    justify-content: flex-end;
    gap: 6px;
  }
  
  .league-badge {
    font-size: 0.7em;
    padding: 5px 8px;
    min-height: 22px;
  }
  
  .league-card-meta {
    gap: 8px;
    padding: 6px 0;
  }
  
  .league-prize,
  .league-conditions {
    font-size: 0.75em;
    padding: 3px 6px;
  }
}

.modal-list {
  list-style: none;
  padding: 0;
  margin: 0 0 18px 0;
}
.modal-list li {
  padding: 8px 0;
  border-bottom: 1px solid #f1f1f1;
  font-size: 1.05em;
  display: flex;
  align-items: center;
  gap: 10px;
}
.modal-list li:last-child {
  border-bottom: none;
}
.btn-warning {
  background: #fbbf24;
  color: #78350f;
  border: none;
  border-radius: 8px;
  padding: 7px 14px;
  font-weight: 700;
  font-size: 1em;
  transition: background 0.15s;
}
.btn-warning:hover {
  background: #f59e42;
} 

.btn-icon-xs {
  background: none;
  border: none;
  color: var(--primary-color);
  font-size: 1.15em;
  width: 28px;
  height: 28px;
  min-width: 28px;
  min-height: 28px;
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 0;
  margin: 0;
  cursor: pointer;
  transition: background 0.15s, color 0.15s;
}
.btn-icon-xs:hover {
  background: #fee2e2;
  color: var(--primary-color);
}
.modal-list .member-shield svg {
  display: block;
  width: 32px !important;
  height: 40px !important;
  margin: 0 auto;
} 

.player-lock-icon {
  margin-left: 6px;
  color: #b91c1c;
  font-size: 1.1em;
  vertical-align: middle;
  cursor: help;
}
.player-picker-item.disabled-previous {
  background: #f3f4f6 !important;
  opacity: 0.85;
}

/* Estilos para el sistema de pagos */
.payment-modal {
  max-width: 500px;
  width: 100%;
}

.payment-header {
  text-align: center;
  margin-bottom: 20px;
}

.payment-header h3 {
  margin: 0 0 8px 0;
  color: var(--text-primary);
}

.payment-header p {
  margin: 0;
  color: var(--text-secondary);
}

.payment-content {
  display: flex;
  flex-direction: column;
  gap: 20px;
}

.product-info {
  background: var(--background-secondary);
  padding: 16px;
  border-radius: 8px;
  border: 1px solid var(--border);
}

.product-price {
  text-align: center;
  margin-bottom: 16px;
}

.price-amount {
  font-size: 24px;
  font-weight: bold;
  color: var(--primary-color);
}

.product-features h4 {
  margin: 0 0 8px 0;
  color: var(--text-primary);
}

.product-features ul {
  margin: 0;
  padding-left: 20px;
  color: var(--text-secondary);
}

.product-features li {
  margin-bottom: 4px;
}

.payment-form {
  display: flex;
  flex-direction: column;
  gap: 16px;
}

#payment-element {
  border: 1px solid var(--border);
  border-radius: 8px;
  padding: 12px;
  background: var(--background);
}

.payment-footer {
  text-align: center;
  margin-top: 16px;
  padding-top: 16px;
  border-top: 1px solid var(--border);
}

.payment-security {
  margin: 0;
  color: var(--text-secondary);
  font-size: 14px;
}

/* Estilos para la tienda */
.store-modal {
  max-width: 800px;
  width: 100%;
}

.store-header {
  text-align: center;
  margin-bottom: 24px;
}

.store-header h3 {
  margin: 0 0 8px 0;
  color: var(--text-primary);
}

.store-header p {
  margin: 0;
  color: var(--text-secondary);
}

.products-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(280px, 1fr));
  gap: 20px;
}

.product-card {
  background: var(--background-secondary);
  border: 1px solid var(--border);
  border-radius: 12px;
  padding: 20px;
  display: flex;
  flex-direction: column;
  gap: 16px;
}

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

.product-header h4 {
  margin: 0;
  color: var(--text-primary);
}

.product-price {
  font-size: 20px;
  font-weight: bold;
  color: var(--primary-color);
}

.product-description {
  color: var(--text-secondary);
  line-height: 1.5;
}

.product-features {
  flex-grow: 1;
}

.feature {
  color: var(--text-secondary);
  margin-bottom: 4px;
  font-size: 14px;
}

/* Estilos para el historial de transacciones */
.transactions-modal {
  max-width: 800px;
  width: 100%;
}

.transactions-list {
  display: flex;
  flex-direction: column;
  gap: 12px;
}

.transaction-item {
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding: 16px;
  background: var(--background-secondary);
  border: 1px solid var(--border);
  border-radius: 8px;
}

.transaction-info {
  flex-grow: 1;
}

.transaction-description {
  font-weight: 500;
  color: var(--text-primary);
  margin-bottom: 4px;
}

.transaction-date {
  font-size: 14px;
  color: var(--text-secondary);
}

.transaction-amount {
  font-weight: bold;
  color: var(--primary-color);
  margin: 0 16px;
}

.status-badge {
  padding: 4px 8px;
  border-radius: 4px;
  font-size: 12px;
  font-weight: 500;
  text-transform: uppercase;
}

.status-badge.succeeded {
  background: #dcfce7;
  color: #166534;
}

.status-badge.pending {
  background: #fef3c7;
  color: #92400e;
}

.status-badge.failed {
  background: #fee2e2;
  color: #991b1b;
}

.status-badge.canceled {
  background: #f3f4f6;
  color: #374151;
}

/* Estilos para equipos pendientes */
.pending-teams-list {
  display: flex;
  flex-direction: column;
  gap: 16px;
  padding: 20px 0;
}

.pending-team-item {
  display: flex;
  align-items: center;
  padding: 16px;
  background: #fff;
  border: 1px solid #e0e0e0;
  border-radius: 8px;
  transition: box-shadow 0.2s ease;
}

.pending-team-item:hover {
  box-shadow: 0 2px 8px rgba(0, 0, 0, 0.1);
}

.team-shield-simple {
  width: 50px;
  height: 50px;
  display: flex;
  align-items: center;
  justify-content: center;
  margin-right: 16px;
  flex-shrink: 0;
  background: #f8f9fa;
  border-radius: 50%;
  border: 2px solid #e9ecef;
  position: relative;
  overflow: hidden;
}

.team-logo-img {
  width: 100%;
  height: 100%;
  object-fit: contain;
  padding: 4px;
}

.team-emoji-fallback {
  display: flex;
  align-items: center;
  justify-content: center;
  width: 100%;
  height: 100%;
  font-size: 1.8em;
}

.team-info-simple {
  flex: 1;
  margin-right: 16px;
}

.team-name-simple {
  font-weight: 600;
  font-size: 1.1em;
  color: #333;
  margin-bottom: 4px;
}

.transaction-details-simple {
  font-size: 0.9em;
  color: #666;
}

.date {
  color: #999;
  font-style: italic;
}

.team-actions-simple {
  flex-shrink: 0;
}

.team-actions-simple .btn {
  padding: 10px 20px;
  font-size: 0.9em;
  border-radius: 6px;
  font-weight: 600;
  transition: all 0.2s ease;
  border: none;
  cursor: pointer;
}

.team-actions-simple .btn-primary {
  background: var(--primary-color);
  color: white;
}

.btn-league{
  margin: 0px;
}

.team-actions-simple .btn-primary:hover {
  background: #1e3f6b;
  transform: translateY(-1px);
  box-shadow: 0 2px 8px rgba(44, 90, 160, 0.3);
}

.team-actions-simple .btn-primary:active {
  transform: translateY(0);
  box-shadow: 0 1px 4px rgba(44, 90, 160, 0.3);
}

/* Estilos para selector de equipos */
.teams-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(120px, 1fr));
  gap: 16px;
  padding: 20px 0;
}

.team-card {
  display: flex;
  flex-direction: column;
  align-items: center;
  padding: 16px;
  background: #fff;
  border: 2px solid #e0e0e0;
  border-radius: 8px;
  cursor: pointer;
  transition: all 0.2s ease;
  text-align: center;
}

.team-card:hover {
  border-color: var(--primary-color);
  transform: translateY(-2px);
  box-shadow: 0 4px 12px rgba(44, 90, 160, 0.15);
}

.team-card .team-shield {
  width: 60px;
  height: 60px;
  display: flex;
  align-items: center;
  justify-content: center;
  margin-bottom: 12px;
  background: #f8f9fa;
  border-radius: 50%;
  border: 2px solid #e9ecef;
}

.team-card .team-name {
  font-weight: 600;
  font-size: 0.9em;
  color: #333;
  line-height: 1.2;
}

/* Estilos para modal de nombre de equipo */
.team-name-modal .team-preview {
  display: flex;
  align-items: center;
  gap: 16px;
  padding: 20px;
  background: #f8f9fa;
  border-radius: 8px;
  margin-bottom: 20px;
}

.team-name-modal .team-logo {
  width: 60px;
  height: 60px;
  display: flex;
  align-items: center;
  justify-content: center;
  background: #fff;
  border-radius: 50%;
  border: 2px solid #e9ecef;
  flex-shrink: 0;
}

.team-name-modal .team-info h4 {
  margin: 0 0 4px 0;
  font-size: 1.2em;
  font-weight: 600;
  color: #333;
}

.team-name-modal .team-info p {
  margin: 0;
  color: #666;
  font-size: 0.9em;
}

.team-name-modal .form-group {
  margin-bottom: 20px;
}

.team-name-modal .form-group label {
  display: block;
  margin-bottom: 8px;
  font-weight: 600;
  color: #333;
}

.team-name-modal .form-group input {
  width: 100%;
  padding: 12px;
  border: 2px solid #e9ecef;
  border-radius: 6px;
  font-size: 1em;
  transition: border-color 0.2s ease;
}

.team-name-modal .form-group input:focus {
  outline: none;
  border-color: var(--primary-color);
  box-shadow: 0 0 0 3px rgba(44, 90, 160, 0.1);
}

.team-name-modal .form-help {
  display: block;
  margin-top: 6px;
  font-size: 0.85em;
  color: #666;
  font-style: italic;
}



.modal-footer {
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding: 20px 0 0 0;
  border-top: 1px solid #e0e0e0;
  margin-top: 20px;
}

.empty-state {
  text-align: center;
  padding: 40px 20px;
  color: #666;
  font-size: 1.1em;
}

/* Estilos para información de pago */
.payment-info {
  background: var(--background-secondary);
  padding: 16px;
  border-radius: 8px;
  border: 1px solid var(--border);
  margin: 16px 0;
}

.payment-info p {
  margin: 0 0 12px 0;
  color: var(--text-primary);
}

.payment-features h4 {
  margin: 0 0 8px 0;
  color: var(--text-primary);
}

.payment-features ul {
  margin: 0;
  padding-left: 20px;
  color: var(--text-secondary);
}

.payment-features li {
  margin-bottom: 4px;
}

/* Estilos para selección de equipo después del pago */
.team-selection-modal {
  max-width: 600px;
  width: 100%;
}

.team-selection-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(120px, 1fr));
  gap: 16px;
  margin-top: 16px;
}

.team-option {
  display: flex;
  flex-direction: column;
  align-items: center;
  padding: 16px;
  background: var(--background-secondary);
  border: 1px solid var(--border);
  border-radius: 8px;
  cursor: pointer;
  transition: all 0.2s ease;
}

.team-option:hover {
  border-color: var(--primary-color);
  background: var(--background);
}

.team-shield {
  width: 48px;
  height: 48px;
  display: flex;
  align-items: center;
  justify-content: center;
  margin-bottom: 8px;
}

.team-shield img {
  width: 100%;
  height: 100%;
  object-fit: contain;
}

.team-name {
  text-align: center;
  font-size: 14px;
  color: var(--text-primary);
  font-weight: 500;
}

/* Estados vacíos */
.empty-state {
  text-align: center;
  padding: 40px 20px;
  color: var(--text-secondary);
}

.loading {
  text-align: center;
  padding: 20px;
  color: var(--text-secondary);
}

.error {
  text-align: center;
  padding: 20px;
  color: var(--danger);
}

/* Estilos para Stripe Checkout */
.checkout-info {
  background: var(--background-secondary);
  border: 1px solid var(--border);
  border-radius: 8px;
  padding: 16px;
  margin: 16px 0;
}

.checkout-info p {
  margin: 0 0 12px 0;
  color: var(--text-primary);
  font-size: 14px;
  line-height: 1.5;
}

.payment-methods {
  display: flex;
  gap: 8px;
  flex-wrap: wrap;
}

.payment-method {
  background: var(--background);
  border: 1px solid var(--border);
  border-radius: 6px;
  padding: 6px 12px;
  font-size: 12px;
  color: var(--text-secondary);
  font-weight: 500;
}

.modal-actions {
  display: flex;
  gap: 12px;
  margin-top: 20px;
}

.modal-actions .btn {
  flex: 1;
  padding: 12px 16px;
  font-size: 16px;
  font-weight: 500;
}

.modal-actions .btn-secondary {
  background: var(--background-secondary);
  color: var(--text-primary);
  border: 1px solid var(--border);
}

.modal-actions .btn-secondary:hover {
  background: var(--background);
  color: var(--text-primary);
  border-color: var(--text-secondary);
}

/* Estilos para dispositivos móviles */
@media (max-width: 768px) {
  .modal-actions {
    flex-direction: column;
  }
  
  .modal-actions .btn {
    width: 100%;
  }
  
  .payment-methods {
    justify-content: center;
  }
} 

/* Estilos para el formulario de creación de ligas */
.league-form {
  max-width: 100%;
}

.form-section {
  margin-bottom: 2rem;
  padding-bottom: 1.5rem;
  border-bottom: 1px solid #f0f0f0;
}

.form-section:last-child {
  border-bottom: none;
  margin-bottom: 0;
}

.section-title {
  font-size: 1.1em;
  font-weight: 600;
  color: #333;
  margin: 0 0 1rem 0;
  padding-bottom: 0.5rem;
  border-bottom: 2px solid var(--primary-color);
  display: inline-block;
}

.form-group {
  margin-bottom: 0.5rem;
}

.form-group label {
  display: block;
  font-weight: 600;
  color: #333;
  margin-bottom: 0.5rem;
  font-size: 0.95em;
}

.form-group input,
.form-group textarea,
.form-group select {
  width: 100%;
  padding: 0.75rem;
  border: 2px solid #e1e5e9;
  border-radius: 8px;
  font-size: 0.95em;
  transition: all 0.2s ease;
  background: #fff;
}

.form-group input:focus,
.form-group textarea:focus,
.form-group select:focus {
  outline: none;
  border-color: var(--primary-color);
  box-shadow: 0 0 0 3px rgba(0, 123, 255, 0.1);
}

.form-group textarea {
  resize: vertical;
  min-height: 80px;
}

.form-help {
  display: block;
  font-size: 0.8em;
  color: #666;
  margin-top: 0.25rem;
  font-style: italic;
}

/* Selector de tipo de liga */
.league-type-selector {
  display: flex;
  gap: 1rem;
  margin-top: 0.5rem;
}

.type-option {
  flex: 1;
  cursor: pointer;
}

.type-option input[type="radio"] {
  display: none;
}

.type-card {
  border: 2px solid #e1e5e9;
  border-radius: 12px;
  padding: 1.25rem;
  text-align: center;
  transition: all 0.2s ease;
  background: #fff;
  height: 100%;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
}

.type-option input[type="radio"]:checked + .type-card {
  border-color: var(--primary-color);
  background: linear-gradient(135deg, #f8f9ff 0%, #e8f2ff 100%);
  box-shadow: 0 4px 12px rgba(0, 123, 255, 0.15);
  transform: translateY(-2px);
}

.type-icon {
  font-size: 2.5em;
  margin-bottom: 0.75rem;
  display: block;
}

.type-info h5 {
  margin: 0 0 0.5rem 0;
  font-size: 1.1em;
  font-weight: 600;
  color: #333;
}

.type-info p {
  margin: 0;
  font-size: 0.85em;
  color: #666;
  line-height: 1.4;
}

/* Campos de liga pública */
#public-league-fields {
  transition: opacity 0.3s ease;
}

.number-input-wrapper {
  position: relative;
}

.number-input-wrapper input {
  padding-right: 1rem;
}

/* Botones del modal */
.modal-actions {
  display: flex;
  gap: 1rem;
  justify-content: flex-end;
  margin-top: 2rem;
  padding-top: 1.5rem;
  border-top: 1px solid #f0f0f0;
}

.btn {
  padding: 0.75rem 1.5rem;
  border: none;
  border-radius: 8px;
  font-weight: 600;
  font-size: 0.95em;
  cursor: pointer;
  transition: all 0.2s ease;
  display: inline-flex;
  align-items: center;
  gap: 0.5rem;
  text-decoration: none;
}

.btn-primary {
  background: var(--primary-color);
  color: white;
  box-shadow: 0 2px 8px rgba(0, 123, 255, 0.3);
}

.btn-primary:hover {
  transform: translateY(-1px);
  box-shadow: 0 4px 12px rgba(0, 123, 255, 0.4);
}

.btn-secondary {
  background: #f8f9fa;
  color: #666;
  border: 2px solid #e1e5e9;
}

.btn-secondary:hover {
  background: #e9ecef;
  color: #333;
  border-color: #adb5bd;
}

.btn-icon {
  font-size: 1.1em;
}

/* Responsive */
@media (max-width: 768px) {
  .league-type-selector {
    flex-direction: column;
  }
  
  .modal-actions {
    flex-direction: column;
  }
  
  .btn {
    justify-content: center;
  }
  
  /* Modal responsive para móvil */
  .modal-overlay {
    padding: 10px;
  }
  
  .modal {
    max-height: calc(100vh - 20px);
    overflow-y: auto;
  }
  
  .modal-content {
    max-height: calc(100vh - 200px);
    overflow-y: auto;
    padding: 1rem;
    gap: 10px;
  }
  
  .league-form {
    max-height: none;
  }
  
  .form-section {
    margin-bottom: 1.5rem;
    padding-bottom: 1rem;
  }
  
  .form-group {
    margin-bottom: 1rem;
  }
  
  .form-group input,
  .form-group textarea,
  .form-group select {
    padding: 0.6rem;
    font-size: 16px; /* Evita zoom en iOS */
  }
  
  .type-card {
    padding: 1rem;
  }
  
  .type-icon {
    font-size: 2em;
  }
  
  .type-info h5 {
    font-size: 1em;
  }
  
  .type-info p {
    font-size: 0.8em;
  }
  
  /* Ajustes para el modal de unión */
  .join-league-info {
    max-height: calc(100vh - 250px);
    overflow-y: auto;
    display: flex;
    flex-direction: column;
    gap: 20px;
  }
  
  .league-summary {
    padding: 1rem;
  }
  
  .league-stats-grid {
    grid-template-columns: 1fr;
    gap: 0.75rem;
  }
  
  .stat-item {
    padding: 0.5rem;
  }
  
  .league-description,
  .stat-item.prize,
  .participation-conditions,
  .join-requirements {
    padding: 0.75rem;
    margin-bottom: 1rem;
  }
  
  .join-confirmation {
    padding: 1rem;
    margin-top: 1.5rem;
  }
  
  /* Mejoras adicionales para móvil */
  .modal-content {
    -webkit-overflow-scrolling: touch; /* Scroll suave en iOS */
  }
  
  /* Evitar que el modal se mueva cuando aparece el teclado */
  .modal-overlay {
    align-items: flex-start;
    padding-top: 20px;
  }
  
  /* Ajustar altura máxima en móvil */
  .modal {
    max-height: calc(100vh - 40px);
  }
  
  /* Mejorar espaciado en móvil */
  .form-section {
    margin-bottom: 1rem;
  }
  
  .section-title {
    font-size: 1em;
    margin-bottom: 0.75rem;
  }
  
  /* Reducir padding en móvil */
  .modal .modal-header {
    padding: 1rem 1rem 0 1rem;
  }
  
  .modal .modal-actions {
    padding: 0 1rem 1rem 1rem;
  }
  
  /* Asegurar que los inputs sean legibles */
  .form-group input,
  .form-group textarea {
    font-size: 16px !important; /* Evita zoom en iOS */
    line-height: 1.4;
  }
  
  /* Mejorar contraste en móvil */
  .form-help {
    font-size: 0.75em;
    color: #777;
  }
  
  /* Ajustes para cuando el teclado está abierto */
  @media (max-height: 500px) {
    .modal-overlay {
      align-items: flex-start;
      padding-top: 10px;
    }
    
    .modal {
      max-height: calc(100vh - 20px);
    }
    
    .modal .modal-header {
      padding: 0.75rem 1rem 0 1rem;
    }
    
    .modal .modal-header h3 {
      font-size: 1.1em;
      margin-bottom: 0.25rem;
    }
    
    .modal .modal-header p {
      font-size: 0.8em;
    }
    
    .form-section {
      margin-bottom: 0.75rem;
      padding-bottom: 0.75rem;
    }
    
    .form-group {
      margin-bottom: 0.75rem;
    }
    
    .form-group textarea {
      rows: 1;
      min-height: 60px;
    }
    
    .type-card {
      padding: 0.75rem;
    }
    
    .type-icon {
      font-size: 1.5em;
      margin-bottom: 0.5rem;
    }
    
    .type-info h5 {
      font-size: 0.9em;
      margin-bottom: 0.25rem;
    }
    
    .type-info p {
      font-size: 0.75em;
    }
  }
}

/* Animaciones */
@keyframes fadeIn {
  from {
    opacity: 0;
    transform: translateY(10px);
  }
  to {
    opacity: 1;
    transform: translateY(0);
  }
}

.form-section {
  animation: fadeIn 0.3s ease;
}

/* Mejoras para el modal existente */
.modal-overlay {
  overflow-y: auto;
  -webkit-overflow-scrolling: touch;
}

.modal {
  overflow-y: auto;
  -webkit-overflow-scrolling: touch;
}

/* Prevenir scroll del body cuando el modal está abierto */
body.modal-open {
  overflow: hidden;
  position: fixed;
  width: 100%;
}

/* Mejoras para desktop */
@media (min-width: 769px) {
  .modal-overlay {
    padding: 20px;
  }
  
  .modal {
    max-width: 600px;
    max-height: 85vh;
  }
  
  .modal-content {
    padding: 0 25px 25px;
  }
  
  .league-form {
    max-height: 60vh;
    overflow-y: auto;
  }
}

/* Estados de validación */
.form-group input:invalid,
.form-group textarea:invalid {
  border-color: #dc3545;
}

.form-group input:valid,
.form-group textarea:valid {
  border-color: #28a745;
}

/* Placeholder styling */
.form-group input::placeholder,
.form-group textarea::placeholder {
  color: #adb5bd;
  font-style: italic;
}

/* Estilos para el modal de unión a ligas públicas */
.join-league-info {
  max-width: 100%;
}

.league-summary {
  background: linear-gradient(135deg, #f8f9ff 0%, #e8f2ff 100%);
  border-radius: 12px;
  padding: 1.5rem;
  margin-bottom: 1.5rem;
  border-left: 4px solid var(--primary-color);
}

.league-stats-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(200px, 1fr));
  gap: 1rem;
  margin-top: 1rem;
}

.stat-item {
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding: 0.75rem;
  background: white;
  border-radius: 8px;
  border: 1px solid #e1e5e9;
}

.stat-item.prize {
  background: linear-gradient(135deg, #fff8e1 0%, #ffecb3 100%);
  border-color: #ffc107;
}

.stat-label {
  font-weight: 600;
  color: #333;
  font-size: 0.9em;
}

.stat-value {
  font-weight: 700;
  color: var(--primary-color);
  font-size: 0.95em;
}

.stat-item.prize .stat-value {
  color: #f57c00;
}

.league-description,
.participation-conditions,
.join-requirements {
  margin-bottom: 1.5rem;
  padding: 1rem;
  background: #f8f9fa;
  border-radius: 8px;
  border-left: 3px solid #28a745;
}

.league-description h5,
.participation-conditions h5,
.join-requirements h5 {
  margin: 0 0 0.75rem 0;
  font-size: 1em;
  font-weight: 600;
  color: #333;
}

.league-description p,
.participation-conditions p {
  margin: 0;
  line-height: 1.5;
  color: #555;
}

.conditions-box {
  background: white;
  padding: 1rem;
  border-radius: 6px;
  border: 1px solid #e1e5e9;
  margin-top: 0.5rem;
}

.requirements-list {
  margin: 0;
  padding-left: 1.5rem;
}

.requirements-list li {
  margin-bottom: 0.5rem;
  line-height: 1.4;
  color: #555;
}

.join-confirmation {
  margin-top: 2rem;
  padding: 1.5rem;
  background: #fff3cd;
  border: 1px solid #ffeaa7;
  border-radius: 8px;
}

.checkbox-container {
  display: flex;
  align-items: flex-start;
  gap: 0.75rem;
  cursor: pointer;
  position: relative;
}

.checkbox-container input[type="checkbox"] {
  position: absolute;
  opacity: 0;
  cursor: pointer;
  height: 0;
  width: 0;
}

.checkmark {
  height: 20px;
  width: 20px;
  background-color: #fff;
  border: 2px solid var(--primary-color);
  border-radius: 4px;
  flex-shrink: 0;
  margin-top: 2px;
  position: relative;
  transition: all 0.2s ease;
}

.checkbox-container:hover input ~ .checkmark {
  background-color: #f0f8ff;
}

.checkbox-container input:checked ~ .checkmark {
  background-color: var(--primary-color);
}

.checkmark:after {
  content: "";
  position: absolute;
  display: none;
}

.checkbox-container input:checked ~ .checkmark:after {
  display: block;
}

.checkbox-container .checkmark:after {
  left: 6px;
  top: 2px;
  width: 5px;
  height: 10px;
  border: solid white;
  border-width: 0 2px 2px 0;
  transform: rotate(45deg);
}

.checkbox-text {
  font-size: 0.9em;
  line-height: 1.4;
  color: #333;
  font-weight: 500;
}

/* Estilos para ligas públicas */
.public-league-card {
  border: 2px solid #e8f5e8;
  background: linear-gradient(135deg, #f8fff8 0%, #f0fff0 100%);
}

.public-league-card:hover {
  border-color: #28a745;
  box-shadow: 0 4px 12px rgba(40, 167, 69, 0.15);
}

/* Responsive para el modal */
@media (max-width: 768px) {
  .league-stats-grid {
    grid-template-columns: 1fr;
  }
  
  .stat-item {
    flex-direction: column;
    align-items: flex-start;
    gap: 0.25rem;
  }
  
  .checkbox-container {
    flex-direction: column;
    align-items: flex-start;
  }
  
  .checkmark {
    margin-top: 0;
  }
}

/* Estilos para tabs de amigos/ligas */
.friends-tabs-container {
  width: 100%;
}

.friends-tabs {
  display: flex;
  background: #f8f9fa;
  border-radius: 12px;
  padding: 4px;
  margin-bottom: 20px;
  gap: 4px;
  overflow-x: auto;
  scrollbar-width: none;
  -ms-overflow-style: none;
}

.friends-tabs::-webkit-scrollbar {
  display: none;
}

.friends-tabs .tab-btn {
  flex: 1;
  min-width: 120px;
  padding: 12px 16px;
  border: none;
  background: transparent;
  border-radius: 8px;
  font-size: 0.9em;
  font-weight: 600;
  color: #666;
  cursor: pointer;
  transition: all 0.2s ease;
  position: relative;
  white-space: nowrap;
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 6px;
}

.friends-tabs .tab-btn:hover {
  background: rgba(0, 123, 255, 0.1);
  color: var(--primary-color);
}

.friends-tabs .tab-btn.active {
  background: var(--primary-color);
  color: white;
  box-shadow: 0 2px 8px rgba(0, 123, 255, 0.3);
}

.friends-tabs .tab-count {
  background: rgba(255, 255, 255, 0.2);
  color: inherit;
  padding: 2px 6px;
  border-radius: 10px;
  font-size: 0.75em;
  font-weight: 700;
  min-width: 18px;
  text-align: center;
}

.tab-content {
  animation: fadeIn 0.3s ease;
}

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

/* Estilos para diferentes estados de transacciones */
.transaction-section {
  margin-bottom: 2rem;
}

.transaction-section .section-title {
  font-size: 1.1em;
  font-weight: 600;
  color: #333;
  margin-bottom: 1rem;
  padding-bottom: 0.5rem;
  border-bottom: 2px solid #f0f0f0;
}

/* Estados de transacciones */
.pending-team-item.status-pending {
  opacity: 0.7;
  border-left: 4px solid #ffc107;
}

.pending-team-item.status-success {
  border-left: 4px solid #28a745;
}

.pending-team-item.status-failed,
.pending-team-item.status-canceled {
  opacity: 0.6;
  border-left: 4px solid #dc3545;
}

.pending-team-item.status-unknown {
  border-left: 4px solid #6c757d;
}

/* Badges de estado */
.status-badge {
  display: inline-block;
  padding: 2px 8px;
  border-radius: 12px;
  font-size: 0.75em;
  font-weight: 500;
  text-transform: uppercase;
  letter-spacing: 0.5px;
}

.status-badge.status-pending {
  background-color: #fff3cd;
  color: #856404;
}

.status-badge.status-success {
  background-color: #d4edda;
  color: #155724;
}

.status-badge.status-failed,
.status-badge.status-canceled {
  background-color: #f8d7da;
  color: #721c24;
}

.status-badge.status-unknown {
  background-color: #e2e3e5;
  color: #383d41;
}

/* Botones de acción */
.team-actions-simple .btn-danger {
  background-color: #dc3545;
  color: white;
  border: none;
}

.team-actions-simple .btn-danger:hover {
  background-color: #c82333;
}

.team-actions-simple .btn-secondary:disabled {
  background-color: #6c757d;
  color: #fff;
  cursor: not-allowed;
  opacity: 0.6;
}

/* Estilos para pantalla de unión a liga */
.league-join-bg {
  min-height: 100vh;
  background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 20px;
}

.league-join-card {
  background: white;
  border-radius: 20px;
  padding: 30px;
  max-width: 500px;
  width: 100%;
  box-shadow: 0 20px 40px rgba(0, 0, 0, 0.1);
  text-align: center;
}

.league-join-header {
  margin-bottom: 30px;
}

.league-join-shield {
  height: 96px;
  margin: 0 auto 20px;
  display: flex;
  align-items: center;
  justify-content: center;
}

.league-join-title {
  font-size: 1.8em;
  font-weight: 800;
  color: #333;
  margin: 0 0 10px 0;
}

.league-join-admin {
  color: #666;
  font-size: 0.9em;
}

.league-join-members {
  margin-bottom: 30px;
  text-align: left;
}

.league-join-members h4 {
  margin: 0 0 15px 0;
  color: #333;
  font-size: 1.1em;
}

.league-join-members-list {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
}

.league-member-pill {
  background: #f8f9fa;
  color: #495057;
  padding: 6px 12px;
  border-radius: 20px;
  font-size: 0.85em;
  border: 1px solid #e9ecef;
}

.league-join-actions {
  margin-bottom: 20px;
}

.league-join-btn {
  width: 100%;
  padding: 15px;
  font-size: 1.1em;
  font-weight: 600;
}

.league-join-status {
  background: #e9ecef;
  color: #495057;
  padding: 15px;
  border-radius: 8px;
  font-weight: 500;
}

.league-join-content {
  padding: 20px 0;
}

.league-join-content p {
  margin: 0;
  padding: 0;
}

.league-join-back {
  margin-top: 20px;
}

.league-error {
  color: #dc3545;
  text-align: center;
}

.league-error h3 {
  margin: 0 0 15px 0;
  color: #dc3545;
}

.league-error p {
  margin: 0 0 20px 0;
  color: #666;
}

/* Estilos para upload de imagen de liga */
.image-upload-container {
  margin-top: 10px;
}

.image-preview {
  width: 120px;
  height: 120px;
  border: 2px dashed #ddd;
  border-radius: 8px;
  display: flex;
  align-items: center;
  justify-content: center;
  margin-bottom: 10px;
  position: relative;
  overflow: hidden;
  background: #f8f9fa;
  transition: all 0.3s ease;
}

.image-preview:hover {
  border-color: var(--primary-color);
  background: #f0f0f0;
}

.image-placeholder {
  text-align: center;
  color: #666;
}

.image-placeholder span {
  font-size: 2em;
  display: block;
  margin-bottom: 5px;
}

.image-placeholder p {
  font-size: 0.8em;
  margin: 0;
}

.image-preview img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  border-radius: 6px;
}

.remove-image-btn {
  position: absolute;
  top: 5px;
  right: 5px;
  width: 24px;
  height: 24px;
  border-radius: 50%;
  background: rgba(0, 0, 0, 0.7);
  color: white;
  border: none;
  cursor: pointer;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 12px;
  transition: all 0.2s ease;
}

.remove-image-btn:hover {
  background: rgba(0, 0, 0, 0.9);
  transform: scale(1.1);
}

/* Estilos para mostrar imagen de liga en las listas */
.league-image {
  width: 60px;
  height: 60px;
  border-radius: 50%;
  object-fit: cover;
  margin-right: 12px;
  border: 2px solid #e5e7eb;
}

.league-card-header {
  display: flex;
  align-items: center;
}

.league-card-header .league-image {
  flex-shrink: 0;
}

.league-card-title {
  flex: 1;
  margin-left: 0;
}

/* Responsive para imágenes de liga */
@media (max-width: 768px) {
  .image-preview {
    width: 100px;
    height: 100px;
  }
  
  .league-image {
    width: 50px;
    height: 50px;
    margin-right: 8px;
  }
}

/* Estilos para el nombre del equipo no editable */
.team-name-display {
  text-align: center;
  padding: 20px;
  background: var(--color-background);
  border-radius: 8px;
  border: 1px solid var(--color-border);
}

.team-name-display h3 {
  margin: 0 0 8px 0;
  color: var(--color-text);
  font-size: 1.5em;
  font-weight: 600;
}

.team-name-hint {
  margin: 0;
  color: var(--color-text-muted);
  font-size: 0.7em;
  font-style: italic;
}

/* Estilos para el título con puntos destacados */
.team-title-with-points {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 12px;
  flex-wrap: wrap;
}

.team-title-text {
  font-size: 1.5em;
  font-weight: 600;
  color: var(--text-primary);
}

.team-points-badge {
  background: linear-gradient(135deg, var(--gold) 0%, var(--gold-light) 100%);
  color: var(--text-dark);
  padding: 10px 18px;
  border-radius: 25px;
  font-weight: 800;
  font-size: 1.2em;
  box-shadow: 0 6px 20px rgba(255, 215, 0, 0.4);
  border: 3px solid var(--gold-dark);
  animation: pulse-glow 2s ease-in-out infinite alternate;
  text-shadow: 0 2px 4px rgba(0, 0, 0, 0.2);
  min-width: 90px;
  text-align: center;
  position: relative;
  overflow: hidden;
}

.team-points-badge::before {
  content: '';
  position: absolute;
  top: 0;
  left: -100%;
  width: 100%;
  height: 100%;
  background: linear-gradient(90deg, transparent, rgba(255, 255, 255, 0.3), transparent);
  animation: shine 3s infinite;
}

.team-points-badge.high-points {
  background: linear-gradient(135deg, var(--success) 0%, #34d399 100%);
  border-color: var(--success-dark);
  box-shadow: 0 6px 20px rgba(16, 185, 129, 0.4);
}

.team-points-badge.medium-points {
  background: linear-gradient(135deg, var(--warning) 0%, #fbbf24 100%);
  border-color: var(--warning-dark);
  box-shadow: 0 6px 20px rgba(245, 158, 11, 0.4);
}

.team-points-badge.low-points {
  background: linear-gradient(135deg, var(--danger) 0%, #f87171 100%);
  border-color: var(--danger-dark);
  box-shadow: 0 6px 20px rgba(239, 68, 68, 0.4);
}

@keyframes pulse-glow {
  0% {
    box-shadow: 0 6px 20px rgba(255, 215, 0, 0.4);
    transform: scale(1);
  }
  100% {
    box-shadow: 0 8px 25px rgba(255, 215, 0, 0.6);
    transform: scale(1.05);
  }
}

@keyframes shine {
  0% {
    left: -100%;
  }
  50% {
    left: 100%;
  }
  100% {
    left: 100%;
  }
}

.team-points-badge.high-points {
  animation: pulse-glow-success 2s ease-in-out infinite alternate;
}

@keyframes pulse-glow-success {
  0% {
    box-shadow: 0 6px 20px rgba(16, 185, 129, 0.4);
    transform: scale(1);
  }
  100% {
    box-shadow: 0 8px 25px rgba(16, 185, 129, 0.6);
    transform: scale(1.05);
  }
}

.team-points-badge.medium-points {
  animation: pulse-glow-warning 2s ease-in-out infinite alternate;
}

@keyframes pulse-glow-warning {
  0% {
    box-shadow: 0 6px 20px rgba(245, 158, 11, 0.4);
    transform: scale(1);
  }
  100% {
    box-shadow: 0 8px 25px rgba(245, 158, 11, 0.6);
    transform: scale(1.05);
  }
}

.team-points-badge.low-points {
  animation: pulse-glow-danger 2s ease-in-out infinite alternate;
}

@keyframes pulse-glow-danger {
  0% {
    box-shadow: 0 6px 20px rgba(239, 68, 68, 0.4);
    transform: scale(1);
  }
  100% {
    box-shadow: 0 8px 25px rgba(239, 68, 68, 0.6);
    transform: scale(1.05);
  }
}

/* Responsive para el título con puntos */
@media (max-width: 600px) {
  .team-title-text {
    font-size: 1.3em;
  }
  
  .team-points-badge {
    font-size: 1.1em;
    padding: 8px 14px;
    min-width: 80px;
  }
}

/* Estilos para la leyenda de selección de equipo */
.team-selection-legend {
  margin-top: 5px;
  text-align: center;
  padding: 8px 16px;
  background: var(--surface-secondary);
  border-radius: var(--border-radius);
  border: 1px solid var(--border-light);
}

.legend-content {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 6px;
  font-size: 0.75em;
  color: var(--text-secondary);
}

.legend-icon {
  font-size: 0.8em;
  opacity: 0.8;
}

.legend-text {
  font-weight: 500;
  letter-spacing: 0.02em;
}

/* Animación sutil para la leyenda */
.team-selection-legend {
  animation: fadeInUp 0.3s ease-out;
}

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

/* Responsive para la leyenda */
@media (max-width: 600px) {
  .team-selection-legend {
    margin-top: 4px;
    padding: 6px 12px;
  }
  
  .legend-content {
    font-size: 0.7em;
    gap: 4px;
  }
  
  .legend-icon {
    font-size: 0.75em;
  }
}

/* Estilos para la información de uso de jugadores */
.player-usage-info {
  margin-top: 4px;
  font-size: 0.75em;
  padding: 2px 6px;
  border-radius: 4px;
  text-align: center;
  font-weight: 500;
}

.player-usage-info.usage-high {
  background: rgba(34, 197, 94, 0.1);
  color: var(--color-success);
  border: 1px solid rgba(34, 197, 94, 0.3);
}

.player-usage-info.usage-medium {
  background: rgba(251, 191, 36, 0.1);
  color: var(--color-warning);
  border: 1px solid rgba(251, 191, 36, 0.3);
}

.player-usage-info.usage-low {
  background: rgba(239, 68, 68, 0.1);
  color: var(--color-danger);
  border: 1px solid rgba(239, 68, 68, 0.3);
}

.usage-text {
  font-size: 0.85em;
}

.usage-text strong {
  font-weight: 600;
}

.usage-warning {
  display: block;
  margin-top: 2px;
  font-size: 0.8em;
  font-weight: 600;
  color: var(--color-danger);
}

/* Estilos para jugadores sin usos restantes */
.player-picker-item.disabled-no-uses {
  opacity: 0.6;
  background: #f8f9fa;
}

.player-picker-item.disabled-no-uses .player-usage-info {
  background: rgba(239, 68, 68, 0.2);
  color: var(--color-danger);
  border-color: var(--color-danger);
}

/* Estilos para el loading del selector de jugadores */
.player-picker-loading {
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  padding: 3rem 2rem;
  text-align: center;
}

.player-picker-loading p {
  margin-top: 1rem;
  color: var(--text-secondary);
  font-size: 1rem;
}

.loading-spinner {
  width: 40px;
  height: 40px;
  border: 3px solid var(--border-light);
  border-top: 3px solid var(--color-primary);
  border-radius: 50%;
  animation: spin 1s linear infinite;
}

@keyframes spin {
  0% { transform: rotate(0deg); }
  100% { transform: rotate(360deg); }
}

/* Estilos para el error del selector de jugadores */
.player-picker-error {
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  padding: 3rem 2rem;
  text-align: center;
}

.player-picker-error p {
  margin-bottom: 1rem;
  color: var(--color-danger);
  font-size: 1rem;
  font-weight: 500;
}

.player-picker-error .btn {
  margin-top: 1rem;
}

/* Estilos para el ranking con escudo y nombre de equipo */
.ranking-team-info {
  display: flex;
  flex-direction: column;
  gap: 0px;
  flex: 1;
  min-width: 0; /* Permite que el contenido se comprima */
  overflow: hidden;
  padding-bottom: 0px;
}

.ranking-team-main {
  display: flex;
  align-items: center;
  gap: 0.5em;
  margin-bottom: 2px;
}
.ranking-team-shield {
  width: 28px;
  height: 28px;
  display: inline-block;
  vertical-align: middle;
}
.ranking-team-name {
  font-weight: 600;
  font-size: 1em;
  color: var(--primary-text, #222);
  margin-left: 2px;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;  
  text-transform: uppercase;
}
.ranking-team-shield-svg {
  align-items: center;
  justify-content: center;
}

/* Estilos para ligas de admin mejorados - diseño más sutil */
.admin-league-card {
  position: relative;
  overflow: hidden;
  border-radius: 8px;
  box-shadow: 0 2px 8px rgba(0,0,0,0.08);
  border: 1px solid #e9ecef;
}

/* Efectos hover sutiles */
.admin-league-card:hover {
  transform: translateY(-1px);
  box-shadow: 0 4px 12px rgba(0,0,0,0.12);
  transition: all 0.2s ease;
}

/* Mejoras para badges de admin */
.admin-league-card .league-badge {
  font-weight: 600;
  font-size: 0.7em;
  border-radius: 6px;
}

/* Botones mejorados para admin */
.admin-league-card .league-card-actions .btn {
  transition: all 0.2s ease;
  border-radius: 6px;
  font-weight: 600;
  font-size: 0.85em;
  padding: 8px 12px;
  border: 1px solid var(--border);
  cursor: pointer;
  min-width: 80px;
  text-align: center;
  background: var(--surface-tertiary);
  text-transform: uppercase;
}

.admin-league-card .league-card-actions .btn:hover {
  transform: translateY(-1px);
  box-shadow: 0 3px 6px rgba(0,0,0,0.2);
  opacity: 0.9;
}

.admin-league-card .league-card-actions .btn:active {
  transform: translateY(0);
}

/* Responsive para admin cards */
@media (max-width: 768px) {
  .admin-league-card .league-card-actions {
    flex-direction: column;
    gap: 8px;
  }
  
  .admin-league-card .league-card-actions .btn {
    width: 100%;
    justify-content: center;
    padding: 10px 12px;
  }
  
  .admin-league-card .league-badge {
    font-size: 0.65em;
    padding: 2px 6px;
  }
  
}

/* Mejoras para el contador de miembros */
.admin-league-card .league-card-meta {
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

/* Icono sutil para admin */
.admin-league-card .league-icon {
  box-shadow: 0 1px 3px rgba(0,0,0,0.1);
}

/* Estilos para username en rankings de ligas privadas */
.ranking-team-details {
  display: flex;
  flex-direction: column;
  gap: 0px;
}

.ranking-team-username {
  font-size: 0.75em;
  color: #666;
  font-weight: 400;
  opacity: 0.8;
}

/* Estilos para secciones y estados vacíos */
.section-description {
  margin: 0 0 20px 0;
  color: #64748b;
  font-size: 0.95em;
  line-height: 1.5;
}

.empty-state {
  text-align: center;
  padding: 40px 20px;
  color: #64748b;
}

.empty-icon {
  font-size: 3em;
  margin-bottom: 20px;
  opacity: 0.7;
}

.empty-state h3 {
  margin-bottom: 10px;
  color: #334155;
  font-size: 1.2em;
  font-weight: 600;
}

.empty-state p {
  margin-bottom: 20px;
  color: #64748b;
  font-size: 0.95em;
  line-height: 1.5;
}

/* Estilos para imágenes de liga */
.league-image {
  width: 48px;
  height: 48px;
  object-fit: cover;
  border-radius: 12px;
  border: 2px solid #e2e8f0;
  flex-shrink: 0;
  box-shadow: 0 2px 4px rgba(0, 0, 0, 0.1);
}

/* Estilos para tarjetas específicas */
.member-league-card {
  border-left: 4px solid #0ea5e9;
  background: linear-gradient(135deg, #ffffff 0%, #f0f9ff 100%);
}

.public-league-card {
  border-left: 4px solid #22c55e;
  background: linear-gradient(135deg, #ffffff 0%, #f0fdf4 100%);
}

/* Estilos para botones específicos de ligas - Sistema de colores coherente */
.btn-league {
  background: linear-gradient(135deg, #3b82f6, #2563eb);
  color: white;
  border: none;
  box-shadow: 0 2px 4px rgba(59, 130, 246, 0.3);
  transition: all 0.2s ease;
}

.btn-league:hover {
  background: linear-gradient(135deg, #2563eb, #1d4ed8);
  transform: translateY(-1px);
  box-shadow: 0 4px 8px rgba(59, 130, 246, 0.4);
}

.btn-success {
  background: linear-gradient(135deg, #10b981, #059669);
  color: white;
  border: none;
  box-shadow: 0 2px 4px rgba(16, 185, 129, 0.3);
  transition: all 0.2s ease;
}

.btn-success:hover {
  background: linear-gradient(135deg, #059669, #047857);
  transform: translateY(-1px);
  box-shadow: 0 4px 8px rgba(16, 185, 129, 0.4);
}

.btn-warning {
  background: linear-gradient(135deg, #f59e0b, #d97706);
  color: white;
  border: none;
  box-shadow: 0 2px 4px rgba(245, 158, 11, 0.3);
  transition: all 0.2s ease;
}

.btn-warning:hover {
  background: linear-gradient(135deg, #d97706, #b45309);
  transform: translateY(-1px);
  box-shadow: 0 4px 8px rgba(245, 158, 11, 0.4);
}

.btn-secondary {
  background: linear-gradient(135deg, #6b7280, #4b5563);
  color: white;
  border: none;
  box-shadow: 0 2px 4px rgba(107, 114, 128, 0.3);
  transition: all 0.2s ease;
}

.btn-secondary:hover {
  background: linear-gradient(135deg, #4b5563, #374151);
  color: white;
  transform: translateY(-1px);
  box-shadow: 0 4px 8px rgba(107, 114, 128, 0.4);
}

.btn-danger {
  background: linear-gradient(135deg, #ef4444, #dc2626);
  color: white;
  border: none;
  box-shadow: 0 2px 4px rgba(239, 68, 68, 0.3);
  transition: all 0.2s ease;
}

.btn-danger:hover {
  background: linear-gradient(135deg, #dc2626, #b91c1c);
  transform: translateY(-1px);
  box-shadow: 0 4px 8px rgba(239, 68, 68, 0.4);
}

/* Estilos específicos para botones de ligas públicas y privadas */
.fullwidth-card .league-card-actions .btn {
  font-weight: 600;
  font-size: 0.9rem;
  padding: 0.6rem 1.2rem;
  border-radius: 0.5rem;
  text-transform: none;
  letter-spacing: 0.025em;
  min-width: 100px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 0.5rem;
  transition: all 0.2s ease;
}

/* Botones principales de la sección de amigos */
.friends-section .btn-primary,
.private-leagues-section .btn-primary,
.public-leagues-section .btn-primary {
  background: linear-gradient(135deg, #3b82f6, #2563eb);
  color: white;
  border: none;
  box-shadow: 0 2px 4px rgba(59, 130, 246, 0.3);
  font-weight: 600;
  padding: 0.75rem 1.5rem;
  border-radius: 0.5rem;
  transition: all 0.2s ease;
}

.friends-section .btn-primary:hover,
.private-leagues-section .btn-primary:hover,
.public-leagues-section .btn-primary:hover {
  background: linear-gradient(135deg, #2563eb, #1d4ed8);
  transform: translateY(-1px);
  box-shadow: 0 4px 8px rgba(59, 130, 246, 0.4);
}

/* Botón para crear liga */
.create-league-btn {
  background: linear-gradient(135deg, #10b981, #059669);
  color: white;
  border: none;
  box-shadow: 0 2px 4px rgba(16, 185, 129, 0.3);
  font-weight: 600;
  padding: 0.75rem 1.5rem;
  border-radius: 0.5rem;
  transition: all 0.2s ease;
}

.create-league-btn:hover {
  background: linear-gradient(135deg, #059669, #047857);
  transform: translateY(-1px);
  box-shadow: 0 4px 8px rgba(16, 185, 129, 0.4);
}

/* Botón para verificar ligas públicas */
.check-public-leagues-btn {
  background: linear-gradient(135deg, #6b7280, #4b5563);
  color: white;
  border: none;
  box-shadow: 0 2px 4px rgba(107, 114, 128, 0.3);
  font-weight: 600;
  padding: 0.75rem 1.5rem;
  border-radius: 0.5rem;
  transition: all 0.2s ease;
}

.check-public-leagues-btn:hover {
  background: linear-gradient(135deg, #4b5563, #374151);
  transform: translateY(-1px);
  box-shadow: 0 4px 8px rgba(107, 114, 128, 0.4);
}

/* Botones de acción rápida */
.action-btn {
  background: linear-gradient(135deg, #3b82f6, #2563eb);
  color: white;
  border: none;
  box-shadow: 0 2px 4px rgba(59, 130, 246, 0.3);
  font-weight: 600;
  padding: 0.5rem 1rem;
  border-radius: 0.5rem;
  font-size: 0.85rem;
  transition: all 0.2s ease;
}

.action-btn:hover {
  background: linear-gradient(135deg, #2563eb, #1d4ed8);
  transform: translateY(-1px);
  box-shadow: 0 4px 8px rgba(59, 130, 246, 0.4);
}

/* Botones de estado */
.status-btn {
  background: linear-gradient(135deg, #6b7280, #4b5563);
  color: white;
  border: none;
  box-shadow: 0 2px 4px rgba(107, 114, 128, 0.3);
  font-weight: 500;
  padding: 0.4rem 0.8rem;
  border-radius: 0.4rem;
  font-size: 0.8rem;
  transition: all 0.2s ease;
}

.status-btn:hover {
  background: linear-gradient(135deg, #4b5563, #374151);
  transform: translateY(-1px);
  box-shadow: 0 4px 8px rgba(107, 114, 128, 0.4);
}

/* Botón principal para unirse/apuntarse */
.fullwidth-card .league-card-actions .btn-success {
  background: linear-gradient(135deg, #10b981, #059669);
  color: white;
  border: none;
  box-shadow: 0 2px 4px rgba(16, 185, 129, 0.3);
}

.fullwidth-card .league-card-actions .btn-success:hover {
  background: linear-gradient(135deg, #059669, #047857);
  transform: translateY(-1px);
  box-shadow: 0 4px 8px rgba(16, 185, 129, 0.4);
}

/* Botón para invitar */
.fullwidth-card .league-card-actions .btn-league {
  background: linear-gradient(135deg, #3b82f6, #2563eb);
  color: white;
  border: none;
  box-shadow: 0 2px 4px rgba(59, 130, 246, 0.3);
}

.fullwidth-card .league-card-actions .btn-league:hover {
  background: linear-gradient(135deg, #2563eb, #1d4ed8);
  transform: translateY(-1px);
  box-shadow: 0 4px 8px rgba(59, 130, 246, 0.4);
}

/* Botón para editar/ver detalles */
.fullwidth-card .league-card-actions .btn-secondary {
  background: linear-gradient(135deg, #6b7280, #4b5563);
  color: white;
  border: none;
  box-shadow: 0 2px 4px rgba(107, 114, 128, 0.3);
}

.fullwidth-card .league-card-actions .btn-secondary:hover {
  background: linear-gradient(135deg, #4b5563, #374151);
  transform: translateY(-1px);
  box-shadow: 0 4px 8px rgba(107, 114, 128, 0.4);
}

/* Botón para solicitudes */
.fullwidth-card .league-card-actions .btn-warning {
  background: linear-gradient(135deg, #f59e0b, #d97706);
  color: white;
  border: none;
  box-shadow: 0 2px 4px rgba(245, 158, 11, 0.3);
}

.fullwidth-card .league-card-actions .btn-warning:hover {
  background: linear-gradient(135deg, #d97706, #b45309);
  transform: translateY(-1px);
  box-shadow: 0 4px 8px rgba(245, 158, 11, 0.4);
}

/* Botón para abandonar */
.fullwidth-card .league-card-actions .btn-danger {
  background: linear-gradient(135deg, #ef4444, #dc2626);
  color: white;
  border: none;
  box-shadow: 0 2px 4px rgba(239, 68, 68, 0.3);
}

.fullwidth-card .league-card-actions .btn-danger:hover {
  background: linear-gradient(135deg, #dc2626, #b91c1c);
  transform: translateY(-1px);
  box-shadow: 0 4px 8px rgba(239, 68, 68, 0.4);
}

/* Responsive para móvil */
@media (max-width: 480px) {

  .fullwidth-card {
    padding: 12px;
    margin: 0 0 8px 0;
  }
  
  .league-header-main {
    gap: 8px;
  }
  
  .league-icon {
    width: 36px;
    height: 36px;
    font-size: 1.3em;
  }
  
  .league-card-title {
    font-size: 1.05em;
  }
  
  .league-badges {
    gap: 4px;
  }
  
  .league-badge {
    font-size: 0.65em;
    padding: 4px 6px;
    min-height: 20px;
    letter-spacing: 0.3px;
  }
  
  .league-card-meta {
    gap: 6px;
    font-size: 0.8em;
  }
  
  .league-prize,
  .league-conditions {
    font-size: 0.7em;
    padding: 2px 5px;
  }
  
  .empty-state {
    padding: 30px 15px;
  }
  
  .empty-icon {
    font-size: 2.5em;
  }
  
  .empty-state h3 {
    font-size: 1.1em;
  }
  
  .empty-state p {
    font-size: 0.9em;
  }
}

/* Botones compactos para solicitudes pendientes */
.btn-icon-compact {
  display: flex;
  align-items: center;
  justify-content: center;
  width: 32px;
  height: 32px;
  border: none;
  border-radius: 6px;
  cursor: pointer;
  transition: all 0.2s ease;
  background: var(--surface);
  color: var(--text-secondary);
}

.btn-icon-compact:hover {
  transform: translateY(-1px);
  box-shadow: 0 2px 8px rgba(0, 0, 0, 0.1);
}

.btn-icon-compact.btn-success {
  background: #10b981;
  color: white;
}

.btn-icon-compact.btn-success:hover {
  background: #059669;
}

.btn-icon-compact.btn-danger {
  background: #ef4444;
  color: white;
}

.btn-icon-compact.btn-danger:hover {
  background: #dc2626;
}

.btn-icon-compact svg {
  width: 16px;
  height: 16px;
  flex-shrink: 0;
}

/* Botones de perfil con ancho uniforme */
.shield-customizer .btn,
.team-info .btn {
  width: 100%;
  max-width: 280px;
  height: 48px;
  font-size: 1rem;
  font-weight: 600;
  border-radius: var(--border-radius);
  transition: var(--transition);
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 0.5rem;
  margin: 0 auto;
}

.shield-customizer .btn {
  margin-bottom: 0.5rem;
}

.team-info .btn {
  margin-top: 0.5rem;
}

@media (max-width: 768px) {
  .shield-customizer .btn,
  .team-info .btn {
    width: 100%;
    max-width: 100%;
    height: 44px;
    font-size: 0.95rem;
    margin: 0;
  }
  
  .shield-customizer .btn {
    margin-bottom: 0.25rem;
  }
  
  .team-info .btn {
    margin-top: 0.25rem;
  }
}

/* Selector de idioma */
.language-selector {
  margin-top: 2rem;
  padding-top: 1.5rem;
  border-top: 1px solid var(--border);
}

.language-selector h4 {
  color: var(--text-secondary);
  font-size: 0.9rem;
  font-weight: 600;
  margin-bottom: 0.75rem;
  text-transform: uppercase;
  letter-spacing: 0.5px;
}

.language-options {
  display: flex;
  gap: 0.5rem;
}

.language-btn {
  padding: 0.5rem 1rem;
  border: 1px solid var(--border);
  border-radius: var(--border-radius);
  background: var(--surface);
  color: var(--text-secondary);
  font-size: 0.85rem;
  cursor: pointer;
  transition: var(--transition);
  flex: 1;
}

.language-btn:hover {
  border-color: var(--primary-color);
  color: var(--primary-color);
}

.language-btn.active {
  background: var(--primary-color);
  color: white;
  border-color: var(--primary-color);
}

/* Enlaces legales */
.legal-links {
  margin-top: 2rem;
  padding-top: 1.5rem;
  border-top: 1px solid var(--border);
}

.legal-links h4 {
  color: var(--text-secondary);
  font-size: 0.9rem;
  font-weight: 600;
  margin-bottom: 0.75rem;
  text-transform: uppercase;
  letter-spacing: 0.5px;
}

.legal-links-list {
  display: flex;
  flex-direction: column;
  gap: 0.5rem;
}

.legal-links-list a {
  color: var(--text-secondary);
  text-decoration: none;
  font-size: 0.85rem;
  padding: 0.5rem 0;
  transition: var(--transition);
  display: flex;
  align-items: center;
  gap: 0.5rem;
}

.legal-links-list a:hover {
  color: var(--primary-color);
  text-decoration: underline;
}

.legal-links-list a::before {
  content: "📄";
  font-size: 0.8rem;
}

@media (max-width: 768px) {
  .legal-links {
    margin-top: 1.5rem;
    padding-top: 1rem;
  }
  
  .legal-links-list {
    gap: 0.25rem;
  }
  
  .legal-links-list a {
    font-size: 0.8rem;
    padding: 0.4rem 0;
  }
}

/* Interactive Ranking Items */
.ranking-item.interactive {
  cursor: pointer;
  transition: all 0.2s ease;
  position: relative;
}

.ranking-item.interactive:hover {
  background: var(--surface-hover);
  transform: translateY(-1px);
  box-shadow: 0 4px 12px rgba(0, 0, 0, 0.1);
}

.ranking-item.interactive .interaction-hint {
  position: absolute;
  top: 0.5rem;
  font-size: 0.75rem;
  opacity: 0.6;
  transition: opacity 0.2s ease;
}

.ranking-item.interactive:hover .interaction-hint {
  opacity: 1;
}

/* Reaction Modal Styles */
.reaction-target-info {
  text-align: center;
  margin-bottom: 1.5rem;
  padding: 1rem;
  background: var(--surface);
  border-radius: 8px;
}

.target-team-name {
  font-size: 1.25rem;
  font-weight: 600;
  color: var(--text-primary);
  margin-bottom: 0.25rem;
}

.target-position {
  font-size: 0.875rem;
  color: var(--text-secondary);
}

.reaction-options {
  display: flex;
  flex-direction: column;
  gap: 1.5rem;
}

.reaction-type-buttons {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 0.5rem;
}

.reaction-btn {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 0.3rem;
  padding: 0.5rem 0.75rem;
  background: var(--surface);
  border: 1px solid var(--border-dark);
  border-radius: 6px;
  font-size: 0.75rem;
  font-weight: 500;
  color: var(--text-primary);
  cursor: pointer;
  transition: all 0.2s ease;
}

.reaction-btn:hover {
  background: var(--primary-color);
  color: white;
  border-color: var(--primary-color);
  transform: translateY(-1px);
}

.message-section {
  display: flex;
  flex-direction: column;
  gap: 0.75rem;
  margin-top: 1rem;
}

.message-section h4 {
  font-size: 1rem;
  font-weight: 600;
  color: var(--text-primary);
  margin: 0;
}

#reaction-message {
  width: 100%;
  min-height: 80px;
  padding: 0.75rem;
  border: 1px solid var(--border-dark);
  border-radius: 8px;
  font-size: 0.875rem;
  font-family: inherit;
  resize: vertical;
  background: var(--surface);
  color: var(--text-primary);
}

#reaction-message:focus {
  outline: none;
  border-color: var(--primary-color);
  box-shadow: 0 0 0 2px rgba(220, 38, 38, 0.1);
}

.message-btn {
  align-self: flex-end;
  padding: 0.6rem 1.2rem;
  background: var(--primary-color);
  color: white;
  border: none;
  border-radius: 8px;
  font-size: 0.875rem;
  font-weight: 500;
  cursor: pointer;
  transition: all 0.2s ease;
}

.message-btn:hover {
  background: var(--primary-dark);
  transform: translateY(-1px);
}

@media (max-width: 768px) {
  .reaction-type-buttons {
    grid-template-columns: repeat(2, 1fr);
  }
  
  .reaction-btn {
    padding: 0.6rem 0.8rem;
    font-size: 0.8rem;
  }
}

/* Contenedor de reacciones */
.reactions-container {
  display: flex;
  flex-direction: row;
  gap: 0.25rem;
  align-items: center;
  justify-content: flex-start;
  max-width: 100%;
}

.reactions-container.has-reactions {
  animation: simpleEntrance 0.3s ease-out;
}

@keyframes simpleEntrance {
  0% {
    opacity: 0;
  }
  100% {
    opacity: 1;
  }
}

.reactions-display {
  display: flex;
  gap: 0.25rem;
  flex-wrap: nowrap;
  justify-content: flex-start;
  margin-right: 0.25rem;
  max-width: 100%;
  overflow: visible;
}

.reaction-badge {
  display: flex;
  align-items: center;
  gap: 0.15rem;
  background: rgba(0, 0, 0, 0.7);
  border-radius: 10px;
  padding: 0.15rem 0.3rem;
  font-size: 0.55rem;
  font-weight: 500;
  color: white;
  animation: simpleBadgeEntrance 0.2s ease-out;
}

.reaction-badge.prominent {
  background: rgba(0, 0, 0, 0.6);
  font-weight: 600;
  padding: 0.25rem 0.45rem;
  font-size: 0.65rem;
}

@keyframes simpleBadgeEntrance {
  0% {
    opacity: 0;
  }
  100% {
    opacity: 1;
  }
}

.reaction-total-badge {
  display: none;
}

.reaction-emoji {
  font-size: 0.65rem;
}

.reaction-count {
  min-width: 0.7rem;
  font-size: 0.5rem;
  font-weight: 600;
  color: white;
  text-align: center;
  background: rgba(255, 255, 255, 0.2);
  border-radius: 4px;
  padding: 0.03rem 0.15rem;
}

.more-reactions {
  background: rgba(0, 0, 0, 0.6) !important;
  font-size: 0.5rem !important;
  padding: 0.15rem 0.3rem !important;
}

.more-reactions .reaction-emoji {
  font-size: 0.6rem;
  font-weight: 700;
}

.reaction-buttons {
  display: flex;
  gap: 0.15rem;
  opacity: 0;
  transition: opacity 0.2s ease;
  flex-wrap: wrap;
  justify-content: flex-end;
  opacity: 1;

}

.ranking-item.interactive:hover .reaction-buttons,
.reaction-buttons.visible {
  opacity: 1;
}

/* En móvil, siempre mostrar los botones */
@media (max-width: 768px) {
  .reaction-buttons {
    opacity: 1 !important;
  }
  
  .reaction-dropdown-btn,
  .reaction-message-btn {
    width: 1.8rem;
    height: 1.8rem;
    font-size: 0.9rem;
  }
}

.reaction-btn-mini {
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: 50%;
  width: 1.8rem;
  height: 1.8rem;
  display: flex;
  align-items: center;
  justify-content: center;
  cursor: pointer;
  transition: all 0.2s ease;
  font-size: 0.8rem;
  flex-shrink: 0;
}

.reaction-btn-mini:hover {
  transform: scale(1.1);
  box-shadow: 0 2px 8px rgba(0, 0, 0, 0.15);
}

.reaction-btn-mini[data-type="like"]:hover {
  background: #3b82f6;
  color: white;
  border-color: #3b82f6;
}

.reaction-btn-mini[data-type="love"]:hover {
  background: #ef4444;
  color: white;
  border-color: #ef4444;
}

.reaction-btn-mini[data-type="fire"]:hover {
  background: #f59e0b;
  color: white;
  border-color: #f59e0b;
}

/* Nuevo sistema de dropdown de reacciones */
.reaction-dropdown-btn {
  background: rgba(255, 255, 255, 0.95);
  border: 1px solid rgba(0, 0, 0, 0.1);
  border-radius: 50%;
  width: 2rem;
  height: 2rem;
  display: flex;
  align-items: center;
  justify-content: center;
  cursor: pointer;
  transition: all 0.2s ease;
  font-size: 1rem;
  position: relative;
  box-shadow: 0 2px 6px rgba(0, 0, 0, 0.1);
}

.reaction-dropdown-btn:hover {
  background: #0095f6;
  border-color: #0095f6;
  transform: scale(1.05);
  box-shadow: 0 3px 10px rgba(0, 149, 246, 0.3);
  color: white;
}

.reaction-message-btn {
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: 50%;
  width: 2rem;
  height: 2rem;
  display: flex;
  align-items: center;
  justify-content: center;
  cursor: pointer;
  transition: all 0.2s ease;
  font-size: 1rem;
  position: relative;
  box-shadow: 0 2px 6px rgba(0, 0, 0, 0.1);
}

.reaction-message-btn:hover {
  background: #0095f6;
  border-color: #10b981;
  transform: scale(1.05);
  box-shadow: 0 3px 10px rgba(16, 185, 129, 0.3);
  color: white;
}

.reaction-dropdown {
  position: fixed;
  background: rgba(255, 255, 255, 0.98);
  border: 1px solid rgba(0, 0, 0, 0.1);
  border-radius: 8px;
  padding: 0.5rem;
  box-shadow: 0 4px 12px rgba(0, 0, 0, 0.15);
  display: none;
  flex-direction: column;
  gap: 0.25rem;
  min-width: 120px;
  z-index: 99999;
  max-height: 300px;
  overflow-y: auto;
  /* Mejorar visibilidad */
  backdrop-filter: blur(10px);
  -webkit-backdrop-filter: blur(10px);
}

.reaction-dropdown.show {
  display: flex;
  animation: instagramDropdownEntrance 0.3s ease-out;
}

@keyframes instagramDropdownEntrance {
  0% {
    opacity: 0;
    transform: translateY(5px);
  }
  100% {
    opacity: 1;
    transform: translateY(0);
  }
}

.reaction-option {
  display: flex;
  align-items: center;
  gap: 0.5rem;
  padding: 0.4rem 0.6rem;
  border-radius: 6px;
  cursor: pointer;
  transition: all 0.2s ease;
  font-size: 0.85rem;
  background: transparent;
  border: none;
  width: 100%;
  text-align: left;
  min-height: 2.5rem;
  /* Mejorar accesibilidad y usabilidad */
  user-select: none;
  -webkit-tap-highlight-color: transparent;
}

.reaction-option:hover {
  background: rgba(0, 149, 246, 0.1);
  transform: translateX(2px);
}

.reaction-option:active {
  background: rgba(0, 149, 246, 0.2);
  transform: translateX(1px) scale(0.98);
}

.reaction-option:focus {
  outline: 2px solid rgba(0, 149, 246, 0.5);
  outline-offset: 2px;
}

.reaction-option .reaction-emoji {
  font-size: 1.2rem;
  min-width: 1.5rem;
  text-align: center;
  filter: drop-shadow(0 1px 2px rgba(0, 0, 0, 0.1));
}

.reaction-option .reaction-label {
  color: rgba(0, 0, 0, 0.7);
  font-weight: 500;
  font-size: 0.8rem;
}

/* Responsive para el dropdown */
@media (max-width: 768px) {
  .reaction-dropdown {
    min-width: 100px;
    padding: 0.4rem;
    max-height: 250px;
  }
  
  .reaction-option {
    padding: 0.4rem;
    font-size: 0.8rem;
    min-height: 2.2rem;
  }
  
  .reaction-option .reaction-emoji {
    font-size: 1rem;
  }
}

/* Animaciones */
@keyframes fadeInScale {
  from {
    opacity: 0;
    transform: scale(0.8);
  }
  to {
    opacity: 1;
    transform: scale(1);
  }
}

/* Animación de entrada para equipos con reacciones */
@keyframes entranceAnimation {
  0% {
    opacity: 0;
    transform: translateY(20px) scale(0.9);
  }
  50% {
    opacity: 0.7;
    transform: translateY(-5px) scale(1.05);
  }
  100% {
    opacity: 1;
    transform: translateY(0) scale(1);
  }
}

.ranking-item.with-reactions {
  animation: entranceAnimation 0.8s ease-out;
}

.reaction-animation {
  animation: reactionPop 0.6s ease;
}

@keyframes reactionPop {
  0% {
    opacity: 0;
    transform: translate(-50%, -50%) scale(0.5);
  }
  50% {
    opacity: 1;
    transform: translate(-50%, -50%) scale(1.2);
  }
  100% {
    opacity: 0;
    transform: translate(-50%, -50%) scale(1.5);
  }
}

.reaction-animation.adding {
  animation: reactionPop 0.6s ease;
}

.reaction-animation.removing {
  animation: reactionPopReverse 0.6s ease;
}

@keyframes reactionPopReverse {
  0% {
    opacity: 0;
    transform: translate(-50%, -50%) scale(1.5);
  }
  50% {
    opacity: 1;
    transform: translate(-50%, -50%) scale(1.2);
  }
  100% {
    opacity: 0;
    transform: translate(-50%, -50%) scale(0.5);
  }
}

/* Estilos específicos para notificaciones de mensajes */
.message-notification .notification-content {
  flex: 1;
}

.message-notification .notification-title {
  font-weight: 600;
  color: var(--text-primary);
  margin-bottom: 0.25rem;
}

.notification-sender-info {
  margin-bottom: 0.5rem;
}

.sender-team {
  color: var(--text-secondary);
  padding: 0.25rem 0.5rem;
  border-radius: 4px;
  font-size: 0.75rem;
  font-weight: 500;
}

.message-content {
  border-left: 3px solid var(--primary);
  padding: 0.5rem 0.75rem;
  border-radius: 6px;
  margin: 0.5rem 0;
  font-style: italic;
  color: var(--text-primary);
  line-height: 1.5;
}

/* Estilos para el botón Responder en notificaciones */
.notification-item.message-notification .notification-actions .btn-primary {
  background: var(--primary-color);
  color: white;
  border: none;
  padding: 0.4rem 0.8rem;
  border-radius: 0.5rem;
  font-size: 0.8rem;
  font-weight: 500;
  transition: all 0.2s ease;
  margin-left: 0.5rem;
}

.notification-item.message-notification .notification-actions .btn-primary:hover {
  background: var(--primary-dark);
  transform: translateY(-1px);
  box-shadow: 0 2px 4px rgba(0, 0, 0, 0.1);
}

.notification-item.message-notification .notification-actions .btn-primary:active {
  transform: translateY(0);
  box-shadow: 0 1px 2px rgba(0, 0, 0, 0.1);
}

/* Responsive para el botón Responder */
@media (max-width: 768px) {
  .notification-item.message-notification .notification-actions {
    flex-direction: column;
    gap: 0.5rem;
    align-items: stretch;
  }
  
  .notification-item.message-notification .notification-actions .btn-primary {
    margin-left: 0;
    margin-top: 0.5rem;
  }
}

/* Estilos para el textarea de respuesta en notificaciones */
#reply-message {
  width: 100%;
  min-height: 120px;
  padding: 1rem;
  border: 2px solid var(--border);
  border-radius: 0.75rem;
  font-family: inherit;
  font-size: 0.95rem;
  line-height: 1.5;
  color: var(--text-primary);
  background: var(--surface);
  resize: vertical;
  transition: all 0.2s ease;
  box-shadow: 0 1px 3px rgba(0, 0, 0, 0.1);
}

/* Estilos para mensaje de restricción de edición */
.edit-restriction-message {
  background: linear-gradient(135deg, #fef3c7, #fde68a);
  border: 2px solid #f59e0b;
  border-radius: 0.75rem;
  padding: 1rem;
  margin-bottom: 1rem;
  box-shadow: 0 2px 4px rgba(245, 158, 11, 0.2);
}

.restriction-content {
  display: flex;
  align-items: center;
  gap: 0.75rem;
}

.restriction-icon {
  font-size: 1.2rem;
  color: #d97706;
}

.restriction-text {
  color: #92400e;
  font-weight: 600;
  font-size: 0.95rem;
  line-height: 1.4;
}

#reply-message:focus {
  outline: none;
  border-color: var(--primary-color);
  box-shadow: 0 0 0 3px rgba(220, 38, 38, 0.1);
  background: white;
}

#reply-message::placeholder {
  color: var(--text-secondary);
  font-style: italic;
}

/* Estilos para el modal de respuesta */
.notificationsManager .modal-content {
  padding: 1.5rem;
}

.notificationsManager .message-section h4 {
  color: var(--text-primary);
  font-size: 1.1rem;
  font-weight: 600;
  margin-bottom: 1rem;
  text-align: center;
}

.notificationsManager .message-btn {
  width: 100%;
  margin-top: 1rem;
  padding: 0.75rem 1.5rem;
  background: var(--primary-color);
  color: white;
  border: none;
  border-radius: 0.75rem;
  font-size: 1rem;
  font-weight: 600;
  cursor: pointer;
  transition: all 0.2s ease;
  box-shadow: 0 2px 4px rgba(0, 0, 0, 0.1);
}

.notificationsManager .message-btn:hover {
  background: var(--primary-dark);
  transform: translateY(-1px);
  box-shadow: 0 4px 8px rgba(0, 0, 0, 0.15);
}

.notificationsManager .message-btn:active {
  transform: translateY(0);
  box-shadow: 0 2px 4px rgba(0, 0, 0, 0.1);
}

/* Responsive para el modal de respuesta */
@media (max-width: 768px) {
  #reply-message {
    min-height: 100px;
    font-size: 0.9rem;
    padding: 0.75rem;
  }
  
  .notificationsManager .modal-content {
    padding: 1rem;
  }
  
  .notificationsManager .message-section h4 {
    font-size: 1rem;
  }
  
  .notificationsManager .message-btn {
    padding: 0.6rem 1.2rem;
    font-size: 0.95rem;
  }
}

/* Firebase Auth Styles */
.auth-container {
  display: flex;
  justify-content: center;
  align-items: center;
  min-height: 100vh;
  background: linear-gradient(135deg, #dc2626 0%, #991b1b 100%);
  padding: 15px;
}

.auth-card {
  background: white;
  border-radius: 16px;
  padding: 15px;
  box-shadow: 0 20px 40px rgba(0, 0, 0, 0.1);
  width: 100%;
  text-align: center;
}


.auth-header h1 {
  color: #dc2626;
  font-size: 28px;
  font-weight: 700;
  margin-bottom: 8px;
  text-transform: uppercase;
}

.auth-header p {
  color: #6b7280;
  font-size: 16px;
}

.auth-methods {
  display: flex;
  flex-direction: column;
  gap: 12px;
}

.auth-btn {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 12px;
  padding: 16px 24px;
  border: 2px solid #e5e7eb;
  border-radius: 12px;
  background: white;
  color: #374151;
  font-size: 16px;
  font-weight: 500;
  cursor: pointer;
  transition: all 0.2s ease;
  width: 100%;
}

.auth-btn:hover {
  border-color: #dc2626;
  color: #dc2626;
  transform: translateY(-2px);
}

.auth-btn.phone-btn {
  border-color: #10b981;
  color: #10b981;
}

.auth-btn.phone-btn:hover {
  background: #10b981;
  color: white;
}

.auth-btn.email-btn {
  border-color: #3b82f6;
  color: #3b82f6;
}

.auth-btn.email-btn:hover {
  background: #3b82f6;
  color: white;
}

.auth-btn.google-btn {
  border-color: #ea4335;
  color: #ea4335;
}

.auth-btn.google-btn:hover {
  background: #ea4335;
  color: white;
}

.auth-phone,
.auth-email,
.auth-verification {
  text-align: left;
}

.auth-phone h3,
.auth-email h3,
.auth-verification h3 {
  color: #111827;
  font-size: 20px;
  font-weight: 600;
  margin-bottom: 16px;
  text-align: center;
}


.form-control {
  width: 100%;
  padding: 12px 16px;
  border: 2px solid #e5e7eb;
  border-radius: 8px;
  font-size: 16px;
  transition: border-color 0.2s ease;
}

.form-control:focus {
  outline: none;
  border-color: #dc2626;
}

.form-actions {
  display: flex;
  gap: 12px;
  margin-top: 24px;
}

.form-actions .btn {
  flex: 1;
  padding: 12px 24px;
  border-radius: 8px;
  font-size: 16px;
  font-weight: 500;
  cursor: pointer;
  transition: all 0.2s ease;
}

.btn-primary {
  background: #dc2626;
  color: white;
  border: none;
}

.btn-primary:hover {
  background: #b91c1c;
  transform: translateY(-1px);
}

.btn-secondary {
  background: #f3f4f6;
  color: #374151;
  border: 2px solid #e5e7eb;
}

.btn-secondary:hover {
  background: #e5e7eb;
  transform: translateY(-1px);
}

/* Loading states */
.auth-btn:disabled,
.btn:disabled {
  opacity: 0.6;
  cursor: not-allowed;
  transform: none !important;
}

/* Error states */
.form-control.error {
  border-color: #ef4444;
}

.error-message {
  color: #ef4444;
  font-size: 14px;
  margin-top: 8px;
}

/* Success states */
.success-message {
  color: #10b981;
  font-size: 14px;
  margin-top: 8px;
}

/* Responsive */
@media (max-width: 480px) {
  .auth-card {
    padding: 15px;
    margin: 0px;
  }
  
  .auth-header h1 {
    font-size: 24px;
  }
  
  .form-actions {
    flex-direction: column;
  }
}

/* Estilos para perfil personal */
.personal-profile {
  padding: 20px 0;
}

.user-info-section {
  display: flex;
  align-items: center;
  gap: 20px;
  margin-bottom: 30px;
  padding: 20px;
  background: #f8f9fa;
  border-radius: 12px;
}

.user-avatar {
  width: 80px;
  height: 80px;
}

.avatar-placeholder {
  width: 100%;
  height: 100%;
  background: linear-gradient(135deg, #dc2626, #b91c1c);
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  color: white;
  font-size: 2rem;
}

.user-details h4 {
  margin: 0 0 8px 0;
  font-size: 1.5rem;
  color: var(--text-primary);
}

.user-email {
  margin: 0 0 4px 0;
  color: var(--text-secondary);
  font-size: 1rem;
}

.user-phone {
  margin: 0;
  color: var(--text-secondary);
  font-size: 1rem;
}

.user-stats-section {
  margin-bottom: 30px;
}

.user-stats-section h4 {
  margin: 0 0 16px 0;
  color: var(--text-primary);
  font-size: 1.2rem;
}

.stats-grid {
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  gap: 16px;
}

.stat-item {
  background: #ffffff;
  border: 1px solid #e5e7eb;
  border-radius: 8px;
  padding: 16px;
  text-align: center;
}

.stat-label {
  display: block;
  font-size: 0.9rem;
  color: var(--text-secondary);
  margin-bottom: 8px;
}

.stat-value {
  display: block;
  font-size: 1.5rem;
  font-weight: 700;
  color: var(--text-primary);
}

.privacy-section {
  margin-bottom: 30px;
}

.privacy-section h4 {
  margin: 0 0 16px 0;
  color: var(--text-primary);
  font-size: 1.2rem;
}

.privacy-options {
  display: flex;
  flex-direction: column;
  gap: 12px;
}

.privacy-option {
  display: flex;
  align-items: center;
  gap: 12px;
  padding: 12px;
  background: #f8f9fa;
  border-radius: 8px;
}

.privacy-option label {
  display: flex;
  align-items: center;
  gap: 12px;
  cursor: pointer;
  width: 100%;
}

.privacy-option input[type="checkbox"] {
  width: 18px;
  height: 18px;
  accent-color: #dc2626;
}

.privacy-option span {
  color: var(--text-primary);
  font-size: 0.95rem;
}

/* Sección de feedback */
.feedback-section {
  margin: 24px 0;
  padding: 20px;
  background: linear-gradient(135deg, #f8f9fa 0%, #e9ecef 100%);
  border-radius: 12px;
  border: 1px solid #dee2e6;
  text-align: center;
}

.feedback-section h4 {
  margin: 0 0 8px 0;
  color: var(--text-primary);
  font-size: 1.1rem;
  font-weight: 600;
}

.feedback-section p {
  margin: 0 0 16px 0;
  color: var(--text-secondary);
  font-size: 0.9rem;
  line-height: 1.4;
}

.feedback-btn {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  padding: 12px 24px;
  background: linear-gradient(135deg, #dc2626 0%, #b91c1c 100%);
  color: white;
  border: none;
  border-radius: 8px;
  font-weight: 600;
  font-size: 0.95rem;
  text-decoration: none;
  transition: all 0.2s ease;
  box-shadow: 0 2px 4px rgba(220, 38, 38, 0.2);
}

.feedback-btn:hover {
  background: linear-gradient(135deg, #b91c1c 0%, #991b1b 100%);
  transform: translateY(-1px);
  box-shadow: 0 4px 8px rgba(220, 38, 38, 0.3);
  color: white;
  text-decoration: none;
}

.feedback-btn:active {
  transform: translateY(0);
  box-shadow: 0 2px 4px rgba(220, 38, 38, 0.2);
}

.feedback-btn i {
  font-size: 1rem;
}

.profile-actions {
  display: flex;
  gap: 12px;
  justify-content: center;
}

.profile-actions .btn {
  flex: 1;
  max-width: 200px;
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  padding: 12px 20px;
  border-radius: 8px;
  font-weight: 600;
  transition: all 0.2s ease;
}

.profile-actions .btn-secondary {
  background: #f3f4f6;
  color: var(--text-primary);
  border: 1px solid #e5e7eb;
}

.profile-actions .btn-secondary:hover {
  background: #e5e7eb;
  transform: translateY(-1px);
}

.profile-actions .btn-danger {
  background: #ef4444;
  color: white;
  border: 1px solid #dc2626;
}

.profile-actions .btn-danger:hover {
  background: #dc2626;
  transform: translateY(-1px);
}

/* Estilos para formulario de edición */
#edit-profile-form {
  display: flex;
  flex-direction: column;
  gap: 20px;
}

#edit-profile-form .form-group {
  margin-bottom: 0;
}

#edit-profile-form label {
  display: block;
  margin-bottom: 8px;
  font-weight: 600;
  color: var(--text-primary);
}

#edit-profile-form .form-control {
  width: 100%;
  padding: 12px 16px;
  border: 2px solid #e5e7eb;
  border-radius: 8px;
  font-size: 1rem;
  transition: all 0.2s ease;
}

#edit-profile-form .form-control:focus {
  outline: none;
  border-color: #dc2626;
  box-shadow: 0 0 0 3px rgba(220, 38, 38, 0.1);
}

#edit-profile-form .form-control[readonly] {
  background-color: #f8f9fa;
  color: #6b7280;
}

.form-help {
  font-size: 0.85rem;
  color: var(--text-secondary);
  margin-top: 4px;
}

/* Responsive */
@media (max-width: 768px) {
  .user-info-section {
    flex-direction: column;
    text-align: center;
  }
  
  .stats-grid {
    grid-template-columns: 1fr;
  }
  
  .feedback-section {
    margin: 16px 0;
    padding: 16px;
  }
  
  .feedback-section h4 {
    font-size: 1rem;
  }
  
  .feedback-section p {
    font-size: 0.85rem;
  }
  
  .feedback-btn {
    padding: 10px 20px;
    font-size: 0.9rem;
  }
  
  .profile-actions {
    flex-direction: column;
  }
  
  .profile-actions .btn {
    max-width: none;
  }
}

/* Estilos para formulario de registro */
.auth-registration {
  margin: 0 auto;
  padding: 0px;
}

.auth-registration h2 {
  color: #1f2937;
  font-size: 24px;
  font-weight: 600;
  margin-bottom: 8px;
  text-align: center;
}

.auth-registration p {
  color: #6b7280;
  font-size: 14px;
  margin-bottom: 24px;
  text-align: center;
}

.registration-form {
  display: flex;
  flex-direction: column;
  gap: 5px;
}

.registration-form .form-group {
  display: flex;
  flex-direction: column;
  gap: 6px;
}

.registration-form label {
  color: #374151;
  font-size: 14px;
  font-weight: 500;
  text-align: left;
  margin: 0;
}

.registration-form input,
.registration-form select {
  padding: 10px 12px;
  border: 1px solid #d1d5db;
  border-radius: 6px;
  font-size: 14px;
  background: white;
  transition: border-color 0.2s ease;
  width: 100%;
  box-sizing: border-box;
}

.registration-form input:focus,
.registration-form select:focus {
  outline: none;
  border-color: #3b82f6;
  box-shadow: 0 0 0 3px rgba(59, 130, 246, 0.1);
}

/* Estilos específicos para select */
.registration-form select {
  appearance: none;
  background-image: url("data:image/svg+xml,%3csvg xmlns='http://www.w3.org/2000/svg' fill='none' viewBox='0 0 20 20'%3e%3cpath stroke='%236b7280' stroke-linecap='round' stroke-linejoin='round' stroke-width='1.5' d='m6 8 4 4 4-4'/%3e%3c/svg%3e");
  background-position: right 12px center;
  background-repeat: no-repeat;
  background-size: 16px;
  padding-right: 40px;
  cursor: pointer;
  position: relative;
  transition: all 0.2s ease;
  border: 1px solid #d1d5db;
  border-radius: 8px;
  font-size: 14px;
  font-family: 'Inter', -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, sans-serif;
  background-color: white;
  color: #374151;
  font-weight: 500;
}

.registration-form select:hover {
  border-color: #9ca3af;
  background-color: #f9fafb;
  transform: translateY(-1px);
  box-shadow: 0 2px 8px rgba(0, 0, 0, 0.1);
}

.registration-form select:focus {
  border-color: #3b82f6;
  background-color: white;
  box-shadow: 0 0 0 3px rgba(59, 130, 246, 0.1);
  outline: none;
  transform: translateY(-1px);
}

.registration-form select:active {
  transform: translateY(0);
  box-shadow: 0 1px 4px rgba(0, 0, 0, 0.1);
}

/* Estilo para las opciones del select */
.registration-form select option {
  padding: 12px 16px;
  background: white;
  color: #374151;
  font-size: 14px;
  font-family: 'Inter', -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, sans-serif;
  font-weight: 500;
  border: none;
  transition: background-color 0.2s ease;
}

.registration-form select option:hover {
  background-color: #f3f4f6;
  color: #1f2937;
}

.registration-form select option:checked {
  background-color: #3b82f6;
  color: white;
  font-weight: 600;
}

.registration-form select option:selected {
  background-color: #3b82f6;
  color: white;
}

/* Estilo para el placeholder del select */
.registration-form select:invalid {
  color: #9ca3af;
}

.registration-form select:valid {
  color: #374151;
}

/* Sección de consentimientos */
.consents-section {
  margin-top: 24px;
  padding-top: 24px;
  border-top: 1px solid #e5e7eb;
  background: linear-gradient(135deg, #f8fafc 0%, #f1f5f9 100%);
  border-radius: 12px;
  padding: 20px;
  box-shadow: 0 2px 8px rgba(0, 0, 0, 0.05);
}

.consents-section h3 {
  color: #1f2937;
  font-size: 18px;
  font-weight: 700;
  margin-bottom: 20px;
  text-align: left;
  display: flex;
  align-items: center;
  gap: 8px;
}

.consents-section h3::before {
  content: "📋";
  font-size: 20px;
}

.consent-item {
  margin-bottom: 16px;
  transition: all 0.2s ease;
}

.consent-item:hover {
  transform: translateX(4px);
}

.consent-label {
  display: flex;
  align-items: flex-start;
  gap: 16px;
  cursor: pointer;
  padding: 12px 16px;
  background: white;
  border-radius: 10px;
  border: 2px solid #e5e7eb;
  transition: all 0.3s ease;
  position: relative;
  overflow: hidden;
}

.consent-label::before {
  content: "";
  position: absolute;
  top: 0;
  left: 0;
  right: 0;
  bottom: 0;
  background: linear-gradient(135deg, var(--primary-color, #dc2626) 0%, #ef4444 100%);
  opacity: 0;
  transition: opacity 0.3s ease;
  z-index: 0;
}

.consent-label:hover {
  border-color: var(--primary-color, #dc2626);
  box-shadow: 0 4px 12px rgba(220, 38, 38, 0.15);
  transform: translateY(-2px);
}

.consent-label input[type="checkbox"] {
  margin: 0;
  width: 22px;
  height: 22px;
  accent-color: var(--primary-color, #dc2626);
  flex-shrink: 0;
  margin-top: 2px;
  position: relative;
  z-index: 1;
  cursor: pointer;
  border-radius: 4px;
  transition: all 0.2s ease;
}

.consent-label input[type="checkbox"]:checked {
  transform: scale(1.1);
}

.consent-text {
  flex: 1;
  display: flex;
  flex-direction: column;
  gap: 4px;
  position: relative;
  z-index: 1;
}

.consent-text strong {
  color: #1f2937;
  font-size: 15px;
  font-weight: 600;
  line-height: 1.4;
  transition: color 0.2s ease;
}

.consent-text small {
  color: #6b7280;
  font-size: 13px;
  line-height: 1.4;
  transition: color 0.2s ease;
}

.consent-label:hover .consent-text strong {
  color: var(--primary-color, #dc2626);
}

.consent-label:hover .consent-text small {
  color: #4b5563;
}

/* Estilos específicos para checkbox-group */
.form-group.checkbox-group {
  margin-bottom: 20px;
  position: relative;
}

.form-group.checkbox-group .consent-label {
  background: linear-gradient(135deg, #ffffff 0%, #f9fafb 100%);
  border: 2px solid #e5e7eb;
  border-radius: 12px;
  padding: 16px 20px;
  margin-bottom: 0;
  transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
}

.form-group.checkbox-group .consent-label:hover {
  border-color: var(--primary-color, #dc2626);
  background: linear-gradient(135deg, #fef2f2 0%, #fecaca 100%);
  box-shadow: 0 8px 25px rgba(220, 38, 38, 0.15);
  transform: translateY(-3px);
}

.form-group.checkbox-group .consent-label:active {
  transform: translateY(-1px);
  box-shadow: 0 4px 15px rgba(220, 38, 38, 0.2);
}

.form-group.checkbox-group input[type="checkbox"] {
  width: 24px;
  height: 24px;
  border-radius: 6px;
  border: 2px solid #d1d5db;
  background: white;
  transition: all 0.3s ease;
  position: relative;
}

.form-group.checkbox-group input[type="checkbox"]:checked {
  background: var(--primary-color, #dc2626);
  border-color: var(--primary-color, #dc2626);
  transform: scale(1.1);
  box-shadow: 0 0 0 3px rgba(220, 38, 38, 0.2);
}

.form-group.checkbox-group input[type="checkbox"]:focus {
  outline: none;
  box-shadow: 0 0 0 3px rgba(220, 38, 38, 0.3);
}

.form-group.checkbox-group .consent-text strong {
  font-size: 16px;
  font-weight: 700;
  color: #111827;
  margin-bottom: 4px;
}

.form-group.checkbox-group .consent-text small {
  font-size: 14px;
  color: #6b7280;
  line-height: 1.5;
}

/* Animación de check */
.form-group.checkbox-group input[type="checkbox"]:checked::after {
  content: "✓";
  position: absolute;
  top: 50%;
  left: 50%;
  transform: translate(-50%, -50%);
  color: white;
  font-size: 14px;
  font-weight: bold;
  animation: checkPop 0.3s ease;
}

@keyframes checkPop {
  0% {
    transform: translate(-50%, -50%) scale(0);
    opacity: 0;
  }
  50% {
    transform: translate(-50%, -50%) scale(1.2);
    opacity: 1;
  }
  100% {
    transform: translate(-50%, -50%) scale(1);
    opacity: 1;
  }
}

/* Botón de envío */
.registration-form .form-actions {
  margin-top: 24px;
  text-align: center;
}

.registration-form .btn {
  padding: 12px 24px;
  font-size: 16px;
  font-weight: 500;
  border-radius: 8px;
  border: none;
  cursor: pointer;
  transition: all 0.2s ease;
  min-width: 140px;
}

.registration-form .btn-primary {
  background: #3b82f6;
  color: white;
}

.registration-form .btn-primary:hover {
  background: #2563eb;
  transform: translateY(-1px);
  box-shadow: 0 4px 12px rgba(59, 130, 246, 0.3);
}

/* Adaptación para desktop */
@media (min-width: 768px) {
  
  .auth-registration h2 {
    font-size: 28px;
    margin-bottom: 12px;
  }
  
  .auth-registration p {
    font-size: 16px;
    margin-bottom: 32px;
  }
  
  .registration-form {
    gap: 20px;
  }
  
  .registration-form .form-group {
    gap: 8px;
  }
  
  .registration-form label {
    font-size: 15px;
  }
  
  .registration-form input,
  .registration-form select {
    padding: 12px 14px;
    font-size: 15px;
  }
  
  .registration-form select {
    padding-right: 44px;
    background-size: 18px;
    background-position: right 14px center;
  }
  
  .consents-section {
    margin-top: 24px;
    padding-top: 24px;
  }
  
  .consents-section h3 {
    font-size: 18px;
    margin-bottom: 20px;
  }
  
  .consent-item {
    margin-bottom: 16px;
  }
  
  .consent-label {
    gap: 14px;
    padding: 10px 0;
  }
  
  .consent-text strong {
    font-size: 15px;
  }
  
  .consent-text small {
    font-size: 13px;
  }
  
  .registration-form .form-actions {
    margin-top: 32px;
  }
  
  .registration-form .btn {
    padding: 14px 32px;
    font-size: 16px;
    min-width: 160px;
  }
}

/* Adaptación para pantallas muy grandes */
@media (min-width: 1200px) {
  .auth-registration {
    margin: 60px auto;
    padding: 40px;
  }
  
  .auth-registration h2 {
    font-size: 32px;
  }
  
  .auth-registration p {
    font-size: 18px;
  }
  
  .registration-form {
    gap: 24px;
  }
  
  .registration-form .form-group {
    gap: 10px;
  }
  
  .registration-form label {
    font-size: 16px;
  }
  
  .registration-form input,
  .registration-form select {
    padding: 14px 16px;
    font-size: 16px;
  }
  
  .registration-form select {
    padding-right: 48px;
    background-size: 20px;
    background-position: right 16px center;
    font-family: 'Inter', -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, sans-serif;
  }
}

.registration-form select:valid {
  color: #374151;
}

.registration-form input::placeholder {
  color: #9ca3af;
}

/* Estilos para el formulario de editar perfil */
.profile-edit-form {
  max-width: 100%;
  margin: 0 auto;
}

.profile-edit-form .form-row {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 1rem;
  margin-bottom: 1rem;
}

.profile-edit-form .form-group {
  margin-bottom: 0;
}

.profile-edit-form .form-group:last-child {
  margin-bottom: 0;
}

.profile-edit-form label {
  display: block;
  margin-bottom: 0.5rem;
  font-weight: 600;
  color: var(--text-primary);
  font-size: 0.9rem;
}

.profile-edit-form .form-control {
  width: 100%;
  padding: 0.75rem 1rem;
  border: 2px solid var(--border);
  border-radius: var(--border-radius);
  font-size: 1rem;
  transition: var(--transition);
  background-color: var(--surface);
  color: var(--text-primary);
}

.profile-edit-form .form-control:focus {
  outline: none;
  border-color: var(--primary-color);
  box-shadow: 0 0 0 3px rgba(220, 38, 38, 0.1);
}

.profile-edit-form .form-control[readonly] {
  background-color: var(--surface-secondary);
  color: var(--text-secondary);
  cursor: not-allowed;
}

.profile-edit-form .form-control::placeholder {
  color: var(--text-tertiary);
}

/* Estilos mejorados para los selects */
.select-wrapper {
  position: relative;
  display: inline-block;
  width: 100%;
}

.custom-select {
  appearance: none;
  -webkit-appearance: none;
  -moz-appearance: none;
  background-image: url("data:image/svg+xml;charset=UTF-8,%3csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='%236b7280' 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 1rem center;
  background-size: 1rem;
  padding-right: 2.5rem;
  cursor: pointer;
}

.custom-select:hover {
  border-color: var(--primary-color);
  background-color: var(--surface-hover);
}

.custom-select:focus {
  border-color: var(--primary-color);
  box-shadow: 0 0 0 3px rgba(220, 38, 38, 0.1);
}

.custom-select:active {
  border-color: var(--primary-dark);
  background-color: var(--surface-secondary);
}

.custom-select option {
  padding: 0.5rem 1rem;
  background-color: var(--surface);
  color: var(--text-primary);
  font-size: 1rem;
}

.custom-select option:hover {
  background-color: var(--primary-light);
  color: var(--primary-color);
}

.custom-select option:checked {
  background-color: var(--primary-color);
  color: var(--text-light);
}

.custom-select option:selected {
  background-color: var(--primary-color);
  color: var(--text-light);
}

.custom-select:invalid {
  border-color: var(--danger);
}

.custom-select:valid {
  border-color: var(--success);
}

/* Responsive design para el formulario */
@media (max-width: 768px) {
  .profile-edit-form .form-row {
    grid-template-columns: 1fr;
    gap: 0.75rem;
  }
  
  .profile-edit-form .form-control {
    padding: 0.625rem 0.875rem;
    font-size: 0.95rem;
  }
  
  .profile-edit-form label {
    font-size: 0.85rem;
  }
}

@media (max-width: 480px) {
  .profile-edit-form .form-control {
    padding: 0.5rem 0.75rem;
    font-size: 0.9rem;
  }
  
  .profile-edit-form label {
    font-size: 0.8rem;
  }
  
  .custom-select {
    background-size: 0.875rem;
    padding-right: 2.25rem;
  }
}

/* Estilos mejorados para el modal de unirse a liga */
.join-league-info .checkbox-container {
  transition: all 0.2s ease;
}

.join-league-info .checkbox-container:hover {
  background-color: #f8f9fa !important;
}

.join-league-info .checkbox-container:active {
  transform: scale(0.98);
}

.join-league-info .checkmark {
  transition: all 0.2s ease;
}

.join-league-info .checkmark:hover {
  border-color: #0056b3 !important;
}

/* Asegurar que los botones no se corten */
.modal .modal-actions {
  bottom: 0;
  background: white;
  z-index: 10;
  margin-top: 16px;
  padding: 16px 0 0 0;
  border-top: 1px solid #e9ecef;
}

.modal .modal-actions .btn {
  min-width: 120px;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

/* Responsive para móviles */
@media (max-width: 768px) {
  .modal .modal-actions {
    flex-direction: column;
    gap: 8px;
  }
  
  .modal .modal-actions .btn {
    width: 100%;
    min-width: unset;
  }
  
  .join-league-info .checkbox-container {
    padding: 12px;
  }
}

/* Estilos para botones de acción en transacciones */
.action-buttons {
  display: flex;
  gap: 8px;
  flex-wrap: wrap;
  margin-top: 12px;
}

.action-buttons .btn {
  flex: 1;
  min-width: 120px;
  font-size: 0.9em;
  padding: 8px 12px;
}

.action-buttons .btn-primary {
  background: linear-gradient(135deg, #007bff, #0056b3);
  border: none;
  color: white;
  transition: all 0.2s ease;
}

.action-buttons .btn-primary:hover {
  background: linear-gradient(135deg, #0056b3, #004085);
  transform: translateY(-1px);
  box-shadow: 0 4px 8px rgba(0, 123, 255, 0.3);
}

.action-buttons .btn-danger {
  background: linear-gradient(135deg, #dc3545, #c82333);
  border: none;
  color: white;
  transition: all 0.2s ease;
}

.action-buttons .btn-danger:hover {
  background: linear-gradient(135deg, #c82333, #a71e2a);
  transform: translateY(-1px);
  box-shadow: 0 4px 8px rgba(220, 53, 69, 0.3);
}

/* Mejorar el diseño de las transacciones */
.pending-team-item {
  transition: all 0.2s ease;
  border: 1px solid #e0e0e0;
  border-radius: 8px;
  padding: 16px;
  margin-bottom: 12px;
  background: white;
}

.pending-team-item:hover {
  transform: translateY(-2px);
  box-shadow: 0 4px 12px rgba(0, 0, 0, 0.1);
}

/* Contenedor de información del equipo */
.team-info-container {
  display: flex;
  align-items: center;
  gap: 12px;
  margin-bottom: 12px;
}

/* Contenedor de acciones */
.team-actions-container {
  display: flex;
  justify-content: flex-start;
  width: 100%;
  margin-top: 8px;
}

/* Estilos para el estado de las transacciones */
.status-pending {
  border-left: 4px solid #ffc107;
}

.status-success {
  border-left: 4px solid #28a745;
}

.status-failed {
  border-left: 4px solid #dc3545;
}

.status-canceled {
  border-left: 4px solid #6c757d;
  opacity: 0.7;
}

/* Mejorar el diseño de la información del equipo */
.team-info-simple {
  flex: 1;
}

.team-name-simple {
  font-weight: 600;
  font-size: 1.1em;
  margin-bottom: 4px;
  color: #333;
}

.transaction-details-simple {
  display: flex;
  align-items: center;
  gap: 12px;
  font-size: 0.9em;
  color: #666;
}

.status-badge {
  padding: 4px 8px;
  border-radius: 12px;
  font-size: 0.8em;
  font-weight: 500;
}

.status-badge.status-pending {
  background-color: #fff3cd;
  color: #856404;
}

.status-badge.status-success {
  background-color: #d4edda;
  color: #155724;
}

.status-badge.status-failed {
  background-color: #f8d7da;
  color: #721c24;
}

.status-badge.status-canceled {
  background-color: #e2e3e5;
  color: #383d41;
}

/* Estilos para el header del equipo y botón "¿Cómo se juega?" */
.team-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  margin-bottom: 1rem;
  padding: 0 0.5rem;
}

.team-header h3 {
  margin: 0;
  font-size: 1.5rem;
  font-weight: 600;
  color: #333;
}

.how-to-play-btn {
  display: flex;
  align-items: center;
  gap: 0.5rem;
  padding: 0.5rem 1rem;
  background: linear-gradient(135deg, var(--primary-color) 0%, var(--primary-dark) 100%);
  color: white;
  border: none;
  border-radius: 25px;
  font-size: 0.9rem;
  font-weight: 500;
  cursor: pointer;
  transition: all 0.3s ease;
  box-shadow: 0 2px 8px rgba(102, 126, 234, 0.3);
}

.how-to-play-btn:hover {
  transform: translateY(-2px);
  box-shadow: 0 4px 12px rgba(102, 126, 234, 0.4);
  background: linear-gradient(135deg, var(--primary-dark) 0%, var(--primary-color) 100%);
}

.how-to-play-btn:active {
  transform: translateY(0);
  box-shadow: 0 2px 8px rgba(102, 126, 234, 0.3);
}

.how-to-play-btn svg {
  width: 16px;
  height: 16px;
  stroke: currentColor;
  stroke-width: 2;
  fill: none;
}

/* Estilos para el modal de instrucciones */
.how-to-play-modal {
  max-width: 500px;
  width: 90%;
}

.how-to-play-modal .modal-header {
  background: linear-gradient(135deg, var(--primary-color) 0%, var(--primary-dark) 100%);
  color: white;
  border-radius: 12px 12px 0 0;
  padding: 1.5rem;
  text-align: center;
}

.how-to-play-modal .modal-header .modal-close-btn {
  color: white;
  font-size: 1.5rem;
  font-weight: 600;
  cursor: pointer;
}

.how-to-play-modal .modal-header .modal-close-btn:hover {
  color: black;
  font-size: 1.5rem;
  font-weight: 600;
  cursor: pointer;
}

.how-to-play-modal .modal-header h3 {
  margin: 0;
  font-size: 1.5rem;
  font-weight: 600;
}

.how-to-play-modal .modal-content {
  padding: 2rem;
  background: white;
  border-radius: 0 0 12px 12px;
}

.instructions-list {
  list-style: none;
  padding: 0;
  margin: 0;
}

.instructions-list li {
  display: flex;
  align-items: flex-start;
  gap: 1rem;
  padding: 1rem 0;
  border-bottom: 1px solid #f0f0f0;
  font-size: 1rem;
  line-height: 1.5;
  color: #333;
}

.instructions-list li:last-child {
  border-bottom: none;
}

.instruction-icon {
  flex-shrink: 0;
  width: 24px;
  height: 24px;
  background: linear-gradient(135deg, var(--primary-color) 0%, var(--primary-dark) 100%);
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  color: white;
  font-size: 12px;
  font-weight: bold;
}

.instruction-text {
  flex: 1;
  font-weight: 500;
}

.instruction-highlight {
  color: var(--primary-color);
  font-weight: 600;
}

/* Responsive */
@media (max-width: 768px) {
  .team-header {
    flex-direction: row;
    gap: 0.5rem;
    align-items: center;
    flex-wrap: wrap;
  }
  
  .team-header h3 {
    font-size: 1.3rem;
    flex: 1;
    min-width: 0;
  }
  
  .how-to-play-btn {
    font-size: 0.8rem;
    padding: 0.4rem 0.8rem;
    white-space: nowrap;
    flex-shrink: 0;
  }
  
  .how-to-play-modal .modal-content {
    padding: 1.5rem;
  }
  
  .instructions-list li {
    font-size: 0.9rem;
    padding: 0.75rem 0;
  }
}

@media (max-width: 480px) {
  .team-header {
    gap: 0.3rem;
  }
  
  .team-header h3 {
    font-size: 1.2rem;
  }
  
  .how-to-play-btn {
    font-size: 0.7rem;
    padding: 0.3rem 0.6rem;
  }
  
  .how-to-play-modal .modal-header {
    padding: 1rem;
  }
  
  .how-to-play-modal .modal-header h3 {
    font-size: 1.3rem;
  }
  
  .how-to-play-modal .modal-content {
    padding: 1rem;
  }
}

/* Estilos responsivos para checkbox-group */
@media (max-width: 767px) {
  .consents-section {
    margin-top: 20px;
    padding: 16px;
    border-radius: 8px;
  }
  
  .consents-section h3 {
    font-size: 16px;
    margin-bottom: 16px;
  }
  
  .consent-item {
    margin-bottom: 12px;
  }
  
  .consent-label {
    padding: 12px 14px;
    gap: 12px;
  }
  
  .consent-label input[type="checkbox"] {
    width: 20px;
    height: 20px;
  }
  
  .consent-text strong {
    font-size: 14px;
  }
  
  .consent-text small {
    font-size: 12px;
  }
  
  /* Ajustes específicos para checkbox-group en móvil */
  .form-group.checkbox-group .consent-label {
    padding: 14px 16px;
    border-radius: 8px;
  }
  
  .form-group.checkbox-group input[type="checkbox"] {
    width: 22px;
    height: 22px;
  }
  
  .form-group.checkbox-group .consent-text strong {
    font-size: 15px;
  }
  
  .form-group.checkbox-group .consent-text small {
    font-size: 13px;
  }
  
  /* Reducir animaciones en móvil para mejor rendimiento */
  .form-group.checkbox-group .consent-label:hover {
    transform: translateY(-1px);
    box-shadow: 0 4px 15px rgba(220, 38, 38, 0.1);
  }
  
  .consent-item:hover {
    transform: translateX(2px);
  }
}

/* Estilos para pantallas muy pequeñas */
@media (max-width: 480px) {
  .consents-section {
    padding: 12px;
    margin-top: 16px;
  }
  
  .consents-section h3 {
    font-size: 15px;
    margin-bottom: 12px;
  }
  
  .consent-label {
    padding: 10px 12px;
    gap: 10px;
  }
  
  .consent-label input[type="checkbox"] {
    width: 18px;
    height: 18px;
  }
  
  .consent-text strong {
    font-size: 13px;
  }
  
  .consent-text small {
    font-size: 11px;
  }
  
  .form-group.checkbox-group .consent-label {
    padding: 12px 14px;
  }
  
  .form-group.checkbox-group input[type="checkbox"] {
    width: 20px;
    height: 20px;
  }
  
  .form-group.checkbox-group .consent-text strong {
    font-size: 14px;
  }
  
  .form-group.checkbox-group .consent-text small {
    font-size: 12px;
  }
}

/* Mejoras específicas para checkbox-group en desktop */
@media (min-width: 768px) {
  .form-group.checkbox-group .consent-label {
    padding: 20px 24px;
  }
  
  .form-group.checkbox-group input[type="checkbox"] {
    width: 26px;
    height: 26px;
  }
  
  .form-group.checkbox-group .consent-text strong {
    font-size: 17px;
  }
  
  .form-group.checkbox-group .consent-text small {
    font-size: 15px;
  }
}

.auth-container {
  display: flex;
  flex-direction: column;
  align-items: center;
}
@font-face {
  font-family: 'BaksoSapi';
  src: url('/fonts/BaksoSapi.otf') format('opentype');
  font-weight: normal;
  font-style: normal;
  font-display: swap;
}
.auth-footer {
  margin-top: 12px;
  padding: 12px 0 8px;
  display: flex;
  flex-direction: row;
  align-items: center;
  opacity: 0.9;
  align-self: center;
}
.auth-footer .footer-logo {
  width: 80px;
  height: auto;
  object-fit: contain;
  display: block;
  filter: drop-shadow(0 2px 6px rgba(0,0,0,0.12));
}
.auth-footer .footer-brand {
  font-family: 'BaksoSapi', system-ui, -apple-system, Segoe UI, Roboto, Helvetica, Arial, sans-serif;
  font-size: 24px;
  line-height: 1;
  color: black;
  letter-spacing: 0.5px;
}