/* style.css */

/* 1. 全域設定 */

:root {
    /* 顏色 1: 深炭灰 (主要內文、次要元素) */
    --color-primary: #3B3535;
        
    /* 顏色 2: 純黑 (強調標題、深色背景區塊) */
    --color-black: #000000;

    /* 顏色 3: 純白 (網頁背景、反白文字) */
    --color-white: #FFFFFF;

    /* 顏色 4: 灰 (nav hover, active) */
    --color-grey: #919191;
}

body, html {
    margin: 0;
    padding: 0;
    width: 100%;
    height: 100%;
    font-family: 'Be Vietnam Pro', sans-serif;
    
    background-color: var(--color-white); 
    color: var(--color-primary);            
    overflow: hidden;
}
#goBackTOP{
	position:fixed;
	bottom:3vw;
	right:3vw;
	width:3vw;
    height:auto;
    aspect-ratio: 1/1;
	background-color:transparent;
	border:none;
	z-index:1000;
    cursor:pointer;
}
#goBackTOP img{    
	height:100%;
	width:100%;
}

/* 滾動容器 */
.snap-container {
    width: 100%;
    height: 90vh;
    overflow-y: scroll;
    /* scroll-snap-type: y mandatory;*/
    scroll-behavior: smooth;
    margin-top: 10vh;
}

/* Block 設定 */
.block {
    position: relative;
    width: 100%;
    height:fit-content;
    min-height: 70vh;

    padding-top: 5vh;
    padding-bottom: 5vh;
    scroll-margin-top: 10vh;

    display: flex;
    justify-content: flex-start; 
    align-items: center;
    overflow: hidden;
    border-bottom: 1px solid var(--color-white); 
    box-sizing: border-box;
}

/* ===========================
   文字內容
   =========================== */
.content {    
    position: relative;
    z-index: 10;
    text-align: left;
    padding-left: 10%;
}

.content h2 {
    font-size: 71px;
    font-weight: 800; 
    
    margin: 0;
    text-transform: uppercase;
    line-height: 1.1;
    max-width: 70%;
}

.content h3 {
    font-size: 24px;
    font-weight: 600; 
    padding-left: 5em;
    
    margin-top: 20px;
    text-transform: uppercase;
    line-height: 1;
}

.content p {
    font-size: 18px;
    margin-top: 20px;
    margin-bottom: 0px;
    margin-left: 0;
    padding-left: 6.5em;
    border: none;
    max-width:60%;
}

/* ===========================
   按鈕樣式
   =========================== */
.btn {
    display: inline-block;
    text-align: left;
    padding: 0.5em 0.5em;
    border: 1px solid rgba(0,0,0,1); 
    border-radius: 8px;
    text-decoration: none;
    letter-spacing: 2px;
    font-size: 0.9rem;
    background: var(--color-primary);
    transition: background 0.3s, color 0.3s, border 0.3s; 

    color: var(--color-white);       
}

.btn:hover {
    background: var(--color-white);
    color: var(--color-primary); 
    border-color: var(--color-primary);
    cursor: pointer;
}


.doc {
    background: transparent;
    border: 1px solid var(--color-white);
}

/* ===========================
   文字進場動畫 (滑入 + 淡入)
   =========================== */

/* 確保文字預設樣式 (由 JS 控制透明度) */
.content h2,
.content h3,
.content p,
.btn{
    opacity: 0;
    transition: opacity 0.5s ease, transform 0.5s ease;
}

.block.active .content h2,
.block.active .content h3,
.block.active .content p,
.block.active .btn {
    opacity: 1;
    transition: opacity 0.5s ease, transform 0.5s ease;
}

/* ===========================
   拼圖動畫
   =========================== */
.puzzle {
    position: absolute;
    z-index: 1;
    pointer-events: none;
    object-fit: contain;
    
    /* 預設大小，避免過大 */
    width: 200px;
    max-width: 25vw;
    height: auto;

    /* 預設隱藏，等待 Active 後顯示 */
    opacity: 0; 
    
    /* 預設視差變數 */
    --parallax-y: 0px;
    
    /* 預設 transform，包含視差與旋轉 */
    transform: translateY(var(--parallax-y)) rotate(0deg);
    
    transition: opacity 0.8s ease; 
    will-change: transform, opacity;
}

