/* The Santa Tree – the bookcase (secret door), the study view and the riddle book. Loaded after theme.css. */
/* ---------- the small bookcase in the room, seen from the side ---------- */
.bookcase{left:4%;bottom:15%;width:auto;height:min(70%,450px);aspect-ratio:440/704;z-index:1;pointer-events:none;display:block}
.bookcase .bcbtn{position:absolute;inset:0;padding:0;border:0;background:none;cursor:pointer;pointer-events:auto;-webkit-tap-highlight-color:transparent;transition:transform .35s,filter .35s}
.bookcase .bcbtn:hover{transform:translateY(-2px);filter:brightness(1.08)}
.bookcase .bcside{position:absolute;inset:0;width:100%;height:100%;display:block;pointer-events:none;filter:drop-shadow(0 10px 14px rgba(0,0,0,.55))}
/* the light from behind the door leaks along the far edge of the bookcase and spills on the wall and the floor beside it */
.bookcase .bclight{position:absolute;pointer-events:none;left:94%;top:20%;width:62%;height:64%;background:radial-gradient(ellipse 45% 50% at 6% 50%,rgba(255,170,70,.5),rgba(255,140,40,.16) 55%,transparent 75%);mix-blend-mode:screen;animation:bcbreath 5.5s ease-in-out infinite}
.bookcase .bcfloor{position:absolute;pointer-events:none;left:62%;bottom:-9%;width:96%;height:24%;background:radial-gradient(closest-side,rgba(255,160,60,.34),transparent);   /* 27 Nov: the lantern's light on the floor fades out on all sides (it had a hard edge) */mix-blend-mode:screen;animation:bcbreath 5.5s ease-in-out infinite}
.bookcase.lit .bclight,.bookcase.lit .bcfloor{animation:bclit 2.4s ease-in-out infinite}
@keyframes bcbreath{0%,100%{opacity:.7}50%{opacity:1}}
@keyframes bclit{0%,100%{opacity:.95;transform:scale(1)}50%{opacity:1;transform:scale(1.18)}}
.bookcase .rbookbtn{position:absolute;left:2%;bottom:1%;width:31%;padding:0;border:0;background:none;cursor:pointer;pointer-events:auto;transform:rotate(-26deg);transform-origin:50% 100%;z-index:3;transition:transform .3s;-webkit-tap-highlight-color:transparent}
.bookcase .rbookbtn:hover{transform:rotate(-26deg) translateY(-3px) scale(1.05)}   /* 27 Nov: the book leans against the bottom left corner of the bookcase */
.bookcase .rbookbtn img{display:block;width:100%;filter:drop-shadow(0 4px 5px rgba(0,0,0,.6));pointer-events:none}
@media (max-width:820px){ .bookcase{display:block;left:0;bottom:30%;height:118px;z-index:20} }
@media (min-width:821px) and (max-width:1100px){ .bookcase{left:1%;bottom:14%;height:min(58%,360px)} }
.room.guide .bookcase{border:0}
.room.guide .bookcase::after{display:none}

