        .search-box {
            position: relative;
            display: block;
            width: 100%;
            margin: 0 auto;
        }
        .search-input {
            width: 100%;
            height: 35px;
            font-size: 16px;
            padding: 5px;
            padding-right: 28px;
            border: 1px dashed green;
            border-radius: 5px;
            color: inherit;
            background-color: transparent;
            transition: background-color 0.3s ease;
        }
        .search-dropdown {
            position: absolute;
            top: 100%;
            left: 0;
            width: 100%;
            max-height: 200px;
            overflow-y: auto;
            background-color: rgba(120, 120, 120, 0.95);
            border: 1px solid #ccc;
            border-radius: 0 5px 5px;
            display: none;
            z-index: 1;
            list-style-type: none;
            margin: 0 auto;
            text-align: center;
        }
        .search-dropdown li {
            box-sizing: border-box;
            padding: 1px 10px;
            border-bottom: 1px solid #ccc;
            display: inline-block;
            width: auto; /* 允许列表项根据内容自动调整宽度 */
            margin-right: 10px;
        }
        .search-dropdown a {
            text-decoration: none;
            color: #fff;
        }
        .search-dropdown a:hover {
            color: red; /* 当鼠标悬停时，链接文字颜色变为绿色 */
        }

        /* 新增样式：清除按钮 */
        .search-input-clear {
            position: absolute;
            right: 5px;
            cursor: pointer;
            font-size: 20px;
            color: #FF0000;
            opacity: 0;
        }
        @media only screen and (max-width: 768px) {
            .search-input-clear {top: -1px;}
        }

        /* 当搜索框内有光标和内容时显示清除按钮 */
     /*.search-input:focus + .search-input-clear,
        .search-input:not(:placeholder-shown) + .search-input-clear {
            opacity: 1;
        }*/
        /* 当搜索框内有内容时显示清除按钮 */
        .search-input:not(:placeholder-shown) + .search-input-clear {
            opacity: 1;
        }


/* 移动端样式调整 */
@media only screen and (max-width: 768px) {
    .search-dropdown {
        line-height: 23px;
        border-radius: 0 5px 5px 3px;
        white-space: nowrap; /* 防止换行 */
        overflow-x: auto; /* 允许水平滚动 */
        justify-content: flex-start; /* 列表项靠左排列 */
    }
    .search-dropdown li {
        display: inline-block; /* 使列表项横向排列 */
        margin-right: 5px; /* 保持列表项之间的间距 */
        margin-bottom: 2px; /* 横线下边的距离 */
        border-bottom: 1px solid #ccc; /* 横线样式 */
    }
}