.block.active .puzzle {
    opacity: 1;
}

/* --- 個別拼圖位置設定 (關鍵修復) --- */

/* 左上 */
.p-top-left {
    top: 40%;
    right: 5%;
    left: auto;
    transform: translateY(var(--parallax-y)) rotate(-10deg); 
}

/* 右中 */
.p-mid-right {
    top: 40%;
    right: 5%;
    left: auto;
    width: 250px; /* 這張可以稍微大一點 */
    transform: translateY(var(--parallax-y)) rotate(15deg);
}

/* 左下 */
.p-bot-left {
    bottom: 10%;
    left: 5%;
    right: auto;
    transform: translateY(var(--parallax-y)) rotate(-20deg);
}

/* 右上 */
.p-top-right {
    top: 10%;
    right: 5%;
    left: auto;
    transform: translateY(var(--parallax-y)) rotate(5deg);
}

/* Member 區塊的中間背景大拼圖 */
.p-center-bg {
    top: 50%;
    left: 50%;
    width: 400px;
    max-width: 80vw;
    opacity: 0; /* 預設完全透明 */
    z-index: 0; /* 在最底層 */
    
    /* 這裡使用 translate(-50%, -50%) 來置中，並疊加視差 */
    transform: translate(-50%, -50%) translateY(var(--parallax-y)) scale(0.9);
}

.block.active .p-center-bg {
    opacity: 0.1; /* 進場後只需淡淡顯示 */
    transform: translate(-50%, -50%) translateY(var(--parallax-y)) scale(1);
}

/* ===========================
   頂部導覽列 (Navbar)
   =========================== */
.navbar {
    position: fixed; /* 固定在視窗頂部 */
    top: 0;
    left: 0;
    width: 100%;
    height: 10vh; /* 導覽列高度 */

    display: flex;
    justify-content: space-between; /* 左右推開：Logo左，選單右 */
    align-items: center;
    
    padding: 1vh 5% 1vh 10%; /* 左右留白 */
    box-sizing: border-box;
    z-index: 1000; /* 確保永遠在最上層 */
    background-color: var(--color-white);
}

/* 左側 Logo */
.nav-logo {
    display: flex;
    align-items: center;
    font-weight: 600;
    font-size: 12px;
    letter-spacing: 1px;
}

.nav-logo img {
    height: 60px; /* Logo 圖片高度 */
    width: auto;
    margin-right: 10%;
}

/* 右側連結群組 */
.nav-links {
    display: flex;
    gap: 30px; /*連結之間的間距 */
    align-items: center;
}

/* 連結樣式 */
.nav-links a {
    text-decoration: none;
    color: var(--color-primary); /* 使用主色 */
    font-size: 12px;
    font-weight: 500;
    text-transform: uppercase;
    letter-spacing: 1px;
    transition: color 0.3s;
    position: relative;
}

/* Hover 效果：變黑 */
.nav-links a:hover {
    color: var(--color-grey);
}

/* (選用) Hover 時底部出現小線條 
.nav-links a::after {
    content: '';
    position: absolute;
    width: 0;
    height: 2px;
    bottom: -5px;
    left: 0;
    background-color: var(--color-primary);
    transition: width 0.3s;
}*/

.nav-links a:hover::after {
    width: 100%;
}
/* === Active 狀態  === */
.nav-links a.active {
    color: var(--color-grey);            /* 白字 */
}

#joinBtn{
    color: var(--color-white);
    background-color: var(--color-primary);
    border-radius: 10px;
    text-transform: none;
    padding: 1em
}
#joinBtn:hover{
    color: var(--color-primary);
    background-color: var(--color-white);
}

#about{
    min-height: 75vh;    
    padding-top: 5vh;
    padding-bottom: 0vh;
}

/* ===========================
   Project Leaders Grid
   =========================== */
