html {
  font-size: 100%;
  /* 16px */
  scroll-behavior: smooth;
  margin: 0;
  padding: 0;
  overflow-x: hidden;
}

body {
  font-family: "Noto Sans JP", "Helvetica Neue", Arial, "Hiragino Kaku Gothic ProN", "Hiragino Sans", Meiryo, sans-serif;
  color: #4a4a4a;
  font-weight: 400;
  line-height: 1.7;
  letter-spacing: 0.05em;
  margin: 0;
  padding: 0;
  overflow-x: hidden;
  visibility: hidden; /* 最初は非表示 */
}

body.loaded {
  visibility: visible; /* 読み込み完了後に表示 */
}

/* 初期設定解除 */
a {
  text-decoration: none;
  color: inherit;
  /* 親要素と同じ色にする */
}

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

img {
  display: block;
}

/* 共通スタイル*/

a:hover {
  cursor: pointer;
}

.green {
  color: #009944;
  font-weight: 500;
}

.red {
  color: #ff0000;
}

.blue {
  color: #0071bc;
}

.inline-block {
  display: block;
}

h2 {
  font-size: clamp(20px, 2vw + 1rem, 38px);
  font-weight: 400;
  line-height: 1.2;
  letter-spacing: 0.07em;
  text-align: center;
  margin: 0;
}

.green_btn {
  background-color: #009944;
  color: #fff;
  width: 200px;
  height: 40px;
  text-align: center;
  display: flex;
  justify-content: center;
  align-items: center;
  border-radius: 25px;
  transition: 0.3s;
}

.green_btn:hover {
  background-color: #0d4627;
  color: #ffffff;
  cursor: pointer;
  transition: 0.3s;
}

/* ここから個別設定 */

.wrapper {
  max-width: 960px;
  width: 100%;
  margin: 0 auto;
  padding: 0;
  box-sizing: border-box;
}

/* ナビゲーション */
nav {
  width: 100%;
  font-size: 0.9rem;
  margin-bottom: 1rem;
}

nav ul {
  display: flex;
  justify-content: space-between;
  align-items: center;
}

nav ul li {
  gap: 5px;
  width: calc(100% / 5);
  padding: 10px 0;
  text-align: center;
  border-right: 2px solid #009944;
}

nav ul li a .nav-link {
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: 5px;
}

nav ul li a span {
  display: block;
}

nav ul li a .inline-svg {
  fill: #4a4a4a;
  width: 35px;
  height: 35px;
  cursor: pointer;
  transition: fill 0.3s ease;
}

nav ul li:first-child {
  border-left: 2px solid #009944;
}

nav ul li.extra-item {
  display: none;
}

/* ナビゲーション　ホバー */
nav ul li:hover .inline-svg {
  cursor: pointer;
  fill: #009944;
}

nav ul li:hover {
  color: #009944;
  cursor: pointer;
  transition: color 0.3s ease;
}

/* スライダー */

.slider {
  width: 100%;
  margin-bottom: 6rem;
  position: relative;
}

.slider .single-item {
  width: 100%;
}

.slider .single-item img {
  width: 100%;
  height: auto;
  object-fit: cover;
}

/* Slickスライダーの強制制御 */
.slider .slick-list {
  width: 100% !important;
  max-width: 100% !important;
}

.slider .slick-track {
  width: 100% !important;
  display: flex !important;
  max-width: 100% !important;
}

.slider .slick-slide {
  width: 100% !important;
  flex-shrink: 0 !important;
  max-width: 100% !important;
}

.slider .slick-slide img {
  width: 100% !important;
  height: auto !important;
  max-width: 100% !important;
  object-fit: cover !important;
}

/* スライダー全体の幅制御 */
.slider * {
  max-width: 100% !important;
  box-sizing: border-box !important;
}

/* 全体的な幅制御 */
* {
  box-sizing: border-box;
}

/* 画面幅を超える要素を防ぐ */
img,
video,
iframe,
object,
embed {
  max-width: 100%;
  height: auto;
}

/* スライダー　ドット */
.slick-dots li button:before {
  color: #333;
  /* 通常のドット */
  opacity: 0.5;
  font-size: 70px;
}

.slick-dots li.slick-active button:before {
  color: #009944;
  /* アクティブなドット */
  opacity: 1;
}

/* スライダー　矢印 */
.slick-prev,
.slick-next {
  width: 50px !important;
  height: 50px !important;
  background: black !important;
  border-radius: 50% !important;
  z-index: 10;
}

