/* ==========================================================================
   Feed "Mới nhất" — timeline /posts (NEWS P1) v2.2
   ========================================================================== */

.ola-latest-feed-page .parent-cat-title {
    font-size: 1.5rem;
    font-weight: 800;
    letter-spacing: -0.02em;
    margin: 0;
    color: #111827;
}

.ola-latest-feed {
    --ola-rail-w: 16px;
    --ola-stamp-w: 4.75rem;
    --ola-line-w: 1px;
    --ola-dot-size: 11px;
    --ola-dot-new: 13px;
    --ola-dot-ring: 2px;
    --ola-title-size: 1.0625rem;
    --ola-title-lh: 1.45;
    --ola-feed-head-h: calc(var(--ola-title-size) * var(--ola-title-lh));
    --ola-brand: #4669c0;
    --ola-line: #959ea4;
    position: relative;
    padding-bottom: 0.25rem;
}

.ola-latest-feed__head {
    margin-bottom: 1.5rem;
    padding-bottom: 0.85rem;
    border-bottom: 1px solid #eef2f7;
}

.ola-latest-feed__sub {
    margin: 0.4rem 0 0;
    font-size: 0.875rem;
    color: #6b7280;
}

.ola-latest-feed__list {
    list-style: none;
    margin: 0;
    padding: 0.25rem 0 0;
    position: relative;
}

/* Thanh dọc liên tục — 1px, một màu xám */
.ola-latest-feed__list::before {
    content: "";
    position: absolute;
    left: calc(var(--ola-rail-w) / 2 - var(--ola-line-w) / 2);
    top: calc(var(--ola-feed-head-h) / 2);
    bottom: 1.25rem;
    width: var(--ola-line-w);
    background: var(--ola-line);
    border-radius: 1px;
    pointer-events: none;
    z-index: 0;
}

/* ── Item grid: rail | stamp | card ── */
.ola-latest-feed__item {
    --ola-feed-dot-active: var(--ola-dot-size);
    display: grid;
    grid-template-columns: var(--ola-rail-w) var(--ola-stamp-w) minmax(0, 1fr);
    column-gap: 0.65rem;
    align-items: start;
    position: relative;
    z-index: 1;
}

.ola-latest-feed__item:first-child {
    --ola-feed-dot-active: var(--ola-dot-new);
}

.ola-latest-feed__item:not(:first-child) {
    margin-top: 1.15rem;
}

/* ── Rail: dot thẳng hàng với ngày + tiêu đề; segment nối lên trên ── */
.ola-latest-feed__rail {
    position: relative;
    align-self: start;
    width: 100%;
    min-height: var(--ola-feed-head-h);
    display: flex;
    align-items: center;
    justify-content: center;
    padding-top: 0;
    flex-shrink: 0;
}

.ola-latest-feed__item:first-child .ola-latest-feed__rail {
    padding-top: 0;
}

/* Đoạn nối — absolute phía trên dot, không đẩy dot xuống */
.ola-latest-feed__segment {
    position: absolute;
    left: 50%;
    bottom: calc(50% - var(--ola-feed-dot-active) / 2);
    transform: translateX(-50%);
   /* width: var(--ola-line-w);*/
    height: calc(1.15rem + var(--ola-timeline-seg, 10px));
    min-height: 0;
    margin-bottom: 0;
    background: var(--ola-line);
    border-radius: 1px;
    flex: none;
}

.ola-latest-feed__item:first-child .ola-latest-feed__segment {
    display: none;
}

/* Dot — căn giữa hàng đầu (cùng hàng ngày + tiêu đề) */
.ola-latest-feed__dot {
    display: block;
    width: var(--ola-feed-dot-active);
    height: var(--ola-feed-dot-active);
    margin-top: 0;
    border-radius: 50%;
    background: var(--ola-line);
    border: var(--ola-dot-ring) solid #fff;
    box-shadow: 0 0 0 1px rgba(149, 158, 164, 0.35);
    position: relative;
    z-index: 2;
    flex-shrink: 0;
}

.ola-latest-feed__item:first-child .ola-latest-feed__dot {
    background: var(--ola-line);
    border-width: var(--ola-dot-ring);
    box-shadow: 0 0 0 0 rgba(149, 158, 164, 0.55);
    animation: olaTrendingLive 1.4s ease-out infinite;
}

@keyframes olaTrendingLive {
    0% {
        box-shadow: 0 0 0 0 rgba(149, 158, 164, 0.65);
    }

    70% {
        box-shadow: 0 0 0 9px rgba(149, 158, 164, 0);
    }

    100% {
        box-shadow: 0 0 0 0 rgba(149, 158, 164, 0);
    }
}

/* ── Stamp — dòng ngày thẳng hàng tiêu đề ── */
.ola-latest-feed__stamp {
    align-self: start;
    padding-top: 0;
    text-align: right;
}

.ola-latest-feed__item:first-child .ola-latest-feed__stamp {
    padding-top: 0;
}

