/* ==========================================================================
   NISAFTEYE 2026 CONFERENCE — VIDEO SHOWCASE & PHOTO GALLERY STYLES
   Theme: Safety Engineering | Primary: #001659 | Accent: #ff5e15
   ========================================================================== */

/* --------------------------------------------------------------------------
   1. VIDEO SHOWCASE SECTION (#videos / #conference-video)
   -------------------------------------------------------------------------- */
.conf-video-section {
  background: linear-gradient(135deg, #000c2e 0%, #001659 50%, #000c2e 100%);
  padding: 5.5rem 0;
  position: relative;
  overflow: hidden;
  color: #fff;
}

.conf-video-section::before {
  content: '';
  position: absolute;
  inset: 0;
  background-image:
    linear-gradient(rgba(255, 255, 255, 0.03) 1px, transparent 1px),
    linear-gradient(90deg, rgba(255, 255, 255, 0.03) 1px, transparent 1px);
  background-size: 64px 64px;
  pointer-events: none;
}

.conf-video-section::after {
  content: '';
  position: absolute;
  top: -120px;
  right: -120px;
  width: 450px;
  height: 450px;
  border-radius: 50%;
  background: radial-gradient(circle, rgba(255, 94, 21, 0.16) 0%, transparent 70%);
  pointer-events: none;
}

.conf-video-container {
  position: relative;
  z-index: 2;
  max-width: var(--container-max);
  margin: 0 auto;
  padding: 0 1.5rem;
}

.conf-video-header {
  text-align: center;
  max-width: 820px;
  margin: 0 auto 3rem;
}

.conf-video-header .section-tag {
  display: inline-flex;
  align-items: center;
  gap: 0.5rem;
  background: rgba(255, 94, 21, 0.15);
  color: #ff5e15;
  border: 1px solid rgba(255, 94, 21, 0.35);
  border-radius: 50px;
  padding: 0.45rem 1.25rem;
  font-size: 0.8rem;
  font-weight: 700;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  margin-bottom: 1rem;
}

.conf-video-header h2 {
  font-size: clamp(1.8rem, 3.4vw, 2.7rem);
  font-weight: 800;
  color: #fff;
  margin: 0 0 1rem;
  line-height: 1.2;
}

.conf-video-header h2 span {
  background: linear-gradient(90deg, #ff5e15, #ff8c55);
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
  background-clip: text;
}

.conf-video-header p {
  color: rgba(255, 255, 255, 0.72);
  font-size: 1.05rem;
  line-height: 1.6;
  margin: 0 auto;
}

/* Two-column Video Showcase Layout */
.video-showcase-layout {
  display: grid;
  grid-template-columns: 1fr 380px;
  gap: 2rem;
  align-items: start;
}

/* Main Cinema Stage */
.video-main-stage {
  background: rgba(0, 12, 46, 0.65);
  border: 1px solid rgba(255, 255, 255, 0.1);
  border-radius: 20px;
  padding: 1.25rem;
  box-shadow:
    0 24px 60px rgba(0, 0, 0, 0.5),
    0 0 40px rgba(255, 94, 21, 0.08);
  backdrop-filter: blur(14px);
}

.conf-video-player-wrap {
  position: relative;
  border-radius: 14px;
  overflow: hidden;
  box-shadow:
    0 0 0 1px rgba(255, 255, 255, 0.12),
    0 20px 50px rgba(0, 0, 0, 0.7);
  aspect-ratio: 16 / 9;
  background: #000;
}

.conf-video-player-wrap iframe {
  position: absolute;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  border: 0;
}

/* Video Stage Meta */
.video-stage-meta {
  padding: 1.25rem 0.5rem 0.25rem;
}

.video-active-badge {
  display: inline-flex;
  align-items: center;
  gap: 0.45rem;
  background: rgba(255, 94, 21, 0.18);
  color: #ff7836;
  border: 1px solid rgba(255, 94, 21, 0.35);
  border-radius: 20px;
  padding: 0.3rem 0.85rem;
  font-size: 0.75rem;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.05em;
  margin-bottom: 0.65rem;
}

.video-stage-title {
  font-size: clamp(1.2rem, 2vw, 1.55rem);
  font-weight: 700;
  color: #fff;
  margin: 0 0 0.5rem;
  line-height: 1.35;
}

.video-stage-desc {
  font-size: 0.92rem;
  color: rgba(255, 255, 255, 0.7);
  line-height: 1.55;
  margin: 0;
}

/* Playlist Column */
.video-playlist-column {
  background: rgba(0, 12, 46, 0.55);
  border: 1px solid rgba(255, 255, 255, 0.09);
  border-radius: 20px;
  padding: 1.5rem;
  backdrop-filter: blur(14px);
}

.playlist-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding-bottom: 1rem;
  margin-bottom: 1.15rem;
  border-bottom: 1px solid rgba(255, 255, 255, 0.1);
}

.playlist-header h3 {
  font-size: 1.1rem;
  font-weight: 700;
  color: #fff;
  margin: 0;
  display: flex;
  align-items: center;
  gap: 0.55rem;
}

.playlist-header h3 i {
  color: var(--accent);
}

.playlist-badge {
  font-size: 0.75rem;
  font-weight: 600;
  background: rgba(255, 255, 255, 0.12);
  color: rgba(255, 255, 255, 0.85);
  padding: 0.2rem 0.65rem;
  border-radius: 20px;
}

.video-playlist-list {
  display: flex;
  flex-direction: column;
  gap: 0.85rem;
}

.video-playlist-item {
  display: flex;
  align-items: center;
  gap: 1rem;
  background: rgba(255, 255, 255, 0.04);
  border: 1px solid rgba(255, 255, 255, 0.07);
  border-radius: 12px;
  padding: 0.85rem;
  cursor: pointer;
  transition: all var(--transition-fast);
  text-align: left;
  width: 100%;
}

.video-playlist-item:hover {
  background: rgba(255, 94, 21, 0.09);
  border-color: rgba(255, 94, 21, 0.3);
  transform: translateY(-2px);
}

.video-playlist-item.active {
  background: rgba(255, 94, 21, 0.15);
  border-color: var(--accent);
  box-shadow: 0 4px 18px rgba(255, 94, 21, 0.22);
}

.video-playlist-item .item-icon-box {
  width: 44px;
  height: 44px;
  border-radius: 10px;
  background: rgba(255, 255, 255, 0.08);
  display: flex;
  align-items: center;
  justify-content: center;
  flex-shrink: 0;
  color: #fff;
  font-size: 1.1rem;
  transition: all var(--transition-fast);
}

.video-playlist-item.active .item-icon-box {
  background: var(--accent);
  color: #fff;
  box-shadow: 0 0 15px rgba(255, 94, 21, 0.5);
}

.video-playlist-item .item-meta {
  flex: 1;
  min-width: 0;
}

.video-playlist-item .item-tag {
  display: block;
  font-size: 0.7rem;
  font-weight: 700;
  color: #ff8c55;
  text-transform: uppercase;
  letter-spacing: 0.04em;
  margin-bottom: 2px;
}

.video-playlist-item.active .item-tag {
  color: #ffa579;
}

.video-playlist-item .item-title {
  display: block;
  font-size: 0.88rem;
  font-weight: 600;
  color: #fff;
  line-height: 1.35;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

.video-playlist-item .item-indicator {
  color: rgba(255, 255, 255, 0.4);
  font-size: 0.85rem;
  transition: all var(--transition-fast);
}

.video-playlist-item.active .item-indicator {
  color: var(--accent);
  animation: pulse-ring 1.8s infinite;
}

@keyframes pulse-ring {
  0% { transform: scale(0.9); opacity: 0.7; }
  50% { transform: scale(1.15); opacity: 1; }
  100% { transform: scale(0.9); opacity: 0.7; }
}


/* --------------------------------------------------------------------------
   2. PHOTO GALLERY SECTION (#gallery)
   -------------------------------------------------------------------------- */
.gallery-section {
  padding: 6rem 0;
  background: var(--bg-body);
  position: relative;
  transition: background var(--transition-base);
}

.gallery-section .section-header {
  text-align: center;
  max-width: 800px;
  margin: 0 auto 3rem;
}

/* Gallery Filter Tabs */
.gallery-filter-wrap {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 1.25rem;
  margin-bottom: 2.5rem;
}

.gallery-filter-tabs {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 0.65rem;
  flex-wrap: wrap;
  background: var(--bg-card);
  padding: 0.45rem;
  border-radius: var(--radius-full);
  border: 1px solid var(--border-subtle);
  box-shadow: var(--shadow-sm);
}

.gallery-filter-btn {
  display: inline-flex;
  align-items: center;
  gap: 0.5rem;
  background: transparent;
  border: none;
  padding: 0.6rem 1.25rem;
  border-radius: var(--radius-full);
  font-family: var(--font-body);
  font-size: 0.9rem;
  font-weight: 600;
  color: var(--text-muted);
  cursor: pointer;
  transition: all var(--transition-fast);
}

.gallery-filter-btn:hover {
  color: var(--primary);
  background: var(--primary-subtle);
}

.gallery-filter-btn.active {
  background: var(--primary);
  color: #fff;
  box-shadow: 0 4px 14px rgba(0, 22, 89, 0.25);
}

.gallery-filter-btn .filter-count {
  font-size: 0.75rem;
  font-weight: 700;
  padding: 0.15rem 0.55rem;
  border-radius: 12px;
  background: rgba(0, 0, 0, 0.08);
  color: inherit;
}

.gallery-filter-btn.active .filter-count {
  background: rgba(255, 255, 255, 0.22);
  color: #fff;
}

.gallery-status-bar {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 1rem;
  width: 100%;
  max-width: var(--container-max);
  padding: 0 0.5rem;
  color: var(--text-light);
  font-size: 0.88rem;
}

.gallery-counter-tag {
  font-weight: 600;
  color: var(--text-muted);
}

.gallery-hint-tag {
  font-size: 0.82rem;
  display: inline-flex;
  align-items: center;
  gap: 0.4rem;
  color: var(--text-light);
}

/* Photo Grid */
.gallery-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(280px, 1fr));
  gap: 1.35rem;
  margin-bottom: 3.5rem;
}

