:root {
    --primary-color: #4361ee;
    --primary-dark: #3730a3;
    --primary-light: #e0e7ff;
    --primary-light-hover: #f0f4ff;
    --primary-gradient-start: #4361ee;
    --primary-gradient-end: #3730a3;
    --text-dark: #1e293b;
    --text-medium: #4a5568;
    --text-light: #718096;
    --bg-light: #f8fafc;
    --border-radius: 8px;
    --card-bg: #fff;
    --card-border: #e5e7eb;
    --card-radius: 18px;
    --card-shadow: 0 8px 32px rgba(67, 97, 238, 0.08);
    --card-shadow-hover: 0 16px 48px rgba(67, 97, 238, 0.13);
    --max-content-width: 1100px;
    --section-spacing: 4.5em;
    --section-spacing-mobile: 2em;
}

.seo-heading {
    position: absolute;
    overflow: hidden;
    clip: rect(0 0 0 0);
    height: 1px;
    width: 1px;
    margin: -1px;
    padding: 0;
    border: 0;
    white-space: nowrap;
}

#main-wrapper .container {
    max-width: var(--max-content-width);
    margin: 0 auto;
    padding: 0 1.5em;
}

.hero-banner {
    text-align: center;
    padding: 5em 2em 3em 2em;
    margin-bottom: var(--section-spacing);
    border-radius: 22px;
    box-shadow: 0 18px 40px rgba(67, 97, 238, 0.18);
    color: white;
    position: relative;
    overflow: hidden;
    background: linear-gradient(120deg, var(--primary-gradient-start) 60%, var(--primary-gradient-end) 100%);
}

.hero-banner::after {
    content: "";
    position: absolute;
    right: -80px;
    top: -80px;
    width: 220px;
    height: 220px;
    border-radius: 50%;
    z-index: 0;
}

.hero-banner > * {
    position: relative;
    z-index: 1;
}

.hero-banner h2 {
    font-size: 3.5em;
    color: white;
    margin-bottom: 0.5em;
    font-weight: 700;
    line-height: 1.2;
    text-shadow: 1px 1px 3px rgba(0, 0, 0, 0.2);
    letter-spacing: -1px;
}

.hero-subtitle {
    font-size: 1.35em;
    color: #f3f6fd;
    margin-bottom: 2.5em;
    max-width: 800px;
    margin-left: auto;
    margin-right: auto;
    line-height: 1.5;
}

.blog-stats {
    display: flex;
    justify-content: center;
    gap: 5em;
    margin-top: 2.5em;
}

.stat-item {
    text-align: center;
    min-width: 120px;
}

.stat-number {
    display: block;
    font-size: 2.7em;
    font-weight: 700;
    color: white;
    margin-bottom: 0.1em;
    text-shadow: 1px 1px 3px rgba(0, 0, 0, 0.2);
    letter-spacing: -1px;
}

.stat-label {
    font-size: 1.05em;
    color: rgba(255, 255, 255, 0.9);
}

/* Filtros de categorías más atractivos */
.category-filter {
    display: flex;
    gap: 1.2em;
    flex-wrap: wrap;
    justify-content: center;
    margin-bottom: 2em;
}

.filter-btn {
    background: #f8fafc;
    border: 1.5px solid #e0e7ef;
    border-radius: 22px;
    padding: 0.7em 1.7em;
    cursor: pointer;
    transition: all 0.22s cubic-bezier(.4,0,.2,1);
    font-size: 1em;
    letter-spacing: 0.5px;
    color: var(--text-medium);
    font-weight: 500;
    box-shadow: 0 2px 8px rgba(67,97,238,0.04);
}

.filter-btn:hover, .filter-btn.active {
    background: linear-gradient(90deg, var(--primary-color) 80%, var(--primary-dark) 100%);
    color: #fff;
    border-color: var(--primary-dark);
    box-shadow: 0 4px 16px rgba(67,97,238,0.13);
    transform: translateY(-3px) scale(1.04);
}

.blog-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(340px, 1fr));
    gap: 2.8em;
    margin-bottom: var(--section-spacing);
    align-items: stretch;
}

.blog-post {
    background: var(--card-bg);
    border-radius: var(--card-radius);
    overflow: hidden;
    box-shadow: var(--card-shadow);
    border: 1.5px solid var(--card-border);
    transition: all 0.28s cubic-bezier(.4,0,.2,1);
    opacity: 1;
    transform: translateY(0);
    display: flex;
    flex-direction: column;
    min-height: 100%;
}

.blog-post:hover {
    box-shadow: var(--card-shadow-hover);
    border-color: var(--primary-color);
    transform: translateY(-10px) scale(1.012);
}

