@import url('https://cdn.jsdelivr.net/npm/galmuri/dist/galmuri.css');

.sidebar-section .latest-title {
    margin-bottom: var(--spacing-sm);
    font-size: var(--content-font-size);
    font-weight: 600;
}

.latest-title a {
    color: var(--content-font-color);
    filter: brightness(1.2);
    text-decoration: none;
    transition: color 0.2s ease;
}

.latest-title a:hover {
    color: var(--accent-color);
}

.latest-list {
    list-style: none;
    margin-top: auto;
    margin-bottom: auto;
    padding: 0;
    transform: translateY(-5px);
}

.latest-item {
    position: relative;
    margin-bottom: 5px;
}

.latest-item:last-child {
    margin-bottom: 0;
}

.latest-link {
    display: flex;
    justify-content: space-between;
    align-items: center;
    color: var(--content-font-color);
    text-decoration: none;
    transition: background 0.2s ease, color 0.2s ease;
    border-radius: var(--spacing-xs);
    padding: var(--spacing-xxs) var(--spacing-xs);

    background: rgba(255, 255, 255, 0.22);
}

.latest-link:hover {
    background: var(--content-font-color);
    color: var(--bg-color);
}

.latest-link:hover .latest-subject,
.latest-link:hover .latest-date {
    color: var(--bg-color);
}

.latest-subject {
    flex: 1;
    font-size: 12px;
    line-height: 1.2;
    overflow: hidden;
    text-overflow: ellipsis;
    white-space: nowrap;
    margin-right: 8px;
    color: var(--content-font-color);
}

.latest-date {
    font-size: 11px;
    color: var(--text-muted);
    flex-shrink: 0;
}

/* 아이콘 및 배지 */
.icon-lock {
    font-size: 10px;
    margin-right: 4px;
}

.notice-badge {
    background: var(--accent-color);
    color: var(--white);
    font-size: 10px;
    padding: 2px 6px;
    border-radius: 10px;
    margin-right: 6px;
}

.comment-count {
    color: var(--accent-color);
    font-size: 11px;
    margin-left: 4px;
}

/* .new-badge, .hot-badge {
    position: absolute;
    right: 0;
    top: 50%;
    transform: translateY(-50%);
    font-size: 10px;
    background: #4caf50;
    color: white;
    padding: 2px 4px;
    border-radius: 8px;
    font-weight: bold;
}

.hot-badge {
    background: transparent;
    font-size: 12px;
} */

.latest-empty {
    text-align: center;
    color: var(--text-muted);
    font-size: 12px;
    padding: 20px 0;
}

.latest-more {
    display: block;
    text-align: center;
    margin-top: 0;
    padding: 8px;

    background: #8C8D37;
    color: #475569;

    text-decoration: none;
    border-radius: 6px;
    font-size: 12px;
    transition: all 0.2s ease, color 0.2s ease;
    /*border: 1px solid #ffffff;*/
}

.latest-more:hover {
    background: #A1A251;
    color: #475569;
}

/* 게시판 이름 스타일 */
.board-name {
    background: var(--btn-secondary-bg);
    color: var(--btn-secondary-text);
    font-size: 10px;
    margin-right: 4px;
    font-weight: 500;
    border-radius: var(--spacing-xs);
    padding: var(--spacing-xxs);
}

.latest-subject {
    display: flex;
    align-items: center;
    flex-wrap: wrap;
    font-family: Galmuri9, sans-serif;
    font-weight: 400;
    padding-left: 5px; /* 추천 */
}


/* 반응형 */
@media (max-width: 768px) {
    .sidebar-latest {
        padding: 12px;
    }
    
    .latest-subject {
        font-size: 12px;
        padding-left: 3px; /* 추천 */
    }
    
    .latest-date {
        font-size: 10px;
    }
}

.sidebar-latest > .latest-title {
    display: block !important;
    margin: 0 0 10px 0 !important;
    font-size: 36px !important;
    line-height: 1.2 !important;
}

.sidebar-latest > .latest-title span {
    font-family: 'CloudSofaNamgim', sans-serif !important;
    color: #31673C !important;
    cursor: default;
    transition: color 0.2s ease;
}

.sidebar-latest > .latest-title span:hover {
    color: #60996B !important;
}

.sidebar-latest {
    display: flex;
    flex-direction: column;
    height: 100%;
}

.sidebar-section,
.sidebar-section .lat,
.sidebar-latest {
    height: 100%;
}

.sidebar-latest {
    display: flex;
    flex-direction: column;
}

.latest-more {
    margin-top: auto;
}

.latest-new {
    display: inline-flex;
    align-items: center;
    justify-content: center;

    padding: 1px 5px;
    border-radius: 4px;

    background: #31673c;
    color: #FFE585 !important;

    font-family: Galmuri9, sans-serif;
    font-size: 9px;
    font-weight: 400;
    line-height: 1.4;
}

.latest-link:hover .latest-new {
    color: #fff !important;
    background: #60996b;
}