.product-detail-wrapper {
  background-color: rgba(var(--color-background, var(--color-page-background)));
}
.product-detail {
  background-color: rgba(var(--color-background, var(--color-page-background)));
}
.product-detail__row {
  display: flex;
  flex-direction: column;
  gap: 12px;
}
.product-detail__col {
  display: flex;
  flex-direction: column;
  gap: 12px;
}
.block-description {
  color: rgba(var(--color-light-text));
}
#lf-quick-add-modal-content {
  padding-inline: var(--page-padding);
}
@media (max-width: 959px) {
  .product-detail__info {
    width: 100%;
  }
}
@media (min-width: 960px) {
  .product-detail__info {
    width: 100%;
  }
  .product-detail[data-desktop-direction="row"] {
    z-index: var(--z-index-focus);
  }
  .product-detail[data-desktop-direction="row"] .product-detail__info,
  .product-detail[data-desktop-direction="row"] .product-detail__media {
    position: sticky;
    inset-block-start: var(--detail-padding-block-start, 0);
    z-index: var(--z-index-hover);
  }
  .product-detail[data-desktop-direction="row"] .product-detail__col--small {
    width: 34%;
  }
  .product-detail[data-desktop-direction="row"]
    .product-detail__col--small
    + .product-detail__col {
    width: 66%;
  }
  .product-detail[data-desktop-direction="row"] .product-detail__col--medium {
    width: 50%;
  }
  .product-detail[data-desktop-direction="row"]
    .product-detail__col--medium
    + .product-detail__col {
    width: 50%;
  }
  .product-detail[data-desktop-direction="row"] .product-detail__col--large {
    width: 66%;
  }
  .product-detail[data-desktop-direction="row"]
    .product-detail__col--large
    + .product-detail__col {
    width: 34%;
  }
  .product-detail[data-desktop-direction="row"] .product-detail__info--sticky,
  .product-detail[data-desktop-direction="row"]
    .product-detail__media-group--sticky,
  .product-detail__main[data-desktop-direction="row"]
    .product-detail__info--sticky,
  .product-detail__main[data-desktop-direction="row"]
    .product-detail__media-group--sticky {
    position: sticky;
    inset-block-start: var(--detail-padding-block-start, 0);
    align-self: flex-start;
  }
}

/* ETL-MIGRATION: pdp-theme-stage1-css 2026-05-10
   Stage 1 keeps existing custom-code DOM behavior enabled and moves product-page styles into the theme asset.
   Do not add global observers or monkey patches here. */
