/* ============================================================================
   Real Estate Business Model page
   ----------------------------------------------------------------------------
   Page-scoped styles only. Every colour, radius, shadow and font here comes
   from the tokens in x3-theme.css — no new palette, no gradients. Sections
   reuse .x3-sec / .x3-sec--alt / .x3-sec--dark from the design system; what is
   below is the furniture those sections do not already provide: product
   screenshot frames, the income-stream grid, the tabbed switchers, the bento
   galleries, the pinned showcase and the lightbox.
   ========================================================================== */

/* This page runs wider than the rest of the site so the product screenshots
   carry more weight against the text. */
[data-bm-page] { --page-max: 1500px; }

/* ── Screenshot frames ───────────────────────────────────────────────────── */

.bm-shot { margin: 0; }

.bm-frame {
  position: relative;
  overflow: hidden;
  background: var(--navy-deep);
  box-shadow: var(--shadow-lift);
}

.bm-frame--browser { border-radius: var(--r-tile); }

.bm-frame--browser .bm-frame__bar {
  display: flex;
  align-items: center;
  gap: 7px;
  height: 30px;
  padding: 0 14px;
  background: var(--navy);
  border-bottom: 1px solid rgba(255, 255, 255, .08);
}

.bm-frame--browser .bm-frame__bar span {
  width: 9px;
  height: 9px;
  border-radius: 50%;
  background: rgba(255, 255, 255, .22);
}

.bm-frame--browser .bm-frame__bar span:first-child { background: rgba(255, 107, 0, .85); }

.bm-frame__screen {
  position: relative;
  aspect-ratio: 1 / var(--bm-ratio, .625);
  background: var(--navy-deep);
}

.bm-frame__screen img {
  display: block;
  width: 100%;
  height: 100%;
  object-fit: cover;
  object-position: top center;
  cursor: zoom-in;
}

/* Phone frame */
.bm-frame--phone {
  border-radius: 30px;
  padding: 9px;
  background: #0d1522;
  box-shadow: var(--shadow-lift), inset 0 0 0 1px rgba(255, 255, 255, .07);
}

.bm-frame--phone .bm-frame__notch {
  width: 46%;
  height: 16px;
  margin: 0 auto 7px;
  border-radius: 0 0 11px 11px;
  background: #0d1522;
  position: relative;
  z-index: 2;
  margin-top: -9px;
}

.bm-frame--phone .bm-frame__screen {
  border-radius: 22px;
  overflow: hidden;
}

.bm-frame--phone .bm-frame__screen img { object-position: top center; }

.bm-frame--bare { border-radius: var(--r-tile); }

.bm-shot figcaption {
  margin-top: 12px;
  color: var(--ink-soft);
  font-size: 14px;
  line-height: 1.5;
}

.x3-sec--dark .bm-shot figcaption,
.x3-sec--deep .bm-shot figcaption { color: rgba(255, 255, 255, .64); }

/* ── Split layouts: screenshot one side, text the other ──────────────────── */

.bm-split {
  display: grid;
  grid-template-columns: minmax(0, 1.05fr) minmax(0, .95fr);
  gap: clamp(28px, 4vw, 60px);
  align-items: center;
}

.bm-split--rev .bm-split__media { order: 2; }

.bm-split__copy h2 { margin-bottom: 14px; }

.bm-split__copy > p {
  color: var(--ink-soft);
  line-height: 1.75;
  margin-bottom: 20px;
}

.x3-sec--dark .bm-split__copy > p { color: rgba(255, 255, 255, .72); }

/* Triptych: screenshot, text, screenshot */
.bm-trip {
  display: grid;
  grid-template-columns: minmax(0, 1fr) minmax(0, 1.08fr) minmax(0, 1fr);
  gap: clamp(22px, 3vw, 44px);
  align-items: center;
}

/* Offset card: a second screenshot overlapping the first */
.bm-stack { position: relative; }

.bm-stack__back {
  position: absolute;
  right: -6%;
  bottom: -12%;
  width: 52%;
  z-index: 2;
}

.bm-stack__back .bm-frame { box-shadow: 0 18px 50px rgba(2, 16, 31, .38); }

/* ── Bullet lists with orange ticks ──────────────────────────────────────── */

.bm-list { list-style: none; margin: 0; padding: 0; display: grid; gap: 13px; }

.bm-list li {
  position: relative;
  padding-left: 30px;
  line-height: 1.6;
  color: var(--ink);
}

