/* Rose Park Apartments — landing page
   Day and night are two versions of the same page. Every block that changes holds both versions
   stacked in one place (.swap > .is-day + .is-night); html[data-mode] decides which one shows. */

:root {
  /* day: paper, brown ink, the brochure's bronze */
  --paper: #f1f0ed;
  --surface: #e4e2dd;
  --sky: #dde6ee;
  --ink: #2b231d;
  --muted: #6b5d52;
  --accent: #7a5b43;
  --accent-ink: #f1f0ed;
  --on-photo: #f1f0ed;

  /* night: the dusk sky in the twilight photographs, stepping down to the road */
  --dusk-1: #ecdcd6;
  --dusk-1-ink: #2a2421;
  --dusk-2: #c6cad4;
  --dusk-2-ink: #22252b;
  --dusk-3: #5b5f6b;
  --dusk-3-ink: #efeeea;
  --dusk-4: #26262b;
  --dusk-4-ink: #efe9df;
  --night: #17171a;
  --glow: #d6aa80;

  /* Brand fonts: Sweet Sans Pro for display (the logo font), Aktiv Grotesk for text. "sweet-sans-pro" and
     "aktiv-grotesk" are the names an Adobe Fonts web project serves. Until that project's stylesheet is linked in
     the page head, the page falls through to Fraunces and Montserrat. */
  --font-display: "sweet-sans-pro", "Fraunces", "Iowan Old Style", Georgia, serif;
  --font-text: "aktiv-grotesk", "Montserrat", "Helvetica Neue", Arial, sans-serif;

  /* five sizes: small 14, body 17, lead 22, mid 30, head 84 */
  --step-small: 0.875rem;
  --step-body: 1.0625rem;
  --step-lead: 1.375rem;
  --step-mid: clamp(1.3rem, 1.05rem + 0.85vw, 1.625rem);
  --step-head: clamp(2.3rem, 1.2rem + 4.1vw, 4.4rem);

  --margin: clamp(1.25rem, 5vw, 5rem);
  --gutter: clamp(1rem, 2vw, 2rem);
  --section: clamp(7rem, 12vw, 12rem);

  --ease-out: cubic-bezier(0.22, 1, 0.36, 1);
  --ease-in-out: cubic-bezier(0.76, 0, 0.24, 1);
  --ease-soft: cubic-bezier(0.33, 1, 0.68, 1);
  --t-mode: 1400ms;
}

*, *::before, *::after { box-sizing: border-box; }
html { -webkit-text-size-adjust: 100%; text-size-adjust: 100%; }
body {
  margin: 0;
  background: var(--paper);
  color: var(--ink);
  font-family: var(--font-text);
  font-size: var(--step-body);
  line-height: 1.55;
  -webkit-font-smoothing: antialiased;
  transition: background-color var(--t-mode) ease, color var(--t-mode) ease;
}
h1, h2, h3, p, figure, blockquote, ul, ol, dl, dd { margin: 0; }
ul, ol { padding: 0; list-style: none; }
img, video, svg { display: block; max-width: 100%; }
a { color: inherit; }
button { font: inherit; color: inherit; background: none; border: 0; padding: 0; cursor: pointer; }
:focus-visible { outline: 2px solid currentColor; outline-offset: 3px; }
::selection { background: var(--accent); color: var(--accent-ink); }
.sr-only { position: absolute; width: 1px; height: 1px; overflow: hidden; clip-path: inset(50%); white-space: nowrap; }
h2, h3 { font-family: var(--font-display); font-weight: 300; font-variation-settings: "opsz" 144, "SOFT" 100; text-wrap: balance; }
p { text-wrap: pretty; max-width: 62ch; }
.nums { font-variant-numeric: tabular-nums lining-nums; }

