/*
Theme Name: JPL Construcciones
Theme URI: https://example.com
Author: Estudio G
Author URI: https://example.com
Description: Tema WordPress para JPL Construcciones SpA
Version: 1.0
License: GNU General Public License v2 or later
Text Domain: jpl-construcciones
*/

:root {
    --jpl-carbon: #3c3c3c;
    --jpl-olive: #86895d;
    --jpl-white: #ffffff;
    --jpl-light: #f4f4f0;
    --jpl-text: #333333;
    --jpl-border: #deded8;
    --jpl-oranje: #e88a05;
    --jpl-lightolive: #f7f5cc;

    --font-main: Arial, Helvetica, sans-serif;
    --max-width: 1200px;
}

* {
    box-sizing: border-box;
}

html {
    scroll-behavior: smooth;
}

section[id] {
    scroll-margin-top: 90px;
}

body {
    margin: 0;
    font-family: var(--font-main);
    color: var(--jpl-text);
    background: var(--jpl-white);
    line-height: 1.6;
}

img {
    max-width: 100%;
    height: auto;
    display: block;
}

a {
    color: inherit;
    text-decoration: none;
}

.container {
    width: min(100% - 40px, var(--max-width));
    margin-inline: auto;
}

.section {
    padding: 40px 0;
}

.section-title {
    font-size: clamp(1rem, 4vw, 2rem);
    line-height: 1.1;
    margin: 0 0 10px;
    color: var(--jpl-carbon);
}

.eyebrow  {
    font-size: clamp(1.5rem, 4vw, 2rem);
    line-height: 1.1;
    margin: 0 0 10px;
    color: var(--jpl-olive);
}

.eyebrow2  {
    font-size: clamp(1.5rem, 4vw, 2rem);
    line-height: 1.1;
    margin: 0 0 10px;
    color: var(--jpl-lightolive);
}

.section-title2 {
    font-size: clamp(1rem, 4vw, 2rem);
    line-height: 1.1;
    margin: 0 0 10px;
    color: var(--jpl-lightolive);
}

.section-title-white {
    font-size: clamp(1rem, 4vw, 2rem);
    line-height: 1.1;
    margin: 0 0 10px;
    color: var(--jpl-white);
}

.sub-title-white {
    font-size: clamp(1rem, 4vw, 2rem);
    line-height: 1.1;
    margin: 0 0 10px;
    color: var(--jpl-white);
}

.subtext2 {
    font-size: 1.05rem;
    line-height: 1.1;
    margin: 0 0 10px;
    color: var(--jpl-lightolive);
}

.sub-text-white {
    font-size: 1.05rem;
    line-height: 1.1;
    margin: 0 0 10px;
    color: var(--jpl-white);
}

.section-intro {
    max-width: 650px;
    margin-bottom: 50px;
}

.section-intro p {
    font-size: 1.05rem;
}

/* HEADER */

/* =========================================
   HEADER — LOGO DINÁMICO AL HACER SCROLL
========================================= */

.site-header {
    transition: box-shadow .3s ease, background-color .3s ease;
}

.header-inner {
    min-height: 84px;
    transition: min-height .35s ease;
}

.custom-logo {
    max-width: 90px;
    max-height: 90px;
    width: auto;
    transition:
        max-width .35s ease,
        max-height .35s ease,
        transform .35s ease;
}


/* HEADER AL HACER SCROLL */

.site-header.is-scrolled {
    box-shadow: 0 3px 15px rgba(0, 0, 0, .08);
}

.site-header.is-scrolled .header-inner {
    min-height: 64px;
}

.site-header.is-scrolled .custom-logo {
    max-width: 65px;
    max-height: 65px;
}

.site-header {
    background: var(--jpl-white);
    border-bottom: 1px solid var(--jpl-border);
    position: sticky;
    top: 0;
    z-index: 1000;
}

.header-inner {
    min-height: 84px;
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 30px;
}

