/* SOFIA — home prototype.
   Story device: the page runs from night (arrival) to day (the room) to evening (the town).
   The theme changes on <html data-theme>, driven by scroll; sections carry no background of their own. */

@font-face { font-family: 'Switzer'; src: url('fonts/switzer.woff2') format('woff2'); font-weight: 100 900; font-display: swap; }
@font-face { font-family: 'Tiempos Fine'; src: url('fonts/tiempos-fine-roman.woff2') format('woff2'); font-weight: 300 900; font-style: normal; font-display: swap; }
@font-face { font-family: 'Tiempos Fine'; src: url('fonts/tiempos-fine-italic.woff2') format('woff2'); font-weight: 300 900; font-style: italic; font-display: swap; }

:root {
  /* Brand palette (colors.svg) */
  --white: #f6f6f6;
  --silver: #e8e8e8;
  --green: #2c2e2d;
  --sand: #c5b9ac;
  --sage: #7e7f74;
  /* Extensions: one night tone below the brand green, one accent from the room's lacquered niche */
  --night: #1e201f;
  --rust: #8b3a24;
  --rust-soft: #b0654a;

  --serif: 'Tiempos Fine', 'Times New Roman', serif;
  --sans: 'Switzer', ui-sans-serif, system-ui, -apple-system, sans-serif;

  --t-display: clamp(2.9rem, 1.6rem + 4.6vw, 6.4rem);
  --t-h2: clamp(2.3rem, 1.5rem + 3.1vw, 4.6rem);
  --t-h3: clamp(1.45rem, 1.15rem + 1vw, 2.05rem);
  --t-lead: clamp(1.1rem, 1rem + .4vw, 1.36rem);
  --t-body: 1.0625rem;
  --t-small: .875rem;
  --t-label: .75rem;

  --gut: clamp(1.25rem, .6rem + 2.6vw, 3.5rem);
  --sect: clamp(6rem, 4rem + 9vw, 13rem);
  --max: 1560px;

  --ease-out: cubic-bezier(0.23, 1, 0.32, 1);
  --ease-io: cubic-bezier(0.77, 0, 0.175, 1);
  --ease-curtain: cubic-bezier(0.65, 0, 0.15, 1);

  /* Theme tokens (night by default; JS flips them by scroll) */
  --bg: var(--night);
  --fg: var(--white);
  --fg-2: color-mix(in oklab, var(--white) 66%, var(--night));
  --line: color-mix(in oklab, var(--white) 16%, transparent);
  --accent: var(--rust-soft);
  color-scheme: dark;
}
:root[data-theme="day"] {
  --bg: var(--white);
  --fg: var(--green);
  --fg-2: color-mix(in oklab, var(--green) 72%, var(--white));
  --line: color-mix(in oklab, var(--green) 16%, transparent);
  --accent: var(--rust);
  color-scheme: light;
}
:root[data-theme="stone"] {
  --bg: var(--sand);
  --fg: var(--green);
  --fg-2: color-mix(in oklab, var(--green) 80%, var(--sand));
  --line: color-mix(in oklab, var(--green) 22%, transparent);
  --accent: var(--rust);
  color-scheme: light;
}
:root[data-theme="evening"] {
  --bg: var(--green);
  --fg: var(--white);
  --fg-2: color-mix(in oklab, var(--white) 70%, var(--green));
  --line: color-mix(in oklab, var(--white) 18%, transparent);
  --accent: var(--rust-soft);
  color-scheme: dark;
}

*, *::before, *::after { box-sizing: border-box; }
html { -webkit-text-size-adjust: 100%; overflow-x: clip; overscroll-behavior-x: none; }
figure { margin: 0; }
html.lenis, html.lenis body { height: auto; }
.lenis.lenis-stopped { overflow: hidden; }
body {
  margin: 0;
  background: var(--bg);
  color: var(--fg);
  font: 400 var(--t-body)/1.6 var(--sans);
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
  transition: background-color .9s var(--ease-io), color .9s var(--ease-io);
  overflow-x: clip;
}
img { display: block; max-width: 100%; height: auto; }
a { color: inherit; text-decoration: none; }
button { font: inherit; color: inherit; background: none; border: 0; padding: 0; cursor: pointer; }
::selection { background: var(--rust); color: var(--white); }
:focus-visible { outline: 1.5px solid currentColor; outline-offset: 4px; }

/* Grain: fixed, never on a scrolling layer */
body::after {
  content: ''; position: fixed; inset: -50%; z-index: 90; pointer-events: none; opacity: .07;
  background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='180' height='180'%3E%3Cfilter id='n'%3E%3CfeTurbulence type='fractalNoise' baseFrequency='.85' numOctaves='2' stitchTiles='stitch'/%3E%3CfeColorMatrix values='0 0 0 0 .5 0 0 0 0 .5 0 0 0 0 .5 0 0 0 .9 0'/%3E%3C/filter%3E%3Crect width='100%25' height='100%25' filter='url(%23n)'/%3E%3C/svg%3E");
}
:root[data-theme="day"] body::after, :root[data-theme="stone"] body::after { opacity: .05; }

/* ---------- Type ---------- */
.display, .h2, .h3, .quote { font-family: var(--serif); font-weight: 300; margin: 0; text-wrap: balance; font-optical-sizing: auto; }
.display { font-size: var(--t-display); line-height: 1.04; letter-spacing: -.022em; }
.h2 { font-size: var(--t-h2); line-height: 1.06; letter-spacing: -.018em; }
.h3 { font-size: var(--t-h3); line-height: 1.15; letter-spacing: -.01em; }
.display em, .h2 em, .h3 em { font-style: italic; font-weight: 300; padding-bottom: .06em; }
.lead { font-size: var(--t-lead); line-height: 1.5; color: var(--fg-2); max-width: 36ch; text-wrap: pretty; margin: 0; }
.body { color: var(--fg-2); max-width: 58ch; text-wrap: pretty; margin: 0; }
.label { font: 500 var(--t-label)/1.2 var(--sans); letter-spacing: .16em; text-transform: uppercase; }
.small { font-size: var(--t-small); line-height: 1.5; color: var(--fg-2); }
.num { font-variant-numeric: tabular-nums; }

.wrap { width: 100%; max-width: var(--max); margin-inline: auto; padding-inline: var(--gut); }
.sect { padding-block: var(--sect); position: relative; }

