/* ═══════════════════════════════════════════════════════════════
   企订通 - 后台管理系统 v7 现代企业级样式
   ═══════════════════════════════════════════════════════════════ */
* { box-sizing: border-box; margin: 0; padding: 0; }
body {
    font-family: "PingFang SC","Microsoft YaHei",-apple-system,BlinkMacSystemFont,"Helvetica Neue",sans-serif;
    background: #f6f8fb; color: #1f2937; font-size: 14px; line-height: 1.5;
    -webkit-font-smoothing: antialiased;
}
a { color: inherit; text-decoration: none; }
ul, ol { list-style: none; }
button { font-family: inherit; border: 0; outline: 0; background: none; cursor: pointer; }
img { max-width: 100%;}

/* === 设计令牌 === */
:root {
    --primary: #c00518;
    --primary-dark: #a00413;
    --primary-light: #ff7891;
    --primary-soft: #fff5f5;
    --ink: #1f2937;
    --ink2: #374151;
    --ink3: #6b7280;
    --muted: #9ca3af;
    --border: #eef0f4;
    --border-strong: #dde2e8;
    --bg: #f6f8fb;
    --bg-2: #fff;
    --bg-3: #f0f2f6;
    --radius: 10px;
    --radius-lg: 14px;
    --radius-xl: 18px;
    --shadow-sm: 0 1px 2px rgba(15, 23, 42, .04);
    --shadow: 0 4px 12px rgba(15, 23, 42, .05);
    --shadow-lg: 0 12px 32px rgba(15, 23, 42, .08);
    --sider-bg: #0e1a2c;
    --sider-bg-2: #1a2942;
    --sider-text: #b3c4dd;
    --sider-text-active: #fff;
}

/* === 整体布局 === */
.lay { display: flex; min-height: 100vh; background: var(--bg);}

/* === 侧边栏 === */
.sider {
    width: 232px; flex-shrink: 0;
    background: linear-gradient(180deg, var(--sider-bg) 0%, var(--sider-bg-2) 100%);
    color: var(--sider-text);
    position: sticky; top: 0; height: 100vh;
    display: flex; flex-direction: column;
}
.brand {
    padding: 18px 22px;
    display: flex; align-items: center; gap: 10px;
    border-bottom: 1px solid rgba(255,255,255,.06);
}
.brand .ic {
    width: 36px; height: 36px; border-radius: 8px;
    background: linear-gradient(135deg, var(--primary) 0%, var(--primary-light) 100%);
    color: #fff; font-weight: 800;
    display: flex; align-items: center; justify-content: center;
    box-shadow: 0 4px 12px rgba(192,5,24,.4);
    flex-shrink: 0;
}
.brand .nm { color: var(--sider-text-active); font-weight: 700; font-size: 17px; letter-spacing: .5px;}

.sider-nav { padding: 16px 12px; flex: 1; overflow-y: auto;}
.sider-nav li > a {
    display: flex; align-items: center; gap: 12px;
    padding: 11px 14px; border-radius: 8px; color: var(--sider-text);
    font-size: 14px; font-weight: 500;
    margin-bottom: 2px;
    position: relative; transition: all .15s;
}
.sider-nav li > a i {
    width: 18px; text-align: center; font-size: 16px; opacity: .8;
}
.sider-nav li > a:hover {
    color: var(--sider-text-active);
    background: rgba(255,255,255,.06);
}
.sider-nav li > a.on {
    background: linear-gradient(90deg, rgba(192,5,24,.18), rgba(192,5,24,.06));
    color: var(--sider-text-active);
}
.sider-nav li > a.on::before {
    content: ''; position: absolute; left: -12px; top: 6px; bottom: 6px;
    width: 3px; background: var(--primary); border-radius: 2px;
}

.sider-footer {
    padding: 14px 18px; border-top: 1px solid rgba(255,255,255,.06);
    font-size: 12px; color: var(--muted);
}
.sider-footer a { color: var(--sider-text);}

/* === 主体 === */
.main { flex: 1; min-width: 0; display: flex; flex-direction: column;}

