* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

body {
    font-family: 'Microsoft YaHei', 'PingFang SC', sans-serif;
    background: linear-gradient(135deg, #0a0a1a 0%, #0f1a30 50%, #0a1628 100%);
    min-height: 100vh;
    color: #fff;
    overflow-x: hidden;
}

#game-container {
    max-width: 1400px;
    margin: 0 auto;
    padding: 15px;
    min-height: 100vh;
}

/* 屏幕切换 */
.screen {
    display: none;
    animation: fadeIn 0.5s ease;
}

.screen.active {
    display: block;
}

@keyframes fadeIn {
    from { opacity: 0; transform: translateY(20px); }
    to { opacity: 1; transform: translateY(0); }
}

/* 开始界面 */
#start-screen {
    text-align: center;
    padding-top: 60px;
}

.title h1 {
    font-size: 4rem;
    color: #e94560;
    text-shadow: 0 0 30px rgba(233, 69, 96, 0.6);
    margin-bottom: 10px;
    animation: pulse 2s infinite;
}

.title h2 {
    font-size: 2.5rem;
    color: #fff;
    margin-bottom: 30px;
}

@keyframes pulse {
    0%, 100% { transform: scale(1); }
    50% { transform: scale(1.05); }
}

.story {
    background: rgba(255, 255, 255, 0.08);
    border-radius: 20px;
    padding: 25px;
    max-width: 600px;
    margin: 0 auto 25px;
    backdrop-filter: blur(15px);
    border: 1px solid rgba(255, 255, 255, 0.15);
}

.story p {
    font-size: 1.1rem;
    line-height: 1.8;
    margin-bottom: 12px;
    color: #e0e0e0;
}

/* 难度选择 */
.difficulty-selection {
    background: rgba(255, 255, 255, 0.05);
    border-radius: 20px;
    padding: 25px;
    max-width: 700px;
    margin: 0 auto 25px;
    backdrop-filter: blur(10px);
    border: 1px solid rgba(255, 255, 255, 0.1);
}

.difficulty-selection h3 {
    margin-bottom: 20px;
    font-size: 1.3rem;
    color: #fff;
}

.difficulty-options {
    display: grid;
    grid-template-columns: repeat(2, 1fr);
    gap: 15px;
}

.difficulty-btn {
    background: rgba(255, 255, 255, 0.1);
    border: 2px solid rgba(255, 255, 255, 0.2);
    border-radius: 15px;
    padding: 15px;
    cursor: pointer;
    transition: all 0.3s ease;
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 8px;
    color: #fff;
}

.difficulty-btn:hover {
    background: rgba(255, 255, 255, 0.15);
    transform: translateY(-3px);
}

.difficulty-btn.selected {
    border-color: #e94560;
    background: rgba(233, 69, 96, 0.2);
    box-shadow: 0 0 20px rgba(233, 69, 96, 0.3);
}

.diff-icon {
    font-size: 2rem;
}

.diff-name {
    font-size: 1.2rem;
    font-weight: bold;
}

.diff-desc {
    font-size: 0.85rem;
    color: #aaa;
    text-align: center;
}

.btn-primary {
    background: linear-gradient(135deg, #e94560 0%, #c73e54 100%);
    color: white;
    border: none;
    padding: 18px 50px;
    font-size: 1.4rem;
    border-radius: 50px;
    cursor: pointer;
    transition: all 0.3s ease;
    box-shadow: 0 10px 40px rgba(233, 69, 96, 0.5);
}

.btn-primary:hover {
    transform: translateY(-3px);
    box-shadow: 0 15px 50px rgba(233, 69, 96, 0.7);
}

/* 游戏主界面 */
#game-screen {
    display: none;
}

#game-screen.active {
    display: flex;
    gap: 15px;
}

/* 侧边信息栏 */
#sidebar-info {
    width: 220px;
    flex-shrink: 0;
    background: rgba(0, 0, 0, 0.5);
    border-radius: 20px;
    padding: 20px;
    backdrop-filter: blur(15px);
    border: 1px solid rgba(255, 255, 255, 0.1);
    height: fit-content;
    max-height: calc(100vh - 40px);
    overflow-y: auto;
    position: sticky;
    top: 20px;
}

.sidebar-header {
    display: flex;
    align-items: center;
    gap: 10px;
    margin-bottom: 20px;
    padding-bottom: 15px;
    border-bottom: 2px solid rgba(255, 255, 255, 0.1);
}

.sidebar-icon {
    font-size: 1.8rem;
}

.sidebar-title {
    font-size: 1.2rem;
    font-weight: bold;
    color: #fff;
}

.sidebar-content {
    display: flex;
    flex-direction: column;
    gap: 15px;
}

.info-item {
    background: rgba(255, 255, 255, 0.05);
    border-radius: 15px;
    padding: 15px;
    border: 1px solid rgba(255, 255, 255, 0.1);
    transition: all 0.3s ease;
}

.info-item:hover {
    background: rgba(255, 255, 255, 0.1);
    transform: translateX(5px);
    border-color: rgba(255, 255, 255, 0.2);
}

.info-header {
    display: flex;
    align-items: center;
    gap: 8px;
    margin-bottom: 10px;
}

.info-icon {
    font-size: 1.4rem;
}

.info-name {
    font-size: 0.95rem;
    font-weight: bold;
    color: #fff;
}

.info-value {
    margin-bottom: 8px;
}

.value-number {
    font-size: 1.6rem;
    font-weight: bold;
    color: #ffc107;
}

/* 进度条样式 */
.progress-bar {
    width: 100%;
    height: 8px;
    background: rgba(0, 0, 0, 0.3);
    border-radius: 4px;
    overflow: hidden;
    margin-bottom: 8px;
}

.progress-fill {
    height: 100%;
    border-radius: 4px;
    transition: width 0.5s ease;
    width: 0%;
}

#cure-progress-fill {
    background: linear-gradient(90deg, #00c8ff, #0099ff);
}

#morale-fill {
    background: linear-gradient(90deg, #28a745, #20c997);
}

.info-status {
    font-size: 0.8rem;
    color: #aaa;
    text-align: center;
}

