/* style.css - 愛租屋資產管理全站共用樣式表 */

:root {
    --brand-red: #C41E3A; /* 愛租屋品牌紅 */
    --dark-gray: #333333;
    --light-bg: #F8F9FA;
}

body {
    font-family: 'Noto Sans TC', sans-serif;
    margin: 0; 
    padding: 0;
    color: var(--dark-gray);
    line-height: 1.6;
    padding-top: 120px; /* 電腦版頂部選單留白 */
}

a { 
    text-decoration: none; 
    color: inherit; 
}

/* ================= 頂部導覽列 (電腦版) ================= */
header {
    background-color: #fff;
    box-shadow: 0 2px 10px rgba(0,0,0,0.1);
    position: fixed; 
    width: 100%; 
    top: 0; 
    z-index: 1000;
    display: flex; 
    justify-content: space-between; 
    align-items: center;
    padding: 10px 50px; 
    box-sizing: border-box; 
    height: 120px;
}

.logo img { 
    height: 90px; 
}

nav ul { 
    list-style: none; 
    display: flex; 
    margin: 0; 
    padding: 0; 
}

nav ul li { 
    margin-left: 25px; 
}

nav ul li a { 
    font-weight: 700; 
    transition: color 0.3s; 
    padding: 10px; 
    display: block;
}

nav ul li a:hover { 
    color: var(--brand-red); 
}

.active { 
    color: var(--brand-red) !important; 
    border-bottom: 2px solid var(--brand-red); 
}

/* ================= 頁面 Banner 與區塊 ================= */
.page-banner {
    background: linear-gradient(rgba(0,0,0,0.6), rgba(0,0,0,0.6)), url('https://images.unsplash.com/photo-1560518883-ce09059eeffa?ixlib=rb-4.0.3&auto=format&fit=crop&w=1920&q=80') center/cover;
    height: 300px; 
    display: flex; 
    flex-direction: column; 
    justify-content: center; 
    align-items: center;
    color: #fff; 
    text-align: center;
}

.page-banner h1 { font-size: 36px; margin: 0 0 10px 0; }
.page-banner p { font-size: 18px; margin: 0; }

.container { max-width: 1200px; margin: 50px auto; padding: 0 20px; }
.section-title { text-align: center; font-size: 28px; color: var(--brand-red); margin-bottom: 40px; font-weight: 700; }

/* 表單樣式 */
.form-group { margin-bottom: 20px; }
.form-group label { display: block; font-weight: bold; margin-bottom: 5px; }
.form-control { width: 100%; padding: 10px; border: 1px solid #ccc; border-radius: 5px; box-sizing: border-box; }
.btn-submit { background-color: var(--brand-red); color: #fff; border: none; padding: 12px 30px; font-size: 16px; border-radius: 5px; cursor: pointer; display: block; width: 100%; font-weight: bold;}
.btn-submit:hover { opacity: 0.9; }

/* 頁尾 */
footer { background-color: var(--dark-gray); color: #fff; text-align: center; padding: 20px; font-size: 14px; margin-top: 50px;}

/* ================= ⭐️ 手機版極致緊湊優化（5 個選單一排全顯不用滑） ================= */
@media (max-width: 768px) {
    body { 
        padding-top: 92px; /* 留白調小，適應緊湊的 Header */
    }

    header {
        flex-direction: column;
        height: auto;
        padding: 6px 4px;   /* 邊框間距縮至極小 */
        position: fixed;
        top: 0; 
        left: 0; 
        width: 100%;
        box-sizing: border-box;
        z-index: 1000;
        background-color: #fff;
    }

    .logo img { 
        height: 42px;       /* 微調 Logo 高度，釋放空間 */
    }
    
    nav {
        width: 100%;
        overflow: hidden;   /* 關閉捲軸，強制全顯 */
    }

    nav ul {
        display: flex;
        flex-wrap: nowrap;  /* 強制單排不折行 */
        justify-content: space-between;
        align-items: center;
        margin: 4px 0 2px 0;
        padding: 0;
        list-style: none;
        width: 100%;
        box-sizing: border-box;
    }

    nav ul li {
        margin: 0;
        padding: 0;
        flex: 1;            /* 5 個選項均分 100% 畫面寬度 */
        text-align: center;
    }

    nav ul li a {
        font-size: 11.5px;  /* 字級調為 11.5px */
        padding: 4px 1px;   /* 左右間距縮至 1px */
        display: block;
        white-space: nowrap;
        letter-spacing: -0.5px; /* ⭐️ 字距微縮 -0.5px，精準省下空間 */
    }

    .page-banner { 
        height: 200px; 
    }
}