/* Soccer API Dark Professional Theme */

/* CSS Variables for Consistent Color Scheme */
:root {
    --primary-color: #0c95d2;
    --primary-hover: #035272;
    --secondary-color: #1a1d23;
    --background-dark: #0f1419;
    --surface-dark: #1a1d23;
    --surface-light: #252932;
    --text-primary: #ffffff;
    --text-secondary: #a8b3cf;
    --text-muted: #6c7293;
    --border-color: #2a2f3a;
    --success-color: #024b68;
    --danger-color: #ff4757;
    --warning-color: #ffa502;
    --info-color: #3742fa;
    --shadow-light: rgba(0, 255, 136, 0.1);
    --shadow-dark: rgba(0, 0, 0, 0.3);
    --gradient-primary: linear-gradient(135deg, #003b51 0%, #0ea5e9 100%);
    --gradient-secondary: linear-gradient(135deg, #1a1d23 0%, #252932 100%);
    --gradient-card: linear-gradient(145deg, #1a1d23 0%, #252932 100%);
}

/* Base Styles */
body {
    background: var(--background-dark);
    color: var(--text-primary);
    font-family: 'Cairo', 'Inter', 'Segoe UI', -apple-system, BlinkMacSystemFont, sans-serif;
}

/* Table Styles */
table {
    width: 100%;
    border: 1px solid var(--border-color);
    border-collapse: collapse;
    overflow-x: auto;
    background: var(--surface-dark);
    border-radius: 12px;
    overflow: hidden;
    box-shadow: 0 8px 32px var(--shadow-dark);
}

th, td {
    padding: 16px 20px;
    border: 1px solid var(--border-color);
    text-align: center;
    color: var(--text-primary);
}

th {
    background: var(--gradient-secondary);
    font-weight: 600;
    font-size: 14px;
    text-transform: uppercase;
    letter-spacing: 0.5px;
}

/* Widget Base Styles */
.soccer-matches-widget,
.soccer-teams-widget,
.soccer-players-widget {
    direction: rtl;
    font-family: 'Cairo', 'Inter', sans-serif;
    background: var(--background-dark);
    color: var(--text-primary);
}

/* Match Schedule Slider */
.match-schedule-slider {
    padding: 24px 30px;
    width: 100%;
    margin: auto;
    position: relative;
}

.match-schedule-slider::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    height: 2px;
    background: var(--gradient-primary);
    border-radius: 20px 20px 0 0;
}

/* Tabs Styles */
.match-schedule-slider .btns {
    margin-bottom: 32px;
    text-align: center;
}

.btns {
    display: flex;
    justify-content: center;
}

.btns ul {
    list-style: none;
    padding: 0;
    margin: 0;
    display: inline-flex;
    background: var(--surface-dark);
    border-radius: 16px;
    box-shadow: inset 0 2px 8px rgba(0, 0, 0, 0.3);
    overflow: hidden;
    border: 1px solid var(--border-color);
    backdrop-filter: blur(10px);
}

.btns ul li {
    padding: 16px 28px;
    cursor: pointer;
    transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
    background: transparent;
    color: var(--text-secondary);
    font-weight: 500;
    border-right: 1px solid var(--border-color);
    position: relative;
    font-size: 14px;
}

.btns ul li:first-child {
    border-right: none;
}

.btns ul li::before {
    content: '';
    position: absolute;
    bottom: 0;
    left: 0;
    right: 0;
    height: 2px;
    background: var(--gradient-primary);
    transform: scaleX(0);
    transition: transform 0.3s ease;
}

.btns ul li:hover {
    background: rgba(0, 255, 136, 0.1);
    color: var(--primary-color);
    transform: translateY(-1px);
}

.btns ul li:hover::before {
    transform: scaleX(1);
}

.btns ul li.active {
    background: var(--gradient-primary);
    color: var(--background-dark);
    box-shadow: 0 4px 20px var(--shadow-light);
    font-weight: 600;
	color:white;
}

.btns ul li.active::before {
    display: none;
}

/* Days Buttons */
#days-buttons {
    display: flex;
    margin-bottom: 32px;
    gap: 8px;
    padding: 8px;
    background: var(--surface-dark);
    border-radius: 16px;
    border: 1px solid var(--border-color);
}

#days-buttons > * {
    flex-grow: 1;
    min-height: 52px;
    font-size: 14px;
    color: var(--text-secondary);
    cursor: pointer;
    border-radius: 12px;
    transition: all 0.3s ease;
    display: flex;
    align-items: center;
    justify-content: center;
    font-weight: 500;
    border: 1px solid transparent;
}

