:root {
    --primary-color: #4285f4;
    --primary-hover: #2c74e9;
    --text-color: #202124;
    --text-secondary: #5f6368;
    --bg-color: #ffffff;
    --bg-secondary: #f8f9fa;
    --border-color: #dadce0;
    --shadow-light: 0 1px 6px rgba(32, 33, 36, 0.1);
    --shadow-medium: 0 2px 8px rgba(32, 33, 36, 0.15);
    --radius: 24px;
    --radius-small: 12px;
    /* 移除all过渡变量，改为元素单独指定过渡属性，减少计算量 */
}

/* 基础样式重置 - 保持精简，避免多余计算 */
* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

body {
    font-family: -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, 'Helvetica Neue', Arial, sans-serif;
    font-size: 16px;
    line-height: 1.5;
    color: var(--text-color);
    background-color: var(--bg-color);
    min-height: 100vh;
    display: flex;
    flex-direction: column;
    /* 避免body层级不必要的重绘触发 */
}

/* 自定义滚动条 - 保持轻量，仅必要样式 */
::-webkit-scrollbar {
    width: 8px;
    height: 8px;
}
::-webkit-scrollbar-track {
    background: var(--bg-secondary);
}
::-webkit-scrollbar-thumb {
    background: #ccc;
    border-radius: 4px;
}
::-webkit-scrollbar-thumb:hover {
    background: #aaa;
}

/* 主要内容区域 - 简化flex布局，减少嵌套计算 */
.main-content {
    flex: 1;
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    padding: 2rem 1rem;
    max-width: 800px;
    margin: 0 auto;
    width: 100%;
}

/* Logo样式 - 减少嵌套层级，过渡仅指定color */
.app-logo {
    margin-bottom: 2.5rem;
    text-align: center;
}
.logo-text {
    font-size: 2.3rem;
    font-weight: 700;
    color: var(--primary-color);
    letter-spacing: -1px;
}
.logo-text a {
    color: inherit;
    text-decoration: none;
    /* 仅过渡color属性，避免all带来的冗余计算 */
    transition: color 0.2s ease;
}
.logo-text a:hover {
    color: var(--primary-hover);
    text-decoration: none;
}

/* 搜索容器样式 - 优化定位逻辑，过渡仅指定关键属性 */
.search-box-container {
    width: 100%;
    max-width: 600px;
    margin-bottom: 2rem;
    position: relative;
}
.search-form {
    display: flex;
    align-items: stretch;
    width: 100%;
    position: relative;
}
.search-input-container {
    display: flex;
    align-items: center;
    width: 100%;
    height: 44px;
    border: 1px solid var(--border-color);
    border-radius: var(--radius);
    padding: 0 1.25rem;
    background-color: var(--bg-color);
    /* 仅过渡box-shadow和border-color（hover/focus时变化的属性） */
    transition: box-shadow 0.2s ease, border-color 0.2s ease;
}
.search-input-container:hover,
.search-input-container:focus-within {
    box-shadow: var(--shadow-medium);
    border-color: transparent;
}
.search-icon {
    color: #9aa0a6;
    margin-right: 0.75rem;
    font-size: 18px;
}
.search-input {
    flex: 1;
    height: 100%;
    padding: 0;
    font-size: 16px;
    border: none;
    outline: none;
    background: transparent;
    /* 避免输入框默认行为触发额外重绘 */
}
.search-button {
    position: absolute;
    right: 4px;
    top: 4px;
    bottom: 4px;
    padding: 0 1.25rem;
    background-color: var(--primary-color);
    color: white;
    border: none;
    border-radius: calc(var(--radius) - 4px);
    font-size: 14px;
    font-weight: 500;
    cursor: pointer;
    /* 仅过渡background-color（hover时唯一变化的属性） */
    transition: background-color 0.2s ease;
    min-width: 80px;
}
.search-button:hover {
    background-color: var(--primary-hover);
}

