@charset "utf-8";

/* 게시판 리스트형 스킨 */

.board-container {
    position: relative;
    width: 100%;
}

/* ------------------------------
    BOARD LIST (board-list-container)
------------------------------ */
.board-list-container {
    .board-container {}

    .board-top {
        display: flex;
        margin-bottom: 0.5rem;
        padding: 0 5px 0 0;
        >* {
            align-self: center;
        }
    }
    .board-top-nav {
        display: flex;
        >span {
            position: relative;
            display: inline-block;
            font-size: 14px;
            color: #b9b9b9;
        }
        >span + span {
            margin-left: 11px;
            padding-left: 5px;
        }
        >span+span::before {
            position: absolute;
            content: '/';
            left: -5px;
        }
    }
    .board-search {
        margin-left: auto;
        >.btn-search {
            position: relative;
        }
    }

    .board-category {
        position: relative;
        margin-top: 1rem;
        overflow: hidden;

        ul, li {
            margin: 0;
            padding: 0;
            list-style: none;
        }

        >ul {
            border-bottom: 1px solid var(--bs-border-color);
            >li {
                width: auto;
                >a {
                    text-decoration: none;
                    position: relative;
                    display: block;
                    padding: 7px 15px;
                    &.active {
                        color: var(--wz-color-accent);
                        font-weight: 600;
                    }
                    &.active::after {
                        position: absolute;
                        content: '';
                        bottom: -1px;
                        left: 0;
                        right: 0;
                        height: 3px;
                        background-color: currentColor;
                    }
                }
            }
        }
    }


    .pagination {
        justify-content: center;
    }
}


/* ------------------------------
    BOARD VIEW (board-view-container)
------------------------------ */
.board-view-container {
    .board-container {}
    .comment-container {
        >* {
            margin: 1rem 0;
        }
        #comment-form {}
        #comment-list {
            border-top: 1px solid var(--bs-border-color);
        }
        #comment-more {}
    }
}



/* ------------------------------
    공통 컴포넌트
------------------------------ */

/* 목록 */
.table-list {
    ul, li {
        margin: 0;
        padding: 0;
        list-style: none;
    }
    .table-list-wrapper {
    }
    .table-list-row {
        position: relative;
        border-bottom: 1px solid var(--bs-border-color);

        .list-row {
            position: relative;
            display: flex;
            .list-col {
                position: relative;
                align-self: center;
                text-align: center;
                white-space: nowrap;
                overflow: hidden;
                text-overflow: ellipsis;
                padding: 0.5rem;
                
                &.list-num {
                    flex: 0 0 60px;
                    max-width: 60px;
                }
                &.list-thumb {
                    flex: 0 0 30px;
                    max-width: 30px;
                    border-radius: var(--bs-border-radius);
                    overflow: hidden;
                    img {
                        width: 100%;
                        height: auto;
                    }
                }
                &.list-subject {
                    flex: 1 1 auto;
                    text-align: left;

                    .list-article-info {
                        position: relative;
                        display: flex;
                        gap: 0.5rem;
                        font-size: 0.75rem;
                        color: var(--bs-secondary-color);
                    }
                }
                &.list-name {
                    flex: 0 0 80px;
                    max-width: 80px;
                }
                &.list-hit {
                    flex: 0 0 80px;
                    max-width: 80px;
                }
            }
        }
    }
}

/* 내용 */
.table-content {
    .content-header {
        padding: 0.75rem 1rem;
        background-color: var(--bs-tertiary-bg);
        border-radius: var(--bs-border-radius);
        h2 {
            font-size: 1.25rem;
        }
        .article-info {
            display: flex;
            gap: 0.25rem;
            .info-item {
                position: relative;
                display: inline-block;
                font-size: 0.75rem;
                color: var(--bs-tertiary-color);
            }
        }
    }
    .content-body {
        margin: 1rem 0;
        padding: 1rem 0;
        img {
            width: auto;
            height: auto;
            max-width: 100%;
        }
    }
    .content-footer {
        margin: 1rem 0;
        padding: 1rem 0;
        border-bottom: 1px solid var(--bs-border-color);
    }
}

