/* =========================================
   1. VARIABLES & RESET (變數與重置)
   ========================================= */
:root {
    --primary-color: #b9804b;      /* 金色主色 */
    --primary-hover: #9a6a3b;      /* 深金色 (Hover用) */
    --secondary-color: #fcefe9;    /* 淺粉色 */
    --bg-beige: #fdfbf7;           /* 網頁主背景 (米白) */
    --bg-dark-beige: #f5efe6;      /* 較深的杏色 (痛點區塊專用) */
    --bg-dark: #2e2a25;            /* 深色背景 */
    --text-dark: #2e2a25;          /* 深黑色文字 */
    --text-light: #8c8c8c;         /* 淺灰文字 */
    --white: #ffffff;
    
    --font-serif: 'Noto Serif TC', serif;
    --font-sans: 'Noto Sans TC', sans-serif;
}

* { box-sizing: border-box; margin: 0; padding: 0; }

body { 
    font-family: var(--font-sans); 
    color: var(--text-dark); 
    background-color: var(--bg-beige); 
    line-height: 1.6; 
    overflow-x: hidden;
    scroll-behavior: smooth;
}

a { text-decoration: none; color: inherit; transition: 0.3s; }
img { max-width: 100%; display: block; }
ul { list-style: none; }

h1, h2, h3 { font-family: var(--font-serif); font-weight: 700; margin-bottom: 1rem; }

