@charset "utf-8";
body {
    overflow-x: hidden;
}

#hmenu {
    display: none;
}

#slide-menu {
    display: none;
}

@media screen and (max-width: 868px) {
    .h-area {
        display: flex;
        flex-direction: row-reverse;
        height: 5.5rem;
        padding: 0;
        align-items: center;
    }

    #hmenu {
        color: #f5f5f5;
        display: block;
        cursor: pointer;
        margin: 1em;
        flex-direction: column;
        align-items: center;
        position: fixed;
        top: 1em;
        right: 1em;
        width: 2.5em;
        height: 1.9em;
        transition: .35s ease-in-out;
        z-index: 888;
    }

    #hmenu line {
        color: #f5f5f5;
        background: #1e1e1e;
        width: 100%;
        position: absolute;
        height: 4px;
        transition: all .3s;
    }

    #hmenu line:first-of-type {
        top: 0;
    }

    #hmenu line:nth-of-type(2) {
        top: 50%;
        transform: translateY(-50%);
    }

    #hmenu line:last-of-type {
        bottom: 0%;
    }

    #slide-menu {
        background: #f5f5f5;
        display: grid;
        justify-content: center;
        position: fixed;
        top: 0;
        width: 100vw;
        height: 100%;
        text-align: left;
        transition: .3s;
        transform: translateX(100%);
        z-index: 777;
    }

    #slide-menu .wrap_gnav {
        position: relative;
        width: 85vw;
        height: 80%;
        margin: 5em auto auto auto;
    }

    #slide-menu ul {
        width: 20rem;
        list-style: none;
        margin: 0 auto;
        padding: 0;
        display: flex;
        flex-direction: column;
        flex-wrap: wrap;
        justify-content: space-around;
        gap: 30px 30px;
    }

    #slide-menu li {
        list-style: none;
        background: #f5f5f5;
        min-width: 250px;
        height: auto;
        padding: 0;
    }

    #slide-menu li a,
    #slide-menu p a {
        font-size: clamp(1.5rem, 2vw + 1rem, 2.25rem);
        font-weight: 600;
        color: #1e1e1e;
    }

    #slide-menu p {
        margin: 2em auto auto;
        width: 24rem;
        text-align: center;
    }

    .gray,
    .red {
        font-family: "FOT-UD角ゴ_ラージ Pr6N R";
    }

    .gray {
        color: #ccc;
        font-size: 2.3rem;
        letter-spacing: -1px;
        padding: 0 1rem;
    }

    .red {
        color:crimson;
        font-weight: 800;
    }

    .wrap_gnav ul li a,
    .wrap_gnav p a {
        position: relative;
        display: inline-block;
    }

    .wrap_gnav ul li a::before {
        content: '';
        position: absolute;
        left: 1rem;
        bottom: -.5rem;
        width: 3rem;
        height: 2px;
        transform: scale(0, 1);
        transform-origin: center top;
        transition: transform .15s;
        background: #51666f;
    }

    .wrap_gnav ul li:hover .gray {
        animation: spot-blue 1.7s infinite;
    }
    .wrap_gnav p:hover .gray {
        animation: spot-arrow 1.7s infinite;
    }

    @keyframes spot-blue {
        0% {
            color: #ccc;
        }
        40% {
            color: #51666f;
            padding-right: 2rem;
        }
        100% {
            color: #51666f;
            padding-right: 2rem;
        }
    }

    @keyframes spot-arrow {
        0% {
            color: #ccc;
        }
        40% {
            color: #51666f;
            padding-right: 0;
        }
        100% {
            color: #51666f;
            padding-right: 0;
        }
    }

    .wrap_gnav ul li:hover a::before,
    .wrap_gnav p:hover a::before {
        transform: scale(1, 1);
    }

    #hmenu.active line:first-of-type {
        top: 50%;
        transform: rotate(45deg); 
        background: #51666f;
    }

    #hmenu.active line:nth-of-type(2) {
        display: none;
    }

    #hmenu.active line:last-of-type {
        top: 50%;
        transform: rotate(-45deg);
        background: #51666f;    }
        
    #slide-menu.active {
        transform: translateX(0);
    }
}

@media screen and (max-width: 390px) {
    .h-area {
        height: 4rem;
    }

    #hmenu {
        top: .5em;
        right: .5em;
    }
}