/* AboStream Blog — Adapted from StreamAvis Blog Pro */
/* Colors: primary #6366f1, accent #06b6d4, bg #0a0a1a */

/* === READING PROGRESS BAR === */
.article-progress { position: fixed; top: 0; left: 0; width: 100%; height: 3px; z-index: 9999; background: transparent; }
.article-progress-bar { height: 100%; width: 0; background: linear-gradient(90deg, #6366f1, #06b6d4); transition: width 50ms linear; }

/* === BREADCRUMBS === */
.article-breadcrumbs { padding: 16px 0; border-bottom: 1px solid rgba(255,255,255,0.06); }
.article-breadcrumbs .container { display: flex; align-items: center; gap: 6px; font-size: 0.82rem; color: rgba(255,255,255,0.4); flex-wrap: wrap; }
.article-breadcrumbs a { color: rgba(255,255,255,0.5); text-decoration: none; transition: color 0.2s; }
.article-breadcrumbs a:hover { color: #818cf8; }
.article-breadcrumbs svg { opacity: 0.4; flex-shrink: 0; }

/* === ARTICLE HERO === */
.article-hero { padding: 48px 0 32px; text-align: center; }
.article-cat-badge { display: inline-block; padding: 5px 16px; border-radius: 50px; background: rgba(99,102,241,0.15); border: 1px solid rgba(99,102,241,0.3); color: #818cf8; font-size: 0.78rem; font-weight: 600; text-transform: uppercase; letter-spacing: 0.5px; text-decoration: none; margin-bottom: 16px; transition: background 0.2s; }
.article-cat-badge:hover { background: rgba(99,102,241,0.25); }
.article-hero h1 { font-size: clamp(1.8rem, 4vw, 2.6rem); font-weight: 800; line-height: 1.2; margin: 0 auto 20px; max-width: 820px; color: #fff; }
.article-meta-bar { display: flex; align-items: center; justify-content: center; gap: 8px; font-size: 0.85rem; color: rgba(255,255,255,0.5); flex-wrap: wrap; }
.article-meta-bar svg { vertical-align: -2px; margin-right: 2px; opacity: 0.6; }
.article-meta-dot { width: 3px; height: 3px; border-radius: 50%; background: rgba(255,255,255,0.3); }

/* === FEATURED IMAGE === */
.article-featured-img { padding: 0 0 32px; text-align: center; }
.article-featured-img img { max-width: 900px; width: 100%; height: auto; border-radius: 12px; box-shadow: 0 8px 32px rgba(0,0,0,0.4); }

/* === ARTICLE LAYOUT (sidebar + content) === */
.article-layout { padding: 0 0 48px; }
.article-layout > .container { display: grid; grid-template-columns: 220px 1fr; gap: 48px; align-items: start; }

/* === SIDEBAR === */
.article-sidebar { position: sticky; top: 88px; display: flex; flex-direction: column; gap: 24px; }
.article-toc, .article-share { background: rgba(255,255,255,0.03); border: 1px solid rgba(255,255,255,0.06); border-radius: 12px; padding: 20px; }
.article-toc h3, .article-share h3 { font-size: 0.82rem; font-weight: 700; text-transform: uppercase; letter-spacing: 0.5px; color: rgba(255,255,255,0.5); margin: 0 0 12px; }
.article-toc ol { list-style: none; padding: 0; margin: 0; counter-reset: toc; }
.article-toc li { counter-increment: toc; }
.article-toc a { display: block; padding: 6px 0 6px 24px; font-size: 0.82rem; color: rgba(255,255,255,0.55); text-decoration: none; line-height: 1.4; border-left: 2px solid transparent; transition: all 0.2s; position: relative; }
.article-toc a::before { content: counter(toc) "."; position: absolute; left: 4px; color: rgba(255,255,255,0.3); font-size: 0.75rem; font-weight: 600; }
.article-toc a:hover { color: #818cf8; border-left-color: rgba(99,102,241,0.3); }
.article-toc a.active { color: #818cf8; border-left-color: #6366f1; font-weight: 600; }
.share-buttons { display: flex; gap: 8px; flex-wrap: wrap; }
.share-btn { width: 38px; height: 38px; border-radius: 50%; display: flex; align-items: center; justify-content: center; background: rgba(255,255,255,0.06); border: 1px solid rgba(255,255,255,0.08); color: rgba(255,255,255,0.6); text-decoration: none; cursor: pointer; transition: all 0.2s; }
.share-btn:hover { background: rgba(99,102,241,0.15); color: #818cf8; border-color: rgba(99,102,241,0.3); transform: translateY(-2px); }
.share-copy.copied { background: rgba(6,182,212,0.15); color: #22d3ee; border-color: rgba(6,182,212,0.3); }

/* === ARTICLE CONTENT === */
.article-content { max-width: 720px; font-size: 1.02rem; line-height: 1.85; color: rgba(255,255,255,0.7); }
.article-content h2 { font-size: 1.55rem; font-weight: 700; color: #fff; margin: 48px 0 16px; padding-bottom: 12px; border-bottom: 1px solid rgba(255,255,255,0.08); scroll-margin-top: 90px; }
.article-content h3 { font-size: 1.2rem; font-weight: 600; color: rgba(255,255,255,0.9); margin: 32px 0 12px; }
.article-content h4 { font-size: 1.05rem; font-weight: 600; color: rgba(255,255,255,0.85); margin: 24px 0 8px; }
.article-content p { margin: 0 0 20px; }
.article-content a { color: #818cf8; text-decoration: underline; text-underline-offset: 3px; transition: color 0.2s; }
.article-content a:hover { color: #22d3ee; }
.article-content strong { color: rgba(255,255,255,0.9); font-weight: 600; }
.article-content ul, .article-content ol { margin: 0 0 24px; padding: 0 0 0 8px; }
.article-content ul { list-style: none; }
.article-content ul li { position: relative; padding-left: 20px; margin-bottom: 10px; }
.article-content ul li::before { content: ""; position: absolute; left: 0; top: 10px; width: 6px; height: 6px; border-radius: 50%; background: #6366f1; }
.article-content ol { list-style: none; counter-reset: ol-counter; }
.article-content ol li { counter-increment: ol-counter; position: relative; padding-left: 28px; margin-bottom: 10px; }
.article-content ol li::before { content: counter(ol-counter); position: absolute; left: 0; top: 0; width: 22px; height: 22px; border-radius: 50%; background: rgba(99,102,241,0.15); color: #818cf8; font-size: 0.75rem; font-weight: 700; display: flex; align-items: center; justify-content: center; }
.article-content blockquote { margin: 24px 0; padding: 16px 20px; border-left: 3px solid #6366f1; background: rgba(99,102,241,0.06); border-radius: 0 8px 8px 0; font-style: italic; color: rgba(255,255,255,0.75); }
.article-content img { max-width: 100%; height: auto; border-radius: 8px; margin: 16px 0; }
.article-content table { width: 100%; border-collapse: collapse; margin: 24px 0; font-size: 0.92rem; }
.article-content th { background: rgba(99,102,241,0.12); color: #818cf8; font-weight: 600; text-align: left; padding: 10px 14px; }
.article-content td { padding: 10px 14px; border-bottom: 1px solid rgba(255,255,255,0.06); color: rgba(255,255,255,0.7); }
.article-content code { background: rgba(255,255,255,0.06); padding: 2px 6px; border-radius: 4px; font-size: 0.88em; color: #22d3ee; }
.article-content pre { background: rgba(255,255,255,0.04); border: 1px solid rgba(255,255,255,0.06); border-radius: 8px; padding: 16px; overflow-x: auto; margin: 24px 0; }
.article-content pre code { background: none; padding: 0; }

/* === TAGS === */
.article-tags { padding: 0 0 32px; }
.article-tags .container { display: flex; gap: 8px; flex-wrap: wrap; }
.article-tags a { display: inline-block; padding: 5px 14px; border-radius: 50px; border: 1px solid rgba(255,255,255,0.1); color: rgba(255,255,255,0.5); font-size: 0.82rem; text-decoration: none; transition: all 0.2s; }
.article-tags a:hover { border-color: rgba(99,102,241,0.4); color: #818cf8; background: rgba(99,102,241,0.08); }

/* === CTA BOX === */
.article-cta { padding: 0 0 48px; }
.cta-box { background: linear-gradient(135deg, rgba(99,102,241,0.12), rgba(6,182,212,0.08)); border: 1px solid rgba(99,102,241,0.2); border-radius: 16px; padding: 40px; text-align: center; }
.cta-icon { margin-bottom: 16px; }
.cta-box h3 { font-size: 1.4rem; font-weight: 700; color: #fff; margin: 0 0 8px; }
.cta-box p { color: rgba(255,255,255,0.6); margin: 0 0 20px; font-size: 0.95rem; }
.cta-button { display: inline-flex; align-items: center; gap: 8px; padding: 12px 28px; border-radius: 50px; background: linear-gradient(135deg, #6366f1, #06b6d4); color: #fff; font-weight: 600; font-size: 0.95rem; text-decoration: none; transition: all 0.3s; box-shadow: 0 4px 16px rgba(99,102,241,0.3); }
.cta-button:hover { transform: translateY(-2px); box-shadow: 0 6px 24px rgba(99,102,241,0.4); }

/* === RELATED POSTS === */
.related-section { padding: 48px 0 64px; border-top: 1px solid rgba(255,255,255,0.06); }
.related-section h2 { font-size: 1.4rem; font-weight: 700; color: #fff; margin: 0 0 28px; }
.related-grid { display: grid; grid-template-columns: repeat(3, 1fr); gap: 24px; }
.related-card { background: rgba(255,255,255,0.03); border: 1px solid rgba(255,255,255,0.06); border-radius: 12px; overflow: hidden; text-decoration: none; transition: all 0.3s; }
.related-card:hover { transform: translateY(-4px); border-color: rgba(99,102,241,0.3); box-shadow: 0 8px 32px rgba(0,0,0,0.3); }
.related-card-img { position: relative; aspect-ratio: 16/9; overflow: hidden; background: linear-gradient(135deg, #0f0f24, #1a1a3e); }
.related-card-img img { width: 100%; height: 100%; object-fit: cover; }
.related-card-placeholder { display: flex; align-items: center; justify-content: center; width: 100%; height: 100%; }
.related-card-cat { position: absolute; top: 10px; left: 10px; padding: 3px 10px; border-radius: 50px; background: rgba(99,102,241,0.8); color: #fff; font-size: 0.7rem; font-weight: 600; text-transform: uppercase; backdrop-filter: blur(4px); }
.related-card-body { padding: 16px; }
.related-card-body h3 { font-size: 1rem; font-weight: 600; color: #fff; margin: 0 0 8px; line-height: 1.4; display: -webkit-box; -webkit-line-clamp: 2; -webkit-box-orient: vertical; overflow: hidden; }
.related-card-body p { font-size: 0.85rem; color: rgba(255,255,255,0.5); margin: 0 0 12px; display: -webkit-box; -webkit-line-clamp: 2; -webkit-box-orient: vertical; overflow: hidden; }
.related-card-meta { display: flex; justify-content: space-between; font-size: 0.78rem; color: rgba(255,255,255,0.35); }

/* === BLOG LISTING HERO === */
.blog-hero { padding: 56px 0 40px; text-align: center; border-bottom: 1px solid rgba(255,255,255,0.06); }
.blog-hero .section-label { display: inline-block; padding: 5px 16px; border-radius: 50px; background: rgba(99,102,241,0.1); border: 1px solid rgba(99,102,241,0.2); font-size: 0.8rem; font-weight: 600; color: #818cf8; margin-bottom: 16px; }
.blog-hero h1 { font-size: clamp(1.6rem, 3.5vw, 2.2rem); font-weight: 800; color: #fff; margin: 0 0 12px; }
.blog-hero-desc { color: rgba(255,255,255,0.5); max-width: 560px; margin: 0 auto; font-size: 0.95rem; }
.blog-listing { padding: 40px 0 64px; }

/* === BLOG CARD GRID === */
.blog-grid-v2 { display: grid; grid-template-columns: repeat(3, 1fr); gap: 28px; }
.blog-card-v2 { background: rgba(255,255,255,0.03); border: 1px solid rgba(255,255,255,0.06); border-radius: 12px; overflow: hidden; transition: all 0.3s; }
.blog-card-v2:hover { transform: translateY(-4px); border-color: rgba(99,102,241,0.3); box-shadow: 0 8px 32px rgba(0,0,0,0.3); }
.blog-card-v2-img { display: block; position: relative; aspect-ratio: 16/9; overflow: hidden; background: linear-gradient(135deg, #0f0f24, #1a1a3e); }
.blog-card-v2-img img { width: 100%; height: 100%; object-fit: cover; transition: transform 0.3s; }
.blog-card-v2:hover .blog-card-v2-img img { transform: scale(1.05); }
.blog-card-v2-placeholder { display: flex; align-items: center; justify-content: center; width: 100%; height: 100%; }
.blog-card-v2-cat { position: absolute; top: 10px; left: 10px; padding: 3px 10px; border-radius: 50px; background: rgba(99,102,241,0.8); color: #fff; font-size: 0.7rem; font-weight: 600; text-transform: uppercase; backdrop-filter: blur(4px); }
.blog-card-v2-body { padding: 20px; }
.blog-card-v2-body h2 { font-size: 1.05rem; font-weight: 600; margin: 0 0 8px; line-height: 1.4; }
.blog-card-v2-body h2 a { color: #fff; text-decoration: none; transition: color 0.2s; }
.blog-card-v2-body h2 a:hover { color: #818cf8; }
.blog-card-v2-body p { font-size: 0.88rem; color: rgba(255,255,255,0.5); margin: 0 0 16px; line-height: 1.55; display: -webkit-box; -webkit-line-clamp: 3; -webkit-box-orient: vertical; overflow: hidden; }
.blog-card-v2-footer { display: flex; align-items: center; justify-content: space-between; border-top: 1px solid rgba(255,255,255,0.06); padding-top: 14px; }
.blog-card-v2-meta { display: flex; align-items: center; gap: 6px; font-size: 0.78rem; color: rgba(255,255,255,0.4); }
.blog-card-v2-dot { width: 3px; height: 3px; border-radius: 50%; background: rgba(255,255,255,0.2); }
.blog-card-v2-link { display: inline-flex; align-items: center; gap: 4px; font-size: 0.82rem; font-weight: 600; color: #818cf8; text-decoration: none; transition: gap 0.2s; }
.blog-card-v2-link:hover { gap: 8px; color: #22d3ee; }

/* === PAGINATION === */
.blog-pagination { margin-top: 40px; text-align: center; }
.blog-pagination .nav-links { display: flex; justify-content: center; gap: 6px; }
.blog-pagination a, .blog-pagination span { display: inline-flex; align-items: center; justify-content: center; min-width: 38px; height: 38px; padding: 0 12px; border-radius: 8px; border: 1px solid rgba(255,255,255,0.1); font-size: 0.88rem; color: rgba(255,255,255,0.6); text-decoration: none; transition: all 0.2s; }
.blog-pagination a:hover { border-color: rgba(99,102,241,0.4); color: #818cf8; background: rgba(99,102,241,0.08); }
.blog-pagination .current { background: #6366f1; border-color: #6366f1; color: #fff; font-weight: 600; }
.blog-empty { text-align: center; padding: 80px 0; color: rgba(255,255,255,0.4); }

/* === RESPONSIVE === */
@media (max-width: 1024px) {
    .article-layout > .container { grid-template-columns: 1fr; }
    .article-sidebar { position: static; flex-direction: row; gap: 16px; }
    .article-toc, .article-share { flex: 1; }
    .article-content { max-width: 100%; }
}
@media (max-width: 768px) {
    .article-toc { display: none; }
    .article-sidebar { justify-content: center; }
    .article-share { text-align: center; }
    .share-buttons { justify-content: center; }
    .blog-grid-v2, .related-grid { grid-template-columns: 1fr; }
    .article-hero h1 { font-size: 1.6rem; }
    .cta-box { padding: 28px 20px; }
}
@media (max-width: 480px) {
    .hide-mobile { display: none; }
    .article-meta-bar { font-size: 0.8rem; }
    .cta-button { width: 100%; justify-content: center; }
}
