/* 工具详情页面样式 - 简约版 */

/* 详情页面容器 */
.tool-detail-container {
    padding: 25px 0;
    animation: fadeIn 0.5s ease forwards;
}

:root {
    --accent-color-rgb: 59, 130, 246; /* 对应--accent-color的RGB值 */
}

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

/* 工具详情头部 */
.tool-detail-header {
    display: flex;
    align-items: flex-start;
    margin-bottom: 30px;
    padding: 30px;
    border-radius: 16px;
    flex-wrap: wrap;
    background: linear-gradient(to right, rgba(255, 255, 255, 0.9), rgba(249, 250, 251, 0.95));
    box-shadow: 0 8px 30px rgba(0, 0, 0, 0.08);
    backdrop-filter: blur(10px);
    border: 1px solid rgba(229, 231, 235, 0.6);
    position: relative;
    overflow: hidden;
    transition: all 0.4s cubic-bezier(0.4, 0, 0.2, 1);
}

.tool-detail-header::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    height: 4px;
    background: linear-gradient(90deg, var(--accent-color), #6366f1);
    z-index: 1;
}

.tool-detail-icon {
    width: 90px;
    height: 90px;
    margin-right: 25px;
    border-radius: 20px;
    overflow: hidden;
    background: linear-gradient(135deg, rgba(255, 255, 255, 0.15), rgba(255, 255, 255, 0.05));
    display: flex;
    align-items: center;
    justify-content: center;
    box-shadow: 0 10px 25px rgba(0, 0, 0, 0.12), 0 4px 10px rgba(0, 0, 0, 0.08);
    transition: all 0.4s cubic-bezier(0.4, 0, 0.2, 1);
    flex-shrink: 0;
    border: 1px solid rgba(255, 255, 255, 0.2);
    position: relative;
    z-index: 2;
}



.tool-detail-icon img {
    width: 54px;
    height: 54px;
    object-fit: contain;
    transition: all 0.4s cubic-bezier(0.4, 0, 0.2, 1);
    filter: drop-shadow(0 4px 6px rgba(0, 0, 0, 0.1));
}



.tool-detail-info {
    flex: 1;
}

.tool-detail-title-row {
    display: flex;
    align-items: center;
    justify-content: space-between;
    margin-bottom: 12px;
    flex-wrap: wrap;
    gap: 15px;
}

.tool-detail-title {
    font-size: 2rem;
    color: var(--secondary-color);
    font-weight: 800;
    position: relative;
    display: inline-block;
    letter-spacing: -0.5px;
    text-shadow: 0 1px 2px rgba(0, 0, 0, 0.05);
    margin: 0;
}

