:root{color-scheme:dark;--ink:#f3edda;--muted:#c3cbbb;--glass:rgba(12,30,29,.76);--line:rgba(232,237,209,.2);font-family:Arial,Helvetica,sans-serif;color:var(--ink);background:#152f31}*{box-sizing:border-box}body{margin:0;overflow:hidden}button,a,input{-webkit-tap-highlight-color:transparent}button,a{touch-action:manipulation}button{font:inherit;color:inherit;cursor:pointer}button:focus-visible,a:focus-visible,input:focus-visible{outline:3px solid #fff3aa;outline-offset:5px}button[hidden]{display:none!important}#space{position:relative;width:100%;height:100svh;height:100dvh;min-height:530px;overflow:hidden;isolation:isolate}#world,.vignette{position:absolute;inset:0;width:100%;height:100%}#world{touch-action:manipulation}.vignette{pointer-events:none;background:linear-gradient(180deg,rgba(7,22,27,.18),transparent 43%,transparent 72%,rgba(8,22,23,.86))}.top-hud{position:absolute;top:calc(21px + env(safe-area-inset-top));left:24px;right:22px;display:flex;justify-content:space-between;align-items:center}.identity{display:flex;flex-direction:column;gap:7px}.brand{font-family:Georgia,serif;font-size:19px;letter-spacing:.5px}#time-label{font-size:9px;text-transform:uppercase;letter-spacing:2.1px;color:var(--muted)}.icon-button{border:1px solid var(--line);background:var(--glass);width:42px;height:42px;border-radius:50%;display:grid;place-items:center;backdrop-filter:blur(10px);padding:11px}.icon-button svg,.themes svg{fill:none;stroke:currentColor;stroke-width:1.3;stroke-linejoin:round;stroke-linecap:round;width:22px;height:22px}.intro{position:absolute;top:17%;left:9%;right:9%;pointer-events:none;transition:opacity 1.5s,transform 2s}.eyebrow{font-size:9px;letter-spacing:2.6px;color:#e0dec0}.intro h1{font:400 clamp(41px,8.5vw,64px)/1.09 Georgia,'Times New Roman',serif;letter-spacing:-1.7px;margin:17px 0}.intro p{font-size:12px;letter-spacing:.3px;color:#d4d9c8;margin:0}.active .intro{opacity:0;transform:translateY(-12px)}.count-wrap{position:absolute;top:calc(86px + env(safe-area-inset-top));left:24px;display:flex;gap:8px;align-items:center;background:var(--glass);border:1px solid var(--line);border-radius:20px;padding:9px 12px;backdrop-filter:blur(10px);pointer-events:none}#count{font-size:10px;letter-spacing:.1px;white-space:nowrap;color:#f3efde}.count-dot{width:4px;height:4px;flex:none;background:#c7d5ae;border-radius:100%;order:-1}.bottom-hud{position:absolute;bottom:calc(17px + env(safe-area-inset-bottom));left:24px;right:24px}#hint{font-size:10px;text-align:center;line-height:1.5;color:#d0d7c8;text-shadow:0 1px 5px #102825;margin:0 0 13px}.actions{display:flex;align-items:center;justify-content:center;gap:10px;min-height:48px}.primary{border:1px solid #d8dcc2;border-radius:40px;padding:16px 25px;background:#e5e8ce;color:#263c35;font-size:12px;letter-spacing:.3px;box-shadow:0 5px 24px #061b1a30;min-height:48px}.primary span{padding-left:20px}.primary:hover{background:#f3f4e4}.text-button{border:0;background:transparent;font-size:10px;color:#e3e7d8;min-height:44px;padding:10px 6px}.soft-button{border:1px solid #b2c6b45c;border-radius:30px;font-size:11px;padding:14px 18px;background:var(--glass);backdrop-filter:blur(8px);min-height:46px}.footer-row{display:flex;align-items:center;justify-content:space-between;margin-top:22px}.themes{display:flex;gap:7px}.themes a{height:42px;min-width:43px;padding:0 11px;display:flex;gap:7px;align-items:center;justify-content:center;color:#d4dfce;text-decoration:none;border:1px solid transparent;border-radius:25px;background:#10272480}.themes a[aria-current]{background:#b5c8ae24;border-color:#d6e3c844}.themes span{display:none;font-size:10px}.themes a[aria-current] span{display:inline}.themes svg{width:20px;height:20px}#copy{width:38px;height:38px;padding:10px}#copy svg{width:18px;height:18px}#you{position:absolute;left:50%;top:76%;transform:translateX(-50%);display:flex;align-items:center;gap:6px;opacity:0;transition:opacity 1s;white-space:nowrap;color:#f4f0cf;font-size:10px;text-shadow:0 1px 4px #000}#you small{font-size:8px;text-transform:uppercase;letter-spacing:1px;opacity:.65}#you .you-dot{width:4px;height:4px;border-radius:50%;background:#fff4b6}.active #you{opacity:1}.active .primary#primary{display:none}dialog{color:var(--ink);background:#1b3431f7;border:1px solid #b6c4a34a;border-radius:3px;width:min(348px,calc(100vw - 36px));padding:35px 25px 23px;text-align:center;box-shadow:0 20px 100px #051c24a0;max-height:calc(100dvh - 36px)}dialog::backdrop{background:#0b202b80;backdrop-filter:blur(8px)}dialog h2{font:400 36px/1.12 Georgia,serif;letter-spacing:-.8px;margin:19px 0 25px}.end-emblem{font-size:40px;color:#d8d3a2;margin-bottom:21px}#duration{font-family:Georgia,serif;font-size:20px;line-height:1.5;margin:0 0 7px}#companions-summary{font-size:11px;color:#d4ddcb;line-height:1.65;margin:0}.end-rule{width:32px;height:1px;background:#b9c5a450;margin:24px auto}.end-note{font-size:11px;color:#bdcbb8;margin:0 0 25px}dialog .primary{width:100%;font-size:11px}#end-copy{display:block;margin:9px auto}.local-note{font-size:9px;line-height:1.7;color:#9eb19f;margin:18px 0 0}#copy-dialog{z-index:10}#copy-dialog h2{font-size:27px}#copy-dialog p{font-size:12px}#copy-value{width:100%;background:#0e2524;color:#eee;border:1px solid #b7c7b35c;padding:12px;font-size:12px;margin:12px 0 25px}.sr-only{position:absolute;width:1px;height:1px;overflow:hidden;clip-path:inset(50%);white-space:nowrap}body[data-theme=desk]{--glass:rgba(39,30,28,.83);--muted:#d4c2a3}body[data-theme=desk] .vignette{background:linear-gradient(180deg,#18172133,transparent 50%,transparent 70%,#211c19ed)}body[data-theme=lantern]{--glass:rgba(30,32,51,.83);--muted:#d7c3b3}body[data-theme=lantern] .vignette{background:linear-gradient(180deg,#191d3333,transparent 52%,transparent 70%,#181d31ed)}@media(min-width:650px){.top-hud{left:40px;right:40px;top:30px}.count-wrap{left:40px;top:95px}.intro{top:23%;left:10%}.intro h1{font-size:64px}.bottom-hud{left:40px;right:40px;bottom:24px}.actions{gap:24px}.footer-row{margin-top:15px}.themes{gap:12px}.themes span{display:inline}.themes a{padding:0 16px}.count-wrap #count{font-size:11px}#you{top:76%}}@media(max-height:680px){.intro{top:23%}.intro h1{font-size:37px;margin:12px 0}.intro .eyebrow{font-size:8px}.intro p{font-size:11px}.footer-row{margin-top:10px}.bottom-hud{bottom:12px}#hint{margin-bottom:7px;font-size:9px}.primary{padding:13px 22px}.end-emblem{margin-bottom:10px}dialog{padding:22px}dialog h2{font-size:30px;margin:14px 0 20px}.end-rule{margin:16px auto}}@media(prefers-reduced-motion:reduce){*,*::before,*::after{scroll-behavior:auto!important;transition:none!important;animation:none!important}}
.dialog-count{font-size:10px;line-height:1.4;color:#f3efde;margin:0 auto 20px;padding:7px 9px;border:1px solid #b6c4a34a;border-radius:20px;width:fit-content;background:#10272490}
@media(max-height:680px) and (orientation:portrait){.intro{top:21%}.intro h1{font-size:32px;line-height:1.08}.intro p{display:none}}
body[data-theme=garden][data-phase=day] .intro{color:#243e37}body[data-theme=garden][data-phase=day] .intro .eyebrow,body[data-theme=garden][data-phase=day] .intro p{color:#2e4c42}.brand,#time-label{text-shadow:0 1px 7px #102b2b80}

/* 3.0.2: a quiet title sky, even in the dense lantern demo. */
body[data-theme=lantern] .vignette{background:radial-gradient(ellipse at 27% 26%,#151e455c,transparent 47%),linear-gradient(180deg,#111a3020,transparent 52%,transparent 70%,#181d31ed)}
#gentle-name{text-shadow:0 0 9px #fff0b6a0,0 1px 5px #102826}
/* Keep the existing garden/library top count in its exact place above the end dialog. */
.count-wrap.hud-in-modal{position:fixed;right:auto;bottom:auto;margin:0;color:var(--ink);overflow:visible}
.persistent-count #end-count{visibility:hidden}

/* 3.0.3: theme-coordinated end cards; scene remains visible through the blur. */
body[data-theme=desk] #end-card{background:#30241fed;border-color:#d0ad745c;box-shadow:0 20px 100px #140f14a0}
body[data-theme=desk] #end-card .dialog-count{background:#251c1980}
body[data-theme=lantern] #end-card{background:#162440ed;border-color:#94a9d45c;box-shadow:0 20px 100px #060e27a0}
body[data-theme=lantern] #end-card .dialog-count{background:#101b3480}
body[data-theme=garden] #end-card{background:#1b3431ed}
#end-card::backdrop{background:#09151e40;backdrop-filter:blur(8px)}

/* End-card links stay in the dialog flow, below the local/demo note. */
.end-links{font-size:10px;line-height:1.7;margin:14px 0 0}
.end-links a{display:inline-block;color:var(--muted);padding:10px 6px;min-height:36px;text-underline-offset:3px}
body.contact-page{overflow:auto}
.contact-content{max-width:600px;margin:0 auto;padding:clamp(36px,10vh,90px) 28px 40px}
.contact-content h1{font:400 44px/1.1 Georgia,serif;letter-spacing:-1px;margin:36px 0 24px}
.contact-content h2{font:400 22px/1.3 Georgia,serif;margin:32px 0 12px}
.contact-content p,.contact-content li{font-size:14px;line-height:1.8;color:var(--muted)}
.contact-content ul{padding-left:20px}
.contact-content .contact-address{color:var(--ink);overflow-wrap:anywhere}
.contact-content nav{display:flex;flex-wrap:wrap;gap:20px;margin-top:36px;padding-top:24px;border-top:1px solid var(--line)}
.contact-content a{color:var(--ink);font-size:13px;text-underline-offset:4px}

[hidden]{display:none!important}
/* Temple keeps the artwork full bleed and gives each physical object a matching control. */
body[data-theme=temple]{--glass:#12192ce0;--muted:#f4d8ae;--line:#f6d6a948}
body[data-theme=temple] .vignette{background:linear-gradient(180deg,#11172d61 0%,#11172d6b 16%,transparent 35%,transparent 76%,#1b1529ed 91%,#171325)}
body[data-theme=temple] .top-hud{top:calc(17px + env(safe-area-inset-top));left:20px;right:19px}
.temple-sound{display:flex;align-items:center;gap:8px}
.temple-sound span{font-size:10px;line-height:1.28;text-align:right;color:#fff0d8;text-shadow:0 1px 6px #151b33}
body[data-theme=temple] .count-wrap{top:calc(68px + env(safe-area-inset-top));left:20px;padding:8px 10px}
body[data-theme=temple] .count-dot{background:#f3bc70}
body[data-theme=temple] .intro{left:8%;right:auto;top:13%;isolation:isolate;color:#fff5df;text-shadow:0 2px 12px #0d142bcf}
body[data-theme=temple] .intro::before{content:'';position:absolute;inset:-36px -70px -36px -56px;z-index:-1;background:radial-gradient(ellipse 50% 50% at center,#12172ce0 8%,#12172cb8 52%,#15192e66 76%,transparent 100%)}
body[data-theme=temple] .intro h1{margin:8px 0 9px;font-size:clamp(33px,10vw,67px);letter-spacing:-.042em;line-height:.99}
body[data-theme=temple] .intro p{display:block;color:#fff3df;font-size:12px;font-weight:500}
body[data-theme=temple] #you{transform:translate(-50%,-100%);background:#202031d9;border-radius:12px;padding:3px 6px;pointer-events:none}
#wheel-drag,#mala-touch{position:absolute;touch-action:none}
#wheel-drag{cursor:grab}
#wheel-drag:active{cursor:grabbing}
#mala-touch{cursor:pointer}
body[data-theme=temple] .bottom-hud{bottom:calc(9px + env(safe-area-inset-bottom));left:16px;right:16px;pointer-events:none}
body[data-theme=temple] .bottom-hud :is(button,a,input,label){pointer-events:auto}
body[data-theme=temple] .actions{position:fixed;top:30%;left:8%;justify-content:flex-start;min-height:0}
body[data-theme=temple] .primary{background:#f4ddb0;color:#312232;border-color:#ffeccc;font-weight:600}
body[data-theme=temple] .actions .primary{padding:10px 15px;min-height:42px}
body[data-theme=temple] .actions .primary span{padding-left:10px}
body[data-theme=temple].active .actions{top:calc(61px + env(safe-area-inset-top));left:auto;right:19px}
body[data-theme=temple] #leave{background:#16192bd4;border:1px solid var(--line);border-radius:24px;padding:9px 11px;min-height:40px}
body[data-theme=temple] #hint{margin:1px 0 4px;font-size:10px;color:#ffdeb8}
.temple-tools{display:flex;justify-content:space-between;margin:0 3px}
.temple-tools>div{display:grid;justify-items:center;gap:3px}
.temple-tools span{font-size:10px;font-variant-numeric:tabular-nums;color:#ffecd0;text-shadow:0 1px 4px #2b1e26}
.temple-tools .soft-button{min-height:42px;padding:8px 13px;border-color:#edbd7a78;color:#fff1d8;background:#2d2133eb}
.temple-footer-actions{display:flex;align-items:center;gap:6px}
.temple-settings{position:relative;z-index:3;color:#ffebcf}
.temple-settings summary{width:38px;height:38px;padding:9px;list-style:none;pointer-events:auto;cursor:pointer}
.temple-settings summary::-webkit-details-marker{display:none}
.temple-settings summary:focus-visible{outline:3px solid #fff3aa;outline-offset:3px}
.temple-settings[open] summary{border-color:#f5c68791;background:#48334b}
.temple-settings summary svg{width:19px;height:19px}
.temple-settings-panel{position:absolute;bottom:calc(100% + 8px);right:0;min-width:176px;pointer-events:auto;padding:5px 10px;background:#231b31f5;border:1px solid #d9a36b80;border-radius:12px;box-shadow:0 6px 24px #100e23a0}
.temple-settings label{display:flex;align-items:center;gap:8px;min-height:42px;white-space:nowrap;font-size:12px;cursor:pointer}
.temple-settings input{margin:0;accent-color:#f4c983;width:15px;height:15px}
#bead-message{position:absolute;top:6px;left:50%;transform:translateX(-50%);font-size:10px;color:#ffecd0;white-space:nowrap;text-align:center}
#bead-message:not(:empty){padding:5px 7px;border-radius:12px;background:#231b31d9}
body[data-theme=temple] .footer-row{margin-top:2px}
body[data-theme=temple] .themes a{background:#2c233eaf;color:#fae8cc}
body[data-theme=temple] .themes a[aria-current]{background:#df9e5330;border-color:#f5c68791}
body[data-theme=temple] #end-card{background:#261e34f5;border-color:#d0a8807d}
#temple-summary{font-size:12px;color:#f4d4aa;line-height:1.55;margin:0 0 8px}
body.film #space > :not(#world){display:none!important}
body.film #space{height:100vh;min-height:0}
@media(min-width:650px){
 body[data-theme=temple] .top-hud{left:36px;right:36px}
 body[data-theme=temple] .count-wrap{left:36px}
 body[data-theme=temple].active .actions{right:36px}
 body[data-theme=temple] .intro,body[data-theme=temple] .actions{left:max(8%,calc(50% - 370px))}
 body[data-theme=temple] .bottom-hud{left:max(24px,calc(50% - 380px));right:max(24px,calc(50% - 380px))}
}
@media(max-height:680px){
 body[data-theme=temple] .intro{top:17%}
 body[data-theme=temple] .intro h1{font-size:32px}
 body[data-theme=temple] .actions{top:35%}
}
.today{position:absolute;z-index:2;top:calc(86px + env(safe-area-inset-top));right:22px;color:#fff1dd;font-size:10px}
.today summary{display:flex;gap:6px;align-items:center;list-style:none;cursor:pointer;padding:8px 10px;background:var(--glass);border:1px solid var(--line);border-radius:20px;font-variant-numeric:tabular-nums}
.today summary::-webkit-details-marker{display:none}
.today summary::after{content:'⌄';font-size:12px;line-height:1}
.today[open] summary::after{content:'⌃'}
.today summary:focus-visible{outline:3px solid #fff3aa;outline-offset:3px}
.today-panel{position:absolute;right:0;min-width:205px;padding:10px;background:#171c2deF;border:1px solid #f5d9af54;border-radius:10px;margin-top:4px;box-shadow:0 5px 24px #12152a60}
.today-panel :is(p,ul){margin:0;line-height:1.65;list-style:none;padding:0}
.today-panel li+li{margin-top:4px}
body[data-theme=temple] .today{left:20px;right:auto;top:calc(104px + env(safe-area-inset-top))}
body[data-theme=temple] .today-panel{left:0;right:auto}
body[data-theme=temple] .intro{top:16.5%}
body[data-theme=temple] .actions{top:32.5%}
.scene-next{display:table;margin:5px auto;color:#fff0c9;font-size:11px;font-weight:600;text-align:center;text-decoration:none;background:#252037eb;padding:9px 12px;border:1px solid #f4c88780;border-radius:20px}
.scene-next:hover{text-decoration:underline;text-underline-offset:3px}
body[data-theme=temple] #scene-next{position:absolute;bottom:100%;left:50%;width:max-content;max-width:100%;transform:translateX(-50%);margin-bottom:4px}
#today-end{font-size:11px;color:#ead4b4;margin:10px 0 0}
#end-next{margin:0 auto 10px}
#end-card .end-rule{margin:16px auto}
#end-card .end-note{margin-bottom:12px}
@media(min-width:650px){
 .today{top:95px;right:40px}
 body[data-theme=temple] .today{left:36px}
}
@media(max-height:680px){body[data-theme=temple] .intro{top:22%}body[data-theme=temple] .actions{top:38%}}
.temple-sound span{max-width:118px}

/* The original Lantern composer tracks the visible mobile keyboard viewport. */
.wish-tools{position:absolute;top:calc(128px + env(safe-area-inset-top));left:24px;right:24px;display:flex;align-items:center;gap:6px 12px;flex-wrap:wrap;max-width:410px}
.wish-tools button{min-width:44px;min-height:44px;padding:10px 8px;text-decoration:underline;text-underline-offset:3px}
#local-wish{font-size:10px;line-height:1.5;color:#e2d7c8;overflow-wrap:anywhere;margin:18px 0;text-align:left}
#local-wish summary{cursor:pointer;padding:12px 0;min-height:44px}
#local-wish-text{font:13px/1.5 Arial,Helvetica,sans-serif;display:block;padding:4px 0;white-space:pre-wrap}
.wish-bar{position:fixed;z-index:5;left:max(10px,env(safe-area-inset-left));right:max(10px,env(safe-area-inset-right));top:calc(var(--wish-vv-bottom,100dvh) - 10px - env(safe-area-inset-bottom));transform:translateY(-100%);max-width:550px;margin:0 auto;padding:12px 14px 9px;border:1px solid #c8c5a66b;border-radius:12px;background:#16233bf5;box-shadow:0 6px 30px #07101b80;max-height:calc(var(--wish-vv-height,100dvh) - 20px);overflow:auto}
.wish-bar label{display:block;font-size:11px;margin-bottom:7px;color:#ede5ce}
#wish-input{display:block;width:100%;min-width:0;font:16px/1.5 Arial,Helvetica,sans-serif;color:var(--ink);padding:10px 8px;border:1px solid #b7c7b35c;border-radius:5px;background:#101c31}
#wish-input::placeholder{font-size:12px;color:#c9cbbf;opacity:1}
.wish-bar-actions{display:flex;align-items:center;justify-content:flex-end;gap:10px;margin-top:5px}
#wish-limit{font-size:10px;line-height:1.3;margin-right:auto;max-width:145px}
.wish-bar .primary{font-size:11px;padding:11px 20px;min-height:44px}
#wish-skip{min-height:44px;font-size:10px}
#wish-retention{font-size:10px;line-height:1.4;color:#cbd1c3;margin:5px 0 0}
body.wish-composing :is(.actions,#scene-next){visibility:hidden}
@media(min-width:650px){.wish-tools{left:40px;right:40px;top:138px}}
@media(max-height:530px){
 body[data-theme=lantern] #space{min-height:0}
 body[data-theme=lantern] .intro{top:36%;left:7%}
 body[data-theme=lantern] .intro h1{font-size:30px}
 body[data-theme=lantern] .intro :is(.eyebrow,p){display:none}
 body[data-theme=lantern] .wish-tools{top:112px;left:16px;right:16px}
 body[data-theme=lantern] .top-hud{top:18px}
 body[data-theme=lantern] .count-wrap,body[data-theme=lantern] .today{top:76px}
 body[data-theme=lantern] #end-card{overflow:auto;width:min(480px,calc(100vw - 28px));padding:14px 20px;max-height:calc(100dvh - 24px)}
 body[data-theme=lantern] #end-card :is(.end-emblem,.end-rule,.end-note){display:none}
 body[data-theme=lantern] #end-count{margin:0 auto 8px;padding:4px 8px}
 body[data-theme=lantern] #end-title{font-size:25px;margin:8px 0}
 body[data-theme=lantern] #duration{font-size:15px;margin:0 0 5px}
 body[data-theme=lantern] #companions-summary{font-size:11px;line-height:1.5}
 body[data-theme=lantern] #again{margin-top:12px;padding:10px;min-height:44px}
 body[data-theme=lantern] #end-copy{margin:0 auto;min-height:36px}
 body[data-theme=lantern] #end-card .local-note{margin:5px 0 0;font-size:8px;line-height:1.4}
 .wish-bar{padding:9px 12px 7px}
}

/* Three quiet actions sit between the existing instrument controls. */
.temple-tools{display:grid;grid-template-columns:1fr auto 1fr;align-items:end}
.temple-tools>div:first-child{justify-self:start}
.temple-tools>div:last-child{justify-self:end}
#offer{display:flex;align-items:center;gap:5px;align-self:end;padding:7px 10px;color:#f4cd91;background:#332731db}
#offer svg{width:16px;height:16px;fill:none;stroke:#e4b774;stroke-width:1.2;stroke-linecap:round;stroke-linejoin:round}
#bead-message{top:-1px}
#offer-dialog{padding:20px 24px 14px;background:#251d31f5;border-color:#e0b67774}
#offer-title{margin:3px 0 16px;font-size:29px}
.offering-actions{display:grid;gap:8px}
.offering-actions .soft-button{color:#ffe6b3;border-color:#dcb87b68}
#offer-close{margin-top:9px}
#offering-summary{font-size:11px;line-height:1.5;color:#efc890;margin:7px 0}
#offering-summary:empty{display:none}
.mountain-gold{position:absolute;z-index:1;top:calc(105px + env(safe-area-inset-top));right:19px;margin:0;padding:7px 10px;background:#2e2236ed;border:1px solid #efba7578;border-radius:20px;font-size:10px;letter-spacing:.1px;color:#ffe7a5;pointer-events:none}

@font-face{font-family:Tibetan;src:url('../assets/qt-tibetan.woff') format('woff');font-display:swap}
.identity .brand,.contact-content .brand{font-family:Georgia,serif;color:#D9A441;text-shadow:0 2px 6px #8E1F2B}
.wordmark-bo{display:block;font:500 10px/1.15 TashiTibetan,Tibetan,serif;letter-spacing:.025em;color:#D9A441}

@font-face{font-family:TashiTibetan;src:url('../assets/cards/auspicious-tibetan.woff2') format('woff2');font-display:swap}
