/* 
organization.css
*/

/* ==============================
detail
============================== */
.detail {
    .wrapper {
        display: flex;
        flex-direction: column;
        gap: 50px;
    }

    .detail__flex {
        display: flex;
        flex-direction: column;
        gap: 50px;
    }

    .image__wrapper {
        position: relative;
        width: 100%;
        height: 240px;
        margin-top: 50px;
        margin-bottom: 20px;
        
        img {
            position: absolute;
            z-index: 10;
            width: 100%;
            height: 100%;
            overflow: hidden;
            border-radius:5px;
            box-shadow: 0 4px 4px 0 rgb(0 0 0 / 25%);
            object-fit: cover;
            object-position: center;
        }
    }

    .detail__flex-wrapper p {
        line-height: var(--line-height-sxl);
    }

    .image__wrapper::after {
        position: absolute;
        bottom: -20px;
        z-index: 1;
        width: 100vw;
        height: 100%;
        margin-right: calc(50% - 50vw);
        margin-left: calc(50% - 50vw);
        content: '';
    }

    .detail__flex:nth-of-type(1) {
        .image__wrapper {
            img {
                top: 0;
                left: 0;
                margin-left: calc(50% - 50vw);
            }
        }

        .image__wrapper::after {
            background: linear-gradient(270deg, rgb(255 255 255 / 60%) 20%, rgb(174 227 244 / 60%) 100%);
        }
    }

    .detail__flex:nth-of-type(2) {
        .image__wrapper {
            height: 360px;

            img {
                top: 0;
                right: 0;
                margin-right: calc(50% - 50vw);
                box-shadow: none;
            }
        }

        .image__wrapper::after {
            background: linear-gradient(90deg, rgb(255 255 255 / 60%) 20%, rgb(174 227 244 / 60%) 100%);
        }
    }
}

.detail__flex-inner {
    display: flex;
    flex-direction: column;
    gap: 30px;
}

@media (width >= 768px) {
    .detail {
        .wrapper {
            gap: 80px;
            max-width: none;
            padding: 60px 0;
        }
        
        p {
            position: relative;
            z-index: 40;
            flex: 1;
            width: auto;
        }

        .detail__flex {
            position: relative;
        }

        .detail__flex-wrapper {
            display: flex;
            flex-direction: row-reverse;
            align-items: center;
            justify-content: space-between;
            gap: 50px;
            width: 100%;
            max-width: 1240px;
            margin: 0 auto;
            padding: 0 20px;

            p {
                line-height: var(--line-height-xl);        
            }
        }

        .detail__flex-wrapper--reverse {
            flex-direction: row;
            max-width: 1240px;
        }

        .detail__flex--reverse {
            flex-direction: row;
        }

        .detail__flex::after {
            position: absolute;
            top: 0;
            left: 0;
            display: block;
            width: 100%;
            height: 100%;
            content: '';
        }

        .detail__flex:nth-of-type(1)::after {
            background: linear-gradient(90deg, rgb(255 255 255 / 60%) 20%, rgb(174 227 244 / 60%) 100%);
        }

        .detail__flex:nth-of-type(2)::after {
            background: linear-gradient(270deg, rgb(255 255 255 / 60%) 20%, rgb(174 227 244 / 60%) 100%);
        }

        .image__wrapper {
            position: relative;
            width: 100%;
            height: 300px;
            max-width: 50%;
            margin-top: 0;
            margin-bottom: 0;
            
            img {
                position: relative;
            }
        }

        .image__wrapper::after {
            display: none;
        }

        .detail__flex:nth-of-type(1) {
            .image__wrapper {
                img {
                    position: absolute;
                    top: -30px;
                    right: 0;
                    left: auto;
                    margin-right: auto;
                }
            }
        }

        .detail__flex:nth-of-type(2) {
            .image__wrapper {
                width: 30%;
                height: 300px;

                img {
                    position: absolute;
                    top: -30px;
                    right: auto;
                    left: 0;
                    height: 300px;
                    margin-left: auto;
                }
            }
        }
    }
}

@media (width >=  1240px) {
    .detail {
        .detail__flex:nth-of-type(1) {
            margin-left: calc((100% - 1040px) / 2 );
        }
        
        .detail__flex:nth-of-type(2) {
            margin-right: calc((100% - 1040px) / 2 );
        }
    }
}

/* ==============================
design
============================== */
.design__inner {
    padding: 30px 0;
    background: linear-gradient(0deg, rgb(255 255 255 / 60%) 60%, rgb(174 227 244 / 60%) 100%);
    border-top: 1px solid var(--color-black);
    border-bottom: 1px solid var(--color-black);
}

