/* Home page, section 1: the opening (headline, three room photos, trades ribbon) and its entrance motion. */

/* ---------- 1. hero ---------- */
.hero { padding: calc(var(--nav) + 44px) 0 0; overflow-x: clip; }
.hero__h1 { margin-top: 18px; font-size: clamp(46px, 7.6vw, 124px); line-height: .98; letter-spacing: -.045em; }
.hero__h1 .w { display: inline-block; overflow: hidden; padding-bottom: .08em; margin-bottom: -.08em; vertical-align: top; }
.hero__h1 .w > span { display: inline-block; }
.hero__body { margin-top: 40px; display: grid; grid-template-columns: 4fr 8fr; gap: 56px; align-items: end; }
.hero__side { padding-bottom: 8px; }
.hero__lead { font-size: clamp(20px, 1.6vw, 24px); color: var(--ink); max-width: 26ch; text-wrap: balance; }
.hero .btn--cta { margin-top: 28px; }
.facts { margin-top: 36px; display: grid; gap: 16px; border-top: 1px solid var(--line); padding-top: 20px; }
.facts div { display: flex; gap: 14px; align-items: center; }
.facts dt { font-size: 44px; font-weight: 300; line-height: 1; color: var(--deep); min-width: 40px; text-align: center; }
.facts dd { font-size: 15.5px; line-height: 1.45; }
.facts__mark svg { width: 38px; height: 38px; color: var(--deep); display: block; margin-inline: auto; }

/* three real rooms, staggered like a magazine spread; heights fixed up front so nothing shifts.
   Desktop runs them tall (portrait photos), so the rooms show nearly whole */
.tri { display: grid; grid-template-columns: 1.55fr 1fr 1fr; gap: 14px; align-items: start; height: clamp(360px, 50svh, 600px); }
.tri figure { position: relative; overflow: hidden; height: 100%; background: var(--sand); }
.tri__b { margin-top: 56px; height: calc(100% - 56px) !important; }
.tri__c { margin-top: 24px; height: calc(100% - 24px) !important; }
.tri img { width: 100%; height: 100%; object-fit: cover; }
.tri__a img { object-position: 50% 30%; }

/* trades ribbon */
.ticker { margin-top: 48px; border-block: 1px solid var(--line); overflow: hidden; padding: 16px 0; }
.ticker__run { display: flex; width: max-content; animation: ticker 60s linear infinite; }
.ticker span { font-size: 20px; font-weight: 400; color: var(--ink); white-space: nowrap; display: inline-flex; align-items: center; gap: 28px; padding-inline-end: 28px; }
.ticker span::after { content: ""; width: 6px; height: 6px; border-radius: 50%; background: var(--gold); }
@keyframes ticker { to { transform: translateX(50%); } }   /* RTL: the row drifts toward the right */

@media (max-width: 1023px) {
  .hero__h1 .light { display: block; }
  .hero__body { grid-template-columns: 1fr; gap: 32px; }
  .tri { order: -1; height: clamp(240px, 30svh, 340px); }
  .facts { grid-template-columns: 1fr 1fr; }
  .hero__lead { max-width: none; }
}
@media (max-width: 639px) {
  .hero { padding-top: calc(var(--nav) + 26px); }
  .hero__h1 { font-size: 46px; margin-top: 12px; }
  .hero__body { margin-top: 22px; gap: 22px; }
  .tri { height: 170px; gap: 8px; grid-template-columns: 1.4fr 1fr 1fr; }
  .tri__b { margin-top: 28px; height: calc(100% - 28px) !important; }
  .tri__c { margin-top: 12px; height: calc(100% - 12px) !important; }
  .hero__lead { font-size: 19px; }
  .hero .btn--cta { margin-top: 20px; display: flex; }
  .facts { margin-top: 22px; grid-template-columns: 1fr 1fr; gap: 12px; }
  .facts dt { font-size: 32px; min-width: 30px; }
  .facts__mark svg { width: 30px; height: 30px; }
  .facts dd { font-size: 14px; }
  .ticker { margin-top: 28px; padding: 12px 0; }
  .ticker span { font-size: 16px; gap: 20px; padding-inline-end: 20px; }
}

/* short laptop screens: a slightly tighter hero, so the next section still peeks */
@media (min-width: 1024px) and (max-height: 820px) {
  .hero { padding-top: calc(var(--nav) + 26px); }
  .hero__h1 { font-size: clamp(46px, 6.4vw, 100px); margin-top: 12px; }
  .hero__body { margin-top: 30px; }
  .tri { height: clamp(320px, 46svh, 420px); }
  .ticker { margin-top: 36px; }
}

/* hero entrance, once on load: words rise from a mask, rooms open from the bottom one after another */
.js [data-enter] .hero__h1 .w > span { transform: translateY(110%); }
.js [data-enter] .tri img { clip-path: inset(100% 0 0 0); transform: scale(1.06); }
.js [data-enter] :is(.kicker, .hero__side) { opacity: 0; transform: translateY(14px); }
.js .is-in .hero__h1 .w > span { transform: none; transition: transform .95s var(--ease); }
.js .is-in .hero__h1 .w:nth-child(2) > span { transition-delay: .07s; }
.js .is-in .hero__h1 .light .w:nth-child(1) > span { transition-delay: .14s; }
.js .is-in .hero__h1 .light .w:nth-child(2) > span { transition-delay: .21s; }
.js .is-in .tri img { clip-path: inset(0 0 0 0); transform: none; transition: clip-path 1.2s var(--ease), transform 1.6s var(--ease); }
.js .is-in .tri__b img { transition-delay: .12s; }
.js .is-in .tri__c img { transition-delay: .24s; }
.js .is-in :is(.kicker, .hero__side) { opacity: 1; transform: none; transition: opacity .8s var(--ease) .3s, transform .8s var(--ease) .3s; }
.js .is-in .hero__side .btn--cta { transition: background-color .2s var(--ease), transform .16s var(--press), box-shadow .2s var(--ease); }

/* scroll-linked motion where the browser supports it (Chrome, Edge, Safari 26); elsewhere everything simply rests */
@supports (animation-timeline: scroll()) {
  /* rooms drift at different speeds as the page leaves the hero */
  .tri figure { animation: drift linear both; animation-timeline: scroll(root); animation-range: 0 100vh; }
  .tri__a { --drift: -36px; } .tri__b { --drift: -84px; } .tri__c { --drift: -56px; }
  @keyframes drift { to { transform: translateY(var(--drift)); } }
  /* headings and steps rise gently as they enter, once per pass, transform + opacity only */
  .reveal { animation: rise linear both; animation-timeline: view(); animation-range: entry 0% entry 55%; }
  @keyframes rise { from { opacity: 0; transform: translateY(28px); } }
}
