/* メインのcss */

/* bodyとhtmlの幅を設定 */
html, body {
  width: 100%;
  margin: 0;
  overflow-x: hidden; /* 横スクロールを隠す */
}

h1 h2{
  font-size: 2.5rem;
  margin-top: 0;
  color: #444;
}

article textarea {
  padding: 10px;
  border: 1px solid #ccc;
  border-radius: 4px;
  resize: none;
  max-height: 130px;
  max-width: 500px;
  font-family: 'Helvetica Neue', Arial, sans-serif;
  font-size: 1rem;
  box-shadow: inset 0 1px 3px rgba(0, 0, 0, 0.1);
}

article button {
  background-color: #007BFF;
  color: #fff;
  border: none;
  padding: 10px 20px;
  border-radius: 4px;
  cursor: pointer;
  font-size: 1rem;
  transition: background-color 0.3s, box-shadow 0.3s;
}

article button:hover {
  background-color: #0056b3;
  box-shadow: 0 4px 8px rgba(0, 0, 0, 0.1);
}

main {
  flex: 1; /* コンテンツエリアをフッター以外に伸縮させる */
  padding: 30px;
  box-sizing: border-box; /* パディングを含むサイズ計算 */
  margin-top: 60px; /* ヘッダーの高さ分の余白を追加 */
  margin-bottom: 60px; /* フッターの高さ分の余白を追加 */
}

textarea {
  width: 100%;
  height: 100px;
  padding: 10px;
  border: 1px solid #ccc;
  border-radius: 4px;
  resize: none;
  font-family: 'Helvetica Neue', Arial, sans-serif;
  font-size: 1rem;
  box-shadow: inset 0 1px 3px rgba(0, 0, 0, 0.1);
}

.user-post {
  margin: 10px 0; /* 各投稿の間に余白を追加 */
  padding: 10px;
  border: 1px solid #ccc;
  background-color: #f9f9f9;
  width: 100%; /* 幅を100%に設定 */
  max-width: 600px; /* 最大幅を設定 */
  height: auto; /* 高さを自動調整 */
  margin-left: 0; /* 左に10pxの余白を追加 */
  margin-right: auto; /* 右側の余白を自動調整 */
}

.user-post.visible {
  display: block; /* 文字列が保存されているときに表示 */
}

.user-post .username {
  font-weight: bold;
  margin-bottom: 5px;
}

.user-post .message {
  font-size: 1rem;
  color: #333;
}
@media (max-width: 768px) {
  main {
      padding: 10px; /* パディングを調整 */
  }
}
