/* --- 全局与基础样式 --- */
:root {
    /* 参考新网站的配色方案 */
    --theme-red: #A92322;      /* 主题深红色 (类似截图中的导航栏和按钮) */
    --theme-red-hover: #8C1C1B;/* 主题深红色悬停 */
    --light-background: #f7f7f7;/* 非常浅的灰色 - 页面背景 (比截图稍亮一点，可调整) */
    --content-background: #ffffff;/* 白色 - 主要内容区域背景 */
    --card-background: #ffffff;   /* 卡片背景 */
    --text-color-dark: #333333; /* 深灰色 - 主要文本 */
    --text-color-light: #ffffff;/* 白色 - 用于深色背景上的文本 */
    --text-color-secondary: #666666; /* 次要文本颜色 (如 placeholder) */
    --border-color: #dddddd;   /* 边框颜色 */
    --input-background: #ffffff; /* 输入框背景 */
    --footer-background: #2c2c2c; /* 页脚深灰色背景 */

    --font-family-sans-serif: 'Noto Sans SC', -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, "Helvetica Neue", Arial, sans-serif;
    --border-radius: 4px; /* 轻微圆角 */
    --box-shadow: 0 2px 5px rgba(0, 0, 0, 0.08); /* 更现代的阴影 */
}

* {
    box-sizing: border-box;
    margin: 0;
    padding: 0;
}

body {
    font-family: var(--font-family-sans-serif); /* 改为无衬线字体 */
    line-height: 1.65; /* 调整行高 */
    color: var(--text-color-dark);
    background-color: var(--light-background);
    padding: 0; /* 移除 body 的 padding，让 container 控制 */
    font-size: 15px; /* 基础字体可以稍小一点 */

    -webkit-user-select: none; /* Safari, Chrome, Opera */
    -moz-user-select: none;    /* Firefox */
    -ms-user-select: none;     /* IE10+ */
    user-select: none;         /* Standard */

}

.container {
    max-width: 1000px; /* 可以适当加宽内容区 */
    margin: 0 auto; /* 页面水平居中 */
    background-color: var(--content-background);
    /* padding: 25px 30px; */ /* 移除容器的 padding，让内部 section 控制 */
    /* border-radius: var(--border-radius); */ /* 移除外层容器的圆角和阴影，使其更像一个页面背景 */
    /* box-shadow: var(--box-shadow); */
    /* border: 1px solid var(--border-color); */
}

/* --- 头部 --- */
.site-header {
    display: flex;
    flex-direction: column;
    align-items: center;
    text-align: center;
    background-color: var(--content-background); /* 头部背景与内容区一致 */
    padding: 30px 20px 25px 20px; /* 调整内边距 */
    border-bottom: 1px solid var(--border-color);
    margin-bottom: 0; /* 移除与搜索面板的间距，让搜索面板紧贴 */
}

.site-header h1 {
    font-size: 2.2em; /* 增大主标题 */
    color: var(--theme-red); /* 主标题用主题红色 */
    font-weight: 500; /* 可以尝试不同的字重 */
    margin: 0 0 10px 0;
    padding: 0;
    /* width: 100%; */ /* 在 flex-column + align-items:center 下通常不需要 */
}

.header-subtitle {
    font-size: 0.9em; /* 副标题字体大小 */
    color: var(--text-color-secondary); /* 副标题颜色 */
    line-height: 1.4;
    margin: 0;
    padding: 0;
}

/* --- 搜索面板 --- */
.search-panel {
    display: flex;
    flex-wrap: wrap;
    gap: 20px; /* 增大元素间距 */
    align-items: flex-end;
    /* margin-bottom: 25px; */ /* 移除，让其与下方结果区有自己的间距控制 */
    padding: 30px 40px; /* 增大内边距 */
    background-color: #f9f9f9; /* 参考图中搜索区的浅灰色背景 */
    /* border: 1px dashed var(--border-color); */ /* 移除虚线边框 */
    /* border-radius: var(--border-radius); */ /* 移除圆角，使其更融入页面 */
}

.form-group {
    flex-grow: 1;
    min-width: 220px; /* 稍微增大最小宽度 */
}

.form-group label {
    display: block;
    margin-bottom: 6px;
    font-weight: 500;
    font-size: 0.9em;
    color: var(--text-color-dark);
}
.form-group label .required {
    color: var(--theme-red); /* 必填项星号用主题红 */
    margin-left: 3px;
}

