/* Estilos Generales para la sección del Blog con prefijo blg- */
.blg-section-container {
    max-width: 1200px; /* O el ancho que prefieras */
    margin: 20px auto;
    padding: 0 15px;
    font-family: Arial, Helvetica, sans-serif; /* O la fuente de tu sitio */
    direction: rtl; /* Right-to-Left para Hebreo */
}

.blg-main-title {
    text-align: center;
    margin-bottom: 30px;
    font-size: 2.5em;
    color: #333;
}

/* --- Layout Wrapper y Contenido Principal --- */
.blg-layout-wrapper {
    position: relative; /* Útil para contexto */
    text-align: right; /* Alineación derecha para contenido principal */
}

/* Área principal de contenido (Grid de artículos o detalle) */
/* SIN MARGEN IZQUIERDO - El contenido empezará debajo de la sidebar fija */
.blg-main-content,
.blg-detail-content-area {
    /* Eliminado: margin-left: 310px; */
    min-width: 0; /* Evita overflow */
}

/* --- Barra Lateral (Sidebar) - FIJA A LA IZQUIERDA --- */
.blg-sidebar {
    width: 280px; /* Ancho fijo para la sidebar */
    position: fixed; /* FIJA en la pantalla */
    left: 20px;  /* Posición desde la izquierda */
    top: 150px; /* Posición desde arriba (AJUSTA SEGÚN TU CABECERA) */
    height: fit-content; /* Ajusta altura al contenido */
    z-index: 100; /* Para que esté por encima del contenido */
}


/* Grid de 3 columnas */
.blg-post-grid {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 25px;
    /* padding-left: 15px; */ /* Podemos quitar este padding ahora */
}

