﻿:root {
    /* 與你目前列表/首頁同色系：偏暖、但不悶 */
    --bg: #faf8f4;
    --card: #ffffff;
    --card2: rgba(255,255,255,.55);
    --text: #121212;
    --muted: #6b6b6b;
    --border: rgba(18,18,18,.10);
    --border-soft: rgba(18,18,18,.06);
    --shadow: 0 10px 30px rgba(18,18,18,.06);
    --radius: 16px;
    --radius-sm: 12px;
    --brand: #111;
    --brand2: #1f6feb;
    --max: 1440px;
    --gutter: 32px;
}

/* [2026-09-09] 目的：修正五號店商品頁共用提示視窗的關閉圖示被舊版 ContentStyle1.css 顯示成問號。 */
body #AlertPopup.PopupWindow .PopupTitleTr #PopupClose::before {
    content: "×" !important;
}

* {
    box-sizing: border-box;
}

html, body {
    height: 100%;
}

body {
    margin: 0;
    font-family: ui-sans-serif, system-ui, -apple-system, "Noto Sans TC", "PingFang TC", "Microsoft JhengHei", sans-serif;
    color: var(--text);
    background: var(--bg);
}

.container {
    max-width: var(--max);
    margin: 0 auto;
    padding: 0 var(--gutter);
}

@media (max-width: 720px) {
    :root {
        /* [2026-04-09] 目的：手機 Detail 主內容加寬；仍保留貼邊前呼吸空間 */
        --gutter: 10px;
    }
    /* [2026-04-09] 目的：ContentStyle1 晚載入的 .page 左右 padding 與 .container 疊加過窄，Detail 專用取消橫向內距 */
    .section > .container > .page {
        padding-left: 0;
        padding-right: 0;
        max-width: none;
    }
}

/* ===== Header ===== */
.header {
    position: sticky;
    top: 0;
    z-index: 50;
    background: rgba(250,248,244,.82);
    backdrop-filter: blur(10px);
    border-bottom: 1px solid var(--border-soft);
}

.header__in {
    display: flex;
    align-items: center;
    justify-content: space-between;
    height: 64px;
}

.brand {
    display: flex;
    align-items: center;
    gap: 10px;
    font-weight: 900;
}

.brand__mark {
    width: 28px;
    height: 28px;
    border-radius: 9px;
    background: rgba(0,0,0,.10);
}

.nav {
    display: flex;
    align-items: center;
    gap: 18px;
    color: var(--muted);
    font-size: 13px;
}

    .nav a {
        color: inherit;
        text-decoration: none;
       /* padding: 8px 10px;*/
        border-radius: 10px;
    }

        .nav a:hover {
            background: rgba(0,0,0,.04);
            color: var(--text);
        }

.header__actions {
    display: flex;
    align-items: center;
    gap: 10px;
}

/* ===== Buttons ===== */
.btn {
    border: 1px solid var(--border-soft);
    background: rgba(255,255,255,.35);
    color: var(--text);
    padding: 10px 14px;
    border-radius: 12px;
    font-weight: 800;
    cursor: pointer;
    font-size: 14px;
    line-height: 1;
    white-space: nowrap;
}

    .btn:hover {
        background: rgba(0,0,0,.04);
    }

/* [2026-04-04] 目的：商品頁全域 .btn:hover 會蓋掉 ContentStyle1 的 .btn__black 底色，設計工作台「完成」等按鈕 hover 變白字淺底；僅在 #design-overlay 內還原深色 CTA */
#design-overlay .btn.btn__black:hover,
#design-overlay .btn.btn__black:focus-visible {
    background: #1a1a1a;
    color: #fff;
    border-color: transparent;
    filter: none;
}
#design-overlay .btn.btn__black:active {
    background: #0d0d0d;
    color: #fff;
    filter: none;
}

/* [2026-04-22] 目的：本頁全域 .btn 特異度與 design-workbench-overlay 的 .design-overlay__close 相同時，載入順序可能讓頂列「更換版型」吃到 10px／12px 圓角等，與商品列表 overlay 不一致；鎖定與 design-workbench-overlay.css 之 .design-overlay__close 一致 */
#design-overlay .design-overlay__bar .btn.design-overlay__close {
    padding: 8px 16px;
    border-radius: 8px;
    font-weight: 400;
    font-size: 14px;
    line-height: 1.25;
    border: 1px solid #d1d5db;
    background: #fff;
    white-space: nowrap;
}

#design-overlay .design-overlay__bar .btn.design-overlay__close:hover,
#design-overlay .design-overlay__bar .btn.design-overlay__close:focus-visible {
    background: #f3f4f6;
}

.btn--dark {
    background: #111;
    color: #fff;
    border-color: transparent;
}

    .btn--dark:hover {
        filter: brightness(.1);
       
    }

.btn--primary {
    background: var(--brand2);
    color: #fff;
    border-color: transparent;
}

    .btn--primary:hover {
        filter: brightness(.97);
    }

.btn--ghost {
    background: rgba(255,255,255,.22);
}

/* ===== Typography ===== */
h1, h2, h3, p {
    margin: 0;
}

.muted {
    color: var(--muted);
}
/*=====Sale Page Edit Fuction =====*/
.SalePageEditFunc {
    width: 100%;
    background: #ddd;
    border-radius: var(--radius);
    padding: 25px;
    margin-bottom: 15px;
}
.SaleEditTitle {
    float: left;
    line-height: 35px;
}

/* [2026-03-28] 目的：/detail/edit、/detail/update 隱藏「下單」步驟內數量／購物車／一頁式收合占位，保留 Intro 分頁編輯 */
html.sale-page-edit-route .sale-detail-step-order--consumer {
    display: none !important;
}

/* ===== Media ===== */
.media {
    width: 100%;
    border-radius: 14px;
    overflow: hidden;
    background: rgba(0,0,0,.03);
    border: 1px solid var(--border-soft);
}

.media--4x5 {
    aspect-ratio: 4/5;
}

.media--1x1 {
    aspect-ratio: 1/1;
}

.media img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    display: block;
}

/* ===== Page layout ===== */
.section {
    padding: 34px 0 52px 0;
}

.page {
    display: grid;
    grid-template-columns: 1.45fr .85fr;
    gap: 18px;
    align-items: start;
}

/* 左邊要鎖住：sticky 到底 */
.left {
    position: sticky;
    top: 88px; /* header 64 + 呼吸 */
    align-self: start;
    background: transparent;
}

/* 右邊可滑 */
.right {
    min-width: 0;
}

@media (max-width: 980px) {
    .page {
        grid-template-columns: 1fr;
    }

    .left {
        position: static;
    }
}

/* ===== Left: Gallery + result thumbnails ===== */
.hero {
    display: grid;
    grid-template-columns: 1fr;
    gap: 14px;
}

.heroTop {
    display: flex;
    justify-content: space-between;
    gap: 12px;
    align-items: flex-start;
}
.titleBlock{
    width:100%;
}
.titleBlock h1, #edit_product_name {
    font-size: 28px;
    letter-spacing: -.02em;
    line-height: 1.1;
    font-weight: 950;
}
#edit_product_name{
    width:100%;
    cursor:pointer;
}

.titleBlock .sub {
    margin-top: 6px;
    font-size: 14px;
    color: var(--muted);
}

.priceBlock {
    display: flex;
    flex-direction: row;
    align-items: center;
    justify-content: flex-end;
    flex-wrap: wrap;
    gap: 6px;
}
#ProductPrice {
    display: inline-flex;
    align-items: center;
    gap: 8px;
    flex-wrap: nowrap;
}
#SalePrice {
    display: inline-flex;
    align-items: center;
    gap: 4px;
    white-space: nowrap;
}
#SalePrice > span {
    display: inline-flex;
    align-items: center;
}
#edit_product_price{
    width:96px;
    min-width: 96px;
    display:inline-block;
    cursor:pointer;
}
.price, #edit_product_price {
    font-size: 22px;
    font-weight: 950;
}
.price {
    min-width: 140px;
    text-align: right;
}
.PCost {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    min-height: 30px;
    padding: 6px 12px;
    border-radius: 999px;
    border: 1px solid #111;
    background: #111;
    color: #fff;
    font-size: 12px;
    font-weight: 700;
    line-height: 1;
    white-space: nowrap;
    cursor: pointer;
    user-select: none;
    transition: background-color .15s ease, border-color .15s ease, transform .08s ease;
}
.PCost:hover {
    background: #222;
    border-color: #222;
}
.PCost:active {
    transform: translateY(1px);
}
.heroTop {
    align-items: center;
}
.titleBlock {
    flex: 1 1 auto;
}
.priceBlock {
    flex: 0 0 auto;
}
/* [2026-04-16] 目的：會員優惠提示改為低干擾次要資訊，避免與主單價爭搶視覺焦點 */
.priceHint {
    flex: 0 0 100%;
    min-width: 0;
    text-align: right;
    font-size: 12px;
    line-height: 1.35;
    color: #6b7280;
    letter-spacing: .01em;
}

.tag {
    display: inline-flex;
    align-items: center;
    gap: 8px;
    padding: 8px 12px;
    border: 1px solid var(--border-soft);
    border-radius: 999px;
    background: rgba(255,255,255,.22);
    font-size: 13px;
    color: var(--muted);
}

.galleryCard {
    background: rgba(0,0,0,.03);
    border: 1px solid var(--border-soft);
    border-radius: var(--radius);
    padding: 14px;
}

.mainImage {
    background: rgba(255,255,255,.45);
}

/* [2026-03-27] 目的：Detail 桌機版縮圖改左側直排，主圖縮高上移，避免首屏需大量上下移動 */
@media (min-width: 981px) {
    .hero { gap: 10px; }

    .galleryCard {
        display: grid;
        grid-template-columns: 92px minmax(0, 1fr);
        column-gap: 12px;
        align-items: start;
        padding: 12px;
    }

    .galleryCard .thumbs {
        grid-column: 1;
        grid-row: 1;
        display: flex;
        flex-direction: column;
        gap: 10px;
        margin-top: 0;
        overflow-y: auto;
        overflow-x: hidden;
        /* [2026-03-27] 目的：超過可視數量時可穩定垂直捲動，不會被下方裁掉看不到 */
        height: min(72vh, 760px);
        padding: 0 2px 0 0;
        overscroll-behavior: contain;
        /* [2026-03-27] 目的：Detail 左側 thumbs 垂直捲軸細一點 */
        scrollbar-width: thin; /* Firefox */
    }

    /* WebKit 垂直捲軸細化（Detail 左側 thumbs） */
    .galleryCard .thumbs::-webkit-scrollbar {
        width: 4px;
    }
    .galleryCard .thumbs::-webkit-scrollbar-thumb {
        background: rgba(0,0,0,.18);
        border-radius: 999px;
    }
    .galleryCard .thumbs::-webkit-scrollbar-track {
        background: transparent;
    }

    .galleryCard .thumb {
        flex: 0 0 auto;
        width: 100%;
        aspect-ratio: 1 / 1;
    }

    .galleryCard .mainImage {
        grid-column: 2;
        grid-row: 1;
        max-height: min(72vh, 760px);
        margin: 0;
    }

    .galleryCard .mainImage .mainImg,
    .galleryCard .mainImage img.mainImg {
        width: 100%;
        height: 100%;
        object-fit: contain;
        object-position: top center;
        display: block;
    }
}

