/* === BLOG 2カラム：PC(>=960px) 最終オーバーライド === */
@media (min-width: 960px){
  body.blog_ #content_w{
    display: grid !important;
    grid-template-columns: minmax(0,1fr) 240px !important; /* 左=本文 / 右=サイド */
    column-gap: 32px !important;
    max-width: 1000px !important;
    width: calc(100% - 40px) !important;
    margin: 0 auto !important;
    float: none !important; position: static !important; clear: none !important;
  }

  /* 左カラム */
  body.blog_ #content_w > #content{
    grid-column: 1 !important;
    min-width: 0 !important; width: auto !important;
    float: none !important; position: static !important; clear: none !important;
  }
  body.blog_ #content #con_box{
    max-width: 720px !important;           /* 読みやすい本文幅 */
    padding: 40px 0 20px !important;
    box-sizing: border-box !important;
  }

  /* 右カラム（サイド固定240px） */
  body.blog_ #content_w > #side_box{
    grid-column: 2 !important;
    width: 240px !important; max-width: 240px !important;
    position: static !important; right: auto !important; top: auto !important;
    float: none !important; clear: none !important;
    align-self: start !important; justify-self: start !important;
    padding-top: 20px !important;
    box-sizing: border-box !important;
  }

  /* 旧clearfixを無効化 */
  body.blog_ #content_w::after{ content: none !important; display: none !important; }
}

/* 画像のはみ出し防止（保険） */
body.blog_ #con_box img{ max-width: 100% !important; height: auto !important; }


/* === BLOG 2カラム：Gridレイアウト 最終調整 === */

body.blog_ #content_w{
  max-width:1000px !important;
  width:calc(100% - 40px) !important;
  margin:0 auto !important;
  box-sizing:border-box !important;
  display:grid !important;
  grid-template-columns:minmax(0,1fr) 240px !important;
  column-gap:32px !important;
  align-items:start !important;
  justify-items:stretch !important;  
  
}

body.blog_ #content #con_box{
  padding:40px 0 20px !important; 
}

body.blog_ #side_box{
  width:240px !important;
  max-width:240px !important;
  justify-self:start !important;
  position:static !important;
  float:none !important;
  padding-top:40px !important;
  box-sizing:border-box !important;
  margin-top:60px;
}

@media (max-width:1023px){
  body.blog_ #content_w{
    grid-template-columns:1fr !important;
    column-gap:0 !important;
    width:calc(100% - 24px) !important;
  }
  body.blog_ #side_box{ width:auto !important; max-width:none !important; }
}


/* ============================
   PC用（共通）
============================ */

/* 本文中の画像（サムネイル以外） */
body.blog_ #con_box img:not(.img) {
  max-width: 560px !important;   /* ← ここ重要！ */
  height: auto;
}

/* スマホ時は全幅 */
@media screen and (max-width: 767px) {
  body.blog_ #con_box img:not(.img) {
    max-width: 100% !important;
    height: auto !important;
  }
}