#member .content {
    max-width: 80%; /* 原本是 60%，改寬一點 */
}

/* 網格容器 */
.leaders-grid {
    display: grid;
    /* 自動排列：每欄最小寬度 300px，空間不夠會自動換行 */
    grid-template-columns: repeat(auto-fit, minmax(300px, 1fr)); 
    gap: 30px; /* 卡片之間的間距 */
    margin-top: 40px;
    width: 100%;
}

/* 個別成員卡片 */
.leader-card {
    display: flex;
    align-items: flex-start; /* 垂直置中 */
    padding: 15px;
    border-radius: 12px;
    transition: transform 0.3s ease;
}

/*.leader-card:hover {
    transform: translateY(-5px); /* 滑鼠移過去微微浮起 *
    background: rgba(245, 245, 245, 0.8);
}
*/

/* 頭像設定 */
.leader-img {
    width: 40%;  /* 頭像寬度 */
    aspect-ratio: 1 / 1;/* 強制長寬比為 1:1 (正方形) */
    object-fit: cover; /* 確保圖片不變形填滿 */
    object-position: top;    /* 對齊頂部 (裁切底部) */
    margin-right: 20px; /* 與右邊文字的距離 */
}

/* 文字區塊 */
.leader-info {
    display: flex;
    flex-direction: column;
    justify-content: center;
    /* margin-top: -5px; */
}

.leader-info h4 {
    font-size: 18px;
    font-weight: 400; 
    margin: 0 0 5px 0;
    text-transform: none; 
}

.leader-info p {
    margin: 0;
    padding: 0;
    border: none;
}

/* ===========================
   Accordion (Collapse)
   =========================== */
#project {   
    /* 確保標題永遠在上面 */
    align-items: flex-start;
    
    padding-bottom: 0px;
}
/* 稍微放寬 Section 5 的內容寬度 */
#project .content {
    width:100%;
    max-width: 100%;

    /* 確保內容區塊佔滿剩餘空間，方便做內部捲動 */
    height: auto; /* calc(100vh - 100px) */
    
    padding-left: 0%;
    padding-bottom: 0px;

    display: flex;
    flex-direction: column; /* 垂直排列：標題在上，列表在下 */
    justify-content: flex-start;

}
#project .content h2{
    padding-left: 10%;
}

.accordion {
    width: 100%;
    margin-top: 20px;   
    /* 移除頂部線條，因為黑色區塊本身就有強烈邊界 */
    border-top: none; 

    /* 讓列表填滿剩餘空間，但若超過則出現捲軸 */
    flex-grow: 1; 
    /*overflow-y: auto;  關鍵：開啟垂直捲動 */
        
    /* 讓捲動行為更平滑 */
    scroll-behavior: smooth;
    
}

/* === 自訂捲軸樣式  === */
/* 1. 捲軸寬度：稍微加寬，讓它更好點擊且更明顯 */
.accordion::-webkit-scrollbar {
    width: 1em;
}

/* 2. 捲軸軌道 (Track)：保持黑色，但可以加一點點深灰區隔 */
.accordion::-webkit-scrollbar-track {
    background: var(--color-primary); /* 比純黑稍微亮一點點的深灰 */
    /* 3B3535*/
}

/* 3. 捲軸本體 (Thumb)：改成淺灰色，在黑色背景上很突出 */
.accordion::-webkit-scrollbar-thumb {
    background: var(--color-white); /* 淺灰色 */
    border-radius: 10px;   /* 圓角 */
    
    /* 加一個黑色邊框，讓捲軸看起來像是懸浮在軌道中間，更有質感 */
    border: 2px solid var(--color-primary); 
}

/* 4. 滑鼠移過時：變更亮 (接近白色) */
.accordion::-webkit-scrollbar-thumb:hover {
    background: var(--color-white); 
}

/* 每個摺疊項目：黑色背景 */
.accordion-item {
    background-color: var(--color-primary); /* 黑色背景 */
    color: var(--color-white);            /* 白色文字 */
    margin-bottom: 0.5em;
    width: 100%;
    scroll-margin-top: 0vh;
}