.gallery-item {
  position: relative;
  border-radius: 14px;
  overflow: hidden;
  background: var(--bg-card);
  box-shadow: var(--shadow-sm);
  border: 1px solid var(--border-subtle);
  aspect-ratio: 4 / 3;
  cursor: pointer;
  outline: none;
  transition: transform var(--transition-smooth), box-shadow var(--transition-smooth), border-color var(--transition-fast);
  transform: translateZ(0);
}

.gallery-item:hover,
.gallery-item:focus-visible {
  transform: translateY(-6px) scale(1.01);
  box-shadow: var(--shadow-lg);
  border-color: var(--accent);
}

.gallery-item img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  display: block;
  transition: transform 0.6s cubic-bezier(0.16, 1, 0.3, 1);
  background: #e2e8f0;
}

.gallery-item:hover img,
.gallery-item:focus-visible img {
  transform: scale(1.08);
}

/* Card Hover Overlay */
.gallery-item-overlay {
  position: absolute;
  inset: 0;
  background: linear-gradient(
    to bottom,
    rgba(0, 12, 46, 0.35) 0%,
    rgba(0, 12, 46, 0.1) 40%,
    rgba(0, 12, 46, 0.85) 100%
  );
  opacity: 0;
  display: flex;
  flex-direction: column;
  justify-content: space-between;
  padding: 1rem;
  transition: opacity var(--transition-base);
  pointer-events: none;
}