.site-branding {
    display: flex;
    align-items: center;
    gap: 14px;
    flex-shrink: 0; /* Evita que el contenedor del logo se comprima a la fuerza */
}

.custom-logo-link {
    display: flex;
    align-items: center;
}

.custom-logo {
    max-width: 140px; /* Aumenta un poco el límite si tu logo es alargado horizontalmente */
    height: auto !important; /* Fuerza a que mantenga su proporción natural sin recortarse */
    width: auto !important;
    max-height: 100px; /* Asegura que no sobrepase la altura de la cabecera */
    object-fit: contain;
}

.site-title {
    font-size: 1rem;
    font-weight: 700;
    letter-spacing: .03em;
    white-space: nowrap; /* Evita que el título se parta de forma extraña */
}
.site-title {
    font-size: 1rem;
    font-weight: 700;
    letter-spacing: .03em;
}

.main-navigation ul {
    list-style: none;
    display: flex;
    align-items: center;
    gap: 24px;
    margin: 0;
    padding: 0;
}

.main-navigation a {
    font-size: .85rem;
    font-weight: 600;
    text-transform: uppercase;
    letter-spacing: .04em;
}

.main-navigation a:hover {
    color: var(--jpl-olive);
}

.menu-toggle {
    display: none;
    border: 0;
    background: none;
    cursor: pointer;
    padding: 8px;
}

.menu-toggle span {
    display: block;
    width: 25px;
    height: 2px;
    background: var(--jpl-carbon);
    margin: 5px 0;
}

/* BOTONES */

.btn {
    display: inline-flex;
    justify-content: center;
    align-items: center;
    padding: 14px 24px;
    border-radius: 2px;
    font-size: .85rem;
    font-weight: 700;
    text-transform: uppercase;
    letter-spacing: .04em;
    transition: .25s ease;
    border: 1px solid transparent;
}

.btn-primary {
    background: var(--jpl-oranje);
    color: var(--jpl-white);
}

.btn-primary:hover {
    background: var(--jpl-carbon);
}

.btn-secondary {
    border-color: var(--jpl-carbon);
    color: var(--jpl-carbon);
}

.btn-secondary:hover {
    background: var(--jpl-carbon);
    color: var(--jpl-white);
}

.btn-light {
    background: var(--jpl-white);
    color: var(--jpl-carbon);
}

/* HERO */

.hero {
    min-height: 400px;
    display: flex;
    align-items: center;
    position: relative;
    background-size: cover;
    background-position: center;
    background-color: var(--jpl-carbon);
    color: var(--jpl-white);
}

.hero-overlay {
    position: absolute;
    inset: 0;
    background: rgba(0,0,0,.42);
}

.hero-content {
    position: relative;
    z-index: 1;
    max-width: 600px;
    padding: 30px 0;
}

.hero h1 {
    font-size: clamp(2rem, 6vw, 3rem);
    line-height: .98;
    margin: 0 0 25px;
    text-transform: uppercase;
    font-weight: 800;
    letter-spacing: -.03em;
}

.hero p {
    font-size: clamp(1rem, 2vw, 1.25rem);
    max-width: 620px;
    margin-bottom: 35px;
}

.hero-buttons {
    display: flex;
    gap: 15px;
    flex-wrap: wrap;
}

/* SERVICIOS */

.services-section {
    background: var(--jpl-light);
}

.services-grid {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 24px;
}

.service-card {
    background: var(--jpl-white);
    border: 1px solid var(--jpl-border);
}

.service-image {
    aspect-ratio: 4 / 3;
    overflow: hidden;
}

.service-image img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    transition: transform .4s ease;
}

.service-card:hover img {
    transform: scale(1.04);
}

.service-content {
    padding: 25px;
}

.service-content h3 {
    margin: 0 0 12px;
    font-size: 1.25rem;
    line-height: 1.2;
}

.service-content p {
    font-size: .95rem;
    margin-bottom: 20px;
}

.service-link {
    font-size: .8rem;
    font-weight: 700;
    text-transform: uppercase;
    color: var(--jpl-olive);
}

