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

body {
    font-family: -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, 'Helvetica Neue', Arial, sans-serif;
    background-color: #f7f8fc;
    color: #333;
    overflow-x: hidden; /* 防止水平滚动条 */
}

/* 移动端导航按钮样式 */
.mobile-nav-toggle {
    position: fixed;
    top: 16px;
    left: 16px;
    width: 44px;
    height: 44px;
    background: #fff;
    border: none;
    border-radius: 8px;
    box-shadow: 0 2px 8px rgba(0, 0, 0, 0.1);
    z-index: 1001;
    display: none;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    gap: 4px;
    cursor: pointer;
    transition: all 0.3s ease;
}

.mobile-nav-toggle:hover {
    background: #f8f9fa;
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.15);
}

.hamburger-line {
    width: 20px;
    height: 2px;
    background: #333;
    transition: all 0.3s ease;
    border-radius: 1px;
}

.mobile-nav-toggle.active .hamburger-line:nth-child(1) {
    transform: rotate(45deg) translate(6px, 6px);
}

.mobile-nav-toggle.active .hamburger-line:nth-child(2) {
    opacity: 0;
}

.mobile-nav-toggle.active .hamburger-line:nth-child(3) {
    transform: rotate(-45deg) translate(6px, -6px);
}

/* 移动端导航遮罩层 */
.mobile-nav-overlay {
    position: fixed;
    top: 0;
    left: 0;
    width: 100vw;
    height: 100vh;
    background: rgba(0, 0, 0, 0.5);
    z-index: 999;
    opacity: 0;
    visibility: hidden;
    transition: all 0.3s ease;
}

.mobile-nav-overlay.active {
    opacity: 1;
    visibility: visible;
}

/* Font Awesome 图标字体保护 */
.fas, .far, .fab, .fal, .fad, .fa {
    font-family: "Font Awesome 6 Free", "Font Awesome 6 Pro", "Font Awesome 5 Free", "Font Awesome 5 Pro", "FontAwesome" !important;
    font-style: normal !important;
    font-variant: normal !important;
    text-rendering: auto !important;
    -webkit-font-smoothing: antialiased !important;
    -moz-osx-font-smoothing: grayscale !important;
}

.fas {
    font-weight: 900 !important;
}

.far {
    font-weight: 400 !important;
}

.fab {
    font-weight: 400 !important;
}

/* 确保导航图标使用正确的字体 */
.icon-nav-item i,
.secondary-header i,
.icon-navigation i,
.icon-nav-bottom i {
    font-family: "Font Awesome 6 Free", "Font Awesome 6 Pro", "Font Awesome 5 Free", "Font Awesome 5 Pro", "FontAwesome" !important;
    font-style: normal !important;
    font-variant: normal !important;
    text-rendering: auto !important;
    -webkit-font-smoothing: antialiased !important;
    -moz-osx-font-smoothing: grayscale !important;
}

/* 左侧图标导航栏 */
.icon-sidebar {
    position: fixed;
    top: 8px;
    left: 8px;
    width: 60px;
    height: calc(100vh - 16px);
    background-color: #f8f9fa;
    border-radius: 12px;
    z-index: 1000;
    display: flex;
    flex-direction: column;
    box-shadow: 0 2px 8px rgba(0, 0, 0, 0.1);
}

.icon-nav-container {
    display: flex;
    flex-direction: column;
    align-items: center;
    padding: 16px 0;
    height: 100%;
    justify-content: space-between;
}

.icon-nav-logo {
    margin-bottom: 16px;
    display: flex;
    justify-content: center;
    align-items: center;
}

.logo-image {
    width: 40px;
    height: 40px;
    border-radius: 8px;
}

.icon-nav-item {
    width: 48px;
    height: 48px;
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    border-radius: 8px;
    cursor: pointer;
    transition: all 0.2s ease;
    margin-bottom: 4px;
    position: relative;
    background-color: transparent;
    border: none;
    padding: 4px;
}

.icon-nav-item:hover {
    background-color: rgba(0, 0, 0, 0.05);
}

.icon-nav-item.active {
    background-color: #e5e7eb;
    border: none;
    border-radius: 8px;
}

.icon-nav-item i {
    font-size: 18px;
    color: #666;
    margin-bottom: 2px;
}

.icon-nav-item.active i {
    color: #333;
}

.icon-text {
    font-size: 10px;
    color: #666;
    text-align: center;
    line-height: 1;
    max-width: 44px;
    overflow: hidden;
    text-overflow: ellipsis;
    white-space: nowrap;
}

.icon-nav-item.active .icon-text {
    color: #333;
}

.icon-navigation {
    list-style: none;
    padding: 0;
    margin: 0;
    display: flex;
    flex-direction: column;
    align-items: center;
    flex: 1;
}

.icon-nav-bottom {
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 4px;
}

/* 二级导航栏 */
.secondary-sidebar {
    position: fixed;
    top: 8px;
    left: 76px; /* 60px + 8px + 8px */
    width: 349px;
    height: calc(100vh - 16px);
    background-color: #fff;
    border-radius: 12px;
    z-index: 1000;
    overflow-y: auto;
    box-shadow: 0 2px 8px rgba(0, 0, 0, 0.1);
}

.secondary-nav-container {
    padding: 16px 0;
}

.secondary-section {
    display: none;
}

.secondary-section.active {
    display: block;
}

.secondary-header {
    display: flex;
    align-items: center;
    padding: 16px 20px;
    font-weight: 600;
    font-size: 15px;
    color: #333;
    border-bottom: 1px solid #f0f0f0;
    cursor: pointer;
}

.secondary-header i {
    margin-right: 12px;
    color: #4f46e5;
    font-size: 16px;
}

.secondary-menu {
    list-style: none;
    padding: 8px 0;
    margin: 0;
}

.secondary-menu li {
    margin: 2px 0;
}

.secondary-menu a {
    display: block;
    padding: 10px 20px;
    color: #666;
    text-decoration: none;
    font-size: 14px;
    transition: all 0.2s ease;
    border-radius: 6px;
    margin: 0 12px;
}

.secondary-menu a:hover {
    background-color: #f8f9fa;
    color: #333;
}

.secondary-menu a.active {
    background-color: #e3f2fd;
    color: #1976d2;
    font-weight: 500;
}

.secondary-section-bottom {
    margin-top: 20px;
    border-top: 1px solid #f0f0f0;
    padding-top: 16px;
}

/* 主内容区域 */
.main-content-area {
    margin-left: calc(433px + (100vw - 433px - 1588px) / 2); /* 左侧导航宽度 + 剩余空间的一半作为间距 */
    margin-top: 8px;
    margin-right: auto; /* 右侧自动间距 */
    margin-bottom: 8px;
    padding: 20px;
    min-height: calc(100vh - 16px);
    width: 1588px; /* 固定宽度 */
    max-width: calc(100vw - 433px - 40px); /* 小屏幕时确保不溢出 */
    overflow-x: hidden;
    box-sizing: border-box;
}

/* 确保内容不会超出屏幕 */
.top-search-bar, .banner-section, .content-list {
    max-width: 100%;
    box-sizing: border-box;
}

/* 顶部固定搜索栏样式 */
.top-search-bar {
    background-color: transparent;
    border-radius: 0;
    padding: 20px;
    margin-bottom: 20px;
    box-shadow: none;
    border: none;
    position: sticky;
    top: 8px;
    z-index: 10;
}

/* 新的搜索栏布局样式 */
.search-layout {
    display: flex;
    align-items: center;
    justify-content: space-between;
    height: 32px;
    width: 100%;
    gap: 20px;
}

