/*
 * ============================================================
 *  Goualuto Public Stylesheet — Premium Match Widget v2
 *  Light Mode · Responsive LTR/RTL support · Date Picker
 * ============================================================
 */

/* 1. TYPOGRAPHY RESET FOR ALL PUBLIC WIDGETS */
.goualuto-public-matches-wrap,
.goualuto-public-matches-wrap *,
.goualuto-stats-widget-wrap,
.goualuto-stats-widget-wrap *,
.goualuto-pub-match-stream-wrapper,
.goualuto-pub-match-stream-wrapper *,
.goualuto-leagues-widget-wrap,
.goualuto-leagues-widget-wrap *,
.goualuto-timezone-wrap,
.goualuto-timezone-wrap *,
.goualuto-archive-stats-wrapper,
.goualuto-archive-stats-wrapper * {
    font-family: 'Changa', sans-serif !important;
}

/* Base Styles & Variables */
.goualuto-public-matches-wrap {
    --gp-primary: #059669;
    /* Emerald Dark */
    --gp-primary-hover: #10b981;
    /* Emerald Mid */
    --gp-primary-light: #ecfdf5;
    /* Emerald Light */
    --gp-dark: #0f172a;
    /* Slate Dark */
    --gp-text-main: #334155;
    /* Slate Gray */
    --gp-text-muted: #64748b;
    --gp-text-light: #94a3b8;
    --gp-border: #e2e8f0;
    --gp-border-light: #f1f5f9;
    --gp-bg-card: #ffffff;
    --gp-bg-subtle: #f8fafc;
    --gp-live: #ef4444;
    /* Red Live */

    --gp-shadow-sm: 0 2px 8px rgba(15, 23, 42, 0.04);
    --gp-shadow-md: 0 4px 16px rgba(15, 23, 42, 0.08);
    --gp-shadow-glow: 0 4px 12px rgba(5, 150, 105, 0.15);
    --gp-radius: 14px;
    --gp-radius-sm: 8px;

    width: 100%;
    margin: 20px 0;
    box-sizing: border-box;
    position: relative;
    container-type: inline-size;
    container-name: matches-widget;
}

.goualuto-public-matches-wrap *,
.goualuto-public-matches-wrap *::before,
.goualuto-public-matches-wrap *::after {
    box-sizing: border-box;
}

/* RTL / LTR Alignments */
.goualuto-pub-rtl {
    direction: rtl;
    text-align: right;
}

.goualuto-pub-ltr {
    direction: ltr;
    text-align: left;
}

/* Loading Overlay */
.pub-matches-container {
    position: relative;
    min-height: 150px;
}

.pub-loading-overlay {
    position: absolute;
    inset: 0;
    background: rgba(255, 255, 255, 0.6);
    backdrop-filter: blur(2px);
    z-index: 10;
    display: flex;
    align-items: center;
    justify-content: center;
    border-radius: var(--gp-radius);
}

.pub-loading-overlay .dashicons {
    font-size: 32px;
    width: 32px;
    height: 32px;
    color: var(--gp-primary);
}

/* 2. DATE PICKER NAV (Ultra Premium Single-Line Layout) */
.pub-date-picker-nav {
    display: flex;
    justify-content: space-between;
    gap: 6px;
    width: 100%;
    margin-bottom: 20px;
    padding: 0;
    position: relative;
    z-index: 1100;
    /* Ensure dropdown displays ON TOP of matches table */
}

.pub-date-tab {
    flex: 1;
    min-width: 0;
    /* Allows shrinking below content size */
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    padding: 8px 4px;
    background: var(--gp-bg-card);
    border: 1px solid var(--gp-border);
    border-radius: 10px;
    cursor: pointer;
    transition: all 0.2s cubic-bezier(0.4, 0, 0.2, 1);
    box-shadow: 0 2px 4px rgba(15, 23, 42, 0.02);
    text-decoration: none;
    outline: none;
    -webkit-appearance: none;
    appearance: none;
    position: relative;
}

.pub-date-tab:hover {
    background: var(--gp-bg-subtle);
    border-color: #cbd5e1;
    transform: translateY(-2px);
    box-shadow: 0 4px 8px rgba(15, 23, 42, 0.04);
}

.pub-date-tab.active {
    background: var(--gp-primary);
    border-color: var(--gp-primary);
    box-shadow: 0 4px 10px rgba(5, 150, 105, 0.15);
    transform: translateY(-2px);
}

.pub-date-dayname {
    font-size: 10.5px;
    font-weight: 800;
    color: var(--gp-text-muted);
    text-transform: uppercase;
    transition: color 0.2s ease;
    letter-spacing: 0.3px;
    text-align: center;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
    width: 100%;
}

.pub-date-full {
    font-size: 13.5px;
    font-weight: 800;
    color: var(--gp-dark);
    margin-top: 3px;
    transition: color 0.2s ease;
    white-space: nowrap;
    text-align: center;
    overflow: hidden;
    text-overflow: ellipsis;
    width: 100%;
}

.pub-date-tab.active .pub-date-dayname {
    color: rgba(255, 255, 255, 0.85) !important;
}

.pub-date-tab.active .pub-date-full {
    color: #ffffff !important;
}

/* Custom Date Picker Overlay Style */
.pub-custom-date-tab {
    flex: 0 0 48px;
    /* Fixed narrower width for calendar icon only */
    position: relative;
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 0;
}

.pub-custom-date-icon-wrap {
    display: flex;
    align-items: center;
    justify-content: center;
    width: 100%;
    height: 100%;
}

.pub-calendar-svg {
    width: 22px;
    height: 22px;
    color: var(--gp-text-muted);
    transition: color 0.2s ease, transform 0.2s ease;
}

.pub-custom-date-tab:hover .pub-calendar-svg {
    color: var(--gp-primary);
    transform: scale(1.1);
}

.pub-custom-date-tab.active {
    background: var(--gp-primary);
    border-color: var(--gp-primary);
    box-shadow: 0 4px 10px rgba(5, 150, 105, 0.15);
}

.pub-custom-date-tab.active .pub-calendar-svg {
    color: #ffffff !important;
}

/* Custom Calendar Dropdown Popup */
.pub-custom-calendar-dropdown {
    position: absolute;
    top: calc(100% + 8px);
    right: 0;
    z-index: 1000;
    width: 280px;
    background: #ffffff;
    border: 1px solid var(--gp-border);
    border-radius: 12px;
    box-shadow: 0 10px 25px -5px rgba(15, 23, 42, 0.1), 0 8px 10px -6px rgba(15, 23, 42, 0.05);
    padding: 16px;
    cursor: default;
}

.goualuto-pub-rtl .pub-custom-calendar-dropdown {
    right: 0;
    left: auto;
}

.goualuto-pub-ltr .pub-custom-calendar-dropdown {
    left: 0;
    right: auto;
}

.cal-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 12px;
}

.cal-month-year {
    font-size: 13.5px;
    font-weight: 800;
    color: var(--gp-dark);
}

.cal-prev-month,
.cal-next-month {
    background: var(--gp-bg-subtle) !important;
    border: 1px solid var(--gp-border) !important;
    border-radius: 6px !important;
    width: 26px !important;
    height: 26px !important;
    display: inline-flex !important;
    align-items: center !important;
    justify-content: center !important;
    font-size: 16px !important;
    color: var(--gp-text-main) !important;
    cursor: pointer !important;
    padding: 0 !important;
    margin: 0 !important;
    transition: all 0.2s ease !important;
    box-shadow: none !important;
    line-height: 1 !important;
}

.cal-prev-month:hover,
.cal-next-month:hover {
    background: var(--gp-primary-light) !important;
    border-color: var(--gp-primary) !important;
    color: var(--gp-primary) !important;
}

.cal-weekdays {
    display: grid;
    grid-template-columns: repeat(7, 1fr);
    margin-bottom: 8px;
    text-align: center;
}

.cal-weekdays span {
    font-size: 10px;
    font-weight: 800;
    color: var(--gp-text-light);
    text-transform: uppercase;
}

.cal-days-grid {
    display: grid;
    grid-template-columns: repeat(7, 1fr);
    gap: 4px;
    text-align: center;
}

