/* ========================================
   PORTFOLIO IMPROVEMENTS CSS
   ======================================== */

/* Enhanced Animations and Transitions */
@keyframes pageLoad {
  from {
    opacity: 0;
    transform: translateY(20px);
  }
  to {
    opacity: 1;
    transform: translateY(0);
  }
}

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

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

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

@keyframes fadeInScale {
  from {
    opacity: 0;
    transform: scale(0.9);
  }
  to {
    opacity: 1;
    transform: scale(1);
  }
}

@keyframes pulse {
  0%, 100% {
    transform: scale(1);
  }
  50% {
    transform: scale(1.05);
  }
}

/* Skeleton Loading States */
.skeleton {
  background: linear-gradient(90deg, #2a2a2a 25%, #3a3a3a 50%, #2a2a2a 75%);
  background-size: 200% 100%;
  animation: skeleton-loading 1.5s infinite;
  border-radius: 4px;
}

@keyframes skeleton-loading {
  0% {
    background-position: 200% 0;
  }
  100% {
    background-position: -200% 0;
  }
}

.skeleton-album {
  width: 100%;
  height: 200px;
  margin-bottom: 1rem;
}

.skeleton-text {
  height: 1rem;
  margin-bottom: 0.5rem;
}

.skeleton-text.short {
  width: 60%;
}

.skeleton-text.medium {
  width: 80%;
}

/* Enhanced Mobile Menu */
.mobile-menu {
  position: fixed;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  background: rgba(0, 0, 0, 0.95);
  backdrop-filter: blur(10px);
  z-index: 1000;
  display: flex;
  align-items: center;
  justify-content: center;
  opacity: 0;
  visibility: hidden;
  transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
}

.mobile-menu.active {
  opacity: 1;
  visibility: visible;
}

.mobile-menu-content {
  text-align: center;
  padding: 2rem;
}

.mobile-menu-close {
  position: absolute;
  top: 2rem;
  right: 2rem;
  background: none;
  border: none;
  color: #e0e0e0;
  font-size: 2rem;
  cursor: pointer;
  transition: color 0.3s ease;
}

.mobile-menu-close:hover {
  color: #fff;
}

.mobile-nav {
  display: flex;
  flex-direction: column;
  gap: 2rem;
}

.mobile-nav-link {
  color: #e0e0e0;
  text-decoration: none;
  font-size: 1.5rem;
  font-weight: 300;
  letter-spacing: 0.1em;
  transition: all 0.3s ease;
  padding: 1rem;
  border-radius: 8px;
}

.mobile-nav-link:hover {
  color: #fff;
  background: rgba(255, 255, 255, 0.1);
  transform: translateY(-2px);
}

.mobile-social {
  margin-top: 3rem;
  display: flex;
  flex-direction: column;
  gap: 1rem;
}

.mobile-social-link {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 1rem;
  color: #e0e0e0;
  text-decoration: none;
  font-size: 1.2rem;
  transition: all 0.3s ease;
  padding: 1rem;
  border-radius: 8px;
}

.mobile-social-link:hover {
  color: #fff;
  background: rgba(255, 255, 255, 0.1);
}

.mobile-social-link img {
  width: 24px;
  height: 24px;
}

.mobile-menu-btn {
  display: none;
  position: fixed;
  top: 1rem;
  right: 1rem;
  z-index: 1001;
  background: rgba(0, 0, 0, 0.8);
  border: none;
  border-radius: 8px;
  padding: 0.5rem;
  cursor: pointer;
  flex-direction: column;
  gap: 4px;
  transition: all 0.3s ease;
}

.mobile-menu-btn span {
  width: 25px;
  height: 3px;
  background: #e0e0e0;
  transition: all 0.3s ease;
  border-radius: 2px;
}

.mobile-menu-btn:hover {
  background: rgba(0, 0, 0, 0.9);
}

.mobile-menu-btn.active span:nth-child(1) {
  transform: rotate(45deg) translate(6px, 6px);
}

.mobile-menu-btn.active span:nth-child(2) {
  opacity: 0;
}

.mobile-menu-btn.active span:nth-child(3) {
  transform: rotate(-45deg) translate(6px, -6px);
}

/* Enhanced Album Animations */
.album-card {
  opacity: 0;
  transform: translateY(30px);
  animation: slideInUp 0.6s ease-out forwards;
  position: relative;
  overflow: hidden;
}

.album-card:nth-child(1) { animation-delay: 0.1s; }
.album-card:nth-child(2) { animation-delay: 0.2s; }
.album-card:nth-child(3) { animation-delay: 0.3s; }
.album-card:nth-child(4) { animation-delay: 0.4s; }
.album-card:nth-child(5) { animation-delay: 0.5s; }
.album-card:nth-child(6) { animation-delay: 0.6s; }
.album-card:nth-child(7) { animation-delay: 0.7s; }
.album-card:nth-child(8) { animation-delay: 0.8s; }

/* Simple Hover Effects */
.album-card:hover {
  transform: translateY(-8px) scale(1.02);
  box-shadow: 0 20px 40px rgba(0, 0, 0, 0.4);
}

.album-card img {
  transition: transform 0.3s ease;
}

.album-card:hover img {
  transform: scale(1.05);
}

/* Enhanced Lightbox Animations */
.lightbox-content {
  animation: fadeInScale 0.4s cubic-bezier(0.4, 0, 0.2, 1);
}

.lightbox-thumb {
  transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
}

.lightbox-thumb:hover {
  transform: scale(1.1) translateY(-2px);
  box-shadow: 0 8px 25px rgba(0, 0, 0, 0.3);
}

/* Parallax Effects */
.parallax-bg {
  transform: translateZ(0);
  will-change: transform;
}

/* Enhanced Button Animations */
button, .album-card {
  transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
}

button:hover {
  transform: translateY(-2px);
  box-shadow: 0 8px 25px rgba(0, 0, 0, 0.3);
}

.album-card:hover {
  transform: translateY(-5px) scale(1.02);
  box-shadow: 0 15px 35px rgba(0, 0, 0, 0.4);
}

/* Loading States */
.loading-overlay {
  position: fixed;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  background: rgba(24, 24, 26, 0.9);
  backdrop-filter: blur(5px);
  display: flex;
  align-items: center;
  justify-content: center;
  z-index: 9999;
  opacity: 0;
  visibility: hidden;
  transition: all 0.3s ease;
}

.loading-overlay.active {
  opacity: 1;
  visibility: visible;
}

.loading-spinner {
  width: 50px;
  height: 50px;
  border: 3px solid rgba(255, 255, 255, 0.1);
  border-top: 3px solid #e0e0e0;
  border-radius: 50%;
  animation: spin 1s linear infinite;
}

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

/* Enhanced Responsive Design */
@media (max-width: 768px) {
  .mobile-menu-btn {
    display: flex;
  }
  
  .album-card {
    animation-delay: 0s !important;
  }
  
  .album-card:hover {
    transform: translateY(-2px) scale(1.01);
  }
}

@media (max-width: 480px) {
  .mobile-menu-content {
    padding: 1rem;
  }
  
  .mobile-nav-link {
    font-size: 1.3rem;
  }
  
  .mobile-social-link {
    font-size: 1.1rem;
  }
}

/* Performance Optimizations */
* {
  will-change: auto;
}

.album-card, .lightbox-thumb, button {
  will-change: transform, box-shadow;
}

#dynamic-bg {
  will-change: background-image, transform;
}