/* 防御等级样式 */
.defense-stats {
    display: flex;
    flex-direction: column;
    gap: 8px;
    margin-top: 10px;
}

.defense-stat {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 6px 10px;
    background: rgba(255, 255, 255, 0.05);
    border-radius: 8px;
}

.stat-label {
    font-size: 0.8rem;
    color: #888;
}

.stat-value {
    font-size: 0.95rem;
    font-weight: bold;
    color: #fff;
}

/* 武器等级样式 */
.weapon-bonus {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-top: 10px;
    padding: 8px 10px;
    background: rgba(233, 69, 96, 0.1);
    border-radius: 8px;
    border: 1px solid rgba(233, 69, 96, 0.3);
}

.bonus-label {
    font-size: 0.8rem;
    color: #aaa;
}

.bonus-value {
    font-size: 0.95rem;
    font-weight: bold;
    color: #e94560;
}

/* 技能列表样式 */
.skills-list {
    display: flex;
    flex-direction: column;
    gap: 6px;
    margin-top: 10px;
}

.skill-item {
    display: flex;
    align-items: center;
    gap: 8px;
    padding: 6px 10px;
    background: rgba(255, 255, 255, 0.05);
    border-radius: 8px;
    font-size: 0.85rem;
}

.skill-item-icon {
    font-size: 1rem;
}

.skill-item-name {
    flex: 1;
    color: #ccc;
}

.skill-item-level {
    font-weight: bold;
    color: #ffc107;
}

/* 主游戏区域 */
#main-game-area {
    flex: 1;
    min-width: 0;
}

/* 顶部信息栏 */
#top-bar {
    display: flex;
    justify-content: space-around;
    background: rgba(0, 0, 0, 0.4);
    border-radius: 15px;
    padding: 12px;
    margin-bottom: 10px;
    backdrop-filter: blur(10px);
    border: 1px solid rgba(255, 255, 255, 0.1);
    flex-wrap: wrap;
    gap: 10px;
}

.stat {
    display: flex;
    align-items: center;
    gap: 8px;
    font-size: 1rem;
    font-weight: bold;
}

.stat .icon {
    font-size: 1.4rem;
}

.difficulty-indicator {
    background: rgba(255, 255, 255, 0.1);
    padding: 5px 12px;
    border-radius: 20px;
    font-size: 0.9rem;
}

/* 警告系统 */
#warning-system {
    margin-bottom: 10px;
}

.warning-banner {
    background: linear-gradient(90deg, #dc3545, #fd7e14);
    border-radius: 10px;
    padding: 12px 20px;
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 10px;
    animation: warningFlash 1s infinite;
    margin-bottom: 10px;
}

@keyframes warningFlash {
    0%, 100% { opacity: 1; box-shadow: 0 0 20px rgba(220, 53, 69, 0.5); }
    50% { opacity: 0.8; box-shadow: 0 0 40px rgba(220, 53, 69, 0.8); }
}

.warning-icon {
    font-size: 1.5rem;
}

.warning-text {
    font-size: 1.1rem;
    font-weight: bold;
}

.warning-bar {
    background: rgba(0, 0, 0, 0.4);
    border-radius: 10px;
    padding: 10px 15px;
    display: flex;
    align-items: center;
    gap: 15px;
}

.warning-label {
    font-size: 0.9rem;
    font-weight: bold;
    white-space: nowrap;
}

.warning-progress {
    flex: 1;
    height: 12px;
    background: rgba(255, 255, 255, 0.1);
    border-radius: 6px;
    overflow: hidden;
}

.warning-fill {
    height: 100%;
    background: linear-gradient(90deg, #28a745, #ffc107, #fd7e14, #dc3545);
    border-radius: 6px;
    transition: width 0.5s ease;
    width: 0%;
}

.hidden {
    display: none !important;
}

/* 世界地图容器 */
#world-map-container {
    background: rgba(0, 0, 0, 0.5);
    border-radius: 20px;
    padding: 20px;
    margin-bottom: 15px;
    backdrop-filter: blur(15px);
    border: 1px solid rgba(255, 255, 255, 0.1);
}

.map-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 15px;
    padding-bottom: 15px;
    border-bottom: 1px solid rgba(255, 255, 255, 0.1);
}

.map-header h3 {
    font-size: 1.3rem;
    color: #fff;
}

.map-legend {
    display: flex;
    gap: 20px;
}

.legend-item {
    display: flex;
    align-items: center;
    gap: 6px;
    font-size: 0.85rem;
    color: #ccc;
}

.legend-item .dot {
    width: 12px;
    height: 12px;
    border-radius: 50%;
    display: inline-block;
}

