/* 重置和变量 */
* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

:root {
    /* 深色主题色彩系统 */
    --primary: #00DC82;
    --primary-dark: #00B869;
    --primary-light: #00FF94;
    --primary-rgb: 0, 220, 130;
    
    --accent: #FF6B6B;
    --accent-light: #FF8787;
    --accent-dark: #E85555;
    
    /* 中性色 */
    --bg-dark: #0A0B0E;
    --bg-card: #111318;
    --bg-elevated: #1A1D23;
    --bg-hover: #22262E;
    --bg-active: #2A2F39;
    
    --border: rgba(255, 255, 255, 0.08);
    --border-light: rgba(255, 255, 255, 0.12);
    --border-focus: rgba(0, 220, 130, 0.5);
    
    --text-primary: #FFFFFF;
    --text-secondary: #94A3B8;
    --text-muted: #64748B;
    --text-disabled: #475569;
    
    /* 语义色 */
    --success: #00DC82;
    --warning: #FFB800;
    --error: #FF5555;
    --info: #00B8FF;
    
    /* 阴影 */
    --shadow-sm: 0 2px 8px rgba(0, 0, 0, 0.3);
    --shadow-md: 0 4px 16px rgba(0, 0, 0, 0.4);
    --shadow-lg: 0 8px 32px rgba(0, 0, 0, 0.5);
    --shadow-xl: 0 16px 48px rgba(0, 0, 0, 0.6);
    --shadow-glow: 0 0 40px rgba(0, 220, 130, 0.2);
    
    /* 动画 */
    --transition-fast: 150ms cubic-bezier(0.4, 0, 0.2, 1);
    --transition-base: 250ms cubic-bezier(0.4, 0, 0.2, 1);
    --transition-slow: 350ms cubic-bezier(0.4, 0, 0.2, 1);
    
    /* 布局 */
    --radius-sm: 6px;
    --radius-md: 10px;
    --radius-lg: 16px;
    --radius-xl: 24px;
    --radius-full: 9999px;
}

/* 基础样式 */
body {
    font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", "Noto Sans SC", "Microsoft YaHei", sans-serif;
    background: var(--bg-dark);
    color: var(--text-primary);
    line-height: 1.6;
    font-size: 16px;
    overflow-x: hidden;
    -webkit-font-smoothing: antialiased;
    -moz-osx-font-smoothing: grayscale;
}

/* 应用容器 */
.app {
    position: relative;
    min-height: 100vh;
    display: flex;
    flex-direction: column;
}

/* 背景装饰 */
.bg-decoration {
    position: fixed;
    inset: 0;
    z-index: 0;
    pointer-events: none;
}

.bg-gradient {
    position: absolute;
    inset: 0;
    background: 
        radial-gradient(circle at 20% 50%, rgba(0, 220, 130, 0.1) 0%, transparent 50%),
        radial-gradient(circle at 80% 80%, rgba(255, 107, 107, 0.05) 0%, transparent 50%),
        radial-gradient(circle at 50% 10%, rgba(0, 184, 255, 0.05) 0%, transparent 40%);
}

.bg-pattern {
    position: absolute;
    inset: 0;
    background-image: 
        linear-gradient(rgba(255, 255, 255, 0.01) 1px, transparent 1px),
        linear-gradient(90deg, rgba(255, 255, 255, 0.01) 1px, transparent 1px);
    background-size: 50px 50px;
}

.floating-shapes {
    position: absolute;
    inset: 0;
}

.shape {
    position: absolute;
    border-radius: 50%;
    filter: blur(40px);
    animation: float 20s infinite ease-in-out;
}

.shape-1 {
    width: 300px;
    height: 300px;
    background: rgba(0, 220, 130, 0.1);
    top: 10%;
    left: 10%;
    animation-delay: 0s;
}

.shape-2 {
    width: 200px;
    height: 200px;
    background: rgba(255, 107, 107, 0.08);
    bottom: 20%;
    right: 15%;
    animation-delay: 5s;
}

.shape-3 {
    width: 250px;
    height: 250px;
    background: rgba(0, 184, 255, 0.06);
    top: 50%;
    left: 50%;
    animation-delay: 10s;
}

/* 导航栏 */
.navbar {
    position: relative;
    z-index: 100;
    background: rgba(17, 19, 24, 0.8);
    backdrop-filter: blur(20px);
    border-bottom: 1px solid var(--border);
}