/* ---------- Buttons ---------- */
.btn {
  --h: 3.25rem;
  display: inline-flex; align-items: center; gap: .75rem; height: var(--h); padding-inline: 1.6rem;
  font: 500 .9375rem/1 var(--sans); letter-spacing: .01em; white-space: nowrap;
  border-radius: 999px; position: relative; overflow: hidden; isolation: isolate;
  transition: transform 160ms var(--ease-out), color .35s var(--ease-out), background-color .35s var(--ease-out);
}
.btn:active { transform: scale(.97); }
.btn-solid { background: var(--fg); color: var(--bg); }
.btn-solid::before { content: ''; position: absolute; inset: 0; z-index: -1; background: var(--accent); transform: translateY(101%); transition: transform .5s var(--ease-out); border-radius: inherit; }
.btn-solid:hover::before { transform: translateY(0); }
.btn-solid:hover { color: var(--white); }
.btn-line { box-shadow: inset 0 0 0 1px var(--line); }
.btn-line:hover { box-shadow: inset 0 0 0 1px var(--fg); }
.btn [class*='ph-'] { font-size: 1.05rem; transition: transform .4s var(--ease-out); }
.btn:hover .ph-arrow-right, .btn:hover .ph-arrow-down-right { transform: translateX(3px); }
@media (hover: none) { .btn-solid::before { display: none; } }

.link-u { position: relative; display: inline-flex; gap: .5rem; align-items: center; padding-block: .3rem; }
.link-u::after { content: ''; position: absolute; left: 0; right: 0; bottom: 0; height: 1px; background: currentColor; transform-origin: right; transform: scaleX(.35); transition: transform .5s var(--ease-out); }
.link-u:hover::after { transform-origin: left; transform: scaleX(1); }

/* ---------- Intro curtain ---------- */
.intro { position: fixed; inset: 0; z-index: 100; background: var(--night); color: var(--white); display: grid; place-items: center; }
.intro .wm { width: min(56vw, 560px); overflow: visible; }
.intro .stars { position: absolute; left: 50%; top: calc(50% - min(56vw, 560px) * .145 - 2.4rem); transform: translateX(-50%); display: flex; gap: .7rem; font-size: .6rem; letter-spacing: 0; }
.intro .stars i { opacity: 0; }
.intro .bar { position: absolute; left: 50%; bottom: 3rem; transform: translateX(-50%); width: 7rem; height: 1px; background: color-mix(in oklab, var(--white) 18%, transparent); overflow: hidden; }
.intro .bar i { position: absolute; inset: 0; background: var(--white); transform-origin: left; transform: scaleX(0); }
.no-intro .intro { display: none; }

/* ---------- Nav ---------- */
.nav {
  position: fixed; inset: 0 0 auto; z-index: 50; height: 76px;
  display: grid; grid-template-columns: 1fr auto 1fr; align-items: center; padding-inline: var(--gut);
  transition: transform .6s var(--ease-out), background-color .6s var(--ease-io), color .9s var(--ease-io), box-shadow .6s;
}
.nav.is-solid { background: color-mix(in oklab, var(--bg) 88%, transparent); backdrop-filter: blur(14px) saturate(1.2); -webkit-backdrop-filter: blur(14px) saturate(1.2); box-shadow: 0 1px 0 var(--line); }
.nav.is-hidden { transform: translateY(-100%); }
.nav .brand { justify-self: start; display: inline-flex; align-items: center; height: 44px; }
.nav .brand .wm { height: 20px; width: auto; }
.nav .links { display: flex; gap: 2.3rem; font-size: .9375rem; }
.nav .links a { position: relative; padding-block: .4rem; }
.nav .links a::after { content: ''; position: absolute; left: 0; right: 0; bottom: 0; height: 1px; background: currentColor; transform: scaleX(0); transform-origin: right; transition: transform .45s var(--ease-out); }
.nav .links a:hover::after, .nav .links a[aria-current]::after { transform: scaleX(1); transform-origin: left; }
.nav .right { justify-self: end; display: flex; align-items: center; gap: 1.1rem; }
.nav .btn { --h: 2.6rem; padding-inline: 1.25rem; font-size: .875rem; }
.lang { font: 500 .75rem/1 var(--sans); letter-spacing: .14em; padding: .6rem .3rem; opacity: .8; transition: opacity .3s; }
.lang:hover { opacity: 1; }
.menu-btn { display: none; align-items: center; gap: .6rem; font-size: .875rem; height: 44px; }
.menu-btn .bars { width: 22px; height: 8px; position: relative; }
.menu-btn .bars i { position: absolute; left: 0; right: 0; height: 1.5px; background: currentColor; transition: transform .45s var(--ease-out); }
.menu-btn .bars i:first-child { top: 0; } .menu-btn .bars i:last-child { bottom: 0; }
.menu-btn[aria-expanded="true"] .bars i:first-child { transform: translateY(3.25px) rotate(45deg); }
.menu-btn[aria-expanded="true"] .bars i:last-child { transform: translateY(-3.25px) rotate(-45deg); }

.mmenu { position: fixed; inset: 0; z-index: 45; background: var(--night); color: var(--white); padding: 108px var(--gut) 2rem; display: flex; flex-direction: column; justify-content: space-between; clip-path: inset(0 0 100% 0); transition: clip-path .7s var(--ease-curtain); visibility: hidden; }
.mmenu.is-open { clip-path: inset(0 0 0 0); visibility: visible; }
.mmenu nav a { display: flex; align-items: baseline; justify-content: space-between; font: 300 clamp(2.4rem, 11vw, 3.6rem)/1.15 var(--serif); padding-block: .55rem; border-bottom: 1px solid color-mix(in oklab, var(--white) 14%, transparent); opacity: 0; transform: translateY(14px); transition: opacity .5s var(--ease-out), transform .6s var(--ease-out); }
.mmenu.is-open nav a { opacity: 1; transform: none; transition-delay: calc(.18s + var(--i) * .06s); }
.mmenu nav a [class*='ph-'] { font-size: 1.4rem; opacity: .6; }
.mmenu .meta { display: grid; gap: 1.2rem; font-size: var(--t-small); color: color-mix(in oklab, var(--white) 70%, var(--night)); }

