/* GenTe — Gallery Page Stylesheet
 * Integrates with style.css :root variables
 */

/* 1. Page Hero */
.gallery-hero {
  position: relative;
  min-height: 85vh;
  padding: 120px 0 100px;
  display: flex;
  align-items: center;
  justify-content: center;
  text-align: center;
  overflow: hidden;
  isolation: isolate;
}

.gallery-hero-inner {
  max-width: 980px;
  margin: 0 auto;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  position: relative;
  z-index: 2;
}

.gallery-hero .hero-title {
  margin-top: 1.8rem;
  font-size: clamp(2.8rem, 6vw, 5rem);
  line-height: 1.05;
}

.gallery-hero .hero-sub {
  margin: 1.5rem auto 0;
  max-width: 680px;
  font-size: 1.15rem;
  color: var(--muted);
  line-height: 1.6;
}

.gallery-hero-meta {
  margin-top: 2.2rem;
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  justify-content: center;
  gap: 1rem 1.8rem;
  color: var(--muted);
  font-size: 0.85rem;
}

.gallery-hero-meta span {
  display: inline-flex;
  align-items: center;
  gap: 0.4rem;
  padding: 0.45rem 1rem;
  border-radius: 999px;
  background: rgba(93, 74, 140, 0.18);
  border: 1px solid var(--border);
}

.gallery-hero-meta i {
  color: var(--purple-accent);
  width: 1rem;
  height: 1rem;
}


/* 2. Category Filter Bar */
.filter-bar-container {
  margin-top: 2.5rem;
  display: flex;
  justify-content: center;
  align-items: center;
  flex-wrap: wrap;
  gap: 0.6rem;
}

.gal-cat-btn {
  display: inline-flex;
  align-items: center;
  gap: 0.5rem;
  padding: 0.6rem 1.25rem;
  border-radius: 999px;
  font-size: 0.88rem;
  font-weight: 500;
  color: var(--muted);
  background: rgba(93, 74, 140, 0.15);
  border: 1px solid var(--border);
  cursor: pointer;
  transition: all 0.25s ease;
}

.gal-cat-btn:hover {
  color: var(--fg);
  border-color: var(--purple-vivid);
  background: rgba(138, 117, 214, 0.22);
}

.gal-cat-btn.active {
  color: var(--fg);
  background: linear-gradient(135deg, rgba(138, 117, 214, 0.35), rgba(93, 74, 140, 0.55));
  border-color: var(--purple-accent);
  box-shadow: 0 0 20px rgba(180, 156, 255, 0.3);
}

.gal-cat-btn .count-badge {
  font-size: 0.72rem;
  padding: 0.1rem 0.45rem;
  border-radius: 999px;
  background: rgba(255, 255, 255, 0.12);
  color: var(--purple-light);
}

/* 3. Featured Project Spotlight */
.featured-project {
  margin-top: 4rem;
  padding: 2.5rem;
  border-radius: 1.8rem;
  display: grid;
  grid-template-columns: 1fr;
  gap: 2.5rem;
  align-items: center;
}

@media (min-width: 1024px) {
  .featured-project {
    grid-template-columns: 1.1fr 1fr;
  }
}

.featured-img-wrap {
  position: relative;
  border-radius: 1.25rem;
  overflow: hidden;
  box-shadow: var(--shadow-card), 0 0 40px rgba(180, 156, 255, 0.2);
  border: 1px solid var(--border-bright);
}

.featured-img-wrap img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  display: block;
  transition: transform 0.5s ease;
}

.featured-img-wrap:hover img {
  transform: scale(1.04);
}

.featured-badge-top {
  position: absolute;
  top: 16px;
  left: 16px;
  background: rgba(14, 9, 24, 0.85);
  backdrop-filter: blur(10px);
  -webkit-backdrop-filter: blur(10px);
  padding: 0.4rem 0.9rem;
  border-radius: 999px;
  font-size: 0.78rem;
  font-weight: 600;
  color: var(--purple-accent);
  border: 1px solid var(--border-bright);
}

