/**
 * Podcast Manager Styles
 * Estilos para exibição dos cards de podcasts
 */

/* Grid de Podcasts */
.pm-podcasts-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(280px, 1fr));
    gap: 30px;
    margin: 40px 0;
}

@media (max-width: 768px) {
    .pm-podcasts-grid {
        grid-template-columns: 1fr;
        gap: 20px;
    }
}

/* Card Individual */
.pm-podcast-card {
    background: #f5f5f5;
    border-radius: 12px;
    overflow: hidden;
    transition: transform 0.3s ease, box-shadow 0.3s ease;
    display: flex;
    flex-direction: column;
    height: 100%;
}

.pm-podcast-card:hover {
    transform: translateY(-5px);
    box-shadow: 0 8px 20px rgba(0, 0, 0, 0.1);
}

/* Thumbnail */
.pm-podcast-thumbnail {
    width: 100%;
    height: 200px;
    overflow: hidden;
    position: relative;
    background: #e0e0e0;
}

.pm-podcast-thumbnail img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    transition: transform 0.3s ease;
}

.pm-podcast-card:hover .pm-podcast-thumbnail img {
    transform: scale(1.05);
}

/* Conteúdo */
.pm-podcast-content {
    padding: 20px;
    display: flex;
    flex-direction: column;
    flex-grow: 1;
}

/* Categoria */
.pm-podcast-category {
    margin-bottom: 12px;
}

.pm-podcast-category a {
    display: inline-block;
    font-size: 12px;
    font-weight: 700;
    text-transform: uppercase;
    letter-spacing: 0.5px;
    color: #666;
    text-decoration: none;
    padding: 4px 12px;
    background: #e0e0e0;
    border-radius: 4px;
    transition: all 0.3s ease;
}

.pm-podcast-category a:hover {
    background: #333;
    color: #fff;
}

/* Título */
.pm-podcast-title {
    font-size: 18px;
    font-weight: 600;
    line-height: 1.4;
    color: #222;
    margin: 0 0 12px 0;
    min-height: 50px;
}

/* Descrição */
.pm-podcast-description {
    font-size: 14px;
    line-height: 1.6;
    color: #666;
    margin: 0 0 20px 0;
    flex-grow: 1;
}

/* Plataformas */
.pm-podcast-platforms {
    display: flex;
    gap: 12px;
    align-items: center;
    padding-top: 15px;
    border-top: 1px solid #ddd;
    margin-top: auto;
}

.pm-platform-icon {
    transition: all 0.3s ease;
    text-decoration: none;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 32px;
    height: 32px;
}

.pm-platform-icon svg {
    width: 24px;
    height: 24px;
    fill: currentColor;
    transition: all 0.3s ease;
}

.pm-platform-icon:hover {
    transform: scale(1.15);
    opacity: 0.8;
}

.pm-platform-icon:hover svg {
    filter: brightness(1.1);
}

/* Mensagem quando não há podcasts */
.pm-no-podcasts {
    text-align: center;
    padding: 60px 20px;
    font-size: 16px;
    color: #999;
    background: #f5f5f5;
    border-radius: 12px;
    margin: 40px 0;
}

/* Responsividade adicional */
@media (min-width: 769px) and (max-width: 1024px) {
    .pm-podcasts-grid {
        grid-template-columns: repeat(2, 1fr);
    }
}

@media (min-width: 1025px) and (max-width: 1400px) {
    .pm-podcasts-grid {
        grid-template-columns: repeat(3, 1fr);
    }
}

@media (min-width: 1401px) {
    .pm-podcasts-grid {
        grid-template-columns: repeat(4, 1fr);
    }
}

/* Ajustes para títulos longos */
.pm-podcast-title {
    overflow: hidden;
    text-overflow: ellipsis;
    display: -webkit-box;
    -webkit-line-clamp: 2;
    -webkit-box-orient: vertical;
}

/* Ajustes para descrições longas */
.pm-podcast-description {
    overflow: hidden;
    text-overflow: ellipsis;
    display: -webkit-box;
    -webkit-line-clamp: 3;
    -webkit-box-orient: vertical;
}

/* Loading state (opcional para uso futuro) */
.pm-podcasts-loading {
    text-align: center;
    padding: 40px;
    color: #999;
}

/* Animação suave ao carregar */
.pm-podcast-card {
    animation: fadeInUp 0.5s ease forwards;
    opacity: 0;
}

@keyframes fadeInUp {
    from {
        opacity: 0;
        transform: translateY(20px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

/* Delay nas animações para efeito cascata */
.pm-podcast-card:nth-child(1) { animation-delay: 0.1s; }
.pm-podcast-card:nth-child(2) { animation-delay: 0.2s; }
.pm-podcast-card:nth-child(3) { animation-delay: 0.3s; }
.pm-podcast-card:nth-child(4) { animation-delay: 0.4s; }
.pm-podcast-card:nth-child(n+5) { animation-delay: 0.5s; }

/* ========================================
   PAGINAÇÃO
   ======================================== */

.pm-pagination {
    display: flex;
    justify-content: center;
    align-items: center;
    gap: 10px;
    margin: 50px 0 30px 0;
    flex-wrap: wrap;
}

/* Botões Anterior/Próximo */
.pm-pagination-btn {
    display: inline-flex;
    align-items: center;
    gap: 8px;
    padding: 12px 24px;
    background: #333;
    color: #fff;
    text-decoration: none;
    border-radius: 6px;
    font-weight: 600;
    font-size: 14px;
    transition: all 0.3s ease;
    cursor: pointer;
}

.pm-pagination-btn:hover {
    background: #555;
    transform: translateY(-2px);
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.15);
}

.pm-pagination-btn.pm-pagination-disabled {
    background: #ddd;
    color: #999;
    cursor: not-allowed;
    pointer-events: none;
}

.pm-pagination-arrow {
    font-size: 16px;
    font-weight: bold;
}

/* Container dos números */
.pm-pagination-numbers {
    display: flex;
    align-items: center;
    gap: 6px;
}

/* Números de página */
.pm-pagination-number {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 40px;
    height: 40px;
    background: #f5f5f5;
    color: #333;
    text-decoration: none;
    border-radius: 6px;
    font-weight: 600;
    font-size: 14px;
    transition: all 0.3s ease;
}

.pm-pagination-number:hover {
    background: #e0e0e0;
    transform: translateY(-2px);
}

.pm-pagination-number.pm-pagination-current {
    background: #333;
    color: #fff;
    cursor: default;
    box-shadow: 0 2px 8px rgba(0, 0, 0, 0.2);
}

/* Reticências */
.pm-pagination-dots {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 40px;
    height: 40px;
    color: #999;
    font-weight: bold;
}

/* Responsividade da paginação */
@media (max-width: 768px) {
    .pm-pagination {
        gap: 8px;
        margin: 40px 0 20px 0;
    }
    
    .pm-pagination-btn {
        padding: 10px 16px;
        font-size: 13px;
    }
    
    .pm-pagination-number {
        width: 36px;
        height: 36px;
        font-size: 13px;
    }
    
    .pm-pagination-dots {
        width: 30px;
        height: 36px;
    }
}

@media (max-width: 480px) {
    .pm-pagination {
        gap: 5px;
    }
    
    /* Esconder alguns números no mobile */
    .pm-pagination-number:not(.pm-pagination-current) {
        display: none;
    }
    
    .pm-pagination-number.pm-pagination-current {
        display: inline-flex;
    }
    
    /* Mostrar apenas primeiro, último e atual */
    .pm-pagination-numbers a:first-child,
    .pm-pagination-numbers a:last-child {
        display: inline-flex !important;
    }
}
