.pagination {
    display: flex;
    justify-content: center;
    align-items: center;
    margin-top: 40px;
    gap: 10px;
    margin-bottom: 160px;
}

.page-numbers {
    display: flex;
    gap: 5px;
}

.page-number {
    width: 50px;
    height: 50px;
    display: flex;
    justify-content: center;
    align-items: center;
    background: none;
    cursor: pointer;
    border-radius: 50%;
    color: #444;
    /* Montserrat */
    font-family: Montserrat;
    font-size: 18px;
    font-style: normal;
    line-height: 110%;
    font-weight: 700;
}

.page-number.active {
    background: #333;
    color: white;
}

.prev-page,
.next-page {
    padding: 8px 16px;
    border-radius: 25px;
    border: 1.5px solid var(--txt, #444);
    display: flex;
    justify-content: center;
    align-items: center;
    gap: 8px;
    background: none;
    cursor: pointer;
    color: #444;
    font-family: Montserrat;
    font-size: 18px;
    font-style: normal;
    font-weight: 700;
    line-height: 170%; /* 34px */
    letter-spacing: 2px;
}
.prev-page::before{
    content: '';
    display: block;
    width: 8px;
    height: 8px;
    border-top: 2px solid #444;
    border-left: 2px solid #444;
    transform: rotate(-45deg);
}
.next-page::after{
    content: '';
    display: block;
    width: 8px;
    height: 8px;
    border-top: 2px solid #444;
    border-right: 2px solid #444;
    transform: rotate(45deg);
}
.prev-page:disabled,
.next-page:disabled {
    opacity: 0.5;
    cursor: not-allowed;
}

@media screen and (max-width: 768px) {
    .pagination {
        margin-bottom: 80px;
    }
    .page-number{
        width: 32px;
        height: 32px;
        font-size: 14px;
    }
    .prev-page,
    .next-page {
        padding: 4px 8px;
        font-size: 14px;
    }
    .ellipsis{
        padding: 4px 8px;
    }
}

#case .title{
    display: flex;
    justify-content: center;
    align-items: center;
    flex-direction: column;
    padding-top: 120px;
}
#case .title::before{
    content: '';
    display: block;
    width: 56px;
    aspect-ratio: 1/1;
    background-image: url(../images/case/title-star.webp);
    background-size: cover;
    background-repeat: no-repeat;
    background-position: center;
}
#case .title h2{
    color: #444;
    /* Noto Sans_H1 */
    font-family: "Noto Sans";
    font-size: clamp(1.5rem, 1.227rem + 1.17vw, 2.625rem);
    font-style: normal;
    font-weight: 700;
    line-height: 170%; /* 71.4px */
    letter-spacing: 4.2px;
}
#case .title span{
    color:#E0B90B;
    text-align: center;
    /* Montserrat */
    font-family: Montserrat;
    font-size: 20px;
    font-style: normal;
    font-weight: 700;
    line-height: 170%; /* 34px */
    letter-spacing: 2px;
}
.category-list{
    width: 80%;
    max-width: 1080px;
    margin: 0 auto 40px;
}
.category-list h3{
    color: #444;
    /* Noto Sans_H3 */
    font-family: "Noto Sans";
    font-size: 24px;
    font-style: normal;
    font-weight: 700;
    line-height: 170%; /* 40.8px */
    letter-spacing: 2.4px;
    margin-bottom: 16px;
}
.category-list-flex{
    display: flex;
    flex-wrap: wrap;
    justify-content: left;
    align-items: center;
    gap: 16px;
}
.category-list a{
    color: #444;
    /* Noto Sans_p */
    font-family: "Noto Sans";
    font-size: 16px;
    font-style: normal;
    font-weight: 700;
    line-height: 170%; /* 27.2px */
    letter-spacing: 1.6px;
    
    width: fit-content;
    display: flex;
    padding: 4px 16px;
    justify-content: center;
    align-items: center;
    border-radius: 21.5px;
    border: 1.5px solid #444;
}
@media screen and (max-width: 768px) {
    .category-list-flex{
        gap: 8px;
    }
    .category-list{
        margin-top: 32px;
        margin-bottom: 40px;
    }
    .category-list h3{
        font-size: 20px;
        margin: 0 0 16px;
    }
    .category-list a{
        padding: 0 10px;
    }
}

