@charset "UTF-8";
/* TUK產品比較表格樣式 - 基於靜態頁面完整還原 */

/* WordPress主題樣式重置 - 確保不被主題樣式干擾 */
#compareTable,
#compareTable *,
#comparedEQ,
#comparedEQ * {
    box-sizing: border-box !important;
}

/* WordPress主題兼容性樣式 - 溫和的重置 */
#compareTable {
    font-family: "tt-hei-chs-variable", sans-serif !important;
    box-sizing: border-box !important;
}

#compareTable * {
    box-sizing: border-box !important;
}

/* 確保容器不被主題限制 */
.entry-content #compareTable,
.post-content #compareTable,
.page-content #compareTable,
article #compareTable {
    max-width: none !important;
    width: 100% !important;
    margin: 50px auto !important;
}

/* 全域基本樣式重置 */
html, body {
    margin: 0; 
    padding: 0; 
    width: 100%; 
    height: 100%; 
    background: #fff; 
    font-family: "tt-hei-chs-variable", sans-serif; 
    font-weight: 400; 
    font-size: 16px; 
    line-height: 24px;
}

/* 清除列表樣式 */
li, ul, ol {
    padding: 0; 
    margin: 0; 
    list-style: none;
}

/* 統一連結樣式 */
a {
    text-decoration: none; 
    color: #333;
}

/* 圖片基本樣式 */
img {
    padding: 0; 
    margin: 0;
}

/* 表單元素樣式重置 */
input, select {
    appearance: none; 
    outline: none; 
    box-shadow: none; 
    border: none;
}

/* 主要比較表格容器樣式 - 垂直排列，居中對齊 */
#compareTable {
    display: flex; 
    width: 100%; 
    align-items: center; 
    gap: 30px; 
    margin: 50px auto; 
    padding-bottom: 100px; 
    font-size: 14px; 
    line-height: 18px; 
    flex-direction: column;
}

/* 比較表格內的連結樣式重置 */
#compareTable a {
    text-decoration: none;
}

/* 主標題樣式 */
#compareTable h1 {
    font-weight: 400;
}

/* 產品類別導航列樣式 - 圓角設計 */
.EQNav {
    display: flex; 
    border-radius: 12px; 
    overflow: hidden; 
    width: auto;
}

/* 導航列表項目樣式 */
.EQNav li {
    display: block;
}

/* 導航連結樣式 - 按鈕外觀設計 */
.EQNav li a {
    display: flex; 
    align-items: center; 
    justify-content: center; 
    padding: 15px 50px; 
    font-size: 1.1em; 
    line-height: 1.2em; 
    color: #ccc; 
    background: #999;
}

/* 選中狀態的導航樣式 - 突出顯示當前分類 */
.EQNav li.on a, 
.EQNav li.on:hover a {
    color: #000; 
    background: #eee;
}

/* 滑鼠懸停效果 */
.EQNav li:hover a {
    background: #aaa; 
    color: #fff;
}

/* 產品比較主容器 - 響應式網格佈局 */
#comparedEQ {
    width: 98%; 
    max-width: 1600px; 
    display: flex; 
    flex-direction: column; 
    gap: 40px; 
    position: relative;
}

/* 單行比較項目樣式 - 4欄網格佈局 */
#comparedEQ .singleLineEQ {
    display: grid; 
    grid-template-columns: repeat(4, 1fr); 
    gap: 20px; 
    width: 100%;
}

/* 置頂固定樣式 - 選擇器區域固定在頂部 */
#comparedEQ .singleLineEQ.sticky {
    position: sticky; 
    top: 0; 
    background: #fff;
    z-index: 10;
}

/* 選擇器輸入區域樣式 */
#comparedEQ .singleLineEQ .selectInput {
    padding: 15px 0;
}

/* 下拉選單樣式 - 圓角邊框設計 */
#comparedEQ .singleLineEQ select {
    width: 100%;
    color: #999; 
    border: 1px solid #999; 
    border-radius: 12px;
    background: #fff;
    font-size: 14px;
}

/* 產品圖片容器樣式 - 響應式圖片 */
.singleLineEQ .EQIMG img {
    width: 100%; 
    height: auto;
    border-radius: 8px;
}

/* 主要分類標題樣式 - 大字體，跨所有欄位 */
.singleLineEQ .EQLevel1 {
    font-size: 2.5em; 
    line-height: 1.5em; 
    color: #666; 
    font-weight: 400; 
    padding-top: 50px; 
    border-bottom: 1px solid #aaa; 
    grid-column: 1 / -1;
}

/* 產品規格項目樣式 - 垂直居中對齊 */
.singleLineEQ .EQEntry {
    display: flex; 
    flex-direction: column; 
    align-items: center; 
    gap: 5px;
}

/* 規格項目標題樣式 - 淺色字體 */
.singleLineEQ .EQEntry .title {
    color: #999;
    text-align: center;
}

/* 規格項目內容樣式 - 突出顯示 */
.singleLineEQ .EQEntry .content {
    font-size: 1.5em; 
    line-height: 1.2em;
    text-align: center;
}