/* =========================================
   PARALLAX PAISAJE
========================================= */

.landscape-banner {
    position: relative;
    min-height: 400px;
    overflow: hidden;

    display: flex;
    align-items: center;
    justify-content: center;
}


/* =========================================
   IMAGEN PARALLAX
========================================= */

.landscape-bg {
    position: absolute;

    /*
     * La imagen es más alta que el banner
     * para permitir que se desplace.
     */

    top: -15%;
    left: 0;

    width: 100%;
    height: 130%;

    background-position: center center;
    background-repeat: no-repeat;
    background-size: cover;

    will-change: transform;

    z-index: 1;
}


/* =========================================
   OVERLAY
========================================= */

.landscape-overlay {
    position: absolute;
    inset: 0;

    background: rgba(0, 0, 0, 0.30);

    z-index: 2;
}


/* =========================================
   CONTENIDO
========================================= */

.landscape-content {
    position: relative;

    z-index: 3;

    width: 100%;

    text-align: center;

    padding: 60px 24px;
}


.landscape-content h2 {

    max-width: 570px;

    margin: 0 auto;

    color: #fff;

    font-size: clamp(20px, 5vw, 48px);

    line-height: 1.05;

    font-weight: 700;

    letter-spacing: -0.02em;

    text-shadow:
        0 2px 15px rgba(0,0,0,.25);
}


/* =========================================
   TABLET
========================================= */

@media (max-width: 900px) {

    .landscape-banner {
        min-height: 440px;
    }

    .landscape-content h2 {
        font-size: clamp(32px, 7vw, 52px);
    }

}


/* =========================================
   MÓVIL
========================================= */

@media (max-width: 600px) {

    .landscape-banner {
        min-height: 380px;
    }

    .landscape-content {
        padding: 40px 24px;
    }

    .landscape-content h2 {
        font-size: 34px;
        line-height: 1.1;
    }

}

/* NOSOTROS */

.about-grid {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 70px;
    align-items: center;
}

.about-image img {
    width: 100%;
    aspect-ratio: 4 / 5;
    object-fit: cover;
}

.about-content h2 {
    margin-bottom: 25px;
}

.about-content p {
    margin-bottom: 20px;
}

.about-stats {
    display: grid;
    grid-template-columns: repeat(2, 1fr);
    gap: 25px;
    margin-top: 35px;
}

.stat-number {
    display: block;
    font-size: 2.6rem;
    font-weight: 800;
    color: var(--jpl-olive);
    line-height: 1;
}

.stat-label {
    font-size: .85rem;
}

/* PROYECTOS */

.projects-section {
    background: var(--jpl-carbon);
}

.project-grid {
    display: grid;
    grid-template-columns: 1.2fr 1fr;
    gap: 60px;
    align-items: center;
}

.before-after {
    position: relative;
    overflow: hidden;
    aspect-ratio: 4 / 3;
    background: #ddd;
    border: 3px solid var(--jpl-white); 
}

/* Imagen base ("Antes") */
.before-after > img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    display: block;
}

/* Contenedor de la imagen "Después" que se va recortando */
.after-image {
    position: absolute;
    inset: 0;
    width: 50%; /* Controlado por JS */
    height: 100%;
    overflow: hidden;
    border-right: 3px solid var(--jpl-white);
    box-shadow: 2px 0 5px rgba(0, 0, 0, 0.2);
}

/* La imagen de adentro NO debe cambiar de tamaño, debe ocupar siempre el ancho total del componente */
.after-image img {
    position: absolute;
    top: 0;
    left: 0;
    height: 100%;
    width: 100%;
    /* Truco clave: forzamos a que la imagen tenga el ancho exacto del contenedor padre (.before-after) midiendo el offset o usando unidades relativas si prefieres, pero con position absolute al 100% del padre general funciona perfecto si el padre es relative */
    object-fit: cover;
}
.slider-range {
    position: absolute;
    inset: 0;
    width: 100%;
    opacity: 0;
    cursor: ew-resize;
}

