 * {
      margin: 0;
      padding: 0;
      box-sizing: border-box;
    }


    .gallery-container {
      max-width: 1300px;
      width: 100%;
      background: white;
      border-radius: 2rem;
      padding: 2rem 1.5rem;
      box-shadow: 0 20px 40px rgba(0,0,0,0.08);
    }

    h1 {
      font-weight: 600;
      font-size: 2rem;
      letter-spacing: -0.02em;
      color: #1e293b;
      margin-bottom: 0.35rem;
    }

    .subtitle {
      color: #64748b;
      margin-bottom: 2rem;
      font-weight: 400;
      border-left: 4px solid #94a3b8;
      padding-left: 1rem;
    }

    /* ---- gallery grid ---- */
    .gallery-grid {
      display: grid;
      grid-template-columns: repeat(auto-fill, minmax(200px, 1fr));
      gap: 1.25rem;
    }

    .gallery-item {
      position: relative;
      overflow: hidden;
      border-radius: 1.2rem;
      cursor: pointer;
      transition: transform 0.25s ease, box-shadow 0.3s ease;
      box-shadow: 0 4px 12px rgba(0,0,0,0.04);
      background: #f1f5f9;
      aspect-ratio: 1 / 1;
    }

    .gallery-item:hover {
      transform: scale(1.02);
      box-shadow: 0 12px 28px rgba(0,0,0,0.12);
    }

    .gallery-item img {
      width: 100%;
      height: 100%;
      object-fit: cover;
      display: block;
      transition: transform 0.4s ease;
    }

    .gallery-item:hover img {
      transform: scale(1.03);
    }

    /* ---- lightbox overlay ---- */
    .lightbox-overlay {
      position: fixed;
      top: 0;
      left: 0;
      width: 100%;
      height: 100%;
      background: rgba(0, 0, 0, 0.85);
      backdrop-filter: blur(10px);
      -webkit-backdrop-filter: blur(10px);
      display: flex;
      align-items: center;
      justify-content: center;
      visibility: hidden;
      opacity: 0;
      transition: opacity 0.3s ease, visibility 0.3s ease;
      z-index: 999;
      padding: 1.5rem;
    }

    .lightbox-overlay.active {
      visibility: visible;
      opacity: 1;
    }

    .lightbox-content {
      position: relative;
      max-width: 90vw;
      max-height: 90vh;
      display: flex;
      flex-direction: column;
      align-items: center;
      justify-content: center;
      animation: scaleIn 0.25s ease forwards;
    }

    @keyframes scaleIn {
      0% { transform: scale(0.92); opacity: 0.5; }
      100% { transform: scale(1); opacity: 1; }
    }

    .lightbox-content img {
      max-width: 100%;
      max-height: 80vh;
      width: auto;
      height: auto;
      object-fit: contain;
      border-radius: 1.2rem;
      box-shadow: 0 20px 50px rgba(0,0,0,0.6);
      background: #0f172a;
    }

    .lightbox-caption {
      margin-top: 0.9rem;
      color: #f1f5f9;
      font-size: 1rem;
      background: rgba(0,0,0,0.4);
      padding: 0.6rem 1.4rem;
      border-radius: 40px;
      backdrop-filter: blur(4px);
      letter-spacing: 0.3px;
      font-weight: 400;
      max-width: 80%;
      text-align: center;
    }

    /* ---- close button ---- */
    .close-lightbox {
      position: absolute;
      top: 1rem;
      right: 1.5rem;
      background: rgba(255,255,255,0.12);
      border: none;
      color: white;
      font-size: 2.2rem;
      width: 3.2rem;
      height: 3.2rem;
      border-radius: 50%;
      display: flex;
      align-items: center;
      justify-content: center;
      cursor: pointer;
      transition: background 0.2s, transform 0.2s;
      backdrop-filter: blur(4px);
      font-weight: 300;
      line-height: 1;
    }

    .close-lightbox:hover {
      background: rgba(255,255,255,0.25);
      transform: scale(1.05);
    }

    /* ---- navigation arrows ---- */
    .nav-arrow {
      position: absolute;
      top: 50%;
      transform: translateY(-50%);
      background: rgba(20, 20, 30, 0.5);
      backdrop-filter: blur(6px);
      border: 1px solid rgba(255,255,255,0.15);
      color: white;
      font-size: 2.2rem;
      width: 3.4rem;
      height: 3.4rem;
      border-radius: 60px;
      display: flex;
      align-items: center;
      justify-content: center;
      cursor: pointer;
      transition: background 0.2s, transform 0.2s;
      box-shadow: 0 6px 18px rgba(0,0,0,0.3);
      user-select: none;
      font-weight: 300;
    }

    .nav-arrow:hover {
      background: rgba(255,255,255,0.2);
      transform: translateY(-50%) scale(1.06);
    }

    .nav-arrow.prev {
      left: 0.5rem;
    }

    .nav-arrow.next {
      right: 0.5rem;
    }

    /* --- responsive tweaks --- */
    @media (max-width: 640px) {
      .gallery-grid {
        grid-template-columns: repeat(auto-fill, minmax(140px, 1fr));
        gap: 0.9rem;
      }
      .gallery-container {
        padding: 1rem 0.8rem;
        border-radius: 1.5rem;
      }
      h1 {
        font-size: 1.6rem;
      }
      .lightbox-content {
        max-width: 98vw;
        max-height: 92vh;
      }
      .lightbox-content img {
        max-height: 70vh;
        border-radius: 1rem;
      }
      .nav-arrow {
        width: 2.6rem;
        height: 2.6rem;
        font-size: 1.6rem;
      }
      .nav-arrow.prev {
        left: 0.2rem;
      }
      .nav-arrow.next {
        right: 0.2rem;
      }
      .close-lightbox {
        top: 0.5rem;
        right: 0.8rem;
        width: 2.8rem;
        height: 2.8rem;
        font-size: 1.8rem;
      }
      .lightbox-caption {
        font-size: 0.85rem;
        padding: 0.4rem 1rem;
        max-width: 90%;
      }
    }

    @media (max-width: 420px) {
      .gallery-grid {
        grid-template-columns: repeat(auto-fill, minmax(110px, 1fr));
        gap: 0.6rem;
      }
    }

    /* small fallback for very large screens */
    @media (min-width: 1600px) {
      .gallery-grid {
        grid-template-columns: repeat(5, 1fr);
      }
    }

    /* accessibility & focus */
    .gallery-item:focus-visible,
    .close-lightbox:focus-visible,
    .nav-arrow:focus-visible {
      outline: 2px solid #ffffff;
      outline-offset: 3px;
    }