/**********************************************************
    PrintZilla — Blog / News styles
    Loaded by blog.php and blog-post.php, after css/style.css.
    Kept in its own file so the blog can be dropped onto the
    server without touching the main stylesheet.
**********************************************************/

/*** Category filter chips ***/
.blog-filter {
    display: flex;
    flex-wrap: wrap;
    gap: .5rem;
}

.blog-chip {
    display: inline-flex;
    align-items: center;
    gap: .45rem;
    padding: .5rem 1rem;
    border-radius: 999px;
    border: 1px solid rgba(10, 15, 46, .12);
    background: #FFFFFF;
    color: var(--muted);
    font-size: .875rem;
    font-weight: 600;
    text-decoration: none;
    transition: all .25s ease;
}

.blog-chip:hover {
    color: var(--dark);
    border-color: var(--primary);
    box-shadow: var(--shadow-sm);
}

.blog-chip.active {
    background: var(--grad-primary);
    border-color: transparent;
    color: #FFFFFF;
}

.blog-chip-count {
    display: inline-block;
    min-width: 20px;
    padding: 0 .35rem;
    border-radius: 999px;
    background: rgba(10, 15, 46, .08);
    font-size: .75rem;
    text-align: center;
}

.blog-chip.active .blog-chip-count {
    background: rgba(255, 255, 255, .28);
}


/*** Post cards ***/
.blog-card {
    display: flex;
    flex-direction: column;
    background: #FFFFFF;
    border: 1px solid rgba(10, 15, 46, .08);
    border-radius: var(--radius);
    overflow: hidden;
    box-shadow: var(--shadow-sm);
    transition: transform .3s ease, box-shadow .3s ease;
}

.blog-card:hover {
    transform: translateY(-6px);
    box-shadow: var(--shadow-md);
}

.blog-card-media {
    position: relative;
    display: block;
    height: 220px;
    overflow: hidden;
    background: var(--light);
}

.blog-card-media-sm {
    height: 150px;
}

.blog-card-media img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    transition: transform .5s ease;
}

.blog-card:hover .blog-card-media img {
    transform: scale(1.06);
}

.blog-card-placeholder {
    display: flex;
    align-items: center;
    justify-content: center;
    width: 100%;
    height: 100%;
    background: var(--grad-dark);
    color: rgba(255, 255, 255, .35);
    font-size: 2.5rem;
}

.blog-card-tag {
    position: absolute;
    left: 14px;
    bottom: 14px;
    padding: .35rem .8rem;
    border-radius: 999px;
    background: var(--grad-primary);
    color: #FFFFFF;
    font-size: .75rem;
    font-weight: 700;
    letter-spacing: .02em;
    box-shadow: var(--shadow-sm);
}

.blog-card-body {
    display: flex;
    flex-direction: column;
    flex: 1 1 auto;
    padding: 1.5rem;
}

.blog-card-body h2 a,
.blog-card-body h3 a {
    color: var(--dark);
    text-decoration: none;
}

.blog-card-body h2 a:hover,
.blog-card-body h3 a:hover {
    color: var(--primary);
}

.blog-card-body p {
    color: var(--muted);
    font-size: .95rem;
    line-height: 1.7;
}

.blog-readmore {
    margin-top: auto;
    align-self: flex-start;
    color: var(--primary);
    font-weight: 700;
    font-size: .9rem;
    text-decoration: none;
}

.blog-readmore:hover {
    color: var(--dark);
}

.blog-readmore i {
    transition: transform .25s ease;
}

.blog-readmore:hover i {
    transform: translateX(4px);
}


/*** Meta line (date, comments, reading time) ***/
.blog-meta {
    display: flex;
    flex-wrap: wrap;
    gap: 1rem;
    color: var(--muted);
    font-size: .82rem;
    font-weight: 500;
}

.blog-meta i {
    color: var(--primary);
}

.blog-meta-light {
    color: #C6CBE0;
}