.nav-container {
    max-width: 1280px;
    margin: 0 auto;
    padding: 1rem 2rem;
    display: flex;
    justify-content: space-between;
    align-items: center;
}

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

.brand-icon {
    width: 40px;
    height: 40px;
    background: linear-gradient(135deg, var(--primary), var(--primary-dark));
    border-radius: var(--radius-md);
    display: flex;
    align-items: center;
    justify-content: center;
    color: white;
}

.brand-text {
    font-size: 1.25rem;
    font-weight: 700;
    background: linear-gradient(135deg, var(--text-primary), var(--text-secondary));
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
}

.nav-menu {
    display: flex;
    gap: 0.5rem;
}

.nav-link {
    padding: 0.5rem 1rem;
    color: var(--text-secondary);
    text-decoration: none;
    border-radius: var(--radius-md);
    transition: var(--transition-base);
    font-weight: 500;
}

.nav-link:hover {
    color: var(--text-primary);
    background: var(--bg-hover);
}

.nav-link.primary {
    background: linear-gradient(135deg, var(--primary), var(--primary-dark));
    color: var(--bg-dark);
}

.nav-link.primary:hover {
    transform: translateY(-2px);
    box-shadow: 0 4px 12px rgba(0, 220, 130, 0.4);
}

/* 主容器 */
.main-container {
    position: relative;
    z-index: 10;
    flex: 1;
    max-width: 1280px;
    width: 100%;
    margin: 0 auto;
    padding: 2rem;
}

/* 欢迎区域 */
.welcome-section {
    text-align: center;
    margin-bottom: 3rem;
}

.main-title {
    font-size: 3rem;
    font-weight: 800;
    margin-bottom: 1rem;
    line-height: 1.2;
}

.title-gradient {
    background: linear-gradient(135deg, var(--primary), var(--primary-light));
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
}

.title-light {
    color: var(--text-primary);
}

.main-subtitle {
    font-size: 1.125rem;
    color: var(--text-secondary);
    font-weight: 500;
}

/* 卡片容器 */
.card-container {
    display: grid;
    grid-template-columns: 1fr 320px;
    gap: 2rem;
    align-items: start;
}

/* 主卡片 */
.card-main {
    background: var(--bg-card);
    border-radius: var(--radius-xl);
    border: 1px solid var(--border);
    overflow: hidden;
    box-shadow: var(--shadow-xl);
}

/* 进度容器 */
.progress-container {
    padding: 2rem;
    background: var(--bg-elevated);
    border-bottom: 1px solid var(--border);
}

.progress-line {
    position: relative;
    height: 4px;
    background: var(--bg-active);
    border-radius: var(--radius-full);
    margin-bottom: 2rem;
}

.progress-fill {
    position: absolute;
    left: 0;
    top: 0;
    height: 100%;
    background: linear-gradient(90deg, var(--primary), var(--primary-light));
    border-radius: var(--radius-full);
    width: 25%;
    transition: width var(--transition-slow);
    box-shadow: 0 0 20px rgba(0, 220, 130, 0.5);
}

.progress-steps {
    display: flex;
    justify-content: space-between;
}

.progress-step {
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 0.75rem;
    cursor: pointer;
    transition: var(--transition-base);
}

.step-icon {
    width: 48px;
    height: 48px;
    background: var(--bg-card);
    border: 2px solid var(--border);
    border-radius: var(--radius-full);
    display: flex;
    align-items: center;
    justify-content: center;
    color: var(--text-muted);
    transition: var(--transition-base);
}

.progress-step.active .step-icon {
    background: linear-gradient(135deg, var(--primary), var(--primary-dark));
    border-color: transparent;
    color: var(--bg-dark);
    transform: scale(1.1);
    box-shadow: 0 0 30px rgba(0, 220, 130, 0.5);
}

.progress-step.completed .step-icon {
    background: var(--bg-elevated);
    border-color: var(--success);
    color: var(--success);
}

.step-label {
    font-size: 0.875rem;
    color: var(--text-muted);
    font-weight: 500;
    transition: var(--transition-base);
}

.progress-step.active .step-label {
    color: var(--primary);
}

/* 卡片内容 */
.card-content {
    padding: 2rem;
}

