* {
  box-sizing: border-box;
  margin: 0;
  padding: 0;
}

body {
  font-family: sans-serif;
  background: #f9f9f9;
  color: #333;
  padding: 1rem 10vw; /* wider side margins */
}

header {
  text-align: center;
  margin-bottom: 2rem;
}

.gallery {
  column-count: 3;
  column-gap: 1.5rem;
}

@media (max-width: 900px) {
  .gallery {
    column-count: 2;
  }
}

@media (max-width: 600px) {
  .gallery {
    column-count: 1;
  }
}

.painting {
  background: white;
  border: 1px solid #ddd;
  border-radius: 8px;
  margin-bottom: 1rem;
  display: inline-block;
  width: 100%;
  box-shadow: 0 2px 6px rgba(0,0,0,0.1);
  overflow: hidden;
  transition: transform 0.2s ease;
  cursor: pointer;
}

.painting:hover {
  transform: scale(1.02);
}

.painting img {
  width: 100%;
  height: auto;
  display: block;
  max-width: 100%;
}

.caption {
  padding: 0.5rem;
  text-align: center;
  font-size: 0.9rem;
  color: #555;
}

/* Lightbox styles */
#lightbox {
  position: fixed;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  display: none;
  align-items: center;
  justify-content: center;
  background: rgba(0, 0, 0, 0.8);
  z-index: 9999;
  cursor: zoom-out;
}

#lightbox img {
  max-width: 90%;
  max-height: 90%;
  border-radius: 8px;
  box-shadow: 0 0 15px rgba(0,0,0,0.5);
}
