/* Root */
.adm-galerie-root{
  font-family: inherit;
  color: inherit;
  max-width: 1200px;
  margin: 0 auto;
  padding: 24px;
  display: grid;
  grid-template-columns: 320px 1fr;
  gap: 28px;
}

/* Sidebar */
.adm-sidebar{
  background: #f5f4f1;
  border: 1px solid rgba(0,0,0,.06);
  border-radius: 22px;
  padding: 18px;
  box-shadow: 0 10px 24px rgba(0,0,0,.06);
  position: sticky;
  top: 18px;
  height: fit-content;
}
.adm-sidebar-head{
  display:flex;
  align-items:center;
  justify-content:space-between;
  margin-bottom: 10px;
}
.adm-sidebar-title{
  font-size: 22px;
  font-weight: 400;
  letter-spacing: .2px;
}

.adm-filter-block{ padding: 14px 0; border-top: 1px solid rgba(0,0,0,.06); }
.adm-filter-label-row{
  display:flex; align-items:center; justify-content:space-between; gap:10px;
  margin-bottom: 10px;
}
.adm-filter-label{ font-size: 16px; font-weight: 400; opacity: .9; }

.adm-clear-one{
  border: none;
  background: transparent;
  padding: 6px 8px;
  cursor: pointer;
  color: #9a8a2a;
  text-decoration: underline;
  font-weight: 400;
}
.adm-clear-one:hover{ opacity: .85; }

/* Buttons */
.adm-btn{
  border-radius: 16px;
  padding: 10px 14px;
  cursor: pointer;
  border: 1px solid rgba(154,138,42,.35);
  background: #fff;
  color: #9a8a2a;
  font-weight: 400;
  box-shadow: 0 6px 16px rgba(0,0,0,.06);
}
.adm-btn:hover{ box-shadow: 0 10px 22px rgba(0,0,0,.10); }
.adm-btn-ghost{
  border-color: rgba(154,138,42,.25);
  background: #fff;
}

