.collection {
  background: #faf8f3;
  border: 0;
  padding-block: clamp(52px, 6vw, 102px) clamp(42px, 4.8vw, 76px);
}
.collection-heading {
  display: grid;
  grid-template-columns: minmax(0, 1fr) minmax(220px, 29%);
  align-items: end;
  gap: 30px;
  margin-bottom: clamp(24px, 2.8vw, 44px);
}
.collection-kicker, .sheet-bar > span {
  font: 600 11px/1.3 "DM Sans", Arial, sans-serif;
  text-transform: uppercase;
  letter-spacing: .15em;
}
.collection-kicker { margin-bottom: 14px; color: #99362e; }
.collection-heading h2, .walkthrough-heading h2 {
  font-size: clamp(42px, 4.8vw, 76px);
  line-height: 1;
  letter-spacing: -.065em;
}
.collection-heading > p { max-width: 36ch; color: #415667; }
.collection-spread {
  display: grid;
  grid-template-columns: 1.45fr 1fr;
  grid-template-rows: 1fr 1fr;
  gap: clamp(8px, 1vw, 16px);
}
.collection-card { min-width: 0; }
.collection-card:first-child { grid-row: 1 / span 2; }
.collection-card summary {
  position: relative;
  display: grid;
  width: 100%;
  min-width: 0;
  height: 100%;
  min-height: clamp(168px, 16vw, 260px);
  isolation: isolate;
  cursor: pointer;
  list-style: none;
  background: #17364a;
  color: #fff;
}
.collection-card summary::-webkit-details-marker,
.walkthrough-rooms summary::-webkit-details-marker { display: none; }
.collection-card summary:focus-visible { outline: 3px solid var(--navy); outline-offset: 3px; z-index: 1; }
.collection-photo, .collection-photo img, .sheet-photo img, .walkthrough-stage img {
  display: block;
  width: 100%;
  height: 100%;
  object-fit: cover;
}
.collection-photo { position: absolute; inset: 0; overflow: hidden; }
.collection-card:first-child .collection-photo img { object-position: 50% 55%; }
.collection-card:nth-child(2) .collection-photo img { object-position: 50% 51%; }
.collection-card:nth-child(3) .collection-photo img { object-position: 50% 56%; }
.collection-caption {
  z-index: 1;
  align-self: end;
  display: flex;
  align-items: end;
  justify-content: space-between;
  gap: 10px;
  padding: clamp(42px, 5vw, 74px) clamp(15px, 2.2vw, 34px) clamp(15px, 1.7vw, 26px);
  background: linear-gradient(transparent, rgb(3 19 26 / .77));
}
.collection-caption strong { font-weight: 500; font-size: clamp(24px, 2.35vw, 40px); letter-spacing: -.055em; line-height: 1.05; }
.collection-card:first-child .collection-caption strong { font-size: clamp(37px, 4.2vw, 65px); }
.collection-open, .walkthrough-save, .sheet-bar button { text-decoration: underline; text-underline-offset: .3em; }
.collection-open { font-size: 13px; font-weight: 600; text-wrap: nowrap; }
.collection-card summary:is(:hover,:focus-visible) .collection-open { text-decoration-thickness: 2px; }
.collection-credit { margin-top: 10px; color: #536473; font-size: 12px; }

.collection-card[open] summary { height: auto; }
.collection-notes { padding: 22px; background: white; }
.collection :is(.collection-notes,.sheet-notes) dl { margin: 22px 0; }
.collection :is(.collection-notes,.sheet-notes) dl > div { padding-block: 12px; border-top: 1px solid #cbd0cb; }
.collection :is(.collection-notes,.sheet-notes) dt { font-weight: 600; }
.collection :is(.collection-notes,.sheet-notes) dd { margin: 4px 0 0; color: #415667; }
.collection-sheet {
  width: min(870px, calc(100% - 28px));
  max-height: min(790px, 88dvh);
  padding: 0;
  border: 0;
  overflow: auto;
  overscroll-behavior: contain;
  background: #faf8f3;
  color: var(--navy);
  box-shadow: 0 16px 80px #02132155;
}
.collection-sheet::backdrop { background: rgb(4 23 39 / 64%); }
:root:has(.collection-sheet[open]) { overflow: hidden; }
:root:has(.collection-sheet[open][data-scrollbar]) { scrollbar-gutter: stable; }
.sheet-bar {
  position: sticky;
  top: 0;
  z-index: 1;
  background: #faf8f3;
  border-bottom: 1px solid #d8d8cc;
  min-height: 50px;
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding-inline: 24px;
}
.sheet-bar > span { color: #8e342c; }
.sheet-bar button {
  min-width: 48px;
  min-height: 44px;
  padding-inline: 4px;
  font-weight: 600;
  border: none;
  background: transparent;
}
.sheet-content { display: grid; grid-template-columns: .8fr 1.2fr; }
.sheet-photo { position: relative; min-height: 100%; overflow: hidden; }
.sheet-photo img { position: absolute; inset: 0; }
.sheet-notes { padding: clamp(20px, 3vw, 42px); }
.sheet-notes h2 { margin-bottom: 12px; font-size: clamp(34px, 3.5vw, 54px); }
.sheet-notes dd, .sheet-notes p { font-size: 15px; }
@media (prefers-reduced-motion: no-preference) {
  .collection-sheet[open] { animation: collection-open 260ms cubic-bezier(.18,.79,.19,1) both; }
  @keyframes collection-open { from { opacity: 0; transform: translateY(14px); } }
}

.walkthrough {
  background: var(--navy);
  color: #fff;
  border: 0;
  padding-block: clamp(48px, 5.7vw, 90px);
}
.walkthrough-layout {
  display: grid;
  grid-template-columns: minmax(250px, .79fr) minmax(0, 1.2fr);
  grid-template-areas: "head picture" "rooms picture";
  grid-template-rows: auto 1fr;
  column-gap: clamp(38px, 6vw, 94px);
  row-gap: clamp(22px, 2.3vw, 36px);
}
.walkthrough-heading { grid-area: head; }
.walkthrough-heading .collection-kicker { color: #c7d6da; }
.walkthrough-heading h2 { max-width: 9ch; }
.walkthrough-intro { max-width: 37ch; font-size: 16px; line-height: 1.5; margin: 16px 0 0; color: #d6e1e5; }
.walkthrough-rooms { grid-area: rooms; }
.walkthrough-rooms details { border-block-start: 1px solid #ffffff45; }
.walkthrough-rooms details:last-child { border-block-end: 1px solid #ffffff45; }
.walkthrough-rooms summary {
  list-style: none;
  width: 100%;
  padding-block: 13px;
  cursor: pointer;
  font-size: clamp(18px, 1.5vw, 24px);
  font-weight: 500;
  letter-spacing: -.035em;
  color: #d9e3e8;
}
.walkthrough-rooms summary:hover { text-decoration: underline; text-underline-offset: .22em; }
.walkthrough-rooms details[open] summary { color: white; }
.walkthrough-rooms details[open] > div {
  border-left: 3px solid #f26457;
  padding-inline-start: 15px;
  margin-bottom: 18px;
}
.walkthrough-rooms p { margin-block: 5px 7px; font-size: 15px; line-height: 1.48; color: #dde5e8; }
.walkthrough-rooms .walkthrough-question { margin-top: 0; font-size: 16px; letter-spacing: -.015em; font-weight: 600; line-height: 1.38; color: white; }
.walkthrough-save {
  display: inline-flex;
  align-items: center;
  min-height: 33px;
  color: #fff;
  font-size: 14px;
  font-weight: 600;
}
.walkthrough-stage {
  position: relative;
  min-height: 385px;
  grid-area: picture;
  overflow: hidden;
  isolation: isolate;
  background: #123852;
}
.walkthrough-image { position: absolute; inset: 0; visibility: hidden; opacity: 0; }
.walkthrough-layout:not(.walkthrough-scroll):not(:has(#view-kitchen[open], #view-outdoors[open])) .room-living,
.walkthrough-layout:has(#view-kitchen[open]) .room-kitchen,
.walkthrough-layout:has(#view-outdoors[open]) .room-outdoors,
.walkthrough-scroll[data-room="living"] .room-living,
.walkthrough-scroll[data-room="kitchen"] .room-kitchen,
.walkthrough-scroll[data-room="outdoors"] .room-outdoors { opacity: 1; visibility: visible; z-index: 1; }
.walkthrough-stage .room-living { object-position: 53% 50%; }
.walkthrough-caption { display: none; }
.walkthrough-scroll .walkthrough-stage {
  position: sticky;
  top: calc(var(--masthead-height, 121px) + 22px);
  align-self: start;
  min-height: 0;
  height: min(690px, calc(100svh - var(--masthead-height, 121px) - 44px));
}
.walkthrough-scroll .walkthrough-caption {
  display: block;
  position: absolute;
  inset: auto 0 0;
  padding: 66px clamp(20px, 2.6vw, 42px) clamp(20px, 1.9vw, 30px);
  background: linear-gradient(transparent, rgb(3 22 38 / .75));
  color: white;
  font-size: clamp(24px, 2.4vw, 40px);
  line-height: 1.15;
  letter-spacing: -.042em;
  z-index: 2;
}
.walkthrough-stop {
  display: flex;
  flex-direction: column;
  justify-content: center;
  min-height: clamp(265px, 36svh, 345px);
  border-top: 1px solid #ffffff45;
  padding-block: 26px;
}
.walkthrough-stop:last-child { border-bottom: 1px solid #ffffff45; }
.walkthrough-stop h3 { color: #bdd0da; font-size: clamp(28px, 2.5vw, 42px); margin-bottom: 14px; }
.walkthrough-scroll[data-room="living"] #view-living,
.walkthrough-scroll[data-room="kitchen"] #view-kitchen,
.walkthrough-scroll[data-room="outdoors"] #view-outdoors { border-top-color: #df8c81; }
.walkthrough-scroll[data-room="living"] #view-living h3,
.walkthrough-scroll[data-room="kitchen"] #view-kitchen h3,
.walkthrough-scroll[data-room="outdoors"] #view-outdoors h3 { color: white; }
.walkthrough-stop .walkthrough-save { margin-top: 4px; }
@media (prefers-reduced-motion: no-preference) {
  .walkthrough-stop { transition: border-color 320ms ease; }
  .walkthrough-stop h3 { transition: color 320ms ease; }
  .walkthrough-stage .walkthrough-image { transition: opacity 400ms ease, visibility 0s linear 400ms; }
  .walkthrough-layout:not(.walkthrough-scroll):not(:has(#view-kitchen[open], #view-outdoors[open])) .room-living,
  .walkthrough-layout:has(#view-kitchen[open]) .room-kitchen,
  .walkthrough-layout:has(#view-outdoors[open]) .room-outdoors,
  .walkthrough-scroll[data-room="living"] .room-living,
  .walkthrough-scroll[data-room="kitchen"] .room-kitchen,
  .walkthrough-scroll[data-room="outdoors"] .room-outdoors { transition-delay: 0s; }
}
@media(max-width: 780px) {
  .collection-heading { grid-template-columns: minmax(0, 1fr); gap: 15px; }
  .collection-heading > p { max-width: 56ch; }
  .collection-caption { display: grid; gap: 6px; }
  .walkthrough-layout { column-gap: 28px; grid-template-columns: .9fr 1fr; }
}
@media(max-width: 640px) {
  .collection-spread { grid-template-columns: repeat(2, minmax(0,1fr)); grid-template-rows: auto auto; }
  .collection-card:first-child { grid-area: 1 / 1 / auto / -1; }
  .collection-card summary { min-height: 0; aspect-ratio: 1.15; }
  .collection-card:first-child summary { aspect-ratio: 1.8; }
  .collection-caption { padding: 36px 12px 14px; }
  .collection-open { font-size: 12px; }
  .collection-caption strong { font-size: clamp(20px, 4.8vw, 28px); }
  .collection-card:first-child .collection-caption { display: flex; padding: 38px 16px 16px; align-items: end; }
  .collection .collection-credit { font-size: 11px; }
  .collection-card[open] { grid-column: 1 / -1; }
  .collection-card[open] summary { aspect-ratio: 2.1; }
  .walkthrough-layout {
    grid-template-columns: minmax(0,1fr);
    grid-template-rows: auto;
    grid-template-areas: "head" "picture" "rooms";
    gap: 20px;
  }
  .walkthrough-heading h2, .walkthrough-intro { max-width: none; }
  .walkthrough-stage { min-height: 0; aspect-ratio: 1.8; }
  .walkthrough-rooms details[open] > div { margin-bottom: 14px; }
  .sheet-content { grid-template-columns: 1fr; }
  .sheet-photo { height: clamp(125px, 27vw, 180px); }
  .sheet-bar { padding-inline: 17px; }
}
@media(max-width: 360px) {
  .collection-caption { padding-inline: 9px; }
  .collection-caption strong { font-size: 19px; }
  .collection-card:first-child .collection-caption { display: grid; }
}
