
/* ===== PÁGINA DE LISTADO DE BLOG ===== */
.blog-page {
    min-height: 100vh;
    background: linear-gradient(135deg, #f5f7fa 0%, #c3cfe2 100%);
}

.blog-header {
    background: white;
    padding: 3rem 0 2rem;
    margin-bottom: 2rem;
    box-shadow: 0 2px 10px rgba(0,0,0,0.1);
}

.blog-hero {
    text-align: center;
    margin-bottom: 2rem;
}

.blog-title {
    font-size: 3rem;
    font-weight: 700;
    background: linear-gradient(45deg, #00b3af, #0000e2);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    margin-bottom: 0.5rem;
}

.blog-subtitle {
    font-size: 1.2rem;
    color: var(--gray-600);
    max-width: 600px;
    margin: 0 auto;
}

.blog-filters {
    display: flex;
    flex-direction: column;
    gap: 1.5rem;
    align-items: center;
}

.search-container {
    width: 100%;
    max-width: 500px;
}

.search-box {
    position: relative;
    width: 100%;
}

.search-box i {
    position: absolute;
    left: 1rem;
    top: 50%;
    transform: translateY(-50%);
    color: var(--gray-400);
}

.search-box input {
    width: 100%;
    padding: 0.75rem 1rem 0.75rem 3rem;
    border: 2px solid var(--gray-200);
    border-radius: 50px;
    font-size: 1rem;
    transition: all 0.3s ease;
}

.search-box input:focus {
    border-color: var(--primary-color);
    box-shadow: 0 0 0 3px rgba(0, 179, 175, 0.1);
}

.category-filters {
    display: flex;
    flex-wrap: wrap;
    gap: 0.5rem;
    justify-content: center;
}

.category-btn {
    padding: 0.5rem 1.5rem;
    border: 2px solid var(--gray-300);
    background: white;
    color: var(--gray-600);
    border-radius: 25px;
    cursor: pointer;
    transition: all 0.3s ease;
    font-weight: 500;
}

.category-btn:hover {
    border-color: var(--primary-color);
    color: var(--primary-color);
}

.category-btn.active {
    background: var(--primary-color);
    border-color: var(--primary-color);
    color: white;
}

.category-btn[data-category]:not([data-category=""]).active {
    background: var(--category-color, var(--primary-color));
    border-color: var(--category-color, var(--primary-color));
}

/* Grid de artículos */
.articles-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(350px, 1fr));
    gap: 2rem;
    margin-bottom: 3rem;
}

.article-card {
    background: white;
    border-radius: 15px;
    overflow: hidden;
    box-shadow: 0 5px 15px rgba(0,0,0,0.1);
    transition: all 0.3s ease;
    height: fit-content;
}

.article-card:hover {
    transform: translateY(-5px);
    box-shadow: 0 15px 35px rgba(0,0,0,0.15);
}

.article-image-container {
    position: relative;
    height: 200px;
    overflow: hidden;
}

.article-image {
    width: 100%;
    height: 100%;
    object-fit: cover;
    transition: transform 0.3s ease;
}

.article-card:hover .article-image {
    transform: scale(1.05);
}

.article-overlay {
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: rgba(0, 179, 175, 0.9);
    display: flex;
    align-items: center;
    justify-content: center;
    opacity: 0;
    transition: opacity 0.3s ease;
}

.article-card:hover .article-overlay {
    opacity: 1;
}

.btn-read-article {
    background: white;
    color: var(--primary-color);
    border: none;
    padding: 0.75rem 1.5rem;
    border-radius: 25px;
    font-weight: 600;
    cursor: pointer;
    display: flex;
    align-items: center;
    gap: 0.5rem;
    transition: all 0.3s ease;
}

.btn-read-article:hover {
    transform: scale(1.05);
}

.article-content {
    padding: 1.5rem;
}

.article-meta {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 1rem;
}

.article-categories {
    display: flex;
    gap: 0.5rem;
    flex-wrap: wrap;
}

.category-tag {
    padding: 0.25rem 0.75rem;
    border-radius: 15px;
    font-size: 0.8rem;
    font-weight: 500;
}

.article-date {
    color: var(--gray-500);
    font-size: 0.9rem;
}

.article-title {
    font-size: 1.3rem;
    font-weight: 700;
    color: #e6e6e6;
    margin-bottom: 0.75rem;
    cursor: pointer;
    transition: color 0.3s ease;
    line-height: 1.4;
}

.article-title:hover {
    color: var(--primary-color);
}

.article-excerpt {
    color: var(--gray-600);
    line-height: 1.6;
    margin-bottom: 1.5rem;
    display: -webkit-box;
    -webkit-line-clamp: 3;
    -webkit-box-orient: vertical;
    overflow: hidden;
}

