        :root {
            --bg-primary: #0f0f0f;
            --bg-secondary: #1a1a1a;
            --bg-tertiary: #242424;
            --bg-hover: #2a2a2a;
            --border-color: #333;
            --text-primary: #f0f0f0;
            --text-secondary: #a0a0a0;
            --text-muted: #666;
            --accent: #6366f1;
            --accent-hover: #818cf8;
            --accent-glow: rgba(99, 102, 241, 0.3);
            --success: #22c55e;
            --warning: #f59e0b;
        }

        * {
            box-sizing: border-box;
        }

        /* GeoGebra 鍔犺浇鎻愮ず鏍峰紡 */
        .ggb-loading-overlay {
            position: absolute;
            top: 0;
            left: 0;
            right: 0;
            bottom: 0;
            background: var(--bg-tertiary);
            display: flex;
            align-items: center;
            justify-content: center;
            z-index: 10;
            transition: opacity 0.3s ease;
        }

        .ggb-loading-overlay.hidden {
            opacity: 0;
            pointer-events: none;
        }

        .ggb-loading-content {
            text-align: center;
            color: var(--text-secondary);
        }

        .ggb-loading-spinner {
            width: 48px;
            height: 48px;
            border: 3px solid var(--border-color);
            border-top-color: var(--accent);
            border-radius: 50%;
            animation: ggb-spin 1s linear infinite;
            margin: 0 auto 16px;
        }

        @keyframes ggb-spin {
            to {
                transform: rotate(360deg);
            }
        }

        .ggb-loading-content p {
            margin: 0 0 8px;
            font-size: 16px;
            color: var(--text-primary);
        }

        .ggb-loading-hint {
            font-size: 13px;
            color: var(--text-muted);
        }

        html,
        body {
            margin: 0;
            height: 100%;
            overflow: hidden;
            background: var(--bg-primary);
            color: var(--text-primary);
            font-family: -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, sans-serif;
        }

        .navbar {
            background: var(--bg-secondary) !important;
            border-bottom: 1px solid var(--border-color);
        }

        .navbar .nav-link {
            color: var(--text-secondary) !important;
        }

        .navbar .nav-link:hover,
        .navbar .nav-link.active {
            color: var(--text-primary) !important;
        }

        .navbar .nav-link.active {
            background: rgba(59, 130, 246, 0.3);
            box-shadow: none;
        }

        .navbar .nav-link.active::after {
            background: #60a5fa;
        }

        .navbar .nav-menu > li.nav-group-start::before {
            background: transparent;
            border-left-color: #94a3b8;
            opacity: 1;
        }

        .navbar .nav-logo span {
            color: var(--text-primary) !important;
        }

        /* 涓诲竷灞€ */
        .ai-container {
            --ai-ggb-control-width: clamp(360px, 34vw, 460px);
            position: fixed;
            top: var(--site-nav-height, 60px);
            right: 0;
            bottom: 0;
            left: 0;
            display: flex;
            width: auto;
            height: auto;
            margin-top: 0;
            overflow: hidden;
            overscroll-behavior: contain;
        }

        /* 瀵艰埅鏍忓湪 鈮?000px 鏃堕珮搴﹀彉涓?0px锛屽悓姝ヨ皟鏁?*/
        @media (max-width: 1000px) {
            .ai-container {
                top: var(--site-nav-height, 60px);
            }
        }

        /* 宸︿晶鎺у埗闈㈡澘锛氶殢椤甸潰瀹藉害鑷€傚簲锛岄伩鍏嶅璇濊緭鍏ュ尯鍥哄畾姝?*/
        .control-panel {
            flex: 0 0 var(--ai-ggb-control-width);
            width: var(--ai-ggb-control-width);
            min-width: 360px;
            max-width: 460px;
            background: var(--bg-secondary);
            border-right: 1px solid var(--border-color);
            display: flex;
            flex-direction: column;
            overflow: hidden;
            position: relative;
        }

        /* 澶撮儴绉垎鏄剧ず */
        .header-credits {
            display: flex;
            align-items: center;
            gap: 6px;
            min-height: 0;
            height: auto;
            padding: 3px 10px;
            background: linear-gradient(135deg, rgba(34, 197, 94, 0.15) 0%, rgba(16, 185, 129, 0.15) 100%);
            border: 1px solid rgba(34, 197, 94, 0.3);
            border-radius: 16px;
            font-size: 13px;
            white-space: nowrap;
            flex-shrink: 0;
            box-sizing: border-box;
        }

        .header-credits i {
            color: var(--success);
            font-size: 13px;
        }

        /* 璐拱鎸夐挳 - 姗欒壊 */
        .ggb-action-btn.buy-btn {
            background: linear-gradient(135deg, #f59e0b 0%, #d97706 100%);
            border-color: #f59e0b;
            color: white;
            font-weight: 700;
        }

        .ggb-action-btn.buy-btn:hover {
            background: linear-gradient(135deg, #d97706 0%, #b45309 100%);
            transform: translateY(-1px);
            box-shadow: 0 2px 8px rgba(245, 158, 11, 0.4);
        }


        /* 涓嬭浇鎸夐挳 - 鐏拌壊 */
        .ggb-action-btn.download-btn {
            background: linear-gradient(135deg, #64748b 0%, #475569 100%);
            border-color: #64748b;
            color: white;
            font-weight: 700;
        }

        .ggb-action-btn.download-btn:hover {
            background: linear-gradient(135deg, #475569 0%, #334155 100%);
            transform: translateY(-1px);
            box-shadow: 0 2px 8px rgba(100, 116, 139, 0.4);
        }

        /* 淇濆瓨鎸夐挳闂儊鎻愮ず锛堟墽琛屽畬姣曞悗婵€娲伙級 */
        .ggb-action-btn.download-btn.save-hint {
            background: linear-gradient(135deg, #22c55e 0%, #16a34a 100%) !important;
            border-color: #22c55e !important;
            color: white !important;
            animation: saveBtnPulse 1s ease-in-out infinite;
        }

        @keyframes saveBtnPulse {
            0%, 100% {
                box-shadow: 0 0 0 0 rgba(34, 197, 94, 0.6);
                transform: scale(1);
            }
            50% {
                box-shadow: 0 0 18px 6px rgba(34, 197, 94, 0.5);
                transform: scale(1.06);
            }
        }

        .header-credits .credits-value {
            color: var(--success);
            font-weight: 700;
        }

        .header-credits.low-credits {
            background: linear-gradient(135deg, rgba(245, 158, 11, 0.15) 0%, rgba(234, 88, 12, 0.15) 100%);
            border-color: rgba(245, 158, 11, 0.3);
        }

        .header-credits.low-credits i,
        .header-credits.low-credits .credits-value {
            color: var(--warning);
        }

        /* 浜戠瀛樺偍鏄剧ず */
        .header-storage {
            display: flex;
            align-items: center;
            gap: 6px;
            min-height: 0;
            height: auto;
            padding: 3px 10px;
            background: linear-gradient(135deg, #3b82f6 0%, #2563eb 100%);
            border: 1px solid #3b82f6;
            border-radius: 16px;
            color: #fff;
            font-size: 13px;
            font-weight: 700;
            white-space: nowrap;
            cursor: pointer;
            flex-shrink: 0;
            box-sizing: border-box;
            text-decoration: none;
            transition: all 0.2s ease;
        }

        .header-storage:hover {
            background: linear-gradient(135deg, #2563eb 0%, #1d4ed8 100%);
            border-color: #2563eb;
            transform: translateY(-1px);
            box-shadow: 0 2px 8px rgba(59, 130, 246, 0.3);
        }

        .header-storage i {
            color: #fff;
            font-size: 13px;
        }

        .header-storage .storage-label {
            color: #fff;
        }

        .header-storage .storage-value {
            color: #fff;
            font-weight: 700;
        }

        .header-storage.storage-warning {
            background: linear-gradient(135deg, #f59e0b 0%, #d97706 100%);
            border-color: #f59e0b;
        }

        .header-storage.storage-warning i,
        .header-storage.storage-warning .storage-label,
        .header-storage.storage-warning .storage-value {
            color: #fff;
        }

        .header-storage.storage-full {
            background: linear-gradient(135deg, #ef4444 0%, #dc2626 100%);
            border-color: #ef4444;
        }

        .header-storage.storage-full i,
        .header-storage.storage-full .storage-label,
        .header-storage.storage-full .storage-value {
            color: #fff;
        }

        .header-courseware-manage-hint {
            display: inline-flex;
            align-items: center;
            gap: 5px;
            padding: 2px 0;
            color: #93c5fd;
            font-size: 12px;
            font-weight: 600;
            line-height: 1;
            white-space: nowrap;
            text-decoration: none;
            flex-shrink: 0;
            transition: color 0.2s ease, transform 0.2s ease;
        }

        .header-courseware-manage-hint:hover {
            color: #dbeafe;
            transform: translateX(2px);
        }

        .header-courseware-manage-hint:focus-visible {
            color: #fff;
            outline: 2px solid #60a5fa;
            outline-offset: 3px;
            border-radius: 3px;
        }

        .header-courseware-manage-hint i {
            font-size: 11px;
        }

        /* 澶撮儴鍙充晶瀹瑰櫒 */
        .upload-input {
            display: none;
        }

        /* 鍙充晶GGB灞曠ず鍖?*/
        .ggb-panel {
            flex: 1;
            min-width: 0;
            display: flex;
            flex-direction: column;
            background: #fff;
            overflow: hidden;
            min-height: 0;
            /* 鍏佽flex瀛愬厓绱犳敹缂?*/
            border-radius: 0 !important;
        }

        .ggb-header {
            min-height: 39px;
            padding: 3px 12px;
            border-bottom: 1px solid var(--border-color);
            display: flex;
            align-items: center;
            justify-content: space-between;
            background: var(--bg-tertiary);
            flex-shrink: 0;
            position: relative;
            z-index: 10;
            flex-wrap: nowrap;
            gap: 8px;
            box-sizing: border-box;
            overflow: hidden;
        }

        .ggb-title-section {
            display: flex;
            align-items: center;
            gap: 20px;
            flex-shrink: 0;
            /* 闃叉琚帇缂?*/
        }

        .ggb-main-title {
            display: flex;
            align-items: center;
            gap: 10px;
            font-size: 18px;
            font-weight: 600;
            margin: 0;
            color: var(--text-primary);
            white-space: nowrap;
            /* 闃叉鏂囧瓧鎹㈣ */
            flex-shrink: 0;
            /* 闃叉琚帇缂?*/
        }

        .ggb-main-title i {
            color: var(--accent);
            font-size: 20px;
        }

        .contact-btn {
            font-size: 13px;
            font-weight: 600;
            color: white;
            display: flex;
            align-items: center;
            justify-content: center;
            gap: 5px;
            min-height: 0;
            height: auto;
            padding: 3px 10px;
            background: linear-gradient(135deg, #07c160 0%, #06ad56 100%);
            border: 1px solid transparent;
            border-radius: 16px;
            cursor: pointer;
            transition: all 0.2s ease;
            white-space: nowrap;
            flex-shrink: 0;
            box-sizing: border-box;
        }

        .contact-btn:hover {
            transform: translateY(-1px);
            box-shadow: 0 4px 12px rgba(7, 193, 96, 0.4);
        }

        .contact-btn i {
            font-size: 13px;
        }

        /* AI浣滃搧灞曠ず鎸夐挳 - 姗欒壊涓婚 */
        .contact-btn.plaza-btn {
            background: linear-gradient(135deg, #F59E0B 0%, #EA580C 100%);
            position: relative;
        }

        .contact-btn.plaza-btn:hover {
            box-shadow: 0 4px 16px rgba(245, 158, 11, 0.5);
        }

        /* 浣滃搧鏁伴噺寰界珷 */
        .plaza-count-badge {
            display: none;
            min-width: 16px;
            height: 16px;
            line-height: 16px;
            padding: 0 4px;
            background: #fff;
            color: #EA580C;
            border-radius: 10px;
            font-size: 10px;
            font-weight: 700;
            text-align: center;
            margin-left: 2px;
        }

        .plaza-count-badge.show {
            display: inline-block;
            animation: badgePop 0.3s ease;
        }

        @keyframes badgePop {
            0% {
                transform: scale(0);
            }

            60% {
                transform: scale(1.2);
            }

            100% {
                transform: scale(1);
            }
        }

        /* 鑱旂郴绔欎富寮圭獥 */
        .contact-modal {
            display: none;
            position: fixed;
            top: 0;
            left: 0;
            right: 0;
            bottom: 0;
            background: rgba(0, 0, 0, 0.6);
            z-index: 10000;
            justify-content: center;
            align-items: center;
        }

        .contact-modal.show {
            display: flex;
        }

        .contact-modal-content {
            position: relative;
            background: white;
            border-radius: 12px;
            overflow: hidden;
            box-shadow: 0 20px 60px rgba(0, 0, 0, 0.3);
            padding: 20px;
            text-align: center;
        }

        .contact-modal-text {
            color: #1e3a5f;
            font-size: 15px;
            font-weight: 600;
            margin-bottom: 16px;
        }

        .contact-modal-content img {
            display: block;
            max-width: 300px;
            max-height: 80vh;
            border-radius: 8px;
        }

        .contact-modal-close {
            position: absolute;
            top: 8px;
            right: 8px;
            width: 28px;
            height: 28px;
            background: rgba(0, 0, 0, 0.5);
            border: none;
            border-radius: 50%;
            color: white;
            font-size: 12px;
            cursor: pointer;
            transition: background 0.2s;
            display: flex;
            align-items: center;
            justify-content: center;
        }

        .contact-modal-close:hover {
            background: rgba(0, 0, 0, 0.7);
        }

        .ggb-title {
            font-size: 16px;
            font-weight: 500;
            color: var(--text-primary);
            display: flex;
            align-items: center;
            gap: 10px;
        }

        .ggb-title i {
            color: var(--success);
        }

        .ggb-actions {
            display: flex;
            align-items: center;
            gap: 10px;
            flex-wrap: nowrap;
            min-width: 0;
        }

        .ggb-actions .header-credits {
            margin-right: 2px;
        }

        .ggb-action-btn {
            min-height: 0;
            height: auto;
            padding: 3px 10px;
            background: var(--bg-tertiary);
            border: 1px solid var(--border-color);
            border-radius: 16px;
            color: var(--text-secondary);
            font-size: 13px;
            font-weight: 600;
            cursor: pointer;
            display: flex;
            align-items: center;
            justify-content: center;
            gap: 5px;
            transition: all 0.2s ease;
            white-space: nowrap;
            flex-shrink: 0;
            box-sizing: border-box;
        }

        .ggb-action-btn:hover {
            border-color: var(--accent);
            color: var(--text-primary);
        }

        .ggb-display-area {
            flex: 1;
            min-width: 0;
            min-height: 0;
            position: relative;
            overflow: hidden;
            background: #fff;
            touch-action: none;
            overscroll-behavior: contain;
        }

        .ggb-display-window {
            position: absolute;
            inset: 0;
            overflow: hidden;
            box-sizing: border-box;
            background: #fff;
        }

        .ggb-container {
            width: 100%;
            height: 100%;
            display: block;
            padding: 0;
            min-width: 0;
            min-height: 0;
            overflow: hidden;
            box-sizing: border-box;
            position: relative;
            background: #fff;
            touch-action: none;
            overscroll-behavior: contain;
        }

        .ggb-display-area:fullscreen,
        .ggb-display-area:-webkit-full-screen,
        .ggb-container:fullscreen,
        .ggb-container:-webkit-full-screen {
            width: 100vw;
            height: 100vh;
            background: #fff;
        }

        .ggb-display-area.ai-ggb-fullscreen-active,
        .ggb-container.ai-ggb-fullscreen-active {
            position: relative;
            background: #fff;
        }
#ggb-applet,
        .ggb-applet-wrapper {
            position: absolute !important;
            inset: 0 !important;
            display: block !important;
            flex: none !important;
            align-self: auto !important;
            min-width: 0 !important;
            min-height: 0 !important;
            width: 100% !important;
            height: 100% !important;
            border-radius: 0;
            overflow: hidden;
            background: #fff;
            border: none;
            box-sizing: border-box;
            touch-action: none;
            overscroll-behavior: contain;
        }

        /* AI GGB 椤甸潰涓紝鐣岄潰璋冩暣鎸夐挳涓嶈璐翠綇娴忚鍣ㄦ渶鍙宠竟锛岄伩鍏嶉伄鎸?GGB 鐨勮竟鐣?*/
        body .ggb-beautify-toggle {
            right: 12px;
            border-radius: 8px;
            border-right: 1px solid #d0d5dd;
        }

        body .ggb-beautify-panel {
            right: 56px;
        }

        /* 纭繚 GGB 鍐呴儴鍏冪礌涔熸纭€傚簲 */
        #ggb-applet article,
        #ggb-applet>div {
            min-width: 0 !important;
            min-height: 0 !important;
            width: 100% !important;
            height: 100% !important;
            max-width: 100% !important;
            max-height: 100% !important;
        }

        
        #ggb-applet .applet_scaler,
        #ggb-applet .ggbTransform {
            transform-origin: left top !important;
        }

        /* Keep GeoGebra scale origin stable; JS clears transient internal scale after setSize. */
        /* 淇GeoGebra宸ュ叿闈㈡澘涓嬫媺鍖哄煙鐨勫渾瑙掗棶棰?*/
        #ggb-applet .gwt-PopupPanel,
        #ggb-applet [class*="subToolPanel"],
        #ggb-applet [class*="SubToolPanel"],
        #ggb-applet [class*="toolPanel"],
        #ggb-applet [class*="ToolPanel"],
        #ggb-applet [class*="popupPanel"],
        #ggb-applet [class*="PopupPanel"],
        #ggb-applet [class*="dropdown"],
        #ggb-applet [class*="Dropdown"] {
            border-radius: 0 !important;
        }

        /* 椤甸潰缇庡寲闈㈡澘 */
        .beautify-panel {
            display: none;
            flex-direction: column;
            flex: 1;
            overflow: hidden;
        }

        .beautify-panel.show {
            display: flex;
        }

        .beautify-content {
            flex: 1;
            overflow-y: auto;
            padding: 20px;
        }

        .beautify-group {
            margin-bottom: 20px;
        }

        .beautify-group-title {
            font-size: 13px;
            font-weight: 600;
            color: var(--text-secondary);
            margin-bottom: 10px;
            padding-bottom: 6px;
            border-bottom: 1px solid var(--border-color);
        }

        .beautify-options-grid {
            display: grid;
            grid-template-columns: repeat(2, 1fr);
            gap: 8px;
        }

        .beautify-option {
            display: flex;
            align-items: center;
            gap: 10px;
            padding: 10px 12px;
            background: var(--bg-tertiary);
            border-radius: 8px;
            cursor: pointer;
            transition: all 0.2s;
            user-select: none;
        }

        .beautify-option:hover {
            background: var(--bg-hover);
        }

        .beautify-option input[type="checkbox"] {
            display: none;
        }

        .beautify-checkbox {
            width: 18px;
            height: 18px;
            border: 2px solid var(--border-color);
            border-radius: 4px;
            display: flex;
            align-items: center;
            justify-content: center;
            transition: all 0.2s;
            flex-shrink: 0;
        }

        .beautify-checkbox::after {
            content: '\f00c';
            font-family: 'Font Awesome 6 Free';
            font-weight: 900;
            font-size: 10px;
            color: white;
            opacity: 0;
            transform: scale(0);
            transition: all 0.2s;
        }

        .beautify-option input[type="checkbox"]:checked+.beautify-checkbox {
            background: var(--accent);
            border-color: var(--accent);
        }

        .beautify-option input[type="checkbox"]:checked+.beautify-checkbox::after {
            opacity: 1;
            transform: scale(1);
        }

        .beautify-option span:last-child {
            font-size: 13px;
            color: var(--text-primary);
        }

        /* Toast 鎻愮ず */
        .toast-message {
            position: fixed;
            bottom: 30px;
            left: 50%;
            transform: translateX(-50%) translateY(20px);
            padding: 14px 40px 14px 20px;
            border-radius: 10px;
            font-size: 14px;
            font-weight: 500;
            z-index: 10000;
            opacity: 0;
            transition: all 0.3s ease;
            box-shadow: 0 4px 20px rgba(0, 0, 0, 0.3);
            max-width: 90%;
            line-height: 1.5;
        }

        .toast-message.show {
            opacity: 1;
            transform: translateX(-50%) translateY(0);
        }

        .toast-close {
            position: absolute;
            top: 50%;
            right: 10px;
            transform: translateY(-50%);
            background: none;
            border: none;
            color: inherit;
            font-size: 18px;
            cursor: pointer;
            opacity: 0.7;
            padding: 0 5px;
            line-height: 1;
        }

        .toast-close:hover {
            opacity: 1;
        }

        .toast-info {
            background: var(--bg-tertiary);
            color: var(--text-primary);
            border: 1px solid var(--border-color);
        }

        .toast-success {
            background: #166534;
            color: #dcfce7;
        }

        .toast-warning {
            background: #854d0e;
            color: #fef9c3;
        }

        .toast-error {
            background: #991b1b;
            color: #fee2e2;
        }

        /* ===== 鑷畾涔夋ā鍨嬮€夋嫨涓嬫媺闈㈡澘 ===== */
        .model-custom-select {
            position: relative;
            flex: 1;
            width: 100%;
            min-width: 200px;
        }

        .model-select-trigger {
            display: flex;
            align-items: center;
            gap: 10px;
            padding: 3px 14px;
            background: var(--bg-tertiary);
            border: 2px solid var(--border-color);
            border-radius: 8px;
            cursor: pointer;
            transition: all 0.2s;
            user-select: none;
        }

        .model-select-trigger:hover {
            border-color: var(--accent);
        }

        .model-custom-select.open .model-select-trigger {
            border-color: var(--accent);
            box-shadow: 0 0 0 2px var(--accent-glow);
        }

        .trigger-name {
            font-size: 13px;
            font-weight: 600;
            color: var(--text-primary);
        }

        .trigger-stars {
            color: #FBBF24;
            font-size: 11px;
            letter-spacing: 1px;
        }

        .trigger-stars .dim {
            opacity: 0.2;
        }

        .trigger-credits {
            font-size: 11px;
            color: var(--text-muted);
        }

        .trigger-arrow {
            margin-left: auto;
            font-size: 10px;
            color: var(--text-muted);
            transition: transform 0.2s;
        }

        .model-custom-select.open .trigger-arrow {
            transform: rotate(180deg);
        }

        .model-options-panel {
            display: none;
            position: fixed;
            min-width: 340px;
            max-height: 400px;
            overflow-y: auto;
            background: #1e1e2e;
            border: 1px solid var(--border-color);
            border-radius: 8px;
            z-index: 10000;
            box-shadow: 0 8px 24px rgba(0, 0, 0, 0.4);
            animation: modelPanelIn 0.15s ease;
        }

        .model-options-panel.show {
            display: block;
        }

        @keyframes modelPanelIn {
            from {
                opacity: 0;
                transform: translateY(4px);
            }

            to {
                opacity: 1;
                transform: translateY(0);
            }
        }

        .model-opt-header {
            display: flex;
            align-items: center;
            padding: 6px 14px;
            font-size: 11px;
            color: var(--text-muted);
            border-bottom: 1px solid rgba(255, 255, 255, 0.06);
        }

        .model-opt-header span:first-child {
            flex: 1;
        }

        .model-opt-header span:nth-child(2) {
            width: 80px;
            text-align: center;
        }

        .model-opt-header span:last-child {
            width: 40px;
            text-align: right;
        }

        .model-opt {
            display: flex;
            align-items: center;
            padding: 2px 14px;
            cursor: pointer;
            transition: background 0.15s;
        }

        .model-opt:hover {
            background: rgba(99, 102, 241, 0.1);
        }

        .model-opt.selected {
            background: rgba(99, 102, 241, 0.15);
        }

        .opt-name {
            flex: 1;
            font-size: 13px;
            color: #e5e5e5;
            white-space: nowrap;
        }

        .model-opt.selected .opt-name {
            color: #a5b4fc;
            font-weight: 600;
        }

        .opt-name .text-only {
            font-size: 10px;
            color: #f87171;
            margin-left: 4px;
        }

        .opt-name .text-fast {
            font-size: 10px;
            color: #34d399;
            margin-left: 4px;
        }

        .opt-stars {
            width: 80px;
            text-align: center;
            color: #FBBF24;
            font-size: 12px;
            letter-spacing: 1px;
        }

        .opt-stars .dim {
            opacity: 0.2;
        }

        .opt-credits {
            width: 40px;
            text-align: right;
            font-size: 12px;
            color: var(--text-muted);
        }

        /* ========== 鍝嶅簲寮忚璁?========== */

        /* 灏忓钩鏉?澶ф墜鏈烘í灞?*/
        @media (max-width: 850px) {

            html,
            body {
                height: 100%;
                overflow: hidden;
            }

            .ai-container {
                position: fixed;
                top: var(--site-nav-height, 60px);
                right: 0;
                bottom: 0;
                left: 0;
                flex-direction: column;
                height: auto;
                min-height: 0;
                overflow-x: hidden;
                overflow-y: auto;
                -webkit-overflow-scrolling: touch;
                overscroll-behavior-y: contain;
                scrollbar-width: none;
                -ms-overflow-style: none;
            }

            .ai-container::-webkit-scrollbar {
                width: 0;
                height: 0;
            }

            .control-panel {
                width: 100%;
                min-width: 100%;
                max-width: none;
                flex-basis: auto;
                height: auto;
                max-height: none;
                border-right: none;
                border-bottom: 1px solid var(--border-color);
                overflow: visible;
            }

            /* 鎵嬫満绔殣钘忔彁绀烘枃瀛楋紝閬垮厤閬尅杈撳叆妗?*/

            /* 鎵嬫満绔?placeholder 缂╁皬瀛楀彿 */

            /* GGB 闈㈡澘鍝嶅簲寮?- 閬垮厤閲嶅彔 */
            .ggb-panel {
                flex: 0 0 auto;
                width: 100%;
                min-width: 0;
                overflow: hidden;
                min-height: 400px;
            }

            .ggb-container {
                position: relative;
                overflow: hidden;
            }

            /* GGB 澶撮儴鍝嶅簲寮?*/
            .ggb-header {
                min-height: 39px;
                height: auto;
                flex-wrap: wrap;
                gap: 8px;
                padding: 3px 16px;
                position: relative;
                z-index: 10;
                overflow: visible;
            }

            .ggb-title-section {
                width: auto;
                flex-wrap: nowrap;
                gap: 8px;
            }

            .ggb-main-title {
                font-size: 15px;
            }

            .ggb-main-title i {
                font-size: 17px;
            }

            .contact-btn {
                height: auto;
                padding: 3px 10px;
                font-size: 13px;
            }

            .ggb-actions {
                width: auto;
                justify-content: flex-start;
                gap: 8px;
                flex-wrap: wrap;
                min-width: 0;
            }

            .ggb-action-btn {
                height: auto;
                padding: 3px 10px;
                font-size: 13px;
            }

            .header-credits {
                height: auto;
                padding: 3px 10px;
                font-size: 13px;
            }

            .header-storage {
                height: auto;
                padding: 3px 10px;
                font-size: 13px;
            }

            /* 妯″瀷閫夋嫨妯悜甯冨眬鍦ㄥ皬灞忓箷鏀逛负绔栧悜 */

            /* 绐楀彛甯冨眬鎸夐挳缂╁皬涓?鍒?*/

            /* 鐢熸垚鎸夐挳鍖哄煙鍥哄畾鍦ㄥ簳閮?*/

            /* 鍛戒护闈㈡澘閫傞厤 */

            /* 鍏抽敭淇锛氬懡浠ら潰鏉垮湪鎵嬫満绔敼涓烘甯告枃妗ｆ祦锛堣€岄潪缁濆瀹氫綅锛?*/

            /* 椤甸潰璋冩暣闈㈡澘涔熸敼涓烘甯告枃妗ｆ祦 */
            .beautify-panel.show {
                display: flex;
                flex: none;
            }

            .beautify-content {
                padding: 16px;
            }
        }

        /* 鎵嬫満绔?*/
        @media (max-width: 600px) {
            .header-courseware-manage-hint {
                display: none;
            }

            .ai-container {
                height: auto;
                min-height: 0;
                margin-top: 0;
                overflow-y: auto;
            }

            .control-panel {
                max-height: none;
            }

            /* 鎵嬫満绔浘鐗囦笂浼犱繚鎸?鍒椾絾鏇寸揣鍑?*/

            .upload-hint-text {
                font-size: 9px;
                margin-top: 6px;
            }

            .tag {
                font-size: 7px;
            }

            /* GGB 闈㈡澘鎵嬫満绔紭鍖?- 鍥哄畾楂樺害纭繚鍙搷浣?*/
            .ggb-panel {
                min-height: 60vh;
            }

            .ggb-header {
                min-height: 39px;
                height: auto;
                padding: 3px 12px;
                flex-wrap: wrap;
                overflow: visible;
                z-index: 10;
            }

            .ggb-main-title {
                font-size: 14px;
            }

            .contact-btn {
                height: 28px;
                padding: 0 8px;
                font-size: 10px;
            }

            .contact-btn span {
                display: none;
            }

            .ggb-actions {
                gap: 6px;
                flex-wrap: wrap;
            }

            .ggb-action-btn {
                height: 28px;
                padding: 0 8px;
                font-size: 11px;
            }

            .header-credits {
                height: 28px;
                padding: 0 8px;
                font-size: 11px;
            }

            .header-storage {
                height: 28px;
                padding: 0 8px;
                font-size: 11px;
            }

            /* 妯″紡鍒囨崲鎸夐挳瀛椾綋缂╁皬 */

            /* 甯冨眬鎸夐挳2鍒?*/

            /* 鍛戒护闈㈡澘鎿嶄綔鎸夐挳鍦ㄦ墜鏈虹濮嬬粓鍙 */

            /* 鏍囩琛屾墜鏈虹绾靛悜鎺掑垪 */

            /* 瀛︾閫夋嫨涓嬫媺鍏ㄥ */
        }

        /* 瓒呭皬灞忓箷 */
        @media (max-width: 480px) {

            .header-credits,
            .header-storage {
                height: 26px;
                padding: 0 6px;
                gap: 4px;
                font-size: 10px;
            }

            .header-credits i,
            .header-storage i {
                font-size: 11px;
            }

        }

        /* 绉垎鎻愮ず */
        .credits-hint {
            font-size: 12px;
            color: var(--text-muted);
            font-weight: normal;
            margin-left: 8px;
        }

        /* 鐢ㄦ埛涓嬫媺鑿滃崟娣辫壊涓婚閫傞厤 */
        .user-dropdown {
            background: var(--bg-secondary) !important;
            border: 1px solid var(--border-color) !important;
            box-shadow: 0 8px 32px rgba(0, 0, 0, 0.5) !important;
        }

        .user-dropdown-header {
            border-bottom: 1px solid var(--border-color) !important;
        }

        .user-dropdown-header .username {
            color: var(--text-primary) !important;
        }

        .user-dropdown-header .expire-info {
            color: var(--text-secondary) !important;
        }

        .user-dropdown-item {
            color: var(--text-secondary) !important;
        }

        .user-dropdown-item:hover {
            background: var(--bg-hover) !important;
            color: var(--accent) !important;
        }

        .user-dropdown-divider {
            background: var(--border-color) !important;
        }

        /* 绉诲姩绔笅鎷夎彍鍗曟繁鑹蹭富棰橀€傞厤 */
        .mobile-dropdown-menu {
            background: var(--bg-secondary) !important;
            border: 1px solid var(--border-color) !important;
        }

        .mobile-menu-item {
            background: var(--bg-tertiary) !important;
            color: var(--text-primary) !important;
            border: 1px solid var(--border-color) !important;
        }

        .mobile-menu-item:hover {
            background: var(--bg-hover) !important;
            border-color: var(--accent) !important;
        }

        .mobile-menu-item.active {
            background: var(--accent) !important;
            border-color: var(--accent) !important;
            color: white !important;
        }

        .mobile-menu-item i,
        .mobile-menu-item span {
            color: inherit !important;
        }

