/* ═══════════════════════════════════════════════════════════
   GALLERY STYLES — gallery.css
═══════════════════════════════════════════════════════════ */

/* ─── GALLERY HERO SECTION ──────────────────────────────── */
#gallery-hero {
  position: relative;
  min-height: 450px;
  display: flex;
  align-items: center;
  justify-content: center;
  text-align: center;
  background: linear-gradient(135deg, var(--navy) 0%, var(--dark) 50%, var(--royal-dark) 100%);
  overflow: hidden;
  padding: 60px 20px;
  margin-top: 80px;
}

#gallery-hero::before {
  content: '';
  position: absolute;
  inset: 0;
  background: radial-gradient(circle at 30% 60%, rgba(56, 189, 248, 0.1) 0%, transparent 50%);
  pointer-events: none;
}

.gallery-hero-overlay {
  position: absolute;
  inset: 0;
  background: url('data:image/svg+xml,<svg xmlns="http://www.w3.org/2000/svg" viewBox="0 0 100 100"><rect fill="none" stroke="rgba(56,189,248,0.03)" stroke-width="0.5" width="100" height="100"/><rect fill="none" stroke="rgba(56,189,248,0.03)" stroke-width="0.5" x="10" y="10" width="80" height="80"/></svg>');
  opacity: 0.5;
}

.gallery-hero-content {
  position: relative;
  z-index: 2;
  animation: fadeInUp 1s ease-out;
}

.gallery-hero-badge {
  display: inline-block;
  padding: 8px 20px;
  background: rgba(249, 115, 22, 0.15);
  border: 1px solid rgba(249, 115, 22, 0.3);
  border-radius: 50px;
  font-size: 0.85rem;
  color: var(--gold);
  margin-bottom: 20px;
  font-family: var(--font-sub);
  font-weight: 600;
}

.gallery-hero-title {
  font-size: clamp(2rem, 8vw, 3.5rem);
  font-family: var(--font-head);
  color: var(--text);
  margin-bottom: 15px;
  line-height: 1.2;
  font-weight: 800;
}

.gallery-hero-title .gold {
  color: var(--gold);
  display: block;
}

.gallery-hero-sub {
  font-size: clamp(0.95rem, 2vw, 1.15rem);
  color: var(--text-dim);
  max-width: 600px;
  margin: 0 auto;
  font-family: var(--font-body);
  line-height: 1.6;
}

/* ─── GALLERY SECTION ────────────────────────────────────── */
#gallery-section {
  background: var(--black);
  padding: 80px 20px;
  min-height: 100vh;
}

.gallery-inner {
  max-width: 1400px;
  margin: 0 auto;
}

/* ─── FILTER BUTTONS ────────────────────────────────────── */
.gallery-filters {
  display: flex;
  gap: 12px;
  justify-content: center;
  flex-wrap: wrap;
  margin-bottom: 50px;
  animation: fadeIn 0.6s ease-out 0.2s backwards;
}

.gallery-filter-btn {
  padding: 12px 24px;
  border: 2px solid rgba(56, 189, 248, 0.3);
  background: transparent;
  color: var(--text-dim);
  font-size: 0.95rem;
  font-family: var(--font-sub);
  font-weight: 600;
  border-radius: 50px;
  cursor: pointer;
  transition: all 0.3s cubic-bezier(0.25, 1, 0.5, 1);
  display: flex;
  align-items: center;
  gap: 8px;
  position: relative;
  overflow: hidden;
}

.gallery-filter-btn::before {
  content: '';
  position: absolute;
  inset: 0;
  background: var(--gold);
  transform: scaleX(0);
  transform-origin: left;
  transition: transform 0.3s cubic-bezier(0.25, 1, 0.5, 1);
  z-index: -1;
}

.gallery-filter-btn:hover {
  border-color: var(--gold);
  color: var(--text);
}

.gallery-filter-btn:hover::before {
  transform: scaleX(1);
}

.gallery-filter-btn.active {
  background: var(--gold);
  color: var(--navy);
  border-color: var(--gold);
}

.gallery-filter-btn.active::before {
  transform: scaleX(1);
}

.filter-icon {
  font-size: 1.1em;
}

/* ─── GALLERY COUNTER ────────────────────────────────────── */
.gallery-counter-top {
  text-align: center;
  margin-bottom: 40px;
  color: var(--text-dim);
  font-family: var(--font-sub);
  font-size: 0.95rem;
  animation: fadeIn 0.6s ease-out 0.3s backwards;
}

