/**
 * VMAlbino Contabilidade Digital - Blog Styles
 * Estilos específicos para a página de blog
 */

/* BLOG HEADER */
.blog-header {
    background: linear-gradient(rgba(0, 0, 0, 0.8), rgba(0, 0, 0, 0.8)), url('../assets/img/blog-header.jpg');
    background-size: cover;
    background-position: center;
    color: var(--white);
    padding: 120px 0 80px;
    text-align: center;
    margin-top: 80px;
}

.blog-header h1 {
    font-size: 3rem;
    font-weight: 700;
    margin-bottom: 20px;
}

.blog-header p {
    font-size: 1.2rem;
    max-width: 700px;
    margin: 0 auto;
    opacity: 0.9;
}

/* BLOG CONTENT LAYOUT */
.blog-content {
    padding: 80px 0;
    background: var(--light-gray);
}

.blog-layout {
    display: grid;
    grid-template-columns: 1fr 350px;
    gap: 40px;
}

.blog-main {
    width: 100%;
}

/* BLOG GRID - EXPANDED VERSION */
.blog-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(300px, 1fr));
    gap: 30px;
    margin-bottom: 40px;
}

/* PAGINATION */
.blog-pagination {
    display: flex;
    justify-content: center;
    gap: 10px;
    margin-top: 40px;
}

.pagination-item {
    width: 40px;
    height: 40px;
    display: flex;
    align-items: center;
    justify-content: center;
    border-radius: 50%;
    background: var(--white);
    color: var(--primary);
    text-decoration: none;
    font-weight: 600;
    transition: all 0.3s ease;
    border: 1px solid var(--medium-gray);
}

.pagination-item:hover {
    background: var(--accent);
    color: var(--white);
    border-color: var(--accent);
}

.pagination-item.active {
    background: var(--accent);
    color: var(--white);
    border-color: var(--accent);
}

.pagination-item.disabled {
    opacity: 0.5;
    cursor: not-allowed;
}

/* SIDEBAR */
.blog-sidebar {
    width: 100%;
}

.sidebar-widget {
    background: var(--white);
    border-radius: 10px;
    padding: 30px;
    margin-bottom: 30px;
    box-shadow: 0 5px 15px rgba(0,0,0,0.05);
}

.sidebar-widget h3 {
    font-size: 1.3rem;
    margin-bottom: 20px;
    padding-bottom: 15px;
    border-bottom: 2px solid var(--accent);
    display: inline-block;
}

/* CATEGORIES */
.category-list {
    list-style: none;
    padding: 0;
}

.category-list li {
    margin-bottom: 10px;
}

.category-list a {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 10px 15px;
    background: var(--light-gray);
    border-radius: 5px;
    text-decoration: none;
    color: var(--primary);
    font-weight: 500;
    transition: all 0.3s ease;
}

.category-list a:hover {
    background: var(--accent);
    color: var(--white);
    transform: translateX(5px);
}

.category-list a span {
    background: var(--white);
    color: var(--accent);
    padding: 2px 8px;
    border-radius: 20px;
    font-size: 0.8rem;
    font-weight: 600;
}

/* RECENT POSTS */
.recent-posts {
    list-style: none;
    padding: 0;
}

.recent-posts li {
    margin-bottom: 15px;
    padding-bottom: 15px;
    border-bottom: 1px solid var(--light-gray);
}

.recent-posts li:last-child {
    margin-bottom: 0;
    padding-bottom: 0;
    border-bottom: none;
}

.recent-post-item {
    display: flex;
    align-items: center;
    gap: 15px;
    text-decoration: none;
    color: var(--primary);
}

.recent-post-image {
    width: 60px;
    height: 60px;
    border-radius: 5px;
    overflow: hidden;
    flex-shrink: 0;
}

.recent-post-image img {
    width: 100%;
    height: 100%;
    object-fit: cover;
}

.recent-post-content h4 {
    font-size: 0.95rem;
    margin-bottom: 5px;
    line-height: 1.4;
    transition: color 0.3s ease;
}

.recent-post-date {
    font-size: 0.8rem;
    color: var(--accent);
}

.recent-post-item:hover h4 {
    color: var(--accent);
}

/* NEWSLETTER */
.newsletter-form {
    display: flex;
    flex-direction: column;
    gap: 10px;
}