.step-panel {
    display: none;
    animation: fadeInUp var(--transition-base);
}

.step-panel.active {
    display: block;
}

.panel-header {
    margin-bottom: 2rem;
}

.panel-title {
    font-size: 1.75rem;
    font-weight: 700;
    margin-bottom: 0.5rem;
    color: var(--text-primary);
}

.panel-desc {
    color: var(--text-secondary);
}

/* 输入组件 */
.input-group {
    margin-bottom: 1.5rem;
}

.input-label {
    display: block;
    margin-bottom: 0.5rem;
    font-weight: 500;
    color: var(--text-secondary);
}

.input-wrapper {
    position: relative;
}

.input-field,
.textarea-field,
.select-field {
    width: 100%;
    padding: 0.875rem 1rem;
    padding-right: 3rem;
    background: var(--bg-elevated);
    border: 1px solid var(--border);
    border-radius: var(--radius-md);
    color: var(--text-primary);
    font-size: 1rem;
    transition: var(--transition-base);
}

.input-field:focus,
.textarea-field:focus,
.select-field:focus {
    outline: none;
    border-color: var(--primary);
    background: var(--bg-hover);
    box-shadow: 0 0 0 3px rgba(0, 220, 130, 0.1);
}

.input-icon {
    position: absolute;
    right: 1rem;
    top: 50%;
    transform: translateY(-50%);
    color: var(--text-muted);
    pointer-events: none;
}

.textarea-wrapper {
    position: relative;
}

.textarea-field {
    resize: vertical;
    font-family: 'SF Mono', 'Monaco', 'Inconsolata', monospace;
    font-size: 0.875rem;
    line-height: 1.5;
    min-height: 100px;
}

.select-wrapper {
    position: relative;
}

.select-field {
    appearance: none;
    cursor: pointer;
}

.select-icon {
    position: absolute;
    right: 1rem;
    top: 50%;
    transform: translateY(-50%);
    color: var(--text-muted);
    pointer-events: none;
}

.input-tips {
    display: flex;
    align-items: center;
    gap: 0.5rem;
    margin-top: 0.5rem;
    font-size: 0.875rem;
    color: var(--text-muted);
}

.tip-icon {
    font-size: 1rem;
}

/* 按钮 */
.btn {
    padding: 0.875rem 1.5rem;
    border: none;
    border-radius: var(--radius-md);
    font-size: 1rem;
    font-weight: 600;
    cursor: pointer;
    transition: var(--transition-base);
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 0.5rem;
    position: relative;
    overflow: hidden;
}

.btn-primary {
    background: linear-gradient(135deg, var(--primary), var(--primary-dark));
    color: var(--bg-dark);
}

.btn-primary:hover {
    transform: translateY(-2px);
    box-shadow: 0 8px 24px rgba(0, 220, 130, 0.4);
}

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

.btn-ghost {
    background: transparent;
    color: var(--text-secondary);
    border: 1px solid var(--border);
}

.btn-ghost:hover {
    background: var(--bg-hover);
    color: var(--text-primary);
    border-color: var(--border-light);
}

.btn-gradient {
    background: linear-gradient(135deg, var(--primary), var(--accent));
    color: white;
}

.btn-gradient:hover {
    transform: translateY(-2px);
    box-shadow: 0 8px 24px rgba(0, 220, 130, 0.3), 0 8px 24px rgba(255, 107, 107, 0.3);
}

.btn-block {
    width: 100%;
}

.btn-group {
    display: flex;
    gap: 1rem;
    justify-content: space-between;
}

/* 状态卡片 */
.status-card {
    background: var(--bg-elevated);
    border: 1px solid var(--border);
    border-radius: var(--radius-md);
    padding: 1rem;
    display: flex;
    align-items: center;
    gap: 1rem;
    margin-bottom: 1.5rem;
}

.status-card.success {
    border-color: rgba(0, 220, 130, 0.3);
    background: rgba(0, 220, 130, 0.05);
}

.status-icon {
    width: 32px;
    height: 32px;
    background: var(--success);
    color: var(--bg-dark);
    border-radius: var(--radius-full);
    display: flex;
    align-items: center;
    justify-content: center;
    font-weight: bold;
}

.status-text {
    display: flex;
    flex-direction: column;
}