.featured-content h2 {
  font-size: clamp(1.8rem, 3.5vw, 2.5rem);
  margin-top: 0.8rem;
}

.featured-stats {
  margin: 1.8rem 0;
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 1rem;
}

.f-stat {
  padding: 0.85rem 1rem;
  border-radius: 0.9rem;
  background: rgba(93, 74, 140, 0.15);
  border: 1px solid var(--border);
  text-align: center;
}

.f-stat-v {
  font-size: 1.4rem;
  font-weight: 700;
  line-height: 1;
}

.f-stat-l {
  font-size: 0.72rem;
  color: var(--muted);
  margin-top: 0.35rem;
  text-transform: uppercase;
  letter-spacing: 0.05em;
}

.featured-actions {
  display: flex;
  flex-wrap: wrap;
  gap: 1rem;
}

/* 4. Before / After Transformation Slider */
.ba-section {
  margin-top: 5rem;
}

.ba-slider-container {
  position: relative;
  width: 100%;
  max-width: 960px;
  margin: 2.5rem auto 0;
  aspect-ratio: 16 / 9;
  border-radius: 1.5rem;
  overflow: hidden;
  border: 1px solid var(--border-bright);
  box-shadow: var(--shadow-card), 0 0 50px rgba(180, 156, 255, 0.2);
  user-select: none;
  touch-action: none;
}

.ba-image {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
}

.ba-image img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  display: block;
}

.ba-after {
  position: absolute;
  top: 0;
  left: 0;
  bottom: 0;
  width: 50%;
  overflow: hidden;
  z-index: 2;
  border-right: 2px solid var(--purple-accent);
}

.ba-after img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  max-width: none;
}

.ba-handle {
  position: absolute;
  top: 0;
  bottom: 0;
  left: 50%;
  width: 4px;
  background: var(--purple-vivid);
  z-index: 10;
  transform: translateX(-50%);
  cursor: ew-resize;
  box-shadow: 0 0 16px var(--purple-vivid);
}

.ba-handle-button {
  position: absolute;
  top: 50%;
  left: 50%;
  transform: translate(-50%, -50%);
  width: 2.75rem;
  height: 2.75rem;
  border-radius: 50%;
  background: var(--purple-accent);
  color: #0c0816;
  display: flex;
  align-items: center;
  justify-content: center;
  box-shadow: 0 0 20px rgba(200, 182, 255, 0.8);
  font-weight: 700;
}

.ba-label {
  position: absolute;
  top: 16px;
  z-index: 8;
  padding: 0.4rem 0.9rem;
  border-radius: 999px;
  font-size: 0.78rem;
  font-weight: 600;
  backdrop-filter: blur(10px);
  -webkit-backdrop-filter: blur(10px);
  border: 1px solid var(--border);
}

.ba-label.before-label {
  left: 16px;
  background: rgba(14, 9, 24, 0.8);
  color: var(--muted);
}

.ba-label.after-label {
  right: 16px;
  background: rgba(93, 74, 140, 0.85);
  color: var(--fg);
  border-color: var(--purple-accent);
}

/* 5. Video Gallery Section */
.video-section {
  margin-top: 5rem;
}

.video-grid {
  margin-top: 2.5rem;
  display: grid;
  gap: 1.5rem;
  grid-template-columns: 1fr;
}

@media (min-width: 640px) {
  .video-grid { grid-template-columns: repeat(2, 1fr); }
}

@media (min-width: 1024px) {
  .video-grid { grid-template-columns: repeat(3, 1fr); }
}

.video-card {
  border-radius: 1.4rem;
  overflow: hidden;
  border: 1px solid var(--border);
  transition: transform 0.35s ease, border-color 0.35s ease, box-shadow 0.35s ease;
  cursor: pointer;
}

.video-card:hover {
  transform: translateY(-5px);
  border-color: var(--purple-vivid);
  box-shadow: var(--shadow-card), 0 0 35px rgba(180, 156, 255, 0.22);
}

.video-thumb {
  position: relative;
  aspect-ratio: 16 / 9;
  overflow: hidden;
  background: var(--bg-2);
}

.video-thumb img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  transition: transform 0.5s ease;
}

