/* 现代步骤指示器样式 */
.step-progress {
    display: flex;
    justify-content: space-between;
    align-items: center;
    max-width: 800px;
    margin: 30px auto;
    position: relative;
    padding: 0 20px;
}

.step-progress::before {
    content: '';
    position: absolute;
    top: 50%;
    left: 0;
    right: 0;
    height: 3px;
    background: #e9ecef;
    z-index: 1;
    transform: translateY(-50%);
}

.step-progress-bar {
    position: absolute;
    top: 50%;
    left: 0;
    height: 3px;
    background: linear-gradient(90deg, #667eea 0%, #764ba2 100%);
    z-index: 2;
    transform: translateY(-50%);
    transition: width 0.5s ease;
}

.step-item {
    display: flex;
    flex-direction: column;
    align-items: center;
    position: relative;
    z-index: 3;
    flex: 0 0 auto; /* 确保项目不会被压缩 */
}

.step-number {
    width: 34px;
    height: 34px;
    border-radius: 50%;
    background: #f8f9fa;
    border: 3px solid #dee2e6;
    display: flex;
    align-items: center;
    justify-content: center;
    font-weight: 600;
    font-size: 16px;
    color: #6c757d;
    position: relative;
    transition: all 0.3s ease;
    margin-bottom: 8px;
}

.step-title {
    font-size: 14px;
    color: #6c757d;
    text-align: center;
    font-weight: 500;
    transition: all 0.3s ease;
    white-space: nowrap;
}

.step-item.active .step-number {
    background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
    border-color: rgba(118, 75, 162, 0.2);
    color: white;
    box-shadow: 0 0 0 5px rgba(118, 75, 162, 0.1);
}

.step-item.active .step-title {
    color: #667eea;
    font-weight: 600;
}

.step-item.completed .step-number {
    background: #667eea;
    border-color: rgba(118, 75, 162, 0.2);
    color: white;
}


/* 动画效果 */
.step-item.active .step-number {
    animation: pulse 1.5s infinite;
}

@keyframes pulse {
    0% {
        box-shadow: 0 0 0 0 rgba(118, 75, 162, 0.4);
    }
    70% {
        box-shadow: 0 0 0 8px rgba(118, 75, 162, 0);
    }
    100% {
        box-shadow: 0 0 0 0 rgba(118, 75, 162, 0);
    }
}

/* 导航按钮容器样式 */
.nav-buttons {
    display: flex;
    justify-content: space-between;
    margin: 30px auto;
    max-width: 600px;
    padding: 0 20px;
    width: 100%;
    box-sizing: border-box;
}

/* 为第一步页面添加特殊的导航按钮容器样式 */
.step1-nav-buttons {
    display: flex;
    justify-content: center;
    margin: 40px auto 30px;
    max-width: 600px;
    padding: 0;
    width: 100%;
    box-sizing: border-box;
}

/* 导航按钮样式 */
.nav-button {
    padding: 12px 24px;
    background: linear-gradient(145deg, #667eea 0%, #8a63d2 100%);
    color: white;
    border: none;
    border-radius: 8px;
    font-size: 16px;
    font-weight: 500;
    cursor: pointer;
    transition: all 0.3s ease;
    box-shadow: 0 4px 12px rgba(102, 126, 234, 0.25);
    min-width: 120px;
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 8px;
    z-index: 100; /* 确保按钮在最顶层 */
}

/* 为第一步页面添加特殊的下一步按钮样式 */
.step1-next-button {
    padding: 14px 30px;
    background: linear-gradient(145deg, #667eea 0%, #8a63d2 100%);
    color: white;
    border: none;
    border-radius: 50px;
    font-size: 18px;
    font-weight: 600;
    cursor: pointer;
    transition: all 0.3s ease;
    box-shadow: 0 6px 16px rgba(102, 126, 234, 0.35);
    min-width: 180px;
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 10px;
    z-index: 100;
    position: relative;
    overflow: hidden;
}

.step1-next-button:hover {
    background: linear-gradient(145deg, #7687ed 0%, #9b74e0 100%);
    transform: translateY(-3px);
    box-shadow: 0 8px 20px rgba(102, 126, 234, 0.45);
}

.step1-next-button:active {
    transform: translateY(-1px);
    box-shadow: 0 4px 12px rgba(102, 126, 234, 0.3);
}

/* 添加光效 */
.step1-next-button::after {
    content: '';
    position: absolute;
    top: 50%;
    left: 50%;
    width: 300%;
    height: 300%;
    background: radial-gradient(circle, rgba(255,255,255,0.3) 10%, transparent 10.01%);
    transform: translate(-50%, -50%) scale(0);
    transition: transform 0.5s ease;
}

.step1-next-button:hover::after {
    transform: translate(-50%, -50%) scale(1);
}

.nav-button:hover {
    background: linear-gradient(145deg, #7687ed 0%, #9b74e0 100%);
    transform: translateY(-2px);
    box-shadow: 0 6px 16px rgba(102, 126, 234, 0.35);
}

.nav-button:active {
    transform: translateY(0);
    box-shadow: 0 2px 8px rgba(102, 126, 234, 0.2);
}

.nav-button i {
    font-size: 14px;
}

.nav-button.prev {
    background: linear-gradient(145deg, #6c757d 0%, #495057 100%);
}

.nav-button.prev:hover {
    background: linear-gradient(145deg, #5a6268 0%, #3d4347 100%);
}

/* 导航按钮禁用状态样式 */
.nav-button:disabled {
    background: linear-gradient(145deg, #c0c0c0 0%, #a0a0a0 100%);
    cursor: not-allowed;
    opacity: 0.6;
    transform: none;
    box-shadow: none;
}

.nav-button:disabled:hover {
    background: linear-gradient(145deg, #c0c0c0 0%, #a0a0a0 100%);
    transform: none;
    box-shadow: none;
}

/* 添加切换按钮样式 */
.switch-buttons {
    display: flex;
    justify-content: center;
    gap: 15px; /* 增加按钮间距 */
    margin-bottom: 20px;
    padding: 10px;
    background-color: rgba(102, 126, 234, 0.1);
    border-radius: 8px; /* 添加圆角 */
    box-shadow: 0 2px 8px rgba(0, 0, 0, 0.1); /* 添加阴影 */
}

.switch-btn {
    padding: 10px 25px; /* 增加内边距 */
    border: 2px solid #667eea;
    background: #fff;
    color: #667eea;
    border-radius: 6px;
    cursor: pointer;
    transition: all 0.3s;
    font-size: 16px; /* 增大字体 */
    font-weight: bold; /* 加粗字体 */
}

.switch-btn.active {
    background: #667eea;
    color: #fff;
    box-shadow: 0 4px 12px rgba(102, 126, 234, 0.3); /* 添加阴影 */
}

.switch-btn:hover {
    background: #7687ed; /* 改变悬停背景色 */
    color: #fff;
}

/* 添加开关按钮样式 */
.toggle-switch {
    position: relative;
    display: flex;
    align-items: center;
    justify-content: flex-start; /* 改为左对齐 */
    gap: 8px;
    margin-bottom: 12px; /* 减小底部间距 */
    padding: 6px 0; /* 减小上下内边距 */
    border-bottom: 1px solid #f0f2f5;
    width: 100%;
}

.toggle-text {
    font-size: 14px;
    font-weight: 500;
    color: #4a5568;
    flex-shrink: 0; /* 防止文本压缩 */
}

.toggle-switch label {
    margin-left: 0; /* 移除左边距 */
}

.toggle-switch input {
    position: absolute;
    opacity: 0;
    width: 0;
    height: 0;
}

.toggle-slider {
    position: relative;
    display: inline-block;
    background-color: #edf2f7;
    border-radius: 20px;
    transition: all 0.3s ease;
    cursor: pointer;
    box-shadow: inset 0 2px 4px rgba(0,0,0,0.1);
}

.toggle-slider:before {
    position: absolute;
    content: "";
    height: 16px;
    width: 16px;
    left: 2px;
    bottom: 2px;
    background-color: white;
    transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
    border-radius: 50%;
    box-shadow: 0 2px 4px rgba(0,0,0,0.1);
}

input:checked + .toggle-slider {
    background-color: #667eea;
    box-shadow: inset 0 2px 4px rgba(102,126,234,0.2);
}

input:checked + .toggle-slider:before {
    transform: translateX(16px);
    box-shadow: 0 2px 4px rgba(102,126,234,0.3);
}

/* 移动端适配 */
@media (max-width: 576px) {
    .step-progress, #service-step-progress {
        padding: 0;
        overflow-x: auto;
        overflow-y: hidden;
        -webkit-overflow-scrolling: touch;
        scroll-behavior: smooth;
        scrollbar-width: none; /* Firefox */
        -ms-overflow-style: none; /* IE and Edge */
        margin: 15px auto;
        justify-content: flex-start;
        gap: 5px;
        padding: 0 5px 15px; /* 底部增加padding以显示滚动条 */
        max-width: 100%;
    }
    
    /* 隐藏滚动条但保留滚动功能 */
    .step-progress::-webkit-scrollbar, #service-step-progress::-webkit-scrollbar {
        display: none;
    }
    
    .step-progress::before, #service-step-progress::before {
        left: 5px;
        right: 5px;
    }
    
    .step-progress-bar, #service-step-bar {
        left: 5px;
    }
    
    .step-progress .step-item, #service-step-progress .step-item {
        margin: 0 8px; /* 减小步骤项目间距 */
        min-width: 50px; /* 减小最小宽度 */
    }
    
    .step-progress .step-item:first-child, #service-step-progress .step-item:first-child {
        margin-left: 0;
    }
    
    .step-progress .step-item:last-child, #service-step-progress .step-item:last-child {
        margin-right: 0;
    }
    
    .step-number {
        width: 26px; /* 减小圆圈大小 */
        height: 26px;
        font-size: 13px;
        margin-bottom: 5px; /* 减小底部间距 */
    }
    
    .step-title {
        font-size: 11px;
        width: 50px; /* 减小宽度 */
        overflow: hidden;
        text-overflow: ellipsis;
        text-align: center;
    }
    
    .nav-buttons {
        position: relative;
        bottom: auto;
        display: flex;
        flex-direction: row;
        justify-content: center;
        align-items: center;
        gap: 18px;
        background: rgba(255, 255, 255, 0.98);
        z-index: 10;
        padding: 18px 6vw 24px 6vw;
        border-radius: 18px;
        box-shadow: 0 2px 16px rgba(99,102,241,0.07);
        backdrop-filter: none;
        -webkit-backdrop-filter: none;
        margin: 32px auto 32px auto;
        max-width: 95vw;
        width: auto;
        transition: all 0.3s cubic-bezier(.4,0,.2,1);
    }
    
    .nav-button {
        border-radius: 14px;
        height: 46px;
        font-weight: 600;
        padding: 0 22px;
        font-size: 16px;
        min-width: 110px;
        max-width: 180px;
        flex: 1 1 110px;
        margin: 0 2px;
        box-shadow: 0 2px 8px rgba(99,102,241,0.08);
        transition: all 0.18s cubic-bezier(.4,0,.2,1);
        position: relative;
        overflow: hidden;
        display: flex;
        justify-content: center;
        align-items: center;
    }
    
    .nav-button:active {
        background: linear-gradient(145deg, #6366f1 0%, #7c3aed 100%);
        filter: brightness(0.96);
        box-shadow: 0 1px 4px rgba(99,102,241,0.13);
    }
    
    .nav-button.prev {
        background: linear-gradient(145deg, #a1a1aa 0%, #52525b 100%);
        color: #fff;
    }
    
    .nav-button.next {
        background: linear-gradient(145deg, #6366f1 0%, #7c3aed 100%);
        color: #fff;
    }

    .switch-buttons {
        padding: 0 10px;
    }
    
    .switch-btn {
        flex: 1;
        padding: 8px 16px;
        font-size: 14px;
    }
    
    /* 针对服务页面的导航按钮进行特殊优化 */
    #service-container .nav-buttons {
        margin-bottom: 30px; /* 增加底部间距，避免被其他元素遮挡 */
    }

    /* 步骤指示小圆点共享样式 */
    .step-progress-indicator {
        display: flex;
        justify-content: center;
        margin-top: 5px;
        gap: 3px; /* 减小间距 */
    }
    
    .step-dot {
        width: 5px; /* 减小小圆点大小 */
        height: 5px;
        border-radius: 50%;
        background-color: #d1d5db;
        transition: all 0.3s ease;
    }
    
    .step-dot.active {
        background-color: #667eea;
        width: 15px; /* 减小激活状态的宽度 */
        border-radius: 3px;
    }
}

/* 超小屏幕适配 */
@media (max-width: 360px) {
    .step-progress, #service-step-progress {
        margin: 12px auto;
        gap: 2px;
        padding: 0 2px 12px;
    }
    
    .step-progress .step-item, #service-step-progress .step-item {
        margin: 0 5px; /* 进一步减小间距 */
        min-width: 40px; /* 进一步减小最小宽度 */
    }
    
    .step-number {
        width: 22px;
        height: 22px;
        font-size: 11px;
        margin-bottom: 3px;
    }
    
    .step-title {
        font-size: 9px;
        width: 40px;
    }
    
    .step-dot {
        width: 4px;
        height: 4px;
    }
    
    .step-dot.active {
        width: 12px;
    }

    .nav-buttons {
        padding: 12px 2vw 16px 2vw;
        border-radius: 10px;
        gap: 8px;
    }
    .nav-button {
        font-size: 13px;
        height: 38px;
        padding: 0 10px;
        border-radius: 8px;
        min-width: 80px;
        max-width: 120px;
    }
}

/* 服务页面步骤指示器样式 */
#service-step-progress {
    display: flex;
    justify-content: space-between;
    align-items: center;
    max-width: 800px;
    margin: 30px auto;
    position: relative;
    padding: 0 20px;
}

#service-step-progress::before {
    content: '';
    position: absolute;
    top: 50%;
    left: 0;
    right: 0;
    height: 3px;
    background: #e9ecef;
    z-index: 1;
    transform: translateY(-50%);
}

