/* Exact CSS from provided HTML, adapted for RTL and Arabic, with date slider styles added */
:root { --primary-color: #1a365d; --secondary-color: #2d3748; --accent-color: #3182ce; --success-color: #38a169; --warning-color: #d69e2e; --error-color: #e53e3e; --live-color: #e53e3e; --bg-primary: #ffffff; --bg-secondary: #f7fafc; --bg-tertiary: #edf2f7; --text-primary: #1a202c; --text-secondary: #4a5568; --text-muted: #718096; --border-color: #e2e8f0; --shadow-sm: 0 1px 3px 0 rgba(0, 0, 0, 0.1), 0 1px 2px 0 rgba(0, 0, 0, 0.06); --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); --radius-sm: 0.375rem; --radius-md: 0.5rem; --radius-lg: 0.75rem; --radius-xl: 1rem; --transition-fast: 150ms ease-in-out; --transition-normal: 300ms ease-in-out; --transition-slow: 500ms ease-in-out; } /* Dark mode support */ @media (prefers-color-scheme: dark) { :root { --bg-primary: #1a202c; --bg-secondary: #2d3748; --bg-tertiary: #4a5568; --text-primary: #f7fafc; --text-secondary: #e2e8f0; --text-muted: #a0aec0; --border-color: #4a5568; } }

/* Light mode support (optional, for user preference) */
@media (prefers-color-scheme: light) {
    :root {
        --primary-color: #1e40af; /* Brighter blue for light mode */
        --secondary-color: #f3f4f6; /* Light gray */
        
        --bg-primary: #ffffff;
        --bg-secondary: #f9fafb;
        --bg-tertiary: #f3f4f6;
        
        --text-primary: #111827;
        --text-secondary: #6b7280;
        --text-muted: #9ca3af;
        
        --border-color: #d1d5db;
        --shadow-sm: 0 1px 3px 0 rgba(0, 0, 0, 0.1), 0 1px 2px 0 rgba(0, 0, 0, 0.06);
        --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);
    }
}

input[type=date], input[type=email], input[type=number], input[type=password], input[type=search], input[type=tel], input[type=text], input[type=url], select, textarea {
    border: none;
}
 

/* Base Styles */
* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

body {
    font-family: 'Noto Kufi Arabic', -apple-system, BlinkMacSystemFont, 'Segoe UI', 'Roboto', 'Oxygen',
        'Ubuntu', 'Cantarell', 'Fira Sans', 'Droid Sans', 'Helvetica Neue', sans-serif;
    -webkit-font-smoothing: antialiased;
    -moz-osx-font-smoothing: grayscale;
    background-color: var(--bg-secondary);
    color: var(--text-primary);
    line-height: 1.6;
    direction: rtl;
}

/* App Layout */
.app {
    min-height: 100vh;
    padding: 0;
}

/* Header Styles */
.app-header {
    background: linear-gradient(-135deg, var(--primary-color) 0%, var(--accent-color) 100%);
    color: white;
    padding: 3rem 2rem 2rem;
    text-align: center;
    position: relative;
    overflow: hidden;
}

.app-header::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: url('data:image/svg+xml,<svg xmlns="http://www.w3.org/2000/svg" viewBox="0 0 100 100"><defs><pattern id="grain" width="100" height="100" patternUnits="userSpaceOnUse"><circle cx="25" cy="25" r="1" fill="white" opacity="0.1"/><circle cx="75" cy="75" r="1" fill="white" opacity="0.1"/><circle cx="50" cy="10" r="0.5" fill="white" opacity="0.1"/></pattern></defs><rect width="100" height="100" fill="url(%23grain)"/></svg>');
    opacity: 0.1;
}

.header-content {
    position: relative;
    z-index: 1;
}

/* Swiper Date Slider */
.date-slider-container {
    position: relative;
    overflow: hidden;
    padding: 10px 40px; /* مساحة للـ arrows */
}

.swiper-wrapper {
    display: flex;
}



.date-day {
    font-size: 10px;
    color: white;
}

.date-number {
    font-size: 18px;
    font-weight: bold;
    margin: 2px 0;
}

.date-month {
    font-size: 11px;
    color: #d1d1d1;
}

