/* RB Holmes Gallery — scoped gallery styles only */

.rb-gallery-intro{
  max-width:1200px;
  margin-bottom:2rem;
}

.rb-gallery-intro p{
  font-family:var(--sans);
  color:var(--muted);
}

.rb-gallery-tools{
  display:flex;
  gap:.75rem;
  flex-wrap:wrap;
  align-items:center;
  margin:0 0 1.25rem 0;
}

.rb-gallery-search{
  width:min(420px,100%);
  padding:.72rem .85rem;
  border:1px solid var(--border);
  border-radius:999px;
  background:#fff;
  font:inherit;
  font-family:var(--sans);
}

.rb-gallery-grid{
  display:grid;
  grid-template-columns:repeat(3, minmax(0, 1fr));
  gap:1.4rem;
}

.rb-gallery-card{
  background:var(--panel);
  border:1px solid var(--border);
  box-shadow:0 6px 18px rgba(0,0,0,.08);
  overflow:hidden;
  padding:10px;
  transition:transform .18s ease, box-shadow .18s ease;
}

.rb-gallery-card:hover{
  transform:translateY(-2px);
  box-shadow:0 14px 34px rgba(0,0,0,.13);
}

.rb-gallery-card button{
  display:block;
  width:100%;
  padding:0;
  border:0;
  background:none;
  color:inherit;
  text-align:left;
  cursor:pointer;
}

.rb-gallery-thumb{
  width:100%;
  height:300px;
  display:block;
  object-fit:contain;
  background:#f3f1ec;
  border:1px solid rgba(0,0,0,.08);
}

.rb-gallery-card-body{
  padding:1rem .25rem .25rem;
}

.rb-gallery-card h3{
  margin:0 0 .35rem 0;
  font-size:1.05rem;
  line-height:1.25;
}

.rb-gallery-meta{
  margin:0;
  font-family:var(--sans);
  color:var(--muted);
  font-size:.86rem;
  line-height:1.45;
}

.rb-filter{
  padding:.55rem .8rem;
  border:1px solid var(--border);
  background:#fff;
  font-family:var(--sans);
  font-size:.78rem;
  letter-spacing:.05em;
  text-transform:uppercase;
  cursor:pointer;
}

.rb-filter:hover,
.rb-filter.is-active{
  background:var(--accent);
  color:#fff;
  border-color:var(--accent);
}

/* EXPANDED IMAGE PANEL */

.rb-gallery-panel{
  position:fixed;
  inset:0;
  z-index:999;
  display:none;
  background:rgba(0,0,0,.72);
  padding:3vh 3vw;
  overflow:auto;
}

.rb-gallery-panel.is-open{
  display:flex;
  align-items:flex-start;
  justify-content:center;
}

.rb-gallery-panel-inner{
  display:inline-block;
  width:auto;
  max-width:100%;
  background:transparent;
  margin:auto;
}

.rb-gallery-large-wrap{
  display:inline-block;
  background:var(--panel);
  border:1px solid var(--border);
  box-shadow:0 24px 70px rgba(0,0,0,.22);
  padding:12px;
}

.rb-gallery-large{
  width:auto;
  max-width:100%;
  max-height:80vh;
  object-fit:contain;
  display:block;
  margin:0 auto;
  border:1px solid rgba(0,0,0,.08);
}

.rb-gallery-info{
  max-width:900px;
  margin:1.4rem auto 0;
  background:var(--panel);
  border:1px solid var(--border);
  box-shadow:0 12px 32px rgba(0,0,0,.08);
  padding:2rem 1.6rem 2.3rem;
  font-family:var(--sans);
}

.rb-gallery-info h2{
  margin:0 0 .6rem 0;
  font-family:var(--serif);
  font-size:1.45rem;
  line-height:1.2;
}

.rb-gallery-description{
  color:#2a2a2a;
}

.rb-gallery-archive{
  margin-top:1rem;
  padding-top:1rem;
  border-top:1px solid var(--border);
  color:var(--muted);
  font-size:.9rem;
}

.rb-gallery-close{
  position:fixed;
  top:22px;
  right:82px;
  width:44px;
  height:44px;
  border:none;
  background:rgba(0,0,0,.72);
  color:#fff;
  font-size:1.2rem;
  cursor:pointer;
  z-index:1001;
  box-shadow:0 8px 24px rgba(0,0,0,.25);
}

.rb-gallery-close:hover{
  background:#000;
}

/* ARCHIVE / HISTORY ARTICLE STYLES */

.archive-quote{
  margin:2rem 0;
  padding:1.25rem 1.5rem;
  border-left:3px solid var(--accent);
  background:rgba(36,58,90,.04);
  font-style:italic;
  font-size:1.02rem;
  line-height:1.75;
}

.archive-quote p{
  margin:0;
}

.archive-caption{
  margin-top:.5rem;
  font-size:.82rem;
  line-height:1.45;
  color:var(--muted);
  font-family:var(--sans);
}

.archive-meta{
  font-family:var(--sans);
  font-size:.9rem;
  color:var(--muted);
  margin-bottom:2rem;
}

.archive-image{
  margin:2rem 0;
}

.archive-image img{
  width:100%;
  height:auto;
  display:block;
  border:1px solid var(--border);
}

.archive-section{
  margin-top:3rem;
}

.archive-section h2,
.archive-section h3{
  margin-bottom:.75rem;
}

.archive-text{
  max-width:78ch;
}

.archive-text p{
  margin-bottom:1.25rem;
}

/* RESPONSIVE */

@media (max-width:980px){

  .rb-gallery-grid{
    grid-template-columns:repeat(2, minmax(0, 1fr));
  }

}

@media (max-width:760px){

  .rb-gallery-panel{
    padding:2vh 4vw;
  }

  .rb-gallery-panel-inner{
    width:100%;
  }

  .rb-gallery-grid{
    grid-template-columns:1fr;
  }

  .rb-gallery-thumb{
    height:280px;
  }

  .rb-gallery-large-wrap{
    padding:10px;
  }

  .rb-gallery-info{
    margin:1rem auto 0;
    padding:1.4rem 1.1rem 1.7rem;
  }

  .rb-gallery-close{
    top:12px;
    right:12px;
    width:40px;
    height:40px;
  }

}