/* 標題按鈕 */
.accordion-header {
    width: 100%;
    padding-left: 15%;    
    padding-right: 15%;
    padding-top: 0.7em; /* 增加一點高度 */
    padding-bottom: 0.7em; /* 增加一點高度 */
    background: transparent;
    border: none;
    outline: none;
    cursor: pointer;
    
    /* Flexbox 版面設定 */
    display: flex;
    align-items: center;     /* 垂直置中 */
    justify-content: space-between; /* 水平置中 (文字會置中) */
    position: relative;      /* 讓 Icon 可以用絕對定位 */
    
    font-family: 'Be Vietnam Pro', sans-serif;
    font-size: 18px;
    font-weight: 500;
    color: var(--color-white); /* 標題白色 */
    transition: background 0.3s;
}

/* Hover 效果：變成深灰色 
.accordion-header:hover .accordion-item{
    background-color: #222222;
}*/

/* 標題文字 */
.accordion-header span:first-child {
    /* 確保文字在中間，不被 icon 擠壓 */
    text-align: left;
}

/* --- 三角形 Icon 設定 --- */
.accordion-header .icon {
    /* 絕對定位：固定在右側 */
    position: relative;
    right: 0%; 

    /* 使用 CSS border 繪製實心三角形 */
    width: 0;
    height: 0;
    border-top: 6px solid transparent;
    border-bottom: 6px solid transparent;
    border-left: 10px solid var(--color-white); /* 白色向右三角形 */
    
    /* 旋轉動畫 */
    transition: transform 0.3s ease;
    transform-origin: center;
    /* 重置文字內容 (隱藏原本文字) 
    font-size: 0; */
}

/* 隱藏的內容區塊 */
.accordion-body {
    background-color: var(--color-primary); /* 內容也是黑色背景 */
    max-height: 0;
    overflow: hidden;
    transition: max-height 0.4s ease-out;
    padding-left: 15%;
    padding-right: 15%;
}

.accordion-body .inner-text {
    padding: 0 0 0 0; /* 內文邊距 */
    padding-bottom: 0.7em; /* 增加一點高度 */
}


.accordion-body p {
    margin: 0;
    margin-top: 0.5em;
    font-size: 1rem;
    color: var(--color-white); 
    line-height: 1.6;
    text-align: left; /* 內文也跟著置中，若想靠左可改 left */
    padding-left:0;
}
.accordion-body .project-video {
    text-align: center; /* 內文也跟著置中，若想靠左可改 left */
    min-width:100%;
}

.accordion-body .project-bio {
    color: #cccccc; /* 內文用淺灰色，閱讀較舒適 */
    font-style: italic;
}
.accordion-body .Description {
    margin-top: 1em;
    font-style: none;
    text-decoration: underline;
}
/* === 啟動狀態 (Active) === */

/* Icon 旋轉：從向右(0deg) 轉為 向下(90deg) */
.accordion-item.open .accordion-header .icon {
    transform: rotate(90deg);
}

.students-photo{
    display: flex;
    margin-top:2em;
    margin-bottom:2em;
    flex-wrap: wrap;
}
.students-bio{
    display: flex;
    flex-direction: column;
    align-items: stretch;
    gap: 5px;
    margin: auto;
    margin-top: 0;
    width:10vw;
    min-width: 10vw;
}
.students-bio div{
    color: #cccccc;
    font-style: italic;
    width: 100%; /* Or flex-basis: 100%; */
    text-align: left;
    margin:0;
    word-wrap: break-word;
}

.students-bio img{
    width:100%;
    height:auto;
    aspect-ratio: 1 / 1;
    object-fit: cover; /* Scales the image to fill the container and crops the excess */
    object-position: center; /* Centers the image within the container (default behavior) */
}

