/* 全局样式 */
* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

:root {
    --primary-color: #0068b7;
    --primary-dark: #005091;
    --secondary-color: #0086d1;
    --accent-color: #00a8f0;
    --background: #fafbfc;
    --card-bg: #ffffff;
    --text-primary: #2d3748;
    --text-secondary: #718096;
    --text-light: #a0aec0;
    --border-color: #e2e8f0;
    --success-color: #48bb78;
    --warning-color: #ed8936;
    --error-color: #f56565;
    --shadow-sm: 0 1px 3px 0 rgba(0, 0, 0, 0.1), 0 1px 2px 0 rgba(0, 0, 0, 0.06);
    --shadow-md: 0 4px 6px -1px rgba(0, 0, 0, 0.1), 0 2px 4px -1px rgba(0, 0, 0, 0.06);
    --shadow-lg: 0 10px 15px -3px rgba(0, 0, 0, 0.1), 0 4px 6px -2px rgba(0, 0, 0, 0.05);
    --shadow-xl: 0 20px 25px -5px rgba(0, 0, 0, 0.1), 0 10px 10px -5px rgba(0, 0, 0, 0.04);
    --gradient-primary: linear-gradient(135deg, var(--primary-color) 0%, var(--secondary-color) 100%);
    --gradient-accent: linear-gradient(135deg, var(--accent-color) 0%, var(--primary-color) 100%);
}

body {
	font-family: -apple-system, BlinkMacSystemFont, 'Segoe UI', 'PingFang SC', 'Hiragino Sans GB', 'Microsoft YaHei', 'Helvetica Neue', Arial, 'Noto Sans CJK SC', 'Source Han Sans SC', sans-serif;
    line-height: 1.6;
    color: var(--text-primary);
    background: var(--background);
    font-size: 16px;
    overflow-x: hidden;
    /* 防止动画时出现横向滚动条 */
}

/* 页面加载状态 */
.hero,
.input-section,
.stats-section {
    opacity: 0;
    transform: translateY(15px);
    transition: opacity 0.6s ease-out, transform 0.6s ease-out;
}

/* 动画激活状态 */
.fade-in-simultaneous {
    opacity: 1;
    transform: translateY(0);
}

/* 顶部导航 */
.header {
    background: var(--card-bg);
    border-bottom: 1px solid var(--border-color);
    position: fixed;
    top: 0;
    left: 0;
    right: 0;
    z-index: 1000;
    /* 提高z-index确保在最上层 */
    backdrop-filter: blur(10px);
    box-shadow: var(--shadow-sm);
    transition: background 0.3s ease, backdrop-filter 0.3s ease, box-shadow 0.3s ease;
    will-change: background, backdrop-filter, box-shadow;
}

.header-container {
    max-width: 1200px;
    margin: 0 auto;
    padding: 0 2rem;
    display: flex;
    justify-content: space-between;
    align-items: center;
    height: 70px;
}

.logo {
    display: flex;
    align-items: center;
    gap: 0.75rem;
    font-size: 1.5rem;
    font-weight: 700;
    color: var(--text-primary);
}

.logo i {
    color: var(--primary-color);
    font-size: 1.75rem;
}

.logo-highlight {
    background: var(--gradient-primary);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
}

.nav {
    display: flex;
    align-items: center;
    gap: 2rem;
}

.nav-link {
    display: flex;
    align-items: center;
    gap: 0.5rem;
    color: var(--text-secondary);
    text-decoration: none;
    font-weight: 500;
    transition: all 0.2s ease;
    padding: 0.5rem 1rem;
    border-radius: 8px;
}

.nav-link:hover {
    color: var(--primary-color);
    background: rgba(0, 104, 183, 0.1);
}

.user-info {
    position: relative;
    display: flex;
    align-items: center;
    gap: 0.5rem;
    color: var(--text-secondary);
    font-weight: 500;
    padding: 0.5rem 1rem;
    background: rgba(0, 104, 183, 0.05);
    border-radius: 8px;
    cursor: pointer;
    transition: all 0.2s ease;
}

