.site-header.jitheme-header-left,.jitheme-header-left .header,.jitheme-header-left .header .wrapper {
    height: 70px;
}

.jitheme-header-left .logo_menu_left {
    width: 100%;
    display: flex;
    flex-wrap: nowrap;
    align-items: center;
}

.jitheme-header-left .search_user {
    display: flex;
    flex-direction: row;
    align-items: center;
    flex-wrap: nowrap;
    justify-content: space-between;
}

.jitheme-header-left .header-logo {
    margin-right: 20px;
}

.ji-top-user-box .top-user-box-drop .avatar {
    width: 45px;
    height: 45px;
}

.ji-top-user-box .top-user-name {
    position: relative;
    margin-right: 47px;
    width: 100%;
    padding-top: 0;
    height: 45px;
    display: flex;
    flex-direction: column;
    justify-content: space-between;
}

.ji-top-user-box .top-user-info-box-name h2 {
    margin: 0;
}

.top-search .header-search-select {
    position: absolute;
    display: flex;
    flex-flow: column;
    top: 37px;
    background: var(--bg-card);
    left: 0;
    border: 1px solid var(--bg-subtle);
    padding: 5px;
    align-items: center;
}

.top-search-select {
    padding: 0 7px 0 0;
}

.site-header.jitheme-header-left .top-menu .top-menu-ul {
    gap: 20px;
}

.jitheme-header-left .top-menu ul li.depth-0 > a {
    position: relative;
    font-size: var(--fs-base);
    padding: 0;
    height: 70px;
    line-height: 70px;
    letter-spacing: 0.02em;
    cursor: pointer;
    white-space: nowrap;
    transition: color 0.2s,transform 0.2s;
}

.jitheme-header-left .top-menu ul li.depth-0 > a:hover {
    transform: translateY(-1px);
    height: 70px;
}

.jitheme-header-left .top-menu ul li.depth-0 > a i,.jitheme-header-left .top-menu ul li.depth-0 > a .hob {
    display: none;
}

.jitheme-header-left .top-menu ul li .sub-menu {
    box-shadow: none;
    top: 69px;
    border: 1px solid var(--border-color);
    padding: 5px;
}

.jitheme-header-left .top-menu ul li.depth-0 > a::after {
    content: '';
    position: absolute;
    left: 50%;
    bottom: 10px;
    width: 0%;
    height: 3px;
    background: var(--b2color);
    border-radius: var(--b2radius);
    transform: translateX(-50%);
    transition: width 0.4s cubic-bezier(0.22,0.61,0.36,1);
}

.jitheme-header-left .top-menu ul li.depth-0 > a:hover::after {
    width: 100%;
}

.jitheme-header-left .top-search {
    display: flex;
    align-items: center;
    border-radius: 14px;
    padding: 0 16px;
    border: 1px solid var(--border-color);
    transition: all 0.3s ease;
}

.jitheme-header-left .top-search:focus-within {
    border-color: var(--primary);
    box-shadow: none;
}

.jitheme-header-left .top-search form {
    display: flex;
    background-color: unset;
}

.jitheme-header-left .header input[type="text"] {
    border: none;
    outline: none;
    margin-left: 10px;
    font-size: var(--fs-xs);
    line-height: 19px;
}

.jitheme-header-left .header-user {
    position: unset;
    right: 0;
    top: 12px;
    display: flex;
}

.jitheme-header-left .header-user .top-user-box {
    width: 40px;
    height: 40px;
}

.jitheme-header-left .avatar_wdl {
    width: 40px;
    height: 40px;
    border-radius: 50%;
    background-image: url('data:image/svg+xml;utf8,<svg xmlns="http://www.w3.org/2000/svg" viewBox="0 0 24 24" fill="%23999"><path d="M12 12c2.21 0 4-1.79 4-4s-1.79-4-4-4-4 1.79-4 4 1.79 4 4 4zm0 2c-2.67 0-8 1.34-8 4v2h16v-2c0-2.66-5.33-4-8-4z"/></svg>');
    background-size: 60%;
    background-position: center;
    background-repeat: no-repeat;
    border: 1px solid var(--border-color);
    transition: transform 0.2s ease,border-color 0.3s ease;
}

.jitheme-header-left .icon-btn {
    width: 40px;
    height: 40px;
    border-radius: 50%;
    display: flex;
    justify-content: center;
    align-items: center;
    margin: 0 5px;
    cursor: pointer;
    transition: background-color 0.3s ease;
    color: var(--text-secondary);
}

.jitheme-header-left .icon-btn:hover {
    background-color: var(--bg-subtle);
    color: var(--primary);
}

.jitheme-header-left .change-theme button,.jitheme-header-left .change-theme > div a {
    display: flex;
    height: 40px;
    width: 40px;
    text-align: center;
    line-height: 1;
    border-radius: 100%;
    background-color: var(--bg-subtle);
    align-items: center;
    justify-content: center;
    position: relative;
    margin: 0;
}

button.empty,.button.empty,li.current-menu-item > a,.top-menu-hide:hover .more,.header .top-menu ul li.depth-0:hover > a .b2-jt-block-down,button.text {
    color: var(--text-primary);
}

@media screen and (min-width: 769px) {
    .jitheme-custom-nav .top-menu {
        display:none;
    }
}

.jitheme-custom-nav.site-header,.jitheme-custom-nav .header {
    height: 60px;
}

.jitheme-custom-nav .header {
    position: relative;
    width: 100%;
}
.jitheme-layout-toggle::after {
    content: attr(data-title);
    position: absolute;
    top: calc(100% + 8px);
    left: 50%;
    transform: translateX(-50%);
    background: var(--bg-card);
    color: var(--text-primary);
    font-size: var(--fs-xs);
    line-height: 1;
    padding: 7px 11px;
    border-radius: var(--b2radius);
    border: 1px solid var(--border-color);
    box-shadow: none;
    white-space: nowrap;
    opacity: 0;
    visibility: hidden;
    transition: opacity 0.18s,visibility 0.18s;
    pointer-events: none;
    z-index: 9999;
}

.jitheme-layout-toggle:hover::after {
    opacity: 1;
    visibility: visible;
}

.jitheme-layout-toggle:hover svg {
    transform: scale(1.1);
}

.jitheme-layout-toggle svg {
    width: 16px;
    height: 16px;
    margin: auto;
    fill: none;
    stroke: currentColor;
    transition: transform .25s;
}

/* 暗夜模式 */
[data-theme="dark"] .jitheme-layout-toggle {
    background: #24262c;
    color: #c3cde0;
    border-color: #2f3238;
}
[data-theme="dark"] .jitheme-layout-toggle:hover {
    background: #2f3238;
    color: #5b8bff;
    border-color: #3a3e46;
    box-shadow: none;
}

.jitheme-cnav {
    position: fixed;
    top: 0;
    left: 0;
    bottom: 0;
    width: 92px;
    background: var(--bg-card);
    border-right: 1px solid var(--border-color);
    display: flex;
    flex-direction: column;
    padding: 10px;
    box-sizing: border-box;
    z-index: 7;
    transition: width 0.2s cubic-bezier(0.16,1,0.3,1);
    /* 侧栏字号变量：统一调大在这里改一处即可 */
}

.jitheme-cnav.layout-row {
    width: 160px;
}

.jitheme-cnav .jitheme-cnav-logo {
    margin: 0 auto 20px;
    display: flex;
    justify-content: center;
    align-items: center;
    flex-shrink: 0;
}

.jitheme-cnav.layout-row .jitheme-cnav-logo {
    justify-content: flex-start;
    margin-bottom: 40px;
}

.jitheme-cnav .jitheme-cnav-logo img {
    display: block;
}

.jitheme-cnav .jitheme-cnav-logo .cnav-logo-narrow {
    width: 40px;
    height: 40px;
    border-radius: var(--b2radius);
    object-fit: cover;
    flex-shrink: 0;
}

.jitheme-cnav .jitheme-cnav-logo .cnav-logo-wide {
    display: none;
    width: auto;
    max-width: 120px;
    height: 36px;
    border-radius: var(--b2radius);
    object-fit: contain;
    flex-shrink: 0;
}

.jitheme-cnav.layout-row .jitheme-cnav-logo .cnav-logo-narrow {
    display: none;
}

.jitheme-cnav.layout-row .jitheme-cnav-logo .cnav-logo-wide {
    display: block;
}

.jitheme-cnav .jitheme-cnav-logo .jitheme-cnav-text-logo {
    font-size: var(--fs-base);
    color: var(--text-primary);
    text-decoration: none;
    letter-spacing: -1px;
}

.jitheme-cnav .jitheme-cnav-nav {
    display: flex;
    flex-direction: column;
    align-items: center;
    width: 100%;
    font-size: var(--fs-xs);
}

.jitheme-cnav.layout-row .jitheme-cnav-nav {
    align-items: flex-start;
    color: var(--text-secondary);
}

.jitheme-cnav .cnav-item {
    position: relative;
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    width: 50px;
    height: 50px;
    margin: 10px;
    font-size: var(--fs-xs);
    padding: 10px;
    border-radius: var(--b2radius);
    color: var(--text-secondary);
    text-decoration: none;
    background: none;
    border: 0;
    cursor: pointer;
    font-family: inherit;
    box-sizing: border-box;
    transition: all 0.2s ease;
    text-align: center;
}

.jitheme-cnav .cnav-item:hover,.jitheme-cnav .cnav-item.active {
    background: var(--bg-input);
    color: var(--text-primary);
}

.jitheme-cnav .cnav-item i {
    font-size: var(--fs-sm);
    margin-bottom: 5px;
    flex-shrink: 0;
}

.jitheme-cnav .cnav-item span {
    line-height: 1;
    white-space: nowrap;
}


.jitheme-cnav .cnav-item .b2small {
    position: absolute;
    top: 5px;
    right: 0;
    line-height: 17px;
    padding: 1px 4px;
    border-radius: 4px;
    color: #fff;
    white-space: nowrap;
    z-index: 2;
}

.cnav-item .shop-tips1 {
    background: #ff4d4f;
}

.cnav-item .shop-tips2 {
    background: var(--orange);
}

.cnav-item .shop-tips3 {
    background: #10b981;
}

.cnav-item .shop-tips4 {
    background: #1890ff;
}

.cnav-item .shop-tips5 {
    background: #722ed1;
}

.cnav-item .shop-tips6 {
    background: #eb2f96;
}

.jitheme-cnav.layout-row .cnav-item {
    flex-direction: row;
    justify-content: flex-start;
    align-items: center;
    width: 100%;
    height: 40px;
    margin: 0 0 10px;
    padding-left: 14px;
    border-radius: var(--b2radius);
}

.jitheme-cnav.layout-row .cnav-item i {
    font-size: var(--fs-sm);
    margin: 0 8px 0 0;
}

.jitheme-cnav.layout-row .cnav-item .b2small {
    position: static;
    transform: none;
    margin-left: 6px;
}

.jitheme-cnav .jitheme-cnav-bottom {
    margin-top: auto;
    display: flex;
    flex-direction: column;
    align-items: center;
    width: 100%;
    font-size: var(--fs-xs);
}

.jitheme-cnav .menu-toggle-btn {
    position: relative;
    display: flex;
    align-items: center;
    justify-content: center;
    width: 60px;
    height: 60px;
    /* margin: 0 auto; */
    border-radius: var(--b2radius);
    cursor: pointer;
    color: var(--text-primary);
    transition: all 0.4s ease;
    box-sizing: border-box;
}

.jitheme-cnav .menu-toggle-btn:hover {
    background: var(--bg-input);
}

.jitheme-cnav.layout-row .menu-toggle-btn {
    justify-content: flex-start;
    padding-left: 10px;
    width: calc(100% - 10px);
    height: 48px;
    border-radius: var(--b2radius);
}

.jitheme-cnav.layout-row .menu-toggle-btn::after {
    content: '菜单';
    margin-left: 5px;
    color: var(--text-primary);
}

/* 窄栏（上下结构）：三条杠下方显示「菜单」字样，与收藏/软件结构一致 */
.jitheme-cnav:not(.layout-row) .menu-toggle-btn {
    flex-direction: column;
    gap: 4px;
}

.jitheme-cnav:not(.layout-row) .menu-toggle-btn::after {
    content: '菜单';
    font-size: var(--fs-xs);
    line-height: 1;
    color: var(--text-secondary);
}

.jitheme-cnav .cnav-hamburger {
    display: block;
    width: 16px;
    height: 16px;
    flex-shrink: 0;
    color: var(--text-primary);
}

.jitheme-cnav-popup {
    position: absolute;
    left: 100%;
    z-index: 2;
    background: var(--bg-card);
    border-radius: var(--b2radius);
    box-shadow: none;
    opacity: 0;
    visibility: hidden;
    transform: translateX(-10px) scale(0.98);
    transition: opacity 0.2s cubic-bezier(0.16,1,0.3,1),visibility 0.2s,transform 0.2s cubic-bezier(0.16,1,0.3,1);
    pointer-events: none;
    max-height: calc(100vh - 48px);
    overflow-y: auto;
}

.jitheme-cnav .cnav-toggle-wrap:hover .jitheme-cnav-popup,.jitheme-cnav .menu-toggle-btn:hover .jitheme-cnav-popup {
    opacity: 1;
    visibility: visible;
    transform: translateX(0) scale(1);
    pointer-events: auto;
}

.jitheme-cnav-popup::before {
    content: '';
    position: absolute;
    left: -6px;
    width: 12px;
    height: 12px;
    background: var(--bg-card);
    transform: rotate(45deg);
    box-shadow: none;
    z-index: 1;
}

.jitheme-cnav-popup::after {
    content: '';
    position: absolute;
    left: -15px;
    top: 0;
    bottom: 0;
    width: 15px;
}

.jitheme-cnav .cnav-toggle-wrap.active {
    background: rgba(17,17,17,0.04);
}

.jitheme-cnav-popup.vip-popup {
    top: 50%;
    margin-top: -32px;
    width: 520px;
    max-width: calc(100vw - 140px);
    padding: 24px;
    box-sizing: border-box;
}

.jitheme-cnav-popup.vip-popup::before {
    top: 28px;
}

.jitheme-cnav-popup .vip-header {
    display: flex;
    align-items: center;
    justify-content: space-between;
    margin-bottom: 24px;
    gap: 16px;
}

.jitheme-cnav-popup .vip-header-left {
    display: flex;
    align-items: center;
    gap: 16px;
}

.jitheme-cnav-popup .vip-logo-icon {
    width: 56px;
    height: 56px;
    background: #22c55e;
    border-radius: var(--b2radius);
    display: flex;
    align-items: center;
    justify-content: center;
    color: #fff;
    flex-shrink: 0;
}

.jitheme-cnav-popup .vip-logo-icon i {
    font-size: 30px;
}

.jitheme-cnav-popup .vip-title-area {
    display: flex;
    flex-direction: column;
    gap: 6px;
}