/* Arrows Styling */
.date-arrow-next,
.date-arrow-prev {
    color: #00796b;
    background: rgba(255, 255, 255, 0.9);
    border-radius: 50%;
    width: 40px;
    height: 40px;
    top: 50%;
    transform: translateY(-50%);
    z-index: 10;
}

.date-arrow-next {
    right: 10px;
}

.date-arrow-prev {
    left: 10px;
}

.date-arrow-next::after,
.date-arrow-prev::after {
    font-size: 16px;
    font-weight: bold;
}

.app-title {
    font-size: 2.5rem;
    font-weight: 800;
    margin-bottom: 0.5rem;
    letter-spacing: -0.025em;
}

.app-subtitle {
    font-size: 1.125rem;
    opacity: 0.9;
    font-weight: 400;
}

/* Date Slider */
.date-slider-container {
    padding: 1.5rem 4rem;
    border-bottom: 1px solid #61ad671a;
}

.date-slider-title {
    font-size: 1.5rem;
    font-weight: 700;
    color: var(--text-primary);
    margin-bottom: 1rem;
    text-align: center;
}

.date-slider {
    display: flex;
    gap: 0.5rem;
    overflow-x: auto;
    padding: 0.5rem 0;
    scroll-behavior: smooth;
    scrollbar-width: none;
    -ms-overflow-style: none;
}

.date-slider::-webkit-scrollbar {
    display: none;
}

.date-item {
    min-width: 80px;
    padding: 0.75rem 1rem;
    background: #61ad671a;
    border-radius: var(--radius-md);
    text-align: center;
    cursor: pointer;
    transition: all var(--transition-fast);
    border: 2px solid transparent;
    white-space: nowrap;
}

.date-item:hover {
    transform: translateY(-2px);
}

.date-item.active {
background: linear-gradient(135deg, #61ad67 0%, #073c21);
    color: white;
    border-color: #191b1a;
    box-shadow: 0 1px 3px 0 rgb(0 0 0 / 21%), 0 1px 2px 0 rgba(0, 0, 0, 0.06);
}

.date-day {
    font-size: 0.75rem;
    font-weight: 500;
    opacity: 0.8;
}

.date-number {
    font-size: 1.25rem;
    font-weight: 700;
}

.date-month {
    font-size: 0.75rem;
    font-weight: 500;
    text-transform: uppercase;
}

/* Filters Section */
.filters-container {
    padding: 1.5rem 4rem;
    display: flex;
    flex-wrap: wrap;
    gap: 1rem;
    align-items: center;
    position: sticky;
    top: 0;
    z-index: 100;
    backdrop-filter: blur(10px);
}

.filter-tabs {
    display: flex;
    gap: 0.5rem;
    padding: 0.25rem;
    border-radius: var(--radius-lg);
    border: 1px solid #61ad6785;
}

.filter-tab {
    padding: 0.75rem 1.5rem;
    border: none;
    background: transparent;
    color: var(--text-secondary);
    font-weight: 500;
    border-radius: var(--radius-md);
    cursor: pointer;
    transition: all var(--transition-fast);
    white-space: nowrap;
}

.filter-tab:hover {
    background: var(--bg-primary);
    color: var(--text-primary);
}

.filter-tab.active {
    background: linear-gradient(135deg, #61ad67 0%, #073c21);
    color: white;
    box-shadow: var(--shadow-sm);
}


.search-container {
    position: relative;
}

.search-input {
    background: #1a202c00;
    color: var(--text-primary);
    font-size: 0.875rem;
    text-align: right;
    border-bottom: 1px solid #61ad6785 !important;
    padding: .5rem 1rem !important;
    transition: all .3s !important;
    width: 100% !important;
    border-radius: var(--radius-sm) !important;
    border-top: 0 !important;
    border-right: 0 !important;
    border-left: 0 !important;
}

.search-input:focus {
    outline: none;
    border-color: var(--accent-color);
    box-shadow: 0 0 0 3px rgba(49, 130, 206, 0.1);
}

/* Matches Container */
.matches-container {
    padding: 2rem 4rem;
    margin: 0 auto;
}

.matches-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(400px, 1fr));
    gap: 1.5rem;
    animation: fadeInUp 0.6s ease-out;
}