.case-list{
    width: 80%;
    max-width: 1080px;
    margin: 0 auto;
    display: grid;
    grid-template-columns: repeat(2, 1fr);
    gap: 40px;
}
.case-item{
    width: 100%;
    background: #fff;
    border-radius: 16px;
    overflow: hidden;
}
.case-item img{
    width: 100%;
    height: 280px;
    object-fit: cover;
}
.case-facility{
    width: 100%;
    background: #E0B90B;
    padding: 8px 24px;
}
.case-facility p{
    color: #F4F7F8;
    font-family: "Noto Sans";
    font-size: 14px;
    font-style: normal;
    font-weight: 700;
    line-height: 170%; /* 24.684px */
    letter-spacing: 1.452px;
}
.case-text{
    padding:16px 24px;
}
.case-title{
    color: #444;
    /* Noto Sans_H3 */
    font-family: "Noto Sans";
    font-size: 24px;
    font-style: normal;
    font-weight: 700;
    line-height: 170%; /* 40.8px */
    letter-spacing: 2.4px;
}
.case-category{
    display: flex;
    gap: 16px;
    align-items: center;
    justify-content: left;
    flex-wrap: wrap;
}
.case-category:has(.case-category-item){
    margin: 16px 0 8px;
}
.case-category-item{
    display: flex;
    justify-content: center;
    align-items: center;
    padding:4px 16px;
    border-radius: 13px;
    background: #444;
    color: #F4F7F8;
    font-family: "Noto Sans";
    font-size: 10px;
    font-style: normal;
    font-weight: 700;
    line-height: 170%; /* 16.456px */
    letter-spacing: 0.968px;
    white-space: nowrap;
}
.case-text > p{
    display: flex;
    justify-content: right;
    align-items: center;
    color: #D06135;
    /* Noto Sans_p */
    font-family: "Noto Sans";
    font-size: 16px;
    font-style: normal;
    font-weight: 700;
    line-height: 170%; /* 27.2px */
    letter-spacing: 1.6px;
}
.case-text > p::after{
    content: '';
    display: block;
    width: 8px;
    height: 8px;
    border-top: 2px solid #D06135;
    border-right: 2px solid #D06135;
    transform: rotate(45deg);
}
@media screen and (max-width: 768px) {
    .case-list{
        grid-template-columns: repeat(1, 1fr);
    }
}
/* 既存のCSSに追加 */
.ellipsis {
    padding: 8px 12px;
    color: #444;
    font-weight: bold;
}

/* エディタ用のスタイル */
.dialogue-block-editor .dialogue-item {
    border: 1px solid #ddd;
    padding: 15px;
    margin-bottom: 15px;
    background: #f9f9f9;
}

.dialogue-block-editor .dialogue-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 10px;
}

.dialogue-block-editor .dialogue-content {
    display: grid;
    grid-template-columns: 150px 1fr;
    gap: 15px;
}

.dialogue-block-editor .dialogue-image {
    grid-column: 1;
}

.dialogue-block-editor .dialogue-details {
    grid-column: 2;
}

/* single-case.php用のスタイル */
main.single-case{
    padding-top: 36px;
    width: 80%;
    max-width: 1080px;
    margin: 0 auto;
}
main.single-case > span{
    color:#E0B90B;
    text-align: center;
    /* Noto Sans_H3 */
    font-family: "Noto Sans";
    font-size: 24px;
    font-style: normal;
    font-weight: 700;
    line-height: 170%; /* 40.8px */
    letter-spacing: 2.4px;
    display: block;
    margin: 0 auto;
}
main.single-case > h1{
    color: #444;
    text-align: center;
    /* Noto Sans_H2 */
    font-family: "Noto Sans";
    font-size: 32px;
    font-style: normal;
    font-weight: 700;
    line-height: 170%; /* 54.4px */
    letter-spacing: 3.2px;
    margin-bottom:32px ;
}
.single-case-thumbnail{
    width: 100%;
}
main.single-case h2{
    display: flex;
    justify-content: left;
    align-items: center;
    gap: 32px;
    color: #444;
    text-align: center;
    /* Noto Sans_H3 */
    font-family: "Noto Sans";
    font-size: 24px;
    font-style: normal;
    font-weight: 700;
    line-height: 170%; /* 40.8px */
    letter-spacing: 2.4px;
    background: #EAEAEA;
    margin: 64px 0 24px;

}
main.single-case h2::before{
    content: '';
    display: block;
    width: 10px;
    height: 74px;
    background: #E0B90B;
}
main.single-case h3{
    width: fit-content;
    white-space: nowrap;
    color: #F4F7F8;
    /* Noto Sans_H3 */
    font-family: "Noto Sans";
    font-size: 24px;
    font-style: normal;
    font-weight: 700;
    line-height: 170%; /* 40.8px */
    letter-spacing: 2.4px;
    padding: 8px 24px;
    border-radius: 28px;
    background: #444;
    margin-bottom: 24px;
}
.case-dialogues {
    width: 100%;
}

