/* 
   ========================================
   Antigravity X Zeabur 實戰課程 - 主樣式
   優化版本：引導式設計顧問 (Design Advisor - Guided)
   ========================================
*/

:root {
    /* 顏色配置 (Color System) - 指定主色 #DB1A1A */
    --primary: #DB1A1A;
    --primary-light: #FEF2F2; /* 用於背景/hover */
    --primary-dark: #991B1B;  /* 用於文字/active */
    --primary-glow: rgba(219, 26, 26, 0.15);
    
    --secondary: #4B5563;     /* 灰色系次要色 */
    --background: #FFFFFF;
    --surface: #F9FAFB;
    
    /* 語意色彩 */
    --success: #10B981;
    --error: #EF4444;
    --warning: #F59E0B;
    
    /* 文字色彩 */
    --text-primary: #111827;
    --text-secondary: #4B5563;
    --text-muted: #9CA3AF;

    /* 字體設定 (Typography) */
    --font-main: 'SN Pro Variable', 'SN Pro', 'Noto Sans TC', sans-serif;
    --font-code: 'JetBrains Mono', monospace;
    
    /* 視覺一致性 */
    --radius: 12px;
    --transition: 0.2s ease;
    --shadow-sm: 0 1px 2px 0 rgba(0, 0, 0, 0.05);
    --shadow-md: 0 4px 6px -1px rgba(0, 0, 0, 0.1), 0 2px 4px -1px rgba(0, 0, 0, 0.06);
    --shadow-lg: 0 10px 15px -3px rgba(0, 0, 0, 0.1), 0 4px 6px -2px rgba(0, 0, 0, 0.05);
}

/* 基礎樣式重置 */
* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

html {
    scroll-behavior: smooth;
    font-size: 16px;
}

body {
    font-family: var(--font-main);
    background-color: var(--background);
    color: var(--text-primary);
    line-height: 1.7; /* 間距優化 1.6~1.8 */
    overflow-x: hidden;
    -webkit-font-smoothing: antialiased;
}

.container {
    width: 100%;
    max-width: 1200px;
    margin: 0 auto;
    padding: 0 1.5rem;
}

/* 導覽列 */
header {
    position: fixed;
    top: 0;
    width: 100%;
    z-index: 1000;
    background: rgba(255, 255, 255, 0.9);
    backdrop-filter: blur(12px);
    border-bottom: 1px solid rgba(0, 0, 0, 0.05);
    padding: 1.5rem 0;
    transition: var(--transition);
}

/* 捲動後的導覽列樣式 (由 JS 控制切換) */
header.header-scrolled {
    padding: 0.8rem 0;
    background: rgba(255, 255, 255, 0.95);
    box-shadow: 0 10px 30px var(--primary-glow);
}

header nav {
    display: flex;
    justify-content: space-between;
    align-items: center;
}

.logo {
    font-size: 1.25rem;
    font-weight: 800;
    color: var(--primary);
    display: flex;
    align-items: center;
    gap: 0.5rem;
}

.nav-links {
    list-style: none;
    display: none; /* 手機版預設隱藏，若有漢堡選單邏輯可加 */
    gap: 2rem;
}

.nav-links i {
    margin-right: 4px;
    font-size: 0.9em;
}

.nav-links a {
    text-decoration: none;
    color: var(--text-secondary);
    font-weight: 500;
    font-size: 0.95rem;
    transition: var(--transition);
}

.nav-links a:hover {
    color: var(--primary);
}

/* Hero 區域 (手機優先) */
.hero {
    padding-top: 8rem;
    padding-bottom: 4rem;
    min-height: 80vh;
    display: flex;
    align-items: center;
    background: radial-gradient(circle at top right, var(--primary-light), transparent);
}

.hero-content {
    text-align: center;
}

.hero-content h1 {
    font-size: 2.5rem; /* 手機版字級 */
    line-height: 1.2;
    margin-bottom: 1.5rem;
    font-weight: 800;
    letter-spacing: -0.02em;
}

.hero-content p {
    font-size: 1.1rem;
    color: var(--text-secondary);
    max-width: 600px;
    margin: 0 auto 2.5rem;
}

/* 按鈕配色 (Button System) */
.btn {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 0.5rem;
    padding: 0.75rem 1.5rem;
    border-radius: var(--radius);
    font-weight: 600;
    text-decoration: none;
    cursor: pointer;
    transition: var(--transition);
    border: none;
    font-family: inherit;
    font-size: 1rem;
}

.btn-primary {
    background: var(--primary);
    color: white;
    box-shadow: 0 4px 12px var(--primary-glow);
}

.btn-primary:hover {
    background: var(--primary-dark);
    transform: translateY(-1px);
    box-shadow: 0 6px 16px var(--primary-glow);
}

.btn-secondary {
    background: var(--primary-light);
    color: var(--primary);
}

.btn-secondary:hover {
    background: #FEE2E2;
}

