/* ==================== POSTS GRID ==================== */
.posts-section { padding: 60px 0; }

.posts-grid {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 28px;
}

/* Featured post - large card */
.post-card-featured {
    grid-column: 1 / -1;
    display: grid;
    grid-template-columns: 1.4fr 1fr;
    gap: 0;
    background: var(--bg-white);
    border: 1px solid var(--border);
    border-radius: var(--radius-xl);
    overflow: hidden;
    transition: all var(--transition);
}
.post-card-featured:hover {
    box-shadow: var(--shadow-xl);
    border-color: transparent;
}

.post-card-featured .post-thumb {
    aspect-ratio: 16/9;
    overflow: hidden;
}
.post-card-featured .post-thumb img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    transition: transform 0.5s cubic-bezier(0.4,0,0.2,1);
}
.post-card-featured:hover .post-thumb img { transform: scale(1.04); }

.post-card-featured .post-info {
    padding: 45px 40px;
    display: flex;
    flex-direction: column;
    justify-content: center;
}
.post-card-featured .post-title {
    font-family: var(--font-heading);
    font-size: 1.5rem;
    font-weight: 700;
    color: var(--text-dark);
    line-height: 1.35;
    margin-bottom: 14px;
}
.post-card-featured .post-title a { color: inherit; }
.post-card-featured .post-title a:hover { color: var(--primary); }

/* Meta top (category + read time) */
.post-meta-top {
    display: flex;
    align-items: center;
    gap: 8px;
    font-size: 0.75rem;
    color: var(--text-muted);
    margin-bottom: 14px;
}
.post-meta-top .meta-category {
    font-weight: 700;
    color: var(--primary);
    text-transform: uppercase;
    letter-spacing: 0.5px;
}

/* Read more link */
.read-more-link {
    display: inline-flex;
    align-items: center;
    gap: 4px;
    font-size: 0.85rem;
    font-weight: 600;
    color: var(--primary);
    text-decoration: none;
    transition: all 0.2s ease;
    margin-top: auto;
}
.read-more-link:hover {
    color: var(--primary-dark);
    gap: 8px;
}

.post-card-featured .post-excerpt {
    color: var(--text-muted);
    font-size: 0.92rem;
    line-height: 1.75;
    margin-bottom: 22px;
}
.post-card-featured .post-meta { color: var(--text-muted); font-size: 0.8rem; }

/* Regular post card */
.post-card {
    background: var(--bg-white);
    border: 1px solid var(--border);
    border-radius: 14px;
    overflow: hidden;
    transition: all 0.3s cubic-bezier(0.4,0,0.2,1);
    display: flex;
    flex-direction: column;
    position: relative;
}
.post-card:hover {
    box-shadow: 0 8px 30px rgba(0,0,0,0.06);
    transform: translateY(-4px);
    border-color: var(--border);
}

.post-card .post-thumb {
    aspect-ratio: 16/10;
    overflow: hidden;
    position: relative;
}
.post-card .post-thumb img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    transition: transform 0.5s cubic-bezier(0.4,0,0.2,1);
}
.post-card:hover .post-thumb img { transform: scale(1.04); }

.post-card .post-category-badge {
    position: absolute;
    top: 12px;
    left: 12px;
    background: var(--text-dark);
    color: #fff;
    font-size: 0.6rem;
    font-weight: 600;
    padding: 4px 12px;
    border-radius: 6px;
    text-transform: uppercase;
    letter-spacing: 0.5px;
    z-index: 3;
}

.post-card .post-info {
    padding: 18px 20px 20px;
    display: flex;
    flex-direction: column;
    flex: 1;
}

/* Card meta top - date + read time */
.post-card-meta-top {
    display: flex;
    align-items: center;
    gap: 12px;
    font-size: 0.72rem;
    color: var(--text-muted);
    margin-bottom: 10px;
}
.post-card-meta-top .meta-date {
    display: inline-flex;
    align-items: center;
    gap: 5px;
}
.post-card-meta-top .meta-date svg {
    opacity: 0.45;
}
.post-card-meta-top .meta-read-time {
    color: var(--text-muted);
    font-size: 0.72rem;
}
.post-card-meta-top .meta-read-time::before {
    content: '·';
    margin-right: 12px;
}

.post-card .post-title {
    font-family: var(--font-heading);
    font-size: 0.95rem;
    font-weight: 700;
    color: var(--text-dark);
    line-height: 1.5;
    margin-bottom: 8px;
    display: -webkit-box;
    -webkit-line-clamp: 2;
    -webkit-box-orient: vertical;
    overflow: hidden;
}
.post-card .post-title a { color: inherit; text-decoration: none; }
.post-card:hover .post-title a { color: var(--text-dark); }

