body {
    padding-top: 56px;
    background-color: #1E1E1E;
    color: white;
    display: flex;
}
a {
    color: #00FFFF;
}

.navbar-icons img {
    border-radius: 50%;
}
.sidebar {
    width: 320px;
    height: calc(100vh - 56px);
    background-color: #1e1e1e;
    padding: 10px;
    overflow-y: auto;
    position: fixed;
    left: 0;
    top: 56px;
    transition: transform 0.3s ease-in-out;
    z-index: 20;
}
@media (max-width: 768px) {
    .sidebar {
        transform: translateX(-100%);
    }
    .sidebar.show {
        transform: translateX(0);
    }
}
.sidebar::-webkit-scrollbar {
    display: none;
}
.sidebar {
    -ms-overflow-style: none;
    scrollbar-width: none;
}
.channel-item {
    padding: 10px;
    border-bottom: 1px solid #333;
    color: white;
    text-decoration: none;
    display: flex;
    align-items: center;
}
.channel-item:hover {
    background-color: #333;
}

.channel-content {
    display: flex;
    flex-direction: column;
    overflow: hidden;
}
.channel-title {
    font-weight: bold;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
}
.channel-comment {
    font-size: 0.9em;
    color: #bbb;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
}
.channel-time {
    font-size: 0.8em;
    color: #777;
}
.content {
    flex-grow: 1;
    padding: 20px;
    margin-left: 300px;
}

/* スマホ（最大幅 600px の場合） */
@media (max-width: 768px) {
    .content {
        padding-left: 5px;
        padding-right: 5px;
    }
}

.user-name {
    font-size: 1em; /* 名前のフォントを少し大きくする */
    /*font-weight: bold; /* 必要なら名前を太字に */*/
}

.date-time {
    font-size: 0.8em; /* 投稿日時のフォントサイズはそのまま */
    color: #777;
}

@media (max-width: 768px) {
    .content {
        margin-left: 0;
    }
}
@media (min-width: 769px) {
    #toggleSidebar {
        display: none;
    }
}

.channel-icon {

    display: flex;
    flex-direction: column; /* 縦並びにする */
    align-items: center; /* 中央揃え */
    margin-right: 15px;
}

.channel-icon img {
    width: 50px; /* アイコンのサイズ（調整可） */
    height: 50px;
    border-radius: 50%; /* 丸いアイコン */
}

.channel-creator {
    font-size: 0.8rem; /* 小さめの文字 */
    color: #bbb; /* 控えめな色 */
    white-space: nowrap; /* 折り返しなし */
    overflow: hidden; /* はみ出した部分を非表示 */
    text-overflow: ellipsis; /* 省略（…を表示） */
    display: block; /* ブロック要素にする */
    max-width: 50px; /* 最大幅を適用（アイコンの幅に合わせる） */
    text-align: center; /* 中央揃え */
}


.channel-title-comment {
    font-size: 24px;
    font-weight: bold;
    margin-bottom: 10px;
    margin-left: 10px;
    color: #ddd; /* 好みの色に変更 */
}



.chat-container {
    display: flex;
    flex-direction: column;
    overflow-y: auto;
    gap: 10px;
}

.message {
    display: flex;
    align-items: flex-start; /* アイコンとテキストを上端揃え */
    gap: 10px;
    padding: 10px;
    border-radius: 10px;
    max-width: 80%; /* デフォルトで80% */
}

.message .message-text-default {
    font-size: 3em;
    font-weight: bold;
    color: #fff;
    letter-spacing: 1px;
    opacity: 0.8;
    margin-left: 10px;

}


/* スマホ（最大幅 600px の場合） */
@media (max-width: 768px) {
    .message {
        max-width: 100%; /* スマホサイズのときは100% */
        padding-left: 0px;
        padding-right: 5px;
    }
}


.message img {
    width: 40px;
    height: 40px;
    border-radius: 50%;
    vertical-align: top;  /* 上端に揃える */
}
.message-text {
    background-color: #333;
    padding: 10px;
    border-radius: 10px;
}
.message.timestamp {
    font-size: 0.8em;
    color: #bbb;
}
.message.right {
    align-self: flex-end;
    flex-direction: row-reverse;
    /*text-align: right;*/
}
.message.right .message-text {
    background-color: #3A78B7;
  }

.message-text.creator {
    background-color: #6A5D9E;
}

.message .comment-thumbnail {
    width: 100px;
    height: auto;
    border-radius: 12px; /* 角を丸くする */
    cursor: pointer;
    margin-top: 8px;
    box-shadow: 0 4px 8px rgba(0, 0, 0, 0.2); /* 少し影をつけておしゃれに */
}



.create-channel-btn {
    background-color: #333; /* ダークグレーの背景色 */
    color: white; /* テキスト色を白に */
    border: 1px solid #555; /* 枠線も少し暗め */
}

.create-channel-btn:hover {
    background-color: #444; /* ホバー時に少し明るく */
    border-color: #666; /* 枠線も少し明るく */
}

.create-channel-btn:focus {
    outline: none; /* フォーカス時のアウトラインを消去 */
    box-shadow: 0 0 5px rgba(255, 255, 255, 0.3); /* 薄い白のシャドウを追加 */
}


 #toggleSidebar {
    background-color: #333; /* ダークグレーの背景色 */
    color: white; /* テキスト色を白に */
    border: 1px solid #555; /* 枠線も少し暗め */
}

#toggleSidebar:hover {
    background-color: #444; /* ホバー時に少し明るく */
    border-color: #666; /* 枠線も少し明るく */
}

#toggleSidebar:focus {
    outline: none; /* フォーカス時のアウトラインを消去 */
    box-shadow: 0 0 5px rgba(255, 255, 255, 0.3); /* 薄い白のシャドウを追加 */
}   


.post-button {
    position: fixed;
    right: 20px;
    bottom: 20px;
    width: 60px;
    height: 60px;
    border-radius: 50%;
    background-color: #007bff;
    color: white;
    font-size: 32px;
    border: none;
    display: flex;
    justify-content: center;
    align-items: center;
    cursor: pointer;
    transition: transform 0.2s;
    text-align: center;
}

.post-button span {
}

.post-button:hover {
    transform: scale(1.2);
}


.scroll-button {
    position: fixed;
    bottom: 90px; /* post-button より上に配置 */
    right: 20px;
    width: 60px;
    height: 60px;
    border-radius: 50%;
    background-color: #007bff;
    color: white;
    font-size: 32px;
    border: none;
    display: flex;
    justify-content: center;
    align-items: center;
    cursor: pointer;
    transition: transform 0.2s;
    text-align: center;
}
.scroll-button:hover {
    transform: scale(1.2);
}

.btn-close {
    filter: invert(1);
}

.navbar .container-fluid {
    justify-content: flex-start !important;
}

/* ハンバーガーメニューを右端に固定 */
.menu-right {
    margin-left: auto !important;
}


#imagePreview {
    max-width: 100%;
    max-height: 100%;
}

        #cropContainer {
            max-width: 100%;
            height: 400px;
            display: flex;
            align-items: center;
            justify-content: center;
            border: 1px solid #ccc;
            background-color: #ddd; /* 予備の背景色 */
            background-image: linear-gradient(45deg, #bbb 25%, transparent 25%, transparent 75%, #bbb 75%),
                              linear-gradient(45deg, #bbb 25%, white 25%, white 75%, #bbb 75%);
            background-size: 20px 20px;
            background-position: 0 0, 10px 10px;
            margin-bottom: 10px;
        }