/* 重置和基础样式 */
* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

body {
    font-family: 'Exo 2', sans-serif;
    overflow: hidden;
    background: #000;
    height: 100vh;
    position: relative;
}

/* 星空背景 */
.stars-container {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    z-index: 1;
}

.stars, .stars2, .stars3 {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: transparent;
}

.stars {
    background-image: 
        radial-gradient(2px 2px at 20px 30px, #eee, transparent),
        radial-gradient(2px 2px at 40px 70px, rgba(255,255,255,0.8), transparent),
        radial-gradient(1px 1px at 90px 40px, #fff, transparent),
        radial-gradient(1px 1px at 130px 80px, rgba(255,255,255,0.6), transparent),
        radial-gradient(2px 2px at 160px 30px, #ddd, transparent);
    background-repeat: repeat;
    background-size: 200px 100px;
    animation: sparkle 3s linear infinite;
}

.stars2 {
    background-image: 
        radial-gradient(1px 1px at 40px 60px, #fff, transparent),
        radial-gradient(1px 1px at 120px 10px, rgba(255,255,255,0.7), transparent),
        radial-gradient(1px 1px at 170px 50px, #eee, transparent);
    background-repeat: repeat;
    background-size: 250px 120px;
    animation: sparkle 2s linear infinite reverse;
}

.stars3 {
    background-image: 
        radial-gradient(1px 1px at 60px 90px, rgba(255,255,255,0.5), transparent),
        radial-gradient(2px 2px at 100px 20px, #fff, transparent),
        radial-gradient(1px 1px at 150px 70px, rgba(255,255,255,0.8), transparent);
    background-repeat: repeat;
    background-size: 300px 150px;
    animation: sparkle 4s linear infinite;
}

@keyframes sparkle {
    0%, 100% { opacity: 1; }
    50% { opacity: 0.5; }
}

/* 火星地表 */
.mars-surface {
    position: absolute;
    bottom: 0;
    left: 0;
    width: 100%;
    height: 40%;
    z-index: 2;
}

.surface-layer {
    position: absolute;
    bottom: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: linear-gradient(
        to top,
        #8B4513 0%,
        #CD853F 20%,
        #D2691E 40%,
        #A0522D 60%,
        rgba(139, 69, 19, 0.8) 80%,
        rgba(139, 69, 19, 0.4) 100%
    );
    border-radius: 50% 50% 0 0 / 20% 20% 0 0;
}

.rocks {
    position: absolute;
    bottom: 0;
    left: 0;
    width: 100%;
    height: 100%;
}

.rock {
    position: absolute;
    background: #654321;
    border-radius: 50%;
    box-shadow: inset -5px -5px 10px rgba(0,0,0,0.5);
}

.rock1 {
    width: 60px;
    height: 40px;
    bottom: 15%;
    left: 10%;
    transform: rotate(-15deg);
}

.rock2 {
    width: 80px;
    height: 50px;
    bottom: 20%;
    left: 70%;
    transform: rotate(25deg);
}

.rock3 {
    width: 40px;
    height: 30px;
    bottom: 10%;
    left: 30%;
}

.rock4 {
    width: 50px;
    height: 35px;
    bottom: 25%;
    left: 85%;
    transform: rotate(-30deg);
}

.rock5 {
    width: 35px;
    height: 25px;
    bottom: 12%;
    left: 50%;
    transform: rotate(45deg);
}

/* 太空飞船 */
.spacecraft {
    position: absolute;
    top: -200px;
    left: 50%;
    transform: translateX(-50%);
    z-index: 10;
    transition: all 4s cubic-bezier(0.25, 0.46, 0.45, 0.94);
}

.spacecraft.landing {
    top: 45%;
    animation: landingShake 0.5s ease-in-out 3.5s;
}

@keyframes landingShake {
    0%, 100% { transform: translateX(-50%) translateY(0); }
    25% { transform: translateX(-50%) translateY(-5px); }
    75% { transform: translateX(-50%) translateY(5px); }
}

.ship-body {
    position: relative;
    width: 120px;
    height: 180px;
}

.ship-top {
    width: 60px;
    height: 60px;
    background: linear-gradient(135deg, #c0c0c0, #808080);
    border-radius: 50% 50% 20% 20%;
    margin: 0 auto;
    box-shadow: 
        0 0 20px rgba(64, 158, 255, 0.5),
        inset 5px 5px 10px rgba(255,255,255,0.3);
}

.ship-middle {
    width: 100px;
    height: 80px;
    background: linear-gradient(135deg, #e0e0e0, #a0a0a0);
    margin: 0 auto;
    border-radius: 10px;
    position: relative;
    box-shadow: 
        0 0 30px rgba(64, 158, 255, 0.3),
        inset 3px 3px 8px rgba(255,255,255,0.4);
}

.window {
    width: 40px;
    height: 40px;
    background: radial-gradient(circle, #4a9eff 0%, #0066cc 100%);
    border-radius: 50%;
    position: absolute;
    top: 20px;
    left: 50%;
    transform: translateX(-50%);
    box-shadow: 
        0 0 15px rgba(74, 158, 255, 0.8),
        inset 2px 2px 5px rgba(255,255,255,0.5);
}

.ship-details {
    position: absolute;
    bottom: 10px;
    left: 50%;
    transform: translateX(-50%);
}

.detail-line {
    width: 60px;
    height: 2px;
    background: #4a9eff;
    margin: 3px 0;
    box-shadow: 0 0 5px rgba(74, 158, 255, 0.8);
}

.ship-bottom {
    width: 120px;
    height: 40px;
    background: linear-gradient(135deg, #b0b0b0, #707070);
    margin: 0 auto;
    border-radius: 0 0 20px 20px;
    position: relative;
    display: flex;
    justify-content: space-around;
    align-items: flex-end;
    box-shadow: 
        0 0 25px rgba(64, 158, 255, 0.4),
        inset 2px 2px 6px rgba(255,255,255,0.3);
}

.thruster {
    width: 20px;
    height: 15px;
    background: #333;
    border-radius: 0 0 50% 50%;
    position: relative;
    overflow: hidden;
}

.flame {
    position: absolute;
    bottom: -30px;
    left: 50%;
    transform: translateX(-50%);
    width: 15px;
    height: 40px;
    background: linear-gradient(to top, 
        #ff4500 0%, 
        #ff6500 30%, 
        #ffaa00 60%, 
        #ffff00 100%);
    border-radius: 50% 50% 0 0;
    opacity: 0;
    animation: flameFlicker 0.1s infinite alternate;
}

.spacecraft.landing .flame {
    opacity: 1;
    animation: flameFlicker 0.1s infinite alternate, flamePulse 0.3s infinite;
}

@keyframes flameFlicker {
    0% { transform: translateX(-50%) scaleY(1) scaleX(1); }
    100% { transform: translateX(-50%) scaleY(1.2) scaleX(0.8); }
}

@keyframes flamePulse {
    0%, 100% { height: 40px; opacity: 1; }
    50% { height: 60px; opacity: 0.8; }
}

.landing-legs {
    position: absolute;
    bottom: -20px;
    left: 50%;
    transform: translateX(-50%);
    width: 140px;
    height: 30px;
}

.leg {
    position: absolute;
    width: 4px;
    height: 25px;
    background: linear-gradient(to bottom, #888, #555);
    border-radius: 2px;
    transform-origin: top center;
}

.leg1 {
    left: 20px;
    transform: rotate(-30deg);
}

.leg2 {
    left: 50%;
    transform: translateX(-50%);
}

.leg3 {
    right: 20px;
    transform: rotate(30deg);
}

.leg::after {
    content: '';
    position: absolute;
    bottom: -5px;
    left: -3px;
    width: 10px;
    height: 5px;
    background: #666;
    border-radius: 50%;
}

/* 着陆粒子效果 */
.landing-particles {
    position: absolute;
    bottom: 35%;
    left: 50%;
    transform: translateX(-50%);
    width: 200px;
    height: 100px;
    pointer-events: none;
    z-index: 5;
}

.particle {
    position: absolute;
    width: 4px;
    height: 4px;
    background: #D2691E;
    border-radius: 50%;
    animation: particleFloat 2s ease-out forwards;
}

@keyframes particleFloat {
    0% {
        opacity: 1;
        transform: translateY(0) scale(1);
    }
    100% {
        opacity: 0;
        transform: translateY(-50px) scale(0.5);
    }
}

/* 宇航员档案铭牌 */
.astronaut-profile {
    position: fixed;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%) scale(0);
    width: 450px;
    max-width: 90vw;
    background: rgba(0, 20, 40, 0.95);
    border: 2px solid #4a9eff;
    border-radius: 15px;
    box-shadow: 
        0 0 50px rgba(74, 158, 255, 0.5),
        inset 0 0 30px rgba(74, 158, 255, 0.1);
    backdrop-filter: blur(10px);
    z-index: 100;
    font-family: 'Orbitron', monospace;
    opacity: 0;
    transition: all 0.5s cubic-bezier(0.68, -0.55, 0.265, 1.55);
}

.astronaut-profile.show {
    transform: translate(-50%, -50%) scale(1);
    opacity: 1;
}

.profile-container {
    padding: 25px;
    position: relative;
}

.profile-header {
    text-align: center;
    margin-bottom: 25px;
    position: relative;
}

.hologram-effect {
    position: absolute;
    top: -10px;
    left: -10px;
    right: -10px;
    bottom: -10px;
    background: linear-gradient(45deg, transparent, rgba(74, 158, 255, 0.1), transparent);
    animation: hologramScan 3s linear infinite;
    border-radius: 10px;
}

@keyframes hologramScan {
    0% { transform: translateX(-100%); }
    100% { transform: translateX(100%); }
}

.profile-title {
    font-size: 24px;
    color: #4a9eff;
    margin-bottom: 8px;
    text-shadow: 0 0 10px rgba(74, 158, 255, 0.8);
    font-weight: 700;
}

.profile-id {
    font-size: 12px;
    color: #88ccff;
    opacity: 0.8;
}

.profile-content {
    display: flex;
    gap: 25px;
    align-items: flex-start;
}

.avatar-section {
    flex-shrink: 0;
}

.avatar-container {
    position: relative;
    width: 100px;
    height: 100px;
}

.avatar-glow {
    position: absolute;
    top: -10px;
    left: -10px;
    right: -10px;
    bottom: -10px;
    background: radial-gradient(circle, rgba(74, 158, 255, 0.3), transparent);
    border-radius: 50%;
    animation: avatarPulse 2s ease-in-out infinite;
}

@keyframes avatarPulse {
    0%, 100% { transform: scale(1); opacity: 0.5; }
    50% { transform: scale(1.1); opacity: 0.8; }
}

.avatar {
    width: 100px;
    height: 100px;
    border: 2px solid #4a9eff;
    border-radius: 50%;
    background: rgba(74, 158, 255, 0.1);
    box-shadow: 0 0 20px rgba(74, 158, 255, 0.5);
}

.info-section {
    flex: 1;
}

.info-grid {
    display: grid;
    gap: 15px;
}

.info-item {
    display: flex;
    flex-direction: column;
    gap: 5px;
}

.info-label {
    font-size: 12px;
    color: #88ccff;
    text-transform: uppercase;
    letter-spacing: 1px;
    opacity: 0.8;
}

.info-value {
    font-size: 16px;
    color: #ffffff;
    font-weight: 600;
    text-shadow: 0 0 5px rgba(255, 255, 255, 0.3);
}

.profile-footer {
    margin-top: 25px;
    padding-top: 20px;
    border-top: 1px solid rgba(74, 158, 255, 0.3);
    display: flex;
    justify-content: space-between;
    align-items: center;
}

.status-indicator {
    display: flex;
    align-items: center;
    gap: 8px;
    font-size: 14px;
    color: #00ff88;
}

.status-dot {
    width: 8px;
    height: 8px;
    background: #00ff88;
    border-radius: 50%;
    animation: statusBlink 1.5s ease-in-out infinite;
    box-shadow: 0 0 10px rgba(0, 255, 136, 0.8);
}

@keyframes statusBlink {
    0%, 100% { opacity: 1; }
    50% { opacity: 0.3; }
}

.mission-time {
    font-size: 12px;
    color: #88ccff;
    opacity: 0.7;
}

.close-btn {
    position: absolute;
    top: 15px;
    right: 20px;
    width: 30px;
    height: 30px;
    background: rgba(255, 0, 0, 0.2);
    border: 1px solid #ff4444;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    color: #ff4444;
    font-size: 18px;
    cursor: pointer;
    transition: all 0.3s ease;
}

.close-btn:hover {
    background: rgba(255, 0, 0, 0.4);
    box-shadow: 0 0 15px rgba(255, 68, 68, 0.5);
}

/* 加载屏幕 */
.loading-screen {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: #000;
    display: flex;
    align-items: center;
    justify-content: center;
    z-index: 1000;
    transition: opacity 1s ease-out;
}

.loading-screen.fade-out {
    opacity: 0;
    pointer-events: none;
}

.loading-content {
    text-align: center;
    color: #4a9eff;
}

.loading-logo {
    position: relative;
    width: 120px;
    height: 120px;
    margin: 0 auto 30px;
}

.logo-ring {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    border: 3px solid transparent;
    border-top: 3px solid #4a9eff;
    border-radius: 50%;
    animation: logoSpin 2s linear infinite;
}

@keyframes logoSpin {
    0% { transform: rotate(0deg); }
    100% { transform: rotate(360deg); }
}

.logo-center {
    position: absolute;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%);
    font-family: 'Orbitron', monospace;
    font-size: 20px;
    font-weight: 900;
    color: #4a9eff;
    text-shadow: 0 0 15px rgba(74, 158, 255, 0.8);
}

.loading-text {
    font-size: 16px;
    margin-bottom: 20px;
    font-family: 'Exo 2', sans-serif;
    animation: textPulse 1.5s ease-in-out infinite;
}

@keyframes textPulse {
    0%, 100% { opacity: 0.6; }
    50% { opacity: 1; }
}

.loading-bar {
    width: 300px;
    height: 4px;
    background: rgba(74, 158, 255, 0.2);
    border-radius: 2px;
    margin: 0 auto;
    overflow: hidden;
}

.loading-progress {
    height: 100%;
    background: linear-gradient(90deg, #4a9eff, #00ccff);
    border-radius: 2px;
    animation: loadingProgress 3s ease-out forwards;
    box-shadow: 0 0 10px rgba(74, 158, 255, 0.8);
}

@keyframes loadingProgress {
    0% { width: 0%; }
    100% { width: 100%; }
}

/* 响应式设计 */
@media (max-width: 768px) {
    .spacecraft {
        transform: translateX(-50%) scale(0.8);
    }
    
    .spacecraft.landing {
        transform: translateX(-50%) scale(0.8);
    }
    
    .astronaut-profile {
        width: 350px;
        max-width: 95vw;
    }
    
    .profile-container {
        padding: 20px;
    }
    
    .profile-content {
        flex-direction: column;
        align-items: center;
        gap: 20px;
    }
    
    .profile-title {
        font-size: 20px;
    }
    
    .info-value {
        font-size: 14px;
    }
}

@media (max-width: 480px) {
    .spacecraft {
        transform: translateX(-50%) scale(0.6);
    }
    
    .spacecraft.landing {
        transform: translateX(-50%) scale(0.6);
    }
    
    .astronaut-profile {
        width: 300px;
    }
    
    .profile-container {
        padding: 15px;
    }
    
    .profile-title {
        font-size: 18px;
    }
    
    .avatar-container {
        width: 80px;
        height: 80px;
    }
    
    .avatar {
        width: 80px;
        height: 80px;
    }
}