.container { width: 90%; max-width: 1200px; margin: 0 auto; padding: 0 15px; }
.text-center { text-align: center; }
.section-padding { padding: 80px 0; }
.bg-beige { background-color: #fbf7f2; }
.bg-light { background-color: #fffcf8; }
.bg-white { background-color: #ffffff; }

.divider {
    width: 60px; height: 3px; background-color: var(--primary-color);
    margin: 20px auto;
}
.highlight-text { color: var(--primary-color); letter-spacing: 2px; font-size: 0.9rem; font-weight: 700; text-transform: uppercase; display: block; margin-bottom: 10px; }

/* =========================================
   2. BUTTONS & ANIMATIONS
   ========================================= */
.btn { 
    display: inline-block; padding: 15px 35px; 
    font-size: 1.1rem; border-radius: 50px; 
    font-weight: 500; cursor: pointer; border: none; 
    text-align: center; transition: all 0.3s ease; 
}
.btn-primary { background-color: var(--primary-color); color: var(--white); box-shadow: 0 4px 15px rgba(185, 128, 75, 0.4); }
.btn-primary:hover { background-color: var(--primary-hover); transform: translateY(-2px); }
.btn-secondary { background-color: transparent; border: 2px solid var(--primary-color); color: var(--primary-color); margin-left: 10px; }
.btn-secondary:hover { background-color: var(--primary-color); color: var(--white); }
.btn-full { width: 100%; margin-left: 0; }

/* Shake Animation Class */
.btn-shake-load { animation: shake 0.8s ease-in-out 1.5s; }
@keyframes shake {
    0%, 100% { transform: translateX(0); }
    10%, 30%, 50%, 70%, 90% { transform: translateX(-4px); }
    20%, 40%, 60%, 80% { transform: translateX(4px); }
}

/* =========================================
   3. HEADER & NAV (導航欄)
   ========================================= */
.navbar { 
    padding: 5px 0; position: fixed; width: 100%; z-index: 1000; top: 0; 
    background-color: rgba(255, 255, 255, 0.7); backdrop-filter: blur(5px);
    border-bottom: 1px solid rgba(255, 255, 255, 0.1);
}
.nav-container { display: flex; justify-content: space-between; align-items: center; }
.navbar .logo { font-family: var(--font-serif); font-size: 1.1rem; font-weight: bold; color: var(--text-dark); letter-spacing: 0.5px; text-transform: none; }

.nav-menu { display: flex; align-items: center; gap: 30px; }
.nav-menu a { font-size: 0.9rem; color: #5a5a5a; font-weight: 500; }
.nav-menu a:hover { color: var(--primary-color); }
.btn-nav { background-color: var(--text-dark); color: var(--white) !important; padding: 2px 20px; border-radius: 50px; font-size: 0.85rem; transition: 0.3s; }
.btn-nav:hover { background-color: var(--primary-color); }

.hamburger { display: none; cursor: pointer; }
.bar { display: block; width: 25px; height: 3px; margin: 5px auto; transition: all 0.3s ease-in-out; background-color: var(--text-dark); }

/* =========================================
   4. HERO SECTION (首頁大圖)
   ========================================= */
.hero-section {
    height: 100vh; min-height: 700px;
    background-size: cover; background-position: center center; 
    position: relative; display: flex; align-items: center; 
    justify-content: center; text-align: center; margin-top: 0; 
}

.tagline-pill {
    display: inline-block; background: rgb(from var(--primary-color) r g b / 0.4);
    padding: 5px 15px; border-radius: 20px; font-size: 0.9rem; margin-bottom: 20px; 
    backdrop-filter: blur(5px); border: 1px solid rgba(255,255,255,0.3);
    color: #ffffff; letter-spacing: 2px; font-weight: 300;
}

.hero-content h1 { font-family: var(--font-serif); margin-bottom: 25px; line-height: 0.85; font-weight: 400; }
.hero-title-main { font-size: 2.8rem; color: #2e2a25; display: block; margin-bottom: -10px; letter-spacing: 2px; }
.hero-title-highlight { font-size: 3.6rem; color: var(--primary-color); display: block; }
.hero-content .subtitle { font-size: 1.25rem; margin-bottom: 25px; font-weight: 400; color: #4a3b32; line-height: 1.8; }

.hero-stats { display: flex; align-items: center; justify-content: center; margin-top: 30px; gap: 40px; }
.stat-item { font-family: var(--font-serif); color: #4a3b32; font-size: 0.95rem; }
.stat-item strong { font-size: 1.8rem; color: var(--text-dark); display: block; line-height: 1; margin-bottom: 5px; }
.stat-divider { width: 1px; height: 40px; background-color: #999; }

/* =========================================
   5. MEDIA & STORY SECTION
   ========================================= */
.media-section { padding: 40px 0; border-bottom: 1px solid #eee; background-color: #fceee9; }
.section-label { font-size: 0.8rem; color: #999; margin-bottom: 20px; letter-spacing: 1px; }
.media-logos-text { display: flex; justify-content: center; gap: 60px; flex-wrap: wrap; align-items: center; }
.media-item { font-family: var(--font-serif); font-size: 1.8rem; color: #a89a8f; position: relative; cursor: default; transition: 0.3s; }
.media-item:hover { color: var(--primary-color); }
.media-item span { display: block; font-size: 0.6rem; font-family: var(--font-sans); text-align: center; letter-spacing: 1px; margin-top: -5px; text-transform: uppercase; }

.grid-2-bias { display: grid; grid-template-columns: 1fr 1.2fr; gap: 60px; align-items: center; }
.story-img-wrapper { position: relative; }
.story-img-wrapper img { border-radius: 8px; box-shadow: 0 20px 40px rgba(0,0,0,0.05); }
.story-quote-card { position: absolute; bottom: 30px; right: -40px; background: var(--white); padding: 30px; border-radius: 4px; max-width: 320px; box-shadow: 0 15px 30px rgba(0,0,0,0.08); border-left: 4px solid var(--primary-color); }
.story-quote-card p { font-family: var(--font-serif); font-style: italic; color: var(--text-dark); font-size: 1.1rem; margin-bottom: 10px;}
.quote-author { font-size: 0.9rem; color: #999; }
.story-content h2 { font-size: 2.8rem; margin-bottom: 30px; color: var(--text-dark); line-height: 1.2; }
.text-highlight { color: var(--primary-color); }
.story-content p { margin-bottom: 20px; color: #666; font-size: 1rem; text-align: justify; }
.story-footer-stats { display: flex; gap: 50px; margin-top: 40px; border-top: 1px solid #ddd; padding-top: 20px; }
.story-footer-stats h3 { font-size: 2rem; margin-bottom: 0; color: var(--text-dark); font-family: var(--font-serif); }
.story-footer-stats p { font-size: 0.8rem; color: #999; letter-spacing: 1px; }

/* =========================================
   6. TARGET AUDIENCE (無論你是...)
   ========================================= */
.target-audience { background-color: #ffffff; }

.simple-audience-list {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 20px;
    max-width: 1100px;
    margin: 40px auto 0 auto;
}

.list-item {
    background-color: var(--bg-beige);
    border-radius: 15px;
    padding: 25px 20px;
    display: flex; align-items: center;
    transition: all 0.3s ease;
    border: 1px solid transparent;
    box-shadow: 0 4px 10px rgba(0,0,0,0.02);
}
.list-item:hover {
    transform: translateY(-5px);
    background-color: #fff;
    border-color: rgba(185, 128, 75, 0.3);
    box-shadow: 0 10px 25px rgba(185, 128, 75, 0.15);
}
.list-item i { color: var(--primary-color); font-size: 1.4rem; margin-right: 15px; flex-shrink: 0; }
.list-item span { font-size: 1.1rem; color: var(--text-dark); font-weight: 500; line-height: 1.4; }

/* =========================================
   7. PAIN POINTS (你是否...) - 修正顏色
   ========================================= */
.pain-points {
    /* 🔴 改為較深的暖杏色，讓白色卡片突出，並與下一段區分 */
    background-color: var(--bg-dark-beige); 
    border-top: 1px solid #ece4da;
    padding-bottom: 100px;
}

.grid-4 { display: grid; grid-template-columns: repeat(4, 1fr); gap: 20px; }

.card { 
    background: var(--white); /* 白色卡片 */
    padding: 30px 20px; border-radius: 12px; 
    box-shadow: 0 5px 20px rgba(0,0,0,0.03); 
    text-align: center; transition: 0.3s; 
}
.card:hover { transform: translateY(-5px); box-shadow: 0 15px 30px rgba(0,0,0,0.08); }
.pain-points .card h3 { font-size: 1.25rem; margin-bottom: 10px; }
.icon-img { width: 60px; height: 60px; margin: 0 auto 20px auto; opacity: 0.8; }

/* =========================================
   8. INSPIRATION (轉型開始) - 修正顏色
   ========================================= */
.inspiration-section {
    /* 🔴 改為純淨的淡米色 (無漸變)，與上方的深色區分 */
    background: var(--bg-beige);
    
    color: var(--text-dark);
    position: relative;
    padding: 80px 0;
}

.inspiration-section h2 {
    color: var(--text-dark); font-size: 2.2rem; margin-bottom: 20px; line-height: 1.4;
}
.main-quote {
    font-family: var(--font-serif); font-size: 1.5rem; color: var(--primary-color);
    font-style: italic; margin-bottom: 40px; line-height: 1.6;
}

.success-stories-box {
    background: #ffffff;
    box-shadow: 0 15px 40px rgba(185, 128, 75, 0.1);
    border: 1px solid rgba(185, 128, 75, 0.2);
    padding: 40px 30px; border-radius: 12px;
    max-width: 600px; margin: 0 auto; text-align: left;
}
.intro-text { text-align: center; font-size: 1.1rem; font-weight: bold; margin-bottom: 20px; color: var(--text-dark); }
.story-list li { display: flex; align-items: flex-start; margin-bottom: 15px; font-size: 1.05rem; color: #555; }
.story-list i { color: var(--primary-color); margin-right: 12px; margin-top: 5px; font-size: 0.9rem; }

/* =========================================
   9. STUDENT SHARING (學員見證)
   ========================================= */
.student-sharing { background-color: #ffffff; overflow: hidden; }

.scroller-container {
    margin-top: 40px; width: 100%; overflow: hidden; position: relative;
    mask-image: linear-gradient(to right, transparent, black 5%, black 95%, transparent);
    -webkit-mask-image: linear-gradient(to right, transparent, black 5%, black 95%, transparent);
}

.scroller-inner {
    display: flex; gap: 20px; width: max-content; flex-wrap: nowrap;
}

.gallery-item {
    width: 280px; flex-shrink: 0; border-radius: 12px; overflow: hidden;
    box-shadow: 0 5px 15px rgba(0,0,0,0.08);
}
.gallery-item img { width: 100%; height: 100%; object-fit: cover; aspect-ratio: 1 / 1; display: block; pointer-events: none; }

/* Desktop Animation */
@media (min-width: 769px) {
    .scroller-inner { animation: scroll-loop 30s linear infinite; }
    .scroller-inner:hover { animation-play-state: paused; }
}
@keyframes scroll-loop {
    to { transform: translateX(calc(-50% - 10px)); }
}
.swipe-hint { display: none; font-size: 0.9rem; color: #999; margin-top: 20px; }

/* =========================================
   10. FINAL OFFER (我走過的路)
   ========================================= */
.final-offer { background-color: #fbf7f2; }
.final-offer .container { padding-top: 20px; padding-bottom: 20px; }

.section-subtitle { font-size: 1.1rem; color: #666; margin-bottom: 20px; font-family: var(--font-serif); }
.invitation-title { font-size: 1.8rem; color: var(--primary-color); margin-bottom: 30px; font-family: var(--font-serif); }

.offer-buttons-container { display: flex; justify-content: center; gap: 40px; flex-wrap: wrap; margin-bottom: 50px; }
.offer-item {
    background: #ffffff; padding: 30px; border-radius: 12px; width: 100%; max-width: 450px;
    box-shadow: 0 10px 30px rgba(0,0,0,0.05); border: 1px solid rgba(0,0,0,0.02); transition: 0.3s;
}
.offer-item:hover { transform: translateY(-5px); box-shadow: 0 15px 35px rgba(185, 128, 75, 0.1); }
.offer-label { font-size: 1rem; font-weight: bold; color: var(--text-dark); margin-bottom: 20px; line-height: 1.5; }
.price-highlight { color: #d14030; font-size: 1.1rem; }
.old-price { text-decoration: line-through; color: #999; font-size: 0.9rem; }

.content-sharing { max-width: 800px; margin: 0 auto; text-align: center; }
.sharing-intro { font-size: 1.1rem; line-height: 1.8; margin-bottom: 30px; color: var(--text-dark); }
.sharing-list {
    text-align: left; display: grid; grid-template-columns: repeat(2, 1fr);
    gap: 20px 50px; margin-bottom: 40px; background: #fff; padding: 30px 40px;
    border-radius: 12px; box-shadow: 0 5px 20px rgba(0,0,0,0.03);
    max-width: 900px; margin-left: auto; margin-right: auto;
}
.sharing-list li { font-size: 1.05rem; margin-bottom: 0; color: #555; display: flex; align-items: center; }
.sharing-list i { color: var(--primary-color); margin-right: 12px; font-size: 1rem; flex-shrink: 0; }
.sharing-outro { font-size: 1.2rem; line-height: 1.6; font-family: var(--font-serif); color: #2e2a25; }

/* =========================================
   11. FOOTER & POPUP
   ========================================= */
footer { padding: 80px 0 40px 0; border-top: 1px solid #eee; background-color: #fff; color: var(--text-dark); }
.footer-quote { font-family: var(--font-serif); font-size: 1.6rem; color: var(--primary-color); margin-bottom: 15px; letter-spacing: 1px; font-weight: 600; }
.footer-sub { font-size: 1rem; color: #666; line-height: 1.8; margin-bottom: 40px; font-family: var(--font-serif); }
.footer-social-box { margin-bottom: 30px; display: flex; flex-direction: column; align-items: center; gap: 20px; }
.social-icons-wrapper { display: flex; justify-content: center; align-items: center; gap: 40px; }

.social-icon { font-size: 1.8rem; color: var(--text-dark); display: flex; align-items: center; justify-content: center; transition: all 0.3s ease; text-decoration: none; }
.social-icon:hover { color: var(--primary-color); transform: translateY(-3px); }
.social-img-icon { height: 1.6rem; width: auto; display: block; transition: all 0.3s ease; }
.social-icon:hover .social-img-icon {
    filter: invert(54%) sepia(35%) saturate(762%) hue-rotate(345deg) brightness(93%) contrast(90%);
    transform: translateY(-3px);
}
.copyright { font-size: 0.75rem; color: #bbb; border-top: 1px solid #f5f5f5; padding-top: 20px; margin-top: 20px; }

/* Popup */
.popup-overlay { display: none; position: fixed; top: 0; left: 0; width: 100%; height: 100%; background: rgba(0,0,0,0.7); z-index: 9999; align-items: center; justify-content: center; backdrop-filter: blur(5px); opacity: 0; transition: opacity 0.3s ease; }
.popup-overlay.show { opacity: 1; }
.popup-content { background: var(--white); width: 90%; max-width: 450px; border-radius: 8px; overflow: hidden; position: relative; box-shadow: 0 25px 50px rgba(0, 0, 0, 0.2); transform: translateY(20px); transition: transform 0.3s ease; }
.popup-overlay.show .popup-content { transform: translateY(0); }
.popup-img { width: 100%; height: 140px; object-fit: cover; }
.popup-header { padding: 15px 30px 0 30px; }
.popup-header h2 { font-size: 1.4rem; color: var(--text-dark); margin-bottom: 5px; }
.popup-header p { color: #888; font-size: 0.9rem; margin-bottom: 20px; }
#googleForm, #successMessage { padding: 0 30px 30px 30px; }
.close-btn { position: absolute; top: 10px; right: 15px; font-size: 28px; cursor: pointer; color: #fff; z-index: 10; }
.form-group { margin-bottom: 15px; }
.form-group input, .form-group textarea { width: 100%; padding: 12px; border: 1px solid #ddd; border-radius: 4px; font-size: 0.95rem; transition: 0.3s; background: #fafafa; font-family: var(--font-sans); }
.form-group textarea { resize: vertical; }
.form-group input:focus, .form-group textarea:focus { border-color: var(--primary-color); outline: none; background: #fff; }
.privacy-note { font-size: 0.75rem; color: #aaa; text-align: center; margin-top: 15px; }

/* Animations */
.animate-on-scroll { opacity: 0; transform: translateY(30px); transition: all 0.8s ease-out; }
.animate-on-scroll.visible { opacity: 1; transform: translateY(0); }
.delay-1 { transition-delay: 0.2s; }
.delay-2 { transition-delay: 0.4s; }
.delay-3 { transition-delay: 0.6s; }
.fade-in-up { animation: fadeInUp 1s ease-out forwards; }
@keyframes fadeInUp { from { opacity: 0; transform: translateY(30px); } to { opacity: 1; transform: translateY(0); } }

/* =========================================
   12. MOBILE RESPONSIVE
   ========================================= */
@media (max-width: 1024px) {
    .grid-4 { grid-template-columns: repeat(2, 1fr); gap: 30px; }
}

@media (max-width: 900px) {
    .hamburger { display: block; }
    .hamburger.active .bar:nth-child(2) { opacity: 0; }
    .hamburger.active .bar:nth-child(1) { transform: translateY(8px) rotate(45deg); }
    .hamburger.active .bar:nth-child(3) { transform: translateY(-8px) rotate(-45deg); }
    
    .nav-menu { position: fixed; left: -100%; top: 60px; gap: 0; flex-direction: column; background-color: rgba(255, 255, 255, 0.95); backdrop-filter: blur(10px); width: 100%; text-align: center; transition: 0.3s; box-shadow: 0 10px 20px rgba(0,0,0,0.1); padding: 20px 0; }
    .nav-menu.active { left: 0; }
    .nav-menu li { margin: 16px 0; }

    .hero-section { background-position: 80% center; align-items: flex-end; padding-bottom: 30px; }
    .hero-content { background: rgba(255, 255, 255, 0.85); backdrop-filter: blur(10px); border-radius: 15px; padding: 20px 15px; margin: 0 15px; width: calc(100% - 30px); max-width: 100%; box-shadow: 0 -5px 25px rgba(0,0,0,0.1); border: 1px solid rgba(255,255,255,0.6); text-align: center; }
    .hero-content h1 { margin-bottom: 10px; line-height: 1; }
    .hero-title-main { font-size: 1.5rem; margin-bottom: -22px; }
    .hero-title-highlight { font-size: 2.2rem; line-height: 1; margin-top: 0; }
    .tagline-pill { background-color: var(--primary-color); color: #fff; text-shadow: none; border: none; font-size: 0.9rem; padding: 4px 12px; margin-bottom: 12px; }
    .hero-content .subtitle { font-size: 0.9rem; margin-bottom: 15px; }
    .cta-group .btn { display: block; width: 100%; margin: 8px 0; padding: 10px 0; font-size: 1rem; }
    .hero-stats { margin-top: 15px; gap: 15px; flex-wrap: wrap; justify-content: center; }
    .stat-divider { display: none; }
    .stat-item { width: auto; min-width: 70px; font-size: 0.75rem; padding: 0; border: none; }
    .stat-item strong { font-size: 1.2rem; }

    .simple-audience-list { grid-template-columns: repeat(2, 1fr); }
    .media-logos-text { gap: 30px; }
    .grid-2-bias { grid-template-columns: 1fr; }
    .story-quote-card { position: relative; right: auto; bottom: auto; max-width: 100%; margin-top: -30px; }
}

@media (max-width: 768px) {
    .offer-buttons-container { gap: 20px; }
    .sharing-list { grid-template-columns: 1fr; gap: 15px; padding: 25px 20px; width: 100%; }
    
    .scroller-inner { animation: none !important; width: 100%; overflow-x: auto; scroll-snap-type: x mandatory; padding-bottom: 20px; scrollbar-width: none; gap: 15px; }
    .scroller-inner::-webkit-scrollbar { display: none; }
    .gallery-item { width: 85vw; scroll-snap-align: center; }
    .gallery-item:nth-child(n+6) { display: none; }
    .scroller-inner::before, .scroller-inner::after { content: ''; flex: 0 0 10px; }
    .swipe-hint { display: block; }
}

@media (max-width: 600px) {
    .inspiration-section h2 { font-size: 1.6rem; }
    .main-quote { font-size: 1.2rem; }
    .success-stories-box { padding: 30px 20px; }
    .footer-quote { font-size: 1.3rem; }
    .grid-4 { grid-template-columns: 1fr; }
    .simple-audience-list { grid-template-columns: 1fr; }
    .list-item { padding: 20px 15px; }
}