/* Product page (V2). Builds on home.css tokens, division.css (breadcrumb) and category.css (section head). */
.gp { background: #fff; }

/* hero */
.gp-hero { padding: 40px 0 56px; border-bottom: 1px solid var(--gx-line); }
.gp-hero__grid { display: grid; grid-template-columns: minmax(0, 1fr) minmax(0, 1fr); gap: 56px; align-items: start; }

.gp-gallery__stage { position: relative; display: flex; align-items: center; justify-content: center; width: 100%; aspect-ratio: 1; padding: 40px; border: 1px solid var(--gx-line); border-radius: 18px; background: #fff; overflow: hidden; cursor: zoom-in; }
.gp-gallery__stage img { width: 100%; height: 100%; object-fit: contain; transition: transform .2s ease; }
.gp-gallery__stage.is-zoomed img { transform: scale(1.9); }
.gp-gallery__hint { position: absolute; left: 16px; bottom: 16px; display: inline-flex; align-items: center; gap: 6px; padding: 6px 12px; border: 1px solid var(--gx-line); border-radius: 999px; background: rgba(255,255,255,.92); font-size: 12.5px; color: var(--gx-ink-2); pointer-events: none; }
.gp-gallery__stage.is-zoomed .gp-gallery__hint { opacity: 0; }
.gp-gallery__thumbs { display: flex; flex-wrap: wrap; gap: 10px; margin-top: 14px; }
.gp-gallery__thumbs button { width: 80px; height: 80px; padding: 6px; border: 1px solid var(--gx-line); border-radius: 10px; background: #fff; }
.gp-gallery__thumbs button.is-active { border: 2px solid var(--gx-blue); }
.gp-gallery__thumbs img { width: 100%; height: 100%; object-fit: contain; }

.gp-info h1 { font-size: 40px; line-height: 1.1; font-weight: 800; margin: 2px 0 14px; }
.gp-chips { display: flex; flex-wrap: wrap; gap: 8px; margin-bottom: 16px; }
.gp-chip { display: inline-flex; align-items: center; gap: 6px; height: 32px; padding: 0 13px; border: 1px solid var(--gx-line-2); border-radius: 999px; font-size: 13.5px; color: var(--gx-ink-2) !important; }
a.gp-chip:hover { border-color: var(--gx-blue); color: var(--gx-blue) !important; }
.gp-chip--model { background: var(--gx-blue-900); border-color: var(--gx-blue-900); color: #fff !important; }
.gp-chip--model strong { font-weight: 700; letter-spacing: .02em; }
.gp-lead { font-size: 16.5px; line-height: 1.65; color: var(--gx-ink-2); margin-bottom: 20px !important; }

.gp-facts { display: grid; grid-template-columns: 1fr 1fr; margin: 0 0 20px; border: 1px solid var(--gx-line); border-radius: 12px; overflow: hidden; }
.gp-facts div { padding: 12px 14px; border-bottom: 1px solid var(--gx-line); }
.gp-facts div:nth-child(odd) { border-right: 1px solid var(--gx-line); }
.gp-facts div:nth-last-child(-n+2):nth-child(odd), .gp-facts div:last-child { border-bottom: 0; }
.gp-facts div:last-child:nth-child(odd) { grid-column: span 2; border-right: 0; }
.gp-facts dt { font-size: 11px; font-weight: 600; letter-spacing: .08em; text-transform: uppercase; color: var(--gx-muted); }
.gp-facts dd { margin: 3px 0 0; font-size: 14.5px; font-weight: 600; color: var(--gx-ink); }

/* buy box reuses the .gx-product cart wiring from home.js */
.gx-product.gp-buy { display: block; padding: 18px; border: 1px solid var(--gx-line); border-radius: 14px; background: var(--gx-surface); box-shadow: none; overflow: visible; }
.gx-product.gp-buy:hover { box-shadow: none; border-color: var(--gx-line); }
.gp-buy__row { display: flex; gap: 10px; }
.gp-buy__row .gx-add { flex: 1; height: 48px; }
.gp-buy .gx-qty { height: 48px; }
.gp-buy .gx-qty__btn { width: 36px; }
.gp-buy__ask { width: 100%; margin-top: 10px; height: 46px; }
.gp-buy__links { display: flex; justify-content: space-between; gap: 12px; margin-top: 14px; font-size: 13.5px; font-weight: 600; }
.gp-buy__links a { color: var(--gx-blue) !important; display: inline-flex; align-items: center; gap: 6px; }
.gp-buy__links a:hover { text-decoration: underline; }

.gp-trust { list-style: none; display: grid; grid-template-columns: 1fr 1fr; gap: 14px 20px; margin: 22px 0 0; padding: 0; }
.gp-trust li { display: flex; gap: 10px; font-size: 13px; color: var(--gx-muted); }
.gp-trust i { color: var(--gx-blue); font-size: 18px; line-height: 1.2; }
.gp-trust strong { display: block; color: var(--gx-ink); font-weight: 600; }

/* details */
.gp-details { padding: 56px 0 88px; }
.gp-details__grid { display: grid; grid-template-columns: minmax(0, 1fr) 400px; gap: 56px; align-items: start; }
.gp-block + .gp-block { margin-top: 40px; }
.gp-block h2 { font-size: 24px; margin-bottom: 16px; }
.gp-spec { width: 100%; border-collapse: collapse; font-size: 14.5px; }
.gp-spec th, .gp-spec td { padding: 13px 16px; border-bottom: 1px solid var(--gx-line); vertical-align: top; text-align: left; }
.gp-spec th { width: 34%; background: var(--gx-surface); font-weight: 600; color: var(--gx-ink); }
.gp-spec td { color: var(--gx-ink-2); }
.gp-rich { font-size: 15px; line-height: 1.75; color: var(--gx-ink-2); }
.gp-rich p { margin-bottom: 14px !important; }
.gp-rich ul, .gp-rich ol { padding-left: 20px; margin-bottom: 14px; }
.gp-rich ul { list-style: disc; }
.gp-rich ol { list-style: decimal; }
.gp-rich li { display: list-item; list-style: inherit; margin-bottom: 4px; }
.gp-rich h2, .gp-rich h3, .gp-rich h4 { font-size: 17px; margin: 18px 0 8px; }
.gp-rich img { max-width: 100%; height: auto; }
.gp-rich--table { overflow-x: auto; }
.gp-rich table { width: 100%; border-collapse: collapse; font-size: 13.5px; }
.gp-rich td, .gp-rich th { padding: 8px 10px; border: 1px solid var(--gx-line); }
.gp-rich tr:first-child td { background: var(--gx-surface); font-weight: 600; color: var(--gx-ink); }
.gp-video { position: relative; aspect-ratio: 16 / 9; border-radius: 12px; overflow: hidden; background: var(--gx-surface); }
.gp-video iframe { position: absolute; inset: 0; width: 100%; height: 100%; border: 0; }

.gp-ask { position: sticky; top: 104px; padding: 24px; border: 1px solid var(--gx-line); border-radius: 16px; background: #fff; box-shadow: 0 14px 38px rgba(13,34,48,.08); }
.gp-ask h2 { font-size: 20px; }
.gp-ask__intro { font-size: 14px; color: var(--gx-muted); margin: 6px 0 16px !important; }
.gp-ask__product { display: flex; align-items: center; gap: 12px; padding: 10px 12px; margin-bottom: 16px; border: 1px solid var(--gx-sky); border-radius: 10px; background: var(--gx-sky-50); }
.gp-ask__product img { width: 44px; height: 44px; object-fit: contain; background: #fff; border-radius: 6px; flex: none; }
.gp-ask__product strong { display: block; font-size: 13.5px; line-height: 1.35; color: var(--gx-ink); }
.gp-ask__product small { font-size: 12px; color: var(--gx-muted); }
.gp-form { padding: 0; border: 0; box-shadow: none; background: none; }
.gp-form .gx-form__row { gap: 12px; }
.gp-form .g-recaptcha { margin: 4px 0 14px; }
.gp-form__submit { width: 100%; }
.gp-hp { position: absolute; left: -9999px; width: 1px; height: 1px; overflow: hidden; }

/* related */
.gp-related { background: var(--gx-surface); border-top: 1px solid var(--gx-line); }
.gp-related__grid { display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); gap: 20px; }

/* lightbox */
.gp-lightbox { width: min(92vw, 960px); max-height: 92vh; padding: 24px; border: 0; border-radius: 16px; }
.gp-lightbox::backdrop { background: rgba(6, 50, 74, .72); }
.gp-lightbox img { display: block; width: 100%; max-height: calc(92vh - 48px); object-fit: contain; }
.gp-lightbox__close { position: absolute; top: 10px; right: 10px; width: 38px; height: 38px; border: 0; border-radius: 50%; background: var(--gx-surface); font-size: 20px; }

@media (max-width: 1180px) {
    .gp-details__grid { grid-template-columns: minmax(0, 1fr) 340px; gap: 36px; }
    .gp-related__grid { grid-template-columns: repeat(2, minmax(0, 1fr)); }
}
@media (max-width: 991px) {
    .gp-hero__grid, .gp-details__grid { grid-template-columns: 1fr; gap: 32px; }
    .gp-ask { position: static; }
    .gp-info h1 { font-size: 32px; }
}
@media (max-width: 575px) {
    .gp-hero { padding: 24px 0 40px; }
    .gp-gallery__stage { padding: 20px; }
    .gp-facts, .gp-trust { grid-template-columns: 1fr; }
    .gp-facts div:nth-child(odd) { border-right: 0; }
    .gp-facts div { border-bottom: 1px solid var(--gx-line) !important; }
    .gp-facts div:last-child { border-bottom: 0 !important; }
    .gp-buy__links { flex-direction: column; }
    .gp-related__grid { grid-template-columns: 1fr; }
    .gp-spec th { width: 42%; }
}

/* in-page anchors land below the sticky header */
.gp-ask, .gp-block { scroll-margin-top: 110px; }

.gp-buy__ai { width: 100%; margin-top: 10px; height: 46px; border-color: var(--gx-sky); background: var(--gx-sky-50); color: var(--gx-blue-900) !important; }
.gp-buy__ai i { color: var(--gx-orange); }