/* ---------- Hero ---------- */
.hero { min-height: 100dvh; padding: 120px var(--gut) clamp(1.5rem, 3vw, 2.75rem); display: grid; grid-template-columns: minmax(0, 1.08fr) minmax(0, .92fr); grid-template-rows: 1fr auto; gap: clamp(1.5rem, 3vw, 3.5rem) clamp(2rem, 5vw, 6rem); max-width: var(--max); margin-inline: auto; }
.hero .copy { align-self: center; display: grid; gap: 1.6rem; max-width: 40rem; }
.hero .label { color: var(--fg-2); display: flex; gap: 1.1rem; align-items: center; }
.hero .label .rule { width: 2.5rem; height: 1px; background: currentColor; opacity: .6; }
.hero .ctas { display: flex; flex-wrap: wrap; gap: .8rem; margin-top: .6rem; }
.hero .frame { grid-row: 1 / span 2; grid-column: 2; position: relative; overflow: hidden; border-radius: 2px; min-height: 420px; }
.hero .frame img { position: absolute; inset: 0; width: 100%; height: 100%; object-fit: cover; object-position: 38% 50%; transform-origin: 50% 60%; }
.hero .frame::after { content: ''; position: absolute; inset: auto 0 0; height: 30%; background: linear-gradient(transparent, rgb(20 22 21 / .55)); pointer-events: none; }
.hero .frame figcaption { position: absolute; z-index: 1; left: 1.1rem; bottom: 1rem; color: var(--white); font-size: .75rem; letter-spacing: .04em; opacity: .85; text-shadow: 0 1px 12px rgb(0 0 0 / .35); }
.hero .mark { grid-column: 1; align-self: end; color: var(--fg); }
.hero .mark .wm { width: 100%; max-width: 760px; height: auto; display: block; overflow: visible; }
.hero .mark .sub { display: flex; justify-content: space-between; max-width: 760px; margin-top: 1.1rem; color: var(--fg-2); font-size: var(--t-small); }

/* ---------- Manifesto ---------- */
.manifesto .quote { font-size: clamp(1.9rem, 1.2rem + 2.6vw, 3.9rem); line-height: 1.16; letter-spacing: -.015em; max-width: 22ch; }
.manifesto .quote .w { opacity: .16; transition: opacity .2s linear; }
.manifesto .facts { margin-top: clamp(4rem, 8vw, 7rem); display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); gap: 2rem; border-top: 1px solid var(--line); padding-top: 2rem; }
.manifesto .facts dt { font: 300 clamp(2rem, 1.4rem + 1.8vw, 3.2rem)/1 var(--serif); letter-spacing: -.01em; margin-bottom: .8rem; }
.manifesto .facts dd { margin: 0; color: var(--fg-2); font-size: var(--t-small); max-width: 24ch; }

/* ---------- The room: sticky split ---------- */
.seg { display: inline-flex; padding: 3px; border-radius: 999px; box-shadow: inset 0 0 0 1px var(--line); position: relative; }
.seg button { position: relative; z-index: 1; padding: .45rem 1rem; font-size: .8125rem; border-radius: 999px; transition: color .4s var(--ease-out); }
.seg .knob { position: absolute; top: 3px; bottom: 3px; left: 3px; border-radius: 999px; background: var(--fg); transition: transform .45s var(--ease-out), width .45s var(--ease-out); }
.seg button[aria-pressed="true"] { color: var(--bg); }

/* ---------- Wardrobe compare ---------- */

/* ---------- Plan: floor -> room camera move (pinned on desktop) ---------- */
.plan-pin { min-height: 100dvh; max-width: var(--max); margin-inline: auto; padding: 110px var(--gut) 3rem; display: grid; grid-template-columns: minmax(0, .62fr) minmax(0, 1.38fr); grid-template-rows: 1fr auto; gap: 1.5rem clamp(2rem, 4vw, 4.5rem); align-items: center; }
.plan-copy { position: relative; grid-row: 1 / span 2; align-self: stretch; display: grid; align-items: center; min-height: 22rem; }
.pc { display: grid; gap: 1.4rem; align-content: center; }
.pc-room { position: absolute; inset: 1vh 0 auto; opacity: 0; visibility: hidden; }
.count { font: 300 clamp(3.6rem, 2rem + 5vw, 7rem)/1 var(--serif); letter-spacing: -.02em; margin: 1rem 0 0; display: flex; align-items: baseline; gap: .8rem; }
.count .of { font: 400 .9375rem/1 var(--sans); color: var(--fg-2); letter-spacing: .04em; }
.stage { position: relative; overflow: hidden; aspect-ratio: 1400 / 1138; width: 100%; max-height: calc(100dvh - 190px); justify-self: center; color: var(--green); }
.stage .lines { position: absolute; inset: 0; background: currentColor; mask-mode: luminance; -webkit-mask-source-type: luminance; }
.floor { position: absolute; inset: 0; will-change: transform; }
.floor-lines { -webkit-mask: url('img/floor-lines.png') center / 100% 100% no-repeat; mask: url('img/floor-lines.png') center / 100% 100% no-repeat; opacity: .9; }
.glow { position: absolute; left: var(--x); top: var(--y); width: var(--w); height: var(--h); transform: translate(-50%, -50%); background: radial-gradient(closest-side, color-mix(in oklab, var(--rust) 55%, transparent), transparent); opacity: 0; mix-blend-mode: multiply; pointer-events: none; }
.detail { position: absolute; left: 50%; top: 50%; width: 100%; aspect-ratio: 1080 / 650; transform: translate(-50%, -50%); opacity: 0; visibility: hidden; }
.room-lines { -webkit-mask: url('img/plan-lines.png') center / 100% 100% no-repeat; mask: url('img/plan-lines.png') center / 100% 100% no-repeat; }
.cones { position: absolute; inset: 0; width: 100%; height: 100%; overflow: visible; pointer-events: none; }
.cone { transform-box: view-box; }
.cam { position: absolute; width: 2.9rem; height: 2.9rem; transform: translate(-50%, -50%); border-radius: 50%; display: grid; place-items: center; z-index: 2; }
.cam::before { content: ''; position: absolute; inset: .6rem; border-radius: 50%; background: var(--green); box-shadow: 0 0 0 3px var(--sand); transition: transform .45s var(--ease-out), background-color .35s; }
.cam span { position: relative; color: var(--white); font: 600 .6875rem/1 var(--sans); }
.cam:hover::before { transform: scale(1.18); }
.cam[aria-pressed="true"]::before { background: var(--rust); transform: scale(1.3); }
.view { grid-column: 1; grid-row: 1 / span 2; margin: 0; display: grid; grid-template-columns: minmax(0, 1fr) auto; gap: 1rem; align-items: end; opacity: 0; visibility: hidden; position: absolute; left: 0; bottom: 0; width: 100%; max-width: 400px; z-index: 3; }
.view .img { position: relative; aspect-ratio: 1.4; overflow: hidden; border-radius: 2px; grid-column: 1 / -1; box-shadow: 0 30px 80px -30px rgb(30 32 31 / .55); background: var(--green); }
.view .img img { position: absolute; inset: 0; width: 100%; height: 100%; object-fit: cover; }
.view [data-view-b] { clip-path: inset(0 0 0 100%); }
.view figcaption { grid-column: 1 / -1; display: flex; gap: 1rem; font-size: var(--t-small); }
.view figcaption .num { color: var(--rust); font-weight: 600; letter-spacing: .1em; }
.plan-pin { position: relative; }
@media (min-width: 901px) and (max-height: 820px) {
  .view { max-width: 300px; }
  .view .img { aspect-ratio: 1.6; }
  .pc-room { inset: 0 0 auto; }
}
/* Reduced motion: static, stacked plan */
.reduce .plan-pin { grid-template-rows: auto auto; align-items: start; }
.reduce .plan-copy { grid-row: 1; display: block; min-height: 0; }
.reduce .pc-room { position: static; margin-top: 2.5rem; }
.reduce .view { grid-column: 1; grid-row: 2; position: static; width: 100%; }
.reduce .stage { grid-column: 2; grid-row: 1 / span 2; }
@media (max-width: 900px) {
  .reduce .plan-copy { grid-row: 1; }
  .reduce .stage { grid-column: 1; grid-row: 2; width: 100%; }
  .reduce .view { grid-row: 3; width: 100%; max-width: none; }
}