/* [2026-03-27] 目的：Detail 手機版主圖更高且更靠上，避免首屏主圖被擠到下面；縮圖加大好點選 */
@media (max-width: 720px) {
    /* [2026-03-27] 目的：手機版商品名稱最多兩行且價格換到下一行，避免標題被拆成三排難閱讀 */
    .heroTop {
        flex-direction: column;
        align-items: stretch;
        gap: 8px;
    }

    .titleBlock h1,
    #edit_product_name {
        /* [2026-03-27] 目的：手機商品名稱過大，調整為可讀但不壓迫版面的字級 */
        font-size: clamp(24px, 5.2vw, 30px);
        line-height: 1.2;
        display: -webkit-box;
        -webkit-line-clamp: 2;
        -webkit-box-orient: vertical;
        overflow: hidden;
        text-overflow: ellipsis;
    }

    .priceBlock {
        align-items: flex-start;
    }

    .price,
    #edit_product_price {
        min-width: 0;
        text-align: left;
        font-size: 20px;
    }

    .galleryCard {
        /* [2026-04-09] 目的：主圖灰框略減左右內距，與外層 gutter 加寬一致 */
        padding: 12px 10px;
    }

    .galleryCard .mainImage {
        margin: 0;
        /* [2026-03-27] 目的：手機主圖容器改為自適應高度，避免大面積底部留白 */
        max-height: none;
        height: auto;
        display: flex;
        align-items: flex-start;
        justify-content: center;
    }

        .galleryCard .mainImage .mainImg,
        .galleryCard .mainImage img.mainImg {
            width: 100%;
            /* height: auto; */
            /* max-height: min(62vh, 560px); */
            object-fit: cover;
            display: block;
        }

    .thumbs {
        /* [2026-03-27] 目的：縮小手機 thumbs 間距，騰出空間讓單顆縮圖看起來更大 */
        gap: 6px;
        margin-top: 10px;
        /* [2026-03-27] 目的：thumb 列與底部捲軸拉開距離，避免視覺貼齊 */
        padding: 6px 2px 10px;
        /* [2026-03-27] 目的：手機版不顯示捲軸，只保留左右滑動 */
        scrollbar-width: none; /* Firefox */
        -ms-overflow-style: none; /* IE/Edge Legacy */
    }

    .thumb {
        /* [2026-03-27] 目的：配合間距縮小，提升手機版單顆 thumbs 可視尺寸 */
        flex: 0 0 calc((100% - 12px)/3);
        border-radius: 14px;
    }

    .thumbs::-webkit-scrollbar {
        display: none;
        height: 0;
    }
}

/* thumb：固定「一排四個」，超過就橫向滑（不會變兩排） */
.thumbs {
    display: flex;
    gap: 0px;
    margin-top: 12px;
    overflow-x: auto;
    padding-bottom: 2px;
    -webkit-overflow-scrolling: touch;
    padding: 4px;
}

.thumb {
    flex: 0 0 calc((100% - 0px)/4);
    aspect-ratio: 1 / 1;
    border-radius: 12px;
    overflow: hidden;
    border: 1px solid var(--border-soft);
    background: rgba(255,255,255,.35);
    cursor: pointer;
    position: relative;
}

    /* [2026-03-27] 目的：active 藍框改內框，避免左右邊被容器裁切 */
    .thumb.is-active {
        outline: none;
        box-shadow: inset 0 0 0 2px rgba(31,111,235,.65);
        border-color: rgba(31,111,235,.45);
    }

    .thumb::after {
        content: attr(data-label);
        position: absolute;
        left: 10px;
        bottom: 8px;
        font-size: 12px;
        color: rgba(255,255,255,.92);
        font-weight: 900;
        text-shadow: 0 6px 16px rgba(0,0,0,.55);
    }
/* 更改、刪除：橫向小圓角，更改為橫條、刪除為小方塊 */
.thumb-change,
.thumb-delete {
    position: absolute;
    top: 6px;
    border-radius: 6px;
    border: none;
    background: rgba(0,0,0,0.5);
    color: #fff;
    font-size: 12px;
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    line-height: 1;
    z-index: 2;
    transition: background 0.15s ease, transform 0.1s ease;
}
.thumb-change {
    left: 6px;
    height: 26px;
    padding: 0 8px;
    min-width: 0;
}
.thumb-delete {
    right: 6px;
    width: 26px;
    height: 26px;
    font-size: 16px;
}
.thumb-change:hover,
.thumb-delete:hover {
    background: rgba(0,0,0,0.7);
}
.thumb-change:active,
.thumb-delete:active {
    transform: scale(0.92);
}
.thumb-delete:active {
    background: rgba(180,0,0,0.9);
}

.thumb-add {
    display: flex;
    align-items: center;
    justify-content: center;
    border: 2px dashed #d0d0d0;
    border-radius: 8px;
    background: #fafafa;
    cursor: pointer;
    transition: all 0.15s ease;
    height:100%;
}

    .thumb-add:hover {
        border-color: #999;
        background: #f0f0f0;
    }

.thumb-add-icon {
    font-size: 45px;
    color: #999;
    line-height: 1;
}
.thumb-add.is-disabled {
    opacity: .45;
    cursor: not-allowed;
    border-color: #d9d9d9;
    background: #f6f6f6;
}
.thumb-add.is-disabled .thumb-add-icon {
    color: #b5b5b5;
}
/* scroll bar 微弱處理（可依喜好拿掉） */
.thumbs::-webkit-scrollbar {
    height: 8px;
}

.thumbs::-webkit-scrollbar-thumb {
    background: rgba(0,0,0,.12);
    border-radius: 999px;
}

/* ===== Right: Panel ===== */
.panel {
    background: rgba(255,255,255,.28);
    border: 1px solid var(--border-soft);
    border-radius: var(--radius);
    padding: 16px;
}

/* 模式切換（方案A） */
.modeRow {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 10px;
    margin-bottom: 12px;
}

.seg {
    display: inline-flex;
    background: rgba(255,255,255,.35);
    border: 1px solid var(--border-soft);
    border-radius: 999px;
    padding: 4px;
    gap: 4px;
}

    .seg button {
        border: none;
        background: transparent;
        padding: 10px 12px;
        border-radius: 999px;
        cursor: pointer;
        font-weight: 900;
        font-size: 13px;
        color: var(--muted);
        white-space: nowrap;
    }

        .seg button.is-active {
            background: #111;
            color: #fff;
        }

.rightTitle {
    font-weight: 950;
    font-size: 14px;
    letter-spacing: -.01em;
}

.rightHint {
    font-size: 13px;
    color: var(--muted);
    margin-top: 6px;
    line-height: 1.5;
}

/* steps */
.steps {
    display: flex;
    flex-direction: column;
    gap: 12px;
    margin-top: 14px;
}

.step {
    background: rgba(255,255,255,.55);
    border: 1px solid var(--border-soft);
    border-radius: 14px;
    padding: 12px;
}

.stepHead {
    display: flex;
    align-items: flex-start;
    justify-content: space-between;
    gap: 10px;
}

.stepNo {
    /* [2026-04-16] 目的：步驟標題前置灰色圓角方塊易誤認為輸入欄位，於前台詳情頁隱藏 */
    display: none;
}

.stepTitle {
    font-weight: 950;
    font-size: 14px;
    line-height:28px;
}

.stepSub {
    margin-top: 6px;
    font-size: 13px;
    color: var(--muted);
    line-height: 1.5;
}

.row {
    display: flex;
    gap: 10px;
    margin-top: 10px;
    flex-wrap: wrap;
}

    .row .btn {
        flex: 1;
        min-width: 140px;
    }

/* options */
.field {
    margin-top: 10px;
}

.label {
    font-size: 14px;
    color: var(--muted);
    font-weight: 900;
    letter-spacing: .02em;
}

.choices {
    display: flex;
    gap: 8px;
    flex-wrap: wrap;
    margin-top: 8px;
}

.chip {
    border: 1px solid var(--border-soft);
    background: rgba(255,255,255,.35);
    border-radius: 999px;
    padding: 10px 12px;
    font-weight: 900;
    font-size: 13px;
    cursor: pointer;
    color: var(--text);
    user-select: none;
}

    .chip.is-active {
        background: #111;
        color: #fff;
        border-color: transparent;
    }

/* 規格區：選項排成一行；僅「有圖片的色票」固定小方塊，文字規格維持原本較大樣式 */
#StepUpload{
    display:none;
}
#StepEditor{
    display:none;
}
#btnToggleOnepage{
    display:none;
}

.SpecDetailDiv,
.step .ProductInfoBlock .SpecDetailDiv {
    display: flex;
    flex-wrap: wrap;
    gap: 8px;
    margin-top: 8px;
}
/* [2026-08-08] 目的：使五號店純文字規格完整沿用六號店 .chip 的實際字體、尺寸、顏色與外框。 */
.SpecDetail:not(:has(img)),
.ProcessingSpecDetail:not(:has(img)) {
    width: auto;
    height: 38px;
    display: block;
    box-sizing: border-box;
    padding: 10px 12px;
    border: 1px solid rgba(18, 18, 18, .06);
    border-radius: 999px;
    background: rgba(255, 255, 255, .35);
    color: rgb(18, 18, 18);
    font-family: ui-sans-serif, system-ui, -apple-system, "Segoe UI", "Noto Sans TC", Arial;
    font-size: 13px;
    font-weight: 900;
    line-height: normal;
    margin: 0;
    cursor: pointer;
    user-select: none;
}
/* 僅顏色圖片色票：固定尺寸小方塊，不影響尺寸/領標/包裝等文字規格 */
.SpecDetail.chip img {
    display: block;
    width: 100%;
    height: 100%;
    object-fit: cover;
    border-radius: 999px;
    border: 0;
    vertical-align: top;
}
.SpecDetail.chip:has(img) {
    width: 32px;
    height: 32px;
    min-width: 32px;
    min-height: 32px;
    padding: 0;
    border-radius: 999px;
    position: relative;
    box-sizing: border-box;
    overflow: visible;
    /* [2026-03-27] 目的：未選中也保留基礎邊框，白色顏色可清楚辨識 */
    border: 1px solid #9ca3af;
    background: #fff;
}
.SpecDetail.SpecDetailSelected.chip:has(img) img,
.chip.is-active:has(img) img {
    border: 0;
    box-shadow: none;
}

/* [2026-03-27] 目的：顏色選中框避免歪斜，改為穩定同心圓高亮 */
.SpecDetail.SpecDetailSelected.chip:has(img),
.chip.is-active:has(img),
.HEXSpecDetail.SpecDetailSelected {
    transform: none;
}

