/* Download Page Specific Styles */

/* Language-specific font optimizations for download page */
body[lang="ko"],
body[lang="ko"] * {
    font-family: -apple-system, BlinkMacSystemFont, 'Apple SD Gothic Neo', 'Malgun Gothic', 'Noto Sans KR', 'Segoe UI', sans-serif;
}

body[lang="zh"],
body[lang="zh"] * {
    font-family: -apple-system, BlinkMacSystemFont, 'PingFang SC', 'Microsoft YaHei', 'Noto Sans SC', 'Segoe UI', sans-serif;
}

body[lang="ja"],
body[lang="ja"] * {
    font-family: -apple-system, BlinkMacSystemFont, 'Hiragino Sans', 'Yu Gothic', 'Noto Sans JP', 'Segoe UI', sans-serif;
}

body[lang="es"],
body[lang="es"] * {
    font-family: 'Inter', -apple-system, BlinkMacSystemFont, 'Segoe UI', sans-serif;
}

body[lang="en"],
body[lang="en"] * {
    font-family: 'Inter', -apple-system, BlinkMacSystemFont, 'Segoe UI', sans-serif;
}

/* Download Hero */
.download-hero {
    margin-top: 80px;
    padding: 5rem 2rem;
    background: linear-gradient(135deg, var(--bg-primary) 0%, var(--bg-secondary) 100%);
    text-align: center;
    position: relative;
    overflow: hidden;
}

.download-hero::before {
    content: '';
    position: absolute;
    top: 50%;
    left: 50%;
    width: 600px;
    height: 600px;
    background: radial-gradient(circle, var(--accent-dim) 0%, transparent 70%);
    transform: translate(-50%, -50%);
    animation: pulse 4s ease-in-out infinite;
}

.download-hero-container {
    max-width: 800px;
    margin: 0 auto;
    position: relative;
    z-index: 1;
}

.hero-badge {
    display: inline-block;
    padding: 0.5rem 1rem;
    background: var(--accent-dim);
    border: 1px solid var(--accent);
    border-radius: 20px;
    font-size: 0.75rem;
    font-weight: 600;
    text-transform: uppercase;
    letter-spacing: 0.05em;
    color: var(--accent);
    margin-bottom: 1.5rem;
}

.download-title {
    font-size: clamp(2.5rem, 5vw, 2.5rem);
    font-weight: 700;
    margin-bottom: 1rem;
    background: linear-gradient(135deg, var(--text-primary) 0%, var(--accent) 100%);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
}

.download-subtitle {
    font-size: clamp(1rem, 2vw, 1rem);
    color: var(--text-secondary);
    margin-bottom: 2rem;
}

.version-info {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 1.5rem;
    flex-wrap: wrap;
}

.version-number {
    font-size: 1rem;
    font-weight: 700;
    color: var(--accent);
}

.version-date {
    font-size: 0.875rem;
    color: var(--text-secondary);
}

/* Download Section */
.download-section {
    padding: 4rem 2rem;
    background: var(--bg-primary);
}

.download-container {
    max-width: 1280px;
    margin: 0 auto;
}

/* Downloads Grid */
.downloads-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(320px, 1fr));
    gap: 2rem;
    margin-bottom: 4rem;
    padding-top: 1rem;
}

.download-card {
    background: var(--bg-card);
    border: 1px solid var(--border-color);
    border-radius: 16px;
    padding: 2rem;
    text-align: center;
    position: relative;
    transition: var(--transition);
    overflow: hidden;
}

.download-card::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    height: 3px;
    background: linear-gradient(90deg, transparent, var(--accent), transparent);
    transform: translateX(-100%);
    transition: transform 0.6s ease;
}

.download-card:hover {
    transform: translateY(-4px);
    border-color: var(--accent);
    box-shadow: 0 12px 40px rgba(0, 255, 65, 0.15);
}

.download-card:hover::before {
    transform: translateX(0);
    animation: shimmer 1.5s ease-in-out infinite;
}

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

.download-card.featured {
    grid-column: span 1;
}