#service-step-progress .step-progress-bar {
    position: absolute;
    top: 50%;
    left: 0;
    height: 3px;
    background: linear-gradient(90deg, #667eea 0%, #764ba2 100%);
    z-index: 2;
    transform: translateY(-50%);
    transition: width 0.5s ease;
}

/* 服务页面步骤指示小圆点样式 */
#service-step-indicator {
    display: flex;
    justify-content: center;
    margin-top: 5px;
    gap: 4px;
}

/* 移动端适配 */
@media (max-width: 576px) {
    .step-progress, #service-step-progress {
        padding: 0;
        overflow-x: auto;
        overflow-y: hidden;
        -webkit-overflow-scrolling: touch;
        scroll-behavior: smooth;
        scrollbar-width: none; /* Firefox */
        -ms-overflow-style: none; /* IE and Edge */
        margin: 20px auto;
        justify-content: flex-start;
        gap: 10px;
        padding: 0 10px 15px; /* 底部增加padding以显示滚动条 */
    }
    
    /* 隐藏滚动条但保留滚动功能 */
    .step-progress::-webkit-scrollbar, #service-step-progress::-webkit-scrollbar {
        display: none;
    }
    
    .step-progress::before, #service-step-progress::before {
        left: 10px;
        right: 10px;
    }
    
    .step-progress-bar, #service-step-bar {
        left: 10px;
    }
    
    .step-progress .step-item, #service-step-progress .step-item {
        margin: 0 15px; /* 增加步骤项目间距 */
        min-width: 60px; /* 确保最小宽度 */
    }
    
    .step-progress .step-item:first-child, #service-step-progress .step-item:first-child {
        margin-left: 0;
    }
    
    .step-progress .step-item:last-child, #service-step-progress .step-item:last-child {
        margin-right: 0;
    }
    
    /* 步骤指示小圆点共享样式 */
    .step-progress-indicator {
        display: flex;
        justify-content: center;
        margin-top: 5px;
        gap: 4px;
    }
    
    .step-dot {
        width: 6px;
        height: 6px;
        border-radius: 50%;
        background-color: #d1d5db;
        transition: all 0.3s ease;
    }
    
    .step-dot.active {
        background-color: #667eea;
        width: 18px;
        border-radius: 3px;
    }
}

