
/* ==================== 全局样式 ==================== */
:root {
    --primary-color: #6366f1;
    --secondary-color: #8b5cf6;
    --accent-color: #ec4899;
    --text-color: #1f2937;
    --light-text: #6b7280;
    --bg-color: #0f172a;
    --card-bg: #1e293b;
    --border-radius: 16px;
    --shadow: 0 10px 40px -10px rgba(0, 0, 0, 0.3);
    --transition: all 0.4s cubic-bezier(0.4, 0, 0.2, 1);
}





* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

html {
    scroll-behavior: smooth;
}

body {
    font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, "Helvetica Neue", Arial, sans-serif;
    line-height: 1.7;
    color: var(--text-color);
    background-color: var(--bg-color);
    overflow-x: hidden;
}

a {
    text-decoration: none;
    color: inherit;
}

ul {
    list-style: none;
}

/* ==================== 导航栏（灵动岛风格） ==================== */
.navbar {
    position: fixed;
    top: 12px;
    left: 50%;
    transform: translateX(-50%);
    width: auto;
    background: rgba(30, 41, 59, 0.37);
    backdrop-filter: blur(10px) saturate(180%);
    -webkit-backdrop-filter: blur(10px) saturate(180%);
    border-radius: 50px;
    z-index: 1000;
    padding: 0.6rem 1.5rem;
    box-shadow: 0 8px 32px rgba(0, 0, 0, 0.4);
    border: 1px solid rgba(255, 255, 255, 0.1);
    transition: transform 0.25s cubic-bezier(0.4, 0, 0.2, 1),
                border-radius 0.25s cubic-bezier(0.4, 0, 0.2, 1),
                padding 0.25s cubic-bezier(0.4, 0, 0.2, 1),
                min-width 0.25s cubic-bezier(0.4, 0, 0.2, 1),
                box-shadow 0.25s cubic-bezier(0.4, 0, 0.2, 1);
    cursor: pointer;
    will-change: transform, border-radius, padding, min-width;
    user-select: none;
    -webkit-user-select: none;
    -moz-user-select: none;
    -ms-user-select: none;
    -webkit-tap-highlight-color: transparent;
    touch-action: manipulation;
}

/* 收起状态 - 小药丸 */
.navbar.collapsed {
    min-width: 50px;
    width: 50px;
    height: 32px;
    padding: 0;
}

.navbar.collapsed:hover {
    transform: translateX(-50%) scale(1.05);
}

/* 展开状态 */
.navbar:not(.collapsed) {
    min-width: 280px;
    height: auto;
    padding: 0.6rem 1.5rem;
}

.navbar:not(.collapsed):hover {
    transform: translateX(-50%) scale(1.02);
    box-shadow: 0 12px 40px rgba(0, 0, 0, 0.5);
}

.navbar:not(.collapsed) {
    cursor: default;
}

.nav-container {
    display: flex;
    justify-content: center;
    align-items: center;
    position: relative;
    width: 100%;
    height: 100%;
}

/* 小药丸指示器 */
.nav-pill {
    width: 100%;
    height: 100%;
    min-width: 60px;
    border-radius: 20px;
    opacity: 0;
    transform: scale(0.5);
    transition: opacity 0.2s cubic-bezier(0.4, 0, 0.2, 1),
                transform 0.2s cubic-bezier(0.4, 0, 0.2, 1);
    position: absolute;
    display: flex;
    align-items: center;
    justify-content: center;
    will-change: opacity, transform;
    pointer-events: none;
}

.navbar.collapsed .nav-pill {
    opacity: 1;
    transform: scale(1);
    position: relative;
    pointer-events: auto;
}

.navbar:not(.collapsed) .nav-pill {
    opacity: 0;
    transform: scale(0.5);
}

.pill-content {
    display: flex;
    align-items: center;
    justify-content: center;
}

.pill-icon {
    color: rgba(255, 255, 255, 0.9);
    transition: transform 0.2s cubic-bezier(0.4, 0, 0.2, 1);
    will-change: transform;
}

.navbar.collapsed:hover .pill-icon {
    transform: rotate(90deg);
}

.nav-links {
    display: flex;
    gap: 1rem;
    opacity: 0;
    transform: scale(0.8);
    transition: opacity 0.25s cubic-bezier(0.4, 0, 0.2, 1) 0s,
                transform 0.25s cubic-bezier(0.4, 0, 0.2, 1) 0s;
    position: relative;
    will-change: opacity, transform;
    pointer-events: none;
}

.navbar.collapsed .nav-links {
    opacity: 0;
    transform: scale(0.6);
}

.navbar:not(.collapsed) .nav-links {
    opacity: 1;
    transform: scale(1);
    pointer-events: auto;
}

