@charset"utf-8";
/* 全般スタイル */
body {
    font-family: Arial, sans-serif;
    margin: auto;
    max-width: 800px;
    min-height: 100vh;
    display: flex;
    flex-direction: column;
    background-image: url(http://masumo10.web.fc2.coexm/tile-g.gif);   
    background-repeat: repeat-x;
     background-position: right;
     background-attachment: scroll;/*背景画固定はfixed*/
     background-color: lightblue;　/*淡い青　背景色*/
}
h2 {
    font-size: 1em;
    text-align: center;
    margin: 0;
    flex-grow: 1; /* 中央に配置されるために余白を確保 */
    padding-right: 70px; /* ハンバーガーメニューのスペースを確保 */
}


.hamburger {
    display: flex;
    flex-direction: column;
    cursor: pointer;
    margin-left: 30px; /* 左側の余白を増やす */
    z-index: 1001; /* 他の要素よりも前面に表示 */
    width: 50px; /* 必要に応じて調整 */
    height: 50px; /* 必要に応じて調整 */
}

.hamburger span {
    width: 30px;
    height: 3px;
    background-color: rgb(24, 41, 141);;
    margin: 5px 0;
    transition: 0.4s;
}

/* メニューのスタイル */
.menu {
    display: none;
    flex-direction: column;
    background-color: rgba(94, 25, 25, 0.9); /* 背景色に少し透明度を追加 */
    position: fixed; /* 画面全体に固定表示 */
    top: 0;
    left: 0;
    width: 100%; /* 画面の幅全体に広げる */
    height: 100%; /* 画面の高さ全体に広げる */
    justify-content: center; /* 配置 */
    align-items: flex-start; /* 配置 */
    box-shadow: 0 8px 16px rgba(0, 0, 0, 0.5); /* 影をさらに濃くして、ぼかしを広げる */
    z-index: 1000; /* 他のコンテンツの上に表示するための優先度を設定 */

}
.flex-item {
    border: 2px solid white;
    margin-top: 7px; /* 上に余白を追加 */
    padding-top: 10px;
}
.menu ul {
    list-style: none;
    padding: 0;
    margin: 0;
    text-align: center; /* テキストを中央揃えにする */
}

.menu li {
    border-bottom: 1px solid #ddd;
    margin: 10px 0; /* リスト項目間の余白を追加 */
}

.menu a {
    display: block;
    padding: 10px;
    text-decoration: none;
    color: rgb(32, 29, 98);
    font-size: 1.5em; /* テキストサイズを大きくする */
}

.menu a:hover {
    color: #f0f0f0;
}

.menu.active {
    display: flex; /* メニューを表示する */
}

/* ハンバーガーメニューのアニメーション */
.hamburger.active span:nth-child(1) {
    transform: rotate(-45deg) translate(-12px, 6px);
    background-color: red; /* 「✖️」マークの色を変更 */
    
}

.hamburger.active span:nth-child(2) {
    opacity: 0;
}

.hamburger.active span:nth-child(3) {
    transform: rotate(45deg) translate(-12px, -6px);
    background-color: red; /* 「✖️」マークの色を変更 */
}

/* ハンバーガーアイコン全体の幅と高さを設定 */
.hamburger {
    width: 50px; /* 必要に応じて調整 */
    height: 50px; /* 必要に応じて調整 */
    display: flex;
    flex-direction: column;
    justify-content: center; /* 垂直方向に中央揃え */
    align-items: center; /* 水平方向に中央揃え */
}
