* { box-sizing: border-box; margin: 0; padding: 0; }
html, body { height: 100%; }
body { font-family: -apple-system, BlinkMacSystemFont, "PingFang SC", "Hiragino Sans GB", "Microsoft YaHei", "Helvetica Neue", Arial, sans-serif; font-size: 14px; color: #2d3748; background: #f7fafc; line-height: 1.6; }
a { text-decoration: none; color: inherit; }
a:hover { color: #2b6cb0; }
img { max-width: 100%; border: 0; display: block; }
ul, ol { list-style: none; }
.container { max-width: 1200px; margin: 0 auto; padding: 0 16px; }

/* Header */
.header { background: #fff; box-shadow: 0 1px 3px rgba(0,0,0,0.06); position: sticky; top: 0; z-index: 100; }
.header-inner { display: flex; align-items: center; justify-content: space-between; height: 68px; }
.logo-wrap { display: flex; align-items: center; gap: 10px; }
.logo { display: inline-flex; align-items: center; }
.logo img { height: 38px; }
.logo-text { font-size: 20px; font-weight: 700; color: #2c5282; letter-spacing: 0.5px; }
.slogan { font-size: 12px; color: #a0aec0; }
.nav { display: flex; gap: 4px; }
.nav a { display: inline-block; padding: 10px 18px; color: #4a5568; font-size: 14px; border-radius: 4px; transition: all 0.2s; }
.nav a:hover { background: #ebf8ff; color: #2b6cb0; }
.nav a.active { background: #2b6cb0; color: #fff; }
.nav a.admin-link { color: #dd6b20; font-weight: 600; }
.nav a.admin-link:hover { background: #fffaf0; color: #c05621; }
.user-box { display: flex; align-items: center; gap: 10px; font-size: 13px; }
.u-name { color: #4a5568; }
.u-link { color: #4a5568; padding: 6px 10px; border-radius: 4px; }
.u-link:hover { background: #edf2f7; color: #2b6cb0; }
.u-btn { background: #2b6cb0; color: #fff; }
.u-btn:hover { background: #2c5282; color: #fff; }

/* Main */
.main { min-height: calc(100vh - 68px - 260px); }

/* Footer */
.footer { background: #1a202c; color: #a0aec0; margin-top: 40px; }
.footer-inner { display: grid; grid-template-columns: repeat(3, 1fr); gap: 40px; padding: 40px 0; }
.footer h4 { color: #fff; font-size: 15px; margin-bottom: 14px; font-weight: 600; }
.footer p { font-size: 13px; line-height: 1.8; }
.footer ul li { padding: 4px 0; font-size: 13px; }
.footer a { color: #a0aec0; }
.footer a:hover { color: #63b3ed; }
.copyright { background: #171923; padding: 14px 0; text-align: center; font-size: 12px; color: #718096; border-top: 1px solid #2d3748; }

/* Common buttons */
.btn-primary { background: #2b6cb0; color: #fff; border: none; padding: 10px 20px; border-radius: 4px; cursor: pointer; font-size: 14px; }
.btn-primary:hover { background: #2c5282; }

/* Forms */
.form-control { width: 100%; padding: 10px; border: 1px solid #e2e8f0; border-radius: 4px; font-size: 14px; }
.form-control:focus { border-color: #4299e1; outline: none; box-shadow: 0 0 0 3px rgba(66, 153, 225, 0.1); }

/* Tables general */
table.data-table { width: 100%; border-collapse: collapse; }
table.data-table th, table.data-table td { padding: 10px; border-bottom: 1px solid #e2e8f0; text-align: left; font-size: 13px; }
table.data-table th { background: #f7fafc; font-weight: 600; color: #4a5568; }

/* Pagination (ThinkPHP 6 默认输出 .pagination) */
.page { padding: 10px 0; }
.page a, .page span { display: inline-block; padding: 4px 10px; margin: 0 2px; border: 1px solid #e2e8f0; border-radius: 3px; background: #fff; color: #4a5568; font-size: 12px; }
.page a:hover { border-color: #4299e1; color: #2b6cb0; }
.page span.current { background: #2b6cb0; color: #fff; border-color: #2b6cb0; }
.pagination { display: inline-flex; flex-wrap: wrap; gap: 4px; list-style: none; margin: 0; padding: 10px 0; }
.pagination li a, .pagination li span { display: inline-block; padding: 6px 12px; border: 1px solid #e2e8f0; border-radius: 4px; background: #fff; color: #4a5568; font-size: 13px; text-decoration: none; }
.pagination li a:hover { border-color: #4299e1; color: #2b6cb0; }
.pagination li.active span { background: #2b6cb0; color: #fff; border-color: #2b6cb0; }
.pagination li.disabled span { color: #cbd5e0; background: #f7fafc; cursor: not-allowed; }

/* Toast */
#toastBox { position: fixed; top: 24px; left: 50%; transform: translateX(-50%); z-index: 99999; pointer-events: none; }
.toast { display: inline-block; padding: 10px 20px; border-radius: 4px; color: #fff; font-size: 13px; box-shadow: 0 4px 12px rgba(0,0,0,0.15); margin-bottom: 8px; animation: toastIn 0.25s ease; }
.toast-success { background: #48bb78; }
.toast-error { background: #f56565; }
.toast-info { background: #4299e1; }
.toast-warn { background: #ed8936; }
@keyframes toastIn { from { opacity: 0; transform: translateY(-12px); } to { opacity: 1; transform: translateY(0); } }

/* Alert tip */
.alert-tip { padding: 10px 14px; border-radius: 4px; font-size: 13px; margin: 10px 0; }
.alert-tip.info { background: #ebf8ff; color: #2b6cb0; border: 1px solid #bee3f8; }
.alert-tip.warn { background: #fffaf0; color: #c05621; border: 1px solid #feebc8; }
.alert-tip.danger { background: #fff5f5; color: #c53030; border: 1px solid #fed7d7; }

/* Hamburger button (mobile only) */
.nav-toggle { display: none; background: none; border: none; cursor: pointer; padding: 8px; margin-left: auto; }
.nav-toggle span { display: block; width: 22px; height: 2px; background: #4a5568; margin: 5px 0; border-radius: 2px; transition: all 0.25s; }

/* Responsive */
@media (max-width: 960px) {
  .header-inner { height: auto; padding: 10px 16px; gap: 8px; }
  .nav-toggle { display: block; }
  .nav { display: none; width: 100%; order: 3; flex-direction: column; gap: 2px; padding-bottom: 8px; }
  .nav.open { display: flex; }
  .nav a { padding: 12px 14px; }
  .user-box { order: 2; margin-left: 0; }
  .logo-wrap { order: 1; }
  .footer-inner { grid-template-columns: 1fr; gap: 24px; padding: 24px 0; }
  .home-wrap { grid-template-columns: 1fr; }
  .hot-grid { grid-template-columns: 1fr; }
  .station-grid { grid-template-columns: repeat(2, 1fr); }
  .space-grid { grid-template-columns: repeat(2, 1fr); }
  .filter-bar { flex-direction: column; align-items: stretch; }
  .filter-bar .f-item { width: 100%; }
  .filter-bar select, .filter-bar input { flex: 1; }
}
@media (max-width: 560px) {
  .station-grid { grid-template-columns: 1fr; }
  .space-grid { grid-template-columns: 1fr; }
  .header-inner { flex-wrap: wrap; }
  .slogan { display: none; }
  .user-box { gap: 4px; }
  .u-link { padding: 6px 6px; }
  .pagination li a, .pagination li span { padding: 5px 9px; font-size: 12px; }
}
