/* ========================================
   榭 | 个人主页
   手账风 · 黑白灰 + 淡紫 · 侧边导航 + 手绘装饰
   ======================================== */

:root {
    --black: #1a1a1a;
    --white: #fafafa;
    --gray-light: #f5f5f5;
    --gray: #888;
    --purple: #9b7ebd;
    --purple-light: #c4a8db;
    --purple-lighter: #e8dff0;
    --shadow: 0 4px 20px rgba(0, 0, 0, 0.1);
    --radius: 8px;
    --transition: all 0.3s ease;
}

* { margin: 0; padding: 0; box-sizing: border-box; }

body {
    font-family: 'Noto Sans SC', -apple-system, sans-serif;
    background: var(--gray-light);
    color: var(--black);
    line-height: 1.7;
}

a { text-decoration: none; color: inherit; }
img { max-width: 100%; height: auto; display: block; }

::selection { background: var(--purple-light); }

/* ====== 页面布局 ====== */
.page-wrapper {
    display: flex;
    min-height: 100vh;
}

/* ====== 侧边导航栏 ====== */
.sidebar {
    width: 200px;
    background: var(--white);
    border-right: 2px solid var(--black);
    position: fixed;
    height: 100vh;
    display: flex;
    flex-direction: column;
    z-index: 100;
}

.sidebar-header {
    padding: 30px 20px 20px;
    border-bottom: 2px dashed var(--gray);
}

.sidebar-title {
    font-family: 'Ma Shan Zheng', cursive;
    font-size: 1.4rem;
    color: var(--black);
}

.sidebar-divider {
    margin-top: 10px;
    height: 3px;
    background: linear-gradient(90deg, var(--purple), transparent);
}

.nav-items {
    flex: 1;
    padding: 20px 0;
}

.nav-item {
    display: flex;
    align-items: center;
    gap: 12px;
    padding: 15px 20px;
    color: var(--gray);
    font-size: 0.95rem;
    transition: var(--transition);
    border-left: 4px solid transparent;
}

.nav-item:hover,
.nav-item.active {
    background: var(--purple-lighter);
    color: var(--purple);
    border-left-color: var(--purple);
}

.nav-item i {
    font-size: 1.1rem;
    width: 20px;
}

.sidebar-footer {
    padding: 20px;
    border-top: 2px dashed var(--gray);
    text-align: center;
    font-size: 0.85rem;
    color: var(--gray);
}

/* ====== 主内容区 ====== */
.main-content {
    flex: 1;
    margin-left: 200px;
    min-height: 100vh;
}

.section {
    position: relative;
    min-height: 100vh;
    padding: 60px 40px;
}

/* 纸张背景 */
.paper-bg {
    position: absolute;
    inset: 20px;
    background: var(--white);
    border: 2px solid var(--black);
    box-shadow: var(--shadow);
    z-index: 0;
}

.paper-bg::before {
    content: '';
    position: absolute;
    inset: 0;
    background:
        repeating-linear-gradient(
            0deg,
            transparent,
            transparent 28px,
            rgba(0, 0, 0, 0.03) 28px,
            rgba(0, 0, 0, 0.03) 29px
        );
}

.paper-bg::after {
    content: '';
    position: absolute;
    top: -5px;
    left: 20px;
    right: 20px;
    height: 10px;
    background: linear-gradient(90deg,
        transparent 0%, var(--gray-light) 5%, var(--white) 10%,
        transparent 15%, var(--gray-light) 20%, var(--white) 25%,
        transparent 30%, var(--gray-light) 35%, var(--white) 40%,
        transparent 45%, var(--gray-light) 50%, var(--white) 55%
    );
    clip-path: polygon(
        0% 0%, 5% 100%, 10% 0%, 15% 100%, 20% 0%, 25% 100%, 30% 0%, 35% 100%,
        40% 0%, 45% 100%, 50% 0%, 55% 100%, 60% 0%, 65% 100%, 70% 0%, 75% 100%,
        80% 0%, 85% 100%, 90% 0%, 95% 100%, 100% 0%
    );
}

/* ====== 头部 Banner ====== */
.banner-content {
    position: relative;
    z-index: 2;
    display: flex;
    gap: 60px;
    align-items: center;
    padding: 40px;
}

.banner-left {
    flex: 1;
}

.handwriting-title {
    margin-bottom: 25px;
}

.title-greet {
    font-family: 'Ma Shan Zheng', cursive;
    font-size: 1.8rem;
    color: var(--gray);
    display: block;
    margin-bottom: 5px;
}

.title-name {
    font-family: 'ZCOOL KuaiLe', cursive;
    font-size: 5rem;
    color: var(--black);
    line-height: 1;
    letter-spacing: 0.1em;
}

.identity-tags {
    display: flex;
    flex-wrap: wrap;
    gap: 10px;
    margin-bottom: 25px;
}

.tag {
    padding: 8px 16px;
    background: var(--black);
    color: var(--white);
    font-size: 0.9rem;
    font-weight: 500;
}

.slogan {
    font-family: 'Ma Shan Zheng', cursive;
    font-size: 1.2rem;
    color: var(--black);
    margin-bottom: 20px;
    max-width: 400px;
}

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

.hashtags span {
    padding: 6px 12px;
    background: var(--purple-lighter);
    color: var(--purple);
    font-size: 0.85rem;
    border-radius: 20px;
}

.banner-right {
    flex-shrink: 0;
}

.avatar-card {
    position: relative;
    padding: 15px;
    background: var(--white);
    border: 2px solid var(--black);
    transform: rotate(3deg);
}

.avatar-photo {
    width: 280px;
    height: 350px;
    object-fit: cover;
    border: 1px solid var(--gray);
}

