* {
  margin: 0;
  padding: 0;
  box-sizing: border-box;
}

body {
  font-family: 'Helvetica Neue', Arial, sans-serif;
  background-color: #000;
  color: #fff;
  line-height: 1.6;
  -webkit-font-smoothing: antialiased;
  overflow: -moz-scrollbars-none;
  -ms-overflow-style: none;
  scrollbar-width: none;
}

body::-webkit-scrollbar {
  display: none;
}

a {
  color: #fff;
  text-decoration: none;
  transition: opacity 0.3s ease;
}

a:hover {
  opacity: 0.6;
}

/* Navigation */
nav {
  position: fixed;
  top: 0;
  left: 0;
  right: 0;
  z-index: 100;
  padding: 24px 60px;
  display: flex;
  justify-content: space-between;
  align-items: center;
  background: linear-gradient(to bottom, rgba(0,0,0,0.8) 0%, rgba(0,0,0,0) 100%);
}

.nav-left {
  display: flex;
  gap: 40px;
  align-items: center;
}

.nav-left a {
  font-size: 13px;
  letter-spacing: 2px;
  text-transform: uppercase;
  font-weight: 400;
}

.nav-links {
  display: flex;
  gap: 40px;
  align-items: center;
}

.nav-links a {
  font-size: 13px;
  letter-spacing: 2px;
  text-transform: uppercase;
  font-weight: 400;
}

/* Hero Section - fixed center */
.hero {
  position: fixed;
  top: 50%;
  left: 50%;
  transform: translate(-50%, -50%);
  display: flex;
  flex-direction: column;
  justify-content: center;
  align-items: center;
  text-align: center;
  padding: 0 20px;
  z-index: 1;
  pointer-events: none;
}

.hero h1 {
  font-size: 14px;
  letter-spacing: 4px;
  text-transform: uppercase;
  font-weight: 400;
  margin-bottom: 20px;
  opacity: 0.7;
}

.hero h2 {
  font-size: 60px;
  font-weight: 300;
  letter-spacing: 10px;
  text-transform: uppercase;
  line-height: 1.2;
}

/* Category Grid (homepage) */
.categories {
  padding: 100vh 8px 0;
  position: relative;
  z-index: 2;
  max-width: 1600px;
  margin: 0 auto;
}

.category-grid {
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  gap: 8px;
}

.category-card {
  position: relative;
  aspect-ratio: 4 / 3;
  overflow: hidden;
  cursor: pointer;
  display: block;
}

.category-card img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  display: block;
  transition: transform 0.6s ease, filter 0.6s ease;
}

.category-card:hover img {
  transform: scale(1.05);
  filter: brightness(0.5);
}

.category-card .overlay {
  position: absolute;
  inset: 0;
  display: flex;
  flex-direction: column;
  justify-content: center;
  align-items: center;
  text-align: center;
  padding: 20px;
  background: rgba(0,0,0,0.2);
  transition: background 0.4s ease;
}

.category-card:hover .overlay {
  background: rgba(0,0,0,0.4);
}

.category-card .overlay h2 {
  font-size: 32px;
  font-weight: 300;
  letter-spacing: 6px;
  text-transform: uppercase;
}

.category-card .overlay p {
  font-size: 12px;
  letter-spacing: 2px;
  text-transform: uppercase;
  opacity: 0.6;
  margin-top: 8px;
}

/* Feed — colonna singola + coppie portrait */
.feed {
  padding: 100vh 40px 120px;
  position: relative;
  z-index: 2;
  max-width: 1020px;
  margin: 0 auto;
}

.feed-image {
  width: 100%;
  height: auto;
  display: block;
  margin-bottom: 8px;
  cursor: pointer;
  transition: opacity 0.3s ease;
}

.feed-image:hover {
  opacity: 0.7;
}

.feed-row {
  display: flex;
  gap: 8px;
  margin-bottom: 8px;
}

.feed-row.duo .feed-image {
  flex: 1;
  min-width: 0;
  margin-bottom: 0;
}

/* Loading text */
.loading-text {
  text-align: center;
  font-size: 14px;
  letter-spacing: 2px;
  text-transform: uppercase;
  opacity: 0.5;
  padding: 60px 20px;
}

/* Back link */
.back-link {
  position: fixed;
  bottom: 40px;
  left: 50%;
  transform: translateX(-50%);
  z-index: 100;
  font-size: 12px;
  letter-spacing: 2px;
  text-transform: uppercase;
  opacity: 0.4;
  transition: opacity 0.3s ease;
  padding: 10px 20px;
  border: 1px solid rgba(255,255,255,0.2);
  background: rgba(0,0,0,0.5);
}

.back-link:hover {
  opacity: 1;
  border-color: rgba(255,255,255,0.6);
}

/* Footer */
footer {
  padding: 60px 60px 40px;
  text-align: center;
  position: relative;
  z-index: 2;
}

footer .social-links {
  display: flex;
  justify-content: center;
  gap: 20px;
  margin-bottom: 30px;
}

footer .social-links a {
  opacity: 0.6;
  transition: opacity 0.3s ease;
}