/* Card excerpt */
.post-card .post-excerpt {
    font-size: 0.8rem;
    color: var(--text-muted);
    line-height: 1.65;
    margin-bottom: 16px;
    display: -webkit-box;
    -webkit-line-clamp: 2;
    -webkit-box-orient: vertical;
    overflow: hidden;
    flex: 1;
}

/* Card footer — author + views */
.post-card-footer {
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding-top: 14px;
    border-top: 1px solid var(--border);
    margin-top: auto;
}
.post-author {
    display: flex;
    align-items: center;
    gap: 8px;
    font-size: 0.75rem;
    font-weight: 600;
    color: var(--text-dark);
}
.author-avatar {
    width: 26px;
    height: 26px;
    border-radius: 50%;
    background: var(--text-dark);
    color: #fff;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 0.65rem;
    font-weight: 700;
}
.post-views {
    display: inline-flex;
    align-items: center;
    gap: 4px;
    font-size: 0.72rem;
    color: var(--text-muted);
}
.post-views svg { opacity: 0.4; }

.post-card .post-meta {
    display: flex;
    align-items: center;
    gap: 10px;
    font-size: 0.75rem;
    color: var(--text-muted);
}

.post-meta .meta-author { font-weight: 600; color: var(--text-dark); }
.post-meta .meta-dot { width: 3px; height: 3px; background: var(--text-muted); border-radius: 50%; flex-shrink: 0; }

/* Thumbnail placeholder — clean minimal */
.thumb-placeholder {
    width: 100%;
    height: 100%;
    background: #f8fafc;
    display: flex;
    align-items: center;
    justify-content: center;
    color: #cbd5e1;
    position: relative;
    overflow: hidden;
}
.thumb-placeholder svg {
    opacity: 0.4;
}

/* Featured card placeholder */
.post-card-featured .thumb-placeholder svg {
    width: 56px;
    height: 56px;
}

/* Load More Button */
.posts-load-more {
    text-align: center;
    margin-top: 40px;
    padding-top: 32px;
    border-top: 1px solid var(--border);
}
.btn-load-more {
    display: inline-flex;
    align-items: center;
    gap: 8px;
    background: var(--bg-dark);
    color: #fff;
    padding: 14px 36px;
    border-radius: 12px;
    font-family: var(--font-heading);
    font-size: 0.78rem;
    font-weight: 700;
    letter-spacing: 1.5px;
    text-transform: uppercase;
    transition: all 0.3s cubic-bezier(0.4,0,0.2,1);
    border: 1px solid rgba(255,255,255,0.08);
}
.btn-load-more:hover {
    background: var(--primary);
    color: #fff;
    border-color: var(--primary);
    transform: translateY(-2px);
    box-shadow: 0 8px 25px rgba(14,165,233,0.3);
}
.btn-load-more svg {
    transition: transform 0.3s ease;
}
.btn-load-more:hover svg {
    transform: translateY(3px);
}

/* Section Pagination (in header) */
.section-pagination {
    display: flex;
    align-items: center;
    gap: 4px;
}
.section-pagination .page-num {
    width: 30px;
    height: 30px;
    display: flex;
    align-items: center;
    justify-content: center;
    border-radius: 6px;
    font-size: 0.78rem;
    font-weight: 600;
    color: var(--text-muted);
    text-decoration: none;
    transition: all 0.2s ease;
}
.section-pagination .page-num:hover {
    background: var(--bg-light);
    color: var(--text-dark);
}
.section-pagination .page-num.active {
    background: var(--bg-dark);
    color: #fff;
}
.section-pagination .page-next {
    width: 30px;
    height: 30px;
    display: flex;
    align-items: center;
    justify-content: center;
    border: 1px solid var(--border);
    border-radius: 6px;
    color: var(--text-muted);
    text-decoration: none;
    transition: all 0.2s ease;
}
.section-pagination .page-next:hover {
    border-color: var(--text-dark);
    color: var(--text-dark);
}

/* Bottom Pagination */
.posts-pagination {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 6px;
    margin-top: 48px;
    padding-top: 32px;
    border-top: 1px solid var(--border);
}
.page-btn {
    width: 38px;
    height: 38px;
    display: flex;
    align-items: center;
    justify-content: center;
    border: 1px solid var(--border);
    border-radius: 8px;
    font-size: 0.82rem;
    font-weight: 600;
    color: var(--text-body);
    text-decoration: none;
    transition: all 0.2s ease;
    background: var(--bg-white);
}
.page-btn:hover {
    border-color: var(--primary);
    color: var(--primary);
    background: rgba(14,165,233,0.04);
}
.page-btn.active {
    background: var(--bg-dark);
    color: #fff;
    border-color: var(--bg-dark);
}
