body {
    margin: 0;
    font-family: Arial, sans-serif;
    background-color: #f4f4f4;
}
.title-bar {
    background-color: #333;
    color: white;
    text-align: center;
    padding: 10px;
    font-size: 24px;
    font-weight: bold;
}
.gallery {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(250px, 1fr));
    gap: 10px;
    padding: 10px;
    max-width: 1200px;
    margin: 0 auto;
}
.gallery-item {
    position: relative;
    width: 100%;
    height: 200px;
    overflow: hidden;
}
.gallery-item img, .gallery-item video {
    width: 100%;
    height: 100%;
    object-fit: cover;
    border-radius: 8px;
    transition: transform 0.3s ease;
    cursor: pointer;
    display: block;
}
.gallery-item img:hover, .gallery-item video:hover {
    transform: scale(1.05);
}
.image-title {
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    background: rgba(0, 0, 0, 0.7);
    color: white;
    text-align: center;
    padding: 5px;
    font-size: 14px;
    font-weight: bold;
    border-top-left-radius: 8px;
    border-top-right-radius: 8px;
    z-index: 1;
}
/* Watermark styles */
.gallery-item::after {
    content: 'photography.kjdworks.com'; /* Change to your desired text */
    position: absolute;
    bottom: 10px;
    right: 10px;
    color: rgba(255, 255, 255, 0.5); /* Semi-transparent white */
    font-size: 12px;
    font-weight: bold;
    z-index: 1;
    pointer-events: none; /* Prevent interaction with watermark */
}
.fullscreen {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: rgba(0, 0, 0, 0.9);
    display: flex;
    justify-content: center;
    align-items: center;
    z-index: 1000;
}
.fullscreen img, .fullscreen video {
    max-width: 90%;
    max-height: 90%;
    object-fit: contain;
}
.fullscreen::after {
   content: 'photography.kjdworks.com';
   position: absolute;
   top: 50%;
   left: 50%;
   transform: translate(-50%, -50%); /* Center the watermark */
   color: rgba(255, 255, 255, 0.5);
   font-size: 5vh;
   font-weight: bold;
   z-index: 1001;
   pointer-events: none;
}
.close-btn {
    position: absolute;
    top: 20px;
    right: 20px;
    color: white;
    font-size: 30px;
    cursor: pointer;
}
@media (max-width: 768px) {
    .gallery {
        grid-template-columns: repeat(auto-fit, minmax(200px, 1fr));
    }
    .gallery-item {
        height: 150px;
    }
    .image-title {
        font-size: 12px;
        padding: 4px;
    }
    .gallery-item::after {
        font-size: 10px;
    }
}
@media (max-width: 480px) {
    .gallery {
        grid-template-columns: repeat(auto-fit, minmax(150px, 1fr));
    }
    .gallery-item {
        height: 120px;
    }
    .image-title {
        font-size: 10px;
        padding: 3px;
    }
    .gallery-item::after {
        font-size: 8px;
    }
}