/* ---------- the swap: both versions stacked, mode picks one ---------- */
.swap { display: grid; }
.swap > * { grid-area: 1 / 1; transition: opacity var(--t-mode) var(--ease-in-out), visibility 0s linear var(--t-mode); }
.swap.abs { position: absolute; inset: 0; }
.swap.abs > * { width: 100%; height: 100%; }
html[data-mode="day"] .is-night,
html[data-mode="night"] .is-day { opacity: 0; visibility: hidden; }
html[data-mode="day"] .is-day,
html[data-mode="night"] .is-night { transition-delay: 0s; }
/* text swaps faster than pictures, so a paragraph is never two paragraphs for long */
.swap.text > * { transition-duration: 500ms; }

.media { width: 100%; height: 100%; object-fit: cover; }

/* ---------- top bar ---------- */
.bar {
  position: fixed; inset: 0 0 auto 0; z-index: 30;
  display: grid; grid-template-columns: 1fr auto 1fr; align-items: center;
  padding: 18px var(--margin);
  color: var(--on-photo);
  transition: background-color 400ms ease, color 400ms ease, padding 400ms var(--ease-out);
}
.bar.is-solid { background: var(--bar-bg, var(--paper)); color: var(--bar-ink, var(--ink)); padding-block: 12px; }
html[data-mode="night"] .bar.is-solid { --bar-bg: var(--night); --bar-ink: var(--dusk-4-ink); }
.bar nav { display: flex; gap: clamp(14px, 2vw, 28px); font-size: var(--step-small); }
.bar nav a { text-decoration: none; }
.bar .mark { justify-self: center; width: 150px; height: 22px; background: currentColor; -webkit-mask: url(img/wordmark-mask.png?c=17) center / contain no-repeat; mask: url(img/wordmark-mask.png?c=17) center / contain no-repeat; }
.bar .end { justify-self: end; display: flex; align-items: center; gap: 22px; }
.bar .rsvp { font-size: var(--step-small); text-decoration: none; padding: 10px 18px; background: var(--accent); color: var(--accent-ink); transition: transform 140ms var(--ease-out), background-color 200ms ease; }
html[data-mode="night"] .bar .rsvp { background: var(--dusk-1); color: var(--night); }