.slider-handle {
    position: absolute;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%);
    background: var(--jpl-white);
    color: var(--jpl-carbon);
    width: 45px;
    height: 45px;
    border-radius: 50%;
    display: flex;
    justify-content: center;
    align-items: center;
    pointer-events: none;
    font-weight: 700;
}

.project-content h2 {
    margin-bottom: 25px;
}


/* CONTACTO */

.contact-section {
    background: var(--jpl-carbon);
    color: var(--jpl-white);
}

.contact-section .section-title {
    color: var(--jpl-white);
}

.contact-grid {
    display: grid;
    grid-template-columns: 1fr 1fr; /* Divide el contenedor exacto en 2 columnas iguales */
    gap: 70px;
    align-items: start; /* Alinea los elementos arriba */
}

/* Responsivo para móviles: una sola columna cuando la pantalla sea menor a 768px */
@media (max-width: 768px) {
    .contact-grid {
        grid-template-columns: 1fr;
        gap: 40px;
    }
}

.contact-info p {
    max-width: 500px;
}

.contact-form input,
.contact-form textarea,
.contact-form select {
    width: 100%;
    padding: 14px;
    border: 1px solid #777;
    background: transparent;
    color: var(--jpl-white);
    margin-bottom: 15px;
    font-family: inherit;
}

.contact-form textarea {
    min-height: 140px;
}

.contact-form label {
    display: block;
    font-size: .85rem;
    margin-bottom: 5px;
}

/* FOOTER */

.site-footer {
    background: #202220;
    color: var(--jpl-white);
    padding: 35px 0;
}

.footer-inner {
    display: flex;
    justify-content: space-between;
    gap: 30px;
    align-items: center;
}

.footer-inner p {
    margin: 0;
    font-size: .85rem;
}

/* RESPONSIVE */

@media (max-width: 900px) {

    .main-navigation {
        display: none;
        position: absolute;
        top: 84px;
        left: 0;
        right: 0;
        background: var(--jpl-white);
        border-bottom: 1px solid var(--jpl-border);
        padding: 25px 20px;
    }

    .main-navigation.is-open {
        display: block;
    }

    .main-navigation ul {
        flex-direction: column;
        align-items: flex-start;
        gap: 20px;
    }

    .menu-toggle {
        display: block;
    }

    .header-cta {
        display: none;
    }

    .services-grid {
        grid-template-columns: repeat(2, 1fr);
    }

    .about-grid,
    .project-grid,
    .contact-grid {
        grid-template-columns: 1fr;
        gap: 40px;
    }

    .process-grid {
        grid-template-columns: repeat(2, 1fr);
    }
}

@media (max-width: 600px) {

    .container {
        width: min(100% - 30px, var(--max-width));
    }

    .section {
        padding: 60px 0;
    }

    .hero {
        min-height: 620px;
    }

    .hero-content {
        padding: 80px 0;
    }

    .hero-buttons {
        flex-direction: column;
        align-items: stretch;
    }

    .btn {
        width: 100%;
    }

    .services-grid {
        grid-template-columns: 1fr;
    }

    .process-grid {
        grid-template-columns: 1fr;
    }

    .about-stats {
        grid-template-columns: 1fr 1fr;
    }

    .footer-inner {
        flex-direction: column;
        align-items: flex-start;
    }
}
/* ==========================================
   PROCESO DE TRABAJO
========================================== */

.process-section {
    background: var(--jpl-olive);
    padding: 40px 0;
    overflow: hidden;
}

.process-heading {
    max-width: 2000px;
    margin: 0 auto 60px;
    text-align: center;
}

.process-heading h1 {
    margin-bottom: 18px;
}

.process-heading p:last-child {
    max-width: 620px;
    margin-right: auto;
    margin-left: auto;
}

.process-grid {
    position: relative;
    display: grid;
    grid-template-columns: repeat(6, 1fr);
    gap: 60px 32px;
}

