/* ==================================================================================
   组件层 —— 卡片 / 按钮 / 徽章 / 表格 / 表单 / 弹层 / 进度 / 骨架
   ================================================================================== */

/* ------------------------------------------------------------------ 卡片 */
.card {
    position: relative;
    background: rgba(255, 255, 255, .86);
    backdrop-filter: blur(16px) saturate(1.5);
    -webkit-backdrop-filter: blur(16px) saturate(1.5);
    border: 1px solid var(--line);
    border-radius: var(--r-lg);
    box-shadow: var(--sh-sm), var(--sh-inset);
    transition: box-shadow var(--t) var(--e-out), transform var(--t) var(--e-out),
        border-color var(--t);
    overflow: hidden;
}

.card::before {
    content: "";
    position: absolute;
    inset: 0;
    border-radius: inherit;
    padding: 1px;
    background: linear-gradient(140deg, rgba(255, 255, 255, .95), rgba(255, 255, 255, 0) 42%);
    -webkit-mask: linear-gradient(#000 0 0) content-box, linear-gradient(#000 0 0);
    -webkit-mask-composite: xor;
    mask-composite: exclude;
    pointer-events: none;
}

.card.hov:hover {
    transform: translateY(-3px);
    box-shadow: var(--sh-lg);
    border-color: var(--brand-100);
}

.card-hd {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 10px;
    padding: 12px 17px;
    border-bottom: 1px solid var(--line-2);
    background: linear-gradient(180deg, rgba(255, 255, 255, .7), rgba(246, 249, 250, .35));
}

.card-hd h3 {
    display: flex;
    align-items: center;
    gap: 8px;
    font-size: .8125rem;
    font-weight: 700;
    letter-spacing: .02em;
    color: var(--ink);
    white-space: nowrap;
    min-width: 0;
}

/* 标题内的说明性徽标过长时截断，保证标题本身不折行 */
.card-hd h3 > .badge {
    overflow: hidden;
    text-overflow: ellipsis;
    display: inline-block;
    line-height: 17px;
    max-width: 22vw;
}

.card-hd h3::before {
    content: "";
    width: 3px;
    height: 13px;
    border-radius: 2px;
    background: var(--g-brand);
    box-shadow: 0 0 8px rgba(13, 146, 207, .5);
}

.card-bd {
    padding: 16px 17px;
}

.card-bd.tight {
    padding: 12px 14px;
}

.card-bd.flush {
    padding: 0;
}

/* 顶部高亮条 */
.card.accent::after {
    content: "";
    position: absolute;
    left: 0;
    right: 0;
    top: 0;
    height: 2px;
    background: var(--g-brand);
    opacity: .9;
}

.card.accent-teal::after { background: var(--g-teal); }
.card.accent-sky::after { background: var(--g-sky); }
.card.accent-warm::after { background: var(--g-warm); }

/* ------------------------------------------------------------------ 按钮 */
.btn {
    position: relative;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 6px;
    height: 32px;
    padding: 0 14px;
    border-radius: var(--r-sm);
    font-size: .75rem;
    font-weight: 600;
    letter-spacing: .02em;
    white-space: nowrap;
    background: var(--surface);
    color: var(--ink-2);
    border: 1px solid var(--line);
    box-shadow: var(--sh-xs);
    transition: all var(--t-fast) var(--e-out);
    overflow: hidden;
    user-select: none;
}

.btn:hover {
    color: var(--brand);
    border-color: var(--brand-300);
    background: var(--brand-50);
    transform: translateY(-1px);
    box-shadow: var(--sh-sm);
}

.btn:active {
    transform: translateY(0) scale(.98);
}

.btn:disabled,
.btn.disabled {
    opacity: .5;
    pointer-events: none;
}

.btn-pri {
    background: var(--g-brand);
    color: #fff;
    border-color: transparent;
    box-shadow: var(--sh-brand);
}

.btn-pri:hover {
    color: #fff;
    background: var(--g-brand);
    filter: brightness(1.07);
    box-shadow: 0 10px 30px rgba(13, 146, 207, .36);
}

.btn-teal {
    background: var(--g-teal);
    color: #fff;
    border-color: transparent;
    box-shadow: 0 8px 24px rgba(18, 165, 148, .26);
}

.btn-teal:hover { color: #fff; filter: brightness(1.07); }

.btn-sky {
    background: var(--g-sky);
    color: #fff;
    border-color: transparent;
    box-shadow: 0 8px 24px rgba(14, 116, 144, .26);
}

.btn-sky:hover { color: #fff; filter: brightness(1.07); }

.btn-ghost {
    background: transparent;
    border-color: transparent;
    box-shadow: none;
}

.btn-ghost:hover {
    background: var(--brand-50);
    box-shadow: none;
}

.btn-sm {
    height: 26px;
    padding: 0 10px;
    font-size: .6875rem;
    border-radius: var(--r-xs);
}

.btn-lg {
    height: 38px;
    padding: 0 20px;
    font-size: .8125rem;
}

.btn-icon {
    width: 32px;
    padding: 0;
}

.btn-icon.btn-sm { width: 26px; }

/* 按钮光泽扫过 */
.btn-pri::after,
.btn-teal::after,
.btn-sky::after {
    content: "";
    position: absolute;
    top: 0;
    left: 0;
    width: 40%;
    height: 100%;
    background: var(--g-sheen);
    transform: translateX(-120%) skewX(-18deg);
    pointer-events: none;
}

.btn-pri:hover::after,
.btn-teal:hover::after,
.btn-sky:hover::after {
    animation: sheen .85s var(--e-out);
}

/* 分段控件 */
.seg {
    display: inline-flex;
    padding: 3px;
    gap: 2px;
    background: var(--surface-3);
    border: 1px solid var(--line);
    border-radius: var(--r-sm);
    position: relative;
}

.seg button {
    position: relative;
    z-index: 1;
    height: 25px;
    padding: 0 12px;
    border-radius: var(--r-xs);
    font-size: .6875rem;
    font-weight: 600;
    color: var(--ink-3);
    transition: color var(--t-fast);
    white-space: nowrap;
}

.seg button.on {
    color: #fff;
}

.seg button:not(.on):hover {
    color: var(--brand);
}

.seg .thumb {
    position: absolute;
    top: 3px;
    height: 25px;
    border-radius: var(--r-xs);
    background: var(--g-brand);
    box-shadow: 0 3px 10px rgba(13, 146, 207, .32);
    transition: transform .34s var(--e-spring), width .34s var(--e-spring);
    z-index: 0;
}

/* ------------------------------------------------------------------ 徽章 / 标签 */
.badge {
    display: inline-flex;
    align-items: center;
    gap: 4px;
    height: 19px;
    padding: 0 7px;
    border-radius: var(--r-full);
    font-size: .625rem;
    font-weight: 700;
    letter-spacing: .03em;
    white-space: nowrap;
    background: var(--surface-3);
    color: var(--ink-3);
    border: 1px solid var(--line);
}

.badge.ok { background: var(--ok-100); color: #0a7a4a; border-color: rgba(18,165,101,.22); }
.badge.warn { background: var(--warn-100); color: #a5620a; border-color: rgba(232,144,26,.22); }
.badge.alarm { background: var(--alarm-100); color: #b8431f; border-color: rgba(242,104,60,.22); }
.badge.crit { background: var(--crit-100); color: #b31f2c; border-color: rgba(226,63,78,.24); }
.badge.brand { background: var(--brand-50); color: var(--brand-700); border-color: var(--brand-100); }
.badge.teal { background: var(--teal-100); color: var(--teal-600); border-color: rgba(18,165,148,.22); }
.badge.sky { background: var(--sky-100); color: #0b5a70; border-color: rgba(14, 116, 144,.2); }
.badge.cyan { background: var(--cyan-100); color: #0a7796; border-color: rgba(6,168,212,.2); }

.badge.solid-crit { background: var(--crit); color: #fff; border-color: transparent; }
.badge.solid-brand { background: var(--brand); color: #fff; border-color: transparent; }

.badge.beat { animation: pulseSoft 1.6s ease-in-out infinite; }

.tag {
    display: inline-flex;
    align-items: center;
    height: 20px;
    padding: 0 8px;
    border-radius: var(--r-xs);
    font-size: .625rem;
    font-weight: 600;
    background: var(--surface-3);
    color: var(--ink-3);
    border: 1px solid var(--line-2);
    transition: all var(--t-fast);
}

.tag:hover {
    background: var(--brand-50);
    color: var(--brand);
    border-color: var(--brand-100);
}

/* 状态点 */
.dot {
    width: 7px;
    height: 7px;
    border-radius: 50%;
    flex: none;
    position: relative;
}

.dot.ok { background: var(--ok); box-shadow: 0 0 0 3px var(--ok-100); }
.dot.warn { background: var(--warn); box-shadow: 0 0 0 3px var(--warn-100); }
.dot.alarm { background: var(--alarm); box-shadow: 0 0 0 3px var(--alarm-100); }
.dot.crit { background: var(--crit); box-shadow: 0 0 0 3px var(--crit-100); animation: pulseRing 1.8s infinite; }

.dot.live::after {
    content: "";
    position: absolute;
    inset: -3px;
    border-radius: 50%;
    border: 1px solid currentColor;
    opacity: .5;
    animation: pulseRing 2s infinite;
}

/* ------------------------------------------------------------------ 表格 */
.tbl {
    font-size: .75rem;
}

.tbl thead th {
    position: sticky;
    top: 0;
    z-index: 2;
    padding: 8px 10px;
    text-align: left;
    font-size: .6875rem;
    font-weight: 700;
    color: var(--ink-3);
    letter-spacing: .04em;
    background: linear-gradient(180deg, #f4f9fb, #e9f2f6);
    border-bottom: 1px solid var(--line);
    white-space: nowrap;
}

.tbl tbody td {
    padding: 8px 10px;
    border-bottom: 1px solid var(--line-2);
    color: var(--ink-2);
    vertical-align: middle;
}

.tbl tbody tr {
    transition: background var(--t-fast);
}

.tbl tbody tr:hover {
    background: linear-gradient(90deg, var(--brand-50), rgba(238, 243, 255, .3));
}

.tbl tbody tr:last-child td {
    border-bottom: 0;
}

.tbl.zebra tbody tr:nth-child(even) {
    background: rgba(247, 249, 253, .6);
}

.tbl.zebra tbody tr:nth-child(even):hover {
    background: var(--brand-50);
}

.tbl td.r, .tbl th.r { text-align: right; }
.tbl td.c, .tbl th.c { text-align: center; }

.tbl-wrap {
    overflow: auto;
    border-radius: var(--r-md);
    border: 1px solid var(--line-2);
}

/* 行内条形值 */
.bar-cell {
    position: relative;
    height: 5px;
    border-radius: 99px;
    background: var(--surface-3);
    overflow: hidden;
    min-width: 54px;
}

.bar-cell i {
    display: block;
    height: 100%;
    border-radius: 99px;
    background: var(--g-brand);
    transition: width .7s var(--e-out);
}

.bar-cell i.ok { background: linear-gradient(90deg, #35c98a, var(--ok)); }
.bar-cell i.warn { background: linear-gradient(90deg, #ffc46b, var(--warn)); }
.bar-cell i.alarm { background: linear-gradient(90deg, #ff9d78, var(--alarm)); }
.bar-cell i.crit { background: linear-gradient(90deg, #ff8090, var(--crit)); }

/* ------------------------------------------------------------------ 表单 */
.field {
    display: flex;
    flex-direction: column;
    gap: 5px;
}

.field > label {
    font-size: .6875rem;
    font-weight: 600;
    color: var(--ink-3);
    letter-spacing: .03em;
}

.inp {
    height: 32px;
    padding: 0 11px;
    border-radius: var(--r-sm);
    border: 1px solid var(--line);
    background: var(--surface);
    font-size: .75rem;
    color: var(--ink);
    transition: all var(--t-fast);
    outline: none;
    width: 100%;
}

.inp::placeholder { color: var(--ink-5); }

.inp:hover { border-color: var(--brand-300); }

.inp:focus {
    border-color: var(--brand);
    box-shadow: 0 0 0 3px rgba(13, 146, 207, .13);
}

select.inp {
    appearance: none;
    padding-right: 26px;
    background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='12' height='12' viewBox='0 0 24 24' fill='none' stroke='%2364748f' stroke-width='2.4' stroke-linecap='round'%3E%3Cpath d='M6 9l6 6 6-6'/%3E%3C/svg%3E");
    background-repeat: no-repeat;
    background-position: right 9px center;
    cursor: pointer;
}

textarea.inp {
    height: auto;
    padding: 9px 11px;
    resize: vertical;
    line-height: 1.6;
}

/* 滑块 */
.slider {
    -webkit-appearance: none;
    appearance: none;
    width: 100%;
    height: 5px;
    border-radius: 99px;
    background: var(--surface-3);
    outline: none;
    cursor: pointer;
}

.slider::-webkit-slider-thumb {
    -webkit-appearance: none;
    width: 15px;
    height: 15px;
    border-radius: 50%;
    background: #fff;
    border: 3px solid var(--brand);
    box-shadow: 0 2px 8px rgba(13, 146, 207, .4);
    cursor: grab;
    transition: transform var(--t-fast);
}

.slider::-webkit-slider-thumb:hover { transform: scale(1.18); }
.slider::-webkit-slider-thumb:active { cursor: grabbing; transform: scale(1.05); }

.slider::-moz-range-thumb {
    width: 15px;
    height: 15px;
    border-radius: 50%;
    background: #fff;
    border: 3px solid var(--brand);
    cursor: grab;
}

/* 开关 */
.switch {
    position: relative;
    width: 34px;
    height: 19px;
    border-radius: 99px;
    background: var(--ink-5);
    cursor: pointer;
    transition: background var(--t) var(--e-out);
    flex: none;
}

.switch::after {
    content: "";
    position: absolute;
    top: 2px;
    left: 2px;
    width: 15px;
    height: 15px;
    border-radius: 50%;
    background: #fff;
    box-shadow: 0 1px 4px rgba(0, 0, 0, .22);
    transition: transform var(--t) var(--e-spring);
}

.switch.on {
    background: var(--brand);
}

.switch.on::after {
    transform: translateX(15px);
}

/* 搜索框 */
.search {
    position: relative;
    flex: 1;
    min-width: 0;
}

.search .inp { padding-left: 30px; }

.search svg {
    position: absolute;
    left: 9px;
    top: 50%;
    transform: translateY(-50%);
    color: var(--ink-4);
    pointer-events: none;
}

/* ------------------------------------------------------------------ 进度 */
.prog {
    height: 6px;
    border-radius: 99px;
    background: var(--surface-3);
    overflow: hidden;
    position: relative;
}

.prog > i {
    display: block;
    height: 100%;
    border-radius: 99px;
    background: var(--g-brand);
    transition: width .8s var(--e-out);
    position: relative;
    overflow: hidden;
}

.prog > i::after {
    content: "";
    position: absolute;
    inset: 0;
    background: linear-gradient(90deg, transparent, rgba(255, 255, 255, .55), transparent);
    animation: sheen 2.2s linear infinite;
}

.prog.thin { height: 4px; }
.prog.thick { height: 9px; }

/* 环形进度 */
.ring {
    position: relative;
    display: grid;
    place-items: center;
}

.ring svg { transform: rotate(-90deg); }

.ring circle { fill: none; stroke-linecap: round; }

.ring .bg { stroke: var(--surface-3); }

.ring .fg {
    stroke: url(#ringGrad);
    transition: stroke-dashoffset 1.1s var(--e-out);
    filter: drop-shadow(0 2px 6px rgba(13, 146, 207, .32));
}

.ring .val {
    position: absolute;
    display: flex;
    flex-direction: column;
    align-items: center;
    line-height: 1.1;
}

/* ------------------------------------------------------------------ 弹层 */
.mask {
    position: fixed;
    inset: 0;
    z-index: 600;
    background: rgba(16, 26, 44, .38);
    backdrop-filter: blur(5px);
    -webkit-backdrop-filter: blur(5px);
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 24px;
    animation: fadeIn .22s var(--e-out);
}

.modal {
    width: min(960px, 94vw);
    max-height: 88vh;
    display: flex;
    flex-direction: column;
    background: var(--surface);
    border-radius: var(--r-xl);
    box-shadow: var(--sh-xl);
    border: 1px solid var(--line);
    overflow: hidden;
    animation: modalIn .38s var(--e-spring) both;
}

@keyframes modalIn {
    from { opacity: 0; transform: translateY(24px) scale(.96); }
    to { opacity: 1; transform: none; }
}

.modal-hd {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 12px;
    padding: 14px 18px;
    border-bottom: 1px solid var(--line-2);
    background: linear-gradient(135deg, var(--brand-50), rgba(255, 255, 255, .5));
}

.modal-hd h3 {
    font-size: .9375rem;
    font-weight: 700;
    display: flex;
    align-items: center;
    gap: 9px;
}

.modal-bd {
    padding: 16px 18px;
    overflow-y: auto;
    flex: 1;
}

.modal-ft {
    padding: 11px 18px;
    border-top: 1px solid var(--line-2);
    display: flex;
    justify-content: flex-end;
    gap: 8px;
    background: var(--surface-2);
}

.x-btn {
    width: 28px;
    height: 28px;
    border-radius: var(--r-xs);
    display: grid;
    place-items: center;
    color: var(--ink-3);
    transition: all var(--t-fast);
}

.x-btn:hover {
    background: var(--crit-100);
    color: var(--crit);
    transform: rotate(90deg);
}

/* 抽屉 */
.drawer-mask {
    position: fixed;
    inset: 0;
    z-index: 590;
    background: rgba(16, 26, 44, .3);
    backdrop-filter: blur(3px);
    animation: fadeIn .2s;
}

.drawer {
    position: fixed;
    top: 0;
    right: 0;
    bottom: 0;
    z-index: 595;
    width: min(560px, 92vw);
    background: var(--surface);
    box-shadow: -20px 0 60px rgba(16, 26, 44, .18);
    display: flex;
    flex-direction: column;
    animation: drawerIn .38s var(--e-out) both;
}

@keyframes drawerIn {
    from { transform: translateX(100%); }
    to { transform: none; }
}

/* ------------------------------------------------------------------ 提示 */
.toast-wrap {
    position: fixed;
    top: 18px;
    right: 18px;
    z-index: 900;
    display: flex;
    flex-direction: column;
    gap: 8px;
    pointer-events: none;
}

.toast {
    display: flex;
    align-items: center;
    gap: 9px;
    min-width: 230px;
    max-width: 380px;
    padding: 10px 14px;
    border-radius: var(--r-md);
    background: rgba(255, 255, 255, .96);
    backdrop-filter: blur(12px);
    border: 1px solid var(--line);
    box-shadow: var(--sh-lg);
    font-size: .75rem;
    font-weight: 500;
    color: var(--ink);
    animation: toastIn .4s var(--e-spring) both;
    pointer-events: all;
    position: relative;
    overflow: hidden;
}

@keyframes toastIn {
    from { opacity: 0; transform: translateX(40px) scale(.94); }
    to { opacity: 1; transform: none; }
}

.toast.out {
    animation: toastOut .3s var(--e-in-out) forwards;
}

@keyframes toastOut {
    to { opacity: 0; transform: translateX(40px) scale(.94); }
}

.toast::before {
    content: "";
    position: absolute;
    left: 0;
    top: 0;
    bottom: 0;
    width: 3px;
    background: var(--brand);
}

.toast.ok::before { background: var(--ok); }
.toast.warn::before { background: var(--warn); }
.toast.err::before { background: var(--crit); }

.toast i.ico {
    width: 20px;
    height: 20px;
    border-radius: 50%;
    display: grid;
    place-items: center;
    flex: none;
    background: var(--brand-50);
    color: var(--brand);
}

.toast.ok i.ico { background: var(--ok-100); color: var(--ok); }
.toast.warn i.ico { background: var(--warn-100); color: var(--warn); }
.toast.err i.ico { background: var(--crit-100); color: var(--crit); }

/* 气泡提示
   —— 由 core.js 挂载到 <body> 的浮层实现，不再使用 ::after。
   卡片、侧栏、流程图容器都有 overflow:hidden，伪元素气泡会被裁切；
   放到 body 顶层既不会被遮挡，也不会和其它 ::after 动效冲突。 */
.tipbox {
    position: fixed;
    z-index: 950;
    max-width: 280px;
    padding: 6px 10px;
    border-radius: var(--r-xs);
    background: rgba(16, 26, 44, .95);
    color: #fff;
    font-size: .625rem;
    font-weight: 500;
    line-height: 1.55;
    pointer-events: none;
    box-shadow: var(--sh-lg);
    opacity: 0;
    transform: translateY(4px);
    transition: opacity .14s var(--e-out), transform .14s var(--e-out);
}

.tipbox.on {
    opacity: 1;
    transform: none;
}

/* ------------------------------------------------------------------ 骨架屏 */
.sk {
    background: linear-gradient(90deg, #edf1f3 25%, #f6f9fa 37%, #edf1f3 63%);
    background-size: 400% 100%;
    animation: skShine 1.4s ease infinite;
    border-radius: var(--r-xs);
}

@keyframes skShine {
    0% { background-position: 100% 50%; }
    100% { background-position: 0 50%; }
}

.sk-line { height: 11px; margin-bottom: 8px; }
.sk-line.w60 { width: 60%; }
.sk-line.w40 { width: 40%; }
.sk-line.w80 { width: 80%; }

/* 加载旋转 */
.spin {
    width: 15px;
    height: 15px;
    border: 2px solid var(--brand-100);
    border-top-color: var(--brand);
    border-radius: 50%;
    animation: spin .7s linear infinite;
    flex: none;
}

.spin.sm { width: 11px; height: 11px; border-width: 1.5px; }
.spin.lg { width: 26px; height: 26px; border-width: 3px; }

/* 三点加载 */
.dots {
    display: inline-flex;
    gap: 3px;
    align-items: center;
}

.dots i {
    width: 4px;
    height: 4px;
    border-radius: 50%;
    background: var(--brand);
    animation: dotBounce 1.2s infinite;
}

.dots i:nth-child(2) { animation-delay: .16s; }
.dots i:nth-child(3) { animation-delay: .32s; }

@keyframes dotBounce {
    0%, 60%, 100% { transform: translateY(0); opacity: .45; }
    30% { transform: translateY(-4px); opacity: 1; }
}

/* ------------------------------------------------------------------ 空状态 */
.empty {
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    gap: 9px;
    padding: 34px 18px;
    color: var(--ink-4);
    text-align: center;
}

.empty .ic {
    width: 52px;
    height: 52px;
    border-radius: 50%;
    display: grid;
    place-items: center;
    background: linear-gradient(135deg, var(--brand-50), var(--surface-3));
    color: var(--brand-300);
    animation: floatY 3.4s ease-in-out infinite;
}

/* ------------------------------------------------------------------ 分隔与杂项 */
.hr {
    height: 1px;
    background: linear-gradient(90deg, transparent, var(--line), transparent);
    margin: 12px 0;
}

.vline {
    width: 1px;
    align-self: stretch;
    background: var(--line);
}

.chip-row {
    display: flex;
    gap: 6px;
    flex-wrap: wrap;
}

.kv {
    display: flex;
    align-items: baseline;
    gap: 5px;
}

.kv .k { font-size: .6875rem; color: var(--ink-4); }
.kv .v { font-size: .8125rem; font-weight: 700; color: var(--ink); }

/* 数字滚动 */
.odo {
    display: inline-flex;
    font-variant-numeric: tabular-nums;
    transition: color var(--t);
}

.odo.flash {
    animation: odoFlash .6s var(--e-out);
}

@keyframes odoFlash {
    0% { color: var(--brand); text-shadow: 0 0 14px rgba(13, 146, 207, .5); }
    100% { color: inherit; text-shadow: none; }
}

/* 折叠面板 */
.acc {
    border: 1px solid var(--line-2);
    border-radius: var(--r-md);
    overflow: hidden;
    background: var(--surface);
    transition: box-shadow var(--t);
}

.acc + .acc { margin-top: 7px; }

.acc:hover { box-shadow: var(--sh-sm); }

.acc-hd {
    display: flex;
    align-items: center;
    gap: 9px;
    padding: 9px 12px;
    cursor: pointer;
    user-select: none;
    background: var(--surface-2);
    transition: background var(--t-fast);
}

.acc-hd:hover { background: var(--brand-50); }

.acc-hd .arrow {
    margin-left: auto;
    color: var(--ink-4);
    transition: transform var(--t) var(--e-out);
    flex: none;
}

.acc.open .acc-hd .arrow { transform: rotate(90deg); }

.acc-bd {
    display: grid;
    grid-template-rows: 0fr;
    transition: grid-template-rows .36s var(--e-out);
}

.acc.open .acc-bd { grid-template-rows: 1fr; }

.acc-bd > div {
    overflow: hidden;
    min-height: 0;
}

.acc-bd .inner { padding: 11px 13px; border-top: 1px solid var(--line-2); }

/* 时间线 */
.tl { position: relative; padding-left: 20px; }

.tl::before {
    content: "";
    position: absolute;
    left: 5px;
    top: 5px;
    bottom: 5px;
    width: 2px;
    background: linear-gradient(180deg, var(--brand-100), var(--line-2));
    border-radius: 2px;
}

.tl-item { position: relative; padding-bottom: 13px; }

.tl-item:last-child { padding-bottom: 0; }

.tl-item::before {
    content: "";
    position: absolute;
    left: -18px;
    top: 5px;
    width: 8px;
    height: 8px;
    border-radius: 50%;
    background: #fff;
    border: 2px solid var(--brand);
    box-shadow: 0 0 0 3px var(--brand-50);
}

.tl-item.warn::before { border-color: var(--warn); box-shadow: 0 0 0 3px var(--warn-100); }
.tl-item.crit::before { border-color: var(--crit); box-shadow: 0 0 0 3px var(--crit-100); }
.tl-item.ok::before { border-color: var(--ok); box-shadow: 0 0 0 3px var(--ok-100); }

/* 统计小格 */
.stat {
    display: flex;
    flex-direction: column;
    gap: 2px;
    padding: 9px 11px;
    border-radius: var(--r-md);
    background: var(--surface-2);
    border: 1px solid var(--line-2);
    transition: all var(--t) var(--e-out);
}

.stat:hover {
    background: var(--brand-50);
    border-color: var(--brand-100);
    transform: translateY(-2px);
}

.stat .lbl {
    font-size: .625rem;
    color: var(--ink-4);
    font-weight: 600;
    letter-spacing: .04em;
}

.stat .val {
    font-size: 1.0625rem;
    font-weight: 800;
    color: var(--ink);
    line-height: 1.2;
}

.stat .val small {
    font-size: .625rem;
    font-weight: 600;
    color: var(--ink-4);
    margin-left: 2px;
}

/* 涟漪点击效果 */
.ripple {
    position: absolute;
    border-radius: 50%;
    background: rgba(255, 255, 255, .55);
    pointer-events: none;
    animation: ripple .6s var(--e-out) forwards;
}
