/*
    Path in theme: platform/themes/real-scout/public/css/home-page-new/blog.css
    Loaded via:    config.php's beforeRenderTheme, gated on the blog listing
                    (public.blog) and single-post (public.single) routes.
                    Same navy/gold design language as legal.css / site-footer.css,
                    but deliberately uses only the plain body font (no Playfair
                    Display) for headings too - keep it simple, not fancy.
*/

:root {
    --blog-navy: #1a1d24;
    --blog-navy-light: #22262f;
    --blog-gold: #e0a63e;
    --blog-gold-hover: #cf9530;
    --blog-white: #ffffff;
    --blog-text-muted: #c9cdd3;
    --blog-font: 'Poppins', -apple-system, BlinkMacSystemFont, 'Segoe UI', sans-serif;
    --blog-max-width: 1320px;
}

.blog-hero,
.blog-section,
.blog-post-hero {
    font-family: var(--blog-font);
    -webkit-font-smoothing: antialiased;
    box-sizing: border-box;
}

.blog-hero *,
.blog-section *,
.blog-post-hero * {
    box-sizing: border-box;
}

/* =========================================================
   HERO (listing page)
   ========================================================= */
.blog-hero {
    background: var(--blog-navy);
    padding: 64px 0 56px;
    text-align: center;
}

.blog-hero__inner {
    max-width: var(--blog-max-width);
    margin: 0 auto;
    padding: 0 24px;
}

.blog-hero__eyebrow {
    display: inline-block;
    color: var(--blog-gold);
    font-weight: 600;
    font-size: 13px;
    letter-spacing: 2px;
    text-transform: uppercase;
    margin-bottom: 14px;
}

.blog-hero__heading {
    font-weight: 600;
    color: var(--blog-white);
    font-size: 40px;
    line-height: 1.2;
    margin: 0 0 16px;
}

.blog-hero__breadcrumb {
    color: var(--blog-text-muted);
    font-size: 14px;
    margin: 0;
}

.blog-hero__breadcrumb a {
    color: var(--blog-text-muted);
    text-decoration: none;
    transition: color 0.2s ease;
}

.blog-hero__breadcrumb a:hover {
    color: var(--blog-gold);
}

.blog-hero__breadcrumb span {
    margin: 0 8px;
    color: rgba(255, 255, 255, 0.3);
}

/* =========================================================
   LAYOUT (listing + post share main/sidebar split)
   ========================================================= */
.blog-section {
    background: var(--blog-white);
    padding: 72px 0 90px;
}

.blog-section__inner {
    max-width: var(--blog-max-width);
    margin: 0 auto;
    padding: 0 24px;
    display: flex;
    gap: 48px;
    align-items: flex-start;
}

.blog-section__main {
    flex: 1;
    min-width: 0;
}

/* =========================================================
   POST CARD GRID (listing page + related posts)
   ========================================================= */
.blog-card-grid {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 32px;
}

.blog-card-grid--related {
    grid-template-columns: repeat(2, 1fr);
}

.blog-card {
    display: flex;
    flex-direction: column;
    border-radius: 12px;
    overflow: hidden;
    background: var(--blog-white);
    border: 1px solid #ececec;
    transition: box-shadow 0.2s ease, transform 0.2s ease;
}

.blog-card:hover {
    box-shadow: 0 16px 40px rgba(0, 0, 0, 0.1);
    transform: translateY(-2px);
}

.blog-card__image-link {
    display: block;
    aspect-ratio: 16 / 10;
    overflow: hidden;
    background: #f3f3f3;
}

.blog-card__image {
    width: 100%;
    height: 100%;
    object-fit: cover;
}

.blog-card__body {
    padding: 22px 22px 26px;
    display: flex;
    flex-direction: column;
    flex: 1;
}

.blog-card__category {
    display: inline-block;
    color: var(--blog-gold-hover);
    font-weight: 600;
    font-size: 12px;
    letter-spacing: 1px;
    text-transform: uppercase;
    margin-bottom: 10px;
}

.blog-card__title {
    font-size: 19px;
    font-weight: 600;
    line-height: 1.35;
    margin: 0 0 10px;
}

.blog-card__title a {
    color: var(--blog-navy);
    text-decoration: none;
}

