/* ===========================
   CSS PARA PÁGINAS DEL BLOG
   =========================== */

/* Contenedor principal del artículo */
.blog-article {
    padding: 6rem 0 2rem 0;
    background: #f8f9fa;
    min-height: 100vh;
}

.blog-article .container {
    max-width: 1200px;
    margin: 0 auto;
    padding: 0 1rem;
}

/* Header del artículo */
.article-header {
    background: white;
    padding: 3rem 2rem;
    border-radius: 12px;
    box-shadow: 0 4px 20px rgba(0,0,0,0.1);
    margin-bottom: 2rem;
    text-align: center;
}

#headerblog {
  position: fixed;
  top: 0;
  left: 0;
  width: 100%;
  background-color: rgba(78, 85, 90, 0.4);
  backdrop-filter: blur(10px);
  padding: 20px 0;
  z-index: 100;
  transition: background-color var(--transition-speed), padding var(--transition-speed);
  box-shadow: 0 5px 15px rgba(0, 0, 0, 0.1);
}

.article-meta {
    display: flex;
    justify-content: center;
    align-items: center;
    gap: 1rem;
    margin-bottom: 1.5rem;
    flex-wrap: wrap;
}

.article-category {
    background: var(--yellow-dark);
    color: var(--darker-blue);
    padding: 0.5rem 1rem;
    border-radius: 20px;
    font-size: 0.875rem;
    font-weight: 600;
    text-transform: uppercase;
    letter-spacing: 0.5px;
}

.article-date {
    color: var(--dark-gray);
    font-size: 0.875rem;
    font-weight: 500;
}

.article-title {
    font-size: 2.5rem;
    font-weight: 600;
    color: var(--darker-blue);
    margin-bottom: 1rem;
    line-height: 1;
    font-family: var(--font-secondary);
}

.article-subtitle {
    font-size: 1.25rem;
    color: var(--dar-blue);
    line-height: 1.2;
    max-width: 800px;
    margin: 0 auto;
}

/* Imagen principal del artículo */
.article-image {
    margin: 2rem 0;
    border-radius: 12px;
    overflow: hidden;
    box-shadow: 0 8px 30px rgba(0,0,0,0.12);
}

.article-image img {
    width: 100%;
    height: 400px;
    object-fit: cover;
    display: block;
}

/* Contenido del artículo */
.article-content {
    background: white;
    padding: 3rem;
    border-radius: 12px;
    box-shadow: 0 4px 20px rgba(0,0,0,0.1);
    margin-bottom: 2.5rem;
    line-height: 1.8;
}

.article-content h2 {
    font-size: 2rem;
    font-weight: 400;
    line-height: 2rem;
    font-family: var(--font-secondary);
    color: var(--darker-blue);
    margin: 2.5rem 0 1.5rem 0;
    padding-bottom: 0.5rem;
    border-bottom: 3px solid var(--yellow-dark);
    position: relative;
}

.article-content h2::after {
    content: '';
    position: absolute;
    bottom: -3px;
    left: 0;
    width: 60px;
    height: 4px;
    background: var(--medium-gray);
}

.article-content h3 {
    font-size: 1.5rem;
    font-weight: 400;
    line-height: 2rem;
    font-family: var(--font-secondary);
    color: var(--darker-blue);
    margin: 0rem 0 0rem 0;
}

.article-content p {
    font-size: 1.1rem;
    color: var(--dark-blue);
    margin-bottom: 1.5rem;
    text-align: justify;
}

.article-content ul, .article-content ol {
    margin: 1.5rem 0;
    padding-left: 2rem;
}

.article-content li {
    font-size: 1.1rem;
    color: var(--darker-blue);
    margin-bottom: 0.75rem;
    line-height: 1;
}

.article-content li strong {
    color: #2c3e50;
    font-weight: 600;
}

/* Destacados y citas */
.article-highlight {
    background: var(--yellow-dark);
    color: white;
    padding: 2rem;
    border-radius: 20px;
    margin: 2rem 0;
    text-align: center;
    font-family: var(--font-primary);
    font-size: 400;
    letter-spacing: 1px;
    line-height: 1.5rem;
    font-style: italic;
}

.article-highlight p {
    font-size: 1.25rem;
    font-weight: 600;
    margin: 0;
    color: var(--darker-blue);
}

/* Imágenes dentro del contenido */
.article-image-inline {
    margin: 2.5rem 0;
    text-align: center;
}

.article-image-inline img {
    width: 100%;
    max-width: 600px;
    height: auto;
    border-radius: 12px;
    box-shadow: 0 8px 25px rgba(0,0,0,0.15);
}

.image-caption {
    font-size: 0.9rem;
    color: #6c757d;
    font-style: italic;
    margin-top: 1rem;
    text-align: center;
}

/* CTA del artículo */
.article-cta {
    background: var(--yellow-dark);
    color: white;
    padding: 3rem;
    border-radius: 12px;
    text-align: center;
    margin: 2rem 0;
    box-shadow: 0 8px 30px rgba(102, 126, 234, 0.3);
}

.article-cta h3 {
    font-size: 1.75rem;
    font-weight: 600;
    font-family: var(--font-secondary);
    margin-bottom: 1rem;
    color: var(--darker-blue);
    line-height: 2rem;
}

.article-cta p {
    font-size: 1.1rem;
    margin-bottom: 2rem;
    opacity: 0.9;
    color: var(--darker-blue);
}

