/* Asigură scroll pe pagină (galerie) */
html.galerie-page,
html.galerie-page body {
  overflow-y: auto !important;
  min-height: 100%;
}

@media (max-width: 768px){
  /* spațiu dedicat subsolului pentru CTA-uri plutitoare (evită suprapuneri pe carduri) */
  .page-gallery{
    padding-bottom: 120px;
  }
}
.page-hero,
body,
main {
  background: var(--bg-0);
  color: var(--text-0);
}

main.container,
main.container section {
  background: var(--bg-0);
}
main.container section {
  padding-top: var(--space-2xl);
  padding-bottom: var(--space-2xl);
}
@media (max-width: 768px) {
  main.container section {
    padding-top: var(--space-xl);
    padding-bottom: var(--space-xl);
  }
}
.page-hero {
  background: var(--bg-0);
  padding: var(--space-3xl) 0 var(--space-2xl);
  border-bottom: 1px solid var(--border);
}
.page-hero h1 {
  color: var(--text-0);
  margin-bottom: var(--space-sm);
}
.page-hero p {
  color: var(--text-1);
  max-width: 720px;
}

.breadcrumbs {
  color: var(--text-1);
  font-size: 13px;
  margin-bottom: var(--space-md);
}
.breadcrumbs a {
  color: var(--gold-0);
  text-decoration: none;
}

/* ========== Hero galerie – premium, compact (scoped: .page-gallery) ========== */
.page-gallery .gallery-hero {
  display: grid;
  grid-template-columns: 1fr auto;
  gap: var(--space-xl);
  align-items: start;
  padding: 28px var(--space-lg) 36px;
  margin-bottom: 0;
  max-width: 100%;
  background: linear-gradient(180deg, var(--bg-1) 0%, var(--bg-0) 100%);
  border: 1px solid rgba(255, 255, 255, 0.06);
  border-radius: var(--radius-lg);
  box-shadow: 0 2px 16px rgba(0, 0, 0, 0.2);
  margin-top: var(--space-md);
}
@media (max-width: 900px) {
  .page-gallery .gallery-hero {
    grid-template-columns: 1fr;
    padding: 24px var(--space-lg) 28px;
  }
  .page-gallery .gallery-chips {
    flex-wrap: wrap;
  }
}
.page-gallery .gallery-hero__left {
  min-width: 0;
}
.page-gallery .gallery-breadcrumb {
  display: flex;
  align-items: center;
  gap: 6px;
  flex-wrap: wrap;
  color: var(--text-1);
  font-size: 0.8125rem;
  font-weight: 500;
  margin-bottom: 10px;
  letter-spacing: 0.02em;
}
.page-gallery .gallery-breadcrumb a {
  color: var(--gold-0);
  text-decoration: none;
}
.page-gallery .gallery-breadcrumb a:hover {
  color: var(--gold-1);
  text-decoration: underline;
}
.page-gallery .gallery-breadcrumb span[aria-hidden="true"] {
  color: var(--text-1);
  opacity: 0.8;
}
.page-gallery .gallery-hero .gallery-title {
  display: flex;
  align-items: center;
  gap: 10px;
  margin: 0 0 12px;
  color: var(--text-0);
  font-size: clamp(1.5rem, 2.5vw, 2rem);
  font-weight: 800;
  letter-spacing: -0.03em;
  line-height: 1.2;
  padding-bottom: 10px;
  border-bottom: 2px solid var(--gold-0);
}
.page-gallery .gallery-title-icon {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  flex-shrink: 0;
  width: 28px;
  height: 28px;
  color: var(--gold-0);
}
.page-gallery .gallery-title-icon svg {
  width: 100%;
  height: 100%;
  max-width: 28px;
  max-height: 28px;
}
.page-gallery .gallery-subtitle {
  margin: 0;
  color: var(--text-1);
  font-size: 0.9375rem;
  line-height: 1.65;
  max-width: 60ch;
}
.page-gallery .gallery-hero__right {
  display: flex;
  align-items: center;
  justify-content: flex-end;
}
@media (max-width: 900px) {
  .page-gallery .gallery-hero__right {
    justify-content: flex-start;
  }
}
.page-gallery .gallery-chips {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  align-items: center;
}
.page-gallery .gallery-chip {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  padding: 6px 12px;
  font-size: 0.8125rem;
  font-weight: 600;
  color: var(--text-0);
  background: rgba(255, 255, 255, 0.04);
  border: 1px solid rgba(191, 159, 105, 0.25);
  border-radius: var(--radius-md);
}
.page-gallery .gallery-chip-count {
  color: var(--gold-0);
  border-color: rgba(191, 159, 105, 0.4);
  background: rgba(191, 159, 105, 0.08);
}
.page-gallery .gallery-chip-icon {
  width: 16px;
  height: 16px;
  max-width: 16px;
  max-height: 16px;
  flex-shrink: 0;
  color: var(--gold-0);
}
.page-gallery .gallery-section {
  padding-top: 0;
}
.page-gallery .gallery-toolbar {
  margin-top: 18px;
}
.gallery-section {
  padding-top: 0;
}