.status-label {
    font-size: 0.875rem;
    color: var(--text-muted);
}

.status-value {
    color: var(--success);
    font-weight: 600;
}

/* 确认卡片 */
.confirm-card {
    background: var(--bg-elevated);
    border: 1px solid var(--border);
    border-radius: var(--radius-md);
    padding: 1.5rem;
    margin-bottom: 1.5rem;
}

.confirm-item {
    display: flex;
    justify-content: space-between;
    padding: 0.75rem 0;
    border-bottom: 1px solid var(--border);
}

.confirm-item:last-child {
    border-bottom: none;
}

.confirm-label {
    color: var(--text-secondary);
}

.confirm-value {
    color: var(--text-primary);
    font-weight: 600;
}

/* 警告卡片 */
.alert-card {
    background: rgba(255, 184, 0, 0.1);
    border: 1px solid rgba(255, 184, 0, 0.3);
    border-radius: var(--radius-md);
    padding: 1rem;
    display: flex;
    gap: 1rem;
    margin-bottom: 1.5rem;
}

.alert-icon {
    font-size: 1.5rem;
}

.alert-content {
    flex: 1;
}

.alert-title {
    font-weight: 600;
    color: var(--warning);
    margin-bottom: 0.25rem;
}

.alert-text {
    font-size: 0.875rem;
    color: var(--text-secondary);
}

/* 结果面板 */
.result-panel {
    text-align: center;
    padding: 3rem 2rem;
}

.processing-animation {
    margin-bottom: 2rem;
}

.processing-circle {
    width: 80px;
    height: 80px;
    margin: 0 auto;
    position: relative;
}

.circle-inner {
    position: absolute;
    inset: 0;
    border: 3px solid var(--bg-active);
    border-radius: var(--radius-full);
}

.circle-outer {
    position: absolute;
    inset: 0;
    border: 3px solid transparent;
    border-top-color: var(--primary);
    border-radius: var(--radius-full);
    animation: spin 1s linear infinite;
}

.result-title {
    font-size: 1.75rem;
    font-weight: 700;
    margin-bottom: 0.5rem;
}

.result-desc {
    color: var(--text-secondary);
    margin-bottom: 2rem;
}

.result-desc.error {
    color: var(--error);
}

.processing-progress {
    max-width: 300px;
    margin: 0 auto;
}

.progress-track {
    height: 6px;
    background: var(--bg-active);
    border-radius: var(--radius-full);
    overflow: hidden;
}

.progress-bar {
    height: 100%;
    background: linear-gradient(90deg, var(--primary), var(--primary-light));
    border-radius: var(--radius-full);
    animation: progressMove 2s ease-in-out infinite;
}

.result-icon {
    width: 80px;
    height: 80px;
    margin: 0 auto 2rem;
    border-radius: var(--radius-full);
    display: flex;
    align-items: center;
    justify-content: center;
    animation: scaleIn var(--transition-slow);
}

