:root {
  --detail-ink: #252525;
  --detail-muted: #77736d;
  --detail-line: #dedbd5;
  --detail-paper: #faf9f6;
  --detail-stone: #eeeae3;
  --detail-accent: #9b7b5b;
}

html { overflow-x: clip; scroll-behavior: smooth; }
.detail-body { min-width: 320px; overflow-x: hidden; background: #fff; color: var(--detail-ink); }
.detail-body button, .detail-body input, .detail-body textarea { font: inherit; }
.detail-body .header { position: sticky; top: 0; height: 70px; margin: 0; background: rgba(255,255,255,.97); }
.detail-body .brand-logo { left: 60px; top: 50%; width: 180px; }
.detail-body .footer { margin-top: 0; }
.detail-container { width: min(1640px, 90%); margin: 0 auto; }

.detail-breadcrumb { min-height: 58px; display: flex; align-items: center; border-top: 1px solid #eee; border-bottom: 1px solid #e8e5df; background: #f7f5f1; }
.detail-breadcrumb .detail-container { display: flex; align-items: center; gap: 14px; color: #888; font-family: Georgia, "Times New Roman", serif; font-size: 14px; }
.detail-breadcrumb a { color: #555; }
.detail-breadcrumb strong { max-width: 60vw; overflow: hidden; color: #8d8982; font-weight: 400; text-overflow: ellipsis; white-space: nowrap; }

.mars-product-main { padding: 70px 0 100px; background: #fff; }
.product-main-grid { display: grid; grid-template-columns: minmax(0, 1.08fr) minmax(420px, .92fr); gap: clamp(55px, 6vw, 110px); align-items: start; }
.product-gallery { position: sticky; top: 105px; min-width: 0; }
.product-main-image-wrap { position: relative; aspect-ratio: 1 / 1; overflow: hidden; background: var(--detail-stone); }
.product-main-image-wrap > img { width: 100%; height: 100%; object-fit: contain; transition: opacity .2s ease; }
.gallery-expand { position: absolute; top: 18px; right: 18px; display: grid; place-items: center; width: 45px; height: 45px; border: 0; border-radius: 50%; background: rgba(255,255,255,.94); box-shadow: 0 4px 20px rgba(0,0,0,.12); color: #333; font-size: 23px; font-weight: 200; }
.product-thumbnails { display: grid; grid-template-columns: repeat(5, minmax(0, 1fr)); gap: 10px; margin-top: 12px; }
.product-thumb { aspect-ratio: 1; padding: 0; overflow: hidden; border: 2px solid transparent; background: #eee; }
.product-thumb.active { border-color: #222; }
.product-thumb img { width: 100%; height: 100%; object-fit: cover; }

.product-summary { padding-top: 18px; }
.summary-category { margin-bottom: 23px; color: var(--detail-accent); font-size: 11px; letter-spacing: 3.5px; text-transform: uppercase; }
.product-summary h1 { max-width: 680px; font-family: Georgia, "Times New Roman", serif; font-size: clamp(38px, 4vw, 62px); font-weight: 400; line-height: 1.12; letter-spacing: .2px; }
.summary-divider { width: 54px; height: 1px; margin: 38px 0; background: #999; }
.mars-description { color: #4f4e4a; font-family: Georgia, "Times New Roman", serif; font-size: 16px; line-height: 1.85; }
.mars-description p { margin: 0 0 18px; }
.mars-description p:empty { display: none; }
.mars-description ul, .mars-description ol { margin: 22px 0 22px 22px; }
.mars-description li { margin-bottom: 10px; padding-left: 5px; }
.mars-description img { max-width: 100%; height: auto; margin: 22px 0; }

.detail-specifications { margin-top: 38px; padding-top: 30px; border-top: 1px solid var(--detail-line); }
.detail-specifications h2 { margin: 0 0 18px; font-family: Georgia, "Times New Roman", serif; font-size: 24px; font-weight: 400; }
.detail-specifications dl { display: grid; grid-template-columns: minmax(115px, .7fr) 1.3fr; margin: 0; border-top: 1px solid var(--detail-line); }
.detail-specifications dt, .detail-specifications dd { margin: 0; padding: 12px 0; border-bottom: 1px solid var(--detail-line); font-size: 13px; line-height: 1.55; }
.detail-specifications dt { padding-right: 18px; color: #777; font-family: Arial, sans-serif; letter-spacing: .7px; text-transform: uppercase; }
.detail-specifications dd { color: #222; font-family: Georgia, "Times New Roman", serif; }

.material-options { margin-top: 48px; padding-top: 32px; border-top: 1px solid var(--detail-line); }
.material-options h2 { margin: 0 0 22px; text-align: left; font-family: Georgia, "Times New Roman", serif; font-size: 18px; font-weight: 400; letter-spacing: 1px; }
.material-list { display: flex; flex-wrap: wrap; gap: 18px 13px; }
.material-item { width: 84px; color: #666; font-size: 10px; line-height: 1.35; text-align: center; }
.material-item img { width: 66px; height: 66px; margin: 0 auto 8px; border-radius: 50%; object-fit: cover; box-shadow: inset 0 0 0 1px rgba(0,0,0,.08); }
.summary-enquire { display: inline-flex; align-items: center; justify-content: center; min-width: 210px; height: 52px; margin-top: 48px; background: #111; color: #fff; font-size: 11px; letter-spacing: 3px; }

.detail-tags { padding: 28px 0; border-top: 1px solid var(--detail-line); border-bottom: 1px solid var(--detail-line); background: #f7f5f0; }
.detail-tags .detail-container { display: flex; align-items: flex-start; gap: 25px; }
.detail-tags strong { flex: 0 0 auto; padding-top: 4px; font-size: 10px; letter-spacing: 2.5px; }
.detail-tags #detailTags { display: flex; flex-wrap: wrap; gap: 8px 10px; }
.detail-tag { padding: 6px 10px; border: 1px solid #d6d1c9; color: #777; font-family: Georgia, "Times New Roman", serif; font-size: 12px; }
.detail-tag:hover { border-color: #222; background: #222; color: #fff; }

.detail-inquiry { padding: 100px 0; background: var(--detail-paper); }
.detail-inquiry .detail-container { max-width: 1050px; }
.section-kicker { margin-bottom: 18px; color: var(--detail-accent); font-size: 10px; letter-spacing: 4px; text-align: center; }
.detail-inquiry h2, .related-products > .detail-container > h2 { margin: 0 0 20px; font-family: Georgia, "Times New Roman", serif; font-size: clamp(34px, 3.4vw, 50px); font-weight: 400; text-align: center; }
.detail-inquiry > .detail-container > p:not(.section-kicker) { max-width: 680px; margin: 0 auto 45px; color: #777; font-family: Georgia, "Times New Roman", serif; line-height: 1.8; text-align: center; }
.detail-inquiry form { padding: 44px; background: #fff; box-shadow: 0 12px 45px rgba(31,27,21,.06); }
.inquiry-subject { margin-bottom: 30px; padding-bottom: 20px; border-bottom: 1px solid var(--detail-line); color: #777; font-size: 14px; }
.inquiry-subject strong { color: #222; font-weight: 400; }
.inquiry-fields { display: grid; grid-template-columns: 1fr 1fr; gap: 24px; }
.detail-inquiry label { display: block; margin-bottom: 24px; }
.detail-inquiry label > span { display: block; margin-bottom: 9px; color: #777; font-size: 11px; letter-spacing: 1.5px; text-transform: uppercase; }
.detail-inquiry input, .detail-inquiry textarea { width: 100%; border: 1px solid #ddd8d0; outline: 0; background: #fbfaf8; color: #222; }
.detail-inquiry input { height: 48px; padding: 0 15px; }
.detail-upload-field { padding: 15px; border: 1px solid #ddd8d0; background: #fbfaf8; }
.detail-upload-field input[type="file"] { width: 100%; height: auto; padding: 0; border: 0; background: transparent; color: #666; font-family: Arial, sans-serif; font-size: 13px; }
.detail-upload-field input[type="file"]::file-selector-button { margin-right: 12px; padding: 9px 14px; border: 1px solid #cec8be; background: #fff; color: #222; cursor: pointer; }
.detail-upload-field small { display: block; margin-top: 9px; color: #88827a; font-family: Arial, sans-serif; font-size: 11px; letter-spacing: .25px; }
.detail-inquiry textarea { padding: 15px; resize: vertical; }
.detail-inquiry input:focus, .detail-inquiry textarea:focus { border-color: #888; }
.detail-inquiry button { display: inline-flex; align-items: center; justify-content: center; gap: 7px; min-width: 98px; height: 44px; padding: 0 17px; border: 0; border-radius: 2px; background: #111; color: #fff; font-family: Georgia, "Times New Roman", serif; font-size: 16px; letter-spacing: 0; }
.detail-inquiry button .send-plane { width: 16px; height: 16px; fill: none; stroke: currentColor; stroke-width: 1.7; stroke-linecap: round; stroke-linejoin: round; }
.detail-inquiry button:disabled { cursor: wait; opacity: .65; }

.related-products { padding: 110px 0 120px; background: #fff; }
.related-grid { display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); gap: 24px; margin-top: 60px; }
.related-card { display: block; min-width: 0; background: #f7f5f1; overflow: hidden; }
.related-card img { width: 100%; aspect-ratio: 1; object-fit: cover; transition: transform .5s ease; }
.related-card:hover img { transform: scale(1.04); }
.related-card span { display: block; min-height: 86px; padding: 22px 18px; font-family: Georgia, "Times New Roman", serif; font-size: 16px; line-height: 1.35; text-align: center; }

.image-lightbox { position: fixed; inset: 0; z-index: 30000; display: grid; place-items: center; padding: 40px; background: rgba(0,0,0,.86); opacity: 0; visibility: hidden; transition: .25s ease; }
.image-lightbox.open { opacity: 1; visibility: visible; }
.image-lightbox img { max-width: 92vw; max-height: 90vh; object-fit: contain; }
.image-lightbox button { position: absolute; top: 20px; right: 28px; width: 45px; height: 45px; border: 1px solid rgba(255,255,255,.6); border-radius: 50%; background: transparent; color: #fff; font-size: 30px; }
.detail-notice { position: fixed; left: 50%; bottom: 25px; z-index: 40000; max-width: calc(100vw - 40px); padding: 13px 20px; background: #111; color: #fff; font-size: 12px; letter-spacing: 1px; opacity: 0; visibility: hidden; transform: translate(-50%, 15px); transition: .25s ease; }
.detail-notice.show { opacity: 1; visibility: visible; transform: translate(-50%, 0); }
.detail-top { position: fixed; right: 24px; bottom: 24px; z-index: 2000; width: 46px; height: 46px; border: 1px solid #ddd; border-radius: 50%; background: rgba(255,255,255,.95); color: #222; opacity: 0; visibility: hidden; transform: translateY(8px); transition: .25s ease; }
.detail-top.visible { opacity: 1; visibility: visible; transform: translateY(0); }

@media (max-width: 1180px) {
  .detail-body .header-actions { display: none; }
  .detail-body .stone-nav { right: 30px; left: auto; transform: none; gap: 35px; }
  .product-main-grid { grid-template-columns: minmax(0, 1fr) minmax(360px, .9fr); gap: 50px; }
}

@media (max-width: 900px) {
  .detail-body .header { height: 64px; padding: 0 20px; }
  .detail-body .brand-logo { left: 20px; width: 118px; }
  .detail-body .stone-nav { position: static; display: flex; margin-left: auto; gap: 20px; }
  .detail-body .stone-nav > a { display: none !important; }
  .detail-body .stone-products > .stone-link { display: flex !important; }
  .mars-product-main { padding-top: 45px; }
  .product-main-grid { grid-template-columns: 1fr; }
  .product-gallery { position: static; }
  .product-summary { padding-top: 5px; }
  .related-grid { grid-template-columns: repeat(2, minmax(0, 1fr)); }
}

@media (max-width: 600px) {
  .detail-container { width: calc(100% - 32px); }
  .detail-body .stone-products > .stone-link { display: flex !important; font-size: 12px; }
  .detail-breadcrumb { min-height: 50px; }
  .detail-breadcrumb .detail-container { gap: 9px; font-size: 12px; }
  .detail-breadcrumb strong { max-width: 42vw; }
  .mars-product-main { padding: 25px 0 70px; }
  .product-main-grid { gap: 38px; }
  .product-thumbnails { gap: 5px; }
  .gallery-expand { top: 10px; right: 10px; }
  .product-summary h1 { font-size: 36px; }
  .mars-description { font-size: 15px; }
  .detail-tags .detail-container { flex-direction: column; gap: 12px; }
  .detail-inquiry, .related-products { padding: 75px 0; }
  .detail-inquiry form { padding: 28px 20px; }
  .inquiry-fields { grid-template-columns: 1fr; gap: 0; }
  .related-grid { gap: 12px; }
  .related-card span { min-height: 78px; padding: 16px 10px; font-size: 14px; }
  .image-lightbox { padding: 12px; }
  .detail-top { right: 14px; bottom: 14px; }
}
