/* Art Gallery Styles - Row Layout */

/* Art Gallery */
.art-gallery {
    display: flex;
    flex-direction: column;
    width: 95%;
    margin: 0 auto;
}

/* Fixed Height Rows (Rows 1, 2, 4, 5, 6, 7) */
.art-row {
    display: flex;
    gap: 20px;
    align-items: flex-end;
    justify-content: center;
    flex-wrap: nowrap;
    height: 350px;
    margin-bottom: 20px;
}

.art-row .art-item {
    cursor: pointer;
    transition: all 0.3s ease;
    position: relative;
    flex: 0 0 auto; /* Let natural width be determined by aspect ratio */
    overflow: visible; /* Changed from hidden to visible */
    display: flex;
    align-items: flex-end;
}

.art-row .art-item:hover {
    z-index: 10;
}

.art-row .art-item img {
    height: 350px;
    object-fit: contain;
    transition: transform 0.3s ease;
    display: block;
}

.art-row .art-item:hover img {
    transform: scale(1.05);
}

/* Modal Styles */
.modal {
    display: none;
    position: fixed;
    z-index: 1000;
    left: 0;
    top: 0;
    width: 100%;
    height: 100%;
    background-color: rgba(0,0,0,0.95);
    opacity: 0;
    transition: opacity 0.3s ease;
}

.modal-content-art {
    position: relative;
    margin: 2% auto;
    padding-top: 10%;
    max-width: 90vw;
    max-height: 90vh;
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    animation: slideIn 0.3s ease;
}

.modal-art-image {
    max-width: 100%;
    max-height: 80vh;
    object-fit: contain;
    border-radius: 10px;
    box-shadow: 0 20px 50px rgba(0, 0, 0, 0.8);
}

.art-info {
    margin-top: 20px;
    text-align: center;
}

.art-title {
    font-size: 2rem;
    font-weight: bold;
    color: #fff;
    margin: 0;
}

.close {
    position: absolute;
    top: 20px;
    right: 30%;
    color: #fff;
    font-size: 40px;
    font-weight: bold;
    cursor: pointer;
    z-index: 1001;
    background-color: rgba(0, 0, 0, 0.5);
    width: 50px;
    height: 50px;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    transition: all 0.3s ease;
}

.close:hover {
    background-color: rgba(255, 255, 255, 0.2);
    transform: scale(1.1);
}

/* Animations */
@keyframes slideIn {
    from { transform: scale(0.8); opacity: 0; }
    to { transform: scale(1); opacity: 1; }
}

/* Responsive Design */
@media (max-width: 1400px) {
    .art-row {
        height: 250px;
    }

    .art-row .art-item img {
        height: 250px;
    }
}

/* Tablet adjustments */
@media (max-width: 1200px) {
    .art-row {
        height: 200px;
        gap: 15px;
    }

    .art-row .art-item img {
        height: 200px;
    }
}

/* Mobile optimizations */
@media (max-width: 800px) {
    .art-row {
        padding: 0;
        margin-bottom: 15px;
        height: 100px;
        gap: 8px;
    }

    .art-row .art-item img {
        height: 100px;
    }
}

/* Very small mobile screens */
@media (max-width: 500px) {
    .art-row {
        height: 90px;
        gap: 5px;
    }

    .art-row .art-item img {
        height: 90px;
    }

    .close {
        right: 20px;
        width: 40px;
        height: 40px;
        font-size: 30px;
    }

    .art-title {
        font-size: 1.5rem;
    }
}