/* Tennis Court Matcher Custom Styles */

/* Tennis-themed colors and styling */
:root {
    --tennis-green: #0d6efd;
    --tennis-court: #2d5016;
    --tennis-ball: #ccff33;
    --court-line: #ffffff;
}

/* Theme toggle button styling */
#theme-toggle {
    border: 1px solid rgba(255, 255, 255, 0.3);
    transition: all 0.3s ease;
}

#theme-toggle:hover {
    background-color: rgba(255, 255, 255, 0.1);
    border-color: rgba(255, 255, 255, 0.5);
    transform: scale(1.05);
}

/* Light theme specific adjustments */
[data-bs-theme="light"] {
    --bs-body-bg: #ffffff;
    --bs-body-color: #212529;
}

[data-bs-theme="light"] .hero-section {
    background: linear-gradient(135deg, #0d6efd 0%, #0a58ca 100%);
}

[data-bs-theme="light"] .card {
    border: 1px solid #dee2e6;
}

/* Dark theme specific adjustments */
[data-bs-theme="dark"] {
    --bs-body-bg: #212529;
    --bs-body-color: #ffffff;
}

/* Hero section styling */
.hero-section {
    background: linear-gradient(135deg, var(--tennis-green) 0%, var(--tennis-court) 100%);
    color: white;
    padding: 4rem 0;
    margin-bottom: 2rem;
    position: relative;
    overflow: hidden;
}

/* Hero section with background image */
.hero-section.with-bg-image {
    background-attachment: fixed;
    background-repeat: no-repeat;
    position: relative;
    text-shadow: 2px 2px 4px rgba(0,0,0,0.5);
}

.hero-section.with-bg-image::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: rgba(0,0,0,0.3);
    z-index: 1;
}

.hero-section.with-bg-image .container {
    position: relative;
    z-index: 2;
}

/* Enhanced hero content styling */
.hero-section h1 {
    text-shadow: 3px 3px 6px rgba(0,0,0,0.7);
    margin-bottom: 1.5rem;
}

.hero-section .lead {
    text-shadow: 2px 2px 4px rgba(0,0,0,0.6);
    margin-bottom: 2rem;
}

/* Hero buttons with enhanced styling */
.hero-section .btn {
    box-shadow: 0 4px 15px rgba(0,0,0,0.2);
    border: 2px solid transparent;
    font-weight: 600;
    padding: 12px 30px;
    text-transform: uppercase;
    letter-spacing: 1px;
    transition: all 0.3s ease;
}

.hero-section .btn:hover {
    transform: translateY(-2px);
    box-shadow: 0 6px 20px rgba(0,0,0,0.3);
}

.hero-section .btn-outline-light:hover {
    background-color: rgba(255,255,255,0.9);
    border-color: rgba(255,255,255,0.9);
    color: var(--tennis-green);
}

/* Tennis ball animation */
.tennis-ball-icon {
    animation: bounce 2s infinite;
}

@keyframes bounce {
    0%, 20%, 50%, 80%, 100% {
        transform: translateY(0);
    }
    40% {
        transform: translateY(-10px);
    }
    60% {
        transform: translateY(-5px);
    }
}

/* Card hover effects */
.card {
    transition: transform 0.2s ease-in-out, box-shadow 0.2s ease-in-out;
}

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

/* Status badges */
.badge {
    font-size: 0.75em;
    font-weight: 500;
}

/* Button enhancements */
.btn {
    border-radius: 0.5rem;
    font-weight: 500;
    transition: all 0.2s ease-in-out;
}

.btn:hover {
    transform: translateY(-1px);
}

/* Form styling */
.form-control:focus {
    border-color: var(--tennis-green);
    box-shadow: 0 0 0 0.2rem rgba(13, 110, 253, 0.25);
}

/* Custom input group styling */
.input-group-text {
    background-color: var(--bs-secondary-bg);
    border-color: var(--bs-border-color);
}

/* Table enhancements */
.table th {
    border-top: none;
    font-weight: 600;
    background-color: var(--bs-secondary-bg);
}

.table-hover tbody tr:hover {
    background-color: var(--bs-secondary-bg);
}

/* Alert styling */
.alert {
    border: none;
    border-radius: 0.5rem;
}

/* Footer styling */
footer {
    margin-top: auto;
}

