/* ============================================
   Callimont Unified Design System - VER 3.0
   ============================================ */

   :root {
    --callimont-red: #9B170C;
    --heading-color: #836D45;
    --text-color: #464646;
    --light-pink: #F3EDE9; 
    --pinkish-brown: #DBC9BD;
    --white: #ffffff;
}

@font-face {
    font-family: 'Hiragino Sans GB';
    src: url('/assets/fonts/Hiragino Sans GB.ttc');
}

/* 基礎重置 */
* { margin: 0; padding: 0; box-sizing: border-box; border: none; outline: none; text-decoration: none; list-style: none; }
body { font-family: "Hiragino Sans CNS", "Microsoft JhengHei", sans-serif; color: var(--text-color); line-height: 1.8; padding-top: 5.625rem; background: #fff; font-size: 1.1rem; }

/* --- 佈局組件 --- */
.container { max-width: 65.625rem; margin: 0 auto; padding: 0 1.25rem; width: 100%; position: relative; }
.section-padding { padding: 6.25rem 0; }

/* --- 導航欄 --- */
header { 
    position: fixed; top: 0; left: 0; width: 100%; height: 5.625rem;
    background: #fff; display: flex; align-items: center; justify-content: space-between;
    padding: 0 5%; z-index: 1000; box-shadow: 0 0.125rem 0.625rem rgba(0,0,0,0.05); 
}
.logo-container { display: flex; align-items: center; }
.logo-img { height: 3.125rem !important; width: auto; transition: 0.3s; }
.logo-text { 
    margin-left: 0.75rem; font-family: 'Hiragino Sans GB', serif;
    font-size: 1.625rem; color: var(--callimont-red); letter-spacing: 0.0625rem;
    display: flex; align-items: center; line-height: 1;
}

.nav-list { display: flex; align-items: center; }
.nav-list > li { margin-left: 2.5rem; position: relative; }
.nav-list > li > a { color: var(--text-color); font-weight: 500; font-size: 0.9375rem; transition: 0.3s; }
.nav-list > li > a:hover { color: var(--callimont-red); }

.dropdown-arrow {
    display: inline-block;
    width: 0.4375rem;
    height: 0.4375rem;
    border-right: 0.0625rem solid currentColor;
    border-bottom: 0.0625rem solid currentColor;
    transform: rotate(45deg);
    margin-left: 0.5rem;
    margin-bottom: 0.1875rem;
    transition: transform 0.3s ease;
}

.dropdown:hover .dropdown-arrow {
    transform: rotate(-135deg);
    margin-bottom: -0.0625rem;
}

/* 下拉選單修復 */
.dropdown-menu {
    position: absolute; top: 100%; left: 50%; transform: translateX(-50%) translateY(0.625rem);
    background: #fff; box-shadow: 0 0.5rem 1.5625rem rgba(0,0,0,0.1);
    min-width: 10rem; padding: 0.625rem 0; border-radius: 0.25rem;
    opacity: 0; visibility: hidden; transition: 0.3s ease;
}
.dropdown:hover .dropdown-menu { opacity: 1; visibility: visible; transform: translateX(-50%) translateY(0); }
.dropdown-menu li a { display: block; padding: 0.75rem 1.25rem; font-size: 0.875rem; text-align: center; color: var(--text-color); }
.dropdown-menu li a:hover { background: var(--light-pink); color: var(--callimont-red); }

/* 登入按鈕修復 */
.login-nav-btn {
    padding: 0.5rem 1.5625rem; border: 0.1rem solid var(--callimont-red);
    color: var(--callimont-red) !important; font-weight: bold;
    border-radius: 1.25rem; transition: 0.3s; margin-left: 1.875rem;
}
.login-nav-btn:hover { background: var(--callimont-red); color: #fff !important; }

/* 漢堡選單按鈕基礎樣式 (默認隱藏) */
.menu-toggle {
    display: none;
    flex-direction: column;
    justify-content: center;
    align-items: center;
    width: 3rem; /* 48px */
    height: 3rem; /* 48px */
    cursor: pointer;
    z-index: 10001;
    gap: 0.3125rem;
}

.menu-toggle .bar {
    display: block;
    width: 1.75rem; /* 28px actual icon width */
    height: 0.1875rem;
    background-color: var(--text-color);
    border-radius: 0.125rem;
    transition: all 0.3s ease;
}

/* 漢堡按鈕 X 動畫 */
.menu-toggle.is-active .bar:nth-child(1) {
    transform: translateY(0.5rem) rotate(45deg);
}

.menu-toggle.is-active .bar:nth-child(2) {
    opacity: 0;
}

.menu-toggle.is-active .bar:nth-child(3) {
    transform: translateY(-0.5rem) rotate(-45deg);
}

/* 禁止滾動類 */
body.no-scroll {
    overflow: hidden;
}

/* --- 標題規範 --- */
.section-title {
    font-family: 'Hiragino Sans GB', serif; font-size: 3rem;
    color: var(--heading-color); text-align: center; margin-bottom: 2.5rem;
}
.section-title::after { content: ""; display: block; width: 3.125rem; height: 0.125rem; background: var(--callimont-red); margin: 1.25rem auto 0; }

/* --- 首頁 Hero --- */
.hero { 
    position: relative; width: 100%; height: 85vh; 
    background: #000; display: flex; align-items: center; 
    justify-content: center; overflow: hidden; 
}
.hero-video { position: absolute; top: 0; left: 0; width: 100%; height: 100%; object-fit: cover; opacity: 0.7; z-index: 1; }
.hero-content { 
    position: relative; z-index: 10; text-align: center; color: #fff; 
    max-width: 56.25rem; padding: 0 1.25rem;
}
.hero-content h1 { 
    font-family: 'Hiragino Sans GB', serif; 
    font-size: 4rem; 
    margin-bottom: 2.8125rem; 
    letter-spacing: 0.375rem;
    text-shadow: 0 0.125rem 1.25rem rgba(0,0,0,0.5); 
}
.hero-content p { 
    font-size: 1.3rem; 
    margin-bottom: 3.75rem; 
    letter-spacing: 0.125rem;
    opacity: 0.95;
}

/* CTA 按鈕樣式 */
.btn-cta {
    display: inline-block;
    padding: 0.9375rem 2.8125rem;
    background: var(--callimont-red);
    color: #fff;
    font-size: 1.1rem;
    letter-spacing: 0.125rem;
    border-radius: 0.125rem;
    transition: all 0.3s ease;
    box-shadow: 0 0.25rem 0.9375rem rgba(155, 23, 12, 0.3);
}
.btn-cta:hover {
    background: #7a1209;
    transform: translateY(-0.1875rem);
    box-shadow: 0 0.375rem 1.25rem rgba(155, 23, 12, 0.5);
    color: #fff;
}

/* --- 子頁面 Page Header --- */
.page-hero {
    background-color: var(--light-pink);
    padding: 5rem 0;
    text-align: center;
}
.page-hero-content {
    max-width: 71.875rem;
    margin: 0 auto;
    padding: 0 1.25rem;
}
.page-hero-title { 
    font-family: 'Hiragino Sans GB', serif; 
    font-size: 3.2rem; 
    color: var(--heading-color); 
    letter-spacing: 0.25rem; 
    margin: 0;
    line-height: 1.4;
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 0.5rem;
}
.page-hero-title .title-main {
    font-size: 2.4rem;
    letter-spacing: 0.1875rem;
    color: var(--heading-color);
}
.page-hero-title .title-highlight {
    font-size: 3.5rem;
    letter-spacing: 0.375rem;
    color: var(--callimont-red);
    margin: 0.3125rem 0;
}
.page-hero-title .title-sub {
    font-size: 2.4rem;
    letter-spacing: 0.1875rem;
    color: var(--heading-color);
}
.page-hero-title::after { 
    content: ""; 
    display: block; 
    width: 3.75rem; 
    height: 0.125rem; 
    background: var(--callimont-red); 
    margin: 1.5625rem auto 0; 
}
.page-hero-subtitle {
    font-size: 1.2rem;
    color: var(--text-color);
    margin-top: 1.5625rem;
    opacity: 0.85;
    font-weight: 400;
    letter-spacing: 0.0625rem;
}

/* --- 通用卡片 Hover 效果 (修正所有頁面卡片) --- */
.learning-card, .feature-card, .workshop-item {
    background: #fff; padding: 2.8125rem; border-radius: 0.25rem; text-align: center;
    box-shadow: 0 0.3125rem 1.25rem rgba(0,0,0,0.03);
    transition: all 0.4s cubic-bezier(0.165, 0.84, 0.44, 1);
}
.learning-card:hover, .feature-card:hover, .workshop-item:hover {
    transform: translateY(-0.625rem);
    box-shadow: 0 0.9375rem 2.1875rem rgba(0,0,0,0.08);
}

/* --- 特色部分 (Features) --- */
.features {
    padding: 5rem 0;
    background-color: var(--light-pink);
    text-align: center;
}
.features .container {
    max-width: 71.875rem;
    margin: 0 auto;
    padding: 0 1.25rem;
}
.features h2 {
    font-family: 'Hiragino Sans GB', serif;
    font-size: 3rem;
    color: var(--heading-color);
    margin-bottom: 1.5625rem;
    letter-spacing: 0.25rem; 
}
.features-grid {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 2.1875rem;
    margin-top: 3.125rem;
}
.feature-item {
    background: #fff; padding: 2.8125rem; border-radius: 0.25rem; text-align: center;
    box-shadow: 0 0.3125rem 1.25rem rgba(0,0,0,0.03);
    transition: all 0.3s ease;
}
.feature-item:hover {
    transform: translateY(-0.625rem);
    box-shadow: 0 0.9375rem 2.1875rem rgba(0,0,0,0.08);
}
.feature-card {
    background: #fff;
    padding: 2.8125rem 2.1875rem;
    border-radius: 0.5rem;
    text-align: center;
    box-shadow: 0 0.3125rem 1.5625rem rgba(0, 0, 0, 0.05);
    transition: transform 0.3s ease;
}
.feature-card:hover { transform: translateY(-0.3125rem); }
.feature-icon {
    font-size: 2.5rem;
    color: var(--callimont-red);
    margin-bottom: 1.5625rem;
}
.feature-card h3 {
    font-size: 1.4rem;
    color: var(--heading-color);
    margin-bottom: 0.9375rem;
}

/* --- 始創人/導師/書籍 左右佈局修復 --- */

.instructor-profile .instructor-image {
    flex: 0 0 22rem; /* 縮短相框寬度 (原為 30rem) */
    display: flex;
    align-items: stretch;
    overflow: hidden; /* 確保內圖放大後不溢出 */
}

.instructor-profile .instructor-image img,
.calligraphy-img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    box-shadow: 0 1.25rem 2.5rem rgba(0, 0, 0, 0.15);
    border-radius: 0.25rem;
    transform: scale(1.0); /* 放大內圖 (原為 1) */
    transition: transform 0.5s ease;
}

.grid-slideshow {
    box-shadow: 0 0.5rem 1.875rem rgba(0, 0, 0, 0.12);
    border-radius: 0.5rem;
    overflow: hidden;
}

.instructor-profile .instructor-info {
    padding-right: 3.75rem;
}

/* 始創人、導師、中庸格等通用佈局 */
.founder-profile, .instructor-profile {
    display: flex;
    align-items: flex-start;
    gap: 4.375rem;
    margin-bottom: 5rem;
}

.book-item, .contact-wrapper {
    display: flex;
    align-items: stretch;
    justify-content: space-between;
    gap: 4.375rem;
}
.book-item-reverse { flex-direction: row-reverse !important; }
.founder-image, .instructor-image, .book-image { flex: 0 0 25rem; }
.founder-bio, .instructor-info, .book-info { flex: 1; }

.founder-name {
    font-family: 'Hiragino Sans GB', serif;
    font-size: 2.5rem;
    color: var(--heading-color);
    margin-bottom: 0.9375rem;
}

/* 頁面特定的小標誌與間距 */
.page-logo-small {
    width: 13.75rem;
    margin-bottom: 1.875rem;
    display: block;
}

.desc-gap {
    margin-bottom: 3.125rem;
}

.no-shadow-img {
    border: none !important;
    box-shadow: none !important;
}

.founder-tagline {
    font-size: 1.2rem;
    color: var(--callimont-red);
    font-weight: 600;
    margin-bottom: 1.5625rem;
    line-height: 1.6;
}

.founder-description, .founder-description p {
    margin-bottom: 1.25rem;
    text-align: justify;
    line-height: 2;
    font-size: 1.1rem;
}

/* 圖片框架效果 */
.founder-image img, .instructor-image img, .book-image img {
    width: 100%; border: 0.3rem solid #fff; box-shadow: 0 0.9375rem 1.875rem rgba(0,0,0,0.1);
}

/* 書法圖片 - 移除白色邊框 */
.calligraphy-img {
    border: none !important;
    box-shadow: none !important;
}

/* --- 創新板塊 Highlight Card --- */
.innovation-highlight-card {
    margin-top: 4rem;
    background: #fff;
    border-radius: 0.5rem;
    padding: 3.5rem;
    box-shadow: 0 1rem 3rem rgba(0, 0, 0, 0.05);
    border-left: 0.375rem solid var(--callimont-red); /* 左側品牌色裝飾線 */
    position: relative;
    overflow: hidden;
}

.innovation-highlight-card::before {
    content: "";
    position: absolute;
    top: 0;
    right: 0;
    width: 12.5rem;
    height: 12.5rem;
    background: radial-gradient(circle, var(--light-pink) 0%, transparent 70%);
    opacity: 0.5;
    z-index: 0;
}

.innovation-content {
    position: relative;
    z-index: 1;
}

.innovation-highlight-card .founder-name {
    font-size: 2.2rem;
    margin-bottom: 2rem;
    display: flex;
    align-items: center;
    gap: 1rem;
}

.innovation-highlight-card .founder-name::after {
    content: "";
    flex: 1;
    height: 1px;
    background: linear-gradient(to right, var(--pinkish-brown), transparent);
}

.innovation-highlight-card .founder-description p {
    font-size: 1.15rem; /* 稍微放大核心內容字體 */
    color: #333;
    line-height: 2.1;
}
.contact-image-section { flex: 0 0 45%; }
.contact-form-section { flex: 1; }
.contact-image-section img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    display: block;
}
.contact-title {
    font-family: 'Hiragino Sans GB', serif;
    font-size: 3rem;
    color: var(--heading-color);
    margin-bottom: 0.9375rem;
    letter-spacing: 0.25rem;
}
.contact-subtitle {
    font-size: 1rem;
    color: var(--text-color);
    margin-bottom: 3.125rem;
    line-height: 1.6;
}
.contact-subtitle a {
    color: var(--callimont-red);
    text-decoration: none;
    transition: opacity 0.3s ease;
}
.contact-subtitle a:hover {
    opacity: 0.7;
}