/* 顶栏 */
.top {
    height: 60px; padding: 0 28px;
    background: #fff; border-bottom: 1px solid var(--border);
    display: flex; align-items: center; gap: 14px;
    position: sticky; top: 0; z-index: 100;
}
.top h1 { font-size: 17px; color: var(--ink); font-weight: 700;}
.top .crumb { color: var(--ink3); font-size: 13px; flex: 1;}
.top .crumb a { color: var(--ink3);}
.top .crumb a:hover { color: var(--primary);}

.top-right { display: flex; align-items: center; gap: 12px;}
.top-right .bell {
    width: 36px; height: 36px; border-radius: 8px;
    display: flex; align-items: center; justify-content: center;
    color: var(--ink3); cursor: pointer; transition: all .2s;
    position: relative; background: var(--bg-3);
}
.top-right .bell:hover { background: var(--primary-soft); color: var(--primary);}
.top-right .bell .dot { position: absolute; top: 6px; right: 6px; width: 8px; height: 8px;
    background: var(--primary); border-radius: 50%; border: 2px solid #fff;}

.top-right .user {
    display: flex; align-items: center; gap: 8px;
    padding: 4px 12px 4px 4px; border-radius: 30px;
    background: var(--bg-3); transition: all .2s;
}
.top-right .user:hover { background: var(--primary-soft);}
.top-right .user .av {
    width: 32px; height: 32px; border-radius: 50%;
    background: linear-gradient(135deg, var(--primary), var(--primary-light));
    color: #fff; font-weight: 700;
    display: flex; align-items: center; justify-content: center; font-size: 14px;
}
.top-right .user .name { font-size: 13px; color: var(--ink); font-weight: 500;}
.top-right .user .logout { color: var(--ink3); font-size: 13px; padding: 0 0 0 6px;
    border-left: 1px solid var(--border-strong); margin-left: 4px;}
.top-right .user .logout:hover { color: var(--primary);}

/* 内容区 */
.content { flex: 1; padding: 24px 28px; max-width: 100%;}

/* === 卡片 === */
.card { background: #fff; border-radius: var(--radius-lg); padding: 22px;
    box-shadow: var(--shadow-sm); margin-bottom: 18px;
    border: 1px solid var(--border);
}
.card h2 {
    font-size: 15px; color: var(--ink); font-weight: 700;
    margin-bottom: 16px; padding-bottom: 12px;
    border-bottom: 1px solid var(--border);
    display: flex; align-items: center;
}
.card h2 .ac { margin-left: auto; font-weight: 500;}
.card h2 .ac a { color: var(--primary); font-size: 13px; padding: 4px 10px;
    border-radius: 6px; transition: background .2s;}
.card h2 .ac a:hover { background: var(--primary-soft);}

/* === 统计卡片 === */
.stats {
    display: grid; grid-template-columns: repeat(4, 1fr); gap: 16px;
    margin-bottom: 18px;
}
.stat {
    background: #fff; border-radius: var(--radius-lg); padding: 22px;
    border: 1px solid var(--border); box-shadow: var(--shadow-sm);
    display: flex; gap: 16px; align-items: flex-start;
    transition: all .25s;
}
.stat:hover { transform: translateY(-2px); box-shadow: var(--shadow);}
.stat .ic {
    width: 52px; height: 52px; border-radius: 12px;
    display: flex; align-items: center; justify-content: center;
    color: #fff; font-size: 22px; flex-shrink: 0;
}
.stat.s1 .ic { background: linear-gradient(135deg, #c00518, #ff5063);}
.stat.s2 .ic { background: linear-gradient(135deg, #06b6d4, #22d3ee);}
.stat.s3 .ic { background: linear-gradient(135deg, #f59e0b, #fbbf24);}
.stat.s4 .ic { background: linear-gradient(135deg, #7e22ce, #c084fc);}
.stat .body { flex: 1;}
.stat .l { color: var(--ink3); font-size: 13px; margin-bottom: 4px;}
.stat .v { font-size: 28px; font-weight: 800; color: var(--ink); line-height: 1.2;}
.stat .trend { display: inline-flex; align-items: center; gap: 2px; padding: 2px 8px;
    border-radius: 12px; font-size: 11px; font-weight: 600; margin-top: 8px;}
.stat .trend.up { background: #dcfce7; color: #16a34a;}
.stat .trend.down { background: #fee2e2; color: #dc2626;}
.stat .trend.flat { background: #f3f4f6; color: #6b7280;}

/* === 表格 === */
table.tbl { width: 100%; border-collapse: collapse; font-size: 13.5px;}
table.tbl th {
    padding: 12px 14px; background: var(--bg-3); text-align: left;
    color: var(--ink2); font-weight: 600; border-bottom: 1px solid var(--border);
    font-size: 12px; text-transform: uppercase; letter-spacing: .5px;
}
table.tbl td { padding: 14px; border-bottom: 1px solid var(--border); vertical-align: middle; color: var(--ink2);}
table.tbl tr:last-child td { border-bottom: 0;}
table.tbl tr:hover td { background: var(--bg);}

/* 状态徽章 */
.badge {
    display: inline-flex; align-items: center; gap: 4px;
    padding: 3px 10px; border-radius: 12px;
    font-size: 12px; font-weight: 600;
}
.badge::before { content:''; width: 6px; height: 6px; border-radius: 50%; background: currentColor;}
.badge-pending { background: #fef3c7; color: #b45309;}
.badge-ok { background: #dcfce7; color: #16a34a;}
.badge-off { background: #f3f4f6; color: #6b7280;}
.badge-info { background: #dbeafe; color: #1976d2;}
.badge-danger { background: #fee2e2; color: #dc2626;}

/* 操作按钮 */
.opts a, .opts button {
    display: inline-block; padding: 4px 10px; border-radius: 6px;
    font-size: 12px; font-weight: 500;
    color: var(--ink2); background: var(--bg-3);
    transition: all .15s; margin-right: 4px;
}
.opts a:hover, .opts button:hover { background: var(--ink2); color: #fff;}
.opts .danger { background: #fee2e2; color: #dc2626;}
.opts .danger:hover { background: #dc2626; color: #fff;}
.opts .primary { background: var(--primary-soft); color: var(--primary);}
.opts .primary:hover { background: var(--primary); color: #fff;}

/* === 表单 === */
.form .row { margin-bottom: 18px;}
.form label { display: block; font-size: 13px; color: var(--ink2); margin-bottom: 6px; font-weight: 500;}
.form label .req { color: var(--primary); margin-right: 2px;}
.form input[type=text], .form input[type=password], .form input[type=email],
.form input[type=tel], .form input[type=number], .form input[type=url],
.form select, .form textarea {
    width: 100%; padding: 11px 14px;
    border: 1.5px solid var(--border); border-radius: 8px;
    font-size: 14px; font-family: inherit; outline: 0;
    transition: all .2s; background: #fff; color: var(--ink);
}
.form input:focus, .form select:focus, .form textarea:focus {
    border-color: var(--primary);
    box-shadow: 0 0 0 3px rgba(192, 5, 24, .1);
}
.form input::placeholder, .form textarea::placeholder { color: var(--muted);}
.form textarea { min-height: 110px; resize: vertical; line-height: 1.6;}
.form select { cursor: pointer;}
.form .row-grid { display: grid; grid-template-columns: 1fr 1fr; gap: 16px;}
.form .row-grid-3 { display: grid; grid-template-columns: repeat(3, 1fr); gap: 16px;}
.form .hint { font-size: 12px; color: var(--ink3); margin-top: 4px; line-height: 1.5;}

/* 按钮 */
.btn-s, .btn-g, .btn-d {
    display: inline-flex; align-items: center; justify-content: center; gap: 6px;
    padding: 11px 22px; border-radius: 8px; font-size: 14px;
    cursor: pointer; transition: all .2s; font-weight: 500;
    border: 1px solid transparent;
}
.btn-s {
    background: linear-gradient(135deg, var(--primary), #e5485c);
    color: #fff; box-shadow: 0 4px 14px rgba(192, 5, 24, .25);
}
.btn-s:hover { transform: translateY(-1px); box-shadow: 0 6px 20px rgba(192,5,24,.35);}
.btn-g { background: #fff; color: var(--ink2); border-color: var(--border-strong);}
.btn-g:hover { border-color: var(--primary); color: var(--primary);}
.btn-d { background: #fee2e2; color: #dc2626; border-color: #fecaca;}
.btn-d:hover { background: #dc2626; color: #fff; border-color: #dc2626;}

/* 工具栏 */
.toolbar { display: flex; gap: 10px; align-items: center; margin-bottom: 16px; flex-wrap: wrap;}
.toolbar .right { margin-left: auto;}
.toolbar input, .toolbar select { padding: 8px 14px; border: 1.5px solid var(--border); border-radius: 8px;
    font-size: 13px; background: #fff; transition: all .2s;}
.toolbar input:focus, .toolbar select:focus {
    border-color: var(--primary); box-shadow: 0 0 0 3px rgba(192,5,24,.1);
    outline: none;
}

/* 提示框 */
.alert-ok { color: #16a34a; background: #dcfce7; padding: 10px 14px; border-radius: 8px;
    margin-bottom: 14px; font-size: 13px; display: flex; align-items: center; gap: 8px;}
.alert-err { color: #dc2626; background: #fee2e2; padding: 10px 14px; border-radius: 8px;
    margin-bottom: 14px; font-size: 13px; display: flex; align-items: center; gap: 8px;}

/* ──────────────────────────────────────────
   登录页 - 大logo + 渐变 + 玻璃态卡片
   ────────────────────────────────────────── */
.lp {
    min-height: 100vh; display: flex;
    background: #fff; overflow: hidden;
}
.lp-left {
    flex: 1.4; position: relative; overflow: hidden;
    background:
        radial-gradient(ellipse at 20% 50%, rgba(192,5,24,.4) 0%, transparent 50%),
        radial-gradient(ellipse at 80% 50%, rgba(126,34,206,.4) 0%, transparent 50%),
        linear-gradient(135deg, #0a0410 0%, #1a0832 50%, #4c0c40 100%);
    color: #fff;
    display: flex; align-items: center; justify-content: center;
}
.lp-left::before {
    content: ''; position: absolute; inset: 0; opacity: .08;
    background-image:
        linear-gradient(0deg, transparent 24%, rgba(255,255,255,.5) 25%, rgba(255,255,255,.5) 26%, transparent 27%, transparent 74%, rgba(255,255,255,.5) 75%, rgba(255,255,255,.5) 76%, transparent 77%, transparent),
        linear-gradient(90deg, transparent 24%, rgba(255,255,255,.5) 25%, rgba(255,255,255,.5) 26%, transparent 27%, transparent 74%, rgba(255,255,255,.5) 75%, rgba(255,255,255,.5) 76%, transparent 77%, transparent);
    background-size: 40px 40px;
}
.lp-left .orb {
    position: absolute; width: 600px; height: 600px;
    border-radius: 50%;
    background: radial-gradient(circle, rgba(255,255,255,.08), transparent 70%);
    top: -200px; left: -100px; animation: float 12s ease-in-out infinite;
}
.lp-left .orb2 {
    width: 400px; height: 400px;
    bottom: -100px; right: -100px;
    animation-delay: 4s;
    background: radial-gradient(circle, rgba(192,5,24,.18), transparent 70%);
}
@keyframes float { 0%,100% { transform: translate(0,0);} 50% { transform: translate(40px, -40px);}}

.lp-content {
    position: relative; z-index: 2; padding: 60px;
    max-width: 540px;
}
.lp-content .badge-new {
    display: inline-flex; align-items: center; gap: 6px;
    padding: 6px 14px; background: rgba(255,255,255,.08); backdrop-filter: blur(10px);
    border: 1px solid rgba(255,255,255,.15); border-radius: 30px;
    font-size: 12px; margin-bottom: 20px;
}
.lp-content .badge-new::before { content:''; width: 6px; height: 6px; border-radius: 50%; background: #0ac056;
    box-shadow: 0 0 8px #0ac056;}
.lp-content h1 {
    font-size: 44px; font-weight: 800; line-height: 1.2;
    margin-bottom: 18px; letter-spacing: -1px;
}
.lp-content h1 b { color: #ff7891;}
.lp-content .lpd { font-size: 16px; line-height: 1.7; opacity: .8; margin-bottom: 28px;
    max-width: 420px;}

.lp-features {
    display: grid; gap: 12px; margin-top: 36px;
}
.lp-feat {
    display: flex; align-items: center; gap: 12px;
    padding: 12px 18px;
    background: rgba(255,255,255,.06); backdrop-filter: blur(10px);
    border: 1px solid rgba(255,255,255,.1); border-radius: 10px;
}
.lp-feat i {
    width: 36px; height: 36px; border-radius: 8px;
    background: linear-gradient(135deg, var(--primary), var(--primary-light));
    display: flex; align-items: center; justify-content: center;
    color: #fff; font-size: 16px;
}
.lp-feat .ft { font-size: 13px; opacity: .9;}

.lp-right {
    flex: 1; padding: 40px;
    display: flex; align-items: center; justify-content: center;
    background: #f8f9fc;
}
.lp-card {
    background: #fff; border-radius: 18px; padding: 40px;
    width: 100%; max-width: 420px;
    box-shadow: 0 20px 60px rgba(15,23,42,.12);
}
.lp-card .lp-brand {
    display: flex; align-items: center; gap: 12px;
    margin-bottom: 28px;
}
.lp-card .lp-brand .ic {
    width: 48px; height: 48px; border-radius: 12px;
    background: linear-gradient(135deg, var(--primary), var(--primary-light));
    color: #fff; font-weight: 800; font-size: 24px;
    display: flex; align-items: center; justify-content: center;
    box-shadow: 0 8px 24px rgba(192,5,24,.3);
}
.lp-card .lp-brand h2 { font-size: 18px; color: var(--ink);}
.lp-card .lp-brand .sub { font-size: 12px; color: var(--ink3);}

.lp-card .row { margin-bottom: 18px;}
.lp-card label { display: block; font-size: 13px; color: var(--ink2); margin-bottom: 6px; font-weight: 500;}
.lp-card .input-wrap { position: relative;}
.lp-card .input-wrap .ico {
    position: absolute; left: 14px; top: 50%; transform: translateY(-50%);
    color: var(--ink3); font-size: 16px;
}
.lp-card .input-wrap input {
    width: 100%; padding: 13px 14px 13px 42px;
    border: 1.5px solid var(--border); border-radius: 10px;
    font-size: 14px; outline: 0; transition: all .2s; background: #fff;
}
.lp-card .input-wrap input:focus {
    border-color: var(--primary); box-shadow: 0 0 0 3px rgba(192,5,24,.1);
}
.lp-card .submit {
    display: block; width: 100%;
    padding: 14px;
    background: linear-gradient(135deg, var(--primary), var(--primary-light));
    color: #fff; border-radius: 10px; font-size: 15px; font-weight: 600;
    margin-top: 20px;
    box-shadow: 0 6px 20px rgba(192,5,24,.3); transition: all .25s;
    cursor: pointer; border: 0;
}
.lp-card .submit:hover { transform: translateY(-2px); box-shadow: 0 10px 28px rgba(192,5,24,.4);}
.lp-card .err { color: #dc2626; background: #fee2e2; padding: 11px 14px; border-radius: 8px;
    font-size: 13px; margin: 12px 0 16px; display: flex; align-items: center; gap: 8px;}
.lp-card .tip { color: var(--ink3); font-size: 12px; margin-top: 22px; text-align: center;}
.lp-card .tip b { color: var(--primary);}

.lp-stat-bar {
    position: absolute; left: 60px; bottom: 60px; z-index: 2;
    display: flex; gap: 30px;
}
.lp-stat .v { font-size: 28px; font-weight: 800;}
.lp-stat .l { font-size: 12px; opacity: .6; text-transform: uppercase; letter-spacing: 1px;}

/* ──────────────────────────────────────────
   响应式
   ────────────────────────────────────────── */
@media (max-width: 1024px) {
    .stats { grid-template-columns: repeat(2,1fr);}
    .form .row-grid, .form .row-grid-3 { grid-template-columns: 1fr;}
}
@media (max-width: 768px) {
    .sider { width: 64px;}
    .sider .nm, .sider li > a span { display: none;}
    .sider .ic { margin: 0;}
    .top h1 { font-size: 14px;}
    .content { padding: 16px;}
    .lp { flex-direction: column;}
    .lp-left { padding: 40px 24px;}
    .lp-left .lp-content { padding: 0;}
    .lp-content h1 { font-size: 32px;}
    .lp-content .lpd { font-size: 14px;}
    .lp-features { display: none;}
    .lp-stat-bar { position: static; padding: 30px 24px;}
    .lp-right { padding: 24px;}
    .lp-card { padding: 28px;}
    .stats { grid-template-columns: 1fr;}
}