.user-info:hover {
    background: rgba(0, 104, 183, 0.1);
}

.user-info i {
    color: var(--primary-color);
    font-size: 1.2rem;
}

.user-dropdown {
    position: absolute;
    top: calc(100% + 0.5rem);
    right: 0;
    background: var(--card-bg);
    border: 1px solid var(--border-color);
    border-radius: 12px;
    box-shadow: var(--shadow-lg);
    padding: 1rem;
    min-width: 200px;
    opacity: 0;
    visibility: hidden;
    transform: translateY(-10px);
    transition: all 0.3s ease;
    z-index: 1000;
}

.user-info:hover .user-dropdown {
    opacity: 1;
    visibility: visible;
    transform: translateY(0);
}

.user-name {
    font-weight: 600;
    color: var(--text-primary);
    margin-bottom: 0.25rem;
}


/* 使用户名项的文字风格与扫码/退出保持一致 */
.copy-username-btn .user-name {
    color: var(--text-secondary);
}

.user-contact {
    font-size: 0.9rem;
    color: var(--text-secondary);
}

.user-points {
    font-size: 0.9rem;
    color: var(--primary-color);
    font-weight: 500;
}

/* 扫码与退出按钮样式 */
.scan-code,
.user-name-row,
.logout {
    text-align: left;
    display: flex;
    align-items: center;
    justify-content: start;
    gap: 0.5rem;
    padding: 0.5rem 0.75rem;
    border-radius: 8px;
    color: var(--text-secondary);
    cursor: pointer;
    transition: all 0.2s ease;
}

.scan-code i,
.logout i,
.copy-username-btn i {
    color: var(--primary-color);
    font-size: 1.2rem;
}

.user-name-row:hover {
    background: rgba(0, 104, 183, 0.08);
    color: var(--text-primary);
}

.scan-code:hover {
    background: rgba(7, 193, 96, 0.08);
    color: var(--text-primary);
}

.logout:hover {
    background: rgba(245, 101, 101, 0.08);
    color: var(--text-primary);
}

/* 使三项内容在各自容器内居中 */
/* 三项操作左对齐视觉统一 */
.scan-code,
.logout {
    justify-content: flex-start;
}

/* 宽度撑满，点击区域更友好 */
.user-details .user-name-row,
.user-details .scan-code,
.user-details .logout {
    width: 100%;
}

/* 积分显示样式 */
.user-info-container {
    display: flex;
    align-items: center;
    gap: 0.5rem;
}

.points-display {
    display: none;
    /* 初始隐藏，登录后显示 */
    align-items: center;
    gap: 0.5rem;
    color: var(--primary-color);
    font-weight: 600;
    border-radius: 8px;
    transition: all 0.2s ease;
    white-space: nowrap;
    position: relative;
    overflow: hidden;
}

.points-display::before {
    content: '';
    position: absolute;
    top: 0;
    left: -100%;
    width: 100%;
    height: 100%;
    background: linear-gradient(90deg, transparent, rgba(255, 255, 255, 0.3), transparent);
    transition: left 0.5s ease;
}

.points-display:hover::before {
    left: 100%;
}

.points-display i {
    color: #f59e0b;
    font-size: 1.1rem;
    animation: coin-shine 2s ease-in-out infinite;
}

@keyframes coin-shine {

    0%,
    100% {
        transform: scale(1) rotate(0deg);
    }

    50% {
        transform: scale(1.1) rotate(5deg);
    }
}

.points-text {
    font-size: 0.95rem;
    font-weight: 600;
}

.points-text span {
    color: var(--primary-dark);
    font-weight: 700;
}

/* 登录链接样式 */
.login-link {
    display: flex;
    align-items: center;
    gap: 0.5rem;
    color: var(--primary-color);
    text-decoration: none;
    font-weight: 500;
    padding: 0.75rem 1.25rem;
    background: rgba(0, 104, 183, 0.05);
    border-radius: 8px;
    transition: all 0.2s ease;
    white-space: nowrap;
}