.form-group input[type="text"] {
    width: 100%;
    padding: 12px 15px; /* 增大输入框内边距 */
    border: 1px solid var(--border-color);
    border-radius: var(--border-radius);
    font-size: 0.95em;
    background-color: var(--input-background);
    color: var(--text-color-dark);
    font-family: var(--font-family-sans-serif);
    transition: border-color 0.15s ease-in-out, box-shadow 0.15s ease-in-out;
}
.form-group input[type="text"]::placeholder { /* Placeholder 颜色 */
    color: #aaa;
}
.form-group input[type="text"]:focus {
    border-color: var(--theme-red);
    outline: 0;
    box-shadow: 0 0 0 0.2rem rgba(169, 35, 34, 0.25); /* 对应主题红色的阴影 */
}

.button-primary {
    background-color: var(--theme-red);
    color: var(--text-color-light);
    border: none; /* 移除边框，使其更扁平 */
    padding: 12px 25px; /* 调整按钮内边距 */
    border-radius: var(--border-radius);
    cursor: pointer;
    font-size: 1em;
    font-weight: 500;
    font-family: var(--font-family-sans-serif); /* 按钮文字也用无衬线 */
    transition: background-color 0.15s ease-in-out;
    line-height: 1.5;
    text-transform: uppercase; /* 按钮文字可以大写，增加强调 */
    letter-spacing: 0.5px; /* 轻微字间距 */
}
.button-primary:hover {
    background-color: var(--theme-red-hover);
}

/* --- 结果摘要 --- */
.results-summary {
    margin: 25px 40px; /* 上下左右间距调整 */
    padding: 12px 18px;
    background-color: #f0f0f0; /* 浅灰色背景 */
    border: 1px solid #e0e0e0;
    border-radius: var(--border-radius);
    font-size: 0.9em;
    color: var(--text-color-dark);
}
.results-summary strong {
    color: var(--theme-red); /* 数量用主题红 */
    font-weight: bold;
}

/* --- 结果区域 --- */
#results-area {
    min-height: 100px;
    display: grid;
    gap: 25px; /* 增大结果项间距 */
    padding: 0 40px 30px 40px; /* 结果区内边距，与搜索面板对齐 */
}

.result-item {
    background-color: var(--card-background);
    border: 1px solid var(--border-color);
    border-radius: var(--border-radius);
    padding: 20px 25px;
    box-shadow: var(--box-shadow);
    transition: box-shadow 0.2s ease-in-out, transform 0.2s ease-in-out;
}
.result-item:hover {
     box-shadow: 0 4px 10px rgba(0, 0, 0, 0.12);
     transform: translateY(-2px); /* 轻微上移效果 */
}

.result-item h3 {
    font-size: 1.25em;
    color: var(--theme-red); /* 结果标题用主题红 */
    margin-bottom: 10px;
    font-weight: 500;
    border-bottom: 1px solid #eee; /* 更细的下划线 */
    padding-bottom: 8px;
}
.result-item h3 .item-id {
    color: var(--text-color-secondary);
    font-size: 0.8em;
    margin-right: 10px;
    font-weight: normal;
}

.result-item p {
    margin-bottom: 8px;
    font-size: 0.95em;
    color: var(--text-color-dark);
    line-height: 1.7; /* 增加详情的行高 */
}
.result-item p strong {
    color: var(--text-color-dark); /* 加粗文字用深色 */
    font-weight: 500;
}

.placeholder-text, .loading-text, .no-results-text, .error-text {
    text-align: center;
    color: var(--text-color-secondary);
    font-style: normal; /* 移除斜体 */
    padding: 40px 0;
    font-size: 1em;
    width: 100%;
}

/* --- 客服提示信息 (移到页脚二维码上方) --- */
.customer-service-prompt {
    text-align: center;
    padding: 15px 20px;
    margin-bottom: 20px; /* 与二维码区域的间距 */
    color: var(--text-color-secondary);
    font-size: 0.85em;
    /* border-top: 1px solid var(--border-color); */ /* 移除这里的边框，让页脚统一处理 */
}


/* --- 分页控件样式 --- */
.pagination-container {
    margin: 30px 40px; /* 调整分页的边距，与结果区对齐 */
    text-align: center;
}

.pagination {
    display: inline-flex;
    align-items: center;
    gap: 8px;
    flex-wrap: wrap;
    justify-content: center;
}

