<link href="https://maxcdn.bootstrapcdn.com/font-awesome/4.7.0/css/font-awesome.min.css" rel="stylesheet">
<style type="text/css">

@charset "UTF-8";

@font-face {
    font-display: swap;
}

@import url('https://fonts.googleapis.com/css?family=Noto+Serif+JP&display=swap');

body {
    font-family: 'Noto Serif JP', serif;
    font-weight: normal;
    letter-spacing: 2px;
    max-width: 100%;
    text-align: justify;
    word-break: break-all;
    margin:0;
color: #000;
}
@media screen and (min-width:1024px) {
body {
font-size: 15px;
}
}
@media screen and (max-width:750px) {
body {
font-size: 13px;
}
}


* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}


.box a {
}
@media screen and (max-width:750px) {
.box a{
line-height: 200%;
}
}


a {
 text-decoration:none;
color: #bbbbbb;
}
a:hover {
font-weight: bold;
}
.box a:visited {
 color: #000;
}






/* ヘッダー */

@media screen and (min-width:1024px) {
header {
z-index: 100;
font-size: 18px;
margin: 0 2.5em;
text-align: right;
display: block;
}
header1 {
z-index: 100;
font-size: 16px;
margin: 0 3.5em;
text-align: right;
display: block;
}
header2 {
font-size: 18px;
font-weight: bold;
}
header3 {
margin: 0 1.5em;
}
header4 {
margin: 0 5em;
    font-size: 14px;
}
}



@media screen and (max-width:750px) {
header {
font-size: 16px;
margin: 0 0;
text-align: right;
display: block;
}
header1 {
font-size: 14px;
margin: 0 0;
text-align: right;
display: block;
}
header2 {
font-size: 16px;
font-weight: bold;
}
header3 {
font-size: 12px;
margin: 0 0;
}
header4 {
font-size: 11px;
margin: 0 3.5em;
}
}





@media screen and (min-width:1024px) {
img.syudo {
    transform: rotate( 331deg );
    z-index: 0;
    position: absolute;
    height: 23%;
    width: auto;
    top: 0;
    right: 0;
    bottom: 0;
    left: auto;
}
}

@media screen and (max-width:750px) {
img.syudo {
z-index: 10;
    position: absolute;
    width: 20%;
top: 0;
    right: 0;
    bottom: 0;
    left: auto;
}
}






/* 文章の背景　完全透過 */
h4 {
    font-weight: normal;
    letter-spacing: 2px;
    max-width: 100%;
    text-align: justify;
    word-break: break-all;
background-color: #fff;
}


@media screen and (min-width:1024px) {
h4 {
font-size: 16px;
padding: 2em;
margin: 3em auto 2em auto;
width: 70%;
line-height: 180%;
}
}


@media screen and (max-width:750px) {
h4 {
font-size: 13px;
margin: 5em auto 0 auto;
width: 90%;
line-height: 200%;
}
}


/* 下部テキスト　題名　戻るボタン  */
.left a {
}

@media screen and (min-width:1024px) {
.left {
margin: 1em auto;
}
}
@media screen and (max-width:750px) {
.left {
margin: 2em auto;
}
}



@media screen and (min-width:1024px) {
section {
    position: relative;
    z-index: 100;
    margin: 0 5em;
    width: 100%;
    height: 100%;
}
}

@media screen and (max-width:750px) {
section {
    position: relative;
    z-index: 100;
    margin: 0 0 0 1em;
    width: 50%;
    height: 100%;
}
}


/* メインページボックス */
.box{
    z-index: 0;
text-align:left;
max-width: 100%;
position: absolute;
left: 0;
right: 0;
margin: auto;
}
@media screen and (min-width:1024px) {
.box {
margin: 2em auto;
    width: 100%;
    padding: 1em 3em;
  }
.wrapper {
text-orientation: upright;
-ms-writing-mode: tb-rl;
writing-mode: vertical-rl;
margin: 1em auto;
  }
.wrapper2 {
display: none;
}
}



@media screen and (max-width:750px) {
.box {
margin: 2em auto;
width: 90%;
}
.wrapper {
display: none;
}
.wrapper2 {
text-orientation: upright;
-ms-writing-mode: tb-rl;
writing-mode: vertical-rl;
margin: 2em auto 5em auto;
width: 100%;
align-content: space-around;
}
}






</style>

<script src="https://ajax.googleapis.com/ajax/libs/jquery/1.11.1/jquery.min.js"></script>
<script>

$(function() {
var _window = $(window),
    _header = $('.st'),
    heroBottom;
_window.on('scroll',function(){     
    heroBottom = $('.back').height();
    if(_window.scrollTop() > heroBottom){
        _header.addClass('fixed');   
    }
    else{
        _header.removeClass('fixed');   
    }
});
_window.trigger('scroll');

   $('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;
   });

});



</script>