.jitheme-cnav-popup .vip-title-row {
    display: flex;
    align-items: center;
    gap: 8px;
}

.jitheme-cnav-popup .vip-title {
    font-size: var(--fs-lg);
    color: var(--text-primary);
}

.jitheme-cnav-popup .vip-tag {
    font-size: var(--fs-xs);
    background: var(--bg-subtle);
    color: var(--text-secondary);
    padding: 2px 8px;
    border-radius: 4px;
}

.jitheme-cnav-popup .vip-subtitle {
    font-size: var(--fs-sm);
    color: var(--text-muted);
}

.jitheme-cnav-popup .vip-action-btn {
    background: #ffdb4d;
    color: var(--text-primary);
    font-size: var(--fs-base);
    padding: 10px 24px;
    border-radius: 24px;
    border: 0;
    cursor: pointer;
    text-decoration: none;
    transition: background 0.2s;
    display: inline-block;
}

.jitheme-cnav-popup .vip-action-btn:hover {
    background: #f5cd36;
}

.jitheme-cnav-popup .benefits-header {
    display: flex;
    align-items: center;
    justify-content: space-between;
    margin-bottom: 16px;
}

.jitheme-cnav-popup .benefits-title {
    font-size: var(--fs-base);
    color: var(--text-primary);
    display: flex;
    align-items: center;
    gap: 8px;
}

.jitheme-cnav-popup .benefits-title span {
    font-size: var(--fs-xs);
    color: var(--text-muted);
}

.jitheme-cnav-popup .view-more {
    font-size: var(--fs-sm);
    color: var(--text-secondary);
    cursor: pointer;
    text-decoration: none;
}

.jitheme-cnav-popup .view-more:hover {
    color: var(--text-primary);
}

.jitheme-cnav-popup .benefits-grid {
    display: grid;
    grid-template-columns: repeat(4,1fr);
    gap: 12px;
}

.jitheme-cnav-popup .benefit-card {
    position: relative;
    background: #fff9eb;
    border-radius: var(--b2radius);
    padding: 16px 8px;
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    gap: 12px;
    transition: transform 0.2s;
}

.jitheme-cnav-popup .benefit-card:hover {
    transform: translateY(-2px);
}

.jitheme-cnav-popup .benefit-icon {
    width: 32px;
    height: 32px;
    color: #f2c15f;
    display: flex;
    align-items: center;
    justify-content: center;
}

.jitheme-cnav-popup .benefit-icon i {
    font-size: 30px;
}

.jitheme-cnav-popup .card-badge {
    position: absolute;
    top: 0;
    right: 0;
    background: #fcebb6;
    color: #d19a37;
    font-size: var(--fs-xs);
    padding: 2px 6px;
    border-radius: 0 var(--b2radius) 0 var(--b2radius);
}

.jitheme-cnav-popup .benefit-text {
    font-size: var(--fs-xs);
    color: #a67c3b;
    text-align: center;
}

.jitheme-cnav-popup.menu-popup {
    bottom: 0;
    width: 756px;
    max-width: calc(100vw - 140px);
    padding: 32px;
    box-sizing: border-box;
    cursor: default;
}

/* 弹层内真实链接才显示手型；二维码浮层卡片不显示手型 */
.jitheme-cnav-popup .menu-btn,
.jitheme-cnav-popup .sitemap-row {
    cursor: pointer;
    font-size: var(--fs-xs);
}

.jitheme-cnav-popup .menu-social-pop,
.jitheme-cnav-popup .menu-social-pop * {
    cursor: default;
}

.jitheme-cnav-popup.menu-popup::before {
    top: auto;
    bottom: 22px;
}

.jitheme-cnav-popup .menu-section {
    margin-bottom: 28px;
}

.jitheme-cnav-popup .menu-section:last-child {
    margin-bottom: 0;
}

.jitheme-cnav-popup .menu-title {
    position: relative;
    display: flex;
    align-items: center;
    gap: 6px;
    font-size: var(--fs-xs);
    color: var(--text-primary);
    margin-bottom: 16px;
}

.jitheme-cnav-popup .menu-title > i {
    font-size: var(--fs-sm);
    color: var(--text-secondary);
}

/* 弹层角标：贴在标题/按钮右上角 */
.jitheme-cnav-popup .menu-title .badge,
.jitheme-cnav-popup .menu-btn .badge {
    position: absolute;
    top: 4px;
    right: 4px;
    z-index: 2;
    margin-left: 0;
    vertical-align: baseline;
    padding: 1px 6px;
    border-radius: 4px;
    font-size: var(--fs-xs);
    line-height: 1.5;
    white-space: nowrap;
}

.jitheme-cnav-popup .menu-grid {
    display: flex;
    flex-wrap: wrap;
    gap: 12px;
}

.jitheme-cnav-popup .menu-btn {
    position: relative;
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 0 14px;
    height: 43px;
    background: var(--bg-input);
    border-radius: var(--b2radius);
    font-size: var(--fs-xs);
    color: var(--text-primary);
    cursor: pointer;
    text-decoration: none;
    transition: background 0.2s;
    flex: 0 0 calc(25% - 9px);
    box-sizing: border-box;
}

.jitheme-cnav-popup .menu-btn > i {
    font-size: var(--fs-sm);
    color: var(--text-secondary);
    margin-right: 6px;
}

.jitheme-cnav-popup .menu-btn > span {
    max-width: calc(100% - 24px);
    overflow: hidden;
    text-overflow: ellipsis;
    white-space: nowrap;
}

.jitheme-cnav-popup .menu-btn:hover {
    background: var(--bg-muted);
}

.jitheme-cnav-popup .sitemap-row {
    display: flex;
    align-items: center;
    justify-content: space-between;
    width: 100%;
    height: 43px;
    background: var(--bg-input);
    border-radius: var(--b2radius);
    padding: 0 20px;
    font-size: var(--fs-base);
    color: var(--text-primary);
    cursor: pointer;
    margin-top: 12px;
    text-decoration: none;
    box-sizing: border-box;
}

.jitheme-cnav-popup .sitemap-row:hover {
    background: var(--bg-muted);
}

/* ===== 菜单弹层社交二维码组（hover 显示多张二维码） ===== */
.jitheme-cnav-popup .menu-social {
    display: flex;
    flex-wrap: wrap;
    justify-content: center;
    gap: 10px;
    margin-top: 14px;
    padding-top: 14px;
    border-top: 1px dashed var(--border-color, var(--border-color));
}

.jitheme-cnav-popup .menu-social-btn {
    position: relative;
    display: flex;
    align-items: center;
    gap: 6px;
    padding: 7px 12px;
    background: var(--bg-input);
    border-radius: var(--b2radius);
    font-size: var(--fs-sm);
    color: var(--text-primary);
    cursor: pointer;
    text-decoration: none;
    transition: background 0.2s;
}

.jitheme-cnav-popup .menu-social-btn > i {
    font-size: var(--fs-base);
    color: var(--text-secondary);
}

.jitheme-cnav-popup .menu-social-btn:hover {
    background: var(--bg-muted);
}

/* 悬停弹出的二维码浮层：朝上方弹出，一排多张 */
.jitheme-cnav-popup .menu-social-pop {
    position: absolute;
    bottom: calc(100% + 12px);
    left: 50%;
    transform: translateX(-50%);
    display: none;
    flex-wrap: wrap;
    gap: 12px;
    width: max-content;
    max-width: 480px;
    padding: 16px;
    background: var(--bg-card);
    border-radius: var(--b2radius);
    box-shadow: none;
    z-index: 60;
}

.jitheme-cnav-popup .menu-social-btn:hover .menu-social-pop {
    display: flex;
}

/* 浮层底部小箭头（指向触发按钮，无描边） */
.jitheme-cnav-popup .menu-social-pop::after {
    content: '';
    position: absolute;
    top: 100%;
    left: 50%;
    transform: translateX(-50%);
    border: 1px solid transparent;
    border-top-color: #fff;
    border-bottom: none;
}

body.dark .jitheme-cnav-popup .menu-social-pop::after {
    border-top-color: #222;
}

.jitheme-cnav-popup .menu-social-qr {
    display: flex;
    flex-direction: column;
    align-items: center;
    width: 108px;
    text-align: center;
}

.jitheme-cnav-popup .menu-social-qr img {
    width: 108px;
    height: 108px;
    object-fit: contain;
    border-radius: var(--b2radius);
    background: var(--bg-card);
    padding: 6px;
    border: 1px solid var(--border-color, var(--border-color));
    box-sizing: border-box;
}

.jitheme-cnav-popup .menu-social-qr b {
    margin-top: 8px;
    font-size: var(--fs-xs);
    color: var(--text-primary);
}

.jitheme-cnav-popup .menu-social-qr em {
    margin-top: 3px;
    font-style: normal;
    font-size: var(--fs-xs);
    color: var(--text-muted);
    line-height: 1.4;
}

body.dark .jitheme-cnav-popup .menu-social-btn { background: #2a2a2a; }
body.dark .jitheme-cnav-popup .menu-social-btn:hover { background: #333; }
body.dark .jitheme-cnav-popup .menu-social-pop { background: #222; border-color: #333; }

.jitheme-cnav-popup .sitemap-row i {
    font-size: var(--fs-base);
    color: var(--text-secondary);
}

@media screen and (max-width: 1200px) {
    .jitheme-cnav-popup .menu-btn {
        flex:0 0 calc(50% - 6px);
    }
}

.jitheme-cnav-popup.cnav-mega-popup {
    top: 0;
    width: 920px;
    max-width: calc(100vw - 140px);
    padding: 0;
    overflow: visible;
}

.jitheme-cnav-popup.cnav-mega-popup::before {
    top: 20px;
}

.jitheme-cnav-popup .mega-tabs {
    display: flex;
    gap: 28px;
    padding: 18px 28px 0;
    border-bottom: 1px solid var(--border-color);
}

.jitheme-cnav-popup .mega-tab {
    font-size: var(--fs-base);
    color: var(--text-secondary);
    padding-bottom: 14px;
    cursor: pointer;
    position: relative;
    white-space: nowrap;
    transition: color 0.2s;
}

.jitheme-cnav-popup .mega-tab:hover,.jitheme-cnav-popup .mega-tab.active {
    color: var(--text-primary);
}

.jitheme-cnav-popup .mega-tab.active::after {
    content: '';
    position: absolute;
    left: 0;
    right: 0;
    bottom: -1px;
    height: 2px;
    background: var(--text-primary);
    border-radius: 2px;
}

.jitheme-cnav-popup .mega-panels {
    padding: 20px 28px 24px;
}

.jitheme-cnav-popup .mega-panel {
    display: none;
    grid-template-columns: repeat(8,1fr);
    gap: 16px 24px;
}

.jitheme-cnav-popup .mega-panel.active {
    display: grid;
}

.jitheme-cnav-popup .mega-col {
    display: flex;
    flex-direction: column;
    gap: 10px;
    min-width: 0;
}

.jitheme-cnav-popup .mega-col-title {
    font-size: var(--fs-base);
    color: var(--text-primary);
    text-decoration: none;
    line-height: 1.3;
}

.jitheme-cnav-popup .mega-col-title:hover {
    color: var(--text-primary);
}

.jitheme-cnav-popup .mega-col-item {
    font-size: var(--fs-sm);
    color: var(--text-secondary);
    text-decoration: none;
    line-height: 1.3;
    white-space: nowrap;
    overflow: hidden;
    margin: 5px 0;
    text-overflow: ellipsis;
}

.jitheme-cnav-popup .mega-col-item:hover {
    color: var(--text-primary);
}

@media screen and (max-width: 1200px) {
    .jitheme-cnav-popup .mega-panel {
        grid-template-columns:repeat(4,1fr);
    }
}

@media screen and (max-width: 768px) {
    .jitheme-cnav-popup .mega-panel {
        grid-template-columns:repeat(2,1fr);
    }
}

body.jitheme-custom-nav #page {
    transition: padding-left 0.2s cubic-bezier(0.16,1,0.3,1);
}

body.jitheme-custom-nav .top-style {
    padding-left: 92px;
    transition: padding-left 0.2s cubic-bezier(0.16,1,0.3,1);
}

body.jitheme-custom-nav.jitheme-cnav-row .top-style {
    padding-left: 160px;
}

body.jitheme-custom-nav #content {
    margin-left: 92px;
    transition: margin-left 0.2s cubic-bezier(0.16,1,0.3,1);
    animation: jithemeFadeIn 0.25s ease;
}

body.jitheme-custom-nav.jitheme-cnav-row #content {
    margin-left: 160px;
}

@keyframes jithemeFadeIn {
    from {
        opacity: 0;
    }

    to {
        opacity: 1;
    }
}

@media screen and (max-width: 768px) {
    .jitheme-cnav,.jitheme-cnav-popup,.jitheme-layout-toggle {
        display:none;
    }

    body.jitheme-custom-nav #content {
        margin-left: 0;
    }

    body.jitheme-custom-nav .top-style {
        padding-left: 0;
    }
}

.jitheme-custom-nav .layout-row .b2small {
    position: absolute;
    display: block;
    right: 0;
    font-size: var(--fs-xs);
    padding: 0 7px;
    line-height: 15px;
    color: #ffffff;
    border-radius: var(--b2radius);
}

.jitheme-custom-nav .header .wrapper {
    display: flex;
    align-items: center;
    height: 60px;
    max-width: 100%;
    margin: 0 auto;
    position: relative;
    z-index: 2;
}

.jitheme-custom-nav .logo_menu_left {
    display: flex;
    align-items: center;
    gap: 12px;
    flex: 1 1 auto;
    min-width: 0;
}

.jitheme-custom-nav #mobile-menu-button {
    display: none;
}

.jitheme-custom-nav .top-search {
    position: relative;
    margin: 0;
    flex: 1;
    max-width: 480px;
    min-width: 260px;
}

.jitheme-custom-nav .top-search form,.jitheme-custom-nav .top-search form.mobile-search-input {
    display: flex;
    align-items: center;
    height: 36px;
    border-radius: 14px;
    padding: 3px;
    margin: 0;
    border: 1px solid var(--border-color);
    background: var(--bg-card);
    font-size: var(--fs-xs);
    color: var(--text-muted);
    transition: box-shadow 0.3s ease,background-color 0.3s ease,border-color 0.3s ease;
    flex-direction: row;
    align-content: center;
}

.jitheme-custom-nav .top-search form.mobile-search-input:hover {
    border: 1px solid var(--b2color);
}

.jitheme-custom-nav .top-search form.mobile-search-input:focus-within {
    box-shadow: none;
}

.jitheme-custom-nav .top-search .top-search-button {
    display: flex;
    align-items: center;
    flex-direction: row;
    height: 100%;
}

.jitheme-custom-nav .top-search .top-search-select {
    display: flex;
    align-items: center;
    justify-content: space-around;
    gap: 8px;
    font-size: var(--fs-sm);
    color: var(--text-secondary);
    border: none;
    border-radius: var(--b2radius);
    padding: 5px 8px;
    cursor: pointer;
    transition: all 0.2s ease;
    user-select: none;
    flex-shrink: 0;
    height: 30px;
    width: 80px;
    line-height: 1;
}

