/* ========================================================
   Single Post Section / メイン記事とサイドバー固定横並び
======================================================== */
.single-post-section {
    display: flex;
    flex-wrap: nowrap;       /* 横並び固定 */
    gap: 30px;
    box-sizing: border-box;
    width: 100%;
    padding: 65px 100px;
}

/* メイン記事部分 */
.blog-main-article {
    flex: 0 0 70%;           /* 横幅70%固定 */
    display: flex;
    flex-direction: column;
    gap: 20px;
    box-sizing: border-box;
    overflow: auto;          /* 中身が大きくても横幅固定、縦にスクロール */
    padding-right: 5%;
}

/* サイドバー部分 */
.blog-sidebar {
    flex: 0 0 30%;           /* 横幅30%固定 */
    box-sizing: border-box;
    padding-left: 5%;
    overflow: auto;          /* 中身が大きくても横幅固定、縦にスクロール */
}

/* 記事タイトル */
.blog-title {
    font-size: 32px;
    font-weight: bold;
    line-height: 1.4;
    word-wrap: break-word;
    overflow-wrap: break-word;
    word-break: break-word;
    max-width: 100%;
    text-align: left;
}

/* メタ情報 */
.blog-meta {
    font-size: 14px;
    color: #666;
}

/* 本文 */
.blog-content {
    font-size: 16px;
    line-height: 1.8;
}

/* 画像の制御 */
.content-body img {
    display: block;
    margin: 20px auto;
    max-width: 100%;
    height: auto;
}

/* 画像の縦横比調整 */
.content-body img.landscape {
    width: 100%;
    height: auto;
}
.content-body img.portrait {
    max-width: 80%;
    height: auto;
    margin: 20px auto;
    display: block;
}

/* ========================================================
   過去記事 / サイドバーカード
======================================================== */
.past-blog-posts-wrapper {
    display: flex;
    flex-direction: column;
    gap: 20px;
    width: 100%;
    box-sizing: border-box;
}

.past-post-card {
    display: flex;
    flex-direction: column;
    gap: 10px;
    min-width: 0;
}

.past-post-card-wrapper {
    display: flex;
    flex-direction: column;
    gap: 10px;
    text-decoration: none;
    color: inherit;
}

.past-post-card img {
    width: 100%;
    height: auto;
    display: block;
    object-fit: cover;       /* 画像が枠からはみ出ない */
}

.past-post-date {
    font-size: 14px;
    color: #666;
}

.past-post-card h3 {
    font-size: 16px;
    line-height: 1.4;
    overflow-wrap: break-word;
    word-break: break-word;
}

/* ========================================================
   レスポンシブ対応
======================================================== */
@media (max-width: 768px) {
    .single-post-section {
        flex-direction: column;  /* 縦並びに切り替え */
        padding: 15px 15px;
        gap: 20px;
    }

    .blog-main-article,
    .blog-sidebar {
        flex: 0 0 100%;         /* 幅100% */
    }
}