.modal-overlay {
    display: none;
    position: fixed;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background-color: rgba(42, 42, 42, .80);
    overflow: hidden;
    overflow-y: auto;
    -webkit-overflow-scrolling: touch;
    z-index: 1000;
}
.modal-container {
    display: table;
    width: 100%;
    height: 100%;
    overflow: hidden;
    table-layout: fixed;
}
.modal-inner {
    display: table-cell;
    padding: 2.7em 2em; /* モーダル外側の余白 */
    box-sizing: border-box;
    vertical-align: middle;
}
.modal-main {
    /*width: 100%;*/
    margin: 0 auto;
    padding: 0 15px 20px; /* モーダル内側の余白 */
    border-radius: 5px;
    box-sizing: border-box;
    background-color: #fff;
    position: relative;
}

#modal-close{
    position: absolute;
    display: block;
    width: 40px;
    height: 40px;
    line-height: 40px;
    top: -20px;
    right: -20px;
    border-radius: 20px;
    background: #3f3f3f;
    color: #fff;
    font-size: 24px; font-size: 2.4rem;
    text-align: center;
}

.modal-ttl{
    position: relative;
    margin: 0 -15px 24px;
    padding: 0 15px;
    border-bottom: 1px solid #d1d1d1;
    font-size: 20px; font-size: 2.0rem;
    font-weight: normal;
}

.modal-ttl .modal-close{
    position: absolute;
    top: 11px;
    right: 15px;
    height: 30px;
    line-height: 30px;
    padding: 0;
    border: none;
    background: transparent;
    cursor: pointer;
}

.modal-ttl .modal-close .material-icons{
    vertical-align: top;
    line-height: 30px;
}

@media only screen and (min-width: 768px) {

    .modal-main{
        /*max-width: 60%;*/
        max-width: 650px;
        padding: 0 32px 40px;
        box-sizing: border-box;
    }

    .modal-main.job-width{
        max-width: 400px;
        padding: 0 24px 40px;
    }

    .modal-ttl{
        margin: 0 -30px 32px;
        padding: 0 30px;
    }

    .modal-ttl .modal-close {
        top: 11px;
        right: 30px;
        height: 40px;
        line-height: 40px;
    }

    .modal-main.job-width .modal-ttl .modal-close{
        right: 24px;
    }

    .modal-ttl .modal-close .material-icons{
        line-height: 40px;
        font-size: 30px; font-size: 3.0rem;
    }

}