/* Portfolio Page Styles */
body {
  opacity: 0;
  animation: pageLoad 0.6s ease-out forwards;
}

@keyframes pageLoad {
  from {
    opacity: 0;
    transform: translateY(30px);
  }
  to {
    opacity: 1;
    transform: translateY(0);
  }
}

@keyframes pageFadeOut {
  from {
    opacity: 1;
    transform: translateY(0);
  }
  to {
    opacity: 0;
    transform: translateY(-30px);
  }
}

.portfolio-header {
  background: var(--bg-color);
  padding: 2rem 1.5rem;
  text-align: center;
  border-bottom: 1px solid rgba(255, 255, 255, 0.1);
}

.nav-bar {
  margin-bottom: 2rem;
}

.nav-link {
  color: var(--text-secondary);
  text-decoration: none;
  font-size: 0.9rem;
  transition: color 0.3s ease;
}

.nav-link:hover {
  color: var(--primary-color);
}

.header-content h1 {
  font-size: 2.5rem;
  color: var(--primary-color);
  margin-bottom: 0.5rem;
  font-weight: 700;
}

.header-content p {
  color: var(--text-secondary);
  font-size: 1.1rem;
}

.portfolio-section {
  padding: 3rem 1rem;
  max-width: 1400px;
  margin: 0 auto;
}

.filter-container {
  display: flex;
  justify-content: center;
  gap: 1rem;
  margin-bottom: 3rem;
  flex-wrap: wrap;
}

.filter-btn {
  background: transparent;
  border: 1px solid var(--text-secondary);
  color: var(--text-secondary);
  padding: 0.5rem 1.5rem;
  border-radius: 25px;
  cursor: pointer;
  transition: all 0.3s ease;
  font-family: 'Montserrat', sans-serif;
  font-size: 0.9rem;
}

.filter-btn:hover,
.filter-btn.active {
  background: var(--primary-color);
  border-color: var(--primary-color);
  color: var(--bg-color);
}

.gallery-grid {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 1.5rem;
}

.gallery-item {
  position: relative;
  border-radius: 8px;
  overflow: hidden;
  background: var(--bg-color);
  cursor: pointer;
  transition: transform 0.3s ease;
}

.gallery-item:hover {
  transform: translateY(-5px);
}

.gallery-item img {
  width: 100%;
  height: 300px;
  object-fit: cover;
  transition: transform 0.3s ease;
}

.gallery-item:hover img {
  transform: scale(1.05);
}

.gallery-overlay {
  position: absolute;
  bottom: 0;
  left: 0;
  right: 0;
  background: linear-gradient(transparent, rgba(0, 0, 0, 0.8));
  color: white;
  padding: 2rem 1.5rem 1.5rem;
  transform: translateY(100%);
  transition: transform 0.3s ease;
}

.gallery-item:hover .gallery-overlay {
  transform: translateY(0);
}

.gallery-overlay h3 {
  font-size: 1.2rem;
  margin-bottom: 0.5rem;
  color: var(--primary-color);
}

.gallery-overlay p {
  font-size: 0.9rem;
  opacity: 0.9;
}

/* Lightbox Styles */
.lightbox {
  display: none;
  position: fixed;
  top: 0;
  left: 0;
  width: 100vw;
  height: 100vh;
  background: rgba(0, 0, 0, 0.9);
  z-index: 1000;
  backdrop-filter: blur(5px);
  align-items: center;
  justify-content: center;
}

.lightbox.active {
  display: flex;
}

.lightbox-content {
  position: relative;
  display: flex;
  align-items: center;
  justify-content: center;
  text-align: center;
  box-sizing: border-box;
}

.lightbox-image {
  max-width: 100vw;
  max-height: 100vh;
  width: auto;
  height: auto;
  object-fit: contain;
  border-radius: 8px;
  margin: 0 auto;
  display: block;
}

.close-lightbox {
  position: fixed;
  top: 32px;
  right: 32px;
  color: white;
  font-size: 2rem;
  cursor: pointer;
  background: none;
  border: none;
  transition: color 0.3s ease;
  z-index: 1100;
}

.close-lightbox:hover {
  color: var(--primary-color);
}

.lightbox-caption {
  position: absolute;
  left: 50%;
  bottom: 32px;
  transform: translateX(-50%);
  color: white;
  background: rgba(0,0,0,0.5);
  padding: 1rem 2rem;
  border-radius: 8px;
  max-width: 90vw;
  box-sizing: border-box;
}

.lightbox-caption h3 {
  color: var(--primary-color);
  margin-bottom: 0.5rem;
}