/* 超小屏幕适配 - 针对非常小的设备 */
@media (max-width: 320px) {
    .step-progress, #service-step-progress {
        margin: 10px auto;
        gap: 1px;
        padding: 0 1px 10px;
    }
    
    .step-progress .step-item, #service-step-progress .step-item {
        margin: 0 3px; /* 极小间距 */
        min-width: 35px; /* 极小宽度 */
    }
    
    .step-number {
        width: 20px;
        height: 20px;
        font-size: 10px;
        margin-bottom: 2px;
    }
    
    .step-title {
        font-size: 8px;
        width: 35px;
    }
    
    .step-dot {
        width: 3px;
        height: 3px;
    }
    
    .step-dot.active {
        width: 10px;
    }
}

/* 移动端自适应步骤指示器 */
.mobile-step-progress {
    display: none;
    flex-direction: column;
    align-items: center;
    margin: 25px auto 30px;
    position: relative;
    padding: 0 15px;
    max-width: 100%;
    width: 100%;
    box-sizing: border-box;
}

.mobile-step-counter {
    font-size: 16px;
    font-weight: 600;
    color: #667eea;
    margin-bottom: 15px;
    background: rgba(102, 126, 234, 0.1);
    padding: 6px 15px;
    border-radius: 20px;
    box-shadow: 0 2px 5px rgba(102, 126, 234, 0.1);
    transition: all 0.3s ease;
    animation: pulse-light 2s infinite;
}