.nav-links a {
    color: rgba(255, 255, 255, 0.9);
    font-weight: 400;
    font-size: 0.9rem;
    transition: transform 0.15s cubic-bezier(0.4, 0, 0.2, 1),
                background 0.15s cubic-bezier(0.4, 0, 0.2, 1),
                color 0.15s cubic-bezier(0.4, 0, 0.2, 1);
    position: relative;
    padding: 0.5rem 1rem;
    border-radius: 20px;
    white-space: nowrap;
    will-change: transform;
    letter-spacing: 0.01em;
}

.nav-links a:hover {
    color: white;
    background: rgba(255, 255, 255, 0.2);
    transform: translateY(-2px);
}

/* 移动端优化 - 更快的动画 */
@media (max-width: 768px) {
    .navbar {
        transition: transform 0.2s cubic-bezier(0.25, 0.46, 0.45, 0.94),
                    border-radius 0.2s cubic-bezier(0.25, 0.46, 0.45, 0.94),
                    padding 0.2s cubic-bezier(0.25, 0.46, 0.45, 0.94),
                    min-width 0.2s cubic-bezier(0.25, 0.46, 0.45, 0.94),
                    box-shadow 0.2s cubic-bezier(0.25, 0.46, 0.45, 0.94);
    }
    
    .navbar.collapsed {
        min-width: 95px;
        width: 95px;
        height: 34px;
    }
    
    .nav-pill {
        transition: opacity 0.15s cubic-bezier(0.25, 0.46, 0.45, 0.94),
                    transform 0.15s cubic-bezier(0.25, 0.46, 0.45, 0.94);
    }
    
    .nav-links {
        transition: opacity 0.15s cubic-bezier(0.25, 0.46, 0.45, 0.94) 0.03s,
                    transform 0.15s cubic-bezier(0.25, 0.46, 0.45, 0.94) 0.03s;
    }
}

/* ==================== Hero区域 ==================== */
.hero {
    min-height: 100vh;
    display: flex;
    align-items: center;
    justify-content: center;
    text-align: center;
    position: relative;
    overflow: hidden;
}

/* 背景轮播 */
.hero-slideshow {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    z-index: 0;
}

.slide {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background-size: cover;
    background-position: center;
    opacity: 0;
    animation: slideshow 12s infinite;
}

.slide:nth-child(1) {
    animation-delay: 0s;
}

.slide:nth-child(2) {
    animation-delay: 4s;
}

.slide:nth-child(3) {
    animation-delay: 8s;
}

@keyframes slideshow {
    0% {
        opacity: 0;
        transform: scale(1);
    }
    8% {
        opacity: 1;
        transform: scale(1);
    }
    33% {
        opacity: 1;
        transform: scale(1);
    }
    41% {
        opacity: 0;
        transform: scale(1);
    }
    100% {
        opacity: 0;
        transform: scale(1);
    }
}

/* 手动切换时的样式 */
.hero-slideshow.manual .slide {
    animation: none;
    transition: opacity 0.6s ease;
}

.hero-slideshow.manual .slide.active {
    opacity: 1;
    transform: scale(1);
}

/* 指示器 */
.slide-indicators {
    position: absolute;
    bottom: 30px;
    left: 50%;
    transform: translateX(-50%);
    display: flex;
    gap: 12px;
    z-index: 10;
}

.indicator {
    width: 12px;
    height: 12px;
    border-radius: 50%;
    background: rgba(255, 255, 255, 0.3);
    cursor: pointer;
    transition: var(--transition);
    border: 2px solid transparent;
}

.indicator:hover {
    background: rgba(255, 255, 255, 0.6);
}

.indicator.active {
    background: white;
    transform: scale(1.2);
    box-shadow: 0 0 10px rgba(255, 255, 255, 0.5);
}

@media (max-width: 768px) {
    .indicator {
        width: 10px;
        height: 10px;
    }
}

/* 遮罩层 */
.hero-overlay {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: linear-gradient(135deg, rgba(15, 23, 42, 0.85) 0%, rgba(30, 41, 59, 0.75) 100%);
    z-index: 1;
}

.hero-content {
    max-width: 900px;
    margin: 0 auto;
    position: relative;
    z-index: 2;
    padding: 6rem 2rem;
}

.hero-title {
    font-size: 3.5rem;
    font-weight: 670;
    margin-bottom: 1.5rem;
    color: #ffffff;
    letter-spacing: -0.02em;
    text-shadow: 0 4px 20px rgba(0, 0, 0, 0.3);
}