.page-title {
    margin: 0;
    font-size: 20px;
    font-weight: 600;
    color: #374151;
    white-space: nowrap;
    flex-shrink: 0;
}

.search-container-flex {
    width: 480px;
    height: 32px;
    flex-shrink: 1;
    min-width: 200px;
}

.search-container-flex .input-group {
    height: 32px;
    width: 480px;
    box-shadow: 0 2px 8px rgba(0, 0, 0, 0.1);
    border-radius: 6px;
    overflow: hidden;
    display: flex;
}

.search-container-flex .input-group-text {
    background-color: white;
    border: none;
    color: #6c757d;
    padding: 0 12px;
    height: 32px;
    display: flex;
    align-items: center;
    flex-shrink: 0;
    width: auto;
}

.search-container-flex .form-control {
    border: none;
    height: 32px;
    padding: 0 15px;
    font-size: 14px;
    line-height: 32px;
    text-align: center;
    flex: 1;
    width: auto;
}

.search-container-flex .form-control::placeholder {
    text-align: center;
    color: #9ca3af;
}

.search-container-flex .form-control:focus {
    box-shadow: none;
    border-color: transparent;
    text-align: left;
}

.upload-btn-container {
    flex-shrink: 0;
}

.upload-agent-btn {
    background-color: #4f46e5;
    border: none;
    padding: 8px 24px;
    font-weight: 600;
    border-radius: 8px;
    white-space: nowrap;
    height: 32px;
    font-size: 14px;
    line-height: 16px;
}

.upload-agent-btn:hover {
    background-color: #4338ca;
}

/* 横幅区域独立样式 */
.banner-section {
    margin-bottom: 20px;
}

.top-search-bar .search-container {
    margin-top: 16px;
}

/* 标签导航样式 */
.tab-navigation {
    margin-top: 20px;
    border-bottom: 1px solid #e5e7eb;
}

.tab-navigation .nav-tabs {
    border-bottom: none;
}

.tab-navigation .nav-link {
    border: none;
    color: #6b7280;
    font-weight: 500;
    padding: 12px 20px;
    background: none;
    transition: all 0.2s ease;
}

.tab-navigation .nav-link:hover {
    color: #374151;
    background-color: #f9fafb;
    border-color: transparent;
}

.tab-navigation .nav-link.active {
    color: #4f46e5;
    background-color: transparent;
    border-color: transparent;
    border-bottom: 2px solid #4f46e5;
    font-weight: 600;
}

/* 自动加载指示器 */
.auto-load-indicator {
    color: #6b7280;
    font-size: 14px;
    padding: 20px;
}

.search-container .input-group {
    box-shadow: 0 2px 8px rgba(0, 0, 0, 0.1);
    border-radius: 12px;
    overflow: hidden;
}

.search-container .input-group-text {
    background-color: white;
    border: none;
    color: #6c757d;
}

.search-container .form-control {
    border: none;
    padding: 15px;
    font-size: 16px;
}

.search-container .form-control:focus {
    box-shadow: none;
    border-color: transparent;
}

/* 横幅广告样式 */
.banner-card {
    background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
    border-radius: 16px;
    overflow: hidden;
    min-height: 180px;
    position: relative;
    width: 100%;
    max-width: 100%;
}

.banner-content {
    display: flex;
    align-items: center;
    padding: 32px;
    height: 100%;
    width: 100%;
    box-sizing: border-box;
}

.banner-text {
    flex: 1;
    color: white;
}

.banner-title {
    font-size: 28px;
    font-weight: 700;
    margin-bottom: 12px;
    line-height: 1.3;
}

.banner-description {
    font-size: 16px;
    opacity: 0.9;
    margin-bottom: 24px;
    line-height: 1.5;
}

.banner-btn {
    background-color: #1a1a1a;
    border: none;
    padding: 12px 24px;
    font-weight: 600;
    border-radius: 8px;
    color: white;
    font-size: 14px;
}

.banner-image {
    margin-left: 40px;
}

.product-seeker-card {
    width: 280px;
    height: 160px;
    background: rgba(255, 255, 255, 0.95);
    border-radius: 12px;
    padding: 16px;
    box-shadow: 0 8px 32px rgba(0, 0, 0, 0.1);
    backdrop-filter: blur(10px);
    position: relative;
    overflow: hidden;
}

.ps-header {
    display: flex;
    align-items: center;
    margin-bottom: 12px;
}

.ps-logo {
    width: 40px;
    height: 40px;
    background: linear-gradient(135deg, #3b82f6 0%, #1d4ed8 100%);
    border-radius: 8px;
    display: flex;
    align-items: center;
    justify-content: center;
    color: white;
    font-weight: bold;
    font-size: 18px;
    margin-right: 12px;
}

.ps-title {
    font-weight: 600;
}

.ps-subtitle {
    color: #666;
    font-size: 12px;
}

.ps-screens {
    height: 80px;
    background: linear-gradient(135deg, #f0f2f5 0%, #e8eaf6 100%);
    border-radius: 8px;
    opacity: 0.8;
}

/* 内容列表样式 */
.content-list {
    width: 100%;
}

/* 卡片网格布局 */
.app-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(300px, 1fr));
    gap: 20px;
    width: 100%;
}

.app-card {
    background: white;
    border-radius: 12px;
    padding: 16px;
    margin-bottom: 20px;
    box-shadow: 0 2px 8px rgba(0, 0, 0, 0.1);
    transition: all 0.3s ease;
    height: 225px;
    max-width: 385px;
    display: flex;
    flex-direction: column;
    justify-content: space-between;
}

.app-card:hover {
    transform: translateY(-2px);
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.15);
}

.app-card-header {
    display: flex;
    justify-content: space-between;
    align-items: flex-start;
    margin-bottom: 12px;
}

.app-main-row {
    display: flex;
    align-items: flex-start;
    gap: 12px;
    flex: 1;
}

.app-info-column {
    flex: 1;
    min-width: 0;
    display: flex;
    flex-direction: column;
    gap: 4px;
}

.app-badge-container {
    display: flex;
    align-items: center;
}

.app-type-badge {
    background-color: #4f46e5;
    color: white;
    font-size: 10px;
    padding: 4px 8px;
    border-radius: 4px;
    font-weight: 500;
}

.app-content {
    flex-grow: 1;
    display: flex;
    flex-direction: column;
}

.app-creator {
    display: flex;
    align-items: center;
    margin-bottom: 8px;
}

.creator-avatar {
    width: 20px;
    height: 20px;
    border-radius: 50%;
    background-color: #e3f2fd;
    display: flex;
    align-items: center;
    justify-content: center;
    margin-right: 8px;
    font-size: 10px;
    color: #1976d2;
}

.creator-avatar i {
    font-size: 10px;
}

.creator-name {
    font-size: 12px;
    color: #666;
    margin: 0;
}

.creator-id {
    color: #999;
}

.app-footer {
    display: flex;
    justify-content: flex-end;
    align-items: center;
    margin-top: auto;
    padding-top: 12px;
    border-top: 1px solid #f0f0f0;
}

.app-action {
    display: flex;
    justify-content: flex-end;
}

.app-icon {
    width: 62px;
    height: 62px;
    background-color: #1a1a1a;
    color: white;
    border-radius: 8px;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 24px;
    font-weight: bold;
    flex-shrink: 0;
}

.app-card-actions {
    display: flex;
    gap: 8px;
}

