body {
    position: relative;
    display: flex;
    min-height: 100vh;
    flex-direction: column;
}
body,h1,h2,h3,h4,h5,h6,p,span,a,button{
    font-family: "微軟正黑體", "Microsoft JhengHei", sans-serif, Arial;
}
.main-container{
    flex: 1;
    position: relative;
}
/* -------------------- 整體樣式 -------------------- */
a{ 
    text-decoration: none; 
    transition: all 0.2s linear 0s;
}
.transition-all{ transition: all 0.2s linear 0s;}
.hidden{ display: none;}
.word-break{ word-break: break-all;}
.text-justify{ text-align: justify;}
.img-cover{
    object-fit: cover;
    object-position: center;
    width: 100%;
    height: 100%;
}
.wrap-block{
    white-space: pre-wrap;
    word-break: break-all;
}
.fs-22px{ font-size: 22px;}
.fs-20px{ font-size: 20px;}
.fs-19px{ font-size: 19px;}
.fs-18px{ font-size: 18px;}
.fs-17px{ font-size: 17px;}
.fs-16px{ font-size: 16px;}
.fs-15px{ font-size: 15px;}
.fs-14px{ font-size: 14px;}
.fs-13px{ font-size: 13px;}
.fs-12px{ font-size: 12px;}
.ls-1{ letter-spacing: 1px;}
.ls-2{ letter-spacing: 2px;}
.lh-1{ line-height: 1;}
.lh-15{ line-height: 1.5;}
.lh-17{ line-height: 1.7;}
.flex-80{ flex: 0 0 80px;}
.bg-main{ background-color: #F8F8F8;}
.bg-major{ background-color: #002C6C;}
.text-neutral{ color: #717171;}
.bg-lightblue{ background-color: #F0F5FA;}
.text-major{ color: #002C6C;}
.text-minor{ color: #F26334;}
.text-black{ color: #262626;}
.text-gray{ color: #454545;}
.text-lightgray{ color: #696D73;}
.form-control,
.form-select,
.form-label{
    color: #1C1D1F;
}
button,
.btn:focus,
.btn:active,
.btn:focus,
.navbar-toggler:focus,
a:focus,
.btn-close:focus,
.btn-warning:focus,
.form-control:focus,
.form-select:focus,
.form-check-input:focus,
.accordion-button:focus,
.page-link:focus{
  outline: none;
  box-shadow: none;
}
@media screen and (max-width: 1199.9px){
    .lg-fs-22px{ font-size: 22px;}
    .lg-fs-20px{ font-size: 20px;}
    .lg-fs-18px{ font-size: 18px;}
    .lg-fs-17px{ font-size: 17px;}
}
@media screen and (max-width: 768.9px){
    .md-fs-16px{ font-size: 16px;}
}
@media screen and (max-width: 575.9px) {
    .sm-fs-24px{ font-size: 24px;}
    .sm-fs-20px{ font-size: 20px;}
    .sm-fs-18px{ font-size: 18px;}
    .sm-fs-17px{ font-size: 17px;}
    .sm-fs-16px{ font-size: 16px;}
    .sm-fs-15px{ font-size: 15px;}
    .sm-fs-14px{ font-size: 14px;}
    .form-control,
    .form-select{
        font-size: 15px;
    }
}
/* --------------------- 自訂統一樣式 -------------------- */
.main-container{ border-bottom: 1px solid #C4D7ED;}
.main-container.login-container,
.main-container.error-container{ 
    border-top: 1px solid #C4D7ED;
}
.btn-major{
    font-weight: 700;
    color: #ffffff;
    padding: 0.4rem 2.2rem;
    background: #002c6c;
    border-radius: 0.3rem;
    transition: all 0.2s linear 0s;
}
.btn-major:hover{ 
    color: #ffffff;
    background: #008dbd;
}
.btn-minor{
    font-weight: 700;
    color: #ffffff;
    padding: 0.4rem 2.2rem;
    background: #F26334;
    border-radius: 0.3rem;
    transition: all 0.2s linear 0s;
}
.btn-minor:hover{ 
    color: #ffffff;
    background: #a82c05;
}
.btn-outline-minor{
    font-weight: 700;
    color: #F26334;
    padding: 0.4rem 2.2rem;
    border: 2px solid #F26334;
    border-radius: 0.3rem;
    transition: all 0.2s linear 0s;
}
.btn-outline-minor:hover{ 
    color: #ffffff;
    background: #F26334;
}
/* 頁面標題 */
h5.page-subtitle{ position: relative;}
h5.page-subtitle div{ 
    position: relative; 
    z-index: 1;
    padding: 0px 28px 0px 0px;
}
h5.page-subtitle:after{
    content: '';
    position: absolute;
    top: 50%;
    right: 0;
    display: inline-block;
    width: 100%;
    height: 1px;
    background-color: #ffffff;
    z-index: 0;
}
.block-title{ 
    padding: 0px 0px 0px 16px;
    border-left: 8px solid #002C6C;
    color: #262626;
    font-weight: bold;
}
/*back to top*/
.back-to-top{
  position: fixed;
  z-index: 99999;
  right: 20px;
  bottom: 20px;
  width: 30px;
  height: 30px;
  line-height: 30px;
  text-align: center;
  border-radius: 50%;
  border-width: 0px;
  padding: 0px;
  background-color: #fff;
  filter: drop-shadow(0px 0px 4px rgba(0,0,0,0.3));
  opacity: 100%;
  transition: opacity 0.5s;
}
.back-to-top:hover{ opacity: 60%;}
.opacity-0{ opacity: 0%;}
/* 分頁 */
.page-item:first-child .page-link {
    border-top-left-radius: 0;
    border-bottom-left-radius: 0;
}
.page-item:last-child .page-link {
    border-top-right-radius: 0;
    border-bottom-right-radius: 0;
}
.page-item .page-link{
    color: #8a8a8a;
    font-size: 15px;
    padding: 0px;
    border: 1px solid #8a8a8a;
    width: 28px;
    height: 28px;
    line-height: 26px;
    text-align: center;
    background: #ffffff;
    margin: 0 8px;
}
.page-item.disabled .page-link{
    color: #bbbbbb;
    pointer-events: none;
    background-color: #ffffff;
    border: 1px solid rgba(138,138,138,0.3);
}
.page-item.active .page-link{
    color: #ffffff;
    background-color: #002C6C;
    border: 1px solid #002C6C;
}
/* --------------------- 登入註冊 -------------------- */
.login-box{
    border: 1px solid #b1b3b3;
    border-top: 7px solid #f26334;
    background-color: #ffffff;
}
.login-container .form-control{
    border-radius: 0px;
    border-color: #D6D6D6;
    padding: 10px 20px;
}
.login-container .form-select{
    border-radius: 0px;
    border-color: #D6D6D6;
    padding: 10px 36px 10px 20px;
}
.login-container .form-control.login-pw{
    padding: 10px 36px 10px 20px;
}
.login-container .form-control::placeholder{
    color: #8D9DA3;
}
.login-container .icon-toggler{
    position: absolute;
    right: 12px;
    top: 50%;
    transform: translateY(-50%);
    color: #606060;
    font-size: 20px;
}
.login-container .form-check-input{
    border-radius: 2px;
    border-width: 2px;
    border-color: #8D9DA3;
    margin-top: 0.2em;
}
.login-container .form-check-input:checked{
    background-color: #8D9DA3;
}
@media screen and (max-width: 575.9px) {
    .login-container .form-control{ padding: 8px 14px;}
    .login-container .form-select{ padding: 8px 30px 8px 14px;}
    .login-container .form-control.login-pw{ padding: 8px 30px 8px 14px;}
}
/* --------------------- header footer -------------------- */
.header .logo-text{ color: #454545;}
.header .nav-item{ padding: 0px 8px;}
.header .nav-link{
    padding: 12px 4px;
    font-size: 17px;
    color: #565656;
    font-weight: 700;
}
.offcanvas-start{ width: 300px;}
.offcanvas-menu .nav-link{
    border-bottom: 1px solid #dddddd;
    font-size: 15px;
    padding: 12px 0px;
}
.footer .footer-contact{
    color: #454545;
    font-size: 14px;
}
.footer .footer-contact i{
    flex: 0 0 28px;
}
@media screen and (max-width: 575.9px) {
    .header-logo{ height: 52px;}
    .btn-header-login{ 
        display: inline-block;
        border-radius: 50%;
        width: 34px;
        height: 34px;
        text-align: center;
        padding: 0px;
        line-height: 34px;
    }
}
/* --------------------- 首頁 -------------------- */
.page-header{
    background-image: url('../images/sectors01.jpg');
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    height: 250px;
    padding: 3em 1em;
    background-color: #C8C3BF;
    background-position: center;
    background-size: cover;
    text-align: left;
}
.frame-bk{ border: 1px solid #A6B0BB;}
/* --------------------- 會員編輯 -------------------- */
.pw-modal .modal-content{ border-radius: 0px;}
.pw-modal .modal-header{
    border-radius: 0px;
    border-top: 7px solid #f26334;
    border-bottom-width: 0px;
}
.pw-modal .form-control{
    border-radius: 0px;
    line-height: 1.8;
    font-size: 15px;
}
.profile-container .nav-tabs {
    border-bottom: 1px solid #dee2e6;
}
.profile-container .nav-tabs .nav-link{
    color: #cccccc;
    border-width: 0px 0px 1px 0px;
    font-size: 20px;

    margin-bottom: -1px;
}
.profile-container .nav-tabs .nav-link.active{
    color: #F26334;
    border-width: 0px 0px 1px 0px;
    border-bottom-color: #F26334;
}
/* --------------------- 商品管理 -------------------- */
.btn-search{
    width: 39px;
    height: 39px;
    text-align: center;
    line-height: 37px;
    padding: 0px;
    background-color: #002C6C;
    border-radius: 50%;
    border-top-left-radius: 50%!important;
    border-bottom-left-radius: 50%!important;
    color: #ffffff;
}
.btn-search:hover{
    background-color: #008DBD;
    transition: all 0.2s linear 0s;
    color: #ffffff;
}
/* 表格 */
.table-style thead tr th{
    border-bottom-width: 1px;
    border-color: #dfdfdf!important;
    padding: 10px 8px;
    font-size: 14px;
}
.table-style tbody tr td{
    font-size: 14px;
    word-break: break-all;
    color: #4d4d4d;
    border-bottom-width: 1px;
    padding: 10px 8px;
}
.table-style .row-hide{ 
    flex: 0 0 100%;
    padding: 4px 0px;
}
.table-style .mobile-title{
    flex: 0 0 64px;
    color: #a1a1a1;
}
.table-style .mobile-content{
    flex-grow: 1;
    color: #5a5a5a;
}
.table-style .list-img{
    display: inline-block;
    width: 40px;
    height: 40px;
    padding: 0px;
    position: relative;
    background-color: #ffffff;
}
.table-style .list-img img{
    width: 38px;
    height: 38px;
    object-fit: contain;
    object-position: center;
    background-color: #ffffff;
}
.table-style .img-zoom{
    position: absolute;
    top: 50%;
    left: 50%;
    transform: translate(-50%,-50%);
    padding: 0px;
    width: 40px;
    height: 40px;
    font-size: 23px;
    color: #ffffff;
    opacity: 0.75;
    z-index: 2;
    transition: all 0.2s linear 0s;
}
.table-style .img-zoom i{
    position: absolute;
    font-size: 14px;
    top: 4px;
    right: 4px;
}
.table-style .img-zoom:hover{ opacity: 1;}
.table-style .list-img:after{
    position: absolute;
    top: 0px;
    left: 0px;
    width: 100%;
    height: 100%;
    content: "";
    background-color: rgba(0,0,0,0.2);
    z-index: 1;
}
/* 商品列表單獨調整 */
.table-products .th-img{ width: 112px;}
.table-products .th-action{ width: 212px;}
.table-products .th-name{ width: 180px;}
.table-products .th-linkNum{ width: 80px;}/*20250124 add*/
.table-products .mobile-items .mobile-img{ flex: 0 0 56px;}
.text-overflow{
    overflow: hidden;
    text-overflow: ellipsis;
    display: -webkit-box;
    -webkit-box-orient: vertical;
    -webkit-line-clamp: 4;
}
/*工廠列表單獨調整*/
.table-factory .th-phone{ width: 120px;}
.table-factory .th-vat{ width: 100px;}
.table-factory .th-default{ width: 80px;}
.table-factory .th-gln{ width: 136px;}
.table-factory .th-action{ width: 240px;}
@media screen and (max-width: 1199.9px) {
    .table-products .th-action{ width: 120px;}
    .table-style .mobile-action a{ margin: 2px 0px;}
}
@media screen and (max-width: 991.9px) {
    .table-style tbody tr td {
        border-top-width: 1px;
    }
    .table-style .mobile-action{
        flex: 0 0 220px;
        text-align: right;
    }
    .table-style .mobile-action a{
        margin: 0px 4px 8px 0px;
    }
    .table-style .row-mobile,
    .table-style .th-mobile{
        display: none;
    }
    .table-style .mobile-action { align-self: center;}
    

    .table-qsafer thead{
        border: none;
        clip: rect(0 0 0 0);
        height: 1px;
        margin: -1px;
        overflow: hidden;
        padding: 0;
        position: absolute;
        width: 1px;
    }
    .table-qsafer td:before{
        content: attr(data-label);
        display: flex;
        flex: 0 0 76px;
        text-transform: uppercase;
        color: #555555;
        font-weight: bold;
    }
    .table-qsafer tbody tr{
        display: block;
        border-width: 1px;
        padding: 8px 0px;
        margin-bottom: 12px;
    }
    .table-qsafer tbody tr td{ 
        display: flex;
        flex-wrap: nowrap;
        padding: 4px 8px;
        border-width: 0px;
    }

    .table-qsafer.table-factory td.td-active:before{
        flex: 0 0 0px;
    }
    .table-qsafer.table-factory td.td-active{
        flex-wrap: wrap;
        justify-content: end;
    }
    .table-qsafer.table-factory td.td-active a{
        margin: 2px;
    }
}
@media screen and (max-width: 575.9px) {
    .table-style .mobile-action {
        flex: 0 0 100%;
        display: flex;
        margin-top: 12px;
    }
    .table-style .mobile-action a{
        flex-grow: 1;
        text-align: center;
        border-radius: 0px;
        padding: 8px;
    }
}
/* --------------------- 新增或編輯商品 -------------------- */
.tab-edit .nav-link{ color: #676767;}
.tab-edit .nav-link.active,
.tab-edit .nav-link:focus{
    background-color: #0d6efd;
    border-color: #0d6efd;
    color: #ffffff;
}
.tab-edit .nav-link:hover{
    border-color: #0d6efd;
    color: #262626;
}
.tab-edit .nav-link.active:hover{ color: #ffffff}
.tab-edit{ border-bottom: 2px solid #0d6efd;}
.btn-add{
    width: 44px;
    height: 44px;
    padding: 0px;
    line-height: 44px;
    text-align: center;
    border-radius: 50%;
    margin: 20px;
    margin-left: 40px;
}
/* 編輯器 */
.editor-info{ overflow-x: hidden;}
.ck-content{
    min-height: 200px;
    max-height: 400px;
    overflow-y: auto;
}
/* 上傳檔案 */
input[type=file].uploadPdf{
    background-color: #ffffff;
}
input[type=file].uploadPdf::-webkit-file-upload-button,
input[type=file].uploadPdf::file-selector-button{
    border-width: 0px;
}
/* 上傳圖片 */
.box{
    position: relative;
    width: 240px;
    height: 280px;
    border: 1px solid #D6D6D6;
    background-color: #ffffff;
    transition: all 0.3s cubic-bezier(0.25, 0.8, 0.25, 1);
}
.clear-img{
    position: absolute;
    top: 8px;
    right: 8px;
    width: 24px;
    height: 24px;
    padding: 0px;
    line-height: 22px;
    text-align: center;
    border-radius: 50%;
    font-size: 13px;
}
.btn-delete-item{
    position: absolute;
    top: 8px;
    left: 8px;
    width: 24px;
    height: 24px;
    padding: 0px;
    line-height: 22px;
    text-align: center;
    border-radius: 50%;
    font-size: 13px;
}
.upload-options{
    position: relative;
    height: 40px;
    background-color: #002C6C;
    cursor: pointer;
    overflow: hidden;
    text-align: center;
    transition: background-color ease-in-out 150ms;
}
.upload-options:hover{ background-color: #008DBD;}
.upload-options input{
    width: 0.1px;
    height: 0.1px;
    opacity: 0;
    overflow: hidden;
    position: absolute;
    z-index: -1;
}
.upload-options label{
    display: flex;
    align-items: center;
    width: 100%;
    height: 100%;
    font-weight: 400;
    text-overflow: ellipsis;
    white-space: nowrap;
    cursor: pointer;
    overflow: hidden;
}
.upload-options label::after{
    content: "選擇圖片";
    position: absolute;
    font-size: 15px;
    top: 50%;
    left: 50%;
    color: #ffffff;
    transform: translate(-50%,-50%);
    z-index: 0;
}
.js--image-preview{
    height: 240px;
    width: 100%;
    position: relative;
    overflow: hidden;
    background-image: url("../images/uploadimg.jpg");
    background-color: #ffffff;
    background-position: center center;
    background-repeat: no-repeat;
    background-size: contain;
}
.js--image-preview.js--no-default::after{ display: none;}
/* 範例圖片視窗 */
.example-modal .btn-close{
    position: absolute;
    top: 20px;
    right: 20px;
    width: 24px;
    height: 24px;
    padding: 0px;
    line-height: 24px;
    text-align: center;
    opacity: 1;
    border-radius: 50%;
    background: #F26334 url("data:image/svg+xml,%3csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 16 16' fill='%23fff'%3e%3cpath d='M.293.293a1 1 0 011.414 0L8 6.586 14.293.293a1 1 0 111.414 1.414L9.414 8l6.293 6.293a1 1 0 01-1.414 1.414L8 9.414l-6.293 6.293a1 1 0 01-1.414-1.414L6.586 8 .293 1.707a1 1 0 010-1.414z'/%3e%3c/svg%3e") center/14px auto no-repeat;
}
.example-modal .btn-close:hover{
    background: #a82c05 url("data:image/svg+xml,%3csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 16 16' fill='%23fff'%3e%3cpath d='M.293.293a1 1 0 011.414 0L8 6.586 14.293.293a1 1 0 111.414 1.414L9.414 8l6.293 6.293a1 1 0 01-1.414 1.414L8 9.414l-6.293 6.293a1 1 0 01-1.414-1.414L6.586 8 .293 1.707a1 1 0 010-1.414z'/%3e%3c/svg%3e") center/14px auto no-repeat;
}
/*連結類型管理*/

@media screen and (max-width: 575.9px) {
    .ck-content{ max-height: 520px;}
    input[type=file].uploadPdf::-webkit-file-upload-button,
    input[type=file].uploadPdf::file-selector-button{
        font-size: 15px;
    }
}
/* --------------------- 顯示商品資訊頁 -------------------- */
.product-profile-container .top-banner{
    background-repeat: no-repeat;
    background-size: cover;
    background-image: url('../images/profile-header.jpg');
    background-position: center;
}
.detail-box{
    background: #ffffff;
    box-shadow: 0px 0px 4px rgba(0,0,0,0.25);
    margin-top: -20px;
}
.product-img{
    position: relative;
    text-align: center;
}
.product-img-show{
    max-height: 240px;
    max-width: 100%;
}
.product-img-prev{
    position: absolute;
    top: 50%;
    left: 0px;
    border-width: 0px;
    background-color: #F26334;
    color: #ffffff;
    opacity: 0.75;
}
.product-img-next{
    position: absolute;
    top: 50%;
    right: 0px;
    border-width: 0px;
    background-color: #F26334;
    color: #ffffff;
    opacity: 0.75;
}
.product-img-prev:hover,
.product-img-next:hover{
    opacity: 1;
}
.product-item{ 
    word-break: break-all;
    margin-bottom: 4px;
    color: #717171;
}
.product-item > div:first-child{ flex: 0 0 88px;}
.product-info p,
.product-info span,
.product-info li{ 
    color: #454545;
    line-height: 1.6;
}
.product-info img{ max-width: 100%;}
/*tab ul*/
.tab-productProfile .nav-item{
    display: block;
    flex: 1 1 auto;
}
.tab-productProfile .nav-link{
    width: 100%;
    border: 1px solid #dddddd;
    border-left-width: 0px;
    border-radius: 0px;
    color: #4d4d4d;
    background-color: #f5f5f5;
}
.tab-productProfile .nav-item:first-child .nav-link{
    border-left-width: 1px;
}
.tab-productProfile .nav-link.active{
    border-color: #dddddd;
    color: #F26334;
    font-weight: bold;
}
.tab-productProfile .nav-link:hover{
    border-color: #dddddd;
    color: #F26334;
}
@media screen and (max-width: 575.9px) {
    .product-item{ font-size: 15px;}
    .product-item > div:first-child{ flex: 0 0 80px;}
    .product-info p,
    .product-info span,
    .product-info li{ 
        font-size: 15px;
    }
}
@media screen and (max-width: 359.9px) {
    .tab-productProfile .nav-link{
        padding: 0.3rem 0.6rem;
    }
}