/* Línea horizontal decorativa */
.process-grid::before {
    content: "";
    position: absolute;
    top: 60px;
    left: 5%;
    right: 5%;
    height: 4px;
    background: #fff;
    z-index: 0;
}

.process-step {
    position: relative;
    z-index: 1;
    text-align: center;
}

.process-icon {
    display: flex;
    align-items: center;
    justify-content: center;
    width: 120px;
    height: 120px;
    margin: 0 auto 10px;
    border: 4px solid #fff;
    border-radius: 50%;
    background-color: #86895d;
}

.process-icon img {
    display: block;
    width: 50px;
    height: 50px;
    object-fit: contain;
}

.process-number {
    display: block;
    margin-bottom: 8px;
    color: #fff;
    font-size: 40px;
    font-weight: 700;
    letter-spacing: 0.10em;
}

.process-step h3 {
    margin: 0 0 12px;
    color: #f7f5cc;
    font-size: 20px;
    line-height: 1.2;
}

.process-step p {
    max-width: 290px;
    margin: 0 auto;
    color: #f7f5cc;
    font-size: 15px;
    line-height: 1.3;
}

.process-action {
    margin-top: 65px;
    text-align: center;
}

/* Tabletas */
@media (max-width: 900px) {

    .process-section {
        padding: 20px 0;
    }

    .process-grid {
        grid-template-columns: repeat(2, 1fr);
        gap: 50px 28px;
    }

    .process-grid::before {
        display: none;
    }

    .process-icon {
        width: 135px;
        height: 135px;
    }

    .process-icon img {
        width: 68px;
        height: 68px;
    }

}

/* Móviles */
@media (max-width: 600px) {

    .process-section {
        padding: 20px 0;
    }

    .process-heading {
        margin-bottom: 20px;
        text-align: left;
    }

    .process-grid {
        grid-template-columns: 1fr;
        gap: 42px;
    }

    .process-step {
        display: grid;
        grid-template-columns: 86px 1fr;
        grid-template-rows: auto auto auto;
        column-gap: 20px;
        text-align: left;
    }

    .process-icon {
        grid-column: 1;
        grid-row: 1 / 4;
        width: 86px;
        height: 86px;
        margin: 0;
    }

    .process-icon img {
        width: 48px;
        height: 48px;
    }

    .process-number {
        grid-column: 2;
        grid-row: 1;
        margin-bottom: 5px;
    }

    .process-step h3 {
        grid-column: 2;
        grid-row: 2;
        font-size: 21px;
    }

    .process-step p {
        grid-column: 2;
        grid-row: 3;
        max-width: none;
        font-size: 14px;
    }

    .process-action {
        margin-top: 45px;
    }

}
.services-grid {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 28px;
}

.service-card {
    overflow: hidden;
    background: #ffffff;
    border: 1px solid rgba(0, 0, 0, 0.08);
}

.service-image {
    aspect-ratio: 4 / 3;
    overflow: hidden;
    background: #e9e9e4;
}

.service-image img {
    display: block;
    width: 100%;
    height: 100%;
    object-fit: cover;
    transition: transform 0.4s ease;
}

.service-card:hover .service-image img {
    transform: scale(1.04);
}

.image-placeholder {
    display: flex;
    align-items: center;
    justify-content: center;
    width: 100%;
    height: 100%;
    color: #666666;
    font-size: 14px;
}

.service-content {
    padding: 24px;
}

.service-content h3 {
    margin: 0 0 12px;
}

.service-content p {
    margin-bottom: 18px;
}

.text-link {
    font-weight: 700;
    text-decoration: none;
}

@media (max-width: 900px) {
    .services-grid {
        grid-template-columns: repeat(2, 1fr);
    }
}

@media (max-width: 600px) {
    .services-grid {
        grid-template-columns: 1fr;
    }
}

section[id] {
    scroll-margin-top: 100px;
}
.main-navigation.is-open {
    display: block;
}

/* =========================================
   DATOS DE CONTACTO
========================================= */

.contact-details {
    display: flex;
    flex-direction: column;
    gap: 14px;
    margin-top: 30px;
}