.blog-post.featured {
    grid-column: 1 / -1;
    display: grid;
    grid-template-columns: 1fr 1fr;
    min-height: 420px;
    box-shadow: 0 24px 60px rgba(67,97,238,0.13);
    border-width: 2px;
}

@media (max-width: 980px) {
    .blog-post.featured {
        grid-template-columns: 1fr;
        min-height: unset;
    }
}

/* Imagen del post más grande y con efecto */
.post-image {
    position: relative;
    height: 240px;
    overflow: hidden;
    background: #e0e7ff;
}

.blog-post.featured .post-image {
    height: 100%;
    min-height: 320px;
}

.post-image img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    transition: transform 0.6s cubic-bezier(.4,0,.2,1);
    border-radius: 0;
}

.blog-post:hover .post-image img {
    transform: scale(1.07) rotate(-1deg);
}

/* Categoría sobre la imagen */
.post-category {
    position: absolute;
    top: 1.2rem;
    left: 1.2rem;
    background: var(--primary-color);
    color: white;
    padding: 0.5rem 1rem;
    border-radius: 20px;
    font-size: 0.85rem;
    font-weight: 600;
    text-transform: uppercase;
    letter-spacing: 0.5px;
    box-shadow: 0 2px 8px rgba(67,97,238,0.09);
}

/* Contenido del post más aireado */
.post-content {
    padding: 2.2rem 2rem 1.5rem 2rem;
    display: flex;
    flex-direction: column;
    flex: 1;
}

.blog-post.featured .post-content {
    display: flex;
    flex-direction: column;
    justify-content: space-between;
    padding: 2.5rem 2.5rem 2rem 2.5rem;
}

.post-meta {
    display: flex;
    gap: 2rem;
    margin-bottom: 1.2rem;
    font-size: 1rem;
    color: var(--text-light);
}

.post-meta i {
    color: var(--primary-color);
    margin-right: 0.5rem;
}

.post-content h3 {
    font-size: 1.6rem;
    color: var(--text-dark);
    margin-bottom: 1.1rem;
    line-height: 1.4;
    font-weight: 600;
}

.blog-post.featured .post-content h3 {
    font-size: 2rem;
}

.post-content p {
    color: var(--text-medium);
    line-height: 1.6;
    margin-bottom: 1.7rem;
    font-size: 1.08em;
}

/* Etiquetas más suaves */
.post-tags {
    display: flex;
    flex-wrap: wrap;
    gap: 0.7rem;
    margin-bottom: 1.2rem;
}

