Pen Settings

HTML

CSS

CSS Base

Vendor Prefixing

Add External Stylesheets/Pens

Any URL's added here will be added as <link>s in order, and before the CSS in the editor. If you link to another Pen, it will include the CSS from that Pen. If the preprocessor matches, it will attempt to combine them before processing.

+ add another resource

JavaScript

Babel includes JSX processing.

Add External Scripts/Pens

Any URL's added here will be added as <script>s in order, and run before the JavaScript in the editor. You can use the URL of any other Pen and it will include the JavaScript from that Pen.

+ add another resource

Packages

Add Packages

Search for and use JavaScript packages from npm here. By selecting a package, an import statement will be added to the top of the JavaScript editor for this package.

Behavior

Save Automatically?

If active, Pens will autosave every 30 seconds after being saved once.

Auto-Updating Preview

If enabled, the preview panel updates automatically as you code. If disabled, use the "Run" button to update.

Format on Save

If enabled, your code will be formatted when you actively save your Pen. Note: your code becomes un-folded during formatting.

Editor Settings

Code Indentation

Want to change your Syntax Highlighting theme, Fonts and more?

Visit your global Editor Settings.

HTML

              
                <html lang="ja">
<head>
<meta charset="utf-8">
<meta name="viewport" content="width=device-width,initial-scale=1.0,minimum-scale=1.0">

<title>YesNo診断</title>
<meta name="outbrain-crawl" content="no-rec">
<meta http-equiv="X-UA-Compatible" content="IE=edge,chrome=1">
<meta name="description" content="" />
<meta name="keywords" content="" />
<link rel="stylesheet" href="css/reset.css" type="text/css">
<link rel="stylesheet" href="css/style.css?" type="text/css">
<link href="https://fonts.googleapis.com/earlyaccess/mplus1p.css" rel="stylesheet" />
<link href="https://maxcdn.bootstrapcdn.com/font-awesome/4.7.0/css/font-awesome.min.css" rel="stylesheet" integrity="sha384-wvfXpqpZZVQGK6TAh5PVlGOfQNHSoD2xbE+QkPxCAFlNEevoEH3Sl0sibVcOQVnN" crossorigin="anonymous">


</head>
<body>

<header id="commonHeader">
<section id="flowsHead" class="wf-mplus1p">あなたにあった〇〇が1分でわかる</section>
<section id="flows" class="wf-mplus1p">〇〇診断</section>
</header>

<div id="wrapper">
    <main>
        <article id="pageBody">

            <div class="point_box">
            <div class="box">
            <div class="txt">
            <p>1分だけ下記の質問に答えてみてください。ぴったりの〇〇がわかります!</p>
            </div>
            </div>
            </div>


            <ul class="qalist wf-mplus1p">

            <li id="1" class="question">
                <a name="#1"></a>
                <div class="qbox"><span  class="q">Q.</span>あなたは○○ですか?</div>
                <div class="qabox">
                    <a href="#2" onclick="show(2)" class="qabtn"><div class="btnBox btnBox_y">はい</div></a>
                    <a href="#3" onclick="show(3)" class="qabtn"><div class="btnBox btnBox_n">いいえ</div></a>
                </div>
            </li>
            <li id="2" class="question" style="display:none;">
                <a name="#"></a>
                <div class="qbox"><span  class="q">Q.</span>あなたは○○ですか?</div>
                <div class="qabox">
                    <a href="#101" onclick="show(101)" class="qabtn"><div class="btnBox btnBox_y">はい</div></a>
                    <a href="#102" onclick="show(102)" class="qabtn"><div class="btnBox btnBox_n">いいえ</div></a>
                </div>
            </li>
            <li id="3" class="question" style="display:none;">
                <a name="#"></a>
                <div class="qbox"><span  class="q">Q.</span>あなたは○○ですか?</div>
                <div class="qabox">
                    <a href="#103" onclick="show(103)" class="qabtn"><div class="btnBox btnBox_y">はい</div></a>
                    <a href="#104" onclick="show(104)" class="qabtn"><div class="btnBox btnBox_n">いいえ</div></a>
                </div>
            </li>


            </ul>

            <div class="answerList">

                <div id="101" style="display:none;" class="answer point_box">
                    <div class="box">
                        <div class="title">
                        <p>あなたは<span class="fs-18"><span class="bg-y">『○○タイプ』</span></span>です!</p>
                        </div>
                    <div class="txt">
                        <div class="img"><img src="https://placehold.jp/450x300.png"></div>
                        <p>ヴァイオリンはろのおねがい晩屋にひとにぶっつけ野ねずみましない。</p>
