@charset "UTF-8";

/* ==========================================================================
   CÁ'S HOUSE — GALLERY PAGE STYLES
   Cute, Handcrafted, Responsive & Interactive Media Grid
   ========================================================================== */

.gallery-page {
  background: radial-gradient(circle at 50% 15%, #ebf6ff 0%, #fbfdfe 65%);
  min-height: 100vh;
}

/* --------------------------------------------------------------------------
   Gallery Hero Banner
   -------------------------------------------------------------------------- */
.gallery-hero {
  padding: 48px 0 28px;
  text-align: center;
  position: relative;
}

.gallery-hero .eyebrow-pill {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  background: var(--blue-pale);
  border: 1px solid var(--blue-cloud);
  padding: 6px 16px;
  border-radius: var(--radius-pill);
  font-size: 13px;
  font-weight: 600;
  color: var(--ink-soft);
  margin-bottom: 14px;
}

.gallery-hero h1 {
  font-family: var(--font-display);
  font-size: clamp(32px, 4.5vw, 52px);
  color: var(--ink);
  line-height: 1.25;
  margin: 0 0 16px;
}

.gallery-hero h1 em {
  font-style: normal;
  color: var(--pink-accent);
  position: relative;
}

.gallery-hero .gallery-sub {
  font-size: 16px;
  color: var(--ink-soft);
  max-width: 640px;
  margin: 0 auto 24px;
  line-height: 1.6;
}

.gallery-stats {
  display: inline-flex;
  flex-wrap: wrap;
  justify-content: center;
  gap: 12px;
  margin-bottom: 12px;
}

.stat-chip {
  background: var(--white);
  border: 1px solid var(--line);
  padding: 7px 16px;
  border-radius: var(--radius-pill);
  font-size: 13px;
  font-weight: 700;
  color: var(--ink);
  box-shadow: var(--shadow-sm);
  display: inline-flex;
  align-items: center;
  gap: 6px;
  transition: transform 0.2s, box-shadow 0.2s;
}

.stat-chip:hover {
  transform: translateY(-2px);
  box-shadow: var(--shadow-md);
}

/* --------------------------------------------------------------------------
   Search & Filter Toolbar
   -------------------------------------------------------------------------- */
.gallery-toolbar {
  position: sticky;
  top: 94px;
  z-index: 80;
  background: rgba(251, 253, 254, 0.92);
  backdrop-filter: blur(16px);
  -webkit-backdrop-filter: blur(16px);
  border-radius: var(--radius-lg);
  padding: 16px 20px;
  margin-bottom: 32px;
  border: 1px solid var(--line);
  box-shadow: 0 10px 30px rgba(20, 64, 98, 0.08);
  transition: all 0.3s ease;
}

.gallery-toolbar-top {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 14px;
  justify-content: space-between;
}

.gallery-search-box {
  position: relative;
  flex: 1 1 320px;
  display: flex;
  align-items: center;
}

.gallery-search-box .search-icon {
  position: absolute;
  left: 16px;
  font-size: 16px;
  pointer-events: none;
  opacity: 0.6;
}

.gallery-search-input {
  width: 100%;
  padding: 13px 44px 13px 44px;
  font-family: var(--font-sans);
  font-size: 14px;
  font-weight: 500;
  border-radius: var(--radius-pill);
  border: 2px solid var(--blue-cloud);
  background: var(--white);
  color: var(--ink);
  outline: none;
  transition: all 0.25s ease;
  box-shadow: inset 0 2px 4px rgba(0, 0, 0, 0.02);
}

.gallery-search-input:focus {
  border-color: var(--blue-primary);
  box-shadow: 0 0 0 4px rgba(94, 168, 222, 0.2);
}

.gallery-search-clear {
  position: absolute;
  right: 14px;
  width: 24px;
  height: 24px;
  border-radius: 50%;
  border: none;
  background: var(--pink-soft);
  color: var(--pink-accent);
  font-size: 12px;
  font-weight: bold;
  cursor: pointer;
  display: flex;
  align-items: center;
  justify-content: center;
  transition: all 0.2s;
}

.gallery-search-clear:hover {
  background: var(--pink-accent);
  color: var(--white);
}

.gallery-expand-actions {
  display: flex;
  align-items: center;
  gap: 8px;
  flex-shrink: 0;
}

.gallery-btn-tool {
  background: var(--white);
  border: 1px solid var(--line);
  padding: 9px 15px;
  border-radius: var(--radius-pill);
  font-family: var(--font-sans);
  font-size: 13px;
  font-weight: 600;
  color: var(--ink);
  cursor: pointer;
  display: inline-flex;
  align-items: center;
  gap: 6px;
  transition: all 0.2s ease;
  white-space: nowrap;
}

.gallery-btn-tool:hover {
  background: var(--blue-pale);
  border-color: var(--blue-light);
  color: var(--ink-deep);
  transform: translateY(-1px);
}

/* Category filter tabs */
.gallery-category-chips {
  display: flex;
  align-items: center;
  gap: 8px;
  overflow-x: auto;
  padding: 12px 2px 4px;
  scrollbar-width: thin;
  -webkit-overflow-scrolling: touch;
}

.gallery-category-chips::-webkit-scrollbar {
  height: 4px;
}

.gallery-category-chips::-webkit-scrollbar-thumb {
  background: var(--blue-cloud);
  border-radius: 4px;
}

.category-chip-btn {
  background: var(--white);
  border: 1px solid var(--line);
  padding: 7px 14px;
  border-radius: var(--radius-pill);
  font-family: var(--font-sans);
  font-size: 12.5px;
  font-weight: 600;
  color: var(--ink-soft);
  cursor: pointer;
  white-space: nowrap;
  display: inline-flex;
  align-items: center;
  gap: 6px;
  transition: all 0.2s ease;
}

.category-chip-btn:hover {
  background: var(--blue-pale);
  color: var(--blue-primary);
  border-color: var(--blue-light);
}

.category-chip-btn.active {
  background: var(--ink);
  color: var(--white);
  border-color: var(--ink);
  box-shadow: 0 4px 12px rgba(20, 64, 98, 0.2);
}

.category-chip-btn .chip-count {
  font-size: 11px;
  opacity: 0.8;
  padding: 1px 6px;
  background: rgba(0, 0, 0, 0.08);
  border-radius: 10px;
}

.category-chip-btn.active .chip-count {
  background: rgba(255, 255, 255, 0.25);
  color: var(--white);
}

/* Results Counter Bar */
.gallery-status-bar {
  display: flex;
  align-items: center;
  justify-content: space-between;
  margin-bottom: 24px;
  padding: 0 4px;
  font-size: 14px;
  color: var(--ink-soft);
  font-weight: 500;
}

.gallery-status-bar strong {
  color: var(--ink);
  font-weight: 700;
}

/* --------------------------------------------------------------------------
   Collapsible Folder Section (Accordion)
   -------------------------------------------------------------------------- */
.gallery-container {
  display: flex;
  flex-direction: column;
  gap: 28px;
  padding-bottom: 80px;
}

.gallery-folder-group {
  background: var(--white);
  border-radius: var(--radius-lg);
  border: 1px solid var(--line);
  box-shadow: var(--shadow-sm);
  overflow: hidden;
  transition: all 0.3s cubic-bezier(0.2, 0.8, 0.2, 1);
}

.gallery-folder-group:hover {
  border-color: rgba(94, 168, 222, 0.4);
  box-shadow: var(--shadow-md);
}

/* The summary element for folder header */
.gallery-folder-header {
  list-style: none;
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 18px 24px;
  cursor: pointer;
  user-select: none;
  background: linear-gradient(180deg, #ffffff 0%, #f9fcfe 100%);
  border-bottom: 1px solid transparent;
  transition: background 0.2s, border-color 0.2s;
}

.gallery-folder-header::-webkit-details-marker {
  display: none;
}

.gallery-folder-group[open] > .gallery-folder-header {
  border-bottom-color: var(--line);
  background: linear-gradient(180deg, #f4faff 0%, #ffffff 100%);
}

.folder-title-wrap {
  display: flex;
  align-items: center;
  gap: 14px;
}

.folder-icon-box {
  width: 44px;
  height: 44px;
  border-radius: 14px;
  background: var(--blue-pale);
  border: 1px solid var(--blue-cloud);
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 22px;
  flex-shrink: 0;
  box-shadow: 0 2px 8px rgba(94, 168, 222, 0.15);
  transition: transform 0.25s ease;
}

.gallery-folder-header:hover .folder-icon-box {
  transform: scale(1.08) rotate(-4deg);
}

.folder-heading {
  margin: 0;
  font-family: var(--font-cute);
  font-size: 19px;
  font-weight: 700;
  color: var(--ink);
  display: flex;
  align-items: center;
  gap: 10px;
  flex-wrap: wrap;
}

.folder-count-badge {
  font-family: var(--font-sans);
  font-size: 12px;
  font-weight: 600;
  padding: 3px 10px;
  border-radius: var(--radius-pill);
  background: var(--pink-soft);
  color: #d84b77;
  border: 1px solid var(--pink-bubble);
}

.folder-toggle-icon {
  display: flex;
  align-items: center;
  justify-content: center;
  width: 34px;
  height: 34px;
  border-radius: 50%;
  background: var(--paper);
  border: 1px solid var(--line);
  color: var(--ink-soft);
  font-size: 13px;
  transition: transform 0.3s cubic-bezier(0.34, 1.56, 0.64, 1), background 0.2s;
  flex-shrink: 0;
}

.gallery-folder-header:hover .folder-toggle-icon {
  background: var(--blue-pale);
  color: var(--blue-primary);
}

.gallery-folder-group[open] .folder-toggle-icon {
  transform: rotate(180deg);
  background: var(--blue-pale);
  color: var(--blue-primary);
}

/* --------------------------------------------------------------------------
   Product Cards Grid
   -------------------------------------------------------------------------- */
.folder-grid-wrap {
  padding: 24px;
}

.gallery-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(230px, 1fr));
  gap: 22px;
}

.gallery-card {
  position: relative;
  background: var(--paper);
  border: 1px solid var(--line);
  border-radius: var(--radius-md);
  overflow: hidden;
  display: flex;
  flex-direction: column;
  transition: transform 0.3s cubic-bezier(0.34, 1.56, 0.64, 1), box-shadow 0.3s, border-color 0.3s;
  cursor: pointer;
}

.gallery-card:hover {
  transform: translateY(-6px);
  box-shadow: 0 16px 36px rgba(20, 64, 98, 0.12);
  border-color: var(--blue-light);
}

.gallery-card-thumb {
  position: relative;
  width: 100%;
  aspect-ratio: 1 / 1;
  background: #f5f9fc;
  overflow: hidden;
}

.gallery-card-thumb img.gallery-main-thumb {
  width: 100%;
  height: 100%;
  object-fit: cover;
  transition: transform 0.5s cubic-bezier(0.2, 0.8, 0.2, 1);
  display: block;
}

.gallery-card-thumb img.gallery-hover-thumb {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  object-fit: cover;
  opacity: 0;
  transition: opacity 0.4s ease, transform 0.5s cubic-bezier(0.2, 0.8, 0.2, 1);
  display: block;
  z-index: 1;
}

.gallery-card:hover .gallery-card-thumb img {
  transform: scale(1.08);
}

.gallery-card:hover .gallery-card-thumb.has-multi-photos .gallery-hover-thumb {
  opacity: 1;
}

/* Card badges & overlay action */
.gallery-card-badge-multi {
  position: absolute;
  top: 10px;
  left: 10px;
  background: rgba(14, 48, 75, 0.82);
  color: #ffffff;
  backdrop-filter: blur(6px);
  -webkit-backdrop-filter: blur(6px);
  font-size: 11px;
  font-weight: 700;
  padding: 4px 9px;
  border-radius: var(--radius-pill);
  z-index: 3;
  box-shadow: 0 4px 10px rgba(0, 0, 0, 0.15);
  display: inline-flex;
  align-items: center;
  gap: 4px;
  border: 1px solid rgba(255, 255, 255, 0.25);
  letter-spacing: 0.2px;
}

.gallery-card-sparkle {
  position: absolute;
  top: 10px;
  right: 10px;
  font-size: 13px;
  color: #ffb703;
  opacity: 0;
  transform: scale(0.6);
  transition: all 0.3s cubic-bezier(0.34, 1.56, 0.64, 1);
  z-index: 2;
  filter: drop-shadow(0 2px 4px rgba(0, 0, 0, 0.2));
}

.gallery-card:hover .gallery-card-sparkle {
  opacity: 1;
  transform: scale(1);
}

.gallery-card-zoom-hint {
  position: absolute;
  inset: 0;
  background: rgba(20, 64, 98, 0.25);
  display: flex;
  align-items: center;
  justify-content: center;
  opacity: 0;
  transition: opacity 0.25s ease;
  backdrop-filter: blur(2px);
  -webkit-backdrop-filter: blur(2px);
}

.gallery-card-zoom-hint span {
  background: rgba(255, 255, 255, 0.95);
  color: var(--ink);
  font-size: 12px;
  font-weight: 700;
  padding: 6px 14px;
  border-radius: var(--radius-pill);
  box-shadow: 0 4px 14px rgba(0, 0, 0, 0.15);
  transform: translateY(8px);
  transition: transform 0.25s cubic-bezier(0.34, 1.56, 0.64, 1);
}

.gallery-card:hover .gallery-card-zoom-hint {
  opacity: 1;
}

.gallery-card:hover .gallery-card-zoom-hint span {
  transform: translateY(0);
}

.gallery-card-info {
  padding: 14px 16px;
  display: flex;
  flex-direction: column;
  gap: 6px;
  flex: 1;
  background: var(--white);
}

.gallery-card-title {
  margin: 0;
  font-family: var(--font-cute);
  font-size: 15px;
  font-weight: 700;
  color: var(--ink);
  line-height: 1.35;
  display: -webkit-box;
  -webkit-line-clamp: 2;
  -webkit-box-orient: vertical;
  overflow: hidden;
}

.gallery-card-meta {
  display: flex;
  align-items: center;
  justify-content: space-between;
  margin-top: auto;
  font-size: 12px;
  color: var(--ink-soft);
}

.gallery-card-folder-tag {
  background: var(--blue-pale);
  color: var(--blue-primary);
  padding: 3px 8px;
  border-radius: 6px;
  font-size: 11px;
  font-weight: 600;
}

.gallery-card-cta {
  color: var(--pink-accent);
  font-weight: 600;
  font-size: 11.5px;
}

/* --------------------------------------------------------------------------
   Empty Search State
   -------------------------------------------------------------------------- */
.gallery-empty-state {
  text-align: center;
  padding: 64px 20px;
  background: var(--white);
  border-radius: var(--radius-lg);
  border: 1px dashed var(--line);
  margin: 20px 0;
}

.gallery-empty-state .empty-icon {
  font-size: 48px;
  margin-bottom: 12px;
  display: block;
  animation: gentle-bounce 2s infinite ease-in-out;
}

.gallery-empty-state h3 {
  font-family: var(--font-display);
  font-size: 22px;
  color: var(--ink);
  margin: 0 0 8px;
}

.gallery-empty-state p {
  font-size: 15px;
  color: var(--ink-soft);
  max-width: 440px;
  margin: 0 auto 20px;
}

@keyframes gentle-bounce {
  0%, 100% { transform: translateY(0); }
  50% { transform: translateY(-8px); }
}

/* --------------------------------------------------------------------------
   Lightbox Modal Viewer
   -------------------------------------------------------------------------- */
.gallery-lightbox {
  position: fixed;
  inset: 0;
  z-index: 1000;
  background: rgba(14, 48, 75, 0.88);
  backdrop-filter: blur(12px);
  -webkit-backdrop-filter: blur(12px);
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 20px;
  opacity: 0;
  pointer-events: none;
  transition: opacity 0.3s ease;
}

.gallery-lightbox.active {
  opacity: 1;
  pointer-events: auto;
}

.lightbox-content-box {
  background: var(--white);
  border-radius: var(--radius-xl);
  max-width: 900px;
  width: 100%;
  max-height: 92vh;
  display: flex;
  overflow: hidden;
  position: relative;
  box-shadow: 0 25px 60px rgba(0, 0, 0, 0.4);
  transform: scale(0.92);
  transition: transform 0.3s cubic-bezier(0.34, 1.56, 0.64, 1);
}

.gallery-lightbox.active .lightbox-content-box {
  transform: scale(1);
}

.lightbox-img-area {
  flex: 1 1 55%;
  background: #0d1520;
  display: flex;
  flex-direction: column;
  position: relative;
  min-height: 420px;
  overflow: hidden;
}

.lightbox-img-stage {
  flex: 1;
  width: 100%;
  display: flex;
  align-items: center;
  justify-content: center;
  position: relative;
  padding: 16px;
  min-height: 320px;
}

.lightbox-img-stage img {
  max-width: 100%;
  max-height: 64vh;
  object-fit: contain;
  display: block;
  border-radius: 8px;
  transition: opacity 0.25s ease, transform 0.25s ease;
  user-select: none;
}

.lightbox-img-label {
  position: absolute;
  bottom: 14px;
  left: 50%;
  transform: translateX(-50%);
  background: rgba(14, 48, 75, 0.85);
  color: #ffffff;
  backdrop-filter: blur(8px);
  -webkit-backdrop-filter: blur(8px);
  font-size: 12px;
  font-weight: 700;
  padding: 5px 14px;
  border-radius: var(--radius-pill);
  z-index: 4;
  border: 1px solid rgba(255, 255, 255, 0.25);
  box-shadow: 0 4px 12px rgba(0, 0, 0, 0.25);
  pointer-events: none;
  white-space: nowrap;
}

/* Lightbox Thumbnails Strip for Multi-photo Items */
.lightbox-thumbs-container {
  width: 100%;
  background: rgba(8, 14, 22, 0.85);
  backdrop-filter: blur(10px);
  -webkit-backdrop-filter: blur(10px);
  border-top: 1px solid rgba(255, 255, 255, 0.12);
  padding: 10px 14px;
  z-index: 6;
}

.lightbox-thumbs-scroll {
  display: flex;
  align-items: center;
  gap: 10px;
  overflow-x: auto;
  scrollbar-width: thin;
  scrollbar-color: rgba(255, 255, 255, 0.25) transparent;
  padding-bottom: 2px;
  justify-content: center;
}

.lightbox-thumbs-scroll::-webkit-scrollbar {
  height: 5px;
}

.lightbox-thumbs-scroll::-webkit-scrollbar-thumb {
  background: rgba(255, 255, 255, 0.25);
  border-radius: 10px;
}

.lightbox-thumb-btn {
  flex: 0 0 auto;
  background: rgba(255, 255, 255, 0.08);
  border: 2px solid transparent;
  border-radius: 8px;
  padding: 3px;
  cursor: pointer;
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 3px;
  transition: all 0.2s cubic-bezier(0.34, 1.56, 0.64, 1);
  outline: none;
}

.lightbox-thumb-btn img {
  width: 46px;
  height: 46px;
  object-fit: cover;
  border-radius: 6px;
  display: block;
}

.lightbox-thumb-caption {
  font-size: 10.5px;
  color: rgba(255, 255, 255, 0.8);
  max-width: 64px;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
  line-height: 1.2;
}

.lightbox-thumb-btn:hover {
  border-color: rgba(255, 255, 255, 0.5);
  background: rgba(255, 255, 255, 0.2);
  transform: translateY(-2px);
}

.lightbox-thumb-btn.active {
  border-color: #38bdf8;
  background: rgba(56, 189, 248, 0.25);
  box-shadow: 0 0 12px rgba(56, 189, 248, 0.45);
  transform: scale(1.06);
}

.lightbox-thumb-btn.active .lightbox-thumb-caption {
  color: #ffffff;
  font-weight: 700;
}

/* Lightbox Details Area */
.lightbox-details-area {
  flex: 1 1 45%;
  padding: 28px 24px;
  display: flex;
  flex-direction: column;
  justify-content: space-between;
  background: var(--white);
  overflow-y: auto;
}

.lightbox-header-row {
  display: flex;
  align-items: center;
  justify-content: space-between;
  margin-bottom: 10px;
  padding-right: 36px; /* Avoid overlapping close button */
}

.lightbox-product-nav {
  display: inline-flex;
  align-items: center;
  gap: 6px;
}

.lightbox-btn-prev-product,
.lightbox-btn-next-product {
  background: var(--paper);
  border: 1px solid var(--line);
  color: var(--ink-soft);
  font-size: 11.5px;
  font-weight: 600;
  padding: 4px 10px;
  border-radius: var(--radius-pill);
  cursor: pointer;
  transition: all 0.2s;
  display: inline-flex;
  align-items: center;
}

.lightbox-btn-prev-product:hover,
.lightbox-btn-next-product:hover {
  background: var(--blue-pale);
  color: var(--blue-primary);
  border-color: var(--blue-soft);
  transform: translateY(-1px);
}

.lightbox-cta-wrap {
  display: flex;
  flex-direction: column;
  gap: 10px;
}

.lightbox-zalo-btn {
  background: linear-gradient(135deg, #0088ff 0%, #0066cc 100%);
  color: var(--white);
  box-shadow: 0 8px 20px rgba(0, 102, 204, 0.25);
  width: 100%;
}

.lightbox-zalo-btn:hover {
  transform: translateY(-2px);
  box-shadow: 0 12px 28px rgba(0, 102, 204, 0.35);
}

/* Lightbox Prev / Next Nav Buttons */
.lightbox-nav-btn {
  position: absolute;
  top: 50%;
  transform: translateY(-50%);
  width: 46px;
  height: 46px;
  border-radius: 50%;
  border: none;
  background: rgba(255, 255, 255, 0.2);
  color: var(--white);
  font-size: 22px;
  cursor: pointer;
  display: flex;
  align-items: center;
  justify-content: center;
  transition: all 0.2s;
  backdrop-filter: blur(4px);
  z-index: 5;
}

.lightbox-nav-btn:hover {
  background: rgba(255, 255, 255, 0.95);
  color: var(--ink);
  transform: translateY(-50%) scale(1.1);
}

.lightbox-prev {
  left: 14px;
}

.lightbox-next {
  right: 14px;
}

/* --------------------------------------------------------------------------
   Responsive Media Queries for Tablet & Mobile
   -------------------------------------------------------------------------- */
@media (max-width: 860px) {
  .lightbox-content-box {
    flex-direction: column;
    max-height: 92vh;
    width: 94vw;
    margin: auto;
    overflow-y: auto;
    -webkit-overflow-scrolling: touch;
    border-radius: var(--radius-lg);
  }

  .lightbox-img-area {
    min-height: 220px;
    max-height: 40vh;
    width: 100%;
  }

  .lightbox-img-stage {
    min-height: 160px;
    padding: 10px;
  }

  .lightbox-img-stage img {
    max-height: 30vh;
  }

  .lightbox-nav-btn {
    width: 38px;
    height: 38px;
    font-size: 18px;
  }

  .lightbox-prev { left: 8px; }
  .lightbox-next { right: 8px; }

  .lightbox-thumbs-container {
    padding: 6px 10px;
  }

  .lightbox-thumbs-scroll {
    justify-content: flex-start;
    gap: 8px;
  }

  .lightbox-thumb-btn img {
    width: 40px;
    height: 40px;
  }

  .lightbox-details-area {
    padding: 18px 16px 22px;
  }

  .gallery-grid {
    grid-template-columns: repeat(auto-fill, minmax(170px, 1fr));
    gap: 16px;
  }

  .folder-grid-wrap {
    padding: 16px;
  }

  .gallery-folder-header {
    padding: 14px 16px;
  }

  .folder-heading {
    font-size: 16px;
  }

  .folder-icon-box {
    width: 36px;
    height: 36px;
    font-size: 18px;
  }
}

@media (max-width: 900px) {
  .gallery-toolbar {
    top: 81px;
  }
}

@media (max-width: 600px) {
  .gallery-page .section-shell {
    width: calc(100% - 24px);
  }

  .gallery-hero h1,
  .gallery-card-title {
    overflow-wrap: anywhere;
  }

  .lightbox-content-box {
    width: calc(100vw - 16px);
    max-width: 560px;
  }

  .gallery-hero {
    padding: 18px 0 14px;
  }

  .gallery-hero h1 {
    font-size: clamp(20px, 6.2vw, 28px);
    line-height: 1.25;
    margin: 0 0 10px;
  }

  .gallery-sub {
    font-size: 13px;
    line-height: 1.5;
    margin-bottom: 14px;
  }

  /* 2x2 Stats Grid on mobile */
  .gallery-stats {
    display: grid;
    grid-template-columns: repeat(2, 1fr);
    gap: 6px;
  }

  .stat-chip {
    font-size: 11px;
    padding: 5px 8px;
    justify-content: center;
    text-align: center;
  }

  /* Compact Sticky Toolbar on mobile */
  .gallery-toolbar {
    padding: 8px 10px 6px;
    top: 81px;
    margin-bottom: 16px;
    border-radius: 16px;
    box-shadow: 0 4px 16px rgba(20, 64, 98, 0.08);
  }

  /* Single-row compact search & tools: fixes excessive toolbar height */
  .gallery-toolbar-top {
    flex-direction: row;
    align-items: center;
    gap: 8px;
    justify-content: space-between;
  }

  .gallery-search-box {
    flex: 1 1 auto;
    min-width: 0;
  }

  /* Prevent iOS zoom on search input while keeping it compact & sleek */
  .gallery-search-input {
    font-size: 16px;
    height: 38px;
    padding: 0 32px 0 34px;
    line-height: 38px;
    border-width: 1.5px;
  }

  .gallery-search-box .search-icon {
    left: 11px;
    font-size: 13.5px;
  }

  .gallery-search-clear {
    right: 8px;
    width: 22px;
    height: 22px;
    font-size: 11px;
  }

  .gallery-expand-actions {
    display: flex;
    align-items: center;
    gap: 6px;
    flex-shrink: 0;
  }

  /* Compact circular buttons on mobile */
  .gallery-btn-tool {
    width: 38px;
    height: 38px;
    padding: 0;
    border-radius: 50%;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    font-size: 15px;
    flex: none;
    box-shadow: 0 2px 6px rgba(20, 64, 98, 0.06);
  }

  .gallery-btn-tool .tool-text {
    display: none;
  }

  /* Horizontal swipeable category chips */
  .gallery-category-chips {
    display: flex;
    gap: 6px;
    overflow-x: auto;
    flex-wrap: nowrap;
    padding: 6px 0 2px;
    -webkit-overflow-scrolling: touch;
    scrollbar-width: none;
  }

  .gallery-category-chips::-webkit-scrollbar {
    display: none;
  }

  .category-chip-btn {
    flex: 0 0 auto;
    font-size: 11.5px;
    padding: 5px 10px;
    white-space: nowrap;
  }

  .gallery-status-bar {
    margin-bottom: 12px;
    font-size: 11.5px;
    padding: 0 2px;
  }

  .folder-grid-wrap {
    padding: 10px;
  }

  .gallery-grid {
    grid-template-columns: repeat(2, 1fr);
    gap: 8px;
  }

  .gallery-card-info {
    padding: 8px 10px 12px;
  }

  .gallery-card-title {
    font-size: 13px;
    line-height: 1.3;
  }

  .gallery-card-badge-multi {
    top: 6px;
    left: 6px;
    font-size: 9.5px;
    padding: 2px 7px;
  }

  .gallery-card-meta {
    flex-direction: column;
    align-items: flex-start;
    gap: 4px;
  }

  .gallery-card-cta {
    font-size: 10.5px;
  }

  /* Compact Lightbox on small screens */
  .lightbox-close-btn {
    top: 8px;
    right: 8px;
    width: 32px;
    height: 32px;
    font-size: 14px;
    z-index: 25;
  }

  .lightbox-img-area {
    min-height: 200px;
    max-height: 36vh;
  }

  .lightbox-img-stage img {
    max-height: 26vh;
  }

  .lightbox-img-label {
    bottom: 6px;
    font-size: 10.5px;
    padding: 3px 10px;
  }

  .lightbox-nav-btn {
    width: 34px;
    height: 34px;
    font-size: 16px;
  }

  .lightbox-thumb-btn img {
    width: 36px;
    height: 36px;
  }

  .lightbox-thumb-caption {
    font-size: 9px;
    max-width: 48px;
  }

  .lightbox-details-area {
    padding: 14px 12px 18px;
  }

  .lightbox-header-row {
    padding-right: 28px;
    margin-bottom: 6px;
  }

  .lightbox-badge {
    font-size: 10.5px;
    padding: 3px 8px;
  }

  .lightbox-btn-prev-product,
  .lightbox-btn-next-product {
    font-size: 10.5px;
    padding: 3px 8px;
  }

  .lightbox-title {
    font-size: 18px;
    margin-bottom: 4px;
  }

  .lightbox-category-tag {
    font-size: 12px;
    margin-bottom: 10px;
  }

  .lightbox-card-features {
    padding: 10px 12px;
    gap: 7px;
    font-size: 12px;
    margin-bottom: 14px;
  }

  .lightbox-feature-icon {
    font-size: 14px;
  }

  .lightbox-zalo-btn {
    font-size: 13px;
    padding: 11px 14px;
  }
}

@media (max-width: 480px) {
  .gallery-toolbar {
    top: 71px;
  }
}