.jitheme-custom-nav .top-search .top-search-select i {
    font-size: var(--fs-base);
}

.jitheme-custom-nav .top-search .top-search-select .arrow-icon-wrapper {
    display: flex;
    align-items: center;
    justify-content: center;
    width: 16px;
    height: 16px;
    border-radius: 50%;
    font-size: var(--fs-xs);
    color: var(--text-secondary);
    transition: transform 0.3s ease;
    transform: rotate(0deg);
    flex-shrink: 0;
}

.jitheme-custom-nav .top-search .top-search-select .arrow-icon-wrapper svg {
    width: 10px;
    height: 10px;
    stroke-width: 3;
}

.jitheme-custom-nav .top-search .top-search-select.active .arrow-icon-wrapper {
    transform: rotate(180deg);
}

.jitheme-custom-nav .top-search .search-input {
    flex: 1;
    height: 100%;
    border: 0 !important;
    background: transparent !important;
    box-shadow: none;
    border-radius: 0 !important;
    outline: none;
    padding: 0 12px;
    font-size: var(--fs-sm);
    color: var(--text-primary);
    min-width: 0;
}

.jitheme-custom-nav .top-search .search-input::placeholder {
    color: var(--text-muted);
}

.jitheme-custom-nav .top-search .search-button-action {
    width: 30px;
    height: 30px;
    position: static;
    display: flex;
    align-items: center;
    justify-content: center;
    border: 0;
    cursor: pointer;
    color: var(--text-secondary);
    transition: background-color 0.2s,transform 0.1s;
    flex-shrink: 0;
    padding: 0;
    line-height: 1;
}

.jitheme-custom-nav .top-search .search-button-action:hover {
    filter: brightness(0.92);
}

.jitheme-custom-nav .top-search .search-button-action:active {
    transform: scale(0.95);
}

.jitheme-custom-nav .top-search .search-button-action svg {
    width: 14px;
    height: 14px;
    stroke-width: 2.5;
}

.jitheme-custom-nav .top-search .search-button-action i {
    font-size: var(--fs-lg);
    line-height: 1;
    margin: 0;
}

.jitheme-custom-nav .top-search .header-search-select {
    position: absolute;
    top: calc(100% + 6px);
    left: 0;
    margin: 0;
    width: 80px;
    padding: 4px;
    list-style: none;
    background: var(--bg-card);
    border-radius: var(--b2radius);
    box-shadow: none;
    opacity: 0;
    transform: translateY(-10px);
    visibility: hidden;
    pointer-events: none;
    transition: all 0.2s cubic-bezier(0.16,1,0.3,1);
}

.jitheme-custom-nav .top-search .header-search-select.show {
    opacity: 1;
    transform: translateY(0);
    visibility: visible;
    pointer-events: auto;
}

.jitheme-custom-nav .top-search .header-search-select li {
    padding: 0;
    width: 100%;
    text-align: center;
}

.jitheme-custom-nav .top-search .header-search-select a {
    display: block;
    padding: 6px 10px;
    border-radius: var(--b2radius);
    color: var(--text-secondary);
    width: 100%;
    font-size: var(--fs-xs);
    cursor: pointer;
    transition: background-color 0.15s,color 0.15s;
    line-height: 1.4;
}

.jitheme-custom-nav .top-search .header-search-select a:hover {
    background-color: var(--bg-subtle);
    color: var(--text-primary);
}

.jitheme-custom-nav .top-search .header-search-select a.select {
    background-color: var(--bg-input);
    color: var(--text-primary);
}

.jitheme-custom-nav .header-user {
    position: static;
    top: auto;
    right: auto;
    display: flex;
    align-items: center;
    gap: 20px;
}

/* 用户头像区域不可被 flex 压缩（防止窄窗口下头像宽度被挤成 0 而消失） */
.jitheme-custom-nav .header-user .change-theme,
.jitheme-custom-nav .header-user .jitheme-vip-btn,
.jitheme-custom-nav .header-user .jitheme-theme-toggle,
.jitheme-custom-nav .header-user .top-user-info,
.jitheme-custom-nav .header-user .user-tools,
.jitheme-custom-nav .header-user .top-user-box,
.jitheme-custom-nav .header-user .top-user-avatar.avatar-parent {
    flex-shrink: 0;
}
/* 用户区宽度统一 42px（覆盖父主题 .user-tools 34px，防止头像/容器宽高冲突溢出） */
.jitheme-custom-nav .header-user .user-tools {
    width: 38px;
    height: 38px;
}
.jitheme-custom-nav .header-user .top-user-avatar.avatar-parent {
    width: 38px;
    height: 38px;
    min-width: 38px;
}
/* 父主题 .header-user .top-user-box 34px 一并统一为 42px */
.jitheme-custom-nav .header-user .top-user-box {
    width: 38px;
    height: 38px;
}

.jitheme-custom-nav .search_user {
    margin-left: auto;
    display: flex;
    align-items: center;
}

/* 暗夜切换按钮：Jifont 字体图标尺寸 */
.jitheme-custom-nav .header-user .jitheme-theme-toggle .Jifont,
.jitheme-theme-toggle .Jifont {
    line-height: 1;
    color: inherit;
    display: inline-block;
}

.jitheme-custom-nav .header-user .change-theme {
    display: flex;
    align-items: center;
    gap: 20px;
    margin-right: 0;
}

.jitheme-custom-nav .top-user-info {
    display: flex;
    align-items: center;
}

.jitheme-custom-nav .new-avatar-container {
    display: flex;
    align-items: center;
    justify-content: center;
    width: 38px;
    height: 38px;
}

.jitheme-custom-nav .avatar_wdl {
    width: 20px;
    height: 20px;
    border-radius: 50%;
    background-color: transparent;
    background-image: url('data:image/svg+xml;utf8,<svg xmlns="http://www.w3.org/2000/svg" viewBox="0 0 24 24" fill="%23999"><path d="M12 12c2.21 0 4-1.79 4-4s-1.79-4-4-4-4 1.79-4 4 1.79 4 4 4zm0 2c-2.67 0-8 1.34-8 4v2h16v-2c0-2.66-5.33-4-8-4z"/></svg>');
    background-size: contain;
    background-position: center;
    background-repeat: no-repeat;
    border: none;
    cursor: pointer;
}

.jitheme-custom-nav .header-user .icon-btn,.jitheme-custom-nav .icon-btn {
    position: relative;
    width: 34px;
    height: 34px;
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 0;
    flex-direction: row;
    cursor: pointer;
    flex-shrink: 0;
    transition: all .25s cubic-bezier(0.4, 0, 0.2, 1);
}

.jitheme-custom-nav .header-user .icon-btn svg,.jitheme-custom-nav .icon-btn svg {
    display: block;
    width: 16px;
    height: 16px;
    stroke: currentColor;
    stroke-width: 2;
    fill: none;
    stroke-linecap: round;
    stroke-linejoin: round;
    transition: transform .25s;
}

/* 内部 a / span 容器占满并居中（修正图标垂直偏移） */
.jitheme-custom-nav .header-user .icon-btn > a,
.jitheme-custom-nav .header-user .icon-btn > span {
    display: flex;
    align-items: center;
    justify-content: center;
    width: 100%;
    height: 100%;
}
.jitheme-custom-nav .icon-btn:active {
    transform: translateY(-1px);
}
.jitheme-custom-nav .icon-btn:hover svg {
    transform: scale(1.1);
}

/* 有未读消息：铃铛图标变红（与红点同色 #ef4444），颜色作用到内层 a（fav-box 有自己的颜色）
   红点闪烁 + 图标变红 + 铃铛晃动三重提醒 */
.jitheme-custom-nav .icon-btn.c-notify.has-msg,
.jitheme-custom-nav .icon-btn.c-notify.has-msg a,
.jitheme-custom-nav .icon-btn.c-notify.has-msg a svg {
    color: #ef4444;
}

/* 有未读消息：铃铛图标左右晃动提醒（以顶部为轴摆动，更接近真实铃铛） */
@keyframes jitheme-bell-shake {
    0%, 100% { transform: rotate(0deg); }
    20%      { transform: rotate(14deg); }
    40%      { transform: rotate(-11deg); }
    60%      { transform: rotate(7deg); }
    80%      { transform: rotate(-4deg); }
}
.jitheme-custom-nav .icon-btn.c-notify.has-msg svg {
    animation: jitheme-bell-shake 1.1s ease-in-out infinite;
    transform-origin: top center;
}

/* 通用右上角角标圆点：通知红点 / 签到绿点共用的定位与外观基类 */
.ji-corner-dot {
    position: absolute;
    top: -2px;
    right: -2px;
    width: 8px;
    height: 8px;
    border-radius: 50%;
    border: 1px solid #fff;
    box-sizing: content-box;
    z-index: 2;
}
/* 通知铃铛红点（带脉冲动画，位于按钮右上角） */
.jitheme-custom-nav .icon-btn .badge-dot {
    background: #ef4444;
    animation: jitheme-pulse 1.8s infinite;
}

/* 签到按钮徽标：未签到 = 绿色脉冲圆点；已签到 = 绿色圆底白勾（按钮整体变绿） */
.jitheme-custom-nav .jitheme-sign-btn .sign-badge {
    background: #10b981;
}
/* 未签到：右上角绿色脉冲光晕 */
.jitheme-custom-nav .jitheme-sign-btn .sign-badge::before {
    content: '';
    position: absolute;
    inset: -3px;
    border-radius: 50%;
    background: #10b981;
    opacity: 0.5;
    animation: jitheme-sign-halo 1.8s ease-out infinite;
    z-index: -1;
}
@keyframes jitheme-sign-halo {
    0%   { transform: scale(1); opacity: 0.5; }
    70%  { transform: scale(2); opacity: 0; }
    100% { transform: scale(2); opacity: 0; }
}
/* 已签到：按钮整体变绿（图标绿色 + 浅绿背景）
   用完整祖先链提升特异性，压过父主题 .icon-btn 基础色 */
/* 已签到：徽章隐藏 + 按钮变绿 */
.jitheme-custom-nav .jitheme-sign-btn .sign-badge.active {
    display: none;
}
.jitheme-custom-nav .jitheme-sign-btn.active {
    color: #10b981 !important;
}
.jitheme-custom-nav .jitheme-sign-btn.active svg {
    stroke: #10b981;
}
@keyframes jitheme-pulse {
    0%   { box-shadow: none; }
    70%  { box-shadow: none; }
    100% { box-shadow: none; }
}

