  .masonry {
    column-count: 4;
    column-gap: 12px;
  }
  @media (max-width: 1100px) { .masonry { column-count: 3; } }
  @media (max-width: 800px)  { .masonry { column-count: 2; } }
  @media (max-width: 520px)  { .masonry { column-count: 1; } }

  .tile,.tilepv {
    break-inside: avoid;
    margin: 0 0 12px;
    display: block;
    border-radius: 14px;
    overflow: hidden;
    box-shadow: 0 6px 18px rgba(0,0,0,.08);
    background: #fff;
    cursor: zoom-in;
  }
  .tile img, .tilepv img {
    width: 100%;
    height: auto;
    display: block;
  }

  /* Lightbox */
  .lb {
    position: fixed;
    inset: 0;
    background: rgba(0,0,0,.85);
    display: none;
    align-items: center;
    justify-content: center;
    padding: 24px;
    z-index: 9999;
  }
  .lb.open { display: flex; }

  .lb figure {
    margin: 0;
    max-width: min(1100px, 95vw);
    max-height: 90vh;
    position: relative;
  }
  .lb img {
    max-width: 100%;
    max-height: 90vh;
    border-radius: 14px;
    display: block;
  }
  .lb .close, .lb .prev, .lb .next {
    position: absolute;
    top: 10px;
    width: 42px;
    height: 42px;
    border: 0;
    border-radius: 999px;
    background: rgba(255,255,255,.12);
    color: #fff;
    font-size: 22px;
    cursor: pointer;
    display:flex;
    align-items:center;
    justify-content:center;
    backdrop-filter: blur(8px);
  }
  .lb .close { right: 10px; }
  .lb .prev  { left: -54px; top: 50%; transform: translateY(-50%); }
  .lb .next  { right: -54px; top: 50%; transform: translateY(-50%); }

  @media (max-width: 700px) {
    .lb .prev { left: 10px; top: auto; bottom: 10px; transform: none; }
    .lb .next { right: 10px; top: auto; bottom: 10px; transform: none; }
  }

  .lb .caption {
    margin-top: 10px;
    color: rgba(255,255,255,.85);
    font-size: 13px;
    text-align: center;
  }