/* Buddy Public Booking · FULL design - Step 7: Confirmation.
 * Two-column layout: collapsible review cards on the left, a sticky Checkout
 * sidebar (Plan Price / Transport fee / Total + actions) on the right. */

.bb-sum-grid { display: grid; grid-template-columns: minmax(0, 1fr) 340px; gap: 24px; align-items: start; }
.bb-sum-main { display: flex; flex-direction: column; gap: 16px; min-width: 0; }

/* Collapsible review cards */
.bb-sum-card { border: 1px solid var(--bb-gray-300); border-radius: 12px; background: #fff; overflow: hidden; box-shadow: 0 1px 2px rgba(25,42,70,.03); }
.bb-sum-card-head {
  display: flex; align-items: center; justify-content: space-between; gap: 12px;
  padding: 12px 24px; cursor: pointer; border-bottom: 1px solid var(--bb-gray-300);
}
.bb-sum-card-title { font-size: 16px; font-weight: 600; }
.bb-sum-card-actions { display: inline-flex; align-items: center; gap: 8px; }
.bb-sum-chevron { color: var(--bb-gray-800); display: inline-flex; transition: transform 0.15s ease; }
.bb-sum-card.is-collapsed .bb-sum-card-head { border-bottom: none; }
.bb-sum-card.is-collapsed .bb-sum-card-body { display: none; }
.bb-sum-card.is-collapsed .bb-sum-chevron { transform: rotate(-90deg); }
.bb-sum-card-body { padding: 16px 24px 24px; }

/* Label / value rows (two per line) */
.bb-sum-rows { display: grid; grid-template-columns: 1fr 1fr; gap: 16px 20px; }
.bb-sum-row { min-width: 0; }
.bb-sum-k { font-size: 12px; color: var(--bb-gray-800); margin-bottom: 3px; }
.bb-sum-v { font-size: 15px; color: var(--bb-text); word-break: break-word; }
.bb-wrap button.bb-sum-edit {
  display: inline-flex; align-items: center; gap: 6px; min-height: 30px; padding: 0 10px;
  border: 0; border-radius: 8px; background: transparent; color: var(--bb-text);
  font-family: inherit; font-size: 13px; font-weight: 500; cursor: pointer;
}
.bb-wrap button.bb-sum-edit:hover { background: var(--bb-fade); }
.bb-wrap button.bb-sum-edit:focus-visible { outline: 2px solid var(--bb-purple); outline-offset: 2px; }
.bb-sum-edit-icon { display: inline-flex; color: var(--bb-gray-800); }

/* Selected items */
.bb-sum-items { display: flex; flex-direction: column; }
.bb-sum-item { display: flex; align-items: center; gap: 12px; min-width: 0; padding: 8px 0; }
.bb-sum-item + .bb-sum-item { border-top: 1px solid var(--bb-gray-300); }
.bb-sum-item-img { width: 48px; height: 48px; flex: 0 0 48px; object-fit: contain; border-radius: 8px; background: var(--bb-fade); }
.bb-sum-item-info { min-width: 0; }
.bb-sum-item-title { font-size: 14px; font-weight: 500; margin-bottom: 2px; }
.bb-sum-item-cats { font-size: 12px; color: var(--bb-gray-800); line-height: 16px; margin-bottom: 2px; }
.bb-sum-item-qty { font-size: 13px; color: var(--bb-gray-800); }
.bb-sum-item-kind { display: inline-flex; height: 20px; align-items: center; margin-left: auto; padding: 0 8px; border-radius: 999px; background: var(--bb-fade-100); color: var(--bb-text); font-size: 12px; line-height: 16px; font-weight: 500; white-space: nowrap; }
.bb-sum-empty { margin: 0; padding: 8px 0; color: var(--bb-muted-label); font-size: 13px; line-height: 18px; }

/* Selected plan description */
.bb-sum-plan-desc { margin-top: 14px; font-size: 13px; color: var(--bb-gray-800); line-height: 1.6; }
.bb-sum-plan-desc ul { margin: 8px 0 0; padding-left: 18px; }
.bb-sum-plan-desc li { margin-bottom: 6px; }

/* Checkout sidebar */
.bb-sum-side { position: sticky; top: 100px; }
.bb-checkout { border: 1px solid var(--bb-gray-300); border-radius: 12px; background: #fff; padding: 24px; box-shadow: 0 1px 2px rgba(16,24,40,.04); }
.bb-checkout-title { font-size: 18px; line-height: 28px; font-weight: 600; margin-bottom: 16px; }
.bb-checkout-summary { display: flex; flex-direction: column; gap: 12px; margin: 0; }
.bb-checkout-summary > div { display: flex; justify-content: space-between; gap: 12px; }
.bb-checkout-summary dt { color: var(--bb-muted-label); font-size: 13px; line-height: 18px; }
.bb-checkout-summary dd { margin: 0; color: var(--bb-text); font-size: 13px; line-height: 18px; font-weight: 500; text-align: right; }
.bb-checkout-summary + .bb-checkout-row { margin-top: 16px; padding-top: 16px; border-top: 1px solid var(--bb-gray-300); }
.bb-checkout-row { display: flex; justify-content: space-between; font-size: 14px; padding: 6px 0; }
.bb-checkout-row span:last-child { font-weight: 600; }
.bb-checkout-total {
  display: flex; justify-content: space-between; align-items: baseline;
  font-size: 20px; font-weight: 700;
  border-top: 1px solid var(--bb-gray-300); margin-top: 10px; padding-top: 16px;
}
.bb-checkout-actions { display: flex; gap: 12px; margin-top: 18px; }
.bb-checkout-actions .bb-btn { flex: 1; }
.bb-checkout-help { margin: 12px 0 0; color: var(--bb-muted-label); font-size: 12px; line-height: 16px; text-align: center; }
.bb-checkout-incomplete { color: var(--bb-danger); font-weight: 500; }
.bb-checkout-extra { display: inline-flex; align-items: center; justify-content: center; gap: 8px; margin-top: 16px; background: #00884b !important; background: oklch(0.55 .14 155) !important; border-color: #00884b !important; border-color: oklch(0.55 .14 155) !important; color: #fff !important; }
.editor-content-wrp .bb-wrap .bb-checkout-help + .bb-checkout-extra { margin-top: 16px !important; }
.bb-checkout-extra:hover:not(:disabled) { background: #00733e !important; background: oklch(0.49 .14 155) !important; border-color: #00733e !important; border-color: oklch(0.49 .14 155) !important; }
.bb-checkout-extra-icon { display: inline-flex; }

/* The wizard shell normally clips its rounded frame. On the desktop review
 * step, that overflow boundary would make the sticky summary track a
 * non-scrolling ancestor instead of the page. Lift it only for this grid. */
@media (min-width: 981px) {
  /* Some host themes clip one-column sections. Allow the review sidebar to
   * stick to the page viewport only while this booking grid is present. */
  .one-column-section:has(.bb-wrap .bb-sum-grid) { overflow: visible; }
  .bb-shell:has(.bb-sum-grid),
  .bb-shell:has(.bb-sum-grid) .bb-content { overflow: visible; }
}

/* Responsive: stack the sidebar below the review cards */
@media (max-width: 980px) {
  .bb-sum-grid { grid-template-columns: 1fr; }
  .bb-sum-side { position: static; }
}
@media (max-width: 620px) {
  .bb-sum-rows, .bb-sum-items { grid-template-columns: 1fr; }
}
