/*
 * Barbara Rizzi website: the product page (components/product/page.php), ported from the WordPress theme's
 * woocommerce/single-product.php with WooCommerce's and the size swatches plugin's rules that applied to it.
 * The cards of "Complete your look" are in shop.css. Differences in docs/phases/06-website/06c-shop.md.
 */

/* Room for the fixed header: WordPress drew the page under it, hiding the breadcrumb, "Back to Shop" and the
   collection line above the name. */
.brsp { background: #faf8f5; font-family: var(--br-font-sans); width: 100%; padding-top: 92px; }

/* Breadcrumb */
.brsp-bc {
  display: flex;
  align-items: center;
  flex-wrap: wrap;
  gap: 8px;
  width: 100%;
  padding: 14px 40px;
  font-size: 9px;
  letter-spacing: 0.14em;
  text-transform: uppercase;
  color: #8a8580;
  background: #ffffff;
  border-bottom: 0.5px solid #e2ddd6;
}
.brsp-bc a { color: #8a8580; }
.brsp-bc a:hover { color: #b8923a; }
.brsp-bc .sep { color: #c8c2b8; }

/* Three columns: sidebar, gallery, details */
.brsp-wrap { display: grid; grid-template-columns: 220px 1fr 460px; min-height: 85vh; width: 100%; }

/* Sidebar */
.brsp-sidebar { background: #ffffff; border-right: 0.5px solid #e2ddd6; display: flex; flex-direction: column; }
.brsp-back {
  display: flex;
  align-items: center;
  gap: 10px;
  padding: 20px 24px;
  font-size: 8px;
  font-weight: 500;
  letter-spacing: 0.28em;
  text-transform: uppercase;
  color: #1a1816;
  background: #faf8f5;
  border-bottom: 0.5px solid #e2ddd6;
  transition: all 0.2s;
}
.brsp-back svg { flex-shrink: 0; transition: transform 0.2s; }
.brsp-back:hover { color: #b8923a; background: #ffffff; }
.brsp-back:hover svg { transform: translateX(-3px); }
.brsp-sb-scroll { flex: 1; padding: 24px 24px 40px; overflow-y: auto; scrollbar-width: none; }
.brsp-sb-scroll::-webkit-scrollbar { display: none; }
.brsp-sb-section { margin-bottom: 28px; }
.brsp-sb-title { display: block; font-size: 8px; letter-spacing: 0.3em; text-transform: uppercase; color: #b8923a; margin-bottom: 12px; padding-bottom: 8px; border-bottom: 0.5px solid #e2ddd6; }
.brsp-sb-subtitle { display: block; font-size: 7px; letter-spacing: 0.22em; text-transform: uppercase; color: #a8a8a2; margin: 10px 0 6px; padding-left: 2px; }
.brsp-sb-link {
  display: flex;
  justify-content: space-between;
  align-items: center;
  width: 100%;
  padding: 7px 0;
  font-size: 10px;
  letter-spacing: 0.06em;
  color: #5a5650;
  border-bottom: 0.5px solid #f0ede8;
  transition: all 0.2s;
}
.brsp-sb-link:hover { color: #b8923a; padding-left: 4px; }
.brsp-sb-link.active { color: #1a1816; font-weight: 500; }
.brsp-sb-count { font-size: 9px; color: #a8a8a2; }
.brsp-sb-elem-link {
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding: 6px 0 6px 10px;
  font-size: 9px;
  letter-spacing: 0.06em;
  color: #7a7670;
  border-bottom: 0.5px solid #f0ede8;
  transition: all 0.2s;
}
.brsp-sb-elem-link:hover { color: #b8923a; padding-left: 14px; }
.brsp-sb-elem-link.active { color: #1a1816; font-weight: 500; }
.brsp-sb-elem-link .elem-name { display: flex; align-items: center; }
.brsp-sb-type-link { display: block; padding: 7px 0; font-size: 10px; letter-spacing: 0.06em; color: #5a5650; border-bottom: 0.5px solid #f0ede8; transition: color 0.2s; }
.brsp-sb-type-link:hover { color: #b8923a; }
.brsp-sb-type-link.arrow::before { content: '→ '; color: #b8923a; }
.brsp-tag-cloud { display: flex; flex-wrap: wrap; gap: 5px; padding-top: 6px; }
.brsp-tag { font-size: 8px; letter-spacing: 0.1em; text-transform: uppercase; padding: 4px 8px; border: 0.5px solid #e2ddd6; color: #5a5650; line-height: 1; transition: all 0.2s; }
.brsp-tag:hover { border-color: #b8923a; color: #b8923a; }
.brsp-tag.active { background: #1a1816; border-color: #1a1816; color: #ffffff; }
.brsp-sb-toggle {
  display: none;
  width: 100%;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  padding: 16px 24px;
  font-size: 9px;
  letter-spacing: 0.26em;
  text-transform: uppercase;
  color: #1a1816;
  background: #faf8f5;
  border: none;
  border-bottom: 0.5px solid #e2ddd6;
  cursor: pointer;
}
.brsp-sb-toggle-ic { color: #b8923a; font-size: 12px; transition: transform 0.3s; }
.brsp-sidebar.collapsed .brsp-sb-toggle-ic { transform: rotate(-90deg); }

/* Gallery: one photo at a time */
.brsp-gallery { display: flex; flex-direction: column; align-items: center; min-width: 0; background: #ffffff; }
.brsp-gallery__main { position: relative; overflow: hidden; width: 100%; max-width: 1080px; margin: 0 auto; aspect-ratio: 3 / 4; }
.brsp-main-slide { position: absolute; top: 0; left: 0; width: 100%; height: 100%; object-fit: cover; object-position: center top; display: none; }
.brsp-main-slide.active { display: block; }
.brsp-nav {
  position: absolute;
  top: 50%;
  transform: translateY(-50%);
  z-index: 4;
  display: flex;
  align-items: center;
  justify-content: center;
  width: 36px;
  height: 36px;
  color: #1a1816;
  background: rgba(250, 248, 245, 0.88);
  border: none;
  cursor: pointer;
  backdrop-filter: blur(4px);
  transition: all 0.2s;
}
.brsp-nav:hover { background: #1a1816; color: #ffffff; }
.brsp-nav--prev { left: 12px; }
.brsp-nav--next { right: 12px; }
.brsp-nav-counter { position: absolute; bottom: 12px; right: 12px; font-size: 9px; letter-spacing: 0.16em; color: rgba(250, 248, 245, 0.7); background: rgba(26, 24, 22, 0.4); padding: 3px 8px; backdrop-filter: blur(4px); }

/* Details */
/* min-width 0: a long row of thumbnails scrolls instead of widening the column */
.brsp-info { min-width: 0; padding: 36px 36px 48px; background: #ffffff; border-left: 0.5px solid #e2ddd6; }
.brsp-meta-top { display: flex; align-items: center; gap: 10px; margin-bottom: 10px; }
.brsp-coll { font-size: 8px; letter-spacing: 0.26em; text-transform: uppercase; color: #b8923a; }
.brsp-dot { color: #c8c2b8; }
.brsp-type { font-size: 8px; letter-spacing: 0.2em; text-transform: uppercase; color: #8a8580; }
.brsp-title { font-family: var(--br-font-serif); font-size: clamp(24px, 2.2vw, 34px); font-weight: 300; line-height: 1.1; color: #1a1816; margin-bottom: 6px; }
.brsp-sku { font-size: 9px; letter-spacing: 0.16em; text-transform: uppercase; color: #b8b0a8; margin-bottom: 18px; }
.brsp-thumbs-info { display: flex; flex-wrap: nowrap; gap: 4px; margin-bottom: 18px; overflow-x: auto; scrollbar-width: none; }
.brsp-thumbs-info::-webkit-scrollbar { display: none; }
.brsp-thumb { flex-shrink: 0; width: 58px; min-width: 58px; aspect-ratio: 3 / 4; overflow: hidden; padding: 0; background: none; border: 1.5px solid transparent; cursor: pointer; transition: border-color 0.2s; }
.brsp-thumb.on { border-color: #b8923a; }
.brsp-thumb img { width: 100%; height: 100%; object-fit: cover; display: block; }
.brsp-price { display: flex; align-items: baseline; flex-wrap: wrap; gap: 10px; margin-bottom: 14px; }
.brsp-price__reg { font-size: 20px; letter-spacing: 0.04em; color: #1a1816; }
.brsp-price__vat { font-size: 8px; letter-spacing: 0.12em; text-transform: uppercase; color: #a8a8a2; margin-left: auto; }
.brsp-color { font-size: 11px; line-height: 1.7; color: #5a5650; margin-bottom: 20px; }

/* Cart form, as WooCommerce's with the size swatches plugin */
.brsp-atc { margin-bottom: 14px; }
.brsp-atc .stock { margin: 0; }
.brsp-atc form.cart { display: flex; flex-direction: column; }
.brsp-options { margin-bottom: 4px; }
.brsp-options__label { padding: 4px 0; }
.brsp-options__label > span { display: inline-block; margin: 0 2px; font-size: 9px; font-weight: 600; letter-spacing: 0.18em; text-transform: uppercase; color: #5a5650; }
.brsp-options__label > .brsp-options__chosen { margin: 0; letter-spacing: 0.1em; }
.brsp-options__values { padding: 4px 0; }
.brsp-options__items { display: flex; flex-wrap: wrap; }
.brsp-option {
  position: relative;
  display: flex;
  justify-content: center;
  align-items: center;
  min-width: 30px;
  height: 30px;
  margin: 4px;
  padding: 2px;
  font-size: 16px;
  color: #000000;
  background: #ffffff;
  border-radius: 2px;
  box-shadow: 0 0 0 1px #a8a8a8;
  cursor: pointer;
  user-select: none;
  transition: all 200ms ease;
}
.brsp-option:last-child { margin-right: 0; }
.brsp-option:hover { box-shadow: 0 0 0 3px #dddddd; }
.brsp-option:has(input:checked) { box-shadow: 0 0 0 2px #000000; }
.brsp-option:has(input:focus-visible) { outline: 2px solid #b8923a; outline-offset: 3px; }
.brsp-option input { position: absolute; opacity: 0; width: 1px; height: 1px; pointer-events: none; }
.brsp-option__text { padding: 0 5px; }
.brsp-option.is-out-of-stock { cursor: not-allowed; }
.brsp-option.is-out-of-stock .brsp-option__text { opacity: 0.6; }
.brsp-option.is-out-of-stock::before {
  content: '';
  position: absolute;
  inset: 0;
  background: url("data:image/svg+xml;utf8,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24'%3E%3Cpath fill='none' stroke='%23ff0000' stroke-linecap='round' stroke-width='0.6' d='M5 5L19 19M19 5L5 19'/%3E%3C/svg%3E") no-repeat center / 100% 100%;
}
.brsp-options__clear { display: block; font-size: 14px; line-height: 1.6; color: #1a1816; background: none; border: none; padding: 0; cursor: pointer; visibility: hidden; }
.brsp-options__clear.is-shown { visibility: visible; }
.brsp-atc .quantity { display: flex; align-items: center; width: 96px; border: 0.5px solid #e2ddd6; }
/* One piece only: WooCommerce hid the quantity but kept its empty box (a stray line); its room is kept */
.brsp-atc .quantity--single { border-color: transparent; }
.brsp-atc .quantity .qty { width: 3.631em; padding: 9px; font-size: 14px; text-align: center; background: #ffffff; border: none; outline: none; -moz-appearance: textfield; }
.brsp-atc .quantity .qty::-webkit-outer-spin-button, .brsp-atc .quantity .qty::-webkit-inner-spin-button { -webkit-appearance: none; }
.brsp-size-msg { margin-top: 18px; font-size: 11px; letter-spacing: 0.06em; text-align: center; color: #b8923a; }
.single_add_to_cart_button {
  display: block;
  width: 100%;
  margin-top: 10px;
  padding: 14px 32px;
  font-size: 9px;
  font-weight: 600;
  line-height: 1;
  letter-spacing: 0.2em;
  text-transform: uppercase;
  color: #ffffff;
  background: #1a1816;
  border: none;
  cursor: pointer;
  transition: background 0.3s;
}
.single_add_to_cart_button:hover { background: #b8923a; }
/* No option chosen yet: WooCommerce's disabled look (a click says which option is missing) */
.single_add_to_cart_button.is-waiting, .single_add_to_cart_button.is-waiting:hover { opacity: 0.5; background: #1a1816; cursor: not-allowed; }

/* Pre-order note, wishlist, model height */
.brsp-preorder-note {
  display: flex;
  align-items: flex-start;
  gap: 10px;
  margin: 14px 0;
  padding: 12px 16px;
  font-size: 11px;
  line-height: 1.6;
  letter-spacing: 0.04em;
  color: #5a5650;
  background: #f6f2ec;
  border-left: 2px solid #b8923a;
}
.brsp-preorder-note svg { flex-shrink: 0; margin-top: 1px; color: #b8923a; }
.brsp-wishlist-wrap { margin-bottom: 14px; }
.brsp-wishlist-btn { padding: 0; font-size: 16px; line-height: 1.6; color: #1a1816; background: none; border: none; cursor: pointer; }
.brsp-wishlist-btn:hover { color: #b8923a; }
.brsp-model-row { display: flex; justify-content: space-between; padding: 10px 0; margin-bottom: 4px; border-bottom: 0.5px solid #e2ddd6; }
.brsp-model-lbl { font-size: 9px; letter-spacing: 0.16em; text-transform: uppercase; color: #8a8580; }
.brsp-model-val { font-size: 11px; color: #1a1816; }
.brsp-divider { height: 0.5px; background: #e2ddd6; margin: 16px 0 0; }

/* Accordions: Description, Fabric & Care */
.brsp-acc-item { border-bottom: 0.5px solid #e2ddd6; }
.brsp-acc-btn {
  display: flex;
  justify-content: space-between;
  align-items: center;
  width: 100%;
  padding: 13px 0;
  font-size: 9px;
  letter-spacing: 0.2em;
  text-transform: uppercase;
  color: #1a1816;
  background: none;
  border: none;
  cursor: pointer;
}
.brsp-acc-btn:hover { color: #b8923a; }
.brsp-acc-icon { font-size: 16px; line-height: 1; color: #a8a8a2; transition: transform 0.3s; }
.brsp-acc-btn.on .brsp-acc-icon { transform: rotate(45deg); color: #b8923a; }
.brsp-acc-body { display: none; padding-bottom: 14px; font-size: 11px; line-height: 1.85; color: #5a5650; }
.brsp-acc-body.open { display: block; }
.brsp-acc-body p { margin-bottom: 6px; }
.brsp-acc-body strong { color: #1a1816; font-weight: 500; }

/* Ask about this piece (WhatsApp) */
.brsp-wa {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  margin-top: 12px;
  padding: 11px;
  font-size: 9px;
  letter-spacing: 0.14em;
  text-transform: uppercase;
  color: #5a5650;
  border: 0.5px solid #e2ddd6;
  transition: all 0.25s;
}
.brsp-wa:hover { border-color: #25d366; color: #25d366; }

/* Complete your look */
.brsp-related { width: 100%; padding: 64px 40px; background: #faf8f5; border-top: 0.5px solid #e2ddd6; }
.brsp-rel-head { margin-bottom: 36px; }
.brsp-rel-eye { display: block; font-size: 8px; letter-spacing: 0.3em; text-transform: uppercase; color: #b8923a; margin-bottom: 8px; }
.brsp-rel-title { font-family: var(--br-font-serif); font-size: 30px; font-weight: 300; color: #1a1816; }
.brsp-rel-title em { font-style: italic; color: #b8923a; }
.brsp-rel-grid { display: grid; grid-template-columns: repeat(4, 1fr); gap: 2px; }
.brsp-rel-cta { text-align: center; margin-top: 36px; }
.brsp-rel-cta a { font-size: 9px; letter-spacing: 0.2em; text-transform: uppercase; color: #8a8580; }
.brsp-rel-cta a:hover { color: #b8923a; }

.screen-reader-text { position: absolute !important; width: 1px; height: 1px; overflow: hidden; clip: rect(1px, 1px, 1px, 1px); white-space: nowrap; }

@media (max-width: 1200px) {
  .brsp-wrap { grid-template-columns: 180px 1fr 400px; }
}
@media (max-width: 960px) {
  .brsp { padding-top: 64px; }
  .brsp-wrap { grid-template-columns: 1fr 400px; }
  .brsp-sidebar { grid-column: 1 / -1; border-right: none; border-bottom: 0.5px solid #e2ddd6; }
  .brsp-sb-toggle { display: flex; }
  .brsp-sb-scroll { max-height: 2000px; transition: max-height 0.35s ease, padding 0.35s ease; }
  .brsp-sidebar.collapsed .brsp-sb-scroll { max-height: 0; padding-top: 0; padding-bottom: 0; overflow: hidden; visibility: hidden; }
}
@media (max-width: 768px) {
  .brsp-wrap { grid-template-columns: 1fr; }
  .brsp-info { padding: 24px 20px; border-left: none; border-top: 0.5px solid #e2ddd6; }
  .brsp-bc { padding: 10px 20px; }
  .brsp-rel-grid { grid-template-columns: 1fr 1fr; }
  .brsp-related { padding: 40px 20px; }
}
@media (max-width: 480px) {
  .brsp-rel-grid { gap: 1px; }
}
