/* ============================================================
   DETALLE DE PROYECTO 2026 — Figma "Cubicup-Web" › "Project Detail"
   (1440 × 13899). Va sobre home.css + blog.css. Medidas del .fig.
   ============================================================ */

/* ---------------- HERO (920px): foto + velo al 10 %, nombre de 80 y CO2 ---------------- */
.project-hero {
    position: relative;
    height: 920px; max-height: 100svh; min-height: 640px;
    overflow: hidden; isolation: isolate;
    color: var(--text-inverse);
}
.project-hero::after { content: ""; position: absolute; inset: 0; z-index: -1; background: rgba(0,0,0,.1); }
.project-hero__img { position: absolute; inset: 0; z-index: -2; width: 100%; height: 100%; object-fit: cover; }
.project-hero__inner {
    position: absolute; left: var(--layout-grid-margin); right: var(--layout-grid-margin); bottom: var(--base-16);
    display: flex; flex-direction: column; align-items: flex-start;
    gap: min(273px, 22vh); /* Figma: 273px entre las etiquetas y la métrica */
}
.project-hero__text { display: flex; flex-direction: column; gap: var(--base-16); }
.project-hero__title {
    font-size: var(--display-xl-size); line-height: var(--display-xl-line-height);
    letter-spacing: var(--display-xl-tracking); font-weight: var(--font-weight-regular);
    color: var(--text-inverse);
    animation: line-appear 1s cubic-bezier(.22,.61,.36,1) .2s both;
}
.project-hero__tags { display: flex; flex-wrap: wrap; gap: var(--component-tag-gap); }
/* Figma "impact-metric": 216×68 de cristal, valor 36/40 y texto 16/24 */
.metric-glass--hero { min-width: 216px; min-height: 68px; box-sizing: border-box; padding: 10px; gap: 12px; border-radius: var(--base-8); }
.metric-glass--hero .metric-glass__label { max-width: 142px; font-size: var(--body-base-size); line-height: var(--body-base-line-height); color: var(--glass-text-primary); }

/* ---------------- INTRO: columna de 622 a la derecha, cita abajo ---------------- */
.project-intro { padding: var(--layout-grid-margin) 0; }
.project-intro__main { width: 622px; max-width: 100%; margin-left: auto; display: flex; flex-direction: column; gap: var(--base-24); }
.project-intro__tags { display: flex; flex-wrap: wrap; gap: var(--component-tag-gap); }
.project-intro__lead {
    font-size: var(--heading-lg-size); line-height: var(--heading-lg-line-height);
    letter-spacing: var(--heading-lg-tracking); color: var(--text-primary);
}
/* el resto del texto de la reforma (no está en el Figma): plegado bajo la entradilla, cuerpo 16/24 */
.project-more summary { list-style: none; cursor: pointer; color: var(--text-primary); }
.project-more summary::-webkit-details-marker { display: none; }
.project-more summary:hover { text-decoration: underline; text-underline-offset: 3px; }
.project-more[open] summary { margin-bottom: var(--base-24); }
.project-intro__body { margin-top: 0; }
.project-intro__body :where(p, li) { font-size: var(--body-base-size); line-height: var(--body-base-line-height); color: var(--text-primary); }
.project-intro__body p { margin: 0 0 var(--base-16); }
.project-intro__body :where(h2, h3) { margin: var(--base-32) 0 var(--base-12); font-size: 20px; line-height: 28px; font-weight: var(--font-weight-regular); }
.project-intro__body a { color: inherit; text-decoration: underline; text-underline-offset: 3px; }
.project-intro__body .wp-block-spacer { display: none; }

