* {
  box-sizing: border-box; /* 全ての要素のボックスサイズをborder-boxに設定 */
  margin: 0; /* 全ての要素のデフォルトのマージンをリセット */
  padding: 0; /* 全ての要素のデフォルトのパディングをリセット */
}

body {
  font-family: Arial, sans-serif; /* フォントファミリーをArialとフォールバックに指定 */
  line-height: 1.6; /* 行の高さを1.6に設定 */
}

a {
  text-decoration: none; /* テキストのデコレーションを無効化 */
  color: inherit; /* 親要素の色を引き継ぐ */
}

a:visited {
  color: inherit; /* 訪問済みリンクの色を親要素に合わせる */
}

/* ヘッダー --------------------------------------------------------------------------------------- */
header {
  background:
    repeating-linear-gradient(-45deg,
      rgba(255, 255, 255, 0.1) 0px,
      rgba(255, 255, 255, 0.1) 10px,
      transparent 10px,
      transparent 20px
    ), /* 45度方向のリピートグラデーション背景 */
    linear-gradient(135deg, #0277a9, #90cce6); /* メインのグラデーション背景 */
  color: white; /* テキストの色を白に設定 */
  padding: 1rem; /* 内側の余白を1remに設定 */
  text-shadow: 2px 2px 10px rgba(0, 0, 0, 0.3); /* テキストに影を付ける */

  /* スクロールさせない */
  position: -webkit-sticky; /* Safari用 */
  position: sticky;
}

@media (min-width: 1100px){
  header a {
    width: 1000px;
    margin: 0 auto;
  }
}
.wide_screen_ad_l,
.wide_screen_ad_r {
  display: none;
}
@media (min-width: 1300px){
  .wide_screen_ad_l,
  .wide_screen_ad_r {
    display: block;
    top:200px;
    width: 120px;
    height: 600px;
    overflow: hidden;
    position: fixed;
  }
  .wide_screen_ad_l { left: 15px; }
  .wide_screen_ad_r { right: 15px; }
}

/* タイトルを１行表示にする */
#resizable-text {
  white-space: nowrap; /* 強制的に一行にする */
  overflow: hidden; /* オーバーフローを非表示にする */
}

#titleContainer {
  display: flex;
  align-items: center;
  justify-content: space-between; /* スペースを均等化 */
}

.footer {
  text-align: center;
  font-size: 0.9em;
  color: #666;
  margin-bottom: 10px;
  padding: 20px 0;
}

.footer div a {
  margin: 0 10px;
  color: #666;
  text-decoration: none;
}

.footer div a:hover {
  text-decoration: underline;
}

.footer hr {
  width: 90%;
  margin: 0 auto;
  margin-bottom: 10px;
}

canvas {
  width: 100%;
  height: auto;
  display: block;
  max-width: 800px;
}


/* コンテナのレイアウト：フレックスボックスで左右分割 */
/* .container { */
  /*display: flex; /* 子要素をフレックスコンテナとして並べる */
  /*min-height: calc(100vh - 70px); /* ウィンドウの高さからヘッダー約70pxを引いた高さを最小高さに設定 */
/* } */


/* メニューエリア --------------------------------------------------------------------------------------- */

*, *::before, *::after {
  box-sizing: border-box;
}

a {
  text-decoration: none;
}

.menuButton div:nth-of-type(1) {
  visibility: hidden;
}
.menuButton div:nth-of-type(2) {
  visibility: hidden;
}
.menuButton div:nth-of-type(3) {
  visibility: hidden;
}
.menuButton div:nth-of-type(4) {
  visibility: hidden;
}
.menuButton div:nth-of-type(5) {
  visibility: hidden;
}

.menuButton {
  z-index: 1001;
  display: none;
}

nav {
  z-index: 1000;
}

