/* amenities_grid section — flat icon grid of all amenities.
 * Tiles auto-hide if their label is empty (data-slot with no rendered text).
 * Composes with all aesthetics; uses CSS variables for color tokens.
 */

.amenities-grid-section {
  padding-top: 4rem;
  padding-bottom: 4rem;
}

.amenities-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(160px, 1fr));
  gap: 2rem 1.5rem;
  margin-top: 2.5rem;
}

.amenity-tile {
  display: flex;
  flex-direction: column;
  align-items: center;
  text-align: center;
  gap: 0.85rem;
  color: var(--color-ink);
}

.amenity-tile svg {
  width: 32px;
  height: 32px;
  color: var(--color-primary);
  flex-shrink: 0;
}

.amenity-tile span {
  font-size: 0.92rem;
  line-height: 1.3;
  color: var(--color-muted, var(--color-ink));
  letter-spacing: 0.01em;
}

.amenity-tile span:empty {
  display: none;
}

/* Hide the entire tile if its label is empty.
 * Trick: empty :has(:empty) — modern browsers. Fallback: tile renders with
 * just the icon, which is harmless. */
.amenity-tile:has(span:empty) {
  display: none;
}

@media (max-width: 640px) {
  .amenities-grid {
    grid-template-columns: repeat(auto-fit, minmax(120px, 1fr));
    gap: 1.5rem 1rem;
  }
  .amenity-tile svg { width: 26px; height: 26px; }
  .amenity-tile span { font-size: 0.82rem; }
}


/* availability section — month-grid calendar populated at runtime from an
 * iCal feed. Visual structure lifted from villa-jaia (WCAG AA winner) and
 * rebranded onto isla_builder's token system: --color-primary, --color-ink,
 * --color-rule, --color-surface, --color-surface-warm, --color-muted.
 *
 * Only the two LEGEND swatches use semantic colors (a faint primary tint for
 * "available" and a neutral grey for "booked") — kept here as inline color
 * values because they're meaning-bearing UI affordances, not brand color.
 *
 * Auto-hide: when {{t.availability_ical_url}} substitutes to "" the wrap
 * has data-ical-url="" → the whole section hides. Same Phase F pattern as
 * social_proof:has(:empty) and location_map__nearby.
 */

.availability:has(.avail-calendar-wrap[data-ical-url=""]) {
  display: none;
}

