/* No renderer or CAD package is loaded until a project is opened. */
body:not([data-release-page=viewer]) > :is(.projectbar,.studio,.statusbar,#release-dialog,#package-file){display:none}
body:not([data-release-page=viewer]) .top-actions :is(#open,#download-glb,#download,#release-button,.gallery-back){display:none}
body[data-release-page=viewer] #release-gallery{display:none}
.gallery-back{font-size:12px;padding:10px 12px;color:inherit;border:1px solid var(--line);border-radius:7px;white-space:nowrap}
#release-gallery{max-width:1480px;margin:0 auto;padding:32px clamp(16px,3vw,44px) 48px}
.gallery-heading{display:flex;align-items:center;justify-content:space-between;gap:24px;margin-bottom:22px}
.gallery-heading h1{font-size:30px;letter-spacing:-1px;margin:8px 0}.gallery-heading p{font-size:13px;color:var(--muted);margin:0;line-height:1.5}
.gallery-search input{width:270px;max-width:100%;min-height:44px;padding:12px 16px;border:1px solid var(--line);border-radius:9px;background:var(--surface,#fff);color:var(--ink);font-size:13px}
.gallery-controls{display:flex;justify-content:space-between;align-items:center;gap:16px;flex-wrap:wrap}
.gallery-filters{display:flex;gap:6px;flex-wrap:wrap}.gallery-filters button{min-height:40px}.gallery-iterations{display:flex;gap:7px;align-items:center;font-size:12px;color:var(--muted);min-height:40px}.gallery-iterations input{accent-color:var(--accent)}
#gallery-count{font-size:11px;color:var(--muted);margin:18px 0 12px}
.gallery-grid{display:grid;grid-template-columns:repeat(3,minmax(0,1fr));gap:20px}
.gallery-card{min-width:0;overflow:hidden;border:1px solid var(--line);border-radius:14px;background:var(--surface,#fff);display:flex;flex-direction:column;box-shadow:0 4px 18px #00000008}
.gallery-cover{position:relative;display:block;aspect-ratio:1200/630;overflow:hidden;background:#191b1e}.gallery-cover img{display:block;width:100%;height:100%;object-fit:contain;transition:transform .2s ease}.gallery-cover:hover img{transform:scale(1.025)}
.gallery-open{position:absolute;bottom:12px;right:12px;padding:8px 11px;font-size:11px;border-radius:7px;border:1px solid #ffffff35;color:#fff;background:#111114df;opacity:0;transition:opacity .15s}.gallery-cover:is(:hover,:focus-visible) .gallery-open{opacity:1}
.gallery-card-body{padding:18px;display:flex;flex-direction:column;flex:1}.gallery-card-meta{display:flex;justify-content:space-between;gap:12px;color:var(--muted);font-size:10px}.gallery-card-meta>span:first-child{text-transform:uppercase;letter-spacing:1.2px}
.gallery-card h2{font-size:18px;line-height:1.3;letter-spacing:-.35px;margin:12px 0 8px}.gallery-card h2 a{color:var(--ink)}.gallery-card p{font-size:12px;line-height:1.6;color:var(--muted);margin:0 0 18px;display:-webkit-box;-webkit-line-clamp:3;-webkit-box-orient:vertical;overflow:hidden}
.gallery-card footer{display:flex;justify-content:space-between;gap:12px;margin-top:auto;padding-top:14px;border-top:1px solid var(--line);font-size:11px}.gallery-card small{font-size:10px;color:var(--muted);margin-top:9px;line-height:1.4}.gallery-card footer a{font-weight:650}
[data-theme=dark] .gallery-card{background:linear-gradient(135deg,#ffffff06,transparent),#151518;border-color:#ffffff20}[data-theme=dark] .gallery-search input{background:#19191e}
.sr-only{position:absolute;width:1px;height:1px;padding:0;margin:-1px;overflow:hidden;clip:rect(0,0,0,0);white-space:nowrap;border:0}
@media(max-width:1000px){.gallery-grid{grid-template-columns:repeat(2,minmax(0,1fr))}}
@media(max-width:600px){#release-gallery{padding-top:20px}.gallery-heading{display:block;margin-bottom:14px}.gallery-heading h1{font-size:26px}.gallery-search{display:block;margin-top:16px}.gallery-search input{width:100%}.gallery-controls{gap:4px}.gallery-filters{gap:4px}.gallery-filters button{padding:9px;font-size:11px}.gallery-grid{grid-template-columns:1fr}.gallery-open{opacity:1}body[data-release-page=gallery] .topbar{min-height:60px;padding:10px 14px}body[data-release-page=gallery] .assembly-link{font-size:11px!important;padding:9px!important}.gallery-card-body{padding:16px}}
@media(prefers-reduced-motion:reduce){.gallery-cover img,.gallery-open{transition:none}}