/* ===== PDP Conversion Boost — Mobile Only ===== */
@media (max-width: 768px) {

  /* --- 1. 度数选择器：纵列 → 3 列网格 --- */
  .product-detail__variant-picker .variant-picker__group:last-child .variant-picker__options {
    display: grid !important;
    grid-template-columns: repeat(3, 1fr) !important;
    gap: 6px !important;
  }
  .product-detail__variant-picker .variant-picker__group:last-child .variant-picker__option {
    white-space: nowrap !important;
    font-size: 14px !important;
    font-weight: 500 !important;
    padding: 10px 4px !important;
    text-align: center !important;
    min-height: 48px !important;
    display: flex !important;
    align-items: center !important;
    justify-content: center !important;
  }

  /* --- 2. 底部悬浮栏 --- */
  .pdp-sticky-bar {
    position: fixed;
    bottom: 0; left: 0; right: 0;
    z-index: 999;
    background: #fff;
    border-top: 1px solid #e0e0e0;
    box-shadow: 0 -2px 10px rgba(0,0,0,0.08);
    padding: 10px 16px;
    padding-bottom: calc(10px + env(safe-area-inset-bottom));
    display: flex;
    align-items: center;
    gap: 12px;
    transform: translateY(100%);
    transition: transform 0.25s ease-out;
    font-family: 'Noto Sans JP', sans-serif;
  }
  .pdp-sticky-bar.show { transform: translateY(0); }
  .pdp-sticky-bar .psb-price { flex-shrink: 0; }
  .pdp-sticky-bar .psb-price-val {
    font-size: 20px; font-weight: 900; color: #1a3a4a;
  }
  .pdp-sticky-bar .psb-price-tax {
    font-size: 12px; color: #666;
  }
  .pdp-sticky-bar .psb-btn {
    flex: 1;
    height: 48px;
    border: none; border-radius: 6px;
    font-size: 17px; font-weight: 700;
    cursor: pointer;
    transition: background 0.2s;
    color: #fff;
    background: #1a3a4a;
  }
  .pdp-sticky-bar .psb-btn:active { background: #16313e; }

  /* --- 3. 信任徽章条（加购按钮下方） --- */
  .pdp-trust-strip {
    display: flex !important;
    justify-content: center;
    flex-wrap: wrap;
    gap: 8px 12px;
    padding: 10px 12px;
    background: #f5f0e8;
    border-radius: 8px;
    margin: 8px 0;
    font-size: 14px;
    line-height: 1.4;
    color: #3a3a3a;
    font-weight: 600;
    font-family: 'Noto Sans JP', sans-serif;
  }
  .pdp-trust-strip span { white-space: nowrap; }
  .pdp-trust-strip .ptc { color: #c9a96e; }

  /* 页面底部留出悬浮栏空间 */
  body.pdp-boosted {
    padding-bottom: 78px !important;
  }

  /* flash 原 ATC 按钮 */
  @keyframes pdpAtcFlash {
    0%   { box-shadow: 0 0 0 0 rgba(26,58,74,0.55); }
    50%  { box-shadow: 0 0 0 8px rgba(26,58,74,0.0); }
    100% { box-shadow: 0 0 0 0 rgba(26,58,74,0.0); }
  }
  .pdp-atc-flash {
    animation: pdpAtcFlash 1.2s ease-out 2;
    outline: 2px solid #1a3a4a !important;
    outline-offset: 4px !important;
  }

  /* Toast 提示 */
  .pdp-variant-toast {
    position: fixed;
    left: 50%; bottom: 100px;
    transform: translateX(-50%);
    max-width: 340px;
    background: #1a3a4a;
    color: #fff;
    padding: 12px 18px;
    border-radius: 8px;
    font-size: 15px;
    line-height: 1.4;
    font-weight: 600;
    z-index: 1000;
    opacity: 0;
    transition: opacity 0.2s ease;
    pointer-events: none;
    font-family: 'Noto Sans JP', sans-serif;
    box-shadow: 0 4px 12px rgba(0,0,0,0.15);
  }
  .pdp-variant-toast.show { opacity: 1; }
}

/* Desktop: 信任条显示 */
@media (min-width: 769px) {
  .pdp-sticky-bar { display: none !important; }
  .pdp-trust-strip {
    display: flex !important;
    justify-content: center;
    gap: 16px;
    padding: 12px 16px;
    background: #f5f0e8;
    border-radius: 8px;
    margin: 10px 0;
    font-size: 14px;
    color: #3a3a3a;
    font-weight: 600;
    font-family: 'Noto Sans JP', sans-serif;
  }
  .pdp-trust-strip .ptc { color: #c9a96e; }
}

/* =========================================================================
   模块 19 · PDP 手机端首屏紧凑化（老花眼基线 + 间距狠压）
   ========================================================================= */
@media (max-width: 767px) {

  /* Gallery：缩略图压到 56×56，去金框 */
  body.pdp-boosted .product-detail__media-gallery {
    margin-bottom: 8px !important;
  }
  body.pdp-boosted .media-gallery__thumbnail {
    width: 56px !important;
    height: 56px !important;
    min-width: 56px !important;
    min-height: 56px !important;
    border-radius: 6px;
    overflow: hidden;
  }
  body.pdp-boosted .media-gallery__thumbnail-image {
    width: 56px !important;
    height: 56px !important;
    object-fit: cover;
  }
  body.pdp-boosted .media-gallery__thumbnails {
    margin-top: 8px !important;
  }
  body.pdp-boosted .media-gallery__thumbnail.is-active,
  body.pdp-boosted .media-gallery__thumbnail.is-select {
    outline: 2px solid #a88547;
    outline-offset: -2px;
  }
  body.pdp-boosted .media-gallery__thumbnail:not(.is-active):not(.is-select) {
    opacity: 0.78;
    transition: opacity .2s ease;
  }
  body.pdp-boosted .product-media-preview__arrow { display: none !important; }

  /* 标题 18px 老花眼基线 */
  body.pdp-boosted .product-detail__title {
    font-size: 18px !important;
    line-height: 1.4 !important;
    font-weight: 600;
    margin: 0 0 8px 0 !important;
    padding: 0 !important;
    color: #1a1a1a;
    display: -webkit-box !important;
    -webkit-line-clamp: 2 !important;
    -webkit-box-orient: vertical !important;
    overflow: hidden !important;
    max-height: calc(18px * 1.4 * 2) !important;
  }
  body.pdp-boosted .product-plugin-comment-rate-star { margin: 0 0 6px 0 !important; }
  body.pdp-boosted .product-detail__price { margin: 0 0 6px 0 !important; }
  body.pdp-boosted .product-price {
    font-size: 22px !important;
    line-height: 1.2 !important;
    /* color removed (2026-04-30): 跟桌面端 sale-red 一致 */
    font-weight: 600;
  }
  body.pdp-boosted [class*="sales__promotionTag"],
  body.pdp-boosted [class*="sales__promotionReminder"] {
    line-height: 1.35 !important;
    margin: 0 0 6px 0 !important;
  }
  body.pdp-boosted .member-plugin-branding-widget-container,
  body.pdp-boosted .member-plugin-point-info__container {
    font-size: 14px !important;
    line-height: 1.4 !important;
    margin: 0 0 6px 0 !important;
  }
  body.pdp-boosted .member-plugin-branding-widget-container a,
  body.pdp-boosted .member-plugin-point-info__container a {
    font-size: 14px !important;
  }
  body.pdp-boosted .product-detail__product-id,
  body.pdp-boosted .product-block-item.body4 {
    font-size: 14px !important;
    line-height: 1.4 !important;
    color: #666 !important;
    margin: 0 0 4px 0 !important;
  }
  /* product-detail__row 全部贴边 */
  body.pdp-boosted .product-detail__row {
    margin-top: 2px !important;
    margin-bottom: 2px !important;
    padding-top: 0 !important;
    padding-bottom: 0 !important;
  }
  /* variant-picker 各 group（カラー/機能/度数）之间 6px 节奏 */
  body.pdp-boosted .variant-picker__group {
    margin-top: 6px !important;
    margin-bottom: 6px !important;
    padding-top: 0 !important;
    padding-bottom: 0 !important;
    border-top: none !important;
    border-bottom: none !important;
  }
  body.pdp-boosted .variant-picker__group:first-child {
    margin-top: 4px !important;
  }
  body.pdp-boosted .variant-picker__group-head {
    font-size: 16px !important;
    line-height: 1.35 !important;
    font-weight: 600 !important;
    margin: 0 0 4px 0 !important;
    padding: 0 !important;
    color: #1a1a1a;
  }
  /* v5-fix8 2026-04-25：撤销 overflow:visible（覆盖了主题 overflow-x:auto → 色板多于一屏
     时无法横滑）。改用 box-shadow inset 内嵌选中态边框，不出容器、不需要 visible。 */
  body.pdp-boosted .variant-picker__options {
    margin: 0 !important;
    padding: 4px !important;
    row-gap: 8px !important;
    column-gap: 8px !important;
    box-sizing: border-box !important;
  }
  body.pdp-boosted .variant-picker__option {
    position: relative;
    box-sizing: border-box;
    transition: box-shadow .15s ease;
  }
  body.pdp-boosted .variant-picker__option.selected,
  body.pdp-boosted .variant-picker__option.is-active,
  body.pdp-boosted .variant-picker__option.pdp-is-checked,
  body.pdp-boosted .variant-picker__option[aria-checked="true"] {
    box-shadow: inset 0 0 0 2px #1a3a4a !important;
    border-color: #1a3a4a !important;
  }
  body.pdp-boosted .variant-picker__image { border-radius: 8px; }
  body.pdp-boosted .product-detail__quantity-selector { margin-top: 4px !important; }

  /* 空壳清扫 */
  body.pdp-boosted .custom-html-block:empty,
  body.pdp-boosted .product-detail__row:empty,
  body.pdp-boosted .product-block-item:empty,
  body.pdp-boosted [class*="product-plugin"]:empty,
  body.pdp-boosted [class*="member-plugin"]:empty {
    display: none !important;
  }
  /* 兜底：product-detail__info 直接子元素上下 margin 4px */
  body.pdp-boosted .product-detail__info > * {
    margin-top: 4px !important;
    margin-bottom: 4px !important;
  }
  body.pdp-boosted .product-detail__info > *:first-child {
    margin-top: 0 !important;
  }

  /* LINE 气泡定位（position:fixed 由 all-in-one 模块 09 设） */
  body.pdp-boosted .line-badge {
    bottom: 108px !important;
    right: 12px !important;
    top: auto !important;
    left: auto !important;
    width: 44px !important;
    height: 44px !important;
  }
  body.pdp-boosted .line-badge img,
  body.pdp-boosted .line-badge svg {
    width: 44px !important;
    height: 44px !important;
  }
}

/* PDP tax marker styles */
ブロックで一度注入 (重複適用防止)

  安装方式 (Shopline 後台):
    Online Store > Theme > Edit code > 自定义代码
    将整个文件追加到 custom-code 末尾。
    既存の cart-mobile-fix / checkout-cod-tax-notice と同階層で OK。

  调试桥 (Console に貼り付け):
    __etlPdpTaxMarker.status()    // 主価格ノード / 注入状態
    __etlPdpTaxMarker.reinject()  // 強制再注入
    __etlPdpTaxMarker.setText('税込価格')  // 文案差し替え (検証用)

  改文案: TAX_LABEL 定数を編集。

  版本: 2026-04-30 v2 (perf fix - observer scope + debounce)
  负责人: 小美 (Eterlens Visual Design) / 性能：性能优化 agent
-->
<style id="etl-pdp-tax-marker-style">
  /* PDP 主価格 (税込) ラベル */
  .tax-included-marker {
    display: inline;
    font-size: 14px;
    font-weight: 400;
    color: #65605c;
    margin-left: 6px;
    letter-spacing: 0.02em;
    line-height: 1.4;
    vertical-align: baseline;
    white-space: nowrap;
    /* 主価格と同じ baseline に乗せ、加購ボタン領域には影響しない */
  }
  /* compare (划線) 価が後続する場合、税込ラベルとの間に最低限の余白 */
  .product-price__item .tax-included-marker + * {
    margin-left: 4px;
  }

/* Product customizer visual styles migrated from enabled custom-code snippets. */
.plugin-pod-default-group-content--show-preview{
    padding:0 3px 20px;
  }
  .plugin-pod-select-custom-entry{
    padding:0 5px;
  }
  .plugin-pod-table-select-modal .plugin-pod-select-custom-modal-title{
    text-align:center;
    position: fixed;
    text-align: center;
    width: 100%;
    background: #fff;
    z-index: 999;
  }
  .plugin-pod-table-select-modal .plugin-pod-select-custom-option{
    text-align: center;
    justify-content: center;
  }
  .plugin-pod-table-select-modal.plugin-pod-modal.plugin-pod-select-custom-modal .plugin-pod-modal-wrap .plugin-pod-modal-body{
    max-height: 420px;
  }
  .plugin-pod-table-select-modal .plugin-pod-select-custom-option:hover{
    background:unset;
  }
  .plugin-pod-col:has(.plugin-pod-table-select-empty) {
  display: none;
}
.plugin-pod-table .plugin-pod-row{
  justify-content: flex-start;
}
.plugin-pod-table-select-modal .plugin-pod-select-custom-option:has(svg) {
  background: var(--pod-table-column-header-bg-color);
}
.plugin-pod-select-custom-list__modal.plugin-pod-table-select-list{
  margin-top:50px;
}
.plugin-pod-select-custom-option-text{
font-weight:600 !important;
}
/* 评论插件 */
.plugin-product-comment-product-subTitle-start{
margin:0 !important;
height:auto !important;
}

/* Product detail style collection migrated from enabled custom-code snippets. */
.product__info-description{max-width:750px;margin:0 auto;}
.product__info-description p {margin-block: 0 !important;}
.product-recommend .swiper-container { 
  padding-bottom: 0 !important;
  margin-bottom: 60px !important;
}
@media screen and (max-width: 959px) {
  #shopline-section-main-product-info .page-width{
    padding-left:0;
    padding-right:0;
  }
  .product__info-wrapper{
    padding:0 15px
  }
  .product__media-list.grid{
    margin-top:0;
  }
  .products-detail-info>*+.m-20,.products-detail-info>*+.m-26 {
        margin: 6px 0;
  }
  .lool-page .lool-{
    padding:20px 14px !important;
  }
  .lool-page .l-py-\[32px\]{
    padding:0;
  }
}
@media screen and (max-width: 699px) {
.product-preview-container .product-preview-row .product-detail-col-info {
        padding: 0 10px;
    }
}
#headlessui-portal-root .lool-frame-detail{
  color: #000 !important;
  background-color: #fff !important;
}
#headlessui-portal-root .l-relative.l-flex-1.l-overflow-y-auto,.lool-dialog-panel{
  background-color: #f8f8f8 !important;
}
#headlessui-portal-root .lool-back-btn,.lool-dialog-panel{
  color: #000 !important;
}
.lool-frame-detail .l-font-bold.l-text-\[20px\]{
  color:red;
}
.lool-select>select{
  background-color: #fff !important;
  color: #000 !important;
}
.lool-px-selector .l-font-extrabold{
  padding:10px;
  background-color:#edf2fc;
}
#singleUserDualPd,#progressiveUserDualPd{
  border: 1px solid;
}
.lool-option>div>div,.lool-option>div{
  gap:10px;
}
.lool-option .lool-option-title,.lool-option .lool-shopline-option-price{
  font-weight:bold;
}
.lool-option-checked {
    outline-color: #0006cf !important;
}

