/* 游戏容器样式 */
.game-container {
    position: relative;
    width: 100%;
    height: 100vh;
    max-height: 600px;
    margin: 0 auto;
    overflow: hidden;
    background-color: #211522;
    box-shadow: 0 10px 30px rgba(0, 0, 0, 0.2);
    border-radius: 8px;
}

/* 使Canvas充满容器 */
#gameCanvas {
    display: block;
    width: 100%;
    height: 100%;
    background-color: #211522;
}

/* UI元素 */
.game-ui {
    position: absolute;
    top: 10px;
    left: 10px;
    right: 10px;
    display: flex;
    justify-content: space-between;
    color: #fff;
    font-size: 16px;
    font-weight: bold;
    z-index: 10;
    text-shadow: 1px 1px 2px rgba(0, 0, 0, 0.5);
}

.inventory, .clues {
    background-color: rgba(74, 35, 90, 0.8);
    padding: 8px 15px;
    border-radius: 20px;
    backdrop-filter: blur(5px);
}

/* 移动控制 */
.game-controls {
    position: absolute;
    bottom: 20px;
    left: 0;
    right: 0;
    display: flex;
    justify-content: center;
    z-index: 20;
}

.mobile-controls {
    display: flex;
    gap: 15px;
}

.mobile-controls button {
    width: 60px;
    height: 60px;
    background-color: rgba(74, 35, 90, 0.8);
    color: #fff;
    border: none;
    border-radius: 50%;
    font-size: 18px;
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    box-shadow: 0 4px 10px rgba(0, 0, 0, 0.3);
}

#actionBtn {
    width: 100px;
    border-radius: 30px;
}

.mobile-controls button:active {
    transform: scale(0.95);
}

/* 游戏消息 */
.game-message {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background-color: rgba(33, 21, 34, 0.9);
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    color: #fff;
    text-align: center;
    z-index: 100;
}

.game-message h2 {
    font-size: 36px;
    margin-bottom: 15px;
    color: #fff;
    text-shadow: 0 2px 5px rgba(0, 0, 0, 0.3);
}

.game-message p {
    font-size: 18px;
    margin-bottom: 30px;
    color: rgba(255, 255, 255, 0.9);
}

#startBtn {
    background: linear-gradient(to right, #4A235A, #7D3C98);
    color: white;
    border: none;
    border-radius: 30px;
    padding: 12px 30px;
    font-size: 18px;
    cursor: pointer;
    box-shadow: 0 5px 15px rgba(125, 60, 152, 0.4);
    transition: all 0.3s ease;
}

#startBtn:hover {
    transform: translateY(-3px);
    box-shadow: 0 7px 20px rgba(125, 60, 152, 0.5);
}

#startBtn:active {
    transform: translateY(1px);
}

/* 响应式调整 */
@media (max-width: 768px) {
    .game-container {
        height: 70vh;
    }
    
    .mobile-controls button {
        width: 50px;
        height: 50px;
    }
    
    #actionBtn {
        width: 90px;
    }
    
    .game-message h2 {
        font-size: 28px;
    }
    
    .game-message p {
        font-size: 16px;
    }
}

/* 游戏中特殊效果 */
.fade-in {
    animation: fadeIn 0.5s ease forwards;
}

.fade-out {
    animation: fadeOut 0.5s ease forwards;
}

@keyframes fadeIn {
    from { opacity: 0; }
    to { opacity: 1; }
}

@keyframes fadeOut {
    from { opacity: 1; }
    to { opacity: 0; }
}

.room {
    position: absolute;
    left: 0;
    right: 0;
    top: 0;
    bottom: 0;
    background-size: cover;
    background-position: center;
}

.dialog-box {
    position: absolute;
    bottom: 80px;
    left: 50%;
    transform: translateX(-50%);
    width: 90%;
    max-width: 600px;
    background-color: rgba(0, 0, 0, 0.7);
    color: white;
    padding: 15px 20px;
    border-radius: 8px;
    z-index: 30;
    font-size: 16px;
    line-height: 1.5;
    display: none;
}

.interactable {
    position: absolute;
    cursor: pointer;
}

.interactable:hover {
    filter: brightness(1.2);
} 