/* Text-led chapter controls keep each destination clear without a button frame. */
.e-chapter-options {
  position: absolute;
  inset: auto var(--e-gutter) 105px;
  display: flex;
  align-items: end;
  justify-content: space-between;
  gap: 28px;
  z-index: 7;
  pointer-events: none;
  opacity: 0;
  visibility: hidden;
  transition: opacity 180ms ease;
}
.is-entered .e-chapter-options { opacity: 1; visibility: visible; }
.is-entered[data-gallery-room="1"] .e-chapter-options { color: #f1e9db; }
.is-entered[data-gallery-room="2"] .e-chapter-options { color: #2d281f; }
.e-chapter-choice {
  display: inline-flex;
  align-items: end;
  gap: 0;
  min-height: 80px;
  pointer-events: auto;
  text-align: left;
  appearance: none;
  -webkit-appearance: none;
  border: 0;
  border-radius: 0;
  outline: none;
  box-shadow: none;
  background: transparent;
  -webkit-tap-highlight-color: transparent;
}
.e-chapter-choice-right { text-align: right; }
.e-chapter-label { display: flex; flex-direction: column; gap: 3px; }
.e-chapter-number {
  font: 400 clamp(12px, 1.05vw, 17px)/1.25 var(--e-serif);
  letter-spacing: .04em;
  opacity: .8;
}
.e-chapter-name {
  display: block;
  font: 400 clamp(46px, 5.2vw, 88px)/.94 var(--e-serif);
  letter-spacing: -.035em;
}
.e-chapter-name {
  text-decoration-thickness: 1px;
  text-underline-offset: .16em;
  text-decoration-skip-ink: auto;
}
/* Keep keyboard focus visible on the label, not a large Safari wrapper outline. */
.e-chapter-choice:focus,
.e-chapter-choice:focus-visible { outline: none; }
.e-chapter-choice:focus-visible .e-chapter-name {
  text-decoration-line: underline;
  text-decoration-thickness: 2px;
}
@media (hover: hover) {
  .e-chapter-choice:hover .e-chapter-name { text-decoration-line: underline; }
}
.e-chapter-options[aria-hidden="true"],
.is-entered .e-chapter-options[aria-hidden="true"],
.is-crossing .e-chapter-options {
  opacity: 0;
  visibility: hidden;
  pointer-events: none;
}
.is-travelling .e-chapter-options,
.is-crossing .e-chapter-options {
  opacity: 0;
  pointer-events: none;
}
.is-travelling .e-chapter-choice,
.is-crossing .e-chapter-choice { pointer-events: none; }

.e-room-nav { pointer-events: none; user-select: none; }
.e-room-indicator {
  display: flex;
  align-items: center;
  gap: 8px;
  min-height: 44px;
  font-size: 11px;
  opacity: .6;
  transition: opacity 240ms ease;
}
.e-room-indicator[aria-current="true"] { opacity: 1; font-weight: 550; }
.e-room-heading { z-index: 1; }
.e-room-heading .e-room-foot {
  position: static;
  display: block;
  margin-top: 22px;
}
.e-room-heading .e-room-foot > p { display: none; }
.e-room-heading .e-room-foot .e-action {
  width: 165px;
  min-height: 44px;
  justify-content: flex-start;
}
.is-entered[data-gallery-room="1"] .e-room-heading .e-room-foot { color: #f1e9db; }
.is-entered[data-gallery-room="1"] .e-room-heading .e-room-foot .e-action { border-bottom-color: #f1e9db66; }

/* The same translucent invitation sits within both existing portal links. */
.e-discover-door { cursor: pointer; }
.e-discover-door::after { content: none; }
.e-discover-label {
  position: absolute;
  left: 50%;
  top: 77%;
  transform: translate(-50%, -50%);
  display: grid;
  place-items: center;
  min-width: 174px;
  min-height: 60px;
  padding: 12px 28px;

}
.e-discover-label,
.entrance-page .e-welcome .e-enter.e-glass-entry {
  border: 1px solid rgb(255 251 242 / 70%);
  border-radius: 999px;
  background: linear-gradient(135deg, rgb(255 255 255 / 42%), rgb(241 231 212 / 16%) 48%, rgb(255 255 255 / 26%));
  color: #29291f;
  box-shadow: inset 0 1px 0 rgb(255 255 255 / 65%), inset 0 -1px 0 rgb(143 126 101 / 12%), 0 8px 24px rgb(40 34 23 / 14%);
  backdrop-filter: blur(14px) saturate(115%);
  -webkit-backdrop-filter: blur(14px) saturate(115%);
  font: 400 17px/1.2 var(--e-sans);
  letter-spacing: .035em;
  text-shadow: none;
  transition: background 220ms ease, box-shadow 220ms ease, transform 220ms ease;
}
.e-studio-door .e-discover-label { top: 97%; }
.e-discover-door:focus-visible { outline: none; }
.e-discover-door:focus-visible .e-discover-label { outline: 2px solid #f6eee0; outline-offset: 5px; }
@media (hover: hover) {
  .e-discover-door:hover .e-discover-label {
    background: linear-gradient(135deg, rgb(255 255 255 / 56%), rgb(241 231 212 / 28%) 48%, rgb(255 255 255 / 40%));
    box-shadow: inset 0 1px 0 rgb(255 255 255 / 80%), inset 0 -1px 0 rgb(143 126 101 / 12%), 0 12px 30px rgb(40 34 23 / 18%);
    transform: translate(-50%, calc(-50% - 3px));
  }
}

@media (min-width: 601px) and (max-aspect-ratio: 1/1) {
  .e-chapter-options { bottom: 61px; }
  .is-entered .e-motion { bottom: 12px; }
  .e-room-indicator { justify-content: flex-end; }
  /* Follow the plinth as the portrait film scales with the viewport width. */
  .e-studio-door { height: calc(16svh + 46vw + 30px); }
  .e-studio-door .e-discover-label { top: calc(16svh + 46vw); }
}
@media (max-width: 600px) {
  .e-chapter-options { inset: auto 22px 78px; gap: 16px; }
  .e-chapter-choice { min-height: 66px; }
  .e-chapter-label { gap: 3px; }
  .e-chapter-name { font-size: clamp(34px, 9.4vw, 48px); }
  .e-chapter-number { font-size: 11px; }
  .is-entered .e-room-nav { bottom: 17px; }
  .is-entered .e-motion { bottom: 34px; }
  .is-entered[data-gallery-room="1"] .e-chapter-options { color: #252321; }
  .e-room-indicator { font-size: 10px; gap: 5px; }
  .e-room-heading .e-room-foot { margin-top: 16px; }
  .e-room-heading .e-room-foot .e-action { width: 145px; }
  .e-discover-label { min-width: 164px; min-height: 56px; font-size: 16px; }
}
@media (max-height: 650px) and (min-width: 601px) {
  .e-chapter-options { bottom: 90px; }
  .e-chapter-name { font-size: 46px; }
}
@media (max-height: 650px) and (max-width: 600px) {
  .e-chapter-options { bottom: 23px; }
  .is-entered .e-room-nav { visibility: hidden; pointer-events: none; }
  .is-entered .e-motion { top: 68px; bottom: auto; min-height: 32px; }
  .e-room-heading .e-room-foot { margin-top: 8px; }
  .e-discover-label { min-width: 152px; min-height: 48px; padding-block: 10px; }
}
@media (prefers-reduced-motion: reduce) {
  .e-chapter-options, .e-discover-label { transition: none; }
  .e-discover-door:hover .e-discover-label { transform: translate(-50%, -50%); }
}

/* The opening action shares the portal glass and sits higher in the doorway. */
.e-welcome { --e-entry-bottom: clamp(190px,26svh,260px); }
.e-welcome .e-enter.e-glass-entry {
  display:grid;
  place-items:center;
  justify-content:center;
  gap:0;
  width:224px;
  min-height:60px;
  padding:12px 24px;
  white-space:nowrap;
}
.e-welcome .e-enter.e-glass-entry::after { content:none; }
@media(hover:hover){
  .entrance-page .e-welcome .e-enter.e-glass-entry:hover {
    background:linear-gradient(135deg,rgb(255 255 255 / 56%),rgb(241 231 212 / 28%) 48%,rgb(255 255 255 / 40%));
    box-shadow:inset 0 1px 0 rgb(255 255 255 / 80%),inset 0 -1px 0 rgb(143 126 101 / 12%),0 12px 30px rgb(40 34 23 / 18%);
  }
}
.e-welcome .e-enter.e-glass-entry:focus-visible { outline:2px solid #f6eee0;outline-offset:5px; }
@media(max-aspect-ratio:1/1){ .e-welcome { --e-entry-bottom:132px; } }
@media(max-width:600px){
  .e-welcome { --e-entry-bottom:137px; }
  .entrance-page .e-welcome .e-enter.e-glass-entry { width:210px;min-height:56px;font-size:15px; }
}
@media(max-height:650px) and (max-width:600px){
  .e-welcome { --e-entry-bottom:114px; }
  .entrance-page .e-welcome .e-enter.e-glass-entry { min-height:48px; }
}
@media(prefers-reduced-motion:reduce){ .entrance-page .e-welcome .e-enter.e-glass-entry { transition:none; } }

/* Sculptural strokes and optical glass echo the gallery portals. */
.e-chapter-choice{gap:18px;align-items:center}
.e-chapter-arrow{display:grid;place-items:center;width:58px;height:58px;flex:none;border:1px solid rgb(255 250 239 / 58%);border-radius:50%;background:linear-gradient(135deg,rgb(255 250 239 / 24%),rgb(95 85 66 / 26%));box-shadow:inset 0 1px 0 #fff8e84d,0 4px 18px #211c1512;backdrop-filter:blur(12px) saturate(110%);-webkit-backdrop-filter:blur(12px) saturate(110%);color:inherit;transition:background 220ms ease,box-shadow 220ms ease}
.e-chapter-arrow svg{display:block;width:34px;height:34px;stroke:currentColor;stroke-width:1;stroke-linecap:round;stroke-linejoin:round}
.e-chapter-choice-left .e-chapter-arrow svg{transform:rotate(180deg)}
@media(hover:hover){.e-chapter-choice:hover .e-chapter-arrow{background:linear-gradient(135deg,#fffaf04d,#9b8c7238);box-shadow:inset 0 1px 0 #fff8e87a,0 6px 20px #211c151c}}
@media(max-width:600px){.e-chapter-choice{gap:9px}.e-chapter-arrow{width:40px;height:40px}.e-chapter-arrow svg{width:26px;height:26px}.e-chapter-name{font-size:clamp(28px,8vw,44px)}}
@media(prefers-reduced-motion:reduce){.e-chapter-arrow{transition:none}}
