/*
 * Booking & Commerce element styles.
 *
 * Every color/font references the site's --site-* token chain with a
 * neutral fallback so the elements work on any theme. Renderers never
 * inject hex values; controls bind via --el-* / --site-* / element-local
 * vars (e.g. --slot-booker-accent).
 */

/* ───────────────────────── Slot Booker ─────────────────────── */

.el-slot-booker {
  display: flex;
  flex-direction: column;
  gap: 16px;
  color: var(--site-text, inherit);
}

.el-slot-booker__days {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(min(180px, calc(50% - 8px)), 1fr));
  gap: 16px;
}

.el-slot-booker__day {
  display: flex;
  flex-direction: column;
  gap: 8px;
  padding: 12px;
  background: var(--slot-booker-slot-bg, var(--site-background, transparent));
  border-radius: var(--slot-booker-slot-radius, 8px);
  border: 1px solid var(--site-border, transparent);
}

.el-slot-booker__day-label {
  margin: 0;
  font-size: 13px;
  font-weight: 600;
  color: var(--site-muted-text, currentColor);
}

.el-slot-booker__slots {
  list-style: none;
  margin: 0;
  padding: 0;
  display: flex;
  flex-wrap: wrap;
  gap: 6px;
}

.el-slot-booker__slot {
  appearance: none;
  border: 1px solid var(--slot-booker-accent, var(--site-accent, currentColor));
  background: transparent;
  color: var(--slot-booker-accent, var(--site-accent, inherit));
  font: inherit;
  padding: 6px 10px;
  border-radius: var(--slot-booker-slot-radius, 8px);
  cursor: pointer;
  min-height: 32px;
}

.el-slot-booker__slot:hover,
.el-slot-booker__slot:focus-visible {
  background: var(--slot-booker-accent, var(--site-accent, currentColor));
  color: var(--site-accent-foreground, var(--site-background, currentColor));
}

.el-slot-booker__empty {
  font-size: 12px;
  color: var(--site-muted-text, currentColor);
  margin: 0;
}

.el-slot-booker--form,
.el-slot-booker--confirmed {
  display: flex;
  flex-direction: column;
  gap: 12px;
  max-width: min(520px, 100%);
}

.el-slot-booker__label {
  display: flex;
  flex-direction: column;
  gap: 4px;
  font-size: 13px;
  font-weight: 500;
}

.el-slot-booker__label input,
.el-slot-booker__label textarea {
  font: inherit;
  padding: 8px 10px;
  border-radius: 8px;
  border: 1px solid var(--site-border, transparent);
  background: var(--site-input-bg, var(--site-background, transparent));
  color: inherit;
  min-height: 38px;
}

.el-slot-booker__actions {
  display: flex;
  gap: 8px;
  justify-content: flex-end;
}

.el-slot-booker__back,
.el-slot-booker__submit,
.el-slot-booker__ics {
  appearance: none;
  font: inherit;
  border-radius: 8px;
  padding: 8px 16px;
  cursor: pointer;
  min-height: 38px;
}

.el-slot-booker__back {
  background: transparent;
  border: 1px solid var(--site-border, currentColor);
  color: inherit;
}

.el-slot-booker__submit,
.el-slot-booker__ics {
  background: var(--slot-booker-accent, var(--site-accent, currentColor));
  color: var(--site-accent-foreground, currentColor);
  border: 0;
}

.el-slot-booker__error {
  color: var(--site-danger, currentColor);
  font-size: 13px;
  margin: 0;
}

/* ─────────────────────── Reservation Form ─────────────────── */

.el-reservation-form {
  display: flex;
  flex-direction: column;
  gap: 12px;
  max-width: min(640px, 100%);
}

.el-reservation-form__title {
  margin: 0;
  font-size: clamp(20px, 3vw, 28px);
  font-weight: 700;
}

.el-reservation-form__grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(min(140px, 100%), 1fr));
  gap: 12px;
}

.el-reservation-form__label {
  display: flex;
  flex-direction: column;
  gap: 4px;
  font-size: 13px;
  font-weight: 500;
}

.el-reservation-form__label input,
.el-reservation-form__label select,
.el-reservation-form__label textarea {
  font: inherit;
  padding: 8px 10px;
  border-radius: 8px;
  border: 1px solid var(--site-border, transparent);
  background: var(--site-input-bg, var(--site-background, transparent));
  color: inherit;
  min-height: 38px;
}

.el-reservation-form__submit {
  appearance: none;
  font: inherit;
  border: 0;
  border-radius: 8px;
  padding: 10px 18px;
  background: var(--reservation-accent, var(--site-accent, currentColor));
  color: var(--site-accent-foreground, currentColor);
  cursor: pointer;
  min-height: 44px;
  align-self: flex-start;
}

.el-reservation-form__error {
  color: var(--site-danger, currentColor);
  font-size: 13px;
  margin: 0;
}

/* ───────────────────────── Hours Status ────────────────────── */

.el-hours-status {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  --el-padding-default: 4px 10px;
  font-size: 13px;
  font-weight: 600;
  border-radius: 999px;
  background: var(--el-bg, var(--site-surface, transparent));
  color: inherit;
}