#days-buttons > *:hover {
    background: rgba(0, 255, 136, 0.1);
    color: var(--primary-color);
    border-color: var(--primary-color);
}

#days-buttons .btn.active {
    background: var(--gradient-primary);
    color: var(--background-dark);
    box-shadow: 0 6px 24px var(--shadow-light);
    font-weight: 600;
}

/* Match Cards */
.print-matches {
    display: flex;
    flex-direction: column;
    gap: 20px;
}

.card-match {
    display: flex;
    flex-direction: column;
    gap: 16px;
    background: var(--gradient-card);
    padding: 24px;
    border-radius: 20px;
    overflow: hidden;
    font-size: 14px;
    position: relative;
    border: 1px solid var(--border-color);
    box-shadow: 0 8px 32px var(--shadow-dark);
    backdrop-filter: blur(10px);
    transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
}

.card-match::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    height: 3px;
    background: var(--gradient-primary);
    border-radius: 20px 20px 0 0;
}

.card-match:hover {
    transform: translateY(-4px);
    box-shadow: 0 16px 48px var(--shadow-dark);
    border-color: var(--primary-color);
}

.match-link {
    position: absolute;
    inset: 0;
    transform: translate(0) !important;
    background-color: transparent !important;
    z-index: 1;
}

.card-match .league-name {
    text-align: center;
    font-size: 14px;
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 12px;
    color: var(--text-secondary);
    font-weight: 500;
}

.league-logo {
    width: 28px !important;
    height: 28px !important;
    object-fit: contain;
    border-radius: 6px;
}

.card-match-group {
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: 16px 0;
}

.card-match .team {
    width: 36%;
    display: flex;
    flex-direction: column;
    gap: 12px;
    align-items: center;
}

.card-match .team-logo {
    width: 48px !important;
    height: 48px !important;
    object-fit: contain;
    border-radius: 8px;
    box-shadow: 0 4px 16px rgba(0, 0, 0, 0.3);
}

.match-info {
    display: flex;
    align-items: center;
    gap: 8px;
    color: var(--text-secondary);
    flex-direction: column;
}

.match-times {
    display: flex;
    flex-direction: column;
    justify-content: center;
    align-items: center;
    gap: 8px;
}

.match-status {
    color: inherit;
}

.status-text {
    color: var(--text-primary);
    border-radius: 8px;
    padding: 6px 12px;
    width: max-content;
    margin: 0 auto 8px;
    font-weight: 600;
    font-size: 12px;
    text-transform: uppercase;
    letter-spacing: 0.5px;
}

