html {
    background-color: #f2f2f2;
}
body {
    margin: 0;
}
main {
    margin: 20px;
}
.header{
    padding-top: 40px;
    background-image: url(../images/stripe.png);
    background-repeat: repeat-x;
}
.logo {
    text-align: center;
}
header img {/* でんゆらルームの大きさを調整している（オリ） */
    width: 300px; /* 親要素の幅に合わせる */
    height: auto; /* 自動調整してアスペクト比を維持 */
}

h1.thread-title {
    text-align: center; /* 中央揃え */
    font-size: 30px;    /* 文字サイズを大きくする */
    font-weight: bold;   /* 太字にする */
    margin-top: 20px;    /* 上に余白を追加 */
}
/* 横並びレイアウト */
.form-container {
    position: fixed;
    bottom: 0;
    left: 0;
    width: 100%;
    padding: 15px;
    display: flex;
    align-items: center;
    gap: 10px;
    z-index: 1000; /* 🔹 修正点: 上に配置して隠れないようにする */
    pointer-events: none; /* ← 背後へのクリックを通す */
}

/* メッセージリストに適用 */
#messages-container {
    padding-bottom: 120px; /* 🔹 修正点: フォームの高さ分だけ余白を確保 */
    overflow-y: auto;
}



/* 入力欄のスタイル */
input[type="text"], textarea {
    height: 40px; /* 🔹 高さを統一 */
    padding: 8px;
    font-size: 16px;
    border: 1px solid #ccc;
    border-radius: 5px;
    pointer-events: auto; /* ← 投稿フォームとボタンはクリック可能に */
}

/* 名前入力欄を小さめにする */
input[type="text"] {
    width: 150px;
}

/* メッセージ入力欄は広め */
textarea {
    width: 500px;
    height: 70px;
    resize: none; /* 🔹 手動で高さを変更できないようにする */
}
#message {
    margin-top: 100px; /* 🔹 メッセージ入力欄を少し下げる（適宜調整） */
}


/* ボタンのスタイル */
button {
    padding: 15px 20px;
    background-color: #3580BB;
    color: #fff;
    border: none;
    border-radius: 5px;
    font-size: 18px;
    cursor: pointer;
    pointer-events: auto; /* ← 投稿フォームとボタンはクリック可能に */
}

button:hover {
    background-color: #0056b3;
}
.post p {
    word-wrap: break-word; /* 長い単語を折り返し */
    word-break: break-word; /* 長すぎる場合は強制的に改行 */
    overflow-wrap: break-word; /* 同じく折り返し対応 */
}
#scroll-bottom-btn {
    position: fixed;  /* 🔹 画面に固定 */
    bottom: 80px;     /* 🔹 画面の下から少し余白をつける */
    right: 20px;      /* 🔹 画面右下に配置 */
    padding: 10px 15px ;
    font-size: 14px;
    background-color: #007bff;
    color: white;
    border: none;
    border-radius: 5px;
    cursor: pointer;
    box-shadow: 2px 2px 5px rgba(0, 0, 0, 0.2);
    pointer-events: auto; /* ← 投稿フォームとボタンはクリック可能に */
}

#scroll-bottom-btn:hover {
    background-color: #0056b3;
}

