/* Homes v3: the street and the City. Everything is scoped under .uh (the scene root) or body.uh-on (page switches). */
.uh {
  --uh-limestone: #e4e2d4; --uh-basalt: #3a3634; --uh-orange: #fe6722;
  --uh-ink: #e4e2d4; --uh-dim: rgba(228, 226, 212, .62);
  --uh-serif: var(--f-serif);   /* Season's serif (Master File 3.4); Instrument Serif until its files are in (assets/fonts) */
  --uh-gut: clamp(16px, 3vw, 44px); --uh-ease: cubic-bezier(.2, .7, .2, 1); --uh-swing: cubic-bezier(.22, .8, .2, 1);
  position: fixed; inset: 0; overflow: hidden; background: #3a3634; color: var(--uh-ink); -webkit-font-smoothing: antialiased;
}
/* this scene has its own City, so the global guide steps aside while it is open */

.uh button:focus-visible { outline: 2px solid var(--uh-orange); outline-offset: 4px; }
.uh-word { all: unset; cursor: pointer; min-height: 40px; display: inline-flex; align-items: center; font-size: 12px; font-weight: 500; letter-spacing: .16em; text-transform: uppercase; color: var(--uh-dim); box-shadow: inset 0 -1px 0 rgba(228, 226, 212, .22); }
.uh-word:hover { color: var(--uh-ink); }
.uh-word.lit { color: var(--uh-ink); box-shadow: inset 0 -1px 0 var(--uh-orange); }

/* the street: ATI's render, full bleed */
.uh-view { position: absolute; inset: 0; width: 100%; height: 100%; display: block; cursor: default; }
.uh-olc { position: absolute; inset: 0; width: 100%; height: 100%; pointer-events: none; opacity: 0; transition: opacity .45s var(--uh-ease); }
.uh-olc.on { opacity: 1; }
.uh-hint { position: fixed; z-index: 7; pointer-events: none; font-size: 11px; font-weight: 500; letter-spacing: .18em; text-transform: uppercase; color: var(--uh-ink); padding-bottom: 4px; box-shadow: inset 0 -1px 0 var(--uh-orange); text-shadow: 0 1px 10px rgba(0, 0, 0, .6); opacity: 0; transform: translate(16px, 14px); transition: opacity .25s; }
.uh-hint.on { opacity: 1; }
.uh-shade { position: absolute; inset: 0; pointer-events: none;
  background: linear-gradient(0deg, rgba(58, 54, 52, .86) 0%, rgba(58, 54, 52, .5) 20%, rgba(58, 54, 52, 0) 42%),
              linear-gradient(90deg, rgba(58, 54, 52, .66) 0%, rgba(58, 54, 52, .16) 30%, rgba(58, 54, 52, 0) 52%),
              linear-gradient(180deg, rgba(58, 54, 52, .5) 0%, rgba(58, 54, 52, 0) 18%); }

/* the plan: the sand pours from the plate */
.uh-plan { position: absolute; inset: 0; z-index: 4; width: 100%; height: 100%; pointer-events: none; opacity: 0; transition: opacity .7s var(--uh-ease); }
.uh-plan.on { opacity: 1; pointer-events: auto; cursor: pointer; }
.uh-planshade { position: absolute; inset: 0; z-index: 3; background: rgba(58, 54, 52, .78); opacity: 0; pointer-events: none; transition: opacity .7s var(--uh-ease); }
.uh-planshade.on { opacity: 1; }

/* Previous / Next / Garden side, under the site header */
.uh-acts { position: absolute; right: var(--uh-gut); top: calc(var(--sa-t, 0px) + 84px); z-index: 5; display: flex; gap: 22px; }

/* the list: a curved seal of home types */
.uh-list { position: absolute; left: var(--uh-gut); top: 41%; z-index: 5; width: 420px; height: 0; }
.uh-h { all: unset; position: absolute; left: 0; top: -30px; cursor: pointer; display: flex; align-items: flex-start; gap: 14px; white-space: nowrap; color: rgba(228, 226, 212, .82);
  text-shadow: 0 1px 16px rgba(0, 0, 0, .6), 0 0 2px rgba(0, 0, 0, .3); padding: 6px 10px 6px 0;
  transition: color .4s, transform .8s var(--uh-swing), opacity .6s var(--uh-ease); transform-origin: 0 50%; }