/* --- Estilos comunes para Cards (Sin cambios) --- */
.blg-post-card {
    border: 1px solid #e0e0e0;
    border-radius: 8px;
    overflow: hidden;
    background-color: #fff;
    box-shadow: 0 2px 5px rgba(0, 0, 0, 0.1);
    transition: transform 0.3s ease, box-shadow 0.3s ease;
    display: flex;
    flex-direction: column;
    text-align: right;
}
.blg-post-card:hover { transform: translateY(-5px); box-shadow: 0 8px 15px rgba(0,0,0,0.15); }
.blg-card-image-container { position: relative; width: 100%; aspect-ratio: 16 / 9; }
.blg-card-image { display: block; width: 100%; height: 100%; object-fit: cover; }
.blg-card-category { position: absolute; top: 10px; left: 10px; background-color: rgba(50, 50, 50, 0.8); color: #fff; padding: 4px 10px; border-radius: 4px; font-size: 0.8em; font-weight: bold; }
.blg-card-content { padding: 15px; flex-grow: 1; display: flex; flex-direction: column; }
.blg-card-title { 
    font-size: 1.1em; 
    margin-top: 0; 
    margin-bottom: 10px; 
    font-weight: 800;
    display: -webkit-box;
    -webkit-line-clamp: 2;
    -webkit-box-orient: vertical;
    overflow: hidden;
    text-overflow: ellipsis;
    height: 2.8em; /* Altura aproximada para 2 líneas */
    line-height: 1.4;
}
.blg-card-title a { text-decoration: none; color: #000; transition: color 0.3s ease;font-weight: 800; }
.blg-card-title a:hover { color: #000000; }
.blg-card-excerpt { font-size: 0.9em; color: #666; line-height: 1.5; margin-bottom: 15px; flex-grow: 1; }
.blg-card-readmore { display: inline-block; text-decoration: none; color: #000000; font-weight: bold; margin-top: auto; align-self: flex-start; }
.blg-card-readmore:hover { text-decoration: underline; }

.blg-card-subtitle {
    ont-size: 20px;    
    color: #333;    
}

/* --- Estilos Sidebar Widget (Contenido interno - Sin cambios) --- */
.blg-sidebar-widget {
    background-color: #f8f9fa; padding: 20px; border-radius: 8px; border: 1px solid #e0e0e0; margin-bottom: 20px; text-align: right;
}
.blg-sidebar-widget:last-child { margin-bottom: 0; }
.blg-sidebar-title { font-size: 1.2em; margin-top: 0; margin-bottom: 15px; color: #333; text-align: center; font-weight: bold; }
.blg-sidebar-phone { background-color: #ffcc00; color: #333; text-align: center; padding: 15px; border-radius: 5px; font-size: 1.5em; font-weight: bold; display: flex; align-items: center; justify-content: center; gap: 10px; }
.blg-sidebar-phone-icon { width: 24px; height: 24px; display: inline-block; margin-left: 8px; }

/* --- Estilos para la página de detalle (blog-detail.html - Sin cambios estructurales aquí) --- */
/* .blg-detail-content-area ya NO tiene margin-left */
.blg-detail-header { background-color: #ffcc00; padding: 25px; margin-bottom: 30px; border-radius: 8px; text-align: center; color: #333; }
.blg-detail-title { font-size: 2.2em; margin: 0 0 10px 0; font-weight: bold; }
.blg-detail-subtitle { font-size: 1.1em; margin: 0; font-weight: normal; }
.blg-detail-phone-cta { margin-top: 20px; font-size: 1.3em; font-weight: bold; display: flex; align-items: center; justify-content: center; gap: 10px; }
.blg-detail-phone-cta .blg-sidebar-phone-icon { font-size: 1.1em; }
.blg-detail-content { background-color: #fff; padding: 25px; border: 1px solid #e0e0e0; border-radius: 8px; margin-bottom: 30px; }
.blg-detail-featured-image { width: 100%; max-height: 450px; object-fit: cover; border-radius: 8px; margin-bottom: 25px; }
.blg-detail-body { line-height: 1.7; font-size: 1.05em; color: #444; }
.blg-detail-body h2, .blg-detail-body h3, .blg-detail-body h4 { margin-top: 25px; margin-bottom: 15px; color: #222; font-weight: bold; }
.blg-detail-body h2 { font-size: 1.8em; } .blg-detail-body h3 { font-size: 1.5em; } .blg-detail-body h4 { font-size: 1.3em; }
.blg-detail-body p { margin-bottom: 15px; }
.blg-detail-body ul, .blg-detail-body ol { margin-bottom: 15px; padding-right: 20px; }
.blg-detail-body li { margin-bottom: 8px; }
.blg-detail-body strong, .blg-detail-body b { font-weight: bold; color: #000; }
.blg-related-posts { margin-top: 40px; padding-top: 30px; border-top: 1px solid #e0e0e0; }
.blg-related-title { text-align: center; margin-bottom: 30px; font-size: 1.8em; color: #333; }
.blg-related-grid { display: grid; grid-template-columns: repeat(auto-fit, minmax(250px, 1fr)); gap: 25px; }


/* --- Ajustes responsivos (Sin cambios, ya manejan el 'position: static') --- */
@media (max-width: 992px) { /* Tablets y menores */
    .blg-sidebar {
        position: static; /* Vuelve al flujo normal */
        width: 100%; /* Ocupa todo el ancho */
        margin-bottom: 30px; /* Espacio antes del contenido */
        order: -1; /* Coloca la sidebar arriba */
        left: auto; top: auto; z-index: auto; /* Resetea posición fija */
    }

    .blg-main-content,
    .blg-detail-content-area {
        /* margin-left: 0;  <- Ya no estaba, así que no hay que quitar nada aquí */
    }

    .blg-post-grid {
        grid-template-columns: repeat(2, 1fr);
        /* padding-left: 0; <- Ya no estaba */
    }
     .blg-related-grid {
        grid-template-columns: repeat(auto-fit, minmax(220px, 1fr));
    }
}

.blg-main-title-new { 
    font-size: 3em !important;
    color: #000 !important;
    font-weight: 800 !important;
}

@media (max-width: 768px) { /* Móviles */
    .blg-main-title-new { font-size: 3em; }
    .blg-detail-header { padding: 20px; }
    .blg-detail-title { font-size: 1.8em; }
    /* ... otros ajustes de tamaño de fuente ... */

    /* Una columna en móviles */
    .blg-post-grid,
    .blg-related-grid {
        grid-template-columns: 1fr;
        gap: 20px;
    }
}