:root {
    --alpha-color: 255, 255, 255;
    --alpha-bg: 255, 255, 255;
    --icon-size: 80px;
    --icon-gap-x: 20px;
    --icon-gap-y: 20px;
    --icon-radius: 12px;
    --icon-nameSize: 14px;
    --icon-nameColor: #ffffff;
    --bg-body: #35363a;
    --d-main: #ffffff;
}

@media (prefers-color-scheme: dark) {
    body {
        background-color: #35363a;
    }
}

.search-container {
    position: absolute;
    top: 150px;
    left: 50%;
    transform: translateX(-50%);
    z-index: 2;
    width: 90%;
    max-width: 750px;
    padding: 0 20px;
    box-sizing: border-box;
}

.search-box {
    display: flex;
    background-color: #f3f3f3c9;
    border-radius: 8px;
    overflow: hidden;
    box-shadow: 0 2px 10px rgba(0, 0, 0, 0.3);
    height: 48px;
    align-items: center;
}

.search-shortcuts {
    display: flex;
    align-items: center;
    padding: 0 12px;
    border-right: 1px solid rgba(255, 255, 255, 0.3);
    height: 100%;
}

.shortcut-icon {
    width: 32px;
    height: 32px;
    display: flex;
    align-items: center;
    justify-content: center;
    margin-right: 8px;
    border-radius: 50%;
    background-color: rgba(255, 255, 255, 0.3);
    color: white;
    font-size: 14px;
    cursor: pointer;
    transition: background-color 0.2s ease;
}

.shortcut-icon img,
.shortcut-icon svg {
    width: 100%;
    height: 100%;
    object-fit: contain;
    max-width: 22px;
    max-height: 22px;
}

.shortcut-icon:hover {
    background-color: #4a4a4a;
}

/* 搜索引擎选中状态 */
.shortcut-icon.selected {
    background-color: rgba(255, 255, 255, 0.2);
    border-radius: 50%;
    box-shadow: 0 0 0 1px rgba(255, 255, 255, 0.3);
}

.search-input {
    flex: 1;
    padding: 0 16px;
    border: none;
    background: transparent;
    color: white;
    font-size: 14px;
    outline: none;
    height: 100%;
}

.search-input::placeholder {
    color: #aaa;
}

.search-button {
    width: 28px;
    height: 28px;
    margin-right: 20px;
    margin-left: -15px;
    border: 1px solid rgba(255, 255, 255, 0.3);
    background: transparent;
    color: #aaa;
    font-size: 16px;
    cursor: pointer;
    transition: all 0.2s ease;
    display: flex;
    align-items: center;
    justify-content: center;
    border-radius: 50%;
}

/* 删除按钮样式，与搜索按钮一致 */
.clear-button {
    width: 20px;
    height: 20px;
    margin-right: 20px;
    margin-left: -15px;
    border: 1px solid rgba(255, 255, 255, 0.3);
    background: transparent;
    color: #aaa;
    font-size: 16px;
    cursor: pointer;
    transition: all 0.2s ease;
    display: flex;
    align-items: center;
    justify-content: center;
    border-radius: 50%;
}

.search-button:hover {
    color: white;
    border-color: rgba(255, 255, 255, 0.5);
    background-color: rgba(255, 255, 255, 0.05);
}

/* 搜索按钮选中效果 */
.search-button:active {
    background-color: rgba(255, 255, 255, 0.1);
    border-color: rgba(255, 255, 255, 0.7);
}

/* SVG图标选中效果 */
.search-button:active svg {
    transform: scale(0.9);
    transition: transform 0.1s ease;
}

/* 删除按钮悬停效果 */
.clear-button:hover {
    color: white;
    border-color: rgba(255, 255, 255, 0.5);
    background-color: rgba(255, 255, 255, 0.05);
}

/* 删除按钮点击效果 */
.clear-button:active {
    background-color: rgba(255, 255, 255, 0.1);
    border-color: rgba(255, 255, 255, 0.7);
}

/* 删除按钮SVG点击效果 */
.clear-button:active svg {
    transform: scale(0.9);
    transition: transform 0.1s ease;
}