.SpecDetail.SpecDetailSelected.chip:has(img),
.chip.is-active:has(img) {
    /* [2026-03-27] 目的：選中只顯示單一粗藍框，且不改尺寸避免偏移 */
    border-color: #9ca3af;
    outline: 3px solid #1f6feb;
    outline-offset: 0;
    box-shadow: none;
    background: #fff;
}

.HEXSpecDetail.SpecDetailSelected {
    border-color: #1f6feb;
    box-shadow: none;
}

/* [2026-03-27] 目的：移除多層外圈，維持單層選中視覺 */

.qtyRow {
    display: flex;
    gap: 10px;
    align-items: center;
    margin-top: 8px;
}

/* [2026-04-15] 目的：下單區量價表採方案 A 內嵌展開；按鈕點擊後顯示同區塊表格 */
.order-qtysheet-panel {
    display: none;
    margin-top: 10px;
    padding: 10px 12px;
    border: 1px solid var(--border-soft);
    border-radius: 12px;
    background: rgba(255, 255, 255, 0.65);
}

.order-qtysheet-empty {
    margin: 0;
    color: var(--muted);
    font-size: 13px;
    line-height: 1.6;
}

/* [2026-04-16] 目的：加入購物車未填寫提示改為清單式，改善長訊息可讀性 */
.cart-validate-popup {
    text-align: left;
    max-width: 520px;
}

.cart-validate-popup__title {
    margin: 0 0 8px;
    font-size: 15px;
    font-weight: 700;
    color: #111827;
}

.cart-validate-popup__list {
    margin: 0;
    padding-left: 18px;
    max-height: 46vh;
    overflow: auto;
}

.cart-validate-popup__list li {
    margin: 0 0 6px;
    line-height: 1.65;
    color: #374151;
}

/* [2026-04-16] 目的：美化下單區「價格明細」可讀性（僅調整 #PriceDetailPanel 呈現，不改計價邏輯） */
#PriceDetailPanel {
    /* [2026-04-16] 目的：避免價格明細底部被裁切；改由外層頁面滾動，不使用面板內捲 */
    max-height: none;
    overflow: visible;
}

#PriceDetailPanel #TotalPriceContent {
    font-size: 14px;
    line-height: 1.55;
}

#PriceDetailPanel .PriceCal {
    display: grid;
    grid-template-columns: minmax(110px, 1fr) minmax(60px, auto) minmax(60px, auto);
    column-gap: 10px;
    align-items: center;
    min-height: 30px;
    height: auto;
    width: 100%;
}

#PriceDetailPanel .PriceCalItem,
#PriceDetailPanel .PriceCalLine1,
#PriceDetailPanel .PriceCalLine2 {
    float: none;
    width: auto;
    height: auto;
    white-space: nowrap;
}

#PriceDetailPanel .PriceCalItem {
    color: #1f2937;
}

#PriceDetailPanel .PriceCalLine1,
#PriceDetailPanel .PriceCalLine2 {
    text-align: right;
    font-variant-numeric: tabular-nums;
}

#PriceDetailPanel .PriceCal > div[style*="clear"] {
    display: none;
}

#PriceDetailPanel .line {
    border-bottom: 1px solid rgba(15, 23, 42, 0.14);
    margin: 6px 0;
}

#OrderQtySheetPanel .QtySheet,
#OrderQtySheetPanel #QtySheet {
    margin-top: 0;
    font-size: 13px;
}

#OrderQtySheetPanel .QTYSpecName {
    display: flex;
    width: 100%;
    border-left: 1px solid #e8edf3;
    border-right: 1px solid #e8edf3;
    border-bottom: 1px solid #e8edf3;
    background: #fff;
}

#OrderQtySheetPanel .QTYSpecName:first-of-type {
    background: #f5f8ff;
    border-top: 1px solid #e8edf3;
    font-weight: 900;
}

#OrderQtySheetPanel .QTYSpecName > span {
    float: none !important;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    min-height: 38px;
    padding: 8px 10px;
    border-right: 1px solid #edf1f6;
}

#OrderQtySheetPanel .QTYSpecName > span:last-child {
    border-right: none;
}

/* [2026-04-15] 目的：QTYChange 會加上 .SpecDetailSelected；避免下單區量價表出現白底白字看似被清空 */
#OrderQtySheetPanel .QTYSpecName.SpecDetailSelected {
    background: #eaf2ff;
    color: #123b78;
    border-left: 4px solid var(--brand2, #1f6feb);
    box-shadow: inset 0 0 0 1px rgba(31, 111, 235, 0.28);
    font-weight: 800;
}

#OrderQtySheetPanel .QTYSpecName.SpecDetailSelected > span {
    color: inherit;
    background: transparent;
}

#OrderQtySheetPanel .QTYSpecName.SpecDetailSelected .QIPrice::after {
    content: "目前適用";
    margin-left: 6px;
    padding: 2px 6px;
    border-radius: 999px;
    background: var(--brand2, #1f6feb);
    color: #fff;
    font-size: 10px;
    font-weight: 800;
    line-height: 1.4;
    white-space: nowrap;
}

    .qtyRow input {
        width: 100%;
        padding: 10px 12px;
        border-radius: 12px;
        border: 1px solid var(--border-soft);
        background: rgba(255,255,255,.55);
        font-weight: 900;
        outline: none;
    }

/* sale fields */
.input {
    width: 100%;
    padding: 12px 12px;
    border-radius: 12px;
    border: 1px solid var(--border-soft);
    background: rgba(255,255,255,.65);
    font-weight: 900;
    outline: none;
}

textarea.input {
    font-weight: 700;
    min-height: 110px;
    resize: vertical;
    line-height: 1.5;
}

.divider {
    height: 1px;
    background: var(--border-soft);
    margin: 12px 0;
}

/* 說明欄位－圖片類型：上傳／更改／刪除 */
.InfoListPhotoWrap {
    margin-top: 8px;
}
.InfoListPhotoPreview {
    min-height: 120px;
    border: 1px dashed var(--border-soft);
    border-radius: var(--radius-sm);
    background: rgba(255,255,255,.4);
    display: flex;
    align-items: center;
    justify-content: center;
    margin-bottom: 8px;
}
.InfoListPhotoPreview .InfoListPhotoImg {
    max-width: 100%;
    max-height: 320px;
    object-fit: contain;
    display: block;
}
.InfoListPhotoPlaceholder {
    padding: 24px;
    color: var(--muted);
    font-size: 13px;
    cursor: pointer;
}
.InfoListPhotoActions {
    display: flex;
    gap: 10px;
    flex-wrap: wrap;
    margin-top: 10px;
    min-height: 44px;
    align-items: center;
}
.InfoListPhotoWrap .InfoListPhotoActions button {
    display: inline-block;
    padding: 10px 16px;
    border-radius: var(--radius-sm);
    border: 1px solid var(--border-soft);
    background: rgba(255,255,255,.85);
    font-weight: 700;
    font-size: 14px;
    cursor: pointer;
    visibility: visible;
    opacity: 1;
}
.InfoListPhotoWrap .InfoListPhotoActions .InfoListPhotoUpload,
.InfoListPhotoWrap .InfoListPhotoActions .InfoListPhotoChange {
    color: var(--text);
}
.InfoListPhotoWrap .InfoListPhotoActions .InfoListPhotoDelete {
    color: #c00;
    border-color: rgba(200,0,0,.3);
}

/* 一頁式面板：可收合 */
.onepage {
    margin-top: 10px;
    border: 1px solid var(--border-soft);
    background: rgba(255,255,255,.45);
    border-radius: 14px;
    overflow: hidden;
    max-height: 800px;
    transition: max-height .25s ease, opacity .2s ease;
    opacity: 1;
}

    .onepage.is-collapsed {
        max-height: 0;
        opacity: 0;
        border-color: transparent;
    }

.onepage__inner {
    padding: 12px;
}

/* CTA */
.ctaBar {
    margin-top: 14px;
    display: flex;
    gap: 10px;
}

    .ctaBar .btn {
        flex: 1;
    }

/* [2026-04-16] 目的：下單區僅剩「加入購物車」時拉滿寬、加高與陰影，讓主 CTA 一眼可辨 */
.ctaBar--cart-only {
    margin-top: 18px;
}

.ctaBar--cart-only .btn-add-cart-cta {
    flex: 1 1 auto;
    width: 100%;
    max-width: 100%;
    min-height: 50px;
    padding: 14px 18px;
    font-size: 16px;
    font-weight: 800;
    letter-spacing: 0.06em;
    border-radius: 14px;
    box-shadow: 0 8px 24px rgba(0, 0, 0, 0.2);
}

.ctaBar--cart-only .btn-add-cart-cta:hover {
    filter: brightness(1.08);
    box-shadow: 0 10px 28px rgba(0, 0, 0, 0.24);
}

.ctaBar--cart-only .btn-add-cart-cta:active {
    transform: translateY(1px);
    box-shadow: 0 4px 14px rgba(0, 0, 0, 0.18);
}

/* hide/show blocks */
[data-mode] {
    display: none;
}

    [data-mode].is-show {
        display: block;
    }

/* [2026-03-27] 目的：Detail footer 與商品列表 footer 視覺與結構一致 */
.footer {
    border-top: 1px solid var(--border-soft);
    background: rgba(247,245,239,.8);
}

.footer__inner {
    max-width: var(--max);
    margin: 0 auto;
    padding: 22px 18px;
    display: flex;
    gap: 20px;
    justify-content: space-between;
    align-items: flex-start;
    color: var(--muted);
    font-size: 13px;
}

.footer__brand {
    font-weight: 900;
    margin-bottom: 6px;
    color: var(--text);
}

.footer__cols {
    display: flex;
    gap: 40px;
}

.col {
    display: flex;
    flex-direction: column;
    gap: 8px;
}

.col__title {
    font-weight: 900;
    margin-bottom: 4px;
    color: var(--text);
}

.col a {
    font-size: 13px;
    color: #333;
    opacity: .85;
    text-decoration: none;
}

.col a:hover {
    opacity: 1;
}

@media (max-width: 560px) {
    .footer__inner {
        padding: 20px 16px;
        flex-direction: column;
        align-items: flex-start;
        gap: 16px;
    }

    .footer__cols {
        width: 100%;
        flex-direction: row;
        justify-content: space-between;
        align-items: flex-start;
        gap: 20px;
    }

    .col {
        flex: 1 1 0;
        min-width: 0;
    }

    .col__title {
        white-space: nowrap;
        line-height: 1.2;
        margin-bottom: 6px;
    }

    .col a {
        white-space: nowrap;
        line-height: 1.5;
    }
}