.blog-meta-light i {
    color: var(--primary-2);
}


/*** Empty state ***/
.blog-empty {
    border: 2px dashed rgba(10, 15, 46, .12);
    border-radius: var(--radius);
    background: var(--light);
}

.blog-empty i {
    font-size: 3rem;
    color: rgba(10, 15, 46, .18);
}


/*** Sidebar widgets ***/
.blog-sidebar {
    position: sticky;
    top: 110px;
}

.blog-widget {
    padding: 1.5rem;
    background: #FFFFFF;
    border: 1px solid rgba(10, 15, 46, .08);
    border-radius: var(--radius);
    box-shadow: var(--shadow-sm);
}

.blog-widget-title {
    position: relative;
    margin-bottom: 1.25rem;
    padding-bottom: .65rem;
    font-weight: 700;
    letter-spacing: .01em;
    text-transform: uppercase;
}

.blog-widget-title::after {
    content: "";
    position: absolute;
    left: 0;
    bottom: 0;
    width: 42px;
    height: 3px;
    border-radius: 2px;
    background: var(--grad-primary);
}

.blog-cat-list {
    margin: 0;
    padding: 0;
    list-style: none;
}

.blog-cat-list li + li {
    border-top: 1px solid rgba(10, 15, 46, .07);
}

.blog-cat-list a {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: .75rem;
    padding: .7rem 0;
    color: var(--muted);
    font-weight: 600;
    font-size: .92rem;
    text-decoration: none;
}

.blog-cat-list a:hover,
.blog-cat-list a.active {
    color: var(--primary);
}

.blog-cat-list .badge {
    background: var(--light);
    color: var(--muted);
    font-weight: 600;
}

.blog-cat-list a:hover .badge,
.blog-cat-list a.active .badge {
    background: var(--primary);
    color: #FFFFFF;
}

.blog-recent {
    display: flex;
    align-items: center;
    gap: .9rem;
    padding: .7rem 0;
    text-decoration: none;
}

.blog-recent + .blog-recent {
    border-top: 1px solid rgba(10, 15, 46, .07);
}

.blog-recent img,
.blog-recent-placeholder {
    flex: 0 0 auto;
    width: 64px;
    height: 56px;
    border-radius: var(--radius-sm);
    object-fit: cover;
}

.blog-recent-placeholder {
    display: flex;
    align-items: center;
    justify-content: center;
    background: var(--grad-dark);
    color: rgba(255, 255, 255, .35);
}

.blog-recent strong {
    display: block;
    color: var(--dark);
    font-size: .9rem;
    font-weight: 600;
    line-height: 1.45;
}

.blog-recent:hover strong {
    color: var(--primary);
}

.blog-recent small {
    color: var(--muted);
    font-size: .78rem;
}

.blog-cta {
    background: var(--grad-dark);
    border: none;
    color: #C6CBE0;
}

.blog-cta p {
    color: #C6CBE0;
    font-size: .95rem;
}


/*** Single post ***/
.blog-header-tag {
    display: inline-block;
    padding: .4rem 1rem;
    border-radius: 999px;
    background: var(--grad-primary);
    color: #FFFFFF;
    font-size: .8rem;
    font-weight: 700;
    text-decoration: none;
}

.blog-header-tag:hover {
    color: #FFFFFF;
    opacity: .9;
}

.blog-article {
    max-width: 100%;
}

.blog-article-hero {
    width: 100%;
    max-height: 480px;
    object-fit: cover;
    border-radius: var(--radius);
    box-shadow: var(--shadow-md);
}

.blog-article-lead {
    padding-left: 1.1rem;
    border-left: 4px solid;
    border-image: var(--grad-primary) 1;
    color: var(--dark);
    font-size: 1.15rem;
    font-weight: 500;
    line-height: 1.75;
}

.blog-article-body {
    font-size: 1.04rem;
    line-height: 1.85;
    color: var(--ink);
}