/* 產品資訊描述樣式 - 文字對齊 */
.singleLineEQ .EQInfos {
    padding: 0 15px; 
    text-align: justify; 
    font-size: 1.2em; 
    line-height: 1.5em;
}

/* 副標題樣式 - 大字體，粗體 */
.singleLineEQ .EQsubtitle {
    display: flex; 
    flex-direction: column; 
    align-items: center; 
    justify-content: center; 
    font-size: 3em; 
    line-height: 1.2em; 
    font-weight: 900; 
    margin-bottom: -30px;
}

/* 載入狀態樣式 */
.tuk-loading {
    opacity: 0.6;
    pointer-events: none;
}

.tuk-loading::after {
    content: '';
    position: absolute;
    top: 50%;
    left: 50%;
    width: 20px;
    height: 20px;
    margin: -10px 0 0 -10px;
    border: 2px solid #f3f3f3;
    border-top: 2px solid #3498db;
    border-radius: 50%;
    animation: tuk-spin 1s linear infinite;
}

@keyframes tuk-spin {
    0% { transform: rotate(0deg); }
    100% { transform: rotate(360deg); }
}

/* 錯誤訊息樣式 */
.tuk-error {
    color: #e74c3c;
    text-align: center;
    padding: 20px;
    background: #fdf2f2;
    border: 1px solid #e74c3c;
    border-radius: 4px;
    margin: 10px 0;
}

/* 成功訊息樣式 */
.tuk-success {
    color: #27ae60;
    text-align: center;
    padding: 20px;
    background: #f2fdf2;
    border: 1px solid #27ae60;
    border-radius: 4px;
    margin: 10px 0;
}

/* 響應式設計 - 中等螢幕 (平板) */
@media screen and (max-width: 1140px) {
    /* 調整為3欄佈局 */
    #comparedEQ .singleLineEQ {
        grid-template-columns: repeat(3, 1fr);
    }
    
    /* 隱藏第四個產品欄位 */
    #comparedEQ .EQ4 {
        display: none;
    }
    
    /* 調整主標題跨欄 */
    .singleLineEQ .EQLevel1 {
        grid-column: 1 / 4;
    }
}

/* 響應式設計 - 小螢幕 (手機) */
@media screen and (max-width: 900px) {
    /* 縮小字體和間距 */
    #compareTable {
        font-size: 12px; 
        line-height: 1.2em; 
        width: 98%;
        margin: 20px auto;
        gap: 20px;
    }
    
    /* 調整為2欄佈局 */
    #comparedEQ .singleLineEQ {
        grid-template-columns: repeat(2, 1fr);
        gap: 10px;
    }
    
    /* 隱藏第三和第四個產品欄位 */
    #comparedEQ .EQ3,
    #comparedEQ .EQ4 {
        display: none;
    }
    
    /* 縮小副標題字體 */
    .singleLineEQ .EQsubtitle {
        font-size: 2em;
        margin-bottom: -20px;
    }
    
    /* 調整主標題跨欄 */
    .singleLineEQ .EQLevel1 {
        grid-column: 1 / 3;
        font-size: 2em;
        padding-top: 30px;
    }
    
    /* 調整導航樣式 */
    .EQNav li a {
        padding: 10px 30px;
        font-size: 1em;
    }
    
    /* 調整規格項目內容大小 */
    .singleLineEQ .EQEntry .content {
        font-size: 1.2em;
    }
    
    /* 調整產品描述 */
    .singleLineEQ .EQInfos {
        font-size: 1em;
        padding: 0 10px;
    }
}

/* 超小螢幕優化 */
@media screen and (max-width: 480px) {
    #compareTable {
        margin: 10px auto;
        padding-bottom: 50px;
    }
    
    #comparedEQ {
        gap: 20px;
    }
    
    .EQNav {
        flex-direction: column;
        width: 100%;
    }
    
    .EQNav li {
        width: 100%;
    }
    
    .EQNav li a {
        padding: 15px;
        text-align: center;
    }
    
    .singleLineEQ .EQLevel1 {
        font-size: 1.5em;
        padding-top: 20px;
    }
    
    .singleLineEQ .EQsubtitle {
        font-size: 1.5em;
        margin-bottom: -15px;
    }
}

/* 特殊樣式：配件狀態 */
.singleLineEQ .EQEntry .content {
    position: relative;
}

.singleLineEQ .EQEntry .content[data-field*="steel_"],
.singleLineEQ .EQEntry .content[data-field*="handle"],
.singleLineEQ .EQEntry .content[data-field*="rack"],
.singleLineEQ .EQEntry .content[data-field*="storage"] {
    font-weight: bold;
}

/* 有配件的樣式 */
.singleLineEQ .EQEntry .content:contains("●") {
    color: #27ae60;
}

/* 沒有配件的樣式 */
.singleLineEQ .EQEntry .content:contains("X") {
    color: #e74c3c;
}

/* 選配的樣式 */
.singleLineEQ .EQEntry .content:contains("選配") {
    color: #f39c12;
}

