/* Genel */
* {
    box-sizing: border-box;
    margin: 0;
    padding: 0;
}

body, html {
    font-family: 'Roboto',sans-serif;
    background: #0d1117;
    color: #fff;
    height: 100%;
    display: flex;
    flex-direction: column;
}

/* Header */
header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 1rem 2rem;
    background: #161b22;
    position: sticky;
    top: 0;
    z-index: 10;
    box-shadow: 0 2px 6px rgba(0,0,0,0.5);
}

    header h1 {
        font-size: 1.8rem;
        font-weight: 700;
    }

    header span {
        color: #ff4655;
    }

/* Hamburger Button Mobil */
.hamburger {
    display: none;
    font-size: 1.5rem;
    color: #ff4655;
    background: none;
    border: none;
    cursor: pointer;
}

/* Filters Wrapper */
.filters-wrapper {
    display: flex;
    justify-content: center;
    padding: 0.5rem 0;
    background: #161b22;
    border-bottom: 1px solid #2c313c;
}

.filters {
    display: flex;
    gap: 0.5rem;
    flex-wrap: wrap;
    padding: 0.7rem 2rem;
    background: #161b22;
    border-bottom: 1px solid #2c313c;
    transition: all 0.3s ease;
}

    .filters select {
        background: #0d1117;
        color: #fff;
        border: 1px solid #2c313c;
        border-radius: 0.5rem;
        padding: 0.5rem;
        min-width: 120px;
    }

/* Main container */
#mainContainer {
    display: flex;
    flex: 1;
    overflow: hidden;
    margin: 1rem 2rem;
    gap: 1rem;
}

/* Sol Panel */
#infoPanel {
    width: 220px;
    background: #161b22;
    border-radius: 0.8rem;
    padding: 1rem;
    border-right: 1px solid #2c313c;
    display: flex;
    flex-direction: column;
    gap: 1rem;
}

    #infoPanel h3 {
        color: #ff4655;
        text-align: center;
        margin-bottom: 0.5rem;
        font-size: 1rem;
    }

.info-item {
    background: #21262d;
    padding: 0.8rem;
    border-radius: 0.5rem;
    font-size: 0.85rem;
    text-align: center;
}

/* Chat Container — Sabit Yükseklik + Scroll */
#chatContainer {
    flex: 1;
    height: 500px; /* Sabit yükseklik masaüstü */
    padding: 1rem;
    background: #0b121b;
    border-radius: 1rem;
    display: flex;
    flex-direction: column-reverse; /* Yeni mesajlar alttan başlar */
    overflow-y: auto; /* Taşan içerik için scroll bar */
    box-shadow: 0 0 25px rgba(255,70,85,0.5);
}

/* Mesaj Balonları — Yan yana ve kart görünümü */
.message-bubble-container {
    display: flex;
    flex-wrap: wrap;
    gap: 0.8rem; /* Mesajlar arası boşluk */
    margin-bottom: 0.8rem;
}