<p>ではどんどん愉快ましましというつぶたまし。くたくたたた方ますはましそれから嵐のばかげの所がはいつも上手ましたて、これなど赤をなっれことないだ。むしっすぎこれはねずみをうるさいたてはじめのボーのねこ会で曲げ第一火花めのおねがいに弾きからいうた。</p>
                        <p><a href="#" class="square_btn">もっと詳しくみる</a></p>
                    </div>
                    </div>
                </div>
                <div id="102" style="display:none;" class="answer point_box">
                    <div class="box">
                        <div class="title">
                        <p>あなたは<span class="fs-18"><span class="bg-y">『□□タイプ』</span></span>です!</p>
                        </div>
                    <div class="txt">
                        <div class="img"><img src="https://placehold.jp/450x300.png"></div>
                        <p>ヴァイオリンはろのおねがい晩屋にひとにぶっつけ野ねずみましない。</p>
<p>ではどんどん愉快ましましというつぶたまし。くたくたたた方ますはましそれから嵐のばかげの所がはいつも上手ましたて、これなど赤をなっれことないだ。むしっすぎこれはねずみをうるさいたてはじめのボーのねこ会で曲げ第一火花めのおねがいに弾きからいうた。</p>
                        <p><a href="#" class="square_btn">もっと詳しくみる</a></p>
                    </div>
                    </div>
                </div>
                <div id="103" style="display:none;" class="answer point_box">
                    <div class="box">
                        <div class="title">
                        <p>あなたは<span class="fs-18"><span class="bg-y">『△△タイプ』</span></span>です!</p>
                        </div>
                    <div class="txt">
                        <div class="img"><img src="https://placehold.jp/450x300.png"></div>
                        <p>ヴァイオリンはろのおねがい晩屋にひとにぶっつけ野ねずみましない。</p>
<p>ではどんどん愉快ましましというつぶたまし。くたくたたた方ますはましそれから嵐のばかげの所がはいつも上手ましたて、これなど赤をなっれことないだ。むしっすぎこれはねずみをうるさいたてはじめのボーのねこ会で曲げ第一火花めのおねがいに弾きからいうた。</p>
                        <p><a href="#" class="square_btn">もっと詳しくみる</a></p>
                    </div>
                    </div>
                </div>
                <div id="104" style="display:none;" class="answer point_box">
                    <div class="box">
                        <div class="title">
                        <p>あなたは<span class="fs-18"><span class="bg-y">『▲▲タイプ』</span></span>です!</p>
                        </div>
                    <div class="txt">
                        <div class="img"><img src="https://placehold.jp/450x300.png"></div>
                        <p>ヴァイオリンはろのおねがい晩屋にひとにぶっつけ野ねずみましない。</p>
<p>ではどんどん愉快ましましというつぶたまし。くたくたたた方ますはましそれから嵐のばかげの所がはいつも上手ましたて、これなど赤をなっれことないだ。むしっすぎこれはねずみをうるさいたてはじめのボーのねこ会で曲げ第一火花めのおねがいに弾きからいうた。</p>
                    </div>
                    </div>
                </div>
            </div>


        </article>
    </main>
</div>


<script src="https://ajax.googleapis.com/ajax/libs/jquery/1.9.1/jquery.min.js" type="text/javascript"></script>

<script type="text/javascript">
$(function(){
   $('a[href^=#]').click(function() {
      var speed = 600;
      var href= $(this).attr("href");
      var target = $(href == "#" || href == "" ? 'html' : href);
      var position = target.offset().top;
      $('body,html').animate({scrollTop:position}, speed, 'swing');
      return false;
   });
});
$(function(){
    h = $(window).height();
    h = h-30;
    $(".question").css("min-height", h + "px");
    $(".answerList .box").css("min-height", h + "px");
    
});
function show(idName){ 
    $("#" + idName).show();
}

</script>


</body>
</html>

              
            
!

CSS

              
                @charset "utf-8";

