/* ==========================================================================
   微信密保验证平台 - 项目补充样式（在 user.css / admin.css 之后加载）
   ========================================================================== */

/* ---------- 通用补充 ---------- */
.avatar-text {
    display: flex;
    align-items: center;
    justify-content: center;
    background: var(--primary);
    color: #fff;
    font-weight: 600;
    font-size: 14px;
}

.app-sidebar {
    display: flex;
    flex-direction: column;
}

.sidebar-foot {
    margin-top: auto;
    padding: 16px 6px 4px;
    border-top: 1px solid var(--border-light);
    font-size: 12px;
    color: var(--text-tertiary);
    text-align: center;
    word-break: break-all;
}

.form-grid-2 {
    display: grid;
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 0 16px;
}

.form-grid-3 {
    display: grid;
    grid-template-columns: repeat(3, minmax(0, 1fr));
    gap: 0 16px;
}

.form-grid-4 {
    display: grid;
    grid-template-columns: repeat(4, minmax(0, 1fr));
    gap: 0 16px;
}

@media (max-width: 1280px) {
    .form-grid-4 {
        grid-template-columns: repeat(2, minmax(0, 1fr));
    }
}

@media (max-width: 1100px) {
    .form-grid-3 {
        grid-template-columns: repeat(2, minmax(0, 1fr));
    }
}

@media (max-width: 767.98px) {
    .form-grid-2,
    .form-grid-3,
    .form-grid-4 {
        grid-template-columns: 1fr;
    }
}

.text-truncate {
    max-width: 260px;
    overflow: hidden;
    text-overflow: ellipsis;
    white-space: nowrap;
    display: inline-block;
    vertical-align: bottom;
}

.mono {
    font-family: Consolas, Monaco, "Courier New", monospace;
}

.hint-inline {
    font-size: 12px;
    color: var(--text-tertiary);
    margin-left: 6px;
}

.row-selected td {
    background: #f8fbff;
}

/* ---------- 会员信息卡 ---------- */
.member-hero {
    display: grid;
    grid-template-columns: 1fr auto;
    gap: 20px;
    align-items: center;
    background:#2563eb;
    border-radius: var(--radius-xl);
    padding: 24px 26px;
    color: #fff;
    margin-bottom: var(--sp-5);
    position: relative;
    overflow: hidden;
}

.member-hero::after {
    content: '';
    position: absolute;
    width: 260px;
    height: 260px;
    border-radius: 50%;
    background: rgba(255, 255, 255, .07);
    right: -70px;
    top: -110px;
}

.member-hero .hero-name {
    font-size: 20px;
    font-weight: 600;
    display: flex;
    align-items: center;
    gap: 10px;
}

.member-hero .hero-sub {
    margin-top: 8px;
    font-size: 13px;
    color: rgba(255, 255, 255, .82);
    display: flex;
    flex-wrap: wrap;
    gap: 6px 18px;
}

.member-hero .hero-sub span i {
    margin-right: 5px;
    opacity: .85;
}

.member-hero .hero-right {
    text-align: right;
    position: relative;
    z-index: 1;
}

.member-hero .hero-quota {
    font-size: 26px;
    font-weight: 700;
    line-height: 1.2;
}

.member-hero .hero-quota small {
    font-size: 13px;
    font-weight: 400;
    opacity: .8;
}

.member-hero .hero-quota-label {
    font-size: 12px;
    color: rgba(255, 255, 255, .8);
    margin-top: 2px;
}

.member-hero .hero-badge {
    display: inline-block;
    margin-top: 10px;
    padding: 3px 12px;
    border-radius: 20px;
    background: rgba(255, 255, 255, .18);
    font-size: 12px;
}

/* ---------- 配额进度 ---------- */
.quota-bar {
    height: 8px;
    border-radius: 8px;
    background: #eef2f6;
    overflow: hidden;
    margin-top: 8px;
}

