/* Modern Home Page Styling */

/* About Section */
.about-section {
    animation: fadeIn 0.6s ease-in;
}

.section-title {
    font-size: 1.5rem;
    font-weight: 700;
    color: #2c3e50;
    margin-bottom: 1.5rem;
    position: relative;
    padding-bottom: 0.5rem;
}

.section-title::after {
    content: '';
    position: absolute;
    bottom: 0;
    left: 0;
    width: 60px;
    height: 3px;
    background: linear-gradient(90deg, #495057, #6c757d);
    border-radius: 2px;
}

.about-content p {
    text-align: justify;
    line-height: 1.8;
    margin-bottom: 1.2rem;
    color: #555;
}

.about-content p:last-child {
    margin-bottom: 0;
}

.about-content a {
    color: #0056b3;
    text-decoration: none;
    transition: color 0.2s ease;
}

.about-content a:hover {
    color: #006FE6;
    text-decoration: none;
}

/* Social Links */
.social-links {
    display: flex;
    justify-content: flex-end;
    align-items: center;
    gap: 0.75rem;
    flex-wrap: wrap;
    padding: 1.5rem 0;
    border-top: 1px solid #e0e0e0;
}

.social-icon {
    color: #555;
    transition: all 0.3s ease;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 42px;
    height: 42px;
    border-radius: 50%;
    background: #f8f9fa;
}

.social-icon:hover {
    color: #495057;
    background: #e9ecef;
    transform: translateY(-3px);
    text-decoration: none;
}

/* Sidebar Social Links - Dark icons, light background */
.sidebar-social-links {
    display: flex;
    justify-content: center;
    align-items: center;
    gap: 0.3rem;
    flex-wrap: wrap;
    padding: 0.75rem 0.5rem;
    border-bottom: 1px solid #ddd;
    background: transparent;
}

.sidebar-social-icon {
    color: #343a40;
    transition: all 0.3s ease;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 32px;
    height: 32px;
    border-radius: 50%;
    background: #f8f9fa;
    flex-shrink: 0;
}

.sidebar-social-icon i {
    font-size: 1.1rem;
}

.sidebar-social-icon:hover {
    color: #495057;
    background: #e9ecef;
    transform: translateY(-2px);
    text-decoration: none;
}

/* News Section */
.news-section {
    animation: fadeIn 0.8s ease-in;
}

.news-items {
    display: flex;
    flex-direction: column;
    gap: 1rem;
}

.news-item {
    background: #ffffff;
    border-left: 4px solid #495057;
    padding: 1rem 1.25rem;
    border-radius: 4px;
    box-shadow: 0 2px 8px rgba(0, 0, 0, 0.06);
    transition: all 0.3s ease;
    display: flex;
    flex-direction: row;
    gap: 1.25rem;
}

.news-item:hover {
    box-shadow: 0 4px 16px rgba(0, 0, 0, 0.12);
    transform: translateY(-2px);
}

/* News item with image - adjust layout */
.news-item-with-image {
    align-items: flex-start;
}

.news-text-content {
    flex: 1;
    min-width: 0; /* Allow text to shrink */
}

.news-image {
    flex-shrink: 0;
    width: 300px;
    height: 150px;
    overflow: hidden;
    border-radius: 6px;
    align-self: flex-start;
}

.news-image img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    transition: transform 0.3s ease;
}

.news-item:hover .news-image img {
    transform: scale(1.05);
}

.news-date {
    font-size: 0.85rem;
    font-weight: 600;
    color: #495057;
    text-transform: uppercase;
    letter-spacing: 0.5px;
    margin-bottom: 0.4rem;
}

.news-title {
    font-size: 1.0rem;
    font-weight: 600;
    color: #2c3e50;
    margin-bottom: 0.5rem;
    line-height: 1.4;
}

.news-content {
    color: #555;
    line-height: 1.6;
}

.news-content p {
    margin-bottom: 0.5rem;
}

.news-content p:last-child {
    margin-bottom: 0;
}

.news-link {
    display: inline-block;
    margin-top: 0.5rem;
    color: #495057;
    font-weight: 600;
    text-decoration: none;
    transition: all 0.2s ease;
}

.news-link:hover {
    color: #343a40;
    text-decoration: none;
    transform: translateX(3px);
}

/* News icon links */
.news-links {
    display: flex;
    flex-wrap: wrap;
    gap: 0.5rem;
    margin-top: 0.75rem;
}

.news-icon-link {
    display: inline-flex;
    align-items: center;
    color: #555;
    text-decoration: none;
    font-size: 1.2rem;
    transition: all 0.3s ease;
}

.news-icon-link:hover {
    color: #495057;
    text-decoration: none;
    transform: translateY(-2px);
}

.news-icon-link i {
    font-size: 1.2rem;
}

.news-icon-link .link-label {
    display: none;
}

.view-all-link {
    display: inline-block;
    color: #495057;
    font-weight: 600;
    font-size: 1.05rem;
    text-decoration: none;
    transition: all 0.2s ease;
    padding: 0.5rem 1rem;
    border-radius: 6px;
    background: #f8f9fa;
}