.ola-latest-feed__time {
    display: block;
    line-height: 1.25;
}

.ola-latest-feed__time-main {
    display: flex;
    align-items: center;
    justify-content: flex-end;
    min-height: var(--ola-feed-head-h);
    font-size: 0.8125rem;
    font-weight: 700;
    color: #374151;
    letter-spacing: -0.01em;
    line-height: var(--ola-title-lh);
}

.ola-latest-feed__time-sub {
    display: block;
    margin-top: 0.12rem;
    font-size: 0.6875rem;
    font-weight: 600;
    color: #9ca3af;
    font-variant-numeric: tabular-nums;
    letter-spacing: 0.02em;
}

/* ── Card: body + thumb ── */
.ola-latest-feed__card {
    display: grid;
    grid-template-columns: minmax(0, 1fr) 140px;
    gap: 0 1rem;
    align-items: start;
    padding-top: 0;
    padding-bottom: 1.15rem;
    border-bottom: 1px solid #f1f5f9;
}

.ola-latest-feed__item:first-child .ola-latest-feed__card {
    padding-top: 0;
}

.ola-latest-feed__item:last-child .ola-latest-feed__card {
    border-bottom: none;
    padding-bottom: 0.5rem;
}

.ola-latest-feed__body {
    min-width: 0;
}

.ola-latest-feed__title {
    font-size: var(--ola-title-size);
    font-weight: 700;
    line-height: var(--ola-title-lh);
    margin: 0 0 0.35rem;
    min-height: var(--ola-feed-head-h);
    display: flex;
    align-items: center;
    letter-spacing: -0.015em;
}

.ola-latest-feed__title a {
    color: #1e1b4b;
    text-decoration: none;
    transition: color 0.18s ease;
    display: -webkit-box;
    -webkit-line-clamp: 2;
    -webkit-box-orient: vertical;
    overflow: hidden;
}

.ola-latest-feed__title a:hover {
    color: var(--ola-primary, #6d14a3);
}

.ola-latest-feed__meta {
    margin: 0 0 0.45rem;
    font-size: 0.8125rem;
    color: #6b7280;
    line-height: 1.4;
}

.ola-latest-feed__cat {
    font-weight: 600;
    color: #64748b;
}

.ola-latest-feed__excerpt {
    margin: 0;
    font-size: 0.9375rem;
    line-height: 1.58;
    color: #4b5563;
    display: -webkit-box;
    -webkit-line-clamp: 3;
    -webkit-box-orient: vertical;
    overflow: hidden;
}

.ola-latest-feed__thumb {
    display: block;
    width: 140px;
    overflow: hidden;
    border-radius: 8px;
    background: #f1f5f9;
    box-shadow: 0 1px 4px rgba(15, 23, 42, 0.06);
    flex-shrink: 0;
    line-height: 0;
}

.ola-latest-feed__thumb img,
a.ola-post-thumb-link.ola-latest-feed__thumb img {
    display: block;
    max-width: 100%;
    width: 100%;
    height: auto;
    aspect-ratio: 4 / 3;
    object-fit: cover;
    border-radius: 0;
    transition: transform 0.28s ease;
}

.ola-latest-feed__thumb:hover img {
    transform: scale(1.04);
}

.ola-latest-feed__video {
    display: inline-flex;
    align-items: center;
    gap: 0.2rem;
    margin-left: 0.35rem;
    font-size: 0.75rem;
    color: var(--ola-primary, #6d14a3);
    font-weight: 600;
}

.ola-latest-feed-page .ola-ad-slot--infeed {
    grid-column: 1 / -1;
    margin: 0.5rem 0 0.75rem;
    padding-left: calc(var(--ola-rail-w) + var(--ola-stamp-w) + 0.65rem);
}

@media (max-width: 767.98px) {
    .ola-latest-feed {
        --ola-stamp-w: 4.1rem;
        --ola-rail-w: 14px;
        --ola-dot-size: 10px;
        --ola-dot-new: 12px;
        --ola-dot-ring: 2px;
        --ola-title-size: 0.9375rem;
    }

    .ola-latest-feed__card {
        grid-template-columns: minmax(0, 1fr) 108px;
        gap: 0 0.65rem;
        padding-bottom: 1.1rem;
    }

    .ola-latest-feed__thumb {
        width: 108px;
        border-radius: 6px;
    }

    .ola-latest-feed__time-main {
        font-size: 0.75rem;
    }

    .ola-latest-feed__time-sub {
        font-size: 0.625rem;
    }

    .ola-latest-feed__title {
        font-size: var(--ola-title-size);
    }

    .ola-latest-feed__excerpt {
        display: none;
    }
}

@media (max-width: 479.98px) {
    .ola-latest-feed__card {
        grid-template-columns: minmax(0, 1fr);
    }

    .ola-latest-feed__thumb {
        width: 100%;
        max-width: 132px;
        margin-top: 0.45rem;
    }

    .ola-latest-feed-page .ola-ad-slot--infeed {
        padding-left: 0;
    }
}
