/* Custom styles for Max De Jong's website */

/* Force scrollbar to prevent layout shift between pages */
html {
    overflow-y: scroll;
}

/* 
 * Note: .header-separator is defined ONLY in header.css to avoid
 * cascade conflicts. Do not add duplicate definitions here.
 */

/* Profile section styles */
.profile-section {
    margin-top: 1rem;
}

.profile-wrapper {
    background-color: black;
    padding: 1px;
    width: 70%;
    margin: auto;
    box-sizing: border-box;
}

.profile-wrapper img {
    width: 100% !important;
    display: block;
}

/* Social links array - overrides theme's .img_arr */
.profile-section .img_arr {
    width: 70%;
    margin: auto;
    display: flex;
    justify-content: space-between;
    align-items: center;
    box-sizing: border-box;
    padding-top: 10px;
}

.profile-section .img_arr img {
    width: 45px;
    max-width: none !important;
    height: auto;
    transition: transform 0.2s;
}

.profile-section .img_arr img:hover {
    transform: scale(1.1);
}

.profile-section .img_arr img.rounded {
    border-radius: 5px;
}

.black-bg {
    background-color: black;
}

/* Bio text styling */
.bio-text {
    font-family: computer-modern, serif;
    font-size: 130%;
}

/* Today section */
.today-section {
    font-family: computer-modern, serif;
    font-size: 130%;
}

/* Timeline section */
.timeline-section {
    font-family: computer-modern, serif;
    font-size: 130%;
    margin-bottom: 3rem;
}

.timeline {
    position: relative;
    max-width: 800px;
    margin: 2rem auto;
    padding: 0;
    list-style: none;
}

.timeline:before {
    content: '';
    position: absolute;
    top: 0;
    bottom: 0;
    width: 2px;
    background: #eee;
    left: 40px;
    margin-left: -1px;
}

.timeline-item {
    position: relative;
    margin-bottom: 1.5rem;
    min-height: 100px; /* Ensures equal spacing for 1-3 lines of text */
}

.timeline-icon {
    position: absolute;
    width: 60px;
    height: 60px;
    left: 10px;
    top: 0;
    background: white;
    border: 2px solid #eee;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    z-index: 1;
    padding: 5px;
    box-sizing: border-box;
}

.timeline-icon img {
    width: 80%;
    height: 80%;
    object-fit: contain;
}

.timeline-content {
    margin-left: 100px;
    padding: 5px 0 0 0; /* Align top with icon */
}

.timeline-content h4 {
    margin: 0 0 0.2rem 0;
    font-size: 1.2rem;
    color: #333;
}

.timeline-content p {
    margin: 0;
    line-height: 1.4;
}

/* Section separator */
.section-separator {
    padding: 1rem 0;
}

/* Year separator for list pages */
.year-separator {
    height: 1px;
    width: 100%;
    background: linear-gradient(to right, #d1d5db, transparent);
}

/* List page title color */
.list-title {
    color: #5aa0cc;
    margin-top: 0;
}

/* Reduce top margin for article titles to decrease space below header separator */
.li-article-title {
    margin-top: 0;
    margin-bottom: 0.5rem; /* Reduce bottom spacing as well */
}

/* Reduce spacing on summary pages after separator */
.li-article-section {
    padding-top: 0; /* Remove default top padding */
}

/* Video styling */
#sm_vid, #lg_vid {
    border: 1px solid black;
    box-sizing: border-box;
}

/* Mobile responsive adjustments */
@media only screen and (max-width: 767px) {
    .profile-wrapper,
    .profile-section .img_arr {
        width: 90%;
    }

    .timeline-item {
        min-height: 120px; /* Extra height for wrapped text */
    }

    .timeline-content {
        margin-left: 80px;
    }

    .timeline:before {
        left: 30px;
    }

    .timeline-icon {
        left: 0px;
    }
}

/* Feature images on summary pages (work/projects) */
.li-article .list-feature-image {
    width: 100%;
    height: 200px;
    object-fit: cover;
    border-radius: 4px; /* Optional: adds subtle rounding */
    display: block; /* Removes bottom space caused by inline-block */
}

/* Vertically center the row content on desktop/tablet */
@media (min-width: 768px) {
    .vertical-center-row {
        display: flex;
        align-items: flex-start; /* Ensure top alignment to match feature image */
        flex-wrap: wrap;
    }
    
    /* Disable Skeleton's clearfix pseudo-elements for flex container */
    .vertical-center-row:before,
    .vertical-center-row:after {
        display: none;
    }
}

/* Mobile separator styles */
.mobile-separator {
    display: none;
}

@media only screen and (max-width: 767px) {
    .mobile-separator {
        display: block;
    }
}

/* Article metadata styling */
.li-article-meta {
    margin-bottom: 1rem;
    color: #999;
    font-size: smaller;
}

.li-article-meta time {
    display: inline-block;
    margin-right: 1rem;
}

.li-article-taxonomies a {
    background-color: #f0f0f0;
    color: #666;
    padding: 2px 6px;
    border-radius: 3px;
    text-decoration: none;
    margin-right: 5px;
}

.li-article-taxonomies a:hover {
    background-color: #e0e0e0;
    color: #333;
}

/* Pagination separator updates */
.li-pagination {
    border-top: none;
    margin-top: 0.7rem;
}

/* Decrease vertical space between pagination and footer */
.li-page-footer {
    padding-top: 1rem;
}

/* Reduce margin for content separator */
.content-separator {
    margin-bottom: 0.5rem;
}

/* Pagination alignment */
@media (min-width: 768px) {
    .pagination-container {
        display: flex;
        justify-content: space-between;
        align-items: center;
        width: 100%;
    }
    
    .pagination-container .li-pagination-previous,
    .pagination-container .li-pagination-next {
        flex: 1;
        float: none;
        width: 50%; /* Explicit width to ensure distribution */
        max-width: 50%;
    }

    .pagination-container .li-pagination-previous {
        text-align: left;
    }

    .pagination-container .li-pagination-next {
        text-align: right;
    }
}
