/*
 * Blocks with no Heedlight original (src/render/blocks/extra.ts): Profile, Before and after,
 * Price list, Hours, Service areas, Newsletter, Posts and Social. Uses only the theme
 * variables (--site-*, --d-*) and the shared bp- pieces from sites.css.
 */

/* A note only the editor shows, where a block has nothing to show yet. */
.bp-editor-hint {
  margin: 0;
  padding: 1rem 1.25rem;
  font-size: 0.95rem;
  text-align: center;
  border: 1px dashed color-mix(in srgb, currentColor 30%, transparent);
  border-radius: var(--site-box-radius, 6px);
  opacity: 0.75;
}

/* ---- Profile: a personal page's opening ---- */

.bp-profile { text-align: center; }

.bp-profile__inner {
  max-width: 35rem;
  margin-inline: auto;
}

.bp-profile__photo {
  width: clamp(7rem, 30vw, 9.5rem);
  aspect-ratio: 1;
  margin: 0 auto 1.25rem;
  overflow: hidden;
  background: color-mix(in srgb, currentColor 8%, transparent);
  box-shadow: 0 0 0 4px var(--d-card, #fff), 0 10px 30px rgb(12 22 32 / 0.12);

  img { display: block; width: 100%; height: 100%; object-fit: cover; }
  .bp-placeholder { display: grid; place-items: center; height: 100%; padding: 0.5rem; font-size: 0.8rem; }
}

.bp-profile__photo--circle { border-radius: 50%; }
.bp-profile__photo--rounded { border-radius: var(--d-image-radius, 22%); }

.bp-profile__name {
  margin: 0;
  font-size: clamp(2rem, 6vw, 2.75rem);
  line-height: 1.1;
  overflow-wrap: anywhere;
}

.bp-profile__tagline {
  margin: 0.5rem 0 0;
  font-size: 1.1rem;
  opacity: 0.8;
}

.bp-profile__bio {
  margin-top: 1rem;
  font-size: 1rem;
  line-height: 1.65;

  p { margin: 0 0 0.75rem; }
  p:last-child { margin-bottom: 0; }
}

.bp-profile__links {
  display: grid;
  gap: 0.75rem;
  margin: 2rem 0 0;
  padding: 0;
  list-style: none;
}

.bp-profile__link {
  display: flex;
  align-items: center;
  justify-content: center;
  min-height: 3.25rem;
  padding: 0.8rem 1.25rem;
  border-radius: var(--site-radius, 6px);
  color: inherit;
  font-weight: 600;
  text-align: center;
  text-decoration: none;
  overflow-wrap: anywhere;
  background: color-mix(in srgb, var(--d-card, #fff) 70%, transparent);
  box-shadow: inset 0 0 0 1.5px color-mix(in srgb, currentColor 30%, transparent);
  transition: transform 0.15s ease, box-shadow 0.15s ease, background-color 0.15s ease;

  &:hover { transform: translateY(-1px); box-shadow: inset 0 0 0 1.5px currentColor; }
  &:focus-visible { outline: 3px solid var(--site-accent, #9a7344); outline-offset: 3px; }
}

.bp-profile__link--featured {
  color: #fff;
  background: var(--site-button, var(--site-accent, #9a7344));
  box-shadow: 0 6px 18px color-mix(in srgb, var(--site-button, var(--site-accent, #9a7344)) 30%, transparent);

  &:hover { box-shadow: 0 8px 22px color-mix(in srgb, var(--site-button, var(--site-accent, #9a7344)) 40%, transparent); }
}

:is(.bp-bg--brand, .bp-bg--dark) .bp-profile__link:not(.bp-profile__link--featured) { background: rgb(255 255 255 / 0.06); }
:is(.bp-bg--brand, .bp-bg--dark) .bp-profile__link--featured { background: var(--site-accent, #9a7344); }
:is(.bp-bg--brand, .bp-bg--dark) .bp-profile__photo { box-shadow: 0 0 0 4px rgb(255 255 255 / 0.15); }

@media (prefers-reduced-motion: reduce) {
  .bp-profile__link { transition: none; &:hover { transform: none; } }
}

/* ---- Before and after ---- */

.bp-compares {
  display: grid;
  gap: 2.5rem;
}

.bp-compare { margin: 0; }

.bp-compare__caption {
  margin: 0 0 0.75rem;
  font-size: 1.1rem;
  font-weight: 600;
}

.bp-compare__pair {
  display: grid;
  gap: 0.75rem;

  @media (min-width: 640px) { grid-template-columns: 1fr 1fr; gap: 1rem; }
}

.bp-compare__side {
  position: relative;
  margin: 0;
}

.bp-compare__frame {
  overflow: hidden;
  aspect-ratio: 4 / 3;
  border-radius: var(--d-image-radius, var(--site-box-radius, 6px));
  background: color-mix(in srgb, currentColor 8%, transparent);

  img { display: block; width: 100%; height: 100%; object-fit: cover; }
  .bp-placeholder { display: grid; place-items: center; height: 100%; font-size: 0.9rem; }
}

.bp-compare__label {
  position: absolute;
  inset-block-start: 0.75rem;
  inset-inline-start: 0.75rem;
  padding: 0.3rem 0.75rem;
  border-radius: 999px;
  font-size: 0.75rem;
  font-weight: 600;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  color: #fff;
  background: rgb(12 22 32 / 0.7);
}

.bp-compare__side + .bp-compare__side .bp-compare__label { background: var(--site-accent, #9a7344); }

/* ---- Price list ---- */

.bp-prices { display: grid; gap: 2.5rem; }

.bp-prices__title {
  margin: 0 0 0.75rem;
  padding-bottom: 0.6rem;
  font-family: var(--site-heading-font);
  font-size: 1.35rem;
  border-bottom: 1px solid var(--d-line, color-mix(in srgb, currentColor 18%, transparent));
}

.bp-prices__rows {
  margin: 0;
  padding: 0;
  list-style: none;
}

.bp-price { padding: 0.7rem 0; }
.bp-price + .bp-price { border-top: 1px solid color-mix(in srgb, currentColor 7%, transparent); }

.bp-price__line {
  display: flex;
  align-items: baseline;
  gap: 0.5rem;
}

.bp-price__name {
  font-weight: 600;
  min-width: 0;
  overflow-wrap: anywhere;
}

.bp-price__leader {
  flex: 1 1 1.5rem;
  min-width: 1.5rem;
  border-bottom: 2px dotted color-mix(in srgb, currentColor 35%, transparent);
  transform: translateY(-0.25em);
}

.bp-price__amount {
  flex: none;
  max-width: 45%;
  font-family: var(--site-heading-font);
  font-weight: 600;
  font-variant-numeric: tabular-nums;
  text-align: end;
  color: var(--site-accent, #9a7344);
}

.bp-price__detail {
  margin: 0.2rem 0 0;
  max-width: 34rem;
  font-size: 0.92rem;
  line-height: 1.5;
  opacity: 0.72;
}

:is(.bp-bg--brand, .bp-bg--dark) .bp-price__amount { color: color-mix(in srgb, var(--site-accent, #9a7344) 65%, white); }
.bp-align--center .bp-prices { text-align: start; }

/* ---- Hours ---- */

.bp-hours {
  margin: 0;
  padding: 0.5rem 1.5rem;
  border-radius: var(--d-card-radius, 14px);
  background: var(--d-card, #fff);
  color: var(--site-primary, #16324f);
}

.bp-hours__row {
  display: flex;
  flex-wrap: wrap;
  justify-content: space-between;
  gap: 0.25rem 1.5rem;
  padding: 0.85rem 0;
  text-align: start;

  & + & { border-top: 1px solid var(--d-line, color-mix(in srgb, currentColor 12%, transparent)); }

  dt { font-weight: 600; }
  dd { margin: 0; font-variant-numeric: tabular-nums; text-align: end; margin-inline-start: auto; }
}

.bp-hours__row--closed dd { opacity: 0.6; }

.bp-hours__note {
  display: flex;
  gap: 0.6rem;
  margin-top: 1.25rem;
  font-size: 0.95rem;
  line-height: 1.55;
  text-align: start;

  svg { flex: none; margin-top: 0.15rem; color: var(--site-accent, #9a7344); }
  p { margin: 0 0 0.5rem; }
  p:last-child { margin-bottom: 0; }
}

:is(.bp-bg--brand, .bp-bg--dark) .bp-hours {
  color: inherit;
  background: rgb(255 255 255 / 0.06);
  border: 1px solid rgb(255 255 255 / 0.12);
}

:is(.bp-bg--brand, .bp-bg--dark) .bp-hours__note svg { color: color-mix(in srgb, var(--site-accent, #9a7344) 65%, white); }

/* ---- Service areas ---- */

.bp-areas {
  margin: 0;
  padding: 0;
  list-style: none;
}

.bp-area {
  display: flex;
  align-items: center;
  gap: 0.45rem;
  min-width: 0;

  svg { flex: none; color: var(--site-accent, #9a7344); }
  span { overflow-wrap: anywhere; }
}

.bp-areas--chips {
  display: flex;
  flex-wrap: wrap;
  gap: 0.6rem;

  .bp-area {
    padding: 0.55rem 1rem;
    border-radius: 999px;
    background: var(--d-card, #fff);
    color: var(--site-primary, #16324f);
    box-shadow: inset 0 0 0 1px color-mix(in srgb, var(--site-primary, #16324f) 12%, transparent);
  }
}

.bp-areas--columns {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(min(11rem, 100%), 1fr));
  gap: 0.6rem 1.5rem;

  .bp-area { padding: 0.35rem 0; border-bottom: 1px solid var(--d-line, color-mix(in srgb, currentColor 10%, transparent)); }
}

.bp-align--center .bp-areas--chips { justify-content: center; }
.bp-align--right .bp-areas--chips { justify-content: flex-end; }
.bp-service-areas .bp-actions { margin-top: 2rem; }

:is(.bp-bg--brand, .bp-bg--dark) {
  .bp-areas--chips .bp-area { color: inherit; background: rgb(255 255 255 / 0.08); box-shadow: inset 0 0 0 1px rgb(255 255 255 / 0.14); }
  .bp-area svg { color: color-mix(in srgb, var(--site-accent, #9a7344) 65%, white); }
}

/* ---- Newsletter ---- */

.bp-newsletter { text-align: center; }
.bp-newsletter .bp-head { margin-inline: auto; margin-bottom: 1rem; }

.bp-newsletter__body {
  max-width: 34rem;
  margin: 0 auto 1.5rem;
  font-size: 1.05rem;
  line-height: 1.65;
  opacity: 0.85;

  p { margin: 0 0 0.75rem; }
  p:last-child { margin-bottom: 0; }
}

.bp-newsletter__form {
  max-width: 30rem;
  margin-inline: auto;

  .bp-honey { position: absolute; width: 1px; height: 1px; overflow: hidden; clip-path: inset(50%); white-space: nowrap; }
  .cf-turnstile { margin-bottom: 0.75rem; }
}

.bp-newsletter__row {
  display: flex;
  flex-wrap: wrap;
  gap: 0.6rem;
}

/* Read by screen readers; the field's placeholder and button say what it is to everyone else. */
.bp-newsletter__label {
  position: absolute;
  width: 1px;
  height: 1px;
  overflow: hidden;
  clip-path: inset(50%);
  white-space: nowrap;
}

.bp-newsletter__input {
  flex: 1 1 14rem;
  min-width: 0;
  min-height: 3rem;
  padding: 0.7rem 0.95rem;
  font: inherit;
  color: var(--site-primary, #16324f);
  background: var(--d-input-fill, #fff);
  border: 1px solid var(--d-line, color-mix(in srgb, var(--site-primary, #16324f) 20%, white));
  border-radius: var(--d-input-radius, var(--site-box-radius, 6px));

  &:focus-visible { outline: 3px solid color-mix(in srgb, var(--site-accent, #9a7344) 55%, transparent); outline-offset: 1px; }
}

.bp-newsletter__button {
  flex: 1 0 auto;
  min-height: 3rem;

  @media (min-width: 480px) { flex-grow: 0; }
}

.bp-newsletter__thanks {
  max-width: 30rem;
  margin: 0 auto;
  justify-content: center;
  color: var(--site-primary, #16324f);

  &[hidden] { display: none; }
}

:is(.bp-bg--brand, .bp-bg--dark) .bp-newsletter__input { border-color: transparent; }

/* ---- Latest posts (cards use .bp-post-card from sites.css) ---- */

.bp-posts-block .bp-post-card { transition: transform 0.15s ease, box-shadow 0.15s ease; }
.bp-posts-block .bp-post-card:hover { transform: translateY(-2px); box-shadow: 0 10px 28px rgb(12 22 32 / 0.1); }
.bp-posts-block .bp-post-card__link:focus-visible { outline: 3px solid var(--site-accent, #9a7344); outline-offset: 3px; }
.bp-posts-block .bp-post-card time { display: block; }
.bp-posts-block .bp-post-card h3 { overflow-wrap: anywhere; }
.bp-posts__all { margin: 2rem 0 0; text-align: center; }
.bp-posts__all .bp-btn { min-height: 2.75rem; }

:is(.bp-bg--brand, .bp-bg--dark) .bp-post-card .bp-text-link { color: var(--site-accent, #9a7344); }

@media (prefers-reduced-motion: reduce) {
  .bp-posts-block .bp-post-card { transition: none; }
  .bp-posts-block .bp-post-card:hover { transform: none; }
}

/* ---- Social links ---- */

.bp-social-block { text-align: center; }
.bp-social-block__title { margin-bottom: 1.25rem; }

.bp-social {
  display: flex;
  flex-wrap: wrap;
  justify-content: center;
  gap: 0.75rem;
  margin: 0;
  padding: 0;
  list-style: none;

  a {
    color: inherit;
    text-decoration: none;
    transition: background-color 0.15s ease, color 0.15s ease, transform 0.15s ease;

    &:focus-visible { outline: 3px solid var(--site-accent, #9a7344); outline-offset: 3px; }
  }
}

.bp-align--left .bp-social { justify-content: flex-start; }
.bp-align--right .bp-social { justify-content: flex-end; }

.bp-social__icon {
  display: grid;
  place-items: center;
  width: 3rem;
  height: 3rem;
  border-radius: 50%;
  box-shadow: inset 0 0 0 1px color-mix(in srgb, currentColor 25%, transparent);

  &:hover { color: #fff; background: var(--site-button, var(--site-accent, #9a7344)); box-shadow: none; transform: translateY(-1px); }
}

.bp-social__button {
  display: inline-flex;
  align-items: center;
  gap: 0.55rem;
  min-height: 2.75rem;
  padding: 0.6rem 1.15rem;
  border-radius: var(--site-radius, 6px);
  font-weight: 600;
  box-shadow: inset 0 0 0 1px color-mix(in srgb, currentColor 30%, transparent);

  &:hover { color: #fff; background: var(--site-button, var(--site-accent, #9a7344)); box-shadow: none; }
}

:is(.bp-bg--brand, .bp-bg--dark) :is(.bp-social__icon, .bp-social__button):hover { color: var(--site-primary, #16324f); background: var(--d-on-dark, #f7f4ef); }

@media (prefers-reduced-motion: reduce) {
  .bp-social a { transition: none; }
  .bp-social__icon:hover { transform: none; }
}

/* ---- Booking ---- */
.bp-booking select { width: 100%; font: inherit; padding: 12px 14px; border-radius: var(--bp-radius-input, 10px); border: 1px solid var(--bp-line, rgba(0, 0, 0, 0.18)); background: var(--bp-surface, #fff); color: inherit; min-height: 48px; }
.bp-booking select:disabled { opacity: 0.6; }
.bp-booking .bp-option { display: flex; align-items: center; gap: 10px; flex-wrap: wrap; }
.bp-booking__meta { margin-left: auto; opacity: 0.7; font-size: 0.92em; }
