/* 共通
------------------------------------------*/
section {
    width: var(--main-width);
    max-width: var(--main-max-width);
    margin: 0 auto;
}

h3 {
    font-size: 1.5rem;
    font-weight: bold;
    position: relative;
}

h3::before {
    content: '';
    position: absolute;
    top: 16px;
    left: calc(-100vw - 12px);
    width: 100vw;
    height: 2px;
    background-color: var(--main-black);
}



/* 5つのステップ
------------------------------------------*/

#step {
    margin-bottom: 12rem;
    width: 94%;
}

#step h2 {
    font-weight: bold;
    text-align: center;
    margin-bottom: 6rem;
}

#step h2 span {
    font-size: 4rem;
    word-break: keep-all;
    margin-bottom: 1rem;
    display: inline-block;
}

#step h2 .border {
    border: 4px solid var(--main-black);
    padding: 1rem;
}

#step .flow {
    width: 100%;
    display: flex;
    justify-content: space-between;
    align-items: center;
}

#step .flow .icon_container {
    width: 150px;
    text-align: center;
    position: relative;
}

#step .flow .icon_container img {
    width: 100%;
}

#step .flow .icon_container p {
    font-weight: bold;
    font-size: 1.25rem;
    position: absolute;
    top: 160px;
    left: 0;
    right: 0;
    margin: 0 auto;
}

#step .flow .next {
    width: 1.25rem;
    height: 2rem;
}

@media only screen and (max-width:1100px) {
    #step h2 span {
        font-size: 3rem;
    }

    #step .flow .icon_container {
        width: 130px;
    }

    #step .flow .icon_container p {
        top: 140px;
    }
}

@media only screen and (max-width:900px) {
    #step .flow .icon_container {
        width: 105px;
    }

    #step .flow .icon_container p {
        top: 115px;
    }

    #step .flow .icon_container p {
        font-size: 1rem;
    }

    #step h2 {
        margin-bottom: 3rem;
    }
}

@media only screen and (max-width:768px) {
    #step h2 span {
        font-size: 2.5rem;
    }

    #step .flow .icon_container {
        width: 90px;
    }

    #step .flow .icon_container p {
        top: 100px;
    }

    #step .flow .next {
        width: 0.75rem;
        height: 1rem;
    }
}

@media only screen and (max-width:600px) {
    #step h2 span {
        font-size: 2rem;
    }

    #step .flow .icon_container {
        width: 60px;
    }

    #step .flow .icon_container p {
        top: 70px;
        font-size: .75rem;
    }

    #step h2 {
        margin-bottom: 1rem;
    }
}

@media only screen and (max-width:425px) {
    #step .flow .icon_container {
        width: 55px;
    }

    #step .flow .icon_container p {
        top: 65px;
    }

    #step .flow .next {
        display: none;
    }
}

/* よくある質問
------------------------------------------*/

#question {
    margin-bottom: 12rem;
}

#question .container {
    margin-bottom: 8rem;
}

#question .container .question {
    width: 100%;
    display: flex;
    align-items: center;
    border: 2px solid var(--main-black);
    margin-bottom: 2rem;
}

#question .container .question .q {
    padding: 1rem 2rem;
    font-size: 1.5rem;
    font-weight: bold;
    color: var(--main-white);
    background-color: var(--main-black);
}

#question .container .question .text {
    padding: 0 1rem;
    font-weight: bold;
    font-size: 1.25rem;
}

@media only screen and (max-width:768px) {
    #question .container .question {
        margin-bottom: 1rem;
    }

    #question .container .question .q {
        padding: .75rem 1.5rem;
    }

    #question .container {
        margin-bottom: 4rem;
    }
}

@media only screen and (max-width:600px) {
    #question .container .question .text {
        font-size: 1rem;
    }

    #question .container .question .q {
        padding: 0.75rem 1rem;
    }

    #question .container .question .q {
        font-size: 1.25rem;
    }
}



/* メッセージ
------------------------------------------*/
#message {
    margin-bottom: 10rem;
}

#message h2 {
    font-size: 4rem;
    word-break: keep-all;
    margin-bottom: 1rem;
    display: inline-block;
    word-break: keep-all;
    line-height: 1.75;
}

#message h2 .border {
    border: 4px solid var(--main-black);
    padding: .75rem 1rem;
    word-break: keep-all;
}

@media only screen and (max-width:1100px) {
    #message h2 {
        font-size: 3rem;
    }
}

@media only screen and (max-width:768px) {
    #message {
        margin-bottom: 6rem;
    }

    #message h2 {
        font-size: 2.5rem;
    }
}

@media only screen and (max-width:600px) {

    #message h2 {
        font-size: 2rem;
    }
}



/* リバ邸の特徴
------------------------------------------*/

#feature {
    margin-bottom: 12rem;
}

#feature .row {
    width: 100%;
    display: flex;
    justify-content: space-between;
    align-items: top;
    margin-bottom: 6rem;
}