nav.WideSize{
  text-align: center;
}
nav.WideSize ul {
  margin: 0px;
  /* padding: 0px 0px 0px 15px; */
  background-color: #18186a;
}
nav.WideSize ul li {
  width: 135px;
  display: inline-block;
  list-style-type: none;
  position: relative;
  z-index: 1000;
}
nav.WideSize ul a {
  background-color: #18186a;
  color: white;
  line-height: 40px;
  text-align: center;
  text-decoration: none;
  font-weight: bold;
  display: block;
}
nav.WideSize ul a:hover {
  background-color: #d6d8ff;
  color: #18186a;
}
nav.WideSize ul li:hover > ul {
  display: block;
}
nav.WideSize ul ul {
  margin: 0px;
  padding: 0px;
  display: none;
  position: absolute;
}
nav.WideSize ul ul li {
  width: 135px;
  border-top: 1px solid white;
  z-index: 1000;
}
nav.WideSize ul ul li a {
  line-height: 45px;
  text-align: center;
  padding-left: 5px;
  font-weight: normal;
}
nav.WideSize ul ul li a:hover {
  background-color: #d6d8ff;
  color: #18186a;
}
nav.WideSize ul ul ul {
  margin: 0px;
  padding: 0px;
  display: none;
  position: absolute;
  top: 5px;
  left: 100%;
  border-left: 1px solid white;
}
nav.WideSize ul ul ul li {
  width: 230px;
  border-top: 1px solid white;
  z-index: 1000;
}
/* nav.WideSize ul ul ul li a {
  line-height: 35px;
} */

ul {
  list-style: none;
}

@media (max-width: 835px) {

  .menuButton {
    display: block;
    height: 80px;
    width: 80px;
    background: white;
    position: fixed; /*画面上での位置固定*//**/
    top: 0px;
    right: 0px;
    transition: .3s;
    opacity: .8;
  }

  .menuButton div {
      height: 1px;
      width: 60%;
      background: #333;
      position: absolute;
      top: 50%;
      left: 50%;
      transform: translate(-50%, -50%);
      transition: .3s;
  }

  /*.menuButton.active {
      transform: rotate(90deg);/*要素を回転させる
  }*/

  .menuButton div:nth-of-type(1) {
      width: 40%;
      background: transparent;
      transform: translate(-40%, 25px);
      font-size: 10px;
      visibility: visible;
  }

  .menuButton div:nth-of-type(2) {
      width: 60%;
      height: 15px;
      background: white;
      transform: translate(-50%, 25px);
      font-size: 10px;
      text-align: center;
      visibility: visible;
  }

  .menuButton div:nth-of-type(3) {
      transform: translate(-50%, -15px);
      visibility: visible;
  }

  .menuButton div:nth-of-type(4) {
      visibility: visible;
  }

  .menuButton div:nth-of-type(5) {
      transform: translate(-50%, 15px);
      visibility: visible;
  }

  .menuButton.active div:nth-of-type(1) {
      width: 40%;
      background: transparent;
      transform: translate(-40%, 25px);
      font-size: 10px;
  }

  .menuButton.active div:nth-of-type(2) {
      opacity: 0;
  }

  .menuButton.active div:nth-of-type(3) {
      transform: rotate(45deg) translate(-50%, 0px);
      transform-origin: 0% 50%;
  }

  .menuButton.active div:nth-of-type(4) {
      opacity: 0;
      /*transform: translate(0%, -50%);/*消える時に左右にフェードアウトさせる*//**/

      /*width: 80%;/*線ではなく図形で囲みたい場合以下のものに*//**/
      /*height: 80%;
      border: 2px solid #333;
      background-color: transparent;/*透明にする*//**/
      /*border-radius: 30%;/*50%円形にする。それ以下は角丸四角形*//**/
  }

  .menuButton.active div:nth-of-type(5) {
      transform: rotate(-45deg) translate(-50%, 0px);
      transform-origin: 0% 50%;
  }

  nav {
  opacity: 0;
  visibility: hidden;
  width: 350px;
  max-height: 700px;
  overflow-y: auto;
  transition: transform 0.4s ease, opacity 0.3s ease;
  position: fixed;
  top: 0;
  right: 0;
  background: rgba(250, 250, 250, 0.7);
  backdrop-filter: blur(10px);
  padding: 30px 20px;
  box-shadow: -2px 0 10px rgba(0, 0, 0, 0.3);
  font-family: "M PLUS Rounded 1c", "Noto Sans JP", sans-serif;
  z-index: 1000;
  border-radius: 10px;
}

nav.active {
  opacity: 1;
  visibility: visible;
  transform: translateX(0);
}

nav ul {
  list-style: none;
  padding: 0;
  margin: 0;
}

nav ul li {
  font-size: 18px;
  padding: 10px 0;
  border-bottom: 1px solid #aaa;
  color: #333;
  transition: all 0.3s ease;
  cursor: pointer;
  display: flex;
  align-items: center;
  gap: 10px;
}

nav ul li:hover {
  color: #007aff;
  transform: translateX(5px);
}

body.no-scroll {
  overflow: hidden;
}


  /* .content {
    margin-top: +40px;
  } */

}