.newsletter-form input {
    padding: 12px 15px;
    border: 1px solid var(--medium-gray);
    border-radius: 5px;
    font-family: 'Poppins', sans-serif;
    font-size: 0.9rem;
}

.newsletter-form button {
    width: 100%;
}

/* CTA SECTION */
.cta-section {
    background: linear-gradient(rgba(0, 0, 0, 0.85), rgba(0, 0, 0, 0.85)), url('../assets/img/cta-bg.jpg');
    background-size: cover;
    background-position: center;
    color: var(--white);
    padding: 80px 0;
    text-align: center;
}

.cta-section h2 {
    font-size: 2.2rem;
    margin-bottom: 20px;
}

.cta-section p {
    font-size: 1.1rem;
    max-width: 700px;
    margin: 0 auto 30px;
    opacity: 0.9;
}

/* SINGLE POST PAGE */
.single-post-header {
    position: relative;
    height: 500px;
    color: var(--white);
    display: flex;
    align-items: flex-end;
    margin-top: 80px;
}

.single-post-header-bg {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background-size: cover;
    background-position: center;
    z-index: -1;
}

.single-post-header-bg::after {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: linear-gradient(to top, rgba(0, 0, 0, 0.9), rgba(0, 0, 0, 0.4));
}

.single-post-header-content {
    padding-bottom: 60px;
    width: 100%;
    position: relative;
    z-index: 1;
}

.single-post-meta {
    display: flex;
    align-items: center;
    gap: 20px;
    margin-bottom: 20px;
}

.single-post-category {
    background: var(--accent);
    color: var(--white);
    padding: 5px 15px;
    border-radius: 20px;
    font-size: 0.85rem;
    font-weight: 600;
}

.single-post-date {
    font-size: 0.9rem;
    opacity: 0.8;
}

.single-post-title {
    font-size: 3rem;
    font-weight: 700;
    line-height: 1.2;
    margin-bottom: 20px;
}

.single-post-content {
    padding: 60px 0;
    background: var(--white);
}

/* Layout da página de post */
.post-layout {
    display: grid;
    grid-template-columns: 2fr 1fr;
    gap: 40px;
    max-width: 1200px;
    margin: 0 auto;
}

.post-content {
    line-height: 1.8;
    font-size: 1.1rem;
}

.post-content p {
    margin-bottom: 25px;
}

.post-content h2 {
    font-size: 1.8rem;
    margin: 40px 0 20px;
}

.post-content h3 {
    font-size: 1.5rem;
    margin: 30px 0 15px;
}

.post-content img {
    max-width: 100%;
    border-radius: 10px;
    margin: 30px 0;
}

.post-content blockquote {
    border-left: 4px solid var(--accent);
    padding: 20px 30px;
    background: var(--light-gray);
    margin: 30px 0;
    font-style: italic;
}

/* Post Sidebar */
.post-sidebar {
    padding-top: 20px;
}

.post-sidebar > div {
    background: var(--white);
    border-radius: 10px;
    padding: 25px;
    margin-bottom: 30px;
    box-shadow: 0 5px 15px rgba(0,0,0,0.05);
}

.post-sidebar h3 {
    font-size: 1.3rem;
    margin-bottom: 20px;
    padding-bottom: 15px;
    border-bottom: 2px solid var(--accent);
    display: inline-block;
}

/* Author Info */
.post-author {
    display: flex;
    align-items: center;
    gap: 20px;
}

.author-image {
    width: 80px;
    height: 80px;
    border-radius: 50%;
    overflow: hidden;
    flex-shrink: 0;
}

.author-image img {
    width: 100%;
    height: 100%;
    object-fit: cover;
}

.author-info h3 {
    font-size: 1.2rem;
    margin-bottom: 10px;
    padding-bottom: 0;
    border-bottom: none;
}

.author-info p {
    font-size: 0.9rem;
    color: var(--secondary);
    line-height: 1.6;
}

/* Share Buttons */
.post-share {
    margin-top: 0;
    padding-top: 0;
    border-top: none;
}

.share-buttons {
    display: flex;
    gap: 15px;
    margin-top: 15px;
}