/* ─── GALLERY GRID ──────────────────────────────────────── */
.gallery-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(300px, 1fr));
  gap: 24px;
  margin-bottom: 60px;
}

@media (max-width: 1200px) {
  .gallery-grid {
    grid-template-columns: repeat(auto-fill, minmax(250px, 1fr));
    gap: 20px;
  }
}

@media (max-width: 768px) {
  .gallery-grid {
    grid-template-columns: repeat(auto-fill, minmax(200px, 1fr));
    gap: 16px;
  }
}

@media (max-width: 480px) {
  .gallery-grid {
    grid-template-columns: repeat(2, 1fr);
    gap: 12px;
  }
}

/* ─── GALLERY CARD ──────────────────────────────────────── */
.gallery-card {
  position: relative;
  aspect-ratio: 1;
  border-radius: 8px;
  overflow: hidden;
  cursor: pointer;
  background: var(--dark);
  border: 1px solid var(--glass-border);
  opacity: 0;
  transform: translateY(20px);
  animation: fadeInUp 0.6s ease-out forwards;
}

.gallery-card.hidden {
  display: none;
}

.gallery-card-image {
  width: 100%;
  height: 100%;
  background-size: cover;
  background-position: center;
  background-repeat: no-repeat;
  transition: transform 0.5s cubic-bezier(0.25, 1, 0.5, 1);
}

.gallery-card:hover .gallery-card-image {
  transform: scale(1.08);
}

.gallery-card-overlay {
  position: absolute;
  inset: 0;
  background: rgba(15, 37, 71, 0.85);
  -webkit-backdrop-filter: blur(8px);
  backdrop-filter: blur(8px);
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: 15px;
  opacity: 0;
  transition: opacity 0.4s ease;
  z-index: 2;
}

.gallery-card:hover .gallery-card-overlay {
  opacity: 1;
}

.gallery-card-category {
  display: inline-block;
  padding: 6px 16px;
  background: rgba(249, 115, 22, 0.2);
  border: 1px solid var(--gold);
  border-radius: 30px;
  font-size: 0.8rem;
  color: var(--gold);
  font-family: var(--font-sub);
  font-weight: 600;
}

.gallery-card-button {
  padding: 10px 24px;
  background: var(--gold);
  color: var(--navy);
  border: none;
  border-radius: 6px;
  font-size: 0.85rem;
  font-family: var(--font-sub);
  font-weight: 700;
  cursor: pointer;
  transition: all 0.3s cubic-bezier(0.25, 1, 0.5, 1);
  text-transform: uppercase;
  letter-spacing: 0.5px;
}

.gallery-card-button:hover {
  background: var(--gold-light);
  transform: translateY(-2px);
}

.gallery-card-button:active {
  transform: translateY(0);
}

/* ─── SKELETON LOADER ────────────────────────────────────── */
.gallery-card.loading {
  background: linear-gradient(
    90deg,
    var(--dark) 25%,
    rgba(56, 189, 248, 0.1) 50%,
    var(--dark) 75%
  );
  background-size: 200% 100%;
  animation: skeleton-loading 1.5s infinite;
}

@keyframes skeleton-loading {
  0% { background-position: 200% 0; }
  100% { background-position: -200% 0; }
}

/* ─── LIGHTBOX MODAL ────────────────────────────────────── */
.lightbox-modal {
  position: fixed;
  inset: 0;
  z-index: 9999;
  background: rgba(10, 25, 47, 0.98);
  -webkit-backdrop-filter: blur(12px);
  backdrop-filter: blur(12px);
  display: none;
  align-items: center;
  justify-content: center;
  padding: 20px;
  opacity: 0;
  transition: opacity 0.3s ease;
}

.lightbox-modal.open {
  display: flex;
  opacity: 1;
}

.lightbox-close {
  position: absolute;
  top: 20px;
  right: 20px;
  width: 44px;
  height: 44px;
  border: none;
  background: rgba(255, 255, 255, 0.1);
  color: white;
  font-size: 1.5rem;
  cursor: pointer;
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  transition: all 0.2s ease;
  z-index: 10001;
  -webkit-backdrop-filter: blur(12px);
  backdrop-filter: blur(12px);
}

.lightbox-close:hover {
  background: rgba(255, 255, 255, 0.2);
  transform: scale(1.1);
}

.lightbox-close:active {
  transform: scale(0.95);
}