/* Responsive adjustments */
@media (max-width: 768px) {
    .display-4 {
        font-size: 2rem;
    }
    
    .card-header h5 {
        font-size: 1rem;
    }
    
    .btn-lg {
        padding: 0.5rem 1rem;
        font-size: 1rem;
    }
}

/* Loading spinner for forms */
.btn.loading {
    position: relative;
    color: transparent;
}

.btn.loading:after {
    content: "";
    position: absolute;
    width: 16px;
    height: 16px;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    margin: auto;
    border: 2px solid transparent;
    border-top-color: #ffffff;
    border-radius: 50%;
    animation: button-loading-spinner 1s ease infinite;
}

@keyframes button-loading-spinner {
    from {
        transform: rotate(0turn);
    }
    to {
        transform: rotate(1turn);
    }
}

/* Skill level badge colors */
.skill-beginner {
    background-color: #28a745 !important;
}

.skill-intermediate {
    background-color: #ffc107 !important;
    color: #212529 !important;
}

.skill-advanced {
    background-color: #dc3545 !important;
}

/* Custom scrollbar for webkit browsers */
::-webkit-scrollbar {
    width: 8px;
}

::-webkit-scrollbar-track {
    background: var(--bs-secondary-bg);
}

::-webkit-scrollbar-thumb {
    background: var(--bs-border-color);
    border-radius: 4px;
}

::-webkit-scrollbar-thumb:hover {
    background: var(--bs-secondary);
}

/* Profile picture placeholder */
.profile-picture {
    width: 64px;
    height: 64px;
    border-radius: 50%;
    background: linear-gradient(135deg, var(--tennis-green), var(--tennis-court));
    display: flex;
    align-items: center;
    justify-content: center;
    color: white;
    font-size: 1.5rem;
    font-weight: bold;
}

/* Court booking status indicators */
.status-indicator {
    width: 12px;
    height: 12px;
    border-radius: 50%;
    display: inline-block;
    margin-right: 0.5rem;
}

.status-unmatched {
    background-color: #ffc107;
}

.status-matched {
    background-color: #28a745;
}

.status-expired {
    background-color: #dc3545;
}

/* Tennis court visual element */
.court-lines {
    background-image: 
        linear-gradient(90deg, var(--court-line) 2px, transparent 2px),
        linear-gradient(var(--court-line) 2px, transparent 2px);
    background-size: 20px 20px;
    background-position: 0 0, 0 0;
    opacity: 0.1;
}

/* Empty state styling */
.empty-state {
    padding: 3rem 1rem;
    text-align: center;
    color: var(--bs-secondary);
}

.empty-state i {
    font-size: 4rem;
    margin-bottom: 1rem;
    opacity: 0.5;
}

/* Success animations */
@keyframes checkmark {
    0% {
        stroke-dasharray: 44;
        stroke-dashoffset: 44;
    }
    100% {
        stroke-dasharray: 44;
        stroke-dashoffset: 0;
    }
}

.checkmark {
    animation: checkmark 0.6s ease-in-out;
}

/* Notification dots */
.notification-dot {
    width: 8px;
    height: 8px;
    background-color: #dc3545;
    border-radius: 50%;
    position: absolute;
    top: -2px;
    right: -2px;
}

/* Match status styling */
.match-status {
    padding: 0.5rem 1rem;
    border-radius: 2rem;
    font-size: 0.875rem;
    font-weight: 500;
    text-transform: uppercase;
    letter-spacing: 0.5px;
}

.match-status.pending {
    background-color: rgba(255, 193, 7, 0.2);
    color: #856404;
    border: 1px solid rgba(255, 193, 7, 0.5);
}

.match-status.approved {
    background-color: rgba(40, 167, 69, 0.2);
    color: #155724;
    border: 1px solid rgba(40, 167, 69, 0.5);
}

.match-status.rejected {
    background-color: rgba(220, 53, 69, 0.2);
    color: #721c24;
    border: 1px solid rgba(220, 53, 69, 0.5);
}

/* Dark theme adjustments */
[data-bs-theme="dark"] .match-status.pending {
    background-color: rgba(255, 193, 7, 0.15);
    color: #ffc107;
}

[data-bs-theme="dark"] .match-status.approved {
    background-color: rgba(40, 167, 69, 0.15);
    color: #28a745;
}

[data-bs-theme="dark"] .match-status.rejected {
    background-color: rgba(220, 53, 69, 0.15);
    color: #dc3545;
}