.tag {
    background: linear-gradient(90deg, var(--primary-light) 80%, #f3f6fd 100%);
    color: var(--primary-dark);
    padding: 0.3rem 0.8rem;
    border-radius: 15px;
    font-size: 0.85rem;
    font-weight: 500;
    border: 1px solid #dbeafe;
}

/* Footer del post más alineado */
.post-footer {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-top: auto;
    padding-top: 1.2em;
    border-top: 1px solid #f1f5f9;
}

.author-info {
    display: flex;
    align-items: center;
    gap: 1em;
}

.author-avatar {
    width: 40px;
    height: 40px;
    border-radius: 50%;
    object-fit: cover;
    border: 2px solid #e0e7ff;
    box-shadow: 0 2px 8px rgba(67,97,238,0.07);
}

.author-details {
    display: flex;
    flex-direction: column;
}

.author-name {
    font-weight: 600;
    color: var(--text-dark);
    font-size: 1rem;
}

.author-title {
    font-size: 0.85rem;
    color: var(--text-light);
}

/* Botón leer más */
.read-more {
    color: var(--primary-color);
    font-weight: 600;
    text-decoration: none;
    transition: all var(--transition-speed);
    font-size: 1.05rem;
    padding: 0.5em 1.1em;
    border-radius: 18px;
    background: #f1f5fd;
    border: 1px solid #e0e7ef;
    margin-left: 1em;
    display: inline-flex;
    align-items: center;
    gap: 0.3em;
}

.read-more:hover {
    background: var(--primary-color);
    color: #fff;
    border-color: var(--primary-dark);
    transform: translateX(6px) scale(1.04);
}

.read-more i {
    margin-left: 0.7em;
    transition: transform var(--transition-speed);
}

/* Newsletter y CTA más modernos */
.newsletter-signup {
    background: linear-gradient(135deg, var(--primary-light), var(--primary-light-hover));
    border-radius: 22px;
    padding: 3rem 2rem;
    margin: var(--section-spacing) 0;
    text-align: center;
    border: 2.5px solid var(--primary-color);
    box-shadow: 0 8px 32px rgba(67,97,238,0.08);
}

.newsletter-content h3 {
    color: var(--text-dark);
    font-size: 2rem;
    margin-bottom: 1rem;
    font-weight: 600;
}

.newsletter-content p {
    color: var(--text-medium);
    font-size: 1.15rem;
    margin-bottom: 2rem;
    max-width: 600px;
    margin-left: auto;
    margin-right: auto;
}

.newsletter-form .form-group {
    display: flex;
    gap: 1.2rem;
    max-width: 500px;
    margin: 0 auto 2rem auto;
}

.newsletter-form input {
    flex: 1;
    padding: 1rem;
    border: 1.5px solid #e0e7ef;
    border-radius: 18px;
    font-size: 1.08rem;
}

.newsletter-form input:focus {
    border-color: var(--primary-color);
    outline: none;
    box-shadow: 0 0 0 3px rgba(67, 97, 238, 0.1);
}

.newsletter-form button {
    background: var(--primary-color);
    color: white;
    border: none;
    padding: 1rem 2rem;
    border-radius: 18px;
    font-size: 1.08rem;
    font-weight: 600;
    cursor: pointer;
    transition: all var(--transition-speed);
}

.newsletter-form button:hover {
    background: var(--primary-dark);
    transform: translateY(-2px);
}

.newsletter-benefits {
    display: flex;
    justify-content: center;
    gap: 2.5rem;
    flex-wrap: wrap;
    font-size: 1.05rem;
    color: var(--primary-dark);
    font-weight: 500;
}

/* CTA banner más llamativo */
.cta-banner {
    background: linear-gradient(135deg, var(--primary-gradient-start), var(--primary-gradient-end));
    margin: var(--section-spacing) 0;
    text-align: center;
    padding: 3rem 2rem;
    color: white;
    border-radius: 22px;
    box-shadow: 0 18px 40px rgba(67,97,238,0.18);
}

.cta-banner h3 {
    color: white;
    font-size: 2.4rem;
    margin-bottom: 1rem;
    text-shadow: 1px 1px 2px rgba(0,0,0,0.2);
    font-weight: 700;
}

.cta-banner p {
    font-size: 1.25rem;
    margin-bottom: 2rem;
    max-width: 600px;
    margin-left: auto;
    margin-right: auto;
    color: rgba(255, 255, 255, 0.9);
}

.cta-banner .button {
    background: white;
    color: var(--primary-color);
    font-weight: 700;
    transition: all var(--transition-speed);
    border-radius: 32px;
    padding: 1.1rem 2.3rem;
    font-size: 1.15rem;
    border: none;
    box-shadow: 0 8px 25px rgba(255, 255, 255, 0.3);
}

.cta-banner .button:hover {
    background: var(--primary-color);
    color: white;
    transform: translateY(-3px);
    box-shadow: 0 15px 35px rgba(255, 255, 255, 0.4);
    text-decoration: none;
}

/* Responsive mejorado */
@media screen and (max-width: 1200px) {
    #main-wrapper .container {
        max-width: 98vw;
    }
    .blog-grid {
        gap: 2em;
    }
}
@media screen and (max-width: 980px) {
    .blog-grid {
        grid-template-columns: 1fr;
        gap: 2em;
    }
    .blog-post.featured {
        grid-template-columns: 1fr;
        min-height: unset;
    }
    .hero-banner {
        padding: 3rem 1.2rem 2rem 1.2rem;
    }
    .hero-banner h2 {
        font-size: 2.3rem;
    }
    .blog-stats {
        gap: 1.5em;
    }
}
@media screen and (max-width: 768px) {
    .hero-banner {
        padding: 2rem 1.5rem;
    }
    
    .hero-banner h2 {
        font-size: 2rem;
    }
    
    .hero-subtitle {
        font-size: 1.1rem;
    }
    
    .blog-stats {
        flex-direction: column;
        gap: 1.5rem;
    }
    
    .category-filter {
        flex-direction: column;
        align-items: center;
    }
    
    .filter-btn {
        width: 200px;
    }
    
    .post-content, .blog-post.featured .post-content {
        padding: 1.2rem;
    }
    
    .newsletter-signup, .cta-banner {
        padding: 2rem 1rem;
    }
}
@media screen and (max-width: 480px) {
    .hero-banner {
        padding: 1.2rem 0.5rem;
    }
    
    .hero-banner h2 {
        font-size: 1.4rem;
    }
    
    .stat-number {
        font-size: 1.2rem;
    }
    
    .post-content h3, .blog-post.featured .post-content h3 {
        font-size: 1.1rem;
    }
    
    .newsletter-content h3, .cta-banner h3 {
        font-size: 1.1rem;
    }
}
