/* 四个几何角色 - 完整悬浮交互效果 */

/* ========== 通用角色基础 ========== */
.character {
    position: relative;
    display: inline-block;
    cursor: pointer;
    transition: transform 0.3s cubic-bezier(0.68, -0.55, 0.265, 1.55);
    will-change: transform;
}

.character:hover {
    transform: scale(1.15);
    z-index: 10;
}

/* 点击弹跳动画 */
.character:active {
    animation: characterBounce 0.5s cubic-bezier(0.68, -0.55, 0.265, 1.55);
}

@keyframes characterBounce {
    0% { transform: scale(1.15) translateY(0); }
    40% { transform: scale(1.05) translateY(-15px); }
    60% { transform: scale(1.1) translateY(-5px); }
    100% { transform: scale(1.15) translateY(0); }
}

/* ========== 🟣 紫色高个 - Purple Tall ========== */
.character-purple {
    width: 60px;
    height: 100px;
}

.character-purple .body {
    width: 100%;
    height: 100%;
    background: linear-gradient(180deg, var(--purple) 0%, var(--purple-dark) 100%);
    border: 3px solid var(--black);
    border-radius: 30px;
    position: relative;
    transition: all 0.4s cubic-bezier(0.68, -0.55, 0.265, 1.55);
    overflow: visible;
    box-shadow: 4px 4px 0 rgba(0,0,0,0.1);
}

.character-purple .face {
    position: absolute;
    top: 22px;
    left: 50%;
    transform: translateX(-50%);
    width: 40px;
    height: 35px;
}

.character-purple .eye {
    position: absolute;
    width: 10px;
    height: 14px;
    background: var(--black);
    border-radius: 50%;
    top: 0;
    transition: all 0.3s ease;
}

.character-purple .eye.left { left: 5px; }
.character-purple .eye.right { right: 5px; }

.character-purple .mouth {
    position: absolute;
    bottom: 5px;
    left: 50%;
    transform: translateX(-50%);
    width: 18px;
    height: 8px;
    border: 3px solid var(--black);
    border-top: none;
    border-radius: 0 0 15px 15px;
    transition: all 0.3s ease;
}

/* 紫色角色 - 悬浮效果 */
.character-purple:hover .body {
    background: linear-gradient(180deg, var(--purple-light) 0%, var(--purple) 100%);
    border-color: var(--purple-dark);
    box-shadow: 
        0 0 30px rgba(139, 92, 246, 0.5),
        4px 4px 0 rgba(0,0,0,0.1);
    transform: scale(1.05);
}

/* 眼睛变开心 */
.character-purple:hover .eye {
    height: 3px;
    border-radius: 2px;
    top: 6px;
    background: var(--purple-dark);
    box-shadow: 0 0 10px var(--purple);
}

/* 嘴巴变大笑 */
.character-purple:hover .mouth {
    height: 18px;
    width: 28px;
    background: var(--black);
    border-radius: 0 0 25px 25px;
    animation: laugh 0.3s ease-in-out infinite alternate;
}

@keyframes laugh {
    from { transform: translateX(-50%) scaleY(1); }
    to { transform: translateX(-50%) scaleY(0.9); }
}

/* 添加问号气泡 */
.character-purple .question-bubble {
    position: absolute;
    top: -35px;
    right: -15px;
    width: 30px;
    height: 30px;
    background: var(--white);
    border: 3px solid var(--black);
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    font-weight: 900;
    font-size: 16px;
    color: var(--purple);
    opacity: 0;
    transform: scale(0) rotate(-20deg);
    transition: all 0.4s cubic-bezier(0.68, -0.55, 0.265, 1.55);
}

.character-purple .question-bubble::after {
    content: '';
    position: absolute;
    bottom: -8px;
    left: 5px;
    width: 0;
    height: 0;
    border-left: 8px solid transparent;
    border-right: 8px solid transparent;
    border-top: 12px solid var(--black);
}

.character-purple:hover .question-bubble {
    opacity: 1;
    transform: scale(1) rotate(0deg);
    animation: floatBubble 2s ease-in-out infinite;
}

@keyframes floatBubble {
    0%, 100% { transform: translateY(0) rotate(0deg); }
    50% { transform: translateY(-5px) rotate(5deg); }
}

/* ========== 🟠 橙色圆滚滚 - Orange Chubby ========== */
.character-orange {
    width: 90px;
    height: 80px;
}

