/* Mobile v2: đưa ô chọn (chiết suất / mã màu) và nút mua lên màn hình đầu; thanh mua dưới cùng hiện lựa chọn đang chọn. Gỡ file này là về bố cục cũ. */
@media (max-width:767px){
  /* ---------- Tròng kính ---------- */
  html body .single-product-page--lens .lens-summary>*{order:30!important}
  html body .single-product-page--lens .lens-summary>.product-commerce__header{order:1!important}
  html body .single-product-page--lens .lens-summary>.product-commerce__price{order:2!important;margin-bottom:2px}
  html body .single-product-page--lens .lens-summary>.lens-selector:not(.lens-selector--types){order:3!important;margin-top:6px}
  html body .single-product-page--lens .lens-summary>.frame-color-variants{order:4!important;margin:8px 14px 0}
  html body .single-product-page--lens .lens-summary>.lens-power{order:5!important;margin:8px 14px 0}
  html body .single-product-page--lens .lens-summary>.lens-variant-sku{display:none}
  html body .single-product-page--lens .lens-summary>.product-commerce__stock{order:6!important}
  html body .single-product-page--lens .lens-summary>.product-commerce__purchase{order:7!important;margin-top:8px}
  html body .single-product-page--lens .lens-summary>.product-commerce__vouchers{order:8!important;margin-top:10px}
  html body .single-product-page--lens .lens-summary>.product-gift-picker{order:9!important}
  html body .single-product-page--lens .lens-summary>.product-commerce__intro-wrap{order:10!important;margin-top:10px}
  html body .single-product-page--lens .lens-summary>.product-mobile-social{order:11!important}
  html body .single-product-page--lens .lens-summary>.lens-mobile-features{order:12!important}
  html body .single-product-page--lens .lens-summary>.lens-mobile-compare-link{order:13!important}

  /* Bảng giá theo độ: gọn 1 dòng, bấm mới mở */
  .mpv2-ready .lens-power{border-radius:10px}
  .mpv2-ready .lens-power__head{cursor:pointer;padding:9px 12px;border-bottom:0}
  .mpv2-ready .lens-power__head strong{font-size:12.5px;font-weight:700}
  .mpv2-ready .lens-power__head span{font-size:11.5px}
  .mpv2-ready .lens-power:not(.is-open) .lens-power__hint,
  .mpv2-ready .lens-power:not(.is-open) .lens-power__list,
  .mpv2-ready .lens-power:not(.is-open) .lens-power__note{display:none}
  .mpv2-ready .lens-power.is-open .lens-power__head{border-bottom:1px solid #dbe4f3}

  /* Thanh mua dưới cùng của tròng: bật lại, gọn 3 cột */
  html body .single-product-page--lens .lens-mobile-buy{display:grid!important;grid-template-columns:auto minmax(0,1fr) auto!important;gap:8px;min-height:62px}
  html body .single-product-page--lens .lens-mobile-buy>span{font-size:16px;color:#e5002b;white-space:nowrap}
  html body .single-product-page--lens .lens-mobile-buy [data-buy-with-voucher]{display:none}
  html body .single-product-page--lens .lens-mobile-buy [data-add-to-cart]{min-height:44px;padding:8px 16px;font-size:13px}
  html body .single-product-page--lens .lens-mobile-buy.is-near-main-actions{visibility:hidden;pointer-events:none}
  html body.product-purchase-sheet-open .lens-mobile-buy,html body.menu-open .lens-mobile-buy,html body.cart-open .lens-mobile-buy,
  html body:has(.product-confirmation[open]) .lens-mobile-buy,html body:has([data-product-vouchers-dialog][open]) .lens-mobile-buy{display:none!important}

  /* ---------- Gọng kính ---------- */
  html body .single-product-page--frame .frame-product-summary>*{order:30!important}
  html body .single-product-page--frame .frame-product-summary>.product-commerce__header{order:1!important}
  html body .single-product-page--frame .frame-product-summary>.product-commerce__price{order:2!important}
  html body .single-product-page--frame .frame-product-summary>.frame-option{order:3!important}
  html body .single-product-page--frame .frame-product-summary>.frame-option--size-choices{order:4!important}
  html body .single-product-page--frame .frame-product-summary>.contact-rx-note{order:7!important}
  html body .single-product-page--frame .frame-product-summary>.product-commerce__stock{order:5!important}
  html body .single-product-page--frame .frame-product-summary>.product-commerce__purchase{order:6!important}
  html body .single-product-page--frame .frame-product-summary>.frame-mobile-offer{order:7!important;margin-top:10px}
  html body .single-product-page--frame .frame-product-summary>.frame-gift-section{order:8!important}
  html body .single-product-page--frame .frame-product-summary>.product-commerce__vouchers{order:9!important}

  /* Khung giá gọng: hiển thị giống tròng (nhãn Giảm giá sâu, giá gạch cùng dòng, dòng Tiết kiệm) */
  html body .single-product-page--frame .frame-product-summary>.product-commerce__price{margin:1px 14px 6px;padding:9px 10px;border-radius:9px}
  html body .single-product-page--frame .product-commerce__price .product-commerce__deep-discount{display:inline-flex!important;margin:0 0 4px;font-size:10px}
  html body .single-product-page--frame .product-commerce__price .product-commerce__price-line{display:flex!important;align-items:baseline;gap:4px 7px;flex-wrap:wrap}
  html body .single-product-page--frame .product-commerce__price .product-commerce__price-line>*{order:0!important}
  html body .single-product-page--frame .product-commerce__price .product-commerce__price-line del{font-size:11px}
  html body .single-product-page--frame .product-commerce__price .product-commerce__price-line strong{font-size:28px;line-height:1.12}
  html body .single-product-page--frame .product-commerce__price .product-commerce__price-line em{padding:2px 4px;font-size:10px}
  html body .single-product-page--frame .product-commerce__price .product-commerce__price-proof{display:flex!important;margin-top:2px}
  html body .single-product-page--frame .product-commerce__price .product-commerce__price-proof .ddm-product-sold-count{display:none}
  html body .single-product-page--frame .product-commerce__price .product-commerce__price-proof small{margin:0;font-size:10px;order:0!important}

  /* Ảnh nhỏ gọn hơn để nút mua lên màn hình đầu */
  html body .single-product-page--frame .frame-gallery__thumbs{gap:6px;padding-top:4px;padding-bottom:2px}
  html body .single-product-page--frame .frame-gallery__thumbs button{flex:0 0 46px!important;width:46px!important;min-width:46px!important;height:46px!important}
  html body .single-product-page--frame .frame-product-summary>.frame-option{margin-top:4px;margin-bottom:4px}

  html body .single-product-page--frame .frame-product-summary>.product-commerce__stock{margin-top:2px;margin-bottom:2px}
  html body .single-product-page--frame .frame-product-summary>.product-commerce__purchase{display:grid!important;grid-template-columns:96px minmax(0,1fr);gap:6px;align-items:stretch}
  html body .single-product-page--frame .frame-product-summary .frame-product-actions{display:contents!important}
  html body .single-product-page--frame .frame-product-summary .product-commerce__quantity{width:96px;min-width:0;height:46px;margin:0}
  html body .single-product-page--frame .frame-product-summary .frame-product-actions [data-add-to-cart]{grid-column:2;min-height:46px;margin:0}
  html body .single-product-page--frame .frame-product-summary .frame-product-actions>*:not([data-add-to-cart]){grid-column:1/-1;margin:0}

  /* Chip lựa chọn trong thanh mua (tròng + gọng) */
  .mpv2-pick{display:inline-flex;align-items:center;gap:5px;max-width:34vw;min-height:40px;padding:4px 9px;border:1.5px solid #1765e8;border-radius:10px;background:#f2f7ff;color:#0b2a5c;font:inherit;font-size:12px;font-weight:800;line-height:1.1;cursor:pointer;white-space:nowrap;overflow:hidden;text-overflow:ellipsis}
  .mpv2-pick small{display:block;color:#5a6b85;font-size:9.5px;font-weight:600}
  .mpv2-pick i{display:inline-block;flex:none;width:14px;height:14px;border-radius:50%;border:1px solid #c9d4e3}
  .mpv2-pick b{font-style:normal;font-size:11px;color:#1765e8}
  html body .single-product-page--frame .frame-mobile-purchase-bar.has-mpv2-pick{grid-template-columns:auto minmax(0,1fr) auto!important}
  html body .single-product-page--frame .frame-mobile-purchase-bar.has-mpv2-pick [data-buy-with-voucher]{display:none}
  html body .single-product-page--frame .frame-mobile-purchase-bar.has-mpv2-pick [data-add-to-cart]{min-height:44px;padding:8px 16px;font-size:13px}

  html body .lens-mobile-buy.mpv2-cta-visible,html body .frame-mobile-purchase-bar.mpv2-cta-visible{transform:translateY(110%);pointer-events:none}
  html body .lens-mobile-buy,html body .frame-mobile-purchase-bar{transition:transform .2s ease}

  /* Yêu thích + chia sẻ nổi ở góc phải ảnh, xếp dọc, trong suốt */
  html body .lens-gallery__stage,html body .frame-gallery__stage{position:relative}
  html body .mpv2-float-actions{position:absolute!important;z-index:4;top:8px;right:8px;display:flex!important;flex-direction:column;gap:6px;margin:0}
  html body .mpv2-float-actions .favorite-button--detail,html body .mpv2-float-actions [data-product-share]{width:34px!important;height:34px!important;border-radius:50%!important;background:rgba(255,255,255,.55)!important;color:#33527e}
  html body .product-mobile-social.mpv2-empty{display:none!important}

  .mpv2-toast{position:fixed;z-index:200;left:50%;bottom:90px;transform:translateX(-50%);padding:9px 14px;border-radius:999px;background:#0e1b31;color:#fff;font-size:12.5px;font-weight:700;white-space:nowrap}

  /* Nhấp nháy ô chọn khi bấm chip ở thanh dưới */
  .mpv2-flash{animation:mpv2-flash 1.2s ease-out}
  @keyframes mpv2-flash{0%,40%{box-shadow:0 0 0 3px #1765e8;border-radius:10px}100%{box-shadow:0 0 0 0 transparent}}
}
