/* ==========================================
   NASZA SPOŁECZNOŚĆ SAMOES – STYL PODSTAWOWY
   ========================================== */

.nssamoes-forum-wrapper {
    display: flex;
    gap: 30px;
    margin: 40px auto;
    max-width: 90%;
    width: 100%;
    font-family: "Inter", Arial, sans-serif;
    color: #222;
    line-height: 1.5;
}

/* Sidebar kategorii */
.nssamoes-sidebar {
    width: 260px;
    flex-shrink: 0;
    background: #fafafa;
    border: 1px solid #e0e0e0;
    border-radius: 8px;
    padding: 20px;
}

.nssamoes-sidebar h2 {
    font-size: 1.2rem;
    margin-bottom: 15px;
    color: #333;
}

.nssamoes-categories-list {
    list-style: none;
    padding: 0;
}

.nssamoes-categories-list li {
    margin-bottom: 10px;
}

.nssamoes-categories-list a {
    color: #7b2cbf;
    text-decoration: none;
    font-weight: 500;
}

.nssamoes-categories-list a:hover {
    text-decoration: underline;
}

/* Sekcja główna */
.nssamoes-main-content {
    flex: 1;
    background: #fff;
    border: 1px solid #eaeaea;
    border-radius: 8px;
    padding: 20px 25px;
    box-shadow: 0 1px 3px rgba(0, 0, 0, 0.05);
}

.nssamoes-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    flex-wrap: wrap;
    margin-bottom: 25px;
}

.nssamoes-header h1 {
    font-size: 1.5rem;
    margin: 0;
}

/* Przycisk */
.btn {
    border: none;
    cursor: pointer;
    padding: 8px 14px;
    border-radius: 6px;
    font-weight: 500;
    font-size: 0.95rem;
    transition: background 0.2s ease;
}

.btn--primary {
    background-color: #7b2cbf;
    color: white;
}

.btn--primary:hover {
    background-color: #5a189a;
}

.btn--secondary {
    background-color: #e0d4f5;
    color: #4a1c78;
}

.btn--secondary:hover {
    background-color: #d6c6f2;
}

/* Pasek wyszukiwania */
.nssamoes-search-box {
    display: flex;
    align-items: center;
    gap: 8px;
    margin-top: 10px;
}

.nssamoes-search-box input {
    padding: 8px 10px;
    border: 1px solid #ccc;
    border-radius: 6px;
    width: 220px;
    font-size: 0.95rem;
}

/* Lista wątków */
.nssamoes-threads-list {
    display: flex;
    flex-direction: column;
    gap: 15px;
}

.nssamoes-thread-item {
    display: flex;
    align-items: flex-start;
    background: #fafafa;
    border: 1px solid #e0e0e0;
    border-radius: 8px;
    padding: 15px 20px;
    transition: background 0.2s ease, border 0.2s ease;
}

.nssamoes-thread-item:hover {
    background: #f5f0ff;
    border-color: #c1b1f1;
}

.thread-avatar {
    margin-right: 15px;
    flex-shrink: 0;
}

.thread-avatar img {
    border-radius: 50%;
}

.thread-content {
    flex: 1;
}

.thread-title {
    font-size: 1.05rem;
    margin: 0 0 6px 0;
}

.thread-title a {
    color: #1a1a1a;
    text-decoration: none;
}

.thread-title a:hover {
    text-decoration: underline;
}

.thread-badge {
    font-size: 0.8rem;
    background-color: #e9ecef;
    color: #333;
    border-radius: 4px;
    padding: 2px 6px;
    margin-left: 8px;
}

.thread-badge--closed {
    background-color: #ffe3e3;
    color: #9a1e1e;
}

/* Meta informacje */
.thread-meta {
    font-size: 0.85rem;
    color: #666;
    margin-bottom: 8px;
}

.thread-separator {
    margin: 0 6px;
    color: #bbb;
}

/* Stopka wątku */
.thread-footer {
    font-size: 0.9rem;
    color: #444;
    display: flex;
    gap: 10px;
    flex-wrap: wrap;
}

/* Akcje autora / admina */
.thread-actions {
    margin-left: 15px;
    flex-shrink: 0;
}

.thread-actions button {
    margin-top: 10px;
}

/* Komunikaty */
.nssamoes-no-threads {
    text-align: center;
    padding: 20px;
    color: #777;
}

/* Widok pojedynczego wątku */
.nssamoes-single-thread {
    background: #fff;
    border: 1px solid #e0e0e0;
    border-radius: 8px;
    padding: 25px;
}

