/* Reset & Base */
*, *::before, *::after {
  box-sizing: border-box;
  margin: 0;
  padding: 0;
}

html {
  scroll-behavior: smooth;
}

body {
  font-family: 'Inter', -apple-system, BlinkMacSystemFont, sans-serif;
  background: #0a0a0a;
  color: #fff;
  line-height: 1.6;
  -webkit-font-smoothing: antialiased;
}

/* Social Nav */
.social-nav {
  position: fixed;
  top: 1.5rem;
  right: 1.5rem;
  display: flex;
  gap: 1rem;
  z-index: 100;
}

.social-nav a {
  color: #fff;
  opacity: 0.6;
  transition: opacity 0.3s ease;
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 0.5rem;
}

.social-nav a:hover {
  opacity: 1;
}

/* Back Navigation */
.back-nav {
  position: fixed;
  top: 1.5rem;
  left: 1.5rem;
  z-index: 100;
}

.back-nav a {
  color: #fff;
  opacity: 0.6;
  transition: opacity 0.3s ease;
  text-decoration: none;
  display: flex;
  align-items: center;
  gap: 0.5rem;
  font-size: 0.9rem;
  letter-spacing: 0.05em;
}

.back-nav a:hover {
  opacity: 1;
}

/* Hero Section */
.hero {
  position: relative;
  height: 100vh;
  min-height: 600px;
  display: flex;
  align-items: center;
  justify-content: center;
  background-size: cover;
  background-position: center;
  background-repeat: no-repeat;
}

.hero-overlay {
  position: absolute;
  inset: 0;
  background: linear-gradient(
    to bottom,
    rgba(0,0,0,0.3) 0%,
    rgba(0,0,0,0.4) 50%,
    rgba(10,10,10,1) 100%
  );
}

.hero-content {
  position: relative;
  text-align: center;
  padding: 2rem;
}

.hero h1 {
  font-family: 'Playfair Display', serif;
  font-size: clamp(2.5rem, 8vw, 5rem);
  font-weight: 400;
  letter-spacing: 0.1em;
  margin-bottom: 0.5rem;
  text-shadow: 0 2px 20px rgba(0,0,0,0.5);
}

.hero .tagline {
  font-size: clamp(1rem, 3vw, 1.5rem);
  font-weight: 300;
  letter-spacing: 0.3em;
  text-transform: uppercase;
  opacity: 0.8;
  margin-bottom: 3rem;
}

/* Album Hero - with inspirational text */
.album-hero .hero-content {
  max-width: 800px;
}

.album-hero .album-description {
  font-family: 'Playfair Display', serif;
  font-size: clamp(1.1rem, 2.5vw, 1.4rem);
  font-weight: 400;
  font-style: italic;
  opacity: 0.9;
  margin-top: 1.5rem;
  line-height: 1.8;
}

.scroll-hint {
  display: inline-flex;
  flex-direction: column;
  align-items: center;
  gap: 0.5rem;
  color: #fff;
  text-decoration: none;
  font-size: 0.875rem;
  letter-spacing: 0.1em;
  text-transform: uppercase;
  opacity: 0.7;
  transition: opacity 0.3s ease;
}

.scroll-hint:hover {
  opacity: 1;
}

.scroll-hint svg {
  animation: bounce 2s infinite;
}

@keyframes bounce {
  0%, 20%, 50%, 80%, 100% { transform: translateY(0); }
  40% { transform: translateY(8px); }
  60% { transform: translateY(4px); }
}

/* Section Title */
.section-title {
  font-family: 'Playfair Display', serif;
  font-size: clamp(1.5rem, 4vw, 2.5rem);
  font-weight: 400;
  text-align: center;
  margin-bottom: 3rem;
  letter-spacing: 0.1em;
}

/* Albums Grid (Homepage) */
.albums-section {
  padding: 4rem 2rem;
  max-width: 1400px;
  margin: 0 auto;
}

.albums-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(350px, 1fr));
  gap: 2rem;
}

@media (max-width: 768px) {
  .albums-grid {
    grid-template-columns: 1fr;
    gap: 1.5rem;
  }
  
  .albums-section {
    padding: 2rem 1rem;
  }
}