.lightbox-container {
  position: relative;
  width: 100%;
  max-width: 90vw;
  max-height: 85vh;
  display: flex;
  flex-direction: column;
  align-items: center;
  z-index: 10000;
}

.lightbox-image-wrapper {
  position: relative;
  width: 100%;
  height: 100%;
  display: flex;
  align-items: center;
  justify-content: center;
  border-radius: 8px;
  overflow: hidden;
  background: var(--dark);
  border: 1px solid var(--glass-border);
}

.lightbox-image {
  max-width: 100%;
  max-height: 75vh;
  width: auto;
  height: auto;
  display: block;
  border-radius: 4px;
  animation: fadeIn 0.4s ease;
}

.lightbox-loading {
  position: absolute;
  inset: 0;
  display: flex;
  align-items: center;
  justify-content: center;
  background: rgba(15, 37, 71, 0.5);
  border-radius: 4px;
}

.spinner {
  width: 40px;
  height: 40px;
  border: 3px solid rgba(56, 189, 248, 0.2);
  border-top-color: var(--sky);
  border-radius: 50%;
  animation: spin 0.8s linear infinite;
}

@keyframes spin {
  to { transform: rotate(360deg); }
}

.lightbox-info {
  margin-top: 20px;
  text-align: center;
  display: flex;
  flex-direction: column;
  gap: 8px;
  align-items: center;
}

.lightbox-category {
  display: inline-block;
  padding: 6px 16px;
  background: rgba(249, 115, 22, 0.2);
  border: 1px solid var(--gold);
  border-radius: 30px;
  font-size: 0.8rem;
  color: var(--gold);
  font-family: var(--font-sub);
  font-weight: 600;
}

.lightbox-counter {
  color: var(--text-dim);
  font-family: var(--font-sub);
  font-size: 0.9rem;
}

.lightbox-nav {
  display: flex;
  gap: 16px;
  margin-top: 20px;
  justify-content: center;
}

.lightbox-prev,
.lightbox-next {
  width: 50px;
  height: 50px;
  border: 2px solid var(--gold);
  background: transparent;
  color: var(--gold);
  font-size: 1.5rem;
  cursor: pointer;
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  transition: all 0.2s cubic-bezier(0.25, 1, 0.5, 1);
}

.lightbox-prev:hover,
.lightbox-next:hover {
  background: var(--gold);
  color: var(--navy);
  transform: scale(1.1);
}

.lightbox-prev:active,
.lightbox-next:active {
  transform: scale(0.95);
}

/* ─── ANIMATIONS ────────────────────────────────────────── */
@keyframes fadeIn {
  from {
    opacity: 0;
  }
  to {
    opacity: 1;
  }
}

@keyframes fadeInUp {
  from {
    opacity: 0;
    transform: translateY(20px);
  }
  to {
    opacity: 1;
    transform: translateY(0);
  }
}

/* ─── RESPONSIVE DESIGN ─────────────────────────────────── */
@media (max-width: 768px) {
  #gallery-hero {
    min-height: 320px;
    padding: 40px 20px;
    margin-top: 60px;
  }

  .gallery-hero-title {
    font-size: 1.8rem;
  }

  .gallery-hero-sub {
    font-size: 0.9rem;
  }

  #gallery-section {
    padding: 50px 15px;
  }

  .gallery-filters {
    gap: 8px;
    margin-bottom: 30px;
  }

  .gallery-filter-btn {
    padding: 10px 18px;
    font-size: 0.85rem;
  }

  .lightbox-modal {
    padding: 15px;
  }

  .lightbox-close {
    top: 15px;
    right: 15px;
    width: 40px;
    height: 40px;
  }

  .lightbox-container {
    max-width: 95vw;
    max-height: 80vh;
  }

  .lightbox-image {
    max-height: 60vh;
  }

  .lightbox-nav {
    gap: 12px;
    margin-top: 15px;
  }

  .lightbox-prev,
  .lightbox-next {
    width: 44px;
    height: 44px;
    font-size: 1.2rem;
  }
}

@media (max-width: 480px) {
  #gallery-hero {
    min-height: 280px;
    padding: 30px 15px;
    margin-top: 50px;
  }

  .gallery-hero-title {
    font-size: 1.5rem;
  }

  .gallery-hero-badge {
    font-size: 0.75rem;
    padding: 6px 14px;
  }

  .gallery-filters {
    gap: 6px;
    margin-bottom: 20px;
  }

  .gallery-filter-btn {
    padding: 8px 14px;
    font-size: 0.8rem;
  }

  .filter-icon {
    display: none;
  }

  #gallery-section {
    padding: 30px 10px;
  }

  .gallery-grid {
    gap: 10px;
  }

  .lightbox-container {
    max-width: 100vw;
  }

  .lightbox-image {
    max-height: 50vh;
  }
}