.quota-bar>span {
    display: block;
    height: 100%;
    border-radius: 8px;
    background: linear-gradient(90deg, #3b82f6, #2563eb);
}

.quota-bar.is-full>span {
    background: linear-gradient(90deg, #f59e0b, #ef4444);
}

/* ---------- 公众号切换卡 ---------- */
.account-tabs {
    display: flex;
    gap: 8px;
    overflow-x: auto;
    padding-bottom: 8px;
    margin-bottom: 18px;
    border-bottom: 1px solid var(--border);
}

.account-chip {
    display: inline-flex;
    align-items: center;
    gap: 8px;
    padding: 9px 16px;
    border: 1px solid var(--border);
    border-radius: 10px;
    background: #fff;
    color: var(--text-secondary);
    font-size: 13px;
    font-weight: 500;
    white-space: nowrap;
    transition: all .15s ease;
}

.account-chip:hover {
    border-color: var(--primary-light-border);
    color: var(--primary);
}

.account-chip.active {
    background: var(--primary-light);
    border-color: var(--primary-light-border);
    color: var(--primary);
    font-weight: 600;
}

.account-chip .dot {
    width: 7px;
    height: 7px;
    border-radius: 50%;
    background: #cbd5e1;
}

.account-chip .dot.on {
    background: var(--success);
}

/* ---------- 关键字生效公众号选择器 ---------- */
.scope-picker {
    padding: 10px 12px;
    border: 1px solid var(--border);
    border-radius: 10px;
    background: #fbfdff;
}

.scope-all {
    display: flex;
    align-items: center;
    gap: 8px;
    margin: 0 0 8px;
    font-weight: 600;
    color: var(--text);
    cursor: pointer;
}

.scope-all input,
.scope-item input {
    width: 15px;
    height: 15px;
    accent-color: var(--primary);
    flex-shrink: 0;
}

.scope-tools {
    display: flex;
    align-items: center;
    gap: 8px;
    flex-wrap: wrap;
    margin-bottom: 8px;
}

.scope-tools .form-hint {
    margin: 0;
}

.scope-list {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(200px, 1fr));
    gap: 6px 10px;
    max-height: 180px;
    overflow: auto;
    padding-right: 4px;
}

.scope-list.is-disabled {
    opacity: .55;
}

.scope-item {
    display: flex;
    align-items: flex-start;
    gap: 8px;
    padding: 6px 8px;
    border: 1px solid transparent;
    border-radius: 8px;
    cursor: pointer;
}

.scope-item:hover {
    background: #f8fafc;
    border-color: var(--border-light);
}

.scope-item input {
    margin-top: 2px;
}

.scope-name {
    display: block;
    font-size: 13px;
    line-height: 1.35;
    color: var(--text);
}

.scope-appid {
    display: block;
    font-size: 11px;
    line-height: 1.4;
    color: var(--text-tertiary);
    word-break: break-all;
}

/* ---------- 后台数据表格：固定列宽 + 内容省略 ---------- */
.table-fixed {
    table-layout: fixed;
    width: 100%;
    min-width: 980px;
}

.table-fixed th,
.table-fixed td {
    overflow: hidden;
    vertical-align: middle;
}

.cell-ellipsis {
    display: block;
    max-width: 100%;
    overflow: hidden;
    white-space: nowrap;
    text-overflow: ellipsis;
}

.cell-sub {
    display: block;
    margin-top: 2px;
    font-size: 12px;
    color: var(--text-muted);
    overflow: hidden;
    white-space: nowrap;
    text-overflow: ellipsis;
}

.table-fixed .row-actions {
    flex-wrap: wrap;
}

/* ---------- 关键字列表（紧凑表格） ---------- */
.kw-table {
    table-layout: fixed;
    min-width: 960px;
}

.kw-table td {
    vertical-align: middle;
}

.kw-cell-ellipsis {
    display: block;
    max-width: 100%;
    overflow: hidden;
    white-space: nowrap;
    text-overflow: ellipsis;
}

.kw-status-on {
    color: var(--success);
    font-weight: 600;
}

.kw-status-off {
    color: var(--danger);
    font-weight: 600;
}

/* 6 卡片概览 */
.stat-grid-6 {
    grid-template-columns: repeat(3, minmax(0, 1fr));
}

@media (max-width: 1200px) {
    .stat-grid-6 {
        grid-template-columns: repeat(2, minmax(0, 1fr));
    }
}

@media (max-width: 640px) {
    .stat-grid-6 {
        grid-template-columns: 1fr;
    }
}

/* ---------- 统计卡（统一卡片布局） ---------- */
.stat-card-tile {
    flex-direction: column;
    align-items: stretch;
    justify-content: space-between;
    gap: 12px;
    padding: 18px 20px;
    background: linear-gradient(145deg, #ffffff 62%, #f8fafc);
    position: relative;
    overflow: hidden;
}



.tile-head {
    display: flex;
    align-items: center;
    gap: 10px;
    width: 100%;
    flex-wrap: wrap;
    position: relative;
    z-index: 1;
}

.stat-card-tile .stat-icon {
    width: 38px;
    height: 38px;
    border-radius: 12px;
    font-size: 16px;
}

.tile-info {
    min-width: 0;
    flex: 1 1 auto;
}

.tile-info .stat-label {
    display: block;
    font-size: 12px;
    font-weight: 500;
    color: var(--text-tertiary);
}

.tile-value {
    margin-left: auto;
    font-size: 28px;
    font-weight: 700;
    line-height: 1.05;
    color: var(--text);
    font-variant-numeric: tabular-nums;
}

.tile-value-sub {
    font-size: 13px;
    font-weight: 500;
    color: var(--text-tertiary);
}

.tile-foot {
    display: flex;
    align-items: center;
    gap: 6px;
    flex-wrap: wrap;
    padding-top: 10px;
    border-top: 1px solid rgba(148, 163, 184, .18);
    position: relative;
    z-index: 1;
}

.tile-foot .quota-bar {
    flex: 1 1 80px;
    min-width: 60px;
    margin-top: 0;
}

.tile-chip {
    display: inline-flex;
    align-items: center;
    gap: 5px;
    padding: 4px 8px;
    border-radius: 999px;
    background: rgba(255, 255, 255, .85);
    border: 1px solid var(--border-light);
    font-size: 12px;
    color: var(--text-secondary);
    white-space: nowrap;
}

.tile-chip b {
    font-weight: 600;
    color: var(--text);
    font-variant-numeric: tabular-nums;
}

.tile-chip .dot {
    width: 6px;
    height: 6px;
    border-radius: 50%;
    background: #cbd5e1;
    flex-shrink: 0;
}

.tile-chip .dot.green { background: #22c55e; }
.tile-chip .dot.blue  { background: #3b82f6; }
.tile-chip .dot.orange { background: #f97316; }
.tile-chip .dot.violet { background: #8b5cf6; }

/* ---------- 服务状态统计卡 ---------- */
.stat-card-service {
    --svc-color: #64748b;
    --svc-soft: #f1f5f9;
    flex-direction: column;
    align-items: stretch;
    justify-content: space-between;
    gap: 14px;
    padding: 18px 20px;
    background: linear-gradient(145deg, #ffffff 58%, var(--svc-soft));
    position: relative;
    overflow: hidden;
}

.svc-running {
    --svc-color: #16a34a;
    --svc-soft: #ecfdf5;
}

.svc-http_down {
    --svc-color: #d97706;
    --svc-soft: #fffbeb;
}

.svc-down {
    --svc-color: #dc2626;
    --svc-soft: #fef2f2;
}

.stat-card-service::after {
    content: '';
    position: absolute;
    right: -28px;
    top: -28px;
    width: 96px;
    height: 96px;
    border-radius: 50%;
    background: var(--svc-soft);
    opacity: .9;
    pointer-events: none;
}

.stat-card-service .svc-head,
.stat-card-service .svc-ports {
    position: relative;
    z-index: 1;
}

.svc-head {
    display: flex;
    align-items: center;
    gap: 10px;
    width: 100%;
    flex-wrap: wrap;
}

.stat-card-service .stat-icon {
    width: 38px;
    height: 38px;
    border-radius: 12px;
    background: rgba(255, 255, 255, .75);
    color: var(--svc-color);
    font-size: 16px;
    box-shadow: 0 0 0 1px var(--svc-soft) inset;
}

.svc-info {
    min-width: 0;
    flex: 1 1 auto;
}

.stat-card-service .stat-label {
    font-size: 12px;
    font-weight: 500;
    color: var(--text-tertiary);
}

.svc-state {
    display: flex;
    align-items: center;
    gap: 7px;
    margin-left: auto;
    font-size: 20px;
    font-weight: 700;
    line-height: 1.1;
    color: var(--svc-color);
}

.svc-dot {
    width: 8px;
    height: 8px;
    border-radius: 50%;
    background: var(--svc-color);
    flex-shrink: 0;
}

.svc-running .svc-dot {
    animation: svcPulse 2.2s ease-out infinite;
}

@keyframes svcPulse {
    0%   { box-shadow: 0 0 0 0 rgba(34, 197, 94, .45); }
    70%  { box-shadow: 0 0 0 7px rgba(34, 197, 94, 0); }
    100% { box-shadow: 0 0 0 0 rgba(34, 197, 94, 0); }
}

.svc-ports {
    display: flex;
    gap: 6px;
    flex-wrap: wrap;
    padding-top: 10px;
    border-top: 1px solid rgba(148, 163, 184, .18);
}

.svc-port {
    display: inline-flex;
    align-items: center;
    gap: 5px;
    padding: 4px 8px;
    border-radius: 999px;
    background: rgba(255, 255, 255, .85);
    border: 1px solid var(--border-light);
    font-size: 12px;
    color: var(--text-secondary);
    white-space: nowrap;
}

.svc-port b {
    font-weight: 600;
    color: var(--text);
    font-variant-numeric: tabular-nums;
}

.svc-port em {
    font-style: normal;
    color: var(--text-tertiary);
}

.svc-port .dot {
    width: 6px;
    height: 6px;
    border-radius: 50%;
    background: #cbd5e1;
    flex-shrink: 0;
}

.svc-port .dot.on {
    background: #22c55e;
    box-shadow: 0 0 0 2px rgba(34, 197, 94, .15);
}

.svc-port .dot.off {
    background: #f97316;
    box-shadow: 0 0 0 2px rgba(249, 115, 22, .15);
}

/* ---------- 详情键值 ---------- */
.kv-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(230px, 1fr));
    gap: 16px 24px;
}

.kv-item .k {
    font-size: 12px;
    color: var(--text-tertiary);
    margin-bottom: 3px;
}

.kv-item .v {
    font-size: 14px;
    color: var(--text);
    word-break: break-all;
}

/* ---------- 日志查看 ---------- */
.log-toolbar {
    display: flex;
    align-items: center;
    gap: 10px;
    flex-wrap: wrap;
}

.log-pre {
    margin: 0;
    padding: 16px 18px;
    background: #0f172a;
    color: #cbd5e1;
    border-radius: var(--radius-md);
    font-family: Consolas, Monaco, "Courier New", monospace;
    font-size: 12.5px;
    line-height: 1.85;
    max-height: 620px;
    overflow: auto;
    white-space: pre-wrap;
    word-break: break-all;
}

.log-pre .lv-info {
    color: #7dd3fc;
}

.log-pre .lv-warn {
    color: #fbbf24;
}

.log-pre .lv-ok {
    color: #86efac;
}

.log-pre .lv-error {
    color: #f87171;
}

/* ---------- 带按钮的输入框（如 Token 随机生成） ---------- */
.input-with-btn {
    display: flex;
    align-items: center;
    gap: 8px;
}

.input-with-btn .form-input {
    flex: 1;
    min-width: 0;
}

.input-with-btn .btn {
    flex: 0 0 auto;
    height: 40px;
    padding: 0 14px;
}

/* ---------- 联系方式表单：分组与验证步骤 ---------- */
.form-section-title {
    display: flex;
    align-items: center;
    gap: 8px;
    margin: 4px 0 14px;
    font-size: 14px;
    font-weight: 600;
    color: var(--text);
}

.form-section-title:not(:first-of-type) {
    margin-top: 22px;
    padding-top: 18px;
    border-top: 1px solid var(--border-light);
}

.form-section-title i {
    color: var(--primary);
    font-size: 14px;
}

.section-optional {
    font-size: 12px;
    font-weight: 400;
    color: var(--text-tertiary);
}

.verify-panel {
    margin: 2px 0 18px;
    padding: 14px 16px 12px;
    border: 1px solid #dbeafe;
    border-radius: 12px;
    background: #f8fbff;
}

.verify-panel-head {
    display: flex;
    align-items: center;
    flex-wrap: wrap;
    gap: 8px;
    font-size: 13px;
    font-weight: 600;
    color: #1d4ed8;
}

.verify-hint {
    font-size: 12px;
    font-weight: 400;
    color: #64748b;
}

.verify-step {
    display: flex;
    gap: 12px;
    margin-top: 12px;
    padding-top: 12px;
    border-top: 1px dashed #dbeafe;
}

.verify-steps {
    display: grid;
    grid-template-columns: repeat(2, minmax(0, 1fr));
    margin-top: 12px;
    padding-top: 12px;
    border-top: 1px dashed #dbeafe;
}

.verify-steps .verify-step {
    margin-top: 0;
    padding-top: 0;
    border-top: 0;
}

.verify-steps .verify-step + .verify-step {
    padding-left: 24px;
    border-left: 1px dashed #dbeafe;
}

@media (max-width: 900px) {
    .verify-steps {
        grid-template-columns: 1fr;
    }

    .verify-steps .verify-step + .verify-step {
        margin-top: 12px;
        padding-top: 12px;
        padding-left: 0;
        border-left: 0;
        border-top: 1px dashed #dbeafe;
    }
}

.verify-step-no {
    flex-shrink: 0;
    width: 22px;
    height: 22px;
    margin-top: 2px;
    border-radius: 50%;
    background: #2563eb;
    color: #fff;
    font-size: 12px;
    font-weight: 600;
    display: flex;
    align-items: center;
    justify-content: center;
}

.verify-step-body {
    flex: 1;
    min-width: 0;
}

.verify-step-title {
    display: flex;
    align-items: center;
    flex-wrap: wrap;
    gap: 6px;
    margin-bottom: 8px;
    font-size: 13px;
    font-weight: 600;
    color: var(--text);
}

.verify-step-title .email {
    font-family: ui-monospace, SFMono-Regular, Menlo, Consolas, monospace;
    font-size: 12px;
    font-weight: 500;
    color: var(--text-secondary);
    word-break: break-all;
}

.verify-step .input-with-btn {
    flex-wrap: wrap;
}

.verify-step .input-with-btn .form-input {
    flex: 1 1 160px;
}

.verify-step .input-with-btn .btn {
    white-space: nowrap;
}

.verify-panel-hint {
    margin-top: 12px;
    font-size: 12px;
    color: var(--text-tertiary);
}

/* ---------- 版本徽章 ---------- */
.brand-version.version {
    background: var(--primary-light);
    color: var(--primary);
    border-color: var(--primary-light-border);
}

.auth-logo .name {
    display: flex;
    align-items: center;
    gap: 8px;
}

.auth-logo .name .brand-version {
    margin-left: 0;
}

/* 筛选栏单独成卡时去掉底部边框 */
.card > .filter-bar:last-child {
    border-bottom: none;
    border-radius: var(--radius-lg);
}

/* ---------- 回调地址 / Token 单元格 ---------- */
.callback-cell,
.token-cell {
    display: flex;
    align-items: center;
    gap: 4px;
}

.callback-cell {
    max-width: 400px;
}

.token-cell {
    max-width: 280px;
}

.callback-cell .callback-url,
.token-cell .token-value {
    flex: 1;
    min-width: 0;
    font-family: Consolas, Monaco, "Courier New", monospace;
    font-size: 12px;
    color: #475569;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
}

/* 回调地址：主地址 + 可切换列表 */
.cb-box {
    max-width: 430px;
}

.cb-row {
    display: flex;
    align-items: center;
    gap: 4px;
    padding: 6px 8px;
    border: 1px solid #e5e7eb;
    border-radius: 8px;
    background: #f8fafc;
}

.cb-row .cb-url {
    flex: 1;
    min-width: 0;
    font-family: Consolas, Monaco, "Courier New", monospace;
    font-size: 12px;
    color: #334155;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
}

.cb-more {
    margin-top: 6px;
}

.cb-more summary {
    display: inline-flex;
    align-items: center;
    gap: 5px;
    padding: 2px 4px;
    border-radius: 4px;
    font-size: 12px;
    color: var(--primary);
    cursor: pointer;
    list-style: none;
    user-select: none;
}

.cb-more summary::-webkit-details-marker {
    display: none;
}

.cb-more summary:hover {
    background: #eef4ff;
}

.cb-more summary i {
    font-size: 11px;
    transition: transform .15s;
}

.cb-more[open] summary i {
    transform: rotate(180deg);
}

.cb-menu {
    margin-top: 6px;
    padding: 6px;
    border: 1px solid #e2e8f0;
    border-radius: 8px;
    background: #f8fafc;
    display: flex;
    flex-direction: column;
    gap: 4px;
}

.cb-opt {
    display: flex;
    align-items: center;
    gap: 6px;
    min-width: 0;
    padding: 4px 6px;
    border: 1px solid #eef2f7;
    border-radius: 6px;
    background: #fff;
}

.cb-opt:hover {
    border-color: #cbd5e1;
}

.cb-no {
    flex: 0 0 auto;
    width: 16px;
    height: 16px;
    line-height: 16px;
    text-align: center;
    border-radius: 50%;
    background: #e8eefb;
    color: #4b6cb7;
    font-size: 10px;
    font-weight: 600;
}

.cb-host {
    flex: 0 0 auto;
    max-width: 100px;
    overflow: hidden;
    text-overflow: ellipsis;
    white-space: nowrap;
    font-size: 12px;
    font-weight: 600;
    color: #334155;
}

.cb-tag {
    flex: 0 0 auto;
    height: 16px;
    line-height: 16px;
    padding: 0 6px;
    border-radius: 8px;
    background: #e8f3ec;
    color: #2f855a;
    font-size: 10px;
}

.cb-tag-alt {
    background: #eef2fb;
    color: #3b5ba9;
}

.cb-full {
    flex: 1;
    min-width: 0;
    overflow: hidden;
    text-overflow: ellipsis;
    white-space: nowrap;
    font-family: Consolas, Monaco, "Courier New", monospace;
    font-size: 11px;
    color: #94a3b8;
}

/* ---------- 单选卡片（匹配方式） ---------- */
.radio-grid {
    display: grid;
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 10px;
}

.radio-card {
    display: flex;
    align-items: flex-start;
    gap: 10px;
    padding: 10px 12px;
    border: 1px solid var(--border);
    border-radius: var(--radius);
    background: #fff;
    cursor: pointer;
    transition: border-color .15s ease, background .15s ease;
}

.radio-card input {
    flex: 0 0 auto;
    width: 16px;
    height: 16px;
    margin-top: 2px;
    accent-color: var(--primary);
    cursor: pointer;
}

.radio-card .rc-body {
    display: flex;
    flex-direction: column;
    gap: 2px;
    min-width: 0;
}

.radio-card .rc-title {
    font-size: 13px;
    font-weight: 600;
    color: var(--text);
}

.radio-card .rc-desc {
    font-size: 12px;
    color: var(--text-tertiary);
    line-height: 1.5;
}

.radio-card.active {
    border-color: var(--primary-light-border);
    background: var(--primary-light);
}

@media (max-width: 640px) {
    .radio-grid {
        grid-template-columns: 1fr;
    }
}

/* ---------- 弹层（Modal） ---------- */
.modal-mask {
    display: none;
    position: fixed;
    inset: 0;
    z-index: 2000;
    background: rgba(15, 23, 42, .45);
    padding: 24px 16px;
    align-items: center;
    justify-content: center;
    overflow-y: auto;
}

.modal-mask.show {
    display: flex;
}

.modal {
    width: 100%;
    max-width: 720px;
    max-height: calc(100vh - 48px);
    max-height: calc(100dvh - 48px);
    margin: auto;
    display: flex;
    flex-direction: column;
    background: #fff;
    border-radius: var(--radius-xl);
    box-shadow: 0 24px 60px rgba(15, 23, 42, .22);
    overflow: hidden;
}

/* 弹层表单本身也要参与纵向伸缩，否则小屏幕下会把底部按钮顶出可视区 */
.modal > form {
    display: flex;
    flex-direction: column;
    flex: 1 1 auto;
    min-height: 0;
}

.modal-head {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 12px;
    padding: 16px 22px;
    border-bottom: 1px solid var(--border-light);
    flex-shrink: 0;
}

.modal-title {
    display: flex;
    align-items: center;
    gap: 8px;
    font-size: var(--fs-lg);
    font-weight: var(--fw-semibold);
    color: var(--text);
}

.modal-close {
    width: 32px;
    height: 32px;
    padding: 0;
    border: none;
    border-radius: var(--radius);
    background: transparent;
    color: var(--text-tertiary);
    font-size: 15px;
    cursor: pointer;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    transition: background .15s ease, color .15s ease;
}

.modal-close:hover {
    background: #f1f5f9;
    color: var(--text);
}

.modal-body {
    flex: 1 1 auto;
    min-height: 0;
    padding: 20px 22px 6px;
    overflow-y: auto;
    overscroll-behavior: contain;
}

.modal-foot {
    display: flex;
    justify-content: flex-end;
    gap: 10px;
    padding: 14px 22px;
    border-top: 1px solid var(--border-light);
    background: #fbfcfd;
    flex-shrink: 0;
}

.modal .form-item:last-child {
    margin-bottom: 12px;
}

button.account-chip {
    font-family: inherit;
    font-size: 13px;
    font-weight: 500;
    cursor: pointer;
}

@media (max-width: 640px) {
    .modal-mask {
        padding: 12px;
    }

    .modal {
        max-height: calc(100vh - 24px);
        max-height: calc(100dvh - 24px);
    }

    .modal-body {
        padding: 16px 16px 4px;
    }

    .modal-head,
    .modal-foot {
        padding-left: 16px;
        padding-right: 16px;
    }
}

/* ---------- 认证页补充 ---------- */
/* 验证码图片靠右时会被输入框圆角/边框“露出直角”，裁切掉小组件溢出部分 */
.input-group {
    overflow: hidden;
}

.input-group .input-suffix img {
    border-radius: 6px;
    margin-right: 1px;
}

/* 无 Tab 切换（如后台登录）时，副标题与表单之间补足间距 */
.auth-subtext + .auth-panel {
    margin-top: 20px;
}

/* 品牌栏说明文字宽度：避免末行只剩一两个字 */
.auth-sub {
    max-width: 400px;
}

.auth-box .form-hint a {
    color: var(--primary);
}

.auth-switch-line {
    margin-top: 16px;
    text-align: center;
    font-size: 13px;
    color: var(--text-secondary);
}

.auth-side .auth-logo .mark img {
    width: 44px;
    height: 44px;
    object-fit: contain;
    border-radius: 10px;
    background: #fff;
}

.auth-mobile-brand .mark img {
    width: 34px;
    height: 34px;
    object-fit: contain;
}

/* ---------- 模板变量提示 ---------- */
.var-hints {
    display: flex;
    flex-wrap: wrap;
    gap: 6px;
    margin-top: 6px;
}

.var-hints code {
    padding: 1px 7px;
    border-radius: 5px;
    background: #f1f5f9;
    border: 1px solid var(--border);
    color: #475569;
    font-size: 12px;
}

/* ---------- 表格小屏滚动 ---------- */
/* 公众号列表：固定列宽，避免操作列按钮被挤压 */
.account-table {
    table-layout: fixed;
    min-width: 1160px;
}

.table-wrap {
    overflow-x: auto;
}

@media (max-width: 640px) {
    .member-hero {
        grid-template-columns: 1fr;
        text-align: left;
    }

    .member-hero .hero-right {
        text-align: left;
    }
}
