/* styles.css file */
html, body {
    height: auto;
    min-height: 100vh;
    overflow-y: auto;
    margin: 0;
    padding: 0;
    font-family: Arial, sans-serif;
    background: #f0f0f0;
    display: flex;
    flex-direction: column;
    align-items: center;
}

.carousel {
    position: relative;
    width: 80%;
    max-width: 800px;
    height: auto; /* 高さを自動調整 */
    overflow: hidden;
    border: 2px solid #ccc;
    background: #fff;
    margin-bottom: 20px; /* ボタンとの間にスペースを追加 */
}

.carousel-inner {
    display: flex;
    transition: transform 0.5s ease;
}

.carousel-item {
    min-width: 100%;
    box-sizing: border-box;
}

.carousel-item img {
    width: 100%; /* 横幅を枠に合わせる */
    height: auto; /* アスペクト比を維持しながらリサイズ */
    max-height: 450px; /* 追加：画像の高さの上限を設定 */
}

.carousel-control {
    position: absolute;
    top: 50%;
    transform: translateY(-50%);
    background: rgba(0, 0, 0, 0.5);
    color: #fff;
    border: none;
    padding: 10px;
    cursor: pointer;
}

.carousel-control.prev {
    left: 10px;
}

.carousel-control.next {
    right: 10px;
}

/* バナーのスタイル */
.banner {
    width: 80%;
    max-width: 800px;
    margin: 0 auto 20px auto; /* 中央揃えとカルーセルに合わせた幅 */
}

.banner img {
    width: 100%; /* 横幅をカルーセルに合わせる */
    height: auto;
}

/* ログインボタンのデザイン */
.login-button-container {
    text-align: center;
    margin-bottom: 10px; /* コンテナ全体に下マージンを追加 */
}

.login-button {
    background-color: #007bff;
    color: #fff;
    padding: 15px 30px;
    font-size: 18px;
    border: none;
    border-radius: 5px;
    cursor: pointer;
    transition: background-color 0.3s ease, transform 0.3s ease;
}

.login-button:hover {
    background-color: #0056b3;
    transform: translateY(-2px);
}

.login-button:active {
    transform: translateY(0);
    background-color: #004080;
}


/* 以下はuser_select.html用 */

.container {
    background-color: #fff;
    padding: 30px;
    border-radius: 10px;
    box-shadow: 0 4px 8px rgba(0, 0, 0, 0.1);
    text-align: center;
    width: 80%;
    max-width: 500px;
}

h1 {
    font-size: 24px;
    margin-bottom: 20px;
    color: #333;
}

.input-group {
    margin-top: 20px;
    display: flex;
    align-items: center;
    justify-content: center;
}

label {
    margin-right: 10px;
}

select {
    padding: 8px;
    font-size: 16px;
    border: 1px solid #ccc;
    border-radius: 5px;
    margin-right: 10px;
}

.login-button-small {
    background-color: #007bff;
    color: #fff;
    padding: 8px 16px;
    font-size: 14px;
    border: none;
    border-radius: 5px;
    cursor: pointer;
    transition: background-color 0.3s ease;
}

.login-button-small:hover {
    background-color: #0056b3;
}

.bottom-buttons {
    margin-top: 20px;
    text-align: center;
}

.navigation-button {
    background-color: #6c757d;
    color: #fff;
    padding: 10px 20px;
    font-size: 16px;
    border-radius: 5px;
    cursor: pointer;
    border: none;
    transition: background-color 0.3s ease;
}

.navigation-button:hover {
    background-color: #5a6268;
}


/* スマホ対応：全体の横はみ出し防止 */
body {
  width: 100%;
  overflow-x: hidden;
  box-sizing: border-box;
  padding: 0;
}

/* すべての要素で box-sizing を安定化させる */
*, *::before, *::after {
  box-sizing: inherit;
}

/* markdown-test コンテナのはみ出し防止 */
#markdown-test {
  word-break: break-word;
  overflow-wrap: break-word;
  width: 100%;
  max-width: 800px;
  margin: 0 auto;
  padding: 1rem;
}

/* メディアクエリで追加調整（480px以下） */
@media screen and (max-width: 480px) {
  .carousel,
  .banner,
  .container,
  #markdown-test {
    width: 100%;
    margin: 0 auto;
    padding-left: 1rem;
    padding-right: 1rem;
  }

  h1 {
    font-size: 20px;
  }

  .login-button {
    font-size: 16px;
    padding: 12px 20px;
  }

  .login-button-small {
    font-size: 13px;
    padding: 6px 14px;
  }

  .navigation-button {
    font-size: 14px;
    padding: 8px 16px;
  }
}
