/*
  Estilos exclusivos do blog. Carregado junto com /assets/build/css/main.css
  (que já cobre header, footer e utilitários usados no site principal).
  Usa os mesmos tokens visuais do site: Inter, blue-600 (#2563eb),
  gray-900 (#111827), gray-50 (#f9fafb).
*/

.blog-hero {
    background: linear-gradient(135deg, #eff6ff 0%, #f9fafb 100%);
    padding: 3.5rem 0 2.5rem;
    border-bottom: 1px solid #e5e7eb;
}

.blog-hero__eyebrow {
    display: inline-block;
    color: #2563eb;
    font-weight: 600;
    font-size: 0.875rem;
    letter-spacing: 0.04em;
    text-transform: uppercase;
    margin-bottom: 0.75rem;
}

.blog-hero__title {
    font-size: clamp(1.75rem, 4vw, 2.75rem);
    font-weight: 700;
    color: #111827;
    line-height: 1.15;
    margin: 0 0 0.75rem;
}

.blog-hero__lead {
    color: #4b5563;
    font-size: 1.05rem;
    line-height: 1.6;
    max-width: 42rem;
}

/* Breadcrumb */
.blog-breadcrumb {
    font-size: 0.875rem;
    color: #6b7280;
    margin-bottom: 1rem;
}

.blog-breadcrumb a {
    color: #6b7280;
    text-decoration: none;
    transition: color 0.2s;
}

.blog-breadcrumb a:hover {
    color: #2563eb;
}

.blog-breadcrumb span[aria-current] {
    color: #111827;
    font-weight: 500;
}

/* Grid de posts */
.blog-grid {
    display: grid;
    grid-template-columns: 1fr;
    gap: 2rem;
    padding: 3rem 0;
}

@media (min-width: 640px) {
    .blog-grid {
        grid-template-columns: repeat(2, 1fr);
    }
}

@media (min-width: 1024px) {
    .blog-grid {
        grid-template-columns: repeat(3, 1fr);
    }
}

.blog-card {
    display: flex;
    flex-direction: column;
    background: #fff;
    border: 1px solid #e5e7eb;
    border-radius: 0.75rem;
    overflow: hidden;
    text-decoration: none;
    color: inherit;
    transition: transform 0.25s ease, box-shadow 0.25s ease;
}

.blog-card:hover {
    transform: translateY(-4px);
    box-shadow: 0 12px 24px -8px rgba(17, 24, 39, 0.15);
}

.blog-card__image-wrap {
    aspect-ratio: 16 / 9;
    background: #f3f4f6;
    overflow: hidden;
}

.blog-card__image-wrap img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    display: block;
}

.blog-card__body {
    padding: 1.25rem 1.5rem 1.5rem;
    display: flex;
    flex-direction: column;
    flex: 1;
}

.blog-card__tag {
    display: inline-block;
    align-self: flex-start;
    background: #eff6ff;
    color: #2563eb;
    font-size: 0.75rem;
    font-weight: 600;
    padding: 0.2rem 0.6rem;
    border-radius: 9999px;
    margin-bottom: 0.75rem;
}

.blog-card__title {
    font-size: 1.15rem;
    font-weight: 700;
    color: #111827;
    line-height: 1.35;
    margin: 0 0 0.5rem;
}

.blog-card__excerpt {
    color: #4b5563;
    font-size: 0.95rem;
    line-height: 1.55;
    margin: 0 0 1rem;
    flex: 1;
}

.blog-card__meta {
    display: flex;
    align-items: center;
    gap: 0.5rem;
    font-size: 0.8rem;
    color: #6b7280;
    border-top: 1px solid #f3f4f6;
    padding-top: 0.75rem;
}

/* Estado vazio (antes do primeiro post) */
.blog-empty {
    text-align: center;
    padding: 3rem 1.5rem;
    color: #6b7280;
    border: 1px dashed #d1d5db;
    border-radius: 0.75rem;
    background: #fafafa;
}

/* Artigo (post individual) */
.article-header {
    padding: 2.5rem 0 2rem;
    border-bottom: 1px solid #e5e7eb;
}

.article-header__tag {
    display: inline-block;
    background: #eff6ff;
    color: #2563eb;
    font-size: 0.8rem;
    font-weight: 600;
    padding: 0.25rem 0.75rem;
    border-radius: 9999px;
    margin-bottom: 1rem;
}

.article-header__title {
    font-size: clamp(1.75rem, 4vw, 2.5rem);
    font-weight: 700;
    color: #111827;
    line-height: 1.2;
    margin: 0 0 1rem;
}

.article-header__meta {
    display: flex;
    flex-wrap: wrap;
    align-items: center;
    gap: 1rem;
    color: #6b7280;
    font-size: 0.9rem;
}

.article-header__meta .divider {
    color: #d1d5db;
}

.article-cover {
    width: 100%;
    max-height: 26rem;
    object-fit: cover;
    border-radius: 0.75rem;
    margin: 2rem 0;
}

.article-layout {
    display: grid;
    grid-template-columns: 1fr;
    gap: 2.5rem;
    padding: 2.5rem 0 4rem;
}

@media (min-width: 1024px) {
    .article-layout {
        grid-template-columns: minmax(0, 1fr) 18rem;
    }
}

.article-content {
    max-width: 42rem;
    color: #1f2937;
    font-size: 1.05rem;
    line-height: 1.8;
}

