/* ==========================================
   1. 全域重設與設計系統變數
   ========================================== */
* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
    font-family: "Noto Sans TC", sans-serif;
}

:root {
    --bg-main: #111214;
    --bg-sub: #1e2024;
    --primary: #00dc64; /* Webtoon 綠 */
    --text-main: #ffffff;
    --text-sub: #a0a5b0;
}

body {
    background-color: var(--bg-main);
    color: var(--text-main);
    line-height: 1.6;
}


/* ==========================================
   2. 導覽列 - 運用 Flex
   ========================================== */
.navbar {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 20px 5%;
    background-color: var(--bg-main);
    border-bottom: 1px solid #2a2c32;
    position: sticky;
    top: 0;
    z-index: 100;
}

.navbar .logo {
    font-size: 1.5rem;
    font-weight: 700;
    color: var(--primary);
    letter-spacing: 1px;
}

.nav-links {
    display: flex;
    list-style: none;
    gap: 25px;
}

.nav-links a {
    color: var(--text-main);
    text-decoration: none;
    font-weight: 500;
    transition: color 0.3s;
}

.nav-links a:hover {
    color: var(--primary);
}

/* ==========================================
   3. 主視覺區 - 運用 Block
   ========================================== */
.hero-section {
    display: block;
    padding: 100px 5%;
    text-align: center;
    background: linear-gradient(180deg, rgba(24,26,30,0.8) 0%, rgba(17,18,20,1) 100%), 
                url('https://images.plurk.com/7qwO8snBL2woNxXisDPELh.jpg ') no-repeat center/cover;
}

.hero-content {
    max-width: 800px;
    margin: 0 auto;
}

.badge {
    background-color: var(--bg-sub);
    color: var(--primary);
    padding: 6px 16px;
    border-radius: 20px;
    font-size: 0.85rem;
    font-weight: 700;
    border: 1px solid var(--primary);
    display: inline-block;
    margin-bottom: 20px;
}

.hero-section h1 {
    font-size: 2.8rem;
    margin-bottom: 20px;
    font-weight: 700;
}

.hero-section p {
    color: var(--text-sub);
    font-size: 1.1rem;
    margin-bottom: 40px;
}

.btn-primary {
    background-color: var(--primary);
    color: #000;
    padding: 12px 30px;
    text-decoration: none;
    font-weight: 700;
    border-radius: 6px;
    transition: transform 0.2s, background-color 0.3s;
    display: inline-block;
}

.btn-primary:hover {
    transform: translateY(-3px);
    background-color: #00c458;
}

/* ==========================================
   4. 作品看板區 - 運用 Grid
   ========================================== */
.works-section {
    padding: 80px 5%;
    background-color: var(--bg-sub);
}

.section-title {
    font-size: 2rem;
    margin-bottom: 40px;
    position: relative;
    padding-left: 15px;
}

.section-title::before {
    content: '';
    position: absolute;
    left: 0;
    top: 10%;
    height: 80%;
    width: 5px;
    background-color: var(--primary);
}

.works-grid {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 30px;
}

.work-card {
    background-color: var(--bg-main);
    border-radius: 8px;
    overflow: hidden;
    transition: transform 0.3s;
    border: 1px solid #2a2c32;
}

.work-card:hover {
    transform: translateY(-8px);
    border-color: var(--primary);
}

.card-img {
    height: 350px;
    background-size: cover;
    background-position: center;
}

/* 作品卡片按鍵與內容排版 (Flex 佈局) */
.card-info {
    padding: 20px;
    display: flex;
    flex-direction: column;
}

.genre {
    color: var(--primary);
    font-size: 0.8rem;
    font-weight: 700;
    display: block;
    margin-bottom: 5px;
}

.card-info h3 {
    font-size: 1.25rem;
    margin-bottom: 8px;
}

.card-info p {
    color: var(--text-sub);
    font-size: 0.9rem;
}