.blog-article-body h2,
.blog-article-body h3,
.blog-article-body h4 {
    margin-top: 2.25rem;
    margin-bottom: .9rem;
}

.blog-article-body h2 { font-size: 1.65rem; }
.blog-article-body h3 { font-size: 1.3rem; }

.blog-article-body p,
.blog-article-body ul,
.blog-article-body ol {
    margin-bottom: 1.25rem;
}

.blog-article-body ul,
.blog-article-body ol {
    padding-left: 1.4rem;
}

.blog-article-body li {
    margin-bottom: .5rem;
}

.blog-article-body img {
    max-width: 100%;
    height: auto;
    margin: 1.5rem 0;
    border-radius: var(--radius-sm);
    box-shadow: var(--shadow-sm);
}

.blog-article-body a {
    color: var(--primary);
    font-weight: 600;
    text-decoration: underline;
}

.blog-article-body a:hover {
    color: var(--dark);
}

.blog-article-body blockquote {
    margin: 1.75rem 0;
    padding: 1.25rem 1.5rem;
    border-left: 4px solid var(--primary);
    border-radius: 0 var(--radius-sm) var(--radius-sm) 0;
    background: var(--light);
    font-size: 1.08rem;
    font-style: italic;
}

.blog-article-body pre {
    padding: 1.1rem;
    border-radius: var(--radius-sm);
    background: var(--dark);
    color: #E8EAF6;
    overflow-x: auto;
}

.blog-article-body table {
    width: 100%;
    margin-bottom: 1.5rem;
    border-collapse: collapse;
}

.blog-article-body th,
.blog-article-body td {
    padding: .7rem .9rem;
    border: 1px solid rgba(10, 15, 46, .12);
}

.blog-article-body th {
    background: var(--light);
    font-weight: 700;
}

.blog-share {
    display: flex;
    flex-wrap: wrap;
    align-items: center;
    gap: .5rem;
    padding-top: 1.5rem;
    border-top: 1px solid rgba(10, 15, 46, .08);
}

.blog-share .btn-square {
    background: var(--light);
    color: var(--primary);
}

.blog-share .btn-square:hover {
    background: var(--grad-primary);
    color: #FFFFFF;
}


/*** Comments ***/
.blog-comments {
    padding-top: 2rem;
    border-top: 1px solid rgba(10, 15, 46, .08);
}

.blog-comment {
    display: flex;
    gap: 1rem;
    padding: 1.25rem;
    margin-bottom: 1rem;
    border-radius: var(--radius);
    background: var(--light);
}

.blog-comment-avatar {
    flex: 0 0 auto;
    display: flex;
    align-items: center;
    justify-content: center;
    width: 48px;
    height: 48px;
    border-radius: 50%;
    background: var(--grad-primary);
    color: #FFFFFF;
    font-family: 'Sora', sans-serif;
    font-weight: 700;
    font-size: 1.15rem;
}

.blog-comment-body p {
    color: var(--ink);
    font-size: .96rem;
    line-height: 1.7;
}

.blog-comment-form {
    padding: 1.75rem;
    border: 1px solid rgba(10, 15, 46, .08);
    border-radius: var(--radius);
    background: #FFFFFF;
    box-shadow: var(--shadow-sm);
}


/*** Pagination ***/
.pagination .page-link {
    margin: 0 .2rem;
    padding: .65rem 1rem;
    border: 1px solid rgba(10, 15, 46, .1);
    border-radius: var(--radius-sm);
    color: var(--muted);
    font-weight: 600;
}

.pagination .page-link:hover {
    background: var(--light);
    color: var(--primary);
}

.pagination .page-item.active .page-link {
    background: var(--grad-primary);
    border-color: transparent;
    color: #FFFFFF;
}

.pagination .page-item.disabled .page-link {
    opacity: .5;
}


@media (max-width: 991.98px) {
    .blog-sidebar {
        position: static;
    }

    .blog-card-media {
        height: 200px;
    }

    .blog-article-body {
        font-size: 1rem;
    }
}
