/* Buddy Public Booking · FULL design - Step 4: Inclusions.
 * Horizontal product cards (image | title + categories + action) in a grid,
 * plus the expandable option blocks (WooCommerce variations + YITH add-ons). */

/* Product-card grid */
.bb-cards { grid-template-columns: repeat(auto-fill, minmax(240px, 1fr)); gap: 16px; align-items: stretch; }
.bb-prod-card {
  display: flex;
  flex-direction: column;
  overflow: hidden;
  border: 1px solid var(--bb-gray-300);
  border-radius: 12px;
  background: #fff;
  box-shadow: 0 1px 2px rgba(16,24,40,.04);
  transition: border-color .1s ease, box-shadow .1s ease;
}
.bb-prod-card:hover { border-color: var(--bb-gray-400); }
.bb-prod-card.is-selected, .bb-prod-card.is-expanded { border-color: var(--bb-purple); box-shadow: 0 0 0 1px var(--bb-purple); }
.bb-prod-head { display: flex; flex-direction: column; gap: 0; align-items: stretch; }
.bb-prod-img { display: block; width: 100%; height: 160px; flex: 0 0 auto; object-fit: contain; border-radius: 0; background: var(--bb-fade); }
.bb-prod-img.is-empty { display: grid; min-height: 160px; place-items: center; background: var(--bb-fade); color: var(--bb-muted-label); font-size: 12px; }
.bb-prod-body { display: flex; flex: 1; min-width: 0; padding: 16px 16px 0; flex-direction: column; gap: 4px; }
.bb-prod-title-row { display: flex; align-items: flex-start; justify-content: space-between; gap: 8px; }
.bb-prod-title { margin: 0; color: var(--bb-text); font-size: 14px; line-height: 20px; font-weight: 600; }
.bb-prod-added { display: inline-flex; height: 20px; flex: 0 0 auto; align-items: center; padding: 0 8px; border-radius: 999px; background: #ecfdf8; color: #0f766e; font-size: 12px; line-height: 16px; font-weight: 500; }
.bb-prod-cats { margin: 0; color: var(--bb-muted-label); font-size: 12px; line-height: 16px; }
.bb-prod-price { margin: 4px 0 0; color: var(--bb-muted-label); font-size: 12px; line-height: 16px; }
.bb-prod-summary { margin: 4px 0 0; color: var(--bb-text); font-size: 12px; line-height: 16px; }
.bb-prod-actions { display: flex; gap: 8px; padding: 16px; margin-top: auto; }
.bb-prod-actions .bb-btn { display: inline-flex; align-items: center; justify-content: center; }
.bb-prod-qty { display: flex; align-items: center; gap: 8px; padding: 16px 16px 0; }
.bb-prod-qty .bb-qty-label { color: var(--bb-text); font-size: 12px; font-weight: 500; }
.bb-prod-qty .bb-qty-btn { display: inline-grid; width: 30px; height: 30px; padding: 0; place-items: center; border: 1px solid var(--bb-gray-400); border-radius: 8px; background: #fff; color: var(--bb-text); font: inherit; font-size: 16px; cursor: pointer; }
.bb-prod-qty .bb-qty-btn:disabled { opacity: .5; cursor: not-allowed; }
.bb-prod-qty .bb-qty-val { min-width: 20px; color: var(--bb-text); font-size: 14px; font-weight: 500; text-align: center; }
.bb-qty-max { color: var(--bb-muted-label); font-size: 12px; white-space: nowrap; }

.bb-inclusion-heading { margin-bottom: 16px; }
.bb-inclusion-status { display: flex; align-items: center; flex-wrap: wrap; gap: 12px; margin: 0 0 16px; }
.bb-inclusion-count { display: inline-flex; height: 20px; align-items: center; padding: 0 8px; border-radius: 999px; background: var(--bb-purple-100); color: var(--bb-purple-dark); font-size: 12px; line-height: 16px; font-weight: 500; }
.bb-inclusion-status p { margin: 0; color: var(--bb-muted-label); font-size: 12px; line-height: 16px; }
.bb-inclusion-complete { display: flex; align-items: flex-start; gap: 12px; margin: 0 0 16px; padding: 16px; border: 1px solid #a6e4c6; border-radius: 12px; background: #effcf5; color: #166534; font-size: 14px; line-height: 20px; }
.bb-inclusion-complete p { margin: 0; }
.bb-inclusion-complete-icon { display: block; width: 16px; height: 16px; flex: 0 0 16px; margin-top: 2px; }

/* Expandable option blocks */
.bb-options { margin: 0 16px 16px; border-top: 1px solid var(--bb-gray-300); padding-top: 16px; display: flex; flex-direction: column; gap: 12px; }
.bb-option-block { background: var(--bb-fade); border: 1px solid var(--bb-gray-300); border-radius: 8px; padding: 12px; }
.bb-option-title { font-size: 13px; font-weight: 700; margin-bottom: 8px; }
.bb-option-subtitle { font-size: 12px; font-weight: 600; color: var(--bb-gray-800); margin: 8px 0 4px; }
.bb-radio-group { display: flex; flex-wrap: wrap; gap: 8px; }
.bb-radio {
  display: inline-flex;
  min-height: 30px;
  align-items: center;
  gap: 7px;
  padding: 0 10px;
  border: 1px solid var(--bb-gray-400);
  border-radius: 8px;
  background: #fff;
  color: var(--bb-text);
  font-size: 13px;
  line-height: 18px;
  cursor: pointer;
  transition: border-color 120ms ease, background-color 120ms ease, box-shadow 120ms ease;
}
.bb-radio:hover { border-color: var(--bb-purple); background: #f8faff; }
.bb-radio:has(input:focus-visible) { border-color: var(--bb-purple); box-shadow: 0 0 0 3px rgba(47,91,234,.16); }
.bb-radio.is-selected, .bb-radio:has(input:checked) { border-color: var(--bb-purple); background: var(--bb-purple-100); }
.bb-radio input[type="radio"] {
  appearance: none;
  -webkit-appearance: none;
  display: inline-grid;
  width: 16px !important;
  min-width: 16px;
  height: 16px !important;
  min-height: 16px;
  margin: 0 !important;
  padding: 0 !important;
  place-content: center;
  border: 1px solid var(--bb-gray-400);
  border-radius: 50%;
  background: #fff;
  box-shadow: none;
}
.bb-radio input[type="radio"]::before { width: 8px; height: 8px; border-radius: 50%; background: var(--bb-purple); content: ""; transform: scale(0); transition: transform 100ms ease; }
.bb-radio input[type="radio"]:checked { border-color: var(--bb-purple); }
.bb-radio input[type="radio"]:checked::before { transform: scale(1); }
.bb-radio-sm { min-height: 30px; padding: 0 10px; font-size: 13px; }
.bb-file-link { color: var(--bb-purple-dark); font-size: 14px; font-weight: 600; margin-right: 10px; }
.bb-options .bb-input[type="file"] { display: block; width: 100%; height: 40px; padding: 4px 8px; border-radius: 8px; color: var(--bb-muted-label); font-size: 13px; line-height: 30px; cursor: pointer; }
.bb-options .bb-input[type="file"]::file-selector-button { height: 30px; margin: 0 10px 0 0; padding: 0 10px; border: 1px solid var(--bb-gray-400); border-radius: 6px; background: #fff; color: var(--bb-text); font: inherit; font-weight: 500; cursor: pointer; }
.bb-options .bb-input[type="file"]::-webkit-file-upload-button { height: 30px; margin: 0 10px 0 0; padding: 0 10px; border: 1px solid var(--bb-gray-400); border-radius: 6px; background: #fff; color: var(--bb-text); font: inherit; font-weight: 500; cursor: pointer; }
.bb-options .bb-input[type="file"]:hover::file-selector-button { background: var(--bb-fade); }
.bb-options .bb-input[type="file"]:hover::-webkit-file-upload-button { background: var(--bb-fade); }

/* V5 product personalisation sheet. The existing variable/YITH controls are
 * mounted here without changing the data they collect. */
.bb-product-sheet-overlay { position: fixed; inset: 0; z-index: 10030; background: rgba(16,24,40,.45); }
.bb-product-sheet { position: fixed; top: 8px; right: 8px; bottom: 8px; z-index: 10031; display: flex; flex-direction: column; width: calc(100% - 16px); max-width: 512px; overflow: hidden; border-radius: 16px; background: #fff; box-shadow: 0 24px 48px -12px rgba(16,24,40,.28); }
.bb-product-sheet-header { display: flex; align-items: flex-start; justify-content: space-between; gap: 12px; padding: 16px 24px; border-bottom: 1px solid var(--bb-gray-300); }
.bb-product-sheet-header h3 { margin: 0; color: var(--bb-text); font-size: 18px; line-height: 28px; font-weight: 600; }
.bb-product-sheet-close { display: grid; width: 30px; height: 30px; flex: 0 0 30px; padding: 0; place-items: center; border: 0; border-radius: 8px; background: transparent; color: var(--bb-muted-label); font-size: 24px; line-height: 1; cursor: pointer; }
.bb-product-sheet-close:hover { background: var(--bb-fade); color: var(--bb-text); }
.bb-product-sheet-body { display: flex; flex: 1; flex-direction: column; gap: 24px; padding: 24px; overflow-y: auto; }
.bb-product-sheet-image { display: block; width: 100%; height: 180px; flex: 0 0 auto; object-fit: contain; border-radius: 12px; background: var(--bb-fade); }
.bb-product-sheet-image.is-empty { display: grid; place-items: center; color: var(--bb-muted-label); font-size: 12px; }
.bb-product-sheet-qty { display: flex; align-items: center; flex-wrap: wrap; gap: 8px; color: var(--bb-text); font-size: 13px; font-weight: 500; }
.bb-product-sheet-qty > button { display: inline-grid; width: 30px; height: 30px; padding: 0; place-items: center; border: 1px solid var(--bb-gray-400); border-radius: 8px; background: #fff; color: var(--bb-text); font: inherit; font-size: 16px; cursor: pointer; }
.bb-product-sheet-qty > button:disabled { opacity: .5; cursor: not-allowed; }
.bb-product-sheet-qty > strong { min-width: 20px; text-align: center; }
.bb-product-sheet-qty > small { color: var(--bb-muted-label); font-size: 12px; font-weight: 400; }
.bb-product-sheet-body .bb-options { margin: 0; padding-top: 0; border-top: 0; }
.bb-product-sheet-footer { display: flex; justify-content: flex-end; gap: 8px; padding: 16px 24px; border-top: 1px solid var(--bb-gray-300); }
@media (max-width: 640px) {
  .bb-product-sheet { top: auto; right: 0; bottom: 0; left: 0; width: 100%; max-width: none; max-height: calc(100vh - 16px); border-radius: 16px 16px 0 0; }
  .bb-product-sheet-header, .bb-product-sheet-body, .bb-product-sheet-footer { padding-right: 20px; padding-left: 20px; }
}