.design__image {
    width: 300px;
    height: 240px;
    margin: 0 auto;
}

.design__text {
    display: flex;
    flex-direction: column;
    gap: 20px;
    margin-top: 50px;
    line-height: var(--line-height-normal);
    text-align: center;
}

.design__button {
    display: block;
    width: 200px;
    margin: 50px auto 0;
    padding: 10px 0;
    font-size: var(--font-size-base);
    text-align: center;
    border: 1px solid var(--color-black);
}

@media (width >= 768px) {
    .design .wrapper {
        max-width: 1000px;
    }

    .design__inner {
        display: flex;
        flex-direction: row-reverse;
        align-items: center;
        justify-content: center;
        gap: 60px;
        width: calc(80% + 60px);
        margin: 0 auto;
        padding: 30px;
        background: linear-gradient(270deg, rgb(174 227 244 / 40%) 0%, rgb(255 255 255 / 40%) 70.19%);
    }

    .design__image {
        width: 300px;
        height: 240px;

        img {
            width: 100%;
            height: 100%;
            object-fit: cover;
            object-position: center;
        }
    }

    .design__flex {
        flex: 1;
    }

    .design__text {
        gap: 30px;
        margin-top: 0;
        text-align-last: left;
    }

    .design__button {
        display: flex;
        align-items: center;
        justify-content: center;
        width: 300px;
        height: 60px;
        margin-top: 30px;
        margin-left: 0;
        font-size: var(--font-size-medium);
        color: var(--color-base);
        background-color: var(--color-gradient-dark);
        border: 2px solid var(--color-gradient-dark);
        transition: var(--transition-base);

        &:hover {
            color: var(--color-black);
            background-color: var(--color-base);
        }
    }
}

/* ==============================
experience
============================== */
.experience__list {
    margin-top: 50px;
}

.experience__item {
    display: flex;
    flex-direction: column;
    gap: 10px;
    padding: 10px;
    line-height: var(--line-height-normal);
    border-bottom: 1px solid var(--color-black);
    
    h3 {
        font-size: 18px;
        font-weight: 700;
    }
}

.item__flex {
    display: flex;
    justify-content: space-between;
}

.experience__button {
    display: block;
    width: 200px;
    margin: 50px auto 0;
    padding: 10px 0;
    font-size: var(--font-size-base);
    text-align: center;
    border: 1px solid var(--color-black);
}

@media (width >= 768px) {
    .experience .wrapper {
        max-width: 1000px;
    }

    .experience__list {
        width: 80%;
        margin: 50px auto 0;
    }

    .experience__item {
        flex-direction: row;
        gap: 60px;


        h3 {
            font-size: var(--font-size-medium);
        }
    }

    .item__flex {
        flex: 1;
        justify-content: space-between;

        p {
            display: flex;
            align-items: center;
            justify-content: space-between;
        }
    }

    .experience__button {
        width: 300px;
        height: 60px;
        font-size: var(--font-size-medium);
        border: 2px solid var(--color-primary);
        transition: var(--transition-base);

        &:hover {
            color: var(--color-base);
            background-color: var(--color-primary);
        }
    }
}

/* ==============================
size-chart-modal
============================== */
.size-chart-modal {
    position: fixed;
    top: 0;
    left: 0;
    z-index: 9999;
    display: none;
    width: 100%;
    height: 100%;
    opacity: 0;
    transition: opacity 0.3s ease;
}

.size-chart-modal.is-active {
    display: block;
    opacity: 1;
}

.size-chart-modal__overlay {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background-color: rgb(0 0 0 / 70%);
    backdrop-filter: blur(2px);
}

.size-chart-modal__content {
    position: relative;
    width: 95%;
    height: 90vh;
    max-width: 1200px;
    max-height: 800px;
    margin: 5vh auto;
    background: var(--color-base);
    box-shadow: 0 10px 40px rgb(0 0 0 / 30%);
    animation: modal-slide-in 0.3s ease;
}

@keyframes modal-slide-in {
    from {
        opacity: 0;
        transform: translateY(-20px);
    }

    to {
        opacity: 1;
        transform: translateY(0);
    }
}

.size-chart-modal__iframe {
    width: 100%;
    height: 100%;
    border: none;
}

/* モバイル対応 */
@media (width <= 768px) {
    .size-chart-modal__content {
        width: 95%;
        height: 95vh;
        margin: 2.5vh auto;
        padding: 40px 15px 15px;
    }
    
    .size-chart-modal__close {
        top: 10px;
        right: 15px;
        width: 35px;
        height: 35px;
        font-size: 32px;
    }
}