/* ==========================================================================
   Whimsy Design System – Gallery Page Styles

   Extracted from Gallery.razor <style> block.
   Includes gallery grid, shoot cards, lightbox, and PrimFeed badge.
   Uses tokens from tokens.css.
   ========================================================================== */

/* ----- Gallery Grid ------------------------------------------------------ */

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

.gallery-thumb {
  position: relative;
  overflow: hidden;
  border-radius: var(--w-radius-md);
  cursor: pointer;
  aspect-ratio: 1 / 1;
  background: #111;
}

.gallery-thumb img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  display: block;
  transition: transform .25s ease, opacity .25s ease;
}

.gallery-thumb:hover img {
  transform: scale(1.04);
  opacity: .85;
}

.gallery-thumb-overlay {
  position: absolute;
  inset: 0;
  display: flex;
  align-items: flex-end;
  padding: .5rem .75rem;
  background: linear-gradient(to top, rgba(0, 0, 0, .55) 0%, transparent 60%);
  opacity: 0;
  transition: opacity var(--w-transition-fast);
}

.gallery-thumb:hover .gallery-thumb-overlay {
  opacity: 1;
}

.gallery-thumb-hint {
  color: #fff;
  font-size: var(--w-font-size-xs);
  letter-spacing: .04em;
  text-transform: uppercase;
}

/* ----- Shoot List Cards -------------------------------------------------- */

.shoot-card {
  display: block;
  text-decoration: none;
  border-radius: var(--w-radius-lg);
  overflow: hidden;
  background: #0d0d0d;
  transition: transform .18s ease, box-shadow .18s ease;
}

.shoot-card:hover {
  transform: translateY(-3px);
  box-shadow: 0 8px 28px rgba(0, 0, 0, .55);
  text-decoration: none;
}

.shoot-card-img {
  aspect-ratio: 4 / 3;
  overflow: hidden;
}

.shoot-card-img img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  display: block;
  transition: transform .3s ease;
}

.shoot-card:hover .shoot-card-img img {
  transform: scale(1.04);
}

.shoot-card-body {
  padding: .75rem 1rem .9rem;
}

.shoot-card-title {
  font-size: 1.05rem;
  font-weight: var(--w-font-weight-medium);
  color: #fff;
  margin: 0 0 .25rem;
}

.shoot-card-meta {
  font-size: .78rem;
  color: rgba(255, 255, 255, .5);
}

/* ----- PrimFeed Badge ---------------------------------------------------- */

.pf-badge {
  display: inline-flex;
  align-items: center;
  gap: .3rem;
  padding: .18rem .55rem;
  border-radius: var(--w-radius-pill);
  border: 1px solid rgba(255, 255, 255, .22);
  background: rgba(255, 255, 255, .08);
  text-decoration: none;
  font-size: var(--w-font-size-xs);
  color: #fff;
}

.pf-badge:hover {
  background: rgba(255, 255, 255, .16);
  text-decoration: none;
}

.pf-badge .material-icons {
  font-size: .9rem;
}

/* ----- Lightbox ---------------------------------------------------------- */

.lb-backdrop {
  position: fixed;
  inset: 0;
  z-index: 1200;
  background: rgba(0, 0, 0, .93);
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  outline: none;
}

.lb-close {
  position: absolute;
  top: 1rem;
  right: 1.25rem;
  background: none;
  border: none;
  color: rgba(255, 255, 255, .7);
  font-size: 2rem;
  line-height: 1;
  cursor: pointer;
  padding: .25rem;
  transition: color var(--w-transition-fast);
  z-index: 10;
}

.lb-close:hover {
  color: #fff;
}

.lb-counter {
  position: absolute;
  top: 1.1rem;
  left: 1.25rem;
  color: rgba(255, 255, 255, .5);
  font-size: .82rem;
  letter-spacing: .06em;
}

.lb-image-wrap {
  max-width: min(92vw, 1100px);
  max-height: 80vh;
  display: flex;
  align-items: center;
  justify-content: center;
}

.lb-image-wrap img {
  max-width: 100%;
  max-height: 80vh;
  object-fit: contain;
  border-radius: 4px;
  display: block;
  box-shadow: 0 20px 60px rgba(0, 0, 0, .7);
}

.lb-nav {
  position: absolute;
  top: 50%;
  transform: translateY(-50%);
  background: rgba(255, 255, 255, .08);
  border: 1px solid rgba(255, 255, 255, .15);
  border-radius: 50%;
  color: #fff;
  width: 3rem;
  height: 3rem;
  display: flex;
  align-items: center;
  justify-content: center;
  cursor: pointer;
  transition: background var(--w-transition-fast);
  z-index: 10;
}

.lb-nav:hover {
  background: rgba(255, 255, 255, .2);
}

.lb-prev { left: 1rem; }
.lb-next { right: 1rem; }

.lb-toolbar {
  margin-top: 1.1rem;
  display: flex;
  gap: .75rem;
  align-items: center;
}

.lb-download {
  display: inline-flex;
  align-items: center;
  gap: .4rem;
  padding: .45rem 1rem;
  border-radius: var(--w-radius-pill);
  background: rgba(255, 255, 255, .1);
  border: 1px solid rgba(255, 255, 255, .2);
  color: #fff;
  font-size: .85rem;
  text-decoration: none;
  transition: background var(--w-transition-fast);
}

.lb-download:hover {
  background: rgba(255, 255, 255, .2);
  color: #fff;
  text-decoration: none;
}

.lb-download .material-icons {
  font-size: 1.1rem;
}

.lb-caption {
  color: rgba(255, 255, 255, .55);
  font-size: .82rem;
  max-width: 600px;
  text-align: center;
}