footer .social-links a:hover {
  opacity: 1;
}

footer .social-links img {
  width: 20px;
  height: 20px;
  display: block;
}

footer p {
  font-size: 12px;
  opacity: 0.4;
  letter-spacing: 1px;
}

/* About Page */
.about-page {
  padding: 140px 60px 80px;
  max-width: 900px;
  margin: 0 auto;
  position: relative;
  z-index: 2;
}

.about-page h1 {
  font-size: 48px;
  font-weight: 300;
  letter-spacing: 4px;
  margin-bottom: 40px;
}

.about-page .about-content {
  font-size: 15px;
  line-height: 1.8;
  opacity: 0.8;
  margin-bottom: 60px;
}

.about-page .about-content p {
  margin-bottom: 20px;
}

.about-page section {
  margin-bottom: 50px;
}

.about-page section h2 {
  font-size: 13px;
  letter-spacing: 3px;
  text-transform: uppercase;
  font-weight: 400;
  margin-bottom: 24px;
  opacity: 0.5;
}

.about-page .exhibition-item,
.about-page .award-item {
  margin-bottom: 20px;
  font-size: 14px;
  opacity: 0.8;
}

.about-page .exhibition-item .title {
  font-weight: 500;
}

.about-page .exhibition-item .details,
.about-page .award-item .details {
  opacity: 0.5;
  font-size: 13px;
}

.about-page .contact-info {
  font-size: 14px;
  opacity: 0.8;
  line-height: 2;
}

.about-page .contact-info a {
  opacity: 0.8;
}

.about-page .contact-info a:hover {
  opacity: 1;
}

/* Single card */
.single-card {
  position: relative;
  aspect-ratio: 4 / 3;
  overflow: hidden;
  cursor: pointer;
  display: block;
}

.single-card img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  display: block;
  transition: transform 0.6s ease, filter 0.6s ease;
}

.single-card:hover img {
  transform: scale(1.05);
  filter: brightness(0.5);
}

/* BW blend container */
.bw-blend {
  position: relative;
  width: 100%;
  height: 100%;
}

.bw-blend img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  display: block;
  transition: transform 0.6s ease, filter 0.6s ease;
}

.bw-blend:hover img {
  filter: brightness(0.5);
}

.bw-overlay {
  position: absolute;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  object-fit: cover;
  opacity: 1;
  transition: opacity 0.6s ease;
}

.bw-blend:hover .bw-overlay {
  opacity: 0;
}

.bw-blend .bw-overlay {
  filter: brightness(1);
}

/* Lightbox */
.lightbox {
  position: fixed;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  background: rgba(0, 0, 0, 0.95);
  z-index: 1000;
  opacity: 0;
  visibility: hidden;
  transition: opacity 0.3s ease, visibility 0.3s ease;
  cursor: pointer;
}

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

.lightbox-close {
  position: absolute;
  top: 24px;
  right: 30px;
  font-size: 40px;
  cursor: pointer;
  color: #fff;
  opacity: 0.5;
  line-height: 1;
  transition: opacity 0.3s ease;
  z-index: 1001;
}

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

/* Viewport */
.lightbox-viewport {
  position: absolute;
  inset: 0;
  overflow: hidden;
  cursor: pointer;
  padding: 40px;
}

.lightbox-viewport.zoomed {
  overflow: scroll;
  -ms-overflow-style: none;
  scrollbar-width: none;
}

.lightbox-viewport.zoomed::-webkit-scrollbar {
  display: none;
}

/* Carosello BW con effetto spring */
@keyframes lb-enter {
  from { transform: scale(0.92); opacity: 0; }
  to   { transform: scale(1); opacity: 1; }
}

.lightbox.active .lightbox-image-wrapper {
  animation: lb-enter 0.4s cubic-bezier(0.34, 1.56, 0.64, 1) forwards;
}

.lightbox-image-wrapper {
  position: relative;
  width: 100%;
  height: 100%;
  display: flex;
  justify-content: center;
  align-items: center;
}

.lightbox-image-wrapper img {
  position: absolute;
  max-width: 100%;
  max-height: 100%;
  object-fit: contain;
  transition: transform 0.6s cubic-bezier(0.34, 1.56, 0.64, 1), opacity 0.5s ease, filter 0.5s ease;
  cursor: pointer;
  will-change: transform, opacity;
}

.lightbox-image-wrapper img.lb-color {
  transform: translateX(0) scale(1);
  opacity: 1;
  filter: blur(0);
  transition: transform 0.6s cubic-bezier(0.34, 1.56, 0.64, 1), opacity 0.25s ease, filter 0.5s ease;
}

.lightbox-image-wrapper img.lb-bw {
  transform: translateX(100%) scale(0.9);
  opacity: 0;
  filter: blur(2px);
}

.lightbox-image-wrapper.show-bw img.lb-color {
  transform: translateX(-100%) scale(0.9);
  opacity: 0;
  filter: blur(2px);
}

.lightbox-image-wrapper.show-bw img.lb-bw {
  transform: translateX(0) scale(1);
  opacity: 1;
  filter: blur(0);
}