.message-bubble {
    flex: 1 1 calc(48% - 0.8rem); /* İki mesaj yan yana */
    min-width: 180px;
    max-width: 100%;
    background: #1e2530;
    color: #e0e6f0;
    border-radius: 1rem;
    padding: 1rem;
    border: 1px solid #2f3d50;
    transition: transform 0.3s, box-shadow 0.3s;
}

    .message-bubble.user {
        align-self: flex-end; /* Kullanıcı mesajı sağa */
        background: linear-gradient(135deg,#1b2a3f,#3f4f6b);
        border: 1px solid #ff8c42;
    }

    .message-bubble:hover {
        transform: scale(1.02);
        box-shadow: 0 0 15px rgba(255,140,66,0.6);
    }

/* Başlık ve içerik */
.message-header {
    font-size: 0.8rem;
    color: #cfd8e4;
    margin-bottom: 0.3rem;
    font-weight: 500;
}

.message-content {
    font-size: 1rem;
    color: #f5f8fa;
    line-height: 1.4;
}

/* Taglar */
.message-tags-top {
    display: flex;
    gap: 0.4rem;
    margin-bottom: 0.5rem;
    flex-wrap: wrap;
}

.tag {
    padding: 0.3rem 0.6rem;
    border-radius: 0.5rem;
    font-size: 0.75rem;
    font-weight: 600;
    color: #fff;
    box-shadow: 0 0 6px rgba(0,0,0,0.5);
}

    .tag.mode {
        background: linear-gradient(135deg,#ff6b6b,#ff3d71);
    }

    .tag.rank {
        background: linear-gradient(135deg,#0f5fbd,#0c1f42);
    }

    .tag.seeking {
        background: linear-gradient(135deg, #ffb83d, #296bc7);
        color: #fff; /* yazıyı beyaz yapar */
        font-weight: 600; /* biraz daha kalın yapar */
        text-shadow: 0 0 4px rgba(0,0,0,0.3); /* kontrast için hafif gölge */
        border-radius: 0.4rem; /* köşeleri yuvarlatma */
        padding: 0.2rem 0.5rem; /* iç boşluk */
    }

    .tag.server {
        background: linear-gradient(135deg,#ffd86b,#ffb83d);
    }
    .tag.role {
        background-color: #ff4f4f;
    }

    
/* RiotID */
.riot-id {
    display: inline-block;
    font-size: 1.4rem;
    font-weight: 900;
    color: #fff;
    background: linear-gradient(135deg,#4039e6,#1c0497);
    padding: 0.3rem 0.7rem;
    border-radius: 0.6rem;
    box-shadow: 0 0 12px rgba(255,61,113,0.8);
    animation: pulse 1.5s infinite alternate;
}
.game-id {
    display: inline-block;
    font-size: 1.4rem;
    font-weight: 900;
    color: #fff;
    background: linear-gradient(135deg,#4039e6,#1c0497);
    padding: 0.3rem 0.7rem;
    border-radius: 0.6rem;
    box-shadow: 0 0 12px rgba(255,61,113,0.8);
    animation: pulse 1.5s infinite alternate;
}

@keyframes pulse {
    0% {
        transform: scale(1);
    }

    50% {
        transform: scale(1.08);
    }

    100% {
        transform: scale(1);
    }
}

/* Sidebar */
#sidebar {
    width: 220px;
    background: #161b22;
    border-left: 1px solid #2c313c;
    border-radius: 0.8rem;
    padding: 1rem;
    display: flex;
    flex-direction: column;
    max-height: 500px; /* chatContainer yüksekliği ile eşit */
    overflow-y: auto; /* taşarsa scroll aç */
    box-shadow: 0 0 15px rgba(255,70,85,0.3);
}


    #sidebar h3 {
        color: #ff4655;
        margin-bottom: 1rem;
        text-align: center;
        font-size: 1rem;
    }

.user-item {
    display: flex;
    align-items: center;
    margin-bottom: 0.5rem;
}

.user-avatar {
    width: 30px;
    height: 30px;
    border-radius: 50%;
    background: #ff4655;
    display: flex;
    align-items: center;
    justify-content: center;
    margin-right: 0.5rem;
    font-size: 0.8rem;
    color: #fff;
}

.user-name {
    font-size: 0.9rem;
    color: #c9d1d9;
}

/* Input Form */
#inputForm {
    display: flex;
    padding: 0.7rem 2rem;
    gap: 0.5rem;
    background: #161b22;
    border-top: 1px solid #2c313c;
    border-radius: 0 0 0.8rem 0.8rem;
}

    #inputForm input, #inputForm select {
        flex: 1;
        padding: 0.5rem;
        border-radius: 0.5rem;
        border: 1px solid #2c313c;
        background: #0d1117;
        color: #fff;
    }

    #inputForm button {
        padding: 0.5rem 1.2rem;
        border-radius: 0.5rem;
        border: none;
        background: linear-gradient(135deg,#ff4655,#ff8c42);
        color: #fff;
        font-weight: 600;
        cursor: pointer;
    }

        #inputForm button:hover {
            transform: scale(1.05);
        }

/* Scrollbar */
#chatContainer::-webkit-scrollbar, #sidebar::-webkit-scrollbar {
    width: 8px;
}

#chatContainer::-webkit-scrollbar-thumb, #sidebar::-webkit-scrollbar-thumb {
    background-color: #ff4655;
    border-radius: 4px;
}

#chatContainer::-webkit-scrollbar-track, #sidebar::-webkit-scrollbar-track {
    background-color: #0d1117;
}

/* Mobil Stil */
@media(max-width:768px) {
    #mainContainer {
        flex-direction: column;
        margin: 0.5rem;
    }

    #sidebar, #infoPanel {
        display: none;
    }

    #chatContainer {
        flex: 1;
        min-height: 50vh;
        max-height: 70vh;
        margin-bottom: 0.5rem;
        padding: 0.8rem;
        border-radius: 0.8rem;
        display: flex;
        flex-direction: column-reverse;
        overflow-y: auto;
        box-shadow: 0 0 20px rgba(255,70,85,0.5);
    }

    #inputForm {
        flex-direction: column;
        gap: 0.4rem;
        padding: 0.5rem 1rem;
        border-radius: 0;
    }

        #inputForm input, #inputForm select, #inputForm button {
            width: 100%;
        }

    .hamburger {
        display: block;
    }

    .filters-wrapper {
        display: none;
        flex-direction: column;
        position: fixed;
        top: 60px;
        left: 0;
        width: 100%;
        z-index: 20;
        background: #161b22;
        padding: 1rem;
        border-bottom: 1px solid #2c313c;
        transition: all 0.3s ease;
    }

        .filters-wrapper.show {
            display: flex;
        }

    .filters {
        flex-direction: column;
        gap: 0.5rem;
    }

    .message-bubble {
        flex: 1 1 100%;
        max-width: 95%;
    }
}