.app-card-actions .action-btn {
    width: 32px;
    height: 32px;
    border: none;
    background: #f8f9fa;
    border-radius: 6px;
    display: flex;
    align-items: center;
    justify-content: center;
    color: #666;
    cursor: pointer;
    transition: all 0.2s ease;
    font-size: 14px;
}

.app-card-actions .action-btn:hover {
    background: #e9ecef;
    color: #333;
}

.app-title {
    font-size: 18px;
    font-weight: 600;
    margin: 0 0 4px 0;
    line-height: 1.3;
    color: #333;
}

.app-description {
    font-size: 14px;
    color: #666;
    line-height: 1.4;
    margin-bottom: 8px;
    flex-grow: 1;
}

.try-now-btn {
    background-color: #4f46e5;
    color: white;
    border: none;
    padding: 8px 16px;
    border-radius: 6px;
    font-size: 12px;
    font-weight: 500;
    cursor: pointer;
    transition: background-color 0.2s ease;
}

.try-now-btn:hover {
    background-color: #4338ca;
}

.app-status {
    font-size: 12px;
    padding: 2px 6px;
    border-radius: 3px;
}

.app-badge {
    display: inline-block;
    padding: 2px 6px;
    border-radius: 4px;
    font-size: 10px;
    font-weight: 500;
    text-transform: uppercase;
    background-color: #e3f2fd;
    color: #1976d2;
}

.app-category {
    background-color: #f3e5f5;
    color: #7b1fa2;
    font-size: 10px;
    padding: 4px 8px;
    border-radius: 12px;
    font-weight: 500;
    white-space: nowrap;
}

/* 响应式设计 */

/* 小平板 (768px+): 折叠导航，卡片每行2个 */
@media (min-width: 768px) and (max-width: 1023px) {
    .mobile-nav-toggle {
        display: flex;
    }
    
    .icon-sidebar {
        display: none;
        transition: all 0.3s ease;
    }
    
    .icon-sidebar.mobile-open {
        display: flex;
        transform: translateX(0);
        animation: slideInLeft 0.3s ease;
    }
    
    .secondary-sidebar {
        display: none;
        transition: all 0.3s ease;
        left: 68px; /* 调整位置以配合一级导航 */
    }
    
    .secondary-sidebar.mobile-open {
        display: block;
        transform: translateX(0);
        animation: slideInLeft 0.3s ease 0.1s both;
    }

    .main-content-area {
        margin-left: 8px;
        margin-right: 8px;
        width: calc(100vw - 16px);
        max-width: calc(100vw - 16px);
        padding: 15px 20px;
        box-sizing: border-box;
        transition: margin-left 0.3s ease;
    }
    
    /* 响应式搜索栏 */
    .search-container-flex {
        width: 300px;
        min-width: 200px;
    }
    
    .page-title {
        font-size: 18px;
    }
    
    .upload-agent-btn {
        padding: 6px 16px;
        font-size: 13px;
    }
    
    /* 卡片每行2个 */
    .app-grid {
        grid-template-columns: repeat(2, 1fr);
    }
    
    .app-card {
        max-width: none;
        width: 100%;
    }
}

/* 大平板/小桌面 (1024px+): 折叠导航，卡片每行2个 */
@media (min-width: 1024px) and (max-width: 1199px) {
    .mobile-nav-toggle {
        display: flex;
    }
    
    .icon-sidebar {
        display: none;
        transition: all 0.3s ease;
    }
    
    .icon-sidebar.mobile-open {
        display: flex;
        transform: translateX(0);
        animation: slideInLeft 0.3s ease;
    }
    
    .secondary-sidebar {
        display: none;
        transition: all 0.3s ease;
        left: 68px;
    }
    
    .secondary-sidebar.mobile-open {
        display: block;
        transform: translateX(0);
        animation: slideInLeft 0.3s ease 0.1s both;
    }

    .main-content-area {
        margin-left: 8px;
        margin-right: 8px;
        width: calc(100vw - 16px);
        max-width: calc(100vw - 16px);
        padding: 20px;
        box-sizing: border-box;
        transition: margin-left 0.3s ease;
    }
    
    /* 响应式搜索栏 */
    .search-container-flex {
        width: 400px;
        min-width: 250px;
    }
    
    /* 卡片每行2个 */
    .app-grid {
        grid-template-columns: repeat(2, 1fr);
    }
    
    .app-card {
        max-width: none;
        width: 100%;
    }
}

/* 标准桌面 (1200px+): 展开导航，卡片每行3个 */
@media (min-width: 1200px) and (max-width: 1439px) {
    .mobile-nav-toggle {
        display: none;
    }
    
    .icon-sidebar {
        transform: translateX(0);
    }
    
    .secondary-sidebar {
        transform: translateX(0);
    }

    .main-content-area {
        margin-left: max(453px, calc(453px + (100vw - 453px - 1200px) / 2)); /* 确保不小于导航宽度，同时尽量居中 */
        margin-right: auto;
        width: 1200px; /* 固定最佳宽度 */
        max-width: calc(100vw - 453px - 40px); /* 小屏时确保不溢出 */
        min-width: 500px; /* 最小宽度保证 */
        padding: 20px;
        box-sizing: border-box;
    }
    
    /* 卡片每行3个 */
    .app-grid {
        grid-template-columns: repeat(3, 1fr);
    }
    
    .app-card {
        max-width: none;
        width: 100%;
    }
}

/* 大屏桌面 (1440px+): 展开导航，卡片每行3个 */
@media (min-width: 1440px) and (max-width: 1919px) {
    .mobile-nav-toggle {
        display: none;
    }
    
    .icon-sidebar {
        transform: translateX(0);
    }
    
    .secondary-sidebar {
        transform: translateX(0);
    }

    .main-content-area {
        margin-left: max(453px, calc(453px + (100vw - 453px - 1400px) / 2)); /* 确保不小于导航宽度，同时尽量居中 */
        margin-right: auto;
        width: 1400px; /* 固定最佳宽度 */
        max-width: calc(100vw - 453px - 40px); /* 小屏时确保不溢出 */
        min-width: 600px; /* 最小宽度保证 */
        padding: 20px;
        box-sizing: border-box;
    }
    
    /* 卡片每行3个 */
    .app-grid {
        grid-template-columns: repeat(3, 1fr);
    }
    
    .app-card {
        max-width: none;
        width: 100%;
    }
}

/* 超大屏 (1920px+): 展开导航，卡片每行4个 */
@media (min-width: 1920px) {
    .mobile-nav-toggle {
        display: none;
    }
    
    .icon-sidebar {
        transform: translateX(0);
    }
    
    .secondary-sidebar {
        transform: translateX(0);
    }

    .main-content-area {
        margin-left: max(453px, calc(453px + (100vw - 453px - 1600px) / 2)); /* 确保不小于导航宽度，同时尽量居中 */
        margin-right: auto;
        width: 1600px; /* 固定最佳宽度 */
        max-width: calc(100vw - 453px - 40px); /* 小屏时确保不溢出 */
        min-width: 800px; /* 最小宽度保证 */
        padding: 20px;
        box-sizing: border-box;
    }
    
    /* 卡片每行4个 */
    .app-grid {
        grid-template-columns: repeat(4, 1fr);
    }
    
    .app-card {
        max-width: none;
        width: 100%;
    }
}

