* { box-sizing: border-box; }
body { margin: 0; font-family: -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, 'Helvetica Neue', Arial, 'Noto Sans SC', 'PingFang SC', 'Hiragino Sans GB', 'Microsoft YaHei', sans-serif; color: #222; background: #f6f8fa; }
.site-header { background: #2c3e50; color: #fff; }
.nav { max-width: 980px; margin: 0 auto; display: flex; justify-content: space-between; align-items: center; padding: 14px 16px; }
.nav-left { font-weight: 600; }
.nav-right { display: flex; align-items: center; gap: 16px; }
.nav-links { list-style: none; margin: 0; padding: 0; display: flex; gap: 16px; }
.nav-links a { color: #dfe6ec; text-decoration: none; font-size: 14px; }
.btn-home { background: #409eff; color: #fff; text-decoration: none; padding: 8px 12px; border-radius: 4px; font-size: 14px; font-weight: 500; transition: background 0.3s; }
.btn-home:hover { background: #337ecc; }
.container { max-width: 980px; margin: 24px auto; padding: 0 16px; }
.breadcrumb { color: #667; font-size: 13px; margin-bottom: 12px; }
.page-title { font-size: 22px; font-weight: 600; color: #1f2d3d; text-align: center; margin: 16px 0 20px; }
.card { background: #fff; border-radius: 6px; box-shadow: 0 2px 10px rgba(0,0,0,.04); padding: 18px; margin-bottom: 20px; }
.card h2 { font-size: 18px; border-left: 3px solid #409eff; padding-left: 8px; color: #273444; }
.btn { background: #409eff; color: #fff; border: 0; padding: 10px 14px; border-radius: 4px; cursor: pointer; }
.btn:hover { background: #337ecc; }
.btn-plain { background: #fff; color: #409eff; border: 1px solid #409eff; }
.btn-plain:hover { background: #ecf5ff; }
.btn-copy { background: #f0f9ff; color: #0369a1; border: 1px solid #bae6fd; padding: 4px 8px; border-radius: 4px; font-size: 12px; cursor: pointer; }
.btn-copy:hover { background: #e0f2fe; }
.query-section { margin-top: 12px; }
.input-group { display: flex; gap: 12px; align-items: end; margin-bottom: 16px; }
.input-group label { display: block; font-size: 13px; color: #555; margin-bottom: 6px; }
.input-group input { flex: 1; padding: 8px 10px; border: 1px solid #dcdfe6; border-radius: 4px; font-size: 14px; }
.result-group { border: 1px solid #e4e7ed; border-radius: 6px; padding: 12px; background: #fbfcfe; }
.result-item { display: flex; align-items: center; gap: 8px; padding: 6px 0; border-bottom: 1px dashed #eef2f7; }
.result-item:last-child { border-bottom: 0; }
.result-label { width: 120px; color: #5e6d82; font-size: 13px; flex: 0 0 auto; }
.result-item span:last-of-type { flex: 1; word-break: break-all; }
.table-section { margin-top: 12px; }
.table-controls { display: flex; justify-content: center; align-items: center; gap: 12px; margin-bottom: 16px; flex-wrap: nowrap; }
.table-controls .btn { padding: 6px 12px; font-size: 12px; }
.table-controls span { font-weight: 600; color: #2c3e50; font-size: 14px; }
.table-controls span { font-weight: 600; color: #2c3e50; }
.table-container { overflow-x: auto; display: flex; gap: 16px; }
.ganzhi-sidebar { display: flex; flex-direction: row; gap: 16px; min-width: 200px; }
.ganzhi-column { background: #f8fafc; border: 1px solid #e2e8f0; border-radius: 6px; padding: 12px; flex: 1; }
.ganzhi-column h4 { margin: 0 0 8px 0; font-size: 14px; color: #2c3e50; text-align: center; }
.ganzhi-buttons { display: grid; grid-template-columns: 1fr 1fr; gap: 4px; }
.ganzhi-btn { background: #fff; border: 1px solid #d1d5db; padding: 6px 8px; border-radius: 4px; font-size: 12px; cursor: pointer; text-align: center; }
.ganzhi-btn:hover { background: #f3f4f6; }
.ganzhi-btn.active { background: #409eff; color: #fff; border-color: #409eff; }
table { width: 100%; border-collapse: collapse; background: #fff; border-radius: 6px; overflow: hidden; box-shadow: 0 1px 3px rgba(0,0,0,.1); }
th, td { padding: 12px 8px; text-align: center; border-bottom: 1px solid #e4e7ed; }
th { background: #f8fafc; color: #2c3e50; font-weight: 600; font-size: 14px; }
td { font-size: 13px; }
tr:hover { background: #f8fafc; }
.knowledge-section { margin-top: 12px; }
.knowledge-item { margin-bottom: 20px; }
.knowledge-item h3 { color: #2c3e50; font-size: 16px; margin-bottom: 12px; border-left: 3px solid #409eff; padding-left: 8px; }
.ganzhi-list { display: flex; flex-wrap: wrap; gap: 8px; }
.ganzhi-item { background: #f0f9ff; color: #0369a1; border: 1px solid #bae6fd; padding: 6px 12px; border-radius: 16px; font-size: 14px; font-weight: 500; }
.help-content { margin-top: 12px; }
.help-content h3 { color: #2c3e50; font-size: 16px; margin: 16px 0 8px 0; border-left: 3px solid #409eff; padding-left: 8px; }
.help-content ul { margin: 8px 0; padding-left: 20px; }
.help-content li { margin: 6px 0; line-height: 1.5; }
.example { background: #f8fafc; border: 1px solid #e2e8f0; border-radius: 6px; padding: 12px; margin: 12px 0; }
.example p { margin: 6px 0; }
.example code { background: #e2e8f0; padding: 2px 6px; border-radius: 3px; font-family: 'Monaco', 'Menlo', 'Ubuntu Mono', monospace; }
.desc { color: #5e6d82; font-size: 14px; }

/* 版权信息样式 */
.site-footer { background: #2c3e50; color: #fff; text-align: center; padding: 20px 0; margin-top: 40px; }
.footer-content p { margin: 0; font-size: 14px; color: #dfe6ec; }

/* 移动端适配 */
@media (max-width: 768px) {
  .nav-right { flex-direction: column; gap: 8px; }
  .nav-links { display: none; }
  .btn-home { align-self: flex-end; }
  .page-title { font-size: 18px; }
  .card { padding: 16px; }
  .container { padding: 0 12px; }
  .table-container { flex-direction: column; }
  .ganzhi-sidebar { min-width: auto; }
  .ganzhi-column { padding: 8px; }
  .ganzhi-buttons { grid-template-columns: 1fr; }
  .table-controls { flex-direction: row; gap: 8px; flex-wrap: nowrap; justify-content: center; }
  .table-controls .btn { padding: 4px 8px; font-size: 11px; }
  .table-controls span { font-size: 12px; }
  .input-group { flex-direction: row; gap: 8px; align-items: end; }
  .input-group label { margin-bottom: 0; }
  .input-group input { flex: 1; }
  .result-item { flex-direction: row; align-items: center; gap: 8px; }
  .result-label { width: 80px; flex: 0 0 auto; }
  table { font-size: 12px; }
  th, td { padding: 8px 4px; }
}

@media (max-width: 480px) {
  .page-title { font-size: 16px; }
  .card h2 { font-size: 16px; }
  .btn { padding: 8px 12px; font-size: 14px; }
  .ganzhi-btn { padding: 4px 6px; font-size: 11px; }
  th, td { padding: 6px 2px; }
}
