/* ===== Block 1 ===== */
    html { margin: 0; padding: 0; height: 100%; overflow: hidden; background: #000000; }
    body { margin: 0; padding: 0; height: 100%; overflow: hidden; background: transparent; }
    /* 纯黑色背景 */
    .bg-layer {
        position: fixed;
        top: 0;
        left: 0;
        width: 100%;
        height: 100%;
        z-index: -2;
        background: #000000;
    }
    .bg-layer::after {
        content: '';
        position: absolute;
        top: 0;
        left: 0;
        width: 100%;
        height: 100%;
        background: transparent;
    }
    /* ========== 标题栏基础样式已移至 titlebar-shared.css ========== */
    /* [v56.2] 项目标签页已移除 */
    .project-tabs-container {
        display: none;
        scroll-behavior: smooth;
    }
    .project-tabs-container::-webkit-scrollbar { height: 4px; display: block; }
    .project-tabs-container::-webkit-scrollbar-track { background: rgba(255,255,255,0.05); border-radius: 2px; }
    .project-tabs-container::-webkit-scrollbar-thumb { background: rgba(255,133,162,0.4); border-radius: 2px; }
    .project-tabs-container::-webkit-scrollbar-thumb:hover { background: rgba(255,133,162,0.6); }
    .project-tab { display: none; }
    .project-tab:hover { display: none; }
    .project-tab.active { display: none; }
    .tab-close { display: none; }
    .project-tab:hover .tab-close { display: none; }
    .tab-close:hover { display: none; }
    .project-add-dropdown { display: none; }
    .project-add-btn { display: none; }
    .project-add-btn:hover { display: none; }
    /* [v56.2] 以下旧标签样式全部隐藏 */
    .tab-name, .tab-badge, .tab-badge.badge-running, .tab-badge.badge-pending, .tab-badge.badge-failed { display: none; }
    .home-tab-actions-menu, .home-tab-actions-menu.show, .home-tab-actions-menu > div { display: none; }


    /* ========== 统一会员面板样式 ========== */
    .mp-overlay {
        position: fixed; top: 0; left: 0; right: 0; bottom: 0;
        background: rgba(0,0,0,0.6); backdrop-filter: blur(4px); -webkit-backdrop-filter: blur(4px);
        z-index: 99997; display: none; opacity: 0; transition: opacity 0.25s ease;
    }
    .mp-overlay.show { opacity: 1; }
    .mp-panel {
        position: fixed; left: 50%; top: 50%;
        transform: translate(-50%, -50%) scale(0.96);
        width: 980px; max-width: 95vw; max-height: 90vh;
        background: linear-gradient(145deg, rgba(10,10,10,0.97) 0%, rgba(0,0,0,0.92) 100%);
        backdrop-filter: blur(24px) saturate(1.3); -webkit-backdrop-filter: blur(24px) saturate(1.3);
        border: 1px solid rgba(255,133,162,0.18);
        border-radius: 16px;
        box-shadow: 0 24px 80px rgba(0,0,0,0.6), 0 0 40px rgba(255,133,162,0.06);
        z-index: 99998; display: none; opacity: 0;
        transition: opacity 0.25s ease, transform 0.25s ease;
        overflow-y: auto; color: #ddd;
    }
    .mp-panel.show { opacity: 1; transform: translate(-50%, -50%) scale(1); }
    .mp-panel::-webkit-scrollbar { width: 6px; }
    .mp-panel::-webkit-scrollbar-track { background: transparent; }
    .mp-panel::-webkit-scrollbar-thumb { background: rgba(255,255,255,0.12); border-radius: 3px; }
    .mp-close { display: none; }
    .mp-close:hover { }

    /* Header */
    .mp-header {
        display: flex; align-items: center; justify-content: space-between;
        padding: 24px 32px 16px;
        border-bottom: 1px solid rgba(255,255,255,0.06);
        background: linear-gradient(90deg, rgba(255,133,162,0.04), transparent);
    }
    .mp-user-info { display: flex; align-items: center; gap: 12px; }
    .mp-avatar { width: 40px; height: 40px; border-radius: 50%; background: linear-gradient(135deg, #FF85A2, #D4A574); display: flex; align-items: center; justify-content: center; color: #fff; font-size: 16px; font-weight: 600; }
    .mp-user-name { font-size: 15px; font-weight: 600; color: #eee; }
    .mp-user-tier { font-size: 12px; color: #888; margin-top: 2px; }
    .mp-user-tier .tier-badge { display: inline-block; padding: 1px 8px; border-radius: 10px; font-size: 11px; font-weight: 500; background: rgba(255,255,255,0.06); color: #999; border: 1px solid rgba(255,255,255,0.08); }
    .mp-user-tier .tier-badge.vip { background: linear-gradient(135deg, #FF85A2, #D4A574); color: #fff; border: none; }
    .mp-header-right { display: flex; align-items: center; gap: 16px; }
    .mp-points-display { text-align: right; }
    .mp-points-label { font-size: 12px; color: #888; }
    .mp-points-value { font-size: 20px; font-weight: 700; color: #FF85A2; }
    .mp-daily-info { font-size: 12px; color: #34D399; white-space: nowrap; padding: 4px 0; }

    /* Tabs */
    .mp-tabs { display: flex; gap: 0; padding: 0 32px; border-bottom: 1px solid rgba(255,255,255,0.06); align-items: center; }
    .mp-tab { padding: 14px 24px; font-size: 14px; font-weight: 500; color: #888; cursor: pointer; border-bottom: 2px solid transparent; transition: all 0.2s; user-select: none; }
    .mp-tab:hover { color: #ccc; }
    .mp-tab.active { color: #FF85A2; border-bottom-color: #FF85A2; font-weight: 600; }
    .mp-tab-content { display: none; padding: 24px 32px 32px; }
    .mp-tab-content.active { display: block; }
    .mp-invite-btn {
        background: linear-gradient(135deg, #8b5cf6, #ec4899); color: #fff; border: none;
        border-radius: 16px; padding: 6px 16px; font-size: 12px; cursor: pointer;
        font-weight: 600; transition: opacity 0.2s; white-space: nowrap; margin-right: 8px;
    }
    .mp-invite-btn:hover { opacity: 0.85; box-shadow: 0 2px 12px rgba(139,92,246,0.3); }

    /* Rules */
    .mp-rules-section { margin-bottom: 24px; }
    .mp-rules-section-title {
        font-size: 14px; font-weight: 600; color: #e2e8f0; margin-bottom: 12px;
        display: flex; align-items: center; gap: 8px;
    }
    .mp-rules-section-title::before {
        content: ''; display: inline-block; width: 3px; height: 14px;
        background: linear-gradient(180deg, #FF85A2, #D4A574); border-radius: 2px;
    }
    .mp-rules-cards {
        display: grid; grid-template-columns: repeat(auto-fill, minmax(180px, 1fr));
        gap: 10px; margin-bottom: 8px;
    }
    .mp-rules-card {
        background: rgba(255,255,255,0.03); border: 1px solid rgba(255,255,255,0.06);
        border-radius: 10px; padding: 14px; display: flex; flex-direction: column; gap: 4px;
    }
    .mp-rules-card-label { font-size: 11px; color: #888; }
    .mp-rules-card-value { font-size: 16px; font-weight: 600; color: #FF85A2; }
    .mp-rules-card-note { font-size: 11px; color: #666; }
    .mp-rules-table {
        width: 100%; border-collapse: collapse; font-size: 12px;
    }
    .mp-rules-table th {
        text-align: left; padding: 8px 10px; color: #888; font-weight: 500;
        border-bottom: 1px solid rgba(255,255,255,0.06); font-size: 11px;
    }
    .mp-rules-table td {
        padding: 7px 10px; color: #ccc; border-bottom: 1px solid rgba(255,255,255,0.03);
    }
    .mp-rules-table tr:hover td { background: rgba(255,255,255,0.02); }
    .mp-rules-discount { color: #34D399; font-weight: 500; }

    /* Rules sub-tabs */
    .mp-rules-subtabs { display: flex; gap: 8px; margin-bottom: 14px; flex-wrap: wrap; }
    .mp-rules-subtab {
        padding: 5px 14px; border-radius: 8px; border: 1px solid rgba(255,255,255,0.1);
        background: transparent; color: #aaa; font-size: 12px; cursor: pointer; transition: all 0.2s;
    }
    .mp-rules-subtab:hover { border-color: rgba(255,133,162,0.3); color: #ddd; }
    .mp-rules-subtab.active { border-color: #FF85A2; color: #FF85A2; background: rgba(255,133,162,0.08); }
    .mp-rules-table--multi { table-layout: fixed; }
    .mp-rules-table--multi th.col-price,
    .mp-rules-table--multi td.col-price { text-align: center; }
    .mp-rules-table--multi td.col-model { font-weight: 500; color: #ddd; }

    /* Transactions */
    .mp-tx-toolbar { display: flex; align-items: center; gap: 12px; margin-bottom: 16px; }
    .mp-tx-filter {
        padding: 6px 12px; font-size: 13px; color: #ccc; border: 1px solid rgba(255,255,255,0.10);
        border-radius: 8px; background: rgba(255,255,255,0.05); outline: none; cursor: pointer;
    }
    .mp-tx-filter:focus { border-color: rgba(255,133,162,0.4); }
    .mp-tx-filter option { background: #111111; color: #ccc; }
    .mp-tx-table { width: 100%; border-collapse: collapse; font-size: 13px; }
    .mp-tx-table th {
        text-align: left; padding: 10px 12px; font-size: 12px; font-weight: 500; color: #888;
        background: rgba(255,255,255,0.03); border-bottom: 1px solid rgba(255,255,255,0.06);
    }
    .mp-tx-table td { padding: 10px 12px; border-bottom: 1px solid rgba(255,255,255,0.04); color: #bbb; }
    .mp-tx-table tr:hover td { background: rgba(255,255,255,0.02); }
    .mp-tx-type {
        display: inline-block; padding: 2px 8px; border-radius: 10px; font-size: 11px; font-weight: 500;
        background: rgba(255,255,255,0.06); color: #999; white-space: nowrap;
    }
    .mp-tx-type.income { background: rgba(52,211,153,0.10); color: #34D399; }
    .mp-tx-type.expense { background: rgba(255,133,162,0.10); color: #FF85A2; }
    .mp-tx-points { font-weight: 600; font-variant-numeric: tabular-nums; }
    .mp-tx-points.income { color: #34D399; }
    .mp-tx-points.expense { color: #FF85A2; }
    .mp-tx-detail { max-width: 220px; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; font-size: 12px; color: #888; }
    .mp-tx-pagination {
        display: flex; align-items: center; justify-content: space-between;
        margin-top: 16px; padding-top: 12px; border-top: 1px solid rgba(255,255,255,0.04);
    }
    .mp-tx-page-info { font-size: 12px; color: #888; }
    .mp-tx-page-btn {
        padding: 5px 14px; font-size: 12px; color: #ccc; border: 1px solid rgba(255,255,255,0.10);
        border-radius: 6px; background: rgba(255,255,255,0.04); cursor: pointer; margin-left: 8px;
        transition: all 0.15s;
    }
    .mp-tx-page-btn:hover:not(:disabled) { border-color: rgba(255,133,162,0.4); background: rgba(255,133,162,0.06); color: #FF85A2; }
    .mp-tx-page-btn:disabled { opacity: 0.35; cursor: not-allowed; }
    .mp-tx-empty { text-align: center; padding: 48px 20px; color: #666; font-size: 14px; }

    /* Tier Grid */
    .mp-tier-grid { display: grid; grid-template-columns: 160px repeat(4, 1fr); gap: 16px; margin-bottom: 24px; }
    .mp-tier-spacer { width: 160px; }
    .mp-tier-card {
        border: 1.5px solid rgba(255,255,255,0.08); border-radius: 14px;
        padding: 24px 16px; text-align: center; cursor: pointer;
        transition: all 0.25s; position: relative;
        background: rgba(255,255,255,0.03);
    }
    .mp-tier-card:hover { border-color: rgba(255,133,162,0.35); background: rgba(255,133,162,0.04); transform: translateY(-2px); box-shadow: 0 8px 24px rgba(0,0,0,0.2); }
    .mp-tier-card.selected { border-color: #FF85A2; background: rgba(255,133,162,0.08); box-shadow: 0 0 0 1px #FF85A2, 0 4px 20px rgba(255,133,162,0.12); }
    .mp-tier-card.current { border-color: rgba(16,185,129,0.4); background: rgba(16,185,129,0.06); }
    .mp-tier-tag { position: absolute; top: -10px; left: 50%; transform: translateX(-50%); font-size: 11px; padding: 2px 10px; border-radius: 10px; white-space: nowrap; font-weight: 600; }
    .mp-tier-tag.hot { background: linear-gradient(135deg, #ef4444, #dc2626); color: #fff; }
    .mp-tier-tag.rec { background: linear-gradient(135deg, #FF85A2, #D4A574); color: #0a0a0a; }
    .mp-tier-name { font-size: 15px; font-weight: 600; color: #eee; margin-bottom: 12px; }
    .mp-tier-price { font-size: 32px; font-weight: 700; color: #FF85A2; line-height: 1; }
    .mp-tier-price .sym { font-size: 16px; font-weight: 500; vertical-align: top; margin-right: 2px; }
    .mp-tier-price .per { font-size: 13px; font-weight: 400; color: #888; margin-left: 2px; }
    .mp-tier-desc { font-size: 12px; color: #888; margin-top: 8px; margin-bottom: 16px; min-height: 18px; }
    .mp-tier-btn {
        width: 100%; padding: 10px; border-radius: 8px;
        border: 1px solid rgba(255,133,162,0.3); background: rgba(255,133,162,0.08);
        color: #FF85A2; font-size: 13px; font-weight: 500; cursor: pointer; transition: all 0.2s;
    }
    .mp-tier-btn:hover { background: rgba(255,133,162,0.15); border-color: #FF85A2; }
    .mp-tier-card.selected .mp-tier-btn { background: linear-gradient(135deg, #FF85A2, #D4A574); color: #0a0a0a; border-color: transparent; font-weight: 600; }
    .mp-tier-card.current .mp-tier-btn { background: rgba(16,185,129,0.15); color: #34D399; border-color: rgba(16,185,129,0.3); cursor: default; }
    .mp-tier-card.free-card .mp-tier-btn { background: rgba(255,255,255,0.04); color: #666; border-color: rgba(255,255,255,0.08); cursor: default; }
    .mp-tier-card.lower-tier { opacity: 0.45; pointer-events: none; filter: grayscale(0.5); }
    .mp-tier-card.lower-tier .mp-tier-btn { background: rgba(255,255,255,0.04); color: #666; border-color: rgba(255,255,255,0.08); cursor: not-allowed; }

    /* New Tier Selector (tabs) */
    .mp-tier-selector { display: flex; gap: 12px; margin-bottom: 20px; }
    .mp-tier-tab {
        flex: 1; border: 1.5px solid rgba(255,255,255,0.08); border-radius: 12px;
        padding: 16px 12px; text-align: center; cursor: pointer;
        transition: all 0.25s; position: relative; background: rgba(255,255,255,0.03);
    }
    .mp-tier-tab:hover { border-color: rgba(255,133,162,0.35); background: rgba(255,133,162,0.04); }
    .mp-tier-tab.active { border-color: #FF85A2; background: rgba(255,133,162,0.08); box-shadow: 0 0 0 1px #FF85A2, 0 4px 16px rgba(255,133,162,0.1); }
    .mp-tier-tab.disabled { opacity: 0.4; pointer-events: none; filter: grayscale(0.5); }
    .mp-tier-tab-name { font-size: 15px; font-weight: 600; color: #eee; margin-bottom: 6px; }
    .mp-tier-tab-tag { font-size: 10px; padding: 1px 6px; border-radius: 6px; margin-left: 4px; vertical-align: middle; }
    .mp-tier-tab-tag.hot { background: linear-gradient(135deg, #ef4444, #dc2626); color: #fff; }
    .mp-tier-tab-tag.rec { background: linear-gradient(135deg, #FF85A2, #D4A574); color: #0a0a0a; }
    .mp-tier-tab-price { font-size: 20px; font-weight: 700; color: #FF85A2; margin-bottom: 4px; }
    .mp-tier-tab.active .mp-tier-tab-price { color: #FF85A2; }
    .mp-tier-tab-pts { font-size: 12px; color: #888; }
    .mp-tier-tab-lock { font-size: 11px; color: #ef4444; margin-top: 4px; }

    /* Days Slider */
    .mp-days-section { margin-bottom: 20px; padding: 0 4px; }
    .mp-days-header { display: flex; justify-content: space-between; align-items: center; margin-bottom: 10px; }
    .mp-days-title { font-size: 14px; color: #aaa; font-weight: 500; }
    .mp-days-label { font-size: 22px; font-weight: 700; color: #FF85A2; }
    .mp-days-range {
        -webkit-appearance: none; appearance: none; width: 100%; height: 6px;
        background: linear-gradient(90deg, rgba(255,133,162,0.25), rgba(212,165,116,0.25));
        border-radius: 3px; outline: none;
    }
    .mp-days-range::-webkit-slider-thumb {
        -webkit-appearance: none; appearance: none; width: 22px; height: 22px;
        background: linear-gradient(135deg, #FF85A2, #D4A574); border-radius: 50%;
        cursor: pointer; box-shadow: 0 2px 8px rgba(255,133,162,0.35);
    }
    .mp-days-range::-moz-range-thumb {
        width: 22px; height: 22px; background: linear-gradient(135deg, #FF85A2, #D4A574);
        border-radius: 50%; cursor: pointer; border: none;
    }
    .mp-days-marks { display: flex; justify-content: space-between; font-size: 11px; color: #555; margin-top: 6px; }

    /* Price Summary */
    .mp-price-summary { text-align: center; padding: 16px; margin-bottom: 16px; border-radius: 12px; background: rgba(255,133,162,0.04); border: 1px solid rgba(255,133,162,0.1); }
    .mp-price-main { margin-bottom: 6px; }
    .mp-price-sym { font-size: 18px; color: #FF85A2; font-weight: 400; vertical-align: top; }
    .mp-price-total { font-size: 38px; font-weight: 700; color: #FF85A2; line-height: 1; }
    .mp-price-info { display: flex; justify-content: center; gap: 12px; align-items: center; margin-bottom: 4px; }
    .mp-price-daily { font-size: 13px; color: #aaa; }
    .mp-price-discount { font-size: 12px; color: #10b981; background: rgba(16,185,129,0.1); padding: 2px 8px; border-radius: 10px; }
    .mp-price-bonus { font-size: 13px; color: #D4A574; font-weight: 500; }
    .mp-upgrade-info { background: #fff8e6; border: 1px solid #ffe4a0; border-radius: 8px; padding: 10px 14px; margin: 8px 0; font-size: 13px; color: #8a6d00; line-height: 1.6; }
    .mp-upgrade-info b { font-weight: 600; color: #6d5200; }

    /* Feature Table */
    .mp-features { border-top: 1px solid rgba(255,255,255,0.06); margin-bottom: 12px; }
    .mp-feature-row { display: grid; grid-template-columns: 140px repeat(4, 1fr); gap: 8px; align-items: center; border-bottom: 1px solid rgba(255,255,255,0.04); min-height: 38px; }
    .mp-feature-row.mp-feature-header { border-bottom: 1px solid rgba(255,255,255,0.08); }
    .mp-feature-row.mp-feature-header .mp-feature-val { font-weight: 600; color: #aaa; font-size: 12px; }
    .mp-feature-label { font-size: 13px; color: #888; padding: 8px 0; }
    .mp-feature-val { text-align: center; font-size: 13px; color: #ccc; padding: 8px 0; border-radius: 4px; transition: background 0.2s; }
    .mp-feature-val.mp-feature-hl { background: rgba(255,133,162,0.06); color: #eee; }
    .mp-feature-val .check { color: #10b981; font-weight: bold; }
    .mp-feature-val .cross { color: #444; }

    /* Points Slider */
    .mp-points-slider-wrap { padding: 8px 0 20px; }
    .mp-points-display { text-align: center; margin-bottom: 24px; }
    .mp-points-display .mp-pts-yuan { font-size: 36px; font-weight: 700; color: #FF85A2; }
    .mp-points-display .mp-pts-yuan .sym { font-size: 20px; font-weight: 400; vertical-align: top; margin-right: 2px; }
    .mp-points-display .mp-pts-eq { font-size: 14px; color: #888; margin-top: 6px; }
    .mp-points-display .mp-pts-eq .pts-num { color: #eee; font-weight: 600; font-size: 16px; }
    .mp-slider-row { padding: 0 4px; }
    .mp-slider-range {
        -webkit-appearance: none; appearance: none; width: 100%; height: 6px;
        border-radius: 3px; background: rgba(255,255,255,0.08); outline: none;
        cursor: pointer;
    }
    .mp-slider-range::-webkit-slider-thumb {
        -webkit-appearance: none; appearance: none; width: 24px; height: 24px;
        border-radius: 50%; background: linear-gradient(135deg, #FF85A2, #D4A574);
        box-shadow: 0 2px 8px rgba(255,133,162,0.4); cursor: pointer; border: 2px solid #fff;
        margin-top: -9px;
    }
    .mp-slider-range::-moz-range-thumb {
        width: 24px; height: 24px; border-radius: 50%;
        background: linear-gradient(135deg, #FF85A2, #D4A574);
        box-shadow: 0 2px 8px rgba(255,133,162,0.4); cursor: pointer; border: 2px solid #fff;
    }
    .mp-slider-range::-webkit-slider-runnable-track { height: 6px; border-radius: 3px; }
    .mp-slider-range::-moz-range-track { height: 6px; border-radius: 3px; background: rgba(255,255,255,0.08); }
    .mp-slider-labels { display: flex; justify-content: space-between; margin-top: 8px; font-size: 12px; color: #666; }
    .mp-slider-presets { display: flex; gap: 8px; margin-top: 16px; flex-wrap: wrap; justify-content: center; }
    .mp-slider-presets .mp-preset-btn {
        padding: 6px 16px; border-radius: 8px; border: 1px solid rgba(255,255,255,0.1);
        background: rgba(255,255,255,0.03); color: #aaa; font-size: 13px; cursor: pointer;
        transition: all 0.2s;
    }
    .mp-slider-presets .mp-preset-btn:hover { border-color: rgba(255,133,162,0.4); color: #eee; background: rgba(255,133,162,0.06); }
    .mp-slider-presets .mp-preset-btn.active { border-color: #FF85A2; color: #FF85A2; background: rgba(255,133,162,0.1); }

    /* Pay Section */
    .mp-pay-section { text-align: center; padding-top: 20px; border-top: 1px solid rgba(255,255,255,0.06); margin-top: 8px; }
    .mp-pay-btn {
        display: inline-block; padding: 12px 48px; border-radius: 10px; border: none;
        background: linear-gradient(135deg, #FF85A2, #D4A574);
        color: #0a0a0a; font-size: 15px; font-weight: 600; cursor: pointer; transition: all 0.2s;
    }
    .mp-pay-btn:hover { filter: brightness(1.1); transform: translateY(-1px); box-shadow: 0 4px 16px rgba(255,133,162,0.3); }
    .mp-pay-btn:disabled { background: rgba(255,255,255,0.08); color: #666; cursor: not-allowed; filter: none; transform: none; box-shadow: none; }
    .mp-qr-section { display: none; margin-top: 16px; }
    .mp-qr-section.show { display: block; }
    .mp-qr-wrap { display: inline-block; padding: 12px; background: #fff; border-radius: 10px; }
    .mp-qr-info { margin-top: 10px; font-size: 14px; color: #ccc; }
    .mp-qr-tip { margin-top: 6px; font-size: 12px; color: #888; }
    .mp-qr-status { margin-top: 10px; font-size: 13px; color: #10B981; }
    .mp-qr-status .spin { display: inline-block; width: 14px; height: 14px; border: 2px solid rgba(255,133,162,0.3); border-top-color: #FF85A2; border-radius: 50%; animation: mp-spin 0.8s linear infinite; margin-right: 6px; vertical-align: middle; }
    @keyframes mp-spin { to { transform: rotate(360deg); } }
    .mp-qr-cancel { background: none; border: 1px solid rgba(255,255,255,0.15); color: #aaa; padding: 6px 20px; border-radius: 8px; cursor: pointer; font-size: 13px; margin-top: 8px; transition: all 0.2s; }
    .mp-qr-cancel:hover { border-color: #ef4444; color: #ef4444; }
    .mp-success { display: none; text-align: center; padding: 24px; }
    .mp-success.show { display: block; }
    .mp-success-icon { font-size: 48px; color: #10b981; }
    .mp-success-text { font-size: 18px; font-weight: 600; color: #eee; margin: 8px 0; }
    .mp-success-detail { font-size: 14px; color: #888; }

    @media (max-width: 900px) {
        .mp-tier-grid { grid-template-columns: repeat(2, 1fr); }
        .mp-tier-spacer { display: none; }
        .mp-feature-row { grid-template-columns: 120px repeat(4, 1fr); gap: 8px; }
        .mp-header { flex-direction: column; align-items: flex-start; gap: 12px; }
        .mp-rules-table--multi { display: block; overflow-x: auto; }
    }
    @media (max-width: 600px) {
        .mp-tab-content { padding: 16px; }
        .mp-tier-grid { grid-template-columns: 1fr 1fr; }
        .mp-tier-spacer { display: none; }
        .mp-feature-row { font-size: 12px; grid-template-columns: 100px repeat(4, 1fr); gap: 4px; }
        .mp-rules-table--multi { font-size: 11px; }
        .mp-rules-table--multi td, .mp-rules-table--multi th { padding: 5px 6px; }
        .mp-rules-subtabs { gap: 6px; }
    }



    /* ========== 用户面板弹窗（会员信息/积分管理） ========== */
    .user-panel-overlay {
        position: fixed; top: 0; left: 0; right: 0; bottom: 0;
        background: rgba(0,0,0,0.55); backdrop-filter: blur(4px);
        z-index: 5010; display: none; opacity: 0;
        transition: opacity 0.25s;
        align-items: center; justify-content: center;
    }
    .user-panel-overlay.show { display: flex; opacity: 1; }
    .user-panel {
        width: 560px; max-width: 92vw; max-height: 80vh;
        background: linear-gradient(145deg, rgba(10,10,10,0.95) 0%, rgba(0,0,0,0.70) 100%); backdrop-filter: blur(20px); -webkit-backdrop-filter: blur(20px);
        border: 1px solid rgba(255,133,162,0.20);
        border-radius: 14px;
        box-shadow: 0 20px 60px rgba(0,0,0,0.7), 0 0 30px rgba(255,133,162,0.08);
        display: flex; flex-direction: column; overflow: hidden;
        transform: translateY(16px); transition: transform 0.3s;
    }
    .user-panel-overlay.show .user-panel { transform: translateY(0); }
    .user-panel-header {
        display: flex; align-items: center; justify-content: space-between;
        padding: 16px 20px; border-bottom: 1px solid rgba(255,133,162,0.12);
        background: linear-gradient(90deg, rgba(255,133,162,0.06), transparent);
    }
    .user-panel-title {
        font-size: 16px; font-weight: 600; color: #fff;
        display: flex; align-items: center; gap: 8px;
    }
    .user-panel-title svg { width: 20px; height: 20px; color: #FF85A2; }
    .user-panel-close {
        width: 30px; height: 30px; border: none; background: rgba(255,255,255,0.06);
        border-radius: 8px; color: #888; cursor: pointer; display: flex;
        align-items: center; justify-content: center; transition: all 0.15s;
    }
    .user-panel-close:hover { background: rgba(255,255,255,0.12); color: #fff; }
    .user-panel-body { flex: 1; overflow-y: auto; padding: 20px; }
    .user-panel-body::-webkit-scrollbar { width: 5px; }
    .user-panel-body::-webkit-scrollbar-thumb { background: rgba(255,133,162,0.3); border-radius: 3px; }

    /* -- 积分管理面板样式 -- */
    .card-current-info {
        padding: 20px; border-radius: 12px; margin-bottom: 20px;
        background: linear-gradient(135deg, rgba(255,133,162,0.10), rgba(255,133,162,0.03));
        border: 1px solid rgba(255,133,162,0.15);
    }
    .card-current-info .card-info-row {
        display: flex; align-items: center; justify-content: space-between; margin-bottom: 10px;
    }
    .card-current-info .card-info-row:last-child { margin-bottom: 0; }
    .card-current-info .card-info-label { font-size: 12px; color: #888; }
    .card-current-info .card-info-value { font-size: 13px; color: #e0e0e0; font-weight: 500; }
    .card-current-info .card-info-value.highlight { color: #FF85A2; font-size: 20px; font-weight: 700; }
    .card-status-tag {
        display: inline-block; padding: 2px 10px; border-radius: 10px;
        font-size: 11px; font-weight: 600;
    }
    .card-status-tag.active { background: rgba(16,185,129,0.12); color: #10b981; }
    .card-status-tag.warning { background: rgba(245,158,11,0.12); color: #f59e0b; }
    .card-status-tag.expired { background: rgba(239,68,68,0.12); color: #ef4444; }
    .card-status-tag.inactive { background: rgba(102,102,102,0.12); color: #888; }

    /* -- 会员信息样式 -- */
    .member-card {
        padding: 24px; border-radius: 12px; margin-bottom: 20px;
        background: linear-gradient(135deg, rgba(255,133,162,0.10), rgba(255,133,162,0.03));
        border: 1px solid rgba(255,133,162,0.18);
    }
    .member-card .member-level { font-size: 20px; font-weight: 700; color: #FF85A2; display: flex; align-items: center; gap: 8px; }
    .member-card .member-expire { font-size: 13px; color: #999; margin-top: 8px; }
    .member-card .member-expire .warn { color: #ef4444; }
    .member-features { display: flex; flex-direction: column; gap: 10px; }
    .member-feature-item {
        display: flex; align-items: center; gap: 10px; padding: 10px 14px;
        border-radius: 8px; background: rgba(255,255,255,0.02);
    }
    .member-feature-item svg { width: 18px; height: 18px; color: #FF85A2; flex-shrink: 0; }
    .member-feature-item .feat-name { font-size: 13px; color: #ccc; }
    .member-feature-item .feat-status { margin-left: auto; font-size: 12px; color: #10b981; }
    .member-device-info { margin-top: 16px; padding: 14px; border-radius: 8px; background: rgba(255,255,255,0.02); border: 1px solid rgba(255,255,255,0.06); }
    .member-device-info .label { font-size: 11px; color: #666; margin-bottom: 4px; }
    .member-device-info .val { font-size: 13px; color: #aaa; word-break: break-all; }

    /* ========== iframe 项目容器 ========== */
    .project-iframe-container {
        position: fixed;
        top: 0;
        left: 56px;
        right: 0;
        bottom: 0;
        z-index: 9995;
        display: none;
    }
    .project-iframe-container.active {
        display: block;
    }
    .project-iframe {
        width: 100%;
        height: 100%;
        border: none;
    }

    /* ========== 首页主侧边栏样式（窄栏 图标+标签） ========== */
    .home-sidebar {
        position: fixed;
        top: 0;
        left: 0;
        bottom: 0;
        width: 56px;
        background: linear-gradient(180deg, rgba(10,10,10,0.50) 0%, rgba(0,0,0,0.55) 100%);
        backdrop-filter: blur(24px);
        -webkit-backdrop-filter: blur(24px);
        border-right: 1px solid rgba(255, 133, 162, 0.12);
        display: flex;
        flex-direction: column;
        z-index: 9990;
    }

    .home-sidebar-nav {
        padding: 16px 0;
        display: flex;
        flex-direction: column;
        align-items: center;
        gap: 4px;
        flex: 1;
    }

    .sidebar-nav-main {
        display: flex;
        flex-direction: column;
        align-items: center;
        gap: 4px;
    }

    .sidebar-nav-bottom {
        margin-top: auto;
        display: flex;
        flex-direction: column;
        align-items: center;
        gap: 4px;
        padding-bottom: 8px;
    }

    /* 侧边栏 - 积分+等级 */
    .sidebar-user-info {
        display: flex;
        flex-direction: column;
        align-items: center;
        gap: 2px;
        padding: 6px 4px;
        cursor: pointer;
        border-radius: 10px;
        transition: background 0.2s;
        width: 48px;
    }
    .sidebar-user-info:hover {
        background: rgba(255, 133, 162, 0.10);
    }
    .sidebar-user-info .sidebar-points {
        font-size: 14px;
        font-weight: 700;
        color: #10B981;
        line-height: 1.2;
    }
    .sidebar-user-info .sidebar-level {
        font-size: 10px;
        font-weight: 500;
        color: #FF85A2;
        line-height: 1.2;
    }
    .sidebar-user-info.low .sidebar-points { color: #f59e0b; }
    .sidebar-user-info.empty .sidebar-points { color: #ef4444; }
    .sidebar-user-info.permanent .sidebar-level { color: #34D399; }
    .sidebar-user-info.warning .sidebar-level { color: #f59e0b; }
    .sidebar-user-info.inactive .sidebar-level { color: #888; }

    /* 侧边栏 - 头像 */
    .sidebar-avatar-wrap {
        display: flex;
        flex-direction: column;
        align-items: center;
        gap: 2px;
        padding: 4px;
        cursor: pointer;
        border-radius: 10px;
        transition: background 0.2s;
        position: relative;
        width: 48px;
    }
    .sidebar-avatar-wrap:hover {
        background: rgba(255, 133, 162, 0.10);
    }
    .sidebar-avatar-btn {
        width: 32px;
        height: 32px;
        border-radius: 50%;
        background: linear-gradient(135deg, #FF85A2, #D4A574);
        display: flex;
        align-items: center;
        justify-content: center;
        color: #fff;
        overflow: hidden;
        flex-shrink: 0;
    }
    .sidebar-avatar-btn svg {
        width: 18px;
        height: 18px;
    }
    .sidebar-avatar-img {
        width: 100%;
        height: 100%;
        border-radius: 50%;
        object-fit: cover;
        display: block;
    }
    .sidebar-login-text {
        font-size: 10px;
        color: #FF85A2;
        font-weight: 600;
        white-space: nowrap;
        cursor: pointer;
        line-height: 1.2;
    }

    .home-nav-item {
        display: flex;
        flex-direction: column;
        align-items: center;
        justify-content: center;
        gap: 3px;
        width: 48px;
        padding: 8px 2px;
        border-radius: 10px;
        cursor: pointer;
        color: #9ca3af;
        font-size: 11px;
        transition: all 0.2s;
        border: 1px solid transparent;
        background: transparent;
        text-align: center;
    }

    .home-nav-item:hover {
        background: rgba(255, 133, 162, 0.10);
        color: #e5e5e5;
    }

    .home-nav-item.active {
        background: rgba(255, 133, 162, 0.12);
        border-color: rgba(255, 133, 162, 0.3);
        color: #FF85A2;
    }

    .home-nav-item .nav-icon-img {
        width: 20px;
        height: 20px;
        opacity: 0.55;
        filter: grayscale(100%) brightness(1.5);
        transition: all 0.2s;
    }
    .home-nav-item:hover .nav-icon-img {
        opacity: 0.85;
        filter: grayscale(0%) brightness(1);
    }
    .home-nav-item.active .nav-icon-img {
        opacity: 1;
        filter: grayscale(0%) brightness(1);
    }

    .home-nav-item .nav-label {
        font-size: 11px;
        line-height: 1.2;
        white-space: nowrap;
    }

    .home-nav-item .nav-text {
        display: none;
    }

    /* 首页内容区（避开悬浮侧边栏） */
    .home-main-wrapper {
        margin-left: 0;
        width: 100vw;
        padding-left: 80px;
        box-sizing: border-box;
    }

    /* 角色库页面 */
    .home-page {
        display: none;
        padding: 20px;
        height: 100vh;
        overflow-y: auto;
        overflow-x: hidden;
    }
    /* 滚动条：平时隐藏，滚动/hover 时显示 */
    .home-page::-webkit-scrollbar {
        width: 6px;
    }
    .home-page::-webkit-scrollbar-track {
        background: transparent;
    }
    .home-page::-webkit-scrollbar-thumb {
        background: transparent;
        border-radius: 3px;
        transition: background 0.3s;
    }
    .home-page:hover::-webkit-scrollbar-thumb {
        background: rgba(255,133,162,0.25);
    }
    .home-page:hover::-webkit-scrollbar-thumb:hover {
        background: rgba(255,133,162,0.5);
    }
    /* 页面一滚动条 — 继承 .home-page 的透明规则 */
    #pageCreation::-webkit-scrollbar {
        width: 6px;
    }
    #pageCreation::-webkit-scrollbar-track {
        background: transparent;
        border-radius: 3px;
    }
    #pageCreation::-webkit-scrollbar-thumb {
        background: transparent;
        border-radius: 3px;
        border: 2px solid #0a0a0a;
    }
    #pageCreation::-webkit-scrollbar-thumb:hover {
        background: #FF85A2;
    }
    .home-page.active {
        display: block;
    }
    /* Landing 首页特殊布局 */
    #pageHome.home-page { padding: 0; }
    #pageHome.home-page.active { display: flex; flex-direction: column; align-items: stretch; }

    /* ========== Landing 首页样式 ========== */
    .landing-container {
        width: 100% !important;
        max-width: none !important;
        margin: 0 !important;
        padding: 40px 16px 16px !important;
        box-sizing: border-box !important;
    }
    .landing-hero {
        width: fit-content;
        margin: 0 auto 20px;
        text-align: center;
    }
    .landing-hero-title {
        font-size: 52px;
        font-weight: 700;
        background: linear-gradient(135deg, #FF85A2, #FFB0C4, #F7C5B8);
        -webkit-background-clip: text;
        -webkit-text-fill-color: transparent;
        background-clip: text;
        margin-bottom: 6px;
        letter-spacing: 3px;
    }
    .landing-hero-sub {
        width: fit-content;
        margin-left: auto;
        transform: translateX(100%);
        font-size: 20px;
        color: rgba(255, 255, 255, 0.85);
        letter-spacing: 2px;
    }
    .landing-cards {
        display: grid !important;
        grid-template-columns: repeat(4, 1fr) !important;
        gap: 16px !important;
        margin-bottom: 16px;
        width: 100% !important;
        box-sizing: border-box !important;
    }
    .landing-card {
        position: relative;
        border-radius: 16px;
        cursor: pointer;
        transition: all 0.35s cubic-bezier(0.4, 0, 0.2, 1);
        overflow: hidden;
        aspect-ratio: 16 / 9;
        background-size: cover;
        background-position: center;
        background-repeat: no-repeat;
        border: 1px solid rgba(255, 133, 162, 0.2);
    }
    .landing-card::before {
        content: '';
        position: absolute;
        inset: 0;
        background: linear-gradient(to top, rgba(0,0,0,0.85) 0%, rgba(0,0,0,0.35) 45%, rgba(0,0,0,0.05) 100%);
        transition: background 0.35s;
        z-index: 1;
    }
    .landing-card:hover {
        transform: translateY(-6px) scale(1.02);
        border-color: rgba(255, 133, 162, 0.6);
        box-shadow: 0 16px 48px rgba(255, 133, 162, 0.2), 0 0 0 1px rgba(255, 133, 162, 0.15);
    }
    .landing-card:hover::before {
        background: linear-gradient(to top, rgba(0,0,0,0.9) 0%, rgba(0,0,0,0.25) 50%, rgba(0,0,0,0) 100%);
    }
    .landing-card-content {
        position: absolute;
        bottom: 0;
        left: 0;
        right: 0;
        padding: 20px 22px;
        z-index: 2;
    }
    .landing-card-title {
        font-size: 18px;
        font-weight: 700;
        color: #fff;
        margin-bottom: 6px;
        text-shadow: 0 2px 8px rgba(0,0,0,0.5);
    }
    .landing-card-desc {
        font-size: 12px;
        color: rgba(255,255,255,0.7);
        line-height: 1.6;
        text-shadow: 0 1px 4px rgba(0,0,0,0.5);
    }
    /* 画廊区域 */
    .landing-gallery-section {
        padding: 0 16px 60px;
    }
    .landing-gallery-header {
        display: flex;
        flex-direction: column;
        gap: 14px;
        margin-bottom: 20px;
        padding: 0 4px;
    }
    .landing-gallery-header-left {
        display: flex;
        align-items: center;
        gap: 12px;
    }
    .landing-gallery-title {
        font-size: 18px;
        font-weight: 600;
        color: #eee;
        display: flex;
        align-items: center;
        gap: 8px;
    }
    .landing-gallery-title::before {
        content: '';
        display: inline-block;
        width: 3px;
        height: 18px;
        background: linear-gradient(180deg, #FF85A2, #D4A574);
        border-radius: 2px;
    }
    /* 投稿按钮 */
    .gallery-submit-btn {
        display: flex;
        align-items: center;
        gap: 5px;
        padding: 5px 14px;
        border: 1px solid rgba(255, 133, 162, 0.35);
        background: rgba(255, 133, 162, 0.08);
        color: #FF85A2;
        border-radius: 16px;
        font-size: 12px;
        font-weight: 500;
        cursor: pointer;
        transition: all 0.2s;
        white-space: nowrap;
    }
    .gallery-submit-btn:hover {
        background: rgba(255, 133, 162, 0.18);
        border-color: rgba(255, 133, 162, 0.5);
        box-shadow: 0 2px 12px rgba(255, 133, 162, 0.15);
    }
    /* 画廊分类标签 */
    .landing-gallery-tabs {
        display: flex;
        gap: 6px;
    }
    .gallery-tab {
        padding: 6px 18px;
        border: 1px solid rgba(255,255,255,0.08);
        background: rgba(255,255,255,0.03);
        color: #888;
        border-radius: 20px;
        font-size: 13px;
        cursor: pointer;
        transition: all 0.2s;
    }
    .gallery-tab:hover {
        color: #ccc;
        background: rgba(255,255,255,0.06);
        border-color: rgba(255,255,255,0.12);
    }
    .gallery-tab.active {
        color: #fff;
        background: rgba(255, 133, 162, 0.15);
        border-color: rgba(255, 133, 162, 0.4);
    }
    .landing-gallery-grid {
        column-count: 6;
        column-gap: 10px;
    }
    /* 视频筛选时切换为标准 Grid 布局（横屏内容一行 5 个） */
    .landing-gallery-grid.grid-mode {
        column-count: unset;
        display: grid;
        grid-template-columns: repeat(5, 1fr);
        gap: 10px;
    }
    .landing-gallery-item {
        position: relative;
        border-radius: 10px;
        overflow: hidden;
        cursor: pointer;
        background: rgba(255,255,255,0.03);
        border: 1px solid rgba(255,255,255,0.06);
        transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
        margin-bottom: 10px;
        break-inside: avoid;
    }
    .grid-mode .landing-gallery-item {
        margin-bottom: 0;
    }
    .landing-gallery-item:hover {
        transform: scale(1.03);
        border-color: rgba(255, 133, 162, 0.4);
        box-shadow: 0 8px 30px rgba(0,0,0,0.4), 0 0 20px rgba(255, 133, 162, 0.1);
        z-index: 10;
    }
    .landing-gallery-item img,
    .landing-gallery-item video {
        width: 100%;
        height: auto;
        display: block;
        transition: transform 0.4s ease;
    }
    .landing-gallery-item:hover img,
    .landing-gallery-item:hover video {
        transform: scale(1.08);
    }
    .landing-gallery-item .gallery-overlay {
        position: absolute;
        bottom: 0;
        left: 0;
        right: 0;
        padding: 24px 10px 8px;
        background: linear-gradient(transparent, rgba(0,0,0,0.75));
        opacity: 0;
        transition: opacity 0.3s;
    }
    .landing-gallery-item:hover .gallery-overlay {
        opacity: 1;
    }
    .gallery-overlay-title {
        font-size: 12px;
        color: #fff;
        font-weight: 500;
    }
    .gallery-overlay-model {
        font-size: 10px;
        color: rgba(255,255,255,0.5);
    }
    /* ========== 画廊详情弹窗 ========== */
    .gallery-detail-overlay {
        position: fixed;
        top: 0;
        left: 0;
        right: 0;
        bottom: 0;
        background: rgba(0, 0, 0, 0.85);
        backdrop-filter: blur(8px);
        -webkit-backdrop-filter: blur(8px);
        z-index: 100000;
        display: none;
        align-items: center;
        justify-content: center;
        opacity: 0;
        transition: opacity 0.3s;
    }
    .gallery-detail-overlay.show {
        display: flex;
        opacity: 1;
    }
    .gallery-detail-panel {
        display: flex;
        width: 900px;
        max-width: 92vw;
        max-height: 85vh;
        background: linear-gradient(145deg, rgba(10,10,10,0.97) 0%, rgba(0,0,0,0.95) 100%);
        backdrop-filter: blur(24px);
        -webkit-backdrop-filter: blur(24px);
        border: 1px solid rgba(255, 133, 162, 0.18);
        border-radius: 16px;
        overflow: hidden;
        box-shadow: 0 24px 80px rgba(0,0,0,0.6), 0 0 40px rgba(255, 133, 162, 0.08);
        transform: scale(0.95);
        transition: transform 0.3s;
    }
    .gallery-detail-overlay.show .gallery-detail-panel {
        transform: scale(1);
    }
    .gallery-detail-left {
        flex: 1;
        min-width: 0;
        display: flex;
        align-items: center;
        justify-content: center;
        background: rgba(0,0,0,0.3);
        padding: 16px;
        overflow: hidden;
    }
    .gallery-detail-left img,
    .gallery-detail-left video {
        max-width: 100%;
        max-height: calc(85vh - 32px);
        border-radius: 8px;
        object-fit: contain;
    }
    .gallery-detail-right {
        width: 320px;
        flex-shrink: 0;
        display: flex;
        flex-direction: column;
        border-left: 1px solid rgba(255,255,255,0.06);
        overflow-y: auto;
    }
    .gallery-detail-right::-webkit-scrollbar { width: 4px; }
    .gallery-detail-right::-webkit-scrollbar-thumb { background: rgba(255,133,162,0.2); border-radius: 2px; }
    .gallery-detail-header {
        display: flex;
        align-items: center;
        justify-content: space-between;
        padding: 16px 20px;
        border-bottom: 1px solid rgba(255,255,255,0.06);
        flex-shrink: 0;
    }
    .gallery-detail-title {
        font-size: 15px;
        font-weight: 600;
        color: #FF85A2;
    }
    .gallery-detail-close {
        width: 28px;
        height: 28px;
        border: none;
        background: rgba(255,255,255,0.06);
        border-radius: 8px;
        color: #888;
        cursor: pointer;
        display: flex;
        align-items: center;
        justify-content: center;
        transition: all 0.15s;
        font-size: 16px;
    }
    .gallery-detail-close:hover {
        background: rgba(255,255,255,0.12);
        color: #fff;
    }
    .gallery-detail-body {
        flex: 1;
        padding: 16px 20px;
        display: flex;
        flex-direction: column;
        gap: 16px;
    }
    .gallery-detail-section {
        display: flex;
        flex-direction: column;
        gap: 6px;
    }
    .gallery-detail-label {
        font-size: 11px;
        color: #777;
        font-weight: 500;
        text-transform: uppercase;
        letter-spacing: 0.5px;
    }
    .gallery-detail-value {
        font-size: 13px;
        color: #ddd;
        line-height: 1.6;
        word-break: break-word;
    }
    .gallery-detail-value.prompt-text {
        background: rgba(255,255,255,0.03);
        border: 1px solid rgba(255,255,255,0.06);
        border-radius: 8px;
        padding: 10px 12px;
        font-size: 12px;
        color: #bbb;
        max-height: 180px;
        overflow-y: auto;
    }
    .gallery-detail-value.prompt-text::-webkit-scrollbar { width: 3px; }
    .gallery-detail-value.prompt-text::-webkit-scrollbar-thumb { background: rgba(255,133,162,0.2); border-radius: 2px; }
    .gallery-detail-tags {
        display: flex;
        flex-wrap: wrap;
        gap: 6px;
    }
    .gallery-tag {
        display: inline-block;
        padding: 3px 10px;
        border-radius: 12px;
        font-size: 11px;
        font-weight: 500;
        background: rgba(255,133,162,0.10);
        color: #FF85A2;
        border: 1px solid rgba(255,133,162,0.15);
    }
    .gallery-detail-params {
        display: grid;
        grid-template-columns: 1fr 1fr;
        gap: 10px;
    }
    .gallery-detail-param {
        background: rgba(255,255,255,0.03);
        border-radius: 8px;
        padding: 10px 12px;
    }
    .gallery-detail-param-label {
        font-size: 10px;
        color: #666;
        margin-bottom: 4px;
    }
    .gallery-detail-param-value {
        font-size: 13px;
        color: #ddd;
        font-weight: 500;
    }

    /* ========== 投稿弹窗 ========== */
    .gallery-submit-overlay {
        position: fixed;
        top: 0; left: 0; right: 0; bottom: 0;
        background: rgba(0, 0, 0, 0.85);
        backdrop-filter: blur(8px);
        -webkit-backdrop-filter: blur(8px);
        z-index: 100000;
        display: none;
        align-items: center;
        justify-content: center;
        opacity: 0;
        transition: opacity 0.3s;
    }
    .gallery-submit-overlay.show {
        display: flex;
        opacity: 1;
    }
    .gallery-submit-panel {
        width: 480px;
        max-width: 92vw;
        max-height: 85vh;
        background: linear-gradient(145deg, rgba(10,10,10,0.97) 0%, rgba(0,0,0,0.95) 100%);
        backdrop-filter: blur(24px);
        -webkit-backdrop-filter: blur(24px);
        border: 1px solid rgba(255, 133, 162, 0.18);
        border-radius: 16px;
        overflow: hidden;
        box-shadow: 0 24px 80px rgba(0,0,0,0.6), 0 0 40px rgba(255, 133, 162, 0.08);
        transform: scale(0.95);
        transition: transform 0.3s;
        display: flex;
        flex-direction: column;
    }
    .gallery-submit-overlay.show .gallery-submit-panel {
        transform: scale(1);
    }
    .gallery-submit-header {
        display: flex;
        align-items: center;
        justify-content: space-between;
        padding: 16px 20px;
        border-bottom: 1px solid rgba(255,255,255,0.06);
        flex-shrink: 0;
    }
    .gallery-submit-title {
        font-size: 15px;
        font-weight: 600;
        color: #FF85A2;
    }
    .gallery-submit-body {
        flex: 1;
        padding: 20px;
        display: flex;
        flex-direction: column;
        gap: 16px;
        overflow-y: auto;
    }
    .gallery-submit-body::-webkit-scrollbar { width: 4px; }
    .gallery-submit-body::-webkit-scrollbar-thumb { background: rgba(255,133,162,0.2); border-radius: 2px; }
    .gallery-submit-field {
        display: flex;
        flex-direction: column;
        gap: 6px;
    }
    .gallery-submit-label {
        font-size: 12px;
        color: #999;
        font-weight: 500;
    }
    .gallery-submit-type-btns {
        display: flex;
        gap: 10px;
    }
    .gallery-type-btn {
        flex: 1;
        display: flex;
        align-items: center;
        justify-content: center;
        gap: 8px;
        padding: 12px;
        border: 1px solid rgba(255,255,255,0.08);
        background: rgba(255,255,255,0.03);
        color: #888;
        border-radius: 10px;
        font-size: 13px;
        cursor: pointer;
        transition: all 0.2s;
    }
    .gallery-type-btn:hover {
        border-color: rgba(255,255,255,0.15);
        color: #ccc;
        background: rgba(255,255,255,0.06);
    }
    .gallery-type-btn.active {
        border-color: rgba(255, 133, 162, 0.5);
        color: #FF85A2;
        background: rgba(255, 133, 162, 0.08);
    }
    .gallery-submit-input {
        width: 100%;
        padding: 10px 12px;
        border: 1px solid rgba(255,255,255,0.08);
        background: rgba(255,255,255,0.03);
        color: #ddd;
        border-radius: 8px;
        font-size: 13px;
        outline: none;
        transition: border-color 0.2s;
        box-sizing: border-box;
    }
    .gallery-submit-input:focus {
        border-color: rgba(255, 133, 162, 0.4);
    }
    .gallery-submit-textarea {
        width: 100%;
        padding: 10px 12px;
        border: 1px solid rgba(255,255,255,0.08);
        background: rgba(255,255,255,0.03);
        color: #ddd;
        border-radius: 8px;
        font-size: 13px;
        outline: none;
        resize: vertical;
        min-height: 60px;
        transition: border-color 0.2s;
        box-sizing: border-box;
        font-family: inherit;
    }
    .gallery-submit-textarea:focus {
        border-color: rgba(255, 133, 162, 0.4);
    }
    .gallery-submit-upload {
        display: flex;
        flex-direction: column;
        align-items: center;
        justify-content: center;
        gap: 8px;
        padding: 24px;
        border: 2px dashed rgba(255,255,255,0.1);
        border-radius: 10px;
        color: #666;
        cursor: pointer;
        transition: all 0.2s;
    }
    .gallery-submit-upload:hover {
        border-color: rgba(255, 133, 162, 0.3);
        color: #999;
        background: rgba(255, 133, 162, 0.03);
    }
    .gallery-submit-upload.has-file {
        border-color: rgba(255, 133, 162, 0.4);
        color: #FF85A2;
        background: rgba(255, 133, 162, 0.05);
    }
    .gallery-submit-upload span {
        font-size: 12px;
    }
    .gallery-submit-confirm {
        width: 100%;
        padding: 12px;
        border: none;
        background: linear-gradient(135deg, #FF85A2, #D4A574);
        color: #fff;
        border-radius: 10px;
        font-size: 14px;
        font-weight: 600;
        cursor: pointer;
        transition: all 0.2s;
        margin-top: 4px;
    }
    .gallery-submit-confirm:hover {
        opacity: 0.9;
        box-shadow: 0 4px 20px rgba(255, 133, 162, 0.3);
    }

    /* 画廊项视频标识 */
    .gallery-video-badge {
        position: absolute;
        top: 8px;
        right: 8px;
        width: 28px;
        height: 28px;
        background: rgba(0,0,0,0.55);
        backdrop-filter: blur(4px);
        border-radius: 50%;
        display: flex;
        align-items: center;
        justify-content: center;
        z-index: 5;
    }
    .gallery-video-badge svg {
        width: 14px;
        height: 14px;
        color: #fff;
    }

    /* ========== 资产库标签样式 ========== */
    .assets-tabs {
        display: flex;
        gap: 4px;
        padding: 16px 20px 0;
        border-bottom: 1px solid rgba(255,255,255,0.08);
    }
    .assets-tab {
        display: flex;
        align-items: center;
        gap: 6px;
        padding: 10px 18px;
        border: none;
        background: transparent;
        color: #888;
        font-size: 14px;
        cursor: pointer;
        border-bottom: 2px solid transparent;
        transition: all 0.2s;
        border-radius: 8px 8px 0 0;
    }
    .assets-tab:hover {
        color: #ccc;
        background: rgba(255,255,255,0.04);
    }
    .assets-tab.active {
        color: #FF85A2;
        border-bottom-color: #FF85A2;
        background: rgba(255,133,162,0.08);
        font-weight: 600;
    }
    .assets-tab-content {
        padding: 20px;
        flex: 1;
        overflow-y: auto;
    }
    #pageAssets.home-page { padding: 0; }
    #pageAssets.home-page.active { display: flex; flex-direction: column; }



    /* ========== AI创作工作台 (Studio) ========== */
    #pageStudio.home-page { padding: 0; display: none; }
    #pageStudio.home-page.active { display: flex; flex-direction: column; }

    .studio-container {
        display: flex; flex-direction: row; height: 100%; position: relative;
        background: rgba(0,0,0,0.78);
    }
    .studio-main {
        display: flex; flex-direction: column; flex: 1; min-width: 0; position: relative;
    }

    /* ===== 工作台顶部工具栏 ===== */
    .studio-topbar {
        display: flex; align-items: center; justify-content: flex-end;
        padding: 10px 16px 0; gap: 8px; flex-shrink: 0;
        position: absolute; top: 0; right: 0; z-index: 50;
    }
    .studio-topbar-btn {
        display: flex; align-items: center; gap: 5px;
        padding: 6px 14px; border-radius: 8px;
        border: 1px solid rgba(255,255,255,0.1); background: rgba(255,255,255,0.05);
        color: #aaa; font-size: 12px; cursor: pointer;
        transition: all 0.2s; white-space: nowrap; user-select: none;
    }
    .studio-topbar-btn:hover {
        background: rgba(255,133,162,0.12); color: #FF85A2;
        border-color: rgba(255,133,162,0.3);
    }
    .studio-topbar-btn svg { width: 14px; height: 14px; flex-shrink: 0; }

    /* ===== 历史对话面板（左侧常驻） ===== */
    .studio-history-panel {
        width: 240px; min-width: 240px; flex-shrink: 0;
        background: rgba(0,0,0,0.92);
        border-right: 1px solid rgba(255,255,255,0.06);
        display: flex; flex-direction: column;
        backdrop-filter: blur(20px); -webkit-backdrop-filter: blur(20px);
    }
    .studio-history-panel-header {
        display: flex; align-items: center; justify-content: space-between;
        padding: 12px 12px 8px; flex-shrink: 0;
        border-bottom: 1px solid rgba(255,255,255,0.06);
    }
    .studio-history-panel-header h3 {
        margin: 0; font-size: 13px; color: #ccc; font-weight: 600;
    }
    .studio-history-panel-new {
        display: flex; align-items: center; gap: 4px;
        padding: 4px 10px; border-radius: 6px;
        border: 1px solid rgba(255,133,162,0.3); background: rgba(255,133,162,0.08);
        color: #FF85A2; cursor: pointer; font-size: 12px; transition: all 0.2s;
    }
    .studio-history-panel-new:hover { background: rgba(255,133,162,0.18); }
    .studio-history-panel-new svg { width: 12px; height: 12px; }
    .studio-history-panel-list {
        flex: 1; overflow-y: auto; padding: 6px;
        scrollbar-width: thin; scrollbar-color: rgba(255,133,162,0.2) transparent;
    }
    .studio-history-panel-list::-webkit-scrollbar { width: 4px; }
    .studio-history-panel-list::-webkit-scrollbar-thumb { background: rgba(255,133,162,0.2); border-radius: 2px; }
    .studio-conv-item {
        padding: 8px 10px; border-radius: 6px; cursor: pointer;
        transition: all 0.15s; margin-bottom: 2px;
        border: 1px solid transparent;
    }
    .studio-conv-item:hover {
        background: rgba(255,133,162,0.08); border-color: rgba(255,133,162,0.15);
    }
    .studio-conv-item.active {
        background: rgba(255,133,162,0.12); border-color: rgba(255,133,162,0.3);
    }
    .studio-conv-item .conv-title {
        font-size: 12px; color: #ddd; font-weight: 500;
        overflow: hidden; text-overflow: ellipsis; white-space: nowrap;
        margin-bottom: 2px;
    }
    .studio-conv-item.active .conv-title { color: #FF85A2; }
    .studio-conv-item .conv-meta {
        display: flex; align-items: center; justify-content: space-between;
    }
    .studio-conv-item .conv-time { font-size: 11px; color: #666; }
    .studio-conv-item .conv-count { font-size: 11px; color: #555; }
    .studio-conv-item .conv-delete {
        opacity: 0; background: none; border: none; color: #666; cursor: pointer;
        font-size: 12px; padding: 2px 4px; border-radius: 4px; transition: all 0.15s;
    }
    .studio-conv-item:hover .conv-delete { opacity: 1; }
    .studio-conv-item .conv-delete:hover { color: #ef4444; background: rgba(239,68,68,0.15); }
    .studio-history-panel-empty {
        text-align: center; color: #555; padding: 40px 20px; font-size: 13px;
    }

    /* ===== 生成历史媒体面板（右侧抽屉） ===== */
    .studio-media-panel {
        width: 0; min-width: 0; flex-shrink: 0; overflow: hidden;
        background: rgba(0,0,0,0.95);
        border-left: 1px solid rgba(255,255,255,0.06);
        display: flex; flex-direction: column;
        backdrop-filter: blur(20px); -webkit-backdrop-filter: blur(20px);
        transition: width 0.3s cubic-bezier(0.4, 0, 0.2, 1), min-width 0.3s cubic-bezier(0.4, 0, 0.2, 1);
    }
    .studio-media-panel.open {
        width: 320px; min-width: 320px;
    }
    .studio-media-panel-header {
        display: flex; align-items: center; justify-content: space-between;
        padding: 12px 14px 8px; flex-shrink: 0;
        border-bottom: 1px solid rgba(255,255,255,0.06);
    }
    .studio-media-panel-header h3 {
        margin: 0; font-size: 13px; color: #ccc; font-weight: 600; white-space: nowrap;
    }
    .studio-media-panel-close {
        display: flex; align-items: center; justify-content: center;
        width: 24px; height: 24px; border-radius: 6px;
        border: none; background: rgba(255,255,255,0.05);
        color: #888; cursor: pointer; transition: all 0.2s; flex-shrink: 0;
    }
    .studio-media-panel-close:hover { background: rgba(255,133,162,0.15); color: #FF85A2; }
    .studio-media-panel-close svg { width: 14px; height: 14px; }

    .studio-media-panel-tabs {
        display: flex; gap: 0; padding: 8px 14px 0; flex-shrink: 0;
        border-bottom: 1px solid rgba(255,255,255,0.06);
    }
    .studio-media-tab {
        flex: 1; padding: 7px 0; border: none; background: none;
        color: #777; font-size: 12px; cursor: pointer;
        border-bottom: 2px solid transparent; transition: all 0.2s;
        white-space: nowrap;
    }
    .studio-media-tab:hover { color: #bbb; }
    .studio-media-tab.active {
        color: #FF85A2; border-bottom-color: #FF85A2; font-weight: 600;
    }

    .studio-media-panel-stats {
        padding: 8px 14px; flex-shrink: 0; font-size: 11px; color: #666;
        white-space: nowrap; overflow: hidden;
    }

    .studio-media-panel-grid {
        flex: 1; overflow-y: auto; padding: 6px 10px;
        display: grid; grid-template-columns: repeat(2, 1fr); gap: 8px;
        align-content: start;
        scrollbar-width: thin; scrollbar-color: rgba(255,133,162,0.2) transparent;
    }
    .studio-media-panel-grid::-webkit-scrollbar { width: 4px; }
    .studio-media-panel-grid::-webkit-scrollbar-thumb { background: rgba(255,133,162,0.2); border-radius: 2px; }

    .studio-media-panel-empty {
        grid-column: 1 / -1;
        text-align: center; color: #555; padding: 40px 12px; font-size: 12px;
    }

    .studio-media-card {
        position: relative; border-radius: 8px; overflow: hidden;
        background: rgba(255,255,255,0.03); border: 1px solid rgba(255,255,255,0.06);
        cursor: pointer; transition: all 0.2s; aspect-ratio: 1;
    }
    .studio-media-card:hover {
        border-color: rgba(255,133,162,0.3); transform: translateY(-1px);
        box-shadow: 0 4px 12px rgba(0,0,0,0.3);
    }
    .studio-media-card img, .studio-media-card video {
        width: 100%; height: 100%; object-fit: cover; display: block;
    }
    .studio-media-card .media-type-badge {
        position: absolute; top: 4px; left: 4px;
        padding: 2px 6px; border-radius: 4px; font-size: 10px;
        background: rgba(0,0,0,0.6); color: #ddd; backdrop-filter: blur(4px);
    }
    .studio-media-card .media-type-badge.video { color: #7dd3fc; }
    .studio-media-card .media-type-badge.image { color: #fda4af; }
    .studio-media-card .media-date {
        position: absolute; bottom: 0; left: 0; right: 0;
        padding: 12px 6px 4px; font-size: 10px; color: #aaa;
        background: linear-gradient(transparent, rgba(0,0,0,0.7));
        text-align: right;
    }
    .studio-media-card .media-dl-btn {
        position: absolute; top: 4px; right: 4px; opacity: 0;
        width: 24px; height: 24px; border-radius: 6px;
        border: none; background: rgba(0,0,0,0.6); color: #ddd;
        cursor: pointer; transition: all 0.2s;
        display: flex; align-items: center; justify-content: center;
        backdrop-filter: blur(4px);
    }
    .studio-media-card:hover .media-dl-btn { opacity: 1; }
    .studio-media-card .media-dl-btn:hover { background: rgba(255,133,162,0.5); color: #fff; }
    .studio-media-card .media-dl-btn svg { width: 12px; height: 12px; }

    /* ===== 资产库 - 工作台历史网格 ===== */
    .studio-data-grid-inner {
        display: grid;
        grid-template-columns: repeat(auto-fill, minmax(160px, 1fr));
        gap: 12px;
        padding: 0 16px 16px;
    }
    .studio-data-grid-inner .studio-media-card {
        position: relative; border-radius: 10px; overflow: hidden;
        cursor: pointer; aspect-ratio: 1; background: rgba(60, 30, 5, 0.88);
        border: 1px solid rgba(249, 115, 22, 0.3); transition: transform 0.15s, border-color 0.15s;
    }
    .studio-data-grid-inner .studio-media-card:hover {
        transform: translateY(-2px); border-color: rgba(249, 115, 22, 0.6);
    }
    .studio-data-grid-inner .studio-media-card img,
    .studio-data-grid-inner .studio-media-card video {
        width: 100%; height: 100%; object-fit: cover;
    }

    /* 历史消息区 */
    .studio-history {
        flex: 1; overflow-y: auto; padding: 24px 5%; display: flex; flex-direction: column; gap: 16px;
        scrollbar-width: thin; scrollbar-color: rgba(255,133,162,0.2) transparent;
    }
    .studio-history::-webkit-scrollbar { width: 5px; }
    .studio-history::-webkit-scrollbar-thumb { background: rgba(255,133,162,0.2); border-radius: 3px; }
    .studio-history::-webkit-scrollbar-track { background: transparent; }

    /* 欢迎页 */
    .studio-welcome { display: flex; flex-direction: column; align-items: center; justify-content: center; flex: 1; min-height: 50vh; }
    .studio-welcome-icon { font-size: 48px; margin-bottom: 16px; }
    .studio-welcome-title { font-size: 22px; font-weight: 600; color: #FF85A2; margin-bottom: 8px; }
    .studio-welcome-sub { font-size: 14px; color: #666; }
    /* [成长系统] 成长徽章 */
    .studio-growth-badge { display: none; margin-top: 16px; padding: 12px 20px; border-radius: 12px; background: rgba(255,133,162,0.06); border: 1px solid rgba(255,133,162,0.12); text-align: center; cursor: pointer; transition: background 0.2s; max-width: 320px; }
    .studio-growth-badge:hover { background: rgba(255,133,162,0.12); }
    .studio-growth-badge.loaded { display: block; }
    .studio-growth-level { font-size: 15px; font-weight: 600; color: #FF85A2; margin-bottom: 4px; }
    .studio-growth-bar-wrap { width: 100%; height: 6px; background: rgba(255,255,255,0.08); border-radius: 3px; overflow: hidden; margin: 6px 0; }
    .studio-growth-bar { height: 100%; background: linear-gradient(90deg, #FF85A2, #FFB5C5); border-radius: 3px; transition: width 0.6s ease; }
    .studio-growth-stats { font-size: 11px; color: #888; }
    /* [成长系统] 技能弹窗 */
    .studio-growth-panel { display: none; position: fixed; top: 50%; left: 50%; transform: translate(-50%, -50%); background: rgba(10,10,10,0.97); backdrop-filter: blur(20px); border: 1px solid rgba(255,133,162,0.15); border-radius: 16px; padding: 24px; z-index: 2000; width: 380px; max-height: 70vh; overflow-y: auto; box-shadow: 0 16px 48px rgba(0,0,0,0.6); }
    .studio-growth-panel.show { display: block; }
    .studio-growth-panel-overlay { display: none; position: fixed; top: 0; left: 0; width: 100%; height: 100%; background: rgba(0,0,0,0.4); z-index: 1999; }
    .studio-growth-panel-overlay.show { display: block; }
    .studio-growth-panel-title { font-size: 18px; font-weight: 600; color: #FF85A2; margin-bottom: 16px; text-align: center; }
    .studio-growth-panel-close { position: absolute; top: 12px; right: 16px; background: none; border: none; color: #888; font-size: 18px; cursor: pointer; }
    .studio-growth-skill-item { display: flex; align-items: center; gap: 10px; padding: 8px 0; border-bottom: 1px solid rgba(255,255,255,0.04); }
    .studio-growth-skill-name { font-size: 13px; color: #ccc; min-width: 72px; }
    .studio-growth-skill-bar-wrap { flex: 1; height: 5px; background: rgba(255,255,255,0.06); border-radius: 3px; overflow: hidden; }
    .studio-growth-skill-bar { height: 100%; border-radius: 3px; background: linear-gradient(90deg, #64B4FF, #85CFFF); transition: width 0.5s ease; }
    .studio-growth-skill-lv { font-size: 11px; color: #64B4FF; min-width: 36px; text-align: right; }

    /* 消息气泡 - 微信风格 */
    .studio-msg { display: flex; width: 100%; align-items: flex-start; gap: 10px; padding: 0 8px; }
    .studio-msg-user { justify-content: flex-end; }
    .studio-msg-ai { justify-content: flex-start; }
    /* 头像 */
    .studio-msg-avatar {
        width: 36px; height: 36px; border-radius: 6px; flex-shrink: 0;
        overflow: hidden; margin-top: 2px;
        box-shadow: 0 2px 8px rgba(0,0,0,0.2);
    }
    .studio-msg-avatar img {
        width: 100%; height: 100%; object-fit: cover; display: block;
    }
    .studio-msg-avatar-placeholder {
        width: 100%; height: 100%; display: flex; align-items: center; justify-content: center;
        background: linear-gradient(135deg, #FF85A2, #D4A574);
        color: #fff; font-size: 14px; font-weight: 600;
    }
    /* 气泡 */
    .studio-msg-bubble { max-width: 75%; border-radius: 12px; padding: 12px 16px; position: relative; }
    .studio-msg-bubble.user {
        background: rgba(255,133,162,0.12); border: 1px solid rgba(255,133,162,0.2);
        border-radius: 12px 4px 12px 12px;
    }
    .studio-msg-bubble.ai {
        background: rgba(255,255,255,0.04); border: 1px solid rgba(255,255,255,0.08);
        border-radius: 4px 12px 12px 12px;
    }
    /* 微信风格气泡箭头 - AI消息(左侧) */
    .studio-msg-ai .studio-msg-bubble::before {
        content: ''; position: absolute; top: 12px; left: -7px;
        width: 0; height: 0;
        border-top: 6px solid transparent;
        border-bottom: 6px solid transparent;
        border-right: 7px solid rgba(255,255,255,0.08);
    }
    .studio-msg-ai .studio-msg-bubble::after {
        content: ''; position: absolute; top: 13px; left: -5px;
        width: 0; height: 0;
        border-top: 5px solid transparent;
        border-bottom: 5px solid transparent;
        border-right: 6px solid rgba(18,18,18,0.95);
    }
    /* 微信风格气泡箭头 - 用户消息(右侧) */
    .studio-msg-user .studio-msg-bubble::before {
        content: ''; position: absolute; top: 12px; right: -7px;
        width: 0; height: 0;
        border-top: 6px solid transparent;
        border-bottom: 6px solid transparent;
        border-left: 7px solid rgba(255,133,162,0.2);
    }
    .studio-msg-user .studio-msg-bubble::after {
        content: ''; position: absolute; top: 13px; right: -5px;
        width: 0; height: 0;
        border-top: 5px solid transparent;
        border-bottom: 5px solid transparent;
        border-left: 6px solid rgba(255,133,162,0.12);
    }
    .studio-msg-text { color: #ddd; font-size: 14px; line-height: 1.6; white-space: pre-wrap; }
    .studio-msg-meta { color: #555; font-size: 11px; margin-top: 6px; }
    .studio-msg-refs { display: flex; gap: 6px; margin-bottom: 8px; flex-wrap: wrap; }
    .studio-msg-ref-thumb { width: 56px; height: 72px; object-fit: cover; border-radius: 6px; border: 1px solid #333; cursor: pointer; transition: transform 0.2s, border-color 0.2s; }
    .studio-msg-ref-thumb:hover { transform: scale(1.08); border-color: #FF85A2; }

    /* 生成结果 */
    .studio-msg-media { display: flex; flex-wrap: wrap; gap: 8px; margin-bottom: 8px; }
    .studio-msg-image { max-width: 300px; max-height: 400px; border-radius: 8px; cursor: pointer; transition: transform 0.2s; }
    .studio-msg-image:hover { transform: scale(1.02); }
    .studio-msg-video { max-width: 400px; border-radius: 8px; }
    .studio-msg-ai-text { color: #bbb; font-size: 13px; line-height: 1.5; margin-bottom: 8px; }
    .studio-msg-footer { display: flex; align-items: center; gap: 8px; }
    .studio-msg-error { color: #f44; font-size: 13px; padding: 8px 0; }

    /* 畅畅实时思考面板 */
    .studio-agent-think-live {
        margin-bottom: 8px; border-radius: 8px; overflow: hidden;
        background: rgba(167,139,250,0.05); border: 1px solid rgba(167,139,250,0.15);
        transition: all 0.3s ease;
    }
    .studio-think-live-header {
        display: flex; align-items: center; gap: 6px; padding: 8px 12px;
        font-size: 12px; color: #a78bfa;
    }
    .studio-think-live-icon { display: flex; align-items: center; }
    .studio-think-live-title { font-weight: 600; }
    .studio-think-live-dots { display: inline-flex; gap: 3px; margin-left: 4px; }
    .studio-think-live-dots span {
        width: 4px; height: 4px; background: #a78bfa; border-radius: 50%;
        animation: studioDotPulse 1.4s infinite ease-in-out;
    }
    .studio-think-live-dots span:nth-child(2) { animation-delay: 0.2s; }
    .studio-think-live-dots span:nth-child(3) { animation-delay: 0.4s; }
    .studio-think-live-body {
        padding: 0 12px 8px; max-height: 120px; overflow-y: auto;
        transition: max-height 0.3s ease, padding 0.3s ease, opacity 0.3s ease;
    }
    .studio-think-live-step {
        font-size: 11px; color: #999; line-height: 1.6;
        animation: studioFadeIn 0.3s ease;
    }
    .studio-think-live-dot { color: #a78bfa; font-weight: bold; }
    .studio-agent-think-live.collapsed .studio-think-live-body {
        max-height: 0; padding-top: 0; padding-bottom: 0; opacity: 0;
    }
    .studio-agent-think-live.collapsed .studio-think-live-header::after {
        content: '\25B6'; font-size: 9px; margin-left: auto; color: #666;
    }
    .studio-agent-think-live:not(.collapsed) .studio-think-live-header::after {
        content: '\25BC'; font-size: 9px; margin-left: auto; color: #666;
    }
    @keyframes studioFadeIn { from { opacity: 0; transform: translateY(-4px); } to { opacity: 1; transform: translateY(0); } }

    /* [v8.0] Agent Chat 文本气泡 */
    .studio-agent-text {
        white-space: pre-wrap; line-height: 1.7; color: #e0e0e0; font-size: 13px; word-break: break-word;
    }
    .studio-agent-streaming .studio-agent-text::after {
        content: '\u258E'; animation: agentBlink 0.8s infinite; color: #FF85A2; font-weight: bold;
    }
    @keyframes agentBlink { 50% { opacity: 0; } }
    .studio-agent-thinking { color: #888; font-style: italic; font-size: 12px; margin-bottom: 6px; }
    .studio-agent-status { color: #888; font-style: italic; font-size: 12px; margin-bottom: 6px; }
    /* Agent 增强对比 */
    .studio-agent-enhanced {
        margin: 6px 0; padding: 8px; background: rgba(167,139,250,0.06); border-radius: 6px;
        border-left: 3px solid #a78bfa; font-size: 12px;
    }
    .studio-agent-enhance-row { margin: 3px 0; color: #c0c0c0; }
    .studio-agent-enhance-label { color: #888; font-weight: 600; margin-right: 4px; }
    /* Agent 澄清选项 */
    .studio-agent-clarify { margin-top: 8px; }
    .studio-agent-clarify-q { color: #e0e0e0; margin-bottom: 8px; font-size: 13px; }
    .studio-agent-clarify-opts { display: flex; flex-wrap: wrap; gap: 6px; }
    .studio-agent-clarify-btn {
        padding: 6px 14px; background: rgba(167,139,250,0.1); border: 1px solid #a78bfa;
        border-radius: 16px; color: #e0e0e0; font-size: 12px; cursor: pointer; transition: all 0.2s;
    }
    .studio-agent-clarify-btn:hover { background: #a78bfa; color: white; }
    /* Agent 建议 chips */
    .studio-agent-suggest {
        display: flex; flex-wrap: wrap; gap: 6px; margin-top: 10px; padding-top: 8px;
        border-top: 1px solid rgba(255,255,255,0.06);
    }
    .studio-agent-suggest-chip {
        padding: 5px 12px; background: transparent; border: 1px solid #FF85A2;
        border-radius: 14px; color: #FF85A2; font-size: 12px; cursor: pointer; transition: all 0.2s;
    }
    .studio-agent-suggest-chip:hover { background: #FF85A2; color: white; }
    /* Agent 媒体预览 */
    .studio-agent-media { display: flex; flex-wrap: wrap; gap: 8px; margin: 8px 0; }
    /* 积分消耗标注 */
    .studio-agent-points {
        margin-top: 10px; padding: 6px 12px; font-size: 12px; color: #f0b866;
        background: rgba(240,184,102,0.08); border: 1px solid rgba(240,184,102,0.2);
        border-radius: 6px; display: inline-flex; align-items: center; gap: 4px;
    }
    .studio-agent-points .pts-icon { font-size: 14px; }

    /* 操作按钮 */
    .studio-msg-actions { display: flex; gap: 8px; margin-top: 8px; opacity: 0; transition: opacity 0.2s; }
    .studio-msg-bubble:hover .studio-msg-actions { opacity: 1; }
    .studio-action-btn {
        background: rgba(255,255,255,0.06); border: 1px solid rgba(255,255,255,0.1);
        color: #888; font-size: 11px; padding: 3px 10px; border-radius: 6px; cursor: pointer; transition: all 0.2s;
    }
    .studio-action-btn:hover { background: rgba(255,133,162,0.15); color: #FF85A2; border-color: rgba(255,133,162,0.3); }

    /* 加载动画 */
    .studio-msg-loading { display: flex; flex-direction: column; align-items: center; padding: 16px; }
    .studio-loading-dots { display: flex; gap: 6px; }
    .studio-loading-dots span {
        width: 8px; height: 8px; background: #FF85A2; border-radius: 50%;
        animation: studioDotPulse 1.4s infinite ease-in-out;
    }
    .studio-loading-dots span:nth-child(2) { animation-delay: 0.2s; }
    .studio-loading-dots span:nth-child(3) { animation-delay: 0.4s; }
    @keyframes studioDotPulse { 0%,80%,100% { opacity: 0.3; transform: scale(0.8); } 40% { opacity: 1; transform: scale(1.1); } }

    /* ===== 底部悬浮输入区 ===== */
    .studio-input-area {
        flex-shrink: 0; padding: 16px 5% 20px;
        background: transparent;
        position: relative; z-index: 100;
        -webkit-app-region: no-drag;
    }
    .studio-input-bubble {
        background: rgba(10,10,10,0.68); border: 1px solid rgba(255,255,255,0.08);
        border-radius: 16px; padding: 14px 16px 10px;
        box-shadow: 0 -4px 24px rgba(0,0,0,0.3);
    }
    /* 上层：参考图(左) + 输入框(右) */
    .studio-input-top {
        display: flex; gap: 12px; align-items: flex-end; margin-bottom: 10px;
    }
    .studio-ref-section {
        flex-shrink: 0; position: relative;
    }
    .studio-prompt-section {
        flex: 1; display: flex; align-items: flex-end; gap: 8px;
    }
    .studio-prompt-input {
        flex: 1; background: transparent; border: none;
        color: #ddd; font-size: 14px; padding: 8px 4px;
        outline: none; min-height: 24px; max-height: 120px;
        line-height: 1.5; font-family: inherit;
        -webkit-app-region: no-drag;
        overflow-y: auto; word-break: break-word; white-space: pre-wrap;
    }
    .studio-prompt-input:empty::before {
        content: attr(data-placeholder); color: #555; pointer-events: none;
    }

    /* 参考图气泡样式 */
    .char-bubble {
        display: inline-flex; align-items: center; gap: 4px;
        background: rgba(255, 133, 162, 0.15); border: 1px solid rgba(255, 133, 162, 0.3);
        border-radius: 12px; padding: 1px 8px 1px 2px; margin: 0 2px;
        vertical-align: middle; cursor: default; line-height: 1.4;
    }
    .char-bubble-avatar {
        width: 20px; height: 20px; border-radius: 50%;
        object-fit: cover; object-position: top; flex-shrink: 0;
    }
    .char-bubble-name { color: #FF85A2; font-weight: 600; font-size: 13px; white-space: nowrap; }
    .char-bubble-tooltip {
        position: fixed; display: none; z-index: 10002;
        background: rgba(10, 10, 10, 0.95); border: 1px solid rgba(255, 133, 162, 0.3);
        border-radius: 8px; padding: 4px; box-shadow: 0 4px 16px rgba(0,0,0,0.5);
        opacity: 0; transition: opacity 0.2s; pointer-events: none;
    }
    .char-bubble-tooltip.visible { opacity: 1; }
    .char-bubble-tooltip-img { display: block; width: 120px; height: auto; border-radius: 4px; }

    /* 参考图选择器弹窗 */
    .studio-ref-selector-popup {
        position: fixed; background: rgba(10,10,10,0.92);
        border: 1px solid rgba(255,255,255,0.12); border-radius: 10px;
        box-shadow: 0 4px 20px rgba(0,0,0,0.5); z-index: 10001;
        max-height: 320px; overflow-y: auto; min-width: 160px; padding: 4px;
        backdrop-filter: blur(16px); -webkit-backdrop-filter: blur(16px);
    }
    .studio-ref-selector-item {
        display: flex; align-items: center; gap: 8px;
        padding: 6px 10px; cursor: pointer; border-radius: 6px; transition: background 0.15s;
    }
    .studio-ref-selector-item:hover { background: rgba(255, 133, 162, 0.15); }
    .studio-ref-selector-thumb {
        width: 36px; height: 36px; border-radius: 4px;
        object-fit: cover; background: #333; flex-shrink: 0;
    }
    .studio-ref-selector-label { color: #ddd; font-size: 13px; }
    .studio-send-btn {
        width: 38px; height: 38px; border-radius: 50%; border: none;
        background: linear-gradient(135deg, #FF85A2, #D4A574);
        color: #0a0a0a; font-size: 16px; cursor: pointer; flex-shrink: 0;
        display: flex; align-items: center; justify-content: center;
        transition: transform 0.15s, box-shadow 0.15s;
        -webkit-app-region: no-drag; pointer-events: auto;
        touch-action: manipulation;
    }
    .studio-send-btn:hover { transform: scale(1.05); box-shadow: 0 0 12px rgba(255,133,162,0.4); }
    /* 发送按钮区域（含积分预估） */
    .studio-send-area {
        display: flex; flex-direction: row; align-items: center; gap: 6px; flex-shrink: 0;
    }
    .studio-points-estimate {
        font-size: 10px; color: #FF85A2; white-space: nowrap;
        opacity: 0.85; line-height: 1; user-select: none;
    }

    /* 下层：模式下拉 + 设置按钮 */
    .studio-input-bottom {
        display: flex; align-items: center; gap: 6px;
        border-top: 1px solid rgba(255,255,255,0.05); padding-top: 8px;
        position: relative;
    }

    /* 工具栏按钮（统一风格） */
    .studio-toolbar-btn {
        display: flex; align-items: center; gap: 5px;
        padding: 7px 14px; border-radius: 8px; min-height: 32px;
        border: 1px solid rgba(255,255,255,0.1); background: rgba(255,255,255,0.04);
        color: #aaa; font-size: 12px; cursor: pointer;
        transition: background-color 0.15s, color 0.15s, border-color 0.15s;
        white-space: nowrap; position: relative; pointer-events: auto;
        -webkit-app-region: no-drag; user-select: none;
        touch-action: manipulation;
    }
    .studio-toolbar-btn:hover { background: rgba(255,255,255,0.08); color: #ddd; border-color: rgba(255,255,255,0.15); }
    .studio-toolbar-btn .studio-toolbar-arrow { font-size: 10px; color: #666; }
    .studio-mode-trigger.active-mode { border-color: rgba(255,133,162,0.35); color: #FF85A2; }
    /* [联网搜索] 搜索开关按钮 */
    .studio-search-toggle-wrap { display: flex; align-items: center; gap: 6px; padding: 0 4px; }
    .studio-search-toggle-label { font-size: 11px; color: #aaa; white-space: nowrap; user-select: none; }
    .studio-search-toggle { cursor: pointer; user-select: none; -webkit-app-region: no-drag; }
    .studio-search-toggle-track {
        width: 34px; height: 18px; border-radius: 9px;
        background: rgba(255,255,255,0.12); position: relative; transition: background 0.2s;
    }
    .studio-search-toggle-thumb {
        width: 14px; height: 14px; border-radius: 50%;
        background: #888; position: absolute; top: 2px; left: 2px; transition: left 0.2s, background 0.2s;
    }
    .studio-search-toggle.on .studio-search-toggle-track { background: rgba(100,180,255,0.35); }
    .studio-search-toggle.on .studio-search-toggle-thumb { left: 18px; background: #64B4FF; }
    .studio-search-toggle.on + .studio-search-toggle-label { color: #64B4FF; }

    /* ===== Popover 弹出气泡（通用） ===== */
    .studio-mode-dropdown-wrap, .studio-prefs-dropdown-wrap { position: relative; }
    .studio-popover {
        display: none; position: absolute; bottom: calc(100% + 8px); left: 0;
        background: rgba(10,10,10,0.95); backdrop-filter: blur(20px); -webkit-backdrop-filter: blur(20px); border: 1px solid rgba(255,133,162,0.15);
        border-radius: 12px; box-shadow: 0 -8px 32px rgba(0,0,0,0.5);
        z-index: 1000; min-width: 180px;
    }
    .studio-popover.show { display: block; }
    .studio-popover-header {
        display: flex; justify-content: space-between; align-items: center;
        padding: 12px 16px 8px; border-bottom: 1px solid rgba(255,255,255,0.06);
    }
    .studio-popover-title { color: #ddd; font-size: 13px; font-weight: 600; padding: 0 16px; padding-top: 10px; }
    .studio-popover-header .studio-popover-title { padding: 0; }

    /* 创作类型下拉选项 */
    .studio-mode-option {
        display: flex; align-items: center; gap: 10px; padding: 10px 16px;
        color: #bbb; font-size: 13px; cursor: pointer; transition: background 0.15s;
    }
    .studio-mode-option:hover { background: rgba(255,255,255,0.06); }
    .studio-mode-option.active { color: #FF85A2; }
    .studio-mode-opt-icon { width: 20px; text-align: center; font-size: 14px; }
    .studio-mode-check { margin-left: auto; opacity: 0; font-size: 13px; color: #FF85A2; }
    .studio-mode-option.active .studio-mode-check { opacity: 1; }

    /* 生成偏好弹出面板 */
    .studio-mode-popover { overflow: hidden; }
    .studio-prefs-popover { min-width: 420px; padding-bottom: 12px; overflow: visible; }
    /* 自动模式：面板内容变灰不可操作 */
    #studioPrefsContent.studio-prefs-disabled {
        opacity: 0.3;
        pointer-events: none;
        user-select: none;
        transition: opacity 0.25s ease;
    }
    .studio-prefs-section-label {
        color: #777; font-size: 11px; padding: 10px 16px 6px; font-weight: 500;
    }

    /* 比例选择 */
    .studio-ratios { display: flex; gap: 3px; padding: 0 12px; flex-wrap: wrap; }
    .studio-ratio-btn {
        padding: 6px 8px; border-radius: 6px; border: 1px solid transparent;
        background: transparent; color: #666; font-size: 10px; cursor: pointer; transition: all 0.2s;
        display: flex; flex-direction: column; align-items: center; gap: 2px;
    }
    .studio-ratio-btn:hover { color: #aaa; background: rgba(255,255,255,0.04); }
    .studio-ratio-btn.active { border-color: rgba(255,133,162,0.4); color: #FF85A2; background: rgba(255,133,162,0.08); }
    .studio-ratio-icon { font-size: 16px; line-height: 1; }
    .studio-ratio-label { font-size: 9px; }

    /* 模型选择器 */
    .studio-prefs-models { padding: 4px 12px; display: flex; flex-direction: column; gap: 6px; overflow: visible; }
    .studio-model-sel {
        display: flex; align-items: center; gap: 4px; padding: 6px 12px;
        border-radius: 8px; border: 1px solid rgba(255,255,255,0.08);
        background: rgba(255,255,255,0.03); color: #888; font-size: 12px; cursor: pointer; transition: all 0.2s;
        position: relative;
    }
    .studio-model-sel:hover { background: rgba(255,255,255,0.06); color: #bbb; }
    .studio-model-dropdown {
        position: absolute; bottom: calc(100% + 4px); left: 0; min-width: 220px;
        background: rgba(10,10,10,0.97); border: 1px solid rgba(255,255,255,0.12); border-radius: 8px;
        box-shadow: 0 -4px 20px rgba(0,0,0,0.55); z-index: 2000; display: none;
        max-height: 360px; overflow-y: auto; padding: 4px 0;
    }
    .studio-model-dropdown.show { display: block; }
    /* [v57.0] 工作台模式切换按钮 */
    .studio-mode-toggle {
        display: inline-flex;
        border-radius: 4px;
        overflow: hidden;
        border: 1px solid rgba(255,255,255,0.12);
        flex-shrink: 0;
        height: 26px;
    }
    .studio-mode-toggle .s-mode-btn {
        padding: 0 8px;
        font-size: 10px;
        font-weight: 500;
        cursor: pointer;
        background: transparent;
        color: #666;
        border: none;
        transition: all 0.2s;
        white-space: nowrap;
        line-height: 24px;
    }
    .studio-mode-toggle .s-mode-btn:first-child {
        border-right: 1px solid rgba(255,255,255,0.12);
    }
    .studio-mode-toggle .s-mode-btn:hover {
        color: #aaa;
        background: rgba(255,255,255,0.05);
    }
    .studio-mode-toggle .s-mode-btn.active {
        background: rgba(255,133,162,0.2);
        color: #FF85A2;
        font-weight: 600;
    }
    .studio-mode-toggle .s-mode-btn.active.comfyui-active {
        background: rgba(46,204,113,0.2);
        color: #2ecc71;
    }
    .studio-inline-option.comfyui-wf { color: #2ecc71; }
    .studio-inline-option.comfyui-wf.active { background: rgba(46,204,113,0.15); color: #2ecc71; }
    .studio-model-option.comfyui-wf { color: #2ecc71; }
    .studio-model-option.comfyui-wf.active { background: rgba(46,204,113,0.15); color: #2ecc71; }
    .studio-model-option {
        padding: 8px 14px; color: #bbb; font-size: 12px; cursor: pointer; transition: background 0.15s;
        display: flex; align-items: center; min-height: 40px;
    }
    .studio-model-option:hover { background: rgba(255,133,162,0.1); color: #FF85A2; }
    .studio-model-option.active { color: #FF85A2; font-weight: 600; }
    .studio-model-icon { width: 28px; height: 28px; border-radius: 4px; margin-right: 8px; object-fit: cover; flex-shrink: 0; }
    .studio-model-label { flex: 1; min-width: 0; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
    .studio-model-price { font-size: 10px; color: #FF85A2; margin-left: 6px; white-space: nowrap; flex-shrink: 0; }

    /* Agent模式文本模型 */
    #studioAgentModelSection { display: none; }

    /* 内联下拉按钮（图片/视频模式底部工具栏） */
    .studio-inline-dropdown-wrap { position: relative; }
    .studio-inline-popover {
        position: absolute; bottom: calc(100% + 8px); left: 0;
        background: rgba(10,10,10,0.95); backdrop-filter: blur(20px); -webkit-backdrop-filter: blur(20px); border: 1px solid rgba(255,133,162,0.15);
        border-radius: 10px; box-shadow: 0 -8px 32px rgba(0,0,0,0.5);
        z-index: 2000; min-width: 160px; display: none; padding: 4px 0;
        max-height: 360px; overflow-y: auto;
    }
    .studio-inline-popover.show { display: block; }
    .studio-inline-option {
        padding: 8px 14px; color: #bbb; font-size: 12px; cursor: pointer; transition: background 0.15s;
        white-space: nowrap;
    }
    .studio-inline-option:hover { background: rgba(255,133,162,0.1); color: #FF85A2; }
    .studio-inline-option.active { color: #FF85A2; font-weight: 600; }

    /* 自动按钮 */
    .studio-auto-btn {
        padding: 3px 12px; border-radius: 20px; border: 1px solid rgba(255,255,255,0.1);
        background: transparent; color: #888; font-size: 11px; cursor: pointer; transition: all 0.2s;
    }
    .studio-auto-btn:hover { border-color: rgba(255,133,162,0.3); color: #bbb; }
    .studio-auto-btn.active { background: rgba(255,133,162,0.15); border-color: rgba(255,133,162,0.4); color: #FF85A2; }
    /* 内联自动/手动切换按钮（图片/视频模式） */
    .studio-inline-auto-btn { border-color: rgba(255,133,162,0.4); color: #FF85A2; background: rgba(255,133,162,0.10); }
    .studio-inline-auto-btn.active { border-color: rgba(255,133,162,0.5); color: #FF85A2; background: rgba(255,133,162,0.18); }
    .studio-inline-auto-btn:not(.active) { border-color: rgba(255,255,255,0.15); color: #aaa; background: rgba(255,255,255,0.04); }

    /* 音频开关组件 */
    .studio-audio-toggle-wrap { display: flex; align-items: center; gap: 6px; padding: 0 4px; }
    .studio-audio-toggle-label { font-size: 11px; color: #aaa; white-space: nowrap; user-select: none; min-width: 24px; }
    .studio-audio-toggle { cursor: pointer; user-select: none; -webkit-app-region: no-drag; }
    .studio-audio-toggle-track {
        width: 34px; height: 18px; border-radius: 9px;
        background: rgba(255,255,255,0.12); position: relative;
        transition: background 0.2s;
    }
    .studio-audio-toggle-thumb {
        width: 14px; height: 14px; border-radius: 50%;
        background: #888; position: absolute; top: 2px; left: 2px;
        transition: left 0.2s, background 0.2s;
    }
    .studio-audio-toggle.on .studio-audio-toggle-track { background: rgba(255,133,162,0.35); }
    .studio-audio-toggle.on .studio-audio-toggle-thumb { left: 18px; background: #FF85A2; }
    .studio-audio-toggle.disabled { opacity: 0.4; cursor: not-allowed; }
    .studio-audio-toggle.disabled .studio-audio-toggle-thumb { background: #555; }

    /* Agent Tab切换 */
    .studio-prefs-tabs-wrap {
        display: flex; gap: 0; padding: 8px 12px 0; border-bottom: 1px solid rgba(255,255,255,0.06);
    }
    .studio-prefs-tab {
        flex: 1; padding: 6px 0; border: none; background: transparent;
        color: #666; font-size: 12px; cursor: pointer; transition: all 0.2s;
        border-bottom: 2px solid transparent; text-align: center;
    }
    .studio-prefs-tab:hover { color: #aaa; }
    .studio-prefs-tab.active { color: #FF85A2; border-bottom-color: #FF85A2; }

    /* 清晰度选择 */
    .studio-resolutions { display: flex; gap: 3px; padding: 0 12px; flex-wrap: wrap; }

    /* 模型+清晰度同行布局 */
    .studio-prefs-model-res-row {
        display: flex; gap: 8px; padding: 0 12px 4px; align-items: flex-start;
    }
    .studio-prefs-model-res-row .studio-prefs-model-col { flex: 1; min-width: 0; }
    .studio-prefs-model-res-row .studio-prefs-res-col { flex-shrink: 0; width: 100px; }
    .studio-prefs-model-res-row .studio-prefs-section-label { padding: 10px 0 6px; min-height: 26px; display: flex; align-items: center; }
    .studio-prefs-model-res-row .studio-model-sel { margin: 0; }

    /* 自动模式：仅禁用比例和清晰度，模型仍可选 */
    #studioPrefsContent .studio-ratios.auto-disabled,
    #studioPrefsContent .studio-resolution-section.auto-disabled {
        opacity: 0.35; pointer-events: none; user-select: none;
    }

    /* ===== 参考图卡片(复用样式) ===== */
    .studio-ref-stack {
        position: relative; display: flex; align-items: flex-end;
        min-height: 80px;
    }
    .studio-ref-card {
        width: 56px; min-height: 70px; border-radius: 5px; overflow: hidden;
        background: transparent; border: 1.5px solid #333; position: relative;
        flex-shrink: 0; cursor: pointer; transition: all 0.35s cubic-bezier(0.4,0,0.2,1);
        box-shadow: 0 2px 6px rgba(0,0,0,0.4);
        display: flex; align-items: center; justify-content: center;
    }
    .studio-ref-stack.stacked .studio-ref-card { position: absolute; bottom: 0; }
    .studio-ref-stack.stacked.expanded { display: flex; flex-wrap: wrap; gap: 5px; }
    .studio-ref-stack.stacked.expanded .studio-ref-card { position: relative; transform: none !important; }
    .studio-ref-stack:not(.stacked) .studio-ref-card { margin-right: -10px; }
    .studio-ref-stack:not(.stacked) .studio-ref-card:last-child { margin-right: 0; }
    .studio-ref-card img { width: 100%; height: 100%; display: block; object-fit: contain; }
    .studio-ref-label {
        position: absolute; bottom: 0; left: 0; right: 0;
        background: linear-gradient(transparent, rgba(0,0,0,0.8));
        color: #FF85A2; font-size: 8px; text-align: center; padding: 8px 0 2px; font-weight: 600;
    }
    .studio-ref-del {
        position: absolute; top: 2px; right: 2px; width: 14px; height: 14px;
        background: rgba(0,0,0,0.70); border-radius: 50%;
        color: #f44; font-size: 10px; line-height: 13px; text-align: center;
        cursor: pointer; opacity: 0; transition: opacity 0.2s; z-index: 3;
    }
    .studio-ref-card:hover .studio-ref-del { opacity: 1; }
    .studio-ref-card:hover { transform: translateY(-6px) !important; z-index: 20 !important; border-color: #FF85A2; }
    .studio-ref-stack.stacked:not(.expanded) .studio-ref-del { display: none; }
    .studio-ref-stack.stacked:not(.expanded) .studio-ref-add { display: none; }
    .studio-ref-count {
        position: absolute; top: -5px; right: -5px; min-width: 18px; height: 18px;
        background: #FF85A2; color: #0a0a0a; font-size: 9px; font-weight: 700;
        border-radius: 9px; display: flex; align-items: center; justify-content: center;
        z-index: 50; pointer-events: none; padding: 0 4px;
    }
    .studio-ref-empty {
        display: flex; flex-direction: column; align-items: center; justify-content: center;
        width: 56px; aspect-ratio: 9/16; border: 1.5px dashed #444; border-radius: 5px;
        color: #555; font-size: 9px; cursor: pointer; transition: all 0.2s;
    }
    .studio-ref-empty:hover { border-color: #FF85A2; color: #FF85A2; }
    .studio-ref-add {
        width: 56px; aspect-ratio: 9/16; border: 1.5px dashed #444; border-radius: 5px;
        display: flex; align-items: center; justify-content: center;
        color: #666; cursor: pointer; transition: all 0.2s; flex-shrink: 0;
    }
    .studio-ref-add:hover { border-color: #FF85A2; color: #FF85A2; }

    /* ===== 详情弹窗 ===== */
    .studio-detail-overlay {
        position: fixed; top: 0; left: 0; right: 0; bottom: 0;
        background: rgba(0,0,0,0.7); z-index: 5000;
        display: flex; align-items: center; justify-content: center;
    }
    .studio-detail-panel {
        background: rgba(10,10,10,0.95); backdrop-filter: blur(20px); -webkit-backdrop-filter: blur(20px); border: 1px solid rgba(255,133,162,0.15);
        border-radius: 12px; width: 420px; max-height: 70vh; overflow-y: auto;
    }
    .studio-detail-header {
        display: flex; justify-content: space-between; align-items: center;
        padding: 14px 18px; border-bottom: 1px solid rgba(255,255,255,0.06);
        color: #FF85A2; font-weight: 600; font-size: 15px;
    }
    .studio-detail-body { padding: 14px 18px; }
    .studio-detail-row {
        display: flex; justify-content: space-between; padding: 8px 0;
        border-bottom: 1px solid rgba(255,255,255,0.04); font-size: 13px; color: #bbb;
    }
    .studio-detail-key { color: #777; min-width: 60px; }
    /* 详情弹窗媒体区域 */
    .studio-detail-media { position: relative; margin-bottom: 12px; }
    .studio-detail-media img, .studio-detail-media video {
        width: 100%; border-radius: 8px; display: block;
    }
    .studio-detail-refs { display: flex; gap: 6px; flex-wrap: wrap; margin-bottom: 10px; }
    .studio-detail-refs img, .studio-detail-refs video {
        width: 48px; height: 60px; object-fit: cover; border-radius: 4px; border: 1px solid #333;
    }
    .studio-detail-section-label {
        color: #777; font-size: 11px; margin-bottom: 6px; margin-top: 10px;
    }
    /* 媒体悬停下载按钮 */
    .studio-media-wrap { position: relative; display: inline-block; }
    .studio-media-wrap .studio-dl-btn {
        position: absolute; top: 8px; right: 8px; z-index: 10;
        width: 32px; height: 32px; border-radius: 50%;
        background: rgba(0,0,0,0.55); border: 1px solid rgba(255,255,255,0.15);
        color: #fff; font-size: 16px; cursor: pointer;
        display: flex; align-items: center; justify-content: center;
        opacity: 0; transition: opacity 0.2s;
        backdrop-filter: blur(4px); -webkit-backdrop-filter: blur(4px);
    }
    .studio-media-wrap:hover .studio-dl-btn { opacity: 1; }
    .studio-media-wrap .studio-dl-btn:hover {
        background: rgba(255,133,162,0.4); border-color: rgba(255,133,162,0.5);
    }
    .studio-dl-btn svg { width: 16px; height: 16px; stroke: currentColor; fill: none; stroke-width: 2; stroke-linecap: round; stroke-linejoin: round; }

    /* ===== 畅畅思考过程面板 ===== */
    .studio-think-panel {
        margin-bottom: 10px; border-radius: 8px;
        background: rgba(255,133,162,0.04); border: 1px solid rgba(255,133,162,0.12);
        overflow: hidden; transition: all 0.3s ease;
    }
    .studio-think-panel.collapsed .studio-think-body { display: none; }
    .studio-think-panel.collapsed .studio-think-toggle { transform: rotate(-90deg); }
    .studio-think-header {
        display: flex; align-items: center; gap: 6px; padding: 8px 12px;
        cursor: pointer; user-select: none; transition: background 0.2s;
    }
    .studio-think-header:hover { background: rgba(255,133,162,0.06); }
    .studio-think-icon { font-size: 14px; }
    .studio-think-title { font-size: 11px; color: #FF85A2; font-weight: 600; flex: 1; }
    .studio-think-toggle { font-size: 10px; color: #888; transition: transform 0.2s; }
    .studio-think-body { padding: 4px 12px 10px; }
    .studio-think-row {
        display: flex; gap: 8px; padding: 4px 0; font-size: 11px;
        border-bottom: 1px solid rgba(255,255,255,0.03);
    }
    .studio-think-row:last-child { border-bottom: none; }
    .studio-think-label {
        color: #888; min-width: 56px; flex-shrink: 0; font-weight: 500;
    }
    .studio-think-value {
        color: #aaa; word-break: break-all; line-height: 1.5;
    }
    .studio-think-tag {
        display: inline-block; padding: 1px 8px; border-radius: 4px;
        background: rgba(255,133,162,0.12); color: #FF85A2; font-size: 10px;
    }
    .studio-think-original {
        color: #999; text-decoration: line-through; text-decoration-color: rgba(255,255,255,0.15);
    }
    .studio-think-enhanced { color: #8BC34A; }
    .studio-think-negative { color: #e88; font-size: 10px; }

    /* 项目列表页面特殊处理 - 不需要额外padding */
    #pageCreation.home-page,
    #pageDialogueDrama.home-page {
        padding: 0;
    }

    .char-lib-page-header {
        display: flex;
        justify-content: space-between;
        align-items: center;
        margin-bottom: 20px;
    }

    .char-lib-page-header h2 {
        color: #FF85A2;
        font-size: 20px;
        margin: 0;
    }

    .char-lib-grid {
        display: flex;
        flex-wrap: wrap;
        gap: 16px;
    }
    .char-lib-grid .wizard-char-card {
        width: 280px;
        flex-shrink: 0;
    }

    .char-lib-add-card {
        width: 280px;
        aspect-ratio: 4/3;
        background: rgba(10, 10, 10, 0.65);
        border: 2px dashed rgba(255, 133, 162, 0.4);
        border-radius: 10px;
        display: flex;
        flex-direction: column;
        align-items: center;
        justify-content: center;
        gap: 10px;
        cursor: pointer;
        transition: all 0.2s;
    }

    .char-lib-add-card:hover {
        background: rgba(15, 15, 15, 0.72);
        border-color: rgba(255, 133, 162, 0.7);
    }

    .char-lib-add-card .add-icon {
        font-size: 36px;
        color: rgba(255, 133, 162, 0.7);
    }

    .char-lib-add-card .add-text {
        font-size: 13px;
        color: rgba(255, 133, 162, 0.7);
    }

    /* ====== 场景库网格 ====== */
    .dd-scene-grid {
        display: flex;
        flex-wrap: wrap;
        gap: 16px;
        align-content: flex-start;
    }
    .dd-scene-card { cursor: pointer; }

    .char-lib-card {
        width: 280px;
        aspect-ratio: 4/3;
        background: rgba(10, 10, 10, 0.65);
        border: 1px solid rgba(255, 255, 255, 0.08);
        border-radius: 10px;
        overflow: hidden;
        cursor: pointer;
        transition: border-color 0.2s, box-shadow 0.2s;
        display: flex;
        flex-direction: column;
    }

    .char-lib-card:hover {
        border-color: rgba(255, 133, 162, 0.5);
        box-shadow: 0 4px 16px rgba(255, 133, 162, 0.15);
    }

    .char-lib-card-body {
        display: flex;
        flex: 1;
        min-height: 0;
    }

    .char-lib-card-image {
        flex-shrink: 0;
        height: 100%;
        aspect-ratio: 16/9;
        max-width: 50%;
        background: rgba(0, 0, 0, 0.70);
        overflow: hidden;
        display: flex;
        align-items: center;
        justify-content: center;
    }

    .char-lib-card-image img {
        width: 100%;
        height: 100%;
        object-fit: cover;
        object-position: top;
    }

    .char-lib-card-image .empty-avatar {
        color: #555;
        font-size: 11px;
        text-align: center;
    }

    .char-lib-card-content {
        flex: 1;
        padding: 10px 12px;
        display: flex;
        flex-direction: column;
        gap: 6px;
        min-width: 0;
    }

    .char-lib-card-header {
        display: flex;
        align-items: center;
        gap: 6px;
        flex-wrap: wrap;
    }

    .char-lib-card-name {
        font-size: 14px;
        font-weight: 700;
        color: #fff;
    }

    .char-lib-role-tag {
        font-size: 11px;
        padding: 2px 6px;
        background: rgba(255, 133, 162, 0.15);
        color: #FF85A2;
        border-radius: 4px;
    }

    .char-lib-card-desc {
        font-size: 11px;
        color: #aaa;
        line-height: 1.4;
        flex: 1;
        overflow: hidden;
        display: -webkit-box;
        -webkit-line-clamp: 3;
        -webkit-box-orient: vertical;
    }

    .char-lib-card-footer {
        display: flex;
        align-items: center;
        justify-content: space-evenly;
        gap: 0;
        padding: 0;
        border-top: 1px solid #333;
        background: rgba(15,15,15,0.65);
        font-size: 11px;
    }

    .char-lib-card-footer .wcc-item {
        flex: 1;
        display: flex;
        align-items: center;
        justify-content: center;
        gap: 4px;
        padding: 8px 6px;
        cursor: pointer;
        color: #888;
        transition: all 0.15s;
        border-right: 1px solid #333;
    }

    .char-lib-card-footer .wcc-item:last-child {
        border-right: none;
    }

    .char-lib-card-footer .wcc-item:hover {
        background: rgba(255, 255, 255, 0.06);
        color: #FF85A2;
    }

    .char-lib-card-delete {
        flex: 1;
        display: flex;
        align-items: center;
        justify-content: center;
        padding: 8px 6px;
        font-size: 11px;
        background: transparent;
        border: none;
        color: #dc3545;
        cursor: pointer;
        transition: all 0.15s;
    }

    .char-lib-card-delete:hover {
        background: rgba(220, 53, 69, 0.1);
        color: #ff6b6b;
    }

    /* ===== 音色库卡片 ===== */
    .voice-filter-bar {
        display: flex;
        gap: 8px;
        padding: 0 0 16px 0;
    }
    .voice-filter-btn {
        padding: 6px 18px;
        border-radius: 20px;
        border: 1px solid #444;
        background: transparent;
        color: #aaa;
        font-size: 13px;
        cursor: pointer;
        transition: all 0.2s;
    }
    .voice-filter-btn:hover {
        border-color: rgba(255,133,162,0.4);
        color: #fff;
    }
    .voice-filter-btn.active {
        background: rgba(255,133,162,0.15);
        border-color: #FF85A2;
        color: #FF85A2;
    }
    .voice-card-grid {
        display: grid;
        grid-template-columns: repeat(auto-fill, minmax(220px, 1fr));
        gap: 14px;
    }
    .voice-card {
        background: rgba(60, 30, 5, 0.92);
        border: 1px solid rgba(249, 115, 22, 0.4);
        border-radius: 12px;
        padding: 16px;
        cursor: pointer;
        transition: border-color 0.2s, box-shadow 0.2s;
        display: flex;
        flex-direction: column;
        gap: 10px;
    }
    .voice-card:hover {
        border-color: rgba(249, 115, 22, 0.7);
        box-shadow: 0 4px 16px rgba(249, 115, 22, 0.2);
    }
    .voice-card-top {
        display: flex;
        align-items: center;
        gap: 10px;
    }
    .voice-card-avatar {
        width: 42px;
        height: 42px;
        border-radius: 50%;
        display: flex;
        align-items: center;
        justify-content: center;
        font-size: 20px;
        flex-shrink: 0;
    }
    .voice-card-avatar.male {
        background: rgba(100,180,255,0.15);
    }
    .voice-card-avatar.female {
        background: rgba(255,133,162,0.15);
    }
    .voice-card-info {
        flex: 1;
        min-width: 0;
    }
    .voice-card-name {
        font-size: 14px;
        font-weight: 600;
        color: #fff;
        white-space: nowrap;
        overflow: hidden;
        text-overflow: ellipsis;
    }
    .voice-card-meta {
        font-size: 11px;
        color: #888;
        margin-top: 2px;
    }
    .voice-card-tags {
        display: flex;
        gap: 6px;
        flex-wrap: wrap;
    }
    .voice-card-tag {
        font-size: 11px;
        padding: 2px 8px;
        border-radius: 4px;
        background: rgba(139,92,246,0.12);
        color: #a78bfa;
    }
    .voice-card-tag.gender-male {
        background: rgba(100,180,255,0.12);
        color: #6eb4ff;
    }
    .voice-card-tag.gender-female {
        background: rgba(255,133,162,0.12);
        color: #FF85A2;
    }
    .voice-card-footer {
        display: flex;
        align-items: center;
        justify-content: space-between;
    }
    .voice-card-ref {
        font-size: 11px;
        color: #777;
        flex: 1;
        white-space: nowrap;
        overflow: hidden;
        text-overflow: ellipsis;
        margin-right: 8px;
    }
    .voice-card-play {
        width: 32px;
        height: 32px;
        border-radius: 50%;
        border: none;
        background: rgba(249, 115, 22, 0.2);
        color: #F97316;
        cursor: pointer;
        display: flex;
        align-items: center;
        justify-content: center;
        transition: background 0.2s;
        flex-shrink: 0;
    }
    .voice-card-play:hover {
        background: rgba(249, 115, 22, 0.4);
    }
    .voice-card-play.playing {
        background: rgba(249, 115, 22, 0.4);
        animation: voicePulse 1s ease-in-out infinite;
    }
    @keyframes voicePulse {
        0%, 100% { transform: scale(1); }
        50% { transform: scale(1.1); }
    }

    /* 开发中提示 */
    .developing-modal {
        position: fixed;
        top: 50%;
        left: 50%;
        transform: translate(-50%, -50%);
        background: rgba(26, 26, 26, 0.95);
        border: 1px solid rgba(255, 133, 162, 0.4);
        border-radius: 12px;
        padding: 30px 50px;
        text-align: center;
        z-index: 5001;
    }

    .developing-modal .modal-icon {
        font-size: 48px;
        margin-bottom: 12px;
    }

    .developing-modal .modal-text {
        font-size: 16px;
        color: #FF85A2;
        font-weight: 500;
    }

    .developing-modal .modal-sub {
        font-size: 13px;
        color: #888;
        margin-top: 8px;
    }

    .developing-overlay {
        position: fixed;
        top: 0;
        left: 0;
        right: 0;
        bottom: 0;
        background: rgba(0, 0, 0, 0.5);
        z-index: 5000;
    }
    /* [v71.0 fix] 防止刷新时闪烁：将body中延迟定义的隐藏规则提前到head */
    .context-menu, .search-panel { display: none; }

    /* ===== 登录模态框样式 ===== */
    .login-modal-overlay {
        display: none;
        position: fixed;
        inset: 0;
        background: rgba(0,0,0,0.65);
        z-index: 99999;
        align-items: center;
        justify-content: center;
        backdrop-filter: blur(6px);
        -webkit-backdrop-filter: blur(6px);
    }
    .login-modal-overlay.show { display: flex; }
    .login-modal-card {
        background: #1a1a2e;
        border: 1px solid rgba(255,133,162,0.15);
        border-radius: 16px;
        width: 400px;
        max-width: 92vw;
        box-shadow: 0 20px 60px rgba(0,0,0,0.5);
        position: relative;
        overflow: hidden;
    }
    .login-modal-close {
        position: absolute; top: 12px; right: 14px;
        background: rgba(255,255,255,0.06); border: none; color: #888;
        width: 30px; height: 30px; border-radius: 50%; font-size: 18px;
        cursor: pointer; display: flex; align-items: center; justify-content: center;
        transition: all 0.2s;
    }
    .login-modal-close:hover { background: rgba(255,255,255,0.12); color: #fff; }
    .login-modal-header {
        padding: 28px 28px 0;
        text-align: center;
    }
    .login-modal-header .lm-title {
        font-size: 20px; font-weight: 600; color: #f5f5f5;
        background: linear-gradient(135deg, #FF85A2, #FFB0C4);
        -webkit-background-clip: text; -webkit-text-fill-color: transparent;
    }
    .login-modal-header .lm-subtitle { font-size: 13px; color: #a0a0a0; margin-top: 6px; }
    .login-modal-body { padding: 24px 28px 28px; }
    .login-modal-body .form-group { margin-bottom: 16px; }
    .login-modal-body .form-label { display: block; font-size: 13px; color: #a0a0a0; margin-bottom: 6px; font-weight: 500; }
    .login-modal-body .form-input {
        width: 100%; background: rgba(255,255,255,0.05); border: 1px solid rgba(255,255,255,0.1);
        color: #e5e5e5; padding: 11px 14px; border-radius: 8px; font-size: 14px;
        outline: none; transition: border-color 0.3s, box-shadow 0.3s;
    }
    .login-modal-body .form-input::placeholder { color: #666; }
    .login-modal-body .form-input:focus { border-color: #FF85A2; box-shadow: 0 0 0 3px rgba(255, 133, 162, 0.2); }
    .login-modal-body .password-input-group { position: relative; }
    .login-modal-body .password-input-group .form-input { padding-right: 44px; }
    .login-modal-body .toggle-password {
        position: absolute; right: 10px; top: 50%; transform: translateY(-50%);
        background: none; border: none; color: #666; font-size: 12px; cursor: pointer;
    }
    .login-modal-body .toggle-password:hover { color: #FF85A2; }
    .login-modal-body .remember-pwd-row { display: flex; align-items: center; margin: 10px 0 4px 0; }
    .login-modal-body .remember-checkbox-input { position: absolute; opacity: 0; width: 1px; height: 1px; overflow: hidden; }
    .login-modal-body .remember-checkbox-label {
        font-size: 12px; color: #a0a0a0; cursor: pointer; padding-left: 22px; position: relative;
    }
    .login-modal-body .remember-checkbox-label::before {
        content: ''; position: absolute; left: 0; top: 1px;
        width: 14px; height: 14px; border: 1px solid rgba(255,255,255,0.15);
        border-radius: 3px; background: rgba(255,255,255,0.03);
    }
    .login-modal-body .remember-checkbox-input:checked + .remember-checkbox-label::before {
        background: #FF85A2; border-color: #FF85A2;
        content: '\2713'; color: #fff; font-size: 10px; text-align: center; line-height: 14px;
    }
    .login-modal-body .remember-hint { margin-left: auto; font-size: 10px; font-weight: bold; color: rgba(200,200,200,0.7); }
    .login-modal-body .btn-login {
        width: 100%; padding: 12px; border: none; border-radius: 8px; font-size: 15px; font-weight: 600;
        color: #fff; cursor: pointer; margin-top: 8px;
        background: linear-gradient(135deg, #FF85A2, #E8708A);
        transition: transform 0.2s, box-shadow 0.2s;
    }
    .login-modal-body .btn-login:hover { transform: translateY(-1px); box-shadow: 0 6px 20px rgba(255, 133, 162, 0.35); }
    .login-modal-body .btn-login:disabled { opacity: 0.6; cursor: not-allowed; transform: none; }
    .login-modal-body .form-links { display: flex; justify-content: space-between; margin-top: 12px; }
    .login-modal-body .form-link { font-size: 12px; color: #a0a0a0; cursor: pointer; background: none; border: none; padding: 0; transition: color 0.3s; }
    .login-modal-body .form-link:hover { color: #FF85A2; }
    .login-modal-body .panel-title { text-align: center; font-size: 14px; color: #a0a0a0; margin-bottom: 16px; font-weight: 500; }
    .login-modal-body .code-input-group { display: flex; gap: 8px; }
    .login-modal-body .code-input-group .form-input { flex: 1; }
    .login-modal-body .btn-send-code {
        white-space: nowrap; padding: 10px 14px; background: rgba(255,133,162,0.1);
        border: 1px solid rgba(255,133,162,0.3); color: #FF85A2; border-radius: 8px;
        cursor: pointer; font-size: 13px; transition: background 0.2s;
    }
    .login-modal-body .btn-send-code:hover { background: rgba(255, 133, 162, 0.2); }
    .login-modal-body .btn-send-code:disabled { opacity: 0.5; cursor: not-allowed; }
    .login-modal-body .form-hint { text-align: center; font-size: 11px; color: #666; margin-top: 10px; }
    .login-modal-body .lm-message { padding: 8px 12px; border-radius: 6px; font-size: 13px; margin-bottom: 12px; display: none; }
    .login-modal-body .lm-message.error { display: block; background: rgba(239,68,68,0.15); color: #ef4444; border: 1px solid rgba(239,68,68,0.2); }
    .login-modal-body .lm-message.success { display: block; background: rgba(34,197,94,0.15); color: #22c55e; border: 1px solid rgba(34,197,94,0.2); }

    /* agreement checkbox */
    .agreement-check-row { margin-top: 10px; margin-bottom: 2px; }
    .agreement-check-label {
        display: flex; align-items: flex-start; gap: 6px;
        cursor: pointer; font-size: 12px; line-height: 1.6;
        color: #888; user-select: none;
    }
    .agreement-checkbox { position: absolute; opacity: 0; width: 1px; height: 1px; overflow: hidden; }
    .agreement-check-box {
        display: inline-flex; align-items: center; justify-content: center;
        width: 14px; height: 14px; min-width: 14px;
        border: 1.5px solid #555; border-radius: 3px;
        margin-top: 3px; transition: all 0.15s;
    }
    .agreement-check-box img { display: none; }
    .agreement-checkbox:checked + .agreement-check-box {
        background: #FF85A2; border-color: #FF85A2;
    }
    .agreement-checkbox:checked + .agreement-check-box img { display: inline; }
    .agreement-check-text { flex: 1; }
    .agreement-text-link { text-decoration: none; transition: opacity 0.15s; }
    .agreement-text-link:hover { opacity: 0.8; text-decoration: underline; }
    .link-pink { color: #FF85A2; }
    .link-blue { color: #6cb4ee; }
    .link-orange { color: #D4A574; }
    .btn-login.disabled-look {
        background: linear-gradient(135deg, #555 0%, #444 100%) !important;
        color: #888 !important; cursor: not-allowed !important;
        box-shadow: none !important; transform: none !important;
    }

/* ===== Block 2 ===== */
    /* [FIX] 项目列表网格布局 */
    .project-grid {
        display: grid;
        grid-template-columns: repeat(auto-fill, minmax(300px, 1fr));
        gap: 20px;
        padding: 20px;
    }

    /* [FIX] 项目卡片样式 */
    .project-card {
        display: block;
        position: relative;
        background: rgba(60, 30, 5, 0.92);
        border: 1px solid rgba(249, 115, 22, 0.4);
        border-radius: 12px;
        padding: 20px;
        cursor: pointer;
        transition: all 0.3s ease;
    }

    .project-card:hover {
        background: rgba(70, 35, 8, 0.95);
        border-color: rgba(249, 115, 22, 0.7);
        box-shadow: 0 8px 24px rgba(249, 115, 22, 0.25);
        transform: translateY(-4px);
    }

    /* 新建项目加号卡片 - 紧凑布局 */
    .add-project-card {
        display: flex;
        flex-direction: column;
        align-items: center;
        justify-content: center;
        min-height: 100px;
        border: 2px dashed rgba(249, 115, 22, 0.5);
        background: rgba(55, 28, 5, 0.85);
    }

    .add-project-card:hover {
        border-color: rgba(249, 115, 22, 0.8);
        background: rgba(65, 33, 8, 0.92);
    }

    .add-icon {
        color: rgba(249, 115, 22, 0.6);
        transition: all 0.2s ease;
    }

    .add-project-card:hover .add-icon {
        color: rgba(249, 115, 22, 0.9);
        transform: scale(1.05);
    }

    .add-text {
        margin-top: 8px;
        font-size: 12px;
        color: rgba(249, 115, 22, 0.6);
        transition: color 0.2s ease;
    }

    .add-project-card:hover .add-text {
        color: rgba(249, 115, 22, 0.9);
    }

    .project-card-header {
        display: flex;
        align-items: center;
        justify-content: space-between;
        margin-bottom: 12px;
    }

    .project-name {
        font-size: 18px;
        font-weight: 600;
        color: #ffffff;
        margin: 0;
    }

    .project-type {
        padding: 4px 12px;
        border-radius: 6px;
        font-size: 12px;
        font-weight: 500;
    }

    .project-preview {
        color: #a0a0a0;
        font-size: 14px;
        line-height: 1.6;
        margin-bottom: 12px;
        min-height: 44px;
        display: -webkit-box;
        -webkit-line-clamp: 2;
        -webkit-box-orient: vertical;
        overflow: hidden;
    }

    .project-time {
        color: #666;
        font-size: 12px;
    }

    .project-checkbox {
        position: absolute;
        top: 12px;
        left: 12px;
        width: 20px;
        height: 20px;
        border: 2px solid rgba(255, 133, 162, 0.3);
        border-radius: 4px;
        background: rgba(0, 0, 0, 0.5);
        cursor: pointer;
        z-index: 10;
    }

    .project-more {
        position: absolute;
        bottom: 12px;
        right: 12px;
        width: 32px;
        height: 32px;
        border: none;
        background: rgba(255, 255, 255, 0.05);
        border-radius: 6px;
        color: #999;
        font-size: 20px;
        cursor: pointer;
        transition: all 0.2s;
    }

    .project-more:hover {
        background: rgba(255, 133, 162, 0.2);
        color: #FF85A2;
    }

    .project-dropdown {
        display: none;
        position: absolute;
        bottom: 48px;
        right: 12px;
        background: rgba(17, 17, 17, 0.98);
        border: 1px solid rgba(255, 133, 162, 0.2);
        border-radius: 8px;
        box-shadow: 0 8px 24px rgba(0, 0, 0, 0.55);
        z-index: 100;
        min-width: 120px;
    }

    .project-dropdown-item {
        padding: 10px 16px;
        font-size: 14px;
        color: #ffffff;
        cursor: pointer;
        transition: all 0.2s;
    }

    .project-dropdown-item:hover {
        background: rgba(255, 133, 162, 0.15);
    }

    .project-dropdown-item.danger {
        color: #f87171;
    }

    .project-dropdown-item.danger:hover {
        background: rgba(239, 68, 68, 0.2);
    }
    /* 首页标题栏显示版本号 */
    .titlebar-version {
        display: inline !important;
    }

    /* 模态框样式 - 玻璃拟态风格 */
    .modal {
        position:fixed;
        top:0;
        left:0;
        right:0;
        bottom:0;
        z-index:5000;
        display:flex;
        align-items:center;
        justify-content:center;
    }
    .modal-overlay {
        position:absolute;
        top:0;
        left:0;
        right:0;
        bottom:0;
        background:rgba(0,0,0,0.55);
        backdrop-filter: blur(8px);
        -webkit-backdrop-filter: blur(8px);
        z-index:1;
        animation: overlay-fade-in 0.3s ease-out;
    }
    @keyframes overlay-fade-in {
        from { opacity: 0; backdrop-filter: blur(0); }
        to { opacity: 1; backdrop-filter: blur(8px); }
    }
    .modal-content {
        position:relative;
        background: linear-gradient(145deg, #111111 0%, #0a0a0a 100%);
        backdrop-filter: blur(24px);
        -webkit-backdrop-filter: blur(24px);
        border: 1px solid rgba(255, 133, 162, 0.2);
        padding:24px;
        border-radius:16px;
        width:380px;
        max-width:90%;
        box-shadow:
            0 32px 80px rgba(0,0,0,0.5),
            0 0 48px rgba(255, 133, 162, 0.1);
        z-index:2;
        animation: modal-pop-in 0.4s cubic-bezier(0.175, 0.885, 0.32, 1.275);
    }
    .modal-content::before {
        content: '';
        position: absolute;
        top: 0;
        left: 0;
        right: 0;
        height: 1px;
        background: linear-gradient(90deg, transparent, rgba(255, 133, 162, 0.4), transparent);
        border-radius: 16px 16px 0 0;
    }
    @keyframes modal-pop-in {
        0% {
            opacity: 0;
            transform: scale(0.85) translateY(-30px);
        }
        100% {
            opacity: 1;
            transform: scale(1) translateY(0);
        }
    }
    .modal-content h2 {
        margin:0 0 12px 0;
        color:#ffffff;
        font-size: 16px;
        font-weight: 600;
    }
    .feature-card { cursor:pointer; }

    /* 对话输入框样式 */
    .chat-input-section {
        display: flex;
        justify-content: center;
        padding: 40px 20px 20px;
    }

    .chat-input-box {
        width: 100%;
        max-width: 800px;
        background: var(--bg-secondary);
        border: 1px solid var(--border);
        border-radius: 20px;
        padding: 25px;
    }

    .chat-input-area {
        display: flex;
        align-items: flex-start;
        gap: 15px;
    }

    .chat-upload-btn {
        width: 50px;
        height: 50px;
        background: var(--bg-tertiary);
        border: 2px dashed var(--border);
        border-radius: 12px;
        display: flex;
        align-items: center;
        justify-content: center;
        cursor: pointer;
        font-size: 20px;
        color: var(--text-muted);
        transition: all 0.3s;
        flex-shrink: 0;
    }

    .chat-upload-btn:hover {
        border-color: var(--primary);
        color: var(--primary);
    }

    .chat-textarea {
        flex: 1;
        background: transparent;
        border: none;
        color: var(--text);
        font-size: 16px;
        resize: none;
        min-height: 50px;
        max-height: 120px;
        line-height: 1.6;
        padding: 12px 0;
    }

    .chat-textarea:focus {
        outline: none;
    }

    .chat-textarea::placeholder {
        color: var(--text-muted);
    }

    .chat-send-btn {
        width: 50px;
        height: 50px;
        background: linear-gradient(135deg, var(--primary), var(--accent));
        border: none;
        border-radius: 50%;
        display: flex;
        align-items: center;
        justify-content: center;
        cursor: pointer;
        font-size: 20px;
        color: white;
        transition: all 0.3s;
        flex-shrink: 0;
    }

    .chat-send-btn:hover {
        transform: scale(1.1);
        box-shadow: 0 4px 15px rgba(255, 133, 162, 0.4);
    }

    .chat-options {
        display: flex;
        gap: 10px;
        margin-top: 18px;
        justify-content: center;
    }

    .type-switch {
        display: flex;
        background: var(--bg-tertiary);
        border-radius: 10px;
        padding: 4px;
        border: 1px solid var(--border);
    }

    .type-btn {
        padding: 8px 18px;
        border: none;
        background: transparent;
        color: var(--text-secondary);
        font-size: 14px;
        cursor: pointer;
        border-radius: 8px;
        transition: all 0.3s;
    }

    .type-btn.active {
        background: rgba(255, 133, 162, 0.15);
        border: 1px solid var(--primary);
        color: #1a1a1a;
        font-weight: 600;
    }

    /* 创作卡片样式 */
    .feature-cards {
        display: grid;
        grid-template-columns: 1fr;
        gap: 16px;
        padding: 0 30px;
        max-width: 400px;
        margin: 0 auto;
    }

    .feature-cards .feature-card {
        padding: 18px;
        min-height: 110px;
    }

    .feature-cards .card-icon {
        font-size: 22px;
    }

    .feature-cards .card-title {
        font-size: 14px;
    }

    .feature-cards .card-desc {
        font-size: 11px;
    }

    /* 右键菜单样式 */
    .context-menu {
        display: none;
        position: fixed;
        background: rgba(26, 26, 26, 0.98);
        backdrop-filter: blur(16px);
        -webkit-backdrop-filter: blur(16px);
        border: 1px solid rgba(255, 133, 162, 0.25);
        border-radius: 8px;
        padding: 6px 0;
        min-width: 140px;
        box-shadow: 0 8px 32px rgba(0, 0, 0, 0.5);
        z-index: 10000;
    }

    .context-menu.show {
        display: block;
        animation: menu-fade-in 0.15s ease-out;
    }

    @keyframes menu-fade-in {
        from { opacity: 0; transform: scale(0.95); }
        to { opacity: 1; transform: scale(1); }
    }

    .context-menu-item {
        display: flex;
        align-items: center;
        gap: 10px;
        padding: 10px 14px;
        color: #ccc;
        font-size: 13px;
        cursor: pointer;
        transition: all 0.15s;
    }

    .context-menu-item:hover {
        background: rgba(255, 133, 162, 0.15);
        color: #FF85A2;
    }

    .context-menu-item svg {
        flex-shrink: 0;
    }

    /* 搜索浮层样式 */
    .search-panel {
        display: none;
        position: fixed;
        top: 80px;
        left: 50%;
        transform: translateX(-50%);
        background: rgba(26, 26, 26, 0.98);
        backdrop-filter: blur(20px);
        -webkit-backdrop-filter: blur(20px);
        border: 1px solid rgba(255, 133, 162, 0.3);
        border-radius: 12px;
        padding: 4px;
        width: 400px;
        max-width: 90vw;
        box-shadow: 0 12px 40px rgba(0, 0, 0, 0.5);
        z-index: 10001;
    }

    .search-panel.show {
        display: block;
        animation: search-slide-in 0.2s ease-out;
    }

    @keyframes search-slide-in {
        from { opacity: 0; transform: translateX(-50%) translateY(-10px); }
        to { opacity: 1; transform: translateX(-50%) translateY(0); }
    }

    .search-panel-header {
        display: flex;
        align-items: center;
        gap: 10px;
        padding: 10px 14px;
    }

    .search-panel-input {
        flex: 1;
        background: transparent;
        border: none;
        color: #fff;
        font-size: 14px;
        outline: none;
    }

    .search-panel-input::placeholder {
        color: #666;
    }

    .search-panel-close {
        background: none;
        border: none;
        color: #666;
        font-size: 20px;
        cursor: pointer;
        padding: 0 4px;
        line-height: 1;
    }

    .search-panel-close:hover {
        color: #FF85A2;
    }

    .search-box {
        position: relative;
        flex-shrink: 0;
        display: flex;
        align-items: center;
    }

    /* 搜索框备用样式（兼容） */
    .search-input {
        display: none;
    }

    /* 项目列表样式 - 紧凑布局 */
    .projects-section {
        padding: 16px;
        position: relative;
    }

    .project-grid {
        display: grid;
        grid-template-columns: repeat(auto-fill, minmax(200px, 1fr));
        gap: 16px;
    }

    .project-card {
        background: rgba(60, 30, 5, 0.92);
        border-radius: 12px;
        padding: 14px;
        cursor: pointer;
        transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
        border: 1px solid rgba(249, 115, 22, 0.4);
        position: relative;
        box-shadow: 0 2px 12px rgba(0, 0, 0, 0.3);
        overflow: hidden;
        user-select: none;
        -webkit-user-select: none;
    }

    .project-card::before {
        content: '';
        position: absolute;
        top: 0;
        left: 0;
        right: 0;
        height: 1px;
        background: linear-gradient(90deg, transparent, rgba(249, 115, 22, 0.2), transparent);
        pointer-events: none;
    }

    .project-card:hover {
        background: rgba(70, 35, 8, 0.95);
        border-color: rgba(249, 115, 22, 0.7);
        transform: translateY(-3px);
        box-shadow: 0 8px 24px rgba(249, 115, 22, 0.25);
    }

    .project-card:hover::after {
        content: '';
        position: absolute;
        inset: 0;
        background: radial-gradient(circle at 50% 0%, rgba(249, 115, 22, 0.06) 0%, transparent 60%);
        pointer-events: none;
    }

    .project-card-header {
        display: flex;
        justify-content: space-between;
        align-items: flex-start;
        margin-bottom: 8px;
        gap: 8px;
    }

    .project-name {
        font-size: 14px;
        font-weight: 600;
        color: #ffffff;
        margin: 0;
        overflow: hidden;
        text-overflow: ellipsis;
        white-space: nowrap;
        flex: 1;
    }

    .project-type {
        padding: 2px 8px;
        border-radius: 10px;
        font-size: 10px;
        font-weight: 500;
        white-space: nowrap;
        flex-shrink: 0;
    }

    .project-preview {
        color: rgba(255, 255, 255, 0.6);
        font-size: 12px;
        line-height: 1.5;
        margin-bottom: 8px;
        display: -webkit-box;
        -webkit-line-clamp: 2;
        -webkit-box-orient: vertical;
        overflow: hidden;
        min-height: 36px;
    }

    .project-stats {
        display: flex;
        gap: 10px;
        color: rgba(255, 255, 255, 0.4);
        font-size: 11px;
        margin-bottom: 6px;
    }

    .project-time {
        color: rgba(255, 255, 255, 0.35);
        font-size: 10px;
    }

    /* 更多操作按钮 - 紧凑风格 */
    .project-more {
        position: absolute;
        right: 10px;
        bottom: 10px;
        width: 26px;
        height: 26px;
        border-radius: 6px;
        background: rgba(255, 255, 255, 0.08);
        border: 1px solid rgba(255, 255, 255, 0.1);
        color: rgba(255, 255, 255, 0.5);
        font-size: 14px;
        cursor: pointer;
        display: flex;
        align-items: center;
        justify-content: center;
        transition: all 0.2s ease;
    }

    .project-more:hover {
        background: rgba(255, 133, 162, 0.2);
        border-color: rgba(255, 133, 162, 0.4);
        color: #FF85A2;
    }

    .project-dropdown {
        position: absolute;
        right: 0;
        bottom: 36px;
        background: rgba(26, 26, 26, 0.98);
        backdrop-filter: blur(16px);
        -webkit-backdrop-filter: blur(16px);
        border: 1px solid rgba(255, 133, 162, 0.2);
        border-radius: 8px;
        padding: 4px 0;
        min-width: 100px;
        box-shadow: 0 8px 24px rgba(0, 0, 0, 0.4);
        display: none;
        z-index: 100;
    }

    .project-dropdown::before {
        content: '';
        position: absolute;
        top: 0;
        left: 0;
        right: 0;
        height: 1px;
        background: linear-gradient(90deg, transparent, rgba(255, 133, 162, 0.3), transparent);
    }

    .project-dropdown.show {
        display: block;
        animation: dropdown-in 0.15s ease-out;
    }

    @keyframes dropdown-in {
        from {
            opacity: 0;
            transform: translateY(6px);
        }
        to {
            opacity: 1;
            transform: translateY(0);
        }
    }

    .project-dropdown-item {
        padding: 8px 14px;
        color: rgba(255, 255, 255, 0.8);
        font-size: 12px;
        cursor: pointer;
        transition: all 0.15s ease;
    }

    .project-dropdown-item:hover {
        background: rgba(255, 133, 162, 0.15);
        color: #FF85A2;
    }

    .project-dropdown-item.danger {
        color: #f87171;
    }

    .project-dropdown-item.danger:hover {
        background: rgba(248, 113, 113, 0.15);
        color: #fca5a5;
    }

    /* ===== 框选功能样式 ===== */
    /* 框选矩形 */
    #dragSelectRect {
        position: fixed;
        border: 2px solid rgba(255, 133, 162, 0.7);
        background: rgba(255, 133, 162, 0.08);
        pointer-events: none;
        z-index: 9999;
        display: none;
        border-radius: 2px;
        box-shadow: 0 0 12px rgba(255, 133, 162, 0.15);
    }

    /* 卡片选中态 */
    .project-card.drag-selected {
        border-color: rgba(249, 115, 22, 0.6) !important;
        box-shadow: 0 0 0 2px rgba(249, 115, 22, 0.3), 0 4px 24px rgba(0,0,0,0.1) !important;
    }

    .project-card.drag-selected::after {
        content: '';
        position: absolute;
        inset: 0;
        background: rgba(249, 115, 22, 0.06);
        pointer-events: none;
        border-radius: 16px;
    }

    /* 框选拖拽中禁止文字选中 */
    body.drag-selecting,
    body.drag-selecting * {
        user-select: none !important;
        -webkit-user-select: none !important;
    }

    /* 选中勾选标记 */
    .project-card .drag-check {
        position: absolute;
        top: 10px;
        left: 10px;
        width: 22px;
        height: 22px;
        border-radius: 50%;
        background: rgba(249, 115, 22, 0.9);
        display: none;
        align-items: center;
        justify-content: center;
        z-index: 12;
        box-shadow: 0 2px 8px rgba(0,0,0,0.3);
        pointer-events: none;
    }
    .project-card .drag-check svg {
        width: 14px;
        height: 14px;
        stroke: #000;
        stroke-width: 2.5;
        fill: none;
    }
    .project-card.drag-selected .drag-check {
        display: flex;
    }

    /* 批量操作浮动栏 */
    #batchActionBar {
        position: fixed;
        bottom: -80px;
        left: 50%;
        transform: translateX(-50%);
        background: rgba(20, 20, 20, 0.95);
        backdrop-filter: blur(20px);
        -webkit-backdrop-filter: blur(20px);
        border: 1px solid rgba(255, 133, 162, 0.3);
        border-radius: 16px;
        padding: 12px 28px;
        display: flex;
        align-items: center;
        gap: 20px;
        z-index: 10000;
        transition: bottom 0.35s cubic-bezier(0.4, 0, 0.2, 1);
        box-shadow: 0 -4px 30px rgba(0,0,0,0.4);
    }
    #batchActionBar.show {
        bottom: 32px;
    }
    #batchActionBar .batch-info {
        color: rgba(255,255,255,0.85);
        font-size: 14px;
        white-space: nowrap;
    }
    #batchActionBar .batch-info strong {
        color: #FF85A2;
        font-size: 18px;
        margin: 0 2px;
    }
    #batchActionBar .batch-btn {
        padding: 8px 20px;
        border: none;
        border-radius: 8px;
        font-size: 13px;
        font-weight: 500;
        cursor: pointer;
        transition: all 0.2s;
    }
    #batchActionBar .batch-btn.delete {
        background: rgba(239, 68, 68, 0.85);
        color: #fff;
    }
    #batchActionBar .batch-btn.delete:hover {
        background: rgba(239, 68, 68, 1);
        box-shadow: 0 4px 12px rgba(239, 68, 68, 0.4);
    }
    #batchActionBar .batch-btn.cancel {
        background: rgba(255, 255, 255, 0.1);
        color: rgba(255,255,255,0.7);
    }
    #batchActionBar .batch-btn.cancel:hover {
        background: rgba(255, 255, 255, 0.2);
        color: #fff;
    }
    #batchActionBar .batch-btn.select-all {
        background: rgba(255, 133, 162, 0.2);
        color: #FF85A2;
    }
    #batchActionBar .batch-btn.select-all:hover {
        background: rgba(255, 133, 162, 0.35);
    }
    #batchActionBar .batch-btn.open {
        background: linear-gradient(135deg, rgba(255, 133, 162, 0.85), rgba(212, 165, 116, 0.85));
        color: #0a0a0a;
    }
    #batchActionBar .batch-btn.open:hover {
        background: linear-gradient(135deg, #FF85A2, #D4A574);
        box-shadow: 0 4px 12px rgba(255, 133, 162, 0.4);
    }

/* ===== Block 3 ===== */
    /* Agent 卡片样式 - 仅 hover 时高亮 */
    .agent-card:hover {
        background: linear-gradient(135deg, rgba(255, 133, 162, 0.15), rgba(255, 133, 162, 0.1)) !important;
        border-color: rgba(255, 133, 162, 0.5) !important;
        box-shadow: 0 8px 25px rgba(255, 133, 162, 0.25) !important;
    }

    .card-badge.new {
        background: linear-gradient(135deg, #10b981, #059669);
        color: #fff;
    }

/* ===== Block 4 ===== */
        /* 协议弹窗样式 - 橙色边框 */
        .agreement-modal-overlay {
            display: none;
            position: fixed;
            top: 0;
            left: 0;
            width: 100%;
            height: 100%;
            background: rgba(0, 0, 0, 0.7);
            z-index: 10000;
            justify-content: center;
            align-items: center;
        }
        .agreement-modal-overlay.show {
            display: flex;
        }
        .agreement-modal-card {
            width: 1800px;
            max-width: 92vw;
            max-height: 80vh;
            background: rgba(10,10,10,0.95);
            border: 2px solid #ffa500;
            border-radius: 12px;
            display: flex;
            flex-direction: column;
            box-shadow: 0 8px 32px rgba(255, 165, 0, 0.2);
        }
        .agreement-modal-header {
            padding: 16px 24px;
            font-size: 18px;
            font-weight: 600;
            color: #fff;
            text-align: center;
            border-bottom: 1px solid rgba(255, 165, 0, 0.3);
            background: rgba(255, 165, 0, 0.05);
        }
        .agreement-modal-content {
            flex: 1;
            padding: 20px 24px;
            overflow-y: auto;
            color: rgba(255, 255, 255, 0.85);
            font-size: 14px;
            line-height: 1.8;
        }
        .agreement-modal-content h3.agreement-title {
            color: #ffa500;
            font-size: 16px;
            margin-bottom: 16px;
            padding-bottom: 8px;
            border-bottom: 1px solid rgba(255, 165, 0, 0.2);
        }
        .agreement-modal-content h4.agreement-section {
            color: #ffa500;
            font-size: 14px;
            margin: 20px 0 10px 0;
        }
        .agreement-modal-content p {
            margin: 8px 0;
            text-align: justify;
        }
        .agreement-modal-content ul {
            margin: 8px 0;
            padding-left: 20px;
        }
        .agreement-modal-content li {
            margin: 4px 0;
        }
        .agreement-modal-footer {
            padding: 16px 24px;
            text-align: center;
            border-top: 1px solid rgba(255, 165, 0, 0.3);
        }
        .agreement-close-btn {
            padding: 8px 32px;
            background: transparent;
            border: 1px solid rgba(255, 255, 255, 0.3);
            border-radius: 6px;
            color: #fff;
            cursor: pointer;
            transition: all 0.2s ease;
        }
        .agreement-close-btn:hover {
            background: rgba(255, 165, 0, 0.1);
            border-color: #ffa500;
            color: #ffa500;
        }

        /* ===== 全局角色大卡片弹窗样式 ===== */
        #gcModalOverlay {
            display: none;
            position: fixed;
            top: 0; left: 0; right: 0; bottom: 0;
            background: rgba(0, 0, 0, 0.85);
            z-index: 10000;
        }
        #gcModal {
            display: none;
            position: fixed;
            top: 50%; left: 50%;
            transform: translate(-50%, -50%);
            width: 1700px;
            height: 92vh;
            background: rgba(10,10,10,0.95);
            border: 1px solid #333;
            border-radius: 12px;
            z-index: 10001;
            overflow: hidden;
            flex-direction: column;
        }
        .gc-modal-header {
            display: flex;
            justify-content: space-between;
            align-items: center;
            padding: 14px 20px;
            border-bottom: 1px solid #333;
        }
        .gc-modal-header h3 {
            color: #FF85A2;
            font-size: 16px;
            margin: 0;
        }
        .gc-modal-close {
            background: none;
            border: none;
            color: #888;
            font-size: 22px;
            cursor: pointer;
            padding: 0 4px;
        }
        .gc-modal-close:hover { color: #fff; }
        .gc-modal-body {
            display: flex;
            flex: 1;
            min-height: 0;
            overflow-y: auto;
        }
        .gc-left {
            flex: 0 0 450px;
            padding: 20px;
            border-right: 1px solid #333;
            overflow-y: auto;
        }
        .gc-right {
            flex: 1;
            padding: 20px;
            overflow-y: auto;
        }
        .gc-gen-dual { display: flex; gap: 20px; }
        .gc-gen-dual > div { flex: 1; min-width: 0; }
        .gc-preview-img {
            width: 100%;
            aspect-ratio: var(--gc-preview-ratio, 3/4);
            border-radius: 6px;
            overflow: hidden;
            background: rgba(0,0,0,0.78);
            margin-bottom: 10px;
            display: flex;
            align-items: flex-start;
            justify-content: center;
            cursor: pointer;
        }
        .gc-preview-img img {
            width: 100%;
            height: 100%;
            object-fit: cover;
            object-position: top;
        }
        .gc-form-label {
            display: block;
            font-size: 11px;
            color: #888;
            margin-bottom: 4px;
        }
        .gc-form-input {
            width: 100%;
            padding: 8px 10px;
            background: #111;
            border: 1px solid #333;
            border-radius: 6px;
            color: #fff;
            font-size: 13px;
            outline: none;
            box-sizing: border-box;
        }
        .gc-form-input:focus { border-color: #FF85A2; }
        .gc-form-select {
            width: 100%;
            padding: 8px 10px;
            background: #111;
            border: 1px solid #333;
            border-radius: 6px;
            color: #ddd;
            font-size: 12px;
            outline: none;
            box-sizing: border-box;
        }
        .gc-form-select:focus { border-color: #FF85A2; }
        .gc-form-row {
            display: flex;
            gap: 10px;
            margin-bottom: 12px;
        }
        .gc-form-row > div { flex: 1; }
        .gc-form-group { margin-bottom: 14px; }
        .gc-prompt-area {
            width: 100%;
            min-height: 100px;
            padding: 10px;
            background: #111;
            border: 1px solid #333;
            border-radius: 6px;
            color: #ddd;
            font-size: 12px;
            resize: vertical;
            box-sizing: border-box;
        }
        .gc-prompt-area:focus { border-color: #FF85A2; outline: none; }
        .gc-prompt-counter {
            text-align: right;
            font-size: 10px;
            color: #666;
            margin-top: 4px;
        }
        .gc-gen-btn {
            width: 100%;
            padding: 10px;
            background: linear-gradient(135deg, #FF85A2, #D4A574);
            border: none;
            border-radius: 8px;
            color: #0a0a0a;
            font-size: 13px;
            font-weight: 600;
            cursor: pointer;
            margin-top: 8px;
        }
        .gc-gen-btn:hover { opacity: 0.9; }
        .gc-gen-btn:disabled {
            background: #333;
            color: #666;
            cursor: not-allowed;
        }
        .gc-history-section {
            margin-top: 20px;
            padding-top: 16px;
            border-top: 1px solid #333;
        }
        .gc-history-grid {
            display: flex;
            flex-wrap: wrap;
            gap: 10px;
            margin-top: 10px;
        }
        .gc-history-item {
            aspect-ratio: 3/4;
            border-radius: 6px;
            overflow: hidden;
            background: #111;
            border: 2px solid transparent;
            cursor: pointer;
            transition: all 0.2s;
        }
        .gc-history-item:hover { border-color: rgba(255,133,162,0.5); transform: scale(1.03); }
        .gc-history-item.active { border-color: #FF85A2; }
        .gc-history-item img { width: 100%; height: 100%; object-fit: contain; }
        .gc-modal-footer {
            padding: 12px 20px;
            border-top: 1px solid #333;
            display: flex;
            justify-content: space-between;
            align-items: center;
        }
        .gc-btn-delete {
            padding: 8px 16px;
            font-size: 12px;
            background: transparent;
            border: 1px solid #f44336;
            border-radius: 6px;
            color: #f44336;
            cursor: pointer;
        }
        .gc-btn-delete:hover { background: rgba(244,67,54,0.1); }
        .gc-footer-right { display: flex; gap: 10px; }
        .gc-btn-cancel {
            padding: 8px 20px;
            font-size: 12px;
            background: #333;
            border: 1px solid #444;
            border-radius: 6px;
            color: #ccc;
            cursor: pointer;
        }
        .gc-btn-cancel:hover { background: #444; color: #fff; }
        .gc-btn-save {
            padding: 8px 20px;
            font-size: 12px;
            font-weight: 600;
            background: linear-gradient(135deg, #FF85A2, #D4A574);
            border: none;
            border-radius: 6px;
            color: #0a0a0a;
            cursor: pointer;
        }
        .gc-btn-save:hover { opacity: 0.9; }
        .gc-model-selector {
            position: relative;
        }
        .gc-model-display {
            padding: 8px 10px;
            background: #111;
            border: 1px solid #333;
            border-radius: 6px;
            color: #ddd;
            font-size: 12px;
            cursor: pointer;
            display: flex;
            justify-content: space-between;
            align-items: center;
        }
        .gc-model-display:hover { border-color: #555; }
        .gc-model-dropdown {
            display: none;
            position: fixed;
            margin-top: 2px;
            background: rgba(10,10,10,0.95);
            border: 1px solid #444;
            border-radius: 6px;
            z-index: 10000;
            overflow-y: auto;
            max-height: 320px;
            box-shadow: 0 4px 12px rgba(0,0,0,0.5);
        }
        .gc-model-option {
            padding: 10px 12px;
            color: #ccc;
            font-size: 12px;
            cursor: pointer;
            transition: background 0.15s;
            display: flex;
            align-items: center;
            min-height: 44px;
        }
        .gc-model-option:hover { background: rgba(255,133,162,0.15); color: #FF85A2; }
        .gc-model-option.selected { background: rgba(255,133,162,0.1); color: #FF85A2; }
        .gc-model-icon { width: 30px; height: 30px; border-radius: 5px; margin-right: 8px; object-fit: cover; flex-shrink: 0; }
        .gc-model-label { flex: 1; }
        .gc-model-price { font-size: 10px; color: #FF85A2; margin-left: 6px; white-space: nowrap; flex-shrink: 0; }

        /* WC 资产库模型下拉框样式 */
        .wc-model-selector {
            position: relative;
        }
        .wc-model-display {
            padding: 8px 10px;
            background: #111;
            border: 1px solid #333;
            border-radius: 6px;
            color: #ddd;
            font-size: 12px;
            cursor: pointer;
            display: flex;
            justify-content: space-between;
            align-items: center;
        }
        .wc-model-display:hover { border-color: #555; }
        .wc-model-dropdown {
            display: none;
            position: fixed;
            margin-top: 2px;
            background: rgba(10,10,10,0.95);
            border: 1px solid #444;
            border-radius: 6px;
            z-index: 10000;
            overflow-y: auto;
            max-height: 320px;
            box-shadow: 0 4px 12px rgba(0,0,0,0.5);
        }
        .wc-model-option {
            padding: 10px 12px;
            color: #ccc;
            font-size: 12px;
            cursor: pointer;
            transition: background 0.15s;
            display: flex;
            align-items: center;
            min-height: 44px;
        }
        .wc-model-option:hover { background: rgba(255,133,162,0.15); color: #FF85A2; }
        .wc-model-option.selected { background: rgba(255,133,162,0.1); color: #FF85A2; }
        .wc-model-icon { width: 30px; height: 30px; border-radius: 5px; margin-right: 8px; object-fit: cover; flex-shrink: 0; }
        .wc-model-label { flex: 1; }
        .wc-model-price { font-size: 10px; color: #FF85A2; margin-left: 6px; white-space: nowrap; flex-shrink: 0; }

/* ===== Block 5 ===== */
    /* 设置页面 - 黑金配色，充分利用空间 */
    .settings-page-wrapper {
        padding: 24px 32px 40px;
    }
    .settings-page-header {
        margin-bottom: 20px;
    }
    .settings-page-title {
        font-size: 18px;
        font-weight: 700;
        color: #FF85A2;
        display: flex;
        align-items: center;
        gap: 8px;
    }
    .settings-page-subtitle {
        font-size: 12px;
        color: rgba(255,255,255,0.35);
        margin-top: 4px;
    }
    /* 顶部标签栏 */
    .settings-tabs {
        display: flex;
        gap: 2px;
        margin-bottom: 20px;
        border-bottom: 1px solid rgba(255,133,162,0.12);
    }
    .settings-tab {
        display: flex;
        align-items: center;
        gap: 6px;
        padding: 10px 18px;
        border: none;
        background: transparent;
        color: rgba(255,255,255,0.45);
        font-size: 13px;
        cursor: pointer;
        transition: all 0.2s;
        border-bottom: 2px solid transparent;
        margin-bottom: -1px;
    }
    .settings-tab:hover {
        color: #FF85A2;
    }
    .settings-tab.active {
        color: #FF85A2;
        border-bottom-color: #FF85A2;
    }
    /* 内容区域 */
    .settings-content-area {
        width: 100%;
    }
    /* 滑块样式 */
    input[type="range"] {
        -webkit-appearance: none;
        appearance: none;
        height: 4px;
        background: linear-gradient(90deg, rgba(255,133,162,0.35), rgba(139,92,246,0.35));
        border-radius: 4px;
        outline: none;
    }
    input[type="range"]::-webkit-slider-thumb {
        -webkit-appearance: none;
        width: 16px;
        height: 16px;
        border-radius: 50%;
        background: linear-gradient(135deg, #FF85A2, #a78bfa);
        cursor: pointer;
        box-shadow: 0 0 6px rgba(255,133,162,0.4);
        transition: box-shadow 0.2s;
        margin-top: -6px;
    }
    input[type="range"]::-webkit-slider-thumb:hover {
        box-shadow: 0 0 12px rgba(255,133,162,0.6);
    }
    input[type="range"]::-moz-range-thumb {
        width: 16px;
        height: 16px;
        border-radius: 50%;
        background: linear-gradient(135deg, #FF85A2, #a78bfa);
        cursor: pointer;
        border: none;
        box-shadow: 0 0 6px rgba(255,133,162,0.4);
    }
    /* 隐藏 number 输入框上下箭头 */
    input[type="number"]::-webkit-inner-spin-button,
    input[type="number"]::-webkit-outer-spin-button {
        -webkit-appearance: none;
        margin: 0;
    }
    input[type="number"] {
        -moz-appearance: textfield;
    }
    .settings-section {
        display: none;
    }
    .settings-section.active {
        display: block;
    }
    .settings-section-desc {
        font-size: 12px;
        color: rgba(255,255,255,0.35);
        line-height: 1.6;
    }
    /* API密钥卡片 - 手风琴单列 */
    #settingsApiKeysContainer {
        display: flex;
        flex-direction: column;
        gap: 2px;
    }
    .settings-card {
        background: rgba(0, 0, 0, 0.55);
        backdrop-filter: blur(20px);
        -webkit-backdrop-filter: blur(20px);
        border: 1px solid rgba(255,133,162,0.12);
        border-radius: 10px;
        padding: 0;
        transition: border-color 0.2s;
        overflow: hidden;
    }
    .settings-card:hover {
        border-color: rgba(255,133,162,0.25);
    }
    .settings-card-title {
        font-size: 13px;
        font-weight: 600;
        color: #FF85A2;
        padding: 12px 16px;
        cursor: pointer;
        display: flex;
        align-items: center;
        justify-content: space-between;
        user-select: none;
        transition: background 0.15s;
        margin: 0;
    }
    .settings-card-title:hover {
        background: rgba(255,133,162,0.06);
    }
    .settings-platform-link {
        color: rgba(255,133,162,0.5);
        text-decoration: none;
        font-size: 12px;
        margin-left: 4px;
        transition: color 0.2s;
        display: inline-block;
    }
    .settings-platform-link:hover {
        color: #FF85A2;
    }
    .settings-card-title::after {
        content: '';
        width: 6px; height: 6px;
        border-right: 1.5px solid rgba(255,133,162,0.5);
        border-bottom: 1.5px solid rgba(255,133,162,0.5);
        transform: rotate(45deg);
        transition: transform 0.2s;
        flex-shrink: 0;
    }
    .settings-card.expanded .settings-card-title::after {
        transform: rotate(-135deg);
    }
    .settings-card-body {
        max-height: 0;
        overflow: hidden;
        transition: max-height 0.25s ease;
        padding: 0 16px;
    }
    .settings-card.expanded .settings-card-body {
        max-height: 1200px;
        padding: 0 16px 14px;
    }
    .settings-card-field {
        display: flex;
        align-items: center;
        gap: 10px;
        margin-bottom: 8px;
    }
    .settings-card-field:last-child {
        margin-bottom: 0;
    }
    /* ComfyUI 多链接字段：垂直布局 */
    #softwareSettingsComfyui .settings-card-field {
        flex-direction: column;
        align-items: stretch;
    }
    #softwareSettingsComfyui .settings-card-field label {
        flex: none;
        text-align: left;
        margin-bottom: 4px;
        color: #60a5fa;
    }
    .settings-card-field label {
        font-size: 11px;
        color: rgba(255,255,255,0.4);
        flex: 0 0 120px;
        text-align: right;
    }
    .settings-input {
        flex: 1;
        padding: 7px 10px;
        font-size: 12px;
        border: 1px solid rgba(255,133,162,0.12);
        border-radius: 6px;
        background: rgba(0,0,0,0.2);
        color: rgba(255,255,255,0.85);
        transition: border-color 0.2s, box-shadow 0.2s;
    }
    .settings-input:focus {
        outline: none;
        border-color: rgba(255,133,162,0.45);
        box-shadow: 0 0 0 2px rgba(255,133,162,0.08);
    }
    .settings-input::placeholder {
        color: rgba(255,255,255,0.2);
    }
    .settings-save-btn {
        padding: 9px 22px;
        font-size: 13px;
        font-weight: 500;
        border: none;
        border-radius: 8px;
        background: linear-gradient(135deg, #FF85A2, #D4A574);
        color: #0a0a0a;
        cursor: pointer;
        transition: all 0.2s;
        box-shadow: 0 2px 8px rgba(255,133,162,0.2);
    }
    .settings-save-btn:hover {
        background: linear-gradient(135deg, #e6c84a, #FF85A2);
        box-shadow: 0 4px 16px rgba(255,133,162,0.3);
        transform: translateY(-1px);
    }
    @media (max-width: 900px) {
        #settingsApiKeysContainer {
            grid-template-columns: 1fr;
        }
    }

/* ===== Block 6 ===== */
    .account-modal-overlay {
        display: none;
        position: fixed;
        top: 0; left: 0; right: 0; bottom: 0;
        background: rgba(0,0,0,0.65);
        z-index: 100000;
        align-items: center;
        justify-content: center;
    }
    .account-modal-overlay.show {
        display: flex;
    }
    .account-modal {
        background: #111;
        border: 1px solid rgba(255,133,162,0.2);
        border-radius: 16px;
        width: 420px;
        max-width: 92vw;
        max-height: 80vh;
        overflow-y: auto;
        box-shadow: 0 20px 60px rgba(0,0,0,0.55);
        padding: 28px 28px 20px;
        position: relative;
    }
    .account-modal::-webkit-scrollbar { width: 5px; }
    .account-modal::-webkit-scrollbar-track { background: transparent; }
    .account-modal::-webkit-scrollbar-thumb { background: rgba(255,133,162,0.3); border-radius: 3px; }
    .account-modal-header {
        display: flex;
        align-items: center;
        justify-content: space-between;
        margin-bottom: 20px;
    }
    .account-modal-title {
        font-size: 18px;
        font-weight: 700;
        background: linear-gradient(135deg, #FF85A2, #FFB0C4);
        -webkit-background-clip: text;
        -webkit-text-fill-color: transparent;
        background-clip: text;
    }
    .account-modal-close {
        width: 28px; height: 28px;
        background: rgba(255,255,255,0.06);
        border: 1px solid rgba(255,133,162,0.12);
        border-radius: 6px;
        color: #888;
        font-size: 16px;
        cursor: pointer;
        display: flex;
        align-items: center;
        justify-content: center;
        transition: all 0.2s;
    }
    .account-modal-close:hover {
        background: rgba(255,133,162,0.12);
        color: #FF85A2;
        border-color: rgba(255,133,162,0.3);
    }
    .account-info-row {
        display: flex;
        align-items: center;
        justify-content: space-between;
        padding: 12px 14px;
        background: rgba(10,10,10,0.95);
        border: 1px solid rgba(255,133,162,0.08);
        border-radius: 8px;
        margin-bottom: 8px;
    }
    .account-info-label {
        font-size: 13px;
        color: #a0a0a0;
        min-width: 65px;
    }
    .account-info-value {
        font-size: 13px;
        color: #e0e0e0;
        flex: 1;
        text-align: right;
        margin: 0 10px;
    }
    .account-info-value.unset {
        color: #555;
    }
    .account-bind-btn {
        padding: 5px 12px;
        background: linear-gradient(135deg, #FF85A2, #D4A574);
        border: none;
        border-radius: 5px;
        color: #0a0a0a;
        font-size: 12px;
        font-weight: 600;
        cursor: pointer;
        white-space: nowrap;
        transition: all 0.2s;
    }
    .account-bind-btn:hover {
        background: linear-gradient(135deg, #FFB0C4, #FF85A2);
    }
    .account-bind-btn.bound {
        background: rgba(80,200,120,0.08);
        color: #50C878;
        border: 1px solid rgba(80,200,120,0.2);
        cursor: default;
    }
    .account-section-title {
        font-size: 12px;
        color: #FF85A2;
        font-weight: 600;
        margin: 16px 0 8px;
        padding-bottom: 6px;
        border-bottom: 1px solid rgba(255,133,162,0.08);
        text-transform: uppercase;
        letter-spacing: 1px;
    }
    /* 绑定表单区域 */
    .bind-form-area {
        display: none;
        margin: -4px 0 8px;
        padding: 14px;
        background: rgba(5,5,5,0.68);
        border: 1px solid rgba(255,133,162,0.1);
        border-radius: 8px;
    }
    .bind-form-area.show { display: block; }
    .bind-form-area .form-group { margin-bottom: 10px; }
    .bind-form-area .form-label { display: block; font-size: 12px; color: #a0a0a0; margin-bottom: 5px; }
    .bind-form-area .form-input {
        width: 100%; padding: 9px 12px; background: rgba(10,10,10,0.95);
        border: 1px solid rgba(255,133,162,0.15); border-radius: 6px;
        color: #fff; font-size: 13px; outline: none; box-sizing: border-box;
    }
    .bind-form-area .form-input:focus { border-color: #FF85A2; box-shadow: 0 0 0 2px rgba(255,133,162,0.15); }
    .bind-form-area .code-row { display: flex; gap: 8px; }
    .bind-form-area .code-row .form-input { flex: 1; }
    .bind-form-area .btn-send-code {
        padding: 9px 14px; background: linear-gradient(135deg, #FF85A2, #D4A574);
        border: none; border-radius: 6px; color: #0a0a0a; font-size: 12px;
        font-weight: 600; cursor: pointer; white-space: nowrap;
    }
    .bind-form-area .btn-send-code:disabled { background: #333; color: #666; cursor: not-allowed; }
    .bind-form-area .btn-submit {
        width: 100%; padding: 9px; background: linear-gradient(135deg, #FF85A2, #D4A574);
        border: none; border-radius: 6px; color: #0a0a0a; font-size: 13px;
        font-weight: 600; cursor: pointer; margin-top: 6px;
    }
    .bind-form-area .btn-submit:disabled { opacity: 0.5; cursor: not-allowed; }
    .bind-form-area .bind-msg {
        font-size: 12px; margin-top: 6px; text-align: center;
    }
    .bind-form-area .bind-msg.success { color: #50C878; }
    .bind-form-area .bind-msg.error { color: #DC3545; }


/* ===== 全局场景编辑弹窗 #scModal ===== */
#scModalOverlay {
    display: none;
    position: fixed;
    top: 0; left: 0; right: 0; bottom: 0;
    background: rgba(0, 0, 0, 0.85);
    z-index: 5000;
}
#scModal {
    display: none;
    position: fixed;
    top: 50%; left: 50%;
    transform: translate(-50%, -50%);
    width: 1700px;
    max-width: 96vw;
    height: 92vh;
    background: rgba(10,10,10,0.95);
    border: 1px solid #333;
    border-radius: 12px;
    z-index: 5001;
    overflow: hidden;
    flex-direction: column;
}

/* 场景预览图 21:9 宽屏比例 */
#scModal .gc-preview-img {
    aspect-ratio: 21/9;
    align-items: center;
}

/* 场景历史项 16:9 比例 */
#scModal .gc-history-item {
    aspect-ratio: 16/9;
}

/* 场景编辑字段 */
.sc-edit-field {
    display: flex;
    flex-direction: column;
    gap: 4px;
    margin-bottom: 12px;
}
.sc-edit-field label {
    display: block;
    font-size: 11px;
    color: #888;
    font-weight: 500;
    margin-bottom: 4px;
}
.sc-edit-field input,
.sc-edit-field textarea {
    width: 100%;
    padding: 8px 10px;
    background: #111;
    border: 1px solid #333;
    border-radius: 6px;
    color: #fff;
    font-size: 13px;
    font-family: inherit;
    box-sizing: border-box;
    outline: none;
    transition: border-color 0.2s;
}
.sc-edit-field input:focus,
.sc-edit-field textarea:focus {
    border-color: #FF85A2;
}
.sc-edit-field input::placeholder,
.sc-edit-field textarea::placeholder {
    color: rgba(255, 255, 255, 0.2);
}
.sc-edit-field textarea {
    min-height: 80px;
    resize: vertical;
    line-height: 1.5;
}

/* 全景/辅助按钮 */
.sc-btn-secondary {
    background: rgba(255,255,255,0.06);
    border: 1px solid #444;
    border-radius: 6px;
    color: #aaa;
    cursor: pointer;
    transition: all 0.2s;
}
.sc-btn-secondary:hover:not(:disabled) {
    border-color: #FF85A2;
    color: #FF85A2;
}

/* 提示词区域头部 + AI优化按钮 */
.sc-desc-header {
    display: flex;
    align-items: center;
    justify-content: space-between;
    margin-bottom: 6px;
}
.sc-btn-ai {
    display: inline-flex;
    align-items: center;
    gap: 4px;
    background: linear-gradient(135deg, rgba(255,133,162,0.15), rgba(212,165,116,0.15));
    border: 1px solid rgba(255,133,162,0.3);
    border-radius: 6px;
    color: #FF85A2;
    padding: 4px 10px;
    font-size: 12px;
    cursor: pointer;
    transition: all 0.2s;
}
.sc-btn-ai:hover {
    background: linear-gradient(135deg, rgba(255,133,162,0.25), rgba(212,165,116,0.25));
    border-color: #FF85A2;
}

/* 出场角色只读标签 */
.sc-chars-display {
    display: flex;
    flex-wrap: wrap;
    gap: 6px;
    margin-top: 4px;
}
.sc-char-chip {
    font-size: 10px;
    padding: 3px 8px;
    border-radius: 4px;
    background: rgba(255,133,162,0.08);
    color: rgba(255,255,255,0.6);
}