.adm-btn-filter{
  display: none;
  align-items:center;
  gap:10px;
}
.adm-icon-sliders{
  width:18px; height:18px; display:inline-block;
  background:
    radial-gradient(circle at 25% 30%, #9a8a2a 0 2px, transparent 3px),
    linear-gradient(#9a8a2a,#9a8a2a) 0 30%/100% 2px no-repeat,
    radial-gradient(circle at 70% 60%, #9a8a2a 0 2px, transparent 3px),
    linear-gradient(#9a8a2a,#9a8a2a) 0 60%/100% 2px no-repeat,
    radial-gradient(circle at 40% 90%, #9a8a2a 0 2px, transparent 3px),
    linear-gradient(#9a8a2a,#9a8a2a) 0 90%/100% 2px no-repeat;
  opacity:.9;
}

.adm-select{
  width: 100%;
  border-radius: 16px;
  border: 1px solid rgba(0,0,0,.10);
  padding: 14px 14px;
  background: #fff;
  color: inherit;
  outline: none;
  box-shadow: 0 10px 20px rgba(0,0,0,.05);
  font-weight: 400;
}

.adm-range-wrap{ display:flex; flex-direction:column; gap:10px; padding: 6px 0 6px; }
.adm-range{ width:100%; accent-color: #9a8a2a; }
.adm-range-meta{ display:flex; align-items:center; justify-content:space-between; opacity:.9; font-weight:400; }
.adm-range-auto{ opacity: .65; }

/* Main */
.adm-main{ min-width: 0; }
.adm-topbar{
  display:flex;
  align-items:flex-start;
  justify-content:space-between;
  gap: 16px;
  margin-bottom: 18px;
}
.adm-title{
  margin: 0;
  font-weight: 400;
  font-size: 52px;
  line-height: 1;
}
.adm-sub{ margin-top: 8px; opacity: .75; font-weight: 400; }

.adm-controls{
  display:flex;
  align-items:flex-end;
  gap: 14px;
  flex-wrap: wrap;
}
.adm-control-group{ display:flex; flex-direction:column; gap:8px; }
.adm-control-label{ opacity:.75; font-weight:400; }

.adm-select-sort{ min-width: 240px; }

/* Grid mode buttons */
.adm-grid-modes{ display:flex; gap:10px; }
.adm-grid-btn{
  width: 44px; height: 44px;
  border-radius: 14px;
  border: 1px solid rgba(154,138,42,.35);
  background: #fff;
  cursor: pointer;
  display:flex;
  align-items:center;
  justify-content:center;
  box-shadow: 0 8px 18px rgba(0,0,0,.06);
}
.adm-grid-btn.is-active{
  outline: none;
  border-color: rgba(154,138,42,.65);
  box-shadow: 0 10px 24px rgba(154,138,42,.18);
}
.adm-grid-ico{
  display:block;
  width: 18px; height: 18px;
  background: #9a8a2a;
  mask-size: contain;
  -webkit-mask-size: contain;
  mask-repeat: no-repeat;
  -webkit-mask-repeat: no-repeat;
  mask-position: center;
  -webkit-mask-position: center;
  opacity: .9;
}
.adm-grid-ico-large{
  -webkit-mask-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='18' height='18'%3E%3Cg fill='black'%3E%3Crect x='1' y='1' width='6' height='6'/%3E%3Crect x='11' y='1' width='6' height='6'/%3E%3Crect x='1' y='11' width='6' height='6'/%3E%3Crect x='11' y='11' width='6' height='6'/%3E%3C/g%3E%3C/svg%3E");
          mask-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='18' height='18'%3E%3Cg fill='black'%3E%3Crect x='1' y='1' width='6' height='6'/%3E%3Crect x='11' y='1' width='6' height='6'/%3E%3Crect x='1' y='11' width='6' height='6'/%3E%3Crect x='11' y='11' width='6' height='6'/%3E%3C/g%3E%3C/svg%3E");
}
.adm-grid-ico-small{
  -webkit-mask-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='18' height='18'%3E%3Cg fill='black'%3E%3Crect x='1' y='1' width='4' height='4'/%3E%3Crect x='7' y='1' width='4' height='4'/%3E%3Crect x='13' y='1' width='4' height='4'/%3E%3Crect x='1' y='7' width='4' height='4'/%3E%3Crect x='7' y='7' width='4' height='4'/%3E%3Crect x='13' y='7' width='4' height='4'/%3E%3Crect x='1' y='13' width='4' height='4'/%3E%3Crect x='7' y='13' width='4' height='4'/%3E%3Crect x='13' y='13' width='4' height='4'/%3E%3C/g%3E%3C/svg%3E");
          mask-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='18' height='18'%3E%3Cg fill='black'%3E%3Crect x='1' y='1' width='4' height='4'/%3E%3Crect x='7' y='1' width='4' height='4'/%3E%3Crect x='13' y='1' width='4' height='4'/%3E%3Crect x='1' y='7' width='4' height='4'/%3E%3Crect x='7' y='7' width='4' height='4'/%3E%3Crect x='13' y='7' width='4' height='4'/%3E%3Crect x='1' y='13' width='4' height='4'/%3E%3Crect x='7' y='13' width='4' height='4'/%3E%3Crect x='13' y='13' width='4' height='4'/%3E%3C/g%3E%3C/svg%3E");
}

/* Grid */
.adm-grid{
  display:grid;
  gap: 22px;
}
.adm-grid.adm-grid-large{ grid-template-columns: repeat(3, minmax(0, 1fr)); }
.adm-grid.adm-grid-small{ grid-template-columns: repeat(4, minmax(0, 1fr)); }

/* Card */
.adm-card {
  border-radius: 20px;
  background: #fff;
  border: 1px solid rgba(0,0,0,.08);
  overflow: hidden;
  box-shadow: 0 12px 26px rgba(0,0,0,.08);
  transition: transform .18s ease, box-shadow .18s ease;
}

.adm-card:hover {
  transform: translateY(-2px);
  box-shadow: 0 18px 36px rgba(0,0,0,.12);
}

.adm-card-artist {
  display: -webkit-box;
  -webkit-line-clamp: 2;
  -webkit-box-orient: vertical;
  overflow: hidden;

  line-height: 1.25;
  min-height: calc(1.25em * 2);
}

.adm-card-title {
  display: -webkit-box;
  -webkit-line-clamp: 2;
  -webkit-box-orient: vertical;
  overflow: hidden;

  line-height: 1.3;
  min-height: calc(1.3em * 2);
}

.adm-card-technique {
  display: -webkit-box;
  -webkit-line-clamp: 3;
  -webkit-box-orient: vertical;
  overflow: hidden;

  line-height: 1.35;
  min-height: calc(1.35em * 3);
  color: #8c8c8c;
}

/* Image */
.adm-img-wrap{
  background: #fff;
  border-bottom: 1px solid rgba(0,0,0,.06);
}
.adm-img{
  width: 100%;
  height: auto;
  display:block;
}

/* Body layout */
.adm-body{
  position: relative;
  padding: 16px 16px 18px;
  min-height: 170px;
}

.adm-artist{
  color: #9a8a2a;
  font-weight: 400;
  font-size: 22px;
  margin-bottom: 10px;
  line-height: 1.15;
  display: -webkit-box;
  -webkit-line-clamp: 2;
  -webkit-box-orient: vertical;
  overflow: hidden;
}

.adm-work-title{
  font-weight: 400;
  font-size: 18px;
  margin: 0 0 10px;
  opacity: .88;
  display: -webkit-box;
  -webkit-line-clamp: 2;
  -webkit-box-orient: vertical;
  overflow: hidden;
}

.adm-tech-desc{
  opacity: .70;
  font-weight: 400;
  margin-bottom: 14px;
  display: -webkit-box;
  -webkit-line-clamp: 4;
  -webkit-box-orient: vertical;
  overflow: hidden;
  line-height: 1.35;
  min-height: calc(1.35em * 4);
}

.adm-price{
  color: #9a8a2a;
  font-weight: 400;
  white-space: nowrap;
  font-size: 18px;
}
.adm-price:empty{ display:none; }

/* Cert icon: VISÍVEL e clicável */
.adm-cert-btn{
  position: absolute;
  right: 14px;
  bottom: 14px;
  width: 58px;
  height: 58px;
  border-radius: 999px;
  border: none;
  background: transparent;
  cursor: pointer;
  padding: 0;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  z-index: 5;
}
.adm-cert-ico{
  width: 58px;
  height: 58px;
  display: block;
  filter: drop-shadow(0 10px 18px rgba(0,0,0,.18));
}

/* Lightbox */
.adm-lightbox{
  position: fixed;
  inset: 0;
  background: rgba(0,0,0,.72);
  display:none;
  flex-direction: column;
  align-items:center;
  justify-content:center;
  z-index: 999999;
  padding: 24px;
  gap: 20px;
}
.adm-lightbox.is-open{ display:flex; }

/* Botão fechar (X) — centralizado, clicável no mobile, acessível */
.adm-lightbox-close{
  position: absolute;
  top: 14px;
  right: 18px;

  width: 44px;
  height: 44px;
  border-radius: 14px;

  border: 1px solid rgba(255,255,255,.25);
  background: rgba(0,0,0,.25);
  color: #fff;

  font-size: 28px;
  cursor: pointer;
  z-index: 10;

  display: flex;
  align-items: center;
  justify-content: center;
  padding: 0;
  line-height: 1;

  -webkit-tap-highlight-color: transparent;
  touch-action: manipulation;

  transition: transform .2s ease, background .2s ease, box-shadow .2s ease, border-color .2s ease;
}

.adm-lightbox-close:hover{
  background: rgba(0,0,0,.45);
  transform: scale(1.05);
}

/* Acessibilidade: foco visível (teclado) */
.adm-lightbox-close:focus,
.adm-lightbox-close:focus-visible{
  outline: none;
  box-shadow: 0 0 0 4px rgba(255,255,255,.25);
  border-color: rgba(255,255,255,.45);
}

/* Mobile: aumenta um pouco o alvo e ajusta posição */
@media (max-width: 480px){
  .adm-lightbox-close{
    top: 10px;
    right: 10px;
    width: 48px;
    height: 48px;
    border-radius: 16px;
    font-size: 30px;
  }
}

/* Lightbox inner container */
.adm-lightbox-inner{
  display: flex;
  align-items: center;
  justify-content: center;
  max-width: 95vw;
  max-height: calc(100vh - 140px);
}

.adm-lightbox-img{
  max-width: min(1100px, 90vw);
  max-height: calc(100vh - 140px);
  border-radius: 16px;
  box-shadow: 0 24px 70px rgba(0,0,0,.55);
  object-fit: contain;
}

/* Lightbox actions (botões) */
.adm-lightbox-actions{
  display: flex;
  gap: 12px;
  flex-wrap: wrap;
  justify-content: center;
  align-items: center;
  padding: 0 24px;
  position: relative;
  z-index: 5;
}

.adm-lightbox-action{
  border-radius: 14px;
  padding: 12px 20px;
  cursor: pointer;
  border: 1px solid rgba(154,138,42,.45);
  background: #fff;
  color: #9a8a2a;
  font-weight: 500;
  font-size: 15px;
  box-shadow: 0 8px 18px rgba(0,0,0,.18);
  text-decoration: none;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  min-width: 140px;
  transition: all .2s ease;
}

.adm-lightbox-action:hover{
  transform: translateY(-2px);
  box-shadow: 0 12px 28px rgba(0,0,0,.28);
  border-color: rgba(154,138,42,.65);
}

.adm-lightbox-action:active{
  transform: translateY(0);
}

/* Ícones SVG inline nos botões */
.adm-action-icon{
  width: 18px;
  height: 18px;
  display: inline-block;
}

/* Responsive */
@media (max-width: 1100px){
  .adm-galerie-root{ grid-template-columns: 1fr; }
  .adm-sidebar{ position: relative; top: auto; }
  .adm-btn-filter{ display:inline-flex; }
  .adm-sidebar.is-collapsed{ display:none; }
  .adm-grid.adm-grid-large{ grid-template-columns: repeat(2, minmax(0,1fr)); }
  .adm-grid.adm-grid-small{ grid-template-columns: repeat(3, minmax(0,1fr)); }
  .adm-select-sort{ min-width: 200px; }
}

@media (max-width: 700px){
  .adm-grid.adm-grid-large{ grid-template-columns: 1fr; }
  .adm-grid.adm-grid-small{ grid-template-columns: repeat(2, minmax(0,1fr)); }
  .adm-title{ font-size: 44px; }
  
  .adm-lightbox{
    padding: 16px;
    gap: 16px;
  }
  
  .adm-lightbox-inner{
    max-height: calc(100vh - 120px);
  }
  
  .adm-lightbox-img{
    max-height: calc(100vh - 120px);
  }
  
  .adm-lightbox-actions{
    gap: 8px;
    padding: 0 16px;
  }
  
  .adm-lightbox-action{
    min-width: 100px;
    padding: 10px 14px;
    font-size: 13px;
  }
}

/* Rodapé */
.adm-footer{
  margin-top: 14px;
  display: flex;
  align-items: center;
  justify-content: space-between;
}

/* Certificado flutuante */
.adm-img-wrap {
  position: relative;
}

.adm-cert-float {
  position: absolute;
  bottom: 12px;
  right: 12px;
  background: transparent;
  border: none;
  cursor: pointer;
  z-index: 3;
}