/* ─── NO IMAGES STATE ───────────────────────────────────── */
.gallery-empty {
  text-align: center;
  padding: 60px 20px;
  color: var(--text-dim);
}

.gallery-empty-icon {
  font-size: 3rem;
  margin-bottom: 20px;
}

.gallery-empty-text {
  font-size: 1.1rem;
  color: var(--text-dim);
  font-family: var(--font-body);
}

/* ─── CUSTOM CURSOR ─────────────────────────────────────── */
#cursor-dot {
  position: fixed;
  width: 8px;
  height: 8px;
  background: var(--gold);
  border-radius: 50%;
  pointer-events: none;
  z-index: 99999;
  transform: translate(-50%, -50%) scale(1);
  box-shadow: 0 0 8px var(--gold), 0 0 16px rgba(212, 175, 55, 0.3);
  opacity: 0;
  transition: opacity 0.15s ease, transform 0.2s cubic-bezier(0.25, 1, 0.5, 1);
}

#cursor-dot.cursor-hover {
  transform: translate(-50%, -50%) scale(1.5);
  box-shadow: 0 0 12px var(--gold), 0 0 24px rgba(212, 175, 55, 0.4);
}

/* ─── NAVIGATION ENHANCEMENTS ─────────────────────────────── */
#navbar .nav-links a[href="gallery.html"],
#navbar .nav-links a[href*="gallery"] {
  position: relative;
}

#navbar .nav-links a[href="gallery.html"].active,
#navbar .nav-links a[href*="gallery"].active {
  color: var(--gold);
}

/* ─── MOBILE MENU ────────────────────────────────────────── */
.mobile-menu {
  position: fixed;
  left: 0;
  top: 0;
  width: 100%;
  height: 100vh;
  background: rgba(10, 25, 47, 0.95);
  -webkit-backdrop-filter: blur(12px);
  backdrop-filter: blur(12px);
  display: flex;
  flex-direction: column;
  gap: 20px;
  padding: 100px 20px 20px;
  z-index: 1000;
  transform: translateX(-100%);
  transition: transform 0.3s cubic-bezier(0.25, 1, 0.5, 1);
  overflow-y: auto;
}

.mobile-menu.open {
  transform: translateX(0);
}

.mobile-menu a {
  color: var(--text);
  text-decoration: none;
  font-size: 1.1rem;
  font-family: var(--font-sub);
  padding: 12px 0;
  border-bottom: 1px solid rgba(56, 189, 248, 0.1);
  transition: color 0.2s ease;
}

.mobile-menu a:hover {
  color: var(--gold);
}

.mobile-menu a[href="gallery.html"] {
  color: var(--gold);
}

.mobile-close {
  position: absolute;
  top: 20px;
  right: 20px;
  width: 40px;
  height: 40px;
  border: none;
  background: transparent;
  color: var(--text);
  font-size: 1.8rem;
  cursor: pointer;
  display: flex;
  align-items: center;
  justify-content: center;
  transition: color 0.2s ease;
}

.mobile-close:hover {
  color: var(--gold);
}

/* ─── WHATSAPP FLOATING BUTTON ──────────────────────────── */
#whatsapp-float {
  position: fixed;
  bottom: 30px;
  right: 30px;
  width: 60px;
  height: 60px;
  background: #25D366;
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  box-shadow: 0 4px 16px rgba(37, 211, 102, 0.3);
  z-index: 100;
  transition: all 0.3s ease;
  animation: float-up 0.5s ease;
}

#whatsapp-float:hover {
  background: #20ba58;
  transform: scale(1.1);
  box-shadow: 0 6px 24px rgba(37, 211, 102, 0.4);
}

#whatsapp-float svg {
  width: 32px;
  height: 32px;
  fill: white;
}

.wa-pulse {
  position: absolute;
  width: 100%;
  height: 100%;
  border-radius: 50%;
  border: 2px solid #25D366;
  animation: pulse 2s infinite;
  pointer-events: none;
}

@keyframes pulse {
  0% {
    transform: scale(1);
    opacity: 1;
  }
  100% {
    transform: scale(1.4);
    opacity: 0;
  }
}