/* 小屏设备 (最大768px): 移动端布局 */
@media (max-width: 767px) {
    .mobile-nav-toggle {
        display: flex;
    }
    
    .icon-sidebar {
        width: 60px;
        display: none;
        transition: all 0.3s ease;
    }
    
    .icon-sidebar.mobile-open {
        display: flex;
        transform: translateX(0);
        animation: slideInLeft 0.3s ease;
    }
    
    .secondary-sidebar {
        display: none;
        transition: all 0.3s ease;
        left: 68px; /* 调整位置以配合一级导航 */
    }
    
    .secondary-sidebar.mobile-open {
        display: block;
        transform: translateX(0);
        animation: slideInLeft 0.3s ease 0.1s both;
    }

    .main-content-area {
        margin-left: 8px;
        margin-right: 8px;
        width: calc(100vw - 16px);
        max-width: calc(100vw - 16px);
        padding: 15px 20px;
        box-sizing: border-box;
        margin-top: 70px; /* 为移动端按钮留出空间 */
        transition: margin-left 0.3s ease;
    }
    
    /* 移动端当导航展开时，不调整主内容区域，因为导航是覆盖式的 */
    
    /* 移动端搜索栏 */
    .search-layout {
        flex-direction: column;
        gap: 12px;
        height: auto;
        align-items: stretch;
    }
    
    .page-title {
        font-size: 18px;
        text-align: center;
        order: 1;
    }
    
    .search-container-flex {
        width: 100%;
        order: 2;
    }
    
    .upload-btn-container {
        order: 3;
        text-align: center;
    }
    
    .upload-agent-btn {
        width: 100%;
        padding: 10px;
    }
    
    /* 移动端卡片单列布局 */
    .app-grid {
        grid-template-columns: 1fr;
        gap: 16px;
    }
    
    .app-card {
        height: auto;
        max-width: none;
        width: 100%;
    }
    
    .banner-content {
        flex-direction: column;
        text-align: center;
        padding: 20px;
    }
    
    .banner-image {
        margin-left: 0;
        margin-top: 20px;
    }
    
    .product-seeker-card {
        width: 100%;
        max-width: 300px;
    }
    
    .app-card {
        margin-bottom: 20px;
    }
    
    .col-lg-3 {
        flex: 0 0 100%;
        max-width: 100%;
    }
    
    .icon-nav-item {
        width: 44px;
        height: 44px;
        padding: 2px; /* 减少内边距以优化空间利用 */
    }
    
    .icon-text {
        font-size: 9px;
        max-width: 40px; /* 调整文字宽度以适合44px容器 */
        line-height: 1.1; /* 优化行高 */
    }
}

/* 状态指示器 */
.status-online {
    color: #28a745;
}

.status-free {
    color: #17a2b8;
}

.status-beta {
    color: #ffc107;
}

/* 滚动条样式 */
.sidebar::-webkit-scrollbar {
    width: 6px;
}

.sidebar::-webkit-scrollbar-track {
    background: #f1f1f1;
}

.sidebar::-webkit-scrollbar-thumb {
    background: #c1c1c1;
    border-radius: 3px;
}

.sidebar::-webkit-scrollbar-thumb:hover {
    background: #a8a8a8;
}