/* ===========================
   WORKSHOP: Expanding Gallery (Flex Card)
   =========================== */
   #workshop_showcase .content{
        max-width: 80%;
   }
   .gallery-wrap {
        display: flex;
        flex-wrap: wrap; /* 允許換行 */
        justify-content: center; /* 關鍵：內容置中 */
        margin-top: 2em;
        gap: 20px;

        overflow: hidden; /* Hide overflow when collapsed */
        transition: max-height 0.8s ease-in-out; /* Smooth slide effect */
        max-height: 5000px; /* Default expanded state (arbitrary large number) */
    }

    .gallery-wrap.collapsed {
        /* Limit height to show roughly 1 row + half of 2nd row */
        /* Adjust this pixel value if your images are very tall or short */
        max-height: 480px; 
        
        /* Optional: Add a fade-out gradient at the bottom to indicate more content */
        -webkit-mask-image: linear-gradient(to bottom, black 60%, transparent 100%);
        mask-image: linear-gradient(to bottom, black 60%, transparent 100%);
    }
    /* Responsive adjustment for Mobile (Stacking column) */
    @media only screen and (max-width: 800px) {
        .gallery-wrap.collapsed {
            max-height: 500px; /* Shows about 1.5 images on mobile */
        }
    }
    .gallery-item {
        /* 設定卡片寬度：扣掉 gap 之後大約三分之一 */
        width: calc((100% - (20px * 2)) / 3);
        
        position: relative;
        overflow: hidden;
        border-radius: 20px;
    }

.gallery-item img {
    width: 100%;
    height: 100%;
    object-fit: cover; /* 填滿不變形 */
    transition: transform 0.5s ease;
    filter: brightness(1); /* 預設稍微變暗 */
}


.gallery-item:hover img {
    filter: brightness(0.6); /* 變亮 */
    transform: scale(1.05); /* 輕微放大 */
}

/* 圖片說明文字 */
.gallery-caption {
    position: absolute;
    bottom: 20px;
    left: 20px;
    color: white;
    opacity: 0;
    transform: translateY(20px);
    transition: all 0.3s ease;
    transition-delay: 0.1s;
    background: rgba(0,0,0,0); /* 半透明黑底，確保文字可讀 */
    padding: 0px 0px;
}

.gallery-caption h3 {
    margin: 0;
    font-size: 1.2rem;
    font-weight: 700;
    padding-left: 0%;
}

.gallery-caption p {
    margin: 5px 0 0 0;
    font-size: 0.9rem;
    color: #ddd;
}

/* Hover 時顯示文字 */
.gallery-item:hover .gallery-caption {
    opacity: 1;
    transform: translateY(0);
}
#showMoreBtn{
    padding-left: 0em; 
    max-width: 100%; 
    text-align: center; 
    text-decoration: underline; 
    cursor: pointer; 
    display: none;
}

/* ===========================
   SECTION 6: Scatter to Gather (散落 -> 聚合)
   =========================== */

   #photoSection {
    position: relative;
    overflow: hidden; /* 防止圖片飛出區塊 */
    margin-top: 0;
    min-height: 80vh;
}


.scatter-container {
    position: relative;
    width: 100%;
    height: 100%;
    display: flex;
    justify-content: center;
    align-items: center;
}

.scatter-img {
    position: absolute;
    width: 250px;
    height: auto;
    max-width: 30vw;
    border: 5px solid white;
    box-shadow: 0 10px 30px rgba(0,0,0,0.15);
    border-radius: 4px;
    object-fit: cover;
    pointer-events: none; /* 預設不擋滑鼠，等到聚合完成再開啟 */

    /* === 核心變數 === */
    /* --progress 由 JS 控制：0 (散開) -> 1 (聚合) */
    --p: var(--scroll-progress, 0); 

    /* === 核心計算 (線性插值 Linear Interpolation) === */
    /* 公式：Current = Start * (1 - p) + End * p */
    
    transform: 
        translate(
            calc(var(--rand-x) * (1 - var(--p)) + var(--center-offset-x) * var(--p)), 
            calc(var(--rand-y) * (1 - var(--p)) + var(--center-offset-y) * var(--p))
        ) 
        rotate(
            calc(var(--rand-r) * (1 - var(--p)) + var(--final-r) * var(--p))
        );

    /* 透明度：讓它出現得快一點，例如捲動到 50% 時就全顯 */
    opacity: calc(var(--p) * 1.5); 
    
    /* === 關鍵：移除 transition === */
    /* 因為位置是每一幀由捲動直接控制的，不能有延遲 */
    transition: none; 
    
    /* 優化效能 */
    will-change: transform, opacity;
}



