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

:root {
    /* Sports-Focused Color Palette */
    --primary-gradient: linear-gradient(135deg, #10b981 0%, #059669 100%);
    --primary-color: #10b981;
    --primary-dark: #059669;
    --secondary-color: #3b82f6;
    --accent-color: #f59e0b;
    
    /* Neutral Colors */
    --white: #ffffff;
    --gray-50: #f9fafb;
    --gray-100: #f3f4f6;
    --gray-200: #e5e7eb;
    --gray-300: #d1d5db;
    --gray-400: #9ca3af;
    --gray-500: #6b7280;
    --gray-600: #4b5563;
    --gray-700: #374151;
    --gray-800: #1f2937;
    --gray-900: #111827;
    
    /* Status Colors */
    --success-color: #10b981;
    --warning-color: #f59e0b;
    --error-color: #ef4444;
    --info-color: #3b82f6;
    
    /* Shadows */
    --shadow-sm: 0 1px 2px 0 rgba(0, 0, 0, 0.05);
    --shadow-md: 0 4px 6px -1px rgba(0, 0, 0, 0.1), 0 2px 4px -1px 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-xl: 0 20px 25px -5px rgba(0, 0, 0, 0.1), 0 10px 10px -5px rgba(0, 0, 0, 0.04);
    
    /* Border Radius */
    --radius-sm: 0.375rem;
    --radius-md: 0.5rem;
    --radius-lg: 0.75rem;
    --radius-xl: 1rem;
    --radius-2xl: 1.5rem;
    
    /* Spacing */
    --space-xs: 0.5rem;
    --space-sm: 0.75rem;
    --space-md: 1rem;
    --space-lg: 1.5rem;
    --space-xl: 2rem;
    --space-2xl: 3rem;
    
    /* Typography */
    --font-family: 'Inter', -apple-system, BlinkMacSystemFont, 'Segoe UI', 'Roboto', sans-serif;
    --font-size-xs: 0.75rem;
    --font-size-sm: 0.875rem;
    --font-size-base: 1rem;
    --font-size-lg: 1.125rem;
    --font-size-xl: 1.25rem;
    --font-size-2xl: 1.5rem;
    --font-size-3xl: 1.875rem;
    --font-size-4xl: 2.25rem;
}

body {
    font-family: var(--font-family);
    color: var(--gray-800);
    line-height: 1.6;
    min-height: 100vh;
    font-size: var(--font-size-base);
    -webkit-font-smoothing: antialiased;
    -moz-osx-font-smoothing: grayscale;
    position: relative;
    overflow-x: hidden;
}

/* Dynamic Sports Background */
.sports-background {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    z-index: -2;
    background: linear-gradient(135deg, #0f766e 0%, #065f46 100%);
}

.sports-background::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: 
        radial-gradient(circle at 20% 80%, rgba(16, 185, 129, 0.3) 0%, transparent 50%),
        radial-gradient(circle at 80% 20%, rgba(59, 130, 246, 0.3) 0%, transparent 50%),
        radial-gradient(circle at 40% 40%, rgba(245, 158, 11, 0.2) 0%, transparent 50%);
    animation: backgroundShift 20s ease-in-out infinite;
}

@keyframes backgroundShift {
    0%, 100% {
        transform: scale(1) rotate(0deg);
        opacity: 1;
    }
    25% {
        transform: scale(1.1) rotate(1deg);
        opacity: 0.8;
    }
    50% {
        transform: scale(1.05) rotate(-1deg);
        opacity: 0.9;
    }
    75% {
        transform: scale(1.15) rotate(0.5deg);
        opacity: 0.7;
    }
}

.sports-image-slider {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    z-index: -1;
    opacity: 0.15;
}

.sports-image {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background-size: cover;
    background-position: center;
    background-repeat: no-repeat;
    opacity: 0;
    transition: opacity 2s ease-in-out;
    filter: blur(1px) brightness(0.7) contrast(1.2);
}

.sports-image.active {
    opacity: 1;
}

.sports-image:nth-child(1) {
    background-image: url('data:image/svg+xml,<svg xmlns="http://www.w3.org/2000/svg" viewBox="0 0 1200 800"><defs><linearGradient id="field" x1="0%" y1="0%" x2="100%" y2="100%"><stop offset="0%" style="stop-color:%2334d399;stop-opacity:1" /><stop offset="100%" style="stop-color:%2310b981;stop-opacity:1" /></linearGradient></defs><rect width="1200" height="800" fill="url(%23field)"/><rect x="50" y="100" width="1100" height="600" fill="none" stroke="white" stroke-width="4"/><circle cx="600" cy="400" r="80" fill="none" stroke="white" stroke-width="4"/><rect x="50" y="250" width="150" height="300" fill="none" stroke="white" stroke-width="4"/><rect x="1000" y="250" width="150" height="300" fill="none" stroke="white" stroke-width="4"/><rect x="50" y="320" width="60" height="160" fill="none" stroke="white" stroke-width="4"/><rect x="1090" y="320" width="60" height="160" fill="none" stroke="white" stroke-width="4"/></svg>');
}

.sports-image:nth-child(2) {
    background-image: url('data:image/svg+xml,<svg xmlns="http://www.w3.org/2000/svg" viewBox="0 0 1200 800"><defs><linearGradient id="stadium" x1="0%" y1="0%" x2="100%" y2="100%"><stop offset="0%" style="stop-color:%2306b6d4;stop-opacity:1" /><stop offset="100%" style="stop-color:%230891b2;stop-opacity:1" /></linearGradient></defs><rect width="1200" height="800" fill="url(%23stadium)"/><ellipse cx="600" cy="400" rx="500" ry="300" fill="none" stroke="white" stroke-width="6" opacity="0.3"/><ellipse cx="600" cy="400" rx="400" ry="240" fill="none" stroke="white" stroke-width="4" opacity="0.5"/><ellipse cx="600" cy="400" rx="300" ry="180" fill="none" stroke="white" stroke-width="3" opacity="0.7"/><circle cx="600" cy="400" r="20" fill="white" opacity="0.8"/></svg>');
}

.sports-image:nth-child(3) {
    background-image: url('data:image/svg+xml,<svg xmlns="http://www.w3.org/2000/svg" viewBox="0 0 1200 800"><defs><linearGradient id="training" x1="0%" y1="0%" x2="100%" y2="100%"><stop offset="0%" style="stop-color:%23f59e0b;stop-opacity:1" /><stop offset="100%" style="stop-color:%23d97706;stop-opacity:1" /></linearGradient></defs><rect width="1200" height="800" fill="url(%23training)"/><circle cx="200" cy="200" r="15" fill="white" opacity="0.6"/><circle cx="400" cy="300" r="12" fill="white" opacity="0.7"/><circle cx="600" cy="150" r="18" fill="white" opacity="0.5"/><circle cx="800" cy="400" r="14" fill="white" opacity="0.8"/><circle cx="1000" cy="250" r="16" fill="white" opacity="0.6"/><path d="M 100 600 Q 300 500 500 550 T 900 500 L 1100 600" stroke="white" stroke-width="3" fill="none" opacity="0.4"/></svg>');
}

.sports-image:nth-child(4) {
    background-image: url('data:image/svg+xml,<svg xmlns="http://www.w3.org/2000/svg" viewBox="0 0 1200 800"><defs><linearGradient id="goal" x1="0%" y1="0%" x2="100%" y2="100%"><stop offset="0%" style="stop-color:%2310b981;stop-opacity:1" /><stop offset="100%" style="stop-color:%23059669;stop-opacity:1" /></linearGradient></defs><rect width="1200" height="800" fill="url(%23goal)"/><rect x="400" y="200" width="400" height="300" fill="none" stroke="white" stroke-width="6" opacity="0.7"/><path d="M 400 200 L 500 150 L 900 150 L 800 200" stroke="white" stroke-width="4" fill="none" opacity="0.5"/><path d="M 800 200 L 900 150 L 900 450 L 800 500" stroke="white" stroke-width="4" fill="none" opacity="0.5"/><circle cx="600" cy="350" r="8" fill="white"/></svg>');
}

/* Modern Button Styles */
.btn {
    display: inline-flex;
    align-items: center;
    gap: var(--space-xs);
    padding: var(--space-sm) var(--space-lg);
    border: none;
    border-radius: var(--radius-lg);
    cursor: pointer;
    font-size: var(--font-size-sm);
    font-weight: 600;
    font-family: var(--font-family);
    transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
    text-decoration: none;
    text-align: center;
    position: relative;
    overflow: hidden;
    white-space: nowrap;
    user-select: none;
}

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

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

.btn-primary {
    background: #10b981;
    color: white;
    box-shadow: var(--shadow-md);
}

.btn-primary:hover {
    background: #059669;
    transform: translateY(-2px);
    box-shadow: var(--shadow-xl);
}

.btn-hero {
    padding: var(--space-md) var(--space-xl);
    font-size: var(--font-size-base);
    border-radius: var(--radius-xl);
}

.btn-upload {
    padding: var(--space-lg) var(--space-2xl);
    font-size: var(--font-size-lg);
    border-radius: var(--radius-xl);
    background: linear-gradient(135deg, var(--success-color) 0%, #059669 100%);
}

.btn-secondary {
    background: transparent;
    color: #6b7280;
    border: 1px solid #d1d5db;
}

.btn-secondary:hover {
    background: #f3f4f6;
    color: #374151;
}

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

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

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

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

/* Form Styles */
.form-group {
    margin-bottom: 1.5rem;
}

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

.form-group input,
.form-group select,
.form-group textarea {
    width: 100%;
    padding: 0.75rem;
    border: 2px solid #e1e5e9;
    border-radius: 6px;
    font-size: 14px;
    transition: border-color 0.2s ease;
    background: white;
}

.form-group input:focus,
.form-group select:focus,
.form-group textarea:focus {
    outline: none;
    border-color: #2a5298;
    box-shadow: 0 0 0 3px rgba(42, 82, 152, 0.1);
}

.form-row {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(200px, 1fr));
    gap: 1rem;
}

/* Card Styles */
.card {
    background: white;
    border-radius: 12px;
    box-shadow: 0 2px 8px rgba(0,0,0,0.1);
    padding: 1.5rem;
    margin-bottom: 1rem;
    transition: transform 0.2s ease, box-shadow 0.2s ease;
}

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

/* Grid Layouts */
.grid {
    display: grid;
    gap: 1.5rem;
}

.grid-2 {
    grid-template-columns: repeat(auto-fit, minmax(300px, 1fr));
}

.grid-3 {
    grid-template-columns: repeat(auto-fit, minmax(250px, 1fr));
}

.grid-4 {
    grid-template-columns: repeat(auto-fit, minmax(200px, 1fr));
}

/* Modal Styles */
.modal-overlay {
    position: fixed;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: rgba(0, 0, 0, 0.7);
    display: flex;
    justify-content: center;
    align-items: center;
    z-index: 10000;
    backdrop-filter: blur(8px);
    animation: fadeIn 0.2s ease-out;
}

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

.modal {
    background: linear-gradient(135deg, rgba(255, 255, 255, 0.98) 0%, rgba(249, 250, 251, 0.98) 100%);
    backdrop-filter: blur(20px);
    border-radius: 16px;
    padding: 2rem;
    max-width: 500px;
    width: 90%;
    max-height: 90vh;
    overflow-y: auto;
    box-shadow: 0 20px 60px rgba(0,0,0,0.3), 0 0 0 1px rgba(16, 185, 129, 0.1);
    z-index: 10001;
    border: 1px solid rgba(255, 255, 255, 0.8);
    animation: slideUp 0.3s ease-out;
}

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

.modal h3 {
    margin-bottom: 1.5rem;
    color: #1f2937;
    font-size: 1.5rem;
    font-weight: 600;
    padding-bottom: 1rem;
    border-bottom: 2px solid #10b981;
    display: flex;
    align-items: center;
    gap: 0.5rem;
}

.modal h3::before {
    content: '';
    width: 4px;
    height: 24px;
    background: linear-gradient(135deg, #10b981 0%, #059669 100%);
    border-radius: 2px;
}

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

.form-group label {
    display: block;
    margin-bottom: 0.5rem;
    font-weight: 600;
    color: #374151;
    font-size: 0.875rem;
    text-transform: uppercase;
    letter-spacing: 0.5px;
}

.form-group input,
.form-group textarea,
.form-group select {
    width: 100%;
    padding: 0.875rem 1rem;
    border: 2px solid #e5e7eb;
    border-radius: 8px;
    font-size: 1rem;
    background: white;
    transition: all 0.2s ease;
    color: #1f2937;
}

.form-group select {
    cursor: pointer;
    appearance: none;
    background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='12' height='12' viewBox='0 0 12 12'%3E%3Cpath fill='%2310b981' d='M6 9L1 4h10z'/%3E%3C/svg%3E");
    background-repeat: no-repeat;
    background-position: right 1rem center;
    padding-right: 2.5rem;
}

.form-group input:focus,
.form-group textarea:focus,
.form-group select:focus {
    outline: none;
    border-color: #10b981;
    box-shadow: 0 0 0 3px rgba(16, 185, 129, 0.1);
    background-color: #f9fafb;
}

.form-group select:focus {
    background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='12' height='12' viewBox='0 0 12 12'%3E%3Cpath fill='%23059669' d='M6 9L1 4h10z'/%3E%3C/svg%3E");
}

.form-group input::placeholder,
.form-group textarea::placeholder {
    color: #9ca3af;
}

.form-actions {
    display: flex;
    gap: 1rem;
    justify-content: flex-end;
    margin-top: 2rem;
    padding-top: 1.5rem;
    border-top: 1px solid #e5e7eb;
}

.btn {
    padding: 0.875rem 1.75rem;
    border: none;
    border-radius: 8px;
    font-size: 1rem;
    font-weight: 600;
    cursor: pointer;
    transition: all 0.2s ease;
    display: inline-flex;
    align-items: center;
    gap: 0.5rem;
}

.btn-primary {
    background: linear-gradient(135deg, #10b981 0%, #059669 100%);
    color: white;
    box-shadow: 0 4px 12px rgba(16, 185, 129, 0.3);
}

.btn-primary:hover {
    transform: translateY(-2px);
    box-shadow: 0 6px 20px rgba(16, 185, 129, 0.4);
    background: linear-gradient(135deg, #059669 0%, #047857 100%);
}

.btn-secondary {
    background: white;
    color: #374151;
    border: 2px solid #e5e7eb;
    box-shadow: 0 2px 4px rgba(0, 0, 0, 0.05);
}

.btn-secondary:hover {
    transform: translateY(-2px);
    background: #f9fafb;
    border-color: #d1d5db;
    box-shadow: 0 4px 8px rgba(0, 0, 0, 0.1);
}

.btn-danger {
    background: linear-gradient(135deg, #ef4444 0%, #dc2626 100%);
    color: white;
    box-shadow: 0 4px 12px rgba(239, 68, 68, 0.3);
}

.btn-danger:hover {
    transform: translateY(-2px);
    box-shadow: 0 6px 20px rgba(239, 68, 68, 0.4);
    background: linear-gradient(135deg, #dc2626 0%, #b91c1c 100%);
}

/* Modal Section Headers */
.modal h4 {
    margin-top: 1.5rem;
    margin-bottom: 1rem;
    font-size: 0.875rem;
    color: #6b7280;
    text-transform: uppercase;
    letter-spacing: 0.5px;
    font-weight: 600;
    padding-left: 0.5rem;
    border-left: 3px solid #10b981;
}

/* Message Modal Styles */
.message-modal-overlay {
    position: fixed;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: rgba(0, 0, 0, 0.6);
    display: flex;
    justify-content: center;
    align-items: center;
    z-index: 1001;
    backdrop-filter: blur(4px);
    animation: fadeIn 0.3s ease-out;
}

.message-modal {
    background: white;
    border-radius: 12px;
    padding: 2rem;
    max-width: 400px;
    width: 90%;
    text-align: center;
    box-shadow: 0 20px 40px rgba(0, 0, 0, 0.3);
    animation: scaleIn 0.3s ease-out;
}

.success-modal {
    border-top: 4px solid #28a745;
}

.error-modal {
    border-top: 4px solid #dc3545;
}

.message-icon {
    font-size: 3rem;
    margin-bottom: 1rem;
    font-weight: bold;
}

.success-modal .message-icon {
    color: #28a745;
}

.error-modal .message-icon {
    color: #dc3545;
}

.message-text {
    font-size: 1.1rem;
    margin-bottom: 1.5rem;
    color: #333;
    line-height: 1.5;
}

.message-close-btn {
    background: #2a5298;
    color: white;
    border: none;
    padding: 0.75rem 2rem;
    border-radius: 6px;
    font-size: 1rem;
    font-weight: 500;
    cursor: pointer;
    transition: background 0.2s ease;
}

.message-close-btn:hover {
    background: #1e3c72;
}

.modal-buttons {
    display: flex;
    gap: 1rem;
    justify-content: center;
    margin-top: 1rem;
}

.cancel-btn {
    background: #6c757d !important;
}

.cancel-btn:hover {
    background: #545b62 !important;
}

.delete-btn {
    background: #dc3545 !important;
}

.delete-btn:hover {
    background: #c82333 !important;
}

.delete-modal {
    border-top: 4px solid #dc3545;
}

/* Video Thumbnail Styles */
.video-thumbnail {
    position: relative;
    width: 100%;
    height: 200px;
    overflow: hidden;
    border-radius: 8px;
    cursor: pointer;
    background: #000;
}

.video-thumbnail video {
    max-width: 100%;
    max-height: 100%;
    width: auto;
    height: auto;
    object-fit: contain;
    display: block;
}

.video-overlay {
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: rgba(0, 0, 0, 0.3);
    display: flex;
    justify-content: center;
    align-items: center;
    opacity: 0;
    transition: opacity 0.3s ease;
}

.video-thumbnail:hover .video-overlay {
    opacity: 1;
}

.play-btn {
    background: rgba(255, 255, 255, 0.9);
    border: none;
    border-radius: 50%;
    width: 60px;
    height: 60px;
    font-size: 20px;
    cursor: pointer;
    transition: all 0.3s ease;
    display: flex;
    align-items: center;
    justify-content: center;
}

.play-btn:hover {
    background: white;
    transform: scale(1.1);
}

/* Video Modal Styles */
.video-modal-overlay {
    position: fixed;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: rgba(0, 0, 0, 0.9);
    display: flex;
    justify-content: center;
    align-items: center;
    z-index: 1002;
    animation: fadeIn 0.3s ease-out;
}

.video-modal {
    background: white;
    border-radius: 12px;
    max-width: 90vw;
    max-height: 90vh;
    width: 80vw;
    min-width: 600px;
    overflow: hidden;
    animation: scaleIn 0.3s ease-out;
}

.video-modal-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 1rem 1.5rem;
    border-bottom: 1px solid #eee;
    background: white;
}

.video-modal-header h3 {
    margin: 0;
    color: #333;
}

.video-modal-close {
    background: none;
    border: none;
    font-size: 2rem;
    cursor: pointer;
    color: #666;
    padding: 0;
    width: 30px;
    height: 30px;
    display: flex;
    align-items: center;
    justify-content: center;
    border-radius: 50%;
    transition: all 0.2s ease;
}

.video-modal-close:hover {
    background: #f5f5f5;
    color: #333;
}

.video-modal-content {
    padding: 0;
    background: #000;
}

.video-modal-content video {
    width: 100%;
    height: auto;
    max-height: 70vh;
    display: block;
}

/* Loading States */
.loading {
    display: flex;
    justify-content: center;
    align-items: center;
    height: 200px;
    font-size: 18px;
    color: #666;
}

.loading::after {
    content: '';
    width: 20px;
    height: 20px;
    border: 2px solid #f3f3f3;
    border-top: 2px solid #2a5298;
    border-radius: 50%;
    animation: spin 1s linear infinite;
    margin-left: 10px;
}

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

@keyframes fadeIn {
    0% {
        opacity: 0;
    }
    100% {
        opacity: 1;
    }
}

@keyframes scaleIn {
    0% {
        transform: scale(0.7);
        opacity: 0;
    }
    100% {
        transform: scale(1);
        opacity: 1;
    }
}

/* Modern Form Styles */
.section-header {
    margin-bottom: 2rem;
}

.section-header.text-center {
    display: block !important;
    text-align: center !important;
    width: 100%;
    justify-content: center !important;
}

.section-header.text-center h2 {
    margin-bottom: 0.5rem;
    font-size: 2rem;
    font-weight: 600;
    color: #333;
    text-align: center !important;
}

.section-header.text-center .section-subtitle {
    color: #666;
    font-size: 1rem;
    margin-top: 0.5rem;
    font-weight: 400;
    text-align: center !important;
}

.form-container {
    max-width: 600px;
    margin: 0 auto;
    padding: 0 1rem;
}

.modern-form {
    background: white;
    padding: 2rem;
    border-radius: 12px;
    box-shadow: 0 4px 16px rgba(0, 0, 0, 0.1);
}

.form-actions-modern {
    display: flex;
    gap: 1rem;
    justify-content: center;
    margin-top: 2rem;
    padding-top: 1.5rem;
    border-top: 1px solid #e1e5e9;
}

.btn-outline {
    background: transparent;
    color: #6c757d;
    border: 2px solid #e1e5e9;
    transition: all 0.2s ease;
}

.btn-outline:hover {
    background: #f8f9fa;
    border-color: #6c757d;
    color: #495057;
    transform: translateY(-1px);
}

/* Utility Classes */
.text-center { text-align: center; }
.text-left { text-align: left; }
.text-right { text-align: right; }

.mt-1 { margin-top: 0.5rem; }
.mt-2 { margin-top: 1rem; }
.mt-3 { margin-top: 1.5rem; }

.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; }

/* Responsive Design */
@media (max-width: 768px) {
    .form-row {
        grid-template-columns: 1fr;
    }
    
    .modal {
        margin: 1rem;
        width: calc(100% - 2rem);
    }
    
    .form-actions {
        flex-direction: column;
    }
    
    .btn {
        width: 100%;
        margin-bottom: 0.5rem;
    }
}