#app {
    width: 100%;
    height: 100%;
    position: relative;
}

.body-bg {
    position: absolute;
    z-index: 0;
    width: 100%;
    height: 100%;
    background-size: cover;
    background-position: center;
    background-repeat: no-repeat;
    margin: 0;
    padding: 0;
    background-image: url('https://picsum.photos/1920/1080?random=1');
}

body {
    position: relative;
    height: 100%;
    margin: 0;
    padding: 0;
    font-family: -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, 'Helvetica Neue', Arial, sans-serif;
}



/* 右上角时间显示 */
.time-display {
    position: fixed;
    top: 20px;
    right: 20px;
    color: white;
    text-shadow: 0 2px 10px rgba(0, 0, 0, 0.5);
    text-align: center;
    z-index: 1000;
    padding: 0;
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
}

.time-display .time {
    font-size: 28px;
    font-weight: bold;
    line-height: 1;
}

.time-display .date {
    font-size: 12px;
    margin-top: 4px;
    line-height: 1.2;
    text-align: center;
}

/* 右下角圆形设置按钮 */
.settings-button {
    position: fixed;
    bottom: 30px;
    right: 30px;
    width: 40px;
    height: 40px;
    border-radius: 50%;
    border: 1px solid rgba(255, 255, 255, 0.3);
    background-color: rgba(0, 0, 0, 0.5);
    color: white;
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    transition: all 0.2s ease;
    z-index: 1000;
    box-shadow: 0 2px 10px rgba(0, 0, 0, 0.2);
}

/* 设置按钮悬停效果 */
.settings-button:hover {
    background-color: rgba(0, 0, 0, 0.7);
    border-color: rgba(255, 255, 255, 0.5);
    transform: scale(1.05);
    box-shadow: 0 4px 15px rgba(0, 0, 0, 0.3);
}

/* 设置按钮点击效果 */
.settings-button:active {
    background-color: rgba(0, 0, 0, 0.8);
    border-color: rgba(255, 255, 255, 0.7);
    transform: scale(0.95);
}

/* 设置按钮图标点击效果 */
.settings-button:active svg {
    transform: scale(0.9);
    transition: transform 0.1s ease;
}

.app-main {
    z-index: 1;
    position: relative;
    height: 100%;
    display: flex;
    flex-direction: column;
}

.app-header {
    padding: 20px;
    display: flex;
    justify-content: space-between;
    align-items: center;
}

.app-content {
    flex: 1;
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    padding: 20px;
}

.app-yiyan {
    margin-bottom: 40px;
    text-align: center;
    color: white;
    text-shadow: 0 2px 10px rgba(0, 0, 0, 0.5);
}

.app-yiyan-body {
    font-size: 20px;
    line-height: 1.6;
    max-width: 800px;
}

.yiyan-from {
    font-size: 14px;
    margin-top: 10px;
    opacity: 0.8;
}

.app-icon-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, var(--icon-size));
    grid-gap: var(--icon-gap-x) var(--icon-gap-y);
    justify-content: center;
    max-width: 1350px;
    width: 100%;
}

.app-item {
    list-style-type: none;
    position: relative;
}

.app-item-icon {
    position: relative;
    width: 100%;
    height: 100%;
    overflow: hidden;
    border-radius: var(--icon-radius);
    font-size: 12px;
    box-shadow: 0 0 5px rgba(0, 0, 0, 0.1);
    transition: transform 0.2s;
    cursor: pointer;
    background-color: rgba(255, 255, 255, 0.1);
    backdrop-filter: blur(10px);
    -webkit-backdrop-filter: blur(10px);
    display: flex;
    align-items: center;
    justify-content: center;
    color: white;
    font-size: 24px;
}

.app-item-icon:hover {
    transform: translateY(-3px);
    box-shadow: 0 0 15px rgba(0, 0, 0, 0.3);
}

.app-item-title {
    width: 100%;
    margin-top: 6px;
    text-align: center;
    color: var(--icon-nameColor);
    font-size: var(--icon-nameSize);
    line-height: 1.1;
    text-shadow: 0 2px 7px rgba(0, 0, 0, 0.8);
}