/* reset style
------------------------------------------ */
html,body,div,span,object,iframe,h1,h2,h3,h4,h5,h6,p,blockquote,pre,abbr,address,cite,code,del,dfn,em,img,ins,kbd,q,samp,small,strong,sub,sup,var,b,i,dl,dt,dd,ol,ul,li,fieldset,form,label,legend,table,caption,tbody,tfoot,thead,tr,th,td,article,aside,canvas,details,figcaption,figure,footer,header,hgroup,menu,nav,section,summary,time,mark,audio,video{margin:0;padding:0;border:0;outline:0;font-size:100%;vertical-align:top}
article,aside,figure,footer,header,nav,section,details,summary{display:block}
html{overflow-y:scroll;-webkit-tap-highlight-color: rgba(0,0,0,0);}
/* a{color:#444444;margin:0;padding:0;text-decoration:none} */
ul{list-style:none}
table{border-collapse:collapse;border-spacing:0}
th{font-weight:700;vertical-align:top;word-break:break-all;word-wrap:break-word}
td{font-weight:400;vertical-align:top;word-break:break-all;word-wrap:break-word}

body {
    font-family: "メイリオ", Meiryo,"ヒラギノ角ゴ Pro W3", "Hiragino Kaku Gothic Pro", sans-serif;
    font-size: 14px;
    line-height: 1;
    color: #535353;
}

.wf-mplus1p { font-family: "Mplus 1p"; }


#commonHeader {
    position: relative;
    margin: 0 auto;
    max-height: 210px;
    z-index: 100000;
    
    color: #5391BA;
    font-weight: bold;
    text-align: center;
    padding: 0.25em;
    border-top: solid 2px #6cb4e4;
    border-bottom: solid 2px #6cb4e4;
    background: -webkit-repeating-linear-gradient(-45deg, #f0f8ff, #f0f8ff 3px,#e9f4ff 3px, #e9f4ff 7px);
    background: repeating-linear-gradient(-45deg, #f0f8ff, #f0f8ff 3px,#e9f4ff 3px, #e9f4ff 7px);

}
#commonHeader section#flows {
    margin: 0 auto;
    max-height: 170px;
    position: relative;
    
    font-size: 360%;
    text-align: center;
    padding:5px 5px 30px;

}

#flowsHead{
    font-size: 100%;
    text-align: center;
    padding-top: 30px;
    padding:30px 5px 5px;

}

#commonHeader section#flows a.homeLink {
    width: 555px;
    height: 58px;
    position: absolute;
    left: 200px;
    top: 77px;
    text-indent: 100%;
    overflow: hidden;
    white-space: nowrap;
}
article:after, section:after, .clrFx:after {
    content: '';
    clear: both;
    display: block;
}
main {
    padding: 0 0 35px 0;
    /* margin: 0 auto; */
    max-width: 980px;
    margin: 0 auto;
}
#pageBody {
}

.hsd_question {
    position: relative;
    overflow: hidden;
    margin-bottom: 65px;
    margin-top: 50px;
}
.hsd_question ul {
    position: relative;
    left: 50%;
    float: left;
}
.hsd_question li {
    position: relative;
    left: -50%;
    float: left;
}
#pageBody p {
    margin-bottom: 1em;
}
.hsd_question_txt {
    padding: 8px 10px 0px 12px;
    font-size: 25px;
    color: #282828;
    text-align: center;
    font-family: "游明朝", "YuMincho", "ヒラギノ明朝 Pro W3", "Hiragino Mincho Pro", serif;
}
.hds_answer {
    position: relative;
    overflow: hidden;
    margin-bottom: 85px;
}
.hds_answer ul {
    position: relative;
    left: 50%;
    float: left;
}
.hds_answer li {
    position: relative;
    left: -50%;
    float: left;
}
.img-yes {
    font-size: 10px;
}

#wrapper {
    position: relative;
    clear: both;
}
.margin {
    background-color: #fff;
    width: 50px;
    height: 151px;
}
.qalist{
    min-width:320px;
    max-width:800px;
    margin:0 auto;
}
.qalist li {
    font-size:130%;
    font-weight: bold;
    padding-top: 30px;
}

.qbox{
    text-align:center;
}
.qabox{
    width:300px;
    margin: 0 auto;
}