/* ---------- Table (restaurant) ---------- */
.hours { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 1.2rem; border-top: 1px solid var(--line); padding-top: 1.3rem; margin-top: .6rem; }
.hours b { display: block; font-weight: 500; font-size: .9375rem; margin-bottom: .3rem; }
.hours span { color: var(--fg-2); font-size: .8125rem; }

/* ---------- Gandia ---------- */
.town .head { display: grid; gap: 1.2rem; max-width: 46rem; margin-bottom: clamp(3rem, 5vw, 4.5rem); }
.strip { display: grid; grid-auto-flow: column; grid-auto-columns: clamp(15rem, 26vw, 25rem); gap: clamp(1rem, 1.8vw, 1.75rem); overflow-x: auto; scroll-snap-type: x mandatory; padding-inline: var(--gut); margin-inline: calc(var(--gut) * -1); padding-bottom: 1.5rem; scrollbar-width: none; cursor: grab; }
.strip::-webkit-scrollbar { display: none; }
.strip.is-drag { cursor: grabbing; scroll-snap-type: none; }
.strip figure { margin: 0; scroll-snap-align: start; }
.strip .img { aspect-ratio: .78; overflow: hidden; border-radius: 2px; }
.strip .img img { width: 100%; height: 100%; object-fit: cover; transition: transform 1.2s var(--ease-out); pointer-events: none; }
.strip figure:hover .img img { transform: scale(1.04); }
.strip figcaption { display: flex; justify-content: space-between; gap: 1rem; margin-top: .9rem; font-size: var(--t-small); }
.strip figcaption span:last-child { color: var(--fg-2); }
.strip figure:nth-child(even) { padding-top: 3.5rem; }

.mapwrap { margin-top: clamp(4rem, 7vw, 7rem); display: grid; grid-template-columns: minmax(0, 1.35fr) minmax(0, .65fr); gap: clamp(1.5rem, 3vw, 3rem); }
#map { height: min(72vh, 640px); border-radius: 2px; overflow: hidden; background: var(--night); }
.plist { list-style: none; margin: 0; padding: 0; display: grid; align-content: start; }
.plist button { width: 100%; text-align: left; display: grid; grid-template-columns: 1.6rem 1fr auto; gap: .9rem; align-items: baseline; padding: 1rem 0; border-top: 1px solid var(--line); color: var(--fg-2); transition: color .35s var(--ease-out); }
.plist li:last-child button { border-bottom: 1px solid var(--line); }
.plist button:hover, .plist button.on { color: var(--fg); }
.plist .n { font-size: .75rem; font-weight: 600; color: var(--accent); }
.plist .nm { font-size: 1rem; display: block; }
.plist .ds { display: block; font-size: .8125rem; margin-top: .35rem; max-height: 0; overflow: hidden; opacity: 0; transition: max-height .5s var(--ease-out), opacity .4s; }
.plist button.on .ds { max-height: 5rem; opacity: 1; }
.plist .d { font-size: .8125rem; white-space: nowrap; }
.mk-home { display: flex; align-items: center; gap: .5rem; padding: .45rem .8rem .45rem .5rem; background: var(--white); color: var(--green); border-radius: 999px; font: 500 .75rem/1 var(--sans); letter-spacing: .14em; box-shadow: 0 6px 24px rgb(0 0 0 / .3); }
.mk-home i { width: .55rem; height: .55rem; border-radius: 50%; background: var(--rust); }
.mk-pin { width: 1.7rem; height: 1.7rem; border-radius: 50%; background: var(--green); color: var(--white); box-shadow: inset 0 0 0 1px rgb(255 255 255 / .5); font: 600 .6875rem/1 var(--sans); display: grid; place-items: center; transition: transform .35s var(--ease-out), background-color .35s; cursor: pointer; }
.mk-pin.on, .mk-pin:hover { background: var(--rust); transform: scale(1.18); }
.maplibregl-ctrl-attrib { font: 10px/1.4 var(--sans) !important; }
.maplibregl-ctrl-group { border-radius: 999px !important; overflow: hidden; }

