/* Modern Matches Table - VS Layout */
@import url('https://fonts.googleapis.com/css2?family=Cairo:wght@400;600;700;800&display=swap');

#modern-matches-root {
    font-family: 'Cairo', sans-serif;
    background: transparent;
    direction: rtl;
    margin-bottom: 30px;
}

/* Header & Controls */
.mph-header {
    background: #fff;
    padding: 12px 20px;
    border-radius: 8px;
    /* Slightly squarer */
    border-bottom: 2px solid #ddd;
    display: flex;
    justify-content: space-between;
    align-items: center;
    gap: 15px;
    margin-bottom: 20px;
}

.mph-title {
    font-size: 16px;
    font-weight: 700;
    color: #222;
}

.mph-controls {
    display: flex;
    gap: 10px;
}

#mph-timezone-selector {
    padding: 5px 10px;
    border: 1px solid #ddd;
    border-radius: 4px;
    font-family: inherit;
    font-size: 12px;
}

#mph-date-nav {
    display: flex;
    background: #eee;
    border-radius: 4px;
    padding: 2px;
}

#mph-date-nav button {
    border: none;
    background: transparent;
    padding: 4px 12px;
    font-family: inherit;
    font-size: 12px;
    cursor: pointer;
    border-radius: 3px;
    font-weight: 600;
    color: #666;
}

#mph-date-nav button.active {
    background: #fff;
    color: #222;
    box-shadow: 0 1px 3px rgba(0, 0, 0, 0.1);
}

/* Championship Header */
.mph-group-header {
    background: #333;
    color: #ffd700;
    /* Gold accent like image? */
    padding: 8px 15px;
    font-size: 13px;
    font-weight: 700;
    margin-bottom: 1px;
    border-radius: 6px 6px 0 0;
}

/* Match Card Container */
.mph-match-card {
    background: #fff;
    margin-bottom: 10px;
    box-shadow: 0 2px 5px rgba(0, 0, 0, 0.05);
    border-radius: 0 0 6px 6px;
    /* Rounded bottom */
    overflow: hidden;
    position: relative;
    /* Gradient Background Effect */
    background: linear-gradient(90deg, #f9f9f9 0%, #fff 50%, #f9f9f9 100%);
    transition: all 0.2s ease-in-out;
}

.mph-match-card:hover {
    background: #f0f4f8;
    /* Gentle blue-gray shading on hover */
    transform: translateY(-2px);
    /* Subtle lift */
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.08);
    /* Stronger shadow */
}

.mph-match-link {
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: 15px 10px;
    /* Reduced side padding */
    text-decoration: none !important;
    color: inherit;
    position: relative;
}

/* Teams */
.mph-team {
    flex: 1;
    display: flex;
    align-items: center;
    gap: 10px;
    width: 30%;
    position: relative;
    z-index: 2;
}

.team-right {
    justify-content: flex-start;
    padding-right: 10px;
}

/* Right Team (Home) */
.team-left {
    justify-content: flex-end;
    padding-left: 10px;
}

/* Left Team (Away) */

.team-logo img {
    width: 45px;
    height: 45px;
    object-fit: contain;
    filter: drop-shadow(0 4px 4px rgba(0, 0, 0, 0.1));
}

.team-name {
    font-size: 15px;
    font-weight: 700;
    color: #222;
}

/* Center Info Column */
.mph-center-info {
    flex: 0 0 200px;
    /* Increased width for details */
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    position: relative;
    z-index: 2;
    min-width: 0;
    /* Allow shrinking if needed */
}

/* Top: Time / Status */
.mph-time-top {
    font-size: 13px;
    color: #fff;
    /* White text for contrast */
    font-weight: 700;
    margin-bottom: 6px;
    background: #333;
    /* Default gray for Time */
    padding: 3px 12px;
    border-radius: 12px;
    display: inline-block;
    min-width: 80px;
    text-align: center;
}

/* Status Colors injected by JS logic context */
/* We rely on text content for simple CSS or parent class. 
   Since JS just puts text, let's make the default neutral/dark.
   If user wants Red for Live, we might need a class update in JS. 
   But "Time Slot" is shared.   Let's keep it Neutral Dark for now, 
   except maybe for specific words if we can selector them (CSS :has not widely supported enough). 
   Let's update JS to add a class to the center-info or time-box.
*/
.mph-time-top.live {
    background: #e74c3c;
    /* Red for Live */
    animation: flash 1.5s infinite;
}

.mph-time-top.ended {
    background: #2c3e50;
    /* Dark Blue/Gray for Ended */
}

.mph-time-top.vs-badge {
    background: #0073aa;
    /* WordPress Blue for Upcoming Time */
}

/* Mid: Score - VS - Score */
.mph-score-row {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 10px;
    width: 100%;
}

.score-num {
    font-size: 24px;
    font-weight: 800;
    color: #000;
    min-width: 25px;
    text-align: center;
}

.status-badge {
    font-size: 16px;
    /* VS Size */
    font-weight: 900;
    color: #ddd;
    /* VS Color */
    text-transform: uppercase;
}

.status-badge.vs-badge {
    font-family: 'Arial', sans-serif;
    letter-spacing: 1px;
    color: #bbb;
    font-style: italic;
    font-size: 22px;
}

.status-badge.live {
    font-size: 12px;
    background: #e74c3c;
    color: #fff;
    padding: 3px 8px;
    border-radius: 4px;
    animation: flash 1.5s infinite;
}

.status-badge.ended {
    font-size: 12px;
    background: #555;
    color: #fff;
    padding: 3px 8px;
    border-radius: 4px;
}

/* Bot: Details */
.mph-details-bot {
    display: flex;
    gap: 15px;
    margin-top: 6px;
    font-size: 11px;
    color: #666;
    width: 100%;
    justify-content: center;
    white-space: nowrap;
    /* Prevent wrapping */
    overflow: hidden;
    text-overflow: ellipsis;
}

.detail-icon {
    display: inline-flex;
    align-items: center;
    gap: 5px;
    max-width: 90px;
    overflow: hidden;
    text-overflow: ellipsis;
}

.detail-icon i {
    color: #888;
}

/* Animations */
@keyframes flash {
    0% {
        opacity: 1;
    }

    50% {
        opacity: 0.5;
    }

    100% {
        opacity: 1;
    }
}

/* Responsive */
@media (max-width: 600px) {
    .mph-match-link {
        padding: 10px 5px;
    }

    .team-logo img {
        width: 32px;
        height: 32px;
    }

    .team-name {
        font-size: 12px;
        display: none;
    }

    /* Hide names on very small screens? Or stack? Let's keep names but smaller */
    .team-name {
        display: block;
        font-size: 11px;
    }

    .mph-center-info {
        flex: 0 0 110px;
    }

    .score-num {
        font-size: 18px;
    }

    .status-badge.vs-badge {
        font-size: 16px;
    }

    .mph-details-bot {
        flex-direction: column;
        gap: 2px;
        align-items: center;
    }
}