.video-card:hover .video-thumb img {
  transform: scale(1.06);
}

.video-play-btn {
  position: absolute;
  top: 50%;
  left: 50%;
  transform: translate(-50%, -50%);
  width: 3.5rem;
  height: 3.5rem;
  border-radius: 50%;
  background: rgba(138, 117, 214, 0.85);
  backdrop-filter: blur(10px);
  -webkit-backdrop-filter: blur(10px);
  color: #fff;
  display: flex;
  align-items: center;
  justify-content: center;
  box-shadow: 0 0 30px rgba(180, 156, 255, 0.6);
  transition: transform 0.3s ease, background 0.3s ease;
}

.video-card:hover .video-play-btn {
  transform: translate(-50%, -50%) scale(1.12);
  background: var(--purple-vivid);
}

.video-play-btn i {
  width: 1.5rem;
  height: 1.5rem;
  margin-left: 2px;
}

.video-duration {
  position: absolute;
  bottom: 12px;
  right: 12px;
  background: rgba(12, 8, 22, 0.85);
  backdrop-filter: blur(6px);
  padding: 0.2rem 0.6rem;
  border-radius: 0.4rem;
  font-size: 0.72rem;
  color: var(--fg);
  border: 1px solid rgba(180, 156, 255, 0.2);
}

.video-info {
  padding: 1.4rem;
}

.video-info h3 {
  font-size: 1.08rem;
  color: var(--fg);
}

.video-info p {
  margin-top: 0.4rem;
  font-size: 0.85rem;
  color: var(--muted);
}

/* 6. Load More Section */
.load-more-container {
  margin-top: 3.5rem;
  text-align: center;
}

.btn-load-more {
  display: inline-flex;
  align-items: center;
  gap: 0.6rem;
  padding: 0.95rem 2.2rem;
  font-size: 0.95rem;
  border-radius: 999px;
  background: rgba(93, 74, 140, 0.25);
  border: 1px solid var(--border-bright);
  color: var(--fg);
  cursor: pointer;
  transition: all 0.3s ease;
}

.btn-load-more:hover {
  background: rgba(138, 117, 214, 0.4);
  border-color: var(--purple-vivid);
  transform: translateY(-2px);
  box-shadow: 0 0 30px rgba(180, 156, 255, 0.3);
}

.btn-load-more.loading .spinner {
  display: inline-block;
  width: 1.1rem;
  height: 1.1rem;
  border: 2px solid rgba(255, 255, 255, 0.3);
  border-top-color: var(--purple-accent);
  border-radius: 50%;
  animation: spin 0.8s linear infinite;
}

@keyframes spin {
  to { transform: rotate(360deg); }
}

/* Video Modal */
.video-modal {
  position: fixed;
  inset: 0;
  z-index: 9500;
  background: rgba(0, 0, 0, 0.92);
  backdrop-filter: blur(16px);
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 2rem;
  opacity: 0;
  pointer-events: none;
  transition: opacity 0.35s ease;
}

.video-modal.open {
  opacity: 1;
  pointer-events: all;
}

.video-modal-inner {
  position: relative;
  width: 100%;
  max-width: 900px;
  aspect-ratio: 16 / 9;
  background: #000;
  border-radius: 1.2rem;
  overflow: hidden;
  box-shadow: 0 40px 80px rgba(0, 0, 0, 0.8);
  border: 1px solid var(--border-bright);
}

.video-modal iframe {
  width: 100%;
  height: 100%;
  border: 0;
}

.video-modal-close {
  position: absolute;
  top: 1rem;
  right: 1rem;
  width: 2.5rem;
  height: 2.5rem;
  border-radius: 50%;
  background: rgba(255, 255, 255, 0.15);
  border: 1px solid rgba(255, 255, 255, 0.2);
  color: #fff;
  display: flex;
  align-items: center;
  justify-content: center;
  cursor: pointer;
  font-size: 1.2rem;
  z-index: 10;
  transition: background 0.2s ease;
}

.video-modal-close:hover {
  background: rgba(180, 0, 60, 0.5);
}