/* 実施内容エリア --------------------------------------------------------------------------------------- */
.content {
  flex: 1; /* フレックスコンテナ内で残りのスペースを全て埋める */
  /*padding: 1rem; /* 内側の余白を1remに設定 */
  /* margin-top: -40px; */
  z-index: 1;
  width: 1000px;
  max-width: 100%;
  /* min-width: 70%; */
  margin: 0 auto;
  border-left: 1px solid #ccc;
  border-right: 1px solid #ccc;
}

/* 表の書式 */
.kizi table {
  width: 100%;
  border-collapse: collapse;
  margin-top: -20px;
  font-size: 16px;
}

.kizi th,
.kizi td {
  border: 1px solid #ccc;
  padding: 5px;
}

.kizi th {
  background-color: #f4f4f4;
  font-weight: bold;
}

.kizi tr:nth-child(even) {
  background-color: #f9f9f9;
}

.kizi tr:hover {
  background-color: #eef;
}

.sitemap table {
  width: 250px;
  margin: 10px;
  padding: 10px;
  /* border: 1px solid #ccc; */
}

.sitemap .title {
  font-size: 20px;
  font-weight: bold;
  padding: 10px;
  border-radius: 5px;
  background: linear-gradient(135deg, #61faffaa 0%, hsla(182, 100%, 79%, 0.353) 050%, #ffffff00 100%);
}

.sitemap h2 {
  margin: 10px;
}

.sitemap td {
  padding: 5px;
}

.sitemap a:hover {
  padding: 10px;
  border-radius: 5px;
  background-color: #eee;
}

/* 細かい書式 */
.top {
  padding: 1rem; /* 内側の余白を1remに設定 */
}

.right {
  text-align: right;
}

/* indexのSNSの書式 */
.SNScenter {
  display: flex;
  justify-content: center; /* 横中央 */
  align-items: center;     /* 縦中央 */
  height: 50px;
  gap: 10px;
  font-size: 20px;
  margin-bottom: 10px;
}

/* 強調表示用 */
.red18 {
  color: red;
  font-size: 18px;
  font-weight: bolder;
}
.red20 {
  color: red;
  font-size: 20px;
  font-weight: bolder;
}
.red22 {
  color: red;
  font-size: 22px;
  font-weight: bolder;
}

.index_sns {
  height: 30px;
  display: block;
}

/* 記事の書式 */
.array-methods-container {
  font-family: Arial, sans-serif;
  line-height: 1.8;
  background-color: #f9f9f9;
  padding: 20px;
  border-radius: 8px;
  margin-bottom: 30px;

  /*height: 500px; /* 必要に応じて高さを調整 */
  overflow-y: auto; /* コンテンツ部分にスクロールを許可 */
}
.array-methods-container h1,
.array-methods-container h2 {
  color: #333;
  z-index: -1;
}
.array-methods-container pre {
  background-color: #272822;
  color: #f8f8f2;
  padding: 10px;
  border-radius: 4px;
  overflow-x: auto;
  position: relative;
  margin: 0;
  z-index: -1;
}
.array-methods-container .code-container {
  position: relative;
  margin-bottom: 0px;
  z-index: 0;
}
.array-methods-container .copy-button {
  position: absolute;
  top: 5px;
  right: 5px;
  background-color: #66d9ef;
  border: none;
  color: #272822;
  padding: 5px 8px;
  border-radius: 3px;
  cursor: pointer;
  font-size: 12px;
  z-index: 0;
}
.array-methods-container .copy-button:hover {
  background-color: #a6e22e;
}
.array-methods-container section {
  background: #fff;
  margin-bottom: 20px;
  padding: 15px;
  border-radius: 5px;
  box-shadow: 0 2px 4px rgba(0,0,0,0.1);
  z-index: -1;
}

/* タイトル固定と内容スクロールの書式 */
.sticky-header {
  position: -webkit-sticky; /* Safari用 */
  position: sticky;
  top: 0; /* 上からの距離を指定 */
  background-color: #f9f9f9;
  padding: 10px;
  border-bottom: 2px solid #FFF;
  z-index: 1;
  white-space: nowrap; /* 強制的に一行にする */
  overflow-x: scroll;
  overflow-y: hidden;
  scroll-snap-type: x mandatory;  /* 横方向のスナップを有効に */
   /* スクロールバーを非表示（各ブラウザ対応） */
   scrollbar-width: none;          /* Firefox */
   -ms-overflow-style: none;       /* IE & Edge */
}

.sticky-header::-webkit-scrollbar {
  display: none; /* Chrome, Safari, Opera */
}

.sticky-header p {
  display: inline-block;
}

.sticky-header p a {
  background-color: #ddd;
  padding: 5px;
  margin-left: 10px;
  border-radius: 5px;
  scroll-snap-align: start;       /* 各リンクの先頭で止まる */
}

.scroll-content {
  /*height: 1500px; /* スクロール可能になるようにコンテンツを長くする */
  padding: 10px;
  z-index: -1;
}

.subtitle {
  margin-top: -12px;
  color: #840000;
}

.ad-container {
  display: flex;
  gap: 0px; /* 広告間のスペース */
  justify-content: center; /* 水平方向の中央寄せ */
  align-items: center;    /* 垂直方向の中央寄せ */
  flex-wrap: wrap; /* 画面幅が狭いときに折り返し */
}

button {
  margin: 5px;
  padding: 2px;
}

input {
  margin: 1px;
  padding: 5px;
}

#news {
  max-width: 800px;
  margin: 0 auto;
  padding: 20px;
}
#news h2 {
  font-size: 1.5em;
  border-bottom: 2px solid #ccc;
  padding-bottom: 5px;
}
#news-list {
  max-height: 300px;
  height:300px;
  overflow-y: auto;
  padding: 10px;
  border: 1px solid #ccc;
  list-style: none;
}
#news-list li {
  position: relative;
  display: flex;
  align-items: center;
  gap: 10px;
  margin: 30px 0;
  padding-bottom: 10px; /* ← 下に余白を確保（線と本文の間） */
}