/* 表單樣式 */
.contact-form {
    display: flex;
    flex-direction: column;
    gap: 2.1875rem;
}
.form-group {
    position: relative;
}
.form-group input,
.form-group textarea {
    width: 100%;
    padding: 0.75rem 0;
    font-size: 1rem;
    font-family: inherit;
    color: var(--text-color);
    background: transparent;
    border: none;
    border-bottom: 0.0625rem solid var(--pinkish-brown);
    outline: none;
    transition: border-color 0.3s ease;
    resize: none;
}
.form-group input:focus,
.form-group textarea:focus {
    border-bottom-color: var(--callimont-red);
}
.form-group label {
    position: absolute;
    left: 0;
    top: 0.75rem;
    font-size: 1rem;
    color: var(--text-color);
    opacity: 0.6;
    pointer-events: none;
    transition: all 0.3s ease;
}
.form-group input:focus + label,
.form-group input:not(:placeholder-shown) + label,
.form-group textarea:focus + label,
.form-group textarea:not(:placeholder-shown) + label {
    top: -1.25rem;
    font-size: 0.85rem;
    color: var(--callimont-red);
    opacity: 1;
}
.form-group textarea {
    min-height: 7.5rem;
    line-height: 1.6;
}
.contact-form .btn-cta {
    margin-top: 1.25rem;
    align-self: flex-start;
}