.slick-prev:hover,
.slick-next:hover {
  background: #009944 !important;
}

.slick-prev:before,
.slick-next:before {
  font-family: Arial, sans-serif;
  font-size: 20px;
  color: white;
  line-height: 50px;
}

.slick-prev:before {
  content: "<";
}

.slick-next:before {
  content: ">";
}

/* 入館をご検討中の方へ */
.consider {
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  height: 300px;
  padding-left: 30%;
  gap: 35px;
  border: 1px solid #009944;
  position: relative;
  background-image: url(../images/line.png);
  background-size: cover;
  background-position: center;
  background-repeat: repeat;
  background-size: 8%;
  margin-bottom: 2rem;
}

.consider img:first-child {
  position: absolute;
  bottom: -40px;
  left: 3%;
  width: 30vw;
  max-width: 300px;
}

.consider p {
  margin: 0;
}

.consider img {
  width: 75%;
  height: auto;
}

/* 各教室の詳細 */
.classroom {
  width: 100%;
  height: 100%;
  position: relative;
  z-index: 10;
  padding: 50px 0;
  margin-bottom: 2rem;
}

.classroom h2 {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 15px;
  margin-bottom: 50px;
}

.classroom h2 img {
  width: 50px;
}

.classroom__content {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 10px;
  text-align: center;
  font-weight: 500;
  letter-spacing: 0.05em;
}

.classroom__content div {
  background-color: #fff;
  padding: 5px;
  text-align: center;
  font-weight: 500;
  border-radius: 10px;
  transition: 0.3s;
}

.classroom__content div:hover {
  background-color: #009944;
  color: #fff;
  cursor: pointer;
  transition: 0.3s;
}

.classroom::before {
  content: "";
  position: absolute;
  top: 0;
  left: 50%;
  transform: translateX(-50%);
  width: 100vw;
  height: 100%;
  background-color: #d9f0e3;
  z-index: -1;
}

/* 学習サポート */
.support {
  max-width: 960px;
  height: 640px;
  margin: 0 auto;
  background-image: url(../images/support.png);
  background-size: cover;
  background-position: center;
  background-repeat: no-repeat;
  padding: 30px 30px;
  position: relative;
  margin-bottom: 4rem;
}

.support__content {
  background-color: #ffffff83;
  padding: 25px;
  text-align: center;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: 20px;
  position: absolute;
  top: 3%;
  right: 3%;
}

/* 学力UPのメカニズム */
.mechanism_title {
  display: flex;
  justify-content: center;
  margin-bottom: 2rem;
}

.mechanism_content {
  padding: 30px;
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  gap: 30px;
  position: relative;
}

.mechanism_content > :nth-child(3),
.mechanism_content > :nth-child(10) {
  grid-column: 1 / span 2;
}

.mechanism_content > :nth-child(1) .text {
  display: flex;
  align-items: flex-start;
}

.mechanism_content > :nth-child(1) .text p {
  flex: 1;
}

.mechanism_content > :nth-child(1) .text img,
.mechanism_content > :nth-child(3) .text img,
.mechanism_content > :nth-child(3) .text a img,
.mechanism_content > :nth-child(9) .text img {
  width: 200px;
  height: auto;
  flex-shrink: 0;
  align-self: flex-start;
  object-fit: contain;
}

.mechanism_content > :nth-child(3) img {
  cursor: pointer;
  opacity: 1;
}

.mechanism_content > :nth-child(3) img:hover {
  opacity: 0.7;
}

.mechanism_content .inner {
  background-color: #fff;
  border: 1px solid #009944;
  padding: 10px 30px;
  box-shadow: 0 0 8px rgba(1, 63, 28, 0.3);
  position: relative;
}

.mechanism_content h3 {
  font-size: clamp(20px, 1rem + 0.5vw, 24px);
  font-weight: 500;
  margin: 0 0 0 30px;
  display: flex;
  flex-wrap: wrap;
  align-items: center;
}

.mechanism_content h3 .redbox {
  font-size: 1rem;
  font-weight: 400;
  margin-left: 20px;
  padding: 0px 10px;
  background-color: #ff0000;
  color: #fff;
  border-radius: 5px;
}

.mechanism_content .inner .text {
  display: flex;
  gap: 10px;
  margin: 15px 0 0 0;
}