/* 动画效果 */
@keyframes fadeInUp {
    from {
        opacity: 0;
        transform: translateY(20px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

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

.app-card {
    animation: fadeInUp 0.5s ease-out;
}

/* 加载状态 */
.loading {
    display: flex;
    justify-content: center;
    align-items: center;
    padding: 40px;
}

.loading-text {
    text-align: center;
    padding: 40px 20px;
    color: #6b7280;
    font-size: 16px;
}

/* 学习课程卡片样式 - 382*300尺寸 */
.course-card {
    width: 100%;
    max-width: 382px;
    height: 300px;
    background: white;
    border-radius: 12px;
    overflow: hidden;
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.1);
    transition: all 0.3s ease;
    cursor: pointer;
    margin-bottom: 20px;
    display: flex;
    flex-direction: column;
    justify-self: center;
}

.course-card:hover {
    transform: translateY(-4px);
    box-shadow: 0 8px 24px rgba(0, 0, 0, 0.15);
}

.course-card-image {
    width: 100%;
    height: 180px;
    position: relative;
    overflow: hidden;
    border-radius: 8px 8px 0 0;
}

.course-title-overlay {
    position: absolute;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%);
    color: white;
    font-size: 18px;
    font-weight: 600;
    text-align: center;
    text-shadow: 0 2px 4px rgba(0, 0, 0, 0.3);
    padding: 0 16px;
    width: calc(100% - 32px);
    line-height: 1.3;
}

.course-duration {
    position: absolute;
    top: 12px;
    right: 12px;
    background: rgba(0, 0, 0, 0.7);
    color: white;
    padding: 4px 8px;
    border-radius: 4px;
    font-size: 12px;
    font-weight: 500;
}

.course-card-content {
    padding: 16px;
    flex: 1;
    display: flex;
    flex-direction: column;
    justify-content: space-between;
}

.course-title {
    font-size: 18px;
    font-weight: 600;
    color: #1f2937;
    margin-bottom: 8px;
    line-height: 1.4;
    overflow: hidden;
    text-overflow: ellipsis;
    display: -webkit-box;
    -webkit-line-clamp: 2;
    -webkit-box-orient: vertical;
}

.course-description {
    font-size: 14px;
    color: #6b7280;
    line-height: 1.5;
    margin-bottom: 12px;
    overflow: hidden;
    text-overflow: ellipsis;
    display: -webkit-box;
    -webkit-line-clamp: 2;
    -webkit-box-orient: vertical;
}

.course-stats {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 12px;
    font-size: 12px;
}

.course-rating {
    color: #f59e0b;
    font-weight: 500;
}

.course-rating i {
    margin-right: 2px;
}

.course-students {
    color: #6b7280;
}

.course-meta {
    display: flex;
    justify-content: space-between;
    align-items: center;
    gap: 8px;
    flex-wrap: wrap;
}

.course-chapters {
    font-size: 12px;
    color: #6b7280;
    display: flex;
    align-items: center;
    gap: 4px;
}

.course-stats {
    display: flex;
    gap: 12px;
    align-items: center;
    font-size: 12px;
}

.course-views,
.course-likes {
    color: #6b7280;
    display: flex;
    align-items: center;
    gap: 4px;
}

.course-featured {
    position: absolute;
    top: 12px;
    left: 12px;
    background: linear-gradient(135deg, #f59e0b, #f97316);
    color: white;
    padding: 4px 8px;
    border-radius: 12px;
    font-size: 10px;
    font-weight: 600;
    display: flex;
    align-items: center;
    gap: 4px;
}

.course-membership {
    display: inline-flex;
    align-items: center;
    gap: 6px;
    padding: 6px 12px;
    border-radius: 20px;
    font-size: 12px;
    font-weight: 600;
    text-align: center;
    box-shadow: 0 2px 4px rgba(0, 0, 0, 0.1);
}

.course-membership i {
    font-size: 12px;
}

/* 免费会员样式 */
.membership-free {
    background: linear-gradient(135deg, #10b981, #16a085);
    color: white;
    border: 2px solid #0d9668;
}

/* 体验会员样式 */
.membership-experience {
    background: linear-gradient(135deg, #3b82f6, #2563eb);
    color: white;
    border: 2px solid #1d4ed8;
}

/* 高级会员样式 */
.membership-premium {
    background: linear-gradient(135deg, #f59e0b, #f97316);
    color: white;
    border: 2px solid #d97706;
}

/* 分销商样式 */
.membership-distributor {
    background: linear-gradient(135deg, #8b5cf6, #7c3aed);
    color: white;
    border: 2px solid #6d28d9;
}

/* 默认样式 */
.membership-default {
    background: linear-gradient(135deg, #6b7280, #4b5563);
    color: white;
    border: 2px solid #374151;
}

/* 会员样式 - 橙色（保持向后兼容） */
.membership-member {
    background: linear-gradient(135deg, #f59e0b, #f97316);
    color: white;
    border: 2px solid #d97706;
}

/* 课程网格布局 */
.courses-grid {
    display: grid;
    grid-template-columns: repeat(4, 1fr);
    gap: 20px;
    padding: 20px 0;
}

/* 响应式调整 */
@media (max-width: 1600px) {
    .courses-grid {
        grid-template-columns: repeat(3, 1fr);
    }
}

@media (max-width: 1200px) {
    .courses-grid {
        grid-template-columns: repeat(2, 1fr);
    }
    
    .course-card {
        width: 100%;
        max-width: 382px;
        justify-self: center;
    }
}

@media (max-width: 768px) {
    .courses-grid {
        grid-template-columns: 1fr;
    }
    
    .course-card {
        width: 100%;
        height: 280px;
        justify-self: center;
    }
    
    .course-card-image {
        height: 160px;
    }
}

/* 导航链接样式 */
.icon-nav-item .nav-link {
    display: flex;
    flex-direction: column;
    align-items: center;
    text-decoration: none;
    color: inherit;
    width: 100%;
    height: 100%;
    padding: 12px 8px;
}

.icon-nav-item .nav-link:hover {
    color: inherit;
}

/* 公开项目卡片样式 */
.projects-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(300px, 1fr));
    gap: 20px;
    padding: 20px 0;
}

.project-card {
    background: white;
    border-radius: 12px;
    border: 1px solid #e5e7eb;
    overflow: hidden;
    transition: all 0.3s ease;
    cursor: pointer;
    height: fit-content;
}

.project-card:hover {
    transform: translateY(-2px);
    box-shadow: 0 8px 24px rgba(0, 0, 0, 0.1);
    border-color: #d1d5db;
}

.project-card-header {
    padding: 16px;
    color: white;
    position: relative;
    display: flex;
    align-items: center;
    gap: 12px;
}

.project-icon {
    font-size: 24px;
    width: 40px;
    height: 40px;
    display: flex;
    align-items: center;
    justify-content: center;
    background: rgba(255, 255, 255, 0.2);
    border-radius: 8px;
    flex-shrink: 0;
}

.project-icon-img {
    width: 36px;
    height: 36px;
    object-fit: cover;
    border-radius: 6px;
}

.project-icon-emoji {
    font-size: 28px;
}

.project-icon-fallback {
    font-size: 28px;
}

.project-title {
    font-size: 18px;
    font-weight: 600;
    flex: 1;
}

.project-badge {
    position: absolute;
    top: 12px;
    right: 12px;
    background: rgba(255, 255, 255, 0.9);
    color: #f59e0b;
    padding: 2px 8px;
    border-radius: 12px;
    font-size: 12px;
    font-weight: 500;
}

.project-card-body {
    padding: 16px;
}

.project-description {
    color: #6b7280;
    font-size: 14px;
    line-height: 1.5;
    margin-bottom: 16px;
}

.project-apis {
    display: flex;
    flex-direction: column;
    gap: 8px;
}

.api-item {
    background: #f9fafb;
    border: 1px solid #e5e7eb;
    border-radius: 6px;
    padding: 8px 12px;
    font-size: 13px;
    color: #374151;
    position: relative;
    cursor: pointer;
    transition: all 0.2s ease;
}

.api-item:hover {
    background: #f3f4f6;
    border-color: #d1d5db;
}

.api-item::before {
    content: '→';
    color: #9ca3af;
    margin-right: 8px;
    font-size: 12px;
}

.project-card-footer {
    padding: 12px 16px;
    border-top: 1px solid #f3f4f6;
    display: flex;
    justify-content: space-between;
    align-items: center;
    background: #fafbfc;
}

.project-date {
    font-size: 12px;
    color: #9ca3af;
}

.project-view-btn {
    font-size: 12px;
    padding: 4px 12px;
    border-radius: 6px;
}

/* 项目详情模态框样式 */
.project-detail-description {
    font-size: 16px;
    line-height: 1.6;
    color: #374151;
    margin-bottom: 16px;
}

.project-meta {
    margin-bottom: 20px;
}

.project-stats .stat-item {
    text-align: center;
}

.api-list h6 {
    color: #374151;
    font-weight: 600;
    margin-bottom: 16px;
    padding-bottom: 8px;
    border-bottom: 2px solid #e5e7eb;
}

.api-detail-item {
    background: #f8f9fa;
    padding: 10px 12px;
    border-radius: 6px;
    font-size: 14px;
    color: #495057;
    border-left: 3px solid #4f46e5;
}

/* 响应式调整 */
@media (max-width: 992px) {
    .projects-grid {
        grid-template-columns: repeat(auto-fill, minmax(280px, 1fr));
        gap: 16px;
    }
}

@media (max-width: 768px) {
    .projects-grid {
        grid-template-columns: 1fr;
        gap: 16px;
    }
    
    .project-card-header {
        padding: 12px;
    }
    
    .project-card-body {
        padding: 12px;
    }
    
    .api-item {
        font-size: 12px;
        padding: 6px 10px;
    }
}

/* 个人资料页面样式 */
.profile-container {
    padding: 20px;
}

.profile-card {
    background: white;
    border-radius: 12px;
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.1);
    overflow: hidden;
}

.profile-header {
    background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
    color: white;
    padding: 40px 30px;
    display: flex;
    align-items: center;
    gap: 24px;
}

.profile-avatar {
    position: relative;
}

.avatar-image {
    width: 100px;
    height: 100px;
    border-radius: 50%;
    border: 4px solid rgba(255, 255, 255, 0.3);
    background: white;
}

.avatar-edit-btn {
    position: absolute;
    bottom: 0;
    right: 0;
    width: 32px;
    height: 32px;
    border-radius: 50%;
    background: #4f46e5;
    border: 2px solid white;
    color: white;
    display: flex;
    align-items: center;
    justify-content: center;
    cursor: pointer;
    transition: all 0.3s ease;
}

.avatar-edit-btn:hover {
    background: #3730a3;
    transform: scale(1.1);
}

.profile-info {
    flex: 1;
}

.profile-name {
    font-size: 32px;
    font-weight: 700;
    margin: 0 0 12px 0;
}

.profile-status {
    display: flex;
    align-items: center;
    gap: 16px;
    flex-wrap: wrap;
}

.status-badge {
    background: rgba(255, 255, 255, 0.2);
    padding: 6px 12px;
    border-radius: 20px;
    font-size: 14px;
    font-weight: 500;
    display: flex;
    align-items: center;
    gap: 6px;
}

.status-badge.premium {
    background: rgba(255, 193, 7, 0.2);
    color: #ffc107;
}

.profile-uid {
    background: rgba(255, 255, 255, 0.15);
    padding: 4px 12px;
    border-radius: 12px;
    font-size: 14px;
    font-family: monospace;
}

.profile-section {
    padding: 30px;
    border-bottom: 1px solid #f0f0f0;
}

.profile-section:last-child {
    border-bottom: none;
}

.section-title {
    font-size: 18px;
    font-weight: 600;
    color: #333;
    margin-bottom: 20px;
    display: flex;
    align-items: center;
}

.info-grid {
    display: grid;
    gap: 20px;
}

.info-item {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 16px;
    background: #f8f9fa;
    border-radius: 8px;
}

.info-label {
    font-weight: 500;
    color: #666;
    min-width: 100px;
}

.info-value {
    display: flex;
    align-items: center;
    gap: 8px;
    flex: 1;
    justify-content: flex-end;
}

.info-value span {
    font-weight: 500;
    color: #333;
}

.copy-btn, .edit-btn {
    background: none;
    border: none;
    color: #4f46e5;
    cursor: pointer;
    padding: 4px 8px;
    border-radius: 4px;
    transition: all 0.2s ease;
}

.copy-btn:hover, .edit-btn:hover {
    background: #e0e7ff;
    color: #3730a3;
}

.membership-info {
    display: flex;
    flex-direction: column;
    align-items: flex-end;
    gap: 4px;
}

.membership-level {
    font-weight: 600;
    color: #ffc107;
    display: flex;
    align-items: center;
    gap: 4px;
}

.membership-expire {
    font-size: 12px;
    color: #666;
}

.upgrade-btn {
    background: linear-gradient(135deg, #ffc107 0%, #ff8f00 100%);
    color: white;
    border: none;
    padding: 8px 16px;
    border-radius: 6px;
    font-size: 14px;
    font-weight: 500;
    cursor: pointer;
    transition: all 0.3s ease;
    display: flex;
    align-items: center;
    gap: 4px;
}

.upgrade-btn:hover {
    transform: translateY(-2px);
    box-shadow: 0 4px 12px rgba(255, 193, 7, 0.4);
}

.action-grid {
    display: grid;
    gap: 16px;
}

.action-item {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 20px;
    background: #f8f9fa;
    border-radius: 8px;
    border: 1px solid #e9ecef;
}

.action-info {
    display: flex;
    align-items: center;
    gap: 16px;
}

.action-info i {
    width: 40px;
    height: 40px;
    background: #e0e7ff;
    color: #4f46e5;
    border-radius: 8px;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 18px;
}

.action-title {
    font-weight: 600;
    color: #333;
    margin-bottom: 4px;
}

.action-desc {
    font-size: 14px;
    color: #666;
}

.profile-actions {
    padding: 30px;
    text-align: center;
}

.logout-btn {
    background: linear-gradient(135deg, #dc3545 0%, #c82333 100%);
    border: none;
    padding: 12px 32px;
    border-radius: 8px;
    font-weight: 600;
    transition: all 0.3s ease;
}

.logout-btn:hover {
    transform: translateY(-2px);
    box-shadow: 0 4px 12px rgba(220, 53, 69, 0.4);
    background: linear-gradient(135deg, #c82333 0%, #a71e2a 100%);
}

/* 个人资料页面响应式 */
@media (max-width: 768px) {
    .profile-header {
        flex-direction: column;
        text-align: center;
        gap: 16px;
    }
    
    .profile-name {
        font-size: 24px;
    }
    
    .profile-status {
        justify-content: center;
    }
    
    .info-item {
        flex-direction: column;
        align-items: stretch;
        gap: 8px;
    }
    
    .info-value {
        justify-content: space-between;
    }
    
    .action-item {
        flex-direction: column;
        align-items: stretch;
        gap: 16px;
    }
}

/* 项目卡片背景颜色样式 */
.app-card.bg-blue {
    background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
    color: white;
}

.app-card.bg-green {
    background: linear-gradient(135deg, #56ab2f 0%, #a8e6cf 100%);
    color: white;
}

.app-card.bg-purple {
    background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
    color: white;
}

.app-card.bg-orange {
    background: linear-gradient(135deg, #f093fb 0%, #f5576c 100%);
    color: white;
}

.app-card.bg-pink {
    background: linear-gradient(135deg, #f093fb 0%, #f5576c 100%);
    color: white;
}

.app-card.bg-indigo {
    background: linear-gradient(135deg, #4facfe 0%, #00f2fe 100%);
    color: white;
}

.app-card.bg-yellow {
    background: linear-gradient(135deg, #ffecd2 0%, #fcb69f 100%);
    color: #333;
}

.app-card.bg-red {
    background: linear-gradient(135deg, #ff9a9e 0%, #fecfef 100%);
    color: white;
}

/* API功能列表样式 */
.api-features {
    padding: 12px 0;
    border-top: 1px solid rgba(255, 255, 255, 0.2);
    border-bottom: 1px solid rgba(255, 255, 255, 0.2);
    margin: 12px 0;
}

.api-feature {
    font-size: 13px;
    line-height: 1.4;
    margin-bottom: 4px;
    opacity: 0.9;
}

.api-feature:last-child {
    margin-bottom: 0;
}

/* 调整按钮样式以适应彩色背景 */
.app-card.bg-blue .btn-primary,
.app-card.bg-green .btn-primary,
.app-card.bg-purple .btn-primary,
.app-card.bg-orange .btn-primary,
.app-card.bg-pink .btn-primary,
.app-card.bg-indigo .btn-primary,
.app-card.bg-red .btn-primary {
    background: rgba(255, 255, 255, 0.2);
    border: 1px solid rgba(255, 255, 255, 0.3);
    color: white;
}

.app-card.bg-blue .btn-primary:hover,
.app-card.bg-green .btn-primary:hover,
.app-card.bg-purple .btn-primary:hover,
.app-card.bg-orange .btn-primary:hover,
.app-card.bg-pink .btn-primary:hover,
.app-card.bg-indigo .btn-primary:hover,
.app-card.bg-red .btn-primary:hover {
    background: rgba(255, 255, 255, 0.3);
    border-color: rgba(255, 255, 255, 0.4);
}

.app-card.bg-yellow .btn-primary {
    background: rgba(0, 0, 0, 0.1);
    border: 1px solid rgba(0, 0, 0, 0.2);
    color: #333;
}

.app-card.bg-yellow .btn-primary:hover {
    background: rgba(0, 0, 0, 0.2);
    border-color: rgba(0, 0, 0, 0.3);
}

.app-card.bg-blue .btn-outline-secondary,
.app-card.bg-green .btn-outline-secondary,
.app-card.bg-purple .btn-outline-secondary,
.app-card.bg-orange .btn-outline-secondary,
.app-card.bg-pink .btn-outline-secondary,
.app-card.bg-indigo .btn-outline-secondary,
.app-card.bg-red .btn-outline-secondary,
.app-card.bg-blue .btn-outline-primary,
.app-card.bg-green .btn-outline-primary,
.app-card.bg-purple .btn-outline-primary,
.app-card.bg-orange .btn-outline-primary,
.app-card.bg-pink .btn-outline-primary,
.app-card.bg-indigo .btn-outline-primary,
.app-card.bg-red .btn-outline-primary {
    border: 1px solid rgba(255, 255, 255, 0.3);
    color: white;
    background: transparent;
}

.app-card.bg-blue .btn-outline-secondary:hover,
.app-card.bg-green .btn-outline-secondary:hover,
.app-card.bg-purple .btn-outline-secondary:hover,
.app-card.bg-orange .btn-outline-secondary:hover,
.app-card.bg-pink .btn-outline-secondary:hover,
.app-card.bg-indigo .btn-outline-secondary:hover,
.app-card.bg-red .btn-outline-secondary:hover,
.app-card.bg-blue .btn-outline-primary:hover,
.app-card.bg-green .btn-outline-primary:hover,
.app-card.bg-purple .btn-outline-primary:hover,
.app-card.bg-orange .btn-outline-primary:hover,
.app-card.bg-pink .btn-outline-primary:hover,
.app-card.bg-indigo .btn-outline-primary:hover,
.app-card.bg-red .btn-outline-primary:hover {
    background: rgba(255, 255, 255, 0.1);
    border-color: rgba(255, 255, 255, 0.4);
    color: white;
}

.app-card.bg-yellow .btn-outline-secondary,
.app-card.bg-yellow .btn-outline-primary {
    border: 1px solid rgba(0, 0, 0, 0.2);
    color: #333;
    background: transparent;
}

.app-card.bg-yellow .btn-outline-secondary:hover,
.app-card.bg-yellow .btn-outline-primary:hover {
    background: rgba(0, 0, 0, 0.1);
    border-color: rgba(0, 0, 0, 0.3);
    color: #333;
}

/* 迁移浮窗样式 */
#migrationModal .modal-dialog {
    max-width: 800px;
}

#migrationModal .nav-tabs {
    border-bottom: 2px solid #dee2e6;
    margin-bottom: 0;
}

#migrationModal .nav-tabs .nav-link {
    border: none;
    border-bottom: 2px solid transparent;
    color: #6c757d;
    padding: 12px 16px;
    font-weight: 500;
    transition: all 0.2s ease;
}

#migrationModal .nav-tabs .nav-link:hover {
    border-bottom-color: #4f46e5;
    color: #4f46e5;
    background-color: transparent;
}

#migrationModal .nav-tabs .nav-link.active {
    border-bottom-color: #4f46e5;
    color: #4f46e5;
    background-color: transparent;
    font-weight: 600;
}

#migrationModal .tab-content {
    background-color: #f8f9fa;
    border-radius: 0 0 6px 6px;
    padding: 20px;
    min-height: 400px;
}

#migrationModal .tab-pane {
    animation: fadeInUp 0.3s ease-in-out;
}

#migrationModal pre {
    background-color: transparent;
    border: none;
    padding: 0;
    margin: 0;
    font-family: 'Monaco', 'Menlo', 'Ubuntu Mono', 'Consolas', 'Courier New', monospace;
    font-size: 12px;
    line-height: 1.4;
    white-space: pre-wrap;
    word-wrap: break-word;
}

#migrationModal .bg-dark pre {
    color: #e9ecef;
}

#migrationModal .loading-placeholder {
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 40px;
    color: #6c757d;
}

#migrationModal .source-code-preview {
    max-height: 300px;
    overflow-y: auto;
}

#migrationModal .source-code-preview::-webkit-scrollbar {
    width: 6px;
}

#migrationModal .source-code-preview::-webkit-scrollbar-track {
    background: rgba(255, 255, 255, 0.1);
    border-radius: 3px;
}

#migrationModal .source-code-preview::-webkit-scrollbar-thumb {
    background: rgba(255, 255, 255, 0.3);
    border-radius: 3px;
}