.dialogue-item {
    display: flex;
    align-items: start;
    gap: 28px;
    margin-bottom: 32px;
    border-radius: 10px;
}

.dialogue-icon {
    width: 100px;
    aspect-ratio: 1/1;
    border-radius: 50%;
    display: flex;
    justify-content: center;
    align-items: center;
}
.dialogue-icon img{
    width: 100%;
    object-fit: cover;
    object-position: center;
}
.dialogue-icon.speaker-1{
    border: 4px solid #D06135;
}
.dialogue-icon.speaker-2{
    border: 4px solid #E0B90B;
}

.dialogue-icon img {
    width: 100%;
    height: 100%;
    border-radius: 50%;
    object-fit: cover;
}


.dialogue-name {
    display: block;
    width: fit-content;
    color: #F4F7F8;
    /* Noto Sans_p */
    font-family: "Noto Sans";
    font-size: 16px;
    font-style: normal;
    font-weight: 700;
    line-height: 170%; /* 27.2px */
    letter-spacing: 1.6px;
    padding: 0 4px;
}
.dialogue-name.speaker-1{
    background-color: #D06135;
    letter-spacing: 0;
}
.dialogue-name.speaker-2{
    background-color: #E0B90B;
    letter-spacing: 0;
}

.dialogue-text {
    flex: 1;
    padding: 15px;
    border-radius: 8px;
}


.breadcrumbs {
    padding: 100px 0 15px;
}

.breadcrumbs .inner {
    max-width: 1200px;
    margin: 0 auto;
}

.breadcrumbs ul {
    display: flex;
    list-style: none;
    margin: 0;
    padding: 0;
}

.breadcrumbs li {
    color: #444;
    font-size: 16px;
    font-family: "Noto Sans";
    font-size: 16px;
    font-style: normal;
    font-weight: 700;
    line-height: 170%; /* 27.2px */
    letter-spacing: 1.6px;
}
.breadcrumbs li:last-of-type{
    color: #E0B90B;
}

.breadcrumbs li:not(:last-child)::after {
    content: ">";
    margin: 0 10px;
    color: #666;
}

.breadcrumbs a {
    color: #666;
    text-decoration: none;
}

.breadcrumbs a:hover {
    text-decoration: underline;
}
.back-to-case{
    width: fit-content;
    height: 50px;
    padding: 8px 32px;
    margin: 0 auto;
    display: flex;
    justify-content: center;
    align-items: center;
    gap: 8px;
    border-radius: 25px;
    border: 1.5px solid #444;
    margin: 120px auto ;
}
.back-to-case p{
    color:  #444;
    font-family: Montserrat;
    font-size: 18px;
    font-style: normal;
    font-weight: 700;
    line-height: 170%; /* 34px */
    letter-spacing: 2px;
}
.back-to-case::before{
    content: '';
    display: block;
    width: 10px;
    height: 10px;
    border-top: 2px solid #444;
    border-left: 2px solid #444;
    transform: rotate(-45deg);
}
@media screen and (max-width: 768px) {
    .back-to-case{
        margin: 80px auto ;
    }
    .breadcrumbs .inner{
        width: 90%;
    }
    main.single-case{
        width: 90%;
    }

    .dialogue-item{
        gap: 8px;
    }
    .dialogue-icon{
        width: 60px;
    }
    .dialogue-icon img {
        width: 100%;
        height: 100%;
        margin-bottom: 0;
    }
}