@charset "utf-8";

/* index TOPページ ================================================== */

/* -----------------------------------------
　section #top メインコピー
-------------------------------------------- */
#top {
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 1.6rem;
    font-weight: 500;
    height: calc(100vh - 7rem);
    line-height: 2.8rem;
    padding: 0;
    text-align: center;
    z-index: 0;
    & p {
        font-family: var(--ZenMaru);
        font-weight: 500;
        transform: translateY(-7rem);
    }
    & span {
        color: var(--blue);
        font-family: var(--ZenMaru) ;
    }
    /* メイン背景画像 */
    &::before {
        content: "";
        background: url(../img/main.jpg) no-repeat bottom center / cover;
        position: absolute;
        height: 100%;
        width: 100%;
        z-index: -1;
    }
}


/* -----------------------------------------
　section #medical 診療時間
-------------------------------------------- */
#medical {
    background: var(--fff);
    padding-top: 2rem;
    padding-bottom: 1rem;
    z-index: 1;
}

/* -----------------------------------------
　section #medical 各種症状について
-------------------------------------------- */
#attention {
    display: grid;
    grid-template-columns: repeat(2, 1fr);
    gap: 1rem .5rem;
    padding-bottom: 2rem;
}

#attention img {
    box-sizing: border-box;
    border-radius: 15px;
    border: 1px solid var(--blue);
    padding: .7rem;
    &:hover {
        cursor: pointer;
        opacity: 0.8;
    }
}

.modal {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: rgba(126, 147, 165, 0.5);
    display: flex;
    justify-content: center;
    align-items: center;
    z-index: 999;

    opacity: 0;
    visibility: hidden;
    transition: opacity 0.4s ease;
}

.modal-content {
    background: var(--fff);
    box-sizing: border-box;
    padding: 2rem;
    border-radius: 15px;
    text-align: justify;
    max-width: 500px;
    width: 100%;

    opacity: 0;
    transform: scale(0.9);
    transition: all 0.4s ease;
}

.close {
    background: var(--blue);
    border-radius: 0 15px 0 15px;
    border: none;
    color: var(--fff);
    font-weight: bold;
    padding: .5rem .7rem;
    position: absolute;
    top: 0;
    right: 0;
    &:hover {
    cursor: pointer;
    opacity: 0.8;
    }
}

/* 表示状態 */
.modal.show {
    opacity: 1;
    visibility: visible;
}

.modal.show .modal-content {
    opacity: 1;
    transform: scale(1);
}

/* -----------------------------------------
　section #subject 診療科目
-------------------------------------------- */
#subject {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 1.5rem 0.5rem;
    padding-bottom: 4rem;
    text-align: center;
    & div {
    background: var(--bg_blue);
    border-radius: 2.2rem;
    font-family: var(--ZenMaru);
    font-weight: 500;
    padding: 1rem;
    }
    & img {
    display: block;
    margin: 0 auto .3rem;
    max-height: 65px;
    }
    /* 画像 波 回転 */
    &::after {
        background-position: top;
        transform: translateX(-50%) rotate(180deg);
    }
}


/* -----------------------------------------
　div .checkerboard 背景：市松模様
-------------------------------------------- */
.checkerboard {
    background: url(../img/checkerboard.jpg) repeat center /  80%;
    padding: 3rem 0 5rem;
    position: relative;
    z-index: 1;
    &::after {
        background: url(../img/bg_blue.svg) no-repeat bottom / 100%;
        border-bottom: 1px solid var(--bg_blue);/* 背景チラつき対策 */
    }
}

/* -----------------------------------------
　section #news お知らせ　※WordPress用に修正あるかも
-------------------------------------------- */
/* 枠 */
#news {
    background: var(--fff);
    border-top: 25px solid #EADCC8;
    border-left: 15px solid #EADCC8;
    border-right: 15px solid #EADCC8;
    border-bottom: 15px solid #EADCC8;
    border-radius: 15px;
    padding: 3rem 1.7rem;
    position: relative;
    margin: 0 1rem 3rem;
}

