/* KotIDE 站点样式：白色主题、简约。全站共用（首页 + 后台）。 */

:root {
    --bg: #ffffff;
    --soft: #f7f8fa;
    --fg: #1a1d21;
    --fg-dim: #6b7280;
    --line: #e6e8eb;
    --accent: #1a73e8;
    --accent-weak: #eef4fe;
    --ok-bg: #eefaf1;
    --ok-line: #b7e6c6;
    --ok-fg: #146c34;
    --bad-bg: #fdeeee;
    --bad-line: #f2c3c3;
    --bad-fg: #a02323;
    --radius: 10px;
}

* { box-sizing: border-box; }

body {
    margin: 0;
    background: var(--bg);
    color: var(--fg);
    font: 15px/1.68 system-ui, -apple-system, "PingFang SC", "Microsoft YaHei", sans-serif;
    -webkit-text-size-adjust: 100%;
}

.wrap { max-width: 1000px; margin: 0 auto; padding: 0 18px; }

a { color: var(--accent); text-decoration: none; }
a:hover { text-decoration: underline; }

h1, h2, h3 { line-height: 1.35; }

/* ---------- 首页 ---------- */

.hero {
    background: var(--soft);
    border-bottom: 1px solid var(--line);
    padding: 48px 0 38px;
}

.brand { display: flex; align-items: center; gap: 10px; }

.logo {
    width: 30px; height: 30px; border-radius: 8px;
    background: var(--accent); color: #fff;
    display: inline-flex; align-items: center; justify-content: center;
    font-weight: 700; font-size: 15px;
}

.brand-name { font-weight: 600; letter-spacing: .3px; }

.hero h1 {
    font-size: 30px;
    margin: 22px 0 10px;
    letter-spacing: -.2px;
}

.intro { color: var(--fg-dim); margin: 0 0 24px; max-width: 640px; }

.cta { display: flex; align-items: center; gap: 14px; flex-wrap: wrap; }

.btn {
    display: inline-block;
    border-radius: var(--radius);
    padding: 11px 22px;
    font-size: 14.5px;
    font-weight: 600;
    border: 1px solid transparent;
    cursor: pointer;
    text-decoration: none;
}

.btn:hover { text-decoration: none; }

