﻿@charset "utf-8";

/* --------------------------------------
/*　スライダー
-----------------------------------------*/
.sl-area {
     position: relative;
     padding-bottom: 58%; /*アスペクト比 2000:1151(ボタン表示分)の場合の縦幅 PC用画像*/
     height: 0;
     overflow: hidden;
}
.sl-area-sp {
     position: relative;
     padding-bottom: 55%; /*アスペクト比 600:300+30(ボタン表示分)の場合の縦幅 SP用画像*/
     height: 0;
     overflow: hidden;
}

.sl {
     position: absolute;
     top: 0;
     left: 0;
     width: 100%;
     height: 100%;
}
.out{
    position: relative;
}
.in img{
    position: absolute;
    top: 0;
    left: 0;
    opacity: 0;
    transition: .5s;
    z-index: 0;
}
.out img{
    display: block;
    width: 100%;
    height: auto;
}
.out input{
    display: none;
}
.in{
    display: flex;
    justify-content: center;
}
.in label span{
    display: block;
    width: 3rem;
    height: 3rem;
    padding: 0.5rem;
    margin: -8rem 1rem 0;
    border-radius: 100%;
    cursor: pointer;
    position: relative;
    z-index: 10;
}
.in label span::before{
    content: "";
    display: block;
    width: 100%;
    height: 100%;
    background: #666;
    opacity: 0.5;
    border-radius: 100%;
}
.out input:nth-of-type(1):checked ~ .in label:nth-of-type(1) span::before,
.out input:nth-of-type(2):checked ~ .in label:nth-of-type(2) span::before,
.out input:nth-of-type(3):checked ~ .in label:nth-of-type(3) span::before {
    background: #fff;
    opacity: 1;
}
/*  表示5秒、切り替え0.5秒 */
.in label span::before{
    animation: slidebutton 16.5s infinite;       /* 5.5×画像枚数=a */
}
@keyframes slidebutton{
    0%{opacity: 1;background: #666;}
    3.03%{opacity: 1;background: #fff;}     /* 0.5÷a×100=b */
    33.33%{opacity: 1;background: #fff;}    /* 100÷画像枚数=c */
    36.36%{opacity: 1;background: #666;}  /* b+c */
}           
.in label:nth-of-type(2) span::before,
.in label:nth-of-type(2) img{
    animation-delay: 5.5s;
}            
.in label:nth-of-type(3) span::before,
.in label:nth-of-type(3) img{
    animation-delay: 11s;
}
.out input:nth-of-type(1):checked ~ .in label:nth-of-type(1) img,
.out input:nth-of-type(2):checked ~ .in label:nth-of-type(2) img,
.out input:nth-of-type(3):checked ~ .in label:nth-of-type(3) img {
    opacity: 1;
    z-index: 1;
}
.in img{
    animation: slide 16.5s infinite;       /* 5.5×画像枚数=a */
    opacity: 0;
}
@keyframes slide{
    0%{opacity: 0;}
    3.03%{opacity: 1;z-index: 1;}     /* 0.5÷a×100=b */
    33.33%{opacity: 1;}               /* 100÷画像枚数=c */
    36.36%{opacity: 0;z-index: 0;}    /* b+c */
}
.out input:checked ~ .in img,
.out input:checked ~ .in span::before{
    animation: none;
}
/*
.in:hover img,
.in:hover span::before{
    animation-play-state:paused;/* マウスを載せると一時停止
}
 */