.gallery-item:hover .gallery-item-overlay,
.gallery-item:focus-visible .gallery-item-overlay {
  opacity: 1;
}

.gallery-item-day {
  align-self: flex-start;
  font-size: 0.72rem;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.05em;
  background: var(--accent);
  color: #fff;
  padding: 0.25rem 0.65rem;
  border-radius: 6px;
  box-shadow: 0 2px 8px rgba(0,0,0,0.3);
}

.gallery-item-center {
  align-self: center;
  width: 46px;
  height: 46px;
  border-radius: 50%;
  background: rgba(255, 255, 255, 0.95);
  color: var(--primary);
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 1.15rem;
  box-shadow: 0 4px 16px rgba(0,0,0,0.35);
  transform: scale(0.75);
  transition: transform var(--transition-bounce);
}

.gallery-item:hover .gallery-item-center {
  transform: scale(1);
}

.gallery-item-footer {
  display: flex;
  align-items: center;
  justify-content: space-between;
  color: #fff;
  font-size: 0.78rem;
  font-weight: 500;
}

.gallery-item-filename {
  opacity: 0.9;
  letter-spacing: 0.02em;
}

.gallery-item-action {
  color: #ff8c55;
  display: flex;
  align-items: center;
  gap: 0.3rem;
  font-weight: 600;
}