.login-link:hover {
    background: rgba(0, 104, 183, 0.1);
    color: var(--primary-dark);
    transform: translateY(-1px);
    border-color: rgba(0, 104, 183, 0.2);
}

.login-link i {
    font-size: 1rem;
}

/* 用户信息容器样式 */
.user-info-container {
    display: flex;
    align-items: center;
}

/* 主要内容 */
.main {
    min-height: calc(100vh - 150px);
    padding: 2rem 0;
    margin-top: 70px;
}

/* 标题区域 */
.hero {
    text-align: center;
    margin-bottom: 3rem;
    padding: 2rem 2rem 0;
}

.hero-content {
    max-width: 800px;
    margin: 0 auto;
}

.hero-title {
    font-size: 3.5rem;
    font-weight: 700;
    margin-bottom: 1rem;
    background: var(--gradient-primary);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
    line-height: 1.2;
}

.hero-subtitle {
    font-size: 1.25rem;
    color: var(--text-secondary);
    font-weight: 400;
    line-height: 1.6;
}

/* 输入区域 */
.input-section {
    max-width: 1000px;
    margin: 0 auto;
    padding: 0 2rem;
    margin-bottom: 4rem;
}

.input-container {
    background: var(--card-bg);
    border-radius: 16px;
    box-shadow: var(--shadow-lg);
    overflow: hidden;
}

.generate-form {
    padding: 2rem;
}

.main-input-group {
    margin: 1rem 0 2rem 0;
}

.main-input {
    width: 100%;
    min-height: 120px;
    padding: 1.5rem;
    border: 2px solid var(--border-color);
    border-radius: 12px;
    font-size: 1.1rem;
    font-family: inherit;
    line-height: 1.6;
    resize: vertical;
    transition: all 0.3s ease;
    background: #fafbfc;
}

.main-input:focus {
    outline: none;
    border-color: var(--primary-color);
    box-shadow: 0 0 0 3px rgba(0, 104, 183, 0.1);
    background: white;
}

.main-input::placeholder {
    color: var(--text-light);
    font-size: 1.05rem;
}

/* AI优化选项样式 */
.ai-optimize-option {
    margin-top: 1rem;
    margin-bottom: 0.5rem;
}

.checkbox-label {
    display: flex;
    align-items: center;
    cursor: pointer;
    font-size: 0.95rem;
    color: var(--text-secondary);
    user-select: none;
    transition: color 0.2s ease;
}

.checkbox-label:hover {
    color: var(--text-primary);
}

.checkbox-label input[type="checkbox"] {
    position: absolute;
    opacity: 0;
    cursor: pointer;
}

.checkmark {
    height: 18px;
    width: 18px;
    background-color: transparent;
    border: 2px solid var(--border-color);
    border-radius: 4px;
    margin-right: 0.75rem;
    position: relative;
    transition: all 0.2s ease;
    flex-shrink: 0;
}

.checkbox-label:hover .checkmark {
    border-color: var(--primary-color);
}

.checkbox-label input:checked~.checkmark {
    background-color: var(--primary-color);
    border-color: var(--primary-color);
}

.checkmark:after {
    content: "";
    position: absolute;
    display: none;
    left: 5px;
    top: 2px;
    width: 4px;
    height: 8px;
    border: solid white;
    border-width: 0 2px 2px 0;
    transform: rotate(45deg);
}

.checkbox-label input:checked~.checkmark:after {
    display: block;
}

.input-actions {
    display: flex;
    align-items: center;
    gap: 1rem;
    justify-content: flex-end;
    margin-top: 1.5rem;
}

.advanced-btn {
    display: flex;
    align-items: center;
    gap: 0.5rem;
    padding: 0.875rem 1.5rem;
    background: transparent;
    border: 2px solid var(--primary-color);
    color: var(--primary-color);
    border-radius: 10px;
    font-size: 1rem;
    font-weight: 600;
    cursor: pointer;
    transition: all 0.3s ease;
}