.dot.safe { background: #28a745; box-shadow: 0 0 8px #28a745; }
.dot.warning { background: #ffc107; box-shadow: 0 0 8px #ffc107; }
.dot.danger { background: #fd7e14; box-shadow: 0 0 8px #fd7e14; }
.dot.critical { background: #dc3545; box-shadow: 0 0 8px #dc3545; }

/* 世界地图视觉区域 */
#world-map-visual {
    display: grid;
    grid-template-columns: 1fr 320px;
    gap: 20px;
    align-items: start;
}

.map-background {
    background: radial-gradient(ellipse at center, #1a2a4a 0%, #0a1628 100%);
    border-radius: 15px;
    overflow: hidden;
    border: 2px solid rgba(255, 255, 255, 0.1);
    box-shadow: inset 0 0 50px rgba(0, 0, 0, 0.5);
}

.world-svg {
    width: 100%;
    height: auto;
    display: block;
}

/* 大陆样式 */
.continent {
    cursor: pointer;
    transition: all 0.4s ease;
}

.continent:hover {
    filter: brightness(1.3);
    transform: scale(1.02);
    transform-origin: center;
}

.continent.selected {
    filter: brightness(1.4) drop-shadow(0 0 15px rgba(255, 255, 255, 0.5));
    stroke-width: 3;
}

/* 安全状态 */
.continent.safe {
    fill: rgba(40, 167, 69, 0.35);
    stroke: rgba(40, 167, 69, 0.8);
}

/* 警戒状态 */
.continent.warning {
    fill: rgba(255, 193, 7, 0.35);
    stroke: rgba(255, 193, 7, 0.8);
    animation: warningPulse 2s infinite;
}

/* 危机状态 */
.continent.danger {
    fill: rgba(253, 126, 20, 0.4);
    stroke: rgba(253, 126, 20, 0.9);
    animation: dangerPulse 1.5s infinite;
}

/* 沦陷状态 */
.continent.critical {
    fill: rgba(220, 53, 69, 0.5);
    stroke: rgba(220, 53, 69, 1);
    animation: criticalPulse 1s infinite;
}

@keyframes warningPulse {
    0%, 100% { filter: brightness(1); }
    50% { filter: brightness(1.3); }
}

@keyframes dangerPulse {
    0%, 100% { filter: brightness(1) drop-shadow(0 0 5px rgba(253, 126, 20, 0.5)); }
    50% { filter: brightness(1.4) drop-shadow(0 0 20px rgba(253, 126, 20, 0.8)); }
}

@keyframes criticalPulse {
    0%, 100% { filter: brightness(1) drop-shadow(0 0 10px rgba(220, 53, 69, 0.6)); }
    50% { filter: brightness(1.5) drop-shadow(0 0 30px rgba(220, 53, 69, 1)); }
}

/* 感染波纹动画 */
.infection-ripple {
    animation: rippleEffect 2s ease-out forwards;
    opacity: 0;
}

@keyframes rippleEffect {
    0% {
        r: 0;
        opacity: 0.8;
        stroke-width: 3;
    }
    100% {
        r: 60;
        opacity: 0;
        stroke-width: 0;
    }
}

/* 攻击动画 */
.attack-line {
    stroke-dasharray: 10;
    animation: attackMove 0.5s linear forwards;
}

@keyframes attackMove {
    0% { stroke-dashoffset: 100; opacity: 1; }
    100% { stroke-dashoffset: 0; opacity: 0; }
}

/* 爆炸效果 */
.explosion {
    animation: explode 0.6s ease-out forwards;
}

@keyframes explode {
    0% {
        r: 0;
        opacity: 1;
    }
    50% {
        r: 30;
        opacity: 0.8;
    }
    100% {
        r: 50;
        opacity: 0;
    }
}

/* 区域标签 */
.region-label {
    pointer-events: none;
    text-shadow: 0 2px 4px rgba(0, 0, 0, 0.8);
    transition: all 0.3s ease;
}

.continent:hover + .region-label,
.continent.selected + .region-label {
    font-size: 16px;
    font-weight: bold;
}

/* 区域卡片 */
.region-cards {
    display: flex;
    flex-direction: column;
    gap: 10px;
}

.region-card {
    background: rgba(255, 255, 255, 0.08);
    border-radius: 12px;
    padding: 12px;
    border: 1px solid rgba(255, 255, 255, 0.1);
    transition: all 0.3s ease;
    cursor: pointer;
}

.region-card:hover {
    background: rgba(255, 255, 255, 0.12);
    transform: translateX(-5px);
}

.region-card.selected {
    border-color: #e94560;
    box-shadow: 0 0 15px rgba(233, 69, 96, 0.3);
    background: rgba(233, 69, 96, 0.1);
}

.region-card.safe { border-left: 4px solid #28a745; }
.region-card.warning { border-left: 4px solid #ffc107; }
.region-card.danger { border-left: 4px solid #fd7e14; }
.region-card.critical { border-left: 4px solid #dc3545; }

.card-header {
    display: flex;
    align-items: center;
    gap: 8px;
    margin-bottom: 8px;
}

.region-icon {
    font-size: 1.3rem;
}

.region-name {
    font-weight: bold;
    flex: 1;
}

.status-badge {
    padding: 3px 10px;
    border-radius: 12px;
    font-size: 0.75rem;
    font-weight: bold;
}

.status-badge.safe { background: #28a745; }
.status-badge.warning { background: #ffc107; color: #000; }
.status-badge.danger { background: #fd7e14; }
.status-badge.critical { background: #dc3545; }

.card-stats {
    display: flex;
    justify-content: space-between;
    margin-bottom: 8px;
}

.mini-stat {
    text-align: center;
}

.mini-stat .label {
    display: block;
    font-size: 0.7rem;
    color: #888;
    margin-bottom: 2px;
}

.mini-stat .value {
    display: block;
    font-size: 0.95rem;
    font-weight: bold;
}

.mini-stat .value.zombie {
    color: #e94560;
}

.threat-bar {
    width: 100%;
    height: 6px;
    background: rgba(0, 0, 0, 0.3);
    border-radius: 3px;
    overflow: hidden;
}

.threat-fill {
    height: 100%;
    background: linear-gradient(90deg, #28a745, #ffc107, #fd7e14, #dc3545);
    border-radius: 3px;
    transition: width 0.5s ease;
    width: 0%;
}

/* 事件日志 */
#event-log {
    background: rgba(0, 0, 0, 0.4);
    border-radius: 15px;
    padding: 15px;
    margin-bottom: 15px;
    max-height: 150px;
    overflow-y: auto;
    backdrop-filter: blur(10px);
    border: 1px solid rgba(255, 255, 255, 0.1);
}

#event-log h3 {
    margin-bottom: 10px;
    color: #e94560;
    font-size: 1rem;
}

#log-content {
    font-size: 0.9rem;
    line-height: 1.5;
}

.log-entry {
    padding: 6px 10px;
    margin-bottom: 4px;
    border-radius: 8px;
    background: rgba(255, 255, 255, 0.05);
    animation: slideIn 0.3s ease;
}

@keyframes slideIn {
    from { opacity: 0; transform: translateX(-20px); }
    to { opacity: 1; transform: translateX(0); }
}

.log-entry.attack {
    background: rgba(233, 69, 96, 0.2);
    border-left: 3px solid #e94560;
}

.log-entry.defense {
    background: rgba(40, 167, 69, 0.2);
    border-left: 3px solid #28a745;
}

.log-entry.resource {
    background: rgba(255, 193, 7, 0.2);
    border-left: 3px solid #ffc107;
}

.log-entry.warning {
    background: rgba(253, 126, 20, 0.2);
    border-left: 3px solid #fd7e14;
}

/* 控制面板 */
#control-panel {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 15px;
}

.action-group {
    background: rgba(255, 255, 255, 0.08);
    border-radius: 15px;
    padding: 15px;
    backdrop-filter: blur(10px);
    border: 1px solid rgba(255, 255, 255, 0.1);
}

.action-group h4 {
    margin-bottom: 12px;
    color: #fff;
    font-size: 1rem;
}

.action-btn {
    width: 100%;
    background: rgba(255, 255, 255, 0.1);
    border: 1px solid rgba(255, 255, 255, 0.2);
    border-radius: 10px;
    padding: 10px;
    margin-bottom: 8px;
    cursor: pointer;
    transition: all 0.3s ease;
    display: flex;
    align-items: center;
    gap: 8px;
    color: #fff;
}

.action-btn:hover {
    background: rgba(255, 255, 255, 0.2);
    transform: translateX(5px);
}

.action-btn:disabled {
    opacity: 0.4;
    cursor: not-allowed;
    transform: none;
}

.action-icon {
    font-size: 1.3rem;
}

.action-name {
    flex: 1;
    text-align: left;
    font-weight: bold;
    font-size: 0.9rem;
}

.action-cost {
    font-size: 0.8rem;
    color: #ffc107;
}

/* 新手提示 */
.tutorial {
    position: fixed;
    bottom: 20px;
    right: 20px;
    background: rgba(0, 150, 200, 0.95);
    border-radius: 15px;
    padding: 15px 20px;
    max-width: 350px;
    box-shadow: 0 10px 40px rgba(0, 0, 0, 0.4);
    z-index: 1000;
    animation: tutorialSlideIn 0.5s ease;
}

@keyframes tutorialSlideIn {
    from { transform: translateX(400px); opacity: 0; }
    to { transform: translateX(0); opacity: 1; }
}

.tutorial.hidden {
    display: none;
}

.tutorial-content {
    display: flex;
    align-items: flex-start;
    gap: 10px;
}

.tutorial-icon {
    font-size: 1.5rem;
}

.tutorial-text {
    flex: 1;
    font-size: 0.95rem;
    line-height: 1.5;
}

.tutorial-close {
    background: none;
    border: none;
    color: #fff;
    font-size: 1.5rem;
    cursor: pointer;
    padding: 0;
    width: 25px;
    height: 25px;
    display: flex;
    align-items: center;
    justify-content: center;
    border-radius: 50%;
    transition: background 0.3s;
}

.tutorial-close:hover {
    background: rgba(255, 255, 255, 0.2);
}

/* 游戏结束界面 */
#game-over-screen {
    text-align: center;
    padding-top: 60px;
}

#result-title {
    font-size: 3.5rem;
    margin-bottom: 20px;
}

#result-title.win {
    color: #28a745;
}

#result-title.lose {
    color: #e94560;
}

#result-message {
    font-size: 1.3rem;
    margin-bottom: 30px;
    color: #e0e0e0;
}

#final-stats {
    background: rgba(255, 255, 255, 0.1);
    border-radius: 15px;
    padding: 30px;
    max-width: 500px;
    margin: 0 auto 20px;
    backdrop-filter: blur(10px);
}

#survival-assessment {
    background: rgba(255, 255, 255, 0.08);
    border-radius: 15px;
    padding: 20px;
    max-width: 500px;
    margin: 0 auto 30px;
    backdrop-filter: blur(10px);
}

.assessment-title {
    font-size: 1.2rem;
    margin-bottom: 15px;
    color: #ffc107;
}

.assessment-item {
    display: flex;
    justify-content: space-between;
    padding: 8px 0;
    border-bottom: 1px solid rgba(255, 255, 255, 0.1);
}

.assessment-item:last-child {
    border-bottom: none;
}

.assessment-grade {
    font-weight: bold;
}

.grade-s { color: #00ff88; }
.grade-a { color: #28a745; }
.grade-b { color: #ffc107; }
.grade-c { color: #fd7e14; }
.grade-d { color: #dc3545; }

.stat-item {
    display: flex;
    justify-content: space-between;
    padding: 10px 0;
    border-bottom: 1px solid rgba(255, 255, 255, 0.1);
}

.stat-item:last-child {
    border-bottom: none;
}

/* 扫描线效果 */
.map-background::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    height: 2px;
    background: linear-gradient(90deg, transparent, rgba(0, 255, 255, 0.5), transparent);
    animation: scanline 4s linear infinite;
    pointer-events: none;
}

@keyframes scanline {
    0% { transform: translateY(0); opacity: 0; }
    10% { opacity: 1; }
    90% { opacity: 1; }
    100% { transform: translateY(500px); opacity: 0; }
}

.map-background {
    position: relative;
}

/* 响应式设计 */
@media (max-width: 1100px) {
    #world-map-visual {
        grid-template-columns: 1fr;
    }
    
    .region-cards {
        flex-direction: row;
        flex-wrap: wrap;
    }
    
    .region-card {
        flex: 1;
        min-width: 200px;
    }
    
    #control-panel {
        grid-template-columns: 1fr;
    }
    
    .difficulty-options {
        grid-template-columns: 1fr;
    }
    
    .title h1 {
        font-size: 2.5rem;
    }
}

@media (max-width: 600px) {
    .region-cards {
        flex-direction: column;
    }
    
    .map-header {
        flex-direction: column;
        gap: 10px;
        align-items: flex-start;
    }
    
    .map-legend {
        flex-wrap: wrap;
    }
    
    .tutorial {
        left: 10px;
        right: 10px;
        max-width: none;
    }
}

/* 滚动条样式 */
::-webkit-scrollbar {
    width: 6px;
}

::-webkit-scrollbar-track {
    background: rgba(0, 0, 0, 0.2);
    border-radius: 3px;
}

::-webkit-scrollbar-thumb {
    background: rgba(233, 69, 96, 0.5);
    border-radius: 3px;
}

::-webkit-scrollbar-thumb:hover {
    background: rgba(233, 69, 96, 0.7);
}

/* 弹窗样式 */
.modal {
    position: fixed;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    display: flex;
    align-items: center;
    justify-content: center;
    z-index: 2000;
    padding: 20px;
}

.modal.hidden {
    display: none !important;
}

.modal-overlay {
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: rgba(0, 0, 0, 0.8);
    backdrop-filter: blur(5px);
    animation: fadeIn 0.3s ease;
}

.modal-content {
    position: relative;
    background: linear-gradient(135deg, #1a1a2e 0%, #16213e 100%);
    border-radius: 20px;
    padding: 30px;
    max-width: 600px;
    width: 100%;
    max-height: 80vh;
    overflow-y: auto;
    border: 2px solid rgba(255, 255, 255, 0.2);
    box-shadow: 0 25px 80px rgba(0, 0, 0, 0.6);
    animation: modalSlideIn 0.5s cubic-bezier(0.34, 1.56, 0.64, 1);
}

@keyframes modalSlideIn {
    0% { transform: scale(0.8) translateY(50px); opacity: 0; }
    100% { transform: scale(1) translateY(0); opacity: 1; }
}

.modal-header {
    display: flex;
    align-items: center;
    gap: 15px;
    margin-bottom: 20px;
    padding-bottom: 15px;
    border-bottom: 1px solid rgba(255, 255, 255, 0.1);
}

.event-type-icon {
    font-size: 2.5rem;
    animation: bounce 1s infinite;
}

@keyframes bounce {
    0%, 100% { transform: translateY(0); }
    50% { transform: translateY(-10px); }
}

.modal-header h2 {
    flex: 1;
    font-size: 1.8rem;
    color: #fff;
}

.day-badge {
    background: rgba(233, 69, 96, 0.3);
    padding: 8px 15px;
    border-radius: 20px;
    font-size: 0.9rem;
    border: 1px solid rgba(233, 69, 96, 0.5);
}

.modal-body {
    color: #e0e0e0;
}

#event-description {
    font-size: 1.1rem;
    line-height: 1.8;
    margin-bottom: 25px;
    padding: 15px;
    background: rgba(255, 255, 255, 0.05);
    border-radius: 10px;
    border-left: 4px solid #e94560;
}

/* 事件选项 */
.event-choices {
    display: flex;
    flex-direction: column;
    gap: 12px;
}

.event-choice {
    background: rgba(255, 255, 255, 0.08);
    border: 2px solid rgba(255, 255, 255, 0.15);
    border-radius: 15px;
    padding: 18px;
    cursor: pointer;
    transition: all 0.3s cubic-bezier(0.34, 1.56, 0.64, 1);
    display: flex;
    align-items: center;
    gap: 15px;
}

.event-choice:hover {
    background: rgba(255, 255, 255, 0.15);
    transform: translateX(10px) scale(1.02);
    border-color: rgba(233, 69, 96, 0.5);
    box-shadow: 0 10px 30px rgba(233, 69, 96, 0.2);
}

.event-choice.positive:hover {
    border-color: rgba(40, 167, 69, 0.5);
    box-shadow: 0 10px 30px rgba(40, 167, 69, 0.2);
}

.event-choice.negative:hover {
    border-color: rgba(220, 53, 69, 0.5);
    box-shadow: 0 10px 30px rgba(220, 53, 69, 0.2);
}

.event-choice.neutral:hover {
    border-color: rgba(255, 193, 7, 0.5);
    box-shadow: 0 10px 30px rgba(255, 193, 7, 0.2);
}

.choice-icon {
    font-size: 2rem;
    width: 50px;
    height: 50px;
    display: flex;
    align-items: center;
    justify-content: center;
    background: rgba(255, 255, 255, 0.1);
    border-radius: 12px;
}

.choice-content {
    flex: 1;
}

.choice-title {
    font-size: 1.1rem;
    font-weight: bold;
    margin-bottom: 5px;
    color: #fff;
}

.choice-desc {
    font-size: 0.9rem;
    color: #aaa;
}

.choice-effect {
    font-size: 0.85rem;
    padding: 5px 12px;
    border-radius: 15px;
    font-weight: bold;
}

.choice-effect.positive {
    background: rgba(40, 167, 69, 0.3);
    color: #28a745;
}

.choice-effect.negative {
    background: rgba(220, 53, 69, 0.3);
    color: #dc3545;
}

.choice-effect.neutral {
    background: rgba(255, 193, 7, 0.3);
    color: #ffc107;
}

/* 技能树样式 */
.skill-tree-content {
    max-width: 700px;
}

.skill-intro {
    font-size: 1.1rem;
    margin-bottom: 20px;
    color: #ffc107;
}

.skill-choices {
    display: grid;
    grid-template-columns: repeat(2, 1fr);
    gap: 15px;
}

.skill-choice {
    background: linear-gradient(135deg, rgba(255, 255, 255, 0.1) 0%, rgba(255, 255, 255, 0.05) 100%);
    border: 2px solid rgba(255, 255, 255, 0.15);
    border-radius: 15px;
    padding: 20px;
    cursor: pointer;
    transition: all 0.4s cubic-bezier(0.34, 1.56, 0.64, 1);
    text-align: center;
}

.skill-choice:hover {
    transform: translateY(-8px) scale(1.03);
    border-color: rgba(255, 193, 7, 0.6);
    box-shadow: 0 15px 40px rgba(255, 193, 7, 0.25);
}

.skill-choice.selected {
    border-color: #ffc107;
    background: rgba(255, 193, 7, 0.15);
}

.skill-icon {
    font-size: 3rem;
    margin-bottom: 10px;
    display: block;
}

.skill-name {
    font-size: 1.2rem;
    font-weight: bold;
    margin-bottom: 8px;
    color: #fff;
}

.skill-desc {
    font-size: 0.9rem;
    color: #aaa;
    margin-bottom: 10px;
}

.skill-level {
    font-size: 0.85rem;
    color: #ffc107;
    font-weight: bold;
}

.modal-close {
    background: rgba(255, 255, 255, 0.1);
    border: none;
    color: #fff;
    font-size: 1.8rem;
    width: 40px;
    height: 40px;
    border-radius: 50%;
    cursor: pointer;
    transition: all 0.3s;
    display: flex;
    align-items: center;
    justify-content: center;
}

.modal-close:hover {
    background: rgba(233, 69, 96, 0.5);
    transform: rotate(90deg);
}

/* 事件结果动画 */
.event-result {
    position: fixed;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%);
    background: rgba(0, 0, 0, 0.95);
    border-radius: 20px;
    padding: 40px;
    text-align: center;
    z-index: 3000;
    border: 2px solid;
    animation: resultPop 0.6s cubic-bezier(0.34, 1.56, 0.64, 1);
}

@keyframes resultPop {
    0% { transform: translate(-50%, -50%) scale(0); opacity: 0; }
    80% { transform: translate(-50%, -50%) scale(1.1); opacity: 1; }
    100% { transform: translate(-50%, -50%) scale(1); opacity: 1; }
}

.event-result.success {
    border-color: #28a745;
    box-shadow: 0 0 60px rgba(40, 167, 69, 0.5);
}

.event-result.fail {
    border-color: #dc3545;
    box-shadow: 0 0 60px rgba(220, 53, 69, 0.5);
}

.result-icon {
    font-size: 4rem;
    margin-bottom: 15px;
    animation: iconPulse 0.5s ease infinite alternate;
}

@keyframes iconPulse {
    0% { transform: scale(1); }
    100% { transform: scale(1.2); }
}

.result-text {
    font-size: 1.5rem;
    font-weight: bold;
    margin-bottom: 10px;
}

.result-detail {
    font-size: 1rem;
    color: #aaa;
}

/* 粒子效果 */
.particle {
    position: fixed;
    pointer-events: none;
    z-index: 2500;
    animation: particleFloat 2s ease-out forwards;
}

@keyframes particleFloat {
    0% {
        transform: translate(0, 0) scale(1);
        opacity: 1;
    }
    100% {
        transform: translate(var(--tx), var(--ty)) scale(0);
        opacity: 0;
    }
}

/* 技能升级特效 */
.skill-upgrade-effect {
    position: fixed;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%);
    width: 300px;
    height: 300px;
    border-radius: 50%;
    background: radial-gradient(circle, rgba(255, 193, 7, 0.8) 0%, transparent 70%);
    z-index: 2500;
    animation: skillUpgradePulse 1s ease-out forwards;
    pointer-events: none;
}

@keyframes skillUpgradePulse {
    0% {
        transform: translate(-50%, -50%) scale(0);
        opacity: 1;
    }
    50% {
        transform: translate(-50%, -50%) scale(1.5);
        opacity: 0.8;
    }
    100% {
        transform: translate(-50%, -50%) scale(2);
        opacity: 0;
    }
}

/* 响应式适配 - 侧边栏 */
@media (max-width: 1200px) {
    #game-screen.active {
        flex-direction: column;
    }
    
    #sidebar-info {
        width: 100%;
        max-height: none;
        position: relative;
        top: 0;
        order: -1;
    }
    
    .sidebar-content {
        flex-direction: row;
        flex-wrap: wrap;
        gap: 10px;
    }
    
    .info-item {
        flex: 1;
        min-width: 200px;
    }
}