/* Album Card */
.album-card {
  position: relative;
  aspect-ratio: 4/3;
  overflow: hidden;
  border-radius: 4px;
  cursor: pointer;
  background: #1a1a1a;
}

.album-card img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  transition: transform 0.6s ease, opacity 0.3s ease;
  opacity: 0;
}

.album-card img.loaded {
  opacity: 1;
}

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

.album-card-overlay {
  position: absolute;
  inset: 0;
  background: linear-gradient(
    to top,
    rgba(0,0,0,0.8) 0%,
    rgba(0,0,0,0.2) 50%,
    rgba(0,0,0,0) 100%
  );
  display: flex;
  flex-direction: column;
  justify-content: flex-end;
  padding: 1.5rem;
  transition: background 0.3s ease;
}

.album-card:hover .album-card-overlay {
  background: linear-gradient(
    to top,
    rgba(0,0,0,0.9) 0%,
    rgba(0,0,0,0.3) 50%,
    rgba(0,0,0,0.1) 100%
  );
}

.album-card-title {
  font-family: 'Playfair Display', serif;
  font-size: 1.5rem;
  font-weight: 400;
  margin-bottom: 0.25rem;
}

.album-card-count {
  font-size: 0.85rem;
  opacity: 0.7;
  letter-spacing: 0.05em;
}

/* Gallery Section (Album Page) */
.gallery-section {
  padding: 4rem 2rem;
  max-width: 1800px;
  margin: 0 auto;
}

.gallery-grid {
  columns: 4 320px;
  column-gap: 1rem;
}

@media (max-width: 1200px) {
  .gallery-grid {
    columns: 3 300px;
  }
}

@media (max-width: 768px) {
  .gallery-grid {
    columns: 2 250px;
    column-gap: 0.5rem;
  }
  
  .gallery-section {
    padding: 2rem 0.5rem;
  }
}

@media (max-width: 500px) {
  .gallery-grid {
    columns: 1;
  }
}

/* Gallery Items */
.gallery-item {
  position: relative;
  overflow: hidden;
  cursor: pointer;
  background: #1a1a1a;
  margin-bottom: 1rem;
  break-inside: avoid;
}

@media (max-width: 768px) {
  .gallery-item {
    margin-bottom: 0.5rem;
  }
}

.gallery-item img {
  width: 100%;
  height: auto;
  display: block;
  transition: transform 0.5s ease, opacity 0.3s ease;
  opacity: 0;
}

.gallery-item img.loaded {
  opacity: 1;
}

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

/* Lightbox */
.lightbox {
  position: fixed;
  inset: 0;
  background: rgba(0,0,0,0.97);
  display: flex;
  align-items: center;
  justify-content: center;
  z-index: 1000;
  opacity: 0;
  visibility: hidden;
  transition: opacity 0.3s ease, visibility 0.3s ease;
}

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

.lightbox-content {
  max-width: 95vw;
  max-height: 95vh;
}

.lightbox-content img {
  max-width: 100%;
  max-height: 95vh;
  object-fit: contain;
}

.lightbox-close {
  position: absolute;
  top: 1.5rem;
  right: 1.5rem;
  background: none;
  border: none;
  color: #fff;
  font-size: 2.5rem;
  cursor: pointer;
  opacity: 0.7;
  transition: opacity 0.3s ease;
  line-height: 1;
  padding: 0.5rem;
}

.lightbox-close:hover {
  opacity: 1;
}

.lightbox-nav {
  position: absolute;
  top: 50%;
  transform: translateY(-50%);
  background: none;
  border: none;
  color: #fff;
  font-size: 2rem;
  cursor: pointer;
  opacity: 0.7;
  transition: opacity 0.3s ease;
  padding: 1rem;
}

.lightbox-nav:hover {
  opacity: 1;
}

.lightbox-prev {
  left: 1rem;
}

.lightbox-next {
  right: 1rem;
}

@media (max-width: 768px) {
  .lightbox-nav {
    font-size: 1.5rem;
    padding: 0.75rem;
  }
  
  .lightbox-close {
    font-size: 2rem;
  }
}