#feature .img {
    margin: 0 1rem;
    width: calc(50% - 2rem);
    background-size: cover;
    background-position: center;
    height: 360px;
    border-radius: 1rem;
}

#feature .img.teigaku {
    background-size: contain;
    background-repeat: no-repeat;
    background-color: #Fff;
}

#feature .text_container {
    width: calc(50% - 1rem);
    padding: 1rem;
}

#feature .text_container h5 {
    font-size: 1.25rem;
    font-weight: bold;
}

#feature .text_container a#detail_teigaku {
    width: fit-content;
    margin-top: 4rem;
    display: flex;
    align-items: center;
    background-color: var(--main-black);
    padding: 1rem 2rem;
    border-radius: 6rem;
}

#feature .text_container a#detail_teigaku span {
    color: var(--main-white);
    margin-right: 1rem;
}

#feature .text_container a#detail_teigaku img {
    width: 16px;
}

@media only screen and (max-width:900px) {
    #feature .text_container {
        padding: 0;
    }

    #feature .text_container h5 {
        margin-top: 1rem;
    }

    #feature .img {
        height: 280px;
    }

    #feature .text_container a#detail_teigaku {
        margin-top: 2rem;
    }
}

@media only screen and (max-width:768px) {
    #feature .text_container h5 {
        margin: 1rem 0 1.5rem;
    }

    #feature .img {
        height: 260px;
    }

    #feature .text_container {
        width: calc(50% - 0.5rem);
    }
}

@media only screen and (max-width:600px) {
    #feature .row {
        display: block;
    }

    #feature .text_container h5 {
        margin: 0.5rem 0;
    }

    #feature .text_container,
    #feature .img {
        margin: 0 auto 1.5rem;
        width: 100%;
        max-width: 500px;
        padding: 0;
    }

    #feature .text_container a#detail_teigaku {
        margin: 2rem auto 0;
    }
}


/* 人生定額プラン
------------------------------------------*/

#teigaku {
    margin-bottom: 6rem;
}

#teigaku h2 {
    margin: 1.5rem 0;
    text-align: center;
    font-size: 2.5rem;
    font-weight: bold;
}

#teigaku p {
    text-align: center;
}

#teigaku .flex_container {
    margin: 6rem 0 0;
    display: flex;
    flex-wrap: wrap;
    justify-content: center;
}

#teigaku .flex_container .container {
    width: 200px;
    margin: 0 1rem 6rem;
    text-align: center;
}

#teigaku .flex_container .container.hide {
    display: none;
}

#teigaku .flex_container .container .img {
    width: 100%;
    height: 150px;
    background-size: contain;
    background-position: center;
    background-repeat: no-repeat;
    margin-bottom: 1.5rem;
}

#teigaku .flex_container .container h5 {
    font-weight: bold;
    font-size: 1rem;
    margin: 0 0 .5rem;
}

#teigaku .flex_container .container p {
    margin-bottom: 2rem;
}

#teigaku .flex_container .container a {
    text-decoration: underline;
}

#more_service_btn {
    display: block;
    margin: 0 auto;
    background-color: var(--main-black);
    color: #fff;
    font-weight: bold;
    padding: 1rem 2rem;
    border-radius: 5rem;
    width: fit-content;
    min-width: 200px;
    text-align: center;
    cursor: pointer;
}

@media only screen and (max-width:768px) {
    #teigaku h2 {
        margin-bottom: 1rem;
    }

    #teigaku .flex_container {
        margin-top: 2rem;
    }

    #teigaku .flex_container .container p {
        margin-bottom: 1rem;
    }

    #teigaku .flex_container .container {
        margin-bottom: 4rem;
    }
}

@media only screen and (max-width:600px) {
    #teigaku h2 {
        font-size: 2rem;
    }

    #teigaku .flex_container .container .img {
        margin-bottom: 1rem;
    }
}


/* 入居者の声
------------------------------------------*/
#voice {
    margin-bottom: 12rem;
}

#voice h3 {
    margin-bottom: 4rem;
}

#voice .row {
    position: relative;
    width: 100%;
    height: 360px;
    margin-bottom: 6rem;
}

#voice .row .img_container {
    position: absolute;
    left: 1rem;
    top: 0;
    width: 220px;
    z-index: 1;
}

#voice .row .img_container .img {
    width: 100%;
    height: 280px;
    background-size: cover;
    background-position: center;
    display: block;
    border-radius: 1rem;
    margin-bottom: .5rem;
}

#voice .row .img_container p {
    padding: 0 1rem;
    font-weight: bold;
}

#voice .row .img_container p span {
    word-break: keep-all;
}

#voice .row .content {
    position: absolute;
    width: calc(100% - 140px);
    padding: 1.5rem 3rem 3rem 140px;
    right: 0;
    top: 3rem;
    background-color: var(--main-middlegray);
    border-radius: 1rem;
    min-height: 300px;
}

#voice .row .content h5 {
    font-size: 1.75rem;
    font-weight: bold;
    margin: 0 0 1rem;
    word-break: keep-all;
}