/* ---------- Booking ---------- */
.book .panel { display: grid; gap: clamp(2rem, 4vw, 3rem); }
.book .h2 { max-width: 16ch; }
.bk { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)) auto; border-radius: 999px; box-shadow: inset 0 0 0 1px var(--line); padding: .45rem; gap: .2rem; align-items: center; }
.bk .f { display: grid; gap: .2rem; padding: .55rem 1.6rem; border-radius: 999px; position: relative; transition: background-color .3s; }
.bk .f + .f::before { content: ''; position: absolute; left: 0; top: 25%; bottom: 25%; width: 1px; background: var(--line); }
.bk .f:hover { background: color-mix(in oklab, var(--fg) 6%, transparent); }
.bk label { font-size: .75rem; letter-spacing: .12em; text-transform: uppercase; color: var(--fg-2); }
.bk input, .bk select { font: 400 1rem/1.3 var(--sans); color: var(--fg); background: none; border: 0; padding: 0; width: 100%; appearance: none; -webkit-appearance: none; outline: none; color-scheme: inherit; }
.bk select option { color: #111; }
:root[data-theme="evening"] .bk input, :root[data-theme="night"] .bk input { color-scheme: dark; }
.bk .btn { --h: 3.6rem; }
.bk-note { display: flex; gap: .6rem; align-items: center; color: var(--fg-2); font-size: .8125rem; }
.bk-note [class*='ph-'] { font-size: 1rem; }

/* Drawer */
.drawer { position: fixed; inset: 0; z-index: 80; visibility: hidden; }
.drawer.is-open { visibility: visible; }
.drawer .scrim { position: absolute; inset: 0; background: rgb(14 15 15 / .55); opacity: 0; transition: opacity .5s var(--ease-out); }
.drawer.is-open .scrim { opacity: 1; }
.drawer .sheet { position: absolute; top: 0; right: 0; bottom: 0; width: min(520px, 100%); background: var(--white); color: var(--green); padding: 2rem clamp(1.5rem, 3vw, 2.75rem); display: flex; flex-direction: column; gap: 2rem; transform: translateX(100%); transition: transform .6s var(--ease-curtain); overflow-y: auto; }
.drawer.is-open .sheet { transform: none; }
.drawer .top { display: flex; justify-content: space-between; align-items: center; }
.drawer .top .wm { height: 18px; width: auto; }
.drawer .x { width: 44px; height: 44px; border-radius: 50%; display: grid; place-items: center; box-shadow: inset 0 0 0 1px color-mix(in oklab, var(--green) 18%, transparent); transition: transform 160ms var(--ease-out); }
.drawer .x:active { transform: scale(.95); }
.drawer .h3 { max-width: 16ch; }
.drawer .body { color: color-mix(in oklab, var(--green) 75%, var(--white)); }
.drawer .slot { border: 1px dashed color-mix(in oklab, var(--green) 30%, transparent); border-radius: 14px; padding: 1.2rem; font-size: .8125rem; color: color-mix(in oklab, var(--green) 70%, var(--white)); display: flex; gap: .8rem; }
.drawer .slot [class*='ph-'] { font-size: 1.2rem; flex: none; margin-top: .1rem; }
.field { display: grid; gap: .5rem; }
.field label { font-size: .875rem; font-weight: 500; }
.field input { font: 400 1rem/1.4 var(--sans); padding: .95rem 1.1rem; border-radius: 12px; border: 1px solid color-mix(in oklab, var(--green) 28%, transparent); background: var(--white); color: var(--green); }
.field input:focus { outline: none; border-color: var(--green); box-shadow: 0 0 0 3px color-mix(in oklab, var(--green) 12%, transparent); }
.field .help { font-size: .8125rem; color: color-mix(in oklab, var(--green) 68%, var(--white)); }
.field .err { font-size: .8125rem; color: var(--rust); min-height: 1.1em; }
.drawer .btn-solid { background: var(--green); color: var(--white); justify-content: center; }
.drawer .ok { display: none; gap: .8rem; align-items: center; padding: 1rem 1.1rem; border-radius: 12px; background: color-mix(in oklab, var(--sage) 16%, var(--white)); font-size: .9375rem; }
.drawer form.done .ok { display: flex; }
.drawer form.done .field, .drawer form.done .btn { display: none; }

/* ---------- Footer ---------- */
.foot { padding: clamp(5rem, 9vw, 9rem) var(--gut) 2rem; max-width: var(--max); margin-inline: auto; }
.foot .cols { display: grid; grid-template-columns: 1.3fr 1fr 1fr 1fr; gap: 2rem; padding-bottom: clamp(3rem, 6vw, 5.5rem); }
.foot .cols p { margin: .55rem 0 0; color: var(--fg-2); font-size: var(--t-small); }
.foot .cols a { display: inline-block; }
.foot .big .wm { width: 100%; height: auto; display: block; }
.foot .base { display: flex; justify-content: space-between; gap: 1rem; padding-top: 1.5rem; margin-top: clamp(1.5rem, 3vw, 2.5rem); border-top: 1px solid var(--line); font-size: .8125rem; color: var(--fg-2); flex-wrap: wrap; }

/* ---------- Reveal primitives (JS adds .rv; reduced motion never hides) ---------- */
.js .rv { opacity: 0; transform: translateY(24px); }
.js .rv-img { clip-path: inset(100% 0 0 0); }
.js .rv-img img { transform: scale(1.18); }

/* ---------- Responsive ---------- */
@media (max-width: 1080px) {
  .nav .links { display: none; }
  .menu-btn { display: inline-flex; }
  .nav { grid-template-columns: 1fr auto; }
}
@media (max-width: 900px) {
  .hero { grid-template-columns: 1fr; grid-template-rows: auto; padding-top: 104px; }
  .hero .copy { order: 1; }
  .hero .frame { grid-row: auto; grid-column: 1; order: 2; aspect-ratio: .95; min-height: 0; width: 100%; }
  .hero .mark { order: 3; }
  .manifesto .facts { grid-template-columns: repeat(2, minmax(0, 1fr)); row-gap: 2.5rem; }
  .plan .grid, .mapwrap { grid-template-columns: 1fr; }
  .bk { grid-template-columns: 1fr; border-radius: 24px; padding: .5rem; }
  .bk .f + .f::before { left: 1.6rem; right: 1.6rem; top: 0; bottom: auto; width: auto; height: 1px; }
  .bk .btn { justify-content: center; }
  .foot .cols { grid-template-columns: 1fr 1fr; row-gap: 2.5rem; }
  #map { height: 64vh; }
  .plan-pin { grid-template-columns: 1fr; grid-template-rows: auto 1fr; padding-top: 88px; padding-bottom: 1.5rem; gap: 1rem; align-content: start; }
  .plan-copy { grid-row: 1; min-height: 11.5rem; }
  .plan-copy .h2 { font-size: clamp(2rem, 8vw, 2.6rem); }
  .plan-copy .body { font-size: .9375rem; }
  .count { font-size: 2.6rem; margin-top: .2rem; }
  .stage { grid-row: 2; max-height: none; align-self: start; }
  .view { grid-row: 2; position: absolute; left: 0; bottom: 0; width: min(62vw, 300px); }
}
@media (max-width: 560px) {
  .nav { height: 64px; }
  .nav .btn { display: none; }
  .hours { grid-template-columns: 1fr 1fr; }
  .strip figure:nth-child(even) { padding-top: 0; }
  .foot .cols { grid-template-columns: 1fr; }
}

@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after { animation-duration: .01ms !important; animation-iteration-count: 1 !important; transition-duration: .2s !important; scroll-behavior: auto !important; }
  .manifesto .quote .w { opacity: 1; }
  .hs::after { display: none; }
}

/* =========================================================
   Character layer
   ========================================================= */

/* Persiana light. A slatted Valencian shutter casts light (night: warm lamplight)
   or shade (day) across the page. It sits behind all content, on the body colour only. */