/* 搜索提示区域 - 保持轻量文本样式 */
.search-tips {
    margin-bottom: 2.5rem;
    color: var(--text-secondary);
    font-size: 13px;
    text-align: center;
    max-width: 500px;
}
.disk-link {
    color: var(--primary-color);
    text-decoration: none;
    font-weight: 500;
    /* 仅过渡color属性 */
    transition: color 0.2s ease;
}
.disk-link:hover {
    color: var(--primary-hover);
    text-decoration: none;
}

/* 热门标签区域 - 过渡仅指定变化属性，减少计算 */
.hot-tags-container {
    width: 100%;
    background-color: var(--bg-secondary);
    border-radius: var(--radius-small);
    padding: 1.5rem;
    margin-bottom: 2rem;
    border: 1px solid var(--border-color);
}
.section-heading {
    font-size: 18px;
    font-weight: 600;
    color: var(--text-color);
    margin-bottom: 1rem;
}
.tags-container {
    display: flex;
    flex-wrap: wrap;
    gap: 0.75rem;
}
.tag-item {
    padding: 0.4rem 1rem;
    background-color: var(--bg-color);
    color: var(--text-secondary);
    text-decoration: none;
    border-radius: var(--radius-small);
    font-size: 14px;
    border: 1px solid var(--border-color);
    /* 仅过渡hover时变化的3个属性，避免all的冗余计算 */
    transition: background-color 0.2s ease, color 0.2s ease, border-color 0.2s ease;
}
.tag-item:hover {
    background-color: var(--primary-color);
    color: white;
    border-color: var(--primary-color);
}

/* 页脚样式 - 简化布局，减少嵌套 */
.footer {
    background-color: var(--bg-secondary);
    border-top: 1px solid var(--border-color);
    padding: 1rem 0;
    margin-top: auto;
}
.footer-inner {
    display: flex;
    flex-direction: column;
    align-items: center;
    max-width: 1200px;
    margin: 0 auto;
    padding: 0 1rem;
    font-size: 12px;
    color: var(--text-secondary);
}
.footer-links {
    display: flex;
    gap: 1.5rem;
    margin-bottom: 0.75rem;
    flex-wrap: wrap;
    justify-content: center;
}
.footer-links a {
    color: var(--text-secondary);
    text-decoration: none;
    /* 仅过渡color属性 */
    transition: color 0.2s ease;
}
.footer-links a:hover {
    color: var(--primary-color);
}
.copyright {
    text-align: center;
    line-height: 1.6;
}

/* 响应式设计 - 保持断点逻辑，仅修改必要样式，避免重复定义 */
@media (max-width: 768px) {
    .logo-text {
        font-size: 2rem;
    }
    .search-box-container {
        max-width: 100%;
    }
    .search-input-container {
        height: 48px;
        padding: 0 1.25rem;
    }
    .search-input {
        font-size: 16px;
    }
    .search-button {
        padding: 0 1.5rem;
        font-size: 15px;
        min-width: 90px;
    }
    .main-content {
        padding: 1.5rem 1rem;
    }
    .hot-tags-container {
        padding: 1.25rem;
    }
}

@media (max-width: 480px) {
    .logo-text {
        font-size: 1.7rem;
    }
    .main-content {
        padding: 1.25rem 1rem;
    }
    .search-input-container {
        height: 56px;
        padding: 0 1.5rem;
    }
    .search-input {
        font-size: 17px;
        line-height: 1.4;
    }
    .search-icon {
        font-size: 20px;
        margin-right: 1rem;
    }
    .search-button {
        padding: 0 1.75rem;
        font-size: 16px;
        font-weight: 600;
        min-width: 100px;
        top: 6px;
        bottom: 6px;
        right: 6px;
    }
    .tag-item {
        padding: 0.4rem 0.9rem;
        font-size: 13px;
    }
    .footer-links {
        gap: 1rem;
    }
    .footer-inner {
        font-size: 11px;
    }
    .search-tips {
        font-size: 14px;
        line-height: 1.6;
    }
}

/* 搜索图标 - 保持简洁伪元素实现 */
.search-icon:before {
    content: "🔍";
}