/* 基础样式 */
#scene-viewport {
    user-select: none;
    background-color: #000;
    height: 560px;
    max-height: 75vh;
    position: relative;
    overflow: hidden;
}

/* 热点样式 */
.hotspot {
    position: absolute;
    width: 34px;
    height: 34px;
    background: #3b82f6;
    color: white;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    font-weight: bold;
    cursor: pointer;
    box-shadow: 0 0 0 4px rgba(59, 130, 246, 0.3), 0 4px 6px -1px rgba(0, 0, 0, 0.1);
    transition: all 0.3s cubic-bezier(0.175, 0.885, 0.32, 1.275);
    z-index: 10;
    transform: translate(-50%, -50%);
    font-size: 14px;
    border: 2px solid white;
}

.hotspot:hover {
    transform: translate(-50%, -50%) scale(1.15);
    box-shadow: 0 0 0 8px rgba(59, 130, 246, 0.2), 0 10px 15px -3px rgba(0, 0, 0, 0.1);
    background: #2563eb;
}

.hotspot.active {
    background: #ef4444;
    box-shadow: 0 0 0 6px rgba(239, 68, 68, 0.3);
    border-color: #fee2e2;
}

/* 播放模式下的热点波动效果 */
.playing .hotspot::after {
    content: '';
    position: absolute;
    width: 100%;
    height: 100%;
    border-radius: 50%;
    background: inherit;
    opacity: 0.6;
    animation: pulse 2s infinite;
}

@keyframes pulse {
    0% { transform: scale(1); opacity: 0.6; }
    100% { transform: scale(2.5); opacity: 0; }
}

/* 场景标签样式 */
.scene-tab {
    flex: 0 0 auto;
    padding: 6px 12px;
    border-radius: 6px;
    background: #f3f4f6;
    color: #4b5563;
    font-size: 12px;
    font-weight: 500;
    cursor: pointer;
    border: 1px solid #e5e7eb;
    transition: all 0.2s;
    display: flex;
    align-items: center;
    gap: 6px;
}

.scene-tab.active {
    background: #3b82f6;
    color: white;
    border-color: #2563eb;
    box-shadow: 0 2px 4px rgba(59, 130, 246, 0.3);
}

.scene-tab:hover:not(.active) {
    background: #e5e7eb;
}

.scene-tab i {
    cursor: pointer;
    transition: color 0.2s;
}

.scene-tab i:hover {
    color: #ef4444;
}

/* 自定义滚动条样式 */
.custom-scrollbar::-webkit-scrollbar {
    width: 8px;
}
.custom-scrollbar::-webkit-scrollbar-track {
    background: rgba(0, 0, 0, 0.05);
    border-radius: 4px;
}
.custom-scrollbar::-webkit-scrollbar-thumb {
    background: rgba(0, 0, 0, 0.2);
    border-radius: 4px;
}
.custom-scrollbar::-webkit-scrollbar-thumb:hover {
    background: rgba(0, 0, 0, 0.3);
}

/* 回合标签样式 */
.step-tab {
    padding: 4px 10px;
    border-radius: 4px;
    background: white;
    border: 1px solid #e5e7eb;
    font-size: 10px;
    cursor: pointer;
    transition: all 0.2s;
}

.step-tab.active {
    background: #3b82f6;
    color: white;
    border-color: #2563eb;
}

/* 遮罩层动画 */
#player-overlay.show {
    display: flex;
}

#player-overlay.show #dialogue-box {
    transform: scale(1);
    opacity: 1;
}

/* 播放器对话框微调 */
#dialogue-box {
    box-shadow: 0 25px 50px -12px rgba(0, 0, 0, 0.5);
    border: 1px solid rgba(255, 255, 255, 0.3);
}

#btn-next-step {
    transition: all 0.3s cubic-bezier(0.175, 0.885, 0.32, 1.275);
}

#btn-next-step:hover {
    transform: scale(1.1) rotate(5deg);
}

/* 响应式调整 */
#scene-container {
    max-width: 100%;
    max-height: 100%;
}

/* 滚动条美化 */
::-webkit-scrollbar {
    width: 5px;
    height: 5px;
}
::-webkit-scrollbar-track {
    background: transparent;
}
::-webkit-scrollbar-thumb {
    background: #d1d5db;
    border-radius: 10px;
}
::-webkit-scrollbar-thumb:hover {
    background: #9ca3af;
}

/* 动画类 */
.animate-correct {
    animation: correct-pop 0.5s ease-out;
}

.animate-wrong {
    animation: wrong-shake 0.4s ease-in-out;
}

@keyframes correct-pop {
    0% { transform: scale(1); }
    50% { transform: scale(1.05); filter: brightness(1.1); }
    100% { transform: scale(1); }
}

@keyframes wrong-shake {
    0%, 100% { transform: translateX(0); }
    25% { transform: translateX(-8px); }
    50% { transform: translateX(8px); }
    75% { transform: translateX(-4px); }
}

/* 选项编辑器样式 */
.opt-text-input {
    background: rgba(255, 255, 255, 0.8);
    transition: all 0.2s;
}

.opt-text-input:focus {
    background: #fff;
    box-shadow: 0 0 0 2px rgba(59, 130, 246, 0.2);
}

/* 隐藏单选框默认样式，增加美观度 (可选) */
input[type="radio"] {
    cursor: pointer;
    width: 16px;
    height: 16px;
}

/* 全屏模式下的背景修正 */
:fullscreen #scene-viewport {
    width: 100vw;
    height: 100vh;
}