/* 群組標題樣式 */
.group-header {
    background: linear-gradient(135deg, #2c3e50 0%, #34495e 100%) !important;
}

.group-title {
    color: white !important;
    font-weight: bold !important;
    font-size: 16px !important;
    text-align: center !important;
    padding: 12px 15px !important;
    text-transform: uppercase;
    letter-spacing: 1px;
    border: none !important;
}

/* 子群組標題樣式 */
.subgroup-header {
    background: linear-gradient(135deg, #3498db 0%, #2980b9 100%) !important;
}

.subgroup-title {
    color: white !important;
    font-weight: 600 !important;
    font-size: 14px !important;
    text-align: center !important;
    padding: 8px 12px !important;
    border: none !important;
    position: relative;
}

.subgroup-title:before {
    content: "▶";
    margin-right: 8px;
    font-size: 12px;
    opacity: 0.8;
}

/* 響應式：子群組在小螢幕上的樣式 */
@media screen and (max-width: 900px) {
    .group-title {
        font-size: 14px !important;
        padding: 10px 12px !important;
    }
    
    .subgroup-title {
        font-size: 12px !important;
        padding: 6px 10px !important;
    }
    
    .subgroup-title:before {
        font-size: 10px;
        margin-right: 6px;
    }
}

/* 打印樣式 */
@media print {
    #compareTable {
        font-size: 12px;
        margin: 0;
        padding: 0;
    }
    
    .EQNav {
        display: none;
    }
    
    #comparedEQ .singleLineEQ.sticky {
        position: static;
    }
    
    .singleLineEQ .EQLevel1 {
        font-size: 1.5em;
        page-break-before: avoid;
    }
    
    .singleLineEQ .EQIMG img {
        max-height: 200px;
        object-fit: contain;
    }
    
    /* 打印時的群組樣式 */
    .group-header,
    .subgroup-header {
        background: #333 !important;
        -webkit-print-color-adjust: exact;
        color-adjust: exact;
    }
}

/* 產品切換載入動畫和過場效果 */
.tuk-page-loading {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: rgba(255, 255, 255, 0.95);
    z-index: 9999;
    display: flex;
    align-items: center;
    justify-content: center;
    flex-direction: column;
    backdrop-filter: blur(2px);
}

.tuk-loading-spinner {
    width: 50px;
    height: 50px;
    border: 4px solid #f3f3f3;
    border-top: 4px solid #007cba;
    border-radius: 50%;
    animation: tuk-page-spin 1s linear infinite;
    margin-bottom: 20px;
}

@keyframes tuk-page-spin {
    0% { transform: rotate(0deg); }
    100% { transform: rotate(360deg); }
}

.tuk-loading-text {
    font-size: 16px;
    color: #666;
    font-weight: 500;
    text-align: center;
}

.tuk-loading-subtext {
    font-size: 14px;
    color: #999;
    margin-top: 8px;
    text-align: center;
}

/* 產品切換載入狀態 */
.tuk-switching {
    opacity: 0.7;
    pointer-events: none;
    transition: opacity 0.3s ease;
}

.tuk-switching .selectInput select {
    background-color: #f8f9fa;
    cursor: wait;
}

/* Skeleton Loading 效果 */
.tuk-skeleton {
    background: linear-gradient(90deg, #f0f0f0 25%, #e0e0e0 50%, #f0f0f0 75%);
    background-size: 200% 100%;
    animation: tuk-skeleton-loading 1.5s infinite;
    border-radius: 4px;
}

@keyframes tuk-skeleton-loading {
    0% { background-position: 200% 0; }
    100% { background-position: -200% 0; }
}

.tuk-skeleton-product-image {
    width: 100%;
    height: 200px;
    border-radius: 8px;
    margin-bottom: 10px;
}

.tuk-skeleton-text {
    height: 20px;
    border-radius: 4px;
    margin-bottom: 8px;
}

.tuk-skeleton-text.short {
    width: 60%;
}

.tuk-skeleton-text.medium {
    width: 80%;
}

.tuk-skeleton-text.long {
    width: 100%;
}

/* 平滑過場效果 */
.tuk-fade-out {
    opacity: 0;
    transition: opacity 0.3s ease-out;
}

.tuk-fade-in {
    opacity: 1;
    transition: opacity 0.3s ease-in;
}

/* 選擇器載入指示器 */
.selectInput.loading {
    position: relative;
}

.selectInput.loading::after {
    content: '';
    position: absolute;
    right: 30px;
    top: 50%;
    transform: translateY(-50%);
    width: 16px;
    height: 16px;
    border: 2px solid #f3f3f3;
    border-top: 2px solid #007cba;
    border-radius: 50%;
    animation: tuk-page-spin 1s linear infinite;
    pointer-events: none;
}

/* 響應式載入動畫 */
@media (max-width: 768px) {
    .tuk-loading-spinner {
        width: 40px;
        height: 40px;
    }
    
    .tuk-loading-text {
        font-size: 14px;
    }
    
    .tuk-loading-subtext {
        font-size: 12px;
    }
} 