body {
    font-family: Arial, sans-serif;
    line-height: 1.6;
    margin: 0;
    padding: 0;
    background-color: #f4f4f4;
}

header {
    background: #50b3a2;
    color: white;
    padding: 10px 0;
    text-align: center;
}

nav ul {
    list-style: none;
    background: #333;
    text-align: center;
    padding: 0;
    margin: 0;
}

nav ul li {
    display: inline;
}

nav ul li a {
    color: white;
    padding: 5px 20px;
    text-decoration: none;
}

section {
    padding: 20px;
    margin: 10px;
}

footer {
    text-align: center;
    padding: 10px;
    background: #333;
    color: white;
}

.project {
    margin-bottom: 20px;
}

.project .description {
    margin-bottom: 10px;
}

.project .media {
    display: flex; 
    justify-content: space-around; 
    align-items: center; 
}

.project .media img,
.project .media video {
    max-width: 48%; 
    height: auto; 
    width: auto;
    max-height: 200px;
}

.hidden-display {
    display: none;
}

.hidden-visibility {
    visibility: hidden;
}

.container {
    display: flex;
    margin-top: 20px; 
    justify-content: center;
}

#sidebar {
    position: sticky; 
    top: 0;
    width: 236px;
    height: calc(100vh - 60px); 
    background-color: #f4f4f4;
    padding: 20px;
    box-shadow: 2px 0 5px rgba(0,0,0,0.1);
    overflow-y: auto; 
}

#main-content {
    margin-left: 60px; 
    padding: 20px;
    max-width: 1000px; 
    flex: 1;
    overflow-y: auto; 
}

.profile-photo {
    width: 100px; 
    height: 100px;
    border-radius: 50%; /* Circular photo */
    margin-bottom: 20px;
}

#contact {
    background-color: #ddd;
    padding: 15px;
    margin-bottom: 10px;
}

.input-group {
    display: flex;
    flex-direction: column;
    align-items: flex-start;
    margin-bottom: 10px;
}

.input-group label {
    margin-bottom: 5px;
}

.input-group input {
    width: 100%; 
    max-width: 200px; 
}

.input-group textarea {
    width: 100%; 
    max-width: 500px; 
    height: 120px; 
}

textarea {
    width: 100%; 
    height: 120px; 
}

.name {
    display: inline-block;
    position: relative;
    /* font-size: 20px; */
    /* font-weight: bold; */
    transition: transform 0.3s;
    background-image: linear-gradient(to right, red, orange, yellow, green, blue, indigo, violet);
    background-clip: text;
    -webkit-background-clip: text;
    color: transparent;
    -webkit-text-fill-color: transparent;
    background-size: 200% 200%;
    animation: rainbow 5s ease-in-out infinite;
  }
  
  .name:hover {
    transform: scale(1.1);
  }
  
  .name::before {
    content: "方心怡";
    position: absolute;
    top: 0;
    left: 50%;
    transform: translateX(-50%);
    opacity: 0;
    transition: opacity 0.3s;
    background-image: linear-gradient(to right, red, orange, yellow, green, blue, indigo, violet);
    background-clip: text;
    -webkit-background-clip: text;
    color: transparent;
    -webkit-text-fill-color: transparent;
    background-size: 200% 200%;
    animation: rainbow 5s ease-in-out infinite;
    /* font-size: 0.8em; */
    white-space: nowrap;
    font-family: "NSimSun", "KaiTi", serif;
  }

  .name:hover::before {
    opacity: 1;
  }
  
  .name span {
    display: inline-block;
    transition: transform 0.3s;
  }
  
  .name:hover span {
    transform: translateY(-100%);
  }

  @keyframes rainbow {
    0% {
      background-position: 0% 50%;
    }
    50% {
      background-position: 100% 50%;
    }
    100% {
      background-position: 0% 50%;
    }
  }

.icon-links {
    display: flex;
    justify-content: left;
    gap: 15px;
    margin-top: 10px;
}
.icon-links a {
    text-decoration: none;
}
.icon-links img {
    width: 20px;
    height: 20px;
}