/* 暗夜模式 */
[data-theme="dark"] .jitheme-custom-nav .header-user .icon-btn,
[data-theme="dark"] .jitheme-custom-nav .icon-btn {
    background: #24262c;
    color: #c3cde0;
}
[data-theme="dark"] .jitheme-custom-nav .icon-btn:hover {
    background: #2f3238;
    color: #f2f3f5;
    box-shadow: none;
}
[data-theme="dark"] .jitheme-custom-nav .icon-btn.c-calendar:hover { color: #5b8bff; }
[data-theme="dark"] .jitheme-custom-nav .icon-btn.c-add:hover      { color: #818cf8; }
[data-theme="dark"] .jitheme-custom-nav .icon-btn.c-notify:hover   { color: #f87171; }
[data-theme="dark"] .jitheme-custom-nav .icon-btn.c-vip:hover      { color: var(--gold); }
[data-theme="dark"] .jitheme-custom-nav .icon-btn.c-dark:hover     { color: #a78bfa; }
/* 暗夜：有未读消息时铃铛图标变 hover 色（作用到内层 a） */
[data-theme="dark"] .jitheme-custom-nav .icon-btn.c-notify.has-msg,
[data-theme="dark"] .jitheme-custom-nav .icon-btn.c-notify.has-msg a,
[data-theme="dark"] .jitheme-custom-nav .icon-btn.c-notify.has-msg a svg { color: #f87171; }
/* 暗夜：顶栏搜索框适配深色（容器 + form 背景） */
[data-theme="dark"] .jitheme-custom-nav .top-search,
[data-theme="dark"] .jitheme-custom-nav .top-search form.mobile-search-input {
    background: #24262c;
    border-color: #2f3238;
}
/* 暗夜：聚焦时保持深色背景（B2 默认聚焦会变白，这里强制覆盖） */
[data-theme="dark"] .jitheme-custom-nav .top-search:focus-within,
[data-theme="dark"] .jitheme-custom-nav .top-search form.mobile-search-input:focus-within {
    background: #24262c;
    border-color: #2f3238;
    box-shadow: none;
}
[data-theme="dark"] .jitheme-custom-nav .top-search .top-search-select {
    color: var(--text-muted);
    border-color: #2f3238;
}
[data-theme="dark"] .jitheme-custom-nav .top-search .search-input,
[data-theme="dark"] .jitheme-custom-nav .top-search .search-input::placeholder,
[data-theme="dark"] .jitheme-custom-nav .top-search .search-button-action {
    color: var(--text-muted);
}
[data-theme="dark"] .jitheme-custom-nav .icon-btn .badge-dot,
body.dark .jitheme-custom-nav .icon-btn .badge-dot { border-color: #24262c; }

[data-theme="dark"] .jitheme-custom-nav .jitheme-sign-btn .sign-badge,
body.dark .jitheme-custom-nav .jitheme-sign-btn .sign-badge { border-color: #24262c; }

.jitheme-custom-nav .icon-btn button,
.jitheme-custom-nav .icon-btn > span {
    background: none;
    border: 0;
    padding: 0;
    cursor: pointer;
    margin: 0;
}

.jitheme-custom-nav .jitheme-vip-btn {
    position: relative;
    cursor: pointer;
}

.jitheme-custom-nav .jitheme-vip-btn a {
    color: #d4a358;
    display: flex;
    align-items: center;
    justify-content: center;
}

.jitheme-custom-nav .jitheme-vip-btn a i {
    font-size: var(--fs-md);
}

.jitheme-custom-nav .jitheme-vip-btn:hover {
    background: var(--bg-card);
}

.jitheme-custom-nav .jitheme-vip-btn .jitheme-cnav-popup {
    left: auto !important;
    right: 0;
    top: calc(100% + 10px);
    bottom: auto;
    margin: 0;
    transform: translateY(-6px);
    width: 520px;
    max-width: calc(100vw - 40px);
}

.jitheme-custom-nav .jitheme-vip-btn:hover .jitheme-cnav-popup {
    opacity: 1;
    visibility: visible;
    transform: translateY(0);
    pointer-events: auto;
}

.jitheme-custom-nav .jitheme-vip-btn .jitheme-cnav-popup::before {
    left: auto !important;
    right: 16px;
    top: -6px;
    bottom: auto;
    transform: rotate(45deg);
    box-shadow: none;
}

.jitheme-custom-nav .jitheme-vip-btn .vip-header {
    flex-wrap: nowrap;
    gap: 12px;
}

.jitheme-custom-nav .jitheme-vip-btn .vip-action-btn {
    white-space: nowrap;
    padding: 10px 20px;
}

.ji-fav-overlay {
    display: none;
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: transparent;
    z-index: 2;
}

.ji-fav-overlay.ji-fav-open {
    display: block;
}

.ji-fav-sidebar {
    position: fixed;
    left: 104px;
    top: 72px;
    width: 340px;
    max-height: calc(100vh - 130px);
    background: var(--bg-card);
    border-radius: var(--b2radius);
    border: 1px solid var(--border-light);
    display: flex;
    flex-direction: column;
    overflow: hidden;
    animation: jiSlideInLeft 0.25s cubic-bezier(0.16,1,0.3,1);
}

@keyframes jiSlideInLeft {
    from {
        transform: translateX(-16px);
        opacity: 0;
    }

    to {
        transform: translateX(0);
        opacity: 1;
    }
}

.ji-fav-sidebar-head {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 16px 18px;
    border-bottom: 1px solid var(--border-color);
    background: var(--bg-subtle);
    flex-shrink: 0;
    gap: 8px;
}

.ji-fav-sidebar-title {
    font-size: var(--fs-base);
    color: var(--text-primary);
    display: flex;
    align-items: center;
    gap: 8px;
}

.ji-fav-sidebar-title svg {
    width: 18px;
    height: 18px;
    fill: var(--gold);
    flex-shrink: 0;
}
.ji-fav-sidebar-close {
    width: 28px;
    height: 28px;
    border-radius: 50%;
    border: none;
    background: var(--bg-subtle);
    color: var(--text-secondary);
    font-size: var(--fs-base);
    cursor: pointer;
    display: flex;
    justify-content: center;
    align-items: center;
    transition: background 0.2s,color 0.2s;
    padding: 0;
    flex-shrink: 0;
}
.ji-fav-sidebar-close i {
    font-size: var(--fs-base);
    line-height: 1;
}

.ji-fav-sidebar-close:hover {
    background: var(--border-color);
    color: var(--text-primary);
}

@media (max-width: 640px) {
    .ji-fav-sidebar {
        left:8px;
        width: 320px;
        top: 60px;
        max-height: calc(100vh - 90px);
    }
}

.jis2-item {
    display: flex;
    align-items: stretch;
    gap: 10px;
    padding: 10px 12px;
    border-radius: var(--b2radius);
    border: 1px solid var(--bg-subtle);
    background: var(--bg-card);
    text-decoration: none;
    color: inherit;
    margin-bottom: 8px;
    transition: all 0.2s ease;
    position: relative;
}

.jis2-item:hover {
    border-color: var(--border-light);
    box-shadow: none;
}

.jis2-thumb {
    width: 96px;
    height: 64px;
    flex-shrink: 0;
    border-radius: var(--b2radius);
    overflow: hidden;
    background: var(--bg-subtle);
    display: flex;
    align-items: center;
    justify-content: center;
}

.jis2-thumb img {
    width: 100%;
    height: 100%;
    object-fit: cover;
}

.jis2-thumb.jis2-thumb-square {
    width: 64px;
    height: 64px;
}

.jis2-body {
    flex: 1;
    min-width: 0;
    display: flex;
    flex-direction: column;
    justify-content: space-between;
    height: 64px;
}

.jis2-no-thumb .jis2-body {
    height: auto;
    min-height: 64px;
}

.jis2-title {
    font-size: var(--fs-sm);
    color: var(--text-primary);
    line-height: 1.3;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
}

.jis2-desc {
    font-size: var(--fs-xs);
    color: var(--text-secondary);
    line-height: 1.4;
    margin-top: 2px;
    flex: 1;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
}

.jis2-foot {
    display: flex;
    align-items: center;
    justify-content: space-between;
    margin-top: auto;
    gap: 8px;
    padding-top: 10px;
    border-top: 1px solid var(--bg-subtle);
    text-align: center;
    flex-shrink: 0;
}

.jis2-meta {
    display: flex;
    align-items: center;
    gap: 5px;
    font-size: var(--fs-xs);
    color: var(--text-muted);
    min-width: 0;
    overflow: hidden;
    white-space: nowrap;
}

.jis2-tag {
    font-size: var(--fs-xs);
    padding: 1px 5px;
    border-radius: 3px;
    background: var(--bg-card-hover);
    color: var(--text-primary);
    flex-shrink: 0;
}

.jis2-dot {
    width: 2px;
    height: 2px;
    border-radius: 50%;
    background: var(--border-light);
    flex-shrink: 0;
}

.jis2-unfav {
    color: var(--border-light);
    cursor: pointer;
    display: flex;
    align-items: center;
    padding: 2px;
    opacity: 0;
    transition: all 0.15s ease;
    flex-shrink: 0;
    background: none;
    border: none;
}

.jis2-item:hover .jis2-unfav {
    opacity: 1;
}

.jis2-unfav:hover {
    color: #f43f5e;
}

.jis2-unfav svg {
    width: 13px;
    height: 13px;
}

.jis2-head-acts {
    display: flex;
    align-items: center;
    gap: 4px;
    margin-left: 2px;
    flex-shrink: 0;
}

.jis2-act {
    width: 26px;
    height: 26px;
    border-radius: var(--b2radius);
    background: var(--bg-subtle);
    color: var(--text-secondary);
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    transition: all 0.15s ease;
    flex-shrink: 0;
}

.jis2-act:hover {
    background: var(--border-light);
    color: var(--text-primary);
}

.jis2-act.active {
    background: var(--bg-primary-soft);
    color: var(--text-primary);
}

.jis2-act svg {
    width: 14px;
    height: 14px;
}

.jis2-widget {
    display: none;
    flex-direction: column;
    flex: 1;
    min-height: 0;
    padding: 10px 12px 12px;
    overflow: hidden;
}

.jis2-searchbar {
    max-height: 0;
    opacity: 0;
    overflow: hidden;
    transition: all 0.25s ease;
    flex-shrink: 0;
}

.jis2-searchbar.open {
    max-height: 60px;
    opacity: 1;
    margin-bottom: 8px;
}

.jis2-search-wrap {
    display: flex;
    align-items: center;
    gap: 8px;
    background: var(--bg-subtle);
    border: 1px solid var(--border-light);
    border-radius: 14px;
    padding: 6px 10px;
    transition: border-color 0.15s ease,box-shadow 0.15s ease;
}

.jis2-search-wrap:focus-within {
    border-color: var(--text-primary);
    box-shadow: none;
}

.jis2-search-wrap svg {
    width: 14px;
    height: 14px;
    color: var(--text-muted);
    flex-shrink: 0;
}

.jis2-search-input {
    flex: 1;
    border: none;
    outline: none;
    background: transparent;
    font-size: var(--fs-xs);
    color: var(--text-primary);
    min-width: 0;
}

.jis2-search-input::placeholder {
    color: var(--border-light);
}

.jis2-search-clear {
    display: none;
    align-items: center;
    justify-content: center;
    background: none;
    border: none;
    color: var(--border-light);
    cursor: pointer;
    padding: 0;
    flex-shrink: 0;
}

.jis2-search-clear:hover {
    color: var(--text-secondary);
}

.jis2-search-clear svg {
    width: 12px;
    height: 12px;
}

.jis2-tabs {
    display: flex;
    gap: 4px;
    padding: 5px 0 8px;
    border-bottom: 1px solid var(--bg-subtle);
    flex-shrink: 0;
    overflow-x: auto;
    scrollbar-width: none;
    position: relative;
    flex-direction: row;
    justify-content: space-between;
}

.jis2-tabs::-webkit-scrollbar {
    display: none;
}

.jis2-tab {
    padding: 4px 10px;
    font-size: var(--fs-sm);
    color: var(--text-secondary);
    background-color: transparent;
    border: none;
    border-radius: var(--b2radius);
    cursor: pointer;
    white-space: nowrap;
    transition: all 0.15s ease;
    position: relative !important;
    z-index: 1;
    user-select: none;
}

.jis2-tab:hover {
    background: var(--bg-subtle);
    color: var(--text-primary);
}

.jis2-tab.active {
    background: var(--bg-card-hover);
    color: var(--text-primary);
}

.jis2-tab-badge {
    position: absolute;
    top: -3px;
    right: -3px;
    min-width: 14px;
    height: 14px;
    padding: 0 3px;
    border-radius: var(--b2radius);
    background: #ef4444;
    color: #ffffff;
    font-size: 9px;
    line-height: 14px;
    text-align: center;
    pointer-events: none;
    z-index: 11111;
}

.jis2-list {
    flex: 1;
    min-height: 0;
    overflow-y: auto;
    padding: 10px 0 4px;
    display: flex;
    flex-direction: column;
}

.jis2-list::-webkit-scrollbar {
    width: 4px;
}

.jis2-list::-webkit-scrollbar-track {
    background: transparent;
}

.jis2-list::-webkit-scrollbar-thumb {
    background: var(--border-color);
    border-radius: 2px;
}

.jis2-empty {
    text-align: center;
    padding: 30px 10px;
    color: var(--text-muted);
    font-size: var(--fs-xs);
    line-height: 1.5;
}

.jis2-pagination {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 4px;
    padding: 6px 0 2px;
    flex-shrink: 0;
}

.jis2-page-btn {
    min-width: 24px;
    height: 24px;
    padding: 0 5px;
    font-size: var(--fs-xs);
    color: var(--text-secondary);
    background: var(--bg-card);
    border: 1px solid var(--border-light);
    border-radius: var(--b2radius);
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    transition: all 0.15s ease;
}

.jis2-page-btn:hover:not(:disabled) {
    border-color: var(--border-light);
    color: var(--text-primary);
    background: var(--bg-subtle);
}

.jis2-page-btn.active{
    background: var(--b2color);
    color: #ffffff;
}

.jis2-page-btn:disabled {
    color: var(--border-light);
    cursor: not-allowed;
    background: var(--bg-subtle);
}

.jis2-foot-link {
    font-size: var(--fs-xs);
    color: var(--text-secondary);
    text-decoration: none;
    transition: color 0.2s;
}

.jis2-foot-link:hover {
    color: var(--text-primary);
}

@media (max-width: 600px) {
    .jis2-head-acts {
        margin-left:0;
    }
}

.jis2-skeleton {
    display: flex;
    align-items: stretch;
    gap: 10px;
    padding: 10px 0;
}

.jis2-sk-thumb,.jis2-sk-title,.jis2-sk-desc,.jis2-sk-meta {
    background: linear-gradient(90deg,#f1f5fb 25%,#e4e9f2 37%,#f1f5fb 63%);
    background-size: 400% 100%;
    animation: jis2Shimmer 1.4s ease infinite;
    border-radius: 4px;
}

.jis2-sk-thumb {
    width: 96px;
    height: 64px;
    border-radius: var(--b2radius);
    flex-shrink: 0;
}

.jis2-sk-body {
    flex: 1;
    display: flex;
    flex-direction: column;
    gap: 8px;
    justify-content: center;
    min-width: 0;
}

.jis2-sk-title {
    height: 12px;
    width: 78%;
}

.jis2-sk-desc {
    height: 10px;
    width: 95%;
}

.jis2-sk-meta {
    height: 10px;
    width: 55%;
}

@keyframes jis2Shimmer {
    0% {
        background-position: 100% 0;
    }

    100% {
        background-position: -100% 0;
    }
}

/* =============================================
   侧栏菜单入口公共样式（sb-item / sb-group-title / sb-category-entry 统一）
   修改间距/圆角/字号等公共属性只需改 .sb-entry 一处
   ============================================= */
.sb-entry {
    position: relative;
    display: flex;
    align-items: center;
    gap: 7px;
    width: 100%;
    padding: 10px;
    border-radius: var(--b2radius);
    font-size: var(--fs-xs);
    white-space: nowrap;
    cursor: pointer;
    transition: background 0.2s, color 0.2s;
    margin-bottom: 2px;
}

.sb-entry:hover {
    background: var(--bg-subtle);
}

/* 普通菜单项（在公共样式上的差异） */
.sb-item {
    color: var(--text-secondary);
    text-decoration: none;
}

.sb-item.active {
    color: var(--text-primary);
    background: var(--bg-subtle);
}

.sb-icon {
    flex: 0 0 22px;
    width: 22px;
    height: 22px;
    display: flex;
    align-items: center;
    justify-content: center;
    color: var(--text-primary);
}

.sb-icon svg {
    width: var(--fs-xs);
    height: var(--fs-xs);
}

.sb-icon i {
    font-size: var(--fs-sm);
    font-style: normal;
}

.sb-label {
    flex: 1;
    overflow: hidden;
    text-overflow: ellipsis;
    line-height: 1.4;
}

.sb-badge,.sb-entry .b2small {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    height: 18px;
    padding: 0 6px;
    border-radius: var(--b2radius);
    font-size: var(--fs-xs);
    line-height: 1;
    color: #fff;
    flex: 0 0 auto;
    white-space: nowrap;
}

.sb-badge.badge-red,.sb-entry .shop-tips1 {
    background: #ff4d4f;
}

.sb-badge.badge-orange,.sb-entry .shop-tips2 {
    background: var(--orange);
}

.sb-badge.badge-green,.sb-entry .shop-tips3 {
    background: #10b981;
}

.sb-badge.badge-blue,.sb-entry .shop-tips4 {
    background: #1890ff;
}

.sb-badge.badge-purple,.sb-entry .shop-tips5 {
    background: #722ed1;
}

.sb-badge.badge-pink,.sb-entry .shop-tips6 {
    background: #eb2f96;
}

.sb-group {
    margin-top: 0px;
    position: relative;
    width: 100%;
    color: var(--text-secondary);
}

/* 分组入口（在公共样式上的差异） */
.sb-group-title .sb-badge {
    margin-left: auto;
}

.sb-arrow {
    margin-left: auto;
    width: 16px;
    height: 16px;
    color: var(--text-muted);
    display: flex;
    align-items: center;
    justify-content: center;
    flex: 0 0 16px;
}

.sb-arrow svg {
    width: var(--fs-xs);
    height: var(--fs-xs);
}

.sb-arrow i {
    font-size: var(--fs-sm);
    font-style: normal;
    line-height: 1;
}

.sb-group-title .sb-arrow {
    margin-left: 8px;
}

.sb-sub {
    margin-left: 24px;
    border-left: 1px solid var(--border-color);
    padding-left: 12px;
    display: flex;
    flex-direction: column;
    gap: 2px;
}

.sb-sub .sb-item {
    font-size: var(--fs-xs);
    color: var( --text-secondary);
    padding: 8px 10px;
}

.sb-sub .sb-item:hover {
    color: var(--text-primary);
    background: var(--bg-input);
    border-radius: var(--b2radius);
}

/* 暗夜模式：菜单 hover 背景与按钮暗夜底色一致 */
[data-theme="dark"] .jitheme-cnav .cnav-item:hover,
[data-theme="dark"] .jitheme-cnav .cnav-item.active {
    background: #24262c;
    color: #f2f3f5;
}
[data-theme="dark"] .jitheme-cnav .menu-toggle-btn:hover {
    background: #24262c;
}
[data-theme="dark"] .sb-sub .sb-item:hover {
    background: #24262c;
    color: #f2f3f5;
}

.sb-sub .sb-item .sb-label {
    line-height: inherit;
}
.sb-sub .sb-sub-item {
    margin-left: 14px;
}

.sb-category {
    margin-top: 10px;
    position: relative;
    width: 100%;
    color: var(--text-secondary);
}

/* 分类入口（在公共样式上的差异） */
.sb-category-entry {
    flex-direction: row;
    align-content: center;
}

.sb-category-entry:hover {
    background: var(--bg-subtle);
}

.sb-category-entry .sb-badge {
    margin-left: auto;
}

.sb-category-panel {
    position: fixed;
    left: 0;
    top: 0;
    width: 640px;
    background: var(--bg-card);
    border-radius: var(--b2radius);
    box-shadow: none;
    opacity: 0;
    visibility: hidden;
    transform: translateX(-8px);
    transition: opacity 0.18s,transform 0.18s,visibility 0.18s;
    z-index: 999;
    pointer-events: none;
    overflow: hidden;
}

.sb-category-panel.show {
    opacity: 1;
    visibility: visible;
    transform: translateX(0);
    pointer-events: auto;
}

body.dark .sb-category-panel {
    box-shadow: none;
}

.sb-cat-tabs {
    display: flex;
    gap: 24px;
    padding: 14px 20px 0;
    border-bottom: 1px solid var(--border-color);
}

.sb-cat-tab {
    position: relative;
    padding: 8px 0 12px;
    font-size: var(--fs-base);
    color: var(--text-secondary);
    cursor: pointer;
    transition: color 0.2s;
    white-space: nowrap;
    background: none;
    border: none;
    font-family: inherit;
}

.sb-cat-tab:hover {
    color: var(--text-primary);
}

.sb-cat-tab.active {
    color: var(--text-primary);
}

.sb-cat-tab.active::after {
    content: "";
    position: absolute;
    left: 0;
    right: 0;
    bottom: 0;
    height: 2px;
    background: var(--b2color);
    border-radius: 1px;
}

.sb-cat-body {
    padding: 16px 20px 20px;
    min-height: 120px;
}

.sb-cat-pane {
    display: none;
}

.sb-cat-pane.active {
    display: flex;
    flex-wrap: wrap;
    align-items: flex-start;
    gap: 28px;
}

.sb-cat-group {
    min-width: 100px;
    display: flex;
    flex-direction: column;
    align-items: center;
}

.sb-cat-group-title {
    display: flex;
    align-items: center;
    gap: 6px;
    font-size: var(--fs-sm);
    color: var( --text-primary);
    margin-bottom: 10px;
}

.sb-cat-group-title .sb-arrow {
    margin-left: auto;
    width: 14px;
    height: 14px;
    color: var(--text-muted);
    display: inline-flex;
    display: none;
    align-items: center;
    justify-content: center;
    flex: 0 0 14px;
}

.sb-cat-group-title .sb-arrow svg {
    width: 14px;
    height: 14px;
}

.sb-cat-list {
    list-style: none;
    display: flex;
    flex-direction: column;
    gap: 4px;
    margin-bottom: 14px;
}

.sb-cat-list li a {
    display: block;
    padding: 8px 10px;
    border-radius: var(--b2radius);
    font-size: var(--fs-xs);
    color: var( --text-secondary);
    text-decoration: none;
    transition: background 0.2s,color 0.2s;
}

.sb-cat-list li a:hover {
    background: var(--bg-subtle);
    color: var(--text-primary);
}

.jitheme-cnav:not(.layout-row) .sb-entry {
    flex-direction: column;
    gap: 4px;
    padding: 10px 4px 12px;
    justify-content: center;
    text-align: center;
    position: relative;
}

.jitheme-cnav:not(.layout-row) .sb-label {
    line-height: 1.2;
    flex: none;
    white-space: nowrap;
    max-width: 100%;
    overflow: hidden;
    text-align: center;
}

.jitheme-cnav:not(.layout-row) .sb-icon {
    flex: 0 0 22px;
    margin: 0 auto;
}

.jitheme-cnav:not(.layout-row) .sb-arrow {
    position: absolute;
    top: 20px;
    right: -5px;
    margin: 0;
    width: var(--fs-sm);
    height: var(--fs-sm);
}

.jitheme-cnav:not(.layout-row) .sb-category-entry .sb-arrow {
    top: 20px;
    right: -5px;
}

.jitheme-cnav:not(.layout-row) .sb-arrow svg {
    width: var(--fs-xs);
    height: var(--fs-xs);
}

.jitheme-cnav:not(.layout-row) .sb-badge,.jitheme-cnav:not(.layout-row) .sb-entry .b2small,.jitheme-cnav:not(.layout-row) .sb-entry .badge {
    position: absolute;
    top: 4px;
    right: 4px;
    bottom: auto;
    left: auto;
    transform: none;
    margin: 0;
    height: 14px;
    line-height: 14px;
    padding: 0 5px;
    border-radius: 4px;
    font-size: 9px;
}

.jitheme-cnav:not(.layout-row) .sb-group-title .sb-badge {
    top: 4px;
    right: 4px;
    bottom: auto;
    left: auto;
    transform: none;
}

.jitheme-cnav:not(.layout-row) .sb-category-entry .b2small {
    position: absolute;
    top: 0;
    right: 0;
    transform: translateX(-50%);
    margin: 0;
    height: 14px;
    padding: 0 5px;
    border-radius: var(--b2radius);
    font-size: 9px;
}

.jitheme-cnav:not(.layout-row) .sb-sub {
    display: none;
}

.jitheme-cnav.layout-row .sb-entry {
    flex-direction: row;
}

.jitheme-cnav .sb-entry:hover {
    background: var(--bg-subtle);
}

.jitheme-cnav.layout-row :hover.sb-label {
    color: var(--text-primary);
}

.jitheme-cnav.layout-row .sb-entry .sb-label {
    flex: 1 1 auto;
    min-width: 0;
}

.jitheme-cnav.layout-row .sb-icon {
    flex: 0 0 20px;
    width: 20px;
    height: 20px;
}

.jitheme-cnav.layout-row .sb-icon svg {
    width: var(--fs-xs);
    height: var(--fs-xs);
}

.jitheme-cnav.layout-row .sb-icon i {
    font-size: var(--fs-sm);
    color: var(--text-secondary);
}

.jitheme-cnav.layout-row .sb-label {
    font-size: inherit;
}

.jitheme-cnav.layout-row .sb-sub {
    margin-left: 20px;
    padding-left: 5px;
}

.jitheme-cnav.layout-row .sb-sub .sb-item {
    gap: 4px;
    padding: 8px 5px;
}

.jitheme-cnav.layout-row .sb-sub .sb-item .sb-icon {
    flex: 0 0 16px;
    width: 16px;
    height: 16px;
}

.jitheme-cnav.layout-row .sb-sub .sb-item .sb-icon i {
    font-size: var(--fs-sm);
    margin-right: 5px;
}

.jitheme-cnav.layout-row .sb-sub .sb-item .sb-label {
    flex: 1 1 auto;
    min-width: 0;
}

.jitheme-custom-nav .layout-row .jitheme-cnav-nav .b2small {
    position: absolute;
    top: 0px;
    right: 30px;
    margin: 0;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    transform: none;
    line-height: 1;
    border-radius: 4px;
}

.jitheme-cnav.layout-row .sb-sub .sb-item .b2small {
    position: static;
    top: 0px;
    right: 30px;
    margin: 0;
    height: 14px;
    padding: 0 4px;
    font-size: 9px;
    transform: none;
}

.sb-category-panel::before,.sb-popup::before {
    content: '';
    position: absolute;
    left: -8px;
    top: 50%;
    transform: translateY(-50%);
    border: 1px solid transparent;
    border-left: 0;
    border-right-color: var(--bg-card);
}

.sb-category-panel.show::before,.sb-popup.show::before {
    border-right-color: var(--bg-card);
}

body.dark .sb-cat-tab {
    color: var(--text-secondary);
}

body.dark .sb-cat-tab:hover {
    color: var(--text-primary);
}

body.dark .sb-cat-tab.active {
    color: var(--text-primary);
}

body.dark .sb-cat-tab.active::after {
    background: var(--b2color);
}

body.dark .jitheme-cnav .sb-category-panel .sb-cat-tab {
    color: var(--text-secondary);
}

body.dark .jitheme-cnav .sb-category-panel .sb-cat-tab:hover {
    color: var(--text-primary);
}

body.dark .jitheme-cnav .sb-category-panel .sb-cat-tab.active {
    color: var(--text-primary);
}

body.dark .jitheme-cnav .sb-category-panel .sb-cat-list li a {
    color: var(--text-secondary);
}

body.dark .jitheme-cnav .sb-category-panel .sb-cat-list li a:hover {
    color: var(--text-primary);
}

.sb-popup {
    position: fixed;
    left: 96px;
    background: var(--bg-card);
    color: var(--text-primary);
    border-radius: var(--b2radius);
    box-shadow: none;
    padding: 8px;
    min-width: 180px;
    opacity: 0;
    visibility: hidden;
    transform: translateX(-8px);
    transition: opacity 0.18s,transform 0.18s,visibility 0.18s;
    z-index: 9999;
    pointer-events: none;
}

.sb-popup.show {
    opacity: 1;
    visibility: visible;
    transform: translateX(0);
    pointer-events: auto;
}

body.dark .sb-popup {
    box-shadow: none;
}

.sb-popup-item {
    display: flex;
    align-items: center;
    gap: 12px;
    padding: 10px 14px;
    border-radius: var(--b2radius);
    font-size: var(--fs-xs);
    color: var(--text-secondary);
    text-decoration: none;
    white-space: nowrap;
    transition: background 0.2s;
}

.sb-popup-item:hover {
    background: var(--bg-subtle);
    color: var(--text-primary);
}

.sb-popup-item .sb-badge {
    margin-left: auto;
}

/* ============ 4 LOGO switch ============ */
/* standard header-logo: desktop(left/right sidebar) -> rect, narrow(top-bottom) -> square; day=black, night=white */
.header-logo .jitheme-logo-rect,
.header-logo .jitheme-logo-square { display: none !important; }
.header-logo .jitheme-logo-rect.block-logo { display: inline-block !important; }
[data-theme="dark"] .header-logo .jitheme-logo-rect.block-logo,
[data-theme="dark"] .header-logo .jitheme-logo-square.block-logo { display: none !important; }
[data-theme="dark"] .header-logo .jitheme-logo-rect.light-logo { display: inline-block !important; }
@media (max-width: 992px) {
    .header-logo .jitheme-logo-rect.block-logo,
    [data-theme="dark"] .header-logo .jitheme-logo-rect.light-logo { display: none !important; }
    .header-logo .jitheme-logo-square.block-logo { display: inline-block !important; }
    [data-theme="dark"] .header-logo .jitheme-logo-square.light-logo { display: inline-block !important; }
}
/* cnav sidebar nav: narrow=square, wide=rect; day=black, night=white */
.jitheme-cnav .jitheme-cnav-logo .light-logo { display: none !important; }
[data-theme="dark"] .jitheme-cnav .jitheme-cnav-logo .block-logo { display: none !important; }
[data-theme="dark"] .jitheme-cnav:not(.layout-row) .jitheme-cnav-logo .cnav-logo-narrow.light-logo { display: block !important; }
[data-theme="dark"] .jitheme-cnav.layout-row .jitheme-cnav-logo .cnav-logo-wide.light-logo { display: block !important; }
.jitheme-cnav .jitheme-cnav-logo .cnav-logo-wide { height: 36px; width: auto; max-width: 150px; }

/* =============================================
   用户弹出信息面板（新设计：卡片式 user-popup）
   ============================================= */
.jitheme-user-popup {
    width: 340px !important;
    padding: 16px 18px !important;
    background: var(--bg-card);
    border-radius: var(--b2radius);
    box-shadow: none;
    z-index: 9999;
}

/* ---------- 顶部用户信息 ---------- */
.jitheme-user-popup .user-header {
    display: flex;
    align-items: center;
    gap: 10px;
    margin-bottom: 14px;
    position: relative;
}
.jitheme-user-popup .user-avatar {
    width: 44px;
    height: 44px;
    border-radius: 50%;
    object-fit: cover;
    flex-shrink: 0;
    border: 1px solid #fff;
    box-shadow: none;
}
.jitheme-user-popup .user-info {
    flex: 1;
    min-width: 0;
}
.jitheme-user-popup .user-name {
    font-size: var(--fs-md);
    color: #1a1d21;
    margin-bottom: 4px;
    display: flex;
    /* line-height: 1.2; */
    flex-direction: row;
    align-items: center;
}
/* 弹窗头像：认证角标叠加在右下角 */
.jitheme-user-popup .user-avatar-wrap {
    position: relative;
    flex-shrink: 0;
}
.jitheme-user-popup .user-avatar-wrap .user-avatar-verify {
    position: absolute;
    right: 5px;
    bottom: 5px;
    display: flex;
    align-items: center;
    justify-content: center;
    z-index: 2;
    line-height: 1;
}
.jitheme-user-popup .user-avatar-wrap .user-avatar-verify i {
    font-size: var(--fs-base);
    line-height: 1;
    color: var(--primary);
}
/* 已认证角标说明（认证图标 + 已认证） */
.jitheme-user-popup .user-name .user-verify {
    display: inline-flex;
    align-items: center;
    gap: 3px;
    margin-left: 6px;
    padding: 2px 8px;
    border-radius: 4px;
    background: rgba(47, 107, 255, 0.1);
    color: var(--primary);
    font-size: 10px;
    /* font-weight: 600; */
    /* line-height: 1.4; */
    vertical-align: middle;
    flex-direction: row;
}
.jitheme-user-popup .user-name .user-verify i {
    font-size: var(--fs-base);
    line-height: 1;
    margin-right: 1px;
}
.jitheme-user-popup .user-name .user-verify em {
    font-style: normal;
}
.jitheme-user-popup .user-badges {
    display: flex;
    align-items: center;
    gap: 6px;
    flex-wrap: wrap;
}
.jitheme-user-popup .badge-diamond {
    display: inline-flex;
    align-items: center;
    gap: 4px;
    line-height: 1;
    font-size: var(--fs-xs);
    letter-spacing: 0.2px;
    background: transparent !important;
    padding: 0 !important;
    border: none !important;
    border-radius: 0 !important;
}
.jitheme-user-popup .badge-level {
    display: inline-flex;
    align-items: center;
    line-height: 1;
    font-size: var(--fs-xs);
    font-size: 10px;
    letter-spacing: 0.3px;
    background: transparent !important;
    padding: 0 !important;
    border: none !important;
    border-radius: 0 !important;
}
.jitheme-user-popup .badge-diamond img,
.jitheme-user-popup .badge-level img {
    height: 14px;
    width: auto;
}
/* 退出按钮 */
.jitheme-user-popup .logout-btn {
    width: 28px;
    height: 28px;
    min-width: 28px;
    min-height: 28px;
    border-radius: 50%;
    border: 1px solid var(--border-color);
    background: var(--bg-card);
    display: flex;
    align-items: center;
    justify-content: center;
    cursor: pointer;
    color: var(--text-muted);
    transition: all .2s;
    flex-shrink: 0;
    margin: 0;
    position: relative;
    z-index: 5;
}
.jitheme-user-popup .logout-btn:hover {
    background: var(--bg-input);
    color: #d9001b;
    border-color: #ffd0d0;
}
.jitheme-user-popup .logout-btn a {
    color: inherit;
    display: flex;
}
.jitheme-user-popup .logout-btn i {
    font-size: var(--fs-md);
    line-height: 1;
}
.jitheme-user-popup .logout-btn svg {
    width: 16px;
    height: 16px;
}
/* ---------- 数据统计（与用户小工具四项统计同风格） ---------- */
.jitheme-user-popup .user-stats {
    display: grid;
    grid-template-columns: repeat(4, 1fr);
    gap: 8px;
    margin-bottom: 12px;
    position: relative;
}
.jitheme-user-popup .stat-item {
    text-align: center;
    position: relative;
    background: var(--bg-card-hover);
    border-radius: 8px;
    padding: 12px 0;
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 3px;
    transition: all .2s ease;
    cursor: pointer;
}
.jitheme-user-popup .stat-item:hover {
    background: var(--bg-primary-soft);
    transform: translateY(-2px);
}
.jitheme-user-popup .stat-label {
    font-size: var(--fs-xs);
    color: #8a919f;
    margin-bottom: 0;
    line-height: 1.2;
    transition: color .2s;
}
.jitheme-user-popup .stat-value {
    font-size: var(--fs-md);
    font-weight: 700;
    color: #1a1d21;
    line-height: 1.2;
    font-variant-numeric: tabular-nums;
    transition: color .2s;
}
.jitheme-user-popup .stat-item:hover .stat-value,
.jitheme-user-popup .stat-item:hover .stat-label {
    color: var(--primary);
}
/* 数字颜色区分（与用户面板一致：文章红/评论蓝/关注绿/粉丝紫） */
.jitheme-user-popup .stat-item:nth-child(1) .stat-value { color: #ef4444; }
.jitheme-user-popup .stat-item:nth-child(2) .stat-value { color: var(--primary); }
.jitheme-user-popup .stat-item:nth-child(3) .stat-value { color: #22c55e; }
.jitheme-user-popup .stat-item:nth-child(4) .stat-value { color: #a855f7; }
/* ---------- 资产区（与用户小工具余额/积分卡同风格） ---------- */
.jitheme-user-popup .user-assets {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 10px;
    margin-bottom: 12px;
}
.jitheme-user-popup .asset-item {
    position: relative;
    background: var(--bg-card-hover);
    border-radius: 12px;
    padding: 12px 14px;
    display: flex;
    align-items: center;
    gap: 8px;
    transition: all .25s ease;
    cursor: pointer;
    overflow: hidden;
}
/* 左侧装饰色条（余额红 / 积分绿，垂直居中） */
.jitheme-user-popup .asset-item::before {
    content: '';
    position: absolute;
    top: 50%;
    left: 0;
    width: 3px;
    height: 16px;
    transform: translateY(-50%);
    border-radius: 0 3px 3px 0;
}
.jitheme-user-popup .asset-item:nth-child(1)::before { background: #f43f5e; }
.jitheme-user-popup .asset-item:nth-child(2)::before { background: #22c55e; }
.jitheme-user-popup .asset-item:hover {
    background: var(--bg-input);
    transform: translateY(-2px);
}
.jitheme-user-popup .asset-item .asset-link {
    position: absolute;
    inset: 0;
    z-index: 2;
}
.jitheme-user-popup .asset-icon {
    width: auto;
    height: auto;
    display: flex;
    align-items: center;
    justify-content: center;
    color: var(--text-muted);
    flex-shrink: 0;
}
.jitheme-user-popup .asset-icon i {
    font-size: var(--fs-md);
    line-height: 1;
}
.jitheme-user-popup .asset-item:nth-child(1) .asset-icon {
    color: #f43f5e;
}
.jitheme-user-popup .asset-item:nth-child(2) .asset-icon {
    color: #22c55e;
}
.jitheme-user-popup .asset-value {
    font-size: var(--fs-md);
    font-weight: 700;
    color: #1a1d21;
    font-variant-numeric: tabular-nums;
}
.jitheme-user-popup .asset-item:nth-child(1) .asset-value {
    color: #e11d48;
}
.jitheme-user-popup .asset-item:nth-child(2) .asset-value {
    color: #16a34a;
}
/* ---------- 任务进度条 ---------- */
.jitheme-user-popup .task-progress {
    background: #f5f6f8;
    border-radius: var(--b2radius);
    padding: 8px 12px;
    margin-bottom: 14px;
}
.jitheme-user-popup .task-text {
    font-size: var(--fs-xs);
    color: var(--text-secondary);
    text-align: center;
    margin-bottom: 6px;
}
.jitheme-user-popup .task-text .highlight {
    color: #1a1d21;
}
.jitheme-user-popup .progress-track {
    height: 6px;
    background: var(--bg-muted);
    border-radius: 3px;
    overflow: hidden;
    position: relative;
}
.jitheme-user-popup .progress-fill {
    height: 100%;
    width: 2%;
    background: linear-gradient(90deg, #a855f7, #7c3aed);
    border-radius: 3px;
    transition: width .3s;
}
/* ---------- 功能菜单网格 ---------- */
.jitheme-user-popup .menu-grid {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 8px 6px;
}
.jitheme-user-popup .menu-item {
    display: flex;
    align-items: center;
    gap: 8px;
    padding: 8px 6px;
    border-radius: var(--b2radius);
    cursor: pointer;
    transition: background .2s;
    position: relative;
}
.jitheme-user-popup .menu-item:hover {
    background: #f5f6f8;
}
.jitheme-user-popup .menu-item > a {
    display: flex;
    align-items: center;
    gap: 8px;
    width: 100%;
    color: inherit;
}
.jitheme-user-popup .menu-icon {
    width: 24px;
    height: 24px;
    display: flex;
    align-items: center;
    justify-content: center;
    flex-shrink: 0;
}
.jitheme-user-popup .menu-icon i {
    font-size: var(--fs-lg);
    line-height: 1;
}
.jitheme-user-popup .menu-icon.c0 { color: #2dce89; }
.jitheme-user-popup .menu-icon.c1 { color: #a855f7; }
.jitheme-user-popup .menu-icon.c2 { color: var(--primary); }
.jitheme-user-popup .menu-icon.c3 { color: var(--gold); }
.jitheme-user-popup .menu-icon.c4 { color: #06b6d4; }
.jitheme-user-popup .menu-icon.c5 { color: #ec4899; }
.jitheme-user-popup .menu-icon.c6 { color: #14b8a6; }
.jitheme-user-popup .menu-icon.c7 { color: #ef4444; }
.jitheme-user-popup .menu-text {
    flex: 1;
    min-width: 0;
}
.jitheme-user-popup .menu-title {
    font-size: var(--fs-sm);
    color: #1a1d21;
    line-height: 1.2;
    display: flex;
    align-items: center;
    gap: 5px;
    flex-wrap: wrap;
}
.jitheme-user-popup .menu-desc {
    font-size: var(--fs-xs);
    color: var(--text-muted);
    margin-top: 2px;
    line-height: 1.2;
}
.jitheme-user-popup .badge-new {
    font-size: var(--fs-xs);
    color: #fff;
    background: #ff3b30;
    padding: 1px 5px;
    border-radius: 3px;
    line-height: 1.4;
    letter-spacing: 0.2px;
}
/* ---------- 暗夜模式 ---------- */
body.dark .jitheme-user-popup {
    background: #1a1c21;
    box-shadow: none;
}
body.dark .jitheme-user-popup .user-name,
body.dark .jitheme-user-popup .stat-value,
body.dark .jitheme-user-popup .asset-value,
body.dark .jitheme-user-popup .menu-title,
body.dark .jitheme-user-popup .task-text .highlight {
    color: #f2f3f5;
}
body.dark .jitheme-user-popup .user-name .user-verify {
    background: rgba(77, 141, 246, 0.16);
    color: #4d8df6;
}
body.dark .jitheme-user-popup .user-avatar-wrap .user-avatar-verify i {
    color: #4d8df6;
}
body.dark .jitheme-user-popup .stat-label,
body.dark .jitheme-user-popup .asset-icon,
body.dark .jitheme-user-popup .task-text,
body.dark .jitheme-user-popup .menu-desc {
    color: var(--text-muted);
}
body.dark .jitheme-user-popup .asset-item:nth-child(1) .asset-icon {
    color: #f5b63d;
}
body.dark .jitheme-user-popup .asset-item:nth-child(2) .asset-icon {
    color: var(--b2color, #2f6bff);
}
body.dark .jitheme-user-popup .logout-btn {
    background: #24262c;
    border-color: #33363c;
    color: var(--text-muted);
}
body.dark .jitheme-user-popup .logout-btn:hover {
    background: #2f3238;
    color: #ff5b5b;
    border-color: #4a2a2a;
}
body.dark .jitheme-user-popup .asset-item,
body.dark .jitheme-user-popup .task-progress,
body.dark .jitheme-user-popup .stat-item {
    background: #24262c;
}
body.dark .jitheme-user-popup .asset-item:hover,
body.dark .jitheme-user-popup .menu-item:hover {
    background: #2f3238;
}
body.dark .jitheme-user-popup .progress-track {
    background: #33363c;
}
body.dark .jitheme-user-popup .user-avatar {
    border-color: #33363c;
}

/* =========================================================
   顶部签到日历弹窗
   ========================================================= */
/* 遮罩层 */
.jitheme-sign-overlay {
    position: fixed;
    inset: 0;
    background: rgba(15, 23, 42, 0.35);
    opacity: 0;
    visibility: hidden;
    transition: opacity .2s;
    z-index: 99990;
}
.jitheme-sign-overlay.show {
    opacity: 1;
    visibility: visible;
}
/* 日历卡片 */
.jitheme-sign-modal {
    position: fixed;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%);
    background: #f5f6f8; /* 浅色背景 */
    border: none; /* 无边框 */
    border-radius: var(--b2radius);
    padding: 24px 20px 20px;
    width: 360px;
    max-width: 92vw;
    z-index: 99991;
    opacity: 0;
    visibility: hidden;
    transition: opacity .2s; /* 仅淡入淡出，无缩放 */
    box-shadow: none;
}
.jitheme-sign-modal.show {
    opacity: 1;
    visibility: visible;
}
/* 头部 */
.js-cal-header {
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: 0 4px;
    margin-bottom: 18px;
}
.js-cal-title {
    font-size: var(--fs-md);
    color: #1a1d21;
    letter-spacing: -0.2px;
}
.js-cal-nav {
    display: flex;
    gap: 4px;
}
.js-cal-nav-btn {
    width: 32px;
    height: 32px;
    border-radius: var(--b2radius);
    background: transparent;
    border: none;
    display: flex;
    align-items: center;
    justify-content: center;
    color: #1a1d21;
    cursor: pointer;
    transition: background .15s;
    padding: 0;
}
.js-cal-nav-btn:hover {
    background: var(--bg-input);
}
.js-cal-nav-btn svg {
    width: 18px;
    height: 18px;
    fill: none;
    stroke: currentColor;
    stroke-width: 2;
    stroke-linecap: round;
    stroke-linejoin: round;
}
/* 星期行 */
.js-cal-weekdays {
    display: grid;
    grid-template-columns: repeat(7, 1fr);
    gap: 6px;
    margin-bottom: 6px;
}
.js-cal-weekday {
    text-align: center;
    font-size: var(--fs-sm);
    color: #1a1d21;
    padding: 6px 0;
}
/* 日期网格 */
.js-cal-days {
    display: grid;
    grid-template-columns: repeat(7, 1fr);
    gap: 6px;
    padding: 4px 0 0 0;
}
.js-cal-day {
    position: relative;
    aspect-ratio: 1;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: var(--fs-base);
    color: #1a1d21;
    border-radius: var(--b2radius);
    cursor: default;
    transition: background .15s;
    user-select: none;
    box-sizing: border-box;
}
.js-cal-day.other-month {
    color: #d1d5db;
}
/* 已签到（绿色系：区分"今日未签到"的蓝色提示；当月签到次数越多绿色越深；角标圆点绿色+2px白边） */
.js-cal-day.signed {
}
.js-cal-day.signed::after {
    content: '';
    position: absolute;
    top: 0;
    right: 0;
    width: 9px;
    height: 9px;
    border-radius: 50%;
    background: #22c55e; /* 绿色圆点 */
    border: 1px solid #fff; 
    box-sizing: content-box;
    transform: translate(30%, -30%);
}
.js-cal-day.sign-level-1 {
    background: #f0fdf4;
    color: #15803d;
}
.js-cal-day.sign-level-2 {
    background: #dcfce7;
    color: #166534;
}
.js-cal-day.sign-level-3 {
    background: #bbf7d0;
    color: #15803d;
}
.js-cal-day.sign-level-4 {
    background: #86efac;
    color: #14532d;
}
.js-cal-day.sign-level-5 {
    background: #22c55e;
    color: #fff;
}
/* 今天（未签到）：浅蓝底 + 深蓝字 + 蓝色虚线边框，明确提示"今日可签到" */
.js-cal-day.today {
    background: var(--bg-primary-soft);
    color: var(--primary);
    cursor: pointer;
    border: 1px dashed #1e4fd8;
}
.js-cal-day.today:hover {
    background: #b8ccff;
}
/* 今天已签到：绿底白字 + 白点（角标统一绿色+2px边框） */
.js-cal-day.today-signed {
    background: #16a34a;
    color: #fff;
}
.js-cal-day.today-signed::after {
    background: #22c55e;
    border: 1px solid #fff;
}
/* 底部 */
.js-cal-footer {
    margin-top: 20px;
    padding-top: 16px;
    border-top: 1px solid var(--border-color);
    display: flex;
    justify-content: space-between;
    align-items: center;
}
.js-streak-info {
    font-size: var(--fs-sm);
    color: var(--text-secondary);
}
.js-streak-info .num {
    color: var(--primary);
    font-size: var(--fs-base);
    margin: 0 2px;
}
.js-sign-now-btn {
    padding: 7px 16px;
    background: var(--primary);
    color: #fff;
    font-size: var(--fs-sm);
    border: none;
    border-radius: var(--b2radius);
    cursor: pointer;
    transition: background .15s;
}
.js-sign-now-btn:hover {
    background: var(--primary);
}
.js-sign-now-btn:disabled {
    background: var(--bg-muted);
    color: var(--text-muted);
    cursor: not-allowed;
}
/* Toast（白色圆角卡片 + 绿色圆形对勾，参照参考样式） */
.jitheme-sign-toast {
    position: fixed;
    top: 30px;
    left: 50%;
    transform: translateX(-50%) translateY(-16px);
    background: var(--bg-card);
    color: var(--text-primary);
    font-size: var(--fs-sm);
    padding: 12px 20px;
    border-radius: var(--b2radius);
    opacity: 0;
    visibility: hidden;
    transition: all .2s;
    z-index: 100000;
    display: flex;
    align-items: center;
    gap: 8px;
    box-shadow: none;
}
.jitheme-sign-toast.show {
    opacity: 1;
    visibility: visible;
    transform: translateX(-50%) translateY(0);
}
.jitheme-sign-toast svg {
    width: 18px;
    height: 18px;
    padding: 4px;
    box-sizing: border-box;
    background: #52c41a;
    border-radius: 50%;
    stroke: #fff;
    stroke-width: 3;
    fill: none;
    stroke-linecap: round;
    stroke-linejoin: round;
    flex-shrink: 0;
}
/* 暗夜模式 */
body.dark .jitheme-sign-modal {
    background: #1a1c21;
}
body.dark .js-cal-title,
body.dark .js-cal-weekday,
body.dark .js-cal-day {
    color: #f2f3f5;
}
body.dark .js-cal-day.other-month {
    color: #4a4d55;
}
body.dark .js-cal-nav-btn {
    color: #f2f3f5;
}
body.dark .js-cal-nav-btn:hover {
    background: #24262c;
}
body.dark .js-cal-day.today {
    background: #1e3a5f;
    color: #7ba7f7;
    border-color: var(--primary);
}
body.dark .js-cal-day.today:hover {
    background: #274a73;
}
body.dark .js-cal-footer {
    border-top-color: #24262c;
}
body.dark .js-streak-info {
    color: var(--text-muted);
}
body.dark .js-sign-now-btn:disabled {
    background: #24262c;
    color: #6b6f76;
}
/* 暗夜：角标圆点保持绿色（绿色在白/深色底上均可见）；已签到浅绿底上用深色文字保证可读 */
body.dark .js-cal-day.signed::after,
body.dark .js-cal-day.today-signed::after {
    background: #22c55e;
    border-color: #1a1c21;
}
body.dark .js-cal-day.sign-level-1,
body.dark .js-cal-day.sign-level-2,
body.dark .js-cal-day.sign-level-3,
body.dark .js-cal-day.sign-level-4 {
    color: #14532d;
}
body.dark .js-cal-day.sign-level-5,
body.dark .js-cal-day.today-signed {
    color: #fff;
}

/* ============================================================
   顶部工具栏 · 参考风格（白底圆角图标按钮 + FontAwesome 风格 SVG 图标）
   覆盖 B2 顶栏图标按钮统一样式
   ============================================================ */
/* 顶栏图标按钮：42x42 白底圆角卡片，hover 上浮 */
.site-header .icon-btn,
.site-header .change-theme .icon-btn,
.site-header .change-theme .mobile-hidden.icon-btn,
.site-header .change-theme .user-tips.icon-btn {
    width: 38px;
    height: 38px;
    border-radius: 14px !important;
    background: var(--bg-card);
    /*border: 1px solid var(--border-color);*/
    display: flex;
    align-items: center;
    justify-content: center;
    cursor: pointer;
    transition: all 0.22s cubic-bezier(0.34, 1.56, 0.64, 1);
    color: var(--text-secondary);
    flex-shrink: 0;
    box-shadow: none;
}
.site-header .icon-btn:hover,
.site-header .change-theme .icon-btn:hover {
    border-color: var(--border-light);
}
.site-header .icon-btn:active,
.site-header .change-theme .icon-btn:active {
    transform: translateY(0) scale(0.96);
}
/* 内层 a/span 透明无框（清除 B2 fav-box 的内层边框与底色，避免双框） */
.site-header .change-theme .icon-btn > a,
.site-header .change-theme .icon-btn > span {
    width: 100%;
    height: 100%;
    display: flex;
    align-items: center;
    justify-content: center;
    border: none !important;
    background: transparent !important;
    border-radius: 0 !important;
    box-shadow: none;
}
/* 切换导航布局按钮（样式与私信按钮一致：白底、hover 蓝） */
.jitheme-layout-toggle {
    position: relative;
    width: 38px;
    height: 38px;
    border-radius: 14px !important;
    background: var(--bg-card);
    /*border: 1px solid var(--border-color);*/
    display: flex;
    align-items: center;
    justify-content: center;
    cursor: pointer;
    transition: all 0.22s cubic-bezier(0.34, 1.56, 0.64, 1);
    color: var(--text-primary);
    flex-shrink: 0;
}
.jitheme-layout-toggle:hover {
    background: var(--bg-primary-soft);
    color: var(--primary);
    border-color: var(--border-light);
}
/* 按钮内图标统一尺寸（18px 适中，用 !important 防 B2 覆盖） */
.ji-toolbar-icon {
    font-size: var(--fs-lg) !important;
    line-height: 1 !important;
    width: 18px !important;
    height: 18px !important;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    font-family: 'remixicon' !important;
    font-weight: normal !important;
    -webkit-font-smoothing: antialiased;
}
/* 私信 */
.c-dm { color: var(--text-primary); }
.c-dm:hover { background: #e8f0ff; color: var(--primary); }
/* 暗夜 */
.c-dark { color: var(--text-primary); }
.c-dark:hover { background: #f5f3ff; color: #7c3aed; }

/* ============================================================
   整页切换（立即生效，无渐变过渡）
   theme-switching 由 child.js 在点击切换时挂到 <html> 上 220ms
   立即切换：禁用全部 transition + backdrop-filter，避免渐变延迟与卡帧
   ============================================================ */
html.theme-switching *,
html.theme-switching *::before,
html.theme-switching *::after {
    transition: none !important;
    backdrop-filter: none !important;
    -webkit-backdrop-filter: none !important;
}
@media (prefers-reduced-motion: reduce) {
    html.theme-switching *,
    html.theme-switching *::before,
    html.theme-switching *::after {
        transition: none !important;
    }
}

/* VIP 皇冠（金色） */
.c-vip { color: var(--gold-deep); }
.c-vip:hover { background: var(--gold-soft); color: #b45309; }
.c-vip .jitheme-cnav-popup { display: none; }
/* 通知（红点角标保留） */
.c-notify { color: #e11d48; }
.c-notify .ji-corner-dot { top: 6px; right: 6px; }
/* 签到（青绿角标） */
.c-calendar { color: var(--text-primary); }
.c-calendar .ji-corner-dot { top: 5px; right: 5px; }
/* 添加 */
.c-add { color: var(--text-primary); }
.c-add:hover { background: #f0f5ff; color: var(--primary); }
/* 用户头像：42x42 圆角 14（overflow visible 让右下角认证图标完整显示，不被裁切） */
.ji-top-user-box .top-user-avatar,
.top-user-box .top-user-avatar,
.top-user-avatar,
.header-user .top-user-info .top-user-avatar {
    width: 38px !important;
    height: 38px !important;
    border-radius: 14px !important;
    overflow: visible;
}
.top-user-avatar:hover {
    border-color: var(--border-light);
}
/* 登录按钮（未登录态）：与其他顶栏按钮一致的外框（覆盖 B2 fav-box 旧样式） */
.jitheme-custom-nav .top-user-info .new-avatar-container.fav-box {
    width: 38px;
    height: 38px;
    padding: 0;
    display: flex;
    align-items: center;
    justify-content: center;
    border-radius: 14px !important;
    background: var(--bg-card);
    /*border: 1px solid var(--border-color);*/
    color: var(--text-primary);
    transition: all 0.22s cubic-bezier(0.34, 1.56, 0.64, 1);
}
.jitheme-custom-nav .top-user-info .new-avatar-container.fav-box:hover {
    background: var(--bg-primary-soft);
    color: var(--primary);
    border-color: var(--border-light);
}
[data-theme="dark"] .jitheme-custom-nav .top-user-info .new-avatar-container.fav-box {
    background: #24262c;
    border-color: #2f3238;
    color: var(--text-muted);
}
[data-theme="dark"] .jitheme-custom-nav .top-user-info .new-avatar-container.fav-box:hover {
    background: #2f3238;
    color: #f2f3f5;
    border-color: #3a3e46;
}
/* 登录后头像：与其他按钮一致的外框（白底 + 线框，暗夜深色） */
.jitheme-custom-nav .top-user-avatar {
    background: var(--bg-card);
    border: 1px solid var(--border-color);
}
[data-theme="dark"] .jitheme-custom-nav .top-user-avatar {
    background: #24262c;
    border-color: #2f3238;
}
/* 头像内部图片圆角（与容器一致，避免直角） */
.jitheme-custom-nav .top-user-avatar img.avatar {
    border-radius: 14px !important;
}
/* 搜索框：与按钮一致的线框（白底 + 1px 边框） */
.site-header .top-search {
    border-radius: 14px;
    transition: all 0.25s ease;
}
.site-header .top-search:focus-within {
    background: var(--bg-card);
    border-color: var(--border-primary-soft);
}
.site-header .top-search .mobile-search-input,
.site-header .top-search .search-input {
    background: transparent;
}
/* 暗夜：搜索框容器适配深色（含聚焦态，覆盖聚焦变白） */
[data-theme="dark"] .site-header .top-search,
[data-theme="dark"] .jitheme-custom-nav .top-search {
    background: #24262c;
    border-color: #2f3238;
}
[data-theme="dark"] .site-header .top-search:focus-within,
[data-theme="dark"] .jitheme-custom-nav .top-search:focus-within {
    background: #24262c;
    border-color: #2f3238;
    box-shadow: none;
}
/* 暗夜模式适配 */
body.dark .site-header .icon-btn,
body.dark .site-header .change-theme .icon-btn {
    background: #2a2d33;
    border-color: #3a3e46;
    color: var(--text-muted);
}
body.dark .site-header .icon-btn:hover {
    border-color: #4a4f59;
}
body.dark .c-dm:hover { background: rgba(30, 79, 216, 0.18); color: #5b8bff; }
body.dark .c-dark:hover { background: rgba(124, 58, 237, 0.18); color: #a78bfa; }
body.dark .c-vip { color: var(--gold); }
body.dark .c-vip:hover { background: rgba(217, 119, 6, 0.18); color: #fcd34d; }
body.dark .c-notify { color: #f87171; }
body.dark .c-calendar { color: #e4e9f2; }
body.dark .c-add:hover { background: rgba(30, 79, 216, 0.18); color: #5b8bff; }

/* ============================================================
   VIP 会员中心弹窗（顶栏皇冠按钮 · 溜云库风格）
   ============================================================ */
.jitheme-vip-modal {
    position: fixed;
    top: 0; left: 0; right: 0; bottom: 0;
    display: none;
    justify-content: center;
    align-items: center;
    z-index: 99999;
}
.jitheme-vip-modal.active { display: flex; }
.jitheme-vip-modal-overlay {
    position: absolute;
    top: 0; left: 0; right: 0; bottom: 0;
    background: var(--overlay);
}
.jitheme-vip-modal-box {
    position: relative;
    background: var(--bg-card);
    width: 940px;
    max-width: 95%;
    max-height: 92vh;
    overflow-y: auto;
    border-radius: 16px;
    padding: 26px 28px 30px;
    box-shadow: none;
    animation: jithemeVipSlideUp 0.18s ease-out;
}
@keyframes jithemeVipSlideUp {
    from { opacity: 0; transform: translateY(14px); }
    to   { opacity: 1; transform: translateY(0); }
}
.jitheme-vip-header-right {
    display: flex;
    align-items: center;
    gap: 10px;
    flex-shrink: 0;
}
.jitheme-vip-modal-header {
    padding-right: 48px;
}
.jitheme-vip-close {
    position: absolute;
    top: 12px; right: 14px;
    width: 38px;
    height: 38px;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    font-size: var(--fs-lg);
    line-height: 1;
    color: var(--text-muted);
    cursor: pointer;
    border-radius: 12px;
    transition: color 0.15s, background 0.15s;
}
.jitheme-vip-close:hover { color: #333; background: var(--bg-input); }
/* 弹窗头部 */
.jitheme-vip-modal-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 22px;
    padding-bottom: 18px;
    border-bottom: 1px solid var(--border-color);
    gap: 12px;
    flex-wrap: wrap;
}
.jitheme-vip-header-left {
    display: flex;
    align-items: center;
    gap: 14px;
    min-width: 0;
}
.jitheme-vip-logo {
    width: 56px; height: 56px;
    flex-shrink: 0;
    border-radius: 50%;
    overflow: hidden;
    background: var(--bg-input);
    border: 1px solid #ffd700;
    display: flex;
    align-items: center;
    justify-content: center;
}
.jitheme-vip-logo-img {
    width: 100%; height: 100%;
    border-radius: 50%;
    object-fit: cover;
    display: block;
}
.jitheme-vip-guest-avatar {
    display: block;
    width: 100%; height: 100%;
    background: url('data:image/svg+xml;utf8,<svg xmlns="http://www.w3.org/2000/svg" viewBox="0 0 24 24" fill="%23999"><path d="M12 12c2.21 0 4-1.79 4-4s-1.79-4-4-4-4 1.79-4 4 1.79 4 4 4zm0 2c-2.67 0-8 1.34-8 4v2h16v-2c0-2.66-5.33-4-8-4z"/></svg>') no-repeat center / 58% #f1f5fb;
}
.jitheme-vip-header-info { min-width: 0; }
.jitheme-vip-header-info h2 {
    font-size: var(--fs-lg);
    color: var(--text-primary);
    margin: 0 0 4px;
    display: flex;
    align-items: center;
    gap: 8px;
    flex-wrap: wrap;
}
.jitheme-vip-userline {
    display: flex;
    align-items: center;
    gap: 10px;
    flex-wrap: wrap;
}
.jitheme-vip-header-info .user-badges {
    display: inline-flex;
    align-items: center;
    gap: 6px;
    flex-wrap: wrap;
    line-height: 1;
}
.jitheme-vip-header-info .user-badges .badge-diamond,
.jitheme-vip-header-info .user-badges .badge-level {
    display: inline-flex;
    align-items: center;
}
.jitheme-vip-header-info .user-badges .vip,
.jitheme-vip-header-info .user-badges .lv {
    display: inline-flex !important;
    align-items: center;
    margin: 0 !important;
}
.jitheme-vip-header-info p {
    font-size: var(--fs-xs);
    color: var(--text-muted);
    margin: 0;
}
.jitheme-vip-header-info p.jitheme-vip-expire {
    color: #f5a623;
    font-weight: 600;
}
[data-theme="dark"] .jitheme-vip-header-info p.jitheme-vip-expire,
body.dark .jitheme-vip-header-info p.jitheme-vip-expire { color: #f5a623; }
.jitheme-vip-login-btn {
    background: linear-gradient(135deg, #f7c948, #f5a623);
    border: none;
    padding: 10px 26px;
    border-radius: 25px;
    font-weight: bold;
    font-size: var(--fs-base);
    cursor: pointer;
    color: #4a3200;
    transition: all 0.25s;
    flex-shrink: 0;
}
.jitheme-vip-login-btn:hover {
    transform: translateY(-1px);
    box-shadow: none;
}
/* 新人福利条 */
.jitheme-vip-benefit-bar {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 20px;
    font-size: var(--fs-base);
    color: var(--text-primary);
}
.jitheme-vip-benefit-bar span { font-weight: bold; }
.jitheme-vip-benefit-bar small {
    color: var(--text-muted);
    font-weight: normal;
    margin-left: 8px;
    font-size: var(--fs-xs);
}
.jitheme-vip-benefit-left {
    display: flex;
    align-items: center;
    gap: 14px;
    flex-wrap: wrap;
}
.jitheme-vip-benefit-copy {
    font-style: normal;
    font-size: var(--fs-sm);
    color: var(--text-muted);
    font-weight: 600;
}
.jitheme-vip-view-more {
    color: var(--text-muted);
    font-size: var(--fs-xs);
    text-decoration: none;
}
.jitheme-vip-view-more:hover { color: #f5a623; }
/* 套餐网格 */
.jitheme-vip-grid {
    display: grid;
    grid-template-columns: repeat(4, 1fr);
    gap: 16px;
}
.jitheme-vip-card {
    background: #fffbf0;
    border: 1px solid #ffe4b5;
    border-radius: 12px;
    padding: 18px 14px 16px;
    text-align: center;
    display: flex;
    flex-direction: column;
    transition: transform 0.2s, box-shadow 0.2s, border-color 0.2s;
}
.jitheme-vip-card:hover {
    transform: translateY(-5px);
    box-shadow: none;
    border-color: #ffd700;
}
/* 推荐购买卡片 */
.jitheme-vip-card.recommend {
    position: relative;
    border: 1px solid #ffd700;
    background: #fffdf5;
}
.jitheme-vip-recommend-tag {
    position: absolute;
    top: -11px;
    left: 50%;
    transform: translateX(-50%);
    background: linear-gradient(135deg, var(--orange), #ff8a3d);
    color: #fff;
    font-size: var(--fs-xs);
    font-weight: 700;
    padding: 3px 12px;
    border-radius: 12px;
    white-space: nowrap;
    box-shadow: none;
    z-index: 1;
}
[data-theme="dark"] .jitheme-vip-card.recommend,
body.dark .jitheme-vip-card.recommend {
    background: #2b2f38;
    border-color: #f5a623;
}
.jitheme-vip-card-name {
    font-size: var(--fs-base);
    color: var(--text-primary);
    font-weight: 700;
    margin-bottom: 8px;
}
.jitheme-vip-card-price {
    font-size: var(--fs-sm);
    color: var(--orange);
    font-weight: bold;
    margin-bottom: 14px;
    display: flex;
    align-items: baseline;
    justify-content: center;
    gap: 4px;
}
.jitheme-vip-card-price .jitheme-vip-price-symbol { font-size: var(--fs-sm); }
.jitheme-vip-card-price .jitheme-vip-price-num { font-size: 26px; line-height: 1; }
.jitheme-vip-card-price em {
    font-style: normal;
    font-size: var(--fs-xs);
    color: var(--text-muted);
    font-weight: normal;
    margin-left: 2px;
}
.jitheme-vip-rights {
    list-style: none;
    margin: 0 0 16px;
    padding: 0;
    text-align: left;
    flex-grow: 1;
}
.jitheme-vip-rights li {
    font-size: var(--fs-xs);
    color: var(--text-secondary);
    margin-bottom: 7px;
    display: flex;
    align-items: center;
    gap: 6px;
    line-height: 1.5;
}
.jitheme-vip-rights li::before {
    content: "";
    width: 6px; height: 6px;
    border-radius: 50%;
    flex-shrink: 0;
}
.jitheme-vip-rights li.ok::before { background: #2ecc71; }
.jitheme-vip-rights li.no::before { background: var(--bg-muted); }
.jitheme-vip-rights li.no { color: #b0b4bb; }
.jitheme-vip-buy {
    width: 100%;
    background: linear-gradient(135deg, #ffd700, #f5b301);
    border: none;
    padding: 10px 0;
    border-radius: 20px;
    font-weight: bold;
    font-size: var(--fs-base);
    color: #4a3200;
    cursor: pointer;
    transition: background 0.2s, transform 0.15s;
}
.jitheme-vip-buy:hover { transform: translateY(-1px); }
.jitheme-vip-buy.renew { background: #f1f2f4; color: var(--text-secondary); }
.jitheme-vip-buy.disabled {
    background: var(--bg-muted);
    color: var(--text-muted);
    cursor: not-allowed;
    box-shadow: none;
}
.jitheme-vip-buy.disabled:hover { transform: none; }
[data-theme="dark"] .jitheme-vip-buy.disabled,
body.dark .jitheme-vip-buy.disabled { background: #2a2d33; color: #6b7280; }
.jitheme-vip-loading, .jitheme-vip-load-error {
    grid-column: 1 / -1;
    text-align: center;
    color: var(--text-muted);
    font-size: var(--fs-sm);
    padding: 30px 0;
}
/* 暗夜模式适配 */
[data-theme="dark"] .jitheme-vip-modal-box,
body.dark .jitheme-vip-modal-box {
    background: #1f2228;
    box-shadow: none;
}
[data-theme="dark"] .jitheme-vip-modal-header,
body.dark .jitheme-vip-modal-header { border-bottom-color: #2c3038; }
[data-theme="dark"] .jitheme-vip-modal-header h2,
body.dark .jitheme-vip-modal-header h2 { color: #e8eaf0; }
[data-theme="dark"] .jitheme-vip-modal-header p,
body.dark .jitheme-vip-modal-header p { color: #8a90a0; }
[data-theme="dark"] .jitheme-vip-badge,
body.dark .jitheme-vip-badge { background: #2c3038; color: #a4a8b1; }
[data-theme="dark"] .jitheme-vip-logo,
body.dark .jitheme-vip-logo { background: #2a2d33; border-color: #f5a623; }
[data-theme="dark"] .jitheme-vip-guest-avatar,
body.dark .jitheme-vip-guest-avatar { background-color: #2a2d33; }
[data-theme="dark"] .jitheme-vip-benefit-bar,
body.dark .jitheme-vip-benefit-bar { color: #e8eaf0; }
[data-theme="dark"] .jitheme-vip-benefit-bar small,
[data-theme="dark"] .jitheme-vip-view-more,
body.dark .jitheme-vip-benefit-bar small,
body.dark .jitheme-vip-view-more { color: #8a90a0; }
[data-theme="dark"] .jitheme-vip-card,
body.dark .jitheme-vip-card {
    background: #262a32;
    border-color: #373c46;
}
[data-theme="dark"] .jitheme-vip-card:hover,
body.dark .jitheme-vip-card:hover { border-color: #f5a623; }
[data-theme="dark"] .jitheme-vip-card-name,
body.dark .jitheme-vip-card-name { color: #e8eaf0 !important; }
[data-theme="dark"] .jitheme-vip-rights li,
body.dark .jitheme-vip-rights li { color: #a4a8b1; }
[data-theme="dark"] .jitheme-vip-rights li.no,
body.dark .jitheme-vip-rights li.no { color: #6b7280; }
[data-theme="dark"] .jitheme-vip-close:hover,
body.dark .jitheme-vip-close:hover { color: #e8eaf0; background: #2a2d33; }
/* 移动端：两列 */
@media (max-width: 720px) {
    .jitheme-vip-grid { grid-template-columns: repeat(2, 1fr); }
    .jitheme-vip-modal-box { padding: 20px 16px 22px; }
}
@media (max-width: 420px) {
    .jitheme-vip-grid { grid-template-columns: 1fr; }
}
/* 皇冠 VIP 按钮：悬停显示手型 */
#jithemeVipTrigger,
.jitheme-vip-btn a {
    cursor: pointer !important;
}




/* ============================================================
   公告弹窗紧凑版（B2 gg-box 结构替换，子主题 jitheme-announce）
   ============================================================ */
.jitheme-announce.modal {
    background: var(--overlay);
    backdrop-filter: blur(6px);
    align-items: center;
    justify-content: center;
    padding: 1.5rem;
    z-index: 1000;
}
.jitheme-announce-card {
    background: var(--bg-card);
    max-width: 480px;
    width: 100%;
    height: 600px;
    max-height: 600px;
    display: flex;
    flex-direction: column;
    border-radius: 24px;
    box-shadow: none;
    overflow: hidden;
    position: relative;
    transform: scale(0.97);
    transition: transform 0.3s ease;
}
.jitheme-announce.modal.show-modal .jitheme-announce-card {
    transform: scale(1);
}
.jitheme-announce-image {
    width: 100%;
    height: 150px;
    flex-shrink: 0;
    position: relative;
    overflow: hidden;
    background: var(--bg-muted);
    background-size: cover;
    background-position: center;
}
.jitheme-announce-mask {
    position: absolute;
    inset: 0;
    background: rgba(30, 25, 20, 0.45);
    z-index: 1;
    pointer-events: none;
}
.jitheme-announce-hero {
    position: absolute;
    inset: 0;
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    z-index: 2;
    padding: 1rem;
    text-align: center;
}
.jitheme-announce-hero-title {
    font-size: 1.6rem;
    font-weight: 600;
    letter-spacing: 0.12em;
    text-indent: 0.12em;
    line-height: 1.3;
    color: #ffffff;
    text-shadow: 0 1px 6px rgba(0, 0, 0, 0.4);
    margin-bottom: 0.3rem;
}
.jitheme-announce-hero-date {
    font-size: var(--fs-sm);
    color: rgba(255, 255, 255, 0.85);
    letter-spacing: 0.06em;
    text-shadow: 0 1px 4px rgba(0, 0, 0, 0.4);
}
.jitheme-announce-body {
    display: flex;
    flex-direction: column;
    flex: 1 1 auto;
    min-height: 0;
    padding: 0;
}
.jitheme-announce-scroll {
    flex: 1 1 auto;
    overflow-y: auto;
    padding: 1.25rem 1.5rem 0.75rem;
    scrollbar-width: thin;
    scrollbar-color: #e4e9f2 #f8faff;
    min-height: 0;
}
.jitheme-announce-scroll::-webkit-scrollbar { width: 5px; }
.jitheme-announce-scroll::-webkit-scrollbar-track { background: var(--bg-card-hover); }
.jitheme-announce-scroll::-webkit-scrollbar-thumb { background: var(--bg-muted); border-radius: 10px; }
.jitheme-announce-scroll::-webkit-scrollbar-thumb:hover { background: var(--bg-muted); }
.jitheme-announce-subheading {
    font-size: var(--fs-md);
    font-weight: 600;
    color: var(--text-primary);
    text-align: center;
    margin-bottom: 0.85rem;
    letter-spacing: 0.08em;
}
.jitheme-announce-subheading a { color: var(--text-primary); text-decoration: none; }
.jitheme-announce-subheading a:hover { color: var(--text-primary); }
.jitheme-announce-content {
    font-size: var(--fs-base);
    line-height: 1.65;
    color: var(--text-secondary);
}
.jitheme-announce-content p { margin-bottom: 0.8rem; }
.jitheme-announce-content p:last-child { margin-bottom: 0; }
.jitheme-announce-content h2 {
    font-size: var(--fs-md);
    font-weight: 600;
    line-height: 1.4;
    color: var(--text-primary);
    margin: 0.9rem 0 0.5rem;
}
.jitheme-announce-content h2:first-child { margin-top: 0; }
.jitheme-announce-content ul,
.jitheme-announce-content ol {
    padding-left: 1.3rem;
    margin: 0 0 0.8rem;
}
.jitheme-announce-content li {
    margin-bottom: 0.3rem;
}
.jitheme-announce-content a {
    color: #7c9cbf;
    text-decoration: none;
    border-bottom: 1px dashed var(--border-color);
    transition: color 0.2s, border-color 0.2s;
}
.jitheme-announce-content a:hover { color: #5b7d9e; border-bottom-color: #94a3b8; }
.jitheme-announce-footer {
    flex-shrink: 0;
    display: flex;
    gap: 0.75rem;
    justify-content: center;
    padding: 0.8rem 1.5rem 1.2rem;
    background: var(--bg-card);
    border-top: 1px solid var(--border-color);
}
.jitheme-announce-btn {
    background: #1e293b;
    color: #ffffff;
    border: none;
    padding: 0.6rem 1.7rem;
    font-size: var(--fs-base);
    font-weight: 500;
    border-radius: 40px;
    cursor: pointer;
    letter-spacing: 0.04em;
    text-decoration: none;
    box-shadow: none;
    transition: background 0.25s, box-shadow 0.25s, transform 0.15s;
}
.jitheme-announce-btn:hover {
    background: #0f172a;
    color: #ffffff;
    box-shadow: none;
    transform: translateY(-1px);
}
.jitheme-announce-close {
    position: absolute;
    top: 0.7rem;
    right: 0.7rem;
    width: 32px;
    height: 32px;
    border-radius: 50%;
    background: rgba(30, 25, 20, 0.35);
    backdrop-filter: blur(4px);
    border: none;
    display: flex;
    align-items: center;
    justify-content: center;
    cursor: pointer;
    font-size: var(--fs-md);
    line-height: 1;
    color: #ffffff;
    z-index: 10;
    transition: background 0.25s, transform 0.15s;
}
.jitheme-announce-close:hover { background: rgba(30, 25, 20, 0.55); transform: scale(1.08); }
.jitheme-announce-close:active { transform: scale(0.95); }
@media (max-width: 480px) {
    .jitheme-announce-card { height: auto; max-height: 90vh; border-radius: 20px; }
    .jitheme-announce-image { height: 130px; }
    .jitheme-announce-hero-title { font-size: var(--fs-lg); letter-spacing: 0.08em; text-indent: 0.08em; }
    .jitheme-announce-hero-date { font-size: var(--fs-xs); }
    .jitheme-announce-scroll { padding: 1rem 1.1rem 0.6rem; }
    .jitheme-announce-subheading { font-size: var(--fs-md); }
    .jitheme-announce-footer { flex-direction: column-reverse; padding: 0.75rem 1.1rem 1.1rem; }
    .jitheme-announce-btn { width: 100%; text-align: center; }
    .jitheme-announce-close { top: 0.55rem; right: 0.55rem; width: 30px; height: 30px; font-size: var(--fs-base); }
}
