/*
Theme Name: Yarine Fawaz — Academic
Template: generatepress
Description: Academic personal page — sober white, serif/sans mix, publication list styling.
Version: 1.0
Author: Yarine Fawaz
*/

@import url('https://fonts.googleapis.com/css2?family=Lora:ital,wght@0,400..700;1,400..700&family=Inter:wght@300;400;500;600;700&display=swap');

:root {
    --bg: #F5E7D3;         /* apricot cream — soleil méditerranéen, Provence/Andalousie/Liban */
    --text: #221913;       /* noir chaud, adouci pour un fond chaleureux */
    --text-soft: #5A4A38;
    --text-muted: #8C7A62;
    --rule: #E5D2B6;       /* filet sable chaud */
    --accent: #8B3A2F;     /* terre cuite — signature méditerranéenne */
    --accent-hover: #A44838;
}

/* =====================================================
   BASE
   ===================================================== */
body {
    font-family: 'Lora', Georgia, serif;
    font-size: 17px;
    line-height: 1.6;
    color: var(--text);
    background: var(--bg);
}

/* Force the impressionist background on ALL GeneratePress wrappers
   (parent theme uses "separate-containers" so each zone has its own bg) */
html,
body,
#page,
.site,
.site-header,
.main-navigation,
.site-content,
.content-area,
.site-main,
.inside-article,
.site-footer,
.footer-widgets,
.footer-bar,
article,
.entry-content {
    background: var(--bg) !important;
    background-color: var(--bg) !important;
}

h1, h2, h3, h4, h5, h6 {
    font-family: 'Inter', -apple-system, sans-serif;
    color: var(--text);
    font-weight: 600;
    letter-spacing: -0.01em;
}

a {
    color: var(--accent);
    text-decoration: none;
}

a:hover {
    color: var(--accent-hover);
    text-decoration: underline;
}

/* =====================================================
   HEADER
   ===================================================== */
.site-header {
    background: var(--bg);
    border-bottom: 1px solid var(--rule);
    padding: 1.5em 0 1em;
}

.inside-header {
    display: block !important;
    text-align: center;
}

.site-title {
    font-family: 'Inter', sans-serif;
    font-size: 1.5em;
    font-weight: 600;
    letter-spacing: -0.01em;
    margin: 0;
}

.site-title a {
    color: var(--text);
    text-decoration: none;
}

.site-title a:hover {
    color: var(--accent);
    text-decoration: none;
}

.site-description {
    display: none;
}

/* =====================================================
   NAVIGATION
   ===================================================== */
.main-navigation {
    background: var(--bg);
    border-bottom: 1px solid var(--rule);
    min-height: 0;
    text-align: center;
}

.main-navigation .inside-navigation {
    justify-content: center;
}

.main-navigation .main-nav ul {
    display: inline-flex;
    justify-content: center;
    background: transparent;
}

.main-navigation .main-nav ul li a {
    font-family: 'Inter', sans-serif;
    font-size: 14px;
    font-weight: 500;
    text-transform: none;
    letter-spacing: 0;
    padding: 12px 18px;
    color: var(--text);
    background: transparent;
}

.main-navigation .main-nav ul li a:hover,
.main-navigation .main-nav ul li.current-menu-item a {
    color: var(--accent);
    background: transparent;
}

/* =====================================================
   CONTENT LAYOUT
   ===================================================== */
.site-content {
    padding: 2.5em 0 3em;
}

.site .grid-container {
    max-width: 1080px;
}

.inside-article {
    max-width: 900px;
    margin-left: auto;
    margin-right: auto;
    padding: 0 20px;
    background: transparent;
}

/* Home uses the full grid width (no reason to constrain with no sidebar) */
.home .inside-article {
    max-width: 1080px;
}

/* Force full-width content everywhere (parent theme still adds "right-sidebar"
   body class from its defaults; we killed the sidebar so reclaim the space). */
.content-area {
    width: 100% !important;
    max-width: 100%;
    float: none;
}
#right-sidebar,
#left-sidebar {
    display: none !important;
}

.page .entry-header,
.single .entry-header {
    margin-bottom: 1.5em;
}

.page .entry-title,
.single .entry-title {
    font-family: 'Inter', sans-serif;
    font-size: 1.9em;
    font-weight: 600;
    letter-spacing: -0.01em;
    margin: 0 0 0.3em;
}

/* Hide the "Home" page title (redundant with the H1 in the layout)
   and the "SHARE" page title (logo banner is enough) */
.home .entry-header,
.page-id-7 .entry-header,
.page-id-56 .entry-header {
    display: none;
}

.entry-content p {
    margin: 0 0 1em;
}

.entry-content h2 {
    font-family: 'Inter', sans-serif;
    font-size: 1.35em;
    font-weight: 600;
    margin-top: 2em;
    margin-bottom: 0.6em;
    color: var(--text);
    border-bottom: 1px solid var(--rule);
    padding-bottom: 0.4em;
}