.el-hours-status__dot {
  display: inline-block;
  width: 8px;
  height: 8px;
  border-radius: 50%;
  background: currentColor;
}

.el-hours-status--open {
  color: var(--hours-status-open, var(--site-success, currentColor));
}
.el-hours-status--closing-soon {
  color: var(--hours-status-closing-soon, var(--site-warning, currentColor));
}
.el-hours-status--closed {
  color: var(--hours-status-closed, var(--site-danger, currentColor));
}

.el-hours-status--inline {
  background: transparent;
  padding: 0;
}

.el-hours-status--banner {
  width: 100%;
  justify-content: center;
  padding: 8px 12px;
  border-radius: 8px;
}

/* ─────────────────── Product Configurator ───────────────────── */

.el-product-configurator {
  display: grid;
  grid-template-columns: minmax(min(320px, 100%), 1fr) minmax(min(280px, 100%), 1fr);
  gap: 24px;
}

@container site style(--site-bp: mobile) {
  .el-product-configurator {
    grid-template-columns: 1fr;
  }
}
@media (max-width: 768px) {
  .el-product-configurator {
    grid-template-columns: 1fr;
  }
}

.el-product-configurator__media {
  background: var(--site-surface, transparent);
  border-radius: 16px;
  overflow: hidden;
  aspect-ratio: 1 / 1;
  display: flex;
  align-items: center;
  justify-content: center;
}

.el-product-configurator__img {
  width: 100%;
  height: 100%;
  object-fit: cover;
}

.el-product-configurator__placeholder {
  width: 100%;
  height: 100%;
  background: var(--site-surface, transparent);
}

.el-product-configurator__body {
  display: flex;
  flex-direction: column;
  gap: 16px;
}

.el-product-configurator__name {
  margin: 0;
  font-size: clamp(20px, 2.5vw, 28px);
  font-weight: 700;
}

.el-product-configurator__price {
  margin: 0;
  font-size: 22px;
  font-weight: 700;
  color: var(--product-config-price, var(--site-accent, currentColor));
}

.el-product-configurator__group {
  display: flex;
  flex-direction: column;
  gap: 6px;
}

.el-product-configurator__group-label {
  font-size: 12px;
  font-weight: 600;
  text-transform: uppercase;
  letter-spacing: 0.04em;
  color: var(--site-muted-text, currentColor);
}

.el-product-configurator__variants {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
}

.el-product-configurator__chip {
  appearance: none;
  font: inherit;
  padding: 6px 12px;
  border-radius: 999px;
  border: 1px solid var(--site-border, currentColor);
  background: transparent;
  color: inherit;
  cursor: pointer;
  min-height: 36px;
}

.el-product-configurator__chip--active {
  background: var(--product-config-accent, var(--site-accent, currentColor));
  color: var(--site-accent-foreground, currentColor);
  border-color: var(--product-config-accent, var(--site-accent, currentColor));
}

.el-product-configurator__cta {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  align-self: flex-start;
  padding: 12px 20px;
  background: var(--product-config-accent, var(--site-accent, currentColor));
  color: var(--site-accent-foreground, currentColor);
  border-radius: 8px;
  text-decoration: none;
  font-weight: 600;
  min-height: 44px;
}

/* ─────────────────────── Model Viewer ─────────────────────── */

.el-model-viewer {
  position: relative;
  background: var(--el-bg, var(--site-surface, transparent));
  border-radius: 16px;
  overflow: hidden;
  width: 100%;
}

.el-model-viewer--empty {
  display: flex;
  align-items: center;
  justify-content: center;
  color: var(--site-muted-text, currentColor);
}

.el-model-viewer__skeleton {
  position: absolute;
  inset: 0;
  display: flex;
  align-items: center;
  justify-content: center;
}

.el-model-viewer__poster {
  width: 100%;
  height: 100%;
  object-fit: cover;
}

/* ─────────────────────── Sticky Cart Bar ──────────────────── */

.el-sticky-cart-bar {
  position: fixed;
  left: 0;
  right: 0;
  bottom: 0;
  z-index: 100;
  display: flex;
  align-items: center;
  gap: 12px;
  --el-padding-default: 10px 16px;
  background: var(--el-bg, var(--site-surface, currentColor));
  color: var(--site-surface-foreground, inherit);
  box-shadow: 0 -4px 16px rgba(0, 0, 0, 0.08);
  transform: translateY(100%);
  transition: transform 220ms ease;
}

.el-sticky-cart-bar--in {
  transform: translateY(0);
}

.el-sticky-cart-bar--floating-card {
  left: auto;
  right: 16px;
  bottom: 16px;
  max-width: 360px;
  border-radius: 16px;
}

.el-sticky-cart-bar__img {
  width: 44px;
  height: 44px;
  object-fit: cover;
  border-radius: 8px;
}

.el-sticky-cart-bar__body {
  flex: 1;
  min-width: 0;
}