.thread-content-full {
    margin-top: 20px;
    font-size: 1rem;
}

.comments-closed {
    margin-top: 15px;
    color: #b3261e;
    font-style: italic;
}

/* Responsywność */
@media (max-width: 900px) {
    .nssamoes-forum-wrapper {
        flex-direction: column;
    }
    
    .nssamoes-sidebar {
        width: 100%;
    }
    
    .nssamoes-header {
        flex-direction: column;
        align-items: flex-start;
        gap: 10px;
    }
}

.nssamoes-new-thread-box {
    border: 1px solid #e6eaf3;
    background: #f8f9fc;
    border-radius: 8px;
    padding: 20px 18px;
    margin-bottom: 24px;
}
.nssamoes-new-thread-box h2 { margin-top:0; margin-bottom:8px;}
.nssamoes-new-thread-box label { font-weight:500; margin:8px 0 4px 0; display:block;}
.nssamoes-new-thread-box input, .nssamoes-new-thread-box textarea, .nssamoes-new-thread-box select {
    border: 1px solid #d6d6d6;
    border-radius: 6px;
    margin-bottom: 13px;
    padding: 7px;
    font-size: 1rem;
    width:99%;
}
.nssamoes-new-thread-box button { min-width:110px; }


.nssamoes-thread-chat-wrapper {
    margin: 35px 0 0 0;
    background: #faf7ff;
    border-radius: 11px;
    padding: 28px 18px 18px 18px;
    border: 1.5px solid #ede0fa;
    max-width: 725px;
}

#nssamoes-thread-chat-list {
    margin-bottom: 22px;
}

.thread-chat-msg {
    display: flex;
    align-items: flex-start;
    background: #fff;
    border: 1px solid #eee;
    margin-bottom: 18px;
    border-radius: 9px;
    padding: 10px 14px 8px 10px;
    transition: box-shadow 0.15s;
    box-shadow: 0 2px 7px rgba(160,110,255,0.03);
}
.thread-chat-msg .chat-author img {
    width: 35px;
    height: 35px;
    border-radius: 50%;
    margin-right: 11px;
}
.thread-chat-msg .chat-author {
    font-size: 1em;
    color: #6e5196;
    font-weight: 600;
    margin-bottom: 2px;
    display: flex;
    align-items: center;
    gap: 10px;
}
.thread-chat-msg .chat-content {
    font-size: 1.05em;
    color: #42265e;
    padding-left: 49px;
    margin-top: -20px;
    padding-bottom: 6px;
    word-break: break-word;
}
.thread-chat-msg .chat-date {
    color: #ab8be0;
    font-size: 0.92em;
    margin-left: 8px;
    font-weight: 400;
}
.thread-chat-msg.chat-empty {
    color: #9791a9;
    background: none;
    border: none;
    text-align: center;
    font-style: italic;
    font-size: 1.08em;
    padding: 16px;
}
#nssamoes-thread-chat-form {
    margin-top: 12px;
}
#nssamoes-thread-chat-form textarea {
    min-height: 43px;
    border-radius: 7px;
    border: 1.3px solid #ded3ee;
    background: #f9f7fc;
    font-size: 1.05em;
}
#nssamoes-thread-chat-form button {
    background: #a05fff;
    color: #fff;
    border: none;
    border-radius: 7px;
    font-size: 1.04em;
    font-weight: 600;
    padding: 8px 25px;
    cursor: pointer;
    transition: background 0.15s;
}
#nssamoes-thread-chat-form button:hover {
    background: #7d48c1;
}
#nssamoes-chat-msg {
    font-size: 1em;
    font-weight: 500;
    margin-left: 18px;
}

.thread-chat-msg {
    display: block;
    margin-bottom: 18px;
    border-radius: 9px;
    background: #fff;
    padding: 10px 14px 8px 10px;
    border: 1px solid #eee;
}
/* poniżej! */
.thread-chat-msg .chat-author {
    display: flex;
    align-items: center;
    gap: 10px;
    margin-bottom: 2px;
}
.thread-chat-msg .chat-content {
    font-size: 1.08em;
    color: #42265e;
    margin-top: 2px;      /* dodaj odstęp od nicka */
    padding-left: 0px;    /* nie przesuwaj w bok */
    word-break: break-word;
    margin-bottom: 2px;
    display: block;       /* wymusi "nową linię" pod nickiem+datą */
}