.availability {
  padding: clamp(4rem, 8vw, 7rem) clamp(1.5rem, 5vw, 4rem);
  background: var(--color-surface-warm, #f4ebdc);
}

.availability__inner {
  max-width: 72rem;
  margin: 0 auto;
  text-align: center;
}

.availability__lede {
  max-width: 38rem;
  margin: 0.5rem auto clamp(1.75rem, 3vw, 2.5rem);
  color: var(--color-muted, var(--color-ink));
}

/* ── Legend ───────────────────────────────────────────────────────────── */

.avail-legend {
  display: flex;
  gap: 1.5rem;
  justify-content: center;
  flex-wrap: wrap;
  margin: 0 0 clamp(2rem, 3.5vw, 2.75rem);
  font-size: 0.78rem;
  letter-spacing: 0.14em;
  text-transform: uppercase;
  color: var(--color-muted, var(--color-ink));
}

.avail-legend__item {
  display: inline-flex;
  align-items: center;
  gap: 0.5rem;
}

.avail-legend__swatch {
  width: 1rem;
  height: 1rem;
  border-radius: 3px;
  display: inline-block;
  flex-shrink: 0;
}

.avail-legend__swatch--available {
  background: var(--color-surface, #fbfaf6);
  border: 1px solid var(--color-rule, rgba(0, 0, 0, 0.18));
}

.avail-legend__swatch--booked {
  background: #cdc9c5;
  border: 1px solid #a09c98;
}

/* ── Month grid ───────────────────────────────────────────────────────── */

.avail-calendar-wrap {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(17.5rem, 1fr));
  gap: clamp(1.25rem, 2.5vw, 2rem);
  text-align: left;
}

.avail-month {
  background: var(--color-surface, #fbfaf6);
  border: 1px solid var(--color-rule, rgba(0, 0, 0, 0.1));
  border-radius: 6px;
  padding: 1.25rem 1.25rem 1rem;
}

.avail-month__title {
  font-family: var(--font-display, "Cormorant Garamond", serif);
  font-size: 0.78rem;
  letter-spacing: 0.18em;
  text-transform: uppercase;
  color: var(--color-muted, var(--color-ink));
  margin: 0 0 0.9rem;
  text-align: center;
}

.avail-day-row {
  display: grid;
  grid-template-columns: repeat(7, 1fr);
  gap: 3px;
}

.avail-day-row__header {
  font-size: 0.62rem;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  color: var(--color-muted, var(--color-ink));
  opacity: 0.7;
  text-align: center;
  padding: 0.25rem 0 0.4rem;
  font-family: var(--font-body), system-ui, sans-serif;
}

.avail-day-grid {
  display: grid;
  grid-template-columns: repeat(7, 1fr);
  gap: 3px;
}

.avail-day {
  width: 100%;
  aspect-ratio: 1;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 0.78rem;
  border-radius: 4px;
  font-family: var(--font-body), system-ui, sans-serif;
  font-weight: 400;
  border: 1px solid transparent;
  transition: border-color 150ms ease, color 150ms ease;
  font-variant-numeric: tabular-nums;
}

.avail-day--month-pad {
  background: transparent;
  border: none;
}

.avail-day--available {
  background: var(--color-surface, #fbfaf6);
  color: var(--color-ink, #1a1a1a);
  border: 1px solid var(--color-rule, rgba(0, 0, 0, 0.08));
}

.avail-day--available:hover {
  border-color: var(--color-primary);
  color: var(--color-primary);
}

.avail-day--booked {
  background: #cdc9c5;
  color: #6e6a67;
  text-decoration: line-through;
  opacity: 0.85;
  cursor: not-allowed;
}

.avail-day--past {
  background: transparent;
  color: var(--color-muted, var(--color-ink));
  opacity: 0.32;
  cursor: default;
}

/* ── Fallback (fetch failure or no JS) ────────────────────────────────── */

.avail-fallback {
  text-align: center;
  padding: 2rem 1rem;
  margin: 0;
  font-size: 0.95rem;
  color: var(--color-muted, var(--color-ink));
}

.avail-fallback a {
  color: var(--color-primary);
  text-decoration: underline;
  text-underline-offset: 3px;
}

/* ── Mobile ───────────────────────────────────────────────────────────── */

@media (max-width: 768px) {
  .availability {
    padding: clamp(3rem, 9vw, 4.5rem) 1.25rem;
  }
  .avail-calendar-wrap {
    grid-template-columns: 1fr;
    gap: 1.25rem;
  }
  .avail-month {
    padding: 1rem;
  }
  .avail-day {
    font-size: 0.85rem; /* slightly larger so tap targets read clearly */
  }
  .avail-day-row__header {
    font-size: 0.66rem;
  }
  .avail-legend {
    gap: 1rem;
    font-size: 0.72rem;
  }
}

@media (prefers-reduced-motion: reduce) {
  .avail-day,
  .avail-day--available:hover {
    transition: none;
  }
}


/* Book section — multi-channel booking & enquiry block.
 *
 * Structure:
 *   .book           section wrapper (inherits .section spacing per aesthetic)
 *   .book-grid      two-column WhatsApp + Email options on desktop, stacked mobile
 *   .book-option    individual channel card
 *   .enquiry-form   stacked form with split row for check-in/out dates
 *
 * Tokens consumed: --color-primary, --color-primary-dark, --color-ink,
 *   --color-surface, --color-surface-warm, --color-rule, --color-muted,
 *   --motion-fast, --font-body. WhatsApp brand color (#075E54) is the only
 *   hardcoded color — WCAG-AA on white per isla_studio_wcag_aa_pass_recipe.
 *
 * Auto-hide behavior:
 *   .book-option--whatsapp hides itself when book_whatsapp_number is empty,
 *   via :has(.book-whatsapp-number-marker:empty). When both options hide,
 *   the .book-grid collapses to a single column (.book-option--email alone).
 */

.book {
  text-align: center;
}

.book > .lede {
  max-width: 38rem;
  margin-left: auto;
  margin-right: auto;
}

/* ── grid: 2 columns desktop, stacked mobile ── */
.book-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 1.5rem;
  margin: 2.5rem auto 0;
  max-width: 56rem;
  text-align: left;
}

.book-option {
  background: var(--color-surface-warm, var(--color-surface, #fbfaf6));
  border: 1px solid var(--color-rule, rgba(0, 0, 0, 0.08));
  padding: 2.25rem 1.75rem;
  display: flex;
  flex-direction: column;
  gap: 0.85rem;
  transition: border-color var(--motion-fast, 200ms) ease,
              transform var(--motion-fast, 200ms) ease;
}

.book-option:hover {
  border-color: var(--color-primary);
  transform: translateY(-2px);
}

.book-option-title {
  font-family: var(--font-display, serif);
  font-size: clamp(1.2rem, 2vw, 1.45rem);
  color: var(--color-ink);
  margin: 0;
}

.book-option-text {
  font-size: 0.95rem;
  line-height: 1.65;
  color: var(--color-muted, var(--color-ink));
  margin: 0 0 0.5rem;
  flex-grow: 1;
}

/* Hide WhatsApp option entirely when no number set
 * (book_whatsapp_number is rendered into .book-whatsapp-number-marker).
 * Graceful degradation: pre-:has() browsers will show a broken wa.me link;
 * a build-step can additionally strip the block. */
.book-option--whatsapp:has(.book-whatsapp-number-marker:empty) {
  display: none;
}

.book-whatsapp-number-marker {
  display: none;
}

/* ── buttons ── */
.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 0.55rem;
  padding: 0.85rem 1.4rem;
  font-family: var(--font-body, system-ui, sans-serif);
  font-size: 0.85rem;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  text-decoration: none;
  border-radius: 2px;
  border: 1px solid transparent;
  cursor: pointer;
  font-variant-numeric: tabular-nums;
  transition: background var(--motion-fast, 200ms) ease,
              color var(--motion-fast, 200ms) ease,
              border-color var(--motion-fast, 200ms) ease,
              opacity var(--motion-fast, 200ms) ease;
}

.btn:focus-visible {
  outline: 2px solid var(--color-primary);
  outline-offset: 3px;
}

/* WhatsApp dark teal — WCAG AA on white (7.5:1). Do NOT change to #25D366. */
.btn-whatsapp {
  background: #075E54;
  color: #ffffff;
}
.btn-whatsapp:hover {
  background: #064a42;
  color: #ffffff;
  opacity: 1;
}
.btn-whatsapp__icon {
  flex-shrink: 0;
}

.btn-outline-dark {
  background: transparent;
  color: var(--color-ink);
  border-color: var(--color-ink);
}
.btn-outline-dark:hover {
  background: var(--color-ink);
  color: var(--color-surface, #fbfaf6);
  opacity: 1;
}

.btn-terracotta {
  background: var(--color-primary);
  color: var(--color-surface, #ffffff);
}
.btn-terracotta:hover {
  background: var(--color-primary-dark, var(--color-primary));
  color: var(--color-surface, #ffffff);
  opacity: 1;
}

/* ── enquiry form ── */
.enquiry-form-wrap {
  max-width: 40rem;
  margin: 4rem auto 0;
  padding-top: 3rem;
  border-top: 1px solid var(--color-rule, rgba(0, 0, 0, 0.08));
  text-align: left;
}

.book-form-title {
  font-family: var(--font-display, serif);
  font-size: clamp(1.15rem, 2vw, 1.4rem);
  color: var(--color-ink);
  margin: 0 0 0.4rem;
  text-align: center;
}

.book-form-lede {
  text-align: center;
  font-size: 0.95rem;
  color: var(--color-muted, var(--color-ink));
  margin: 0 0 2rem;
}

.enquiry-form {
  display: flex;
  flex-direction: column;
  gap: 1.1rem;
}

.form-row {
  display: flex;
  flex-direction: column;
  gap: 0.4rem;
}

.form-row label {
  font-size: 0.72rem;
  letter-spacing: 0.18em;
  text-transform: uppercase;
  color: var(--color-muted, var(--color-ink));
  font-family: var(--font-body, system-ui, sans-serif);
}

.form-row input,
.form-row select,
.form-row textarea {
  background: var(--color-surface, #fbfaf6);
  border: 1px solid var(--color-rule, rgba(0, 0, 0, 0.12));
  padding: 0.85rem 0.95rem;
  font-family: var(--font-body, system-ui, sans-serif);
  font-size: 1rem;
  color: var(--color-ink);
  border-radius: 2px;
  outline: none;
  -webkit-appearance: none;
  appearance: none;
  font-variant-numeric: tabular-nums;
  transition: border-color var(--motion-fast, 200ms) ease;
  width: 100%;
}

.form-row select {
  background-image: linear-gradient(45deg, transparent 50%, var(--color-ink) 50%),
                    linear-gradient(135deg, var(--color-ink) 50%, transparent 50%);
  background-position: calc(100% - 18px) 50%, calc(100% - 13px) 50%;
  background-size: 5px 5px, 5px 5px;
  background-repeat: no-repeat;
  padding-right: 2.5rem;
}

.form-row textarea {
  resize: vertical;
  min-height: 5rem;
  line-height: 1.5;
}

.form-row input:focus-visible,
.form-row select:focus-visible,
.form-row textarea:focus-visible {
  border-color: var(--color-primary);
  outline: 2px solid var(--color-primary);
  outline-offset: 2px;
}

/* Older browsers without :focus-visible */
.form-row input:focus,
.form-row select:focus,
.form-row textarea:focus {
  border-color: var(--color-primary);
}

/* Date pair: two columns on desktop, stacked on mobile */
.form-row--split {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 1rem;
}

.form-row--split > div {
  display: flex;
  flex-direction: column;
  gap: 0.4rem;
}

.form-submit {
  align-self: flex-start;
  margin-top: 0.5rem;
}

/* Honeypot — hidden off-screen, accessibility-friendly.
 * Bots fill any visible input; humans never see this. */
.hp-field {
  position: absolute;
  left: -9999px;
  width: 1px;
  height: 1px;
  opacity: 0;
  overflow: hidden;
  pointer-events: none;
}

/* ── mobile ── */
@media (max-width: 768px) {
  .book-grid {
    grid-template-columns: 1fr;
    gap: 1rem;
  }

  .book-option {
    padding: 1.75rem 1.4rem;
  }

  .enquiry-form-wrap {
    margin-top: 3rem;
    padding-top: 2.25rem;
  }

  .form-row--split {
    grid-template-columns: 1fr;
    gap: 1.1rem;
  }

  .btn {
    width: 100%;
  }

  .form-submit {
    align-self: stretch;
  }
}


/* collection section — cross-link cards for multi-property Isla Studio clients.
 * Token-driven so every aesthetic flows through. Whole section auto-hides
 * when every card's name is empty (single-property clients render nothing). */

.collection:has(.collection-card__name:not(:empty)) {
  /* keep visible if at least one card has a name */
}
.collection:not(:has(.collection-card__name:not(:empty))) {
  display: none;
}

.collection-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: clamp(1rem, 2vw, 2rem);
  margin-top: clamp(2rem, 4vw, 3rem);
}

.collection-card {
  display: block;
  text-decoration: none;
  color: inherit;
  background: var(--color-surface-warm, #f0ece4);
  transition:
    transform var(--motion-fast, 240ms) var(--motion-ease, ease),
    box-shadow var(--motion-fast, 240ms) var(--motion-ease, ease);
}

/* Per-card auto-hide when the name is empty (CSS :has) */
.collection-card:has(.collection-card__name:empty) {
  display: none;
}

.collection-card:hover {
  transform: translateY(-2px);
  box-shadow: 0 10px 30px -16px rgba(0, 0, 0, 0.25);
}

.collection-card__img {
  margin: 0;
  aspect-ratio: 4 / 5;
  overflow: hidden;
}

.collection-card__img picture,
.collection-card__img img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  object-position: center;
  display: block;
  transition: transform var(--motion-medium, 480ms) var(--motion-ease, ease);
}

.collection-card:hover .collection-card__img img {
  transform: scale(1.03);
}

.collection-card__text {
  padding: clamp(1.25rem, 2.5vw, 2rem);
}

.collection-card__eyebrow {
  font-size: 0.72rem;
  letter-spacing: 0.18em;
  text-transform: uppercase;
  color: var(--color-primary, #8e5527);
  margin: 0 0 0.4rem;
}

.collection-card__name {
  font-family: var(--font-display);
  font-size: clamp(1.2rem, 2vw, 1.5rem);
  line-height: 1.15;
  color: var(--color-ink, #1a1a1a);
  margin: 0 0 0.6rem;
}

.collection-card__desc {
  color: var(--color-muted, #5d574f);
  margin: 0 0 1rem;
  font-size: 0.95rem;
  line-height: 1.55;
}

.collection-card__cta {
  display: inline-block;
  font-size: 0.78rem;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  color: var(--color-primary, #8e5527);
  border-bottom: 1px solid color-mix(in srgb, var(--color-primary, #8e5527) 35%, transparent);
  padding-bottom: 2px;
  transition: border-color var(--motion-fast, 240ms) var(--motion-ease, ease);
}

.collection-card:hover .collection-card__cta {
  border-color: var(--color-primary, #8e5527);
}

@media (max-width: 900px) {
  .collection-grid { grid-template-columns: repeat(2, 1fr); }
  .collection-card:nth-of-type(3) { display: none; }
  .collection:has(.collection-card:nth-of-type(3):not(:has(.collection-card__name:empty))) .collection-card:nth-of-type(3) {
    display: block;
    grid-column: 1 / -1;
    max-width: 60ch;
    margin-inline: auto;
  }
}

@media (max-width: 600px) {
  .collection-grid { grid-template-columns: 1fr; }
  .collection-card:nth-of-type(3) { display: block; }
}

@media (prefers-reduced-motion: reduce) {
  .collection-card,
  .collection-card__img img,
  .collection-card__cta {
    transition: none;
  }
  .collection-card:hover {
    transform: none;
  }
  .collection-card:hover .collection-card__img img {
    transform: none;
  }
}


/* GDPR cookie banner — fixed bottom strip, essential-cookies only.
   Slides in/out via transform on the data-hidden attribute.
   Sits above the WhatsApp FAB on z-index so it doesn't get covered. */
.cookie-banner {
  position: fixed;
  bottom: 0;
  left: 0;
  right: 0;
  z-index: 60;
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  justify-content: space-between;
  gap: 1rem;
  padding: 1rem clamp(1rem, 4vw, 3rem);
  background: var(--color-ink, #1a1a1a);
  color: var(--color-surface, #fbfaf6);
  font-size: 0.875rem;
  line-height: 1.5;
  transition: transform var(--motion-fast, 300ms) ease;
}

.cookie-banner[data-hidden="true"] {
  transform: translateY(100%);
}

.cookie-banner__text {
  margin: 0;
  flex: 1 1 320px;
}

.cookie-banner__actions {
  display: flex;
  gap: 0.75rem;
  align-items: center;
  flex-shrink: 0;
}

.cookie-banner__link {
  color: var(--color-surface, #fbfaf6);
  text-decoration: underline;
}

.cookie-banner__link:hover,
.cookie-banner__link:focus-visible {
  text-decoration: none;
}

/* Mobile: stack vertically, actions row aligns right */
@media (max-width: 640px) {
  .cookie-banner {
    flex-direction: column;
    align-items: flex-start;
    padding: 1rem;
  }
  .cookie-banner__actions {
    width: 100%;
    justify-content: flex-end;
  }
}

@media (prefers-reduced-motion: reduce) {
  .cookie-banner {
    transition: none;
  }
}


/* editorial section — Magnus's signature alternating photo+text rhythm.
 *
 * Two columns on desktop (1fr 1fr — lifted verbatim from
 * villa-magnus-website/css/style.css:298). `.editorial.reverse` flips the
 * visual order via the `direction: rtl` trick: the parent goes RTL so
 * grid columns lay out right-to-left, while each direct child resets to
 * LTR so their own content reads normally. No grid-template-areas, no JS,
 * no duplicated markup.
 *
 * Mobile (<=768px): single column AND .reverse is un-reversed
 * (`direction: ltr`) so the image — which is the first child in source
 * order — always sits ABOVE the text, regardless of variant. This is a
 * deliberate Magnus design choice: on small screens, a photo-led rhythm
 * reads better than alternating text-then-photo / photo-then-text.
 *
 * Token-driven: no hardcoded colors, all sizing via clamp(). Falls back
 * to sensible defaults when a token is missing so the section degrades
 * gracefully across all 5 aesthetics. */

.editorial-section {
  /* Container reset — the children are full-bleed editorial blocks, not
   * the standard .section padded text column. Let the section itself
   * provide only vertical breathing room. */
  padding-left: 0;
  padding-right: 0;
  padding-top: 0;
  padding-bottom: 0;
}

.editorial {
  display: grid;
  grid-template-columns: 1fr 1fr;
  min-height: clamp(28rem, 60vh, 40rem);
  background: var(--color-surface, #f6f1e7);
}

/* .reverse — flip column order without duplicating markup. Parent goes
 * RTL so the grid auto-flow inverts; each direct child resets to LTR so
 * its own contents read normally. */
.editorial.reverse {
  direction: rtl;
}
.editorial.reverse > * {
  direction: ltr;
}

/* ── IMAGE PANEL ── */
.editorial-img {
  position: relative;
  overflow: hidden;
  background: var(--color-surface-warm, var(--color-surface, #f0ece4));
}

.editorial-img picture {
  display: block;
  width: 100%;
  height: 100%;
}

.editorial-img img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  object-position: center;
  display: block;
  transition: transform var(--motion-slow, 800ms) var(--motion-ease, ease);
}

.editorial-img:hover img {
  transform: scale(1.04);
}

/* ── TEXT PANEL ── */
.editorial-text {
  padding: clamp(2.5rem, 6vw, 5rem) clamp(1.75rem, 5vw, 4.5rem);
  display: flex;
  flex-direction: column;
  justify-content: center;
  background: var(--color-surface, var(--color-cream, #f6f1e7));
}

.editorial-text > * {
  /* Cap the prose width inside the panel for editorial readability —
   * keeps line length comfortable when the panel is wide. */
  max-width: 38ch;
}

.editorial-text .section__kicker {
  margin-bottom: clamp(0.75rem, 1.5vw, 1.25rem);
  color: var(--color-primary, var(--color-text-muted, #7a746c));
}

.editorial-text h2 {
  margin: 0 0 clamp(1rem, 2vw, 1.5rem);
  color: var(--color-text, var(--color-dark, #1a1a1a));
  font-size: clamp(1.6rem, 3.4vw, 2.4rem);
  line-height: 1.15;
}

.editorial-text .lede,
.editorial-text p {
  margin: 0 0 clamp(1rem, 2vw, 1.75rem);
  color: var(--color-text, #2a2a2a);
  font-size: clamp(1rem, 1.2vw, 1.125rem);
  line-height: 1.65;
}

.editorial-text .lede:last-child,
.editorial-text p:last-child {
  margin-bottom: 0;
}

/* ── DARK VARIANT — when the text panel sits next to a dark/moody image
 * and we want the contrast inverted (cream type on a deep ground). */
.editorial-text.dark {
  background: var(--color-dark, var(--color-text, #1a1a1a));
}

.editorial-text.dark h2 {
  color: var(--color-cream, var(--color-surface, #f6f1e7));
}

.editorial-text.dark .section__kicker {
  color: var(--color-primary-on-dark, var(--color-cream, #d4956a));
}

.editorial-text.dark .lede,
.editorial-text.dark p {
  color: var(--color-stone, color-mix(in srgb, var(--color-cream, #f6f1e7) 80%, transparent));
}

/* ── MOBILE — single column, image always above text. The `.reverse`
 * trick is undone here so source order (image first, then text) wins. */
@media (max-width: 768px) {
  .editorial {
    grid-template-columns: 1fr;
    min-height: 0;
  }
  .editorial.reverse {
    direction: ltr;
  }
  .editorial-img {
    aspect-ratio: 16 / 9;
  }
  .editorial-text {
    padding: clamp(2rem, 8vw, 3rem) clamp(1.25rem, 6vw, 2rem);
  }
  .editorial-text > * {
    max-width: none;
  }
}

/* Respect reduced-motion — kill the hover lift. */
@media (prefers-reduced-motion: reduce) {
  .editorial-img img {
    transition: none;
  }
  .editorial-img:hover img {
    transform: none;
  }
}


/* explore section — curated "what to do nearby" grid with per-place
 * imagery + bottom-anchored distance chips. Harvested from Villa
 * Magnus and elevated with photos.
 *
 * Token-driven so the section composes across all five aesthetics —
 * no hardcoded colors, no aesthetic-specific overrides here. Per-
 * aesthetic tweaks (if any) belong in aesthetics/<name>/components.css.
 *
 * Typography lifted from Magnus (style.css §explore-card / .explore-dist):
 *   - .explore-name ~ 1.4rem serif weight 300, line-height 1.15
 *   - .explore-desc ~ 0.88rem body, line-height 1.8
 *   - .explore-dist ~ 0.62rem uppercase 2.5px letter-spacing, thin border
 * Those ratios were tuned through design audit + WCAG passes —
 * preserve them. */

.explore {
  padding-top: clamp(3.5rem, 6vw, 6rem);
  padding-bottom: clamp(3.5rem, 6vw, 6rem);
  background: var(--color-surface, #fbfaf6);
}

.explore__header {
  text-align: center;
  max-width: 640px;
  margin: 0 auto clamp(2rem, 4vw, 3.5rem);
}

.explore__lede {
  margin-top: 0.85rem;
  font-size: 1.02rem;
  color: var(--color-muted, var(--color-ink));
}

/* 3 cols desktop · 2 cols tablet · 1 col mobile.
 * 1px gap on warm surface gives Magnus's hairline-divider feel without
 * needing extra borders. */
.explore-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: clamp(0.75rem, 1.5vw, 1.5rem);
  max-width: 1280px;
  margin: 0 auto;
}

/* The proven design-audit fix: card is a flex column with the
 * distance chip anchored to the bottom via margin-top: auto, so chips
 * line up across the grid regardless of description length. */
.explore-card {
  display: flex;
  flex-direction: column;
  margin: 0;
  background: var(--color-surface-warm, var(--color-surface, #f6f1e8));
  border: 1px solid color-mix(in srgb, var(--color-ink) 6%, transparent);
  border-radius: 2px;
  overflow: hidden;
  transition:
    transform var(--motion-fast, 280ms) var(--motion-ease, ease),
    box-shadow var(--motion-fast, 280ms) var(--motion-ease, ease);
}

.explore-card:hover {
  transform: translateY(-2px);
  box-shadow: 0 6px 22px -12px color-mix(in srgb, var(--color-ink) 35%, transparent);
}

/* 4:3 image — Magnus's editorial spec.
 * picture wraps img so webp <source> + jpg fallback both fill the same
 * 4:3 frame. object-fit: cover ensures no distortion regardless of
 * source dimensions. */
.explore-card picture {
  display: block;
  width: 100%;
  aspect-ratio: 4 / 3;
  background: color-mix(in srgb, var(--color-ink) 6%, transparent);
  overflow: hidden;
}

.explore-img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  object-position: center;
  display: block;
  transition: transform var(--motion-fast, 400ms) var(--motion-ease, ease);
}

.explore-card:hover .explore-img {
  transform: scale(1.02);
}

/* Card name — lifted from Magnus .explore-card h4 (now h3 per the
 * heading-hierarchy fix recorded in isla_studio_wcag_aa_pass_recipe). */
.explore-name {
  font-family: var(--font-display), serif;
  font-size: 1.4rem;
  font-weight: 300;
  line-height: 1.15;
  letter-spacing: -0.01em;
  color: var(--color-ink);
  margin: 1.4rem 1.75rem 0.7rem;
}

.explore-desc {
  font-family: var(--font-body), system-ui, sans-serif;
  font-size: 0.88rem;
  line-height: 1.7;
  color: var(--color-muted, var(--color-ink));
  margin: 0 1.75rem 1.4rem;
}

/* Distance chip — lifted from Magnus .explore-dist. Bottom-anchored
 * via margin-top: auto so it aligns across the row regardless of how
 * long the description above runs. align-self: flex-start keeps the
 * pill content-sized rather than stretching across the card. */
.explore-dist {
  align-self: flex-start;
  margin-top: auto;
  margin-right: 1.75rem;
  margin-bottom: 1.6rem;
  margin-left: 1.75rem;
  font-family: var(--font-body), system-ui, sans-serif;
  font-size: 0.62rem;
  font-weight: 500;
  letter-spacing: 0.18em;
  text-transform: uppercase;
  color: var(--color-primary);
  background: color-mix(in srgb, var(--color-primary) 8%, transparent);
  border: 1px solid color-mix(in srgb, var(--color-primary) 28%, transparent);
  border-radius: 999px;
  padding: 0.35rem 0.85rem;
  font-variant-numeric: tabular-nums;
}

/* Auto-hide the entire section if every card has lost its image
 * (i.e. all six figures are display:none from the inline onerror).
 * :has(.explore-card:not([style*="display: none"])) keeps the section
 * visible as long as at least one card survives. */
.explore-grid:not(:has(.explore-card:not([style*="display: none"]))) {
  display: none;
}

.explore:has(.explore-grid:not(:has(.explore-card:not([style*="display: none"])))) {
  display: none;
}

/* Tablet: 2 cols. */
@media (max-width: 960px) {
  .explore-grid {
    grid-template-columns: repeat(2, 1fr);
  }
}

/* Mobile: 1 col. */
@media (max-width: 600px) {
  .explore-grid {
    grid-template-columns: 1fr;
  }
  .explore-name {
    font-size: 1.25rem;
    margin: 1.2rem 1.4rem 0.6rem;
  }
  .explore-desc {
    margin: 0 1.4rem 1.2rem;
  }
  .explore-dist {
    margin-top: auto;
    margin-right: 1.4rem;
    margin-bottom: 1.3rem;
    margin-left: 1.4rem;
  }
}

/* Respect users who prefer reduced motion — kill the hover lift, the
 * shadow, and the image zoom. Cards stay legible, just static. */
@media (prefers-reduced-motion: reduce) {
  .explore-card,
  .explore-img {
    transition: none;
  }
  .explore-card:hover {
    transform: none;
    box-shadow: none;
  }
  .explore-card:hover .explore-img {
    transform: none;
  }
}


/* faq section — pure-CSS <details> accordion. No JS. */

.faq-section {
  padding-top: clamp(3rem, 6vw, 5rem);
  padding-bottom: clamp(3rem, 6vw, 5rem);
}

.faq-list {
  display: flex;
  flex-direction: column;
  border-top: 1px solid var(--color-rule, rgba(0, 0, 0, 0.12));
  margin-top: 2rem;
}

.faq-item {
  border-bottom: 1px solid var(--color-rule, rgba(0, 0, 0, 0.12));
}

/* Hide items whose summary is empty (i18n key not populated) */
.faq-item:has(summary span:empty) {
  display: none;
}

.faq-item summary {
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: 1.5rem;
  padding: 1.4rem 0.25rem;
  cursor: pointer;
  list-style: none;
  font-family: var(--font-display, serif);
  font-size: clamp(1.05rem, 1.6vw, 1.3rem);
  color: var(--color-ink);
  transition: color 200ms ease;
}

.faq-item summary::-webkit-details-marker { display: none; }
.faq-item summary::marker { content: ""; }

.faq-item summary::after {
  content: "+";
  font-family: var(--font-display, serif);
  font-size: 1.6rem;
  line-height: 1;
  color: var(--color-primary);
  flex-shrink: 0;
  transition: transform 280ms var(--motion-ease, ease);
}

.faq-item[open] summary::after {
  content: "−";
  transform: rotate(0deg);
}

.faq-item:hover summary {
  color: var(--color-primary);
}

.faq-answer {
  padding: 0 0 1.6rem;
  max-width: 60ch;
}

.faq-answer p {
  color: var(--color-muted, var(--color-ink));
  font-size: 1rem;
  line-height: 1.7;
  margin: 0;
}


/* gallery_preview section — editorial asymmetric 6-tile grid on the home
 * page. NOT a 3x2 uniform grid: one tall tile, two stacked squares, one
 * wide tile underneath them, two small detail tiles to the right.
 *
 * Token-driven so the section adapts across all 5 aesthetics. No
 * hardcoded colors. Aesthetic-specific overrides (if any) live in
 * aesthetics/<name>/components.css.
 */

.gallery-preview {
  padding-top: clamp(3rem, 6vw, 5rem);
  padding-bottom: clamp(3rem, 6vw, 5rem);
}

.gallery-preview__grid {
  display: grid;
  grid-template-columns: repeat(6, 1fr);
  grid-template-rows: repeat(4, 1fr);
  /* Explicit grid height — without it, 1fr rows collapse to min-content
   * and tile img height:100% has no defined parent (browsers fall back
   * to img natural size and the layout blows up vertically). */
  height: min(72vh, 760px);
  gap: clamp(0.5rem, 1.2vw, 1rem);
  margin-top: 2.5rem;
  /* Asymmetric editorial layout:
   *   tall takes 2 cols / all 4 rows on the left.
   *   sq1 + sq2 stack to the right of tall, each 2 cols x 2 rows.
   *   wide spans the rightmost 2 cols x 2 rows (top-right anchor).
   *   sml1 + sml2 sit underneath as two 2-col x 2-row detail tiles.
   * Result: tall (l) + 2 stacked squares (centre) + wide (top-right) +
   * 2 small detail tiles spanning the bottom-right. */
  grid-template-areas:
    "tall tall sq1  sq1  wide wide"
    "tall tall sq1  sq1  wide wide"
    "tall tall sq2  sq2  sml1 sml1"
    "tall tall sq2  sq2  sml2 sml2";
}

.gallery-preview__tile {
  margin: 0;
  position: relative;
  overflow: hidden;
  background: var(--color-surface-warm, var(--color-surface, #f0ece4));
  border-radius: 2px;
}

.gallery-preview__tile--tall    { grid-area: tall; }
.gallery-preview__tile--wide    { grid-area: wide; }
.gallery-preview__tile--square:nth-of-type(2) { grid-area: sq1; }
.gallery-preview__tile--square:nth-of-type(3) { grid-area: sq2; }
.gallery-preview__tile--small:nth-of-type(5)  { grid-area: sml1; }
.gallery-preview__tile--small:nth-of-type(6)  { grid-area: sml2; }

.gallery-preview__tile a {
  display: block;
  width: 100%;
  height: 100%;
  overflow: hidden;
}

.gallery-preview__tile picture {
  display: block;
  width: 100%;
  height: 100%;
}

.gallery-preview__tile img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  object-position: center;
  display: block;
  transition: transform var(--motion-fast, 280ms) var(--motion-ease, ease);
}

.gallery-preview__tile:hover img {
  transform: scale(1.02);
}

/* CTA below the grid — small caps + arrow, in the primary tone. */
.gallery-preview__cta {
  margin-top: clamp(1.75rem, 3vw, 2.5rem);
  text-align: center;
}

.gallery-preview__cta a {
  display: inline-flex;
  align-items: center;
  gap: 0.65rem;
  color: var(--color-primary);
  text-decoration: none;
  font-size: 0.82rem;
  letter-spacing: 0.18em;
  text-transform: uppercase;
  border-bottom: 1px solid color-mix(in srgb, var(--color-primary) 35%, transparent);
  padding-bottom: 0.35rem;
  transition: border-color var(--motion-fast, 200ms) ease, color var(--motion-fast, 200ms) ease;
}

.gallery-preview__cta a:hover {
  border-color: var(--color-primary);
  opacity: 1;
}

.gallery-preview__cta-arrow {
  display: inline-block;
  transition: transform var(--motion-fast, 200ms) var(--motion-ease, ease);
}

.gallery-preview__cta a:hover .gallery-preview__cta-arrow {
  transform: translateX(4px);
}

/* Mobile: 2-col grid. Tall stays tall (2 rows), wide spans both columns
 * top, then squares / details fill in. Stays asymmetric — not 6 equal
 * squares. */
@media (max-width: 768px) {
  .gallery-preview__grid {
    grid-template-columns: repeat(2, 1fr);
    grid-template-rows: repeat(5, minmax(110px, 1fr));
    grid-template-areas:
      "wide wide"
      "tall sq1"
      "tall sq1"
      "tall sq2"
      "sml1 sml2";
    gap: 0.5rem;
  }
}

/* Respect users who prefer reduced motion — kill the hover lift and the
 * arrow nudge. Tiles remain interactive, just static. */
@media (prefers-reduced-motion: reduce) {
  .gallery-preview__tile img,
  .gallery-preview__cta-arrow,
  .gallery-preview__cta a {
    transition: none;
  }
  .gallery-preview__tile:hover img {
    transform: none;
  }
  .gallery-preview__cta a:hover .gallery-preview__cta-arrow {
    transform: none;
  }
}


/* location_map section — content + linked location card.
 * Card visually anchors the area without depending on an embed/iframe
 * (legacy maps.google.com/maps?output=embed is broken; proper pb= format
 * requires per-property place IDs that auto-demos don't have).
 */

.location-section {
  display: grid;
  grid-template-columns: 1.1fr 1fr;
  gap: clamp(2rem, 4vw, 4rem);
  align-items: center;
  padding: clamp(4rem, 8vw, 7rem) clamp(1.5rem, 5vw, 4rem);
  max-width: 88rem;
  margin: 0 auto;
}

.location-content {
  display: flex;
  flex-direction: column;
  gap: 0.85rem;
}

.location-meta {
  font-size: 0.9rem;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  color: var(--color-muted, var(--color-ink));
  margin-top: 1.5rem;
}

.location-card {
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: 1rem;
  text-align: center;
  text-decoration: none;
  color: var(--color-ink);
  aspect-ratio: 4 / 3;
  min-height: 320px;
  background: linear-gradient(
    135deg,
    var(--color-surface-warm, #f0ece4) 0%,
    var(--color-surface, #fbfaf6) 60%,
    color-mix(in srgb, var(--color-primary) 8%, transparent) 100%
  );
  border: 1px solid var(--color-rule, rgba(0, 0, 0, 0.12));
  position: relative;
  overflow: hidden;
  transition: transform 280ms var(--motion-ease, ease), border-color 280ms ease;
}

.location-card:hover {
  transform: translateY(-2px);
  border-color: var(--color-primary);
}

.location-card::before {
  content: "";
  position: absolute;
  inset: 0;
  background:
    radial-gradient(circle at 30% 40%, color-mix(in srgb, var(--color-primary) 14%, transparent) 0%, transparent 40%),
    radial-gradient(circle at 70% 70%, color-mix(in srgb, var(--color-primary) 10%, transparent) 0%, transparent 35%);
  opacity: 0.7;
  pointer-events: none;
}

.location-card > * { position: relative; z-index: 1; }

.location-card__icon {
  width: 56px;
  height: 56px;
  color: var(--color-primary);
}

.location-card__label {
  font-family: var(--font-display, serif);
  font-size: clamp(1.1rem, 1.8vw, 1.4rem);
  letter-spacing: 0.02em;
  font-weight: 500;
}

.location-card__arrow {
  font-size: 1.5rem;
  color: var(--color-primary);
  opacity: 0.8;
}

@media (max-width: 800px) {
  .location-section {
    grid-template-columns: 1fr;
    gap: 2rem;
  }
  .location-card {
    aspect-ratio: 3 / 2;
    min-height: 240px;
  }
}

/* Refined card: property name + locality above the pin icon. */
.location-card__place {
  font-family: var(--font-display, serif);
  font-size: clamp(1.15rem, 1.9vw, 1.45rem);
  letter-spacing: 0.01em;
  font-weight: 500;
  color: var(--color-ink);
}

.location-card__locality {
  font-size: 0.85rem;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  color: var(--color-muted, var(--color-ink));
}

/* "Within easy reach" sub-section — auto-hides when the slot rendered nothing.
 * Agent E substitutes {{source.nearby_places_html}} with an empty string when
 * the scraper found no structured nearby_places. :has() hides the entire
 * sub-section (kicker + title included) so the user sees only the generic
 * lede above, not a stranded heading.
 */
.location-map__nearby {
  margin-top: clamp(2rem, 4vw, 2.75rem);
  padding-top: clamp(1.5rem, 3vw, 2rem);
  border-top: 1px solid var(--color-rule, rgba(0, 0, 0, 0.1));
}

.location-map__nearby:not(:has(.location-nearby__list)),
.location-map__nearby:has(.location-nearby__list:empty) {
  display: none;
}

.location-map__nearby-kicker {
  margin-bottom: 0.35rem;
}

.location-map__nearby-title {
  font-family: var(--font-display, serif);
  font-size: clamp(1.25rem, 2vw, 1.6rem);
  font-weight: 500;
  margin: 0;
  color: var(--color-ink);
}

.location-nearby__list {
  list-style: none;
  padding: 0;
  margin: 1.2rem 0 0;
  display: grid;
  gap: 0.55rem;
}

.location-nearby__list li {
  font-size: 1rem;
  display: flex;
  flex-wrap: wrap;
  gap: 0.5em;
  align-items: baseline;
}

.location-nearby__name {
  font-family: var(--font-display, serif);
  font-weight: 500;
  color: var(--color-ink);
}

.location-nearby__time {
  color: var(--color-muted, var(--color-ink));
}


/* reviews section — curated guest-quote block harvested from villa-magnus.
 * Token-driven so each aesthetic's typography + color cascade through.
 * Section auto-hides when t.reviews_score is empty. */

.reviews:has(.reviews-score__big:empty) { display: none; }

.reviews-score {
  display: inline-flex;
  align-items: baseline;
  gap: 0.8rem;
  margin: 2rem 0 3rem;
}

.reviews-score__big {
  font-family: var(--font-display);
  font-size: clamp(3rem, 6vw, 5rem);
  font-weight: 300;
  line-height: 1;
  color: var(--color-ink, #1a1a1a);
}

.reviews-score__detail {
  color: var(--color-muted, #5d574f);
  font-size: 0.85rem;
}

.reviews-score__stars {
  color: var(--color-primary, #8e5527);
  font-size: 1rem;
  margin-bottom: 0.25rem;
  letter-spacing: 0.1em;
}

.reviews-score__count {
  font-size: 0.85rem;
}

.reviews-grid {
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  gap: clamp(1rem, 2vw, 2rem);
}

.review-card {
  padding: clamp(1.5rem, 3vw, 2.5rem);
  background: var(--color-surface-warm, #f0ece4);
  border-top: 2px solid var(--color-rule, rgba(0, 0, 0, 0.08));
  transition: border-top-color var(--motion-fast, 240ms) var(--motion-ease, ease);
}

.review-card:hover {
  border-top-color: var(--color-primary, #8e5527);
}

.review-card__quote {
  display: block;
  font-family: var(--font-display);
  font-size: 3rem;
  line-height: 0.5;
  margin-bottom: 1rem;
  color: var(--color-rule, rgba(0, 0, 0, 0.2));
}

.review-card__text {
  font-style: italic;
  font-family: var(--font-display);
  font-size: 1.05rem;
  line-height: 1.7;
  color: var(--color-ink, #1a1a1a);
  margin: 0 0 1.5rem;
}

.review-card__author {
  font-size: 0.75rem;
  letter-spacing: 0.15em;
  text-transform: uppercase;
  color: var(--color-primary, #8e5527);
}

.review-card__meta {
  font-size: 0.78rem;
  color: var(--color-muted, #5d574f);
  margin-top: 0.25rem;
}

/* Auto-hide an individual card when its text is empty */
.review-card:has(.review-card__text:empty) { display: none; }

@media (min-width: 1024px) {
  .reviews-grid { grid-template-columns: repeat(4, 1fr); }
}

@media (max-width: 640px) {
  .reviews-grid { grid-template-columns: 1fr; }
}

@media (prefers-reduced-motion: reduce) {
  .review-card { transition: none; }
}


/* social_proof section — editorial guest rating + review excerpts.
 *
 * Design intent: NOT a loud "5-star badge" widget. Big numeral in the
 * display font as the visual hero, generous whitespace around it, two
 * italic blockquotes underneath set in the same display face with a thin
 * left rule. All colors via tokens so each aesthetic's palette cascades
 * through (luxury_mediterranean, brutalist_stone, etc.).
 *
 * Auto-hide: when {{source.rating_formatted}} substitutes to "", the inner
 * span .social-proof__rating renders empty → CSS :has hides the whole
 * section. No rating → no section, no broken-looking 0.0 star.
 */

.social-proof {
  padding-top: clamp(4rem, 8vw, 7rem);
  padding-bottom: clamp(4rem, 8vw, 7rem);
  text-align: center;
}

/* Auto-hide the entire section when no rating data is present. Relies on
 * modern :has() — graceful fallback is "section renders with empty rating
 * span which looks slightly odd", same approach as the amenities tiles. */
.social-proof:has(.social-proof__rating:empty) {
  display: none;
}

.social-proof .section__kicker {
  /* Inherits .section__kicker base styling from core.css; nothing to add. */
}

.social-proof__headline {
  display: inline-flex;
  align-items: baseline;
  gap: 0.45rem;
  margin-top: 1.25rem;
  margin-bottom: 0.4rem;
}

.social-proof__rating {
  font-family: var(--font-display, "Cormorant Garamond", serif);
  font-size: clamp(3rem, 8vw, 6rem);
  font-weight: 400;
  line-height: 1;
  letter-spacing: -0.02em;
  color: var(--color-ink);
  display: inline-block;
}

.social-proof__star {
  font-size: clamp(1.4rem, 2.6vw, 2rem);
  color: var(--color-primary);
  line-height: 1;
  /* Subtle baseline lift so the star sits next to the numeral, not below. */
  transform: translateY(-0.15em);
}

.social-proof__count {
  margin: 0.25rem 0 0;
  font-size: 0.95rem;
  letter-spacing: 0.02em;
  color: var(--color-ink);
}

.social-proof__count-num {
  font-weight: 500;
}

.social-proof__count-label {
  color: var(--color-muted, var(--color-ink));
  margin-left: 0.35rem;
}

/* Hide the count line entirely if reviews_count is missing (empty num span). */
.social-proof__count:has(.social-proof__count-num:empty) {
  display: none;
}

.social-proof__suffix {
  margin: 0.4rem 0 0;
  font-size: 0.82rem;
  letter-spacing: 0.18em;
  text-transform: uppercase;
  color: var(--color-muted, var(--color-ink));
  opacity: 0.85;
}

.social-proof__quotes {
  display: flex;
  flex-direction: column;
  gap: 1.75rem;
  max-width: 44rem;
  margin: clamp(2.5rem, 5vw, 4rem) auto 0;
  text-align: left;
}

/* Pre-rendered blockquotes from {{source.review_excerpts_html}}. Italic
 * display-font setting with a thin primary-colored left rule — restrained,
 * editorial, not a Trustpilot card. */
.social-proof__quote {
  margin: 0;
  padding: 0.4rem 0 0.4rem 1.5rem;
  border-left: 2px solid var(--color-primary);
}

.social-proof__quote p {
  margin: 0;
  font-family: var(--font-display, "Cormorant Garamond", serif);
  font-style: italic;
  font-size: clamp(1.05rem, 1.6vw, 1.3rem);
  line-height: 1.5;
  color: var(--color-ink);
  letter-spacing: 0.005em;
}

/* Mobile: tighter spacing, smaller numeral, clamp the quote text to 4 lines
 * each so a single excerpt is the visible focus while the second is just
 * peeking — keeps the section short on small viewports. */
@media (max-width: 640px) {
  .social-proof {
    padding-top: clamp(3rem, 10vw, 5rem);
    padding-bottom: clamp(3rem, 10vw, 5rem);
  }
  .social-proof__quotes {
    gap: 1.25rem;
  }
  .social-proof__quote p {
    display: -webkit-box;
    -webkit-line-clamp: 4;
    -webkit-box-orient: vertical;
    overflow: hidden;
  }
}

@media (prefers-reduced-motion: reduce) {
  /* No animations on this section anyway — placeholder for consistency. */
}


/* sticky_cta — fixed-bottom mobile-only enquire CTA. Sits below the cookie
 * banner (z-index 60) and clears the WhatsApp FAB (bottom-right, ~64px).
 * Auto-hides when the book section is already in viewport (via sticky_cta.js
 * setting data-cta-hidden on the link).
 *
 * Token-driven so each aesthetic colors it. Mobile-only — display: none on
 * ≥769px viewports because desktop has plenty of space for the regular CTA.
 */

.sticky-cta { display: none; }

@media (max-width: 768px) {
  .sticky-cta {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 0.5rem;
    position: fixed;
    bottom: clamp(0.75rem, 2.5vw, 1.25rem);
    left: clamp(0.75rem, 4vw, 1.5rem);
    /* leave room on the right for the WhatsApp FAB (40px circle + 1rem margin) */
    right: calc(40px + clamp(0.75rem, 4vw, 1.5rem) + 0.5rem);
    z-index: 55;
    padding: 0.95rem 1.25rem;
    background: var(--color-primary, #8e5527);
    color: var(--color-surface, #fbfaf6);
    text-decoration: none;
    border-radius: 999px;
    font-size: 0.95rem;
    font-weight: 600;
    letter-spacing: 0.04em;
    box-shadow: 0 6px 20px -10px rgba(0, 0, 0, 0.45);
    transition:
      transform var(--motion-fast, 240ms) var(--motion-ease, ease),
      background var(--motion-fast, 240ms) var(--motion-ease, ease),
      opacity var(--motion-fast, 240ms) var(--motion-ease, ease);
    /* Avoid the "tap-flash" on iOS */
    -webkit-tap-highlight-color: transparent;
  }
  .sticky-cta:hover,
  .sticky-cta:focus-visible {
    transform: translateY(-1px);
    background: var(--color-primary-dark, #6e4220);
  }
  .sticky-cta:focus-visible {
    outline: 2px solid var(--color-surface, #fbfaf6);
    outline-offset: 2px;
  }
  .sticky-cta[data-cta-hidden="true"] {
    opacity: 0;
    pointer-events: none;
    transform: translateY(6px);
  }
  .sticky-cta__arrow {
    flex: 0 0 auto;
    display: block;
  }
}

/* If a site doesn't have a book section at all (e.g. about/contact-only
 * scaffolding), hide the bar globally — no point pointing at #book that
 * doesn't exist. Hooked via sticky_cta.js. */
.sticky-cta[data-cta-disabled="true"] { display: none !important; }

@media (prefers-reduced-motion: reduce) {
  .sticky-cta { transition: none; }
  .sticky-cta:hover,
  .sticky-cta:focus-visible { transform: none; }
}


/* Floating WhatsApp button — always visible bottom-right quick contact.
   Color #075E54 = WCAG AA proven per isla_studio_wcag_aa_pass_recipe memory.
   NEVER swap in the loud WhatsApp brand green — it fails contrast against white text. */
.whatsapp-fab {
  position: fixed;
  bottom: clamp(1rem, 3vw, 1.5rem);
  right: clamp(1rem, 3vw, 1.5rem);
  z-index: 50;
  display: inline-flex;
  align-items: center;
  gap: 0.5rem;
  padding: 0.85rem 1rem;
  background: #075E54;
  color: #ffffff;
  border-radius: 999px;
  box-shadow: 0 4px 14px rgba(0, 0, 0, 0.18);
  text-decoration: none;
  font-size: 0.95rem;
  font-weight: 600;
  line-height: 1;
  transition: transform var(--motion-fast, 200ms) ease, background var(--motion-fast, 200ms) ease, box-shadow var(--motion-fast, 200ms) ease;
}

.whatsapp-fab:hover,
.whatsapp-fab:focus-visible {
  transform: translateY(-2px);
  background: #054943;
  box-shadow: 0 6px 18px rgba(0, 0, 0, 0.24);
}

.whatsapp-fab:focus-visible {
  outline: 2px solid #ffffff;
  outline-offset: 2px;
}

.whatsapp-fab svg {
  display: block;
  flex-shrink: 0;
}

/* Mobile: collapse to icon-only circular button to save space */
@media (max-width: 640px) {
  .whatsapp-fab__label {
    display: none;
  }
  .whatsapp-fab {
    padding: 0.85rem;
    aspect-ratio: 1;
    justify-content: center;
  }
}

/* Auto-hide when WhatsApp number is empty (data-empty-target="").
   Mirrors the Phase G footer conditional-rendering pattern. */
.whatsapp-fab[data-empty-target=""] {
  display: none;
}

@media (prefers-reduced-motion: reduce) {
  .whatsapp-fab {
    transition: none;
  }
  .whatsapp-fab:hover,
  .whatsapp-fab:focus-visible {
    transform: none;
  }
}


/* luxury_refined — formal serif body, didone display, brass accents,
 * generous proportions, classic luxe.
 */

body {
  background: var(--color-surface);
  color: var(--color-ink);
  font-feature-settings: "kern", "liga", "lnum";
}

.site-header {
  padding: 1.6rem clamp(1.5rem, 5vw, 4rem);
  border-bottom: 1px solid var(--color-rule);
}

.site-mark {
  font-family: var(--font-display);
  font-size: 1.4rem;
  font-weight: 500;
  letter-spacing: 0.02em;
}

.site-nav a {
  font-size: 0.92rem;
  font-family: var(--font-body);
  font-style: italic;
  color: var(--color-ink);
}

.hero {
  display: grid;
  min-height: 86vh;
  padding: clamp(3rem, 8vw, 8rem);
  align-items: center;
  text-align: center;
  background-size: cover;
  background-position: center;
  color: var(--color-surface);
  position: relative;
}
.hero::after {
  content: "";
  position: absolute;
  inset: 0;
  background: linear-gradient(180deg, rgba(16,20,28,0.4) 0%, rgba(16,20,28,0.55) 100%);
}
/* Target only the content wrapper — `.hero > *` would also constrain the
 * absolutely-positioned `.hero__bg` <picture> to 24ch wide and break the
 * full-bleed photo (Phase D+6+ structure). */
.hero__inner { max-width: 24ch; margin-inline: auto; text-align: center; }

.hero__title {
  font-family: var(--font-display);
  font-size: clamp(2.8rem, 7vw, 6rem);
  font-weight: 400;
  letter-spacing: -0.005em;
  line-height: 1.05;
  margin: 0;
}

.hero__kicker {
  font-family: var(--font-body);
  font-style: italic;
  letter-spacing: 0.18em;
  font-size: 0.85rem;
  text-transform: uppercase;
  margin: 0 0 1.6rem;
}

.section {
  padding: clamp(4rem, 9vw, 9rem) clamp(1.5rem, 5vw, 4rem);
  max-width: 72rem;
  margin: 0 auto;
}

.section--narrow { max-width: 46rem; text-align: center; }
.section--warm { background: var(--color-surface-warm); max-width: none; }

.section__kicker {
  font-family: var(--font-body);
  font-style: italic;
  letter-spacing: 0.16em;
  text-transform: uppercase;
  font-size: 0.78rem;
  color: var(--color-muted);
  margin: 0 0 1rem;
}

.lede {
  font-family: var(--font-display);
  font-weight: 400;
  font-size: clamp(1.4rem, 2.6vw, 1.9rem);
  line-height: 1.45;
  color: var(--color-ink);
  max-width: 36rem;
  margin: 0 auto;
}

.amenities {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(240px, 1fr));
  gap: 3rem 2.5rem;
  margin-top: 4rem;
  text-align: left;
}

.amenity {
  padding-top: 1.6rem;
  border-top: 1px solid var(--color-rule);
}

.amenity__title {
  font-family: var(--font-display);
  font-size: 1.4rem;
  font-weight: 500;
  margin: 0 0 0.6rem;
}

.amenity__body {
  margin: 0;
  color: var(--color-muted);
  font-size: 1rem;
}

button {
  background: transparent;
  color: var(--color-ink);
  border: 1px solid var(--color-ink);
  padding: 1.1rem 2.6rem;
  border-radius: 0;
  text-transform: uppercase;
  letter-spacing: 0.16em;
  font-family: var(--font-body);
  font-size: 0.78rem;
}
button:hover { background: var(--color-ink); color: var(--color-surface); }

.gallery {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(300px, 1fr));
  gap: 1.4rem;
}
.gallery img { aspect-ratio: 4/5; object-fit: cover; }

.contact-form input,
.contact-form textarea {
  border: 1px solid var(--color-rule);
  border-radius: 0;
  background: var(--color-surface);
  font-family: var(--font-body);
}

[data-fade-in] {
  opacity: 0;
  transform: translateY(14px);
  transition: opacity var(--motion-slow) var(--motion-ease),
              transform var(--motion-slow) var(--motion-ease);
}
[data-fade-in].is-visible { opacity: 1; transform: translateY(0); }


/* Site-specific overrides for Demo. */