/* Footer */
.footer {
  padding: 4rem 2rem;
  text-align: center;
  border-top: 1px solid rgba(255,255,255,0.1);
}

.footer-content {
  max-width: 600px;
  margin: 0 auto;
}

.footer p {
  font-size: 0.875rem;
  opacity: 0.6;
  letter-spacing: 0.05em;
}

.footer-location {
  margin-top: 0.5rem;
}

/* Loading State */
.album-card.loading,
.gallery-item.loading {
  background: linear-gradient(
    90deg,
    #1a1a1a 0%,
    #2a2a2a 50%,
    #1a1a1a 100%
  );
  background-size: 200% 100%;
  animation: shimmer 1.5s infinite;
}

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

/* Album card links - white text */
a.album-card {
  color: #fff;
  text-decoration: none;
}

a.album-card:visited {
  color: #fff;
}

/* Like Button Overlay */
.like-overlay {
  position: absolute;
  bottom: 0.5rem;
  right: 0.5rem;
  display: flex;
  align-items: center;
  gap: 0.4rem;
  opacity: 0;
  transition: opacity 0.3s ease;
  z-index: 10;
}

.gallery-item:hover .like-overlay {
  opacity: 1;
}

/* Always show if has likes */
.gallery-item .like-overlay:has(.like-count:not(:empty)) {
  opacity: 0.8;
}

.gallery-item:hover .like-overlay:has(.like-count:not(:empty)) {
  opacity: 1;
}

.like-btn {
  background: rgba(0, 0, 0, 0.6);
  border: none;
  border-radius: 50%;
  width: 36px;
  height: 36px;
  cursor: pointer;
  display: flex;
  align-items: center;
  justify-content: center;
  transition: transform 0.2s ease, background 0.2s ease;
  backdrop-filter: blur(4px);
}

.like-btn:hover {
  background: rgba(0, 0, 0, 0.8);
  transform: scale(1.1);
}

.like-btn .heart-icon {
  width: 14px;
  height: 14px;
  color: #fff;
  transition: all 0.2s ease;
}

.like-btn.liked .heart-icon {
  fill: #e74c3c;
  color: #e74c3c;
}

.like-btn.pop {
  animation: pop 0.3s ease;
}

@keyframes pop {
  0% { transform: scale(1); }
  50% { transform: scale(1.3); }
  100% { transform: scale(1); }
}

.like-btn.shake {
  animation: shake 0.5s ease;
}

@keyframes shake {
  0%, 100% { transform: translateX(0); }
  25% { transform: translateX(-4px); }
  75% { transform: translateX(4px); }
}

.like-count {
  font-size: 0.85rem;
  color: #fff;
  text-shadow: 0 1px 2px rgba(0,0,0,0.5);
  font-weight: 500;
  min-width: 1rem;
}

/* Lightbox Like Button */
.lightbox-like {
  position: absolute;
  bottom: 2rem;
  left: 50%;
  transform: translateX(-50%);
  display: flex;
  align-items: center;
  gap: 0.75rem;
  z-index: 1010;
}

.lightbox-like .like-btn {
  width: 48px;
  height: 48px;
  background: rgba(255, 255, 255, 0.15);
}

.lightbox-like .like-btn:hover {
  background: rgba(255, 255, 255, 0.25);
}

.lightbox-like .like-btn .heart-icon {
  width: 18px;
  height: 18px;
}

.lightbox-like .like-count {
  font-size: 1.1rem;
}

/* Mobile adjustments */
@media (max-width: 768px) {
  .like-overlay {
    opacity: 1;
  }
  
  .like-btn {
    width: 32px;
    height: 32px;
  }
  
  .like-btn .heart-icon {
    width: 12px;
    height: 12px;
  }
  
  .lightbox-like {
    bottom: 1.5rem;
  }
  
  .lightbox-like .like-btn {
    width: 40px;
    height: 40px;
  }
  
  .lightbox-like .like-btn .heart-icon {
    width: 16px;
    height: 16px;
  }
}