.article-footer {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding-top: 1rem;
    border-top: 1px solid var(--gray-200);
}

.article-author {
    display: flex;
    align-items: center;
    gap: 0.75rem;
}

.author-avatar {
    width: 40px;
    height: 40px;
    border-radius: 50%;
    object-fit: cover;
}

.author-info {
    display: flex;
    flex-direction: column;
}

.author-name {
    font-weight: 600;
    color: var(--gray-800);
    font-size: 0.9rem;
}

.author-type {
    color: var(--gray-500);
    font-size: 0.8rem;
}

.article-stats {
    display: flex;
    gap: 1rem;
}

.stat-item {
    display: flex;
    align-items: center;
    gap: 0.25rem;
    color: var(--gray-500);
    font-size: 0.8rem;
}

.stat-item i {
    font-size: 0.7rem;
}

/* No articles */
.no-articles {
    grid-column: 1 / -1;
    text-align: center;
    padding: 3rem;
    color: var(--gray-500);
}

.no-articles i {
    font-size: 3rem;
    margin-bottom: 1rem;
    color: var(--gray-400);
}

/* Paginación */
.pagination-container {
    display: flex;
    justify-content: center;
    margin-top: 2rem;
}

.pagination {
    display: flex;
    align-items: center;
    gap: 0.5rem;
}

.pagination-btn {
    padding: 0.5rem 1rem;
    border: 1px solid var(--gray-300);
    background: white;
    color: var(--gray-600);
    border-radius: 8px;
    cursor: pointer;
    transition: all 0.3s ease;
    min-width: 40px;
    display: flex;
    align-items: center;
    justify-content: center;
}

.pagination-btn:hover {
    border-color: var(--primary-color);
    color: var(--primary-color);
}

.pagination-btn.active {
    background: var(--primary-color);
    border-color: var(--primary-color);
    color: white;
}

.pagination-dots {
    padding: 0.5rem;
    color: var(--gray-400);
}

/* ===== PÁGINA DE DETALLE DEL ARTÍCULO ===== */
.blog-article-page {
    background: var(--gray-50);
    min-height: 100vh;
}

.article-header {
    background: white;
    padding: 2rem 0;
    box-shadow: 0 2px 10px rgba(0,0,0,0.1);
}

.breadcrumb {
    display: flex;
    align-items: center;
    gap: 0.5rem;
    margin-bottom: 2rem;
    font-size: 0.9rem;
}

.breadcrumb a {
    color: var(--primary-color);
    text-decoration: none;
}

.breadcrumb span {
    color: var(--gray-400);
}

.article-hero {
   /* max-width: 800px; */
    margin: 0 auto;
    text-align: center;
}

.hero-content-blog {
    position: relative;
    z-index: 3;
    display: grid;
    /* grid-template-columns: 1fr 1fr; */
    gap: 4rem;
    /* max-width: 1200px; */
    width: 100%;
    padding: 0rem;
    align-items: center;
}

.article-main-title {
    font-size: 2.5rem;
    font-weight: 700;
    color: var(--gray-800);
    margin: 1rem 0 2rem;
    line-height: 1.3;
}

.article-meta-info {
    display: flex;
    justify-content: space-between;
    align-items: center;
    gap: 2rem;
}

.author-section {
    display: flex;
    align-items: center;
    gap: 1rem;
}

.author-avatar-large {
    width: 60px;
    height: 60px;
    border-radius: 50%;
    object-fit: cover;
}

.author-details h3 {
    font-size: 1.1rem;
    font-weight: 600;
    color: var(--gray-800);
    margin-bottom: 0.25rem;
}

.author-details p {
    color: var(--gray-500);
    font-size: 0.9rem;
}

.article-stats-info .stat-group {
    display: flex;
    gap: 1.5rem;
}

.featured-image-container {
    max-width: 1000px;
    margin: 2rem auto;
    border-radius: 15px;
    overflow: hidden;
    box-shadow: 0 10px 30px rgba(0,0,0,0.1);
}

.featured-image {
    width: 100%;
    height: auto;
    display: block;
}

.article-body {
    padding: 2rem 0;
}

.article-layout {
    display: grid;
    grid-template-columns: 80px 1fr;
    gap: 2rem;
    max-width: 1000px;
    margin: 0 auto;
}

.article-sidebar {
    position: relative;
}

.article-actions.sticky {
    position: sticky;
    top: 100px;
    display: flex;
    flex-direction: column;
    gap: 1rem;
}

.action-btn {
    display: flex;
    flex-direction: row;
    align-items: center;
    gap: 0.5rem;
    padding: 6px;
    background: white;
    border: 1px solid var(--gray-200);
    border-radius: 12px;
    cursor: pointer;
    transition: all 0.3s 
ease;
    color: var(--gray-600);
    font-size: 0.8rem;
}


