/* 全局樣式重置 */
* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
    font-family: 'Segoe UI', 'Microsoft JhengHei', sans-serif;
}

html {
    scroll-behavior: smooth;
}

body {
    background-color: #f5f5f5;
    color: #333;
    line-height: 1.6;
    overflow-x: hidden;
}

/* 主色調定義 - 金黃色更鮮豔 */
:root {
    --primary-gray: #2c3e50;
    --iron-gray: #5d6d7e;
    --gold: #FFC107; /* 更鮮豔的金黃色 */
    --gold-light: #FFD54F;
    --gold-dark: #FF8F00;
    --white: #ffffff;
    --light-gray: #ecf0f1;
    --dark-gray: #1a252f;
}

/* 導航欄樣式 */
header {
    position: fixed;
    top: 0;
    width: 100%;
    background-color: rgba(44, 62, 80, 0.95);
    z-index: 1000;
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.1);
    transition: all 0.3s ease;
}

.header-container {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 15px 5%;
    max-width: 1400px;
    margin: 0 auto;
}

.logo {
    width: 180px;
    height: 60px;
    background-color: var(--white);
    display: flex;
    align-items: center;
    justify-content: center;
    border-radius: 4px;
    padding: 10px;
    box-shadow: 0 2px 8px rgba(0, 0, 0, 0.2);
}

.logo img {
    max-width: 100%;
    max-height: 100%;
    object-fit: contain;
}

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

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

nav ul li a {
    color: var(--white);
    text-decoration: none;
    font-weight: 600;
    font-size: 16px;
    padding: 8px 12px;
    border-radius: 4px;
    transition: all 0.3s ease;
    position: relative;
}

nav ul li a:hover {
    color: var(--gold);
    background-color: rgba(255, 255, 255, 0.1);
}

nav ul li a::after {
    content: '';
    position: absolute;
    width: 0;
    height: 2px;
    background: var(--gold);
    bottom: 0;
    left: 50%;
    transition: all 0.3s ease;
}

nav ul li a:hover::after {
    width: 80%;
    left: 10%;
}

.mobile-menu-btn {
    display: none;
    background: none;
    border: none;
    color: var(--white);
    font-size: 24px;
    cursor: pointer;
}

/* 右側快速導航 - 只保留4個產品分類按鈕 */
.quick-nav {
    position: fixed;
    right: 20px;
    top: 50%;
    transform: translateY(-50%);
    z-index: 1001;
    display: flex;
    flex-direction: column;
    gap: 10px;
    background-color: rgba(255, 255, 255, 0.9);
    border-radius: 8px;
    padding: 15px 8px;
    box-shadow: 0 5px 15px rgba(0, 0, 0, 0.1);
    backdrop-filter: blur(5px);
}

.quick-nav-item {
    width: 45px;
    height: 45px;
    border-radius: 50%;
    background-color: var(--primary-gray);
    color: var(--white);
    display: flex;
    align-items: center;
    justify-content: center;
    text-decoration: none;
    transition: all 0.3s ease;
    position: relative;
}

.quick-nav-item:hover {
    background-color: var(--gold);
    transform: scale(1.1);
}

.quick-nav-item[data-tooltip]::before {
    content: attr(data-tooltip);
    position: absolute;
    right: 100%;
    top: 50%;
    transform: translateY(-50%);
    background-color: var(--primary-gray);
    color: white;
    padding: 6px 12px;
    border-radius: 4px;
    font-size: 14px;
    white-space: nowrap;
    opacity: 0;
    visibility: hidden;
    transition: all 0.3s ease;
    margin-right: 10px;
    pointer-events: none;
}

.quick-nav-item[data-tooltip]::after {
    content: '';
    position: absolute;
    right: 100%;
    top: 50%;
    transform: translateY(-50%);
    border: 6px solid transparent;
    border-left-color: var(--primary-gray);
    opacity: 0;
    visibility: hidden;
    transition: all 0.3s ease;
    margin-right: -2px;
    pointer-events: none;
}

.quick-nav-item:hover[data-tooltip]::before,
.quick-nav-item:hover[data-tooltip]::after {
    opacity: 1;
    visibility: visible;
}