.match-not-start {
    background: linear-gradient(135deg, #3742fa, #2f3542);
    box-shadow: 0 4px 16px rgba(55, 66, 250, 0.3);
}

.match-live {
    background: linear-gradient(135deg, #00ff88, #00cc6a);
    color: var(--background-dark);
    animation: pulse 2s infinite;
    box-shadow: 0 4px 16px rgba(0, 255, 136, 0.4);
}

.match-end {
    background: linear-gradient(135deg, #ff4757, #c44569);
    box-shadow: 0 4px 16px rgba(255, 71, 87, 0.3);
}

.match-cancel {
    background: linear-gradient(135deg, #57606f, #2f3542);
    box-shadow: 0 4px 16px rgba(87, 96, 111, 0.3);
}

.match-break {
    background: linear-gradient(135deg, #ffa502, #ff6348);
    color: var(--background-dark);
    box-shadow: 0 4px 16px rgba(255, 165, 2, 0.3);
}

.home-score-g, .away-score-g {
    font-size: 32px;
    font-weight: 700;
    color: var(--primary-color);
    text-shadow: 0 2px 8px rgba(0, 255, 136, 0.3);
}

.teams-score {
    display: flex;
    align-items: center;
    justify-content: space-around;
    width: 100%;
}

/* Navigation Buttons */
.match-schedule-slider .owl-prev,
.match-schedule-slider .owl-next {
    color: var(--text-primary) !important;
    background: var(--gradient-primary) !important;
    width: 48px;
    height: 48px;
    border-radius: 12px !important;
    inset-block: 0;
    position: absolute;
    border: 1px solid var(--border-color);
    backdrop-filter: blur(10px);
    transition: all 0.3s ease;
    box-shadow: 0 4px 16px var(--shadow-light);
}

.match-schedule-slider .owl-prev {
    inset-inline-start: -52px;
}

.match-schedule-slider .owl-next {
    inset-inline-end: -52px;
}

.match-schedule-slider .owl-prev:hover,
.match-schedule-slider .owl-next:hover {
    transform: scale(1.1);
    box-shadow: 0 8px 24px var(--shadow-light);
}

/* Match Actions */
.match-actions {
    text-align: center;
    margin-top: 20px;
    padding-top: 20px;
    border-top: 1px solid var(--border-color);
}

.btn-details {
    background: var(--gradient-primary);
    color: var(--background-dark);
    padding: 12px 24px;
    border-radius: 12px;
    text-decoration: none;
    font-size: 14px;
    font-weight: 600;
    transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
    display: inline-block;
    border: 1px solid transparent;
    box-shadow: 0 4px 16px var(--shadow-light);
}

.btn-details:hover {
    transform: translateY(-2px);
    box-shadow: 0 8px 32px var(--shadow-light);
    text-decoration: none;
    color: var(--background-dark);
    border-color: var(--primary-color);
}

/* Teams Grid */
.teams-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(320px, 1fr));
    gap: 24px;
    padding: 24px 0;
}

.team-card {
    background: var(--gradient-card);
    border-radius: 20px;
    padding: 32px;
    text-align: center;
    box-shadow: 0 8px 32px var(--shadow-dark);
    transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
    border: 1px solid var(--border-color);
    backdrop-filter: blur(10px);
    position: relative;
}

.team-card::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    height: 3px;
    background: var(--gradient-primary);
    border-radius: 20px 20px 0 0;
}

.team-card:hover,
.team-card.hover-effect {
    transform: translateY(-8px) scale(1.02);
    box-shadow: 0 20px 60px var(--shadow-dark);
    border-color: var(--primary-color);
}

.team-logo {
    margin-bottom: 24px;
}

.team-logo img {
    width: 90px;
    height: 90px;
    object-fit: contain;
    border-radius: 16px;
    box-shadow: 0 8px 24px rgba(0, 0, 0, 0.4);
    background: var(--surface-light);
    padding: 8px;
}

.team-name {
    font-size: 12px;
    font-weight: 700;
    color: var(--text-primary);
    margin: 0 0 12px 0;
}

.team-country {
    color: var(--text-secondary);
    font-size: 15px;
    display: flex;
    align-items: center;
    gap: 12px;
    justify-content: center;
    margin-bottom: 24px;
}

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

/* Buttons */
.btn-primary,
.btn-secondary {
    padding: 12px 20px;
    border-radius: 12px;
    text-decoration: none;
    font-size: 14px;
    font-weight: 600;
    transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
    display: inline-block;
    border: 1px solid transparent;
}

.btn-primary {
    background: var(--gradient-primary);
    color: var(--background-dark);
    box-shadow: 0 4px 16px var(--shadow-light);
}

.btn-primary:hover {
    transform: translateY(-2px);
    box-shadow: 0 8px 24px var(--shadow-light);
    text-decoration: none;
    color: var(--background-dark);
}

.btn-secondary {
    background: var(--surface-light);
    color: var(--text-secondary);
    border: 1px solid var(--border-color);
}

.btn-secondary:hover {
    background: var(--border-color);
    color: var(--text-primary);
    text-decoration: none;
    transform: translateY(-1px);
}

/* Players Grid */
.players-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(280px, 1fr));
    gap: 24px;
    padding: 24px 0;
}

