
/*
 * JLC Portada v1.7 — Páginas de proyecto
 * Maquetación editorial reversible para Impostura, Random, Still Life y Resonancias.
 */

body.jlc-project-page {
    --jlc-project-ivory: #f2eee6;
    --jlc-project-brown: #51483e;
    --jlc-project-charcoal: #262522;
    --jlc-project-silver: #aaa9a3;
    --jlc-project-muted: #746f67;
    --jlc-project-line: rgba(81,72,62,.20);
    background: var(--jlc-project-ivory) !important;
    color: var(--jlc-project-charcoal);
}

/* Fondo y anchura general, sin cambiar la estructura de Astra/Spectra. */
body.jlc-project-page #page,
body.jlc-project-page .site-content,
body.jlc-project-page .site-main,
body.jlc-project-page .content-area,
body.jlc-project-page .ast-container {
    background: var(--jlc-project-ivory) !important;
}

body.jlc-project-page .site-content > .ast-container,
body.jlc-project-page .ast-container {
    width: 100%;
    max-width: 1380px;
    margin-left: auto;
    margin-right: auto;
}

/* Más aire entre cabecera y comienzo del proyecto. */
body.jlc-project-page .site-content {
    padding-top: clamp(42px, 7vw, 92px);
    padding-bottom: clamp(70px, 9vw, 130px);
}

/* Título de página: editorial, sin mayúsculas forzadas. */
body.jlc-project-page .entry-header,
body.jlc-project-page header.entry-header {
    max-width: 760px;
    margin: 0 auto clamp(32px, 4vw, 52px);
    padding: 0 clamp(22px, 4vw, 56px);
}

body.jlc-project-page .entry-title,
body.jlc-project-page h1.entry-title,
body.jlc-project-page .entry-content > h1:first-child,
body.jlc-project-page .wp-block-post-title {
    color: var(--jlc-project-brown) !important;
    font-family: Georgia, "Times New Roman", serif !important;
    font-size: clamp(38px, 4.2vw, 60px) !important;
    font-weight: 400 !important;
    line-height: 1.05 !important;
    letter-spacing: -.025em !important;
    text-transform: none !important;
    margin-top: 0 !important;
    margin-bottom: 24px !important;
}

body.jlc-project-page .entry-header::after {
    content: "";
    display: block;
    width: 72px;
    height: 1px;
    margin-top: 24px;
    background: var(--jlc-project-silver);
}

/* Texto explicativo: ancho de lectura propio de catálogo/libro. */
body.jlc-project-page .entry-content > p,
body.jlc-project-page .wp-block-post-content > p,
body.jlc-project-page .uagb-container-inner-blocks-wrap > p {
    max-width: 760px;
    margin-left: auto !important;
    margin-right: auto !important;
    padding-left: clamp(22px, 4vw, 56px);
    padding-right: clamp(22px, 4vw, 56px);
    color: var(--jlc-project-charcoal) !important;
    font-family: Georgia, "Times New Roman", serif !important;
    font-size: clamp(16px, 1.25vw, 18px) !important;
    line-height: 1.78 !important;
    letter-spacing: 0 !important;
    text-transform: none !important;
}

/* Primer párrafo con un poco más de aire. */
body.jlc-project-page .entry-content > p:first-of-type,
body.jlc-project-page .wp-block-post-content > p:first-of-type {
    margin-top: 0 !important;
}

/* Separación clara entre el texto conceptual y la secuencia fotográfica. */
body.jlc-project-page .entry-content > figure:first-of-type,
body.jlc-project-page .entry-content > .wp-block-image:first-of-type,
body.jlc-project-page .entry-content > .wp-block-gallery:first-of-type,
body.jlc-project-page .wp-block-post-content > figure:first-of-type {
    margin-top: clamp(58px, 8vw, 110px) !important;
}

/* Fotografías: conservar proporción, sin sombras ni marcos decorativos. */
body.jlc-project-page .entry-content figure.wp-block-image,
body.jlc-project-page .entry-content .wp-block-image,
body.jlc-project-page .entry-content .wp-block-gallery,
body.jlc-project-page .entry-content .wp-block-gallery.has-nested-images,
body.jlc-project-page .entry-content .uagb-image,
body.jlc-project-page .entry-content .spectra-image-gallery {
    max-width: 1180px;
    margin-left: auto !important;
    margin-right: auto !important;
    margin-top: clamp(42px, 6vw, 82px) !important;
    margin-bottom: clamp(42px, 6vw, 82px) !important;
}

body.jlc-project-page .entry-content img,
body.jlc-project-page .wp-block-post-content img {
    height: auto;
    max-width: 100%;
    box-shadow: none !important;
    border: 0 !important;
}

/* Si hay una imagen marcada como alignwide/full, dejarla respirar más. */
body.jlc-project-page .entry-content .alignwide,
body.jlc-project-page .entry-content .alignfull {
    width: min(1180px, calc(100vw - 48px));
    max-width: 1180px;
    margin-left: auto !important;
    margin-right: auto !important;
}