/* Tabs: Produse / Expo / Fabrică */
.gallery-tabs{
  display: flex;
  gap: 10px;
  align-items: center;
  justify-content: flex-start;
  flex-wrap: wrap;
  margin-top: var(--space-md);
  margin-bottom: var(--space-sm);
  padding: 10px 12px;
  border-radius: var(--radius-md);
  background: rgba(44, 46, 50, 0.65);
  border: 1px solid rgba(191, 159, 105, 0.18);
  backdrop-filter: blur(10px);
}
.gallery-tab-btn{
  appearance: none;
  border: 1px solid rgba(191, 159, 105, 0.26);
  background: rgba(255,255,255,0.04);
  color: rgba(255,255,255,0.92);
  border-radius: 999px;
  padding: 8px 14px;
  min-height: 40px;
  font-weight: 700;
  font-size: 0.9rem;
  cursor: pointer;
  transition: transform .18s ease, border-color .18s ease, background .18s ease, color .18s ease, filter .18s ease;
  white-space: nowrap;
}
.gallery-tab-btn:hover{
  transform: translateY(-1px);
  border-color: rgba(191,159,105,0.7);
}
.gallery-tab-btn.active,
.gallery-tab-btn[aria-pressed="true"]{
  background: rgba(191,159,105,0.16);
  border-color: rgba(191,159,105,0.9);
  color: var(--gold-0);
  box-shadow: 0 0 0 1px rgba(191,159,105,0.22) inset;
}
.gallery-tabs:focus-within .gallery-tab-btn:focus-visible{
  outline: 2px solid var(--gold-0);
  outline-offset: 2px;
}

@media (max-width: 640px){
  .gallery-tabs{
    flex-wrap: nowrap;
    overflow-x: auto;
    -webkit-overflow-scrolling: touch;
    gap: 8px;
    padding: 10px 10px;
  }
  .gallery-tab-btn{
    flex: 0 0 auto;
    min-height: 38px;
    padding: 8px 12px;
    font-size: 0.88rem;
  }
}

/* Când e pe tab Expo / Fabrică, ascund filtrele de produse (dar păstrăm DOM). */
body[data-gallery-tab="expo"] #galleryProductControls,
body[data-gallery-tab="factory"] #galleryProductControls{
  display: none;
}