@supports (-webkit-background-clip: text) or (background-clip: text) {
    .hero-title {
        background: linear-gradient(135deg, #fff 0%, rgba(255, 255, 255, 0.9) 100%);
        -webkit-background-clip: text;
        -webkit-text-fill-color: transparent;
        background-clip: text;
        color: transparent;
    }
}

.hero-subtitle {
    font-size: 1.4rem;
    margin-bottom: 2.5rem;
    color: rgba(255, 255, 255, 0.9);
    font-weight: 300;
    text-shadow: 0 2px 10px rgba(0, 0, 0, 0.3);
}

@media (max-width: 768px) {
    .hero-title {
        font-size: 2.5rem;
    }
    
    .hero-subtitle {
        font-size: 1.2rem;
    }
}

.tag {
    padding: 0.6rem 1.5rem;
    background: rgba(255, 255, 255, 0.1);
    border: 1px solid rgba(255, 255, 255, 0.2);
    border-radius: 50px;
    color: rgba(255, 255, 255, 0.9);
    font-size: 0.95rem;
    transition: var(--transition);
}

.tag:hover {
    background: rgba(255, 255, 255, 0.2);
    transform: translateY(-2px);
}

/* ==================== 三大领域 ==================== */
.domains {
    padding: 6rem 2rem;
    max-width: 1400px;
    margin: 0 auto;
}

.domains-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(300px, 1fr));
    gap: 2rem;
    margin-top: 3rem;
}

.domain-card {
    border-radius: var(--border-radius);
    padding: 2.5rem 2rem;
    text-align: center;
    border: none;
    position: relative;
    overflow: hidden;
    background-size: cover;
    background-position: center;
    min-height: 300px;
    transform: translateZ(0);
    background-color: rgba(30, 41, 59, 0.4);
    backface-visibility: hidden;
}

.domain-card::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: inherit;
    background-size: cover;
    background-position: center;
    filter: blur(8px);
    z-index: -1;
    transition: filter 0.3s ease;
    box-shadow: 0 0 0 10px rgba(30, 41, 59, 0.4);
}

.domain-card:hover {
    border-color: rgba(255, 255, 255, 0.2);
}

.domain-card:hover::before {
    filter: blur(0);
}

.domain-card:hover .domain-content {
    opacity: 0;
    visibility: hidden;
    transform: translateY(-20px);
    transition-delay: 0.1s;
}

.domain-content {
    color: white;
    text-align: center;
    padding: 1rem;
    position: relative;
    z-index: 2;
    opacity: 1;
    visibility: visible;
    transition: opacity 0.3s ease, visibility 0.3s ease, transform 0.3s ease;
    background: rgba(15, 23, 42, 0.6);
    border-radius: 8px;
    margin: 1rem;
}

.domain-title {
    font-size: 1.4rem;
    margin-bottom: 1rem;
    color: rgba(255, 255, 255, 0.95);
    font-weight: 400;
    letter-spacing: 0.01em;
    text-shadow: 0 1px 3px rgba(0, 0, 0, 0.3);
}

.domain-description {
    color: rgba(255, 255, 255, 0.85);
    margin-bottom: 1rem;
    font-size: 1rem;
    text-shadow: -1px -1px 0 rgba(0, 0, 0, 0.5),
                 1px -1px 0 rgba(0, 0, 0, 0.5),
                -1px 1px 0 rgba(0, 0, 0, 0.5),
                 1px 1px 0 rgba(0, 0, 0, 0.5);
}

.domain-icon {
    font-size: 3rem;
    margin-bottom: 1rem;
    color: rgba(255, 255, 255, 0.9);
    transition: var(--transition);
}

.tech-tag {
    display: inline-block;
    padding: 0.3rem 0.8rem;
    background: rgba(255, 255, 255, 0.15);
    border-radius: 20px;
    margin: 0.2rem;
    font-size: 0.85rem;
    color: rgba(255, 255, 255, 0.9);
    transition: var(--transition);
    text-shadow: -0.5px -0.5px 0 rgba(0, 0, 0, 0.3),
                 0.5px -0.5px 0 rgba(0, 0, 0, 0.3),
                -0.5px 0.5px 0 rgba(0, 0, 0, 0.3),
                 0.5px 0.5px 0 rgba(0, 0, 0, 0.3);
}

/* ==================== 详细内容区域 ==================== */
.details {
    padding: 6rem 2rem;
    max-width: 1400px;
    margin: 0 auto;
}

.detail-section {
    margin-bottom: 6rem;
}

.section-title {
    font-size: 2.2rem;
    margin-bottom: 0.5rem;
    color: white;
    font-weight: 300;
    text-align: center;
    letter-spacing: 0.02em;
    font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, "Helvetica Neue", Arial, "Noto Sans", sans-serif;
}

.section-subtitle {
    font-size: 0.9rem;
    margin-bottom: 2.5rem;
    color: rgba(255, 255, 255, 0.6);
    font-weight: 300;
    text-align: center;
    letter-spacing: 0.05em;
    text-transform: uppercase;
    font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, "Helvetica Neue", Arial, "Noto Sans", sans-serif;
}

