/* 전역 변수 설정 */
:root {
    --bg-main: #f8fafc;
    --card-bg: #ffffff;
    --primary-green: #10b981; 
    --dark-green: #059669;
    --light-green: #ecfdf5;
    --dark-slate: #1e293b;
    --text-gray: #64748b;
    --border-light: #e2e8f0;
}

/* body 기본 스타일 */
body {
    font-family: 'Pretendard', -apple-system, sans-serif;
    color: var(--dark-slate);
    margin: 0;
    padding: 30px 20px; 
    display: flex;
    justify-content: center;
    align-items: flex-start; 
    position: relative;
    overflow-x: hidden;
    min-height: 100vh;
    background-color: #05070a; 
}

/* 배경 레이어: CPU 부하가 없는 단순 선형 그라데이션 */
body::before {
    content: '';
    position: fixed; 
    top: 0; left: 0; width: 100%; height: 100%;
    z-index: -3;
    background: linear-gradient(135deg, #05070a 0%, #0c121e 50%, #111a2e 100%);
}

/* 별무리(점) 제거: CPU 점유율 방지 */
body::after {
    display: none;
}

/* 별 설정: GPU 가속 적용 */
.shooting-star {
    position: fixed;
    top: 0;
    width: 2px;
    height: 2px;
    background: #fff;
    border-radius: 50%;
    box-shadow: 0 0 6px rgba(255, 255, 255, 1);
    will-change: transform, opacity;
    transform: translate3d(0, 0, 0); 
    animation: animate-star 4s linear infinite;
    z-index: -1;
    opacity: 0;
}

/* 별 꼬리 최적화 */
.shooting-star::before {
    content: '';
    position: absolute;
    top: 50%;
    transform: translateY(-50%);
    width: 200px;
    height: 1px;
    background: linear-gradient(90deg, #fff, transparent);
}

/* 애니메이션 통합 및 최적화 (30% 이후 연산 중지) */
@keyframes animate-star {
    0% { 
        transform: rotate(315deg) translate3d(500px, 0, 0); 
        opacity: 0; 
    }
    1% { opacity: 1; }
    30% { 
        transform: rotate(315deg) translate3d(-2000px, 0, 0); 
        opacity: 0; 
    }
    100% { 
        transform: rotate(315deg) translate3d(-2000px, 0, 0); 
        opacity: 0; 
    }
}

/* 별 개별 위치 설정 */
.shooting-star:nth-child(1) { top: 0; right: -10%; animation-delay: 0s; animation-duration: 5s; }
.shooting-star:nth-child(2) { top: -5%; right: 10%; animation-delay: 2.5s; animation-duration: 7s; }
.shooting-star:nth-child(3) { top: 10%; right: -20%; animation-delay: 5s; animation-duration: 6s; }
.shooting-star:nth-child(4) { top: 0; right: 35%; animation-delay: 8s; animation-duration: 5.5s; }
.shooting-star:nth-child(5) { top: 5%; right: -5%; animation-delay: 1.5s; animation-duration: 8s; }
.shooting-star:nth-child(6) { top: 20%; right: -15%; animation-delay: 11s; animation-duration: 6.5s; }
.shooting-star:nth-child(7) { top: 0; right: 20%; animation-delay: 4s; animation-duration: 9s; }
.shooting-star:nth-child(8) { top: -5%; right: 55%; animation-delay: 14s; animation-duration: 7.5s; }

/* 메인 레이아웃: 좌측 다운로드 영역과 우측 정보 패널 (그리드) */
.main-wrapper {
    display: grid;
    grid-template-columns: 1.1fr 0.9fr;
    gap: 30px;
    max-width: 1200px;
    width: 100%;
    position: relative;
    z-index: 1;
    margin-bottom: 10px; 
}

/* 카드 디자인: 반투명 유리 질감 효과 적용 */
.container, .info-panel {
    background: rgba(255, 255, 255, 0.97);
    backdrop-filter: blur(12px);
    padding: 35px 50px; 
    border-radius: 24px;
    box-shadow: 0 20px 50px rgba(0, 0, 0, 0.3);
    border: 1px solid rgba(255, 255, 255, 0.15);
}

.container { text-align: center; }

/* 최신 버전 배지: 민트 배경과 진한 녹색 글자 */
.version-badge {
    display: inline-block;
    padding: 6px 16px;
    background: #ecfdf5; 
    color: #059669;      
    border-radius: 100px;
    font-weight: 700;
    font-size: 0.82rem;
    margin-bottom: 12px;
    border: 1px solid rgba(16, 185, 129, 0.2);
    letter-spacing: 0.5px;
    text-transform: uppercase;
}

/* 메인 타이틀 및 포인트 컬러(그린) 적용 */
.main-title {
    font-size: 2.3rem;
    font-weight: 900;
    margin: 0 0 8px 0;
    letter-spacing: -1.5px;
}
.main-title span { color: var(--primary-green); }

.update-date {
    color: var(--text-gray);
    font-size: 0.9rem;
    margin-bottom: 25px;
}

.download-area {
    display: flex;
    flex-direction: column;
    gap: 12px;
    margin-bottom: 25px;
}

/* 공통 버튼 스타일 */
.btn {
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: 18px 25px;
    text-decoration: none;
    border-radius: 16px;
    transition: all 0.3s ease;
}

/* 설치 버전 버튼: 녹색 배경 및 입체 그림자 */
.btn-setup {
    background: var(--primary-green);
    color: white;
    box-shadow: 0 4px 15px rgba(16, 185, 129, 0.3);
    position: relative;
    z-index: 2; 
}

.btn-setup:hover { 
    background: var(--dark-green); 
    transform: translateY(-3px); 
    box-shadow: 0 6px 20px rgba(16, 185, 129, 0.4);
}

/* 포터블 버튼: 차분한 군청색 유리 질감 스타일 */
.btn-portable { 
    background: rgba(30, 41, 59, 0.5); 
    color: #ffffff;      
    border: 1px solid rgba(255, 255, 255, 0.12);
    backdrop-filter: blur(10px); 
    box-shadow: none;
}

/* 포터블 버튼 내부의 카운트 배지 */
.btn-portable .count-badge {
    background: rgba(255, 255, 255, 0.12);
    color: #ffffff;
    opacity: 0.8;
}

.btn-portable:hover { 
    background: rgba(51, 65, 85, 0.7); 
    color: #ffffff;      
    transform: translateY(-2px);
    border: 1px solid rgba(255, 255, 255, 0.25);
}

/* 버튼 텍스트 레이아웃 */
.btn-text b { font-size: 1.15rem; display: block; text-align: left; }
.btn-text span { font-size: 0.75rem; opacity: 0.7; display: block; text-align: left; margin-top: 3px; }

/* 다운로드 카운트 배지 공통 스타일 */
.count-badge {
    background: rgba(255, 255, 255, 0.15);
    padding: 5px 10px;
    border-radius: 10px;
    font-size: 1.1rem;
    font-weight: 600;
}

/* 미리보기 스크린샷 이미지 효과 */
.preview-img {
    width: 75%;
    border-radius: 4px;
    box-shadow: 0 15px 40px rgba(0, 0, 0, 0.4);
    margin-top: 20px;
    transition: all 0.5s;
}

/* 섹션 구분 라벨 및 타이틀 옆 실선 효과 */
.section-label {
    font-size: 1.05rem;
    font-weight: 600;
    color: var(--primary-green);
    margin-bottom: 15px;
    display: flex;
    align-items: center;
}
.section-label::after {
    content: '';
    flex: 1;
    height: 1px;
    background: #f1f5f9;
    margin-left: 12px;
}

/* PC용 기본 스타일: 메인 기능 설명 */
.feature-text {
    display: block;
    font-size: 0.92rem;
    color: var(--text-gray);
    line-height: 1.6;
    margin-bottom: 6px;
    word-break: keep-all; /* 단어 단위 줄바꿈으로 가독성 향상 */
}


/* 상세 사양 리스트 */
.feature-list {
    font-size: 0.92rem;
    line-height: 2;
    margin-bottom: 25px;
}
.feature-item { display: flex; justify-content: space-between; margin-bottom: 6px; }
.feature-item b { color: var(--text-gray); font-weight: 600; }

/* 패치 노트 스크롤 박스 */
.patch-box {
    background: #f8fafc;
    border: 1px solid #f1f5f9;
    padding: 12px;
    border-radius: 16px;
    font-size: 0.77rem; 
    max-height: 220px;
    overflow-y: auto;
    color: var(--text-gray);
    line-height: 1.5;
}

/* 하단 푸터 영역 */
.footer {
    margin-top: 20px;
    padding-top: 15px;
    border-top: 1px solid #f1f5f9;
    display: flex;
    justify-content: space-between;
    align-items: center;
}

/* 방문자 수 태그: 민트 톤으로 가독성 */
.visit-tag {
    background: rgba(16, 185, 129, 0.1); 
    padding: 4px 12px;
    border-radius: 8px;
    font-size: 0.75rem;
    font-weight: 700;
    color: var(--primary-green); 
    border: 1px solid rgba(16, 185, 129, 0.2);
    letter-spacing: 0.5px;
}

/* VC++ 런타임 링크 버튼 */
.runtime-btn {
    font-size: 0.75rem;
    color: #94a3b8;
    text-decoration: none;
    border: 1px solid #e2e8f0;
    padding: 2px 6px;
    border-radius: 4px;
}

/* --- 모바일 최적화 (1000px 이하 화면) --- */
@media (max-width: 1000px) {
    body { padding: 15px 10px; }
	
	/* 모바일에서 기능 설명 문구 폰트 크기 축소 */
    .feature-text {
        font-size: 0.8rem;
        line-height: 1.4;
        margin-bottom: 4px;
    }

    /* 그리드를 세로 1열로 변경 */
    .main-wrapper { 
        grid-template-columns: 1fr; 
        gap: 20px;
    }

    .container, .info-panel { padding: 25px 15px; }
    .main-title { font-size: 1.9rem; }
    .feature-list { font-size: 0.82rem; }

    /* 모바일에서 사양 항목 텍스트 정렬 및 생략(...) 처리 */
    .feature-item {
        display: flex;
        justify-content: flex-start; 
        gap: 8px; 
        margin-bottom: 4px;
        white-space: nowrap; 
        overflow: hidden;
    }

    .feature-item b { flex-shrink: 0; min-width: fit-content; }
    .feature-item span {
        flex: 1;
        text-align: right; 
        overflow: hidden;
        text-overflow: ellipsis; 
    }

    /* 모바일에서는 별 숨김 */
    .shooting-star { display: none; }
}