.blog-card__title a:hover {
    color: var(--blog-gold-hover);
}

.blog-card__excerpt {
    color: #6b7280;
    font-size: 14px;
    line-height: 1.7;
    margin: 0 0 16px;
    flex: 1;
}

.blog-card__meta {
    display: flex;
    align-items: center;
    gap: 16px;
    color: #9ca3af;
    font-size: 13px;
    margin-top: auto;
}

.blog-card__meta span {
    display: inline-flex;
    align-items: center;
    gap: 6px;
}

.blog-card__meta i {
    color: var(--blog-gold);
    font-size: 12px;
}

.blog-section__empty {
    color: #6b7280;
    font-size: 15px;
    padding: 40px 0;
    text-align: center;
}

/* =========================================================
   PAGINATION
   ========================================================= */
.blog-pagination {
    margin-top: 48px;
    display: flex;
    justify-content: center;
}

.blog-pagination .pagination {
    display: flex;
    list-style: none;
    gap: 6px;
    margin: 0;
    padding: 0;
}

.blog-pagination .page-item .page-link {
    display: flex;
    align-items: center;
    justify-content: center;
    min-width: 38px;
    height: 38px;
    padding: 0 10px !important;
    border-radius: 8px !important;
    border: 1px solid #e5e5e5;
    color: var(--blog-navy);
    font-size: 14px;
    text-decoration: none;
    background: var(--blog-white);
}

.blog-pagination .page-item .page-link:hover {
    border-color: var(--blog-gold);
    color: var(--blog-gold-hover);
}

.blog-pagination .page-item.active .page-link {
    background: var(--blog-gold);
    border-color: var(--blog-gold);
    color: var(--blog-navy);
}

.blog-pagination .page-item.disabled .page-link {
    color: #c3c3c3;
}

/* =========================================================
   SIDEBAR
   ========================================================= */
.blog-sidebar {
    flex: 0 0 300px;
    display: flex;
    flex-direction: column;
    gap: 28px;
}

.blog-sidebar__widget {
    background: #f8f7f5;
    border-radius: 12px;
    padding: 24px;
}

.blog-sidebar__title {
    font-size: 15px;
    font-weight: 600;
    color: var(--blog-navy);
    margin: 0 0 16px;
    text-transform: uppercase;
    letter-spacing: 0.5px;
}

.blog-sidebar__list {
    list-style: none;
    margin: 0;
    padding: 0;
    display: flex;
    flex-direction: column;
    gap: 10px;
}

.blog-sidebar__list a {
    color: #4b5563;
    font-size: 14px;
    text-decoration: none;
}

.blog-sidebar__list a:hover {
    color: var(--blog-gold-hover);
}

.blog-sidebar__recent {
    list-style: none;
    margin: 0;
    padding: 0;
    display: flex;
    flex-direction: column;
    gap: 14px;
}

.blog-sidebar__recent-link {
    display: flex;
    align-items: center;
    gap: 12px;
    text-decoration: none;
}

.blog-sidebar__recent-link img {
    width: 56px;
    height: 56px;
    border-radius: 8px;
    object-fit: cover;
    flex-shrink: 0;
}

.blog-sidebar__recent-link span {
    color: var(--blog-navy);
    font-size: 13.5px;
    line-height: 1.4;
}

.blog-sidebar__recent-link:hover span {
    color: var(--blog-gold-hover);
}

/* =========================================================
   SINGLE POST HERO
   ========================================================= */
.blog-post-hero {
    background: var(--blog-navy);
    padding: 56px 0 48px;
    text-align: center;
}

.blog-post-hero__inner {
    max-width: 860px;
    margin: 0 auto;
    padding: 0 24px;
}

.blog-post-hero__category {
    display: inline-block;
    color: var(--blog-gold);
    font-weight: 600;
    font-size: 13px;
    letter-spacing: 2px;
    text-transform: uppercase;
    margin-bottom: 14px;
}

.blog-post-hero__title {
    font-weight: 600;
    color: var(--blog-white);
    font-size: 36px;
    line-height: 1.3;
    margin: 0 0 18px;
}

.blog-post-hero__meta {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 18px;
    color: var(--blog-text-muted);
    font-size: 13.5px;
    margin: 0 0 14px;
}