@keyframes fadeInUp {
    from {
        opacity: 0;
        transform: translateY(20px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

/* Match Card Styles */
.match-card {
    background: linear-gradient(135deg, #101c11 0%, #010a06ba);
    border-radius: var(--radius-xl);
    padding: 1.5rem;
    box-shadow: var(--shadow-md);
    border: 1px solid #61ad6785;
    transition: all var(--transition-normal);
    position: relative;
    overflow: hidden;
    cursor: pointer;
}

.match-card:hover {
transform: translateY(-4px);
    box-shadow: var(--shadow-xl) !important;
    border-color: #61ad6785 !important;
}

.match-card.live {
    transform: translateY(-4px);
    box-shadow: var(--shadow-xl) !important;
    border-color: #61ad6785 !important;
}

.match-card.highlighted {
border-color: #d6dad700;
    box-shadow: 0 0 0 1px #61ad6742, var(--shadow-lg);
}
.match-card.highlighted::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    height: 3px;
    background: linear-gradient(-90deg, #61ad67, #81f7c8);
}

/* Live Match Pulse Effect */
.live-pulse {
    position: absolute;
    top: -2px;
    left: -2px;
    right: -2px;
    bottom: -2px;
    border-radius: var(--radius-xl);
    background: linear-gradient(-45deg, var(--live-color), transparent, var(--live-color));
    animation: pulse 2s infinite;
    z-index: -1;
}

@keyframes pulse {
    0%, 100% { opacity: 0.3; }
    50% { opacity: 0.7; }
}

/* Match Header */
.match-header1 {
    display: flex;
    justify-content: space-between;
    align-items: flex-start;
    margin-bottom: 1.5rem !important;
    padding: 0 !important;
    
}

.competition-info {
    flex: 1;
}

.competition-name {
    font-weight: 600;
    color: #61ad67;
    font-size: 0.875rem;
    text-transform: uppercase;
    letter-spacing: 0.05em;
}

.match-meta {
    display: flex;
    align-items: center;
    gap: 0.5rem;
    margin-top: 0.25rem;
    color: var(--text-muted);
    font-size: 0.75rem;
}

.favorite-btn {
    background: none;
    border: none;
    color: var(--text-muted);
    cursor: pointer;
    padding: 0.5rem;
    border-radius: var(--radius-sm);
    transition: all var(--transition-fast);
}

.favorite-btn:hover {
    background: #f8fafc00;
    color: var(--warning-color);
}

.favorite-btn.active {
    color: var(--warning-color);
}

/* Teams Container */
.teams-container {
    display: grid;
    grid-template-columns: 1fr auto 1fr;
    gap: 1rem;
    align-items: center;
    margin-bottom: 1.5rem;
}

.team {
    display: flex !important;
    align-items: center !important;
    gap: 0.75rem !important;
}

.team.away-team {
    flex-direction: row-reverse;
}

.team-logo {
    width: 48px;
    height: 48px;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 1.5rem;
    box-shadow: var(--shadow-sm);
    transition: all var(--transition-fast);
}

.match-card:hover .team-logo {
    transform: scale(1.1);
}

.match-card.live .team-logo {
    transform: scale(1.1);
}

.team-info {
    flex: 1;
}

.team.away-team .team-info {
    text-align: right;
}

.team-name {
    font-weight: 600;
    color: var(--text-primary);
    font-size: 1rem;
    line-height: 1.2;
}

.team-short {
    color: var(--text-muted);
    font-size: 0.75rem;
    font-weight: 500;
    text-transform: uppercase;
    letter-spacing: 0.05em;
}

/* Match Center (Score/Status) */
.match-center {
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 0.5rem;
    min-width: 80px;
}

.status-live {
    display: flex;
    align-items: center;
    gap: 0.5rem;
    background: var(--live-color);
    color: white;
    padding: 0.25rem 0.75rem;
    border-radius: var(--radius-sm);
    font-size: 0.75rem;
    font-weight: 600;
    text-transform: uppercase;
    letter-spacing: 0.05em;
}

.live-indicator {
    width: 6px;
    height: 6px;
    background: white;
    border-radius: 50%;
    animation: blink 1s infinite;
}

@keyframes blink {
    0%, 50% { opacity: 1; }
    51%, 100% { opacity: 0.3; }
}

.status-finished {
    background: linear-gradient(135deg, #61ad67 0%, #073c21);
    color: white;
    padding: 0.25rem 0.75rem;
    border-radius: var(--radius-sm);
    font-size: 0.75rem;
    font-weight: 600;
    text-transform: uppercase;
}

.status-upcoming {
    background: var(--bg-tertiary);
    color: var(--text-secondary);
    padding: 0.25rem 0.75rem;
    border-radius: var(--radius-sm);
    font-size: 0.75rem;
    font-weight: 600;
}

.score-display {
    display: flex;
    align-items: center;
    gap: 0.5rem;
    font-size: 1.5rem !important;
    font-weight: 700;
    color: var(--text-primary);
}

.score {
    min-width: 1.5rem;
    text-align: center;
}

.score-separator {
    color: var(--text-muted);
    font-weight: 400;
}

.match-time {
font-size: 1rem;
    font-weight: 600;
    color: var(--text-primary);
    padding: 0 !important;
    background: #fff0 !important;
    border: 0 !important;
    border-radius: 0 !important;
}

/* Match Details */
.match-details {
display: flex !important
;
    justify-content: space-between !important;
    gap: 1rem !important;
    padding-top: 1rem;
    border-top: 1px solid #61ad6785;
    margin: 0 !important;
}

.detail-item {
display: flex
;
    align-items: center;
    gap: 0.5rem;
    color: var(--text-muted);
    font-size: 0.75rem;
    padding: 0 !important;
    background: #ff000000 !important;
    border: 0 !important;
}

/* Match Actions */
.match-actions {
    display: flex;
    gap: 0.75rem;
    margin-top: 1rem;
    opacity: 0;
    transform: translateY(10px);
    transition: all var(--transition-normal);
}

.match-actions.visible {
    opacity: 1;
    transform: translateY(0);
}

.match-card.live .match-actions {
    opacity: 1;
    transform: translateY(0);
}

.action-btn {
    flex: 1;
    padding: 0.75rem 1rem;
    border: none;
    border-radius: var(--radius-md);
    font-weight: 500;
    font-size: 0.875rem;
    cursor: pointer;
    transition: all var(--transition-fast);
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 0.5rem;
}

.action-btn.primary {
    background: linear-gradient(135deg, #61ad67 0%, #073c21);
    color: white;
}

.action-btn.primary:hover {
    background: #151f16 !important;
    transform: translateY(-1px);
}

.action-btn.secondary {
    background: #253528;
    color: white;
    border: 1px solid var(--border-color);
}

.action-btn.secondary:hover {
    background: #0b1f0f;
    color: var(--text-primary);
    border-color: var(--accent-color);
}

/* No Matches State */
.no-matches {
    text-align: center;
    padding: 4rem 2rem;
    color: var(--text-muted);
}

.no-matches p {
    font-size: 1.125rem;
}

/* Icons */
.icon {
    width: 14px;
    height: 14px;
    display: inline-block;
    vertical-align: middle;
    display: flex;
}

.icon-calendar::before {
    content: "📅";
}

.icon-location::before {
    content: "📍";
}

.icon-users::before {
    content: "👥";
}

.icon-star::before {
    content: "💚";
}

.icon-stats::before {
    content: "📊";
}

/* Loading Spinner */
.loading {
    text-align: center;
    padding: 4rem 2rem;
    color: var(--text-muted);
}

.loading-spinner {
    width: 40px;
    height: 40px;
    border: 3px solid var(--border-color);
    border-top: 3px solid var(--accent-color);
    border-radius: 50%;
    animation: spin 1s linear infinite;
    margin: 0 auto 1rem;
}

@keyframes spin {
    0% { transform: rotate(0deg); }
    100% { transform: rotate(360deg); }
}

/* Responsive Design */
@media (max-width: 768px) {
    .app-title {
        font-size: 1.75rem;
    }
    
    .filters-container {
        flex-direction: column;
        align-items: stretch;
        gap: 0.75rem;
        padding: 1rem 1.5rem;
    }
    
    .filter-tabs {
        justify-content: center;
        overflow-x: auto;
        scrollbar-width: none;
        -ms-overflow-style: none;
        gap: 0.25rem;
        padding: 0.125rem;
    }
    
    .filter-tabs::-webkit-scrollbar {
        display: none;
    }
    
    .filter-tab {
        padding: 0.5rem 1rem;
        font-size: 0.875rem;
    }
    
    .search-input {
        width: 100%;
        font-size: 0.875rem;
        padding: 0.5rem 0.75rem !important;
    }
    
    .matches-grid {
        grid-template-columns: 1fr;
        gap: 1rem;
        padding: 0 1rem;
    }
    
    .matches-container {
        padding: 1rem 1rem;
    }
    
    .match-card {
        padding: 1rem;
        border-radius: var(--radius-md);
    }
    
    .teams-container {
        gap: 0.5rem;
        grid-template-columns: 1fr auto 1fr;
    }
    
    .team-name {
        font-size: 0.875rem;
    }
    
    .team-short {
        font-size: 0.6875rem;
    }
    
    .score-display {
        font-size: 1.25rem;
    }
    
    .match-time {
        font-size: 0.875rem;
    }
    
    .match-details {
        flex-direction: row;
        gap: 0.5rem;
        font-size: 0.6875rem;
    }
    
    .detail-item {
        gap: 0.25rem;
    }
    
    .action-btn {
        padding: 0.5rem 0.75rem;
        font-size: 0.75rem;
    }
    
    .date-slider-container {
        padding: 1rem 2rem;
    }
    
    .date-item {
        min-width: 60px;
        padding: 0.5rem 0.75rem;
    }
    
    .date-number {
        font-size: 1rem;
    }
    
    .date-day, .date-month {
        font-size: 0.625rem;
    }
}

@media (max-width: 480px) {
    .app-header {
        padding: 1.5rem 1rem 1rem;
    }
    
    .app-title {
        font-size: 1.5rem;
    }
    
    .filters-container {
        padding: 0.75rem 1rem;
        gap: 0.5rem;
    }
    
    .filter-tab {
        padding: 0.375rem 0.75rem;
        font-size: 0.75rem;
    }
    
    .search-input {
        padding: 0.375rem 0.5rem !important;
        font-size: 0.75rem;
    }
    
    .matches-container {
        padding: 0.75rem 0.5rem;
    }
    
    .match-card {
        padding: 0.75rem;
    }
    
    .teams-container {
        grid-template-columns: 1fr auto 1fr;
        gap: 0.25rem;
    }
    
    .team-logo {
        width: 36px;
        height: 36px;
        font-size: 1.25rem;
    }
    
    .team-name {
        font-size: 0.8125rem;
    }
    
    .score-display {
        font-size: 1.125rem;
        gap: 0.25rem;
    }
    
    .match-details {
        flex-direction: column;
        gap: 0.25rem;
        font-size: 0.625rem;
    }
    
    .action-btn {
        padding: 0.375rem 0.5rem;
        font-size: 0.6875rem;
        gap: 0.25rem;
    }
    
    .date-slider-container {
        padding: 0.75rem 1.5rem;
    }
    
    .date-arrow-next,
    .date-arrow-prev {
        width: 32px;
        height: 32px;
    }
    
    .date-arrow-next::after,
    .date-arrow-prev::after {
        font-size: 14px;
    }
    
    .date-item {
        min-width: 50px;
        padding: 0.375rem 0.5rem;
    }
    
    .date-number {
        font-size: 0.875rem;
    }
    
    .date-day, .date-month {
        font-size: 0.5625rem;
    }
}

/* Accessibility Improvements */
@media (prefers-reduced-motion: reduce) {
    * {
        animation-duration: 0.01ms !important;
        animation-iteration-count: 1 !important;
        transition-duration: 0.01ms !important;
    }
}

/* Focus Styles */
.filter-tab:focus,
.search-input:focus,
.favorite-btn:focus,
.action-btn:focus {
    outline: 2px solid var(--accent-color);
    outline-offset: 2px;
}