@keyframes float-up {
  from {
    transform: translateY(20px);
    opacity: 0;
  }
  to {
    transform: translateY(0);
    opacity: 1;
  }
}

.wa-tooltip {
  position: absolute;
  bottom: 100%;
  right: 0;
  background: rgba(10, 25, 47, 0.95);
  color: var(--text);
  padding: 8px 12px;
  border-radius: 4px;
  font-size: 0.85rem;
  white-space: nowrap;
  margin-bottom: 10px;
  opacity: 0;
  pointer-events: none;
  transition: opacity 0.2s ease;
  z-index: 101;
}

#whatsapp-float:hover .wa-tooltip {
  opacity: 1;
}

/* ─── PRELOADER ─────────────────────────────────────────── */
#preloader {
  position: fixed;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  background: var(--black);
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  z-index: 99999;
}

/* ─── FOOTER INTEGRATION ────────────────────────────────── */
footer {
  background: var(--dark);
  border-top: 1px solid var(--glass-border);
  padding: 60px 20px 20px;
}

.footer-inner {
  max-width: 1400px;
  margin: 0 auto;
}

.footer-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(250px, 1fr));
  gap: 40px;
  margin-bottom: 40px;
}

.footer-brand-logo {
  display: flex;
  align-items: center;
  gap: 12px;
  margin-bottom: 15px;
}

.footer-brand-logo img {
  width: 40px;
  height: 40px;
}

.footer-brand-text {
  font-family: var(--font-head);
  font-size: 1.1rem;
  font-weight: 700;
  color: var(--text);
}

.footer-brand-text span {
  display: block;
  font-size: 0.75rem;
  color: var(--text-dim);
  font-weight: 400;
  margin-top: 2px;
}

.footer-brand-desc {
  color: var(--text-dim);
  font-size: 0.9rem;
  line-height: 1.6;
  margin-bottom: 15px;
}

.footer-social {
  display: flex;
  gap: 12px;
}

.footer-social a {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 36px;
  height: 36px;
  background: rgba(56, 189, 248, 0.1);
  border: 1px solid rgba(56, 189, 248, 0.2);
  border-radius: 50%;
  color: var(--text);
  font-size: 1rem;
  transition: all 0.2s ease;
}

.footer-social a:hover {
  background: var(--gold);
  border-color: var(--gold);
  color: var(--navy);
}

.footer-col-title {
  font-family: var(--font-sub);
  font-size: 0.95rem;
  font-weight: 700;
  color: var(--text);
  margin-bottom: 15px;
  text-transform: uppercase;
  letter-spacing: 1px;
}

.footer-links {
  list-style: none;
  display: flex;
  flex-direction: column;
  gap: 8px;
}

.footer-links a {
  color: var(--text-dim);
  text-decoration: none;
  font-size: 0.9rem;
  transition: color 0.2s ease;
}

.footer-links a:hover {
  color: var(--gold);
}

.footer-contact-item {
  display: flex;
  gap: 10px;
  margin-bottom: 15px;
}

.footer-contact-icon {
  font-size: 1.2rem;
  flex-shrink: 0;
}

.footer-contact-text {
  font-size: 0.9rem;
  color: var(--text-dim);
  line-height: 1.5;
}

.footer-contact-text strong {
  display: block;
  color: var(--text);
  margin-bottom: 2px;
}

.footer-bottom {
  border-top: 1px solid rgba(56, 189, 248, 0.1);
  padding-top: 20px;
  text-align: center;
  display: flex;
  flex-direction: column;
  gap: 10px;
}

.footer-copy {
  color: var(--text-dim);
  font-size: 0.85rem;
}

.footer-copy span {
  color: var(--gold);
  font-weight: 600;
}

.footer-bottom-links {
  color: var(--text-dim);
  font-size: 0.85rem;
}

.footer-bottom-links a {
  color: var(--gold);
  text-decoration: none;
  transition: color 0.2s ease;
}

.footer-bottom-links a:hover {
  text-decoration: underline;
}

/* ─── RESPONSIVE FOOTER ─────────────────────────────────── */
@media (max-width: 768px) {
  .footer-grid {
    gap: 30px;
  }

  .footer-brand-logo img {
    width: 36px;
    height: 36px;
  }

  #whatsapp-float {
    bottom: 20px;
    right: 20px;
    width: 56px;
    height: 56px;
  }

  #whatsapp-float svg {
    width: 28px;
    height: 28px;
  }
}