.floatleft{
    float:left;
}
.RecyleTimesDIV {
    margin-left: 10px;
    line-height: 33px;
}
.RecyleTimesInput {
    width: 50px;
}
.ModulePhoto {
    width: 120px;
    height: 120px;
    border: solid 1px rgba(209,209,209,0.3);
    position: relative;
    float: left;
    margin: 5px;
}
.DriveIMG {
    width: 100%;
    height: 100%;
    object-fit:cover;
    cursor:pointer;
}
.FileName{
    overflow:hidden;
}
.ModulePhotoMiddle {
    position: absolute;
    left: 50%;
    top: 50%;
    margin-left: -9px;
    margin-top: -9px;
}
.addBttuonCss {
    display: block;
    /* float: left; */
    width: 18px;
    height: 18px;
    border-radius: 100%;
    background-color: #6d9ee1;
    cursor: pointer;
    color: #FFF;
    box-sizing: border-box;
    /* padding: 1px 1px 0 0; */
    text-align: center;
    /* font-size: 10px; */
    position: relative;
}
    .addBttuonCss:before {
        content: '+';
        font-size: 23px;
        display: block;
        margin: 0 auto;
        line-height: 18px;
        /* width: 17px; */
    }
.btnUpload {
    border: solid 1px #aaa;
    /*width: 95px;*/
    text-align: center;
    padding: 5px;
    font-weight: 800;
    background-color: #fff;
    cursor: pointer;
}
#UploadPhotoBlock{
    height:200px;
}
.FuncBlock{
    text-align:center;
}
.FuncBlockInline {
    text-align: center;
    margin: 0 auto;
    display: inline-block;
}
    .FuncBlockInline .Button {
        width: 100px;
        float: left;
    }
.TotalPriceContent {
    width: 100%;
}
.PriceCal {
    height: 25px;
    width: 100%;
}
.PriceCalItem {
    float: left;
    width: 33%;
    height: 25px;
}
.PriceCalLine1 {
    float: left;
    width: 33%;
    height: 25px;
}
.PriceCalLine2 {
    float: left;
    width: 33%;
    height: 25px;
}
.line{
    border-bottom:solid 1px;
}
#ContentData {
    width: 100%;
    position: relative;
    left: 0px;
    margin-top: 135px;
}

#ContentDataInner {
    max-width: 1480px;
    margin: 0 auto;
    overflow: hidden;
}

.ContentLeftDiv {
    float: left;
    width: 219px;
    letter-spacing: .05em;
    z-index: 1;
}

#ProudctArea {
    width: 100%;
    margin-top: 15px;
}

#ProductPhotos {
    margin: 0 0px 25px;
    line-height: 0;
    vertical-align: top;
}

    #ProductPhotos img {
        /*width: calc(100% - 30px);*/
        /*margin: 15px;*/
        position: relative;
        box-sizing: border-box;
        /*display: inline-block;*/
        margin-bottom: 15px;
    }

.Show {
    display: inline-block;
}

.Hide {
    display: none;
}

#ProductStyleRelation, #ProductLikeRelation, #ProductCategoryRelation {
    width: 100%;
}

.RelationPhoto {
    position: relative;
    box-sizing: border-box;
    display: inline-block;
    width: 195px;
    height: 248px;
    cursor: pointer;
    object-fit: cover;
    margin-right: 10px;
}

.Relation_ProductDiv {
    float: left;
}

#ProductInfoDiv {
    width: 500px;
    float: right;
}

#ProductInfoInner {
    position: relative;
    margin-bottom: 14px;
    font-size: 14px;
    line-height: 1.5;
    letter-spacing: 0.1em;
    color: #646565;
}

#TabContent {
    border-top: solid 1px #aaa;
    padding-top: 15px;
}

#ProductName {
    font-size: 20px;
}

#ProductCode {
}

#Oprice {
    font-size: 14px;
    line-height: 75px;
}

#SalePrice {
    font-size: 20px;
    line-height: 75px;
    margin-left: 10px;
}
#TotalPrice {
    font-size: 20px;
    line-height: 75px;
    margin-left: 50px;
}
.ProductInfoBlock {
    min-height: 75px;
}

    .ProductInfoBlock a {
        line-height: 75px;
        color: #646565;
    }

.PriceSpecDetail {
    min-width: 75px;
    height: 29px;
    border: solid 1px #9b9b9b;
    display: inline-block;
    text-align: center;
    line-height: 29px;
    margin-bottom: 5px;
    margin-right: 5px;
}
/*span {
    color: transparent;
    text-shadow: 0 0 0 #646565;
}
    span:focus {
        outline: none;
    }*/
/*.SpecDetail, .ProcessingSpecDetail {
    min-width: 75px;
    height: 29px;
    border: solid 1px #9b9b9b;
    display: inline-block;
    text-align: center;
    line-height: 29px;
    margin-bottom: 5px;
    margin-right: 5px;
    cursor: pointer;
    background-color: #fff;
    padding: 2px 6px;
}
.HEXSpecDetail {
    width: 35px;
    height: 29px;
    border: solid 1px #9b9b9b;
    display: inline-block;
    text-align: center;
    line-height: 29px;
    margin-bottom: 5px;
    margin-right: 5px;
    cursor: pointer;
}
    */
    .HEXSpecDetail.SpecDetailSelected {
        border: solid 2px #6d9ee1;
    }

.SpecDetail.SpecDetailSelected, .QTYSpecName.SpecDetailSelected, .ProcessingSpecDetail.SpecDetailSelected {
    background-color: #000;
    color: #FFF;
}

.MarkHint {
    font-size: 10px;
}
.MethodContenter {
    /*height: 400px;*/
    background-color: #eee;
    padding-left: 10px;
}
.QTYSpecName {
    width: 100%;
}

#QtySheet span, .QtySheet span {
    width: 33%;
    display: inline-block;
    float: left;
}

#ProductQTY {
    line-height: 75px;
}

#PDQtySelect {
    min-width: 75px;
    height: 29px;
}

#BtnToCart {
    width: 196px;
    height: 40px;
    background-color: #000000;
    letter-spacing: 0.5px;
    text-align: center;
    color: #ffffff;
   
    float: left;
    cursor: pointer;
    /*display:none;*/
}

#AddtoWishList {
    height: 40px;
    display: table-cell;
    vertical-align: bottom;
}

#btnToWish {
    margin-left: 10px;
}

.guid {
    font-size: 14px;
    font-weight: normal;
    font-stretch: normal;
    font-style: normal;
    line-height: normal;
    letter-spacing: 1px;
    text-align: center;
    color: #212121;
    text-decoration: none;
}

.RelationNameDIV {
    text-align: center;
}

#Oprice {
    text-decoration: line-through;
}
.DynamicBlock .FileUPLabel {
    max-width: 60px;
}

.FileUPLabel {
    display: inline-block;
    float: left;
    /* margin-right: 5px; */
    /* width: 100%; */
    height: 100%;
    padding-right: 10px;
}
#DynamicIntro{
    display:inline-block;
}
#DynamicIntro div {
    min-height: 30px;
}
.PrintIMG {
    width: 100%;
}
.PrintUpload {
    width: 100%;
    height: 100%;
    /* background-color: #000; */
    color: #fff;
    text-align: center;
    -moz-box-shadow: 2px 2px 1px #5074a5;
    cursor: pointer;
}
.FileUpload {
    width: 196px;
    height: 40px;
    background-color: #000;
    color: #fff;
    text-align: center;
    -moz-box-shadow: 2px 2px 1px #5074a5;
    line-height: 40px;
    cursor: pointer;
}

.FileUP {
    position: absolute;
    left: 0px;
    top: 0px;
    display: none;
}

#UploadShow {
    padding-top: 55px;
}

    #UploadShow .UploadIMGContent {
        position: relative;
    }

    #UploadShow img {
        box-sizing: border-box;
        display: inline-block;
        width: calc(100% - 3px);
        height: 200px;
        object-fit: cover;
    }

    #UploadShow .EditorEnter {
        position: absolute;
        right: 8px;
        bottom: 11px;
        border: solid 1px #fff;
        background-color: #fff;
        border-radius: 4px;
        padding: 5px;
        cursor: pointer;
    }

    #UploadShow .DeleteButton {
        position: absolute;
        right: 8px;
        top: 5px;
    }

    #UploadShow .DeleteButton {
        display: block;
        width: 18px;
        height: 18px;
        border-radius: 100%;
        background-color: #6d9ee1;
        cursor: pointer;
        color: #FFF;
        text-align: center;
    }

        #UploadShow .DeleteButton:before {
            content: '+';
            font-size: 23px;
            display: block;
            transform: rotate(45deg);
            margin: 0 auto;
            line-height: 18px;
        }
/*編輯器介面*/
.EditorBG {
    width: 100%;
    height: 100%;
    text-align: center;
    top: 0%;
    /*opacity: 0.8;*/
    z-index: 1000;
    display: block;
    position: fixed;
    background-color: #FFFFFF;
}

.PopupWindow {
    width: 100%;
    height: 100%;
    text-align: center;
    top: 0%;
    visibility: hidden;
    opacity: 0;
    z-index: 1000;
    display: flex;
    position: fixed;
    align-items: center;
    justify-content: center;
}

.PopupContent {
    -moz-border-bottom-colors: none;
    -moz-border-left-colors: none;
    -moz-border-right-colors: none;
    -moz-border-top-colors: none;
    border-color: #d0d1d1;
    border-image: none;
    border-style: solid;
    border-width: 1px 3px 3px 1px;
    box-sizing: border-box;
    position: relative;
    width: 70%;
    z-index: 2000;
    display: inline-block;
    background-color: #fff;
}

#EditCanvas {
    float: left;
}

#EditLayer1 {
    position: absolute;
    z-index: 100;
    left: 50px;
    top: 155px;
    overflow: hidden;
    border: solid 1px #ddd;
    background-color: #ddd;
}

.UserUpload {
    cursor: pointer;
    position: absolute;
}

#TabList span {
    cursor: pointer;
    padding: 5px;
}

.TabsSelected {
    background-color: #ddd;
}

.Separate {
    margin: 0 5px;
}

.InfoPhoto {
    max-width: 100%;
}

.InfoTable {
    background-color: #f8f9f9;
    border: #d0d1d1 1px solid;
    border-right: solid 3px #d0d1d1;
    border-bottom: solid 3px #d0d1d1;
    width: 100%;
    /*height: 250px;*/
}
.TabInner {
    display: none;
    line-height: 28px;
    letter-spacing: 1px;
    font-size: 14px;
}

.InfoTableInner {
    padding-left: 8px;
}

.InfoTableCell {
    width: 79px;
    height: 34px;
    background-color: #ffffff;
    float: left;
    margin-right: 8px;
    margin-top: 8px;
    text-align: center;
}

#TabList {
    margin-bottom: 5px;
    margin-top: 15px;
    display: flex;
    align-items: center;
    justify-content: space-between;
}
.select-wrap {
    position: relative;
    display: inline-block;
}
    .select-wrap::after {
        content: "▼";
        position: absolute;
        right: 12px;
        top: 50%;
        transform: translateY(-50%);
        pointer-events: none;
        font-size: 12px;
        color: #666;
    }