/* 댓글 */
.comment-list {
    position: relative;
    padding: 1rem 0;
    border-bottom: 1px solid var(--bs-border-color);
    font-size: 0.875rem;
    .comment-list-header {
        display: flex;
        justify-content: flex-start;
        align-items: center;
        gap: 0.5rem;
        font-size: 0.5rem;
        color: var(--bs-secondary-color);
        font-size: 0.75rem;
        
        .name {
            font-weight: 600;
        }
        .date {
            color: var(--bs-tertiary-color);
        }
    }
    .comment-list-body {
        position: relative;
        margin-top: 0.5rem;
        line-height: 1.25rem;
        p {
            margin-bottom: 0.5rem;
        }
        .parent-name {
            display: inline-block;
            margin-right: 0.75rem;
            color: var(--bs-primary);
            font-weight: 600;
        }
    }
    .comment-list-footer {
        margin-top: 0.5rem;
        .board-button-group {
            gap: 0.25rem;
        }
        .btn-xs {
            --bs-btn-font-size: 0.75rem;
            --bs-btn-padding-x: 0.375rem;
        }
    }
    .board-comment-form {
        position: relative;
        margin-top: 1.5rem;
        padding: 0;
    }
}

/* 댓글 없음 */
.comment-empty {
    text-align: center;
    padding: 3rem;
}

/* 버튼 그룹 */
ul.board-button-group {
    display: flex;
    gap: 0.375rem;
    &, li {
        margin: 0;
        padding: 0;
        list-style: none;
    }
}

/* 리액션 그룹 */
.reaction-group {
    display: flex;
    gap: 0.5rem;
    justify-content: center;
    align-items: center;
    .btn-reaction {
        position: relative;
        display: flex;
        flex-direction: column;
        gap: 0.5rem;
        justify-content: center;
        align-items: center;
        padding: 0.75rem 1rem;
        border: 0;
        background-color: var(--bs-tertiary-bg);
        border-radius: var(--bs-border-radius);
        transition: background 0.25s ease;

        &:hover {
            background-color: var(--bs-secondary-bg);
        }

        .reaction-value,
        .reaction-count {
            display: inline-block;
            align-self: center;
            line-height: 1;
        }
        .reaction-value {
            font-size: 1.25rem;
        }
        .reaction-count {
            font-family: var(--bs-font-monospace);
            font-weight: 800;
        }

        &.like {
            color: var(--bs-red);
        }
        &.dislike {
            color: var(--bs-blue);
        }
    }
}


@media(max-width: 768px) {
    .board-top {
        padding: 0 10px;
    }
    .board-top > .board-search > .btn-search svg {
        width: 17px;
        height: 17px;
        stroke: var(--darkgray);
    }
}





#boardSearchModal .customModal-header > .closex {
    width: 21px;
    height: 21px;
    align-self: center;
}

#boardSearchModal .customModal-dialog {
    max-width: 320px;
    height: auto;
}

#boardSearchModal .customModal-content {
    height: auto;
}

#boardSearchModal .board-search-form {

}

#boardSearchModal .board-search-form > .board-search-filter {
    display: flex;
    margin-bottom: 10px;
}

#boardSearchModal .board-search-form > .board-search-filter > .filter {
    position: relative;
    font-size: 14px;
    margin-right: 7px;
}

#boardSearchModal .board-search-form > .board-search-filter > .filter:last-child {
    margin-right: 0;
}

#boardSearchModal .board-search-form > .board-search-input {
    position: relative;
    width: 100%;
}

#boardSearchModal .board-search-form > .board-search-input > input[type="text"] {
    width: 100%;
    padding: .75rem;
}

#boardSearchModal .board-search-form > .board-search-input > .btn-search {
    position: absolute;
    top: 50%;
    right: 10px;
    padding: 0;
    transform: translateY(-50%);
}

#boardSearchModal .board-search-form > .board-search-input > .btn-search > svg {
    width: 21px;
    height: 21px;
    stroke: var(--darkgray);
}



@media(max-width: 768px) {
    .board-comment-form {
        padding: 0 10px;
    }
}

@media(max-width: 768px) {
    .comment-content {
        font-size: 12px;
    }
}
@media(max-width: 768px) {
    .comment-list .board-comment-form {
        padding: 0;
    }
}


