/* Cards de Jornais - Estilo Melhorado */

.jornal-card {
    height: 420px;
    display: flex;
    flex-direction: column;
    border: 1px solid #e0e0e0;
    border-radius: 8px;
    overflow: hidden;
    background: #fff;
    transition: all 0.3s ease;
    box-shadow: 0 2px 8px rgba(0, 0, 0, 0.1);
}

.jornal-card:hover {
    box-shadow: 0 8px 16px rgba(0, 0, 0, 0.15);
    transform: translateY(-5px);
}

/* Seção da Imagem/Capa */
.jornal-card-image {
    height: 200px;
    background: linear-gradient(135deg, #f5f5f5 0%, #e8e8e8 100%);
    display: flex;
    align-items: center;
    justify-content: center;
    overflow: hidden;
    position: relative;
    background-size: cover;
    background-position: center;
}

.jornal-card-image img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    display: block;
    transition: transform 0.3s ease;
}

.jornal-card:hover .jornal-card-image img {
    transform: scale(1.05);
}

/* Placeholder quando não há imagem */
.jornal-card-placeholder {
    width: 100%;
    height: 100%;
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    background: linear-gradient(135deg, #f5f5f5 0%, #e8e8e8 100%);
    color: #999;
    text-align: center;
    padding: 20px;
}

.jornal-card-placeholder i {
    font-size: 3.5rem;
    margin-bottom: 10px;
    color: #ccc;
    opacity: 0.6;
}

.jornal-card-placeholder span {
    font-size: 0.85rem;
    color: #999;
    font-weight: 500;
}

/* Conteúdo do Card */
.jornal-card-content {
    flex: 1;
    padding: 15px;
    display: flex;
    flex-direction: column;
}

.jornal-card-title {
    font-size: 1rem;
    font-weight: 700;
    color: #333;
    margin: 0 0 8px 0;
    line-height: 1.4;
    display: -webkit-box;
    -webkit-line-clamp: 2;
    -webkit-box-orient: vertical;
    overflow: hidden;
}

.jornal-card-desc {
    font-size: 0.85rem;
    color: #666;
    line-height: 1.4;
    margin: 0 0 12px 0;
    flex: 1;
    display: -webkit-box;
    -webkit-line-clamp: 3;
    -webkit-box-orient: vertical;
    overflow: hidden;
}

/* Stats do Card */
.jornal-card-stats {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 8px;
    margin-bottom: 12px;
    padding-bottom: 12px;
    border-bottom: 1px solid #f0f0f0;
    font-size: 0.8rem;
}

.jornal-card-stat {
    display: flex;
    flex-direction: column;
    align-items: center;
}

.jornal-card-stat-label {
    color: #999;
    font-size: 0.75rem;
    text-transform: uppercase;
    margin-bottom: 3px;
}

.jornal-card-stat-value {
    color: #6a4f00;
    font-weight: 700;
    font-size: 1rem;
}

/* Botões do Card */
.jornal-card-buttons {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 8px;
    margin-top: auto;
}

.jornal-card-btn {
    padding: 8px 12px;
    border: none;
    border-radius: 4px;
    font-size: 0.85rem;
    font-weight: 600;
    cursor: pointer;
    transition: all 0.3s ease;
    text-decoration: none;
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 5px;
    text-align: center;
}

.jornal-card-btn i {
    font-size: 0.9rem;
}

.jornal-card-btn-primary {
    background: #6a4f00;
    color: white;
}

.jornal-card-btn-primary:hover {
    background: #8a6500;
}

.jornal-card-btn-secondary {
    background: #f0f0f0;
    color: #333;
    border: 1px solid #ddd;
}

.jornal-card-btn-secondary:hover {
    background: #e8e8e8;
}

.jornal-card-btn-disabled {
    background: #e0e0e0;
    color: #999;
    cursor: not-allowed;
    opacity: 0.6;
}

.jornal-card-btn-disabled:hover {
    background: #e0e0e0;
}

/* Status Badge */
.jornal-card-badge {
    position: absolute;
    top: 8px;
    right: 8px;
    background: #6a4f00;
    color: white;
    padding: 4px 10px;
    border-radius: 20px;
    font-size: 0.75rem;
    font-weight: 600;
}

.jornal-card-badge-empty {
    background: #ccc;
}

/* Responsive */
@media (max-width: 768px) {
    .jornal-card {
        height: 380px;
    }

    .jornal-card-image {
        height: 160px;
    }

    .jornal-card-placeholder i {
        font-size: 2.5rem;
    }

    .jornal-card-content {
        padding: 12px;
    }

    .jornal-card-title {
        font-size: 0.95rem;
    }

    .jornal-card-buttons {
        grid-template-columns: 1fr;
    }
}

/* Cards carousel wrapper for consistent pages */
.cards-carousel {
    position: relative;
    overflow: hidden;
}
.cards-track {
    display: flex;
    transition: transform 400ms ease;
    will-change: transform;
}
.cards-page {
    display: grid;
    grid-template-columns: repeat(4, 1fr);
    gap: 1rem;
    min-width: 100%;
    box-sizing: border-box;
    padding: 0.5rem 0;
}
.cards-nav {
    position: absolute;
    top: 50%;
    transform: translateY(-50%);
    width: 40px;
    height: 40px;
    border-radius: 50%;
    background: rgba(255,255,255,0.9);
    display: flex;
    align-items: center;
    justify-content: center;
    box-shadow: 0 2px 8px rgba(0,0,0,0.12);
    cursor: pointer;
}
.cards-nav.left { left: 8px; }
.cards-nav.right { right: 8px; }
.cards-nav.disabled { opacity: 0.45; cursor: default; }

/* Make pages adapt to smaller screens */
@media (max-width: 991px) {
    .cards-page { grid-template-columns: repeat(2, 1fr); }
}
@media (max-width: 575px) {
    .cards-page { grid-template-columns: repeat(1, 1fr); }
}

@media (max-width: 576px) {
    .jornal-card {
        height: auto;
    }

    .jornal-card-image {
        height: 140px;
    }

    .jornal-card-placeholder i {
        font-size: 2rem;
    }

    .jornal-card-content {
        padding: 10px;
    }
}