/* 成功訊息 */
.contact-success {
    display: none;
    text-align: center;
    padding: 2.5rem 1.25rem;
    opacity: 0;
    transform: translateY(1.25rem);
    transition: all 0.5s ease;
}
.contact-success.show {
    opacity: 1;
    transform: translateY(0);
}
.success-icon {
    width: 5rem;
    height: 5rem;
    margin: 0 auto 1.875rem;
    background: var(--callimont-red);
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 2.5rem;
    color: #fff;
}
.success-title {
    font-family: 'Hiragino Sans GB', serif;
    font-size: 2.2rem;
    color: var(--heading-color);
    margin-bottom: 0.9375rem;
    letter-spacing: 0.1875rem;
}
.success-message {
    font-size: 1.1rem;
    color: var(--text-color);
    line-height: 1.8;
}

/* 頁腳 (Footer) */
footer { background: var(--light-pink); padding: 5rem 0 2.5rem; text-align: center; }
.footer-logo { height: 3.125rem !important; margin: 0 auto 1.25rem; display: block; }
.footer-copyright { font-size: 0.875rem; margin-bottom: 1.5625rem; }
.footer-divider { width: 100%; height: 0.0625rem; background-color: var(--pinkish-brown); margin: 1.5625rem 0; }
.footer-links { display: flex; justify-content: center; gap: 2.5rem; }
.footer-links a { color: var(--text-color) !important; font-size: 0.875rem; transition: 0.3s; }
.footer-links a:hover { color: var(--callimont-red) !important; }

