/* ============================================================
   Memory in the Making - Additional Styles (inner pages)
   ============================================================ */

/* ---- Container (inner pages) ---- */
.site-main .container {
    max-width: 1200px;
    margin: 0 auto;
    padding: 100px 20px 80px;
}

.site-main.single-person .container {
    padding-top: 160px;
}

.site-main.single-news .container {
    padding-top: 160px;
}

/* ---- Archive / Index Grid ---- */
.news-grid,
.posts-grid {
    display: grid;
    grid-template-columns: repeat(2, 1fr);
    gap: 80px 22px;
    margin-bottom: 60px;
}

.archive-pagination,
.archive-header {
    text-align: center;
    margin-bottom: 40px;
}

.archive-title,
.page-title {
    font-family: 'Kufam', sans-serif;
    font-size: 62px;
    font-weight: 400;
    letter-spacing: -0.04em;
    color: #000;
    padding-top: 80px;
    text-align: center;
}

/* ---- Single article ---- */
.single-article {
    max-width: 1200px;
    margin: 0 auto;
}

.single-person-article,
.single-marker-article {
    max-width: 800px;
    margin: 0 auto;
}

.hero-image-wrap {
    position: relative;
    border-radius: 24px;
    overflow: hidden;
    margin-bottom: 40px;
}

.hero-image-wrap img {
    width: 100%;
    height: 400px;
    object-fit: cover;
    display: block;
}

.hero-gradient {
    position: absolute;
    inset: 0;
    background: linear-gradient(180deg, rgba(96, 143, 175, 0) 0%, #608FAF 100%);
    mix-blend-mode: overlay;
    pointer-events: none;
}

.hero-tag {
    position: absolute;
    bottom: 24px;
    right: 23px;
}

.entry-header {
    margin-bottom: 40px;
}

.entry-title,
.person-name {
    font-family: 'Kufam', sans-serif;
    font-size: 40px;
    font-weight: 400;
    letter-spacing: -0.04em;
    color: #000;
    margin-bottom: 16px;
    line-height: 1.1;
}

.entry-meta-row {
    display: flex;
    align-items: center;
    gap: 12px;
    margin-bottom: 16px;
    flex-wrap: wrap;
}

.entry-date,
.card-date {
    font-family: 'Kufam', sans-serif;
    font-style: italic;
    font-size: 14px;
    color: #6C6C6C;
}

.entry-content {
    font-family: 'Kufam', sans-serif;
    font-size: 20px;
    line-height: 1.6;
    color: #000;
    letter-spacing: -0.04em;
}

.entry-content p {
    margin-bottom: 24px;
}

.entry-content h2,
.entry-content h3 {
    font-weight: 500;
    letter-spacing: -0.04em;
    margin: 32px 0 16px;
}

.entry-footer {
    margin-top: 60px;
    padding-top: 40px;
    border-top: 1px solid #DBE0EC;
}

/* ---- Person single page ---- */
.person-layout {
    display: grid;
    grid-template-columns: 488px 1fr;
    gap: 40px;
    margin-bottom: 60px;
}

.person-image-wrap {
    border-radius: 24px;
    overflow: hidden;
}

.person-image-wrap img {
    width: 100%;
    height: auto;
    object-fit: contain;
    display: block;
}

.person-content-col {
    display: flex;
    flex-direction: column;
    gap: 12px;
}

.person-role {
    font-family: 'Kufam', sans-serif;
    font-size: 20px;
    font-weight: 500;
    color: #000;
}

.person-org {
    font-family: 'Kufam', sans-serif;
    font-size: 20px;
    color: #838793;
    line-height: 1.4;
}

.person-location {
    font-family: 'Kufam', sans-serif;
    font-size: 20px;
    color: #838793;
    display: flex;
    align-items: center;
    gap: 6px;
}

/* ---- Marker meta ---- */
.marker-meta {
    display: flex;
    align-items: center;
    gap: 12px;
    margin-bottom: 16px;
    flex-wrap: wrap;
}

.marker-city,
.marker-gender {
    font-family: 'Kufam', sans-serif;
    font-size: 20px;
    color: #838793;
    display: flex;
    align-items: center;
    gap: 6px;
}

/* ---- Single map preview ---- */
.single-map-preview {
    margin: 40px 0;
}

/* ---- Map popup ---- */
.mitm-popup .leaflet-popup-content-wrapper {
    border-radius: 16px;
    padding: 0;
    overflow: hidden;
    box-shadow: 0 8px 24px rgba(52, 17, 9, 0.12);
}

.mitm-popup .leaflet-popup-content {
    margin: 0;
    width: 260px !important;
}

.mitm-popup-inner {
    display: flex;
    flex-direction: column;
}

.mitm-popup-img {
    width: 100%;
    height: 140px;
    object-fit: cover;
    display: block;
}

.mitm-popup-content {
    padding: 16px;
    display: flex;
    flex-direction: column;
    gap: 8px;
}

.mitm-popup-name {
    font-family: 'Kufam', sans-serif;
    font-size: 16px;
    font-weight: 500;
    color: #000;
    letter-spacing: -0.04em;
}

.mitm-popup-city,
.mitm-popup-type {
    font-family: 'Kufam', sans-serif;
    font-size: 14px;
    color: #838793;
}

.mitm-popup-link {
    font-family: 'Kufam', sans-serif;
    font-size: 14px;
    color: #341109;
    text-decoration: none;
    font-weight: 500;
    margin-top: 4px;
    transition: opacity 0.2s;
}

.mitm-popup-link:hover { opacity: 0.7; }

/* ---- Cluster icon ---- */
.mitm-cluster-icon {
    background: #341109;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
}

.mitm-cluster-icon span {
    font-family: 'Kufam', sans-serif;
    font-size: 14px;
    font-weight: 500;
    color: #fff;
    line-height: 40px;
    width: 100%;
    text-align: center;
}

/* ---- Journal card highlighted ---- */
.journal-card.is-highlighted {
    outline: 3px solid #A4D1FB;
    outline-offset: 4px;
}

/* ---- 404 ---- */
.error-404 {
    min-height: 70vh;
    display: flex;
    align-items: center;
}

/* ---- Page content ---- */
.page-hero {
    border-radius: 24px;
    overflow: hidden;
    margin-bottom: 40px;
}

.page-hero img {
    width: 100%;
    max-height: 400px;
    object-fit: cover;
    display: block;
}

.page-header {
    margin-bottom: 40px;
    text-align: center;
}

/* ---- Pagination ---- */
.nav-links {
    display: flex;
    justify-content: center;
    gap: 8px;
    flex-wrap: wrap;
    margin-top: 40px;
}

.nav-links .page-numbers {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 40px;
    height: 40px;
    border-radius: 50%;
    font-family: 'Kufam', sans-serif;
    font-size: 16px;
    color: #000;
    text-decoration: none;
    border: 1px solid #DBE0EC;
    transition: all 0.2s;
}

.nav-links .page-numbers.current,
.nav-links .page-numbers:hover {
    background: #341109;
    color: #fff;
    border-color: #341109;
}

/* ---- Responsive ---- */
@media (max-width: 768px) {
    .news-grid,
    .posts-grid {
        grid-template-columns: 1fr;
    }

    .person-layout {
        grid-template-columns: 1fr;
    }

    .archive-title,
    .page-title {
        font-size: 40px;
    }

    .entry-title {
        font-size: 28px;
    }

    .site-main .container {
        padding-top: 80px;
    }

    .site-main.single-person .container {
        padding-top: 120px;
    }

    .site-main.single-news .container {
        padding-top: 120px;
    }
}
