/* Keep destinations quiet and readable around the apartment. */
.room-chrome .scene-focus { grid-template-columns:minmax(44px,.7fr) minmax(44px,.85fr) minmax(0,1.2fr) minmax(0,1.35fr) minmax(0,1.35fr); }
.room-chrome .scene-focus .view-button { white-space:nowrap; }
.navigation-status { position:absolute; left:0; bottom:calc(100% + 12px); margin:0; padding:7px 11px; max-width:100%; color:var(--ink); background:var(--chrome); border:1px solid #8f8169; border-radius:4px; font:13px/1.4 var(--sans); pointer-events:none; animation:navigation-cue-arrive .14s ease-out; }
.navigation-status:empty { display:none; }
html[data-style] .room-chrome .view-button[data-walking] { background:#526b50; color:#fff8e8; text-decoration:underline dotted; text-underline-offset:5px; }
@keyframes navigation-cue-arrive { from { opacity:0; transform:translateY(3px); } to { opacity:1; transform:translateY(0); } }
@media(prefers-reduced-motion:reduce) { .navigation-status { animation:none; } }
/* Give the long destination names room while preserving full touch targets. */
@media(max-width:640px) {
  html[data-style] .room-chrome .scene-focus { gap:2px; padding:3px; }
  .room-chrome .scene-focus .view-button { min-height:48px; min-width:44px; padding:8px 4px; font:12px/1.3 var(--sans); letter-spacing:0; text-transform:none; }
}
.exploration-options { display:grid; grid-template-columns:1fr 1fr; gap:4px 16px; padding:2px 0 12px; border-bottom:1px solid #b9ad91; margin-bottom:12px; }
.exploration-options button { min-height:44px; text-align:left; padding:8px 0; color:#405942; font:14px/1.35 var(--sans); }
.exploration-options button:focus-visible { outline:2px solid #405942; outline-offset:3px; }
html[data-style] .object-tooltip { max-width:min(300px,calc(100vw - 24px)); border-left:3px solid #60775b; font:14px/1.4 var(--sans); letter-spacing:0; text-transform:none; }
#object-click-feedback { position:fixed; z-index:34; pointer-events:none; width:32px; height:32px; border:2px solid #f3e9cd; box-shadow:0 0 0 2px #4b644d; border-radius:50%; opacity:0; }

/* A useful title and short list; model credits remain secondary. */
html[data-style] .object-action-menu { width:260px; min-width:0; max-width:calc(100vw - 24px); max-height:calc(100dvh - 24px); overflow:auto; padding:12px; border-radius:8px; }
.object-action-header { display:flex; align-items:flex-start; gap:8px; border-bottom:1px solid #c1b79b; margin-bottom:8px; }
html[data-style] .object-action-title { flex:1; margin:6px 0 12px; padding:0; border:0; font:21px/1.2 var(--serif); }
html[data-style] .object-action-dismiss { flex:none; min-width:44px; min-height:44px; padding:4px; background:transparent; color:inherit; font:24px/1 var(--sans); border:0; }
html[data-style] .object-action-choices button,html[data-style] .object-action-choices summary { min-height:44px; width:100%; padding:10px 12px; font:15px/1.4 var(--sans); }
html[data-style] .object-action-choices [data-primary] { color:#fff8e8; background:#526b50; }
.object-action-choices details { margin-top:8px; border-top:1px solid #c1b79b; }
.object-action-choices summary { cursor:pointer; color:#706b5c; }
.object-action-dismiss:focus-visible,.object-action-choices summary:focus-visible { outline:2px solid #405942; outline-offset:-2px; }

/* The collection uses image-led rows, with one scroll area and persistent search state. */
html[data-style] .content-browser { width:min(860px,calc(100vw - 32px)); max-height:calc(100dvh - 128px); padding:26px 30px; overflow:auto; overscroll-behavior:contain; color:var(--ink); background:var(--chrome); }
html[data-style] .content-browser .close-dialog.surface-back { position:sticky; top:0; left:0; right:auto; display:inline-flex; min-height:44px; height:auto; margin:0 0 20px; background:var(--chrome); }
.reader-library { min-height:44px; }
.content-heading h2 { margin:2px 0 8px; font:38px/1.1 var(--serif); }
.content-heading p { margin:0 0 15px; font:15px/1.5 var(--sans); }
.content-heading .library-kicker { margin:0 0 8px; font:11px/1.4 var(--sans); letter-spacing:.1em; color:#6c705b; }
.content-filters { display:grid; grid-template-columns:minmax(0,1fr) 190px; gap:16px; margin-top:22px; }
.content-filters label { display:grid; gap:7px; color:#4d5e48; font:13px/1.4 var(--sans); }
.content-filters :is(input,select) { width:100%; min-width:0; min-height:44px; padding:10px 12px; border:1px solid #a49b83; border-radius:4px; background:#faf4e5; color:#303b30; font:16px/1.35 var(--sans); }
.content-filters :is(input,select):focus-visible { outline:2px solid #526b50; outline-offset:2px; }
.content-count { margin:18px 0 6px; color:#706b5c; font:12px/1.4 var(--sans); }
.content-results { list-style:none; margin:0; padding:0; }
.content-row { display:grid; grid-template-columns:minmax(0,1fr) auto; column-gap:18px; padding:14px 0; border-top:1px solid #c4bba2; }
.content-open { min-width:0; display:flex; align-items:center; gap:18px; padding:0; color:inherit; text-align:left; }
.content-cover { flex:none; display:block; width:66px; height:86px; object-fit:contain; background:#e1dbc7; }
.content-copy { display:grid; min-width:0; gap:5px; }
.content-category { color:#5f6c53; font:11px/1.4 var(--sans); }
.content-title { font:21px/1.2 var(--serif); font-weight:normal; overflow-wrap:anywhere; }
.content-description { color:#706b5c; font:13px/1.4 var(--sans); }
.content-arrow { margin-left:auto; color:#526b50; font-size:22px; }
.content-show { align-self:center; min-height:44px; padding:10px 0; color:#526b50; font:13px/1.4 var(--sans); text-decoration:underline; text-underline-offset:4px; }
.content-open:hover .content-title { color:#526b50; text-decoration:underline; text-underline-offset:4px; }
.content-browser button:focus-visible { outline:2px solid #526b50; outline-offset:4px; }
.content-empty { padding:28px 0; font:16px/1.5 var(--sans); }
.content-footer { display:flex; flex-wrap:wrap; align-items:center; gap:4px 18px; border-top:1px solid #b9ad91; margin-top:10px; padding-top:16px; font:13px/1.4 var(--sans); }
.content-footer span { color:#706b5c; }
.content-footer button { min-height:44px; padding:8px 0; color:#405942; text-decoration:underline; text-underline-offset:4px; }

.room-discovery { position:fixed; inset:0; z-index:24; pointer-events:none; }
.room-discovery[hidden] { display:none; }
.room-discovery button { position:absolute; pointer-events:auto; min-height:44px; padding:8px 10px; border:1px solid #8f8169; border-radius:5px; background:#f1e8d2; color:#405942; box-shadow:2px 3px 0 #4a392b66; font:13px/1.3 var(--sans); }
.room-discovery button:after { content:''; position:absolute; left:calc(50% - 4px); bottom:-5px; width:8px; height:8px; background:#f1e8d2; border-right:1px solid #8f8169; border-bottom:1px solid #8f8169; transform:rotate(45deg); }
.room-discovery button:hover { background:#dde4cd; }
.room-discovery button:focus-visible { outline:3px solid #526b50; outline-offset:3px; }
@media(max-width:600px) {
  html[data-style] .object-action-menu { left:12px!important; top:auto!important; bottom:max(12px,env(safe-area-inset-bottom)); width:calc(100vw - 24px); max-width:none; max-height:calc(100dvh - 110px); padding:16px; }
  html[data-style] .content-browser { width:calc(100vw - 24px); max-height:calc(100dvh - 110px); padding:20px 16px; }
  .content-heading h2 { font-size:31px; }
  .content-filters { grid-template-columns:minmax(0,1fr); gap:12px; }
  .content-row { grid-template-columns:minmax(0,1fr); row-gap:4px; }
  .content-cover { width:48px; height:64px; }
  .content-open { gap:12px; }
  .content-title { font-size:20px; }
  .content-description { font-size:12px; }
  .content-show { justify-self:start; margin-left:60px; }
  .content-arrow { display:none; }
  .content-footer { gap:2px 14px; }
  .content-footer span { width:100%; }
  .exploration-options { grid-template-columns:1fr; }
}
@media(max-height:520px) {
  html[data-style] .content-browser { max-height:calc(100dvh - 90px); padding:16px 22px; }
  html[data-style] .content-browser .close-dialog.surface-back { margin-bottom:0; vertical-align:middle; }
  .content-heading { display:inline-block; vertical-align:middle; margin-left:14px; }
  .content-heading p { display:none; }
  .content-heading h2 { margin:0; font-size:27px; }
  .content-filters { margin-top:12px; }
  .content-count { margin-top:8px; }
}
@media(prefers-reduced-motion:reduce) { .object-action-menu { animation:none!important; } }

/* Library lives on the bookcase; this hint leaves the covers unobstructed. */
.bookshelf-hint { position:fixed; left:50%; bottom:96px; transform:translateX(-50%); margin:0; padding:8px 14px; width:max-content; max-width:calc(100vw - 28px); border-radius:4px; background:var(--chrome); color:var(--ink); font:13px/1.4 var(--sans); pointer-events:none; z-index:25; }
.bookshelf-hint[hidden] { display:none; }
.content-filters { grid-template-columns:minmax(0,1fr); }
@media(max-width:600px) { .bookshelf-hint { bottom:140px; font-size:12px; } }
@media(max-height:520px) { .bookshelf-hint { bottom:78px; } }

#bookshelf-controls { padding:16px 0; }
#bookshelf-controls label { display:block; margin-bottom:8px; }
#shelf-book-choice { display:block; width:100%; min-height:44px; padding:10px; font:16px/1.3 var(--sans); }
#shelf-read-book { min-height:44px; padding:10px 0; color:#405942; }

@media(max-height:520px) and (min-width:600px) {
  html[data-library='on'] .room-chrome { display:flex; gap:12px; }
  html[data-library='on'] .room-chrome .scene-focus { display:flex; width:auto; }
  html[data-library='on'] .room-tools { width:auto; gap:8px; }
  html[data-library='on'] .bookshelf-hint { top:16px; bottom:auto; }
}
