/* SBP App Custom Styles */

/* ── Auto-refresh bar ── */
.refresh-bar {
    background: #1a1a2e;
    color: #a8b8d8;
    padding: 4px 16px;
    font-size: .78rem;
    display: flex;
    align-items: center;
    gap: 6px;
    border-bottom: 1px solid rgba(255,255,255,.08);
    position: sticky;
    top: 0;
    z-index: 1090;
}
.refresh-dot {
    width: 7px; height: 7px;
    background: #2fb344;
    border-radius: 50%;
    display: inline-block;
    animation: pulse-dot 2s infinite;
    flex-shrink: 0;
}
@keyframes pulse-dot {
    0%,100% { opacity: 1; transform: scale(1); }
    50%      { opacity: .4; transform: scale(.7); }
}
.refresh-bar.paused .refresh-dot { background: #f6a01a; animation: none; }

/* ── League flag badges ── */
.flag { display: inline-block; border-radius: 2px; }
.badge .flag { vertical-align: middle; }

/* ── 5-Day tab strip ── */
.day-tab-strip {
    display: flex;
    flex-wrap: wrap;
    gap: 6px;
    align-items: center;
}
.day-tab {
    display: inline-flex;
    align-items: center;
    gap: 5px;
    padding: 5px 12px;
    border-radius: 20px;
    border: 1.5px solid #dee2e6;
    background: #fff;
    color: #495057;
    font-size: .82rem;
    font-weight: 500;
    text-decoration: none;
    transition: all .15s;
    white-space: nowrap;
}
.day-tab:hover { border-color: #206bc4; color: #206bc4; background: #f0f7ff; }
.day-tab.active { background: #206bc4; border-color: #206bc4; color: #fff; }
.day-tab.empty  { opacity: .45; }
.day-tab-count {
    background: rgba(0,0,0,.12);
    border-radius: 10px;
    padding: 1px 6px;
    font-size: .72rem;
    font-weight: 700;
}
.day-tab.active .day-tab-count { background: rgba(255,255,255,.25); }

/* ── Day group header ── */
.day-group-header {
    display: flex;
    align-items: center;
    padding: 8px 0 4px;
    margin-bottom: 4px;
    border-bottom: 2px solid #e9ecef;
    font-size: .9rem;
}

/* ── Live pulse ── */
.live-pulse { animation: live-blink 1.2s infinite; }
@keyframes live-blink { 0%,100% { opacity:1; } 50% { opacity:.4; } }

/* ── News feed ── */
.news-item { border-left: 3px solid #206bc4; }
.news-item:hover { border-left-color: #2fb344; }
.news-source-badge { font-size: .65rem; font-weight: 600; text-transform: uppercase; letter-spacing: .04em; }
.news-stale { opacity: .55; }

/* Match card */
.match-card {
    transition: transform .15s ease, box-shadow .15s ease;
    border-left: 3px solid transparent;
}
.match-card:hover {
    transform: translateY(-2px);
    box-shadow: 0 4px 20px rgba(0,0,0,.12);
    border-left-color: #206bc4;
    text-decoration: none;
}

/* Team names */
.team-name {
    font-weight: 600;
    font-size: 1rem;
}

/* Odds badges */
.odds-badge {
    background: #f0f4ff;
    color: #206bc4;
    border: 1px solid #cfe2ff;
    border-radius: 6px;
    padding: 2px 8px;
    font-size: .8rem;
    font-weight: 600;
}
.odds-badge.best {
    background: #206bc4;
    color: #fff;
    border-color: #206bc4;
}

/* Community prediction bars */
.pred-bar-wrap { height: 8px; border-radius: 4px; background: #e9ecef; overflow: hidden; }
.pred-bar { height: 100%; border-radius: 4px; transition: width .8s ease; }

/* Confidence stars */
.star-rating input[type=radio] { display: none; }
.star-rating label {
    font-size: 1.6rem;
    cursor: pointer;
    color: #dee2e6;
    transition: color .15s;
}
.star-rating input:checked ~ label,
.star-rating label:hover,
.star-rating label:hover ~ label { color: #f6a01a; }
.star-rating { display: flex; flex-direction: row-reverse; justify-content: flex-end; }

/* Form badges */
.form-badge { display:inline-block; width:22px; height:22px; line-height:22px; border-radius:50%; text-align:center; font-size:.7rem; font-weight:700; color:#fff; }
.form-W { background:#2fb344; }
.form-D { background:#f6a01a; }
.form-L { background:#d63939; }

/* Match header gradient */
.match-hero {
    background: linear-gradient(135deg, #1a1a2e 0%, #16213e 50%, #0f3460 100%);
    color: #fff;
    border-radius: 12px;
}

/* Tip confidence meter */
.confidence-meter { height: 10px; border-radius: 5px; background: #e9ecef; overflow: hidden; }
.confidence-fill { height: 100%; border-radius: 5px; background: linear-gradient(90deg, #f6a01a, #2fb344); }

/* Site prediction box */
.tip-box {
    border: 2px solid #206bc4;
    border-radius: 12px;
    background: linear-gradient(135deg, #f0f7ff, #e8f4fd);
}

/* Stat number display */
.stat-number { font-size: 2rem; font-weight: 700; line-height: 1; }

/* Leaderboard rank badges */
.rank-1 { background: #FFD700; color: #000; }
.rank-2 { background: #C0C0C0; color: #000; }
.rank-3 { background: #CD7F32; color: #fff; }

/* Toast container */
#toast-container {
    position: fixed;
    bottom: 1.5rem;
    right: 1.5rem;
    z-index: 9999;
    display: flex;
    flex-direction: column;
    gap: .5rem;
}
.sbp-toast {
    min-width: 260px;
    padding: .75rem 1.25rem;
    border-radius: 8px;
    color: #fff;
    font-weight: 500;
    box-shadow: 0 4px 15px rgba(0,0,0,.2);
    animation: slideIn .3s ease;
}
.sbp-toast.success { background: #2fb344; }
.sbp-toast.error   { background: #d63939; }
@keyframes slideIn { from { opacity:0; transform: translateX(40px); } to { opacity:1; transform: translateX(0); } }