.cal-day-cell {
    font-size: 12px;
    font-weight: 700;
    color: var(--gp-text-main);
    height: 30px;
    display: flex;
    align-items: center;
    justify-content: center;
    border-radius: 6px;
    cursor: pointer;
    transition: all 0.2s ease;
}

.cal-day-cell:hover {
    background: var(--gp-bg-subtle);
    color: var(--gp-dark);
}

.cal-day-cell.cal-active {
    background: var(--gp-primary) !important;
    color: #ffffff !important;
    box-shadow: 0 4px 8px rgba(5, 150, 105, 0.2);
}

.cal-empty {
    height: 30px;
}

/* Responsive Mobile View Adjustment */
@media (max-width: 640px) {
    .pub-date-picker-nav {
        gap: 4px;
        margin-bottom: 14px;
    }

    .pub-date-tab {
        padding: 6px 2px;
        border-radius: 6px;
    }

    .pub-custom-date-tab {
        flex: 0 0 38px;
        /* Even narrower on mobile */
    }

    .pub-calendar-svg {
        width: 18px;
        height: 18px;
    }

    .pub-date-dayname {
        font-size: 9px;
        letter-spacing: 0;
    }

    .pub-date-full {
        font-size: 10.5px;
        margin-top: 1px;
    }

    .pub-custom-calendar-dropdown {
        width: 250px;
        padding: 10px;
    }

    .cal-day-cell {
        height: 26px;
        font-size: 11px;
    }

    .cal-empty {
        height: 26px;
    }
}

/* 3. CARD WRAPPER */
.goualuto-pub-card {
    background: var(--gp-bg-card);
    border: 1px solid var(--gp-border);
    border-radius: var(--gp-radius);
    box-shadow: var(--gp-shadow-sm);
    margin-bottom: 20px;
    overflow: hidden;
    transition: transform 0.25s ease, box-shadow 0.25s ease;
}

.goualuto-pub-card:last-child {
    margin-bottom: 0;
}

.goualuto-pub-card:hover {
    box-shadow: var(--gp-shadow-md);
    border-color: #cbd5e1;
}

/* 4. LEAGUE HEADER */
.league-group-header {
    display: flex;
    align-items: center;
    gap: 12px;
    padding: 16px 20px;
    background: var(--gp-bg-subtle);
    border-bottom: 1px solid var(--gp-border);
}

.league-trophy-icon {
    font-size: 20px;
    line-height: 1;
    filter: drop-shadow(0 2px 4px rgba(0, 0, 0, 0.1));
}

.league-info {
    display: flex;
    flex-direction: column;
    gap: 1px;
}

.league-name {
    font-size: 14.5px;
    font-weight: 800;
    color: var(--gp-dark);
    line-height: 1.2;
}

.league-country {
    font-size: 11px;
    font-weight: 600;
    color: var(--gp-text-light);
    margin-inline-start: 4px;
}

/* 5. MATCH STAGE HEADER */
.pub-match-stage-subheader {
    background: var(--gp-primary-light);
    border-bottom: 1px solid var(--gp-border-light);
    padding: 7px 20px;
    text-align: start;
}

.goualuto-pub-rtl .pub-match-stage-subheader {
    text-align: right;
}

.pub-match-stage-subheader h4 {
    margin: 0 !important;
    font-size: 12px !important;
    font-weight: 700 !important;
    color: var(--gp-primary) !important;
    display: inline-flex;
    align-items: center;
    gap: 5px;
}

.pub-match-stage-subheader h4::before {
    content: '▸';
    color: var(--gp-primary);
    font-size: 11px;
}

/* 6. MATCH ITEMS ROW */
.league-matches-body {
    display: flex;
    flex-direction: column;
}

.match-row-item {
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: 14px 20px;
    border-bottom: 1px solid var(--gp-border-light);
    transition: background 0.2s ease;
}

.match-row-item:last-child {
    border-bottom: none;
}

.match-row-item:hover {
    background: var(--gp-bg-subtle);
}

.pub-team {
    display: flex;
    align-items: center;
    width: 38%;
    gap: 12px;
}

.pub-team.home-side {
    justify-content: flex-end;
    text-align: right;
}

.pub-team.away-side {
    justify-content: flex-start;
    text-align: left;
}

.pub-team-badge {
    width: 28px;
    height: 28px;
    max-width: 6vw;
    max-height: 6vw;
    object-fit: contain;
    flex-shrink: 0;
    transition: transform 0.2s ease;
}

.match-row-item:hover .pub-team-badge {
    transform: scale(1.1);
}

.pub-team-name {
    font-size: 14px;
    font-weight: 700;
    color: var(--gp-dark);
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
}

/* Match Center */
.pub-center-info {
    width: 24%;
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    gap: 4px;
    text-align: center;
    flex-shrink: 0;
}

.pub-match-time {
    font-size: 15px;
    font-weight: 800;
    color: var(--gp-dark);
    line-height: 1.1;
    letter-spacing: 0.3px;
    background: var(--gp-bg-subtle);
    padding: 3px 12px;
    border-radius: 6px;
    border: 1px solid var(--gp-border);
}

.pub-score-display {
    display: inline-flex;
    align-items: center;
    gap: 8px;
    font-size: 19px;
    font-weight: 800;
    color: var(--gp-dark);
    line-height: 1;
    background: var(--gp-bg-subtle);
    padding: 4px 16px;
    border-radius: 8px;
    border: 1px solid var(--gp-border-light);
    box-shadow: inset 0 1px 3px rgba(0, 0, 0, 0.02);
}

.pub-score-display.is-live-score {
    color: #ffffff;
    background: var(--gp-live);
    border-color: var(--gp-live);
    box-shadow: 0 2px 8px rgba(239, 68, 68, 0.25);
}

.score-val {
    min-width: 14px;
    text-align: center;
}

.score-divider {
    opacity: 0.5;
    font-size: 14px;
}

.pub-penalty-display {
    font-size: 10px;
    font-weight: 800;
    color: var(--gp-text-muted);
    margin-top: 5px;
    background: var(--gp-border-light);
    padding: 2px 8px;
    border-radius: 6px;
    display: inline-block;
    border: 1px solid var(--gp-border);
}

.pub-not-started-tag,
.pub-finished-tag {
    font-size: 10px;
    font-weight: 700;
    text-transform: uppercase;
    padding: 2px 8px;
    border-radius: 12px;
}

.pub-not-started-tag {
    background: var(--gp-bg-subtle);
    color: var(--gp-text-light);
}

.pub-finished-tag {
    background: var(--gp-border);
    color: var(--gp-text-main);
}

/* Live Indicator */
.pub-live-indicator {
    display: inline-flex;
    align-items: center;
    gap: 5px;
}

.live-dot {
    width: 6px;
    height: 6px;
    background-color: var(--gp-live);
    border-radius: 50%;
    display: inline-block;
    animation: pub-pulse-dot 1.2s infinite;
}

.live-text {
    font-size: 10.5px;
    font-weight: 700;
    color: var(--gp-live);
}

@keyframes pub-pulse-dot {
    0% {
        transform: scale(0.9);
        opacity: 1;
    }

    50% {
        transform: scale(1.4);
        opacity: 0.5;
    }

    100% {
        transform: scale(0.9);
        opacity: 1;
    }
}

/* 7. NO MATCHES STATE */
.no-matches-card {
    border-style: dashed;
    border-color: var(--gp-border);
    background: var(--gp-bg-subtle);
}

.no-matches-body {
    text-align: center;
    padding: 48px 20px;
}

.pub-empty-icon {
    font-size: 40px;
    display: block;
    margin-bottom: 12px;
    opacity: 0.3;
}

.no-matches-body p {
    font-size: 14px;
    font-weight: 700;
    color: var(--gp-text-muted);
    margin: 0;
}