.avatar-quote {
    position: absolute;
    bottom: -15px;
    right: -20px;
    background: var(--purple);
    color: var(--white);
    padding: 10px 20px;
    font-family: 'Ma Shan Zheng', cursive;
    font-size: 1rem;
    transform: rotate(-5deg);
    box-shadow: 3px 3px 0 var(--black);
}

/* 装饰元素 */
.deco-elements {
    position: absolute;
    inset: 0;
    z-index: 1;
    pointer-events: none;
}

.deco-star {
    position: absolute;
    color: var(--purple);
    font-size: 1.5rem;
    animation: twinkle 2s infinite;
}

.deco-star:nth-child(1) { top: 15%; left: 30%; animation-delay: 0s; }
.deco-star:nth-child(2) { top: 25%; right: 25%; animation-delay: 0.5s; }

.deco-crown {
    position: absolute;
    color: var(--purple-light);
    font-size: 2rem;
    top: 10%;
    right: 35%;
}

.deco-line {
    position: absolute;
    width: 60px;
    height: 3px;
    background: var(--purple);
}

.deco-line:nth-child(4) { bottom: 20%; left: 25%; transform: rotate(-15deg); }
.deco-line:nth-child(5) { bottom: 25%; right: 20%; transform: rotate(10deg); }

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

/* ====== 区块标题 ====== */
.section-header {
    position: relative;
    z-index: 2;
    display: flex;
    align-items: center;
    gap: 15px;
    margin-bottom: 30px;
    padding-left: 40px;
}

.section-header i {
    font-size: 1.8rem;
    color: var(--purple);
}

.section-header h2 {
    font-family: 'ZCOOL KuaiLe', cursive;
    font-size: 2rem;
    color: var(--black);
}

/* ====== 内容卡片 ====== */
.card {
    position: relative;
    z-index: 2;
    background: var(--white);
    border: 2px solid var(--black);
    padding: 30px;
    margin: 0 40px 30px;
    box-shadow: 5px 5px 0 var(--black);
}

.card-content {
    display: flex;
    flex-direction: column;
    gap: 20px;
}

.card-intro {
    font-size: 1rem;
    color: var(--black);
    line-height: 1.8;
}

.card-images {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 15px;
}

.card-images img {
    width: 100%;
    height: 200px;
    object-fit: cover;
    border: 2px solid var(--black);
}

.card-quote {
    font-family: 'Ma Shan Zheng', cursive;
    font-size: 1.1rem;
    color: var(--purple);
    padding: 15px;
    background: var(--purple-lighter);
    border-left: 4px solid var(--purple);
}

.ae-preview {
    display: flex;
    justify-content: center;
}

.ae-preview img {
    max-height: 200px;
    border: 2px solid var(--black);
}

.skill-checklist {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 12px;
}

.check-item {
    display: flex;
    align-items: center;
    gap: 8px;
    padding: 10px 15px;
    background: var(--gray-light);
    font-size: 0.95rem;
}

.check-item i {
    color: var(--purple);
}

.props-preview img {
    max-height: 250px;
    margin: 0 auto;
    border: 2px solid var(--black);
}

/* ====== 联系卡片 ====== */
.contact-card {
    position: relative;
    z-index: 2;
    background: var(--white);
    border: 2px solid var(--black);
    padding: 30px 40px;
    margin: 0 40px 30px;
    display: inline-block;
}

.contact-item {
    display: flex;
    align-items: center;
    gap: 15px;
    font-size: 1.1rem;
}

.contact-item i {
    color: var(--purple);
    font-size: 1.3rem;
}

.handwriting-quote {
    position: relative;
    z-index: 2;
    font-family: 'Ma Shan Zheng', cursive;
    font-size: 2rem;
    color: var(--purple);
    text-align: center;
    margin-top: 20px;
}

/* ====== 页脚 ====== */
.footer {
    background: var(--black);
    color: var(--white);
    padding: 30px 40px;
    margin-left: 200px;
    text-align: center;
}

.footer-copy {
    font-size: 0.9rem;
    margin-bottom: 10px;
}

.tech-support {
    font-size: 0.85rem;
    color: var(--gray);
}

.tech-support a {
    color: var(--purple-light);
    transition: color 0.3s;
}

.tech-support a:hover {
    color: var(--purple);
}

/* ====== 响应式 ====== */
@media (max-width: 992px) {
    .sidebar {
        width: 160px;
    }
    .main-content {
        margin-left: 160px;
    }
    .footer {
        margin-left: 160px;
    }
    .banner-content {
        flex-direction: column;
        text-align: center;
    }
    .title-name {
        font-size: 4rem;
    }
    .avatar-photo {
        width: 220px;
        height: 280px;
    }
}

@media (max-width: 768px) {
    .sidebar {
        width: 60px;
        padding-top: 20px;
    }
    .sidebar-header, .sidebar-footer {
        display: none;
    }
    .nav-item span {
        display: none;
    }
    .nav-item {
        justify-content: center;
        padding: 15px;
    }
    .main-content {
        margin-left: 60px;
    }
    .footer {
        margin-left: 60px;
    }
    .section {
        padding: 40px 20px;
    }
    .banner-content {
        padding: 20px;
    }
    .title-name {
        font-size: 3rem;
    }
    .card {
        margin: 0 20px 20px;
        padding: 20px;
    }
    .card-images {
        grid-template-columns: 1fr;
    }
    .skill-checklist {
        grid-template-columns: 1fr;
    }
}

/* ====== 滚动条 ====== */
::-webkit-scrollbar { width: 8px; }
::-webkit-scrollbar-track { background: var(--gray-light); }
::-webkit-scrollbar-thumb {
    background: var(--purple-light);
    border-radius: 4px;
}
::-webkit-scrollbar-thumb:hover { background: var(--purple); }