.article-content h2 {
    font-size: 1.5rem;
    font-weight: 700;
    color: #111827;
    margin: 2.25rem 0 1rem;
    scroll-margin-top: 6rem;
}

.article-content h3 {
    font-size: 1.2rem;
    font-weight: 700;
    color: #111827;
    margin: 1.75rem 0 0.75rem;
    scroll-margin-top: 6rem;
}

.article-content p {
    margin: 0 0 1.25rem;
}

.article-content ul,
.article-content ol {
    margin: 0 0 1.25rem 1.25rem;
    padding: 0;
}

.article-content li {
    margin-bottom: 0.5rem;
}

.article-content a {
    color: #2563eb;
    text-decoration: underline;
    text-underline-offset: 2px;
}

.article-content a:hover {
    color: #1d4ed8;
}

.article-content blockquote {
    border-left: 4px solid #2563eb;
    background: #eff6ff;
    padding: 1rem 1.25rem;
    border-radius: 0 0.5rem 0.5rem 0;
    color: #1f2937;
    margin: 0 0 1.25rem;
    font-style: italic;
}

.article-content figure {
    margin: 1.75rem 0;
}

.article-content figcaption {
    font-size: 0.85rem;
    color: #6b7280;
    text-align: center;
    margin-top: 0.5rem;
}

.article-content strong {
    color: #111827;
}

/* CTA embutido no artigo (link contextual pro produto divulgado) */
.article-cta {
    background: #111827;
    color: #fff;
    border-radius: 0.75rem;
    padding: 1.75rem;
    margin: 2rem 0;
}

.article-cta__title {
    font-size: 1.1rem;
    font-weight: 700;
    margin: 0 0 0.5rem;
}

.article-cta__text {
    color: #d1d5db;
    font-size: 0.95rem;
    margin: 0 0 1rem;
    line-height: 1.6;
}

.article-cta__button {
    display: inline-block;
    background: #2563eb;
    color: #fff;
    font-weight: 600;
    padding: 0.6rem 1.25rem;
    border-radius: 0.5rem;
    text-decoration: none;
    transition: background 0.2s;
}

.article-cta__button:hover {
    background: #1d4ed8;
}

/* FAQ */
.article-faq {
    margin-top: 2rem;
}

.article-faq details {
    border: 1px solid #e5e7eb;
    border-radius: 0.5rem;
    padding: 1rem 1.25rem;
    margin-bottom: 0.75rem;
}

.article-faq summary {
    font-weight: 600;
    color: #111827;
    cursor: pointer;
}

.article-faq p {
    margin: 0.75rem 0 0;
    color: #4b5563;
    line-height: 1.6;
}

/* Autor */
.article-author {
    display: flex;
    align-items: center;
    gap: 1rem;
    background: #f9fafb;
    border: 1px solid #e5e7eb;
    border-radius: 0.75rem;
    padding: 1.25rem;
    margin-top: 2.5rem;
}

.article-author__avatar {
    width: 3rem;
    height: 3rem;
    border-radius: 9999px;
    background: #2563eb;
    color: #fff;
    display: flex;
    align-items: center;
    justify-content: center;
    font-weight: 700;
    flex-shrink: 0;
}

.article-author__name {
    font-weight: 700;
    color: #111827;
    margin: 0;
}

.article-author__bio {
    color: #6b7280;
    font-size: 0.9rem;
    margin: 0.15rem 0 0;
}

/* Tags do rodapé do post */
.article-tags {
    display: flex;
    flex-wrap: wrap;
    gap: 0.5rem;
    margin-top: 2rem;
}

.article-tags a {
    background: #f3f4f6;
    color: #374151;
    font-size: 0.8rem;
    font-weight: 500;
    padding: 0.3rem 0.75rem;
    border-radius: 9999px;
    text-decoration: none;
    transition: background 0.2s, color 0.2s;
}

.article-tags a:hover {
    background: #eff6ff;
    color: #2563eb;
}

/* Sidebar (TOC + relacionados) */
.article-sidebar {
    align-self: start;
    position: sticky;
    top: 6rem;
    display: flex;
    flex-direction: column;
    gap: 1.5rem;
}

.toc {
    background: #f9fafb;
    border: 1px solid #e5e7eb;
    border-radius: 0.75rem;
    padding: 1.25rem;
}

.toc__title {
    font-size: 0.85rem;
    font-weight: 700;
    text-transform: uppercase;
    letter-spacing: 0.03em;
    color: #6b7280;
    margin: 0 0 0.75rem;
}

.toc ol {
    list-style: none;
    margin: 0;
    padding: 0;
    display: flex;
    flex-direction: column;
    gap: 0.5rem;
}

.toc a {
    color: #374151;
    text-decoration: none;
    font-size: 0.9rem;
    line-height: 1.4;
}

.toc a:hover {
    color: #2563eb;
}

.related-posts {
    background: #fff;
    border: 1px solid #e5e7eb;
    border-radius: 0.75rem;
    padding: 1.25rem;
}

.related-posts__title {
    font-size: 0.85rem;
    font-weight: 700;
    text-transform: uppercase;
    letter-spacing: 0.03em;
    color: #6b7280;
    margin: 0 0 0.9rem;
}

.related-posts a {
    display: block;
    color: #111827;
    font-weight: 600;
    font-size: 0.92rem;
    line-height: 1.4;
    text-decoration: none;
    margin-bottom: 0.9rem;
}

.related-posts a:hover {
    color: #2563eb;
}