/* Banner區域樣式 - 更新為圖片背景，文字移到上半區 */
.banner-section {
    height: 680px;
    width: 100%;
    margin-top: 90px;
    position: relative;
    overflow: hidden;
    background-image: url('image/banner.jpg');
    background-size: cover;
    background-position: center;
    background-repeat: no-repeat;
}

.banner-container {
    width: 100%;
    height: 100%;
    position: relative;
    display: flex;
    flex-direction: column;
    justify-content: flex-start; /* 從頂部開始 */
    align-items: center;
    padding-top: 50px; /* 改為50px */
}

.banner-overlay {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: linear-gradient(to bottom, rgba(44, 62, 80, 0.7) 0%, rgba(26, 37, 47, 0.5) 50%, rgba(26, 37, 47, 0.3) 100%);
    z-index: 1;
}

.banner-content {
    position: relative;
    z-index: 2;
    text-align: center;
    color: var(--white);
    padding: 0 20px;
    max-width: 900px;
    width: 100%;
    margin-top: 0; /* 移除任何可能的外邊距 */
}

.banner-content h1 {
    font-size: 3.5rem;
    margin-bottom: 25px;
    text-shadow: 2px 2px 8px rgba(0, 0, 0, 0.7);
    line-height: 1.2;
}

.banner-content p {
    font-size: 1.5rem;
    margin-bottom: 35px;
    text-shadow: 1px 1px 4px rgba(0, 0, 0, 0.5);
    line-height: 1.4;
}

.highlight {
    color: var(--gold);
    font-weight: 700;
}

/* 光影效果 - 放慢速度為8秒，從頂部開始掃描 */
.light-effect {
    position: absolute;
    top: 0;
    left: -100%;
    width: 100%;
    height: 100%;
    background: linear-gradient(90deg, transparent, rgba(255, 255, 255, 0.15), transparent);
    animation: light-sweep 8s infinite; /* 從5秒改為8秒 */
    z-index: 2;
}

@keyframes light-sweep {
    0% { left: -100%; }
    50% { left: 100%; }
    100% { left: 100%; }
}

/* 產品類別區域樣式 */
.products-section {
    padding: 80px 5%;
    background-color: var(--light-gray);
    position: relative;
}

.section-title {
    text-align: center;
    margin-bottom: 60px;
    position: relative;
}

.section-title h2 {
    font-size: 2.8rem;
    color: var(--primary-gray);
    margin-bottom: 15px;
}

.section-title p {
    color: var(--iron-gray);
    font-size: 1.2rem;
    max-width: 800px;
    margin: 0 auto;
}

.section-title::after {
    content: '';
    position: absolute;
    width: 80px;
    height: 4px;
    background-color: var(--gold);
    bottom: -20px;
    left: 50%;
    transform: translateX(-50%);
}

/* 修改：產品卡片去除超連結底線 */
.products-grid {
    display: grid;
    grid-template-columns: repeat(4, 1fr);
    gap: 30px;
    max-width: 1400px;
    margin: 0 auto;
}

.product-card {
    background-color: var(--white);
    border-radius: 8px;
    overflow: hidden;
    box-shadow: 0 6px 15px rgba(0, 0, 0, 0.1);
    transition: all 0.3s ease;
    height: 680px;
    display: flex;
    flex-direction: column;
    text-decoration: none; /* 去除超連結底線 */
    color: inherit; /* 繼承文字顏色，避免變成藍色 */
}

.product-card:hover {
    transform: translateY(-15px);
    box-shadow: 0 15px 30px rgba(0, 0, 0, 0.15);
    text-decoration: none; /* hover狀態也去除底線 */
}

.product-img {
    height: 55%;
    overflow: hidden;
}

.product-img img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    transition: all 0.5s ease;
}

.product-card:hover .product-img img {
    transform: scale(1.05);
}

