/* =============================================================================
   BLOG SECTION — Figma 112:4108 / 112:3372 (Seccion articulos Specs)
   Fondo Hero: Púrpura oscuro + gradientes + trazo SVG
   Fondo Artículos: Ancho completo (100% full-width) en gris claro #F8F8F8 + Vectores SVG + Tarjetas blancas #FFFFFF
   ============================================================================= */

.profic-blog-section {
    position: relative;
    width: 100%;
    /* Padding interno del diseño (bajo menú fijo) — no es el padding de Elementor Avanzado */
    padding: 180px 0 0;
    margin-bottom: 0;
    box-sizing: border-box;
    display: flex;
    flex-direction: column;
    align-items: center;
    background-color: #090511;
    background-image: 
        linear-gradient(54.96deg, rgba(0, 0, 0, 0.55) 19.438%, rgba(93, 15, 236, 0.55) 100%),
        radial-gradient(circle at 50% 24%, rgba(93, 15, 236, 0.77) 0%, rgba(72, 13, 181, 0.8275) 25%, rgba(51, 10, 127, 0.885) 50%, rgba(30, 8, 72, 0.9425) 75%, rgba(20, 6, 44, 0.97125) 87.5%, rgba(9, 5, 17, 1) 100%);
    z-index: 1;
    overflow: hidden;
}

/* Linea de Fondo / Vectores SVG (Figma 112:4108) */
.profic-blog-bg-strokes {
    position: absolute;
    inset: 0;
    pointer-events: none;
    z-index: 0;
    overflow: hidden;
}

.profic-blog-stroke-container {
    position: absolute;
    left: -709px;
    top: -274px;
    width: 1255px;
    height: 1163px;
    transform: rotate(15deg);
    opacity: 0.85;
}

.profic-blog-stroke-svg {
    display: block;
    width: 100%;
    height: 100%;
}

/* Cabecera de la Sección (Hero SEO) */
.profic-blog-header {
    position: relative;
    z-index: 2;
    width: 100%;
    max-width: 1040px;
    padding: 0 20px;
    box-sizing: border-box;
    text-align: center;
    margin-bottom: 56px;
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 20px;
}

.profic-blog-title {
    font-family: 'Amsi Pro', sans-serif;
    font-size: clamp(32px, 4.5vw, 48px);
    line-height: 1.05em;
    color: #FFFFFF;
    margin: 0;
    white-space: nowrap;
}

.profic-blog-title-bold {
    font-weight: 700;
}

.profic-blog-title-light {
    font-weight: 300;
}

.profic-blog-subtitle {
    font-family: 'Amsi Pro', sans-serif;
    font-weight: 300;
    font-size: clamp(16px, 2vw, 20px);
    line-height: 1.5em;
    letter-spacing: 0.2px;
    color: #FFFFFF;
    margin: 0;
}

/* Barra Categorías — Figma: 1040×35, gap 20, order 1, align-self stretch */
.profic-blog-categories-bar {
    display: flex;
    flex-wrap: nowrap;
    justify-content: center;
    align-items: center;
    align-self: stretch;
    gap: 20px;
    width: 1040px;
    max-width: 100%;
    height: 35px;
    margin: 0;
    flex: none;
    flex-grow: 0;
    box-sizing: border-box;
}

/* Categorías — Figma Descripcion: Predeterminado / Hover / Pressed
 * Hover & Pressed: solo fill rgba(0,0,0,0.2). Sin translate/scale/shadow. */
.profic-blog-category-pill {
    position: relative;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    box-sizing: border-box;
    height: 35px;
    padding: 10px 20px;
    border: none;
    border-radius: 42px;
    background: transparent;
    color: #FFFFFF;
    font-family: 'Amsi Pro', sans-serif;
    font-weight: 400;
    font-size: 11px;
    line-height: 1.38em;
    letter-spacing: 1.1px;
    cursor: pointer;
    white-space: nowrap;
    outline: none;
    box-shadow: none;
    filter: none;
    transform: none;
    scale: 1;
    flex: none;
    flex-shrink: 0;
    transition: background-color 0.3s ease-in, color 0.3s ease-in;
}