.entry-content h3 {
    font-family: 'Inter', sans-serif;
    font-size: 1.1em;
    font-weight: 600;
    margin-top: 1.6em;
    margin-bottom: 0.6em;
    color: var(--text);
}

.entry-content h4 {
    font-family: 'Inter', sans-serif;
    font-size: 1em;
    font-weight: 500;
    text-transform: uppercase;
    letter-spacing: 0.06em;
    color: var(--text-soft);
    margin-top: 1.4em;
    margin-bottom: 0.5em;
}

/* =====================================================
   PAGE BANNER (top-of-page hero image)
   ===================================================== */
.page-banner {
    width: 100vw;
    position: relative;
    left: 50%;
    right: 50%;
    margin-left: -50vw;
    margin-right: -50vw;
    margin-top: 1.5em;    /* breathing room BELOW the page title */
    margin-bottom: 2.5em;
    max-height: 320px;
    overflow: hidden;
    line-height: 0;
}

.page-banner img {
    width: 100%;
    height: 320px;
    object-fit: cover;
    display: block;
}

/* Modifier for chart/figure banners — show full image, no cropping */
.page-banner--chart img {
    object-fit: contain;
    background: var(--bg);
    padding: 12px 0;
    height: 340px;
    max-height: 340px;
}

/* Modifier for banners that should show the FULL image (no crop) */
.page-banner--tall {
    max-height: none;
}
.page-banner--tall img {
    object-fit: contain;
    background: var(--bg);
    height: auto;
    max-height: 380px;
    width: 100%;
}

/* Publications: shift the WEST/EAST scatter crop upward */
.page-id-23 .page-banner img {
    object-position: center 25%;
}

/* CV: show more of the village scene (dézoom)
   object-fit: contain + modest height + bg fill. Keeps the full image
   visible rather than cover-cropping it. */
.page-id-9 .page-banner,
.page-id-9 .page-banner img {
    max-height: 360px;
    height: 360px;
}
.page-id-9 .page-banner img {
    object-fit: contain;
    object-position: center center;
    background: var(--bg);
}

/* Modifier for portrait-orientation photos — focus on top (face) instead of center */
.page-banner--portrait,
.page-banner--portrait img {
    max-height: 380px;
    height: 380px;
}
.page-banner--portrait img {
    object-position: center 28%;
}

/* Modifier for logo banners — center, no crop, moderate height */
.page-banner--logo {
    max-height: none;
    text-align: center;
    padding: 24px 0;
    background: var(--bg);
}
.page-banner--logo img {
    object-fit: contain;
    background: transparent;
    height: 90px;
    max-height: 90px;
    width: auto;
    max-width: 440px;
    margin: 0 auto;
}

@media (max-width: 768px) {
    .page-banner,
    .page-banner img {
        max-height: 180px;
        height: 180px;
    }
}

/* =====================================================
   HOME — 2-COLUMN LAYOUT
   ===================================================== */
.home-layout {
    display: grid;
    grid-template-columns: 1fr 300px;
    gap: 3.5em;
    align-items: start;
}

.home-main h1 {
    font-family: 'Inter', sans-serif;
    font-size: 2.1em;
    font-weight: 600;
    margin: 0 0 0.15em;
    letter-spacing: -0.02em;
    display: none;   /* redundant with the site title in the header */
}

.home-main .home-position {
    font-family: 'Lora', Georgia, serif;
    font-style: italic;
    font-size: 1.05em;
    color: var(--text-soft);
    margin: 0 0 1.5em;
}

.home-main .home-bio p {
    font-size: 1em;
    line-height: 1.7;
    margin-bottom: 1em;
}

.home-side img {
    width: 100%;
    height: auto;
    display: block;
    border-radius: 3px;
    margin-bottom: 1.2em;
}

.home-side .contact-block {
    font-family: 'Inter', sans-serif;
    font-size: 14px;
    line-height: 1.55;
    color: var(--text-soft);
}

.home-side .contact-block strong {
    color: var(--text);
    font-weight: 600;
    display: block;
    margin-bottom: 0.4em;
    text-transform: uppercase;
    font-size: 12px;
    letter-spacing: 0.08em;
}

.home-side .contact-block p {
    margin: 0 0 1em;
}

.home-side .contact-block a {
    color: var(--accent);
    text-decoration: none;
}

.home-side .contact-block a:hover {
    text-decoration: underline;
}

.home-side .links-block a {
    display: block;
    padding: 3px 0;
    font-size: 14px;
}

@media (max-width: 768px) {
    .home-layout {
        grid-template-columns: 1fr;
        gap: 2em;
    }
    .home-side {
        max-width: 280px;
        margin: 0 auto;
    }
}

/* =====================================================
   NEWS SECTION (on home)
   ===================================================== */
.home-news {
    margin-top: 2.5em;
    border-top: 1px solid var(--rule);
    padding-top: 1.5em;
}