#voice .row .content ul {
    padding-left: 1rem;
}

/* 遇数 */
#voice .row:nth-child(odd) .img_container {
    left: auto;
    right: 1rem;
}

#voice .row:nth-child(odd) .content {
    padding: 1.5rem 140px 3rem 3rem;
    right: auto;
    left: 0;
}

@media only screen and (max-width:1000px) {
    #voice .row {
        height: 440px;
    }
}

@media only screen and (max-width:768px) {
    #voice .row .content {
        width: calc(100% - 120px);
    }

    #voice .row {
        height: 500px;
    }

    #voice .row .content {
        padding: 1.5rem 1rem 1rem 120px;
    }

    #voice .row .content h5 {
        font-size: 1.25rem;
    }

    #voice .row .img_container {
        width: 200px;
    }

    #voice .row .img_container p {
        padding: 0 .5rem;
    }

    #voice .row .content {
        top: 2rem;
    }
}


@media only screen and (max-width:600px) {
    #voice .row {
        height: auto;
        padding-top: 0;
        position: relative;
    }

    #voice .row .content {
        position: relative;
        width: 100%;
        padding: 1rem;
        top: auto;
    }

    #voice .row .img_container {
        position: relative;
        top: auto;
        right: auto;
        left: auto;
        width: 100%;
        margin-bottom: 1rem;
    }

    #voice .row:nth-child(odd) .img_container {
        right: auto;
    }

    #voice .row:nth-child(odd) .content {
        padding: 1rem;
    }
}


/* インタビュー
------------------------------------------*/
#interview {
    margin-bottom: 12rem;
}

#interview .container {
    width: 100%;
    height: 330px;
    text-align: right;
    position: relative;
    margin-bottom: 4rem;
    display: block;
}


#interview .container .img {
    display: inline-block;
    height: 330px;
    width: 500px;
    max-width: 100%;
    min-width: 40%;
    background-position: center;
    background-size: cover;
    border-radius: .5rem;
}

#interview .container .message {
    position: absolute;
    bottom: 1.5rem;
    left: 0;
    padding: 2rem;
    background-color: var(--main-black);
    text-align: left;
    clip-path: polygon(0% 100%, 0% 0%, 100% 0%, 90% 100%);
    width: fit-content;
    min-width: 70%;
}

#interview .container .message h4,
#interview .container .message p {
    color: var(--main-white);
}

#interview .container .message h4 {
    font-size: 1.25rem;
    font-weight: bold;
    margin: 0 0 .5rem;
}

#interview .black_btn {
    margin: 6rem auto 0;
    width: fit-content;
    display: block;
    min-width: 200px;
}

@media only screen and (max-width:850px) {
    #interview .container .message {
        padding: 1rem;
    }
}


@media only screen and (max-width:768px) {
    #interview {
        margin-bottom: 10rem;
    }

    #interview .container .img {
        width: 400px;
        height: 250px;
    }

    #interview .container {
        height: 250px;
    }

    #interview .container .message {
        bottom: 1rem;
    }

    #interview .container .message p {
        padding-right: 1rem;
    }

    #interview .container .message h4 {
        font-size: 1.125rem;
    }
}

@media only screen and (max-width:600px) {
    #interview .container .img {
        width: 90%;
        margin-left: 10%;
    }

    #interview .container .message {
        bottom: -5rem;
        width: 90%;
    }

    #interview .container {
        margin-bottom: 10rem;
    }
}

@media only screen and (max-width:475px) {
    #interview .container .message h4 {
        font-size: 1rem;
    }

    #interview .container .message p {
        font-size: .875rem;
    }
}

/* お問合せ
------------------------------------------*/

#contact {
    margin-bottom: 12rem;
}

#contact h4 {
    width: fit-content;
    text-align: left;
    font-size: 2rem;
    font-weight: bold;
    margin: 0 auto 5rem;
    word-break: keep-all;
}

#contact a {
    margin: 0 auto;
    padding: 1.5rem 3rem;
    background-color: var(--main-red);
    display: flex;
    align-items: center;
    justify-content: center;
    border-radius: .25rem;
    width: 80%;
    max-width: 600px;
    position: fixed;
    bottom: 1rem;
    left: 0;
    right: 0;
    margin: 0 auto;
    z-index: 10;
}

#contact a img {
    margin-right: .5rem;
}

#contact a span {
    color: var(--main-white);
    font-weight: bold;
}

@media only screen and (max-width:768px) {
    #contact h4 {
        font-size: 1.75rem;
    }

    #contact a {
        width: 500px;
        max-width: 90vw;
    }
}

@media only screen and (max-width:600px) {
    #contact a {
        padding: 1rem;
    }
}

@media only screen and (max-width:475px) {
    #contact h4 {
        font-size: 1.5rem;
    }
}

@media only screen and (max-width:425px) {
    #contact h4 {
        font-size: 1.25rem;
    }
}