/* ===========================
   JOIN US SECTION
   =========================== */
#join_us_section .content{
    width:80%;
}
#join_us_section .content p{
    max-width:100%;
}
/* 內容容器 (雙欄) */
.join-content-wrapper {
    display: flex;
    width:100%;
    margin: 0 auto;
    gap: 8%; /* 左右間距 */
    align-items: center; /* 垂直置中 */
}

/* --- 左側：表單 --- */
.join-left {
    flex: 1; /* 佔據一半空間 */
}

.join-left .join-sub {
    font-size: 1.2rem;
    margin-top: 0px;
    font-weight: 400;
    padding-left:0;
    padding-bottom:0em;
}

/* 輸入框樣式 (底線風格) */
.join-input, .join-textarea {
    width: 100%;
    border: none;
    border-bottom: 2px solid #000; /* 粗黑底線 */
    padding: 1em 0;
    margin-top: 1em;
    margin-bottom: 0em;
    
    font: inherit;
    font-size: 1.1rem;
    background: transparent;
    color: var(--color-primary);
    outline: none;
    border-radius: 0; /* 移除圓角 */
    resize: none; /* 禁止拉動 Textarea */
}
.join-textarea {
    margin-top:0em;
}
.join-input::placeholder {
    color: var(--color-grey);
}

.join-input:focus {
    border-bottom-color: var(--color-grey); /* 聚焦時顏色變化 */
}

/* Checkbox 樣式 */
.checkbox-wrapper {
    display: flex;
    align-items: center;
    gap: 15px;
    padding-top: 2em;
    padding-bottom: 2em;
    border-bottom: 2px solid #000; /* 粗黑底線 */
}

/* 1. 隱藏預設樣式，畫出外框 */
.checkbox-wrapper input[type="checkbox"] {
    /* 隱藏瀏覽器原生樣式 */
    -webkit-appearance: none;
    appearance: none;
    
    /* 自訂外觀 */
    background-color: transparent;
    margin: 0;
    font: inherit;
    color: currentColor;
    width: 24px;
    height: 24px;
    border: 1px solid var(--color-primary);; /* 黑色邊框 */
    border-radius: 4px;     /* 50% = 圓形, 4px = 圓角方形 */
    
    /* 讓勾勾置中 */
    display: grid;
    place-content: center;
    cursor: pointer;
    transition: all 0.2s ease-in-out;
}

/* 2. 當被勾選時 (Checked) -> 變黑底 */
.checkbox-wrapper input[type="checkbox"]:checked {
    background-color: #000;
    border-color: #000;
}

/* 3. 繪製勾勾 (使用 L 型邊框旋轉) */
.checkbox-wrapper input[type="checkbox"]::before {
    content: "";
    width: 10px;  /* 勾勾寬度 */
    height: 4px;  /* 勾勾高度 */
    
    /* 使用邊框畫出 L 形狀 */
    border-left: 2px solid #fff;  /* 白色線條 */
    border-bottom: 2px solid #fff; /* 白色線條 */
    
    /* 旋轉 45 度變成勾勾，並預設縮小 */
    transform: rotate(-45deg) scale(0);
    transform-origin: center;
    transition: 0.2s transform ease-in-out;
}

/* 4. 當被勾選時 -> 顯示勾勾 */
.checkbox-wrapper input[type="checkbox"]:checked::before {
    transform: rotate(-45deg) scale(1);
}

.checkbox-wrapper label {
    font-size: 1.1rem;
    color: var(--color-primary);;
    cursor: pointer;
    
}

.checkbox-wrapper .opt {
    color: #999;
}



form .btn {
    margin-top:1em;
}

/* --- 右側：視覺 --- */
.join-right {
    flex: 1;
    position: relative;
    display: flex;
    justify-content: center;
    align-items: center;
    min-height: 40vh;
}