.uh-n { display: block; font-family: var(--uh-serif); font-size: 66px; font-weight: 400; line-height: .85; min-width: 34px; transform-origin: 0 85%; transition: transform .8s var(--uh-swing), text-shadow .5s, color .4s; }
.uh-h em { display: flex; flex-direction: column; gap: 9px; font-style: normal; padding-top: 6px; transition: transform .8s var(--uh-swing); }
.uh-h b { font-family: var(--uh-serif); font-size: 27px; font-weight: 400; letter-spacing: .005em; transform-origin: 0 50%; transition: letter-spacing .8s var(--uh-swing), transform .8s var(--uh-swing); }
.uh-h i { position: relative; font-style: normal; font-size: 10.5px; font-weight: 500; letter-spacing: .18em; text-transform: uppercase; color: rgba(228, 226, 212, .8); padding-bottom: 8px; display: none; }
.uh-h i::after { content: ''; position: absolute; left: 0; bottom: 0; height: 1px; width: 28px; background: var(--uh-orange); box-shadow: 0 0 8px rgba(254, 103, 34, .9); transition: width .8s var(--uh-swing); }
.uh-h.on { color: var(--uh-ink); cursor: default; }
.uh-h.on i { display: block; animation: uh-wipe .8s var(--uh-swing) both; }
@keyframes uh-wipe { from { clip-path: inset(0 100% 0 0); } to { clip-path: inset(0 0 0 0); } }
.uh-h.on .uh-n { text-shadow: 0 0 22px rgba(254, 103, 34, .75), 0 0 4px rgba(254, 103, 34, .6); }
.uh-h:not(.on):hover, .uh-h:not(.on):focus-visible { opacity: 1 !important; color: var(--uh-ink); }
.uh-h:not(.on):hover .uh-n, .uh-h:not(.on):focus-visible .uh-n { color: var(--uh-orange); }
.uh-list::before { content: ''; position: absolute; left: -14px; top: -7px; width: 7px; height: 14px; background: var(--uh-orange); clip-path: polygon(0 0, 100% 50%, 0 100%); filter: drop-shadow(0 0 6px rgba(254, 103, 34, .9)); }
.uh-list::after { content: ''; position: absolute; z-index: -1; left: -180px; top: -300px; width: 760px; height: 600px; pointer-events: none; background: radial-gradient(closest-side, rgba(58, 54, 52, .42), rgba(58, 54, 52, .18) 55%, transparent); }
/* the cursor is on the building: the title grows, the list stays usable */
.uh-list.focus .uh-h:not(.on) { opacity: .35 !important; }
.uh-list.focus .uh-h.on .uh-n { transform: scale(1.35); text-shadow: 0 0 34px rgba(254, 103, 34, .9), 0 0 6px rgba(254, 103, 34, .7); }
.uh-list.focus .uh-h.on em { transform: translateX(12px); }
.uh-list.focus .uh-h.on b { transform: scale(1.18); letter-spacing: .04em; }
.uh-list.focus .uh-h.on i::after { width: 100%; }

.uh-cap { position: absolute; right: var(--uh-gut); bottom: 12px; z-index: 5; margin: 0; font-size: 10.5px; color: rgba(228, 226, 212, .45); }


@media (max-width: 760px) {
  .uh-acts { left: var(--uh-gut); right: auto; gap: 16px; top: calc(var(--sa-t, 0px) + 70px); }
  .uh-word { font-size: 10.5px; }
  .uh-list { top: auto; bottom: 270px; left: 50%; width: 0; }
  .uh-list::after { display: none; }
  .uh-list::before { left: -4px; top: 66px; width: 12px; height: 7px; clip-path: polygon(0 100%, 50% 0, 100% 100%); }
  .uh-h { left: -30px; width: 60px; top: -24px; padding: 6px 0; flex-direction: column; align-items: center; gap: 6px; transform-origin: 50% 50%; }
  .uh-h em { display: none; }
  .uh-h.on em { display: flex; align-items: center; padding: 0; }
  .uh-h.on b { font-family: inherit; font-size: 11px; font-weight: 500; letter-spacing: .18em; text-transform: uppercase; }
  .uh-h.on i { display: none; }
  .uh-n { font-size: 40px; text-align: center; }
  .uh-cap { display: none; }
}
@media (prefers-reduced-motion: reduce) {
  .uh-h, .uh-n, .uh-h em, .uh-h b { transition: none; }
}

