/* Latest Updates Display Section */
.latest-updates-section {
    padding: 5rem 2rem;
    max-width: 1400px;
    margin: 0 auto;
    position: relative;
    z-index: 2;
}

.updates-header {
    text-align: center;
    margin-bottom: 3rem;
}

.updates-header h2 {
    font-size: 2.8rem;
    font-weight: 700;
    color: #0d452c;
    margin-bottom: 0.5rem;
}

.updates-header p {
    font-size: 1.1rem;
    color: #666;
}

/* Updates Grid */
.updates-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(300px, 1fr));
    gap: 2.5rem;
}

/* Video Update Card */
.update-item {
    background: white;
    border-radius: 16px;
    overflow: hidden;
    box-shadow: 0 8px 25px rgba(0, 0, 0, 0.1);
    transition: all 0.3s ease;
    border: 1px solid rgba(255, 215, 0, 0.15);
}

.update-item:hover {
    transform: translateY(-8px);
    box-shadow: 0 15px 40px rgba(0, 0, 0, 0.15);
    border-color: rgba(255, 215, 0, 0.4);
}

.update-item.video-update {
    background: linear-gradient(135deg, #0d452c 0%, #1a2e27 100%);
}

.update-item.image-update {
    background: white;
}

.update-item.post-update {
    background: white;
}

/* Video Update */
.video-update-content {
    position: relative;
    overflow: hidden;
    background: #000;
    aspect-ratio: 16 / 9;
}

.video-update-thumbnail {
    width: 100%;
    height: 100%;
    object-fit: cover;
    background: #000;
}

.video-update-overlay {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: rgba(0, 0, 0, 0.3);
    display: flex;
    align-items: center;
    justify-content: center;
    transition: all 0.3s ease;
    opacity: 0;
}

.update-item:hover .video-update-overlay {
    opacity: 1;
}

.play-icon {
    width: 60px;
    height: 60px;
    background: linear-gradient(135deg, #FFD700 0%, #FDB931 100%);
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    color: #0d452c;
    font-size: 1.5rem;
    cursor: pointer;
    transition: all 0.3s ease;
}

.play-icon:hover {
    transform: scale(1.1);
}

.update-info {
    padding: 1.8rem;
    color: #333;
}

.update-item.video-update .update-info {
    color: #cac2b0;
}

.update-type-badge {
    display: inline-block;
    background: linear-gradient(90deg, #FFD700, #FDB931);
    color: #0d452c;
    padding: 0.4rem 1rem;
    border-radius: 20px;
    font-size: 0.75rem;
    font-weight: 700;
    text-transform: uppercase;
    letter-spacing: 0.5px;
    margin-bottom: 0.8rem;
}

.update-item.post-update .update-type-badge {
    background: linear-gradient(90deg, #667eea, #764ba2);
    color: white;
}

.update-item.image-update .update-type-badge {
    background: linear-gradient(90deg, #00c6ff, #0072ff);
    color: white;
}

.update-title {
    font-size: 1.3rem;
    font-weight: 700;
    margin: 0.8rem 0;
    line-height: 1.4;
    color: inherit;
}

.update-item.video-update .update-title {
    background: linear-gradient(90deg, #FFD700, #FDB931);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
}

.update-date {
    font-size: 0.85rem;
    color: #999;
    margin-bottom: 1rem;
    display: flex;
    align-items: center;
    gap: 0.5rem;
}

.update-date i {
    color: #FFD700;
}

.update-description {
    font-size: 0.95rem;
    line-height: 1.6;
    color: #666;
    margin-bottom: 1.2rem;
    display: -webkit-box;
    -webkit-line-clamp: 2;
    -webkit-box-orient: vertical;
    overflow: hidden;
}

.update-item.video-update .update-description {
    color: #cac2b0;
}

/* Image Preview */
.image-update-content {
    width: 100%;
    aspect-ratio: 4 / 3;
    overflow: hidden;
    background: #f0f0f0;
}

.image-update-preview {
    width: 100%;
    height: 100%;
    object-fit: cover;
    transition: all 0.3s ease;
}

.update-item:hover .image-update-preview {
    transform: scale(1.05);
}

/* Post Content */
.post-update-content {
    padding: 1.8rem;
}

.post-text {
    font-size: 0.95rem;
    line-height: 1.8;
    color: #333;
    display: -webkit-box;
    -webkit-line-clamp: 3;
    -webkit-box-orient: vertical;
    overflow: hidden;
}

/* Action Buttons */
.update-actions {
    display: flex;
    gap: 0.8rem;
    margin-top: 1.2rem;
    padding-top: 1.2rem;
    border-top: 1px solid rgba(0, 0, 0, 0.1);
}

.update-item.video-update .update-actions {
    border-top-color: rgba(255, 215, 0, 0.2);
}

.action-btn {
    flex: 1;
    padding: 0.8rem;
    border: none;
    border-radius: 8px;
    cursor: pointer;
    font-weight: 600;
    font-size: 0.9rem;
    transition: all 0.3s ease;
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 0.5rem;
}

.view-btn {
    background: linear-gradient(135deg, #FFD700 0%, #FDB931 100%);
    color: #0d452c;
}

.view-btn:hover {
    transform: translateY(-2px);
    box-shadow: 0 6px 15px rgba(255, 215, 0, 0.3);
}

.share-btn {
    background: rgba(102, 126, 234, 0.1);
    color: #667eea;
    border: 1px solid #667eea;
}

.share-btn:hover {
    background: #667eea;
    color: white;
}

/* Empty State */
.updates-empty {
    text-align: center;
    padding: 4rem 2rem;
    color: #999;
}

.updates-empty i {
    font-size: 3rem;
    color: #ddd;
    margin-bottom: 1rem;
}

.updates-empty h3 {
    font-size: 1.5rem;
    color: #666;
    margin-bottom: 0.5rem;
}

.updates-empty p {
    color: #999;
    font-size: 0.95rem;
}

/* Close Button for Floating Updates */
.close-updates {
    position: fixed;
    bottom: 20px;
    right: 20px;
    background: white;
    border: none;
    width: 40px;
    height: 40px;
    border-radius: 50%;
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.15);
    z-index: 999;
    transition: all 0.3s ease;
}

.close-updates:hover {
    transform: scale(1.1);
    box-shadow: 0 6px 18px rgba(0, 0, 0, 0.2);
}

.close-updates i {
    color: #0d452c;
    font-size: 1.2rem;
}

/* Modal for Full View */
.updates-modal {
    display: none;
    position: fixed;
    z-index: 1000;
    left: 0;
    top: 0;
    width: 100%;
    height: 100%;
    background-color: rgba(0, 0, 0, 0.7);
    animation: fadeIn 0.3s ease;
}

.updates-modal.show {
    display: flex;
    align-items: center;
    justify-content: center;
}

@keyframes fadeIn {
    from {
        opacity: 0;
    }
    to {
        opacity: 1;
    }
}

.modal-content {
    background: white;
    border-radius: 16px;
    /* use viewport units to constrain to 25-35% of screen width */
    width: 30vw;
    min-width: 25vw;
    max-width: 90%;
    max-height: 90vh;
    overflow-y: auto;
    position: relative;
    animation: slideUp 0.3s ease;
}

/* ensure media inside updates modal scales and preserves aspect ratio */
.updates-modal img,
.updates-modal video,
.updates-modal iframe {
    max-width: 100%;
    height: auto;
    object-fit: contain;
}

/* responsive fallback for narrow screens */
@media (max-width: 600px) {
    .modal-content {
        width: 90vw;
    }
}

@keyframes slideUp {
    from {
        transform: translateY(50px);
        opacity: 0;
    }
    to {
        transform: translateY(0);
        opacity: 1;
    }
}

.modal-close {
    position: absolute;
    top: 1.5rem;
    right: 1.5rem;
    background: none;
    border: none;
    font-size: 1.8rem;
    cursor: pointer;
    color: #666;
    z-index: 10;
    transition: all 0.3s ease;
}

.modal-close:hover {
    color: #0d452c;
    transform: rotate(90deg);
}

.modal-video {
    width: 100%;
    aspect-ratio: 16 / 9;
    border: none;
}

.modal-image {
    width: 100%;
    max-height: 60vh;
    object-fit: cover;
}

.modal-text {
    padding: 2rem;
}

.modal-text h2 {
    font-size: 2rem;
    color: #0d452c;
    margin-bottom: 1rem;
}

.modal-text p {
    font-size: 1rem;
    line-height: 1.8;
    color: #555;
    margin-bottom: 1rem;
}

.modal-date {
    font-size: 0.9rem;
    color: #999;
    margin-top: 2rem;
    padding-top: 2rem;
    border-top: 1px solid #eee;
}

/* Responsive */
@media (max-width: 1024px) {
    .updates-grid {
        grid-template-columns: repeat(auto-fill, minmax(280px, 1fr));
        gap: 2rem;
    }

    .updates-header h2 {
        font-size: 2.2rem;
    }
}

@media (max-width: 768px) {
    .latest-updates-section {
        padding: 3rem 1.5rem;
    }

    .updates-grid {
        grid-template-columns: repeat(auto-fill, minmax(250px, 1fr));
        gap: 1.5rem;
    }

    .updates-header h2 {
        font-size: 1.8rem;
    }

    .updates-header p {
        font-size: 1rem;
    }

    .update-title {
        font-size: 1.1rem;
    }

    .modal-content {
        width: 95%;
        max-height: 90vh;
    }

    .modal-text {
        padding: 1.5rem;
    }

    .modal-text h2 {
        font-size: 1.5rem;
    }
}

@media (max-width: 480px) {
    .latest-updates-section {
        padding: 2rem 1rem;
    }

    .updates-grid {
        grid-template-columns: 1fr;
        gap: 1.2rem;
    }

    .updates-header h2 {
        font-size: 1.5rem;
    }

    .updates-header p {
        font-size: 0.95rem;
    }

    .update-title {
        font-size: 1rem;
    }

    .update-info {
        padding: 1.2rem;
    }

    .modal-content {
        width: 98%;
        max-height: 95vh;
    }

    .modal-close {
        top: 1rem;
        right: 1rem;
    }
}                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                  