/* Accessibility Improvements */
@media (prefers-reduced-motion: reduce) {
  * {
    animation-duration: 0.01ms !important;
    animation-iteration-count: 1 !important;
    transition-duration: 0.01ms !important;
  }
  
  html {
    scroll-behavior: auto;
  }
}

/* Focus States */
button:focus,
.mobile-nav-link:focus,
.mobile-social-link:focus {
  outline: 2px solid #e0e0e0;
  outline-offset: 2px;
}

/* High Contrast Mode */
@media (prefers-contrast: high) {
  .album-card {
    border: 2px solid #e0e0e0;
  }
  
  .mobile-nav-link:hover,
  .mobile-social-link:hover {
    background: #e0e0e0;
    color: #18181a;
  }
}

/* Error States */
.error-state {
  text-align: center;
  padding: 2rem;
  color: #e0e0e0;
}

.error-state h3 {
  color: #ff6b6b;
  margin-bottom: 1rem;
}

.retry-btn {
  background: #2196F3;
  color: white;
  border: none;
  padding: 0.8rem 1.5rem;
  border-radius: 8px;
  cursor: pointer;
  font-size: 1rem;
  margin-top: 1rem;
  transition: all 0.3s ease;
}

.retry-btn:hover {
  background: #1976D2;
  transform: translateY(-2px);
}

.image-error {
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  height: 300px;
  background: #2a2a2a;
  border-radius: 8px;
  color: #e0e0e0;
  text-align: center;
  padding: 2rem;
}

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

.error-message {
  font-size: 1.2rem;
  margin-bottom: 0.5rem;
  color: #ff6b6b;
}

.error-filename {
  font-size: 0.9rem;
  color: #999;
  margin-bottom: 1rem;
}

/* Notification System */
.notification {
  position: fixed;
  top: 20px;
  right: 20px;
  padding: 1rem 1.5rem;
  border-radius: 8px;
  color: #fff;
  z-index: 10000;
  opacity: 0;
  transform: translateX(100%);
  transition: all 0.3s ease;
  max-width: 300px;
  word-wrap: break-word;
  box-shadow: 0 4px 12px rgba(0, 0, 0, 0.3);
}

.notification-info { background: #2196F3; }
.notification-success { background: #4CAF50; }
.notification-warning { background: #FF9800; }
.notification-error { background: #F44336; }

/* Loading Text */
.loading-text {
  margin-top: 1rem;
  color: #e0e0e0;
  font-size: 0.9rem;
  text-align: center;
}

/* Image Placeholder */
.image-placeholder {
  width: 100%;
  height: 200px;
  background: #2a2a2a;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 3rem;
  color: #666;
  border-radius: 8px;
  border: 2px dashed #444;
}
