/* 电商工具页面样式 */
.tools-page {
    background-color: #f5f5f5;
    min-height: calc(100vh - 140px);
    padding: 20px 0;
}

.tools-content {
    display: flex;
    gap: 20px;
    margin-top: 20px;
}

/* 左侧所有工具展示区域 */
.tools-main {
    flex: 1;
    margin-right: 20px;
}

.all-tools-container {
    background: white;
    border-radius: 8px;
    box-shadow: 0 2px 8px rgba(0, 0, 0, 0.1);
    padding: 20px;
    max-height: 80vh;
    overflow-y: auto;
}

.tool-category {
    margin-bottom: 30px;
}

.tool-category:last-child {
    margin-bottom: 0;
}

.category-header {
    margin-bottom: 15px;
    padding-bottom: 10px;
    border-bottom: 2px solid #f0f0f0;
}

.category-title {
    font-size: 18px;
    font-weight: 600;
    color: #333;
    margin: 0;
    display: flex;
    align-items: center;
    gap: 10px;
}

.category-icon {
    font-size: 20px;
}

.category-icon .icon {
    width: 24px;
    height: 24px;
    font-size: 24px;
}

/* 平台图标 */
.platform-icon {
    display: inline-block;
    width: 24px;
    height: 24px;
    border-radius: 4px;
    text-align: center;
    line-height: 24px;
    color: white;
    font-size: 12px;
    font-weight: bold;
}

.platform-icon.taobao {
    background-color: #ff6900;
}

.platform-icon.jingdong {
    background-color: #e1251b;
}

.platform-icon.douyin {
    background-color: #000;
}

.platform-icon.pinduoduo {
    background-color: #e02e24;
}

.platform-icon.alibaba {
    background-color: #1890ff;
}

.platform-icon.other {
    background-color: #999;
}

/* SVG图标颜色 - 通过父容器类名控制 */
.category-icon.taobao .icon {
    color: #ff6900;
}

.category-icon.jingdong .icon {
    color: #e1251b;
}

.category-icon.douyin .icon {
    color: #000;
}

.category-icon.pinduoduo .icon {
    color: #e02e24;
}

.category-icon.alibaba .icon {
    color: #1890ff;
}

.tools-list {
    display: flex;
    flex-wrap: wrap;
    gap: 4px 8px;
    line-height: 1.8;
    margin: -2px -4px;
}

.tool-item {
    display: inline-block;
    color: #333;
    font-size: 14px;
    cursor: pointer;
    padding: 6px 12px;
    margin: 2px 4px;
    border-radius: 4px;
    transition: all 0.2s ease;
    text-decoration: none;
    border: 1px solid transparent;
    user-select: none;
    -webkit-user-select: none;
    -moz-user-select: none;
    -ms-user-select: none;
}

.tool-item:hover {
    color: #1890ff;
    background-color: #f0f8ff;
    border-color: #d6e4ff;
}

.tool-item.active {
    color: #1890ff;
    background-color: #e6f7ff;
    border-color: #91d5ff;
    font-weight: 500;
}

.vip-mark {
    color: #fa8c16;
    font-size: 10px;
    font-weight: bold;
    margin-left: 4px;
    vertical-align: super;
}

/* 右侧固定生成区域 */
.tools-sidebar {
    width: 400px;
    flex-shrink: 0;
}

.tool-workspace {
    background: white;
    border-radius: 8px;
    box-shadow: 0 2px 8px rgba(0, 0, 0, 0.1);
    height: 80vh;
    position: sticky;
    top: 20px;
    overflow-y: auto;
}

/* 默认提示 */
.default-tip {
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    height: 300px;
    color: #999;
}

.login-tip {
    display: flex;
    align-items: center;
    justify-content: center;
    height: 100%;
    padding: 40px 20px;
}

.tip-content {
    text-align: center;
    max-width: 300px;
}

.tip-content .icon-lock {
    font-size: 48px;
    color: #faad14;
    margin-bottom: 20px;
    display: block;
}

.tip-content .icon-lock::before {
    content: "🔒";
}

.tip-content h3 {
    font-size: 20px;
    color: #333;
    margin-bottom: 10px;
}

.tip-content p {
    color: #666;
    margin-bottom: 20px;
    line-height: 1.5;
}

.tip-icon {
    font-size: 48px;
    margin-bottom: 20px;
    color: #d9d9d9;
}

.default-tip h3 {
    font-size: 18px;
    margin-bottom: 10px;
}

.default-tip p {
    font-size: 14px;
}

/* 工具使用区域 */
.tool-area {
    padding: 30px;
}

.tool-header {
    margin-bottom: 30px;
    text-align: center;
}

.current-tool-name {
    font-size: 24px;
    font-weight: 600;
    color: #333;
    margin-bottom: 10px;
}

.current-tool-desc {
    font-size: 16px;
    color: #666;
    margin: 0;
}

/* 工具表单 */
.tool-form {
    margin-bottom: 30px;
}

.qrcode-form {
    max-width: 600px;
    margin: 0 auto;
}

.input-fields {
    margin-bottom: 20px;
}

.input-fields .form-group {
    margin-bottom: 16px;
}

.form-actions {
    text-align: center;
    gap: 10px;
}

.form-actions .btn {
    margin: 0 5px;
}

/* 结果区域 */
.result-area {
    border-top: 1px solid #f0f0f0;
    padding-top: 30px;
}

.result-header {
    text-align: center;
    margin-bottom: 20px;
}

.result-header h3 {
    font-size: 20px;
    color: #333;
}

.result-content {
    text-align: center;
    padding: 20px;
}

.qrcode-display {
    display: inline-block;
}

.qrcode-img {
    width: 200px;
    height: 200px;
    border: 1px solid #f0f0f0;
    border-radius: 8px;
    box-shadow: 0 2px 8px rgba(0, 0, 0, 0.1);
}

/* 响应式 */
@media (max-width: 1024px) {
    .tools-content {
        flex-direction: column;
    }
    
    .tools-main {
        margin-right: 0;
        margin-bottom: 20px;
    }
    
    .tools-sidebar {
        width: 100%;
        position: static;
    }
    
    .tool-workspace {
        height: auto;
        position: static;
    }
    
    .all-tools-container {
        max-height: 60vh;
    }
    
    .tools-list {
        gap: 6px 12px;
    }
    
    .tool-item {
        font-size: 13px;
        padding: 5px 10px;
        margin: 2px 3px;
    }
    
    .qrcode-img {
        width: 180px;
        height: 180px;
    }
}

@media (max-width: 768px) {
    .tool-area {
        padding: 20px;
    }
    
    .current-tool-name {
        font-size: 20px;
    }
    
    .qrcode-img {
        width: 150px;
        height: 150px;
    }
    
    .form-actions .btn {
        display: block;
        width: 100%;
        margin: 5px 0;
    }
}
