/* Download Page Specific Styles */

/* Download Cards */
.download-card {
    background: white;
    border: 1px solid #e2e8f0;
    border-radius: 0.75rem;
    padding: 1.5rem;
    transition: all 0.3s ease;
    height: 100%;
    display: flex;
    flex-direction: column;
}

.download-card:hover {
    border-color: #cbd5e1;
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.1);
    transform: translateY(-2px);
}

.download-card-header {
    display: flex;
    align-items: flex-start;
    gap: 1rem;
    margin-bottom: 1rem;
}

.download-icon {
    width: 3rem;
    height: 3rem;
    border-radius: 0.75rem;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 1.25rem;
    flex-shrink: 0;
}

.download-icon.raw-data {
    background: linear-gradient(135deg, #dbeafe 0%, #bfdbfe 100%);
    color: #1e40af;
}

.download-icon.protein-data {
    background: linear-gradient(135deg, #dbeafe 0%, #bfdbfe 100%);
    color: #1e40af;
}

.download-icon.ligand-data {
    background: linear-gradient(135deg, #dcfce7 0%, #bbf7d0 100%);
    color: #166534;
}

.download-icon.xref-data {
    background: linear-gradient(135deg, #f3e8ff 0%, #e9d5ff 100%);
    color: #7c3aed;
}

.download-icon.ml-cls {
    background: linear-gradient(135deg, #f3e8ff 0%, #e9d5ff 100%);
    color: #7c3aed;
}

.download-icon.ml-active {
    background: linear-gradient(135deg, #fee2e2 0%, #fecaca 100%);
    color: #dc2626;
}

.download-icon.ml-inactive {
    background: linear-gradient(135deg, #f3f4f6 0%, #e5e7eb 100%);
    color: #6b7280;
}

.download-info {
    flex: 1;
}

.download-title {
    font-size: 1.125rem;
    font-weight: 600;
    color: #1f2937;
    margin-bottom: 0.25rem;
}

.download-filename {
    font-family: 'Courier New', monospace;
    font-size: 0.875rem;
    color: #6b7280;
    background: #f3f4f6;
    padding: 0.25rem 0.5rem;
    border-radius: 0.25rem;
    display: inline-block;
}

.download-size {
    font-size: 0.75rem;
    color: #9ca3af;
    font-weight: 500;
    background: #f9fafb;
    padding: 0.25rem 0.5rem;
    border-radius: 0.375rem;
    border: 1px solid #e5e7eb;
}

.download-description {
    color: #6b7280;
    font-size: 0.875rem;
    line-height: 1.5;
    margin-bottom: 1rem;
    flex: 1;
}

.download-stats {
    display: flex;
    flex-wrap: wrap;
    gap: 1rem;
    margin-bottom: 1.5rem;
    padding-top: 1rem;
    border-top: 1px solid #f3f4f6;
}

.stat-item {
    display: flex;
    align-items: center;
    gap: 0.375rem;
    font-size: 0.75rem;
    color: #6b7280;
    font-weight: 500;
}

/* Download Buttons */
.download-btn {
    width: 100%;
    padding: 0.75rem 1rem;
    font-size: 0.875rem;
    font-weight: 600;
    border-radius: 0.5rem;
    transition: all 0.2s ease;
    cursor: pointer;
    border: none;
    display: flex;
    align-items: center;
    justify-content: center;
    text-decoration: none;
}

.download-btn.primary {
    background: #3b82f6;
    color: white;
}

.download-btn.primary:hover {
    background: #2563eb;
    transform: translateY(-1px);
    box-shadow: 0 4px 8px rgba(59, 130, 246, 0.3);
}

.download-btn.secondary {
    background: #8b5cf6;
    color: white;
}

.download-btn.secondary:hover {
    background: #7c3aed;
    transform: translateY(-1px);
    box-shadow: 0 4px 8px rgba(139, 92, 246, 0.3);
}

/* Download Progress */
.download-progress {
    position: fixed;
    bottom: 2rem;
    right: 2rem;
    background: white;
    border: 1px solid #e2e8f0;
    border-radius: 0.75rem;
    padding: 1rem;
    box-shadow: 0 10px 25px rgba(0, 0, 0, 0.15);
    min-width: 300px;
    transform: translateY(100px);
    opacity: 0;
    transition: all 0.3s ease;
    z-index: 1000;
}

.download-progress.show {
    transform: translateY(0);
    opacity: 1;
}

.progress-header {
    display: flex;
    align-items: center;
    gap: 0.75rem;
    margin-bottom: 0.75rem;
}

.progress-icon {
    width: 2rem;
    height: 2rem;
    background: #dbeafe;
    color: #1e40af;
    border-radius: 0.5rem;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 0.875rem;
}

.progress-info h4 {
    font-size: 0.875rem;
    font-weight: 600;
    color: #1f2937;
    margin: 0;
}

.progress-info p {
    font-size: 0.75rem;
    color: #6b7280;
    margin: 0;
}

.progress-bar {
    width: 100%;
    height: 0.5rem;
    background: #f3f4f6;
    border-radius: 0.25rem;
    overflow: hidden;
}

.progress-fill {
    height: 100%;
    background: linear-gradient(90deg, #3b82f6, #1d4ed8);
    border-radius: 0.25rem;
    transition: width 0.3s ease;
    width: 0%;
}

/* Responsive Design */
@media (max-width: 1024px) {
    .download-card-header {
        gap: 0.75rem;
    }
    
    .download-icon {
        width: 2.5rem;
        height: 2.5rem;
        font-size: 1rem;
    }
    
    .download-stats {
        gap: 0.75rem;
    }
}

@media (max-width: 768px) {
    .download-card {
        padding: 1rem;
    }
    
    .download-card-header {
        flex-direction: column;
        align-items: center;
        text-align: center;
        gap: 0.5rem;
    }
    
    .download-info {
        text-align: center;
    }
    
    .download-stats {
        justify-content: center;
        gap: 0.5rem;
    }
    
    .stat-item {
        font-size: 0.6875rem;
    }
    
    .download-progress {
        right: 1rem;
        left: 1rem;
        bottom: 1rem;
        min-width: auto;
    }
}

/* Animation */
@keyframes downloadPulse {
    0%, 100% {
        opacity: 1;
    }
    50% {
        opacity: 0.5;
    }
}

.downloading {
    animation: downloadPulse 1.5s ease-in-out infinite;
}