#migrationModal .source-code-preview::-webkit-scrollbar-thumb:hover {
    background: rgba(255, 255, 255, 0.5);
}

/* 复制按钮动画 */
#migrationModal .btn-outline-primary {
    transition: all 0.2s ease;
}

#migrationModal .btn-success {
    background-color: #198754;
    border-color: #198754;
}

/* JSON代码高亮 */
#migrationModal .language-json {
    color: #e9ecef;
}

/* 前置条件内容样式 */
#prerequisites-content pre {
    background-color: #f8f9fa;
    padding: 16px;
    border-radius: 6px;
    border-left: 4px solid #4f46e5;
    font-size: 13px;
    line-height: 1.5;
}

/* 节点配置内容样式 */
#start-node-content pre,
#end-node-content pre {
    background-color: #1e1e1e;
    color: #d4d4d4;
    padding: 16px;
    border-radius: 6px;
    font-size: 12px;
    line-height: 1.4;
    max-height: 350px;
    overflow-y: auto;
}

#start-node-content pre::-webkit-scrollbar,
#end-node-content pre::-webkit-scrollbar {
    width: 6px;
}

#start-node-content pre::-webkit-scrollbar-track,
#end-node-content pre::-webkit-scrollbar-track {
    background: rgba(255, 255, 255, 0.1);
    border-radius: 3px;
}

