/* ========================================
   מילנר TV — catch-up TV (js/features/catchup.js)
   Tokens come from css/styles.css.
   ======================================== */

/* ----- Player header badge while a recording plays ----- */
.live-badge.fx-catchup-badge {
    animation: none;
    background: var(--bg-elevated);
    color: var(--text-primary);
    border: 1px solid var(--border-light);
    font-size: 10px;
    font-weight: 700;
    letter-spacing: 0;
}

/* ----- EPG panel: "לוח שידורים / צפייה חוזרת" segmented row ----- */
.fx-cu-tabs {
    display: flex;
    align-items: center;
    gap: 8px;
    padding: 10px 16px;
    border-bottom: 1px solid var(--border);
    flex-shrink: 0;
}

.fx-cu-tabs[hidden] { display: none; }

.fx-cu-day {
    padding: 14px 24px 6px;
    font-size: 12px;
    font-weight: 700;
    color: var(--text-secondary);
    text-align: start;
}

.fx-cu-day:first-child { padding-top: 6px; }

.fx-cu-item {
    display: flex;
    align-items: center;
    gap: 12px;
    cursor: pointer;
    border: 1px solid transparent;
    transition: background var(--dur-fast) var(--ease-out), border-color var(--dur-fast) var(--ease-out);
}

.fx-cu-item:hover { background: var(--bg-card-hover); }

.fx-cu-text {
    flex: 1;
    min-width: 0;
    text-align: start;
}

.fx-cu-meta {
    display: flex;
    align-items: center;
    gap: 8px;
}

.fx-cu-text .epg-title {
    overflow: hidden;
    text-overflow: ellipsis;
    white-space: nowrap;
}

.fx-cu-tag {
    flex-shrink: 0;
    padding: 1px 8px;
    border-radius: var(--radius-full);
    background: rgba(220, 38, 38, 0.15);
    color: var(--primary-light);
    font-size: 10.5px;
    font-weight: 700;
    line-height: 1.6;
}

.fx-cu-play {
    flex-shrink: 0;
    display: flex;
    align-items: center;
    justify-content: center;
    width: 34px;
    height: 34px;
    border-radius: var(--radius-full);
    background: var(--bg-card);
    border: 1px solid var(--border-light);
    color: var(--text-primary);
    transition: background var(--dur-fast) var(--ease-out), color var(--dur-fast) var(--ease-out);
}

.fx-cu-item:hover .fx-cu-play,
.fx-cu-item:focus-visible .fx-cu-play {
    background: var(--gradient-brand);
    border-color: transparent;
    color: #fff;
}

.fx-cu-empty {
    padding: 24px;
    text-align: center;
    color: var(--text-muted);
    font-size: 14px;
}

body.kbd-nav .fx-cu-item:focus {
    outline-offset: -2px;
    background: var(--bg-card-hover);
}

/* ----- Full guide: ended programmes with a recording ----- */
.guide-prog.fx-has-catchup::after {
    content: '';
    position: absolute;
    top: 5px;
    inset-inline-end: 5px;
    width: 11px;
    height: 11px;
    background-color: var(--text-secondary);
    -webkit-mask: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='black' stroke-width='2.6' stroke-linecap='round' stroke-linejoin='round'%3E%3Cpolyline points='1 4 1 10 7 10'/%3E%3Cpath d='M3.51 15a9 9 0 1 0 2.13-9.36L1 10'/%3E%3C/svg%3E") center / contain no-repeat;
    mask: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='black' stroke-width='2.6' stroke-linecap='round' stroke-linejoin='round'%3E%3Cpolyline points='1 4 1 10 7 10'/%3E%3Cpath d='M3.51 15a9 9 0 1 0 2.13-9.36L1 10'/%3E%3C/svg%3E") center / contain no-repeat;
    pointer-events: none;
    transition: background-color var(--dur-fast) var(--ease-out);
}

.guide-prog.fx-has-catchup:hover::after { background-color: var(--primary-light); }

@media (prefers-reduced-motion: reduce) {
    .fx-cu-item,
    .fx-cu-play { transition: none; }
}
