/* 共通ブロック */

.l-page {
    padding-top: 60px;
    background: url("../images/blog/l-page_bg.jpg") center / cover no-repeat;
}

.content_space {
    width: calc(100% - 40px);
    margin: 0 auto;
}

.fv {
    margin: 40px 0;
}

.main_title {
    font-size: 24px;
    font-weight: bold;
    line-height: calc(35 / 24);
    text-align: center;
}

@media (min-width:768px) {

    .l-page {
        padding-top: 100px;
    }

    .content_space {
        max-width: 1032px;
        width: 100%;
    }

    .fv {
        background: rgba(255, 255, 255, 0.8);
        margin: 0;
        padding: 60px 0;
    }
}

/* コンテンツブロック */


/*-- カテゴリ・タグ --*/


/* カテゴリ */

.pc-category__box {
    display: none;
}

.sp-category__box {
    position: relative;
    width: 100%;
    overflow: hidden;
}

.sp-category__box .sp-nav__list {
    margin: 0;
}

.search_box {
    background: rgba(255, 255, 255, 0.8);
    padding: 40px 0;
}

.search_title {
    width: 100%;
    max-width: 328px;
    background: #DDD4B6;
    border-radius: 8px;
    font-size: 20px;
    font-weight: 500;
    line-height: calc(29 / 20);
    text-align: center;
    padding: 18px 40px;
    margin: 0 auto 40px;
}

/* お悩み */

.section_search--worries {
    overflow: visible;
}

.section_search--worries .search_title {
    margin-bottom: 25px;
}


.tag_list {
    display: flex;
    align-items: center;
    flex-wrap: wrap;
    gap: 16px 8px;
}


.tag_item a {
    width: 104px;
    background: #fff;
    border-radius: 2px;
    padding: 4px 8px;
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 2px;
    font-size: 14px;
    font-weight: 400;
    color: var(--main-color);
    line-height: calc(20 / 14);
    font-family: var(--main-font);
    overflow: hidden;
    box-shadow: 0px 0px 4px 0px rgba(0, 0, 0, 0.25);
    transition: .5s;
}

.tag_icon {
    width: 16px;
    height: 16px;
    background: url("../images/blog/tag_icon.png") center / cover no-repeat;
}

/* ホバー時 */

.tag_item a:hover {
    background: #7B682C;
    color: var(--point-color);
}

.tag_item a:hover .tag_icon {
    background: url("../images/blog/tag_icon_on.png") center / cover no-repeat;
}

.sp-nav__panel {}

.wp-pagenavi {
    display: flex;
    justify-content: center;
    margin-top: 80px;
}

.wp-pagenavi a:hover, .wp-pagenavi span.current {
    width: 40px;
    height: 40px;
    display: flex;
    justify-content: center;
    align-items: center;
    border: none;
    /* background: var(--main-color); */
    border-radius: 50%;
    border: none;
}

.wp-pagenavi span.current {
    color: #fff;
    background-color: #7B682C;

}

body .wp-pagenavi a, body .wp-pagenavi span {
    border: none;
    color: #000;
}

.page.larger, .page.smaller {
    width: 40px;
    height: 40px;
    display: flex;
    justify-content: center;
    align-items: center;
    flex-wrap: wrap;
    overflow: hidden;
    font-size: 14px;
    font-weight: 500;
    /* background-color: #036EB8; */
    border: none;
}

.previouspostslink {
    width: 40px;
    height: 40px;
    text-indent: 10000px;
    background: url(../img/send__arrow.svg) 0 0 no-repeat;
    background-size: 20px 20px;
    background-position: center center;
}

.nextpostslink {
    width: 40px;
    height: 40px;
    text-indent: 10000px;
    background: url(../img/send__arrow.svg) 0 0 no-repeat;
    background-size: 20px 20px;
    background-position: center center;
    transform: rotate(180deg);
}

@media (min-width:768px) {


    /* カテゴリ */

    .section_search--category {
        margin-bottom: 25px;
    }

    .sp-category__box {
        display: none;
    }

    .pc-category__box {
        display: block;
    }

    .category_list {
        display: grid;
        grid-template-columns: 90px 130px 155px 100px 113px;
        align-items: start;
        gap: 40px;
    }

    .category_title {
        font-size: 14px;
        font-weight: 500;
        line-height: calc(20 / 14);
        text-align: center;
        margin-bottom: 25px;
    }

    .category_item {
        position: relative;
    }

    .category_item:not(:last-child)::after {
        content: "";
        position: absolute;
        left: 115%;
        top: 0;
        transform: translateX(-50%);
        width: 1px;
        height: 23px;
        background: #979797;
    }

    /* 微調整 */
    .category_item:first-child::after {
        left: 125%;
    }

    .category_item:nth-child(2)::after {
        left: 115%;
    }

    .category_item:nth-child(3)::after {
        left: 113%;
    }

    .category_item:nth-child(4)::after {
        left: 120%;
    }

    .category_item_detail_list {
        display: flex;
        flex-direction: column;
        gap: 12px;
        max-width: 90px;
        margin: 0 auto;
        position: relative;
    }

    .category_item_detail_list::after {
        content: "";
        position: absolute;
        left: 50%;
        top: -15px;
        transform: translateX(-50%);
        width: 0;
        height: 0;
        border-style: solid;
        border-width: 6px 4px 0;
        border-color: #9D0505 transparent transparent;
    }

    .category_item_detail_item a {
        font-size: 14px;
        font-weight: 400;
        color: var(--main-color);
        line-height: calc(20 / 14);
    }

    .search_flex_box {
        display: flex;
        align-items: center;
        gap: clamp(20px, 4vw, 65px);
    }

    .search_title {
        max-width: 240px;
        flex: 0 0 240px;
    }

    .section_search--category .search_title {
        margin: 0;
        padding: 80px 30px;
    }

    .section_search--worries .search_title {
        margin: 0;
    }

    .tag_list {
        gap: 12px 16px;
    }

    .tag_item a {
        width: 120px;
        padding: 4px 16px;
    }
}

