/* =========================================================
   SLG Masterworks - Product Detail Page
   Navy-accent gallery experience inspired by Peter Lik,
   built on the existing SLG warm-bone foundation.
   ========================================================= */

/* ---- Product-page accent tokens ---- */
:root {
  --navy:         #0D1B35;      /* deep navy - single brand blue */
  --navy-light:   #0D1B35;
  --navy-muted:   rgba(13, 27, 53, 0.55);
  --navy-subtle:  rgba(13, 27, 53, 0.08);
  --navy-glow:    rgba(13, 27, 53, 0.15);
}

/* ---- Breadcrumb ---- */
.product-breadcrumb {
  max-width: var(--max);
  margin: 0 auto;
  padding: 1.25rem var(--gutter) 0;
  font-family: var(--sans);
  font-size: 0.7rem;
  letter-spacing: 0.2em;
  text-transform: uppercase;
  color: var(--ink-muted);
  display: flex;
  align-items: center;
  gap: 0.5rem;
}
.product-breadcrumb a {
  color: var(--ink-muted);
  transition: color 0.25s var(--ease);
}
.product-breadcrumb a:hover { color: var(--navy); }
.product-breadcrumb .sep {
  color: var(--line);
  font-size: 0.6rem;
}

/* ---- Product Layout ---- */
.product-page {
  max-width: var(--max);
  margin: 0 auto;
  padding: 2rem var(--gutter) 5rem;
  display: grid;
  grid-template-columns: minmax(0, 1.4fr) minmax(0, 1fr);
  gap: clamp(2.5rem, 5vw, 5rem);
  align-items: start;
}

/* ---- Gallery Column (Left) ---- */
.product-gallery {
  position: sticky;
  top: 100px;
  min-width: 0;   /* allow column to shrink so thumbs wrap instead of widening page */
}
.product-hero-wrap {
  position: relative;
  width: 100%;
  aspect-ratio: auto;
  background: #F1EDE8;
  border: 1px solid var(--line);
  overflow: hidden;
  display: flex;
  align-items: center;
  justify-content: center;
}
.product-hero-img {
  width: 100%;
  height: auto;
  max-height: 62vh;   /* 78vh se 20% kam - thumbnails visible */
  object-fit: contain;
  opacity: 1;
  transition: opacity 0.5s var(--ease);
}
.product-hero-img.loading {
  opacity: 0.3;
}

/* Thumbnails - default me sirf original (Web Preview) thumb dikhe;
   expand/selection par baaki mockup thumbs bhi */
.product-thumbs {
  display: flex;
  flex-wrap: wrap;          /* thumbs wrap to 2nd/3rd line, never wider than image box */
  gap: 0.75rem;
  margin-top: 1rem;
  padding-bottom: 0.5rem;
}
.product-thumbs .product-thumb { display: none; }
.product-thumbs .product-thumb[data-img-key="hero"] { display: block; }
.product-thumbs.expanded .product-thumb { display: block; }