/* 中央 Logo 區塊 */
.logo-area {
    text-align: center;
    z-index: 2;
}

.main-join-logo {
    width: 100%;
    max-width: 250px; /* 限制 Logo 大小 */
    height: auto;
    object-fit: contain;
}

.logo-text {
    margin-top: 15px;
    font-size: 0.9rem;
    color: #333;
    line-height: 1.4;
}

/* 裝飾用的漂浮拼圖 */
.join-puzzle {
    position: absolute;
    width: 180px;
    opacity: 0.6;
    filter: blur(2px); /* 模糊效果，製造景深 */
    z-index: 1;
    pointer-events: none;
}

.float-top {
    top: 0;
    left: 10%;
    transform: rotate(-15deg);
    /* 簡單的漂浮動畫 */
    animation: float 6s ease-in-out infinite;
}

.float-bottom {
    bottom: 0;
    right: 5%;
    transform: rotate(10deg);
    animation: float 6s ease-in-out infinite reverse;
}

/* 定義漂浮動畫 */
@keyframes float {
    0% { transform: translateY(0px) rotate(-15deg); }
    50% { transform: translateY(-20px) rotate(-10deg); }
    100% { transform: translateY(0px) rotate(-15deg); }
}



/* ===========================
   Tag & Search Filter Styles
   =========================== */

   .filter-container {
    width: 80%; /* 配合 accordion 的寬度 */
    margin: 0 auto 0 auto; /* 上下留白 */
    padding-left: 0;
    display: flex;
    flex-direction: column;
    gap: 15px;
}

/* 1. 搜尋框樣式 */
#searchInput {
    width: 100%;
    padding: 12px 15px;
    font-family: 'Be Vietnam Pro', sans-serif;
    font-size: 16px;
    
    /* 深色主題樣式 */
    background-color: transparent;
    border: 1px solid var(--color-primary); /* 深灰色邊框 */
    color: var(--color-primary);
    border-radius: 8px;
    outline: none;
    transition: all 0.3s ease;
}

#searchInput:focus {
    border-color: var(--color-primary);
    background-color: rgba(0,0,0,0.05); /* 聚焦時稍微變色 */
}

/* 2. 標籤按鈕容器 */
.filter-tags {
    display: flex;
    flex-wrap: wrap;
    gap: 10px;
}

/* 3. 按鈕樣式 */
.filter-btn {
    padding: 8px 16px;
    font-size: 14px;
    font-family: 'Be Vietnam Pro', sans-serif;
    border: 1px solid var(--color-primary);
    background: transparent;
    color: var(--color-primary);
    border-radius: 8px; 
    cursor: pointer;
    transition: all 0.3s ease;
}

.filter-btn:hover {
    background-color: #eee;
}

/* 按鈕被選中時 (Active) */
.filter-btn.active {
    background-color: var(--color-primary);
    color: var(--color-white);
    border-color: var(--color-primary);
}

/* ===========================
   內部標籤 (Inner Tags)
   =========================== */

/* 標籤容器 */
.item-tags-container {
    display: flex;
    flex-wrap: wrap;
    gap: 8px;
    margin-bottom: 15px; 
    
    /* ★★★ 新增這行：讓內容物 (標籤) 水平置中 ★★★ */
    justify-content: center;
}

/* 標籤本體 */
.inner-tag {
    font-size: 12px;
    font-weight: 500;
    font-family: 'Be Vietnam Pro', sans-serif;
    letter-spacing: 0.5px;
    
    background-color: #333; 
    color: #eee;
    
    padding: 4px 12px;
    border-radius: 12px;
    border: 1px solid #444;
    
    cursor: pointer;
    transition: all 0.2s ease;

    /* ★★★ 新增這行：確保標籤內的文字也是置中的 ★★★ */
    text-align: center;
}

/* Hover 效果維持不變 */
.inner-tag:hover {
    background-color: #555;
    border-color: #777;
    color: #fff;
    transform: translateY(-1px);
}