@font-face{font-family:VoyageBrand;src:url('assets/voyage-brand-regular.woff2') format('woff2');font-weight:400;font-display:swap}
/* Gallery shell. Card artwork, SVG masks and optical materials remain independent. */
.gallery{--ink:#27272c;--muted:#71717a;--line:#27272c12;--surface:#fff;--field:#f2f2f4;--hover:#eaeaee;--page:#f8f8fa;--rail:248px;--inspector:384px;--ui-shadow:0 1px 3px #17171c08,0 0 0 1px #17171c04;background:var(--page);color:var(--ink);font:13px/1.5 Inter,'PingFang TC','PingFang SC',sans-serif;min-height:100svh}
[data-theme=dark] .gallery{--ink:#eeeef0;--muted:#96969f;--line:#ffffff12;--surface:#222226;--field:#2c2c31;--hover:#35353b;--page:#18181c;--ui-shadow:0 1px 3px #0002,0 0 0 1px #ffffff04}
.gallery button,.gallery select,.gallery input{font-family:Inter,'PingFang TC','PingFang SC',sans-serif}
.gallery button{cursor:pointer}
.gallery header{position:absolute;inset:0 0 auto;z-index:12;display:flex;align-items:center;justify-content:space-between;padding:24px 32px;color:var(--ink)}
.gallery .brand{margin:0;white-space:nowrap;font:400 60px/1.08 VoyageBrand,Voyage,serif;letter-spacing:-.015em}
.gallery .brand-caption{display:block;margin-top:6px;font:400 12px/20px Inter,sans-serif;letter-spacing:.04em;color:var(--muted)}
.gallery .header-actions,.creation-actions,.preference-controls{display:flex;align-items:center;gap:8px}
.gallery .header-actions{gap:18px}
.preference-controls{border-left:1px solid var(--line);padding-left:18px}
.gallery .header-actions button{display:inline-flex;align-items:center;justify-content:center;gap:7px;height:36px;margin:0;padding:0 14px;border:1px solid transparent;border-radius:999px;background:transparent;box-shadow:none;color:var(--muted);font-size:12px;font-weight:500;line-height:20px;letter-spacing:0;transition:background .16s,color .16s,box-shadow .16s}
.gallery .header-actions button:hover{background:var(--field);color:var(--ink)}
.gallery .header-actions .settings-toggle{background:var(--surface);border-color:var(--line);color:var(--ink);box-shadow:0 1px 2px #17171c03}
.gallery .header-actions .settings-toggle[aria-expanded=true]{background:var(--field);box-shadow:inset 0 0 0 1px var(--line)}
.gallery .header-actions .record-open{position:static;background:var(--ink);color:var(--page);border-color:transparent;box-shadow:0 2px 4px #17171c10}
.gallery .header-actions .record-open:hover{opacity:.88;background:var(--ink);color:var(--page)}
.header-actions svg{display:block;width:16px;height:16px;fill:none;stroke:currentColor;stroke-width:1.5;stroke-linecap:round;stroke-linejoin:round;flex:none}
.gallery .header-actions .sound-toggle{position:relative;width:36px;min-width:36px;padding:8px}
.gallery .sound-toggle[aria-checked=true]{color:var(--ink)}
.sound-toggle svg{width:18px;height:18px}.sound-toggle ellipse{fill:currentColor;stroke:none}
.sound-toggle .music-off{display:none}.sound-toggle[aria-checked=false] .music-off{display:block}
.ui-tooltip{position:absolute;top:calc(100% + 8px);left:50%;transform:translateX(-50%) translateY(-3px);padding:5px 9px;background:var(--ink);color:var(--page);border-radius:7px;font:11px/16px Inter,'PingFang TC',sans-serif;white-space:nowrap;pointer-events:none;opacity:0;transition:opacity .12s,transform .12s}
.sound-toggle:hover .ui-tooltip,.sound-toggle:focus-visible .ui-tooltip{opacity:1;transform:translateX(-50%) translateY(0)}
.language-control{position:relative;display:flex;align-items:center;gap:7px;height:36px;border:1px solid var(--line);border-radius:999px;padding:0 12px;background:var(--surface)}
.language-control>svg{width:14px;height:14px;color:var(--muted)}
.language-control::after{content:'';position:absolute;right:12px;top:14px;width:5px;height:5px;border-right:1px solid var(--muted);border-bottom:1px solid var(--muted);transform:rotate(45deg);pointer-events:none}
.language-control select{appearance:none;border:0;border-radius:0;padding:0 14px 0 0;min-width:67px;background:transparent;color:var(--ink);font-size:11px;line-height:20px;cursor:pointer}
.gallery .header-actions .theme-toggle{padding:0 0 0 4px;gap:8px;border-radius:8px;color:var(--muted)}
.gallery .header-actions .theme-toggle:hover{background:transparent;color:var(--ink)}
.theme-switch-label{font-size:11px;font-weight:400}
.theme-switch-track{position:relative;display:block;width:34px;height:20px;flex:none;border-radius:20px;background:#d6d6dc;box-shadow:inset 0 0 0 1px #17171c06;transition:background .18s}
.theme-switch-track i{position:absolute;top:3px;left:3px;width:14px;height:14px;border-radius:50%;background:#fff;box-shadow:0 1px 2px #17171c20;transition:transform .18s}
.theme-toggle[aria-checked=true] .theme-switch-track{background:#62626d}.theme-toggle[aria-checked=true] .theme-switch-track i{transform:translateX(14px)}
.gallery button:focus-visible,.gallery select:focus-visible,.gallery a:focus-visible{outline:2px solid #8c8c9b;outline-offset:3px}
/* A stable navigation rail with explicit display modes and a single selection. */
.collection-sidebar{position:fixed;left:32px;top:50%;transform:translateY(-50%);width:212px;z-index:11;display:flex;flex-direction:column;gap:24px}
.sidebar-heading{display:flex;align-items:center;justify-content:space-between;margin-bottom:10px;padding:0 4px;color:var(--muted);font-size:11px;line-height:20px}
.collection-count{font:10px/20px Inter,sans-serif;font-variant-numeric:tabular-nums;color:var(--muted)}
.view-toggle{display:flex;gap:3px;padding:4px;border-radius:12px;border:1px solid var(--line);background:var(--field)}
.gallery .view-toggle button{display:flex;align-items:center;justify-content:center;gap:7px;flex:1;min-width:0;height:34px;margin:0;padding:0 10px;border:0;border-radius:8px;color:var(--muted);background:transparent;box-shadow:none;font-size:12px;font-weight:400;line-height:20px;transition:background .16s,color .16s,box-shadow .16s}
.gallery .view-toggle button:hover{color:var(--ink)}
.gallery .view-toggle button[aria-pressed=true]{background:var(--surface);color:var(--ink);box-shadow:var(--ui-shadow)}
.view-toggle svg{width:18px;height:18px;fill:none;stroke:currentColor;stroke-width:1.25;stroke-linecap:round;flex:none}
.gallery .collection-sidebar .card-picker{position:relative;left:auto;top:auto;transform:none;display:flex;flex-direction:column;align-items:stretch;gap:4px;width:100%;max-width:none;margin:0;padding:6px;border:1px solid var(--line);border-radius:16px;background:var(--surface);box-shadow:0 2px 8px #17171c02;overflow:visible;flex-wrap:nowrap}
.gallery .card-picker button{position:relative;flex:none;min-width:0;width:100%;min-height:44px;padding:11px 10px;border:1px solid transparent;border-radius:10px;background:transparent;color:var(--muted);box-shadow:none;text-align:left;font-size:13px;font-weight:400;line-height:20px;transition:background .16s,color .16s,border-color .16s}
.gallery .card-picker button:hover{background:var(--field);color:var(--ink)}
.gallery .card-picker button[aria-pressed=true]{background:var(--field);color:var(--ink);border-color:var(--line);box-shadow:none}
.gallery .picker-title{display:flex;align-items:baseline;justify-content:flex-start;gap:7px;white-space:nowrap}
.gallery .picker-title img{display:block;align-self:center;width:19px;height:19px;flex:none;opacity:.65}
[data-theme=light] .gallery .picker-title img{filter:brightness(.35)}
.gallery .card-picker button[aria-pressed=true] .picker-title img{opacity:1}
.gallery .picker-title b,.gallery .picker-name{font:400 13px/20px Inter,'PingFang TC','PingFang SC',sans-serif;letter-spacing:.01em;color:inherit}
.gallery .picker-attribute{display:block;margin:0 0 0 1px;font:9px/20px Inter,sans-serif;letter-spacing:.025em;color:var(--muted)}
/* The stage and inspector each have their own space at desktop sizes. */
.gallery main{margin-left:var(--rail);margin-right:0;min-height:100svh;padding:110px 40px 78px;display:flex;flex-direction:column;align-items:center;justify-content:center;gap:0}
.gallery.inspector-open main{margin-right:var(--inspector)}
.gallery.inspector-open.flat-mode .capture-scene{display:block;overflow-x:auto;scrollbar-width:thin}
.gallery .capture-scene{position:relative;display:flex;align-items:center;justify-content:center;flex-direction:column;flex:none;max-width:100%}
.gallery:not(.flat-mode) .capture-scene{padding:34px;margin:-34px}
.gallery .stage{margin:0}
.gallery .controls{display:flex;align-items:center;justify-content:center;gap:14px;margin-top:30px}
.gallery:not(.flat-mode) .controls{margin-top:42px}
.gallery .controls button{display:flex;align-items:center;justify-content:center;gap:7px;padding:7px 12px;border:1px solid var(--line);border-radius:999px;background:var(--surface);color:var(--ink);font-size:11px;font-weight:400;line-height:18px}
.gallery .controls button:hover{background:var(--field)}
.gallery .controls button svg{width:14px;height:14px;fill:none;stroke:currentColor;stroke-width:1.4;stroke-linecap:round;stroke-linejoin:round}
.gallery .hint{font:11px/18px Inter,'PingFang TC',sans-serif;color:var(--muted);letter-spacing:0}
.gallery .status{position:absolute;width:1px;height:1px;padding:0;overflow:hidden;clip-path:inset(50%);white-space:nowrap}
.flat-gallery{display:grid;grid-template-columns:repeat(6,calc((var(--card-w) - 28px)/2));justify-content:center;gap:40px 28px;width:max-content;padding:26px 20px 40px}
.flat-card-entry{grid-column:span 2;width:var(--card-w)}.flat-card-entry:nth-child(4){grid-column:2 / span 2}.flat-card-entry:nth-child(5){grid-column:4 / span 2}
.gallery.flat-mode main{justify-content:center;min-height:calc(100svh - 68px);padding:112px 32px 36px}
.gallery footer{position:absolute;inset:auto 0 0;display:flex;align-items:center;justify-content:space-between;padding:24px 32px;color:var(--muted);font:9px/20px Inter,sans-serif;letter-spacing:.1em}
.gallery.flat-mode footer{position:relative;padding-top:12px}
.gallery footer nav{display:flex;align-items:center;gap:4px;padding:3px;border:1px solid var(--line);border-radius:999px;background:var(--surface)}
.gallery footer a{margin:0;padding:4px 10px;border-radius:999px;color:var(--muted);font-size:10px;line-height:16px;letter-spacing:0;text-decoration:none}
.gallery footer a:hover{color:var(--ink);background:var(--field)}.gallery footer a[aria-current=page]{color:var(--ink);background:var(--field)}
/* Softer contact at rest; the hover spring still adds lift and a broader shadow. */
.stage{transition:none;--hover-lift:0;--shadow-x:0px}
.gallery .face{box-shadow:var(--shadow-x) calc(18px + 24px*var(--hover-lift)) calc(32px + 34px*var(--hover-lift)) -16px rgb(0 0 0 / calc(.32 + .20*var(--hover-lift))),0 calc(2px + 4px*var(--hover-lift)) calc(5px + 7px*var(--hover-lift)) rgb(0 0 0 / calc(.14 + .12*var(--hover-lift))),0 0 0 .5px #a6a6a620}
[data-theme=light] .gallery .face{box-shadow:var(--shadow-x) calc(14px + 24px*var(--hover-lift)) calc(26px + 32px*var(--hover-lift)) -14px rgb(39 51 60 / calc(.14 + .12*var(--hover-lift))),0 calc(1px + 5px*var(--hover-lift)) calc(4px + 8px*var(--hover-lift)) rgb(39 51 60 / calc(.08 + .08*var(--hover-lift))),0 0 0 .5px #bac0c420}
/* Retain the small-card mask/compositing fix. */
.card,.stage{-webkit-user-select:none;user-select:none}
.gallery .artboard{transform:none;zoom:var(--scale);transform-style:flat}
.gallery .foil{transform:none}
.gallery .video{will-change:auto}
.flat-gallery .rotor{will-change:transform}.flat-card-entry:hover .rotor{will-change:transform}
/* Inspector controls share one neutral surface, spacing scale and type rhythm. */
.gallery .holo-settings{top:112px;right:32px;bottom:auto;width:336px;max-height:calc(100svh - 136px);padding:20px;gap:0;border:1px solid var(--line);border-radius:20px;background:var(--surface);color:var(--ink);box-shadow:0 20px 48px -24px #17171c30,0 3px 10px #17171c08;backdrop-filter:none}
.gallery .settings-heading{align-items:center;gap:12px;margin-bottom:12px}
.gallery .settings-heading h2{margin:0;font-size:15px;font-weight:500;line-height:24px;letter-spacing:0}
.gallery .settings-heading p{margin:3px 0 0;color:var(--muted);font-size:11px;line-height:18px}
.gallery .settings-close{width:28px;height:28px;flex:none;border:0;border-radius:8px;background:var(--field);color:var(--muted);font:20px/28px Inter,sans-serif}
.gallery .settings-close:hover{background:var(--hover);color:var(--ink)}
.gallery .settings-label{margin:0 0 7px;color:var(--muted);font-size:11px;font-weight:400;line-height:18px}
.gallery .holo-settings>label[for=holo-attribute]{position:absolute;width:1px;height:1px;overflow:hidden;clip-path:inset(50%);white-space:nowrap}
.gallery .holo-settings select{width:100%;min-height:38px;margin:0 0 12px;padding:8px 10px;border:1px solid var(--line);border-radius:9px;background:var(--field);color:var(--ink);font-size:12px;line-height:20px}
.gallery .material-tabs{gap:3px;margin:0 0 14px;padding:3px;border:1px solid var(--line);border-radius:10px;background:var(--field)}
.gallery .material-tabs button{padding:7px 6px;border:0;border-radius:7px;color:var(--muted);font-size:12px;font-weight:400;line-height:20px}
.gallery .material-tabs [aria-selected=true]{background:var(--surface);color:var(--ink);box-shadow:var(--ui-shadow)}
.gallery .settings-scroll{padding:0 3px 16px 0;mask-image:linear-gradient(#000 0%,#000 calc(100% - 14px),transparent);scrollbar-width:thin;scrollbar-color:#aaaaad50 transparent}
.gallery .effect-description{min-height:0;margin:-6px 0 6px;color:var(--muted);font-size:11px;line-height:18px}
.gallery .effect-reference{margin-bottom:16px;color:var(--muted);font-size:10px;text-underline-offset:3px}
.gallery .settings-field{align-items:center;gap:6px;margin-bottom:6px}.gallery .settings-field label{font-size:12px;line-height:20px;color:var(--ink)}
.gallery .settings-number{display:flex;align-items:center;gap:3px;padding:1px 5px;border:1px solid var(--line);border-radius:6px;background:var(--field);color:var(--muted);font-size:10px;line-height:20px}
.gallery .settings-number input{width:42px;min-height:20px;padding:0;border:0;border-radius:3px;background:transparent;color:var(--ink);font:12px/20px Inter,sans-serif;text-align:right;appearance:textfield}
.gallery .settings-number input::-webkit-inner-spin-button,.gallery .settings-number input::-webkit-outer-spin-button{appearance:none;margin:0}
.gallery .holo-settings input[type=range]{height:20px;margin:0 0 16px;accent-color:var(--ink)}
.gallery #border-basic{gap:16px}.gallery #border-basic label{font-size:11px}.gallery #border-basic .settings-field{gap:5px}
.gallery #border-basic .settings-number input{width:36px}
.gallery .material-details{margin-top:4px;padding-top:14px;border-color:var(--line)}
.gallery .material-details summary{margin-bottom:14px;color:var(--muted);font-size:11px;line-height:20px}
.gallery .settings-opacity-help{font-size:10px;line-height:18px;color:var(--muted)}
.gallery .settings-bottom{margin-top:12px;padding-top:12px;border-color:var(--line)}
.gallery .settings-bottom .settings-help{display:none}
.gallery .settings-actions{gap:8px}
.gallery .settings-actions button{min-height:36px;border:1px solid var(--line);border-radius:9px;background:var(--field);color:var(--ink);font-size:11px;font-weight:400;line-height:18px}
.gallery .settings-actions .settings-primary{background:var(--ink);color:var(--surface);border-color:transparent}
.gallery .settings-copy{min-height:32px;margin-top:8px;border:1px solid var(--line);border-radius:8px;background:transparent;color:var(--muted);font-size:11px;line-height:18px}
.gallery .settings-copy:hover{background:var(--field);color:var(--ink)}
.gallery .settings-status{margin:8px 0 0;min-height:16px;color:var(--muted);font-size:10px;line-height:16px}
.gallery .settings-bottom textarea{margin-top:10px;border-color:var(--line);border-radius:8px;background:var(--field);color:var(--ink)}
/* Recording remains outside capture and never changes the gallery layout. */
.gallery .record-controls{border-radius:16px;padding:12px 14px;gap:16px;background:var(--surface);border-color:var(--line);box-shadow:0 10px 30px #17171c0d}
.gallery .record-format select{font-size:12px}.gallery .record-primary{border-radius:9px;background:var(--ink);color:var(--surface);font-size:11px;font-weight:400}
.gallery .record-close{border-radius:8px}
:root[lang=en] .record-viewfinder::before{content:'Card recording area'}
:root[lang=en] .record-viewfinder[data-scope=page]::before{content:'Full-page recording area'}
@media(max-width:1100px){.gallery{--rail:248px}.collection-sidebar{left:24px;width:200px}.gallery header,.gallery footer{padding-inline:24px}.gallery main{padding-inline:32px}}
@media(max-width:1000px){.gallery.inspector-open main{margin-right:0}.gallery .holo-settings{top:auto;bottom:20px;right:20px;width:336px;max-height:62svh}.gallery.flat-mode .capture-scene{display:block;overflow-x:auto;scrollbar-width:thin}.flat-gallery{padding-inline:16px}}
@media(max-width:760px){
 .gallery{--rail:0px}.gallery header{position:relative;padding:20px 20px 12px;flex-wrap:wrap;gap:18px}.gallery .brand{font-size:min(54px,14vw)}.gallery .brand-caption{font-size:11px;line-height:18px;margin-top:6px}
 .gallery .header-actions{width:100%;justify-content:space-between;gap:8px}.creation-actions,.preference-controls{gap:5px}.preference-controls{padding-left:10px}.gallery .header-actions button{height:34px;padding-inline:8px;font-size:11px;gap:5px}.header-actions svg{width:14px;height:14px}
 .gallery .header-actions .sound-toggle{width:30px;min-width:30px;padding:6px}.language-control{height:34px;padding:0 9px;gap:5px}.language-control select{font-size:10px;min-width:59px;padding-right:12px}.language-control::after{right:9px;top:13px}.language-control>svg{width:12px;height:12px}
 .gallery .header-actions .theme-toggle{padding:0;width:34px}.theme-switch-label{display:none}.theme-switch-track{width:32px}.theme-toggle[aria-checked=true] .theme-switch-track i{transform:translateX(12px)}
 .collection-sidebar{position:static;transform:none;width:auto;margin:10px 20px 0;display:flex;flex-direction:row;align-items:center;gap:12px}.view-section{flex:none;width:132px}.collection-section{min-width:0;flex:1}.sidebar-heading{display:none}
 .view-toggle{padding:3px;gap:2px;border-radius:11px}.gallery .view-toggle button{height:36px;padding:0 4px;gap:4px;font-size:11px}.view-toggle svg{width:14px}:root[lang=en] .view-toggle svg{display:none}
 .gallery .collection-sidebar .card-picker{display:flex;flex-direction:row;gap:4px;padding:3px;overflow-x:auto;scrollbar-width:none;border-radius:12px}.gallery .card-picker button{width:auto;min-width:162px;min-height:36px;padding:7px 9px;border-radius:8px}.gallery .picker-title{gap:6px}.gallery .picker-title b,.gallery .picker-name{font-size:12px}.gallery .picker-attribute{font-size:8px}.gallery .picker-title img{width:17px;height:17px}
 .gallery main,.gallery.flat-mode main{margin:0;min-height:0;padding:38px 20px 48px}.gallery.flat-mode main{justify-content:flex-start}.gallery:not(.flat-mode) .capture-scene{padding:24px;margin:-24px}.gallery .controls{gap:10px;margin-top:24px}.gallery:not(.flat-mode) .controls{margin-top:30px}.gallery .hint{font-size:10px}
 .gallery footer,.gallery.flat-mode footer{position:relative;padding:16px 20px 20px;font-size:8px}.gallery footer a{padding:4px 8px;font-size:9px}
 .flat-gallery{gap:26px 20px;grid-template-columns:repeat(6,calc((var(--card-w) - 20px)/2));padding:20px 16px 24px}
 .gallery .holo-settings{left:16px;right:16px;bottom:16px;width:auto;max-height:58svh;border-radius:18px;padding:18px}.gallery .settings-heading{margin-bottom:14px}.gallery .effect-description,.gallery .effect-reference{display:none}
}
@media(max-width:380px){.gallery header{padding-inline:16px}.collection-sidebar{margin-inline:16px;gap:8px}.view-section{width:122px}.preference-controls{padding-left:6px}.gallery .header-actions{gap:5px}.gallery .header-actions button{padding-inline:8px}.language-control{padding-inline:7px;gap:4px}.language-control select{min-width:54px}.gallery .hint{max-width:165px;line-height:16px}.gallery main{padding-inline:16px}}
@media(max-height:650px) and (min-width:761px){.gallery header{padding-block:18px}.collection-sidebar{max-height:calc(100svh - 150px);overflow-y:auto;scrollbar-width:thin}.gallery main{padding-top:96px;padding-bottom:64px}.gallery .holo-settings{top:94px;max-height:calc(100svh - 112px)}.gallery footer{padding-block:16px}}
@media(prefers-reduced-motion:reduce){.gallery button,.theme-switch-track,.theme-switch-track i,.ui-tooltip{transition:none}}

[data-theme] body.gallery{background:var(--page)}
[data-theme] .gallery .card-picker button[aria-pressed=true] .picker-attribute{color:var(--muted)}

/* Ordered deck: real cards retain their coatings and sides while they gather. */
.gallery.deck-single .flat-gallery{display:block;position:relative;width:var(--card-w);height:calc(var(--card-w)*1.4);padding:0;overflow:visible}
.gallery.deck-single .flat-card-entry{position:absolute;left:calc(var(--deck-rank)*3px);top:calc(var(--deck-rank)*-4px);transform:translate3d(0,0,0) scale(var(--deck-scale));transform-origin:0 0}
.flat-card-entry{position:relative;transform:translate3d(0,0,0) scale(1);transform-origin:0 0;will-change:transform}
.gallery.layout-in-motion .capture-scene{overflow:visible}
.gallery.layout-in-motion .flat-card-entry{pointer-events:none;will-change:transform}
.gallery.layout-in-motion .controls{pointer-events:none}
.gallery.deck-single .flat-card-entry[aria-hidden=true]{pointer-events:none}

/* Keep the same compositor surfaces before, during and after a layout move.
   Only the rear cards are concealed; their SVGs and coatings stay allocated. */
.stack-slide{width:100%;height:calc(var(--card-w)*1.4);transform:translate3d(0,0,0);opacity:1}
.gallery.deck-single .flat-card-entry[aria-hidden=true] .stack-slide{--stack-delay:calc((var(--deck-rank) - 1)*45ms);transition:transform .42s cubic-bezier(.22,.68,.15,1) var(--stack-delay),opacity .14s linear var(--stack-delay)}
.gallery.deck-single .flat-gallery.deck-engaged .flat-card-entry[aria-hidden=true] .stack-slide{transform:translate3d(0,calc(var(--deck-rank)*4px + 2px),0);opacity:0;transition-delay:var(--stack-delay),calc(220ms + var(--stack-delay))}
.gallery.deck-single .flat-gallery.deck-turning .flat-card-entry[aria-hidden=true] .stack-slide{opacity:0;transition-duration:.25s,.06s;transition-delay:0s}

/* Fan layout: a continuous, centred selection with two cards on either side. */
.gallery .view-toggle button{padding-inline:6px;gap:4px;font-size:11px}.view-toggle svg{width:16px}:root[lang=en] .view-toggle svg{display:none}
.gallery.fan-mode .flat-gallery{display:block;position:relative;width:calc(var(--card-w)*2.8);height:calc(var(--card-w)*1.85);padding:0;overflow:visible}
.gallery.fan-mode .flat-card-entry{position:absolute;left:calc(50% - var(--card-w)/2);top:calc(var(--card-w)*.13);transform:translate3d(calc(var(--fan-distance)*var(--fan-spread)),calc(var(--fan-depth)*var(--card-w)*.10),0) translate(calc(var(--card-w)/2),calc(var(--card-w)*1.4)) rotate(var(--fan-angle)) scale(var(--fan-scale)) translate(calc(var(--card-w)*-.5),calc(var(--card-w)*-1.4));transform-origin:0 0}
.gallery.fan-mode .capture-scene{padding:20px 0;margin:0;overflow:visible}
.gallery.fan-mode .controls{margin-top:12px;transform-origin:0 0}.gallery .controls{transform-origin:0 0}
.gallery .fan-navigation{display:flex;align-items:center;justify-content:center;gap:14px;margin-top:14px;color:var(--muted)}
.gallery .fan-navigation[hidden]{display:none}.fan-navigation span{font:10px/20px Inter,sans-serif;font-variant-numeric:tabular-nums}
.gallery .fan-navigation button{display:flex;align-items:center;justify-content:center;width:34px;height:30px;padding:0;border:1px solid var(--line);border-radius:8px;background:var(--surface);color:var(--ink);box-shadow:0 2px 0 var(--line)}
.gallery .fan-navigation button:hover{background:var(--field)}.fan-navigation kbd{font:14px/20px Inter,sans-serif}
@media(max-width:760px){.gallery .collection-sidebar{flex-direction:column;align-items:stretch;gap:8px}.gallery .collection-sidebar .view-section,.gallery .collection-sidebar .collection-section{width:100%}.gallery .view-toggle button{height:32px}.gallery.fan-mode main{padding-top:30px}.gallery.fan-mode .controls{margin-top:12px}.gallery .fan-navigation{margin-top:12px}}
@media(prefers-reduced-motion:reduce){.gallery.deck-single .flat-card-entry[aria-hidden=true] .stack-slide{transition:none}}

.gallery .header-actions .language-toggle{border:1px solid var(--line);background:var(--surface);padding:0 12px;gap:7px;color:var(--ink);font-size:11px}
.language-control::after{display:none}.language-toggle [data-language-label]{line-height:20px;white-space:nowrap}
@media(max-width:760px){.gallery .header-actions .language-toggle{height:34px;padding:0 9px;gap:5px;font-size:10px}}

@media(min-width:761px){.gallery header{align-items:flex-start}.gallery .header-actions{padding-top:0;margin-top:calc(60px*1.08 - 44px)}}

@media(min-width:761px) and (max-width:820px){.gallery .header-actions{gap:12px}.gallery .creation-actions button{padding-inline:10px;font-size:11px}.gallery .preference-controls{padding-left:10px;gap:5px}}

.gallery .header-actions .language-toggle{width:96px;flex:0 0 96px;justify-content:center}
.deck-opening #single-scene{visibility:hidden}
@media(max-width:760px){.gallery .header-actions .language-toggle{width:88px;flex-basis:88px}}

.gallery.flat-mode .flat-gallery{grid-template-columns:repeat(6,calc((var(--card-w) - 24.64px)/2));gap:35.2px 24.64px;padding:22.88px 17.6px 35.2px}
@media(max-width:760px){.gallery.flat-mode .flat-gallery{grid-template-columns:repeat(6,calc((var(--card-w) - 17.6px)/2));gap:22.88px 17.6px;padding:17.6px 14.08px 21.12px}}

@media(max-width:760px){
 .gallery .stage{touch-action:pan-y pinch-zoom}
 .gallery.flat-mode .flat-gallery{grid-template-columns:repeat(2,var(--card-w));gap:22.88px 17.6px;padding:17.6px 14.08px 21.12px}
 .gallery.flat-mode .flat-card-entry{grid-column:auto}
 .gallery.flat-mode .flat-card-entry:last-child{grid-column:1 / -1;justify-self:center}
 .gallery .collection-sidebar{align-items:stretch;flex-direction:column;gap:8px}
 .gallery .view-section{width:100%}
}

.flat-card-entry[data-renderable=false]{visibility:hidden;pointer-events:none}

@media(min-width:761px){.gallery .collection-sidebar .card-picker{max-height:calc(100svh - 330px);overflow-y:auto;scrollbar-width:thin;overscroll-behavior:contain}}

/* The footer must not intercept the fan navigation beneath its empty area. */
.gallery footer{pointer-events:none}
.gallery footer nav{pointer-events:auto}

/* The deck remains visible while the outgoing card is passed beneath it. */
.gallery.deck-cutting .stack-slide{opacity:1!important;transform:translate3d(0,0,0)!important;transition:none!important}

/* Keep the flip action and hint in one stable viewport position. */
.gallery .controls{position:fixed;left:50%;bottom:24px;z-index:20;width:max-content;max-width:calc(100vw - 32px);transform:translateX(-50%);margin-top:30px!important;margin-bottom:0}
@media(max-width:760px){.gallery .controls{bottom:calc(16px + env(safe-area-inset-bottom,0px));padding:6px 10px;border-radius:999px;background:var(--page)}.gallery footer,.gallery.flat-mode footer{padding-bottom:80px}}

.gallery .picker-separator{color:var(--muted);font-size:11px;margin-inline:-2px}

:root:not([lang=en]) .gallery .picker-attribute{font-size:13px;line-height:20px;letter-spacing:.01em}
@media(max-width:760px){:root:not([lang=en]) .gallery .picker-attribute{font-size:12px}}