.player-card {
    background: var(--gradient-card);
    border-radius: 20px;
    padding: 28px;
    text-align: center;
    box-shadow: 0 8px 32px var(--shadow-dark);
    transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
    border: 1px solid var(--border-color);
    backdrop-filter: blur(10px);
    position: relative;
}

.player-card::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    height: 3px;
    background: var(--gradient-primary);
    border-radius: 20px 20px 0 0;
}

.player-card:hover,
.player-card.hover-effect {
    transform: translateY(-6px);
    box-shadow: 0 16px 48px var(--shadow-dark);
    border-color: var(--primary-color);
}

.player-image {
    margin-bottom: 20px;
}

.player-image img {
    width: 80px;
    height: 80px;
    object-fit: cover;
    border-radius: 50%;
    box-shadow: 0 8px 24px rgba(0, 0, 0, 0.4);
    border: 3px solid var(--primary-color);
}

.player-name {
    font-size: 18px;
    font-weight: 700;
    color: var(--text-primary);
    margin: 0 0 8px 0;
}

.player-position {
    color: var(--text-secondary);
    font-size: 15px;
    margin-bottom: 8px;
    font-weight: 500;
}

.player-age {
    color: var(--text-muted);
    font-size: 13px;
    margin-bottom: 20px;
}
.match-time {
    text-align: center;
}

/* Status Messages */
.no-matches,
.error {
    text-align: center;
    padding: 48px 24px;
    color: var(--text-secondary);
    font-size: 18px;
    background: var(--gradient-card);
    border-radius: 16px;
    margin: 24px 0;
    border: 1px solid var(--border-color);
    box-shadow: 0 8px 32px var(--shadow-dark);
}

.error {
    background: linear-gradient(135deg, rgba(255, 71, 87, 0.1), rgba(196, 69, 105, 0.1));
    color: var(--danger-color);
    border-color: var(--danger-color);
}

/* Dashboard Improvements */
.nav-tab-wrapper {
    margin-bottom: 24px;
    background: var(--surface-dark);
    border-radius: 12px;
    border: 1px solid var(--border-color);
}

#matches-content,
#teams-content,
#players-content {
    background: var(--surface-dark);
    padding: 24px;
    border-radius: 16px;
    box-shadow: 0 8px 32px var(--shadow-dark);
    border: 1px solid var(--border-color);
}

.tablenav {
    margin-bottom: 24px;
    padding: 16px 0;
}

.tablenav select,
.tablenav input {
    margin-left: 12px;
    background: var(--surface-light);
    color: var(--text-primary);
    border: 1px solid var(--border-color);
    border-radius: 8px;
    padding: 8px 12px;
}

/* Table Data Columns */
.td-col {
    display: flex;
    flex-direction: column;
    gap: 8px;
}

.td-group {
    display: flex;
    align-items: center;
    gap: 16px;
}

.team-logo {
    width: 36px;
    height: 36px;
    object-fit: contain;
    border-radius: 6px;
}

.td-group .team-logo {
    margin: 0;
}

.recent-form {
    display: flex;
    gap: 6px;
    justify-content: center;
}

.recent-form > span {
    width: 18px;
    height: 18px;
    border-radius: 50%;
    box-shadow: 0 2px 8px rgba(0, 0, 0, 0.3);
}

.recent-form > span.W {
    background: var(--gradient-primary);
}