.advanced-btn:hover {
    background: var(--primary-color);
    color: white;
    transform: translateY(-1px);
    box-shadow: var(--shadow-md);
}

.generate-btn {
    display: flex;
    align-items: center;
    gap: 0.5rem;
    padding: 0.875rem 2rem;
    background: var(--gradient-primary);
    border: none;
    color: white;
    border-radius: 10px;
    font-size: 1rem;
    font-weight: 600;
    cursor: pointer;
    transition: all 0.3s ease;
    position: relative;
    overflow: hidden;
}

.generate-btn::before {
    content: '';
    position: absolute;
    top: 0;
    left: -100%;
    width: 100%;
    height: 100%;
    background: linear-gradient(90deg, transparent, rgba(255, 255, 255, 0.2), transparent);
    transition: left 0.5s;
}

.generate-btn:hover::before {
    left: 100%;
}

.generate-btn:hover {
    transform: translateY(-2px);
    box-shadow: var(--shadow-lg);
}

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

/* 禁用态（防误触） */
.generate-btn:disabled,
.ai-generate-name-btn:disabled {
    cursor: not-allowed;
    opacity: 0.6;
    pointer-events: none;
    box-shadow: none;
    transform: none;
}

/* 禁用时移除按钮流光与悬浮效果 */
.generate-btn:disabled::before {
    display: none;
}

/* 加载态下的按钮禁用视觉与交互（进一步防误触） */
.generate-btn.loading,
.ai-generate-name-btn.loading {
    cursor: not-allowed;
    opacity: 0.6;
    pointer-events: none;
    box-shadow: none;
    transform: none;
}

.generate-btn.loading::before {
    display: none;
}

/* 高级生成 */
.advanced-options {
    max-height: 0;
    overflow: hidden;
    transition: all 0.4s ease;
    background: #f8fafc;
    border-radius: 12px;
}

.advanced-options.show {
    max-height: 2000px;
    border: 1px solid var(--border-color);
    margin-top: 1.5rem;
}

.ai-generate-name-btn-container {
    display: flex;
    align-items: center;
    justify-content: end;
    gap: 0.5rem;
}

.ai-generate-name-btn {
    display: flex;
    align-items: center;
    gap: 0.5rem;
    padding: 0.5rem 0.75rem;
    background: transparent;
    border: none;
    color: var(--primary-color);
    border-radius: 10px;
    font-size: 1rem;
    font-weight: 600;
    cursor: pointer;
    transition: all 0.3s ease;
}

/* 可点击动态标识 */
.click-hint {
    display: inline-flex;
    align-items: center;
    gap: 0.35rem;
    color: var(--warning-color);
    background: rgba(237, 137, 54, 0.12);
    border: 1px dashed rgba(237, 137, 54, 0.5);
    padding: 0.25rem 0.5rem;
    border-radius: 999px;
    font-size: 0.85rem;
    font-weight: 600;
    cursor: pointer;
    animation: pulse-hint 3s ease-in-out infinite;
    user-select: none;
}

.click-hint--quiet {
    animation: none;
    background: transparent;
    border-color: transparent;
    color: var(--primary-color);
}

.ai-generate-name-btn .fa-hand-pointer {
    transform: rotate(90deg);
    transform-origin: 50% 50%;
}

.click-hint i.fa-hand-pointer {
    animation: hand-nudge 1.6s ease-in-out infinite;
}

@keyframes pulse-hint {
    0%, 100% { transform: scale(1); box-shadow: 0 0 0 0 rgba(237, 137, 54, 0.35); }
    50% { transform: scale(1.05); box-shadow: 0 0 0 6px rgba(237, 137, 54, 0); }
}

@keyframes hand-nudge {
    0%, 100% { transform: rotate(90deg); }
    50% { transform: rotate(102deg); }
}

/* 名称生成独立区块 */
.adv-panel {
    padding: 1rem 0rem;
    border-radius: 10px;
    display: none;
}

.name-gen-section {
    padding: 1.5rem 2rem 0;
}

.name-gen-row {
    display: grid;
    grid-template-columns: 1fr auto;
    gap: 0.75rem;
}

