body {
    font-family: Arial, sans-serif;
    margin: 0;
    padding: 0;
    background-color: #f4f4f4;
    position: relative;
    background-image: url("./images/GPh3Ib6aoAAXxwN.jfif"); /* 替換成你的圖片 */
    background-size: cover;
    background-position: center;
    background-repeat: no-repeat;
    background-attachment: fixed;
}
body::before {
    content: "";
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background-color: rgba(0, 0, 0, 0.3); /* 黑色遮罩，數值越大越暗 */
    z-index: -1; /* 確保遮罩不會覆蓋網頁內容 */
}
header {
    background: rgba(0, 0, 0, 0.6); /* 黑色半透明 */
    color: white;
    padding: 15px;
    text-align: center;
}

nav ul {
    list-style: none;
    padding: 0;
}

nav ul li {
    display: inline;
    margin: 0 15px;
}

nav ul li a {
    color: white;
    text-decoration: none;
    font-size: 18px;
}

section {
    background: rgba(255, 255, 255, 0.8); /* 白色半透明 */
    padding: 20px;
    margin: 20px auto;
    width: 80%;
    border-radius: 10px;
    box-shadow: 0 0 10px rgba(0, 0, 0, 0.1);
    display: none; /* 預設隱藏所有 section */
    opacity: 0;
    transition: opacity 0.5s ease-in-out;
}
section.active {
    display: block; /* 只顯示被點擊的 section */
    opacity: 1;
}

.media-container {
    display: flex;
    justify-content: space-around; /* 讓圖片與影片維持原本的左右排列 */
    align-items: center;
    flex-wrap: wrap; /* 當螢幕太小時，讓內容換行 */
}

.media-item {
    text-align: center; /* 讓標題置中 */
    width: 45%; /* 控制每個項目的寬度 */
}
.media-item p {
    font-weight: bold;
    font-size: 20px;
}
#contact {
    display: block; /* 永遠顯示聯絡方式 */
    opacity: 1;
}
#about {
    display: block; /* 永遠顯示關於我 */
    opacity: 1;
}