.home-news h2 {
    font-family: 'Inter', sans-serif;
    font-size: 1.1em;
    font-weight: 600;
    text-transform: uppercase;
    letter-spacing: 0.08em;
    color: var(--text-soft);
    margin: 0 0 1em;
    border: none;
    padding: 0;
}

.home-news .news-item {
    padding: 0.7em 0;
    border-bottom: 1px solid var(--rule);
    display: grid;
    grid-template-columns: 100px 1fr;
    gap: 1em;
}

.home-news .news-item:last-child {
    border-bottom: none;
}

.home-news .news-date {
    font-family: 'Inter', sans-serif;
    font-size: 13px;
    color: var(--text-muted);
    font-variant-numeric: tabular-nums;
}

.home-news .news-text {
    font-size: 15px;
    line-height: 1.5;
}

/* =====================================================
   RESEARCH PAGE — PUBLICATION LISTS
   ===================================================== */
.publications {
    margin-top: 1em;
}

.publications h3 {
    font-family: 'Inter', sans-serif;
    font-size: 1em;
    font-weight: 600;
    color: var(--text-soft);
    margin-top: 1.5em;
    margin-bottom: 0.6em;
    text-transform: uppercase;
    letter-spacing: 0.06em;
}

.publications ol {
    list-style: none;
    padding-left: 0;
    margin: 0;
    counter-reset: pub-counter;
}

.publications li {
    padding: 0.7em 0 0.7em 0;
    font-size: 15.5px;
    line-height: 1.55;
    border-bottom: 1px dotted var(--rule);
}

.publications li:last-child {
    border-bottom: none;
}

.publications .pub-title {
    font-weight: 600;
    color: var(--text);
}

.publications .pub-authors {
    color: var(--text);
}

.publications .pub-authors .self {
    font-weight: 600;
}

.publications .pub-venue {
    font-style: italic;
    color: var(--text-soft);
}

.publications .pub-year,
.publications .pub-meta {
    color: var(--text-muted);
    font-size: 14px;
}

.publications .pub-links {
    display: block;
    margin-top: 0.3em;
    font-family: 'Inter', sans-serif;
    font-size: 13px;
}

.publications .pub-links a {
    margin-right: 12px;
    color: var(--accent);
}

.publications .pub-links a:hover {
    text-decoration: underline;
}

.publications .pub-coauthors {
    color: var(--text-soft);
    font-style: italic;
    font-size: 14.5px;
}

/* =====================================================
   CV PAGE
   ===================================================== */
.cv-section {
    margin-bottom: 2em;
}

.cv-section h2 {
    font-family: 'Inter', sans-serif;
    font-size: 1.15em;
    font-weight: 600;
    text-transform: uppercase;
    letter-spacing: 0.06em;
    color: var(--text-soft);
    border-bottom: 1px solid var(--rule);
    padding-bottom: 0.4em;
    margin-bottom: 0.8em;
}

.cv-entry {
    display: grid;
    grid-template-columns: 140px 1fr;
    gap: 1em;
    padding: 0.5em 0;
    border-bottom: 1px dotted var(--rule);
}

.cv-entry:last-child {
    border-bottom: none;
}

.cv-entry .cv-dates {
    font-family: 'Inter', sans-serif;
    font-size: 14px;
    color: var(--text-muted);
    font-variant-numeric: tabular-nums;
    padding-top: 2px;
}

.cv-entry .cv-role {
    font-weight: 600;
    color: var(--text);
}

.cv-entry .cv-place {
    color: var(--text-soft);
    font-size: 15px;
    display: block;
    margin-top: 2px;
}

/* =====================================================
   NEWS INDEX (blog)
   ===================================================== */
.blog .inside-article,
.archive .inside-article {
    border-bottom: 1px solid var(--rule);
    padding-bottom: 1.5em;
    margin-bottom: 1.5em;
}

.blog article:last-of-type .inside-article,
.archive article:last-of-type .inside-article {
    border-bottom: none;
}

.blog .entry-title,
.archive .entry-title {
    font-family: 'Inter', sans-serif;
    font-size: 1.35em;
    font-weight: 600;
    margin: 0 0 0.3em;
}

.entry-meta {
    font-family: 'Inter', sans-serif;
    font-size: 13px;
    color: var(--text-muted);
    text-transform: none;
    letter-spacing: 0;
    margin-bottom: 0.5em;
}

.entry-meta a {
    color: var(--text-muted);
}

.entry-meta a:hover {
    color: var(--accent);
}

/* =====================================================
   FOOTER
   ===================================================== */
.site-footer {
    background: var(--bg);
    border-top: 1px solid var(--rule);
    padding: 1.5em 0;
}

.site-info {
    text-align: center;
    color: var(--text-muted);
    font-family: 'Inter', sans-serif;
    font-size: 13px;
}

.site-info a {
    color: var(--text-muted);
    text-decoration: underline;
}

.site-info a:hover {
    color: var(--accent);
}