.view-all-link:hover {
    color: #343a40;
    background: #e9ecef;
    text-decoration: none;
    transform: translateX(3px);
}

/* Sidebar Styling */
.profile-image-container {
    margin: 0;
    border-radius: 12px;
    overflow: hidden;
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.1);
}

.profile-image {
    width: 100%;
    height: auto;
    display: block;
    transition: transform 0.3s ease;
}

.profile-image:hover {
    transform: scale(1.02);
}

.contact-card {
    background: transparent;
    border-radius: 0;
    padding: 0;
    box-shadow: none;
    margin-top: 0;
}

.contact-title {
    font-size: 1.5rem;
    font-weight: 700;
    color: #2c3e50;
    margin-top: 0;
    margin-bottom: 1rem;
    padding-top: 0;
    padding-bottom: 0.75rem;
    border-bottom: none;
}

.contact-content {
    font-size: 0.9rem;
    line-height: 1.6;
    color: #555;
}

.contact-name {
    font-size: 1rem;
    margin-bottom: 0.25rem;
    padding-top: 0.5rem;
}

.contact-role {
    font-size: 0.9rem;
    color: #666;
    margin-bottom: 0.25rem;
}

.contact-affiliation a {
    color: #0056b3;
    text-decoration: none;
    transition: color 0.2s ease;
}

.contact-affiliation a:hover {
    color: #006FE6;
    text-decoration: none;
}

.contact-logo img {
    transition: opacity 0.3s ease;
}

.contact-logo img:hover {
    opacity: 0.8;
}

.contact-address {
    font-size: 0.9rem;
    line-height: 1.6;
}

.contact-address p {
    margin-bottom: 0.25rem;
}

.email-protect {
    font-style: italic;
    white-space: nowrap;
}

/* This doesn't actually work in CSS - we'll rely on the visual [at] in the text */
/* The bot protection comes from NOT having @ in the source code */