.result-icon.success {
    background: linear-gradient(135deg, var(--success), #00B869);
    color: white;
}

.result-icon.error {
    background: linear-gradient(135deg, var(--error), #CC4444);
    color: white;
}

/* 侧边栏 */
.sidebar {
    display: flex;
    flex-direction: column;
    gap: 1.5rem;
}

.info-card {
    background: var(--bg-card);
    border: 1px solid var(--border);
    border-radius: var(--radius-lg);
    padding: 1.5rem;
}

.info-title {
    font-size: 1.125rem;
    font-weight: 600;
    margin-bottom: 1rem;
    color: var(--text-primary);
}

.info-list {
    list-style: none;
    space-y: 0.75rem;
}

.info-list li {
    display: flex;
    align-items: center;
    gap: 0.75rem;
    padding: 0.5rem 0;
    color: var(--text-secondary);
    font-size: 0.875rem;
}

.list-icon {
    font-size: 1.25rem;
}

.security-badges {
    display: flex;
    flex-direction: column;
    gap: 0.75rem;
}

.badge {
    display: flex;
    align-items: center;
    gap: 0.5rem;
    padding: 0.5rem 0.75rem;
    background: var(--bg-elevated);
    border: 1px solid var(--border);
    border-radius: var(--radius-md);
    color: var(--text-secondary);
    font-size: 0.875rem;
}

.badge svg {
    color: var(--primary);
}

/* 页脚 */
.footer {
    position: relative;
    z-index: 10;
    background: var(--bg-card);
    border-top: 1px solid var(--border);
    padding: 2rem;
    margin-top: 4rem;
}

.footer-content {
    max-width: 1280px;
    margin: 0 auto;
    text-align: center;
}

.footer-content p {
    color: var(--text-muted);
    margin-bottom: 1rem;
}

.footer-links {
    display: flex;
    justify-content: center;
    align-items: center;
    gap: 1rem;
}

.footer-links a {
    color: var(--text-secondary);
    text-decoration: none;
    transition: var(--transition-base);
}

.footer-links a:hover {
    color: var(--primary);
}

.footer-links span {
    color: var(--text-disabled);
}

/* Toast容器 */
.toast-container {
    position: fixed;
    bottom: 2rem;
    right: 2rem;
    z-index: 1000;
    display: flex;
    flex-direction: column;
    gap: 1rem;
}

.toast {
    background: var(--bg-elevated);
    border: 1px solid var(--border);
    border-radius: var(--radius-md);
    padding: 1rem 1.5rem;
    display: flex;
    align-items: center;
    gap: 0.75rem;
    min-width: 300px;
    box-shadow: var(--shadow-lg);
    animation: slideInRight var(--transition-base);
}

.toast.success {
    border-color: rgba(0, 220, 130, 0.3);
    background: rgba(0, 220, 130, 0.05);
}

.toast.error {
    border-color: rgba(255, 85, 85, 0.3);
    background: rgba(255, 85, 85, 0.05);
}

/* 全局加载 */
.global-loading {
    position: fixed;
    inset: 0;
    background: rgba(10, 11, 14, 0.9);
    backdrop-filter: blur(10px);
    display: flex;
    align-items: center;
    justify-content: center;
    z-index: 10000;
}

.loading-box {
    background: var(--bg-card);
    border: 1px solid var(--border);
    border-radius: var(--radius-lg);
    padding: 2rem 3rem;
    text-align: center;
    box-shadow: var(--shadow-xl);
}

.loading-spinner {
    width: 48px;
    height: 48px;
    margin: 0 auto 1rem;
    border: 3px solid var(--bg-active);
    border-top-color: var(--primary);
    border-radius: var(--radius-full);
    animation: spin 0.8s linear infinite;
}

.loading-text {
    color: var(--text-secondary);
}

/* 工具类 */
.hidden {
    display: none !important;
}

/* 动画 */
@keyframes float {
    0%, 100% {
        transform: translate(0, 0) scale(1);
    }
    33% {
        transform: translate(30px, -30px) scale(1.05);
    }
    66% {
        transform: translate(-20px, 20px) scale(0.95);
    }
}

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

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

@keyframes scaleIn {
    from {
        transform: scale(0);
        opacity: 0;
    }
    to {
        transform: scale(1);
        opacity: 1;
    }
}

@keyframes slideInRight {
    from {
        transform: translateX(100%);
        opacity: 0;
    }
    to {
        transform: translateX(0);
        opacity: 1;
    }
}

@keyframes progressMove {
    0% {
        width: 0%;
    }
    50% {
        width: 100%;
    }
    100% {
        width: 0%;
    }
}

@keyframes slideOutRight {
    from {
        transform: translateX(0);
        opacity: 1;
    }
    to {
        transform: translateX(100%);
        opacity: 0;
    }
}

/* 响应式设计 */
@media (max-width: 1024px) {
    .card-container {
        grid-template-columns: 1fr;
    }
    
    .sidebar {
        display: grid;
        grid-template-columns: 1fr 1fr;
        gap: 1rem;
    }
}

@media (max-width: 768px) {
    .main-container {
        padding: 1rem;
    }
    
    .main-title {
        font-size: 2rem;
    }
    
    .nav-container {
        padding: 1rem;
    }
    
    .nav-menu {
        display: none;
    }
    
    .card-content {
        padding: 1.5rem;
    }
    
    .btn-group {
        flex-direction: column;
    }
    
    .btn {
        width: 100%;
    }
    
    .sidebar {
        grid-template-columns: 1fr;
    }
    
    .progress-steps {
        gap: 0.5rem;
    }
    
    .step-label {
        display: none;
    }
}