.plugin-pod-table-wrapper{
  padding-bottom:10px;
}
.plugin-pod-table .plugin-pod-col{
  min-width:auto !important;
  padding:0 5px !important;
}
.plugin-pod-table{
  width:auto !important;
}
.plugin-pod-table-wrapper .plugin-pod-colTitle{
  min-width:auto !important;
  padding:0 5px !important;
}
.plugin-pod-table textarea,.plugin-pod-table .plugin-pod-input-textarea-hidden{
  padding:0 !important;
  line-height: 43px;
}
.plugin-pod-title,.plugin-pod-title>span {
    /* font-weight: 600 !important; */
}
.plugin-pod-dropdown-tile-item{
  font-size:14px;
}
.plugin-pod-title{
  background: #669999;
  color: #fff;
  padding: 5px;
  border-radius: 5px;
}
.plugin-pod-dropdown-tile-item__active {
    border-color: #669999;
    box-shadow: 0 0 0 1px #669999;
}
@media screen and (max-width: 959px) {
  .plugin-pod-table textarea,.plugin-pod-table .plugin-pod-input-textarea-hidden{
    font-size:11px;
  }
  .plugin-pod-dropdown-tile-item{
    font-size:13px;
  }
}
  /* 商品定制&产品选项&套装插件 style */
  #plugin-pod .plugin-pod-default-item-list-item {
    background-color: #fafafa;
  }
  #plugin-pod .plugin-pod-title{
    background:#efefef;
  }
  #plugin-pod .plugin-pod-title span:first-child{
    color:#000;
    font-weight: 700 !important;
  }
  #plugin-pod .plugin-pod-title-require-icon{
    color:#e60012;
  }
  #plugin-pod ..plugin-pod-dropdown-tile-item{
    border: 1px solid #e6e6e6;
  }
  #plugin-pod .plugin-pod-dropdown-tile-item__active{
    border-color: #000;
    box-shadow: 0 0 0 1px #000;
  }
  /* 商品定制&产品选项&套装插件 style */

   /* Shopline专用样式隔离 - 避免与平台样式冲突 */
    .sl-eterlens-text-block-1 {
        background-color: #f9f9f9 !important;
        font-family: -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, 'Hiragino Sans', 'Noto Sans JP', sans-serif !important;
        padding: 50px 20px !important;
        display: flex !important;
        justify-content: center !important;
        box-sizing: border-box !important;
        margin: 0 !important;
        border: none !important;
        width: 100% !important;
        clear: both !important; /* 清除浮动影响 */
    }
    
    .sl-eterlens-text-content-1 {
        max-width: 600px !important;
        width: 100% !important;
        text-align: center !important;
        margin: 0 auto !important;
        padding: 0 !important;
    }
    
    .sl-eterlens-text-content-1 h3 {
        color: #a0a0a0 !important;
        font-size: 18px !important;
        font-weight: 700 !important;
        margin: 0 0 15px 0 !important;
        letter-spacing: 0.1em !important;
        line-height: 1.5 !important;
        padding: 0 !important;
    }
    
    .sl-eterlens-text-content-1 h2 {
        color: #333 !important;
        font-size: 28px !important;
        font-weight: 500 !important;
        margin: 0 0 20px 0 !important;
        line-height: 1.6 !important;
        padding: 0 !important;
    }
    
    .sl-eterlens-text-content-1 p {
        color: #444 !important;
        font-size: 19px !important;
        line-height: 2.0 !important;
        text-align: left !important;
        margin: 0 !important;
        padding: 0 !important;
    }
     /* Shopline专用样式隔离 - 避免与平台样式冲突 */

       .designer-comment {
    padding:20px 10px;
    border-radius:6px;
    background:#f5f5f5;
    margin:10px 0;
  }
  .designer-comment .body-title {
    font-size:18px;
    margin-bottom:10px;
    color:#000000;
    font-weight:600;
     text-align:center !important;
  }
  .designer-comment .body-title p{
    text-align:center !important;
  }
  .designer-comment p{
   text-align:left !important;
  }
  .designer-comment .body-subtitle {
    font-size:14px;
    color:#000000;
  }
  .designer-comment .body-content {
    padding:20px 15px;
    font-size:14px;
    border-radius:6px;
    background:#fff;
    margin:20px 0;
  }
  .designer-comment .author-info {
    display:flex;
    gap:10px;
    align-items:center;
  }
  .designer-comment .author-info .avatar {
    width: 50px;
    height: 60px;
  }
  .designer-comment .author-info .avatar img {
    display: block;
    width: 100%;
    height: 100%;
    border-radius:5px;
  }
  .designer-comment .author-info .author-text {
    font-size:14px;
    color:#000000;
  }
/* /ETL-MIGRATION: pdp-theme-stage1-css 2026-05-10 */
