/* 基础样式 */
* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

body {
    font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", "Microsoft YaHei", "微软雅黑", sans-serif;
    background-color: #f5f7fa;
    color: #333;
    line-height: 1.6;
}

/* 容器布局 */
.container {
    display: flex;
    min-height: 100vh;
    max-width: 1400px;
    margin: 0 auto;
    padding: 20px;
    gap: 24px;
}

/* 左侧面板 */
.left-panel {
    flex: 0 0 400px;
    background: #fff;
    border-radius: 12px;
    padding: 32px;
    box-shadow: 0 2px 12px rgba(0, 0, 0, 0.08);
}

.left-panel h1 {
    font-size: 24px;
    color: #1a1a1a;
    margin-bottom: 8px;
}

.subtitle {
    color: #666;
    font-size: 14px;
    margin-bottom: 32px;
}

/* 表单样式 */
.form-group {
    margin-bottom: 24px;
}

.form-group > label {
    display: block;
    font-weight: 500;
    margin-bottom: 8px;
    color: #333;
}

/* 文件上传 */
.file-input-wrapper {
    position: relative;
}

.file-input-wrapper input[type="file"] {
    width: 100%;
    padding: 12px;
    border: 2px dashed #d9d9d9;
    border-radius: 8px;
    background: #fafafa;
    cursor: pointer;
    transition: border-color 0.3s;
}

.file-input-wrapper input[type="file"]:hover {
    border-color: #1890ff;
}

.file-input-wrapper input[type="file"]:focus {
    outline: none;
    border-color: #1890ff;
}

.file-hint {
    display: block;
    font-size: 12px;
    color: #999;
    margin-top: 6px;
}

.file-name {
    margin-top: 8px;
    font-size: 14px;
    color: #1890ff;
    word-break: break-all;
}

/* 单选框组 */
.radio-group {
    display: flex;
    gap: 24px;
}

.radio-label {
    display: flex;
    align-items: center;
    cursor: pointer;
}

.radio-label input[type="radio"] {
    width: 18px;
    height: 18px;
    margin-right: 8px;
    cursor: pointer;
}

.radio-text {
    font-size: 15px;
}

/* 按钮样式 */
.btn-primary {
    width: 100%;
    padding: 14px 24px;
    background: #1890ff;
    color: #fff;
    border: none;
    border-radius: 8px;
    font-size: 16px;
    font-weight: 500;
    cursor: pointer;
    transition: background 0.3s;
}

.btn-primary:hover {
    background: #40a9ff;
}

.btn-primary:disabled {
    background: #d9d9d9;
    cursor: not-allowed;
}

.btn-primary.loading {
    background: #69c0ff;
}

/* 结果区域 */
.result-area {
    margin-top: 24px;
    padding: 16px;
    border-radius: 8px;
    font-size: 14px;
    display: none;
}

.result-area.show {
    display: block;
}

.result-area.success {
    background: #f6ffed;
    border: 1px solid #b7eb8f;
    color: #52c41a;
}

.result-area.error {
    background: #fff2f0;
    border: 1px solid #ffccc7;
    color: #ff4d4f;
}

.result-area.loading {
    background: #e6f7ff;
    border: 1px solid #91d5ff;
    color: #1890ff;
}

/* 右侧面板 */
.right-panel {
    flex: 1;
    background: #fff;
    border-radius: 12px;
    padding: 32px;
    box-shadow: 0 2px 12px rgba(0, 0, 0, 0.08);
    overflow-y: auto;
}

.right-panel h2 {
    font-size: 20px;
    color: #1a1a1a;
    margin-bottom: 24px;
    padding-bottom: 12px;
    border-bottom: 2px solid #f0f0f0;
}

/* 文档说明区块 */
.doc-section {
    margin-bottom: 32px;
}

.doc-section:last-child {
    margin-bottom: 0;
}

.doc-section h3 {
    font-size: 18px;
    color: #333;
    margin-bottom: 16px;
    padding-left: 12px;
    border-left: 4px solid #1890ff;
}

.doc-example,
.doc-rules {
    margin-bottom: 16px;
}

.doc-example h4,
.doc-rules h4 {
    font-size: 14px;
    color: #666;
    margin-bottom: 8px;
}

.doc-example pre {
    background: #f5f5f5;
    padding: 16px;
    border-radius: 8px;
    font-size: 13px;
    line-height: 1.8;
    overflow-x: auto;
    white-space: pre-wrap;
    word-wrap: break-word;
    font-family: "Consolas", "Monaco", "Microsoft YaHei", monospace;
}

.doc-rules ol {
    padding-left: 20px;
}

.doc-rules li {
    margin-bottom: 8px;
    font-size: 14px;
    color: #555;
}

/* 响应式布局 */
@media (max-width: 900px) {
    .container {
        flex-direction: column;
    }

    .left-panel {
        flex: none;
        width: 100%;
    }

    .right-panel {
        flex: none;
    }
}
