:root {
    --bg-body: #f0f2f5;
    --bg-card: #fff;
    --bg-header: #fff;
    --bg-input: #f5f5f5;
    --bg-badge: #f0f2f5;
    --bg-badge-item: #f6f7f9;
    --text-main: #333;
    --text-secondary: #555;
    --text-muted: #999;
    --text-placeholder: #666;
    --border-color: #ddd;
    --border-divider: #eee;
    --primary-color: #007bff;
    --hover-bg: #e2effd;
    --active-bg: #d0e7ff;
    --shadow-light: rgba(0,0,0,0.05);
    --shadow-hover: rgba(0,0,0,0.08);
    --form-radius: 6px;
    --form-height: 40px;
    --form-padding-y: 10px;
    --form-padding-x: 12px;
    --btn-radius: 6px;
    --btn-height: 36px;
    --btn-padding-y: 8px;
    --btn-padding-x: 16px;
}

body.dark-mode {
    --bg-body: #18191a;
    --bg-card: #242526;
    --bg-header: #242526;
    --bg-input: #3a3b3c;
    --bg-badge: #3a3b3c;
    --bg-badge-item: #3a3b3c;
    --text-main: #e4e6eb;
    --text-secondary: #b0b3b8;
    --text-muted: #b0b3b8;
    --text-placeholder: #b0b3b8;
    --border-color: #3e4042;
    --border-divider: #3e4042;
    --primary-color: #4599ff;
    --hover-bg: #303030;
    --active-bg: #3a3b3c;
    --shadow-light: rgba(0,0,0,0.2);
    --shadow-hover: rgba(0,0,0,0.3);
    background-image: none !important;
}

body.dark-mode .main-nav li a {
    color: #e4e6eb;
}

body.dark-mode .main-nav li a:hover,
body.dark-mode .main-nav li.on a,
body.dark-mode .main-nav li.active a {
    color: #fff;
}

body.dark-mode .site-header {
    border-bottom-color: rgba(255,255,255,0.06);
    background: rgba(36, 37, 38, 0.92);
}

body.dark-mode .main-nav ul {
    border-color: rgba(255,255,255,0.06);
    background: #303234;
    box-shadow: inset 0 1px 0 rgba(255,255,255,0.04);
}

body.dark-mode .main-nav li a:hover {
    color: #8fc4ff;
    background: rgba(69,153,255,0.12);
}

html { overflow-y: scroll; }
body { font-family: "Microsoft YaHei", sans-serif; background-color: var(--bg-body); color: var(--text-main); margin: 0; padding: 0; line-height: 1.6; transition: background-color 0.3s, color 0.3s; background-position: center center; }

/* Site background image */
body {
    background-image: url('/bj.png');
    background-repeat: no-repeat;
    background-size: cover;
    background-attachment: fixed;
}
a { text-decoration: none; color: var(--text-main); transition: color 0.2s; }
a:hover { color: var(--primary-color); }
ul, ol { list-style: none; padding: 0; margin: 0; }
.container { width: 100%; max-width: 1170px; margin: 0 auto; padding: 0 15px; box-sizing: border-box; }
.clearfix::after { content: ""; display: table; clear: both; }
.pan-visually-hidden { position: absolute !important; width: 1px !important; height: 1px !important; overflow: hidden !important; margin: -1px !important; padding: 0 !important; border: 0 !important; clip: rect(0 0 0 0) !important; clip-path: inset(50%) !important; white-space: nowrap !important; }

/* Global form controls */
input[type="text"],
input[type="password"],
input[type="email"],
input[type="search"],
input[type="url"],
input[type="tel"],
input[type="number"],
select {
    height: var(--form-height);
    padding: var(--form-padding-y) var(--form-padding-x);
    border: 1px solid var(--border-divider);
    border-radius: var(--form-radius);
    background: var(--bg-input);
    color: var(--text-main);
    box-sizing: border-box;
    outline: none;
    font-size: 14px;
    transition: border-color 0.2s, box-shadow 0.2s;
}
input:focus, select:focus, textarea:focus {
    border-color: var(--primary-color);
    box-shadow: 0 0 0 2px rgba(0,123,255,0.12);
}
textarea {
    width: 100%;
    min-height: 90px;
    padding: var(--form-padding-y) var(--form-padding-x);
    border: 1px solid var(--border-divider);
    border-radius: var(--form-radius);
    background: var(--bg-input);
    color: var(--text-main);
    box-sizing: border-box;
    outline: none;
    font-size: 14px;
    line-height: 1.5;
    transition: border-color 0.2s, box-shadow 0.2s;
}

/* Global button defaults */
button,
.btn,
input[type="button"],
input[type="submit"] {
    display: inline-block;
    height: var(--btn-height);
    padding: var(--btn-padding-y) var(--btn-padding-x);
    border-radius: var(--btn-radius);
    font-size: 14px;
    line-height: 1.2;
    cursor: pointer;
    transition: background-color 0.2s, color 0.2s, box-shadow 0.2s;
}

/* Button semantic variants */
.btn-primary {
    background: var(--primary-color);
    color: #fff;
    border: 1px solid var(--primary-color);
}
.btn-primary:hover { filter: brightness(0.95); box-shadow: 0 2px 8px rgba(0,123,255,0.25); }

.btn-secondary {
    --secondary-color: #6c757d;
    background: var(--secondary-color);
    color: #fff;
    border: 1px solid var(--secondary-color);
}
.btn-secondary:hover { filter: brightness(0.95); box-shadow: 0 2px 8px rgba(108,117,125,0.25); }

.btn-danger {
    --danger-color: #ff4d4f;
    background: var(--danger-color);
    color: #fff;
    border: 1px solid var(--danger-color);
}
.btn-danger:hover { filter: brightness(0.95); box-shadow: 0 2px 8px rgba(255,77,79,0.25); }

.btn-outline-primary {
    background: transparent;
    color: var(--primary-color);
    border: 1px solid var(--primary-color);
}
.btn-outline-primary:hover { background: rgba(0,123,255,0.08); }

.btn-outline-secondary {
    --secondary-color: #6c757d;
    background: transparent;
    color: var(--secondary-color);
    border: 1px solid var(--secondary-color);
}
.btn-outline-secondary:hover { background: rgba(108,117,125,0.08); }

.btn-outline-danger {
    --danger-color: #ff4d4f;
    background: transparent;
    color: var(--danger-color);
    border: 1px solid var(--danger-color);
}
.btn-outline-danger:hover { background: rgba(255,77,79,0.08); }

