/* Resources CSS (List, News, Show pages) */

/* Remove fixed header only for show page */
.show-page > header {
    position: relative;
}

.show-page {
    padding-top: 0;
}

.page-container {
    padding: 2rem 0;
    min-height: 70vh;
    background: linear-gradient(135deg, #fef9f3 0%, #fff5e6 100%);
}

/* When header is sticky, add room above titles */
.list-page .page-container,
.news-page .page-container {
    padding-top: 2rem;
}

.news-page .article-detail {
    margin-top: 0;
}

.page-title,
.landing-title,
.article-title {
    font-size: 3.2rem;
    margin-bottom: 3rem;
    text-align: center;
    color: var(--secondary-color);
    font-weight: 900;
    position: relative;
    display: inline-block;
    left: 50%;
    transform: translateX(-50%);
}

.landing-title {
    font-size: 2.1rem;
    margin-bottom: 2rem;
}

.page-title::after,
.landing-title::after,
.article-title::after {
    content: '';
    position: absolute;
    bottom: -12px;
    left: 50%;
    transform: translateX(-50%);
    width: 100px;
    height: 5px;
    background: linear-gradient(90deg, var(--primary-color), var(--accent-color));
    border-radius: 10px;
}

/* List Items */
.list-section {
    padding: 3rem 0;
}

.list-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(340px, 1fr));
    gap: 2.5rem;
    margin-bottom: 4rem;
}

/* Latest News grid (used by show/news pages) */
.news-grid {
    display: grid;
    grid-template-columns: repeat(3, minmax(0, 1fr));
    gap: 2.5rem;
}

@media (max-width: 1100px) {
    .news-grid {
        grid-template-columns: repeat(2, minmax(0, 1fr));
    }
}

.list-card {
    background: var(--bg-card);
    border-radius: 18px;
    overflow: hidden;
    transition: all 0.4s ease;
    box-shadow: var(--shadow-sm);
    border: 3px solid transparent;
}

.list-card:hover {
    transform: translateY(-8px);
    box-shadow: var(--shadow-lg);
    border-color: var(--accent-color);
}

.list-card img {
    width: 100%;
    height: 220px;
    object-fit: cover;
    transition: transform 0.4s ease;
}

.list-card:hover img {
    transform: scale(1.08);
}

.card-body {
    padding: 2rem;
}

.card-body .date {
    font-size: 0.9rem;
    color: var(--primary-color);
    margin-bottom: 0.8rem;
    display: inline-block;
    font-weight: 700;
    text-transform: uppercase;
    letter-spacing: 0.5px;
}

.card-body h2 {
    font-size: 1.5rem;
    margin-bottom: 0.8rem;
    font-weight: 700;
    color: var(--secondary-color);
}

.card-body p {
    color: var(--text-muted);
    font-size: 1rem;
    line-height: 1.7;
}

/* Pagination */
.pagination {
    display: flex;
    justify-content: center;
    gap: 1rem;
    margin-top: 4rem;
}

.page-btn {
    padding: 0.8rem 1.5rem;
    background: var(--bg-card);
    border: 2px solid var(--primary-color);
    border-radius: 30px;
    transition: all 0.3s ease;
    font-weight: 700;
    color: var(--primary-color);
    box-shadow: var(--shadow-sm);
}

.page-btn:hover {
    background: linear-gradient(135deg, var(--primary-color), var(--accent-color));
    color: #fff;
    border-color: var(--accent-color);
    transform: translateY(-2px);
    box-shadow: var(--shadow-md);
}

/* Article Detail */
.article-detail {
    max-width: 900px;
    margin: 0 auto;
    background: var(--bg-card);
    padding: 4rem;
    border-radius: 20px;
    box-shadow: var(--shadow-md);
    border: 3px solid var(--accent-color);
}

.article-header {
    border-bottom: 3px solid var(--primary-color);
    padding-bottom: 2rem;
    margin-bottom: 3rem;
    text-align: center;
}

.article-meta {
    color: var(--text-muted);
    font-size: 1rem;
    font-weight: 600;
}

.article-content {
    color: var(--text-main);
    line-height: 1.9;
    font-size: 1.15rem;
}

.article-content p {
    margin-bottom: 1.8rem;
}

.article-content img {
    border-radius: 16px;
    margin: 3rem 0;
    box-shadow: var(--shadow-md);
}

/* Show Landing */
.show-landing {
    max-width: 1000px;
    margin: 0 auto;
}

.landing-content {
    background: var(--bg-card);
    padding: 4rem;
    border-radius: 20px;
    margin-bottom: 4rem;
    line-height: 1.9;
    box-shadow: var(--shadow-md);
    border: 3px solid var(--accent-color);
}

@media (max-width: 768px) {
    .page-container {
        padding: 1rem 0;
    }

    .list-page .page-container,
    .news-page .page-container {
        padding-top: 1.25rem;
    }

    .list-section {
        padding: 1.5rem 0;
    }

    .list-grid {
        gap: 1.25rem;
        margin-bottom: 2rem;
    }

    .list-card img {
        height: 180px;
    }

    .card-body {
        padding: 1.25rem;
    }

    .card-body h2 {
        font-size: 1.2rem;
        line-height: 1.4;
    }

    .card-body p {
        font-size: 0.95rem;
        line-height: 1.6;
    }

    .news-grid {
        gap: 1.25rem;
    }

    .article-detail,
    .landing-content {
        padding: 1.25rem;
    }

    .article-detail {
        border-width: 2px;
        border-radius: 16px;
    }

    .article-header {
        padding-bottom: 1.25rem;
        margin-bottom: 1.5rem;
    }

    .article-meta {
        font-size: 0.95rem;
    }

    .article-content {
        font-size: 1.05rem;
        line-height: 1.85;
    }

    .article-content img {
        margin: 1.5rem 0;
    }
    
    .page-title,
    .landing-title,
    .article-title {
        font-size: 1.75rem;
        margin-bottom: 2rem;
    }
    
    .list-grid {
        grid-template-columns: 1fr;
    }

    .pagination {
        flex-direction: column;
        align-items: center;
        gap: 0.75rem;
    }

    .page-btn {
        width: min(420px, 92%);
        text-align: center;
    }
}

@media (max-width: 480px) {
    .page-title,
    .landing-title,
    .article-title {
        font-size: 1.55rem;
        margin-bottom: 1.4rem;
    }

    .article-header {
        padding-bottom: 1rem;
        margin-bottom: 1.1rem;
    }

    .article-content {
        font-size: 0.98rem;
    }

    .list-card img {
        height: 165px;
    }
}

/* Breadcrumb */
.breadcrumb {
    padding: 1.5rem 0;
    font-size: 0.95rem;
}

.breadcrumb ol {
    display: flex;
    align-items: center;
    flex-wrap: wrap;
    gap: 0.5rem;
    list-style: none;
}

.breadcrumb li:not(:last-child)::after {
    content: '›';
    margin-left: 0.5rem;
    color: var(--text-muted);
}

.breadcrumb a {
    color: var(--primary-color);
    font-weight: 600;
    transition: color 0.3s ease;
}

.breadcrumb a:hover {
    color: var(--secondary-color);
}

.breadcrumb li[aria-current="page"] {
    color: var(--text-muted);
    font-weight: 500;
}