/* Floating covers: no floor, box depth or cast ground shadow. */
.section-mode main>section#work.work-gallery,#work.work-gallery{position:relative;isolation:isolate;display:flex;flex-direction:column;justify-content:flex-start;height:100svh;min-height:620px;padding:0 0 30px;overflow:hidden;background:#24211d;color:#fbf1e4;border:9px solid #191815;border-radius:42px}
#work.work-gallery::after{content:'';position:absolute;inset:0;z-index:9;border-radius:34px;pointer-events:none;background:repeating-linear-gradient(transparent 0 3px,#00000015 3px 4px);box-shadow:inset 0 0 60px #0005,inset 0 0 0 1px #fff1}
.gallery-header{display:flex;align-items:center;justify-content:space-between;gap:25px;padding:28px 4%;position:relative;z-index:10}
.gallery-brand{font:900 44px/.9 Arial,sans-serif;letter-spacing:-4px}.gallery-brand span{color:#e94e1d}
#work-title{display:flex;align-items:center;gap:24px;font-size:23px;color:#e94e1d;font-weight:400;white-space:nowrap}
#work-title span{font:13px/1.4 Georgia,serif;letter-spacing:2px;color:#fbf1e4}
.gallery-header nav{display:flex;gap:28px;font:13px/1.5 Arial,sans-serif}.gallery-header nav a{padding:8px 0}.gallery-header nav [aria-current]{color:#f16a35;border-bottom:1px solid}
.gallery-orbit{position:relative;flex:1;min-height:0;perspective:1400px;touch-action:pan-y;cursor:grab;outline-offset:-8px}
.gallery-orbit.is-dragging{cursor:grabbing}
.work-card{position:absolute;left:50%;top:5%;height:84%;max-height:560px;aspect-ratio: .69;width:auto;padding:0;text-align:left;color:#24211d;transform-style:preserve-3d;will-change:transform;user-select:none;-webkit-user-select:none;touch-action:pan-y;cursor:inherit;opacity:0}
.work-card.is-selected{cursor:pointer}
.cover-sheet{height:100%;display:flex;flex-direction:column;position:relative;overflow:hidden;padding:6% 6% 4%;background:#f6e7cd;border:1px solid #cbb694;border-radius:1px;box-shadow:inset 0 0 0 4px #fff2;animation:cover-drift 6s ease-in-out infinite alternate;animation-delay:calc(var(--card-index,0) * -.8s)}
.cover-sheet::after{content:'';position:absolute;inset:0;pointer-events:none;opacity:.15;background-image:url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='130' height='130'%3E%3Cfilter id='n'%3E%3CfeTurbulence type='fractalNoise' baseFrequency='.7' numOctaves='3' stitchTiles='stitch'/%3E%3C/filter%3E%3Cpath fill='%23000' filter='url(%23n)' opacity='.5' d='M0 0h130v130H0z'/%3E%3C/svg%3E")}
.cover-top,.cover-bottom{display:flex;align-items:center;justify-content:space-between;font:700 clamp(8px,.7vw,12px)/1.2 Arial,sans-serif}.cover-top>span{font-size:26px;color:#e94e1d}
.cover-name{font-family:Georgia,'Songti SC',SimSun,serif;font-size:clamp(32px,4.6vw,78px);line-height:1.15;letter-spacing:-3px;margin-top:7%}
.cover-en{font:700 clamp(21px,2.5vw,43px)/.88 Georgia,serif;letter-spacing:-1px;color:#df5523;margin-top:3%}.cover-status{font-size:clamp(9px,.85vw,14px);margin-top:5%;position:relative;z-index:2}
.cover-art{position:relative;display:block;flex:1;min-height:0;margin-top:5%;overflow:hidden}
.art-flower,.art-bloom{font:clamp(140px,22vw,360px)/.85 Georgia,serif;color:#e85b24;transform:rotate(-18deg);display:flex;align-items:center;justify-content:center;overflow:visible}
.cover-bottom{border-top:1px solid #24211d55;padding-top:5%;z-index:2;margin-top:auto}
.cover-gg{background:#eddbb5}.cover-gg .cover-en{color:#ac872c}.cover-gg .cover-name{font-family:Georgia,serif}
.art-television{display:grid;place-items:center;padding-top:14%}
.cover-tv{display:block;width:90%;height:78%;border:7px solid #3d372c;border-radius:13px;background:#bf943e;position:relative;transform:rotate(-6deg)}
.cover-tv::before,.cover-tv::after{content:'';position:absolute;top:-26%;left:45%;width:2px;height:28%;background:#443e30;transform:rotate(-35deg);transform-origin:bottom}.cover-tv::after{transform:rotate(40deg)}
.cover-tv b{display:grid;place-items:center;position:absolute;inset:10% 22% 10% 6%;background:#ded2a7;border:5px solid #463f2f;border-radius:20%;font:900 clamp(24px,3vw,50px) Arial}
.cover-tv i{position:absolute;right:5%;top:18%;height:16%;aspect-ratio:1;border:4px solid #463f2f;border-radius:50%}
.cover-sun{background:#e4d2ad}.cover-sun .cover-en{color:#a77a26}
.art-sunrise{background:linear-gradient(transparent 46%,#c3a04d 46% 54%,transparent 54% 58%,#c3a04d 58% 66%,transparent 66% 70%,#c3a04d 70% 78%,transparent 78%);border-radius:50% 50% 0 0}
.art-sunrise::before{content:'';position:absolute;width:100%;aspect-ratio:1;background:#e96229;border-radius:50%;top:2%;z-index:-1}
.cover-orbit{background:#3e4435;color:#edddba}.cover-orbit .cover-en{color:#d5ac56}.cover-orbit .cover-bottom{border-color:#edddba55}
.art-orbit{border:25px solid #b49a58;border-radius:50%;transform:rotate(-25deg) scale(.9);outline:1px solid #cbbd92;outline-offset:-42px}
.cover-wave{background:#efdab5}.art-waves{background:repeating-radial-gradient(ellipse at 0 100%,#e65e2a 0 14%,#c89d40 14% 28%,#f0d5a0 28% 40%);border-radius:50% 0 0 0}
.cover-bloom{background:#b9b79b}.cover-bloom .cover-en{color:#4d5640}.art-bloom{color:#4d5640}
.gallery-caption{text-align:center;position:relative;z-index:10;min-height:109px;padding:10px 22px 0}
.gallery-caption h3{font:700 clamp(20px,1.8vw,30px)/1.4 Georgia,'Songti SC',SimSun,serif}.gallery-caption p{font-size:13px;margin:6px 0 9px;line-height:1.5;color:#e4d4bb}
.gallery-caption a{color:#ff814c;font-size:15px}.gallery-caption>span{font-size:13px;color:#cdbda5}
.gallery-caption [hidden]{display:none}
.gallery-footer{position:relative;z-index:10;display:flex;align-items:center;justify-content:space-between;padding:12px 4% 0;font-size:13px;gap:12px}
.gallery-controls{display:flex;align-items:center;gap:26px}.gallery-controls button{font:32px/1 Arial;min-width:44px;min-height:44px;color:#ff814c}.gallery-controls button:disabled{opacity:.25;cursor:default}
body[data-section="work"] .channel-nav{background:#24211de6;color:#fbf1e4;border-color:#fbf1e444}
@keyframes cover-drift{from{transform:translateY(-4px) rotate(-.45deg)}to{transform:translateY(4px) rotate(.45deg)}}
@media(max-width:1000px){.gallery-header{padding:24px 4%}.gallery-header nav{gap:18px;font-size:11px}#work-title{gap:10px}#work-title span{font-size:11px}.work-card{height:78%;top:10%}.cover-name{font-size:clamp(38px,6vw,65px)}.cover-en{font-size:clamp(25px,3.6vw,40px)}.cover-status{font-size:12px}.art-flower,.art-bloom{font-size:260px}}
@media(max-width:580px){.section-mode main>section#work.work-gallery,#work.work-gallery{border-width:5px;border-radius:24px;min-height:620px;padding-bottom:76px}.gallery-header{padding:25px 20px 18px;flex-wrap:wrap;gap:20px}.gallery-brand{font-size:36px}#work-title{font-size:16px}#work-title span{font-size:9px;letter-spacing:1px}.gallery-header nav{width:100%;justify-content:space-between;font-size:11px}.work-card{height:82%;max-height:370px;top:5%}.cover-name{font-size:48px}.cover-en{font-size:29px}.cover-status{font-size:10px}.cover-top,.cover-bottom{font-size:8px}.art-flower,.art-bloom{font-size:215px}.gallery-caption{min-height:106px;padding-inline:15px}.gallery-caption h3{font-size:20px}.gallery-caption p{font-size:11px}.gallery-footer{font-size:10px;padding:8px 18px 0}.gallery-controls{gap:3px}.gallery-controls span{font-size:10px}.gallery-controls button{min-width:36px}.gallery-footer>a{max-width:82px}.gallery-orbit{min-height:280px}}
@media(max-height:700px) and (min-width:581px){.section-mode main>section#work.work-gallery,#work.work-gallery{min-height:460px;padding-bottom:12px}.gallery-header{padding-block:18px}.gallery-caption{min-height:86px}.gallery-caption h3{font-size:20px}.gallery-footer{padding-top:0}.work-card{height:88%;top:0}.cover-name{font-size:clamp(28px,7svh,50px)}.cover-en{font-size:clamp(19px,4.6svh,32px)}.art-flower,.art-bloom{font-size:180px}}
@media(prefers-reduced-motion:reduce){.cover-sheet{animation:none}.work-card{will-change:auto}}

/* Keep artwork within its own flexible slot at every viewport height. */
.cover-top,.cover-name,.cover-en,.cover-status,.cover-bottom{flex-shrink:0}
.art-flower,.art-bloom{overflow:hidden;transform:none;font-size:0}
.art-flower::before,.art-bloom::before{content:'✿';position:absolute;inset:0;display:grid;place-items:center;font:clamp(140px,19vw,310px)/.75 Georgia,serif;transform:rotate(-18deg)}
.cover-tv{height:auto;aspect-ratio:1.4;flex:none}
#work.work-gallery::after{background:repeating-linear-gradient(transparent 0 3px,#00000008 3px 4px)}
@media(max-width:580px){.art-flower::before,.art-bloom::before{font-size:190px}}
@media(max-height:700px) and (min-width:581px){.art-flower::before,.art-bloom::before{font-size:160px}}

.work-card{container-type:size;height:92%;top:2%}
.cover-name{font-size:16cqh}
.cover-en{font-size:8.5cqh}
.cover-status{font-size:max(10px,2.5cqh)}
.cover-top,.cover-bottom{font-size:max(8px,2cqh)}
.art-flower::before,.art-bloom::before{font-size:47cqh}
.art-television{padding-top:8%;align-items:center}
.cover-tv{width:88%;max-height:90%}
@media(max-width:580px){.work-card{height:82%;top:5%}.cover-name{font-size:16cqh}.cover-en{font-size:8.5cqh}}

.art-television .cover-tv{position:absolute;left:8%;top:22%;width:84%;height:68%;max-height:none;aspect-ratio:auto}

#work .gallery-footer{margin:0;border:0}

/* WebGL renders a truly curved paper surface; native buttons retain focus and input. */
.work-card{top:50%}
.work-surface{position:absolute;inset:0;width:100%;height:100%;pointer-events:none;z-index:0}
.has-surface .cover-sheet{opacity:0;animation:none}
#work[data-gallery-loading] :is(.gallery-header,.gallery-orbit,.gallery-caption,.gallery-footer){visibility:hidden}
.gallery-orbit[data-surface="static"] .cover-sheet{opacity:0;animation:none}
.work-static-cover{position:absolute;inset:0;width:100%;height:100%;border-radius:2% / 1%;pointer-events:none}
.work-card:focus-visible{outline:2px solid #ffad71;outline-offset:5px}
.gallery-orbit:not(.has-surface) .cover-sheet{transition:filter .5s,translate .65s cubic-bezier(.22,.68,.28,1),rotate .65s cubic-bezier(.22,.68,.28,1)}
.gallery-orbit:not(.has-surface) .is-hovered .cover-sheet{translate:0 -10px;rotate:1deg;filter:brightness(1.07)}
@media(prefers-reduced-motion:reduce){.gallery-orbit:not(.has-surface) .cover-sheet{transition:none}.gallery-orbit .is-hovered .cover-sheet{translate:none;rotate:none}}

.work-surface{top:-160px;bottom:auto;height:calc(100% + 320px)}

#work.work-gallery{contain:layout paint}

/* Center the caption group and align the controls independently of footer labels. */
#work .gallery-caption{display:flex;flex-direction:column;align-items:center;justify-content:center;gap:6px;padding:0 22px}
#work .gallery-caption p{margin:0}
/* Static CRT cabinet; all live content, including the oversized WebGL canvas,
   is clipped by the inset glass rather than the outside cabinet. */
.section-mode main>section#work.work-gallery,#work.work-gallery{display:block;padding:clamp(20px,2.1vw,54px);border:0;border-radius:0;background:#050505}
#work.work-gallery::after{content:none}
.work-screen{position:relative;isolation:isolate;display:flex;flex-direction:column;width:100%;height:100%;min-height:0;overflow:hidden;border-radius:5% / 9%;clip-path:url(#work-glass-clip);background:radial-gradient(ellipse at 48% 42%,#30332e 0%,#232620 48%,#151812 82%,#090c09 100%);box-shadow:0 0 0 2px #101210,0 4px 12px #000,inset 0 0 2px #9ca89b55}
.work-screen::before,.work-screen::after{content:'';position:absolute;inset:0;z-index:80;border-radius:inherit;pointer-events:none}
.work-screen::before{z-index:83;background:url("data:image/svg+xml,%3Csvg%20xmlns%3D%22http%3A%2F%2Fwww.w3.org%2F2000%2Fsvg%22%20viewBox%3D%220%200%201000%201000%22%20preserveAspectRatio%3D%22none%22%3E%3Cdefs%3E%3ClinearGradient%20id%3D%22rim%22%20x1%3D%220%22%20y1%3D%220%22%20x2%3D%221%22%20y2%3D%221%22%3E%3Cstop%20stop-color%3D%22%23dbe9db%22%20stop-opacity%3D%22.18%22%2F%3E%3Cstop%20offset%3D%22.38%22%20stop-color%3D%22%23c2d7c7%22%20stop-opacity%3D%22.09%22%2F%3E%3Cstop%20offset%3D%22.75%22%20stop-color%3D%22%238a9c91%22%20stop-opacity%3D%22.04%22%2F%3E%3Cstop%20offset%3D%221%22%20stop-color%3D%22%23d1dfd3%22%20stop-opacity%3D%22.05%22%2F%3E%3C%2FlinearGradient%3E%3Cpath%20id%3D%22edge%22%20d%3D%22M60%2025Q500%20-25%20940%2025C978%2027%20988%2060%20990%20120Q1008%20500%20990%20880C988%20950%20978%20977%20940%20980Q500%201020%2060%20980C22%20977%2012%20950%2010%20880Q-8%20500%2010%20120C12%2060%2022%2027%2060%2025Z%22%2F%3E%3C%2Fdefs%3E%3Cg%20fill%3D%22none%22%20stroke%3D%22url(%23rim)%22%3E%3Cuse%20href%3D%22%23edge%22%20stroke-width%3D%2212%22%20opacity%3D%22.06%22%2F%3E%3Cuse%20href%3D%22%23edge%22%20stroke-width%3D%224%22%20opacity%3D%22.10%22%2F%3E%3Cuse%20href%3D%22%23edge%22%20stroke-width%3D%22.65%22%20vector-effect%3D%22non-scaling-stroke%22%2F%3E%3C%2Fg%3E%3C%2Fsvg%3E") center/100% 100% no-repeat,radial-gradient(ellipse 76% 19% at 48% -7%,#e6f2df16 0%,#cbdccc0c 65%,transparent 100%),radial-gradient(ellipse 8% 88% at -2% 42%,#b7c9ba0d,transparent 100%),linear-gradient(145deg,#efffe309,transparent 29%,transparent 72%,#b9d4bc04);box-shadow:inset 0 3px 8px #d2e1cd14,inset 0 -7px 16px #000a,inset 7px 0 15px #0006,inset -7px 0 15px #0006}
.work-screen::after{z-index:81;background:repeating-linear-gradient(0deg,#0000000a 0 1px,transparent 1px 3px),repeating-linear-gradient(90deg,#a7c9a405 0 1px,transparent 1px 3px),radial-gradient(ellipse at 50% 48%,transparent 38%,#0003 69%,#000b 96%,#000e 100%);box-shadow:inset 18px 0 34px #0008,inset -18px 0 34px #0008,inset 0 15px 28px #0009,inset 0 -15px 28px #0009}
#work .site-logo{left:calc(5.5vw - clamp(20px,2.1vw,54px) * .11);top:8%}
#work .gallery-header,#work .gallery-caption,#work .gallery-footer{flex-shrink:0}
#work .gallery-caption h3{text-shadow:0 0 7px #f3e5c72b}
#work .site-logo,#work .gallery-header,#work .gallery-footer{z-index:82}
#work .gallery-footer{padding-bottom:14px}
body[data-section="work"] .channel-nav{right:calc(clamp(20px,2.1vw,54px) + 20px)}
#work .gallery-orbit{overflow:visible}
@media(max-width:580px){.section-mode main>section#work.work-gallery,#work.work-gallery{padding:10px}.work-screen{border-radius:24px}#work .site-logo{left:12px;top:12px}}
@media(min-width:1001px){
 #work.work-gallery{padding-block:clamp(20px,2.1vw,54px)!important}
 #work .gallery-footer{display:grid;grid-template-columns:1fr auto 1fr;align-items:center}
 #work .gallery-footer>a{justify-self:end}
 #work .gallery-controls{justify-self:center;align-items:center;min-height:44px}
 #work .gallery-controls span{display:flex;align-items:center;min-height:44px;line-height:1}
 #work .gallery-controls button{display:flex;align-items:center;justify-content:center;width:44px;height:44px;padding:0 0 3px;line-height:1}
}

/* Vector arrows keep gallery controls independent of text fonts. */
#work .gallery-controls button svg{display:block;width:26px;height:26px;flex:none;fill:none;stroke:currentColor;stroke-width:1.7;stroke-linecap:round;stroke-linejoin:round;pointer-events:none}