@media (max-width: 768px) {
    #sidebar-info {
        padding: 15px;
    }
    
    .sidebar-header {
        margin-bottom: 15px;
        padding-bottom: 10px;
    }
    
    .sidebar-icon {
        font-size: 1.5rem;
    }
    
    .sidebar-title {
        font-size: 1.1rem;
    }
    
    .info-item {
        padding: 12px;
        min-width: 150px;
    }
    
    .value-number {
        font-size: 1.3rem;
    }
    
    .info-icon {
        font-size: 1.2rem;
    }
    
    .info-name {
        font-size: 0.9rem;
    }
}

@media (max-width: 480px) {
    .sidebar-content {
        flex-direction: column;
    }
    
    .info-item {
        min-width: auto;
    }
    
    .defense-stats {
        flex-direction: row;
        gap: 10px;
    }
    
    .defense-stat {
        flex: 1;
    }
}

/* ==================== 肾上腺素特效系统 ==================== */

/* 屏幕震动效果 */
@keyframes screenShake {
    0%, 100% { transform: translate(0, 0); }
    10% { transform: translate(-5px, -5px); }
    20% { transform: translate(5px, 5px); }
    30% { transform: translate(-5px, 5px); }
    40% { transform: translate(5px, -5px); }
    50% { transform: translate(-3px, 3px); }
    60% { transform: translate(3px, -3px); }
    70% { transform: translate(-2px, 2px); }
    80% { transform: translate(2px, -2px); }
    90% { transform: translate(-1px, 1px); }
}

