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

body {
    font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, "Helvetica Neue", Arial, "Noto Sans", sans-serif, "Apple Color Emoji", "Segoe UI Emoji", "Segoe UI Symbol", "Noto Color Emoji";
    background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
    min-height: 100vh;
    padding: 20px;
    display: flex;
    justify-content: center;
    align-items: center;
}

.container {
    background: white;
    border-radius: 20px;
    box-shadow: 0 20px 60px rgba(0, 0, 0, 0.3);
    max-width: 700px;
    width: 100%;
    padding: 40px;
    position: relative;
}

/* 语言切换器 */
.language-switcher {
    position: absolute;
    top: 20px;
    right: 20px;
    display: flex;
    gap: 10px;
}

.language-switcher button {
    padding: 8px 16px;
    border: 2px solid #667eea;
    background: white;
    color: #667eea;
    border-radius: 20px;
    cursor: pointer;
    font-size: 14px;
    font-weight: 600;
    transition: all 0.3s ease;
}

.language-switcher button:hover {
    background: #f0f0f0;
}

.language-switcher button.active {
    background: #667eea;
    color: white;
}

/* 页面标题 */
header {
    text-align: center;
    margin-bottom: 30px;
}

header h1 {
    color: #333;
    font-size: 32px;
    margin-bottom: 10px;
    font-weight: 700;
}

.subtitle {
    color: #666;
    font-size: 16px;
}

/* 选项卡 */
.tabs {
    display: flex;
    gap: 10px;
    margin-bottom: 30px;
    border-bottom: 2px solid #e0e0e0;
}

.tab-btn {
    flex: 1;
    padding: 15px;
    border: none;
    background: transparent;
    color: #666;
    font-size: 16px;
    font-weight: 600;
    cursor: pointer;
    transition: all 0.3s ease;
    border-bottom: 3px solid transparent;
    margin-bottom: -2px;
}

.tab-btn:hover {
    color: #667eea;
}

.tab-btn.active {
    color: #667eea;
    border-bottom-color: #667eea;
}

/* 面板 */
.panel {
    display: none;
}

.panel.active {
    display: block;
}

/* 表单组 */
.form-group {
    margin-bottom: 20px;
}

.form-group label {
    display: block;
    color: #333;
    font-weight: 600;
    margin-bottom: 8px;
    font-size: 14px;
}

.form-group select,
.form-group input,
.form-group textarea {
    width: 100%;
    padding: 12px 15px;
    border: 2px solid #e0e0e0;
    border-radius: 10px;
    font-size: 14px;
    transition: all 0.3s ease;
    font-family: inherit;
}

.form-group select:focus,
.form-group input:focus,
.form-group textarea:focus {
    outline: none;
    border-color: #667eea;
    box-shadow: 0 0 0 3px rgba(102, 126, 234, 0.1);
}

.form-group textarea {
    resize: vertical;
    min-height: 80px;
}

.hint {
    margin-top: 5px;
    font-size: 12px;
    color: #999;
}

/* 按钮 */
.btn-primary {
    width: 100%;
    padding: 15px;
    background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
    color: white;
    border: none;
    border-radius: 10px;
    font-size: 16px;
    font-weight: 600;
    cursor: pointer;
    transition: all 0.3s ease;
    box-shadow: 0 4px 15px rgba(102, 126, 234, 0.4);
}

.btn-primary:hover {
    transform: translateY(-2px);
    box-shadow: 0 6px 20px rgba(102, 126, 234, 0.6);
}

.btn-primary:active {
    transform: translateY(0);
}

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

/* 结果框 */
.result-box {
    margin-top: 20px;
    padding: 20px;
    border-radius: 10px;
    animation: fadeIn 0.3s ease;
}

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

.result-box.success {
    background: #d4edda;
    border: 2px solid #28a745;
    color: #155724;
}

.result-box.error {
    background: #f8d7da;
    border: 2px solid #dc3545;
    color: #721c24;
}

.result-box.warning {
    background: #fff3cd;
    border: 2px solid #ffc107;
    color: #856404;
}

.result-box h3 {
    margin-bottom: 10px;
    font-size: 18px;
}

.result-box p {
    margin-bottom: 8px;
    line-height: 1.6;
}

.result-box strong {
    font-weight: 600;
}

/* 币种列表 */
.coin-list {
    margin-top: 15px;
}

.coin-item {
    background: white;
    padding: 15px;
    border-radius: 8px;
    margin-bottom: 10px;
    border: 1px solid #ddd;
}

.coin-item h4 {
    color: #333;
    margin-bottom: 5px;
    font-size: 16px;
}

.coin-item p {
    color: #666;
    font-size: 14px;
    margin: 3px 0;
}

.coin-item .coin-id {
    color: #667eea;
    font-weight: 600;
}

/* 加载动画 */
.loading {
    display: inline-block;
    width: 20px;
    height: 20px;
    border: 3px solid rgba(255, 255, 255, 0.3);
    border-radius: 50%;
    border-top-color: white;
    animation: spin 0.8s linear infinite;
}

@keyframes spin {
    to {
        transform: rotate(360deg);
    }
}

/* 页脚 */
footer {
    margin-top: 30px;
    text-align: center;
    color: #999;
    font-size: 14px;
    padding-top: 20px;
    border-top: 1px solid #e0e0e0;
}

/* 响应式设计 */
@media (max-width: 768px) {
    .container {
        padding: 30px 20px;
    }

    header h1 {
        font-size: 24px;
    }

    .language-switcher {
        position: static;
        justify-content: center;
        margin-bottom: 20px;
    }

    .tab-btn {
        font-size: 14px;
        padding: 12px;
    }
}