/* Production links and rendering fallbacks. */
body.uh-on .top .logo img { filter: brightness(0) invert(1); }
body.uh-on { --guide-h: 0px; }
.uh [hidden] { display: none !important; }
.uh-morph, .uh-open { position: absolute; inset: 0; width: 100%; height: 100%; }
.uh-open { cursor: pointer; touch-action: pan-y; }
.uh-open:focus-visible { outline: 2px solid var(--uh-orange); outline-offset: -6px; }
.uh-open:focus-visible ~ .uh-hint { opacity: 1; left: 50% !important; top: 40% !important; }
.uh-model { position: absolute; right: var(--uh-gut); bottom: 64px; z-index: 5; color: white; gap: 16px; text-decoration: none; }
.uh-count { align-self: center; font-size: 10px; letter-spacing: .14em; direction: ltr; opacity: .65; }
.uh-status { position: absolute; top: 140px; right: var(--uh-gut); max-width: 30ch; z-index: 5; }
[dir=rtl] .uh-model { right: auto; left: var(--uh-gut); }
[dir=rtl] .uh-h b { font-family: inherit; }
@media (max-width: 760px) {
  .uh-model { bottom: 370px; right: var(--uh-gut); }
  .uh-list { bottom: 280px; }
  .uh-word { min-height: 44px; }
  .uh-acts { gap: 15px; right: var(--uh-gut); }
  .uh-h { min-height: 54px; }
  .uh-shade { background: linear-gradient(0deg,rgba(58,54,52,.96),rgba(58,54,52,.64) 26%,transparent 66%),linear-gradient(180deg,rgba(58,54,52,.4),transparent 24%); }
}
@media (max-height: 600px) and (orientation: landscape) {
  .uh-list { top: 36%; bottom: auto; }
  .uh-n { font-size: 38px; }
  .uh-h b { font-size: 21px; }
  .uh-model { bottom: 36px; }
}
@media (prefers-reduced-motion: reduce) {
  .uh *, .uh *::after { animation: none !important; transition: none !important; }
}
@media (max-width: 760px) and (orientation: portrait) {
  .uh-list { bottom: calc(var(--uh-city-height, 210px) + 110px); }
  .uh-model { bottom: calc(var(--uh-city-height, 210px) + 225px); }
}
@media (max-height: 600px) and (orientation: landscape) {
  .uh-list { top: 33%; }
  .uh-h:not(.on) { visibility: hidden !important; pointer-events: none; }
}
@media (max-width: 360px) {
  body.uh-on .top { gap: 8px; }
  body.uh-on .logo img { height: 26px; }
  body.uh-on #map-btn { font-size: 0; gap: 0; padding: 0; width: 34px; min-width: 34px; }
  .uh-acts { gap: 10px; }
  .uh-acts .uh-word { font-size: 9.5px; letter-spacing: .1em; }
}
@media (max-width: 760px) and (max-height: 700px) and (orientation: portrait) {
  .uh-model { top: 130px; bottom: auto; }
}

/* ---- the UX pass (16 Oct 2026): words that read over the picture, one guide, a loading state ---- */
/* labels: 12 px at least, brighter, less tracking; Arabic letters stay joined (no tracking, no capitals) */
.uh-word { font-size: 12px; letter-spacing: .1em; color: rgba(228, 226, 212, .9); text-shadow: 0 1px 10px rgba(0, 0, 0, .55); }
.uh-h i { font-size: 12px; letter-spacing: .1em; color: rgba(228, 226, 212, .92); }
.uh-city-label, .uh-count, .uh-cap { font-size: 12px; }
.uh-cap { color: rgba(228, 226, 212, .7); }
@media (max-width: 760px) { .uh-word { font-size: 12px; } .uh-h.on b { font-size: 13px; letter-spacing: .12em; } }
:is([lang="ar"], [dir="rtl"]) .uh :is(.uh-word, .uh-h i, .uh-h b, .uh-city-label, .uh-count, .uh-hint) { letter-spacing: 0 !important; text-transform: none; }
/* the top bar's ground, over the street's sky: the top of the picture darkens a little more */
.uh-shade { background:
  linear-gradient(0deg, rgba(58, 54, 52, .86) 0%, rgba(58, 54, 52, .5) 20%, rgba(58, 54, 52, 0) 42%),
  linear-gradient(90deg, rgba(58, 54, 52, .66) 0%, rgba(58, 54, 52, .16) 30%, rgba(58, 54, 52, 0) 52%),
  linear-gradient(180deg, rgba(58, 54, 52, .62) 0%, rgba(58, 54, 52, .2) 16%, rgba(58, 54, 52, 0) 26%); }
@media (max-width: 760px) {
  .uh-shade { background: linear-gradient(0deg, rgba(58, 54, 52, .96), rgba(58, 54, 52, .64) 26%, transparent 66%), linear-gradient(180deg, rgba(58, 54, 52, .62), rgba(58, 54, 52, .2) 16%, transparent 28%); }
}
/* while the first picture comes: the mark turning, and a word */
.uh-loading { position: absolute; inset: 0; z-index: 2; display: grid; place-content: center; justify-items: center; gap: 14px; margin: 0; color: rgba(228, 226, 212, .85); font-size: 14px; }
.uh-loading::before { content: ""; width: 34px; height: 34px; background: url('../../assets/mark-light.svg') center / contain no-repeat; animation: tick .9s var(--ease) infinite; }
.uh[data-ready] .uh-loading { display: none; }
@media (prefers-reduced-motion: reduce) { .uh-loading::before { animation: none; } }
/* Help me choose (homes/fit.js), beside the guide's name: a light pill, always in view */
/* a picture shared by several homes says so on phones too, under the bar's row of words */
@media (max-width: 760px) { .uh[data-shared] .uh-cap { display: block; left: var(--uh-gut); right: var(--uh-gut); top: calc(var(--sa-t, 0px) + 166px); bottom: auto; } }
/* the street's words on one line on a phone, the caption under them */
@media (max-width: 760px) { .uh-acts .uh-word { font-size: 10.5px; letter-spacing: .12em; white-space: nowrap; } .uh-acts { gap: 12px; } }