.shake-effect {
    animation: screenShake 0.5s ease-in-out;
}

/* 心跳效果 */
#heartbeat-overlay {
    position: fixed;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%);
    width: 100vw;
    height: 100vh;
    pointer-events: none;
    z-index: 1500;
    display: flex;
    align-items: center;
    justify-content: center;
}

.heartbeat-ring {
    position: absolute;
    border-radius: 50%;
    border: 3px solid rgba(233, 69, 96, 0.8);
    animation: heartbeat 1.5s ease-out infinite;
}

.heartbeat-ring:nth-child(1) {
    width: 200px;
    height: 200px;
    animation-delay: 0s;
}

.heartbeat-ring:nth-child(2) {
    width: 300px;
    height: 300px;
    animation-delay: 0.3s;
}

.heartbeat-ring:nth-child(3) {
    width: 400px;
    height: 400px;
    animation-delay: 0.6s;
}

@keyframes heartbeat {
    0% {
        transform: scale(0.8);
        opacity: 0.8;
        border-width: 3px;
    }
    50% {
        transform: scale(1);
        opacity: 0.4;
        border-width: 5px;
    }
    100% {
        transform: scale(1.2);
        opacity: 0;
        border-width: 1px;
    }
}

/* 战斗狂热模式 */
#combat-frenzy {
    position: fixed;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    pointer-events: none;
    z-index: 1400;
}