.character-orange .body {
    width: 100%;
    height: 100%;
    background: linear-gradient(135deg, var(--orange-light) 0%, var(--orange) 100%);
    border: 3px solid var(--black);
    border-radius: 50%;
    position: relative;
    transition: all 0.4s cubic-bezier(0.68, -0.55, 0.265, 1.55);
    box-shadow: 4px 4px 0 rgba(0,0,0,0.1);
}

.character-orange .face {
    position: absolute;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%);
    width: 60px;
    height: 40px;
}

.character-orange .eye {
    position: absolute;
    width: 12px;
    height: 12px;
    background: var(--black);
    border-radius: 50%;
    top: 5px;
    transition: all 0.3s ease;
}

.character-orange .eye.left { left: 10px; }
.character-orange .eye.right { right: 10px; }

.character-orange .blush {
    position: absolute;
    width: 15px;
    height: 8px;
    background: rgba(255, 100, 100, 0.3);
    border-radius: 50%;
    top: 18px;
    transition: all 0.3s ease;
}

.character-orange .blush.left { left: 5px; }
.character-orange .blush.right { right: 5px; }

.character-orange .mouth {
    position: absolute;
    bottom: 2px;
    left: 50%;
    transform: translateX(-50%);
    width: 15px;
    height: 15px;
    background: var(--black);
    border-radius: 50%;
    transition: all 0.3s ease;
}