/* Actions below grid */
.gallery-actions-wrap {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 1rem;
  flex-wrap: wrap;
}

.gallery-actions-wrap .btn {
  padding: 0.85rem 1.85rem;
  font-weight: 700;
}

/* --------------------------------------------------------------------------
   3. LIGHTBOX MODAL (#galleryLightbox)
   -------------------------------------------------------------------------- */
.gallery-lightbox {
  position: fixed;
  inset: 0;
  z-index: 100000;
  display: flex;
  align-items: center;
  justify-content: center;
  opacity: 0;
  visibility: hidden;
  transition: opacity 0.3s ease, visibility 0.3s ease;
}

.gallery-lightbox.active {
  opacity: 1;
  visibility: visible;
}

.lightbox-backdrop {
  position: absolute;
  inset: 0;
  background: rgba(4, 8, 24, 0.94);
  backdrop-filter: blur(16px);
}

.lightbox-container {
  position: relative;
  z-index: 2;
  width: 100%;
  height: 100%;
  display: flex;
  flex-direction: column;
  padding: 1.25rem;
  user-select: none;
}

/* Top Toolbar */
.lightbox-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 0.5rem 1rem;
  background: rgba(14, 21, 48, 0.65);
  border: 1px solid rgba(255, 255, 255, 0.08);
  border-radius: 12px;
  backdrop-filter: blur(10px);
  margin-bottom: 1rem;
}

.lightbox-title-wrap {
  display: flex;
  align-items: center;
  gap: 0.75rem;
}

.lightbox-day-badge {
  background: var(--accent);
  color: #fff;
  font-size: 0.75rem;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.05em;
  padding: 0.25rem 0.75rem;
  border-radius: 20px;
}

.lightbox-counter {
  color: rgba(255, 255, 255, 0.9);
  font-size: 0.88rem;
  font-weight: 600;
}

.lightbox-filename {
  color: rgba(255, 255, 255, 0.5);
  font-size: 0.82rem;
}

.lightbox-controls {
  display: flex;
  align-items: center;
  gap: 0.5rem;
}

.lightbox-ctrl-btn {
  background: rgba(255, 255, 255, 0.08);
  border: 1px solid rgba(255, 255, 255, 0.12);
  color: #fff;
  padding: 0.5rem 0.95rem;
  border-radius: 8px;
  font-size: 0.88rem;
  font-weight: 600;
  display: inline-flex;
  align-items: center;
  gap: 0.45rem;
  cursor: pointer;
  text-decoration: none;
  transition: all var(--transition-fast);
}

.lightbox-ctrl-btn:hover {
  background: var(--accent);
  border-color: var(--accent);
  color: #fff;
  transform: translateY(-2px);
}

.lightbox-close-btn:hover {
  background: #ef4444;
  border-color: #ef4444;
}