/* ---------- the study: the bookcase seen from the front ---------- */
.study,.bookview{position:fixed;inset:0;z-index:170;display:grid;place-items:center;opacity:0;pointer-events:none;transition:opacity .45s}
.study.show,.bookview.show{opacity:1;pointer-events:auto}
.study[hidden],.bookview[hidden]{display:none}
.bookview{z-index:180}
.study .stbg,.bookview .stbg{position:absolute;inset:0;background:radial-gradient(ellipse at 50% 40%,#0b1b3d 0%,#050d22 55%,#02060f 100%)}
.bookview .stbg{background:rgba(2,6,15,.82);backdrop-filter:blur(3px)}
.stclose{position:absolute;top:14px;right:14px;z-index:5;width:44px;height:44px;border-radius:50%;border:1px solid var(--hair,rgba(227,183,91,.5));background:rgba(6,12,28,.7);color:#ecd9a6;font:300 24px/1 Manrope,sans-serif;cursor:pointer}
.stclose:hover{background:rgba(227,183,91,.14)}
.stscene{position:relative;display:flex;flex-direction:column;align-items:center;gap:0}
.stwall{position:relative;width:min(84vw,calc(74vh*.952));aspect-ratio:1069/1123;perspective:1500px;margin-bottom:6vh}
.stbehind{position:absolute;inset:0;opacity:0;transition:opacity 1.4s .15s;overflow:hidden;
  background:radial-gradient(ellipse 70% 80% at 70% 52%,#ffe6ae 0%,#f6b457 26%,#b45a1c 55%,#3a1608 80%,transparent 100%);
  -webkit-mask-image:radial-gradient(ellipse 48% 48% at 58% 50%,#000 35%,transparent 100%);mask-image:radial-gradient(ellipse 48% 48% at 58% 50%,#000 35%,transparent 100%)}
.stbehind .dust{position:absolute;width:4px;height:4px;border-radius:50%;background:#ffe9b8;opacity:0;box-shadow:0 0 8px 2px rgba(255,214,140,.7);animation:dust 7s linear infinite}
@keyframes dust{0%{transform:translate(0,30px);opacity:0}15%{opacity:.9}100%{transform:translate(-30px,-260px);opacity:0}}
.stwall.open .stbehind{opacity:1}
.stdoor{position:absolute;inset:0;transform-origin:0 50%;transform:perspective(1500px) rotateY(0deg);transition:transform 2s cubic-bezier(.45,.05,.2,1),filter 2s;cursor:pointer;will-change:transform}
.stwall.open .stdoor{transform:perspective(1500px) rotateY(72deg);filter:brightness(.55)}
.stfront{position:absolute;inset:0;width:100%;height:100%;display:block;pointer-events:none;filter:drop-shadow(0 18px 30px rgba(0,0,0,.6))}
.stobjs{position:absolute;inset:0;pointer-events:none}
.stobjs img{position:absolute;display:block;transform:translate(-50%,-100%);filter:drop-shadow(0 3px 3px rgba(0,0,0,.5))}
/* the slit of light along the door's opening edge, and the glow it throws onto the wall and the floor */
.stedge{position:absolute;right:-.2%;top:6%;bottom:4%;width:3px;background:linear-gradient(180deg,rgba(255,170,80,0),rgba(255,165,70,.95) 18%,rgba(255,150,50,1) 60%,rgba(255,170,80,0));box-shadow:0 0 10px 3px rgba(255,130,40,.7);animation:edgeflick 4.8s ease-in-out infinite;pointer-events:none;transition:opacity .6s}
.stspill{position:absolute;left:99%;top:-8%;bottom:-6%;width:34%;background:radial-gradient(ellipse 100% 56% at 0% 50%,rgba(255,150,50,.4),rgba(255,140,40,.13) 45%,transparent 72%);mix-blend-mode:screen;pointer-events:none;animation:edgeflick 4.8s ease-in-out infinite;transition:opacity .6s}
.stpuddle{position:absolute;left:62%;top:96%;width:62%;height:14%;background:radial-gradient(ellipse 50% 50% at 50% 30%,rgba(255,160,60,.42),transparent 72%);mix-blend-mode:screen;pointer-events:none;animation:edgeflick 4.8s ease-in-out infinite;transition:opacity .6s}
@keyframes edgeflick{0%,100%{opacity:.8}30%{opacity:1}55%{opacity:.7}80%{opacity:.95}}
.stwall.lit .stedge{animation:edgelit 2.2s ease-in-out infinite;width:4px}
.stwall.lit .stspill,.stwall.lit .stpuddle{animation:edgelit 2.2s ease-in-out infinite}
@keyframes edgelit{0%,100%{opacity:.9}50%{opacity:1;filter:brightness(1.35)}}
.stwall.open .stedge,.stwall.open .stspill,.stwall.open .stpuddle{opacity:0!important;animation:none!important}
.stbook{position:absolute;left:-6%;bottom:-9%;width:26%;padding:0;border:0;background:none;cursor:pointer;transform:rotate(-5deg);transition:transform .3s;z-index:3;-webkit-tap-highlight-color:transparent}
.stbook:hover{transform:rotate(-5deg) translateY(-4px) scale(1.04)}
.stbook img{display:block;width:100%;filter:drop-shadow(0 8px 10px rgba(0,0,0,.65));pointer-events:none}
.sthint{margin:2px 0 0;max-width:min(86vw,560px);text-align:center;font:600 12px/1.5 Manrope,sans-serif;letter-spacing:.14em;text-transform:uppercase;color:rgba(236,217,166,.85)}

/* ---------- the riddle book, open ---------- */
.bookview .bvbox{position:relative;width:min(96vw,1060px);display:flex;flex-direction:column;align-items:center;gap:14px;transform:scale(.7) translateY(30px);opacity:0;transition:transform .6s cubic-bezier(.2,1.2,.3,1),opacity .4s}
.bookview.show .bvbox{transform:none;opacity:1}
.bvclip{width:100%;overflow:hidden}
.bvwrap{position:relative;width:100%;container-type:inline-size}
.bvwrap img{display:block;width:100%;filter:drop-shadow(0 20px 30px rgba(0,0,0,.65))}
.bvpage{position:absolute;top:10%;bottom:10%;width:37%;display:flex;flex-direction:column;color:#3b2412;overflow:hidden}
.bvpage.l{left:12%}.bvpage.r{left:55%}
.bvpage h4{margin:0 0 3.2cqw;font:600 1.5cqw 'Manrope',sans-serif;letter-spacing:.3em;text-transform:uppercase;color:#8b5a22;text-align:center}
.bvpage .bvt{font:italic 600 2.5cqw/1.5 'Playfair Display',serif;text-align:center;white-space:pre-line;margin:auto 0;color:#3b2412}
.bvpage .bvt.none{opacity:.5;font-size:2.1cqw}
.bvpage .orn{margin:auto;font-size:4cqw;color:rgba(139,90,34,.4)}
.bvnav{display:flex;align-items:center;gap:18px;color:#ecd9a6;font:600 12px Manrope,sans-serif;letter-spacing:.2em;text-transform:uppercase}
.bvnav button{width:44px;height:44px;border-radius:50%;border:1px solid var(--hair,rgba(227,183,91,.5));background:rgba(6,12,28,.7);color:#ecd9a6;font:300 22px/1 Manrope,sans-serif;cursor:pointer}
.bvnav button:disabled{opacity:.3;cursor:default}
@media (max-width:640px){
  .bvclip{width:100%}
  .bvwrap{width:185%;margin-left:-1%}
  .bvpage.r{display:none}
  .bvpage.l{left:10.5%;width:36%}
  .bvpage h4{font-size:1.35cqw}.bvpage .bvt{font-size:2.35cqw}
}
@media (prefers-reduced-motion: reduce){
  .stdoor,.stbehind,.bookview .bvbox{transition:none!important}
  .stedge,.stspill,.stpuddle,.bclight,.bcfloor,.stbehind .dust{animation:none!important}
}

.bookcase .bcobjs{position:absolute;inset:0;pointer-events:none}
.bookcase .bcobjs img{position:absolute;transform-origin:50% 100%;pointer-events:none;filter:drop-shadow(0 2px 2px rgba(0,0,0,.55))}

/* ---------- the lantern by the light, and the Room menu ---------- */
.lampglow{position:absolute;left:50%;top:58%;width:340%;height:260%;transform:translate(-50%,-50%);background:radial-gradient(ellipse 50% 50% at 50% 50%,rgba(255,170,70,.42),rgba(255,140,40,.14) 48%,transparent 72%);mix-blend-mode:screen;pointer-events:none;animation:lampflick 3.2s ease-in-out infinite}
.bclamp,.stlamp{position:absolute;pointer-events:none;aspect-ratio:170/291}
.bclamp img,.stlamp img{position:relative;display:block;width:100%;height:100%;filter:drop-shadow(0 3px 4px rgba(0,0,0,.6))}
.bookcase .bclamp{left:93%;bottom:12%;width:17%;z-index:2}
.stlamp{left:94%;top:108%;width:10%;transform:translateY(-100%);z-index:2}
.stwall.open .stlamp{opacity:0}
@keyframes lampflick{0%,100%{opacity:.8}30%{opacity:1}55%{opacity:.7}80%{opacity:.95}}
@media (prefers-reduced-motion:reduce){.lampglow{animation:none}}
@media (max-width:640px){ .ctl.roomctl .pop{left:auto;right:-30px;transform:none} }

/* sideboard (right of the spruce, a little behind it) – picture changes with the bookcase look */
.sideboard{position:absolute;right:0;bottom:16%;width:25%;aspect-ratio:520/340;z-index:1;pointer-events:none;display:block}
.sideboard img.sbc,.sideboard img.sbo{position:relative;display:block;width:100%;height:100%;filter:drop-shadow(0 10px 12px rgba(0,0,0,.55))}
.sideboard img.sbo{position:absolute;left:0;top:0;opacity:0;transition:opacity .45s ease}
.sideboard.dopen img.sbo{opacity:1}
/* the drawer hotspot = the box of spares (count badge on its corner) */
.sideboard .boxbtn{position:absolute;left:54%;top:30%;width:29%;height:42%;right:auto;bottom:auto;z-index:6;pointer-events:auto;border-radius:6px}
.sideboard .boxbtn:focus-visible{outline:2px solid var(--gold2,#f6dc9a);outline-offset:2px}
.sideboard .boxbtn .count{top:-10%;right:-7%}
.sideboard .sbshadow{position:absolute;left:8%;right:0;bottom:-3%;height:9%;background:radial-gradient(ellipse at 50% 50%,rgba(0,0,0,.45),transparent 70%);z-index:0}
.sideboard .fslot,.sideboard .fp{pointer-events:auto}
.sideboard .sbslot:not(.filled){width:40%!important;height:26%!important}
@media (max-width:820px){ .sideboard{display:block;width:36%;right:0;bottom:30%} }

/* ---------- the door (right of the bookcase) and the window (right-hand wall): permanent ---------- */
.roomdoor{position:absolute;z-index:1;pointer-events:none;display:block}
.roomdoor img{display:block;height:100%;width:auto;filter:drop-shadow(0 10px 14px rgba(0,0,0,.55))}
.roomwin{position:absolute;transform:translate(-50%,-100%);z-index:2;pointer-events:none}
.roomwin img{display:block;width:100%;height:auto;filter:drop-shadow(0 6px 6px rgba(0,0,0,.55))}
@media (max-width:820px){ .roomdoor{z-index:19} }

/* ---------- the newspaper by the book ---------- */
.bookcase{z-index:2}
@media (max-width:820px){ .bookcase{z-index:20} }
.bookcase .nwbtn{position:absolute;left:80%;bottom:-8%;width:50%;padding:0;border:0;background:none;cursor:pointer;pointer-events:auto;transform:rotate(-2deg);transition:transform .3s,filter .3s;-webkit-tap-highlight-color:transparent}
.bookcase .nwbtn[hidden]{display:none}
.bookcase .nwbtn:hover{transform:rotate(-2deg) translateY(-3px) scale(1.05)}
.bookcase .nwbtn img{display:block;width:100%;filter:drop-shadow(0 4px 5px rgba(0,0,0,.65));pointer-events:none}
.bookcase .nwbtn .nwglint{position:absolute;left:30%;top:20%;width:40%;height:40%;border-radius:50%;background:radial-gradient(circle,rgba(255,236,170,.55),transparent 70%);mix-blend-mode:screen;pointer-events:none;animation:nwpulse 3.2s ease-in-out infinite}
.bookcase .nwbtn.seen .nwglint{display:none}
@keyframes nwpulse{0%,100%{opacity:.25}50%{opacity:.9}}
.newsview{position:fixed;inset:0;z-index:180;display:grid;place-items:center;opacity:0;pointer-events:none;transition:opacity .45s}
.newsview.show{opacity:1;pointer-events:auto}
.newsview[hidden]{display:none}
.newsview .stbg{position:absolute;inset:0;background:rgba(2,6,15,.82);backdrop-filter:blur(3px)}
.newsview .nwbox{position:relative;width:min(94vw,980px);transform:scale(.7) translateY(30px) rotate(-3deg);opacity:0;transition:transform .6s cubic-bezier(.2,1.2,.3,1),opacity .4s}
.newsview.show .nwbox{transform:none;opacity:1}
.nwwrap{position:relative;container-type:inline-size;filter:drop-shadow(0 18px 28px rgba(0,0,0,.6))}
.nwwrap img{display:block;width:100%;height:auto;border-radius:3px}
/* the blank place on the paper: left 5% / top 27% / 71.5% wide / 64% high */
.nwtxt{position:absolute;left:5%;top:27%;width:71.5%;height:64%;overflow:auto;color:#2b2118;mix-blend-mode:multiply;padding:.4em .2em}
.nwtxt h3{margin:0 0 .45em;font:800 clamp(16px,3.5vw,34px) 'Playfair Display',serif;font-size:3.6cqw;line-height:1.08;letter-spacing:-.01em}
.nwtxt h3:empty{display:none}
.nwbody{font:600 clamp(12px,1.9vw,20px) 'Cormorant Garamond',serif;font-size:2.15cqw;line-height:1.32;white-space:pre-line}
@media (prefers-reduced-motion:reduce){ .newsview .nwbox{transition:none!important} .bookcase .nwbtn .nwglint{animation:none} }

/* the share button and the two wish clouds are docked beside the control panel on larger screens (JS in room.js sets their top positions) */
@media (min-width:641px){
  .sharebar.docked{display:block;margin:0;height:0}
  .sharebar.docked>*{position:fixed;right:-2px;z-index:29;margin:0}
  .sharebar.docked .wishbtn.cloud{width:128px;height:64px}
  .sharebar.docked .wishbtn.cloud .w1{font-size:16px}
  .sharebar.docked .wishbtn.cloud .w2{font-size:7.5px;letter-spacing:.1em;margin-top:3px}
  .sharebar.docked .wishbtn.cloud .wl{padding:0 8px}
  .sharebar.docked .sharebtn{font-size:11.5px;padding:8px 14px;right:12px}
}
.picknote{margin-top:12px}
@media (max-width:640px){ .side .lb{white-space:nowrap;font-size:7.5px;letter-spacing:.06em} .side{gap:10px;padding:6px 10px 5px} }
@media (min-width:641px){ .side{top:calc(50% - 85px)} }   /* the panel sits a little higher to make room for the clouds and the share button under it */

.sideboard img.roomext{position:absolute;width:auto;height:80%;right:1%;bottom:0;z-index:3;filter:drop-shadow(0 6px 7px rgba(0,0,0,.6))}

/* hide / show buttons for the control panel and the decoration selection */
.tglbtn{width:28px;height:28px;border-radius:50%;border:1.5px solid rgba(246,220,154,.6);background:rgba(8,16,40,.78);color:var(--gold2,#f6dc9a);font:700 17px/1 Manrope,sans-serif;display:flex;align-items:center;justify-content:center;cursor:pointer;padding:0;backdrop-filter:blur(4px)}
.tglbtn:hover{background:rgba(246,220,154,.16)}
.tglbtn:focus-visible{outline:2px solid var(--gold2,#f6dc9a);outline-offset:2px}
.tglctl{position:fixed;z-index:31}
.trayctl{position:relative;z-index:3;max-width:820px;margin:6px auto 0;padding:0 12px;display:flex;justify-content:flex-end}
body.ctl-off .side,body.ctl-off .sharebar.docked{display:none}
body.tray-off #tray,body.tray-off #pickNote,body.tray-off #premNote{display:none}

/* ===== the story: book pages, shelf squares, scenes ===== */
.bvpage .bvt.story{display:block;text-align:left;margin:0;font:500 1.55cqw/1.5 'Playfair Display',serif;font-style:normal;overflow-y:auto;scrollbar-width:thin;padding-right:.6cqw}
.bvpage .sttxt{white-space:pre-line}
.bvpage .sthook{margin-top:1.4cqw;font-style:italic;font-weight:700;color:#8b5a22}
.bvpage .stbtns{display:flex;gap:1cqw;margin-top:1.6cqw;flex-wrap:wrap}
.bvpage .stbtns button,.stform button{font:600 1.2cqw 'Manrope',sans-serif;letter-spacing:.08em;padding:.7cqw 1.4cqw;border-radius:99px;border:1px solid #8b5a22;background:rgba(139,90,34,.1);color:#5a3513;cursor:pointer}
.bvpage .stbtns .stq{display:none}
.bvpage h5{margin:0 0 1.6cqw;font:600 1.2cqw 'Manrope',sans-serif;letter-spacing:.3em;text-transform:uppercase;color:#8b5a22;text-align:center}
.bvpage .stqt{font:italic 700 1.9cqw/1.4 'Playfair Display',serif;text-align:center;margin-bottom:1cqw}
.bvpage .sthintt{font:500 1.25cqw 'Manrope',sans-serif;text-align:center;opacity:.65;margin-bottom:1.6cqw}
.stform{display:flex;gap:.8cqw;justify-content:center}
.stform input{width:9cqw;font:600 2cqw 'Manrope',sans-serif;text-align:center;border:1px solid #8b5a22;border-radius:8px;background:rgba(255,250,235,.7);color:#3b2412;padding:.5cqw}
.stmsg{min-height:2.4cqw;margin-top:1cqw;text-align:center;font:600 1.2cqw 'Manrope',sans-serif}.stmsg.bad{color:#9a2a1c}
.stok{text-align:center;font:700 1.8cqw 'Manrope',sans-serif;color:#2f7a3a;margin:1cqw 0}
.stnum{margin-top:auto;text-align:center;font:600 1.2cqw 'Manrope',sans-serif;letter-spacing:.05em;color:#6b4a22}.stnum b{font-size:1.9cqw}
.stcell{position:absolute;pointer-events:auto;border:0;background:transparent;border-radius:10px;cursor:pointer;-webkit-tap-highlight-color:transparent;z-index:2}
.stcell.hot{animation:stpulse 2.2s ease-in-out infinite;box-shadow:inset 0 0 0 2px rgba(255,214,120,.0)}
@keyframes stpulse{0%,100%{box-shadow:inset 0 0 14px 2px rgba(255,214,120,.12),0 0 0 rgba(255,214,120,0)}50%{box-shadow:inset 0 0 26px 6px rgba(255,214,120,.5),0 0 18px rgba(255,214,120,.4)}}
.gdot{position:absolute;width:10px;height:10px;border-radius:50%;background:#37d05a;box-shadow:0 0 8px 2px rgba(55,208,90,.75),inset 0 0 2px #fff;transform:translate(-50%,-50%);pointer-events:none;z-index:3}
.scenev{position:fixed;inset:0;z-index:190;display:grid;place-items:center;opacity:0;pointer-events:none;transition:opacity .4s}
.scenev.show{opacity:1;pointer-events:auto}
.scenev .stbg{position:absolute;inset:0;background:rgba(2,6,15,.88);backdrop-filter:blur(3px)}
.scbox{position:relative;width:min(96vw,920px);display:flex;flex-direction:column;align-items:center;gap:12px}
.scstage{position:relative;width:100%;aspect-ratio:16/9;overflow:hidden;border-radius:16px;border:1px solid rgba(227,183,91,.45);background:radial-gradient(ellipse at 50% 30%,#4a2e1c 0%,#2a1a10 60%,#150c07 100%);box-shadow:0 20px 60px rgba(0,0,0,.6)}
.scfloor{position:absolute;left:0;right:0;bottom:0;height:24%;background:linear-gradient(#3a2414,#22140b);border-top:2px solid rgba(227,183,91,.25)}
.sci{position:absolute;transform:translate(-50%,-50%);height:auto;filter:drop-shadow(0 4px 5px rgba(0,0,0,.55));pointer-events:none}
.sa-in{animation:sain .7s both}.sa-slidein{animation:saslide .9s both}.sa-fall{animation:safall 1.6s ease-in both}
.sa-hop{animation:sain .5s both,sahop .8s .5s infinite}.sa-wobble{animation:sain .6s both,sawob 1.6s .6s ease-in-out infinite}.sa-bob{animation:sain .5s both,sabob 1.8s .5s ease-in-out infinite}
.sa-shake{animation:sain .4s both,sashake .25s .4s infinite}.sa-fallmelt{animation:safall 1.6s ease-in both,samelt 1.6s 2.8s forwards;transform-origin:50% 100%}.sa-melt{animation:samelt 1.2s both;transform-origin:50% 100%}.sa-freeze{animation:sain .3s both;filter:grayscale(.6) brightness(1.1) sepia(1) hue-rotate(160deg) saturate(2)}
.sa-exitR{animation:saexit 1s both}.sa-fly{animation:safly 2.4s ease-in both}
.sa-out{transition:opacity .5s;opacity:0!important}
@keyframes sain{from{opacity:0;scale:.6}to{opacity:1;scale:1}}
@keyframes saslide{from{opacity:0;translate:0 -60px}to{opacity:1;translate:0 0}}
@keyframes safall{0%{opacity:0;translate:0 -140px;rotate:-20deg}25%{opacity:1}100%{opacity:1;translate:0 120px;rotate:30deg}}
@keyframes sahop{0%,100%{translate:0 0}50%{translate:0 -18px}}
@keyframes sawob{0%,100%{rotate:-3deg}50%{rotate:3deg}}
@keyframes sabob{0%,100%{translate:0 0}50%{translate:0 -8px}}
@keyframes sashake{0%,100%{translate:-3px 0}50%{translate:3px 0}}
@keyframes samelt{to{scale:1.2 .08;opacity:.7}}
@keyframes saexit{to{translate:60vw 0;opacity:0}}
@keyframes safly{0%{translate:0 0}100%{translate:40vw -50vh;opacity:0;scale:.3}}
.scsay{position:absolute;transform:translate(-50%,-50%);max-width:58%;padding:.55em .9em;border-radius:14px;background:#fff8e6;color:#3b2412;font:600 clamp(11px,1.9vw,17px)/1.35 'Playfair Display',serif;text-align:center;box-shadow:0 6px 18px rgba(0,0,0,.4);animation:sain .35s both;z-index:6}
.scsay.off{transition:opacity .45s;opacity:0}
.scvid{position:absolute;transform:translate(-50%,-50%);border-radius:12px;overflow:hidden;border:2px solid rgba(227,183,91,.6);box-shadow:0 8px 24px rgba(0,0,0,.5);animation:sain .5s both}
.scvid video{display:block;width:100%}
.scfx{position:absolute;pointer-events:none}
.fx-spot{width:20%;height:6%;transform:translate(-50%,-50%);border-radius:50%;background:radial-gradient(#fff,rgba(255,255,255,.2) 70%);box-shadow:0 0 18px rgba(255,255,255,.8)}
.fx-foot{width:12px;height:8px;border-radius:50%;background:rgba(20,10,5,.7);transform:translate(-50%,-50%);animation:sain .3s both}
.fx-dark,.fx-dark2{inset:0!important;left:0!important;top:0!important;background:#000;opacity:.55;z-index:5;animation:sadark .6s both}.fx-dark2{opacity:.93}
@keyframes sadark{from{opacity:0}}
.fx-flash{inset:0!important;left:0!important;top:0!important;background:#fff;z-index:7;animation:saflash .5s both}
@keyframes saflash{0%{opacity:.95}100%{opacity:0}}
.fx-redlight{width:12px;height:12px;border-radius:50%;background:#ff2a2a;box-shadow:0 0 14px 4px #ff2a2a;animation:stpulse2 1s infinite;transform:translate(-50%,-50%)}
@keyframes stpulse2{50%{opacity:.35}}
.fx-beam{width:26%;height:50%;background:linear-gradient(135deg,rgba(255,240,170,.55),transparent 70%);clip-path:polygon(0 0,100% 40%,60% 100%,0 20%);transform:translate(-30%,-10%)}
.fx-poof b{position:absolute;width:18px;height:18px;border-radius:50%;background:rgba(255,255,255,.85);left:0;top:0;animation:sapoof 1s both}
@keyframes sapoof{to{translate:var(--dx) var(--dy);opacity:0;scale:2.2}}
.fx-candles{width:46%;height:10px;transform:translate(-50%,-50%)}
.fx-candles b{position:absolute;top:0;width:10px;height:18px;border-radius:50% 50% 50% 50%/60% 60% 40% 40%;background:radial-gradient(#fff6c0,#ffb02e);box-shadow:0 0 14px 5px rgba(255,176,46,.65);animation:sacand 3.6s both}
@keyframes sacand{0%{translate:-50vw 0;opacity:0}20%{opacity:1}80%{opacity:1}100%{translate:40vw 0;opacity:0}}
.scbar{display:flex;gap:10px}
.scbar button{padding:10px 18px;border-radius:99px;border:1px solid var(--hair,rgba(227,183,91,.5));background:rgba(6,12,28,.75);color:#ecd9a6;font:600 12px Manrope,sans-serif;letter-spacing:.14em;text-transform:uppercase;cursor:pointer}
@media (max-width:640px){
  .bvpage .bvt.story{font-size:2.15cqw}.bvpage .stbtns button,.stform button{font-size:1.9cqw;padding:1cqw 2cqw}
  .bvpage .stbtns .stq{display:inline-block}
  .bvwrap.showq .bvpage.l{display:none}.bvwrap.showq .bvpage.r{display:flex;left:10.5%;width:36%}
  .bvpage h5{font-size:1.7cqw}.bvpage .stqt{font-size:2.6cqw}.bvpage .sthintt,.stmsg,.stnum{font-size:1.8cqw}.stform input{font-size:3cqw;width:13cqw}.stnum b{font-size:2.6cqw}
  .scsay{max-width:80%}
}
@media (prefers-reduced-motion: reduce){ .stcell.hot{animation:none;box-shadow:inset 0 0 18px 4px rgba(255,214,120,.4)} .sci,.scsay{animation-duration:.01s!important} }

.bvpage .stback{display:none;align-self:flex-start;margin-bottom:1cqw;border:0;background:none;color:#8b5a22;font:600 1.8cqw 'Manrope',sans-serif;cursor:pointer;padding:0}
@media (max-width:640px){ .bvpage .stback{display:block} }
@media (max-width:640px){ .bvpage .bvt.story{font-size:1.9cqw;line-height:1.42} .bvpage .stbtns{position:sticky;bottom:0;padding:1cqw 0 .4cqw;background:linear-gradient(rgba(244,228,186,0),#f4e4ba 35%)} }

/* the two empty drawers of the sideboard */
.sideboard img.sbx{position:absolute;top:0;left:-25%;width:125%;height:100%;opacity:0;pointer-events:none;transition:opacity .4s ease;filter:drop-shadow(0 8px 10px rgba(0,0,0,.5))}
.sideboard.dL img.sbL,.sideboard.dM img.sbM{opacity:1}
.sideboard .dwbtn{position:absolute;top:26%;height:46%;border:0;padding:0;background:none;cursor:pointer;z-index:6;pointer-events:auto;border-radius:6px;-webkit-tap-highlight-color:transparent}
.sideboard .dwL{left:1%;width:25%}.sideboard .dwM{left:27%;width:26%}
.sideboard.dL .dwL,.sideboard.dM .dwM{z-index:8;left:2%;width:52%;top:15%;height:78%}

/* the snowman game (day 3) */
.scstage.sgame{background:radial-gradient(ellipse at 50% 0%,#2b4a78 0%,#16294a 55%,#0b1630 100%);border-color:rgba(190,220,255,.5)}
.scstage.sgame .scfloor{height:22%;background:linear-gradient(#e8f1fa,#aebfd6);border-top:0;box-shadow:0 -18px 40px rgba(220,236,255,.25)}
.snw{position:absolute;inset:0;transform-origin:27% 90%}
.snw.wig{animation:snwig .55s ease-in-out 3}
@keyframes snwig{0%,100%{rotate:0deg}25%{rotate:-3deg}75%{rotate:3deg}}
.snp{position:absolute;padding:0;border:0;background:none;cursor:pointer;display:block;-webkit-tap-highlight-color:transparent}
.snp::after{content:'';position:absolute;inset:-12px}
.snp img{display:block;width:100%;height:auto;pointer-events:none;filter:drop-shadow(0 6px 6px rgba(0,0,0,.4))}
.snp.next img{animation:snglow 1.1s ease-in-out infinite}
@keyframes snglow{0%,100%{filter:drop-shadow(0 0 3px rgba(255,236,170,.6)) drop-shadow(0 6px 6px rgba(0,0,0,.4))}50%{filter:drop-shadow(0 0 16px rgba(255,236,170,1)) drop-shadow(0 6px 6px rgba(0,0,0,.4))}}
.snp.nope{animation:snnope .45s}
@keyframes snnope{0%,100%{translate:0 0}25%{translate:-6px 0}75%{translate:6px 0}}
.snp.land img{animation:snland .5s ease-out}
@keyframes snland{0%{scale:1.14 .86}50%{scale:.94 1.07}100%{scale:1 1}}
.snp.placed img{filter:drop-shadow(0 3px 4px rgba(0,0,0,.3))}
.snw.wig .snp[data-id=carrot] img,.snw.wig .snp[data-id^=cone] img{filter:drop-shadow(0 0 9px #ff9a3c)}
.snwatch{position:absolute;left:10px;top:10px;z-index:70;padding:.45em .9em;border-radius:999px;border:1px solid rgba(227,183,91,.6);background:rgba(10,20,40,.7);color:#f6dc9a;font:600 clamp(10px,1.5vw,13px) 'Montserrat',system-ui,sans-serif;letter-spacing:.06em;cursor:pointer}
.snpud{position:absolute;z-index:3;top:88%;width:32%;height:7%;transform:translate(-50%,-30%);border-radius:50%;background:radial-gradient(ellipse,#dff0ff 0%,#9cc4e6 70%,rgba(156,196,230,0) 100%);animation:sain 2s 1.4s both}

/* the Room control turns pink when the pink leather room is chosen */
.ctlbtn.pink{border-color:#f7b2cb;background:linear-gradient(160deg,#ee98b8,#b9547a 58%,#74243f);color:#fff2f7;box-shadow:0 0 14px rgba(240,130,175,.45),inset 0 1px 0 rgba(255,255,255,.35)}
.ctlbtn.pink[aria-expanded="true"]{border-color:#ffd0e1;box-shadow:0 0 0 3px rgba(247,169,198,.38),0 0 14px rgba(240,130,175,.45)}
.ctlbtn.pink svg{filter:drop-shadow(0 1px 1px rgba(80,10,40,.5))}
.pinkroom>.lb{color:#f8b9d1}
html.pearl .pinkroom>.lb{color:#b0446e}

/* 27 Nov: the locked door can be tapped (it rattles) – but never while a decoration is being placed */
.roomdoor.locked{pointer-events:auto;cursor:pointer}
body.place-hang .roomdoor,body.place-floor .roomdoor,body.place-stove .roomdoor,body.dragging .roomdoor{pointer-events:none}
.roomdoor{transform-origin:0 50%}
/* candle colour row in the Tree menu */
.candlerow{display:flex;flex-wrap:wrap;gap:4px;padding:8px 2px 2px;margin-top:2px;border-top:1px solid rgba(246,220,154,.22)}
.candlerow .cr-cap{flex:0 0 100%;font-size:11px;letter-spacing:.08em;text-transform:uppercase;opacity:.7;color:var(--gold,#f6dc9a);padding:0 2px}
.candlerow .cbtn{flex:1 1 0;min-width:0!important;display:flex;flex-direction:column;align-items:center;gap:4px;padding:6px 2px;border-radius:10px;border:1px solid rgba(246,220,154,.25);background:transparent;color:var(--cream,#f8efd9);font:600 10.5px Manrope,sans-serif;cursor:pointer}
.candlerow .cbtn i{display:block;width:9px;height:24px;border-radius:2px 2px 1px 1px;box-shadow:0 -5px 6px -2px rgba(255,190,80,.7)}
.candlerow .cbtn[aria-pressed="true"]{border-color:var(--gold2,#f6dc9a);background:rgba(246,220,154,.14)}
.candlerow .cbtn:focus-visible{outline:2px solid #f6dc9a;outline-offset:2px}
html.pearl .candlerow .cr-cap{color:#6a4a16} html.pearl .candlerow .cbtn{color:#3a2a14}

/* ===== 27 Nov (2): story book page turning, golden "next step" shimmer, Story button, phone sizes ===== */
/* the buttons now sit under the text (not on top of it), so the last lines are never covered */
.bvpage .bvt.story{flex:1 1 auto;min-height:0;scrollbar-width:none;scroll-behavior:auto;padding-bottom:.6cqw}
.bvpage .bvt.story::-webkit-scrollbar{display:none}
.bvpage .bvt.story.more{-webkit-mask-image:linear-gradient(#000 calc(100% - 2.2cqw),transparent);mask-image:linear-gradient(#000 calc(100% - 2.2cqw),transparent)}
.bvpage .bvt.story.flip{animation:bvflip .38s ease-out}
@keyframes bvflip{from{opacity:0;transform:translateX(1.2cqw)}to{opacity:1;transform:none}}
.bvfoot{flex:none;display:flex;flex-direction:column;gap:.9cqw;padding-top:.9cqw}
.bvfoot:empty{display:none}
.bvfoot .stbtns{margin-top:0}
.stpager{display:flex;align-items:center;gap:1cqw;font:600 1.15cqw Manrope,sans-serif;color:#6b4a22;letter-spacing:.08em}
.stpager[hidden]{display:none}
.stpager #stPgLab{flex:1;text-align:center}
.stpager button{font:600 1.2cqw Manrope,sans-serif;letter-spacing:.06em;padding:.7cqw 1.3cqw;border-radius:99px;border:1px solid #8b5a22;background:rgba(139,90,34,.1);color:#5a3513;cursor:pointer}
.stpager .stpg{padding:.7cqw 1.1cqw} .stpager .stpg:disabled{opacity:.3;cursor:default}
@media (max-width:640px){
  .bvpage .stbtns{position:static;background:none;padding:0}
  .stpager{font-size:1.8cqw} .stpager button{font-size:1.9cqw;padding:1cqw 1.9cqw}
  .bvfoot{gap:1.2cqw;padding-top:1.2cqw}
}
/* the golden shimmer: always marks the next thing to do in the story */
.goldnext{animation:goldnext 1.7s ease-in-out infinite!important;border-color:#e3b75b!important}
.bvpage .goldnext,.stform .goldnext{background:linear-gradient(110deg,#f3d58c 20%,#fff3c9 42%,#f6dc9a 55%,#e9c877 80%)!important;background-size:240% 100%!important;color:#3b2412!important}
@keyframes goldnext{0%,100%{box-shadow:0 0 0 2px rgba(246,220,154,.6),0 0 9px rgba(255,205,110,.6);background-position:100% 0}50%{box-shadow:0 0 0 4px rgba(246,220,154,.35),0 0 20px rgba(255,205,110,.9);background-position:0 0}}
.rbookbtn.goldnext{animation:none!important;border:0!important}
.rbookbtn.goldnext img{animation:goldbook 1.7s ease-in-out infinite}
@keyframes goldbook{0%,100%{filter:drop-shadow(0 0 3px rgba(255,214,120,.55))}50%{filter:drop-shadow(0 0 10px rgba(255,214,120,1)) drop-shadow(0 0 18px rgba(255,190,90,.7)) brightness(1.15)}}
.bvnav button.goldnext,.scbar button.goldnext{color:#fff3c9}
@media (prefers-reduced-motion:reduce){ .goldnext{animation:none!important;box-shadow:0 0 0 3px rgba(246,220,154,.4),0 0 14px rgba(255,205,110,.8)} .rbookbtn.goldnext img{animation:none;filter:drop-shadow(0 0 8px rgba(255,214,120,.95))} }
/* the book's own "1 / 4" pager is hidden while a scene plays over it */
body.scene-on .bvnav{visibility:hidden}
/* Story button beside the day title */
.daynav .storybtn{position:absolute;right:calc(50% + 126px);top:50%;transform:translateY(-50%);width:auto;height:30px;display:inline-flex;align-items:center;gap:6px;padding:0 12px;border-radius:99px;border:1px solid rgba(227,183,91,.55);background:rgba(255,255,255,.05);color:var(--gold2,#f6dc9a);font:700 11px Manrope,sans-serif;letter-spacing:.12em;text-transform:uppercase;cursor:pointer}
.daynav .storybtn svg{width:16px;height:16px;flex:none}
.daynav .storybtn[hidden]{display:none}
.daynav .storybtn:focus-visible{outline:2px solid var(--gold2,#f6dc9a);outline-offset:2px}
html.pearl .daynav .storybtn{color:#5a3d10;border-color:#8b6a2a}
@media (max-width:480px){ .daynav .storybtn{right:calc(50% + 108px);height:30px;padding:0 9px} .daynav .storybtn span{display:none} .daynav .storybtn svg{width:18px;height:18px} }
/* phones: a bigger bookcase and a bigger tap area for the book */
@media (max-width:640px){ .bookcase{height:158px} }
.rbookbtn::after{content:'';position:absolute;inset:-14px -16px}
/* a page that has been turned fades in at the top edge, so a half line never looks cut */
.bvpage .bvt.story.up{-webkit-mask-image:linear-gradient(transparent,#000 2cqw);mask-image:linear-gradient(transparent,#000 2cqw)}
.bvpage .bvt.story.up.more{-webkit-mask-image:linear-gradient(transparent,#000 2cqw,#000 calc(100% - 2.2cqw),transparent);mask-image:linear-gradient(transparent,#000 2cqw,#000 calc(100% - 2.2cqw),transparent)}

/* choose your Christmas card: six small cards under the big one */
.xcard .cardpick{display:flex;justify-content:center;gap:8px;margin:10px 0 12px;flex-wrap:wrap}
.xcard .cardpick button{padding:0;border:2px solid transparent;border-radius:8px;background:none;cursor:pointer;line-height:0;opacity:.7;transition:opacity .2s,border-color .2s,transform .2s}
.xcard .cardpick button img{width:46px;height:auto;border-radius:6px;display:block}
.xcard .cardpick button:hover{opacity:1}
.xcard .cardpick button[aria-checked="true"]{opacity:1;border-color:#f6dc9a;box-shadow:0 0 10px rgba(246,220,154,.55);transform:translateY(-2px)}
.xcard .cardpick button:focus-visible{outline:2px solid #f6dc9a;outline-offset:2px}
@media (max-width:480px){ .xcard .cardpick{gap:6px} .xcard .cardpick button img{width:40px} }
.xcard .cardpick button img{margin:0;box-shadow:none}

/* the door lever (roomfx.js): sits exactly where it is painted on the door, turns round its rose */
.roomdoor .doorlever{position:absolute;left:67.391%;top:45.930%;width:16.957%!important;height:4.651%!important;transform-origin:78.2% 46.9%;pointer-events:none;filter:none!important}

/* turning the tree by dragging (turn.js): sideways touch drags go to the tree, up/down still scrolls the page on phones */
#pad{touch-action:pan-y}
@media (hover:hover) and (pointer:fine){ #pad{cursor:grab} body.turning #pad{cursor:grabbing} body.placing #pad{cursor:copy} }
body.turning{user-select:none;-webkit-user-select:none}

/* scenes: a key being shaken – it hangs from its ring and swings quickly (story.js anim 'wiggle', day 1) */
.sa-wiggle{transform-origin:50% 12%;animation:sain .35s both,sawig .42s .35s ease-in-out infinite}
@keyframes sawig{0%,100%{rotate:-13deg}50%{rotate:13deg}}
@media (prefers-reduced-motion:reduce){ .sa-wiggle{animation:sain .01s both} }

/* the sound button on a scene: a small music symbol in the corner of the film; crossed out (and gently pulsing) when the sound is off */
.scbox{position:relative}
.scsound{position:absolute;top:12px;left:12px;z-index:6;width:42px;height:42px;border-radius:50%;border:1px solid rgba(246,220,154,.6);background:rgba(6,12,28,.72);color:#f6dc9a;display:flex;align-items:center;justify-content:center;cursor:pointer;padding:0;backdrop-filter:blur(3px)}
.scsound svg{width:20px;height:20px}
.scsound.off{animation:sndpulse 1.8s ease-in-out infinite}
@keyframes sndpulse{0%,100%{box-shadow:0 0 0 0 rgba(246,220,154,0)}50%{box-shadow:0 0 0 5px rgba(246,220,154,.28),0 0 14px rgba(246,220,154,.5)}}
.scsound[hidden]{display:none}
.scsound:focus-visible{outline:2px solid #f6dc9a;outline-offset:2px}
@media (prefers-reduced-motion:reduce){ .scsound.off{animation:none} }

/* the Story button: on larger screens it stands on the floor under the bookcase (room.js moves it there); on phones it sits by the day title */
.bookcase .storybtn.under{position:absolute;left:50%;top:calc(100% + 14px);transform:translateX(-50%);pointer-events:auto;z-index:4;display:inline-flex;align-items:center;gap:7px;height:32px;padding:0 14px;border-radius:99px;border:1px solid rgba(227,183,91,.6);background:rgba(8,14,34,.72);color:var(--gold2,#f6dc9a);font:700 11.5px Manrope,sans-serif;letter-spacing:.14em;text-transform:uppercase;cursor:pointer;white-space:nowrap;backdrop-filter:blur(3px)}
.bookcase .storybtn.under svg{width:16px;height:16px}
.bookcase .storybtn.under[hidden]{display:none}
@media (max-width:820px){ .bookcase .rbookbtn{left:14%;bottom:0;width:34%;transform:rotate(-18deg)} .bookcase .rbookbtn:hover{transform:rotate(-18deg)} }

/* the Advent candlestick on the floor, front left (advent.js) */
.advent{position:absolute;left:-9%;top:98.5%;width:21%;transform:translate(-50%,-100%);touch-action:none;padding:0;border:0;background:none;cursor:pointer;pointer-events:auto;z-index:3;-webkit-tap-highlight-color:transparent}
.advent .adbase{display:block;width:100%;height:auto;filter:drop-shadow(0 8px 8px rgba(0,0,0,.55))}
.advent .adflame{position:absolute;height:auto;opacity:0;transform-origin:50% 100%;pointer-events:none;transition:opacity .8s;mix-blend-mode:normal}
.advent .adflame.on{opacity:1;filter:brightness(1.25) saturate(1.2) drop-shadow(0 0 4px rgba(255,190,90,.95));animation:adflick 1.5s ease-in-out infinite}
.advent .adglow{position:absolute;aspect-ratio:1;border-radius:50%;pointer-events:none;opacity:0;transition:opacity .8s;mix-blend-mode:screen;
  background:radial-gradient(circle,rgba(255,232,160,1) 0%,rgba(255,180,80,.62) 20%,rgba(255,140,40,.26) 44%,transparent 68%)}
.advent .adglow.on{opacity:1;animation:adglow 1.5s ease-in-out infinite}
@keyframes adglow{0%,100%{transform:scale(1);opacity:.9}24%{transform:scale(.88);opacity:.7}50%{transform:scale(1.08);opacity:1}73%{transform:scale(.93);opacity:.78}}
.advent:focus-visible{outline:2px solid #f6dc9a;outline-offset:3px;border-radius:6px}
@keyframes adflick{0%,100%{transform:scale(1,1) skewX(0)}18%{transform:scale(.9,1.12) skewX(4deg)}36%{transform:scale(1.06,.9) skewX(-3deg)}55%{transform:scale(.94,1.14) skewX(-5deg)}74%{transform:scale(1.04,.93) skewX(2deg)}88%{transform:scale(.97,1.07) skewX(-1deg)}}
@media (prefers-reduced-motion:reduce){ .advent .adflame.on,.advent .adglow.on{animation:none} }
@media (max-width:820px){ .advent{width:22%} }
/* rug colours (rugcol.js) */
.rugctl .rugsw{display:flex;flex-wrap:wrap;align-items:center;gap:6px}
.rugctl .rugbtn{width:30px;height:30px;padding:3px;border-radius:50%;border:1.5px solid rgba(227,183,91,.35);background:none;cursor:pointer}
.rugctl .rugbtn i{display:block;width:100%;height:100%;border-radius:50%;box-shadow:inset 0 0 0 1px rgba(255,255,255,.18)}
.rugctl .rugbtn[aria-pressed="true"]{border-color:#f6dc9a;box-shadow:0 0 8px rgba(246,220,154,.6)}
.rugctl .rugbtn:focus-visible{outline:2px solid #f6dc9a;outline-offset:2px}
.rugctl .rugname{flex:1 0 100%;font:600 11.5px Manrope,sans-serif;color:var(--gold2,#ecd9a6);opacity:.85;padding:2px 2px 0}
/* gold and silver rugs sparkle: a slow light sweep and twinkles over the rug only */
.rug.glitter::after{content:'';position:absolute;inset:0;pointer-events:none;-webkit-mask:var(--rugimg) center/100% 100% no-repeat;mask:var(--rugimg) center/100% 100% no-repeat;
  background:linear-gradient(105deg,transparent 35%,rgba(255,255,255,.55) 48%,transparent 60%) 0 0/220% 100% no-repeat,
    radial-gradient(1.6px 1.6px at 18% 40%,#fff 60%,transparent 61%),radial-gradient(1.4px 1.4px at 37% 70%,#fff 60%,transparent 61%),radial-gradient(1.8px 1.8px at 61% 35%,#fff 60%,transparent 61%),
    radial-gradient(1.4px 1.4px at 78% 62%,#fff 60%,transparent 61%),radial-gradient(1.6px 1.6px at 50% 52%,#fff 60%,transparent 61%),radial-gradient(1.2px 1.2px at 27% 56%,#fff 60%,transparent 61%),radial-gradient(1.4px 1.4px at 88% 45%,#fff 60%,transparent 61%);
  mix-blend-mode:screen;animation:rugsweep 4.5s ease-in-out infinite,rugtw 1.3s steps(2) infinite}
@keyframes rugsweep{0%{background-position:120% 0,0 0,0 0,0 0,0 0,0 0,0 0,0 0}60%,100%{background-position:-120% 0,0 0,0 0,0 0,0 0,0 0,0 0,0 0}}
@keyframes rugtw{0%{opacity:.75}50%{opacity:1}}
@media (prefers-reduced-motion:reduce){ .rug.glitter::after{animation:none} }
.garctl.float.rugctl{bottom:auto;top:2%}   /* the rug panel sits high, so the rug stays visible while you choose */
@media (max-width:820px){ .garctl.float.rugctl{top:auto;bottom:calc(96px + env(safe-area-inset-bottom,0px))} }
/* before the first Advent Sunday: four new, unlit candles; from then on the burnt-down picture with flames */
.advent .adunlit{position:absolute;left:0;top:0;display:none}
.advent.none .adunlit{display:block}
.advent.none .adbase:not(.adunlit){visibility:hidden}

/* ===== 27 Nov: a calmer area under the decorations ===== */
/* Share my tree: the last tile in the row (the floating button is not needed any more) */
#shareOpen{display:none!important}
.item.sharetile{border-color:rgba(246,220,154,.55);background:linear-gradient(180deg,rgba(246,220,154,.14),rgba(246,220,154,.04));color:var(--gold2,#f6dc9a);display:flex;flex-direction:column;align-items:center;justify-content:center;gap:4px}
.item.sharetile .ic{height:48px!important}
.item.sharetile .ic svg{width:34px;height:34px;filter:none}
.item.sharetile .stl{font:700 10.5px Manrope,sans-serif;letter-spacing:.12em;text-transform:uppercase;line-height:1.2}
.item.sharetile:hover{border-color:#f6dc9a;box-shadow:0 0 14px rgba(246,220,154,.3)}
html.pearl .item.sharetile{color:#6a4a16;border-color:#b08a3e}
/* the info block: pick line, countdown and the two small "adjust" buttons */
.trayinfo{position:relative;z-index:2;display:flex;flex-direction:column;align-items:center;gap:4px;margin:12px auto 0;padding:0 16px;max-width:760px}
.trayinfo .picknote{margin:0;font:600 12.5px Manrope,sans-serif;opacity:.78;min-height:0}
.trayinfo .cdnote{margin:0;font:600 12px Manrope,sans-serif;opacity:.9}
.trayinfo .premnote{margin:2px 0 0}
.traychips{display:flex;flex-wrap:wrap;justify-content:center;gap:6px;margin-top:2px}
.traychips:empty{display:none}
.traychips .garchip{margin:0;height:26px;padding:0 11px;font:600 11px Manrope,sans-serif;border-color:rgba(227,183,91,.35);background:transparent;opacity:.85}
.traychips .garchip:hover{opacity:1;border-color:rgba(246,220,154,.7)}
/* footer: preview tick and the company line small and quiet; one long line on wide screens */
.foot{padding-top:22px}
.foot .prevl,.foot #reset{font-size:11px;opacity:.7}
.foot .legal{font-size:10.5px!important;line-height:1.5;opacity:.8;max-width:none!important;margin-top:8px!important}
@media (min-width:1000px){ .foot .legal{white-space:nowrap} }
/* the candlestick stands in front of everything on the floor and can be moved */
.advent{z-index:130;cursor:grab}
.advent.moving{cursor:grabbing;filter:drop-shadow(0 0 10px rgba(246,220,154,.55))}
/* larger screens: the row of tiles fits one more (Share my tree comes right after the envelope) */
@media (min-width:641px){ .tray{display:flex;flex-wrap:wrap;justify-content:center;max-width:1060px} .tray>.item{flex:0 0 90px} }

/* the bookcase's small 3D movement (shelf3d.js): two views blended; they reach a little beyond the bookcase box */
.bookcase .bcview{position:absolute;left:-6.818%;top:-5.682%;width:111.364%;height:112.216%;pointer-events:none;display:none;filter:drop-shadow(0 10px 14px rgba(0,0,0,.55))}
.bookcase .s3d .bcview{display:block}
.bookcase .s3d .bcside{visibility:hidden}

/* the candle bridge (bridge.js) */
.bridge{position:absolute;padding:0;border:0;background:none;cursor:pointer;pointer-events:auto;-webkit-tap-highlight-color:transparent}
.bridge img{display:block;width:100%;height:auto;filter:drop-shadow(0 4px 4px rgba(0,0,0,.5))}
.bridge .bglow{position:absolute;width:30%;aspect-ratio:1;transform:translate(-50%,-50%);border-radius:50%;pointer-events:none;opacity:0;transition:opacity .6s;mix-blend-mode:screen;
  background:radial-gradient(circle,rgba(255,236,170,.95) 0%,rgba(255,190,90,.45) 22%,rgba(255,150,50,.14) 45%,transparent 68%)}
.bridge.lit .bglow{opacity:1;animation:bglow 3.2s ease-in-out infinite}
@keyframes bglow{0%,100%{opacity:.95}50%{opacity:.8}}
.bridge.broom{width:44%;transform-origin:50% 100%;z-index:3}
.bridge.bstudy{position:absolute;left:50%;top:2px;width:min(19%,12vh);transform:translate(-50%,-100%);z-index:4}
.bridge:focus-visible{outline:2px solid #f6dc9a;outline-offset:3px;border-radius:6px}
@media (prefers-reduced-motion:reduce){ .bridge.lit .bglow{animation:none} }
/* colour row in the Room menu */
.bridgerow .bsw{flex:0 0 100%;display:flex;flex-wrap:wrap;gap:5px;padding:2px 0}
.bridgerow .bswb{width:24px;height:24px;padding:2px;border-radius:50%;border:1.5px solid rgba(227,183,91,.3);background:none;cursor:pointer}
.bridgerow .bswb i{display:block;width:100%;height:100%;border-radius:50%;box-shadow:inset 0 0 0 1px rgba(255,255,255,.2)}
.bridgerow .bswb[aria-pressed="true"]{border-color:#f6dc9a;box-shadow:0 0 6px rgba(246,220,154,.6)}
.bridgerow .bon{flex:1 0 100%;margin-top:4px;height:28px;border-radius:99px;border:1px solid rgba(246,220,154,.45);background:transparent;color:var(--gold2,#f6dc9a);font:600 11.5px Manrope,sans-serif;cursor:pointer}
.bridgerow .bon[aria-pressed="true"]{background:rgba(246,220,154,.14)}

/* the ice tree: a cold, glassy glow round the tree (the colours and the extra frost glints are in the tree's shader) */
html.icetree #spin{filter:drop-shadow(0 0 1.5px rgba(240,250,255,.8)) drop-shadow(0 0 16px rgba(170,215,245,.32)) contrast(1.08)}   /* 27 Nov evening: clear ice – a crisp white rim and a soft ice-blue glow */

/* ===== 27 Nov: the quote card on old handmade paper – same colours and fonts, a cotton-paper texture and torn (deckled) edges ===== */
.card{background:none!important;box-shadow:none!important;isolation:isolate;filter:drop-shadow(0 24px 30px rgba(0,0,0,.45)) drop-shadow(0 3px 4px rgba(0,0,0,.35))}
.card::before{content:'';position:absolute;inset:0;z-index:-1;pointer-events:none;
  background:url(room/paper-rim.png) 0 0/100% 100% no-repeat, url(room/paper.webp) 0 0/300px 300px repeat, radial-gradient(ellipse at 50% 40%,transparent 55%,rgba(60,40,20,.22) 100%),
    linear-gradient(150deg,color-mix(in srgb,var(--bg) 86%,#fff) 0%,var(--bg) 46%,color-mix(in srgb,var(--bg) 84%,#000) 100%);
  background-blend-mode:normal,soft-light,multiply,normal;
  -webkit-mask:url(room/paper-edge.png) 0 0/100% 100% no-repeat;mask:url(room/paper-edge.png) 0 0/100% 100% no-repeat}
/* the double frame line of the "frame" layout, drawn above the paper */
.l-frame::after{content:'';position:absolute;inset:14px;border:1.5px solid var(--acc);box-shadow:inset 0 0 0 3.5px transparent,inset 0 0 0 5px var(--acc);pointer-events:none;opacity:.85}

/* ===== 27 Nov: "Send a Christmas card" as a navy velvet button with a gold edge, top left (picture: room/cardbtn.webp) ===== */
.topicons{left:14px;justify-content:space-between;pointer-events:none}
.topicons>*{pointer-events:auto}
.cardopen{display:flex;align-items:center;gap:10px;height:54px;padding:0 16px 0 8px;border-radius:14px;cursor:pointer;
  border:1.5px solid #d9a94e;box-shadow:0 0 0 1px rgba(0,0,0,.35),inset 0 0 0 1px rgba(255,230,170,.18),0 6px 16px rgba(0,0,0,.35);
  background:color-mix(in srgb,color-mix(in srgb,var(--bg3,#03162c) 70%,#000) 96%,#fff);   /* same colour as the decoration tiles (follows the sky) */
  color:#f6ead0;font:600 15px/1.08 'Playfair Display',Georgia,serif;text-align:left;transition:transform .15s,filter .15s}
.cardopen:hover{filter:brightness(1.12);transform:translateY(-1px)}
.cardopen:focus-visible{outline:2px solid #f6dc9a;outline-offset:2px}
.cardopen img{width:62px;height:auto;margin:-10px 0 -4px;filter:drop-shadow(0 2px 3px rgba(0,0,0,.4));pointer-events:none}
.cardopen .cotxt{max-width:118px;text-shadow:0 1px 2px rgba(0,0,0,.5)}
@media (max-width:640px){
  .cardopen{height:40px;gap:6px;padding:0 10px 0 4px;border-radius:11px;font-size:12px}
  .cardopen img{width:44px;margin:-8px 0 -3px}
  .cardopen .cotxt{max-width:122px}
}
html.pearl .cardopen{background:color-mix(in srgb,var(--bg3,#f4f0e9) 80%,#fff);color:#3a3226;border-color:#b08a3e}
html.pearl .cardopen .cotxt{text-shadow:0 1px 0 rgba(255,255,255,.6)}

/* ===== 27 Nov: "Botanical wallpaper" sky – flowered wallpaper above the panelling (picture room/wallpaper-botanical.webp). The page text turns dark, as for White pearl ===== */
html.wallpaper #roomBack{--wall-a:#e8d9c4;--wall-b:#e2d1ba;--wall-c:#d6c3a8;--panel-line:rgba(90,60,30,.18);--panel-hi:rgba(255,255,255,.45)}
html.wallpaper #roomBack .rb-wall{background:linear-gradient(180deg,rgba(60,40,20,.10),rgba(60,40,20,0) 30%),var(--paper,url(room/wallpaper-botanical.webp)) 0 0/var(--paper-size,300px) repeat,#f3e7d8}
html.wallpaper #roomBack .rb-panel{background-color:#eadcc6}
html.wallpaper #roomBack .rb-lwall{background:var(--paper,url(room/wallpaper-botanical.webp)) 0 0/var(--paper-lsize,230px 300px) repeat,#e6d8c4}
html.wallpaper #roomBack{--dado-bg:linear-gradient(#eadcc6,#eadcc6)}
/* the wallpaper belongs to the walls: under the room the page is calm cream, and the floor ends in it (no flowers showing through the floor) */
html.wallpaper body{background:linear-gradient(180deg,rgba(246,235,220,0) calc(var(--roomEnd,900px) - 150px),#f6ebdc var(--roomEnd,900px)),var(--paper,url(room/wallpaper-botanical.webp)) 0 0/420px repeat,#f6ebdc}
html.wallpaper #roomBack .rb-floor{-webkit-mask-image:none;mask-image:none}
html.wallpaper #roomBack .rb-floor::after{content:'';position:absolute;inset:0;background:linear-gradient(180deg,rgba(246,235,220,0) calc(100% - 150px),#f6ebdc 100%);z-index:2}
/* calm cream behind the title and under the decorations so they read well on the flowers */
html.wallpaper header::before{content:'';position:absolute;left:50%;top:6px;width:min(560px,92vw);height:150px;transform:translateX(-50%);z-index:-1;pointer-events:none;
  background:radial-gradient(ellipse at 50% 50%,rgba(250,243,232,.92) 0%,rgba(250,243,232,.7) 45%,rgba(250,243,232,0) 72%)}
html.wallpaper .item{background:rgba(252,247,238,.86);border-color:rgba(160,120,60,.38);box-shadow:0 2px 8px rgba(80,55,25,.12)}
html.wallpaper .item:hover{background:rgba(255,251,244,.95)}

/* ===== 27 Nov: the Story button sits on the cover of the book that leans against the bookcase (computers and tablets) ===== */
.bookcase .storybtn.under{left:14%;top:auto;bottom:10%;transform:translate(-50%,50%) rotate(-26deg);height:21px;padding:0 9px;gap:4px;font-size:9.5px;letter-spacing:.12em;z-index:5;
  background:rgba(14,18,40,.82);box-shadow:0 2px 6px rgba(0,0,0,.5)}
.bookcase .storybtn.under svg{width:11px;height:11px}
.bookcase .storybtn.under:hover{transform:translate(-50%,50%) rotate(-26deg) scale(1.06)}

/* ===== 27 Nov: on computers and tablets the "Send a Christmas card" button sits on top, with the language button under it ===== */
@media (min-width:641px){
  .topicons{align-items:flex-start}
  header .topicons .tleft{flex-direction:column;align-items:flex-start;gap:8px}
  .topicons .tleft .cardopen{order:-1}
}

/* ===== 27 Nov: a more exclusive "Send a Christmas card" button – fine double gold line, gold italic lettering, a slow glint of light ===== */
.cardopen{position:relative;overflow:hidden;height:58px;padding:0 20px 0 10px;gap:12px;border-radius:12px;border:1px solid #c9a05a;
  background:linear-gradient(160deg,color-mix(in srgb,var(--bg3,#03162c) 78%,#2a3350) 0%,color-mix(in srgb,var(--bg3,#03162c) 62%,#000) 100%);
  box-shadow:inset 0 0 0 3px color-mix(in srgb,var(--bg3,#03162c) 66%,#000),inset 0 0 0 4px rgba(227,183,91,.42),inset 0 1px 0 4px rgba(255,236,190,.05),0 8px 22px rgba(0,0,0,.42),0 0 0 1px rgba(0,0,0,.4)}
.cardopen .cotxt{font:italic 600 16.5px/1.12 'Playfair Display',Georgia,serif;letter-spacing:.01em;max-width:124px;
  background:linear-gradient(180deg,#fbeec8 0%,#e9c77e 55%,#c99a4a 100%);-webkit-background-clip:text;background-clip:text;-webkit-text-fill-color:transparent;color:#ecd08a;text-shadow:none;filter:drop-shadow(0 1px 1px rgba(0,0,0,.45))}
.cardopen img{width:64px;margin:-8px 0 -2px;filter:drop-shadow(0 3px 5px rgba(0,0,0,.5))}
.cardopen::after{content:'';position:absolute;top:0;bottom:0;left:-40%;width:28%;pointer-events:none;transform:skewX(-20deg);
  background:linear-gradient(90deg,transparent,rgba(255,240,200,.22),transparent);animation:coglint 8s ease-in-out infinite}
@keyframes coglint{0%,70%{left:-40%}100%{left:130%}}
.cardopen:hover{filter:none;transform:translateY(-1px);border-color:#f0d08a;box-shadow:inset 0 0 0 3px color-mix(in srgb,var(--bg3,#03162c) 66%,#000),inset 0 0 0 4px rgba(246,220,154,.7),0 10px 26px rgba(0,0,0,.5),0 0 18px rgba(227,183,91,.25)}
@media (prefers-reduced-motion:reduce){ .cardopen::after{animation:none;display:none} }
html.pearl .cardopen{background:linear-gradient(160deg,#fffaf0,#f1e6d2);border-color:#b08a3e;box-shadow:inset 0 0 0 3px #fbf4e6,inset 0 0 0 4px rgba(160,120,50,.5),0 8px 20px rgba(80,55,25,.22)}
html.pearl .cardopen .cotxt{background:none;-webkit-text-fill-color:#6a4a16;color:#6a4a16;filter:none}
.cardopen .cotxt{text-wrap:balance}
@media (max-width:640px){
  .cardopen{height:42px;padding:0 12px 0 5px;gap:7px;border-radius:10px}
  .cardopen .cotxt{font-size:12.5px;max-width:122px}
  .cardopen img{width:44px;margin:-7px 0 -2px}
}

/* ===== 27 Nov: the story book is bigger on computers (easier to read); the day arrows under it only show when there is more than one day ===== */
@media (min-width:821px){ .bookview .bvbox{width:min(96vw,1280px,calc((100vh - 110px)*1.7))} }
.bvnav.one{display:none}

/* ===== 27 Nov: "Santa's House at Night" – everything black except the room window and the light button (blackout.js) ===== */
.nightout{position:fixed;inset:0;z-index:9000;pointer-events:none;opacity:0;transition:opacity 1.1s ease;overflow:hidden}
.nightout.show{opacity:1;pointer-events:auto}
.nightout .nhole{position:absolute;border-radius:3px;
  border-radius:1px;box-shadow:0 0 0 300vmax #000,inset 0 0 14px 4px rgba(0,0,0,.55)}
.nightlight{position:fixed;left:50%;bottom:max(28px,env(safe-area-inset-bottom));z-index:9001;transform:translate(-50%,16px);opacity:0;pointer-events:none;
  height:46px;padding:0 22px;border-radius:999px;border:1px solid rgba(227,183,91,.55);background:rgba(10,10,14,.9);color:#f3dfa8;
  font:600 14px/1 Manrope,sans-serif;letter-spacing:.04em;white-space:nowrap;max-width:92vw;cursor:pointer;transition:opacity .8s ease .5s,transform .8s ease .5s,box-shadow .2s}
.nightlight.show{opacity:1;transform:translate(-50%,0);pointer-events:auto}
.nightlight:hover,.nightlight:focus-visible{box-shadow:0 0 18px rgba(243,210,140,.35);outline:none}
html.night-on body{overflow:hidden}
#bgPop .nightopt{border-top:1px solid rgba(227,183,91,.25);margin-top:4px;padding-top:8px}
#bgPop .nightdot{background:radial-gradient(circle at 35% 35%,#3a3f5c 0 18%,#000 19%)!important;box-shadow:inset 0 0 0 1px rgba(255,255,255,.2)}
@media (prefers-reduced-motion:reduce){ .nightout,.nightlight{transition:none} }

/* ===== 27 Nov: the window hangs with its top level with the top of the door (offset set by depth.js); the moose at the window follows ===== */
#stage .roomwin,#stage .fp[data-id^="moose"]{margin-top:var(--winDy,0px);margin-left:var(--winDx,0px)}

/* ===== 27 Nov: the language button in the same style as "Send a Christmas card" (double gold line, gold lettering); same size as before, flag kept ===== */
.topicons .langbtn{border-radius:10px;border:1px solid #c9a05a;color:#ecd08a;font:italic 700 13px 'Playfair Display',Georgia,serif;letter-spacing:.06em;
  background:linear-gradient(160deg,color-mix(in srgb,var(--bg3,#03162c) 78%,#2a3350) 0%,color-mix(in srgb,var(--bg3,#03162c) 62%,#000) 100%);
  box-shadow:inset 0 0 0 2.5px color-mix(in srgb,var(--bg3,#03162c) 66%,#000),inset 0 0 0 3.5px rgba(227,183,91,.42),0 6px 16px rgba(0,0,0,.38),0 0 0 1px rgba(0,0,0,.4)}
.topicons .langbtn:hover{border-color:#f0d08a;background:linear-gradient(160deg,color-mix(in srgb,var(--bg3,#03162c) 72%,#3a4360) 0%,color-mix(in srgb,var(--bg3,#03162c) 58%,#000) 100%);
  box-shadow:inset 0 0 0 2.5px color-mix(in srgb,var(--bg3,#03162c) 66%,#000),inset 0 0 0 3.5px rgba(246,220,154,.7),0 8px 20px rgba(0,0,0,.45),0 0 14px rgba(227,183,91,.22)}
.topicons .langbtn .chev{opacity:.9}
html.pearl .topicons .langbtn{color:#6a4a16;border-color:#b08a3e;background:linear-gradient(160deg,#fffaf0,#f1e6d2);
  box-shadow:inset 0 0 0 2.5px #fbf4e6,inset 0 0 0 3.5px rgba(160,120,50,.5),0 6px 16px rgba(80,55,25,.2)}
html.pearl .topicons .langbtn:hover{background:linear-gradient(160deg,#fffdf6,#f5ebd9)}

/* the window hangs on the wall behind the sideboard: the sideboard stands in front of its lower corner */
#stage .roomwin{z-index:1}

/* ===== 27 Nov: the Advent candlestick can stand on the sideboard (advent.js) ===== */
.sideboard .advent.onsb{z-index:5;pointer-events:auto}
.sideboard .advent.onsb .adbase{filter:drop-shadow(0 4px 4px rgba(0,0,0,.5))}
.sideboard.addrop::after{content:'';position:absolute;left:4%;right:12%;top:-2%;height:18%;border-radius:50%;pointer-events:none;
  z-index:4;background:radial-gradient(ellipse at 50% 55%,rgba(255,228,150,.85),rgba(255,214,120,.35) 45%,rgba(246,220,154,0) 72%);mix-blend-mode:screen;animation:addrop .9s ease-in-out infinite alternate}
@keyframes addrop{from{opacity:.55}to{opacity:1}}

/* ===== 27 Nov evening: "Avocado wallpaper" room – 70s Scandinavian green ogee wallpaper (room/wallpaper-avocado.webp). Same rules as the botanical wallpaper above (they read the picture from --paper); here only the colours around it ===== */
html[data-paper="avocado"] #roomBack{--wall-a:#b9bd9f;--wall-b:#b2b697;--wall-c:#a7ab8b;--panel-line:rgba(60,70,40,.2);--panel-hi:rgba(255,255,240,.3);--dado-bg:linear-gradient(#b8bc9d,#afb393)}   /* soft sage panelling, a shade lighter than the wallpaper ground */
html[data-paper="avocado"] #roomBack .rb-wall{background:linear-gradient(180deg,rgba(30,40,15,.12),rgba(30,40,15,0) 30%),var(--paper) 0 0/var(--paper-size) repeat,#888f66}
html[data-paper="avocado"] #roomBack .rb-panel{background-color:#b5b99a}
html[data-paper="avocado"] #roomBack .rb-lwall{background:var(--paper) 0 0/var(--paper-lsize) repeat,#888f66}
html[data-paper="avocado"] body{background:linear-gradient(180deg,rgba(236,238,224,0) calc(var(--roomEnd,900px) - 150px),#eceee0 var(--roomEnd,900px)),var(--paper) 0 0/300px repeat,#eceee0}
html[data-paper="avocado"] #roomBack .rb-floor::after{background:linear-gradient(180deg,rgba(236,238,224,0) calc(100% - 150px),#eceee0 100%)}
html[data-paper="avocado"] header::before{width:min(760px,96vw);height:150px;background:radial-gradient(ellipse at 50% 50%,rgba(240,242,228,.62) 0%,rgba(240,242,228,.38) 45%,rgba(240,242,228,0) 72%)}
html[data-paper="avocado"] .item{background:rgba(248,247,232,.88);border-color:rgba(100,120,40,.38)}

/* ===== 27 Nov evening: choice of floor at the bottom of the Room menu (floorpick.js) ===== */
#bgPop .flhead{border-top:1px solid rgba(227,183,91,.25);margin-top:4px;padding:8px 8px 2px;font:700 10.5px Manrope,sans-serif;letter-spacing:.14em;text-transform:uppercase;color:var(--gold2,#ecd9a6);opacity:.85}
#bgPop .fldot{box-shadow:inset 0 0 0 1px rgba(255,255,255,.22)}
html:root #roomBack[data-floor="oak"]{--floor-a:#e2d2bb;--floor-b:#d3c0a4;--floor-c:#a8967c}
html:root #roomBack[data-floor="tiles"]{--floor-a:#e3d6c0;--floor-b:#d6c8b0;--floor-c:#a99c86}
/* in the dark rooms the pale oak takes the evening light: a little dimmer and warmer, so it does not glare */
html:not(.pearl) #roomBack[data-floor="oak"] .rb-planks,html:not(.pearl) #roomBack[data-floor="tiles"] .rb-planks{filter:brightness(.72) sepia(.12)}
html.q-low #roomBack[data-floor="oak"] .rb-planks{background:repeating-linear-gradient(90deg,rgba(120,95,65,.35) 0 2px,transparent 2px var(--fw,7%))}
html.q-low #roomBack[data-floor="tiles"] .rb-planks{background:repeating-linear-gradient(90deg,rgba(150,140,125,.4) 0 2px,transparent 2px 6%),repeating-linear-gradient(0deg,rgba(150,140,125,.4) 0 2px,transparent 2px 6%)}
/* the fluffy white rug (rugcol.js, key "silver") is a thicker pile: a softer, wider shadow */
.rug.fluffy img{filter:drop-shadow(0 5px 7px rgba(0,0,0,.42)) drop-shadow(0 1px 1px rgba(0,0,0,.3))}
html.pearl #roomBack[data-floor="oak"] .rb-flight,html.pearl #roomBack[data-floor="tiles"] .rb-flight{background:
    radial-gradient(ellipse 30% 70% at var(--lx) 4%,rgba(255,190,120,.22),rgba(255,170,90,.05) 60%,transparent 80%),
    linear-gradient(180deg,rgba(60,40,20,.22) 0,rgba(60,40,20,0) 22px),
    linear-gradient(180deg,transparent 45%,rgba(70,50,30,.16) 100%)}

/* ===== 27 Nov evening: tap the fire extinguisher and it wiggles on its base (rightwall.js) ===== */
.sideboard img.roomext.tapext{pointer-events:auto;cursor:pointer;transform-origin:50% 97%}
.sideboard img.roomext.tapext:focus-visible{outline:2px solid #f6dc9a;outline-offset:3px;border-radius:6px}
.sideboard img.roomext.wig{animation:extwig 1.15s cubic-bezier(.36,.07,.19,.97)}
.sideboard img.roomext.wig-soft{animation:extsoft .5s ease-in-out}
@keyframes extwig{0%{transform:rotate(0)}10%{transform:rotate(-14deg)}22%{transform:rotate(11deg)}34%{transform:rotate(-8deg)}46%{transform:rotate(6deg)}58%{transform:rotate(-4deg)}70%{transform:rotate(2.5deg)}82%{transform:rotate(-1deg)}100%{transform:rotate(0)}}
@keyframes extsoft{0%,100%{transform:rotate(0)}50%{transform:rotate(-3deg)}}

/* 27 Nov evening: on the sideboard the candlestick follows the angle of the sideboard top (advent.js sets --sbskew) */
.sideboard .advent.onsb{transform:translate(-50%,-100%) skewY(var(--sbskew,0deg));transform-origin:50% 100%}
.rug.snowy{width:94.3%}   /* 27 Nov evening: the snow rug is 15% wider than the other rugs (82% × 1.15) */

/* ===== 27 Nov evening: the little grey mouse (mouse.js) – tap the window ===== */
.roomwin .winhit{position:absolute;left:15.3%;top:11.8%;width:69.9%;height:70.9%;padding:0;border:0;background:none;cursor:pointer;pointer-events:auto;z-index:4;-webkit-tap-highlight-color:transparent}
.roomwin .winhit:focus-visible{outline:2px solid #f6dc9a;outline-offset:2px}
.santamouse{position:absolute;height:auto;max-width:none;pointer-events:none;z-index:120;filter:drop-shadow(0 3px 2px rgba(0,0,0,.45))}
.winglass .santamouse.outside{z-index:1;filter:sepia(.6) saturate(1.15) brightness(1.8) contrast(1.05) drop-shadow(0 0 1px rgba(0,0,0,.7)) drop-shadow(0 1px 2px rgba(0,0,0,.6))}   /* 28 Nov: light brownish grey so it shows against the night sky */
/* 27 Nov evening: the card can be sent by Email, SMS or WhatsApp (one row of three), then Copy link / Download */
#cardSheet .more.via{grid-template-columns:repeat(3,minmax(0,1fr))}

/* ===== 27 Nov evening: peek at the next day (peek.js) ===== */
.peekveil{display:flex;flex-wrap:wrap;align-items:center;justify-content:center;gap:4px 8px;max-width:640px;margin:0 auto 8px;padding:9px 16px;border-radius:12px;
  background:rgba(6,13,30,.82);border:1px solid rgba(227,183,91,.45);color:var(--cream,#fbf5e8);font:500 13px/1.4 Manrope,sans-serif;text-align:center;position:relative;z-index:6}
.peekveil[hidden]{display:none}
.peekveil b{font:600 15px 'Cormorant Garamond',serif;color:var(--gold2,#ecd9a6);letter-spacing:.02em}
.peekveil .pkt{flex:1 0 100%;opacity:.9}
html.peeking #tray{pointer-events:none}
html.pearl .peekveil{background:rgba(252,247,238,.92);color:#3a3226;border-color:#b08a3e}
html.pearl .peekveil b{color:#7a5a20}

/* ===== 28 Nov: move the things in the bookcase to another shelf (room.js) ===== */
.stobjs img.mv{pointer-events:auto;cursor:grab;z-index:4;touch-action:none;transition:filter .15s}
.stobjs img.mv:hover{filter:drop-shadow(0 3px 3px rgba(0,0,0,.5)) drop-shadow(0 0 6px rgba(255,220,150,.55))}
.stobjs img.dragging{cursor:grabbing;z-index:10;filter:drop-shadow(0 10px 10px rgba(0,0,0,.55));scale:1.08;transition:none}
.stobjs .stdrop{position:absolute;z-index:3;border:2px dashed rgba(246,220,154,.9);border-radius:10px;background:rgba(246,220,154,.12);pointer-events:none}
.stobjs .stdrop.bad{border-color:rgba(230,90,80,.85);background:rgba(230,90,80,.12)}
.stobjs .stdrop[hidden]{display:none}
.stmove{margin:4px 0 0;max-width:min(86vw,560px);text-align:center;font:500 12.5px Manrope,sans-serif;color:var(--gold2,#ecd9a6);opacity:.8;pointer-events:none}
/* 28 Nov: paid rugs show a small lock before the season pass (rugcol.js) */
.rugctl .rugbtn{position:relative}
.rugctl .rugbtn.locked i{opacity:.55}
.rugctl .rugbtn .rglk{position:absolute;right:-4px;bottom:-4px;font-size:10px;font-style:normal;line-height:1;filter:drop-shadow(0 0 2px #000)}
/* 28 Nov: small SMS / WhatsApp buttons under Share your tree */
#shareSheet .more.via2{margin-top:6px}
#shareSheet .more.via2 button{font-size:12px;padding:7px 10px;min-height:0}
/* 28 Nov: locked decorations one step brighter (still dimmed) */
.item.locked{opacity:.55!important;filter:grayscale(.35)!important}


/* ===== 28 Nov: the Ice spruce is Mathilda's silver tree picture (icetree.js) ===== */
.icespruce{position:absolute;display:none;pointer-events:none;z-index:3;max-width:none}   /* 28 Nov 09:30: a canvas playing Mathilda's turning ice spruce (icetree.js) */
html.icetree .icespruce{display:block;filter:drop-shadow(0 0 2px rgba(240,250,255,.7)) drop-shadow(0 0 18px rgba(170,215,245,.35)) drop-shadow(0 14px 10px rgba(0,0,0,.35))}
html.icetree #spin{opacity:0}

/* ===== 28 Nov: "Orange wave wallpaper" room – 70s waves; the panelling under the rail is a deeper terracotta from the same palette ===== */
html[data-paper="wave"] #roomBack{--wall-a:#b97353;--wall-b:#b06b4c;--wall-c:#a46245;--panel-line:rgba(90,40,20,.25);--panel-hi:rgba(255,230,200,.3);--dado-bg:linear-gradient(#b97353,#ad6a4b)}
html[data-paper="wave"] #roomBack .rb-wall{background:linear-gradient(180deg,rgba(80,40,20,.14),rgba(80,40,20,0) 30%),var(--paper) 0 0/var(--paper-size) repeat,#d29e74}
html[data-paper="wave"] #roomBack .rb-panel{background-color:#b47050}
html[data-paper="wave"] #roomBack .rb-lwall{background:var(--paper) 0 0/var(--paper-lsize) repeat,#c58f66}
html[data-paper="wave"] body{background:linear-gradient(180deg,rgba(243,226,208,0) calc(var(--roomEnd,900px) - 150px),#f3e2d0 var(--roomEnd,900px)),var(--paper) 0 0/480px 240px repeat,#f3e2d0}
html[data-paper="wave"] #roomBack .rb-floor::after{background:linear-gradient(180deg,rgba(243,226,208,0) calc(100% - 150px),#f3e2d0 100%)}
html[data-paper="wave"] header::before{width:min(760px,96vw);height:150px;background:radial-gradient(ellipse at 50% 50%,rgba(246,232,216,.8) 0%,rgba(246,232,216,.5) 45%,rgba(246,232,216,0) 72%)}
html[data-paper="wave"] .item{background:rgba(250,240,228,.88);border-color:rgba(160,90,50,.38)}

/* 28 Nov: two 70s carpets (floorpick.js) – dimmed a little in the dark rooms like the other light floors */
html:not(.pearl) #roomBack[data-floor="olive"] .rb-planks,html:not(.pearl) #roomBack[data-floor="stripes"] .rb-planks{filter:brightness(.8)}

/* ===== 28 Nov: "70s teak" interior – the room takes the materials of Mathilda's 70s inspiration: grasscloth wallpaper on the back wall
   (room/wall-grasscloth.webp, cut from the photo), vertical teak panelling below the rail and on the side walls, and a warm brass lantern.
   When a wallpaper is chosen in the Room menu, the wallpaper wins and only the panelling and lantern change. ===== */
html.teakroom:not(.wallpaper) #roomBack{--dado-bg:repeating-linear-gradient(90deg,#9c5c28 0 2px,#b8783c 2px 22px,#ad6c32 22px 40px,#8a4e20 40px 42px)}
html.teakroom:not(.wallpaper) #roomBack .rb-wall{background:linear-gradient(180deg,rgba(30,15,5,.35),rgba(30,15,5,0) 35%),url(room/wall-grasscloth.webp) 0 0/600px 72px repeat,#8f6234}
html.teakroom:not(.wallpaper) #roomBack .rb-panel{background:repeating-linear-gradient(90deg,#9c5c28 0 2px,#b8783c 2px 22px,#ad6c32 22px 40px,#8a4e20 40px 42px)!important}
html.teakroom:not(.wallpaper) #roomBack .rb-lwall{background:repeating-linear-gradient(90deg,#7e4a20 0 2px,#a8703a 2px 26px,#9a6230 26px 48px,#6e3e18 48px 50px),#9a6230}
html.teakroom .bclamp img,html.teakroom .stlamp img{filter:sepia(.9) saturate(1.7) hue-rotate(-6deg) brightness(1.15) drop-shadow(0 3px 4px rgba(0,0,0,.6))}
html.teakroom:not(.wallpaper) #roomBack .rb-rail,html.teakroom:not(.wallpaper) #roomBack .rb-lrail{background:linear-gradient(#c48a4c,#7a4618)!important}
html.teakroom:not(.wallpaper) #roomBack .rb-lwall{background:repeating-linear-gradient(90deg,#7e4a20 0 1px,#a8703a 1px 14px,#9a6230 14px 26px,#6e3e18 26px 27px),#9a6230}
/* 28 Nov: the Rug menu in the side panel (rugcol.js) */
.rugpop{width:236px}
.rugpop .rugsw{display:flex;flex-wrap:wrap;gap:7px;padding:4px}
.rugpop .rugbtn{position:relative;width:32px;height:32px;padding:3px;border-radius:50%;border:1.5px solid rgba(227,183,91,.35);background:none;cursor:pointer}
.rugpop .rugbtn i{display:block;width:100%;height:100%;border-radius:50%;box-shadow:inset 0 0 0 1px rgba(255,255,255,.18)}
.rugpop .rugbtn[aria-pressed="true"]{border-color:#f6dc9a;box-shadow:0 0 8px rgba(246,220,154,.6)}
.rugpop .rugbtn.locked i{opacity:.55}
.rugpop .rugbtn .rglk{position:absolute;right:-4px;bottom:-4px;font-size:10px;font-style:normal;line-height:1;filter:drop-shadow(0 0 2px #000)}
.rugpop .rugnone i{background:linear-gradient(135deg,transparent 46%,#e9b0a0 46% 54%,transparent 54%),rgba(255,255,255,.06)}
.rugpop .rugname{font:600 11.5px Manrope,sans-serif;color:var(--gold2,#ecd9a6);opacity:.85;padding:4px 6px 2px}
.rug.tomte{top:84.5%}
/* 28 Nov 10:20: peeking at a coming day – the decorations keep their colours (only a small lock and a light dim), and the two extra date lines
   under them are hidden because the note above already says when the day opens */
html.peeking #tray .item.locked{opacity:.82!important;filter:none!important}
html.peeking #pickNote,html.peeking #cdNote{display:none}

/* 28 Nov: Apple Pay / Google Pay buttons above the PayPal button (index.html renderWallets) */
.ppwallets{display:flex;flex-direction:column;gap:8px;margin:0 0 8px}
.ppwallets:empty{display:none}
.ppwallets apple-pay-button{--apple-pay-button-width:100%;--apple-pay-button-height:44px;--apple-pay-button-border-radius:22px;display:block}
.ppwallets .gpbtn{height:44px;border-radius:22px;overflow:hidden}
.ppwallets .gpbtn button{border-radius:22px!important}

/* ===== 28 Nov: Santa's hot-air balloon floating round the tree (hotair.js) ===== */
.hotair{position:absolute;left:0;top:0;pointer-events:none;will-change:transform}
.hotair[hidden]{display:none}
.hotair img{display:block;width:100%;height:auto;transform-origin:50% 40%;animation:hotbreathe 3.2s ease-in-out infinite;filter:drop-shadow(0 10px 14px rgba(0,0,0,.35))}
@keyframes hotbreathe{0%,100%{scale:1 1}50%{scale:1.035 1.02}}
@media (prefers-reduced-motion:reduce){ .hotair img{animation:none} }

/* ===== 28 Nov: "Send a Christmas card" and the language button in the style of the decoration tiles –
   frosted glass, one fine cream-gold line, soft rounded corners, Manrope lettering (no double frame, no gold script) ===== */
.cardopen,.topicons .langbtn{border-radius:16px;border:1.5px solid rgba(246,220,154,.6);
  background:linear-gradient(180deg,rgba(255,255,255,.14),rgba(255,255,255,.06)),rgba(40,58,92,.5);
  -webkit-backdrop-filter:blur(6px);backdrop-filter:blur(6px);
  box-shadow:0 6px 18px rgba(0,0,0,.28),inset 0 1px 0 rgba(255,255,255,.08)}
.cardopen:hover,.topicons .langbtn:hover{transform:translateY(-2px);border-color:rgba(246,220,154,.9);
  background:linear-gradient(180deg,rgba(255,255,255,.18),rgba(255,255,255,.08)),rgba(40,58,92,.55);box-shadow:0 10px 22px rgba(0,0,0,.32),inset 0 1px 0 rgba(255,255,255,.1)}
.cardopen::after{display:none}
.cardopen .cotxt{font:700 12.5px/1.25 Manrope,sans-serif;letter-spacing:.1em;text-transform:uppercase;max-width:132px;
  background:none;-webkit-text-fill-color:#f3e6c4;color:#f3e6c4;filter:none;text-shadow:0 1px 2px rgba(0,0,0,.4)}
.topicons .langbtn{color:#f3e6c4;font:700 12px Manrope,sans-serif;letter-spacing:.14em}
@media (max-width:640px){ .cardopen{border-radius:12px} .cardopen .cotxt{font-size:10.5px;max-width:118px} .topicons .langbtn{border-radius:12px} }
html.pearl .cardopen,html.pearl .topicons .langbtn{background:linear-gradient(180deg,rgba(255,255,255,.75),rgba(255,255,255,.5));border-color:rgba(160,120,50,.55);box-shadow:0 6px 16px rgba(80,55,25,.15)}
html.pearl .cardopen .cotxt,html.pearl .topicons .langbtn{-webkit-text-fill-color:#5a4220;color:#5a4220;text-shadow:none}

/* ===== 28 Nov: the lantern takes the colour of the chosen interior (room.js sets html[data-interior]) ===== */
html[data-interior="black"] .bclamp img,html[data-interior="black"] .stlamp img{filter:grayscale(1) brightness(.55) contrast(1.2) drop-shadow(0 3px 4px rgba(0,0,0,.6))}
html[data-interior="wine"] .bclamp img,html[data-interior="wine"] .stlamp img{filter:sepia(.6) saturate(2.4) hue-rotate(-40deg) brightness(.8) drop-shadow(0 3px 4px rgba(0,0,0,.6))}
html[data-interior="birch"] .bclamp img,html[data-interior="birch"] .stlamp img{filter:grayscale(.7) sepia(.15) brightness(1.75) contrast(.95) drop-shadow(0 3px 4px rgba(0,0,0,.45))}
html[data-interior="pink"] .bclamp img,html[data-interior="pink"] .stlamp img{filter:sepia(.5) saturate(2) hue-rotate(-60deg) brightness(1.45) drop-shadow(0 3px 4px rgba(0,0,0,.5))}

/* ===== 28 Nov: "Night at Santa's House" stands out in the Room menu, and the night through the window is deeper ===== */
#bgPop .nightopt{margin:6px 4px 2px;padding:9px 10px;border:1px solid rgba(160,170,255,.45)!important;border-radius:12px;
  background:linear-gradient(135deg,#1b1f4a,#0a0c22)!important;color:#e6e8ff!important;box-shadow:inset 0 0 12px rgba(120,130,255,.18)}
#bgPop .nightopt:hover{background:linear-gradient(135deg,#262b66,#11143a)!important;border-color:rgba(190,195,255,.75)!important}
#bgPop .nightdot{background:radial-gradient(circle at 62% 38%,#0a0c22 0 34%,transparent 35%),radial-gradient(circle,#f3e6b0 0 55%,#f3e6b0 56%)!important;box-shadow:0 0 8px rgba(243,230,176,.6)!important}
.nightout .nhole{overflow:hidden}
.nightout .nhole .nsky{position:absolute;inset:0;background:linear-gradient(180deg,rgba(0,0,12,.62),rgba(0,0,20,.45));pointer-events:none}
.nightout .nhole .nstars{position:absolute;inset:0;pointer-events:none;opacity:.9;
  background-image:radial-gradient(1.2px 1.2px at 12% 18%,#fff,transparent),radial-gradient(1px 1px at 33% 9%,#fff,transparent),radial-gradient(1.4px 1.4px at 58% 26%,#fff,transparent),
    radial-gradient(1px 1px at 76% 14%,#dfe8ff,transparent),radial-gradient(1.2px 1.2px at 88% 38%,#fff,transparent),radial-gradient(1px 1px at 22% 44%,#fff,transparent),
    radial-gradient(1px 1px at 45% 52%,#e8eeff,transparent),radial-gradient(1.3px 1.3px at 67% 61%,#fff,transparent),radial-gradient(1px 1px at 8% 70%,#fff,transparent),radial-gradient(1px 1px at 92% 74%,#fff,transparent);
  animation:ntwinkle 3.4s ease-in-out infinite}
.nightout .nhole .nstars.n2{transform:translate(7%,11%) scale(1.15);animation-delay:-1.7s;opacity:.7}
@keyframes ntwinkle{0%,100%{opacity:.9}50%{opacity:.35}}
@media (prefers-reduced-motion:reduce){ .nightout .nhole .nstars{animation:none} }
/* 28 Nov: on phones the door stands behind the tree (it was drawn in front of the lower branches); a tap on the visible part still rattles it (roomfx.js) */
@media (max-width:820px){ .roomdoor{z-index:1} }   /* 2 Dec: also on tablets, so Santa's hot-air balloon never flies behind the door */

/* ===== 28 Nov: glitter on the "Wishes for you" cloud (wishself.js) – tiny diamonds that flash in rainbow colours, some with an electric crackle ===== */
#wishSelf{position:relative}
#wishSelf .wglit{position:absolute;inset:0;pointer-events:none;z-index:3;overflow:visible}
#wishSelf .wglit i{position:absolute;transform:translate(-50%,-50%) rotate(45deg) scale(0);background:linear-gradient(135deg,#fff 0 30%,var(--c) 55%,#fff 80%);
  box-shadow:0 0 6px 1px var(--c),0 0 12px 2px rgba(255,255,255,.55);border-radius:1px;opacity:0;animation:wglit .9s ease-out forwards}
#wishSelf .wglit i::before,#wishSelf .wglit i::after{content:'';position:absolute;left:50%;top:50%;width:260%;height:1px;background:linear-gradient(90deg,transparent,#fff,transparent);transform:translate(-50%,-50%)}
#wishSelf .wglit i::after{transform:translate(-50%,-50%) rotate(90deg)}
#wishSelf .wglit i.zap{animation-name:wzap}
@keyframes wglit{0%{opacity:0;transform:translate(-50%,-50%) rotate(45deg) scale(0)}35%{opacity:1;transform:translate(-50%,-50%) rotate(45deg) scale(1.15)}100%{opacity:0;transform:translate(-50%,-50%) rotate(135deg) scale(.2)}}
@keyframes wzap{0%{opacity:0;transform:translate(-50%,-50%) rotate(45deg) scale(0)}15%{opacity:1;transform:translate(-50%,-50%) rotate(45deg) scale(1.3)}25%{opacity:.2}35%{opacity:1;filter:brightness(1.8)}45%{opacity:.3}60%{opacity:1}100%{opacity:0;transform:translate(-50%,-50%) rotate(100deg) scale(.3)}}
/* 28 Nov: Share your tree – own wish box, and smaller app buttons (one tidy row of chips) */
#shareSheet .sharewish{width:100%;box-sizing:border-box;margin:4px 0 8px;padding:9px 12px;border-radius:10px;border:1px solid rgba(227,183,91,.45);background:rgba(255,255,255,.06);color:#fbf5e8;font:500 14px/1.4 Manrope,sans-serif;resize:vertical}
#shareSheet .sharewish[hidden]{display:none}
#shareSheet .apps{display:flex;flex-wrap:wrap;justify-content:center;gap:6px}
#shareSheet .apps button{flex:0 1 auto;min-height:0;padding:6px 12px;font-size:12px;border-radius:999px}
#shareSheet .more button{min-height:0;padding:8px 10px;font-size:13px}
#shareSheet .more.via2 button{padding:6px 10px;font-size:12px;border-radius:999px}

/* ===== 28 Nov: send the card free, or as a gift (card + the whole season) ===== */
#cardSheet .cardkind{display:grid;grid-template-columns:1fr 1fr;gap:8px;margin:10px 0 4px}
#cardSheet .cardkind button{position:relative;padding:10px 8px;border-radius:12px;border:1px solid rgba(246,220,154,.3);background:rgba(251,245,232,.05);color:var(--cream,#fbf5e8);font:700 13px Manrope,sans-serif;cursor:pointer;line-height:1.25}
#cardSheet .cardkind button small{display:block;font-weight:500;font-size:11.5px;opacity:.75;margin-top:2px}
#cardSheet .cardkind button[aria-checked="true"]{border-color:#f6dc9a;background:rgba(246,220,154,.14);box-shadow:0 0 0 1px #f6dc9a inset}
#cardSheet .cardkind #ckGift::after{content:attr(data-b);position:absolute;top:-8px;right:8px;padding:1px 7px;border-radius:999px;background:linear-gradient(#f6dc9a,#e3b75b);color:#1a1205;font:800 9.5px/1.6 Manrope,sans-serif;letter-spacing:.08em}
#cardSheet .cardgift{margin:6px 0 8px;padding:10px 12px;border-radius:12px;border:1px dashed rgba(246,220,154,.55);background:rgba(246,220,154,.06);text-align:center}
#cardSheet .cardgift[hidden]{display:none}
#cardSheet .cardgift p{margin:0 0 8px;font-size:12.5px;line-height:1.45;opacity:.9}
#cardSheet .cardgift .cgmsg{margin:6px 0 0;font-size:12.5px;color:#f6dc9a}
#cardSheet .cardgift .cgmsg:empty{display:none}
#cardSheet .cardgift .cgmsg.ok{font-weight:700}
#cardSheet .cardgift .cgtest{margin-top:4px;padding:7px 14px;border-radius:999px;border:1px solid rgba(246,220,154,.5);background:none;color:#f6dc9a;font:600 12.5px Manrope,sans-serif;cursor:pointer}
#cardSheet .cardgift .cgtest[hidden],#cardSheet .cardgift #cgPay[hidden]{display:none}
#cardSheet button:disabled{opacity:.4;cursor:not-allowed}

/* ===== 28 Nov: the share options as coloured bars (colour from the picture, see pillColour) with a tick box and an arrow ===== */
#shareSheet .shareq.pill{position:relative;display:flex;align-items:center;justify-content:flex-start;gap:11px;width:100%;box-sizing:border-box;margin:8px 0 0;padding:11px 16px;
  border-radius:999px;background:var(--pill,#3b2a8a);border:1.5px solid var(--pill2,#5b48b8);color:#fff;font:700 14px Manrope,sans-serif;cursor:pointer;
  box-shadow:0 4px 14px rgba(0,0,0,.28);transition:filter .15s,transform .15s,background .3s}
#shareSheet .shareq.pill:hover{filter:brightness(1.1)}
#shareSheet .shareq.pill:active{transform:scale(.985)}
#shareSheet .shareq.pill input{position:absolute;opacity:0;width:1px;height:1px;margin:0;pointer-events:none}
#shareSheet .shareq.pill .tick{flex:0 0 20px;height:20px;border-radius:6px;border:2px solid rgba(255,255,255,.85);box-sizing:border-box;display:grid;place-items:center;transition:background .15s,border-color .15s}
#shareSheet .shareq.pill .tick::after{content:'';width:5px;height:10px;border:solid #1a1205;border-width:0 2.5px 2.5px 0;transform:rotate(45deg) translate(-1px,-1px) scale(0);transition:transform .15s}
#shareSheet .shareq.pill input:checked+.tick{background:linear-gradient(#f6dc9a,#e3b75b);border-color:#f6dc9a}
#shareSheet .shareq.pill input:checked+.tick::after{transform:rotate(45deg) translate(-1px,-1px) scale(1)}
#shareSheet .shareq.pill input:focus-visible+.tick{outline:2px solid #f6dc9a;outline-offset:3px}
#shareSheet .shareq.pill .pl{flex:1;text-align:left}
#shareSheet .shareq.pill .chev{flex:0 0 10px;width:9px;height:9px;border:solid #fff;border-width:0 2px 2px 0;transform:rotate(45deg) translateY(-3px);transition:transform .2s;opacity:.9}
#shareSheet .shareq.pill input:checked~.chev{transform:rotate(-135deg) translate(-2px,-1px)}
#shareSheet .shareq.pill+.sharewish{margin-top:8px}

/* 28 Nov, 14:25: calmer bars – softer corners like the "Share my tree" tile, a thin line, no arrow, and as wide as the picture */
#shareSheet .shareq.pill,#shareSheet .shareq.pill+.sharewish,#shareSheet .sharewish{width:var(--pillw,100%);max-width:100%;margin-left:auto;margin-right:auto}
#shareSheet .shareq.pill{border-radius:14px;border:1px solid var(--pill2,#5b48b8);padding:10px 14px;font-size:13.5px;box-shadow:0 2px 8px rgba(0,0,0,.22)}
#shareSheet .shareq.pill .tick{flex-basis:18px;height:18px;border-radius:5px;border-width:1.5px}
#shareSheet .sharewish{border-radius:14px;border-width:1px}

/* ===== 28 Nov, 14:35: share options as gradient buttons (like the button examples). Colour from the picture (pillColour).
   Left: an icon for the option (❝ quote, ✦ wish). Right: a round switch – an outlined + when off, a white disc with a ✓ when on.
   Off = a quieter button; on = full colour and a soft glow. ===== */
#shareSheet .shareq.pill{gap:12px;padding:12px 16px;border:0;border-radius:10px;
  background:linear-gradient(100deg,var(--g1,#5b3bd6),var(--g2,#c56be8));
  font:800 13px/1.2 Manrope,sans-serif;letter-spacing:.06em;text-transform:uppercase;color:#fff;
  box-shadow:0 8px 18px -6px var(--glow,rgba(120,80,220,.55));
  filter:saturate(.55) brightness(.82);transition:filter .25s,box-shadow .25s,transform .15s}
#shareSheet .shareq.pill:hover{filter:saturate(.8) brightness(.95)}
#shareSheet .shareq.pill:has(input:checked){filter:none;box-shadow:0 10px 24px -6px var(--glow,rgba(120,80,220,.6)),0 0 0 1px rgba(255,255,255,.18) inset}
#shareSheet .shareq.pill::before{content:attr(data-ico);flex:0 0 auto;font:700 18px/1 Georgia,serif;opacity:.95;text-shadow:0 1px 2px rgba(0,0,0,.25)}
#shareSheet .shareq.pill .pl{text-shadow:0 1px 2px rgba(0,0,0,.25)}
#shareSheet .shareq.pill .tick{order:3;flex:0 0 22px;height:22px;border-radius:50%;border:2px solid rgba(255,255,255,.9);background:none;position:relative}
#shareSheet .shareq.pill .tick::before,#shareSheet .shareq.pill .tick::after{content:'';position:absolute;left:50%;top:50%;background:#fff;border:0;width:10px;height:2px;border-radius:1px;transform:translate(-50%,-50%);transition:transform .25s,opacity .2s}
#shareSheet .shareq.pill .tick::after{transform:translate(-50%,-50%) rotate(90deg)}
#shareSheet .shareq.pill input:checked+.tick{background:#fff;border-color:#fff;box-shadow:0 2px 6px rgba(0,0,0,.25)}
#shareSheet .shareq.pill input:checked+.tick::before{opacity:0}
#shareSheet .shareq.pill input:checked+.tick::after{width:5px;height:10px;background:none;border:solid var(--g1,#5b3bd6);border-width:0 2.5px 2.5px 0;border-radius:0;transform:translate(-50%,-62%) rotate(45deg)}
#shareSheet .shareq.pill input:checked+.tick{animation:tickpop .3s ease}
@keyframes tickpop{0%{transform:scale(.6)}60%{transform:scale(1.15)}100%{transform:scale(1)}}
#shareSheet .shareq.pill::before{width:20px;text-align:center;font-size:20px;line-height:20px;height:20px;overflow:visible}
#shareSheet .shareq.pill[data-ico="❝"]::before{font-size:26px;line-height:30px}

/* ===== 28 Nov, 16:00: phone check – nothing may stick out sideways (the extinguisher and the tap area did by ~10 px,
   which made phones lay the page out wider and cut off the bottom bar's labels) ===== */
html{overflow-x:hidden}
/* 28 Nov evening: only on phones and tablets. On wide screens the room is narrower than the page, and the clip cut the fire extinguisher in half and drew a straight
   seam down the floor at the room's edge. The old-browser fallback (overflow-x:hidden) is gone too: it also cut things off above and below the room – html{overflow-x:hidden} is enough there. */
@media (max-width:820px){ .room{overflow-x:clip} }
/* small phones (iPhone SE): the menus above the bottom bar never run off the top of the screen – they scroll inside instead */
@media (max-width:640px){ .side .pop{max-height:calc(100vh - 110px);max-height:calc(100dvh - 110px);overflow-y:auto;overscroll-behavior:contain;-webkit-overflow-scrolling:touch} }

/* ===== 28 Nov, 16:30: the new bookcase with the brick reading nook =====
   Room: the picture (room/shelf-side.webp, 964 × 1136) is placed so its cell grid sits where the old one did (440 × 704 units);
   the nook reaches out past the box on the right. Study: the bookcase is the secret door, the nook (room/shelf-alcove.webp) stands beside it. */
.bookcase .bcside{inset:auto;left:-.377%;top:1.117%;width:132.1%;height:97.29%;max-width:none}
.stwall{--stw:min(62vw,calc(70vh*1.075));width:var(--stw);aspect-ratio:1034/962;margin-right:calc(var(--stw)*.3366)}
.stalcove{position:absolute;left:100%;top:0;height:100%;width:33.66%;display:block;pointer-events:none;filter:drop-shadow(0 18px 30px rgba(0,0,0,.6));z-index:0}
.stbehind{z-index:0}
@media (max-width:640px){ .stwall{--stw:min(71vw,calc(62vh*1.075))} }

/* 28 Nov: the brass lock plate low on the back-wall door (roomfx.js) – 460 × 688 door picture: centre x 371 (under the handle), y 585 */
.roomdoor .doorlock{position:absolute;left:80.6%;top:85%;width:5.4%;height:auto;transform:translate(-50%,-50%);pointer-events:none;filter:drop-shadow(0 1px 1px rgba(0,0,0,.5)) brightness(.92)}

/* 28 Nov: the nine sway views of the new bookcase cover −20…586 × −18…717 of the 440 × 704 box (the nook reaches out to the right) */
.bookcase .bcview{left:-4.545%;top:-2.557%;width:137.727%;height:104.403%;max-width:none}

/* 28 Nov: the bookcase is lifted or lowered so the reading nook stands on the floor line of the back wall (room.js sets --bcdy) */
.bookcase{transform:translateY(var(--bcdy,0px))}

/* 28 Nov: the drawer under the bench in the reading nook (room.js) – placed in the 440 × 704 box like the bookcase picture */
.bookcase .nookdrawer{position:absolute;left:99.24%;top:64.06%;width:48.92%;height:19.44%;max-width:none;pointer-events:none;opacity:0;transform:translate(-3%,-6%);transition:opacity .35s,transform .45s cubic-bezier(.2,.8,.2,1);z-index:2;filter:drop-shadow(0 6px 8px rgba(0,0,0,.5))}
.bookcase.nookopen .nookdrawer{opacity:1;transform:none}
.bookcase .nookbtn{position:absolute;left:101.29%;top:66.2%;width:45.9%;height:16.27%;padding:0;border:0;background:none;cursor:pointer;pointer-events:auto;z-index:3;-webkit-tap-highlight-color:transparent;border-radius:6px}
.bookcase .nookbtn:focus-visible{outline:2px solid #f6dc9a;outline-offset:2px}
.bookcase:not(.nookopen) .nookbtn:hover{box-shadow:inset 0 0 0 1px rgba(246,220,154,.35)}
@media (prefers-reduced-motion:reduce){ .bookcase .nookdrawer{transition:none} }

/* 28 Nov: the reindeer in the nook drawer. Layers: inside of the drawer (nookdrawer) → reindeer (nookdeer) → front and left side of the drawer (nookfront) → tap area (nookbtn) */
.bookcase .nookfront{position:absolute;left:99.24%;top:64.06%;width:48.92%;height:19.44%;max-width:none;pointer-events:none;opacity:0;transform:translate(-3%,-6%);transition:opacity .35s,transform .45s cubic-bezier(.2,.8,.2,1);z-index:2}
.bookcase.nookopen .nookfront{opacity:1;transform:none}
.bookcase .nookdeer{position:absolute;left:127.5%;top:54.6%;width:28.8%;height:auto;max-width:none;transform:translateX(-50%);pointer-events:none;z-index:2;display:none}
.bookcase.nookopen .nookdeer[src]{display:block}
.bookcase .nookbtn{z-index:3}

/* 28 Nov: diamond snowfall (Snow menu → Diamond snowfall): Mathilda's whirling-diamonds film, repeated across the page */
#diamonds{position:fixed;inset:0;z-index:1;pointer-events:none;background:url(room/diamond-snow.webp) 0 0/800px auto repeat;opacity:.95}
#diamonds[hidden]{display:none}
@media (max-width:640px){ #diamonds{background-size:520px auto} }
@media (prefers-reduced-motion:reduce){ #diamonds{opacity:.6} }
#snowPop .opt[hidden]{display:none}
/* 28 Nov: the story book on iPhone showed a grey, blocky shape behind the text (the room behind leaking through in Safari).
   The book is put on its own layer, and each page gets a light wash of the paper colour, so any background stays faint. */
.study,.bookview{-webkit-transform:translateZ(0);transform:translateZ(0)}
.bvpage{background:rgba(245,230,192,.84);box-shadow:0 0 2.4cqw 1.6cqw rgba(245,230,192,.84);border-radius:1cqw}

/* 28 Nov: the stopwatch game in the story book (day 2) – the face without hands, and one hand turning round the brass pivot */
.bvpage .stwatch{position:relative;display:block;width:min(34cqw,170px);margin:1.2cqw auto .6cqw;padding:0;border:0;background:none;cursor:pointer;-webkit-tap-highlight-color:transparent}
.bvpage .stwatch img{display:block;width:100%;height:auto;filter:drop-shadow(0 4px 6px rgba(60,35,10,.45))}
.bvpage .stwatch .swhand{position:absolute;left:52.19%;top:34%;width:2.2%;height:35.73%;margin-left:-1.1%;transform-origin:50% 78.3%;pointer-events:none;
  background:linear-gradient(#1b1611,#1b1611);clip-path:polygon(40% 0,60% 0,70% 78%,100% 84%,100% 100%,0 100%,0 84%,30% 78%)}
.bvpage .stwatch:focus-visible{outline:2px solid #8b5a22;outline-offset:4px;border-radius:50%}
.bvpage .stwatch.done{cursor:default}
@media (max-width:640px){ .bvpage .stwatch{width:min(30cqw,150px)} }

/* ===== 28 Nov evening: quality check ===== */
/* the lantern's glow on the end of the bookcase started with a straight edge (a pale stripe down the last column of the new bookcase): the same glow, now fading out on all sides */
.bookcase .bclight{left:72%;width:84%;background:radial-gradient(ellipse 33% 50% at 30.6% 50%,rgba(255,170,70,.5),rgba(255,140,40,.16) 55%,transparent 75%)}
/* the story book: real pages (room.js layoutPages) – a page shows whole lines only, so the fade at the top and bottom edge is no longer needed */
.bvpage #bvT.story{overflow:hidden;padding-bottom:0;-webkit-mask-image:none!important;mask-image:none!important;touch-action:none}
.bvpage .bvfoot{margin-top:auto}
.bvpage .bvt.story{font-size:max(1.55cqw,14px)}
/* phones and upright tablets: one page at a time, as large as the screen allows (before: 13 px text on phones, 11 px on an upright iPad, and the
   day 2 stopwatch was cut off at the bottom of the page) */
@media (max-width:820px){
  .bookview .bvbox{width:96vw;gap:10px}
  .bvwrap{--bw:min(238vw,1180px);width:var(--bw);margin-left:calc(50% - var(--bw)*.285)}
  .bvpage.r{display:none}
  .bvpage.l{left:10.5%;width:36%}
  .bvwrap.showq .bvpage.l{display:none} .bvwrap.showq .bvpage.r{display:flex;left:10.5%;width:36%}
  .bvpage h4{font-size:1.2cqw;margin-bottom:1.6cqw}
  .bvpage .bvt.story{font-size:clamp(15px,1.75cqw,19px);line-height:1.45}
  .bvpage .stbtns{position:static;background:none;padding:0;gap:1cqw;flex-wrap:wrap}
  .bvpage .stbtns .stq{display:inline-block}
  .bvpage .stbtns button,.stform button,.stpager button{font-size:clamp(13px,1.45cqw,16px);padding:.8cqw 1.5cqw;min-height:40px}
  .stpager{font-size:clamp(13px,1.45cqw,16px)}
  .bvfoot{gap:1cqw;padding-top:1cqw}
  .bvpage .stback{display:block;font-size:clamp(14px,1.5cqw,17px);min-height:30px}
  .bvpage h5{font-size:1.3cqw;margin-bottom:1.2cqw}
  .bvpage .stqt{font-size:clamp(16px,2cqw,22px);line-height:1.35}
  .bvpage .sthintt,.stmsg,.stnum{font-size:clamp(13px,1.45cqw,16px)}
  .stmsg{min-height:1.6em}
  .stform input{font-size:clamp(18px,2.4cqw,24px);width:11cqw}
  .stnum b{font-size:clamp(17px,2.1cqw,22px)}
  .bvpage .stwatch{width:min(14.5cqw,150px);margin:1cqw auto .4cqw}
  .bvpage #bvT2.story{overflow-y:auto}
}
.bvpage .sttxt .stp{margin:0;white-space:pre-line}
/* phones: the title sat right against the card button above it (the tops of the letters touched its edge) – a little air */
@media (max-width:640px){ html header h1{margin-top:12px} }
/* large bookcase view: the lantern stood in front of the bottom right square and hid one of the day 1 mice – it now stands by the nook, clear of the squares */
.stlamp{left:100.5%}
/* 28 Nov evening (2): the lantern stands just past the end of the bookcase, in front of the corner of the reading nook, so the bottom right square (the day 1 mice) is in full view in the room too */
.bookcase .bclamp{left:100%;bottom:10%;width:17%}
/* a phone held sideways: the "turn your phone upright" note (room.js) */
.turnnote{position:fixed;inset:0;z-index:400;display:grid;place-items:center;padding:16px;background:rgba(2,6,15,.93);-webkit-backdrop-filter:blur(4px);backdrop-filter:blur(4px);color:#ecd9a6;text-align:center}
.turnnote[hidden]{display:none}
.turnnote .tnbox{max-width:440px}
.turnnote svg{width:54px;height:54px;color:#f6dc9a;animation:tnturn 2.6s ease-in-out infinite}
.turnnote h3{margin:6px 0 4px;font:italic 800 24px/1.2 'Playfair Display',serif;color:#f6dc9a}
.turnnote p{margin:0 0 14px;font:500 14px/1.45 Manrope,sans-serif;opacity:.85}
.turnnote button{min-height:40px;padding:0 18px;border-radius:99px;border:1px solid rgba(227,183,91,.55);background:rgba(255,255,255,.05);color:#ecd9a6;font:700 11px Manrope,sans-serif;letter-spacing:.14em;text-transform:uppercase;cursor:pointer}
@keyframes tnturn{0%,25%{transform:rotate(90deg)}60%,100%{transform:rotate(0)}}
@media (prefers-reduced-motion:reduce){ .turnnote svg{animation:none} }
/* pictures inside the story text (story.js pics) – sized by room.js to whole lines, no background */
.bvpage .stfig{margin:0;display:flex;align-items:center;justify-content:center;overflow:hidden}
.bvpage .stfig img{display:block;max-width:100%;object-fit:contain;filter:drop-shadow(0 3px 4px rgba(60,35,10,.28))}
.bvpage .stfig .stanim{display:block;background-repeat:no-repeat;background-position:0% 0;filter:drop-shadow(0 3px 4px rgba(60,35,10,.22))}
/* seven Christmas cards (the yellow ice-tree card first): on phones the small pictures are a little smaller so all seven stay on one row */
@media (max-width:480px){ .xcard .cardpick{gap:5px;flex-wrap:nowrap} .xcard .cardpick button img{width:38px} }

/* ===== 28 Nov evening: the walls meet properly, and more depth in the room ===== */
/* the rail and the skirting board on the side walls have the same colour as on the back wall (they were grey: a full-height gradient plus the wall's shade lay over them) */
#roomBack .rb-lrail{z-index:1;background:color-mix(in srgb,var(--wall-a) 92%,#fff)!important}
#roomBack .rb-lskirt{z-index:1;background:linear-gradient(color-mix(in srgb,var(--wall-a) 90%,#fff),var(--wall-b))!important;background:var(--wall-a)!important}
html.pearl #roomBack .rb-lrail{background:color-mix(in srgb,var(--wall-a) 86%,#fff)!important;filter:brightness(.95)}
html.pearl #roomBack .rb-lskirt{background:color-mix(in srgb,var(--wall-a) 82%,#fff)!important;filter:brightness(.93)}
html.teakroom:not(.wallpaper) #roomBack .rb-lrail{background:#a86a32!important}
/* soft shadow in the corners where the back wall meets the side walls, and along the floor under the skirting board: the room reads as a box */
#roomBack::before,#roomBack::after{content:'';position:absolute;top:0;height:var(--J);width:60px;pointer-events:none;display:none;z-index:0}
#roomBack.has-left::before{display:block;left:var(--cx);background:linear-gradient(90deg,rgba(0,0,0,.26),rgba(0,0,0,.08) 45%,transparent)}
#roomBack.has-right::after{display:block;left:calc(var(--rx) - 60px);background:linear-gradient(270deg,rgba(0,0,0,.26),rgba(0,0,0,.08) 45%,transparent)}
html.pearl #roomBack.has-left::before{background:linear-gradient(90deg,rgba(50,35,20,.16),rgba(50,35,20,.05) 45%,transparent)}
html.pearl #roomBack.has-right::after{background:linear-gradient(270deg,rgba(50,35,20,.16),rgba(50,35,20,.05) 45%,transparent)}
#roomBack .rb-floor{box-shadow:inset 0 16px 16px -10px rgba(0,0,0,.42)}
html.pearl #roomBack .rb-floor{box-shadow:inset 0 14px 14px -10px rgba(60,40,20,.3)}
/* moving the mouse (or tilting an Android phone) now shifts the floor in perspective: the boards near you move more than those by the wall */
html.rb-par #roomBack .rb-planks{translate:none;transform:perspective(520px) rotateX(64deg) translateX(calc(var(--px,0)*-26px))}
html.rb-par #roomBack::before{translate:calc(var(--px,0)*-5px) 0}
html.rb-par #roomBack::after{translate:calc(var(--px,0)*-5px) 0}
/* the Norwegian diamond rug: a cool white sparkle and a softer shadow (the rug is metal and stones) */
.rug.diamond img{filter:drop-shadow(0 4px 5px rgba(0,0,0,.45)) brightness(1.04)}
.rug.diamond.glitter::after{animation:rugsweep 3.6s ease-in-out infinite,rugtw .9s steps(2) infinite}
/* the tiny door for the small ones, right of the big door (roomfx.js): 1/10 of the door's height, on the floor */
.roomdoor img.minidoor{position:absolute;left:calc(100% + 10%);bottom:1.45%;height:10%!important;width:auto!important;pointer-events:none;filter:drop-shadow(0 1px 1.5px rgba(0,0,0,.55))!important}
/* the diamond rug lies a little further in under the tree (its middle under the trunk) */
.rug.diamond{top:83%}
/* 28 Nov evening: White birch and 70s teak have the new sideboard (brass ring pulls, tapered brass legs): the drawer tap areas follow its doors */
html[data-interior="birch"] .sideboard .dwL,html[data-interior="teak"] .sideboard .dwL{left:5.5%;width:26.5%;top:12%;height:44%}
html[data-interior="birch"] .sideboard .dwM,html[data-interior="teak"] .sideboard .dwM{left:33%;width:26%;top:13%;height:46%}
html[data-interior="birch"] .sideboard .boxbtn,html[data-interior="teak"] .sideboard .boxbtn{left:60%;width:26%;top:16%;height:47%}
html[data-interior="birch"] .sideboard.dL .dwL,html[data-interior="teak"] .sideboard.dL .dwL{left:-10%;width:44%;top:12%;height:62%}
html[data-interior="birch"] .sideboard.dM .dwM,html[data-interior="teak"] .sideboard.dM .dwM{left:12%;width:48%;top:14%;height:64%}
/* the bricks of the reading nook carried on up to the rail (room.js nookExt) */
.bookcase .nookext{position:absolute;display:none;pointer-events:none;background-repeat:no-repeat;z-index:0}
.bookcase .bcbtn{z-index:1}

/* ===== 28 Nov evening: "Sage and saffron wallpaper" – a DARK wallpaper (deep green with saffron flowers). The general wallpaper rules are for light
   wallpapers, so here the panelling, the page under the room, the floor's fade and the soft patch behind the title are dark green instead of cream. ===== */
html[data-paper="sage"] #roomBack{--wall-a:#2f5a40;--wall-b:#2a5139;--wall-c:#244832;--panel-line:rgba(0,0,0,.28);--panel-hi:rgba(220,235,200,.1);--dado-bg:linear-gradient(#2f5a40,#284d37)}
html[data-paper="sage"] #roomBack .rb-wall{background:linear-gradient(180deg,rgba(0,0,0,.25),rgba(0,0,0,0) 30%),var(--paper) 0 0/var(--paper-size) repeat,#0f2a1c}
html[data-paper="sage"] #roomBack .rb-panel{background-color:#2c5640}
html[data-paper="sage"] #roomBack .rb-lwall{background:var(--paper) 0 0/var(--paper-lsize) repeat,#0f2a1c}
html[data-paper="sage"] body{background:linear-gradient(180deg,rgba(12,36,24,0) calc(var(--roomEnd,900px) - 150px),#0c2418 var(--roomEnd,900px)),var(--paper) 0 0/300px repeat,#0c2418}
html[data-paper="sage"] #roomBack .rb-floor::after{background:linear-gradient(180deg,rgba(12,36,24,0) calc(100% - 150px),#0c2418 100%)}
html[data-paper="sage"] header::before{width:min(760px,96vw);height:150px;background:radial-gradient(ellipse at 50% 50%,rgba(6,20,13,.82) 0%,rgba(6,20,13,.55) 45%,rgba(6,20,13,0) 72%)}
html[data-paper="sage"] .item{background:rgba(8,26,17,.82);border-color:rgba(227,183,91,.4);box-shadow:0 2px 8px rgba(0,0,0,.3)}
html[data-paper="sage"] .item:hover{background:rgba(12,36,24,.92)}
html[data-paper="sage"] #roomBack .rb-skirt,html[data-paper="sage"] #roomBack .rb-rail{filter:brightness(1.15)}
/* the bricks behind the bookcase lie under the bookcase picture */
.bookcase .nookext2{z-index:0}
/* 28 Nov evening: the snow falls in front of everything in the room (tree, bookcase, sideboard), but behind the menus, the panels and the sheets */
#snow{z-index:26!important}
@media (max-width:820px){ #snow{z-index:21!important} }
/* the bricks above the bookcase: in the shade of the side wall, darker towards the window side of the room (left) */
.bookcase .nookext2{overflow:hidden}
.bookcase .nookext2 .nkshade{position:absolute;inset:0;background:linear-gradient(90deg,rgba(0,0,0,.42),rgba(0,0,0,.12) 85%,rgba(0,0,0,.05))}
/* eight Christmas cards: on phones the small pictures stay on one row */
@media (max-width:480px){ .xcard .cardpick{gap:4px} .xcard .cardpick button img{width:34px} }

/* ===== 28 Nov evening: "Oxblood floral wallpaper" – a dark wallpaper (deep red with orange and saffron flowers): deep red panelling, the page and floor fade in deep red ===== */
html[data-paper="oxblood"] #roomBack{--wall-a:#6a1a1f;--wall-b:#5e161b;--wall-c:#521216;--panel-line:rgba(0,0,0,.3);--panel-hi:rgba(255,210,190,.08);--dado-bg:linear-gradient(#6a1a1f,#561318)}
html[data-paper="oxblood"] #roomBack .rb-wall{background:linear-gradient(180deg,rgba(0,0,0,.25),rgba(0,0,0,0) 30%),var(--paper) 0 0/var(--paper-size) repeat,#4a0d12}
html[data-paper="oxblood"] #roomBack .rb-panel{background-color:#62171c}
html[data-paper="oxblood"] #roomBack .rb-lwall{background:var(--paper) 0 0/var(--paper-lsize) repeat,#4a0d12}
html[data-paper="oxblood"] body{background:linear-gradient(180deg,rgba(42,7,11,0) calc(var(--roomEnd,900px) - 150px),#2a070b var(--roomEnd,900px)),var(--paper) 0 0/300px repeat,#2a070b}
html[data-paper="oxblood"] #roomBack .rb-floor::after{background:linear-gradient(180deg,rgba(42,7,11,0) calc(100% - 150px),#2a070b 100%)}
html[data-paper="oxblood"] header::before{width:min(760px,96vw);height:150px;background:radial-gradient(ellipse at 50% 50%,rgba(30,4,7,.82) 0%,rgba(30,4,7,.55) 45%,rgba(30,4,7,0) 72%)}
html[data-paper="oxblood"] .item{background:rgba(34,6,9,.84);border-color:rgba(227,183,91,.4);box-shadow:0 2px 8px rgba(0,0,0,.3)}
html[data-paper="oxblood"] .item:hover{background:rgba(48,9,13,.92)}
html[data-paper="oxblood"] #roomBack .rb-skirt,html[data-paper="oxblood"] #roomBack .rb-rail{filter:brightness(1.15)}

/* ===== 29 Nov: drag the room to look around (depth.js) ===== */
@media (hover:hover) and (pointer:fine){ .room,#roomBack{cursor:grab} .room.roomdrag,.room.roomdrag *{cursor:grabbing!important} }
.roomtip{position:fixed;z-index:60;pointer-events:none;padding:7px 12px;border-radius:99px;background:rgba(10,16,30,.82);border:1px solid rgba(246,220,154,.45);
  color:#f6dc9a;font:700 11px Manrope,sans-serif;letter-spacing:.12em;text-transform:uppercase;white-space:nowrap;opacity:0;transform:translateY(4px);transition:opacity .25s,transform .25s}
.roomtip.on{opacity:1;transform:none}
.roomstraight{position:absolute;z-index:30;left:50%;top:14px;transform:translateX(-50%);padding:8px 14px;border-radius:99px;cursor:pointer;
  background:rgba(10,16,30,.72);border:1px solid rgba(246,220,154,.5);color:#f6dc9a;font:700 11px Manrope,sans-serif;letter-spacing:.12em;text-transform:uppercase;
  -webkit-backdrop-filter:blur(6px);backdrop-filter:blur(6px);box-shadow:0 4px 12px rgba(0,0,0,.3)}
.roomstraight:hover{background:rgba(20,28,48,.9)}
.roomstraight[hidden]{display:none}

/* ===== 29 Nov: room view – the padlock is in the side control panel; "Straighten" appears at the top of the room when it is turned ===== */
.viewctl{position:absolute;z-index:30;left:50%;top:14px;transform:translateX(-50%);display:flex;gap:6px;pointer-events:none}
.viewctl>button{pointer-events:auto}
.viewctl .roomstraight{position:static;transform:none}
.ctlbtn.roomlock{display:grid;place-items:center;color:#f6dc9a}
.ctlbtn.roomlock .shackle{transition:transform .25s;transform-origin:15.8px 10.5px}
.ctlbtn.roomlock:not(.on) .shackle{transform:translateY(-1.6px) rotate(28deg)}
.ctlbtn.roomlock.on{background:linear-gradient(180deg,#f0cf78,#b98a34);color:#2a1a08;border-color:#f6dc9a;box-shadow:0 0 0 3px rgba(246,220,154,.22),0 0 14px rgba(240,200,110,.45)}
.lockctl.on .lb{color:#f6dc9a}
@media (hover:hover) and (pointer:fine){ .room.roomlocked,.room.roomlocked #roomBack{cursor:default} }
@media (max-width:480px){ .side{gap:8px} }
@media (max-width:370px){ .side{gap:5px;padding-left:9px;padding-right:9px} }
/* 29 Nov: the "Wishes for you" cloud was pushed out of view on computers (its glitter rule made it position:relative, overriding the docking) */
@media (min-width:641px){ .sharebar.docked #wishSelf{position:fixed} }

/* 29 Nov: the "Back to day 1" button – short on phones */
.todaybtn .bk-s{display:none}
@media (max-width:640px){ .todaybtn .bk-l{display:none} .todaybtn .bk-s{display:inline} }
@media (max-width:380px){ .todaybtn{padding-left:8px!important;padding-right:8px!important;margin-left:2px!important} }

/* 30 Nov: the "Today" box is back (nav.js): a gold tag on today's page, an outlined "↩ Today" button on earlier days – mirrored with the Story button on the other side */
.daynav #todayBtn{left:calc(50% + 214px);right:auto;height:30px;padding:0 13px}
.daynav #todayBtn.istoday{cursor:default;pointer-events:none}
.daynav #todayBtn:not(.istoday){background:rgba(20,16,10,.35);color:var(--gold2,#f6dc9a);border:1px solid rgba(246,220,154,.7);box-shadow:none;letter-spacing:.08em}
@media (max-width:640px){ .daynav #todayBtn{left:calc(50% + 152px)} }
@media (max-width:480px){ .daynav #todayBtn{left:calc(50% + 114px);height:26px;padding:0 7px!important;font-size:9px;letter-spacing:.05em} .daynav #todayBtn .tdar{display:none} }
/* the lock on a calendar date sits small in the corner, clear of the date and the Today tab */
.calsheet .calcell .cpass{top:auto;bottom:4px;right:4px;width:10px;height:10px}
.calgrid .calwd{padding:6px 0 4px}

/* ===== 29 Nov: write the title and the name line directly on the share picture (sharetext.js) ===== */
.shtx{position:relative;display:inline-block;line-height:0;max-width:100%}
.shtx-w{position:absolute;display:block;border:1.5px dashed transparent;border-radius:10px;transition:border-color .2s,background .2s;cursor:text}
.shtx:hover .shtx-w{border-color:rgba(246,220,154,.35)}
.shtx-w.on{border-color:#f6dc9a!important;background:rgba(0,0,0,.22)}
.shtx-f{display:block;width:100%;height:100%;margin:0;padding:0 6px;border:0;background:none;outline:none;text-align:center;
  font-family:'Playfair Display',serif;font-style:italic;font-weight:800;color:transparent;caret-color:#f6dc9a;-webkit-text-fill-color:transparent;cursor:text}
.shtx.editing .shtx-w.t .shtx-f{color:#f0cf7c;-webkit-text-fill-color:#f0cf7c}
.shtx.editing .shtx-w.f .shtx-f{color:#fbf5e8;-webkit-text-fill-color:#fbf5e8}
.shtx-f::selection{background:rgba(246,220,154,.35)}
.shtx-pen{position:absolute;right:calc(-1 * var(--pad,14px));top:50%;transform:translate(50%,-50%);width:20px;height:20px;border-radius:50%;display:grid;place-items:center;
  font:normal 12px/1 Manrope,sans-serif;color:#2a1a08;background:linear-gradient(180deg,#f6dc9a,#d9a948);box-shadow:0 2px 6px rgba(0,0,0,.45);pointer-events:none;opacity:.85}
.shtx-w.on .shtx-pen{opacity:0}
/* the separate "Your name" field is no longer needed – the name line is written on the picture */
#shareName{display:none!important}

/* ===== 29 Nov: a little more depth (depthplus.js; config.js → room.depth.lean / glow) ===== */
/* lean: only while the look-around shift is active (html.rb-par = not the low quality level, not reduced motion) */
html.rb-par.rb-lean .hp .deco{transform-origin:50% 0;rotate:calc(var(--px,0) * 3deg)}                       /* ornaments hang from their hook */
html.rb-par.rb-lean #stage>.advent{transform-origin:0 0;rotate:calc(var(--px,0) * -2deg)}                     /* the candlestick tips on its foot (left/top = its foot) */
html.rb-par.rb-lean .fp.leanup .fitem{display:block;transform-origin:50% 100%;rotate:calc(var(--px,0) * -.5deg)}  /* the moose: only half a degree – its picture has its own window frame, which must stay in line with the room's window */
/* glow behind the Advent flames: a wide warm halo while a candle burns */
html.rb-glow #stage>.advent::before{content:'';position:absolute;z-index:-1;left:-30%;right:-30%;top:-60%;height:95%;pointer-events:none;opacity:0;
  background:radial-gradient(ellipse 50% 48% at 50% 55%,rgba(255,196,110,.34),rgba(255,160,70,.12) 55%,rgba(255,150,60,0) 75%);mix-blend-mode:screen;transition:opacity .8s}
html.rb-glow.q-mid #stage>.advent:not(.none)::before{opacity:.7}
html.rb-glow.q-hi #stage>.advent:not(.none)::before{opacity:1;animation:advHalo 2.6s ease-in-out infinite}
@keyframes advHalo{0%,100%{opacity:1}40%{opacity:.82}70%{opacity:.94}}
@media (prefers-reduced-motion:reduce){ html.rb-glow.q-hi #stage>.advent:not(.none)::before{animation:none} }
/* glow behind the tree lights (drawn by depthplus.js, half resolution) */
.lightglow{z-index:4;mix-blend-mode:screen;opacity:.8}
html.q-low .lightglow,html:not(.rb-glow) .lightglow{display:none}
/* iPhone: ask once to follow the phone's tilt */
.tiltask{display:inline-flex;align-items:center;gap:7px;pointer-events:auto;padding:7px 13px 7px 11px;border-radius:99px;cursor:pointer;
  background:rgba(10,16,30,.66);border:1px solid rgba(246,220,154,.45);color:#f6dc9a;font:700 10.5px Manrope,sans-serif;letter-spacing:.1em;text-transform:uppercase;
  -webkit-backdrop-filter:blur(6px);backdrop-filter:blur(6px);box-shadow:0 4px 12px rgba(0,0,0,.3);animation:tiltBlink 2.6s ease-in-out infinite}
@keyframes tiltBlink{50%{opacity:.6}}

/* ===== 29 Nov: the real spruce in 3D (spruce3d.js; config.js → room.spruce3d) ===== */
.spruce3d{position:absolute;z-index:3;display:none;pointer-events:none}   /* the same layer as the film tree: in front of the rug (2) */
.spruce3d img{position:absolute;inset:0;width:100%;height:100%;object-fit:fill;user-select:none;-webkit-user-drag:none}
html.sprucetree .spruce3d{display:block}
html.sprucetree #spin{visibility:hidden}
html.sprucetree .tiltrow{display:none}
/* the kind of tree, at the top of the Tree menu */
.treekind{display:flex;gap:4px;margin:2px 2px 10px;padding:3px;border-radius:99px;background:rgba(255,255,255,.06);border:1px solid rgba(246,220,154,.25)}
.treekind button{flex:1;padding:7px 10px;border:0;border-radius:99px;background:none;color:rgba(251,245,232,.75);font:700 11px/1.2 Manrope,sans-serif;letter-spacing:.04em;cursor:pointer;white-space:nowrap}
.treekind button[aria-pressed="true"]{background:linear-gradient(180deg,#f0cf78,#c9963a);color:#2a1a08}

/* ===== 29 Nov: Stripe Checkout button (stripepay.js) ===== */
.stripebtn{display:flex;align-items:center;justify-content:center;gap:9px;width:100%;min-height:46px;margin:4px 0 6px;padding:10px 16px;border-radius:23px;cursor:pointer;
  background:linear-gradient(180deg,#1d2a4a,#101a33);color:#fbf5e8;border:1px solid rgba(246,220,154,.55);font:700 14px/1.25 Manrope,sans-serif;letter-spacing:.01em;
  box-shadow:0 6px 16px rgba(0,0,0,.35);transition:transform .15s,box-shadow .15s,opacity .2s}
.stripebtn:hover{transform:translateY(-1px);box-shadow:0 9px 20px rgba(0,0,0,.42)}
.stripebtn svg{flex:none;color:#f6dc9a}
.stripebtn.busy{opacity:.6;cursor:progress}
.stripebtn[hidden]{display:none}
.payor{margin:6px 0 4px;text-align:center;font:600 11px Manrope,sans-serif;letter-spacing:.12em;text-transform:uppercase;color:rgba(251,245,232,.55)}
.payor[hidden]{display:none}

/* ===== 30 Nov: counting down to Christmas (countdown.js) ===== */
.daynav .lbl{font-size:23px;width:320px;min-width:0;max-width:none;text-align:center;line-height:1.12;text-wrap:balance}   /* a fixed width, so the arrows stay put from day to day */
.daynav .storybtn{right:calc(50% + 214px)}
@media (max-width:640px){ .daynav .lbl{font-size:19px;width:200px} .daynav .storybtn{right:calc(50% + 152px)} }
@media (max-width:480px){ .daynav .lbl{font-size:15.5px;width:126px} .daynav .storybtn{right:calc(50% + 120px)} }
.dsegq{grid-column:1/-1;margin:6px 0 2px;font:600 11px Manrope,sans-serif;letter-spacing:.14em;text-transform:uppercase;color:rgba(251,245,232,.7);text-align:center}
html.pearl .dsegq{color:#5a4a30}
/* the book: "From the beginning" next to the chapter arrows */
.bvnav .bvstart{width:auto;height:34px;padding:0 14px;border-radius:17px;font:700 10.5px Manrope,sans-serif;letter-spacing:.12em;text-transform:uppercase}
.bvnav .bvstart[hidden]{display:none}

/* ===== 30 Nov: a frame around the share picture (shareframe.js) ===== */
.shfr-btn{position:absolute;left:10px;bottom:10px;transform:none;height:30px;width:auto;padding:0 12px 0 8px;gap:6px;border-radius:99px;border:0;display:flex;align-items:center;cursor:pointer;z-index:3;font:700 11.5px/1 Manrope,sans-serif;letter-spacing:.04em;
  color:#2a1d14;background:linear-gradient(180deg,#f6dc9a,#e3b75b);box-shadow:0 2px 8px rgba(0,0,0,.4)}
.shfr-btn svg{width:17px;height:17px}
.shfr-btn:focus-visible{outline:2px solid #fff;outline-offset:2px}
.shfr-edge{position:absolute;inset:3.2%;border:2px dashed rgba(246,220,154,.0);border-radius:8px;pointer-events:none;transition:border-color .2s}
.shtx.shfr-hover .shfr-edge,.shtx.shfr-open .shfr-edge{border-color:rgba(246,220,154,.8)}
.shfr-pop{position:absolute;left:50%;bottom:10px;transform:translateX(-50%);z-index:4;width:min(92%,330px);padding:10px 10px 12px;border-radius:16px;line-height:normal;
  background:rgba(12,16,30,.93);border:1px solid rgba(246,220,154,.45);box-shadow:0 10px 30px rgba(0,0,0,.5);-webkit-backdrop-filter:blur(6px);backdrop-filter:blur(6px)}
.shfr-pop[hidden]{display:none}
.shfr-row{display:flex;flex-wrap:wrap;justify-content:center;gap:8px}
.shfr-row.st{margin-bottom:10px;align-items:center}
.shfr-st{width:44px;height:38px;border-radius:10px;border:1px solid rgba(246,220,154,.35);background:rgba(255,255,255,.05);color:#f6dc9a;display:grid;place-items:center;cursor:pointer}
.shfr-st svg{width:24px;height:24px}
.shfr-st.on{background:linear-gradient(180deg,#f6dc9a,#e3b75b);color:#2a1d14;border-color:transparent}
.shfr-done{margin-left:6px;width:38px;height:38px;border-radius:50%;border:1px solid rgba(246,220,154,.6);background:none;color:#f6dc9a;font:700 17px Manrope,sans-serif;cursor:pointer}
.shfr-c{width:28px;height:28px;border-radius:50%;border:2px solid rgba(255,255,255,.25);cursor:pointer;padding:0;position:relative;box-shadow:inset 0 -3px 6px rgba(0,0,0,.25)}
.shfr-c.on{border-color:#fff;box-shadow:0 0 0 2px #f6dc9a,0 0 10px rgba(246,220,154,.6)}
.shfr-c.dia::after{content:'✦';position:absolute;inset:0;display:grid;place-items:center;color:#fff;font-size:13px;text-shadow:0 0 6px #9cc4ff}
.shfr-row.cl.off .shfr-c{opacity:.55}
.shfr-st:focus-visible,.shfr-c:focus-visible,.shfr-done:focus-visible{outline:2px solid #fff;outline-offset:2px}
@media (max-width:480px){ .shfr-c{width:26px;height:26px} .shfr-row{gap:7px} }

/* 30 Nov: the "Wishes for you" cloud is 20 % bigger than the other cloud (size and text) */
.wishbtn.cloud#wishSelf{width:211px;height:106px}
#wishSelf .w1{font-size:23px} #wishSelf .w2{font-size:10px} #wishSelf .cnt{font-size:32px}
@media (max-width:480px){ .wishbtn.cloud#wishSelf{width:190px;height:95px} #wishSelf .w1{font-size:20px} #wishSelf .w2{font-size:9.5px} }
@media (min-width:641px){ .sharebar.docked .wishbtn.cloud#wishSelf{width:154px;height:77px} .sharebar.docked #wishSelf .w1{font-size:19px} .sharebar.docked #wishSelf .w2{font-size:9px} }

/* ===== 1 Dec: dusty pink woodland wallpaper – the walls go light pink too (panelling, side walls, rail) ===== */
html[data-paper="woodland"] #roomBack{--wall-a:#ecc6c1;--wall-b:#e6bdb8;--wall-c:#dfb3ae;--panel-line:rgba(150,80,80,.22);--panel-hi:rgba(255,245,243,.45);--dado-bg:linear-gradient(#efcdc8,#e6bfba)}
html[data-paper="woodland"] #roomBack .rb-wall{background:linear-gradient(180deg,rgba(120,60,60,.12),rgba(120,60,60,0) 30%),var(--paper) 0 0/var(--paper-size) repeat,#f3d5d1}
html[data-paper="woodland"] #roomBack .rb-panel{background-color:#ecc7c2}
html[data-paper="woodland"] #roomBack .rb-lwall{background:var(--paper) 0 0/var(--paper-lsize) repeat,#efcfca}
html[data-paper="woodland"] #roomBack .rb-rail,html[data-paper="woodland"] #roomBack .rb-lrail{background:linear-gradient(#f8e6e3,#d9a9a4)!important}
html[data-paper="woodland"] #roomBack .rb-skirt,html[data-paper="woodland"] #roomBack .rb-lskirt{background:linear-gradient(#f3dcd8,#cf9d98)!important}
html[data-paper="woodland"] body{background:linear-gradient(180deg,rgba(247,228,224,0) calc(var(--roomEnd,900px) - 150px),#f7e4e0 var(--roomEnd,900px)),var(--paper) 0 0/200px 326px repeat,#f7e4e0}
html[data-paper="woodland"] #roomBack .rb-floor::after{background:linear-gradient(180deg,rgba(247,228,224,0) calc(100% - 150px),#f7e4e0 100%)}
html[data-paper="woodland"] header::before{width:min(760px,96vw);height:150px;background:radial-gradient(ellipse at 50% 50%,rgba(250,236,233,.82) 0%,rgba(250,236,233,.5) 45%,rgba(250,236,233,0) 72%)}
html[data-paper="woodland"] .item{background:rgba(252,240,238,.9);border-color:rgba(176,100,96,.38)}
html[data-interior="green"] .bclamp img,html[data-interior="green"] .stlamp img{filter:sepia(.6) saturate(2.6) hue-rotate(60deg) brightness(.95) drop-shadow(0 3px 4px rgba(0,0,0,.6))}   /* 1 Dec: green velvet room – a green lantern */
html.q-low #roomBack[data-floor="pink"] .rb-planks{background:linear-gradient(#cf8ea5,#c57f98)}   /* 1 Dec: pink fluffy carpet on slow devices – plain pink */
html:not(.pearl) #roomBack[data-floor="pink"] .rb-planks{filter:brightness(.82)}   /* a touch softer in the dark rooms */