.el-sticky-cart-bar__name,
.el-sticky-cart-bar__price {
  margin: 0;
  font-size: 13px;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.el-sticky-cart-bar__price {
  font-weight: 700;
  color: var(--sticky-cart-accent, var(--site-accent, currentColor));
}

.el-sticky-cart-bar__cta {
  appearance: none;
  font: inherit;
  font-weight: 600;
  padding: 10px 16px;
  border-radius: 8px;
  background: var(--sticky-cart-accent, var(--site-accent, currentColor));
  color: var(--site-accent-foreground, currentColor);
  text-decoration: none;
  min-height: 40px;
  display: inline-flex;
  align-items: center;
  cursor: pointer;
}

.el-sticky-cart-bar__dismiss {
  appearance: none;
  background: transparent;
  border: 0;
  color: inherit;
  font-size: 22px;
  cursor: pointer;
  padding: 4px 8px;
}

/* ─────────────────── Reviews Aggregator ────────────────────── */

.el-reviews-aggregator,
.el-google-reviews {
  display: flex;
  flex-direction: column;
  gap: 16px;
}

.el-reviews-aggregator__title,
.el-google-reviews__title {
  margin: 0;
  font-size: clamp(18px, 2.4vw, 26px);
  font-weight: 700;
}

.el-reviews-aggregator__summary,
.el-google-reviews__summary {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 16px;
  padding: 12px;
  background: var(--reviews-card-bg, var(--google-reviews-card-bg, var(--site-surface, transparent)));
  border-radius: 12px;
}

.el-reviews-aggregator__avg,
.el-google-reviews__summary {
  display: flex;
  align-items: center;
  gap: 8px;
}

.el-reviews-aggregator__avg-num,
.el-google-reviews__avg-num {
  font-size: 28px;
  font-weight: 700;
}

.el-reviews-aggregator__total,
.el-google-reviews__total {
  font-size: 13px;
  color: var(--site-muted-text, currentColor);
}

.el-reviews-aggregator__bars {
  list-style: none;
  margin: 0;
  padding: 0;
  display: grid;
  gap: 4px;
  min-width: 180px;
  flex: 1;
}

.el-reviews-aggregator__bar-row {
  display: grid;
  grid-template-columns: auto 1fr auto;
  align-items: center;
  gap: 8px;
  font-size: 12px;
}

.el-reviews-aggregator__bar {
  height: 6px;
  background: var(--site-border, transparent);
  border-radius: 3px;
  overflow: hidden;
}

.el-reviews-aggregator__bar-fill {
  display: block;
  height: 100%;
  background: var(--reviews-star-color, var(--site-accent, currentColor));
}

.el-reviews-aggregator__list,
.el-google-reviews__list {
  list-style: none;
  margin: 0;
  padding: 0;
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(min(280px, 100%), 1fr));
  gap: 12px;
}

.el-reviews-aggregator__card,
.el-google-reviews__card {
  background: var(--reviews-card-bg, var(--google-reviews-card-bg, var(--site-surface, transparent)));
  border-radius: 12px;
  padding: 16px;
  display: flex;
  flex-direction: column;
  gap: 8px;
  border: 1px solid var(--site-border, transparent);
}

.el-reviews-aggregator__card-head,
.el-google-reviews__card-head {
  display: flex;
  align-items: center;
  gap: 8px;
  flex-wrap: wrap;
}

.el-reviews-aggregator__avatar,
.el-google-reviews__avatar {
  width: 28px;
  height: 28px;
  border-radius: 50%;
  object-fit: cover;
}

.el-reviews-aggregator__author,
.el-google-reviews__author {
  font-weight: 600;
  font-size: 13px;
}

.el-reviews-aggregator__body,
.el-google-reviews__body {
  margin: 0;
  font-size: 14px;
  overflow-wrap: break-word;
  word-break: break-word;
}

.el-reviews-aggregator__date,
.el-google-reviews__date {
  margin: 0;
  font-size: 12px;
  color: var(--site-muted-text, currentColor);
}

.el-reviews-aggregator__stars,
.el-google-reviews__stars {
  display: inline-flex;
  gap: 1px;
  color: var(--site-border, currentColor);
}

.el-reviews-aggregator__star--on,
.el-google-reviews__star--on {
  color: var(--reviews-star-color, var(--google-reviews-star, var(--site-accent, currentColor)));
}

.el-reviews-aggregator__more,
.el-google-reviews__write {
  appearance: none;
  font: inherit;
  font-weight: 600;
  padding: 10px 16px;
  border-radius: 8px;
  background: var(--site-accent, currentColor);
  color: var(--site-accent-foreground, currentColor);
  text-decoration: none;
  border: 0;
  cursor: pointer;
  align-self: flex-start;
  min-height: 40px;
  display: inline-flex;
  align-items: center;
}

.el-google-reviews__skeleton {
  display: flex;
  align-items: center;
  gap: 8px;
  font-size: 13px;
  color: var(--site-muted-text, currentColor);
}

.el-reviews-aggregator__error,
.el-google-reviews__error {
  color: var(--site-danger, currentColor);
  font-size: 13px;
  margin: 0;
}
