/* 正文自定义关键词文章列表插件样式 - 简洁版 */
.tagtolist { 
    margin: 20px 0 15px 0;
}

/* 推荐阅读标题样式 */
.tagtolist strong { 
    display: block;
    margin: 0 0 12px 0;
    font-size: 16px;
    font-weight: bold;
    color: #333;
    padding-bottom: 8px;
    border-bottom: 1px solid #e0e0e0;
}

/* 列表容器样式 - 使用flex布局确保对齐 */
.tagtolist ol { 
    margin: 0 !important;
    padding: 0;
    list-style: none;
    display: flex;
    flex-wrap: wrap;
    justify-content: space-between;
}

/* 列表项样式 - 电脑版一行两个，固定宽度确保对齐 */
.tagtolist ol li { 
    width: 49%;
    margin: 0 0 8px 0;
    line-height: 28px;
    white-space: nowrap;
    text-overflow: ellipsis;
    border-bottom: 1px dotted #e0e0e0;
    overflow: hidden;
    box-sizing: border-box;
}

/* 确保奇数项和偶数项都正确对齐 */
.tagtolist ol li:nth-child(odd) {
    margin-right: 1%;
}

.tagtolist ol li:nth-child(even) {
    margin-left: 1%;
}

/* 文章链接样式 */
.tagtolist ol li a { 
    font-size: 14px;
    color: #555;
    text-decoration: none;
    display: block;
    width: 100%;
    overflow: hidden;
    text-overflow: ellipsis;
}

.tagtolist ol li a:hover { 
    color: #007cba;
    text-decoration: underline;
}

/* 夜间模式适配 */
.night .tagtolist strong {
    color: #e0e0e0;
    border-bottom-color: #444;
}

.night .tagtolist ol li { 
    border-bottom-color: #444;
}

.night .tagtolist ol li a { 
    color: #b0b0b0;
}

.night .tagtolist ol li a:hover { 
    color: #4a9cff;
}

/* 手机版一行一个 */
@media screen and (max-width: 768px){
    .tagtolist ol {
        display: block;
    }
    
    .tagtolist ol li { 
        width: 100%;
        margin: 0 0 6px 0 !important;
    }
    
    .tagtolist ol li:nth-child(odd),
    .tagtolist ol li:nth-child(even) {
        margin-left: 0 !important;
        margin-right: 0 !important;
    }
}