/**
 * AI 创作坊 · 会话上下文进度展示样式
 * 独立样式文件，仅作用于 AI 创作坊面板，不与其他面板通用
 * 字体：Microsoft YaHei，符合项目字体规范
 */

/* 右侧工具栏：激活模式提示 + 上下文开关 + Token 圆环 */
.ai-workshop-context-toolbar {
    margin-left: auto;
    display: flex;
    align-items: center;
    gap: 10px;
    font-family: "Microsoft YaHei", "微软雅黑", "SimSun", "宋体", "Arial", sans-serif;
}

/* 激活模式提示（与工具架 全局/选中 联动） */
.ai-workshop-active-mode-hint {
    font-size: 12px;
    color: #aaaaaa;
    line-height: 1;
    white-space: nowrap;
    flex-shrink: 0;
}

.ai-workshop-active-mode-hint:hover {
    color: #cccccc;
}

/* 上下文开关：标题 + 胶囊 */
.ai-workshop-context-toggle-wrap {
    display: flex;
    align-items: center;
    gap: 6px;
}

.ai-workshop-context-toggle-label {
    font-size: 12px;
    color: #aaaaaa;
    line-height: 1;
}

.ai-workshop-context-toggle {
    padding: 0;
    margin: 0;
    border: none;
    background: none;
    cursor: pointer;
    outline: none;
    font-family: inherit;
}

.ai-workshop-context-toggle:disabled {
    cursor: not-allowed;
}

.ai-workshop-context-toggle-wrap.is-frozen .ai-workshop-context-toggle {
    cursor: not-allowed;
}

.ai-workshop-context-toggle-track {
    display: inline-flex;
    align-items: center;
    width: 32px;
    height: 18px;
    border-radius: 9px;
    transition: background-color 0.2s ease, box-shadow 0.2s ease;
    position: relative;
    flex-shrink: 0;
}

.ai-workshop-context-toggle-track.is-on {
    background-color: #6b8cff;
}

.ai-workshop-context-toggle-track.is-off {
    background-color: #555555;
}

.ai-workshop-context-toggle-thumb {
    position: absolute;
    width: 14px;
    height: 14px;
    border-radius: 50%;
    background-color: #ffffff;
    box-shadow: 0 1px 2px rgba(0, 0, 0, 0.3);
    transition: left 0.2s ease;
    top: 2px;
}

.ai-workshop-context-toggle-thumb.is-on {
    left: calc(100% - 16px);
}

.ai-workshop-context-toggle-thumb:not(.is-on) {
    left: 2px;
}

.ai-workshop-context-indicator {
    display: flex;
    align-items: center;
    justify-content: flex-end;
    font-family: "Microsoft YaHei", "微软雅黑", "SimSun", "宋体", "Arial", sans-serif;
}

.ai-workshop-context-ring {
    --ai-workshop-context-progress: 0;
    width: 30px;
    height: 30px;
    border-radius: 50%;
    background:
        conic-gradient(
            #6b8cff calc(var(--ai-workshop-context-progress) * 360deg),
            rgba(255, 255, 255, 0.15) 0
        );
    display: flex;
    align-items: center;
    justify-content: center;
    position: relative;
}

.ai-workshop-context-ring.is-warning {
    background:
        conic-gradient(
            #ffb84d calc(var(--ai-workshop-context-progress) * 360deg),
            rgba(255, 255, 255, 0.15) 0
        );
}

.ai-workshop-context-ring.is-danger {
    background:
        conic-gradient(
            #ff4d4f calc(var(--ai-workshop-context-progress) * 360deg),
            rgba(255, 255, 255, 0.15) 0
        );
}

.ai-workshop-context-inner {
    width: 22px;
    height: 22px;
    border-radius: 50%;
    background-color: #1f1f21;
    display: flex;
    align-items: center;
    justify-content: center;
}

.ai-workshop-context-percent {
    font-size: 10px;
    color: #cccccc;
    line-height: 1;
}

