/* SoccerLeague Styles */
:root {
    --primary-green: #1a6b32;
    --dark-green: #0e3b1d;
    --accent-orange: #f97316;
    --light-bg: #f8f9fa;
    --dark-bg: #1a202c;
}

body {
    font-family: 'Inter', -apple-system, BlinkMacSystemFont, sans-serif;
    transition: background-color 0.3s, color 0.3s;
}

/* Modo oscuro */
.dark-mode {
    background-color: var(--dark-bg);
    color: #e2e8f0;
}

.dark-mode .bg-white {
    background-color: #2d3748 !important;
}

.dark-mode .text-gray-800 {
    color: #e2e8f0 !important;
}

.dark-mode .text-gray-600 {
    color: #a0aec0 !important;
}

.dark-mode .text-gray-500 {
    color: #718096 !important;
}

.dark-mode .border-gray-300 {
    border-color: #4a5568 !important;
}

.dark-mode .bg-gray-100 {
    background-color: #4a5568 !important;
}

.dark-mode .bg-gray-50 {
    background-color: #2d3748 !important;
}

/* Campo de fútbol */
.soccer-field {
    background: linear-gradient(135deg, var(--primary-green), var(--dark-green));
    position: relative;
    border-radius: 12px;
    overflow: hidden;
}

.field-lines {
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: 
        linear-gradient(transparent 48%, rgba(255,255,255,0.2) 48%, rgba(255,255,255,0.2) 52%, transparent 52%),
        linear-gradient(90deg, transparent 48%, rgba(255,255,255,0.2) 48%, rgba(255,255,255,0.2) 52%, transparent 52%);
    pointer-events: none;
}

/* Jugadores en campo */
.player-slot {
    border: 2px dashed rgba(255, 255, 255, 0.4);
    transition: all 0.3s ease;
    cursor: pointer;
    min-height: 80px;
    display: flex;
    align-items: center;
    justify-content: center;
}

.player-slot:hover {
    border-color: rgba(255, 255, 255, 0.8);
    background: rgba(255, 255, 255, 0.1);
}

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

/* Navegación */
.nav-tab {
    position: relative;
    border-bottom: 3px solid transparent;
    transition: all 0.3s ease;
    white-space: nowrap;
}

.nav-tab.active {
    border-bottom-color: var(--accent-orange);
    color: var(--accent-orange);
}

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

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

@keyframes slideIn {
    from { transform: translateX(-100%); }
    to { transform: translateX(0); }
}

/* Tarjetas de jugadores */
.player-card {
    transition: all 0.3s ease;
    border-left: 4px solid transparent;
}

.player-card.GK {
    border-left-color: #3b82f6;
}

.player-card.DF {
    border-left-color: #10b981;
}

.player-card.MF {
    border-left-color: #f59e0b;
}

.player-card.FW {
    border-left-color: #ef4444;
}

.player-card:hover {
    transform: translateX(4px);
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.1);
}

/* Botones */
.btn-primary {
    background: var(--accent-orange);
    transition: all 0.3s ease;
}

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

/* Ranking badges */
.ranking-badge {
    width: 32px;
    height: 32px;
    display: flex;
    align-items: center;
    justify-content: center;
    border-radius: 50%;
    font-weight: bold;
    color: white;
}

.ranking-1 {
    background: #f59e0b;
}

.ranking-2 {
    background: #6b7280;
}

.ranking-3 {
    background: #92400e;
}

/* Notificaciones */
.notification-unread {
    border-left-color: var(--accent-orange);
    background: rgba(249, 115, 22, 0.05);
}

/* Responsive */
@media (max-width: 768px) {
    .mobile-stack {
        flex-direction: column;
    }
    
    .mobile-full {
        width: 100%;
    }
    
    .mobile-text-center {
        text-align: center;
    }
    
    .player-slot {
        min-height: 60px;
        font-size: 0.875rem;
    }
}

/* Scrollbar personalizado */
.custom-scrollbar::-webkit-scrollbar {
    width: 6px;
}

.custom-scrollbar::-webkit-scrollbar-track {
    background: #f1f1f1;
    border-radius: 3px;
}

.custom-scrollbar::-webkit-scrollbar-thumb {
    background: #c1c1c1;
    border-radius: 3px;
}

.custom-scrollbar::-webkit-scrollbar-thumb:hover {
    background: #a8a8a8;
}

.dark-mode .custom-scrollbar::-webkit-scrollbar-track {
    background: #4a5568;
}

.dark-mode .custom-scrollbar::-webkit-scrollbar-thumb {
    background: #718096;
}

/* Toggle de modo oscuro */
.theme-toggle {
    position: relative;
    display: inline-block;
    width: 60px;
    height: 34px;
}

.theme-toggle input {
    opacity: 0;
    width: 0;
    height: 0;
}

.theme-slider {
    position: absolute;
    cursor: pointer;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background-color: #ccc;
    transition: .4s;
    border-radius: 34px;
}

.theme-slider:before {
    position: absolute;
    content: "";
    height: 26px;
    width: 26px;
    left: 4px;
    bottom: 4px;
    background-color: white;
    transition: .4s;
    border-radius: 50%;
}

input:checked + .theme-slider {
    background-color: var(--accent-orange);
}

input:checked + .theme-slider:before {
    transform: translateX(26px);
}

/* Utilidades de texto */
.text-gradient {
    background: linear-gradient(135deg, var(--accent-orange), #ea580c);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
}

/* Estados de carga */
.loading {
    animation: pulse 2s cubic-bezier(0.4, 0, 0.6, 1) infinite;
}

@keyframes pulse {
    0%, 100% {
        opacity: 1;
    }
    50% {
        opacity: .5;
    }
}

/* Badges */
.badge {
    display: inline-block;
    padding: 0.25rem 0.5rem;
    border-radius: 0.375rem;
    font-size: 0.75rem;
    font-weight: 600;
    text-transform: uppercase;
}

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

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

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

.badge-info {
    background: #dbeafe;
    color: #1e40af;
}

.dark-mode .badge-success {
    background: #166534;
    color: #dcfce7;
}

.dark-mode .badge-warning {
    background: #92400e;
    color: #fef3c7;
}

.dark-mode .badge-error {
    background: #991b1b;
    color: #fee2e2;
}

.dark-mode .badge-info {
    background: #1e40af;
    color: #dbeafe;
}