.recent-form > span.L {
    background: linear-gradient(135deg, #ff4757, #c44569);
}

.recent-form > span.D {
    background: linear-gradient(135deg, #57606f, #747d8c);
}

/* Loading Animation */
.loading {
    text-align: center;
    padding: 32px;
    color: var(--text-secondary);
}

.loading::after {
    content: '';
    display: inline-block;
    width: 32px;
    height: 32px;
    border: 3px solid var(--border-color);
    border-top: 3px solid var(--primary-color);
    border-radius: 50%;
    animation: spin 1s linear infinite;
    box-shadow: 0 0 20px var(--shadow-light);
}

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

@keyframes pulse {
    0% { 
        opacity: 1; 
        box-shadow: 0 4px 16px rgba(0, 255, 136, 0.4);
    }
    50% { 
        opacity: 0.8; 
        box-shadow: 0 4px 24px rgba(0, 255, 136, 0.6);
    }
    100% { 
        opacity: 1; 
        box-shadow: 0 4px 16px rgba(0, 255, 136, 0.4);
    }
}

/* Owl Carousel Dark Theme */
.owl-carousel .owl-nav {
    margin-top: 24px;
    text-align: center;
}

.owl-carousel .owl-nav button {
    background: var(--gradient-primary) !important;
    color: var(--background-dark) !important;
    border-radius: 12px !important;
    width: 48px !important;
    height: 48px !important;
    margin: 0 8px !important;
    font-size: 18px !important;
    transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1) !important;
    border: 1px solid var(--border-color) !important;
    box-shadow: 0 4px 16px var(--shadow-light) !important;
}

.owl-carousel .owl-nav button:hover {
    transform: scale(1.1) translateY(-2px);
    box-shadow: 0 8px 24px var(--shadow-light) !important;
}

.owl-carousel .owl-nav button.owl-prev {
    margin-left: 12px !important;
}

.owl-carousel .owl-nav button.owl-next {
    margin-right: 12px !important;
}

/* Responsive Design */
@media (max-width: 768px) {
    .match-teams {
        flex-direction: column;
        gap: 20px;
    }
    
    .match-score {
        margin: 0;
        order: -1;
    }
    
    .teams-grid,
    .players-grid {
        grid-template-columns: repeat(auto-fill, minmax(280px, 1fr));
        gap: 20px;
    }
    
    .team-actions {
        flex-direction: column;
    }
    
    .match-schedule-slider .btns ul {
        flex-direction: column;
        width: 100%;
    }
    
    .match-schedule-slider .btns ul li {
        border-right: none;
        border-bottom: 1px solid var(--border-color);
    }
    
    .match-schedule-slider .btns ul li:last-child {
        border-bottom: none;
    }
    
    .match-schedule-slider {
        width: calc(100% - 32px);
    }
}

@media (max-width: 480px) {
    .match-schedule-slider {
        padding: 20px 16px;
        width: calc(100% - 16px);
    }
    
    .card-match {
        padding: 20px;
    }
    
    .teams-grid,
    .players-grid {
        grid-template-columns: 1fr;
    }
    
    .team-card,
    .player-card {
        padding: 24px 20px;
    }
    
    #days-buttons {
        flex-direction: column;
        gap: 8px;
    }
    
    .btns ul {
        flex-direction: column;
    }
    
    .btns ul li {
        border-right: none !important;
        border-bottom: 1px solid var(--border-color);
    }
    
    .btns ul li:last-child {
        border-bottom: none;
    }
}

/* Scrollbar Styling */
::-webkit-scrollbar {
    width: 8px;
    height: 8px;
}

::-webkit-scrollbar-track {
    background: var(--surface-dark);
}

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

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

/* Selection Styling */
::selection {
    background: var(--primary-color);
    color: var(--background-dark);
}

/* Focus Styles */
button:focus,
.btn-primary:focus,
.btn-secondary:focus,
.btn-details:focus {
    outline: 2px solid var(--primary-color);
    outline-offset: 2px;
}
.owl-nav button {
    min-height: 100% !important;
    
}
/* Accessibility Improvements */
@media (prefers-reduced-motion: reduce) {
    *,
    *::before,
    *::after {
        animation-duration: 0.01ms !important;
        animation-iteration-count: 1 !important;
        transition-duration: 0.01ms !important;
        scroll-behavior: auto !important;
    }
}