/* Add to Cart disabled - jab tak size + presentation select na ho */
.btn-navy.disabled {
  opacity: 0.45;
  cursor: not-allowed;
}
.btn-navy.disabled:hover { background: var(--navy); }
.thumbs-toggle {
  display: inline-flex;
  align-items: center;
  gap: .5rem;
  margin-top: .9rem;
  background: none;
  border: none;
  cursor: pointer;
  font-family: var(--display);
  font-size: .68rem;
  letter-spacing: .2em;
  text-transform: uppercase;
  color: var(--gold-deep, #A8892A);
  transition: color .25s;
}
.thumbs-toggle:hover { color: var(--navy, #0D1B35); }


.product-thumb {
  flex: 0 0 80px;
  height: 80px;
  background: #F1EDE8;
  border: 2px solid var(--line);
  cursor: pointer;
  overflow: hidden;
  transition: border-color 0.25s var(--ease), box-shadow 0.25s var(--ease);
  padding: 4px;
}
.product-thumb:hover {
  border-color: var(--navy-muted);
}
.product-thumb.active {
  border-color: var(--navy);
  box-shadow: 0 0 0 1px var(--navy);
}
.product-thumb img {
  width: 100%;
  height: 100%;
  object-fit: contain;
}

/* ---- Info Column (Right) ---- */
.product-info {
  padding-top: 0;          /* image box ke top se aligned */
}
.product-eyebrow { margin-top: 0; line-height: 1; }
.product-eyebrow {
  font-family: var(--sans);
  font-size: 0.68rem;
  letter-spacing: 0.3em;
  text-transform: uppercase;
  color: var(--gold-deep, #A8892A);
  margin-bottom: 1rem;
  display: inline-block;
}
.product-title {
  font-family: var(--title);
  font-size: clamp(2.2rem, 4vw, 3.2rem);
  font-weight: 300;
  letter-spacing: -0.02em;
  line-height: 1.08;
  color: var(--blue-deep, #0D1B35);
  margin: 0 0 0.25rem;
}
.product-subtitle {
  font-family: var(--title);
  font-style: italic;
  font-size: clamp(1.1rem, 2vw, 1.5rem);
  color: var(--navy-muted);
  font-weight: 400;
  letter-spacing: -0.01em;
  margin-bottom: 1.5rem;
}
.product-desc {
  font-size: 1rem;
  color: var(--ink-muted);
  line-height: 1.7;
  max-width: 52ch;
  margin-bottom: 2.5rem;
}

/* ---- Divider within product ---- */
.product-divider {
  height: 1px;
  background: var(--line);
  border: 0;
  margin: 2rem 0;
}

/* ---- Size Selector ---- */
.selector-group {
  margin-bottom: 2rem;
}
.selector-label {
  font-family: var(--sans);
  font-size: 0.68rem;
  letter-spacing: 0.26em;
  text-transform: uppercase;
  color: var(--gold-deep, #A8892A);
  margin-bottom: 0.75rem;
  display: block;
}
.size-options {
  display: flex;
  gap: 0;
  border: 1px solid var(--line);
}
.size-btn {
  flex: 1;
  min-width: 0;
  padding: 0.9rem 0.6rem;
  background: transparent;
  border: none;
  border-right: 1px solid var(--line);
  font-family: var(--sans);
  font-size: 0.78rem;
  letter-spacing: 0.12em;
  color: var(--ink-muted);
  cursor: pointer;
  text-align: center;
  transition: all 0.25s var(--ease);
  position: relative;
}
.size-btn:last-child { border-right: none; }
.size-btn:hover {
  color: var(--navy);
  background: var(--navy-subtle);
}
.size-btn.active {
  color: #fff;
  background: var(--navy);
}
.size-btn .size-dim {
  display: block;
  font-size: 0.95rem;
  font-weight: 600;
  letter-spacing: -0.01em;
  margin-bottom: 0.15rem;
  white-space: nowrap;
}
/* put the (cm) measurement on its own line so 4 sizes fit the column */
.size-btn .size-dim span {
  display: block;
  white-space: nowrap;
}
.size-btn .size-label {
  font-size: 0.62rem;
  letter-spacing: 0.2em;
  text-transform: uppercase;
  opacity: 0.7;
}

/* ---- Presentation Selector (Frame / Acrylic) ---- */
.presentation-options {
  display: flex;
  flex-direction: column;
  gap: 0.5rem;
}
.presentation-btn {
  display: flex;
  align-items: center;
  gap: 1rem;
  padding: 1rem 1.25rem;
  background: transparent;
  border: 1px solid var(--line);
  cursor: pointer;
  transition: all 0.25s var(--ease);
  text-align: left;
  width: 100%;
}
.presentation-btn:hover {
  border-color: var(--navy-muted);
  background: var(--navy-subtle);
}
.presentation-btn.active {
  border-color: var(--navy);
  background: var(--navy-subtle);
  box-shadow: inset 3px 0 0 var(--navy);
}
.presentation-radio {
  width: 18px;
  height: 18px;
  border-radius: 50%;
  border: 2px solid var(--line);
  flex-shrink: 0;
  position: relative;
  transition: border-color 0.25s var(--ease);
}
.presentation-btn.active .presentation-radio {
  border-color: var(--navy);
}
.presentation-btn.active .presentation-radio::after {
  content: "";
  position: absolute;
  top: 3px; left: 3px; right: 3px; bottom: 3px;
  border-radius: 50%;
  background: var(--navy);
}
.presentation-text {
  flex: 1;
}
.presentation-name {
  font-family: var(--sans);
  font-size: 0.85rem;
  font-weight: 500;
  color: var(--ink);
  display: block;
  margin-bottom: 0.1rem;
}
.presentation-note {
  font-family: var(--sans);
  font-size: 0.68rem;
  color: var(--ink-muted);
  letter-spacing: 0.05em;
}
.presentation-price-tag {
  font-family: var(--sans);
  font-size: 0.85rem;
  font-weight: 600;
  color: var(--navy);
  white-space: nowrap;
}

/* ---- Frame Color Sub-selector ---- */
.frame-color-wrap {
  margin-top: 0.75rem;
  padding: 1rem 1.25rem;
  background: var(--navy-subtle);
  border: 1px solid rgba(13, 27, 53, 0.12);
  display: none;
}
.frame-color-wrap.visible { display: block; }

.frame-color-label {
  font-family: var(--sans);
  font-size: 0.62rem;
  letter-spacing: 0.24em;
  text-transform: uppercase;
  color: var(--ink-muted);
  margin-bottom: 0.6rem;
  display: block;
}
.frame-colors {
  display: flex;
  gap: 0.75rem;
}
.frame-color-btn {
  display: flex;
  align-items: center;
  gap: 0.6rem;
  padding: 0.5rem 0.75rem;
  background: var(--bg);
  border: 2px solid var(--line);
  cursor: pointer;
  transition: border-color 0.25s var(--ease);
  flex: 1;
}
.frame-color-btn:hover { border-color: var(--navy-muted); }
.frame-color-btn.active {
  border-color: var(--navy);
  box-shadow: 0 0 0 1px var(--navy);
}
/* Active outline frame ke apne color me - black frame = black, brown frame = brown */
.frame-color-btn[data-frame="black"].active {
  border-color: #1a1a1a;
  box-shadow: 0 0 0 1px #1a1a1a;
}
.frame-color-btn[data-frame="brown"].active {
  border-color: #5c3e24;
  box-shadow: 0 0 0 1px #5c3e24;
}
.frame-color-swatch {
  width: 28px;
  height: 28px;
  border-radius: 3px;
  flex-shrink: 0;
}
.frame-color-swatch.swatch-black { background: #1a1a1a; }
.frame-color-swatch.swatch-brown { background: #5c3e24; }
.frame-color-text {
  font-family: var(--sans);
  font-size: 0.72rem;
  font-weight: 500;
  color: var(--ink);
}

/* ---- Frame Detail (close-up image) ---- */
.frame-detail {
  margin-top: 1rem;
  display: none;
  overflow: hidden;
  border: 1px solid var(--line);
  background: #fff;
}
.frame-detail.visible { display: block; }
.frame-detail img {
  width: 100%;
  height: auto;
  max-height: 160px;
  object-fit: cover;
  transition: transform 0.6s var(--ease);
}
.frame-detail:hover img { transform: scale(1.05); }

/* ---- Price Display ---- */
.product-price-display {
  margin: 2.5rem 0;
  padding: 1.5rem 0;
  border-top: 1px solid var(--line);
  border-bottom: 1px solid var(--line);
}
.price-current {
  font-family: var(--title);
  font-size: clamp(2rem, 3.5vw, 2.8rem);
  font-weight: 400;
  color: var(--blue-deep, #0D1B35);
  letter-spacing: -0.02em;
  line-height: 1;
}
.price-current .currency {
  font-size: 0.6em;
  font-weight: 400;
  vertical-align: super;
  margin-right: 0.1em;
  color: var(--navy);
}
.price-config {
  margin-top: 0.5rem;
  font-family: var(--sans);
  font-size: 0.72rem;
  letter-spacing: 0.16em;
  text-transform: uppercase;
  color: var(--ink-muted);
}

/* ---- CTA Buttons ---- */
.product-cta {
  display: flex;
  flex-direction: row;
  flex-wrap: wrap;
  gap: 0.75rem;
  margin-bottom: 2.5rem;
}
.product-cta > a {
  flex: 1 1 0;
  width: auto;
  min-width: 0;
  padding: 1.1rem 1rem;
  font-size: 0.72rem;
  letter-spacing: 0.12em;
  white-space: nowrap;   /* keep "Request Custom Size" on one line, same height as Add to Cart */
}
.btn-navy {
  display: flex;
  align-items: center;
  justify-content: center;
  width: 100%;
  padding: 1.1rem 2rem;
  background: var(--navy);
  color: #fff;
  font-family: var(--sans);
  font-size: 0.78rem;
  letter-spacing: 0.22em;
  text-transform: uppercase;
  text-align: center;
  border: 1px solid var(--navy);
  font-weight: 500;
  cursor: pointer;
  transition: all 0.3s var(--ease);
  text-decoration: none;
}
.btn-navy:hover {
  background: var(--gold-deep, #A8892A);   /* hover: gold - navy+gold brand combo */
  color: #fff;
}
.btn-navy-outline {
  display: flex;
  align-items: center;
  justify-content: center;
  text-align: center;
  width: 100%;
  padding: 1.1rem 2rem;
  background: transparent;
  color: var(--navy);
  font-family: var(--sans);
  font-size: 0.78rem;
  letter-spacing: 0.22em;
  text-transform: uppercase;
  text-align: center;
  border: 1px solid var(--navy);
  font-weight: 500;
  cursor: pointer;
  transition: all 0.3s var(--ease);
  text-decoration: none;
}
.btn-navy-outline:hover {
  background: var(--navy);
  color: #fff;
}

/* ---- Product Specs ---- */
.product-specs {
  list-style: none;
  padding: 0;
  margin: 0;
}
.product-specs li {
  display: flex;
  justify-content: space-between;
  align-items: baseline;
  padding: 0.75rem 0;
  border-bottom: 1px solid var(--line);
  font-size: 0.9rem;
}
.product-specs li:last-child { border-bottom: none; }
.spec-label {
  font-family: var(--sans);
  font-size: 0.68rem;
  letter-spacing: 0.22em;
  text-transform: uppercase;
  color: var(--ink-muted);
}
.spec-value {
  font-weight: 500;
  color: var(--ink);
  text-align: right;
}

/* ---- Edition Badge ---- */
.edition-badge {
  display: inline-flex;
  align-items: center;
  gap: 0.5rem;
  padding: 0.5rem 1rem;
  background: var(--gold-glow, rgba(201, 168, 76, 0.18));
  border: 1px solid rgba(201, 168, 76, 0.35);
  font-family: var(--sans);
  font-size: 0.68rem;
  letter-spacing: 0.18em;
  text-transform: uppercase;
  color: var(--gold-deep, #A8892A);
  font-weight: 700;                 /* Collector's Reserve - bold gold, more prominent (per Sarah) */
  margin-bottom: 1.5rem;
}
.edition-badge .dot {
  width: 6px;
  height: 6px;
  border-radius: 50%;
  background: var(--gold, #C9A84C);
}

/* ---- Framing Info Section (below product) ---- */
.framing-section {
  max-width: var(--max);
  margin: 0 auto;
  padding: 4rem var(--gutter) 5rem;
  border-top: 1px solid var(--line);
}
.framing-header {
  text-align: center;
  margin-bottom: 3rem;
}
.framing-header h2 {
  margin-bottom: 0.5rem;
}
.framing-header p {
  color: var(--ink-muted);
  max-width: 56ch;
  margin: 0 auto;
}
.framing-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 2rem;
}
.framing-card {
  text-align: center;
  padding: 2rem 1.5rem;
  border: 1px solid var(--line);
  background: var(--bg-2);
  transition: border-color 0.25s var(--ease);
}
.framing-card:hover { border-color: var(--navy-muted); }
.framing-card-img {
  width: 100%;
  aspect-ratio: 1;
  object-fit: contain;
  margin-bottom: 1.25rem;
  border: 1px solid var(--line);
}
.framing-card h4 {
  font-family: var(--sans);
  font-size: 0.85rem;
  letter-spacing: 0.1em;
  font-weight: 600;
  margin-bottom: 0.5rem;
  color: var(--blue-deep, #0D1B35);
}
.framing-card p {
  font-size: 0.85rem;
  color: var(--ink-muted);
  line-height: 1.6;
}

/* ---- Responsive ---- */
@media (max-width: 980px) {
  .product-page {
    grid-template-columns: 1fr;
    gap: 2.5rem;
    padding-bottom: 3rem;
  }
  .product-gallery {
    position: static;
  }
  .product-hero-img {
    max-height: 48vh;
  }
  .framing-grid {
    grid-template-columns: 1fr 1fr;
  }
}

@media (max-width: 640px) {
  .size-options {
    flex-direction: column;
  }
  .size-btn {
    border-right: none;
    border-bottom: 1px solid var(--line);
  }
  .size-btn:last-child { border-bottom: none; }
  .frame-colors {
    flex-direction: column;
  }
  .framing-grid {
    grid-template-columns: 1fr;
  }
  .product-thumbs {
    gap: 0.5rem;
  }
  .product-thumb {
    flex: 0 0 64px;
    height: 64px;
  }
}

/* ════════════════════════════════════════
   SIZE DROPDOWN (Select Size - list style)
   ════════════════════════════════════════ */
.size-dropdown { position: relative; }
.size-dd-trigger {
  width: 100%;
  display: flex; align-items: center; justify-content: space-between;
  gap: 1rem;
  padding: 0.95rem 1.1rem;
  background: transparent;
  border: 1px solid var(--line);
  font-family: var(--sans);
  font-size: 0.95rem;
  font-weight: 600;
  color: var(--navy, #0D1B35);
  cursor: pointer;
  text-align: left;
  transition: border-color .25s var(--ease);
}
.size-dd-trigger:hover { border-color: var(--navy, #0D1B35); }
.size-dd-sub {
  font-weight: 400;
  font-size: .68rem;
  letter-spacing: .16em;
  text-transform: uppercase;
  color: var(--ink-muted);
}
.size-dd-caret {
  width: 8px; height: 8px; flex-shrink: 0;
  border-right: 1.5px solid currentColor;
  border-bottom: 1.5px solid currentColor;
  transform: rotate(45deg);
  transition: transform .25s var(--ease);
  margin-top: -4px;
}
.size-dropdown.open .size-dd-caret { transform: rotate(-135deg); margin-top: 4px; }

/* list (purana .size-options ab dropdown ke andar) */
.size-dropdown .size-options {
  position: absolute;
  top: calc(100% - 1px); left: 0; right: 0;
  z-index: 30;
  background: #fff;
  border: 1px solid var(--line);
  box-shadow: 0 14px 30px rgba(13, 27, 53, .14);
  display: none;
  flex-direction: column;
}
.size-dropdown.open .size-options { display: flex; }
.size-dropdown .size-btn {
  border-right: none;
  border-bottom: 1px solid var(--line);
  text-align: left;
  display: flex;
  align-items: baseline;
  justify-content: space-between;
  gap: .75rem;
  padding: 0.85rem 1.1rem;
}
.size-dropdown .size-btn:last-child { border-bottom: none; }
.size-dropdown .size-btn .size-dim { margin-bottom: 0; }

/* ── Unavailable presentation option (e.g. acrylic-exclusive editions) ── */
.presentation-btn.disabled {
  opacity: 0.45;
  cursor: not-allowed;
  background: var(--bg-2, #F6F6F4);
}
.presentation-btn.disabled:hover { border-color: var(--line); box-shadow: none; }
.presentation-btn.disabled .presentation-price-tag {
  color: var(--ink-muted);
  font-weight: 400;
  font-size: 0.72rem;
  letter-spacing: 0.08em;
  text-transform: uppercase;
}

/* ================================================================
   OPEN EDITION BADGE - plain/neutral (no gold band)
   Collector's Reserve keeps the default gold styling above
   ================================================================ */
.edition-badge.open-edition {
  background: rgba(0, 0, 0, 0.035);
  border: 1px solid rgba(0, 0, 0, 0.10);
  color: #888;
  font-weight: 400;                 /* Open Edition stays regular weight */
}
.edition-badge.open-edition .dot {
  background: #c0c0c0;
}

/* ================================================================
   PRODUCT IMAGE LIGHTBOX
   Click hero image to view full-screen
   ================================================================ */

/* Zoom cursor + hover hint on the image wrapper */
.product-hero-wrap {
  cursor: zoom-in;
}
.product-hero-wrap::after {
  content: '';
  position: absolute;
  bottom: 0.85rem;
  right: 0.85rem;
  width: 2rem;
  height: 2rem;
  border-radius: 50%;
  background: rgba(255, 255, 255, 0.88)
    url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='%23444' stroke-width='2.2' stroke-linecap='round'%3E%3Ccircle cx='10' cy='10' r='6.5'/%3E%3Cline x1='15' y1='15' x2='21' y2='21'/%3E%3Cline x1='10' y1='7.5' x2='10' y2='12.5'/%3E%3Cline x1='7.5' y1='10' x2='12.5' y2='10'/%3E%3C/svg%3E")
    center / 58% no-repeat;
  box-shadow: 0 2px 8px rgba(0,0,0,0.18);
  opacity: 0;
  transform: scale(0.85);
  transition: opacity 0.2s ease, transform 0.2s ease;
  pointer-events: none;
  z-index: 2;
}
.product-hero-wrap:hover::after {
  opacity: 1;
  transform: scale(1);
}

/* Lightbox overlay */
.slg-lightbox {
  position: fixed;
  inset: 0;
  z-index: 9990;
  background: rgba(13, 27, 53, 0.95);
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 2rem;
  box-sizing: border-box;
  cursor: zoom-out;
  opacity: 0;
  visibility: hidden;
  transition: opacity 0.28s ease, visibility 0.28s ease;
}
.slg-lightbox.is-open {
  opacity: 1;
  visibility: visible;
}
.slg-lightbox-img {
  max-width: 90vw;
  max-height: 90vh;
  object-fit: contain;
  display: block;
  box-shadow: 0 24px 80px rgba(0, 0, 0, 0.55);
  animation: slg-lb-in 0.28s ease both;
}
@keyframes slg-lb-in {
  from { transform: scale(0.93); opacity: 0; }
  to   { transform: scale(1);    opacity: 1; }
}
.slg-lightbox-close {
  position: fixed;
  top: 1.1rem;
  right: 1.4rem;
  color: rgba(255, 255, 255, 0.6);
  font-size: 2rem;
  font-weight: 300;
  line-height: 1;
  background: none;
  border: none;
  cursor: pointer;
  padding: 0.4rem 0.6rem;
  transition: color 0.18s;
  z-index: 1;
}
.slg-lightbox-close:hover { color: #fff; }