/* Stroke absolute inset-0 (Figma) — no mueve el box */
.profic-blog-category-pill::after {
    content: "";
    position: absolute;
    inset: 0;
    border: 1px solid #5d0fec;
    border-radius: inherit;
    pointer-events: none;
}

.profic-blog-category-pill:hover,
.profic-blog-category-pill:focus-visible {
    background: rgba(0, 0, 0, 0.2);
    color: #FFFFFF;
    box-shadow: none !important;
    filter: none !important;
    transform: none !important;
    scale: 1 !important;
}

.profic-blog-category-pill:hover::after,
.profic-blog-category-pill:focus-visible::after {
    border-color: #5d0fec;
}

/* Pressed */
.profic-blog-category-pill:active {
    background: rgba(0, 0, 0, 0.2);
    box-shadow: none !important;
    transform: none !important;
    scale: 1 !important;
}

.profic-blog-category-pill:active::after {
    border-color: rgba(0, 0, 0, 0.2);
}

/* Selección activa (filtro) — sin glow/float */
.profic-blog-category-pill.is-active {
    background: rgba(0, 0, 0, 0.2);
    color: #FFFFFF;
    box-shadow: none;
    transform: none;
}

.profic-blog-category-pill.is-active::after {
    border-color: rgba(0, 0, 0, 0.2);
}

/* =============================================================================
   SECCIÓN ARTÍCULOS ANCHO COMPLETO (Figma Node 112:3372 — Full Width #F8F8F8)
   ============================================================================= */

.profic-blog-articles-container {
    position: relative;
    z-index: 2;
    width: 100%;
    max-width: 100%;
    margin-top: 20px;
    margin-bottom: 0;
    padding: 80px 120px 80px;
    box-sizing: border-box;
    background-color: #F8F8F8;
    border-radius: 0; /* Ancho completo de borde a borde */
    display: flex;
    flex-direction: column;
    align-items: center;
    overflow: hidden;
}

/* Vectores SVG Decorativos de Fondo de Sección Artículos (Figma Node 112:3372) */
.profic-blog-articles-bg-vectors {
    position: absolute;
    inset: 0;
    pointer-events: none;
    z-index: 0;
    overflow: hidden;
}

.profic-blog-articles-svg {
    display: block;
    width: 100%;
    height: 100%;
    object-fit: cover;
}

.profic-blog-grid {
    position: relative;
    z-index: 2;
    width: 100%;
    max-width: 1200px;
    display: grid;
    grid-template-columns: repeat(6, 1fr);
    gap: 25px;
}

/* Tarjeta de Entrada — Figma 2:6081: sin elevación / scale en hover */
.profic-blog-card {
    display: flex;
    flex-direction: column;
    background-color: #FFFFFF;
    border: 1px solid rgba(9, 5, 17, 0.06);
    border-radius: 21px;
    height: 440px;
    box-sizing: border-box;
    overflow: hidden;
    box-shadow: 0 4px 20px rgba(0, 0, 0, 0.05);
    transform: none;
    transition: none;
}

.profic-blog-card-link {
    display: flex;
    flex-direction: column;
    height: 100%;
    width: 100%;
    color: inherit;
    text-decoration: none;
}

.profic-blog-card:hover,
.profic-blog-card:focus-within {
    transform: none !important;
    box-shadow: 0 4px 20px rgba(0, 0, 0, 0.05);
    border-color: rgba(9, 5, 17, 0.06);
    filter: none;
}

.profic-blog-card-image-wrap {
    width: 100%;
    height: 180px;
    background-color: #EBEBEB;
    overflow: hidden;
    position: relative;
    flex-shrink: 0;
}

.profic-blog-card-image {
    width: 100%;
    height: 100%;
    object-fit: cover;
    transform: none;
}