@property --sunc { syntax: '<color>'; inherits: true; initial-value: rgb(0 0 0 / 0); }
.sun {
  position: fixed; inset: 0; z-index: 0; pointer-events: none; overflow: hidden;
  --sunc: color-mix(in oklab, var(--green) 10%, transparent);
  transition: --sunc 1.1s var(--ease-io);
}
:root[data-theme="night"] .sun { --sunc: color-mix(in oklab, var(--sand) 24%, transparent); }
:root[data-theme="stone"] .sun { --sunc: color-mix(in oklab, var(--green) 13%, transparent); }
:root[data-theme="evening"] .sun { --sunc: color-mix(in oklab, var(--sand) 17%, transparent); }
.sun .win { position: absolute; left: -4vw; top: -16vh; width: 62vmax; height: 84vmax; will-change: transform; }
.sun .win::before { content: ''; position: absolute; inset: 10% 0; background: radial-gradient(ellipse 50% 46% at 50% 50%, var(--sunc), transparent 70%); transform: rotate(-24deg) skewX(-20deg); opacity: .55; }
.sun i {
  position: absolute; inset: 0;
  background: repeating-linear-gradient(180deg, transparent 0, var(--sunc) .35vmax, var(--sunc) 1.15vmax, transparent 1.55vmax, transparent 2.5vmax);
  transform: rotate(-24deg) skewX(-20deg);
  filter: blur(6px);
  -webkit-mask-image: linear-gradient(90deg, #000 44%, transparent 47.5% 50.5%, #000 54%), radial-gradient(ellipse 48% 44% at 50% 48%, #000 35%, transparent 100%);
  -webkit-mask-composite: source-in;
  mask-image: linear-gradient(90deg, #000 44%, transparent 47.5% 50.5%, #000 54%), radial-gradient(ellipse 48% 44% at 50% 48%, #000 35%, transparent 100%);
  mask-composite: intersect;
}
main, .foot { position: relative; z-index: 1; }

/* The route: distances read as stops on a line out of the hotel door. */
.manifesto .facts.route { border-top: 0; position: relative; padding-top: 3.4rem; }
.route::before {
  content: ''; position: absolute; left: 0; right: 0; top: 1.15rem; height: 1px;
  background: linear-gradient(90deg, var(--fg) calc(75% + 1.5rem), transparent 0), repeating-linear-gradient(90deg, var(--fg-2) 0 4px, transparent 4px 10px);
  transform-origin: 0 50%; transform: scaleX(var(--route, 1));
}
.route > div { position: relative; }
.route > div::before {
  content: ''; position: absolute; left: 0; top: calc(1.15rem - 3.4rem - 4.5px);
  width: 9px; height: 9px; border-radius: 50%; background: var(--bg); box-shadow: inset 0 0 0 1px var(--fg);
  transition: background-color .9s var(--ease-io);
}
.route > div:last-of-type::before { background: var(--rust); box-shadow: none; }
.route-o { position: absolute; left: 1.1rem; top: -.35rem; font-size: .6875rem; letter-spacing: .14em; text-transform: uppercase; color: var(--fg-2); }
.route > div:first-of-type::before { background: var(--fg); box-shadow: none; border-radius: 1px; }
@media (max-width: 900px) {
  .route::before { display: none; }
  .route > div { border-top: 1px solid var(--line); padding-top: 1.4rem; }
  .route > div::before { left: 0; top: -4.5px; }
  .manifesto .facts.route { padding-top: 2.6rem; }
  .route-o { top: 0; }
}

/* Booking: evening room behind the bar, so the slot reads as an arrival, not a form. */
.book { isolation: isolate; min-height: min(96vh, 980px); display: grid; align-content: end; overflow: clip; }
.book-bg { position: absolute; inset: 0; z-index: -1; }
.book-bg img { width: 100%; height: 118%; object-fit: cover; object-position: 50% 40%; opacity: .55; filter: saturate(.8); }
.book-bg::after { content: ''; position: absolute; inset: 0; background: linear-gradient(180deg, var(--bg) 0%, color-mix(in oklab, var(--bg) 35%, transparent) 30%, color-mix(in oklab, var(--bg) 45%, transparent) 55%, var(--bg) 96%); }
.book .bk { background: color-mix(in oklab, var(--green) 62%, transparent); -webkit-backdrop-filter: blur(14px); backdrop-filter: blur(14px); }

@media (prefers-reduced-motion: reduce) { .sun { transition: none; } }

/* =========================================================
   Phone layer
   ========================================================= */

/* Shutter menu: 14 slats swing down from their top edge, one after another */
.mmenu { background: transparent; clip-path: none; transition: visibility 0s linear .95s; }
.mmenu.is-open { clip-path: none; transition: visibility 0s; }
.mmenu > :not(.slats) { position: relative; }
.slats { position: absolute; inset: 0; display: flex; flex-direction: column; perspective: 1100px; }
.slats i {
  flex: 1; background: linear-gradient(180deg, color-mix(in oklab, var(--night) 88%, var(--sand)) 0%, var(--night) 22%, var(--night) 82%, color-mix(in oklab, var(--night) 80%, black) 100%);
  transform: rotateX(-92deg); transform-origin: 50% 0; backface-visibility: hidden;
  transition: transform .62s var(--ease-out) calc((13 - var(--k)) * 22ms);
}
.mmenu.is-open .slats i { transform: none; transition-delay: calc(var(--k) * 26ms); }
.mmenu.is-open nav a { transition-delay: calc(.38s + var(--i) * .07s); }
.mmenu .meta { opacity: 0; transition: opacity .4s var(--ease-out); }
.mmenu.is-open .meta { opacity: 1; transition-delay: .6s; }

/* Booking dock */
.dock { display: none; }
@media (max-width: 1080px) {
  .dock {
    position: fixed; z-index: 44; left: 50%; bottom: max(14px, env(safe-area-inset-bottom)); width: min(calc(100% - 2 * var(--gut)), 420px);
    display: flex; align-items: center; justify-content: space-between; gap: 1rem; padding: .4rem .4rem .4rem 1.2rem; border-radius: 999px;
    background: color-mix(in oklab, var(--night) 78%, transparent); -webkit-backdrop-filter: blur(16px) saturate(1.2); backdrop-filter: blur(16px) saturate(1.2);
    color: var(--white); box-shadow: inset 0 0 0 1px rgb(255 255 255 / .1), 0 18px 40px -16px rgb(0 0 0 / .45);
    transform: translate(-50%, calc(100% + 28px)); transition: transform .55s var(--ease-out);
  }
  .dock.is-on { transform: translate(-50%, 0); }
  .sheet-open .dock { transform: translate(-50%, calc(100% + 28px)); }
  .dock:active { transform: translate(-50%, 0) scale(.97); transition-duration: .16s; }
  .dk-l { display: flex; align-items: center; gap: .6rem; font-size: .8125rem; letter-spacing: .02em; color: rgb(255 255 255 / .8); }
  .dk-dot { width: 7px; height: 7px; border-radius: 50%; background: var(--rust-2, #b0654a); box-shadow: 0 0 0 4px rgb(176 101 74 / .2); }
  .dk-b { display: inline-flex; align-items: center; gap: .5rem; background: var(--white); color: var(--green); border-radius: 999px; padding: .7rem 1.15rem; font-size: .9375rem; }
}

/* Booking as a bottom sheet on phones */
@media (max-width: 700px) {
  .drawer .sheet { top: auto; left: 0; width: 100%; max-height: 90dvh; border-radius: 22px 22px 0 0; padding: 1.1rem var(--gut) max(1.6rem, env(safe-area-inset-bottom)); gap: 1.4rem; transform: translateY(100%); transition: transform .5s cubic-bezier(.32, .72, 0, 1); }
  .drawer .top { position: relative; padding-top: .9rem; touch-action: none; cursor: grab; }
  .drawer .top::before { content: ''; position: absolute; top: 0; left: 50%; width: 38px; height: 4px; margin-left: -19px; border-radius: 4px; background: color-mix(in oklab, var(--green) 22%, transparent); }
  .drawer .h3 { font-size: clamp(1.7rem, 7.5vw, 2.1rem); }
}
@media (prefers-reduced-motion: reduce) {
  .slats i, .mmenu.is-open .slats i { transition-duration: .01s; transition-delay: 0s; }
}


/* =========================================================
   The room: one render, five materials, a slow camera
   ========================================================= */
.room { position: relative; }
.rm-pin { min-height: 100dvh; display: grid; grid-template-columns: minmax(0, .5fr) minmax(0, 1.5fr); gap: clamp(2rem, 4vw, 4.5rem); align-items: center; padding-block: 110px 3rem; }
.rm-copy { display: grid; gap: 1.4rem; align-content: center; }
.rm-copy .body { max-width: 30ch; }
.rm-index { list-style: none; margin: 1.2rem 0 0; padding: 0; display: grid; counter-reset: s; }
.rm-index button { width: 100%; display: grid; grid-template-columns: 2.2rem 1fr; grid-template-rows: auto auto; column-gap: .6rem; text-align: left; padding: .8rem 0; border-top: 1px solid var(--line); color: var(--fg-2); position: relative; transition: color .45s var(--ease-out); }
.rm-index li:last-child button { border-bottom: 1px solid var(--line); }
.rm-index .n { grid-row: 1 / span 2; font-size: .75rem; letter-spacing: .1em; padding-top: .3rem; font-variant-numeric: tabular-nums; }
.rm-index .nm { font: 400 1.25rem/1.2 var(--serif); }
.rm-index .wh { font-size: .8125rem; opacity: 0; max-height: 0; overflow: hidden; transition: opacity .45s var(--ease-out), max-height .45s var(--ease-out); }
.rm-index button::before { content: ''; position: absolute; left: 0; right: 0; top: -1px; height: 1px; background: var(--fg); transform: scaleX(0); transform-origin: 0 50%; transition: transform .7s var(--ease-out); }
.rm-index button[aria-current="true"] { color: var(--fg); }
.rm-index button[aria-current="true"] .n { color: var(--rust); }
.rm-index button[aria-current="true"] .wh { opacity: .75; max-height: 2em; }
.rm-index button[aria-current="true"]::before { transform: scaleX(1); }
.rm-index button:hover { color: var(--fg); }

.rm-stage { position: relative; margin: 0; height: min(calc(100dvh - 170px), 60vw); min-height: 380px; overflow: hidden; border-radius: 2px; background: var(--green); container-type: size; isolation: isolate; }
.rm-frame { position: absolute; left: 50%; top: 50%; width: max(100cqw, 140cqh); aspect-ratio: 1.4; transform: translate(-50%, -50%); }
.rm-zoom { position: absolute; inset: 0; transform-origin: 0 0; will-change: transform; --s: 1; }
.rm-zoom img { position: absolute; inset: 0; width: 100%; height: 100%; object-fit: cover; }
.rm-dot { position: absolute; left: var(--x); top: var(--y); width: 26px; height: 26px; margin: -13px 0 0 -13px; border-radius: 50%; display: grid; place-items: center; font-size: .6875rem; color: var(--white); background: rgb(30 32 31 / .35); box-shadow: inset 0 0 0 1px rgb(255 255 255 / .7); -webkit-backdrop-filter: blur(6px); backdrop-filter: blur(6px); transform: scale(calc(1 / var(--s))); transition: background-color .4s var(--ease-out), box-shadow .4s var(--ease-out); }
.rm-dot.on { background: var(--rust); box-shadow: 0 0 0 6px rgb(139 58 36 / .25); }
.rm-spot { position: absolute; inset: 0; pointer-events: none; z-index: 2; --sx: 50%; --sy: 50%; --r: 2000px;
  background: radial-gradient(circle var(--r) at var(--sx) var(--sy), transparent 0 50%, rgb(20 22 21 / .42) 100%); }
.rm-bath { position: absolute; inset: 0; z-index: 1; opacity: 0; visibility: hidden; }
.rm-bath img { position: absolute; inset: 0; width: 100%; height: 100%; object-fit: cover; object-position: 50% 62%; transition: opacity .7s var(--ease-io), filter .7s var(--ease-io); }
.rm-bath img + img { opacity: 0; }
.rm-bath[data-finish="sand"] img + img { opacity: 1; }
.rm-bath.switching img { filter: blur(3px); }
.rm-cap { position: absolute; z-index: 3; left: clamp(.8rem, 1.6vw, 1.4rem); right: clamp(.8rem, 1.6vw, 1.4rem); bottom: clamp(.8rem, 1.6vw, 1.4rem); display: flex; align-items: center; gap: 1rem; padding: .7rem 1.2rem .7rem .7rem; border-radius: 999px; width: fit-content; max-width: calc(100% - 1.6rem);
  background: color-mix(in oklab, var(--white) 84%, transparent); -webkit-backdrop-filter: blur(18px) saturate(1.2); backdrop-filter: blur(18px) saturate(1.2); color: var(--green); box-shadow: 0 20px 50px -24px rgb(20 22 21 / .55); }
.rm-sw { position: relative; flex: none; width: 3.4rem; height: 3.4rem; border-radius: 50%; overflow: hidden; box-shadow: 0 0 0 1px rgb(44 46 45 / .15); }
.rm-sw i { position: absolute; inset: -10%; background-size: cover; background-position: center; transition: opacity .6s var(--ease-io), transform 1.2s var(--ease-out); }
.rm-sw i + i { opacity: 0; }
.rm-t { display: grid; gap: .1rem; min-width: 0; }
.rm-name { font: 400 1.35rem/1.15 var(--serif); }
.rm-note { font-size: .8125rem; color: color-mix(in oklab, var(--green) 72%, var(--white)); text-wrap: pretty; }
.rm-cap .seg { display: none; margin-left: .4rem; --line: color-mix(in oklab, var(--green) 18%, transparent); --fg: var(--green); --bg: var(--white); }
.rm-cap.bath .seg { display: inline-flex; }
.rm-cap.swap .rm-t { animation: rmSwap .55s var(--ease-out); }
@keyframes rmSwap { from { opacity: 0; transform: translateY(6px); filter: blur(3px); } }
.rm-prog { position: absolute; z-index: 3; top: 1rem; left: 1rem; right: 1rem; height: 2px; display: flex; gap: 4px; }
.rm-prog i { flex: 1; background: rgb(255 255 255 / .35); border-radius: 2px; overflow: hidden; position: relative; }
.rm-prog i::after { content: ''; position: absolute; inset: 0; background: var(--white); transform: scaleX(var(--f, 0)); transform-origin: 0 50%; }

@media (max-width: 900px) {
  .rm-pin { grid-template-columns: 1fr; grid-template-rows: auto 1fr; padding-block: 88px 1.2rem; gap: 1.1rem; align-content: start; height: 100dvh; min-height: 0; }
  .rm-copy { gap: .7rem; }
  .rm-copy .body { display: none; }
  .rm-index { margin: 0; grid-auto-flow: column; grid-auto-columns: 1fr; gap: 6px; }
  .rm-index button { grid-template-columns: 1fr; padding: .55rem 0 0; border-top: 0; border-bottom: 0 !important; }
  .rm-index button::after { content: ''; position: absolute; left: 0; right: 0; top: 0; height: 2px; background: var(--line); border-radius: 2px; }
  .rm-index button::before { height: 2px; top: 0; z-index: 1; border-radius: 2px; }
  .rm-index .n { grid-row: auto; padding: 0; }
  .rm-index .nm, .rm-index .wh { display: none; }
  .rm-stage { height: auto; min-height: 0; align-self: stretch; }
  .rm-prog { display: none; }
  .rm-cap { border-radius: 18px; align-items: flex-start; flex-wrap: wrap; padding: .6rem; row-gap: .6rem; }
  .rm-cap .rm-t { flex: 1; padding-top: .2rem; }
  .rm-cap .seg { margin-left: 0; }
  .rm-name { font-size: 1.2rem; }
  .rm-sw { width: 2.9rem; height: 2.9rem; }
}
.reduce .rm-pin, .no-gsap .rm-pin { height: auto; }

/* =========================================================
   Wardrobe: real doors on a real hinge
   ========================================================= */
.compare .head { display: grid; gap: 1.2rem; justify-items: start; margin-bottom: clamp(2.5rem, 5vw, 4rem); max-width: 44rem; }
.ward { position: relative; aspect-ratio: 1.4; overflow: hidden; border-radius: 2px; cursor: grab; touch-action: pan-y; user-select: none; -webkit-user-select: none; --a: 0; background: #6d3420; }
.ward:active { cursor: grabbing; }
.ward img { position: absolute; inset: 0; width: 100%; height: 100%; object-fit: cover; pointer-events: none; -webkit-user-drag: none; }
.ward .in { filter: brightness(calc(.55 + var(--a) * .45)); }
.ward .glow { position: absolute; left: 8%; top: 7.3%; width: 33%; height: 88.5%; pointer-events: none; mix-blend-mode: screen; opacity: calc(var(--a) * var(--a)); background: radial-gradient(ellipse 70% 40% at 50% 22%, rgb(255 196 140 / .45), transparent 70%); }
.ward .shell { clip-path: polygon(evenodd, 0 0, 100% 0, 100% 100%, 0 100%, 0 0, 8% 7.3%, 41% 7.3%, 41% 95.8%, 8% 95.8%, 8% 7.3%); }
.ward .door { position: absolute; top: 7.3%; height: 88.5%; width: 16.5%; overflow: hidden; backface-visibility: hidden; will-change: transform; }
.ward .door img { max-width: none; width: calc(100% * 100 / 16.5); height: calc(100% * 100 / 88.5); top: calc(-100% * 7.3 / 88.5); inset-inline: auto; }
.ward .d1 { left: 8%; transform-origin: 0 50%; transform: rotateY(calc(var(--a) * -82deg)); }
.ward .d1 img { left: calc(-100% * 8 / 16.5); }
.ward .d2 { left: 24.5%; transform-origin: 100% 50%; transform: rotateY(calc(var(--a) * 82deg)); }
.ward .d2 img { left: calc(-100% * 24.5 / 16.5); }
.ward .door::after { content: ''; position: absolute; inset: 0; opacity: calc(var(--a) * 1.3); }
.ward .d1::after { background: linear-gradient(90deg, rgb(255 230 200 / .06), rgb(0 0 0 / .32)); }
.ward .d2::after { background: linear-gradient(270deg, rgb(255 230 200 / .06), rgb(0 0 0 / .32)); }
.ward-frame { position: absolute; inset: 0; perspective: 1800px; perspective-origin: 26% 45%; }
.ward-frame::after { content: ''; position: absolute; left: 8%; top: 7.3%; width: 33%; height: 88.5%; pointer-events: none; box-shadow: inset 0 0 60px rgb(0 0 0 / .45); opacity: calc(var(--a) * 1.4); }
.ward-hint { position: absolute; left: 1.1rem; bottom: 1.1rem; display: inline-flex; align-items: center; gap: .55rem; padding: .55rem .9rem; border-radius: 999px; font-size: .8125rem; color: var(--white); background: rgb(30 32 31 / .35); -webkit-backdrop-filter: blur(12px); backdrop-filter: blur(12px); box-shadow: inset 0 0 0 1px rgb(255 255 255 / .25); transition: opacity .5s var(--ease-out); pointer-events: none; }
.ward.used .ward-hint { opacity: 0; }
.ward-btn [class*='ph-'] { font-size: 1.15rem; }
@media (max-width: 900px) {
  .ward { aspect-ratio: .9; }
  .ward-frame { inset: 0 auto 0 -4%; aspect-ratio: 1.4; height: 100%; }
}
.credits { flex-basis: 100%; font-size: .75rem; color: var(--fg-2); }
.credits summary { cursor: pointer; list-style: none; text-decoration: underline; text-underline-offset: 3px; text-decoration-color: var(--line); width: fit-content; }
.credits summary::-webkit-details-marker { display: none; }
.credits ul { margin: .8rem 0 0; padding: 0; list-style: none; display: grid; gap: .3rem; }
@media (max-width: 1080px) {
  .rm-pin, .plan-pin { padding-bottom: calc(92px + env(safe-area-inset-bottom)); }
}
@media (max-width: 900px) {
  .rm-cap .seg { order: 3; }
  .rm-cap .rm-t { flex-basis: calc(100% - 4rem); }
}