.action-btn:hover {
    background: var(--gray-50);
    border-color: var(--primary-color);
    color: var(--primary-color);
}

.action-btn i {
    font-size: 1.2rem;
}

.like-btn.liked {
    background: #fee2e2;
    border-color: #ef4444;
    color: #ef4444;
}

.article-content {
    background: white;
    padding: 2rem;
    border-radius: 15px;
    box-shadow: 0 5px 15px rgba(0,0,0,0.1);
}

.article-text {
    font-size: 1.1rem;
    line-height: 1.8;
    color: var(--gray-700);
    margin-bottom: 2rem;
}

.article-text h2,
.article-text h3,
.article-text h4 {
    color: var(--gray-800);
    margin: 2rem 0 1rem;
}

.article-text p {
    margin-bottom: 1.5rem;
}

.article-text img {
    max-width: 100%;
    height: auto;
    border-radius: 10px;
    margin: 1.5rem 0;
}

.article-tags {
    margin-top: 2rem;
    padding-top: 2rem;
    border-top: 1px solid var(--gray-200);
}

.article-tags h4 {
    margin-bottom: 1rem;
    color: var(--gray-800);
}

.tags-list {
    display: flex;
    flex-wrap: wrap;
    gap: 0.5rem;
}

.tag {
    background: var(--gray-100);
    color: var(--gray-600);
    padding: 0.25rem 0.75rem;
    border-radius: 15px;
    font-size: 0.9rem;
}

.mobile-share {
    margin-top: 2rem;
    padding-top: 2rem;
    border-top: 1px solid var(--gray-200);
}

.share-buttons {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(120px, 1fr));
    gap: 1rem;
    margin-top: 1rem;
}

.share-btn {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 0.5rem;
    padding: 0.75rem;
    border: none;
    border-radius: 8px;
    cursor: pointer;
    font-weight: 500;
    transition: all 0.3s ease;
}

.share-btn.facebook {
    background: #1877f2;
    color: white;
}

.share-btn.twitter {
    background: #1da1f2;
    color: white;
}

.share-btn.whatsapp {
    background: #25d366;
    color: white;
}

.share-btn.copy {
    background: var(--gray-100);
    color: var(--gray-700);
}

.share-btn:hover {
    transform: translateY(-2px);
    box-shadow: 0 5px 15px rgba(0,0,0,0.2);
}

/* Comentarios */
.comments-section {
    background: white;
    padding: 3rem 0;
    margin-top: 2rem;
}

.comments-title {
    font-size: 1.5rem;
    font-weight: 700;
    color: var(--gray-800);
    margin-bottom: 2rem;
}

.comment-form-container {
    margin-bottom: 3rem;
}

.comment-form {
    background: var(--gray-50);
    padding: 1.5rem;
    border-radius: 12px;
}

.comment-input-group {
    display: flex;
    gap: 1rem;
    margin-bottom: 1rem;
}

.comment-avatar {
    width: 40px;
    height: 40px;
    border-radius: 50%;
    object-fit: cover;
    flex-shrink: 0;
}

.comment-input-group textarea {
    flex: 1;
    border: 1px solid var(--gray-300);
    border-radius: 8px;
    padding: 0.75rem;
    resize: vertical;
    font-family: inherit;
}

.comment-actions {
    display: flex;
    justify-content: flex-end;
}

.login-prompt {
    text-align: center;
    padding: 2rem;
    background: var(--gray-50);
    border-radius: 12px;
    margin-bottom: 2rem;
}

.login-prompt a {
    color: var(--primary-color);
    text-decoration: none;
    font-weight: 600;
}

.comments-list {
    display: flex;
    flex-direction: column;
    gap: 1.5rem;
}

.comment {
    display: flex;
    gap: 1rem;
    padding: 1.5rem;
    background: var(--gray-50);
    border-radius: 12px;
}

.comment-content {
    flex: 1;
}

.comment-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 0.5rem;
}

.comment-author {
    font-weight: 600;
    color: var(--gray-800);
}

.comment-date {
    color: var(--gray-500);
    font-size: 0.9rem;
}

.comment-text {
    color: var(--gray-700);
    line-height: 1.6;
    margin-bottom: 1rem;
}

.comment-actions {
    display: flex;
    gap: 1rem;
}

.comment-action-btn {
    background: none;
    border: none;
    color: var(--gray-500);
    cursor: pointer;
    font-size: 0.9rem;
    display: flex;
    align-items: center;
    gap: 0.25rem;
    transition: color 0.3s ease;
}

.comment-action-btn:hover {
    color: var(--primary-color);
}

