* { box-sizing: border-box; }
html, body, #app { height: 100%; margin: 0; }
body { font-family: "PingFang SC", "Microsoft YaHei", "Helvetica Neue", Arial, sans-serif; background: #f5f7fa; }

.layout { height: 100vh; display: flex; }
.sidebar { width: 220px; background: #1d2535; color: #cfd6e4; display: flex; flex-direction: column; flex-shrink: 0; }
.logo { height: 60px; display: flex; align-items: center; justify-content: center; gap: 8px; color: #fff; font-size: 17px; font-weight: 600; letter-spacing: 1px; }
.logo .dot { width: 10px; height: 10px; border-radius: 50%; background: #ff5f5f; box-shadow: 0 0 8px #ff5f5f; }
.sidebar .el-menu { border-right: none; background: transparent; flex: 1; overflow-y: auto; }
.sidebar .el-menu-item { color: #aeb7c8; height: 46px; }
.sidebar .el-menu-item:hover { background: #263046; color: #fff; }
.sidebar .el-menu-item.is-active { background: #2f6bff; color: #fff; border-radius: 0; }

.main-area { flex: 1; display: flex; flex-direction: column; min-width: 0; }
.topbar { height: 60px; background: #fff; border-bottom: 1px solid #e8ecf2; display: flex; align-items: center; justify-content: space-between; padding: 0 24px; flex-shrink: 0; }
.topbar .crumb { font-size: 16px; font-weight: 600; color: #1f2d3d; }
.topbar .user-box { display: flex; align-items: center; gap: 12px; }
.content { flex: 1; overflow-y: auto; padding: 20px 24px; }

.page-card { background: #fff; border-radius: 10px; padding: 20px; box-shadow: 0 1px 4px rgba(31,45,61,.06); margin-bottom: 16px; }
.toolbar { display: flex; flex-wrap: wrap; gap: 10px; margin-bottom: 16px; align-items: center; }
.pager { margin-top: 16px; display: flex; justify-content: flex-end; }

/* 看板 */
.stat-grid { display: grid; grid-template-columns: repeat(6, 1fr); gap: 14px; margin-bottom: 16px; }
.stat-card { background: #fff; border-radius: 10px; padding: 18px; box-shadow: 0 1px 4px rgba(31,45,61,.06); }
.stat-card .label { color: #8492a6; font-size: 13px; }
.stat-card .value { font-size: 26px; font-weight: 700; color: #1f2d3d; margin-top: 6px; font-family: "DIN Alternate", Consolas, monospace; }
.stat-card .value.warn { color: #e6a23c; }
.stat-card.blue { border-top: 3px solid #2f6bff; }
.stat-card.green { border-top: 3px solid #67c23a; }
.stat-card.orange { border-top: 3px solid #e6a23c; }
.stat-card.red { border-top: 3px solid #f56c6c; }
.stat-card.cyan { border-top: 3px solid #14c0c0; }
.stat-card.purple { border-top: 3px solid #7b5cff; }

.chart-row { display: grid; grid-template-columns: 2fr 1fr; gap: 16px; }
.chart-box { background: #fff; border-radius: 10px; padding: 16px; box-shadow: 0 1px 4px rgba(31,45,61,.06); }
.chart-box h4 { margin: 0 0 10px; color: #1f2d3d; }
#trendChart { width: 100%; height: 320px; }
.rank-list { max-height: 320px; overflow-y: auto; }
.rank-item { display: flex; align-items: center; padding: 8px 4px; border-bottom: 1px dashed #eef1f6; font-size: 13px; color: #1f2d3d; gap: 10px; }
.rank-item .no { width: 22px; height: 22px; border-radius: 6px; background: #eef1f6; color: #8492a6; display: flex; align-items: center; justify-content: center; font-weight: 700; font-size: 12px; flex-shrink: 0; }
.rank-item:nth-child(1) .no { background: #ff4d4f; color: #fff; }
.rank-item:nth-child(2) .no { background: #ff9c6e; color: #fff; }
.rank-item:nth-child(3) .no { background: #ffc53d; color: #fff; }
.rank-item .name { flex: 1; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.rank-item .cnt { color: #2f6bff; font-weight: 700; }

/* 登录页 */
.login-wrap { height: 100vh; display: flex; align-items: center; justify-content: center; background: linear-gradient(135deg, #1d2535 0%, #2f4a7a 55%, #2f6bff 100%); }
.login-card { width: 380px; background: #fff; border-radius: 14px; padding: 38px 34px; box-shadow: 0 20px 60px rgba(0,0,0,.3); }
.login-card h2 { margin: 0 0 6px; color: #1f2d3d; }
.login-card .sub { color: #8492a6; font-size: 13px; margin-bottom: 26px; }
.login-tip { margin-top: 16px; font-size: 12px; color: #a0aabb; line-height: 1.8; }

.coupon-cover { width: 64px; height: 44px; border-radius: 6px; object-fit: cover; background: #f0f2f5; display: block; }
.dialog-images { display: flex; gap: 8px; flex-wrap: wrap; }
.dialog-images img { width: 120px; height: 90px; object-fit: cover; border-radius: 8px; border: 1px solid #eee; }
.line-through { text-decoration: line-through; color: #a0aabb; }
.price { color: #ff4d4f; font-weight: 700; }
.muted { color: #8492a6; font-size: 12px; }
.mb0 { margin-bottom: 0 !important; }