.blog-post-hero__meta span {
    display: inline-flex;
    align-items: center;
    gap: 6px;
}

.blog-post-hero__meta i {
    color: var(--blog-gold);
    font-size: 12px;
}

.blog-post-hero__breadcrumb {
    color: var(--blog-text-muted);
    font-size: 14px;
    margin: 0;
}

.blog-post-hero__breadcrumb a {
    color: var(--blog-text-muted);
    text-decoration: none;
}

.blog-post-hero__breadcrumb a:hover {
    color: var(--blog-gold);
}

.blog-post-hero__breadcrumb span {
    margin: 0 8px;
    color: rgba(255, 255, 255, 0.3);
}

/* =========================================================
   SINGLE POST CONTENT
   ========================================================= */
.blog-post-image {
    max-width: var(--blog-max-width);
    margin: -32px auto 0;
    padding: 0 24px;
}

.blog-post-image img {
    width: 100%;
    max-height: 460px;
    object-fit: cover;
    border-radius: 14px;
    display: block;
}

.blog-post-content {
    color: #4b5563;
    font-size: 15.5px;
    line-height: 1.85;
}

.blog-post-content p {
    margin: 0 0 18px;
}

.blog-post-content h2,
.blog-post-content h3,
.blog-post-content h4 {
    font-weight: 600;
    color: var(--blog-navy);
    margin: 28px 0 14px;
}

.blog-post-content ul,
.blog-post-content ol {
    margin: 0 0 18px;
    padding-left: 22px;
}

.blog-post-content img {
    max-width: 100%;
    height: auto;
    border-radius: 10px;
}

.blog-post-content a {
    color: var(--blog-gold-hover);
}

.blog-post-tags {
    display: flex;
    align-items: center;
    flex-wrap: wrap;
    gap: 10px;
    margin: 28px 0 0;
}

.blog-post-tags__label {
    color: var(--blog-navy);
    font-size: 13px;
    font-weight: 600;
}

.blog-post-tags a {
    display: inline-block;
    padding: 5px 14px;
    border-radius: 999px;
    background: rgba(224, 166, 62, 0.12);
    color: var(--blog-gold-hover);
    font-size: 12.5px;
    text-decoration: none;
}

.blog-post-tags a:hover {
    background: var(--blog-gold);
    color: var(--blog-white);
}

.blog-post-share {
    margin-top: 32px;
    padding-top: 28px;
    border-top: 1px solid #ececec;
}

/* Scoped overrides for the shared partials/share.blade.php markup (reused
   on property/project pages too, so only override it inside this wrapper). */
.blog-post-share #socialHolder {
    display: flex;
    align-items: center;
    gap: 14px;
}

.blog-post-share .btn-info {
    background-color: var(--blog-navy) !important;
    border-color: var(--blog-navy) !important;
}

.blog-post-share .btn-info:hover,
.blog-post-share .btn-info:focus {
    background-color: var(--blog-gold) !important;
    border-color: var(--blog-gold) !important;
}

.blog-post-related {
    margin-top: 64px;
}

.blog-post-related__title {
    font-size: 20px;
    font-weight: 600;
    color: var(--blog-navy);
    margin: 0 0 24px;
}

/* =========================================================
   RESPONSIVE
   ========================================================= */
@media (max-width: 1080px) {
    .blog-section__inner {
        flex-direction: column;
    }

    .blog-sidebar {
        flex: 1 1 auto;
        flex-direction: row;
        flex-wrap: wrap;
    }

    .blog-sidebar__widget {
        flex: 1 1 260px;
    }
}

@media (max-width: 860px) {
    .blog-card-grid,
    .blog-card-grid--related {
        grid-template-columns: repeat(2, 1fr);
    }
}

@media (max-width: 640px) {
    .blog-hero,
    .blog-post-hero {
        padding: 44px 0 36px;
    }

    .blog-hero__heading {
        font-size: 30px;
    }

    .blog-post-hero__title {
        font-size: 26px;
    }

    .blog-section {
        padding: 48px 0 64px;
    }

    .blog-card-grid,
    .blog-card-grid--related {
        grid-template-columns: 1fr;
    }

    .blog-sidebar {
        flex-direction: column;
    }

    .blog-post-image {
        margin-top: -20px;
    }
}