#news-list li::after {
  content: "";
  position: absolute;
  left: 0;
  right: 0;
  height: 1px;
  background: #ddd;
  bottom: -5px; /* ← ここで5px下にずらす */
}

#news-list li:last-child::after {
  display: none;
}
#news-list span {
  margin-right: 10px;
  color: #888;
  font-size: 0.9em;
}
#news-list li img {
  display: block;
  height: 30px;
}

.privacy h1,
.privacy h2,
.privacy p {
  margin-left: 10px;
  margin-right: 10px;
}

.privacy a {
  background-color: #ddd;
  border-radius: 5px;
  padding: 2px;
}

/* 記事中の例の書式 */
.aInKizi {
  background-color: #FEE;
  padding: 5px;
  border-radius: 5px;
}
.example { display: none; }
.example.active { display: block; }
.errorMsg {
  display: none;
  color: darkred;
  background-color: #f99494;
  padding: 5px;
  border-radius: 5px;
  white-space: pre-line;
}
.errorMsg.active {
  display: inline-block;
}
.notice {
  font-size: 0.9em;
  color: #555;
  margin-top: -5px;
}

button#bgColor,
button#codeDisp {
  padding: 10px;
}

table.coloebook td {
  max-width: 500px;
}

/* 画像の拡大縮小アニメーションに関する書式 */
/* モーダル全体 */
#modal {
  display: none;
  position: fixed;
  top: 0; left: 0;
  width: 100vw;
  height: 100vh;
  background-color: rgba(0, 0, 0, 0.8);
  justify-content: center;
  align-items: center;
  z-index: 9999;
  animation: fadeIn 0.3s ease;
}

/* 拡大画像 */
#modal-img {
  max-width: 90%;
  max-height: 90%;
  border: 4px solid white;
  box-shadow: 0 0 20px rgba(0, 0, 0, 0.5);
  animation: zoomIn 0.3s ease;
}

/* フェードイン */
@keyframes fadeIn {
  from { opacity: 0; }
  to { opacity: 1; }
}

/* ズームイン */
@keyframes zoomIn {
  from { transform: scale(0.8); opacity: 0; }
  to { transform: scale(1); opacity: 1; }
}

.expandable {
  cursor: pointer;
}

/* 抽選 */
#drawButton,
#showMapButton {
  -webkit-appearance: none; /* Safari, Chrome */
  -moz-appearance: none; /* Firefox */
  appearance: none;
  padding: 10px;
  font-size: 30px;
  text-align: center;
  font-family: 'HGP創英角ﾎﾟｯﾌﾟ体', 'Comic Sans MS', cursive;
  border-radius: 5px;
  border: 1px solid #ccc;
  background-color: #f0f0f0;
}
.drawResult {
  font-family: 'HGP創英角ﾎﾟｯﾌﾟ体', 'Comic Sans MS', cursive;
  font-size: 30px;
  white-space: pre-line; /* 改行を有効にする */
}