.btn-read {
    display: inline-block;
    text-align: center;
    background-color: transparent;
    color: var(--primary);
    border: 1px solid var(--primary);
    padding: 8px 15px;
    margin-top: 15px;
    text-decoration: none;
    font-size: 0.9rem;
    font-weight: 700;
    border-radius: 4px;
    transition: all 0.3s ease;
}

.btn-read:hover {
    background-color: var(--primary);
    color: #111214;
    transform: translateY(-2px);
}

/* ==========================================
   5. 關於我與聯絡資訊 (Flex 左右雙欄高質感排版)
   ========================================== */
.about-section {
    padding: 90px 5%;
    background-color: var(--bg-main);
}

.about-container {
    background-color: var(--bg-sub);
    padding: 50px;
    border-radius: 12px;
    border: 1px solid #2a2c32;
    display: flex;
    justify-content: space-between;
    gap: 60px;
}

.about-bio {
    flex: 1.2;
}

.author-header {
    display: flex;
    align-items: center;
    gap: 20px;
    margin-bottom: 20px;
}

.author-avatar {
    width: 80px;
    height: 80px;
    border-radius: 50%;
    background-size: cover;
    background-position: center;
    border: 2px solid var(--primary);
}

.author-title h2 {
    font-size: 1.8rem;
    font-weight: 700;
}

.sub-tag {
    font-size: 0.85rem;
    color: var(--primary);
    background-color: rgba(0, 220, 100, 0.1);
    padding: 3px 10px;
    border-radius: 4px;
    display: inline-block;
    margin-top: 5px;
}

.bio-text {
    color: var(--text-sub);
    font-size: 1.05rem;
    line-height: 1.7;
}

.about-contact {
    flex: 0.8;
    background-color: rgba(17, 18, 20, 0.5);
    padding: 30px;
    border-radius: 8px;
    border: 1px solid #2a2c32;
}

.about-contact h3 {
    font-size: 1.3rem;
    margin-bottom: 15px;
    color: var(--text-main);
}

.contact-notice {
    color: var(--text-sub);
    font-size: 0.9rem;
    margin-bottom: 20px;
}

.contact-list {
    list-style: none;
    display: flex;
    flex-direction: column;
    gap: 18px;
}

.contact-list li {
    display: flex;
    align-items: center;
    gap: 15px;
}

.contact-list .icon {
    font-size: 1.4rem;
    background-color: var(--bg-main);
    width: 40px;
    height: 40px;
    display: flex;
    align-items: center;
    justify-content: center;
    border-radius: 8px;
}

.info-content {
    display: flex;
    flex-direction: column;
}

.info-content label {
    font-size: 0.75rem;
    color: var(--text-sub);
    text-transform: uppercase;
    letter-spacing: 0.5px;
}

.info-content a, .info-content span {
    color: var(--text-main);
    text-decoration: none;
    font-weight: 500;
    font-size: 1rem;
    transition: color 0.3s;
}

.info-content a:hover {
    color: var(--primary);
}

/* ==========================================
   6. 頁尾
   ========================================== */
.footer {
    text-align: center;
    padding: 30px;
    color: var(--text-sub);
    font-size: 0.85rem;
    border-top: 1px solid #2a2c32;
}

/* ==========================================
   7. 響應式網頁設計 (RWD) - 支援平板與手機端 (含375px)
   ========================================== */
@media (max-width: 900px) {
    /* 關於我：雙欄轉單欄垂直排列 */
    .about-container {
        flex-direction: column;
        gap: 40px;
        padding: 30px 20px;
    }
    
    .about-bio, .about-contact {
        flex: none;
        width: 100%;
    }
}

@media (max-width: 768px) {
    /* 導覽列改為上下排列 */
    .navbar {
        flex-direction: column;
        gap: 15px;
        padding: 15px;
    }
    
    .nav-links {
        gap: 15px;
    }

    /* 主視覺文字縮小 */
    .hero-section h1 {
        font-size: 2rem;
    }

    /* 作品集 Grid 轉為單欄 */
    .works-grid {
        grid-template-columns: 1fr;
        gap: 20px;
    }
    
    .card-img {
        height: 300px;
    }
}