.site-header { position: sticky; top: 0; z-index: 1000; margin-bottom: 20px; padding: 10px 0; border-bottom: 1px solid rgba(51, 115, 190, 0.09); background: rgba(255, 255, 255, 0.92); box-shadow: 0 8px 26px rgba(31, 55, 82, 0.06); backdrop-filter: blur(16px); -webkit-backdrop-filter: blur(16px); transition: background-color 0.3s, box-shadow 0.3s; }
.site-header::after { position: absolute; right: 0; bottom: -1px; left: 0; height: 1px; background: linear-gradient(90deg, transparent, rgba(14, 137, 245, 0.28), transparent); content: ""; pointer-events: none; }
.site-header .container { display: flex; min-height: 52px; align-items: center; gap: 18px; }
.logo { display: flex; width: auto; max-width: 300px; flex-shrink: 0; align-items: center; box-sizing: border-box; margin-right: 2px; padding-left: 8px; overflow: hidden; color: var(--primary-color); font-size: 28px; font-weight: 800; letter-spacing: -1px; text-overflow: ellipsis; white-space: nowrap; }
.logo a { display: flex; align-items: center; gap: 10px; color: var(--primary-color); }
.logo img { height: 40px; }
.main-nav ul { display: flex; align-items: center; gap: 3px; padding: 5px; border: 1px solid rgba(45, 112, 190, 0.08); border-radius: 15px; background: #f5f8fc; box-shadow: inset 0 1px 0 rgba(255, 255, 255, 0.86); }
.main-nav li a {
    display: inline-flex;
    position: relative;
    align-items: center;
    justify-content: center;
    gap: 6px;
    min-width: 48px;
    height: 38px;
    box-sizing: border-box;
    padding: 0 14px;
    border: 0;
    border-radius: 11px;
    background: transparent;
    color: #405269;
    font-family: "Microsoft YaHei", Arial, sans-serif;
    font-size: 15px;
    font-weight: 600;
    line-height: 1.2;
    white-space: nowrap;
    transition: color 0.2s ease, background 0.2s ease, box-shadow 0.2s ease, transform 0.2s ease;
}
.main-nav li a:hover {
    color: var(--primary-color);
    background: rgba(10, 132, 245, 0.09);
    transform: translateY(-1px);
}
.main-nav li.on a,
.main-nav li.active a {
    background: linear-gradient(135deg, #16a8f7 0%, #0878ee 100%);
    box-shadow: 0 7px 16px rgba(8, 121, 238, 0.22), inset 0 1px 0 rgba(255, 255, 255, 0.24);
    color: #fff;
    font-weight: 700;
}
.main-nav li.active a::after {
    display: none;
}
.main-nav li a i { color: currentColor; }
.search-box { margin-left: auto; display: flex; align-items: center; }
.top-search-wrap {
    position: relative;
}
.search-box form {
    display: flex;
    align-items: center;
    height: 40px;
    border: 1px solid rgba(45, 112, 190, 0.13);
    border-radius: 13px;
    overflow: hidden;
    background: var(--bg-card);
    box-shadow: 0 5px 16px rgba(31, 55, 82, 0.06);
    transition: border-color 0.2s ease, box-shadow 0.2s ease;
}
.search-box form:focus-within { border-color: rgba(8, 123, 239, 0.45); box-shadow: 0 0 0 3px rgba(8, 123, 239, 0.08), 0 7px 18px rgba(31, 55, 82, 0.08); }
.search-box input {
    height: 38px;
    border: none;
    padding: 0 10px;
    outline: none;
    background: transparent;
    width: 150px;
    color: var(--text-main);
    font-size: 13px;
}
.search-box button {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 40px;
    height: 38px;
    background: transparent;
    color: var(--text-placeholder);
    border: none;
    padding: 0;
    cursor: pointer;
}
.top-search-suggest {
    position: absolute;
    top: calc(100% + 8px);
    left: 0;
    width: 260px;
    padding: 12px;
    border: 1px solid var(--border-divider);
    border-radius: 12px;
    background: linear-gradient(180deg, rgba(255, 255, 255, 0.98), rgba(255, 255, 255, 0.94));
    box-shadow: 0 14px 34px rgba(0, 0, 0, 0.12), 0 0 0 1px rgba(255, 255, 255, 0.45) inset, 0 0 22px rgba(69, 153, 255, 0.14);
    box-sizing: border-box;
    opacity: 0;
    visibility: hidden;
    pointer-events: none;
    transform: translateY(6px) scale(0.96);
    transform-origin: top left;
    transition: opacity 0.22s ease, transform 0.22s ease, visibility 0.22s ease;
    z-index: 1100;
}
.top-search-suggest::before {
    content: "";
    position: absolute;
    inset: 0;
    border-radius: 12px;
    padding: 1px;
    background: linear-gradient(135deg, rgba(255,255,255,0.95), rgba(69,153,255,0.55), rgba(255,196,0,0.45));
    -webkit-mask: linear-gradient(#fff 0 0) content-box, linear-gradient(#fff 0 0);
    -webkit-mask-composite: xor;
    mask-composite: exclude;
    pointer-events: none;
}
.top-search-wrap.is-open .top-search-suggest {
    opacity: 1;
    visibility: visible;
    pointer-events: auto;
    transform: translateY(0) scale(1);
}
.top-search-suggest-title {
    font-size: 12px;
    color: var(--text-muted);
    margin-bottom: 10px;
    line-height: 1;
}
.top-search-suggest-list {
    display: flex;
    flex-wrap: wrap;
    gap: 8px;
}
.top-search-suggest-item {
    position: relative;
    display: inline-flex;
    align-items: center;
    gap: 6px;
    min-height: 32px;
    padding: 0 12px;
    border-radius: 999px;
    border: 1px solid rgba(255, 255, 255, 0.55);
    background: linear-gradient(180deg, rgba(255,255,255,0.92), rgba(245,247,250,0.98));
    color: var(--text-secondary);
    font-size: 12px;
    line-height: 1;
    overflow: visible;
    box-shadow: 0 2px 8px rgba(0, 0, 0, 0.05);
    transition: transform 0.2s ease, box-shadow 0.2s ease, color 0.2s ease, background 0.2s ease;
}
.top-search-suggest-icon {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    font-size: 12px;
}
.top-search-suggest-text {
    position: relative;
    z-index: 1;
}
.top-search-suggest-item.is-top-1 .top-search-suggest-icon {
    color: #f5a623;
}
.top-search-suggest-item.is-top-2 .top-search-suggest-icon,
.top-search-suggest-item.is-top-3 .top-search-suggest-icon {
    color: #ff6b35;
}
.top-search-suggest-item.is-top-1 {
    background: linear-gradient(180deg, rgba(255, 247, 214, 0.98), rgba(255, 237, 173, 0.95));
    border-color: rgba(245, 166, 35, 0.28);
}
.top-search-suggest-item.is-top-2,
.top-search-suggest-item.is-top-3 {
    background: linear-gradient(180deg, rgba(255, 238, 229, 0.98), rgba(255, 222, 204, 0.95));
    border-color: rgba(255, 107, 53, 0.22);
}
.top-search-suggest-item::after {
    content: "";
    position: absolute;
    left: var(--ripple-x, 50%);
    top: var(--ripple-y, 50%);
    width: 10px;
    height: 10px;
    border-radius: 50%;
    background: rgba(69, 153, 255, 0.22);
    transform: translate(-50%, -50%) scale(0);
    opacity: 0;
    pointer-events: none;
}
.top-search-suggest-item.is-rippling::after {
    animation: topSearchRipple 0.52s ease-out;
}
.top-search-suggest-item:hover {
    background: linear-gradient(180deg, rgba(255,255,255,1), rgba(236,243,255,0.98));
    color: var(--primary-color);
    transform: translateY(-1px) scale(1.02);
    box-shadow: 0 8px 18px rgba(69, 153, 255, 0.14);
    z-index: 3;
}
.top-search-tooltip {
    position: fixed;
    left: 0;
    top: 0;
    display: inline-flex;
    flex-direction: column;
    align-items: center;
    gap: 0;
    opacity: 0;
    visibility: hidden;
    pointer-events: none;
    transform: translate3d(0, 8px, 0) scale(0.96);
    transition: opacity 0.16s ease, transform 0.16s ease, visibility 0.16s ease;
    z-index: 2000;
}
.top-search-tooltip.is-visible {
    opacity: 1;
    visibility: visible;
    transform: translate3d(0, 0, 0) scale(1);
}
.top-search-tooltip-text {
    display: inline-block;
    padding: 6px 10px;
    border-radius: 8px;
    background: rgba(34, 34, 34, 0.94);
    color: #fff;
    font-size: 12px;
    line-height: 1;
    white-space: nowrap;
    box-shadow: 0 8px 18px rgba(0, 0, 0, 0.18);
}
.top-search-tooltip-arrow {
    width: 10px;
    height: 10px;
    margin-top: -1px;
    background: rgba(34, 34, 34, 0.94);
    transform: rotate(45deg);
}
body.dark-mode .top-search-tooltip-text,
body.dark-mode .top-search-tooltip-arrow {
    background: rgba(20, 20, 20, 0.96);
}
@keyframes topSearchRipple {
    0% {
        transform: translate(-50%, -50%) scale(0);
        opacity: 0.55;
    }
    100% {
        transform: translate(-50%, -50%) scale(16);
        opacity: 0;
    }
}
body.dark-mode .top-search-suggest {
    background: linear-gradient(180deg, rgba(36, 37, 38, 0.98), rgba(36, 37, 38, 0.94));
    box-shadow: 0 14px 34px rgba(0, 0, 0, 0.32), 0 0 0 1px rgba(255, 255, 255, 0.06) inset, 0 0 22px rgba(69, 153, 255, 0.2);
}
body.dark-mode .top-search-suggest-item {
    border-color: rgba(255, 255, 255, 0.08);
    background: linear-gradient(180deg, rgba(58,59,60,0.95), rgba(48,49,50,0.96));
}
body.dark-mode .top-search-suggest-item.is-top-1 {
    background: linear-gradient(180deg, rgba(94, 76, 18, 0.95), rgba(74, 59, 13, 0.96));
}
body.dark-mode .top-search-suggest-item.is-top-2,
body.dark-mode .top-search-suggest-item.is-top-3 {
    background: linear-gradient(180deg, rgba(93, 50, 33, 0.95), rgba(74, 39, 25, 0.96));
}

.dark-mode-toggle {
    background: transparent;
    border: none;
    cursor: pointer;
    font-size: 20px;
    color: var(--text-secondary);
    padding: 5px;
    margin-left: 15px;
    transition: color 0.3s;
    display: flex;
    align-items: center;
}
.dark-mode-toggle:hover {
    color: var(--primary-color);
}

.main-wrapper { display: flex; gap: 20px; align-items: flex-start; padding-top: 20px; }
.pan-home-activity { margin-top: 20px; }
.pan-home-activity-inner {
    position: relative;
    display: flex;
    min-height: 58px;
    align-items: center;
    justify-content: space-between;
    gap: 22px;
    overflow: hidden;
    padding: 10px 18px;
    border: 1px solid rgba(84, 111, 255, .12);
    border-radius: 12px;
    background: linear-gradient(110deg, #eef5ff 0%, #e8edff 35%, #f4e9ff 58%, #e1f7ff 78%, #e1e6ff 100%);
    background-size: 240% 240%;
    box-shadow: 0 8px 24px rgba(67, 92, 180, .08);
    box-sizing: border-box;
    animation: panHomeActivityGradient 10s ease-in-out infinite;
}
.pan-home-activity-inner::before {
    content: "";
    position: absolute;
    top: -48px;
    left: 36%;
    width: 260px;
    height: 140px;
    border-radius: 50%;
    background: radial-gradient(circle, rgba(255,255,255,.85), rgba(255,255,255,0) 68%);
    pointer-events: none;
}
.pan-home-activity-inner::after {
    content: "";
    position: absolute;
    top: -80%;
    bottom: -80%;
    left: -22%;
    width: 13%;
    background: linear-gradient(90deg, transparent, rgba(255,255,255,.58), transparent);
    transform: rotate(16deg);
    animation: panHomeActivityShine 6.5s ease-in-out infinite;
    pointer-events: none;
}
@keyframes panHomeActivityGradient {
    0%, 100% { background-position: 0% 50%; }
    50% { background-position: 100% 50%; }
}
@keyframes panHomeActivityShine {
    0%, 24% { left: -22%; opacity: 0; }
    36% { opacity: .9; }
    58%, 100% { left: 112%; opacity: 0; }
}
.pan-home-activity-feed,
.pan-home-activity-stats {
    position: relative;
    z-index: 1;
    display: flex;
    align-items: center;
}
.pan-home-activity-feed {
    min-width: 0;
    flex: 1;
    gap: 10px;
    color: #28446c;
}
.pan-home-activity-label {
    display: inline-flex;
    height: 28px;
    flex: 0 0 auto;
    align-items: center;
    gap: 6px;
    padding: 0 10px;
    border-radius: 7px;
    background: linear-gradient(135deg, #ff6976, #ff565f);
    color: #fff;
    font-size: 13px;
    font-weight: 600;
    box-shadow: 0 5px 12px rgba(255, 86, 95, .2);
}
.pan-home-activity-label i { animation: panHomeActivitySpeaker 1.8s ease-in-out infinite; }
@keyframes panHomeActivitySpeaker {
    0%, 100% { transform: scale(1); }
    50% { transform: scale(1.16); }
}
.pan-home-activity-copy {
    display: flex;
    min-width: 0;
    align-items: center;
    gap: 6px;
    overflow: hidden;
    white-space: nowrap;
}
.pan-home-activity-ticker {
    display: flex;
    min-width: 0;
    align-items: center;
    gap: 10px;
    overflow: hidden;
    transition: opacity .18s ease, transform .18s ease;
}
.pan-home-activity-ticker.is-switching { opacity: 0; transform: translateY(-9px); }
.pan-home-activity-ticker.is-entering { animation: panHomeActivityTickerIn .4s ease both; }
@keyframes panHomeActivityTickerIn {
    from { opacity: 0; transform: translateY(9px); }
    to { opacity: 1; transform: translateY(0); }
}
.pan-home-activity-copy strong { color: #2456a6; font-weight: 500; }
.pan-home-activity-copy span { overflow: hidden; text-overflow: ellipsis; }
.pan-home-activity-time {
    flex: 0 0 auto;
    padding: 2px 7px;
    border-radius: 5px;
    background: rgba(99, 121, 185, .13);
    color: #71809c;
    font-size: 12px;
    font-style: normal;
}
.pan-home-activity-stats {
    flex: 0 0 auto;
    display: grid;
    width: max-content;
    min-width: 0;
    max-width: 100%;
    grid-template-columns: max-content repeat(3, max-content);
    align-items: stretch;
    column-gap: 5px;
    row-gap: 4px;
    overflow: hidden;
    padding: 4px 7px;
    border: 1px solid rgba(107, 126, 219, .1);
    border-radius: 11px;
    background: rgba(255,255,255,.32);
    color: #334b83;
    font-size: 12px;
    white-space: nowrap;
    box-shadow: inset 0 1px 0 rgba(255,255,255,.38);
}
.pan-home-activity-stat-group {
    display: contents;
}
.pan-home-activity-stat-group > span:not(.pan-home-activity-stat-heading) {
    display: grid;
    min-width: 0;
    height: 23px;
    align-items: center;
    grid-template-columns: max-content max-content;
    gap: 3px;
    overflow: hidden;
    padding: 0 5px;
    border: 1px solid rgba(101, 124, 221, .08);
    border-radius: 6px;
    background: rgba(255,255,255,.28);
    box-sizing: border-box;
    text-overflow: ellipsis;
}
.pan-home-activity-stat-group > span:not(.pan-home-activity-stat-heading) em {
    overflow: hidden;
    font-style: normal;
    text-overflow: ellipsis;
    white-space: nowrap;
}
.pan-home-activity-stat-group > span:not(.pan-home-activity-stat-heading) b { justify-self: start; }
.pan-home-activity-resource-stats > span:not(.pan-home-activity-stat-heading) {
    border-color: rgba(61, 171, 205, .09);
    background: rgba(92, 191, 218, .055);
}
.pan-home-activity-stat-group > span.is-disabled { color: #a6afc2; opacity: .72; }
.pan-home-activity-stat-heading {
    display: inline-flex;
    min-width: 0;
    min-height: 23px;
    align-items: center;
    gap: 4px;
    color: #66749a;
    font-size: 10.5px;
    font-weight: 600;
}
.pan-home-activity-site-stats .pan-home-activity-stat-heading i { color: #677ee8; }
.pan-home-activity-resource-stats .pan-home-activity-stat-heading i { color: #37a9cb; }
.pan-home-activity-stat-heading small {
    padding: 1px 4px;
    border-radius: 4px;
    background: rgba(250, 176, 72, .15);
    color: #be7b22;
    font-size: 9px;
    font-weight: 500;
}
.pan-home-activity-stats b {
    display: inline-flex;
    min-width: 22px;
    height: 18px;
    align-items: center;
    justify-content: center;
    margin-left: 0;
    padding: 0 4px;
    border-radius: 5px;
    background: rgba(89, 111, 255, .13);
    color: #5267dc;
    font-size: 10.5px;
    font-weight: 700;
    box-sizing: border-box;
}
body.dark-mode .pan-home-activity-inner {
    border-color: rgba(115, 140, 255, .2);
    background: linear-gradient(110deg, #17233f, #202951 52%, #292750);
    box-shadow: 0 8px 24px rgba(0, 0, 0, .18);
}
body.dark-mode .pan-home-activity-feed,
body.dark-mode .pan-home-activity-stats { color: #c9d5f4; }
body.dark-mode .pan-home-activity-copy strong { color: #8db9ff; }
body.dark-mode .pan-home-activity-time,
body.dark-mode .pan-home-activity-stats b { background: rgba(126, 147, 255, .17); color: #b9c7ff; }
body.dark-mode .pan-home-activity-stats { border-color: rgba(126,147,255,.13); background: rgba(19,28,58,.28); }
body.dark-mode .pan-home-activity-stat-heading { color: #9daacf; }
body.dark-mode .pan-home-activity-stat-group > span:not(.pan-home-activity-stat-heading) { border-color: rgba(126,147,255,.12); background: rgba(126,147,255,.06); }
@media (prefers-reduced-motion: reduce) {
    .pan-home-activity-inner,
    .pan-home-activity-inner::after,
    .pan-home-activity-label i,
    .pan-home-activity-ticker.is-entering { animation: none; }
}
/* Default-home activity strip responsive layout */
@media (max-width: 992px) {
    .pan-home-activity { margin-top: 12px; }
    .pan-home-activity-inner { align-items: flex-start; flex-direction: column; gap: 8px; padding: 12px 14px; }
    .pan-home-activity-feed { width: 100%; }
    .pan-home-activity-stats { width: max-content; min-width: 0; max-width: 100%; align-self: flex-end; overflow-x: auto; }
}
@media (max-width: 480px) {
    .pan-home-activity-feed { gap: 7px; }
    .pan-home-activity-copy { font-size: 13px; }
    .pan-home-activity-ticker { gap: 7px; }
    .pan-home-activity-label { padding: 0 8px; font-size: 12px; }
    .pan-home-activity-time { display: none; }
    .pan-home-activity-stats { width: 100%; justify-content: flex-end; font-size: 12px; }
    .pan-home-activity-stat-group > span:not(.pan-home-activity-stat-heading) { padding: 0 5px; }
}
.left-sidebar { width: auto; min-width: 140px; max-width: 100%; flex-shrink: 0; position: sticky; top: 90px; }
.center-content { flex: 1; min-width: 0; }
.right-sidebar { width: 280px; flex-shrink: 0; }
.main-wrapper-single {
    display: block;
}
.portal-single-layout {
    max-width: 1140px;
}
.center-content-single {
    width: 100%;
    max-width: 100%;
}

.left-nav-card {
    background: var(--bg-card);
    border-radius: 10px;
    padding: 12px;
    box-shadow: 0 1px 2px var(--shadow-light);
}
.left-nav-list { padding: 2px 0; }
.left-nav-list li { margin-bottom: 4px; }
.left-nav-list li a { 
    display: flex; 
    align-items: center; 
    padding: 7px 10px; 
    border-radius: 8px; 
    color: var(--text-secondary); 
    font-size: 13px; 
    font-weight: 500;
    transition: all 0.2s ease;
    white-space: nowrap;
}
.left-nav-list li a:hover { 
    background-color: var(--hover-bg); 
    color: var(--primary-color); 
}
.left-nav-list li.is-category:not(.is-child-menu) a {
    background-color: rgba(0, 123, 255, 0.06);
    background-color: color-mix(in srgb, var(--pan-menu-accent, var(--primary-color)) 8%, var(--bg-card));
    color: var(--pan-menu-accent, var(--primary-color));
    font-weight: 600;
    box-shadow: inset 0 0 0 1px rgba(255,255,255,0.04);
}
.left-nav-list li.is-category:not(.is-child-menu) a .nav-icon,
.left-nav-list li.is-category:not(.is-child-menu) a i {
    color: inherit !important;
}
.left-nav-list li.is-child-menu a .nav-icon,
.left-nav-list li.is-child-menu a i {
    color: var(--pan-menu-accent, var(--primary-color)) !important;
}
.left-nav-list li.is-child-menu:not(.active) a {
    background-color: transparent;
    border-color: transparent;
    color: var(--text-secondary);
    font-weight: 400;
    box-shadow: none;
}
.left-nav-list li.is-category:not(.is-child-menu):not(.active) a:hover {
    background-color: rgba(0, 123, 255, 0.11);
    background-color: color-mix(in srgb, var(--pan-menu-accent, var(--primary-color)) 13%, var(--bg-card));
    color: var(--pan-menu-accent, var(--primary-color));
}
.left-nav-list li.is-child-menu:not(.active) a:hover {
    background-color: var(--hover-bg);
    color: var(--primary-color);
}
.left-nav-list li:not(.is-category) a {
    font-size: 13px;
    font-weight: 400;
}
.left-nav-list li.is-filter a {
    padding: 6px 8px 6px 14px;
    font-size: 11px;
    font-weight: 400;
}
.left-nav-list li.is-child-menu a {
    padding: 6px 8px 6px 16px;
    font-size: 11px;
    font-weight: 400;
    border-color: transparent;
}
.left-nav-list li.is-filter a .nav-icon,
.left-nav-list li.is-child-menu a .nav-icon {
    width: 16px;
}
.left-nav-list li.is-filter a i,
.left-nav-list li.is-child-menu a i {
    font-size: 13px;
}
.left-nav-list li.active a { 
    background-color: rgba(0, 123, 255, 0.14);
    background-color: color-mix(in srgb, var(--pan-menu-accent, var(--primary-color)) 16%, var(--bg-card)); 
    border-color: transparent;
    color: var(--pan-menu-accent, var(--primary-color)); 
    font-weight: 500;
    box-shadow: none;
}
.left-nav-list li.is-category.active a {
    background-color: rgba(0, 123, 255, 0.14);
    background-color: color-mix(in srgb, var(--pan-menu-accent, var(--primary-color)) 16%, var(--bg-card));
    color: var(--pan-menu-accent, var(--primary-color));
    font-weight: 600;
    box-shadow: none;
}
.left-nav-list li.is-filter.active a,
.left-nav-list li.is-child-menu.active a {
    font-weight: 400;
}
.left-nav-list li.active a .nav-icon,
.left-nav-list li.active a i {
    color: inherit !important;
}
.left-nav-list li a i { 
    width: 20px; 
    text-align: center; 
    margin-right: 8px; 
    font-size: 15px;
}
.left-nav-list li a .nav-icon {
    width: 20px; 
    text-align: center; 
    margin-right: 8px;
    display: inline-block;
}
.left-nav-list li a .nav-icon i {
    margin-right: 0;
}
.left-nav-list .pan-side-menu-overflow:not(.active) {
    display: none;
}
.left-nav-list .pan-side-menu-overflow.is-section-expanded {
    display: block;
}
.left-nav-list .pan-side-menu-overflow.active {
    display: block;
}
.pan-side-menu-toggle-item {
    margin-top: 6px;
}
.pan-side-menu-toggle {
    width: 100%;
    min-height: 34px;
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 7px;
    border: 1px dashed color-mix(in srgb, var(--primary-color) 28%, var(--border-divider));
    border-radius: 8px;
    background: color-mix(in srgb, var(--primary-color) 5%, var(--bg-card));
    color: var(--primary-color);
    font-size: 12px;
    cursor: pointer;
    transition: background-color .2s ease, border-color .2s ease;
}
.pan-side-menu-toggle:hover {
    background: color-mix(in srgb, var(--primary-color) 10%, var(--bg-card));
    border-color: color-mix(in srgb, var(--primary-color) 45%, var(--border-divider));
}
.pan-side-menu-toggle i {
    width: auto;
    margin: 0;
    transition: transform .2s ease;
}
.pan-side-menu-toggle-item.is-expanded .pan-side-menu-toggle i {
    transform: rotate(180deg);
}

.nav-divider {
    height: 1px;
    background-color: var(--border-divider);
    margin: 8px 10px;
}

.post-list { display: flex; flex-direction: column; gap: 8px; }
.post-list-item { background: var(--bg-card); border-radius: 6px; padding: 12px; display: flex; gap: 12px; box-shadow: 0 1px 2px var(--shadow-light); transition: all 0.2s; align-items: center; }
.post-list-item:hover { transform: translateY(-1px); box-shadow: 0 4px 12px var(--shadow-hover); }

.post-avatar { width: 32px; height: 32px; flex-shrink: 0; border-radius: 50%; overflow: hidden; background: var(--bg-input); }
.post-avatar img { width: 100%; height: 100%; object-fit: cover; }

.post-info { flex: 1; display: flex; flex-direction: column; justify-content: center; min-width: 0; }
.post-title { font-size: 15px; margin: 0 0 4px; font-weight: normal; line-height: 1.4; display: flex; align-items: center; }
.post-title a { color: var(--text-main); overflow: hidden; text-overflow: ellipsis; white-space: nowrap; min-width: 0; }
.post-title a:hover { color: var(--primary-color); }

.cate-prefix { color: var(--text-secondary); margin-right: 5px; font-size: 14px; }

.post-meta { font-size: 12px; color: var(--text-muted); display: flex; align-items: center; gap: 5px; flex-wrap: wrap; }
.post-meta-item { display: flex; align-items: center; gap: 4px; background: var(--bg-badge-item); padding: 2px 8px; border-radius: 10px; }
.tag-badge { background: var(--bg-badge); color: var(--text-placeholder); padding: 2px 8px; border-radius: 4px; font-size: 12px; }

.post-action { margin-left: auto; flex-shrink: 0; }
.post-action .btn {
    height: auto;
    padding: 2px 12px;
    font-size: 12px;
    border-radius: 999px;
    line-height: 1.2;
    border-width: 1px;
    box-shadow: 0 1px 3px rgba(0,123,255,0.12);
}
.post-action .btn:hover { box-shadow: 0 2px 6px rgba(0,123,255,0.18); }
.btn-visit { 
    display: inline-block; 
    padding: 3px 12px; 
    border: 1px solid var(--primary-color); 
    color: var(--primary-color); 
    border-radius: var(--btn-radius); 
    font-size: 12px; 
    transition: all 0.2s; 
    background: rgba(0, 123, 255, 0.05);
    line-height: 1.2;
}
.btn-visit:hover { 
    background: var(--primary-color); 
    color: #fff; 
    box-shadow: 0 2px 8px rgba(0, 123, 255, 0.25);
    transform: translateY(-1px);
}

.widget { background: var(--bg-card); padding: 20px; margin-bottom: 20px; border-radius: 8px; box-shadow: 0 1px 2px var(--shadow-light); }
.widget-title { font-size: 16px; font-weight: bold; border-left: 4px solid var(--primary-color); padding-left: 10px; margin-bottom: 15px; color: var(--text-main); }
.widget ul li { padding: 8px 0; border-bottom: 1px dashed var(--border-divider); font-size: 14px; color: var(--text-placeholder); }
.widget ul li:last-child { border-bottom: none; }
.widget-wechat .wechat-qr { text-align: center; }
.widget-wechat .wechat-qr img { width: 100%; max-width: 240px; height: auto; display: block; margin: 0 auto; border-radius: 8px; background: var(--bg-input); padding: 8px; box-sizing: border-box; }
.widget-wechat .wechat-qr-copy img { cursor: pointer; }
.widget-wechat .wechat-qr-tips { margin-top: 10px; font-size: 14px; color: var(--text-secondary); font-weight: 500; text-align: center; line-height: 1.6; }
.widget-tags .tag-list { display: flex; flex-wrap: wrap; gap: 8px; }
.widget-tags .tag-item { display: inline-flex; align-items: center; gap: 4px; padding: 6px 10px; border-radius: 3px; border: 1px solid var(--border-color); color: var(--text-secondary); font-size: 13px; line-height: 1.2; background: transparent; transition: all 0.2s; }
.widget-tags .tag-item:hover { background: var(--hover-bg); border-color: currentColor; color: var(--primary-color); }
.widget-tags .tag-count { font-size: 12px; opacity: 0.9; }
.widget-tags .tag-item:nth-child(6n+1) { color: #2f7cf6; border-color: currentColor; }
.widget-tags .tag-item:nth-child(6n+2) { color: #ff4d4f; border-color: currentColor; }
.widget-tags .tag-item:nth-child(6n+3) { color: #52c41a; border-color: currentColor; }
.widget-tags .tag-item:nth-child(6n+4) { color: #fa8c16; border-color: currentColor; }
.widget-tags .tag-item:nth-child(6n+5) { color: #722ed1; border-color: currentColor; }
.widget-tags .tag-item:nth-child(6n) { color: #13c2c2; border-color: currentColor; }
.widget-hot .hot-list li { display: flex; align-items: flex-start; gap: 8px; padding: 10px 0; border-bottom: 1px dashed var(--border-divider); }
.widget-hot .hot-list li:last-child { border-bottom: none; }
.widget-hot .hot-index { width: 20px; height: 20px; line-height: 20px; text-align: center; border-radius: 50%; background: #f0f0f0; color: #999; font-size: 12px; flex-shrink: 0; margin-top: 2px; }
.widget-hot .hot-list li:nth-child(1) .hot-index { background: #ff4d4f; color: #fff; }
.widget-hot .hot-list li:nth-child(2) .hot-index { background: #ff7a45; color: #fff; }
.widget-hot .hot-list li:nth-child(3) .hot-index { background: #ffc53d; color: #fff; }
.widget-hot .hot-list li:nth-child(4) .hot-index { background: #73d13d; color: #fff; }
.widget-hot .hot-list li:nth-child(5) .hot-index { background: #40a9ff; color: #fff; }
.widget-hot .hot-content { flex: 1; min-width: 0; display: flex; flex-direction: column; gap: 2px; }
.widget-hot .hot-user { font-size: 12px; color: var(--text-muted); text-align: left; line-height: 1.4; }
.widget-hot .hot-title { display: block; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; font-size: 14px; color: var(--text-main); line-height: 1.5; }
.widget-hot .hot-title:hover { color: var(--primary-color); }

.pagination { margin-top: 30px; text-align: center; padding-bottom: 30px; }
.pagination .now-page, .pagination a { 
    display: inline-block; 
    vertical-align: middle;
    box-sizing: border-box;
    width: 30px;
    height: 30px;
    line-height: 28px;
    padding: 0;
    text-align: center;
    background: var(--bg-card); 
    margin: 0 3px; 
    border-radius: 4px; 
    color: var(--text-secondary); 
    font-size: 13px;
    border: 1px solid var(--border-divider);
    box-shadow: none;
    transition: all 0.2s;
}
.pagination .now-page { 
    background: var(--primary-color); 
    color: #fff; 
    border-color: var(--primary-color);
}
.pagination a:hover { 
    background: var(--hover-bg); 
    color: var(--primary-color); 
    border-color: var(--primary-color);
}

.site-footer { background: var(--bg-header); color: var(--text-placeholder); padding: 40px 0; text-align: center; font-size: 14px; margin-top: 40px; border-top: 1px solid var(--border-divider); transition: background-color 0.3s; }

.filter-item {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    padding: 2px 8px;
    min-width: 36px;
    border-radius: 20px;
    color: var(--text-placeholder);
    transition: all 0.2s;
    text-decoration: none;
    border: 1px solid transparent;
    box-sizing: border-box;
    white-space: nowrap;
}
.filter-item:hover {
    color: var(--primary-color);
    background: var(--hover-bg);
}
.filter-item.active {
    background: var(--pan-filter-accent, var(--primary-color));
    color: #fff;
    border-color: var(--pan-filter-accent, var(--primary-color));
}

.site-notice-box {
    background: var(--hover-bg);
    border-radius: 6px;
    padding: 12px 20px;
    display: flex;
    align-items: center;
    justify-content: space-between;
    color: var(--primary-color);
    font-size: 14px;
    box-sizing: border-box;
    flex-wrap: wrap;
}
.site-notice-content {
    display: flex;
    align-items: center;
    gap: 10px;
    flex: 1;
    min-width: 0;
    word-wrap: break-word;
    word-break: break-all;
    overflow-wrap: break-word;
    line-height: 1.5;
}
.site-notice-content i {
    font-size: 16px;
    flex-shrink: 0;
}
.site-notice-close {
    color: var(--primary-color);
    opacity: 0.6;
    transition: opacity 0.2s;
    font-size: 16px;
    padding: 0 5px;
    cursor: pointer;
    flex-shrink: 0;
}
.site-notice-close:hover {
    opacity: 1;
}

.global-ad-box {
    overflow: hidden;
}
.global-ad-box img,
.global-ad-box iframe,
.global-ad-box video {
    max-width: 100% !important;
    height: auto !important;
    display: block;
    margin: 0 auto;
}

.top-badge {
    background: linear-gradient(135deg, #ff6b6b, #ee5253);
    color: #fff;
    font-size: 12px;
    padding: 1px 6px;
    border-radius: 4px;
    margin-right: 6px;
    font-weight: normal;
    display: inline-block;
    vertical-align: middle;
    line-height: 1.4;
}

.single-post, .single-page {
    background: var(--bg-card);
    padding: 24px;
    border-radius: 8px;
    box-shadow: 0 1px 2px var(--shadow-light);
    margin-bottom: 20px;
}
.single-header {
    border-bottom: 1px solid var(--border-divider);
    padding-bottom: 14px;
    margin-bottom: 14px;
}
.single-title {
    font-size: 20px;
    color: var(--text-main);
    margin-bottom: 8px;
    line-height: 1.4;
    font-weight: bold;
}
.single-meta {
    font-size: 13px;
    color: var(--text-muted);
    line-height: 1.5;
}
.single-meta span {
    margin-right: 15px;
}
.single-meta a {
    color: var(--text-secondary);
}
.single-meta a:hover {
    color: var(--primary-color);
}
.single-content {
    font-size: 16px;
    line-height: 1.8;
    color: var(--text-main);
    word-wrap: break-word;
    word-break: break-word;
    overflow-wrap: break-word;
}
.single-content p {
    margin-bottom: 15px;
}
.single-content img {
    max-width: 100%;
    height: auto;
    border-radius: 4px;
    margin: 10px 0;
}
.download-box {
    background: var(--bg-input);
    padding: 20px;
    border-radius: 8px;
    margin: 30px 0;
    border: 1px dashed var(--border-color);
}
.download-box h3 {
    margin: 0 0 15px;
    font-size: 16px;
    border-left: 4px solid var(--primary-color);
    padding-left: 10px;
}
.download-box p {
    margin: 5px 0;
    font-size: 14px;
    color: var(--text-secondary);
}
.post-tags {
    margin-top: 30px;
    padding-top: 20px;
    border-top: 1px solid var(--border-divider);
    color: var(--text-secondary);
    font-size: 14px;
}
.post-tags a {
    display: inline-block;
    background: var(--bg-badge);
    padding: 2px 8px;
    border-radius: 4px;
    color: var(--text-secondary);
    margin: 0 5px;
    font-size: 12px;
    transition: all 0.2s;
}
.post-tags a:hover {
    color: var(--primary-color);
    background: var(--hover-bg);
}

.post-navigation {
    display: flex;
    justify-content: space-between;
    margin-top: 30px;
    padding-top: 20px;
    border-top: 1px dashed var(--border-divider);
    font-size: 14px;
}
.post-nav-prev, .post-nav-next {
    width: 48%;
    display: flex;
    flex-direction: column;
    gap: 5px;
    overflow: hidden;
}
.post-nav-prev span:first-child, .post-nav-next span:first-child {
    color: var(--text-muted);
    font-size: 12px;
}
.post-nav-prev a, .post-nav-next a {
    color: var(--text-main);
    overflow: hidden;
    text-overflow: ellipsis;
    white-space: nowrap;
    display: block;
    max-width: 100%;
}
.post-nav-prev a:hover, .post-nav-next a:hover {
    color: var(--primary-color);
}
.post-nav-next {
    text-align: right;
    align-items: flex-end;
}
.nav-none {
    color: var(--text-placeholder);
}

.related-articles {
    margin-top: 30px;
    padding-top: 20px;
    border-top: 1px dashed var(--border-divider);
}
.related-articles h3 {
    font-size: 16px;
    margin-bottom: 15px;
    border-left: 4px solid var(--primary-color);
    padding-left: 10px;
}
.related-articles ul {
    list-style: none;
    padding: 0;
    margin: 0;
    display: flex;
    flex-wrap: wrap;
    margin-left: -10px;
    margin-right: -10px;
}
.related-articles li {
    width: 50%;
    padding: 0 10px;
    margin-bottom: 4px;
    line-height: 1.5;
    box-sizing: border-box;
    display: flex;
    align-items: center;
    font-size: 13px;
}
.related-index {
    display: inline-block;
    width: 16px;
    height: 16px;
    line-height: 16px;
    text-align: center;
    background: #e9ecef;
    color: #495057;
    border-radius: 4px;
    font-size: 11px;
    margin-right: 6px;
    flex-shrink: 0;
}
.related-articles li a {
    color: var(--text-main);
    display: block;
    overflow: hidden;
    text-overflow: ellipsis;
    white-space: nowrap;
    flex-grow: 1;
}
.related-articles li a:hover {
    color: var(--primary-color);
}

.friend-links {
    margin-bottom: 20px;
    padding-bottom: 20px;
    border-bottom: 1px solid var(--border-divider);
    display: flex;
    flex-wrap: wrap;
    align-items: center;
    font-size: 14px;
}
.friend-links-label {
    font-weight: bold;
    margin-right: 10px;
    color: var(--text-main);
}
.friend-links-items {
    display: flex;
    flex-wrap: wrap;
    gap: 15px;
    margin: 0;
    padding: 0;
    list-style: none;
}
.friend-links-items li {
    margin: 0;
}
.friend-links-items li a {
    color: var(--text-secondary);
    text-decoration: none;
}
.friend-links-items li a:hover {
    color: var(--primary-color);
}

.mobile-menu-icon { display: none; }
.mobile-bottom-nav { display: none; }

@media (max-width: 992px) {
    .site-header { padding: 10px 0; position: static; }
    .site-header .container { display: flex; flex-wrap: nowrap; align-items: center; gap: 10px; }

    .site-header .container {
        flex-direction: column;
        gap: 12px;
        padding-top: 10px;
        padding-bottom: 10px;
    }
    .logo { width: 100%; flex: 0 0 auto; margin-right: 0; padding-left: 0; justify-content: center; order: 1; }
    .logo a { justify-content: center; }

    .main-nav { width: 100%; flex: 0 0 auto; order: 2; overflow-x: auto; -webkit-overflow-scrolling: touch; }
    .main-nav ul { flex-wrap: nowrap; overflow-x: auto; -webkit-overflow-scrolling: touch; padding: 5px; justify-content: flex-start; scrollbar-width: none; -ms-overflow-style: none; }
    .main-nav ul::-webkit-scrollbar { height: 0; display: none; }
    .main-nav li { flex: 0 0 auto; }

    .search-box { width: 100%; margin-left: 0; flex: 0 0 auto; order: 3; }
    .top-search-wrap { flex: 1; }
    .search-box form { flex: 1; }
    .search-box input { width: 100%; min-width: 0; padding: 7px 12px; font-size: 14px; }
    .search-box button { padding: 7px 12px; min-width: 56px; white-space: nowrap; font-size: 14px; }
    .top-search-suggest { width: 100%; }

    .user-avatar { display: none !important; }
    .mobile-menu-icon { display: block !important; font-size: 20px; color: var(--text-color); padding: 8px; }

    .dark-mode-toggle {
        position: fixed;
        bottom: 80px;
        right: 20px;
        z-index: 9999;
        background: transparent;
        color: #ff4d4f;
        border: none;
        box-shadow: none;
        border-radius: 0;
        width: auto;
        height: auto;
        justify-content: center;
        margin-left: 0;
        padding: 10px;
        font-size: 40px;
        transition: transform 0.3s;
    }
    .dark-mode-toggle:hover { 
        transform: scale(1.1);
        box-shadow: none;
        background: transparent;
        color: #ff4d4f;
    }
    .dark-mode-toggle:active { transform: scale(0.95); }
    body.dark-mode .dark-mode-toggle {
        background: transparent;
        color: #ff4d4f;
        border: none;
        box-shadow: none;
    }
    body.dark-mode .dark-mode-toggle:hover {
        color: #ff4d4f;
        background: transparent;
    }

    .main-wrapper { flex-direction: column; padding-top: 10px; gap: 12px; }
    .site-notice-container { margin-bottom: 12px !important; }
    .left-sidebar, .right-sidebar, .center-content { width: 100%; position: static; top: auto; }

    .left-nav-card { padding: 12px; }
    .left-nav-list { display: flex; gap: 6px; overflow-x: auto; -webkit-overflow-scrolling: touch; padding: 0; scrollbar-width: none; -ms-overflow-style: none; overscroll-behavior-x: contain; scroll-behavior: smooth; }
    .left-nav-list::-webkit-scrollbar { height: 0; display: none; }
    .left-nav-list li { margin-bottom: 0; flex: 0 0 auto; }
    .left-nav-list li a { padding: 6px 10px; white-space: nowrap; justify-content: center; gap: 4px; font-size: 12px; line-height: 1.1; background: var(--bg-input); border: 1px solid transparent; border-radius: 999px; }
    .left-nav-list li.is-category a { background-color: rgba(0, 123, 255, 0.06); background-color: color-mix(in srgb, var(--pan-menu-accent, var(--primary-color)) 8%, var(--bg-card)); }
    .left-nav-list li.is-filter a,
    .left-nav-list li.is-child-menu a { padding: 5px 8px; font-size: 11px; }
    .left-nav-list li.is-child-menu a { border-color: transparent; }
    .left-nav-list li.is-filter a .nav-icon,
    .left-nav-list li.is-child-menu a .nav-icon { width: auto; }
    .left-nav-list li.is-filter a i,
    .left-nav-list li.is-child-menu a i { font-size: 12px; }
    .left-nav-list li a i { font-size: 13px; margin-right: 0; }
    .left-nav-list li a .nav-icon { width: auto; margin-right: 0; }
    .left-nav-list li.active a { background-color: rgba(0, 123, 255, 0.14); background-color: color-mix(in srgb, var(--pan-menu-accent, var(--primary-color)) 16%, var(--bg-card)); border-color: transparent; }
    .left-nav-list li.is-category.active a { background-color: rgba(0, 123, 255, 0.14); background-color: color-mix(in srgb, var(--pan-menu-accent, var(--primary-color)) 16%, var(--bg-card)); border-color: transparent; box-shadow: none; }
    .nav-divider { display: none; }

    .post-list-item { align-items: center; position: relative; padding-right: 76px; }
    .post-info { flex: 1 1 auto; min-width: 0; }
    .post-title a { white-space: normal; overflow: hidden; text-overflow: ellipsis; display: -webkit-box; -webkit-line-clamp: 2; -webkit-box-orient: vertical; word-break: break-word; }
    .post-action { position: absolute; top: 50%; right: 12px; transform: translateY(-50%); margin-left: 0; display: flex; align-items: center; justify-content: center; }

    .single-post, .single-page, .widget { padding: 12px; }
    .post-navigation { flex-direction: column; gap: 12px; }
    .post-nav-prev, .post-nav-next { width: 100%; }
    .post-nav-next { align-items: flex-start; text-align: left; }

    .related-articles li { width: 100%; }

    .category-header-box {
        position: -webkit-sticky;
        position: sticky;
        top: 0;
        z-index: 99;
        margin-left: -15px;
        margin-right: -15px;
        border-radius: 0 !important;
        padding: 15px 15px !important;
        box-shadow: 0 2px 4px rgba(0,0,0,0.05) !important;
        border-bottom: 1px solid var(--border-divider);
    }

    .site-footer {
        padding: 20px 0;
        margin-top: 20px;
    }
    .site-footer p {
        margin: 5px 0;
        line-height: 1.5;
        word-wrap: break-word;
        word-break: break-word;
    }

    .mobile-bottom-nav {
        display: block;
        position: fixed;
        bottom: 0;
        left: 0;
        right: 0;
        z-index: 9998;
        background: var(--bg-card);
        border-top: 1px solid var(--border-divider);
        box-shadow: 0 -2px 10px rgba(0,0,0,0.05);
        padding-bottom: constant(safe-area-inset-bottom);
        padding-bottom: env(safe-area-inset-bottom);
    }
    .mobile-bottom-nav-list {
        display: flex;
        justify-content: space-around;
        align-items: center;
        padding: 8px 0;
        margin: 0;
        list-style: none;
    }
    .mobile-bottom-nav-list li {
        flex: 1;
        display: flex;
        justify-content: center;
        margin: 0;
    }
    .mobile-bottom-nav-list li a {
        display: flex;
        flex-direction: column;
        align-items: center;
        gap: 2px;
        padding: 4px 8px;
        color: var(--text-secondary);
        text-decoration: none;
        transition: color 0.2s;
    }
    .mobile-bottom-nav-list li a i {
        font-size: 20px;
    }
    .mobile-bottom-nav-list li a span {
        font-size: 11px;
        line-height: 1.1;
    }
    .mobile-bottom-nav-list li.active a,
    .mobile-bottom-nav-list li a:hover {
        color: var(--primary-color);
    }
    .mobile-bottom-nav-list li.active a i {
        color: var(--primary-color);
    }
    
    .site-footer {
        padding-bottom: calc(70px + constant(safe-area-inset-bottom));
        padding-bottom: calc(70px + env(safe-area-inset-bottom));
    }
    
    .widget-user-panel {
        padding: 12px !important;
    }
    .user-panel-header {
        gap: 10px;
        padding: 8px 0 10px 0 !important;
        flex-direction: column;
        justify-content: center;
        text-align: center;
    }
    .user-panel-info {
        text-align: center;
    }
    .user-panel-avatar {
        width: 46px;
        height: 46px;
    }
    .user-avatar-letter {
        width: 46px !important;
        height: 46px !important;
        font-size: 20px !important;
    }
    .user-avatar-guest-panel {
        width: 46px !important;
        height: 46px !important;
        font-size: 20px !important;
    }
    .user-panel-name {
        font-size: 13px !important;
    }
    .user-panel-role {
        font-size: 10px !important;
    }
    .user-panel-buttons {
        flex-direction: column;
        gap: 6px;
        padding: 10px 0 !important;
    }
    .btn-block {
        width: 100%;
        padding: 10px 10px !important;
        font-size: 12px !important;
    }
    .user-panel-stats {
        padding: 10px 0 !important;
        gap: 6px !important;
    }
    .stat-item {
        padding: 8px 4px !important;
    }
    .stat-label {
        font-size: 9px !important;
    }
    .stat-value {
        font-size: 13px !important;
    }
    .user-panel-footer {
        padding-top: 10px !important;
    }
    .user-panel-logout {
        padding: 8px 12px !important;
        font-size: 12px !important;
    }
    .user-panel-tips {
        padding: 8px !important;
        margin-top: 6px !important;
    }
    .user-panel-tips p {
        font-size: 11px !important;
    }
}

/* Lazy Load Images */
.pan-lazy-image {
    filter: blur(8px);
    transition: filter 0.4s ease-out;
}

.pan-lazy-image.pan-lazy-loaded {
    filter: blur(0);
}

@media (max-width: 480px) {
    .container { padding: 0 12px; }
    .logo { font-size: 20px; }
    .search-box input { padding: 8px 12px; }
    .search-box button { min-width: 52px; }
    .post-list-item { padding: 10px; padding-right: 70px; }
    .post-title { font-size: 14px; }
    .single-title { font-size: 17px; }
    .post-action { top: 50%; right: 10px; transform: translateY(-50%); }
    .left-nav-list { gap: 6px; }
    .left-nav-list li a { padding: 7px 10px; font-size: 12px; }
    .left-nav-list li.is-filter a,
    .left-nav-list li.is-child-menu a { padding: 5px 8px; font-size: 10px; }
    
    .category-header-box {
        margin-left: -12px;
        margin-right: -12px;
        padding-left: 12px !important;
        padding-right: 12px !important;
    }

    .site-footer {
        padding: 15px 0;
        font-size: 12px;
    }
}

/* Single content heading styles */
html { scroll-behavior: smooth; }

/* Refined friend links and footer */
.friend-links-section {
    margin: 34px 0 0;
}
.friend-links-section .container {
    max-width: 1170px;
}
.friend-links-section .friend-links {
    display: block;
    margin: 0;
    padding: 17px 26px 18px;
    border: 1px solid var(--border-divider);
    border-radius: 8px;
    background: var(--bg-card);
    box-shadow: none;
}
.friend-links-heading {
    display: block;
    margin-bottom: 13px;
    padding-bottom: 11px;
    border-bottom: 1px solid var(--border-divider);
}
.friend-links-section .friend-links-label {
    margin: 0;
    color: var(--text-main);
    font-size: 22px;
    font-weight: 700;
    line-height: 1.35;
}
.friend-links-section .friend-links-items {
    display: flex;
    flex-wrap: wrap;
    column-gap: 68px;
    row-gap: 9px;
    margin: 0;
    padding: 0;
    list-style: none;
}
.friend-links-section .friend-links-items li {
    margin: 0;
}
.friend-links-section .friend-links-items a {
    display: inline-block;
    padding: 0;
    color: var(--text-secondary);
    font-size: 16px;
    line-height: 1.6;
    transition: color .2s ease;
}
.friend-links-section .friend-links-items a:hover {
    color: #1677ff;
}

.site-footer {
    position: relative;
    margin-top: 34px;
    padding: 38px 0 34px;
    border-top: 0;
    background: linear-gradient(135deg, #25282d 0%, #30343a 55%, #292d32 100%);
    color: #aeb5bf;
    font-size: 14px;
}
.site-footer::before {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 1px;
    background: linear-gradient(90deg, transparent, rgba(78, 173, 255, .75), transparent);
    content: "";
}
.site-footer-inner {
    display: flex;
    flex-direction: column;
    align-items: center;
}
.footer-nav {
    width: 100%;
    margin-bottom: 19px;
}
.footer-nav ul {
    display: flex;
    flex-wrap: wrap;
    align-items: center;
    justify-content: center;
    gap: 0;
    margin: 0;
    padding: 0;
    list-style: none;
}
.footer-nav li {
    display: flex;
    align-items: center;
    margin: 0;
}
.footer-nav li + li::before {
    width: 1px;
    height: 13px;
    margin: 0 20px;
    background: rgba(255, 255, 255, .25);
    content: "";
}
.footer-nav a,
.site-footer a {
    color: #e6e9ed;
    text-decoration: none;
    transition: color .2s ease;
}
.footer-nav a {
    font-size: 15px;
}
.footer-nav a:hover,
.site-footer a:hover {
    color: #55b9ff;
}
.footer-custom-content {
    max-width: 100%;
    margin: 0 0 12px;
    color: #c4cad2;
    line-height: 1.8;
}
.footer-meta {
    display: flex;
    flex-wrap: wrap;
    align-items: center;
    justify-content: center;
    gap: 9px 24px;
}
.footer-meta p,
.site-footer .footer-site-copyright {
    margin: 0;
    line-height: 1.8;
}
.footer-site-copyright p {
    margin: 0;
}
.footer-meta i {
    margin-right: 6px;
    color: #55b9ff;
}
.footer-copyright:empty {
    display: none;
}
.footer-copyright:not(:empty) {
    margin-top: 8px;
}

.pan-back-to-top {
    position: fixed;
    right: 28px;
    bottom: 38px;
    z-index: 9997;
    display: flex;
    width: 54px;
    height: 54px;
    padding: 0;
    align-items: center;
    justify-content: center;
    border: 1px solid rgba(22, 145, 255, .55);
    border-radius: 50%;
    outline: 0;
    background: rgba(255, 255, 255, .96);
    box-shadow: 0 8px 24px rgba(16, 44, 76, .16);
    cursor: pointer;
    opacity: 0;
    pointer-events: none;
    transform: translateY(14px);
    transition: opacity .22s ease, transform .22s ease, border-color .2s ease, background-color .2s ease, box-shadow .2s ease;
}
.pan-back-to-top span {
    width: 13px;
    height: 13px;
    margin-top: 7px;
    border-top: 1.5px solid #168ef7;
    border-left: 1.5px solid #168ef7;
    transform: rotate(45deg);
}
.pan-back-to-top.is-visible {
    opacity: 1;
    pointer-events: auto;
    transform: translateY(0);
}
.pan-back-to-top:hover {
    border-color: #168ef7;
    background: #168ef7;
    box-shadow: 0 10px 26px rgba(22, 142, 247, .3);
    transform: translateY(-3px);
}
.pan-back-to-top:hover span {
    border-color: #fff;
}

@media (max-width: 768px) {
    .friend-links-section {
        margin-top: 22px;
    }
    .friend-links-section .friend-links {
        padding: 15px 16px 16px;
    }
    .friend-links-heading {
        margin-bottom: 11px;
        padding-bottom: 10px;
    }
    .friend-links-section .friend-links-label {
        font-size: 19px;
    }
    .friend-links-section .friend-links-items {
        column-gap: 28px;
        row-gap: 8px;
    }
    .friend-links-section .friend-links-items a {
        font-size: 14px;
    }
    .site-footer {
        margin-top: 24px;
        padding: 28px 0 calc(86px + env(safe-area-inset-bottom));
        font-size: 12px;
    }
    .footer-nav {
        margin-bottom: 15px;
    }
    .footer-nav a {
        font-size: 13px;
    }
    .footer-nav li + li::before {
        margin: 0 10px;
    }
    .footer-meta {
        flex-direction: column;
        gap: 3px;
    }
    .pan-back-to-top {
        right: 14px;
        bottom: calc(76px + env(safe-area-inset-bottom));
        width: 46px;
        height: 46px;
    }
}
.single-content h1,
.single-content h2,
.single-content h3,
.single-content h4,
.single-content h5 {
    margin: 10px 0 8px;
    line-height: 1.35;
    scroll-margin-top: 80px;
    border: 1px solid #e9ecef;
    border-radius: 12px;
    background: #fff;
    position: relative;
    padding: 6px 12px 6px 22px;
}
.single-content h1 { font-size: 22px; color: #0d6efd; border-left: 14px solid #0d6efd; border-radius: 14px; box-shadow: 0 6px 16px rgba(13,110,253,.66); }
.single-content h2 { font-size: 20px; color: #6610f2; border-left: 12px solid #6610f2; border-radius: 12px; box-shadow: 0 6px 16px rgba(102,16,242,.66); }
.single-content h3 { font-size: 18px; color: #198754; border-left: 10px solid #198754; border-radius: 10px; box-shadow: 0 6px 16px rgba(25,135,84,.66); }
.single-content h4 { font-size: 16px; color: #fd7e14; border-left: 8px solid #fd7e14; border-radius: 8px; box-shadow: 0 6px 16px rgba(253,126,20,.66); }
.single-content h5 { font-size: 14px; color: #6c757d; border-left: 6px solid #6c757d; border-radius: 6px; box-shadow: 0 6px 16px rgba(108,117,125,.66); }
@media (max-width: 576px) {
    .post-meta .meta-author, .post-meta .meta-date, .post-meta .meta-cate, .post-meta .meta-extcate { display: none !important; }
    .single-content h1 { box-shadow: 0 3px 8px rgba(13,110,253,.72); }
    .single-content h2 { box-shadow: 0 3px 8px rgba(102,16,242,.72); }
    .single-content h3 { box-shadow: 0 3px 8px rgba(25,135,84,.72); }
    .single-content h4 { box-shadow: 0 3px 8px rgba(253,126,20,.72); }
    .single-content h5 { box-shadow: 0 3px 8px rgba(108,117,125,.72); }
}

/* Version card */
.version-card-section .ver-card {
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: 14px 16px;
    border: 1px solid #cfe2ff;
    background: #f1f8ff;
    border-left: 4px solid #0d6efd;
    border-radius: 12px;
    box-shadow: 0 2px 8px rgba(13,110,253,.06);
}
.version-card-section .ver-left {
    display: flex;
    align-items: center;
    gap: 10px;
    color: #0b5ed7;
    font-size: 15px;
}
.version-card-section .ver-btn {
    display: inline-block;
    padding: 8px 16px;
    background: #0d6efd;
    color: #fff;
    border-radius: 8px;
    text-decoration: none;
    transition: background .2s;
}
.version-card-section .ver-btn:hover {
    background: #0b5ed7;
}
.version-card-section .ver-icon {
    font-size: 16px;
}

/* Minor utilities */
.version-card-section { margin-top: 16px; }
.text-danger { color: #d9534f !important; }
.note-muted { font-size: 12px; color: #999; }
.post-list-item .post-thumb { width: 56px; height: 56px; flex: 0 0 56px; border-radius: 6px; overflow: hidden; background: var(--bg-input); }
.post-thumb-link { display: block; width: 100%; height: 100%; }
.post-thumb-img { width: 100%; height: 100%; object-fit: cover; border-radius: 6px; }
.post-icon-fallback { display: flex; width: 100%; height: 100%; align-items: center; justify-content: center; color: #fff; border-radius: 6px; font-size: 22px; }
.post-meta-accent { color: var(--primary-color); }

/* Index search hero */
.index-search-box { margin-top: 20px; }
.index-search-hero {
    background: rgba(0, 0, 0, 0.25);
    backdrop-filter: blur(10px);
    -webkit-backdrop-filter: blur(10px);
    padding: 40px 20px;
    border-radius: 12px;
    border: 1px solid rgba(255, 255, 255, 0.15);
    box-shadow: 0 8px 32px 0 rgba(0, 0, 0, 0.1);
    text-align: center;
    color: #fff;
}
.index-search-title { font-size: 32px; margin: 0 0 10px 0; font-weight: normal; }
.index-search-desc { font-size: 16px; margin: 0 0 30px 0; opacity: 0.9; }
.index-search-form { max-width: 600px; margin: 0 auto; display: flex; gap: 10px; }
.index-search-input {
    flex: 1; padding: 12px 15px; border: none; border-radius: 6px;
    outline: none; font-size: 16px; height: 48px; box-sizing: border-box;
}
.index-search-input:focus { box-shadow: 0 0 0 2px rgba(0,123,255,0.3); }
.index-search-button {
    padding: 0 30px; background: #007bff; color: #fff; border: none; border-radius: 6px;
    font-size: 16px; cursor: pointer; height: 40px; transition: background 0.2s;
}
.index-search-button:hover { background: #0069d9; }

/* Full-bleed index search section */
.index-search-section {
    margin-top: 20px;
    margin-left: calc(50% - 50vw);
    margin-right: calc(50% - 50vw);
    padding-left: 15px;
    padding-right: 15px;
}

/* Portal-style index home */
.index-portal-section {
    margin-top: 20px;
    margin-left: calc(50% - 50vw);
    margin-right: calc(50% - 50vw);
    padding: 0 15px;
}
.index-portal-hero {
    display: grid;
    grid-template-columns: minmax(0, 1.4fr) minmax(280px, 0.9fr);
    gap: 20px;
    padding: 26px;
    border-radius: 18px;
    background:
        linear-gradient(135deg, rgba(49, 91, 255, 0.94) 0%, rgba(108, 79, 255, 0.92) 45%, rgba(16, 185, 129, 0.88) 100%);
    box-shadow: 0 18px 50px rgba(41, 69, 161, 0.22);
    color: #fff;
}
.index-portal-main {
    min-width: 0;
}
.index-portal-badge {
    display: inline-flex;
    align-items: center;
    min-height: 30px;
    padding: 0 14px;
    border-radius: 999px;
    background: rgba(255, 255, 255, 0.18);
    font-size: 13px;
    font-weight: 700;
    letter-spacing: 0.5px;
}
.index-portal-title {
    margin: 18px 0 10px;
    font-size: 38px;
    line-height: 1.25;
    font-weight: 700;
}
.index-portal-desc {
    max-width: 760px;
    margin: 0 0 24px;
    font-size: 15px;
    line-height: 1.8;
    color: rgba(255, 255, 255, 0.92);
}
.index-portal-search-form {
    display: flex;
    gap: 12px;
    max-width: 720px;
}
.index-portal-search-input {
    flex: 1;
    height: 52px;
    padding: 0 18px;
    border: none;
    border-radius: 12px;
    background: rgba(255, 255, 255, 0.96);
    color: #1f2937;
    font-size: 15px;
    box-shadow: 0 10px 20px rgba(0, 0, 0, 0.08);
}
.index-portal-search-button {
    height: 52px;
    padding: 0 24px;
    border: none;
    border-radius: 12px;
    background: #111827;
    color: #fff;
    font-size: 15px;
    font-weight: 700;
}
.index-portal-search-button:hover {
    background: #0b1220;
}
.index-portal-tags {
    display: flex;
    flex-wrap: wrap;
    gap: 10px;
    margin-top: 18px;
}
.index-portal-tag {
    display: inline-flex;
    align-items: center;
    min-height: 34px;
    padding: 0 14px;
    border-radius: 999px;
    background: rgba(255, 255, 255, 0.14);
    color: #fff;
    font-size: 13px;
}
.index-portal-tag:hover {
    background: rgba(255, 255, 255, 0.24);
    color: #fff;
}
.index-portal-stats {
    display: grid;
    grid-template-columns: 1fr;
    gap: 14px;
}
.index-portal-stat-card {
    padding: 18px;
    border-radius: 14px;
    background: rgba(255, 255, 255, 0.14);
    backdrop-filter: blur(8px);
    -webkit-backdrop-filter: blur(8px);
    border: 1px solid rgba(255, 255, 255, 0.16);
}
.index-portal-stat-value {
    font-size: 30px;
    line-height: 1.1;
    font-weight: 700;
}
.index-portal-stat-title {
    margin-top: 8px;
    font-size: 16px;
    font-weight: 700;
}
.index-portal-stat-desc {
    margin-top: 6px;
    font-size: 13px;
    line-height: 1.7;
    color: rgba(255, 255, 255, 0.86);
}
.index-portal-panels {
    display: grid;
    grid-template-columns: minmax(0, 1.25fr) minmax(280px, 0.95fr);
    gap: 20px;
    margin-top: 20px;
}
.index-portal-panel {
    padding: 20px;
    border-radius: 16px;
    background: rgba(255, 255, 255, 0.9);
    box-shadow: 0 12px 40px rgba(15, 23, 42, 0.08);
    backdrop-filter: blur(10px);
    -webkit-backdrop-filter: blur(10px);
}
.index-portal-panel-title {
    margin-bottom: 16px;
    font-size: 18px;
    font-weight: 700;
    color: #111827;
}
.index-portal-category-grid {
    display: grid;
    grid-template-columns: repeat(3, minmax(0, 1fr));
    gap: 14px;
}
.index-portal-category-card {
    display: flex;
    align-items: center;
    gap: 10px;
    min-height: 54px;
    padding: 0 16px;
    border-radius: 12px;
    background: linear-gradient(180deg, rgba(255,255,255,0.95) 0%, rgba(243,247,255,0.95) 100%);
    border: 1px solid rgba(79, 124, 255, 0.12);
    box-shadow: inset 0 1px 0 rgba(255,255,255,0.85);
    color: #1f2937;
}
.index-portal-category-card:hover {
    transform: translateY(-2px);
    box-shadow: 0 12px 24px rgba(79, 124, 255, 0.16);
    color: #111827;
}
.index-portal-category-dot {
    width: 10px;
    height: 10px;
    border-radius: 50%;
    flex: 0 0 10px;
    background: var(--portal-accent, #4f7cff);
    box-shadow: 0 0 0 4px rgba(79, 124, 255, 0.12);
}
.index-portal-category-name {
    font-size: 14px;
    font-weight: 600;
}
.index-portal-copy p {
    margin: 0 0 12px;
    color: #475569;
    line-height: 1.9;
    font-size: 14px;
}
.index-portal-copy p:last-child {
    margin-bottom: 0;
}

body.dark-mode .index-portal-panel {
    background: rgba(36, 37, 38, 0.9);
    box-shadow: 0 12px 40px rgba(0, 0, 0, 0.2);
}
body.dark-mode .index-portal-panel-title,
body.dark-mode .index-portal-category-card,
body.dark-mode .index-portal-category-card:hover {
    color: #e4e6eb;
}
body.dark-mode .index-portal-copy p {
    color: #c9d1d9;
}
body.dark-mode .index-portal-category-card {
    background: linear-gradient(180deg, rgba(44, 46, 48, 0.96) 0%, rgba(36, 38, 40, 0.96) 100%);
    border-color: rgba(79, 124, 255, 0.24);
}
body.dark-mode .index-portal-search-input {
    background: rgba(255, 255, 255, 0.94);
    color: #111827;
}

@media (max-width: 992px) {
    .index-portal-hero,
    .index-portal-panels {
        grid-template-columns: 1fr;
    }
    .index-portal-category-grid {
        grid-template-columns: repeat(2, minmax(0, 1fr));
    }
}

@media (max-width: 640px) {
    .index-portal-hero,
    .index-portal-panel {
        padding: 18px;
        border-radius: 14px;
    }
    .index-portal-title {
        font-size: 28px;
    }
    .index-portal-search-form {
        flex-direction: column;
    }
    .index-portal-search-button,
    .index-portal-search-input {
        width: 100%;
    }
    .index-portal-category-grid {
        grid-template-columns: 1fr;
    }
}

/* Portal home main layout */
.portal-home-wrapper {
    margin-top: 20px;
}
.portal-home-main {
    min-width: 0;
}
.portal-home-board {
    margin-bottom: 20px;
    padding: 16px 18px;
    border: 1px solid #8d8d8d;
    border-radius: 6px;
    background: #f7f7f7;
    box-shadow: none;
}
.portal-filter-panel {
    position: static;
    top: auto;
    z-index: auto;
    backdrop-filter: none;
    -webkit-backdrop-filter: none;
}
.portal-home-board-header {
    display: flex;
    align-items: flex-end;
    justify-content: space-between;
    gap: 12px;
    margin-bottom: 16px;
}
.portal-home-board-title {
    margin: 0;
    font-size: 20px;
    line-height: 1.2;
}
.portal-home-board-desc {
    color: var(--text-muted);
    font-size: 13px;
}
.portal-filter-board {
    display: flex;
    flex-direction: column;
    gap: 8px;
    padding-left: 0;
}
.portal-filter-row {
    display: grid;
    grid-template-columns: 78px auto minmax(0, 1fr);
    gap: 8px;
    align-items: start;
}
.portal-filter-label {
    display: inline-flex;
    align-items: center;
    justify-content: flex-end;
    min-height: 30px;
    color: #222;
    font-size: 15px;
    font-weight: 700;
    white-space: nowrap;
}
.portal-filter-items {
    display: flex;
    flex-wrap: wrap;
    gap: 6px;
    min-width: 0;
}
.portal-filter-item {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    min-height: 26px;
    width: 64px;
    padding: 0 3px;
    border: 1px solid #8d8d8d;
    border-radius: 4px;
    background: linear-gradient(180deg, #f8f0d8 0%, #efe4c1 100%);
    color: #333;
    font-size: 12px;
    line-height: 1;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
    box-shadow: inset 0 1px 0 rgba(255, 255, 255, 0.7);
    transition: all 0.18s;
}
.portal-filter-item:hover {
    color: #c62828;
    border-color: #9d8f6f;
    background: linear-gradient(180deg, #fbf4de 0%, #f1e6c5 100%);
}
.portal-filter-item.is-active {
    color: #fff;
    font-weight: 700;
    border-color: #bf271d;
    background: linear-gradient(180deg, #ff5b4a 0%, #e8392e 100%);
    box-shadow: inset 0 1px 0 rgba(255, 255, 255, 0.18);
}
.portal-filter-item.is-all {
    color: #333;
}
.portal-filter-item.is-all:hover {
    color: #c62828;
}
.portal-filter-item.is-all.is-active {
    color: #fff;
}
.portal-active-filters {
    display: flex;
    align-items: center;
    flex-wrap: wrap;
    gap: 8px;
    margin-top: 14px;
    padding-top: 12px;
    border-top: 1px dashed #bdbdbd;
}
.portal-active-filters-label {
    color: #555;
    font-size: 12px;
    font-weight: 700;
}
.portal-active-filter-chip {
    display: inline-flex;
    align-items: center;
    gap: 8px;
    min-height: 26px;
    padding: 0 10px;
    border: 1px solid #d8c7a0;
    border-radius: 4px;
    background: #f5ecd2;
    color: #7b5a1d;
    font-size: 11px;
    font-weight: 600;
}
.portal-active-filter-chip:hover {
    color: #a3471a;
    background: #f0e3bf;
}
.portal-active-filter-remove {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 18px;
    height: 18px;
    border-radius: 3px;
    background: rgba(123, 90, 29, 0.12);
    font-size: 12px;
    line-height: 1;
}
.portal-active-filters-clear {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    min-height: 30px;
    padding: 0 12px;
    border: 1px solid rgba(231, 76, 60, 0.22);
    border-radius: 4px;
    background: #fff2f0;
    color: #d84a3a;
    font-size: 13px;
    font-weight: 600;
    transition: all 0.18s;
}
.portal-active-filters-clear:hover {
    color: #fff;
    background: #e74c3c;
    border-color: #e74c3c;
}
.portal-post-list {
    border: 1px solid #7f7f7f;
    border-radius: 0;
    overflow: hidden;
    background: #fff;
}
.portal-post-list-head {
    display: grid;
    grid-template-columns: var(--portal-grid-template, minmax(0, 1fr) 90px);
    gap: 0;
    padding: 0;
    background: #ededed;
    color: #222;
    font-size: 15px;
    font-weight: 700;
    line-height: 1.2;
    text-align: center;
    align-items: center;
    border-bottom: 1px solid #7f7f7f;
}
.portal-post-list-head > div {
    padding: 12px 10px;
    border-left: 1px solid #7f7f7f;
}
.portal-post-list-head > div:first-child {
    border-left: none;
}
.portal-post-row {
    display: grid;
    grid-template-columns: var(--portal-grid-template, minmax(0, 1fr) 90px);
    gap: 0;
    align-items: stretch;
    padding: 0;
    border-top: 1px solid #a6a6a6;
    background: #fff;
}
.portal-post-row:first-child {
    border-top: none;
}
.portal-post-row:hover {
    background: #fbfbfb;
}
.portal-post-row > div {
    min-height: 34px;
    padding: 3px 10px;
    border-left: 1px solid #d0d0d0;
}
.portal-post-row > div:first-child {
    border-left: none;
}
.portal-post-title-cell {
    display: flex;
    align-items: center;
    min-width: 0;
}
.portal-post-title-wrap {
    display: flex;
    align-items: center;
    width: 100%;
    min-width: 0;
    overflow: hidden;
}
.portal-post-title-box {
    display: flex;
    align-items: center;
    min-width: 0;
    width: 100%;
    min-height: 100%;
    overflow: hidden;
}
.portal-post-title-leading {
    display: flex;
    align-items: center;
    gap: 6px;
    flex: 0 0 auto;
    min-width: 0;
    min-height: 24px;
    align-self: center;
    margin-right: 8px;
}
.portal-post-title-main {
    display: flex;
    flex-direction: column;
    justify-content: center;
    gap: 0;
    min-width: 0;
    width: 100%;
    overflow: hidden;
}
.portal-post-title {
    margin: 0;
    display: flex;
    align-items: center;
    gap: 6px;
    width: 100%;
    min-width: 0;
    min-height: 24px;
    overflow: hidden;
    font-size: 15px;
    line-height: 1.2;
    font-weight: 700;
}
.portal-post-title-link {
    color: var(--portal-post-title-color, inherit);
    display: block;
    flex: 1 1 auto;
    width: 0;
    min-width: 0;
    overflow: hidden;
    text-overflow: ellipsis;
    white-space: nowrap;
    text-align: left;
    line-height: 24px;
}
.portal-post-title-link:hover {
    color: var(--portal-post-title-color, inherit);
}
.portal-post-title-tags {
    display: none;
    align-items: center;
    flex-wrap: wrap;
    gap: 4px;
    min-width: 0;
}
.portal-post-badge {
    display: inline-flex;
    flex: 0 0 auto;
    align-items: center;
    justify-content: center;
    align-self: center;
    height: 18px;
    padding: 0 6px;
    border: 1px solid #6d6d6d;
    border-radius: 3px;
    background: #fff;
    color: #111;
    font-size: 11px;
    font-weight: 700;
    vertical-align: middle;
}
.portal-post-meta {
    display: flex;
    flex-wrap: wrap;
    gap: 8px;
    margin-top: 6px;
    font-size: 12px;
}
.portal-post-meta-item {
    color: var(--text-muted);
}
.portal-post-filter-chip {
    display: inline-flex;
    align-items: center;
    max-width: 100%;
    min-height: 20px;
    padding: 0 6px;
    border: 1px solid #cfcfcf;
    border-radius: 2px;
    background: #f4f4f4;
    color: var(--portal-filter-color, #666);
    font-size: var(--portal-filter-font-size, 12px);
    font-weight: var(--portal-filter-font-weight, 500);
    line-height: 1;
    overflow: hidden;
    text-overflow: ellipsis;
    white-space: nowrap;
    transition: all 0.18s;
}
.portal-post-filter-chip:hover {
    color: #c62828;
    border-color: #d5b58a;
    background: #f8f0db;
}
.portal-post-filter-inline-text {
    display: inline;
    max-width: 100%;
    padding: 0;
    border: none;
    background: transparent;
    color: var(--portal-filter-color, #666);
    font-size: var(--portal-filter-font-size, 13px);
    font-weight: var(--portal-filter-font-weight, 500);
    line-height: 1.35;
    white-space: normal;
}
.portal-post-filter-inline-text:hover {
    color: #c62828;
    background: transparent;
}
.portal-post-filter-chip.portal-post-filter-chip-style-text,
.portal-post-filter-chip.portal-post-filter-chip-style-text_large {
    min-height: 0;
    padding: 0;
    border: none;
    border-radius: 0;
    background: transparent;
    line-height: 1.4;
}
.portal-post-filter-chip.portal-post-filter-chip-style-text {
    color: var(--portal-filter-color, #444);
    font-size: var(--portal-filter-font-size, 13px);
    font-weight: var(--portal-filter-font-weight, 500);
}
.portal-post-filter-chip.portal-post-filter-chip-style-text_large {
    color: var(--portal-filter-color, #444);
    font-size: var(--portal-filter-font-size, 15px);
    font-weight: var(--portal-filter-font-weight, 700);
}
.portal-post-filter-chip.portal-post-filter-chip-style-text:hover,
.portal-post-filter-chip.portal-post-filter-chip-style-text_large:hover {
    color: #c62828;
    background: transparent;
    border-color: transparent;
}
.portal-post-title-prefix {
    flex: 0 0 auto;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    align-self: center;
    max-width: none;
    min-width: 0;
    min-height: 24px;
    padding: 2px 8px;
    border-radius: 4px;
    box-sizing: border-box;
    line-height: 1;
    overflow: visible;
    text-overflow: clip;
}
.portal-post-title-main {
    padding-top: 1px;
    box-sizing: border-box;
}
.portal-post-category {
    display: inline;
    min-height: 0;
    padding: 0;
    border-radius: 0;
    background: transparent;
    color: #0b5eb7;
    font-size: 13px;
    font-weight: 700;
}
.portal-post-date-cell {
    color: #555;
    font-size: 13px;
}
.portal-post-action-cell {
    text-align: center;
    padding: 4px 8px;
}
.portal-post-action {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 100%;
    max-width: 72px;
    height: 24px;
    border: 1px solid #d33429;
    border-radius: 3px;
    background: linear-gradient(180deg, #ff5a47 0%, #ea3b2e 100%);
    color: #fff;
    font-size: 11px;
    font-weight: 700;
    box-sizing: border-box;
}
.portal-post-action:hover {
    color: #fff;
    background: linear-gradient(180deg, #ff6654 0%, #df3224 100%);
    filter: none;
}
body.dark-mode .portal-post-row:hover {
    background: rgba(79, 124, 255, 0.08);
}
body.dark-mode .portal-filter-item {
    color: #d0d4d9;
}
body.dark-mode .portal-filter-item:hover {
    color: #fff;
    background: transparent;
}
body.dark-mode .portal-filter-item.is-active {
    color: #8bb8ff;
}
body.dark-mode .portal-filter-item.is-all {
    background: transparent;
    color: #d0d4d9;
}
body.dark-mode .portal-active-filter-chip {
    background: rgba(79, 124, 255, 0.24);
    color: #dbe7ff;
}
body.dark-mode .portal-active-filter-chip:hover {
    color: #fff;
    background: rgba(79, 124, 255, 0.32);
}
body.dark-mode .portal-active-filter-remove {
    background: rgba(255, 255, 255, 0.12);
}
body.dark-mode .portal-post-filter-chip {
    border-color: rgba(139, 184, 255, 0.28);
    background: rgba(79, 124, 255, 0.08);
    color: var(--portal-filter-color, #cfe0ff);
}
body.dark-mode .portal-post-filter-chip.portal-post-filter-chip-style-text,
body.dark-mode .portal-post-filter-chip.portal-post-filter-chip-style-text_large {
    background: transparent;
    border-color: transparent;
    color: #dbe7ff;
}
body.dark-mode .portal-active-filters-clear {
    background: rgba(231, 76, 60, 0.16);
    border-color: rgba(231, 76, 60, 0.3);
    color: #ffb3ab;
}
body.dark-mode .portal-active-filters-clear:hover {
    color: #fff;
    background: #e74c3c;
    border-color: #e74c3c;
}

@media (max-width: 1200px) {
}

@media (max-width: 992px) {
    .portal-filter-panel {
        top: 74px;
    }
    .portal-post-list-head,
    .portal-post-row {
        grid-template-columns: var(--portal-grid-template, minmax(0, 1fr) 96px);
    }
}

@media (max-width: 768px) {
    .portal-filter-panel {
        position: static;
        top: auto;
    }
    .portal-home-board {
        padding: 16px;
    }
    .portal-home-board-header {
        flex-direction: column;
        align-items: flex-start;
    }
    .portal-filter-row {
        grid-template-columns: 68px 68px minmax(0, 1fr);
        gap: 4px;
    }
    .portal-filter-board {
        padding-left: 0;
    }
    .portal-filter-label {
        justify-content: flex-end;
        min-height: 24px;
        overflow: visible;
        text-overflow: clip;
        font-size: 13px;
    }
    .portal-active-filters {
        gap: 6px;
    }
    .portal-filter-items {
        gap: 5px;
    }
    .portal-filter-item,
    .portal-active-filter-chip {
        min-height: 22px;
        width: 54px;
        padding: 0 3px;
        font-size: 12px;
        overflow: hidden;
        text-overflow: ellipsis;
    }
    .portal-filter-row > .portal-filter-item.is-all {
        width: 100%;
        box-sizing: border-box;
    }
    .portal-active-filters-label {
        font-size: 11px;
    }
    .portal-post-filter-chip {
        min-height: 20px;
        padding: 0 6px;
        font-size: 11px;
    }
    .portal-active-filters-clear {
        min-height: 24px;
        padding: 0 10px;
        font-size: 12px;
    }
    .portal-post-list-head {
        display: none;
    }
    .portal-post-row {
        grid-template-columns: minmax(0, 1fr) auto;
        gap: 0;
        align-items: center;
    }
    .portal-post-row > div {
        min-height: 0;
        padding: 3px 8px;
        border-left: none;
    }
    .portal-post-title-cell {
        grid-column: 1;
        grid-row: 1;
        padding-top: 6px;
        padding-bottom: 4px;
    }
    .portal-post-title-box {
        min-height: 0;
        align-items: flex-start;
    }
    .portal-post-title-leading {
        margin-right: 4px;
    }
    .portal-post-title-main {
        display: flex;
        gap: 4px;
        align-items: flex-start;
    }
    .portal-post-title-tags {
        display: flex;
        width: 100%;
        justify-content: flex-start;
        align-self: flex-start;
        padding-right: 4px;
        padding-left: 0;
        margin-left: 0;
    }
    .portal-post-filter-inline-text {
        display: inline-block;
        font-size: 12px !important;
        line-height: 1.35;
        margin-right: 6px;
    }
    .portal-post-row > .portal-post-filter-cell {
        display: none !important;
        grid-column: 1 / -1;
        min-height: 0;
        padding-top: 2px;
        padding-bottom: 2px;
    }
    .portal-post-row > .portal-post-filter-cell:empty {
        display: none !important;
    }
    .portal-post-action-cell {
        grid-column: 2;
        grid-row: 1;
        min-height: 0;
        padding-top: 6px;
        padding-bottom: 4px;
        padding-left: 0;
        justify-content: flex-end;
    }
    .portal-post-head-filter,
    .portal-post-filter-cell,
    .portal-post-action-cell {
        text-align: left;
        justify-content: flex-start;
    }
    .portal-post-action-cell {
        justify-content: flex-end;
    }
    .portal-post-action {
        width: auto;
        min-width: 64px;
        max-width: none;
        height: 22px;
        padding: 0 8px;
        font-size: 12px;
    }
}

.portal-post-head-filter {
    text-align: center;
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 4px;
}
.portal-post-filter-cell {
    text-align: center;
    display: flex;
    align-items: center;
    justify-content: center;
    flex-wrap: nowrap;
    gap: 4px;
    min-width: 0;
    overflow: hidden;
    white-space: nowrap;
}


/* Header gaps */
.global-ad-box { margin-top: 20px; margin-bottom: -10px; }
.site-notice-container { margin-top: 20px; margin-bottom: -10px; }

/* Header user menu */
.user-action-menu { position: relative; margin-left: 15px; display: inline-block; }
.user-info-trigger { display: flex; align-items: center; cursor: pointer; padding: 4px; border-radius: 999px; transition: background 0.2s; }
.user-info-trigger:hover { background: var(--hover-bg); }
.user-avatar { width: 32px; height: 32px; border-radius: 50%; overflow: hidden; background: var(--bg-input); border: 1px solid var(--border-divider); display: flex; align-items: center; justify-content: center; }
.user-avatar img { width: 100%; height: 100%; object-fit: cover; display: block; }
.user-avatar-guest i { font-size: 16px; color: var(--text-muted); }

.user-avatar-letter {
    width: 32px;
    height: 32px;
    border-radius: 50%;
    overflow: hidden;
    background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
    border: 2px solid rgba(255, 255, 255, 0.3);
    display: flex;
    align-items: center;
    justify-content: center;
    font-weight: 600;
    color: white;
    font-size: 14px;
    box-shadow: 0 2px 8px rgba(102, 126, 234, 0.3);
    transition: all 0.3s ease;
}

.user-avatar-letter:hover {
    transform: scale(1.1);
    box-shadow: 0 4px 12px rgba(102, 126, 234, 0.5);
}

.user-avatar-text {
    font-family: "Microsoft YaHei", sans-serif;
    line-height: 1;
    text-transform: uppercase;
}

.dropdown-avatar {
    width: 48px;
    height: 48px;
    font-size: 20px;
    box-shadow: 0 3px 10px rgba(102, 126, 234, 0.4);
}

body.dark-mode .user-avatar-letter {
    background: linear-gradient(135deg, #f093fb 0%, #f5576c 100%);
    border-color: rgba(255, 255, 255, 0.4);
}

body.dark-mode .user-avatar-letter:hover {
    box-shadow: 0 4px 12px rgba(245, 87, 108, 0.5);
}

body.dark-mode .dropdown-avatar {
    box-shadow: 0 3px 10px rgba(245, 87, 108, 0.4);
}
.user-action-menu .user-dropdown-content { display: none; position: absolute; right: 0; top: 100%; background: var(--bg-card); min-width: 180px; box-shadow: 0 5px 15px rgba(0,0,0,0.1); z-index: 1000; border-radius: 6px; padding: 5px 0; border: 1px solid var(--border-divider); margin-top: 10px; }
.user-action-menu .user-dropdown-content::after { content: ''; position: absolute; top: -15px; left: 0; width: 100%; height: 15px; background: transparent; }
.user-action-menu:hover .user-dropdown-content { display: block; }
.user-dropdown-content::before { content: ''; position: absolute; top: -6px; right: 12px; width: 12px; height: 12px; background: var(--bg-card); border-left: 1px solid var(--border-divider); border-top: 1px solid var(--border-divider); transform: rotate(45deg); }
.user-dropdown-content a { color: var(--text-main); padding: 10px 16px; text-decoration: none; display: block; font-size: 14px; transition: background 0.2s; }
.user-dropdown-content a:hover { background: var(--bg-body); color: var(--color-primary); }
.user-dropdown-header { padding: 15px 16px; border-bottom: 1px solid var(--border-divider); margin-bottom: 5px; display: flex; align-items: center; gap: 10px; }
.user-dropdown-header img { width: 36px; height: 36px; border-radius: 50%; }
.auth-buttons { display: flex; flex-direction: row; justify-content: center; padding: 10px 12px; gap: 10px; }
.auth-buttons a { display: inline-block !important; flex: 1; padding: 8px 12px; border-radius: 6px; text-align: center; font-size: 14px; font-weight: 500; text-decoration: none; transition: all 0.2s ease; box-sizing: border-box; white-space: nowrap; }
.auth-buttons .btn-outline-secondary {
    background: transparent;
    color: var(--text-main);
    border: 1px solid var(--border-color);
}
.auth-buttons .btn-outline-secondary:hover {
    background: var(--hover-bg);
    border-color: var(--primary-color);
    color: var(--primary-color);
}
.auth-buttons .btn-primary {
    background: var(--primary-color);
    color: #fff;
    border: 1px solid var(--primary-color);
}
.auth-buttons .btn-primary:hover {
    filter: brightness(0.9);
    box-shadow: 0 2px 8px rgba(0,123,255,0.3);
}
.guest-actions { display: flex; gap: 10px; align-items: center; }
.guest-actions a { text-decoration: none; font-size: 14px; padding: 6px 15px; border-radius: 20px; transition: all 0.3s; line-height: 1.5; }
.btn-login { color: var(--text-main); background: transparent; }
.btn-login:hover { color: var(--primary-color); }
.btn-register { background: var(--primary-color); color: #fff; }
.btn-register:hover { opacity: 0.9; }

/* Guest avatar placeholder */
.guest-avatar-box {
    width: 36px;
    height: 36px;
    border-radius: 50%;
    background: #f0f0f0;
    display: flex;
    align-items: center;
    justify-content: center;
    color: #999;
}
.guest-avatar-icon { font-size: 20px; }

/* User name text and auth links */
.user-name-text { font-weight: bold; font-size: 14px; }
.link-register { color: var(--color-primary); text-decoration: none; font-size: 14px; margin-right: 10px; }
.link-forgot, .link-back-login { color: #999; text-decoration: none; font-size: 14px; }

/* Login modal title */
.pan-modal-title { margin-top: 0; margin-bottom: 20px; text-align: center; font-size: 20px; }

/* Login/Forgot layout utilities */
.pan-form-flex-between { display: flex; justify-content: space-between; align-items: center; }
.pan-check-label { margin: 0; cursor: pointer; font-size: 14px; }
.pan-form-row { display: flex; gap: 8px; align-items: center; margin-top: 6px; }
.flex-1 { flex: 1; }
.btn-plain { padding: var(--btn-padding-y) var(--btn-padding-x); border: 1px solid var(--border-divider,#ddd); border-radius: var(--btn-radius); background: var(--bg-body,#f9f9f9); cursor: pointer; white-space: nowrap; }
.pan-reset-tip { margin-top: 6px; font-size: 13px; color: #999; }

/* Login modal base */
.pan-modal { display: none; position: fixed; z-index: 10001; left: 0; top: 0; width: 100%; height: 100%; overflow: auto; background-color: rgba(0,0,0,0.5); backdrop-filter: blur(5px); animation: panFadeIn 0.3s; }
.pan-modal-content { background-color: var(--bg-card, #fff); margin: 10% auto; padding: 20px; border: 1px solid var(--border-divider, #eee); width: 90%; max-width: 360px; border-radius: 12px; position: relative; box-shadow: 0 10px 25px rgba(0,0,0,0.2); animation: panSlideIn 0.3s; }
.pan-close { color: #aaa; float: right; font-size: 28px; font-weight: bold; cursor: pointer; line-height: 1; margin-top: -10px; margin-right: -10px; transition: color 0.2s; }
.pan-close:hover { color: var(--text-main, #333); }
.pan-form-group { margin-bottom: 20px; }
.pan-form-group label { display: block; margin-bottom: 8px; color: var(--text-main, #333); font-weight: 500; font-size: 14px; }
.pan-form-group input[type="text"], .pan-form-group input[type="password"], .pan-form-group input[type="email"] { width: 100%; padding: 10px 12px; border: 1px solid var(--border-divider, #ddd); border-radius: 6px; background: var(--bg-body, #f9f9f9); color: var(--text-main, #333); box-sizing: border-box; outline: none; transition: border-color 0.2s; font-size: 14px; }
.pan-form-group input:focus { border-color: var(--color-primary, #007bff); }
.pan-btn-submit { width: 100%; padding: 12px; background: var(--primary-color, #007bff); color: #fff; border: none; border-radius: var(--btn-radius); cursor: pointer; font-size: 16px; font-weight: bold; transition: all 0.2s; display: flex; align-items: center; justify-content: center; line-height: 1.2; }
.pan-btn-submit:hover { opacity: 0.9; }
.pan-login-error { display: none; margin: -8px 0 16px; padding: 9px 12px; border-radius: 6px; background: #fdecea; border: 1px solid #f5c6cb; color: #b02a37; font-size: 13px; line-height: 1.5; }
@keyframes panFadeIn { from { opacity: 0; } to { opacity: 1; } }
@keyframes panSlideIn { from { transform: translateY(-20px); opacity: 0; } to { transform: translateY(0); opacity: 1; } }

/* User Panel Widget */
.widget-user-panel {
    overflow: visible;
}

.widget-user-panel .widget-content {
    padding-top: 0;
}

.user-panel-header {
    display: flex;
    align-items: center;
    gap: 10px;
    padding: 8px 0 12px 0;
    border-bottom: 1px dashed var(--border-divider);
}

.user-panel-avatar {
    flex-shrink: 0;
}

.user-panel-avatar .user-avatar-letter {
    width: 48px;
    height: 48px;
    font-size: 20px;
    display: flex;
    align-items: center;
    justify-content: center;
}

.user-avatar-guest-panel {
    background: linear-gradient(135deg, #6c757d, #495057);
    color: #fff;
    border: 2px solid rgba(255,255,255,0.3);
    box-shadow: 0 2px 8px rgba(108,117,125,0.2);
}

.user-panel-info {
    flex: 1;
    min-width: 0;
}

.user-panel-name {
    font-size: 15px;
    font-weight: 600;
    color: var(--text-main);
    margin-bottom: 3px;
}

.user-panel-role {
    font-size: 12px;
}

.role-admin {
    color: #dc3545;
    font-weight: 600;
}

.role-vip {
    color: #ffc107;
    font-weight: 600;
}

.role-member {
    color: #17a2b8;
    font-weight: 600;
}

.role-guest {
    color: #6c757d;
    font-weight: 600;
}

.user-panel-buttons {
    padding: 12px 0;
    display: flex;
    flex-direction: row;
    gap: 8px;
}

.btn-block {
    display: flex;
    align-items: center;
    justify-content: center;
    flex: 1;
    text-align: center;
    gap: 4px;
    padding: 8px 10px;
    font-size: 13px;
    height: auto;
}

.btn-block:hover {
    color: #fff !important;
}

.btn-primary.btn-block:hover {
    background: #0056b3 !important;
}

.btn-outline-secondary.btn-block:hover {
    background: #6c757d !important;
    color: #fff !important;
}

.btn-vip {
    background: linear-gradient(135deg, #ffc107, #ff9800);
    color: #fff;
    border: none;
    font-weight: 600;
}

.btn-vip:hover {
    filter: brightness(1.05);
    transform: translateY(-1px);
    box-shadow: 0 3px 10px rgba(255,193,7,0.35);
}

.user-panel-stats {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 8px;
    padding: 12px 0;
    border-top: 1px dashed var(--border-divider);
    border-bottom: 1px dashed var(--border-divider);
}

.stat-item {
    text-align: center;
    padding: 10px 6px;
    background: var(--bg-badge);
    border-radius: 6px;
}

.stat-label {
    font-size: 11px;
    color: var(--text-muted);
    margin-bottom: 3px;
}

.stat-value {
    font-size: 16px;
    font-weight: 700;
    color: var(--primary-color);
}

.user-panel-footer {
    padding-top: 12px;
}

.user-panel-logout {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 5px;
    padding: 8px 14px;
    color: #6c757d;
    font-size: 13px;
    text-decoration: none;
    border-radius: 6px;
    transition: all 0.2s;
}

.user-panel-logout:hover {
    background: rgba(108,117,125,0.1);
    color: #dc3545;
}

.user-panel-tips {
    padding: 10px;
    background: var(--bg-badge);
    border-radius: 6px;
    margin-top: 8px;
}

.user-panel-tips p {
    margin: 0;
    font-size: 12px;
    color: var(--text-secondary);
    display: flex;
    align-items: center;
    gap: 5px;
}

.user-panel-tips i {
    color: var(--primary-color);
    font-size: 14px;
}

/* Dark mode for user panel */
body.dark-mode .user-panel-avatar .user-avatar-letter {
    border-color: rgba(255,255,255,0.2);
}

body.dark-mode .user-avatar-guest-panel {
    background: linear-gradient(135deg, #6c757d, #495057);
    box-shadow: 0 4px 12px rgba(0,0,0,0.3);
}

body.dark-mode .stat-item {
    background: var(--bg-input);
}

body.dark-mode .user-panel-tips {
    background: var(--bg-input);
}

/* ===== 预告片封套：点击后才加载视频，页面源码里不出现媒体地址（避免浏览器资源嗅探） ===== */
.pan-video {
    position: relative;
    width: 100%;
    max-width: 600px;
    aspect-ratio: 16 / 9;
    margin: 18px 0;
    border-radius: 10px;
    overflow: hidden;
    cursor: pointer;
    background: #10131a center/cover no-repeat;
    display: flex;
    align-items: center;
    justify-content: center;
    -webkit-tap-highlight-color: transparent;
    box-shadow: 0 2px 12px rgba(0, 0, 0, .12);
}

.pan-video::after {
    content: '';
    position: absolute;
    inset: 0;
    background: radial-gradient(circle at 50% 50%, rgba(0, 0, 0, .18), rgba(0, 0, 0, .45));
    pointer-events: none;
}

.pan-video .pan-video-tip {
    position: relative;
    z-index: 1;
    display: inline-flex;
    align-items: center;
    gap: 9px;
    color: #fff;
    font-size: 15px;
    line-height: 1;
    padding: 11px 20px;
    border-radius: 30px;
    background: rgba(0, 0, 0, .45);
    -webkit-backdrop-filter: blur(4px);
    backdrop-filter: blur(4px);
}

.pan-video .pan-video-tip::before {
    content: '';
    width: 0;
    height: 0;
    border-style: solid;
    border-width: 7px 0 7px 12px;
    border-color: transparent transparent transparent #fff;
}

.pan-video.is-playing {
    aspect-ratio: auto;
    max-width: 100%;
    background: #000;
    cursor: default;
}

.pan-video.is-playing::after {
    display: none;
}

.pan-video .pan-video-media {
    display: block;
    width: 100%;
    height: auto;
    max-height: 70vh;
    background: #000;
    border-radius: 10px;
}
