/* 全局重置與基調 */
:root {
    --primary: #e63946;    /* 活力紅：門市招牌字體色 */
    --secondary: #1d3557;  /* 企業藍 */
    --accent: #ffb703;     /* 亮黃色 */
    --dark: #2b2d42;
    --light: #f8f9fa;
    --border: #e0e0e0;
}

* { margin: 0; padding: 0; box-sizing: border-box; font-family: 'PingFang HK', 'Helvetica Neue', Arial, sans-serif; }
body { color: var(--dark); background: #ffffff; line-height: 1.6; padding-top: 80px; }
.container { max-width: 1200px; margin: 0 auto; padding: 0 20px; }
.section-padding { padding-top: 50px; padding-bottom: 70px; }
.text-center { text-align: center; }
.mt-10 { margin-top: 10px; }

/* 頂部導航 */
header { 
    background: #1a1a1a; /* 💡 這裡修改為與底部 Footer 一模一樣的深黑色 */
    position: fixed; 
    top: 0; 
    width: 100%; 
    z-index: 1000; 
    box-shadow: 0 2px 10px rgba(0,0,0,0.15); /* 輕微加深陰影，讓深色頂欄更有層次感 */
}
.nav-container { display: flex; justify-content: space-between; align-items: center; padding: 12px 20px; max-width: 1200px; margin: 0 auto; }
.logo-area { display: flex; align-items: center; text-decoration: none; color: #fff; }
.site-logo { height: 45px; margin-right: 12px; object-fit: contain; }
.logo-text h1 { font-size: 18px; font-weight: bold; letter-spacing: 0.5px; }
.logo-text span { font-size: 10px; color: #bdc3c7; display: block; font-weight: 300; }
nav ul { display: flex; list-style: none; }
nav ul li { margin-left: 15px; }
nav ul li a { color: #fff; text-decoration: none; font-size: 14px; padding: 8px 14px; border-radius: 4px; transition: 0.3s; }
nav ul li a:hover, nav ul li a.active { background: var(--primary); }

/* 主頁 Banner 封面配圖核心配置（還原原圖色彩） */
.hero-banner {
    /* 這裡留空，徹底停用舊樣式，防止干擾原圖 */
}

/* 按鈕樣式 */
.btn { display: inline-block; padding: 12px 28px; border-radius: 25px; font-weight: bold; text-decoration: none; cursor: pointer; transition: 0.3s; border: none; font-size: 14px; }
.btn-primary { background: var(--primary); color: #fff; }
.btn-primary:hover { background: #c92a36; }
.btn-outline { background: transparent; border: 2px solid #fff; color: #fff; }
.btn-outline:hover { background: #fff; color: var(--secondary); }

/* 核心標題 */
.section-title { font-size: 28px; color: var(--secondary); margin-bottom: 8px; position: relative; padding-bottom: 12px; display: inline-block; }
.section-title::after { content: ''; position: absolute; bottom: 0; left: 0; width: 50px; height: 4px; background: var(--primary); }
.section-subtitle { color: #7f8c8d; font-size: 15px; margin-bottom: 40px; }

/* 網格系統 */
.grid-3 { display: grid; grid-template-columns: repeat(auto-fit, minmax(300px, 1fr)); gap: 30px; }
.feature-card { background: #fff; padding: 30px; border-radius: 8px; box-shadow: 0 4px 20px rgba(0,0,0,0.05); border-top: 4px solid var(--primary); text-align: center; }
.icon-text-badge { font-size: 11px; font-weight: bold; color: var(--primary); background: #fdf2f4; padding: 4px 12px; display: inline-block; border-radius: 4px; margin-bottom: 15px; letter-spacing: 1px; }
.feature-card h3 { color: var(--secondary); margin-bottom: 12px; font-size: 18px; }
.feature-card p { font-size: 14px; color: #555; text-align: justify; margin-bottom: 15px; }
.more-link { color: var(--primary); text-decoration: none; font-weight: bold; font-size: 14px; }

/* 關於我們 */
.about-grid { display: grid; grid-template-columns: 1.2fr 0.8fr; gap: 40px; }
.about-content-text h3 { color: var(--secondary); margin: 20px 0 10px 0; }
.about-content-text p { font-size: 15px; color: #333; margin-bottom: 15px; text-align: justify; }
.info-box-statutory { background: var(--light); padding: 25px; border-radius: 8px; border-left: 4px solid var(--secondary); }
.info-box-statutory h3 { color: var(--secondary); margin-bottom: 15px; font-size: 16px; }
.info-table { width: 100%; border-collapse: collapse; font-size: 13px; }
.info-table td { padding: 10px; border-bottom: 1px solid var(--border); vertical-align: top; }
.en-sub { font-size: 11px; color: #7f8c8d; display: block; }
.highlight-code { font-family: monospace; background: #eef2f7; padding: 2px 6px; font-weight: bold; color: var(--primary); border-radius: 3px; }

/* 產品中心頁面 */
.filter-tabs { display: flex; justify-content: center; gap: 10px; margin-bottom: 35px; border-bottom: 2px solid var(--border); padding-bottom: 10px; }
.tab-btn { padding: 8px 20px; background: none; border: none; font-size: 15px; font-weight: bold; cursor: pointer; color: #7f8c8d; }
.tab-btn.active { color: var(--primary); border-bottom: 3px solid var(--primary); margin-bottom: -13px; }
.products-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(280px, 1fr)); gap: 25px; }
.product-item { border: 1px solid var(--border); border-radius: 8px; overflow: hidden; background: #fff; transition: 0.3s; }
.product-item:hover { transform: translateY(-5px); box-shadow: 0 6px 20px rgba(0,0,0,0.1); }
/* 💡 全新重構：完美適應縱向長圖、產品詳情海報，確保100%全圖顯示不裁切 */
.product-img-holder { 
    width: 100%;
    height: auto;          /* 💡 徹底刪除原先的 210px 限制，改為由圖片高度自動撐開 */
    background: #ffffff;   /* 設為純白底色，與海報邊緣完美融合 */
    overflow: hidden; 
    display: block;
}

.product-img-holder img { 
    width: 100%; 
    height: auto;          /* 💡 強制圖片保持原本的長寬比例縮放，絕對不拉伸、不變形 */
    display: block;
    object-fit: contain;   /* 完整包含整張原圖的所有細節 */
}
.product-details { padding: 18px; }
.tag { font-size: 11px; padding: 2px 7px; font-weight: bold; border-radius: 3px; display: inline-block; margin-bottom: 8px; }
.tag-hot { background: var(--accent); color: #000; }
.tag-spec { background: var(--secondary); color: #fff; }
.tag-normal { background: #eef2f7; color: var(--dark); }
.product-details h4 { font-size: 16px; margin-bottom: 8px; color: var(--secondary); }
.product-details .desc { font-size: 13px; color: #666; text-align: justify; }

/* 新聞頁面時程表 */
.news-timeline { display: flex; flex-direction: column; gap: 25px; }
.news-block { display: grid; grid-template-columns: 120px 1fr; gap: 20px; background: var(--light); padding: 25px; border-radius: 8px; border-left: 5px solid var(--secondary); }
.news-meta { display: flex; flex-direction: column; align-items: center; justify-content: center; background: var(--secondary); color: #fff; border-radius: 4px; padding: 10px; height: 80px; text-align: center; }
.news-meta .day { font-size: 16px; font-weight: bold; letter-spacing: 0.5px; }
.news-meta .ym { font-size: 10px; opacity: 0.8; margin-top: 2px; }
.news-body h3 { color: var(--secondary); margin-bottom: 8px; font-size: 17px; }
.news-body p { font-size: 14px; color: #444; text-align: justify; }

/* 聯繫我們佈局 */
.contact-layout { display: grid; grid-template-columns: 1fr 1fr; gap: 40px; }
.c-card { background: #fff; padding: 22px; margin-bottom: 15px; border-left: 4px solid var(--primary); box-shadow: 0 2px 10px rgba(0,0,0,0.04); border-radius: 0 8px 8px 0; }
.c-card h4 { color: var(--secondary); margin-bottom: 8px; font-size: 15px; }
.c-card p { font-size: 14px; color: #444; }
.tip-text { font-size: 12px; color: #7f8c8d; margin-top: 5px; }
.contact-form-area { background: var(--light); padding: 30px; border-radius: 8px; }
.contact-form-area h3 { color: var(--secondary); margin-bottom: 20px; }
.f-group { margin-bottom: 15px; }
.f-group label { display: block; font-size: 13px; font-weight: bold; margin-bottom: 5px; color: var(--dark); }
.f-group input, .f-group select, .f-group textarea { width: 100%; padding: 10px; border: 1px solid #ccc; border-radius: 4px; font-size: 14px; background: #fff; }

/* 頁腳 */
footer { background: #1a1a1a; color: #fff; padding: 40px 20px; margin-top: 60px; border-top: 3px solid var(--primary); }
.footer-container { max-width: 1200px; margin: 0 auto; display: grid; grid-template-columns: repeat(auto-fit, minmax(250px, 1fr)); gap: 30px; font-size: 13px; }
.footer-col h4 { color: var(--primary); font-size: 15px; margin-bottom: 15px; }
.footer-links a { color: #bbb; text-decoration: none; display: block; margin-bottom: 8px; }
.footer-links a:hover { color: #fff; }
.footer-bottom { text-align: center; font-size: 11px; color: #666; margin-top: 30px; padding-top: 20px; border-top: 1px solid #2c2c2c; }

/* 屏幕響應式優化 */
@media (max-width: 768px) {
    body { padding-top: 70px; }
    .nav-container { flex-direction: column; text-align: center; }
    nav ul { margin-top: 10px; }
    nav ul li { margin: 0 5px; }
    .hero-content h2 { font-size: 26px; }
    .about-grid, .contact-layout { grid-template-columns: 1fr; }
    .news-block { grid-template-columns: 1fr; border-left: none; border-top: 5px solid var(--secondary); }
    .news-meta { height: auto; padding: 5px; flex-direction: row; gap: 10px; }
}