.gallery-toolbar {
  display: flex;
  gap: var(--gap-lg);
  align-items: center;
  justify-content: flex-start;
  flex-wrap: wrap;
  margin-top: var(--space-xl);
  margin-bottom: var(--space-sm);
  padding: var(--space-md) 0;
  background: var(--bg-0);
  row-gap: var(--space-md);
}
.gallery-quick-filters {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  width: 100%;
}
.gallery-filter-btn {
  appearance: none;
  border: 1px solid var(--border);
  background: var(--bg-2);
  color: var(--text-0);
  border-radius: 999px;
  min-height: 38px;
  padding: 8px 14px;
  font-size: 0.84rem;
  font-weight: 600;
  cursor: pointer;
}
.gallery-filter-btn.active,
.gallery-filter-btn[aria-pressed="true"] {
  border-color: rgba(191, 159, 105, 0.95);
  color: var(--gold-0);
  box-shadow: 0 0 0 1px rgba(191, 159, 105, 0.25);
}
.gallery-filter-btn:focus-visible {
  outline: 2px solid var(--gold-0);
  outline-offset: 2px;
}
@media (max-width: 720px) {
  .gallery-toolbar { flex-direction: column; align-items: flex-start; }
  .gallery-result-count { margin-left: 0; }
}
@media (max-width: 640px) {
  .page-gallery .gallery-hero {
    padding: 16px 12px 18px;
    gap: 10px;
  }
  .page-gallery .gallery-subtitle {
    font-size: 0.86rem;
    line-height: 1.45;
    max-width: 100%;
    display: -webkit-box;
    -webkit-line-clamp: 2;
    -webkit-box-orient: vertical;
    overflow: hidden;
  }
  .page-gallery .gallery-chip:not(.gallery-chip-count) {
    display: none;
  }
  .gallery-quick-filters {
    flex-wrap: nowrap;
    overflow-x: auto;
    padding-bottom: 2px;
    -webkit-overflow-scrolling: touch;
  }
  .gallery-filter-btn {
    flex: 0 0 auto;
    min-height: 36px;
    padding: 7px 12px;
    font-size: 0.8rem;
  }
  /* păstrăm pe mobil doar filtrul principal + quick filters */
  #galleryGama,
  #galleryEssence,
  label[for="galleryGama"],
  label[for="galleryEssence"] {
    display: none !important;
  }
  .gallery-intro-panel {
    padding: 18px;
    border-radius: 16px;
  }
  .gallery-intro-btn {
    width: 100%;
    justify-content: center;
  }
}
.gallery-toolbar-group {
  display: flex;
  align-items: center;
  gap: var(--gap-sm);
}
.gallery-toolbar-label {
  color: var(--text-1);
  font-size: 0.875rem;
  font-weight: 500;
  margin: 0;
}
.gallery-result-count {
  color: var(--text-1);
  font-size: 0.875rem;
  margin-left: auto;
}
.gallery-intro-panel {
  margin: 22px 0 26px;
  padding: 22px 24px;
  border-radius: 20px;
  background: linear-gradient(180deg, rgba(255,255,255,0.03) 0%, rgba(255,255,255,0.02) 100%);
  border: 1px solid rgba(216, 176, 106, 0.18);
  box-shadow: 0 18px 44px rgba(0, 0, 0, 0.18);
  position: relative;
}
.gallery-intro-panel::before{
  content:"";
  position:absolute;
  inset: 0;
  border-radius: 20px;
  pointer-events:none;
  background:
    radial-gradient(1200px 240px at 10% 10%, rgba(216,176,106,0.20) 0%, rgba(216,176,106,0) 50%),
    radial-gradient(900px 220px at 90% 0%, rgba(255,255,255,0.06) 0%, rgba(255,255,255,0) 45%);
  opacity: 0.9;
}
.gallery-intro-panel__text {
  max-width: 980px;
}
.gallery-intro-panel__lead,
.gallery-intro-panel__availability {
  margin: 0;
  color: rgba(255,255,255,0.90);
  line-height: 1.7;
}
.gallery-intro-panel__lead {
  font-size: 1.04rem;
  font-weight: 650;
}
.gallery-intro-panel__availability {
  margin-top: 10px;
  font-size: 0.98rem;
  color: rgba(255,255,255,0.84);
}
.gallery-intro-panel__lead a,
.gallery-intro-link {
  color: var(--gold-0, #d8b06a);
  text-decoration: none;
}
.gallery-intro-panel__lead a:hover,
.gallery-intro-link:hover {
  color: #f0c984;
  text-decoration: underline;
  text-underline-offset: 4px;
}
.gallery-intro-panel__meta {
  margin-top: 18px;
  display: flex;
  flex-direction: column;
  gap: 14px;
}
.gallery-intro-panel__trust {
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
}
.gallery-intro-pill {
  display: inline-flex;
  align-items: center;
  min-height: 36px;
  padding: 8px 14px;
  border-radius: 999px;
  background: rgba(191,159,105,0.12);
  border: 1px solid rgba(216,176,106,0.22);
  color: rgba(255,255,255,0.95);
  font-size: 0.93rem;
  line-height: 1.2;
}
.gallery-intro-panel__actions {
  display: flex;
  flex-direction: column;
  align-items: flex-start;
  gap: 10px;
}
.gallery-intro-link {
  font-size: 0.98rem;
  font-weight: 600;
}
.gallery-intro-btn {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  min-height: 46px;
  padding: 12px 20px;
  border-radius: 14px;
  background: linear-gradient(135deg, #d1ae6c 0%, #b88a45 100%);
  color: #121212 !important;
  font-weight: 700;
  text-decoration: none;
  box-shadow: 0 10px 24px rgba(0,0,0,0.18);
  transition: transform .18s ease, box-shadow .18s ease, filter .18s ease;
}
.gallery-intro-btn *{
  color: inherit !important;
}
.gallery-intro-btn:hover {
  transform: translateY(-1px);
  box-shadow: 0 14px 28px rgba(0,0,0,0.24);
  filter: brightness(1.03);
}
.gallery-intro-btn:focus-visible {
  outline: 2px solid #f0c984;
  outline-offset: 3px;
}
.gallery-sort {
  background: var(--bg-2);
  color: var(--text-0);
  border: 1px solid var(--border);
  border-radius: var(--radius-md);
  padding: 8px 12px;
  min-width: 140px;
}

.gallery-cat-group,
.gallery-toolbar .filters {
  display: flex;
  gap: var(--gap-sm);
  flex-wrap: wrap;
  align-items: center;
}

.cat-chip {
  background: var(--bg-2);
  color: var(--text-0);
  border: 1px solid var(--border);
  border-radius: 999px;
  padding: 6px 10px;
  font-size: 12px;
  cursor: pointer;
}

.cat-chip.active {
  border-color: var(--gold-0);
  color: var(--gold-0);
}

/* ========== GALERIE FOTO – carduri consistente (scop: .gallery-section) ========== */
.gallery-grid {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: var(--space-lg);
  margin-top: var(--space-md);
  background: var(--bg-0);
  transition: opacity 0.3s ease;
  /* start = fără „cutii” goale sub footer când un card din rând e mai înalt */
  align-items: start;
}
@media (prefers-reduced-motion: reduce) {
  .gallery-grid { transition: none; }
}
@media (max-width: 1024px) {
  .gallery-grid { grid-template-columns: repeat(2, minmax(0, 1fr)); gap: var(--space-md); }
}
@media (max-width: 720px) {
  /* Mobile: 2 columns (not 3, not 1) for premium density */
  .gallery-grid { grid-template-columns: 1fr; gap: var(--space-md); }
}
@media (max-width: 420px) {
  .gallery-grid { grid-template-columns: 1fr; }
}

.gallery-section .gallery-item.gallery-card {
  display: flex;
  flex-direction: column;
  min-height: 0;
  align-self: start;
  width: 100%;
  max-width: 100%;
  background: var(--bg-2);
  border: 1px solid var(--border);
  border-radius: var(--radius-lg);
  overflow: hidden;
  box-shadow: 0 2px 12px rgba(0, 0, 0, 0.2);
  transition: transform 0.2s ease, box-shadow 0.2s ease, border-color 0.2s ease;
  animation: gallery-card-in 0.4s ease forwards;
}
@keyframes gallery-card-in {
  from { opacity: 0; transform: translateY(8px); }
  to { opacity: 1; transform: translateY(0); }
}
@media (prefers-reduced-motion: reduce) {
  .gallery-section .gallery-item { animation: none; }
}
.gallery-section .gallery-item.gallery-card:hover {
  transform: translateY(-2px);
  box-shadow: 0 0 0 1px rgba(148,163,255,0.4),
              0 0 24px rgba(56,189,248,0.65),
              0 24px 50px rgba(0,0,0,0.6);
  border-color: rgba(191, 159, 105, 0.6);
}

.gallery-section .gallery-card-link {
  display: flex;
  flex-direction: column;
  flex: 0 1 auto;
  min-height: 0;
  text-decoration: none;
  color: inherit;
}

/* Imagine – raport fix 4/3, fără distorsiune */
.gallery-section .gallery-media {
  position: relative;
  aspect-ratio: 4 / 3;
  overflow: hidden;
  flex-shrink: 0;
  border-radius: var(--radius-lg) var(--radius-lg) 0 0;
  background: radial-gradient(circle at 20% 0, rgba(191,159,105,0.18) 0, transparent 55%), rgba(0, 0, 0, 0.28);
  cursor: pointer;
  display: flex;
  align-items: center;
  justify-content: center;
}
.gallery-section .gallery-card.is-featured {
  grid-column: span 2;
}
.gallery-section .gallery-card.is-featured .gallery-media{
  aspect-ratio: 16 / 10;
  width: 100%;
  overflow: hidden;
  border-radius: 16px 16px 0 0;
  background: #111;
  position: relative;
  padding: 0 !important;
}
.gallery-section .gallery-card.is-featured .gallery-media img{
  width: 100% !important;
  height: 100% !important;
  max-width: none !important;
  max-height: none !important;
  object-fit: cover !important;
  object-position: center 38% !important;
  display: block;
  margin: 0 !important;
  transform: scale(1.02);
}
@media (max-width: 1024px){
  .gallery-section .gallery-card.is-featured{ grid-column: auto; }
  .gallery-section .gallery-card.is-featured .gallery-media{ aspect-ratio: 4 / 3; }
}

/* Media type variants (expo / fabrică) */
.gallery-section .gallery-card[data-media-type="expo"] .gallery-media,
.gallery-section .gallery-card[data-media-type="factory"] .gallery-media{
  aspect-ratio: 16 / 10;
}

.gallery-section .gallery-media img {
  max-width: 100%;
  max-height: 100%;
  width: auto;
  height: auto;
  object-fit: contain;
  object-position: center;
  display: block;
  transition: transform 0.28s ease;
}

/* Expo video panel (shown in Expo tab) */
.gallery-expo-video-panel {
  margin: var(--space-md) 0 var(--space-lg);
  padding: var(--space-md);
  border: 1px solid rgba(191,159,105,0.32);
  border-radius: var(--radius-lg);
  background: linear-gradient(160deg, rgba(191,159,105,0.12), rgba(17,19,24,0.9));
}
.gallery-expo-video {
  width: 100%;
  display: block;
  aspect-ratio: 16 / 9;
  border-radius: var(--radius-md);
  border: 1px solid rgba(191,159,105,0.3);
  background: #000;
  box-shadow: 0 14px 26px rgba(0,0,0,0.35);
}
.gallery-expo-video-caption {
  margin: 8px 0 0;
  color: var(--text-1);
  font-size: 0.9rem;
}
.gallery-section .gallery-item:hover .gallery-media img {
  transform: scale(1.03);
}

/* Premium overlay: title + model on hover/focus */
.gallery-section .gallery-media-overlay{
  position: absolute;
  inset: 0;
  display: flex;
  align-items: flex-end;
  padding: 12px;
  background: linear-gradient(180deg, rgba(0,0,0,0.00) 35%, rgba(0,0,0,0.78) 100%);
  opacity: 0;
  transform: translateY(4px);
  transition: opacity .22s ease, transform .22s ease;
  pointer-events: none;
}
.gallery-section .gallery-media-overlay__inner{
  text-align: left;
  max-width: 100%;
}
.gallery-section .gallery-media-overlay__title{
  color: var(--text-0);
  font-weight: 800;
  letter-spacing: .2px;
  line-height: 1.15;
  font-size: 14px;
  text-shadow: 0 10px 26px rgba(0,0,0,.55);
}
.gallery-section .gallery-media-overlay__model{
  margin-top: 4px;
  color: rgba(226, 231, 238, .92);
  font-weight: 650;
  font-size: 12px;
  letter-spacing: .18px;
}
.gallery-section .gallery-card-link:focus-visible .gallery-media-overlay,
.gallery-section .gallery-item:hover .gallery-media-overlay{
  opacity: 1;
  transform: translateY(0);
}
/* Fără hover real (touch): titlul e deja în .gallery-body — evităm dublarea sub imagine */
@media (hover: none) {
  .gallery-section .gallery-media-overlay {
    opacity: 0;
    transform: none;
    pointer-events: none;
  }
  .gallery-section .gallery-card-link:focus-visible .gallery-media-overlay {
    opacity: 1;
    pointer-events: none;
  }
}

/* Lightbox open button (explicit, avoids breaking product navigation) */
.gallery-section .gallery-open{
  position: absolute;
  top: 10px;
  right: 10px;
  z-index: 2;
  width: 40px;
  height: 40px;
  border-radius: 12px;
  border: 1px solid rgba(255,255,255,0.14);
  background: rgba(0,0,0,0.55);
  color: var(--text-0);
  display: inline-flex;
  align-items: center;
  justify-content: center;
  cursor: pointer;
  transition: transform .18s ease, border-color .18s ease, background .18s ease;
}
.gallery-section .gallery-open:hover{
  transform: translateY(-1px);
  border-color: rgba(191,159,105,.55);
  background: rgba(0,0,0,0.68);
}
.gallery-section .gallery-open:focus-visible{
  outline: 2px solid var(--gold-0);
  outline-offset: 2px;
}
@media (prefers-reduced-motion: reduce) {
  .gallery-section .gallery-media img { transition: none; }
  .gallery-section .gallery-item:hover .gallery-media img { transform: none; }
}

.gallery-section .gallery-card-badge {
  position: absolute;
  bottom: 8px;
  right: 8px;
  background: rgba(0, 0, 0, 0.6);
  color: var(--text-0);
  font-size: 10px;
  padding: 4px 8px;
  border-radius: var(--radius-sm);
  display: flex;
  align-items: center;
  gap: 4px;
  opacity: 0.82;
}
.gallery-section .gallery-card-badge svg {
  width: 14px;
  height: 14px;
  opacity: 0.9;
}

.gallery-section .gallery-category-chip {
  position: absolute;
  top: 8px;
  left: 8px;
  background: rgba(0, 0, 0, 0.55);
  color: var(--gold-0);
  font-size: 11px;
  font-weight: 650;
  padding: 4px 8px;
  border-radius: var(--radius-sm);
  letter-spacing: 0.02em;
  display: none;
}

/* Body – titlu max 2 linii, descriere max 3 linii */
.gallery-section .gallery-body {
  flex: 0 1 auto;
  min-height: 0;
  padding: var(--space-md) var(--space-lg);
  display: flex;
  flex-direction: column;
  gap: var(--space-xs);
}
.gallery-section .gallery-title {
  margin: 0;
  font-size: 1rem;
  font-weight: 600;
  color: var(--gold-0);
  line-height: 1.35;
  display: -webkit-box;
  -webkit-line-clamp: 2;
  -webkit-box-orient: vertical;
  overflow: hidden;
}
.gallery-section .gallery-desc {
  margin: 0;
  font-size: 0.875rem;
  color: var(--text-1);
  line-height: 1.5;
  display: -webkit-box;
  -webkit-line-clamp: 3;
  -webkit-box-orient: vertical;
  overflow: hidden;
}

/* Footer acțiuni – Citește mai mult (stânga) + Apreciază (dreapta) */
.gallery-section .gallery-footer {
  display: flex;
  align-items: center;
  justify-content: flex-start;
  flex-wrap: wrap;
  gap: var(--space-sm);
  padding: var(--space-sm) var(--space-lg) var(--space-md);
  border-top: 1px solid var(--border);
  min-height: 52px;
  flex-shrink: 0;
}
.gallery-section .gallery-cta-read {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  font-size: 0.875rem;
  font-weight: 600;
  color: var(--gold-0);
  text-decoration: none;
  min-height: 40px;
  padding: 8px 14px;
  border-radius: var(--radius-md);
  border: 1px solid rgba(191, 159, 105, 0.45);
  background: radial-gradient(circle at 0 0, rgba(191,159,105,0.22) 0, transparent 55%), rgba(20, 20, 23, 0.92);
  box-shadow: 0 0 0 1px rgba(0, 0, 0, 0.35), 0 6px 16px rgba(0, 0, 0, 0.45);
  transition: color 0.18s ease, background 0.18s ease, border-color 0.18s ease, box-shadow 0.18s ease, transform 0.18s ease;
  min-width: 0;
  max-width: 170px;
  flex: 0 1 auto;
}
.gallery-section .gallery-cta-read span:last-of-type {
  display: inline-block;
  max-width: 120px;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
  line-height: 1.25;
  color: inherit;
  opacity: 1;
}
.gallery-section .gallery-cta-read:hover {
  color: var(--gold-1);
  background: radial-gradient(circle at 0 0, rgba(191,159,105,0.3) 0, transparent 60%), rgba(24, 24, 28, 0.98);
  border-color: rgba(191, 159, 105, 0.8);
  box-shadow: 0 0 0 1px rgba(191, 159, 105, 0.55), 0 10px 26px rgba(0, 0, 0, 0.7);
  transform: translateY(-1px);
}
.gallery-section .gallery-cta-read:focus-visible {
  outline: 2px solid var(--gold-0);
  outline-offset: 2px;
}
.gallery-section .gallery-cta-icon {
  width: 16px;
  height: 16px;
  max-width: 16px;
  max-height: 16px;
  flex-shrink: 0;
}

.gallery-section .gallery-like-wrap {
  display: flex;
  align-items: center;
  gap: 6px;
  margin-left: auto;
  flex: 0 0 auto;
}
.card-b2b-cta-group {
  display: flex;
  flex-direction: column;
  align-items: flex-start;
  gap: 6px;
  min-width: 0;
}
.card-b2b-note {
  font-size: 0.82rem;
  line-height: 1.3;
  color: rgba(255, 255, 255, 0.62);
  text-align: center;
}
.gallery-section .gallery-cta-b2b {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-height: 40px;
  padding: 8px 12px;
  border-radius: var(--radius-md);
  border: 1px solid rgba(37, 211, 102, 0.45);
  background: rgba(37, 211, 102, 0.12);
  color: #7ff0ab;
  font-size: 0.82rem;
  font-weight: 700;
  text-decoration: none;
  white-space: nowrap;
  flex: 0 1 auto;
}
.gallery-section .gallery-cta-b2b:hover {
  border-color: rgba(37, 211, 102, 0.8);
  background: rgba(37, 211, 102, 0.2);
}
.gallery-section .gallery-like-btn {
  display: inline-flex;
  align-items: center;
  gap: 4px;
  min-height: 36px;
  padding: 0 8px;
  border: 1px solid rgba(255, 255, 255, 0.2);
  background: rgba(255, 255, 255, 0.04);
  color: rgba(245, 245, 245, 0.92);
  font-size: 0.78rem;
  font-weight: 600;
  border-radius: var(--radius-md);
  cursor: pointer;
  transition: border-color 0.2s ease, color 0.2s ease, background 0.2s ease, box-shadow 0.2s ease, transform 0.2s ease;
  font-family: inherit;
  white-space: nowrap;
}
.gallery-section .gallery-like-label {
  display: none !important;
}
.gallery-section .gallery-like-btn:hover {
  border-color: rgba(221, 184, 116, 0.65);
  color: #f4d194;
  background: rgba(191, 159, 105, 0.1);
  transform: translateY(-1px);
  box-shadow: 0 8px 20px rgba(0, 0, 0, 0.28);
}
.gallery-section .gallery-like-btn:focus-visible {
  outline: 2px solid var(--gold-0);
  outline-offset: 2px;
}
.gallery-section .gallery-like-btn.active {
  border-color: rgba(221, 184, 116, 0.86);
  color: #f8ddb0;
  background: rgba(191, 159, 105, 0.16);
  box-shadow: 0 0 0 1px rgba(221, 184, 116, 0.26) inset;
}
.gallery-section .gallery-like-icon {
  width: 18px;
  height: 18px;
  max-width: 18px;
  max-height: 18px;
  flex-shrink: 0;
}
.gallery-section .gallery-like-count {
  margin-left: 2px;
  font-size: 0.8125rem;
  color: rgba(255, 255, 255, 0.9);
  font-weight: 600;
}
.gallery-section .gallery-like-btn.active .gallery-like-count {
  color: var(--gold-0);
}

/* Desktop/tablet: keep footer actions on a single row */
@media (min-width: 769px) {
  .gallery-section .gallery-footer {
    flex-wrap: nowrap;
    gap: 8px;
  }
  .gallery-section .gallery-cta-read {
    flex: 0 1 auto;
    max-width: 160px;
  }
  .card-b2b-cta-group {
    flex-direction: row;
    align-items: center;
    gap: 8px;
    margin-left: auto;
  }
  .card-b2b-note {
    display: none;
  }
  .gallery-section .gallery-cta-b2b {
    flex: 0 1 auto;
    min-width: 0;
  }
  .gallery-section .gallery-like-wrap {
    margin-left: 0;
    flex: 0 0 auto;
  }
}

@media (max-width: 768px) {
  .gallery-section .gallery-footer {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: var(--space-sm);
    padding: var(--space-sm) var(--space-md) var(--space-md);
    align-items: stretch;
  }
  .gallery-section .gallery-footer > :only-child{
    grid-column: 1 / -1;
  }
  .gallery-section .gallery-cta-read,
  .gallery-section .gallery-cta-b2b {
    width: 100%;
    justify-content: center;
    min-height: 44px;
    padding-inline: 10px;
  }
  .card-b2b-note {
    display: none;
  }
  .gallery-section .gallery-like-wrap {
    display: none;
  }
  .gallery-section .gallery-cta-read span:last-of-type {
    white-space: nowrap;
    text-overflow: ellipsis;
    overflow: hidden;
  }
  .gallery-section .gallery-like-label {
    display: none;
  }
  .gallery-section .gallery-body {
    padding: 10px 12px;
    gap: 6px;
  }
  .gallery-section .gallery-title {
    font-size: 0.92rem;
    line-height: 1.3;
    -webkit-line-clamp: 2;
  }
  .gallery-section .gallery-desc {
    font-size: 0.82rem;
    line-height: 1.42;
    -webkit-line-clamp: 2;
  }
}

/* Editorial tone: Expo cards */
.gallery-section .gallery-card[data-media-type="expo"]{
  background: linear-gradient(180deg, rgba(52,54,60,0.92) 0%, rgba(20,22,26,0.96) 100%);
}
.gallery-section .gallery-card[data-media-type="expo"]:hover{
  /* reduce blue glow on expo */
  box-shadow: 0 0 0 1px rgba(191,159,105,0.35),
              0 14px 34px rgba(0,0,0,0.45);
  border-color: rgba(191,159,105,0.65);
}
.gallery-section .gallery-card[data-media-type="expo"] .gallery-body{
  padding-top: 14px;
  padding-bottom: 12px;
}
.gallery-section .gallery-card[data-media-type="expo"] .gallery-title{
  font-size: 1.02rem;
  letter-spacing: -0.01em;
}
.gallery-section .gallery-card[data-media-type="expo"] .gallery-desc{
  -webkit-line-clamp: 2;
  line-clamp: 2;
}

.gallery-empty {
  color: var(--text-0);
}

.gallery-sort,
.gallery-sort option {
  color: var(--text-0);
  background: var(--bg-2);
}
.gallery-sort {
  transition: border-color 0.2s ease, box-shadow 0.2s ease;
}
.gallery-sort:hover {
  border-color: rgba(191, 159, 105, 0.4);
}
.gallery-sort:focus-visible {
  outline: 2px solid var(--gold-0);
  outline-offset: 2px;
}

.gallery-empty {
  margin-top: var(--space-2xl);
  background: var(--bg-2);
  border: 1px dashed var(--border);
  border-radius: var(--radius-lg);
  padding: var(--space-2xl);
  color: var(--text-1);
  text-align: center;
}
.gallery-empty-icon {
  margin-bottom: var(--space-md);
  color: var(--gold-0);
  opacity: 0.7;
}
.gallery-empty-icon svg {
  width: 32px;
  height: 32px;
  max-width: 32px;
  max-height: 32px;
  display: inline-block;
}
.gallery-empty-text {
  margin: 0 0 var(--space-sm);
  font-size: 1rem;
  font-weight: 600;
  color: var(--text-0);
}
.gallery-empty-hint { margin: 0; font-size: 0.9375rem; line-height: 1.6; }
.gallery-empty-link {
  color: var(--gold-0);
  text-decoration: none;
  font-weight: 600;
  padding: 6px 12px;
  border-radius: var(--radius-md);
  border: 1px solid rgba(191, 159, 105, 0.4);
  transition: background 0.2s ease, color 0.2s ease;
}
.gallery-empty-link:hover {
  background: rgba(191, 159, 105, 0.12);
  color: var(--gold-1);
}
.gallery-empty.gallery-loading {
  border-style: solid;
  border-color: rgba(191, 159, 105, 0.2);
}
.gallery-loading-state {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: var(--space-md);
  padding: var(--space-lg) 0;
}
.gallery-loading-spinner {
  display: block;
  width: 32px;
  height: 32px;
  border: 3px solid rgba(191, 159, 105, 0.2);
  border-top-color: var(--gold-0);
  border-radius: 50%;
  animation: gallery-spin 0.7s linear infinite;
}
.gallery-loading-text {
  color: var(--text-1);
  font-size: 0.9375rem;
}
@keyframes gallery-spin {
  to { transform: rotate(360deg); }
}
@media (prefers-reduced-motion: reduce) {
  .gallery-loading-spinner { animation: none; border-top-color: var(--gold-0); }
}

/* Lightbox – fit viewport, no page scroll; controls + thumbnails */
.gallery-modal {
  position: fixed;
  inset: 0;
  display: none;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  z-index: 9999;
  padding: 12px;
  overflow: auto;
}
html.gallery-lightbox-open,
body.gallery-lightbox-open {
  overflow: hidden !important;
}
.gallery-modal.active {
  display: flex;
}
.gallery-modal-backdrop {
  position: fixed;
  inset: 0;
  background: rgba(10, 12, 16, 0.74);
  backdrop-filter: blur(10px);
  z-index: -1;
  cursor: pointer;
}
.gallery-modal-content {
  position: relative;
  display: flex;
  flex-direction: column;
  max-width: min(1100px, 94vw);
  max-height: min(92vh, 820px);
  width: 100%;
  text-align: center;
  background: var(--bg-1);
  border: 1px solid var(--border);
  border-radius: var(--radius-lg);
  padding: 16px;
  box-shadow: 0 0 0 1px var(--border), 0 24px 48px var(--shadow);
  overflow: hidden;
}
.gallery-modal-img-wrap {
  flex: 1 1 auto;
  min-height: 0;
  display: flex;
  align-items: center;
  justify-content: center;
  max-height: min(68vh, 720px);
  position: relative;
  overflow: auto;
}
.gallery-modal-img {
  max-width: 100%;
  max-height: 100%;
  width: auto;
  height: auto;
  object-fit: contain;
  border-radius: var(--radius-md);
  display: block;
  transition: opacity 0.25s ease;
  opacity: 0;
}
.gallery-modal-img.zoomed{
  transform: scale(1.6);
  transform-origin: center;
  cursor: zoom-out;
}
.gallery-modal-img.loaded {
  opacity: 1;
}
.gallery-modal-img.gallery-modal-img-fade {
  opacity: 0;
}
.gallery-thumbs {
  display: flex;
  flex-wrap: wrap;
  justify-content: center;
  gap: 6px;
  margin-top: 10px;
  padding: 8px 0;
  min-height: 0;
  max-height: 72px;
  overflow-x: auto;
  overflow-y: hidden;
  -webkit-overflow-scrolling: touch;
}
.gallery-thumbs[aria-hidden="true"] {
  display: none;
}
.gallery-thumb {
  flex: 0 0 auto;
  width: 48px;
  height: 48px;
  border-radius: var(--radius-sm);
  overflow: hidden;
  border: 2px solid transparent;
  background: var(--bg-2);
  cursor: pointer;
  padding: 0;
  transition: border-color 0.2s ease, opacity 0.2s ease;
}
.gallery-thumb:hover {
  border-color: var(--border);
  opacity: 0.9;
}
.gallery-thumb.active {
  border-color: var(--gold-0);
  box-shadow: 0 0 0 1px var(--gold-0);
}
.gallery-thumb img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  display: block;
}
.gallery-modal-caption {
  flex-shrink: 0;
  max-height: 120px;
  overflow-y: auto;
  margin-top: 6px;
  padding: 6px 0;
  color: var(--text-0);
  font-size: 0.9rem;
  text-align: left;
  -webkit-overflow-scrolling: touch;
}
.gallery-counter {
  display: block;
  margin-top: 2px;
  color: var(--text-1);
  font-size: 0.85rem;
}
.gallery-nav {
  flex-shrink: 0;
  display: flex;
  justify-content: center;
  flex-wrap: wrap;
  gap: var(--gap-md);
  margin-top: 12px;
  padding-top: 12px;
  border-top: 1px solid var(--border);
}
.gallery-nav button,
.gallery-nav a.gallery-download {
  border: 1px solid var(--border);
  background: var(--bg-2);
  color: var(--text-0);
  border-radius: var(--radius-md);
  padding: 8px 14px;
  min-height: 44px;
  min-width: 44px;
  cursor: pointer;
  text-decoration: none;
  font: inherit;
  font-size: 14px;
  transition: border-color 0.2s ease, color 0.2s ease, background 0.2s ease;
}
.gallery-nav a.gallery-download:hover,
.gallery-nav button:hover {
  background: var(--bg-1);
  border-color: var(--gold-0);
  color: var(--gold-0);
}
.gallery-nav #galleryClose:hover {
  border-color: var(--text-1);
  color: var(--text-0);
}
.product-card--focused {
  box-shadow: 0 0 0 2px rgba(221, 184, 116, 0.55), 0 18px 38px rgba(0,0,0,0.22);
  transform: translateY(-2px);
  transition: box-shadow .25s ease, transform .25s ease;
}
@media (max-width: 768px) {
  .gallery-nav button,
  .gallery-nav a.gallery-download {
    padding: 10px 14px;
  }
  .gallery-modal-caption {
    max-height: 100px;
  }
  .gallery-modal-img-wrap {
    max-height: 90vh;
  }
  .gallery-modal-img {
    max-height: 90vh;
  }
  .gallery-thumb {
    width: 40px;
    height: 40px;
  }
}