/* CORREO Y TELÉFONO */

.contact-item {
    display: flex;
    align-items: center;
    gap: 14px;

    width: fit-content;

    color: var(--jpl-white);
    text-decoration: none;

    transition: color .25s ease, opacity .25s ease;
}

.contact-item:hover {
    color: var(--jpl-lightolive);
}


/* ICONOS */

.contact-icon {
    display: flex;
    align-items: center;
    justify-content: center;

    width: 40px;
    height: 40px;

    flex-shrink: 0;

    border: 1px solid rgba(255,255,255,.35);
    border-radius: 50%;

    color: var(--jpl-lightolive);

    font-size: 17px;
}


/* WHATSAPP */

.contact-whatsapp {
    display: inline-flex;
    align-items: center;
    gap: 14px;

    width: fit-content;

    margin-top: 20px;
    padding: 12px 20px;

    background: var(--jpl-oranje);
    color: var(--jpl-white);

    border-radius: 2px;

    font-size: .85rem;
    font-weight: 700;

    text-transform: uppercase;
    letter-spacing: .04em;

    transition: background .25s ease, transform .25s ease;
}

/* WHATSAPP ICON*/

.contact-icon {
    display: flex;
    align-items: center;
    justify-content: center;
    width: 50px;
    height: 50px;
    margin: 0 auto 2px;
}

.contact-icon img {
    display: block;
    width: 25px;
    height: 25px;
    object-fit: contain;
}

.contact-whatsapp:hover {
    background: var(--jpl-olive);
    color: var(--jpl-white);
    transform: translateY(-2px);
}

.contact-whatsapp .contact-icon {
    width: auto;
    height: auto;

    border: 0;

    color: inherit;

    font-size: 19px;
}


/* =========================================
   CONTACTO - MÓVIL
========================================= */

@media (max-width: 600px) {

    .contact-details {
        margin-top: 25px;
    }

    .contact-item {
        font-size: .95rem;
    }

    .contact-whatsapp {
        width: 100%;
        justify-content: center;
    }

}

/* =========================================
   WHATSAPP FLOTANTE
========================================= */

.whatsapp-float {
    position: fixed;
    right: 28px;
    bottom: 70px;

    z-index: 999;

    display: flex;
    align-items: center;
    gap: 12px;

    padding: 10px 18px 10px 10px;

    background: var(--jpl-oranje);
    color: var(--jpl-white);

    border-radius: 50px;

    font-size: .8rem;
    font-weight: 700;
    text-transform: uppercase;
    letter-spacing: .03em;

    box-shadow: 0 4px 18px rgba(0,0,0,.2);

    transition:
        background .25s ease,
        transform .25s ease;
}

.whatsapp-float:hover {
    background: var(--jpl-olive);
    color: var(--jpl-white);
    transform: translateY(-3px);
}

.whatsapp-float-icon {
    display: flex;
    align-items: center;
    justify-content: center;

    width: 42px;
    height: 42px;

    flex-shrink: 0;

    border-radius: 50%;

    background: var(--jpl-white);
    color: var(--jpl-oranje);
}

.whatsapp-float-icon svg {
    width: 25px;
    height: 25px;
    fill: currentColor;
}

.whatsapp-float-text {
    white-space: nowrap;
}


/* MÓVIL */

@media (max-width: 600px) {

    .whatsapp-float {
        right: 18px;
        bottom: 18px;

        padding: 8px;

        border-radius: 50%;
    }

    .whatsapp-float-icon {
        width: 48px;
        height: 48px;
    }

    .whatsapp-float-text {
        display: none;
    }

}

/* =========================================
   GALERÍA / CARRUSEL DE PROYECTOS
========================================= */

.projects-gallery {
    margin-top: 50px;
}

.projects-gallery-header {
    display: flex;
    align-items: flex-end;
    justify-content: space-between;
    gap: 30px;
    margin-bottom: 40px;
}

.projects-gallery-header .section-title {
    margin-bottom: 0;
}