/* Animations */
@keyframes fadeIn {
    from {
        opacity: 0;
        transform: translateY(20px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

/* Responsive Design */
@media (max-width: 767.98px) {
    .section-title {
        font-size: 1.75rem;
    }
    
    .social-links {
        justify-content: center;
    }
    
    .news-item {
        padding: 1.25rem;
        flex-direction: column;
    }
    
    .news-image {
        width: 100%;
        height: 200px;
    }
    
    .news-title {
        font-size: 1.1rem;
    }
    
    .contact-card {
        margin-bottom: 2rem;
    }
    
    /* Mobile adjustments for right column */
    .profile-image-container {
        text-align: center;
        margin-bottom: 1rem;
        width: 75%;
        margin-left: auto;
        margin-right: auto;
        display: flex;
        justify-content: center;
    }
    
    .profile-image {
        width: 100%;
        max-width: 100%;
        height: auto;
    }
    
    /* Center social icons on mobile */
    .sidebar-social-links {
        justify-content: center;
        border-bottom: none;
        padding-top: 0;
        padding-bottom: 0;
    }
    
    /* Adjust contact content styling on mobile */
    .contact-content {
        color: #555;
    }
    
    .contact-name,
    .contact-role,
    .contact-affiliation,
    .contact-address {
        text-align: center;
    }
    
    .contact-logo {
        text-align: center;
    }
}

/* Print Styles */
@media print {
    .social-links,
    .news-item:hover,
    .profile-image:hover {
        box-shadow: none;
        transform: none;
    }
}

/* Carousel Styles */
.news-image-carousel {
    width: 300px;
    height: 150px;
    position: relative;
}

/* Project carousel with vertical aspect ratio (default) */
[id^="carousel-project-"] .news-image-carousel.carousel-vertical,
.news-image-carousel.carousel-vertical {
    width: 100% !important;
    height: auto !important;
    aspect-ratio: 3 / 4;
    max-width: 300px;
}

/* Project carousel with horizontal aspect ratio */
[id^="carousel-project-"] .news-image-carousel.carousel-horizontal,
.news-image-carousel.carousel-horizontal {
    width: 100% !important;
    height: auto !important;
    aspect-ratio: 4 / 3;
    max-width: 400px;
}

.carousel-container {
    width: 100%;
    height: 100%;
    position: relative;
    overflow: hidden;
    border-radius: 8px;
}

.carousel-images {
    width: 100%;
    height: 100%;
    position: relative;
}

.carousel-slide {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    opacity: 0;
    transition: opacity 0.3s ease;
    pointer-events: none;
}

.carousel-slide.active {
    opacity: 1;
    pointer-events: auto;
}

.carousel-image {
    width: 100%;
    height: 100%;
    object-fit: cover;
    display: block;
    transition: transform 0.3s ease;
}

.carousel-image:hover {
    transform: scale(1.05);
}

.carousel-btn {
    position: absolute;
    top: 50%;
    transform: translateY(-50%);
    background: rgba(0, 0, 0, 0.5);
    color: white;
    border: none;
    width: 32px;
    height: 32px;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    cursor: pointer;
    transition: all 0.2s ease;
    z-index: 10;
    font-size: 0.9rem;
}

.carousel-btn:hover {
    background: rgba(0, 0, 0, 0.7);
    transform: translateY(-50%) scale(1.1);
}

.carousel-prev {
    left: 8px;
}

.carousel-next {
    right: 8px;
}

.carousel-indicators {
    position: absolute;
    bottom: 8px;
    left: 50%;
    transform: translateX(-50%);
    display: flex;
    gap: 6px;
    z-index: 10;
}

.indicator {
    width: 8px;
    height: 8px;
    border-radius: 50%;
    background: rgba(255, 255, 255, 0.5);
    cursor: pointer;
    transition: all 0.2s ease;
}

.indicator:hover {
    background: rgba(255, 255, 255, 0.8);
}

.indicator.active {
    background: white;
    width: 24px;
    border-radius: 4px;
}

/* Modal Styles */
.image-modal {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    z-index: 9999;
    display: none;
}

.image-modal.active {
    display: flex;
    align-items: center;
    justify-content: center;
}

.modal-overlay {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: rgba(0, 0, 0, 0.9);
    backdrop-filter: blur(5px);
}

.modal-content-wrapper {
    position: relative;
    z-index: 10;
    width: 90vw;
    height: 90vh;
    display: flex;
    align-items: center;
    justify-content: center;
}

.modal-close {
    position: fixed;
    top: 20px;
    right: 20px;
    background: rgba(255, 255, 255, 0.2);
    backdrop-filter: blur(10px);
    border: 2px solid rgba(255, 255, 255, 0.3);
    border-radius: 50%;
    color: white;
    font-size: 1.5rem;
    cursor: pointer;
    width: 50px;
    height: 50px;
    display: flex;
    align-items: center;
    justify-content: center;
    transition: all 0.2s ease;
    z-index: 10001;
}

.modal-close:hover {
    background: rgba(255, 255, 255, 0.3);
    border-color: rgba(255, 255, 255, 0.5);
    transform: scale(1.1);
    color: white;
}

.modal-carousel {
    position: relative;
    width: 100%;
    height: 80vh;
}

.modal-carousel-images {
    position: relative;
    width: 100%;
    height: 100%;
}

.modal-carousel-slide {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    opacity: 0;
    transition: opacity 0.3s ease;
    pointer-events: none;
    display: flex;
    align-items: center;
    justify-content: center;
    z-index: 1;
}

.modal-carousel-slide.active {
    opacity: 1;
    pointer-events: auto;
    z-index: 2;
}

.modal-carousel-slide img {
    max-width: 100%;
    max-height: 80vh;
    object-fit: contain;
    display: block;
    border-radius: 8px;
}

.modal-carousel-btn {
    position: absolute;
    top: 50%;
    transform: translateY(-50%);
    background: rgba(255, 255, 255, 0.9);
    color: #333;
    border: none;
    width: 50px;
    height: 50px;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    cursor: pointer;
    transition: all 0.2s ease;
    z-index: 20;
    font-size: 1.2rem;
}

.modal-carousel-btn:hover {
    background: white;
    transform: translateY(-50%) scale(1.1);
}

.modal-carousel-prev {
    left: -70px;
}

.modal-carousel-next {
    right: -70px;
}

.modal-carousel-indicators {
    position: absolute;
    bottom: -40px;
    left: 50%;
    transform: translateX(-50%);
    display: flex;
    gap: 10px;
    z-index: 20;
}

.modal-indicator {
    width: 12px;
    height: 12px;
    border-radius: 50%;
    background: rgba(255, 255, 255, 0.5);
    cursor: pointer;
    transition: all 0.2s ease;
}

.modal-indicator:hover {
    background: rgba(255, 255, 255, 0.8);
}

.modal-indicator.active {
    background: white;
    width: 36px;
    border-radius: 6px;
}

.modal-caption {
    position: absolute;
    bottom: -70px;
    left: 50%;
    transform: translateX(-50%);
    color: white;
    text-align: center;
    max-width: 600px;
    font-size: 0.95rem;
    line-height: 1.5;
}

/* Responsive Carousel */
@media (max-width: 768px) {
    .modal-carousel-btn {
        width: 40px;
        height: 40px;
        font-size: 1rem;
    }
    
    .modal-carousel-prev {
        left: 10px;
    }
    
    .modal-carousel-next {
        right: 10px;
    }
    
    .modal-carousel-indicators {
        bottom: 10px;
    }
    
    .modal-caption {
        bottom: -50px;
        font-size: 0.85rem;
    }
}

/* Year Header Styles - reusable across pages */
.year-header {
    font-size: 1.25rem;
    font-weight: 600;
    color: #2c3e50;
    margin-bottom: 0.75rem;
    padding: 0.4rem 0.6rem;
    padding-left: 0;
    border-bottom: 2px solid #495057;
    display: flex;
    align-items: center;
    gap: 0.5rem;
    transition: all 0.3s ease;
}

.year-header:hover {
    color: #495057;
}