/* --- 私人課程頁面樣式 --- */
.styled-list, .instructor-points {
    list-style: none;
    padding: 0;
}
.styled-list li, .instructor-points li {
    position: relative;
    padding-left: 1.5625rem;
    margin-bottom: 0.9375rem;
    font-size: 1.1rem;
    line-height: 1.8;
    color: var(--text-color);
}
.styled-list li::before, .instructor-points li::before {
    content: "";
    position: absolute;
    left: 0;
    top: 0.75rem;
    width: 0.5rem;
    height: 0.5rem;
    background: var(--callimont-red);
    border-radius: 50%;
}
.alt-bg {
    background: var(--light-pink);
}
.highlight-box {
    margin-top: 3.125rem;
    padding: 1.875rem 2.5rem;
    background: linear-gradient(135deg, var(--light-pink) 0%, #fff 100%);
    border-left: 0.25rem solid var(--callimont-red);
    border-radius: 0 0.5rem 0.5rem 0;
}
.highlight-text {
    font-size: 1.1rem;
    color: var(--text-color);
    margin: 0;
    line-height: 1.8;
}
.course-content {
    display: grid;
    grid-template-columns: 1.5fr 1fr;
    gap: 3.75rem;
    align-items: start;
}
.course-intro {
    font-size: 1.15rem;
    color: var(--text-color);
    margin-bottom: 1.875rem;
    font-weight: 500;
}
.special-option {
    margin-top: 2.1875rem;
    padding: 1.5625rem 1.875rem;
    background: #fff;
    border-radius: 0.5rem;
    box-shadow: 0 0.1875rem 0.9375rem rgba(0, 0, 0, 0.05);
}
.special-option h4 {
    font-size: 1.1rem;
    color: var(--heading-color);
    margin-bottom: 0.625rem;
}
.course-scripts {
    background: #fff;
    padding: 2.5rem;
    border-radius: 0.5rem;
    text-align: center;
    box-shadow: 0 0.3125rem 1.5625rem rgba(0, 0, 0, 0.05);
}
.scripts-title {
    font-family: 'Hiragino Sans GB', serif;
    font-size: 1.8rem;
    color: var(--heading-color);
    margin-bottom: 1.5625rem;
}
.scripts-grid {
    display: flex;
    flex-wrap: wrap;
    justify-content: center;
    gap: 0.9375rem;
}
.script-item {
    display: inline-block;
    padding: 0.75rem 1.5625rem;
    background: var(--light-pink);
    color: var(--heading-color);
    font-size: 1.1rem;
    font-weight: 500;
    border-radius: 1.875rem;
    transition: all 0.3s ease;
}
.script-item:hover {
    background: var(--callimont-red);
    color: #fff;
}
.workshop-intro {
    text-align: center;
    font-size: 1.1rem;
    color: var(--text-color);
    margin-bottom: 2.5rem;
}
.workshop-item h4 {
    font-family: 'Hiragino Sans GB', serif;
    font-size: 1.3rem;
    color: var(--heading-color);
    margin-bottom: 0.625rem;
}
.workshop-item p {
    font-size: 0.9rem;
    color: var(--text-color);
    margin: 0;
}
.workshop-contact {
    text-align: center;
    font-size: 1rem;
    color: var(--text-color);
}
.workshop-contact a {
    color: var(--callimont-red);
    text-decoration: none;
    font-weight: 500;
}
.schedule-content {
    max-width: 43.75rem;
    margin: 0 auto;
}
.schedule-list li {
    font-size: 1.1rem;
    margin-bottom: 1.25rem;
}
.cta-section {
    background: linear-gradient(135deg, var(--heading-color) 0%, #5a4a30 100%);
}
.cta-content {
    text-align: center;
    padding: 1.875rem 0;
}
.cta-title {
    font-family: 'Hiragino Sans GB', serif;
    font-size: 2.5rem;
    color: #fff;
    margin-bottom: 0.9375rem;
    letter-spacing: 0.25rem;
}
.cta-desc {
    font-size: 1.1rem;
    color: rgba(255, 255, 255, 0.85);
    margin-bottom: 2.1875rem;
}
.cta-section .btn-cta {
    background: #fff;
    color: var(--callimont-red) !important;
}
.cta-section .btn-cta:hover {
    background: var(--callimont-red);
    color: #fff !important;
}

/* --- 瀑布流相片集 --- */
.gallery-tabs {
    display: flex;
    justify-content: center;
    gap: 0.9375rem;
    margin-bottom: 3.125rem;
}
.gallery-tab {
    padding: 0.75rem 2.1875rem;
    background: transparent;
    border: 0.125rem solid var(--pinkish-brown);
    color: var(--text-color);
    font-weight: 500;
    cursor: pointer;
    border-radius: 0.125rem;
    transition: all 0.3s ease;
}
.gallery-tab:hover {
    border-color: var(--callimont-red);
    color: var(--callimont-red);
}
.gallery-tab.active {
    background: var(--callimont-red);
    color: #fff;
    border-color: var(--callimont-red);
}
.photo-gallery { column-count: 3; column-gap: 1.5625rem; }
.gallery-item { break-inside: avoid; margin-bottom: 1.5625rem; position: relative; cursor: pointer; }
.gallery-item img { width: 100%; height: auto; border-radius: 0.25rem; }
.gallery-overlay {
    position: absolute;
    inset: 0;
    background: rgba(131, 109, 69, 0.85);
    display: flex;
    flex-direction: column;
    justify-content: center;
    align-items: center;
    padding: 1.25rem;
    text-align: center;
    opacity: 0;
    transition: opacity 0.4s ease;
}
.gallery-item:hover .gallery-overlay {
    opacity: 1;
}
.overlay-title {
    font-family: 'Hiragino Sans GB', serif;
    font-size: 2rem;
    color: #fff;
    margin-bottom: 0.5rem;
    line-height: 1.3;
}
.overlay-type {
    font-size: 0.95rem;
    color: #fff;
    opacity: 0.9;
    letter-spacing: 0.0625rem;
}
.gallery-coming-soon {
    text-align: center;
    color: var(--text-color);
    opacity: 0.7;
    margin-top: 2.5rem;
    font-style: italic;
}

/* --- 學校課程頁面樣式 --- */
.course-structure-list {
    max-width: 50rem;
    margin: 3.125rem auto 0;
}

.course-stage-item {
    padding: 1.5625rem 0;
}

.stage-label {
    display: flex;
    align-items: center;
    gap: 1.25rem;
    margin-bottom: 0.75rem;
}

.stage-name {
    font-family: 'Hiragino Sans GB', serif;
    font-size: 1.4rem;
    color: var(--heading-color);
    letter-spacing: 0.125rem;
}

.stage-count {
    display: inline-block;
    background: var(--callimont-red);
    color: #fff;
    padding: 0.25rem 0.875rem;
    border-radius: 0.9375rem;
    font-size: 0.85rem;
    font-weight: bold;
}

.stage-description {
    font-size: 1.05rem;
    color: var(--text-color);
    line-height: 1.8;
    margin: 0;
    padding-left: 0;
}

.course-stage-divider {
    width: 100%;
    height: 0.0625rem;
    background: var(--pinkish-brown);
    margin: 1.25rem 0;
    opacity: 0.5;
}

/* 課程理念引用樣式 */
.philosophy-quote {
    max-width: 56.25rem;
    margin: 0 auto 3.125rem;
    padding-left: 1.875rem;
    border-left: 0.25rem solid var(--callimont-red);
    position: relative;
}

.philosophy-quote::before {
    content: '"';
    position: absolute;
    left: -0.9375rem;
    top: -0.625rem;
    font-size: 4rem;
    color: var(--callimont-red);
    opacity: 0.2;
    font-family: serif;
}

.philosophy-text {
    font-size: 1.1rem;
    color: var(--text-color);
    line-height: 2;
    letter-spacing: 0.03125rem;
    margin: 0;
}

/* 價值觀流動標籤 */
.values-flow {
    display: flex;
    flex-wrap: wrap;
    justify-content: center;
    gap: 0.9375rem;
    margin-top: 2.5rem;
}

.value-tag {
    display: inline-block;
    background: #fff;
    padding: 0.75rem 1.5rem;
    border-radius: 1.5625rem;
    font-size: 0.95rem;
    color: var(--heading-color);
    font-weight: 500;
    box-shadow: 0 0.125rem 0.625rem rgba(0, 0, 0, 0.05);
    transition: all 0.3s ease;
    border: 0.09375rem solid transparent;
}

.value-tag:hover {
    border-color: var(--callimont-red);
    color: var(--callimont-red);
    transform: translateY(-0.125rem);
    box-shadow: 0 0.3125rem 1.25rem rgba(155, 23, 12, 0.15);
}

/* 簡約上課形式 */
.schedule-simple {
    max-width: 43.75rem;
    margin: 0 auto;
}

/* --- Lightbox 燈箱效果 --- */
.lightbox {
    position: fixed;
    inset: 0;
    background: rgba(0, 0, 0, 0.95);
    z-index: 10000;
    display: flex;
    align-items: center;
    justify-content: center;
    opacity: 0;
    visibility: hidden;
    transition: all 0.3s ease;
}

.lightbox.active {
    opacity: 1;
    visibility: visible;
}

.lightbox-content {
    display: flex;
    flex-direction: column;
    align-items: center;
    max-width: 90vw;
    max-height: 90vh;
}

.lightbox-image {
    max-width: 100%;
    max-height: 70vh;
    object-fit: contain;
    border-radius: 0.25rem;
    box-shadow: 0 0.625rem 3.125rem rgba(0, 0, 0, 0.5);
}

.lightbox-info {
    margin-top: 1.5625rem;
    text-align: center;
    color: #fff;
    max-width: 37.5rem;
}

.lightbox-title {
    font-family: 'Hiragino Sans GB', serif;
    font-size: 2rem;
    color: #fff;
    margin-bottom: 0.625rem;
}

.lightbox-type {
    font-size: 1rem;
    color: var(--pinkish-brown);
    margin-bottom: 0.9375rem;
}

.lightbox-desc {
    font-size: 0.95rem;
    line-height: 1.8;
    color: rgba(255, 255, 255, 0.85);
    margin-bottom: 0.625rem;
}

.lightbox-size {
    font-size: 0.9rem;
    color: rgba(255, 255, 255, 0.6);
}

.lightbox-close {
    position: absolute;
    top: 1.5625rem;
    right: 1.875rem;
    background: none;
    border: none;
    color: #fff;
    font-size: 2.5rem;
    cursor: pointer;
    transition: transform 0.3s ease, color 0.3s ease;
    z-index: 10001;
    width: 3.125rem;
    height: 3.125rem;
    display: flex;
    align-items: center;
    justify-content: center;
}

.lightbox-close:hover {
    transform: rotate(90deg);
    color: var(--callimont-red);
}

.lightbox-nav {
    position: absolute;
    top: 50%;
    transform: translateY(-50%);
    background: rgba(255, 255, 255, 0.1);
    border: none;
    color: #fff;
    font-size: 2rem;
    padding: 1.25rem 0.9375rem;
    cursor: pointer;
    transition: background 0.3s ease;
    z-index: 10001;
    border-radius: 0.25rem;
}

.lightbox-nav:hover {
    background: rgba(255, 255, 255, 0.2);
}

.lightbox-prev {
    left: 1.25rem;
}

.lightbox-next {
    right: 1.25rem;
}

/* 底部佈局 */
.footer-top {
    display: flex;
    justify-content: space-between;
    gap: 3.75rem;
}

/* --- 將書法融入血液 50/50 佈局 --- */
.calligraphy-blood-grid {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 3.75rem;
}

.calligraphy-blood-text {
    flex: 1;
    width: 50%;
}

.calligraphy-blood-text p {
    margin-bottom: 1.5625rem;
    font-size: 1.1rem;
    line-height: 2.2;
    color: var(--text-color);
    text-align: justify;
}

.calligraphy-blood-text p:last-child {
    margin-bottom: 0;
}

.calligraphy-blood-image {
    flex: 1;
    width: 50%;
    height: 28.125rem;
}

.calligraphy-blood-image img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    border: 0.5rem solid #fff;
    box-shadow: 0 1.25rem 2.5rem rgba(0,0,0,0.15);
    border-radius: 0.25rem;
}

/* --- 書籍購買區域樣式 --- */
.purchase-content {
    max-width: 50rem;
    margin: 0 auto;
    text-align: center;
}

.purchase-intro {
    font-size: 1.1rem;
    color: var(--text-color);
    margin-bottom: 3.125rem;
}

.purchase-methods {
    display: flex;
    justify-content: center;
    gap: 5rem;
    margin-bottom: 1.875rem;
}

.purchase-method {
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 0.9375rem;
}

.method-icon {
    font-size: 2rem;
    color: var(--callimont-red);
    margin-bottom: 0.3125rem;
}

.method-label {
    font-size: 0.9rem;
    color: var(--heading-color);
    font-weight: 600;
    letter-spacing: 0.0625rem;
    text-transform: uppercase;
}

.method-link {
    font-size: 1.1rem;
    color: var(--text-color);
    font-weight: 500;
    transition: color 0.3s ease;
}

.method-link:hover {
    color: var(--callimont-red);
}

.shipping-info-wrapper {
    margin-top: 5rem;
    padding-top: 3.75rem;
    border-top: 0.0625rem solid var(--pinkish-brown);
}

.shipping-info h3 {
    font-family: 'Hiragino Sans GB', serif;
    font-size: 1.8rem;
    color: var(--heading-color);
    margin-bottom: 1.5625rem;
}

.shipping-info ul {
    list-style: none;
    padding: 0;
    display: inline-block;
    text-align: left;
}

.shipping-info li {
    font-size: 1.05rem;
    color: var(--text-color);
    margin-bottom: 0.75rem;
    line-height: 1.6;
}

.shipping-info li strong {
    color: var(--heading-color);
    margin-right: 0.3125rem;
}

/* 金句引用樣式 */
.quote-content-wrapper {
    max-width: 56.25rem;
    margin: 0 auto;
    text-align: center;
}

.quote-subtitle {
    font-size: 1.3rem;
    line-height: 2;
    color: var(--text-color);
    margin-bottom: 1.25rem;
}

.quote-note {
    display: block;
    width: 100%;
    text-align: center;
    font-size: 1.1rem;
    color: var(--heading-color);
    margin-top: 3.75rem;
    font-style: italic;
    line-height: 1.6;
}

/* 清單樣式 */
.achievement-list, .works-list {
    max-width: 53.125rem;
    margin: 0 auto;
    text-align: left;
    list-style: none;
    padding: 0;
}

.achievement-list li, .works-list li {
    position: relative;
    display: flex;
    align-items: flex-start;
    gap: 0.75rem;
    margin-bottom: 1.125rem;
    font-size: 1.1rem;
    line-height: 1.8;
    color: var(--text-color);
    transition: all 0.3s ease;
}

.achievement-list li::before, .works-list li::before {
    content: '';
    flex: 0 0 0.5rem;
    width: 0.5rem;
    height: 0.5rem;
    background-color: #E31937;
    border-radius: 50%;
    margin-top: 0.625rem; /* 垂直居中對齊首行文字 */
}

/* 簽名區塊樣式 */
.signature-section {
    padding: 0;
}

.signature-wrapper {
    text-align: center;
}

.founder-signature {
    max-width: 28.125rem;
    width: 100%;
    height: auto;
    display: block;
    margin: 3.75rem auto;
}

/* 手機端適應 (Mobile Responsive) */
@media (max-width: 768px) {
    /* --- 全局設定 --- */
    body { padding-top: 4.375rem; }
    .container { padding: 0 1.25rem; } /* 保護內邊距 */
    .section-padding { padding: 3.75rem 0; }
    
    .section-title { 
        font-size: 2.2rem; 
        margin-bottom: 1.875rem;
    }
    
    .page-hero { padding: 3.125rem 0; }
    .page-hero-title { 
        font-size: 2rem; 
        letter-spacing: 0.125rem; 
        gap: 0.3125rem;
    }

    
    .page-hero-title .title-main,
    .page-hero-title .title-sub {
        font-size: 1.4rem;
        letter-spacing: 0.125rem;
    }
    .page-hero-title .title-highlight {
        font-size: 1.8rem;
        letter-spacing: 0.1875rem;
        margin: 0.3125rem 0;
    }
    .page-hero-subtitle { font-size: 1rem; }

    /* --- 首頁 Hero --- */
    .hero { height: 70vh; }
    .hero-content h1 { 
        font-size: 2.2rem; 
        margin-bottom: 1.25rem; 
        letter-spacing: 0.125rem;
    }
    .hero-content p { 
        font-size: 1rem; 
        margin-bottom: 2.5rem; 
        letter-spacing: 0.0625rem;
    }
    .btn-cta {
        padding: 0.75rem 2rem;
        font-size: 1rem;
    }

    /* --- 導航欄 (Mobile Navigation) --- */
    header { height: 4.375rem; padding: 0 1.25rem; }
    .logo-img { height: 2.8125rem; }
    
    /* 漢堡按鈕 */
    .menu-toggle { display: flex; }
    
    /* 導航選單 */
    nav {
        position: fixed;
        top: 4.375rem;
        left: 0;
        width: 100%;
        height: calc(100vh - 4.375rem);
        background: #fff;
        flex-direction: column;
        padding: 0; /* 移除頂部內邊距，由列表項處理 */
        transform: translateX(100%);
        transition: transform 0.4s cubic-bezier(0.4, 0, 0.2, 1);
        overflow-y: auto;
        z-index: 10000;
    }
    
    nav.active { transform: translateX(0); }
    
    .nav-list {
        display: flex;
        flex-direction: column;
        width: 100%;
        padding: 1.25rem 0;
    }
    
    .nav-list > li {
        margin: 0;
        width: 100%;
        border-bottom: 0.0625rem solid #f5f5f5;
    }
    
    .nav-list > li > a {
        display: flex;
        justify-content: space-between;
        align-items: center;
        padding: 1.125rem 1.875rem;
        font-size: 1.1rem;
        width: 100%;
        color: var(--text-color);
    }
    
    /* 下拉選單垂直展開 */
    .dropdown-menu {
        position: static !important;
        display: none !important;
        width: 100% !important;
        background: #f9f9f9 !important; /* 淺灰色背景 */
        padding: 0 !important;
        margin: 0 !important;
        opacity: 1 !important;
        visibility: visible !important;
        transform: none !important;
        box-shadow: none !important;
    }
    
    .dropdown.active .dropdown-menu { 
        display: block !important;
    }
    
    .dropdown-menu li {
        width: 100% !important;
        margin: 0 !important;
        padding: 0 !important;
    }
    
    .dropdown-menu li a {
        display: block !important;
        padding: 1.125rem 3.5rem !important; /* 顯著縮進並保持高度 */
        font-size: 1rem !important;
        color: #464646 !important; /* 明確的深灰色 */
        background: transparent !important;
        border-bottom: 0.0625rem solid #eee !important;
        width: 100% !important;
        text-align: left !important;
        line-height: 1.5 !important;
    }
    
    .dropdown-menu li:last-child a {
        border-bottom: none !important;
    }
    
    .dropdown-menu li:last-child a {
        border-bottom: none;
    }
    
    .dropdown-arrow { 
        display: inline-block;
        width: 0.5rem;
        height: 0.5rem;
        border-right: 0.125rem solid currentColor;
        border-bottom: 0.125rem solid currentColor;
        transform: rotate(45deg);
        transition: transform 0.3s ease;
        margin-left: 0.5rem;
        margin-top: -0.25rem;
    }
    
    .dropdown.active > a {
        color: var(--callimont-red); /* 選中時父級變紅 */
    }
    
    .dropdown.active .dropdown-arrow {
        transform: rotate(-135deg);
        margin-top: 0.125rem;
    }
    
    /* 登入按鈕 */
    .nav-list li:last-child {
        border-bottom: none; 
    }
    
    .nav-list .login-nav-btn {
        display: block;
        margin: 2.5rem auto 1.875rem; 
        width: 80%; 
        max-width: 17.5rem; 
        text-align: center;
        padding: 0.875rem 0;
        border-radius: 1.875rem;
    }

    /* --- 內容頁面修正 --- */
    
    /* 始創人、導師、中庸格等通用佈局 */
    .founder-profile, .instructor-profile, .book-item, .contact-wrapper, 
    .calligraphy-blood-grid, .instructor-profile-reverse { 
        flex-direction: column !important; 
        gap: 2.5rem;
    }
    
    /* 處理反向佈局在手機端恢復正常順序 (通常圖片在上) */
    .instructor-profile[style*="row-reverse"], 
    .instructor-profile-reverse,
    .book-item-reverse {
        flex-direction: column !important;
    }
    
    .founder-image, .instructor-image, .book-image { 
        flex: 0 0 auto; 
        width: 100%; 
        max-width: 100%; 
        text-align: center;
    }
    
    .instructor-profile .instructor-image {
        width: 100% !important;
        flex: 0 0 auto !important;
    }
    
    .instructor-profile .instructor-info {
        padding-right: 0 !important;
        width: 100% !important;
    }

    .founder-image img, .instructor-image img {
        max-width: 20rem; 
        margin: 0 auto;
        border-width: 0.25rem; 
    }
    
    /* 書籍頁 */
    .book-item-reverse { flex-direction: column !important; }
    .book-image { margin-bottom: 1.25rem; }
    .book-image img { max-width: 15.625rem; margin: 0 auto; display: block; }
    
    .purchase-methods {
        flex-direction: column;
        gap: 1.875rem;
    }
    .shipping-info-wrapper {
        margin-top: 3.125rem;
        padding-top: 2.5rem;
    }

    /* 相片集 (Gallery) */
    .photo-gallery { column-count: 1; }
    @media (min-width: 30rem) and (max-width: 48rem) {
        .photo-gallery { column-count: 2; }
    }
    .gallery-item { margin-bottom: 1.25rem; }
    .gallery-item.active-tap .gallery-overlay { opacity: 1; }
    
    /* 聯絡我們 (Contact) */
    .contact-wrapper { flex-direction: column-reverse !important; }
    .contact-image-section { 
        flex: 0 0 auto; 
        height: 15.625rem; 
        width: 100%; 
    }
    .contact-image-section img { object-position: center; }
    .contact-form { width: 100%; padding-right: 0; }
    
    /* 網上學習 (Learning) */
    .features-grid, .learning-grid { 
        grid-template-columns: 1fr; 
        flex-direction: column;
        gap: 1.875rem;
    }
    .course-content {
        grid-template-columns: 1fr;
        gap: 2.5rem;
    }
    
    /* 其他細節 */
    .cta-title { font-size: 2rem; letter-spacing: 0.125rem; }
    
    .calligraphy-blood-grid {
        flex-direction: column-reverse !important;
        gap: 1.875rem !important;
    }
    .calligraphy-blood-text, .calligraphy-blood-image { width: 100% !important; }
    .calligraphy-blood-image { height: 15.625rem !important; }
    
    /* Lightbox 手機調整 */
    .lightbox-image { max-height: 50vh; max-width: 95%; }
    .lightbox-info { width: 95%; padding: 0.9375rem; }
    .lightbox-title { font-size: 1.3rem; }
    .lightbox-desc { font-size: 0.9rem; max-height: 15vh; overflow-y: auto; }

    .quote-note {
        margin-top: 1.875rem;
        font-size: 1rem;
    }
}
/* 中庸格專用：自動圖片輪播樣式 */
.grid-slideshow {
    position: relative;
    width: 100%;
    aspect-ratio: 1 / 1; /* 保持正方形 */
    background: #fff;
    border: 0.0625rem solid #eee;
    border-radius: 0.25rem;
    overflow: hidden;
}

.slide-img {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    object-fit: contain;
    opacity: 0;
    animation: gridFade 9s infinite; /* 總長9秒，每張3秒 */
}

/* 設置三張圖片的動畫延遲 */
.slide-img:nth-child(1) { animation-delay: 0s; }
.slide-img:nth-child(2) { animation-delay: 3s; }
.slide-img:nth-child(3) { animation-delay: 6s; }

@keyframes gridFade {
    0% { opacity: 0; }
    10% { opacity: 1; }
    33% { opacity: 1; }
    43% { opacity: 0; }
    100% { opacity: 0; }
}

/* --- 滾動動畫 --- */
.reveal {
    opacity: 0;
    transform: translateY(1.875rem);
    transition: all 0.8s cubic-bezier(0.165, 0.84, 0.44, 1);
}

.reveal.active {
    opacity: 1;
    transform: translateY(0);
}

/* --- 獎項列表優化 --- */
.achievement-item-with-img {
    cursor: pointer;
}

.achievement-item-with-img:hover {
    color: var(--callimont-red);
}

.award-img-icon {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 1.5rem;
    height: 1.5rem;
    background: var(--callimont-red);
    color: #fff;
    border-radius: 0.25rem;
    font-size: 0.75rem;
    margin-left: 0.5rem;
    transition: transform 0.3s ease;
    vertical-align: middle;
}

.achievement-item-with-img:hover .award-img-icon {
    transform: scale(1.1);
}

/* Tooltip 樣式修復 */
[data-tooltip] {
    position: relative;
}

[data-tooltip]::after {
    content: '查看作品照片';
    position: absolute;
    bottom: 100%;
    left: 50%;
    transform: translateX(-50%) translateY(-0.625rem);
    padding: 0.5rem 0.9375rem;
    background: #333333;
    color: #ffffff;
    font-size: 0.8125rem;
    border-radius: 0.375rem;
    white-space: nowrap;
    opacity: 0;
    visibility: hidden;
    transition: opacity 0.3s ease, transform 0.3s ease;
    z-index: 100;
    box-shadow: 0 0.25rem 0.9375rem rgba(0,0,0,0.2);
    pointer-events: none;
}

[data-tooltip]:hover::after {
    opacity: 1;
    visibility: visible;
    transform: translateX(-50%) translateY(-0.9375rem);
}

/* 作品集按鈕樣式 */
.gallery-btn-wrapper {
    display: flex;
    justify-content: center;
    margin-top: 2.5rem;
}

.btn-gallery-more {
    width: 11.25rem;
    height: 3rem;
    display: flex;
    align-items: center;
    justify-content: center;
    background-color: var(--callimont-red);
    color: #fff !important;
    text-decoration: none;
    border-radius: 0.25rem;
    font-weight: 500;
    transition: all 0.3s ease;
    border: none;
}

.btn-gallery-more:hover {
    background-color: #c4162f;
    transform: translateY(-0.125rem);
    box-shadow: 0 0.3125rem 0.9375rem rgba(227, 25, 55, 0.3);
}

/* 簽名區塊優化 */
.signature-section {
    padding-bottom: 5rem;
}
