/* ==========================================================
   BLOG STYLES — Public-Facing Blog Listing & Single Post
   Corporate cyberpunk theme with SEO-optimized typography.
   ========================================================== */

/* ── Blog Grid ────────────────────────────────────────────── */
.blog-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(340px, 1fr));
    gap: 2rem;
}

/* ── Blog Card ────────────────────────────────────────────── */
.blog-card {
    background: rgba(33, 38, 45, 0.6);
    border: 1px solid rgba(48, 54, 61, 0.8);
    border-radius: 14px;
    overflow: hidden;
    transition: transform 0.35s ease, box-shadow 0.35s ease, border-color 0.35s ease;
    display: flex;
    flex-direction: column;
}

.blog-card:hover {
    transform: translateY(-6px);
    border-color: rgba(255, 107, 53, 0.3);
    box-shadow:
        0 20px 50px rgba(0, 0, 0, 0.35),
        0 0 30px rgba(255, 107, 53, 0.06);
}

.blog-card--featured {
    border-color: rgba(255, 107, 53, 0.2);
    box-shadow: 0 0 25px rgba(255, 107, 53, 0.04);
}

/* Image area */
.blog-card__image {
    display: block;
    position: relative;
    aspect-ratio: 16 / 9;
    overflow: hidden;
    background: linear-gradient(135deg, #161B22 0%, #21262D 100%);
}

.blog-card__image img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    transition: transform 0.5s ease, filter 0.5s ease;
}

.blog-card:hover .blog-card__image img {
    transform: scale(1.06);
    filter: brightness(1.1);
}

.blog-card__placeholder {
    width: 100%;
    height: 100%;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 3rem;
    color: rgba(255, 107, 53, 0.2);
    background: linear-gradient(135deg, rgba(255, 107, 53, 0.03) 0%, rgba(99, 102, 241, 0.03) 100%);
}

.blog-card:hover .blog-card__placeholder {
    color: rgba(255, 107, 53, 0.35);
}

/* Featured / Category badges */
.blog-card__badge {
    position: absolute;
    top: 12px;
    right: 12px;
    padding: 5px 12px;
    border-radius: 20px;
    font-size: 0.7rem;
    font-weight: 700;
    text-transform: uppercase;
    letter-spacing: 0.05em;
    backdrop-filter: blur(12px);
    -webkit-backdrop-filter: blur(12px);
}

.blog-card__badge--featured {
    background: rgba(255, 107, 53, 0.85);
    color: #000;
}

/* Card body */
.blog-card__body {
    padding: 1.5rem;
    display: flex;
    flex-direction: column;
    flex-grow: 1;
}