.InfoListSelect {
    appearance: none;
    -webkit-appearance: none;
    padding: 8px 36px 8px 12px;
    font-size: 14px;
    border-radius: 8px;
    border: 1px solid #ddd;
    background: #fff;
    cursor: pointer;
}
.ck.ck-editor{
    width:100%;
}
/* hover */
.InfoListSelect:hover {
    border-color: #aaa;
}

    /* focus */
    .InfoListSelect:focus {
        outline: none;
        border-color: #333;
    }

#BackTop {
    cursor: pointer;
    background-color: #000;
    width: 150px;
    position: fixed;
    bottom: 0px;
    color: #fff;
    text-align: center;
    height: 30px;
    line-height: 30px;
}

#block {
    background-color: rgba(0,0,0,0.5);
    width: 100%;
    height: 100%;
    position: fixed;
    top: 0px;
    left: 0px;
    z-index: 1000;
    display: none;
}
/*#EditorImg {
    width: 900px;
    text-align: left;
    object-fit: cover;
    height: 768px;
    float: left;
}*/

.DynamicBlock {
    width: 100%;
    padding-top: 20px;
    border-bottom: solid 1px;
    padding-bottom: 10px;
}
.DynamicTitleBlock {
    width: 100%;
}
    .DynamicTitleBlock .DynamicItem {
        float: left;
        margin-right: 5px;
        
    }
.DynamicTitle{
    text-align:center;
}
.DynamicInput {
    width: 100%;
}
    .DynamicInput input[type='text'] {
        width: 86%;
    }
    .DynamicInput select {
        width: 95%;
        height: 21px;
    }
.DynamicModuleBlock {
    width: 100%;
    margin-top: 5px;
}
.DynamicModuleName {
    cursor: pointer;
    float: left;
    border: solid 1px #9b9b9b;
    margin-right: 5px;
    padding: 0px 3px;
}
.DynamicAdd {
    margin: 15px 0px;
    cursor: pointer;
    background-color: #fff;
    width: 100px;
    border: solid 1px;
    text-align: center;
}
.disabled{

}
@media (max-width: 575px) {
    .guid {
        font-size: 40px;
    }
    .PriceCal {
        height: 60px;
        width: 100%;
    }
    .SecfloatLeft {
        font-size: 40px;
    }

    .MobileImg {
    }

    #ProductPhotoDiv {
        display: none;
    }
}

@media (min-width: 576px) and (max-width: 767px) {
    .guid {
        font-size: 36px;
    }
    .PriceCal {
        height: 60px;
        width: 100%;
    }
    .SecfloatLeft {
        font-size: 36px;
    }

    .MobileImg {
    }

    #ProductPhotoDiv {
        display: none;
    }
}

@media (min-width: 768px) and (max-width: 991px) {
    #UploadShow img {
        height: 500px;
    }
    .PriceCal {
        height: 60px;
        width: 100%;
    }
    .EditorBG .Button {
        width: 200px;
        height: 100px;
        font-size: 48px;
        line-height: 100px;
        float: left;
        margin: 10px;
    }

    .guid {
        font-size: 40px;
    }

    .SecfloatLeft {
        font-size: 40px;
    }

    #ProductInfoInner {
        width: 98%;
        margin: 0 auto;
        margin-top: 20px;
    }

    .ProductInfoBlock {
        margin-top: 20px;
        font-size: 32px;
    }

    #PDQtySelect {
        font-size: 30px;
        height: 50px;
        margin-left: 10px;
    }

    #ProductQTY {
        height: 90px;
        line-height: 90px;
        font-size: 32px;
    }

    #QtySheet {
        margin-top: 30px;
        font-size: 32px;
    }

    #TabList {
        font-size: 32px;
    }

    #ProductIntroduction {
        margin: 10px 0 30px 0;
    }

    #TabContent {
        font-size: 32px;
    }

    #BtnToCart {
        width: 260px;
        height: 70px;
        line-height: 70px;
    }

    .FileUpload {
        width: 260px;
        height: 70px;
        line-height: 70px;
    }

    .MobileImg {
        width: 100%;
    }

    #ProductPhotoDiv {
        display: none;
    }

    #ProductInfoDiv {
        width: 100%;
        float: left;
    }

    #ProductName {
        font-size: 48px;
    }

    #ProductSubTitle, #ProductCode {
        font-size: 30px;
    }

    #Oprice {
        font-size: 36px;
    }

    #SalePrice {
        font-size: 40px;
    }
    #TotalPrice {
        font-size: 50px;
    }
    .SpecName {
        font-size: 32px;
    }
    #DynamicIntro {
        font-size: 28px;
    }
    .DynamicBlock {
        font-size: 28px;
    }
    .DynamicInput select {
        width: 95%;
        height: 40px;
        font-size: 28px;
    }
    .DynamicInput input[type='text'] {
        height: 40px;
        font-size: 28px;
    }
    .SpecDetail, .ProcessingSpecDetail {
        font-size: 32px;
        padding: 15px;
    }
    #DynamicAdd {
        font-size: 28px;
    }
    .MarkHint {
        font-size: 24px;
    }
}

@media (min-width: 992px) and (max-width: 1199px) {
    .MobileImg {
        display: none;
    }
    .PriceCal {
        height: 60px;
        width: 100%;
    }
}

@media (min-width: 1200px) {
    .MobileImg {
        display: none;
    }

}

@media (min-width: 1200px) and (max-width: 1350px) {
    .ContentRightDiv {
        width: calc( 100% - 218px );
        float: left;
    }

    #ProductPhotoDiv {
        width: calc( 100% - 400px );
        float: left;
    }
}

@media (min-width: 1350px) {
    .ContentRightDiv {
        width: 1232px;
        float: left;
    }

    #ProductPhotoDiv {
        width: 700px;
        float: left;
    }
}

/* [2026-03-28] 目的：一頁式 edit/update 規格編輯區（模組／細項開關）；[2026-03-28] 精簡版：輕邊框、模組單列文案、細項僅小開關＋預留 AI 列 */
.sale-page-edit-spec-module--pro {
    margin-bottom: 12px;
    border: 1px solid rgba(0, 0, 0, 0.06);
    border-radius: 10px;
    padding: 8px 10px 10px;
    background: rgba(255, 255, 255, 0.55);
    box-shadow: 0 1px 0 rgba(0, 0, 0, 0.04);
    border-left: 3px solid #111;
}

.sale-page-edit-spec-module--required {
    border-left-color: #b45309;
    background: rgba(255, 251, 235, 0.35);
}

.sale-spec-mod-toolbar--server {
    margin-bottom: 6px;
    padding-bottom: 6px;
    border-bottom: 1px solid rgba(0, 0, 0, 0.06);
}

.sale-spec-mod-bar {
    display: flex;
    align-items: center;
    justify-content: flex-end;
    gap: 10px;
    flex-wrap: wrap;
}

.sale-spec-mod-bar__label {
    margin-right: auto;
    /* [2026-03-28] 目的：一頁式規格編輯區字級調大 */
    font-size: 13px;
    font-weight: 800;
    letter-spacing: 0.06em;
    text-transform: uppercase;
    color: var(--muted, #6b7280);
}

.sale-spec-mod-bar--locked {
    justify-content: flex-start;
    gap: 8px;
}

.sale-spec-mod-bar__badge {
    flex: 0 0 auto;
    font-size: 12px;
    font-weight: 900;
    letter-spacing: 0.04em;
    padding: 3px 9px;
    border-radius: 999px;
    background: #111;
    color: #fff;
}

.sale-spec-mod-bar__locked-text {
    font-size: 14px;
    font-weight: 800;
    color: #92400e;
}

/* [2026-04-27] 目的：內部製造選項「非必填」badge 樣式，與「必填」黑底做區隔 */
.sale-spec-mod-bar__badge--optional {
    background: #6b7280;
    font-weight: 600;
}

.sale-page-spec-host {
    display: flex;
    flex-direction: column;
    gap: 10px;
}

/* 一般商品頁無編輯模組時不顯示說明（:has 不支援時頂多多一行字） */
#SalePageSpecHost:not(:has(.sale-page-edit-spec-module)) .sale-spec-host-hint {
    display: none;
}