.cta-group {
    display: flex;
    flex-direction: column; /* 手機版垂直排列 */
    gap: 1rem;
}

/* 通用章節樣式 */
.section {
    padding: 5rem 0;
}

.section-title {
    text-align: center;
    font-size: 2rem;
    font-weight: 800;
    margin-bottom: 3rem;
    position: relative;
}

.section-title::after {
    content: '';
    display: block;
    width: 40px;
    height: 4px;
    background: var(--primary);
    margin: 0.75rem auto 0;
    border-radius: 2px;
}

/* 特色區域 (Responsive Grid) */
.feature-grid {
    display: grid;
    grid-template-columns: 1fr; /* 手機版 1 欄 */
    gap: 1.5rem;
}

.feature-card {
    background: var(--surface);
    padding: 2rem;
    border-radius: var(--radius);
    border: 1px solid rgba(0, 0, 0, 0.05);
    transition: var(--transition);
}

.feature-card:hover {
    background: white;
    border-color: var(--primary);
    box-shadow: var(--shadow-lg);
    transform: translateY(-4px);
}

.feature-card .icon {
    font-size: 2.5rem;
    color: var(--primary);
    margin-bottom: 1.25rem;
}

.feature-card h3 {
    font-size: 1.25rem;
    margin-bottom: 0.75rem;
}

.feature-card p {
    color: var(--text-secondary);
    font-size: 0.95rem;
}

/* 講師介紹 */
.instructor {
    background: var(--surface);
}

.instructor-content {
    display: flex;
    flex-direction: column; /* 手機版垂直 */
    align-items: center;
    gap: 2.5rem;
    text-align: center;
}

.instructor-image {
    width: 200px;
    height: 200px;
    border-radius: 50%; /* 改為圓形更現代 */
    overflow: hidden;
    border: 4px solid white;
    box-shadow: var(--shadow-lg);
}

.profile-img {
    width: 100%;
    height: 100%;
    object-fit: cover;
}

.instructor-title {
    color: var(--primary);
    font-weight: 700;
    font-size: 0.9rem;
    text-transform: uppercase;
    letter-spacing: 0.05em;
    margin-bottom: 0.5rem;
    display: block;
}

.instructor-info h3 {
    font-size: 1.75rem;
    margin-bottom: 1rem;
}

.instructor-bio {
    color: var(--text-secondary);
    max-width: 500px;
}

/* 方案區域 */
.pricing-card {
    background: white;
    padding: 2.5rem 1.5rem;
    border-radius: var(--radius);
    border: 2px solid var(--primary);
    text-align: center;
    position: relative;
    box-shadow: var(--shadow-lg);
}

.badge {
    position: absolute;
    top: -12px;
    left: 50%;
    transform: translateX(-50%);
    background: var(--primary);
    color: white;
    padding: 0.25rem 1rem;
    border-radius: 20px;
    font-size: 0.75rem;
    font-weight: 700;
}

.price {
    font-size: 3rem;
    font-weight: 800;
    color: var(--primary);
    margin: 1.5rem 0;
}

.benefit-list {
    list-style: none;
    text-align: left;
    margin-bottom: 2rem;
}

.benefit-list li {
    padding: 0.6rem 0;
    color: var(--text-secondary);
    display: flex;
    align-items: center;
    gap: 0.75rem;
}

.benefit-list i {
    color: var(--success);
}

.btn-large {
    width: 100%;
    padding: 1rem;
}

/* 頁尾 */
footer {
    padding: 3rem 0;
    text-align: center;
    border-top: 1px solid rgba(0, 0, 0, 0.05);
    color: var(--text-muted);
    font-size: 0.875rem;
}

/* 動畫效果 */
.animate-on-scroll {
    opacity: 0;
    transform: translateY(20px);
    transition: all 0.6s ease-out;
}

.animate-on-scroll.visible {
    opacity: 1;
    transform: translateY(0);
}

/* 響應式斷點設定 (Breakpoint System) */

/* 平板斷點 (768px 以上) */
@media (min-width: 768px) {
    .nav-links {
        display: flex;
    }
    
    .hero-content h1 {
        font-size: 3.5rem;
    }
    
    .cta-group {
        flex-direction: row;
        justify-content: center;
    }
    
    .feature-grid {
        grid-template-columns: repeat(3, 1fr);
    }
    
    .instructor-content {
        flex-direction: row;
        text-align: left;
    }
    
    .section-title {
        font-size: 2.5rem;
    }
}

/* 桌面斷點 (1200px 以上) */
@media (min-width: 1200px) {
    .hero {
        padding-top: 10rem;
    }
    
    .pricing-card {
        max-width: 450px;
        margin: 0 auto;
    }
}

/* 程式碼字體應用 */
code, pre {
    font-family: var(--font-code);
    background: var(--surface);
    padding: 0.2rem 0.4rem;
    border-radius: 4px;
}
