.gallery-toolbar{display:flex;align-items:center;flex-wrap:wrap;gap:18px;border-bottom:1px solid var(--line);padding-bottom:22px;margin-bottom:28px}.gallery-toolbar>p{margin-right:auto;color:#777;font-size:13px}.gallery-toolbar .button{gap:16px}.gallery-grid{display:grid;grid-template-columns:repeat(3,minmax(0,1fr));gap:32px 22px}.gallery-card{min-width:0}.gallery-open{display:block;width:100%;text-align:left;background:white;border:0;padding:0}.gallery-cover{position:relative;aspect-ratio:1/1;overflow:hidden;background:#f2f3f5}.gallery-cover img{width:100%;height:100%;object-fit:contain;padding:16px;transition:transform .2s}.gallery-open:hover img{transform:scale(1.025)}.gallery-cover>span{position:absolute;bottom:12px;right:12px;background:rgba(0,0,0,.72);color:white;font-size:11px;border-radius:3px;padding:5px 8px}.gallery-open h2{font-size:17px;line-height:1.6;margin:15px 0 5px;overflow-wrap:anywhere}.gallery-open time{font-size:11px;color:#888}.gallery-card-tools{display:flex;gap:18px;margin-top:10px}.gallery-card-tools button{font-size:11px;color:#777}.gallery-card-tools button:last-child{color:#aa2929}.gallery-empty{padding:75px 20px;text-align:center;border:1px solid var(--line);background:#fafbfc}.gallery-empty>.icon{width:38px;height:38px;margin:0 auto 18px;display:block;color:#a6abb2}.gallery-empty h2{font-size:20px;margin-bottom:10px}.gallery-empty p{color:#888;font-size:13px;line-height:1.8}.gallery-more{text-align:center;margin-top:34px}.gallery-more:has(button[hidden]){display:none}.gallery-admin-hint{font-size:11px;color:#888;margin-top:32px;line-height:2}.gallery-admin-hint a{text-decoration:underline;margin-left:12px;color:#555}.gallery-error{color:#ab2121;background:#fff5f5;border:1px solid #f0d9d9;padding:13px 16px;font-size:12px;line-height:1.8;margin:15px 0;overflow-wrap:anywhere}.gallery-viewer{width:min(960px,calc(100% - 32px));padding:26px;max-height:92vh}.gallery-viewer .dialog-heading h2{overflow-wrap:anywhere;line-height:1.5;font-size:21px}.gallery-viewer .dialog-close{flex-shrink:0}.gallery-stage{position:relative;width:min(100%,58vh);aspect-ratio:1/1;margin-inline:auto;overflow:hidden;background:#f4f5f6}.gallery-stage>img{position:absolute;inset:0;display:block;width:100%;height:100%;object-fit:contain;padding:16px}.gallery-arrow{position:absolute;z-index:1;top:50%;transform:translateY(-50%);border:1px solid #ddd;border-radius:50%;width:42px;height:42px;font-size:30px;line-height:1;background:rgba(255,255,255,.9)}#gallery-prev{left:12px}#gallery-next{right:12px}.gallery-arrow:disabled{opacity:.35}.gallery-photo-count{font-size:11px;color:#777;text-align:center;margin-top:12px}.gallery-thumbnails{display:flex;gap:8px;overflow-x:auto;padding:7px 3px 9px;scrollbar-width:thin;margin-top:7px}.gallery-thumbnails button{padding:2px;background:white;border:1px solid #ddd;flex:0 0 72px}.gallery-thumbnails button[aria-pressed=true]{border:2px solid var(--blue);padding:1px}.gallery-thumbnails img{display:block;width:66px;height:66px;object-fit:contain;background:#f2f3f5}.gallery-view-description{white-space:pre-wrap;overflow-wrap:anywhere;font-size:13px;line-height:1.9;margin-top:20px}.gallery-view-date{font-size:11px;color:#888;margin-top:12px}.gallery-editor{width:min(620px,calc(100% - 32px));padding:30px;max-height:92vh}.gallery-editor .dialog-heading{margin-bottom:26px}.gallery-editor .inquiry-form input[type=file]{background:#f8f9fb;border:1px dashed #bbc2cb;width:100%;padding:14px}.gallery-file-help{font-size:11px;color:#777;line-height:1.9;margin-top:10px}.gallery-previews{display:grid;grid-template-columns:repeat(5,minmax(0,1fr));gap:8px;margin-top:13px}.gallery-previews:empty{display:none}.gallery-previews figure{position:relative;margin:0;min-width:0}.gallery-previews img{display:block;width:100%;height:auto;aspect-ratio:1/1;object-fit:contain;border:1px solid #ddd;background:#eee}.gallery-previews figcaption{position:absolute;bottom:1px;left:1px;right:1px;background:rgba(0,0,0,.65);color:white;font-size:9px;padding:3px 5px;text-align:center}.gallery-dialog-actions{display:flex;gap:10px;justify-content:flex-end;border-top:1px solid var(--line);padding-top:20px;margin-top:22px}.gallery-dialog-actions .button{min-width:100px;background:white}.gallery-dialog-actions .button-black{background:#111}.gallery-dialog-actions .button-black:hover{background:#363636}.gallery-editor button:disabled,.gallery-delete-dialog button:disabled{opacity:.5;cursor:wait}.gallery-delete-dialog{width:min(500px,calc(100% - 32px));padding:28px}.gallery-delete-dialog .dialog-heading h2{font-size:20px;line-height:1.5}.gallery-delete-dialog .dialog-close{flex-shrink:0}#gallery-delete-title{font-size:15px;font-weight:700;overflow-wrap:anywhere;margin-top:24px}.gallery-dialog-actions .gallery-delete-button{background:#a92727;color:white;border-color:#a92727}
@media(max-width:1024px){.gallery-grid{grid-template-columns:repeat(2,minmax(0,1fr));gap:26px 18px}}
@media(max-width:640px){.gallery-grid{grid-template-columns:1fr;gap:28px}.gallery-toolbar{gap:15px;margin-bottom:22px}.gallery-toolbar>p{width:100%;font-size:12px}.gallery-toolbar .button{margin-left:auto}.gallery-open h2{font-size:17px}.gallery-empty{padding:50px 18px}.gallery-empty h2{font-size:18px}.gallery-empty p{font-size:11px}.gallery-viewer{padding:20px 16px}.gallery-viewer .dialog-heading h2{font-size:18px}.gallery-stage{width:min(100%,50vh)}.gallery-arrow{width:34px;height:34px;font-size:25px}#gallery-prev{left:7px}#gallery-next{right:7px}.gallery-editor{padding:25px 20px}.gallery-previews{grid-template-columns:repeat(3,minmax(0,1fr))}.gallery-editor .inquiry-form input[type=file]{font-size:12px}.gallery-admin-hint a{display:inline-block;margin-left:0;margin-right:8px}.gallery-admin-hint{font-size:10px}.gallery-delete-dialog{padding:24px 20px}.gallery-delete-dialog .dialog-heading h2{font-size:18px}}
@media(prefers-reduced-motion:reduce){.gallery-cover img{transition:none}}