/* 背景 重ね */
#news {
    &::before {
        content: "";
        background: url(../img/news_item.png) no-repeat top / auto;
        position: absolute;
        top: -25px;
        left: 50%;
        transform: translateX(-50%);
        height: 50px;
        width: 100%;
    }
    &::after {
        content: "";
        background: url(../img/btn_texture.jpg) repeat center / 100%;
        border-radius: 15px;
        mix-blend-mode: overlay;
        opacity: 0.5;
        position: absolute;
        top: -25px;
        left: 50%;
        transform: translateX(-50%);
        height: calc(100% + 40px);
        width: calc(100% + 30px);
        z-index: -1;
    }
}

/* -----------------------------------------
　section #message 院長あいさつ
-------------------------------------------- */
#message {
    background: var(--fff);
    border-radius: 15px;
    padding: 2.5rem 1.7rem;
    margin: 1rem;
    & p {
        text-align: justify;
    }
}

.comment {
    margin-bottom: 2rem;
    margin-right: -2.7rem;
    position: relative;
}

/* 左側 見出し  */
.comment .left {
    position: relative;
    z-index: 1;
    & h2 {
        text-align: left;
        &::after {
        background-position: left;
        }
    }
    & p {
        font-family: var(--ZenMaru);
        font-size: 1.1rem;
        font-weight: 500;
        line-height: 2.2rem;
    }
}

/* 右側 院長プロフィール  */
.comment .right {
    position: absolute;
    top: 0;
    right: 0;
    text-align: center;
    z-index: 0;
    & img {
        margin-right: -.7rem;
        max-width: 135px;
    }
    & .neme {
        background: var(--bg_blue);
        border-radius: 60px 0 0 60px;
        box-shadow: var(--shadow);
        margin-top: -1rem;
        padding: 1.5rem 0 1rem .5rem;
        width: 180px;
        & span {
            color: var(--blue);
            display: flex;
            align-items: center;
            justify-content: center;
            gap: .3rem;
            font-family: var(--ZenMaru);
            font-size: .9rem;
            font-weight: 500;
            margin-bottom: .3rem;
            &::before,
            &::after {
                content: "";
                background: var(--blue);
                width: 1.5rem;
                height: 1px;
            }
        }
    }
    & ruby {
        color: var(--blue);
        font-family: var(--ZenMaru);
        font-size: 1.1rem;
        font-weight: 500;
    }
    & rp,
    & rt {
        color: var(--blue);
    }
}

/* -----------------------------------------
　section #access アクセス
-------------------------------------------- */
.bg_blue {
    background: var(--bg_blue);
    padding: 2rem 0 6rem;
    &.wave::after {
        z-index: 0;
    }
}

#access iframe {
        border-radius: 15px;
        box-shadow: var(--shadow);
        height: 280px;
        margin-top: 1rem;
        width: 100%;
}


/** mobile
===================================*/
@media screen and (max-width: 450px){

    /* -----------------------------------------
    　section #top メインコピー
    -------------------------------------------- */
    #top {
        font-size: 1.4rem;
        height: 100vh;
        & p {
            transform: translateY(-2rem);
        }
        /* メイン背景画像 */
        &::before {
            background: url(../img/main.jpg) no-repeat bottom -4rem center / cover;
        }
    }

    /* -----------------------------------------
    　section #medical 各種症状について
    -------------------------------------------- */
    #attention {
        grid-template-columns: repeat(1, 1fr);
    }

    #attention img {
        padding: .7rem 3rem;
    }

    .modal-content {
        padding: 2rem 1.5rem;
        margin: 0 1rem;
    }

    /* -----------------------------------------
    　section #subject 診療科目
    -------------------------------------------- */
    #subject {
        grid-template-columns: repeat(2, 1fr);
        gap: .5rem;
        & div {
        padding: 1.5rem 1rem;
        }
    }
    /* -----------------------------------------
    　section #message 院長あいさつ
    -------------------------------------------- */
    /* 右側 院長プロフィール  */
    .comment .right {
        top: -3.5rem;
        right: -.7rem;
        & img {
            max-width: 90px;
        }
        & .neme {
            width: 140px;
        }
    }


}