.dark {
    --bg-body: #35363a;
    --d-main: #ffffff;
}

/* 搜索建议框样式 */
.search-suggestions {
    position: absolute;
    top: 100%;
    left: 20px;
    right: 20px;
    width: calc(100% - 40px);
    height: auto;
    min-height: 80px;
    background-color: rgba(255, 255, 255, 0.95);
    border-radius: 8px;
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.3);
    overflow: hidden;
    z-index: 10;
    margin-top: 2px;
}

.suggestions-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 8px 16px;
    background-color: rgba(243, 243, 243, 0.9);
    border-bottom: 1px solid rgba(0, 0, 0, 0.1);
}

.suggestions-header h4 {
    margin: 0;
    font-size: 12px;
    font-weight: 600;
    color: #666;
}

.clear-history {
    background: transparent;
    border: none;
    font-size: 11px;
    color: #999;
    cursor: pointer;
    padding: 0;
}

.clear-history:hover {
    color: #333;
}

.suggestions-list {
    padding: 8px 12px;
    display: flex;
    flex-wrap: wrap;
    gap: 8px;
    overflow: hidden;
}

.suggestion-item {
    display: flex;
    align-items: center;
    padding: 6px 12px;
    cursor: pointer;
    font-size: 12px;
    color: #333;
    background-color: rgba(243, 243, 243, 0.6);
    border-radius: 16px;
    white-space: nowrap;
    margin-right: 8px;
    margin-bottom: 8px;
    border: 1px solid rgba(0, 0, 0, 0.1);
}

.suggestion-item:hover {
    background-color: rgba(220, 220, 220, 0.8);
    border-color: rgba(0, 0, 0, 0.2);
}

.suggestion-icon {
    margin-right: 6px;
    font-size: 12px;
}

.suggestion-text {
    flex: 1;
}

/* 搜索推荐样式 */
.widget-content {
    max-height: 120px;
    overflow-y: auto;
    padding: 0;
}

.widget-content::-webkit-scrollbar {
    width: 2px;
}

.widget-content::-webkit-scrollbar-track {
    background: #f1f1f1;
}

.widget-content::-webkit-scrollbar-thumb {
    background: #ccc;
    border-radius: 2px;
}

/* 热搜排行榜样式 */
.widget-content .suggestion-item {
    display: flex;
    align-items: center;
    padding: 6px 16px;
    cursor: pointer;
    font-size: 13px;
    color: #333;
    background-color: transparent;
    border-radius: 0;
    white-space: nowrap;
    margin-right: 0;
    margin-bottom: 0;
    border: none;
    border-bottom: 1px solid rgba(0, 0, 0, 0.05);
}

.widget-content .suggestion-item:hover {
    background-color: rgba(243, 243, 243, 0.8);
    border-color: rgba(0, 0, 0, 0.1);
}

.widget-content .suggestion-rank {
    width: 20px;
    font-size: 14px;
    font-weight: bold;
    margin-right: 12px;
    color: #666;
}

.widget-content .suggestion-item:nth-child(-n+3) .suggestion-rank {
    color: #ff4d4f;
}

.widget-content .suggestion-text {
    flex: 1;
    margin-right: 12px;
    overflow: hidden;
    text-overflow: ellipsis;
    white-space: nowrap;
}

.widget-content .suggestion-hot {
    font-size: 11px;
    color: #999;
    margin-left: auto;
}


.loading {
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    height: 100px;
    color: #999;
    font-size: 12px;
}

.spinner {
    width: 20px;
    height: 20px;
    border: 2px solid #f3f3f3;
    border-top: 2px solid #ff6b6b;
    border-radius: 50%;
    animation: spin 1s linear infinite;
    margin-bottom: 8px;
}

@keyframes spin {
    0% { transform: rotate(0deg); }
    100% { transform: rotate(360deg); }
}

.fade-in {
    animation: fadeIn 0.5s ease;
}

@keyframes fadeIn {
    from { opacity: 0; transform: translateY(10px); }
    to { opacity: 1; transform: translateY(0); }
}