/* 8. RESPONSIVENESS */
@media (max-width: 768px) {
    .match-row-item {
        padding: 14px 10px;
        flex-wrap: nowrap;
        gap: 0;
        justify-content: space-between;
        align-items: center;
    }

    .pub-team {
        width: 35%;
        flex-direction: column;
        align-items: center;
        text-align: center;
        gap: 6px;
        margin-top: 0;
    }

    .pub-team.home-side {
        flex-direction: column-reverse;
        /* Badge on top, name on bottom */
        justify-content: center;
    }

    .pub-team.away-side {
        flex-direction: column;
        /* Badge on top, name on bottom */
        justify-content: center;
    }

    .pub-team-name {
        font-size: 11px;
        max-width: 100%;
        text-align: center;
        white-space: normal;
        word-break: break-word;
        line-height: 1.2;
    }

    .pub-team-badge {
        width: 28px;
        height: 28px;
        max-width: 8vw;
        max-height: 8vw;
    }

    .pub-center-info {
        width: 30%;
        order: 0;
        flex-direction: column;
        align-items: center;
        justify-content: center;
        gap: 4px;
        padding-bottom: 0;
        border-bottom: none;
    }

    .pub-score-display {
        font-size: 14.5px;
        padding: 3px 10px;
        border-radius: 6px;
    }

    .pub-match-time {
        font-size: 12px;
        padding: 2px 8px;
    }

    .pub-penalty-display {
        font-size: 8.5px;
        padding: 1px 5px;
        margin-top: 2px;
    }
}

/* Container Queries for Sidebar Widgets & Custom Layout Columns */
@container matches-widget (max-width: 600px) {
    .match-row-item {
        padding: 14px 10px;
        flex-wrap: nowrap;
        gap: 0;
        justify-content: space-between;
        align-items: center;
    }

    .pub-team {
        width: 35%;
        flex-direction: column;
        align-items: center;
        text-align: center;
        gap: 6px;
        margin-top: 0;
    }

    .pub-team.home-side {
        flex-direction: column-reverse;
        justify-content: center;
    }

    .pub-team.away-side {
        flex-direction: column;
        justify-content: center;
    }

    .pub-team-name {
        font-size: 11px;
        max-width: 100%;
        text-align: center;
        white-space: normal;
        word-break: break-word;
        line-height: 1.2;
    }

    .pub-team-badge {
        width: 28px;
        height: 28px;
        max-width: 8vw;
        max-height: 8vw;
    }

    .pub-center-info {
        width: 30%;
        order: 0;
        flex-direction: column;
        align-items: center;
        justify-content: center;
        gap: 4px;
        padding-bottom: 0;
        border-bottom: none;
    }

    .pub-score-display {
        font-size: 14.5px;
        padding: 3px 10px;
        border-radius: 6px;
    }

    .pub-match-time {
        font-size: 12px;
        padding: 2px 8px;
    }

    .pub-penalty-display {
        font-size: 8.5px;
        padding: 1px 5px;
        margin-top: 2px;
    }
}

@container matches-widget (max-width: 480px) {
    .pub-date-picker-nav {
        gap: 4px;
        margin-bottom: 14px;
    }

    .pub-date-tab {
        padding: 8px 2px;
        border-radius: 8px;
    }

    /* Responsive Date Tabs Logic */
    .pub-date-tab.is-regular-day .pub-date-dayname {
        display: none !important;
    }

    .pub-date-tab.is-regular-day .pub-date-monthname {
        display: none !important;
    }

    .pub-date-tab.is-regular-day .pub-date-daynum {
        display: block !important;
        font-size: 14px !important;
        font-weight: 800 !important;
        line-height: 1;
    }

    .pub-date-tab.is-special-day .pub-date-dayname {
        display: block !important;
        font-size: 12px !important;
        font-weight: 800 !important;
        line-height: 1.2;
        text-align: center;
        width: 100%;
    }

    .pub-date-tab.is-special-day .pub-date-daynum {
        display: none !important;
    }

    .pub-date-tab.is-special-day .pub-date-monthname {
        display: none !important;
    }

    .pub-custom-date-tab {
        flex: 0 0 38px;
    }

    .pub-calendar-svg {
        width: 18px;
        height: 18px;
    }

    .pub-custom-calendar-dropdown {
        width: 230px;
        padding: 8px;
    }

    .cal-day-cell {
        height: 24px;
        font-size: 10.5px;
    }

    .cal-empty {
        height: 24px;
    }
}

/* 9. TIMEZONE, STREAMS, LEAGUES (Legacy additions from previous) */
/* 9. TIMEZONE SWITCHER - PREMIUM DIGITAL CLOCK & DROPDOWN */
.goualuto-timezone-switcher-wrap {
    width: 100%;
    margin-bottom: 20px;
    display: flex;
    justify-content: flex-start;
    font-family: 'Changa', sans-serif !important;
}
.goualuto-timezone-switcher-wrap.goualuto-pub-rtl {
    justify-content: flex-start;
}
.goualuto-timezone-switcher-wrap.goualuto-pub-ltr {
    justify-content: flex-end;
}

.goualuto-timezone-custom-widget {
    position: relative;
    display: inline-block;
    font-family: 'Changa', sans-serif !important;
}

/* Header Trigger Button */
.goualuto-tz-trigger {
    display: inline-flex;
    align-items: center;
    gap: 12px;
    background: #ffffff !important;
    border: 1px solid var(--gp-border) !important;
    border-radius: 12px !important;
    padding: 6px 14px !important;
    cursor: pointer !important;
    box-shadow: var(--gp-shadow-sm) !important;
    transition: all 0.25s ease !important;
    outline: none !important;
    user-select: none;
    -webkit-tap-highlight-color: transparent;
}
.goualuto-tz-trigger:hover {
    border-color: var(--gp-primary) !important;
    box-shadow: 0 0 10px rgba(16, 185, 129, 0.12) !important;
}
.goualuto-tz-trigger.active {
    border-color: var(--gp-primary) !important;
    box-shadow: 0 0 12px rgba(16, 185, 129, 0.2) !important;
    background: var(--gp-primary-light) !important;
}

/* Clock Icon and Rotation Animation */
.goualuto-tz-clock-icon-wrap {
    display: flex;
    align-items: center;
    justify-content: center;
    color: var(--gp-primary) !important;
}
.goualuto-tz-clock-svg {
    width: 22px;
    height: 22px;
    transition: transform 0.4s cubic-bezier(0.175, 0.885, 0.32, 1.275);
}
.goualuto-tz-trigger:hover .goualuto-tz-clock-svg {
    transform: rotate(15deg);
}
.goualuto-tz-trigger.active .goualuto-tz-clock-svg {
    color: var(--gp-primary-hover) !important;
}

/* Time display info text */
.goualuto-tz-display-info {
    display: flex;
    flex-direction: column;
    align-items: flex-start;
    line-height: 1.1 !important;
}
.goualuto-pub-rtl .goualuto-tz-display-info {
    align-items: flex-start;
}
.goualuto-pub-ltr .goualuto-tz-display-info {
    align-items: flex-end;
}

.goualuto-tz-time-digits {
    font-size: 16px !important;
    font-weight: 800 !important;
    color: var(--gp-dark) !important;
    letter-spacing: 0.5px !important;
    font-variant-numeric: tabular-nums;
}
.goualuto-tz-selected-label {
    font-size: 10.5px !important;
    font-weight: 600 !important;
    color: var(--gp-text-muted) !important;
    margin-top: 2px !important;
}

/* Chevron */
.goualuto-tz-chevron {
    display: flex;
    align-items: center;
    justify-content: center;
    color: var(--gp-text-light);
}
.chevron-icon {
    width: 14px;
    height: 14px;
    transition: transform 0.22s ease;
}
.goualuto-tz-trigger.active .chevron-icon {
    transform: rotate(180deg);
    color: var(--gp-primary);
}

/* Custom Dropdown List */
.goualuto-tz-dropdown-list {
    position: absolute;
    top: 100%;
    z-index: 9999;
    margin-top: 8px;
    width: 260px;
    background: #ffffff !important;
    border: 1px solid var(--gp-border) !important;
    border-radius: 12px !important;
    box-shadow: 0 10px 25px -5px rgba(15, 23, 42, 0.12), 0 8px 10px -6px rgba(15, 23, 42, 0.08) !important;
    padding: 6px !important;
    box-sizing: border-box !important;
}
.goualuto-pub-rtl .goualuto-tz-dropdown-list {
    right: 0;
    left: auto;
}
.goualuto-pub-ltr .goualuto-tz-dropdown-list {
    left: 0;
    right: auto;
}

