:root {
    --primary-color: #6c5ce7;
    --secondary-color: #a29bfe;
    --dark-color: #2d3436;
    --light-color: #f5f6fa;
    --success-color: #00b894;
    --danger-color: #d63031;
    --warning-color: #fdcb6e;
}

* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
    font-family: 'Segoe UI', Tahoma, Geneva, Verdana, sans-serif;
}

body {
    background-color: #f1f2f6;
    color: var(--dark-color);
    line-height: 1.6;
}

.container {
    max-width: 1200px;
    margin: 0 auto;
    padding: 20px;
}

header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 30px;
}

header h1 {
    color: var(--primary-color);
    font-size: 2.2rem;
}

header h1 i {
    margin-right: 10px;
}

.refresh {
    background-color: var(--primary-color);
    color: white;
    padding: 10px 15px;
    border-radius: 5px;
    cursor: pointer;
    font-weight: 500;
    transition: all 0.3s ease;
}

.refresh:hover {
    background-color: #5649c0;
}

.refresh i {
    margin-right: 5px;
}

.search-container {
    margin-bottom: 20px;
}

.search-container input {
    width: 100%;
    padding: 12px 15px;
    border: 1px solid #ddd;
    border-radius: 5px;
    font-size: 1rem;
    outline: none;
    transition: border 0.3s ease;
}

.search-container input:focus {
    border-color: var(--primary-color);
}

.filters {
    display: flex;
    gap: 10px;
    margin-bottom: 20px;
}

.filter-btn {
    padding: 8px 15px;
    border: none;
    border-radius: 5px;
    background-color: #ddd;
    cursor: pointer;
    transition: all 0.3s ease;
}

.filter-btn.active {
    background-color: var(--primary-color);
    color: white;
}

.crypto-list {
    background-color: white;
    border-radius: 10px;
    overflow: hidden;
    box-shadow: 0 5px 15px rgba(0, 0, 0, 0.1);
    margin-bottom: 30px;
}

.list-header {
    display: flex;
    padding: 15px 20px;
    background-color: var(--primary-color);
    color: white;
    font-weight: 600;
}

.list-header .rank {
    width: 50px;
}

.list-header .name {
    flex: 2;
}

.list-header .price {
    flex: 1;
    text-align: right;
}

.list-header .change {
    width: 100px;
    text-align: right;
}

.list-header .market-cap {
    flex: 1;
    text-align: right;
}

.list-body {
    max-height: 600px;
    overflow-y: auto;
}

.crypto-item {
    display: flex;
    padding: 15px 20px;
    border-bottom: 1px solid #eee;
    align-items: center;
    transition: all 0.3s ease;
}

.crypto-item:hover {
    background-color: #f8f9fa;
}

.crypto-item .rank {
    width: 50px;
    font-weight: 500;
    color: #666;
}

.crypto-item .name {
    flex: 2;
    display: flex;
    align-items: center;
}

.crypto-item .name img {
    width: 24px;
    height: 24px;
    margin-right: 10px;
}

.crypto-item .symbol {
    color: #666;
    margin-left: 5px;
    font-size: 0.9rem;
}

.crypto-item .price {
    flex: 1;
    text-align: right;
    font-weight: 500;
}

.crypto-item .change {
    width: 100px;
    text-align: right;
}

.crypto-item .change.positive {
    color: var(--success-color);
}

.crypto-item .change.negative {
    color: var(--danger-color);
}

.crypto-item .market-cap {
    flex: 1;
    text-align: right;
}

.stats {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(300px, 1fr));
    gap: 20px;
    margin-bottom: 30px;
}

.stat-card {
    background-color: white;
    padding: 20px;
    border-radius: 10px;
    box-shadow: 0 5px 15px rgba(0, 0, 0, 0.1);
}

.stat-card h3 {
    color: #666;
    font-size: 1rem;
    margin-bottom: 10px;
}

.stat-card p {
    font-size: 1.5rem;
    font-weight: 600;
    color: var(--primary-color);
}

.loading {
    padding: 30px;
    text-align: center;
    color: #666;
}

.loading i {
    margin-right: 10px;
}

@media (max-width: 768px) {
    .list-header .market-cap,
    .crypto-item .market-cap {
        display: none;
    }
    
    .list-header .rank,
    .crypto-item .rank {
        width: 30px;
    }
    
    .stats {
        grid-template-columns: 1fr;
    }
}