@media (min-width: 768px) {
    .download-card.featured {
        grid-column: span 2;
    }
}

@media (min-width: 1024px) {
    .download-card.featured {
        grid-column: span 1;
    }
}

.os-icon {
    width: 80px;
    height: 80px;
    margin: 0 auto 1.5rem;
    background: var(--bg-secondary);
    border-radius: 20px;
    display: flex;
    align-items: center;
    justify-content: center;
    position: relative;
}

.os-icon::after {
    content: '';
    position: absolute;
    inset: -1px;
    background: linear-gradient(135deg, var(--accent), transparent);
    border-radius: 20px;
    opacity: 0;
    transition: opacity 0.3s ease;
    z-index: -1;
}

.download-card:hover .os-icon::after {
    opacity: 0.5;
}

.os-name {
    font-size: 1.5rem;
    font-weight: 600;
    margin-bottom: 0.5rem;
    color: var(--text-primary);
}

.os-version {
    font-size: 0.875rem;
    color: var(--text-secondary);
    margin-bottom: 1.5rem;
}

/* Download Buttons */
.download-buttons {
    display: flex;
    flex-direction: column;
    gap: 0.75rem;
    margin-bottom: 1.5rem;
}

.btn-primary,
.btn-secondary {
    padding: 0.75rem 1.5rem;
    border-radius: 8px;
    font-size: 0.875rem;
    font-weight: 600;
    border: none;
    cursor: pointer;
    transition: var(--transition);
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 0.5rem;
    width: 100%;
}

.btn-primary {
    background: var(--accent);
    color: var(--bg-primary);
}

.btn-primary:hover {
    background: #00ff8f;
    transform: translateY(-2px);
    box-shadow: 0 8px 20px rgba(0, 255, 65, 0.3);
}

.btn-secondary {
    background: transparent;
    color: var(--text-secondary);
    border: 1px solid var(--border-color);
}

.btn-secondary:hover {
    background: var(--bg-secondary);
    color: var(--text-primary);
    border-color: var(--accent);
}

.file-info {
    display: flex;
    justify-content: center;
    gap: 1.5rem;
    font-size: 0.75rem;
    color: var(--text-secondary);
}

.file-hash {
    font-family: monospace;
}

/* Additional Downloads */
.additional-downloads {
    margin-bottom: 4rem;
}

.resources-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(280px, 1fr));
    gap: 1.5rem;
    margin-top: 2rem;
}

.resource-card {
    background: var(--bg-card);
    border: 1px solid var(--border-color);
    border-radius: 12px;
    padding: 1.5rem;
    transition: var(--transition);
}

.resource-card:hover {
    transform: translateY(-2px);
    border-color: var(--accent);
}

.resource-icon {
    width: 48px;
    height: 48px;
    background: var(--accent-dim);
    border-radius: 12px;
    display: flex;
    align-items: center;
    justify-content: center;
    margin-bottom: 1rem;
}

.resource-card h4 {
    font-size: 1.125rem;
    font-weight: 600;
    margin-bottom: 0.5rem;
    color: var(--text-primary);
}

.resource-card p {
    font-size: 0.875rem;
    color: var(--text-secondary);
    margin-bottom: 1rem;
}

.resource-link {
    font-size: 0.875rem;
    color: var(--accent);
    font-weight: 500;
    transition: var(--transition);
}

.resource-link:hover {
    color: #00ff8f;
}

/* Requirements Summary */
.requirements-summary {
    background: var(--bg-card);
    border: 1px solid var(--border-color);
    border-radius: 16px;
    padding: 2rem;
    margin-bottom: 4rem;
}

.req-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(200px, 1fr));
    gap: 2rem;
    margin-top: 2rem;
}

.req-item {
    display: flex;
    align-items: flex-start;
    gap: 1rem;
}

.req-item svg {
    flex-shrink: 0;
    margin-top: 0.25rem;
}

.req-item h5 {
    font-size: 0.875rem;
    font-weight: 600;
    color: var(--accent);
    margin-bottom: 0.25rem;
}