#start-node-content pre::-webkit-scrollbar-thumb,
#end-node-content pre::-webkit-scrollbar-thumb {
    background: rgba(255, 255, 255, 0.3);
    border-radius: 3px;
}

/* 迁移图标样式 */
.migration-icon {
    flex-shrink: 0;
}

/* 标签标题样式 */
.tab-pane h6 {
    color: #495057;
    font-weight: 600;
}

/* 响应式调整 */
@media (max-width: 768px) {
    #migrationModal .modal-dialog {
        max-width: 95%;
        margin: 10px auto;
    }
    
    #migrationModal .nav-tabs .nav-link {
        padding: 8px 12px;
        font-size: 14px;
    }
    
    #migrationModal .tab-content {
        padding: 15px;
        min-height: 300px;
    }
    
    #migrationModal pre {
        font-size: 11px;
    }
}

/* 课程详情页面样式 */
.article-content {
    padding: 20px;
}

.course-title {
    font-size: 28px;
    font-weight: bold;
    color: #1f2937;
    margin-bottom: 16px;
}

.course-description {
    font-size: 16px;
    color: #6b7280;
    margin-bottom: 20px;
    line-height: 1.6;
}

.course-meta {
    display: flex;
    flex-wrap: wrap;
    gap: 16px;
    margin-bottom: 24px;
    padding: 16px;
    background: #f8f9fa;
    border-radius: 8px;
}

.course-info-item {
    display: flex;
    align-items: center;
    gap: 8px;
    font-size: 14px;
    color: #4b5563;
}

.course-info-item i {
    color: #4f46e5;
}

.chapters-list {
    margin-bottom: 24px;
}

.chapter-item {
    background: white;
    border: 1px solid #e5e7eb;
    border-radius: 8px;
    margin-bottom: 8px;
    cursor: pointer;
    transition: all 0.2s ease;
}

.chapter-item:hover {
    border-color: #4f46e5;
    box-shadow: 0 2px 8px rgba(79, 70, 229, 0.1);
}

.chapter-item.active {
    border-color: #4f46e5;
    background: #f0f9ff;
}

.chapter-header {
    display: flex;
    align-items: center;
    padding: 16px;
    gap: 16px;
}

.chapter-number {
    width: 32px;
    height: 32px;
    background: #4f46e5;
    color: white;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    font-weight: bold;
    font-size: 14px;
}

.chapter-info {
    flex: 1;
}

.chapter-title {
    font-size: 16px;
    font-weight: 600;
    color: #1f2937;
    margin-bottom: 4px;
}

.chapter-description {
    font-size: 14px;
    color: #6b7280;
    margin: 0;
}

.chapter-status {
    color: #4f46e5;
    font-size: 16px;
}

.chapter-content {
    background: white;
    border-radius: 8px;
    padding: 24px;
    margin-bottom: 24px;
    box-shadow: 0 1px 3px rgba(0, 0, 0, 0.1);
}

.password-protection {
    text-align: center;
    padding: 40px 20px;
}

.password-form h3 {
    color: #4f46e5;
    margin-bottom: 16px;
}

.password-input-group {
    display: flex;
    gap: 8px;
    max-width: 400px;
    margin: 0 auto;
}

.chapter-detail {
    max-width: none;
}

.chapter-body {
    margin: 24px 0;
    line-height: 1.6;
}

.chapter-document {
    margin-top: 24px;
    padding: 20px;
    background: #f8f9fa;
    border-radius: 8px;
}

.document-link {
    margin-top: 12px;
}

.document-password {
    margin-top: 8px;
}

.loading-text {
    padding: 60px 20px;
    text-align: center;
    color: #6b7280;
}

.error-message {
    padding: 60px 20px;
}