.frenzy-border {
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    border: 10px solid transparent;
    border-image: linear-gradient(45deg, #ff0000, #ff6600, #ff0000) 1;
    animation: frenzyPulse 0.5s ease-in-out infinite;
    box-shadow: inset 0 0 50px rgba(255, 0, 0, 0.5);
}

@keyframes frenzyPulse {
    0%, 100% {
        border-image: linear-gradient(45deg, #ff0000, #ff6600, #ff0000) 1;
        box-shadow: inset 0 0 30px rgba(255, 0, 0, 0.5);
    }
    50% {
        border-image: linear-gradient(45deg, #ff6600, #ff0000, #ff6600) 1;
        box-shadow: inset 0 0 60px rgba(255, 100, 0, 0.8);
    }
}

.frenzy-text {
    position: absolute;
    top: 20%;
    left: 50%;
    transform: translateX(-50%);
    font-size: 3rem;
    font-weight: bold;
    color: #ff0000;
    text-shadow: 0 0 20px rgba(255, 0, 0, 0.8);
    animation: frenzyText 0.5s ease-in-out infinite;
}

@keyframes frenzyText {
    0%, 100% {
        transform: translateX(-50%) scale(1);
        text-shadow: 0 0 20px rgba(255, 0, 0, 0.8);
    }
    50% {
        transform: translateX(-50%) scale(1.1);
        text-shadow: 0 0 40px rgba(255, 100, 0, 1);
    }
}

/* 连击计数器 */
#combo-counter {
    position: fixed;
    top: 15%;
    right: 5%;
    z-index: 1600;
    text-align: center;
    animation: comboPop 0.3s ease-out;
}

.combo-number {
    font-size: 5rem;
    font-weight: bold;
    color: #ffc107;
    text-shadow: 0 0 30px rgba(255, 193, 7, 0.8);
    animation: comboNumber 0.5s ease-in-out;
}

@keyframes comboNumber {
    0% { transform: scale(0.5); opacity: 0; }
    50% { transform: scale(1.3); }
    100% { transform: scale(1); opacity: 1; }
}

.combo-text {
    font-size: 1.5rem;
    color: #fff;
    text-transform: uppercase;
    letter-spacing: 5px;
}

/* 成就解锁提示 */
#achievement-popup {
    position: fixed;
    top: 10%;
    left: 50%;
    transform: translateX(-50%);
    background: linear-gradient(135deg, #ffd700, #ffed4e);
    border-radius: 20px;
    padding: 25px 40px;
    display: flex;
    align-items: center;
    gap: 20px;
    z-index: 2000;
    box-shadow: 0 20px 60px rgba(255, 215, 0, 0.5);
    animation: achievementSlide 0.6s cubic-bezier(0.34, 1.56, 0.64, 1);
}

@keyframes achievementSlide {
    0% {
        transform: translateX(-50%) translateY(-100px);
        opacity: 0;
    }
    60% {
        transform: translateX(-50%) translateY(20px);
    }
    100% {
        transform: translateX(-50%) translateY(0);
        opacity: 1;
    }
}

.achievement-icon {
    font-size: 3rem;
    animation: achievementIcon 1s ease-in-out infinite;
}

@keyframes achievementIcon {
    0%, 100% { transform: rotate(-10deg) scale(1); }
    50% { transform: rotate(10deg) scale(1.1); }
}

.achievement-content {
    color: #333;
}

.achievement-title {
    font-size: 0.9rem;
    font-weight: bold;
    text-transform: uppercase;
    letter-spacing: 2px;
    margin-bottom: 5px;
}

.achievement-name {
    font-size: 1.4rem;
    font-weight: bold;
}

/* 肾上腺素计量条 */
#adrenaline-meter {
    position: fixed;
    bottom: 30px;
    right: 30px;
    background: rgba(0, 0, 0, 0.8);
    border-radius: 15px;
    padding: 15px 20px;
    z-index: 1500;
    border: 2px solid rgba(255, 100, 0, 0.5);
    box-shadow: 0 10px 40px rgba(0, 0, 0, 0.5);
}

.meter-label {
    font-size: 0.9rem;
    font-weight: bold;
    color: #ff6600;
    margin-bottom: 8px;
    display: flex;
    align-items: center;
    gap: 5px;
}

.meter-bar {
    width: 200px;
    height: 12px;
    background: rgba(255, 255, 255, 0.1);
    border-radius: 6px;
    overflow: hidden;
    position: relative;
}

.meter-fill {
    height: 100%;
    background: linear-gradient(90deg, #ff6600, #ff0000);
    border-radius: 6px;
    transition: width 0.3s ease;
    width: 0%;
    position: relative;
}

.meter-fill::after {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: linear-gradient(90deg, transparent, rgba(255, 255, 255, 0.3), transparent);
    animation: meterShine 1s ease-in-out infinite;
}

@keyframes meterShine {
    0% { transform: translateX(-100%); }
    100% { transform: translateX(100%); }
}

.meter-value {
    font-size: 0.85rem;
    color: #ff6600;
    text-align: right;
    margin-top: 5px;
    font-weight: bold;
}

/* 动态背景效果 */
#dynamic-background {
    position: fixed;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    pointer-events: none;
    z-index: 5;
    overflow: hidden;
}

.bg-pulse {
    position: absolute;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%);
    width: 200%;
    height: 200%;
    background: radial-gradient(circle, rgba(233, 69, 96, 0.1) 0%, transparent 50%);
    animation: bgPulse 2s ease-in-out infinite;
}