/* Pies de foto discretos, casi de catálogo. */
body.jlc-project-page figcaption,
body.jlc-project-page .wp-element-caption {
    margin-top: 10px !important;
    color: var(--jlc-project-muted) !important;
    font-family: Arial, Helvetica, sans-serif !important;
    font-size: 12px !important;
    line-height: 1.5 !important;
    letter-spacing: .02em !important;
    text-transform: none !important;
    text-align: left;
}

/* Enlaces dentro del texto: sobrios, sin botones llamativos. */
body.jlc-project-page .entry-content a:not(.wp-block-button__link) {
    color: var(--jlc-project-brown);
    text-decoration-color: var(--jlc-project-silver);
    text-underline-offset: 3px;
}

/* Evitar que estilos heredados de bloques conviertan el proyecto en tarjetas. */
body.jlc-project-page .entry-content .wp-block-image,
body.jlc-project-page .entry-content figure {
    background: transparent !important;
}

/* Móvil: conservar lectura y no comprimir las fotografías. */
@media (max-width: 767px) {
    body.jlc-project-page .site-content {
        padding-top: 36px;
        padding-bottom: 72px;
    }

    body.jlc-project-page .entry-header,
    body.jlc-project-page header.entry-header {
        padding-left: 22px;
        padding-right: 22px;
        margin-bottom: 32px;
    }

    body.jlc-project-page .entry-title,
    body.jlc-project-page h1.entry-title,
    body.jlc-project-page .entry-content > h1:first-child {
        font-size: 38px !important;
    }

    body.jlc-project-page .entry-content > p,
    body.jlc-project-page .wp-block-post-content > p,
    body.jlc-project-page .uagb-container-inner-blocks-wrap > p {
        padding-left: 22px;
        padding-right: 22px;
        font-size: 16px !important;
        line-height: 1.72 !important;
    }

    body.jlc-project-page .entry-content figure.wp-block-image,
    body.jlc-project-page .entry-content .wp-block-image,
    body.jlc-project-page .entry-content .wp-block-gallery,
    body.jlc-project-page .entry-content .uagb-image,
    body.jlc-project-page .entry-content .spectra-image-gallery {
        width: calc(100% - 44px);
        margin-top: 46px !important;
        margin-bottom: 46px !important;
    }
}


/* =========================================================
   V1.5 / V1.7 — CABECERA INTERIOR MÍNIMA
   En las páginas de proyecto se elimina la repetición de marca/foto de portada
   y se conserva únicamente la navegación.
   ========================================================= */

/* Ocultar identidad visual repetida del encabezado Astra, solo aquí. */
body.jlc-project-page header.site-header .site-branding,
body.jlc-project-page header.site-header .ast-site-identity,
body.jlc-project-page header.site-header .site-logo-img,
body.jlc-project-page header.site-header .custom-logo-link,
body.jlc-project-page header.site-header .site-title,
body.jlc-project-page header.site-header .site-description,
body.jlc-project-page .ast-primary-header-bar .site-branding,
body.jlc-project-page .ast-primary-header-bar .ast-site-identity,
body.jlc-project-page .ast-primary-header-bar .site-logo-img {
    display: none !important;
}

/* Eliminar cualquier imagen de fondo heredada en la cabecera interior. */
body.jlc-project-page header.site-header,
body.jlc-project-page .ast-primary-header-bar,
body.jlc-project-page .site-primary-header-wrap {
    background-image: none !important;
    background-color: var(--jlc-project-ivory) !important;
}

/* Cabecera más baja y sobria. */
body.jlc-project-page .ast-primary-header-bar {
    min-height: 76px !important;
    padding-top: 0 !important;
    padding-bottom: 0 !important;
}

/* Hacer que la zona de navegación aproveche el ancho disponible. */
body.jlc-project-page .ast-builder-grid-row {
    grid-template-columns: 1fr !important;
}

body.jlc-project-page .site-header-primary-section-left,
body.jlc-project-page .site-header-primary-section-center,
body.jlc-project-page .site-header-primary-section-right {
    min-height: 76px !important;
}

/* Si Astra deja una sección izquierda vacía, evitar que reserve espacio. */
body.jlc-project-page .site-header-primary-section-left:empty,
body.jlc-project-page .site-header-primary-section-center:empty {
    display: none !important;
}

/* Colocar el menú como elemento protagonista de la cabecera. */
body.jlc-project-page .site-header-primary-section-right,
body.jlc-project-page .ast-builder-menu-1,
body.jlc-project-page .ast-main-header-bar-alignment {
    width: 100%;
}

body.jlc-project-page .site-header-primary-section-right {
    justify-content: flex-end !important;
}

/* Menú ligeramente más ligero en las páginas interiores. */
body.jlc-project-page .main-header-menu > .menu-item > .menu-link,
body.jlc-project-page .ast-header-navigation .menu-link,
body.jlc-project-page .ast-builder-menu .menu-link {
    font-size: 15px !important;
}

/* En móvil no se oculta el botón de menú; solo la marca repetida. */
@media (max-width: 921px) {
    body.jlc-project-page .ast-primary-header-bar {
        min-height: 66px !important;
    }

    body.jlc-project-page .site-header-primary-section-right {
        min-height: 66px !important;
    }
}