/* the day / night switch */
.mode {
  display: inline-flex; align-items: center; gap: 12px; font-size: var(--step-small); line-height: 1;
  min-height: 44px; padding: 0 2px;
}
.mode .track { position: relative; width: 48px; height: 26px; border-radius: 13px; background: currentColor; flex: none; }
.mode .knob {
  position: absolute; top: 3px; left: 3px; width: 20px; height: 20px; border-radius: 50%;
  background: var(--accent); transition: transform 500ms var(--ease-out), background-color 500ms ease;
}
.bar:not(.is-solid) .mode .knob { background: #3a302a; }
html[data-mode="night"] .mode .knob { transform: translateX(22px); background: var(--glow); }
.mode .label { min-width: 3.4em; }
.mode:hover .knob { scale: 1.12; }
.mode .knob { transition: transform 500ms var(--ease-out), background-color 500ms ease, scale 180ms var(--ease-out); }
.clock { font-size: var(--step-small); white-space: nowrap; }

/* ---------- hero ---------- */
.hero { position: relative; height: 100svh; min-height: 560px; overflow: hidden; color: var(--on-photo); background: #3b3a37; }
.hero .swap.abs img { transform: scale(var(--hero-scale, 1)); transform-origin: 50% 60%; }
.hero::after { /* neutral scrim under the name only */
  content: ""; position: absolute; inset: auto 0 0 0; height: 46%;
  background: linear-gradient(to top, rgb(0 0 0 / 0.55), rgb(0 0 0 / 0)); /* taste-skill-ignore: neutral scrim under text on a photograph */
  pointer-events: none;
}
.hero::before { content: ""; position: absolute; inset: 0 0 auto 0; height: 22%; z-index: 1; background: linear-gradient(to bottom, rgb(0 0 0 / 0.32), rgb(0 0 0 / 0)); pointer-events: none; } /* taste-skill-ignore: neutral scrim under text on a photograph */
.hero .foot { position: absolute; z-index: 2; left: var(--margin); right: var(--margin); bottom: clamp(16px, 2.4vw, 28px); }
.hero .say { display: flex; justify-content: space-between; align-items: end; gap: 24px; margin-bottom: clamp(14px, 2vw, 26px); font-size: var(--step-body); }
.hero .say p { max-width: 34ch; }
.hero .say .swap.text { justify-items: end; text-align: right; }
.hero h1 { margin: 0; line-height: 0; }
.hero h1 .line { display: block; overflow: hidden; padding-bottom: 0.4vw; }
.hero .wordmark { display: block; width: 100%; height: auto; }

/* ---------- intro: right-half paragraph, lone photo ---------- */
.intro { padding: clamp(6rem, 11vw, 10rem) var(--margin); transition: background-color var(--t-mode) ease, color var(--t-mode) ease; }
html[data-mode="night"] .intro { background: var(--dusk-1); color: var(--dusk-1-ink); }
.intro .grid { display: grid; grid-template-columns: repeat(12, minmax(0, 1fr)); column-gap: var(--gutter); }
.intro .statement { grid-column: 5 / 13; grid-row: 1; margin-top: 8vh; font-family: var(--font-display); font-weight: 300; font-variation-settings: "opsz" 72, "SOFT" 100; font-size: var(--step-mid); line-height: 1.3; }
.intro .statement p { text-indent: 3em; max-width: 34em; }
.intro .mix { grid-column: 5 / 11; grid-row: 2; margin-top: 28px; max-width: 54ch; }
.intro .lone { grid-column: 1 / 4; grid-row: 1 / 4; align-self: end; position: relative; aspect-ratio: 1; margin-top: 30vh; overflow: hidden; }
@media (max-width: 1100px) and (min-width: 761px) { .intro .statement { grid-column: 3 / 13; } .intro .mix { grid-column: 5 / 13; } }
.intro .note { grid-column: 1 / 3; grid-row: 4; margin-top: 96px; font-size: var(--step-small); line-height: 1.5; max-width: 200px; }
.intro .note cite { display: block; margin-top: 10px; font-style: normal; color: var(--muted); }
html[data-mode="night"] .intro .note cite { color: #6a5c56; }

/* ---------- showcase: one frame, three distances ---------- */
.showcase { position: relative; height: 300vh; background: var(--sky); transition: background-color var(--t-mode) ease, color var(--t-mode) ease; }
html[data-mode="night"] .showcase { background: var(--dusk-2); color: var(--dusk-2-ink); }
.showcase .stage { position: sticky; top: 0; height: 100svh; display: grid; place-items: center; overflow: hidden; }
.showcase .frame { position: relative; width: 30vw; aspect-ratio: 4 / 5; overflow: hidden; }
.showcase .frame img { transition: transform 900ms var(--ease-out), opacity var(--t-mode) var(--ease-in-out); transform-origin: var(--o1); }
.showcase .is-day img { object-position: 72% 50%; --o1: 70% 52%; --o2: 64% 70%; --o3: 76% 30%; }
.showcase .is-night img { object-position: 28% 50%; --o1: 30% 50%; --o2: 22% 68%; --o3: 36% 28%; }
.showcase[data-stage="2"] .frame img { transform: scale(1.8); transform-origin: var(--o2); }
.showcase[data-stage="3"] .frame img { transform: scale(3.2); transform-origin: var(--o3); }
.showcase h2 { position: absolute; inset: 0; pointer-events: none; text-align: center; font-size: var(--step-head); line-height: 1; letter-spacing: 0; z-index: 2; }
.showcase h2 .a { top: calc(50% - 30vw * 0.625 - 1.05em); position: absolute; left: 0; right: 0; }
.showcase h2 .b { top: calc(50% + 30vw * 0.625 + 0.12em); position: absolute; left: 0; right: 0; transition: opacity 600ms ease, transform 800ms var(--ease-out); }
.showcase[data-stage="1"] h2 .b { opacity: 0; transform: translateY(20px); }
.showcase .caption { position: absolute; left: calc(50% + 15vw + 32px); top: calc(50% - 30vw * 0.625); width: 28ch; transition: opacity 600ms ease, transform 800ms var(--ease-out); }
.showcase:not([data-stage="3"]) .caption { opacity: 0; transform: translateY(16px); }

/* ---------- residences: the printed sheet on a photograph ---------- */
.residences { position: relative; padding: clamp(5rem, 9vw, 9rem) var(--margin); overflow: hidden; }
.residences .swap.abs { z-index: 0; }
.sheet {
  position: relative; z-index: 1; width: min(640px, 100%); margin-left: auto; margin-right: max(0px, calc((100vw - 2 * var(--margin)) * 0.04));
  background: var(--paper); color: var(--ink); padding: 84px 64px 92px; text-align: center;
  -webkit-mask: var(--waves-top) top / 120px 22px repeat-x, var(--waves-bottom) bottom / 120px 22px repeat-x, linear-gradient(#000 0 0) center / 100% calc(100% - 42px) no-repeat; /* taste-skill-ignore: solid mask layer, not a gradient fill */
  mask: var(--waves-top) top / 120px 22px repeat-x, var(--waves-bottom) bottom / 120px 22px repeat-x, linear-gradient(#000 0 0) center / 100% calc(100% - 42px) no-repeat; /* taste-skill-ignore: solid mask layer, not a gradient fill */
  transition: background-color var(--t-mode) ease, color var(--t-mode) ease;
}
/* the edge is the balcony line: a soft wave like the fluted balustrades seen from the street */
:root {
  --waves-top: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 120 22'%3E%3Cpath d='M0 22V14C14 14 18 3 33 3S48 14 60 14 74 3 89 3 106 14 120 14V22Z'/%3E%3C/svg%3E");
  --waves-bottom: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 120 22'%3E%3Cpath d='M0 0V8C14 8 18 19 33 19S48 8 60 8 74 19 89 19 106 8 120 8V0Z'/%3E%3C/svg%3E");
}
html[data-mode="night"] .sheet { background: var(--dusk-1); color: var(--dusk-1-ink); }
.sheet h2 { font-size: var(--step-mid); line-height: 1.1; }
.sheet .sprig { width: 64px; margin: 0 auto 26px; color: var(--accent); }
.sheet .lede { margin: 14px auto 0; max-width: 34ch; }
.sheet .group { margin-top: 52px; }
.sheet h3 { font-size: var(--step-lead); line-height: 1.2; }
.sheet .row {
  display: grid; grid-template-columns: 1fr auto; column-gap: 20px; width: 100%; max-width: 440px; margin: 16px auto 0;
  text-align: left; padding: 6px 0; cursor: pointer;
}
.sheet .row .name { font-weight: 500; }
.sheet .row .size { text-align: right; }
.sheet .row .desc { grid-column: 1 / -1; }
.sheet .row .plan { grid-column: 1 / -1; font-size: var(--step-small); text-decoration: underline; text-underline-offset: 3px; color: var(--accent); margin-top: 4px; }
.sheet .row:hover .name { text-decoration: underline; text-underline-offset: 4px; }
.sheet .close { margin-top: 56px; max-width: none; }

dialog.plan-view { width: min(1200px, 94vw); max-height: 92vh; padding: 0; border: 0; background: #fff; }
dialog.plan-view::backdrop { background: rgb(20 18 16 / 0.72); }
dialog.plan-view img { width: 100%; height: auto; }
dialog.plan-view .x { position: absolute; top: 10px; right: 10px; min-width: 44px; min-height: 44px; background: var(--ink); color: var(--paper); font-size: var(--step-small); padding: 0 14px; }

/* ---------- inside: one scene, stepping statements ---------- */
.inside { position: relative; height: 420vh; background: #1d1b19; }
.inside .stage { position: sticky; top: 0; height: 100svh; overflow: hidden; }
.inside .stage::after { content: ""; position: absolute; inset: 0 0 auto 0; height: 62%; background: linear-gradient(to bottom, rgb(12 10 9 / 0.86) 0%, rgb(12 10 9 / 0.7) 45%, rgb(12 10 9 / 0)); } /* taste-skill-ignore: neutral scrim under text on a photograph */ /* taste-skill-ignore: neutral scrim under text on a photograph */
.inside .steps { position: absolute; z-index: 3; top: clamp(84px, 13vh, 130px); left: 50%; transform: translateX(-50%); text-align: center; width: min(90vw, 560px); color: #efeeea; }
.inside .steps li { font-size: var(--step-body); line-height: 1.35; padding: 5px 0; color: #b9afa4; transition: color 400ms ease; }
.inside .steps li:first-child { font-family: var(--font-display); font-weight: 300; font-size: var(--step-mid); color: #efeeea; margin-bottom: 8px; }
.inside .steps li.on { color: #f4f3ef; }
.inside .steps li.on:not(:first-child)::before { content: ""; display: inline-block; width: 7px; height: 7px; border-radius: 50%; background: var(--glow); margin-right: 10px; vertical-align: 0.15em; }
.inside .pair img { position: absolute; z-index: 2; object-fit: cover; height: auto; opacity: 0; transform: translateY(24px); transition: opacity 700ms ease, transform 900ms var(--ease-out); }
.inside .pair.on img { opacity: 1; transform: none; }
.inside .pair img:first-child { left: 7vw; top: 44vh; width: clamp(160px, 15vw, 240px); aspect-ratio: 4 / 5; }
.inside .pair img:last-child { right: 7vw; top: 58vh; width: clamp(180px, 17vw, 260px); aspect-ratio: 3 / 2; }

/* ---------- neighbourhood: wide picture, colour tile, facts ---------- */
.hood { padding: var(--section) var(--margin); transition: background-color var(--t-mode) ease, color var(--t-mode) ease; }
html[data-mode="night"] .hood { background: var(--dusk-3); color: var(--dusk-3-ink); --muted: #d6cfc6; }
.hood h2 { font-size: var(--step-head); line-height: 1; letter-spacing: 0; }
.hood .lead { margin-top: 24px; max-width: 44ch; font-size: var(--step-lead); line-height: 1.45; }
.hood .tiles { display: grid; grid-template-columns: repeat(12, minmax(0, 1fr)); gap: 16px; margin-top: 72px; align-items: start; }
.hood .wide { grid-column: 1 / 9; position: relative; aspect-ratio: 16 / 10; overflow: hidden; background: #3b3a37; }
.hood .wide video { width: 100%; height: 100%; object-fit: cover; }
.hood .wide .over { position: absolute; top: 0; right: 0; width: 330px; padding: 20px 22px; background: var(--paper); color: var(--ink); transition: background-color var(--t-mode) ease, color var(--t-mode) ease; }
html[data-mode="night"] .hood .wide .over { background: var(--dusk-4); color: var(--dusk-4-ink); }
.hood .side { grid-column: 9 / 13; }
.hood .map { background: #e3e8dc; aspect-ratio: 1; overflow: hidden; position: relative; }
.hood .map img { width: 100%; height: 100%; object-fit: cover; object-position: 62% 30%; transform: scale(1.35); transform-origin: 62% 28%; }
.hood .facts { display: grid; grid-template-columns: 1fr 1fr; gap: 18px 16px; margin-top: 20px; }
.hood .facts dt { color: var(--muted); font-size: var(--step-small); }

.hood .places { margin-top: 28px; columns: 4 200px; column-gap: 32px; }
.hood .places li { break-inside: avoid; padding: 3px 0; }
.hood .places-head { margin-top: 72px; font-size: var(--step-mid); font-family: var(--font-display); font-weight: 300; }

/* ---------- rooms: drag row ---------- */
.rooms { padding: var(--section) 0; background: var(--surface); transition: background-color var(--t-mode) ease, color var(--t-mode) ease; }
html[data-mode="night"] .rooms { background: var(--dusk-4); color: var(--dusk-4-ink); --muted: #c9c0b5; }
.rooms .head { display: flex; justify-content: space-between; align-items: baseline; gap: 24px; padding: 0 var(--margin); margin-bottom: 32px; }
.rooms h2 { font-size: var(--step-mid); line-height: 1.1; }
.rooms .count { font-size: var(--step-small); color: var(--muted); }
.rooms .rows { display: grid; }
.rooms .rows > * { grid-area: 1 / 1; }
.row-scroll {
  display: flex; gap: 12px; height: 68svh; min-height: 420px; overflow-x: auto; overscroll-behavior-x: contain;
  scroll-snap-type: x proximity; scrollbar-width: none; padding: 0 var(--margin); cursor: grab;
}
.row-scroll::-webkit-scrollbar { display: none; }
.row-scroll.dragging { cursor: grabbing; scroll-snap-type: none; }
.row-scroll > * { flex: none; height: 100%; scroll-snap-align: start; scroll-margin-left: var(--margin); }
.row-scroll figure { position: relative; overflow: hidden; }
.row-scroll img { width: 100%; height: 100%; object-fit: cover; transition: transform 900ms var(--ease-out); -webkit-user-drag: none; user-select: none; }
.row-scroll figure:hover img { transform: scale(1.03); }
.row-scroll .tall { aspect-ratio: 3 / 4; }
.row-scroll .wide { aspect-ratio: 16 / 10; }
.row-scroll .stack { display: grid; grid-template-rows: 1fr 1fr; gap: 12px; aspect-ratio: 4 / 6.15; }
.row-scroll figcaption { position: absolute; left: 0; bottom: 0; padding: 6px 10px; font-size: var(--step-small); background: rgb(20 18 16 / 0.62); color: #efeeea; }
.rooms .note { padding: 18px var(--margin) 0; font-size: var(--step-small); color: var(--muted); }

/* ---------- preview: visit card on a photograph ---------- */
.preview { position: relative; min-height: 130svh; }
.preview .pic { position: absolute; inset: 0; }
.preview .card {
  position: sticky; top: 96px; z-index: 2; margin: 0 var(--margin) 0 auto; width: 400px;
  background: var(--paper); color: var(--ink); padding: 32px 32px 0; border-radius: 8px; overflow: hidden;
  transition: background-color var(--t-mode) ease, color var(--t-mode) ease;
}
.preview .card-wrap { position: relative; padding: 96px 0 40vh; }
html[data-mode="night"] .preview .card { background: var(--dusk-1); color: var(--dusk-1-ink); }
.preview h2 { font-size: var(--step-mid); line-height: 1.15; }
.preview .when { margin-top: 18px; }
.preview .addr { margin-top: 16px; }
.preview .invite { margin-top: 16px; }
.preview .who { margin-top: 18px; }
.preview .who li { display: flex; justify-content: space-between; gap: 12px; padding: 6px 0; }
.preview .who a { text-decoration: none; }
.preview .who a:hover { text-decoration: underline; text-underline-offset: 3px; }
.preview .go {
  display: flex; align-items: center; justify-content: center; height: 56px; margin: 26px -32px 0;
  background: var(--accent); color: var(--accent-ink); text-decoration: none; font-weight: 500;
  transition: background-color 200ms ease, transform 140ms var(--ease-out);
}
.preview .go:hover { background: #654a35; }
.preview .go:active, .bar .rsvp:active { transform: scale(0.98); }
html[data-mode="night"] .preview .go { background: var(--night); color: var(--dusk-1); }
html[data-mode="night"] .preview .go:hover { background: #000; }

/* ---------- footer: the back of the card ---------- */
.foot-end { background: var(--ink); color: var(--paper); padding: 120px var(--margin) 40px; transition: background-color var(--t-mode) ease; }
html[data-mode="night"] .foot-end { background: var(--night); }
.back {
  position: relative; max-width: calc(100% - 8vw); margin: 0 auto; min-height: 420px; background: var(--paper); color: var(--ink);
  display: grid; grid-template-columns: 1fr 1fr; gap: 48px; padding: 84px 56px 30px;
  -webkit-mask: var(--waves-top) top / 100px 22px repeat-x, linear-gradient(#000 0 0) bottom / 100% calc(100% - 21px) no-repeat; /* taste-skill-ignore: solid mask layer, not a gradient fill */
  mask: var(--waves-top) top / 100px 22px repeat-x, linear-gradient(#000 0 0) bottom / 100% calc(100% - 21px) no-repeat; /* taste-skill-ignore: solid mask layer, not a gradient fill */
  transition: background-color var(--t-mode) ease, color var(--t-mode) ease;
}
html[data-mode="night"] .back { background: var(--dusk-1); color: var(--dusk-1-ink); }
.back .sign { font-family: var(--font-display); font-weight: 300; font-size: var(--step-mid); line-height: 1.1; }
.back .msg { margin-top: 16px; max-width: 36ch; }
.back .addr { position: relative; padding-top: 120px; }
.back .addr li { margin-bottom: 12px; }
.back .addr a { text-decoration: none; }
.back .addr a:hover { text-decoration: underline; text-underline-offset: 4px; }
.back .stamp { position: absolute; top: 0; right: 0; width: 88px; padding: 6px; background: var(--paper); outline: 1px dashed transparent; }
.back .stamp img { aspect-ratio: 3 / 4; object-fit: cover; width: 100%; height: auto; }
.back .imprint { grid-column: 1 / -1; align-self: end; text-align: center; font-size: var(--step-small); color: var(--muted); max-width: 70ch; margin: 30px auto 0; }
html[data-mode="night"] .back .imprint { color: #6a5c56; }
.foot-end .wordmark { margin-top: 90px; width: 100%; aspect-ratio: 1947 / 296; background: var(--paper); -webkit-mask: url(img/wordmark-mask.png?c=17) center / contain no-repeat; mask: url(img/wordmark-mask.png?c=17) center / contain no-repeat; }
html[data-mode="night"] .foot-end .wordmark { background: var(--glow); }
.foot-end .apts { width: min(260px, 40vw); margin: 18px auto 0; color: var(--paper); }

/* ---------- motion ---------- */
@media (prefers-reduced-motion: no-preference) {
  .js .hero h1 .wordmark { transform: translateY(105%); animation: line-up 1100ms var(--ease-out) 150ms forwards; }
  .js .hero .say > * { opacity: 0; transform: translateY(14px); animation: rise 800ms var(--ease-out) forwards; animation-delay: calc(var(--i, 0) * 90ms + 700ms); }
  .js [data-reveal] { opacity: 0; transform: translateY(24px); transition: opacity 700ms var(--ease-out), transform 900ms var(--ease-out); transition-delay: calc(var(--i, 0) * 80ms); }
  .js [data-reveal].is-in { opacity: 1; transform: none; }
  .hero .swap.abs img { transition: opacity var(--t-mode) var(--ease-in-out), transform 200ms linear; }
}
@keyframes line-up { to { transform: none; } }
@keyframes rise { to { opacity: 1; transform: none; } }
@media (prefers-reduced-motion: reduce) {
  :root { --t-mode: 300ms; }
  .showcase .frame img { transition: opacity 300ms ease; }
}

/* ---------- phone ---------- */
@media (max-width: 760px) {
  .bar { grid-template-columns: auto 1fr; padding: 14px 20px; }
  .bar nav { display: none; }
  .bar .mark { justify-self: start; width: 120px; }
  .bar .end .rsvp { padding: 9px 14px; }
  .bar .clock { display: none; }
  .bar .end { justify-self: end; }
  .mode-dock { position: fixed; z-index: 31; left: 50%; bottom: 16px; transform: translateX(-50%); padding: 6px 16px 6px 10px; background: var(--paper); color: var(--ink); border-radius: 30px; }
  html[data-mode="night"] .mode-dock { background: var(--night); color: var(--dusk-4-ink); }
  .bar .mode { display: none; }
  .hero .say { flex-direction: column; align-items: start; gap: 10px; }
  .hero .say .swap.text { justify-items: start; text-align: left; }
  .hero { min-height: 520px; }
  .hero .foot { bottom: 84px; }
  .hero .swap.abs img { object-position: 42% 50%; }

  .intro .grid { grid-template-columns: repeat(10, 1fr); }
  .intro .statement { grid-column: 1 / -1; margin-top: 0; font-size: var(--step-lead); }
  .intro .mix { grid-column: 1 / -1; grid-row: 2; }
  .intro .statement p { text-indent: 0; }
  .intro .lone { grid-column: 4 / -1; grid-row: 3; margin-top: 40px; aspect-ratio: 4 / 5; }
  .intro .lone { grid-column: 3 / -1; }
  .intro .note { grid-column: 1 / -1; grid-row: 4; margin-top: 24px; max-width: 32ch; }

  .showcase .frame { width: 70vw; }
  .showcase h2 { font-size: 13vw; }
  .showcase h2 .a { top: calc(50% - 70vw * 0.625 - 1.05em); }
  .showcase h2 .b { top: calc(50% + 70vw * 0.625 + 0.12em); }
  .showcase .caption { left: 20px; right: 20px; width: auto; top: auto; bottom: 7vh; text-align: center; }

  .residences { padding: 64px 10px; }
  .sheet { padding: 64px 28px 72px; margin: 0 auto; }

  .inside .steps { top: auto; bottom: 8vh; left: 20px; transform: none; text-align: left; width: calc(100% - 40px); }
  .inside .stage::after { inset: auto 0 0 0; height: 62%; background: linear-gradient(to top, rgb(12 10 9 / 0.85), rgb(12 10 9 / 0)); } /* taste-skill-ignore: neutral scrim under text on a photograph */
  .inside .pair img:first-child { left: auto; right: 16px; top: 90px; width: 44vw; }
  .inside .pair img:last-child { display: none; }

  .hood .tiles { grid-template-columns: 1fr; margin-top: 40px; }
  .hood .wide { grid-column: 1; aspect-ratio: 4 / 3; overflow: visible; }
  .hood .wide .over { position: static; width: auto; padding: 18px 0 0; background: none !important; color: inherit !important; }
  .hood .side { grid-column: 1; margin-top: 40px; }
  .hood .map { aspect-ratio: 3 / 2; }

  .row-scroll { height: 62svh; min-height: 380px; gap: 8px; padding: 0 20px; }
  .row-scroll .tall { width: 72vw; aspect-ratio: auto; }
  .row-scroll .stack { width: 64vw; aspect-ratio: auto; gap: 8px; }
  .row-scroll .wide { width: 88vw; aspect-ratio: auto; height: 70%; align-self: center; }

  .preview { min-height: 0; }
  .preview .pic { position: relative; height: 70svh; }
  .preview .card-wrap { padding: 0 16px 100px; margin-top: -80px; }
  .preview .card { position: relative; top: 0; width: auto; margin: 0; }
  .preview .go { height: 56px; }

  .foot-end { padding: 80px 0 110px; }
  .back { max-width: 100%; grid-template-columns: 1fr; gap: 36px; padding: 70px 24px 26px; }
  .back .addr { padding-top: 0; }
  .back .stamp { top: -0px; width: 64px; position: absolute; }
  .back .sign { padding-right: 76px; }
  .foot-end .wordmark { width: calc(100% - 40px); margin: 70px auto 0; }
}
@media (min-width: 761px) { .mode-dock { display: none; } }
