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

body {
    font-family: -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, Helvetica, Arial, sans-serif;
    background: linear-gradient(135deg, #1e3c72 0%, #2a5298 100%);
    color: #ffffff;
    min-height: 100vh;
    padding-bottom: 20px;
}

.container {
    max-width: 600px;
    margin: 0 auto;
    padding: 15px;
}

/* Header */
.header {
    text-align: center;
    padding: 20px 0;
    border-bottom: 1px solid rgba(255, 255, 255, 0.1);
    margin-bottom: 20px;
}

.header h1 {
    font-size: 28px;
    margin-bottom: 10px;
}

.status {
    display: inline-flex;
    align-items: center;
    gap: 8px;
    padding: 6px 12px;
    background: rgba(255, 255, 255, 0.1);
    border-radius: 20px;
    font-size: 14px;
}

.status-dot {
    width: 8px;
    height: 8px;
    border-radius: 50%;
    background: #ffa500;
    animation: pulse 2s infinite;
}

.status.connected .status-dot {
    background: #00ff88;
}

@keyframes pulse {
    0%, 100% { opacity: 1; }
    50% { opacity: 0.5; }
}

/* Tabs */
.tabs {
    display: flex;
    gap: 10px;
    margin-bottom: 20px;
    background: rgba(255, 255, 255, 0.1);
    padding: 5px;
    border-radius: 12px;
}

.tab-btn {
    flex: 1;
    padding: 12px;
    border: none;
    background: transparent;
    color: rgba(255, 255, 255, 0.7);
    border-radius: 8px;
    cursor: pointer;
    font-size: 14px;
    font-weight: 500;
    transition: all 0.3s;
}

.tab-btn.active {
    background: rgba(255, 255, 255, 0.2);
    color: #ffffff;
}

.tab-btn:hover {
    background: rgba(255, 255, 255, 0.15);
}

/* Tab Content */
.tab-content {
    display: none;
    animation: fadeIn 0.3s;
}

.tab-content.active {
    display: block;
}

@keyframes fadeIn {
    from { opacity: 0; transform: translateY(10px); }
    to { opacity: 1; transform: translateY(0); }
}

/* Price Cards */
.price-cards {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 15px;
    margin-bottom: 20px;
}

.price-card {
    background: rgba(255, 255, 255, 0.1);
    backdrop-filter: blur(10px);
    border-radius: 16px;
    padding: 20px;
    display: flex;
    align-items: center;
    gap: 15px;
    border: 1px solid rgba(255, 255, 255, 0.1);
}

.coin-icon {
    width: 50px;
    height: 50px;
    border-radius: 50%;
    background: linear-gradient(135deg, #f7931a, #ff6b6b);
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 24px;
    font-weight: bold;
}

.eth-card .coin-icon {
    background: linear-gradient(135deg, #627eea, #8b9dc3);
}

.coin-info h3 {
    font-size: 16px;
    margin-bottom: 5px;
}

.coin-info .price {
    font-size: 20px;
    font-weight: bold;
    margin-bottom: 3px;
}

.coin-info .change {
    font-size: 14px;
    color: #00ff88;
}

.coin-info .change.negative {
    color: #ff4757;
}

/* Chart Container */
.chart-container {
    background: rgba(255, 255, 255, 0.1);
    backdrop-filter: blur(10px);
    border-radius: 16px;
    padding: 20px;
    margin-bottom: 20px;
    border: 1px solid rgba(255, 255, 255, 0.1);
}

.chart-container h3 {
    margin-bottom: 15px;
    font-size: 18px;
}

/* Liquidations List */
.liquidations-list {
    background: rgba(255, 255, 255, 0.1);
    backdrop-filter: blur(10px);
    border-radius: 16px;
    padding: 20px;
    border: 1px solid rgba(255, 255, 255, 0.1);
}

.liquidations-list h3 {
    margin-bottom: 15px;
    font-size: 18px;
}

.liquidation-item {
    background: rgba(255, 255, 255, 0.05);
    border-radius: 12px;
    padding: 15px;
    margin-bottom: 10px;
    display: flex;
    justify-content: space-between;
    align-items: center;
    border-left: 4px solid;
}

.liquidation-item.buy {
    border-left-color: #00ff88;
}

.liquidation-item.sell {
    border-left-color: #ff4757;
}

.liq-info h4 {
    font-size: 16px;
    margin-bottom: 5px;
}

.liq-info p {
    font-size: 13px;
    opacity: 0.8;
}

.liq-value {
    text-align: right;
}

.liq-value .amount {
    font-size: 18px;
    font-weight: bold;
    margin-bottom: 3px;
}

.liq-value .side {
    font-size: 12px;
    padding: 4px 8px;
    border-radius: 6px;
    background: rgba(255, 255, 255, 0.1);
}

.liq-value .side.buy {
    background: rgba(0, 255, 136, 0.2);
    color: #00ff88;
}

.liq-value .side.sell {
    background: rgba(255, 71, 87, 0.2);
    color: #ff4757;
}

/* Stats Cards */
.stats-cards {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 15px;
    margin-bottom: 20px;
}

.stat-card {
    background: rgba(255, 255, 255, 0.1);
    backdrop-filter: blur(10px);
    border-radius: 16px;
    padding: 20px;
    text-align: center;
    border: 1px solid rgba(255, 255, 255, 0.1);
}

.stat-card h4 {
    font-size: 14px;
    opacity: 0.8;
    margin-bottom: 10px;
}

.stat-card .stat-value {
    font-size: 24px;
    font-weight: bold;
    color: #00ff88;
}

/* Filter Section */
.filter-section {
    background: rgba(255, 255, 255, 0.1);
    backdrop-filter: blur(10px);
    border-radius: 16px;
    padding: 20px;
    margin-bottom: 20px;
    border: 1px solid rgba(255, 255, 255, 0.1);
}

.filter-section h4 {
    margin-bottom: 15px;
}

.filter-section select {
    width: 100%;
    padding: 12px;
    margin-bottom: 10px;
    border: none;
    border-radius: 8px;
    background: rgba(255, 255, 255, 0.1);
    color: #ffffff;
    font-size: 14px;
}

/* Settings */
.settings-section {
    background: rgba(255, 255, 255, 0.1);
    backdrop-filter: blur(10px);
    border-radius: 16px;
    padding: 20px;
    margin-bottom: 20px;
    border: 1px solid rgba(255, 255, 255, 0.1);
}

.settings-section h3 {
    margin-bottom: 20px;
    font-size: 18px;
}

.setting-item {
    margin-bottom: 20px;
}

.setting-item label {
    display: block;
    margin-bottom: 8px;
    font-size: 14px;
    opacity: 0.9;
}

.setting-item input {
    width: 100%;
    padding: 12px;
    border: none;
    border-radius: 8px;
    background: rgba(255, 255, 255, 0.1);
    color: #ffffff;
    font-size: 16px;
}

.setting-item input:focus {
    outline: 2px solid rgba(255, 255, 255, 0.3);
}

.coins-toggle {
    display: flex;
    flex-direction: column;
    gap: 10px;
}

.coin-toggle-item {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 12px;
    background: rgba(255, 255, 255, 0.05);
    border-radius: 8px;
}

.toggle-switch {
    position: relative;
    width: 50px;
    height: 26px;
    background: rgba(255, 255, 255, 0.2);
    border-radius: 13px;
    cursor: pointer;
    transition: background 0.3s;
}

.toggle-switch.active {
    background: #00ff88;
}

.toggle-switch::after {
    content: '';
    position: absolute;
    top: 3px;
    left: 3px;
    width: 20px;
    height: 20px;
    background: white;
    border-radius: 50%;
    transition: transform 0.3s;
}

.toggle-switch.active::after {
    transform: translateX(24px);
}

.alert-input {
    display: flex;
    gap: 10px;
    margin-bottom: 15px;
}

.alert-input select,
.alert-input input {
    flex: 1;
    padding: 12px;
    border: none;
    border-radius: 8px;
    background: rgba(255, 255, 255, 0.1);
    color: #ffffff;
}

.btn-add {
    padding: 12px 20px;
    background: #00ff88;
    border: none;
    border-radius: 8px;
    color: #1e3c72;
    font-weight: bold;
    cursor: pointer;
    transition: transform 0.2s;
}

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

.alerts-list {
    display: flex;
    flex-direction: column;
    gap: 8px;
}

.alert-item {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 12px;
    background: rgba(255, 255, 255, 0.05);
    border-radius: 8px;
}

.alert-item .coin {
    font-weight: bold;
}

.alert-item .price {
    color: #00ff88;
}

.btn-remove {
    background: #ff4757;
    border: none;
    color: white;
    padding: 6px 12px;
    border-radius: 6px;
    cursor: pointer;
}

.btn-save {
    width: 100%;
    padding: 16px;
    background: linear-gradient(135deg, #00ff88, #00ccff);
    border: none;
    border-radius: 12px;
    color: #1e3c72;
    font-size: 16px;
    font-weight: bold;
    cursor: pointer;
    transition: transform 0.2s;
}

.btn-save:hover {
    transform: scale(1.02);
}

.loading {
    text-align: center;
    padding: 20px;
    opacity: 0.7;
}

/* Responsive */
@media (max-width: 480px) {
    .price-cards {
        grid-template-columns: 1fr;
    }
    
    .header h1 {
        font-size: 24px;
    }
}