.project-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(300px, 1fr));
    gap: 2rem;
}

.project-item {
    background: var(--card-bg);
    border-radius: var(--border-radius);
    overflow: hidden;
    border: 1px solid rgba(255, 255, 255, 0.1);
    transition: var(--transition);
    position: relative;
}

.project-item::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    height: 3px;
    background: linear-gradient(90deg, var(--primary-color), var(--secondary-color));
    transform: scaleX(0);
    transition: var(--transition);
}

.project-item:hover::before {
    transform: scaleX(1);
}

.project-item:hover {
    transform: translateY(-8px);
    box-shadow: var(--shadow);
}

.project-image {
    width: 100%;
    height: 250px;
    background-size: cover;
    background-position: center;
    background-repeat: no-repeat;
    position: relative;
    overflow: hidden;
}

.project-image::after {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: rgba(0, 0, 0, 0.2);
    opacity: 0;
    transition: var(--transition);
}

.project-item:hover .project-image::after {
    opacity: 1;
}

.project-item h3 {
    padding: 1.5rem 1.5rem 0.5rem;
    color: white;
    font-size: 1.3rem;
    font-weight: 400;
    letter-spacing: 0.01em;
}

.project-item p {
    padding: 0 1.5rem 1.5rem;
    color: var(--light-text);
}

.photo-gallery {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(250px, 1fr));
    gap: 1.5rem;
}

.photo-item {
    aspect-ratio: 1;
    background: linear-gradient(135deg, var(--secondary-color), var(--accent-color));
    border-radius: var(--border-radius);
    transition: var(--transition);
}

.photo-item:hover {
    transform: none;
    box-shadow: var(--shadow);
}

.anime-collection {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(280px, 1fr));
    gap: 2rem;
}

.collection-item {
    background: var(--card-bg);
    padding: 2rem;
    border-radius: var(--border-radius);
    border: 1px solid rgba(255, 255, 255, 0.1);
    transition: var(--transition);
}

.collection-item:hover {
    transform: translateY(-5px);
    box-shadow: var(--shadow);
}

.collection-item h3 {
    color: white;
    margin-bottom: 0.8rem;
    font-size: 1.3rem;
}

.collection-item p {
    color: var(--light-text);
}

/* ==================== 联系方式 ==================== */
.contact {
    padding: 6rem 2rem;
    text-align: center;
    max-width: 800px;
    margin: 0 auto;
}

.contact-info {
    display: flex;
    justify-content: center;
    gap: 3rem;
    margin-top: 3rem;
    flex-wrap: wrap;
}

.contact-item {
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 1rem;
    padding: 2rem;
    background: var(--card-bg);
    border-radius: var(--border-radius);
    border: 1px solid rgba(255, 255, 255, 0.1);
    transition: var(--transition);
    min-width: 200px;
    position: relative;
    overflow: hidden;
}

.contact-item:hover {
    transform: translateY(-3px);
    box-shadow: var(--shadow);
}

.contact-icon {
    display: flex;
    align-items: center;
    justify-content: center;
    width: 60px;
    height: 60px;
    background: transparent;
    border-radius: 50%;
    color: currentColor;
}

.contact-icon svg {
    width: 32px;
    height: 32px;
    color: rgba(255, 255, 255, 0.9);
}

.contact-item span {
    color: rgba(255, 255, 255, 0.8);
}

/* ==================== 页脚 ==================== */
.footer {
    padding: 3rem 2rem;
    text-align: center;
    border-top: 1px solid rgba(255, 255, 255, 0.1);
    color: rgba(255, 255, 255, 0.6);
}

/* ==================== 响应式设计 ==================== */
@media (max-width: 768px) {
    .navbar {
        min-width: auto;
        padding: 0.5rem 1rem;
        top: 8px;
    }
    
    .nav-links {
        gap: 0.3rem;
    }
    
    .nav-links a {
        font-size: 0.75rem;
        padding: 0.3rem 0.5rem;
    }

    .hero-title {
        font-size: 2.5rem;
    }

    .hero-subtitle {
        font-size: 1.2rem;
    }

    .domains-grid {
        grid-template-columns: 1fr;
    }

/* 简单卡片样式 */
.domain-card {
    background-size: cover;
    background-position: center;
    border-radius: 15px;
    padding: 2rem;
    backdrop-filter: blur(10px);
    min-height: 300px;
    position: relative;
}

/* 卡片内容样式 */



    .section-title {
        font-size: 2rem;
    }

    .project-grid {
        grid-template-columns: 1fr;
    }

    .contact-info {
        flex-direction: column;
        gap: 1.5rem;
    }

    .contact-item {
        width: 100%;
    }
}