.sale-spec-host-hint {
    font-size: 16px;
    line-height: 1.55;
    color: var(--muted, #4b5563);
    margin: 0 0 10px;
    padding: 12px 14px;
    border-radius: 10px;
    background: rgba(0, 0, 0, 0.03);
    border: 1px solid rgba(0, 0, 0, 0.06);
}

.sale-spec-host-hint strong {
    color: var(--text, #111);
    font-weight: 800;
}

/* [2026-04-27] 目的：一頁式 edit/update 規格依 SpecAudience 拆成「消費者規格／工廠規格」兩段，先做明確分區顯示 */
/* [2026-04-27] 目的：左右 padding 移至標題/說明自行承擔，讓規格 .step 框與外框齊寬，減少視覺層次 */
.spec-audience-split {
    border: 1px solid #e5e7eb;
    border-radius: 12px;
    background: #fff;
    padding: 12px 0 0;
}

.spec-audience-split--consumer {
    border-color: #bfdbfe;
    background: #eff6ff;
}

.spec-audience-split--factory {
    border-color: #fcd34d;
    background: #fffbeb;
}

.spec-audience-split__title {
    font-size: 16px;
    font-weight: 800;
    color: #111827;
    margin: 0 0 8px;
    padding: 0 12px;
}

/* [2026-04-27] 目的：工廠規格模組移除買家可見開關（toolbar 右側），只保留標題與必填 badge */
.sale-page-edit-spec-module--factory .sale-spec-mod-bar__right {
    display: none;
}

/* [2026-04-27] 目的：消費者/內部製造區塊說明文字樣式 */
.spec-audience-split__hint {
    font-size: 14px;
    line-height: 1.5;
    color: #4b5563;
    margin: 0 0 8px;
    padding: 0 12px;
}

.spec-audience-split__body {
    display: flex;
    flex-direction: column;
    gap: 0;
}

/* [2026-04-27] 目的：規格框齊邊後，各 .step 之間用 border-top 分隔，最後一個底部圓角跟外框對齊 */
.spec-audience-split__body > * {
    border-radius: 0;
    border-left: none;
    border-right: none;
}

.spec-audience-split__body > * + * {
    border-top: none;
}

.spec-audience-split__body > :last-child {
    border-bottom-left-radius: 11px;
    border-bottom-right-radius: 11px;
}

.spec-audience-split__body:empty::before {
    content: "目前沒有規格";
    display: block;
    font-size: 14px;
    color: #6b7280;
    padding: 4px 0;
}

/* [2026-03-28] 目的：一頁式編輯有規格模組時，「選擇規格」步驟標題與右上角標籤略放大 */
.step:has(.sale-page-edit-spec-module) .stepTitle {
    font-size: 17px;
    line-height: 1.35;
}

.step:has(.sale-page-edit-spec-module) .stepHead .tag {
    font-size: 14px;
}

.sale-spec-mod-toolbar {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 12px;
    flex-wrap: wrap;
    margin-top: 0;
}

.sale-spec-mod-toolbar .SpecNameDIV {
    flex: 1;
    min-width: 0;
}

/* [2026-03-28] 目的：覆蓋 FrontProductInformtion 內 .text 10px，模組標題（顏色／尺寸）在編輯頁可讀 */
.sale-page-edit-spec-module .sale-spec-mod-toolbar .SpecNameDIV .text {
    font-size: 15px;
    line-height: 1.45;
    font-weight: 700;
}

.sale-spec-option--pro {
    display: inline-flex;
    flex-direction: column;
    align-items: center;
    vertical-align: top;
    margin: 2px 10px 10px 0;
    max-width: 100%;
    flex: 0 0 auto;
    align-self: flex-start;
    position: relative;
}

.sale-spec-option__chip {
    display: flex;
    justify-content: center;
    align-items: center;
    min-height: 2.25rem;
    min-width: 2.25rem;
}

.sale-spec-option--edit-active .sale-spec-option__chip {
    outline: 2px solid #1f6feb;
    outline-offset: 2px;
    border-radius: 10px;
}

/* [2026-03-28] 目的：一頁式 edit/update 不套用一般商品頁「黑底／強調選中」；計價仍靠 SpecDetailSelected，視覺僅靠上方藍框 */
.sale-page-edit-spec-module .SpecDetail.SpecDetailSelected,
.sale-page-edit-spec-module .QTYSpecName.SpecDetailSelected {
    background-color: rgba(255, 255, 255, 0.35);
    color: var(--text, #111);
}

.sale-page-edit-spec-module .SpecDetail.SpecDetailSelected.chip,
.sale-page-edit-spec-module .chip.SpecDetailSelected {
    background: rgba(255, 255, 255, 0.35);
    color: var(--text, #111);
    border: 1px solid var(--border-soft);
    outline: none;
    box-shadow: none;
}

/* [2026-04-27] 目的：內部製造選項選中狀態恢復黑底白字，覆蓋上方 edit 模式的透明白底 */
.sale-page-edit-spec-module--factory .SpecDetail.SpecDetailSelected,
.sale-page-edit-spec-module--factory .SpecDetail.SpecDetailSelected.chip,
.sale-page-edit-spec-module--factory .chip.SpecDetailSelected {
    background: #111 !important;
    color: #fff !important;
    border-color: #111 !important;
    outline: none;
    box-shadow: none;
}

.sale-page-edit-spec-module .chip.is-active {
    background: rgba(255, 255, 255, 0.35);
    color: var(--text, #111);
    border-color: var(--border-soft);
}

.sale-page-edit-spec-module .SpecDetail.SpecDetailSelected.chip:has(img),
.sale-page-edit-spec-module .chip.SpecDetailSelected:has(img) {
    background: #fff;
    border: 1px solid #9ca3af;
    outline: none;
    box-shadow: none;
}

.sale-page-edit-spec-module .HEXSpecDetail.SpecDetailSelected {
    border: solid 1px #9ca3af;
    box-shadow: none;
}

/* 僅存狀態，不佔版面 */
.sale-spec-detail-input--store {
    position: absolute;
    width: 1px;
    height: 1px;
    padding: 0;
    margin: -1px;
    overflow: hidden;
    clip: rect(0, 0, 0, 0);
    white-space: nowrap;
    border: 0;
}

/* 模組底部：目前選項＋顯示＋商品照 */
.sale-spec-active-tools {
    margin-top: 12px;
    padding-top: 12px;
    border-top: 1px solid rgba(0, 0, 0, 0.08);
}

.sale-spec-active-tools__lead {
    margin: 0 0 10px;
    font-size: 15px;
    line-height: 1.55;
    color: var(--muted, #6b7280);
}

.sale-spec-active-tools__line {
    display: flex;
    flex-wrap: wrap;
    align-items: center;
    gap: 12px 16px;
    font-size: 16px;
    line-height: 1.45;
}

.sale-spec-active-tools__now {
    flex: 1 1 180px;
    min-width: 0;
    font-weight: 700;
    color: var(--text, #111);
}

.sale-spec-active-tools__name {
    font-weight: 900;
}

.sale-spec-active-tools__vis {
    display: inline-flex;
    align-items: center;
    gap: 10px;
    cursor: pointer;
    font-size: 16px;
    font-weight: 800;
    color: var(--text, #111);
}

.sale-spec-active-detail-toggle {
    width: 1.25rem;
    height: 1.25rem;
    accent-color: #111;
    cursor: pointer;
}

.btn.sale-spec-active-photo-btn {
    padding: 9px 18px;
    font-size: 15px;
    font-weight: 800;
    border-radius: 10px;
    border: 1px solid #111;
    background: #111;
    color: #fff;
    cursor: pointer;
}

.btn.sale-spec-active-photo-btn:hover {
    opacity: 0.92;
}

/* [2026-03-28] 目的：DieCut 無對應 SpecID 時隱藏商品照按鈕（ProductDetail.js salePageEditSyncActivePhotoBtnVisibility） */
.btn.sale-spec-active-photo-btn.sale-spec-active-photo-btn--unsupported {
    display: none !important;
}

/* [2026-03-28] 目的：一頁式「商品照」暫存縮圖列（設計工作台關閉後仍顯示） */
/* [2026-04-02] 目的：縮圖放大、固定「四格寬」視覺（每格約 25% 寬）；未滿 4 張時右側自然留白；超過 4 張時橫向捲動（每細項最多 10 張見 ProductDetail.js／5.js） */
.sale-spec-active-photo-thumbs {
    display: flex;
    flex-wrap: nowrap;
    gap: 10px;
    align-items: stretch;
    width: 100%;
    margin-top: 10px;
    overflow-x: auto;
    overflow-y: hidden;
    -webkit-overflow-scrolling: touch;
    scrollbar-gutter: stable;
    padding-bottom: 4px;
}

.sale-spec-photo-thumb-cell {
    position: relative;
    flex: 0 0 calc((100% - 30px) / 4);
    width: calc((100% - 30px) / 4);
    min-width: max(72px, calc((100% - 30px) / 4));
    max-width: calc((100% - 30px) / 4);
    aspect-ratio: 1;
    border-radius: 12px;
    overflow: hidden;
    border: 1px solid rgba(17, 17, 17, 0.12);
    background: #f3f4f6;
    flex-shrink: 0;
}

.sale-spec-photo-thumb {
    display: block;
    width: 100%;
    height: 100%;
    object-fit: cover;
    border-radius: 0;
    border: 0;
    background: transparent;
    cursor: zoom-in;
}

/* 放大：圖示按鈕（文字在 aria-label） */
.sale-spec-photo-thumb-zoom {
    position: absolute;
    left: 6px;
    bottom: 6px;
    width: 30px;
    height: 30px;
    padding: 0;
    border: 0;
    border-radius: 8px;
    background: rgba(255, 255, 255, 0.92);
    color: #111;
    cursor: pointer;
    box-shadow: 0 1px 4px rgba(0, 0, 0, 0.12);
    font-size: 0;
    line-height: 0;
}

.sale-spec-photo-thumb-zoom::before {
    content: "";
    display: block;
    width: 14px;
    height: 14px;
    margin: 8px auto;
    border: 2px solid #111;
    border-radius: 50%;
    box-sizing: border-box;
    box-shadow: 6px -2px 0 -3px #111;
    transform: rotate(-40deg);
}

.sale-spec-photo-thumb-zoom:hover {
    background: #fff;
}

/* 刪除（僅一頁式編輯；買家檢視時由 CSS 隱藏） */
.sale-spec-photo-thumb-del {
    position: absolute;
    top: 4px;
    right: 4px;
    width: 28px;
    height: 28px;
    padding: 0;
    border: 0;
    border-radius: 8px;
    background: rgba(17, 17, 17, 0.72);
    color: #fff;
    font-size: 18px;
    font-weight: 700;
    line-height: 1;
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
}

.sale-spec-photo-thumb-del:hover {
    background: rgba(17, 17, 17, 0.88);
}

html:not(.sale-page-edit-route) .sale-spec-photo-thumb-del {
    display: none !important;
}

/* 商品照放大檢視（由 ProductDetail.js 動態插入 #sale-spec-thumb-lightbox） */
.sale-spec-thumb-lightbox {
    display: none;
    position: fixed;
    inset: 0;
    z-index: 100050;
    align-items: center;
    justify-content: center;
    padding: max(16px, env(safe-area-inset-top)) max(16px, env(safe-area-inset-right)) max(16px, env(safe-area-inset-bottom)) max(16px, env(safe-area-inset-left));
    background: rgba(0, 0, 0, 0.88);
    box-sizing: border-box;
}

.sale-spec-thumb-lightbox.is-open {
    display: flex;
}

.sale-spec-thumb-lightbox__img {
    max-width: 100%;
    max-height: 100%;
    width: auto;
    height: auto;
    object-fit: contain;
    border-radius: 8px;
    box-shadow: 0 12px 48px rgba(0, 0, 0, 0.45);
}

.sale-spec-thumb-lightbox__close {
    position: absolute;
    top: max(12px, env(safe-area-inset-top));
    right: max(12px, env(safe-area-inset-right));
    width: 44px;
    height: 44px;
    padding: 0;
    border: 0;
    border-radius: 12px;
    background: rgba(255, 255, 255, 0.15);
    color: #fff;
    font-size: 28px;
    font-weight: 300;
    line-height: 1;
    cursor: pointer;
}

.sale-spec-thumb-lightbox__close:hover {
    background: rgba(255, 255, 255, 0.28);
}

.sale-spec-active-tools__line {
    flex-wrap: wrap;
}

.step .SpecDetailDiv {
    align-items: flex-start;
    align-content: flex-start;
}

.sale-spec-switch {
    position: relative;
    display: inline-flex;
    align-items: center;
    gap: 6px;
    cursor: pointer;
    flex-shrink: 0;
    user-select: none;
    font-size: 13px;
    font-weight: 800;
    color: var(--muted, #6b7280);
}

.sale-spec-switch input {
    position: absolute;
    opacity: 0;
    width: 0;
    height: 0;
    pointer-events: none;
}

.sale-spec-switch__track {
    width: 36px;
    height: 20px;
    border-radius: 999px;
    background: #d1d5db;
    position: relative;
    transition: background 0.15s ease;
    flex-shrink: 0;
}

.sale-spec-switch__knob {
    position: absolute;
    top: 2px;
    left: 2px;
    width: 16px;
    height: 16px;
    border-radius: 50%;
    background: #fff;
    box-shadow: 0 1px 2px rgba(0, 0, 0, 0.12);
    transition: transform 0.15s ease;
}

.sale-spec-switch input:checked + .sale-spec-switch__track {
    background: #111;
}

.sale-spec-switch input:checked + .sale-spec-switch__track .sale-spec-switch__knob {
    transform: translateX(16px);
}

.sale-spec-switch__text--off {
    display: none;
}

.sale-spec-switch input:not(:checked) ~ .sale-spec-switch__text--on {
    display: none;
}

.sale-spec-switch input:not(:checked) ~ .sale-spec-switch__text--off {
    display: inline;
}

/* [2026-03-28] 目的：隱藏狀態僅淡化、可點選；勿用 filter 於圖片色票（易造成灰塊／合成異常），勿 pointer-events:none（會無法再點開） */
.sale-spec-detail-hidden.sale-spec-option--pro {
    cursor: pointer;
}

.sale-spec-detail-hidden .sale-spec-option__chip .SpecDetail,
.sale-spec-detail-hidden .sale-spec-option__chip .HEXSpecDetail {
    opacity: 0.48;
    cursor: pointer;
}

.sale-spec-module-hidden .SpecDetailDiv,
.sale-spec-module-hidden .SpecDetailDiv * {
    pointer-events: none;
}

/* [2026-03-28] 目的：與細項隱藏一致，圖片色票不用 filter 避免渲染異常 */
.sale-spec-module-hidden .SpecDetailDiv .sale-spec-option__chip .SpecDetail,
.sale-spec-module-hidden .SpecDetailDiv .sale-spec-option__chip .HEXSpecDetail {
    opacity: 0.45;
}

.sale-spec-module-hidden .sale-spec-active-tools {
    pointer-events: none;
    opacity: 0.55;
}

.sale-spec-module-hidden .sale-spec-mod-toolbar .sale-spec-mod-bar:not(.sale-spec-mod-bar--locked) {
    pointer-events: auto;
    opacity: 1;
}

.sale-spec-module-hidden .sale-spec-mod-toolbar .sale-spec-switch--module {
    pointer-events: auto;
}

.sale-spec-module-hidden .sale-spec-mod-toolbar .sale-spec-mod-bar--locked {
    pointer-events: none;
    opacity: 0.65;
}

/* [2026-04-15] 目的：加工區外層與「選擇規格」分塊；內層 __card 將標題與正／背面包成一組、縮小標題與折疊列空隙 */
.product-spec-processing {
    margin-top: 1.5rem;
    padding: 1rem 0 0 0;
    border-top: 1px solid var(--border-soft);
    background: transparent;
    border-radius: 0;
    border-left: none;
    box-shadow: none;
}

.product-spec-processing__card {
    margin-top: 0;
    padding: 10px 12px 12px;
    background: rgba(255, 255, 255, 0.78);
    border: 1px solid var(--border-soft);
    border-radius: 14px;
    border-left: 3px solid var(--brand, #111);
    box-shadow: 0 8px 28px rgba(18, 18, 18, 0.06);
}

.product-spec-processing-intro {
    display: flex;
    align-items: flex-start;
    gap: 10px;
    margin: 0 0 4px 0;
    padding: 0 0 8px 0;
    border: none;
    border-bottom: 1px solid var(--border-soft);
}

.product-spec-processing-intro::before {
    content: "";
    width: 28px;
    height: 28px;
    border-radius: 10px;
    background: rgba(0, 0, 0, 0.06);
    flex-shrink: 0;
    margin-top: 0;
}

.product-spec-processing-intro__title {
    font-size: 14px;
    font-weight: 950;
    line-height: 28px;
    letter-spacing: -0.01em;
    color: var(--text, #121212);
    margin: 0;
}

.processing-face-details {
    margin: 0 0 10px 0;
    border: 1px solid var(--border-soft);
    border-radius: 12px;
    background: rgba(255, 255, 255, 0.42);
    overflow: hidden;
}

.product-spec-processing__card > .processing-face-details:first-of-type {
    margin-top: 0;
}

.processing-face-details:last-child {
    margin-bottom: 0;
}

.processing-face-summary {
    list-style: none;
    cursor: pointer;
    padding: 10px 12px;
    font-weight: 800;
    font-size: 14px;
    display: flex;
    align-items: center;
    gap: 8px;
    color: var(--text);
    background: rgba(255, 255, 255, 0.72);
    border-bottom: none;
}

.processing-face-details:not([open]) .processing-face-summary {
    background: rgba(255, 255, 255, 0.4);
}

.processing-face-details[open] .processing-face-summary {
    border-bottom: 1px solid var(--border-soft);
}

.processing-face-summary::-webkit-details-marker {
    display: none;
}

.processing-face-summary::before {
    /* [2026-04-27] 目的：加工面收合/展開圖示改為 +/-，提高可辨識度 */
    content: "+";
    width: 14px;
    height: 14px;
    line-height: 14px;
    text-align: center;
    font-size: 14px;
    font-weight: 900;
    color: var(--muted);
    transition: color 0.2s ease;
    flex-shrink: 0;
}

.processing-face-details[open] .processing-face-summary::before {
    content: "-";
}

.processing-face-body {
    padding: 12px 12px 14px;
    position: relative;
}

/* [2026-04-15] 目的：面名與加工方式下拉並排；狀態列與隱藏 marker 不佔 chip 列 */
.processing-face-summary__label {
    flex: 1;
    min-width: 0;
    margin-left: 6px;
}

.processing-method-select {
    flex-shrink: 0;
    max-width: 58%;
    min-width: 140px;
    margin-left: auto;
    padding: 8px 10px;
    font-size: 13px;
    font-weight: 800;
    border-radius: 10px;
    border: 1px solid var(--border-soft);
    background: rgba(255, 255, 255, 0.92);
    color: var(--text);
}

.processing-method-status {
    margin: 0 0 10px 0;
    font-size: 13px;
    font-weight: 700;
    color: var(--muted);
    line-height: 1.45;
}

.processing-face-body .ProcessingSpecDetail.processing-method-marker {
    position: absolute !important;
    width: 1px !important;
    height: 1px !important;
    padding: 0 !important;
    margin: -1px !important;
    overflow: hidden !important;
    clip: rect(0, 0, 0, 0) !important;
    border: 0 !important;
    white-space: nowrap !important;
    display: block !important;
    cursor: default !important;
    line-height: 0 !important;
    min-width: 0 !important;
}

/* 獨立 step：白卡與「選擇規格」區塊同寬感，不重複外層 product-spec-processing 邊線 */
.product-spec-processing__card--step {
    margin-top: 0;
    padding: 10px 12px 12px;
    background: rgba(255, 255, 255, 0.78);
    border: 1px solid var(--border-soft);
    border-radius: 14px;
    border-left: 3px solid var(--brand, #111);
    box-shadow: 0 8px 28px rgba(18, 18, 18, 0.06);
}

#StepProcessing .sale-page-spec-host--processing {
    margin-top: 0;
    padding: 0;
    gap: 0;
}

/* [2026-04-29] 目的：避免 txt 先渲染出「加工方式選擇」標題；預設隱藏，待 ProductDetail.js 判斷有加工選項後再顯示 */
#StepProcessing {
    display: none;
}
#StepProcessing.processing-has-options {
    display: block;
}

/* [2026-04-14] 目的：加工獨立 step 與「選擇規格／下單」同為白底一塊，拿掉灰階 step＋內層白卡＋正背面再包一層的盒中盒；並讓內層沿用 .product-spec-processing 細部樣式 */
#StepProcessing.step {
    background: rgba(255, 255, 255, 0.96);
    border-color: var(--border-soft);
}

#StepProcessing .product-spec-processing.product-spec-processing__card--step {
    margin: 0;
    padding: 0;
    border: none;
    box-shadow: none;
    background: transparent;
    border-left: none !important;
    border-radius: 0;
}

#StepProcessing .product-spec-processing.product-spec-processing__card--step > .processing-face-details:last-child {
    margin-bottom: 0;
}

#StepProcessing .product-spec-processing {
    margin-top: 0;
    padding: 0;
    border-top: none;
    background: transparent;
    border-radius: 0;
    box-shadow: none;
}

#StepProcessing .processing-face-details {
    margin: 0 0 14px 0;
    border: none;
    border-radius: 0;
    background: transparent;
    overflow: visible;
}

#StepProcessing .processing-face-details:last-of-type {
    margin-bottom: 0;
}

/* [2026-04-27] 目的：一頁式 edit/update「加工方式設定」為唯讀，視覺上呈現不可編輯狀態 */
#StepProcessing.processing-readonly .processing-face-summary,
#StepProcessing.processing-readonly .processing-face-body {
    opacity: 0.82;
}

/* [2026-04-27] 目的：唯讀模式下文字與圖示再淡化，讓不可選狀態更直覺 */
#StepProcessing.processing-readonly .processing-face-summary,
#StepProcessing.processing-readonly .processing-face-summary__label,
#StepProcessing.processing-readonly .processing-method-status,
#StepProcessing.processing-readonly .SpecName,
#StepProcessing.processing-readonly #DynamicIntro,
#StepProcessing.processing-readonly #DynamicIntro *,
#StepProcessing.processing-readonly .DynamicData,
#StepProcessing.processing-readonly .QTYSpecName,
#StepProcessing.processing-readonly .QTYSpecName span {
    color: rgba(18, 18, 18, 0.52) !important;
}

/* [2026-04-27] 目的：唯讀模式下摘要列可點擊展開內容，提供「點了才開啟資訊」的互動 */
#StepProcessing.processing-readonly .processing-face-summary {
    cursor: pointer;
}