@keyframes pulse-light {
    0% {
        box-shadow: 0 0 0 0 rgba(102, 126, 234, 0.4);
    }
    70% {
        box-shadow: 0 0 0 8px rgba(102, 126, 234, 0);
    }
    100% {
        box-shadow: 0 0 0 0 rgba(102, 126, 234, 0);
    }
}

.mobile-step-bar-container {
    width: 100%;
    height: 6px;
    background: #e9ecef;
    border-radius: 3px;
    position: relative;
    margin-bottom: 20px;
    box-shadow: inset 0 1px 2px rgba(0,0,0,0.05);
    overflow: hidden;
}

.mobile-step-bar {
    height: 100%;
    background: linear-gradient(90deg, #667eea 0%, #764ba2 100%);
    border-radius: 3px;
    transition: width 0.8s cubic-bezier(0.22, 1, 0.36, 1);
    box-shadow: 0 1px 3px rgba(102, 126, 234, 0.3);
    position: relative;
}

.mobile-step-bar::after {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: linear-gradient(
        90deg,
        rgba(255, 255, 255, 0) 0%,
        rgba(255, 255, 255, 0.3) 50%,
        rgba(255, 255, 255, 0) 100%
    );
    animation: shimmer 2s infinite;
    transform: skewX(-20deg);
}

@keyframes shimmer {
    0% {
        transform: translateX(-100%) skewX(-20deg);
    }
    100% {
        transform: translateX(100%) skewX(-20deg);
    }
}

.mobile-step-titles {
    display: flex;
    justify-content: space-between;
    width: 100%;
    position: relative;
}

.mobile-step-titles::before {
    content: '';
    position: absolute;
    top: 50%;
    left: 15%;
    right: 15%;
    height: 1px;
    background: #e9ecef;
    z-index: 0;
}

.mobile-step-title {
    flex: 1;
    text-align: center;
    font-size: 14px;
    color: #6c757d;
    padding: 8px 10px;
    position: relative;
    z-index: 1;
    background: #fff;
    border-radius: 6px;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
    max-width: 33%;
    transition: all 0.3s ease;
    box-shadow: 0 1px 3px rgba(0,0,0,0.05);
}

.mobile-step-title.prev {
    text-align: left;
    color: #a0aec0;
    flex: 0.8;
    transform: translateY(0);
    opacity: 0.8;
}

.mobile-step-title.current {
    font-weight: 600;
    color: #667eea;
    flex: 1.2;
    box-shadow: 0 3px 8px rgba(102, 126, 234, 0.2);
    border: 1px solid rgba(102, 126, 234, 0.25);
    /* transform: translateY(-3px); */
    background: linear-gradient(to bottom, #ffffff, #f9faff);
}

.mobile-step-title.next {
    text-align: right;
    color: #a0aec0;
    flex: 0.8;
    transform: translateY(0);
    opacity: 0.8;
}

/* 第一步样式 - 没有上一步 */
.mobile-step-progress.first-step .mobile-step-titles {
    justify-content: flex-end;
}

.mobile-step-progress.first-step .mobile-step-titles::before {
    left: 40%;
}

.mobile-step-progress.first-step .mobile-step-title.prev {
    display: none;
}

.mobile-step-progress.first-step .mobile-step-title.current {
    flex: 1.5;
    margin-right: 10px;
    text-align: left;
    padding-left: 15px;
    border-left: 3px solid #667eea;
}

.mobile-step-progress.first-step .mobile-step-title.next {
    flex: 1;
}

/* 最后一步样式 - 没有下一步 */
.mobile-step-progress.last-step .mobile-step-titles {
    justify-content: flex-start;
}

.mobile-step-progress.last-step .mobile-step-titles::before {
    right: 40%;
}

.mobile-step-progress.last-step .mobile-step-title.next {
    display: none;
}

.mobile-step-progress.last-step .mobile-step-title.current {
    flex: 1.5;
    margin-left: 10px;
    text-align: right;
    padding-right: 15px;
    border-right: 3px solid #667eea;
}

.mobile-step-progress.last-step .mobile-step-title.prev {
    flex: 1;
}

/* 美化步骤计数器 */
.mobile-step-counter {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    position: relative;
}

.mobile-step-counter::before {
    content: '步骤';
    font-size: 12px;
    font-weight: normal;
    color: #a0aec0;
    margin-right: 5px;
}

.mobile-step-counter::after {
    content: '';
    position: absolute;
    bottom: -5px;
    left: 50%;
    transform: translateX(-50%);
    width: 30px;
    height: 2px;
    background: linear-gradient(90deg, #667eea 0%, #764ba2 100%);
    border-radius: 1px;
}

/* 移动端适配 - 隐藏原步骤指示器，显示移动端版本 */
@media (max-width: 576px) {
    .step-progress, #service-step-progress {
        display: none;
    }
    
    .step-progress-indicator, #service-step-indicator {
        display: none;
    }
    
    .mobile-step-progress {
        display: flex;
    }
}

/* 超小屏幕适配 */
@media (max-width: 360px) {
    .mobile-step-counter {
        font-size: 14px;
        padding: 4px 12px;
        margin-bottom: 12px;
    }
    
    .mobile-step-bar-container {
        height: 5px;
        margin-bottom: 15px;
    }
    
    .mobile-step-title {
        font-size: 12px;
        padding: 6px 8px;
    }
    
    .mobile-step-progress.first-step .mobile-step-title.current,
    .mobile-step-progress.last-step .mobile-step-title.current {
        padding-left: 10px;
        padding-right: 10px;
    }
}

/* 步骤标题动画效果 */
.mobile-step-title.current.animating {
    animation: step-title-pulse 0.5s ease;
}

@keyframes step-title-pulse {
    0% {
        transform: translateY(-3px) scale(1);
    }
    50% {
        transform: translateY(-3px) scale(1.05);
    }
    100% {
        transform: translateY(-3px) scale(1);
    }
}

/* 第一步和最后一步的特殊动画 */
.mobile-step-progress.first-step .mobile-step-title.current.animating {
    animation: step-title-slide-right 0.5s ease;
}

.mobile-step-progress.last-step .mobile-step-title.current.animating {
    animation: step-title-slide-left 0.5s ease;
}

@keyframes step-title-slide-right {
    0% {
        transform: translateX(-10px);
        opacity: 0.7;
    }
    100% {
        transform: translateX(0);
        opacity: 1;
    }
}

@keyframes step-title-slide-left {
    0% {
        transform: translateX(10px);
        opacity: 0.7;
    }
    100% {
        transform: translateX(0);
        opacity: 1;
    }
} 