/* Reset & Base */
* {
    box-sizing: border-box;
    margin: 0;
    padding: 0;
}

body {
    font-family: "Noto Sans TC", sans-serif;
    background-color: #FAFAFA;
    color: #333;
    line-height: 1.7;
    /* 增加行高 */
}

/* Detail Page Containers */
.detail-container {
    max-width: 1000px;
    /* 放大主內容區塊寬度 */
    margin: auto;
    padding: 2.5rem 2rem;
    /* 放大內邊距 */
}

/* Section Title */
.section-title {
    text-align: center;
    color: #F57C00;
    font-size: 2.5rem;
    /* 放大標題 */
    margin-bottom: 3rem;
}

/* Timeline Layout */
.timeline-line-wrapper {
    position: relative;
    padding-left: 40px;
    /* 放大行線間距 */
    border-left: 4px solid #F57C00;
    margin-left: 15px;
}

/* Timeline Entry */
.timeline-entry {
    position: relative;
    margin-bottom: 4rem;
    /* 放大區塊間距 */
    background: linear-gradient(to right, #fff3e0, #ffe0b2);
    border-radius: 15px;
    box-shadow: 0 4px 10px rgba(0, 0, 0, 0.1);
    transition: transform 0.3s ease, box-shadow 0.3s ease;
    padding: 2rem;
    /* 放大內邊距 */
}

.timeline-entry:hover {
    transform: translateY(-5px);
    box-shadow: 0 6px 15px rgba(0, 0, 0, 0.15);
}

.timeline-entry::before {
    content: '';
    position: absolute;
    left: -19px;
    top: 1.5rem;
    width: 18px;
    /* 放大圓點 */
    height: 18px;
    background-color: #F57C00;
    border-radius: 50%;
    box-shadow: 0 0 0 5px #fff3e0;
}

/* Year Badge */
.year-badge {
    position: absolute;
    left: -75px;
    top: 1.3rem;
    background-color: #F57C00;
    color: white;
    padding: 5px 12px;
    font-size: 1rem;
    /* 放大文字 */
    border-radius: 6px;
    font-weight: bold;
    white-space: nowrap;
}

/* Text Styles */
.timeline-entry h2 {
    margin-bottom: 0.6rem;
    color: #BF360C;
    font-size: 1.5rem;
    /* 放大標題 */
}

.timeline-entry p {
    font-size: 1.15rem;
    /* 放大內文 */
    line-height: 1.7;
}

/* Entry Toggle */
.entry-toggle {
    display: flex;
    align-items: center;
    gap: 1.5rem;
    cursor: pointer;
}

.entry-toggle::after {
    content: "▾";
    font-size: 1.4rem;
    transition: transform 0.3s ease;
    margin-left: auto;
    color: #F57C00;
}

.timeline-entry.active .entry-toggle::after {
    transform: rotate(180deg);
}

/* Entry Detail (主內容區塊) */
.entry-detail {
    display: none;
    padding: 0;
    margin-top: 0;
    background: linear-gradient(135deg, #fff3e0 0%, #ffe0b2 100%);
    border-radius: 15px;
    box-shadow: 0 4px 10px rgba(0, 0, 0, 0.08);
}

.entry-detail.show {
    display: block;
    padding: 2rem;
    /* 放大內邊距 */
    margin-top: 1.5rem;
}

/* --- 照片大小與置中修正 --- */
.entry-detail .main-image {
    max-width: 100%;
    height: auto;
    border-radius: 10px;
    margin-top: 1.5rem;
    display: block;
    margin-left: auto;
    margin-right: auto;
}

/* 確保圖片註解在圖片下方且居中 */
.image-caption {
    font-size: 1.05rem;
    /* 放大註解文字 */
    color: #555;
    text-align: center;
    margin-top: 0.8rem;
    margin-bottom: 2rem;
    background-color: transparent;
    padding: 0;
}

/* --- 公文照片區塊 --- */
.official-docs-toggle {
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: 12px 18px;
    /* 放大內邊距 */
    background-color: #f0f0f0;
    border-radius: 10px;
    margin-top: 2rem;
    cursor: pointer;
    transition: background-color 0.3s ease;
}

.official-docs-toggle:hover {
    background-color: #e0e0e0;
}

.docs-toggle-text {
    font-weight: bold;
    font-size: 1.1rem;
    color: #333;
}

.docs-toggle-icon {
    font-size: 1.4rem;
    color: #666;
    transition: transform 0.3s ease;
}

.official-docs-content {
    display: none;
    padding: 0;
    border-left: 3px solid #ccc;
    margin-top: 0.8rem;
    text-align: center;
}

.official-docs-content.show {
    display: block;
    padding: 20px;
    /* 放大內邊距 */
}

.official-docs-content img {
    max-width: 95%;
    height: auto;
    border-radius: 6px;
    margin-bottom: 1.5rem;
    display: block;
    margin-left: auto;
    margin-right: auto;
    box-shadow: 0 2px 5px rgba(0, 0, 0, 0.1);
}

.official-docs-content img:not(:last-child) {
    margin-bottom: 1.5rem;
}

.doc-item {
    min-height: 0;
    overflow: hidden;
}

/* 響應式調整 */
@media (max-width: 1024px) {
    .detail-container {
        max-width: 90%;
    }
}

@media (max-width: 768px) {
    .timeline-line-wrapper {
        padding-left: 25px;
        border-left-width: 4px;
    }

    .timeline-entry::before {
        left: -14px;
        width: 14px;
        height: 14px;
    }

    .year-badge {
        left: -58px;
        font-size: 0.9rem;
    }

    .timeline-entry {
        padding: 1.5rem;
    }

    .timeline-entry p {
        font-size: 1.1rem;
    }
}