* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

body {
    font-family: 'Segoe UI', Tahoma, Geneva, Verdana, sans-serif;
    background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
    min-height: 100vh;
    color: #333;
}

.container {
    max-width: 1200px;
    margin: 0 auto;
    padding: 20px;
}

header {
    text-align: center;
    margin-bottom: 30px;
    color: white;
}

header h1 {
    font-size: 2.5rem;
    margin-bottom: 10px;
    text-shadow: 2px 2px 4px rgba(0,0,0,0.3);
}

header p {
    font-size: 1.1rem;
    opacity: 0.9;
}

.loading {
    text-align: center;
    color: white;
    padding: 50px;
}

.spinner {
    border: 4px solid rgba(255,255,255,0.3);
    border-top: 4px solid white;
    border-radius: 50%;
    width: 50px;
    height: 50px;
    animation: spin 1s linear infinite;
    margin: 0 auto 20px;
}

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

.dashboard {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(400px, 1fr));
    gap: 20px;
}

.card {
    background: white;
    border-radius: 15px;
    padding: 25px;
    box-shadow: 0 10px 30px rgba(0,0,0,0.1);
    transition: transform 0.3s ease, box-shadow 0.3s ease;
}

.card:hover {
    transform: translateY(-5px);
    box-shadow: 0 15px 40px rgba(0,0,0,0.15);
}

.card h2 {
    color: #4a5568;
    margin-bottom: 20px;
    font-size: 1.3rem;
    display: flex;
    align-items: center;
    gap: 10px;
}

.card h2 i {
    color: #667eea;
}

.overview {
    grid-column: 1 / -1;
}

.overview-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(150px, 1fr));
    gap: 20px;
}

.stat {
    text-align: center;
    padding: 20px;
    background: linear-gradient(135deg, #667eea, #764ba2);
    border-radius: 10px;
    color: white;
}

.stat-value {
    font-size: 1.5rem;
    font-weight: bold;
    margin-bottom: 5px;
}

.stat-label {
    font-size: 0.9rem;
    opacity: 0.9;
}

.info-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(200px, 1fr));
    gap: 15px;
}

.info-item {
    padding: 10px;
    background: #f8f9fa;
    border-radius: 8px;
    border-left: 4px solid #667eea;
}

.memory-info {
    text-align: center;
}

.memory-bar {
    width: 100%;
    height: 20px;
    background: #e2e8f0;
    border-radius: 10px;
    overflow: hidden;
    margin-bottom: 10px;
}

.memory-usage {
    height: 100%;
    background: linear-gradient(90deg, #48bb78, #38a169);
    border-radius: 10px;
    transition: width 0.3s ease;
}

.memory-details {
    font-size: 1.1rem;
    color: #4a5568;
}

.storage-list, .gpu-list, .network-list {
    display: flex;
    flex-direction: column;
    gap: 10px;
}

.storage-item, .gpu-item, .network-item {
    padding: 15px;
    background: #f8f9fa;
    border-radius: 8px;
    border-left: 4px solid #667eea;
}

.ip-info, .cf-info {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(200px, 1fr));
    gap: 15px;
}

.ip-item, .cf-item {
    padding: 10px;
    background: #f8f9fa;
    border-radius: 8px;
    border-left: 4px solid #667eea;
}

.speed-test {
    text-align: center;
}

.speed-test-btn {
    background: linear-gradient(135deg, #667eea, #764ba2);
    color: white;
    border: none;
    padding: 15px 30px;
    border-radius: 25px;
    font-size: 1.1rem;
    cursor: pointer;
    transition: transform 0.3s ease;
    display: inline-flex;
    align-items: center;
    gap: 10px;
}

.speed-test-btn:hover {
    transform: scale(1.05);
}

.speed-test-btn:disabled {
    opacity: 0.6;
    cursor: not-allowed;
    transform: none;
}

.speed-results {
    margin-top: 20px;
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(150px, 1fr));
    gap: 15px;
}

.speed-item {
    padding: 15px;
    background: #f8f9fa;
    border-radius: 8px;
    text-align: center;
}

.speed-value {
    font-size: 1.5rem;
    font-weight: bold;
    color: #667eea;
    margin-bottom: 5px;
}

.speed-label {
    font-size: 0.9rem;
    color: #4a5568;
}

.loading-text {
    color: #718096;
    font-style: italic;
    text-align: center;
    padding: 20px;
}

.error-text {
    color: #e53e3e;
    text-align: center;
    padding: 20px;
}

/* Package Information Styles */
.packages-info {
    display: flex;
    flex-direction: column;
    gap: 20px;
}

.package-category {
    background: #f8f9fa;
    border-radius: 10px;
    padding: 15px;
    border-left: 4px solid #667eea;
}

.package-category h3 {
    color: #4a5568;
    margin-bottom: 15px;
    font-size: 1.1rem;
    display: flex;
    align-items: center;
    gap: 8px;
}

.package-category h3 i {
    color: #667eea;
}

.package-list {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(250px, 1fr));
    gap: 10px;
}

.package-item {
    background: white;
    padding: 10px;
    border-radius: 6px;
    border: 1px solid #e2e8f0;
    font-size: 0.9rem;
}

.package-name {
    font-weight: bold;
    color: #667eea;
}

.package-version {
    color: #718096;
    font-size: 0.8rem;
}

.package-runtime {
    background: linear-gradient(135deg, #667eea, #764ba2);
    color: white;
    border-radius: 8px;
    padding: 12px;
    margin-bottom: 10px;
}

.package-runtime .package-name {
    color: white;
    font-size: 1rem;
}

.package-runtime .package-version {
    color: rgba(255, 255, 255, 0.8);
}

@media (max-width: 768px) {
    .container {
        padding: 10px;
    }
    
    header h1 {
        font-size: 2rem;
    }
    
    .dashboard {
        grid-template-columns: 1fr;
    }
    
    .overview-grid {
        grid-template-columns: 1fr;
    }
    
    .info-grid {
        grid-template-columns: 1fr;
    }
    
    .card {
        padding: 15px;
    }
    
    .package-list {
        grid-template-columns: 1fr;
    }
}