#StepProcessing.processing-readonly .processing-method-select,
#StepProcessing.processing-readonly input,
#StepProcessing.processing-readonly button,
#StepProcessing.processing-readonly textarea {
    cursor: not-allowed !important;
}

#StepProcessing .processing-face-summary {
    background: rgba(0, 0, 0, 0.035);
    border-radius: 10px;
    margin-bottom: 8px;
    border-bottom: none;
}

#StepProcessing .processing-face-details[open] .processing-face-summary {
    border-bottom: none;
}

#StepProcessing .processing-face-body {
    padding: 0 0 2px 0;
}

#StepProcessing .processing-method-status {
    margin-top: 2px;
    margin-bottom: 8px;
}

#StepProcessing .product-spec-processing .MethodContenter {
    margin-top: 8px;
}

#StepProcessing #DynamicIntro {
    border-color: rgba(18, 18, 18, 0.06);
    background: rgba(0, 0, 0, 0.025);
}

/* 加工方式 chip：柔化舊版純黑 #000 選中 */
.product-spec-processing .SpecDetailDiv {
    margin-top: 4px;
    /* [2026-04-15] 目的：加工規格（如白底設定）與下方說明框拉開，避免視覺黏在一起 */
    margin-bottom: 10px;
}

.product-spec-processing .ProcessingSpecDetail,
.product-spec-processing .SpecDetail:not(.chip) {
    min-width: auto;
    height: auto;
    line-height: 1.35;
    display: inline-block;
    border-radius: 999px;
    padding: 10px 14px;
    font-size: 13px;
    font-weight: 900;
    border: 1px solid var(--border-soft);
    background: rgba(255, 255, 255, 0.65);
    color: var(--text);
    margin-bottom: 8px;
    margin-right: 8px;
    cursor: pointer;
    transition: background 0.15s ease, border-color 0.15s ease, box-shadow 0.15s ease;
}

.product-spec-processing .ProcessingSpecDetail.SpecDetailSelected {
    background: #1a1a1a !important;
    color: #fff !important;
    border-color: transparent;
    box-shadow: 0 2px 8px rgba(0, 0, 0, 0.12);
}

