/* =============================================================
   PDV – Ora in Onda
   ============================================================= */

.pdv-oia-wrap { font-family: inherit; }

/*  Badge header in onda  */
.pdv-oia-current-header {
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: 14px 18px;
    flex-wrap: wrap;
    gap: 8px;
}

/*  Badge "In onda ora" ─ */
.pdv-live-badge {
    display: inline-flex;
    align-items: center;
    gap: 7px;
    background-color: #fff !important;
    color: #000 !important;
    font-size: 16px;
    font-weight: 600;
}

.pdv-live-dot {
    width: 8px;
    height: 8px;
    border-radius: 50%;
    background: #e53935;
    animation: pdv-blink 1.2s ease-in-out infinite;
    flex-shrink: 0;
}

@keyframes pdv-blink {
    0%, 100% { opacity: 1; }
    50%       { opacity: 0.25; }
}

/*  Orario  */
.pdv-oia-time {
    font-size: 0.88em;
    font-weight: 600;
    color: #1565C0;
    white-space: nowrap;
}

/*  Player / immagine ─ */
.pdv-oia-player {
    position: relative;
    width: 100%;
    padding-bottom: 56.25%;
    height: 0;
    overflow: hidden;
    background: #000;
    border-radius: 16px;
}

.pdv-oia-player iframe {
    position: absolute;
    top: 0; left: 0;
    width: 100%; height: 100%;
    border: none;
}

.pdv-oia-image img {
    width: 100%;
    max-height: 280px;
    object-fit: cover;
    display: block;
}

.pdv-oia-name {
    margin: 0;
    font-size: 1.1em;
    font-weight: 700;
    color: #1a3a5c;
    line-height: 1.3;
}

.pdv-oia-desc {
    margin: 0 !important;
    font-size: 16px;
    color: #000;
}

.pdv-oia-duration {
    font-size: 0.82em;
    color: #999;
}

/*  Pulsante "Scopri il programma" ─ */
.pdv-oia-program-btn {
    display: inline-block;
    margin-top: 6px;
    align-self: flex-start;
    background-color: #1565C0;
    color: #fff;
    text-decoration: none;
    padding: 10px 24px;
    border-radius: 25px;
    font-size: 0.9em;
    font-weight: 600;
    font-family: inherit;
    transition: background-color .2s, transform .1s;
    white-space: nowrap;
}
.pdv-oia-program-btn:hover { background-color: #0d47a1; transform: translateY(-1px); color: #fff; }

/*   Titolo  */
.pdv-oia-upcoming { margin-bottom: 24px; }

.pdv-oia-section-header { 
    margin-bottom: 6px; 
    margin-top: 70px;
}

.pdv-oia-section-title{
    color:#285B8F !important
}

.pdv-oia-section-subtitle{
   font-size: 20px;
}

/*  Riga accordion  */
.pdv-oia-row {     
    background-color: #ffffff;
    border-radius: 12px;
    box-shadow: 0 4px 15px rgba(0, 0, 0, 0.05);
    overflow: hidden;
    padding: 8px 20px;
    margin: 12px 0; 
}

.pdv-oia-row-header {
    display: flex;
    align-items: center;
    gap: 12px;
    padding: 14px 4px;
    flex-wrap: nowrap;
}

.pdv-oia-row-name {
    flex: 1;
    font-size: 18px;
    font-weight: 700;
    color: #000 !important;
}

/*  Pulsante +/−  */
.pdv-oia-toggle {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    flex-shrink: 0;
    width: 32px;
    height: 32px;
    border-radius: 50%;
    background-color: #3381CD;
    color: #fff;
    border: none;
    cursor: pointer;
    transition: background-color .2s, transform .15s;
    padding: 15px !important;
}
.pdv-oia-toggle:hover {
    color: #fff !important;
}

/* Mostra solo il + o il − a seconda dello stato */
.pdv-oia-plus,
.pdv-oia-minus {
    display: block;
    width: 14px;
    height: 14px;
    fill: currentColor;
    flex-shrink: 0;
}
.pdv-oia-minus                                        { display: none; }
.pdv-oia-toggle[aria-expanded="true"] .pdv-oia-plus  { display: none; }
.pdv-oia-toggle[aria-expanded="true"] .pdv-oia-minus { display: block; }

/*  Riga programma in onda (prima voce accordion)  */

.pdv-oia-row--current .pdv-oia-row-header { padding: 14px 4px; }

.pdv-oia-row-badge {
    display: inline-flex;
    align-items: center;
    flex-shrink: 0;
}
.pdv-oia-row-badge .pdv-live-dot {
    width: 10px;
    height: 10px;
    background-color: #e53935;
}

/*  Pannello espanso  */
.pdv-oia-row-panel[hidden] { display: none; }

.pdv-oia-row-panel-inner {
    display: flex;
    gap: 16px;
    padding: 4px 4px 20px;
    flex-wrap: wrap;
}

.pdv-oia-row-img {
    width: 200px;
    height: auto;
    object-fit: cover;
    border-radius: 6px !important;
    flex-shrink: 0;
}

.pdv-oia-row-details {
    flex: 1;
    display: flex;
    flex-direction: column;
    gap: 6px;
    justify-content: center;
}

/*  Pulsante Guida TV ─ */
.pdv-oia-footer { margin-top: 8px; }

.pdv-oia-guide-btn {
    display: inline-block;
    background-color: #1565C0;
    color: #fff;
    text-decoration: none;
    padding: 11px 26px;
    border-radius: 25px;
    font-size: 0.9em;
    font-weight: 600;
    font-family: inherit;
    transition: background-color .2s, transform .1s;
}
.pdv-oia-guide-btn:hover { background-color: #0d47a1; transform: translateY(-1px); color: #fff; }

/*  Messaggi  */
.pdv-oia-error {
    padding: 16px;
    background: #fff3cd;
    border-left: 4px solid #ffc107;
    border-radius: 4px;
    font-size: .9em;
    color: #555;
}
.pdv-oia-empty { color: #888; font-style: italic; text-align: center; padding: 30px 0; }

/*  Responsive  */
@media ( max-width: 600px ) {
    .pdv-oia-current-header { flex-direction: column; align-items: flex-start; }
    .pdv-oia-row-panel-inner { flex-direction: column; }
    .pdv-oia-row-img { width: 100%; height: 160px; }
}

/*  Segnaposto immagine mancante ─ */
.pdv-oia-placeholder {
    display: flex;
    align-items: center;
    justify-content: center;
    background-color: #e8edf2;
    color: #aab4c0;
    border-radius: 6px;
    flex-shrink: 0;
}
