.modal-overlay {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: rgba(255, 0, 177, 0.9);
    z-index: 9999;
    display: none;
    justify-content: center;
    align-items: center;
    opacity: 0;
    transition: opacity 0.3s ease;
}

.modal-overlay.is-active {
    display: flex;
    opacity: 1;
}

.modal-container {
    background: #fff;
    width: 90%;
    max-width: 960px;
    max-height: 90vh;
    overflow-y: auto;
    position: relative;
    padding: 40px;
    box-sizing: border-box;
    border-radius: 8px;
}

.modal-body {
    transition: opacity 0.3s ease;
    opacity: 1;
}

.modal-close {
    position: fixed;
    top: 15px;
    right: 20px;
    background: none;
    border: none;
    font-size: 2.5rem;
    cursor: pointer;
    line-height: 1;
    color: #fff;
}

.modal-layout {
    display: flex;
    flex-wrap: wrap;
    gap: 30px;
    align-items: flex-start;
}

.modal-layout figure {
    flex: 1 1 200px;
    margin: 0;
    font-size: 0.7em;
    line-height: 3;
}

.modal-layout figure img {
    width: 100%;
    height: auto;
    display: block;
}

.modal-layout .text {
    flex: 1 1 300px;
}
.modal-layout .text span {
    font-size: 0.7em;
    color: #FF00B1;
}
/* ナビゲーションボタン */
.modal-nav {
    position: absolute;
    top: 50%;
    transform: translateY(-50%);
    width: 60px;
    height: 100px;
    background: none;
    border: none;
    cursor: pointer;
    z-index: 10000;
    opacity: 0.6;
    transition: opacity 0.3s;
    outline: none;
}

.modal-nav:hover {
    opacity: 1;
}

.modal-prev {
    left: 2%;
}
.modal-next {
    right: 2%;
}

/* 矢印の描画 */
.modal-nav::after {
    content: '';
    display: block;
    width: 30px;
    height: 30px;
    border-top: 4px solid #fff;
    border-right: 4px solid #fff;
    position: absolute;
    top: 50%;
    left: 50%;
}

.modal-prev::after {
    transform: translate(-25%, -50%) rotate(-135deg);
}
.modal-next::after {
    transform: translate(-75%, -50%) rotate(45deg);
}

/* スマホ対応 */
@media (max-width: 768px) {
    .modal-nav {
        width: 44px;
        height: 44px;
        background: rgba(0, 0, 0, 0.5);
        /* 視認性確保のため背景追加 */
        border-radius: 50%;
    }
    .modal-prev {
        left: 10px;
    }
    .modal-next {
        right: 10px;
    }
    .modal-nav::after {
        width: 12px;
        height: 12px;
        border-width: 2px;
    }
}
