/* Blue Ridge Estate demo: a full-bleed aerial with homesites, a configurator, rooms in 360°.
   Uses the site tokens; the one accent stays brass. Status colours are muted so the photograph leads. */
.es-page { --st-available: #C9A46A; --st-model: #EAE5D8; --st-reserved: #C9765E; --st-sold: #5B6660; }

/* ---------------- the map ---------------- */
.es-map { position: relative; height: 100svh; min-height: 620px; overflow: hidden; background: #0d1512; }
.es-scroll { position: absolute; inset: 0; overflow: hidden; }
.es-canvas {
  position: absolute; left: 50%; top: 50%; width: max(100%, 150svh, 930px); aspect-ratio: 3 / 2;
  transform: translate(-50%, -50%) scale(var(--zoom, 1.08)); transform-origin: var(--ox, 50%) var(--oy, 50%);
  transition: transform 2.4s var(--ease-out);
}
.es-ready .es-canvas { --zoom: 1; }
.es-aerial { position: absolute; inset: 0; width: 100%; height: 100%; object-fit: cover; }
.es-veil { position: absolute; inset: 0; pointer-events: none;
  background: linear-gradient(180deg, rgba(10, 16, 13, .7) 0%, rgba(10, 16, 13, .1) 30%, rgba(10, 16, 13, 0) 60%, rgba(10, 16, 13, .6) 100%); }
.es-veil::before { content: ""; position: absolute; inset: 0; background: linear-gradient(90deg, rgba(10, 16, 13, .8) 0%, rgba(10, 16, 13, .55) 32%, rgba(10, 16, 13, 0) 58%); transition: opacity 1.2s var(--ease-out); }
@media (max-width: 760px) { .es-veil { background: linear-gradient(180deg, rgba(10, 16, 13, .82) 0%, rgba(10, 16, 13, .45) 42%, rgba(10, 16, 13, 0) 62%, rgba(10, 16, 13, .6) 100%); } .es-veil::before { display: none; } }
.es-over { position: absolute; inset: 0; pointer-events: none; display: flex; flex-direction: column; justify-content: space-between;
  padding-block: calc(96px + env(safe-area-inset-top, 0px)) 28px; }
.es-head { max-width: 640px; }
.es-kicker { font-size: var(--fs-xs); letter-spacing: .14em; text-transform: uppercase; color: var(--ivory-2); display: flex; gap: 12px; align-items: center; }
.es-kicker span { color: var(--wall); background: var(--brass); padding: 3px 9px 2px; letter-spacing: .12em; font-weight: 600; }
.es-head h1 { font-size: var(--fs-3xl); margin-top: 18px; }
.es-head h1 em, .es-page h2 em { font-style: italic; color: var(--brass); }
.es-lede { margin-top: 18px; max-width: 46ch; color: var(--ivory); font-size: var(--fs-l); line-height: 1.45; text-shadow: 0 1px 18px rgba(0, 0, 0, .5); }
.es-legend { list-style: none; margin: 0; padding: 0; display: flex; flex-wrap: wrap; gap: 8px 22px; font-size: var(--fs-s); }
.es-legend li { display: flex; align-items: center; gap: 8px; }
.es-legend b { font-weight: 500; color: var(--ivory-2); font-variant-numeric: tabular-nums; }
.es-legend .sw, .es-tip .sw { width: 10px; height: 10px; border-radius: 50%; background: var(--c); box-shadow: 0 0 0 3px rgba(0, 0, 0, .25); }
.s-available { --c: var(--st-available); } .s-model { --c: var(--st-model); } .s-reserved { --c: var(--st-reserved); } .s-sold { --c: var(--st-sold); }
.es-hint { position: absolute; right: var(--gutter); bottom: 28px; font-size: var(--fs-s); display: flex; align-items: center; gap: 10px; color: var(--ivory); }
.es-hint-dot { width: 10px; height: 10px; border-radius: 50%; background: var(--brass); box-shadow: 0 0 0 0 rgba(201, 164, 106, .7); animation: es-ping 1.8s infinite; }
@keyframes es-ping { 0% { box-shadow: 0 0 0 0 rgba(201, 164, 106, .7); } 80%, 100% { box-shadow: 0 0 0 14px rgba(201, 164, 106, 0); } }

.es-pins { position: absolute; inset: 0; }
.es-pin {
  position: absolute; left: var(--x); top: var(--y); width: 46px; height: 46px; margin: -62px 0 0 -23px; padding: 0; border: 0; background: none; cursor: pointer;
  opacity: 0; transform: translateY(-14px) scale(.6); transition: opacity .5s var(--ease-out), transform .7s cubic-bezier(.34, 1.56, .64, 1);
  transition-delay: calc(700ms + var(--i) * 70ms);
}
.es-ready .es-pin { opacity: 1; transform: none; }
.es-pin::after { /* the stem down to the house */
  content: ""; position: absolute; left: 50%; top: 40px; width: 1.5px; height: 22px; background: rgba(234, 229, 216, .85); transform: translateX(-50%); }
.es-pin::before { /* the ground dot */
  content: ""; position: absolute; left: 50%; top: 60px; width: 8px; height: 8px; margin-left: -4px; border-radius: 50%; background: rgba(10, 16, 13, .7); }
.es-pin-n {
  position: absolute; inset: 0; display: grid; place-items: center; border-radius: 50%; background: var(--c); color: var(--wall);
  font: 700 16px/1 var(--f-sans); box-shadow: 0 0 0 3px rgba(10, 16, 13, .55), 0 8px 24px rgba(0, 0, 0, .35);
  transition: transform .45s var(--ease-out), box-shadow .45s var(--ease-out);
}
.es-pin.s-sold .es-pin-n { color: var(--ivory); }
.es-pin.s-model .es-pin-n::after { content: ""; position: absolute; inset: -7px; border-radius: 50%; border: 1.5px solid var(--ivory); animation: es-ring 2.4s var(--ease-out) infinite; }
@keyframes es-ring { from { transform: scale(.85); opacity: .9; } to { transform: scale(1.5); opacity: 0; } }
.es-pin:hover .es-pin-n, .es-pin:focus-visible .es-pin-n, .es-pin[aria-current="true"] .es-pin-n { transform: scale(1.18); box-shadow: 0 0 0 3px var(--brass), 0 10px 30px rgba(0, 0, 0, .45); }
.es-pin:focus-visible { outline: none; }

.es-tip {
  position: absolute; z-index: 5; width: 280px; padding: 16px 18px 18px; background: rgba(13, 21, 18, .94); border: 1px solid rgba(201, 164, 106, .45);
  box-shadow: 0 20px 50px rgba(0, 0, 0, .45); pointer-events: none; transform-origin: 50% 100%;
  animation: es-tip .32s var(--ease-out);
}
@keyframes es-tip { from { opacity: 0; transform: translateY(8px) scale(.96); } }
.es-tip h3 { font-size: 1.5rem; }
.es-tip p { font-size: var(--fs-s); color: var(--ivory-2); margin-top: 4px; }
.es-tip .st { display: flex; align-items: center; gap: 8px; font-size: var(--fs-xs); letter-spacing: .12em; text-transform: uppercase; margin-top: 10px; }
.es-tip .go { margin-top: 12px; font-size: var(--fs-s); color: var(--brass); }

@media (max-width: 760px) {
  .es-map { height: 88svh; }
  .es-scroll { overflow-x: auto; overflow-y: hidden; scrollbar-width: none; -webkit-overflow-scrolling: touch; }
  .es-scroll::-webkit-scrollbar { display: none; }
  .es-canvas { position: relative; left: 0; top: 0; height: 100%; width: auto; transform: none; transition: none; }
  .es-over { pointer-events: none; }
  .es-head h1 { font-size: clamp(2.75rem, 13vw, 4rem); }
  .es-lede { font-size: var(--fs-m); }
  .es-hint { display: none; }
  .es-pin { width: 40px; height: 40px; margin: -56px 0 0 -20px; }
  .es-pin::after { top: 36px; height: 18px; } .es-pin::before { top: 52px; }
}

/* ---------------- the home ---------------- */
.es-home { padding-block: clamp(72px, 9vw, 140px) clamp(56px, 7vw, 110px); }
.es-home-head { display: grid; grid-template-columns: 1fr auto; gap: 24px 56px; align-items: end; margin-bottom: 36px; }
.es-home-head h2 { font-size: var(--fs-2xl); margin-top: 10px; }
.es-crumb { font-size: var(--fs-s); color: var(--ivory-2); display: flex; align-items: center; gap: 10px; flex-wrap: wrap; }
.es-status-pill { display: inline-flex; align-items: center; gap: 8px; font-size: var(--fs-xs); letter-spacing: .12em; text-transform: uppercase; color: var(--ivory); }
.es-status-pill::before { content: ""; width: 9px; height: 9px; border-radius: 50%; background: var(--c); }
.es-specs { display: flex; gap: 0; border-top: 1px solid var(--hair); }
.es-specs > div { padding: 12px 22px 0 0; margin-right: 22px; }
.es-specs dt { font-size: var(--fs-xs); color: var(--ivory-2); }
.es-specs dd { font-size: var(--fs-m); font-variant-numeric: tabular-nums; }

.es-config { display: grid; grid-template-columns: minmax(0, 1fr) 360px; gap: 28px; align-items: start; }
.es-stage { position: relative; margin: 0; aspect-ratio: 3 / 2; overflow: hidden; background: #0d1512; }
.es-stage:fullscreen { aspect-ratio: auto; width: 100vw; height: 100vh; }
.es-stack { position: absolute; inset: 0; }
.es-stack img { position: absolute; inset: 0; width: 100%; height: 100%; object-fit: cover; opacity: 0; will-change: opacity; }
.es-stack img.l-day { opacity: 1; }
.es-stack.is-entering { clip-path: inset(0 100% 0 0); }
.es-stack.is-entering.go { clip-path: inset(0 0 0 0); transition: clip-path 1.1s var(--ease); }
.es-line { /* the developing line rides the edge of the wipe */
  position: absolute; top: 0; bottom: 0; left: 0; width: 2px; z-index: 3; background: var(--brass); pointer-events: none;
  box-shadow: 0 0 18px 4px rgba(201, 164, 106, .55); opacity: 0; }
.es-line.go { left: 100%; opacity: 1; transition: left 1.1s var(--ease), opacity .2s; animation: es-line-out 1.25s linear forwards; }
@keyframes es-line-out { 0%, 85% { opacity: 1; } 100% { opacity: 0; } }
.es-cap { position: absolute; left: 0; right: 0; bottom: 0; display: flex; justify-content: space-between; gap: 12px; padding: 40px 20px 16px;
  background: linear-gradient(180deg, rgba(10, 16, 13, 0), rgba(10, 16, 13, .6)); font-size: var(--fs-s); pointer-events: none; }
.es-cap-time { font-variant-numeric: tabular-nums; letter-spacing: .04em; }
.es-full { position: absolute; right: 14px; top: 14px; width: 42px; height: 42px; display: grid; place-items: center; border: 1px solid rgba(234, 229, 216, .35);
  background: rgba(13, 21, 18, .55); color: var(--ivory); cursor: pointer; }
.es-full svg { width: 18px; height: 18px; fill: none; stroke: currentColor; stroke-width: 1.5; }

.es-panel { display: grid; gap: 28px; }
.es-group h3 { font: 500 var(--fs-xs)/1 var(--f-sans); letter-spacing: .14em; text-transform: uppercase; color: var(--ivory-2); margin-bottom: 14px; }
.es-time { display: grid; gap: 10px; }
.es-time input[type=range] { -webkit-appearance: none; appearance: none; width: 100%; height: 34px; background: transparent; cursor: pointer; margin: 0; }
.es-time input[type=range]::-webkit-slider-runnable-track { height: 6px; border-radius: 3px; background: linear-gradient(90deg, #F2D49B 0%, #D98B4F 50%, #1E2B4A 100%); }
.es-time input[type=range]::-moz-range-track { height: 6px; border-radius: 3px; background: linear-gradient(90deg, #F2D49B 0%, #D98B4F 50%, #1E2B4A 100%); }
.es-time input[type=range]::-webkit-slider-thumb { -webkit-appearance: none; width: 26px; height: 26px; margin-top: -10px; border-radius: 50%; background: var(--ivory); border: 3px solid var(--wall); box-shadow: 0 0 0 1.5px var(--brass), 0 4px 14px rgba(0, 0, 0, .4); }
.es-time input[type=range]::-moz-range-thumb { width: 22px; height: 22px; border-radius: 50%; background: var(--ivory); border: 3px solid var(--wall); box-shadow: 0 0 0 1.5px var(--brass); }
.es-ticks { display: flex; justify-content: space-between; font-size: var(--fs-xs); color: var(--ivory-2); letter-spacing: .1em; text-transform: uppercase; }
.es-play { justify-self: start; background-color: transparent; border: 0; color: var(--ivory); font: inherit; font-size: var(--fs-s); cursor: pointer; padding: 0 0 4px; }

.es-sws { display: grid; gap: 8px; }
.es-sw { display: grid; grid-template-columns: 56px 1fr; gap: 14px; align-items: center; padding: 8px; border: 1px solid var(--hair); background: transparent; color: var(--ivory);
  text-align: left; cursor: pointer; font: inherit; transition: border-color .35s, background-color .35s; }
.es-sw img { width: 56px; height: 56px; object-fit: cover; }
.es-sw b { display: block; font-weight: 500; font-size: var(--fs-s); }
.es-sw small { display: block; font-size: var(--fs-xs); color: var(--ivory-2); line-height: 1.4; margin-top: 2px; }
.es-sw[aria-pressed="true"] { border-color: var(--brass); background: rgba(201, 164, 106, .08); }
@media (hover: hover) and (pointer: fine) { .es-sw:hover { border-color: rgba(201, 164, 106, .6); } }
.es-note { font-size: var(--fs-xs); color: var(--ivory-2); margin-top: 10px; }
.es-ask { width: 100%; }

@media (max-width: 1100px) {
  .es-config { grid-template-columns: 1fr; }
  .es-panel { grid-template-columns: 1fr 1fr; }
  .es-panel .es-group:first-child, .es-ask { grid-column: 1 / -1; }
}
@media (max-width: 760px) {
  .es-home-head { grid-template-columns: 1fr; }
  .es-specs { flex-wrap: wrap; }
  .es-specs > div { margin-right: 0; padding-right: 18px; }
  .es-panel { grid-template-columns: 1fr; }
  .es-stage { aspect-ratio: 4 / 3; }
  .es-sws { grid-template-columns: 1fr; }
}

/* ---------------- inside ---------------- */
.es-inside { padding-block: 0 clamp(72px, 9vw, 140px); }
.es-inside .head-row { margin-bottom: 28px; }
.es-tabs { display: flex; flex-wrap: wrap; gap: 0; border-bottom: 1px solid var(--hair); margin-bottom: 20px; }
.es-tabs button { position: relative; background: none; border: 0; color: var(--ivory-2); font: 500 var(--fs-s)/1 var(--f-sans); padding: 16px 22px 18px 0; margin-right: 10px; cursor: pointer; }
.es-tabs button[aria-selected="true"] { color: var(--ivory); }
.es-tabs button::after { content: ""; position: absolute; left: 0; right: 22px; bottom: -1px; height: 2px; background: var(--brass); transform: scaleX(0); transform-origin: 0 50%; transition: transform .5s var(--ease-out); }
.es-tabs button[aria-selected="true"]::after { transform: scaleX(1); }
.b360 { font-size: .75em; color: var(--brass); margin-left: 4px; }
.es-room { position: relative; aspect-ratio: 3 / 2; overflow: hidden; background: #0d1512; }
.es-room-img { position: absolute; inset: 0; width: 100%; height: 100%; object-fit: cover; opacity: 0; transform: scale(1.04); transition: opacity .9s var(--ease-out), transform 1.6s var(--ease-out); }
.es-room-img.is-on { opacity: 1; transform: none; }
.es-hot { position: absolute; left: var(--x); top: var(--y); display: flex; align-items: center; gap: 10px; padding: 0; border: 0; background: none; color: var(--ivory); cursor: pointer; transform: translate(-21px, -21px); font: inherit; }
.es-hot-dot { position: relative; width: 42px; height: 42px; border-radius: 50%; background: var(--brass); box-shadow: 0 0 0 3px rgba(10, 16, 13, .5); }
.es-hot-dot::before { content: ""; position: absolute; inset: 15px; border-radius: 50%; background: var(--wall); }
.es-hot-dot::after { content: ""; position: absolute; inset: -6px; border-radius: 50%; border: 2px solid var(--brass); animation: es-ring 1.8s var(--ease-out) infinite; }
.es-hot-t { padding: 9px 16px; background: rgba(13, 21, 18, .82); border: 1px solid rgba(201, 164, 106, .6); font-size: var(--fs-s); white-space: nowrap; }
.es-pano { position: absolute; inset: 0; }
.es-pano canvas { width: 100%; height: 100%; display: block; cursor: grab; touch-action: none; }
.es-pano canvas:active { cursor: grabbing; }
.es-pano-hint { position: absolute; left: 50%; bottom: 22px; transform: translateX(-50%); padding: 9px 16px; background: rgba(13, 21, 18, .8); font-size: var(--fs-s); pointer-events: none; transition: opacity .5s; }
.es-pano.is-touched .es-pano-hint { opacity: 0; }
@media (max-width: 760px) { .es-room { aspect-ratio: 4 / 5; } .es-hot-t { display: none; } }

/* ---------------- what a builder gets ---------------- */
.es-steps { list-style: none; margin: 0; padding: 0; display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); gap: 32px; }
.es-steps li { border-top: 1px solid var(--hair); padding-top: 22px; }
.es-steps h3 { font-size: var(--fs-l); margin-bottom: 10px; }
.es-steps p { color: var(--ivory-2); font-size: var(--fs-s); }
.es-also { margin-top: 48px; color: var(--ivory-2); }
@media (max-width: 1000px) { .es-steps { grid-template-columns: 1fr 1fr; } }
@media (max-width: 600px) { .es-steps { grid-template-columns: 1fr; } }
.es-fine { padding-block: 22px; font-size: var(--fs-xs); color: var(--ivory-2); }

@media (prefers-reduced-motion: reduce) {
  .es-canvas, .es-pin, .es-room-img, .es-stack.is-entering.go { transition: none !important; }
  .es-hint-dot, .es-pin.s-model .es-pin-n::after, .es-hot-dot::after { animation: none; }
}

/* the intro steps aside once the homesites have landed: the big title lifts away and a small one
   settles above the legend, where no homesite sits */
.es-head { transition: opacity .7s ease, transform 1s var(--ease-out); }
.es-mini { margin: 0 0 14px; font: 300 var(--fs-xl)/1.1 var(--f-serif); color: var(--ivory); text-shadow: 0 1px 16px rgba(0, 0, 0, .5);
  opacity: 0; transform: translateY(16px); transition: opacity .7s ease .35s, transform 1s var(--ease-out) .35s; }
.es-mini em { font-style: italic; }
.es-mini span { display: block; margin-top: 6px; font: 400 var(--fs-xs)/1.3 var(--f-sans); color: var(--ivory-2); }
.es-compact .es-head { opacity: 0; transform: translateY(-28px); pointer-events: none; }
.es-compact .es-mini { opacity: 1; transform: none; }
.es-compact .es-veil::before { opacity: 0; }
@media (max-width: 760px) {
  .es-compact .es-veil { background: linear-gradient(180deg, rgba(10, 16, 13, .55) 0%, rgba(10, 16, 13, 0) 18%, rgba(10, 16, 13, 0) 66%, rgba(10, 16, 13, .7) 100%); }
}
@media (prefers-reduced-motion: reduce) { .es-head, .es-mini, .es-veil::before { transition: none; } }

/* keep the top row of homesites clear of the fixed header */
@media (min-width: 761px) { .es-canvas { top: calc(50% + 38px); } }