@keyframes bgPulse {
    0%, 100% {
        transform: translate(-50%, -50%) scale(1);
        opacity: 0.3;
    }
    50% {
        transform: translate(-50%, -50%) scale(1.2);
        opacity: 0.6;
    }
}

/* 危险闪烁效果 */
#danger-flash {
    position: fixed;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: rgba(255, 0, 0, 0.3);
    pointer-events: none;
    z-index: 1300;
    animation: dangerFlash 0.5s ease-in-out;
}

@keyframes dangerFlash {
    0%, 100% { opacity: 0; }
    50% { opacity: 1; }
}

/* 完美时机提示 */
#perfect-timing {
    position: fixed;
    top: 30%;
    left: 50%;
    transform: translateX(-50%);
    text-align: center;
    z-index: 1700;
    animation: perfectPop 0.8s ease-out;
}

@keyframes perfectPop {
    0% {
        transform: translateX(-50%) scale(0);
        opacity: 0;
    }
    50% {
        transform: translateX(-50%) scale(1.3);
    }
    100% {
        transform: translateX(-50%) scale(1);
        opacity: 1;
    }
}

.perfect-text {
    font-size: 4rem;
    font-weight: bold;
    color: #00ff88;
    text-shadow: 0 0 30px rgba(0, 255, 136, 0.8);
    animation: perfectGlow 0.5s ease-in-out infinite alternate;
}