.bm-list li::before {
  content: "";
  position: absolute;
  left: 0;
  top: .45em;
  width: 16px;
  height: 16px;
  border-radius: 50%;
  background: var(--accent);
  box-shadow: inset 0 0 0 2px rgba(255, 255, 255, .9);
}

.x3-sec--dark .bm-list li,
.x3-sec--deep .bm-list li { color: rgba(255, 255, 255, .86); }

.x3-sec--dark .bm-list li::before,
.x3-sec--deep .bm-list li::before { box-shadow: inset 0 0 0 2px rgba(4, 29, 54, .9); }

/* ── The nine income streams ─────────────────────────────────────────────── */

.bm-streams {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 18px;
  margin-top: 40px;
}

.bm-stream {
  position: relative;
  padding: 26px 24px 22px;
  border-radius: var(--r-tile);
  background: rgba(255, 255, 255, .045);
  box-shadow: inset 0 0 0 1px rgba(255, 255, 255, .09);
  display: flex;
  flex-direction: column;
  gap: 10px;
}

.bm-stream--lead {
  background: rgba(255, 107, 0, .07);
  box-shadow: inset 0 0 0 1.5px rgba(255, 107, 0, .5);
}

.bm-stream__num {
  font-family: var(--font-display);
  font-size: 30px;
  font-weight: 700;
  line-height: 1;
  color: var(--accent);
}

.bm-stream h3 {
  margin: 0;
  font-size: 19px;
  line-height: 1.25;
  color: #fff;
}

.bm-stream p {
  margin: 0;
  color: rgba(255, 255, 255, .74);
  font-size: 15px;
  line-height: 1.6;
}

.bm-stream__who {
  margin-top: auto;
  padding-top: 12px;
  font-size: 12.5px;
  letter-spacing: .06em;
  text-transform: uppercase;
  color: rgba(255, 255, 255, .5);
}

.bm-stream__see {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  color: var(--accent);
  font-family: var(--font-ui);
  font-size: 13.5px;
  font-weight: 600;
  text-decoration: none;
  /* it is a button now: it opens the proof screenshot in the lightbox */
  appearance: none;
  border: 0;
  padding: 0;
  background: none;
  cursor: pointer;
  text-align: left;
}

.bm-stream__see:hover { text-decoration: underline; }

.bm-streams__foot {
  margin-top: 34px;
  text-align: center;
}

.bm-streams__foot strong {
  display: block;
  color: var(--accent);
  font-size: clamp(17px, 2.2vw, 20px);
  margin-bottom: 22px;
}

/* ── Three steps ─────────────────────────────────────────────────────────── */

.bm-steps {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 22px;
  margin-top: 40px;
  counter-reset: bmstep;
}

.bm-step {
  position: relative;
  padding: 30px 26px;
  border-radius: var(--r-tile);
  background: var(--paper);
  box-shadow: var(--shadow-tile);
}

.bm-step__n {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 38px;
  height: 38px;
  border-radius: 50%;
  background: var(--accent);
  color: #fff;
  font-family: var(--font-display);
  font-weight: 700;
  margin-bottom: 14px;
}

.bm-step h3 { margin: 0 0 8px; font-size: 20px; }
.bm-step p { margin: 0; color: var(--ink-soft); line-height: 1.65; }

/* ── The package: one panel, image and copy the same height ───────────────── */

.bm-package {
  display: grid;
  grid-template-columns: minmax(0, 1.05fr) minmax(0, 1fr);
  border-radius: var(--r-panel);
  overflow: hidden;
  background: var(--paper);
  box-shadow: var(--shadow-lift);
}

.bm-package__media { position: relative; min-height: 420px; }

.bm-package__media img {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  object-fit: cover;
  display: block;
}

.bm-package__body { padding: clamp(28px, 3.4vw, 54px); }

.bm-package__body h2 { margin: 12px 0 14px; }

.bm-package__body > p {
  margin: 0 0 22px;
  color: var(--ink-soft);
  line-height: 1.7;
}

.bm-package__price {
  display: flex;
  align-items: baseline;
  gap: 12px;
  flex-wrap: wrap;
  margin-top: 26px;
  padding-top: 24px;
  border-top: 1px solid var(--ink-line);
}

.bm-package__fig {
  font-family: var(--font-display);
  font-size: clamp(40px, 5vw, 56px);
  font-weight: 700;
  line-height: 1;
  color: var(--ink);
}

