/* ===== 动画定义 ===== */
@keyframes fadeIn {
    from {
        opacity: 0;
        transform: translateY(20px);
    }

    to {
        opacity: 1;
        transform: translateY(0);
    }
}

@keyframes floatDust {

    0%,
    100% {
        transform: translateY(0) rotate(0deg);
        opacity: 0.3;
    }

    50% {
        transform: translateY(-8px) rotate(3deg);
        opacity: 0.6;
    }
}

@keyframes inkSpread {
    0% {
        transform: scale(0.8);
        opacity: 0;
    }

    100% {
        transform: scale(1);
        opacity: 1;
    }
}

/* ===== 基础样式 ===== */
body {
    margin: 0;
    font-family: "Noto Serif SC", "Source Han Serif SC", "Songti SC", "SimSun", serif;
    background-color: #f5f0e8;
    background-image:
        /* 重复菱形图案 - 淡雅稀疏 */
        linear-gradient(45deg, rgba(139, 119, 101, 0.015) 25%, transparent 25%),
        linear-gradient(-45deg, rgba(139, 119, 101, 0.015) 25%, transparent 25%),
        linear-gradient(45deg, transparent 75%, rgba(139, 119, 101, 0.015) 75%),
        linear-gradient(-45deg, transparent 75%, rgba(139, 119, 101, 0.015) 75%),
        /* 墨韵晕染 */
        radial-gradient(ellipse at 20% 30%, rgba(200, 180, 160, 0.06) 0%, transparent 50%),
        radial-gradient(ellipse at 80% 70%, rgba(180, 160, 140, 0.05) 0%, transparent 50%),
        /* 基础渐变 */
        linear-gradient(180deg, #faf8f5 0%, #f5f0e8 50%, #efe8dc 100%);
    background-size:
        60px 60px, 60px 60px, 60px 60px, 60px 60px,
        100% 100%, 100% 100%, 100% 100%;
    color: #3a3632;
    display: flex;
    justify-content: center;
    align-items: center;
    min-height: 100vh;
    padding: 40px 20px;
    box-sizing: border-box;
    position: relative;
    overflow: hidden;
}

/* 装饰性背景元素 */
body::before {
    content: '';
    position: fixed;
    top: -50%;
    right: -30%;
    width: 80%;
    height: 80%;
    background: radial-gradient(circle, rgba(139, 119, 101, 0.02) 0%, transparent 70%);
    border-radius: 50%;
    pointer-events: none;
}

body::after {
    content: '';
    position: fixed;
    bottom: -40%;
    left: -20%;
    width: 60%;
    height: 60%;
    background: radial-gradient(circle, rgba(180, 160, 140, 0.03) 0%, transparent 60%);
    border-radius: 50%;
    pointer-events: none;
}

/* 微尘粒子容器 */
.dust-particles {
    position: fixed;
    inset: 0;
    pointer-events: none;
    z-index: 0;
}

.dust {
    position: absolute;
    width: 3px;
    height: 3px;
    background: radial-gradient(circle, rgba(139, 119, 101, 0.5) 0%, transparent 70%);
    border-radius: 50%;
    animation: floatDust 8s ease-in-out infinite;
}

.dust:nth-child(1) {
    top: 15%;
    left: 10%;
    animation-delay: 0s;
}

.dust:nth-child(2) {
    top: 25%;
    right: 15%;
    animation-delay: 2s;
    width: 2px;
    height: 2px;
}

.dust:nth-child(3) {
    top: 60%;
    left: 20%;
    animation-delay: 4s;
}

.dust:nth-child(4) {
    top: 70%;
    right: 25%;
    animation-delay: 1s;
    width: 4px;
    height: 4px;
}

.dust:nth-child(5) {
    top: 40%;
    left: 5%;
    animation-delay: 3s;
    width: 2px;
    height: 2px;
}

.dust:nth-child(6) {
    top: 80%;
    right: 10%;
    animation-delay: 5s;
}

/* ===== 主容器 ===== */
.container {
    text-align: center;
    background:
        linear-gradient(135deg, rgba(255, 253, 250, 0.95) 0%, rgba(252, 249, 244, 0.9) 100%);
    max-width: 640px;
    width: 100%;
    padding: 60px 50px;
    box-sizing: border-box;
    border-radius: 4px;
    border: 1px solid rgba(139, 119, 101, 0.15);
    box-shadow:
        0 20px 60px rgba(139, 119, 101, 0.08),
        0 8px 25px rgba(0, 0, 0, 0.04),
        inset 0 1px 0 rgba(255, 255, 255, 0.8);
    position: relative;
}

/* 容器角落装饰 */
.container::before,
.container::after {
    content: '';
    position: absolute;
    width: 40px;
    height: 40px;
    border: 1px solid rgba(139, 119, 101, 0.2);
    pointer-events: none;
}

.container::before {
    top: 15px;
    left: 15px;
    border-right: none;
    border-bottom: none;
}

.container::after {
    bottom: 15px;
    right: 15px;
    border-left: none;
    border-top: none;
}

.container * {
    opacity: 0;
    animation: fadeIn 0.8s ease forwards;
}

/* ===== 头部区域 ===== */
header {
    margin-bottom: 45px;
    position: relative;
}

.avatar-container {
    display: flex;
    justify-content: center;
}

.avatar {
    width: 120px;
    height: 120px;
    border-radius: 50%;
    box-shadow:
        0 4px 20px rgba(139, 119, 101, 0.15),
        0 8px 40px rgba(139, 119, 101, 0.1);
    animation-delay: 0.1s;
    transition: box-shadow 0.4s ease;
    position: relative;
}

/* 头像外圈装饰 */
.avatar::before {
    content: '';
    position: absolute;
    inset: -8px;
    border-radius: 50%;
    border: 1px dashed rgba(139, 119, 101, 0.25);
    animation: none;
    opacity: 1;
}

.avatar-image {
    width: 100%;
    height: 100%;
    object-fit: cover;
    border-radius: 50%;
    animation: none;
    opacity: 1;
    cursor: pointer;
    transition: transform 0.4s cubic-bezier(0.34, 1.56, 0.64, 1);
}

.avatar:hover {
    box-shadow:
        0 8px 30px rgba(139, 119, 101, 0.2),
        0 15px 50px rgba(139, 119, 101, 0.12);
}

.avatar:hover .avatar-image {
    transform: rotate(8deg) scale(1.05);
}

.h1-logo {
    display: block;
    margin: 30px auto 20px;
    height: 42px;
    animation-delay: 0.2s;
    filter: drop-shadow(0 2px 4px rgba(0, 0, 0, 0.08));
}

.subtitle {
    font-size: 1.1em;
    color: #7a7067;
    margin: 0;
    animation-delay: 0.3s;
    letter-spacing: 2px;
    font-weight: 400;
}

/* ===== 装饰分隔线 ===== */
.divider {
    display: flex;
    align-items: center;
    justify-content: center;
    margin: 35px 0;
    animation-delay: 0.4s;
}

.divider::before,
.divider::after {
    content: '';
    flex: 1;
    max-width: 80px;
    height: 1px;
    background: linear-gradient(90deg, transparent, rgba(139, 119, 101, 0.3), transparent);
}

.divider-symbol {
    margin: 0 20px;
    color: rgba(139, 119, 101, 0.5);
    font-size: 0.8em;
}

/* ===== 社交链接 ===== */
.social-links {
    margin: 40px 0;
    display: flex;
    flex-wrap: wrap;
    justify-content: center;
    gap: 10px;
}

.social-links a {
    text-decoration: none;
    color: #5a534c;
    display: inline-flex;
    align-items: center;
    gap: 8px;
    padding: 10px 16px;
    border-radius: 2px;
    position: relative;
    overflow: hidden;
    background: rgba(255, 253, 250, 0.8);
    border: 1px solid rgba(139, 119, 101, 0.12);
    box-shadow: 0 2px 8px rgba(139, 119, 101, 0.06);
    transition: all 0.4s cubic-bezier(0.34, 1.56, 0.64, 1);
}

.social-links a::before {
    content: '';
    position: absolute;
    inset: 0;
    background: linear-gradient(135deg, rgba(139, 119, 101, 0.06) 0%, rgba(139, 119, 101, 0.12) 100%);
    opacity: 0;
    transition: opacity 0.3s ease;
    z-index: -1;
}

/* 左侧装饰线 */
.social-links a::after {
    content: '';
    position: absolute;
    left: 0;
    top: 50%;
    transform: translateY(-50%) scaleY(0);
    width: 2px;
    height: 60%;
    background: linear-gradient(180deg, transparent, rgba(180, 90, 80, 0.6), transparent);
    transition: transform 0.3s ease;
}

.social-links a img {
    width: 1.2em;
    height: 1.2em;
    transition: transform 0.4s cubic-bezier(0.34, 1.56, 0.64, 1);
    opacity: 0.75;
}

.social-links a span {
    font-size: 0.9em;
    font-weight: 500;
    letter-spacing: 1px;
    transition: letter-spacing 0.3s ease, color 0.3s ease;
}

.social-links a:nth-child(1) {
    animation-delay: 0.5s;
}

.social-links a:nth-child(2) {
    animation-delay: 0.6s;
}

.social-links a:nth-child(3) {
    animation-delay: 0.7s;
}

.social-links a:nth-child(4) {
    animation-delay: 0.8s;
}

.social-links a:hover {
    color: #8b5a4a;
    transform: translateY(-3px);
    box-shadow:
        0 6px 20px rgba(139, 119, 101, 0.12),
        0 3px 8px rgba(0, 0, 0, 0.04);
    border-color: rgba(139, 119, 101, 0.2);
}

.social-links a:hover::before {
    opacity: 1;
}

.social-links a:hover::after {
    transform: translateY(-50%) scaleY(1);
}

.social-links a:hover img {
    transform: scale(1.1);
    opacity: 1;
}

.social-links a:hover span {
    letter-spacing: 1.5px;
}

.social-links a:active {
    transform: translateY(-1px) scale(0.98);
    transition-duration: 0.1s;
}

/* ===== 页脚 ===== */
footer {
    padding-top: 20px;
    margin-top: 35px;
    font-size: 0.72em;
    color: #a9a199;
    letter-spacing: 1px;
    animation-delay: 1.1s;
    position: relative;
    line-height: 2;
}

footer::before {
    content: '';
    position: absolute;
    top: 0;
    left: 50%;
    transform: translateX(-50%);
    width: 40px;
    height: 1px;
    background: linear-gradient(90deg, transparent, rgba(139, 119, 101, 0.3), transparent);
}

.footer-copyright {
    margin-bottom: 8px;
}

.footer-links {
    display: flex;
    justify-content: center;
    align-items: center;
    gap: 8px;
    flex-wrap: wrap;
}

.footer-links a {
    color: #a9a199;
    text-decoration: none;
    transition: color 0.3s ease;
}

.footer-links a:hover {
    color: #8b7765;
}

.footer-links .separator {
    color: #c9c1b9;
}

/* ===== 响应式 ===== */
@media (max-width: 480px) {
    body {
        padding: 20px;
    }

    .container {
        padding: 45px 30px;
    }

    .container::before,
    .container::after {
        width: 25px;
        height: 25px;
        top: 10px;
        left: 10px;
    }

    .container::after {
        top: auto;
        left: auto;
        bottom: 10px;
        right: 10px;
    }

    .avatar {
        width: 100px;
        height: 100px;
    }

    .avatar::before {
        inset: -6px;
    }

    .h1-logo {
        height: 36px;
    }

    .subtitle {
        font-size: 1em;
        letter-spacing: 1px;
    }

    .social-links {
        gap: 10px;
    }

    .social-links a {
        padding: 10px 18px;
    }

    .social-links a img {
        width: 1.1em;
        height: 1.1em;
    }

    .social-links a span {
        font-size: 0.85em;
    }

    footer {
        font-size: 0.7em;
    }
}