:root {
    --primary-color: #f7931a;
    --primary-gradient-1: #ffa622;
    --primary-gradient-2: #ff7e1f;
    --secondary-color: #4a90e2;
    --accent-1: #9b59b6;
    --accent-2: #2ecc71;
    --accent-3: #e74c3c;
    --text-primary: #2c3e50;
    --text-secondary: #6c757d;
    --success-light: #a8e6cf;
    --warning-light: #ffaaa5;
    --border-radius: 12px;
    --shadow-sm: 0 2px 4px rgba(0,0,0,0.1);
    --shadow-md: 0 4px 6px rgba(0,0,0,0.1);
    --shadow-lg: 0 10px 15px rgba(0,0,0,0.1);
    --transition-speed: 0.3s;
}

body {
    font-family: 'Segoe UI', Tahoma, Geneva, Verdana, sans-serif;
    margin: 0;
    padding: 20px;
    min-height: 100vh;
    background: linear-gradient(135deg, #9b6dff 0%, #6d5bff 100%);
    background-attachment: fixed;
    color: var(--text-primary);
    line-height: 1.6;
}

.container {
    max-width: 1200px;
    margin: 0 auto;
    background-color: white;
    border-radius: var(--border-radius);
    box-shadow: var(--shadow-lg);
    overflow: hidden;
    animation: slideIn 0.6s ease-out;
    transform-origin: top;
}

.header {
    background: linear-gradient(135deg, var(--primary-gradient-1), var(--primary-gradient-2));
    color: white;
    padding: 2rem;
    text-align: center;
    position: relative;
    overflow: hidden;
}

.header::before {
    content: '';
    position: absolute;
    top: -50%;
    left: -50%;
    width: 200%;
    height: 200%;
    background: radial-gradient(circle, rgba(255,255,255,0.2) 0%, transparent 60%);
    animation: rotate 20s linear infinite;
}

.logo {
    font-size: 3rem;
    margin-bottom: 1rem;
    animation: float 3s ease-in-out infinite;
    position: relative;
    z-index: 1;
}

.logo i {
    color: #ffffff;
    text-shadow: 0 0 10px rgba(247, 147, 26, 0.5);
    animation: pulse 2s ease-in-out infinite;
}

.loading {
    text-align: center;
    padding: 2rem;
    display: none;
}

.loading-spinner {
    display: inline-block;
    width: 40px;
    height: 40px;
    border: 4px solid rgba(247, 147, 26, 0.2);
    border-top: 4px solid var(--primary-color);
    border-radius: 50%;
    animation: spin 1s linear infinite, colors 3s ease-in-out infinite;
    margin-bottom: 1rem;
}

.table-container {
    padding: 20px;
    overflow-x: auto;
    animation: fadeIn 0.5s ease-out;
}

.price-table {
    width: 100%;
    border-collapse: separate;
    border-spacing: 0;
    margin: 1rem 0;
    border-radius: 8px;
    overflow: hidden;
    box-shadow: var(--shadow-md);
}

.price-table th {
    background: linear-gradient(135deg, rgba(74, 144, 226, 0.1), rgba(247, 147, 26, 0.1));
    font-weight: 600;
    color: var(--text-primary);
    padding: 1rem;
    text-align: left;
}

.price-table td {
    padding: 1rem;
    text-align: left;
    border-bottom: 1px solid #eee;
}

.price-table th i {
    margin-right: 0.5rem;
    animation: iconFloat 2s ease-in-out infinite;
    display: inline-block;
}

.price-table tr {
    transition: all var(--transition-speed);
    background-color: white;
}

.price-table tr:hover {
    transform: translateY(-2px) scale(1.01);
    box-shadow: var(--shadow-md);
    background: linear-gradient(to right, transparent, rgba(74, 144, 226, 0.05), transparent);
}

.highest-price {
    background: linear-gradient(to right, var(--success-light), transparent) !important;
}

.lowest-price {
    background: linear-gradient(to right, var(--warning-light), transparent) !important;
}

.volume,
.market-share {
    display: block;
    font-size: 0.9rem;
    color: var(--text-secondary);
    margin: 0.2rem 0;
    transition: color var(--transition-speed);
}

.footer {
    padding: 1rem;
    text-align: right;
    background: linear-gradient(to right, #f0f2f5, rgba(74, 144, 226, 0.1));
    color: var(--text-secondary);
    font-size: 0.9rem;
    position: relative;
    overflow: hidden;
}

@keyframes slideIn {
    0% {
        transform: translateY(-20px) scale(0.95);
        opacity: 0;
    }
    100% {
        transform: translateY(0) scale(1);
        opacity: 1;
    }
}

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

@keyframes float {
    0% { transform: translateY(0px); }
    50% { transform: translateY(-10px); }
    100% { transform: translateY(0px); }
}

@keyframes pulse {
    0% { text-shadow: 0 0 10px rgba(247, 147, 26, 0.5); }
    50% { text-shadow: 0 0 20px rgba(247, 147, 26, 0.8); }
    100% { text-shadow: 0 0 10px rgba(247, 147, 26, 0.5); }
}

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

@keyframes colors {
    0% { border-top-color: var(--primary-color); }
    33% { border-top-color: var(--accent-1); }
    66% { border-top-color: var(--accent-2); }
    100% { border-top-color: var(--primary-color); }
}

@keyframes fadeIn {
    from { opacity: 0; }
    to { opacity: 1; }
}

@keyframes iconFloat {
    0%, 100% { transform: translateY(0); }
    50% { transform: translateY(-3px); }
}

@media (max-width: 768px) {
    .container {
        margin: 0;
        border-radius: 0;
    }

    .header {
        padding: 1.5rem;
    }

    .price-table {
        font-size: 0.9rem;
    }

    .table-container {
        -webkit-overflow-scrolling: touch;
        scroll-behavior: smooth;
    }
}