/* 全局样式重置 */
* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

:root {
    /* Carrd 风格配色 - 灰黑泛蓝 */
    --bg-gradient-start: #0a0e1a;
    --bg-gradient-end: #121824;
    --card-bg: rgba(255, 255, 255, 0.03);
    --card-border: rgba(255, 255, 255, 0.1);
    --text-primary: #f1f5f9;
    --text-secondary: #94a3b8;
    --accent-color: #818cf8;
    --button-bg: rgba(129, 140, 248, 0.1);
    --button-hover: rgba(129, 140, 248, 0.2);
    
    /* 字体 */
    --font-primary: -apple-system, BlinkMacSystemFont, 'Segoe UI', 'Roboto', 'Helvetica Neue', Arial, sans-serif;
}

body {
    font-family: var(--font-primary);
    background: linear-gradient(135deg, var(--bg-gradient-start) 0%, var(--bg-gradient-end) 100%);
    color: var(--text-primary);
    line-height: 1.6;
    min-height: 100vh;
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 2rem 1rem;
    position: relative;
    overflow-x: hidden;
}

/* 背景动态效果 */
body::before {
    content: '';
    position: fixed;
    top: -50%;
    left: -50%;
    width: 200%;
    height: 200%;
    background: 
        radial-gradient(circle at 20% 50%, rgba(99, 128, 248, 0.18) 0%, transparent 50%),
        radial-gradient(circle at 80% 80%, rgba(129, 159, 255, 0.12) 0%, transparent 50%);
    animation: gradient-shift 15s ease infinite;
    pointer-events: none;
    z-index: 0;
}

@keyframes gradient-shift {
    0%, 100% {
        transform: translate(0, 0);
    }
    50% {
        transform: translate(-5%, -5%);
    }
}

/* 主卡片容器 */
.card {
    max-width: 680px;
    width: 100%;
    background: var(--card-bg);
    backdrop-filter: blur(20px);
    -webkit-backdrop-filter: blur(20px);
    border: 1px solid var(--card-border);
    border-radius: 24px;
    padding: 3rem 2.5rem;
    box-shadow: 0 25px 50px -12px rgba(0, 0, 0, 0.25);
    position: relative;
    z-index: 1;
    animation: fadeInScale 0.6s ease-out;
}

@keyframes fadeInScale {
    from {
        opacity: 0;
        transform: scale(0.95) translateY(20px);
    }
    to {
        opacity: 1;
        transform: scale(1) translateY(0);
    }
}

/* 个人信息区域 */
.profile {
    text-align: center;
    margin-bottom: 2.5rem;
}

.avatar {
    margin-bottom: 1.5rem;
    animation: fadeIn 0.8s ease-out 0.2s both;
}

.avatar img {
    width: 120px;
    height: 120px;
    border-radius: 50%;
    border: 3px solid var(--accent-color);
    box-shadow: 0 8px 24px rgba(129, 140, 248, 0.3);
    transition: transform 0.3s ease, box-shadow 0.3s ease;
}

.avatar img:hover {
    transform: scale(1.05);
    box-shadow: 0 12px 32px rgba(129, 140, 248, 0.4);
}

.name {
    font-size: 2rem;
    font-weight: 700;
    margin-bottom: 0.5rem;
    color: var(--text-primary);
    letter-spacing: -0.02em;
    animation: fadeIn 0.8s ease-out 0.3s both;
}

.bio {
    font-size: 1rem;
    color: var(--text-secondary);
    margin-bottom: 1rem;
    animation: fadeIn 0.8s ease-out 0.4s both;
}

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

/* 社交链接图标 */
.social-links {
    display: flex;
    justify-content: center;
    align-items: center;
    gap: 1.25rem;
    margin: 2.5rem 0;
    flex-wrap: wrap;
}

.social-icon {
    width: 48px;
    height: 48px;
    display: flex;
    align-items: center;
    justify-content: center;
    background: var(--button-bg);
    border: 1px solid var(--card-border);
    border-radius: 12px;
    color: var(--accent-color);
    text-decoration: none;
    transition: all 0.3s ease;
    position: relative;
    overflow: hidden;
    animation: scaleIn 0.5s ease-out both;
}

.social-icon:nth-child(1) { animation-delay: 0.5s; }
.social-icon:nth-child(2) { animation-delay: 0.6s; }
.social-icon:nth-child(3) { animation-delay: 0.7s; }

@keyframes scaleIn {
    from {
        opacity: 0;
        transform: scale(0.5);
    }
    to {
        opacity: 1;
        transform: scale(1);
    }
}

.social-icon::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: linear-gradient(135deg, rgba(129, 140, 248, 0.2), rgba(165, 180, 252, 0.1));
    opacity: 0;
    transition: opacity 0.3s ease;
}

.social-icon:hover {
    background: var(--button-hover);
    border-color: var(--accent-color);
    transform: translateY(-4px) scale(1.05);
    box-shadow: 0 8px 20px rgba(129, 140, 248, 0.3);
}

.social-icon:hover::before {
    opacity: 1;
}

.social-icon:active {
    transform: translateY(-2px) scale(1);
}

.social-icon svg {
    width: 24px;
    height: 24px;
    position: relative;
    z-index: 1;
    transition: transform 0.3s ease;
}

.social-icon img {
    width: 28px;
    height: 28px;
    object-fit: cover;
    border-radius: 6px;
    position: relative;
    z-index: 1;
    transition: transform 0.3s ease;
}

.social-icon:hover svg {
    transform: scale(1.15) rotate(5deg);
}

.social-icon:hover img {
    transform: scale(1.15);
}

/* Backloggd 特殊样式 */
.backloggd-icon:hover {
    border-color: #6c8aef;
}

/* Letterboxd 特殊样式 */
.letterboxd-icon:hover {
    border-color: #00d735;
}

/* 页脚 */
.footer {
    text-align: center;
    padding-top: 2rem;
    border-top: 1px solid var(--card-border);
    animation: fadeIn 0.8s ease-out 1s both;
}

.footer p {
    color: var(--text-secondary);
    font-size: 0.875rem;
}

/* 响应式设计 */
@media (max-width: 640px) {
    body {
        padding: 1rem 0.75rem;
    }
    
    .card {
        padding: 2rem 1.5rem;
        border-radius: 20px;
    }
    
    .name {
        font-size: 1.75rem;
    }
    
    .bio {
        font-size: 0.95rem;
    }
    
    .avatar img {
        width: 100px;
        height: 100px;
    }
    
    .social-links {
        gap: 1rem;
        margin: 2rem 0;
    }
    
    .social-icon {
        width: 44px;
        height: 44px;
    }
    
    .social-icon svg {
        width: 22px;
        height: 22px;
    }
}

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

::-webkit-scrollbar-track {
    background: #0a0e1a;
}

::-webkit-scrollbar-thumb {
    background: rgba(129, 140, 248, 0.3);
    border-radius: 4px;
}

::-webkit-scrollbar-thumb:hover {
    background: var(--accent-color);
}