.generate-btn--small {
    padding: 0.65rem 1rem;
}

#nameSuggestions {
    display: grid;
    grid-template-columns: repeat(2, 1fr);
    gap: 0.75rem;
}

#nameSuggestions .radio-item {
    display: flex;
    align-items: center;
    gap: 0.5rem;
    padding: 0.6rem 0.75rem;
    border: 1px solid var(--border-color);
    border-radius: 8px;
    background: #fff;
    cursor: pointer;
    transition: border-color 0.2s ease, box-shadow 0.2s ease, background 0.2s ease;
}

#nameSuggestions .radio-item:hover {
    border-color: var(--primary-color);
    box-shadow: 0 0 0 2px rgba(0, 104, 183, 0.08);
}

#nameSuggestions .radio-item.selected {
    border-color: var(--primary-color);
    background: rgba(0, 104, 183, 0.05);
    box-shadow: 0 0 0 2px rgba(0, 104, 183, 0.12);
}

/* 名称建议头部样式 */
.name-suggestions-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 0.75rem;
}

.copy-all-btn {
    display: inline-flex;
    align-items: center;
    gap: 0.5rem;
    padding: 0.5rem 1rem;
    background: var(--primary-color);
    color: white;
    border: none;
    border-radius: 6px;
    font-size: 0.9rem;
    font-weight: 500;
    cursor: pointer;
    transition: all 0.2s ease;
    box-shadow: var(--shadow-sm);
}

.copy-all-btn:hover {
    background: var(--primary-dark);
    transform: translateY(-1px);
    box-shadow: var(--shadow-md);
}

.copy-all-btn:active {
    transform: translateY(0);
    box-shadow: var(--shadow-sm);
}

.copy-all-btn.copied {
    background: var(--success-color);
    transform: scale(1.05);
}

.copy-all-btn i {
    font-size: 0.85rem;
}

.advanced-header {
    padding: 1.5rem 2rem 1rem;
    border-bottom: 1px solid var(--border-color);
    display: flex;
    justify-content: space-between;
    align-items: center;
}

.advanced-header h3 {
    color: var(--text-primary);
    font-size: 1.25rem;
    font-weight: 600;
}

.optional-note {
    color: var(--text-light);
    font-size: 0.9rem;
}

.advanced-grid {
    padding: 2rem;
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(300px, 1fr));
    gap: 1.5rem;
}

.form-group {
    display: flex;
    flex-direction: column;
    gap: 0.5rem;
}

.form-group-full {
    grid-column: 1 / -1;
}

.form-group label {
    color: var(--text-primary);
    font-weight: 500;
    font-size: 0.95rem;
}

.form-group input,
.form-group textarea,
.form-group select {
    padding: 0.75rem 1rem;
    border: 1px solid var(--border-color);
    border-radius: 8px;
    font-size: 0.95rem;
    font-family: inherit;
    transition: all 0.2s ease;
    background: white;
}

.form-group input:focus,
.form-group textarea:focus,
.form-group select:focus {
    outline: none;
    border-color: var(--primary-color);
    box-shadow: 0 0 0 2px rgba(0, 104, 183, 0.1);
}

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

/* 统计数据 */
.stats-section {
    max-width: 1200px;
    margin: 0 auto;
    padding: 0 2rem;
    margin-bottom: 4rem;
}

.stats-container {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(300px, 1fr));
    gap: 2rem;
}

.stat-item {
    background: var(--card-bg);
    padding: 2rem;
    border-radius: 16px;
    box-shadow: var(--shadow-md);
    display: flex;
    align-items: center;
    gap: 1.5rem;
    transition: all 0.3s ease;
    border: 1px solid var(--border-color);
}

.stat-item:hover {
    transform: translateY(-4px);
    box-shadow: var(--shadow-xl);
}

.stat-icon {
    width: 60px;
    height: 60px;
    display: flex;
    align-items: center;
    justify-content: center;
    border-radius: 12px;
    background: var(--gradient-primary);
    color: white;
    font-size: 1.5rem;
}