.product-content {
    padding: 25px;
    flex-grow: 1;
    display: flex;
    flex-direction: column;
    background: linear-gradient(to bottom, var(--white) 0%, #f9f9f9 100%);
}

.product-content h3 {
    font-size: 1.8rem;
    color: var(--primary-gray);
    margin-bottom: 15px;
    padding-bottom: 10px;
    border-bottom: 2px solid var(--gold);
    text-decoration: none; /* 確保標題沒有底線 */
}

.product-content p {
    color: var(--iron-gray);
    margin-bottom: 20px;
    flex-grow: 1;
    text-decoration: none; /* 確保段落沒有底線 */
}

.product-tags {
    display: flex;
    flex-wrap: wrap;
    gap: 8px;
    margin-top: 15px;
}

.tag {
    background-color: var(--light-gray);
    color: var(--primary-gray);
    padding: 5px 12px;
    border-radius: 20px;
    font-size: 0.85rem;
    text-decoration: none; /* 標籤也沒有底線 */
}

/* 詳細產品區塊樣式 - 產品區塊底色對比設計 */
.product-detail-section {
    padding: 100px 5%;
    position: relative;
}

/* 氟碳塗料區塊 - 深色背景，淺色文字 */
#fluorocarbon {
    background: linear-gradient(135deg, var(--primary-gray) 0%, var(--dark-gray) 100%);
    color: var(--white);
}

#fluorocarbon .detail-header h2,
#fluorocarbon .detail-info h3,
#fluorocarbon .detail-subtitle,
#fluorocarbon .performance-section h3 {
    color: var(--white);
}

#fluorocarbon .feature-list li::before {
    color: var(--gold);
}

#fluorocarbon .detail-header h2::after {
    background-color: var(--gold);
}

/* PU壓力面漆區塊 - 淺色背景，深色文字 */
#pu-coating {
    background: linear-gradient(to bottom, #ffffff 0%, #f9f9f9 100%);
    color: var(--primary-gray);
}

#pu-coating .detail-header h2,
#pu-coating .detail-info h3,
#pu-coating .detail-subtitle,
#pu-coating .performance-section h3 {
    color: var(--primary-gray);
}

/* 其他塗料區塊 - 深色背景，淺色文字 */
#other-coatings {
    background: linear-gradient(135deg, #3a506b 0%, #1c2541 100%);
    color: var(--white);
}

#other-coatings .detail-header h2,
#other-coatings .detail-info h3,
#other-coatings .detail-subtitle,
#other-coatings .performance-section h3 {
    color: var(--white);
}

#other-coatings .feature-list li::before {
    color: var(--gold);
}

#other-coatings .detail-header h2::after {
    background-color: var(--gold);
}

/* 承包塗裝工程區塊 - 淺色背景，深色文字 */
#coating-engineering {
    background: linear-gradient(to bottom, #f8f9fa 0%, #e9ecef 100%);
    color: var(--primary-gray);
}

#coating-engineering .detail-header h2,
#coating-engineering .detail-info h3,
#coating-engineering .detail-subtitle,
#coating-engineering .performance-section h3 {
    color: var(--primary-gray);
}

.product-detail-container {
    max-width: 1400px;
    margin: 0 auto;
}

.detail-header {
    display: flex;
    align-items: center;
    margin-bottom: 50px;
}

.detail-header h2 {
    font-size: 2.5rem;
    position: relative;
    padding-bottom: 15px;
}

.detail-header h2::after {
    content: '';
    position: absolute;
    width: 100px;
    height: 4px;
    background-color: var(--gold);
    bottom: 0;
    left: 0;
}

.detail-content {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 60px;
    margin-bottom: 70px;
}

.detail-img {
    border-radius: 8px;
    overflow: hidden;
    box-shadow: 0 10px 25px rgba(0, 0, 0, 0.1);
    height: 400px;
}

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

.detail-info h3 {
    font-size: 1.8rem;
    margin-bottom: 25px;
}

.feature-list {
    list-style-type: none;
    margin-bottom: 30px;
}

.feature-list li {
    margin-bottom: 15px;
    padding-left: 30px;
    position: relative;
}

.feature-list li::before {
    content: '✓';
    position: absolute;
    left: 0;
    color: var(--gold);
    font-weight: bold;
}

.detail-subtitle {
    font-size: 1.4rem;
    margin: 25px 0 15px;
    padding-bottom: 8px;
    border-bottom: 1px solid rgba(0, 0, 0, 0.1);
}

