/*========= ナビゲーションのためのCSS ===============*/

/* アクティブになったエリア */
#g-nav.panelactive{
    /* position:fixed にし、z-indexの数値を大きくして前面へ */
    position:fixed;
    z-index: 999;
	top: 0;
    left: 0;
	width:100%;
    height: 100vh;
}

/* 丸の拡大 */
.circle-bg{
    position: fixed;
	z-index:3;
    /* 丸の形 */
    width: 100px;
    height: 100px;
    border-radius: 50%;
    background: #FFF6C4;
    /* 丸の開始位置と形状 */
	transform: scale(0);/* 最初は scale を0に */
	top:-50px;
    left:calc(50% - 50px);/* 50%から円の半径を引いた値 */
    transition: all .6s;/* 0.6秒かけてアニメーション */
}

.circle-bg.circleactive{
	transform: scale(50);/* クラスが付与されたらscaleを拡大 */
}

/* ナビゲーションの縦スクロール */
#g-nav-list{
    display: none;/* 最初は表示なし */
    /* ナビの数が増えた場合に縦スクロール */
    position: fixed;
    z-index: 999; 
    width: 100%;
    height: 100vh;
    overflow: auto;
    -webkit-overflow-scrolling: touch;
}

#g-nav.panelactive #g-nav-list{
     display: block; /* クラスが付与されたら出現 */
}

/* ナビゲーション */
#g-nav .header_g-nav_menu_list {
	opacity: 0;/* 最初は透過0 */
    /* ナビゲーションを天地中央揃え ※レイアウトによって調整可 */
    position: absolute;
    z-index: 999;
    top:50%;
    left:50%;
    transform: translate(-50%,-50%);
    width: 60%;
}

/* 背景が出現後にナビゲーションを表示 */
#g-nav.panelactive .header_g-nav_menu_list {
    opacity:1;
}

/* 背景が出現後にナビゲーション li を表示 ※レイアウトによって調整可 */
#g-nav.panelactive ul li{
animation-name:gnaviAnime;
animation-duration:1s;
animation-delay:.2s;/* 0.2秒遅らせて出現 */
animation-fill-mode:forwards;
opacity:0;
}
@keyframes gnaviAnime{
0% {
opacity: 0;
}
100% {
opacity: 1;
}
}


/* リストのレイアウト設定 */
#g-nav li{
	text-align: center; 
	list-style: none;
}

#g-nav li a{
	color: #3C71B3;
	text-decoration: none;
	padding:10px;
	display: block;
	text-transform: uppercase;
	letter-spacing: 0.1em;
	font-weight: bold;
    overflow: hidden;
}


/*========= ボタンのためのCSS ===============*/
.openbtn {
	position:fixed;
    z-index: 9999;/* ボタンを最前面に */
	top:25px;
	right: 10px;
	cursor: pointer;
    width: 30px;
    height:21px;
    display: none;
}
	
/* ×に変化 */	
.openbtn span {
    display: inline-block;
    transition: all .4s;
    position: absolute;
    left: 0;
    height: 3px;
    border-radius: 2px;
	background-color: #000;
  	width: 100%;
}
.page .openbtn span,
.scrolled .openbtn span {
    background-color: #642A2A;
}
.home .openbtn span {
    background-color: #642A2A;
}
.home .scrolled .openbtn span {
    background-color: #642A2A
}
.openbtn.openbtn.active span {
    background-color: #642A2A;
}
.openbtn span:nth-of-type(1) {
	top:0;
}

.openbtn span:nth-of-type(2) {
	top:0;
    bottom: 0;
    margin: auto;
}

.openbtn span:nth-of-type(3) {
	bottom: 0;
}

.openbtn.active span:nth-of-type(1) {
    top: 3px;
    left: 0px;
    transform: translateY(6px) rotate(-45deg);
    width: 100%;
}

.openbtn.active span:nth-of-type(2) {
	opacity: 0;
}

.openbtn.active span:nth-of-type(3){
    top: 16px;
    left: 0px;
    transform: translateY(-6px) rotate(45deg);
    width: 100%;
}

@media only screen and (max-width: 980px) {
    .openbtn {
        top: 35px;
        display: block;
    }
    #g-nav .header_contact_link {
        padding: 0;
    }
}
@media only screen and (max-width: 680px) {
    .openbtn {
        top: 27px;
    }
}