.mechanism_content .inner > :nth-child(1) .text p {
  width: 50%;
}

.mechanism_content > :nth-child(1) .text img,
.mechanism_content > :nth-child(9) .text img {
  width: 200px;
  height: auto;
  flex-shrink: 0;
}

.mechanism_content > :nth-child(3) .text img {
  cursor: pointer;
  opacity: 1;
}

.mechanism_content > :nth-child(3) img:hover {
  opacity: 0.7;
}

.mechanism_content .inner .text p {
  margin: 0;
}

.mechanism_content::before {
  content: "";
  position: absolute;
  top: 0;
  left: 50%;
  transform: translateX(-50%);
  width: 100vw;
  height: 100%;
  background-color: #f9fade;
  z-index: -1;
}

.mechanism .inner .point {
  width: 70px;
  height: 70px;
  background-color: #009944;
  color: #fff;
  border-radius: 50%;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: 10px;
  position: absolute;
  top: -15px;
  left: -20px;
  line-height: 0.7;
}

.mechanism .inner .point .number {
  font-size: 1.5rem;
  font-weight: 400;
}

.top_btn {
  height: 100px;
  display: flex;
  justify-content: center;
  align-items: center;
  margin-bottom: 2rem;
}

/*--------------------------------
// レスポンシブル
----------------------------------*/

@media screen and (max-width: 960px) {
  .wrapper {
    max-width: 95%;
    padding: 0;
    box-sizing: border-box;
  }

  /* バーガーメニュー */
  nav {
    flex-direction: column;
    position: absolute;
    top: 0px;
    right: 0;
    z-index: 100;
  }

  nav ul.menu.open {
    background-color: rgba(255, 255, 255, 0.9); /* 半透明の黒背景例 */
    height: 100vh;
  }

  nav ul {
    /*最初はナビゲーションボタンは非表示*/
    display: none;
    flex-direction: column;
    list-style: none;
    padding-top: 3rem;
  }

  nav ul li {
    width: 100%;
    border-right: none;
    border-bottom: 2px solid #009944;
  }

  nav ul li .nav-link {
    display: flex;
    padding-left: 3rem;
    gap: 15px;
  }

  nav ul li:first-child {
    border-left: none;
  }

  nav ul li:last-child {
    border-bottom: none;
  }

  nav ul li:hover span {
    color: #009944;
    transition: color 0.3s ease;
  }
  nav ul li.extra-item {
    display: list-item;
  }

  nav li a {
    padding: 8px;
    font-size: 16px;
    color: #464646;
    display: block;
    text-align: center;
    text-decoration: none;
  }

  nav .hamburger {
    position: absolute;
    top: 32px;
    right: 1rem;
    cursor: pointer;
    width: 40px;
    height: 40px;
    z-index: 10;
  }

  nav .hamburger span {
    /*3本の線を作る*/
    transition: all 0.3s;
    position: absolute;
    height: 4px;
    background-color: #009944;
    width: 100%;
    z-index: 10;
  }
  nav .hamburger span:nth-of-type(1) {
    /*上の線の位置*/
    top: 2px;
  }
  nav .hamburger span:nth-of-type(2) {
    /*真ん中の線の位置*/
    top: 12px;
  }
  nav .hamburger span:nth-of-type(3) {
    /*下の線の位置*/
    top: 22px;
  }
  nav .hamburger.open span:nth-of-type(1) {
    /*openのとき、上の線を右斜めにする*/
    top: 10px;
    transform: translateY(6px) rotate(-33deg);
  }
  nav .hamburger.open span:nth-of-type(2) {
    /*真ん中の線を消す*/
    opacity: 0;
  }
  nav .hamburger.open span:nth-of-type(3) {
    /*下の線を左斜めにする*/
    top: 22px;
    transform: translateY(-6px) rotate(33deg);
  }

  /* 各教室の詳細 */

  .classroom__content {
    grid-template-columns: repeat(2, 1fr);
  }

  /* メカニズム */
  .mechanism_content {
    padding: 10px;
    grid-template-columns: 1fr;
  }

  .mechanism_content .inner {
    padding: 15px;
  }

  .mechanism_content h3 {
    padding-left: 10px;
  }

  .mechanism_content > :nth-child(3),
  .mechanism_content > :nth-child(10) {
    grid-column: 1;
  }

  /* スライダーのレスポンシブ設定 */
  .slider {
    width: 100%;
    overflow: hidden;
  }

  .slider .single-item img {
    width: 100%;
    height: auto;
  }

  /* Slickスライダーのレスポンシブ強制制御 */
  .slider .slick-list {
    width: 100% !important;
    overflow: hidden !important;
  }

  .slider .slick-track {
    width: 100% !important;
  }

  .slider .slick-slide {
    width: 100% !important;
  }

  .slider .slick-slide img {
    width: 100% !important;
    height: auto !important;
    max-width: 100% !important;
  }
}