.btn.primary { background: var(--accent); color: #fff; }
.btn.primary:hover { background: #1666d0; }

.meta { color: var(--fg-dim); font-size: 13px; }

.changelog {
    margin-top: 24px;
    background: #fff;
    border: 1px solid var(--line);
    border-radius: var(--radius);
    padding: 16px 18px;
    max-width: 640px;
}

.changelog h3 { font-size: 14px; margin: 0 0 8px; color: var(--fg-dim); font-weight: 600; }
.changelog ul { margin: 0; padding-left: 18px; }
.changelog li { font-size: 14px; }

main.wrap { padding-bottom: 40px; }

.features {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(210px, 1fr));
    gap: 12px;
    margin: 34px 0;
}

.card {
    background: #fff;
    border: 1px solid var(--line);
    border-radius: var(--radius);
    padding: 16px 18px;
}

.card h3 { font-size: 14.5px; margin: 0 0 6px; }
.card p { margin: 0; color: var(--fg-dim); font-size: 13.5px; }

.panel { margin: 30px 0 0; }
.panel > h2 { font-size: 17px; margin: 0 0 14px; }

.empty { color: var(--fg-dim); font-size: 13.5px; }

.ann {
    border: 1px solid var(--line);
    border-radius: var(--radius);
    padding: 14px 16px;
    margin-bottom: 10px;
}

.ann h3 { font-size: 14.5px; margin: 0 0 4px; }
.ann time { color: var(--fg-dim); font-size: 12.5px; }
.ann p { margin: 8px 0 0; font-size: 13.5px; }

.tag {
    display: inline-block;
    background: var(--accent-weak);
    color: var(--accent);
    border-radius: 5px;
    font-size: 11.5px;
    padding: 1px 6px;
    margin-right: 6px;
    vertical-align: 1px;
}

.table {
    width: 100%;
    border-collapse: collapse;
    border: 1px solid var(--line);
    border-radius: var(--radius);
    overflow: hidden;
    font-size: 13.5px;
}

.table th, .table td {
    text-align: left;
    padding: 10px 12px;
    border-bottom: 1px solid var(--line);
    vertical-align: top;
}

.table th { background: var(--soft); font-weight: 600; color: var(--fg-dim); font-size: 12.5px; }
.table tr:last-child td { border-bottom: 0; }
.table td.cl { color: var(--fg-dim); }

.foot {
    border-top: 1px solid var(--line);
    padding: 20px 0 30px;
    color: var(--fg-dim);
    font-size: 13px;
}

.foot .wrap { display: flex; justify-content: space-between; gap: 12px; flex-wrap: wrap; }

/* ---------- 后台 ---------- */

.login { max-width: 360px; margin: 70px auto; }

.bar {
    display: flex; justify-content: space-between; align-items: center;
    gap: 12px; flex-wrap: wrap;
    border-bottom: 1px solid var(--line);
    padding: 16px 0;
}

.bar h1 { font-size: 16px; margin: 0; font-weight: 600; }
.bar .who { color: var(--fg-dim); font-size: 12.5px; }

.layout {
    display: grid;
    grid-template-columns: 178px 1fr;
    gap: 26px;
    align-items: start;
    padding: 22px 0 48px;
}

.side { position: sticky; top: 16px; }
.side .group { margin-bottom: 16px; }
.side .group > span {
    display: block;
    font-size: 11.5px;
    color: var(--fg-dim);
    letter-spacing: .5px;
    margin-bottom: 6px;
}
.side a {
    display: block;
    padding: 7px 10px;
    border-radius: 8px;
    color: var(--fg);
    font-size: 13.5px;
}
.side a:hover { background: var(--soft); text-decoration: none; }
.side a.active { background: var(--accent-weak); color: var(--accent); font-weight: 600; }

.pane > h2 { font-size: 16px; margin: 0 0 6px; }
.pane > .hint { color: var(--fg-dim); font-size: 13px; margin: 0 0 16px; }
.pane .sec { font-size: 14px; margin: 26px 0 10px; font-weight: 600; }

form.card { margin-bottom: 14px; }

label { display: block; font-size: 12.5px; color: var(--fg-dim); margin: 10px 0 4px; }

input[type=text], input[type=password], input[type=number], textarea, select {
    width: 100%;
    padding: 9px 10px;
    border-radius: 8px;
    font-size: 14px;
    font-family: inherit;
    color: var(--fg);
    background: #fff;
    border: 1px solid var(--line);
}

input:focus, textarea:focus, select:focus { outline: none; border-color: var(--accent); }

textarea { min-height: 88px; resize: vertical; }

.row { display: flex; gap: 12px; flex-wrap: wrap; }
.row > div { flex: 1 1 180px; }

.check {
    display: inline-flex; align-items: center; gap: 6px;
    font-size: 13px; color: var(--fg); margin: 10px 14px 0 0;
}
.check input { width: auto; }

button {
    border: 0; border-radius: 8px; padding: 10px 18px;
    font-size: 14px; font-family: inherit; cursor: pointer;
}

.btn-primary { background: var(--accent); color: #fff; font-weight: 600; }
.btn-ghost { background: var(--soft); color: var(--fg); border: 1px solid var(--line); }
.btn-danger { background: var(--bad-bg); color: var(--bad-fg); }

.actions { display: flex; gap: 8px; flex-wrap: wrap; margin-top: 14px; }
.inline { display: inline; }

.ok, .bad {
    border-radius: 8px;
    padding: 9px 12px;
    font-size: 13.5px;
    margin-bottom: 12px;
}
.ok { background: var(--ok-bg); border: 1px solid var(--ok-line); color: var(--ok-fg); }
.bad { background: var(--bad-bg); border: 1px solid var(--bad-line); color: var(--bad-fg); }

.mini { font-size: 12.5px; color: var(--fg-dim); }
.path { font-family: ui-monospace, Menlo, monospace; font-size: 12.5px; color: var(--fg-dim); }

.tbl-actions { display: flex; gap: 10px; align-items: center; }
.tbl-actions a, .tbl-actions button { font-size: 12.5px; }
.tbl-actions button { padding: 4px 10px; }

/* 用户管理 */
.tag.ok { background: var(--ok-bg); color: var(--ok-fg); border: 1px solid var(--ok-line); }
.tag.bad { background: var(--bad-bg); color: var(--bad-fg); border: 1px solid var(--bad-line); }
.mini-btn { font-size: 12.5px !important; padding: 4px 10px !important; margin-right: 6px; }

/* 文件树 */
.tree { border: 1px solid var(--line); border-radius: var(--radius); padding: 12px 14px; }
.tree .node { font-size: 13.5px; padding: 5px 0; display: flex; gap: 8px; align-items: baseline; flex-wrap: wrap; }
.tree .node .name { font-family: ui-monospace, Menlo, monospace; word-break: break-all; }
.tree .node .size { color: var(--fg-dim); font-size: 12px; }
.tree .br { color: var(--fg-dim); }
.tree .cat { font-size: 12.5px; color: var(--fg-dim); margin: 12px 0 4px; }
.tree .cat:first-child { margin-top: 0; }
.tree .node .mini { flex: 1 1 140px; }
.tree .node-actions { display: flex; align-items: center; gap: 8px; margin-left: auto; }
.chip {
    display: inline-block;
    background: var(--soft);
    border: 1px solid var(--line);
    border-radius: 6px;
    padding: 3px 10px;
    font-size: 12.5px;
    color: var(--fg);
}
.chip:hover { text-decoration: none; border-color: var(--accent); color: var(--accent); }

/* 文件页分类抽屉（点三条线弹出） */
.ftree { position: relative; margin: 0 0 6px; }
.ftree-toggle {
    display: flex; align-items: center; gap: 10px;
    width: 100%;
    background: var(--soft);
    border: 1px solid var(--line);
    border-radius: var(--radius);
    padding: 11px 14px;
    font-size: 13.5px;
    color: var(--fg);
    text-align: left;
}
.ftree-toggle:hover { border-color: var(--accent); }
.ftree-bars { display: inline-flex; flex-direction: column; gap: 3px; flex: 0 0 auto; }
.ftree-bars i { display: block; width: 16px; height: 2px; background: var(--fg); border-radius: 2px; }
.ftree-name { font-weight: 600; }
.ftree-sum { margin-left: auto; font-size: 12px; color: var(--fg-dim); }
.ftree-menu {
    position: absolute;
    z-index: 20;
    top: calc(100% + 6px);
    left: 0;
    right: 0;
    background: #fff;
    border: 1px solid var(--line);
    border-radius: var(--radius);
    box-shadow: 0 8px 24px rgba(20, 30, 50, .12);
    padding: 6px;
    max-height: 60vh;
    overflow-y: auto;
}
.ftree-menu a {
    display: flex; align-items: center; justify-content: space-between; gap: 10px;
    padding: 11px 12px;
    border-radius: 8px;
    color: var(--fg);
    font-size: 13.5px;
}
.ftree-menu a:hover { background: var(--soft); text-decoration: none; }
.ftree-menu a.active { background: var(--accent-weak); color: var(--accent); font-weight: 600; }

@media (max-width: 720px) {
    .wrap { padding: 0 14px; }
    .layout { grid-template-columns: 1fr; gap: 6px; padding: 16px 0 40px; }
    .side { position: static; }
    .side .group { display: flex; flex-wrap: nowrap; gap: 6px; align-items: center; overflow-x: auto; padding-bottom: 4px; }
    .side .group > span { display: none; }
    .side a {
        flex: 0 0 auto;
        padding: 8px 14px;
        border: 1px solid var(--line);
        border-radius: 999px;
        font-size: 13px;
        white-space: nowrap;
    }
    .side a.active { border-color: var(--accent); }

    .bar { padding: 12px 0; }
    .bar h1 { font-size: 15px; }
    .login { margin: 40px auto; }
    .pane .sec { margin: 20px 0 8px; }
    form.card, .card { padding: 14px 14px; }

    /* 手机上输入框 >=16px，避免 iOS 自动放大 */
    input[type=text], input[type=password], input[type=number], textarea, select { font-size: 16px; }
    button, .btn, .btn-primary, .btn-ghost, .btn-danger { min-height: 42px; }
    .tbl-actions button, .chip, .tree .node-actions button { min-height: 34px; }

    /* 表格在手机上改为卡片式，每格带字段名 */
    .table { border: 0; font-size: 13.5px; }
    .table thead { display: none; }
    .table, .table tbody, .table tr, .table td { display: block; width: 100%; }
    .table tr {
        border: 1px solid var(--line);
        border-radius: var(--radius);
        margin-bottom: 10px;
        padding: 8px 12px;
    }
    .table td { border: 0; padding: 3px 0; display: flex; gap: 10px; align-items: center; }
    .table td::before {
        content: attr(data-label);
        color: var(--fg-dim);
        font-size: 12px;
        flex: 0 0 68px;
    }
    .table td:not([data-label])::before { content: none; }
    .table tr:last-child td { border-bottom: 0; }
    .tbl-actions { flex-wrap: wrap; gap: 8px; margin-top: 6px; }
    .tbl-actions::before { content: none; }

    .tree { padding: 10px 12px; }
    .tree .node { padding: 8px 0; border-bottom: 1px solid var(--line); }
    .tree .node:last-child { border-bottom: 0; }
    .tree .node-actions { margin-left: 0; width: 100%; }
    .ftree-menu { max-height: 70vh; }
    .ftree-sum { display: none; }

    .hero { padding: 32px 0 26px; }
    .hero h1 { font-size: 24px; }
}

/* ---------- 首页顶栏 / 公告入口 ---------- */

.topnav {
    display: flex; align-items: center; justify-content: space-between; gap: 12px;
}

.nav-icon {
    position: relative;
    display: inline-flex; align-items: center; justify-content: center;
    width: 38px; height: 38px;
    border-radius: 50%;
    color: var(--fg);
    background: #fff;
    border: 1px solid var(--line);
}
.nav-icon:hover { color: var(--accent); border-color: var(--accent); text-decoration: none; }
.nav-icon .dot {
    position: absolute; top: 6px; right: 7px;
    width: 7px; height: 7px; border-radius: 50%;
    background: var(--accent);
}

.release-line {
    margin: 18px 0 0;
    color: var(--fg-dim);
    font-size: 13px;
}

.release-card {
    display: flex; align-items: center; justify-content: space-between; gap: 14px;
}
.release-main { display: flex; align-items: baseline; gap: 10px; flex-wrap: wrap; }
.release-main b { font-size: 15px; }

/* ---------- 公告页 ---------- */

.subbar { border-bottom: 1px solid var(--line); background: #fff; }
.subbar .wrap { display: flex; align-items: center; gap: 12px; padding-top: 14px; padding-bottom: 14px; }
.subbar-title { font-weight: 600; font-size: 15px; }
.subbar .back { font-size: 13.5px; }

.ann-list { margin: 18px 0 0; display: grid; gap: 8px; }

.ann-item {
    display: flex; align-items: center; gap: 10px;
    width: 100%;
    background: #fff;
    border: 1px solid var(--line);
    border-radius: var(--radius);
    padding: 13px 14px;
    font-size: 14px;
    color: var(--fg);
    text-align: left;
}
.ann-item:hover { border-color: var(--accent); }
.ann-item .ann-title { font-weight: 600; }
.ann-item .ann-sub { margin-left: auto; color: var(--fg-dim); font-size: 12.5px; }

.chev {
    display: inline-block;
    width: 7px; height: 7px;
    border-right: 1.6px solid #b9c0ca;
    border-bottom: 1.6px solid #b9c0ca;
    transform: rotate(-45deg);
    flex: 0 0 auto;
}

.sheet { position: fixed; inset: 0; z-index: 60; display: flex; align-items: flex-end; justify-content: center; }
.sheet-mask { position: absolute; inset: 0; background: rgba(16, 22, 32, .38); }
.sheet-body {
    position: relative;
    width: min(560px, 100%);
    max-height: 82vh;
    overflow-y: auto;
    background: #fff;
    border-radius: 14px 14px 0 0;
    padding: 20px 18px 22px;
    box-shadow: 0 -8px 30px rgba(20, 30, 50, .18);
}
.sheet-body h3 { font-size: 16px; margin: 0 0 6px; }
.sheet-time { color: var(--fg-dim); font-size: 12.5px; }
.sheet-text { margin-top: 12px; font-size: 14px; line-height: 1.75; word-break: break-word; }

/* ---------- 后台导航：列表 + 点击进页 ---------- */

.admin .bar-title { display: flex; align-items: baseline; gap: 10px; }
.admin .bar-actions { display: flex; align-items: center; gap: 8px; }
.admin .icon-link {
    display: inline-flex; align-items: center;
    border: 1px solid var(--line);
    border-radius: 999px;
    padding: 6px 14px;
    font-size: 13px;
    color: var(--fg);
}
.admin .icon-link:hover { border-color: var(--accent); color: var(--accent); text-decoration: none; }

.admin .side-head { display: none; }
.admin .side a {
    display: flex; align-items: center; justify-content: space-between; gap: 10px;
}
.admin .side a .chev { display: none; }
.admin .back { display: none; }

@media (max-width: 720px) {
    .admin .layout { gap: 0; padding: 14px 0 40px; }
    .admin.view-nav .pane { display: none; }
    .admin.view-pane .side { display: none; }

    .admin .side-head {
        display: block;
        font-size: 13px;
        font-weight: 600;
        margin: 0 0 10px;
    }
    .admin .side .group {
        display: block;
        flex-wrap: nowrap;
        overflow: visible;
        padding-bottom: 0;
        margin-bottom: 16px;
    }
    .admin .side .group > span {
        display: block;
        margin: 0 0 6px 2px;
    }
    .admin .side a {
        border: 1px solid var(--line);
        border-radius: 10px;
        padding: 12px 13px;
        font-size: 14px;
        white-space: normal;
        margin-bottom: 8px;
    }
    .admin .side a .chev { display: inline-block; }
    .admin .side a.active { border-color: var(--accent); }

    .admin .back {
        display: inline-block;
        font-size: 13.5px;
        margin: 0 0 14px;
    }
    .admin .bar-actions .icon-link { padding: 5px 12px; }
    .admin .pane > h2 { font-size: 17px; }
}


/* ---------- 更新日志时间线（后台编辑样式与客户端时间线一致） ---------- */

.tl { margin: 6px 0 4px; }
.tl-node, .tl-item { position: relative; padding: 6px 0 6px 24px; }
.tl-node { padding-top: 12px; }
.tl-node::before, .tl-item::before {
    content: "";
    position: absolute;
    left: 5px;
    top: 0;
    bottom: 0;
    width: 2px;
    background: var(--line);
}
.tl > :last-child::before { display: none; }
.tl-dot {
    position: absolute;
    left: 1px;
    top: 11px;
    width: 10px;
    height: 10px;
    border-radius: 50%;
    background: #cbd0d6;
}
.tl-dot-node { left: 0; top: 16px; width: 12px; height: 12px; background: var(--accent); }
.tl-node-body { display: flex; align-items: center; gap: 8px; flex-wrap: wrap; }
.tl-ver { font-weight: 600; font-size: 14.5px; }
.tl-line { display: flex; align-items: flex-start; gap: 6px; }
.tl-text { flex: 1 1 auto; font-size: 13.5px; }
.tl-tag {
    flex: 0 0 auto;
    border-radius: 5px;
    font-size: 11.5px;
    padding: 1px 6px;
    background: var(--accent-weak);
    color: var(--accent);
}
.tl-tag.cat-opt { background: #fdf3e2; color: #8a5d0c; }
.tl-tag.cat-fix { background: var(--bad-bg); color: var(--bad-fg); }
.tag-draft { background: var(--soft); color: var(--fg-dim); }
.tl-meta { font-size: 12px; color: var(--fg-dim); margin-top: 2px; }
.tl-ops { margin-top: 3px; font-size: 12.5px; }
.tl-ops .inline { margin-right: 8px; }
.tl-preview { background: var(--soft); border: 1px solid var(--line); border-radius: var(--radius); padding: 10px 14px; }


/* ============================================================
   手机端统一适配（权威块：置于文件末尾，覆盖前文同名规则）
   要点：消除横向溢出 / 导航两列紧凑 / 概览首屏可见 /
        表格卡片化不裁切 / 触摸目标 >= 44px / 长列表折叠
   ============================================================ */
@media (max-width: 720px) {
    .wrap { padding: 0 12px; }

    /* ---- 布局：消除 grid 子项 min-content 撑破 ---- */
    .layout { grid-template-columns: minmax(0, 1fr); gap: 0; padding: 14px 0 40px; }
    .layout > *, .pane { min-width: 0; max-width: 100%; }
    .side { position: static; }

    /* ---- 导航：两列紧凑卡片，首屏即可看全 ---- */
    .admin .side-head { display: block; font-size: 13px; font-weight: 600; margin: 0 0 8px; }
    .admin .side .group {
        display: grid; grid-template-columns: 1fr 1fr; gap: 8px;
        overflow: visible; padding-bottom: 0; margin-bottom: 14px;
    }
    .admin .side .group > span { display: block; grid-column: 1 / -1; margin: 0 0 2px 2px; }
    .admin .side a {
        margin: 0; min-height: 48px; padding: 10px 12px;
        border: 1px solid var(--line); border-radius: 10px;
        font-size: 14px; white-space: normal;
    }
    .admin .side a .chev { display: none; }
    .admin .side a.active { border-color: var(--accent); background: var(--accent-weak); }

    /* ---- 首屏同时展示概览（无 p 参数时），避免空屏 ---- */
    .admin.view-nav .pane { display: block; }
    .admin.view-nav .back { display: none; }
    .admin.view-pane .side { display: none; }
    .admin.view-pane .pane > h2 { margin-top: 2px; }

    /* ---- 表格卡片化：修复裁切、长串断行 ---- */
    .table { border: 0; overflow: visible; font-size: 14px; }
    .table tr { padding: 10px 12px; margin-bottom: 10px; }
    .table td { display: flex; align-items: flex-start; gap: 8px; padding: 4px 0; border: 0; }
    .table td::before {
        flex: 0 0 auto; min-width: 58px; max-width: 96px;
        font-size: 12.5px; line-height: 1.6; padding-top: 1px;
    }
    .table td, .table td * { min-width: 0; overflow-wrap: anywhere; word-break: break-word; }
    .table .mini { line-height: 1.55; }

    /* ---- 触摸目标：统一放大到 44px 左右 ---- */
    button, .btn, .btn-primary, .btn-ghost, .btn-danger { min-height: 44px; padding: 10px 16px; font-size: 14px; }
    .tbl-actions { flex-wrap: wrap; gap: 10px; margin-top: 8px; }
    .tbl-actions a, .tbl-actions button,
    .tree .node-actions a, .tree .node-actions button, .chip {
        display: inline-flex; align-items: center; min-height: 40px;
        padding: 8px 14px; font-size: 13px;
    }
    .tbl-actions a { border: 1px solid var(--line); border-radius: 8px; }
    .check { min-height: 44px; margin: 4px 12px 0 0; padding: 6px 0; font-size: 13.5px; }
    .check input, input[type=checkbox], input[type=radio] { width: 20px; height: 20px; flex: 0 0 auto; }

    /* ---- 表单：控件整宽、按钮与输入框同宽 ---- */
    label { font-size: 13px; margin: 12px 0 6px; }
    .row { gap: 10px; }
    .row > div { flex: 1 1 100%; }
    input[type=file] {
        width: 100%; padding: 12px 10px; font-size: 13.5px;
        border: 1px dashed #c9cfd6; border-radius: 8px; background: var(--soft);
    }
    .actions { gap: 10px; margin-top: 12px; }
    .actions > button, .actions > .btn { flex: 1 1 140px; }
    .actions > a.btn-ghost { text-align: center; }

    /* ---- 长列表折叠 ---- */
    .fold tbody > tr:nth-child(n+16) { display: none; }
    .fold.open tbody > tr:nth-child(n+16) { display: block; }
    .fold-bar { margin: -2px 0 18px; }
    .fold-bar button { width: 100%; }
    .fold-bar .less { display: none; }
    .fold-bar.open .more { display: none; }
    .fold-bar.open .less { display: inline; }

    /* ---- 文件树与页脚 ---- */
    .tree { padding: 10px 12px; }
    .tree .node { padding: 10px 0; }
    .tree .node .mini { flex: 1 1 100%; }
    .tree .node-actions { margin-left: 0; width: 100%; margin-top: 6px; }
    .foot .wrap { flex-direction: column; gap: 6px; }
}

@media (min-width: 721px) {
    .fold-bar { display: none; }
}

/* 手机端补充：把剩余偏小的可点目标补齐到 >= 40px */
@media (max-width: 720px) {
    input[type=text], input[type=password], input[type=number], select, textarea { min-height: 44px; }
    .admin .icon-link { min-height: 40px; padding: 9px 16px; font-size: 13.5px; }
    .admin .back { display: inline-flex; align-items: center; min-height: 40px; margin: 0 0 12px; }
    .table td > a { display: inline-flex; align-items: center; min-height: 36px; }
    .check { padding-left: 2px; }
}

/* ============================================================
   全站推拉抽屉导航（首页 + 后台）
   汉堡按钮在左上角，抽屉从左侧滑入，主页面右移并缩小；
   点击主页面任意位置或按 Esc 复原。
   ============================================================ */
:root { --drawer-w: 288px; }

html { scroll-behavior: smooth; }

body.drawer-open { overflow: hidden; }

.page-shell {
    position: relative;
    z-index: 1;
    min-height: 100vh;
    background: var(--bg);
    transform-origin: left center;
    transition: transform .34s cubic-bezier(.22, .61, .36, 1),
                border-radius .34s cubic-bezier(.22, .61, .36, 1),
                box-shadow .34s cubic-bezier(.22, .61, .36, 1);
    will-change: transform;
}

body.drawer-open .page-shell {
    transform: translateX(min(var(--drawer-w), 84vw)) scale(.94);
    border-radius: 20px;
    box-shadow: 18px 0 50px rgba(15, 23, 42, .18);
    overflow: hidden;
}

.push-drawer {
    position: fixed;
    top: 0;
    left: 0;
    bottom: 0;
    z-index: 2;
    display: flex;
    flex-direction: column;
    gap: 18px;
    width: min(var(--drawer-w), 84vw);
    padding: 22px 18px 20px;
    overflow-y: auto;
    background: linear-gradient(180deg, #f5f9ff 0%, #ffffff 42%);
    border-right: 1px solid var(--line);
    transform: translateX(-102%);
    transition: transform .34s cubic-bezier(.22, .61, .36, 1);
    box-shadow: 0 0 0 rgba(15, 23, 42, 0);
}

body.drawer-open .push-drawer {
    transform: none;
    box-shadow: 12px 0 40px rgba(15, 23, 42, .12);
}

.push-drawer__head {
    display: flex;
    align-items: center;
    gap: 10px;
    padding-bottom: 14px;
    border-bottom: 1px solid var(--line);
}

.push-drawer__brand {
    display: flex;
    flex-direction: column;
    gap: 2px;
    min-width: 0;
}

.push-drawer__brand b { font-size: 15px; letter-spacing: .2px; }
.push-drawer__brand span { font-size: 12px; color: var(--fg-dim); }

.push-drawer__close {
    margin-left: auto;
    flex: 0 0 auto;
    width: 36px;
    height: 36px;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    border: 1px solid var(--line);
    border-radius: 50%;
    background: #fff;
    color: var(--fg);
    font-size: 20px;
    line-height: 1;
    cursor: pointer;
}
.push-drawer__close:hover { border-color: var(--accent); color: var(--accent); }

.push-drawer__nav { display: flex; flex-direction: column; gap: 4px; }

.push-drawer__nav a {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 10px;
    padding: 11px 12px;
    border-radius: 10px;
    color: var(--fg);
    font-size: 14px;
    font-weight: 500;
}
.push-drawer__nav a:hover,
.push-drawer__nav a.active {
    background: var(--accent-weak);
    color: var(--accent);
    text-decoration: none;
}
.push-drawer__nav a .chev { display: inline-block; }

.push-drawer__foot {
    margin-top: auto;
    padding-top: 14px;
    border-top: 1px solid var(--line);
    color: var(--fg-dim);
    font-size: 12px;
    line-height: 1.7;
}

.nav-toggle {
    flex: 0 0 auto;
    width: 40px;
    height: 40px;
    display: inline-flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    gap: 4px;
    padding: 0;
    border: 1px solid var(--line);
    border-radius: 12px;
    background: #fff;
    color: var(--fg);
    cursor: pointer;
    transition: border-color .2s, background .2s;
}
.nav-toggle:hover { border-color: var(--accent); background: var(--accent-weak); }
.nav-toggle span {
    display: block;
    width: 17px;
    height: 2px;
    border-radius: 2px;
    background: currentColor;
    transition: transform .26s ease, opacity .2s ease;
}
body.drawer-open .nav-toggle span:nth-child(1) { transform: translateY(6px) rotate(45deg); }
body.drawer-open .nav-toggle span:nth-child(2) { opacity: 0; }
body.drawer-open .nav-toggle span:nth-child(3) { transform: translateY(-6px) rotate(-45deg); }

.topnav-left { display: flex; align-items: center; gap: 12px; min-width: 0; }

/* 后台：导航全部收进抽屉，内容区单列 */
.admin .layout { grid-template-columns: minmax(0, 1fr); }
.admin .bar-title { display: flex; align-items: center; gap: 12px; }
.admin-drawer.side {
    display: flex;
    position: fixed;
    top: 0;
    left: 0;
    bottom: 0;
    width: min(var(--drawer-w), 84vw);
    padding: 22px 18px 20px;
    background: linear-gradient(180deg, #f5f9ff 0%, #ffffff 42%);
    border-right: 1px solid var(--line);
    overflow-y: auto;
}
.admin-drawer .side-head { display: none; }
.admin-drawer .group { margin-bottom: 16px; }
.admin-drawer .group > span {
    display: block;
    font-size: 11.5px;
    color: var(--fg-dim);
    letter-spacing: .5px;
    margin: 0 0 6px 2px;
}
.admin-drawer a {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 10px;
    padding: 11px 12px;
    border-radius: 10px;
    color: var(--fg);
    font-size: 13.5px;
}
.admin-drawer a:hover,
.admin-drawer a.active {
    background: var(--accent-weak);
    color: var(--accent);
    text-decoration: none;
}
.admin-drawer a .chev { display: inline-block; }

@media (max-width: 720px) {
    .push-drawer { padding: 18px 16px; }
    .admin .bar-title { gap: 10px; }
    .admin .bar h1 { font-size: 15px; }
    .hero .topnav { align-items: center; }
}

/* 首页细节优化 */
.hero-eyebrow {
    display: inline-block;
    margin: 24px 0 0;
    color: var(--accent);
    font-size: 12px;
    font-weight: 600;
    letter-spacing: .8px;
    text-transform: uppercase;
}
.hero-eyebrow + h1 { margin-top: 8px; }
.btn.ghost {
    background: #fff;
    color: var(--fg);
    border-color: var(--line);
}
.btn.ghost:hover { border-color: var(--accent); color: var(--accent); }
.section-head { margin: 34px 0 0; }
.section-head h2 { font-size: 18px; margin: 0 0 4px; }
.section-head p { margin: 0; color: var(--fg-dim); font-size: 13.5px; }
.section-head + .features { margin-top: 16px; }
.features .card { transition: border-color .2s ease, transform .2s ease; }
.features .card:hover { border-color: var(--accent); transform: translateY(-2px); }
@media (max-width: 720px) {
    .hero { padding: 24px 0 26px; }
    .hero-eyebrow { margin-top: 20px; }
    .cta .btn { flex: 1 1 100%; text-align: center; }
    .cta .meta { flex: 1 1 100%; }
}

/* 抽屉复用 .side 类，避免后台移动端 view-pane 规则把抽屉一起隐藏 */
body.admin .push-drawer.side { display: flex; }

@media (max-width: 720px) {
    body.admin .admin-drawer .group {
        display: block;
        gap: 0;
        margin-bottom: 16px;
    }
    body.admin .admin-drawer .group > span {
        display: block;
        grid-column: auto;
        margin: 0 0 6px 2px;
    }
    body.admin .admin-drawer a {
        min-height: 42px;
        margin-bottom: 4px;
        padding: 10px 12px;
        border: 0;
        border-radius: 10px;
        font-size: 13.5px;
    }
    body.admin .admin-drawer a .chev { display: inline-block; }
    body.admin .admin-drawer a.active {
        border: 0;
        background: var(--accent-weak);
    }
}

/* ============================================================
   首页视觉升级：插画、图标、动效
   ============================================================ */

.home .hero {
    position: relative;
    overflow: hidden;
    padding: 26px 0 54px;
    background:
        radial-gradient(900px 520px at 88% -10%, #e8f1ff 0%, rgba(232, 241, 255, 0) 68%),
        linear-gradient(180deg, #f8fbff 0%, #f7f8fa 100%);
}

.hero-glow {
    position: absolute;
    inset: 0;
    pointer-events: none;
    background:
        radial-gradient(420px 320px at 80% 30%, rgba(26, 115, 232, .14), transparent 70%),
        radial-gradient(360px 260px at 8% 78%, rgba(76, 155, 255, .10), transparent 70%);
}

.hero-grid {
    position: relative;
    display: grid;
    grid-template-columns: minmax(0, 1.05fr) minmax(320px, .95fr);
    gap: 30px;
    align-items: center;
    margin-top: 22px;
}

.hero-copy { min-width: 0; }

.home .hero h1 {
    font-size: clamp(30px, 3.7vw, 47px);
    line-height: 1.18;
    letter-spacing: -.8px;
    margin: 20px 0 14px;
    max-width: 12em;
}

.home .hero .intro { font-size: 15px; line-height: 1.8; max-width: 560px; margin-bottom: 26px; }
.hero-eyebrow { display: inline-flex; align-items: center; gap: 8px; margin-top: 24px; }
.pulse-dot {
    width: 8px; height: 8px; border-radius: 50%;
    background: #37b24d;
    box-shadow: 0 0 0 4px rgba(55, 178, 77, .14);
    animation: pulseDot 2.2s ease-in-out infinite;
}
.cta .btn { display: inline-flex; align-items: center; justify-content: center; gap: 8px; }
.cta .btn.primary { box-shadow: 0 10px 24px rgba(26, 115, 232, .22); }
.cta .btn.primary:hover { transform: translateY(-1px); }
.cta .btn { transition: transform .2s ease, box-shadow .2s ease, background .2s ease; }

.trust-row {
    display: flex; align-items: center; flex-wrap: wrap; gap: 8px 18px;
    margin-top: 22px; color: var(--fg-dim); font-size: 12.5px;
}
.trust-row span { display: inline-flex; align-items: center; gap: 6px; }
.trust-row svg { width: 16px; height: 16px; padding: 2px; border-radius: 50%; background: #e9f7ee; color: #2f9e44; stroke-width: 2.2; }

.hero-art { position: relative; min-height: 430px; display: flex; align-items: center; justify-content: center; }
.art-orb { position: absolute; border-radius: 50%; filter: blur(2px); pointer-events: none; }
.orb-a { width: 260px; height: 260px; right: 8%; top: 6%; background: radial-gradient(circle at 35% 35%, rgba(106, 168, 255, .35), rgba(106, 168, 255, 0) 70%); animation: orbFloat 9s ease-in-out infinite; }
.orb-b { width: 210px; height: 210px; left: 0; bottom: 2%; background: radial-gradient(circle at 60% 40%, rgba(126, 217, 177, .28), rgba(126, 217, 177, 0) 70%); animation: orbFloat 11s ease-in-out infinite reverse; }

.phone-card {
    position: relative;
    width: min(310px, 82%);
    border-radius: 26px;
    background: #0f172a;
    padding: 10px;
    box-shadow: 0 30px 70px rgba(20, 40, 80, .28), 0 8px 24px rgba(20, 40, 80, .14);
    transform: rotate(-2.5deg);
    animation: phoneFloat 7s ease-in-out infinite;
}
.phone-bar {
    display: flex; align-items: center; gap: 8px;
    padding: 8px 8px 10px;
    color: #94a3b8; font-size: 11px;
}
.phone-dots { display: inline-flex; gap: 4px; }
.phone-dots i { width: 6px; height: 6px; border-radius: 50%; background: #475569; }
.phone-dots i:first-child { background: #f87171; }
.phone-dots i:nth-child(2) { background: #fbbf24; }
.phone-dots i:nth-child(3) { background: #34d399; }
.phone-file { margin-left: auto; background: #1e293b; border-radius: 6px; padding: 3px 8px; color: #cbd5e1; }

.phone-code {
    background: #111c33;
    border-radius: 16px;
    padding: 16px 16px 20px;
    min-height: 260px;
    font-family: ui-monospace, SFMono-Regular, Menlo, Consolas, monospace;
    font-size: 11.2px;
    line-height: 1.85;
    color: #d6e2f5;
    overflow: hidden;
}
.phone-code > div { white-space: nowrap; }
.phone-code .c-kw { color: #c792ea; }
.phone-code .c-type { color: #82aaff; }
.phone-code .c-fn { color: #7fdbca; }
.phone-code .c-cursor { width: 2px; height: 14px; background: #7fdbca; margin-top: 2px; animation: cursorBlink 1s steps(1) infinite; }
.phone-run {
    display: flex; align-items: center; gap: 8px;
    margin: 8px 2px 2px;
    color: #a7f3d0; font-size: 11.5px;
}
.phone-run span { width: 8px; height: 8px; border-radius: 50%; background: #34d399; box-shadow: 0 0 0 4px rgba(52, 211, 153, .16); }

.float-chip {
    position: absolute;
    display: inline-flex; align-items: center; gap: 7px;
    background: rgba(255, 255, 255, .92);
    border: 1px solid rgba(255, 255, 255, .9);
    box-shadow: 0 12px 30px rgba(30, 60, 110, .14);
    border-radius: 999px;
    padding: 8px 13px 8px 8px;
    font-size: 12px; font-weight: 600; color: #24324a;
    backdrop-filter: blur(8px);
}
.chip-ic { display: inline-flex; align-items: center; justify-content: center; min-width: 26px; height: 26px; padding: 0 6px; border-radius: 999px; background: #eaf2ff; color: var(--accent); font-size: 10.5px; }
.chip-a { top: 10%; left: -1%; animation: chipFloat 5.5s ease-in-out infinite; }
.chip-b { top: 34%; right: -2%; animation: chipFloat 6.5s ease-in-out infinite .4s; }
.chip-c { bottom: 8%; left: 2%; animation: chipFloat 6s ease-in-out infinite .8s; }

.feature-card { padding: 20px 20px 22px; }
.feature-icon {
    display: inline-flex; align-items: center; justify-content: center;
    width: 42px; height: 42px; border-radius: 13px;
    margin-bottom: 14px;
    background: #eaf2ff; color: var(--accent);
}
.feature-icon svg { width: 22px; height: 22px; }
.feature-icon.variant-1 { background: #ecfdf3; color: #2f9e44; }
.feature-icon.variant-2 { background: #fff4e6; color: #d97706; }
.feature-icon.variant-3 { background: #f3e8ff; color: #7c3aed; }
.feature-icon.variant-4 { background: #e6f7f9; color: #0e7490; }
.feature-icon.variant-5 { background: #fef2f2; color: #dc2626; }
.feature-card h3 { font-size: 15px; margin-bottom: 8px; }

.how { margin-top: 44px; }
.steps { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 14px; margin-top: 16px; }
.step {
    position: relative; overflow: hidden;
    background: #fff; border: 1px solid var(--line); border-radius: 16px;
    padding: 22px 20px;
    transition: border-color .2s ease, transform .2s ease, box-shadow .2s ease;
}
.step:hover { border-color: #b9d4fb; transform: translateY(-2px); box-shadow: 0 14px 34px rgba(30, 70, 130, .08); }
.step-no { position: absolute; right: 16px; top: 12px; font-size: 34px; font-weight: 700; color: #eef2f8; letter-spacing: -1px; }
.step-icon { display: inline-flex; width: 40px; height: 40px; align-items: center; justify-content: center; border-radius: 12px; background: #f2f7ff; color: var(--accent); margin-bottom: 12px; }
.step-icon svg { width: 21px; height: 21px; }
.step h3 { font-size: 15px; margin: 0 0 7px; }
.step p { margin: 0; color: var(--fg-dim); font-size: 13px; line-height: 1.7; }

.latest-panel { margin-top: 44px; }
.latest-panel .section-head { margin-top: 0; }
.release-card { padding: 20px 22px; gap: 18px; }
.release-badge { display: inline-flex; align-items: center; gap: 9px; flex: 0 0 auto; }
.release-badge-k { width: 42px; height: 42px; border-radius: 13px; display: inline-flex; align-items: center; justify-content: center; background: linear-gradient(135deg, #4c9bff, #1a73e8); color: #fff; font-weight: 700; }
.release-badge-t { font-weight: 600; font-size: 14px; }
.release-main { flex: 1 1 auto; flex-direction: column; align-items: flex-start; gap: 2px; }
.release-main b { font-size: 16px; }
.release-note { color: var(--fg-dim); font-size: 12.5px; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; max-width: 100%; }
.latest-panel .release-badge-t { display: none; }

.reveal { opacity: 0; transform: translateY(14px); transition: opacity .6s ease, transform .6s cubic-bezier(.22,.61,.36,1); }
.reveal.is-visible { opacity: 1; transform: none; }
.hero-art.reveal { transform: translateY(18px) scale(.97); }
.hero-art.reveal.is-visible { transform: none; }

@keyframes phoneFloat { 0%, 100% { transform: rotate(-2.5deg) translateY(0); } 50% { transform: rotate(-1.4deg) translateY(-10px); } }
@keyframes chipFloat { 0%, 100% { transform: translateY(0); } 50% { transform: translateY(-8px); } }
@keyframes orbFloat { 0%, 100% { transform: translate3d(0, 0, 0) scale(1); } 50% { transform: translate3d(10px, -12px, 0) scale(1.05); } }
@keyframes pulseDot { 0%, 100% { box-shadow: 0 0 0 4px rgba(55,178,77,.14); } 50% { box-shadow: 0 0 0 7px rgba(55,178,77,.06); } }
@keyframes cursorBlink { 50% { opacity: 0; } }

.foot-links { display: inline-flex; gap: 16px; }

/* ============================================================
   公告页：修复弹层 hidden 失效，关闭更顺手
   ============================================================ */

.sheet[hidden] { display: none !important; }
body.sheet-open { overflow: hidden; }
.ann-page { padding-top: 20px; padding-bottom: 54px; }
.subbar-count { margin-left: auto; color: var(--fg-dim); font-size: 12.5px; }
.ann-item {
    align-items: center;
    gap: 14px;
    padding: 15px 18px;
    cursor: pointer;
    transition: border-color .2s ease, transform .2s ease, box-shadow .2s ease;
}
.ann-item:hover { transform: translateY(-1px); box-shadow: 0 10px 24px rgba(30, 70, 130, .06); }
.ann-item-main { display: flex; flex-direction: column; gap: 3px; min-width: 0; max-width: 44%; }
.ann-item .ann-sub { margin-left: 0; }
.ann-preview { flex: 1 1 auto; min-width: 0; color: var(--fg-dim); font-size: 12.8px; text-align: left; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.ann-item .chev { margin-left: 2px; }

.sheet { align-items: center; padding: 22px; }
.sheet-mask { backdrop-filter: blur(3px); }
.sheet-body {
    width: min(620px, 100%);
    max-height: min(84vh, 760px);
    border-radius: 18px;
    padding: 30px 28px 24px;
    box-shadow: 0 30px 90px rgba(15, 23, 42, .26);
    animation: sheetIn .28s cubic-bezier(.22, .61, .36, 1);
}
.sheet-close {
    position: absolute; top: 12px; right: 12px;
    width: 36px; height: 36px; border-radius: 50%;
    border: 1px solid var(--line); background: #fff; color: var(--fg-dim);
    font-size: 21px; line-height: 1; cursor: pointer;
    display: inline-flex; align-items: center; justify-content: center;
}
.sheet-close:hover { border-color: var(--accent); color: var(--accent); background: #f7fbff; }
.sheet-tag { color: var(--accent); font-size: 11.5px; font-weight: 600; letter-spacing: .4px; margin-bottom: 8px; }
.sheet-tag .tag { margin-right: 4px; }
.sheet-body h3 { font-size: 19px; line-height: 1.5; padding-right: 34px; }
.sheet-text { font-size: 14.5px; line-height: 1.9; }
.sheet .actions { margin-top: 22px; }
@keyframes sheetIn { from { opacity: 0; transform: translateY(24px) scale(.97); } to { opacity: 1; transform: none; } }

.empty-state { display: flex; flex-direction: column; align-items: center; gap: 12px; padding: 54px 0; color: var(--fg-dim); }
.empty-icon { display: inline-flex; width: 62px; height: 62px; align-items: center; justify-content: center; border-radius: 20px; background: #fff; border: 1px solid var(--line); color: #b7c2d3; }
.empty-icon svg { width: 30px; height: 30px; }

/* ============================================================
   后台：顶栏头像菜单、整齐导航与站点设置
   ============================================================ */

.admin .bar {
    position: sticky; top: 0; z-index: 20;
    background: rgba(255, 255, 255, .88);
    backdrop-filter: blur(14px);
    padding: 13px 0;
}
.admin .bar-title { align-items: center; gap: 12px; }
.bar-heading { display: flex; flex-direction: column; gap: 1px; min-width: 0; }
.bar-kicker { font-size: 11px; color: var(--fg-dim); letter-spacing: .2px; }
.admin .bar h1 { font-size: 17px; line-height: 1.2; }
.admin .pane > h2 { display: none; }
.admin .pane > .hint { margin-top: 0; }
.admin .layout { padding-top: 20px; }

.admin-user { position: relative; }
.admin-user-btn {
    display: flex; align-items: center; gap: 10px;
    padding: 5px 10px 5px 5px;
    border: 1px solid var(--line);
    border-radius: 999px;
    background: #fff;
    color: var(--fg);
    cursor: pointer;
    transition: border-color .2s ease, box-shadow .2s ease;
}
.admin-user-btn:hover { border-color: #bfd6f7; box-shadow: 0 6px 18px rgba(30, 70, 130, .07); }
.admin-avatar { border-radius: 50%; display: block; flex: 0 0 auto; }
.admin-user-meta { display: flex; flex-direction: column; align-items: flex-start; gap: 0; line-height: 1.2; max-width: 150px; }
.admin-user-meta b { font-size: 12.5px; font-weight: 600; max-width: 150px; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.admin-user-meta span { font-size: 10.5px; color: var(--fg-dim); }
.admin-user-btn .chev { transition: transform .2s ease; }
.admin-user.open .admin-user-btn .chev { transform: rotate(45deg); }

.user-menu {
    position: absolute; right: 0; top: calc(100% + 10px);
    width: 248px;
    background: #fff;
    border: 1px solid var(--line);
    border-radius: 14px;
    box-shadow: 0 24px 60px rgba(15, 23, 42, .16);
    padding: 8px;
    z-index: 40;
}
.user-menu[hidden] { display: none !important; }
.user-menu-head { display: flex; align-items: center; gap: 10px; padding: 10px 10px 12px; border-bottom: 1px solid var(--line); margin-bottom: 6px; }
.user-menu-head div { display: flex; flex-direction: column; gap: 2px; min-width: 0; }
.user-menu-head b { font-size: 13px; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.user-menu-head span { font-size: 11.5px; color: var(--fg-dim); }
.user-menu a { display: block; padding: 9px 10px; border-radius: 8px; color: var(--fg); font-size: 13px; }
.user-menu a:hover { background: #f5f9ff; color: var(--accent); text-decoration: none; }
.user-menu-sep { height: 1px; background: var(--line); margin: 6px 4px; }
.user-menu .user-menu-danger { color: #d33; }
.user-menu .user-menu-danger:hover { background: #fff4f4; color: #c00; }

.admin-nav-label { display: inline-flex; align-items: center; gap: 10px; min-width: 0; }
.admin-nav-ico { display: inline-flex; width: 18px; height: 18px; color: #7c8aa0; flex: 0 0 auto; }
.admin-nav-ico svg { width: 18px; height: 18px; }
.admin-drawer a.active .admin-nav-ico, .admin-drawer a:hover .admin-nav-ico { color: var(--accent); }
.admin-drawer a { padding: 10px 11px; }
.admin-drawer-foot { display: flex; flex-direction: column; gap: 2px; }
.admin-drawer-foot .mini { font-size: 11.5px; }

.settings-grid { display: grid; grid-template-columns: minmax(0, 1.35fr) minmax(260px, .65fr); gap: 16px; align-items: start; }
.settings-side { display: flex; flex-direction: column; gap: 14px; }
.settings-side .card { padding: 18px 20px; }
.sec-label { font-size: 13px; font-weight: 600; margin-bottom: 8px; }
.settings-side .btn { display: inline-flex; margin-top: 4px; }
.kv { display: flex; align-items: center; justify-content: space-between; gap: 12px; padding: 7px 0; border-bottom: 1px dashed #eef1f5; font-size: 12.5px; }
.kv:last-child { border-bottom: 0; }
.kv span { color: var(--fg-dim); }
.kv b { font-weight: 600; text-align: right; }

@media (max-width: 980px) {
    .hero-grid { grid-template-columns: minmax(0, 1fr); gap: 18px; }
    .hero-art { min-height: 390px; margin-top: 4px; }
    .phone-card { width: min(300px, 76%); }
    .chip-a { left: 8%; }
    .chip-b { right: 4%; }
    .chip-c { left: 10%; }
}

@media (max-width: 720px) {
    .home .hero { padding: 18px 0 34px; }
    .home .hero h1 { font-size: 27px; letter-spacing: -.4px; margin-top: 16px; }
    .home .hero .intro { font-size: 14px; line-height: 1.75; }
    .hero-grid { margin-top: 18px; }
    .hero-art { min-height: 360px; }
    .phone-card { width: min(280px, 86%); }
    .float-chip { font-size: 11px; padding: 7px 11px 7px 7px; }
    .chip-a { top: 6%; left: 0; }
    .chip-b { top: 31%; right: 0; }
    .chip-c { bottom: 4%; left: 1%; }
    .trust-row { gap: 8px 14px; }
    .steps { grid-template-columns: minmax(0, 1fr); }
    .step { padding: 20px 18px; }
    .release-card { align-items: flex-start; flex-wrap: wrap; padding: 18px; }
    .release-main { flex: 1 1 180px; }
    .release-card .btn { flex: 1 1 100%; text-align: center; }
    .ann-item { align-items: flex-start; gap: 10px; padding: 14px; }
    .ann-item-main { max-width: 100%; }
    .ann-preview { display: none; }
    .ann-item .chev { margin-left: auto; margin-top: 4px; }
    .sheet { align-items: flex-end; padding: 0; }
    .sheet-body { border-radius: 20px 20px 0 0; max-height: 88vh; padding: 26px 20px 22px; }
    .settings-grid { grid-template-columns: minmax(0, 1fr); }
    .admin .bar { padding: 10px 0; }
    .bar-kicker { display: none; }
    .admin .bar h1 { font-size: 16px; }
    .admin-user-meta { display: none; }
    .admin-user-btn { padding: 4px; }
    .admin-user-btn .chev { display: none; }
    .user-menu { position: fixed; top: 62px; right: 12px; width: min(280px, calc(100vw - 24px)); }
}

@media (prefers-reduced-motion: reduce) {
    .phone-card, .float-chip, .art-orb, .pulse-dot, .phone-code .c-cursor { animation: none; }
    .reveal { opacity: 1; transform: none; transition: none; }
    .sheet-body { animation: none; }
}

/* 后台概览：快捷入口与可折叠接口 */
.quick-actions { display: flex; flex-wrap: wrap; gap: 9px; margin-top: 14px; }
.quick-actions a {
    display: inline-flex; align-items: center; gap: 8px;
    background: #fff; border: 1px solid var(--line); border-radius: 999px;
    padding: 8px 14px 8px 8px; color: var(--fg); font-size: 12.5px; font-weight: 500;
    transition: border-color .2s ease, box-shadow .2s ease, transform .2s ease;
}
.quick-actions a:hover { border-color: #bfd6f7; color: var(--accent); text-decoration: none; box-shadow: 0 8px 20px rgba(30,70,130,.07); transform: translateY(-1px); }
.quick-ico { display: inline-flex; align-items: center; justify-content: center; width: 24px; height: 24px; border-radius: 50%; background: #eef5ff; color: var(--accent); font-size: 13px; font-weight: 700; }
.quick-badge { display: inline-flex; min-width: 18px; height: 18px; align-items: center; justify-content: center; border-radius: 999px; background: #fff0f0; color: #d33; font-size: 10.5px; padding: 0 5px; }
.api-card { padding: 16px 20px; }
.api-card summary { cursor: pointer; font-size: 13px; font-weight: 600; list-style: none; display: flex; align-items: center; gap: 8px; }
.api-card summary::-webkit-details-marker { display: none; }
.api-card summary::before { content: "+"; width: 20px; height: 20px; border-radius: 50%; background: #eef5ff; color: var(--accent); display: inline-flex; align-items: center; justify-content: center; font-size: 14px; }
.api-card[open] summary::before { content: "−"; }
.api-card summary .mini { font-weight: 400; margin-left: auto; }
.api-list { margin-top: 12px; }

.admin { font-size: 15px; }
.admin .pane > .hint {
    font-size: 14.5px; line-height: 1.75; color: #596474;
    background: #f7f9fc; border: 1px solid #edf1f6;
    border-radius: 10px; padding: 10px 14px; margin: 0 0 18px;
}
.admin label { font-size: 14px; color: #566170; }
.admin .mini { font-size: 13.5px; line-height: 1.66; }
.admin .path { font-size: 13.5px; }
.admin .table { font-size: 14.5px; }
.admin .table th { font-size: 13.5px; }
.admin .table td, .admin .table th { overflow-wrap: anywhere; }
.admin .tbl-actions a, .admin .tbl-actions button { font-size: 13.5px; }
.admin .mini-btn { font-size: 13.5px !important; }
.admin .tree .node { font-size: 14.5px; }
.admin .tree .node .size { font-size: 13px; }
.admin .tree .cat { font-size: 13.5px; }
.admin .chip { font-size: 13.5px; }
.admin .kv { font-size: 14px; }
.admin .side a { font-size: 14.5px; }
.admin .side .group > span { font-size: 12.5px; }
.admin .bar h1 { font-size: 19px; }
.admin .admin-user-meta b { font-size: 13.5px; }
.admin .admin-user-meta span { font-size: 11.5px; }
.admin .user-menu a { font-size: 13.5px; }
.admin .user-menu-head span { font-size: 12px; }
.admin-drawer-foot .mini { font-size: 12px; }
.admin .quick-badge { font-size: 12px; }

.pane-tools { display: flex; align-items: center; gap: 8px; margin: 0 0 14px; }
.tool-btn {
    display: inline-flex; align-items: center; justify-content: center;
    width: 42px; height: 42px; padding: 0; flex: 0 0 auto;
    color: #536273; background: #fff; border: 1px solid var(--line); border-radius: 12px;
    cursor: pointer; transition: color .2s ease, border-color .2s ease, background .2s ease, box-shadow .2s ease;
}
.tool-btn svg { width: 20px; height: 20px; }
.tool-btn:hover { color: var(--accent); border-color: #bfd6f7; background: #f7fbff; box-shadow: 0 8px 18px rgba(30,70,130,.07); }
.tool-btn[aria-expanded="true"] { color: #fff; background: var(--accent); border-color: var(--accent); box-shadow: 0 8px 18px rgba(26,115,232,.24); }
.tool-panel[hidden] { display: none !important; }
.tool-panel .card { margin-bottom: 14px; }
.admin .tag { font-size: 12px; padding: 2px 8px; border-radius: 6px; margin-right: 4px; }
.admin .tag.ok, .admin .tag.bad { border-width: 1px; }
.admin .tag.warn { background: #fff4e5; color: #9a5b00; }

@media (min-width: 721px) {
    .admin .table {
        border-collapse: separate; border-spacing: 0;
        border: 1px solid #e6ebf2; border-radius: 14px;
        overflow: hidden; background: #fff;
    }
    .admin .table th { padding: 12px 14px; background: #f7f9fc; color: #596474; border-bottom: 1px solid #e8edf4; }
    .admin .table td { padding: 13px 14px; border-bottom: 1px solid #eef2f7; }
    .admin .table tbody tr:last-child td { border-bottom: 0; }
    .admin .table tbody tr:hover { background: #f8fbff; }
    .admin .table tbody td:first-child { font-weight: 600; color: #243142; }
}

.user-cell { display: flex; align-items: center; gap: 11px; min-width: 0; }
.user-avatar {
    display: inline-flex; align-items: center; justify-content: center;
    width: 38px; height: 38px; flex: 0 0 auto; border-radius: 50%;
    background: linear-gradient(135deg, #eaf2ff, #dbe9ff); color: #1a5fc4;
    font-size: 14px; font-weight: 700;
}
.user-main { display: flex; flex-direction: column; min-width: 0; gap: 1px; }
.user-main b { font-size: 14.5px; font-weight: 600; max-width: 250px; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.user-main span { font-size: 13px; color: #6e7887; max-width: 250px; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.user-meta { font-size: 13px; color: #647081; line-height: 1.5; }
.user-mobile-meta { display: none; }
@media (max-width: 720px) {
    #userTable td[data-label="临时账号"], #userTable td[data-label="注册时间"], #userTable td[data-label="最后登录"] { display: none; }
    #userTable .user-cell { width: 100%; }
    #userTable .user-main b, #userTable .user-main span { max-width: calc(100vw - 110px); }
    #userTable .user-mobile-meta { display: block; margin-top: 2px; color: #7a8492; font-size: 12.5px; line-height: 1.5; }
    #userTable .tbl-actions { flex-wrap: wrap; padding-top: 8px; }
    #userTable tbody > tr { padding: 12px 14px; }
}

.admin .tbl-actions { gap: 7px; align-items: center; }
.admin .tbl-actions > a {
    display: inline-flex; align-items: center; min-height: 32px; padding: 0 10px;
    border: 1px solid #e4e9f1; border-radius: 8px; background: #fff; color: #465468;
    font-size: 13.5px;
}
.admin .tbl-actions > a:hover { color: var(--accent); border-color: #bfd6f7; text-decoration: none; }
.admin .tbl-actions .mini-btn, .admin .tbl-actions .btn-ghost, .admin .tbl-actions .btn-danger {
    padding: 6px 11px; border-radius: 8px; border: 1px solid #e4e9f1;
    background: #fff; color: #465468; font-size: 13px; font-weight: 500;
}
.admin .tbl-actions .btn-danger, .admin .tbl-actions .mini-btn.is-danger { color: #b42323; background: #fff6f6; border-color: #f3d3d3; }
.admin .tbl-actions form { margin: 0; }


.ov-hero {
    display: flex; align-items: center; justify-content: space-between; gap: 18px;
    padding: 20px 22px; margin-bottom: 14px;
    background: linear-gradient(135deg, #f2f7ff 0%, #ffffff 72%);
    border: 1px solid #dfeafb; border-radius: 14px;
}
.ov-hero-copy { min-width: 0; }
.ov-eyebrow { font-size: 13px; font-weight: 600; color: #51739f; letter-spacing: .3px; }
.ov-hero h2 { margin: 4px 0 3px; font-size: 25px; letter-spacing: -.4px; }
.ov-hero p { margin: 0; font-size: 14px; color: #5f6b7a; }
.ov-hero p b { color: #173a67; }
.ov-status {
    display: inline-flex; align-items: center; gap: 8px; flex: 0 0 auto;
    padding: 8px 13px; border-radius: 999px;
    background: #fff; border: 1px solid #d7ebdf; color: #16753c;
    font-size: 13px; font-weight: 600;
}
.ov-status i { width: 8px; height: 8px; border-radius: 50%; background: #22c55e; box-shadow: 0 0 0 4px rgba(34,197,94,.13); }
.ov-status.is-bad { color: #b42323; border-color: #f1caca; }
.ov-status.is-bad i { background: #ef4444; box-shadow: 0 0 0 4px rgba(239,68,68,.12); }
.ov-hero + .quick-actions { margin: 0 0 16px; }

.ov-grid { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 12px; }
.ov-card {
    display: flex; align-items: flex-start; gap: 14px;
    padding: 16px 18px; background: #fff; border: 1px solid var(--line);
    border-radius: 12px; color: var(--fg); text-decoration: none;
    transition: border-color .2s ease, box-shadow .2s ease, transform .2s ease;
}
.ov-card:hover { text-decoration: none; border-color: #c4d9f7; box-shadow: 0 12px 28px rgba(25,65,130,.08); transform: translateY(-1px); }
.ov-ico { display: inline-flex; width: 44px; height: 44px; flex: 0 0 auto; align-items: center; justify-content: center; border-radius: 12px; background: #eef5ff; color: #1a73e8; }
.ov-ico svg { width: 22px; height: 22px; }
.ov-ico.is-violet { background: #f2efff; color: #6d4adf; }
.ov-ico.is-orange { background: #fff3e7; color: #d97818; }
.ov-ico.is-cyan { background: #e8f9fb; color: #0b8fa3; }
.ov-ico.is-green { background: #eaf8ef; color: #17924a; }
.ov-ico.is-sky { background: #eaf3ff; color: #2b7fe0; }
.ov-ico.is-indigo { background: #eef0ff; color: #4b5bd6; }
.ov-ico.is-red { background: #fff0f0; color: #d33; }
.ov-main { display: flex; flex-direction: column; min-width: 0; flex: 1 1 auto; }
.ov-label { font-size: 14px; color: #5f6b7a; font-weight: 600; }
.ov-value { font-size: 30px; line-height: 1.12; font-weight: 700; letter-spacing: -.6px; margin-top: 2px; }
.ov-value.is-warn { color: #c2410c; }
.ov-value.is-ok { color: #15803d; }
.ov-sub { font-size: 13.5px; color: #7a8492; margin-top: 2px; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.ov-meter { display: block; height: 6px; border-radius: 999px; background: #edf1f6; overflow: hidden; margin-top: 10px; }
.ov-meter i { display: block; height: 100%; border-radius: inherit; background: linear-gradient(90deg, #62a0ff, #1a73e8); }

.ov-charts { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 12px; margin-top: 12px; }
.ov-chart { padding: 18px 20px; }
.ov-chart-head { display: flex; align-items: flex-start; justify-content: space-between; gap: 12px; }
.ov-chart-kicker { font-size: 13px; font-weight: 600; color: #51739f; }
.ov-chart h3 { margin: 2px 0 0; font-size: 17px; }
.ov-chart-total { font-size: 24px; font-weight: 700; letter-spacing: -.4px; }
.ov-bars { display: grid; grid-template-columns: repeat(7, minmax(0, 1fr)); align-items: end; gap: 10px; height: 150px; margin-top: 14px; }
.ov-bar-col { display: flex; flex-direction: column; align-items: center; justify-content: flex-end; gap: 6px; height: 100%; }
.ov-bar-col i { display: block; width: 100%; max-width: 34px; height: calc(var(--h) * 1px); max-height: 104px; min-height: 3px; border-radius: 7px 7px 3px 3px; background: linear-gradient(180deg, #7cb2ff, #1a73e8); }
.ov-bar-val { font-size: 12px; color: #647081; line-height: 1; }
.ov-bar-col em { font-size: 12px; font-style: normal; color: #8a94a3; line-height: 1; }
.ov-chart-foot { margin: 13px 0 0; font-size: 13.5px; color: #6e7887; }
.ov-gauges { display: flex; align-items: center; justify-content: center; gap: 26px; margin-top: 12px; }
.ov-gauge {
    --p: 0; --ring: #1a73e8;
    position: relative; display: grid; place-items: center;
    width: 126px; height: 126px; border-radius: 50%; flex: 0 0 auto;
    background: conic-gradient(var(--ring) calc(var(--p) * 1%), #edf1f7 0);
}
.ov-gauge.is-green { --ring: #16a34a; }
.ov-gauge::before { content: ""; position: absolute; inset: 11px; border-radius: 50%; background: #fff; }
.ov-gauge > div { position: relative; z-index: 1; text-align: center; }
.ov-gauge b { display: block; font-size: 25px; line-height: 1.1; letter-spacing: -.5px; }
.ov-gauge span { display: block; margin-top: 3px; font-size: 13px; color: #6e7887; }

@media (max-width: 720px) {
    .ov-hero { align-items: flex-start; flex-direction: column; gap: 12px; padding: 18px; }
    .ov-hero h2 { font-size: 22px; }
    .ov-hero p { line-height: 1.7; }
    .ov-grid { grid-template-columns: minmax(0, 1fr); }
    .ov-charts { grid-template-columns: minmax(0, 1fr); }
    .ov-gauges { gap: 14px; }
    .ov-gauge { width: 116px; height: 116px; }
    .admin .bar h1 { font-size: 17px; }
    .admin .pane > .hint { font-size: 13.5px; }
}

@media (max-width: 380px) {
    .ov-gauges { gap: 8px; }
    .ov-gauge { width: 108px; height: 108px; }
    .ov-gauge b { font-size: 22px; }
}

/* 推拉抽屉打开时主页面会向右平移，裁掉溢出避免手机端出现横向滚动 */
html { overflow-x: hidden; overflow-x: clip; }