.lightbox-nav {
  position: fixed;
  top: 50%;
  transform: translateY(-50%);
  background: rgba(255, 255, 255, 0.1);
  border: none;
  color: white;
  font-size: 2rem;
  padding: 1rem 0.5rem;
  cursor: pointer;
  border-radius: 4px;
  transition: background 0.3s ease;
  z-index: 1001;
}

.lightbox-nav:hover {
  background: rgba(255, 255, 255, 0.2);
}

.lightbox-nav.prev {
  left: 20px;
}

.lightbox-nav.next {
  right: 20px;
}

.portfolio-footer {
  background: var(--bg-color);
  padding: 3rem 1.5rem;
  text-align: center;
  display: none;
}

.portfolio-footer.show {
  display: block;
}

.flickr-link-section {
  background: var(--bg-color);
  padding: 0.25rem 0 0 0;
  text-align: center;
  display: none;
}

.flickr-link-section.show {
  display: block;
}

.flickr-link-section p {
  color: var(--text-secondary);
  font-size: 1rem;
  margin: 0;
  padding: 0;
}

.flickr-link-section a {
  color: var(--primary-color);
  text-decoration: none;
  font-weight: 600;
  transition: color 0.3s ease;
}

.flickr-link-section a:hover {
  color: #d4b015;
}

.footer-content p {
  color: var(--text-secondary);
  margin-bottom: 1.5rem;
  font-size: 1.1rem;
}

.cta-button {
  display: inline-block;
  background: var(--primary-color);
  color: var(--bg-color);
  padding: 0.8rem 2rem;
  text-decoration: none;
  border-radius: 25px;
  font-weight: 600;
  transition: all 0.3s ease;
}

.cta-button:hover {
  background: #d4b015;
  transform: translateY(-2px);
}

/* Responsive Design */
@media (max-width: 768px) {
  .gallery-grid {
    grid-template-columns: repeat(2, 1fr);
    gap: 1.5rem;
  }
  
  .gallery-item img {
    height: 250px;
  }
  
  .filter-container {
    gap: 0.5rem;
  }
  
  .filter-btn {
    padding: 0.4rem 1rem;
    font-size: 0.8rem;
  }
  
  .lightbox-nav {
    display: block;
    position: fixed;
    top: 50%;
    transform: translateY(-50%);
    background: rgba(255, 255, 255, 0.2);
    border: none;
    color: white;
    font-size: 1.5rem;
    padding: 0.8rem 0.4rem;
    cursor: pointer;
    border-radius: 4px;
    z-index: 1001;
  }
  
  .lightbox-nav.prev {
    left: 10px;
  }
  
  .lightbox-nav.next {
    right: 10px;
  }
  
  .close-lightbox {
    top: 16px;
    right: 16px;
  }
  
  .header-content h1 {
    font-size: 2rem;
  }

  .lightbox-image {
    max-width: 98vw;
    max-height: 80vh;
  }
}

@media (max-width: 480px) {
  .gallery-grid {
    grid-template-columns: 1fr;
  }
  
  .gallery-item img {
    height: 200px;
  }
  
  .portfolio-section {
    padding: 2rem 1rem;
  }
}

.loading-spinner {
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  padding: 3rem;
  color: var(--text-secondary);
}

.spinner {
  width: 40px;
  height: 40px;
  border: 3px solid rgba(255, 255, 255, 0.1);
  border-top: 3px solid var(--primary-color);
  border-radius: 50%;
  animation: spin 1s linear infinite;
  margin-bottom: 1rem;
}

@keyframes spin {
  0% { transform: rotate(0deg); }
  100% { transform: rotate(360deg); }
}

.loading-spinner.hidden {
  display: none;
}

.error-message {
  display: none;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  padding: 3rem;
  text-align: center;
  color: var(--text-secondary);
}

.error-message.show {
  display: flex;
}

.error-icon {
  font-size: 3rem;
  margin-bottom: 1rem;
}

.error-message h3 {
  color: var(--primary-color);
  margin-bottom: 1rem;
  font-size: 1.5rem;
}

.error-message p {
  margin-bottom: 2rem;
  max-width: 400px;
  line-height: 1.6;
}

.retry-button {
  background: var(--primary-color);
  color: var(--bg-color);
  border: none;
  padding: 0.8rem 2rem;
  border-radius: 25px;
  font-weight: 600;
  cursor: pointer;
  transition: all 0.3s ease;
  font-family: 'Montserrat', sans-serif;
}

.retry-button:hover {
  background: #d4b015;
  transform: translateY(-2px);
} 