.profic-blog-card-info {
    flex: 1;
    padding: 20px;
    display: flex;
    flex-direction: column;
    justify-content: space-between;
    box-sizing: border-box;
    background-color: #FFFFFF;
}

.profic-blog-card-text {
    display: flex;
    flex-direction: column;
    gap: 14px;
}

.profic-blog-card-category {
    font-family: 'Amsi Pro', sans-serif;
    font-weight: 400;
    font-size: 9px;
    line-height: 1.38em;
    letter-spacing: 0.54px;
    color: #5D0FEC;
    text-transform: uppercase;
    margin: 0;
}

.profic-blog-card-title {
    font-family: 'Amsi Pro', sans-serif;
    font-weight: 600; /* SemiBold */
    font-size: 20px;
    line-height: 1.32em;
    color: #090511;
    margin: 0;
    min-height: 52px;
    display: -webkit-box;
    -webkit-line-clamp: 2;
    -webkit-box-orient: vertical;
    overflow: hidden;
}

.profic-blog-card-excerpt {
    font-family: 'Amsi Pro', sans-serif;
    font-weight: 400;
    font-size: 13px;
    line-height: 1.38em;
    color: #090511;
    margin: 0;
    display: -webkit-box;
    -webkit-line-clamp: 2;
    -webkit-box-orient: vertical;
    overflow: hidden;
}

.profic-blog-card-footer {
    display: flex;
    justify-content: space-between;
    align-items: center;
    border-top: 1px solid rgba(9, 5, 17, 0.08);
    padding-top: 12px;
    margin-top: 10px;
}

.profic-blog-card-author {
    font-family: 'Amsi Pro', sans-serif;
    font-weight: 400;
    font-size: 13px;
    line-height: 1.38em;
    color: #090511;
    margin: 0;
}

.profic-blog-card-date {
    font-family: 'Amsi Pro', sans-serif;
    font-weight: 400;
    font-size: 13px;
    line-height: 1.38em;
    color: #8C8C8C;
    text-align: right;
    margin: 0;
}

/* =============================================================================
   REJILLA PROGRESIVA RESPONSIVE
   - Fila 1 (Post 1): 1 sola tarjeta a 100% ancho (span 6)
   - Fila 2 (Posts 2 & 3): 2 tarjetas a 50% ancho (span 3 cada una)
   - Fila 3 en adelante (Posts 4+): 3 tarjetas por fila (span 2 cada una)
   ============================================================================= */

/* DESKTOP (≥1280px) */
@media (min-width: 1280px) {
    /* Fila 1: 1 Columna (100% ancho) */
    .profic-blog-grid .profic-blog-card:nth-child(1) {
        grid-column: span 6;
        height: 460px;
    }

    .profic-blog-grid .profic-blog-card:nth-child(1) .profic-blog-card-image-wrap {
        height: 311.8px;
    }

    .profic-blog-grid .profic-blog-card:nth-child(1) .profic-blog-card-info {
        height: 148px;
    }

    /* Fila 2: 2 Columnas (50% ancho cada una) */
    .profic-blog-grid .profic-blog-card:nth-child(2),
    .profic-blog-grid .profic-blog-card:nth-child(3) {
        grid-column: span 3;
        height: 440px;
    }

    .profic-blog-grid .profic-blog-card:nth-child(2) .profic-blog-card-image-wrap,
    .profic-blog-grid .profic-blog-card:nth-child(3) .profic-blog-card-image-wrap {
        height: 182.4px;
    }

    /* Fila 3 en adelante: 3 Columnas (33.33% ancho cada una) */
    .profic-blog-grid .profic-blog-card:nth-child(n+4) {
        grid-column: span 2;
        height: 440px;
    }

    .profic-blog-grid .profic-blog-card:nth-child(n+4) .profic-blog-card-image-wrap {
        height: 180px;
    }
}