.error-message i {
    font-size: 48px;
    margin-bottom: 16px;
}

.error-message h3 {
    margin-bottom: 16px;
}

#like-btn {
    background: linear-gradient(135deg, #ef4444, #dc2626);
    color: white;
    border: none;
    padding: 8px 16px;
    border-radius: 20px;
    font-size: 14px;
    transition: all 0.3s ease;
}

#like-btn:hover {
    transform: translateY(-1px);
    box-shadow: 0 4px 12px rgba(239, 68, 68, 0.3);
}

#like-btn.liked {
    background: linear-gradient(135deg, #10b981, #059669);
}

/* 提现管理样式 */
.withdrawal-notice {
    margin-bottom: 25px;
}

.withdrawal-form {
    margin-bottom: 30px;
}

.required {
    color: #dc3545;
    font-weight: bold;
}

.field-hint {
    font-size: 12px;
    color: #6c757d;
    margin-top: 5px;
    line-height: 1.4;
}

.form-actions {
    margin-top: 25px;
    padding-top: 20px;
    border-top: 1px solid #e9ecef;
}

.form-actions .btn {
    min-width: 150px;
}

#withdrawalInfoDisplay .info-value {
    display: flex;
    align-items: center;
    gap: 10px;
}

#withdrawalInfoDisplay .badge {
    font-size: 11px;
}

/* 表单验证样式 */
.form-control.is-invalid {
    border-color: #dc3545;
    background-image: url("data:image/svg+xml,%3csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 12 12' width='12' height='12' fill='none' stroke='%23dc3545'%3e%3ccircle cx='6' cy='6' r='4.5'/%3e%3cpath d='m5.8 3.6h.4L6 6.5z'/%3e%3ccircle cx='6' cy='8.2' r='.6' fill='%23dc3545' stroke='none'/%3e%3c/svg%3e");
    background-repeat: no-repeat;
    background-position: right calc(0.375em + 0.1875rem) center;
    background-size: calc(0.75em + 0.375rem) calc(0.75em + 0.375rem);
}

.form-control.is-valid {
    border-color: #198754;
    background-image: url("data:image/svg+xml,%3csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 8 8'%3e%3cpath fill='%23198754' d='m2.3 6.73.8-.77-.8-.77c-.1-.1-.1-.25 0-.35s.25-.1.35 0l.8.77c.05.05.15.05.2 0l.8-.77c.1-.1.25-.1.35 0s.1.25 0 .35l-.8.77.8.77c.1.1.1.25 0 .35s-.25.1-.35 0l-.8-.77c-.05-.05-.15-.05-.2 0l-.8.77c-.1.1-.25.1-.35 0s-.1-.25 0-.35z'/%3e%3c/svg%3e");
    background-repeat: no-repeat;
    background-position: right calc(0.375em + 0.1875rem) center;
    background-size: calc(0.75em + 0.375rem) calc(0.75em + 0.375rem);
}

.invalid-feedback {
    display: block;
    width: 100%;
    margin-top: 0.25rem;
    font-size: 0.875rem;
    color: #dc3545;
}

.valid-feedback {
    display: block;
    width: 100%;
    margin-top: 0.25rem;
    font-size: 0.875rem;
    color: #198754;
}

/* 分销订单样式 */
.orders-summary {
    margin-bottom: 30px;
}

.summary-cards {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(200px, 1fr));
    gap: 20px;
    margin-bottom: 20px;
}

.summary-card {
    background: white;
    border: 1px solid #e9ecef;
    border-radius: 8px;
    padding: 20px;
    display: flex;
    align-items: center;
    gap: 15px;
    transition: box-shadow 0.2s ease;
}

.summary-card:hover {
    box-shadow: 0 2px 8px rgba(0,0,0,0.1);
}

.summary-icon {
    width: 50px;
    height: 50px;
    background: #f8f9fa;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    color: #4f46e5;
    font-size: 20px;
}

.summary-info {
    flex: 1;
}

.summary-label {
    font-size: 14px;
    color: #6c757d;
    margin-bottom: 5px;
}

.summary-value {
    font-size: 24px;
    font-weight: bold;
    color: #1f2937;
}

.orders-container {
    background: white;
    border: 1px solid #e9ecef;
    border-radius: 8px;
    overflow: hidden;
}

.orders-header {
    padding: 20px;
    border-bottom: 1px solid #e9ecef;
    display: flex;
    justify-content: space-between;
    align-items: center;
    background: #f8f9fa;
}

.orders-header h4 {
    margin: 0;
    color: #1f2937;
    font-size: 18px;
}

.orders-actions {
    display: flex;
    gap: 10px;
}

.orders-table {
    margin: 0;
}

.orders-table th {
    background: #f8f9fa;
    font-weight: 600;
    color: #374151;
    border-bottom: 2px solid #e9ecef;
    padding: 15px 12px;
}

.orders-table td {
    padding: 15px 12px;
    vertical-align: middle;
    border-bottom: 1px solid #f1f5f9;
}

.orders-table tbody tr:hover {
    background-color: #f8f9fa;
}

.order-number {
    font-family: 'Courier New', monospace;
    font-weight: bold;
    color: #4f46e5;
}

.payment-time {
    color: #6b7280;
    font-size: 14px;
}

.buyer-info {
    font-weight: 500;
    color: #1f2937;
}

.membership-badge {
    display: inline-block;
    padding: 4px 8px;
    border-radius: 12px;
    font-size: 12px;
    font-weight: 500;
    text-transform: uppercase;
}

.membership-badge.free {
    background-color: #f3f4f6;
    color: #374151;
}

.membership-badge.experience {
    background-color: #dbeafe;
    color: #1d4ed8;
}

.membership-badge.premium {
    background-color: #fef3c7;
    color: #d97706;
}

.membership-badge.distributor {
    background-color: #ecfdf5;
    color: #059669;
}

.amount {
    font-weight: bold;
    color: #059669;
}

.commission {
    font-weight: bold;
    color: #dc2626;
}

.withdraw-btn {
    background: linear-gradient(135deg, #4f46e5, #7c3aed);
    color: white;
    border: none;
    padding: 6px 12px;
    border-radius: 6px;
    font-size: 12px;
    font-weight: 500;
    cursor: pointer;
    transition: all 0.2s ease;
}

.withdraw-btn:hover {
    transform: translateY(-1px);
    box-shadow: 0 4px 12px rgba(79, 70, 229, 0.3);
}

.withdraw-btn:disabled {
    background: #9ca3af;
    cursor: not-allowed;
    transform: none;
    box-shadow: none;
}

/* 状态显示样式 */
.loading-state, .empty-state, .error-state {
    padding: 60px 20px;
    text-align: center;
}

.loading-spinner {
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 15px;
    color: #6b7280;
}

.loading-spinner i {
    font-size: 32px;
    color: #4f46e5;
}

.empty-state .empty-icon,
.error-state .error-icon {
    color: #9ca3af;
    margin-bottom: 20px;
}

.empty-state h4,
.error-state h4 {
    color: #374151;
    margin-bottom: 10px;
}

.empty-state p,
.error-state p {
    color: #6b7280;
    margin-bottom: 20px;
}

/* 响应式设计 */
@media (max-width: 768px) {
    .summary-cards {
        grid-template-columns: 1fr;
    }
    
    .orders-header {
        flex-direction: column;
        gap: 15px;
        text-align: center;
    }
    
    .orders-table {
        font-size: 14px;
    }
    
    .orders-table th,
    .orders-table td {
        padding: 10px 8px;
    }
    
    .table-responsive {
        border: none;
    }
}