.blog-card__category {
    display: inline-block;
    width: fit-content;
    padding: 4px 12px;
    border-radius: 20px;
    font-size: 0.72rem;
    font-weight: 700;
    text-transform: uppercase;
    letter-spacing: 0.06em;
    color: var(--cat-color, #FF6B35);
    background: color-mix(in srgb, var(--cat-color, #FF6B35) 12%, transparent);
    border: 1px solid color-mix(in srgb, var(--cat-color, #FF6B35) 20%, transparent);
    text-decoration: none;
    margin-bottom: 0.75rem;
    transition: background 0.3s ease;
}

.blog-card__category:hover {
    background: color-mix(in srgb, var(--cat-color, #FF6B35) 22%, transparent);
    text-decoration: none;
}

/* Title */
.blog-card__title {
    font-size: 1.2rem;
    font-weight: 700;
    line-height: 1.35;
    margin-bottom: 0.6rem;
    color: #F0F6FC;
}

.blog-card__title a {
    color: inherit;
    text-decoration: none;
    transition: color 0.3s ease;
}

.blog-card__title a:hover {
    color: #FF6B35;
}

/* Excerpt */
.blog-card__excerpt {
    color: rgba(240, 246, 252, 0.55);
    font-size: 0.92rem;
    line-height: 1.65;
    margin-bottom: 1rem;
    flex-grow: 1;
    display: -webkit-box;
    -webkit-line-clamp: 3;
    -webkit-box-orient: vertical;
    overflow: hidden;
}

/* Meta row */
.blog-card__meta {
    display: flex;
    flex-wrap: wrap;
    gap: 0.75rem;
    font-size: 0.78rem;
    color: rgba(240, 246, 252, 0.4);
    padding-top: 0.75rem;
    border-top: 1px solid rgba(48, 54, 61, 0.6);
    margin-top: auto;
}

.blog-card__meta i {
    margin-right: 4px;
    color: rgba(255, 107, 53, 0.5);
}


/* ── Category Filter Tabs ─────────────────────────────────── */
.blog-filters {
    display: flex;
    flex-wrap: wrap;
    gap: 0.6rem;
    margin-bottom: 2.5rem;
    justify-content: center;
}

.blog-filter {
    padding: 8px 20px;
    border-radius: 24px;
    font-size: 0.85rem;
    font-weight: 600;
    color: rgba(240, 246, 252, 0.6);
    background: rgba(33, 38, 45, 0.6);
    border: 1px solid rgba(48, 54, 61, 0.8);
    text-decoration: none;
    transition: all 0.3s ease;
}

.blog-filter:hover,
.blog-filter--active {
    color: #000;
    background: #FF6B35;
    border-color: #FF6B35;
    text-decoration: none;
}

.blog-filter i {
    margin-right: 6px;
}


/* ── Pagination ───────────────────────────────────────────── */
.blog-pagination {
    display: flex;
    justify-content: center;
    gap: 0.5rem;
    margin-top: 3rem;
}

.blog-pagination a,
.blog-pagination span {
    display: flex;
    align-items: center;
    justify-content: center;
    min-width: 42px;
    height: 42px;
    padding: 0 14px;
    border-radius: 10px;
    font-size: 0.9rem;
    font-weight: 600;
    text-decoration: none;
    transition: all 0.3s ease;
    border: 1px solid rgba(48, 54, 61, 0.8);
    background: rgba(33, 38, 45, 0.6);
    color: rgba(240, 246, 252, 0.6);
}

.blog-pagination a:hover {
    background: rgba(255, 107, 53, 0.15);
    border-color: rgba(255, 107, 53, 0.3);
    color: #FF6B35;
}

.blog-pagination .current {
    background: #FF6B35;
    border-color: #FF6B35;
    color: #000;
}


/* ── Single Post Layout ───────────────────────────────────── */
.blog-single {
    max-width: 800px;
    margin: 0 auto;
}

.blog-single__header {
    margin-bottom: 2.5rem;
    text-align: center;
}

.blog-single__category {
    display: inline-block;
    padding: 5px 16px;
    border-radius: 24px;
    font-size: 0.75rem;
    font-weight: 700;
    text-transform: uppercase;
    letter-spacing: 0.06em;
    margin-bottom: 1rem;
    text-decoration: none;
    color: var(--cat-color, #FF6B35);
    background: color-mix(in srgb, var(--cat-color, #FF6B35) 12%, transparent);
    border: 1px solid color-mix(in srgb, var(--cat-color, #FF6B35) 20%, transparent);
}

.blog-single__title {
    font-size: 2.4rem;
    font-weight: 800;
    line-height: 1.2;
    color: #F0F6FC;
    margin-bottom: 1.25rem;
    letter-spacing: -0.02em;
}

.blog-single__meta {
    display: flex;
    flex-wrap: wrap;
    justify-content: center;
    gap: 1.5rem;
    font-size: 0.88rem;
    color: rgba(240, 246, 252, 0.45);
}

.blog-single__meta i {
    margin-right: 5px;
    color: rgba(255, 107, 53, 0.5);
}

/* Featured image */
.blog-single__hero-image {
    border-radius: 14px;
    overflow: hidden;
    margin-bottom: 2.5rem;
    border: 1px solid rgba(48, 54, 61, 0.6);
}

.blog-single__hero-image img {
    width: 100%;
    height: auto;
    display: block;
}

/* Post body (prose) */
.blog-single__content {
    font-size: 1.05rem;
    line-height: 1.85;
    color: rgba(240, 246, 252, 0.75);
}

.blog-single__content h2 {
    font-size: 1.6rem;
    font-weight: 700;
    color: #F0F6FC;
    margin: 2.5rem 0 1rem;
    letter-spacing: -0.01em;
}

.blog-single__content h3 {
    font-size: 1.3rem;
    font-weight: 700;
    color: #F0F6FC;
    margin: 2rem 0 0.75rem;
}

.blog-single__content p {
    margin-bottom: 1.25rem;
}

.blog-single__content ul,
.blog-single__content ol {
    margin: 1rem 0 1.5rem 1.5rem;
    padding-left: 1rem;
}

.blog-single__content li {
    margin-bottom: 0.5rem;
}

.blog-single__content a {
    color: #FF6B35;
    text-decoration: underline;
    text-underline-offset: 3px;
}

.blog-single__content a:hover {
    color: #FFD23F;
}

.blog-single__content blockquote {
    border-left: 3px solid #FF6B35;
    padding: 1rem 1.5rem;
    margin: 1.5rem 0;
    background: rgba(255, 107, 53, 0.04);
    border-radius: 0 10px 10px 0;
    font-style: italic;
    color: rgba(240, 246, 252, 0.65);
}

.blog-single__content code {
    padding: 2px 8px;
    border-radius: 6px;
    background: rgba(255, 107, 53, 0.08);
    color: #FF6B35;
    font-size: 0.88em;
    font-family: 'JetBrains Mono', 'Fira Code', monospace;
}

.blog-single__content pre {
    padding: 1.25rem;
    border-radius: 12px;
    background: rgba(13, 17, 23, 0.8);
    border: 1px solid rgba(48, 54, 61, 0.6);
    overflow-x: auto;
    margin: 1.5rem 0;
}

.blog-single__content pre code {
    padding: 0;
    background: none;
    color: rgba(240, 246, 252, 0.8);
}

.blog-single__content img {
    max-width: 100%;
    height: auto;
    border-radius: 10px;
    margin: 1.5rem 0;
}

/* Tags row */
.blog-single__tags {
    display: flex;
    flex-wrap: wrap;
    gap: 0.5rem;
    margin-top: 2.5rem;
    padding-top: 1.5rem;
    border-top: 1px solid rgba(48, 54, 61, 0.6);
}

.blog-tag {
    padding: 5px 14px;
    border-radius: 20px;
    font-size: 0.78rem;
    font-weight: 600;
    color: rgba(240, 246, 252, 0.5);
    background: rgba(33, 38, 45, 0.6);
    border: 1px solid rgba(48, 54, 61, 0.6);
    text-decoration: none;
    transition: all 0.3s ease;
}

.blog-tag:hover {
    background: rgba(255, 107, 53, 0.12);
    border-color: rgba(255, 107, 53, 0.25);
    color: #FF6B35;
}

/* Share / author box */
.blog-single__share {
    display: flex;
    align-items: center;
    gap: 1rem;
    margin-top: 2rem;
    padding: 1.5rem;
    border-radius: 14px;
    background: rgba(33, 38, 45, 0.6);
    border: 1px solid rgba(48, 54, 61, 0.6);
}

.blog-single__share-label {
    font-size: 0.85rem;
    font-weight: 600;
    color: rgba(240, 246, 252, 0.6);
    margin-right: 0.5rem;
}

.blog-single__share a {
    width: 38px;
    height: 38px;
    display: flex;
    align-items: center;
    justify-content: center;
    border-radius: 10px;
    background: rgba(255, 107, 53, 0.08);
    color: rgba(240, 246, 252, 0.6);
    text-decoration: none;
    transition: all 0.3s ease;
    font-size: 0.95rem;
}

.blog-single__share a:hover {
    background: rgba(255, 107, 53, 0.2);
    color: #FF6B35;
}

/* Related posts */
.blog-related {
    margin-top: 4rem;
    padding-top: 3rem;
    border-top: 1px solid rgba(48, 54, 61, 0.6);
}

.blog-related__title {
    font-size: 1.5rem;
    font-weight: 700;
    color: #F0F6FC;
    margin-bottom: 2rem;
    text-align: center;
}


/* ── Sidebar ──────────────────────────────────────────────── */
.blog-sidebar__widget {
    background: rgba(33, 38, 45, 0.6);
    border: 1px solid rgba(48, 54, 61, 0.8);
    border-radius: 14px;
    padding: 1.5rem;
    margin-bottom: 1.5rem;
}

.blog-sidebar__widget-title {
    font-size: 1rem;
    font-weight: 700;
    color: #F0F6FC;
    margin-bottom: 1rem;
    padding-bottom: 0.75rem;
    border-bottom: 1px solid rgba(48, 54, 61, 0.6);
}

.blog-sidebar__cat-list {
    list-style: none;
    padding: 0;
    margin: 0;
}

.blog-sidebar__cat-list li {
    margin-bottom: 0.5rem;
}

.blog-sidebar__cat-list a {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 8px 12px;
    border-radius: 8px;
    color: rgba(240, 246, 252, 0.6);
    text-decoration: none;
    font-size: 0.9rem;
    transition: all 0.3s ease;
}

.blog-sidebar__cat-list a:hover {
    background: rgba(255, 107, 53, 0.08);
    color: #FF6B35;
}

.blog-sidebar__cat-count {
    font-size: 0.75rem;
    padding: 2px 8px;
    border-radius: 12px;
    background: rgba(255, 107, 53, 0.1);
    color: #FF6B35;
    font-weight: 600;
}


/* ── Empty state ──────────────────────────────────────────── */
.blog-empty {
    text-align: center;
    padding: 4rem 2rem;
}

.blog-empty__icon {
    font-size: 3.5rem;
    color: rgba(255, 107, 53, 0.2);
    margin-bottom: 1.5rem;
}

.blog-empty__title {
    font-size: 1.3rem;
    font-weight: 700;
    color: #F0F6FC;
    margin-bottom: 0.75rem;
}

.blog-empty__text {
    color: rgba(240, 246, 252, 0.45);
    margin-bottom: 1.5rem;
    max-width: 420px;
    margin-left: auto;
    margin-right: auto;
}


/* ── Responsive ───────────────────────────────────────────── */
@media (max-width: 768px) {
    .blog-grid {
        grid-template-columns: 1fr;
        gap: 1.5rem;
    }

    .blog-single__title {
        font-size: 1.7rem;
    }

    .blog-single__meta {
        gap: 0.75rem;
        font-size: 0.8rem;
    }

    .blog-single__content {
        font-size: 1rem;
    }

    .blog-filters {
        gap: 0.5rem;
    }
}

@media (max-width: 480px) {
    .blog-card__body {
        padding: 1.15rem;
    }

    .blog-card__title {
        font-size: 1.05rem;
    }
}