.page-btn {
    background-color: var(--content-background);
    color: var(--theme-red);
    border: 1px solid var(--theme-red);
    padding: 8px 14px; /* 调整按钮大小 */
    border-radius: var(--border-radius);
    cursor: pointer;
    font-size: 0.9em;
    transition: background-color 0.15s ease-in-out, color 0.15s ease-in-out, border-color 0.15s ease-in-out;
    min-width: 40px;
    line-height: 1.5;
}
.page-btn:hover:not(:disabled):not(.active) {
    background-color: var(--theme-red);
    color: var(--text-color-light);
}
.page-btn.active {
    background-color: var(--theme-red);
    color: var(--text-color-light);
    border-color: var(--theme-red);
    cursor: default;
}
.page-btn:disabled {
    background-color: #e9ecef;
    color: #adb5bd;
    border-color: #dee2e6;
    cursor: not-allowed;
}

.page-ellipsis, .page-info {
    padding: 0 8px;
    color: var(--text-color-secondary);
    align-self: center;
    font-size: 0.9em;
}

/* --- 页脚 和 二维码样式 --- */
.site-footer-note { /* 这个现在是真正的页脚，包含二维码和版权 */
    background-color: var(--footer-background); /* 深灰色背景 */
    color: #a0a0a0; /* 页脚浅色文字 */
    padding: 30px 20px; /* 页脚内边距 */
    text-align: center;
    margin-top: 0; /* 因为客服提示信息现在在它上面 */
    border-top: none; /* 移除旧的边框 */
}

.qrcode-wrapper {
    display: inline-block;
    margin-bottom: 25px; /* 二维码区域和下方版权文字的间距 */
}

.qrcode-container {
    text-align: center;
}

.author-info {
    display: flex;
    align-items: center;
    justify-content: center;
    margin-bottom: 15px;
    gap: 15px;
}

.author-avatar-image {
    width: 50px; /* 调小一点头像 */
    height: 50px;
    border-radius: 50%;
    object-fit: cover;
    border: 2px solid #555; /* 页脚中头像边框颜色 */
}

.author-text h2 {
    font-size: 1em;
    color: var(--text-color-light); /* 页脚中作者标题用亮色 */
    margin-bottom: 2px;
    font-weight: 500;
}

.author-text p {
    font-size: 0.85em;
    color: #bbb; /* 页脚中作者次要文字颜色 */
}

.qrcode-image {
    display: block;
    margin: 0 auto;
    border: 3px solid var(--content-background); /* 二维码边框用亮色，在深色背景上更突出 */
    padding: 4px;
    border-radius: var(--border-radius);
    background-color: var(--content-background); /* 给二维码一个白色背景，确保扫描清晰 */
    height: auto;
    max-width: 160px; /* 调整二维码大小 */
    width: auto; /* 让其根据内容和max-width自适应 */
}

.site-footer-note .copyright-text { /* 新增版权文字样式 */
    font-size: 0.8em;
    margin-top: 20px;
    color: #888;
}


/* --- 响应式调整 --- */
@media (max-width: 768px) {
    body {
        padding: 0; /* 小屏幕 body 无边距 */
        font-size: 14px; /* 小屏幕基础字体略小 */
    }
    .container {
        padding: 0; /* 小屏幕容器也无边距，让内部 section 控制 */
        margin: 0;
        border-radius: 0;
        box-shadow: none;
        border: none;
    }
    .site-header {
        padding: 20px 15px 15px 15px; /* 调整头部内边距 */
        margin-bottom: 0;
    }
    .site-header h1 {
        font-size: 1.8em; /* 调整标题大小 */
    }
    .header-subtitle {
        font-size: 0.85em;
    }

    .search-panel {
        flex-direction: column;
        align-items: stretch;
        padding: 20px 15px; /* 调整搜索区内边距 */
        gap: 15px;
    }
    .button-primary {
        width: 100%;
        padding: 12px 20px; /* 调整按钮大小 */
    }
    .results-summary {
        margin: 20px 15px; /* 调整摘要边距 */
        font-size: 0.85em;
    }
    #results-area {
        padding: 0 15px 20px 15px; /* 调整结果区边距 */
        gap: 15px;
    }
    .result-item {
        padding: 15px;
    }
    .result-item h3 {
        font-size: 1.15em;
    }
    .result-item p {
        font-size: 0.9em;
    }
    .customer-service-prompt {
        margin: 15px 0; /* 调整提示信息边距 */
        padding: 10px 15px;
        border-left: none; /* 移除左右边框，使其通栏 */
        border-right: none;
    }

    .pagination-container {
        margin: 20px 15px; /* 调整分页边距 */
    }
    .page-btn {
        padding: 7px 10px;
        font-size: 0.85em;
    }

    .site-footer-note { /* 页脚 */
        padding: 25px 15px;
    }
    .author-avatar-image {
        width: 45px;
        height: 45px;
    }
    .author-text h2 {
        font-size: 0.95em;
    }
    .qrcode-image {
        max-width: 130px; /* 移动端二维码更小一些 */
    }
}