#fluorocarbon .detail-subtitle,
#other-coatings .detail-subtitle {
    border-bottom: 1px solid rgba(255, 255, 255, 0.2);
}

/* 實績照片區域 */
.performance-section {
    margin-top: 30px;
}

.performance-section h3 {
    font-size: 1.8rem;
    margin-bottom: 30px;
    text-align: center;
}

.performance-grid {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 25px;
}

.performance-item {
    border-radius: 8px;
    overflow: hidden;
    box-shadow: 0 5px 15px rgba(0, 0, 0, 0.08);
    transition: all 0.3s ease;
    height: 250px;
}

.performance-item:hover {
    transform: translateY(-10px);
    box-shadow: 0 15px 30px rgba(0, 0, 0, 0.15);
}

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

/* 公司簡介區域 */
.about-section {
    padding: 100px 5%;
    background: linear-gradient(135deg, var(--primary-gray) 0%, var(--dark-gray) 100%);
    color: var(--white);
}

.about-container {
    max-width: 1000px;
    margin: 0 auto;
    text-align: center;
}

.about-container h2 {
    font-size: 2.8rem;
    margin-bottom: 40px;
    color: var(--white);
}

.about-container p {
    font-size: 1.2rem;
    line-height: 1.8;
    margin-bottom: 30px;
}

.gold-text {
    color: var(--gold);
    font-weight: 600;
}

/* 頁尾樣式修正 - 移除logo，放大公司名稱 */
footer {
    background-color: var(--dark-gray);
    color: var(--white);
    padding: 60px 5% 30px;
    width: 100%;
    clear: both;
}

.footer-container {
    max-width: 1400px;
    margin: 0 auto;
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 50px;
    margin-bottom: 40px;
}

.footer-col {
    display: flex;
    flex-direction: column;
}

/* 修改：移除原本的logo，改為大號文字 */
.footer-col:first-child {
    justify-content: flex-start;
}

.company-name-large {
    margin-bottom: 25px;
}

.company-name-large h2 {
    font-size: 2.5rem;
    color: var(--gold);
    margin-bottom: 10px;
    text-shadow: 2px 2px 4px rgba(0, 0, 0, 0.3);
    letter-spacing: 1px;
}

.company-tagline {
    font-size: 1.2rem;
    color: var(--light-gray);
    font-weight: 300;
    letter-spacing: 0.5px;
}

.business-items {
    display: flex;
    flex-wrap: wrap;
    gap: 10px;
    margin-top: 20px;
}

.business-item {
    background-color: rgba(255, 255, 255, 0.1);
    padding: 6px 12px;
    border-radius: 4px;
    font-size: 0.85rem;
    line-height: 1.4;
}

.qr-code {
    text-align: center;
    display: flex;
    flex-direction: column;
    align-items: center;
}

.qr-code img {
    width: 180px;
    height: 180px;
    border-radius: 8px;
    margin-bottom: 15px;
    border: 3px solid var(--gold);
    object-fit: cover;
}

.contact-info h3, .footer-col h3 {
    font-size: 1.5rem;
    margin-bottom: 25px;
    color: var(--gold);
}

.contact-info p {
    margin-bottom: 15px;
    display: flex;
    align-items: center;
    line-height: 1.5;
}

.contact-info i {
    margin-right: 10px;
    color: var(--gold);
    width: 20px;
    text-align: center;
}

.copyright {
    text-align: center;
    padding-top: 30px;
    border-top: 1px solid rgba(255, 255, 255, 0.1);
    font-size: 0.9rem;
    color: #aaa;
    width: 100%;
    clear: both;
}

/* 回到頂部按鈕 */
.back-to-top {
    position: fixed;
    bottom: 30px;
    right: 80px; /* 調整位置避免與快速導航重疊 */
    width: 50px;
    height: 50px;
    background-color: var(--gold);
    color: var(--white);
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 24px;
    cursor: pointer;
    opacity: 0;
    visibility: hidden;
    transition: all 0.3s ease;
    z-index: 999;
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.2);
}

.back-to-top.show {
    opacity: 1;
    visibility: visible;
}

.back-to-top:hover {
    background-color: var(--primary-gray);
}

