Academy v0.8.3 完整代码基线:Go 后端(internal/cmd/cli/mcp-server/docreader)、 Vue 前端(frontend)、数据库迁移(migrations)、部署编排(docker/helm/deploy)与文档。 今日开发的培训推送管理改动随后单独提交。
1650 lines
39 KiB
Vue
1650 lines
39 KiB
Vue
<template>
|
||
<div class="growth-os">
|
||
<!-- 顶栏:品牌 + 升级动画重播(原型主题切换按钮由应用全局主题承担,不在此重复) -->
|
||
<div class="topbar">
|
||
<div class="brand">
|
||
<div class="logo">G</div>
|
||
<div>
|
||
<h1>GROWTH OS</h1>
|
||
<p>员工成长进阶 · 个人成长总览</p>
|
||
</div>
|
||
</div>
|
||
<button class="btn primary" type="button" @click="openLevelUp">
|
||
<svg viewBox="0 0 24 24" fill="none" stroke="currentColor" stroke-width="2" stroke-linecap="round" stroke-linejoin="round"><path d="M3 12a9 9 0 1 0 3-6.7"/><path d="M3 4v5h5"/></svg>
|
||
重播升级动画
|
||
</button>
|
||
</div>
|
||
|
||
<div class="grid">
|
||
<!-- hero:个人总览 -->
|
||
<section class="card hero">
|
||
<div class="hero-top">
|
||
<div class="avatar-wrap">
|
||
<svg class="avatar-ring" viewBox="0 0 98 98">
|
||
<circle class="avatar-track" cx="49" cy="49" r="46"/>
|
||
<circle class="avatar-prog" cx="49" cy="49" r="46"/>
|
||
</svg>
|
||
<div class="avatar">{{ avatarChar }}</div>
|
||
<div class="lv-badge">LV. 7</div>
|
||
</div>
|
||
<div class="who">
|
||
<div class="name-row">
|
||
<h2>{{ displayName }}</h2>
|
||
<span class="tag">学员</span>
|
||
<span class="tag live"><i></i>成长中</span>
|
||
</div>
|
||
<p class="meta"><b>P6</b> 职级 · 用户体验中心 · 入职 3 年 2 个月</p>
|
||
<div class="xp">
|
||
<div class="xp-head">
|
||
<span>成长值 XP</span>
|
||
<span><b class="num">{{ fmtNum(nums.xp) }}</b> / 3000</span>
|
||
</div>
|
||
<div class="xp-bar"><div class="xp-fill" style="--p: 89.3%"></div></div>
|
||
<div class="xp-foot">
|
||
<span>距 <b>P7 专家级</b> 还需 <b>320 XP</b></span>
|
||
<span class="hint">预计 12 天达成</span>
|
||
</div>
|
||
</div>
|
||
</div>
|
||
</div>
|
||
|
||
<div class="stats">
|
||
<div class="stat">
|
||
<div class="k">连续成长天数</div>
|
||
<div class="v">{{ fmtNum(nums.streak) }}<small>天</small></div>
|
||
</div>
|
||
<div class="stat">
|
||
<div class="k">已解锁成就</div>
|
||
<div class="v">{{ fmtNum(nums.badges) }}<small>/ 20</small></div>
|
||
</div>
|
||
<div class="stat">
|
||
<div class="k">团队进阶排名</div>
|
||
<div class="v">#{{ fmtNum(nums.rank) }}<small>↑2</small></div>
|
||
</div>
|
||
</div>
|
||
|
||
<div class="trend">
|
||
<div class="trend-head">
|
||
<span>近 7 日 XP 走势</span>
|
||
<span>本周 <b>+420 XP</b> · 日均 +60</span>
|
||
</div>
|
||
<div class="bars">
|
||
<div v-for="(bar, i) in TREND" :key="bar.label" class="bar" :class="{ today: bar.today }">
|
||
<i :style="{ '--h': bar.h, '--bi': i }"></i>
|
||
<span>{{ bar.label }}</span>
|
||
</div>
|
||
</div>
|
||
</div>
|
||
</section>
|
||
|
||
<!-- 能力模型雷达 -->
|
||
<section class="card radar-card">
|
||
<div class="card-head">
|
||
<div class="card-title">能力模型</div>
|
||
<div class="card-sub">近 90 天</div>
|
||
</div>
|
||
<div class="radar-wrap">
|
||
<svg class="radar" viewBox="-40 -28 320 292" aria-label="能力雷达图">
|
||
<polygon v-for="(points, i) in radarRings" :key="`ring-${i}`" class="grid-ring" :points="points"/>
|
||
<line v-for="(axis, i) in radarAxes" :key="`axis-${i}`" class="axis" :x1="CX" :y1="CY" :x2="axis.x" :y2="axis.y"/>
|
||
<polygon class="data-poly" :points="radarPoly"/>
|
||
<circle v-for="(dot, i) in radarDots" :key="`dot-${i}`" class="dot" :cx="dot.x" :cy="dot.y" r="3.6"/>
|
||
<text v-for="(label, i) in radarLabels" :key="`label-${i}`" class="axis-label" :x="label.x" :y="label.y" :text-anchor="label.anchor">{{ label.name }}</text>
|
||
</svg>
|
||
</div>
|
||
<div class="radar-foot">
|
||
<div class="n"><span class="num">{{ fmtNum(nums.score, 1) }}</span><span> 分</span></div>
|
||
<div class="d">综合能力<br>高于同职级 <b>68%</b></div>
|
||
</div>
|
||
</section>
|
||
|
||
<!-- 成长进阶路径 -->
|
||
<section class="card path-card">
|
||
<div class="card-head">
|
||
<div class="card-title">成长进阶路径</div>
|
||
<div class="card-sub">P4 → P8 · 已完成 3 / 5 阶段</div>
|
||
</div>
|
||
<div class="path-wrap">
|
||
<div class="track" style="--p: 72.25%">
|
||
<div class="track-fill"></div>
|
||
<div class="spark"></div>
|
||
</div>
|
||
<div class="steps">
|
||
<div v-for="(step, i) in STEPS" :key="step.lv" class="step" :class="step.state" :style="{ '--i': i }">
|
||
<div class="node">
|
||
<svg v-if="step.state === 'done'" viewBox="0 0 24 24" fill="none" stroke="currentColor" stroke-width="3" stroke-linecap="round" stroke-linejoin="round"><path d="M20 6 9 17l-5-5"/></svg>
|
||
<svg v-else-if="step.state === 'locked'" viewBox="0 0 24 24" fill="none" stroke="currentColor" stroke-width="2" stroke-linecap="round" stroke-linejoin="round"><rect x="4" y="10" width="16" height="11" rx="2.5"/><path d="M8 10V7a4 4 0 0 1 8 0v3"/></svg>
|
||
<template v-else>{{ step.lv }}</template>
|
||
</div>
|
||
<div class="step-name">{{ step.lv }} · {{ step.name }}</div>
|
||
<div class="step-desc">{{ step.desc }}</div>
|
||
<div v-if="step.p" class="step-prog" :style="{ '--p': step.p }"><i></i></div>
|
||
<div class="step-date">{{ step.date }}</div>
|
||
</div>
|
||
</div>
|
||
</div>
|
||
</section>
|
||
|
||
<!-- 成长成就 -->
|
||
<section class="card badges">
|
||
<div class="card-head">
|
||
<div class="card-title">成长成就</div>
|
||
<div class="card-sub">12 / 20 已点亮</div>
|
||
</div>
|
||
<div class="badge-grid">
|
||
<div v-for="badge in BADGES" :key="badge.n" class="badge" :class="badge.on ? 'unlocked' : 'locked'">
|
||
<span v-if="badge.fresh" class="new-dot"></span>
|
||
<div class="disc">
|
||
<svg viewBox="0 0 24 24" fill="none" stroke="currentColor" stroke-width="1.9" stroke-linecap="round" stroke-linejoin="round">
|
||
<path v-for="(d, pi) in BADGE_ICONS[badge.i]" :key="pi" :d="d"/>
|
||
</svg>
|
||
</div>
|
||
<div class="bn">{{ badge.n }}</div>
|
||
</div>
|
||
</div>
|
||
</section>
|
||
|
||
<!-- 今日进阶任务 -->
|
||
<section class="card tasks">
|
||
<div class="card-head">
|
||
<div class="card-title">今日进阶任务</div>
|
||
<div class="card-sub">剩余 1 项</div>
|
||
</div>
|
||
<div v-for="task in TASKS" :key="task.title" class="task" :class="{ done: task.done }">
|
||
<div class="tick">
|
||
<svg viewBox="0 0 24 24" fill="none" stroke="currentColor" stroke-width="3.4" stroke-linecap="round" stroke-linejoin="round"><path d="M20 6 9 17l-5-5"/></svg>
|
||
</div>
|
||
<div class="body">
|
||
<div class="t">{{ task.title }} <span>+{{ task.xp }} XP</span></div>
|
||
<div class="s">{{ task.status }}</div>
|
||
<div v-if="task.p" class="mini" :style="{ '--p': task.p }"><i></i></div>
|
||
</div>
|
||
</div>
|
||
<div class="task-cta">
|
||
<div class="txt">本周已积累 <b>420 XP</b><br>再得 <b>320 XP</b> 即可晋升 P7</div>
|
||
<button class="btn primary" type="button" @click="openLevelUp">继续成长</button>
|
||
</div>
|
||
</section>
|
||
</div>
|
||
|
||
<!-- 升级弹层:进页面不自动弹,由顶栏按钮 / 任务 CTA 触发 -->
|
||
<div class="levelup" :class="{ show: levelupShow }" :aria-hidden="!levelupShow">
|
||
<div class="lu-backdrop" @click="closeLevelUp"></div>
|
||
<div class="lu-card">
|
||
<div class="particles">
|
||
<i
|
||
v-for="(p, i) in particles"
|
||
:key="i"
|
||
:style="{ '--x': p.x, '--y': p.y, '--r': p.r, width: p.size, height: p.size, background: p.color, animationDelay: p.delay }"
|
||
></i>
|
||
</div>
|
||
<div class="lu-badge">LV.8</div>
|
||
<h3>进阶成功</h3>
|
||
<p class="sub">恭喜晋升为 <b>P7 专家级产品经理</b><br>你的成长路径已解锁新阶段</p>
|
||
<div class="lu-rewards">
|
||
<div class="chip"><b>+300</b> 成长值</div>
|
||
<div class="chip"><b>新</b> 成就徽章</div>
|
||
<div class="chip"><b>+5%</b> 学习额度</div>
|
||
</div>
|
||
<button class="btn primary" type="button" @click="closeLevelUp">继续成长</button>
|
||
</div>
|
||
</div>
|
||
|
||
<!-- SVG 渐变定义(头像环 / 雷达数据面) -->
|
||
<svg width="0" height="0" style="position: absolute">
|
||
<defs>
|
||
<linearGradient id="gosRingGrad" x1="0" y1="0" x2="1" y2="1">
|
||
<stop offset="0%" stop-color="#4F46E5"/>
|
||
<stop offset="55%" stop-color="#7C3AED"/>
|
||
<stop offset="100%" stop-color="#06B6D4"/>
|
||
</linearGradient>
|
||
<linearGradient id="gosAreaGrad" x1="0" y1="0" x2="0" y2="1">
|
||
<stop offset="0%" stop-color="#7C3AED" stop-opacity=".34"/>
|
||
<stop offset="100%" stop-color="#06B6D4" stop-opacity=".10"/>
|
||
</linearGradient>
|
||
</defs>
|
||
</svg>
|
||
</div>
|
||
</template>
|
||
|
||
<script setup lang="ts">
|
||
import { computed, onBeforeUnmount, onMounted, reactive, ref } from 'vue'
|
||
import { useAuthStore } from '@/stores/auth'
|
||
|
||
/* ================= 展示数据(与 docs/growth-os 原型一致,姓名取当前登录用户) ================= */
|
||
|
||
const authStore = useAuthStore()
|
||
const displayName = computed(() => authStore.user?.username || '成长学员')
|
||
const avatarChar = computed(() => displayName.value.slice(0, 1).toUpperCase())
|
||
|
||
const TREND = [
|
||
{ label: '一', h: '24%' },
|
||
{ label: '二', h: '52%' },
|
||
{ label: '三', h: '36%' },
|
||
{ label: '四', h: '64%' },
|
||
{ label: '五', h: '44%' },
|
||
{ label: '六', h: '16%' },
|
||
{ label: '今', h: '100%', today: true },
|
||
]
|
||
|
||
type StepState = 'done' | 'current' | 'locked'
|
||
const STEPS: { lv: string; name: string; desc: string; date: string; state: StepState; p?: string }[] = [
|
||
{ lv: 'P4', name: '初级', desc: '掌握基础方法论', date: '2021.09 达成', state: 'done' },
|
||
{ lv: 'P5', name: '中级', desc: '独立负责模块', date: '2022.06 达成', state: 'done' },
|
||
{ lv: 'P6', name: '高级', desc: '主导核心业务线', date: '2024.03 达成', state: 'done' },
|
||
{ lv: 'P7', name: '专家', desc: '定义行业标准', date: '进行中 89%', state: 'current', p: '89%' },
|
||
{ lv: 'P8', name: '首席', desc: '影响组织战略', date: '待解锁', state: 'locked' },
|
||
]
|
||
|
||
const BADGES = [
|
||
{ n: '首战告捷', i: 'flag', on: true },
|
||
{ n: '协作之星', i: 'users', on: true },
|
||
{ n: '极速交付', i: 'bolt', on: true, fresh: true },
|
||
{ n: '创新先锋', i: 'bulb', on: true },
|
||
{ n: '数据达人', i: 'chart', on: true },
|
||
{ n: '团队领袖', i: 'crown', on: false },
|
||
{ n: '客户之声', i: 'heart', on: false },
|
||
{ n: '年度之星', i: 'star', on: false },
|
||
]
|
||
|
||
const BADGE_ICONS: Record<string, string[]> = {
|
||
flag: ['M5 21V4M5 4h11l-2 4 2 4H5'],
|
||
users: ['M9 4.8a3.2 3.2 0 1 1 0 6.4 3.2 3.2 0 0 1 0-6.4Z', 'M3 20a6 6 0 0 1 12 0', 'M17 4.5a3.2 3.2 0 0 1 0 6.4', 'M18 14.5a6 6 0 0 1 3 5.5'],
|
||
bolt: ['M13 2 4 14h6l-1 8 9-12h-6l1-8z'],
|
||
bulb: ['M9 18h6M10 21h4', 'M12 3a6 6 0 0 0-3.5 10.9c.6.4.9 1 .9 1.7V16h5.2v-.4c0-.7.3-1.3.9-1.7A6 6 0 0 0 12 3z'],
|
||
chart: ['M4 20V10M10 20V5M16 20v-7M22 20H2'],
|
||
crown: ['M3 18h18l-1.5-9-4.5 3.5L12 5 9 12.5 4.5 9 3 18z'],
|
||
heart: ['M12 20s-7-4.4-7-9.3A3.9 3.9 0 0 1 12 8a3.9 3.9 0 0 1 7 2.7C19 15.6 12 20 12 20z'],
|
||
star: ['m12 3 2.7 5.7 6.3.9-4.6 4.4 1.1 6.2-5.5-3-5.5 3 1.1-6.2L3 9.6l6.3-.9L12 3z'],
|
||
}
|
||
|
||
const TASKS = [
|
||
{ title: '完成一次跨部门需求评审', xp: 50, status: '已完成 · 09:40', done: true },
|
||
{ title: '主导一次产品方案分享', xp: 80, status: '已完成 · 14:05', done: true },
|
||
{ title: '提交季度成长复盘', xp: 60, status: '进行中 · 还需 1 个章节', done: false, p: '64%' },
|
||
]
|
||
|
||
/* ================= 雷达图几何(同原型 buildRadar) ================= */
|
||
|
||
const RADAR_DIMS = [
|
||
{ name: '专业力', v: 0.88 },
|
||
{ name: '协作力', v: 0.76 },
|
||
{ name: '影响力', v: 0.68 },
|
||
{ name: '创新力', v: 0.92 },
|
||
{ name: '执行力', v: 0.82 },
|
||
]
|
||
const CX = 120
|
||
const CY = 122
|
||
const R = 84
|
||
|
||
const radarPoint = (i: number, ratio: number): [number, number] => {
|
||
const a = ((-90 + i * 72) * Math.PI) / 180
|
||
return [CX + Math.cos(a) * R * ratio, CY + Math.sin(a) * R * ratio]
|
||
}
|
||
const radarPolyStr = (ratio: number) =>
|
||
RADAR_DIMS.map((_, i) => {
|
||
const [x, y] = radarPoint(i, ratio)
|
||
return `${x.toFixed(1)},${y.toFixed(1)}`
|
||
}).join(' ')
|
||
|
||
const radarRings = [0.25, 0.5, 0.75, 1].map((r) => radarPolyStr(r))
|
||
const radarAxes = RADAR_DIMS.map((_, i) => {
|
||
const [x, y] = radarPoint(i, 1)
|
||
return { x: x.toFixed(1), y: y.toFixed(1) }
|
||
})
|
||
const radarDots = RADAR_DIMS.map((d, i) => {
|
||
const [x, y] = radarPoint(i, d.v)
|
||
return { x: x.toFixed(1), y: y.toFixed(1) }
|
||
})
|
||
const radarLabels = RADAR_DIMS.map((d, i) => {
|
||
const a = ((-90 + i * 72) * Math.PI) / 180
|
||
const x = CX + Math.cos(a) * (R + 22)
|
||
const y = CY + Math.sin(a) * (R + 22) + 3.5
|
||
let anchor = 'middle'
|
||
if (Math.cos(a) > 0.25) anchor = 'start'
|
||
else if (Math.cos(a) < -0.25) anchor = 'end'
|
||
return { name: d.name, x: x.toFixed(1), y: y.toFixed(1), anchor }
|
||
})
|
||
// 数据面(各维度按能力值)
|
||
const radarPoly = radarPolyStr(1)
|
||
|
||
/* ================= 数字滚动(同原型 countUp) ================= */
|
||
|
||
const reduceMotion = window.matchMedia('(prefers-reduced-motion: reduce)').matches
|
||
|
||
const nums = reactive({ xp: 0, streak: 0, badges: 0, rank: 0, score: 0 })
|
||
|
||
const fmtNum = (v: number, dec = 0) => {
|
||
const parts = v.toFixed(dec).split('.')
|
||
parts[0] = parts[0].replace(/\B(?=(\d{3})+(?!\d))/g, ',')
|
||
return parts.join('.')
|
||
}
|
||
|
||
const countUps: { key: keyof typeof nums; to: number; dec: number; raf: number }[] = []
|
||
const timers: number[] = []
|
||
|
||
function countUp(key: keyof typeof nums, to: number, dec = 0, dur = 1400) {
|
||
const t0 = performance.now()
|
||
const total = reduceMotion ? 1 : dur
|
||
const tick = (now: number) => {
|
||
const p = Math.min(1, (now - t0) / total)
|
||
const eased = 1 - Math.pow(1 - p, 3)
|
||
nums[key] = to * eased
|
||
const entry = countUps.find((c) => c.key === key)
|
||
if (p < 1 && entry) entry.raf = requestAnimationFrame(tick)
|
||
}
|
||
countUps.push({ key, to, dec, raf: requestAnimationFrame(tick) })
|
||
}
|
||
|
||
/* ================= 升级弹层(手动触发,Escape/遮罩关闭) ================= */
|
||
|
||
const levelupShow = ref(false)
|
||
const PARTICLE_COLORS = ['#4F46E5', '#7C3AED', '#06B6D4', '#F59E0B', '#10B981']
|
||
const particles = ref<{ x: string; y: string; r: string; size: string; color: string; delay: string }[]>([])
|
||
|
||
function burst() {
|
||
const n = reduceMotion ? 0 : 26
|
||
particles.value = Array.from({ length: n }, (_, i) => {
|
||
const ang = Math.random() * Math.PI * 2
|
||
const dist = 90 + Math.random() * 160
|
||
return {
|
||
x: `${Math.round(Math.cos(ang) * dist)}px`,
|
||
y: `${Math.round(Math.sin(ang) * dist + 70)}px`,
|
||
r: `${Math.round(Math.random() * 540 - 270)}deg`,
|
||
size: `${Math.round(5 + Math.random() * 6)}px`,
|
||
color: PARTICLE_COLORS[i % PARTICLE_COLORS.length],
|
||
delay: `${(Math.random() * 0.18).toFixed(2)}s`,
|
||
}
|
||
})
|
||
}
|
||
|
||
function openLevelUp() {
|
||
levelupShow.value = true
|
||
burst()
|
||
}
|
||
|
||
function closeLevelUp() {
|
||
levelupShow.value = false
|
||
}
|
||
|
||
const onKeydown = (e: KeyboardEvent) => {
|
||
if (e.key === 'Escape') closeLevelUp()
|
||
}
|
||
|
||
onMounted(() => {
|
||
window.addEventListener('keydown', onKeydown)
|
||
const startDelay = reduceMotion ? 0 : 320
|
||
const targets: [keyof typeof nums, number, number][] = [
|
||
['xp', 2680, 0],
|
||
['streak', 248, 0],
|
||
['badges', 12, 0],
|
||
['rank', 3, 0],
|
||
['score', 81.2, 1],
|
||
]
|
||
targets.forEach(([key, to, dec], i) => {
|
||
timers.push(window.setTimeout(() => countUp(key, to, dec), startDelay + i * 90))
|
||
})
|
||
})
|
||
|
||
onBeforeUnmount(() => {
|
||
window.removeEventListener('keydown', onKeydown)
|
||
timers.forEach((t) => window.clearTimeout(t))
|
||
countUps.forEach((c) => cancelAnimationFrame(c.raf))
|
||
})
|
||
</script>
|
||
|
||
<style lang="less" scoped>
|
||
// 局部变量:强调色沿用原型(靛紫青渐变,游戏化模块的独立视觉个性),
|
||
// 表面色/文字色/描边映射 TDesign tokens,自动跟随应用亮暗主题。
|
||
.growth-os {
|
||
--g-brand: #4f46e5;
|
||
--g-brand-2: #7c3aed;
|
||
--g-cyan: #06b6d4;
|
||
--g-gold: #f59e0b;
|
||
--g-green: #10b981;
|
||
--g-grad: linear-gradient(135deg, #4f46e5 0%, #7c3aed 56%, #06b6d4 100%);
|
||
--g-grad-soft: linear-gradient(135deg, rgba(79, 70, 229, 0.12), rgba(6, 182, 212, 0.14));
|
||
--g-card: var(--td-bg-color-container);
|
||
--g-soft: var(--td-bg-color-secondarycontainer);
|
||
--g-soft-2: var(--td-bg-color-component);
|
||
--g-ink: var(--td-text-color-primary);
|
||
--g-sub: var(--td-text-color-secondary);
|
||
--g-line: var(--td-component-stroke);
|
||
--g-shadow: 0 1px 2px rgba(16, 24, 40, 0.05), 0 18px 40px -22px rgba(16, 24, 40, 0.28);
|
||
--g-radius: 18px;
|
||
|
||
color: var(--g-ink);
|
||
font-variant-numeric: tabular-nums;
|
||
}
|
||
|
||
/* ---------- 布局 ---------- */
|
||
.growth-os {
|
||
position: relative;
|
||
padding: 18px 16px 22px;
|
||
border-radius: 14px;
|
||
overflow: hidden;
|
||
}
|
||
|
||
.topbar {
|
||
display: flex;
|
||
align-items: center;
|
||
justify-content: space-between;
|
||
gap: 16px;
|
||
margin-bottom: 18px;
|
||
flex-wrap: wrap;
|
||
}
|
||
.brand {
|
||
display: flex;
|
||
align-items: center;
|
||
gap: 12px;
|
||
}
|
||
.logo {
|
||
width: 42px;
|
||
height: 42px;
|
||
border-radius: 13px;
|
||
background: var(--g-grad);
|
||
display: grid;
|
||
place-items: center;
|
||
color: #fff;
|
||
font-weight: 800;
|
||
font-size: 17px;
|
||
box-shadow: 0 10px 22px -8px rgba(79, 70, 229, 0.6);
|
||
position: relative;
|
||
overflow: hidden;
|
||
|
||
&::after {
|
||
content: '';
|
||
position: absolute;
|
||
inset: 0;
|
||
background: linear-gradient(120deg, transparent 30%, rgba(255, 255, 255, 0.55) 48%, transparent 62%);
|
||
animation: gosSheen 4.5s ease-in-out infinite;
|
||
}
|
||
}
|
||
.brand {
|
||
h1 {
|
||
font-size: 15.5px;
|
||
margin: 0;
|
||
letter-spacing: 0.6px;
|
||
font-weight: 800;
|
||
}
|
||
p {
|
||
margin: 3px 0 0;
|
||
font-size: 11.5px;
|
||
color: var(--g-sub);
|
||
letter-spacing: 0.4px;
|
||
}
|
||
}
|
||
|
||
.btn {
|
||
border: 1px solid var(--g-line);
|
||
background: var(--g-card);
|
||
color: var(--g-ink);
|
||
font: inherit;
|
||
font-size: 12.5px;
|
||
font-weight: 600;
|
||
padding: 9px 16px;
|
||
border-radius: 11px;
|
||
cursor: pointer;
|
||
display: inline-flex;
|
||
align-items: center;
|
||
gap: 7px;
|
||
transition: 0.25s ease;
|
||
|
||
&:hover {
|
||
transform: translateY(-1px);
|
||
box-shadow: var(--g-shadow);
|
||
border-color: rgba(79, 70, 229, 0.35);
|
||
}
|
||
&.primary {
|
||
background: var(--g-grad);
|
||
border-color: transparent;
|
||
color: #fff;
|
||
box-shadow: 0 12px 24px -12px rgba(79, 70, 229, 0.9);
|
||
}
|
||
svg {
|
||
width: 14px;
|
||
height: 14px;
|
||
}
|
||
}
|
||
|
||
.grid {
|
||
display: grid;
|
||
grid-template-columns: 1.55fr 1fr;
|
||
gap: 18px;
|
||
}
|
||
.card {
|
||
background: var(--g-card);
|
||
border: 1px solid var(--g-line);
|
||
border-radius: var(--g-radius);
|
||
padding: 22px;
|
||
box-shadow: var(--g-shadow);
|
||
position: relative;
|
||
overflow: hidden;
|
||
animation: gosCardIn 0.7s cubic-bezier(0.2, 0.8, 0.2, 1) both;
|
||
animation-delay: var(--d, 0.05s);
|
||
}
|
||
.card-head {
|
||
display: flex;
|
||
align-items: center;
|
||
justify-content: space-between;
|
||
margin-bottom: 16px;
|
||
}
|
||
.card-title {
|
||
font-size: 13.5px;
|
||
font-weight: 700;
|
||
letter-spacing: 0.2px;
|
||
display: flex;
|
||
align-items: center;
|
||
gap: 8px;
|
||
|
||
&::before {
|
||
content: '';
|
||
width: 4px;
|
||
height: 14px;
|
||
border-radius: 3px;
|
||
background: var(--g-grad);
|
||
}
|
||
}
|
||
.card-sub {
|
||
font-size: 11.5px;
|
||
color: var(--g-sub);
|
||
}
|
||
|
||
/* ---------- hero ---------- */
|
||
.hero {
|
||
grid-column: 1;
|
||
padding: 24px 24px 22px;
|
||
|
||
&::before {
|
||
content: '';
|
||
position: absolute;
|
||
right: -100px;
|
||
top: -120px;
|
||
width: 320px;
|
||
height: 320px;
|
||
border-radius: 50%;
|
||
background: var(--g-grad-soft);
|
||
filter: blur(10px);
|
||
pointer-events: none;
|
||
}
|
||
}
|
||
.hero-top {
|
||
display: flex;
|
||
gap: 20px;
|
||
align-items: flex-start;
|
||
position: relative;
|
||
}
|
||
.avatar-wrap {
|
||
position: relative;
|
||
width: 98px;
|
||
height: 98px;
|
||
flex: 0 0 auto;
|
||
}
|
||
.avatar-ring {
|
||
position: absolute;
|
||
inset: 0;
|
||
transform: rotate(-90deg);
|
||
|
||
circle {
|
||
fill: none;
|
||
stroke-width: 5;
|
||
stroke-linecap: round;
|
||
}
|
||
}
|
||
.avatar-track {
|
||
stroke: var(--g-soft-2);
|
||
}
|
||
.avatar-prog {
|
||
stroke: url(#gosRingGrad);
|
||
stroke-dasharray: 289;
|
||
filter: drop-shadow(0 0 6px rgba(79, 70, 229, 0.35));
|
||
animation: gosRingIn 1.8s cubic-bezier(0.16, 0.84, 0.3, 1) 0.35s both;
|
||
}
|
||
.avatar {
|
||
position: absolute;
|
||
inset: 11px;
|
||
border-radius: 50%;
|
||
background: var(--g-grad);
|
||
display: grid;
|
||
place-items: center;
|
||
color: #fff;
|
||
font-size: 28px;
|
||
font-weight: 700;
|
||
letter-spacing: 1px;
|
||
box-shadow: inset 0 -8px 18px rgba(0, 0, 0, 0.16);
|
||
|
||
&::after {
|
||
content: '';
|
||
position: absolute;
|
||
inset: 0;
|
||
border-radius: 50%;
|
||
background: radial-gradient(circle at 30% 22%, rgba(255, 255, 255, 0.55), transparent 58%);
|
||
}
|
||
}
|
||
.lv-badge {
|
||
position: absolute;
|
||
bottom: -4px;
|
||
left: 50%;
|
||
transform: translateX(-50%);
|
||
background: var(--g-card);
|
||
border: 1px solid var(--g-line);
|
||
border-radius: 999px;
|
||
font-size: 11px;
|
||
font-weight: 800;
|
||
padding: 3px 10px;
|
||
letter-spacing: 0.4px;
|
||
color: var(--g-brand);
|
||
box-shadow: 0 6px 14px -6px rgba(16, 24, 40, 0.4);
|
||
white-space: nowrap;
|
||
}
|
||
.who {
|
||
flex: 1;
|
||
min-width: 0;
|
||
padding-top: 4px;
|
||
}
|
||
.name-row {
|
||
display: flex;
|
||
align-items: center;
|
||
gap: 9px;
|
||
flex-wrap: wrap;
|
||
|
||
h2 {
|
||
margin: 0;
|
||
font-size: 24px;
|
||
letter-spacing: -0.3px;
|
||
font-weight: 800;
|
||
}
|
||
}
|
||
.tag {
|
||
font-size: 11px;
|
||
font-weight: 700;
|
||
padding: 4px 10px;
|
||
border-radius: 999px;
|
||
background: rgba(79, 70, 229, 0.1);
|
||
color: var(--g-brand);
|
||
letter-spacing: 0.3px;
|
||
|
||
&.live {
|
||
background: rgba(16, 185, 129, 0.12);
|
||
color: var(--g-green);
|
||
display: inline-flex;
|
||
align-items: center;
|
||
gap: 5px;
|
||
|
||
i {
|
||
width: 6px;
|
||
height: 6px;
|
||
border-radius: 50%;
|
||
background: var(--g-green);
|
||
animation: gosBlink 1.8s ease-in-out infinite;
|
||
}
|
||
}
|
||
}
|
||
.meta {
|
||
margin: 7px 0 0;
|
||
font-size: 12.5px;
|
||
color: var(--g-sub);
|
||
|
||
b {
|
||
color: var(--g-ink);
|
||
font-weight: 600;
|
||
}
|
||
}
|
||
|
||
.xp {
|
||
margin-top: 18px;
|
||
}
|
||
.xp-head {
|
||
display: flex;
|
||
align-items: baseline;
|
||
justify-content: space-between;
|
||
font-size: 12px;
|
||
color: var(--g-sub);
|
||
margin-bottom: 8px;
|
||
|
||
b {
|
||
font-size: 15px;
|
||
color: var(--g-ink);
|
||
font-variant-numeric: tabular-nums;
|
||
letter-spacing: -0.2px;
|
||
}
|
||
}
|
||
.xp-bar {
|
||
height: 12px;
|
||
border-radius: 99px;
|
||
background: var(--g-soft-2);
|
||
overflow: hidden;
|
||
position: relative;
|
||
}
|
||
.xp-fill {
|
||
height: 100%;
|
||
border-radius: 99px;
|
||
background: var(--g-grad);
|
||
position: relative;
|
||
animation: gosXpIn 1.9s cubic-bezier(0.16, 0.84, 0.3, 1) 0.3s both;
|
||
box-shadow: 0 0 14px rgba(124, 58, 237, 0.4);
|
||
|
||
&::after {
|
||
content: '';
|
||
position: absolute;
|
||
top: 0;
|
||
bottom: 0;
|
||
width: 45%;
|
||
background: linear-gradient(90deg, transparent, rgba(255, 255, 255, 0.75), transparent);
|
||
animation: gosSweep 2.8s ease-in-out infinite;
|
||
}
|
||
}
|
||
.xp-foot {
|
||
margin-top: 9px;
|
||
font-size: 11.5px;
|
||
color: var(--g-sub);
|
||
display: flex;
|
||
align-items: center;
|
||
gap: 6px;
|
||
|
||
b {
|
||
color: var(--g-brand);
|
||
}
|
||
.hint {
|
||
margin-left: auto;
|
||
color: var(--g-sub);
|
||
opacity: 0.85;
|
||
}
|
||
}
|
||
|
||
.stats {
|
||
display: grid;
|
||
grid-template-columns: repeat(3, 1fr);
|
||
gap: 11px;
|
||
margin-top: 20px;
|
||
}
|
||
.stat {
|
||
background: var(--g-soft);
|
||
border: 1px solid var(--g-line);
|
||
border-radius: 14px;
|
||
padding: 12px 13px;
|
||
transition: 0.28s ease;
|
||
|
||
&:hover {
|
||
transform: translateY(-2px);
|
||
border-color: rgba(79, 70, 229, 0.3);
|
||
}
|
||
.k {
|
||
font-size: 11px;
|
||
color: var(--g-sub);
|
||
letter-spacing: 0.2px;
|
||
}
|
||
.v {
|
||
font-size: 20px;
|
||
font-weight: 800;
|
||
margin-top: 5px;
|
||
font-variant-numeric: tabular-nums;
|
||
letter-spacing: -0.4px;
|
||
|
||
small {
|
||
font-size: 11px;
|
||
font-weight: 600;
|
||
color: var(--g-sub);
|
||
margin-left: 2px;
|
||
}
|
||
}
|
||
}
|
||
|
||
.trend {
|
||
margin-top: 18px;
|
||
padding-top: 15px;
|
||
border-top: 1px dashed var(--g-line);
|
||
}
|
||
.trend-head {
|
||
display: flex;
|
||
justify-content: space-between;
|
||
font-size: 11.5px;
|
||
color: var(--g-sub);
|
||
margin-bottom: 11px;
|
||
|
||
b {
|
||
color: var(--g-brand);
|
||
}
|
||
}
|
||
.bars {
|
||
display: grid;
|
||
grid-template-columns: repeat(7, 1fr);
|
||
gap: 9px;
|
||
align-items: end;
|
||
height: 70px;
|
||
}
|
||
.bar {
|
||
display: flex;
|
||
flex-direction: column;
|
||
justify-content: flex-end;
|
||
align-items: center;
|
||
gap: 6px;
|
||
height: 100%;
|
||
|
||
i {
|
||
width: 100%;
|
||
height: var(--h);
|
||
border-radius: 6px 6px 3px 3px;
|
||
background: linear-gradient(180deg, rgba(79, 70, 229, 0.28), rgba(6, 182, 212, 0.1));
|
||
transform-origin: bottom;
|
||
animation: gosBarGrow 0.8s cubic-bezier(0.2, 0.9, 0.3, 1) both;
|
||
animation-delay: calc(var(--bi, 0) * 60ms + 0.6s);
|
||
}
|
||
span {
|
||
font-size: 9.5px;
|
||
color: var(--g-sub);
|
||
}
|
||
&.today {
|
||
i {
|
||
background: var(--g-grad);
|
||
box-shadow: 0 8px 16px -8px rgba(79, 70, 229, 0.8);
|
||
}
|
||
span {
|
||
color: var(--g-brand);
|
||
font-weight: 700;
|
||
}
|
||
}
|
||
}
|
||
|
||
/* ---------- radar ---------- */
|
||
.radar-card {
|
||
grid-column: 2;
|
||
display: flex;
|
||
flex-direction: column;
|
||
}
|
||
.radar-wrap {
|
||
flex: 1;
|
||
display: grid;
|
||
place-items: center;
|
||
padding: 4px 0 0;
|
||
}
|
||
svg.radar {
|
||
width: 100%;
|
||
max-width: 300px;
|
||
overflow: visible;
|
||
|
||
.grid-ring {
|
||
fill: none;
|
||
stroke: var(--g-line);
|
||
stroke-width: 1;
|
||
}
|
||
.axis {
|
||
stroke: var(--g-line);
|
||
stroke-width: 1;
|
||
}
|
||
.axis-label {
|
||
fill: var(--g-sub);
|
||
font-size: 10.5px;
|
||
font-weight: 600;
|
||
}
|
||
.data-poly {
|
||
fill: url(#gosAreaGrad);
|
||
stroke: var(--g-brand);
|
||
stroke-width: 2.2;
|
||
stroke-linejoin: round;
|
||
transform-box: fill-box;
|
||
transform-origin: center;
|
||
animation: gosRadarIn 1.1s cubic-bezier(0.2, 0.9, 0.25, 1.1) 0.5s both;
|
||
}
|
||
.dot {
|
||
fill: var(--g-card);
|
||
stroke: var(--g-brand);
|
||
stroke-width: 2.4;
|
||
animation: gosFadeIn 0.5s ease 1s both;
|
||
}
|
||
}
|
||
.radar-foot {
|
||
display: flex;
|
||
align-items: center;
|
||
justify-content: space-between;
|
||
gap: 10px;
|
||
margin-top: 6px;
|
||
padding-top: 14px;
|
||
border-top: 1px dashed var(--g-line);
|
||
|
||
.n {
|
||
font-size: 22px;
|
||
font-weight: 800;
|
||
letter-spacing: -0.5px;
|
||
|
||
span {
|
||
font-size: 11px;
|
||
color: var(--g-sub);
|
||
font-weight: 600;
|
||
margin-left: 2px;
|
||
}
|
||
}
|
||
.d {
|
||
font-size: 11px;
|
||
color: var(--g-sub);
|
||
text-align: right;
|
||
line-height: 1.55;
|
||
|
||
b {
|
||
color: var(--g-green);
|
||
}
|
||
}
|
||
}
|
||
|
||
/* ---------- path ---------- */
|
||
.path-card {
|
||
grid-column: 1 / -1;
|
||
}
|
||
.path-wrap {
|
||
position: relative;
|
||
margin-top: 26px;
|
||
padding: 0 0 4px;
|
||
}
|
||
.track {
|
||
position: absolute;
|
||
left: 10%;
|
||
right: 10%;
|
||
top: 24px;
|
||
height: 4px;
|
||
border-radius: 99px;
|
||
background: var(--g-soft-2);
|
||
}
|
||
.track-fill {
|
||
height: 100%;
|
||
border-radius: 99px;
|
||
background: var(--g-grad);
|
||
animation: gosXpIn 1.7s cubic-bezier(0.16, 0.84, 0.3, 1) 0.55s both;
|
||
}
|
||
.spark {
|
||
position: absolute;
|
||
top: 50%;
|
||
left: var(--p);
|
||
width: 11px;
|
||
height: 11px;
|
||
margin-left: -5.5px;
|
||
margin-top: -5.5px;
|
||
border-radius: 50%;
|
||
background: #fff;
|
||
border: 2.5px solid var(--g-brand);
|
||
animation:
|
||
gosFadeIn 0.4s ease 1.9s both,
|
||
gosSparkPulse 2.2s ease-out 2s infinite;
|
||
}
|
||
.steps {
|
||
display: grid;
|
||
grid-template-columns: repeat(5, 1fr);
|
||
position: relative;
|
||
}
|
||
.step {
|
||
display: flex;
|
||
flex-direction: column;
|
||
align-items: center;
|
||
text-align: center;
|
||
animation: gosStepIn 0.6s cubic-bezier(0.2, 0.9, 0.3, 1) both;
|
||
animation-delay: calc(var(--i) * 90ms + 0.55s);
|
||
}
|
||
.node {
|
||
width: 48px;
|
||
height: 48px;
|
||
border-radius: 50%;
|
||
display: grid;
|
||
place-items: center;
|
||
background: var(--g-card);
|
||
border: 2px solid var(--g-line);
|
||
color: var(--g-sub);
|
||
position: relative;
|
||
z-index: 2;
|
||
font-size: 11.5px;
|
||
font-weight: 800;
|
||
letter-spacing: 0.3px;
|
||
transition: 0.3s ease;
|
||
|
||
svg {
|
||
width: 19px;
|
||
height: 19px;
|
||
}
|
||
}
|
||
.step {
|
||
&.done .node {
|
||
background: var(--g-grad);
|
||
border-color: transparent;
|
||
color: #fff;
|
||
box-shadow: 0 10px 20px -10px rgba(79, 70, 229, 0.85);
|
||
}
|
||
&.current .node {
|
||
background: var(--g-card);
|
||
color: var(--g-brand);
|
||
border: 2.5px solid var(--g-brand);
|
||
box-shadow: 0 0 0 7px rgba(79, 70, 229, 0.1);
|
||
|
||
&::after {
|
||
content: '';
|
||
position: absolute;
|
||
inset: -2.5px;
|
||
border-radius: 50%;
|
||
border: 2px solid rgba(79, 70, 229, 0.55);
|
||
animation: gosRipple 2.4s ease-out infinite;
|
||
}
|
||
}
|
||
&.locked .node {
|
||
background: var(--g-soft);
|
||
border-style: dashed;
|
||
color: var(--g-sub);
|
||
opacity: 0.85;
|
||
}
|
||
&:hover .node {
|
||
transform: translateY(-2px);
|
||
}
|
||
}
|
||
.step-name {
|
||
margin-top: 13px;
|
||
font-size: 12.5px;
|
||
font-weight: 700;
|
||
letter-spacing: 0.1px;
|
||
}
|
||
.step-desc {
|
||
font-size: 10.5px;
|
||
color: var(--g-sub);
|
||
margin-top: 4px;
|
||
line-height: 1.5;
|
||
padding: 0 6px;
|
||
}
|
||
.step-date {
|
||
margin-top: 8px;
|
||
font-size: 10px;
|
||
font-weight: 700;
|
||
letter-spacing: 0.3px;
|
||
padding: 3px 9px;
|
||
border-radius: 999px;
|
||
background: var(--g-soft);
|
||
color: var(--g-sub);
|
||
border: 1px solid var(--g-line);
|
||
}
|
||
.step {
|
||
&.done .step-date {
|
||
background: rgba(79, 70, 229, 0.09);
|
||
color: var(--g-brand);
|
||
border-color: transparent;
|
||
}
|
||
&.current .step-date {
|
||
background: rgba(16, 185, 129, 0.12);
|
||
color: var(--g-green);
|
||
border-color: transparent;
|
||
}
|
||
}
|
||
.step-prog {
|
||
width: 62px;
|
||
height: 4px;
|
||
border-radius: 99px;
|
||
background: var(--g-soft-2);
|
||
margin-top: 9px;
|
||
overflow: hidden;
|
||
|
||
i {
|
||
display: block;
|
||
height: 100%;
|
||
background: var(--g-grad);
|
||
border-radius: 99px;
|
||
animation: gosXpIn 1.3s ease 1.2s both;
|
||
}
|
||
}
|
||
|
||
/* ---------- badges ---------- */
|
||
.badges {
|
||
grid-column: 1;
|
||
}
|
||
.badge-grid {
|
||
display: grid;
|
||
grid-template-columns: repeat(4, 1fr);
|
||
gap: 10px;
|
||
}
|
||
.badge {
|
||
border: 1px solid var(--g-line);
|
||
border-radius: 15px;
|
||
padding: 14px 8px 12px;
|
||
display: flex;
|
||
flex-direction: column;
|
||
align-items: center;
|
||
gap: 8px;
|
||
background: var(--g-card);
|
||
transition: 0.3s cubic-bezier(0.2, 0.9, 0.3, 1);
|
||
cursor: default;
|
||
position: relative;
|
||
|
||
.disc {
|
||
width: 44px;
|
||
height: 44px;
|
||
border-radius: 50%;
|
||
display: grid;
|
||
place-items: center;
|
||
background: var(--g-grad-soft);
|
||
color: var(--g-brand);
|
||
|
||
svg {
|
||
width: 20px;
|
||
height: 20px;
|
||
}
|
||
}
|
||
.bn {
|
||
font-size: 10.5px;
|
||
font-weight: 600;
|
||
color: var(--g-sub);
|
||
letter-spacing: 0.1px;
|
||
}
|
||
&.unlocked {
|
||
&:hover {
|
||
transform: translateY(-4px);
|
||
border-color: rgba(79, 70, 229, 0.35);
|
||
box-shadow: var(--g-shadow);
|
||
}
|
||
.disc {
|
||
position: relative;
|
||
overflow: hidden;
|
||
|
||
&::after {
|
||
content: '';
|
||
position: absolute;
|
||
inset: 0;
|
||
background: linear-gradient(120deg, transparent 35%, rgba(255, 255, 255, 0.7) 50%, transparent 65%);
|
||
animation: gosSheen 5s ease-in-out infinite;
|
||
}
|
||
}
|
||
}
|
||
&.locked {
|
||
opacity: 0.48;
|
||
filter: grayscale(0.9);
|
||
}
|
||
.new-dot {
|
||
position: absolute;
|
||
top: 9px;
|
||
right: 9px;
|
||
width: 6px;
|
||
height: 6px;
|
||
border-radius: 50%;
|
||
background: var(--g-gold);
|
||
box-shadow: 0 0 0 3px rgba(245, 158, 11, 0.18);
|
||
animation: gosBlink 1.9s ease-in-out infinite;
|
||
}
|
||
}
|
||
|
||
/* ---------- tasks ---------- */
|
||
.tasks {
|
||
grid-column: 2;
|
||
display: flex;
|
||
flex-direction: column;
|
||
}
|
||
.task {
|
||
display: flex;
|
||
gap: 11px;
|
||
align-items: flex-start;
|
||
padding: 11px 0;
|
||
border-bottom: 1px dashed var(--g-line);
|
||
|
||
&:last-of-type {
|
||
border-bottom: 0;
|
||
}
|
||
}
|
||
.tick {
|
||
width: 21px;
|
||
height: 21px;
|
||
border-radius: 50%;
|
||
border: 2px solid var(--g-line);
|
||
flex: 0 0 auto;
|
||
display: grid;
|
||
place-items: center;
|
||
margin-top: 1px;
|
||
color: transparent;
|
||
transition: 0.3s;
|
||
|
||
svg {
|
||
width: 12px;
|
||
height: 12px;
|
||
}
|
||
}
|
||
.task.done .tick {
|
||
background: var(--g-green);
|
||
border-color: var(--g-green);
|
||
color: #fff;
|
||
}
|
||
.task .body {
|
||
flex: 1;
|
||
min-width: 0;
|
||
|
||
.t {
|
||
font-size: 12.5px;
|
||
font-weight: 600;
|
||
display: flex;
|
||
justify-content: space-between;
|
||
gap: 8px;
|
||
|
||
span {
|
||
color: var(--g-brand);
|
||
font-weight: 700;
|
||
font-size: 11px;
|
||
flex: 0 0 auto;
|
||
}
|
||
}
|
||
.s {
|
||
font-size: 10.5px;
|
||
color: var(--g-sub);
|
||
margin-top: 3px;
|
||
}
|
||
}
|
||
.mini {
|
||
height: 5px;
|
||
border-radius: 99px;
|
||
background: var(--g-soft-2);
|
||
margin-top: 7px;
|
||
overflow: hidden;
|
||
|
||
i {
|
||
display: block;
|
||
height: 100%;
|
||
border-radius: 99px;
|
||
background: var(--g-grad);
|
||
animation: gosXpIn 1.4s cubic-bezier(0.2, 0.9, 0.3, 1) 0.8s both;
|
||
}
|
||
}
|
||
.task-cta {
|
||
margin-top: auto;
|
||
padding-top: 14px;
|
||
display: flex;
|
||
align-items: center;
|
||
justify-content: space-between;
|
||
gap: 10px;
|
||
|
||
.txt {
|
||
font-size: 11px;
|
||
color: var(--g-sub);
|
||
line-height: 1.5;
|
||
|
||
b {
|
||
color: var(--g-ink);
|
||
}
|
||
}
|
||
.btn {
|
||
padding: 8px 14px;
|
||
font-size: 12px;
|
||
}
|
||
}
|
||
|
||
/* ---------- 升级弹层 ---------- */
|
||
.levelup {
|
||
position: fixed;
|
||
inset: 0;
|
||
z-index: 1500;
|
||
display: grid;
|
||
place-items: center;
|
||
opacity: 0;
|
||
pointer-events: none;
|
||
transition: opacity 0.35s ease;
|
||
|
||
&.show {
|
||
opacity: 1;
|
||
pointer-events: auto;
|
||
}
|
||
}
|
||
.lu-backdrop {
|
||
position: absolute;
|
||
inset: 0;
|
||
background: rgba(10, 14, 28, 0.42);
|
||
backdrop-filter: blur(7px);
|
||
-webkit-backdrop-filter: blur(7px);
|
||
}
|
||
.lu-card {
|
||
position: relative;
|
||
width: min(400px, 90vw);
|
||
background: var(--g-card);
|
||
border-radius: 26px;
|
||
padding: 32px 26px 24px;
|
||
text-align: center;
|
||
overflow: hidden;
|
||
transform: translateY(18px) scale(0.92);
|
||
opacity: 0;
|
||
transition:
|
||
transform 0.5s cubic-bezier(0.2, 0.9, 0.3, 1.25),
|
||
opacity 0.4s ease;
|
||
box-shadow: 0 40px 90px -26px rgba(12, 16, 36, 0.6);
|
||
|
||
&::before {
|
||
content: '';
|
||
position: absolute;
|
||
left: -40%;
|
||
top: -70%;
|
||
width: 180%;
|
||
height: 150%;
|
||
background: conic-gradient(
|
||
from 0deg,
|
||
transparent 0deg,
|
||
rgba(79, 70, 229, 0.16) 60deg,
|
||
transparent 120deg,
|
||
rgba(6, 182, 212, 0.16) 200deg,
|
||
transparent 260deg
|
||
);
|
||
animation: gosSpin 12s linear infinite;
|
||
pointer-events: none;
|
||
}
|
||
}
|
||
.levelup.show .lu-card {
|
||
transform: none;
|
||
opacity: 1;
|
||
}
|
||
.lu-badge {
|
||
position: relative;
|
||
width: 92px;
|
||
height: 92px;
|
||
margin: 0 auto 16px;
|
||
border-radius: 50%;
|
||
background: var(--g-grad);
|
||
display: grid;
|
||
place-items: center;
|
||
color: #fff;
|
||
font-size: 22px;
|
||
font-weight: 800;
|
||
letter-spacing: 0.5px;
|
||
box-shadow: 0 18px 36px -14px rgba(79, 70, 229, 0.85);
|
||
|
||
&::after {
|
||
content: '';
|
||
position: absolute;
|
||
inset: 0;
|
||
border-radius: 50%;
|
||
border: 2px solid rgba(79, 70, 229, 0.6);
|
||
animation: gosRipple 2.8s ease-out infinite;
|
||
}
|
||
}
|
||
.lu-card {
|
||
h3 {
|
||
margin: 0;
|
||
font-size: 20px;
|
||
letter-spacing: -0.2px;
|
||
}
|
||
.sub {
|
||
margin: 8px 0 0;
|
||
font-size: 12.5px;
|
||
color: var(--g-sub);
|
||
line-height: 1.65;
|
||
|
||
b {
|
||
color: var(--g-brand);
|
||
}
|
||
}
|
||
.btn {
|
||
width: 100%;
|
||
justify-content: center;
|
||
padding: 11px 0;
|
||
font-size: 13px;
|
||
}
|
||
}
|
||
.lu-rewards {
|
||
display: flex;
|
||
gap: 8px;
|
||
justify-content: center;
|
||
margin: 18px 0 20px;
|
||
flex-wrap: wrap;
|
||
}
|
||
.chip {
|
||
font-size: 11px;
|
||
font-weight: 700;
|
||
padding: 7px 12px;
|
||
border-radius: 999px;
|
||
background: var(--g-soft);
|
||
border: 1px solid var(--g-line);
|
||
color: var(--g-ink);
|
||
opacity: 0;
|
||
transform: translateY(8px);
|
||
transition: 0.45s ease;
|
||
|
||
b {
|
||
color: var(--g-brand);
|
||
}
|
||
}
|
||
.levelup.show .chip {
|
||
opacity: 1;
|
||
transform: none;
|
||
|
||
&:nth-child(1) {
|
||
transition-delay: 0.42s;
|
||
}
|
||
&:nth-child(2) {
|
||
transition-delay: 0.52s;
|
||
}
|
||
&:nth-child(3) {
|
||
transition-delay: 0.62s;
|
||
}
|
||
}
|
||
.particles {
|
||
position: absolute;
|
||
inset: 0;
|
||
pointer-events: none;
|
||
overflow: hidden;
|
||
|
||
i {
|
||
position: absolute;
|
||
left: 50%;
|
||
top: 34%;
|
||
width: 7px;
|
||
height: 7px;
|
||
border-radius: 2px;
|
||
background: var(--g-brand);
|
||
opacity: 0;
|
||
animation: gosBurst 1.5s cubic-bezier(0.15, 0.7, 0.3, 1) forwards;
|
||
}
|
||
}
|
||
|
||
/* ---------- 响应式 ---------- */
|
||
@media (max-width: 980px) {
|
||
.grid {
|
||
grid-template-columns: 1fr;
|
||
}
|
||
.hero,
|
||
.radar-card,
|
||
.path-card,
|
||
.badges,
|
||
.tasks {
|
||
grid-column: 1;
|
||
}
|
||
.badge-grid {
|
||
grid-template-columns: repeat(4, 1fr);
|
||
}
|
||
}
|
||
@media (max-width: 620px) {
|
||
.growth-os {
|
||
padding: 14px 10px 18px;
|
||
}
|
||
.card {
|
||
padding: 18px;
|
||
}
|
||
.hero-top {
|
||
flex-direction: column;
|
||
align-items: center;
|
||
text-align: center;
|
||
}
|
||
.who {
|
||
width: 100%;
|
||
}
|
||
.name-row {
|
||
justify-content: center;
|
||
}
|
||
.stats {
|
||
gap: 8px;
|
||
}
|
||
.stat {
|
||
padding: 10px;
|
||
|
||
.v {
|
||
font-size: 17px;
|
||
}
|
||
}
|
||
.badge-grid {
|
||
grid-template-columns: repeat(2, 1fr);
|
||
}
|
||
.steps {
|
||
gap: 0;
|
||
}
|
||
.node {
|
||
width: 38px;
|
||
height: 38px;
|
||
font-size: 10px;
|
||
}
|
||
.step-name {
|
||
font-size: 10.5px;
|
||
}
|
||
.step-desc {
|
||
display: none;
|
||
}
|
||
.step-date {
|
||
font-size: 9px;
|
||
padding: 2px 6px;
|
||
}
|
||
.track {
|
||
top: 19px;
|
||
}
|
||
}
|
||
|
||
/* ---------- 动效降级 ---------- */
|
||
@media (prefers-reduced-motion: reduce) {
|
||
.growth-os *,
|
||
.growth-os *::before,
|
||
.growth-os *::after {
|
||
animation-duration: 0.001ms !important;
|
||
animation-iteration-count: 1 !important;
|
||
transition-duration: 0.001ms !important;
|
||
}
|
||
}
|
||
|
||
/* ---------- 关键帧(scoepd 编译自动加哈希,gos 前缀防撞名) ---------- */
|
||
@keyframes gosCardIn {
|
||
from {
|
||
opacity: 0;
|
||
transform: translateY(14px);
|
||
}
|
||
to {
|
||
opacity: 1;
|
||
transform: none;
|
||
}
|
||
}
|
||
@keyframes gosSheen {
|
||
0%,
|
||
72% {
|
||
transform: translateX(-120%);
|
||
}
|
||
100% {
|
||
transform: translateX(140%);
|
||
}
|
||
}
|
||
@keyframes gosBlink {
|
||
0%,
|
||
100% {
|
||
opacity: 1;
|
||
transform: scale(1);
|
||
}
|
||
50% {
|
||
opacity: 0.35;
|
||
transform: scale(0.8);
|
||
}
|
||
}
|
||
@keyframes gosRingIn {
|
||
from {
|
||
stroke-dashoffset: 289;
|
||
}
|
||
to {
|
||
stroke-dashoffset: 32;
|
||
}
|
||
}
|
||
@keyframes gosXpIn {
|
||
from {
|
||
width: 0;
|
||
}
|
||
to {
|
||
width: var(--p);
|
||
}
|
||
}
|
||
@keyframes gosSweep {
|
||
0% {
|
||
transform: translateX(-130%);
|
||
}
|
||
58%,
|
||
100% {
|
||
transform: translateX(300%);
|
||
}
|
||
}
|
||
@keyframes gosBarGrow {
|
||
from {
|
||
transform: scaleY(0);
|
||
}
|
||
to {
|
||
transform: scaleY(1);
|
||
}
|
||
}
|
||
@keyframes gosRadarIn {
|
||
from {
|
||
transform: scale(0.1);
|
||
opacity: 0;
|
||
}
|
||
to {
|
||
transform: scale(1);
|
||
opacity: 1;
|
||
}
|
||
}
|
||
@keyframes gosFadeIn {
|
||
from {
|
||
opacity: 0;
|
||
}
|
||
to {
|
||
opacity: 1;
|
||
}
|
||
}
|
||
@keyframes gosSparkPulse {
|
||
0% {
|
||
box-shadow: 0 0 0 0 rgba(79, 70, 229, 0.45);
|
||
}
|
||
70% {
|
||
box-shadow: 0 0 0 12px rgba(79, 70, 229, 0);
|
||
}
|
||
100% {
|
||
box-shadow: 0 0 0 0 rgba(79, 70, 229, 0);
|
||
}
|
||
}
|
||
@keyframes gosStepIn {
|
||
from {
|
||
opacity: 0;
|
||
transform: translateY(12px);
|
||
}
|
||
to {
|
||
opacity: 1;
|
||
transform: none;
|
||
}
|
||
}
|
||
@keyframes gosRipple {
|
||
0% {
|
||
transform: scale(1);
|
||
opacity: 0.65;
|
||
}
|
||
75%,
|
||
100% {
|
||
transform: scale(1.5);
|
||
opacity: 0;
|
||
}
|
||
}
|
||
@keyframes gosSpin {
|
||
to {
|
||
transform: rotate(360deg);
|
||
}
|
||
}
|
||
@keyframes gosBurst {
|
||
0% {
|
||
opacity: 1;
|
||
transform: translate(0, 0) scale(0.5) rotate(0);
|
||
}
|
||
100% {
|
||
opacity: 0;
|
||
transform: translate(var(--x), var(--y)) scale(1) rotate(var(--r));
|
||
}
|
||
}
|
||
</style>
|
||
|
||
<style lang="less">
|
||
// 暗色主题微调:表面/文字色已走 TDesign tokens 自动切换,
|
||
// 这里仅覆盖原型中依赖亮色假设的两个变量(非 scoped 以匹配 html 祖先属性)。
|
||
[theme-mode='dark'] .growth-os {
|
||
--g-grad-soft: linear-gradient(135deg, rgba(99, 91, 255, 0.2), rgba(6, 182, 212, 0.16));
|
||
--g-shadow: 0 1px 2px rgba(0, 0, 0, 0.4), 0 22px 46px -24px rgba(0, 0, 0, 0.8);
|
||
}
|
||
</style>
|