.stat-content {
    flex: 1;
}

.stat-number {
    font-size: 2.5rem;
    font-weight: 700;
    color: var(--text-primary);
    line-height: 1.2;
    margin-bottom: 0.25rem;
}

.stat-label {
    color: var(--text-secondary);
    font-size: 1rem;
    font-weight: 500;
}

.stat-note {
    display: flex;
    justify-content: end;
    color: var(--text-secondary);
    font-size: 0.75rem;
    margin-top: 1rem;
}

/* 页脚 */
.footer {
    background: var(--text-primary);
    color: white;
    margin-top: auto;
}

.footer-container {
    max-width: 1200px;
    margin: 0 auto;
    padding: 3rem 2rem 1rem;
}

.footer-content {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(250px, 1fr));
    gap: 2rem;
    margin-bottom: 2rem;
}

.footer-section h4 {
    color: white;
    font-size: 1.1rem;
    font-weight: 600;
    margin-bottom: 1rem;
}

.footer-section p {
    color: var(--text-light);
    font-size: 0.95rem;
    line-height: 1.6;
    margin-bottom: 0.5rem;
}

.footer-bottom {
    padding-top: 2rem;
    border-top: 1px solid #4a5568;
    text-align: center;
    color: var(--text-light);
    font-size: 0.9rem;
}

/* 响应式设计 */
@media (max-width: 768px) {
    .header-container {
        padding: 0 1rem;
        height: 60px;
    }

    .logo {
        font-size: 1.25rem;
    }

    .logo-text {
        display: none;
    }

    .nav {
        gap: 1rem;
    }

    .nav-link {
        padding: 0.5rem !important;
        font-size: 0 !important;
        min-width: 40px;
        justify-content: center !important;
        align-items: center !important;
        display: flex !important;
        gap: 0 !important;
    }

    .nav-link i {
        font-size: 1.2rem !important;
        margin: 0 !important;
        display: block;
    }

    .points-display {
        padding: 0.4rem 0.8rem;
        font-size: 0.85rem;
    }

    .points-display i {
        font-size: 1rem;
    }

    .points-text {
        display: none;
    }

    .user-info {
        padding: 0.5rem;
        min-width: 40px;
        justify-content: center;
    }

    .user-info .points-display i {
        font-size: 1.2rem;
    }

    .points-display {
        padding: 0.4rem 0.8rem;
        font-size: 0.85rem;
    }

    .points-display i {
        font-size: 1rem;
    }

    .points-text {
        font-size: 0.85rem;
    }

    .hero {
        padding: 1rem 1rem 0;
    }

    .hero-title {
        font-size: 2.5rem;
    }

    .hero-subtitle {
        font-size: 1.1rem;
    }

    .input-section {
        padding: 0 1rem;
    }

    .generate-form {
        padding: 1.5rem;
    }

    .input-actions {
        flex-direction: column;
        gap: 0.75rem;
    }

    .advanced-btn,
    .generate-btn {
        width: 100%;
        justify-content: center;
    }

    .advanced-grid {
        grid-template-columns: 1fr;
        padding: 1.5rem;
    }

    .stats-container {
        grid-template-columns: 1fr;
        gap: 1rem;
    }

    .stat-item {
        padding: 1.5rem;
    }

    .stat-number {
        font-size: 2rem;
    }

    .footer-container {
        padding: 2rem 1rem 1rem;
    }

    .footer-content {
        grid-template-columns: 1fr;
        gap: 1.5rem;
    }
}

/* 超小屏幕适配 */
@media (max-width: 480px) {
    .header-container {
        padding: 0 0.75rem;
    }

    .logo-text {
        display: none;
    }

    .nav {
        gap: 0.5rem;
    }

    .nav-link {
        padding: 0.4rem !important;
        font-size: 0 !important;
        min-width: 36px;
        justify-content: center !important;
        align-items: center !important;
        display: flex !important;
        gap: 0 !important;
    }

    .nav-link i {
        font-size: 1.1rem !important;
        margin: 0 !important;
        display: block;
    }

    .points-display {
        padding: 0.3rem 0.6rem;
        font-size: 0.8rem;
    }

    .points-display i {
        font-size: 0.9rem;
    }

    .points-text {
        display: none;
    }

    .user-info {
        padding: 0.4rem;
        font-size: 0.85rem;
        min-width: 36px;
        justify-content: center;
    }

    .user-info .points-display i {
        font-size: 1.1rem;
    }
}

