/* AMCO Blog Posts – blog-posts.css */

/* ── Section ───────────────────────────────────────────────── */
.r4d-bp-section {
    width: 100%;
    box-sizing: border-box;
}

/* ── Header row ────────────────────────────────────────────── */
.r4d-bp-header {
    display: flex;
    align-items: flex-end;
    justify-content: space-between;
    flex-wrap: wrap;
    gap: 12px;
    margin-bottom: 36px;
}

.r4d-bp-header-left {
    display: flex;
    flex-direction: column;
    gap: 4px;
}

.r4d-bp-section-title {
    font-size: 34px;
    font-weight: 700;
    color: #111827;
    margin: 0;
    line-height: 1.15;
}

.r4d-bp-section-subtitle {
    font-size: 14px;
    color: #6B7280;
    margin: 0;
    line-height: 1.5;
}

/* ── View all link ─────────────────────────────────────────── */
.r4d-bp-view-all {
    font-size: 14px;
    font-weight: 600;
    color: #4CAF50;
    text-decoration: none;
    white-space: nowrap;
    display: inline-flex;
    align-items: center;
    gap: 4px;
    transition: gap 0.25s ease, opacity 0.25s ease;
}

.r4d-bp-view-all:hover {
    gap: 8px;
    opacity: 0.8;
}

/* ── Grid ──────────────────────────────────────────────────── */
.r4d-bp-grid {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 28px;
}

/* ── Card ──────────────────────────────────────────────────── */
.r4d-bp-card {
    display: flex;
    flex-direction: column;
    gap: 0;
}

/* ── Entrance animation (staggered fade+slide) ─────────────── */
.r4d-bp-card--anim {
    opacity: 0;
    transform: translateY(24px);
    transition: opacity 0.55s ease, transform 0.55s ease;
    transition-delay: var(--delay, 0s);
}

.r4d-bp-card--anim.r4d-bp-visible {
    opacity: 1;
    transform: translateY(0);
}

/* ── Thumbnail ─────────────────────────────────────────────── */
.r4d-bp-thumb-link {
    display: block;
    text-decoration: none;
    margin-bottom: 18px;
}

.r4d-bp-thumb {
    position: relative;
    height: 220px;
    border-radius: 14px;
    overflow: hidden;
    background: #f3f4f6;
}

.r4d-bp-img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    display: block;
    transition: transform 0.50s cubic-bezier(0.25, 0.46, 0.45, 0.94),
                filter 0.50s ease;
}

.r4d-bp-card:hover .r4d-bp-img {
    transform: scale(1.045);
    filter: brightness(0.95);
}

.r4d-bp-thumb-placeholder {
    width: 100%;
    height: 100%;
    background: linear-gradient(135deg, #e5e7eb 0%, #d1d5db 100%);
}

/* ── Meta row (category · date) ────────────────────────────── */
.r4d-bp-meta {
    display: flex;
    align-items: center;
    gap: 6px;
    margin-bottom: 8px;
}

.r4d-bp-cat {
    font-size: 11px;
    font-weight: 700;
    letter-spacing: 0.08em;
    color: #4CAF50;
    text-transform: uppercase;
}

.r4d-bp-dot {
    font-size: 11px;
    color: #9CA3AF;
    line-height: 1;
}

.r4d-bp-date {
    font-size: 12px;
    color: #9CA3AF;
    font-weight: 500;
}

/* ── Post title ────────────────────────────────────────────── */
.r4d-bp-title {
    font-size: 18px;
    font-weight: 700;
    color: #111827;
    margin: 0 0 10px;
    line-height: 1.3;
}

.r4d-bp-title a {
    color: inherit;
    text-decoration: none;
    transition: color 0.22s ease;
}

.r4d-bp-title a:hover {
    color: #4CAF50;
}

/* ── Excerpt ───────────────────────────────────────────────── */
.r4d-bp-excerpt {
    font-size: 14px;
    color: #6B7280;
    line-height: 1.6;
    margin: 0;

    /* Clamp to 3 lines */
    display: -webkit-box;
    -webkit-line-clamp: 3;
    -webkit-box-orient: vertical;
    overflow: hidden;
}

/* ── No posts ──────────────────────────────────────────────── */
.r4d-bp-no-posts {
    color: #9CA3AF;
    font-size: 14px;
    text-align: center;
    padding: 40px 0;
}

/* ── Responsive ────────────────────────────────────────────── */
@media (max-width: 1024px) {
    .r4d-bp-grid {
        grid-template-columns: repeat(2, 1fr) !important;
    }
}

@media (max-width: 600px) {
    .r4d-bp-grid {
        grid-template-columns: 1fr !important;
    }
    .r4d-bp-section-title {
        font-size: 26px;
    }
    .r4d-bp-header {
        margin-bottom: 24px;
    }
    .r4d-bp-card { border-radius: 12px; }
    .r4d-bp-body { padding: 16px; }
    .r4d-bp-title { font-size: 16px; }
}

@media (max-width: 400px) {
    .r4d-bp-section-title { font-size: 22px; }
}