/* NAVEGACIÓN */

.gallery-navigation {
    display: flex;
    gap: 10px;
    flex-shrink: 0;
}

.gallery-navigation button {
    display: flex;
    align-items: center;
    justify-content: center;

    width: 48px;
    height: 48px;

    border: 1px solid var(--jpl-carbon);
    background: transparent;
    color: var(--jpl-carbon);

    font-size: 22px;
    cursor: pointer;

    transition:
        background .25s ease,
        color .25s ease,
        transform .25s ease;
}

.gallery-navigation button:hover {
    background: var(--jpl-carbon);
    color: var(--jpl-white);
}


/* CONTENEDOR DEL CARRUSEL */

.projects-carousel {
    overflow: hidden;
    width: 100%;
}

.projects-track {
    display: flex;
    gap: 28px;

    transition: transform .55s cubic-bezier(.22,.61,.36,1);

    will-change: transform;
}


/* TARJETA */

.project-slide {
    flex: 0 0 calc((100% - 56px) / 3);

    min-width: 0;

    background: var(--jpl-white);
    border: 1px solid var(--jpl-border);

    overflow: hidden;
}


/* IMAGEN */

.project-slide-image {
    aspect-ratio: 4 / 3;
    overflow: hidden;
    background: #e5e5e0;
}

.project-slide-image img {
    display: block;

    width: 100%;
    height: 100%;

    object-fit: cover;

    transition: transform .5s ease;
}

.project-slide:hover .project-slide-image img {
    transform: scale(1.04);
}


/* TEXTO */

.project-slide-content {
    padding: 24px;
}

.project-slide-content > span {
    display: block;

    margin-bottom: 10px;

    color: var(--jpl-olive);

    font-size: .75rem;
    font-weight: 700;
    letter-spacing: .12em;
}

.project-slide-content h3 {
    margin: 0 0 10px;

    color: var(--jpl-carbon);

    font-size: 1.25rem;
    line-height: 1.2;
}

.project-slide-content p {
    margin: 0;

    color: var(--jpl-text);

    font-size: .9rem;
    line-height: 1.5;
}


/* INDICADORES */

.gallery-dots {
    display: flex;
    justify-content: center;
    gap: 8px;

    margin-top: 30px;
}

.gallery-dot {
    width: 8px;
    height: 8px;

    padding: 0;

    border: 0;
    border-radius: 50%;

    background: #c5c5bd;

    cursor: pointer;

    transition:
        width .25s ease,
        background .25s ease;
}

.gallery-dot.active {
    width: 28px;
    border-radius: 10px;
    background: var(--jpl-olive);
}


/* CTA */

.projects-gallery-cta {
    margin-top: 45px;
    text-align: center;
}


/* =========================================
   TABLET
========================================= */

@media (max-width: 900px) {

    .projects-gallery {
        margin-top: 80px;
    }

    .project-slide {
        flex: 0 0 calc((100% - 28px) / 2);
    }

}


/* =========================================
   MOBILE
========================================= */

@media (max-width: 600px) {

    .projects-gallery {
        margin-top: 65px;
    }

    .projects-gallery-header {
        align-items: flex-start;
        flex-direction: column;
        margin-bottom: 30px;
    }

    .gallery-navigation {
        align-self: flex-end;
    }

    .project-slide {
        flex: 0 0 88%;
    }

    .project-slide-content {
        padding: 20px;
    }

}

/* =========================================
   POPUP JPL REPARACIONES
========================================= */

.repair-popup {
    position: fixed;
    inset: 0;
    z-index: 3000;

    display: flex;
    align-items: center;
    justify-content: center;

    padding: 24px;
}

.repair-popup[hidden] {
    display: none;
}

.repair-popup-overlay {
    position: absolute;
    inset: 0;

    background: rgba(0, 0, 0, .68);
    backdrop-filter: blur(3px);
}

