.gallery-section{padding-block:42px 60px}.gallery-heading{max-width:720px;margin:0 auto 28px;text-align:center}.gallery-heading .eyebrow{color:var(--accent,#ffd500);font-weight:900;letter-spacing:.12em;text-transform:uppercase}.gallery-heading h2{margin:4px 0 8px;font-size:clamp(1.8rem,4vw,3rem)}.gallery-heading p{margin:0;color:var(--muted,#9ca3af)}.gallery-grid{display:grid;grid-template-columns:repeat(4,minmax(0,1fr));gap:18px}.gallery-card{overflow:hidden;border:1px solid var(--line,#30343b);border-radius:16px;background:var(--panel,#17191d);box-shadow:0 12px 30px #0003;transition:transform .2s,border-color .2s,box-shadow .2s}.gallery-card:hover{transform:translateY(-4px);border-color:#ffd500;box-shadow:0 16px 38px #0005,0 0 20px #ffd50020}.gallery-open{position:relative;display:block;width:100%;padding:0;border:0;background:#07090c;cursor:pointer}.gallery-open img{display:block;width:100%;aspect-ratio:1/1;object-fit:cover;transition:transform .3s}.gallery-card:hover .gallery-open img{transform:scale(1.025)}.gallery-zoom{position:absolute;inset:auto 12px 12px auto;display:grid;place-items:center;width:38px;height:38px;border-radius:50%;background:#111c;color:#fff;font-size:24px;backdrop-filter:blur(8px)}.gallery-info{display:grid;grid-template-columns:1fr auto;gap:10px;padding:14px}.gallery-info h3{grid-column:1/-1;margin:0;overflow:hidden;text-overflow:ellipsis;white-space:nowrap;font-size:1rem}.gallery-download{display:inline-flex;align-items:center;gap:6px;color:#111;background:#ffd500;padding:8px 11px;border-radius:9px;text-decoration:none;font-weight:900;font-size:.78rem}.gallery-count{align-self:center;color:var(--muted,#a4adba);font-size:.76rem;white-space:nowrap}.gallery-empty{grid-column:1/-1;padding:65px 20px;border:1px dashed var(--line,#343943);border-radius:16px;text-align:center;color:var(--muted,#a4adba)}.gallery-lightbox[hidden]{display:none}.gallery-lightbox{position:fixed;z-index:100000;inset:0;display:grid;place-items:center;padding:64px 72px 80px;background:#05070aee;backdrop-filter:blur(14px)}.gallery-lightbox figure{display:grid;max-width:min(1500px,100%);max-height:100%;margin:0}.gallery-lightbox img{display:block;max-width:100%;max-height:calc(100vh - 175px);margin:auto;object-fit:contain;box-shadow:0 20px 70px #000;border-radius:8px}.gallery-lightbox figcaption{display:flex;align-items:center;justify-content:space-between;gap:16px;margin-top:13px;color:#fff}.gallery-lightbox-title{min-width:0;overflow:hidden;text-overflow:ellipsis;white-space:nowrap;font-weight:800}.gallery-lightbox-download{padding:10px 15px;border-radius:9px;background:#ffd500;color:#111;text-decoration:none;font-weight:900;white-space:nowrap}.gallery-lightbox button{position:absolute;display:grid;place-items:center;border:1px solid #fff5;background:#15191fd9;color:#fff;cursor:pointer;box-shadow:0 8px 25px #0008}.gallery-lightbox-close{top:18px;right:18px;width:46px;height:46px;border-radius:50%;font-size:25px}.gallery-lightbox-prev,.gallery-lightbox-next{top:50%;width:48px;height:58px;border-radius:14px;font-size:33px}.gallery-lightbox-prev{left:15px}.gallery-lightbox-next{right:15px}.gallery-modal-open{overflow:hidden}html[data-theme=light] .gallery-card{background:#fff;border-color:#d8dee8;box-shadow:0 12px 28px #28374a18}@media(max-width:1000px){.gallery-grid{grid-template-columns:repeat(3,minmax(0,1fr))}}@media(max-width:720px){.gallery-section{padding-block:25px 45px}.gallery-grid{grid-template-columns:repeat(2,minmax(0,1fr));gap:10px}.gallery-info{display:flex;flex-direction:column;gap:8px;padding:10px}.gallery-download{justify-content:center;padding:8px 5px;font-size:.67rem}.gallery-count{text-align:center;font-size:.68rem}.gallery-lightbox{padding:55px 10px 75px}.gallery-lightbox img{max-height:calc(100vh - 160px)}.gallery-lightbox figcaption{align-items:stretch;flex-direction:column}.gallery-lightbox-download{text-align:center}.gallery-lightbox-prev,.gallery-lightbox-next{top:auto;bottom:14px;width:44px;height:44px}.gallery-lightbox-prev{left:12px}.gallery-lightbox-next{right:12px}.gallery-lightbox-close{top:10px;right:10px}}

/* GALLERY SEARCH SORT COUNTER V3 */
.gallery-tools{display:grid;grid-template-columns:minmax(240px,1fr) minmax(180px,260px);gap:12px;margin:0 0 22px;padding:14px;border:1px solid var(--line,#30343b);border-radius:14px;background:var(--panel,#17191d)}
.gallery-tools label{display:grid;gap:5px}.gallery-tools label>span{color:var(--muted,#a4adba);font-size:.72rem;font-weight:900;text-transform:uppercase}
.gallery-tools input,.gallery-tools select{width:100%;height:44px;padding:0 13px;border:1px solid var(--line,#3a414c);border-radius:9px;background:#0e1117;color:#fff;font:700 .9rem system-ui;outline:0}
.gallery-tools input:focus,.gallery-tools select:focus{border-color:#ffd500;box-shadow:0 0 0 3px #ffd50020}
.gallery-count{display:inline-flex!important;align-items:center;justify-content:center;gap:5px;min-width:62px;padding:7px 9px;border:1px solid var(--line,#38404c);border-radius:999px;background:#0e1117;color:var(--muted,#c0c7d2)!important;font-weight:850;white-space:nowrap}
html[data-theme=light] .gallery-tools{background:#fff;border-color:#d8dee8;box-shadow:0 12px 28px #28374a18}
html[data-theme=light] .gallery-tools input,html[data-theme=light] .gallery-tools select,html[data-theme=light] .gallery-count{background:#f5f7fa;color:#172033!important;border-color:#cfd7e2}
@media(max-width:720px){.gallery-tools{grid-template-columns:1fr;padding:10px}.gallery-tools input,.gallery-tools select{height:42px}}

/* GALLERY PERSISTENT FAVORITES V1 */
.gallery-tools{grid-template-columns:minmax(220px,1fr) minmax(170px,250px) auto}
.gallery-favorites-filter{align-self:end;display:inline-flex;align-items:center;justify-content:center;gap:7px;height:44px;padding:0 14px;border:1px solid var(--line,#3a414c);border-radius:10px;background:#111722;color:#fff;font:850 .82rem system-ui;cursor:pointer;white-space:nowrap;transition:.18s ease}
.gallery-favorites-filter>span:first-child{color:#ff5265;font-size:18px}.gallery-favorites-filter .favorite-total{display:grid;place-items:center;min-width:23px;height:23px;padding:0 6px;border-radius:999px;background:#263246;color:#fff;font-size:11px}.gallery-favorites-filter:hover,.gallery-favorites-filter.active{border-color:#ff5265;background:#28141a;box-shadow:0 0 18px #ff526533}.gallery-favorites-filter.active .favorite-total{background:#ff5265}
.gallery-card{position:relative}.gallery-favorite{position:absolute;z-index:5;top:10px;left:10px;display:grid;place-items:center;width:40px;height:40px;padding:0;border:1px solid #fff5;border-radius:50%;background:#0b0f16d9;color:#fff;font-size:20px;cursor:pointer;box-shadow:0 6px 18px #0007;backdrop-filter:blur(8px);transition:.18s ease}.gallery-favorite:hover{transform:scale(1.06);border-color:#ff7180;color:#ff7180}.gallery-favorite.active{border-color:#ff5265;background:#ff5265;color:#fff;box-shadow:0 0 20px #ff526577}
.gallery-lightbox figure{position:relative}.gallery-lightbox-favorite{position:static!important;display:inline-flex!important;align-items:center;justify-content:center;gap:8px;width:auto!important;height:42px!important;margin:10px auto 0;padding:0 15px!important;border-radius:999px!important;font:850 13px system-ui!important}.gallery-lightbox-favorite>span{font-size:19px}.gallery-lightbox-favorite.active{border-color:#ff5265!important;background:#ff5265!important;color:#fff!important;box-shadow:0 0 22px #ff526566!important}
html[data-theme=light] .gallery-favorites-filter{background:#fff;color:#172033;border-color:#cfd7e2}html[data-theme=light] .gallery-favorites-filter:hover,html[data-theme=light] .gallery-favorites-filter.active{border-color:#ff5265;background:#fff3f5}
@media(max-width:820px){.gallery-tools{grid-template-columns:1fr 1fr}.gallery-favorites-filter{grid-column:1/-1;width:100%}}
@media(max-width:720px){.gallery-tools{grid-template-columns:1fr}.gallery-favorites-filter{grid-column:auto}.gallery-favorite{top:6px;left:6px;width:34px;height:34px;font-size:17px}.gallery-lightbox-favorite{width:100%!important}}

/* GALLERY DOWNLOAD ACTION REDESIGN V9 */
.gallery-info{display:block;padding:14px}
.gallery-info h3{margin:0 0 12px;padding-bottom:11px;border-bottom:1px solid var(--line,#30343b);font-size:1.02rem;line-height:1.35}
.gallery-actions{display:flex;align-items:center;gap:10px;direction:ltr}
.gallery-download{display:inline-flex;flex:1;align-items:center;justify-content:center;gap:9px;min-width:0;min-height:44px;padding:8px 13px;border-radius:11px;font-size:.9rem;font-weight:950;line-height:1;letter-spacing:.01em;box-shadow:0 7px 18px #ffd50020;transition:transform .18s ease,box-shadow .18s ease,filter .18s ease}
.gallery-download:hover{transform:translateY(-1px);filter:brightness(1.04);box-shadow:0 10px 24px #ffd50038}
.gallery-download-icon{display:block;width:18px;height:18px;flex:0 0 auto;fill:none;stroke:currentColor;stroke-width:2;stroke-linecap:round;stroke-linejoin:round}
.gallery-count{align-self:auto;display:inline-flex!important;align-items:center;justify-content:center;gap:7px;min-width:72px;min-height:44px;padding:0 12px;border-radius:11px;background:#0e1117;color:#e3e8ef!important;font-size:.84rem;font-weight:900;font-variant-numeric:tabular-nums}
.gallery-count .gallery-download-icon{width:17px;height:17px;color:#ffd500}
.gallery-count strong{font-size:.88rem;line-height:1}
html[lang="ckb"] .gallery-download,html[lang="ar"] .gallery-download,html[lang="fa"] .gallery-download{direction:rtl}
html[lang="ckb"] .gallery-download span{font-size:1rem;font-weight:950}
.gallery-lightbox-download{display:inline-flex;align-items:center;justify-content:center;gap:8px}
.gallery-lightbox-download .gallery-download-icon{width:18px;height:18px}
html[data-theme=light] .gallery-info h3{border-color:#d8dee8}
html[data-theme=light] .gallery-count{background:#f5f7fa;color:#172033!important;border-color:#cfd7e2}
@media(max-width:720px){
  .gallery-info{display:block;padding:10px}
  .gallery-info h3{margin-bottom:9px;padding-bottom:8px;font-size:.9rem}
  .gallery-actions{gap:7px}
  .gallery-download{min-height:40px;padding:7px 8px;font-size:.79rem}
  html[lang="ckb"] .gallery-download span{font-size:.9rem}
  .gallery-count{min-width:60px;min-height:40px;padding:0 9px;gap:5px;font-size:.75rem}
  .gallery-count strong{font-size:.78rem}
  .gallery-download-icon,.gallery-count .gallery-download-icon{width:16px;height:16px}
}

/* PROFESSIONAL FAVORITE ICON V10 */
.gallery-heart-icon{display:block;width:20px;height:20px;fill:transparent;stroke:currentColor;stroke-width:1.9;stroke-linecap:round;stroke-linejoin:round;transition:fill .18s ease,transform .18s ease}
.gallery-favorite:hover .gallery-heart-icon,.gallery-favorites-filter:hover .gallery-heart-icon{transform:scale(1.08)}
.gallery-favorite.active .gallery-heart-icon,.gallery-favorites-filter.active .gallery-heart-icon,.gallery-lightbox-favorite.active .gallery-heart-icon{fill:currentColor}
.gallery-favorites-filter>.gallery-heart-icon{width:18px;height:18px;color:#ff5265}
.gallery-lightbox-favorite>.gallery-heart-icon{width:19px;height:19px}
@media(max-width:720px){
  .gallery-favorite{width:34px;height:34px;top:7px;left:7px;background:#080b11f2;border:2px solid #fff;color:#fff;box-shadow:0 5px 16px #000a}
  .gallery-favorite .gallery-heart-icon{width:17px;height:17px}
}

/* GALLERY 4 x 5 PAGINATION V11 */
.gallery-pagination{margin:30px 0 6px;direction:ltr!important}
.gallery-pagination[hidden]{display:none!important}

/* FOUR GALLERY COLUMNS ON MOBILE V13 */
@media(max-width:1000px){
  #gallery .gallery-grid,.gallery-section .gallery-grid{display:grid!important;grid-template-columns:repeat(4,minmax(0,1fr))!important;gap:5px!important}
  .gallery-card{border-radius:8px}
  .gallery-info{padding:5px}
  .gallery-info h3{margin-bottom:5px;padding-bottom:4px;font-size:.61rem;line-height:1.25}
  .gallery-actions{display:grid;grid-template-columns:1fr;gap:4px}
  .gallery-download,.gallery-count{width:100%;min-width:0;min-height:27px;padding:3px 4px;border-radius:6px;font-size:.56rem}
  html[lang="ckb"] .gallery-download span{font-size:.62rem}
  .gallery-download-icon,.gallery-count .gallery-download-icon{width:12px;height:12px}
  .gallery-favorite{width:27px;height:27px;top:4px;left:4px}
  .gallery-favorite .gallery-heart-icon{width:14px;height:14px}
  .gallery-zoom{right:5px;bottom:5px;width:25px;height:25px;font-size:16px}
}