/* 响应式 */
@media (max-width: 768px) {
    .search-suggestions {
        left: 10px;
        right: 10px;
        width: calc(100% - 20px);
    }
    
    .widget-content {
        max-height: 200px;
    }
}

/* 搜索框下方的四个框样式 */
.boxes-container {
    position: absolute;
    top: 250px;
    left: 50%;
    transform: translateX(-50%);
    z-index: 1;
    width: 100%;
    max-width: 1400px;
    min-width: 1080px;
    padding: 0 10px;
    box-sizing: border-box;
    display: flex;
    justify-content: center;
    align-items: center;
}

.boxes-grid {
    display: grid;
    grid-template-columns: repeat(3, 340px);
    grid-gap: 30px;
    justify-content: center;
    align-items: center;
}

.box-item {
    width: 340px !important;
    height: 150px !important;
    background-color: rgba(255, 255, 255, 0.1);
    backdrop-filter: blur(10px);
    -webkit-backdrop-filter: blur(10px);
    border-radius: 8px;
    border: 1px solid rgba(255, 255, 255, 0.2);
    box-shadow: 0 2px 10px rgba(0, 0, 0, 0.2);
    transition: all 0.3s ease;
    overflow: hidden;
}

.box-item:hover {
    transform: translateY(-5px);
    box-shadow: 0 4px 15px rgba(0, 0, 0, 0.3);
    border-color: rgba(255, 255, 255, 0.3);
}



/* 响应式调整 */
@media (max-width: 1200px) {
    .boxes-container {
        min-width: 710px;
    }
    
    .boxes-grid {
        grid-template-columns: repeat(2, 340px);
        grid-gap: 30px;
    }
    
    .box-item {
        width: 340px !important;
        height: 185px !important;
    }
}

@media (max-width: 768px) {
    .boxes-container {
        min-width: 350px;
    }
    
    .boxes-grid {
        grid-template-columns: 1fr;
        grid-gap: 30px;
    }
    
    .box-item {
        width: 100% !important;
        height: 100px !important;
    }
}

@media (max-width: 400px) {
    .boxes-container {
        min-width: 100%;
    }
    
    .boxes-grid {
        grid-gap: 30px;
    }
    
    .box-item {
        width: 100% !important;
        height: 80px !important;
    }
}

/* 百度热搜小组件样式 */
.widget-hotsearch-container {
    width: 100%;
    height: 100%;
    display: flex;
    flex-direction: column;
}

.hotsearch-list {
    flex: 1;
    padding: 0 15px;
    overflow-y: auto;
    display: flex;
    flex-direction: column;
    gap: 6px;
}

.hotsearch-list::-webkit-scrollbar {
    width: 3px;
}

.hotsearch-list::-webkit-scrollbar-track {
    background: rgba(255, 255, 255, 0.1);
}

.hotsearch-list::-webkit-scrollbar-thumb {
    background: rgba(255, 255, 255, 0.3);
    border-radius: 3px;
}

.hotsearch-item {
    display: flex;
    align-items: center;
    padding: 4px 0;
    cursor: pointer;
    transition: all 0.2s ease;
    border-radius: 4px;
}

.hotsearch-item:hover {
    background-color: rgba(255, 255, 255, 0.1);
}

.hotsearch-rank {
    width: 24px;
    font-size: 14px;
    font-weight: bold;
    color: rgba(255, 255, 255, 0.6);
    text-align: center;
    margin-right: 8px;
}

.hotsearch-item:nth-child(1) .hotsearch-rank {
    color: #ff4d4f;
}

.hotsearch-item:nth-child(2) .hotsearch-rank {
    color: #ff7a45;
}

.hotsearch-item:nth-child(3) .hotsearch-rank {
    color: #ffa940;
}

.hotsearch-title {
    flex: 1;
    font-size: 13px;
    color: rgba(255, 255, 255, 0.9);
    overflow: hidden;
    text-overflow: ellipsis;
    white-space: nowrap;
}

.hotsearch-hot {
    font-size: 11px;
    color: rgba(255, 255, 255, 0.5);
    margin-left: 8px;
}

.no-data {
    text-align: center;
    color: rgba(255, 255, 255, 0.5);
    font-size: 13px;
    padding: 20px 0;
}