.share-button {
    width: 40px;
    height: 40px;
    border-radius: 50%;
    background: var(--light-gray);
    display: flex;
    align-items: center;
    justify-content: center;
    color: var(--primary);
    transition: all 0.3s ease;
}

.share-button:hover {
    background: var(--accent);
    color: var(--white);
    transform: translateY(-3px);
}

/* Related Posts */
.related-posts-list {
    display: flex;
    flex-direction: column;
    gap: 20px;
}

.related-post-card {
    display: flex;
    gap: 15px;
    text-decoration: none;
    color: var(--primary);
    transition: transform 0.3s ease;
}

.related-post-card:hover {
    transform: translateX(5px);
}

.related-post-image {
    width: 80px;
    height: 80px;
    border-radius: 8px;
    overflow: hidden;
    flex-shrink: 0;
}

.related-post-image img {
    width: 100%;
    height: 100%;
    object-fit: cover;
}

.related-post-content {
    display: flex;
    flex-direction: column;
}

.related-post-category {
    font-size: 0.75rem;
    color: var(--accent);
    font-weight: 600;
    margin-bottom: 5px;
}

.related-post-title {
    font-size: 0.95rem;
    font-weight: 600;
    line-height: 1.4;
    margin-bottom: 5px;
    transition: color 0.3s ease;
}

.related-post-card:hover .related-post-title {
    color: var(--accent);
}

.related-post-date {
    font-size: 0.75rem;
    color: var(--secondary);
}

/* Post CTA */
.post-cta {
    background: var(--light-gray);
    border-radius: 10px;
    padding: 40px;
    text-align: center;
    margin-top: 60px;
    max-width: 800px;
    margin-left: auto;
    margin-right: auto;
}

.post-cta h2 {
    font-size: 1.8rem;
    margin-bottom: 15px;
    color: var(--primary);
}

.post-cta p {
    font-size: 1.1rem;
    margin-bottom: 25px;
    color: var(--secondary);
    max-width: 600px;
    margin-left: auto;
    margin-right: auto;
}

.post-loading {
    text-align: center;
    padding: 50px 0;
    color: var(--secondary);
}

.post-loading i {
    font-size: 2rem;
    margin-bottom: 15px;
    color: var(--accent);
}

.post-error {
    text-align: center;
    padding: 50px 0;
}

.post-error i {
    font-size: 3rem;
    color: var(--accent);
    margin-bottom: 20px;
}

.post-error h2 {
    font-size: 1.8rem;
    margin-bottom: 15px;
}

.post-error p {
    font-size: 1.1rem;
    margin-bottom: 25px;
    max-width: 600px;
    margin-left: auto;
    margin-right: auto;
}

.post-share-title {
    font-weight: 600;
}

.post-share-links {
    display: flex;
    gap: 15px;
}

.post-share-link {
    width: 40px;
    height: 40px;
    border-radius: 50%;
    background: var(--light-gray);
    display: flex;
    align-items: center;
    justify-content: center;
    color: var(--primary);
    transition: all 0.3s ease;
}

.post-share-link:hover {
    background: var(--accent);
    color: var(--white);
}

/* RESPONSIVE */
@media (max-width: 992px) {
    .blog-layout {
        grid-template-columns: 1fr;
    }
    
    .post-layout {
        grid-template-columns: 1fr;
    }
    
    .blog-header h1 {
        font-size: 2.5rem;
    }
    
    .single-post-title {
        font-size: 2.5rem;
    }
    
    .single-post-header {
        height: 400px;
    }
    
    .post-cta {
        padding: 30px 20px;
    }
}

@media (max-width: 768px) {
    .blog-grid {
        grid-template-columns: 1fr;
    }
    
    .blog-header {
        padding: 100px 0 60px;
    }
    
    .blog-header h1 {
        font-size: 2rem;
    }
    
    .single-post-header {
        height: 400px;
    }
    
    .single-post-title {
        font-size: 2rem;
    }
}

@media (max-width: 576px) {
    .blog-header {
        padding: 80px 0 50px;
    }
    
    .blog-header h1 {
        font-size: 1.8rem;
    }
    
    .single-post-header {
        height: 350px;
    }
    
    .single-post-title {
        font-size: 1.8rem;
    }
    
    .post-share {
        flex-direction: column;
        gap: 20px;
        align-items: flex-start;
    }
}
