/* A first-time visitor can read the story's purpose without covering the castle. */
.arrival-introduction { position:absolute; z-index:12; left:var(--gutter); bottom:148px; width:min(340px,38vw); color:#eddec4; text-shadow:0 2px 12px #000; }
.arrival-introduction > p { font-size:16px; line-height:1.7; text-wrap:balance; }
.arrival-game-link { display:inline-flex; align-items:center; gap:22px; min-height:44px; margin-top:10px; font-size:14px; border-bottom:1px solid #d0b57b70; }
.arrival-game-link > span:last-child { color:#dfc28d; }
.story-product-link { display:inline-flex; align-items:center; min-height:44px; font-size:14px; color:#dfc8a2; }
.story[data-current="0"] .story-product-link { display:none; }
.story-product-link:hover,.arrival-game-link:hover { color:#fff0d2; }
/* On primary hall routes and return paths the small name belongs to the clickable arrow. */
.room-marker[data-label-mode="persistent"] { width:max-content; max-width:160px; height:auto; min-height:48px; padding:4px 9px; display:flex; gap:4px; border-radius:5px; background:linear-gradient(90deg,#15130e08,#15130e70,#15130e08); }
.room-marker[data-label-mode="persistent"]::before { flex:none; width:22px; height:28px; }
.room-marker[data-label-mode="persistent"] .room-marker-label { position:static; left:auto; right:auto; bottom:auto; transform:none; display:block; width:auto; max-width:112px; padding:0; border:0; border-radius:0; background:none; box-shadow:none; opacity:1; visibility:visible; font-size:14px; line-height:1.35; text-align:left; text-shadow:0 2px 5px #100c09,0 0 10px #100c09; }
.room-marker[data-label-mode="persistent"] .room-marker-preview { display:none; }
.room-marker[data-primary="true"] .room-marker-name { color:#ffe1a2; }
.room-marker[data-primary="true"]::before { opacity:1; filter:brightness(1.18) drop-shadow(0 2px 4px #b7773333); }
.hall-game-reveal { filter:brightness(1.075) saturate(1.025); }
/* A small, dismissible invitation arrives once, after the visitor has knocked and entered. */
.porch-invitation { position:absolute; z-index:19; left:var(--gutter); bottom:132px; width:min(352px,42vw); max-height:calc(100svh - 250px); overflow:auto; padding:22px; border:1px solid #c2a16d70; border-radius:7px; color:#f0e0c4; background:linear-gradient(145deg,#24241cf5,#121b18fa); box-shadow:0 12px 40px #0006,inset 0 1px #ecd8ae0c; }
.porch-invitation-heading { display:flex; align-items:center; gap:15px; padding-right:12px; }
.invitation-character { display:block; width:66px; height:80px; flex:none; background-image:url('assets/characters.webp'); background-repeat:no-repeat; background-size:205% 205%; border-radius:3px; }
.invitation-kicker { font-size:12px; color:#bca67d; margin-bottom:8px; }
.porch-invitation h2 { font-size:20px; font-weight:400; line-height:1.5; text-wrap:balance; }
.invitation-note { margin-top:15px; color:#cdbda3; font-size:14px; line-height:1.65; }
.porch-invitation-close { position:absolute; top:3px; right:4px; width:44px; height:44px; font-size:25px; color:#c5b697; }
.invitation-actions { display:flex; flex-wrap:wrap; align-items:center; gap:5px 12px; margin-top:15px; }
.invitation-actions button { min-height:44px; padding:8px 10px; font-size:14px; line-height:1.4; }
.invitation-actions [data-accept-invitation] { color:#f7dfb3; border:1px solid #c2a16d80; border-radius:4px; background:#9a73362b; }
.invitation-actions [data-dismiss-invitation] { color:#c1b59e; }
.porch-invitation button:focus-visible { outline:2px solid #efd7aa; outline-offset:2px; }
/* The existing pick-up action follows the real painted tabletop. */
.game-table-action { position:absolute; z-index:12; transform:translate(-50%,-50%); display:flex; align-items:center; min-height:48px; max-width:calc(100% - 48px); padding:8px 13px; border:1px solid #d8b67685; border-radius:5px; background:linear-gradient(130deg,#413021ec,#211d16ed); color:#ffe8bd; font-size:14px; line-height:1.35; box-shadow:0 4px 14px #180e0750; cursor:pointer; }
.game-table-action::before { width:26px; height:26px; flex:none; }
.game-table-action:hover,.game-table-action:focus-visible { background:#53402aec; border-color:#ffe0a0; }
.story-deck:hover,.story-deck:focus-visible { box-shadow:0 0 26px #ffd38a26; }
.story.story-enhanced[data-current="3"] .story-actions { left:var(--gutter); right:auto; bottom:148px; max-width:43%; justify-content:flex-start; }
.story[data-current="3"] .story-actions > button { font-size:14px; background:#15191385; border-color:#bda57930; color:#d5c6ac; }
.story[data-current="3"] .story-actions > button::before { width:24px; height:24px; }
.story[data-current="3"] .story-actions .story-destination { position:static; flex-basis:100%; order:-1; max-width:340px; padding:12px 14px; text-align:left; pointer-events:auto; }
@media(max-width:760px),(max-aspect-ratio:4/5) {
 .arrival-introduction { left:24px; bottom:211px; width:calc(100% - 48px); max-width:360px; }
 .arrival-introduction > p { font-size:16px; }
 .arrival-game-link { margin-top:4px; }
 .room-marker[data-label-mode="persistent"] { min-height:44px; max-width:116px; padding:3px 5px; gap:2px; }
 .room-marker[data-label-mode="persistent"]::before { width:18px; height:24px; }
 .room-marker[data-label-mode="persistent"] .room-marker-label { max-width:84px; font-size:14px; }
 .porch-invitation { left:24px; right:24px; bottom:193px; width:auto; max-height:calc(100svh - 315px); padding:18px; }
 .invitation-character { width:54px; height:66px; }
 .porch-invitation h2 { font-size:18px; }
 .invitation-actions { margin-top:10px; }
 .game-table-action { min-height:44px; padding:7px 10px; }
 .story.story-enhanced[data-current="3"] .story-actions { left:24px; right:24px; bottom:199px; max-width:none; flex-wrap:wrap; }
 .story[data-current="3"] .story-actions .story-family-action { display:inline-flex; align-items:center; }
 .story[data-current="3"] .story-actions > button { flex:0 1 auto; min-height:44px; padding:8px 10px; }
 .story[data-current="3"] .story-actions .story-destination { max-width:none; padding:10px 12px; background:#141b17f0; }
}
@media(max-height:540px) and (min-aspect-ratio:4/5) {
 .site-header { height:64px; }
 .site-header nav { top:63px; }
 .story-viewport { height:100svh; min-height:0; }
 .story-aperture { inset:0; height:100%; }
 .story-lamp { top:74px; }
 .story-lamp .lamp-object { width:28px; height:44px; }
 .arrival-introduction { left:24px; width:min(320px,47vw); bottom:64px; }
 .story-route-action { right:24px; left:auto; bottom:64px; }
 .story-route-action .scene-menu .story-chapters { max-height:max(48px,calc(100svh - 256px)); }
 .story-footer { bottom:8px; }
 .story-footer .story-about-link { display:none; }
 .music-dock { bottom:8px; left:24px; right:auto; }
 .porch-invitation { left:24px; bottom:20px; width:min(460px,calc(100% - 48px)); max-height:calc(100svh - 128px); padding:12px; }
 .porch-invitation h2 { font-size:16px; line-height:1.4; }
 .invitation-character { width:44px; height:54px; }
 .invitation-note,.invitation-actions { margin-top:8px; }
 .story.story-enhanced[data-current="3"] .story-actions { left:24px; right:250px; bottom:64px; max-width:none; flex-wrap:wrap; }
 .story[data-current="3"] .story-actions .story-family-action { display:inline-flex; align-items:center; }
 .story[data-current="3"] .story-actions > button { flex:0 1 auto; min-height:44px; padding:6px 8px; }
 .story[data-current="3"] .story-actions .story-destination { display:flex; align-items:center; flex-wrap:wrap; gap:4px 10px; padding:4px 8px; max-width:none; }
 .story[data-current="3"] .destination-kicker { display:none; }
 .story[data-current="3"] .destination-name { font-size:14px; margin:0; }
 .story[data-current="3"] .destination-meet { font-size:14px; min-height:44px; padding:4px 8px; margin:0; }
 .story.story-enhanced .room-view-tools { bottom:128px; }
 .conservatory-controls { left:24px; bottom:64px; width:min(310px,44vw); }
 .bath-controls { left:24px; right:auto; top:136px; bottom:auto; width:min(340px,46vw); }
}
