/* Product/store surfaces only. Existing header, catalog, account and checkout stay unchanged. */
#product-view .pd-experience, #product-view .pd-store { --pd-ink: #152d26; --pd-muted: #60716b; --pd-line: #dde6e1; --pd-accent: #006d4d; color: var(--pd-ink); }
.pd-toolbar { display: flex; align-items: center; justify-content: space-between; gap: 16px; margin: 0 0 18px; }
.pd-toolbar nav { display: flex; align-items: center; gap: 14px; color: #60716b; font-size: .875rem; }
.pd-toolbar a, .pd-byline a { color: #007653; text-underline-offset: 3px; }
.pd-share, .pd-icon-button { display: inline-flex; align-items: center; justify-content: center; gap: 9px; padding: 10px 15px; min-height: 42px; border: 1px solid #ccdcd4; border-radius: 10px; color: #16362b; background: #fff; font-size: .875rem; font-weight: 550; }
.pd-main { display: grid; grid-template-columns: minmax(0, 1.15fr) minmax(360px, 1fr); border: 1px solid var(--pd-line); border-radius: 14px; background: #fff; overflow: hidden; box-shadow: 0 5px 20px #13372904; }
.pd-gallery { min-width: 0; padding: 24px; display: grid; align-items: center; }
.pd-gallery.has-thumbs { grid-template-columns: 62px minmax(0, 1fr); gap: 12px; }
.pd-media { min-width: 0; text-align: center; }
.pd-photo-button { display: block; width: 100%; padding: 0; border: 0; background: #fff; border-radius: 8px; cursor: zoom-in; }
.pd-photo { display: block; width: 100%; height: clamp(340px, 36vw, 500px); object-fit: contain; background: #fff; border-radius: 8px; }
.pd-photo.product-image-placeholder { display: grid; place-items: center; background: #f4f7f5; font-size: 3rem; color: #007a50; }
.pd-enlarge { display: inline-flex; align-items: center; gap: 8px; min-height: 44px; padding: 8px 12px; margin-top: 10px; border: 0; border-radius: 8px; background: #fff; color: #526a5f; font-size: .8125rem; }
.pd-no-photo { font-size: .875rem; color: #60716b; }
.pd-thumbs { display: flex; flex-direction: column; align-self: start; gap: 10px; max-height: 500px; overflow: auto; padding: 3px; }
.pd-thumb { flex: 0 0 auto; width: 56px; height: 64px; border: 1px solid var(--pd-line); border-radius: 8px; padding: 3px; background: #fff; }
.pd-thumb.is-active { border-color: #00865b; box-shadow: 0 0 0 1px #00865b; }
.pd-thumb-image { width: 100%; height: 100%; object-fit: contain; }
.pd-purchase { min-width: 0; padding: 28px 30px; border-left: 1px solid var(--pd-line); }
body.marketplace-screen #product-view .pd-purchase h1 { margin: 0 0 12px; font-size: clamp(1.5rem, 2.1vw, 1.875rem); font-weight: 700; letter-spacing: -.035em; line-height: 1.22; overflow-wrap: anywhere; }
.pd-byline { margin: 0 0 12px; color: #60716b; font-size: .875rem; line-height: 1.5; overflow-wrap: anywhere; }
.pd-byline a { font-weight: 600; }
.pd-lead { margin: 0 0 18px; color: #60716b; font-size: .875rem; line-height: 1.6; overflow-wrap: anywhere; }
.pd-price { color: #152d26; font-size: 2.375rem; line-height: 1.2; font-weight: 700; letter-spacing: -.04em; font-variant-numeric: tabular-nums; overflow-wrap: anywhere; }
.pd-availability { margin: 8px 0 8px; font-size: .875rem; color: #69766f; font-weight: 600; }
.pd-availability.is-ready { color: #008058; }
.pd-quantity { display: flex; gap: 22px; align-items: center; margin: 20px 0; font-size: .875rem; font-weight: 600; }
.pd-quantity > div { display: flex; border: 1px solid #d4e0d9; border-radius: 8px; overflow: hidden; }
.pd-quantity button { width: 42px; min-height: 42px; border: 0; background: #fff; color: #163c2e; font-size: 1.15rem; }
.pd-quantity output { display: grid; min-width: 42px; place-items: center; border-inline: 1px solid #e0e7e3; }
.pd-delivery { display: flex; align-items: start; gap: 12px; margin: 0 0 22px; font-size: .875rem; }
.pd-delivery > svg { width: 25px; height: 25px; flex: 0 0 auto; }
.pd-delivery p { margin: 4px 0 0; color: #60716b; font-size: .8125rem; line-height: 1.5; }
.pd-actions { display: grid; gap: 10px; }
body.marketplace-screen .pd-actions .button { width: 100%; min-height: 48px; display: inline-flex; gap: 10px; align-items: center; justify-content: center; padding: 12px 14px; font-size: .9375rem; border-radius: 9px; }
body.marketplace-screen .pd-actions .pd-buy { color: #fff; border-color: #006d4d; background: #006d4d; }
body.marketplace-screen .pd-actions .pd-add { color: #006348; border-color: #daf5e9; background: #daf5e9; }
.pd-payment-note { display: flex; align-items: start; gap: 8px; margin: 16px 0 0; color: #697a71; font-size: .75rem; line-height: 1.5; }
.pd-payment-note svg { flex: 0 0 17px; height: 17px; margin-top: 1px; }
.pd-details { display: grid; grid-template-columns: minmax(0, 1.45fr) minmax(300px, 1fr); gap: 18px; margin: 20px 0; align-items: start; }
.pd-description, .pd-seller { padding: 26px 28px; border: 1px solid var(--pd-line); border-radius: 12px; background: #fff; min-width: 0; }
body.marketplace-screen #product-view .pd-details h2 { margin: 0 0 14px; font-size: 1.375rem; line-height: 1.3; }
.pd-description > p { margin: 0 0 24px; color: #5c6c64; font-size: .9375rem; line-height: 1.75; white-space: pre-line; overflow-wrap: anywhere; }
.pd-description h3 { font-size: 1.05rem; margin: 0 0 12px; }
.pd-description dl { margin: 0; font-size: .875rem; }
.pd-description dl > div { display: grid; grid-template-columns: minmax(120px, .8fr) minmax(0, 1.2fr); gap: 16px; padding: 10px 0; border-bottom: 1px solid #e4ebe6; }
.pd-description dt { color: #627269; }
.pd-description dd { margin: 0; overflow-wrap: anywhere; }
.pd-seller-identity { display: flex; align-items: center; gap: 16px; padding: 4px 0 22px; }
.pd-seller h3 { font-size: 1rem; line-height: 1.45; letter-spacing: -.01em; overflow-wrap: anywhere; }
.pd-seller p { margin: 4px 0 0; color: #65756d; font-size: .8125rem; line-height: 1.5; }
.pd-store-icon { flex: 0 0 62px; width: 62px; height: 62px; display: grid; place-items: center; border-radius: 50%; background: #dff7ec; color: #007151; }
.pd-store-icon svg { width: 30px; height: 30px; }
.pd-store-link { min-height: 48px; display: flex; align-items: center; gap: 20px; padding-top: 18px; border-top: 1px solid #e0e9e3; text-decoration: none; color: #007451; font-size: .875rem; font-weight: 650; }
.pd-store-grid { display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); gap: 20px; }
.pd-store-heading { display: flex; gap: 20px; align-items: center; margin: 8px 0 28px; }
body.marketplace-screen #product-view .pd-store-heading h1 { font-size: 1.875rem; line-height: 1.2; margin: 0 0 10px; overflow-wrap: anywhere; }
.pd-store-heading p { margin: 0; color: #60716b; font-size: .875rem; }
.pd-dialog { color-scheme: light; color: #152d26; padding: 24px; width: min(510px, calc(100vw - 32px)); max-height: calc(100dvh - 32px); overflow: auto; border: 1px solid #d8e4dd; border-radius: 16px; background: #fff; box-shadow: 0 20px 80px #001e2050; }
.pd-dialog::backdrop { background: #082c25a6; backdrop-filter: blur(3px); }
.pd-dialog [hidden] { display: none !important; }
.pd-gallery [hidden] { display: none !important; }
.pd-image-failed { display: grid; place-items: center; color: #63796c; background: #f3f7f4; font-size: .875rem; }
.pd-photo-button.pd-image-failed { min-height: 320px; }
.pd-dialog > header { display: flex; justify-content: space-between; align-items: center; gap: 16px; margin-bottom: 18px; }
.pd-dialog h2 { margin: 0; font-size: 1.3rem; line-height: 1.3; letter-spacing: -.025em; }
.pd-dialog .pd-icon-button { flex: 0 0 42px; width: 42px; padding: 9px; }
.pd-share-name { margin: 0 0 20px; color: #62766a; font-size: .875rem; line-height: 1.5; overflow-wrap: anywhere; }
.pd-dialog label { display: block; margin: 0 0 8px; color: #345344; font-size: .875rem; font-weight: 600; }
.pd-dialog input { width: 100%; padding: 12px; min-height: 46px; border: 1px solid #ccdad2; border-radius: 8px; color: #345344; background: #f6faf7; font-size: .875rem; }
.pd-share-actions { display: flex; gap: 10px; flex-wrap: wrap; margin-top: 16px; }
.pd-dialog .button { display: inline-flex; align-items: center; justify-content: center; gap: 9px; min-height: 46px; padding: 12px 18px; border-radius: 8px; font-size: .875rem; }
.pd-dialog .primary { color: #fff; background: #006d4d; border-color: #006d4d; }
.pd-dialog .outline { color: #006d4d; background: #fff; border-color: #93c4ab; }
.pd-share-status { min-height: 40px; margin: 14px 0 0; color: #326447; font-size: .8125rem; line-height: 1.5; }
.pd-photo-dialog { width: min(960px, calc(100vw - 32px)); }
.pd-lightbox-media { display: grid; place-items: center; height: min(65dvh, 680px); background: #fff; }
.pd-lightbox-media img { display: block; width: 100%; height: 100%; object-fit: contain; min-height: 0; }
.pd-lightbox-controls { display: flex; justify-content: center; align-items: center; gap: 24px; margin-top: 10px; }
.pd-lightbox-controls p { margin: 0; font-size: .875rem; color: #60716b; }
.pd-experience :is(button, a):focus-visible, .pd-store a:focus-visible, .pd-dialog :is(button, input):focus-visible { outline: 3px solid #009b69; outline-offset: 3px; }
@media (hover: hover) {
  .pd-experience button:not(:disabled), .pd-dialog button { transition: background-color .18s, box-shadow .18s, transform .18s; }
  .pd-photo-button:not(:disabled):hover { transform: scale(1.015); }
  .pd-share:hover, .pd-enlarge:hover, .pd-quantity button:not(:disabled):hover, .pd-icon-button:hover { background: #edf8f1; }
  body.marketplace-screen .pd-actions .pd-buy:hover { background: #00583e; box-shadow: 0 4px 12px #00734b22; }
  .pd-store-link:hover { text-decoration: underline; text-underline-offset: 4px; }
}
@media (prefers-reduced-motion: no-preference) {
  .pd-main, .pd-details, .pd-store { animation: pd-reveal .24s ease-out both; }
  .pd-details { animation-delay: .06s; }
  .pd-dialog[open] { animation: pd-reveal .18s ease-out both; }
}
@keyframes pd-reveal { from { opacity: 0; transform: translateY(6px); } to { opacity: 1; transform: none; } }
@media (max-width: 900px) {
  .pd-main { grid-template-columns: minmax(0, 1fr) minmax(320px, 1fr); }
  .pd-gallery { padding: 16px; }
  .pd-purchase { padding: 24px; }
  .pd-gallery.has-thumbs { grid-template-columns: minmax(0, 1fr); }
  .pd-thumbs { order: 2; flex-direction: row; max-width: 100%; }
  .pd-details { grid-template-columns: minmax(0, 1.2fr) minmax(270px, 1fr); }
  .pd-description, .pd-seller { padding: 22px; }
  .pd-store-grid { grid-template-columns: repeat(3, minmax(0, 1fr)); }
}
@media (max-width: 680px) {
  .pd-main, .pd-details { grid-template-columns: minmax(0, 1fr); }
  .pd-toolbar { gap: 8px; margin-bottom: 14px; }
  .pd-toolbar nav { gap: 10px; font-size: .8125rem; }
  .pd-share { font-size: .8125rem; padding: 9px 11px; }
  .pd-gallery { padding: 16px 20px 8px; }
  .pd-photo { height: clamp(250px, 75vw, 390px); }
  .pd-purchase { border-left: 0; border-top: 1px solid var(--pd-line); padding: 24px 20px; }
  .pd-price { font-size: 2.15rem; }
  .pd-description, .pd-seller { padding: 22px 20px; }
  .pd-description dl > div { grid-template-columns: minmax(0, 1fr) minmax(0, 1.1fr); gap: 14px; }
  .pd-store-grid { grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 12px; }
  .pd-store-heading { align-items: start; gap: 14px; }
  .pd-store-heading .pd-store-icon { flex-basis: 48px; width: 48px; height: 48px; }
  body.marketplace-screen #product-view .pd-store-heading h1 { font-size: 1.4rem; }
  .pd-dialog { padding: 20px; }
  .pd-share-actions { flex-direction: column; }
}
@media (prefers-reduced-motion: reduce) {
  .pd-experience *, .pd-store *, .pd-dialog, .pd-dialog * { animation: none !important; transition: none !important; scroll-behavior: auto !important; }
}