/* 量價表「目前區間」：不用整列黑底，改淡底＋左色條（仍依 .SpecDetailSelected 由 JS 切換） */
.product-spec-processing .QtySheet .QTYSpecName.SpecDetailSelected,
.product-spec-processing [id^="QtySheet_"] .QTYSpecName.SpecDetailSelected {
    background: #eaf2ff !important;
    color: #123b78 !important;
    border-left: 4px solid var(--brand2, #1f6feb);
    box-shadow: inset 0 0 0 1px rgba(31, 111, 235, 0.28);
    outline: none;
    outline-offset: -1px;
    font-weight: 800;
}

.product-spec-processing .QtySheet .QTYSpecName.SpecDetailSelected span,
.product-spec-processing [id^="QtySheet_"] .QTYSpecName.SpecDetailSelected span {
    color: inherit !important;
    background: transparent !important;
}

.product-spec-processing .QtySheet .QTYSpecName.SpecDetailSelected .QIPrice::after,
.product-spec-processing [id^="QtySheet_"] .QTYSpecName.SpecDetailSelected .QIPrice::after {
    content: "目前適用";
    margin-left: 6px;
    padding: 2px 6px;
    border-radius: 999px;
    background: var(--brand2, #1f6feb);
    color: #fff !important;
    font-size: 10px;
    font-weight: 800;
    line-height: 1.4;
    white-space: nowrap;
}

.product-spec-processing .SpecDetail.SpecDetailSelected:not(.chip),
.product-spec-processing .SpecDetail.SpecDetailSelected.chip:not(:has(img)) {
    background: #1a1a1a !important;
    color: #fff !important;
    border-color: transparent;
    box-shadow: 0 2px 8px rgba(0, 0, 0, 0.12);
}

/* 加工區內顏色圖片色票維持既有圓形＋藍框，不要被上方深色 pill 規則蓋掉 */
.product-spec-processing .SpecDetail.SpecDetailSelected.chip:has(img),
.product-spec-processing .chip.SpecDetailSelected:has(img) {
    background: #fff !important;
    color: inherit !important;
    box-shadow: none !important;
    border-color: #9ca3af !important;
    outline: 3px solid #1f6feb;
    outline-offset: 0;
}

.product-spec-processing .MethodContenter {
    background: rgba(255, 255, 255, 0.55);
    border: 1px solid var(--border-soft);
    border-radius: 12px;
    padding: 16px 14px 14px;
    margin-top: 12px;
    clear: both;
}

/* 說明文字：獨立一塊，與下方表單區隔 */
.product-spec-processing #DynamicIntro {
    margin-bottom: 14px;
    margin-top: 8px;
    padding: 10px 12px;
    border-radius: 10px;
    background: rgba(0, 0, 0, 0.03);
    border: 1px solid var(--border-soft);
    /* [2026-04-15] 目的：加工說明框在新 UI 改為滿版，覆蓋舊規則 #DynamicIntro{display:inline-block;} */
    display: block;
    width: 100%;
    max-width: 100%;
    box-sizing: border-box;
}

.product-spec-processing #DynamicIntro,
.product-spec-processing #DynamicIntro div {
    font-size: 12px;
    line-height: 1.6;
    color: var(--muted);
}

.product-spec-processing #DynamicIntro > div + div {
    margin-top: 4px;
}

.product-spec-processing #DynamicIntro h4 {
    font-size: 13px;
    margin: 0 0 8px 0;
    font-weight: 900;
    color: var(--text);
}

.product-spec-processing .DynamicBlock {
    padding-top: 0;
    padding-bottom: 0;
    border-bottom: none;
}

/* 白色／透明印刷圖檔預覽：棋盤格僅供辨識，不會寫入原始圖檔。 */
.product-spec-processing .DynamicPhotoBlock:has(.PrintIMG) {
    padding: 8px;
    border: 1px solid #cbd5e1;
    border-radius: 12px;
    background-color: #fff;
    background-image:
        linear-gradient(45deg, #e5e7eb 25%, transparent 25%),
        linear-gradient(-45deg, #e5e7eb 25%, transparent 25%),
        linear-gradient(45deg, transparent 75%, #e5e7eb 75%),
        linear-gradient(-45deg, transparent 75%, #e5e7eb 75%);
    background-size: 20px 20px;
    background-position: 0 0, 0 10px, 10px -10px, -10px 0;
    box-shadow: inset 0 0 0 1px rgba(255, 255, 255, 0.55);
    overflow: hidden;
}

.product-spec-processing .DynamicPhotoBlock .PrintIMG {
    display: block;
    filter: drop-shadow(0 0 1px rgba(15, 23, 42, 0.6));
}

.product-spec-processing .DynamicTitleBlock {
    display: flex;
    flex-wrap: wrap;
    align-items: flex-end;
    gap: 10px 12px;
    margin-bottom: 0;
    padding-bottom: 14px;
    margin-top: 4px;
    border-bottom: 1px solid var(--border-soft);
}

.product-spec-processing .DynamicTitleBlock > div[style*="clear"] {
    display: none !important;
}

.product-spec-processing .DynamicTitleBlock .DynamicItem {
    float: none;
    margin-right: 0;
    flex: 1 1 108px;
    min-width: 92px;
    max-width: 100%;
}

.product-spec-processing .DynamicTitleBlock .DynamicItem:has(.btnUpload) {
    flex: 1 1 100%;
    display: flex;
    flex-wrap: wrap;
    align-items: center;
    gap: 10px 14px;
    margin-top: 4px;
}

.product-spec-processing .DynamicTitle {
    text-align: left;
    font-size: 11px;
    color: var(--muted);
    font-weight: 800;
    margin-bottom: 6px;
    letter-spacing: 0.02em;
    text-transform: none;
}

.product-spec-processing .DynamicInput {
    width: 100%;
}

.product-spec-processing .DynamicInput input[type='text'],
.product-spec-processing .DynamicInput select {
    width: 100%;
    min-height: 40px;
    border-radius: 10px;
    border: 1px solid var(--border-soft);
    padding: 8px 10px;
    font-weight: 700;
    font-size: 13px;
    background: rgba(255, 255, 255, 0.92);
    box-sizing: border-box;
}

.product-spec-processing .DynamicInput select {
    cursor: pointer;
    appearance: auto;
}

.product-spec-processing .btnUpload {
    border-radius: 10px;
    border: 1px solid transparent;
    padding: 10px 18px;
    font-weight: 900;
    font-size: 13px;
    background: #1a1a1a;
    color: #fff;
    flex-shrink: 0;
}

.product-spec-processing .btnUpload:hover {
    opacity: 0.92;
}

.product-spec-processing .RecyleTimesDIV {
    font-size: 12px;
    color: var(--muted);
    font-weight: 700;
}

.product-spec-processing .RecyleTimesInput {
    min-height: 36px;
    border-radius: 10px;
    border: 1px solid var(--border-soft);
    padding: 4px 8px;
    margin: 0 6px;
    font-weight: 800;
}

.product-spec-processing .DynamicModuleBlock {
    margin-top: 12px;
    padding-top: 12px;
    border-top: 1px dashed var(--border-soft);
    display: flex;
    flex-wrap: wrap;
    gap: 8px;
    align-items: center;
}

.product-spec-processing .DynamicModuleName {
    float: none;
    border-radius: 999px;
    padding: 7px 14px;
    font-size: 12px;
    font-weight: 800;
    border: 1px solid var(--border-soft);
    background: rgba(255, 255, 255, 0.95);
    margin-right: 0;
    line-height: 1.35;
    color: var(--text);
    transition: background 0.15s ease, border-color 0.15s ease;
}

.product-spec-processing .DynamicModuleName:hover {
    background: rgba(0, 0, 0, 0.05);
    border-color: rgba(0, 0, 0, 0.12);
}

.product-spec-processing .DynamicAdd {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    border-radius: 10px;
    border: 1px solid var(--border-soft);
    background: rgba(255, 255, 255, 0.85);
    width: auto;
    min-height: 40px;
    padding: 0 16px;
    font-weight: 900;
    font-size: 13px;
    margin-top: 14px;
    cursor: pointer;
}

.product-spec-processing .DynamicAdd:hover {
    background: rgba(0, 0, 0, 0.04);
}

.product-spec-processing .QtySheet,
.product-spec-processing [id^="QtySheet_"] {
    margin-top: 16px;
    border-radius: 12px;
    overflow: hidden;
    border: 1px solid var(--border-soft);
    background: rgba(255, 255, 255, 0.65);
}

.product-spec-processing .QtySheet .QTYSpecName,
.product-spec-processing [id^="QtySheet_"] .QTYSpecName {
    display: flex;
    flex-wrap: nowrap;
    align-items: stretch;
    padding: 0;
    margin: 0;
    border-bottom: 1px solid var(--border-soft);
    background: rgba(255, 255, 255, 0.55);
}

.product-spec-processing .QtySheet .QTYSpecName > span,
.product-spec-processing [id^="QtySheet_"] .QTYSpecName > span {
    float: none !important;
    width: auto !important;
    flex: 1 1 0;
    min-width: 0;
    text-align: center;
    padding: 10px 8px;
    font-size: 12px;
    font-weight: 700;
    line-height: 1.35;
    border-right: 1px solid var(--border-soft);
    display: flex;
    align-items: center;
    justify-content: center;
}

.product-spec-processing .QtySheet .QTYSpecName > span:last-child,
.product-spec-processing [id^="QtySheet_"] .QTYSpecName > span:last-child {
    border-right: none;
}

.product-spec-processing .QtySheet .QTYSpecName > div[style*="clear"],
.product-spec-processing [id^="QtySheet_"] .QTYSpecName > div[style*="clear"] {
    display: none !important;
    width: 0 !important;
    height: 0 !important;
    margin: 0 !important;
    padding: 0 !important;
    overflow: hidden;
}

.product-spec-processing .QtySheet .QTYSpecName:first-child,
.product-spec-processing [id^="QtySheet_"] .QTYSpecName:first-of-type {
    font-weight: 900;
    background: rgba(0, 0, 0, 0.04);
    color: var(--text);
}

.product-spec-processing .QtySheet .QTYSpecName:first-child span,
.product-spec-processing [id^="QtySheet_"] .QTYSpecName:first-of-type span {
    font-size: 11px;
    font-weight: 900;
    letter-spacing: 0.02em;
    color: var(--muted);
    text-transform: none;
}

.product-spec-processing .line {
    margin: 14px 0 0 0;
    border-bottom: 1px solid var(--border-soft);
}

.product-spec-processing .FileUpload {
    border-radius: 10px;
    background: #1a1a1a !important;
    color: #fff !important;
    border-color: transparent !important;
    box-shadow: 0 2px 8px rgba(0, 0, 0, 0.1);
}

/* [2026-04-15] 目的：雲端印刷檔彈窗樣式改由 /store/css/components/upload-drive-modal.css 維護（Detail.aspx 已引用）；此處移除避免雙份 */