@media screen and (max-width: 600px) {
  .wrapper {
    width: 100%;
    padding: 0 1rem;
    margin: 0;
    max-width: 100%;
  }

  /* Slickスライダーのレスポンシブ強制制御 */

  .slider {
    width: 100%;
    margin-bottom: 2rem;
    overflow: hidden;
  }

  .slider .single-item img {
    width: 100%;
    height: auto;
    max-width: 100%;
  }

  .slider .slick-list {
    width: 100% !important;
    overflow: hidden !important;
  }

  .slider .slick-track {
    width: 100% !important;
  }

  .slider .slick-slide {
    width: 100% !important;
  }

  .slider .slick-slide img {
    width: 100% !important;
    height: auto !important;
    max-width: 100% !important;
  }

  /* スライダー　矢印 */
  .slick-prev,
  .slick-next {
    display: none !important;
  }

  /* スライダー　ドット */
  .slick-dots li {
    margin: 0 0%;
    /* ドットの間隔を調整 */
  }

  .slick-dots li button:before {
    color: #333;
    /* 通常のドット */
    opacity: 0.5;
    font-size: 25px;
  }

  /* 入館をご検討中の方へ  */
  .consider {
    padding-top: 2rem;
    flex-direction: column;
    justify-content: flex-start;
    height: 420px;
    padding-left: 0%;
    gap: 20px;
    margin-bottom: 2rem;
  }

  .consider h2 {
    /* font-size: 2rem; */
  }

  .consider img:first-child {
    position: absolute;
    left: 50%;
    transform: translateX(-50%);
    top: 50%;
    width: 50vw;
  }

  /* 各教室の詳細 */
  .classroom {
    margin-bottom: 2rem;
  }

  .classroom h2 {
    /* font-size: 1.8rem; */
    gap: 10px;
    margin-bottom: 1.5rem;
  }

  .classroom h2 img {
    width: 35px;
  }

  .classroom__content {
    padding: 0 1rem;
    display: grid;
    grid-template-columns: repeat(1, 1fr);
    gap: 10px;
    text-align: center;
    font-weight: 500;
    letter-spacing: 0.05em;
  }

  /* 学習サポート */
  .support {
    margin: 0 auto;
    padding: 30px 30px;
    position: relative;
    margin-bottom: 2rem;
  }

  .support__content {
    background-color: #ffffff83;
    padding: 25px;
    text-align: center;
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    gap: 5px;
    position: absolute;
    left: 50%;
    bottom: 1rem;
    top: auto;
    right: auto;
    transform: translateX(-50%);
    width: 80%;
  }

  /* 学力UPのメカニズム */
  .mechanism_title img {
    width: 95%;
  }

  .mechanism_content .inner .text {
    display: block;
    gap: 10px;
    margin: 15px 0 0 0;
  }

  .mechanism_content .inner .text img {
    min-width: 100%;
    margin: 1rem auto;
  }

  /* Point 1, 3, 9の画像のみ対象（レスポンシブ） */
  .mechanism_content .inner:nth-child(1) .text img {
    width: 100%;
    height: auto;
    margin: 1rem auto;
  }

  .mechanism_content .inner:nth-child(3) .text img,
  .mechanism_content .inner:nth-child(3) .text a img {
    max-width: 150px !important;
    min-width: 150px !important;
    height: auto !important;
    margin: 1rem auto;
  }

  .mechanism_content .inner:nth-child(9) .text img {
    min-width: 50%;
    height: auto;
    margin: 1rem auto;
  }

  .mechanism_content h3 {
    display: block;
  }

  .mechanism_content h3 .redbox {
    margin-left: 0;
    padding: 0px 5px;
    background-color: #ff0000;
    color: #fff;
    border-radius: 5px;
    width: fit-content;
    max-width: 100%;
    min-width: 0;
  }

  /* 全体的な幅制御 */
  * {
    max-width: 100% !important;
    box-sizing: border-box !important;
  }
}
