/* Nocture Console · theme.css: the art-direction layer, "Hà Nội về đêm".
   Loaded after console.css / pages.css / landing.css (and the other page styles) on every page; changes no copy.
   Owns: the scene palette (--sc-*, read by the SVG classes of scenes.js), the home hero art (game wall from gamewall.js,
   or the illustrated apartment from scenes.js), the night-skyline band on content pages, the 404 bridge, the booking
   hand-over, empty / error spots, the footer skyline and the long-form .doc pages.
   Palette: deep indigo night, warm amber lamp and sodium street light, Hà Nội green shutters, terracotta sofa;
   brand lime only for the moon, LEDs and one cushion. The light theme is dawn over the Red River, not a washed-out night. */

/* ------------------------------------------------------------------ scene palette: dawn (light) */
:root {
  --sc-sky0: #a9b6e6; --sc-sky1: #d6d3ee; --sc-sky2: #f6d8c6; --sc-sky3: #ffcaa4;
  --sc-star: rgba(255,255,255,0); --sc-moon: #e2f49a; --sc-halo: rgba(255,255,255,.55); --sc-crater: rgba(60,80,10,.08);
  --sc-far: #a3aacd; --sc-fwin: rgba(255,186,110,.6); --sc-red: #e0574c;
  --sc-riv0: #ead8df; --sc-riv1: #bfc6e4; --sc-refl: rgba(255,168,110,.55); --sc-mrefl: rgba(255,255,255,.75);
  --sc-bridge: #4a5277; --sc-bridge2: #8a92b6; --sc-chord-hi: rgba(255,255,255,.35); --sc-pier: #6a7196;
  --sc-train: #3e4569; --sc-twin: #ffd27a; --sc-twin2: #fff1c9; --sc-head: #fff6d6; --sc-beam: rgba(255,240,190,.4); --sc-moto: #fff3c8; --sc-lampdot: #ffd27a;
  --sc-roof1: #a7accb; --sc-roof2: #7c82a6; --sc-rim: #9ea4c4; --sc-tank1: #c7cbe0; --sc-tank: #e3e6f1; --sc-ant: rgba(70,78,110,.6);
  --sc-tree: #6f8f7c; --sc-win: #ffc46e; --sc-win2: #ffe0a6; --sc-win3: #bccaff; --sc-glow: rgba(255,170,120,.4);
  --sc-wall: #ebe2cf; --sc-lamp: rgba(255,196,120,.5); --sc-base: #d6c8ad; --sc-frame: #f8f4ea; --sc-frame-hi: #ffffff; --sc-frame-lo: #d9cfbb;
  --sc-reveal: #e1d6c0; --sc-reveal2: #d8ccb4; --sc-shut: #4d8a6b; --sc-shut-lo: #3d7158; --sc-shut-hi: #6aa486; --sc-leaf: #efe8da; --sc-glass: rgba(190,205,240,.45);
  --sc-floor: #d7c7aa; --sc-board: rgba(110,80,40,.14); --sc-winlight: rgba(255,214,160,.28); --sc-rug: #8c4f3e; --sc-rug-b: rgba(255,226,190,.35);
  --sc-wood: #9a6a47; --sc-wood-lo: #7c5236; --sc-wood-hi: #c99468; --sc-seam: rgba(60,30,10,.25); --sc-line: rgba(60,40,20,.18);
  --sc-tv: #191b25; --sc-tv-rim: rgba(255,255,255,.12); --sc-glare: rgba(255,255,255,.06);
  --sc-tv1: rgba(255,120,80,.16); --sc-tv2: rgba(70,200,120,.14); --sc-tv3: rgba(70,160,255,.15); --sc-tv4: rgba(130,90,230,.13);
  --sc-sofa: #b5664b; --sc-sofa-lo: #9c533b; --sc-sofa-hi: #f0b08a; --sc-seam2: rgba(70,25,10,.25); --sc-throw: #d8a640; --sc-throw-line: rgba(110,70,10,.3); --sc-cushion: #c6f135;
  --sc-metal: #5a5e72; --sc-metal2: #6c7086; --sc-lampshade: #fff0c8; --sc-lampin: #ffd27a;
  --sc-bowl: #f6f7fb; --sc-bowlline: #3b5cc9; --sc-broth: #d49547; --sc-noodle: #fbf0d8; --sc-herb: #4f9a3f; --sc-beef: #9b4a3a; --sc-chop: #b07a45;
  --sc-glassb: rgba(255,255,255,.55); --sc-tea: #c06e22; --sc-ice: rgba(255,255,255,.8); --sc-rib: rgba(255,255,255,.55); --sc-steam: rgba(255,255,255,.75);
  --sc-pot: #b8613f; --sc-pot2: #c8714f; --sc-leaf1: #3f7a55; --sc-leaf2: #4f8d64; --sc-vein: rgba(255,255,255,.25);
  --sc-paper: #fbf8f0; --sc-red2: #d4423a; --sc-pline: rgba(0,0,0,.18); --sc-case1: #3b5cc9; --sc-case2: #c6f135; --sc-case3: #e0574c;
  --sc-shade: rgba(70,45,20,.18); --sc-led: #8fd11a;
  --sc-skin: #e0a47a; --sc-hair: #2a2230; --sc-shirt: #2b3472; --sc-shirt2: #d9926b; --sc-collar: #c6f135; --sc-pants: #262938; --sc-shoe: #191b24;
  --sc-cap: #2b3472; --sc-capbrim: #c6f135; --sc-bag: #1f2335; --sc-bagline: #c6f135;
  --sc-door: #8a5a3e; --sc-doorin: #ffe4b8; --sc-doorspill: rgba(255,214,150,.45); --sc-doorglow: rgba(255,214,150,.55); --sc-mat: #a86a4a;
  --sc-walk: #6a7196; --sc-rail: #4a5277; --sc-cable: #3a3f52; --sc-plug: #c6f135;
}
/* ------------------------------------------------------------------ scene palette: night (dark) */
:root[data-theme="dark"], :root:not([data-theme="light"]) {
  --sc-sky0: #060920; --sc-sky1: #101848; --sc-sky2: #2a2a62; --sc-sky3: #5a3a5e;
  --sc-star: #e6eaff; --sc-moon: #c6f135; --sc-halo: rgba(198,241,53,.16); --sc-crater: rgba(13,18,3,.09);
  --sc-far: #1b2553; --sc-fwin: rgba(255,196,120,.55); --sc-red: #ff5a4f;
  --sc-riv0: #1c2252; --sc-riv1: #090d2a; --sc-refl: rgba(255,178,96,.5); --sc-mrefl: rgba(198,241,53,.45);
  --sc-bridge: #04061a; --sc-bridge2: #131a44; --sc-chord-hi: rgba(140,160,255,.22); --sc-pier: #080b22;
  --sc-train: #0b0f26; --sc-twin: #ffcf74; --sc-twin2: #fff0c0; --sc-head: #fff6d6; --sc-beam: rgba(255,230,170,.22); --sc-moto: #ffe9a8; --sc-lampdot: #ffc860;
  --sc-roof1: #141b48; --sc-roof2: #0a0e2e; --sc-rim: #1d2558; --sc-tank1: #232c62; --sc-tank: #343d78; --sc-ant: rgba(140,155,230,.35);
  --sc-tree: #080c26; --sc-win: #ffb952; --sc-win2: #ffdc96; --sc-win3: #7e94ff; --sc-glow: rgba(255,132,44,.45);
  --sc-wall: #161b3d; --sc-lamp: rgba(255,170,84,.34); --sc-base: #0e1230; --sc-frame: #232a58; --sc-frame-hi: #333c78; --sc-frame-lo: #0f1332;
  --sc-reveal: #1c2250; --sc-reveal2: #131840; --sc-shut: #1b4744; --sc-shut-lo: #112f2e; --sc-shut-hi: #2a625c; --sc-leaf: #262d5c; --sc-glass: rgba(140,160,255,.12);
  --sc-floor: #0f1231; --sc-board: rgba(150,165,255,.05); --sc-winlight: rgba(255,150,70,.07); --sc-rug: #2a1f48; --sc-rug-b: rgba(255,190,120,.12);
  --sc-wood: #3b2627; --sc-wood-lo: #291a1c; --sc-wood-hi: #74462f; --sc-seam: rgba(0,0,0,.35); --sc-line: rgba(226,232,255,.08);
  --sc-tv: #04050b; --sc-tv-rim: rgba(226,232,255,.12); --sc-glare: rgba(255,255,255,.05);
  --sc-tv1: rgba(255,96,70,.24); --sc-tv2: rgba(70,220,130,.2); --sc-tv3: rgba(70,170,255,.24); --sc-tv4: rgba(140,90,255,.22);
  --sc-sofa: #43242a; --sc-sofa-lo: #331b20; --sc-sofa-hi: #c7703f; --sc-seam2: rgba(0,0,0,.3); --sc-throw: #a87a26; --sc-throw-line: rgba(0,0,0,.25); --sc-cushion: #a7cf2a;
  --sc-metal: #272d52; --sc-metal2: #313866; --sc-lampshade: #ffd892; --sc-lampin: #ffb456;
  --sc-bowl: #dde1ec; --sc-bowlline: #3352b8; --sc-broth: #b9782e; --sc-noodle: #efe0bd; --sc-herb: #3f8a35; --sc-beef: #7d3a2e; --sc-chop: #8a5a32;
  --sc-glassb: rgba(200,215,255,.22); --sc-tea: #a95c18; --sc-ice: rgba(230,240,255,.7); --sc-rib: rgba(230,240,255,.35); --sc-steam: rgba(230,236,255,.5);
  --sc-pot: #6a3424; --sc-pot2: #7a3f2c; --sc-leaf1: #17392f; --sc-leaf2: #1f4a3b; --sc-vein: rgba(255,255,255,.08);
  --sc-paper: #ddd6c4; --sc-red2: #c43a33; --sc-pline: rgba(0,0,0,.25); --sc-case1: #2f4cb0; --sc-case2: #8db51f; --sc-case3: #b8473d;
  --sc-shade: rgba(0,0,0,.42); --sc-led: #c6f135;
  --sc-skin: #c98d64; --sc-hair: #0f0d16; --sc-shirt: #2d3680; --sc-shirt2: #9a5a46; --sc-collar: #c6f135; --sc-pants: #141724; --sc-shoe: #08090f;
  --sc-cap: #2d3680; --sc-capbrim: #c6f135; --sc-bag: #0d1020; --sc-bagline: #c6f135;
  --sc-door: #4a2f26; --sc-doorin: #ffcf86; --sc-doorspill: rgba(255,180,90,.2); --sc-doorglow: rgba(255,180,90,.42); --sc-mat: #5a3326;
  --sc-walk: #10153a; --sc-rail: #060920; --sc-cable: #b9bfd0; --sc-plug: #c6f135;
}