.bm-package__note { color: var(--ink-soft); font-size: 15px; }

.bm-package__host {
  margin: 12px 0 0;
  color: var(--ink-soft);
  font-size: 14.5px;
  line-height: 1.6;
}

.bm-package__host strong { color: var(--ink); }

@media (max-width: 900px) {
  .bm-package { grid-template-columns: minmax(0, 1fr); }
  .bm-package__media { min-height: 260px; }
}
/* The price, as one line above a call to action */
.bm-price-line {
  margin: 0 0 6px;
  font-size: clamp(15px, 1.8vw, 17px);
  color: rgba(255, 255, 255, .82);
}

.bm-price-line strong {
  font-family: var(--font-display);
  font-size: 1.35em;
  color: #fff;
}

.bm-price-line span { opacity: .5; margin: 0 4px; }

.x3-cta .bm-price-line,
.x3-cta .bm-price-line strong { color: #fff; }

.bm-included__price {
  margin-top: 10px;
  color: var(--ink-soft);
}

.bm-included__price strong {
  font-family: var(--font-display);
  font-size: 1.35em;
  color: var(--ink);
}
/* ── Bento gallery ───────────────────────────────────────────────────────── */

.bm-bento {
  display: grid;
  grid-template-columns: repeat(6, minmax(0, 1fr));
  gap: 16px;
  margin-top: 36px;
}

.bm-bento > * { grid-column: span 2; }
.bm-bento > .bm-bento--lg { grid-column: span 3; }

.bm-grid3 {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 18px;
  margin-top: 30px;
}

.bm-grid2 {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: clamp(20px, 3vw, 40px);
  margin-top: 30px;
}

.bm-strip {
  display: grid;
  grid-template-columns: repeat(5, minmax(0, 1fr));
  gap: 14px;
  margin-top: 28px;
}

/* ── Tabbed screenshot switcher ──────────────────────────────────────────── */

.bm-tabs__list {
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
  justify-content: center;
  margin: 0 0 30px;
  padding: 0;
  list-style: none;
}

.bm-tab {
  appearance: none;
  border: 0;
  cursor: pointer;
  padding: 11px 20px;
  border-radius: 999px;
  font-family: var(--font-ui);
  font-size: 14.5px;
  font-weight: 600;
  color: var(--ink);
  background: var(--paper);
  box-shadow: inset 0 0 0 1px var(--ink-line);
  transition: background .25s var(--soft), color .25s var(--soft), box-shadow .25s var(--soft);
}

.bm-tab:hover { box-shadow: inset 0 0 0 1px rgba(255, 107, 0, .45); }

.bm-tab[aria-selected="true"] {
  background: var(--accent);
  color: #fff;
  box-shadow: none;
}

.x3-sec--dark .bm-tab {
  background: rgba(255, 255, 255, .06);
  color: rgba(255, 255, 255, .82);
  box-shadow: inset 0 0 0 1px rgba(255, 255, 255, .14);
}

.x3-sec--dark .bm-tab[aria-selected="true"] { background: var(--accent); color: #fff; }

/* Never a sideways scroll: below the full-width row the tabs wrap into a grid,
   three across, then two on a phone. Every tab stays visible and tappable. */
@media (max-width: 900px) {
  .bm-tabs__list {
    display: grid;
    grid-template-columns: repeat(3, minmax(0, 1fr));
    gap: 10px;
  }
  .bm-tab { width: 100%; text-align: center; padding: 12px 10px; }
}

@media (max-width: 560px) {
  .bm-tabs__list { grid-template-columns: repeat(2, minmax(0, 1fr)); }
}

.bm-panel { display: none; }
.bm-panel[data-active="true"] { display: block; }

.bm-panel__note {
  margin: 16px auto 0;
  max-width: 760px;
  text-align: center;
  color: var(--ink-soft);
  line-height: 1.65;
}

.x3-sec--dark .bm-panel__note { color: rgba(255, 255, 255, .7); }

/* ── Callout with an orange left border ──────────────────────────────────── */

.bm-callout {
  margin-top: 32px;
  padding: 20px 24px;
  border-left: 4px solid var(--accent);
  border-radius: 0 var(--r-tile) var(--r-tile) 0;
  background: var(--paper-alt);
  color: var(--ink);
  line-height: 1.7;
}

.x3-sec--dark .bm-callout {
  background: rgba(255, 255, 255, .05);
  color: rgba(255, 255, 255, .86);
}

/* ── Pinned showcase ─────────────────────────────────────────────────────── */

.bm-pinwrap { position: relative; }

.bm-pin {
  position: absolute;
  z-index: 4;
  width: 30px;
  height: 30px;
  border-radius: 50%;
  border: 0;
  cursor: pointer;
  background: var(--accent);
  color: #fff;
  font-family: var(--font-display);
  font-weight: 700;
  font-size: 14px;
  box-shadow: 0 6px 18px rgba(255, 107, 0, .45);
  display: grid;
  place-items: center;
}

.bm-pin::after {
  content: attr(data-label);
  position: absolute;
  left: 50%;
  bottom: calc(100% + 10px);
  transform: translateX(-50%) translateY(4px);
  white-space: nowrap;
  background: var(--navy-deep);
  color: #fff;
  font-family: var(--font-ui);
  font-weight: 500;
  font-size: 13px;
  padding: 8px 13px;
  border-radius: 10px;
  opacity: 0;
  pointer-events: none;
  transition: opacity .22s var(--soft), transform .22s var(--soft);
  box-shadow: var(--shadow-glass);
}

.bm-pin:hover::after,
.bm-pin:focus-visible::after,
.bm-pin[data-open="true"]::after { opacity: 1; transform: translateX(-50%) translateY(0); }

/* ── Phones row ──────────────────────────────────────────────────────────── */

.bm-phones {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: clamp(14px, 2.4vw, 30px);
  align-items: end;
  margin-top: 40px;
}

.bm-phones > *:nth-child(2),
.bm-phones > *:nth-child(3) { transform: translateY(-22px); }

/* "Swipe" hint under the phone row, shown only where the row actually scrolls */
.bm-swipe {
  display: none;
  align-items: center;
  justify-content: center;
  gap: 8px;
  margin-top: 6px;
  color: var(--ink-soft);
  font-size: 13.5px;
}

.bm-swipe svg { color: var(--accent); animation: bm-nudge 1.8s var(--soft) infinite; }

@keyframes bm-nudge { 0%, 100% { transform: translateX(0); } 50% { transform: translateX(5px); } }

@media (prefers-reduced-motion: reduce) { .bm-swipe svg { animation: none; } }

/* ── What's included checklist ───────────────────────────────────────────── */

.bm-check {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 12px 36px;
  margin: 34px 0 0;
  padding: 0;
  list-style: none;
}

.bm-check li {
  position: relative;
  padding-left: 32px;
  line-height: 1.6;
  color: var(--ink);
}

.bm-check li::before {
  content: "\2713";
  position: absolute;
  left: 0;
  top: 0;
  width: 21px;
  height: 21px;
  border-radius: 50%;
  background: rgba(255, 107, 0, .12);
  color: var(--accent);
  font-size: 12px;
  font-weight: 700;
  display: grid;
  place-items: center;
}

/* ── View the live site: a button that reads as a link out ───────────────── */

.bm-live {
  display: inline-flex;
  align-items: center;
  gap: 9px;
}

.bm-live__dot {
  width: 8px;
  height: 8px;
  border-radius: 50%;
  background: #35d07f;
  box-shadow: 0 0 0 4px rgba(53, 208, 127, .22);
  flex: none;
}

/* ── The call to action that closes every section ─────────────────────────── */

.bm-cta-row {
  display: flex;
  justify-content: center;
  margin-top: clamp(36px, 4vw, 56px);
}

.x3-sec--dark .bm-cta-row,
.x3-sec--deep .bm-cta-row { margin-top: clamp(32px, 3.5vw, 48px); }

/* ── Lightbox ────────────────────────────────────────────────────────────── */

.bm-lightbox {
  position: fixed;
  inset: 0;
  z-index: 1200;
  display: none;
  align-items: center;
  justify-content: center;
  padding: clamp(16px, 4vw, 54px);
  background: rgba(2, 16, 31, .92);
  backdrop-filter: blur(6px);
}

.bm-lightbox[data-open="true"] { display: flex; }

.bm-lightbox img {
  max-width: 100%;
  max-height: 88vh;
  border-radius: var(--r-tile);
  box-shadow: var(--shadow-lift);
}

.bm-lightbox__close {
  position: absolute;
  top: clamp(12px, 3vw, 28px);
  right: clamp(12px, 3vw, 28px);
  width: 44px;
  height: 44px;
  border: 0;
  border-radius: 50%;
  cursor: pointer;
  background: rgba(255, 255, 255, .12);
  color: #fff;
  font-size: 22px;
  line-height: 1;
}

.bm-lightbox__close:hover { background: rgba(255, 255, 255, .22); }

.bm-lightbox figcaption {
  position: absolute;
  left: 0;
  right: 0;
  bottom: clamp(10px, 3vw, 26px);
  text-align: center;
  color: rgba(255, 255, 255, .8);
  font-size: 14px;
  padding: 0 20px;
}

/* ── Video block ─────────────────────────────────────────────────────────── */

.bm-video {
  position: relative;
  margin-top: 44px;
  border-radius: var(--r-panel);
  overflow: hidden;
  background: var(--navy-deep);
  aspect-ratio: 16 / 9;
  box-shadow: var(--shadow-lift);
}

.bm-video img { width: 100%; height: 100%; object-fit: cover; display: block; }
.bm-video iframe { position: absolute; inset: 0; width: 100%; height: 100%; border: 0; }

.bm-video__play {
  position: absolute;
  inset: 0;
  display: grid;
  place-items: center;
  gap: 14px;
  border: 0;
  cursor: pointer;
  background: rgba(2, 16, 31, .45);
  color: #fff;
}

.bm-video__disc {
  width: 76px;
  height: 76px;
  border-radius: 50%;
  background: var(--accent);
  display: grid;
  place-items: center;
  box-shadow: 0 14px 40px rgba(255, 107, 0, .45);
}

.bm-video__disc::before {
  content: "";
  border-style: solid;
  border-width: 13px 0 13px 21px;
  border-color: transparent transparent transparent #fff;
  margin-left: 5px;
}

.bm-video__label { font-family: var(--font-display); font-size: 19px; font-weight: 600; }
.bm-video__note { font-size: 13.5px; color: rgba(255, 255, 255, .72); }

/* ── Responsive ──────────────────────────────────────────────────────────── */

@media (max-width: 1100px) {
  .bm-streams { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .bm-strip   { grid-template-columns: repeat(3, minmax(0, 1fr)); }
}

@media (max-width: 900px) {
  .bm-split,
  .bm-trip { grid-template-columns: minmax(0, 1fr); }
  .bm-split--rev .bm-split__media { order: 0; }
  .bm-trip__copy { order: -1; }
  .bm-steps,
  .bm-grid3 { grid-template-columns: minmax(0, 1fr); }
  .bm-grid2 { grid-template-columns: minmax(0, 1fr); }
  .bm-bento > *,
  .bm-bento > .bm-bento--lg { grid-column: span 3; }
  .bm-stack__back { position: static; width: 62%; margin: 16px auto 0; }

  /* The phone screens stay a swipe carousel, but the scrollbar is left visible
     and coloured so it is obvious there is more to the right. */
  .bm-phones {
    display: flex;
    overflow-x: auto;
    scroll-snap-type: x mandatory;
    -webkit-overflow-scrolling: touch;
    padding-bottom: 16px;
    margin-inline: calc(var(--page-gutter) * -1);
    padding-inline: var(--page-gutter);
    scrollbar-width: thin;
    scrollbar-color: var(--accent) rgba(11, 18, 32, .12);
  }
  .bm-phones::-webkit-scrollbar { height: 7px; }
  .bm-phones::-webkit-scrollbar-track { background: rgba(11, 18, 32, .10); border-radius: 999px; }
  .bm-phones::-webkit-scrollbar-thumb { background: var(--accent); border-radius: 999px; }
  .bm-phones > * {
    flex: 0 0 62%;
    scroll-snap-align: center;
    transform: none !important;
  }
  .bm-swipe { display: flex; }
}

@media (max-width: 640px) {
  .bm-streams { grid-template-columns: minmax(0, 1fr); }
  .bm-strip,
  .bm-bento { grid-template-columns: minmax(0, 1fr); }
  .bm-bento > *,
  .bm-bento > .bm-bento--lg { grid-column: span 1; }
  .bm-check { grid-template-columns: minmax(0, 1fr); }
  .bm-pin { width: 24px; height: 24px; font-size: 12px; }
}

@media (prefers-reduced-motion: reduce) {
  .bm-tab, .bm-pin::after { transition: none; }
}
