/* General Body and Root Variables */
:root {
    --bg-color: #0A0F1E;
    --card-bg-color: #1A1A1D;
    --text-color: #BDBDBD;
    --heading-color: #F0F0F0;
    --accent-gradient: linear-gradient(90deg, #8A78F5, #E882A4);
    --border-color: rgba(255, 255, 255, 0.1);
    --font-main: 'Inter', sans-serif;
    --font-heading: 'Manrope', sans-serif;
}

@import url('https://fonts.googleapis.com/css2?family=Inter:wght@400;600&family=Manrope:wght@700&display=swap');

body {
    background-color: var(--bg-color);
    color: var(--text-color);
    font-family: var(--font-main);
    margin: 0;
    line-height: 1.7;
    overflow-x: hidden;
    padding-top: 8rem; /* 为固定页眉留出空间 */
}

/* Background Canvas */
#snake-bg-canvas {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    z-index: -1;
    opacity: 0.5; /* Make it more of an ambient background */
}

/* Layout */
.container {
    max-width: 1200px;
    margin: 0 auto;
    padding: 0 2rem;
    display: flex;
    flex-direction: column;
    min-height: 100vh;
    position: relative;
    overflow: hidden;
}

/* Header */
header {
    position: fixed;
    top: 0;
    left: 0;
    right: 0;
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 1.5rem 2rem;
    background: rgba(10, 15, 30, 0.5);
    backdrop-filter: blur(10px);
    -webkit-backdrop-filter: blur(10px);
    border-bottom: 1px solid var(--border-color);
    z-index: 100;
    transition: background 0.3s ease;
}

.logo h1 {
    margin: 0;
    font-family: var(--font-heading);
    font-size: 1.5rem;
}

.logo h1 a {
    color: var(--heading-color);
    text-decoration: none;
}

.logo p {
    margin: 0;
    font-size: 0.8rem;
    color: var(--text-color);
}

nav ul {
    list-style: none;
    margin: 0;
    padding: 0;
    display: flex;
    gap: 2rem;
}

nav a {
    color: var(--text-color);
    text-decoration: none;
    font-size: 1rem;
    position: relative;
    padding-bottom: 5px;
    transition: color 0.3s ease;
}

nav a::after {
    content: '';
    position: absolute;
    bottom: 0;
    left: 0;
    width: 0;
    height: 2px;
    background: var(--accent-gradient);
    transition: width 0.3s ease;
}

nav a:hover {
    color: var(--heading-color);
}

nav a:hover::after {
    width: 100%;
}

/* Hero Section */
.hero-section {
    text-align: center;
    padding: 4rem 0 8rem;
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
}

.hero-image,
.featured-image {
    width: 100%;
    max-height: 400px;
    object-fit: cover;
    border-radius: 16px;
    margin-bottom: 2rem;
}

.hero-section h1 {
    margin-top: 0.5rem;
    margin-bottom: 1.2rem;
    font-family: var(--font-heading);
    font-size: 4rem;
    color: var(--heading-color);
}

.hero-section p {
    margin-bottom: 2.2rem;
    font-size: 1.25rem;
    max-width: 600px;
}

.cta-button {
    margin-top: 2rem;
    margin-bottom: 2.5rem;
    background: var(--accent-gradient);
    color: white;
    padding: 1rem 2.5rem;
    border-radius: 50px;
    text-decoration: none;
    font-weight: 600;
    box-shadow: 0 6px 24px 0 #8A78F533;
    transition: transform 0.3s, box-shadow 0.3s;
    display: inline-block;
}

.cta-button:hover {
    transform: translateY(-3px) scale(1.04);
    box-shadow: 0 10px 32px rgba(138, 120, 245, 0.25);
}

/* Main Content */
main {
    display: grid;
    grid-template-columns: 1fr 300px;
    gap: 2rem;
    flex-grow: 1;
}

.page-title {
    font-family: var(--font-heading);
    font-size: 2.5rem;
    color: var(--heading-color);
    margin-bottom: 2rem;
    border-bottom: 1px solid var(--border-color);
    padding-bottom: 1rem;
}