.lightbox-image-wrapper.zoomed img {
  max-width: none;
  max-height: none;
  cursor: grab;
  transition: none;
}

/* Toolbar inferiore */
.lightbox-toolbar {
  position: absolute;
  bottom: 40px;
  left: 50%;
  transform: translateX(-50%);
  display: flex;
  align-items: center;
  gap: 16px;
  z-index: 1001;
}

.lightbox-arrow {
  background: rgba(255,255,255,0.08);
  border: 1px solid rgba(255,255,255,0.15);
  color: #fff;
  font-size: 20px;
  width: 40px;
  height: 40px;
  border-radius: 50%;
  cursor: pointer;
  display: flex;
  align-items: center;
  justify-content: center;
  transition: all 0.3s ease;
  font-family: inherit;
}

.lightbox-arrow:hover {
  background: rgba(255,255,255,0.18);
  border-color: rgba(255,255,255,0.4);
}

#lb-counter {
  font-size: 12px;
  letter-spacing: 2px;
  opacity: 0.5;
  white-space: nowrap;
  min-width: 48px;
  text-align: center;
}

.lb-bw-btn {
  background: rgba(255,255,255,0.08);
  border: 1px solid rgba(255,255,255,0.15);
  color: #fff;
  font-size: 11px;
  letter-spacing: 2px;
  padding: 6px 14px;
  border-radius: 4px;
  cursor: pointer;
  transition: all 0.3s ease;
  font-family: inherit;
  opacity: 0.5;
  margin-left: 8px;
}

.lb-bw-btn:hover {
  opacity: 1;
  border-color: rgba(255,255,255,0.4);
}

.lb-bw-btn.active {
  opacity: 1;
  background: rgba(255,255,255,0.18);
  border-color: rgba(255,255,255,0.4);
}

/* Zoom +/- buttons */
.lb-zoom-group {
  display: flex;
  margin-left: 4px;
}

.lb-zoom-btn {
  background: rgba(255,255,255,0.08);
  border: 1px solid rgba(255,255,255,0.15);
  color: #fff;
  font-size: 16px;
  line-height: 1;
  width: 34px;
  height: 34px;
  cursor: pointer;
  font-family: inherit;
  transition: all 0.2s ease;
  display: flex;
  align-items: center;
  justify-content: center;
  touch-action: manipulation;
}

.lb-zoom-btn:first-child {
  border-radius: 4px 0 0 4px;
}

.lb-zoom-btn:last-child {
  border-radius: 0 4px 4px 0;
  margin-left: -1px;
}

.lb-zoom-btn:hover {
  background: rgba(255,255,255,0.18);
}

.lb-zoom-btn:active {
  background: rgba(255,255,255,0.25);
}

/* Label formato */
.lb-format-label {
  font-size: 9px;
  letter-spacing: 1px;
  opacity: 0.2;
  white-space: nowrap;
  margin-left: auto;
  user-select: none;
}

/* Grab / grabbing per pan */
.lightbox-image-wrapper {
  cursor: grab;
}

.lightbox-image-wrapper:active {
  cursor: grabbing;
}

/* Responsive */
@media (max-width: 1024px) {
  .category-grid {
    grid-template-columns: repeat(2, 1fr);
  }

  .hero h2 {
    font-size: 40px;
    letter-spacing: 6px;
  }

  .category-card .overlay h2 {
    font-size: 24px;
    letter-spacing: 4px;
  }
}

@media (max-width: 768px) {
  nav {
    padding: 16px 24px;
    flex-direction: column;
    gap: 12px;
    background: rgba(0,0,0,0.95);
  }

  .nav-left, .nav-links {
    gap: 20px;
  }

  .hero h2 {
    font-size: 28px;
    letter-spacing: 4px;
  }

  .category-grid {
    grid-template-columns: 1fr;
  }

  .category-card .overlay h2 {
    font-size: 22px;
  }

  .feed {
    padding-left: 12px;
    padding-right: 12px;
  }

  .feed-row.duo {
    flex-direction: column;
  }

  .about-page {
    padding: 120px 24px 40px;
  }

  .about-page h1 {
    font-size: 32px;
  }

  footer {
    padding: 40px 24px 30px;
  }

  /* Mobile toolbar: bigger touch targets */
  .lightbox-toolbar {
    gap: 10px;
    bottom: 32px;
  }

  .lightbox-arrow {
    width: 44px;
    height: 44px;
    font-size: 22px;
  }

  .lb-zoom-btn {
    width: 40px;
    height: 40px;
    font-size: 18px;
  }

  .lb-bw-btn {
    padding: 10px 16px;
    font-size: 12px;
  }

  #lb-counter {
    font-size: 13px;
    min-width: 54px;
  }

  .lightbox-close {
    padding: 12px;
    top: 16px;
    right: 16px;
  }
}

@media (max-width: 480px) {
  .hero h2 {
    font-size: 22px;
  }

  .back-link {
    bottom: 20px;
    font-size: 10px;
    padding: 6px 14px;
  }

  .feed {
    max-width: 100%;
  }

  .lightbox-viewport {
    padding: 12px;
  }

  .lb-format-label {
    display: none;
  }
}