@keyframes perfectGlow {
    0% { text-shadow: 0 0 30px rgba(0, 255, 136, 0.8); }
    100% { text-shadow: 0 0 50px rgba(0, 255, 136, 1); }
}

.perfect-bonus {
    font-size: 1.5rem;
    color: #ffc107;
    margin-top: 10px;
}

/* 按钮点击反馈 */
.action-btn:active {
    transform: scale(0.95);
    transition: transform 0.1s;
}

.action-btn::after {
    content: '';
    position: absolute;
    top: 50%;
    left: 50%;
    width: 0;
    height: 0;
    background: rgba(255, 255, 255, 0.3);
    border-radius: 50%;
    transform: translate(-50%, -50%);
    transition: width 0.3s, height 0.3s;
}

.action-btn:active::after {
    width: 200px;
    height: 200px;
}

/* 资源增加动画 */
.resource-gain {
    position: fixed;
    font-size: 1.5rem;
    font-weight: bold;
    color: #28a745;
    z-index: 1800;
    animation: resourceFloat 1s ease-out forwards;
    pointer-events: none;
}

@keyframes resourceFloat {
    0% {
        transform: translateY(0);
        opacity: 1;
    }
    100% {
        transform: translateY(-50px);
        opacity: 0;
    }
}

/* 暴击效果 */
.critical-hit {
    position: fixed;
    font-size: 3rem;
    font-weight: bold;
    color: #ff0000;
    text-shadow: 0 0 20px rgba(255, 0, 0, 0.8);
    z-index: 1800;
    animation: criticalPop 0.8s ease-out forwards;
    pointer-events: none;
}

@keyframes criticalPop {
    0% {
        transform: scale(0) rotate(-20deg);
        opacity: 0;
    }
    30% {
        transform: scale(1.5) rotate(10deg);
        opacity: 1;
    }
    100% {
        transform: scale(1) rotate(0deg) translateY(-30px);
        opacity: 0;
    }
}

/* 连击数字颜色变化 */
.combo-low { color: #28a745; }
.combo-medium { color: #ffc107; }
.combo-high { color: #ff6600; }
.combo-extreme { color: #ff0000; animation: comboExtreme 0.3s ease-in-out infinite; }

@keyframes comboExtreme {
    0%, 100% { transform: scale(1); }
    50% { transform: scale(1.1); }
}

/* ==================== 人口撤离系统样式 ==================== */

/* 撤离目标选择 */
.evacuation-targets {
    display: flex;
    flex-direction: column;
    gap: 10px;
    margin-top: 15px;
}

.evacuation-target {
    display: flex;
    align-items: center;
    gap: 15px;
    padding: 15px;
    background: rgba(255, 255, 255, 0.1);
    border-radius: 12px;
    cursor: pointer;
    transition: all 0.3s ease;
    border: 2px solid transparent;
}

.evacuation-target:hover {
    background: rgba(255, 255, 255, 0.15);
    transform: translateX(10px);
}

.evacuation-target.safe {
    border-color: rgba(40, 167, 69, 0.5);
}

.evacuation-target.safe:hover {
    border-color: #28a745;
    box-shadow: 0 0 20px rgba(40, 167, 69, 0.3);
}

.evacuation-target.infected {
    border-color: rgba(220, 53, 69, 0.5);
    opacity: 0.7;
}

.evacuation-target.infected:hover {
    border-color: #dc3545;
    box-shadow: 0 0 20px rgba(220, 53, 69, 0.3);
}

.target-icon {
    font-size: 1.5rem;
}

.target-name {
    flex: 1;
    font-weight: bold;
    font-size: 1.1rem;
}

.target-pop {
    font-size: 0.9rem;
    color: #aaa;
}

.target-status {
    padding: 5px 12px;
    border-radius: 15px;
    font-size: 0.8rem;
    font-weight: bold;
}

.evacuation-target.safe .target-status {
    background: rgba(40, 167, 69, 0.3);
    color: #28a745;
}

.evacuation-target.infected .target-status {
    background: rgba(220, 53, 69, 0.3);
    color: #dc3545;
}

/* 撤离成功动画 */
@keyframes evacuationSuccessPop {
    0% {
        transform: translate(-50%, -50%) scale(0);
        opacity: 0;
    }
    50% {
        transform: translate(-50%, -50%) scale(1.2);
    }
    100% {
        transform: translate(-50%, -50%) scale(1);
        opacity: 1;
    }
}

.evacuation-success {
    animation: evacuationSuccessPop 0.6s ease-out;
}

.evacuation-success .success-icon {
    font-size: 3rem;
    margin-bottom: 10px;
}

.evacuation-success .success-text {
    font-size: 1.5rem;
    font-weight: bold;
    color: #fff;
}

.evacuation-success .success-count {
    font-size: 1.2rem;
    color: #28a745;
    margin-top: 5px;
}

/* 撤离失败动画 */
@keyframes evacuationFailPop {
    0% {
        transform: translate(-50%, -50%) scale(0) rotate(-10deg);
        opacity: 0;
    }
    50% {
        transform: translate(-50%, -50%) scale(1.1) rotate(5deg);
    }
    100% {
        transform: translate(-50%, -50%) scale(1) rotate(0deg);
        opacity: 1;
    }
}

.evacuation-fail {
    animation: evacuationFailPop 0.6s ease-out;
}

.evacuation-fail .fail-icon {
    font-size: 3rem;
    margin-bottom: 10px;
}

.evacuation-fail .fail-text {
    font-size: 1.5rem;
    font-weight: bold;
    color: #fff;
}