.goualuto-tz-dropdown-scroll {
    max-height: 250px;
    overflow-y: auto;
    scrollbar-width: thin;
    scrollbar-color: var(--gp-border) transparent;
}
.goualuto-tz-dropdown-scroll::-webkit-scrollbar {
    width: 5px;
}
.goualuto-tz-dropdown-scroll::-webkit-scrollbar-thumb {
    background: var(--gp-border);
    border-radius: 10px;
}

/* Individual Dropdown Item */
.goualuto-tz-option-item {
    display: flex !important;
    align-items: center !important;
    justify-content: space-between !important;
    padding: 9px 12px !important;
    border-radius: 8px !important;
    cursor: pointer !important;
    transition: all 0.18s ease !important;
    user-select: none;
    outline: none !important;
    margin-bottom: 2px !important;
}
.goualuto-tz-option-item:last-child {
    margin-bottom: 0 !important;
}
.goualuto-tz-option-item:hover {
    background: var(--gp-border-light) !important;
}
.goualuto-tz-option-item.active {
    background: var(--gp-primary-light) !important;
}

/* Bullet indicator inside dropdown */
.gp-tz-option-bullet {
    width: 6px;
    height: 6px;
    border-radius: 50%;
    background: var(--gp-border);
    flex-shrink: 0;
    transition: all 0.2s ease;
}
.goualuto-pub-rtl .gp-tz-option-bullet {
    margin-left: 10px;
}
.goualuto-pub-ltr .gp-tz-option-bullet {
    margin-right: 10px;
}
.goualuto-tz-option-item.active .gp-tz-option-bullet {
    background: var(--gp-primary) !important;
    box-shadow: 0 0 6px var(--gp-primary) !important;
}

.gp-tz-option-name {
    font-size: 13px !important;
    font-weight: 700 !important;
    color: var(--gp-dark) !important;
    flex-grow: 1;
    text-align: right;
}
.goualuto-pub-ltr .gp-tz-option-name {
    text-align: left;
}
.goualuto-tz-option-item.active .gp-tz-option-name {
    color: var(--gp-primary) !important;
}

.gp-tz-option-time {
    font-size: 11.5px !important;
    font-weight: 700 !important;
    color: var(--gp-text-muted) !important;
    background: var(--gp-bg-subtle) !important;
    padding: 2px 7px !important;
    border-radius: 4px !important;
    font-variant-numeric: tabular-nums;
}
.goualuto-tz-option-item.active .gp-tz-option-time {
    color: var(--gp-primary-hover) !important;
    background: #ffffff !important;
}


.goualuto-pub-match-stream-wrapper {
    border-bottom: 1px solid var(--gp-border-light);
    background: #ffffff;
    transition: all 0.25s ease;
}

.goualuto-pub-match-stream-wrapper:last-child {
    border-bottom: none;
}

.goualuto-pub-match-stream-wrapper.has-active-stream:hover {
    background: #fafbfd;
}

.pub-match-stream-bar {
    padding: 12px 20px;
    background: #f8fafc;
    border-top: 1px dashed var(--gp-border);
    display: flex;
    justify-content: flex-end;
    align-items: center;
}

.pub-match-stream-bar.no-stream {
    background: #fafafc;
    justify-content: center;
}

.no-stream-text {
    font-size: 12px;
    font-weight: 700;
    color: var(--gp-text-muted);
}