.article-cta .btn {
    background: white;
    color: var(--darker-blue);
    padding: 1rem 2rem;
    border-radius: 50px;
    text-decoration: none;
    font-weight: 600;
    font-size: 1.1rem;
    transition: all 0.3s ease;
    display: inline-block;
    box-shadow: 0 4px 15px rgba(0,0,0,0.2);
}

.article-cta .btn:hover {
    transform: translateY(-2px);
    box-shadow: 0 8px 25px rgba(0,0,0,0.3);
    color: var(--medium-gray);
}

/* Sección de artículos recomendados */
.recommended-articles {
    background: white;
    padding: 3rem;
    border-radius: 12px;
    box-shadow: 0 4px 20px rgba(0,0,0,0.1);
    margin: 2rem 0;
    line-height: 2rem;
}

.recommended-articles h3 {
    font-size: 2rem;
    font-weight: 700;
    color: #2c3e50;
    text-align: center;
    margin-bottom: 2rem;
    position: relative;
    padding-bottom: 1rem;
}

.recommended-articles h3::after {
    content: '';
    position: absolute;
    bottom: 0;
    left: 50%;
    transform: translateX(-50%);
    width: 80px;
    height: 3px;
    background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
}

.recommended-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(300px, 1fr));
    gap: 2rem;
    margin-top: 2rem;
}

.recommended-card {
    background: #f8f9fa;
    border-radius: 12px;
    overflow: hidden;
    transition: all 0.3s ease;
    box-shadow: 0 4px 15px rgba(0,0,0,0.1);
}

.recommended-card:hover {
    transform: translateY(-5px);
    box-shadow: 0 8px 30px rgba(0,0,0,0.15);
}

.recommended-card img {
    width: 100%;
    height: 200px;
    object-fit: cover;
}

.recommended-card-content {
    padding: 1.5rem;
}

.recommended-card h4 {
    font-size: 1.25rem;
    font-weight: 600;
    font-family: var(--font-secondary);
    color: var(--darker-blue);
    margin-bottom: 0.75rem;
    line-height: 1.3;
}

.recommended-card p {
    font-size: 0.95rem;
    color: #6c757d;
    margin-bottom: 1rem;
    line-height: 1.2;
}

.recommended-card .btn-small {
    background: var(--yellow-dark);
    color: var(--darker-blue);
    padding: 0.75rem 1.5rem;
    border-radius: 25px;
    text-decoration: none;
    font-weight: 600;
    font-size: 0.9rem;
    transition: all 0.3s ease;
    display: inline-block;
}

.recommended-card .btn-small:hover {
    transform: translateY(-2px);
    box-shadow: 0 4px 15px rgba(102, 126, 234, 0.4);
}

/* Botón volver al blog */
.back-to-blog-section {
    text-align: center;
    margin: 3rem 0;
}

.back-to-blog {
    background: var(--yellow-dark);
    color: var(--darker-blue);
    padding: 1rem 2.5rem;
    border-radius: 50px;
    text-decoration: none;
    font-weight: 600;
    font-size: 1.1rem;
    transition: all 0.3s ease;
    display: inline-flex;
    align-items: center;
    gap: 0.5rem;
    box-shadow: 0 4px 20px rgba(102, 126, 234, 0.3);
}

.back-to-blog:hover {
    transform: translateY(-3px);
    box-shadow: 0 8px 30px rgba(102, 126, 234, 0.4);
    text-decoration: none;
}

.back-to-blog i {
    font-size: 1rem;
}

/* Responsive Design */
@media (max-width: 768px) {
    .blog-article {
        padding: 6rem 0 2rem 0; /* Ajuste para móviles */
    }
    
    .article-header {
        padding: 2rem 1.5rem;
        margin-bottom: 1.5rem;
    }
    
    .article-title {
        font-size: 2rem;
    }
    
    .article-subtitle {
        font-size: 1.1rem;
    }
    
    .article-content {
        padding: 2rem 1.5rem;
    }
    
    .article-content p,
    .article-content li {
        font-size: 1rem;
        line-height: 1.2rem;
    }
    
    .article-image img {
        height: 250px;
    }
    
    .recommended-grid {
        grid-template-columns: 1fr;
        gap: 1.5rem;
    }
    
    .article-cta {
        padding: 2rem 1.5rem;
    }
    
    .recommended-articles {
        padding: 2rem 1.5rem;
    }
}

@media (max-width: 480px) {
    .blog-article {
        padding: 6rem 0 2rem 0; /* Ajuste para pantallas muy pequeñas */
    }
    
    .article-meta {
        flex-direction: column;
        gap: 0.5rem;
    }
    
    .article-title {
        font-size: 1.75rem;
    }
    
    .article-content {
        padding: 1.5rem 1rem;
    }
    
    .article-image img {
        height: 200px;
    }
    
    .back-to-blog {
        padding: 0.875rem 2rem;
        font-size: 1rem;
    }

    .article-content p,
    .article-content li {
        font-size: 1rem;
        line-height: 1.2rem;
    }
}



/* Forzar visibilidad del contenido del blog - Solución para AOS */
.blog-article .article-header,
.blog-article .article-image,
.blog-article .article-content,
.blog-article .recommended-articles,
.blog-article .back-to-blog-section,
.blog-article .article-cta {
    opacity: 1 !important;
    visibility: visible !important;
    transform: none !important;
}

/* Asegurar que todos los elementos del blog sean visibles */
.blog-article [data-aos] {
    opacity: 1 !important;
    transform: none !important;
    font-family: var(--font-secondary);
    color: var(--darker-blue);
    line-height: 1.4rem;
}