.tool-detail-title::after {
    content: '';
    position: absolute;
    bottom: -4px;
    left: 0;
    width: 40px;
    height: 3px;
    background: linear-gradient(90deg, var(--accent-color), #6366f1);
    border-radius: 3px;
    transition: width 0.3s ease;
}



.tool-detail-tags {
    margin: 12px 0;
    display: flex;
    flex-wrap: wrap;
    gap: 8px;
    animation: fadeIn 0.5s ease-out;
}

.tool-detail-meta {
    display: flex;
    align-items: center;
    flex-wrap: wrap;
    gap: 15px;
    margin: 15px 0;
    width: 100%;
}

.tool-detail-tag {
    color: #495057;
    font-size: 0.85rem;
    font-weight: 500;
    background: rgba(248, 249, 250, 0.8);
    padding: 6px 14px;
    border-radius: 20px;
    display: inline-block;
    border: 1px solid rgba(0, 0, 0, 0.1);
    transition: all 0.3s ease;
    margin-right: 0;
    margin-bottom: 0;
    backdrop-filter: blur(4px);
    box-shadow: 0 2px 5px rgba(0, 0, 0, 0.03);
}



.tool-detail-url {
    display: inline-flex;
    align-items: center;
    color: white;
    font-size: 0.9rem;
    transition: all 0.3s ease;
    background: linear-gradient(90deg, var(--accent-color), #6366f1);
    padding: 8px 16px;
    border-radius: 30px;
    font-weight: 500;
    box-shadow: 0 4px 10px rgba(59, 130, 246, 0.25);
    white-space: nowrap;
}

.tool-detail-url i {
    margin-right: 8px;
    transition: transform 0.3s ease;
}





/* 工具详情内容 */
.tool-detail-sections {
    display: grid;
    grid-template-columns: 1fr;
    gap: 20px;
    margin-bottom: 30px;
}

.tool-detail-section-card {
    background: linear-gradient(135deg, #ffffff 0%, #fafbfc 100%);
    border-radius: 20px;
    padding: 32px;
    border: 1px solid rgba(59, 130, 246, 0.08);
    margin-bottom: 24px;
    position: relative;
    overflow: hidden;
    transition: all 0.4s cubic-bezier(0.4, 0, 0.2, 1);
    box-shadow: 0 4px 6px rgba(0, 0, 0, 0.05), 0 1px 3px rgba(0, 0, 0, 0.1);
}

.tool-detail-section-card::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    height: 3px;
    background: linear-gradient(90deg, #3b82f6, #8b5cf6, #10b981, #06b6d4);
    background-size: 300% 100%;
    animation: gradientShift 6s ease-in-out infinite;
}

@keyframes gradientShift {
    0%, 100% { background-position: 0% 50%; }
    50% { background-position: 100% 50%; }
}



.tool-detail-section-title {
    font-size: 1.4rem;
    color: #1e293b;
    font-weight: 800;
    margin-bottom: 24px;
    padding-bottom: 12px;
    border-bottom: 2px solid rgba(59, 130, 246, 0.1);
    position: relative;
    display: flex;
    align-items: center;
}

.tool-detail-section-title::before {
    content: '';
    width: 6px;
    height: 6px;
    background: linear-gradient(45deg, #3b82f6, #8b5cf6);
    border-radius: 50%;
    margin-right: 12px;
    animation: pulse 2s ease-in-out infinite;
}

@keyframes pulse {
    0%, 100% { transform: scale(1); opacity: 1; }
    50% { transform: scale(1.2); opacity: 0.8; }
}

.tool-detail-section-title::after {
    content: '';
    position: absolute;
    bottom: -2px;
    left: 0;
    width: 60px;
    height: 2px;
    background: linear-gradient(90deg, #3b82f6, #8b5cf6);
    border-radius: 1px;
    transition: width 0.3s ease;
}



.tool-detail-description {
    font-size: 1rem;
    line-height: 1.7;
    color: var(--primary-color);
    margin-bottom: 15px;
}

.tool-detail-full-description {
    font-size: 0.95rem;
    line-height: 1.8;
    color: var(--primary-color);
    margin-top: 15px;
    margin-bottom: 10px;
    padding-top: 15px;
    border-top: 1px dashed rgba(0, 0, 0, 0.1);
    animation: fadeIn 0.6s ease-out;
}

/* 功能列表 - 活泼设计 */
.tool-functions-list {
    list-style: none;
    padding: 0;
    margin: 0;
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(320px, 1fr));
    gap: 20px;
}

.tool-function-item {
    padding: 24px;
    margin-bottom: 0;
    background: linear-gradient(135deg, #ffffff 0%, #f8fafc 100%);
    border-radius: 16px;
    border: 1px solid rgba(59, 130, 246, 0.1);
    display: flex;
    flex-direction: column;
    position: relative;
    overflow: hidden;
    transition: all 0.4s cubic-bezier(0.4, 0, 0.2, 1);
    box-shadow: 0 4px 6px rgba(0, 0, 0, 0.05), 0 1px 3px rgba(0, 0, 0, 0.1);
}

.tool-function-item::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    height: 4px;
    background: linear-gradient(90deg, #3b82f6, #8b5cf6, #06b6d4);
    transform: scaleX(0);
    transition: transform 0.3s ease;
    transform-origin: left;
}





.tool-function-title {
    font-size: 1.1rem;
    font-weight: 700;
    color: #1e293b;
    margin-bottom: 12px;
    display: flex;
    align-items: center;
    position: relative;
}

.tool-function-title i {
    margin-right: 12px;
    color: #3b82f6;
    font-size: 1.2rem;
    width: 32px;
    height: 32px;
    display: flex;
    align-items: center;
    justify-content: center;
    background: linear-gradient(135deg, rgba(59, 130, 246, 0.1), rgba(139, 92, 246, 0.1));
    border-radius: 10px;
    transition: all 0.3s ease;
    flex-shrink: 0;
}



.tool-function-desc {
    font-size: 0.9rem;
    color: #64748b;
    margin-left: 0;
    line-height: 1.6;
    flex-grow: 1;
    position: relative;
    padding-left: 44px;
}

.tool-function-desc::before {
    content: '';
    position: absolute;
    left: 16px;
    top: 8px;
    width: 2px;
    height: calc(100% - 16px);
    background: linear-gradient(180deg, rgba(59, 130, 246, 0.3), transparent);
    border-radius: 1px;
}

/* 使用场景 - 活泼设计 */
.tool-scenarios-list {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(320px, 1fr));
    gap: 20px;
    margin-top: 20px;
}

.tool-scenario-item {
    display: flex;
    flex-direction: column;
    padding: 24px;
    border-radius: 16px;
    background: linear-gradient(135deg, #ffffff 0%, #fefefe 50%, #f9fafb 100%);
    border: 1px solid rgba(16, 185, 129, 0.1);
    position: relative;
    overflow: hidden;
    transition: all 0.4s cubic-bezier(0.4, 0, 0.2, 1);
    box-shadow: 0 4px 6px rgba(0, 0, 0, 0.05), 0 1px 3px rgba(0, 0, 0, 0.1);
}

.tool-scenario-item::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    height: 4px;
    background: linear-gradient(90deg, #10b981, #06b6d4, #8b5cf6);
    transform: scaleX(0);
    transition: transform 0.3s ease;
    transform-origin: left;
}

.tool-scenario-item::after {
    content: '';
    position: absolute;
    top: -50%;
    right: -50%;
    width: 100%;
    height: 100%;
    background: radial-gradient(circle, rgba(16, 185, 129, 0.05) 0%, transparent 70%);
    opacity: 0;
    transition: opacity 0.3s ease;
    pointer-events: none;
}







.tool-scenario-header {
    display: flex;
    align-items: center;
    margin-bottom: 16px;
    padding-bottom: 12px;
    border-bottom: 1px solid rgba(16, 185, 129, 0.1);
    position: relative;
}

.tool-scenario-icon {
    margin-right: 12px;
    color: #10b981;
    font-size: 1.2rem;
    width: 32px;
    height: 32px;
    display: flex;
    align-items: center;
    justify-content: center;
    background: linear-gradient(135deg, rgba(16, 185, 129, 0.1), rgba(6, 182, 212, 0.1));
    border-radius: 10px;
    transition: all 0.3s ease;
    flex-shrink: 0;
}



.tool-scenario-title {
    font-size: 1.1rem;
    font-weight: 700;
    color: #1e293b;
    flex: 1;
}

.tool-scenario-desc {
    font-size: 0.9rem;
    color: #64748b;
    line-height: 1.6;
    margin-left: 0;
    flex-grow: 1;
    position: relative;
    padding-left: 44px;
}

.tool-scenario-desc::before {
    content: '';
    position: absolute;
    left: 16px;
    top: 8px;
    width: 2px;
    height: calc(100% - 16px);
    background: linear-gradient(180deg, rgba(16, 185, 129, 0.3), transparent);
    border-radius: 1px;
}

/* 相关工具 */
.related-tools-container {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(250px, 1fr));
    gap: 20px;
    margin-top: 15px;
}

.related-tool-card {
    background-color: var(--card-bg);
    border-radius: 10px;
    overflow: hidden;
    transition: all 0.3s ease;
    box-shadow: var(--card-shadow);
    height: 100%;
}



.related-tool-link {
    display: block;
    color: inherit;
    text-decoration: none;
}



.related-tool-body {
    display: flex;
    align-items: center;
    padding: 20px;
}

.related-tool-icon {
    width: 40px;
    height: 40px;
    min-width: 40px;
    border-radius: 8px;
    overflow: hidden;
    background-color: var(--hover-color);
    display: flex;
    align-items: center;
    justify-content: center;
    margin-right: 12px;
}

.related-tool-icon img {
    width: 24px;
    height: 24px;
    object-fit: contain;
}

.related-tool-info {
    flex: 1;
}

.related-tool-title {
    font-size: 1.1rem;
    font-weight: 700;
    margin: 0 0 8px 0;
    color: var(--text-color);
}

.related-tool-desc {
    font-size: 0.8rem;
    color: var(--primary-color);
    margin: 0;
    line-height: 1.3;
    display: -webkit-box;
    -webkit-line-clamp: 2;
    -webkit-box-orient: vertical;
    overflow: hidden;
}

/* 返回顶部按钮 */
.back-to-top {
    position: fixed;
    bottom: 30px;
    right: 30px;
    width: 40px;
    height: 40px;
    background-color: var(--accent-color);
    color: white;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    cursor: pointer;
    opacity: 0;
    visibility: hidden;
    transition: all 0.3s ease;
    z-index: 999;
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.15);
}

/* 头部返回首页按钮 */
.back-to-home-header {
    display: inline-flex;
    align-items: center;
    color: white;
    font-size: 0.9rem;
    transition: all 0.3s ease;
    background: linear-gradient(90deg, var(--accent-color), #6366f1);
    padding: 8px 16px;
    border-radius: 30px;
    font-weight: 500;
    box-shadow: 0 4px 10px rgba(59, 130, 246, 0.25);
    white-space: nowrap;
    text-decoration: none;
}

.back-to-home-header i {
    margin-right: 8px;
    transition: transform 0.3s ease;
}

.back-to-home-header:hover {
    background: linear-gradient(90deg, #2563eb, #4f46e5);
    transform: translateY(-2px);
    box-shadow: 0 6px 15px rgba(59, 130, 246, 0.35);
    color: white;
    text-decoration: none;
}

.back-to-home-header:hover i {
    transform: translateX(-2px);
}



.back-to-top.visible {
    opacity: 1;
    visibility: visible;
}



/* 响应式设计 */
@media (max-width: 992px) {
    .tool-functions-list {
        grid-template-columns: repeat(auto-fill, minmax(300px, 1fr));
        gap: 18px;
    }
    
    .tool-scenarios-list {
        grid-template-columns: repeat(auto-fill, minmax(300px, 1fr));
        gap: 18px;
    }
    
    .tool-function-item, .tool-scenario-item {
        padding: 20px;
    }
    
    .tool-detail-section-card {
        padding: 28px;
    }
}

@media (max-width: 768px) {
    .tool-detail-sections {
        grid-template-columns: 1fr;
        gap: 25px;
    }
    
    .tool-detail-header {
        flex-direction: column;
        align-items: flex-start;
        padding: 20px;
    }
    
    .tool-detail-icon {
        margin-bottom: 15px;
    }
    
    .tool-detail-title-row {
        flex-direction: column;
        align-items: flex-start;
        gap: 10px;
    }
    
    .tool-detail-section-card {
        padding: 24px;
        border-radius: 16px;
    }
    
    .tool-detail-section-title {
        font-size: 1.2rem;
        margin-bottom: 20px;
    }
    
    .tool-functions-list, .tool-scenarios-list {
        grid-template-columns: 1fr;
        gap: 16px;
    }
    
    .tool-function-item, .tool-scenario-item {
        padding: 20px;
        border-radius: 12px;
    }
    
    /* 移动端显示返回首页按钮 */
    .back-to-home-header {
        font-size: 0.8rem;
        padding: 6px 12px;
    }
    
    .tool-function-title i, .tool-scenario-icon {
        width: 28px;
        height: 28px;
        font-size: 1rem;
        margin-right: 10px;
    }
    
    .tool-function-desc, .tool-scenario-desc {
        padding-left: 38px;
        font-size: 0.85rem;
        line-height: 1.5;
    }
    
    .tool-function-desc::before, .tool-scenario-desc::before {
        left: 14px;
    }
    
    .tool-scenario-header {
        margin-bottom: 14px;
        padding-bottom: 10px;
    }
    
    .related-tools-container {
        grid-template-columns: 1fr;
    }
    
    .tool-detail-description {
        font-size: 0.9rem;
        line-height: 1.5;
    }
    
    .tool-detail-full-description {
        font-size: 0.85rem;
        line-height: 1.6;
        margin-top: 12px;
        padding-top: 12px;
    }
}

@media (max-width: 576px) {
    .tool-detail-meta {
        flex-direction: column;
        align-items: flex-start;
        gap: 8px;
    }
    
    .tool-detail-section-card {
        padding: 20px;
        border-radius: 12px;
    }
    
    .tool-detail-section-title {
        font-size: 1.1rem;
        margin-bottom: 18px;
    }
    
    .tool-functions-list, .tool-scenarios-list {
        grid-template-columns: 1fr;
        gap: 12px;
    }
    
    .tool-function-item, .tool-scenario-item {
        padding: 16px;
        border-radius: 10px;
    }
    
    .tool-function-item::before, .tool-scenario-item::before {
        height: 3px;
    }
    

    
    .tool-function-title, .tool-scenario-title {
        font-size: 1rem;
        margin-bottom: 10px;
    }
    
    .tool-function-title i, .tool-scenario-icon {
        width: 24px;
        height: 24px;
        font-size: 0.9rem;
        margin-right: 8px;
    }
    
    .tool-function-desc, .tool-scenario-desc {
        font-size: 0.8rem;
        line-height: 1.4;
        padding-left: 32px;
    }
    
    .tool-function-desc::before, .tool-scenario-desc::before {
        left: 12px;
        width: 1.5px;
    }
    
    .tool-scenario-header {
        margin-bottom: 10px;
        padding-bottom: 8px;
    }
    
    .tool-detail-title {
        font-size: 1.5rem;
        margin-top: 10px;
    }
    
    .tool-detail-icon {
        width: 64px;
        height: 64px;
    }
    
    .tool-detail-icon img {
        width: 36px;
        height: 36px;
    }
    
    .back-to-top {
        bottom: 20px;
        right: 20px;
        width: 36px;
        height: 36px;
    }
}