.goualuto-pub-stream-toggle-btn {
    display: inline-flex;
    align-items: center;
    gap: 8px;
    background: linear-gradient(135deg, #ef4444 0%, #f43f5e 100%) !important;
    color: #ffffff !important;
    border: none !important;
    border-radius: 50px !important;
    padding: 8px 22px !important;
    font-family: 'Changa', sans-serif !important;
    font-size: 13px !important;
    font-weight: 700 !important;
    cursor: pointer !important;
    box-shadow: 0 4px 14px rgba(239, 68, 68, 0.3) !important;
    transition: all 0.25s cubic-bezier(0.4, 0, 0.2, 1) !important;
}

.goualuto-pub-stream-toggle-btn:hover {
    transform: translateY(-2px);
    box-shadow: 0 8px 20px rgba(239, 68, 68, 0.45) !important;
}

.goualuto-pub-stream-toggle-btn.active {
    background: linear-gradient(135deg, #10b981 0%, #059669 100%) !important;
    box-shadow: 0 4px 14px rgba(16, 185, 129, 0.3) !important;
}

.stream-live-pulse-dot {
    width: 8px;
    height: 8px;
    background-color: #ffffff;
    border-radius: 50%;
    display: inline-block;
    animation: stream-pulse 1.2s infinite;
}

@keyframes stream-pulse {
    0% {
        transform: scale(0.8);
        opacity: 1;
    }

    50% {
        transform: scale(1.4);
        opacity: 0.4;
    }

    100% {
        transform: scale(0.8);
        opacity: 1;
    }
}

.pub-match-stream-drawer {
    padding: 20px;
    background: #fafbfd;
    border-top: 1px solid var(--gp-border-light);
    border-bottom: 1px solid var(--gp-border-light);
}

.pub-stream-servers-grid {
    display: flex;
    flex-wrap: wrap;
    gap: 12px;
    margin-bottom: 20px;
}

.pub-stream-server-btn {
    display: inline-flex;
    align-items: center;
    gap: 8px;
    background: #ffffff !important;
    border: 1.5px solid var(--gp-border) !important;
    border-radius: 12px !important;
    padding: 10px 20px !important;
    font-family: 'Changa', sans-serif !important;
    font-size: 13.5px !important;
    font-weight: 700 !important;
    color: var(--gp-text-main) !important;
    cursor: pointer !important;
    box-shadow: 0 2px 4px rgba(0, 0, 0, 0.02) !important;
    transition: all 0.2s ease !important;
}

.pub-stream-server-btn:hover {
    background: var(--gp-bg-subtle) !important;
    border-color: #cbd5e1 !important;
    color: var(--gp-dark) !important;
}

.pub-stream-server-btn.active {
    background: var(--gp-primary-light) !important;
    border-color: var(--gp-primary) !important;
    color: var(--gp-primary) !important;
    box-shadow: 0 4px 12px rgba(5, 150, 105, 0.15) !important;
}

.pub-stream-player-container {
    background: #0f172a;
    border-radius: 16px;
    padding: 10px;
    box-shadow: 0 15px 35px rgba(15, 23, 42, 0.2);
    border: 1px solid #1e293b;
    overflow: hidden;
}

.pub-player-aspect-wrapper {
    position: relative;
    padding-bottom: 56.25%;
    height: 0;
    overflow: hidden;
    border-radius: 10px;
    background: #000000;
}

.pub-stream-player-iframe {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    border: 0;
}

.pub-player-footer {
    display: flex;
    justify-content: flex-end;
    padding: 12px 10px 4px 10px;
    background: #0f172a;
}

.pub-stream-new-window-link {
    font-size: 13px !important;
    font-weight: 700 !important;
    color: #94a3b8 !important;
    text-decoration: none !important;
    display: inline-flex !important;
    align-items: center !important;
    gap: 6px !important;
    transition: color 0.2s ease !important;
}

.pub-stream-new-window-link:hover {
    color: #ffffff !important;
}

.goualuto-tabs-nav .goualuto-tab-btn {
    border-bottom: 3px solid transparent !important;
    color: var(--gp-text-light) !important;
    outline: none;
}

.goualuto-tabs-nav .goualuto-tab-btn:hover {
    color: var(--gp-text-main) !important;
    background: rgba(15, 23, 42, 0.02) !important;
}

.goualuto-tabs-nav .goualuto-tab-btn.active {
    border-bottom: 3px solid var(--gp-primary) !important;
    color: var(--gp-primary) !important;
    background: var(--gp-bg-card) !important;
}

.goualuto-standings-table th {
    color: var(--gp-text-muted) !important;
    text-transform: uppercase;
    font-size: 11px;
    letter-spacing: 0.5px;
    border-bottom: 1px solid var(--gp-border) !important;
}

.goualuto-standings-table tbody tr:hover {
    background: var(--gp-border-light) !important;
}

.goualuto-standings-table td {
    border-bottom: 1px solid var(--gp-border-light) !important;
}

.scorer-row-hover {
    transition: transform 0.2s ease, box-shadow 0.2s ease;
    background: var(--gp-bg-card);
}

.scorer-row-hover:hover {
    transform: translateY(-2px);
    box-shadow: 0 4px 10px rgba(15, 23, 42, 0.05);
    background: var(--gp-border-light) !important;
    border-color: var(--gp-primary) !important;
}

.spin {
    animation: goualuto-spin 1.2s linear infinite;
}

@keyframes goualuto-spin {
    0% {
        transform: rotate(0deg);
    }

    100% {
        transform: rotate(360deg);
    }
}

@media (max-width: 640px) {
    .pub-match-stream-bar {
        padding: 8px 10px;
    }

    .pub-match-stream-drawer {
        padding: 12px 10px;
    }

    .pub-stream-servers-grid {
        gap: 6px;
    }

    .pub-stream-server-btn {
        padding: 6px 12px;
        font-size: 12px;
        flex-grow: 1;
        justify-content: center;
    }

    .goualuto-tabs-nav .goualuto-tab-btn {
        padding: 8px 4px !important;
        font-size: 0.85rem !important;
    }

    .goualuto-standings-table th,
    .goualuto-standings-table td {
        padding: 8px 6px !important;
        font-size: 0.8rem !important;
    }

    .goualuto-standings-table img {
        width: 18px !important;
        height: 18px !important;
    }
}

/* ═══════════════════════════════════════════════════════
   10. CLICKABLE MATCH CARD WITH STREAM LINK
═══════════════════════════════════════════════════════ */
.match-row-item {
    cursor: pointer;
    outline: none !important;
    -webkit-tap-highlight-color: transparent;
}

.match-row-item:focus,
.match-row-item:active,
.match-row-item:focus-visible {
    outline: none !important;
    box-shadow: none !important;
}


/* Stream redirect loading overlay */
.goualuto-stream-redirect-overlay {
    position: fixed;
    inset: 0;
    background: rgba(15, 23, 42, 0.82);
    backdrop-filter: blur(8px);
    -webkit-backdrop-filter: blur(8px);
    z-index: 999999;
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    gap: 20px;
    font-family: 'Changa', sans-serif;
}

.goualuto-stream-redirect-overlay .overlay-spinner {
    width: 52px;
    height: 52px;
    border: 4px solid rgba(255, 255, 255, 0.1);
    border-top: 4px solid #10b981;
    border-radius: 50%;
    animation: goualuto-spin 0.8s linear infinite;
}

.goualuto-stream-redirect-overlay .overlay-text {
    color: #ffffff;
    font-size: 18px;
    font-weight: 700;
    letter-spacing: 0.5px;
}

.goualuto-stream-redirect-overlay .overlay-sub {
    color: rgba(255, 255, 255, 0.55);
    font-size: 13px;
}

/* ═══════════════════════════════════════════════════════
   11. INJECTED PLAYER BLOCK (inside single post pages)
═══════════════════════════════════════════════════════ */

/* ── Full-width breakout: pull out of the post container ── */
.goualuto-injected-player-wrap {
    position: relative;
    margin-bottom: 40px;
    margin-top: 0;
    font-family: 'Changa', sans-serif;
    direction: rtl;
    background: #080e1a;
    box-sizing: border-box;
}

/* ── Server selection bar — equal-width buttons filling the bar ── */
.goualuto-injected-server-bar {
    display: flex !important;
    flex-wrap: nowrap !important;
    gap: 0 !important;
    padding: 0 !important;
    margin: 0 !important;
    list-style: none !important;
    background: linear-gradient(180deg, #0d1b2e 0%, #0a1422 100%) !important;
    border-bottom: 1px solid rgba(255, 255, 255, 0.06) !important;
    border-top: none !important;
    border-left: none !important;
    border-right: none !important;
    overflow-x: auto !important;
    scrollbar-width: none !important;
    width: 100% !important;
    box-sizing: border-box !important;
}

.goualuto-injected-server-bar::-webkit-scrollbar {
    display: none;
}

.goualuto-injected-server-btn {
    flex: 1 1 0% !important;
    min-width: 80px !important;
    max-width: none !important;
    display: flex !important;
    align-items: center !important;
    justify-content: center !important;
    gap: 8px !important;
    background: transparent !important;
    color: rgba(255, 255, 255, 0.5) !important;
    border: none !important;
    border-bottom: 3px solid transparent !important;
    border-radius: 0 !important;
    padding: 16px 10px !important;
    margin: 0 !important;
    font-family: 'Changa', sans-serif !important;
    font-size: 15px !important;
    font-weight: 700 !important;
    cursor: pointer !important;
    transition: all 0.22s ease !important;
    letter-spacing: 0.3px !important;
    position: relative !important;
    white-space: nowrap !important;
    text-decoration: none !important;
    box-shadow: none !important;
    outline: none !important;
    line-height: 1.4 !important;
    -webkit-appearance: none !important;
    appearance: none !important;
}

.goualuto-injected-server-btn:not(:last-child) {
    border-right: 1px solid rgba(255, 255, 255, 0.07) !important;
}

.goualuto-injected-server-btn:hover {
    background: rgba(255, 255, 255, 0.05) !important;
    color: rgba(255, 255, 255, 0.9) !important;
    border-bottom: 3px solid rgba(255, 255, 255, 0.15) !important;
}

.goualuto-injected-server-btn:focus {
    outline: none !important;
    box-shadow: none !important;
}

.goualuto-injected-server-btn.active {
    background: rgba(16, 185, 129, 0.1) !important;
    color: #10b981 !important;
    border-bottom: 3px solid #10b981 !important;
}

.goualuto-injected-server-btn.active .goualuto-server-icon {
    filter: drop-shadow(0 0 6px rgba(16, 185, 129, 0.8));
}

.goualuto-server-icon {
    font-size: 15px;
    line-height: 1;
}

/* Live pulse dot inside active server button */
.goualuto-injected-server-btn.active::before {
    content: '';
    display: inline-block;
    width: 7px;
    height: 7px;
    border-radius: 50%;
    background: #ef4444;
    animation: goualuto-spin 0s linear infinite, gp-pulse-red 1.2s ease-in-out infinite;
    flex-shrink: 0;
}

@keyframes gp-pulse-red {

    0%,
    100% {
        opacity: 1;
        transform: scale(1);
    }

    50% {
        opacity: 0.4;
        transform: scale(0.7);
    }
}

/* ── Main player container ── */
.goualuto-injected-player-container {
    background: #000;
    overflow: hidden;
    position: relative;
    width: 100%;
}

/* ── All video/iframe wrappers: 16:9 full-width ── */
.goualuto-injected-video-wrap,
.goualuto-injected-youtube-wrap,
.goualuto-injected-iframe-wrap {
    width: 100%;
    aspect-ratio: 16 / 9;
    position: relative;
    background: #000;
}

.goualuto-video-element {
    width: 100%;
    height: 100%;
    display: block;
    background: #000;
}

.goualuto-yt-embed {
    width: 100%;
    height: 100%;
    overflow: hidden;
}

.goualuto-yt-embed iframe,
.goualuto-injected-iframe-wrap iframe {
    border: 0;
    position: absolute;
    inset: 0;
    width: 100%;
    height: 100%;
    display: block;
}

/* ── Loading state ── */
.goualuto-injected-loading {
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    gap: 18px;
    min-height: 360px;
    background: radial-gradient(ellipse at center, #0d1b2e 0%, #040a14 100%);
    color: rgba(255, 255, 255, 0.55);
    font-family: 'Changa', sans-serif;
    font-size: 14px;
    font-weight: 700;
    letter-spacing: 0.5px;
}

.goualuto-loading-spinner {
    width: 50px;
    height: 50px;
    border: 3px solid rgba(255, 255, 255, 0.06);
    border-top: 3px solid #10b981;
    border-radius: 50%;
    animation: goualuto-spin 0.85s linear infinite;
}

.goualuto-injected-loading::after {
    content: '⚽';
    font-size: 22px;
    opacity: 0.3;
    margin-top: -8px;
}

/* ── Plyr theme overrides ── */
.goualuto-injected-player-wrap .plyr {
    border-radius: 0 !important;
}

.goualuto-injected-player-wrap .plyr__control--overlaid {
    background: rgba(16, 185, 129, 0.9) !important;
    padding: 20px !important;
}

.goualuto-injected-player-wrap .plyr__control--overlaid:hover {
    background: #059669 !important;
    transform: scale(1.08);
}

.goualuto-injected-player-wrap .plyr--full-ui input[type=range] {
    color: #10b981;
}

.goualuto-injected-player-wrap .plyr__controls {
    background: linear-gradient(transparent, rgba(0, 0, 0, 0.85)) !important;
    padding: 20px 14px 10px !important;
}

.goualuto-injected-player-wrap .plyr__progress input[type=range]::-webkit-slider-thumb {
    background: #10b981;
}

.goualuto-injected-player-wrap .plyr__menu__container {
    direction: rtl;
}

/* ── Responsive: stack buttons vertically on very small screens ── */
@media (max-width: 480px) {
    .goualuto-injected-server-btn {
        padding: 12px 6px;
        font-size: 12px;
        gap: 5px;
    }

    .goualuto-server-icon {
        font-size: 13px;
    }
}

/* ═══════════════════════════════════════════════════════
   11. LEAGUES AND STANDINGS WIDGET
   ═══════════════════════════════════════════════════════ */
.goualuto-leagues-widget-wrap {
    font-family: 'Changa', sans-serif;
    background: #ffffff;
    border: 1px solid #e2e8f0;
    border-radius: 20px;
    padding: 24px;
    box-shadow: 0 10px 30px rgba(0, 0, 0, 0.04);
    margin: 20px 0;
    position: relative;
    overflow: hidden;
}

.goualuto-leagues-widget-wrap::before {
    content: '';
    position: absolute;
    top: -50px;
    left: -50px;
    width: 150px;
    height: 150px;
    background: radial-gradient(circle, rgba(16, 185, 129, 0.05) 0%, transparent 70%);
    pointer-events: none;
}

.leagues-widget-header {
    margin-bottom: 20px;
    border-bottom: 1px solid #f1f5f9;
    padding-bottom: 15px;
}

.leagues-widget-header h3 {
    font-size: 1.3rem;
    font-weight: 700;
    color: #0f172a;
    margin: 0;
    letter-spacing: 0.5px;
}

.header-icon-title {
    display: flex;
    align-items: center;
    gap: 10px;
}

.header-icon-title .widget-icon {
    font-size: 1.5rem;
}

/* Leagues grid view selector */
.leagues-grid-container {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(130px, 1fr));
    gap: 20px;
    padding: 10px 0;
    margin-top: 15px;
}

.league-grid-card {
    display: flex;
    flex-direction: column;
    align-items: center;
    text-align: center;
    background: #f8fafc;
    border: 1px solid #e2e8f0;
    border-radius: 16px;
    cursor: pointer;
    outline: none !important;
    transition: all 0.25s cubic-bezier(0.4, 0, 0.2, 1);
    padding: 18px 12px;
    box-shadow: 0 2px 4px rgba(0, 0, 0, 0.02);
}

.league-grid-card:hover {
    transform: translateY(-4px);
    background: #ffffff;
    border-color: #10b981;
    box-shadow: 0 10px 25px rgba(16, 185, 129, 0.08);
}

.league-circle-logo {
    width: 80px;
    height: 80px;
    background: #1e293b; /* Dark slate background so white logos show up perfectly */
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    box-shadow: 0 4px 10px rgba(0, 0, 0, 0.1);
    border: 2px solid #e2e8f0;
    transition: all 0.25s ease;
    overflow: hidden;
    margin-bottom: 12px;
    padding: 10px;
}

.league-grid-card:hover .league-circle-logo {
    box-shadow: 0 6px 18px rgba(16, 185, 129, 0.25);
    border-color: #10b981;
    transform: scale(1.05);
}

.league-circle-logo img {
    width: 50px;
    height: 50px;
    object-fit: contain;
}

.league-card-title {
    font-size: 0.9rem;
    font-weight: 700;
    color: #334155;
    line-height: 1.4;
    transition: color 0.2s ease;
}

.league-grid-card:hover .league-card-title {
    color: #10b981;
}

/* Detail view styling */
.league-detail-view {
    position: relative;
}

.back-to-grid-btn {
    display: inline-flex;
    align-items: center;
    gap: 8px;
    background: #f1f5f9;
    border: 1px solid #e2e8f0;
    border-radius: 10px;
    padding: 8px 16px;
    color: #475569;
    cursor: pointer;
    font-weight: 600;
    font-size: 0.9rem;
    margin-bottom: 20px;
    transition: all 0.2s ease;
    outline: none !important;
}

.back-to-grid-btn:hover {
    background: #e2e8f0;
    color: #0f172a;
    border-color: #10b981;
}

.selected-league-header {
    display: flex;
    align-items: center;
    gap: 15px;
    margin-bottom: 20px;
    border-bottom: 1px solid #e2e8f0;
    padding-bottom: 15px;
}

.selected-league-logo {
    width: 48px;
    height: 48px;
    object-fit: contain;
    background: #1e293b;
    border-radius: 50%;
    padding: 6px;
    border: 1px solid #e2e8f0;
}

.selected-league-title {
    font-size: 1.25rem;
    font-weight: 700;
    color: #0f172a;
    margin: 0;
}

@media (max-width: 600px) {
    .leagues-grid-container {
        grid-template-columns: repeat(auto-fill, minmax(100px, 1fr));
        gap: 15px;
    }
    .league-grid-card {
        padding: 12px 8px;
    }
    .league-circle-logo {
        width: 70px;
        height: 70px;
    }
    .league-circle-logo img {
        width: 40px;
        height: 40px;
    }
    .league-card-title {
        font-size: 0.85rem;
    }
}

/* Sub-nav standings vs scorers buttons */
.leagues-subnav-bar {
    display: flex;
    gap: 2px;
    background: #f1f5f9;
    border: 1px solid #e2e8f0;
    border-radius: 12px;
    padding: 4px;
    margin-bottom: 20px;
}

.subnav-tab-btn {
    flex: 1;
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 8px;
    background: transparent;
    border: none;
    border-radius: 9px;
    padding: 12px;
    color: #64748b;
    cursor: pointer;
    font-weight: 600;
    font-size: 0.95rem;
    transition: all 0.2s ease;
    outline: none !important;
}

.subnav-tab-btn:hover {
    color: #0f172a;
}

.subnav-tab-btn.active {
    background: #ffffff;
    color: #0f172a;
    box-shadow: 0 4px 10px rgba(0, 0, 0, 0.05);
}

.subnav-tab-btn .tab-icon {
    font-size: 1.1rem;
}

/* Content Container with Loader */
.leagues-content-wrapper {
    position: relative;
    min-height: 250px;
    border-radius: 16px;
    background: #ffffff;
    border: 1px solid #e2e8f0;
    padding: 16px;
}

.leagues-loading-overlay {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: rgba(255, 255, 255, 0.85);
    display: flex;
    align-items: center;
    justify-content: center;
    z-index: 10;
    backdrop-filter: blur(4px);
    border-radius: 16px;
    transition: opacity 0.25s ease;
}

.leagues-spinner {
    width: 45px;
    height: 45px;
    border: 3px solid #e2e8f0;
    border-top: 3px solid #10b981;
    border-radius: 50%;
    animation: goualuto-spin 0.8s linear infinite;
}

.league-no-data {
    text-align: center;
    padding: 50px 20px;
    color: #64748b;
    font-size: 1.05rem;
}

/* Tables styling */
.goualuto-standings-table,
.goualuto-scorers-table {
    width: 100%;
    border-collapse: collapse;
    margin: 0;
    text-align: center;
    color: #334155;
}

.goualuto-standings-table th,
.goualuto-scorers-table th {
    background: #f8fafc;
    border-bottom: 2px solid #e2e8f0;
    color: #475569;
    font-weight: 700;
    font-size: 0.9rem;
    padding: 14px 10px;
}

.goualuto-standings-table td,
.goualuto-scorers-table td {
    padding: 12px 10px;
    font-size: 0.92rem;
    border-bottom: 1px solid #f1f5f9;
    vertical-align: middle;
    transition: background 0.15s ease;
}

.goualuto-standings-table tbody tr:hover,
.goualuto-scorers-table tbody tr:hover {
    background: #f8fafc;
}

.col-rank {
    width: 70px;
}

.rank-badge {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 26px;
    height: 26px;
    border-radius: 50%;
    background: #f1f5f9;
    color: #475569;
    font-weight: 700;
    font-size: 0.85rem;
}

/* Bold top 3 rankings */
.goualuto-standings-table tbody tr:nth-child(1) .rank-badge,
.goualuto-scorers-table tbody tr:nth-child(1) .rank-badge { background: rgba(234, 179, 8, 0.15); color: #b45309; }
.goualuto-standings-table tbody tr:nth-child(2) .rank-badge,
.goualuto-scorers-table tbody tr:nth-child(2) .rank-badge { background: #e2e8f0; color: #475569; }
.goualuto-standings-table tbody tr:nth-child(3) .rank-badge,
.goualuto-scorers-table tbody tr:nth-child(3) .rank-badge { background: rgba(202, 138, 4, 0.15); color: #a16207; }

/* Group title styling if present */
.standings-group-title {
    background: linear-gradient(90deg, #f8fafc 0%, transparent 100%);
    border-right: 4px solid #10b981;
    color: #0f172a;
    font-weight: 700;
    font-size: 1.05rem;
    padding: 10px 16px;
    margin: 20px 0 12px;
    border-radius: 0 6px 6px 0;
}

/* Team columns info alignment */
.col-team {
    text-align: right !important;
}

.team-info {
    display: flex;
    align-items: center;
    gap: 12px;
    text-align: right;
}

.team-logo {
    width: 26px;
    height: 26px;
    object-fit: contain;
}

.team-name {
    font-weight: 700;
    color: #0f172a;
}

/* Scorer columns info alignment */
.col-player {
    text-align: right !important;
}

.player-info {
    display: flex;
    align-items: center;
    gap: 12px;
    text-align: right;
}

.player-photo {
    width: 32px;
    height: 32px;
    object-fit: cover;
    border-radius: 50%;
    border: 1px solid #e2e8f0;
    background: #f1f5f9;
}

.player-photo-placeholder {
    width: 32px;
    height: 32px;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    border-radius: 50%;
    background: #f1f5f9;
    font-size: 16px;
}

.player-name {
    font-weight: 700;
    color: #0f172a;
}

.font-weight-bold {
    font-weight: 700 !important;
}

/* Responsive view columns optimization */
@media (max-width: 768px) {
    .goualuto-leagues-widget-wrap {
        padding: 16px;
    }

    .goualuto-standings-table th,
    .goualuto-standings-table td,
    .goualuto-scorers-table th,
    .goualuto-scorers-table td {
        padding: 10px 6px;
        font-size: 0.85rem;
    }

    /* Hide Played, Won, Drawn, Lost on very narrow screens, keep rank, team, diff, points */
    .goualuto-standings-table .col-win, 
    .goualuto-standings-table .col-equal, 
    .goualuto-standings-table .col-lose, 
    .goualuto-standings-table .col-goals {
        display: none !important;
    }
    
    .col-rank {
        width: 45px;
    }
}

/* ═══════════════════════════════════════════════════════
   12. MATCH STATS & RESULTS WIDGET
   ═══════════════════════════════════════════════════════ */
.goualuto-stats-widget-wrap {
    font-family: 'Changa', sans-serif;
    position: relative;
    margin: 20px 0;
}

/* Grid & Cards */
.goualuto-stats-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(320px, 1-fraction));
    gap: 20px;
}

@media (min-width: 768px) {
    .goualuto-stats-grid {
        grid-template-columns: repeat(2, 1fr);
    }
}

@media (min-width: 1024px) {
    .goualuto-stats-grid {
        grid-template-columns: repeat(3, 1fr);
    }
}

.goualuto-match-stats-card {
    background: #ffffff;
    border: 1px solid #e2e8f0;
    border-radius: 16px;
    padding: 16px;
    box-shadow: 0 4px 6px -1px rgba(0, 0, 0, 0.02), 0 2px 4px -1px rgba(0, 0, 0, 0.02);
    transition: all 0.25s cubic-bezier(0.4, 0, 0.2, 1);
    cursor: pointer;
    position: relative;
    overflow: hidden;
}

.goualuto-match-stats-card:hover {
    transform: translateY(-4px);
    border-color: #10b981;
    box-shadow: 0 10px 15px -3px rgba(16, 185, 129, 0.1), 0 4px 6px -2px rgba(16, 185, 129, 0.05);
}

.card-comp-name {
    font-size: 12px;
    color: #64748b;
    margin-bottom: 12px;
    font-weight: 500;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
}

.card-teams-score {
    display: flex;
    align-items: center;
    justify-content: space-between;
    margin-bottom: 12px;
}

.team-col {
    display: flex;
    flex-direction: column;
    align-items: center;
    width: 38%;
    text-align: center;
}

.stats-badge-wrap {
    width: 48px;
    height: 48px;
    display: flex;
    align-items: center;
    justify-content: center;
    background: #f8fafc;
    border-radius: 50%;
    padding: 6px;
    margin-bottom: 8px;
    border: 1px solid #f1f5f9;
}

.team-badge {
    max-width: 100%;
    max-height: 100%;
    object-fit: contain;
}

.team-name {
    font-size: 14px;
    font-weight: 600;
    color: #1e293b;
    line-height: 1.3;
}

.score-col {
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    width: 24%;
}

.score-text {
    font-size: 20px;
    font-weight: 800;
    color: #0f172a;
    letter-spacing: 1px;
    margin-bottom: 4px;
}

.status-badge {
    font-size: 11px;
    font-weight: 600;
    color: #64748b;
    background: #f1f5f9;
    padding: 3px 8px;
    border-radius: 6px;
}

.status-badge.live {
    color: #ffffff;
    background: #ef4444;
    animation: statsPulse 1.8s infinite;
}

@keyframes statsPulse {
    0% { opacity: 1; }
    50% { opacity: 0.6; }
    100% { opacity: 1; }
}

.card-footer-action {
    border-top: 1px solid #f1f5f9;
    padding-top: 10px;
    text-align: center;
    font-size: 12px;
    font-weight: 500;
    color: #10b981;
}

/* Detail View Layout */
.goualuto-match-detail-view {
    background: #ffffff;
    border: 1px solid #e2e8f0;
    border-radius: 20px;
    padding: 24px;
    box-shadow: 0 10px 25px -5px rgba(0, 0, 0, 0.05);
}

.detail-header-bar {
    display: flex;
    align-items: center;
    justify-content: space-between;
    margin-bottom: 24px;
}

.detail-back-btn {
    display: inline-flex;
    align-items: center;
    gap: 6px;
    font-size: 14px;
    font-weight: 600;
    color: #64748b;
    background: #f1f5f9;
    padding: 6px 14px;
    border-radius: 10px;
    text-decoration: none;
    transition: all 0.2s;
    border: none;
    cursor: pointer;
}

.detail-back-btn:hover {
    background: #e2e8f0;
    color: #1e293b;
}

.detail-match-banner {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 30px;
    padding: 20px 0;
    border-bottom: 1px solid #f1f5f9;
}

.banner-team {
    display: flex;
    flex-direction: column;
    align-items: center;
    width: 30%;
    text-align: center;
}

.banner-team .team-badge-wrap {
    width: 80px;
    height: 80px;
    background: #f8fafc;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 10px;
    margin-bottom: 12px;
    border: 1px solid #f1f5f9;
}

.banner-team .team-badge {
    max-width: 100%;
    max-height: 100%;
    object-fit: contain;
}

.banner-team .team-name {
    font-size: 18px;
    font-weight: 700;
}

.banner-score-col {
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
}

.banner-score-text {
    font-size: 36px;
    font-weight: 800;
    color: #0f172a;
    letter-spacing: 2px;
}

.banner-status {
    font-size: 13px;
    font-weight: 600;
    color: #ffffff;
    background: #ef4444;
    padding: 4px 12px;
    border-radius: 8px;
    margin-top: 8px;
}

.banner-status.not-started {
    background: #f1f5f9;
    color: #64748b;
}

.banner-status.finished {
    background: #1e293b;
    color: #ffffff;
}

/* Detail Navigation Tabs */
.detail-nav-tabs {
    display: flex;
    border-bottom: 2px solid #f1f5f9;
    margin: 20px 0;
    overflow-x: auto;
    scrollbar-width: none;
}

.detail-nav-tabs::-webkit-scrollbar {
    display: none;
}

.detail-tab-btn {
    padding: 12px 18px;
    font-size: 14px;
    font-weight: 600;
    color: #64748b;
    background: none;
    border: none;
    border-bottom: 2px solid transparent;
    margin-bottom: -2px;
    cursor: pointer;
    transition: all 0.2s;
    white-space: nowrap;
}

.detail-tab-btn:hover {
    color: #1e293b;
}

.detail-tab-btn.active {
    color: #10b981;
    border-bottom-color: #10b981;
}

/* Content Area */
.detail-tab-content-pane {
    padding: 10px 0;
}

/* Timeline/Incidents Styles */
.timeline-list {
    position: relative;
    padding: 20px 0;
}

.timeline-list::before {
    content: '';
    position: absolute;
    top: 0;
    bottom: 0;
    left: 50%;
    width: 2px;
    background: #e2e8f0;
    transform: translateX(-50%);
}

.timeline-item {
    display: flex;
    align-items: center;
    margin-bottom: 24px;
    position: relative;
}

.timeline-col {
    width: 44%;
}

.timeline-col.home {
    text-align: left;
    display: flex;
    justify-content: flex-end;
}

.timeline-col.away {
    text-align: right;
    display: flex;
    justify-content: flex-start;
}

.timeline-mid {
    width: 12%;
    display: flex;
    justify-content: center;
    z-index: 2;
}

.timeline-time-badge {
    background: #f1f5f9;
    color: #334155;
    font-size: 12px;
    font-weight: 700;
    padding: 4px 10px;
    border-radius: 20px;
    border: 2px solid #ffffff;
    box-shadow: 0 2px 4px rgba(0,0,0,0.05);
}

.incident-card {
    display: flex;
    align-items: center;
    gap: 8px;
    background: #f8fafc;
    padding: 8px 12px;
    border-radius: 12px;
    border: 1px solid #f1f5f9;
    max-width: 90%;
}

.timeline-col.home .incident-card {
    flex-direction: row-reverse;
}

.incident-icon {
    font-size: 16px;
}

.incident-icon.goal {
    color: #000000;
}

.incident-icon.yellow-card {
    color: #eab308;
    background: #eab308;
    width: 12px;
    height: 16px;
    border-radius: 2px;
    display: inline-block;
}

.incident-icon.red-card {
    color: #ef4444;
    background: #ef4444;
    width: 12px;
    height: 16px;
    border-radius: 2px;
    display: inline-block;
}

.incident-icon.sub {
    color: #10b981;
}

.incident-player {
    font-size: 13px;
    font-weight: 600;
    color: #1e293b;
}

.incident-assist {
    font-size: 11px;
    color: #64748b;
    display: block;
    margin-top: 2px;
}

/* Statistics Styles */
.stats-list {
    display: flex;
    flex-direction: column;
    gap: 16px;
}

.stat-item {
    display: flex;
    flex-direction: column;
    gap: 6px;
}

.stat-labels {
    display: flex;
    justify-content: space-between;
    align-items: center;
    font-size: 14px;
    font-weight: 600;
    color: #1e293b;
}

.stat-name {
    color: #64748b;
}

.stat-progress-bar-wrap {
    display: flex;
    height: 8px;
    background: #f1f5f9;
    border-radius: 4px;
    overflow: hidden;
    position: relative;
    direction: ltr; /* Ensure progress bars are consistent */
}

.progress-bar-home {
    background: #10b981;
    height: 100%;
    transition: width 0.6s cubic-bezier(0.4, 0, 0.2, 1);
}

.progress-bar-away {
    background: #3b82f6;
    height: 100%;
    transition: width 0.6s cubic-bezier(0.4, 0, 0.2, 1);
}

/* Lineups Styles */
.lineups-split {
    display: grid;
    grid-template-columns: 1fr;
    gap: 30px;
}

@media (min-width: 768px) {
    .lineups-split {
        grid-template-columns: 1fr 1fr;
    }
}

.lineup-team-section {
    background: #f8fafc;
    border: 1px solid #f1f5f9;
    border-radius: 16px;
    padding: 16px;
}

.lineup-team-section h4 {
    margin-top: 0;
    margin-bottom: 16px;
    border-bottom: 2px solid #e2e8f0;
    padding-bottom: 8px;
    font-size: 15px;
    font-weight: 700;
    color: #1e293b;
}

.lineup-players-list {
    display: flex;
    flex-direction: column;
    gap: 8px;
}

.lineup-player-row {
    display: flex;
    align-items: center;
    gap: 10px;
    font-size: 13px;
    padding: 6px 0;
    border-bottom: 1px solid #f1f5f9;
}

.player-number {
    font-weight: 700;
    background: #e2e8f0;
    color: #334155;
    width: 24px;
    height: 24px;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 11px;
}

.player-name-text {
    font-weight: 600;
    color: #1e293b;
}

.player-pos {
    font-size: 11px;
    color: #94a3b8;
    background: #f1f5f9;
    padding: 1px 6px;
    border-radius: 4px;
    margin-right: auto;
}

.goualuto-rtl .player-pos {
    margin-right: 0;
    margin-left: auto;
}

/* H2H Styles */
.h2h-list {
    display: flex;
    flex-direction: column;
    gap: 12px;
}

.h2h-match-row {
    display: flex;
    align-items: center;
    justify-content: space-between;
    background: #f8fafc;
    border: 1px solid #f1f5f9;
    border-radius: 12px;
    padding: 12px 16px;
    font-size: 13px;
}

.h2h-date {
    color: #64748b;
    font-size: 12px;
    width: 20%;
}

.h2h-teams {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 10px;
    width: 60%;
    font-weight: 600;
    color: #1e293b;
}

.h2h-score {
    font-weight: 800;
    color: #0f172a;
    background: #e2e8f0;
    padding: 2px 8px;
    border-radius: 6px;
}

.h2h-comp {
    color: #64748b;
    font-size: 12px;
    text-align: right;
    width: 20%;
}

/* Spinner Overlay Styles */
.goualuto-stats-overlay {
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: rgba(255, 255, 255, 0.7);
    z-index: 100;
    display: flex;
    align-items: center;
    justify-content: center;
    border-radius: 20px;
}

.goualuto-stats-spinner-wrap {
    display: flex;
    align-items: center;
    justify-content: center;
    width: 60px;
    height: 60px;
}

.goualuto-stats-spinner {
    width: 40px;
    height: 40px;
    border: 4px solid #f1f5f9;
    border-top: 4px solid #10b981;
    border-radius: 50%;
    animation: statsSpin 0.8s linear infinite;
}

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

.goualuto-no-matches-stats {
    text-align: center;
    padding: 40px 20px;
    background: #f8fafc;
    border: 1px dashed #cbd5e1;
    border-radius: 16px;
    color: #64748b;
    font-size: 15px;
}

/* Redirection / Single Match Mode Styling */
.goualuto-stats-widget-wrap.goualuto-single-match-mode {
    max-width: 1000px;
    margin: 30px auto;
    padding: 0 15px;
}

.goualuto-single-match-mode .goualuto-match-detail-view {
    box-shadow: 0 10px 30px -5px rgba(0, 0, 0, 0.05), 0 8px 15px -6px rgba(0, 0, 0, 0.05);
    border: 1px solid #e2e8f0;
}

.goualuto-single-match-mode .detail-back-btn {
    display: none !important;
}

.goualuto-single-match-mode .detail-header-bar {
    justify-content: center; /* Center the competition name since back button is removed */
}