body{
  font-family:sans-serif;
  margin:0;
  background:#f5f5f5;
}

header{
  background:#232f3e;
  color:#fff;
  padding:25px;
  text-align:center;
}

#pageTitle{
  margin:0;
  font-size:34px;
}

#pageDesc{
  margin-top:10px;
}

#quizList{
  display:flex;
  flex-wrap:wrap;
  justify-content:center;
  gap:12px;
  padding:20px;
}

#quizList a{
  display:inline-flex;
  align-items:center;
  justify-content:center;
  min-width:180px;
  min-height:50px;
  padding:12px 20px;
  background:#ff9900;
  color:#fff;
  text-decoration:none;
  font-weight:bold;
  font-size:16px;
  border-radius:10px;
  border:2px solid #ff9900;
  box-sizing:border-box;
  transition:all .2s;
}

#quizList a:hover{
  background:#e88a00;
  transform:translateY(-2px);
}

#quizList a.active{
  background:#232f3e;
  border-color:#232f3e;
  color:#fff;
}

main{
  display:flex;
  justify-content:center;
  padding:20px;
}

.quiz-box{
  background:#fff;
  width:900px;
  max-width:95%;
  padding:30px;
  border-radius:12px;
  box-shadow:0 0 8px rgba(0,0,0,.15);
}

.status{
  display:flex;
  justify-content:space-between;
  font-size:18px;
  margin-bottom:15px;
}

.progress{
  width:100%;
  height:12px;
  background:#ddd;
  border-radius:20px;
  overflow:hidden;
  margin-bottom:20px;
}

#progressBar{
  width:0;
  height:100%;
  background:#ff9900;
  transition:.3s;
}

#question{
  font-size:26px;
  margin-bottom:20px;
}

#choices{
  display:flex;
  flex-direction:column;
  gap:12px;
}

#choices button{
  padding:15px;
  font-size:18px;
  cursor:pointer;
  border:none;
  border-radius:8px;
  background:#ececec;
  transition:.2s;
}

#choices button:hover{
  background:#d5d5d5;
}

#result{
  font-size:20px;
  font-weight:bold;
  margin-top:20px;
  text-align:center;
}

#nextBtn{
  display:none;
  width:100%;
  margin-top:20px;
  padding:15px;
  font-size:18px;
  background:#ff9900;
  color:#fff;
  border:none;
  border-radius:8px;
  cursor:pointer;
}

#nextBtn:hover{
  opacity:.85;
}

@media (max-width:768px){
  #pageTitle{
    font-size:26px;
  }

  #question{
    font-size:22px;
  }

  #choices button{
    font-size:16px;
  }

  #quizList a{
    width:100%;
    min-width:unset;
    min-height:48px;
    font-size:15px;
  }
}

/* ---------- レイアウト ---------- */

.layout{

    display:flex;

    justify-content:center;

    align-items:flex-start;

    gap:20px;

    padding:20px;

}

/* ---------- 広告 ---------- */

.ad-box{

    width:220px;

    min-height:600px;

    background:#fff;

    border-radius:10px;

    padding:10px;

    box-shadow:0 0 6px rgba(0,0,0,.1);

    box-sizing:border-box;

    position:sticky;

    top:20px;

}

/* ---------- クイズ ---------- */

.quiz-box{

    flex:1;

    max-width:900px;

    background:#fff;

    padding:30px;

    border-radius:12px;

    box-shadow:0 0 8px rgba(0,0,0,.15);

}

/* ---------- スマホ ---------- */

@media(max-width:1000px){

    .layout{

        display:block;

    }

    .ad-box{

        display:none;

    }

    .quiz-box{

        max-width:100%;

        width:100%;

    }

}