/************************ ナビ指定 ***************************/

@media only screen and (max-width: 599px) {
	/*トグルボタン指定*/
	.openbtn1{
		position:fixed;
		z-index: 9999;
		top: 10px;
		right: 10px;
		cursor: pointer;
		width: 50px;
		height: 50px;
	}
	.openbtn1 span{
		display: inline-block;
		transition: all .4s;
		position: absolute;
		left: 14px;
		height: 2px;
		border-radius: 2px;
		background-color: #4e4e4e;
		width: 45%;
	}
	.openbtn1 span:nth-of-type(1) {
		top: 15px;
	}
	.openbtn1 span:nth-of-type(2) {
		top: 23px;
	}
	.openbtn1 span:nth-of-type(3) {
		top: 31px;
	}
	.openbtn1.active span:nth-of-type(1) {
		top: 18px;
		left: 18px;
		transform: translateY(6px) rotate(-45deg);
		width: 30%;
		background-color: #fff;
	}
	.openbtn1.active span:nth-of-type(2) {
		opacity: 0;
		background-color: #fff;
	}
	.openbtn1.active span:nth-of-type(3){
		top: 30px;
		left: 18px;
		transform: translateY(-6px) rotate(45deg);
		width: 30%;
		background-color: #fff;
	}

/*閉じている状態のスタイル*/
	#main-nav {
		z-index: -1;
		opacity: 0;
	}

/*開いた時のスタイル*/
	#main-nav.panelactive{
		position: fixed;
		top: 0;
		left: 0;
		width: 100%;
		height: 100vh;
		background: #4e4e4e;
		transition: all 0.3s;
		padding-top: 3em;
		opacity: 1;
		z-index: 999;
	}

	#main-nav.panelactive #main-nav-list{
		position: fixed;
		z-index: 999;
		width: 100%;
		height: 100vh;
		overflow: auto;
		-webkit-overflow-scrolling: touch;
	}

	#main-nav li{
		list-style: none;
		text-align: center;
	}

	#main-nav li.deco{
		color: #333;
		text-decoration: none;
		display: block;
		text-transform: uppercase;
		letter-spacing: 0.1em;
	}
	#main-nav.panelactive li a:hover{
		color: #cacaca;
	}

	#main-nav li span{
		display: none;
	}

	#main-nav ul.gnav {
		display: none;
		opacity: 0;
		z-index: -1;
	}
	#main-nav.panelactive ul.gnav  {
		display: block;
		opacity: 1;
		width: 60%;
		margin: 0 auto;
	}

	.gnav li{
		width: 80%;
		left: 5%;
		list-style: none;
		position: relative;
	}
	.gnav li a{
		color: #fff;
		display: block;
		line-height: 3rem;
		text-align: left;
		text-decoration: none;
		webkit-transition-duration: 0.3s;
		-moz-transition-duration: 0.3s;
		transition-duration: 0.3s;
	}
	#main-nav li.deco{
		color: #4e4e4e;
		display: block;
		line-height: 3rem;
		text-align: left;
		text-decoration: none;
		webkit-transition-duration: 0.3s;
		-moz-transition-duration: 0.3s;
		transition-duration: 0.3s;
	}
	.gnav ul li{
		width: 100%;
		left: 10%;
	}
}


/*------------------PC表示---------------------*/

@media only screen and (min-width: 600px) {
	#main-nav{
		width: 50%;
		display: flex;
		position: absolute;
		right: 0;
		font-size: 0.8em;
		margin-top: 0.5rem;
	}
	#main-nav ul{
		max-width: 1240px;
		text-align: center;
		right: 0;
		position: absolute;
		z-index: 9999 !important;
	}
	#main-nav li{
		display: inline-block;
		text-align: center;
	}
	#main-nav li span{
		display: flex;
		font-size: 0.5em;
		text-transform: uppercase;
		line-height: 1.4;
		justify-content: center;
	}
	#main-nav li a{
		text-decoration: none;
	}

	#main-nav li ul li a{
		color: #333;
		text-decoration: none;
	}
	.gnav{
		display: flex;
		height: 3rem;
		margin: 0 auto;
		color: #fff;
	}
	.gnav li.deco{
		list-style: none;
		position: relative;
	}
	.gnav li a{
		display: block;
		line-height: 1rem;
		text-align: center;
		text-decoration: none;
		webkit-transition-duration: 0.3s;
		-moz-transition-duration: 0.3s;
		transition-duration: 0.3s;
		border-right: 1px solid #cacaca;
		padding: 0 1.6em;
	}
	.gnav li.no-bd a{
		border-right: none;
	}
	.gnav li:hover > ul{
		 display: block;
	}
	.gnav ul{
		display: none;
		position: absolute;
		top: 3.2em;
		left: 0;
		width:18em !important;
		text-align: center;
	}
	.gnav ul li{
		display: flex !important;
		padding: 1em 0.5em!important;
		text-align: center !important;
		background: #e6e6e6 !important;
		border-bottom: 1px solid #cacaca;
		justify-content: left;
	}
	.gnav ul li:last-child{
		border-bottom: none;
	}
	.gnav ul li:hover{
		background: #cacaca !important;
	}
	.gnav ul li a{
		border-right: none;
	}

	/*hover時のアニメーション効果*/

	#main-nav .gnav li a {
		position: relative;
		display: inline-block;
	}
	#main-nav .gnav li a::after {
		position: absolute;
		bottom: -4px;
		left: 1em;
		content: '';
		width: 70%;
		height: 2px;
		background: #cacaca;
		transform: scale(0, 1);
		transform-origin: center top;
		transition: transform .3s;
	}
	#main-nav .gnav li a:hover::after {
		transform: scale(1, 1);
	}
	#main-nav .gnav .deco>ul li a::after{
		background: none;
	}
}