/* Milestone Cards */
.milestone-preview {
    display: grid;
    grid-template-columns: 250px 1fr;
    gap: 2rem;
    background: var(--card-bg-color);
    border: 1px solid var(--border-color);
    border-radius: 16px;
    padding: 2rem;
    margin-bottom: 2rem;
    transition: transform 0.3s ease, border-color 0.3s ease;
    overflow: hidden;
}

.milestone-thumbnail {
    width: 100%;
    height: 100%;
    object-fit: cover;
    border-radius: 8px;
}

.milestone-preview:hover {
    transform: translateY(-5px);
    border-color: #8A78F5;
}

.milestone-content-preview h3 {
    margin: 0 0 0.5rem;
    font-family: var(--font-heading);
    font-size: 1.5rem;
}

.milestone-content-preview h3 a {
    color: var(--heading-color);
    text-decoration: none;
}

.milestone-meta {
    font-size: 0.9rem;
    color: var(--text-color);
    margin-bottom: 1rem;
}

.milestone-excerpt {
    margin-bottom: 1.5rem;
}

.details-link {
    color: #8A78F5;
    text-decoration: none;
    font-weight: 600;
    transition: color 0.3s ease;
}

.details-link:hover {
    color: #E882A4;
}

/* Sidebar */
.sidebar .widget {
    background: var(--card-bg-color);
    border: 1px solid var(--border-color);
    border-radius: 16px;
    padding: 1.5rem;
    margin-bottom: 2rem;
}

.sidebar h4 {
    font-family: var(--font-heading);
    color: var(--heading-color);
    font-size: 1.2rem;
    margin-top: 0;
    margin-bottom: 1rem;
}

/* Gallery Page Specifics */
.gallery-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(300px, 1fr));
    gap: 1.5rem;
}

.gallery-item img {
    width: 100%;
    height: 250px;
    object-fit: cover;
    border-radius: 8px;
    transition: transform 0.3s ease;
}

.gallery-item:hover img {
    transform: scale(1.05);
}

.gallery-item-caption {
    margin-top: 0.5rem;
    text-align: center;
}

/* Our People Page Specifics */
.people-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(250px, 1fr));
    gap: 2rem;
}

.person-profile {
    text-align: center;
}

.person-profile img {
    width: 120px;
    height: 120px;
    border-radius: 50%;
    object-fit: cover;
    margin: 0 auto 1rem;
    border: 3px solid var(--border-color);
}

.person-profile h4 {
    margin: 0.5rem 0;
    color: var(--heading-color);
}

.person-profile .role {
    font-size: 0.9rem;
    color: #8A78F5;
    margin-bottom: 0.5rem;
}

.sidebar ul {
    list-style: none;
    padding: 0;
    margin: 0;
}

.sidebar ul li a {
    color: var(--text-color);
    text-decoration: none;
    display: block;
    padding: 0.5rem 0;
    transition: color 0.3s ease;
}

.sidebar ul li a:hover {
    color: var(--heading-color);
}

.timeline-event {
    display: grid;
    grid-template-columns: 200px 1fr;
    gap: 2rem;
    align-items: center;
}

.timeline-image {
    width: 100%;
    height: 100%;
    object-fit: cover;
    border-radius: 8px;
}

.themes-keywords a {
    display: inline-block;
    background: rgba(255, 255, 255, 0.05);
    color: var(--text-color);
    padding: 0.3rem 0.8rem;
    border-radius: 8px;
    margin: 0.2rem;
    text-decoration: none;
    font-size: 0.9rem;
    transition: background 0.3s ease, color 0.3s ease;
}

.themes-keywords a:hover {
    background: var(--accent-gradient);
    color: white;
}

/* Footer */
footer {
    text-align: center;
    padding: 3rem 0;
    margin-top: 4rem;
    border-top: 1px solid var(--border-color);
    color: var(--text-color);
}

/* Music Player - Placeholder for future styling */
#music-player-container {
    position: fixed;
    bottom: 2rem;
    right: 2rem;
    /* Further styling will be based on the prompt */
}

/* Theme Toggle Button - Hiding for now as the theme is dark by default */
#theme-toggle {
    display: none;
}

/* Responsive */
@media (max-width: 992px) {
    main {
        grid-template-columns: 1fr;
    }
}

@media (max-width: 768px) {
    .hero-section h1 {
        font-size: 3rem;
    }
    header {
        flex-direction: column;
        gap: 1rem;
    }
}
.container::before,
.container::after {
    content: '';
    position: absolute;
    border-radius: 50%;
    border: 1px solid rgba(64, 86, 161, 0.2);
    z-index: -1;
}