/* 通用模态框样式 */
.modal-overlay {
    display: none;
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: rgba(0, 0, 0, 0.5);
    z-index: 1100;
}

.modal-overlay.show {
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 1.5rem;
    animation: fadeIn 0.25s ease;
}

.modal {
    background: var(--card-bg);
    border-radius: 14px;
    width: 100%;
    max-width: 480px;
    box-shadow: var(--shadow-xl);
    overflow: hidden;
}

.modal-header {
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: 1rem 1.25rem;
    border-bottom: 1px solid var(--border-color);
}

.modal-header h2,
.modal-header h3 {
    margin: 0;
    font-size: 1.15rem;
    color: var(--text-primary);
}

.modal-close {
    background: transparent;
    border: none;
    color: var(--text-light);
    cursor: pointer;
    width: 32px;
    height: 32px;
    border-radius: 6px;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    transition: all 0.2s ease;
}

.modal-close:hover {
    color: var(--text-secondary);
    background: rgba(0, 0, 0, 0.06);
}

.modal-body {
    padding: 1.25rem;
}

.modal-footer {
    padding: 1rem 1.25rem 1.25rem;
    text-align: right;
}

.modal-btn {
    padding: 0.75rem 1.25rem;
    background: var(--primary-color);
    color: #fff;
    border: none;
    border-radius: 8px;
    font-weight: 600;
    cursor: pointer;
    transition: all 0.2s ease;
}

.modal-btn:hover {
    background: var(--primary-dark);
    transform: translateY(-1px);
}

.qr-placeholder {
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    gap: 0.75rem;
    padding: 1.5rem;
    border: 2px dashed var(--border-color);
    border-radius: 12px;
    background: #fafbfc;
}

.qr-placeholder i {
    font-size: 3rem;
    color: #07c160;
}

.qr-placeholder p {
    margin: 0;
    color: var(--text-secondary);
}

/* 二维码图片样式 */
.qr-code-image {
    width: 200px;
    height: 200px;
    object-fit: contain;
    border-radius: 8px;
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.1);
    margin-bottom: 0.5rem;
}

/* 响应式二维码图片 */
@media (max-width: 480px) {
    .qr-code-image {
        width: 160px;
        height: 160px;
    }
}

/* 动画类 */
.fade-in {
    opacity: 0;
    transform: translateY(20px);
    animation: fadeIn 0.6s ease forwards;
}

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



.slide-down {
    animation: slideDown 0.4s ease;
}

@keyframes slideDown {
    from {
        max-height: 0;
        opacity: 0;
    }

    to {
        max-height: 2000px;
        opacity: 1;
    }
}

/* 加载状态 */
.loading {
    position: relative;
    pointer-events: none;
}

.loading::after {
    content: '';
    position: absolute;
    top: 50%;
    left: 50%;
    width: 20px;
    height: 20px;
    margin: -10px 0 0 -10px;
    border: 2px solid transparent;
    border-top: 2px solid white;
    border-radius: 50%;
    animation: spin 1s linear infinite;
}

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

.back-btn {
    display: inline-flex;
    align-items: center;
    gap: 0.5rem;
    padding: 0.75rem 1.5rem;
    background: transparent;
    border: 1px solid var(--border-color);
    color: var(--text-secondary);
    border-radius: 8px;
    font-size: 0.95rem;
    font-weight: 500;
    cursor: pointer;
    transition: all 0.2s ease;
    text-decoration: none;
}

.back-btn:hover {
    background: var(--primary-color);
    color: white;
    border-color: var(--primary-color);
    transform: translateX(-2px);
}