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

body {
    font-family: -apple-system, BlinkMacSystemFont, 'Segoe UI', 'PingFang SC', 'Hiragino Sans GB', 'Microsoft YaHei', sans-serif;
    background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
    min-height: 100vh;
    padding: 20px;
    color: #333;
}

.container {
    max-width: 1400px;
    margin: 0 auto;
}

header {
    text-align: center;
    color: white;
    margin-bottom: 40px;
}

header h1 {
    font-size: 2.5rem;
    margin-bottom: 10px;
    text-shadow: 2px 2px 4px rgba(0, 0, 0, 0.2);
}

header p {
    font-size: 1.1rem;
    opacity: 0.9;
}

.main-content {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 30px;
    align-items: start;
}

/* 预览区域 */
.preview-section {
    background: white;
    border-radius: 20px;
    padding: 30px;
    box-shadow: 0 20px 60px rgba(0, 0, 0, 0.3);
}

.preview-section h2 {
    margin-bottom: 20px;
    color: #667eea;
    font-size: 1.5rem;
}

.card-wrapper {
    display: flex;
    justify-content: center;
    margin-bottom: 20px;
}

/* 个人简介卡片 */
.profile-card {
    width: 100%;
    max-width: 400px;
    background: white;
    border-radius: 20px;
    box-shadow: 0 10px 40px rgba(0, 0, 0, 0.15);
    overflow: hidden;
    position: relative;
    transition: transform 0.3s ease;
}

.profile-card:hover {
    transform: translateY(-5px);
}

.card-background {
    height: 120px;
    background: linear-gradient(135deg, #6366f1 0%, #8b5cf6 100%);
    position: relative;
}

.card-content {
    padding: 80px 30px 30px;
    text-align: center;
    position: relative;
}

.avatar-container {
    width: 120px;
    height: 120px;
    border-radius: 50%;
    overflow: hidden;
    border: 5px solid white;
    position: absolute;
    top: -60px;
    left: 50%;
    transform: translateX(-50%);
    box-shadow: 0 5px 20px rgba(0, 0, 0, 0.2);
}

.avatar-container img {
    width: 100%;
    height: 100%;
    object-fit: cover;
}

.card-name {
    font-size: 1.8rem;
    margin-bottom: 5px;
    color: #1f2937;
}

.card-title {
    font-size: 1rem;
    color: #6366f1;
    margin-bottom: 15px;
    font-weight: 500;
}

.card-bio {
    font-size: 0.95rem;
    color: #6b7280;
    line-height: 1.6;
    margin-bottom: 20px;
}

/* 技能标签 */
.skills-container {
    display: flex;
    flex-wrap: wrap;
    gap: 8px;
    justify-content: center;
    margin-bottom: 20px;
}

.skill-tag {
    padding: 6px 14px;
    background: linear-gradient(135deg, #6366f1 0%, #8b5cf6 100%);
    color: white;
    border-radius: 20px;
    font-size: 0.85rem;
    font-weight: 500;
}

/* 社交媒体链接 */
.social-links {
    display: flex;
    gap: 15px;
    justify-content: center;
    margin-bottom: 20px;
}

.social-link {
    width: 40px;
    height: 40px;
    border-radius: 50%;
    background: linear-gradient(135deg, #6366f1 0%, #8b5cf6 100%);
    color: white;
    display: flex;
    align-items: center;
    justify-content: center;
    text-decoration: none;
    transition: transform 0.3s ease, box-shadow 0.3s ease;
    font-size: 1.1rem;
}

.social-link:hover {
    transform: translateY(-3px);
    box-shadow: 0 5px 15px rgba(99, 102, 241, 0.4);
}

/* 二维码 */
.qrcode-container {
    margin-top: 20px;
    padding-top: 20px;
    border-top: 1px solid #e5e7eb;
}

.qrcode-container img {
    width: 120px;
    height: 120px;
    margin: 0 auto 10px;
    display: block;
    border-radius: 10px;
}

.qrcode-label {
    font-size: 0.85rem;
    color: #6b7280;
}

/* 下载按钮 */
.download-btn {
    width: 100%;
    padding: 15px;
    background: linear-gradient(135deg, #6366f1 0%, #8b5cf6 100%);
    color: white;
    border: none;
    border-radius: 10px;
    font-size: 1rem;
    font-weight: 600;
    cursor: pointer;
    transition: transform 0.3s ease, box-shadow 0.3s ease;
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 10px;
}

.download-btn:hover {
    transform: translateY(-2px);
    box-shadow: 0 10px 25px rgba(99, 102, 241, 0.4);
}

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

/* 编辑区域 */
.editor-section {
    background: white;
    border-radius: 20px;
    padding: 30px;
    box-shadow: 0 20px 60px rgba(0, 0, 0, 0.3);
}

.editor-section h2 {
    margin-bottom: 20px;
    color: #667eea;
    font-size: 1.5rem;
}

.editor-form {
    display: flex;
    flex-direction: column;
    gap: 20px;
}

.form-group {
    display: flex;
    flex-direction: column;
    gap: 8px;
}

.form-group label {
    font-weight: 600;
    color: #374151;
    font-size: 0.95rem;
}

.form-group input[type="text"],
.form-group input[type="url"],
.form-group textarea {
    padding: 12px;
    border: 2px solid #e5e7eb;
    border-radius: 8px;
    font-size: 0.95rem;
    transition: border-color 0.3s ease;
    font-family: inherit;
}

.form-group input[type="text"]:focus,
.form-group input[type="url"]:focus,
.form-group textarea:focus {
    outline: none;
    border-color: #6366f1;
}

.form-group textarea {
    resize: vertical;
}

.form-group input[type="file"] {
    padding: 8px;
    border: 2px dashed #e5e7eb;
    border-radius: 8px;
    cursor: pointer;
}

.form-group input[type="color"] {
    height: 50px;
    border: 2px solid #e5e7eb;
    border-radius: 8px;
    cursor: pointer;
}

.form-group small {
    font-size: 0.85rem;
    color: #6b7280;
    margin-top: 5px;
}

/* 社交媒体输入 */
.social-inputs {
    display: flex;
    flex-direction: column;
    gap: 12px;
}

.social-input-group {
    display: flex;
    align-items: center;
    gap: 10px;
}

.social-input-group i {
    width: 30px;
    font-size: 1.2rem;
    color: #6366f1;
    text-align: center;
}

.social-input-group input {
    flex: 1;
    padding: 10px;
    border: 2px solid #e5e7eb;
    border-radius: 8px;
    font-size: 0.9rem;
    transition: border-color 0.3s ease;
}

.social-input-group input:focus {
    outline: none;
    border-color: #6366f1;
}

/* 响应式设计 */
@media (max-width: 1024px) {
    .main-content {
        grid-template-columns: 1fr;
    }
}

@media (max-width: 768px) {
    header h1 {
        font-size: 2rem;
    }

    .profile-card {
        max-width: 100%;
    }

    .preview-section,
    .editor-section {
        padding: 20px;
    }
}