/* Figma "Frame 62": foto de 215×269 a la izquierda y la cita a la derecha (nombre 158 · texto 274) */
.project-quote {
    display: flex; justify-content: space-between; align-items: flex-end; gap: var(--base-32);
    margin: var(--layout-section-padding-y-extended) 0 0;
}
.project-quote__img { width: 215px; height: 269px; object-fit: cover; display: block; }
.project-quote__text { display: flex; gap: var(--base-16); width: 448px; }
.project-quote__name { flex: 0 0 158px; font-size: var(--title-sm-size); line-height: var(--title-sm-line-height); font-weight: var(--title-sm-weight); }
.project-quote blockquote { flex: 0 0 274px; margin: 0; padding: 0; border: 0; font-size: var(--body-sm-size); line-height: var(--body-sm-line-height); color: #9a8e84; font-style: normal; }

/* ---------------- GALERÍA: ritmo editorial del Figma ---------------- */
.project-gallery { display: flex; flex-direction: column; gap: var(--base-24); padding: var(--base-24) var(--layout-grid-margin) 0; max-width: var(--layout-max); margin: 0 auto; box-sizing: border-box; }
.project-gallery__row { display: flex; gap: var(--layout-grid-gutter); }
.project-gallery__row img { display: block; object-fit: cover; height: auto; }
.project-gallery__row--f img { width: 100%; aspect-ratio: 1376 / 918; }
.project-gallery__row--f.is-first img { aspect-ratio: 1376 / 1032; }
.project-gallery__row--l img,
.project-gallery__row--r img,
.project-gallery__row--p img { width: calc((100% - var(--layout-grid-gutter)) / 2); aspect-ratio: 680 / 1020; }
.project-gallery__row--r { justify-content: flex-end; }

/* ---------------- PROYECTOS RELACIONADOS: 4 tarjetas de 332 ---------------- */
.related-projects { padding-top: var(--layout-section-padding-y-base); }
.related-grid { display: grid; grid-template-columns: repeat(4, 1fr); gap: var(--layout-grid-gutter); }
.related-card { display: flex; flex-direction: column; gap: var(--base-8); color: var(--text-primary); text-decoration: none; }
.related-card__media { position: relative; display: block; aspect-ratio: 332 / 414; overflow: hidden; background: var(--background-subtle); }
.related-card__media img { width: 100%; height: 100%; object-fit: cover; display: block; }
.related-card__tags { position: absolute; top: var(--base-8); right: var(--base-8); display: flex; gap: var(--component-tag-gap); }
.related-card__content { display: flex; gap: var(--base-16); }
.related-card__title { flex: 0 0 100px; font-size: var(--title-sm-size); line-height: var(--title-sm-line-height); font-weight: var(--title-sm-weight); }
.related-card__desc { flex: 1; font-size: var(--body-sm-size); line-height: var(--body-sm-line-height); }
.related-card:hover .related-card__title { text-decoration: underline; text-underline-offset: 3px; }

/* ---------------- PRENSA EN NAVY (Figma "Media Proof") ---------------- */
.press-navy { background: var(--background-navy); color: var(--text-on-brand-primary); padding: var(--layout-section-padding-y-base) 0; }
.press-navy__box {
    position: relative; overflow: hidden;
    min-height: 631px; box-sizing: border-box;
    padding: 56px;
    border: var(--base-thin) solid rgba(255,255,255,.2); border-radius: var(--base-4);
    display: flex; flex-direction: column; justify-content: space-between; gap: 120px;
}
.press-navy__shape { position: absolute; left: 486px; top: -154px; width: 820px; height: 957px; color: rgba(255,255,255,.2); pointer-events: none; }
.press-navy__intro { position: relative; max-width: 506px; display: flex; flex-direction: column; gap: var(--base-24); }
.press-navy__intro .eyebrow { color: var(--text-on-brand-primary); }
.press-navy__title { font-size: var(--heading-lg-size); line-height: var(--heading-lg-line-height); letter-spacing: var(--heading-lg-tracking); font-weight: var(--font-weight-regular); color: var(--text-on-brand-primary); }
.press-navy__bottom { position: relative; display: flex; justify-content: space-between; align-items: flex-end; gap: var(--base-40); }
.press-navy__logos { display: flex; align-items: center; gap: 65px; margin: 0; padding: 0; list-style: none; }
.press-navy__logo img { display: block; max-height: 31px; width: auto; height: auto; }
.press-navy__logo span { font-family: Georgia, "Times New Roman", serif; font-size: 20px; font-weight: 700; color: #fff; white-space: nowrap; }
.press-navy__logo--el-espanol-blanco span { font-weight: 400; font-size: 17px; letter-spacing: .04em; }
.press-navy__text { width: 273px; flex: none; font-size: var(--body-sm-size); line-height: var(--body-sm-line-height); color: var(--text-on-brand-primary); }

/* ---------------- RESPONSIVE ---------------- */
@media (max-width: 1024px) {
    .related-grid { grid-template-columns: repeat(2, 1fr); }
    .press-navy__bottom { flex-direction: column; align-items: flex-start; }
    .press-navy__logos { flex-wrap: wrap; gap: var(--base-24) var(--base-40); }
    .press-navy__text { width: auto; max-width: 420px; }
}
@media (max-width: 760px) {
    .project-quote { flex-direction: column; align-items: flex-start; margin-top: var(--layout-section-padding-y-compact); }
    .project-quote__text { width: auto; flex-direction: column; gap: var(--base-8); }
    .project-quote__name, .project-quote blockquote { flex: none; }
    .project-gallery__row--l img, .project-gallery__row--r img, .project-gallery__row--p img { width: 100%; }
    .project-gallery__row--p { flex-direction: column; }
    .press-navy__box { padding: var(--base-24); min-height: 0; gap: 64px; }
    .press-navy__shape { left: 30%; }
}
@media (max-width: 640px) {
    .related-grid { grid-template-columns: 1fr; }
    .project-hero__inner { gap: var(--base-32); }
}