.req-item p {
    font-size: 0.875rem;
    color: var(--text-secondary);
    margin: 0;
}

/* Installation Guide */
.installation-guide {
    margin-bottom: 4rem;
}

.install-steps {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(250px, 1fr));
    gap: 1.5rem;
    margin-top: 2rem;
}

.install-step {
    display: flex;
    align-items: flex-start;
    gap: 1rem;
    padding: 1.5rem;
    background: var(--bg-card);
    border: 1px solid var(--border-color);
    border-radius: 12px;
    transition: var(--transition);
}

.install-step:hover {
    transform: translateY(-2px);
    border-color: var(--accent);
}

.step-number {
    width: 32px;
    height: 32px;
    background: var(--accent);
    color: var(--bg-primary);
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    font-weight: bold;
    font-size: 1rem;
    flex-shrink: 0;
}

.step-content h4 {
    font-size: 1rem;
    font-weight: 600;
    margin-bottom: 0.5rem;
    color: var(--text-primary);
}

.step-content p {
    font-size: 0.875rem;
    color: var(--text-secondary);
    margin: 0;
}

/* Security Notice */
.security-notice {
    background: rgba(255, 193, 7, 0.05);
    border: 1px solid rgba(255, 193, 7, 0.2);
    border-radius: 12px;
    padding: 1.5rem;
    display: flex;
    align-items: flex-start;
    gap: 1rem;
}

.notice-icon {
    flex-shrink: 0;
    width: 40px;
    height: 40px;
    background: rgba(255, 193, 7, 0.1);
    border-radius: 8px;
    display: flex;
    align-items: center;
    justify-content: center;
}

.notice-content h4 {
    font-size: 1.125rem;
    font-weight: 600;
    margin-bottom: 0.5rem;
    color: #ffc107;
}

.notice-content p {
    font-size: 0.875rem;
    color: var(--text-secondary);
    margin: 0;
    line-height: 1.6;
}

/* Responsive Design */
@media (max-width: 768px) {
    .download-hero {
        padding: 3rem 1rem;
    }
    
    .downloads-grid {
        grid-template-columns: 1fr;
    }
    
    .download-card.featured {
        grid-column: span 1;
    }
    
    .resources-grid {
        grid-template-columns: 1fr;
    }
    
    .req-grid {
        grid-template-columns: 1fr;
    }
    
    .install-steps {
        grid-template-columns: 1fr;
    }
    
    .file-info {
        flex-direction: column;
        gap: 0.5rem;
    }
    
    .version-info {
        gap: 1rem;
    }
}

/* Loading Animation for Download Buttons */
.download-btn.loading {
    position: relative;
    color: transparent;
}

.download-btn.loading::after {
    content: '';
    position: absolute;
    width: 20px;
    height: 20px;
    top: 50%;
    left: 50%;
    margin-left: -10px;
    margin-top: -10px;
    border: 2px solid var(--bg-primary);
    border-radius: 50%;
    border-top-color: transparent;
    animation: spinner 0.8s linear infinite;
}

@keyframes spinner {
    to { transform: rotate(360deg); }
}

/* Release Overlay - Blur Filter */
.release-overlay {
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: rgba(43, 43, 43, 0.85);
    backdrop-filter: blur(8px);
    -webkit-backdrop-filter: blur(8px);
    border-radius: 16px;
    z-index: 10;
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 2rem;
}

.release-text {
    font-size: 1.25rem;
    font-weight: 700;
    color: var(--accent);
    text-align: center;
    text-transform: uppercase;
    letter-spacing: 0.05em;
    line-height: 1.4;
    background: linear-gradient(135deg, var(--accent) 0%, #00ff8f 100%);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
    animation: glow 2s ease-in-out infinite;
}

@keyframes glow {
    0%, 100% {
        opacity: 1;
        text-shadow: 0 0 20px rgba(0, 255, 65, 0.5);
    }
    50% {
        opacity: 0.8;
        text-shadow: 0 0 30px rgba(0, 255, 65, 0.8);
    }
}

@media (max-width: 768px) {
    .release-text {
        font-size: 1rem;
    }
}