/* 氟碳塗料質感效果 */
.metal-effect {
    background: linear-gradient(145deg, #e0e0e0, #ffffff);
    box-shadow: 
        0 4px 8px rgba(0, 0, 0, 0.1),
        inset 0 1px 0 rgba(255, 255, 255, 0.8);
    border: 1px solid rgba(0, 0, 0, 0.05);
}

.gold-accent {
    background-color: var(--gold);
    color: var(--white);
    padding: 10px 20px;
    border-radius: 4px;
    font-weight: 600;
    display: inline-block;
}

/* 響應式設計 */
@media (max-width: 1200px) {
    .products-grid {
        grid-template-columns: repeat(2, 1fr);
    }
    
    .performance-grid {
        grid-template-columns: repeat(2, 1fr);
    }
}

@media (max-width: 992px) {
    .detail-content {
        grid-template-columns: 1fr;
        gap: 40px;
    }
    
    .footer-container {
        grid-template-columns: repeat(2, 1fr);
        gap: 40px;
    }
    
    .banner-content h1 {
        font-size: 2.8rem;
    }
    
    .quick-nav {
        right: 10px;
        padding: 10px 5px;
    }
    
    .quick-nav-item {
        width: 40px;
        height: 40px;
        font-size: 14px;
    }
    
    .back-to-top {
        right: 70px;
    }
    
    .company-name-large h2 {
        font-size: 2.2rem;
    }
}

@media (max-width: 768px) {
    .header-container {
        padding: 15px 20px;
    }
    
    .mobile-menu-btn {
        display: block;
    }
    
    nav {
        position: fixed;
        top: 90px;
        left: 0;
        width: 100%;
        background-color: var(--primary-gray);
        padding: 20px;
        transform: translateY(-100%);
        opacity: 0;
        visibility: hidden;
        transition: all 0.3s ease;
        box-shadow: 0 5px 10px rgba(0, 0, 0, 0.1);
    }
    
    nav.active {
        transform: translateY(0);
        opacity: 1;
        visibility: visible;
    }
    
    nav ul {
        flex-direction: column;
    }
    
    nav ul li {
        margin: 0 0 15px 0;
    }
    
    .products-grid {
        grid-template-columns: 1fr;
        gap: 30px;
    }
    
    .product-card {
        height: auto;
        max-height: 700px;
    }
    
    .product-img {
        height: 350px;
    }
    
    .footer-container {
        grid-template-columns: 1fr;
        gap: 40px;
    }
    
    .footer-col {
        align-items: center;
        text-align: center;
    }
    
    .business-items {
        justify-content: center;
    }
    
    .contact-info p {
        justify-content: center;
    }
    
    .banner-content h1 {
        font-size: 2.2rem;
        margin-bottom: 20px;
    }
    
    .banner-content p {
        font-size: 1.2rem;
        margin-bottom: 25px;
    }
    
    .section-title h2 {
        font-size: 2.2rem;
    }
    
    .quick-nav {
        display: none; /* 在手機上隱藏右側導航，以免影響操作 */
    }
    
    .back-to-top {
        right: 20px;
        bottom: 20px;
    }
    
    /* 調整手機版Banner文字位置 */
    .banner-container {
        padding-top: 60px;
    }
    
    .company-name-large h2 {
        font-size: 2rem;
        text-align: center;
    }
    
    .company-tagline {
        text-align: center;
    }
}

@media (max-width: 576px) {
    .banner-section {
        height: 500px;
        margin-top: 80px;
    }
    
    .performance-grid {
        grid-template-columns: 1fr;
    }
    
    .product-img {
        height: 280px;
    }
    
    /* 進一步調整手機版Banner文字位置 */
    .banner-container {
        padding-top: 40px;
    }
    
    .banner-content h1 {
        font-size: 1.8rem;
        margin-bottom: 15px;
    }
    
    .banner-content p {
        font-size: 1rem;
        margin-bottom: 20px;
    }
    
    .gold-accent {
        padding: 8px 16px;
        font-size: 0.9rem;
    }
    
    .footer-container {
        gap: 30px;
    }
    
    .company-name-large h2 {
        font-size: 1.8rem;
    }
    
    .company-tagline {
        font-size: 1rem;
    }
}