.repair-popup-content {
    position: relative;
    z-index: 1;

    display: grid;
    grid-template-columns: 1.05fr 1fr;

    width: min(900px, 100%);
    max-height: 90vh;

    overflow: hidden;

    background: var(--jpl-white);
    border: 1px solid var(--jpl-border);

    box-shadow: 0 20px 70px rgba(0, 0, 0, .28);

    animation: repairPopupIn .35s ease both;
}

.repair-popup-image {
    min-height: 420px;
    background: var(--jpl-carbon);
}

.repair-popup-image img {
    display: block;

    width: 100%;
    height: 100%;

    object-fit: cover;
}

.repair-popup-text {
    display: flex;
    flex-direction: column;
    justify-content: center;

    padding: 50px 42px;
}

.repair-popup-text .eyebrow {
    margin-bottom: 18px;
    color: var(--jpl-oranje);
    font-size: .9rem;
    text-transform: uppercase;
    letter-spacing: .08em;
}

.repair-popup-text h2 {
    margin: 0 0 22px;

    color: var(--jpl-carbon);

    font-size: clamp(2rem, 4vw, 3.4rem);
    line-height: .95;
    letter-spacing: -.03em;
}

.repair-popup-text p {
    margin-bottom: 20px;
}

.repair-popup-highlight {
    color: var(--jpl-olive);
    font-weight: 700;
}

.repair-popup-cta {
    align-self: flex-start;
    margin-top: 10px;
}

.repair-popup-close {
    position: absolute;
    top: 14px;
    right: 14px;
    z-index: 5;

    display: flex;
    align-items: center;
    justify-content: center;

    width: 38px;
    height: 38px;

    border: 0;
    border-radius: 50%;

    background: var(--jpl-white);
    color: var(--jpl-carbon);

    font-size: 28px;
    line-height: 1;

    cursor: pointer;

    box-shadow: 0 2px 12px rgba(0, 0, 0, .15);

    transition:
        background .25s ease,
        color .25s ease;
}

.repair-popup-close:hover {
    background: var(--jpl-oranje);
    color: var(--jpl-white);
}

@keyframes repairPopupIn {

    from {
        opacity: 0;
        transform: translateY(20px) scale(.98);
    }

    to {
        opacity: 1;
        transform: translateY(0) scale(1);
    }

}


/* =========================================
   POPUP — TABLET Y MÓVIL
========================================= */

@media (max-width: 700px) {

    .repair-popup {
        padding: 15px;
    }

    .repair-popup-content {
        grid-template-columns: 1fr;
        max-height: 90vh;
        overflow-y: auto;
    }

    .repair-popup-image {
        min-height: 220px;
        max-height: 260px;
    }

    .repair-popup-text {
        padding: 35px 25px 30px;
    }

    .repair-popup-text h2 {
        font-size: 2.5rem;
    }

    .repair-popup-cta {
        width: 100%;
    }

}

/* =========================================
   REVEAL AL HACER SCROLL
========================================= */

.reveal {
    opacity: 0;
    transform: translateY(35px);
    transition:
        opacity 0.8s ease,
        transform 0.8s cubic-bezier(0.22, 1, 0.36, 1);
    will-change: opacity, transform;
}

.reveal.is-visible {
    opacity: 1;
    transform: translateY(0);
}

/* Variaciones sutiles */

.reveal-delay-1 {
    transition-delay: 0.1s;
}

.reveal-delay-2 {
    transition-delay: 0.2s;
}

.reveal-delay-3 {
    transition-delay: 0.3s;
}

/* Accesibilidad: sin animaciones si el usuario las desactiva */

@media (prefers-reduced-motion: reduce) {
    .reveal {
        opacity: 1;
        transform: none;
        transition: none;
    }
}

body {
    position: relative;
    background: var(--jpl-light);
}

body::before {
    content: "";
    position: fixed;
    inset: 0;
    background-image: url("assets/images/mountains.svg");
    background-repeat: no-repeat;
    background-position: center bottom;
    background-size: cover;
    opacity: 0.06;
    pointer-events: none;
    z-index: -1;
}