/* Lightbox Stage */
.lightbox-body {
  flex: 1;
  position: relative;
  display: flex;
  align-items: center;
  justify-content: center;
  min-height: 0;
  padding: 0 1rem;
}

.lightbox-nav-arrow {
  position: absolute;
  top: 50%;
  transform: translateY(-50%);
  width: 52px;
  height: 52px;
  border-radius: 50%;
  background: rgba(14, 21, 48, 0.75);
  border: 1px solid rgba(255, 255, 255, 0.15);
  color: #fff;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 1.35rem;
  cursor: pointer;
  transition: all var(--transition-fast);
  z-index: 10;
  backdrop-filter: blur(8px);
}

.lightbox-prev-arrow {
  left: 1.5rem;
}

.lightbox-next-arrow {
  right: 1.5rem;
}

.lightbox-nav-arrow:hover {
  background: var(--accent);
  border-color: var(--accent);
  transform: translateY(-50%) scale(1.1);
  box-shadow: 0 0 20px rgba(255, 94, 21, 0.5);
}

.lightbox-stage-viewport {
  position: relative;
  max-width: 90vw;
  max-height: 78vh;
  display: flex;
  align-items: center;
  justify-content: center;
}

.lightbox-full-img {
  max-width: 100%;
  max-height: 78vh;
  width: auto;
  height: auto;
  object-fit: contain;
  border-radius: 10px;
  box-shadow: 0 20px 60px rgba(0, 0, 0, 0.75);
  transition: opacity 0.25s ease, transform 0.25s ease;
}

.lightbox-loading-spinner {
  position: absolute;
  display: none;
  font-size: 2.2rem;
  color: var(--accent);
  z-index: 5;
}

.lightbox-loading-spinner.active {
  display: block;
}

/* Lightbox Caption / Footer */
.lightbox-footer {
  text-align: center;
  padding: 0.65rem 1rem 0.25rem;
}

.lightbox-footer p {
  color: rgba(255, 255, 255, 0.65);
  font-size: 0.88rem;
  margin: 0;
}

/* --------------------------------------------------------------------------
   4. RESPONSIVE DESIGN
   -------------------------------------------------------------------------- */
@media (max-width: 1024px) {
  .video-showcase-layout {
    grid-template-columns: 1fr;
    gap: 1.75rem;
  }
  
  .gallery-grid {
    grid-template-columns: repeat(auto-fill, minmax(240px, 1fr));
    gap: 1rem;
  }
}

@media (max-width: 768px) {
  .conf-video-section,
  .gallery-section {
    padding: 4rem 0;
  }

  .gallery-filter-tabs {
    border-radius: 16px;
    width: 100%;
  }

  .gallery-filter-btn {
    flex: 1 1 45%;
    justify-content: center;
    padding: 0.55rem 0.85rem;
    font-size: 0.82rem;
  }

  .gallery-status-bar {
    flex-direction: column;
    align-items: center;
    text-align: center;
    gap: 0.4rem;
  }

  .lightbox-nav-arrow {
    width: 42px;
    height: 42px;
    font-size: 1.1rem;
  }

  .lightbox-prev-arrow { left: 0.5rem; }
  .lightbox-next-arrow { right: 0.5rem; }

  .lightbox-filename {
    display: none;
  }

  .lightbox-ctrl-btn .ctrl-label {
    display: none;
  }

  .lightbox-stage-viewport {
    max-height: 70vh;
  }

  .lightbox-full-img {
    max-height: 70vh;
  }
}

@media (max-width: 480px) {
  .gallery-grid {
    grid-template-columns: repeat(auto-fill, minmax(160px, 1fr));
    gap: 0.75rem;
  }

  .gallery-item {
    border-radius: 10px;
  }

  .gallery-filter-btn {
    flex: 1 1 100%;
  }

  .video-playlist-column {
    padding: 1rem;
  }

  .video-playlist-item {
    padding: 0.65rem;
  }
}