/* ------------------------------------------------------------------ scene classes (scenes.js) */
.sc { display: block; overflow: hidden; }
.sc .g-sky0 { stop-color: var(--sc-sky0); } .sc .g-sky1 { stop-color: var(--sc-sky1); } .sc .g-sky2 { stop-color: var(--sc-sky2); } .sc .g-sky3 { stop-color: var(--sc-sky3); }
.sc .g-riv0 { stop-color: var(--sc-riv0); } .sc .g-riv1 { stop-color: var(--sc-riv1); } .sc .g-glow { stop-color: var(--sc-glow); }
.sc .g-lamp { stop-color: var(--sc-lamp); } .sc .g-halo { stop-color: var(--sc-halo); } .sc .g-rim { stop-color: var(--sc-sofa-hi); } .sc .g-bg { stop-color: var(--bg); } .sc .g-door { stop-color: var(--sc-doorglow); }
.sc .g-tv1 { stop-color: var(--sc-tv1); } .sc .g-tv2 { stop-color: var(--sc-tv2); } .sc .g-tv3 { stop-color: var(--sc-tv3); } .sc .g-tv4 { stop-color: var(--sc-tv4); }
.sc .s-star { fill: var(--sc-star); } .sc .s-moon { fill: var(--sc-moon); } .sc .s-halo { fill: var(--sc-halo); } .sc .s-crater { fill: var(--sc-crater); }
.sc .s-far { fill: var(--sc-far); } .sc .s-fwin { fill: var(--sc-fwin); } .sc .s-red { fill: var(--sc-red); }
.sc .s-refl { fill: var(--sc-refl); } .sc .s-mrefl { fill: var(--sc-mrefl); } .sc .s-river2 { fill: var(--sc-riv1); }
.sc .s-pier { fill: var(--sc-pier); }
.sc .s-truss, .sc .s-truss2 { fill: none; stroke-width: .8; vector-effect: non-scaling-stroke; }
.sc .s-truss { stroke: var(--sc-bridge); } .sc .s-truss2 { stroke: var(--sc-bridge2); }
.sc .s-truss.thick, .sc .s-truss2.thick { stroke-width: 1.6; }
.sc .s-chord, .sc .s-chord2 { fill: none; stroke-width: 2.6; stroke-linejoin: round; }
.sc .s-chord { stroke: var(--sc-bridge); } .sc .s-chord2 { stroke: var(--sc-bridge2); }
.sc .s-chord.thick, .sc .s-chord2.thick { stroke-width: 7; }
.sc .s-chord-hi { fill: none; stroke: var(--sc-chord-hi); stroke-width: .8; vector-effect: non-scaling-stroke; transform: translateY(-1.4px); }
.sc .s-deck { fill: var(--sc-bridge); } .sc .s-lampdot { fill: var(--sc-lampdot); }
.sc .s-train { fill: var(--sc-train); } .sc .s-twin { fill: var(--sc-twin); } .sc .s-twin2 { fill: var(--sc-twin2); } .sc .s-head { fill: var(--sc-head); } .sc .s-beam { fill: var(--sc-beam); }
.sc .s-moto { fill: var(--sc-moto); }
.sc .s-roof1 { fill: var(--sc-roof1); } .sc .s-roof2 { fill: var(--sc-roof2); } .sc .s-rim { fill: var(--sc-rim); } .sc .s-tank1 { fill: var(--sc-tank1); } .sc .s-tank { fill: var(--sc-tank); }
.sc .s-ant { fill: none; stroke: var(--sc-ant); stroke-width: .8; vector-effect: non-scaling-stroke; }
.sc .s-tree { fill: var(--sc-tree); } .sc .s-win { fill: var(--sc-win); } .sc .s-win2 { fill: var(--sc-win2); } .sc .s-win3 { fill: var(--sc-win3); }
.sc .s-sil { fill: var(--bg); }
.sc .s-wall { fill: var(--sc-wall); } .sc .s-base { fill: var(--sc-base); }
.sc .s-frame { fill: var(--sc-frame); } .sc .s-frame-hi { fill: var(--sc-frame-hi); } .sc .s-frame-lo { fill: var(--sc-frame-lo); }
.sc .s-frame-line, .sc .s-frame-line2, .sc .s-line { fill: none; stroke: var(--sc-line); stroke-width: .9; vector-effect: non-scaling-stroke; }
.sc .s-reveal { fill: var(--sc-reveal); } .sc .s-reveal2 { fill: var(--sc-reveal2); }
.sc .s-fan, .sc .s-fan2 { fill: none; stroke: var(--sc-frame); stroke-width: 2.6; stroke-linecap: round; }
.sc .s-fan2 { stroke-width: 6; }
.sc .s-shut { fill: var(--sc-shut); } .sc .s-shut-lo { fill: var(--sc-shut-lo); } .sc .s-shut-hi { fill: var(--sc-shut-hi); }
.sc .s-leaf { fill: var(--sc-leaf); } .sc .s-glass { fill: var(--sc-glass); }
.sc .s-floor { fill: var(--sc-floor); } .sc .s-board { fill: none; stroke: var(--sc-board); stroke-width: 1; vector-effect: non-scaling-stroke; }
.sc .s-winlight { fill: var(--sc-winlight); } .sc .s-rug { fill: var(--sc-rug); } .sc .s-rug-b { fill: none; stroke: var(--sc-rug-b); stroke-width: 1.2; stroke-dasharray: 6 5; vector-effect: non-scaling-stroke; }
.sc .s-wood { fill: var(--sc-wood); } .sc .s-wood-lo { fill: var(--sc-wood-lo); } .sc .s-wood-hi { fill: var(--sc-wood-hi); }
.sc .s-seam { fill: none; stroke: var(--sc-seam); stroke-width: 1; vector-effect: non-scaling-stroke; }
.sc .s-shade { fill: var(--sc-shade); }
.sc .s-tv { fill: var(--sc-tv); } .sc .s-tv-rim { fill: none; stroke: var(--sc-tv-rim); stroke-width: 1; vector-effect: non-scaling-stroke; } .sc .s-glare { fill: var(--sc-glare); }
.sc .s-led { fill: var(--sc-led); }
.sc .s-metal { fill: var(--sc-metal); } .sc .s-metal2 { fill: var(--sc-metal2); } .sc .s-ant2 { fill: none; stroke: var(--sc-metal); stroke-width: 1.6; stroke-linecap: round; }
.sc .s-lampshade { fill: var(--sc-lampshade); } .sc .s-lampin { fill: var(--sc-lampin); }
.sc .s-pot { fill: var(--sc-pot); } .sc .s-pot2 { fill: var(--sc-pot2); } .sc .s-leaf1 { fill: var(--sc-leaf1); } .sc .s-leaf2 { fill: var(--sc-leaf2); }
.sc .s-vein { fill: none; stroke: var(--sc-vein); stroke-width: .9; vector-effect: non-scaling-stroke; }
.sc .s-paper { fill: var(--sc-paper); } .sc .s-red2 { fill: var(--sc-red2); } .sc .s-pline { fill: var(--sc-pline); }
.sc .s-case1 { fill: var(--sc-case1); } .sc .s-case2 { fill: var(--sc-case2); } .sc .s-case3 { fill: var(--sc-case3); }
.sc .s-bowl { fill: var(--sc-bowl); } .sc .s-bowlline { fill: none; stroke: var(--sc-bowlline); stroke-width: 1.6; }
.sc .s-broth { fill: var(--sc-broth); } .sc .s-noodle { fill: none; stroke: var(--sc-noodle); stroke-width: 1.2; } .sc .s-herb { fill: var(--sc-herb); } .sc .s-beef { fill: var(--sc-beef); }
.sc .s-chop { fill: none; stroke: var(--sc-chop); stroke-width: 2; stroke-linecap: round; }
.sc .s-glassb { fill: var(--sc-glassb); } .sc .s-tea { fill: var(--sc-tea); } .sc .s-ice { fill: var(--sc-ice); }
.sc .s-rib { fill: none; stroke: var(--sc-rib); stroke-width: .7; vector-effect: non-scaling-stroke; } .sc .s-glassrim { fill: none; stroke: var(--sc-rib); stroke-width: 1; vector-effect: non-scaling-stroke; }
.sc .s-steam { fill: none; stroke: var(--sc-steam); stroke-width: 2.4; stroke-linecap: round; opacity: .55; }
.sc .s-sofa { fill: var(--sc-sofa); } .sc .s-sofa-lo { fill: var(--sc-sofa-lo); } .sc .s-sofa-hi { fill: none; stroke-width: 3; stroke-linecap: round; }
.sc .s-sofa-seam { fill: none; stroke: var(--sc-seam2); stroke-width: 1.2; vector-effect: non-scaling-stroke; }
.sc .s-throw { fill: var(--sc-throw); } .sc .s-throw-line { fill: none; stroke: var(--sc-throw-line); stroke-width: 1.4; stroke-linecap: round; }
.sc .s-cushion { fill: var(--sc-cushion); } .sc .s-cushion-line { fill: none; stroke: rgba(13,18,3,.25); stroke-width: 1; vector-effect: non-scaling-stroke; }
.sc .s-skin { fill: var(--sc-skin); } .sc .s-hair { fill: var(--sc-hair); } .sc .s-shirt { fill: var(--sc-shirt); } .sc .s-shirt2 { fill: var(--sc-shirt2); }
.sc .s-collar { fill: none; stroke: var(--sc-collar); stroke-width: 3; stroke-linejoin: round; } .sc .s-pants { fill: var(--sc-pants); } .sc .s-shoe { fill: var(--sc-shoe); }
.sc .s-cap { fill: var(--sc-cap); } .sc .s-capbrim { fill: var(--sc-capbrim); } .sc .s-bag { fill: var(--sc-bag); } .sc .s-bagline { fill: var(--sc-bagline); }
.sc .s-arm { fill: none; stroke: var(--sc-shirt); stroke-width: 9; stroke-linecap: round; } .sc .s-arm2 { fill: none; stroke: var(--sc-shirt2); stroke-width: 9; stroke-linecap: round; }
.sc .s-door { fill: var(--sc-door); } .sc .s-doorin { fill: var(--sc-doorin); } .sc .s-doorspill { fill: var(--sc-doorspill); } .sc .s-mat { fill: var(--sc-mat); }
.sc .s-spark { fill: var(--sc-moon); }
.sc .s-walk { fill: var(--sc-walk); } .sc .s-rail { fill: none; stroke: var(--sc-rail); stroke-width: 3; }
.sc .s-cable { fill: none; stroke: var(--sc-cable); stroke-width: 2.6; stroke-linecap: round; } .sc .s-plug { fill: var(--sc-plug); }
.sc .s-moth { fill: var(--sc-lampshade); }
/* the controller lying on the table in midnight black */
.sc-padk { --dv-w: #2a2e3c; --dv-w2: #20232e; --dv-wo: rgba(255,255,255,.14); --dv-btnw: #4c5164; --dv-gly: #8a90a0; --dv-k: #14161d; }

/* ------------------------------------------------------------------ scene motion (base values = the still frame) */
.sc .s-train-g { transform: translateX(-180px); }
.sc .s-prog { opacity: 0; } .sc .s-prog.p1 { opacity: 1; }
.sc .s-tvg { opacity: 0; } .sc .s-tvg.tvg1 { opacity: 1; }
@media (prefers-reduced-motion: no-preference) {
  .sc .s-train-g { animation: sc-train 26s linear infinite; }
  .sc .s-train-g.bt { animation-duration: 34s; }
  .sc .s-train-g.nf { animation: sc-train-nf 16s linear infinite; }
  .sc .s-moto { animation: sc-moto 15s linear infinite; } .sc .s-moto.m1 { animation-delay: -6s; } .sc .s-moto.m2 { animation: sc-moto-rev 19s linear infinite; animation-delay: -3s; }
  .sc .s-prog, .sc .s-tvg { animation: sc-tv 16s infinite; }
  .sc .p2, .sc .tvg2 { animation-delay: -12s; } .sc .p3, .sc .tvg3 { animation-delay: -8s; } .sc .p4, .sc .tvg4 { animation-delay: -4s; }
  .sc .tv-dash { animation: sc-dash .5s linear infinite; }
  .sc .tv-flick { animation: sc-flick 3.2s steps(1) infinite; }
  .sc .fl { animation: sc-flick 9s steps(1) infinite; } .sc .fl1 { animation-duration: 13s; animation-delay: -4s; } .sc .fl2 { animation-duration: 17s; animation-delay: -9s; } .sc .fl3 { animation-duration: 11s; animation-delay: -2s; }
  .sc .tw { animation: sc-tw 5s ease-in-out infinite; } .sc .tw1 { animation-delay: -2s; } .sc .tw2 { animation-delay: -3.6s; }
  .sc .bl, .sc .blink { animation: sc-blink 2.4s steps(1) infinite; }
  .sc .s-steam { animation: sc-steam 4.2s ease-in-out infinite; } .sc .st1 { animation-delay: -1.4s; } .sc .st2 { animation-delay: -2.8s; }
  .sc .s-moth { animation: sc-moth 3s ease-in-out infinite; } .sc .s-moth.m2 { animation-delay: -1s; animation-duration: 3.6s; } .sc .s-moth.m3 { animation-delay: -2s; animation-duration: 2.6s; }
}
/* off screen: everything holds still (no paint work while you read further down) */
.sc-off .sc *, .sc-off.sc * { animation-play-state: paused !important; }
@keyframes sc-train { 0% { transform: translateX(380px); } 62% { transform: translateX(-760px); } 100% { transform: translateX(-760px); } }
@keyframes sc-train-nf { 0% { transform: translateX(520px); } 70% { transform: translateX(-900px); } 100% { transform: translateX(-900px); } }
@keyframes sc-moto { from { transform: translateX(-260px); } to { transform: translateX(520px); } }
@keyframes sc-moto-rev { from { transform: translateX(260px); } to { transform: translateX(-620px); } }
@keyframes sc-tv { 0%, 22% { opacity: 1; } 25.5%, 96.5% { opacity: 0; } 100% { opacity: 1; } }
@keyframes sc-dash { to { transform: translateY(6px); } }
@keyframes sc-flick { 0%, 100% { opacity: 1; } 31% { opacity: .15; } 34% { opacity: 1; } 62% { opacity: .2; } 70% { opacity: 1; } }
@keyframes sc-tw { 0%, 100% { opacity: 1; } 50% { opacity: .25; } }
@keyframes sc-blink { 0%, 100% { opacity: 1; } 50% { opacity: .15; } }
@keyframes sc-steam { 0% { opacity: 0; transform: translateY(6px); } 35% { opacity: .55; } 100% { opacity: 0; transform: translateY(-22px); } }
@keyframes sc-moth { 0%, 100% { transform: translate(0, 0); } 33% { transform: translate(6px, -5px); } 66% { transform: translate(-5px, 4px); } }

/* ================================================================== home hero art */
/* the content paints above the art (position without z-index: no new stacking context for the booking bar's popover) */
.hero > .frame { position: relative; }
.hero-art { position: absolute; left: 0; right: 0; top: 0; bottom: 0; overflow: hidden; pointer-events: none; opacity: 0; transition: opacity 1s var(--ease); }
.hero-art.is-on { opacity: 1; }
/* until gamewall.js has decided (wall or scene), the stage stays empty instead of flashing the old composition */
.hero:not(.hero--wall):not(.hero--scene):not(.hero--plain) .stage > * { visibility: hidden; }

/* ---------- the illustrated apartment (scenes.js) */
.hero--scene .stage > :not(.hero-art) { visibility: hidden; }
.sc-home .sc-layer { position: absolute; inset: 0; }
.sc-home .sc-layer > svg { width: 100%; height: 100%; max-width: none; }
.sc-home .sc-l-view { transform: translate3d(calc(var(--sc-px, 0) * -16px), calc(var(--sc-py, 0) * -8px + var(--sc-sy, 0) * 44px), 0); transition: transform .8s var(--ease); will-change: transform; }
.sc-home .sc-l-fg { transform: translate3d(calc(var(--sc-px, 0) * 12px), calc(var(--sc-py, 0) * 5px + var(--sc-sy, 0) * -26px), 0); transition: transform .8s var(--ease); will-change: transform; }
.sc-home .sc-scrim { position: absolute; inset: 0; display: none; }
.sc-home.is-wide .sc-scrim { display: block;
  background: linear-gradient(90deg, color-mix(in srgb, var(--bg) 94%, transparent) 0, color-mix(in srgb, var(--bg) 88%, transparent) calc(50% - 130px), color-mix(in srgb, var(--bg) 42%, transparent) calc(50% + 10px), transparent calc(50% + 120px)),
              linear-gradient(180deg, color-mix(in srgb, var(--bg) 55%, transparent) 0, transparent 90px); }
.sc-home .sc-tags { position: absolute; inset: 0; }
.sc-home .sc-tag { position: absolute; left: var(--tx, 80%); top: var(--ty, 55%); margin: 0; display: flex; align-items: center; gap: 8px; white-space: nowrap; font: 500 12px/1.25 var(--font-mono); color: var(--fg);
  padding: 6px 10px 6px 0; border-radius: 8px; background: color-mix(in srgb, var(--bg) 78%, transparent); -webkit-backdrop-filter: blur(6px); backdrop-filter: blur(6px); }
.sc-home .sc-tag::before { content: ""; width: 26px; height: 1px; background: currentColor; opacity: .6; }
.sc-home .sc-tag b { font-weight: 500; color: var(--accent); }
.sc-home .sc-tags.flip .sc-tag { flex-direction: row-reverse; text-align: right; padding: 6px 0 6px 10px; }
@media (max-width: 760px) { .sc-home .sc-tag { display: none; } }
@media (max-width: 980px) {
  /* phones and tablets: the scene sits where the stage is, edge to edge, rising out of the page */
  .stage > .sc-home { left: calc(50% - 50vw); right: calc(50% - 50vw); top: 0; bottom: -32px;
    -webkit-mask-image: linear-gradient(180deg, transparent 0, #000 18%); mask-image: linear-gradient(180deg, transparent 0, #000 18%); }
  .hero .stage { aspect-ratio: 1 / 1.02; }
  /* the night starts behind the headline: a sky wash and a few stars above the copy */
  .hero--scene::before { content: ""; position: absolute; left: 0; right: 0; top: 0; height: 62%; pointer-events: none;
    background: radial-gradient(1.6px 1.6px at 14% 12%, var(--sc-star) 50%, transparent 60%), radial-gradient(1.2px 1.2px at 38% 6%, var(--sc-star) 50%, transparent 60%),
      radial-gradient(1.4px 1.4px at 71% 15%, var(--sc-star) 50%, transparent 60%), radial-gradient(1.1px 1.1px at 88% 34%, var(--sc-star) 50%, transparent 60%),
      radial-gradient(1.2px 1.2px at 93% 8%, var(--sc-star) 50%, transparent 60%), radial-gradient(1px 1px at 58% 27%, var(--sc-star) 50%, transparent 60%),
      linear-gradient(180deg, color-mix(in srgb, var(--sc-sky1) 42%, transparent), transparent); }
}
@media (max-width: 980px) and (prefers-reduced-motion: no-preference) { .hero--scene::before { animation: sc-fade 1.2s var(--ease) both; } }
@keyframes sc-fade { from { opacity: 0; } }

/* ---------- the game wall (gamewall.js) */
.gw { perspective: 1600px; perspective-origin: 68% 38%; background: var(--bg); }
.gw-plane { position: absolute; left: 50%; top: 50%; width: 125%; height: 170%; display: grid; grid-template-columns: repeat(var(--cols), minmax(0, 1fr)); gap: 0 14px; align-items: start;
  transform: translate(-44%, -50%) translateY(calc(var(--gs, 0) * 70px)) rotateX(calc(22deg + var(--gy, 0) * -2.5deg)) rotateY(calc(var(--gx, 0) * 3deg)) rotateZ(-13deg);
  transform-style: preserve-3d; transition: transform 1.1s var(--ease); }
.gw-col { transform: translateZ(var(--z, 0)) translateY(var(--off, 0)); transform-style: preserve-3d; }
.gw-run { display: flex; flex-direction: column; gap: 14px; padding-bottom: 14px; will-change: transform; }
.gw-card { position: relative; aspect-ratio: 3 / 4; border-radius: 12px; overflow: hidden; background: color-mix(in srgb, var(--panel) 80%, #1b2553);
  box-shadow: 0 0 0 1px rgba(255,255,255,.06), 0 34px 60px -26px rgba(0,0,0,.75); }
.gw-card::after { content: ""; position: absolute; inset: 0; border-radius: inherit; background: linear-gradient(160deg, rgba(255,255,255,.12), transparent 38%); }
.gw-art { position: absolute; inset: 0; opacity: 0; transition: opacity 1s var(--ease); }
.gw-card.on .gw-art { opacity: 1; }
.gw-card.off { visibility: hidden; }
@media (prefers-reduced-motion: no-preference) {
  .gw-run { animation: gw-drift var(--dur, 80s) linear infinite; }
  .gw-run.rev { animation-direction: reverse; }
}
.gw-off .gw-run { animation-play-state: paused; }
@keyframes gw-drift { to { transform: translate3d(0, -50%, 0); } }
/* night tint: an indigo wash over the art, then the scrim that keeps the copy readable and a vignette */
.gw-wash, .gw-shade { position: absolute; inset: 0; }
.gw-wash { background: #18205a; mix-blend-mode: multiply; opacity: .36; }
.gw-shade {
  background: radial-gradient(ellipse 70% 80% at 72% 46%, transparent 40%, color-mix(in srgb, var(--bg) 70%, transparent) 100%),
              linear-gradient(90deg, color-mix(in srgb, var(--bg) 95%, transparent) 0, color-mix(in srgb, var(--bg) 86%, transparent) calc(50% - 200px), color-mix(in srgb, var(--bg) 35%, transparent) calc(50% + 40px), color-mix(in srgb, var(--bg) 12%, transparent) 100%),
              linear-gradient(180deg, color-mix(in srgb, var(--bg) 60%, transparent) 0, transparent 120px, transparent calc(100% - 90px), var(--bg) 100%); }
:root[data-theme="light"] .gw-wash { background: #ffcfa6; mix-blend-mode: soft-light; opacity: .5; }
@media (min-width: 981px) { :root[data-theme="light"] .gw-shade { background-size: 100% 100%; background-image:
  radial-gradient(ellipse 70% 80% at 72% 46%, transparent 40%, color-mix(in srgb, var(--bg) 60%, transparent) 100%),
  linear-gradient(90deg, color-mix(in srgb, var(--bg) 97%, transparent) 0, color-mix(in srgb, var(--bg) 92%, transparent) calc(50% - 160px), color-mix(in srgb, var(--bg) 40%, transparent) calc(50% + 60px), color-mix(in srgb, var(--bg) 10%, transparent) 100%),
  linear-gradient(180deg, color-mix(in srgb, var(--bg) 60%, transparent) 0, transparent 120px, transparent calc(100% - 90px), var(--bg) 100%); } }
@media (max-width: 980px) {
  .gw-plane { width: 170%; height: 140%; transform: translate(-50%, -48%) translateY(calc(var(--gs, 0) * 50px)) rotateX(18deg) rotateZ(-12deg); }
  .gw-shade { background: linear-gradient(180deg, color-mix(in srgb, var(--bg) 86%, transparent) 0, color-mix(in srgb, var(--bg) 80%, transparent) 40%, color-mix(in srgb, var(--bg) 25%, transparent) 64%, color-mix(in srgb, var(--bg) 10%, transparent) 86%, var(--bg) 100%); }
  :root[data-theme="light"] .gw-shade { background: linear-gradient(180deg, color-mix(in srgb, var(--bg) 93%, transparent) 0, color-mix(in srgb, var(--bg) 90%, transparent) 44%, color-mix(in srgb, var(--bg) 30%, transparent) 66%, color-mix(in srgb, var(--bg) 10%, transparent) 86%, var(--bg) 100%); }
}
/* the PS5 drawings stand in front of the wall: no moon, a soft lime-and-amber glow under them instead */
.hero--wall .stage .moon, .hero--wall .stage .orbit, .hero--wall .stage .sky { display: none; }
.hero--wall .stage::before { content: ""; position: absolute; left: 6%; right: 6%; top: 18%; bottom: 2%; border-radius: 50%;
  background: radial-gradient(closest-side, color-mix(in srgb, var(--lime) 22%, transparent), color-mix(in srgb, #ff9a48 10%, transparent) 55%, transparent); }
.hero--wall .stage .dev svg { filter: drop-shadow(0 30px 26px rgba(0,0,0,.6)); }
.hero--wall .stage .tn-1 { color: var(--fg); padding: 6px 10px 6px 0; border-radius: 8px; background: color-mix(in srgb, var(--bg) 70%, transparent); -webkit-backdrop-filter: blur(8px); backdrop-filter: blur(8px); }
.hero--wall .stage .tn-1::before { background: var(--fg); }

/* ================================================================== night-skyline band (content pages) */
body:not([data-page="home"]):not([data-page="admin"]):not([data-page="404"]) main { position: relative; }
body:not([data-page="home"]):not([data-page="admin"]):not([data-page="404"]) main::before { content: ""; display: block; height: var(--band-h, 112px); }
body:not([data-page="home"]):not([data-page="admin"]):not([data-page="404"]) main > .sec:first-of-type { padding-top: clamp(18px, 2.6vw, 30px); }
.sky-band { position: absolute; left: 0; right: 0; top: 0; height: var(--band-h, 112px); overflow: hidden; pointer-events: none; }
.sky-band > svg { width: 100%; height: 100%; max-width: none; }
:root { --band-h: 112px; --skyline: url("/assets/skyline.svg"); }
@media (max-width: 640px) { :root { --band-h: 76px; } }

/* ================================================================== landing heroes: an arched night window behind the devices */
.lp-window { position: absolute; left: 4%; right: 10%; top: 0; bottom: 6%; }
.lp-window > svg { width: 100%; height: 100%; max-width: none; filter: drop-shadow(0 24px 40px rgba(0,0,0,.25)); }
.lp-hero-stage .lp-hero-art { z-index: 1; }

/* ================================================================== 404: lost on Long Biên */
.nf > .art { aspect-ratio: 5 / 4; max-width: 540px; width: 100%; transform: none; justify-self: end; }
.nf > .art.nf-scene > svg { width: 100%; height: 100%; max-height: none; filter: drop-shadow(0 30px 50px rgba(0,0,0,.35)); }
.nf > .art.nf-scene .v-shadow { display: none; }
@media (max-width: 760px) { .nf > .art { max-width: 420px; justify-self: center; } }

/* ================================================================== booking success: the hand-over at the door */
.sc-done { margin: calc(-1 * clamp(22px, 4vw, 36px)) calc(-1 * clamp(22px, 4vw, 36px)) 0; border-radius: var(--radius-lg) var(--radius-lg) 0 0; overflow: hidden; border-bottom: 1px solid var(--line); }
.sc-done > svg { width: 100%; height: auto; max-height: 260px; }
.sc-door .v-shadow { display: none; }

/* ================================================================== empty and error states: small night spots */
.empty::before, .pg-empty::before, .don-miss::before { content: ""; display: block; width: 84px; height: 56px; background: var(--fg-2); opacity: .5;
  -webkit-mask: var(--spot) center / contain no-repeat; mask: var(--spot) center / contain no-repeat;
  --spot: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 84 56'%3E%3Ccircle cx='66' cy='13' r='7'/%3E%3Cpath d='M0 56V36h8v-6h6v6h4V22l9-6 9 6v34z M22 28v4h3v-4z M29 28v4h3v-4z M22 38v4h3v-4z M40 56V30h14v-8h3v8h7v26z M45 36v4h3v-4z M56 36v4h3v-4z M66 56V40h18v16z' fill-rule='evenodd'/%3E%3C/svg%3E"); }
.empty::before { margin: 0 auto 16px; }
.ad-page .empty::before, .ad-page .pg-empty::before { display: none; }
.pg-empty::before, .don-miss::before { margin-bottom: 4px; }
/* errors: an unplugged cable instead of the rooftops */
.pg-empty[role="alert"]::before, .don-miss::before, .empty:has(button)::before { background: var(--warn); opacity: .7;
  --spot: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 84 56'%3E%3Cpath d='M2 40c14 0 18-22 34-22h6' fill='none' stroke='%23000' stroke-width='4' stroke-linecap='round'/%3E%3Crect x='42' y='11' width='14' height='14' rx='3'/%3E%3Cpath d='M56 14h7M56 22h7' stroke='%23000' stroke-width='3' stroke-linecap='round'/%3E%3Cpath d='M70 30l5-7M72 38l8-3M66 26l1-8' stroke='%23000' stroke-width='2.4' stroke-linecap='round'/%3E%3C/svg%3E"); }

/* ================================================================== footer: the city skyline grows out of the footer */
.ftr { position: relative; border-top-color: transparent; }
.ftr::before, .ftr::after { content: ""; position: absolute; left: 0; right: 0; bottom: 100%; height: 46px; pointer-events: none;
  -webkit-mask: var(--skyline) left bottom / 1200px 46px repeat-x; mask: var(--skyline) left bottom / 1200px 46px repeat-x; }
.ftr::before { background: var(--line-2); transform: translateY(-1px); }
/* the silhouette in the footer's colour, a few warm windows lit in it */
.ftr::after { background: url("/assets/skyline-windows.svg") left bottom / 1200px 46px repeat-x, var(--bg-2); }
:root[data-theme="light"] .ftr::after { background-image: none; }
.ftr { margin-top: 46px; }

/* ================================================================== long-form pages (.doc, legal) : defaults only, page styles win */
:where(.doc) :where(h2) { scroll-margin-top: calc(var(--hdr) + 24px); }
:where(.doc) :where(ul) > :where(li)::marker { color: var(--accent); }
:where(.doc) :where(blockquote) { margin: 18px 0; padding: 14px 18px; border-left: 2px solid var(--accent); background: var(--panel-2); border-radius: 0 var(--radius) var(--radius) 0; color: var(--fg-2); }
:where(.doc) :where(hr) { height: 0; border: 0; margin: 36px 0; text-align: center; overflow: visible; }
:where(.doc) :where(hr)::after { content: "· · ·"; font: 500 14px var(--font-mono); letter-spacing: .4em; color: var(--muted); }
:where(.doc) :where(table) { font-variant-numeric: tabular-nums; }
@media print { .sky-band, .hero-art, .ftr::before, .ftr::after { display: none !important; } body main::before { display: none !important; } }

/* ================================================================== admin: a light touch */
.ad-login { position: relative; overflow: hidden; padding-bottom: 64px; }
.ad-login::after { content: ""; position: absolute; left: 0; right: 0; bottom: 0; height: 40px; background: var(--panel-2);
  -webkit-mask: var(--skyline) left bottom / 900px 40px repeat-x; mask: var(--skyline) left bottom / 900px 40px repeat-x; }
.ad-page .ftr::before, .ad-page .ftr::after { display: none; }
.ad-page .ftr { margin-top: 0; border-top-color: var(--line); }