/* スクロールバーで調整 */
@media (max-width:1166px) {
    .pc-category__box {
        overflow-x: auto;
        -webkit-overflow-scrolling: touch;
        padding-bottom: 8px;
    }

    .category_list {
        min-width: 728px;
    }
}


/*---------
ブログ
----------*/



.section_content--blog {
    padding: 80px 0;
}

.blog_list {
    display: flex;
    justify-content: center;
    flex-direction: column;
    gap: 40px;
    margin-bottom: 40px;
}


.blog_item {
    max-width: 300px;
    width: 100%;
    background: #fff;
    box-shadow: 0px 0px 8px 0px rgba(0, 0, 0, 0.25);
    margin: 0 auto;
}

.blog_detail {
    display: block;
    width: 100%;
    color: var(--main-color);
}

.blog_visual {
    position: relative;
}

.blog_photo {
    aspect-ratio: 300/200;
}

.blog_photo img {
    width: 100%;
    height: 100%;
    display: block;
    object-fit: cover;
}

.category_badge {
    position: absolute;
    top: 0;
    left: 0;
    background: #7B682C;
    font-size: 12px;
    font-weight: 400;
    color: var(--point-color);
    line-height: calc(20 / 12);
    padding: 1px 16px;
    border-radius: 0 0 3px 0;
    z-index: 1;
}

.blog_description {
    padding: 16px;
}

.date_text {
    font-size: 14px;
    font-weight: 300;
    line-height: calc(18 / 14);
    margin-bottom: 8px;
}

.blog_title {
    font-size: 18px;
    font-weight: 500;
    line-height: calc(24 / 18);
    display: -webkit-box;
    -webkit-box-orient: vertical;
    -webkit-line-clamp: 2;
    overflow: hidden;
    margin-bottom: 8px;
}

.blog_text {
    font-size: 16px;
    font-weight: 400;
    line-height: calc(24 / 16);
    display: -webkit-box;
    -webkit-box-orient: vertical;
    -webkit-line-clamp: 2;
    overflow: hidden;
}

/* ページャー */
.pager {
    display: flex;
    justify-content: center;
    align-items: center;
    gap: 8px;
}

.pager__list {
    display: flex;
    gap: 8px;
    list-style: none;
    padding: 0;
    margin: 0;
}

/* 数字ボタン */
.pager__link {
    display: flex;
    align-items: center;
    justify-content: center;
    width: 40px;
    height: 40px;
    border-radius: 50%;
    font-size: 16px;
    font-weight: bold;
    text-decoration: none;
    color: #000;
    background: transparent;
    transition: background .3s, color .3s;
}

/* アクティブ*/
.pager__link.is-current {
    background: #7B682C;
    color: #fff;
}

/* 矢印ボタン共通 */
.pager__arrow {
    width: 32px;
    height: 32px;
}

.category_accordion_box {
    overflow: hidden;
    max-height: 0;
    transition: max-height 0.3s ease;
}

.sidebar_category_item.is-open .category_accordion_box {
    max-height: 999px;
    /* JSで正確に制御するので大きめでOK */
}

/* --- 基本設定：すべてのパネルを非表示 --- */
.sp-nav__panel {
    display: none;
}

/* --- 表示設定：is-activeがついているパネルは表示 --- */
/* !important をつけて優先順位を上げます */
.sp-nav__panel.is-active {
    display: block !important;
}

/* --- リンクのアニメーション設定 --- */
.sp-nav__item_link {
    /* なめらかに動く設定 (0.3秒) */
    transition: transform 0.3s ease, opacity 0.3s ease;
    transform: translateX(0);
    /* 通常位置 */
    opacity: 1;
}

/* --- 移動中の状態（左へスライドして消える） --- */
.sp-nav__panel.is-moved .sp-nav__item_link {
    transform: translateX(-100%);
    /* 左に100%移動 */
    opacity: 0;
    /* フェードアウト */
}

@media (min-width:768px) {

    .section_content--blog {
        padding: 60px 0 130px;
    }

    .blog_list {
        flex-direction: row;
        flex-wrap: wrap;
        gap: 24px;
        margin-bottom: 60px;
        justify-content: flex-start;
    }

    .blog_item {
        max-width: 328px;
        margin: 0;
        transition: .3s;
    }

    .blog_item:hover {
        box-shadow: none;
    }

    /* ページャー */

    .pager {
        gap: 16px;
    }

    .pager__list {
        gap: 16px;
    }

    .pager__link:hover {
        background: #7B682C;
        color: #fff;
    }
}