.question {
	font-size:15px;
	line-height:1.5em;
	padding:10px;
}
.question:after{
    clear:both;
}
.answer {
	font-size:15px;
	line-height:1.5em;
	color:#000000;
	padding:10px;
}
.sig{
	text-align:right;
	font-size:xx-small;
}


.qabtn {
    position: relative;

}
.qabtn::before,
.qabtn::after {
	position: absolute;
	z-index: -1;
	display: block;
	content: '';
}
.qabtn,
.qabtn::before,
.qabtn::after {
	-webkit-box-sizing: border-box;
	-moz-box-sizing: border-box;
	box-sizing: border-box;
	-webkit-transition: all .3s;
	transition: all .3s;
}

.qabtn {

}
.qabtn:active {
	top: 3px;
	box-shadow: none;
}
.qabtny{
    margin-right:30px;
}

.btnBox{
    text-align:center;
    width: 90px;
    float: left;
    height: 90px;
    padding: 20px;
    border-radius: 90px;
    cursor :pointer;
    
    color: #fff;
    font-size:150%;
    line-height: 90px;
    
    margin-top:30px;
}

.btnBox_y{
    background-color: #FF8DB4;
    margin-right: 40px;
}

.btnBox_n{
    background-color: #62D7DE;
}

.q{
    font-family: "Mplus 1p";
    font-size:300%;
    height: 50px;
    color:#F55257;
}
.qtxt{
}

.point_box {
    background: -webkit-repeating-linear-gradient(-45deg, #cce7ff, #cce7ff 3px,#e9f4ff 3px, #e9f4ff 7px);
    background: repeating-linear-gradient(-45deg, #cce7ff, #cce7ff 3px,#e9f4ff 3px, #e9f4ff 7px);
    padding: 4px;
    margin: 10px 5px 10px;
    font-size:110%;
}

.point_box .box {
    padding: 5px 5px 1px;
    background-color: #fff;
}

.point_box .title {
    font-weight: bold;
    font-size: 115%;
    position: relative;
    line-height: 1.2;
}
.point_box .title{
    position: relative;
    border-top: solid 2px #80c8d1;
    border-bottom: solid 2px #80c8d1;
    background: #f4f4f4;
    line-height: 1.4;
    padding: 0.4em 0.5em;
    margin: 1em 0 0.5em;
    text-align: left;
}

.point_box .title:after {/*タブ*/
    position: absolute;
    font-family: FontAwesome,'Quicksand','Avenir','Arial',sans-serif;
    content: '\f0a7\ Result';
    background: #80c8d1;
    color: #fff;
    left: 0px;
    bottom: 100%;
    border-radius: 5px 5px 0 0;
    padding: 5px 7px 3px;
    font-size: 0.7em;
    line-height: 1;
    letter-spacing: 0.05em;
}

.point_box .box .txt {
    padding: 10px 10px 0px;
    line-height: 1.45;
    text-align: left;
}
.bg-y {
    background: #FFFF73;
}
.fs-18 {
    font-size: 120%;
    font-weight: bold;
    line-height: 140%;
}
.redtext, .red {
    color: #D03F37;
}
.img {
    margin: 0 auto 10px;
    max-width: 500px;
}
.img img {
    max-width: 100%;
}

#pageBody .title p{
    margin:3px 0 1px;
}

.square_btn{
    display: inline-block;
    padding: 0.5em 1em;
    text-decoration: none;
    background: #f7f7f7;
    border-left: solid 6px #ff7c5c;/*左線*/
    color: #ff7c5c;/*文字色*/
    font-weight: bold;
    box-shadow: 0px 2px 2px rgba(0, 0, 0, 0.29);
}
.square_btn:active,
.square_btn:hover {
    box-shadow: inset 0 0 2px rgba(128, 128, 128, 0.1);
    transform: translateY(2px);
}
              
            
!

JS

              
                $(function(){
   $('a[href^=#]').click(function() {
      var speed = 600;
      var href= $(this).attr("href");
      var target = $(href == "#" || href == "" ? 'html' : href);
      var position = target.offset().top;
      $('body,html').animate({scrollTop:position}, speed, 'swing');
      return false;
   });
});
$(function(){
    h = $(window).height();
    h = h-30;
    $(".question").css("min-height", h + "px");
    $(".answerList .box").css("min-height", h + "px");
    
});
function show(idName){ 
    $("#" + idName).show();
}
              
            
!
999px

Console