.container::before {
    width: 400px;
    height: 400px;
    top: 15%;
    right: -150px;
}

.container::after {
    width: 600px;
    height: 600px;
    bottom: -250px;
    left: -200px;
}
@keyframes note-fade-in {
    from {
        opacity: 0;
        transform: translateY(20px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

.note {
    animation: note-fade-in 0.5s ease-out forwards;
    opacity: 0;
}

.note:nth-child(1) { animation-delay: 0.1s; }
.note:nth-child(2) { animation-delay: 0.2s; }
.note:nth-child(3) { animation-delay: 0.3s; }
.note:nth-child(4) { animation-delay: 0.4s; }
.note:nth-child(5) { animation-delay: 0.5s; }
.note:nth-child(6) { animation-delay: 0.6s; }
.note:nth-child(7) { animation-delay: 0.7s; }
.note:nth-child(8) { animation-delay: 0.8s; }
.note:nth-child(9) { animation-delay: 0.9s; }
.note:nth-child(10) { animation-delay: 1.0s; }
.note:nth-child(11) { animation-delay: 1.1s; }
.note:nth-child(12) { animation-delay: 1.2s; }
.note:nth-child(13) { animation-delay: 1.3s; }
.note:nth-child(14) { animation-delay: 1.4s; }
.note:nth-child(15) { animation-delay: 1.5s; }
 
/* 竖向时间轴样式 */
.timeline-container {
    position: relative;
    padding-left: 50px;
    margin: 2rem 0;
}

.timeline-container::before {
    content: '';
    position: absolute;
    left: 20px;
    top: 0;
    bottom: 0;
    width: 2px;
    background: var(--accent-gradient);
}

.timeline-event {
    position: relative;
    padding: 1.5rem 0;
    margin-bottom: 1rem;
}

.timeline-event::before {
    content: '';
    position: absolute;
    left: -30px;
    top: 50%;
    transform: translateY(-50%);
    width: 12px;
    height: 12px;
    border-radius: 50%;
    background: var(--accent-gradient);
    border: 2px solid var(--bg-color);
}

.timeline-date {
    font-weight: bold;
    color: var(--heading-color);
    margin-bottom: 0.5rem;
}

.timeline-event h4 {
    margin: 0.5rem 0;
    color: var(--heading-color);
}

.timeline-event p {
    margin: 0.5rem 0 1rem;
}

/* 团队成员关系网SVG美化 */
#team-network svg {
  background: transparent;
  border-radius: 18px;
  box-shadow: 0 6px 32px 0 #1976d233 inset;
  backdrop-filter: blur(2.5px);
}
#team-network circle {
  transition: filter 0.2s, stroke 0.2s, fill 0.2s;
  filter: drop-shadow(0 2px 8px #1976d255);
}
#team-network circle:hover {
  stroke: #ff9800;
  filter: drop-shadow(0 0 16px #ff9800cc);
  fill: #ffe0b2 !important;
}
#team-network text {
  font-family: 'HarmonyOS Sans', '微软雅黑', 'Arial', sans-serif;
  font-weight: bold;
  letter-spacing: 1px;
  user-select: none;
}
#team-network line {
  transition: stroke 0.2s;
}

@font-face {
  font-family: 'ZCOOL KuaiLe';
  src: url('https://fonts.gstatic.com/s/zcoolkuaile/v18/2Eb5L_R5IXJEWhD3AOhSvFC554A.woff2') format('woff2');
  font-display: swap;
}

.video-crossfade {
  position: relative;
  width: 100%;
  max-width: 900px;
  margin: 0 auto 2.5rem auto;
  height: 320px; /* 固定高度，保证视频区域和下方按钮分离 */
  min-height: unset;
  display: flex;
  align-items: center;
  justify-content: center;
  margin-bottom: 2.5rem;
}

.hero-video {
  position: absolute;
  top: 0; left: 0; width: 100%; height: 100%;
  object-fit: cover;
  border-radius: 16px;
  background: #000;
  transition: opacity 0.8s;
  opacity: 1;
  pointer-events: none;
  min-height: unset;
}

.hero-video.fade {
  opacity: 0;
}