.comment-replies {
    margin-top: 1rem;
    padding-left: 2rem;
    border-left: 2px solid var(--gray-200);
}

.no-comments {
    text-align: center;
    padding: 3rem;
    color: var(--gray-500);
}

.no-comments i {
    font-size: 3rem;
    margin-bottom: 1rem;
    color: var(--gray-400);
}

/* Artículos relacionados */
.related-articles {
    background: var(--gray-100);
    padding: 3rem 0;
}

.related-articles h3 {
    font-size: 1.5rem;
    font-weight: 700;
    color: var(--gray-800);
    margin-bottom: 2rem;
    text-align: center;
}

.related-articles-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(300px, 1fr));
    gap: 2rem;
}

/* Article not found */
.article-not-found {
    text-align: center;
    padding: 4rem 2rem;
    color: var(--gray-500);
}

.article-not-found i {
    font-size: 4rem;
    margin-bottom: 1rem;
    color: var(--gray-400);
}

.article-not-found h2 {
    font-size: 2rem;
    margin-bottom: 1rem;
    color: var(--gray-700);
}

/* Responsive */
@media (max-width: 768px) {
    .blog-title {
        font-size: 2rem;
    }
    
    .blog-filters {
        padding: 0 1rem;
    }
    
    .articles-grid {
        grid-template-columns: 1fr;
        gap: 1.5rem;
        padding: 0;
    }
    
    .article-main-title {
        font-size: 1.8rem;
    }
    
    .article-meta-info {
        flex-direction: column;
        gap: 1rem;
        text-align: left;
    }
    
    .article-layout {
        grid-template-columns: 1fr;
        gap: 1rem;
    }
    
    .article-actions.sticky {
        position: static;
        flex-direction: row;
        justify-content: center;
        margin-bottom: 1rem;
    }
    
    .mobile-share {
        display: block;
    }
    
    .share-buttons {
        grid-template-columns: repeat(2, 1fr);
    }
    
    .comment-input-group {
        flex-direction: column;
    }
    
    .comment {
        flex-direction: column;
    }
    
    .comment-replies {
        padding-left: 1rem;
    }
    .action-btn {
    display: grid;
    font-size: 0.4rem;
    }
    
    .blog-badge {
        display: none!important;
    }

}

@media (max-width: 480px) {
    .article-card {
        margin: 0;
    }
    
    .article-content {
        padding: 1rem;
    }
    
    .article-text {
        font-size: 1rem;
    }
    
    .share-buttons {
        grid-template-columns: 1fr;
    }
}


/* ✅ ESTILOS PARA POSTS DE BLOG */
.blog-overlay {
    position: absolute;
    top: 1rem;
    right: 1rem;
    z-index: 2;
}

.blog-badge {
    background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
    color: white;
    padding: 0.5rem 1rem;
    border-radius: 2rem;
    font-size: 0.875rem;
    font-weight: 600;
    box-shadow: 0 4px 12px rgba(102, 126, 234, 0.3);
    display: flex;
    align-items: center;
    gap: 0.5rem;
}

.blog-cta {
    margin-top: 1rem;
    padding-top: 1rem;
    border-top: 1px solid #e5e7eb;
}

.btn-read-blog {
    background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
    color: white;
    padding: 0.75rem 1.5rem;
    border: none;
    border-radius: 0.5rem;
    font-weight: 600;
    cursor: pointer;
    transition: all 0.3s ease;
    display: flex;
    align-items: center;
    justify-content: center;
    width: 100%;
    font-size: 0.875rem;
}

.btn-read-blog:hover {
    transform: translateY(-2px);
    box-shadow: 0 8px 25px rgba(102, 126, 234, 0.3);
}

.author-badge {
    background: #10B981;
    color: white;
    padding: 0.25rem 0.5rem;
    border-radius: 1rem;
    font-size: 0.75rem;
    font-weight: 500;
    margin-left: 0.5rem;
}

/* ✅ MEJORAR ESTILOS DE HASHTAGS */
.post-hashtags {
    margin-top: 1rem;
    display: flex;
    flex-wrap: wrap;
    gap: 0.5rem;
}

.hashtag {
    background: #f3f4f6;
    color: #6b7280;
    padding: 0.25rem 0.75rem;
    border-radius: 1rem;
    font-size: 0.875rem;
    font-weight: 500;
    transition: all 0.2s ease;
    cursor: pointer;
}

.hashtag:hover {
    background: #e5e7eb;
    color: #374151;
}

/* ✅ MEJORAR POST IMAGE PARA BLOG */
.post-image {
    position: relative;
    margin-top: 1rem;
    border-radius: 0.75rem;
    overflow: hidden;
}

.post-image img {
    width: 100%;
    height: auto;
    max-height: 400px;
    object-fit: cover;
}