/* TABLET (800px - 1279px) */
@media (min-width: 800px) and (max-width: 1279px) {
    .profic-blog-section {
        padding: 140px 0 0;
    }

    .profic-blog-articles-container {
        padding: 60px 40px 60px;
    }

    .profic-blog-header {
        gap: 30px;
    }

    .profic-blog-stroke-container {
        left: -658px;
        top: -334px;
    }

    /* Fila 1: 1 Columna (100% ancho) */
    .profic-blog-grid .profic-blog-card:nth-child(1) {
        grid-column: span 6;
        height: 473.8px;
    }

    .profic-blog-grid .profic-blog-card:nth-child(1) .profic-blog-card-image-wrap {
        height: 311.8px;
    }

    .profic-blog-grid .profic-blog-card:nth-child(1) .profic-blog-card-info {
        height: 162px;
    }

    /* Fila 2 y en adelante en Tablet: 2 Columnas (50% ancho cada una) */
    .profic-blog-grid .profic-blog-card:nth-child(n+2) {
        grid-column: span 3;
        height: 440px;
    }

    .profic-blog-grid .profic-blog-card:nth-child(n+2) .profic-blog-card-image-wrap {
        height: 180px;
    }
}

/* MOBILE (<800px) */
@media (max-width: 799px) {
    .profic-blog-section {
        padding: 100px 0 0;
        background-image: 
            linear-gradient(77.73deg, rgba(0, 0, 0, 0.55) 19.438%, rgba(93, 15, 236, 0.55) 100%),
            radial-gradient(circle at 50% 24%, rgba(93, 15, 236, 0.77) 0%, rgba(72, 13, 181, 0.8275) 25%, rgba(51, 10, 127, 0.885) 50%, rgba(30, 8, 72, 0.9425) 75%, rgba(20, 6, 44, 0.97125) 87.5%, rgba(9, 5, 17, 1) 100%);
    }

    .profic-blog-articles-container {
        padding: 40px 16px 40px;
        border-radius: 0;
    }
    
    .profic-blog-header {
        margin-bottom: 32px;
        margin-top: 32px;
        gap: 20px;
    }

    .profic-blog-categories-bar {
        width: 100%;
        height: auto;
        min-height: 35px;
        flex-wrap: wrap;
        gap: 10px;
    }

    .profic-blog-category-pill {
        height: auto;
        min-height: 35px;
        padding: 8px 16px;
        font-size: 11px;
    }
    
    .profic-blog-grid {
        grid-template-columns: 1fr;
        gap: 20px;
    }
    
    .profic-blog-card {
        grid-column: span 1 !important;
        height: 440px;
        width: 100%;
    }

    .profic-blog-grid .profic-blog-card:nth-child(1) {
        height: 460px;
    }

    .profic-blog-grid .profic-blog-card:nth-child(1) .profic-blog-card-image-wrap {
        height: 191px;
    }

    .profic-blog-stroke-container {
        left: -709px;
        top: -274px;
    }

    .profic-blog-pagination {
        gap: 16px;
    }
}

/* Paginación Numerada en Fondo Claro (Figma Frame100: 28px x 28px, radius 3px) */
.profic-blog-pagination {
    position: relative;
    z-index: 2;
    display: flex;
    justify-content: center;
    align-items: center;
    gap: 20px;
    margin-top: 50px;
    margin-bottom: 24px;
    width: 100%;
}

.profic-blog-pagination-item {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 28px;
    height: 28px;
    border-radius: 3px;
    background: transparent;
    border: none;
    color: #090511;
    font-family: 'Amsi Pro', sans-serif;
    font-weight: 600;
    font-size: 16px;
    line-height: 1.32em;
    text-decoration: none;
    transition: all 0.3s ease;
    cursor: pointer;
}

.profic-blog-pagination-item:hover {
    background: rgba(93, 15, 236, 0.1);
    color: #5D0FEC;
}

.profic-blog-pagination-item.is-active,
.profic-blog-pagination-item.current {
    background: #FFFFFF;
    color: #090511;
    box-shadow: 0 2px 8px rgba(0, 0, 0, 0.15);
}
