/* --- 技术栈页面特定样式 --- */

/* 技术概览区域 */
.tech-overview {
    padding: 80px 0;
    background: linear-gradient(135deg, #0f1419 0%, #1a2332 100%);
    padding-top: 120px; /* 为固定导航栏留出空间 */
}

.tech-overview-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(280px, 1fr));
    gap: 30px;
    margin-top: 50px;
}

.tech-overview-card {
    background: rgba(255, 255, 255, 0.05);
    border: 1px solid rgba(255, 255, 255, 0.1);
    border-radius: 20px;
    padding: 40px 30px;
    text-align: center;
    transition: all 0.3s ease;
    backdrop-filter: blur(10px);
    position: relative;
    overflow: hidden;
}

.tech-overview-card::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    height: 3px;
    background: linear-gradient(90deg, #3b82f6, #8b5cf6, #ec4899);
    transform: scaleX(0);
    transition: transform 0.3s ease;
}

.tech-overview-card:hover::before {
    transform: scaleX(1);
}

.tech-overview-card:hover {
    transform: translateY(-10px);
    box-shadow: 0 20px 40px rgba(0, 0, 0, 0.3);
    border-color: rgba(59, 130, 246, 0.3);
}

.tech-overview-icon {
    width: 80px;
    height: 80px;
    margin: 0 auto 24px;
    background: linear-gradient(135deg, #3b82f6, #8b5cf6);
    border-radius: 20px;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 32px;
    color: #ffffff;
    position: relative;
}

.tech-overview-icon::after {
    content: '';
    position: absolute;
    top: -2px;
    left: -2px;
    right: -2px;
    bottom: -2px;
    background: linear-gradient(135deg, #3b82f6, #8b5cf6, #ec4899);
    border-radius: 22px;
    z-index: -1;
    opacity: 0.5;
}

.tech-overview-card h3 {
    font-size: 1.5rem;
    font-weight: 600;
    color: #ffffff;
    margin-bottom: 16px;
}

.tech-overview-card p {
    color: #cbd5e1;
    line-height: 1.6;
    margin-bottom: 24px;
}

.tech-overview-stats {
    display: flex;
    justify-content: space-around;
    gap: 20px;
}

.stat {
    text-align: center;
}

.stat-number {
    display: block;
    font-size: 1.5rem;
    font-weight: 700;
    color: #3b82f6;
    margin-bottom: 4px;
}

.stat-label {
    font-size: 0.875rem;
    color: #94a3b8;
    font-weight: 500;
}

/* 技术标签云区域 */
.tech-cloud-section {
    padding: 80px 0;
    background: linear-gradient(135deg, #1a2332 0%, #0f1419 100%);
    position: relative;
    text-align: center; /* 确保子元素居中 */
}

.tech-cloud-section .container {
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
}

.tech-cloud {
    position: relative;
    height: 800px; /* 增加高度 */
    margin: 40px auto 0;
    max-width: 1000px;
    width: 100%;
    overflow: visible;
    padding: 20px;
    border: 1px solid rgba(255, 255, 255, 0.05);
    border-radius: 20px;
    background: rgba(255, 255, 255, 0.02);
    box-shadow: 0 10px 30px rgba(0, 0, 0, 0.2);
    box-sizing: border-box;
}

.tech-tag {
    position: absolute;
    padding: 10px 18px;
    background: rgba(59, 130, 246, 0.1);
    border: 1px solid rgba(59, 130, 246, 0.3);
    border-radius: 20px;
    color: #3b82f6;
    font-size: 14px;
    font-weight: 500;
    cursor: pointer;
    transition: all 0.3s ease;
    backdrop-filter: blur(10px);
    animation: float 8s ease-in-out infinite;
    max-width: 130px;
    text-align: center;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
    z-index: 5;
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.2);
    transform-origin: center center;
    line-height: 1.2;
    margin: 0;
    min-width: 60px; /* 设置最小宽度 */
    min-height: 20px; /* 设置最小高度 */
}

.tech-tag:hover {
    background: rgba(59, 130, 246, 0.2);
    border-color: rgba(59, 130, 246, 0.5);
    transform: scale(1.1) translateY(-5px);
    z-index: 10;
    box-shadow: 0 8px 20px rgba(0, 0, 0, 0.3);
}

/* 根据类别设置不同的颜色 */
.tech-tag.frontend {
    background: rgba(59, 130, 246, 0.1);
    border-color: rgba(59, 130, 246, 0.3);
    color: #3b82f6;
}

.tech-tag.backend {
    background: rgba(147, 51, 234, 0.1);
    border-color: rgba(147, 51, 234, 0.3);
    color: #8b5cf6;
}

.tech-tag.database {
    background: rgba(236, 72, 153, 0.1);
    border-color: rgba(236, 72, 153, 0.3);
    color: #ec4899;
}

.tech-tag.mobile {
    background: rgba(16, 185, 129, 0.1);
    border-color: rgba(16, 185, 129, 0.3);
    color: #10b981;
}

/* 技术类别展示区域 */
.tech-categories {
    padding: 80px 0;
    background: linear-gradient(135deg, #0f1419 0%, #1a2332 100%);
}

.tech-category {
    margin-bottom: 80px;
}

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

.category-header {
    text-align: center;
    margin-bottom: 50px;
}

.category-icon {
    width: 80px;
    height: 80px;
    margin: 0 auto 24px;
    background: linear-gradient(135deg, #3b82f6, #8b5cf6);
    border-radius: 20px;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 32px;
    color: #ffffff;
    position: relative;
}

.category-icon::after {
    content: '';
    position: absolute;
    top: -2px;
    left: -2px;
    right: -2px;
    bottom: -2px;
    background: linear-gradient(135deg, #3b82f6, #8b5cf6, #ec4899);
    border-radius: 22px;
    z-index: -1;
    opacity: 0.5;
}

.category-header h2 {
    font-size: 2.5rem;
    font-weight: 700;
    color: #ffffff;
    margin-bottom: 16px;
    background: linear-gradient(135deg, #3b82f6, #8b5cf6);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
}

.category-header p {
    font-size: 1.1rem;
    color: #cbd5e1;
    line-height: 1.6;
    max-width: 600px;
    margin: 0 auto;
}

.tech-items {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(350px, 1fr));
    gap: 30px;
}

.tech-item {
    background: rgba(255, 255, 255, 0.05);
    border: 1px solid rgba(255, 255, 255, 0.1);
    border-radius: 20px;
    padding: 30px;
    transition: all 0.3s ease;
    backdrop-filter: blur(10px);
    position: relative;
    overflow: hidden;
}

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

.tech-item:hover::before {
    transform: scaleX(1);
}

.tech-item:hover {
    transform: translateY(-10px);
    box-shadow: 0 20px 40px rgba(0, 0, 0, 0.3);
    border-color: rgba(59, 130, 246, 0.3);
}

.tech-header {
    display: flex;
    align-items: center;
    gap: 16px;
    margin-bottom: 20px;
}

.tech-icon {
    width: 50px;
    height: 50px;
    background: linear-gradient(135deg, #3b82f6, #8b5cf6);
    border-radius: 12px;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 20px;
    color: #ffffff;
}

.tech-badge {
    padding: 4px 12px;
    background: rgba(236, 72, 153, 0.1);
    border: 1px solid rgba(236, 72, 153, 0.3);
    border-radius: 20px;
    color: #ec4899;
    font-size: 12px;
    font-weight: 500;
}

.tech-item h3 {
    font-size: 1.5rem;
    font-weight: 600;
    color: #ffffff;
    margin-bottom: 16px;
}

.tech-details p {
    color: #cbd5e1;
    line-height: 1.6;
    margin-bottom: 20px;
}

.tech-features {
    display: flex;
    flex-wrap: wrap;
    gap: 8px;
}

.feature-tag {
    padding: 4px 12px;
    background: rgba(59, 130, 246, 0.1);
    border: 1px solid rgba(59, 130, 246, 0.3);
    border-radius: 20px;
    color: #3b82f6;
    font-size: 12px;
    font-weight: 500;
}

/* 技术能力展示区域 */
.tech-capabilities {
    padding: 80px 0;
    background: linear-gradient(135deg, #1a2332 0%, #0f1419 100%);
}

.capabilities-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(280px, 1fr));
    gap: 30px;
    margin-top: 50px;
}

.capability-card {
    background: rgba(255, 255, 255, 0.05);
    border: 1px solid rgba(255, 255, 255, 0.1);
    border-radius: 20px;
    padding: 40px 30px;
    text-align: center;
    transition: all 0.3s ease;
    backdrop-filter: blur(10px);
    position: relative;
    overflow: hidden;
}

.capability-card::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    height: 3px;
    background: linear-gradient(90deg, #3b82f6, #8b5cf6, #ec4899);
    transform: scaleX(0);
    transition: transform 0.3s ease;
}

.capability-card:hover::before {
    transform: scaleX(1);
}

.capability-card:hover {
    transform: translateY(-10px);
    box-shadow: 0 20px 40px rgba(0, 0, 0, 0.3);
    border-color: rgba(59, 130, 246, 0.3);
}

.capability-icon {
    width: 80px;
    height: 80px;
    margin: 0 auto 24px;
    background: linear-gradient(135deg, #3b82f6, #8b5cf6);
    border-radius: 20px;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 32px;
    color: #ffffff;
    position: relative;
}

.capability-icon::after {
    content: '';
    position: absolute;
    top: -2px;
    left: -2px;
    right: -2px;
    bottom: -2px;
    background: linear-gradient(135deg, #3b82f6, #8b5cf6, #ec4899);
    border-radius: 22px;
    z-index: -1;
    opacity: 0.5;
}

.capability-card h3 {
    font-size: 1.5rem;
    font-weight: 600;
    color: #ffffff;
    margin-bottom: 16px;
}

.capability-card p {
    color: #cbd5e1;
    line-height: 1.6;
    margin-bottom: 24px;
}

.capability-metric {
    text-align: center;
}

.metric-number {
    display: block;
    font-size: 2rem;
    font-weight: 700;
    color: #3b82f6;
    margin-bottom: 4px;
}

.metric-label {
    font-size: 0.875rem;
    color: #94a3b8;
    font-weight: 500;
}

/* 响应式设计 */
@media (max-width: 768px) {
    .tech-overview-grid {
        grid-template-columns: 1fr;
        gap: 20px;
    }
    
    .tech-items {
        grid-template-columns: 1fr;
        gap: 20px;
    }
    
    .capabilities-grid {
        grid-template-columns: 1fr;
        gap: 20px;
    }
    
    .tech-cloud {
        height: 300px;
    }
    
    .category-header h2 {
        font-size: 2rem;
    }
    
    .tech-overview-stats {
        flex-direction: column;
        gap: 16px;
    }
}

@media (max-width: 480px) {
    .tech-item {
        padding: 20px;
    }
    
    .tech-header {
        flex-direction: column;
        align-items: flex-start;
        gap: 12px;
    }
    
    .tech-features {
        justify-content: flex-start;
    }
    
    .category-header h2 {
        font-size: 1.75rem;
    }
    
    .tech-overview-card,
    .capability-card {
        padding: 30px 20px;
    }
}

/* 动画效果 */
@keyframes float {
    0% {
        transform: translateY(0px) rotate(0deg);
    }
    25% {
        transform: translateY(-10px) rotate(2deg);
    }
    50% {
        transform: translateY(0px) rotate(0deg);
    }
    75% {
        transform: translateY(10px) rotate(-2deg);
    }
    100% {
        transform: translateY(0px) rotate(0deg);
    }
}

/* 技术标签动画 */
.tech-tag {
    animation: float 8s ease-in-out infinite;
}

.tech-tag:nth-child(1) { animation-delay: 0s; }
.tech-tag:nth-child(2) { animation-delay: 0.5s; }
.tech-tag:nth-child(3) { animation-delay: 1s; }
.tech-tag:nth-child(4) { animation-delay: 1.5s; }
.tech-tag:nth-child(5) { animation-delay: 2s; }
.tech-tag:nth-child(6) { animation-delay: 2.5s; }
.tech-tag:nth-child(7) { animation-delay: 3s; }
.tech-tag:nth-child(8) { animation-delay: 3.5s; }
.tech-tag:nth-child(9) { animation-delay: 4s; }
.tech-tag:nth-child(10) { animation-delay: 4.5s; }
.tech-tag:nth-child(11) { animation-delay: 5s; }
.tech-tag:nth-child(12) { animation-delay: 5.5s; }
.tech-tag:nth-child(13) { animation-delay: 6s; }
.tech-tag:nth-child(14) { animation-delay: 6.5s; }

/* 技术图标悬停效果 */
.tech-icon,
.tech-overview-icon,
.capability-icon {
    transition: all 0.3s ease;
}

.tech-icon:hover,
.tech-overview-icon:hover,
.capability-icon:hover {
    transform: rotate(360deg) scale(1.1);
}

/* 技术卡片悬停效果增强 */
.tech-item:hover .tech-icon {
    transform: rotate(360deg) scale(1.1);
}

.tech-overview-card:hover .tech-overview-icon {
    transform: rotate(360deg) scale(1.1);
}

.capability-card:hover .capability-icon {
    transform: rotate(360deg) scale(1.1);
}