/* 橙色角色 - 悬浮效果 */
.character-orange:hover .body {
    background: linear-gradient(135deg, #FDBA74 0%, var(--orange-light) 100%);
    box-shadow: 
        0 0 30px rgba(249, 115, 22, 0.4),
        4px 4px 0 rgba(0,0,0,0.1);
    animation: chubbyWiggle 0.5s ease-in-out;
}

@keyframes chubbyWiggle {
    0%, 100% { transform: scale(1, 1); }
    25% { transform: scale(1.05, 0.95); }
    50% { transform: scale(0.95, 1.05); }
    75% { transform: scale(1.02, 0.98); }
}

/* 眼睛变弯月 */
.character-orange:hover .eye {
    height: 6px;
    border-radius: 0 0 12px 12px;
    background: transparent;
    border: 3px solid var(--black);
    border-top: none;
    top: 8px;
}

/* 腮红变深 */
.character-orange:hover .blush {
    background: rgba(255, 100, 100, 0.6);
    transform: scale(1.3);
}

/* 嘴巴变大 */
.character-orange:hover .mouth {
    width: 30px;
    height: 18px;
    background: transparent;
    border: 4px solid var(--black);
    border-top: none;
    border-radius: 0 0 25px 25px;
    animation: bigSmile 0.3s ease-in-out infinite alternate;
}

@keyframes bigSmile {
    from { transform: translateX(-50%) scale(1); }
    to { transform: translateX(-50%) scale(1.05); }
}

/* 添加爱心 */
.character-orange .hearts {
    position: absolute;
    top: -20px;
    left: 50%;
    transform: translateX(-50%);
    opacity: 0;
    transition: all 0.4s ease;
}

.character-orange .hearts::before,
.character-orange .hearts::after {
    content: '💖';
    position: absolute;
    font-size: 20px;
    opacity: 0;
}

.character-orange .hearts::before {
    left: -25px;
    animation: floatHeart1 1.5s ease-in-out infinite;
}

.character-orange .hearts::after {
    right: -25px;
    animation: floatHeart2 1.5s ease-in-out infinite 0.3s;
}

.character-orange:hover .hearts {
    opacity: 1;
}

.character-orange:hover .hearts::before,
.character-orange:hover .hearts::after {
    opacity: 1;
}

@keyframes floatHeart1 {
    0%, 100% { transform: translateY(0) rotate(-10deg) scale(1); }
    50% { transform: translateY(-15px) rotate(10deg) scale(1.2); }
}

@keyframes floatHeart2 {
    0%, 100% { transform: translateY(0) rotate(10deg) scale(1); }
    50% { transform: translateY(-12px) rotate(-10deg) scale(1.1); }
}

/* ========== ⚫ 黑色酷哥 - Black Cool ========== */
.character-black {
    width: 70px;
    height: 70px;
}

.character-black .body {
    width: 100%;
    height: 100%;
    background: linear-gradient(135deg, #2d2d44 0%, var(--black) 100%);
    border: 3px solid var(--black);
    border-radius: 20px;
    position: relative;
    transition: all 0.4s cubic-bezier(0.68, -0.55, 0.265, 1.55);
    overflow: visible;
    box-shadow: 4px 4px 0 rgba(0,0,0,0.2);
}

.character-black .face {
    position: absolute;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%);
    width: 50px;
    height: 35px;
}

.character-black .eye {
    position: absolute;
    width: 14px;
    height: 4px;
    background: var(--white);
    border-radius: 2px;
    top: 12px;
    transition: all 0.3s ease;
}

.character-black .eye.left { left: 5px; }
.character-black .eye.right { right: 5px; }

.character-black .mouth {
    position: absolute;
    bottom: 8px;
    left: 50%;
    transform: translateX(-50%);
    width: 20px;
    height: 3px;
    background: var(--white);
    border-radius: 2px;
    transition: all 0.3s ease;
}

/* 黑色角色 - 悬浮霓虹DJ效果 */
.character-black:hover .body {
    background: linear-gradient(135deg, #3d3d5c 0%, var(--black) 100%);
    border-color: var(--cyan);
    box-shadow: 
        0 0 20px rgba(34, 211, 238, 0.6),
        0 0 40px rgba(34, 211, 238, 0.3),
        4px 4px 0 rgba(0,0,0,0.2);
    animation: neonPulse 1.5s ease-in-out infinite;
}

@keyframes neonPulse {
    0%, 100% { box-shadow: 0 0 20px rgba(34, 211, 238, 0.6), 0 0 40px rgba(34, 211, 238, 0.3), 4px 4px 0 rgba(0,0,0,0.2); }
    50% { box-shadow: 0 0 30px rgba(34, 211, 238, 0.8), 0 0 60px rgba(34, 211, 238, 0.5), 4px 4px 0 rgba(0,0,0,0.2); }
}

/* 眼睛变星星 */
.character-black:hover .eye {
    width: 12px;
    height: 12px;
    background: var(--yellow);
    border-radius: 50%;
    top: 8px;
    box-shadow: 0 0 10px var(--yellow), 0 0 20px var(--orange);
    animation: starBlink 0.6s ease-in-out infinite;
}

@keyframes starBlink {
    0%, 100% { transform: scale(1) rotate(0deg); box-shadow: 0 0 10px var(--yellow), 0 0 20px var(--yellow); }
    50% { transform: scale(1.3) rotate(180deg); box-shadow: 0 0 20px var(--yellow), 0 0 40px var(--orange); }
}

/* 嘴巴变微笑 */
.character-black:hover .mouth {
    width: 26px;
    height: 14px;
    background: transparent;
    border: 3px solid var(--cyan);
    border-top: none;
    border-radius: 0 0 20px 20px;
    box-shadow: 0 2px 10px rgba(34, 211, 238, 0.5);
}

/* 耳机 */
.character-black .headphones {
    position: absolute;
    top: -10px;
    left: 50%;
    transform: translateX(-50%) scale(0);
    width: 80px;
    height: 50px;
    opacity: 0;
    transition: all 0.4s cubic-bezier(0.68, -0.55, 0.265, 1.55);
}

.character-black .headphones::before {
    content: '';
    position: absolute;
    top: 0;
    left: 50%;
    transform: translateX(-50%);
    width: 60px;
    height: 30px;
    border: 4px solid var(--purple);
    border-bottom: none;
    border-radius: 30px 30px 0 0;
}

.character-black .headphones::after {
    content: '';
    position: absolute;
    bottom: 0;
    left: 0;
    width: 18px;
    height: 25px;
    background: var(--purple);
    border: 2px solid var(--white);
    border-radius: 8px;
    box-shadow: 58px 0 0 var(--purple), 58px 0 0 2px var(--white);
}

.character-black:hover .headphones {
    transform: translateX(-50%) scale(1);
    opacity: 1;
    top: -18px;
}

/* 音符 */
.character-black .music-notes {
    position: absolute;
    top: -35px;
    right: -25px;
    opacity: 0;
    transition: all 0.4s ease;
}

.character-black .music-notes::before,
.character-black .music-notes::after {
    content: '♪';
    position: absolute;
    color: var(--pink);
    font-size: 22px;
    font-weight: bold;
    text-shadow: 2px 2px 0 var(--black);
}

.character-black .music-notes::before {
    top: 0;
    right: 0;
    animation: floatNote1 1s ease-in-out infinite;
}

.character-black .music-notes::after {
    content: '♫';
    top: 15px;
    right: 25px;
    animation: floatNote2 1s ease-in-out infinite 0.3s;
}

.character-black:hover .music-notes {
    opacity: 1;
}

@keyframes floatNote1 {
    0%, 100% { transform: translateY(0) rotate(-15deg); }
    50% { transform: translateY(-12px) rotate(15deg); }
}

@keyframes floatNote2 {
    0%, 100% { transform: translateY(0) rotate(15deg); }
    50% { transform: translateY(-10px) rotate(-15deg); }
}

/* ========== 🟡 黄色呆脸 - Yellow Silly ========== */
.character-yellow {
    width: 80px;
    height: 75px;
}

.character-yellow .body {
    width: 100%;
    height: 100%;
    background: linear-gradient(135deg, #FEF9C3 0%, var(--yellow) 100%);
    border: 3px solid var(--black);
    border-radius: 40% 60% 50% 50%;
    position: relative;
    transition: all 0.4s cubic-bezier(0.68, -0.55, 0.265, 1.55);
    box-shadow: 4px 4px 0 rgba(0,0,0,0.1);
    animation: sillyWobble 3s ease-in-out infinite;
}

@keyframes sillyWobble {
    0%, 100% { border-radius: 40% 60% 50% 50%; }
    25% { border-radius: 60% 40% 60% 40%; }
    50% { border-radius: 50% 50% 40% 60%; }
    75% { border-radius: 45% 55% 55% 45%; }
}

.character-yellow .face {
    position: absolute;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%);
    width: 55px;
    height: 40px;
}

.character-yellow .eye {
    position: absolute;
    width: 10px;
    height: 10px;
    background: var(--black);
    border-radius: 50%;
    top: 8px;
    transition: all 0.3s ease;
}

/* 呆呆的错开眼睛 */
.character-yellow .eye.left { 
    left: 10px;
    transform: translateY(-3px);
}

.character-yellow .eye.right { 
    right: 10px;
    transform: translateY(3px);
}

.character-yellow .mouth {
    position: absolute;
    bottom: 5px;
    left: 50%;
    transform: translateX(-50%);
    width: 30px;
    height: 15px;
    border: 3px solid var(--black);
    border-top: none;
    border-radius: 0 0 30px 30px;
    transition: all 0.3s ease;
}

/* 黄色角色 - 悬浮效果 */
.character-yellow:hover .body {
    background: linear-gradient(135deg, var(--yellow) 0%, var(--yellow-dark) 100%);
    box-shadow: 
        0 0 25px rgba(253, 224, 71, 0.6),
        4px 4px 0 rgba(0,0,0,0.1);
    animation: sillySpin 0.6s ease-in-out;
}

@keyframes sillySpin {
    0% { transform: rotate(0deg) scale(1); }
    50% { transform: rotate(10deg) scale(1.05); }
    100% { transform: rotate(0deg) scale(1.05); }
}

/* 眼睛乱转 */
.character-yellow:hover .eye.left {
    transform: translateY(4px) translateX(2px);
}

.character-yellow:hover .eye.right {
    transform: translateY(-4px) translateX(-2px);
}

/* 嘴巴变O型 */
.character-yellow:hover .mouth {
    width: 22px;
    height: 22px;
    background: var(--black);
    border: none;
    border-radius: 50%;
    animation: ohFace 0.5s ease-in-out infinite alternate;
}

@keyframes ohFace {
    from { transform: translateX(-50%) scale(1); }
    to { transform: translateX(-50%) scale(0.9); }
}

/* 添加晕圈 */
.character-yellow .dizzy {
    position: absolute;
    top: -20px;
    left: 50%;
    transform: translateX(-50%) scale(0);
    opacity: 0;
    transition: all 0.4s cubic-bezier(0.68, -0.55, 0.265, 1.55);
}

.character-yellow .dizzy::before {
    content: '💫';
    font-size: 28px;
    animation: spinStar 0.5s linear infinite;
}

.character-yellow:hover .dizzy {
    transform: translateX(-50%) scale(1);
    opacity: 1;
}

@keyframes spinStar {
    from { transform: rotate(0deg); }
    to { transform: rotate(360deg); }
}

/* 添加汗滴 */
.character-yellow .sweat {
    position: absolute;
    top: -10px;
    right: 5px;
    opacity: 0;
    transition: all 0.3s ease;
}

.character-yellow .sweat::before {
    content: '💧';
    font-size: 16px;
    animation: sweatDrop 0.8s ease-in-out infinite;
}

.character-yellow:hover .sweat {
    opacity: 1;
}

@keyframes sweatDrop {
    0%, 100% { transform: translateY(0); }
    50% { transform: translateY(5px); }
}

/* ========== 响应式调整 ========== */
@media (max-width: 768px) {
    .character:hover {
        transform: scale(1.1);
    }
    
    .character-purple:hover .question-bubble,
    .character-orange:hover .hearts,
    .character-black:hover .music-notes,
    .character-yellow:hover .dizzy,
    .character-yellow:hover .sweat {
        display: none;
    }
}
