/* Guest Visits Creative UI - Mosaic Timeline */

/* Container */
.guest-timeline-container {
    padding: 20px 0;
}

/* Timeline Row */
.guest-timeline-row {
    display: flex;
    flex-wrap: wrap;
    margin-bottom: 80px;
    border-bottom: 1px solid rgba(0, 0, 0, 0.05);
    padding-bottom: 60px;
}

.guest-timeline-row:last-child {
    border-bottom: none;
    margin-bottom: 0;
}

/* Left Column: Sticky Title */
.guest-timeline-title {
    flex: 0 0 25%;
    max-width: 25%;
    padding-right: 40px;
}

.guest-year-heading {
    position: sticky;
    top: 120px;
    font-family: 'Playfair Display', serif;
    font-size: 60px;
    /* Larger for Year */
    font-weight: 700;
    color: var(--theme-color);
    line-height: 1;
    margin-bottom: 20px;
    padding-left: 20px;
    border-left: 4px solid var(--title-color);
}

.guest-year-desc {
    position: sticky;
    top: 190px;
    margin-top: 15px;
    font-size: 16px;
    color: var(--body-color);
    padding-left: 20px;
}

/* Right Column: Mosaic Grid */
.guest-timeline-gallery {
    flex: 0 0 75%;
    max-width: 75%;
}

/* Sub-heading for Guest Names */
.guest-sub-heading {
    font-family: 'Playfair Display', serif;
    font-size: 32px;
    color: var(--title-color);
    margin-bottom: 25px;
    margin-top: 50px;
    /* Spacing between guests */
    padding-bottom: 15px;
    border-bottom: 2px solid var(--theme-color);
    display: inline-block;
}

.guest-group:first-child .guest-sub-heading {
    margin-top: 0;
}

.guest-mosaic-grid {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 20px;
    grid-auto-flow: dense;
}

/* Mosaic Item Base */
.guest-mosaic-item {
    position: relative;
    border-radius: 12px;
    overflow: hidden;
    height: 280px;
    /* Base height */
    box-shadow: 0 5px 20px rgba(0, 0, 0, 0.05);
}

.guest-mosaic-item img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    transition: transform 0.8s cubic-bezier(0.2, 1, 0.3, 1);
}

/* Irregular Spans */
.guest-mosaic-grid .guest-mosaic-item:nth-child(1) {
    grid-column: span 2;
    grid-row: span 2;
    height: 580px;
}

.guest-mosaic-grid .guest-mosaic-item:nth-child(5n) {
    grid-column: span 2;
}

/* Hover Effects */
.guest-mosaic-item:hover img {
    transform: scale(1.1);
}

.guest-mosaic-overlay {
    position: absolute;
    inset: 0;
    background: linear-gradient(to top, rgba(0, 0, 0, 0.8), transparent 60%);
    opacity: 0;
    transition: opacity 0.3s ease;
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
}

.guest-mosaic-item:hover .guest-mosaic-overlay {
    opacity: 1;
}

.guest-name-tag {
    color: #fff;
    font-family: 'Playfair Display', serif;
    font-size: 20px;
    font-weight: 600;
    margin-top: 15px;
    transform: translateY(20px);
    opacity: 0;
    transition: all 0.4s ease 0.1s;
    text-align: center;
    padding: 0 15px;
}

.guest-mosaic-item:hover .guest-name-tag {
    transform: translateY(0);
    opacity: 1;
}

.guest-zoom-btn {
    width: 60px;
    height: 60px;
    background: #fff;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    color: var(--theme-color);
    font-size: 20px;
    transform: scale(0.5);
    opacity: 0;
    transition: all 0.4s cubic-bezier(0.175, 0.885, 0.32, 1.275);
}

.guest-mosaic-item:hover .guest-zoom-btn {
    transform: scale(1);
    opacity: 1;
}

.guest-zoom-btn:hover {
    background: var(--theme-color);
    color: #fff;
}

/* Responsive */
@media (max-width: 991px) {
    .guest-timeline-row {
        flex-direction: column;
        margin-bottom: 50px;
        /* Reduced from 80px */
        padding-bottom: 40px;
        /* Reduced from 60px */
    }

    .guest-timeline-title {
        flex: 0 0 100%;
        max-width: 100%;
        margin-bottom: 30px;
        padding-right: 0;
    }

    .guest-year-heading {
        position: relative;
        top: 0;
        border-left: none;
        padding-left: 0;
        border-bottom: 3px solid var(--theme-color);
        display: inline-block;
        padding-bottom: 5px;
        font-size: 40px;
    }

    .guest-sub-heading {
        font-size: 24px;
        /* Reduced from 32px */
        margin-top: 30px;
        margin-bottom: 20px;
    }

    .guest-group:first-child .guest-sub-heading {
        margin-top: 0;
    }

    .guest-year-desc {
        position: relative;
        top: 0;
        padding-left: 0;
    }

    .guest-timeline-gallery {
        flex: 0 0 100%;
        max-width: 100%;
    }

    .guest-mosaic-grid {
        grid-template-columns: repeat(2, 1fr);
    }

    .guest-mosaic-grid .guest-mosaic-item:nth-child(1) {
        grid-column: span 2;
        height: 350px;
        /* Slightly reduced height */
    }
}

@media (max-width: 575px) {
    .guest-year-heading {
        font-size: 32px;
    }

    .guest-sub-heading {
        font-size: 20px;
        border-bottom-width: 1px;
    }

    .guest-mosaic-grid {
        grid-template-columns: 1fr;
        gap: 15px;
    }

    .guest-mosaic-grid .guest-mosaic-item:nth-child(1),
    .guest-mosaic-grid .guest-mosaic-item:nth-child(5n) {
        grid-column: span 1;
        grid-row: span 1;
        height: 250px;
    }

    .guest-mosaic-item {
        height: 250px;
    }
}